diff --git a/games/knifehit/c2runtime.js b/games/knifehit/c2runtime.js new file mode 100644 index 00000000..f9e0c9d4 --- /dev/null +++ b/games/knifehit/c2runtime.js @@ -0,0 +1,28105 @@ +// Generated by Construct 2, the HTML5 game and app creator :: http://www.scirra.com +var cr = {}; +cr.plugins_ = {}; +cr.behaviors = {}; +if (typeof Object.getPrototypeOf !== "function") +{ + if (typeof "test".__proto__ === "object") + { + Object.getPrototypeOf = function(object) { + return object.__proto__; + }; + } + else + { + Object.getPrototypeOf = function(object) { + return object.constructor.prototype; + }; + } +} +(function(){ + cr.logexport = function (msg) + { + if (window.console && window.console.log) + window.console.log(msg); + }; + cr.logerror = function (msg) + { + if (window.console && window.console.error) + window.console.error(msg); + }; + cr.seal = function(x) + { + return x; + }; + cr.freeze = function(x) + { + return x; + }; + cr.is_undefined = function (x) + { + return typeof x === "undefined"; + }; + cr.is_number = function (x) + { + return typeof x === "number"; + }; + cr.is_string = function (x) + { + return typeof x === "string"; + }; + cr.isPOT = function (x) + { + return x > 0 && ((x - 1) & x) === 0; + }; + cr.nextHighestPowerOfTwo = function(x) { + --x; + for (var i = 1; i < 32; i <<= 1) { + x = x | x >> i; + } + return x + 1; + } + cr.abs = function (x) + { + return (x < 0 ? -x : x); + }; + cr.max = function (a, b) + { + return (a > b ? a : b); + }; + cr.min = function (a, b) + { + return (a < b ? a : b); + }; + cr.PI = Math.PI; + cr.round = function (x) + { + return (x + 0.5) | 0; + }; + cr.floor = function (x) + { + if (x >= 0) + return x | 0; + else + return (x | 0) - 1; // correctly round down when negative + }; + cr.ceil = function (x) + { + var f = x | 0; + return (f === x ? f : f + 1); + }; + function Vector2(x, y) + { + this.x = x; + this.y = y; + cr.seal(this); + }; + Vector2.prototype.offset = function (px, py) + { + this.x += px; + this.y += py; + return this; + }; + Vector2.prototype.mul = function (px, py) + { + this.x *= px; + this.y *= py; + return this; + }; + cr.vector2 = Vector2; + cr.segments_intersect = function(a1x, a1y, a2x, a2y, b1x, b1y, b2x, b2y) + { + var max_ax, min_ax, max_ay, min_ay, max_bx, min_bx, max_by, min_by; + if (a1x < a2x) + { + min_ax = a1x; + max_ax = a2x; + } + else + { + min_ax = a2x; + max_ax = a1x; + } + if (b1x < b2x) + { + min_bx = b1x; + max_bx = b2x; + } + else + { + min_bx = b2x; + max_bx = b1x; + } + if (max_ax < min_bx || min_ax > max_bx) + return false; + if (a1y < a2y) + { + min_ay = a1y; + max_ay = a2y; + } + else + { + min_ay = a2y; + max_ay = a1y; + } + if (b1y < b2y) + { + min_by = b1y; + max_by = b2y; + } + else + { + min_by = b2y; + max_by = b1y; + } + if (max_ay < min_by || min_ay > max_by) + return false; + var dpx = b1x - a1x + b2x - a2x; + var dpy = b1y - a1y + b2y - a2y; + var qax = a2x - a1x; + var qay = a2y - a1y; + var qbx = b2x - b1x; + var qby = b2y - b1y; + var d = cr.abs(qay * qbx - qby * qax); + var la = qbx * dpy - qby * dpx; + if (cr.abs(la) > d) + return false; + var lb = qax * dpy - qay * dpx; + return cr.abs(lb) <= d; + }; + function Rect(left, top, right, bottom) + { + this.set(left, top, right, bottom); + cr.seal(this); + }; + Rect.prototype.set = function (left, top, right, bottom) + { + this.left = left; + this.top = top; + this.right = right; + this.bottom = bottom; + }; + Rect.prototype.copy = function (r) + { + this.left = r.left; + this.top = r.top; + this.right = r.right; + this.bottom = r.bottom; + }; + Rect.prototype.width = function () + { + return this.right - this.left; + }; + Rect.prototype.height = function () + { + return this.bottom - this.top; + }; + Rect.prototype.offset = function (px, py) + { + this.left += px; + this.top += py; + this.right += px; + this.bottom += py; + return this; + }; + Rect.prototype.normalize = function () + { + var temp = 0; + if (this.left > this.right) + { + temp = this.left; + this.left = this.right; + this.right = temp; + } + if (this.top > this.bottom) + { + temp = this.top; + this.top = this.bottom; + this.bottom = temp; + } + }; + Rect.prototype.intersects_rect = function (rc) + { + return !(rc.right < this.left || rc.bottom < this.top || rc.left > this.right || rc.top > this.bottom); + }; + Rect.prototype.intersects_rect_off = function (rc, ox, oy) + { + return !(rc.right + ox < this.left || rc.bottom + oy < this.top || rc.left + ox > this.right || rc.top + oy > this.bottom); + }; + Rect.prototype.contains_pt = function (x, y) + { + return (x >= this.left && x <= this.right) && (y >= this.top && y <= this.bottom); + }; + Rect.prototype.equals = function (r) + { + return this.left === r.left && this.top === r.top && this.right === r.right && this.bottom === r.bottom; + }; + cr.rect = Rect; + function Quad() + { + this.tlx = 0; + this.tly = 0; + this.trx = 0; + this.try_ = 0; // is a keyword otherwise! + this.brx = 0; + this.bry = 0; + this.blx = 0; + this.bly = 0; + cr.seal(this); + }; + Quad.prototype.set_from_rect = function (rc) + { + this.tlx = rc.left; + this.tly = rc.top; + this.trx = rc.right; + this.try_ = rc.top; + this.brx = rc.right; + this.bry = rc.bottom; + this.blx = rc.left; + this.bly = rc.bottom; + }; + Quad.prototype.set_from_rotated_rect = function (rc, a) + { + if (a === 0) + { + this.set_from_rect(rc); + } + else + { + var sin_a = Math.sin(a); + var cos_a = Math.cos(a); + var left_sin_a = rc.left * sin_a; + var top_sin_a = rc.top * sin_a; + var right_sin_a = rc.right * sin_a; + var bottom_sin_a = rc.bottom * sin_a; + var left_cos_a = rc.left * cos_a; + var top_cos_a = rc.top * cos_a; + var right_cos_a = rc.right * cos_a; + var bottom_cos_a = rc.bottom * cos_a; + this.tlx = left_cos_a - top_sin_a; + this.tly = top_cos_a + left_sin_a; + this.trx = right_cos_a - top_sin_a; + this.try_ = top_cos_a + right_sin_a; + this.brx = right_cos_a - bottom_sin_a; + this.bry = bottom_cos_a + right_sin_a; + this.blx = left_cos_a - bottom_sin_a; + this.bly = bottom_cos_a + left_sin_a; + } + }; + Quad.prototype.offset = function (px, py) + { + this.tlx += px; + this.tly += py; + this.trx += px; + this.try_ += py; + this.brx += px; + this.bry += py; + this.blx += px; + this.bly += py; + return this; + }; + var minresult = 0; + var maxresult = 0; + function minmax4(a, b, c, d) + { + if (a < b) + { + if (c < d) + { + if (a < c) + minresult = a; + else + minresult = c; + if (b > d) + maxresult = b; + else + maxresult = d; + } + else + { + if (a < d) + minresult = a; + else + minresult = d; + if (b > c) + maxresult = b; + else + maxresult = c; + } + } + else + { + if (c < d) + { + if (b < c) + minresult = b; + else + minresult = c; + if (a > d) + maxresult = a; + else + maxresult = d; + } + else + { + if (b < d) + minresult = b; + else + minresult = d; + if (a > c) + maxresult = a; + else + maxresult = c; + } + } + }; + Quad.prototype.bounding_box = function (rc) + { + minmax4(this.tlx, this.trx, this.brx, this.blx); + rc.left = minresult; + rc.right = maxresult; + minmax4(this.tly, this.try_, this.bry, this.bly); + rc.top = minresult; + rc.bottom = maxresult; + }; + Quad.prototype.contains_pt = function (x, y) + { + var tlx = this.tlx; + var tly = this.tly; + var v0x = this.trx - tlx; + var v0y = this.try_ - tly; + var v1x = this.brx - tlx; + var v1y = this.bry - tly; + var v2x = x - tlx; + var v2y = y - tly; + var dot00 = v0x * v0x + v0y * v0y + var dot01 = v0x * v1x + v0y * v1y + var dot02 = v0x * v2x + v0y * v2y + var dot11 = v1x * v1x + v1y * v1y + var dot12 = v1x * v2x + v1y * v2y + var invDenom = 1.0 / (dot00 * dot11 - dot01 * dot01); + var u = (dot11 * dot02 - dot01 * dot12) * invDenom; + var v = (dot00 * dot12 - dot01 * dot02) * invDenom; + if ((u >= 0.0) && (v > 0.0) && (u + v < 1)) + return true; + v0x = this.blx - tlx; + v0y = this.bly - tly; + var dot00 = v0x * v0x + v0y * v0y + var dot01 = v0x * v1x + v0y * v1y + var dot02 = v0x * v2x + v0y * v2y + invDenom = 1.0 / (dot00 * dot11 - dot01 * dot01); + u = (dot11 * dot02 - dot01 * dot12) * invDenom; + v = (dot00 * dot12 - dot01 * dot02) * invDenom; + return (u >= 0.0) && (v > 0.0) && (u + v < 1); + }; + Quad.prototype.at = function (i, xory) + { + if (xory) + { + switch (i) + { + case 0: return this.tlx; + case 1: return this.trx; + case 2: return this.brx; + case 3: return this.blx; + case 4: return this.tlx; + default: return this.tlx; + } + } + else + { + switch (i) + { + case 0: return this.tly; + case 1: return this.try_; + case 2: return this.bry; + case 3: return this.bly; + case 4: return this.tly; + default: return this.tly; + } + } + }; + Quad.prototype.midX = function () + { + return (this.tlx + this.trx + this.brx + this.blx) / 4; + }; + Quad.prototype.midY = function () + { + return (this.tly + this.try_ + this.bry + this.bly) / 4; + }; + Quad.prototype.intersects_segment = function (x1, y1, x2, y2) + { + if (this.contains_pt(x1, y1) || this.contains_pt(x2, y2)) + return true; + var a1x, a1y, a2x, a2y; + var i; + for (i = 0; i < 4; i++) + { + a1x = this.at(i, true); + a1y = this.at(i, false); + a2x = this.at(i + 1, true); + a2y = this.at(i + 1, false); + if (cr.segments_intersect(x1, y1, x2, y2, a1x, a1y, a2x, a2y)) + return true; + } + return false; + }; + Quad.prototype.intersects_quad = function (rhs) + { + var midx = rhs.midX(); + var midy = rhs.midY(); + if (this.contains_pt(midx, midy)) + return true; + midx = this.midX(); + midy = this.midY(); + if (rhs.contains_pt(midx, midy)) + return true; + var a1x, a1y, a2x, a2y, b1x, b1y, b2x, b2y; + var i, j; + for (i = 0; i < 4; i++) + { + for (j = 0; j < 4; j++) + { + a1x = this.at(i, true); + a1y = this.at(i, false); + a2x = this.at(i + 1, true); + a2y = this.at(i + 1, false); + b1x = rhs.at(j, true); + b1y = rhs.at(j, false); + b2x = rhs.at(j + 1, true); + b2y = rhs.at(j + 1, false); + if (cr.segments_intersect(a1x, a1y, a2x, a2y, b1x, b1y, b2x, b2y)) + return true; + } + } + return false; + }; + cr.quad = Quad; + cr.RGB = function (red, green, blue) + { + return Math.max(Math.min(red, 255), 0) + | (Math.max(Math.min(green, 255), 0) << 8) + | (Math.max(Math.min(blue, 255), 0) << 16); + }; + cr.GetRValue = function (rgb) + { + return rgb & 0xFF; + }; + cr.GetGValue = function (rgb) + { + return (rgb & 0xFF00) >> 8; + }; + cr.GetBValue = function (rgb) + { + return (rgb & 0xFF0000) >> 16; + }; + cr.shallowCopy = function (a, b, allowOverwrite) + { + var attr; + for (attr in b) + { + if (b.hasOwnProperty(attr)) + { +; + a[attr] = b[attr]; + } + } + return a; + }; + cr.arrayRemove = function (arr, index) + { + var i, len; + index = cr.floor(index); + if (index < 0 || index >= arr.length) + return; // index out of bounds + for (i = index, len = arr.length - 1; i < len; i++) + arr[i] = arr[i + 1]; + cr.truncateArray(arr, len); + }; + cr.truncateArray = function (arr, index) + { + arr.length = index; + }; + cr.clearArray = function (arr) + { + cr.truncateArray(arr, 0); + }; + cr.shallowAssignArray = function (dest, src) + { + cr.clearArray(dest); + var i, len; + for (i = 0, len = src.length; i < len; ++i) + dest[i] = src[i]; + }; + cr.appendArray = function (a, b) + { + a.push.apply(a, b); + }; + cr.fastIndexOf = function (arr, item) + { + var i, len; + for (i = 0, len = arr.length; i < len; ++i) + { + if (arr[i] === item) + return i; + } + return -1; + }; + cr.arrayFindRemove = function (arr, item) + { + var index = cr.fastIndexOf(arr, item); + if (index !== -1) + cr.arrayRemove(arr, index); + }; + cr.clamp = function(x, a, b) + { + if (x < a) + return a; + else if (x > b) + return b; + else + return x; + }; + cr.to_radians = function(x) + { + return x / (180.0 / cr.PI); + }; + cr.to_degrees = function(x) + { + return x * (180.0 / cr.PI); + }; + cr.clamp_angle_degrees = function (a) + { + a %= 360; // now in (-360, 360) range + if (a < 0) + a += 360; // now in [0, 360) range + return a; + }; + cr.clamp_angle = function (a) + { + a %= 2 * cr.PI; // now in (-2pi, 2pi) range + if (a < 0) + a += 2 * cr.PI; // now in [0, 2pi) range + return a; + }; + cr.to_clamped_degrees = function (x) + { + return cr.clamp_angle_degrees(cr.to_degrees(x)); + }; + cr.to_clamped_radians = function (x) + { + return cr.clamp_angle(cr.to_radians(x)); + }; + cr.angleTo = function(x1, y1, x2, y2) + { + var dx = x2 - x1; + var dy = y2 - y1; + return Math.atan2(dy, dx); + }; + cr.angleDiff = function (a1, a2) + { + if (a1 === a2) + return 0; + var s1 = Math.sin(a1); + var c1 = Math.cos(a1); + var s2 = Math.sin(a2); + var c2 = Math.cos(a2); + var n = s1 * s2 + c1 * c2; + if (n >= 1) + return 0; + if (n <= -1) + return cr.PI; + return Math.acos(n); + }; + cr.angleRotate = function (start, end, step) + { + var ss = Math.sin(start); + var cs = Math.cos(start); + var se = Math.sin(end); + var ce = Math.cos(end); + if (Math.acos(ss * se + cs * ce) > step) + { + if (cs * se - ss * ce > 0) + return cr.clamp_angle(start + step); + else + return cr.clamp_angle(start - step); + } + else + return cr.clamp_angle(end); + }; + cr.angleClockwise = function (a1, a2) + { + var s1 = Math.sin(a1); + var c1 = Math.cos(a1); + var s2 = Math.sin(a2); + var c2 = Math.cos(a2); + return c1 * s2 - s1 * c2 <= 0; + }; + cr.rotatePtAround = function (px, py, a, ox, oy, getx) + { + if (a === 0) + return getx ? px : py; + var sin_a = Math.sin(a); + var cos_a = Math.cos(a); + px -= ox; + py -= oy; + var left_sin_a = px * sin_a; + var top_sin_a = py * sin_a; + var left_cos_a = px * cos_a; + var top_cos_a = py * cos_a; + px = left_cos_a - top_sin_a; + py = top_cos_a + left_sin_a; + px += ox; + py += oy; + return getx ? px : py; + } + cr.distanceTo = function(x1, y1, x2, y2) + { + var dx = x2 - x1; + var dy = y2 - y1; + return Math.sqrt(dx*dx + dy*dy); + }; + cr.xor = function (x, y) + { + return !x !== !y; + }; + cr.lerp = function (a, b, x) + { + return a + (b - a) * x; + }; + cr.unlerp = function (a, b, c) + { + if (a === b) + return 0; // avoid divide by 0 + return (c - a) / (b - a); + }; + cr.anglelerp = function (a, b, x) + { + var diff = cr.angleDiff(a, b); + if (cr.angleClockwise(b, a)) + { + return a + diff * x; + } + else + { + return a - diff * x; + } + }; + cr.qarp = function (a, b, c, x) + { + return cr.lerp(cr.lerp(a, b, x), cr.lerp(b, c, x), x); + }; + cr.cubic = function (a, b, c, d, x) + { + return cr.lerp(cr.qarp(a, b, c, x), cr.qarp(b, c, d, x), x); + }; + cr.cosp = function (a, b, x) + { + return (a + b + (a - b) * Math.cos(x * Math.PI)) / 2; + }; + cr.hasAnyOwnProperty = function (o) + { + var p; + for (p in o) + { + if (o.hasOwnProperty(p)) + return true; + } + return false; + }; + cr.wipe = function (obj) + { + var p; + for (p in obj) + { + if (obj.hasOwnProperty(p)) + delete obj[p]; + } + }; + var startup_time = +(new Date()); + cr.performance_now = function() + { + if (typeof window["performance"] !== "undefined") + { + var winperf = window["performance"]; + if (typeof winperf.now !== "undefined") + return winperf.now(); + else if (typeof winperf["webkitNow"] !== "undefined") + return winperf["webkitNow"](); + else if (typeof winperf["mozNow"] !== "undefined") + return winperf["mozNow"](); + else if (typeof winperf["msNow"] !== "undefined") + return winperf["msNow"](); + } + return Date.now() - startup_time; + }; + var isChrome = false; + var isSafari = false; + var isiOS = false; + var isEjecta = false; + if (typeof window !== "undefined") // not c2 editor + { + isChrome = /chrome/i.test(navigator.userAgent) || /chromium/i.test(navigator.userAgent); + isSafari = !isChrome && /safari/i.test(navigator.userAgent); + isiOS = /(iphone|ipod|ipad)/i.test(navigator.userAgent); + isEjecta = window["c2ejecta"]; + } + var supports_set = ((!isSafari && !isEjecta && !isiOS) && (typeof Set !== "undefined" && typeof Set.prototype["forEach"] !== "undefined")); + function ObjectSet_() + { + this.s = null; + this.items = null; // lazy allocated (hopefully results in better GC performance) + this.item_count = 0; + if (supports_set) + { + this.s = new Set(); + } + this.values_cache = []; + this.cache_valid = true; + cr.seal(this); + }; + ObjectSet_.prototype.contains = function (x) + { + if (this.isEmpty()) + return false; + if (supports_set) + return this.s["has"](x); + else + return (this.items && this.items.hasOwnProperty(x)); + }; + ObjectSet_.prototype.add = function (x) + { + if (supports_set) + { + if (!this.s["has"](x)) + { + this.s["add"](x); + this.cache_valid = false; + } + } + else + { + var str = x.toString(); + var items = this.items; + if (!items) + { + this.items = {}; + this.items[str] = x; + this.item_count = 1; + this.cache_valid = false; + } + else if (!items.hasOwnProperty(str)) + { + items[str] = x; + this.item_count++; + this.cache_valid = false; + } + } + }; + ObjectSet_.prototype.remove = function (x) + { + if (this.isEmpty()) + return; + if (supports_set) + { + if (this.s["has"](x)) + { + this.s["delete"](x); + this.cache_valid = false; + } + } + else if (this.items) + { + var str = x.toString(); + var items = this.items; + if (items.hasOwnProperty(str)) + { + delete items[str]; + this.item_count--; + this.cache_valid = false; + } + } + }; + ObjectSet_.prototype.clear = function (/*wipe_*/) + { + if (this.isEmpty()) + return; + if (supports_set) + { + this.s["clear"](); // best! + } + else + { + this.items = null; // creates garbage; will lazy allocate on next add() + this.item_count = 0; + } + cr.clearArray(this.values_cache); + this.cache_valid = true; + }; + ObjectSet_.prototype.isEmpty = function () + { + return this.count() === 0; + }; + ObjectSet_.prototype.count = function () + { + if (supports_set) + return this.s["size"]; + else + return this.item_count; + }; + var current_arr = null; + var current_index = 0; + function set_append_to_arr(x) + { + current_arr[current_index++] = x; + }; + ObjectSet_.prototype.update_cache = function () + { + if (this.cache_valid) + return; + if (supports_set) + { + cr.clearArray(this.values_cache); + current_arr = this.values_cache; + current_index = 0; + this.s["forEach"](set_append_to_arr); +; + current_arr = null; + current_index = 0; + } + else + { + var values_cache = this.values_cache; + cr.clearArray(values_cache); + var p, n = 0, items = this.items; + if (items) + { + for (p in items) + { + if (items.hasOwnProperty(p)) + values_cache[n++] = items[p]; + } + } +; + } + this.cache_valid = true; + }; + ObjectSet_.prototype.valuesRef = function () + { + this.update_cache(); + return this.values_cache; + }; + cr.ObjectSet = ObjectSet_; + var tmpSet = new cr.ObjectSet(); + cr.removeArrayDuplicates = function (arr) + { + var i, len; + for (i = 0, len = arr.length; i < len; ++i) + { + tmpSet.add(arr[i]); + } + cr.shallowAssignArray(arr, tmpSet.valuesRef()); + tmpSet.clear(); + }; + cr.arrayRemoveAllFromObjectSet = function (arr, remset) + { + if (supports_set) + cr.arrayRemoveAll_set(arr, remset.s); + else + cr.arrayRemoveAll_arr(arr, remset.valuesRef()); + }; + cr.arrayRemoveAll_set = function (arr, s) + { + var i, j, len, item; + for (i = 0, j = 0, len = arr.length; i < len; ++i) + { + item = arr[i]; + if (!s["has"](item)) // not an item to remove + arr[j++] = item; // keep it + } + cr.truncateArray(arr, j); + }; + cr.arrayRemoveAll_arr = function (arr, rem) + { + var i, j, len, item; + for (i = 0, j = 0, len = arr.length; i < len; ++i) + { + item = arr[i]; + if (cr.fastIndexOf(rem, item) === -1) // not an item to remove + arr[j++] = item; // keep it + } + cr.truncateArray(arr, j); + }; + function KahanAdder_() + { + this.c = 0; + this.y = 0; + this.t = 0; + this.sum = 0; + cr.seal(this); + }; + KahanAdder_.prototype.add = function (v) + { + this.y = v - this.c; + this.t = this.sum + this.y; + this.c = (this.t - this.sum) - this.y; + this.sum = this.t; + }; + KahanAdder_.prototype.reset = function () + { + this.c = 0; + this.y = 0; + this.t = 0; + this.sum = 0; + }; + cr.KahanAdder = KahanAdder_; + cr.regexp_escape = function(text) + { + return text.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&"); + }; + function CollisionPoly_(pts_array_) + { + this.pts_cache = []; + this.bboxLeft = 0; + this.bboxTop = 0; + this.bboxRight = 0; + this.bboxBottom = 0; + this.convexpolys = null; // for physics behavior to cache separated polys + this.set_pts(pts_array_); + cr.seal(this); + }; + CollisionPoly_.prototype.set_pts = function(pts_array_) + { + this.pts_array = pts_array_; + this.pts_count = pts_array_.length / 2; // x, y, x, y... in array + this.pts_cache.length = pts_array_.length; + this.cache_width = -1; + this.cache_height = -1; + this.cache_angle = 0; + }; + CollisionPoly_.prototype.is_empty = function() + { + return !this.pts_array.length; + }; + CollisionPoly_.prototype.update_bbox = function () + { + var myptscache = this.pts_cache; + var bboxLeft_ = myptscache[0]; + var bboxRight_ = bboxLeft_; + var bboxTop_ = myptscache[1]; + var bboxBottom_ = bboxTop_; + var x, y, i = 1, i2, len = this.pts_count; + for ( ; i < len; ++i) + { + i2 = i*2; + x = myptscache[i2]; + y = myptscache[i2+1]; + if (x < bboxLeft_) + bboxLeft_ = x; + if (x > bboxRight_) + bboxRight_ = x; + if (y < bboxTop_) + bboxTop_ = y; + if (y > bboxBottom_) + bboxBottom_ = y; + } + this.bboxLeft = bboxLeft_; + this.bboxRight = bboxRight_; + this.bboxTop = bboxTop_; + this.bboxBottom = bboxBottom_; + }; + CollisionPoly_.prototype.set_from_rect = function(rc, offx, offy) + { + this.pts_cache.length = 8; + this.pts_count = 4; + var myptscache = this.pts_cache; + myptscache[0] = rc.left - offx; + myptscache[1] = rc.top - offy; + myptscache[2] = rc.right - offx; + myptscache[3] = rc.top - offy; + myptscache[4] = rc.right - offx; + myptscache[5] = rc.bottom - offy; + myptscache[6] = rc.left - offx; + myptscache[7] = rc.bottom - offy; + this.cache_width = rc.right - rc.left; + this.cache_height = rc.bottom - rc.top; + this.update_bbox(); + }; + CollisionPoly_.prototype.set_from_quad = function(q, offx, offy, w, h) + { + this.pts_cache.length = 8; + this.pts_count = 4; + var myptscache = this.pts_cache; + myptscache[0] = q.tlx - offx; + myptscache[1] = q.tly - offy; + myptscache[2] = q.trx - offx; + myptscache[3] = q.try_ - offy; + myptscache[4] = q.brx - offx; + myptscache[5] = q.bry - offy; + myptscache[6] = q.blx - offx; + myptscache[7] = q.bly - offy; + this.cache_width = w; + this.cache_height = h; + this.update_bbox(); + }; + CollisionPoly_.prototype.set_from_poly = function (r) + { + this.pts_count = r.pts_count; + cr.shallowAssignArray(this.pts_cache, r.pts_cache); + this.bboxLeft = r.bboxLeft; + this.bboxTop - r.bboxTop; + this.bboxRight = r.bboxRight; + this.bboxBottom = r.bboxBottom; + }; + CollisionPoly_.prototype.cache_poly = function(w, h, a) + { + if (this.cache_width === w && this.cache_height === h && this.cache_angle === a) + return; // cache up-to-date + this.cache_width = w; + this.cache_height = h; + this.cache_angle = a; + var i, i2, i21, len, x, y; + var sina = 0; + var cosa = 1; + var myptsarray = this.pts_array; + var myptscache = this.pts_cache; + if (a !== 0) + { + sina = Math.sin(a); + cosa = Math.cos(a); + } + for (i = 0, len = this.pts_count; i < len; i++) + { + i2 = i*2; + i21 = i2+1; + x = myptsarray[i2] * w; + y = myptsarray[i21] * h; + myptscache[i2] = (x * cosa) - (y * sina); + myptscache[i21] = (y * cosa) + (x * sina); + } + this.update_bbox(); + }; + CollisionPoly_.prototype.contains_pt = function (a2x, a2y) + { + var myptscache = this.pts_cache; + if (a2x === myptscache[0] && a2y === myptscache[1]) + return true; + var i, i2, imod, len = this.pts_count; + var a1x = this.bboxLeft - 110; + var a1y = this.bboxTop - 101; + var a3x = this.bboxRight + 131 + var a3y = this.bboxBottom + 120; + var b1x, b1y, b2x, b2y; + var count1 = 0, count2 = 0; + for (i = 0; i < len; i++) + { + i2 = i*2; + imod = ((i+1)%len)*2; + b1x = myptscache[i2]; + b1y = myptscache[i2+1]; + b2x = myptscache[imod]; + b2y = myptscache[imod+1]; + if (cr.segments_intersect(a1x, a1y, a2x, a2y, b1x, b1y, b2x, b2y)) + count1++; + if (cr.segments_intersect(a3x, a3y, a2x, a2y, b1x, b1y, b2x, b2y)) + count2++; + } + return (count1 % 2 === 1) || (count2 % 2 === 1); + }; + CollisionPoly_.prototype.intersects_poly = function (rhs, offx, offy) + { + var rhspts = rhs.pts_cache; + var mypts = this.pts_cache; + if (this.contains_pt(rhspts[0] + offx, rhspts[1] + offy)) + return true; + if (rhs.contains_pt(mypts[0] - offx, mypts[1] - offy)) + return true; + var i, i2, imod, leni, j, j2, jmod, lenj; + var a1x, a1y, a2x, a2y, b1x, b1y, b2x, b2y; + for (i = 0, leni = this.pts_count; i < leni; i++) + { + i2 = i*2; + imod = ((i+1)%leni)*2; + a1x = mypts[i2]; + a1y = mypts[i2+1]; + a2x = mypts[imod]; + a2y = mypts[imod+1]; + for (j = 0, lenj = rhs.pts_count; j < lenj; j++) + { + j2 = j*2; + jmod = ((j+1)%lenj)*2; + b1x = rhspts[j2] + offx; + b1y = rhspts[j2+1] + offy; + b2x = rhspts[jmod] + offx; + b2y = rhspts[jmod+1] + offy; + if (cr.segments_intersect(a1x, a1y, a2x, a2y, b1x, b1y, b2x, b2y)) + return true; + } + } + return false; + }; + CollisionPoly_.prototype.intersects_segment = function (offx, offy, x1, y1, x2, y2) + { + var mypts = this.pts_cache; + if (this.contains_pt(x1 - offx, y1 - offy)) + return true; + var i, leni, i2, imod; + var a1x, a1y, a2x, a2y; + for (i = 0, leni = this.pts_count; i < leni; i++) + { + i2 = i*2; + imod = ((i+1)%leni)*2; + a1x = mypts[i2] + offx; + a1y = mypts[i2+1] + offy; + a2x = mypts[imod] + offx; + a2y = mypts[imod+1] + offy; + if (cr.segments_intersect(x1, y1, x2, y2, a1x, a1y, a2x, a2y)) + return true; + } + return false; + }; + CollisionPoly_.prototype.mirror = function (px) + { + var i, leni, i2; + for (i = 0, leni = this.pts_count; i < leni; ++i) + { + i2 = i*2; + this.pts_cache[i2] = px * 2 - this.pts_cache[i2]; + } + }; + CollisionPoly_.prototype.flip = function (py) + { + var i, leni, i21; + for (i = 0, leni = this.pts_count; i < leni; ++i) + { + i21 = i*2+1; + this.pts_cache[i21] = py * 2 - this.pts_cache[i21]; + } + }; + CollisionPoly_.prototype.diag = function () + { + var i, leni, i2, i21, temp; + for (i = 0, leni = this.pts_count; i < leni; ++i) + { + i2 = i*2; + i21 = i2+1; + temp = this.pts_cache[i2]; + this.pts_cache[i2] = this.pts_cache[i21]; + this.pts_cache[i21] = temp; + } + }; + cr.CollisionPoly = CollisionPoly_; + function SparseGrid_(cellwidth_, cellheight_) + { + this.cellwidth = cellwidth_; + this.cellheight = cellheight_; + this.cells = {}; + }; + SparseGrid_.prototype.totalCellCount = 0; + SparseGrid_.prototype.getCell = function (x_, y_, create_if_missing) + { + var ret; + var col = this.cells[x_]; + if (!col) + { + if (create_if_missing) + { + ret = allocGridCell(this, x_, y_); + this.cells[x_] = {}; + this.cells[x_][y_] = ret; + return ret; + } + else + return null; + } + ret = col[y_]; + if (ret) + return ret; + else if (create_if_missing) + { + ret = allocGridCell(this, x_, y_); + this.cells[x_][y_] = ret; + return ret; + } + else + return null; + }; + SparseGrid_.prototype.XToCell = function (x_) + { + return cr.floor(x_ / this.cellwidth); + }; + SparseGrid_.prototype.YToCell = function (y_) + { + return cr.floor(y_ / this.cellheight); + }; + SparseGrid_.prototype.update = function (inst, oldrange, newrange) + { + var x, lenx, y, leny, cell; + if (oldrange) + { + for (x = oldrange.left, lenx = oldrange.right; x <= lenx; ++x) + { + for (y = oldrange.top, leny = oldrange.bottom; y <= leny; ++y) + { + if (newrange && newrange.contains_pt(x, y)) + continue; // is still in this cell + cell = this.getCell(x, y, false); // don't create if missing + if (!cell) + continue; // cell does not exist yet + cell.remove(inst); + if (cell.isEmpty()) + { + freeGridCell(cell); + this.cells[x][y] = null; + } + } + } + } + if (newrange) + { + for (x = newrange.left, lenx = newrange.right; x <= lenx; ++x) + { + for (y = newrange.top, leny = newrange.bottom; y <= leny; ++y) + { + if (oldrange && oldrange.contains_pt(x, y)) + continue; // is still in this cell + this.getCell(x, y, true).insert(inst); + } + } + } + }; + SparseGrid_.prototype.queryRange = function (rc, result) + { + var x, lenx, ystart, y, leny, cell; + x = this.XToCell(rc.left); + ystart = this.YToCell(rc.top); + lenx = this.XToCell(rc.right); + leny = this.YToCell(rc.bottom); + for ( ; x <= lenx; ++x) + { + for (y = ystart; y <= leny; ++y) + { + cell = this.getCell(x, y, false); + if (!cell) + continue; + cell.dump(result); + } + } + }; + cr.SparseGrid = SparseGrid_; + function RenderGrid_(cellwidth_, cellheight_) + { + this.cellwidth = cellwidth_; + this.cellheight = cellheight_; + this.cells = {}; + }; + RenderGrid_.prototype.totalCellCount = 0; + RenderGrid_.prototype.getCell = function (x_, y_, create_if_missing) + { + var ret; + var col = this.cells[x_]; + if (!col) + { + if (create_if_missing) + { + ret = allocRenderCell(this, x_, y_); + this.cells[x_] = {}; + this.cells[x_][y_] = ret; + return ret; + } + else + return null; + } + ret = col[y_]; + if (ret) + return ret; + else if (create_if_missing) + { + ret = allocRenderCell(this, x_, y_); + this.cells[x_][y_] = ret; + return ret; + } + else + return null; + }; + RenderGrid_.prototype.XToCell = function (x_) + { + return cr.floor(x_ / this.cellwidth); + }; + RenderGrid_.prototype.YToCell = function (y_) + { + return cr.floor(y_ / this.cellheight); + }; + RenderGrid_.prototype.update = function (inst, oldrange, newrange) + { + var x, lenx, y, leny, cell; + if (oldrange) + { + for (x = oldrange.left, lenx = oldrange.right; x <= lenx; ++x) + { + for (y = oldrange.top, leny = oldrange.bottom; y <= leny; ++y) + { + if (newrange && newrange.contains_pt(x, y)) + continue; // is still in this cell + cell = this.getCell(x, y, false); // don't create if missing + if (!cell) + continue; // cell does not exist yet + cell.remove(inst); + if (cell.isEmpty()) + { + freeRenderCell(cell); + this.cells[x][y] = null; + } + } + } + } + if (newrange) + { + for (x = newrange.left, lenx = newrange.right; x <= lenx; ++x) + { + for (y = newrange.top, leny = newrange.bottom; y <= leny; ++y) + { + if (oldrange && oldrange.contains_pt(x, y)) + continue; // is still in this cell + this.getCell(x, y, true).insert(inst); + } + } + } + }; + RenderGrid_.prototype.queryRange = function (left, top, right, bottom, result) + { + var x, lenx, ystart, y, leny, cell; + x = this.XToCell(left); + ystart = this.YToCell(top); + lenx = this.XToCell(right); + leny = this.YToCell(bottom); + for ( ; x <= lenx; ++x) + { + for (y = ystart; y <= leny; ++y) + { + cell = this.getCell(x, y, false); + if (!cell) + continue; + cell.dump(result); + } + } + }; + RenderGrid_.prototype.markRangeChanged = function (rc) + { + var x, lenx, ystart, y, leny, cell; + x = rc.left; + ystart = rc.top; + lenx = rc.right; + leny = rc.bottom; + for ( ; x <= lenx; ++x) + { + for (y = ystart; y <= leny; ++y) + { + cell = this.getCell(x, y, false); + if (!cell) + continue; + cell.is_sorted = false; + } + } + }; + cr.RenderGrid = RenderGrid_; + var gridcellcache = []; + function allocGridCell(grid_, x_, y_) + { + var ret; + SparseGrid_.prototype.totalCellCount++; + if (gridcellcache.length) + { + ret = gridcellcache.pop(); + ret.grid = grid_; + ret.x = x_; + ret.y = y_; + return ret; + } + else + return new cr.GridCell(grid_, x_, y_); + }; + function freeGridCell(c) + { + SparseGrid_.prototype.totalCellCount--; + c.objects.clear(); + if (gridcellcache.length < 1000) + gridcellcache.push(c); + }; + function GridCell_(grid_, x_, y_) + { + this.grid = grid_; + this.x = x_; + this.y = y_; + this.objects = new cr.ObjectSet(); + }; + GridCell_.prototype.isEmpty = function () + { + return this.objects.isEmpty(); + }; + GridCell_.prototype.insert = function (inst) + { + this.objects.add(inst); + }; + GridCell_.prototype.remove = function (inst) + { + this.objects.remove(inst); + }; + GridCell_.prototype.dump = function (result) + { + cr.appendArray(result, this.objects.valuesRef()); + }; + cr.GridCell = GridCell_; + var rendercellcache = []; + function allocRenderCell(grid_, x_, y_) + { + var ret; + RenderGrid_.prototype.totalCellCount++; + if (rendercellcache.length) + { + ret = rendercellcache.pop(); + ret.grid = grid_; + ret.x = x_; + ret.y = y_; + return ret; + } + else + return new cr.RenderCell(grid_, x_, y_); + }; + function freeRenderCell(c) + { + RenderGrid_.prototype.totalCellCount--; + c.reset(); + if (rendercellcache.length < 1000) + rendercellcache.push(c); + }; + function RenderCell_(grid_, x_, y_) + { + this.grid = grid_; + this.x = x_; + this.y = y_; + this.objects = []; // array which needs to be sorted by Z order + this.is_sorted = true; // whether array is in correct sort order or not + this.pending_removal = new cr.ObjectSet(); + this.any_pending_removal = false; + }; + RenderCell_.prototype.isEmpty = function () + { + if (!this.objects.length) + { +; +; + return true; + } + if (this.objects.length > this.pending_removal.count()) + return false; +; + this.flush_pending(); // takes fast path and just resets state + return true; + }; + RenderCell_.prototype.insert = function (inst) + { + if (this.pending_removal.contains(inst)) + { + this.pending_removal.remove(inst); + if (this.pending_removal.isEmpty()) + this.any_pending_removal = false; + return; + } + if (this.objects.length) + { + var top = this.objects[this.objects.length - 1]; + if (top.get_zindex() > inst.get_zindex()) + this.is_sorted = false; // 'inst' should be somewhere beneath 'top' + this.objects.push(inst); + } + else + { + this.objects.push(inst); + this.is_sorted = true; + } +; + }; + RenderCell_.prototype.remove = function (inst) + { + this.pending_removal.add(inst); + this.any_pending_removal = true; + if (this.pending_removal.count() >= 30) + this.flush_pending(); + }; + RenderCell_.prototype.flush_pending = function () + { +; + if (!this.any_pending_removal) + return; // not changed + if (this.pending_removal.count() === this.objects.length) + { + this.reset(); + return; + } + cr.arrayRemoveAllFromObjectSet(this.objects, this.pending_removal); + this.pending_removal.clear(); + this.any_pending_removal = false; + }; + function sortByInstanceZIndex(a, b) + { + return a.zindex - b.zindex; + }; + RenderCell_.prototype.ensure_sorted = function () + { + if (this.is_sorted) + return; // already sorted + this.objects.sort(sortByInstanceZIndex); + this.is_sorted = true; + }; + RenderCell_.prototype.reset = function () + { + cr.clearArray(this.objects); + this.is_sorted = true; + this.pending_removal.clear(); + this.any_pending_removal = false; + }; + RenderCell_.prototype.dump = function (result) + { + this.flush_pending(); + this.ensure_sorted(); + if (this.objects.length) + result.push(this.objects); + }; + cr.RenderCell = RenderCell_; + var fxNames = [ "lighter", + "xor", + "copy", + "destination-over", + "source-in", + "destination-in", + "source-out", + "destination-out", + "source-atop", + "destination-atop"]; + cr.effectToCompositeOp = function(effect) + { + if (effect <= 0 || effect >= 11) + return "source-over"; + return fxNames[effect - 1]; // not including "none" so offset by 1 + }; + cr.setGLBlend = function(this_, effect, gl) + { + if (!gl) + return; + this_.srcBlend = gl.ONE; + this_.destBlend = gl.ONE_MINUS_SRC_ALPHA; + switch (effect) { + case 1: // lighter (additive) + this_.srcBlend = gl.ONE; + this_.destBlend = gl.ONE; + break; + case 2: // xor + break; // todo + case 3: // copy + this_.srcBlend = gl.ONE; + this_.destBlend = gl.ZERO; + break; + case 4: // destination-over + this_.srcBlend = gl.ONE_MINUS_DST_ALPHA; + this_.destBlend = gl.ONE; + break; + case 5: // source-in + this_.srcBlend = gl.DST_ALPHA; + this_.destBlend = gl.ZERO; + break; + case 6: // destination-in + this_.srcBlend = gl.ZERO; + this_.destBlend = gl.SRC_ALPHA; + break; + case 7: // source-out + this_.srcBlend = gl.ONE_MINUS_DST_ALPHA; + this_.destBlend = gl.ZERO; + break; + case 8: // destination-out + this_.srcBlend = gl.ZERO; + this_.destBlend = gl.ONE_MINUS_SRC_ALPHA; + break; + case 9: // source-atop + this_.srcBlend = gl.DST_ALPHA; + this_.destBlend = gl.ONE_MINUS_SRC_ALPHA; + break; + case 10: // destination-atop + this_.srcBlend = gl.ONE_MINUS_DST_ALPHA; + this_.destBlend = gl.SRC_ALPHA; + break; + } + }; + cr.round6dp = function (x) + { + return Math.round(x * 1000000) / 1000000; + }; + /* + var localeCompare_options = { + "usage": "search", + "sensitivity": "accent" + }; + var has_localeCompare = !!"a".localeCompare; + var localeCompare_works1 = (has_localeCompare && "a".localeCompare("A", undefined, localeCompare_options) === 0); + var localeCompare_works2 = (has_localeCompare && "a".localeCompare("รก", undefined, localeCompare_options) !== 0); + var supports_localeCompare = (has_localeCompare && localeCompare_works1 && localeCompare_works2); + */ + cr.equals_nocase = function (a, b) + { + if (typeof a !== "string" || typeof b !== "string") + return false; + if (a.length !== b.length) + return false; + if (a === b) + return true; + /* + if (supports_localeCompare) + { + return (a.localeCompare(b, undefined, localeCompare_options) === 0); + } + else + { + */ + return a.toLowerCase() === b.toLowerCase(); + }; + cr.isCanvasInputEvent = function (e) + { + var target = e.target; + if (!target) + return true; + if (target === document || target === window) + return true; + if (document && document.body && target === document.body) + return true; + if (cr.equals_nocase(target.tagName, "canvas")) + return true; + return false; + }; +}()); +var MatrixArray=typeof Float32Array!=="undefined"?Float32Array:Array,glMatrixArrayType=MatrixArray,vec3={},mat3={},mat4={},quat4={};vec3.create=function(a){var b=new MatrixArray(3);a&&(b[0]=a[0],b[1]=a[1],b[2]=a[2]);return b};vec3.set=function(a,b){b[0]=a[0];b[1]=a[1];b[2]=a[2];return b};vec3.add=function(a,b,c){if(!c||a===c)return a[0]+=b[0],a[1]+=b[1],a[2]+=b[2],a;c[0]=a[0]+b[0];c[1]=a[1]+b[1];c[2]=a[2]+b[2];return c}; +vec3.subtract=function(a,b,c){if(!c||a===c)return a[0]-=b[0],a[1]-=b[1],a[2]-=b[2],a;c[0]=a[0]-b[0];c[1]=a[1]-b[1];c[2]=a[2]-b[2];return c};vec3.negate=function(a,b){b||(b=a);b[0]=-a[0];b[1]=-a[1];b[2]=-a[2];return b};vec3.scale=function(a,b,c){if(!c||a===c)return a[0]*=b,a[1]*=b,a[2]*=b,a;c[0]=a[0]*b;c[1]=a[1]*b;c[2]=a[2]*b;return c}; +vec3.normalize=function(a,b){b||(b=a);var c=a[0],d=a[1],e=a[2],g=Math.sqrt(c*c+d*d+e*e);if(g){if(g===1)return b[0]=c,b[1]=d,b[2]=e,b}else return b[0]=0,b[1]=0,b[2]=0,b;g=1/g;b[0]=c*g;b[1]=d*g;b[2]=e*g;return b};vec3.cross=function(a,b,c){c||(c=a);var d=a[0],e=a[1],a=a[2],g=b[0],f=b[1],b=b[2];c[0]=e*b-a*f;c[1]=a*g-d*b;c[2]=d*f-e*g;return c};vec3.length=function(a){var b=a[0],c=a[1],a=a[2];return Math.sqrt(b*b+c*c+a*a)};vec3.dot=function(a,b){return a[0]*b[0]+a[1]*b[1]+a[2]*b[2]}; +vec3.direction=function(a,b,c){c||(c=a);var d=a[0]-b[0],e=a[1]-b[1],a=a[2]-b[2],b=Math.sqrt(d*d+e*e+a*a);if(!b)return c[0]=0,c[1]=0,c[2]=0,c;b=1/b;c[0]=d*b;c[1]=e*b;c[2]=a*b;return c};vec3.lerp=function(a,b,c,d){d||(d=a);d[0]=a[0]+c*(b[0]-a[0]);d[1]=a[1]+c*(b[1]-a[1]);d[2]=a[2]+c*(b[2]-a[2]);return d};vec3.str=function(a){return"["+a[0]+", "+a[1]+", "+a[2]+"]"}; +mat3.create=function(a){var b=new MatrixArray(9);a&&(b[0]=a[0],b[1]=a[1],b[2]=a[2],b[3]=a[3],b[4]=a[4],b[5]=a[5],b[6]=a[6],b[7]=a[7],b[8]=a[8]);return b};mat3.set=function(a,b){b[0]=a[0];b[1]=a[1];b[2]=a[2];b[3]=a[3];b[4]=a[4];b[5]=a[5];b[6]=a[6];b[7]=a[7];b[8]=a[8];return b};mat3.identity=function(a){a[0]=1;a[1]=0;a[2]=0;a[3]=0;a[4]=1;a[5]=0;a[6]=0;a[7]=0;a[8]=1;return a}; +mat3.transpose=function(a,b){if(!b||a===b){var c=a[1],d=a[2],e=a[5];a[1]=a[3];a[2]=a[6];a[3]=c;a[5]=a[7];a[6]=d;a[7]=e;return a}b[0]=a[0];b[1]=a[3];b[2]=a[6];b[3]=a[1];b[4]=a[4];b[5]=a[7];b[6]=a[2];b[7]=a[5];b[8]=a[8];return b};mat3.toMat4=function(a,b){b||(b=mat4.create());b[15]=1;b[14]=0;b[13]=0;b[12]=0;b[11]=0;b[10]=a[8];b[9]=a[7];b[8]=a[6];b[7]=0;b[6]=a[5];b[5]=a[4];b[4]=a[3];b[3]=0;b[2]=a[2];b[1]=a[1];b[0]=a[0];return b}; +mat3.str=function(a){return"["+a[0]+", "+a[1]+", "+a[2]+", "+a[3]+", "+a[4]+", "+a[5]+", "+a[6]+", "+a[7]+", "+a[8]+"]"};mat4.create=function(a){var b=new MatrixArray(16);a&&(b[0]=a[0],b[1]=a[1],b[2]=a[2],b[3]=a[3],b[4]=a[4],b[5]=a[5],b[6]=a[6],b[7]=a[7],b[8]=a[8],b[9]=a[9],b[10]=a[10],b[11]=a[11],b[12]=a[12],b[13]=a[13],b[14]=a[14],b[15]=a[15]);return b}; +mat4.set=function(a,b){b[0]=a[0];b[1]=a[1];b[2]=a[2];b[3]=a[3];b[4]=a[4];b[5]=a[5];b[6]=a[6];b[7]=a[7];b[8]=a[8];b[9]=a[9];b[10]=a[10];b[11]=a[11];b[12]=a[12];b[13]=a[13];b[14]=a[14];b[15]=a[15];return b};mat4.identity=function(a){a[0]=1;a[1]=0;a[2]=0;a[3]=0;a[4]=0;a[5]=1;a[6]=0;a[7]=0;a[8]=0;a[9]=0;a[10]=1;a[11]=0;a[12]=0;a[13]=0;a[14]=0;a[15]=1;return a}; +mat4.transpose=function(a,b){if(!b||a===b){var c=a[1],d=a[2],e=a[3],g=a[6],f=a[7],h=a[11];a[1]=a[4];a[2]=a[8];a[3]=a[12];a[4]=c;a[6]=a[9];a[7]=a[13];a[8]=d;a[9]=g;a[11]=a[14];a[12]=e;a[13]=f;a[14]=h;return a}b[0]=a[0];b[1]=a[4];b[2]=a[8];b[3]=a[12];b[4]=a[1];b[5]=a[5];b[6]=a[9];b[7]=a[13];b[8]=a[2];b[9]=a[6];b[10]=a[10];b[11]=a[14];b[12]=a[3];b[13]=a[7];b[14]=a[11];b[15]=a[15];return b}; +mat4.determinant=function(a){var b=a[0],c=a[1],d=a[2],e=a[3],g=a[4],f=a[5],h=a[6],i=a[7],j=a[8],k=a[9],l=a[10],n=a[11],o=a[12],m=a[13],p=a[14],a=a[15];return o*k*h*e-j*m*h*e-o*f*l*e+g*m*l*e+j*f*p*e-g*k*p*e-o*k*d*i+j*m*d*i+o*c*l*i-b*m*l*i-j*c*p*i+b*k*p*i+o*f*d*n-g*m*d*n-o*c*h*n+b*m*h*n+g*c*p*n-b*f*p*n-j*f*d*a+g*k*d*a+j*c*h*a-b*k*h*a-g*c*l*a+b*f*l*a}; +mat4.inverse=function(a,b){b||(b=a);var c=a[0],d=a[1],e=a[2],g=a[3],f=a[4],h=a[5],i=a[6],j=a[7],k=a[8],l=a[9],n=a[10],o=a[11],m=a[12],p=a[13],r=a[14],s=a[15],A=c*h-d*f,B=c*i-e*f,t=c*j-g*f,u=d*i-e*h,v=d*j-g*h,w=e*j-g*i,x=k*p-l*m,y=k*r-n*m,z=k*s-o*m,C=l*r-n*p,D=l*s-o*p,E=n*s-o*r,q=1/(A*E-B*D+t*C+u*z-v*y+w*x);b[0]=(h*E-i*D+j*C)*q;b[1]=(-d*E+e*D-g*C)*q;b[2]=(p*w-r*v+s*u)*q;b[3]=(-l*w+n*v-o*u)*q;b[4]=(-f*E+i*z-j*y)*q;b[5]=(c*E-e*z+g*y)*q;b[6]=(-m*w+r*t-s*B)*q;b[7]=(k*w-n*t+o*B)*q;b[8]=(f*D-h*z+j*x)*q; +b[9]=(-c*D+d*z-g*x)*q;b[10]=(m*v-p*t+s*A)*q;b[11]=(-k*v+l*t-o*A)*q;b[12]=(-f*C+h*y-i*x)*q;b[13]=(c*C-d*y+e*x)*q;b[14]=(-m*u+p*B-r*A)*q;b[15]=(k*u-l*B+n*A)*q;return b};mat4.toRotationMat=function(a,b){b||(b=mat4.create());b[0]=a[0];b[1]=a[1];b[2]=a[2];b[3]=a[3];b[4]=a[4];b[5]=a[5];b[6]=a[6];b[7]=a[7];b[8]=a[8];b[9]=a[9];b[10]=a[10];b[11]=a[11];b[12]=0;b[13]=0;b[14]=0;b[15]=1;return b}; +mat4.toMat3=function(a,b){b||(b=mat3.create());b[0]=a[0];b[1]=a[1];b[2]=a[2];b[3]=a[4];b[4]=a[5];b[5]=a[6];b[6]=a[8];b[7]=a[9];b[8]=a[10];return b};mat4.toInverseMat3=function(a,b){var c=a[0],d=a[1],e=a[2],g=a[4],f=a[5],h=a[6],i=a[8],j=a[9],k=a[10],l=k*f-h*j,n=-k*g+h*i,o=j*g-f*i,m=c*l+d*n+e*o;if(!m)return null;m=1/m;b||(b=mat3.create());b[0]=l*m;b[1]=(-k*d+e*j)*m;b[2]=(h*d-e*f)*m;b[3]=n*m;b[4]=(k*c-e*i)*m;b[5]=(-h*c+e*g)*m;b[6]=o*m;b[7]=(-j*c+d*i)*m;b[8]=(f*c-d*g)*m;return b}; +mat4.multiply=function(a,b,c){c||(c=a);var d=a[0],e=a[1],g=a[2],f=a[3],h=a[4],i=a[5],j=a[6],k=a[7],l=a[8],n=a[9],o=a[10],m=a[11],p=a[12],r=a[13],s=a[14],a=a[15],A=b[0],B=b[1],t=b[2],u=b[3],v=b[4],w=b[5],x=b[6],y=b[7],z=b[8],C=b[9],D=b[10],E=b[11],q=b[12],F=b[13],G=b[14],b=b[15];c[0]=A*d+B*h+t*l+u*p;c[1]=A*e+B*i+t*n+u*r;c[2]=A*g+B*j+t*o+u*s;c[3]=A*f+B*k+t*m+u*a;c[4]=v*d+w*h+x*l+y*p;c[5]=v*e+w*i+x*n+y*r;c[6]=v*g+w*j+x*o+y*s;c[7]=v*f+w*k+x*m+y*a;c[8]=z*d+C*h+D*l+E*p;c[9]=z*e+C*i+D*n+E*r;c[10]=z*g+C* +j+D*o+E*s;c[11]=z*f+C*k+D*m+E*a;c[12]=q*d+F*h+G*l+b*p;c[13]=q*e+F*i+G*n+b*r;c[14]=q*g+F*j+G*o+b*s;c[15]=q*f+F*k+G*m+b*a;return c};mat4.multiplyVec3=function(a,b,c){c||(c=b);var d=b[0],e=b[1],b=b[2];c[0]=a[0]*d+a[4]*e+a[8]*b+a[12];c[1]=a[1]*d+a[5]*e+a[9]*b+a[13];c[2]=a[2]*d+a[6]*e+a[10]*b+a[14];return c}; +mat4.multiplyVec4=function(a,b,c){c||(c=b);var d=b[0],e=b[1],g=b[2],b=b[3];c[0]=a[0]*d+a[4]*e+a[8]*g+a[12]*b;c[1]=a[1]*d+a[5]*e+a[9]*g+a[13]*b;c[2]=a[2]*d+a[6]*e+a[10]*g+a[14]*b;c[3]=a[3]*d+a[7]*e+a[11]*g+a[15]*b;return c}; +mat4.translate=function(a,b,c){var d=b[0],e=b[1],b=b[2],g,f,h,i,j,k,l,n,o,m,p,r;if(!c||a===c)return a[12]=a[0]*d+a[4]*e+a[8]*b+a[12],a[13]=a[1]*d+a[5]*e+a[9]*b+a[13],a[14]=a[2]*d+a[6]*e+a[10]*b+a[14],a[15]=a[3]*d+a[7]*e+a[11]*b+a[15],a;g=a[0];f=a[1];h=a[2];i=a[3];j=a[4];k=a[5];l=a[6];n=a[7];o=a[8];m=a[9];p=a[10];r=a[11];c[0]=g;c[1]=f;c[2]=h;c[3]=i;c[4]=j;c[5]=k;c[6]=l;c[7]=n;c[8]=o;c[9]=m;c[10]=p;c[11]=r;c[12]=g*d+j*e+o*b+a[12];c[13]=f*d+k*e+m*b+a[13];c[14]=h*d+l*e+p*b+a[14];c[15]=i*d+n*e+r*b+a[15]; +return c};mat4.scale=function(a,b,c){var d=b[0],e=b[1],b=b[2];if(!c||a===c)return a[0]*=d,a[1]*=d,a[2]*=d,a[3]*=d,a[4]*=e,a[5]*=e,a[6]*=e,a[7]*=e,a[8]*=b,a[9]*=b,a[10]*=b,a[11]*=b,a;c[0]=a[0]*d;c[1]=a[1]*d;c[2]=a[2]*d;c[3]=a[3]*d;c[4]=a[4]*e;c[5]=a[5]*e;c[6]=a[6]*e;c[7]=a[7]*e;c[8]=a[8]*b;c[9]=a[9]*b;c[10]=a[10]*b;c[11]=a[11]*b;c[12]=a[12];c[13]=a[13];c[14]=a[14];c[15]=a[15];return c}; +mat4.rotate=function(a,b,c,d){var e=c[0],g=c[1],c=c[2],f=Math.sqrt(e*e+g*g+c*c),h,i,j,k,l,n,o,m,p,r,s,A,B,t,u,v,w,x,y,z;if(!f)return null;f!==1&&(f=1/f,e*=f,g*=f,c*=f);h=Math.sin(b);i=Math.cos(b);j=1-i;b=a[0];f=a[1];k=a[2];l=a[3];n=a[4];o=a[5];m=a[6];p=a[7];r=a[8];s=a[9];A=a[10];B=a[11];t=e*e*j+i;u=g*e*j+c*h;v=c*e*j-g*h;w=e*g*j-c*h;x=g*g*j+i;y=c*g*j+e*h;z=e*c*j+g*h;e=g*c*j-e*h;g=c*c*j+i;d?a!==d&&(d[12]=a[12],d[13]=a[13],d[14]=a[14],d[15]=a[15]):d=a;d[0]=b*t+n*u+r*v;d[1]=f*t+o*u+s*v;d[2]=k*t+m*u+A* +v;d[3]=l*t+p*u+B*v;d[4]=b*w+n*x+r*y;d[5]=f*w+o*x+s*y;d[6]=k*w+m*x+A*y;d[7]=l*w+p*x+B*y;d[8]=b*z+n*e+r*g;d[9]=f*z+o*e+s*g;d[10]=k*z+m*e+A*g;d[11]=l*z+p*e+B*g;return d};mat4.rotateX=function(a,b,c){var d=Math.sin(b),b=Math.cos(b),e=a[4],g=a[5],f=a[6],h=a[7],i=a[8],j=a[9],k=a[10],l=a[11];c?a!==c&&(c[0]=a[0],c[1]=a[1],c[2]=a[2],c[3]=a[3],c[12]=a[12],c[13]=a[13],c[14]=a[14],c[15]=a[15]):c=a;c[4]=e*b+i*d;c[5]=g*b+j*d;c[6]=f*b+k*d;c[7]=h*b+l*d;c[8]=e*-d+i*b;c[9]=g*-d+j*b;c[10]=f*-d+k*b;c[11]=h*-d+l*b;return c}; +mat4.rotateY=function(a,b,c){var d=Math.sin(b),b=Math.cos(b),e=a[0],g=a[1],f=a[2],h=a[3],i=a[8],j=a[9],k=a[10],l=a[11];c?a!==c&&(c[4]=a[4],c[5]=a[5],c[6]=a[6],c[7]=a[7],c[12]=a[12],c[13]=a[13],c[14]=a[14],c[15]=a[15]):c=a;c[0]=e*b+i*-d;c[1]=g*b+j*-d;c[2]=f*b+k*-d;c[3]=h*b+l*-d;c[8]=e*d+i*b;c[9]=g*d+j*b;c[10]=f*d+k*b;c[11]=h*d+l*b;return c}; +mat4.rotateZ=function(a,b,c){var d=Math.sin(b),b=Math.cos(b),e=a[0],g=a[1],f=a[2],h=a[3],i=a[4],j=a[5],k=a[6],l=a[7];c?a!==c&&(c[8]=a[8],c[9]=a[9],c[10]=a[10],c[11]=a[11],c[12]=a[12],c[13]=a[13],c[14]=a[14],c[15]=a[15]):c=a;c[0]=e*b+i*d;c[1]=g*b+j*d;c[2]=f*b+k*d;c[3]=h*b+l*d;c[4]=e*-d+i*b;c[5]=g*-d+j*b;c[6]=f*-d+k*b;c[7]=h*-d+l*b;return c}; +mat4.frustum=function(a,b,c,d,e,g,f){f||(f=mat4.create());var h=b-a,i=d-c,j=g-e;f[0]=e*2/h;f[1]=0;f[2]=0;f[3]=0;f[4]=0;f[5]=e*2/i;f[6]=0;f[7]=0;f[8]=(b+a)/h;f[9]=(d+c)/i;f[10]=-(g+e)/j;f[11]=-1;f[12]=0;f[13]=0;f[14]=-(g*e*2)/j;f[15]=0;return f};mat4.perspective=function(a,b,c,d,e){a=c*Math.tan(a*Math.PI/360);b*=a;return mat4.frustum(-b,b,-a,a,c,d,e)}; +mat4.ortho=function(a,b,c,d,e,g,f){f||(f=mat4.create());var h=b-a,i=d-c,j=g-e;f[0]=2/h;f[1]=0;f[2]=0;f[3]=0;f[4]=0;f[5]=2/i;f[6]=0;f[7]=0;f[8]=0;f[9]=0;f[10]=-2/j;f[11]=0;f[12]=-(a+b)/h;f[13]=-(d+c)/i;f[14]=-(g+e)/j;f[15]=1;return f}; +mat4.lookAt=function(a,b,c,d){d||(d=mat4.create());var e,g,f,h,i,j,k,l,n=a[0],o=a[1],a=a[2];g=c[0];f=c[1];e=c[2];c=b[1];j=b[2];if(n===b[0]&&o===c&&a===j)return mat4.identity(d);c=n-b[0];j=o-b[1];k=a-b[2];l=1/Math.sqrt(c*c+j*j+k*k);c*=l;j*=l;k*=l;b=f*k-e*j;e=e*c-g*k;g=g*j-f*c;(l=Math.sqrt(b*b+e*e+g*g))?(l=1/l,b*=l,e*=l,g*=l):g=e=b=0;f=j*g-k*e;h=k*b-c*g;i=c*e-j*b;(l=Math.sqrt(f*f+h*h+i*i))?(l=1/l,f*=l,h*=l,i*=l):i=h=f=0;d[0]=b;d[1]=f;d[2]=c;d[3]=0;d[4]=e;d[5]=h;d[6]=j;d[7]=0;d[8]=g;d[9]=i;d[10]=k;d[11]= +0;d[12]=-(b*n+e*o+g*a);d[13]=-(f*n+h*o+i*a);d[14]=-(c*n+j*o+k*a);d[15]=1;return d};mat4.fromRotationTranslation=function(a,b,c){c||(c=mat4.create());var d=a[0],e=a[1],g=a[2],f=a[3],h=d+d,i=e+e,j=g+g,a=d*h,k=d*i;d*=j;var l=e*i;e*=j;g*=j;h*=f;i*=f;f*=j;c[0]=1-(l+g);c[1]=k+f;c[2]=d-i;c[3]=0;c[4]=k-f;c[5]=1-(a+g);c[6]=e+h;c[7]=0;c[8]=d+i;c[9]=e-h;c[10]=1-(a+l);c[11]=0;c[12]=b[0];c[13]=b[1];c[14]=b[2];c[15]=1;return c}; +mat4.str=function(a){return"["+a[0]+", "+a[1]+", "+a[2]+", "+a[3]+", "+a[4]+", "+a[5]+", "+a[6]+", "+a[7]+", "+a[8]+", "+a[9]+", "+a[10]+", "+a[11]+", "+a[12]+", "+a[13]+", "+a[14]+", "+a[15]+"]"};quat4.create=function(a){var b=new MatrixArray(4);a&&(b[0]=a[0],b[1]=a[1],b[2]=a[2],b[3]=a[3]);return b};quat4.set=function(a,b){b[0]=a[0];b[1]=a[1];b[2]=a[2];b[3]=a[3];return b}; +quat4.calculateW=function(a,b){var c=a[0],d=a[1],e=a[2];if(!b||a===b)return a[3]=-Math.sqrt(Math.abs(1-c*c-d*d-e*e)),a;b[0]=c;b[1]=d;b[2]=e;b[3]=-Math.sqrt(Math.abs(1-c*c-d*d-e*e));return b};quat4.inverse=function(a,b){if(!b||a===b)return a[0]*=-1,a[1]*=-1,a[2]*=-1,a;b[0]=-a[0];b[1]=-a[1];b[2]=-a[2];b[3]=a[3];return b};quat4.length=function(a){var b=a[0],c=a[1],d=a[2],a=a[3];return Math.sqrt(b*b+c*c+d*d+a*a)}; +quat4.normalize=function(a,b){b||(b=a);var c=a[0],d=a[1],e=a[2],g=a[3],f=Math.sqrt(c*c+d*d+e*e+g*g);if(f===0)return b[0]=0,b[1]=0,b[2]=0,b[3]=0,b;f=1/f;b[0]=c*f;b[1]=d*f;b[2]=e*f;b[3]=g*f;return b};quat4.multiply=function(a,b,c){c||(c=a);var d=a[0],e=a[1],g=a[2],a=a[3],f=b[0],h=b[1],i=b[2],b=b[3];c[0]=d*b+a*f+e*i-g*h;c[1]=e*b+a*h+g*f-d*i;c[2]=g*b+a*i+d*h-e*f;c[3]=a*b-d*f-e*h-g*i;return c}; +quat4.multiplyVec3=function(a,b,c){c||(c=b);var d=b[0],e=b[1],g=b[2],b=a[0],f=a[1],h=a[2],a=a[3],i=a*d+f*g-h*e,j=a*e+h*d-b*g,k=a*g+b*e-f*d,d=-b*d-f*e-h*g;c[0]=i*a+d*-b+j*-h-k*-f;c[1]=j*a+d*-f+k*-b-i*-h;c[2]=k*a+d*-h+i*-f-j*-b;return c};quat4.toMat3=function(a,b){b||(b=mat3.create());var c=a[0],d=a[1],e=a[2],g=a[3],f=c+c,h=d+d,i=e+e,j=c*f,k=c*h;c*=i;var l=d*h;d*=i;e*=i;f*=g;h*=g;g*=i;b[0]=1-(l+e);b[1]=k+g;b[2]=c-h;b[3]=k-g;b[4]=1-(j+e);b[5]=d+f;b[6]=c+h;b[7]=d-f;b[8]=1-(j+l);return b}; +quat4.toMat4=function(a,b){b||(b=mat4.create());var c=a[0],d=a[1],e=a[2],g=a[3],f=c+c,h=d+d,i=e+e,j=c*f,k=c*h;c*=i;var l=d*h;d*=i;e*=i;f*=g;h*=g;g*=i;b[0]=1-(l+e);b[1]=k+g;b[2]=c-h;b[3]=0;b[4]=k-g;b[5]=1-(j+e);b[6]=d+f;b[7]=0;b[8]=c+h;b[9]=d-f;b[10]=1-(j+l);b[11]=0;b[12]=0;b[13]=0;b[14]=0;b[15]=1;return b}; +quat4.slerp=function(a,b,c,d){d||(d=a);var e=a[0]*b[0]+a[1]*b[1]+a[2]*b[2]+a[3]*b[3],g,f;if(Math.abs(e)>=1)return d!==a&&(d[0]=a[0],d[1]=a[1],d[2]=a[2],d[3]=a[3]),d;g=Math.acos(e);f=Math.sqrt(1-e*e);if(Math.abs(f)<0.001)return d[0]=a[0]*0.5+b[0]*0.5,d[1]=a[1]*0.5+b[1]*0.5,d[2]=a[2]*0.5+b[2]*0.5,d[3]=a[3]*0.5+b[3]*0.5,d;e=Math.sin((1-c)*g)/f;c=Math.sin(c*g)/f;d[0]=a[0]*e+b[0]*c;d[1]=a[1]*e+b[1]*c;d[2]=a[2]*e+b[2]*c;d[3]=a[3]*e+b[3]*c;return d}; +quat4.str=function(a){return"["+a[0]+", "+a[1]+", "+a[2]+", "+a[3]+"]"}; +(function() +{ + var MAX_VERTICES = 8000; // equates to 2500 objects being drawn + var MAX_INDICES = (MAX_VERTICES / 2) * 3; // 6 indices for every 4 vertices + var MAX_POINTS = 8000; + var MULTI_BUFFERS = 4; // cycle 4 buffers to try and avoid blocking + var BATCH_NULL = 0; + var BATCH_QUAD = 1; + var BATCH_SETTEXTURE = 2; + var BATCH_SETOPACITY = 3; + var BATCH_SETBLEND = 4; + var BATCH_UPDATEMODELVIEW = 5; + var BATCH_RENDERTOTEXTURE = 6; + var BATCH_CLEAR = 7; + var BATCH_POINTS = 8; + var BATCH_SETPROGRAM = 9; + var BATCH_SETPROGRAMPARAMETERS = 10; + var BATCH_SETTEXTURE1 = 11; + var BATCH_SETCOLOR = 12; + var BATCH_SETDEPTHTEST = 13; + var BATCH_SETEARLYZMODE = 14; + /* + var lose_ext = null; + window.lose_context = function () + { + if (!lose_ext) + { + console.log("WEBGL_lose_context not supported"); + return; + } + lose_ext.loseContext(); + }; + window.restore_context = function () + { + if (!lose_ext) + { + console.log("WEBGL_lose_context not supported"); + return; + } + lose_ext.restoreContext(); + }; + */ + var tempMat4 = mat4.create(); + function GLWrap_(gl, isMobile, enableFrontToBack) + { + this.isIE = /msie/i.test(navigator.userAgent) || /trident/i.test(navigator.userAgent); + this.width = 0; // not yet known, wait for call to setSize() + this.height = 0; + this.enableFrontToBack = !!enableFrontToBack; + this.isEarlyZPass = false; + this.isBatchInEarlyZPass = false; + this.currentZ = 0; + this.zNear = 1; + this.zFar = 1000; + this.zIncrement = ((this.zFar - this.zNear) / 32768); + this.zA = this.zFar / (this.zFar - this.zNear); + this.zB = this.zFar * this.zNear / (this.zNear - this.zFar); + this.kzA = 65536 * this.zA; + this.kzB = 65536 * this.zB; + this.cam = vec3.create([0, 0, 100]); // camera position + this.look = vec3.create([0, 0, 0]); // lookat position + this.up = vec3.create([0, 1, 0]); // up vector + this.worldScale = vec3.create([1, 1, 1]); // world scaling factor + this.enable_mipmaps = true; + this.matP = mat4.create(); // perspective matrix + this.matMV = mat4.create(); // model view matrix + this.lastMV = mat4.create(); + this.currentMV = mat4.create(); + this.gl = gl; + this.version = (this.gl.getParameter(this.gl.VERSION).indexOf("WebGL 2") === 0 ? 2 : 1); + this.initState(); + }; + GLWrap_.prototype.initState = function () + { + var gl = this.gl; + var i, len; + this.lastOpacity = 1; + this.lastTexture0 = null; // last bound to TEXTURE0 + this.lastTexture1 = null; // last bound to TEXTURE1 + this.currentOpacity = 1; + gl.clearColor(0, 0, 0, 0); + gl.clear(gl.COLOR_BUFFER_BIT); + gl.enable(gl.BLEND); + gl.blendFunc(gl.ONE, gl.ONE_MINUS_SRC_ALPHA); + gl.disable(gl.CULL_FACE); + gl.disable(gl.STENCIL_TEST); + gl.disable(gl.DITHER); + if (this.enableFrontToBack) + { + gl.enable(gl.DEPTH_TEST); + gl.depthFunc(gl.LEQUAL); + } + else + { + gl.disable(gl.DEPTH_TEST); + } + this.maxTextureSize = gl.getParameter(gl.MAX_TEXTURE_SIZE); + this.lastSrcBlend = gl.ONE; + this.lastDestBlend = gl.ONE_MINUS_SRC_ALPHA; + this.vertexData = new Float32Array(MAX_VERTICES * (this.enableFrontToBack ? 3 : 2)); + this.texcoordData = new Float32Array(MAX_VERTICES * 2); + this.pointData = new Float32Array(MAX_POINTS * 4); + this.pointBuffer = gl.createBuffer(); + gl.bindBuffer(gl.ARRAY_BUFFER, this.pointBuffer); + gl.bufferData(gl.ARRAY_BUFFER, this.pointData.byteLength, gl.DYNAMIC_DRAW); + this.vertexBuffers = new Array(MULTI_BUFFERS); + this.texcoordBuffers = new Array(MULTI_BUFFERS); + for (i = 0; i < MULTI_BUFFERS; i++) + { + this.vertexBuffers[i] = gl.createBuffer(); + gl.bindBuffer(gl.ARRAY_BUFFER, this.vertexBuffers[i]); + gl.bufferData(gl.ARRAY_BUFFER, this.vertexData.byteLength, gl.DYNAMIC_DRAW); + this.texcoordBuffers[i] = gl.createBuffer(); + gl.bindBuffer(gl.ARRAY_BUFFER, this.texcoordBuffers[i]); + gl.bufferData(gl.ARRAY_BUFFER, this.texcoordData.byteLength, gl.DYNAMIC_DRAW); + } + this.curBuffer = 0; + this.indexBuffer = gl.createBuffer(); + gl.bindBuffer(gl.ELEMENT_ARRAY_BUFFER, this.indexBuffer); + var indexData = new Uint16Array(MAX_INDICES); + i = 0, len = MAX_INDICES; + var fv = 0; + while (i < len) + { + indexData[i++] = fv; // top left + indexData[i++] = fv + 1; // top right + indexData[i++] = fv + 2; // bottom right (first tri) + indexData[i++] = fv; // top left + indexData[i++] = fv + 2; // bottom right + indexData[i++] = fv + 3; // bottom left + fv += 4; + } + gl.bufferData(gl.ELEMENT_ARRAY_BUFFER, indexData, gl.STATIC_DRAW); + this.vertexPtr = 0; + this.texPtr = 0; + this.pointPtr = 0; + var fsSource, vsSource; + this.shaderPrograms = []; + fsSource = [ + "varying mediump vec2 vTex;", + "uniform lowp float opacity;", + "uniform lowp sampler2D samplerFront;", + "void main(void) {", + " gl_FragColor = texture2D(samplerFront, vTex);", + " gl_FragColor *= opacity;", + "}" + ].join("\n"); + if (this.enableFrontToBack) + { + vsSource = [ + "attribute highp vec3 aPos;", + "attribute mediump vec2 aTex;", + "varying mediump vec2 vTex;", + "uniform highp mat4 matP;", + "uniform highp mat4 matMV;", + "void main(void) {", + " gl_Position = matP * matMV * vec4(aPos.x, aPos.y, aPos.z, 1.0);", + " vTex = aTex;", + "}" + ].join("\n"); + } + else + { + vsSource = [ + "attribute highp vec2 aPos;", + "attribute mediump vec2 aTex;", + "varying mediump vec2 vTex;", + "uniform highp mat4 matP;", + "uniform highp mat4 matMV;", + "void main(void) {", + " gl_Position = matP * matMV * vec4(aPos.x, aPos.y, 0.0, 1.0);", + " vTex = aTex;", + "}" + ].join("\n"); + } + var shaderProg = this.createShaderProgram({src: fsSource}, vsSource, ""); +; + this.shaderPrograms.push(shaderProg); // Default shader is always shader 0 + fsSource = [ + "uniform mediump sampler2D samplerFront;", + "varying lowp float opacity;", + "void main(void) {", + " gl_FragColor = texture2D(samplerFront, gl_PointCoord);", + " gl_FragColor *= opacity;", + "}" + ].join("\n"); + var pointVsSource = [ + "attribute vec4 aPos;", + "varying float opacity;", + "uniform mat4 matP;", + "uniform mat4 matMV;", + "void main(void) {", + " gl_Position = matP * matMV * vec4(aPos.x, aPos.y, 0.0, 1.0);", + " gl_PointSize = aPos.z;", + " opacity = aPos.w;", + "}" + ].join("\n"); + shaderProg = this.createShaderProgram({src: fsSource}, pointVsSource, ""); +; + this.shaderPrograms.push(shaderProg); // Point shader is always shader 1 + fsSource = [ + "varying mediump vec2 vTex;", + "uniform lowp sampler2D samplerFront;", + "void main(void) {", + " if (texture2D(samplerFront, vTex).a < 1.0)", + " discard;", // discarding non-opaque fragments + "}" + ].join("\n"); + var shaderProg = this.createShaderProgram({src: fsSource}, vsSource, ""); +; + this.shaderPrograms.push(shaderProg); // Early-Z shader is always shader 2 + fsSource = [ + "uniform lowp vec4 colorFill;", + "void main(void) {", + " gl_FragColor = colorFill;", + "}" + ].join("\n"); + var shaderProg = this.createShaderProgram({src: fsSource}, vsSource, ""); +; + this.shaderPrograms.push(shaderProg); // Fill-color shader is always shader 3 + for (var shader_name in cr.shaders) + { + if (cr.shaders.hasOwnProperty(shader_name)) + this.shaderPrograms.push(this.createShaderProgram(cr.shaders[shader_name], vsSource, shader_name)); + } + gl.activeTexture(gl.TEXTURE0); + gl.bindTexture(gl.TEXTURE_2D, null); + this.batch = []; + this.batchPtr = 0; + this.hasQuadBatchTop = false; + this.hasPointBatchTop = false; + this.lastProgram = -1; // start -1 so first switchProgram can do work + this.currentProgram = -1; // current program during batch execution + this.currentShader = null; + this.fbo = gl.createFramebuffer(); + this.renderToTex = null; + this.depthBuffer = null; + this.attachedDepthBuffer = false; // wait until first size call to attach, otherwise it has no storage + if (this.enableFrontToBack) + { + this.depthBuffer = gl.createRenderbuffer(); + } + this.tmpVec3 = vec3.create([0, 0, 0]); +; + var pointsizes = gl.getParameter(gl.ALIASED_POINT_SIZE_RANGE); + this.minPointSize = pointsizes[0]; + this.maxPointSize = pointsizes[1]; + if (this.maxPointSize > 2048) + this.maxPointSize = 2048; +; + this.switchProgram(0); + cr.seal(this); + }; + function GLShaderProgram(gl, shaderProgram, name) + { + this.gl = gl; + this.shaderProgram = shaderProgram; + this.name = name; + this.locAPos = gl.getAttribLocation(shaderProgram, "aPos"); + this.locATex = gl.getAttribLocation(shaderProgram, "aTex"); + this.locMatP = gl.getUniformLocation(shaderProgram, "matP"); + this.locMatMV = gl.getUniformLocation(shaderProgram, "matMV"); + this.locOpacity = gl.getUniformLocation(shaderProgram, "opacity"); + this.locColorFill = gl.getUniformLocation(shaderProgram, "colorFill"); + this.locSamplerFront = gl.getUniformLocation(shaderProgram, "samplerFront"); + this.locSamplerBack = gl.getUniformLocation(shaderProgram, "samplerBack"); + this.locDestStart = gl.getUniformLocation(shaderProgram, "destStart"); + this.locDestEnd = gl.getUniformLocation(shaderProgram, "destEnd"); + this.locSeconds = gl.getUniformLocation(shaderProgram, "seconds"); + this.locPixelWidth = gl.getUniformLocation(shaderProgram, "pixelWidth"); + this.locPixelHeight = gl.getUniformLocation(shaderProgram, "pixelHeight"); + this.locLayerScale = gl.getUniformLocation(shaderProgram, "layerScale"); + this.locLayerAngle = gl.getUniformLocation(shaderProgram, "layerAngle"); + this.locViewOrigin = gl.getUniformLocation(shaderProgram, "viewOrigin"); + this.locScrollPos = gl.getUniformLocation(shaderProgram, "scrollPos"); + this.hasAnyOptionalUniforms = !!(this.locPixelWidth || this.locPixelHeight || this.locSeconds || this.locSamplerBack || this.locDestStart || this.locDestEnd || this.locLayerScale || this.locLayerAngle || this.locViewOrigin || this.locScrollPos); + this.lpPixelWidth = -999; // set to something unlikely so never counts as cached on first set + this.lpPixelHeight = -999; + this.lpOpacity = 1; + this.lpDestStartX = 0.0; + this.lpDestStartY = 0.0; + this.lpDestEndX = 1.0; + this.lpDestEndY = 1.0; + this.lpLayerScale = 1.0; + this.lpLayerAngle = 0.0; + this.lpViewOriginX = 0.0; + this.lpViewOriginY = 0.0; + this.lpScrollPosX = 0.0; + this.lpScrollPosY = 0.0; + this.lpSeconds = 0.0; + this.lastCustomParams = []; + this.lpMatMV = mat4.create(); + if (this.locOpacity) + gl.uniform1f(this.locOpacity, 1); + if (this.locColorFill) + gl.uniform4f(this.locColorFill, 1.0, 1.0, 1.0, 1.0); + if (this.locSamplerFront) + gl.uniform1i(this.locSamplerFront, 0); + if (this.locSamplerBack) + gl.uniform1i(this.locSamplerBack, 1); + if (this.locDestStart) + gl.uniform2f(this.locDestStart, 0.0, 0.0); + if (this.locDestEnd) + gl.uniform2f(this.locDestEnd, 1.0, 1.0); + if (this.locLayerScale) + gl.uniform1f(this.locLayerScale, 1.0); + if (this.locLayerAngle) + gl.uniform1f(this.locLayerAngle, 0.0); + if (this.locViewOrigin) + gl.uniform2f(this.locViewOrigin, 0.0, 0.0); + if (this.locScrollPos) + gl.uniform2f(this.locScrollPos, 0.0, 0.0); + if (this.locSeconds) + gl.uniform1f(this.locSeconds, 0.0); + this.hasCurrentMatMV = false; // matMV needs updating + }; + function areMat4sEqual(a, b) + { + return a[0]===b[0]&&a[1]===b[1]&&a[2]===b[2]&&a[3]===b[3]&& + a[4]===b[4]&&a[5]===b[5]&&a[6]===b[6]&&a[7]===b[7]&& + a[8]===b[8]&&a[9]===b[9]&&a[10]===b[10]&&a[11]===b[11]&& + a[12]===b[12]&&a[13]===b[13]&&a[14]===b[14]&&a[15]===b[15]; + }; + GLShaderProgram.prototype.updateMatMV = function (mv) + { + if (areMat4sEqual(this.lpMatMV, mv)) + return; // no change, save the expensive GL call + mat4.set(mv, this.lpMatMV); + this.gl.uniformMatrix4fv(this.locMatMV, false, mv); + }; + GLWrap_.prototype.createShaderProgram = function(shaderEntry, vsSource, name) + { + var gl = this.gl; + var fragmentShader = gl.createShader(gl.FRAGMENT_SHADER); + gl.shaderSource(fragmentShader, shaderEntry.src); + gl.compileShader(fragmentShader); + if (!gl.getShaderParameter(fragmentShader, gl.COMPILE_STATUS)) + { + var compilationlog = gl.getShaderInfoLog(fragmentShader); + gl.deleteShader(fragmentShader); + throw new Error("error compiling fragment shader: " + compilationlog); + } + var vertexShader = gl.createShader(gl.VERTEX_SHADER); + gl.shaderSource(vertexShader, vsSource); + gl.compileShader(vertexShader); + if (!gl.getShaderParameter(vertexShader, gl.COMPILE_STATUS)) + { + var compilationlog = gl.getShaderInfoLog(vertexShader); + gl.deleteShader(fragmentShader); + gl.deleteShader(vertexShader); + throw new Error("error compiling vertex shader: " + compilationlog); + } + var shaderProgram = gl.createProgram(); + gl.attachShader(shaderProgram, fragmentShader); + gl.attachShader(shaderProgram, vertexShader); + gl.linkProgram(shaderProgram); + if (!gl.getProgramParameter(shaderProgram, gl.LINK_STATUS)) + { + var compilationlog = gl.getProgramInfoLog(shaderProgram); + gl.deleteShader(fragmentShader); + gl.deleteShader(vertexShader); + gl.deleteProgram(shaderProgram); + throw new Error("error linking shader program: " + compilationlog); + } + gl.useProgram(shaderProgram); + gl.deleteShader(fragmentShader); + gl.deleteShader(vertexShader); + var ret = new GLShaderProgram(gl, shaderProgram, name); + ret.extendBoxHorizontal = shaderEntry.extendBoxHorizontal || 0; + ret.extendBoxVertical = shaderEntry.extendBoxVertical || 0; + ret.crossSampling = !!shaderEntry.crossSampling; + ret.preservesOpaqueness = !!shaderEntry.preservesOpaqueness; + ret.animated = !!shaderEntry.animated; + ret.parameters = shaderEntry.parameters || []; + var i, len; + for (i = 0, len = ret.parameters.length; i < len; i++) + { + ret.parameters[i][1] = gl.getUniformLocation(shaderProgram, ret.parameters[i][0]); + ret.lastCustomParams.push(0); + gl.uniform1f(ret.parameters[i][1], 0); + } + cr.seal(ret); + return ret; + }; + GLWrap_.prototype.getShaderIndex = function(name_) + { + var i, len; + for (i = 0, len = this.shaderPrograms.length; i < len; i++) + { + if (this.shaderPrograms[i].name === name_) + return i; + } + return -1; + }; + GLWrap_.prototype.project = function (x, y, out) + { + var mv = this.matMV; + var proj = this.matP; + var fTempo = [0, 0, 0, 0, 0, 0, 0, 0]; + fTempo[0] = mv[0]*x+mv[4]*y+mv[12]; + fTempo[1] = mv[1]*x+mv[5]*y+mv[13]; + fTempo[2] = mv[2]*x+mv[6]*y+mv[14]; + fTempo[3] = mv[3]*x+mv[7]*y+mv[15]; + fTempo[4] = proj[0]*fTempo[0]+proj[4]*fTempo[1]+proj[8]*fTempo[2]+proj[12]*fTempo[3]; + fTempo[5] = proj[1]*fTempo[0]+proj[5]*fTempo[1]+proj[9]*fTempo[2]+proj[13]*fTempo[3]; + fTempo[6] = proj[2]*fTempo[0]+proj[6]*fTempo[1]+proj[10]*fTempo[2]+proj[14]*fTempo[3]; + fTempo[7] = -fTempo[2]; + if(fTempo[7]===0.0) //The w value + return; + fTempo[7]=1.0/fTempo[7]; + fTempo[4]*=fTempo[7]; + fTempo[5]*=fTempo[7]; + fTempo[6]*=fTempo[7]; + out[0]=(fTempo[4]*0.5+0.5)*this.width; + out[1]=(fTempo[5]*0.5+0.5)*this.height; + }; + GLWrap_.prototype.setSize = function(w, h, force) + { + if (this.width === w && this.height === h && !force) + return; + this.endBatch(); + var gl = this.gl; + this.width = w; + this.height = h; + gl.viewport(0, 0, w, h); + mat4.lookAt(this.cam, this.look, this.up, this.matMV); + if (this.enableFrontToBack) + { + mat4.ortho(-w/2, w/2, h/2, -h/2, this.zNear, this.zFar, this.matP); + this.worldScale[0] = 1; + this.worldScale[1] = 1; + } + else + { + mat4.perspective(45, w / h, this.zNear, this.zFar, this.matP); + var tl = [0, 0]; + var br = [0, 0]; + this.project(0, 0, tl); + this.project(1, 1, br); + this.worldScale[0] = 1 / (br[0] - tl[0]); + this.worldScale[1] = -1 / (br[1] - tl[1]); + } + var i, len, s; + for (i = 0, len = this.shaderPrograms.length; i < len; i++) + { + s = this.shaderPrograms[i]; + s.hasCurrentMatMV = false; + if (s.locMatP) + { + gl.useProgram(s.shaderProgram); + gl.uniformMatrix4fv(s.locMatP, false, this.matP); + } + } + gl.useProgram(this.shaderPrograms[this.lastProgram].shaderProgram); + gl.bindTexture(gl.TEXTURE_2D, null); + gl.activeTexture(gl.TEXTURE1); + gl.bindTexture(gl.TEXTURE_2D, null); + gl.activeTexture(gl.TEXTURE0); + this.lastTexture0 = null; + this.lastTexture1 = null; + if (this.depthBuffer) + { + gl.bindFramebuffer(gl.FRAMEBUFFER, this.fbo); + gl.bindRenderbuffer(gl.RENDERBUFFER, this.depthBuffer); + gl.renderbufferStorage(gl.RENDERBUFFER, gl.DEPTH_COMPONENT16, this.width, this.height); + if (!this.attachedDepthBuffer) + { + gl.framebufferRenderbuffer(gl.FRAMEBUFFER, gl.DEPTH_ATTACHMENT, gl.RENDERBUFFER, this.depthBuffer); + this.attachedDepthBuffer = true; + } + gl.bindRenderbuffer(gl.RENDERBUFFER, null); + gl.bindFramebuffer(gl.FRAMEBUFFER, null); + this.renderToTex = null; + } + }; + GLWrap_.prototype.resetModelView = function () + { + mat4.lookAt(this.cam, this.look, this.up, this.matMV); + mat4.scale(this.matMV, this.worldScale); + }; + GLWrap_.prototype.translate = function (x, y) + { + if (x === 0 && y === 0) + return; + this.tmpVec3[0] = x;// * this.worldScale[0]; + this.tmpVec3[1] = y;// * this.worldScale[1]; + this.tmpVec3[2] = 0; + mat4.translate(this.matMV, this.tmpVec3); + }; + GLWrap_.prototype.scale = function (x, y) + { + if (x === 1 && y === 1) + return; + this.tmpVec3[0] = x; + this.tmpVec3[1] = y; + this.tmpVec3[2] = 1; + mat4.scale(this.matMV, this.tmpVec3); + }; + GLWrap_.prototype.rotateZ = function (a) + { + if (a === 0) + return; + mat4.rotateZ(this.matMV, a); + }; + GLWrap_.prototype.updateModelView = function() + { + if (areMat4sEqual(this.lastMV, this.matMV)) + return; + var b = this.pushBatch(); + b.type = BATCH_UPDATEMODELVIEW; + if (b.mat4param) + mat4.set(this.matMV, b.mat4param); + else + b.mat4param = mat4.create(this.matMV); + mat4.set(this.matMV, this.lastMV); + this.hasQuadBatchTop = false; + this.hasPointBatchTop = false; + }; + /* + var debugBatch = false; + jQuery(document).mousedown( + function(info) { + if (info.which === 2) + debugBatch = true; + } + ); + */ + GLWrap_.prototype.setEarlyZIndex = function (i) + { + if (!this.enableFrontToBack) + return; + if (i > 32760) + i = 32760; + this.currentZ = this.cam[2] - this.zNear - i * this.zIncrement; + }; + function GLBatchJob(type_, glwrap_) + { + this.type = type_; + this.glwrap = glwrap_; + this.gl = glwrap_.gl; + this.opacityParam = 0; // for setOpacity() + this.startIndex = 0; // for quad() + this.indexCount = 0; // " + this.texParam = null; // for setTexture() + this.mat4param = null; // for updateModelView() + this.shaderParams = []; // for user parameters + cr.seal(this); + }; + GLBatchJob.prototype.doSetEarlyZPass = function () + { + var gl = this.gl; + var glwrap = this.glwrap; + if (this.startIndex !== 0) // enable + { + gl.depthMask(true); // enable depth writes + gl.colorMask(false, false, false, false); // disable color writes + gl.disable(gl.BLEND); // no color writes so disable blend + gl.bindFramebuffer(gl.FRAMEBUFFER, glwrap.fbo); + gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.TEXTURE_2D, null, 0); + gl.clear(gl.DEPTH_BUFFER_BIT); // auto-clear depth buffer + gl.bindFramebuffer(gl.FRAMEBUFFER, null); + glwrap.isBatchInEarlyZPass = true; + } + else + { + gl.depthMask(false); // disable depth writes, only test existing depth values + gl.colorMask(true, true, true, true); // enable color writes + gl.enable(gl.BLEND); // turn blending back on + glwrap.isBatchInEarlyZPass = false; + } + }; + GLBatchJob.prototype.doSetTexture = function () + { + this.gl.bindTexture(this.gl.TEXTURE_2D, this.texParam); + }; + GLBatchJob.prototype.doSetTexture1 = function () + { + var gl = this.gl; + gl.activeTexture(gl.TEXTURE1); + gl.bindTexture(gl.TEXTURE_2D, this.texParam); + gl.activeTexture(gl.TEXTURE0); + }; + GLBatchJob.prototype.doSetOpacity = function () + { + var o = this.opacityParam; + var glwrap = this.glwrap; + glwrap.currentOpacity = o; + var curProg = glwrap.currentShader; + if (curProg.locOpacity && curProg.lpOpacity !== o) + { + curProg.lpOpacity = o; + this.gl.uniform1f(curProg.locOpacity, o); + } + }; + GLBatchJob.prototype.doQuad = function () + { + this.gl.drawElements(this.gl.TRIANGLES, this.indexCount, this.gl.UNSIGNED_SHORT, this.startIndex); + }; + GLBatchJob.prototype.doSetBlend = function () + { + this.gl.blendFunc(this.startIndex, this.indexCount); + }; + GLBatchJob.prototype.doUpdateModelView = function () + { + var i, len, s, shaderPrograms = this.glwrap.shaderPrograms, currentProgram = this.glwrap.currentProgram; + for (i = 0, len = shaderPrograms.length; i < len; i++) + { + s = shaderPrograms[i]; + if (i === currentProgram && s.locMatMV) + { + s.updateMatMV(this.mat4param); + s.hasCurrentMatMV = true; + } + else + s.hasCurrentMatMV = false; + } + mat4.set(this.mat4param, this.glwrap.currentMV); + }; + GLBatchJob.prototype.doRenderToTexture = function () + { + var gl = this.gl; + var glwrap = this.glwrap; + if (this.texParam) + { + if (glwrap.lastTexture1 === this.texParam) + { + gl.activeTexture(gl.TEXTURE1); + gl.bindTexture(gl.TEXTURE_2D, null); + glwrap.lastTexture1 = null; + gl.activeTexture(gl.TEXTURE0); + } + gl.bindFramebuffer(gl.FRAMEBUFFER, glwrap.fbo); + if (!glwrap.isBatchInEarlyZPass) + { + gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.TEXTURE_2D, this.texParam, 0); + } + } + else + { + if (!glwrap.enableFrontToBack) + { + gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.TEXTURE_2D, null, 0); + } + gl.bindFramebuffer(gl.FRAMEBUFFER, null); + } + }; + GLBatchJob.prototype.doClear = function () + { + var gl = this.gl; + var mode = this.startIndex; + if (mode === 0) // clear whole surface + { + gl.clearColor(this.mat4param[0], this.mat4param[1], this.mat4param[2], this.mat4param[3]); + gl.clear(gl.COLOR_BUFFER_BIT); + } + else if (mode === 1) // clear rectangle + { + gl.enable(gl.SCISSOR_TEST); + gl.scissor(this.mat4param[0], this.mat4param[1], this.mat4param[2], this.mat4param[3]); + gl.clearColor(0, 0, 0, 0); + gl.clear(gl.COLOR_BUFFER_BIT); + gl.disable(gl.SCISSOR_TEST); + } + else // clear depth + { + gl.clear(gl.DEPTH_BUFFER_BIT); + } + }; + GLBatchJob.prototype.doSetDepthTestEnabled = function () + { + var gl = this.gl; + var enable = this.startIndex; + if (enable !== 0) + { + gl.enable(gl.DEPTH_TEST); + } + else + { + gl.disable(gl.DEPTH_TEST); + } + }; + GLBatchJob.prototype.doPoints = function () + { + var gl = this.gl; + var glwrap = this.glwrap; + if (glwrap.enableFrontToBack) + gl.disable(gl.DEPTH_TEST); + var s = glwrap.shaderPrograms[1]; + gl.useProgram(s.shaderProgram); + if (!s.hasCurrentMatMV && s.locMatMV) + { + s.updateMatMV(glwrap.currentMV); + s.hasCurrentMatMV = true; + } + gl.enableVertexAttribArray(s.locAPos); + gl.bindBuffer(gl.ARRAY_BUFFER, glwrap.pointBuffer); + gl.vertexAttribPointer(s.locAPos, 4, gl.FLOAT, false, 0, 0); + gl.drawArrays(gl.POINTS, this.startIndex / 4, this.indexCount); + s = glwrap.currentShader; + gl.useProgram(s.shaderProgram); + if (s.locAPos >= 0) + { + gl.enableVertexAttribArray(s.locAPos); + gl.bindBuffer(gl.ARRAY_BUFFER, glwrap.vertexBuffers[glwrap.curBuffer]); + gl.vertexAttribPointer(s.locAPos, glwrap.enableFrontToBack ? 3 : 2, gl.FLOAT, false, 0, 0); + } + if (s.locATex >= 0) + { + gl.enableVertexAttribArray(s.locATex); + gl.bindBuffer(gl.ARRAY_BUFFER, glwrap.texcoordBuffers[glwrap.curBuffer]); + gl.vertexAttribPointer(s.locATex, 2, gl.FLOAT, false, 0, 0); + } + if (glwrap.enableFrontToBack) + gl.enable(gl.DEPTH_TEST); + }; + GLBatchJob.prototype.doSetProgram = function () + { + var gl = this.gl; + var glwrap = this.glwrap; + var s = glwrap.shaderPrograms[this.startIndex]; // recycled param to save memory + glwrap.currentProgram = this.startIndex; // current batch program + glwrap.currentShader = s; + gl.useProgram(s.shaderProgram); // switch to + if (!s.hasCurrentMatMV && s.locMatMV) + { + s.updateMatMV(glwrap.currentMV); + s.hasCurrentMatMV = true; + } + if (s.locOpacity && s.lpOpacity !== glwrap.currentOpacity) + { + s.lpOpacity = glwrap.currentOpacity; + gl.uniform1f(s.locOpacity, glwrap.currentOpacity); + } + if (s.locAPos >= 0) + { + gl.enableVertexAttribArray(s.locAPos); + gl.bindBuffer(gl.ARRAY_BUFFER, glwrap.vertexBuffers[glwrap.curBuffer]); + gl.vertexAttribPointer(s.locAPos, glwrap.enableFrontToBack ? 3 : 2, gl.FLOAT, false, 0, 0); + } + if (s.locATex >= 0) + { + gl.enableVertexAttribArray(s.locATex); + gl.bindBuffer(gl.ARRAY_BUFFER, glwrap.texcoordBuffers[glwrap.curBuffer]); + gl.vertexAttribPointer(s.locATex, 2, gl.FLOAT, false, 0, 0); + } + } + GLBatchJob.prototype.doSetColor = function () + { + var s = this.glwrap.currentShader; + var mat4param = this.mat4param; + this.gl.uniform4f(s.locColorFill, mat4param[0], mat4param[1], mat4param[2], mat4param[3]); + }; + GLBatchJob.prototype.doSetProgramParameters = function () + { + var i, len, s = this.glwrap.currentShader; + var gl = this.gl; + var mat4param = this.mat4param; + if (s.locSamplerBack && this.glwrap.lastTexture1 !== this.texParam) + { + gl.activeTexture(gl.TEXTURE1); + gl.bindTexture(gl.TEXTURE_2D, this.texParam); + this.glwrap.lastTexture1 = this.texParam; + gl.activeTexture(gl.TEXTURE0); + } + var v = mat4param[0]; + var v2; + if (s.locPixelWidth && v !== s.lpPixelWidth) + { + s.lpPixelWidth = v; + gl.uniform1f(s.locPixelWidth, v); + } + v = mat4param[1]; + if (s.locPixelHeight && v !== s.lpPixelHeight) + { + s.lpPixelHeight = v; + gl.uniform1f(s.locPixelHeight, v); + } + v = mat4param[2]; + v2 = mat4param[3]; + if (s.locDestStart && (v !== s.lpDestStartX || v2 !== s.lpDestStartY)) + { + s.lpDestStartX = v; + s.lpDestStartY = v2; + gl.uniform2f(s.locDestStart, v, v2); + } + v = mat4param[4]; + v2 = mat4param[5]; + if (s.locDestEnd && (v !== s.lpDestEndX || v2 !== s.lpDestEndY)) + { + s.lpDestEndX = v; + s.lpDestEndY = v2; + gl.uniform2f(s.locDestEnd, v, v2); + } + v = mat4param[6]; + if (s.locLayerScale && v !== s.lpLayerScale) + { + s.lpLayerScale = v; + gl.uniform1f(s.locLayerScale, v); + } + v = mat4param[7]; + if (s.locLayerAngle && v !== s.lpLayerAngle) + { + s.lpLayerAngle = v; + gl.uniform1f(s.locLayerAngle, v); + } + v = mat4param[8]; + v2 = mat4param[9]; + if (s.locViewOrigin && (v !== s.lpViewOriginX || v2 !== s.lpViewOriginY)) + { + s.lpViewOriginX = v; + s.lpViewOriginY = v2; + gl.uniform2f(s.locViewOrigin, v, v2); + } + v = mat4param[10]; + v2 = mat4param[11]; + if (s.locScrollPos && (v !== s.lpScrollPosX || v2 !== s.lpScrollPosY)) + { + s.lpScrollPosX = v; + s.lpScrollPosY = v2; + gl.uniform2f(s.locScrollPos, v, v2); + } + v = mat4param[12]; + if (s.locSeconds && v !== s.lpSeconds) + { + s.lpSeconds = v; + gl.uniform1f(s.locSeconds, v); + } + if (s.parameters.length) + { + for (i = 0, len = s.parameters.length; i < len; i++) + { + v = this.shaderParams[i]; + if (v !== s.lastCustomParams[i]) + { + s.lastCustomParams[i] = v; + gl.uniform1f(s.parameters[i][1], v); + } + } + } + }; + GLWrap_.prototype.pushBatch = function () + { + if (this.batchPtr === this.batch.length) + this.batch.push(new GLBatchJob(BATCH_NULL, this)); + return this.batch[this.batchPtr++]; + }; + GLWrap_.prototype.endBatch = function () + { + if (this.batchPtr === 0) + return; + if (this.gl.isContextLost()) + return; + var gl = this.gl; + if (this.pointPtr > 0) + { + gl.bindBuffer(gl.ARRAY_BUFFER, this.pointBuffer); + gl.bufferSubData(gl.ARRAY_BUFFER, 0, this.pointData.subarray(0, this.pointPtr)); + if (s && s.locAPos >= 0 && s.name === "") + gl.vertexAttribPointer(s.locAPos, 4, gl.FLOAT, false, 0, 0); + } + if (this.vertexPtr > 0) + { + var s = this.currentShader; + gl.bindBuffer(gl.ARRAY_BUFFER, this.vertexBuffers[this.curBuffer]); + gl.bufferSubData(gl.ARRAY_BUFFER, 0, this.vertexData.subarray(0, this.vertexPtr)); + if (s && s.locAPos >= 0 && s.name !== "") + gl.vertexAttribPointer(s.locAPos, this.enableFrontToBack ? 3 : 2, gl.FLOAT, false, 0, 0); + gl.bindBuffer(gl.ARRAY_BUFFER, this.texcoordBuffers[this.curBuffer]); + gl.bufferSubData(gl.ARRAY_BUFFER, 0, this.texcoordData.subarray(0, this.texPtr)); + if (s && s.locATex >= 0 && s.name !== "") + gl.vertexAttribPointer(s.locATex, 2, gl.FLOAT, false, 0, 0); + } + var i, len, b; + for (i = 0, len = this.batchPtr; i < len; i++) + { + b = this.batch[i]; + switch (b.type) { + case 1: + b.doQuad(); + break; + case 2: + b.doSetTexture(); + break; + case 3: + b.doSetOpacity(); + break; + case 4: + b.doSetBlend(); + break; + case 5: + b.doUpdateModelView(); + break; + case 6: + b.doRenderToTexture(); + break; + case 7: + b.doClear(); + break; + case 8: + b.doPoints(); + break; + case 9: + b.doSetProgram(); + break; + case 10: + b.doSetProgramParameters(); + break; + case 11: + b.doSetTexture1(); + break; + case 12: + b.doSetColor(); + break; + case 13: + b.doSetDepthTestEnabled(); + break; + case 14: + b.doSetEarlyZPass(); + break; + } + } + this.batchPtr = 0; + this.vertexPtr = 0; + this.texPtr = 0; + this.pointPtr = 0; + this.hasQuadBatchTop = false; + this.hasPointBatchTop = false; + this.isBatchInEarlyZPass = false; + this.curBuffer++; + if (this.curBuffer >= MULTI_BUFFERS) + this.curBuffer = 0; + }; + GLWrap_.prototype.setOpacity = function (op) + { + if (op === this.lastOpacity) + return; + if (this.isEarlyZPass) + return; // ignore + var b = this.pushBatch(); + b.type = BATCH_SETOPACITY; + b.opacityParam = op; + this.lastOpacity = op; + this.hasQuadBatchTop = false; + this.hasPointBatchTop = false; + }; + GLWrap_.prototype.setTexture = function (tex) + { + if (tex === this.lastTexture0) + return; +; + var b = this.pushBatch(); + b.type = BATCH_SETTEXTURE; + b.texParam = tex; + this.lastTexture0 = tex; + this.hasQuadBatchTop = false; + this.hasPointBatchTop = false; + }; + GLWrap_.prototype.setBlend = function (s, d) + { + if (s === this.lastSrcBlend && d === this.lastDestBlend) + return; + if (this.isEarlyZPass) + return; // ignore + var b = this.pushBatch(); + b.type = BATCH_SETBLEND; + b.startIndex = s; // recycle params to save memory + b.indexCount = d; + this.lastSrcBlend = s; + this.lastDestBlend = d; + this.hasQuadBatchTop = false; + this.hasPointBatchTop = false; + }; + GLWrap_.prototype.isPremultipliedAlphaBlend = function () + { + return (this.lastSrcBlend === this.gl.ONE && this.lastDestBlend === this.gl.ONE_MINUS_SRC_ALPHA); + }; + GLWrap_.prototype.setAlphaBlend = function () + { + this.setBlend(this.gl.ONE, this.gl.ONE_MINUS_SRC_ALPHA); + }; + GLWrap_.prototype.setNoPremultiplyAlphaBlend = function () + { + this.setBlend(this.gl.SRC_ALPHA, this.gl.ONE_MINUS_SRC_ALPHA); + }; + var LAST_VERTEX = MAX_VERTICES * 2 - 8; + GLWrap_.prototype.quad = function(tlx, tly, trx, try_, brx, bry, blx, bly) + { + if (this.vertexPtr >= LAST_VERTEX) + this.endBatch(); + var v = this.vertexPtr; // vertex cursor + var t = this.texPtr; + var vd = this.vertexData; // vertex data array + var td = this.texcoordData; // texture coord data array + var currentZ = this.currentZ; + if (this.hasQuadBatchTop) + { + this.batch[this.batchPtr - 1].indexCount += 6; + } + else + { + var b = this.pushBatch(); + b.type = BATCH_QUAD; + b.startIndex = this.enableFrontToBack ? v : (v / 2) * 3; + b.indexCount = 6; + this.hasQuadBatchTop = true; + this.hasPointBatchTop = false; + } + if (this.enableFrontToBack) + { + vd[v++] = tlx; + vd[v++] = tly; + vd[v++] = currentZ; + vd[v++] = trx; + vd[v++] = try_; + vd[v++] = currentZ; + vd[v++] = brx; + vd[v++] = bry; + vd[v++] = currentZ; + vd[v++] = blx; + vd[v++] = bly; + vd[v++] = currentZ; + } + else + { + vd[v++] = tlx; + vd[v++] = tly; + vd[v++] = trx; + vd[v++] = try_; + vd[v++] = brx; + vd[v++] = bry; + vd[v++] = blx; + vd[v++] = bly; + } + td[t++] = 0; + td[t++] = 0; + td[t++] = 1; + td[t++] = 0; + td[t++] = 1; + td[t++] = 1; + td[t++] = 0; + td[t++] = 1; + this.vertexPtr = v; + this.texPtr = t; + }; + GLWrap_.prototype.quadTex = function(tlx, tly, trx, try_, brx, bry, blx, bly, rcTex) + { + if (this.vertexPtr >= LAST_VERTEX) + this.endBatch(); + var v = this.vertexPtr; // vertex cursor + var t = this.texPtr; + var vd = this.vertexData; // vertex data array + var td = this.texcoordData; // texture coord data array + var currentZ = this.currentZ; + if (this.hasQuadBatchTop) + { + this.batch[this.batchPtr - 1].indexCount += 6; + } + else + { + var b = this.pushBatch(); + b.type = BATCH_QUAD; + b.startIndex = this.enableFrontToBack ? v : (v / 2) * 3; + b.indexCount = 6; + this.hasQuadBatchTop = true; + this.hasPointBatchTop = false; + } + var rc_left = rcTex.left; + var rc_top = rcTex.top; + var rc_right = rcTex.right; + var rc_bottom = rcTex.bottom; + if (this.enableFrontToBack) + { + vd[v++] = tlx; + vd[v++] = tly; + vd[v++] = currentZ; + vd[v++] = trx; + vd[v++] = try_; + vd[v++] = currentZ; + vd[v++] = brx; + vd[v++] = bry; + vd[v++] = currentZ; + vd[v++] = blx; + vd[v++] = bly; + vd[v++] = currentZ; + } + else + { + vd[v++] = tlx; + vd[v++] = tly; + vd[v++] = trx; + vd[v++] = try_; + vd[v++] = brx; + vd[v++] = bry; + vd[v++] = blx; + vd[v++] = bly; + } + td[t++] = rc_left; + td[t++] = rc_top; + td[t++] = rc_right; + td[t++] = rc_top; + td[t++] = rc_right; + td[t++] = rc_bottom; + td[t++] = rc_left; + td[t++] = rc_bottom; + this.vertexPtr = v; + this.texPtr = t; + }; + GLWrap_.prototype.quadTexUV = function(tlx, tly, trx, try_, brx, bry, blx, bly, tlu, tlv, tru, trv, bru, brv, blu, blv) + { + if (this.vertexPtr >= LAST_VERTEX) + this.endBatch(); + var v = this.vertexPtr; // vertex cursor + var t = this.texPtr; + var vd = this.vertexData; // vertex data array + var td = this.texcoordData; // texture coord data array + var currentZ = this.currentZ; + if (this.hasQuadBatchTop) + { + this.batch[this.batchPtr - 1].indexCount += 6; + } + else + { + var b = this.pushBatch(); + b.type = BATCH_QUAD; + b.startIndex = this.enableFrontToBack ? v : (v / 2) * 3; + b.indexCount = 6; + this.hasQuadBatchTop = true; + this.hasPointBatchTop = false; + } + if (this.enableFrontToBack) + { + vd[v++] = tlx; + vd[v++] = tly; + vd[v++] = currentZ; + vd[v++] = trx; + vd[v++] = try_; + vd[v++] = currentZ; + vd[v++] = brx; + vd[v++] = bry; + vd[v++] = currentZ; + vd[v++] = blx; + vd[v++] = bly; + vd[v++] = currentZ; + } + else + { + vd[v++] = tlx; + vd[v++] = tly; + vd[v++] = trx; + vd[v++] = try_; + vd[v++] = brx; + vd[v++] = bry; + vd[v++] = blx; + vd[v++] = bly; + } + td[t++] = tlu; + td[t++] = tlv; + td[t++] = tru; + td[t++] = trv; + td[t++] = bru; + td[t++] = brv; + td[t++] = blu; + td[t++] = blv; + this.vertexPtr = v; + this.texPtr = t; + }; + GLWrap_.prototype.convexPoly = function(pts) + { + var pts_count = pts.length / 2; +; + var tris = pts_count - 2; // 3 points = 1 tri, 4 points = 2 tris, 5 points = 3 tris etc. + var last_tri = tris - 1; + var p0x = pts[0]; + var p0y = pts[1]; + var i, i2, p1x, p1y, p2x, p2y, p3x, p3y; + for (i = 0; i < tris; i += 2) // draw 2 triangles at a time + { + i2 = i * 2; + p1x = pts[i2 + 2]; + p1y = pts[i2 + 3]; + p2x = pts[i2 + 4]; + p2y = pts[i2 + 5]; + if (i === last_tri) + { + this.quad(p0x, p0y, p1x, p1y, p2x, p2y, p2x, p2y); + } + else + { + p3x = pts[i2 + 6]; + p3y = pts[i2 + 7]; + this.quad(p0x, p0y, p1x, p1y, p2x, p2y, p3x, p3y); + } + } + }; + var LAST_POINT = MAX_POINTS - 4; + GLWrap_.prototype.point = function(x_, y_, size_, opacity_) + { + if (this.pointPtr >= LAST_POINT) + this.endBatch(); + var p = this.pointPtr; // point cursor + var pd = this.pointData; // point data array + if (this.hasPointBatchTop) + { + this.batch[this.batchPtr - 1].indexCount++; + } + else + { + var b = this.pushBatch(); + b.type = BATCH_POINTS; + b.startIndex = p; + b.indexCount = 1; + this.hasPointBatchTop = true; + this.hasQuadBatchTop = false; + } + pd[p++] = x_; + pd[p++] = y_; + pd[p++] = size_; + pd[p++] = opacity_; + this.pointPtr = p; + }; + GLWrap_.prototype.switchProgram = function (progIndex) + { + if (this.lastProgram === progIndex) + return; // no change + var shaderProg = this.shaderPrograms[progIndex]; + if (!shaderProg) + { + if (this.lastProgram === 0) + return; // already on default shader + progIndex = 0; + shaderProg = this.shaderPrograms[0]; + } + var b = this.pushBatch(); + b.type = BATCH_SETPROGRAM; + b.startIndex = progIndex; + this.lastProgram = progIndex; + this.hasQuadBatchTop = false; + this.hasPointBatchTop = false; + }; + GLWrap_.prototype.programUsesDest = function (progIndex) + { + var s = this.shaderPrograms[progIndex]; + return !!(s.locDestStart || s.locDestEnd); + }; + GLWrap_.prototype.programUsesCrossSampling = function (progIndex) + { + var s = this.shaderPrograms[progIndex]; + return !!(s.locDestStart || s.locDestEnd || s.crossSampling); + }; + GLWrap_.prototype.programPreservesOpaqueness = function (progIndex) + { + return this.shaderPrograms[progIndex].preservesOpaqueness; + }; + GLWrap_.prototype.programExtendsBox = function (progIndex) + { + var s = this.shaderPrograms[progIndex]; + return s.extendBoxHorizontal !== 0 || s.extendBoxVertical !== 0; + }; + GLWrap_.prototype.getProgramBoxExtendHorizontal = function (progIndex) + { + return this.shaderPrograms[progIndex].extendBoxHorizontal; + }; + GLWrap_.prototype.getProgramBoxExtendVertical = function (progIndex) + { + return this.shaderPrograms[progIndex].extendBoxVertical; + }; + GLWrap_.prototype.getProgramParameterType = function (progIndex, paramIndex) + { + return this.shaderPrograms[progIndex].parameters[paramIndex][2]; + }; + GLWrap_.prototype.programIsAnimated = function (progIndex) + { + return this.shaderPrograms[progIndex].animated; + }; + GLWrap_.prototype.setProgramParameters = function (backTex, pixelWidth, pixelHeight, destStartX, destStartY, destEndX, destEndY, layerScale, layerAngle, viewOriginLeft, viewOriginTop, scrollPosX, scrollPosY, seconds, params) + { + var i, len; + var s = this.shaderPrograms[this.lastProgram]; + var b, mat4param, shaderParams; + if (s.hasAnyOptionalUniforms || params.length) + { + b = this.pushBatch(); + b.type = BATCH_SETPROGRAMPARAMETERS; + if (b.mat4param) + mat4.set(this.matMV, b.mat4param); + else + b.mat4param = mat4.create(); + mat4param = b.mat4param; + mat4param[0] = pixelWidth; + mat4param[1] = pixelHeight; + mat4param[2] = destStartX; + mat4param[3] = destStartY; + mat4param[4] = destEndX; + mat4param[5] = destEndY; + mat4param[6] = layerScale; + mat4param[7] = layerAngle; + mat4param[8] = viewOriginLeft; + mat4param[9] = viewOriginTop; + mat4param[10] = scrollPosX; + mat4param[11] = scrollPosY; + mat4param[12] = seconds; + if (s.locSamplerBack) + { +; + b.texParam = backTex; + } + else + b.texParam = null; + if (params.length) + { + shaderParams = b.shaderParams; + shaderParams.length = params.length; + for (i = 0, len = params.length; i < len; i++) + shaderParams[i] = params[i]; + } + this.hasQuadBatchTop = false; + this.hasPointBatchTop = false; + } + }; + GLWrap_.prototype.clear = function (r, g, b_, a) + { + var b = this.pushBatch(); + b.type = BATCH_CLEAR; + b.startIndex = 0; // clear all mode + if (!b.mat4param) + b.mat4param = mat4.create(); + b.mat4param[0] = r; + b.mat4param[1] = g; + b.mat4param[2] = b_; + b.mat4param[3] = a; + this.hasQuadBatchTop = false; + this.hasPointBatchTop = false; + }; + GLWrap_.prototype.clearRect = function (x, y, w, h) + { + if (w < 0 || h < 0) + return; // invalid clear area + var b = this.pushBatch(); + b.type = BATCH_CLEAR; + b.startIndex = 1; // clear rect mode + if (!b.mat4param) + b.mat4param = mat4.create(); + b.mat4param[0] = x; + b.mat4param[1] = y; + b.mat4param[2] = w; + b.mat4param[3] = h; + this.hasQuadBatchTop = false; + this.hasPointBatchTop = false; + }; + GLWrap_.prototype.clearDepth = function () + { + var b = this.pushBatch(); + b.type = BATCH_CLEAR; + b.startIndex = 2; // clear depth mode + this.hasQuadBatchTop = false; + this.hasPointBatchTop = false; + }; + GLWrap_.prototype.setEarlyZPass = function (e) + { + if (!this.enableFrontToBack) + return; // no depth buffer in use + e = !!e; + if (this.isEarlyZPass === e) + return; // no change + var b = this.pushBatch(); + b.type = BATCH_SETEARLYZMODE; + b.startIndex = (e ? 1 : 0); + this.hasQuadBatchTop = false; + this.hasPointBatchTop = false; + this.isEarlyZPass = e; + this.renderToTex = null; + if (this.isEarlyZPass) + { + this.switchProgram(2); // early Z program + } + else + { + this.switchProgram(0); // normal rendering + } + }; + GLWrap_.prototype.setDepthTestEnabled = function (e) + { + if (!this.enableFrontToBack) + return; // no depth buffer in use + var b = this.pushBatch(); + b.type = BATCH_SETDEPTHTEST; + b.startIndex = (e ? 1 : 0); + this.hasQuadBatchTop = false; + this.hasPointBatchTop = false; + }; + GLWrap_.prototype.fullscreenQuad = function () + { + mat4.set(this.lastMV, tempMat4); + this.resetModelView(); + this.updateModelView(); + var halfw = this.width / 2; + var halfh = this.height / 2; + this.quad(-halfw, halfh, halfw, halfh, halfw, -halfh, -halfw, -halfh); + mat4.set(tempMat4, this.matMV); + this.updateModelView(); + }; + GLWrap_.prototype.setColorFillMode = function (r_, g_, b_, a_) + { + this.switchProgram(3); + var b = this.pushBatch(); + b.type = BATCH_SETCOLOR; + if (!b.mat4param) + b.mat4param = mat4.create(); + b.mat4param[0] = r_; + b.mat4param[1] = g_; + b.mat4param[2] = b_; + b.mat4param[3] = a_; + this.hasQuadBatchTop = false; + this.hasPointBatchTop = false; + }; + GLWrap_.prototype.setTextureFillMode = function () + { +; + this.switchProgram(0); + }; + GLWrap_.prototype.restoreEarlyZMode = function () + { +; + this.switchProgram(2); + }; + GLWrap_.prototype.present = function () + { + this.endBatch(); + this.gl.flush(); + /* + if (debugBatch) + { +; + debugBatch = false; + } + */ + }; + function nextHighestPowerOfTwo(x) { + --x; + for (var i = 1; i < 32; i <<= 1) { + x = x | x >> i; + } + return x + 1; + } + var all_textures = []; + var textures_by_src = {}; + GLWrap_.prototype.contextLost = function () + { + cr.clearArray(all_textures); + textures_by_src = {}; + }; + var BF_RGBA8 = 0; + var BF_RGB8 = 1; + var BF_RGBA4 = 2; + var BF_RGB5_A1 = 3; + var BF_RGB565 = 4; + GLWrap_.prototype.loadTexture = function (img, tiling, linearsampling, pixelformat, tiletype, nomip) + { + tiling = !!tiling; + linearsampling = !!linearsampling; + var tex_key = img.src + "," + tiling + "," + linearsampling + (tiling ? ("," + tiletype) : ""); + var webGL_texture = null; + if (typeof img.src !== "undefined" && textures_by_src.hasOwnProperty(tex_key)) + { + webGL_texture = textures_by_src[tex_key]; + webGL_texture.c2refcount++; + return webGL_texture; + } + this.endBatch(); +; + var gl = this.gl; + var isPOT = (cr.isPOT(img.width) && cr.isPOT(img.height)); + webGL_texture = gl.createTexture(); + gl.bindTexture(gl.TEXTURE_2D, webGL_texture); + gl.pixelStorei(gl["UNPACK_PREMULTIPLY_ALPHA_WEBGL"], true); + var internalformat = gl.RGBA; + var format = gl.RGBA; + var type = gl.UNSIGNED_BYTE; + if (pixelformat && !this.isIE) + { + switch (pixelformat) { + case BF_RGB8: + internalformat = gl.RGB; + format = gl.RGB; + break; + case BF_RGBA4: + type = gl.UNSIGNED_SHORT_4_4_4_4; + break; + case BF_RGB5_A1: + type = gl.UNSIGNED_SHORT_5_5_5_1; + break; + case BF_RGB565: + internalformat = gl.RGB; + format = gl.RGB; + type = gl.UNSIGNED_SHORT_5_6_5; + break; + } + } + if (this.version === 1 && !isPOT && tiling) + { + var canvas = document.createElement("canvas"); + canvas.width = cr.nextHighestPowerOfTwo(img.width); + canvas.height = cr.nextHighestPowerOfTwo(img.height); + var ctx = canvas.getContext("2d"); + if (typeof ctx["imageSmoothingEnabled"] !== "undefined") + { + ctx["imageSmoothingEnabled"] = linearsampling; + } + else + { + ctx["webkitImageSmoothingEnabled"] = linearsampling; + ctx["mozImageSmoothingEnabled"] = linearsampling; + ctx["msImageSmoothingEnabled"] = linearsampling; + } + ctx.drawImage(img, + 0, 0, img.width, img.height, + 0, 0, canvas.width, canvas.height); + gl.texImage2D(gl.TEXTURE_2D, 0, internalformat, format, type, canvas); + } + else + gl.texImage2D(gl.TEXTURE_2D, 0, internalformat, format, type, img); + if (tiling) + { + if (tiletype === "repeat-x") + { + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.REPEAT); + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE); + } + else if (tiletype === "repeat-y") + { + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE); + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.REPEAT); + } + else + { + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.REPEAT); + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.REPEAT); + } + } + else + { + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE); + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE); + } + if (linearsampling) + { + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR); + if ((isPOT || this.version >= 2) && this.enable_mipmaps && !nomip) + { + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR_MIPMAP_LINEAR); + gl.generateMipmap(gl.TEXTURE_2D); + } + else + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR); + } + else + { + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST); + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST); + } + gl.bindTexture(gl.TEXTURE_2D, null); + this.lastTexture0 = null; + webGL_texture.c2width = img.width; + webGL_texture.c2height = img.height; + webGL_texture.c2refcount = 1; + webGL_texture.c2texkey = tex_key; + all_textures.push(webGL_texture); + textures_by_src[tex_key] = webGL_texture; + return webGL_texture; + }; + GLWrap_.prototype.createEmptyTexture = function (w, h, linearsampling, _16bit, tiling) + { + this.endBatch(); + var gl = this.gl; + if (this.isIE) + _16bit = false; + var webGL_texture = gl.createTexture(); + gl.bindTexture(gl.TEXTURE_2D, webGL_texture); + gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, w, h, 0, gl.RGBA, _16bit ? gl.UNSIGNED_SHORT_4_4_4_4 : gl.UNSIGNED_BYTE, null); + if (tiling) + { + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.REPEAT); + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.REPEAT); + } + else + { + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE); + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE); + } + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, linearsampling ? gl.LINEAR : gl.NEAREST); + gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, linearsampling ? gl.LINEAR : gl.NEAREST); + gl.bindTexture(gl.TEXTURE_2D, null); + this.lastTexture0 = null; + webGL_texture.c2width = w; + webGL_texture.c2height = h; + all_textures.push(webGL_texture); + return webGL_texture; + }; + GLWrap_.prototype.videoToTexture = function (video_, texture_, _16bit) + { + this.endBatch(); + var gl = this.gl; + if (this.isIE) + _16bit = false; + gl.bindTexture(gl.TEXTURE_2D, texture_); + gl.pixelStorei(gl["UNPACK_PREMULTIPLY_ALPHA_WEBGL"], true); + try { + gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, _16bit ? gl.UNSIGNED_SHORT_4_4_4_4 : gl.UNSIGNED_BYTE, video_); + } + catch (e) + { + if (console && console.error) + console.error("Error updating WebGL texture: ", e); + } + gl.bindTexture(gl.TEXTURE_2D, null); + this.lastTexture0 = null; + }; + GLWrap_.prototype.deleteTexture = function (tex) + { + if (!tex) + return; + if (typeof tex.c2refcount !== "undefined" && tex.c2refcount > 1) + { + tex.c2refcount--; + return; + } + this.endBatch(); + if (tex === this.lastTexture0) + { + this.gl.bindTexture(this.gl.TEXTURE_2D, null); + this.lastTexture0 = null; + } + if (tex === this.lastTexture1) + { + this.gl.activeTexture(this.gl.TEXTURE1); + this.gl.bindTexture(this.gl.TEXTURE_2D, null); + this.gl.activeTexture(this.gl.TEXTURE0); + this.lastTexture1 = null; + } + cr.arrayFindRemove(all_textures, tex); + if (typeof tex.c2texkey !== "undefined") + delete textures_by_src[tex.c2texkey]; + this.gl.deleteTexture(tex); + }; + GLWrap_.prototype.estimateVRAM = function () + { + var total = this.width * this.height * 4 * 2; + var i, len, t; + for (i = 0, len = all_textures.length; i < len; i++) + { + t = all_textures[i]; + total += (t.c2width * t.c2height * 4); + } + return total; + }; + GLWrap_.prototype.textureCount = function () + { + return all_textures.length; + }; + GLWrap_.prototype.setRenderingToTexture = function (tex) + { + if (tex === this.renderToTex) + return; +; + var b = this.pushBatch(); + b.type = BATCH_RENDERTOTEXTURE; + b.texParam = tex; + this.renderToTex = tex; + this.hasQuadBatchTop = false; + this.hasPointBatchTop = false; + }; + cr.GLWrap = GLWrap_; +}()); +; +(function() +{ + var raf = window["requestAnimationFrame"] || + window["mozRequestAnimationFrame"] || + window["webkitRequestAnimationFrame"] || + window["msRequestAnimationFrame"] || + window["oRequestAnimationFrame"]; + function Runtime(canvas) + { + if (!canvas || (!canvas.getContext && !canvas["dc"])) + return; + if (canvas["c2runtime"]) + return; + else + canvas["c2runtime"] = this; + var self = this; + this.isCrosswalk = /crosswalk/i.test(navigator.userAgent) || /xwalk/i.test(navigator.userAgent) || !!(typeof window["c2isCrosswalk"] !== "undefined" && window["c2isCrosswalk"]); + this.isCordova = this.isCrosswalk || (typeof window["device"] !== "undefined" && (typeof window["device"]["cordova"] !== "undefined" || typeof window["device"]["phonegap"] !== "undefined")) || (typeof window["c2iscordova"] !== "undefined" && window["c2iscordova"]); + this.isPhoneGap = this.isCordova; + this.isDirectCanvas = !!canvas["dc"]; + this.isAppMobi = (typeof window["AppMobi"] !== "undefined" || this.isDirectCanvas); + this.isCocoonJs = !!window["c2cocoonjs"]; + this.isEjecta = !!window["c2ejecta"]; + if (this.isCocoonJs) + { + CocoonJS["App"]["onSuspended"].addEventListener(function() { + self["setSuspended"](true); + }); + CocoonJS["App"]["onActivated"].addEventListener(function () { + self["setSuspended"](false); + }); + } + if (this.isEjecta) + { + document.addEventListener("pagehide", function() { + self["setSuspended"](true); + }); + document.addEventListener("pageshow", function() { + self["setSuspended"](false); + }); + document.addEventListener("resize", function () { + self["setSize"](window.innerWidth, window.innerHeight); + }); + } + this.isDomFree = (this.isDirectCanvas || this.isCocoonJs || this.isEjecta); + this.isMicrosoftEdge = /edge\//i.test(navigator.userAgent); + this.isIE = (/msie/i.test(navigator.userAgent) || /trident/i.test(navigator.userAgent) || /iemobile/i.test(navigator.userAgent)) && !this.isMicrosoftEdge; + this.isTizen = /tizen/i.test(navigator.userAgent); + this.isAndroid = /android/i.test(navigator.userAgent) && !this.isTizen && !this.isIE && !this.isMicrosoftEdge; // IE mobile and Tizen masquerade as Android + this.isiPhone = (/iphone/i.test(navigator.userAgent) || /ipod/i.test(navigator.userAgent)) && !this.isIE && !this.isMicrosoftEdge; // treat ipod as an iphone; IE mobile masquerades as iPhone + this.isiPad = /ipad/i.test(navigator.userAgent); + this.isiOS = this.isiPhone || this.isiPad || this.isEjecta; + this.isiPhoneiOS6 = (this.isiPhone && /os\s6/i.test(navigator.userAgent)); + this.isChrome = (/chrome/i.test(navigator.userAgent) || /chromium/i.test(navigator.userAgent)) && !this.isIE && !this.isMicrosoftEdge; // note true on Chromium-based webview on Android 4.4+; IE 'Edge' mode also pretends to be Chrome + this.isAmazonWebApp = /amazonwebappplatform/i.test(navigator.userAgent); + this.isFirefox = /firefox/i.test(navigator.userAgent); + this.isSafari = /safari/i.test(navigator.userAgent) && !this.isChrome && !this.isIE && !this.isMicrosoftEdge; // Chrome and IE Mobile masquerade as Safari + this.isWindows = /windows/i.test(navigator.userAgent); + this.isNWjs = (typeof window["c2nodewebkit"] !== "undefined" || typeof window["c2nwjs"] !== "undefined" || /nodewebkit/i.test(navigator.userAgent) || /nwjs/i.test(navigator.userAgent)); + this.isNodeWebkit = this.isNWjs; // old name for backwards compat + this.isArcade = (typeof window["is_scirra_arcade"] !== "undefined"); + this.isWindows8App = !!(typeof window["c2isWindows8"] !== "undefined" && window["c2isWindows8"]); + this.isWindows8Capable = !!(typeof window["c2isWindows8Capable"] !== "undefined" && window["c2isWindows8Capable"]); + this.isWindowsPhone8 = !!(typeof window["c2isWindowsPhone8"] !== "undefined" && window["c2isWindowsPhone8"]); + this.isWindowsPhone81 = !!(typeof window["c2isWindowsPhone81"] !== "undefined" && window["c2isWindowsPhone81"]); + this.isWindows10 = !!window["cr_windows10"]; + this.isWinJS = (this.isWindows8App || this.isWindows8Capable || this.isWindowsPhone81 || this.isWindows10); // note not WP8.0 + this.isBlackberry10 = !!(typeof window["c2isBlackberry10"] !== "undefined" && window["c2isBlackberry10"]); + this.isAndroidStockBrowser = (this.isAndroid && !this.isChrome && !this.isCrosswalk && !this.isFirefox && !this.isAmazonWebApp && !this.isDomFree); + this.devicePixelRatio = 1; + this.isMobile = (this.isCordova || this.isCrosswalk || this.isAppMobi || this.isCocoonJs || this.isAndroid || this.isiOS || this.isWindowsPhone8 || this.isWindowsPhone81 || this.isBlackberry10 || this.isTizen || this.isEjecta); + if (!this.isMobile) + { + this.isMobile = /(blackberry|bb10|playbook|palm|symbian|nokia|windows\s+ce|phone|mobile|tablet|kindle|silk)/i.test(navigator.userAgent); + } + this.isWKWebView = !!(this.isiOS && this.isCordova && window["webkit"]); + if (typeof cr_is_preview !== "undefined" && !this.isNWjs && (window.location.search === "?nw" || /nodewebkit/i.test(navigator.userAgent) || /nwjs/i.test(navigator.userAgent))) + { + this.isNWjs = true; + } + this.isDebug = (typeof cr_is_preview !== "undefined" && window.location.search.indexOf("debug") > -1); + this.canvas = canvas; + this.canvasdiv = document.getElementById("c2canvasdiv"); + this.gl = null; + this.glwrap = null; + this.glUnmaskedRenderer = "(unavailable)"; + this.enableFrontToBack = false; + this.earlyz_index = 0; + this.ctx = null; + this.firstInFullscreen = false; + this.oldWidth = 0; // for restoring non-fullscreen canvas after fullscreen + this.oldHeight = 0; + this.canvas.oncontextmenu = function (e) { if (e.preventDefault) e.preventDefault(); return false; }; + this.canvas.onselectstart = function (e) { if (e.preventDefault) e.preventDefault(); return false; }; + this.canvas.ontouchstart = function (e) { if(e.preventDefault) e.preventDefault(); return false; }; + if (this.isDirectCanvas) + window["c2runtime"] = this; + if (this.isNWjs) + { + window["ondragover"] = function(e) { e.preventDefault(); return false; }; + window["ondrop"] = function(e) { e.preventDefault(); return false; }; + if (window["nwgui"] && window["nwgui"]["App"]["clearCache"]) + window["nwgui"]["App"]["clearCache"](); + } + if (this.isAndroidStockBrowser && typeof jQuery !== "undefined") + { + jQuery("canvas").parents("*").css("overflow", "visible"); + } + this.width = canvas.width; + this.height = canvas.height; + this.draw_width = this.width; + this.draw_height = this.height; + this.cssWidth = this.width; + this.cssHeight = this.height; + this.lastWindowWidth = window.innerWidth; + this.lastWindowHeight = window.innerHeight; + this.forceCanvasAlpha = false; // note: now unused, left for backwards compat since plugins could modify it + this.redraw = true; + this.isSuspended = false; + if (!Date.now) { + Date.now = function now() { + return +new Date(); + }; + } + this.plugins = []; + this.types = {}; + this.types_by_index = []; + this.behaviors = []; + this.layouts = {}; + this.layouts_by_index = []; + this.eventsheets = {}; + this.eventsheets_by_index = []; + this.wait_for_textures = []; // for blocking until textures loaded + this.triggers_to_postinit = []; + this.all_global_vars = []; + this.all_local_vars = []; + this.solidBehavior = null; + this.jumpthruBehavior = null; + this.shadowcasterBehavior = null; + this.deathRow = {}; + this.hasPendingInstances = false; // true if anything exists in create row or death row + this.isInClearDeathRow = false; + this.isInOnDestroy = 0; // needs to support recursion so increments and decrements and is true if > 0 + this.isRunningEvents = false; + this.isEndingLayout = false; + this.createRow = []; + this.isLoadingState = false; + this.saveToSlot = ""; + this.loadFromSlot = ""; + this.loadFromJson = null; // set to string when there is something to try to load + this.lastSaveJson = ""; + this.signalledContinuousPreview = false; + this.suspendDrawing = false; // for hiding display until continuous preview loads + this.fireOnCreateAfterLoad = []; // for delaying "On create" triggers until loading complete + this.dt = 0; + this.dt1 = 0; + this.minimumFramerate = 30; + this.logictime = 0; // used to calculate CPUUtilisation + this.cpuutilisation = 0; + this.timescale = 1.0; + this.kahanTime = new cr.KahanAdder(); + this.wallTime = new cr.KahanAdder(); + this.last_tick_time = 0; + this.fps = 0; + this.last_fps_time = 0; + this.tickcount = 0; + this.tickcount_nosave = 0; // same as tickcount but never saved/loaded + this.execcount = 0; + this.framecount = 0; // for fps + this.objectcount = 0; + this.changelayout = null; + this.destroycallbacks = []; + this.event_stack = []; + this.event_stack_index = -1; + this.localvar_stack = [[]]; + this.localvar_stack_index = 0; + this.trigger_depth = 0; // recursion depth for triggers + this.pushEventStack(null); + this.loop_stack = []; + this.loop_stack_index = -1; + this.next_uid = 0; + this.next_puid = 0; // permanent unique ids + this.layout_first_tick = true; + this.family_count = 0; + this.suspend_events = []; + this.raf_id = -1; + this.timeout_id = -1; + this.isloading = true; + this.loadingprogress = 0; + this.isNodeFullscreen = false; + this.stackLocalCount = 0; // number of stack-based local vars for recursion + this.audioInstance = null; + this.had_a_click = false; + this.isInUserInputEvent = false; + this.objects_to_pretick = new cr.ObjectSet(); + this.objects_to_tick = new cr.ObjectSet(); + this.objects_to_tick2 = new cr.ObjectSet(); + this.registered_collisions = []; + this.temp_poly = new cr.CollisionPoly([]); + this.temp_poly2 = new cr.CollisionPoly([]); + this.allGroups = []; // array of all event groups + this.groups_by_name = {}; + this.cndsBySid = {}; + this.actsBySid = {}; + this.varsBySid = {}; + this.blocksBySid = {}; + this.running_layout = null; // currently running layout + this.layer_canvas = null; // for layers "render-to-texture" + this.layer_ctx = null; + this.layer_tex = null; + this.layout_tex = null; + this.layout_canvas = null; + this.layout_ctx = null; + this.is_WebGL_context_lost = false; + this.uses_background_blending = false; // if any shader uses background blending, so entire layout renders to texture + this.fx_tex = [null, null]; + this.fullscreen_scaling = 0; + this.files_subfolder = ""; // path with project files + this.objectsByUid = {}; // maps every in-use UID (as a string) to its instance + this.loaderlogos = null; + this.snapshotCanvas = null; + this.snapshotData = ""; + this.objectRefTable = []; + this.requestProjectData(); + }; + Runtime.prototype.requestProjectData = function () + { + var self = this; + if (this.isWKWebView) + { + this.fetchLocalFileViaCordovaAsText("data.js", function (str) + { + self.loadProject(JSON.parse(str)); + }, function (err) + { + alert("Error fetching data.js"); + }); + return; + } + var xhr; + if (this.isWindowsPhone8) + xhr = new ActiveXObject("Microsoft.XMLHTTP"); + else + xhr = new XMLHttpRequest(); + var datajs_filename = "data.js"; + if (this.isWindows8App || this.isWindowsPhone8 || this.isWindowsPhone81 || this.isWindows10) + datajs_filename = "data.json"; + xhr.open("GET", datajs_filename, true); + var supportsJsonResponse = false; + if (!this.isDomFree && ("response" in xhr) && ("responseType" in xhr)) + { + try { + xhr["responseType"] = "json"; + supportsJsonResponse = (xhr["responseType"] === "json"); + } + catch (e) { + supportsJsonResponse = false; + } + } + if (!supportsJsonResponse && ("responseType" in xhr)) + { + try { + xhr["responseType"] = "text"; + } + catch (e) {} + } + if ("overrideMimeType" in xhr) + { + try { + xhr["overrideMimeType"]("application/json; charset=utf-8"); + } + catch (e) {} + } + if (this.isWindowsPhone8) + { + xhr.onreadystatechange = function () + { + if (xhr.readyState !== 4) + return; + self.loadProject(JSON.parse(xhr["responseText"])); + }; + } + else + { + xhr.onload = function () + { + if (supportsJsonResponse) + { + self.loadProject(xhr["response"]); // already parsed by browser + } + else + { + if (self.isEjecta) + { + var str = xhr["responseText"]; + str = str.substr(str.indexOf("{")); // trim any BOM + self.loadProject(JSON.parse(str)); + } + else + { + self.loadProject(JSON.parse(xhr["responseText"])); // forced to sync parse JSON + } + } + }; + xhr.onerror = function (e) + { + cr.logerror("Error requesting " + datajs_filename + ":"); + cr.logerror(e); + }; + } + xhr.send(); + }; + Runtime.prototype.initRendererAndLoader = function () + { + var self = this; + var i, len, j, lenj, k, lenk, t, s, l, y; + this.isRetina = ((!this.isDomFree || this.isEjecta || this.isCordova) && this.useHighDpi && !this.isAndroidStockBrowser); + if (this.fullscreen_mode === 0 && this.isiOS) + this.isRetina = false; + this.devicePixelRatio = (this.isRetina ? (window["devicePixelRatio"] || window["webkitDevicePixelRatio"] || window["mozDevicePixelRatio"] || window["msDevicePixelRatio"] || 1) : 1); + if (typeof window["StatusBar"] === "object") + window["StatusBar"]["hide"](); + this.ClearDeathRow(); + var attribs; + if (this.fullscreen_mode > 0) + this["setSize"](window.innerWidth, window.innerHeight, true); + this.canvas.addEventListener("webglcontextlost", function (ev) { + ev.preventDefault(); + self.onContextLost(); + cr.logexport("[Construct 2] WebGL context lost"); + window["cr_setSuspended"](true); // stop rendering + }, false); + this.canvas.addEventListener("webglcontextrestored", function (ev) { + self.glwrap.initState(); + self.glwrap.setSize(self.glwrap.width, self.glwrap.height, true); + self.layer_tex = null; + self.layout_tex = null; + self.fx_tex[0] = null; + self.fx_tex[1] = null; + self.onContextRestored(); + self.redraw = true; + cr.logexport("[Construct 2] WebGL context restored"); + window["cr_setSuspended"](false); // resume rendering + }, false); + try { + if (this.enableWebGL && (this.isCocoonJs || this.isEjecta || !this.isDomFree)) + { + attribs = { + "alpha": true, + "depth": false, + "antialias": false, + "powerPreference": "high-performance", + "failIfMajorPerformanceCaveat": true + }; + if (!this.isAndroid) + this.gl = this.canvas.getContext("webgl2", attribs); + if (!this.gl) + { + this.gl = (this.canvas.getContext("webgl", attribs) || + this.canvas.getContext("experimental-webgl", attribs)); + } + } + } + catch (e) { + } + if (this.gl) + { + var isWebGL2 = (this.gl.getParameter(this.gl.VERSION).indexOf("WebGL 2") === 0); + var debug_ext = this.gl.getExtension("WEBGL_debug_renderer_info"); + if (debug_ext) + { + var unmasked_vendor = this.gl.getParameter(debug_ext.UNMASKED_VENDOR_WEBGL); + var unmasked_renderer = this.gl.getParameter(debug_ext.UNMASKED_RENDERER_WEBGL); + this.glUnmaskedRenderer = unmasked_renderer + " [" + unmasked_vendor + "]"; + } + if (this.enableFrontToBack) + this.glUnmaskedRenderer += " [front-to-back enabled]"; +; + if (!this.isDomFree) + { + this.overlay_canvas = document.createElement("canvas"); + jQuery(this.overlay_canvas).appendTo(this.canvas.parentNode); + this.overlay_canvas.oncontextmenu = function (e) { return false; }; + this.overlay_canvas.onselectstart = function (e) { return false; }; + this.overlay_canvas.width = Math.round(this.cssWidth * this.devicePixelRatio); + this.overlay_canvas.height = Math.round(this.cssHeight * this.devicePixelRatio); + jQuery(this.overlay_canvas).css({"width": this.cssWidth + "px", + "height": this.cssHeight + "px"}); + this.positionOverlayCanvas(); + this.overlay_ctx = this.overlay_canvas.getContext("2d"); + } + this.glwrap = new cr.GLWrap(this.gl, this.isMobile, this.enableFrontToBack); + this.glwrap.setSize(this.canvas.width, this.canvas.height); + this.glwrap.enable_mipmaps = (this.downscalingQuality !== 0); + this.ctx = null; + for (i = 0, len = this.types_by_index.length; i < len; i++) + { + t = this.types_by_index[i]; + for (j = 0, lenj = t.effect_types.length; j < lenj; j++) + { + s = t.effect_types[j]; + s.shaderindex = this.glwrap.getShaderIndex(s.id); + s.preservesOpaqueness = this.glwrap.programPreservesOpaqueness(s.shaderindex); + this.uses_background_blending = this.uses_background_blending || this.glwrap.programUsesDest(s.shaderindex); + } + } + for (i = 0, len = this.layouts_by_index.length; i < len; i++) + { + l = this.layouts_by_index[i]; + for (j = 0, lenj = l.effect_types.length; j < lenj; j++) + { + s = l.effect_types[j]; + s.shaderindex = this.glwrap.getShaderIndex(s.id); + s.preservesOpaqueness = this.glwrap.programPreservesOpaqueness(s.shaderindex); + } + l.updateActiveEffects(); // update preserves opaqueness flag + for (j = 0, lenj = l.layers.length; j < lenj; j++) + { + y = l.layers[j]; + for (k = 0, lenk = y.effect_types.length; k < lenk; k++) + { + s = y.effect_types[k]; + s.shaderindex = this.glwrap.getShaderIndex(s.id); + s.preservesOpaqueness = this.glwrap.programPreservesOpaqueness(s.shaderindex); + this.uses_background_blending = this.uses_background_blending || this.glwrap.programUsesDest(s.shaderindex); + } + y.updateActiveEffects(); // update preserves opaqueness flag + } + } + } + else + { + if (this.fullscreen_mode > 0 && this.isDirectCanvas) + { +; + this.canvas = null; + document.oncontextmenu = function (e) { return false; }; + document.onselectstart = function (e) { return false; }; + this.ctx = AppMobi["canvas"]["getContext"]("2d"); + try { + this.ctx["samplingMode"] = this.linearSampling ? "smooth" : "sharp"; + this.ctx["globalScale"] = 1; + this.ctx["HTML5CompatibilityMode"] = true; + this.ctx["imageSmoothingEnabled"] = this.linearSampling; + } catch(e){} + if (this.width !== 0 && this.height !== 0) + { + this.ctx.width = this.width; + this.ctx.height = this.height; + } + } + if (!this.ctx) + { +; + if (this.isCocoonJs) + { + attribs = { + "antialias": !!this.linearSampling, + "alpha": true + }; + this.ctx = this.canvas.getContext("2d", attribs); + } + else + { + attribs = { + "alpha": true + }; + this.ctx = this.canvas.getContext("2d", attribs); + } + this.setCtxImageSmoothingEnabled(this.ctx, this.linearSampling); + } + this.overlay_canvas = null; + this.overlay_ctx = null; + } + this.tickFunc = function (timestamp) { self.tick(false, timestamp); }; + if (window != window.top && !this.isDomFree && !this.isWinJS && !this.isWindowsPhone8) + { + document.addEventListener("mousedown", function () { + window.focus(); + }, true); + document.addEventListener("touchstart", function () { + window.focus(); + }, true); + } + if (typeof cr_is_preview !== "undefined") + { + if (this.isCocoonJs) + console.log("[Construct 2] In preview-over-wifi via CocoonJS mode"); + if (window.location.search.indexOf("continuous") > -1) + { + cr.logexport("Reloading for continuous preview"); + this.loadFromSlot = "__c2_continuouspreview"; + this.suspendDrawing = true; + } + if (this.pauseOnBlur && !this.isMobile) + { + jQuery(window).focus(function () + { + self["setSuspended"](false); + }); + jQuery(window).blur(function () + { + var parent = window.parent; + if (!parent || !parent.document.hasFocus()) + self["setSuspended"](true); + }); + } + } + window.addEventListener("blur", function () { + self.onWindowBlur(); + }); + if (!this.isDomFree) + { + var unfocusFormControlFunc = function (e) { + if (cr.isCanvasInputEvent(e) && document["activeElement"] && document["activeElement"] !== document.getElementsByTagName("body")[0] && document["activeElement"].blur) + { + try { + document["activeElement"].blur(); + } + catch (e) {} + } + } + if (typeof PointerEvent !== "undefined") + { + document.addEventListener("pointerdown", unfocusFormControlFunc); + } + else if (window.navigator["msPointerEnabled"]) + { + document.addEventListener("MSPointerDown", unfocusFormControlFunc); + } + else + { + document.addEventListener("touchstart", unfocusFormControlFunc); + } + document.addEventListener("mousedown", unfocusFormControlFunc); + } + if (this.fullscreen_mode === 0 && this.isRetina && this.devicePixelRatio > 1) + { + this["setSize"](this.original_width, this.original_height, true); + } + this.tryLockOrientation(); + this.getready(); // determine things to preload + this.go(); // run loading screen + this.extra = {}; + cr.seal(this); + }; + var webkitRepaintFlag = false; + Runtime.prototype["setSize"] = function (w, h, force) + { + var offx = 0, offy = 0; + var neww = 0, newh = 0, intscale = 0; + if (this.lastWindowWidth === w && this.lastWindowHeight === h && !force) + return; + this.lastWindowWidth = w; + this.lastWindowHeight = h; + var mode = this.fullscreen_mode; + var orig_aspect, cur_aspect; + var isfullscreen = (document["mozFullScreen"] || document["webkitIsFullScreen"] || !!document["msFullscreenElement"] || document["fullScreen"] || this.isNodeFullscreen) && !this.isCordova; + if (!isfullscreen && this.fullscreen_mode === 0 && !force) + return; // ignore size events when not fullscreen and not using a fullscreen-in-browser mode + if (isfullscreen) + mode = this.fullscreen_scaling; + var dpr = this.devicePixelRatio; + if (mode >= 4) + { + if (mode === 5 && dpr !== 1) // integer scaling + { + w += 1; + h += 1; + } + orig_aspect = this.original_width / this.original_height; + cur_aspect = w / h; + if (cur_aspect > orig_aspect) + { + neww = h * orig_aspect; + if (mode === 5) // integer scaling + { + intscale = (neww * dpr) / this.original_width; + if (intscale > 1) + intscale = Math.floor(intscale); + else if (intscale < 1) + intscale = 1 / Math.ceil(1 / intscale); + neww = this.original_width * intscale / dpr; + newh = this.original_height * intscale / dpr; + offx = (w - neww) / 2; + offy = (h - newh) / 2; + w = neww; + h = newh; + } + else + { + offx = (w - neww) / 2; + w = neww; + } + } + else + { + newh = w / orig_aspect; + if (mode === 5) // integer scaling + { + intscale = (newh * dpr) / this.original_height; + if (intscale > 1) + intscale = Math.floor(intscale); + else if (intscale < 1) + intscale = 1 / Math.ceil(1 / intscale); + neww = this.original_width * intscale / dpr; + newh = this.original_height * intscale / dpr; + offx = (w - neww) / 2; + offy = (h - newh) / 2; + w = neww; + h = newh; + } + else + { + offy = (h - newh) / 2; + h = newh; + } + } + } + else if (isfullscreen && mode === 0) + { + offx = Math.floor((w - this.original_width) / 2); + offy = Math.floor((h - this.original_height) / 2); + w = this.original_width; + h = this.original_height; + } + if (mode < 2) + this.aspect_scale = dpr; + this.cssWidth = Math.round(w); + this.cssHeight = Math.round(h); + this.width = Math.round(w * dpr); + this.height = Math.round(h * dpr); + this.redraw = true; + if (this.wantFullscreenScalingQuality) + { + this.draw_width = this.width; + this.draw_height = this.height; + this.fullscreenScalingQuality = true; + } + else + { + if ((this.width < this.original_width && this.height < this.original_height) || mode === 1) + { + this.draw_width = this.width; + this.draw_height = this.height; + this.fullscreenScalingQuality = true; + } + else + { + this.draw_width = this.original_width; + this.draw_height = this.original_height; + this.fullscreenScalingQuality = false; + /*var orig_aspect = this.original_width / this.original_height; + var cur_aspect = this.width / this.height; + if ((this.fullscreen_mode !== 2 && cur_aspect > orig_aspect) || (this.fullscreen_mode === 2 && cur_aspect < orig_aspect)) + this.aspect_scale = this.height / this.original_height; + else + this.aspect_scale = this.width / this.original_width;*/ + if (mode === 2) // scale inner + { + orig_aspect = this.original_width / this.original_height; + cur_aspect = this.lastWindowWidth / this.lastWindowHeight; + if (cur_aspect < orig_aspect) + this.draw_width = this.draw_height * cur_aspect; + else if (cur_aspect > orig_aspect) + this.draw_height = this.draw_width / cur_aspect; + } + else if (mode === 3) + { + orig_aspect = this.original_width / this.original_height; + cur_aspect = this.lastWindowWidth / this.lastWindowHeight; + if (cur_aspect > orig_aspect) + this.draw_width = this.draw_height * cur_aspect; + else if (cur_aspect < orig_aspect) + this.draw_height = this.draw_width / cur_aspect; + } + } + } + if (this.canvasdiv && !this.isDomFree) + { + jQuery(this.canvasdiv).css({"width": Math.round(w) + "px", + "height": Math.round(h) + "px", + "margin-left": Math.floor(offx) + "px", + "margin-top": Math.floor(offy) + "px"}); + if (typeof cr_is_preview !== "undefined") + { + jQuery("#borderwrap").css({"width": Math.round(w) + "px", + "height": Math.round(h) + "px"}); + } + } + if (this.canvas) + { + this.canvas.width = Math.round(w * dpr); + this.canvas.height = Math.round(h * dpr); + if (this.isEjecta) + { + this.canvas.style.left = Math.floor(offx) + "px"; + this.canvas.style.top = Math.floor(offy) + "px"; + this.canvas.style.width = Math.round(w) + "px"; + this.canvas.style.height = Math.round(h) + "px"; + } + else if (this.isRetina && !this.isDomFree) + { + this.canvas.style.width = Math.round(w) + "px"; + this.canvas.style.height = Math.round(h) + "px"; + } + } + if (this.overlay_canvas) + { + this.overlay_canvas.width = Math.round(w * dpr); + this.overlay_canvas.height = Math.round(h * dpr); + this.overlay_canvas.style.width = this.cssWidth + "px"; + this.overlay_canvas.style.height = this.cssHeight + "px"; + } + if (this.glwrap) + { + this.glwrap.setSize(Math.round(w * dpr), Math.round(h * dpr)); + } + if (this.isDirectCanvas && this.ctx) + { + this.ctx.width = Math.round(w); + this.ctx.height = Math.round(h); + } + if (this.ctx) + { + this.setCtxImageSmoothingEnabled(this.ctx, this.linearSampling); + } + this.tryLockOrientation(); + if (this.isiPhone && !this.isCordova) + { + window.scrollTo(0, 0); + } + }; + Runtime.prototype.tryLockOrientation = function () + { + if (!this.autoLockOrientation || this.orientations === 0) + return; + var orientation = "portrait"; + if (this.orientations === 2) + orientation = "landscape"; + try { + if (screen["orientation"] && screen["orientation"]["lock"]) + screen["orientation"]["lock"](orientation).catch(function(){}); + else if (screen["lockOrientation"]) + screen["lockOrientation"](orientation); + else if (screen["webkitLockOrientation"]) + screen["webkitLockOrientation"](orientation); + else if (screen["mozLockOrientation"]) + screen["mozLockOrientation"](orientation); + else if (screen["msLockOrientation"]) + screen["msLockOrientation"](orientation); + } + catch (e) + { + if (console && console.warn) + console.warn("Failed to lock orientation: ", e); + } + }; + Runtime.prototype.onContextLost = function () + { + this.glwrap.contextLost(); + this.is_WebGL_context_lost = true; + var i, len, t; + for (i = 0, len = this.types_by_index.length; i < len; i++) + { + t = this.types_by_index[i]; + if (t.onLostWebGLContext) + t.onLostWebGLContext(); + } + }; + Runtime.prototype.onContextRestored = function () + { + this.is_WebGL_context_lost = false; + var i, len, t; + for (i = 0, len = this.types_by_index.length; i < len; i++) + { + t = this.types_by_index[i]; + if (t.onRestoreWebGLContext) + t.onRestoreWebGLContext(); + } + }; + Runtime.prototype.positionOverlayCanvas = function() + { + if (this.isDomFree) + return; + var isfullscreen = (document["mozFullScreen"] || document["webkitIsFullScreen"] || document["fullScreen"] || !!document["msFullscreenElement"] || this.isNodeFullscreen) && !this.isCordova; + var overlay_position = isfullscreen ? jQuery(this.canvas).offset() : jQuery(this.canvas).position(); + overlay_position.position = "absolute"; + jQuery(this.overlay_canvas).css(overlay_position); + }; + var caf = window["cancelAnimationFrame"] || + window["mozCancelAnimationFrame"] || + window["webkitCancelAnimationFrame"] || + window["msCancelAnimationFrame"] || + window["oCancelAnimationFrame"]; + Runtime.prototype["setSuspended"] = function (s) + { + var i, len; + var self = this; + if (s && !this.isSuspended) + { + cr.logexport("[Construct 2] Suspending"); + this.isSuspended = true; // next tick will be last + if (this.raf_id !== -1 && caf) // note: CocoonJS does not implement cancelAnimationFrame + caf(this.raf_id); + if (this.timeout_id !== -1) + clearTimeout(this.timeout_id); + for (i = 0, len = this.suspend_events.length; i < len; i++) + this.suspend_events[i](true); + } + else if (!s && this.isSuspended) + { + cr.logexport("[Construct 2] Resuming"); + this.isSuspended = false; + this.last_tick_time = cr.performance_now(); // ensure first tick is a zero-dt one + this.last_fps_time = cr.performance_now(); // reset FPS counter + this.framecount = 0; + this.logictime = 0; + for (i = 0, len = this.suspend_events.length; i < len; i++) + this.suspend_events[i](false); + this.tick(false); // kick off runtime again + } + }; + Runtime.prototype.addSuspendCallback = function (f) + { + this.suspend_events.push(f); + }; + Runtime.prototype.GetObjectReference = function (i) + { +; + return this.objectRefTable[i]; + }; + Runtime.prototype.loadProject = function (data_response) + { +; + if (!data_response || !data_response["project"]) + cr.logerror("Project model unavailable"); + var pm = data_response["project"]; + this.name = pm[0]; + this.first_layout = pm[1]; + this.fullscreen_mode = pm[12]; // 0 = off, 1 = crop, 2 = scale inner, 3 = scale outer, 4 = letterbox scale, 5 = integer letterbox scale + this.fullscreen_mode_set = pm[12]; + this.original_width = pm[10]; + this.original_height = pm[11]; + this.parallax_x_origin = this.original_width / 2; + this.parallax_y_origin = this.original_height / 2; + if (this.isDomFree && !this.isEjecta && (pm[12] >= 4 || pm[12] === 0)) + { + cr.logexport("[Construct 2] Letterbox scale fullscreen modes are not supported on this platform - falling back to 'Scale outer'"); + this.fullscreen_mode = 3; + this.fullscreen_mode_set = 3; + } + this.uses_loader_layout = pm[18]; + this.loaderstyle = pm[19]; + if (this.loaderstyle === 0) + { + var loaderImage = new Image(); + loaderImage.crossOrigin = "anonymous"; + this.setImageSrc(loaderImage, "loading-logo.png"); + this.loaderlogos = { + logo: loaderImage + }; + } + else if (this.loaderstyle === 4) // c2 splash + { + var loaderC2logo_1024 = new Image(); + loaderC2logo_1024.src = ""; + var loaderC2logo_512 = new Image(); + loaderC2logo_512.src = ""; + var loaderC2logo_256 = new Image(); + loaderC2logo_256.src = ""; + var loaderC2logo_128 = new Image(); + loaderC2logo_128.src = ""; + var loaderPowered_1024 = new Image(); + loaderPowered_1024.src = ""; + var loaderPowered_512 = new Image(); + loaderPowered_512.src = ""; + var loaderPowered_256 = new Image(); + loaderPowered_256.src = ""; + var loaderPowered_128 = new Image(); + loaderPowered_128.src = ""; + var loaderWebsite_1024 = new Image(); + loaderWebsite_1024.src = ""; + var loaderWebsite_512 = new Image(); + loaderWebsite_512.src = ""; + var loaderWebsite_256 = new Image(); + loaderWebsite_256.src = ""; + var loaderWebsite_128 = new Image(); + loaderWebsite_128.src = ""; + this.loaderlogos = { + logo: [loaderC2logo_1024, loaderC2logo_512, loaderC2logo_256, loaderC2logo_128], + powered: [loaderPowered_1024, loaderPowered_512, loaderPowered_256, loaderPowered_128], + website: [loaderWebsite_1024, loaderWebsite_512, loaderWebsite_256, loaderWebsite_128] + }; + } + this.next_uid = pm[21]; + this.objectRefTable = cr.getObjectRefTable(); + this.system = new cr.system_object(this); + var i, len, j, lenj, k, lenk, idstr, m, b, t, f, p; + var plugin, plugin_ctor; + for (i = 0, len = pm[2].length; i < len; i++) + { + m = pm[2][i]; + p = this.GetObjectReference(m[0]); +; + cr.add_common_aces(m, p.prototype); + plugin = new p(this); + plugin.singleglobal = m[1]; + plugin.is_world = m[2]; + plugin.is_rotatable = m[5]; + plugin.must_predraw = m[9]; + if (plugin.onCreate) + plugin.onCreate(); // opportunity to override default ACEs + cr.seal(plugin); + this.plugins.push(plugin); + } + this.objectRefTable = cr.getObjectRefTable(); + for (i = 0, len = pm[3].length; i < len; i++) + { + m = pm[3][i]; + plugin_ctor = this.GetObjectReference(m[1]); +; + plugin = null; + for (j = 0, lenj = this.plugins.length; j < lenj; j++) + { + if (this.plugins[j] instanceof plugin_ctor) + { + plugin = this.plugins[j]; + break; + } + } +; +; + var type_inst = new plugin.Type(plugin); +; + type_inst.name = m[0]; + type_inst.is_family = m[2]; + type_inst.instvar_sids = m[3].slice(0); + type_inst.vars_count = m[3].length; + type_inst.behs_count = m[4]; + type_inst.fx_count = m[5]; + type_inst.sid = m[11]; + if (type_inst.is_family) + { + type_inst.members = []; // types in this family + type_inst.family_index = this.family_count++; + type_inst.families = null; + } + else + { + type_inst.members = null; + type_inst.family_index = -1; + type_inst.families = []; // families this type belongs to + } + type_inst.family_var_map = null; + type_inst.family_beh_map = null; + type_inst.family_fx_map = null; + type_inst.is_contained = false; + type_inst.container = null; + if (m[6]) + { + type_inst.texture_file = m[6][0]; + type_inst.texture_filesize = m[6][1]; + type_inst.texture_pixelformat = m[6][2]; + } + else + { + type_inst.texture_file = null; + type_inst.texture_filesize = 0; + type_inst.texture_pixelformat = 0; // rgba8 + } + if (m[7]) + { + type_inst.animations = m[7]; + } + else + { + type_inst.animations = null; + } + type_inst.index = i; // save index in to types array in type + type_inst.instances = []; // all instances of this type + type_inst.deadCache = []; // destroyed instances to recycle next create + type_inst.solstack = [new cr.selection(type_inst)]; // initialise SOL stack with one empty SOL + type_inst.cur_sol = 0; + type_inst.default_instance = null; + type_inst.default_layerindex = 0; + type_inst.stale_iids = true; + type_inst.updateIIDs = cr.type_updateIIDs; + type_inst.getFirstPicked = cr.type_getFirstPicked; + type_inst.getPairedInstance = cr.type_getPairedInstance; + type_inst.getCurrentSol = cr.type_getCurrentSol; + type_inst.pushCleanSol = cr.type_pushCleanSol; + type_inst.pushCopySol = cr.type_pushCopySol; + type_inst.popSol = cr.type_popSol; + type_inst.getBehaviorByName = cr.type_getBehaviorByName; + type_inst.getBehaviorIndexByName = cr.type_getBehaviorIndexByName; + type_inst.getEffectIndexByName = cr.type_getEffectIndexByName; + type_inst.applySolToContainer = cr.type_applySolToContainer; + type_inst.getInstanceByIID = cr.type_getInstanceByIID; + type_inst.collision_grid = new cr.SparseGrid(this.original_width, this.original_height); + type_inst.any_cell_changed = true; + type_inst.any_instance_parallaxed = false; + type_inst.extra = {}; + type_inst.toString = cr.type_toString; + type_inst.behaviors = []; + for (j = 0, lenj = m[8].length; j < lenj; j++) + { + b = m[8][j]; + var behavior_ctor = this.GetObjectReference(b[1]); + var behavior_plugin = null; + for (k = 0, lenk = this.behaviors.length; k < lenk; k++) + { + if (this.behaviors[k] instanceof behavior_ctor) + { + behavior_plugin = this.behaviors[k]; + break; + } + } + if (!behavior_plugin) + { + behavior_plugin = new behavior_ctor(this); + behavior_plugin.my_types = []; // types using this behavior + behavior_plugin.my_instances = new cr.ObjectSet(); // instances of this behavior + if (behavior_plugin.onCreate) + behavior_plugin.onCreate(); + cr.seal(behavior_plugin); + this.behaviors.push(behavior_plugin); + if (cr.behaviors.solid && behavior_plugin instanceof cr.behaviors.solid) + this.solidBehavior = behavior_plugin; + if (cr.behaviors.jumpthru && behavior_plugin instanceof cr.behaviors.jumpthru) + this.jumpthruBehavior = behavior_plugin; + if (cr.behaviors.shadowcaster && behavior_plugin instanceof cr.behaviors.shadowcaster) + this.shadowcasterBehavior = behavior_plugin; + } + if (behavior_plugin.my_types.indexOf(type_inst) === -1) + behavior_plugin.my_types.push(type_inst); + var behavior_type = new behavior_plugin.Type(behavior_plugin, type_inst); + behavior_type.name = b[0]; + behavior_type.sid = b[2]; + behavior_type.onCreate(); + cr.seal(behavior_type); + type_inst.behaviors.push(behavior_type); + } + type_inst.global = m[9]; + type_inst.isOnLoaderLayout = m[10]; + type_inst.effect_types = []; + for (j = 0, lenj = m[12].length; j < lenj; j++) + { + type_inst.effect_types.push({ + id: m[12][j][0], + name: m[12][j][1], + shaderindex: -1, + preservesOpaqueness: false, + active: true, + index: j + }); + } + type_inst.tile_poly_data = m[13]; + if (!this.uses_loader_layout || type_inst.is_family || type_inst.isOnLoaderLayout || !plugin.is_world) + { + type_inst.onCreate(); + cr.seal(type_inst); + } + if (type_inst.name) + this.types[type_inst.name] = type_inst; + this.types_by_index.push(type_inst); + if (plugin.singleglobal) + { + var instance = new plugin.Instance(type_inst); + instance.uid = this.next_uid++; + instance.puid = this.next_puid++; + instance.iid = 0; + instance.get_iid = cr.inst_get_iid; + instance.toString = cr.inst_toString; + instance.properties = m[14]; + instance.onCreate(); + cr.seal(instance); + type_inst.instances.push(instance); + this.objectsByUid[instance.uid.toString()] = instance; + } + } + for (i = 0, len = pm[4].length; i < len; i++) + { + var familydata = pm[4][i]; + var familytype = this.types_by_index[familydata[0]]; + var familymember; + for (j = 1, lenj = familydata.length; j < lenj; j++) + { + familymember = this.types_by_index[familydata[j]]; + familymember.families.push(familytype); + familytype.members.push(familymember); + } + } + for (i = 0, len = pm[28].length; i < len; i++) + { + var containerdata = pm[28][i]; + var containertypes = []; + for (j = 0, lenj = containerdata.length; j < lenj; j++) + containertypes.push(this.types_by_index[containerdata[j]]); + for (j = 0, lenj = containertypes.length; j < lenj; j++) + { + containertypes[j].is_contained = true; + containertypes[j].container = containertypes; + } + } + if (this.family_count > 0) + { + for (i = 0, len = this.types_by_index.length; i < len; i++) + { + t = this.types_by_index[i]; + if (t.is_family || !t.families.length) + continue; + t.family_var_map = new Array(this.family_count); + t.family_beh_map = new Array(this.family_count); + t.family_fx_map = new Array(this.family_count); + var all_fx = []; + var varsum = 0; + var behsum = 0; + var fxsum = 0; + for (j = 0, lenj = t.families.length; j < lenj; j++) + { + f = t.families[j]; + t.family_var_map[f.family_index] = varsum; + varsum += f.vars_count; + t.family_beh_map[f.family_index] = behsum; + behsum += f.behs_count; + t.family_fx_map[f.family_index] = fxsum; + fxsum += f.fx_count; + for (k = 0, lenk = f.effect_types.length; k < lenk; k++) + all_fx.push(cr.shallowCopy({}, f.effect_types[k])); + } + t.effect_types = all_fx.concat(t.effect_types); + for (j = 0, lenj = t.effect_types.length; j < lenj; j++) + t.effect_types[j].index = j; + } + } + for (i = 0, len = pm[5].length; i < len; i++) + { + m = pm[5][i]; + var layout = new cr.layout(this, m); + cr.seal(layout); + this.layouts[layout.name] = layout; + this.layouts_by_index.push(layout); + } + for (i = 0, len = pm[6].length; i < len; i++) + { + m = pm[6][i]; + var sheet = new cr.eventsheet(this, m); + cr.seal(sheet); + this.eventsheets[sheet.name] = sheet; + this.eventsheets_by_index.push(sheet); + } + for (i = 0, len = this.eventsheets_by_index.length; i < len; i++) + this.eventsheets_by_index[i].postInit(); + for (i = 0, len = this.eventsheets_by_index.length; i < len; i++) + this.eventsheets_by_index[i].updateDeepIncludes(); + for (i = 0, len = this.triggers_to_postinit.length; i < len; i++) + this.triggers_to_postinit[i].postInit(); + cr.clearArray(this.triggers_to_postinit) + this.audio_to_preload = pm[7]; + this.files_subfolder = pm[8]; + this.pixel_rounding = pm[9]; + this.aspect_scale = 1.0; + this.enableWebGL = pm[13]; + this.linearSampling = pm[14]; + this.clearBackground = pm[15]; + this.versionstr = pm[16]; + this.useHighDpi = pm[17]; + this.orientations = pm[20]; // 0 = any, 1 = portrait, 2 = landscape + this.autoLockOrientation = (this.orientations > 0); + this.pauseOnBlur = pm[22]; + this.wantFullscreenScalingQuality = pm[23]; // false = low quality, true = high quality + this.fullscreenScalingQuality = this.wantFullscreenScalingQuality; + this.downscalingQuality = pm[24]; // 0 = low (mips off), 1 = medium (mips on, dense spritesheet), 2 = high (mips on, sparse spritesheet) + this.preloadSounds = pm[25]; // 0 = no, 1 = yes + this.projectName = pm[26]; + this.enableFrontToBack = pm[27] && !this.isIE; // front-to-back renderer disabled in IE (but not Edge) + this.start_time = Date.now(); + cr.clearArray(this.objectRefTable); + this.initRendererAndLoader(); + }; + var anyImageHadError = false; + var MAX_PARALLEL_IMAGE_LOADS = 100; + var currentlyActiveImageLoads = 0; + var imageLoadQueue = []; // array of [img, srcToSet] + Runtime.prototype.queueImageLoad = function (img_, src_) + { + var self = this; + var doneFunc = function () + { + currentlyActiveImageLoads--; + self.maybeLoadNextImages(); + }; + img_.addEventListener("load", doneFunc); + img_.addEventListener("error", doneFunc); + imageLoadQueue.push([img_, src_]); + this.maybeLoadNextImages(); + }; + Runtime.prototype.maybeLoadNextImages = function () + { + var next; + while (imageLoadQueue.length && currentlyActiveImageLoads < MAX_PARALLEL_IMAGE_LOADS) + { + currentlyActiveImageLoads++; + next = imageLoadQueue.shift(); + this.setImageSrc(next[0], next[1]); + } + }; + Runtime.prototype.waitForImageLoad = function (img_, src_) + { + img_["cocoonLazyLoad"] = true; + img_.onerror = function (e) + { + img_.c2error = true; + anyImageHadError = true; + if (console && console.error) + console.error("Error loading image '" + img_.src + "': ", e); + }; + if (this.isEjecta) + { + img_.src = src_; + } + else if (!img_.src) + { + if (typeof XAPKReader !== "undefined") + { + XAPKReader.get(src_, function (expanded_url) + { + img_.src = expanded_url; + }, function (e) + { + img_.c2error = true; + anyImageHadError = true; + if (console && console.error) + console.error("Error extracting image '" + src_ + "' from expansion file: ", e); + }); + } + else + { + img_.crossOrigin = "anonymous"; // required for Arcade sandbox compatibility + this.queueImageLoad(img_, src_); // use a queue to avoid requesting all images simultaneously + } + } + this.wait_for_textures.push(img_); + }; + Runtime.prototype.findWaitingTexture = function (src_) + { + var i, len; + for (i = 0, len = this.wait_for_textures.length; i < len; i++) + { + if (this.wait_for_textures[i].cr_src === src_) + return this.wait_for_textures[i]; + } + return null; + }; + var audio_preload_totalsize = 0; + var audio_preload_started = false; + Runtime.prototype.getready = function () + { + if (!this.audioInstance) + return; + audio_preload_totalsize = this.audioInstance.setPreloadList(this.audio_to_preload); + }; + Runtime.prototype.areAllTexturesAndSoundsLoaded = function () + { + var totalsize = audio_preload_totalsize; + var completedsize = 0; + var audiocompletedsize = 0; + var ret = true; + var i, len, img; + for (i = 0, len = this.wait_for_textures.length; i < len; i++) + { + img = this.wait_for_textures[i]; + var filesize = img.cr_filesize; + if (!filesize || filesize <= 0) + filesize = 50000; + totalsize += filesize; + if (!!img.src && (img.complete || img["loaded"]) && !img.c2error) + completedsize += filesize; + else + ret = false; // not all textures loaded + } + if (ret && this.preloadSounds && this.audioInstance) + { + if (!audio_preload_started) + { + this.audioInstance.startPreloads(); + audio_preload_started = true; + } + audiocompletedsize = this.audioInstance.getPreloadedSize(); + completedsize += audiocompletedsize; + if (audiocompletedsize < audio_preload_totalsize) + ret = false; // not done yet + } + if (totalsize == 0) + this.progress = 1; // indicate to C2 splash loader that it can finish now + else + this.progress = (completedsize / totalsize); + return ret; + }; + var isC2SplashDone = false; + Runtime.prototype.go = function () + { + if (!this.ctx && !this.glwrap) + return; + var ctx = this.ctx || this.overlay_ctx; + if (this.overlay_canvas) + this.positionOverlayCanvas(); + var curwidth = window.innerWidth; + var curheight = window.innerHeight; + if (this.lastWindowWidth !== curwidth || this.lastWindowHeight !== curheight) + { + this["setSize"](curwidth, curheight); + } + this.progress = 0; + this.last_progress = -1; + var self = this; + if (this.areAllTexturesAndSoundsLoaded() && (this.loaderstyle !== 4 || isC2SplashDone)) + { + this.go_loading_finished(); + } + else + { + var ms_elapsed = Date.now() - this.start_time; + if (ctx) + { + var overlay_width = this.width; + var overlay_height = this.height; + var dpr = this.devicePixelRatio; + if (this.loaderstyle < 3 && (this.isCocoonJs || (ms_elapsed >= 500 && this.last_progress != this.progress))) + { + ctx.clearRect(0, 0, overlay_width, overlay_height); + var mx = overlay_width / 2; + var my = overlay_height / 2; + var haslogo = (this.loaderstyle === 0 && this.loaderlogos.logo.complete); + var hlw = 40 * dpr; + var hlh = 0; + var logowidth = 80 * dpr; + var logoheight; + if (haslogo) + { + var loaderLogoImage = this.loaderlogos.logo; + logowidth = loaderLogoImage.width * dpr; + logoheight = loaderLogoImage.height * dpr; + hlw = logowidth / 2; + hlh = logoheight / 2; + ctx.drawImage(loaderLogoImage, cr.floor(mx - hlw), cr.floor(my - hlh), logowidth, logoheight); + } + if (this.loaderstyle <= 1) + { + my += hlh + (haslogo ? 12 * dpr : 0); + mx -= hlw; + mx = cr.floor(mx) + 0.5; + my = cr.floor(my) + 0.5; + ctx.fillStyle = anyImageHadError ? "red" : "DodgerBlue"; + ctx.fillRect(mx, my, Math.floor(logowidth * this.progress), 6 * dpr); + ctx.strokeStyle = "black"; + ctx.strokeRect(mx, my, logowidth, 6 * dpr); + ctx.strokeStyle = "white"; + ctx.strokeRect(mx - 1 * dpr, my - 1 * dpr, logowidth + 2 * dpr, 8 * dpr); + } + else if (this.loaderstyle === 2) + { + ctx.font = (this.isEjecta ? "12pt ArialMT" : "12pt Arial"); + ctx.fillStyle = anyImageHadError ? "#f00" : "#999"; + ctx.textBaseLine = "middle"; + var percent_text = Math.round(this.progress * 100) + "%"; + var text_dim = ctx.measureText ? ctx.measureText(percent_text) : null; + var text_width = text_dim ? text_dim.width : 0; + ctx.fillText(percent_text, mx - (text_width / 2), my); + } + this.last_progress = this.progress; + } + else if (this.loaderstyle === 4) + { + this.draw_c2_splash_loader(ctx); + if (raf) + raf(function() { self.go(); }); + else + setTimeout(function() { self.go(); }, 16); + return; + } + } + setTimeout(function() { self.go(); }, (this.isCocoonJs ? 10 : 100)); + } + }; + var splashStartTime = -1; + var splashFadeInDuration = 300; + var splashFadeOutDuration = 300; + var splashAfterFadeOutWait = (typeof cr_is_preview === "undefined" ? 200 : 0); + var splashIsFadeIn = true; + var splashIsFadeOut = false; + var splashFadeInFinish = 0; + var splashFadeOutStart = 0; + var splashMinDisplayTime = (typeof cr_is_preview === "undefined" ? 3000 : 0); + var renderViaCanvas = null; + var renderViaCtx = null; + var splashFrameNumber = 0; + function maybeCreateRenderViaCanvas(w, h) + { + if (!renderViaCanvas || renderViaCanvas.width !== w || renderViaCanvas.height !== h) + { + renderViaCanvas = document.createElement("canvas"); + renderViaCanvas.width = w; + renderViaCanvas.height = h; + renderViaCtx = renderViaCanvas.getContext("2d"); + } + }; + function mipImage(arr, size) + { + if (size <= 128) + return arr[3]; + else if (size <= 256) + return arr[2]; + else if (size <= 512) + return arr[1]; + else + return arr[0]; + }; + Runtime.prototype.draw_c2_splash_loader = function(ctx) + { + if (isC2SplashDone) + return; + var w = Math.ceil(this.width); + var h = Math.ceil(this.height); + var dpr = this.devicePixelRatio; + var logoimages = this.loaderlogos.logo; + var poweredimages = this.loaderlogos.powered; + var websiteimages = this.loaderlogos.website; + for (var i = 0; i < 4; ++i) + { + if (!logoimages[i].complete || !poweredimages[i].complete || !websiteimages[i].complete) + return; + } + if (splashFrameNumber === 0) + splashStartTime = Date.now(); + var nowTime = Date.now(); + var isRenderingVia = false; + var renderToCtx = ctx; + var drawW, drawH; + if (splashIsFadeIn || splashIsFadeOut) + { + ctx.clearRect(0, 0, w, h); + maybeCreateRenderViaCanvas(w, h); + renderToCtx = renderViaCtx; + isRenderingVia = true; + if (splashIsFadeIn && splashFrameNumber === 1) + splashStartTime = Date.now(); + } + else + { + ctx.globalAlpha = 1; + } + renderToCtx.fillStyle = "#333333"; + renderToCtx.fillRect(0, 0, w, h); + if (this.cssHeight > 256) + { + drawW = cr.clamp(h * 0.22, 105, w * 0.6); + drawH = drawW * 0.25; + renderToCtx.drawImage(mipImage(poweredimages, drawW), w * 0.5 - drawW/2, h * 0.2 - drawH/2, drawW, drawH); + drawW = Math.min(h * 0.395, w * 0.95); + drawH = drawW; + renderToCtx.drawImage(mipImage(logoimages, drawW), w * 0.5 - drawW/2, h * 0.485 - drawH/2, drawW, drawH); + drawW = cr.clamp(h * 0.22, 105, w * 0.6); + drawH = drawW * 0.25; + renderToCtx.drawImage(mipImage(websiteimages, drawW), w * 0.5 - drawW/2, h * 0.868 - drawH/2, drawW, drawH); + renderToCtx.fillStyle = "#3C3C3C"; + drawW = w; + drawH = Math.max(h * 0.005, 2); + renderToCtx.fillRect(0, h * 0.8 - drawH/2, drawW, drawH); + renderToCtx.fillStyle = anyImageHadError ? "red" : "#E0FF65"; + drawW = w * this.progress; + renderToCtx.fillRect(w * 0.5 - drawW/2, h * 0.8 - drawH/2, drawW, drawH); + } + else + { + drawW = h * 0.55; + drawH = drawW; + renderToCtx.drawImage(mipImage(logoimages, drawW), w * 0.5 - drawW/2, h * 0.45 - drawH/2, drawW, drawH); + renderToCtx.fillStyle = "#3C3C3C"; + drawW = w; + drawH = Math.max(h * 0.005, 2); + renderToCtx.fillRect(0, h * 0.85 - drawH/2, drawW, drawH); + renderToCtx.fillStyle = anyImageHadError ? "red" : "#E0FF65"; + drawW = w * this.progress; + renderToCtx.fillRect(w * 0.5 - drawW/2, h * 0.85 - drawH/2, drawW, drawH); + } + if (isRenderingVia) + { + if (splashIsFadeIn) + { + if (splashFrameNumber === 0) + ctx.globalAlpha = 0; + else + ctx.globalAlpha = Math.min((nowTime - splashStartTime) / splashFadeInDuration, 1); + } + else if (splashIsFadeOut) + { + ctx.globalAlpha = Math.max(1 - (nowTime - splashFadeOutStart) / splashFadeOutDuration, 0); + } + ctx.drawImage(renderViaCanvas, 0, 0, w, h); + } + if (splashIsFadeIn && nowTime - splashStartTime >= splashFadeInDuration && splashFrameNumber >= 2) + { + splashIsFadeIn = false; + splashFadeInFinish = nowTime; + } + if (!splashIsFadeIn && nowTime - splashFadeInFinish >= splashMinDisplayTime && !splashIsFadeOut && this.progress >= 1) + { + splashIsFadeOut = true; + splashFadeOutStart = nowTime; + } + if ((splashIsFadeOut && nowTime - splashFadeOutStart >= splashFadeOutDuration + splashAfterFadeOutWait) || + (typeof cr_is_preview !== "undefined" && this.progress >= 1 && Date.now() - splashStartTime < 500)) + { + isC2SplashDone = true; + splashIsFadeIn = false; + splashIsFadeOut = false; + renderViaCanvas = null; + renderViaCtx = null; + this.loaderlogos = null; + } + ++splashFrameNumber; + }; + Runtime.prototype.go_loading_finished = function () + { + if (this.overlay_canvas) + { + this.canvas.parentNode.removeChild(this.overlay_canvas); + this.overlay_ctx = null; + this.overlay_canvas = null; + } + this.start_time = Date.now(); + this.last_fps_time = cr.performance_now(); // for counting framerate + var i, len, t; + if (this.uses_loader_layout) + { + for (i = 0, len = this.types_by_index.length; i < len; i++) + { + t = this.types_by_index[i]; + if (!t.is_family && !t.isOnLoaderLayout && t.plugin.is_world) + { + t.onCreate(); + cr.seal(t); + } + } + } + else + this.isloading = false; + for (i = 0, len = this.layouts_by_index.length; i < len; i++) + { + this.layouts_by_index[i].createGlobalNonWorlds(); + } + if (this.fullscreen_mode >= 2) + { + var orig_aspect = this.original_width / this.original_height; + var cur_aspect = this.width / this.height; + if ((this.fullscreen_mode !== 2 && cur_aspect > orig_aspect) || (this.fullscreen_mode === 2 && cur_aspect < orig_aspect)) + this.aspect_scale = this.height / this.original_height; + else + this.aspect_scale = this.width / this.original_width; + } + if (this.first_layout) + this.layouts[this.first_layout].startRunning(); + else + this.layouts_by_index[0].startRunning(); +; + if (!this.uses_loader_layout) + { + this.loadingprogress = 1; + this.trigger(cr.system_object.prototype.cnds.OnLoadFinished, null); + if (window["C2_RegisterSW"]) // note not all platforms use SW + window["C2_RegisterSW"](); + } + if (navigator["splashscreen"] && navigator["splashscreen"]["hide"]) + navigator["splashscreen"]["hide"](); + for (i = 0, len = this.types_by_index.length; i < len; i++) + { + t = this.types_by_index[i]; + if (t.onAppBegin) + t.onAppBegin(); + } + if (document["hidden"] || document["webkitHidden"] || document["mozHidden"] || document["msHidden"]) + { + window["cr_setSuspended"](true); // stop rendering + } + else + { + this.tick(false); + } + if (this.isDirectCanvas) + AppMobi["webview"]["execute"]("onGameReady();"); + }; + Runtime.prototype.tick = function (background_wake, timestamp, debug_step) + { + if (!this.running_layout) + return; + var nowtime = cr.performance_now(); + var logic_start = nowtime; + if (!debug_step && this.isSuspended && !background_wake) + return; + if (!background_wake) + { + if (raf) + this.raf_id = raf(this.tickFunc); + else + { + this.timeout_id = setTimeout(this.tickFunc, this.isMobile ? 1 : 16); + } + } + var raf_time = timestamp || nowtime; + var fsmode = this.fullscreen_mode; + var isfullscreen = (document["mozFullScreen"] || document["webkitIsFullScreen"] || document["fullScreen"] || !!document["msFullscreenElement"]) && !this.isCordova; + if ((isfullscreen || this.isNodeFullscreen) && this.fullscreen_scaling > 0) + fsmode = this.fullscreen_scaling; + if (fsmode > 0) // r222: experimentally enabling this workaround for all platforms + { + var curwidth = window.innerWidth; + var curheight = window.innerHeight; + if (this.lastWindowWidth !== curwidth || this.lastWindowHeight !== curheight) + { + this["setSize"](curwidth, curheight); + } + } + if (!this.isDomFree) + { + if (isfullscreen) + { + if (!this.firstInFullscreen) + this.firstInFullscreen = true; + } + else + { + if (this.firstInFullscreen) + { + this.firstInFullscreen = false; + if (this.fullscreen_mode === 0) + { + this["setSize"](Math.round(this.oldWidth / this.devicePixelRatio), Math.round(this.oldHeight / this.devicePixelRatio), true); + } + } + else + { + this.oldWidth = this.width; + this.oldHeight = this.height; + } + } + } + if (this.isloading) + { + var done = this.areAllTexturesAndSoundsLoaded(); // updates this.progress + this.loadingprogress = this.progress; + if (done) + { + this.isloading = false; + this.progress = 1; + this.trigger(cr.system_object.prototype.cnds.OnLoadFinished, null); + if (window["C2_RegisterSW"]) + window["C2_RegisterSW"](); + } + } + this.logic(raf_time); + if ((this.redraw || this.isCocoonJs) && !this.is_WebGL_context_lost && !this.suspendDrawing && !background_wake) + { + this.redraw = false; + if (this.glwrap) + this.drawGL(); + else + this.draw(); + if (this.snapshotCanvas) + { + if (this.canvas && this.canvas.toDataURL) + { + this.snapshotData = this.canvas.toDataURL(this.snapshotCanvas[0], this.snapshotCanvas[1]); + if (window["cr_onSnapshot"]) + window["cr_onSnapshot"](this.snapshotData); + this.trigger(cr.system_object.prototype.cnds.OnCanvasSnapshot, null); + } + this.snapshotCanvas = null; + } + } + if (!this.hit_breakpoint) + { + this.tickcount++; + this.tickcount_nosave++; + this.execcount++; + this.framecount++; + } + this.logictime += cr.performance_now() - logic_start; + }; + Runtime.prototype.logic = function (cur_time) + { + var i, leni, j, lenj, k, lenk, type, inst, binst; + if (cur_time - this.last_fps_time >= 1000) // every 1 second + { + this.last_fps_time += 1000; + if (cur_time - this.last_fps_time >= 1000) + this.last_fps_time = cur_time; + this.fps = this.framecount; + this.framecount = 0; + this.cpuutilisation = this.logictime; + this.logictime = 0; + } + var wallDt = 0; + if (this.last_tick_time !== 0) + { + var ms_diff = cur_time - this.last_tick_time; + if (ms_diff < 0) + ms_diff = 0; + wallDt = ms_diff / 1000.0; // dt measured in seconds + this.dt1 = wallDt; + if (this.dt1 > 0.5) + this.dt1 = 0; + else if (this.dt1 > 1 / this.minimumFramerate) + this.dt1 = 1 / this.minimumFramerate; + } + this.last_tick_time = cur_time; + this.dt = this.dt1 * this.timescale; + this.kahanTime.add(this.dt); + this.wallTime.add(wallDt); // prevent min/max framerate affecting wall clock + var isfullscreen = (document["mozFullScreen"] || document["webkitIsFullScreen"] || document["fullScreen"] || !!document["msFullscreenElement"] || this.isNodeFullscreen) && !this.isCordova; + if (this.fullscreen_mode >= 2 /* scale */ || (isfullscreen && this.fullscreen_scaling > 0)) + { + var orig_aspect = this.original_width / this.original_height; + var cur_aspect = this.width / this.height; + var mode = this.fullscreen_mode; + if (isfullscreen && this.fullscreen_scaling > 0) + mode = this.fullscreen_scaling; + if ((mode !== 2 && cur_aspect > orig_aspect) || (mode === 2 && cur_aspect < orig_aspect)) + { + this.aspect_scale = this.height / this.original_height; + } + else + { + this.aspect_scale = this.width / this.original_width; + } + if (this.running_layout) + { + this.running_layout.scrollToX(this.running_layout.scrollX); + this.running_layout.scrollToY(this.running_layout.scrollY); + } + } + else + this.aspect_scale = (this.isRetina ? this.devicePixelRatio : 1); + this.ClearDeathRow(); + this.isInOnDestroy++; + this.system.runWaits(); // prevent instance list changing + this.isInOnDestroy--; + this.ClearDeathRow(); // allow instance list changing + this.isInOnDestroy++; + var tickarr = this.objects_to_pretick.valuesRef(); + for (i = 0, leni = tickarr.length; i < leni; i++) + tickarr[i].pretick(); + for (i = 0, leni = this.types_by_index.length; i < leni; i++) + { + type = this.types_by_index[i]; + if (type.is_family || (!type.behaviors.length && !type.families.length)) + continue; + for (j = 0, lenj = type.instances.length; j < lenj; j++) + { + inst = type.instances[j]; + for (k = 0, lenk = inst.behavior_insts.length; k < lenk; k++) + { + inst.behavior_insts[k].tick(); + } + } + } + for (i = 0, leni = this.types_by_index.length; i < leni; i++) + { + type = this.types_by_index[i]; + if (type.is_family || (!type.behaviors.length && !type.families.length)) + continue; // type doesn't have any behaviors + for (j = 0, lenj = type.instances.length; j < lenj; j++) + { + inst = type.instances[j]; + for (k = 0, lenk = inst.behavior_insts.length; k < lenk; k++) + { + binst = inst.behavior_insts[k]; + if (binst.posttick) + binst.posttick(); + } + } + } + tickarr = this.objects_to_tick.valuesRef(); + for (i = 0, leni = tickarr.length; i < leni; i++) + tickarr[i].tick(); + this.isInOnDestroy--; // end preventing instance lists from being changed + this.handleSaveLoad(); // save/load now if queued + i = 0; + while (this.changelayout && i++ < 10) + { + this.doChangeLayout(this.changelayout); + } + for (i = 0, leni = this.eventsheets_by_index.length; i < leni; i++) + this.eventsheets_by_index[i].hasRun = false; + if (this.running_layout.event_sheet) + this.running_layout.event_sheet.run(); + cr.clearArray(this.registered_collisions); + this.layout_first_tick = false; + this.isInOnDestroy++; // prevent instance lists from being changed + for (i = 0, leni = this.types_by_index.length; i < leni; i++) + { + type = this.types_by_index[i]; + if (type.is_family || (!type.behaviors.length && !type.families.length)) + continue; // type doesn't have any behaviors + for (j = 0, lenj = type.instances.length; j < lenj; j++) + { + var inst = type.instances[j]; + for (k = 0, lenk = inst.behavior_insts.length; k < lenk; k++) + { + binst = inst.behavior_insts[k]; + if (binst.tick2) + binst.tick2(); + } + } + } + tickarr = this.objects_to_tick2.valuesRef(); + for (i = 0, leni = tickarr.length; i < leni; i++) + tickarr[i].tick2(); + this.isInOnDestroy--; // end preventing instance lists from being changed + }; + Runtime.prototype.onWindowBlur = function () + { + var i, leni, j, lenj, k, lenk, type, inst, binst; + for (i = 0, leni = this.types_by_index.length; i < leni; i++) + { + type = this.types_by_index[i]; + if (type.is_family) + continue; + for (j = 0, lenj = type.instances.length; j < lenj; j++) + { + inst = type.instances[j]; + if (inst.onWindowBlur) + inst.onWindowBlur(); + if (!inst.behavior_insts) + continue; // single-globals don't have behavior_insts + for (k = 0, lenk = inst.behavior_insts.length; k < lenk; k++) + { + binst = inst.behavior_insts[k]; + if (binst.onWindowBlur) + binst.onWindowBlur(); + } + } + } + }; + Runtime.prototype.doChangeLayout = function (changeToLayout) + { + var prev_layout = this.running_layout; + this.running_layout.stopRunning(); + var i, len, j, lenj, k, lenk, type, inst, binst; + if (this.glwrap) + { + for (i = 0, len = this.types_by_index.length; i < len; i++) + { + type = this.types_by_index[i]; + if (type.is_family) + continue; + if (type.unloadTextures && (!type.global || type.instances.length === 0) && changeToLayout.initial_types.indexOf(type) === -1) + { + type.unloadTextures(); + } + } + } + if (prev_layout == changeToLayout) + cr.clearArray(this.system.waits); + cr.clearArray(this.registered_collisions); + this.runLayoutChangeMethods(true); + changeToLayout.startRunning(); + this.runLayoutChangeMethods(false); + this.redraw = true; + this.layout_first_tick = true; + this.ClearDeathRow(); + }; + Runtime.prototype.runLayoutChangeMethods = function (isBeforeChange) + { + var i, len, beh, type, j, lenj, inst, k, lenk, binst; + for (i = 0, len = this.behaviors.length; i < len; i++) + { + beh = this.behaviors[i]; + if (isBeforeChange) + { + if (beh.onBeforeLayoutChange) + beh.onBeforeLayoutChange(); + } + else + { + if (beh.onLayoutChange) + beh.onLayoutChange(); + } + } + for (i = 0, len = this.types_by_index.length; i < len; i++) + { + type = this.types_by_index[i]; + if (!type.global && !type.plugin.singleglobal) + continue; + for (j = 0, lenj = type.instances.length; j < lenj; j++) + { + inst = type.instances[j]; + if (isBeforeChange) + { + if (inst.onBeforeLayoutChange) + inst.onBeforeLayoutChange(); + } + else + { + if (inst.onLayoutChange) + inst.onLayoutChange(); + } + if (inst.behavior_insts) + { + for (k = 0, lenk = inst.behavior_insts.length; k < lenk; k++) + { + binst = inst.behavior_insts[k]; + if (isBeforeChange) + { + if (binst.onBeforeLayoutChange) + binst.onBeforeLayoutChange(); + } + else + { + if (binst.onLayoutChange) + binst.onLayoutChange(); + } + } + } + } + } + }; + Runtime.prototype.pretickMe = function (inst) + { + this.objects_to_pretick.add(inst); + }; + Runtime.prototype.unpretickMe = function (inst) + { + this.objects_to_pretick.remove(inst); + }; + Runtime.prototype.tickMe = function (inst) + { + this.objects_to_tick.add(inst); + }; + Runtime.prototype.untickMe = function (inst) + { + this.objects_to_tick.remove(inst); + }; + Runtime.prototype.tick2Me = function (inst) + { + this.objects_to_tick2.add(inst); + }; + Runtime.prototype.untick2Me = function (inst) + { + this.objects_to_tick2.remove(inst); + }; + Runtime.prototype.getDt = function (inst) + { + if (!inst || inst.my_timescale === -1.0) + return this.dt; + return this.dt1 * inst.my_timescale; + }; + Runtime.prototype.draw = function () + { + this.running_layout.draw(this.ctx); + if (this.isDirectCanvas) + this.ctx["present"](); + }; + Runtime.prototype.drawGL = function () + { + if (this.enableFrontToBack) + { + this.earlyz_index = 1; // start from front, 1-based to avoid exactly equalling near plane Z value + this.running_layout.drawGL_earlyZPass(this.glwrap); + } + this.running_layout.drawGL(this.glwrap); + this.glwrap.present(); + }; + Runtime.prototype.addDestroyCallback = function (f) + { + if (f) + this.destroycallbacks.push(f); + }; + Runtime.prototype.removeDestroyCallback = function (f) + { + cr.arrayFindRemove(this.destroycallbacks, f); + }; + Runtime.prototype.getObjectByUID = function (uid_) + { +; + var uidstr = uid_.toString(); + if (this.objectsByUid.hasOwnProperty(uidstr)) + return this.objectsByUid[uidstr]; + else + return null; + }; + var objectset_cache = []; + function alloc_objectset() + { + if (objectset_cache.length) + return objectset_cache.pop(); + else + return new cr.ObjectSet(); + }; + function free_objectset(s) + { + s.clear(); + objectset_cache.push(s); + }; + Runtime.prototype.DestroyInstance = function (inst) + { + var i, len; + var type = inst.type; + var typename = type.name; + var has_typename = this.deathRow.hasOwnProperty(typename); + var obj_set = null; + if (has_typename) + { + obj_set = this.deathRow[typename]; + if (obj_set.contains(inst)) + return; // already had DestroyInstance called + } + else + { + obj_set = alloc_objectset(); + this.deathRow[typename] = obj_set; + } + obj_set.add(inst); + this.hasPendingInstances = true; + if (inst.is_contained) + { + for (i = 0, len = inst.siblings.length; i < len; i++) + { + this.DestroyInstance(inst.siblings[i]); + } + } + if (this.isInClearDeathRow) + obj_set.values_cache.push(inst); + if (!this.isEndingLayout) + { + this.isInOnDestroy++; // support recursion + this.trigger(Object.getPrototypeOf(inst.type.plugin).cnds.OnDestroyed, inst); + this.isInOnDestroy--; + } + }; + Runtime.prototype.ClearDeathRow = function () + { + if (!this.hasPendingInstances) + return; + var inst, type, instances; + var i, j, leni, lenj, obj_set; + this.isInClearDeathRow = true; + for (i = 0, leni = this.createRow.length; i < leni; ++i) + { + inst = this.createRow[i]; + type = inst.type; + type.instances.push(inst); + for (j = 0, lenj = type.families.length; j < lenj; ++j) + { + type.families[j].instances.push(inst); + type.families[j].stale_iids = true; + } + } + cr.clearArray(this.createRow); + this.IterateDeathRow(); // moved to separate function so for-in performance doesn't hobble entire function + cr.wipe(this.deathRow); // all objectsets have already been recycled + this.isInClearDeathRow = false; + this.hasPendingInstances = false; + }; + Runtime.prototype.IterateDeathRow = function () + { + for (var p in this.deathRow) + { + if (this.deathRow.hasOwnProperty(p)) + { + this.ClearDeathRowForType(this.deathRow[p]); + } + } + }; + Runtime.prototype.ClearDeathRowForType = function (obj_set) + { + var arr = obj_set.valuesRef(); // get array of items from set +; + var type = arr[0].type; +; +; + var i, len, j, lenj, w, f, layer_instances, inst; + cr.arrayRemoveAllFromObjectSet(type.instances, obj_set); + type.stale_iids = true; + if (type.instances.length === 0) + type.any_instance_parallaxed = false; + for (i = 0, len = type.families.length; i < len; ++i) + { + f = type.families[i]; + cr.arrayRemoveAllFromObjectSet(f.instances, obj_set); + f.stale_iids = true; + } + for (i = 0, len = this.system.waits.length; i < len; ++i) + { + w = this.system.waits[i]; + if (w.sols.hasOwnProperty(type.index)) + cr.arrayRemoveAllFromObjectSet(w.sols[type.index].insts, obj_set); + if (!type.is_family) + { + for (j = 0, lenj = type.families.length; j < lenj; ++j) + { + f = type.families[j]; + if (w.sols.hasOwnProperty(f.index)) + cr.arrayRemoveAllFromObjectSet(w.sols[f.index].insts, obj_set); + } + } + } + var first_layer = arr[0].layer; + if (first_layer) + { + if (first_layer.useRenderCells) + { + layer_instances = first_layer.instances; + for (i = 0, len = layer_instances.length; i < len; ++i) + { + inst = layer_instances[i]; + if (!obj_set.contains(inst)) + continue; // not destroying this instance + inst.update_bbox(); + first_layer.render_grid.update(inst, inst.rendercells, null); + inst.rendercells.set(0, 0, -1, -1); + } + } + cr.arrayRemoveAllFromObjectSet(first_layer.instances, obj_set); + first_layer.setZIndicesStaleFrom(0); + } + for (i = 0; i < arr.length; ++i) // check array length every time in case it changes + { + this.ClearDeathRowForSingleInstance(arr[i], type); + } + free_objectset(obj_set); + this.redraw = true; + }; + Runtime.prototype.ClearDeathRowForSingleInstance = function (inst, type) + { + var i, len, binst; + for (i = 0, len = this.destroycallbacks.length; i < len; ++i) + this.destroycallbacks[i](inst); + if (inst.collcells) + { + type.collision_grid.update(inst, inst.collcells, null); + } + var layer = inst.layer; + if (layer) + { + layer.removeFromInstanceList(inst, true); // remove from both instance list and render grid + } + if (inst.behavior_insts) + { + for (i = 0, len = inst.behavior_insts.length; i < len; ++i) + { + binst = inst.behavior_insts[i]; + if (binst.onDestroy) + binst.onDestroy(); + binst.behavior.my_instances.remove(inst); + } + } + this.objects_to_pretick.remove(inst); + this.objects_to_tick.remove(inst); + this.objects_to_tick2.remove(inst); + if (inst.onDestroy) + inst.onDestroy(); + if (this.objectsByUid.hasOwnProperty(inst.uid.toString())) + delete this.objectsByUid[inst.uid.toString()]; + this.objectcount--; + if (type.deadCache.length < 100) + type.deadCache.push(inst); + }; + Runtime.prototype.createInstance = function (type, layer, sx, sy) + { + if (type.is_family) + { + var i = cr.floor(Math.random() * type.members.length); + return this.createInstance(type.members[i], layer, sx, sy); + } + if (!type.default_instance) + { + return null; + } + return this.createInstanceFromInit(type.default_instance, layer, false, sx, sy, false); + }; + var all_behaviors = []; + Runtime.prototype.createInstanceFromInit = function (initial_inst, layer, is_startup_instance, sx, sy, skip_siblings) + { + var i, len, j, lenj, p, effect_fallback, x, y; + if (!initial_inst) + return null; + var type = this.types_by_index[initial_inst[1]]; +; +; + var is_world = type.plugin.is_world; +; + if (this.isloading && is_world && !type.isOnLoaderLayout) + return null; + if (is_world && !this.glwrap && initial_inst[0][11] === 11) + return null; + var original_layer = layer; + if (!is_world) + layer = null; + var inst; + if (type.deadCache.length) + { + inst = type.deadCache.pop(); + inst.recycled = true; + type.plugin.Instance.call(inst, type); + } + else + { + inst = new type.plugin.Instance(type); + inst.recycled = false; + } + if (is_startup_instance && !skip_siblings && !this.objectsByUid.hasOwnProperty(initial_inst[2].toString())) + inst.uid = initial_inst[2]; + else + inst.uid = this.next_uid++; + this.objectsByUid[inst.uid.toString()] = inst; + inst.puid = this.next_puid++; + inst.iid = type.instances.length; + for (i = 0, len = this.createRow.length; i < len; ++i) + { + if (this.createRow[i].type === type) + inst.iid++; + } + inst.get_iid = cr.inst_get_iid; + inst.toString = cr.inst_toString; + var initial_vars = initial_inst[3]; + if (inst.recycled) + { + cr.wipe(inst.extra); + } + else + { + inst.extra = {}; + if (typeof cr_is_preview !== "undefined") + { + inst.instance_var_names = []; + inst.instance_var_names.length = initial_vars.length; + for (i = 0, len = initial_vars.length; i < len; i++) + inst.instance_var_names[i] = initial_vars[i][1]; + } + inst.instance_vars = []; + inst.instance_vars.length = initial_vars.length; + } + for (i = 0, len = initial_vars.length; i < len; i++) + inst.instance_vars[i] = initial_vars[i][0]; + if (is_world) + { + var wm = initial_inst[0]; +; + inst.x = cr.is_undefined(sx) ? wm[0] : sx; + inst.y = cr.is_undefined(sy) ? wm[1] : sy; + inst.z = wm[2]; + inst.width = wm[3]; + inst.height = wm[4]; + inst.depth = wm[5]; + inst.angle = wm[6]; + inst.opacity = wm[7]; + inst.hotspotX = wm[8]; + inst.hotspotY = wm[9]; + inst.blend_mode = wm[10]; + effect_fallback = wm[11]; + if (!this.glwrap && type.effect_types.length) // no WebGL renderer and shaders used + inst.blend_mode = effect_fallback; // use fallback blend mode - destroy mode was handled above + inst.compositeOp = cr.effectToCompositeOp(inst.blend_mode); + if (this.gl) + cr.setGLBlend(inst, inst.blend_mode, this.gl); + if (inst.recycled) + { + for (i = 0, len = wm[12].length; i < len; i++) + { + for (j = 0, lenj = wm[12][i].length; j < lenj; j++) + inst.effect_params[i][j] = wm[12][i][j]; + } + inst.bbox.set(0, 0, 0, 0); + inst.collcells.set(0, 0, -1, -1); + inst.rendercells.set(0, 0, -1, -1); + inst.bquad.set_from_rect(inst.bbox); + cr.clearArray(inst.bbox_changed_callbacks); + } + else + { + inst.effect_params = wm[12].slice(0); + for (i = 0, len = inst.effect_params.length; i < len; i++) + inst.effect_params[i] = wm[12][i].slice(0); + inst.active_effect_types = []; + inst.active_effect_flags = []; + inst.active_effect_flags.length = type.effect_types.length; + inst.bbox = new cr.rect(0, 0, 0, 0); + inst.collcells = new cr.rect(0, 0, -1, -1); + inst.rendercells = new cr.rect(0, 0, -1, -1); + inst.bquad = new cr.quad(); + inst.bbox_changed_callbacks = []; + inst.set_bbox_changed = cr.set_bbox_changed; + inst.add_bbox_changed_callback = cr.add_bbox_changed_callback; + inst.contains_pt = cr.inst_contains_pt; + inst.update_bbox = cr.update_bbox; + inst.update_render_cell = cr.update_render_cell; + inst.update_collision_cell = cr.update_collision_cell; + inst.get_zindex = cr.inst_get_zindex; + } + inst.tilemap_exists = false; + inst.tilemap_width = 0; + inst.tilemap_height = 0; + inst.tilemap_data = null; + if (wm.length === 14) + { + inst.tilemap_exists = true; + inst.tilemap_width = wm[13][0]; + inst.tilemap_height = wm[13][1]; + inst.tilemap_data = wm[13][2]; + } + for (i = 0, len = type.effect_types.length; i < len; i++) + inst.active_effect_flags[i] = true; + inst.shaders_preserve_opaqueness = true; + inst.updateActiveEffects = cr.inst_updateActiveEffects; + inst.updateActiveEffects(); + inst.uses_shaders = !!inst.active_effect_types.length; + inst.bbox_changed = true; + inst.cell_changed = true; + type.any_cell_changed = true; + inst.visible = true; + inst.my_timescale = -1.0; + inst.layer = layer; + inst.zindex = layer.instances.length; // will be placed at top of current layer + inst.earlyz_index = 0; + if (typeof inst.collision_poly === "undefined") + inst.collision_poly = null; + inst.collisionsEnabled = true; + this.redraw = true; + } + var initial_props, binst; + cr.clearArray(all_behaviors); + for (i = 0, len = type.families.length; i < len; i++) + { + all_behaviors.push.apply(all_behaviors, type.families[i].behaviors); + } + all_behaviors.push.apply(all_behaviors, type.behaviors); + if (inst.recycled) + { + for (i = 0, len = all_behaviors.length; i < len; i++) + { + var btype = all_behaviors[i]; + binst = inst.behavior_insts[i]; + binst.recycled = true; + btype.behavior.Instance.call(binst, btype, inst); + initial_props = initial_inst[4][i]; + for (j = 0, lenj = initial_props.length; j < lenj; j++) + binst.properties[j] = initial_props[j]; + binst.onCreate(); + btype.behavior.my_instances.add(inst); + } + } + else + { + inst.behavior_insts = []; + for (i = 0, len = all_behaviors.length; i < len; i++) + { + var btype = all_behaviors[i]; + var binst = new btype.behavior.Instance(btype, inst); + binst.recycled = false; + binst.properties = initial_inst[4][i].slice(0); + binst.onCreate(); + cr.seal(binst); + inst.behavior_insts.push(binst); + btype.behavior.my_instances.add(inst); + } + } + initial_props = initial_inst[5]; + if (inst.recycled) + { + for (i = 0, len = initial_props.length; i < len; i++) + inst.properties[i] = initial_props[i]; + } + else + inst.properties = initial_props.slice(0); + this.createRow.push(inst); + this.hasPendingInstances = true; + if (layer) + { +; + layer.appendToInstanceList(inst, true); + if (layer.parallaxX !== 1 || layer.parallaxY !== 1) + type.any_instance_parallaxed = true; + } + this.objectcount++; + if (type.is_contained) + { + inst.is_contained = true; + if (inst.recycled) + cr.clearArray(inst.siblings); + else + inst.siblings = []; // note: should not include self in siblings + if (!is_startup_instance && !skip_siblings) // layout links initial instances + { + for (i = 0, len = type.container.length; i < len; i++) + { + if (type.container[i] === type) + continue; + if (!type.container[i].default_instance) + { + return null; + } + inst.siblings.push(this.createInstanceFromInit(type.container[i].default_instance, original_layer, false, is_world ? inst.x : sx, is_world ? inst.y : sy, true)); + } + for (i = 0, len = inst.siblings.length; i < len; i++) + { + inst.siblings[i].siblings.push(inst); + for (j = 0; j < len; j++) + { + if (i !== j) + inst.siblings[i].siblings.push(inst.siblings[j]); + } + } + } + } + else + { + inst.is_contained = false; + inst.siblings = null; + } + inst.onCreate(); + if (!inst.recycled) + cr.seal(inst); + for (i = 0, len = inst.behavior_insts.length; i < len; i++) + { + if (inst.behavior_insts[i].postCreate) + inst.behavior_insts[i].postCreate(); + } + return inst; + }; + Runtime.prototype.getLayerByName = function (layer_name) + { + var i, len; + for (i = 0, len = this.running_layout.layers.length; i < len; i++) + { + var layer = this.running_layout.layers[i]; + if (cr.equals_nocase(layer.name, layer_name)) + return layer; + } + return null; + }; + Runtime.prototype.getLayerByNumber = function (index) + { + index = cr.floor(index); + if (index < 0) + index = 0; + if (index >= this.running_layout.layers.length) + index = this.running_layout.layers.length - 1; + return this.running_layout.layers[index]; + }; + Runtime.prototype.getLayer = function (l) + { + if (cr.is_number(l)) + return this.getLayerByNumber(l); + else + return this.getLayerByName(l.toString()); + }; + Runtime.prototype.clearSol = function (solModifiers) + { + var i, len; + for (i = 0, len = solModifiers.length; i < len; i++) + { + solModifiers[i].getCurrentSol().select_all = true; + } + }; + Runtime.prototype.pushCleanSol = function (solModifiers) + { + var i, len; + for (i = 0, len = solModifiers.length; i < len; i++) + { + solModifiers[i].pushCleanSol(); + } + }; + Runtime.prototype.pushCopySol = function (solModifiers) + { + var i, len; + for (i = 0, len = solModifiers.length; i < len; i++) + { + solModifiers[i].pushCopySol(); + } + }; + Runtime.prototype.popSol = function (solModifiers) + { + var i, len; + for (i = 0, len = solModifiers.length; i < len; i++) + { + solModifiers[i].popSol(); + } + }; + Runtime.prototype.updateAllCells = function (type) + { + if (!type.any_cell_changed) + return; // all instances must already be up-to-date + var i, len, instances = type.instances; + for (i = 0, len = instances.length; i < len; ++i) + { + instances[i].update_collision_cell(); + } + var createRow = this.createRow; + for (i = 0, len = createRow.length; i < len; ++i) + { + if (createRow[i].type === type) + createRow[i].update_collision_cell(); + } + type.any_cell_changed = false; + }; + Runtime.prototype.getCollisionCandidates = function (layer, rtype, bbox, candidates) + { + var i, len, t; + var is_parallaxed = (layer ? (layer.parallaxX !== 1 || layer.parallaxY !== 1) : false); + if (rtype.is_family) + { + for (i = 0, len = rtype.members.length; i < len; ++i) + { + t = rtype.members[i]; + if (is_parallaxed || t.any_instance_parallaxed) + { + cr.appendArray(candidates, t.instances); + } + else + { + this.updateAllCells(t); + t.collision_grid.queryRange(bbox, candidates); + } + } + } + else + { + if (is_parallaxed || rtype.any_instance_parallaxed) + { + cr.appendArray(candidates, rtype.instances); + } + else + { + this.updateAllCells(rtype); + rtype.collision_grid.queryRange(bbox, candidates); + } + } + }; + Runtime.prototype.getTypesCollisionCandidates = function (layer, types, bbox, candidates) + { + var i, len; + for (i = 0, len = types.length; i < len; ++i) + { + this.getCollisionCandidates(layer, types[i], bbox, candidates); + } + }; + Runtime.prototype.getSolidCollisionCandidates = function (layer, bbox, candidates) + { + var solid = this.getSolidBehavior(); + if (!solid) + return null; + this.getTypesCollisionCandidates(layer, solid.my_types, bbox, candidates); + }; + Runtime.prototype.getJumpthruCollisionCandidates = function (layer, bbox, candidates) + { + var jumpthru = this.getJumpthruBehavior(); + if (!jumpthru) + return null; + this.getTypesCollisionCandidates(layer, jumpthru.my_types, bbox, candidates); + }; + Runtime.prototype.testAndSelectCanvasPointOverlap = function (type, ptx, pty, inverted) + { + var sol = type.getCurrentSol(); + var i, j, inst, len; + var orblock = this.getCurrentEventStack().current_event.orblock; + var lx, ly, arr; + if (sol.select_all) + { + if (!inverted) + { + sol.select_all = false; + cr.clearArray(sol.instances); // clear contents + } + for (i = 0, len = type.instances.length; i < len; i++) + { + inst = type.instances[i]; + inst.update_bbox(); + lx = inst.layer.canvasToLayer(ptx, pty, true); + ly = inst.layer.canvasToLayer(ptx, pty, false); + if (inst.contains_pt(lx, ly)) + { + if (inverted) + return false; + else + sol.instances.push(inst); + } + else if (orblock) + sol.else_instances.push(inst); + } + } + else + { + j = 0; + arr = (orblock ? sol.else_instances : sol.instances); + for (i = 0, len = arr.length; i < len; i++) + { + inst = arr[i]; + inst.update_bbox(); + lx = inst.layer.canvasToLayer(ptx, pty, true); + ly = inst.layer.canvasToLayer(ptx, pty, false); + if (inst.contains_pt(lx, ly)) + { + if (inverted) + return false; + else if (orblock) + sol.instances.push(inst); + else + { + sol.instances[j] = sol.instances[i]; + j++; + } + } + } + if (!inverted) + arr.length = j; + } + type.applySolToContainer(); + if (inverted) + return true; // did not find anything overlapping + else + return sol.hasObjects(); + }; + Runtime.prototype.testOverlap = function (a, b) + { + if (!a || !b || a === b || !a.collisionsEnabled || !b.collisionsEnabled) + return false; + a.update_bbox(); + b.update_bbox(); + var layera = a.layer; + var layerb = b.layer; + var different_layers = (layera !== layerb && (layera.parallaxX !== layerb.parallaxX || layerb.parallaxY !== layerb.parallaxY || layera.scale !== layerb.scale || layera.angle !== layerb.angle || layera.zoomRate !== layerb.zoomRate)); + var i, len, i2, i21, x, y, haspolya, haspolyb, polya, polyb; + if (!different_layers) // same layers: easy check + { + if (!a.bbox.intersects_rect(b.bbox)) + return false; + if (!a.bquad.intersects_quad(b.bquad)) + return false; + if (a.tilemap_exists && b.tilemap_exists) + return false; + if (a.tilemap_exists) + return this.testTilemapOverlap(a, b); + if (b.tilemap_exists) + return this.testTilemapOverlap(b, a); + haspolya = (a.collision_poly && !a.collision_poly.is_empty()); + haspolyb = (b.collision_poly && !b.collision_poly.is_empty()); + if (!haspolya && !haspolyb) + return true; + if (haspolya) + { + a.collision_poly.cache_poly(a.width, a.height, a.angle); + polya = a.collision_poly; + } + else + { + this.temp_poly.set_from_quad(a.bquad, a.x, a.y, a.width, a.height); + polya = this.temp_poly; + } + if (haspolyb) + { + b.collision_poly.cache_poly(b.width, b.height, b.angle); + polyb = b.collision_poly; + } + else + { + this.temp_poly.set_from_quad(b.bquad, b.x, b.y, b.width, b.height); + polyb = this.temp_poly; + } + return polya.intersects_poly(polyb, b.x - a.x, b.y - a.y); + } + else // different layers: need to do full translated check + { + haspolya = (a.collision_poly && !a.collision_poly.is_empty()); + haspolyb = (b.collision_poly && !b.collision_poly.is_empty()); + if (haspolya) + { + a.collision_poly.cache_poly(a.width, a.height, a.angle); + this.temp_poly.set_from_poly(a.collision_poly); + } + else + { + this.temp_poly.set_from_quad(a.bquad, a.x, a.y, a.width, a.height); + } + polya = this.temp_poly; + if (haspolyb) + { + b.collision_poly.cache_poly(b.width, b.height, b.angle); + this.temp_poly2.set_from_poly(b.collision_poly); + } + else + { + this.temp_poly2.set_from_quad(b.bquad, b.x, b.y, b.width, b.height); + } + polyb = this.temp_poly2; + for (i = 0, len = polya.pts_count; i < len; i++) + { + i2 = i * 2; + i21 = i2 + 1; + x = polya.pts_cache[i2]; + y = polya.pts_cache[i21]; + polya.pts_cache[i2] = layera.layerToCanvas(x + a.x, y + a.y, true); + polya.pts_cache[i21] = layera.layerToCanvas(x + a.x, y + a.y, false); + } + polya.update_bbox(); + for (i = 0, len = polyb.pts_count; i < len; i++) + { + i2 = i * 2; + i21 = i2 + 1; + x = polyb.pts_cache[i2]; + y = polyb.pts_cache[i21]; + polyb.pts_cache[i2] = layerb.layerToCanvas(x + b.x, y + b.y, true); + polyb.pts_cache[i21] = layerb.layerToCanvas(x + b.x, y + b.y, false); + } + polyb.update_bbox(); + return polya.intersects_poly(polyb, 0, 0); + } + }; + var tmpQuad = new cr.quad(); + var tmpRect = new cr.rect(0, 0, 0, 0); + var collrect_candidates = []; + Runtime.prototype.testTilemapOverlap = function (tm, a) + { + var i, len, c, rc; + var bbox = a.bbox; + var tmx = tm.x; + var tmy = tm.y; + tm.getCollisionRectCandidates(bbox, collrect_candidates); + var collrects = collrect_candidates; + var haspolya = (a.collision_poly && !a.collision_poly.is_empty()); + for (i = 0, len = collrects.length; i < len; ++i) + { + c = collrects[i]; + rc = c.rc; + if (bbox.intersects_rect_off(rc, tmx, tmy)) + { + tmpQuad.set_from_rect(rc); + tmpQuad.offset(tmx, tmy); + if (tmpQuad.intersects_quad(a.bquad)) + { + if (haspolya) + { + a.collision_poly.cache_poly(a.width, a.height, a.angle); + if (c.poly) + { + if (c.poly.intersects_poly(a.collision_poly, a.x - (tmx + rc.left), a.y - (tmy + rc.top))) + { + cr.clearArray(collrect_candidates); + return true; + } + } + else + { + this.temp_poly.set_from_quad(tmpQuad, 0, 0, rc.right - rc.left, rc.bottom - rc.top); + if (this.temp_poly.intersects_poly(a.collision_poly, a.x, a.y)) + { + cr.clearArray(collrect_candidates); + return true; + } + } + } + else + { + if (c.poly) + { + this.temp_poly.set_from_quad(a.bquad, 0, 0, a.width, a.height); + if (c.poly.intersects_poly(this.temp_poly, -(tmx + rc.left), -(tmy + rc.top))) + { + cr.clearArray(collrect_candidates); + return true; + } + } + else + { + cr.clearArray(collrect_candidates); + return true; + } + } + } + } + } + cr.clearArray(collrect_candidates); + return false; + }; + Runtime.prototype.testRectOverlap = function (r, b) + { + if (!b || !b.collisionsEnabled) + return false; + b.update_bbox(); + var layerb = b.layer; + var haspolyb, polyb; + if (!b.bbox.intersects_rect(r)) + return false; + if (b.tilemap_exists) + { + b.getCollisionRectCandidates(r, collrect_candidates); + var collrects = collrect_candidates; + var i, len, c, tilerc; + var tmx = b.x; + var tmy = b.y; + for (i = 0, len = collrects.length; i < len; ++i) + { + c = collrects[i]; + tilerc = c.rc; + if (r.intersects_rect_off(tilerc, tmx, tmy)) + { + if (c.poly) + { + this.temp_poly.set_from_rect(r, 0, 0); + if (c.poly.intersects_poly(this.temp_poly, -(tmx + tilerc.left), -(tmy + tilerc.top))) + { + cr.clearArray(collrect_candidates); + return true; + } + } + else + { + cr.clearArray(collrect_candidates); + return true; + } + } + } + cr.clearArray(collrect_candidates); + return false; + } + else + { + tmpQuad.set_from_rect(r); + if (!b.bquad.intersects_quad(tmpQuad)) + return false; + haspolyb = (b.collision_poly && !b.collision_poly.is_empty()); + if (!haspolyb) + return true; + b.collision_poly.cache_poly(b.width, b.height, b.angle); + tmpQuad.offset(-r.left, -r.top); + this.temp_poly.set_from_quad(tmpQuad, 0, 0, 1, 1); + return b.collision_poly.intersects_poly(this.temp_poly, r.left - b.x, r.top - b.y); + } + }; + Runtime.prototype.testSegmentOverlap = function (x1, y1, x2, y2, b) + { + if (!b || !b.collisionsEnabled) + return false; + b.update_bbox(); + var layerb = b.layer; + var haspolyb, polyb; + tmpRect.set(cr.min(x1, x2), cr.min(y1, y2), cr.max(x1, x2), cr.max(y1, y2)); + if (!b.bbox.intersects_rect(tmpRect)) + return false; + if (b.tilemap_exists) + { + b.getCollisionRectCandidates(tmpRect, collrect_candidates); + var collrects = collrect_candidates; + var i, len, c, tilerc; + var tmx = b.x; + var tmy = b.y; + for (i = 0, len = collrects.length; i < len; ++i) + { + c = collrects[i]; + tilerc = c.rc; + if (tmpRect.intersects_rect_off(tilerc, tmx, tmy)) + { + tmpQuad.set_from_rect(tilerc); + tmpQuad.offset(tmx, tmy); + if (tmpQuad.intersects_segment(x1, y1, x2, y2)) + { + if (c.poly) + { + if (c.poly.intersects_segment(tmx + tilerc.left, tmy + tilerc.top, x1, y1, x2, y2)) + { + cr.clearArray(collrect_candidates); + return true; + } + } + else + { + cr.clearArray(collrect_candidates); + return true; + } + } + } + } + cr.clearArray(collrect_candidates); + return false; + } + else + { + if (!b.bquad.intersects_segment(x1, y1, x2, y2)) + return false; + haspolyb = (b.collision_poly && !b.collision_poly.is_empty()); + if (!haspolyb) + return true; + b.collision_poly.cache_poly(b.width, b.height, b.angle); + return b.collision_poly.intersects_segment(b.x, b.y, x1, y1, x2, y2); + } + }; + Runtime.prototype.typeHasBehavior = function (t, b) + { + if (!b) + return false; + var i, len, j, lenj, f; + for (i = 0, len = t.behaviors.length; i < len; i++) + { + if (t.behaviors[i].behavior instanceof b) + return true; + } + if (!t.is_family) + { + for (i = 0, len = t.families.length; i < len; i++) + { + f = t.families[i]; + for (j = 0, lenj = f.behaviors.length; j < lenj; j++) + { + if (f.behaviors[j].behavior instanceof b) + return true; + } + } + } + return false; + }; + Runtime.prototype.typeHasNoSaveBehavior = function (t) + { + return this.typeHasBehavior(t, cr.behaviors.NoSave); + }; + Runtime.prototype.typeHasPersistBehavior = function (t) + { + return this.typeHasBehavior(t, cr.behaviors.Persist); + }; + Runtime.prototype.getSolidBehavior = function () + { + return this.solidBehavior; + }; + Runtime.prototype.getJumpthruBehavior = function () + { + return this.jumpthruBehavior; + }; + var candidates = []; + Runtime.prototype.testOverlapSolid = function (inst) + { + var i, len, s; + inst.update_bbox(); + this.getSolidCollisionCandidates(inst.layer, inst.bbox, candidates); + for (i = 0, len = candidates.length; i < len; ++i) + { + s = candidates[i]; + if (!s.extra["solidEnabled"]) + continue; + if (this.testOverlap(inst, s)) + { + cr.clearArray(candidates); + return s; + } + } + cr.clearArray(candidates); + return null; + }; + Runtime.prototype.testRectOverlapSolid = function (r) + { + var i, len, s; + this.getSolidCollisionCandidates(null, r, candidates); + for (i = 0, len = candidates.length; i < len; ++i) + { + s = candidates[i]; + if (!s.extra["solidEnabled"]) + continue; + if (this.testRectOverlap(r, s)) + { + cr.clearArray(candidates); + return s; + } + } + cr.clearArray(candidates); + return null; + }; + var jumpthru_array_ret = []; + Runtime.prototype.testOverlapJumpThru = function (inst, all) + { + var ret = null; + if (all) + { + ret = jumpthru_array_ret; + cr.clearArray(ret); + } + inst.update_bbox(); + this.getJumpthruCollisionCandidates(inst.layer, inst.bbox, candidates); + var i, len, j; + for (i = 0, len = candidates.length; i < len; ++i) + { + j = candidates[i]; + if (!j.extra["jumpthruEnabled"]) + continue; + if (this.testOverlap(inst, j)) + { + if (all) + ret.push(j); + else + { + cr.clearArray(candidates); + return j; + } + } + } + cr.clearArray(candidates); + return ret; + }; + Runtime.prototype.pushOutSolid = function (inst, xdir, ydir, dist, include_jumpthrus, specific_jumpthru) + { + var push_dist = dist || 50; + var oldx = inst.x + var oldy = inst.y; + var i; + var last_overlapped = null, secondlast_overlapped = null; + for (i = 0; i < push_dist; i++) + { + inst.x = (oldx + (xdir * i)); + inst.y = (oldy + (ydir * i)); + inst.set_bbox_changed(); + if (!this.testOverlap(inst, last_overlapped)) + { + last_overlapped = this.testOverlapSolid(inst); + if (last_overlapped) + secondlast_overlapped = last_overlapped; + if (!last_overlapped) + { + if (include_jumpthrus) + { + if (specific_jumpthru) + last_overlapped = (this.testOverlap(inst, specific_jumpthru) ? specific_jumpthru : null); + else + last_overlapped = this.testOverlapJumpThru(inst); + if (last_overlapped) + secondlast_overlapped = last_overlapped; + } + if (!last_overlapped) + { + if (secondlast_overlapped) + this.pushInFractional(inst, xdir, ydir, secondlast_overlapped, 16); + return true; + } + } + } + } + inst.x = oldx; + inst.y = oldy; + inst.set_bbox_changed(); + return false; + }; + Runtime.prototype.pushOutSolidAxis = function(inst, xdir, ydir, dist) + { + dist = dist || 50; + var oldX = inst.x; + var oldY = inst.y; + var lastOverlapped = null; + var secondLastOverlapped = null; + var i, which, sign; + for (i = 0; i < dist; ++i) + { + for (which = 0; which < 2; ++which) + { + sign = which * 2 - 1; // -1 or 1 + inst.x = oldX + (xdir * i * sign); + inst.y = oldY + (ydir * i * sign); + inst.set_bbox_changed(); + if (!this.testOverlap(inst, lastOverlapped)) + { + lastOverlapped = this.testOverlapSolid(inst); + if (lastOverlapped) + { + secondLastOverlapped = lastOverlapped; + } + else + { + if (secondLastOverlapped) + this.pushInFractional(inst, xdir * sign, ydir * sign, secondLastOverlapped, 16); + return true; + } + } + } + } + inst.x = oldX; + inst.y = oldY; + inst.set_bbox_changed(); + return false; + }; + Runtime.prototype.pushOut = function (inst, xdir, ydir, dist, otherinst) + { + var push_dist = dist || 50; + var oldx = inst.x + var oldy = inst.y; + var i; + for (i = 0; i < push_dist; i++) + { + inst.x = (oldx + (xdir * i)); + inst.y = (oldy + (ydir * i)); + inst.set_bbox_changed(); + if (!this.testOverlap(inst, otherinst)) + return true; + } + inst.x = oldx; + inst.y = oldy; + inst.set_bbox_changed(); + return false; + }; + Runtime.prototype.pushInFractional = function (inst, xdir, ydir, obj, limit) + { + var divisor = 2; + var frac; + var forward = false; + var overlapping = false; + var bestx = inst.x; + var besty = inst.y; + while (divisor <= limit) + { + frac = 1 / divisor; + divisor *= 2; + inst.x += xdir * frac * (forward ? 1 : -1); + inst.y += ydir * frac * (forward ? 1 : -1); + inst.set_bbox_changed(); + if (this.testOverlap(inst, obj)) + { + forward = true; + overlapping = true; + } + else + { + forward = false; + overlapping = false; + bestx = inst.x; + besty = inst.y; + } + } + if (overlapping) + { + inst.x = bestx; + inst.y = besty; + inst.set_bbox_changed(); + } + }; + Runtime.prototype.pushOutSolidNearest = function (inst, max_dist_) + { + var max_dist = (cr.is_undefined(max_dist_) ? 100 : max_dist_); + var dist = 0; + var oldx = inst.x + var oldy = inst.y; + var dir = 0; + var dx = 0, dy = 0; + var last_overlapped = this.testOverlapSolid(inst); + if (!last_overlapped) + return true; // already clear of solids + while (dist <= max_dist) + { + switch (dir) { + case 0: dx = 0; dy = -1; dist++; break; + case 1: dx = 1; dy = -1; break; + case 2: dx = 1; dy = 0; break; + case 3: dx = 1; dy = 1; break; + case 4: dx = 0; dy = 1; break; + case 5: dx = -1; dy = 1; break; + case 6: dx = -1; dy = 0; break; + case 7: dx = -1; dy = -1; break; + } + dir = (dir + 1) % 8; + inst.x = cr.floor(oldx + (dx * dist)); + inst.y = cr.floor(oldy + (dy * dist)); + inst.set_bbox_changed(); + if (!this.testOverlap(inst, last_overlapped)) + { + last_overlapped = this.testOverlapSolid(inst); + if (!last_overlapped) + return true; + } + } + inst.x = oldx; + inst.y = oldy; + inst.set_bbox_changed(); + return false; + }; + Runtime.prototype.registerCollision = function (a, b) + { + if (!a.collisionsEnabled || !b.collisionsEnabled) + return; + this.registered_collisions.push([a, b]); + }; + Runtime.prototype.addRegisteredCollisionCandidates = function (inst, otherType, arr) + { + var i, len, r, otherInst; + for (i = 0, len = this.registered_collisions.length; i < len; ++i) + { + r = this.registered_collisions[i]; + if (r[0] === inst) + otherInst = r[1]; + else if (r[1] === inst) + otherInst = r[0]; + else + continue; + if (otherType.is_family) + { + if (otherType.members.indexOf(otherType) === -1) + continue; + } + else + { + if (otherInst.type !== otherType) + continue; + } + if (arr.indexOf(otherInst) === -1) + arr.push(otherInst); + } + }; + Runtime.prototype.checkRegisteredCollision = function (a, b) + { + var i, len, x; + for (i = 0, len = this.registered_collisions.length; i < len; i++) + { + x = this.registered_collisions[i]; + if ((x[0] === a && x[1] === b) || (x[0] === b && x[1] === a)) + return true; + } + return false; + }; + Runtime.prototype.calculateSolidBounceAngle = function(inst, startx, starty, obj) + { + var objx = inst.x; + var objy = inst.y; + var radius = cr.max(10, cr.distanceTo(startx, starty, objx, objy)); + var startangle = cr.angleTo(startx, starty, objx, objy); + var firstsolid = obj || this.testOverlapSolid(inst); + if (!firstsolid) + return cr.clamp_angle(startangle + cr.PI); + var cursolid = firstsolid; + var i, curangle, anticlockwise_free_angle, clockwise_free_angle; + var increment = cr.to_radians(5); // 5 degree increments + for (i = 1; i < 36; i++) + { + curangle = startangle - i * increment; + inst.x = startx + Math.cos(curangle) * radius; + inst.y = starty + Math.sin(curangle) * radius; + inst.set_bbox_changed(); + if (!this.testOverlap(inst, cursolid)) + { + cursolid = obj ? null : this.testOverlapSolid(inst); + if (!cursolid) + { + anticlockwise_free_angle = curangle; + break; + } + } + } + if (i === 36) + anticlockwise_free_angle = cr.clamp_angle(startangle + cr.PI); + var cursolid = firstsolid; + for (i = 1; i < 36; i++) + { + curangle = startangle + i * increment; + inst.x = startx + Math.cos(curangle) * radius; + inst.y = starty + Math.sin(curangle) * radius; + inst.set_bbox_changed(); + if (!this.testOverlap(inst, cursolid)) + { + cursolid = obj ? null : this.testOverlapSolid(inst); + if (!cursolid) + { + clockwise_free_angle = curangle; + break; + } + } + } + if (i === 36) + clockwise_free_angle = cr.clamp_angle(startangle + cr.PI); + inst.x = objx; + inst.y = objy; + inst.set_bbox_changed(); + if (clockwise_free_angle === anticlockwise_free_angle) + return clockwise_free_angle; + var half_diff = cr.angleDiff(clockwise_free_angle, anticlockwise_free_angle) / 2; + var normal; + if (cr.angleClockwise(clockwise_free_angle, anticlockwise_free_angle)) + { + normal = cr.clamp_angle(anticlockwise_free_angle + half_diff + cr.PI); + } + else + { + normal = cr.clamp_angle(clockwise_free_angle + half_diff); + } +; + var vx = Math.cos(startangle); + var vy = Math.sin(startangle); + var nx = Math.cos(normal); + var ny = Math.sin(normal); + var v_dot_n = vx * nx + vy * ny; + var rx = vx - 2 * v_dot_n * nx; + var ry = vy - 2 * v_dot_n * ny; + return cr.angleTo(0, 0, rx, ry); + }; + var triggerSheetIndex = -1; + Runtime.prototype.trigger = function (method, inst, value /* for fast triggers */) + { +; + if (!this.running_layout) + return false; + var sheet = this.running_layout.event_sheet; + if (!sheet) + return false; // no event sheet active; nothing to trigger + var ret = false; + var r, i, len; + triggerSheetIndex++; + var deep_includes = sheet.deep_includes; + for (i = 0, len = deep_includes.length; i < len; ++i) + { + r = this.triggerOnSheet(method, inst, deep_includes[i], value); + ret = ret || r; + } + r = this.triggerOnSheet(method, inst, sheet, value); + ret = ret || r; + triggerSheetIndex--; + return ret; + }; + Runtime.prototype.triggerOnSheet = function (method, inst, sheet, value) + { + var ret = false; + var i, leni, r, families; + if (!inst) + { + r = this.triggerOnSheetForTypeName(method, inst, "system", sheet, value); + ret = ret || r; + } + else + { + r = this.triggerOnSheetForTypeName(method, inst, inst.type.name, sheet, value); + ret = ret || r; + families = inst.type.families; + for (i = 0, leni = families.length; i < leni; ++i) + { + r = this.triggerOnSheetForTypeName(method, inst, families[i].name, sheet, value); + ret = ret || r; + } + } + return ret; // true if anything got triggered + }; + Runtime.prototype.triggerOnSheetForTypeName = function (method, inst, type_name, sheet, value) + { + var i, leni; + var ret = false, ret2 = false; + var trig, index; + var fasttrigger = (typeof value !== "undefined"); + var triggers = (fasttrigger ? sheet.fasttriggers : sheet.triggers); + var obj_entry = triggers[type_name]; + if (!obj_entry) + return ret; + var triggers_list = null; + for (i = 0, leni = obj_entry.length; i < leni; ++i) + { + if (obj_entry[i].method == method) + { + triggers_list = obj_entry[i].evs; + break; + } + } + if (!triggers_list) + return ret; + var triggers_to_fire; + if (fasttrigger) + { + triggers_to_fire = triggers_list[value]; + } + else + { + triggers_to_fire = triggers_list; + } + if (!triggers_to_fire) + return null; + for (i = 0, leni = triggers_to_fire.length; i < leni; i++) + { + trig = triggers_to_fire[i][0]; + index = triggers_to_fire[i][1]; + ret2 = this.executeSingleTrigger(inst, type_name, trig, index); + ret = ret || ret2; + } + return ret; + }; + Runtime.prototype.executeSingleTrigger = function (inst, type_name, trig, index) + { + var i, leni; + var ret = false; + this.trigger_depth++; + var current_event = this.getCurrentEventStack().current_event; + if (current_event) + this.pushCleanSol(current_event.solModifiersIncludingParents); + var isrecursive = (this.trigger_depth > 1); // calling trigger from inside another trigger + this.pushCleanSol(trig.solModifiersIncludingParents); + if (isrecursive) + this.pushLocalVarStack(); + var event_stack = this.pushEventStack(trig); + event_stack.current_event = trig; + if (inst) + { + var sol = this.types[type_name].getCurrentSol(); + sol.select_all = false; + cr.clearArray(sol.instances); + sol.instances[0] = inst; + this.types[type_name].applySolToContainer(); + } + var ok_to_run = true; + if (trig.parent) + { + var temp_parents_arr = event_stack.temp_parents_arr; + var cur_parent = trig.parent; + while (cur_parent) + { + temp_parents_arr.push(cur_parent); + cur_parent = cur_parent.parent; + } + temp_parents_arr.reverse(); + for (i = 0, leni = temp_parents_arr.length; i < leni; i++) + { + if (!temp_parents_arr[i].run_pretrigger()) // parent event failed + { + ok_to_run = false; + break; + } + } + } + if (ok_to_run) + { + this.execcount++; + if (trig.orblock) + trig.run_orblocktrigger(index); + else + trig.run(); + ret = ret || event_stack.last_event_true; + } + this.popEventStack(); + if (isrecursive) + this.popLocalVarStack(); + this.popSol(trig.solModifiersIncludingParents); + if (current_event) + this.popSol(current_event.solModifiersIncludingParents); + if (this.hasPendingInstances && this.isInOnDestroy === 0 && triggerSheetIndex === 0 && !this.isRunningEvents) + { + this.ClearDeathRow(); + } + this.trigger_depth--; + return ret; + }; + Runtime.prototype.getCurrentCondition = function () + { + var evinfo = this.getCurrentEventStack(); + return evinfo.current_event.conditions[evinfo.cndindex]; + }; + Runtime.prototype.getCurrentConditionObjectType = function () + { + var cnd = this.getCurrentCondition(); + return cnd.type; + }; + Runtime.prototype.isCurrentConditionFirst = function () + { + var evinfo = this.getCurrentEventStack(); + return evinfo.cndindex === 0; + }; + Runtime.prototype.getCurrentAction = function () + { + var evinfo = this.getCurrentEventStack(); + return evinfo.current_event.actions[evinfo.actindex]; + }; + Runtime.prototype.pushLocalVarStack = function () + { + this.localvar_stack_index++; + if (this.localvar_stack_index >= this.localvar_stack.length) + this.localvar_stack.push([]); + }; + Runtime.prototype.popLocalVarStack = function () + { +; + this.localvar_stack_index--; + }; + Runtime.prototype.getCurrentLocalVarStack = function () + { + return this.localvar_stack[this.localvar_stack_index]; + }; + Runtime.prototype.pushEventStack = function (cur_event) + { + this.event_stack_index++; + if (this.event_stack_index >= this.event_stack.length) + this.event_stack.push(new cr.eventStackFrame()); + var ret = this.getCurrentEventStack(); + ret.reset(cur_event); + return ret; + }; + Runtime.prototype.popEventStack = function () + { +; + this.event_stack_index--; + }; + Runtime.prototype.getCurrentEventStack = function () + { + return this.event_stack[this.event_stack_index]; + }; + Runtime.prototype.pushLoopStack = function (name_) + { + this.loop_stack_index++; + if (this.loop_stack_index >= this.loop_stack.length) + { + this.loop_stack.push(cr.seal({ name: name_, index: 0, stopped: false })); + } + var ret = this.getCurrentLoop(); + ret.name = name_; + ret.index = 0; + ret.stopped = false; + return ret; + }; + Runtime.prototype.popLoopStack = function () + { +; + this.loop_stack_index--; + }; + Runtime.prototype.getCurrentLoop = function () + { + return this.loop_stack[this.loop_stack_index]; + }; + Runtime.prototype.getEventVariableByName = function (name, scope) + { + var i, leni, j, lenj, sheet, e; + while (scope) + { + for (i = 0, leni = scope.subevents.length; i < leni; i++) + { + e = scope.subevents[i]; + if (e instanceof cr.eventvariable && cr.equals_nocase(name, e.name)) + return e; + } + scope = scope.parent; + } + for (i = 0, leni = this.eventsheets_by_index.length; i < leni; i++) + { + sheet = this.eventsheets_by_index[i]; + for (j = 0, lenj = sheet.events.length; j < lenj; j++) + { + e = sheet.events[j]; + if (e instanceof cr.eventvariable && cr.equals_nocase(name, e.name)) + return e; + } + } + return null; + }; + Runtime.prototype.getLayoutBySid = function (sid_) + { + var i, len; + for (i = 0, len = this.layouts_by_index.length; i < len; i++) + { + if (this.layouts_by_index[i].sid === sid_) + return this.layouts_by_index[i]; + } + return null; + }; + Runtime.prototype.getObjectTypeBySid = function (sid_) + { + var i, len; + for (i = 0, len = this.types_by_index.length; i < len; i++) + { + if (this.types_by_index[i].sid === sid_) + return this.types_by_index[i]; + } + return null; + }; + Runtime.prototype.getGroupBySid = function (sid_) + { + var i, len; + for (i = 0, len = this.allGroups.length; i < len; i++) + { + if (this.allGroups[i].sid === sid_) + return this.allGroups[i]; + } + return null; + }; + Runtime.prototype.doCanvasSnapshot = function (format_, quality_) + { + this.snapshotCanvas = [format_, quality_]; + this.redraw = true; // force redraw so snapshot is always taken + }; + function IsIndexedDBAvailable() + { + try { + return !!window.indexedDB; + } + catch (e) + { + return false; + } + }; + function makeSaveDb(e) + { + var db = e.target.result; + db.createObjectStore("saves", { keyPath: "slot" }); + }; + function IndexedDB_WriteSlot(slot_, data_, oncomplete_, onerror_) + { + try { + var request = indexedDB.open("_C2SaveStates"); + request.onupgradeneeded = makeSaveDb; + request.onerror = onerror_; + request.onsuccess = function (e) + { + var db = e.target.result; + db.onerror = onerror_; + var transaction = db.transaction(["saves"], "readwrite"); + var objectStore = transaction.objectStore("saves"); + var putReq = objectStore.put({"slot": slot_, "data": data_ }); + putReq.onsuccess = oncomplete_; + }; + } + catch (err) + { + onerror_(err); + } + }; + function IndexedDB_ReadSlot(slot_, oncomplete_, onerror_) + { + try { + var request = indexedDB.open("_C2SaveStates"); + request.onupgradeneeded = makeSaveDb; + request.onerror = onerror_; + request.onsuccess = function (e) + { + var db = e.target.result; + db.onerror = onerror_; + var transaction = db.transaction(["saves"]); + var objectStore = transaction.objectStore("saves"); + var readReq = objectStore.get(slot_); + readReq.onsuccess = function (e) + { + if (readReq.result) + oncomplete_(readReq.result["data"]); + else + oncomplete_(null); + }; + }; + } + catch (err) + { + onerror_(err); + } + }; + Runtime.prototype.signalContinuousPreview = function () + { + this.signalledContinuousPreview = true; + }; + function doContinuousPreviewReload() + { + cr.logexport("Reloading for continuous preview"); + if (!!window["c2cocoonjs"]) + { + CocoonJS["App"]["reload"](); + } + else + { + if (window.location.search.indexOf("continuous") > -1) + window.location.reload(true); + else + window.location = window.location + "?continuous"; + } + }; + Runtime.prototype.handleSaveLoad = function () + { + var self = this; + var savingToSlot = this.saveToSlot; + var savingJson = this.lastSaveJson; + var loadingFromSlot = this.loadFromSlot; + var continuous = false; + if (this.signalledContinuousPreview) + { + continuous = true; + savingToSlot = "__c2_continuouspreview"; + this.signalledContinuousPreview = false; + } + if (savingToSlot.length) + { + this.ClearDeathRow(); + savingJson = this.saveToJSONString(); + if (IsIndexedDBAvailable() && !this.isCocoonJs) + { + IndexedDB_WriteSlot(savingToSlot, savingJson, function () + { + cr.logexport("Saved state to IndexedDB storage (" + savingJson.length + " bytes)"); + self.lastSaveJson = savingJson; + self.trigger(cr.system_object.prototype.cnds.OnSaveComplete, null); + self.lastSaveJson = ""; + if (continuous) + doContinuousPreviewReload(); + }, function (e) + { + try { + localStorage.setItem("__c2save_" + savingToSlot, savingJson); + cr.logexport("Saved state to WebStorage (" + savingJson.length + " bytes)"); + self.lastSaveJson = savingJson; + self.trigger(cr.system_object.prototype.cnds.OnSaveComplete, null); + self.lastSaveJson = ""; + if (continuous) + doContinuousPreviewReload(); + } + catch (f) + { + cr.logexport("Failed to save game state: " + e + "; " + f); + self.trigger(cr.system_object.prototype.cnds.OnSaveFailed, null); + } + }); + } + else + { + try { + localStorage.setItem("__c2save_" + savingToSlot, savingJson); + cr.logexport("Saved state to WebStorage (" + savingJson.length + " bytes)"); + self.lastSaveJson = savingJson; + this.trigger(cr.system_object.prototype.cnds.OnSaveComplete, null); + self.lastSaveJson = ""; + if (continuous) + doContinuousPreviewReload(); + } + catch (e) + { + cr.logexport("Error saving to WebStorage: " + e); + self.trigger(cr.system_object.prototype.cnds.OnSaveFailed, null); + } + } + this.saveToSlot = ""; + this.loadFromSlot = ""; + this.loadFromJson = null; + } + if (loadingFromSlot.length) + { + if (IsIndexedDBAvailable() && !this.isCocoonJs) + { + IndexedDB_ReadSlot(loadingFromSlot, function (result_) + { + if (result_) + { + self.loadFromJson = result_; + cr.logexport("Loaded state from IndexedDB storage (" + self.loadFromJson.length + " bytes)"); + } + else + { + self.loadFromJson = localStorage.getItem("__c2save_" + loadingFromSlot) || ""; + cr.logexport("Loaded state from WebStorage (" + self.loadFromJson.length + " bytes)"); + } + self.suspendDrawing = false; + if (!self.loadFromJson) + { + self.loadFromJson = null; + self.trigger(cr.system_object.prototype.cnds.OnLoadFailed, null); + } + }, function (e) + { + self.loadFromJson = localStorage.getItem("__c2save_" + loadingFromSlot) || ""; + cr.logexport("Loaded state from WebStorage (" + self.loadFromJson.length + " bytes)"); + self.suspendDrawing = false; + if (!self.loadFromJson) + { + self.loadFromJson = null; + self.trigger(cr.system_object.prototype.cnds.OnLoadFailed, null); + } + }); + } + else + { + try { + this.loadFromJson = localStorage.getItem("__c2save_" + loadingFromSlot) || ""; + cr.logexport("Loaded state from WebStorage (" + this.loadFromJson.length + " bytes)"); + } + catch (e) + { + this.loadFromJson = null; + } + this.suspendDrawing = false; + if (!self.loadFromJson) + { + self.loadFromJson = null; + self.trigger(cr.system_object.prototype.cnds.OnLoadFailed, null); + } + } + this.loadFromSlot = ""; + this.saveToSlot = ""; + } + if (this.loadFromJson !== null) + { + this.ClearDeathRow(); + var ok = this.loadFromJSONString(this.loadFromJson); + if (ok) + { + this.lastSaveJson = this.loadFromJson; + this.trigger(cr.system_object.prototype.cnds.OnLoadComplete, null); + this.lastSaveJson = ""; + } + else + { + self.trigger(cr.system_object.prototype.cnds.OnLoadFailed, null); + } + this.loadFromJson = null; + } + }; + function CopyExtraObject(extra) + { + var p, ret = {}; + for (p in extra) + { + if (extra.hasOwnProperty(p)) + { + if (extra[p] instanceof cr.ObjectSet) + continue; + if (extra[p] && typeof extra[p].c2userdata !== "undefined") + continue; + if (p === "spriteCreatedDestroyCallback") + continue; + ret[p] = extra[p]; + } + } + return ret; + }; + Runtime.prototype.saveToJSONString = function() + { + var i, len, j, lenj, type, layout, typeobj, g, c, a, v, p; + var o = { + "c2save": true, + "version": 1, + "rt": { + "time": this.kahanTime.sum, + "walltime": this.wallTime.sum, + "timescale": this.timescale, + "tickcount": this.tickcount, + "execcount": this.execcount, + "next_uid": this.next_uid, + "running_layout": this.running_layout.sid, + "start_time_offset": (Date.now() - this.start_time) + }, + "types": {}, + "layouts": {}, + "events": { + "groups": {}, + "cnds": {}, + "acts": {}, + "vars": {} + } + }; + for (i = 0, len = this.types_by_index.length; i < len; i++) + { + type = this.types_by_index[i]; + if (type.is_family || this.typeHasNoSaveBehavior(type)) + continue; + typeobj = { + "instances": [] + }; + if (cr.hasAnyOwnProperty(type.extra)) + typeobj["ex"] = CopyExtraObject(type.extra); + for (j = 0, lenj = type.instances.length; j < lenj; j++) + { + typeobj["instances"].push(this.saveInstanceToJSON(type.instances[j])); + } + o["types"][type.sid.toString()] = typeobj; + } + for (i = 0, len = this.layouts_by_index.length; i < len; i++) + { + layout = this.layouts_by_index[i]; + o["layouts"][layout.sid.toString()] = layout.saveToJSON(); + } + var ogroups = o["events"]["groups"]; + for (i = 0, len = this.allGroups.length; i < len; i++) + { + g = this.allGroups[i]; + ogroups[g.sid.toString()] = this.groups_by_name[g.group_name].group_active; + } + var ocnds = o["events"]["cnds"]; + for (p in this.cndsBySid) + { + if (this.cndsBySid.hasOwnProperty(p)) + { + c = this.cndsBySid[p]; + if (cr.hasAnyOwnProperty(c.extra)) + ocnds[p] = { "ex": CopyExtraObject(c.extra) }; + } + } + var oacts = o["events"]["acts"]; + for (p in this.actsBySid) + { + if (this.actsBySid.hasOwnProperty(p)) + { + a = this.actsBySid[p]; + if (cr.hasAnyOwnProperty(a.extra)) + oacts[p] = { "ex": CopyExtraObject(a.extra) }; + } + } + var ovars = o["events"]["vars"]; + for (p in this.varsBySid) + { + if (this.varsBySid.hasOwnProperty(p)) + { + v = this.varsBySid[p]; + if (!v.is_constant && (!v.parent || v.is_static)) + ovars[p] = v.data; + } + } + o["system"] = this.system.saveToJSON(); + return JSON.stringify(o); + }; + Runtime.prototype.refreshUidMap = function () + { + var i, len, type, j, lenj, inst; + this.objectsByUid = {}; + for (i = 0, len = this.types_by_index.length; i < len; i++) + { + type = this.types_by_index[i]; + if (type.is_family) + continue; + for (j = 0, lenj = type.instances.length; j < lenj; j++) + { + inst = type.instances[j]; + this.objectsByUid[inst.uid.toString()] = inst; + } + } + }; + Runtime.prototype.loadFromJSONString = function (str) + { + var o; + try { + o = JSON.parse(str); + } + catch (e) { + return false; + } + if (!o["c2save"]) + return false; // probably not a c2 save state + if (o["version"] > 1) + return false; // from future version of c2; assume not compatible + this.isLoadingState = true; + var rt = o["rt"]; + this.kahanTime.reset(); + this.kahanTime.sum = rt["time"]; + this.wallTime.reset(); + this.wallTime.sum = rt["walltime"] || 0; + this.timescale = rt["timescale"]; + this.tickcount = rt["tickcount"]; + this.execcount = rt["execcount"]; + this.start_time = Date.now() - rt["start_time_offset"]; + var layout_sid = rt["running_layout"]; + if (layout_sid !== this.running_layout.sid) + { + var changeToLayout = this.getLayoutBySid(layout_sid); + if (changeToLayout) + this.doChangeLayout(changeToLayout); + else + return; // layout that was saved on has gone missing (deleted?) + } + var i, len, j, lenj, k, lenk, p, type, existing_insts, load_insts, inst, binst, layout, layer, g, iid, t; + var otypes = o["types"]; + for (p in otypes) + { + if (otypes.hasOwnProperty(p)) + { + type = this.getObjectTypeBySid(parseInt(p, 10)); + if (!type || type.is_family || this.typeHasNoSaveBehavior(type)) + continue; + if (otypes[p]["ex"]) + type.extra = otypes[p]["ex"]; + else + cr.wipe(type.extra); + existing_insts = type.instances; + load_insts = otypes[p]["instances"]; + for (i = 0, len = cr.min(existing_insts.length, load_insts.length); i < len; i++) + { + this.loadInstanceFromJSON(existing_insts[i], load_insts[i]); + } + for (i = load_insts.length, len = existing_insts.length; i < len; i++) + this.DestroyInstance(existing_insts[i]); + for (i = existing_insts.length, len = load_insts.length; i < len; i++) + { + layer = null; + if (type.plugin.is_world) + { + layer = this.running_layout.getLayerBySid(load_insts[i]["w"]["l"]); + if (!layer) + continue; + } + inst = this.createInstanceFromInit(type.default_instance, layer, false, 0, 0, true); + this.loadInstanceFromJSON(inst, load_insts[i]); + } + type.stale_iids = true; + } + } + this.ClearDeathRow(); + this.refreshUidMap(); + var olayouts = o["layouts"]; + for (p in olayouts) + { + if (olayouts.hasOwnProperty(p)) + { + layout = this.getLayoutBySid(parseInt(p, 10)); + if (!layout) + continue; // must've gone missing + layout.loadFromJSON(olayouts[p]); + } + } + var ogroups = o["events"]["groups"]; + for (p in ogroups) + { + if (ogroups.hasOwnProperty(p)) + { + g = this.getGroupBySid(parseInt(p, 10)); + if (g && this.groups_by_name[g.group_name]) + this.groups_by_name[g.group_name].setGroupActive(ogroups[p]); + } + } + var ocnds = o["events"]["cnds"]; + for (p in this.cndsBySid) + { + if (this.cndsBySid.hasOwnProperty(p)) + { + if (ocnds.hasOwnProperty(p)) + { + this.cndsBySid[p].extra = ocnds[p]["ex"]; + } + else + { + this.cndsBySid[p].extra = {}; + } + } + } + var oacts = o["events"]["acts"]; + for (p in this.actsBySid) + { + if (this.actsBySid.hasOwnProperty(p)) + { + if (oacts.hasOwnProperty(p)) + { + this.actsBySid[p].extra = oacts[p]["ex"]; + } + else + { + this.actsBySid[p].extra = {}; + } + } + } + var ovars = o["events"]["vars"]; + for (p in ovars) + { + if (ovars.hasOwnProperty(p) && this.varsBySid.hasOwnProperty(p)) + { + this.varsBySid[p].data = ovars[p]; + } + } + this.next_uid = rt["next_uid"]; + this.isLoadingState = false; + for (i = 0, len = this.fireOnCreateAfterLoad.length; i < len; ++i) + { + inst = this.fireOnCreateAfterLoad[i]; + this.trigger(Object.getPrototypeOf(inst.type.plugin).cnds.OnCreated, inst); + } + cr.clearArray(this.fireOnCreateAfterLoad); + this.system.loadFromJSON(o["system"]); + for (i = 0, len = this.types_by_index.length; i < len; i++) + { + type = this.types_by_index[i]; + if (type.is_family || this.typeHasNoSaveBehavior(type)) + continue; + for (j = 0, lenj = type.instances.length; j < lenj; j++) + { + inst = type.instances[j]; + if (type.is_contained) + { + iid = inst.get_iid(); + cr.clearArray(inst.siblings); + for (k = 0, lenk = type.container.length; k < lenk; k++) + { + t = type.container[k]; + if (type === t) + continue; +; + inst.siblings.push(t.instances[iid]); + } + } + if (inst.afterLoad) + inst.afterLoad(); + if (inst.behavior_insts) + { + for (k = 0, lenk = inst.behavior_insts.length; k < lenk; k++) + { + binst = inst.behavior_insts[k]; + if (binst.afterLoad) + binst.afterLoad(); + } + } + } + } + this.redraw = true; + return true; + }; + Runtime.prototype.saveInstanceToJSON = function(inst, state_only) + { + var i, len, world, behinst, et; + var type = inst.type; + var plugin = type.plugin; + var o = {}; + if (state_only) + o["c2"] = true; // mark as known json data from Construct 2 + else + o["uid"] = inst.uid; + if (cr.hasAnyOwnProperty(inst.extra)) + o["ex"] = CopyExtraObject(inst.extra); + if (inst.instance_vars && inst.instance_vars.length) + { + o["ivs"] = {}; + for (i = 0, len = inst.instance_vars.length; i < len; i++) + { + o["ivs"][inst.type.instvar_sids[i].toString()] = inst.instance_vars[i]; + } + } + if (plugin.is_world) + { + world = { + "x": inst.x, + "y": inst.y, + "w": inst.width, + "h": inst.height, + "l": inst.layer.sid, + "zi": inst.get_zindex() + }; + if (inst.angle !== 0) + world["a"] = inst.angle; + if (inst.opacity !== 1) + world["o"] = inst.opacity; + if (inst.hotspotX !== 0.5) + world["hX"] = inst.hotspotX; + if (inst.hotspotY !== 0.5) + world["hY"] = inst.hotspotY; + if (inst.blend_mode !== 0) + world["bm"] = inst.blend_mode; + if (!inst.visible) + world["v"] = inst.visible; + if (!inst.collisionsEnabled) + world["ce"] = inst.collisionsEnabled; + if (inst.my_timescale !== -1) + world["mts"] = inst.my_timescale; + if (type.effect_types.length) + { + world["fx"] = []; + for (i = 0, len = type.effect_types.length; i < len; i++) + { + et = type.effect_types[i]; + world["fx"].push({"name": et.name, + "active": inst.active_effect_flags[et.index], + "params": inst.effect_params[et.index] }); + } + } + o["w"] = world; + } + if (inst.behavior_insts && inst.behavior_insts.length) + { + o["behs"] = {}; + for (i = 0, len = inst.behavior_insts.length; i < len; i++) + { + behinst = inst.behavior_insts[i]; + if (behinst.saveToJSON) + o["behs"][behinst.type.sid.toString()] = behinst.saveToJSON(); + } + } + if (inst.saveToJSON) + o["data"] = inst.saveToJSON(); + return o; + }; + Runtime.prototype.getInstanceVarIndexBySid = function (type, sid_) + { + var i, len; + for (i = 0, len = type.instvar_sids.length; i < len; i++) + { + if (type.instvar_sids[i] === sid_) + return i; + } + return -1; + }; + Runtime.prototype.getBehaviorIndexBySid = function (inst, sid_) + { + var i, len; + for (i = 0, len = inst.behavior_insts.length; i < len; i++) + { + if (inst.behavior_insts[i].type.sid === sid_) + return i; + } + return -1; + }; + Runtime.prototype.loadInstanceFromJSON = function(inst, o, state_only) + { + var p, i, len, iv, oivs, world, fxindex, obehs, behindex, value; + var oldlayer; + var type = inst.type; + var plugin = type.plugin; + if (state_only) + { + if (!o["c2"]) + return; + } + else + inst.uid = o["uid"]; + if (o["ex"]) + inst.extra = o["ex"]; + else + cr.wipe(inst.extra); + oivs = o["ivs"]; + if (oivs) + { + for (p in oivs) + { + if (oivs.hasOwnProperty(p)) + { + iv = this.getInstanceVarIndexBySid(type, parseInt(p, 10)); + if (iv < 0 || iv >= inst.instance_vars.length) + continue; // must've gone missing + value = oivs[p]; + if (value === null) + value = NaN; + inst.instance_vars[iv] = value; + } + } + } + if (plugin.is_world) + { + world = o["w"]; + if (inst.layer.sid !== world["l"]) + { + oldlayer = inst.layer; + inst.layer = this.running_layout.getLayerBySid(world["l"]); + if (inst.layer) + { + oldlayer.removeFromInstanceList(inst, true); + inst.layer.appendToInstanceList(inst, true); + inst.set_bbox_changed(); + inst.layer.setZIndicesStaleFrom(0); + } + else + { + inst.layer = oldlayer; + if (!state_only) + this.DestroyInstance(inst); + } + } + inst.x = world["x"]; + inst.y = world["y"]; + inst.width = world["w"]; + inst.height = world["h"]; + inst.zindex = world["zi"]; + inst.angle = world.hasOwnProperty("a") ? world["a"] : 0; + inst.opacity = world.hasOwnProperty("o") ? world["o"] : 1; + inst.hotspotX = world.hasOwnProperty("hX") ? world["hX"] : 0.5; + inst.hotspotY = world.hasOwnProperty("hY") ? world["hY"] : 0.5; + inst.visible = world.hasOwnProperty("v") ? world["v"] : true; + inst.collisionsEnabled = world.hasOwnProperty("ce") ? world["ce"] : true; + inst.my_timescale = world.hasOwnProperty("mts") ? world["mts"] : -1; + inst.blend_mode = world.hasOwnProperty("bm") ? world["bm"] : 0;; + inst.compositeOp = cr.effectToCompositeOp(inst.blend_mode); + if (this.gl) + cr.setGLBlend(inst, inst.blend_mode, this.gl); + inst.set_bbox_changed(); + if (world.hasOwnProperty("fx")) + { + for (i = 0, len = world["fx"].length; i < len; i++) + { + fxindex = type.getEffectIndexByName(world["fx"][i]["name"]); + if (fxindex < 0) + continue; // must've gone missing + inst.active_effect_flags[fxindex] = world["fx"][i]["active"]; + inst.effect_params[fxindex] = world["fx"][i]["params"]; + } + } + inst.updateActiveEffects(); + } + obehs = o["behs"]; + if (obehs) + { + for (p in obehs) + { + if (obehs.hasOwnProperty(p)) + { + behindex = this.getBehaviorIndexBySid(inst, parseInt(p, 10)); + if (behindex < 0) + continue; // must've gone missing + inst.behavior_insts[behindex].loadFromJSON(obehs[p]); + } + } + } + if (o["data"]) + inst.loadFromJSON(o["data"]); + }; + Runtime.prototype.fetchLocalFileViaCordova = function (filename, successCallback, errorCallback) + { + var path = cordova["file"]["applicationDirectory"] + "www/" + filename; + window["resolveLocalFileSystemURL"](path, function (entry) + { + entry.file(successCallback, errorCallback); + }, errorCallback); + }; + Runtime.prototype.fetchLocalFileViaCordovaAsText = function (filename, successCallback, errorCallback) + { + this.fetchLocalFileViaCordova(filename, function (file) + { + var reader = new FileReader(); + reader.onload = function (e) + { + successCallback(e.target.result); + }; + reader.onerror = errorCallback; + reader.readAsText(file); + }, errorCallback); + }; + var queuedArrayBufferReads = []; + var activeArrayBufferReads = 0; + var MAX_ARRAYBUFFER_READS = 8; + Runtime.prototype.maybeStartNextArrayBufferRead = function() + { + if (!queuedArrayBufferReads.length) + return; // none left + if (activeArrayBufferReads >= MAX_ARRAYBUFFER_READS) + return; // already got maximum number in-flight + activeArrayBufferReads++; + var job = queuedArrayBufferReads.shift(); + this.doFetchLocalFileViaCordovaAsArrayBuffer(job.filename, job.successCallback, job.errorCallback); + }; + Runtime.prototype.fetchLocalFileViaCordovaAsArrayBuffer = function (filename, successCallback_, errorCallback_) + { + var self = this; + queuedArrayBufferReads.push({ + filename: filename, + successCallback: function (result) + { + activeArrayBufferReads--; + self.maybeStartNextArrayBufferRead(); + successCallback_(result); + }, + errorCallback: function (err) + { + activeArrayBufferReads--; + self.maybeStartNextArrayBufferRead(); + errorCallback_(err); + } + }); + this.maybeStartNextArrayBufferRead(); + }; + Runtime.prototype.doFetchLocalFileViaCordovaAsArrayBuffer = function (filename, successCallback, errorCallback) + { + this.fetchLocalFileViaCordova(filename, function (file) + { + var reader = new FileReader(); + reader.onload = function (e) + { + successCallback(e.target.result); + }; + reader.readAsArrayBuffer(file); + }, errorCallback); + }; + Runtime.prototype.fetchLocalFileViaCordovaAsURL = function (filename, successCallback, errorCallback) + { + var blobType = ""; + var lowername = filename.toLowerCase(); + var ext3 = lowername.substr(lowername.length - 4); + var ext4 = lowername.substr(lowername.length - 5); + if (ext3 === ".mp4") + blobType = "video/mp4"; + else if (ext4 === ".webm") + blobType = "video/webm"; // use video type but hopefully works with audio too + else if (ext3 === ".m4a") + blobType = "audio/mp4"; + else if (ext3 === ".mp3") + blobType = "audio/mpeg"; + this.fetchLocalFileViaCordovaAsArrayBuffer(filename, function (arrayBuffer) + { + var blob = new Blob([arrayBuffer], { type: blobType }); + var url = URL.createObjectURL(blob); + successCallback(url); + }, errorCallback); + }; + Runtime.prototype.isAbsoluteUrl = function (url) + { + return /^(?:[a-z]+:)?\/\//.test(url) || url.substr(0, 5) === "data:" || url.substr(0, 5) === "blob:"; + }; + Runtime.prototype.setImageSrc = function (img, src) + { + if (this.isWKWebView && !this.isAbsoluteUrl(src)) + { + this.fetchLocalFileViaCordovaAsURL(src, function (url) + { + img.src = url; + }, function (err) + { + alert("Failed to load image: " + err); + }); + } + else + { + img.src = src; + } + }; + Runtime.prototype.setCtxImageSmoothingEnabled = function (ctx, e) + { + if (typeof ctx["imageSmoothingEnabled"] !== "undefined") + { + ctx["imageSmoothingEnabled"] = e; + } + else + { + ctx["webkitImageSmoothingEnabled"] = e; + ctx["mozImageSmoothingEnabled"] = e; + ctx["msImageSmoothingEnabled"] = e; + } + }; + cr.runtime = Runtime; + cr.createRuntime = function (canvasid) + { + return new Runtime(document.getElementById(canvasid)); + }; + cr.createDCRuntime = function (w, h) + { + return new Runtime({ "dc": true, "width": w, "height": h }); + }; + window["cr_createRuntime"] = cr.createRuntime; + window["cr_createDCRuntime"] = cr.createDCRuntime; + window["createCocoonJSRuntime"] = function () + { + window["c2cocoonjs"] = true; + var canvas = document.createElement("screencanvas") || document.createElement("canvas"); + canvas.screencanvas = true; + document.body.appendChild(canvas); + var rt = new Runtime(canvas); + window["c2runtime"] = rt; + window.addEventListener("orientationchange", function () { + window["c2runtime"]["setSize"](window.innerWidth, window.innerHeight); + }); + window["c2runtime"]["setSize"](window.innerWidth, window.innerHeight); + return rt; + }; + window["createEjectaRuntime"] = function () + { + var canvas = document.getElementById("canvas"); + var rt = new Runtime(canvas); + window["c2runtime"] = rt; + window["c2runtime"]["setSize"](window.innerWidth, window.innerHeight); + return rt; + }; +}()); +window["cr_getC2Runtime"] = function() +{ + var canvas = document.getElementById("c2canvas"); + if (canvas) + return canvas["c2runtime"]; + else if (window["c2runtime"]) + return window["c2runtime"]; + else + return null; +} +window["cr_getSnapshot"] = function (format_, quality_) +{ + var runtime = window["cr_getC2Runtime"](); + if (runtime) + runtime.doCanvasSnapshot(format_, quality_); +} +window["cr_sizeCanvas"] = function(w, h) +{ + if (w === 0 || h === 0) + return; + var runtime = window["cr_getC2Runtime"](); + if (runtime) + runtime["setSize"](w, h); +} +window["cr_setSuspended"] = function(s) +{ + var runtime = window["cr_getC2Runtime"](); + if (runtime) + runtime["setSuspended"](s); +} +; +(function() +{ + function Layout(runtime, m) + { + this.runtime = runtime; + this.event_sheet = null; + this.scrollX = (this.runtime.original_width / 2); + this.scrollY = (this.runtime.original_height / 2); + this.scale = 1.0; + this.angle = 0; + this.first_visit = true; + this.name = m[0]; + this.originalWidth = m[1]; + this.originalHeight = m[2]; + this.width = m[1]; + this.height = m[2]; + this.unbounded_scrolling = m[3]; + this.sheetname = m[4]; + this.sid = m[5]; + var lm = m[6]; + var i, len; + this.layers = []; + this.initial_types = []; + for (i = 0, len = lm.length; i < len; i++) + { + var layer = new cr.layer(this, lm[i]); + layer.number = i; + cr.seal(layer); + this.layers.push(layer); + } + var im = m[7]; + this.initial_nonworld = []; + for (i = 0, len = im.length; i < len; i++) + { + var inst = im[i]; + var type = this.runtime.types_by_index[inst[1]]; +; + if (!type.default_instance) + type.default_instance = inst; + this.initial_nonworld.push(inst); + if (this.initial_types.indexOf(type) === -1) + this.initial_types.push(type); + } + this.effect_types = []; + this.active_effect_types = []; + this.shaders_preserve_opaqueness = true; + this.effect_params = []; + for (i = 0, len = m[8].length; i < len; i++) + { + this.effect_types.push({ + id: m[8][i][0], + name: m[8][i][1], + shaderindex: -1, + preservesOpaqueness: false, + active: true, + index: i + }); + this.effect_params.push(m[8][i][2].slice(0)); + } + this.updateActiveEffects(); + this.rcTex = new cr.rect(0, 0, 1, 1); + this.rcTex2 = new cr.rect(0, 0, 1, 1); + this.persist_data = {}; + }; + Layout.prototype.saveObjectToPersist = function (inst) + { + var sidStr = inst.type.sid.toString(); + if (!this.persist_data.hasOwnProperty(sidStr)) + this.persist_data[sidStr] = []; + var type_persist = this.persist_data[sidStr]; + type_persist.push(this.runtime.saveInstanceToJSON(inst)); + }; + Layout.prototype.hasOpaqueBottomLayer = function () + { + var layer = this.layers[0]; + return !layer.transparent && layer.opacity === 1.0 && !layer.forceOwnTexture && layer.visible; + }; + Layout.prototype.updateActiveEffects = function () + { + cr.clearArray(this.active_effect_types); + this.shaders_preserve_opaqueness = true; + var i, len, et; + for (i = 0, len = this.effect_types.length; i < len; i++) + { + et = this.effect_types[i]; + if (et.active) + { + this.active_effect_types.push(et); + if (!et.preservesOpaqueness) + this.shaders_preserve_opaqueness = false; + } + } + }; + Layout.prototype.getEffectByName = function (name_) + { + var i, len, et; + for (i = 0, len = this.effect_types.length; i < len; i++) + { + et = this.effect_types[i]; + if (et.name === name_) + return et; + } + return null; + }; + var created_instances = []; + function sort_by_zindex(a, b) + { + return a.zindex - b.zindex; + }; + var first_layout = true; + Layout.prototype.startRunning = function () + { + if (this.sheetname) + { + this.event_sheet = this.runtime.eventsheets[this.sheetname]; +; + this.event_sheet.updateDeepIncludes(); + } + this.runtime.running_layout = this; + this.width = this.originalWidth; + this.height = this.originalHeight; + this.scrollX = (this.runtime.original_width / 2); + this.scrollY = (this.runtime.original_height / 2); + var i, k, len, lenk, type, type_instances, initial_inst, inst, iid, t, s, p, q, type_data, layer; + for (i = 0, len = this.runtime.types_by_index.length; i < len; i++) + { + type = this.runtime.types_by_index[i]; + if (type.is_family) + continue; // instances are only transferred for their real type + type_instances = type.instances; + for (k = 0, lenk = type_instances.length; k < lenk; k++) + { + inst = type_instances[k]; + if (inst.layer) + { + var num = inst.layer.number; + if (num >= this.layers.length) + num = this.layers.length - 1; + inst.layer = this.layers[num]; + if (inst.layer.instances.indexOf(inst) === -1) + inst.layer.instances.push(inst); + inst.layer.zindices_stale = true; + } + } + } + if (!first_layout) + { + for (i = 0, len = this.layers.length; i < len; ++i) + { + this.layers[i].instances.sort(sort_by_zindex); + } + } + var layer; + cr.clearArray(created_instances); + this.boundScrolling(); + for (i = 0, len = this.layers.length; i < len; i++) + { + layer = this.layers[i]; + layer.createInitialInstances(); // fills created_instances + layer.updateViewport(null); + } + var uids_changed = false; + if (!this.first_visit) + { + for (p in this.persist_data) + { + if (this.persist_data.hasOwnProperty(p)) + { + type = this.runtime.getObjectTypeBySid(parseInt(p, 10)); + if (!type || type.is_family || !this.runtime.typeHasPersistBehavior(type)) + continue; + type_data = this.persist_data[p]; + for (i = 0, len = type_data.length; i < len; i++) + { + layer = null; + if (type.plugin.is_world) + { + layer = this.getLayerBySid(type_data[i]["w"]["l"]); + if (!layer) + continue; + } + inst = this.runtime.createInstanceFromInit(type.default_instance, layer, false, 0, 0, true); + this.runtime.loadInstanceFromJSON(inst, type_data[i]); + uids_changed = true; + created_instances.push(inst); + } + cr.clearArray(type_data); + } + } + for (i = 0, len = this.layers.length; i < len; i++) + { + this.layers[i].instances.sort(sort_by_zindex); + this.layers[i].zindices_stale = true; // in case of duplicates/holes + } + } + if (uids_changed) + { + this.runtime.ClearDeathRow(); + this.runtime.refreshUidMap(); + } + for (i = 0; i < created_instances.length; i++) + { + inst = created_instances[i]; + if (!inst.type.is_contained) + continue; + iid = inst.get_iid(); + for (k = 0, lenk = inst.type.container.length; k < lenk; k++) + { + t = inst.type.container[k]; + if (inst.type === t) + continue; + if (t.instances.length > iid) + inst.siblings.push(t.instances[iid]); + else + { + if (!t.default_instance) + { + } + else + { + s = this.runtime.createInstanceFromInit(t.default_instance, inst.layer, true, inst.x, inst.y, true); + this.runtime.ClearDeathRow(); + t.updateIIDs(); + inst.siblings.push(s); + created_instances.push(s); // come back around and link up its own instances too + } + } + } + } + for (i = 0, len = this.initial_nonworld.length; i < len; i++) + { + initial_inst = this.initial_nonworld[i]; + type = this.runtime.types_by_index[initial_inst[1]]; + if (!type.is_contained) + { + inst = this.runtime.createInstanceFromInit(this.initial_nonworld[i], null, true); + } +; + } + this.runtime.changelayout = null; + this.runtime.ClearDeathRow(); + if (this.runtime.ctx && !this.runtime.isDomFree) + { + for (i = 0, len = this.runtime.types_by_index.length; i < len; i++) + { + t = this.runtime.types_by_index[i]; + if (t.is_family || !t.instances.length || !t.preloadCanvas2D) + continue; + t.preloadCanvas2D(this.runtime.ctx); + } + } + /* + if (this.runtime.glwrap) + { + console.log("Estimated VRAM at layout start: " + this.runtime.glwrap.textureCount() + " textures, approx. " + Math.round(this.runtime.glwrap.estimateVRAM() / 1024) + " kb"); + } + */ + if (this.runtime.isLoadingState) + { + cr.shallowAssignArray(this.runtime.fireOnCreateAfterLoad, created_instances); + } + else + { + for (i = 0, len = created_instances.length; i < len; i++) + { + inst = created_instances[i]; + this.runtime.trigger(Object.getPrototypeOf(inst.type.plugin).cnds.OnCreated, inst); + } + } + cr.clearArray(created_instances); + if (!this.runtime.isLoadingState) + { + this.runtime.trigger(cr.system_object.prototype.cnds.OnLayoutStart, null); + } + this.first_visit = false; + }; + Layout.prototype.createGlobalNonWorlds = function () + { + var i, k, len, initial_inst, inst, type; + for (i = 0, k = 0, len = this.initial_nonworld.length; i < len; i++) + { + initial_inst = this.initial_nonworld[i]; + type = this.runtime.types_by_index[initial_inst[1]]; + if (type.global) + { + if (!type.is_contained) + { + inst = this.runtime.createInstanceFromInit(initial_inst, null, true); + } + } + else + { + this.initial_nonworld[k] = initial_inst; + k++; + } + } + cr.truncateArray(this.initial_nonworld, k); + }; + Layout.prototype.stopRunning = function () + { +; + /* + if (this.runtime.glwrap) + { + console.log("Estimated VRAM at layout end: " + this.runtime.glwrap.textureCount() + " textures, approx. " + Math.round(this.runtime.glwrap.estimateVRAM() / 1024) + " kb"); + } + */ + if (!this.runtime.isLoadingState) + { + this.runtime.trigger(cr.system_object.prototype.cnds.OnLayoutEnd, null); + } + this.runtime.isEndingLayout = true; + cr.clearArray(this.runtime.system.waits); + var i, leni, j, lenj; + var layer_instances, inst, type; + if (!this.first_visit) + { + for (i = 0, leni = this.layers.length; i < leni; i++) + { + this.layers[i].updateZIndices(); + layer_instances = this.layers[i].instances; + for (j = 0, lenj = layer_instances.length; j < lenj; j++) + { + inst = layer_instances[j]; + if (!inst.type.global) + { + if (this.runtime.typeHasPersistBehavior(inst.type)) + this.saveObjectToPersist(inst); + } + } + } + } + for (i = 0, leni = this.layers.length; i < leni; i++) + { + layer_instances = this.layers[i].instances; + for (j = 0, lenj = layer_instances.length; j < lenj; j++) + { + inst = layer_instances[j]; + if (!inst.type.global) + { + this.runtime.DestroyInstance(inst); + } + } + this.runtime.ClearDeathRow(); + cr.clearArray(layer_instances); + this.layers[i].zindices_stale = true; + } + for (i = 0, leni = this.runtime.types_by_index.length; i < leni; i++) + { + type = this.runtime.types_by_index[i]; + if (type.global || type.plugin.is_world || type.plugin.singleglobal || type.is_family) + continue; + for (j = 0, lenj = type.instances.length; j < lenj; j++) + this.runtime.DestroyInstance(type.instances[j]); + this.runtime.ClearDeathRow(); + } + first_layout = false; + this.runtime.isEndingLayout = false; + }; + var temp_rect = new cr.rect(0, 0, 0, 0); + Layout.prototype.recreateInitialObjects = function (type, x1, y1, x2, y2) + { + temp_rect.set(x1, y1, x2, y2); + var i, len; + for (i = 0, len = this.layers.length; i < len; i++) + { + this.layers[i].recreateInitialObjects(type, temp_rect); + } + }; + Layout.prototype.draw = function (ctx) + { + var layout_canvas; + var layout_ctx = ctx; + var ctx_changed = false; + var render_offscreen = !this.runtime.fullscreenScalingQuality; + if (render_offscreen) + { + if (!this.runtime.layout_canvas) + { + this.runtime.layout_canvas = document.createElement("canvas"); + layout_canvas = this.runtime.layout_canvas; + layout_canvas.width = this.runtime.draw_width; + layout_canvas.height = this.runtime.draw_height; + this.runtime.layout_ctx = layout_canvas.getContext("2d"); + ctx_changed = true; + } + layout_canvas = this.runtime.layout_canvas; + layout_ctx = this.runtime.layout_ctx; + if (layout_canvas.width !== this.runtime.draw_width) + { + layout_canvas.width = this.runtime.draw_width; + ctx_changed = true; + } + if (layout_canvas.height !== this.runtime.draw_height) + { + layout_canvas.height = this.runtime.draw_height; + ctx_changed = true; + } + if (ctx_changed) + { + this.runtime.setCtxImageSmoothingEnabled(layout_ctx, this.runtime.linearSampling); + } + } + layout_ctx.globalAlpha = 1; + layout_ctx.globalCompositeOperation = "source-over"; + if (this.runtime.clearBackground && !this.hasOpaqueBottomLayer()) + layout_ctx.clearRect(0, 0, this.runtime.draw_width, this.runtime.draw_height); + var i, len, l; + for (i = 0, len = this.layers.length; i < len; i++) + { + l = this.layers[i]; + if (l.visible && l.opacity > 0 && l.blend_mode !== 11 && (l.instances.length || !l.transparent)) + l.draw(layout_ctx); + else + l.updateViewport(null); // even if not drawing, keep viewport up to date + } + if (render_offscreen) + { + ctx.drawImage(layout_canvas, 0, 0, this.runtime.width, this.runtime.height); + } + }; + Layout.prototype.drawGL_earlyZPass = function (glw) + { + glw.setEarlyZPass(true); + if (!this.runtime.layout_tex) + { + this.runtime.layout_tex = glw.createEmptyTexture(this.runtime.draw_width, this.runtime.draw_height, this.runtime.linearSampling); + } + if (this.runtime.layout_tex.c2width !== this.runtime.draw_width || this.runtime.layout_tex.c2height !== this.runtime.draw_height) + { + glw.deleteTexture(this.runtime.layout_tex); + this.runtime.layout_tex = glw.createEmptyTexture(this.runtime.draw_width, this.runtime.draw_height, this.runtime.linearSampling); + } + glw.setRenderingToTexture(this.runtime.layout_tex); + if (!this.runtime.fullscreenScalingQuality) + { + glw.setSize(this.runtime.draw_width, this.runtime.draw_height); + } + var i, l; + for (i = this.layers.length - 1; i >= 0; --i) + { + l = this.layers[i]; + if (l.visible && l.opacity === 1 && l.shaders_preserve_opaqueness && + l.blend_mode === 0 && (l.instances.length || !l.transparent)) + { + l.drawGL_earlyZPass(glw); + } + else + { + l.updateViewport(null); // even if not drawing, keep viewport up to date + } + } + glw.setEarlyZPass(false); + }; + Layout.prototype.drawGL = function (glw) + { + var render_to_texture = (this.active_effect_types.length > 0 || + this.runtime.uses_background_blending || + !this.runtime.fullscreenScalingQuality || + this.runtime.enableFrontToBack); + if (render_to_texture) + { + if (!this.runtime.layout_tex) + { + this.runtime.layout_tex = glw.createEmptyTexture(this.runtime.draw_width, this.runtime.draw_height, this.runtime.linearSampling); + } + if (this.runtime.layout_tex.c2width !== this.runtime.draw_width || this.runtime.layout_tex.c2height !== this.runtime.draw_height) + { + glw.deleteTexture(this.runtime.layout_tex); + this.runtime.layout_tex = glw.createEmptyTexture(this.runtime.draw_width, this.runtime.draw_height, this.runtime.linearSampling); + } + glw.setRenderingToTexture(this.runtime.layout_tex); + if (!this.runtime.fullscreenScalingQuality) + { + glw.setSize(this.runtime.draw_width, this.runtime.draw_height); + } + } + else + { + if (this.runtime.layout_tex) + { + glw.setRenderingToTexture(null); + glw.deleteTexture(this.runtime.layout_tex); + this.runtime.layout_tex = null; + } + } + if (this.runtime.clearBackground && !this.hasOpaqueBottomLayer()) + glw.clear(0, 0, 0, 0); + var i, len, l; + for (i = 0, len = this.layers.length; i < len; i++) + { + l = this.layers[i]; + if (l.visible && l.opacity > 0 && (l.instances.length || !l.transparent)) + l.drawGL(glw); + else + l.updateViewport(null); // even if not drawing, keep viewport up to date + } + if (render_to_texture) + { + if (this.active_effect_types.length === 0 || + (this.active_effect_types.length === 1 && this.runtime.fullscreenScalingQuality)) + { + if (this.active_effect_types.length === 1) + { + var etindex = this.active_effect_types[0].index; + glw.switchProgram(this.active_effect_types[0].shaderindex); + glw.setProgramParameters(null, // backTex + 1.0 / this.runtime.draw_width, // pixelWidth + 1.0 / this.runtime.draw_height, // pixelHeight + 0.0, 0.0, // destStart + 1.0, 1.0, // destEnd + this.scale, // layerScale + this.angle, // layerAngle + 0.0, 0.0, // viewOrigin + this.runtime.draw_width / 2, this.runtime.draw_height / 2, // scrollPos + this.runtime.kahanTime.sum, // seconds + this.effect_params[etindex]); // fx parameters + if (glw.programIsAnimated(this.active_effect_types[0].shaderindex)) + this.runtime.redraw = true; + } + else + glw.switchProgram(0); + if (!this.runtime.fullscreenScalingQuality) + { + glw.setSize(this.runtime.width, this.runtime.height); + } + glw.setRenderingToTexture(null); // to backbuffer + glw.setDepthTestEnabled(false); // ignore depth buffer, copy full texture + glw.setOpacity(1); + glw.setTexture(this.runtime.layout_tex); + glw.setAlphaBlend(); + glw.resetModelView(); + glw.updateModelView(); + var halfw = this.runtime.width / 2; + var halfh = this.runtime.height / 2; + glw.quad(-halfw, halfh, halfw, halfh, halfw, -halfh, -halfw, -halfh); + glw.setTexture(null); + glw.setDepthTestEnabled(true); // turn depth test back on + } + else + { + this.renderEffectChain(glw, null, null, null); + } + } + }; + Layout.prototype.getRenderTarget = function() + { + if (this.active_effect_types.length > 0 || + this.runtime.uses_background_blending || + !this.runtime.fullscreenScalingQuality || + this.runtime.enableFrontToBack) + { + return this.runtime.layout_tex; + } + else + { + return null; + } + }; + Layout.prototype.getMinLayerScale = function () + { + var m = this.layers[0].getScale(); + var i, len, l; + for (i = 1, len = this.layers.length; i < len; i++) + { + l = this.layers[i]; + if (l.parallaxX === 0 && l.parallaxY === 0) + continue; + if (l.getScale() < m) + m = l.getScale(); + } + return m; + }; + Layout.prototype.scrollToX = function (x) + { + if (!this.unbounded_scrolling) + { + var widthBoundary = (this.runtime.draw_width * (1 / this.getMinLayerScale()) / 2); + if (x > this.width - widthBoundary) + x = this.width - widthBoundary; + if (x < widthBoundary) + x = widthBoundary; + } + if (this.scrollX !== x) + { + this.scrollX = x; + this.runtime.redraw = true; + } + }; + Layout.prototype.scrollToY = function (y) + { + if (!this.unbounded_scrolling) + { + var heightBoundary = (this.runtime.draw_height * (1 / this.getMinLayerScale()) / 2); + if (y > this.height - heightBoundary) + y = this.height - heightBoundary; + if (y < heightBoundary) + y = heightBoundary; + } + if (this.scrollY !== y) + { + this.scrollY = y; + this.runtime.redraw = true; + } + }; + Layout.prototype.boundScrolling = function () + { + this.scrollToX(this.scrollX); + this.scrollToY(this.scrollY); + }; + Layout.prototype.renderEffectChain = function (glw, layer, inst, rendertarget) + { + var active_effect_types = inst ? + inst.active_effect_types : + layer ? + layer.active_effect_types : + this.active_effect_types; + var layerScale = 1, layerAngle = 0, viewOriginLeft = 0, viewOriginTop = 0, viewOriginRight = this.runtime.draw_width, viewOriginBottom = this.runtime.draw_height; + if (inst) + { + layerScale = inst.layer.getScale(); + layerAngle = inst.layer.getAngle(); + viewOriginLeft = inst.layer.viewLeft; + viewOriginTop = inst.layer.viewTop; + viewOriginRight = inst.layer.viewRight; + viewOriginBottom = inst.layer.viewBottom; + } + else if (layer) + { + layerScale = layer.getScale(); + layerAngle = layer.getAngle(); + viewOriginLeft = layer.viewLeft; + viewOriginTop = layer.viewTop; + viewOriginRight = layer.viewRight; + viewOriginBottom = layer.viewBottom; + } + var fx_tex = this.runtime.fx_tex; + var i, len, last, temp, fx_index = 0, other_fx_index = 1; + var y, h; + var windowWidth = this.runtime.draw_width; + var windowHeight = this.runtime.draw_height; + var halfw = windowWidth / 2; + var halfh = windowHeight / 2; + var rcTex = layer ? layer.rcTex : this.rcTex; + var rcTex2 = layer ? layer.rcTex2 : this.rcTex2; + var screenleft = 0, clearleft = 0; + var screentop = 0, cleartop = 0; + var screenright = windowWidth, clearright = windowWidth; + var screenbottom = windowHeight, clearbottom = windowHeight; + var boxExtendHorizontal = 0; + var boxExtendVertical = 0; + var inst_layer_angle = inst ? inst.layer.getAngle() : 0; + if (inst) + { + for (i = 0, len = active_effect_types.length; i < len; i++) + { + boxExtendHorizontal += glw.getProgramBoxExtendHorizontal(active_effect_types[i].shaderindex); + boxExtendVertical += glw.getProgramBoxExtendVertical(active_effect_types[i].shaderindex); + } + var bbox = inst.bbox; + screenleft = layer.layerToCanvas(bbox.left, bbox.top, true, true); + screentop = layer.layerToCanvas(bbox.left, bbox.top, false, true); + screenright = layer.layerToCanvas(bbox.right, bbox.bottom, true, true); + screenbottom = layer.layerToCanvas(bbox.right, bbox.bottom, false, true); + if (inst_layer_angle !== 0) + { + var screentrx = layer.layerToCanvas(bbox.right, bbox.top, true, true); + var screentry = layer.layerToCanvas(bbox.right, bbox.top, false, true); + var screenblx = layer.layerToCanvas(bbox.left, bbox.bottom, true, true); + var screenbly = layer.layerToCanvas(bbox.left, bbox.bottom, false, true); + temp = Math.min(screenleft, screenright, screentrx, screenblx); + screenright = Math.max(screenleft, screenright, screentrx, screenblx); + screenleft = temp; + temp = Math.min(screentop, screenbottom, screentry, screenbly); + screenbottom = Math.max(screentop, screenbottom, screentry, screenbly); + screentop = temp; + } + screenleft -= boxExtendHorizontal; + screentop -= boxExtendVertical; + screenright += boxExtendHorizontal; + screenbottom += boxExtendVertical; + rcTex2.left = screenleft / windowWidth; + rcTex2.top = 1 - screentop / windowHeight; + rcTex2.right = screenright / windowWidth; + rcTex2.bottom = 1 - screenbottom / windowHeight; + clearleft = screenleft = cr.floor(screenleft); + cleartop = screentop = cr.floor(screentop); + clearright = screenright = cr.ceil(screenright); + clearbottom = screenbottom = cr.ceil(screenbottom); + clearleft -= boxExtendHorizontal; + cleartop -= boxExtendVertical; + clearright += boxExtendHorizontal; + clearbottom += boxExtendVertical; + if (screenleft < 0) screenleft = 0; + if (screentop < 0) screentop = 0; + if (screenright > windowWidth) screenright = windowWidth; + if (screenbottom > windowHeight) screenbottom = windowHeight; + if (clearleft < 0) clearleft = 0; + if (cleartop < 0) cleartop = 0; + if (clearright > windowWidth) clearright = windowWidth; + if (clearbottom > windowHeight) clearbottom = windowHeight; + rcTex.left = screenleft / windowWidth; + rcTex.top = 1 - screentop / windowHeight; + rcTex.right = screenright / windowWidth; + rcTex.bottom = 1 - screenbottom / windowHeight; + } + else + { + rcTex.left = rcTex2.left = 0; + rcTex.top = rcTex2.top = 0; + rcTex.right = rcTex2.right = 1; + rcTex.bottom = rcTex2.bottom = 1; + } + var pre_draw = (inst && (glw.programUsesDest(active_effect_types[0].shaderindex) || boxExtendHorizontal !== 0 || boxExtendVertical !== 0 || inst.opacity !== 1 || inst.type.plugin.must_predraw)) || (layer && !inst && layer.opacity !== 1); + glw.setAlphaBlend(); + if (pre_draw) + { + if (!fx_tex[fx_index]) + { + fx_tex[fx_index] = glw.createEmptyTexture(windowWidth, windowHeight, this.runtime.linearSampling); + } + if (fx_tex[fx_index].c2width !== windowWidth || fx_tex[fx_index].c2height !== windowHeight) + { + glw.deleteTexture(fx_tex[fx_index]); + fx_tex[fx_index] = glw.createEmptyTexture(windowWidth, windowHeight, this.runtime.linearSampling); + } + glw.switchProgram(0); + glw.setRenderingToTexture(fx_tex[fx_index]); + h = clearbottom - cleartop; + y = (windowHeight - cleartop) - h; + glw.clearRect(clearleft, y, clearright - clearleft, h); + if (inst) + { + inst.drawGL(glw); + } + else + { + glw.setTexture(this.runtime.layer_tex); + glw.setOpacity(layer.opacity); + glw.resetModelView(); + glw.translate(-halfw, -halfh); + glw.updateModelView(); + glw.quadTex(screenleft, screenbottom, screenright, screenbottom, screenright, screentop, screenleft, screentop, rcTex); + } + rcTex2.left = rcTex2.top = 0; + rcTex2.right = rcTex2.bottom = 1; + if (inst) + { + temp = rcTex.top; + rcTex.top = rcTex.bottom; + rcTex.bottom = temp; + } + fx_index = 1; + other_fx_index = 0; + } + glw.setOpacity(1); + var last = active_effect_types.length - 1; + var post_draw = glw.programUsesCrossSampling(active_effect_types[last].shaderindex) || + (!layer && !inst && !this.runtime.fullscreenScalingQuality); + var etindex = 0; + for (i = 0, len = active_effect_types.length; i < len; i++) + { + if (!fx_tex[fx_index]) + { + fx_tex[fx_index] = glw.createEmptyTexture(windowWidth, windowHeight, this.runtime.linearSampling); + } + if (fx_tex[fx_index].c2width !== windowWidth || fx_tex[fx_index].c2height !== windowHeight) + { + glw.deleteTexture(fx_tex[fx_index]); + fx_tex[fx_index] = glw.createEmptyTexture(windowWidth, windowHeight, this.runtime.linearSampling); + } + glw.switchProgram(active_effect_types[i].shaderindex); + etindex = active_effect_types[i].index; + if (glw.programIsAnimated(active_effect_types[i].shaderindex)) + this.runtime.redraw = true; + if (i == 0 && !pre_draw) + { + glw.setRenderingToTexture(fx_tex[fx_index]); + h = clearbottom - cleartop; + y = (windowHeight - cleartop) - h; + glw.clearRect(clearleft, y, clearright - clearleft, h); + if (inst) + { + var pixelWidth; + var pixelHeight; + if (inst.curFrame && inst.curFrame.texture_img) + { + var img = inst.curFrame.texture_img; + pixelWidth = 1.0 / img.width; + pixelHeight = 1.0 / img.height; + } + else + { + pixelWidth = 1.0 / inst.width; + pixelHeight = 1.0 / inst.height; + } + glw.setProgramParameters(rendertarget, // backTex + pixelWidth, + pixelHeight, + rcTex2.left, rcTex2.top, // destStart + rcTex2.right, rcTex2.bottom, // destEnd + layerScale, + layerAngle, + viewOriginLeft, viewOriginTop, + (viewOriginLeft + viewOriginRight) / 2, (viewOriginTop + viewOriginBottom) / 2, + this.runtime.kahanTime.sum, + inst.effect_params[etindex]); // fx params + inst.drawGL(glw); + } + else + { + glw.setProgramParameters(rendertarget, // backTex + 1.0 / windowWidth, // pixelWidth + 1.0 / windowHeight, // pixelHeight + 0.0, 0.0, // destStart + 1.0, 1.0, // destEnd + layerScale, + layerAngle, + viewOriginLeft, viewOriginTop, + (viewOriginLeft + viewOriginRight) / 2, (viewOriginTop + viewOriginBottom) / 2, + this.runtime.kahanTime.sum, + layer ? // fx params + layer.effect_params[etindex] : + this.effect_params[etindex]); + glw.setTexture(layer ? this.runtime.layer_tex : this.runtime.layout_tex); + glw.resetModelView(); + glw.translate(-halfw, -halfh); + glw.updateModelView(); + glw.quadTex(screenleft, screenbottom, screenright, screenbottom, screenright, screentop, screenleft, screentop, rcTex); + } + rcTex2.left = rcTex2.top = 0; + rcTex2.right = rcTex2.bottom = 1; + if (inst && !post_draw) + { + temp = screenbottom; + screenbottom = screentop; + screentop = temp; + } + } + else + { + glw.setProgramParameters(rendertarget, // backTex + 1.0 / windowWidth, // pixelWidth + 1.0 / windowHeight, // pixelHeight + rcTex2.left, rcTex2.top, // destStart + rcTex2.right, rcTex2.bottom, // destEnd + layerScale, + layerAngle, + viewOriginLeft, viewOriginTop, + (viewOriginLeft + viewOriginRight) / 2, (viewOriginTop + viewOriginBottom) / 2, + this.runtime.kahanTime.sum, + inst ? // fx params + inst.effect_params[etindex] : + layer ? + layer.effect_params[etindex] : + this.effect_params[etindex]); + glw.setTexture(null); + if (i === last && !post_draw) + { + if (inst) + glw.setBlend(inst.srcBlend, inst.destBlend); + else if (layer) + glw.setBlend(layer.srcBlend, layer.destBlend); + glw.setRenderingToTexture(rendertarget); + } + else + { + glw.setRenderingToTexture(fx_tex[fx_index]); + h = clearbottom - cleartop; + y = (windowHeight - cleartop) - h; + glw.clearRect(clearleft, y, clearright - clearleft, h); + } + glw.setTexture(fx_tex[other_fx_index]); + glw.resetModelView(); + glw.translate(-halfw, -halfh); + glw.updateModelView(); + glw.quadTex(screenleft, screenbottom, screenright, screenbottom, screenright, screentop, screenleft, screentop, rcTex); + if (i === last && !post_draw) + glw.setTexture(null); + } + fx_index = (fx_index === 0 ? 1 : 0); + other_fx_index = (fx_index === 0 ? 1 : 0); // will be opposite to fx_index since it was just assigned + } + if (post_draw) + { + glw.switchProgram(0); + if (inst) + glw.setBlend(inst.srcBlend, inst.destBlend); + else if (layer) + glw.setBlend(layer.srcBlend, layer.destBlend); + else + { + if (!this.runtime.fullscreenScalingQuality) + { + glw.setSize(this.runtime.width, this.runtime.height); + halfw = this.runtime.width / 2; + halfh = this.runtime.height / 2; + screenleft = 0; + screentop = 0; + screenright = this.runtime.width; + screenbottom = this.runtime.height; + } + } + glw.setRenderingToTexture(rendertarget); + glw.setTexture(fx_tex[other_fx_index]); + glw.resetModelView(); + glw.translate(-halfw, -halfh); + glw.updateModelView(); + if (inst && active_effect_types.length === 1 && !pre_draw) + glw.quadTex(screenleft, screentop, screenright, screentop, screenright, screenbottom, screenleft, screenbottom, rcTex); + else + glw.quadTex(screenleft, screenbottom, screenright, screenbottom, screenright, screentop, screenleft, screentop, rcTex); + glw.setTexture(null); + } + }; + Layout.prototype.getLayerBySid = function (sid_) + { + var i, len; + for (i = 0, len = this.layers.length; i < len; i++) + { + if (this.layers[i].sid === sid_) + return this.layers[i]; + } + return null; + }; + Layout.prototype.saveToJSON = function () + { + var i, len, layer, et; + var o = { + "sx": this.scrollX, + "sy": this.scrollY, + "s": this.scale, + "a": this.angle, + "w": this.width, + "h": this.height, + "fv": this.first_visit, // added r127 + "persist": this.persist_data, + "fx": [], + "layers": {} + }; + for (i = 0, len = this.effect_types.length; i < len; i++) + { + et = this.effect_types[i]; + o["fx"].push({"name": et.name, "active": et.active, "params": this.effect_params[et.index] }); + } + for (i = 0, len = this.layers.length; i < len; i++) + { + layer = this.layers[i]; + o["layers"][layer.sid.toString()] = layer.saveToJSON(); + } + return o; + }; + Layout.prototype.loadFromJSON = function (o) + { + var i, j, len, fx, p, layer; + this.scrollX = o["sx"]; + this.scrollY = o["sy"]; + this.scale = o["s"]; + this.angle = o["a"]; + this.width = o["w"]; + this.height = o["h"]; + this.persist_data = o["persist"]; + if (typeof o["fv"] !== "undefined") + this.first_visit = o["fv"]; + var ofx = o["fx"]; + for (i = 0, len = ofx.length; i < len; i++) + { + fx = this.getEffectByName(ofx[i]["name"]); + if (!fx) + continue; // must've gone missing + fx.active = ofx[i]["active"]; + this.effect_params[fx.index] = ofx[i]["params"]; + } + this.updateActiveEffects(); + var olayers = o["layers"]; + for (p in olayers) + { + if (olayers.hasOwnProperty(p)) + { + layer = this.getLayerBySid(parseInt(p, 10)); + if (!layer) + continue; // must've gone missing + layer.loadFromJSON(olayers[p]); + } + } + }; + cr.layout = Layout; + function Layer(layout, m) + { + this.layout = layout; + this.runtime = layout.runtime; + this.instances = []; // running instances + this.scale = 1.0; + this.angle = 0; + this.disableAngle = false; + this.tmprect = new cr.rect(0, 0, 0, 0); + this.tmpquad = new cr.quad(); + this.viewLeft = 0; + this.viewRight = 0; + this.viewTop = 0; + this.viewBottom = 0; + this.zindices_stale = false; + this.zindices_stale_from = -1; // first index that has changed, or -1 if no bound + this.clear_earlyz_index = 0; + this.name = m[0]; + this.index = m[1]; + this.sid = m[2]; + this.visible = m[3]; // initially visible + this.background_color = m[4]; + this.transparent = m[5]; + this.parallaxX = m[6]; + this.parallaxY = m[7]; + this.opacity = m[8]; + this.forceOwnTexture = m[9]; + this.useRenderCells = m[10]; + this.zoomRate = m[11]; + this.blend_mode = m[12]; + this.effect_fallback = m[13]; + this.compositeOp = "source-over"; + this.srcBlend = 0; + this.destBlend = 0; + this.render_grid = null; + this.last_render_list = alloc_arr(); + this.render_list_stale = true; + this.last_render_cells = new cr.rect(0, 0, -1, -1); + this.cur_render_cells = new cr.rect(0, 0, -1, -1); + if (this.useRenderCells) + { + this.render_grid = new cr.RenderGrid(this.runtime.original_width, this.runtime.original_height); + } + this.render_offscreen = false; + var im = m[14]; + var i, len; + this.startup_initial_instances = []; // for restoring initial_instances after load + this.initial_instances = []; + this.created_globals = []; // global object UIDs already created - for save/load to avoid recreating + for (i = 0, len = im.length; i < len; i++) + { + var inst = im[i]; + var type = this.runtime.types_by_index[inst[1]]; +; + if (!type.default_instance) + { + type.default_instance = inst; + type.default_layerindex = this.index; + } + this.initial_instances.push(inst); + if (this.layout.initial_types.indexOf(type) === -1) + this.layout.initial_types.push(type); + } + cr.shallowAssignArray(this.startup_initial_instances, this.initial_instances); + this.effect_types = []; + this.active_effect_types = []; + this.shaders_preserve_opaqueness = true; + this.effect_params = []; + for (i = 0, len = m[15].length; i < len; i++) + { + this.effect_types.push({ + id: m[15][i][0], + name: m[15][i][1], + shaderindex: -1, + preservesOpaqueness: false, + active: true, + index: i + }); + this.effect_params.push(m[15][i][2].slice(0)); + } + this.updateActiveEffects(); + this.rcTex = new cr.rect(0, 0, 1, 1); + this.rcTex2 = new cr.rect(0, 0, 1, 1); + }; + Layer.prototype.updateActiveEffects = function () + { + cr.clearArray(this.active_effect_types); + this.shaders_preserve_opaqueness = true; + var i, len, et; + for (i = 0, len = this.effect_types.length; i < len; i++) + { + et = this.effect_types[i]; + if (et.active) + { + this.active_effect_types.push(et); + if (!et.preservesOpaqueness) + this.shaders_preserve_opaqueness = false; + } + } + }; + Layer.prototype.getEffectByName = function (name_) + { + var i, len, et; + for (i = 0, len = this.effect_types.length; i < len; i++) + { + et = this.effect_types[i]; + if (et.name === name_) + return et; + } + return null; + }; + Layer.prototype.createInitialInstances = function () + { + var i, k, len, inst, initial_inst, type, keep, hasPersistBehavior; + for (i = 0, k = 0, len = this.initial_instances.length; i < len; i++) + { + initial_inst = this.initial_instances[i]; + type = this.runtime.types_by_index[initial_inst[1]]; +; + hasPersistBehavior = this.runtime.typeHasPersistBehavior(type); + keep = true; + if (!hasPersistBehavior || this.layout.first_visit) + { + inst = this.runtime.createInstanceFromInit(initial_inst, this, true); + if (!inst) + continue; // may have skipped creation due to fallback effect "destroy" + created_instances.push(inst); + if (inst.type.global) + { + keep = false; + this.created_globals.push(inst.uid); + } + } + if (keep) + { + this.initial_instances[k] = this.initial_instances[i]; + k++; + } + } + this.initial_instances.length = k; + this.runtime.ClearDeathRow(); // flushes creation row so IIDs will be correct + if (!this.runtime.glwrap && this.effect_types.length) // no WebGL renderer and shaders used + this.blend_mode = this.effect_fallback; // use fallback blend mode + this.compositeOp = cr.effectToCompositeOp(this.blend_mode); + if (this.runtime.gl) + cr.setGLBlend(this, this.blend_mode, this.runtime.gl); + this.render_list_stale = true; + }; + Layer.prototype.recreateInitialObjects = function (only_type, rc) + { + var i, len, initial_inst, type, wm, x, y, inst, j, lenj, s; + var types_by_index = this.runtime.types_by_index; + var only_type_is_family = only_type.is_family; + var only_type_members = only_type.members; + for (i = 0, len = this.initial_instances.length; i < len; ++i) + { + initial_inst = this.initial_instances[i]; + wm = initial_inst[0]; + x = wm[0]; + y = wm[1]; + if (!rc.contains_pt(x, y)) + continue; // not in the given area + type = types_by_index[initial_inst[1]]; + if (type !== only_type) + { + if (only_type_is_family) + { + if (only_type_members.indexOf(type) < 0) + continue; + } + else + continue; // only_type is not a family, and the initial inst type does not match + } + inst = this.runtime.createInstanceFromInit(initial_inst, this, false); + this.runtime.isInOnDestroy++; + this.runtime.trigger(Object.getPrototypeOf(type.plugin).cnds.OnCreated, inst); + if (inst.is_contained) + { + for (j = 0, lenj = inst.siblings.length; j < lenj; j++) + { + s = inst.siblings[i]; + this.runtime.trigger(Object.getPrototypeOf(s.type.plugin).cnds.OnCreated, s); + } + } + this.runtime.isInOnDestroy--; + } + }; + Layer.prototype.removeFromInstanceList = function (inst, remove_from_grid) + { + var index = cr.fastIndexOf(this.instances, inst); + if (index < 0) + return; // not found + if (remove_from_grid && this.useRenderCells && inst.rendercells && inst.rendercells.right >= inst.rendercells.left) + { + inst.update_bbox(); // make sure actually in its current rendercells + this.render_grid.update(inst, inst.rendercells, null); // no new range provided - remove only + inst.rendercells.set(0, 0, -1, -1); // set to invalid state to indicate not inserted + } + if (index === this.instances.length - 1) + this.instances.pop(); + else + { + cr.arrayRemove(this.instances, index); + this.setZIndicesStaleFrom(index); + } + this.render_list_stale = true; + }; + Layer.prototype.appendToInstanceList = function (inst, add_to_grid) + { +; + inst.zindex = this.instances.length; + this.instances.push(inst); + if (add_to_grid && this.useRenderCells && inst.rendercells) + { + inst.set_bbox_changed(); // will cause immediate update and new insertion to grid + } + this.render_list_stale = true; + }; + Layer.prototype.prependToInstanceList = function (inst, add_to_grid) + { +; + this.instances.unshift(inst); + this.setZIndicesStaleFrom(0); + if (add_to_grid && this.useRenderCells && inst.rendercells) + { + inst.set_bbox_changed(); // will cause immediate update and new insertion to grid + } + }; + Layer.prototype.moveInstanceAdjacent = function (inst, other, isafter) + { +; + var myZ = inst.get_zindex(); + var insertZ = other.get_zindex(); + cr.arrayRemove(this.instances, myZ); + if (myZ < insertZ) + insertZ--; + if (isafter) + insertZ++; + if (insertZ === this.instances.length) + this.instances.push(inst); + else + this.instances.splice(insertZ, 0, inst); + this.setZIndicesStaleFrom(myZ < insertZ ? myZ : insertZ); + }; + Layer.prototype.setZIndicesStaleFrom = function (index) + { + if (this.zindices_stale_from === -1) // not yet set + this.zindices_stale_from = index; + else if (index < this.zindices_stale_from) // determine minimum z index affected + this.zindices_stale_from = index; + this.zindices_stale = true; + this.render_list_stale = true; + }; + Layer.prototype.updateZIndices = function () + { + if (!this.zindices_stale) + return; + if (this.zindices_stale_from === -1) + this.zindices_stale_from = 0; + var i, len, inst; + if (this.useRenderCells) + { + for (i = this.zindices_stale_from, len = this.instances.length; i < len; ++i) + { + inst = this.instances[i]; + inst.zindex = i; + this.render_grid.markRangeChanged(inst.rendercells); + } + } + else + { + for (i = this.zindices_stale_from, len = this.instances.length; i < len; ++i) + { + this.instances[i].zindex = i; + } + } + this.zindices_stale = false; + this.zindices_stale_from = -1; + }; + Layer.prototype.getScale = function (include_aspect) + { + return this.getNormalScale() * (this.runtime.fullscreenScalingQuality || include_aspect ? this.runtime.aspect_scale : 1); + }; + Layer.prototype.getNormalScale = function () + { + return ((this.scale * this.layout.scale) - 1) * this.zoomRate + 1; + }; + Layer.prototype.getAngle = function () + { + if (this.disableAngle) + return 0; + return cr.clamp_angle(this.layout.angle + this.angle); + }; + var arr_cache = []; + function alloc_arr() + { + if (arr_cache.length) + return arr_cache.pop(); + else + return []; + } + function free_arr(a) + { + cr.clearArray(a); + arr_cache.push(a); + }; + function mergeSortedZArrays(a, b, out) + { + var i = 0, j = 0, k = 0, lena = a.length, lenb = b.length, ai, bj; + out.length = lena + lenb; + for ( ; i < lena && j < lenb; ++k) + { + ai = a[i]; + bj = b[j]; + if (ai.zindex < bj.zindex) + { + out[k] = ai; + ++i; + } + else + { + out[k] = bj; + ++j; + } + } + for ( ; i < lena; ++i, ++k) + out[k] = a[i]; + for ( ; j < lenb; ++j, ++k) + out[k] = b[j]; + }; + var next_arr = []; + function mergeAllSortedZArrays_pass(arr, first_pass) + { + var i, len, arr1, arr2, out; + for (i = 0, len = arr.length; i < len - 1; i += 2) + { + arr1 = arr[i]; + arr2 = arr[i+1]; + out = alloc_arr(); + mergeSortedZArrays(arr1, arr2, out); + if (!first_pass) + { + free_arr(arr1); + free_arr(arr2); + } + next_arr.push(out); + } + if (len % 2 === 1) + { + if (first_pass) + { + arr1 = alloc_arr(); + cr.shallowAssignArray(arr1, arr[len - 1]); + next_arr.push(arr1); + } + else + { + next_arr.push(arr[len - 1]); + } + } + cr.shallowAssignArray(arr, next_arr); + cr.clearArray(next_arr); + }; + function mergeAllSortedZArrays(arr) + { + var first_pass = true; + while (arr.length > 1) + { + mergeAllSortedZArrays_pass(arr, first_pass); + first_pass = false; + } + return arr[0]; + }; + var render_arr = []; + Layer.prototype.getRenderCellInstancesToDraw = function () + { +; + this.updateZIndices(); + this.render_grid.queryRange(this.viewLeft, this.viewTop, this.viewRight, this.viewBottom, render_arr); + if (!render_arr.length) + return alloc_arr(); + if (render_arr.length === 1) + { + var a = alloc_arr(); + cr.shallowAssignArray(a, render_arr[0]); + cr.clearArray(render_arr); + return a; + } + var draw_list = mergeAllSortedZArrays(render_arr); + cr.clearArray(render_arr); + return draw_list; + }; + Layer.prototype.draw = function (ctx) + { + this.render_offscreen = (this.forceOwnTexture || this.opacity !== 1.0 || this.blend_mode !== 0); + var layer_canvas = this.runtime.canvas; + var layer_ctx = ctx; + var ctx_changed = false; + if (this.render_offscreen) + { + if (!this.runtime.layer_canvas) + { + this.runtime.layer_canvas = document.createElement("canvas"); +; + layer_canvas = this.runtime.layer_canvas; + layer_canvas.width = this.runtime.draw_width; + layer_canvas.height = this.runtime.draw_height; + this.runtime.layer_ctx = layer_canvas.getContext("2d"); +; + ctx_changed = true; + } + layer_canvas = this.runtime.layer_canvas; + layer_ctx = this.runtime.layer_ctx; + if (layer_canvas.width !== this.runtime.draw_width) + { + layer_canvas.width = this.runtime.draw_width; + ctx_changed = true; + } + if (layer_canvas.height !== this.runtime.draw_height) + { + layer_canvas.height = this.runtime.draw_height; + ctx_changed = true; + } + if (ctx_changed) + { + this.runtime.setCtxImageSmoothingEnabled(layer_ctx, this.runtime.linearSampling); + } + if (this.transparent) + layer_ctx.clearRect(0, 0, this.runtime.draw_width, this.runtime.draw_height); + } + layer_ctx.globalAlpha = 1; + layer_ctx.globalCompositeOperation = "source-over"; + if (!this.transparent) + { + layer_ctx.fillStyle = "rgb(" + this.background_color[0] + "," + this.background_color[1] + "," + this.background_color[2] + ")"; + layer_ctx.fillRect(0, 0, this.runtime.draw_width, this.runtime.draw_height); + } + layer_ctx.save(); + this.disableAngle = true; + var px = this.canvasToLayer(0, 0, true, true); + var py = this.canvasToLayer(0, 0, false, true); + this.disableAngle = false; + if (this.runtime.pixel_rounding) + { + px = Math.round(px); + py = Math.round(py); + } + this.rotateViewport(px, py, layer_ctx); + var myscale = this.getScale(); + layer_ctx.scale(myscale, myscale); + layer_ctx.translate(-px, -py); + var instances_to_draw; + if (this.useRenderCells) + { + this.cur_render_cells.left = this.render_grid.XToCell(this.viewLeft); + this.cur_render_cells.top = this.render_grid.YToCell(this.viewTop); + this.cur_render_cells.right = this.render_grid.XToCell(this.viewRight); + this.cur_render_cells.bottom = this.render_grid.YToCell(this.viewBottom); + if (this.render_list_stale || !this.cur_render_cells.equals(this.last_render_cells)) + { + free_arr(this.last_render_list); + instances_to_draw = this.getRenderCellInstancesToDraw(); + this.render_list_stale = false; + this.last_render_cells.copy(this.cur_render_cells); + } + else + instances_to_draw = this.last_render_list; + } + else + instances_to_draw = this.instances; + var i, len, inst, last_inst = null; + for (i = 0, len = instances_to_draw.length; i < len; ++i) + { + inst = instances_to_draw[i]; + if (inst === last_inst) + continue; + this.drawInstance(inst, layer_ctx); + last_inst = inst; + } + if (this.useRenderCells) + this.last_render_list = instances_to_draw; + layer_ctx.restore(); + if (this.render_offscreen) + { + ctx.globalCompositeOperation = this.compositeOp; + ctx.globalAlpha = this.opacity; + ctx.drawImage(layer_canvas, 0, 0); + } + }; + Layer.prototype.drawInstance = function(inst, layer_ctx) + { + if (!inst.visible || inst.width === 0 || inst.height === 0) + return; + inst.update_bbox(); + var bbox = inst.bbox; + if (bbox.right < this.viewLeft || bbox.bottom < this.viewTop || bbox.left > this.viewRight || bbox.top > this.viewBottom) + return; + layer_ctx.globalCompositeOperation = inst.compositeOp; + inst.draw(layer_ctx); + }; + Layer.prototype.updateViewport = function (ctx) + { + this.disableAngle = true; + var px = this.canvasToLayer(0, 0, true, true); + var py = this.canvasToLayer(0, 0, false, true); + this.disableAngle = false; + if (this.runtime.pixel_rounding) + { + px = Math.round(px); + py = Math.round(py); + } + this.rotateViewport(px, py, ctx); + }; + Layer.prototype.rotateViewport = function (px, py, ctx) + { + var myscale = this.getScale(); + this.viewLeft = px; + this.viewTop = py; + this.viewRight = px + (this.runtime.draw_width * (1 / myscale)); + this.viewBottom = py + (this.runtime.draw_height * (1 / myscale)); + var temp; + if (this.viewLeft > this.viewRight) + { + temp = this.viewLeft; + this.viewLeft = this.viewRight; + this.viewRight = temp; + } + if (this.viewTop > this.viewBottom) + { + temp = this.viewTop; + this.viewTop = this.viewBottom; + this.viewBottom = temp; + } + var myAngle = this.getAngle(); + if (myAngle !== 0) + { + if (ctx) + { + ctx.translate(this.runtime.draw_width / 2, this.runtime.draw_height / 2); + ctx.rotate(-myAngle); + ctx.translate(this.runtime.draw_width / -2, this.runtime.draw_height / -2); + } + this.tmprect.set(this.viewLeft, this.viewTop, this.viewRight, this.viewBottom); + this.tmprect.offset((this.viewLeft + this.viewRight) / -2, (this.viewTop + this.viewBottom) / -2); + this.tmpquad.set_from_rotated_rect(this.tmprect, myAngle); + this.tmpquad.bounding_box(this.tmprect); + this.tmprect.offset((this.viewLeft + this.viewRight) / 2, (this.viewTop + this.viewBottom) / 2); + this.viewLeft = this.tmprect.left; + this.viewTop = this.tmprect.top; + this.viewRight = this.tmprect.right; + this.viewBottom = this.tmprect.bottom; + } + } + Layer.prototype.drawGL_earlyZPass = function (glw) + { + var windowWidth = this.runtime.draw_width; + var windowHeight = this.runtime.draw_height; + var shaderindex = 0; + var etindex = 0; + this.render_offscreen = this.forceOwnTexture; + if (this.render_offscreen) + { + if (!this.runtime.layer_tex) + { + this.runtime.layer_tex = glw.createEmptyTexture(this.runtime.draw_width, this.runtime.draw_height, this.runtime.linearSampling); + } + if (this.runtime.layer_tex.c2width !== this.runtime.draw_width || this.runtime.layer_tex.c2height !== this.runtime.draw_height) + { + glw.deleteTexture(this.runtime.layer_tex); + this.runtime.layer_tex = glw.createEmptyTexture(this.runtime.draw_width, this.runtime.draw_height, this.runtime.linearSampling); + } + glw.setRenderingToTexture(this.runtime.layer_tex); + } + this.disableAngle = true; + var px = this.canvasToLayer(0, 0, true, true); + var py = this.canvasToLayer(0, 0, false, true); + this.disableAngle = false; + if (this.runtime.pixel_rounding) + { + px = Math.round(px); + py = Math.round(py); + } + this.rotateViewport(px, py, null); + var myscale = this.getScale(); + glw.resetModelView(); + glw.scale(myscale, myscale); + glw.rotateZ(-this.getAngle()); + glw.translate((this.viewLeft + this.viewRight) / -2, (this.viewTop + this.viewBottom) / -2); + glw.updateModelView(); + var instances_to_draw; + if (this.useRenderCells) + { + this.cur_render_cells.left = this.render_grid.XToCell(this.viewLeft); + this.cur_render_cells.top = this.render_grid.YToCell(this.viewTop); + this.cur_render_cells.right = this.render_grid.XToCell(this.viewRight); + this.cur_render_cells.bottom = this.render_grid.YToCell(this.viewBottom); + if (this.render_list_stale || !this.cur_render_cells.equals(this.last_render_cells)) + { + free_arr(this.last_render_list); + instances_to_draw = this.getRenderCellInstancesToDraw(); + this.render_list_stale = false; + this.last_render_cells.copy(this.cur_render_cells); + } + else + instances_to_draw = this.last_render_list; + } + else + instances_to_draw = this.instances; + var i, inst, last_inst = null; + for (i = instances_to_draw.length - 1; i >= 0; --i) + { + inst = instances_to_draw[i]; + if (inst === last_inst) + continue; + this.drawInstanceGL_earlyZPass(instances_to_draw[i], glw); + last_inst = inst; + } + if (this.useRenderCells) + this.last_render_list = instances_to_draw; + if (!this.transparent) + { + this.clear_earlyz_index = this.runtime.earlyz_index++; + glw.setEarlyZIndex(this.clear_earlyz_index); + glw.setColorFillMode(1, 1, 1, 1); + glw.fullscreenQuad(); // fill remaining space in depth buffer with current Z value + glw.restoreEarlyZMode(); + } + }; + Layer.prototype.drawGL = function (glw) + { + var windowWidth = this.runtime.draw_width; + var windowHeight = this.runtime.draw_height; + var shaderindex = 0; + var etindex = 0; + this.render_offscreen = (this.forceOwnTexture || this.opacity !== 1.0 || this.active_effect_types.length > 0 || this.blend_mode !== 0); + if (this.render_offscreen) + { + if (!this.runtime.layer_tex) + { + this.runtime.layer_tex = glw.createEmptyTexture(this.runtime.draw_width, this.runtime.draw_height, this.runtime.linearSampling); + } + if (this.runtime.layer_tex.c2width !== this.runtime.draw_width || this.runtime.layer_tex.c2height !== this.runtime.draw_height) + { + glw.deleteTexture(this.runtime.layer_tex); + this.runtime.layer_tex = glw.createEmptyTexture(this.runtime.draw_width, this.runtime.draw_height, this.runtime.linearSampling); + } + glw.setRenderingToTexture(this.runtime.layer_tex); + if (this.transparent) + glw.clear(0, 0, 0, 0); + } + if (!this.transparent) + { + if (this.runtime.enableFrontToBack) + { + glw.setEarlyZIndex(this.clear_earlyz_index); + glw.setColorFillMode(this.background_color[0] / 255, this.background_color[1] / 255, this.background_color[2] / 255, 1); + glw.fullscreenQuad(); + glw.setTextureFillMode(); + } + else + { + glw.clear(this.background_color[0] / 255, this.background_color[1] / 255, this.background_color[2] / 255, 1); + } + } + this.disableAngle = true; + var px = this.canvasToLayer(0, 0, true, true); + var py = this.canvasToLayer(0, 0, false, true); + this.disableAngle = false; + if (this.runtime.pixel_rounding) + { + px = Math.round(px); + py = Math.round(py); + } + this.rotateViewport(px, py, null); + var myscale = this.getScale(); + glw.resetModelView(); + glw.scale(myscale, myscale); + glw.rotateZ(-this.getAngle()); + glw.translate((this.viewLeft + this.viewRight) / -2, (this.viewTop + this.viewBottom) / -2); + glw.updateModelView(); + var instances_to_draw; + if (this.useRenderCells) + { + this.cur_render_cells.left = this.render_grid.XToCell(this.viewLeft); + this.cur_render_cells.top = this.render_grid.YToCell(this.viewTop); + this.cur_render_cells.right = this.render_grid.XToCell(this.viewRight); + this.cur_render_cells.bottom = this.render_grid.YToCell(this.viewBottom); + if (this.render_list_stale || !this.cur_render_cells.equals(this.last_render_cells)) + { + free_arr(this.last_render_list); + instances_to_draw = this.getRenderCellInstancesToDraw(); + this.render_list_stale = false; + this.last_render_cells.copy(this.cur_render_cells); + } + else + instances_to_draw = this.last_render_list; + } + else + instances_to_draw = this.instances; + var i, len, inst, last_inst = null; + for (i = 0, len = instances_to_draw.length; i < len; ++i) + { + inst = instances_to_draw[i]; + if (inst === last_inst) + continue; + this.drawInstanceGL(instances_to_draw[i], glw); + last_inst = inst; + } + if (this.useRenderCells) + this.last_render_list = instances_to_draw; + if (this.render_offscreen) + { + shaderindex = this.active_effect_types.length ? this.active_effect_types[0].shaderindex : 0; + etindex = this.active_effect_types.length ? this.active_effect_types[0].index : 0; + if (this.active_effect_types.length === 0 || (this.active_effect_types.length === 1 && + !glw.programUsesCrossSampling(shaderindex) && this.opacity === 1)) + { + if (this.active_effect_types.length === 1) + { + glw.switchProgram(shaderindex); + glw.setProgramParameters(this.layout.getRenderTarget(), // backTex + 1.0 / this.runtime.draw_width, // pixelWidth + 1.0 / this.runtime.draw_height, // pixelHeight + 0.0, 0.0, // destStart + 1.0, 1.0, // destEnd + myscale, // layerScale + this.getAngle(), + this.viewLeft, this.viewTop, + (this.viewLeft + this.viewRight) / 2, (this.viewTop + this.viewBottom) / 2, + this.runtime.kahanTime.sum, + this.effect_params[etindex]); // fx parameters + if (glw.programIsAnimated(shaderindex)) + this.runtime.redraw = true; + } + else + glw.switchProgram(0); + glw.setRenderingToTexture(this.layout.getRenderTarget()); + glw.setOpacity(this.opacity); + glw.setTexture(this.runtime.layer_tex); + glw.setBlend(this.srcBlend, this.destBlend); + glw.resetModelView(); + glw.updateModelView(); + var halfw = this.runtime.draw_width / 2; + var halfh = this.runtime.draw_height / 2; + glw.quad(-halfw, halfh, halfw, halfh, halfw, -halfh, -halfw, -halfh); + glw.setTexture(null); + } + else + { + this.layout.renderEffectChain(glw, this, null, this.layout.getRenderTarget()); + } + } + }; + Layer.prototype.drawInstanceGL = function (inst, glw) + { +; + if (!inst.visible || inst.width === 0 || inst.height === 0) + return; + inst.update_bbox(); + var bbox = inst.bbox; + if (bbox.right < this.viewLeft || bbox.bottom < this.viewTop || bbox.left > this.viewRight || bbox.top > this.viewBottom) + return; + glw.setEarlyZIndex(inst.earlyz_index); + if (inst.uses_shaders) + { + this.drawInstanceWithShadersGL(inst, glw); + } + else + { + glw.switchProgram(0); // un-set any previously set shader + glw.setBlend(inst.srcBlend, inst.destBlend); + inst.drawGL(glw); + } + }; + Layer.prototype.drawInstanceGL_earlyZPass = function (inst, glw) + { +; + if (!inst.visible || inst.width === 0 || inst.height === 0) + return; + inst.update_bbox(); + var bbox = inst.bbox; + if (bbox.right < this.viewLeft || bbox.bottom < this.viewTop || bbox.left > this.viewRight || bbox.top > this.viewBottom) + return; + inst.earlyz_index = this.runtime.earlyz_index++; + if (inst.blend_mode !== 0 || inst.opacity !== 1 || !inst.shaders_preserve_opaqueness || !inst.drawGL_earlyZPass) + return; + glw.setEarlyZIndex(inst.earlyz_index); + inst.drawGL_earlyZPass(glw); + }; + Layer.prototype.drawInstanceWithShadersGL = function (inst, glw) + { + var shaderindex = inst.active_effect_types[0].shaderindex; + var etindex = inst.active_effect_types[0].index; + var myscale = this.getScale(); + if (inst.active_effect_types.length === 1 && !glw.programUsesCrossSampling(shaderindex) && + !glw.programExtendsBox(shaderindex) && ((!inst.angle && !inst.layer.getAngle()) || !glw.programUsesDest(shaderindex)) && + inst.opacity === 1 && !inst.type.plugin.must_predraw) + { + glw.switchProgram(shaderindex); + glw.setBlend(inst.srcBlend, inst.destBlend); + if (glw.programIsAnimated(shaderindex)) + this.runtime.redraw = true; + var destStartX = 0, destStartY = 0, destEndX = 0, destEndY = 0; + if (glw.programUsesDest(shaderindex)) + { + var bbox = inst.bbox; + var screenleft = this.layerToCanvas(bbox.left, bbox.top, true, true); + var screentop = this.layerToCanvas(bbox.left, bbox.top, false, true); + var screenright = this.layerToCanvas(bbox.right, bbox.bottom, true, true); + var screenbottom = this.layerToCanvas(bbox.right, bbox.bottom, false, true); + destStartX = screenleft / windowWidth; + destStartY = 1 - screentop / windowHeight; + destEndX = screenright / windowWidth; + destEndY = 1 - screenbottom / windowHeight; + } + var pixelWidth; + var pixelHeight; + if (inst.curFrame && inst.curFrame.texture_img) + { + var img = inst.curFrame.texture_img; + pixelWidth = 1.0 / img.width; + pixelHeight = 1.0 / img.height; + } + else + { + pixelWidth = 1.0 / inst.width; + pixelHeight = 1.0 / inst.height; + } + glw.setProgramParameters(this.render_offscreen ? this.runtime.layer_tex : this.layout.getRenderTarget(), // backTex + pixelWidth, + pixelHeight, + destStartX, destStartY, + destEndX, destEndY, + myscale, + this.getAngle(), + this.viewLeft, this.viewTop, + (this.viewLeft + this.viewRight) / 2, (this.viewTop + this.viewBottom) / 2, + this.runtime.kahanTime.sum, + inst.effect_params[etindex]); + inst.drawGL(glw); + } + else + { + this.layout.renderEffectChain(glw, this, inst, this.render_offscreen ? this.runtime.layer_tex : this.layout.getRenderTarget()); + glw.resetModelView(); + glw.scale(myscale, myscale); + glw.rotateZ(-this.getAngle()); + glw.translate((this.viewLeft + this.viewRight) / -2, (this.viewTop + this.viewBottom) / -2); + glw.updateModelView(); + } + }; + Layer.prototype.canvasToLayer = function (ptx, pty, getx, using_draw_area) + { + var multiplier = this.runtime.devicePixelRatio; + if (this.runtime.isRetina) + { + ptx *= multiplier; + pty *= multiplier; + } + var ox = this.runtime.parallax_x_origin; + var oy = this.runtime.parallax_y_origin; + var par_x = ((this.layout.scrollX - ox) * this.parallaxX) + ox; + var par_y = ((this.layout.scrollY - oy) * this.parallaxY) + oy; + var x = par_x; + var y = par_y; + var invScale = 1 / this.getScale(!using_draw_area); + if (using_draw_area) + { + x -= (this.runtime.draw_width * invScale) / 2; + y -= (this.runtime.draw_height * invScale) / 2; + } + else + { + x -= (this.runtime.width * invScale) / 2; + y -= (this.runtime.height * invScale) / 2; + } + x += ptx * invScale; + y += pty * invScale; + var a = this.getAngle(); + if (a !== 0) + { + x -= par_x; + y -= par_y; + var cosa = Math.cos(a); + var sina = Math.sin(a); + var x_temp = (x * cosa) - (y * sina); + y = (y * cosa) + (x * sina); + x = x_temp; + x += par_x; + y += par_y; + } + return getx ? x : y; + }; + Layer.prototype.layerToCanvas = function (ptx, pty, getx, using_draw_area) + { + var ox = this.runtime.parallax_x_origin; + var oy = this.runtime.parallax_y_origin; + var par_x = ((this.layout.scrollX - ox) * this.parallaxX) + ox; + var par_y = ((this.layout.scrollY - oy) * this.parallaxY) + oy; + var x = par_x; + var y = par_y; + var a = this.getAngle(); + if (a !== 0) + { + ptx -= par_x; + pty -= par_y; + var cosa = Math.cos(-a); + var sina = Math.sin(-a); + var x_temp = (ptx * cosa) - (pty * sina); + pty = (pty * cosa) + (ptx * sina); + ptx = x_temp; + ptx += par_x; + pty += par_y; + } + var invScale = 1 / this.getScale(!using_draw_area); + if (using_draw_area) + { + x -= (this.runtime.draw_width * invScale) / 2; + y -= (this.runtime.draw_height * invScale) / 2; + } + else + { + x -= (this.runtime.width * invScale) / 2; + y -= (this.runtime.height * invScale) / 2; + } + x = (ptx - x) / invScale; + y = (pty - y) / invScale; + var multiplier = this.runtime.devicePixelRatio; + if (this.runtime.isRetina && !using_draw_area) + { + x /= multiplier; + y /= multiplier; + } + return getx ? x : y; + }; + Layer.prototype.rotatePt = function (x_, y_, getx) + { + if (this.getAngle() === 0) + return getx ? x_ : y_; + var nx = this.layerToCanvas(x_, y_, true); + var ny = this.layerToCanvas(x_, y_, false); + this.disableAngle = true; + var px = this.canvasToLayer(nx, ny, true); + var py = this.canvasToLayer(nx, ny, true); + this.disableAngle = false; + return getx ? px : py; + }; + Layer.prototype.saveToJSON = function () + { + var i, len, et; + var o = { + "s": this.scale, + "a": this.angle, + "vl": this.viewLeft, + "vt": this.viewTop, + "vr": this.viewRight, + "vb": this.viewBottom, + "v": this.visible, + "bc": this.background_color, + "t": this.transparent, + "px": this.parallaxX, + "py": this.parallaxY, + "o": this.opacity, + "zr": this.zoomRate, + "fx": [], + "cg": this.created_globals, // added r197; list of global UIDs already created + "instances": [] + }; + for (i = 0, len = this.effect_types.length; i < len; i++) + { + et = this.effect_types[i]; + o["fx"].push({"name": et.name, "active": et.active, "params": this.effect_params[et.index] }); + } + return o; + }; + Layer.prototype.loadFromJSON = function (o) + { + var i, j, len, p, inst, fx; + this.scale = o["s"]; + this.angle = o["a"]; + this.viewLeft = o["vl"]; + this.viewTop = o["vt"]; + this.viewRight = o["vr"]; + this.viewBottom = o["vb"]; + this.visible = o["v"]; + this.background_color = o["bc"]; + this.transparent = o["t"]; + this.parallaxX = o["px"]; + this.parallaxY = o["py"]; + this.opacity = o["o"]; + this.zoomRate = o["zr"]; + this.created_globals = o["cg"] || []; // added r197 + cr.shallowAssignArray(this.initial_instances, this.startup_initial_instances); + var temp_set = new cr.ObjectSet(); + for (i = 0, len = this.created_globals.length; i < len; ++i) + temp_set.add(this.created_globals[i]); + for (i = 0, j = 0, len = this.initial_instances.length; i < len; ++i) + { + if (!temp_set.contains(this.initial_instances[i][2])) // UID in element 2 + { + this.initial_instances[j] = this.initial_instances[i]; + ++j; + } + } + cr.truncateArray(this.initial_instances, j); + var ofx = o["fx"]; + for (i = 0, len = ofx.length; i < len; i++) + { + fx = this.getEffectByName(ofx[i]["name"]); + if (!fx) + continue; // must've gone missing + fx.active = ofx[i]["active"]; + this.effect_params[fx.index] = ofx[i]["params"]; + } + this.updateActiveEffects(); + this.instances.sort(sort_by_zindex); + this.zindices_stale = true; + }; + cr.layer = Layer; +}()); +; +(function() +{ + var allUniqueSolModifiers = []; + function testSolsMatch(arr1, arr2) + { + var i, len = arr1.length; + switch (len) { + case 0: + return true; + case 1: + return arr1[0] === arr2[0]; + case 2: + return arr1[0] === arr2[0] && arr1[1] === arr2[1]; + default: + for (i = 0; i < len; i++) + { + if (arr1[i] !== arr2[i]) + return false; + } + return true; + } + }; + function solArraySorter(t1, t2) + { + return t1.index - t2.index; + }; + function findMatchingSolModifier(arr) + { + var i, len, u, temp, subarr; + if (arr.length === 2) + { + if (arr[0].index > arr[1].index) + { + temp = arr[0]; + arr[0] = arr[1]; + arr[1] = temp; + } + } + else if (arr.length > 2) + arr.sort(solArraySorter); // so testSolsMatch compares in same order + if (arr.length >= allUniqueSolModifiers.length) + allUniqueSolModifiers.length = arr.length + 1; + if (!allUniqueSolModifiers[arr.length]) + allUniqueSolModifiers[arr.length] = []; + subarr = allUniqueSolModifiers[arr.length]; + for (i = 0, len = subarr.length; i < len; i++) + { + u = subarr[i]; + if (testSolsMatch(arr, u)) + return u; + } + subarr.push(arr); + return arr; + }; + function EventSheet(runtime, m) + { + this.runtime = runtime; + this.triggers = {}; + this.fasttriggers = {}; + this.hasRun = false; + this.includes = new cr.ObjectSet(); // all event sheets included by this sheet, at first-level indirection only + this.deep_includes = []; // all includes from this sheet recursively, in trigger order + this.already_included_sheets = []; // used while building deep_includes + this.name = m[0]; + var em = m[1]; // events model + this.events = []; // triggers won't make it to this array + var i, len; + for (i = 0, len = em.length; i < len; i++) + this.init_event(em[i], null, this.events); + }; + EventSheet.prototype.toString = function () + { + return this.name; + }; + EventSheet.prototype.init_event = function (m, parent, nontriggers) + { + switch (m[0]) { + case 0: // event block + { + var block = new cr.eventblock(this, parent, m); + cr.seal(block); + if (block.orblock) + { + nontriggers.push(block); + var i, len; + for (i = 0, len = block.conditions.length; i < len; i++) + { + if (block.conditions[i].trigger) + this.init_trigger(block, i); + } + } + else + { + if (block.is_trigger()) + this.init_trigger(block, 0); + else + nontriggers.push(block); + } + break; + } + case 1: // variable + { + var v = new cr.eventvariable(this, parent, m); + cr.seal(v); + nontriggers.push(v); + break; + } + case 2: // include + { + var inc = new cr.eventinclude(this, parent, m); + cr.seal(inc); + nontriggers.push(inc); + break; + } + default: +; + } + }; + EventSheet.prototype.postInit = function () + { + var i, len; + for (i = 0, len = this.events.length; i < len; i++) + { + this.events[i].postInit(i < len - 1 && this.events[i + 1].is_else_block); + } + }; + EventSheet.prototype.updateDeepIncludes = function () + { + cr.clearArray(this.deep_includes); + cr.clearArray(this.already_included_sheets); + this.addDeepIncludes(this); + cr.clearArray(this.already_included_sheets); + }; + EventSheet.prototype.addDeepIncludes = function (root_sheet) + { + var i, len, inc, sheet; + var deep_includes = root_sheet.deep_includes; + var already_included_sheets = root_sheet.already_included_sheets; + var arr = this.includes.valuesRef(); + for (i = 0, len = arr.length; i < len; ++i) + { + inc = arr[i]; + sheet = inc.include_sheet; + if (!inc.isActive() || root_sheet === sheet || already_included_sheets.indexOf(sheet) > -1) + continue; + already_included_sheets.push(sheet); + sheet.addDeepIncludes(root_sheet); + deep_includes.push(sheet); + } + }; + EventSheet.prototype.run = function (from_include) + { + if (!this.runtime.resuming_breakpoint) + { + this.hasRun = true; + if (!from_include) + this.runtime.isRunningEvents = true; + } + var i, len; + for (i = 0, len = this.events.length; i < len; i++) + { + var ev = this.events[i]; + ev.run(); + this.runtime.clearSol(ev.solModifiers); + if (this.runtime.hasPendingInstances) + this.runtime.ClearDeathRow(); + } + if (!from_include) + this.runtime.isRunningEvents = false; + }; + function isPerformanceSensitiveTrigger(method) + { + if (cr.plugins_.Sprite && method === cr.plugins_.Sprite.prototype.cnds.OnFrameChanged) + { + return true; + } + return false; + }; + EventSheet.prototype.init_trigger = function (trig, index) + { + if (!trig.orblock) + this.runtime.triggers_to_postinit.push(trig); // needs to be postInit'd later + var i, len; + var cnd = trig.conditions[index]; + var type_name; + if (cnd.type) + type_name = cnd.type.name; + else + type_name = "system"; + var fasttrigger = cnd.fasttrigger; + var triggers = (fasttrigger ? this.fasttriggers : this.triggers); + if (!triggers[type_name]) + triggers[type_name] = []; + var obj_entry = triggers[type_name]; + var method = cnd.func; + if (fasttrigger) + { + if (!cnd.parameters.length) // no parameters + return; + var firstparam = cnd.parameters[0]; + if (firstparam.type !== 1 || // not a string param + firstparam.expression.type !== 2) // not a string literal node + { + return; + } + var fastevs; + var firstvalue = firstparam.expression.value.toLowerCase(); + var i, len; + for (i = 0, len = obj_entry.length; i < len; i++) + { + if (obj_entry[i].method == method) + { + fastevs = obj_entry[i].evs; + if (!fastevs[firstvalue]) + fastevs[firstvalue] = [[trig, index]]; + else + fastevs[firstvalue].push([trig, index]); + return; + } + } + fastevs = {}; + fastevs[firstvalue] = [[trig, index]]; + obj_entry.push({ method: method, evs: fastevs }); + } + else + { + for (i = 0, len = obj_entry.length; i < len; i++) + { + if (obj_entry[i].method == method) + { + obj_entry[i].evs.push([trig, index]); + return; + } + } + if (isPerformanceSensitiveTrigger(method)) + obj_entry.unshift({ method: method, evs: [[trig, index]]}); + else + obj_entry.push({ method: method, evs: [[trig, index]]}); + } + }; + cr.eventsheet = EventSheet; + function Selection(type) + { + this.type = type; + this.instances = []; // subset of picked instances + this.else_instances = []; // subset of unpicked instances + this.select_all = true; + }; + Selection.prototype.hasObjects = function () + { + if (this.select_all) + return this.type.instances.length; + else + return this.instances.length; + }; + Selection.prototype.getObjects = function () + { + if (this.select_all) + return this.type.instances; + else + return this.instances; + }; + /* + Selection.prototype.ensure_picked = function (inst, skip_siblings) + { + var i, len; + var orblock = inst.runtime.getCurrentEventStack().current_event.orblock; + if (this.select_all) + { + this.select_all = false; + if (orblock) + { + cr.shallowAssignArray(this.else_instances, inst.type.instances); + cr.arrayFindRemove(this.else_instances, inst); + } + this.instances.length = 1; + this.instances[0] = inst; + } + else + { + if (orblock) + { + i = this.else_instances.indexOf(inst); + if (i !== -1) + { + this.instances.push(this.else_instances[i]); + this.else_instances.splice(i, 1); + } + } + else + { + if (this.instances.indexOf(inst) === -1) + this.instances.push(inst); + } + } + if (!skip_siblings) + { + } + }; + */ + Selection.prototype.pick_one = function (inst) + { + if (!inst) + return; + if (inst.runtime.getCurrentEventStack().current_event.orblock) + { + if (this.select_all) + { + cr.clearArray(this.instances); + cr.shallowAssignArray(this.else_instances, inst.type.instances); + this.select_all = false; + } + var i = this.else_instances.indexOf(inst); + if (i !== -1) + { + this.instances.push(this.else_instances[i]); + this.else_instances.splice(i, 1); + } + } + else + { + this.select_all = false; + cr.clearArray(this.instances); + this.instances[0] = inst; + } + }; + cr.selection = Selection; + function EventBlock(sheet, parent, m) + { + this.sheet = sheet; + this.parent = parent; + this.runtime = sheet.runtime; + this.solModifiers = []; + this.solModifiersIncludingParents = []; + this.solWriterAfterCnds = false; // block does not change SOL after running its conditions + this.group = false; // is group of events + this.initially_activated = false; // if a group, is active on startup + this.toplevelevent = false; // is an event block parented only by a top-level group + this.toplevelgroup = false; // is parented only by other groups or is top-level (i.e. not in a subevent) + this.has_else_block = false; // is followed by else +; + this.conditions = []; + this.actions = []; + this.subevents = []; + this.group_name = ""; + this.group = false; + this.initially_activated = false; + this.group_active = false; + this.contained_includes = null; + if (m[1]) + { + this.group_name = m[1][1].toLowerCase(); + this.group = true; + this.initially_activated = !!m[1][0]; + this.contained_includes = []; + this.group_active = this.initially_activated; + this.runtime.allGroups.push(this); + this.runtime.groups_by_name[this.group_name] = this; + } + this.orblock = m[2]; + this.sid = m[4]; + if (!this.group) + this.runtime.blocksBySid[this.sid.toString()] = this; + var i, len; + var cm = m[5]; + for (i = 0, len = cm.length; i < len; i++) + { + var cnd = new cr.condition(this, cm[i]); + cnd.index = i; + cr.seal(cnd); + this.conditions.push(cnd); + /* + if (cnd.is_logical()) + this.is_logical = true; + if (cnd.type && !cnd.type.plugin.singleglobal && this.cndReferences.indexOf(cnd.type) === -1) + this.cndReferences.push(cnd.type); + */ + this.addSolModifier(cnd.type); + } + var am = m[6]; + for (i = 0, len = am.length; i < len; i++) + { + var act = new cr.action(this, am[i]); + act.index = i; + cr.seal(act); + this.actions.push(act); + } + if (m.length === 8) + { + var em = m[7]; + for (i = 0, len = em.length; i < len; i++) + this.sheet.init_event(em[i], this, this.subevents); + } + this.is_else_block = false; + if (this.conditions.length) + { + this.is_else_block = (this.conditions[0].type == null && this.conditions[0].func == cr.system_object.prototype.cnds.Else); + } + }; + window["_c2hh_"] = "8D9E0ABFC8F968E2FEDC80FC6ED0ECA1496C6F1E"; + EventBlock.prototype.postInit = function (hasElse/*, prevBlock_*/) + { + var i, len; + var p = this.parent; + if (this.group) + { + this.toplevelgroup = true; + while (p) + { + if (!p.group) + { + this.toplevelgroup = false; + break; + } + p = p.parent; + } + } + this.toplevelevent = !this.is_trigger() && (!this.parent || (this.parent.group && this.parent.toplevelgroup)); + this.has_else_block = !!hasElse; + this.solModifiersIncludingParents = this.solModifiers.slice(0); + p = this.parent; + while (p) + { + for (i = 0, len = p.solModifiers.length; i < len; i++) + this.addParentSolModifier(p.solModifiers[i]); + p = p.parent; + } + this.solModifiers = findMatchingSolModifier(this.solModifiers); + this.solModifiersIncludingParents = findMatchingSolModifier(this.solModifiersIncludingParents); + var i, len/*, s*/; + for (i = 0, len = this.conditions.length; i < len; i++) + this.conditions[i].postInit(); + for (i = 0, len = this.actions.length; i < len; i++) + this.actions[i].postInit(); + for (i = 0, len = this.subevents.length; i < len; i++) + { + this.subevents[i].postInit(i < len - 1 && this.subevents[i + 1].is_else_block); + } + /* + if (this.is_else_block && this.prev_block) + { + for (i = 0, len = this.prev_block.solModifiers.length; i < len; i++) + { + s = this.prev_block.solModifiers[i]; + if (this.solModifiers.indexOf(s) === -1) + this.solModifiers.push(s); + } + } + */ + }; + EventBlock.prototype.setGroupActive = function (a) + { + if (this.group_active === !!a) + return; // same state + this.group_active = !!a; + var i, len; + for (i = 0, len = this.contained_includes.length; i < len; ++i) + { + this.contained_includes[i].updateActive(); + } + if (len > 0 && this.runtime.running_layout.event_sheet) + this.runtime.running_layout.event_sheet.updateDeepIncludes(); + }; + function addSolModifierToList(type, arr) + { + var i, len, t; + if (!type) + return; + if (arr.indexOf(type) === -1) + arr.push(type); + if (type.is_contained) + { + for (i = 0, len = type.container.length; i < len; i++) + { + t = type.container[i]; + if (type === t) + continue; // already handled + if (arr.indexOf(t) === -1) + arr.push(t); + } + } + }; + EventBlock.prototype.addSolModifier = function (type) + { + addSolModifierToList(type, this.solModifiers); + }; + EventBlock.prototype.addParentSolModifier = function (type) + { + addSolModifierToList(type, this.solModifiersIncludingParents); + }; + EventBlock.prototype.setSolWriterAfterCnds = function () + { + this.solWriterAfterCnds = true; + if (this.parent) + this.parent.setSolWriterAfterCnds(); + }; + EventBlock.prototype.is_trigger = function () + { + if (!this.conditions.length) // no conditions + return false; + else + return this.conditions[0].trigger; + }; + EventBlock.prototype.run = function () + { + var i, len, c, any_true = false, cnd_result; + var runtime = this.runtime; + var evinfo = this.runtime.getCurrentEventStack(); + evinfo.current_event = this; + var conditions = this.conditions; + if (!this.is_else_block) + evinfo.else_branch_ran = false; + if (this.orblock) + { + if (conditions.length === 0) + any_true = true; // be sure to run if empty block + evinfo.cndindex = 0 + for (len = conditions.length; evinfo.cndindex < len; evinfo.cndindex++) + { + c = conditions[evinfo.cndindex]; + if (c.trigger) // skip triggers when running OR block + continue; + cnd_result = c.run(); + if (cnd_result) // make sure all conditions run and run if any were true + any_true = true; + } + evinfo.last_event_true = any_true; + if (any_true) + this.run_actions_and_subevents(); + } + else + { + evinfo.cndindex = 0 + for (len = conditions.length; evinfo.cndindex < len; evinfo.cndindex++) + { + cnd_result = conditions[evinfo.cndindex].run(); + if (!cnd_result) // condition failed + { + evinfo.last_event_true = false; + if (this.toplevelevent && runtime.hasPendingInstances) + runtime.ClearDeathRow(); + return; // bail out now + } + } + evinfo.last_event_true = true; + this.run_actions_and_subevents(); + } + this.end_run(evinfo); + }; + EventBlock.prototype.end_run = function (evinfo) + { + if (evinfo.last_event_true && this.has_else_block) + evinfo.else_branch_ran = true; + if (this.toplevelevent && this.runtime.hasPendingInstances) + this.runtime.ClearDeathRow(); + }; + EventBlock.prototype.run_orblocktrigger = function (index) + { + var evinfo = this.runtime.getCurrentEventStack(); + evinfo.current_event = this; + if (this.conditions[index].run()) + { + this.run_actions_and_subevents(); + this.runtime.getCurrentEventStack().last_event_true = true; + } + }; + EventBlock.prototype.run_actions_and_subevents = function () + { + var evinfo = this.runtime.getCurrentEventStack(); + var len; + for (evinfo.actindex = 0, len = this.actions.length; evinfo.actindex < len; evinfo.actindex++) + { + if (this.actions[evinfo.actindex].run()) + return; + } + this.run_subevents(); + }; + EventBlock.prototype.resume_actions_and_subevents = function () + { + var evinfo = this.runtime.getCurrentEventStack(); + var len; + for (len = this.actions.length; evinfo.actindex < len; evinfo.actindex++) + { + if (this.actions[evinfo.actindex].run()) + return; + } + this.run_subevents(); + }; + EventBlock.prototype.run_subevents = function () + { + if (!this.subevents.length) + return; + var i, len, subev, pushpop/*, skipped_pop = false, pop_modifiers = null*/; + var last = this.subevents.length - 1; + this.runtime.pushEventStack(this); + if (this.solWriterAfterCnds) + { + for (i = 0, len = this.subevents.length; i < len; i++) + { + subev = this.subevents[i]; + pushpop = (!this.toplevelgroup || (!this.group && i < last)); + if (pushpop) + this.runtime.pushCopySol(subev.solModifiers); + subev.run(); + if (pushpop) + this.runtime.popSol(subev.solModifiers); + else + this.runtime.clearSol(subev.solModifiers); + } + } + else + { + for (i = 0, len = this.subevents.length; i < len; i++) + { + this.subevents[i].run(); + } + } + this.runtime.popEventStack(); + }; + EventBlock.prototype.run_pretrigger = function () + { + var evinfo = this.runtime.getCurrentEventStack(); + evinfo.current_event = this; + var any_true = false; + var i, len; + for (evinfo.cndindex = 0, len = this.conditions.length; evinfo.cndindex < len; evinfo.cndindex++) + { +; + if (this.conditions[evinfo.cndindex].run()) + any_true = true; + else if (!this.orblock) // condition failed (let OR blocks run all conditions anyway) + return false; // bail out + } + return this.orblock ? any_true : true; + }; + EventBlock.prototype.retrigger = function () + { + this.runtime.execcount++; + var prevcndindex = this.runtime.getCurrentEventStack().cndindex; + var len; + var evinfo = this.runtime.pushEventStack(this); + if (!this.orblock) + { + for (evinfo.cndindex = prevcndindex + 1, len = this.conditions.length; evinfo.cndindex < len; evinfo.cndindex++) + { + if (!this.conditions[evinfo.cndindex].run()) // condition failed + { + this.runtime.popEventStack(); // moving up level of recursion + return false; // bail out + } + } + } + this.run_actions_and_subevents(); + this.runtime.popEventStack(); + return true; // ran an iteration + }; + EventBlock.prototype.isFirstConditionOfType = function (cnd) + { + var cndindex = cnd.index; + if (cndindex === 0) + return true; + --cndindex; + for ( ; cndindex >= 0; --cndindex) + { + if (this.conditions[cndindex].type === cnd.type) + return false; + } + return true; + }; + cr.eventblock = EventBlock; + function Condition(block, m) + { + this.block = block; + this.sheet = block.sheet; + this.runtime = block.runtime; + this.parameters = []; + this.results = []; + this.extra = {}; // for plugins to stow away some custom info + this.index = -1; + this.anyParamVariesPerInstance = false; + this.func = this.runtime.GetObjectReference(m[1]); +; + this.trigger = (m[3] > 0); + this.fasttrigger = (m[3] === 2); + this.looping = m[4]; + this.inverted = m[5]; + this.isstatic = m[6]; + this.sid = m[7]; + this.runtime.cndsBySid[this.sid.toString()] = this; + if (m[0] === -1) // system object + { + this.type = null; + this.run = this.run_system; + this.behaviortype = null; + this.beh_index = -1; + } + else + { + this.type = this.runtime.types_by_index[m[0]]; +; + if (this.isstatic) + this.run = this.run_static; + else + this.run = this.run_object; + if (m[2]) + { + this.behaviortype = this.type.getBehaviorByName(m[2]); +; + this.beh_index = this.type.getBehaviorIndexByName(m[2]); +; + } + else + { + this.behaviortype = null; + this.beh_index = -1; + } + if (this.block.parent) + this.block.parent.setSolWriterAfterCnds(); + } + if (this.fasttrigger) + this.run = this.run_true; + if (m.length === 10) + { + var i, len; + var em = m[9]; + for (i = 0, len = em.length; i < len; i++) + { + var param = new cr.parameter(this, em[i]); + cr.seal(param); + this.parameters.push(param); + } + this.results.length = em.length; + } + }; + Condition.prototype.postInit = function () + { + var i, len, p; + for (i = 0, len = this.parameters.length; i < len; i++) + { + p = this.parameters[i]; + p.postInit(); + if (p.variesPerInstance) + this.anyParamVariesPerInstance = true; + } + }; + /* + Condition.prototype.is_logical = function () + { + return !this.type || this.type.plugin.singleglobal; + }; + */ + Condition.prototype.run_true = function () + { + return true; + }; + Condition.prototype.run_system = function () + { + var i, len; + for (i = 0, len = this.parameters.length; i < len; i++) + this.results[i] = this.parameters[i].get(); + return cr.xor(this.func.apply(this.runtime.system, this.results), this.inverted); + }; + Condition.prototype.run_static = function () + { + var i, len; + for (i = 0, len = this.parameters.length; i < len; i++) + this.results[i] = this.parameters[i].get(); + var ret = this.func.apply(this.behaviortype ? this.behaviortype : this.type, this.results); + this.type.applySolToContainer(); + return ret; + }; + Condition.prototype.run_object = function () + { + var i, j, k, leni, lenj, p, ret, met, inst, s, sol2; + var type = this.type; + var sol = type.getCurrentSol(); + var is_orblock = this.block.orblock && !this.trigger; // triggers in OR blocks need to work normally + var offset = 0; + var is_contained = type.is_contained; + var is_family = type.is_family; + var family_index = type.family_index; + var beh_index = this.beh_index; + var is_beh = (beh_index > -1); + var params_vary = this.anyParamVariesPerInstance; + var parameters = this.parameters; + var results = this.results; + var inverted = this.inverted; + var func = this.func; + var arr, container; + if (params_vary) + { + for (j = 0, lenj = parameters.length; j < lenj; ++j) + { + p = parameters[j]; + if (!p.variesPerInstance) + results[j] = p.get(0); + } + } + else + { + for (j = 0, lenj = parameters.length; j < lenj; ++j) + results[j] = parameters[j].get(0); + } + if (sol.select_all) { + cr.clearArray(sol.instances); // clear contents + cr.clearArray(sol.else_instances); + arr = type.instances; + for (i = 0, leni = arr.length; i < leni; ++i) + { + inst = arr[i]; +; + if (params_vary) + { + for (j = 0, lenj = parameters.length; j < lenj; ++j) + { + p = parameters[j]; + if (p.variesPerInstance) + results[j] = p.get(i); // default SOL index is current object + } + } + if (is_beh) + { + offset = 0; + if (is_family) + { + offset = inst.type.family_beh_map[family_index]; + } + ret = func.apply(inst.behavior_insts[beh_index + offset], results); + } + else + ret = func.apply(inst, results); + met = cr.xor(ret, inverted); + if (met) + sol.instances.push(inst); + else if (is_orblock) // in OR blocks, keep the instances not meeting the condition for subsequent testing + sol.else_instances.push(inst); + } + if (type.finish) + type.finish(true); + sol.select_all = false; + type.applySolToContainer(); + return sol.hasObjects(); + } + else { + k = 0; + var using_else_instances = (is_orblock && !this.block.isFirstConditionOfType(this)); + arr = (using_else_instances ? sol.else_instances : sol.instances); + var any_true = false; + for (i = 0, leni = arr.length; i < leni; ++i) + { + inst = arr[i]; +; + if (params_vary) + { + for (j = 0, lenj = parameters.length; j < lenj; ++j) + { + p = parameters[j]; + if (p.variesPerInstance) + results[j] = p.get(i); // default SOL index is current object + } + } + if (is_beh) + { + offset = 0; + if (is_family) + { + offset = inst.type.family_beh_map[family_index]; + } + ret = func.apply(inst.behavior_insts[beh_index + offset], results); + } + else + ret = func.apply(inst, results); + if (cr.xor(ret, inverted)) + { + any_true = true; + if (using_else_instances) + { + sol.instances.push(inst); + if (is_contained) + { + for (j = 0, lenj = inst.siblings.length; j < lenj; j++) + { + s = inst.siblings[j]; + s.type.getCurrentSol().instances.push(s); + } + } + } + else + { + arr[k] = inst; + if (is_contained) + { + for (j = 0, lenj = inst.siblings.length; j < lenj; j++) + { + s = inst.siblings[j]; + s.type.getCurrentSol().instances[k] = s; + } + } + k++; + } + } + else + { + if (using_else_instances) + { + arr[k] = inst; + if (is_contained) + { + for (j = 0, lenj = inst.siblings.length; j < lenj; j++) + { + s = inst.siblings[j]; + s.type.getCurrentSol().else_instances[k] = s; + } + } + k++; + } + else if (is_orblock) + { + sol.else_instances.push(inst); + if (is_contained) + { + for (j = 0, lenj = inst.siblings.length; j < lenj; j++) + { + s = inst.siblings[j]; + s.type.getCurrentSol().else_instances.push(s); + } + } + } + } + } + cr.truncateArray(arr, k); + if (is_contained) + { + container = type.container; + for (i = 0, leni = container.length; i < leni; i++) + { + sol2 = container[i].getCurrentSol(); + if (using_else_instances) + cr.truncateArray(sol2.else_instances, k); + else + cr.truncateArray(sol2.instances, k); + } + } + var pick_in_finish = any_true; // don't pick in finish() if we're only doing the logic test below + if (using_else_instances && !any_true) + { + for (i = 0, leni = sol.instances.length; i < leni; i++) + { + inst = sol.instances[i]; + if (params_vary) + { + for (j = 0, lenj = parameters.length; j < lenj; j++) + { + p = parameters[j]; + if (p.variesPerInstance) + results[j] = p.get(i); + } + } + if (is_beh) + ret = func.apply(inst.behavior_insts[beh_index], results); + else + ret = func.apply(inst, results); + if (cr.xor(ret, inverted)) + { + any_true = true; + break; // got our flag, don't need to test any more + } + } + } + if (type.finish) + type.finish(pick_in_finish || is_orblock); + return is_orblock ? any_true : sol.hasObjects(); + } + }; + cr.condition = Condition; + function Action(block, m) + { + this.block = block; + this.sheet = block.sheet; + this.runtime = block.runtime; + this.parameters = []; + this.results = []; + this.extra = {}; // for plugins to stow away some custom info + this.index = -1; + this.anyParamVariesPerInstance = false; + this.func = this.runtime.GetObjectReference(m[1]); +; + if (m[0] === -1) // system + { + this.type = null; + this.run = this.run_system; + this.behaviortype = null; + this.beh_index = -1; + } + else + { + this.type = this.runtime.types_by_index[m[0]]; +; + this.run = this.run_object; + if (m[2]) + { + this.behaviortype = this.type.getBehaviorByName(m[2]); +; + this.beh_index = this.type.getBehaviorIndexByName(m[2]); +; + } + else + { + this.behaviortype = null; + this.beh_index = -1; + } + } + this.sid = m[3]; + this.runtime.actsBySid[this.sid.toString()] = this; + if (m.length === 6) + { + var i, len; + var em = m[5]; + for (i = 0, len = em.length; i < len; i++) + { + var param = new cr.parameter(this, em[i]); + cr.seal(param); + this.parameters.push(param); + } + this.results.length = em.length; + } + }; + Action.prototype.postInit = function () + { + var i, len, p; + for (i = 0, len = this.parameters.length; i < len; i++) + { + p = this.parameters[i]; + p.postInit(); + if (p.variesPerInstance) + this.anyParamVariesPerInstance = true; + } + }; + Action.prototype.run_system = function () + { + var runtime = this.runtime; + var i, len; + var parameters = this.parameters; + var results = this.results; + for (i = 0, len = parameters.length; i < len; ++i) + results[i] = parameters[i].get(); + return this.func.apply(runtime.system, results); + }; + Action.prototype.run_object = function () + { + var type = this.type; + var beh_index = this.beh_index; + var family_index = type.family_index; + var params_vary = this.anyParamVariesPerInstance; + var parameters = this.parameters; + var results = this.results; + var func = this.func; + var instances = type.getCurrentSol().getObjects(); + var is_family = type.is_family; + var is_beh = (beh_index > -1); + var i, j, leni, lenj, p, inst, offset; + if (params_vary) + { + for (j = 0, lenj = parameters.length; j < lenj; ++j) + { + p = parameters[j]; + if (!p.variesPerInstance) + results[j] = p.get(0); + } + } + else + { + for (j = 0, lenj = parameters.length; j < lenj; ++j) + results[j] = parameters[j].get(0); + } + for (i = 0, leni = instances.length; i < leni; ++i) + { + inst = instances[i]; + if (params_vary) + { + for (j = 0, lenj = parameters.length; j < lenj; ++j) + { + p = parameters[j]; + if (p.variesPerInstance) + results[j] = p.get(i); // pass i to use as default SOL index + } + } + if (is_beh) + { + offset = 0; + if (is_family) + { + offset = inst.type.family_beh_map[family_index]; + } + func.apply(inst.behavior_insts[beh_index + offset], results); + } + else + func.apply(inst, results); + } + return false; + }; + cr.action = Action; + var tempValues = []; + var tempValuesPtr = -1; + function pushTempValue() + { + tempValuesPtr++; + if (tempValues.length === tempValuesPtr) + tempValues.push(new cr.expvalue()); + return tempValues[tempValuesPtr]; + }; + function popTempValue() + { + tempValuesPtr--; + }; + function Parameter(owner, m) + { + this.owner = owner; + this.block = owner.block; + this.sheet = owner.sheet; + this.runtime = owner.runtime; + this.type = m[0]; + this.expression = null; + this.solindex = 0; + this.get = null; + this.combosel = 0; + this.layout = null; + this.key = 0; + this.object = null; + this.index = 0; + this.varname = null; + this.eventvar = null; + this.fileinfo = null; + this.subparams = null; + this.variadicret = null; + this.subparams = null; + this.variadicret = null; + this.variesPerInstance = false; + var i, len, param; + switch (m[0]) + { + case 0: // number + case 7: // any + this.expression = new cr.expNode(this, m[1]); + this.solindex = 0; + this.get = this.get_exp; + break; + case 1: // string + this.expression = new cr.expNode(this, m[1]); + this.solindex = 0; + this.get = this.get_exp_str; + break; + case 5: // layer + this.expression = new cr.expNode(this, m[1]); + this.solindex = 0; + this.get = this.get_layer; + break; + case 3: // combo + case 8: // cmp + this.combosel = m[1]; + this.get = this.get_combosel; + break; + case 6: // layout + this.layout = this.runtime.layouts[m[1]]; +; + this.get = this.get_layout; + break; + case 9: // keyb + this.key = m[1]; + this.get = this.get_key; + break; + case 4: // object + this.object = this.runtime.types_by_index[m[1]]; +; + this.get = this.get_object; + this.block.addSolModifier(this.object); + if (this.owner instanceof cr.action) + this.block.setSolWriterAfterCnds(); + else if (this.block.parent) + this.block.parent.setSolWriterAfterCnds(); + break; + case 10: // instvar + this.index = m[1]; + if (owner.type && owner.type.is_family) + { + this.get = this.get_familyvar; + this.variesPerInstance = true; + } + else + this.get = this.get_instvar; + break; + case 11: // eventvar + this.varname = m[1]; + this.eventvar = null; + this.get = this.get_eventvar; + break; + case 2: // audiofile ["name", ismusic] + case 12: // fileinfo "name" + this.fileinfo = m[1]; + this.get = this.get_audiofile; + break; + case 13: // variadic + this.get = this.get_variadic; + this.subparams = []; + this.variadicret = []; + for (i = 1, len = m.length; i < len; i++) + { + param = new cr.parameter(this.owner, m[i]); + cr.seal(param); + this.subparams.push(param); + this.variadicret.push(0); + } + break; + default: +; + } + }; + Parameter.prototype.postInit = function () + { + var i, len; + if (this.type === 11) // eventvar + { + this.eventvar = this.runtime.getEventVariableByName(this.varname, this.block.parent); +; + } + else if (this.type === 13) // variadic, postInit all sub-params + { + for (i = 0, len = this.subparams.length; i < len; i++) + this.subparams[i].postInit(); + } + if (this.expression) + this.expression.postInit(); + }; + Parameter.prototype.maybeVaryForType = function (t) + { + if (this.variesPerInstance) + return; // already varies per instance, no need to check again + if (!t) + return; // never vary for system type + if (!t.plugin.singleglobal) + { + this.variesPerInstance = true; + return; + } + }; + Parameter.prototype.setVaries = function () + { + this.variesPerInstance = true; + }; + Parameter.prototype.get_exp = function (solindex) + { + this.solindex = solindex || 0; // default SOL index to use + var temp = pushTempValue(); + this.expression.get(temp); + popTempValue(); + return temp.data; // return actual JS value, not expvalue + }; + Parameter.prototype.get_exp_str = function (solindex) + { + this.solindex = solindex || 0; // default SOL index to use + var temp = pushTempValue(); + this.expression.get(temp); + popTempValue(); + if (cr.is_string(temp.data)) + return temp.data; + else + return ""; + }; + Parameter.prototype.get_object = function () + { + return this.object; + }; + Parameter.prototype.get_combosel = function () + { + return this.combosel; + }; + Parameter.prototype.get_layer = function (solindex) + { + this.solindex = solindex || 0; // default SOL index to use + var temp = pushTempValue(); + this.expression.get(temp); + popTempValue(); + if (temp.is_number()) + return this.runtime.getLayerByNumber(temp.data); + else + return this.runtime.getLayerByName(temp.data); + } + Parameter.prototype.get_layout = function () + { + return this.layout; + }; + Parameter.prototype.get_key = function () + { + return this.key; + }; + Parameter.prototype.get_instvar = function () + { + return this.index; + }; + Parameter.prototype.get_familyvar = function (solindex_) + { + var solindex = solindex_ || 0; + var familytype = this.owner.type; + var realtype = null; + var sol = familytype.getCurrentSol(); + var objs = sol.getObjects(); + if (objs.length) + realtype = objs[solindex % objs.length].type; + else if (sol.else_instances.length) + realtype = sol.else_instances[solindex % sol.else_instances.length].type; + else if (familytype.instances.length) + realtype = familytype.instances[solindex % familytype.instances.length].type; + else + return 0; + return this.index + realtype.family_var_map[familytype.family_index]; + }; + Parameter.prototype.get_eventvar = function () + { + return this.eventvar; + }; + Parameter.prototype.get_audiofile = function () + { + return this.fileinfo; + }; + Parameter.prototype.get_variadic = function () + { + var i, len; + for (i = 0, len = this.subparams.length; i < len; i++) + { + this.variadicret[i] = this.subparams[i].get(); + } + return this.variadicret; + }; + cr.parameter = Parameter; + function EventVariable(sheet, parent, m) + { + this.sheet = sheet; + this.parent = parent; + this.runtime = sheet.runtime; + this.solModifiers = []; + this.name = m[1]; + this.vartype = m[2]; + this.initial = m[3]; + this.is_static = !!m[4]; + this.is_constant = !!m[5]; + this.sid = m[6]; + this.runtime.varsBySid[this.sid.toString()] = this; + this.data = this.initial; // note: also stored in event stack frame for local nonstatic nonconst vars + if (this.parent) // local var + { + if (this.is_static || this.is_constant) + this.localIndex = -1; + else + this.localIndex = this.runtime.stackLocalCount++; + this.runtime.all_local_vars.push(this); + } + else // global var + { + this.localIndex = -1; + this.runtime.all_global_vars.push(this); + } + }; + EventVariable.prototype.postInit = function () + { + this.solModifiers = findMatchingSolModifier(this.solModifiers); + }; + EventVariable.prototype.setValue = function (x) + { +; + var lvs = this.runtime.getCurrentLocalVarStack(); + if (!this.parent || this.is_static || !lvs) + this.data = x; + else // local nonstatic variable: use event stack to keep value at this level of recursion + { + if (this.localIndex >= lvs.length) + lvs.length = this.localIndex + 1; + lvs[this.localIndex] = x; + } + }; + EventVariable.prototype.getValue = function () + { + var lvs = this.runtime.getCurrentLocalVarStack(); + if (!this.parent || this.is_static || !lvs || this.is_constant) + return this.data; + else // local nonstatic variable + { + if (this.localIndex >= lvs.length) + { + return this.initial; + } + if (typeof lvs[this.localIndex] === "undefined") + { + return this.initial; + } + return lvs[this.localIndex]; + } + }; + EventVariable.prototype.run = function () + { + if (this.parent && !this.is_static && !this.is_constant) + this.setValue(this.initial); + }; + cr.eventvariable = EventVariable; + function EventInclude(sheet, parent, m) + { + this.sheet = sheet; + this.parent = parent; + this.runtime = sheet.runtime; + this.solModifiers = []; + this.include_sheet = null; // determined in postInit + this.include_sheet_name = m[1]; + this.active = true; + }; + EventInclude.prototype.toString = function () + { + return "include:" + this.include_sheet.toString(); + }; + EventInclude.prototype.postInit = function () + { + this.include_sheet = this.runtime.eventsheets[this.include_sheet_name]; +; +; + this.sheet.includes.add(this); + this.solModifiers = findMatchingSolModifier(this.solModifiers); + var p = this.parent; + while (p) + { + if (p.group) + p.contained_includes.push(this); + p = p.parent; + } + this.updateActive(); + }; + EventInclude.prototype.run = function () + { + if (this.parent) + this.runtime.pushCleanSol(this.runtime.types_by_index); + if (!this.include_sheet.hasRun) + this.include_sheet.run(true); // from include + if (this.parent) + this.runtime.popSol(this.runtime.types_by_index); + }; + EventInclude.prototype.updateActive = function () + { + var p = this.parent; + while (p) + { + if (p.group && !p.group_active) + { + this.active = false; + return; + } + p = p.parent; + } + this.active = true; + }; + EventInclude.prototype.isActive = function () + { + return this.active; + }; + cr.eventinclude = EventInclude; + function EventStackFrame() + { + this.temp_parents_arr = []; + this.reset(null); + cr.seal(this); + }; + EventStackFrame.prototype.reset = function (cur_event) + { + this.current_event = cur_event; + this.cndindex = 0; + this.actindex = 0; + cr.clearArray(this.temp_parents_arr); + this.last_event_true = false; + this.else_branch_ran = false; + this.any_true_state = false; + }; + EventStackFrame.prototype.isModifierAfterCnds = function () + { + if (this.current_event.solWriterAfterCnds) + return true; + if (this.cndindex < this.current_event.conditions.length - 1) + return !!this.current_event.solModifiers.length; + return false; + }; + cr.eventStackFrame = EventStackFrame; +}()); +(function() +{ + function ExpNode(owner_, m) + { + this.owner = owner_; + this.runtime = owner_.runtime; + this.type = m[0]; +; + this.get = [this.eval_int, + this.eval_float, + this.eval_string, + this.eval_unaryminus, + this.eval_add, + this.eval_subtract, + this.eval_multiply, + this.eval_divide, + this.eval_mod, + this.eval_power, + this.eval_and, + this.eval_or, + this.eval_equal, + this.eval_notequal, + this.eval_less, + this.eval_lessequal, + this.eval_greater, + this.eval_greaterequal, + this.eval_conditional, + this.eval_system_exp, + this.eval_object_exp, + this.eval_instvar_exp, + this.eval_behavior_exp, + this.eval_eventvar_exp][this.type]; + var paramsModel = null; + this.value = null; + this.first = null; + this.second = null; + this.third = null; + this.func = null; + this.results = null; + this.parameters = null; + this.object_type = null; + this.beh_index = -1; + this.instance_expr = null; + this.varindex = -1; + this.behavior_type = null; + this.varname = null; + this.eventvar = null; + this.return_string = false; + switch (this.type) { + case 0: // int + case 1: // float + case 2: // string + this.value = m[1]; + break; + case 3: // unaryminus + this.first = new cr.expNode(owner_, m[1]); + break; + case 18: // conditional + this.first = new cr.expNode(owner_, m[1]); + this.second = new cr.expNode(owner_, m[2]); + this.third = new cr.expNode(owner_, m[3]); + break; + case 19: // system_exp + this.func = this.runtime.GetObjectReference(m[1]); +; + if (this.func === cr.system_object.prototype.exps.random + || this.func === cr.system_object.prototype.exps.choose) + { + this.owner.setVaries(); + } + this.results = []; + this.parameters = []; + if (m.length === 3) + { + paramsModel = m[2]; + this.results.length = paramsModel.length + 1; // must also fit 'ret' + } + else + this.results.length = 1; // to fit 'ret' + break; + case 20: // object_exp + this.object_type = this.runtime.types_by_index[m[1]]; +; + this.beh_index = -1; + this.func = this.runtime.GetObjectReference(m[2]); + this.return_string = m[3]; + if (cr.plugins_.Function && this.func === cr.plugins_.Function.prototype.exps.Call) + { + this.owner.setVaries(); + } + if (m[4]) + this.instance_expr = new cr.expNode(owner_, m[4]); + else + this.instance_expr = null; + this.results = []; + this.parameters = []; + if (m.length === 6) + { + paramsModel = m[5]; + this.results.length = paramsModel.length + 1; + } + else + this.results.length = 1; // to fit 'ret' + break; + case 21: // instvar_exp + this.object_type = this.runtime.types_by_index[m[1]]; +; + this.return_string = m[2]; + if (m[3]) + this.instance_expr = new cr.expNode(owner_, m[3]); + else + this.instance_expr = null; + this.varindex = m[4]; + break; + case 22: // behavior_exp + this.object_type = this.runtime.types_by_index[m[1]]; +; + this.behavior_type = this.object_type.getBehaviorByName(m[2]); +; + this.beh_index = this.object_type.getBehaviorIndexByName(m[2]); + this.func = this.runtime.GetObjectReference(m[3]); + this.return_string = m[4]; + if (m[5]) + this.instance_expr = new cr.expNode(owner_, m[5]); + else + this.instance_expr = null; + this.results = []; + this.parameters = []; + if (m.length === 7) + { + paramsModel = m[6]; + this.results.length = paramsModel.length + 1; + } + else + this.results.length = 1; // to fit 'ret' + break; + case 23: // eventvar_exp + this.varname = m[1]; + this.eventvar = null; // assigned in postInit + break; + } + this.owner.maybeVaryForType(this.object_type); + if (this.type >= 4 && this.type <= 17) + { + this.first = new cr.expNode(owner_, m[1]); + this.second = new cr.expNode(owner_, m[2]); + } + if (paramsModel) + { + var i, len; + for (i = 0, len = paramsModel.length; i < len; i++) + this.parameters.push(new cr.expNode(owner_, paramsModel[i])); + } + cr.seal(this); + }; + ExpNode.prototype.postInit = function () + { + if (this.type === 23) // eventvar_exp + { + this.eventvar = this.owner.runtime.getEventVariableByName(this.varname, this.owner.block.parent); +; + } + if (this.first) + this.first.postInit(); + if (this.second) + this.second.postInit(); + if (this.third) + this.third.postInit(); + if (this.instance_expr) + this.instance_expr.postInit(); + if (this.parameters) + { + var i, len; + for (i = 0, len = this.parameters.length; i < len; i++) + this.parameters[i].postInit(); + } + }; + var tempValues = []; + var tempValuesPtr = -1; + function pushTempValue() + { + ++tempValuesPtr; + if (tempValues.length === tempValuesPtr) + tempValues.push(new cr.expvalue()); + return tempValues[tempValuesPtr]; + }; + function popTempValue() + { + --tempValuesPtr; + }; + function eval_params(parameters, results, temp) + { + var i, len; + for (i = 0, len = parameters.length; i < len; ++i) + { + parameters[i].get(temp); + results[i + 1] = temp.data; // passing actual javascript value as argument instead of expvalue + } + } + ExpNode.prototype.eval_system_exp = function (ret) + { + var parameters = this.parameters; + var results = this.results; + results[0] = ret; + var temp = pushTempValue(); + eval_params(parameters, results, temp); + popTempValue(); + this.func.apply(this.runtime.system, results); + }; + ExpNode.prototype.eval_object_exp = function (ret) + { + var object_type = this.object_type; + var results = this.results; + var parameters = this.parameters; + var instance_expr = this.instance_expr; + var func = this.func; + var index = this.owner.solindex; // default to parameter's intended SOL index + var sol = object_type.getCurrentSol(); + var instances = sol.getObjects(); + if (!instances.length) + { + if (sol.else_instances.length) + instances = sol.else_instances; + else + { + if (this.return_string) + ret.set_string(""); + else + ret.set_int(0); + return; + } + } + results[0] = ret; + ret.object_class = object_type; // so expression can access family type if need be + var temp = pushTempValue(); + eval_params(parameters, results, temp); + if (instance_expr) { + instance_expr.get(temp); + if (temp.is_number()) { + index = temp.data; + instances = object_type.instances; // pick from all instances, not SOL + } + } + popTempValue(); + var len = instances.length; + if (index >= len || index <= -len) + index %= len; // wraparound + if (index < 0) + index += len; + var returned_val = func.apply(instances[index], results); +; + }; + ExpNode.prototype.eval_behavior_exp = function (ret) + { + var object_type = this.object_type; + var results = this.results; + var parameters = this.parameters; + var instance_expr = this.instance_expr; + var beh_index = this.beh_index; + var func = this.func; + var index = this.owner.solindex; // default to parameter's intended SOL index + var sol = object_type.getCurrentSol(); + var instances = sol.getObjects(); + if (!instances.length) + { + if (sol.else_instances.length) + instances = sol.else_instances; + else + { + if (this.return_string) + ret.set_string(""); + else + ret.set_int(0); + return; + } + } + results[0] = ret; + ret.object_class = object_type; // so expression can access family type if need be + var temp = pushTempValue(); + eval_params(parameters, results, temp); + if (instance_expr) { + instance_expr.get(temp); + if (temp.is_number()) { + index = temp.data; + instances = object_type.instances; // pick from all instances, not SOL + } + } + popTempValue(); + var len = instances.length; + if (index >= len || index <= -len) + index %= len; // wraparound + if (index < 0) + index += len; + var inst = instances[index]; + var offset = 0; + if (object_type.is_family) + { + offset = inst.type.family_beh_map[object_type.family_index]; + } + var returned_val = func.apply(inst.behavior_insts[beh_index + offset], results); +; + }; + ExpNode.prototype.eval_instvar_exp = function (ret) + { + var instance_expr = this.instance_expr; + var object_type = this.object_type; + var varindex = this.varindex; + var index = this.owner.solindex; // default to parameter's intended SOL index + var sol = object_type.getCurrentSol(); + var instances = sol.getObjects(); + var inst; + if (!instances.length) + { + if (sol.else_instances.length) + instances = sol.else_instances; + else + { + if (this.return_string) + ret.set_string(""); + else + ret.set_int(0); + return; + } + } + if (instance_expr) + { + var temp = pushTempValue(); + instance_expr.get(temp); + if (temp.is_number()) + { + index = temp.data; + var type_instances = object_type.instances; + if (type_instances.length !== 0) // avoid NaN result with % + { + index %= type_instances.length; // wraparound + if (index < 0) // offset + index += type_instances.length; + } + inst = object_type.getInstanceByIID(index); + var to_ret = inst.instance_vars[varindex]; + if (cr.is_string(to_ret)) + ret.set_string(to_ret); + else + ret.set_float(to_ret); + popTempValue(); + return; // done + } + popTempValue(); + } + var len = instances.length; + if (index >= len || index <= -len) + index %= len; // wraparound + if (index < 0) + index += len; + inst = instances[index]; + var offset = 0; + if (object_type.is_family) + { + offset = inst.type.family_var_map[object_type.family_index]; + } + var to_ret = inst.instance_vars[varindex + offset]; + if (cr.is_string(to_ret)) + ret.set_string(to_ret); + else + ret.set_float(to_ret); + }; + ExpNode.prototype.eval_int = function (ret) + { + ret.type = cr.exptype.Integer; + ret.data = this.value; + }; + ExpNode.prototype.eval_float = function (ret) + { + ret.type = cr.exptype.Float; + ret.data = this.value; + }; + ExpNode.prototype.eval_string = function (ret) + { + ret.type = cr.exptype.String; + ret.data = this.value; + }; + ExpNode.prototype.eval_unaryminus = function (ret) + { + this.first.get(ret); // retrieve operand + if (ret.is_number()) + ret.data = -ret.data; + }; + ExpNode.prototype.eval_add = function (ret) + { + this.first.get(ret); // left operand + var temp = pushTempValue(); + this.second.get(temp); // right operand + if (ret.is_number() && temp.is_number()) + { + ret.data += temp.data; // both operands numbers: add + if (temp.is_float()) + ret.make_float(); + } + popTempValue(); + }; + ExpNode.prototype.eval_subtract = function (ret) + { + this.first.get(ret); // left operand + var temp = pushTempValue(); + this.second.get(temp); // right operand + if (ret.is_number() && temp.is_number()) + { + ret.data -= temp.data; // both operands numbers: subtract + if (temp.is_float()) + ret.make_float(); + } + popTempValue(); + }; + ExpNode.prototype.eval_multiply = function (ret) + { + this.first.get(ret); // left operand + var temp = pushTempValue(); + this.second.get(temp); // right operand + if (ret.is_number() && temp.is_number()) + { + ret.data *= temp.data; // both operands numbers: multiply + if (temp.is_float()) + ret.make_float(); + } + popTempValue(); + }; + ExpNode.prototype.eval_divide = function (ret) + { + this.first.get(ret); // left operand + var temp = pushTempValue(); + this.second.get(temp); // right operand + if (ret.is_number() && temp.is_number()) + { + ret.data /= temp.data; // both operands numbers: divide + ret.make_float(); + } + popTempValue(); + }; + ExpNode.prototype.eval_mod = function (ret) + { + this.first.get(ret); // left operand + var temp = pushTempValue(); + this.second.get(temp); // right operand + if (ret.is_number() && temp.is_number()) + { + ret.data %= temp.data; // both operands numbers: modulo + if (temp.is_float()) + ret.make_float(); + } + popTempValue(); + }; + ExpNode.prototype.eval_power = function (ret) + { + this.first.get(ret); // left operand + var temp = pushTempValue(); + this.second.get(temp); // right operand + if (ret.is_number() && temp.is_number()) + { + ret.data = Math.pow(ret.data, temp.data); // both operands numbers: raise to power + if (temp.is_float()) + ret.make_float(); + } + popTempValue(); + }; + ExpNode.prototype.eval_and = function (ret) + { + this.first.get(ret); // left operand + var temp = pushTempValue(); + this.second.get(temp); // right operand + if (temp.is_string() || ret.is_string()) + this.eval_and_stringconcat(ret, temp); + else + this.eval_and_logical(ret, temp); + popTempValue(); + }; + ExpNode.prototype.eval_and_stringconcat = function (ret, temp) + { + if (ret.is_string() && temp.is_string()) + this.eval_and_stringconcat_str_str(ret, temp); + else + this.eval_and_stringconcat_num(ret, temp); + }; + ExpNode.prototype.eval_and_stringconcat_str_str = function (ret, temp) + { + ret.data += temp.data; + }; + ExpNode.prototype.eval_and_stringconcat_num = function (ret, temp) + { + if (ret.is_string()) + { + ret.data += (Math.round(temp.data * 1e10) / 1e10).toString(); + } + else + { + ret.set_string(ret.data.toString() + temp.data); + } + }; + ExpNode.prototype.eval_and_logical = function (ret, temp) + { + ret.set_int(ret.data && temp.data ? 1 : 0); + }; + ExpNode.prototype.eval_or = function (ret) + { + this.first.get(ret); // left operand + var temp = pushTempValue(); + this.second.get(temp); // right operand + if (ret.is_number() && temp.is_number()) + { + if (ret.data || temp.data) + ret.set_int(1); + else + ret.set_int(0); + } + popTempValue(); + }; + ExpNode.prototype.eval_conditional = function (ret) + { + this.first.get(ret); // condition operand + if (ret.data) // is true + this.second.get(ret); // evaluate second operand to ret + else + this.third.get(ret); // evaluate third operand to ret + }; + ExpNode.prototype.eval_equal = function (ret) + { + this.first.get(ret); // left operand + var temp = pushTempValue(); + this.second.get(temp); // right operand + ret.set_int(ret.data === temp.data ? 1 : 0); + popTempValue(); + }; + ExpNode.prototype.eval_notequal = function (ret) + { + this.first.get(ret); // left operand + var temp = pushTempValue(); + this.second.get(temp); // right operand + ret.set_int(ret.data !== temp.data ? 1 : 0); + popTempValue(); + }; + ExpNode.prototype.eval_less = function (ret) + { + this.first.get(ret); // left operand + var temp = pushTempValue(); + this.second.get(temp); // right operand + ret.set_int(ret.data < temp.data ? 1 : 0); + popTempValue(); + }; + ExpNode.prototype.eval_lessequal = function (ret) + { + this.first.get(ret); // left operand + var temp = pushTempValue(); + this.second.get(temp); // right operand + ret.set_int(ret.data <= temp.data ? 1 : 0); + popTempValue(); + }; + ExpNode.prototype.eval_greater = function (ret) + { + this.first.get(ret); // left operand + var temp = pushTempValue(); + this.second.get(temp); // right operand + ret.set_int(ret.data > temp.data ? 1 : 0); + popTempValue(); + }; + ExpNode.prototype.eval_greaterequal = function (ret) + { + this.first.get(ret); // left operand + var temp = pushTempValue(); + this.second.get(temp); // right operand + ret.set_int(ret.data >= temp.data ? 1 : 0); + popTempValue(); + }; + ExpNode.prototype.eval_eventvar_exp = function (ret) + { + var val = this.eventvar.getValue(); + if (cr.is_number(val)) + ret.set_float(val); + else + ret.set_string(val); + }; + cr.expNode = ExpNode; + function ExpValue(type, data) + { + this.type = type || cr.exptype.Integer; + this.data = data || 0; + this.object_class = null; +; +; +; + if (this.type == cr.exptype.Integer) + this.data = Math.floor(this.data); + cr.seal(this); + }; + ExpValue.prototype.is_int = function () + { + return this.type === cr.exptype.Integer; + }; + ExpValue.prototype.is_float = function () + { + return this.type === cr.exptype.Float; + }; + ExpValue.prototype.is_number = function () + { + return this.type === cr.exptype.Integer || this.type === cr.exptype.Float; + }; + ExpValue.prototype.is_string = function () + { + return this.type === cr.exptype.String; + }; + ExpValue.prototype.make_int = function () + { + if (!this.is_int()) + { + if (this.is_float()) + this.data = Math.floor(this.data); // truncate float + else if (this.is_string()) + this.data = parseInt(this.data, 10); + this.type = cr.exptype.Integer; + } + }; + ExpValue.prototype.make_float = function () + { + if (!this.is_float()) + { + if (this.is_string()) + this.data = parseFloat(this.data); + this.type = cr.exptype.Float; + } + }; + ExpValue.prototype.make_string = function () + { + if (!this.is_string()) + { + this.data = this.data.toString(); + this.type = cr.exptype.String; + } + }; + ExpValue.prototype.set_int = function (val) + { +; + this.type = cr.exptype.Integer; + this.data = Math.floor(val); + }; + ExpValue.prototype.set_float = function (val) + { +; + this.type = cr.exptype.Float; + this.data = val; + }; + ExpValue.prototype.set_string = function (val) + { +; + this.type = cr.exptype.String; + this.data = val; + }; + ExpValue.prototype.set_any = function (val) + { + if (cr.is_number(val)) + { + this.type = cr.exptype.Float; + this.data = val; + } + else if (cr.is_string(val)) + { + this.type = cr.exptype.String; + this.data = val.toString(); + } + else + { + this.type = cr.exptype.Integer; + this.data = 0; + } + }; + cr.expvalue = ExpValue; + cr.exptype = { + Integer: 0, // emulated; no native integer support in javascript + Float: 1, + String: 2 + }; +}()); +; +cr.system_object = function (runtime) +{ + this.runtime = runtime; + this.waits = []; +}; +cr.system_object.prototype.saveToJSON = function () +{ + var o = {}; + var i, len, j, lenj, p, w, t, sobj; + o["waits"] = []; + var owaits = o["waits"]; + var waitobj; + for (i = 0, len = this.waits.length; i < len; i++) + { + w = this.waits[i]; + waitobj = { + "t": w.time, + "st": w.signaltag, + "s": w.signalled, + "ev": w.ev.sid, + "sm": [], + "sols": {} + }; + if (w.ev.actions[w.actindex]) + waitobj["act"] = w.ev.actions[w.actindex].sid; + for (j = 0, lenj = w.solModifiers.length; j < lenj; j++) + waitobj["sm"].push(w.solModifiers[j].sid); + for (p in w.sols) + { + if (w.sols.hasOwnProperty(p)) + { + t = this.runtime.types_by_index[parseInt(p, 10)]; +; + sobj = { + "sa": w.sols[p].sa, + "insts": [] + }; + for (j = 0, lenj = w.sols[p].insts.length; j < lenj; j++) + sobj["insts"].push(w.sols[p].insts[j].uid); + waitobj["sols"][t.sid.toString()] = sobj; + } + } + owaits.push(waitobj); + } + return o; +}; +cr.system_object.prototype.loadFromJSON = function (o) +{ + var owaits = o["waits"]; + var i, len, j, lenj, p, w, addWait, e, aindex, t, savedsol, nusol, inst; + cr.clearArray(this.waits); + for (i = 0, len = owaits.length; i < len; i++) + { + w = owaits[i]; + e = this.runtime.blocksBySid[w["ev"].toString()]; + if (!e) + continue; // event must've gone missing + aindex = -1; + for (j = 0, lenj = e.actions.length; j < lenj; j++) + { + if (e.actions[j].sid === w["act"]) + { + aindex = j; + break; + } + } + if (aindex === -1) + continue; // action must've gone missing + addWait = {}; + addWait.sols = {}; + addWait.solModifiers = []; + addWait.deleteme = false; + addWait.time = w["t"]; + addWait.signaltag = w["st"] || ""; + addWait.signalled = !!w["s"]; + addWait.ev = e; + addWait.actindex = aindex; + for (j = 0, lenj = w["sm"].length; j < lenj; j++) + { + t = this.runtime.getObjectTypeBySid(w["sm"][j]); + if (t) + addWait.solModifiers.push(t); + } + for (p in w["sols"]) + { + if (w["sols"].hasOwnProperty(p)) + { + t = this.runtime.getObjectTypeBySid(parseInt(p, 10)); + if (!t) + continue; // type must've been deleted + savedsol = w["sols"][p]; + nusol = { + sa: savedsol["sa"], + insts: [] + }; + for (j = 0, lenj = savedsol["insts"].length; j < lenj; j++) + { + inst = this.runtime.getObjectByUID(savedsol["insts"][j]); + if (inst) + nusol.insts.push(inst); + } + addWait.sols[t.index.toString()] = nusol; + } + } + this.waits.push(addWait); + } +}; +(function () +{ + var sysProto = cr.system_object.prototype; + function SysCnds() {}; + SysCnds.prototype.EveryTick = function() + { + return true; + }; + SysCnds.prototype.OnLayoutStart = function() + { + return true; + }; + SysCnds.prototype.OnLayoutEnd = function() + { + return true; + }; + SysCnds.prototype.Compare = function(x, cmp, y) + { + return cr.do_cmp(x, cmp, y); + }; + SysCnds.prototype.CompareTime = function (cmp, t) + { + var elapsed = this.runtime.kahanTime.sum; + if (cmp === 0) + { + var cnd = this.runtime.getCurrentCondition(); + if (!cnd.extra["CompareTime_executed"]) + { + if (elapsed >= t) + { + cnd.extra["CompareTime_executed"] = true; + return true; + } + } + return false; + } + return cr.do_cmp(elapsed, cmp, t); + }; + SysCnds.prototype.LayerVisible = function (layer) + { + if (!layer) + return false; + else + return layer.visible; + }; + SysCnds.prototype.LayerEmpty = function (layer) + { + if (!layer) + return false; + else + return !layer.instances.length; + }; + SysCnds.prototype.LayerCmpOpacity = function (layer, cmp, opacity_) + { + if (!layer) + return false; + return cr.do_cmp(layer.opacity * 100, cmp, opacity_); + }; + SysCnds.prototype.Repeat = function (count) + { + var current_frame = this.runtime.getCurrentEventStack(); + var current_event = current_frame.current_event; + var solModifierAfterCnds = current_frame.isModifierAfterCnds(); + var current_loop = this.runtime.pushLoopStack(); + var i; + if (solModifierAfterCnds) + { + for (i = 0; i < count && !current_loop.stopped; i++) + { + this.runtime.pushCopySol(current_event.solModifiers); + current_loop.index = i; + current_event.retrigger(); + this.runtime.popSol(current_event.solModifiers); + } + } + else + { + for (i = 0; i < count && !current_loop.stopped; i++) + { + current_loop.index = i; + current_event.retrigger(); + } + } + this.runtime.popLoopStack(); + return false; + }; + SysCnds.prototype.While = function (count) + { + var current_frame = this.runtime.getCurrentEventStack(); + var current_event = current_frame.current_event; + var solModifierAfterCnds = current_frame.isModifierAfterCnds(); + var current_loop = this.runtime.pushLoopStack(); + var i; + if (solModifierAfterCnds) + { + for (i = 0; !current_loop.stopped; i++) + { + this.runtime.pushCopySol(current_event.solModifiers); + current_loop.index = i; + if (!current_event.retrigger()) // one of the other conditions returned false + current_loop.stopped = true; // break + this.runtime.popSol(current_event.solModifiers); + } + } + else + { + for (i = 0; !current_loop.stopped; i++) + { + current_loop.index = i; + if (!current_event.retrigger()) + current_loop.stopped = true; + } + } + this.runtime.popLoopStack(); + return false; + }; + SysCnds.prototype.For = function (name, start, end) + { + var current_frame = this.runtime.getCurrentEventStack(); + var current_event = current_frame.current_event; + var solModifierAfterCnds = current_frame.isModifierAfterCnds(); + var current_loop = this.runtime.pushLoopStack(name); + var i; + if (end < start) + { + if (solModifierAfterCnds) + { + for (i = start; i >= end && !current_loop.stopped; --i) // inclusive to end + { + this.runtime.pushCopySol(current_event.solModifiers); + current_loop.index = i; + current_event.retrigger(); + this.runtime.popSol(current_event.solModifiers); + } + } + else + { + for (i = start; i >= end && !current_loop.stopped; --i) // inclusive to end + { + current_loop.index = i; + current_event.retrigger(); + } + } + } + else + { + if (solModifierAfterCnds) + { + for (i = start; i <= end && !current_loop.stopped; ++i) // inclusive to end + { + this.runtime.pushCopySol(current_event.solModifiers); + current_loop.index = i; + current_event.retrigger(); + this.runtime.popSol(current_event.solModifiers); + } + } + else + { + for (i = start; i <= end && !current_loop.stopped; ++i) // inclusive to end + { + current_loop.index = i; + current_event.retrigger(); + } + } + } + this.runtime.popLoopStack(); + return false; + }; + var foreach_instancestack = []; + var foreach_instanceptr = -1; + SysCnds.prototype.ForEach = function (obj) + { + var sol = obj.getCurrentSol(); + foreach_instanceptr++; + if (foreach_instancestack.length === foreach_instanceptr) + foreach_instancestack.push([]); + var instances = foreach_instancestack[foreach_instanceptr]; + cr.shallowAssignArray(instances, sol.getObjects()); + var current_frame = this.runtime.getCurrentEventStack(); + var current_event = current_frame.current_event; + var solModifierAfterCnds = current_frame.isModifierAfterCnds(); + var current_loop = this.runtime.pushLoopStack(); + var i, len, j, lenj, inst, s, sol2; + var is_contained = obj.is_contained; + if (solModifierAfterCnds) + { + for (i = 0, len = instances.length; i < len && !current_loop.stopped; i++) + { + this.runtime.pushCopySol(current_event.solModifiers); + inst = instances[i]; + sol = obj.getCurrentSol(); + sol.select_all = false; + cr.clearArray(sol.instances); + sol.instances[0] = inst; + if (is_contained) + { + for (j = 0, lenj = inst.siblings.length; j < lenj; j++) + { + s = inst.siblings[j]; + sol2 = s.type.getCurrentSol(); + sol2.select_all = false; + cr.clearArray(sol2.instances); + sol2.instances[0] = s; + } + } + current_loop.index = i; + current_event.retrigger(); + this.runtime.popSol(current_event.solModifiers); + } + } + else + { + sol.select_all = false; + cr.clearArray(sol.instances); + for (i = 0, len = instances.length; i < len && !current_loop.stopped; i++) + { + inst = instances[i]; + sol.instances[0] = inst; + if (is_contained) + { + for (j = 0, lenj = inst.siblings.length; j < lenj; j++) + { + s = inst.siblings[j]; + sol2 = s.type.getCurrentSol(); + sol2.select_all = false; + cr.clearArray(sol2.instances); + sol2.instances[0] = s; + } + } + current_loop.index = i; + current_event.retrigger(); + } + } + cr.clearArray(instances); + this.runtime.popLoopStack(); + foreach_instanceptr--; + return false; + }; + function foreach_sortinstances(a, b) + { + var va = a.extra["c2_feo_val"]; + var vb = b.extra["c2_feo_val"]; + if (cr.is_number(va) && cr.is_number(vb)) + return va - vb; + else + { + va = "" + va; + vb = "" + vb; + if (va < vb) + return -1; + else if (va > vb) + return 1; + else + return 0; + } + }; + SysCnds.prototype.ForEachOrdered = function (obj, exp, order) + { + var sol = obj.getCurrentSol(); + foreach_instanceptr++; + if (foreach_instancestack.length === foreach_instanceptr) + foreach_instancestack.push([]); + var instances = foreach_instancestack[foreach_instanceptr]; + cr.shallowAssignArray(instances, sol.getObjects()); + var current_frame = this.runtime.getCurrentEventStack(); + var current_event = current_frame.current_event; + var current_condition = this.runtime.getCurrentCondition(); + var solModifierAfterCnds = current_frame.isModifierAfterCnds(); + var current_loop = this.runtime.pushLoopStack(); + var i, len, j, lenj, inst, s, sol2; + for (i = 0, len = instances.length; i < len; i++) + { + instances[i].extra["c2_feo_val"] = current_condition.parameters[1].get(i); + } + instances.sort(foreach_sortinstances); + if (order === 1) + instances.reverse(); + var is_contained = obj.is_contained; + if (solModifierAfterCnds) + { + for (i = 0, len = instances.length; i < len && !current_loop.stopped; i++) + { + this.runtime.pushCopySol(current_event.solModifiers); + inst = instances[i]; + sol = obj.getCurrentSol(); + sol.select_all = false; + cr.clearArray(sol.instances); + sol.instances[0] = inst; + if (is_contained) + { + for (j = 0, lenj = inst.siblings.length; j < lenj; j++) + { + s = inst.siblings[j]; + sol2 = s.type.getCurrentSol(); + sol2.select_all = false; + cr.clearArray(sol2.instances); + sol2.instances[0] = s; + } + } + current_loop.index = i; + current_event.retrigger(); + this.runtime.popSol(current_event.solModifiers); + } + } + else + { + sol.select_all = false; + cr.clearArray(sol.instances); + for (i = 0, len = instances.length; i < len && !current_loop.stopped; i++) + { + inst = instances[i]; + sol.instances[0] = inst; + if (is_contained) + { + for (j = 0, lenj = inst.siblings.length; j < lenj; j++) + { + s = inst.siblings[j]; + sol2 = s.type.getCurrentSol(); + sol2.select_all = false; + cr.clearArray(sol2.instances); + sol2.instances[0] = s; + } + } + current_loop.index = i; + current_event.retrigger(); + } + } + cr.clearArray(instances); + this.runtime.popLoopStack(); + foreach_instanceptr--; + return false; + }; + SysCnds.prototype.PickByComparison = function (obj_, exp_, cmp_, val_) + { + var i, len, k, inst; + if (!obj_) + return; + foreach_instanceptr++; + if (foreach_instancestack.length === foreach_instanceptr) + foreach_instancestack.push([]); + var tmp_instances = foreach_instancestack[foreach_instanceptr]; + var sol = obj_.getCurrentSol(); + cr.shallowAssignArray(tmp_instances, sol.getObjects()); + if (sol.select_all) + cr.clearArray(sol.else_instances); + var current_condition = this.runtime.getCurrentCondition(); + for (i = 0, k = 0, len = tmp_instances.length; i < len; i++) + { + inst = tmp_instances[i]; + tmp_instances[k] = inst; + exp_ = current_condition.parameters[1].get(i); + val_ = current_condition.parameters[3].get(i); + if (cr.do_cmp(exp_, cmp_, val_)) + { + k++; + } + else + { + sol.else_instances.push(inst); + } + } + cr.truncateArray(tmp_instances, k); + sol.select_all = false; + cr.shallowAssignArray(sol.instances, tmp_instances); + cr.clearArray(tmp_instances); + foreach_instanceptr--; + obj_.applySolToContainer(); + return !!sol.instances.length; + }; + SysCnds.prototype.PickByEvaluate = function (obj_, exp_) + { + var i, len, k, inst; + if (!obj_) + return; + foreach_instanceptr++; + if (foreach_instancestack.length === foreach_instanceptr) + foreach_instancestack.push([]); + var tmp_instances = foreach_instancestack[foreach_instanceptr]; + var sol = obj_.getCurrentSol(); + cr.shallowAssignArray(tmp_instances, sol.getObjects()); + if (sol.select_all) + cr.clearArray(sol.else_instances); + var current_condition = this.runtime.getCurrentCondition(); + for (i = 0, k = 0, len = tmp_instances.length; i < len; i++) + { + inst = tmp_instances[i]; + tmp_instances[k] = inst; + exp_ = current_condition.parameters[1].get(i); + if (exp_) + { + k++; + } + else + { + sol.else_instances.push(inst); + } + } + cr.truncateArray(tmp_instances, k); + sol.select_all = false; + cr.shallowAssignArray(sol.instances, tmp_instances); + cr.clearArray(tmp_instances); + foreach_instanceptr--; + obj_.applySolToContainer(); + return !!sol.instances.length; + }; + SysCnds.prototype.TriggerOnce = function () + { + var cndextra = this.runtime.getCurrentCondition().extra; + if (typeof cndextra["TriggerOnce_lastTick"] === "undefined") + cndextra["TriggerOnce_lastTick"] = -1; + var last_tick = cndextra["TriggerOnce_lastTick"]; + var cur_tick = this.runtime.tickcount; + cndextra["TriggerOnce_lastTick"] = cur_tick; + return this.runtime.layout_first_tick || last_tick !== cur_tick - 1; + }; + SysCnds.prototype.Every = function (seconds) + { + var cnd = this.runtime.getCurrentCondition(); + var last_time = cnd.extra["Every_lastTime"] || 0; + var cur_time = this.runtime.kahanTime.sum; + if (typeof cnd.extra["Every_seconds"] === "undefined") + cnd.extra["Every_seconds"] = seconds; + var this_seconds = cnd.extra["Every_seconds"]; + if (cur_time >= last_time + this_seconds) + { + cnd.extra["Every_lastTime"] = last_time + this_seconds; + if (cur_time >= cnd.extra["Every_lastTime"] + 0.04) + { + cnd.extra["Every_lastTime"] = cur_time; + } + cnd.extra["Every_seconds"] = seconds; + return true; + } + else if (cur_time < last_time - 0.1) + { + cnd.extra["Every_lastTime"] = cur_time; + } + return false; + }; + SysCnds.prototype.PickNth = function (obj, index) + { + if (!obj) + return false; + var sol = obj.getCurrentSol(); + var instances = sol.getObjects(); + index = cr.floor(index); + if (index < 0 || index >= instances.length) + return false; + var inst = instances[index]; + sol.pick_one(inst); + obj.applySolToContainer(); + return true; + }; + SysCnds.prototype.PickRandom = function (obj) + { + if (!obj) + return false; + var sol = obj.getCurrentSol(); + var instances = sol.getObjects(); + var index = cr.floor(Math.random() * instances.length); + if (index >= instances.length) + return false; + var inst = instances[index]; + sol.pick_one(inst); + obj.applySolToContainer(); + return true; + }; + SysCnds.prototype.CompareVar = function (v, cmp, val) + { + return cr.do_cmp(v.getValue(), cmp, val); + }; + SysCnds.prototype.IsGroupActive = function (group) + { + var g = this.runtime.groups_by_name[group.toLowerCase()]; + return g && g.group_active; + }; + SysCnds.prototype.IsPreview = function () + { + return typeof cr_is_preview !== "undefined"; + }; + SysCnds.prototype.PickAll = function (obj) + { + if (!obj) + return false; + if (!obj.instances.length) + return false; + var sol = obj.getCurrentSol(); + sol.select_all = true; + obj.applySolToContainer(); + return true; + }; + SysCnds.prototype.IsMobile = function () + { + return this.runtime.isMobile; + }; + SysCnds.prototype.CompareBetween = function (x, a, b) + { + return x >= a && x <= b; + }; + SysCnds.prototype.Else = function () + { + var current_frame = this.runtime.getCurrentEventStack(); + if (current_frame.else_branch_ran) + return false; // another event in this else-if chain has run + else + return !current_frame.last_event_true; + /* + var current_frame = this.runtime.getCurrentEventStack(); + var current_event = current_frame.current_event; + var prev_event = current_event.prev_block; + if (!prev_event) + return false; + if (prev_event.is_logical) + return !this.runtime.last_event_true; + var i, len, j, lenj, s, sol, temp, inst, any_picked = false; + for (i = 0, len = prev_event.cndReferences.length; i < len; i++) + { + s = prev_event.cndReferences[i]; + sol = s.getCurrentSol(); + if (sol.select_all || sol.instances.length === s.instances.length) + { + sol.select_all = false; + sol.instances.length = 0; + } + else + { + if (sol.instances.length === 1 && sol.else_instances.length === 0 && s.instances.length >= 2) + { + inst = sol.instances[0]; + sol.instances.length = 0; + for (j = 0, lenj = s.instances.length; j < lenj; j++) + { + if (s.instances[j] != inst) + sol.instances.push(s.instances[j]); + } + any_picked = true; + } + else + { + temp = sol.instances; + sol.instances = sol.else_instances; + sol.else_instances = temp; + any_picked = true; + } + } + } + return any_picked; + */ + }; + SysCnds.prototype.OnLoadFinished = function () + { + return true; + }; + SysCnds.prototype.OnCanvasSnapshot = function () + { + return true; + }; + SysCnds.prototype.EffectsSupported = function () + { + return !!this.runtime.glwrap; + }; + SysCnds.prototype.OnSaveComplete = function () + { + return true; + }; + SysCnds.prototype.OnSaveFailed = function () + { + return true; + }; + SysCnds.prototype.OnLoadComplete = function () + { + return true; + }; + SysCnds.prototype.OnLoadFailed = function () + { + return true; + }; + SysCnds.prototype.ObjectUIDExists = function (u) + { + return !!this.runtime.getObjectByUID(u); + }; + SysCnds.prototype.IsOnPlatform = function (p) + { + var rt = this.runtime; + switch (p) { + case 0: // HTML5 website + return !rt.isDomFree && !rt.isNodeWebkit && !rt.isCordova && !rt.isWinJS && !rt.isWindowsPhone8 && !rt.isBlackberry10 && !rt.isAmazonWebApp; + case 1: // iOS + return rt.isiOS; + case 2: // Android + return rt.isAndroid; + case 3: // Windows 8 + return rt.isWindows8App; + case 4: // Windows Phone 8 + return rt.isWindowsPhone8; + case 5: // Blackberry 10 + return rt.isBlackberry10; + case 6: // Tizen + return rt.isTizen; + case 7: // CocoonJS + return rt.isCocoonJs; + case 8: // Cordova + return rt.isCordova; + case 9: // Scirra Arcade + return rt.isArcade; + case 10: // node-webkit + return rt.isNodeWebkit; + case 11: // crosswalk + return rt.isCrosswalk; + case 12: // amazon webapp + return rt.isAmazonWebApp; + case 13: // windows 10 app + return rt.isWindows10; + default: // should not be possible + return false; + } + }; + var cacheRegex = null; + var lastRegex = ""; + var lastFlags = ""; + function getRegex(regex_, flags_) + { + if (!cacheRegex || regex_ !== lastRegex || flags_ !== lastFlags) + { + cacheRegex = new RegExp(regex_, flags_); + lastRegex = regex_; + lastFlags = flags_; + } + cacheRegex.lastIndex = 0; // reset + return cacheRegex; + }; + SysCnds.prototype.RegexTest = function (str_, regex_, flags_) + { + var regex = getRegex(regex_, flags_); + return regex.test(str_); + }; + var tmp_arr = []; + SysCnds.prototype.PickOverlappingPoint = function (obj_, x_, y_) + { + if (!obj_) + return false; + var sol = obj_.getCurrentSol(); + var instances = sol.getObjects(); + var current_event = this.runtime.getCurrentEventStack().current_event; + var orblock = current_event.orblock; + var cnd = this.runtime.getCurrentCondition(); + var i, len, inst, pick; + if (sol.select_all) + { + cr.shallowAssignArray(tmp_arr, instances); + cr.clearArray(sol.else_instances); + sol.select_all = false; + cr.clearArray(sol.instances); + } + else + { + if (orblock) + { + cr.shallowAssignArray(tmp_arr, sol.else_instances); + cr.clearArray(sol.else_instances); + } + else + { + cr.shallowAssignArray(tmp_arr, instances); + cr.clearArray(sol.instances); + } + } + for (i = 0, len = tmp_arr.length; i < len; ++i) + { + inst = tmp_arr[i]; + inst.update_bbox(); + pick = cr.xor(inst.contains_pt(x_, y_), cnd.inverted); + if (pick) + sol.instances.push(inst); + else + sol.else_instances.push(inst); + } + obj_.applySolToContainer(); + return cr.xor(!!sol.instances.length, cnd.inverted); + }; + SysCnds.prototype.IsNaN = function (n) + { + return !!isNaN(n); + }; + SysCnds.prototype.AngleWithin = function (a1, within, a2) + { + return cr.angleDiff(cr.to_radians(a1), cr.to_radians(a2)) <= cr.to_radians(within); + }; + SysCnds.prototype.IsClockwiseFrom = function (a1, a2) + { + return cr.angleClockwise(cr.to_radians(a1), cr.to_radians(a2)); + }; + SysCnds.prototype.IsBetweenAngles = function (a, la, ua) + { + var angle = cr.to_clamped_radians(a); + var lower = cr.to_clamped_radians(la); + var upper = cr.to_clamped_radians(ua); + var obtuse = (!cr.angleClockwise(upper, lower)); + if (obtuse) + return !(!cr.angleClockwise(angle, lower) && cr.angleClockwise(angle, upper)); + else + return cr.angleClockwise(angle, lower) && !cr.angleClockwise(angle, upper); + }; + SysCnds.prototype.IsValueType = function (x, t) + { + if (typeof x === "number") + return t === 0; + else // string + return t === 1; + }; + sysProto.cnds = new SysCnds(); + function SysActs() {}; + SysActs.prototype.GoToLayout = function (to) + { + if (this.runtime.isloading) + return; // cannot change layout while loading on loader layout + if (this.runtime.changelayout) + return; // already changing to a different layout +; + this.runtime.changelayout = to; + }; + SysActs.prototype.NextPrevLayout = function (prev) + { + if (this.runtime.isloading) + return; // cannot change layout while loading on loader layout + if (this.runtime.changelayout) + return; // already changing to a different layout + var index = this.runtime.layouts_by_index.indexOf(this.runtime.running_layout); + if (prev && index === 0) + return; // cannot go to previous layout from first layout + if (!prev && index === this.runtime.layouts_by_index.length - 1) + return; // cannot go to next layout from last layout + var to = this.runtime.layouts_by_index[index + (prev ? -1 : 1)]; +; + this.runtime.changelayout = to; + }; + SysActs.prototype.CreateObject = function (obj, layer, x, y) + { + if (!layer || !obj) + return; + var inst = this.runtime.createInstance(obj, layer, x, y); + if (!inst) + return; + this.runtime.isInOnDestroy++; + var i, len, s; + this.runtime.trigger(Object.getPrototypeOf(obj.plugin).cnds.OnCreated, inst); + if (inst.is_contained) + { + for (i = 0, len = inst.siblings.length; i < len; i++) + { + s = inst.siblings[i]; + this.runtime.trigger(Object.getPrototypeOf(s.type.plugin).cnds.OnCreated, s); + } + } + this.runtime.isInOnDestroy--; + var sol = obj.getCurrentSol(); + sol.select_all = false; + cr.clearArray(sol.instances); + sol.instances[0] = inst; + if (inst.is_contained) + { + for (i = 0, len = inst.siblings.length; i < len; i++) + { + s = inst.siblings[i]; + sol = s.type.getCurrentSol(); + sol.select_all = false; + cr.clearArray(sol.instances); + sol.instances[0] = s; + } + } + }; + SysActs.prototype.SetLayerVisible = function (layer, visible_) + { + if (!layer) + return; + if (layer.visible !== visible_) + { + layer.visible = visible_; + this.runtime.redraw = true; + } + }; + SysActs.prototype.SetLayerOpacity = function (layer, opacity_) + { + if (!layer) + return; + opacity_ = cr.clamp(opacity_ / 100, 0, 1); + if (layer.opacity !== opacity_) + { + layer.opacity = opacity_; + this.runtime.redraw = true; + } + }; + SysActs.prototype.SetLayerScaleRate = function (layer, sr) + { + if (!layer) + return; + if (layer.zoomRate !== sr) + { + layer.zoomRate = sr; + this.runtime.redraw = true; + } + }; + SysActs.prototype.SetLayerForceOwnTexture = function (layer, f) + { + if (!layer) + return; + f = !!f; + if (layer.forceOwnTexture !== f) + { + layer.forceOwnTexture = f; + this.runtime.redraw = true; + } + }; + SysActs.prototype.SetLayoutScale = function (s) + { + if (!this.runtime.running_layout) + return; + if (this.runtime.running_layout.scale !== s) + { + this.runtime.running_layout.scale = s; + this.runtime.running_layout.boundScrolling(); + this.runtime.redraw = true; + } + }; + SysActs.prototype.ScrollX = function(x) + { + this.runtime.running_layout.scrollToX(x); + }; + SysActs.prototype.ScrollY = function(y) + { + this.runtime.running_layout.scrollToY(y); + }; + SysActs.prototype.Scroll = function(x, y) + { + this.runtime.running_layout.scrollToX(x); + this.runtime.running_layout.scrollToY(y); + }; + SysActs.prototype.ScrollToObject = function(obj) + { + var inst = obj.getFirstPicked(); + if (inst) + { + this.runtime.running_layout.scrollToX(inst.x); + this.runtime.running_layout.scrollToY(inst.y); + } + }; + SysActs.prototype.SetVar = function(v, x) + { +; + if (v.vartype === 0) + { + if (cr.is_number(x)) + v.setValue(x); + else + v.setValue(parseFloat(x)); + } + else if (v.vartype === 1) + v.setValue(x.toString()); + }; + SysActs.prototype.AddVar = function(v, x) + { +; + if (v.vartype === 0) + { + if (cr.is_number(x)) + v.setValue(v.getValue() + x); + else + v.setValue(v.getValue() + parseFloat(x)); + } + else if (v.vartype === 1) + v.setValue(v.getValue() + x.toString()); + }; + SysActs.prototype.SubVar = function(v, x) + { +; + if (v.vartype === 0) + { + if (cr.is_number(x)) + v.setValue(v.getValue() - x); + else + v.setValue(v.getValue() - parseFloat(x)); + } + }; + SysActs.prototype.SetGroupActive = function (group, active) + { + var g = this.runtime.groups_by_name[group.toLowerCase()]; + if (!g) + return; + switch (active) { + case 0: + g.setGroupActive(false); + break; + case 1: + g.setGroupActive(true); + break; + case 2: + g.setGroupActive(!g.group_active); + break; + } + }; + SysActs.prototype.SetTimescale = function (ts_) + { + var ts = ts_; + if (ts < 0) + ts = 0; + this.runtime.timescale = ts; + }; + SysActs.prototype.SetObjectTimescale = function (obj, ts_) + { + var ts = ts_; + if (ts < 0) + ts = 0; + if (!obj) + return; + var sol = obj.getCurrentSol(); + var instances = sol.getObjects(); + var i, len; + for (i = 0, len = instances.length; i < len; i++) + { + instances[i].my_timescale = ts; + } + }; + SysActs.prototype.RestoreObjectTimescale = function (obj) + { + if (!obj) + return false; + var sol = obj.getCurrentSol(); + var instances = sol.getObjects(); + var i, len; + for (i = 0, len = instances.length; i < len; i++) + { + instances[i].my_timescale = -1.0; + } + }; + var waitobjrecycle = []; + function allocWaitObject() + { + var w; + if (waitobjrecycle.length) + w = waitobjrecycle.pop(); + else + { + w = {}; + w.sols = {}; + w.solModifiers = []; + } + w.deleteme = false; + return w; + }; + function freeWaitObject(w) + { + cr.wipe(w.sols); + cr.clearArray(w.solModifiers); + waitobjrecycle.push(w); + }; + var solstateobjects = []; + function allocSolStateObject() + { + var s; + if (solstateobjects.length) + s = solstateobjects.pop(); + else + { + s = {}; + s.insts = []; + } + s.sa = false; + return s; + }; + function freeSolStateObject(s) + { + cr.clearArray(s.insts); + solstateobjects.push(s); + }; + SysActs.prototype.Wait = function (seconds) + { + if (seconds < 0) + return; + var i, len, s, t, ss; + var evinfo = this.runtime.getCurrentEventStack(); + var waitobj = allocWaitObject(); + waitobj.time = this.runtime.kahanTime.sum + seconds; + waitobj.signaltag = ""; + waitobj.signalled = false; + waitobj.ev = evinfo.current_event; + waitobj.actindex = evinfo.actindex + 1; // pointing at next action + for (i = 0, len = this.runtime.types_by_index.length; i < len; i++) + { + t = this.runtime.types_by_index[i]; + s = t.getCurrentSol(); + if (s.select_all && evinfo.current_event.solModifiers.indexOf(t) === -1) + continue; + waitobj.solModifiers.push(t); + ss = allocSolStateObject(); + ss.sa = s.select_all; + cr.shallowAssignArray(ss.insts, s.instances); + waitobj.sols[i.toString()] = ss; + } + this.waits.push(waitobj); + return true; + }; + SysActs.prototype.WaitForSignal = function (tag) + { + var i, len, s, t, ss; + var evinfo = this.runtime.getCurrentEventStack(); + var waitobj = allocWaitObject(); + waitobj.time = -1; + waitobj.signaltag = tag.toLowerCase(); + waitobj.signalled = false; + waitobj.ev = evinfo.current_event; + waitobj.actindex = evinfo.actindex + 1; // pointing at next action + for (i = 0, len = this.runtime.types_by_index.length; i < len; i++) + { + t = this.runtime.types_by_index[i]; + s = t.getCurrentSol(); + if (s.select_all && evinfo.current_event.solModifiers.indexOf(t) === -1) + continue; + waitobj.solModifiers.push(t); + ss = allocSolStateObject(); + ss.sa = s.select_all; + cr.shallowAssignArray(ss.insts, s.instances); + waitobj.sols[i.toString()] = ss; + } + this.waits.push(waitobj); + return true; + }; + SysActs.prototype.Signal = function (tag) + { + var lowertag = tag.toLowerCase(); + var i, len, w; + for (i = 0, len = this.waits.length; i < len; ++i) + { + w = this.waits[i]; + if (w.time !== -1) + continue; // timer wait, ignore + if (w.signaltag === lowertag) // waiting for this signal + w.signalled = true; // will run on next check + } + }; + SysActs.prototype.SetLayerScale = function (layer, scale) + { + if (!layer) + return; + if (layer.scale === scale) + return; + layer.scale = scale; + this.runtime.redraw = true; + }; + SysActs.prototype.ResetGlobals = function () + { + var i, len, g; + for (i = 0, len = this.runtime.all_global_vars.length; i < len; i++) + { + g = this.runtime.all_global_vars[i]; + g.data = g.initial; + } + }; + SysActs.prototype.SetLayoutAngle = function (a) + { + a = cr.to_radians(a); + a = cr.clamp_angle(a); + if (this.runtime.running_layout) + { + if (this.runtime.running_layout.angle !== a) + { + this.runtime.running_layout.angle = a; + this.runtime.redraw = true; + } + } + }; + SysActs.prototype.SetLayerAngle = function (layer, a) + { + if (!layer) + return; + a = cr.to_radians(a); + a = cr.clamp_angle(a); + if (layer.angle === a) + return; + layer.angle = a; + this.runtime.redraw = true; + }; + SysActs.prototype.SetLayerParallax = function (layer, px, py) + { + if (!layer) + return; + if (layer.parallaxX === px / 100 && layer.parallaxY === py / 100) + return; + layer.parallaxX = px / 100; + layer.parallaxY = py / 100; + if (layer.parallaxX !== 1 || layer.parallaxY !== 1) + { + var i, len, instances = layer.instances; + for (i = 0, len = instances.length; i < len; ++i) + { + instances[i].type.any_instance_parallaxed = true; + } + } + this.runtime.redraw = true; + }; + SysActs.prototype.SetLayerBackground = function (layer, c) + { + if (!layer) + return; + var r = cr.GetRValue(c); + var g = cr.GetGValue(c); + var b = cr.GetBValue(c); + if (layer.background_color[0] === r && layer.background_color[1] === g && layer.background_color[2] === b) + return; + layer.background_color[0] = r; + layer.background_color[1] = g; + layer.background_color[2] = b; + this.runtime.redraw = true; + }; + SysActs.prototype.SetLayerTransparent = function (layer, t) + { + if (!layer) + return; + if (!!t === !!layer.transparent) + return; + layer.transparent = !!t; + this.runtime.redraw = true; + }; + SysActs.prototype.SetLayerBlendMode = function (layer, bm) + { + if (!layer) + return; + if (layer.blend_mode === bm) + return; + layer.blend_mode = bm; + layer.compositeOp = cr.effectToCompositeOp(layer.blend_mode); + if (this.runtime.gl) + cr.setGLBlend(layer, layer.blend_mode, this.runtime.gl); + this.runtime.redraw = true; + }; + SysActs.prototype.StopLoop = function () + { + if (this.runtime.loop_stack_index < 0) + return; // no loop currently running + this.runtime.getCurrentLoop().stopped = true; + }; + SysActs.prototype.GoToLayoutByName = function (layoutname) + { + if (this.runtime.isloading) + return; // cannot change layout while loading on loader layout + if (this.runtime.changelayout) + return; // already changing to different layout +; + var l; + for (l in this.runtime.layouts) + { + if (this.runtime.layouts.hasOwnProperty(l) && cr.equals_nocase(l, layoutname)) + { + this.runtime.changelayout = this.runtime.layouts[l]; + return; + } + } + }; + SysActs.prototype.RestartLayout = function (layoutname) + { + if (this.runtime.isloading) + return; // cannot restart loader layouts + if (this.runtime.changelayout) + return; // already changing to a different layout +; + if (!this.runtime.running_layout) + return; + this.runtime.changelayout = this.runtime.running_layout; + var i, len, g; + for (i = 0, len = this.runtime.allGroups.length; i < len; i++) + { + g = this.runtime.allGroups[i]; + g.setGroupActive(g.initially_activated); + } + }; + SysActs.prototype.SnapshotCanvas = function (format_, quality_) + { + this.runtime.doCanvasSnapshot(format_ === 0 ? "image/png" : "image/jpeg", quality_ / 100); + }; + SysActs.prototype.SetCanvasSize = function (w, h) + { + if (w <= 0 || h <= 0) + return; + var mode = this.runtime.fullscreen_mode; + var isfullscreen = (document["mozFullScreen"] || document["webkitIsFullScreen"] || !!document["msFullscreenElement"] || document["fullScreen"] || this.runtime.isNodeFullscreen); + if (isfullscreen && this.runtime.fullscreen_scaling > 0) + mode = this.runtime.fullscreen_scaling; + if (mode === 0) + { + this.runtime["setSize"](w, h, true); + } + else + { + this.runtime.original_width = w; + this.runtime.original_height = h; + this.runtime["setSize"](this.runtime.lastWindowWidth, this.runtime.lastWindowHeight, true); + } + }; + SysActs.prototype.SetLayoutEffectEnabled = function (enable_, effectname_) + { + if (!this.runtime.running_layout || !this.runtime.glwrap) + return; + var et = this.runtime.running_layout.getEffectByName(effectname_); + if (!et) + return; // effect name not found + var enable = (enable_ === 1); + if (et.active == enable) + return; // no change + et.active = enable; + this.runtime.running_layout.updateActiveEffects(); + this.runtime.redraw = true; + }; + SysActs.prototype.SetLayerEffectEnabled = function (layer, enable_, effectname_) + { + if (!layer || !this.runtime.glwrap) + return; + var et = layer.getEffectByName(effectname_); + if (!et) + return; // effect name not found + var enable = (enable_ === 1); + if (et.active == enable) + return; // no change + et.active = enable; + layer.updateActiveEffects(); + this.runtime.redraw = true; + }; + SysActs.prototype.SetLayoutEffectParam = function (effectname_, index_, value_) + { + if (!this.runtime.running_layout || !this.runtime.glwrap) + return; + var et = this.runtime.running_layout.getEffectByName(effectname_); + if (!et) + return; // effect name not found + var params = this.runtime.running_layout.effect_params[et.index]; + index_ = Math.floor(index_); + if (index_ < 0 || index_ >= params.length) + return; // effect index out of bounds + if (this.runtime.glwrap.getProgramParameterType(et.shaderindex, index_) === 1) + value_ /= 100.0; + if (params[index_] === value_) + return; // no change + params[index_] = value_; + if (et.active) + this.runtime.redraw = true; + }; + SysActs.prototype.SetLayerEffectParam = function (layer, effectname_, index_, value_) + { + if (!layer || !this.runtime.glwrap) + return; + var et = layer.getEffectByName(effectname_); + if (!et) + return; // effect name not found + var params = layer.effect_params[et.index]; + index_ = Math.floor(index_); + if (index_ < 0 || index_ >= params.length) + return; // effect index out of bounds + if (this.runtime.glwrap.getProgramParameterType(et.shaderindex, index_) === 1) + value_ /= 100.0; + if (params[index_] === value_) + return; // no change + params[index_] = value_; + if (et.active) + this.runtime.redraw = true; + }; + SysActs.prototype.SaveState = function (slot_) + { + this.runtime.saveToSlot = slot_; + }; + SysActs.prototype.LoadState = function (slot_) + { + this.runtime.loadFromSlot = slot_; + }; + SysActs.prototype.LoadStateJSON = function (jsonstr_) + { + this.runtime.loadFromJson = jsonstr_; + }; + SysActs.prototype.SetHalfFramerateMode = function (set_) + { + this.runtime.halfFramerateMode = (set_ !== 0); + }; + SysActs.prototype.SetFullscreenQuality = function (q) + { + var isfullscreen = (document["mozFullScreen"] || document["webkitIsFullScreen"] || !!document["msFullscreenElement"] || document["fullScreen"] || this.isNodeFullscreen); + if (!isfullscreen && this.runtime.fullscreen_mode === 0) + return; + this.runtime.wantFullscreenScalingQuality = (q !== 0); + this.runtime["setSize"](this.runtime.lastWindowWidth, this.runtime.lastWindowHeight, true); + }; + SysActs.prototype.ResetPersisted = function () + { + var i, len; + for (i = 0, len = this.runtime.layouts_by_index.length; i < len; ++i) + { + this.runtime.layouts_by_index[i].persist_data = {}; + this.runtime.layouts_by_index[i].first_visit = true; + } + }; + SysActs.prototype.RecreateInitialObjects = function (obj, x1, y1, x2, y2) + { + if (!obj) + return; + this.runtime.running_layout.recreateInitialObjects(obj, x1, y1, x2, y2); + }; + SysActs.prototype.SetPixelRounding = function (m) + { + this.runtime.pixel_rounding = (m !== 0); + this.runtime.redraw = true; + }; + SysActs.prototype.SetMinimumFramerate = function (f) + { + if (f < 1) + f = 1; + if (f > 120) + f = 120; + this.runtime.minimumFramerate = f; + }; + function SortZOrderList(a, b) + { + var layerA = a[0]; + var layerB = b[0]; + var diff = layerA - layerB; + if (diff !== 0) + return diff; + var indexA = a[1]; + var indexB = b[1]; + return indexA - indexB; + }; + function SortInstancesByValue(a, b) + { + return a[1] - b[1]; + }; + SysActs.prototype.SortZOrderByInstVar = function (obj, iv) + { + if (!obj) + return; + var i, len, inst, value, r, layer, toZ; + var sol = obj.getCurrentSol(); + var pickedInstances = sol.getObjects(); + var zOrderList = []; + var instValues = []; + var layout = this.runtime.running_layout; + var isFamily = obj.is_family; + var familyIndex = obj.family_index; + for (i = 0, len = pickedInstances.length; i < len; ++i) + { + inst = pickedInstances[i]; + if (!inst.layer) + continue; // not a world instance + if (isFamily) + value = inst.instance_vars[iv + inst.type.family_var_map[familyIndex]]; + else + value = inst.instance_vars[iv]; + zOrderList.push([ + inst.layer.index, + inst.get_zindex() + ]); + instValues.push([ + inst, + value + ]); + } + if (!zOrderList.length) + return; // no instances were world instances + zOrderList.sort(SortZOrderList); + instValues.sort(SortInstancesByValue); + for (i = 0, len = zOrderList.length; i < len; ++i) + { + inst = instValues[i][0]; // instance in the order we want + layer = layout.layers[zOrderList[i][0]]; // layer to put it on + toZ = zOrderList[i][1]; // Z index on that layer to put it + if (layer.instances[toZ] !== inst) // not already got this instance there + { + layer.instances[toZ] = inst; // update instance + inst.layer = layer; // update instance's layer reference (could have changed) + layer.setZIndicesStaleFrom(toZ); // mark Z indices stale from this point since they have changed + } + } + }; + sysProto.acts = new SysActs(); + function SysExps() {}; + SysExps.prototype["int"] = function(ret, x) + { + if (cr.is_string(x)) + { + ret.set_int(parseInt(x, 10)); + if (isNaN(ret.data)) + ret.data = 0; + } + else + ret.set_int(x); + }; + SysExps.prototype["float"] = function(ret, x) + { + if (cr.is_string(x)) + { + ret.set_float(parseFloat(x)); + if (isNaN(ret.data)) + ret.data = 0; + } + else + ret.set_float(x); + }; + SysExps.prototype.str = function(ret, x) + { + if (cr.is_string(x)) + ret.set_string(x); + else + ret.set_string(x.toString()); + }; + SysExps.prototype.len = function(ret, x) + { + ret.set_int(x.length || 0); + }; + SysExps.prototype.random = function (ret, a, b) + { + if (b === undefined) + { + ret.set_float(Math.random() * a); + } + else + { + ret.set_float(Math.random() * (b - a) + a); + } + }; + SysExps.prototype.sqrt = function(ret, x) + { + ret.set_float(Math.sqrt(x)); + }; + SysExps.prototype.abs = function(ret, x) + { + ret.set_float(Math.abs(x)); + }; + SysExps.prototype.round = function(ret, x) + { + ret.set_int(Math.round(x)); + }; + SysExps.prototype.floor = function(ret, x) + { + ret.set_int(Math.floor(x)); + }; + SysExps.prototype.ceil = function(ret, x) + { + ret.set_int(Math.ceil(x)); + }; + SysExps.prototype.sin = function(ret, x) + { + ret.set_float(Math.sin(cr.to_radians(x))); + }; + SysExps.prototype.cos = function(ret, x) + { + ret.set_float(Math.cos(cr.to_radians(x))); + }; + SysExps.prototype.tan = function(ret, x) + { + ret.set_float(Math.tan(cr.to_radians(x))); + }; + SysExps.prototype.asin = function(ret, x) + { + ret.set_float(cr.to_degrees(Math.asin(x))); + }; + SysExps.prototype.acos = function(ret, x) + { + ret.set_float(cr.to_degrees(Math.acos(x))); + }; + SysExps.prototype.atan = function(ret, x) + { + ret.set_float(cr.to_degrees(Math.atan(x))); + }; + SysExps.prototype.exp = function(ret, x) + { + ret.set_float(Math.exp(x)); + }; + SysExps.prototype.ln = function(ret, x) + { + ret.set_float(Math.log(x)); + }; + SysExps.prototype.log10 = function(ret, x) + { + ret.set_float(Math.log(x) / Math.LN10); + }; + SysExps.prototype.max = function(ret) + { + var max_ = arguments[1]; + if (typeof max_ !== "number") + max_ = 0; + var i, len, a; + for (i = 2, len = arguments.length; i < len; i++) + { + a = arguments[i]; + if (typeof a !== "number") + continue; // ignore non-numeric types + if (max_ < a) + max_ = a; + } + ret.set_float(max_); + }; + SysExps.prototype.min = function(ret) + { + var min_ = arguments[1]; + if (typeof min_ !== "number") + min_ = 0; + var i, len, a; + for (i = 2, len = arguments.length; i < len; i++) + { + a = arguments[i]; + if (typeof a !== "number") + continue; // ignore non-numeric types + if (min_ > a) + min_ = a; + } + ret.set_float(min_); + }; + SysExps.prototype.dt = function(ret) + { + ret.set_float(this.runtime.dt); + }; + SysExps.prototype.timescale = function(ret) + { + ret.set_float(this.runtime.timescale); + }; + SysExps.prototype.wallclocktime = function(ret) + { + ret.set_float((Date.now() - this.runtime.start_time) / 1000.0); + }; + SysExps.prototype.time = function(ret) + { + ret.set_float(this.runtime.kahanTime.sum); + }; + SysExps.prototype.tickcount = function(ret) + { + ret.set_int(this.runtime.tickcount); + }; + SysExps.prototype.objectcount = function(ret) + { + ret.set_int(this.runtime.objectcount); + }; + SysExps.prototype.fps = function(ret) + { + ret.set_int(this.runtime.fps); + }; + SysExps.prototype.loopindex = function(ret, name_) + { + var loop, i, len; + if (!this.runtime.loop_stack.length) + { + ret.set_int(0); + return; + } + if (name_) + { + for (i = this.runtime.loop_stack_index; i >= 0; --i) + { + loop = this.runtime.loop_stack[i]; + if (loop.name === name_) + { + ret.set_int(loop.index); + return; + } + } + ret.set_int(0); + } + else + { + loop = this.runtime.getCurrentLoop(); + ret.set_int(loop ? loop.index : -1); + } + }; + SysExps.prototype.distance = function(ret, x1, y1, x2, y2) + { + ret.set_float(cr.distanceTo(x1, y1, x2, y2)); + }; + SysExps.prototype.angle = function(ret, x1, y1, x2, y2) + { + ret.set_float(cr.to_degrees(cr.angleTo(x1, y1, x2, y2))); + }; + SysExps.prototype.scrollx = function(ret) + { + ret.set_float(this.runtime.running_layout.scrollX); + }; + SysExps.prototype.scrolly = function(ret) + { + ret.set_float(this.runtime.running_layout.scrollY); + }; + SysExps.prototype.newline = function(ret) + { + ret.set_string("\n"); + }; + SysExps.prototype.lerp = function(ret, a, b, x) + { + ret.set_float(cr.lerp(a, b, x)); + }; + SysExps.prototype.qarp = function(ret, a, b, c, x) + { + ret.set_float(cr.qarp(a, b, c, x)); + }; + SysExps.prototype.cubic = function(ret, a, b, c, d, x) + { + ret.set_float(cr.cubic(a, b, c, d, x)); + }; + SysExps.prototype.cosp = function(ret, a, b, x) + { + ret.set_float(cr.cosp(a, b, x)); + }; + SysExps.prototype.windowwidth = function(ret) + { + ret.set_int(this.runtime.width); + }; + SysExps.prototype.windowheight = function(ret) + { + ret.set_int(this.runtime.height); + }; + SysExps.prototype.uppercase = function(ret, str) + { + ret.set_string(cr.is_string(str) ? str.toUpperCase() : ""); + }; + SysExps.prototype.lowercase = function(ret, str) + { + ret.set_string(cr.is_string(str) ? str.toLowerCase() : ""); + }; + SysExps.prototype.clamp = function(ret, x, l, u) + { + if (x < l) + ret.set_float(l); + else if (x > u) + ret.set_float(u); + else + ret.set_float(x); + }; + SysExps.prototype.layerscale = function (ret, layerparam) + { + var layer = this.runtime.getLayer(layerparam); + if (!layer) + ret.set_float(0); + else + ret.set_float(layer.scale); + }; + SysExps.prototype.layeropacity = function (ret, layerparam) + { + var layer = this.runtime.getLayer(layerparam); + if (!layer) + ret.set_float(0); + else + ret.set_float(layer.opacity * 100); + }; + SysExps.prototype.layerscalerate = function (ret, layerparam) + { + var layer = this.runtime.getLayer(layerparam); + if (!layer) + ret.set_float(0); + else + ret.set_float(layer.zoomRate); + }; + SysExps.prototype.layerparallaxx = function (ret, layerparam) + { + var layer = this.runtime.getLayer(layerparam); + if (!layer) + ret.set_float(0); + else + ret.set_float(layer.parallaxX * 100); + }; + SysExps.prototype.layerparallaxy = function (ret, layerparam) + { + var layer = this.runtime.getLayer(layerparam); + if (!layer) + ret.set_float(0); + else + ret.set_float(layer.parallaxY * 100); + }; + SysExps.prototype.layerindex = function (ret, layerparam) + { + var layer = this.runtime.getLayer(layerparam); + if (!layer) + ret.set_int(-1); + else + ret.set_int(layer.index); + }; + SysExps.prototype.layoutscale = function (ret) + { + if (this.runtime.running_layout) + ret.set_float(this.runtime.running_layout.scale); + else + ret.set_float(0); + }; + SysExps.prototype.layoutangle = function (ret) + { + ret.set_float(cr.to_degrees(this.runtime.running_layout.angle)); + }; + SysExps.prototype.layerangle = function (ret, layerparam) + { + var layer = this.runtime.getLayer(layerparam); + if (!layer) + ret.set_float(0); + else + ret.set_float(cr.to_degrees(layer.angle)); + }; + SysExps.prototype.layoutwidth = function (ret) + { + ret.set_int(this.runtime.running_layout.width); + }; + SysExps.prototype.layoutheight = function (ret) + { + ret.set_int(this.runtime.running_layout.height); + }; + SysExps.prototype.find = function (ret, text, searchstr) + { + if (cr.is_string(text) && cr.is_string(searchstr)) + ret.set_int(text.search(new RegExp(cr.regexp_escape(searchstr), "i"))); + else + ret.set_int(-1); + }; + SysExps.prototype.findcase = function (ret, text, searchstr) + { + if (cr.is_string(text) && cr.is_string(searchstr)) + ret.set_int(text.search(new RegExp(cr.regexp_escape(searchstr), ""))); + else + ret.set_int(-1); + }; + SysExps.prototype.left = function (ret, text, n) + { + ret.set_string(cr.is_string(text) ? text.substr(0, n) : ""); + }; + SysExps.prototype.right = function (ret, text, n) + { + ret.set_string(cr.is_string(text) ? text.substr(text.length - n) : ""); + }; + SysExps.prototype.mid = function (ret, text, index_, length_) + { + ret.set_string(cr.is_string(text) ? text.substr(index_, length_) : ""); + }; + SysExps.prototype.tokenat = function (ret, text, index_, sep) + { + if (cr.is_string(text) && cr.is_string(sep)) + { + var arr = text.split(sep); + var i = cr.floor(index_); + if (i < 0 || i >= arr.length) + ret.set_string(""); + else + ret.set_string(arr[i]); + } + else + ret.set_string(""); + }; + SysExps.prototype.tokencount = function (ret, text, sep) + { + if (cr.is_string(text) && text.length) + ret.set_int(text.split(sep).length); + else + ret.set_int(0); + }; + SysExps.prototype.replace = function (ret, text, find_, replace_) + { + if (cr.is_string(text) && cr.is_string(find_) && cr.is_string(replace_)) + ret.set_string(text.replace(new RegExp(cr.regexp_escape(find_), "gi"), replace_)); + else + ret.set_string(cr.is_string(text) ? text : ""); + }; + SysExps.prototype.trim = function (ret, text) + { + ret.set_string(cr.is_string(text) ? text.trim() : ""); + }; + SysExps.prototype.pi = function (ret) + { + ret.set_float(cr.PI); + }; + SysExps.prototype.layoutname = function (ret) + { + if (this.runtime.running_layout) + ret.set_string(this.runtime.running_layout.name); + else + ret.set_string(""); + }; + SysExps.prototype.renderer = function (ret) + { + ret.set_string(this.runtime.gl ? "webgl" : "canvas2d"); + }; + SysExps.prototype.rendererdetail = function (ret) + { + ret.set_string(this.runtime.glUnmaskedRenderer); + }; + SysExps.prototype.anglediff = function (ret, a, b) + { + ret.set_float(cr.to_degrees(cr.angleDiff(cr.to_radians(a), cr.to_radians(b)))); + }; + SysExps.prototype.choose = function (ret) + { + var index = cr.floor(Math.random() * (arguments.length - 1)); + ret.set_any(arguments[index + 1]); + }; + SysExps.prototype.rgb = function (ret, r, g, b) + { + ret.set_int(cr.RGB(r, g, b)); + }; + SysExps.prototype.projectversion = function (ret) + { + ret.set_string(this.runtime.versionstr); + }; + SysExps.prototype.projectname = function (ret) + { + ret.set_string(this.runtime.projectName); + }; + SysExps.prototype.anglelerp = function (ret, a, b, x) + { + a = cr.to_radians(a); + b = cr.to_radians(b); + var diff = cr.angleDiff(a, b); + if (cr.angleClockwise(b, a)) + { + ret.set_float(cr.to_clamped_degrees(a + diff * x)); + } + else + { + ret.set_float(cr.to_clamped_degrees(a - diff * x)); + } + }; + SysExps.prototype.anglerotate = function (ret, a, b, c) + { + a = cr.to_radians(a); + b = cr.to_radians(b); + c = cr.to_radians(c); + ret.set_float(cr.to_clamped_degrees(cr.angleRotate(a, b, c))); + }; + SysExps.prototype.zeropad = function (ret, n, d) + { + var s = (n < 0 ? "-" : ""); + if (n < 0) n = -n; + var zeroes = d - n.toString().length; + for (var i = 0; i < zeroes; i++) + s += "0"; + ret.set_string(s + n.toString()); + }; + SysExps.prototype.cpuutilisation = function (ret) + { + ret.set_float(this.runtime.cpuutilisation / 1000); + }; + SysExps.prototype.viewportleft = function (ret, layerparam) + { + var layer = this.runtime.getLayer(layerparam); + ret.set_float(layer ? layer.viewLeft : 0); + }; + SysExps.prototype.viewporttop = function (ret, layerparam) + { + var layer = this.runtime.getLayer(layerparam); + ret.set_float(layer ? layer.viewTop : 0); + }; + SysExps.prototype.viewportright = function (ret, layerparam) + { + var layer = this.runtime.getLayer(layerparam); + ret.set_float(layer ? layer.viewRight : 0); + }; + SysExps.prototype.viewportbottom = function (ret, layerparam) + { + var layer = this.runtime.getLayer(layerparam); + ret.set_float(layer ? layer.viewBottom : 0); + }; + SysExps.prototype.loadingprogress = function (ret) + { + ret.set_float(this.runtime.loadingprogress); + }; + SysExps.prototype.unlerp = function(ret, a, b, y) + { + ret.set_float(cr.unlerp(a, b, y)); + }; + SysExps.prototype.canvassnapshot = function (ret) + { + ret.set_string(this.runtime.snapshotData); + }; + SysExps.prototype.urlencode = function (ret, s) + { + ret.set_string(encodeURIComponent(s)); + }; + SysExps.prototype.urldecode = function (ret, s) + { + ret.set_string(decodeURIComponent(s)); + }; + SysExps.prototype.canvastolayerx = function (ret, layerparam, x, y) + { + var layer = this.runtime.getLayer(layerparam); + ret.set_float(layer ? layer.canvasToLayer(x, y, true) : 0); + }; + SysExps.prototype.canvastolayery = function (ret, layerparam, x, y) + { + var layer = this.runtime.getLayer(layerparam); + ret.set_float(layer ? layer.canvasToLayer(x, y, false) : 0); + }; + SysExps.prototype.layertocanvasx = function (ret, layerparam, x, y) + { + var layer = this.runtime.getLayer(layerparam); + ret.set_float(layer ? layer.layerToCanvas(x, y, true) : 0); + }; + SysExps.prototype.layertocanvasy = function (ret, layerparam, x, y) + { + var layer = this.runtime.getLayer(layerparam); + ret.set_float(layer ? layer.layerToCanvas(x, y, false) : 0); + }; + SysExps.prototype.savestatejson = function (ret) + { + ret.set_string(this.runtime.lastSaveJson); + }; + SysExps.prototype.imagememoryusage = function (ret) + { + if (this.runtime.glwrap) + ret.set_float(Math.round(100 * this.runtime.glwrap.estimateVRAM() / (1024 * 1024)) / 100); + else + ret.set_float(0); + }; + SysExps.prototype.regexsearch = function (ret, str_, regex_, flags_) + { + var regex = getRegex(regex_, flags_); + ret.set_int(str_ ? str_.search(regex) : -1); + }; + SysExps.prototype.regexreplace = function (ret, str_, regex_, flags_, replace_) + { + var regex = getRegex(regex_, flags_); + ret.set_string(str_ ? str_.replace(regex, replace_) : ""); + }; + var regexMatches = []; + var lastMatchesStr = ""; + var lastMatchesRegex = ""; + var lastMatchesFlags = ""; + function updateRegexMatches(str_, regex_, flags_) + { + if (str_ === lastMatchesStr && regex_ === lastMatchesRegex && flags_ === lastMatchesFlags) + return; + var regex = getRegex(regex_, flags_); + regexMatches = str_.match(regex); + lastMatchesStr = str_; + lastMatchesRegex = regex_; + lastMatchesFlags = flags_; + }; + SysExps.prototype.regexmatchcount = function (ret, str_, regex_, flags_) + { + var regex = getRegex(regex_, flags_); + updateRegexMatches(str_.toString(), regex_, flags_); + ret.set_int(regexMatches ? regexMatches.length : 0); + }; + SysExps.prototype.regexmatchat = function (ret, str_, regex_, flags_, index_) + { + index_ = Math.floor(index_); + var regex = getRegex(regex_, flags_); + updateRegexMatches(str_.toString(), regex_, flags_); + if (!regexMatches || index_ < 0 || index_ >= regexMatches.length) + ret.set_string(""); + else + ret.set_string(regexMatches[index_]); + }; + SysExps.prototype.infinity = function (ret) + { + ret.set_float(Infinity); + }; + SysExps.prototype.setbit = function (ret, n, b, v) + { + n = n | 0; + b = b | 0; + v = (v !== 0 ? 1 : 0); + ret.set_int((n & ~(1 << b)) | (v << b)); + }; + SysExps.prototype.togglebit = function (ret, n, b) + { + n = n | 0; + b = b | 0; + ret.set_int(n ^ (1 << b)); + }; + SysExps.prototype.getbit = function (ret, n, b) + { + n = n | 0; + b = b | 0; + ret.set_int((n & (1 << b)) ? 1 : 0); + }; + SysExps.prototype.originalwindowwidth = function (ret) + { + ret.set_int(this.runtime.original_width); + }; + SysExps.prototype.originalwindowheight = function (ret) + { + ret.set_int(this.runtime.original_height); + }; + sysProto.exps = new SysExps(); + sysProto.runWaits = function () + { + var i, j, len, w, k, s, ss; + var evinfo = this.runtime.getCurrentEventStack(); + for (i = 0, len = this.waits.length; i < len; i++) + { + w = this.waits[i]; + if (w.time === -1) // signalled wait + { + if (!w.signalled) + continue; // not yet signalled + } + else // timer wait + { + if (w.time > this.runtime.kahanTime.sum) + continue; // timer not yet expired + } + evinfo.current_event = w.ev; + evinfo.actindex = w.actindex; + evinfo.cndindex = 0; + for (k in w.sols) + { + if (w.sols.hasOwnProperty(k)) + { + s = this.runtime.types_by_index[parseInt(k, 10)].getCurrentSol(); + ss = w.sols[k]; + s.select_all = ss.sa; + cr.shallowAssignArray(s.instances, ss.insts); + freeSolStateObject(ss); + } + } + w.ev.resume_actions_and_subevents(); + this.runtime.clearSol(w.solModifiers); + w.deleteme = true; + } + for (i = 0, j = 0, len = this.waits.length; i < len; i++) + { + w = this.waits[i]; + this.waits[j] = w; + if (w.deleteme) + freeWaitObject(w); + else + j++; + } + cr.truncateArray(this.waits, j); + }; +}()); +; +(function () { + cr.add_common_aces = function (m, pluginProto) + { + var singleglobal_ = m[1]; + var position_aces = m[3]; + var size_aces = m[4]; + var angle_aces = m[5]; + var appearance_aces = m[6]; + var zorder_aces = m[7]; + var effects_aces = m[8]; + if (!pluginProto.cnds) + pluginProto.cnds = {}; + if (!pluginProto.acts) + pluginProto.acts = {}; + if (!pluginProto.exps) + pluginProto.exps = {}; + var cnds = pluginProto.cnds; + var acts = pluginProto.acts; + var exps = pluginProto.exps; + if (position_aces) + { + cnds.CompareX = function (cmp, x) + { + return cr.do_cmp(this.x, cmp, x); + }; + cnds.CompareY = function (cmp, y) + { + return cr.do_cmp(this.y, cmp, y); + }; + cnds.IsOnScreen = function () + { + var layer = this.layer; + this.update_bbox(); + var bbox = this.bbox; + return !(bbox.right < layer.viewLeft || bbox.bottom < layer.viewTop || bbox.left > layer.viewRight || bbox.top > layer.viewBottom); + }; + cnds.IsOutsideLayout = function () + { + this.update_bbox(); + var bbox = this.bbox; + var layout = this.runtime.running_layout; + return (bbox.right < 0 || bbox.bottom < 0 || bbox.left > layout.width || bbox.top > layout.height); + }; + cnds.PickDistance = function (which, x, y) + { + var sol = this.getCurrentSol(); + var instances = sol.getObjects(); + if (!instances.length) + return false; + var inst = instances[0]; + var pickme = inst; + var dist = cr.distanceTo(inst.x, inst.y, x, y); + var i, len, d; + for (i = 1, len = instances.length; i < len; i++) + { + inst = instances[i]; + d = cr.distanceTo(inst.x, inst.y, x, y); + if ((which === 0 && d < dist) || (which === 1 && d > dist)) + { + dist = d; + pickme = inst; + } + } + sol.pick_one(pickme); + return true; + }; + acts.SetX = function (x) + { + if (this.x !== x) + { + this.x = x; + this.set_bbox_changed(); + } + }; + acts.SetY = function (y) + { + if (this.y !== y) + { + this.y = y; + this.set_bbox_changed(); + } + }; + acts.SetPos = function (x, y) + { + if (this.x !== x || this.y !== y) + { + this.x = x; + this.y = y; + this.set_bbox_changed(); + } + }; + acts.SetPosToObject = function (obj, imgpt) + { + var inst = obj.getPairedInstance(this); + if (!inst) + return; + var newx, newy; + if (inst.getImagePoint) + { + newx = inst.getImagePoint(imgpt, true); + newy = inst.getImagePoint(imgpt, false); + } + else + { + newx = inst.x; + newy = inst.y; + } + if (this.x !== newx || this.y !== newy) + { + this.x = newx; + this.y = newy; + this.set_bbox_changed(); + } + }; + acts.MoveForward = function (dist) + { + if (dist !== 0) + { + this.x += Math.cos(this.angle) * dist; + this.y += Math.sin(this.angle) * dist; + this.set_bbox_changed(); + } + }; + acts.MoveAtAngle = function (a, dist) + { + if (dist !== 0) + { + this.x += Math.cos(cr.to_radians(a)) * dist; + this.y += Math.sin(cr.to_radians(a)) * dist; + this.set_bbox_changed(); + } + }; + exps.X = function (ret) + { + ret.set_float(this.x); + }; + exps.Y = function (ret) + { + ret.set_float(this.y); + }; + exps.dt = function (ret) + { + ret.set_float(this.runtime.getDt(this)); + }; + } + if (size_aces) + { + cnds.CompareWidth = function (cmp, w) + { + return cr.do_cmp(this.width, cmp, w); + }; + cnds.CompareHeight = function (cmp, h) + { + return cr.do_cmp(this.height, cmp, h); + }; + acts.SetWidth = function (w) + { + if (this.width !== w) + { + this.width = w; + this.set_bbox_changed(); + } + }; + acts.SetHeight = function (h) + { + if (this.height !== h) + { + this.height = h; + this.set_bbox_changed(); + } + }; + acts.SetSize = function (w, h) + { + if (this.width !== w || this.height !== h) + { + this.width = w; + this.height = h; + this.set_bbox_changed(); + } + }; + exps.Width = function (ret) + { + ret.set_float(this.width); + }; + exps.Height = function (ret) + { + ret.set_float(this.height); + }; + exps.BBoxLeft = function (ret) + { + this.update_bbox(); + ret.set_float(this.bbox.left); + }; + exps.BBoxTop = function (ret) + { + this.update_bbox(); + ret.set_float(this.bbox.top); + }; + exps.BBoxRight = function (ret) + { + this.update_bbox(); + ret.set_float(this.bbox.right); + }; + exps.BBoxBottom = function (ret) + { + this.update_bbox(); + ret.set_float(this.bbox.bottom); + }; + } + if (angle_aces) + { + cnds.AngleWithin = function (within, a) + { + return cr.angleDiff(this.angle, cr.to_radians(a)) <= cr.to_radians(within); + }; + cnds.IsClockwiseFrom = function (a) + { + return cr.angleClockwise(this.angle, cr.to_radians(a)); + }; + cnds.IsBetweenAngles = function (a, b) + { + var lower = cr.to_clamped_radians(a); + var upper = cr.to_clamped_radians(b); + var angle = cr.clamp_angle(this.angle); + var obtuse = (!cr.angleClockwise(upper, lower)); + if (obtuse) + return !(!cr.angleClockwise(angle, lower) && cr.angleClockwise(angle, upper)); + else + return cr.angleClockwise(angle, lower) && !cr.angleClockwise(angle, upper); + }; + acts.SetAngle = function (a) + { + var newangle = cr.to_radians(cr.clamp_angle_degrees(a)); + if (isNaN(newangle)) + return; + if (this.angle !== newangle) + { + this.angle = newangle; + this.set_bbox_changed(); + } + }; + acts.RotateClockwise = function (a) + { + if (a !== 0 && !isNaN(a)) + { + this.angle += cr.to_radians(a); + this.angle = cr.clamp_angle(this.angle); + this.set_bbox_changed(); + } + }; + acts.RotateCounterclockwise = function (a) + { + if (a !== 0 && !isNaN(a)) + { + this.angle -= cr.to_radians(a); + this.angle = cr.clamp_angle(this.angle); + this.set_bbox_changed(); + } + }; + acts.RotateTowardAngle = function (amt, target) + { + var newangle = cr.angleRotate(this.angle, cr.to_radians(target), cr.to_radians(amt)); + if (isNaN(newangle)) + return; + if (this.angle !== newangle) + { + this.angle = newangle; + this.set_bbox_changed(); + } + }; + acts.RotateTowardPosition = function (amt, x, y) + { + var dx = x - this.x; + var dy = y - this.y; + var target = Math.atan2(dy, dx); + var newangle = cr.angleRotate(this.angle, target, cr.to_radians(amt)); + if (isNaN(newangle)) + return; + if (this.angle !== newangle) + { + this.angle = newangle; + this.set_bbox_changed(); + } + }; + acts.SetTowardPosition = function (x, y) + { + var dx = x - this.x; + var dy = y - this.y; + var newangle = Math.atan2(dy, dx); + if (isNaN(newangle)) + return; + if (this.angle !== newangle) + { + this.angle = newangle; + this.set_bbox_changed(); + } + }; + exps.Angle = function (ret) + { + ret.set_float(cr.to_clamped_degrees(this.angle)); + }; + } + if (!singleglobal_) + { + cnds.CompareInstanceVar = function (iv, cmp, val) + { + return cr.do_cmp(this.instance_vars[iv], cmp, val); + }; + cnds.IsBoolInstanceVarSet = function (iv) + { + return this.instance_vars[iv]; + }; + cnds.PickInstVarHiLow = function (which, iv) + { + var sol = this.getCurrentSol(); + var instances = sol.getObjects(); + if (!instances.length) + return false; + var inst = instances[0]; + var pickme = inst; + var val = inst.instance_vars[iv]; + var i, len, v; + for (i = 1, len = instances.length; i < len; i++) + { + inst = instances[i]; + v = inst.instance_vars[iv]; + if ((which === 0 && v < val) || (which === 1 && v > val)) + { + val = v; + pickme = inst; + } + } + sol.pick_one(pickme); + return true; + }; + cnds.PickByUID = function (u) + { + var i, len, j, inst, families, instances, sol; + var cnd = this.runtime.getCurrentCondition(); + if (cnd.inverted) + { + sol = this.getCurrentSol(); + if (sol.select_all) + { + sol.select_all = false; + cr.clearArray(sol.instances); + cr.clearArray(sol.else_instances); + instances = this.instances; + for (i = 0, len = instances.length; i < len; i++) + { + inst = instances[i]; + if (inst.uid === u) + sol.else_instances.push(inst); + else + sol.instances.push(inst); + } + this.applySolToContainer(); + return !!sol.instances.length; + } + else + { + for (i = 0, j = 0, len = sol.instances.length; i < len; i++) + { + inst = sol.instances[i]; + sol.instances[j] = inst; + if (inst.uid === u) + { + sol.else_instances.push(inst); + } + else + j++; + } + cr.truncateArray(sol.instances, j); + this.applySolToContainer(); + return !!sol.instances.length; + } + } + else + { + inst = this.runtime.getObjectByUID(u); + if (!inst) + return false; + sol = this.getCurrentSol(); + if (!sol.select_all && sol.instances.indexOf(inst) === -1) + return false; // not picked + if (this.is_family) + { + families = inst.type.families; + for (i = 0, len = families.length; i < len; i++) + { + if (families[i] === this) + { + sol.pick_one(inst); + this.applySolToContainer(); + return true; + } + } + } + else if (inst.type === this) + { + sol.pick_one(inst); + this.applySolToContainer(); + return true; + } + return false; + } + }; + cnds.OnCreated = function () + { + return true; + }; + cnds.OnDestroyed = function () + { + return true; + }; + acts.SetInstanceVar = function (iv, val) + { + var myinstvars = this.instance_vars; + if (cr.is_number(myinstvars[iv])) + { + if (cr.is_number(val)) + myinstvars[iv] = val; + else + myinstvars[iv] = parseFloat(val); + } + else if (cr.is_string(myinstvars[iv])) + { + if (cr.is_string(val)) + myinstvars[iv] = val; + else + myinstvars[iv] = val.toString(); + } + else +; + }; + acts.AddInstanceVar = function (iv, val) + { + var myinstvars = this.instance_vars; + if (cr.is_number(myinstvars[iv])) + { + if (cr.is_number(val)) + myinstvars[iv] += val; + else + myinstvars[iv] += parseFloat(val); + } + else if (cr.is_string(myinstvars[iv])) + { + if (cr.is_string(val)) + myinstvars[iv] += val; + else + myinstvars[iv] += val.toString(); + } + else +; + }; + acts.SubInstanceVar = function (iv, val) + { + var myinstvars = this.instance_vars; + if (cr.is_number(myinstvars[iv])) + { + if (cr.is_number(val)) + myinstvars[iv] -= val; + else + myinstvars[iv] -= parseFloat(val); + } + else +; + }; + acts.SetBoolInstanceVar = function (iv, val) + { + this.instance_vars[iv] = val ? 1 : 0; + }; + acts.ToggleBoolInstanceVar = function (iv) + { + this.instance_vars[iv] = 1 - this.instance_vars[iv]; + }; + acts.Destroy = function () + { + this.runtime.DestroyInstance(this); + }; + if (!acts.LoadFromJsonString) + { + acts.LoadFromJsonString = function (str_) + { + var o, i, len, binst; + try { + o = JSON.parse(str_); + } + catch (e) { + return; + } + this.runtime.loadInstanceFromJSON(this, o, true); + if (this.afterLoad) + this.afterLoad(); + if (this.behavior_insts) + { + for (i = 0, len = this.behavior_insts.length; i < len; ++i) + { + binst = this.behavior_insts[i]; + if (binst.afterLoad) + binst.afterLoad(); + } + } + }; + } + exps.Count = function (ret) + { + var count = ret.object_class.instances.length; + var i, len, inst; + for (i = 0, len = this.runtime.createRow.length; i < len; i++) + { + inst = this.runtime.createRow[i]; + if (ret.object_class.is_family) + { + if (inst.type.families.indexOf(ret.object_class) >= 0) + count++; + } + else + { + if (inst.type === ret.object_class) + count++; + } + } + ret.set_int(count); + }; + exps.PickedCount = function (ret) + { + ret.set_int(ret.object_class.getCurrentSol().getObjects().length); + }; + exps.UID = function (ret) + { + ret.set_int(this.uid); + }; + exps.IID = function (ret) + { + ret.set_int(this.get_iid()); + }; + if (!exps.AsJSON) + { + exps.AsJSON = function (ret) + { + ret.set_string(JSON.stringify(this.runtime.saveInstanceToJSON(this, true))); + }; + } + } + if (appearance_aces) + { + cnds.IsVisible = function () + { + return this.visible; + }; + acts.SetVisible = function (v) + { + if (!v !== !this.visible) + { + this.visible = !!v; + this.runtime.redraw = true; + } + }; + cnds.CompareOpacity = function (cmp, x) + { + return cr.do_cmp(cr.round6dp(this.opacity * 100), cmp, x); + }; + acts.SetOpacity = function (x) + { + var new_opacity = x / 100.0; + if (new_opacity < 0) + new_opacity = 0; + else if (new_opacity > 1) + new_opacity = 1; + if (new_opacity !== this.opacity) + { + this.opacity = new_opacity; + this.runtime.redraw = true; + } + }; + exps.Opacity = function (ret) + { + ret.set_float(cr.round6dp(this.opacity * 100.0)); + }; + } + if (zorder_aces) + { + cnds.IsOnLayer = function (layer_) + { + if (!layer_) + return false; + return this.layer === layer_; + }; + cnds.PickTopBottom = function (which_) + { + var sol = this.getCurrentSol(); + var instances = sol.getObjects(); + if (!instances.length) + return false; + var inst = instances[0]; + var pickme = inst; + var i, len; + for (i = 1, len = instances.length; i < len; i++) + { + inst = instances[i]; + if (which_ === 0) + { + if (inst.layer.index > pickme.layer.index || (inst.layer.index === pickme.layer.index && inst.get_zindex() > pickme.get_zindex())) + { + pickme = inst; + } + } + else + { + if (inst.layer.index < pickme.layer.index || (inst.layer.index === pickme.layer.index && inst.get_zindex() < pickme.get_zindex())) + { + pickme = inst; + } + } + } + sol.pick_one(pickme); + return true; + }; + acts.MoveToTop = function () + { + var layer = this.layer; + var layer_instances = layer.instances; + if (layer_instances.length && layer_instances[layer_instances.length - 1] === this) + return; // is already at top + layer.removeFromInstanceList(this, false); + layer.appendToInstanceList(this, false); + this.runtime.redraw = true; + }; + acts.MoveToBottom = function () + { + var layer = this.layer; + var layer_instances = layer.instances; + if (layer_instances.length && layer_instances[0] === this) + return; // is already at bottom + layer.removeFromInstanceList(this, false); + layer.prependToInstanceList(this, false); + this.runtime.redraw = true; + }; + acts.MoveToLayer = function (layerMove) + { + if (!layerMove || layerMove == this.layer) + return; + this.layer.removeFromInstanceList(this, true); + this.layer = layerMove; + layerMove.appendToInstanceList(this, true); + this.runtime.redraw = true; + }; + acts.ZMoveToObject = function (where_, obj_) + { + var isafter = (where_ === 0); + if (!obj_) + return; + var other = obj_.getFirstPicked(this); + if (!other || other.uid === this.uid) + return; + if (this.layer.index !== other.layer.index) + { + this.layer.removeFromInstanceList(this, true); + this.layer = other.layer; + other.layer.appendToInstanceList(this, true); + } + this.layer.moveInstanceAdjacent(this, other, isafter); + this.runtime.redraw = true; + }; + exps.LayerNumber = function (ret) + { + ret.set_int(this.layer.number); + }; + exps.LayerName = function (ret) + { + ret.set_string(this.layer.name); + }; + exps.ZIndex = function (ret) + { + ret.set_int(this.get_zindex()); + }; + } + if (effects_aces) + { + acts.SetEffectEnabled = function (enable_, effectname_) + { + if (!this.runtime.glwrap) + return; + var i = this.type.getEffectIndexByName(effectname_); + if (i < 0) + return; // effect name not found + var enable = (enable_ === 1); + if (this.active_effect_flags[i] === enable) + return; // no change + this.active_effect_flags[i] = enable; + this.updateActiveEffects(); + this.runtime.redraw = true; + }; + acts.SetEffectParam = function (effectname_, index_, value_) + { + if (!this.runtime.glwrap) + return; + var i = this.type.getEffectIndexByName(effectname_); + if (i < 0) + return; // effect name not found + var et = this.type.effect_types[i]; + var params = this.effect_params[i]; + index_ = Math.floor(index_); + if (index_ < 0 || index_ >= params.length) + return; // effect index out of bounds + if (this.runtime.glwrap.getProgramParameterType(et.shaderindex, index_) === 1) + value_ /= 100.0; + if (params[index_] === value_) + return; // no change + params[index_] = value_; + if (et.active) + this.runtime.redraw = true; + }; + } + }; + cr.set_bbox_changed = function () + { + this.bbox_changed = true; // will recreate next time box requested + this.cell_changed = true; + this.type.any_cell_changed = true; // avoid unnecessary updateAllBBox() calls + this.runtime.redraw = true; // assume runtime needs to redraw + var i, len, callbacks = this.bbox_changed_callbacks; + for (i = 0, len = callbacks.length; i < len; ++i) + { + callbacks[i](this); + } + if (this.layer.useRenderCells) + this.update_bbox(); + }; + cr.add_bbox_changed_callback = function (f) + { + if (f) + { + this.bbox_changed_callbacks.push(f); + } + }; + cr.update_bbox = function () + { + if (!this.bbox_changed) + return; // bounding box not changed + var bbox = this.bbox; + var bquad = this.bquad; + bbox.set(this.x, this.y, this.x + this.width, this.y + this.height); + bbox.offset(-this.hotspotX * this.width, -this.hotspotY * this.height); + if (!this.angle) + { + bquad.set_from_rect(bbox); // make bounding quad from box + } + else + { + bbox.offset(-this.x, -this.y); // translate to origin + bquad.set_from_rotated_rect(bbox, this.angle); // rotate around origin + bquad.offset(this.x, this.y); // translate back to original position + bquad.bounding_box(bbox); + } + bbox.normalize(); + this.bbox_changed = false; // bounding box up to date + this.update_render_cell(); + }; + var tmprc = new cr.rect(0, 0, 0, 0); + cr.update_render_cell = function () + { + if (!this.layer.useRenderCells) + return; + var mygrid = this.layer.render_grid; + var bbox = this.bbox; + tmprc.set(mygrid.XToCell(bbox.left), mygrid.YToCell(bbox.top), mygrid.XToCell(bbox.right), mygrid.YToCell(bbox.bottom)); + if (this.rendercells.equals(tmprc)) + return; + if (this.rendercells.right < this.rendercells.left) + mygrid.update(this, null, tmprc); // first insertion with invalid rect: don't provide old range + else + mygrid.update(this, this.rendercells, tmprc); + this.rendercells.copy(tmprc); + this.layer.render_list_stale = true; + }; + cr.update_collision_cell = function () + { + if (!this.cell_changed || !this.collisionsEnabled) + return; + this.update_bbox(); + var mygrid = this.type.collision_grid; + var bbox = this.bbox; + tmprc.set(mygrid.XToCell(bbox.left), mygrid.YToCell(bbox.top), mygrid.XToCell(bbox.right), mygrid.YToCell(bbox.bottom)); + if (this.collcells.equals(tmprc)) + return; + if (this.collcells.right < this.collcells.left) + mygrid.update(this, null, tmprc); // first insertion with invalid rect: don't provide old range + else + mygrid.update(this, this.collcells, tmprc); + this.collcells.copy(tmprc); + this.cell_changed = false; + }; + cr.inst_contains_pt = function (x, y) + { + if (!this.bbox.contains_pt(x, y)) + return false; + if (!this.bquad.contains_pt(x, y)) + return false; + if (this.tilemap_exists) + return this.testPointOverlapTile(x, y); + if (this.collision_poly && !this.collision_poly.is_empty()) + { + this.collision_poly.cache_poly(this.width, this.height, this.angle); + return this.collision_poly.contains_pt(x - this.x, y - this.y); + } + else + return true; + }; + cr.inst_get_iid = function () + { + this.type.updateIIDs(); + return this.iid; + }; + cr.inst_get_zindex = function () + { + this.layer.updateZIndices(); + return this.zindex; + }; + cr.inst_updateActiveEffects = function () + { + cr.clearArray(this.active_effect_types); + var i, len, et; + var preserves_opaqueness = true; + for (i = 0, len = this.active_effect_flags.length; i < len; i++) + { + if (this.active_effect_flags[i]) + { + et = this.type.effect_types[i]; + this.active_effect_types.push(et); + if (!et.preservesOpaqueness) + preserves_opaqueness = false; + } + } + this.uses_shaders = !!this.active_effect_types.length; + this.shaders_preserve_opaqueness = preserves_opaqueness; + }; + cr.inst_toString = function () + { + return "Inst" + this.puid; + }; + cr.type_getFirstPicked = function (frominst) + { + if (frominst && frominst.is_contained && frominst.type != this) + { + var i, len, s; + for (i = 0, len = frominst.siblings.length; i < len; i++) + { + s = frominst.siblings[i]; + if (s.type == this) + return s; + } + } + var instances = this.getCurrentSol().getObjects(); + if (instances.length) + return instances[0]; + else + return null; + }; + cr.type_getPairedInstance = function (inst) + { + var instances = this.getCurrentSol().getObjects(); + if (instances.length) + return instances[inst.get_iid() % instances.length]; + else + return null; + }; + cr.type_updateIIDs = function () + { + if (!this.stale_iids || this.is_family) + return; // up to date or is family - don't want family to overwrite IIDs + var i, len; + for (i = 0, len = this.instances.length; i < len; i++) + this.instances[i].iid = i; + var next_iid = i; + var createRow = this.runtime.createRow; + for (i = 0, len = createRow.length; i < len; ++i) + { + if (createRow[i].type === this) + createRow[i].iid = next_iid++; + } + this.stale_iids = false; + }; + cr.type_getInstanceByIID = function (i) + { + if (i < this.instances.length) + return this.instances[i]; + i -= this.instances.length; + var createRow = this.runtime.createRow; + var j, lenj; + for (j = 0, lenj = createRow.length; j < lenj; ++j) + { + if (createRow[j].type === this) + { + if (i === 0) + return createRow[j]; + --i; + } + } +; + return null; + }; + cr.type_getCurrentSol = function () + { + return this.solstack[this.cur_sol]; + }; + cr.type_pushCleanSol = function () + { + this.cur_sol++; + if (this.cur_sol === this.solstack.length) + { + this.solstack.push(new cr.selection(this)); + } + else + { + this.solstack[this.cur_sol].select_all = true; // else clear next SOL + cr.clearArray(this.solstack[this.cur_sol].else_instances); + } + }; + cr.type_pushCopySol = function () + { + this.cur_sol++; + if (this.cur_sol === this.solstack.length) + this.solstack.push(new cr.selection(this)); + var clonesol = this.solstack[this.cur_sol]; + var prevsol = this.solstack[this.cur_sol - 1]; + if (prevsol.select_all) + { + clonesol.select_all = true; + } + else + { + clonesol.select_all = false; + cr.shallowAssignArray(clonesol.instances, prevsol.instances); + } + cr.clearArray(clonesol.else_instances); + }; + cr.type_popSol = function () + { +; + this.cur_sol--; + }; + cr.type_getBehaviorByName = function (behname) + { + var i, len, j, lenj, f, index = 0; + if (!this.is_family) + { + for (i = 0, len = this.families.length; i < len; i++) + { + f = this.families[i]; + for (j = 0, lenj = f.behaviors.length; j < lenj; j++) + { + if (behname === f.behaviors[j].name) + { + this.extra["lastBehIndex"] = index; + return f.behaviors[j]; + } + index++; + } + } + } + for (i = 0, len = this.behaviors.length; i < len; i++) { + if (behname === this.behaviors[i].name) + { + this.extra["lastBehIndex"] = index; + return this.behaviors[i]; + } + index++; + } + return null; + }; + cr.type_getBehaviorIndexByName = function (behname) + { + var b = this.getBehaviorByName(behname); + if (b) + return this.extra["lastBehIndex"]; + else + return -1; + }; + cr.type_getEffectIndexByName = function (name_) + { + var i, len; + for (i = 0, len = this.effect_types.length; i < len; i++) + { + if (this.effect_types[i].name === name_) + return i; + } + return -1; + }; + cr.type_applySolToContainer = function () + { + if (!this.is_contained || this.is_family) + return; + var i, len, j, lenj, t, sol, sol2; + this.updateIIDs(); + sol = this.getCurrentSol(); + var select_all = sol.select_all; + var es = this.runtime.getCurrentEventStack(); + var orblock = es && es.current_event && es.current_event.orblock; + for (i = 0, len = this.container.length; i < len; i++) + { + t = this.container[i]; + if (t === this) + continue; + t.updateIIDs(); + sol2 = t.getCurrentSol(); + sol2.select_all = select_all; + if (!select_all) + { + cr.clearArray(sol2.instances); + for (j = 0, lenj = sol.instances.length; j < lenj; ++j) + sol2.instances[j] = t.getInstanceByIID(sol.instances[j].iid); + if (orblock) + { + cr.clearArray(sol2.else_instances); + for (j = 0, lenj = sol.else_instances.length; j < lenj; ++j) + sol2.else_instances[j] = t.getInstanceByIID(sol.else_instances[j].iid); + } + } + } + }; + cr.type_toString = function () + { + return "Type" + this.sid; + }; + cr.do_cmp = function (x, cmp, y) + { + if (typeof x === "undefined" || typeof y === "undefined") + return false; + switch (cmp) + { + case 0: // equal + return x === y; + case 1: // not equal + return x !== y; + case 2: // less + return x < y; + case 3: // less/equal + return x <= y; + case 4: // greater + return x > y; + case 5: // greater/equal + return x >= y; + default: +; + return false; + } + }; +})(); +cr.shaders = {}; +cr.shaders["blacknwhite"] = {src: ["varying mediump vec2 vTex;", +"uniform lowp sampler2D samplerFront;", +"uniform lowp float threshold;", +"void main(void)", +"{", +"lowp vec4 front = texture2D(samplerFront, vTex);", +"lowp float gray = front.r * 0.299 + front.g * 0.587 + front.b * 0.114;", +"if (gray < threshold)", +"gl_FragColor = vec4(0.0, 0.0, 0.0, front.a);", +"else", +"gl_FragColor = vec4(front.a, front.a, front.a, front.a);", +"}" +].join("\n"), + extendBoxHorizontal: 0, + extendBoxVertical: 0, + crossSampling: false, + preservesOpaqueness: true, + animated: false, + parameters: [["threshold", 0, 1]] } +cr.shaders["setcolor"] = {src: ["varying mediump vec2 vTex;", +"uniform lowp sampler2D samplerFront;", +"uniform lowp float red;", +"uniform lowp float green;", +"uniform lowp float blue;", +"void main(void)", +"{", +"lowp float a = texture2D(samplerFront, vTex).a;", +"gl_FragColor = vec4(red * a, green * a, blue * a, a);", +"}" +].join("\n"), + extendBoxHorizontal: 0, + extendBoxVertical: 0, + crossSampling: false, + preservesOpaqueness: true, + animated: false, + parameters: [["red", 0, 1], ["green", 0, 1], ["blue", 0, 1]] } +; +; +cr.plugins_.Arr = function(runtime) +{ + this.runtime = runtime; +}; +(function () +{ + var pluginProto = cr.plugins_.Arr.prototype; + pluginProto.Type = function(plugin) + { + this.plugin = plugin; + this.runtime = plugin.runtime; + }; + var typeProto = pluginProto.Type.prototype; + typeProto.onCreate = function() + { + }; + pluginProto.Instance = function(type) + { + this.type = type; + this.runtime = type.runtime; + }; + var instanceProto = pluginProto.Instance.prototype; + var arrCache = []; + function allocArray() + { + if (arrCache.length) + return arrCache.pop(); + else + return []; + }; + if (!Array.isArray) + { + Array.isArray = function (vArg) { + return Object.prototype.toString.call(vArg) === "[object Array]"; + }; + } + function freeArray(a) + { + var i, len; + for (i = 0, len = a.length; i < len; i++) + { + if (Array.isArray(a[i])) + freeArray(a[i]); + } + cr.clearArray(a); + arrCache.push(a); + }; + instanceProto.onCreate = function() + { + this.cx = this.properties[0]; + this.cy = this.properties[1]; + this.cz = this.properties[2]; + if (!this.recycled) + this.arr = allocArray(); + var a = this.arr; + a.length = this.cx; + var x, y, z; + for (x = 0; x < this.cx; x++) + { + if (!a[x]) + a[x] = allocArray(); + a[x].length = this.cy; + for (y = 0; y < this.cy; y++) + { + if (!a[x][y]) + a[x][y] = allocArray(); + a[x][y].length = this.cz; + for (z = 0; z < this.cz; z++) + a[x][y][z] = 0; + } + } + this.forX = []; + this.forY = []; + this.forZ = []; + this.forDepth = -1; + }; + instanceProto.onDestroy = function () + { + var x; + for (x = 0; x < this.cx; x++) + freeArray(this.arr[x]); // will recurse down and recycle other arrays + cr.clearArray(this.arr); + }; + instanceProto.at = function (x, y, z) + { + x = Math.floor(x); + y = Math.floor(y); + z = Math.floor(z); + if (isNaN(x) || x < 0 || x > this.cx - 1) + return 0; + if (isNaN(y) || y < 0 || y > this.cy - 1) + return 0; + if (isNaN(z) || z < 0 || z > this.cz - 1) + return 0; + return this.arr[x][y][z]; + }; + instanceProto.set = function (x, y, z, val) + { + x = Math.floor(x); + y = Math.floor(y); + z = Math.floor(z); + if (isNaN(x) || x < 0 || x > this.cx - 1) + return; + if (isNaN(y) || y < 0 || y > this.cy - 1) + return; + if (isNaN(z) || z < 0 || z > this.cz - 1) + return; + this.arr[x][y][z] = val; + }; + instanceProto.getAsJSON = function () + { + return JSON.stringify({ + "c2array": true, + "size": [this.cx, this.cy, this.cz], + "data": this.arr + }); + }; + instanceProto.saveToJSON = function () + { + return { + "size": [this.cx, this.cy, this.cz], + "data": this.arr + }; + }; + instanceProto.loadFromJSON = function (o) + { + var sz = o["size"]; + this.cx = sz[0]; + this.cy = sz[1]; + this.cz = sz[2]; + this.arr = o["data"]; + }; + instanceProto.setSize = function (w, h, d) + { + if (w < 0) w = 0; + if (h < 0) h = 0; + if (d < 0) d = 0; + if (this.cx === w && this.cy === h && this.cz === d) + return; // no change + this.cx = w; + this.cy = h; + this.cz = d; + var x, y, z; + var a = this.arr; + a.length = w; + for (x = 0; x < this.cx; x++) + { + if (cr.is_undefined(a[x])) + a[x] = allocArray(); + a[x].length = h; + for (y = 0; y < this.cy; y++) + { + if (cr.is_undefined(a[x][y])) + a[x][y] = allocArray(); + a[x][y].length = d; + for (z = 0; z < this.cz; z++) + { + if (cr.is_undefined(a[x][y][z])) + a[x][y][z] = 0; + } + } + } + }; + instanceProto.getForX = function () + { + if (this.forDepth >= 0 && this.forDepth < this.forX.length) + return this.forX[this.forDepth]; + else + return 0; + }; + instanceProto.getForY = function () + { + if (this.forDepth >= 0 && this.forDepth < this.forY.length) + return this.forY[this.forDepth]; + else + return 0; + }; + instanceProto.getForZ = function () + { + if (this.forDepth >= 0 && this.forDepth < this.forZ.length) + return this.forZ[this.forDepth]; + else + return 0; + }; + function Cnds() {}; + Cnds.prototype.CompareX = function (x, cmp, val) + { + return cr.do_cmp(this.at(x, 0, 0), cmp, val); + }; + Cnds.prototype.CompareXY = function (x, y, cmp, val) + { + return cr.do_cmp(this.at(x, y, 0), cmp, val); + }; + Cnds.prototype.CompareXYZ = function (x, y, z, cmp, val) + { + return cr.do_cmp(this.at(x, y, z), cmp, val); + }; + instanceProto.doForEachTrigger = function (current_event) + { + this.runtime.pushCopySol(current_event.solModifiers); + current_event.retrigger(); + this.runtime.popSol(current_event.solModifiers); + }; + Cnds.prototype.ArrForEach = function (dims) + { + var current_event = this.runtime.getCurrentEventStack().current_event; + this.forDepth++; + var forDepth = this.forDepth; + if (forDepth === this.forX.length) + { + this.forX.push(0); + this.forY.push(0); + this.forZ.push(0); + } + else + { + this.forX[forDepth] = 0; + this.forY[forDepth] = 0; + this.forZ[forDepth] = 0; + } + switch (dims) { + case 0: + for (this.forX[forDepth] = 0; this.forX[forDepth] < this.cx; this.forX[forDepth]++) + { + for (this.forY[forDepth] = 0; this.forY[forDepth] < this.cy; this.forY[forDepth]++) + { + for (this.forZ[forDepth] = 0; this.forZ[forDepth] < this.cz; this.forZ[forDepth]++) + { + this.doForEachTrigger(current_event); + } + } + } + break; + case 1: + for (this.forX[forDepth] = 0; this.forX[forDepth] < this.cx; this.forX[forDepth]++) + { + for (this.forY[forDepth] = 0; this.forY[forDepth] < this.cy; this.forY[forDepth]++) + { + this.doForEachTrigger(current_event); + } + } + break; + case 2: + for (this.forX[forDepth] = 0; this.forX[forDepth] < this.cx; this.forX[forDepth]++) + { + this.doForEachTrigger(current_event); + } + break; + } + this.forDepth--; + return false; + }; + Cnds.prototype.CompareCurrent = function (cmp, val) + { + return cr.do_cmp(this.at(this.getForX(), this.getForY(), this.getForZ()), cmp, val); + }; + Cnds.prototype.Contains = function(val) + { + var x, y, z; + for (x = 0; x < this.cx; x++) + { + for (y = 0; y < this.cy; y++) + { + for (z = 0; z < this.cz; z++) + { + if (this.arr[x][y][z] === val) + return true; + } + } + } + return false; + }; + Cnds.prototype.IsEmpty = function () + { + return this.cx === 0 || this.cy === 0 || this.cz === 0; + }; + Cnds.prototype.CompareSize = function (axis, cmp, value) + { + var s = 0; + switch (axis) { + case 0: + s = this.cx; + break; + case 1: + s = this.cy; + break; + case 2: + s = this.cz; + break; + } + return cr.do_cmp(s, cmp, value); + }; + pluginProto.cnds = new Cnds(); + function Acts() {}; + Acts.prototype.Clear = function () + { + var x, y, z; + for (x = 0; x < this.cx; x++) + for (y = 0; y < this.cy; y++) + for (z = 0; z < this.cz; z++) + this.arr[x][y][z] = 0; + }; + Acts.prototype.SetSize = function (w, h, d) + { + this.setSize(w, h, d); + }; + Acts.prototype.SetX = function (x, val) + { + this.set(x, 0, 0, val); + }; + Acts.prototype.SetXY = function (x, y, val) + { + this.set(x, y, 0, val); + }; + Acts.prototype.SetXYZ = function (x, y, z, val) + { + this.set(x, y, z, val); + }; + Acts.prototype.Push = function (where, value, axis) + { + var x = 0, y = 0, z = 0; + var a = this.arr; + switch (axis) { + case 0: // X axis + if (where === 0) // back + { + x = a.length; + a.push(allocArray()); + } + else // front + { + x = 0; + a.unshift(allocArray()); + } + a[x].length = this.cy; + for ( ; y < this.cy; y++) + { + a[x][y] = allocArray(); + a[x][y].length = this.cz; + for (z = 0; z < this.cz; z++) + a[x][y][z] = value; + } + this.cx++; + break; + case 1: // Y axis + for ( ; x < this.cx; x++) + { + if (where === 0) // back + { + y = a[x].length; + a[x].push(allocArray()); + } + else // front + { + y = 0; + a[x].unshift(allocArray()); + } + a[x][y].length = this.cz; + for (z = 0; z < this.cz; z++) + a[x][y][z] = value; + } + this.cy++; + break; + case 2: // Z axis + for ( ; x < this.cx; x++) + { + for (y = 0; y < this.cy; y++) + { + if (where === 0) // back + { + a[x][y].push(value); + } + else // front + { + a[x][y].unshift(value); + } + } + } + this.cz++; + break; + } + }; + Acts.prototype.Pop = function (where, axis) + { + var x = 0, y = 0, z = 0; + var a = this.arr; + switch (axis) { + case 0: // X axis + if (this.cx === 0) + break; + if (where === 0) // back + { + freeArray(a.pop()); + } + else // front + { + freeArray(a.shift()); + } + this.cx--; + break; + case 1: // Y axis + if (this.cy === 0) + break; + for ( ; x < this.cx; x++) + { + if (where === 0) // back + { + freeArray(a[x].pop()); + } + else // front + { + freeArray(a[x].shift()); + } + } + this.cy--; + break; + case 2: // Z axis + if (this.cz === 0) + break; + for ( ; x < this.cx; x++) + { + for (y = 0; y < this.cy; y++) + { + if (where === 0) // back + { + a[x][y].pop(); + } + else // front + { + a[x][y].shift(); + } + } + } + this.cz--; + break; + } + }; + Acts.prototype.Reverse = function (axis) + { + var x = 0, y = 0, z = 0; + var a = this.arr; + if (this.cx === 0 || this.cy === 0 || this.cz === 0) + return; // no point reversing empty array + switch (axis) { + case 0: // X axis + a.reverse(); + break; + case 1: // Y axis + for ( ; x < this.cx; x++) + a[x].reverse(); + break; + case 2: // Z axis + for ( ; x < this.cx; x++) + for (y = 0; y < this.cy; y++) + a[x][y].reverse(); + break; + } + }; + function compareValues(va, vb) + { + if (cr.is_number(va) && cr.is_number(vb)) + return va - vb; + else + { + var sa = "" + va; + var sb = "" + vb; + if (sa < sb) + return -1; + else if (sa > sb) + return 1; + else + return 0; + } + } + Acts.prototype.Sort = function (axis) + { + var x = 0, y = 0, z = 0; + var a = this.arr; + if (this.cx === 0 || this.cy === 0 || this.cz === 0) + return; // no point sorting empty array + switch (axis) { + case 0: // X axis + a.sort(function (a, b) { + return compareValues(a[0][0], b[0][0]); + }); + break; + case 1: // Y axis + for ( ; x < this.cx; x++) + { + a[x].sort(function (a, b) { + return compareValues(a[0], b[0]); + }); + } + break; + case 2: // Z axis + for ( ; x < this.cx; x++) + { + for (y = 0; y < this.cy; y++) + { + a[x][y].sort(compareValues); + } + } + break; + } + }; + Acts.prototype.Delete = function (index, axis) + { + var x = 0, y = 0, z = 0; + index = Math.floor(index); + var a = this.arr; + if (index < 0) + return; + switch (axis) { + case 0: // X axis + if (index >= this.cx) + break; + freeArray(a[index]); + a.splice(index, 1); + this.cx--; + break; + case 1: // Y axis + if (index >= this.cy) + break; + for ( ; x < this.cx; x++) + { + freeArray(a[x][index]); + a[x].splice(index, 1); + } + this.cy--; + break; + case 2: // Z axis + if (index >= this.cz) + break; + for ( ; x < this.cx; x++) + { + for (y = 0; y < this.cy; y++) + { + a[x][y].splice(index, 1); + } + } + this.cz--; + break; + } + }; + Acts.prototype.Insert = function (value, index, axis) + { + var x = 0, y = 0, z = 0; + index = Math.floor(index); + var a = this.arr; + if (index < 0) + return; + switch (axis) { + case 0: // X axis + if (index > this.cx) + return; + x = index; + a.splice(x, 0, allocArray()); + a[x].length = this.cy; + for ( ; y < this.cy; y++) + { + a[x][y] = allocArray(); + a[x][y].length = this.cz; + for (z = 0; z < this.cz; z++) + a[x][y][z] = value; + } + this.cx++; + break; + case 1: // Y axis + if (index > this.cy) + return; + for ( ; x < this.cx; x++) + { + y = index; + a[x].splice(y, 0, allocArray()); + a[x][y].length = this.cz; + for (z = 0; z < this.cz; z++) + a[x][y][z] = value; + } + this.cy++; + break; + case 2: // Z axis + if (index > this.cz) + return; + for ( ; x < this.cx; x++) + { + for (y = 0; y < this.cy; y++) + { + a[x][y].splice(index, 0, value); + } + } + this.cz++; + break; + } + }; + Acts.prototype.JSONLoad = function (json_) + { + var o; + try { + o = JSON.parse(json_); + } + catch(e) { return; } + if (!o["c2array"]) // presumably not a c2array object + return; + var sz = o["size"]; + this.cx = sz[0]; + this.cy = sz[1]; + this.cz = sz[2]; + this.arr = o["data"]; + }; + Acts.prototype.JSONDownload = function (filename) + { + var a = document.createElement("a"); + if (typeof a.download === "undefined") + { + var str = 'data:text/html,' + encodeURIComponent("

Download link

"); + window.open(str); + } + else + { + var body = document.getElementsByTagName("body")[0]; + a.textContent = filename; + a.href = "data:application/json," + encodeURIComponent(this.getAsJSON()); + a.download = filename; + body.appendChild(a); + var clickEvent = document.createEvent("MouseEvent"); + clickEvent.initMouseEvent("click", true, true, window, 0, 0, 0, 0, 0, false, false, false, false, 0, null); + a.dispatchEvent(clickEvent); + body.removeChild(a); + } + }; + pluginProto.acts = new Acts(); + function Exps() {}; + Exps.prototype.At = function (ret, x, y_, z_) + { + var y = y_ || 0; + var z = z_ || 0; + ret.set_any(this.at(x, y, z)); + }; + Exps.prototype.Width = function (ret) + { + ret.set_int(this.cx); + }; + Exps.prototype.Height = function (ret) + { + ret.set_int(this.cy); + }; + Exps.prototype.Depth = function (ret) + { + ret.set_int(this.cz); + }; + Exps.prototype.CurX = function (ret) + { + ret.set_int(this.getForX()); + }; + Exps.prototype.CurY = function (ret) + { + ret.set_int(this.getForY()); + }; + Exps.prototype.CurZ = function (ret) + { + ret.set_int(this.getForZ()); + }; + Exps.prototype.CurValue = function (ret) + { + ret.set_any(this.at(this.getForX(), this.getForY(), this.getForZ())); + }; + Exps.prototype.Front = function (ret) + { + ret.set_any(this.at(0, 0, 0)); + }; + Exps.prototype.Back = function (ret) + { + ret.set_any(this.at(this.cx - 1, 0, 0)); + }; + Exps.prototype.IndexOf = function (ret, v) + { + for (var i = 0; i < this.cx; i++) + { + if (this.arr[i][0][0] === v) + { + ret.set_int(i); + return; + } + } + ret.set_int(-1); + }; + Exps.prototype.LastIndexOf = function (ret, v) + { + for (var i = this.cx - 1; i >= 0; i--) + { + if (this.arr[i][0][0] === v) + { + ret.set_int(i); + return; + } + } + ret.set_int(-1); + }; + Exps.prototype.AsJSON = function (ret) + { + ret.set_string(this.getAsJSON()); + }; + pluginProto.exps = new Exps(); +}()); +; +; +cr.plugins_.Audio = function(runtime) +{ + this.runtime = runtime; +}; +(function () +{ + var pluginProto = cr.plugins_.Audio.prototype; + pluginProto.Type = function(plugin) + { + this.plugin = plugin; + this.runtime = plugin.runtime; + }; + var typeProto = pluginProto.Type.prototype; + typeProto.onCreate = function() + { + }; + var audRuntime = null; + var audInst = null; + var audTag = ""; + var appPath = ""; // for Cordova only + var API_HTML5 = 0; + var API_WEBAUDIO = 1; + var API_CORDOVA = 2; + var API_APPMOBI = 3; + var api = API_HTML5; + var context = null; + var audioBuffers = []; // cache of buffers + var audioInstances = []; // cache of instances + var lastAudio = null; + var useOgg = false; // determined at create time + var timescale_mode = 0; + var silent = false; + var masterVolume = 1; + var listenerX = 0; + var listenerY = 0; + var isContextSuspended = false; + var panningModel = 1; // HRTF + var distanceModel = 1; // Inverse + var refDistance = 10; + var maxDistance = 10000; + var rolloffFactor = 1; + var micSource = null; + var micTag = ""; + var useNextTouchWorkaround = false; // heuristic in case play() does not return a promise and we have to guess if the play was blocked + var playOnNextInput = []; // C2AudioInstances with HTMLAudioElements to play on next input event + var playMusicAsSoundWorkaround = false; // play music tracks with Web Audio API + var hasPlayedDummyBuffer = false; // dummy buffer played to unblock AudioContext on some platforms + function addAudioToPlayOnNextInput(a) + { + var i = playOnNextInput.indexOf(a); + if (i === -1) + playOnNextInput.push(a); + }; + function tryPlayAudioElement(a) + { + var audioElem = a.instanceObject; + var playRet; + try { + playRet = audioElem.play(); + } + catch (err) { + addAudioToPlayOnNextInput(a); + return; + } + if (playRet) // promise was returned + { + playRet.catch(function (err) + { + addAudioToPlayOnNextInput(a); + }); + } + else if (useNextTouchWorkaround && !audRuntime.isInUserInputEvent) + { + addAudioToPlayOnNextInput(a); + } + }; + function playQueuedAudio() + { + var i, len, m, playRet; + if (!hasPlayedDummyBuffer && !isContextSuspended && context) + { + playDummyBuffer(); + if (context["state"] === "running") + hasPlayedDummyBuffer = true; + } + var tryPlay = playOnNextInput.slice(0); + cr.clearArray(playOnNextInput); + if (!silent) + { + for (i = 0, len = tryPlay.length; i < len; ++i) + { + m = tryPlay[i]; + if (!m.stopped && !m.is_paused) + { + playRet = m.instanceObject.play(); + if (playRet) + { + playRet.catch(function (err) + { + addAudioToPlayOnNextInput(m); + }); + } + } + } + } + }; + function playDummyBuffer() + { + if (context["state"] === "suspended" && context["resume"]) + context["resume"](); + if (!context["createBuffer"]) + return; + var buffer = context["createBuffer"](1, 220, 22050); + var source = context["createBufferSource"](); + source["buffer"] = buffer; + source["connect"](context["destination"]); + startSource(source); + }; + document.addEventListener("pointerup", playQueuedAudio, true); + document.addEventListener("touchend", playQueuedAudio, true); + document.addEventListener("click", playQueuedAudio, true); + document.addEventListener("keydown", playQueuedAudio, true); + document.addEventListener("gamepadconnected", playQueuedAudio, true); + function dbToLinear(x) + { + var v = dbToLinear_nocap(x); + if (!isFinite(v)) // accidentally passing a string can result in NaN; set volume to 0 if so + v = 0; + if (v < 0) + v = 0; + if (v > 1) + v = 1; + return v; + }; + function linearToDb(x) + { + if (x < 0) + x = 0; + if (x > 1) + x = 1; + return linearToDb_nocap(x); + }; + function dbToLinear_nocap(x) + { + return Math.pow(10, x / 20); + }; + function linearToDb_nocap(x) + { + return (Math.log(x) / Math.log(10)) * 20; + }; + var effects = {}; + function getDestinationForTag(tag) + { + tag = tag.toLowerCase(); + if (effects.hasOwnProperty(tag)) + { + if (effects[tag].length) + return effects[tag][0].getInputNode(); + } + return context["destination"]; + }; + function createGain() + { + if (context["createGain"]) + return context["createGain"](); + else + return context["createGainNode"](); + }; + function createDelay(d) + { + if (context["createDelay"]) + return context["createDelay"](d); + else + return context["createDelayNode"](d); + }; + function startSource(s, scheduledTime) + { + if (s["start"]) + s["start"](scheduledTime || 0); + else + s["noteOn"](scheduledTime || 0); + }; + function startSourceAt(s, x, d, scheduledTime) + { + if (s["start"]) + s["start"](scheduledTime || 0, x); + else + s["noteGrainOn"](scheduledTime || 0, x, d - x); + }; + function stopSource(s) + { + try { + if (s["stop"]) + s["stop"](0); + else + s["noteOff"](0); + } + catch (e) {} + }; + function setAudioParam(ap, value, ramp, time) + { + if (!ap) + return; // iOS is missing some parameters + ap["cancelScheduledValues"](0); + if (time === 0) + { + ap["value"] = value; + return; + } + var curTime = context["currentTime"]; + time += curTime; + switch (ramp) { + case 0: // step + ap["setValueAtTime"](value, time); + break; + case 1: // linear + ap["setValueAtTime"](ap["value"], curTime); // to set what to ramp from + ap["linearRampToValueAtTime"](value, time); + break; + case 2: // exponential + ap["setValueAtTime"](ap["value"], curTime); // to set what to ramp from + ap["exponentialRampToValueAtTime"](value, time); + break; + } + }; + var filterTypes = ["lowpass", "highpass", "bandpass", "lowshelf", "highshelf", "peaking", "notch", "allpass"]; + function FilterEffect(type, freq, detune, q, gain, mix) + { + this.type = "filter"; + this.params = [type, freq, detune, q, gain, mix]; + this.inputNode = createGain(); + this.wetNode = createGain(); + this.wetNode["gain"]["value"] = mix; + this.dryNode = createGain(); + this.dryNode["gain"]["value"] = 1 - mix; + this.filterNode = context["createBiquadFilter"](); + if (typeof this.filterNode["type"] === "number") + this.filterNode["type"] = type; + else + this.filterNode["type"] = filterTypes[type]; + this.filterNode["frequency"]["value"] = freq; + if (this.filterNode["detune"]) // iOS 6 doesn't have detune yet + this.filterNode["detune"]["value"] = detune; + this.filterNode["Q"]["value"] = q; + this.filterNode["gain"]["value"] = gain; + this.inputNode["connect"](this.filterNode); + this.inputNode["connect"](this.dryNode); + this.filterNode["connect"](this.wetNode); + }; + FilterEffect.prototype.connectTo = function (node) + { + this.wetNode["disconnect"](); + this.wetNode["connect"](node); + this.dryNode["disconnect"](); + this.dryNode["connect"](node); + }; + FilterEffect.prototype.remove = function () + { + this.inputNode["disconnect"](); + this.filterNode["disconnect"](); + this.wetNode["disconnect"](); + this.dryNode["disconnect"](); + }; + FilterEffect.prototype.getInputNode = function () + { + return this.inputNode; + }; + FilterEffect.prototype.setParam = function(param, value, ramp, time) + { + switch (param) { + case 0: // mix + value = value / 100; + if (value < 0) value = 0; + if (value > 1) value = 1; + this.params[5] = value; + setAudioParam(this.wetNode["gain"], value, ramp, time); + setAudioParam(this.dryNode["gain"], 1 - value, ramp, time); + break; + case 1: // filter frequency + this.params[1] = value; + setAudioParam(this.filterNode["frequency"], value, ramp, time); + break; + case 2: // filter detune + this.params[2] = value; + setAudioParam(this.filterNode["detune"], value, ramp, time); + break; + case 3: // filter Q + this.params[3] = value; + setAudioParam(this.filterNode["Q"], value, ramp, time); + break; + case 4: // filter/delay gain (note value is in dB here) + this.params[4] = value; + setAudioParam(this.filterNode["gain"], value, ramp, time); + break; + } + }; + function DelayEffect(delayTime, delayGain, mix) + { + this.type = "delay"; + this.params = [delayTime, delayGain, mix]; + this.inputNode = createGain(); + this.wetNode = createGain(); + this.wetNode["gain"]["value"] = mix; + this.dryNode = createGain(); + this.dryNode["gain"]["value"] = 1 - mix; + this.mainNode = createGain(); + this.delayNode = createDelay(delayTime); + this.delayNode["delayTime"]["value"] = delayTime; + this.delayGainNode = createGain(); + this.delayGainNode["gain"]["value"] = delayGain; + this.inputNode["connect"](this.mainNode); + this.inputNode["connect"](this.dryNode); + this.mainNode["connect"](this.wetNode); + this.mainNode["connect"](this.delayNode); + this.delayNode["connect"](this.delayGainNode); + this.delayGainNode["connect"](this.mainNode); + }; + DelayEffect.prototype.connectTo = function (node) + { + this.wetNode["disconnect"](); + this.wetNode["connect"](node); + this.dryNode["disconnect"](); + this.dryNode["connect"](node); + }; + DelayEffect.prototype.remove = function () + { + this.inputNode["disconnect"](); + this.mainNode["disconnect"](); + this.delayNode["disconnect"](); + this.delayGainNode["disconnect"](); + this.wetNode["disconnect"](); + this.dryNode["disconnect"](); + }; + DelayEffect.prototype.getInputNode = function () + { + return this.inputNode; + }; + DelayEffect.prototype.setParam = function(param, value, ramp, time) + { + switch (param) { + case 0: // mix + value = value / 100; + if (value < 0) value = 0; + if (value > 1) value = 1; + this.params[2] = value; + setAudioParam(this.wetNode["gain"], value, ramp, time); + setAudioParam(this.dryNode["gain"], 1 - value, ramp, time); + break; + case 4: // filter/delay gain (note value is passed in dB but needs to be linear here) + this.params[1] = dbToLinear(value); + setAudioParam(this.delayGainNode["gain"], dbToLinear(value), ramp, time); + break; + case 5: // delay time + this.params[0] = value; + setAudioParam(this.delayNode["delayTime"], value, ramp, time); + break; + } + }; + function ConvolveEffect(buffer, normalize, mix, src) + { + this.type = "convolve"; + this.params = [normalize, mix, src]; + this.inputNode = createGain(); + this.wetNode = createGain(); + this.wetNode["gain"]["value"] = mix; + this.dryNode = createGain(); + this.dryNode["gain"]["value"] = 1 - mix; + this.convolveNode = context["createConvolver"](); + if (buffer) + { + this.convolveNode["normalize"] = normalize; + this.convolveNode["buffer"] = buffer; + } + this.inputNode["connect"](this.convolveNode); + this.inputNode["connect"](this.dryNode); + this.convolveNode["connect"](this.wetNode); + }; + ConvolveEffect.prototype.connectTo = function (node) + { + this.wetNode["disconnect"](); + this.wetNode["connect"](node); + this.dryNode["disconnect"](); + this.dryNode["connect"](node); + }; + ConvolveEffect.prototype.remove = function () + { + this.inputNode["disconnect"](); + this.convolveNode["disconnect"](); + this.wetNode["disconnect"](); + this.dryNode["disconnect"](); + }; + ConvolveEffect.prototype.getInputNode = function () + { + return this.inputNode; + }; + ConvolveEffect.prototype.setParam = function(param, value, ramp, time) + { + switch (param) { + case 0: // mix + value = value / 100; + if (value < 0) value = 0; + if (value > 1) value = 1; + this.params[1] = value; + setAudioParam(this.wetNode["gain"], value, ramp, time); + setAudioParam(this.dryNode["gain"], 1 - value, ramp, time); + break; + } + }; + function FlangerEffect(delay, modulation, freq, feedback, mix) + { + this.type = "flanger"; + this.params = [delay, modulation, freq, feedback, mix]; + this.inputNode = createGain(); + this.dryNode = createGain(); + this.dryNode["gain"]["value"] = 1 - (mix / 2); + this.wetNode = createGain(); + this.wetNode["gain"]["value"] = mix / 2; + this.feedbackNode = createGain(); + this.feedbackNode["gain"]["value"] = feedback; + this.delayNode = createDelay(delay + modulation); + this.delayNode["delayTime"]["value"] = delay; + this.oscNode = context["createOscillator"](); + this.oscNode["frequency"]["value"] = freq; + this.oscGainNode = createGain(); + this.oscGainNode["gain"]["value"] = modulation; + this.inputNode["connect"](this.delayNode); + this.inputNode["connect"](this.dryNode); + this.delayNode["connect"](this.wetNode); + this.delayNode["connect"](this.feedbackNode); + this.feedbackNode["connect"](this.delayNode); + this.oscNode["connect"](this.oscGainNode); + this.oscGainNode["connect"](this.delayNode["delayTime"]); + startSource(this.oscNode); + }; + FlangerEffect.prototype.connectTo = function (node) + { + this.dryNode["disconnect"](); + this.dryNode["connect"](node); + this.wetNode["disconnect"](); + this.wetNode["connect"](node); + }; + FlangerEffect.prototype.remove = function () + { + this.inputNode["disconnect"](); + this.delayNode["disconnect"](); + this.oscNode["disconnect"](); + this.oscGainNode["disconnect"](); + this.dryNode["disconnect"](); + this.wetNode["disconnect"](); + this.feedbackNode["disconnect"](); + }; + FlangerEffect.prototype.getInputNode = function () + { + return this.inputNode; + }; + FlangerEffect.prototype.setParam = function(param, value, ramp, time) + { + switch (param) { + case 0: // mix + value = value / 100; + if (value < 0) value = 0; + if (value > 1) value = 1; + this.params[4] = value; + setAudioParam(this.wetNode["gain"], value / 2, ramp, time); + setAudioParam(this.dryNode["gain"], 1 - (value / 2), ramp, time); + break; + case 6: // modulation + this.params[1] = value / 1000; + setAudioParam(this.oscGainNode["gain"], value / 1000, ramp, time); + break; + case 7: // modulation frequency + this.params[2] = value; + setAudioParam(this.oscNode["frequency"], value, ramp, time); + break; + case 8: // feedback + this.params[3] = value / 100; + setAudioParam(this.feedbackNode["gain"], value / 100, ramp, time); + break; + } + }; + function PhaserEffect(freq, detune, q, modulation, modfreq, mix) + { + this.type = "phaser"; + this.params = [freq, detune, q, modulation, modfreq, mix]; + this.inputNode = createGain(); + this.dryNode = createGain(); + this.dryNode["gain"]["value"] = 1 - (mix / 2); + this.wetNode = createGain(); + this.wetNode["gain"]["value"] = mix / 2; + this.filterNode = context["createBiquadFilter"](); + if (typeof this.filterNode["type"] === "number") + this.filterNode["type"] = 7; // all-pass + else + this.filterNode["type"] = "allpass"; + this.filterNode["frequency"]["value"] = freq; + if (this.filterNode["detune"]) // iOS 6 doesn't have detune yet + this.filterNode["detune"]["value"] = detune; + this.filterNode["Q"]["value"] = q; + this.oscNode = context["createOscillator"](); + this.oscNode["frequency"]["value"] = modfreq; + this.oscGainNode = createGain(); + this.oscGainNode["gain"]["value"] = modulation; + this.inputNode["connect"](this.filterNode); + this.inputNode["connect"](this.dryNode); + this.filterNode["connect"](this.wetNode); + this.oscNode["connect"](this.oscGainNode); + this.oscGainNode["connect"](this.filterNode["frequency"]); + startSource(this.oscNode); + }; + PhaserEffect.prototype.connectTo = function (node) + { + this.dryNode["disconnect"](); + this.dryNode["connect"](node); + this.wetNode["disconnect"](); + this.wetNode["connect"](node); + }; + PhaserEffect.prototype.remove = function () + { + this.inputNode["disconnect"](); + this.filterNode["disconnect"](); + this.oscNode["disconnect"](); + this.oscGainNode["disconnect"](); + this.dryNode["disconnect"](); + this.wetNode["disconnect"](); + }; + PhaserEffect.prototype.getInputNode = function () + { + return this.inputNode; + }; + PhaserEffect.prototype.setParam = function(param, value, ramp, time) + { + switch (param) { + case 0: // mix + value = value / 100; + if (value < 0) value = 0; + if (value > 1) value = 1; + this.params[5] = value; + setAudioParam(this.wetNode["gain"], value / 2, ramp, time); + setAudioParam(this.dryNode["gain"], 1 - (value / 2), ramp, time); + break; + case 1: // filter frequency + this.params[0] = value; + setAudioParam(this.filterNode["frequency"], value, ramp, time); + break; + case 2: // filter detune + this.params[1] = value; + setAudioParam(this.filterNode["detune"], value, ramp, time); + break; + case 3: // filter Q + this.params[2] = value; + setAudioParam(this.filterNode["Q"], value, ramp, time); + break; + case 6: // modulation + this.params[3] = value; + setAudioParam(this.oscGainNode["gain"], value, ramp, time); + break; + case 7: // modulation frequency + this.params[4] = value; + setAudioParam(this.oscNode["frequency"], value, ramp, time); + break; + } + }; + function GainEffect(g) + { + this.type = "gain"; + this.params = [g]; + this.node = createGain(); + this.node["gain"]["value"] = g; + }; + GainEffect.prototype.connectTo = function (node_) + { + this.node["disconnect"](); + this.node["connect"](node_); + }; + GainEffect.prototype.remove = function () + { + this.node["disconnect"](); + }; + GainEffect.prototype.getInputNode = function () + { + return this.node; + }; + GainEffect.prototype.setParam = function(param, value, ramp, time) + { + switch (param) { + case 4: // gain + this.params[0] = dbToLinear(value); + setAudioParam(this.node["gain"], dbToLinear(value), ramp, time); + break; + } + }; + function TremoloEffect(freq, mix) + { + this.type = "tremolo"; + this.params = [freq, mix]; + this.node = createGain(); + this.node["gain"]["value"] = 1 - (mix / 2); + this.oscNode = context["createOscillator"](); + this.oscNode["frequency"]["value"] = freq; + this.oscGainNode = createGain(); + this.oscGainNode["gain"]["value"] = mix / 2; + this.oscNode["connect"](this.oscGainNode); + this.oscGainNode["connect"](this.node["gain"]); + startSource(this.oscNode); + }; + TremoloEffect.prototype.connectTo = function (node_) + { + this.node["disconnect"](); + this.node["connect"](node_); + }; + TremoloEffect.prototype.remove = function () + { + this.oscNode["disconnect"](); + this.oscGainNode["disconnect"](); + this.node["disconnect"](); + }; + TremoloEffect.prototype.getInputNode = function () + { + return this.node; + }; + TremoloEffect.prototype.setParam = function(param, value, ramp, time) + { + switch (param) { + case 0: // mix + value = value / 100; + if (value < 0) value = 0; + if (value > 1) value = 1; + this.params[1] = value; + setAudioParam(this.node["gain"]["value"], 1 - (value / 2), ramp, time); + setAudioParam(this.oscGainNode["gain"]["value"], value / 2, ramp, time); + break; + case 7: // modulation frequency + this.params[0] = value; + setAudioParam(this.oscNode["frequency"], value, ramp, time); + break; + } + }; + function RingModulatorEffect(freq, mix) + { + this.type = "ringmod"; + this.params = [freq, mix]; + this.inputNode = createGain(); + this.wetNode = createGain(); + this.wetNode["gain"]["value"] = mix; + this.dryNode = createGain(); + this.dryNode["gain"]["value"] = 1 - mix; + this.ringNode = createGain(); + this.ringNode["gain"]["value"] = 0; + this.oscNode = context["createOscillator"](); + this.oscNode["frequency"]["value"] = freq; + this.oscNode["connect"](this.ringNode["gain"]); + startSource(this.oscNode); + this.inputNode["connect"](this.ringNode); + this.inputNode["connect"](this.dryNode); + this.ringNode["connect"](this.wetNode); + }; + RingModulatorEffect.prototype.connectTo = function (node_) + { + this.wetNode["disconnect"](); + this.wetNode["connect"](node_); + this.dryNode["disconnect"](); + this.dryNode["connect"](node_); + }; + RingModulatorEffect.prototype.remove = function () + { + this.oscNode["disconnect"](); + this.ringNode["disconnect"](); + this.inputNode["disconnect"](); + this.wetNode["disconnect"](); + this.dryNode["disconnect"](); + }; + RingModulatorEffect.prototype.getInputNode = function () + { + return this.inputNode; + }; + RingModulatorEffect.prototype.setParam = function(param, value, ramp, time) + { + switch (param) { + case 0: // mix + value = value / 100; + if (value < 0) value = 0; + if (value > 1) value = 1; + this.params[1] = value; + setAudioParam(this.wetNode["gain"], value, ramp, time); + setAudioParam(this.dryNode["gain"], 1 - value, ramp, time); + break; + case 7: // modulation frequency + this.params[0] = value; + setAudioParam(this.oscNode["frequency"], value, ramp, time); + break; + } + }; + function DistortionEffect(threshold, headroom, drive, makeupgain, mix) + { + this.type = "distortion"; + this.params = [threshold, headroom, drive, makeupgain, mix]; + this.inputNode = createGain(); + this.preGain = createGain(); + this.postGain = createGain(); + this.setDrive(drive, dbToLinear_nocap(makeupgain)); + this.wetNode = createGain(); + this.wetNode["gain"]["value"] = mix; + this.dryNode = createGain(); + this.dryNode["gain"]["value"] = 1 - mix; + this.waveShaper = context["createWaveShaper"](); + this.curve = new Float32Array(65536); + this.generateColortouchCurve(threshold, headroom); + this.waveShaper.curve = this.curve; + this.inputNode["connect"](this.preGain); + this.inputNode["connect"](this.dryNode); + this.preGain["connect"](this.waveShaper); + this.waveShaper["connect"](this.postGain); + this.postGain["connect"](this.wetNode); + }; + DistortionEffect.prototype.setDrive = function (drive, makeupgain) + { + if (drive < 0.01) + drive = 0.01; + this.preGain["gain"]["value"] = drive; + this.postGain["gain"]["value"] = Math.pow(1 / drive, 0.6) * makeupgain; + }; + function e4(x, k) + { + return 1.0 - Math.exp(-k * x); + } + DistortionEffect.prototype.shape = function (x, linearThreshold, linearHeadroom) + { + var maximum = 1.05 * linearHeadroom * linearThreshold; + var kk = (maximum - linearThreshold); + var sign = x < 0 ? -1 : +1; + var absx = x < 0 ? -x : x; + var shapedInput = absx < linearThreshold ? absx : linearThreshold + kk * e4(absx - linearThreshold, 1.0 / kk); + shapedInput *= sign; + return shapedInput; + }; + DistortionEffect.prototype.generateColortouchCurve = function (threshold, headroom) + { + var linearThreshold = dbToLinear_nocap(threshold); + var linearHeadroom = dbToLinear_nocap(headroom); + var n = 65536; + var n2 = n / 2; + var x = 0; + for (var i = 0; i < n2; ++i) { + x = i / n2; + x = this.shape(x, linearThreshold, linearHeadroom); + this.curve[n2 + i] = x; + this.curve[n2 - i - 1] = -x; + } + }; + DistortionEffect.prototype.connectTo = function (node) + { + this.wetNode["disconnect"](); + this.wetNode["connect"](node); + this.dryNode["disconnect"](); + this.dryNode["connect"](node); + }; + DistortionEffect.prototype.remove = function () + { + this.inputNode["disconnect"](); + this.preGain["disconnect"](); + this.waveShaper["disconnect"](); + this.postGain["disconnect"](); + this.wetNode["disconnect"](); + this.dryNode["disconnect"](); + }; + DistortionEffect.prototype.getInputNode = function () + { + return this.inputNode; + }; + DistortionEffect.prototype.setParam = function(param, value, ramp, time) + { + switch (param) { + case 0: // mix + value = value / 100; + if (value < 0) value = 0; + if (value > 1) value = 1; + this.params[4] = value; + setAudioParam(this.wetNode["gain"], value, ramp, time); + setAudioParam(this.dryNode["gain"], 1 - value, ramp, time); + break; + } + }; + function CompressorEffect(threshold, knee, ratio, attack, release) + { + this.type = "compressor"; + this.params = [threshold, knee, ratio, attack, release]; + this.node = context["createDynamicsCompressor"](); + try { + this.node["threshold"]["value"] = threshold; + this.node["knee"]["value"] = knee; + this.node["ratio"]["value"] = ratio; + this.node["attack"]["value"] = attack; + this.node["release"]["value"] = release; + } + catch (e) {} + }; + CompressorEffect.prototype.connectTo = function (node_) + { + this.node["disconnect"](); + this.node["connect"](node_); + }; + CompressorEffect.prototype.remove = function () + { + this.node["disconnect"](); + }; + CompressorEffect.prototype.getInputNode = function () + { + return this.node; + }; + CompressorEffect.prototype.setParam = function(param, value, ramp, time) + { + }; + function AnalyserEffect(fftSize, smoothing) + { + this.type = "analyser"; + this.params = [fftSize, smoothing]; + this.node = context["createAnalyser"](); + this.node["fftSize"] = fftSize; + this.node["smoothingTimeConstant"] = smoothing; + this.freqBins = new Float32Array(this.node["frequencyBinCount"]); + this.signal = new Uint8Array(fftSize); + this.peak = 0; + this.rms = 0; + }; + AnalyserEffect.prototype.tick = function () + { + this.node["getFloatFrequencyData"](this.freqBins); + this.node["getByteTimeDomainData"](this.signal); + var fftSize = this.node["fftSize"]; + var i = 0; + this.peak = 0; + var rmsSquaredSum = 0; + var s = 0; + for ( ; i < fftSize; i++) + { + s = (this.signal[i] - 128) / 128; + if (s < 0) + s = -s; + if (this.peak < s) + this.peak = s; + rmsSquaredSum += s * s; + } + this.peak = linearToDb(this.peak); + this.rms = linearToDb(Math.sqrt(rmsSquaredSum / fftSize)); + }; + AnalyserEffect.prototype.connectTo = function (node_) + { + this.node["disconnect"](); + this.node["connect"](node_); + }; + AnalyserEffect.prototype.remove = function () + { + this.node["disconnect"](); + }; + AnalyserEffect.prototype.getInputNode = function () + { + return this.node; + }; + AnalyserEffect.prototype.setParam = function(param, value, ramp, time) + { + }; + function ObjectTracker() + { + this.obj = null; + this.loadUid = 0; + }; + ObjectTracker.prototype.setObject = function (obj_) + { + this.obj = obj_; + }; + ObjectTracker.prototype.hasObject = function () + { + return !!this.obj; + }; + ObjectTracker.prototype.tick = function (dt) + { + }; + function C2AudioBuffer(src_, is_music) + { + this.src = src_; + this.myapi = api; + this.is_music = is_music; + this.added_end_listener = false; + var self = this; + this.outNode = null; + this.mediaSourceNode = null; + this.panWhenReady = []; // for web audio API positioned sounds + this.seekWhenReady = 0; + this.pauseWhenReady = false; + this.supportWebAudioAPI = false; + this.failedToLoad = false; + this.wasEverReady = false; // if a buffer is ever marked as ready, it's permanently considered ready after then. + if (api === API_WEBAUDIO && is_music && !playMusicAsSoundWorkaround) + { + this.myapi = API_HTML5; + this.outNode = createGain(); + } + this.bufferObject = null; // actual audio object + this.audioData = null; // web audio api: ajax request result (compressed audio that needs decoding) + var request; + switch (this.myapi) { + case API_HTML5: + this.bufferObject = new Audio(); + this.bufferObject.crossOrigin = "anonymous"; + this.bufferObject.addEventListener("canplaythrough", function () { + self.wasEverReady = true; // update loaded state so preload is considered complete + }); + if (api === API_WEBAUDIO && context["createMediaElementSource"] && !/wiiu/i.test(navigator.userAgent)) + { + this.supportWebAudioAPI = true; // can be routed through web audio api + this.bufferObject.addEventListener("canplay", function () + { + if (!self.mediaSourceNode && self.bufferObject) + { + self.mediaSourceNode = context["createMediaElementSource"](self.bufferObject); + self.mediaSourceNode["connect"](self.outNode); + } + }); + } + this.bufferObject.autoplay = false; // this is only a source buffer, not an instance + this.bufferObject.preload = "auto"; + this.bufferObject.src = src_; + break; + case API_WEBAUDIO: + if (audRuntime.isWKWebView) + { + audRuntime.fetchLocalFileViaCordovaAsArrayBuffer(src_, function (arrayBuffer) + { + self.audioData = arrayBuffer; + self.decodeAudioBuffer(); + }, function (err) + { + self.failedToLoad = true; + }); + } + else + { + request = new XMLHttpRequest(); + request.open("GET", src_, true); + request.responseType = "arraybuffer"; + request.onload = function () { + self.audioData = request.response; + self.decodeAudioBuffer(); + }; + request.onerror = function () { + self.failedToLoad = true; + }; + request.send(); + } + break; + case API_CORDOVA: + this.bufferObject = true; + break; + case API_APPMOBI: + this.bufferObject = true; + break; + } + }; + C2AudioBuffer.prototype.release = function () + { + var i, len, j, a; + for (i = 0, j = 0, len = audioInstances.length; i < len; ++i) + { + a = audioInstances[i]; + audioInstances[j] = a; + if (a.buffer === this) + a.stop(); + else + ++j; // keep + } + audioInstances.length = j; + if (this.mediaSourceNode) + { + this.mediaSourceNode["disconnect"](); + this.mediaSourceNode = null; + } + if (this.outNode) + { + this.outNode["disconnect"](); + this.outNode = null; + } + this.bufferObject = null; + this.audioData = null; + }; + C2AudioBuffer.prototype.decodeAudioBuffer = function () + { + if (this.bufferObject || !this.audioData) + return; // audio already decoded or AJAX request not yet complete + var self = this; + if (context["decodeAudioData"]) + { + context["decodeAudioData"](this.audioData, function (buffer) { + self.bufferObject = buffer; + self.audioData = null; // clear AJAX response to allow GC and save memory, only need the bufferObject now + var p, i, len, a; + if (!cr.is_undefined(self.playTagWhenReady) && !silent) + { + if (self.panWhenReady.length) + { + for (i = 0, len = self.panWhenReady.length; i < len; i++) + { + p = self.panWhenReady[i]; + a = new C2AudioInstance(self, p.thistag); + a.setPannerEnabled(true); + if (typeof p.objUid !== "undefined") + { + p.obj = audRuntime.getObjectByUID(p.objUid); + if (!p.obj) + continue; + } + if (p.obj) + { + var px = cr.rotatePtAround(p.obj.x, p.obj.y, -p.obj.layer.getAngle(), listenerX, listenerY, true); + var py = cr.rotatePtAround(p.obj.x, p.obj.y, -p.obj.layer.getAngle(), listenerX, listenerY, false); + a.setPan(px, py, cr.to_degrees(p.obj.angle - p.obj.layer.getAngle()), p.ia, p.oa, p.og); + a.setObject(p.obj); + } + else + { + a.setPan(p.x, p.y, p.a, p.ia, p.oa, p.og); + } + a.play(self.loopWhenReady, self.volumeWhenReady, self.seekWhenReady); + if (self.pauseWhenReady) + a.pause(); + audioInstances.push(a); + } + cr.clearArray(self.panWhenReady); + } + else + { + a = new C2AudioInstance(self, self.playTagWhenReady || ""); // sometimes playTagWhenReady is not set - TODO: why? + a.play(self.loopWhenReady, self.volumeWhenReady, self.seekWhenReady); + if (self.pauseWhenReady) + a.pause(); + audioInstances.push(a); + } + } + else if (!cr.is_undefined(self.convolveWhenReady)) + { + var convolveNode = self.convolveWhenReady.convolveNode; + convolveNode["normalize"] = self.normalizeWhenReady; + convolveNode["buffer"] = buffer; + } + }, function (e) { + self.failedToLoad = true; + }); + } + else + { + this.bufferObject = context["createBuffer"](this.audioData, false); + this.audioData = null; // clear AJAX response to allow GC and save memory, only need the bufferObject now + if (!cr.is_undefined(this.playTagWhenReady) && !silent) + { + var a = new C2AudioInstance(this, this.playTagWhenReady); + a.play(this.loopWhenReady, this.volumeWhenReady, this.seekWhenReady); + if (this.pauseWhenReady) + a.pause(); + audioInstances.push(a); + } + else if (!cr.is_undefined(this.convolveWhenReady)) + { + var convolveNode = this.convolveWhenReady.convolveNode; + convolveNode["normalize"] = this.normalizeWhenReady; + convolveNode["buffer"] = this.bufferObject; + } + } + }; + C2AudioBuffer.prototype.isLoaded = function () + { + switch (this.myapi) { + case API_HTML5: + var ret = this.bufferObject["readyState"] >= 4; // HAVE_ENOUGH_DATA + if (ret) + this.wasEverReady = true; + return ret || this.wasEverReady; + case API_WEBAUDIO: + return !!this.audioData || !!this.bufferObject; + case API_CORDOVA: + return true; + case API_APPMOBI: + return true; + } + return false; + }; + C2AudioBuffer.prototype.isLoadedAndDecoded = function () + { + switch (this.myapi) { + case API_HTML5: + return this.isLoaded(); // no distinction between loaded and decoded in HTML5 audio, just rely on ready state + case API_WEBAUDIO: + return !!this.bufferObject; + case API_CORDOVA: + return true; + case API_APPMOBI: + return true; + } + return false; + }; + C2AudioBuffer.prototype.hasFailedToLoad = function () + { + switch (this.myapi) { + case API_HTML5: + return !!this.bufferObject["error"]; + case API_WEBAUDIO: + return this.failedToLoad; + } + return false; + }; + function C2AudioInstance(buffer_, tag_) + { + var self = this; + this.tag = tag_; + this.fresh = true; + this.stopped = true; + this.src = buffer_.src; + this.buffer = buffer_; + this.myapi = api; + this.is_music = buffer_.is_music; + this.playbackRate = 1; + this.hasPlaybackEnded = true; // ended flag + this.resume_me = false; // make sure resumes when leaving suspend + this.is_paused = false; + this.resume_position = 0; // for web audio api to resume from correct playback position + this.looping = false; + this.is_muted = false; + this.is_silent = false; + this.volume = 1; + this.onended_handler = function (e) + { + if (self.is_paused || self.resume_me) + return; + var bufferThatEnded = this; + if (!bufferThatEnded) + bufferThatEnded = e.target; + if (bufferThatEnded !== self.active_buffer) + return; + self.hasPlaybackEnded = true; + self.stopped = true; + audTag = self.tag; + audRuntime.trigger(cr.plugins_.Audio.prototype.cnds.OnEnded, audInst); + }; + this.active_buffer = null; + this.isTimescaled = ((timescale_mode === 1 && !this.is_music) || timescale_mode === 2); + this.mutevol = 1; + this.startTime = (this.isTimescaled ? audRuntime.kahanTime.sum : audRuntime.wallTime.sum); + this.gainNode = null; + this.pannerNode = null; + this.pannerEnabled = false; + this.objectTracker = null; + this.panX = 0; + this.panY = 0; + this.panAngle = 0; + this.panConeInner = 0; + this.panConeOuter = 0; + this.panConeOuterGain = 0; + this.instanceObject = null; + var add_end_listener = false; + if (this.myapi === API_WEBAUDIO && this.buffer.myapi === API_HTML5 && !this.buffer.supportWebAudioAPI) + this.myapi = API_HTML5; + switch (this.myapi) { + case API_HTML5: + if (this.is_music) + { + this.instanceObject = buffer_.bufferObject; + add_end_listener = !buffer_.added_end_listener; + buffer_.added_end_listener = true; + } + else + { + this.instanceObject = new Audio(); + this.instanceObject.crossOrigin = "anonymous"; + this.instanceObject.autoplay = false; + this.instanceObject.src = buffer_.bufferObject.src; + add_end_listener = true; + } + if (add_end_listener) + { + this.instanceObject.addEventListener('ended', function () { + audTag = self.tag; + self.stopped = true; + audRuntime.trigger(cr.plugins_.Audio.prototype.cnds.OnEnded, audInst); + }); + } + break; + case API_WEBAUDIO: + this.gainNode = createGain(); + this.gainNode["connect"](getDestinationForTag(tag_)); + if (this.buffer.myapi === API_WEBAUDIO) + { + if (buffer_.bufferObject) + { + this.instanceObject = context["createBufferSource"](); + this.instanceObject["buffer"] = buffer_.bufferObject; + this.instanceObject["connect"](this.gainNode); + } + } + else + { + this.instanceObject = this.buffer.bufferObject; // reference the audio element + this.buffer.outNode["connect"](this.gainNode); + if (!this.buffer.added_end_listener) + { + this.buffer.added_end_listener = true; + this.buffer.bufferObject.addEventListener('ended', function () { + audTag = self.tag; + self.stopped = true; + audRuntime.trigger(cr.plugins_.Audio.prototype.cnds.OnEnded, audInst); + }); + } + } + break; + case API_CORDOVA: + this.instanceObject = new window["Media"](appPath + this.src, null, null, function (status) { + if (status === window["Media"]["MEDIA_STOPPED"]) + { + self.hasPlaybackEnded = true; + self.stopped = true; + audTag = self.tag; + audRuntime.trigger(cr.plugins_.Audio.prototype.cnds.OnEnded, audInst); + } + }); + break; + case API_APPMOBI: + this.instanceObject = true; + break; + } + }; + C2AudioInstance.prototype.hasEnded = function () + { + var time; + switch (this.myapi) { + case API_HTML5: + return this.instanceObject.ended; + case API_WEBAUDIO: + if (this.buffer.myapi === API_WEBAUDIO) + { + if (!this.fresh && !this.stopped && this.instanceObject["loop"]) + return false; + if (this.is_paused) + return false; + return this.hasPlaybackEnded; + } + else + return this.instanceObject.ended; + case API_CORDOVA: + return this.hasPlaybackEnded; + case API_APPMOBI: + true; // recycling an AppMobi sound does not matter because it will just do another throwaway playSound + } + return true; + }; + C2AudioInstance.prototype.canBeRecycled = function () + { + if (this.fresh || this.stopped) + return true; // not yet used or is not playing + return this.hasEnded(); + }; + C2AudioInstance.prototype.setPannerEnabled = function (enable_) + { + if (api !== API_WEBAUDIO) + return; + if (!this.pannerEnabled && enable_) + { + if (!this.gainNode) + return; + if (!this.pannerNode) + { + this.pannerNode = context["createPanner"](); + if (typeof this.pannerNode["panningModel"] === "number") + this.pannerNode["panningModel"] = panningModel; + else + this.pannerNode["panningModel"] = ["equalpower", "HRTF", "soundfield"][panningModel]; + if (typeof this.pannerNode["distanceModel"] === "number") + this.pannerNode["distanceModel"] = distanceModel; + else + this.pannerNode["distanceModel"] = ["linear", "inverse", "exponential"][distanceModel]; + this.pannerNode["refDistance"] = refDistance; + this.pannerNode["maxDistance"] = maxDistance; + this.pannerNode["rolloffFactor"] = rolloffFactor; + } + this.gainNode["disconnect"](); + this.gainNode["connect"](this.pannerNode); + this.pannerNode["connect"](getDestinationForTag(this.tag)); + this.pannerEnabled = true; + } + else if (this.pannerEnabled && !enable_) + { + if (!this.gainNode) + return; + this.pannerNode["disconnect"](); + this.gainNode["disconnect"](); + this.gainNode["connect"](getDestinationForTag(this.tag)); + this.pannerEnabled = false; + } + }; + C2AudioInstance.prototype.setPan = function (x, y, angle, innerangle, outerangle, outergain) + { + if (!this.pannerEnabled || api !== API_WEBAUDIO) + return; + this.pannerNode["setPosition"](x, y, 0); + this.pannerNode["setOrientation"](Math.cos(cr.to_radians(angle)), Math.sin(cr.to_radians(angle)), 0); + this.pannerNode["coneInnerAngle"] = innerangle; + this.pannerNode["coneOuterAngle"] = outerangle; + this.pannerNode["coneOuterGain"] = outergain; + this.panX = x; + this.panY = y; + this.panAngle = angle; + this.panConeInner = innerangle; + this.panConeOuter = outerangle; + this.panConeOuterGain = outergain; + }; + C2AudioInstance.prototype.setObject = function (o) + { + if (!this.pannerEnabled || api !== API_WEBAUDIO) + return; + if (!this.objectTracker) + this.objectTracker = new ObjectTracker(); + this.objectTracker.setObject(o); + }; + C2AudioInstance.prototype.tick = function (dt) + { + if (!this.pannerEnabled || api !== API_WEBAUDIO || !this.objectTracker || !this.objectTracker.hasObject() || !this.isPlaying()) + { + return; + } + this.objectTracker.tick(dt); + var inst = this.objectTracker.obj; + var px = cr.rotatePtAround(inst.x, inst.y, -inst.layer.getAngle(), listenerX, listenerY, true); + var py = cr.rotatePtAround(inst.x, inst.y, -inst.layer.getAngle(), listenerX, listenerY, false); + this.pannerNode["setPosition"](px, py, 0); + var a = 0; + if (typeof this.objectTracker.obj.angle !== "undefined") + { + a = inst.angle - inst.layer.getAngle(); + this.pannerNode["setOrientation"](Math.cos(a), Math.sin(a), 0); + } + }; + C2AudioInstance.prototype.play = function (looping, vol, fromPosition, scheduledTime) + { + var instobj = this.instanceObject; + this.looping = looping; + this.volume = vol; + var seekPos = fromPosition || 0; + scheduledTime = scheduledTime || 0; + switch (this.myapi) { + case API_HTML5: + if (instobj.playbackRate !== 1.0) + instobj.playbackRate = 1.0; + if (instobj.volume !== vol * masterVolume) + instobj.volume = vol * masterVolume; + if (instobj.loop !== looping) + instobj.loop = looping; + if (instobj.muted) + instobj.muted = false; + if (instobj.currentTime !== seekPos) + { + try { + instobj.currentTime = seekPos; + } + catch (err) + { +; + } + } + tryPlayAudioElement(this); + break; + case API_WEBAUDIO: + this.muted = false; + this.mutevol = 1; + if (this.buffer.myapi === API_WEBAUDIO) + { + this.gainNode["gain"]["value"] = vol * masterVolume; + if (!this.fresh) + { + this.instanceObject = context["createBufferSource"](); + this.instanceObject["buffer"] = this.buffer.bufferObject; + this.instanceObject["connect"](this.gainNode); + } + this.instanceObject["onended"] = this.onended_handler; + this.active_buffer = this.instanceObject; + this.instanceObject.loop = looping; + this.hasPlaybackEnded = false; + if (seekPos === 0) + startSource(this.instanceObject, scheduledTime); + else + startSourceAt(this.instanceObject, seekPos, this.getDuration(), scheduledTime); + } + else + { + if (instobj.playbackRate !== 1.0) + instobj.playbackRate = 1.0; + if (instobj.loop !== looping) + instobj.loop = looping; + instobj.volume = vol * masterVolume; + if (instobj.currentTime !== seekPos) + { + try { + instobj.currentTime = seekPos; + } + catch (err) + { +; + } + } + tryPlayAudioElement(this); + } + break; + case API_CORDOVA: + if ((!this.fresh && this.stopped) || seekPos !== 0) + instobj["seekTo"](seekPos); + instobj["play"](); + this.hasPlaybackEnded = false; + break; + case API_APPMOBI: + if (audRuntime.isDirectCanvas) + AppMobi["context"]["playSound"](this.src, looping); + else + AppMobi["player"]["playSound"](this.src, looping); + break; + } + this.playbackRate = 1; + this.startTime = (this.isTimescaled ? audRuntime.kahanTime.sum : audRuntime.wallTime.sum) - seekPos; + this.fresh = false; + this.stopped = false; + this.is_paused = false; + }; + C2AudioInstance.prototype.stop = function () + { + switch (this.myapi) { + case API_HTML5: + if (!this.instanceObject.paused) + this.instanceObject.pause(); + break; + case API_WEBAUDIO: + if (this.buffer.myapi === API_WEBAUDIO) + stopSource(this.instanceObject); + else + { + if (!this.instanceObject.paused) + this.instanceObject.pause(); + } + break; + case API_CORDOVA: + this.instanceObject["stop"](); + break; + case API_APPMOBI: + if (audRuntime.isDirectCanvas) + AppMobi["context"]["stopSound"](this.src); + break; + } + this.stopped = true; + this.is_paused = false; + }; + C2AudioInstance.prototype.pause = function () + { + if (this.fresh || this.stopped || this.hasEnded() || this.is_paused) + return; + switch (this.myapi) { + case API_HTML5: + if (!this.instanceObject.paused) + this.instanceObject.pause(); + break; + case API_WEBAUDIO: + if (this.buffer.myapi === API_WEBAUDIO) + { + this.resume_position = this.getPlaybackTime(true); + if (this.looping) + this.resume_position = this.resume_position % this.getDuration(); + this.is_paused = true; + stopSource(this.instanceObject); + } + else + { + if (!this.instanceObject.paused) + this.instanceObject.pause(); + } + break; + case API_CORDOVA: + this.instanceObject["pause"](); + break; + case API_APPMOBI: + if (audRuntime.isDirectCanvas) + AppMobi["context"]["stopSound"](this.src); + break; + } + this.is_paused = true; + }; + C2AudioInstance.prototype.resume = function () + { + if (this.fresh || this.stopped || this.hasEnded() || !this.is_paused) + return; + switch (this.myapi) { + case API_HTML5: + tryPlayAudioElement(this); + break; + case API_WEBAUDIO: + if (this.buffer.myapi === API_WEBAUDIO) + { + this.instanceObject = context["createBufferSource"](); + this.instanceObject["buffer"] = this.buffer.bufferObject; + this.instanceObject["connect"](this.gainNode); + this.instanceObject["onended"] = this.onended_handler; + this.active_buffer = this.instanceObject; + this.instanceObject.loop = this.looping; + this.gainNode["gain"]["value"] = masterVolume * this.volume * this.mutevol; + this.updatePlaybackRate(); + this.startTime = (this.isTimescaled ? audRuntime.kahanTime.sum : audRuntime.wallTime.sum) - (this.resume_position / (this.playbackRate || 0.001)); + startSourceAt(this.instanceObject, this.resume_position, this.getDuration()); + } + else + { + tryPlayAudioElement(this); + } + break; + case API_CORDOVA: + this.instanceObject["play"](); + break; + case API_APPMOBI: + if (audRuntime.isDirectCanvas) + AppMobi["context"]["resumeSound"](this.src); + break; + } + this.is_paused = false; + }; + C2AudioInstance.prototype.seek = function (pos) + { + if (this.fresh || this.stopped || this.hasEnded()) + return; + switch (this.myapi) { + case API_HTML5: + try { + this.instanceObject.currentTime = pos; + } + catch (e) {} + break; + case API_WEBAUDIO: + if (this.buffer.myapi === API_WEBAUDIO) + { + if (this.is_paused) + this.resume_position = pos; + else + { + this.pause(); + this.resume_position = pos; + this.resume(); + } + } + else + { + try { + this.instanceObject.currentTime = pos; + } + catch (e) {} + } + break; + case API_CORDOVA: + break; + case API_APPMOBI: + if (audRuntime.isDirectCanvas) + AppMobi["context"]["seekSound"](this.src, pos); + break; + } + }; + C2AudioInstance.prototype.reconnect = function (toNode) + { + if (this.myapi !== API_WEBAUDIO) + return; + if (this.pannerEnabled) + { + this.pannerNode["disconnect"](); + this.pannerNode["connect"](toNode); + } + else + { + this.gainNode["disconnect"](); + this.gainNode["connect"](toNode); + } + }; + C2AudioInstance.prototype.getDuration = function (applyPlaybackRate) + { + var ret = 0; + switch (this.myapi) { + case API_HTML5: + if (typeof this.instanceObject.duration !== "undefined") + ret = this.instanceObject.duration; + break; + case API_WEBAUDIO: + ret = this.buffer.bufferObject["duration"]; + break; + case API_CORDOVA: + ret = this.instanceObject["getDuration"](); + break; + case API_APPMOBI: + if (audRuntime.isDirectCanvas) + ret = AppMobi["context"]["getDurationSound"](this.src); + break; + } + if (applyPlaybackRate) + ret /= (this.playbackRate || 0.001); // avoid divide-by-zero + return ret; + }; + C2AudioInstance.prototype.getPlaybackTime = function (applyPlaybackRate) + { + var duration = this.getDuration(); + var ret = 0; + switch (this.myapi) { + case API_HTML5: + if (typeof this.instanceObject.currentTime !== "undefined") + ret = this.instanceObject.currentTime; + break; + case API_WEBAUDIO: + if (this.buffer.myapi === API_WEBAUDIO) + { + if (this.is_paused) + return this.resume_position; + else + ret = (this.isTimescaled ? audRuntime.kahanTime.sum : audRuntime.wallTime.sum) - this.startTime; + } + else if (typeof this.instanceObject.currentTime !== "undefined") + ret = this.instanceObject.currentTime; + break; + case API_CORDOVA: + break; + case API_APPMOBI: + if (audRuntime.isDirectCanvas) + ret = AppMobi["context"]["getPlaybackTimeSound"](this.src); + break; + } + if (applyPlaybackRate) + ret *= this.playbackRate; + if (!this.looping && ret > duration) + ret = duration; + return ret; + }; + C2AudioInstance.prototype.isPlaying = function () + { + return !this.is_paused && !this.fresh && !this.stopped && !this.hasEnded(); + }; + C2AudioInstance.prototype.shouldSave = function () + { + return !this.fresh && !this.stopped && !this.hasEnded(); + }; + C2AudioInstance.prototype.setVolume = function (v) + { + this.volume = v; + this.updateVolume(); + }; + C2AudioInstance.prototype.updateVolume = function () + { + var volToSet = this.volume * masterVolume; + if (!isFinite(volToSet)) + volToSet = 0; // HTMLMediaElement throws if setting non-finite volume + switch (this.myapi) { + case API_HTML5: + if (typeof this.instanceObject.volume !== "undefined" && this.instanceObject.volume !== volToSet) + this.instanceObject.volume = volToSet; + break; + case API_WEBAUDIO: + if (this.buffer.myapi === API_WEBAUDIO) + { + this.gainNode["gain"]["value"] = volToSet * this.mutevol; + } + else + { + if (typeof this.instanceObject.volume !== "undefined" && this.instanceObject.volume !== volToSet) + this.instanceObject.volume = volToSet; + } + break; + case API_CORDOVA: + break; + case API_APPMOBI: + break; + } + }; + C2AudioInstance.prototype.getVolume = function () + { + return this.volume; + }; + C2AudioInstance.prototype.doSetMuted = function (m) + { + switch (this.myapi) { + case API_HTML5: + if (this.instanceObject.muted !== !!m) + this.instanceObject.muted = !!m; + break; + case API_WEBAUDIO: + if (this.buffer.myapi === API_WEBAUDIO) + { + this.mutevol = (m ? 0 : 1); + this.gainNode["gain"]["value"] = masterVolume * this.volume * this.mutevol; + } + else + { + if (this.instanceObject.muted !== !!m) + this.instanceObject.muted = !!m; + } + break; + case API_CORDOVA: + break; + case API_APPMOBI: + break; + } + }; + C2AudioInstance.prototype.setMuted = function (m) + { + this.is_muted = !!m; + this.doSetMuted(this.is_muted || this.is_silent); + }; + C2AudioInstance.prototype.setSilent = function (m) + { + this.is_silent = !!m; + this.doSetMuted(this.is_muted || this.is_silent); + }; + C2AudioInstance.prototype.setLooping = function (l) + { + this.looping = l; + switch (this.myapi) { + case API_HTML5: + if (this.instanceObject.loop !== !!l) + this.instanceObject.loop = !!l; + break; + case API_WEBAUDIO: + if (this.instanceObject.loop !== !!l) + this.instanceObject.loop = !!l; + break; + case API_CORDOVA: + break; + case API_APPMOBI: + if (audRuntime.isDirectCanvas) + AppMobi["context"]["setLoopingSound"](this.src, l); + break; + } + }; + C2AudioInstance.prototype.setPlaybackRate = function (r) + { + this.playbackRate = r; + this.updatePlaybackRate(); + }; + C2AudioInstance.prototype.updatePlaybackRate = function () + { + var r = this.playbackRate; + if (this.isTimescaled) + r *= audRuntime.timescale; + switch (this.myapi) { + case API_HTML5: + if (this.instanceObject.playbackRate !== r) + this.instanceObject.playbackRate = r; + break; + case API_WEBAUDIO: + if (this.buffer.myapi === API_WEBAUDIO) + { + if (this.instanceObject["playbackRate"]["value"] !== r) + this.instanceObject["playbackRate"]["value"] = r; + } + else + { + if (this.instanceObject.playbackRate !== r) + this.instanceObject.playbackRate = r; + } + break; + case API_CORDOVA: + break; + case API_APPMOBI: + break; + } + }; + C2AudioInstance.prototype.setSuspended = function (s) + { + switch (this.myapi) { + case API_HTML5: + if (s) + { + if (this.isPlaying()) + { + this.resume_me = true; + this.instanceObject["pause"](); + } + else + this.resume_me = false; + } + else + { + if (this.resume_me) + { + this.instanceObject["play"](); + this.resume_me = false; + } + } + break; + case API_WEBAUDIO: + if (s) + { + if (this.isPlaying()) + { + this.resume_me = true; + if (this.buffer.myapi === API_WEBAUDIO) + { + this.resume_position = this.getPlaybackTime(true); + if (this.looping) + this.resume_position = this.resume_position % this.getDuration(); + stopSource(this.instanceObject); + } + else + this.instanceObject["pause"](); + } + else + this.resume_me = false; + } + else + { + if (this.resume_me) + { + if (this.buffer.myapi === API_WEBAUDIO) + { + this.instanceObject = context["createBufferSource"](); + this.instanceObject["buffer"] = this.buffer.bufferObject; + this.instanceObject["connect"](this.gainNode); + this.instanceObject["onended"] = this.onended_handler; + this.active_buffer = this.instanceObject; + this.instanceObject.loop = this.looping; + this.gainNode["gain"]["value"] = masterVolume * this.volume * this.mutevol; + this.updatePlaybackRate(); + this.startTime = (this.isTimescaled ? audRuntime.kahanTime.sum : audRuntime.wallTime.sum) - (this.resume_position / (this.playbackRate || 0.001)); + startSourceAt(this.instanceObject, this.resume_position, this.getDuration()); + } + else + { + this.instanceObject["play"](); + } + this.resume_me = false; + } + } + break; + case API_CORDOVA: + if (s) + { + if (this.isPlaying()) + { + this.instanceObject["pause"](); + this.resume_me = true; + } + else + this.resume_me = false; + } + else + { + if (this.resume_me) + { + this.resume_me = false; + this.instanceObject["play"](); + } + } + break; + case API_APPMOBI: + break; + } + }; + pluginProto.Instance = function(type) + { + this.type = type; + this.runtime = type.runtime; + audRuntime = this.runtime; + audInst = this; + this.listenerTracker = null; + this.listenerZ = -600; + if (this.runtime.isWKWebView) + playMusicAsSoundWorkaround = true; + if ((this.runtime.isiOS || (this.runtime.isAndroid && (this.runtime.isChrome || this.runtime.isAndroidStockBrowser))) && !this.runtime.isCrosswalk && !this.runtime.isDomFree && !this.runtime.isAmazonWebApp && !playMusicAsSoundWorkaround) + { + useNextTouchWorkaround = true; + } + context = null; + if (typeof AudioContext !== "undefined") + { + api = API_WEBAUDIO; + context = new AudioContext(); + } + else if (typeof webkitAudioContext !== "undefined") + { + api = API_WEBAUDIO; + context = new webkitAudioContext(); + } + if (this.runtime.isiOS && context) + { + if (context.close) + context.close(); + if (typeof AudioContext !== "undefined") + context = new AudioContext(); + else if (typeof webkitAudioContext !== "undefined") + context = new webkitAudioContext(); + } + if (api !== API_WEBAUDIO) + { + if (this.runtime.isCordova && typeof window["Media"] !== "undefined") + api = API_CORDOVA; + else if (this.runtime.isAppMobi) + api = API_APPMOBI; + } + if (api === API_CORDOVA) + { + appPath = location.href; + var i = appPath.lastIndexOf("/"); + if (i > -1) + appPath = appPath.substr(0, i + 1); + appPath = appPath.replace("file://", ""); + } + if (this.runtime.isSafari && this.runtime.isWindows && typeof Audio === "undefined") + { + alert("It looks like you're using Safari for Windows without Quicktime. Audio cannot be played until Quicktime is installed."); + this.runtime.DestroyInstance(this); + } + else + { + if (this.runtime.isDirectCanvas) + useOgg = this.runtime.isAndroid; // AAC on iOS, OGG on Android + else + { + try { + useOgg = !!(new Audio().canPlayType('audio/ogg; codecs="vorbis"')) && + !this.runtime.isWindows10; + } + catch (e) + { + useOgg = false; + } + } + switch (api) { + case API_HTML5: +; + break; + case API_WEBAUDIO: +; + break; + case API_CORDOVA: +; + break; + case API_APPMOBI: +; + break; + default: +; + } + this.runtime.tickMe(this); + } + }; + var instanceProto = pluginProto.Instance.prototype; + instanceProto.onCreate = function () + { + this.runtime.audioInstance = this; + timescale_mode = this.properties[0]; // 0 = off, 1 = sounds only, 2 = all + this.saveload = this.properties[1]; // 0 = all, 1 = sounds only, 2 = music only, 3 = none + this.playinbackground = (this.properties[2] !== 0); + this.nextPlayTime = 0; + panningModel = this.properties[3]; // 0 = equalpower, 1 = hrtf, 3 = soundfield + distanceModel = this.properties[4]; // 0 = linear, 1 = inverse, 2 = exponential + this.listenerZ = -this.properties[5]; + refDistance = this.properties[6]; + maxDistance = this.properties[7]; + rolloffFactor = this.properties[8]; + this.listenerTracker = new ObjectTracker(); + var draw_width = (this.runtime.draw_width || this.runtime.width); + var draw_height = (this.runtime.draw_height || this.runtime.height); + if (api === API_WEBAUDIO) + { + context["listener"]["setPosition"](draw_width / 2, draw_height / 2, this.listenerZ); + context["listener"]["setOrientation"](0, 0, 1, 0, -1, 0); + window["c2OnAudioMicStream"] = function (localMediaStream, tag) + { + if (micSource) + micSource["disconnect"](); + micTag = tag.toLowerCase(); + micSource = context["createMediaStreamSource"](localMediaStream); + micSource["connect"](getDestinationForTag(micTag)); + }; + } + this.runtime.addSuspendCallback(function(s) + { + audInst.onSuspend(s); + }); + var self = this; + this.runtime.addDestroyCallback(function (inst) + { + self.onInstanceDestroyed(inst); + }); + }; + instanceProto.onInstanceDestroyed = function (inst) + { + var i, len, a; + for (i = 0, len = audioInstances.length; i < len; i++) + { + a = audioInstances[i]; + if (a.objectTracker) + { + if (a.objectTracker.obj === inst) + { + a.objectTracker.obj = null; + if (a.pannerEnabled && a.isPlaying() && a.looping) + a.stop(); + } + } + } + if (this.listenerTracker.obj === inst) + this.listenerTracker.obj = null; + }; + instanceProto.saveToJSON = function () + { + var o = { + "silent": silent, + "masterVolume": masterVolume, + "listenerZ": this.listenerZ, + "listenerUid": this.listenerTracker.hasObject() ? this.listenerTracker.obj.uid : -1, + "playing": [], + "effects": {} + }; + var playingarr = o["playing"]; + var i, len, a, d, p, panobj, playbackTime; + for (i = 0, len = audioInstances.length; i < len; i++) + { + a = audioInstances[i]; + if (!a.shouldSave()) + continue; // no need to save stopped sounds + if (this.saveload === 3) // not saving/loading any sounds/music + continue; + if (a.is_music && this.saveload === 1) // not saving/loading music + continue; + if (!a.is_music && this.saveload === 2) // not saving/loading sound + continue; + playbackTime = a.getPlaybackTime(); + if (a.looping) + playbackTime = playbackTime % a.getDuration(); + d = { + "tag": a.tag, + "buffersrc": a.buffer.src, + "is_music": a.is_music, + "playbackTime": playbackTime, + "volume": a.volume, + "looping": a.looping, + "muted": a.is_muted, + "playbackRate": a.playbackRate, + "paused": a.is_paused, + "resume_position": a.resume_position + }; + if (a.pannerEnabled) + { + d["pan"] = {}; + panobj = d["pan"]; + if (a.objectTracker && a.objectTracker.hasObject()) + { + panobj["objUid"] = a.objectTracker.obj.uid; + } + else + { + panobj["x"] = a.panX; + panobj["y"] = a.panY; + panobj["a"] = a.panAngle; + } + panobj["ia"] = a.panConeInner; + panobj["oa"] = a.panConeOuter; + panobj["og"] = a.panConeOuterGain; + } + playingarr.push(d); + } + var fxobj = o["effects"]; + var fxarr; + for (p in effects) + { + if (effects.hasOwnProperty(p)) + { + fxarr = []; + for (i = 0, len = effects[p].length; i < len; i++) + { + fxarr.push({ "type": effects[p][i].type, "params": effects[p][i].params }); + } + fxobj[p] = fxarr; + } + } + return o; + }; + var objectTrackerUidsToLoad = []; + instanceProto.loadFromJSON = function (o) + { + var setSilent = o["silent"]; + masterVolume = o["masterVolume"]; + this.listenerZ = o["listenerZ"]; + this.listenerTracker.setObject(null); + var listenerUid = o["listenerUid"]; + if (listenerUid !== -1) + { + this.listenerTracker.loadUid = listenerUid; + objectTrackerUidsToLoad.push(this.listenerTracker); + } + var playingarr = o["playing"]; + var i, len, d, src, is_music, tag, playbackTime, looping, vol, b, a, p, pan, panObjUid; + if (this.saveload !== 3) + { + for (i = 0, len = audioInstances.length; i < len; i++) + { + a = audioInstances[i]; + if (a.is_music && this.saveload === 1) + continue; // only saving/loading sound: leave music playing + if (!a.is_music && this.saveload === 2) + continue; // only saving/loading music: leave sound playing + a.stop(); + } + } + var fxarr, fxtype, fxparams, fx; + for (p in effects) + { + if (effects.hasOwnProperty(p)) + { + for (i = 0, len = effects[p].length; i < len; i++) + effects[p][i].remove(); + } + } + cr.wipe(effects); + for (p in o["effects"]) + { + if (o["effects"].hasOwnProperty(p)) + { + fxarr = o["effects"][p]; + for (i = 0, len = fxarr.length; i < len; i++) + { + fxtype = fxarr[i]["type"]; + fxparams = fxarr[i]["params"]; + switch (fxtype) { + case "filter": + addEffectForTag(p, new FilterEffect(fxparams[0], fxparams[1], fxparams[2], fxparams[3], fxparams[4], fxparams[5])); + break; + case "delay": + addEffectForTag(p, new DelayEffect(fxparams[0], fxparams[1], fxparams[2])); + break; + case "convolve": + src = fxparams[2]; + b = this.getAudioBuffer(src, false); + if (b.bufferObject) + { + fx = new ConvolveEffect(b.bufferObject, fxparams[0], fxparams[1], src); + } + else + { + fx = new ConvolveEffect(null, fxparams[0], fxparams[1], src); + b.normalizeWhenReady = fxparams[0]; + b.convolveWhenReady = fx; + } + addEffectForTag(p, fx); + break; + case "flanger": + addEffectForTag(p, new FlangerEffect(fxparams[0], fxparams[1], fxparams[2], fxparams[3], fxparams[4])); + break; + case "phaser": + addEffectForTag(p, new PhaserEffect(fxparams[0], fxparams[1], fxparams[2], fxparams[3], fxparams[4], fxparams[5])); + break; + case "gain": + addEffectForTag(p, new GainEffect(fxparams[0])); + break; + case "tremolo": + addEffectForTag(p, new TremoloEffect(fxparams[0], fxparams[1])); + break; + case "ringmod": + addEffectForTag(p, new RingModulatorEffect(fxparams[0], fxparams[1])); + break; + case "distortion": + addEffectForTag(p, new DistortionEffect(fxparams[0], fxparams[1], fxparams[2], fxparams[3], fxparams[4])); + break; + case "compressor": + addEffectForTag(p, new CompressorEffect(fxparams[0], fxparams[1], fxparams[2], fxparams[3], fxparams[4])); + break; + case "analyser": + addEffectForTag(p, new AnalyserEffect(fxparams[0], fxparams[1])); + break; + } + } + } + } + for (i = 0, len = playingarr.length; i < len; i++) + { + if (this.saveload === 3) // not saving/loading any sounds/music + continue; + d = playingarr[i]; + src = d["buffersrc"]; + is_music = d["is_music"]; + tag = d["tag"]; + playbackTime = d["playbackTime"]; + looping = d["looping"]; + vol = d["volume"]; + pan = d["pan"]; + panObjUid = (pan && pan.hasOwnProperty("objUid")) ? pan["objUid"] : -1; + if (is_music && this.saveload === 1) // not saving/loading music + continue; + if (!is_music && this.saveload === 2) // not saving/loading sound + continue; + a = this.getAudioInstance(src, tag, is_music, looping, vol); + if (!a) + { + b = this.getAudioBuffer(src, is_music); + b.seekWhenReady = playbackTime; + b.pauseWhenReady = d["paused"]; + if (pan) + { + if (panObjUid !== -1) + { + b.panWhenReady.push({ objUid: panObjUid, ia: pan["ia"], oa: pan["oa"], og: pan["og"], thistag: tag }); + } + else + { + b.panWhenReady.push({ x: pan["x"], y: pan["y"], a: pan["a"], ia: pan["ia"], oa: pan["oa"], og: pan["og"], thistag: tag }); + } + } + continue; + } + a.resume_position = d["resume_position"]; + a.setPannerEnabled(!!pan); + a.play(looping, vol, playbackTime); + a.updatePlaybackRate(); + a.updateVolume(); + a.doSetMuted(a.is_muted || a.is_silent); + if (d["paused"]) + a.pause(); + if (d["muted"]) + a.setMuted(true); + a.doSetMuted(a.is_muted || a.is_silent); + if (pan) + { + if (panObjUid !== -1) + { + a.objectTracker = a.objectTracker || new ObjectTracker(); + a.objectTracker.loadUid = panObjUid; + objectTrackerUidsToLoad.push(a.objectTracker); + } + else + { + a.setPan(pan["x"], pan["y"], pan["a"], pan["ia"], pan["oa"], pan["og"]); + } + } + } + if (setSilent && !silent) // setting silent + { + for (i = 0, len = audioInstances.length; i < len; i++) + audioInstances[i].setSilent(true); + silent = true; + } + else if (!setSilent && silent) // setting not silent + { + for (i = 0, len = audioInstances.length; i < len; i++) + audioInstances[i].setSilent(false); + silent = false; + } + }; + instanceProto.afterLoad = function () + { + var i, len, ot, inst; + for (i = 0, len = objectTrackerUidsToLoad.length; i < len; i++) + { + ot = objectTrackerUidsToLoad[i]; + inst = this.runtime.getObjectByUID(ot.loadUid); + ot.setObject(inst); + ot.loadUid = -1; + if (inst) + { + listenerX = inst.x; + listenerY = inst.y; + } + } + cr.clearArray(objectTrackerUidsToLoad); + }; + instanceProto.onSuspend = function (s) + { + if (this.playinbackground) + return; + if (!s && context && context["resume"]) + { + context["resume"](); + isContextSuspended = false; + } + var i, len; + for (i = 0, len = audioInstances.length; i < len; i++) + audioInstances[i].setSuspended(s); + if (s && context && context["suspend"]) + { + context["suspend"](); + isContextSuspended = true; + } + }; + instanceProto.tick = function () + { + var dt = this.runtime.dt; + var i, len, a; + for (i = 0, len = audioInstances.length; i < len; i++) + { + a = audioInstances[i]; + a.tick(dt); + if (timescale_mode !== 0) + a.updatePlaybackRate(); + } + var p, arr, f; + for (p in effects) + { + if (effects.hasOwnProperty(p)) + { + arr = effects[p]; + for (i = 0, len = arr.length; i < len; i++) + { + f = arr[i]; + if (f.tick) + f.tick(); + } + } + } + if (api === API_WEBAUDIO && this.listenerTracker.hasObject()) + { + this.listenerTracker.tick(dt); + listenerX = this.listenerTracker.obj.x; + listenerY = this.listenerTracker.obj.y; + context["listener"]["setPosition"](this.listenerTracker.obj.x, this.listenerTracker.obj.y, this.listenerZ); + } + }; + var preload_list = []; + instanceProto.setPreloadList = function (arr) + { + var i, len, p, filename, size, isOgg; + var total_size = 0; + for (i = 0, len = arr.length; i < len; ++i) + { + p = arr[i]; + filename = p[0]; + size = p[1] * 2; + isOgg = (filename.length > 4 && filename.substr(filename.length - 4) === ".ogg"); + if ((isOgg && useOgg) || (!isOgg && !useOgg)) + { + preload_list.push({ + filename: filename, + size: size, + obj: null + }); + total_size += size; + } + } + return total_size; + }; + instanceProto.startPreloads = function () + { + var i, len, p, src; + for (i = 0, len = preload_list.length; i < len; ++i) + { + p = preload_list[i]; + src = this.runtime.files_subfolder + p.filename; + p.obj = this.getAudioBuffer(src, false); + } + }; + instanceProto.getPreloadedSize = function () + { + var completed = 0; + var i, len, p; + for (i = 0, len = preload_list.length; i < len; ++i) + { + p = preload_list[i]; + if (p.obj.isLoadedAndDecoded() || p.obj.hasFailedToLoad() || this.runtime.isDomFree || this.runtime.isAndroidStockBrowser) + { + completed += p.size; + } + else if (p.obj.isLoaded()) // downloaded but not decoded: only happens in Web Audio API, count as half-way progress + { + completed += Math.floor(p.size / 2); + } + }; + return completed; + }; + instanceProto.releaseAllMusicBuffers = function () + { + var i, len, j, b; + for (i = 0, j = 0, len = audioBuffers.length; i < len; ++i) + { + b = audioBuffers[i]; + audioBuffers[j] = b; + if (b.is_music) + b.release(); + else + ++j; // keep + } + audioBuffers.length = j; + }; + instanceProto.getAudioBuffer = function (src_, is_music, dont_create) + { + var i, len, a, ret = null, j, k, lenj, ai; + for (i = 0, len = audioBuffers.length; i < len; i++) + { + a = audioBuffers[i]; + if (a.src === src_) + { + ret = a; + break; + } + } + if (!ret && !dont_create) + { + if (playMusicAsSoundWorkaround && is_music) + this.releaseAllMusicBuffers(); + ret = new C2AudioBuffer(src_, is_music); + audioBuffers.push(ret); + } + return ret; + }; + instanceProto.getAudioInstance = function (src_, tag, is_music, looping, vol) + { + var i, len, a; + for (i = 0, len = audioInstances.length; i < len; i++) + { + a = audioInstances[i]; + if (a.src === src_ && (a.canBeRecycled() || is_music)) + { + a.tag = tag; + return a; + } + } + var b = this.getAudioBuffer(src_, is_music); + if (!b.bufferObject) + { + if (tag !== "") + { + b.playTagWhenReady = tag; + b.loopWhenReady = looping; + b.volumeWhenReady = vol; + } + return null; + } + a = new C2AudioInstance(b, tag); + audioInstances.push(a); + return a; + }; + var taggedAudio = []; + function SortByIsPlaying(a, b) + { + var an = a.isPlaying() ? 1 : 0; + var bn = b.isPlaying() ? 1 : 0; + if (an === bn) + return 0; + else if (an < bn) + return 1; + else + return -1; + }; + function getAudioByTag(tag, sort_by_playing) + { + cr.clearArray(taggedAudio); + if (!tag.length) + { + if (!lastAudio || lastAudio.hasEnded()) + return; + else + { + cr.clearArray(taggedAudio); + taggedAudio[0] = lastAudio; + return; + } + } + var i, len, a; + for (i = 0, len = audioInstances.length; i < len; i++) + { + a = audioInstances[i]; + if (cr.equals_nocase(tag, a.tag)) + taggedAudio.push(a); + } + if (sort_by_playing) + taggedAudio.sort(SortByIsPlaying); + }; + function reconnectEffects(tag) + { + var i, len, arr, n, toNode = context["destination"]; + if (effects.hasOwnProperty(tag)) + { + arr = effects[tag]; + if (arr.length) + { + toNode = arr[0].getInputNode(); + for (i = 0, len = arr.length; i < len; i++) + { + n = arr[i]; + if (i + 1 === len) + n.connectTo(context["destination"]); + else + n.connectTo(arr[i + 1].getInputNode()); + } + } + } + getAudioByTag(tag); + for (i = 0, len = taggedAudio.length; i < len; i++) + taggedAudio[i].reconnect(toNode); + if (micSource && micTag === tag) + { + micSource["disconnect"](); + micSource["connect"](toNode); + } + }; + function addEffectForTag(tag, fx) + { + if (!effects.hasOwnProperty(tag)) + effects[tag] = [fx]; + else + effects[tag].push(fx); + reconnectEffects(tag); + }; + function Cnds() {}; + Cnds.prototype.OnEnded = function (t) + { + return cr.equals_nocase(audTag, t); + }; + Cnds.prototype.PreloadsComplete = function () + { + var i, len; + for (i = 0, len = audioBuffers.length; i < len; i++) + { + if (!audioBuffers[i].isLoadedAndDecoded() && !audioBuffers[i].hasFailedToLoad()) + return false; + } + return true; + }; + Cnds.prototype.AdvancedAudioSupported = function () + { + return api === API_WEBAUDIO; + }; + Cnds.prototype.IsSilent = function () + { + return silent; + }; + Cnds.prototype.IsAnyPlaying = function () + { + var i, len; + for (i = 0, len = audioInstances.length; i < len; i++) + { + if (audioInstances[i].isPlaying()) + return true; + } + return false; + }; + Cnds.prototype.IsTagPlaying = function (tag) + { + getAudioByTag(tag); + var i, len; + for (i = 0, len = taggedAudio.length; i < len; i++) + { + if (taggedAudio[i].isPlaying()) + return true; + } + return false; + }; + pluginProto.cnds = new Cnds(); + function Acts() {}; + Acts.prototype.Play = function (file, looping, vol, tag) + { + if (silent) + return; + var v = dbToLinear(vol); + var is_music = file[1]; + var src = this.runtime.files_subfolder + file[0] + (useOgg ? ".ogg" : ".m4a"); + lastAudio = this.getAudioInstance(src, tag, is_music, looping!==0, v); + if (!lastAudio) + return; + lastAudio.setPannerEnabled(false); + lastAudio.play(looping!==0, v, 0, this.nextPlayTime); + this.nextPlayTime = 0; + }; + Acts.prototype.PlayAtPosition = function (file, looping, vol, x_, y_, angle_, innerangle_, outerangle_, outergain_, tag) + { + if (silent) + return; + var v = dbToLinear(vol); + var is_music = file[1]; + var src = this.runtime.files_subfolder + file[0] + (useOgg ? ".ogg" : ".m4a"); + lastAudio = this.getAudioInstance(src, tag, is_music, looping!==0, v); + if (!lastAudio) + { + var b = this.getAudioBuffer(src, is_music); + b.panWhenReady.push({ x: x_, y: y_, a: angle_, ia: innerangle_, oa: outerangle_, og: dbToLinear(outergain_), thistag: tag }); + return; + } + lastAudio.setPannerEnabled(true); + lastAudio.setPan(x_, y_, angle_, innerangle_, outerangle_, dbToLinear(outergain_)); + lastAudio.play(looping!==0, v, 0, this.nextPlayTime); + this.nextPlayTime = 0; + }; + Acts.prototype.PlayAtObject = function (file, looping, vol, obj, innerangle, outerangle, outergain, tag) + { + if (silent || !obj) + return; + var inst = obj.getFirstPicked(); + if (!inst) + return; + var v = dbToLinear(vol); + var is_music = file[1]; + var src = this.runtime.files_subfolder + file[0] + (useOgg ? ".ogg" : ".m4a"); + lastAudio = this.getAudioInstance(src, tag, is_music, looping!==0, v); + if (!lastAudio) + { + var b = this.getAudioBuffer(src, is_music); + b.panWhenReady.push({ obj: inst, ia: innerangle, oa: outerangle, og: dbToLinear(outergain), thistag: tag }); + return; + } + lastAudio.setPannerEnabled(true); + var px = cr.rotatePtAround(inst.x, inst.y, -inst.layer.getAngle(), listenerX, listenerY, true); + var py = cr.rotatePtAround(inst.x, inst.y, -inst.layer.getAngle(), listenerX, listenerY, false); + lastAudio.setPan(px, py, cr.to_degrees(inst.angle - inst.layer.getAngle()), innerangle, outerangle, dbToLinear(outergain)); + lastAudio.setObject(inst); + lastAudio.play(looping!==0, v, 0, this.nextPlayTime); + this.nextPlayTime = 0; + }; + Acts.prototype.PlayByName = function (folder, filename, looping, vol, tag) + { + if (silent) + return; + var v = dbToLinear(vol); + var is_music = (folder === 1); + var src = this.runtime.files_subfolder + filename.toLowerCase() + (useOgg ? ".ogg" : ".m4a"); + lastAudio = this.getAudioInstance(src, tag, is_music, looping!==0, v); + if (!lastAudio) + return; + lastAudio.setPannerEnabled(false); + lastAudio.play(looping!==0, v, 0, this.nextPlayTime); + this.nextPlayTime = 0; + }; + Acts.prototype.PlayAtPositionByName = function (folder, filename, looping, vol, x_, y_, angle_, innerangle_, outerangle_, outergain_, tag) + { + if (silent) + return; + var v = dbToLinear(vol); + var is_music = (folder === 1); + var src = this.runtime.files_subfolder + filename.toLowerCase() + (useOgg ? ".ogg" : ".m4a"); + lastAudio = this.getAudioInstance(src, tag, is_music, looping!==0, v); + if (!lastAudio) + { + var b = this.getAudioBuffer(src, is_music); + b.panWhenReady.push({ x: x_, y: y_, a: angle_, ia: innerangle_, oa: outerangle_, og: dbToLinear(outergain_), thistag: tag }); + return; + } + lastAudio.setPannerEnabled(true); + lastAudio.setPan(x_, y_, angle_, innerangle_, outerangle_, dbToLinear(outergain_)); + lastAudio.play(looping!==0, v, 0, this.nextPlayTime); + this.nextPlayTime = 0; + }; + Acts.prototype.PlayAtObjectByName = function (folder, filename, looping, vol, obj, innerangle, outerangle, outergain, tag) + { + if (silent || !obj) + return; + var inst = obj.getFirstPicked(); + if (!inst) + return; + var v = dbToLinear(vol); + var is_music = (folder === 1); + var src = this.runtime.files_subfolder + filename.toLowerCase() + (useOgg ? ".ogg" : ".m4a"); + lastAudio = this.getAudioInstance(src, tag, is_music, looping!==0, v); + if (!lastAudio) + { + var b = this.getAudioBuffer(src, is_music); + b.panWhenReady.push({ obj: inst, ia: innerangle, oa: outerangle, og: dbToLinear(outergain), thistag: tag }); + return; + } + lastAudio.setPannerEnabled(true); + var px = cr.rotatePtAround(inst.x, inst.y, -inst.layer.getAngle(), listenerX, listenerY, true); + var py = cr.rotatePtAround(inst.x, inst.y, -inst.layer.getAngle(), listenerX, listenerY, false); + lastAudio.setPan(px, py, cr.to_degrees(inst.angle - inst.layer.getAngle()), innerangle, outerangle, dbToLinear(outergain)); + lastAudio.setObject(inst); + lastAudio.play(looping!==0, v, 0, this.nextPlayTime); + this.nextPlayTime = 0; + }; + Acts.prototype.SetLooping = function (tag, looping) + { + getAudioByTag(tag); + var i, len; + for (i = 0, len = taggedAudio.length; i < len; i++) + taggedAudio[i].setLooping(looping === 0); + }; + Acts.prototype.SetMuted = function (tag, muted) + { + getAudioByTag(tag); + var i, len; + for (i = 0, len = taggedAudio.length; i < len; i++) + taggedAudio[i].setMuted(muted === 0); + }; + Acts.prototype.SetVolume = function (tag, vol) + { + getAudioByTag(tag); + var v = dbToLinear(vol); + var i, len; + for (i = 0, len = taggedAudio.length; i < len; i++) + taggedAudio[i].setVolume(v); + }; + Acts.prototype.Preload = function (file) + { + if (silent) + return; + var is_music = file[1]; + var src = this.runtime.files_subfolder + file[0] + (useOgg ? ".ogg" : ".m4a"); + if (api === API_APPMOBI) + { + if (this.runtime.isDirectCanvas) + AppMobi["context"]["loadSound"](src); + else + AppMobi["player"]["loadSound"](src); + return; + } + else if (api === API_CORDOVA) + { + return; + } + this.getAudioInstance(src, "", is_music, false); + }; + Acts.prototype.PreloadByName = function (folder, filename) + { + if (silent) + return; + var is_music = (folder === 1); + var src = this.runtime.files_subfolder + filename.toLowerCase() + (useOgg ? ".ogg" : ".m4a"); + if (api === API_APPMOBI) + { + if (this.runtime.isDirectCanvas) + AppMobi["context"]["loadSound"](src); + else + AppMobi["player"]["loadSound"](src); + return; + } + else if (api === API_CORDOVA) + { + return; + } + this.getAudioInstance(src, "", is_music, false); + }; + Acts.prototype.SetPlaybackRate = function (tag, rate) + { + getAudioByTag(tag); + if (rate < 0.0) + rate = 0; + var i, len; + for (i = 0, len = taggedAudio.length; i < len; i++) + taggedAudio[i].setPlaybackRate(rate); + }; + Acts.prototype.Stop = function (tag) + { + getAudioByTag(tag); + var i, len; + for (i = 0, len = taggedAudio.length; i < len; i++) + taggedAudio[i].stop(); + }; + Acts.prototype.StopAll = function () + { + var i, len; + for (i = 0, len = audioInstances.length; i < len; i++) + audioInstances[i].stop(); + }; + Acts.prototype.SetPaused = function (tag, state) + { + getAudioByTag(tag); + var i, len; + for (i = 0, len = taggedAudio.length; i < len; i++) + { + if (state === 0) + taggedAudio[i].pause(); + else + taggedAudio[i].resume(); + } + }; + Acts.prototype.Seek = function (tag, pos) + { + getAudioByTag(tag); + var i, len; + for (i = 0, len = taggedAudio.length; i < len; i++) + { + taggedAudio[i].seek(pos); + } + }; + Acts.prototype.SetSilent = function (s) + { + var i, len; + if (s === 2) // toggling + s = (silent ? 1 : 0); // choose opposite state + if (s === 0 && !silent) // setting silent + { + for (i = 0, len = audioInstances.length; i < len; i++) + audioInstances[i].setSilent(true); + silent = true; + } + else if (s === 1 && silent) // setting not silent + { + for (i = 0, len = audioInstances.length; i < len; i++) + audioInstances[i].setSilent(false); + silent = false; + } + }; + Acts.prototype.SetMasterVolume = function (vol) + { + masterVolume = dbToLinear(vol); + var i, len; + for (i = 0, len = audioInstances.length; i < len; i++) + audioInstances[i].updateVolume(); + }; + Acts.prototype.AddFilterEffect = function (tag, type, freq, detune, q, gain, mix) + { + if (api !== API_WEBAUDIO || type < 0 || type >= filterTypes.length || !context["createBiquadFilter"]) + return; + tag = tag.toLowerCase(); + mix = mix / 100; + if (mix < 0) mix = 0; + if (mix > 1) mix = 1; + addEffectForTag(tag, new FilterEffect(type, freq, detune, q, gain, mix)); + }; + Acts.prototype.AddDelayEffect = function (tag, delay, gain, mix) + { + if (api !== API_WEBAUDIO) + return; + tag = tag.toLowerCase(); + mix = mix / 100; + if (mix < 0) mix = 0; + if (mix > 1) mix = 1; + addEffectForTag(tag, new DelayEffect(delay, dbToLinear(gain), mix)); + }; + Acts.prototype.AddFlangerEffect = function (tag, delay, modulation, freq, feedback, mix) + { + if (api !== API_WEBAUDIO || !context["createOscillator"]) + return; + tag = tag.toLowerCase(); + mix = mix / 100; + if (mix < 0) mix = 0; + if (mix > 1) mix = 1; + addEffectForTag(tag, new FlangerEffect(delay / 1000, modulation / 1000, freq, feedback / 100, mix)); + }; + Acts.prototype.AddPhaserEffect = function (tag, freq, detune, q, mod, modfreq, mix) + { + if (api !== API_WEBAUDIO || !context["createOscillator"]) + return; + tag = tag.toLowerCase(); + mix = mix / 100; + if (mix < 0) mix = 0; + if (mix > 1) mix = 1; + addEffectForTag(tag, new PhaserEffect(freq, detune, q, mod, modfreq, mix)); + }; + Acts.prototype.AddConvolutionEffect = function (tag, file, norm, mix) + { + if (api !== API_WEBAUDIO || !context["createConvolver"]) + return; + var doNormalize = (norm === 0); + var src = this.runtime.files_subfolder + file[0] + (useOgg ? ".ogg" : ".m4a"); + var b = this.getAudioBuffer(src, false); + tag = tag.toLowerCase(); + mix = mix / 100; + if (mix < 0) mix = 0; + if (mix > 1) mix = 1; + var fx; + if (b.bufferObject) + { + fx = new ConvolveEffect(b.bufferObject, doNormalize, mix, src); + } + else + { + fx = new ConvolveEffect(null, doNormalize, mix, src); + b.normalizeWhenReady = doNormalize; + b.convolveWhenReady = fx; + } + addEffectForTag(tag, fx); + }; + Acts.prototype.AddGainEffect = function (tag, g) + { + if (api !== API_WEBAUDIO) + return; + tag = tag.toLowerCase(); + addEffectForTag(tag, new GainEffect(dbToLinear(g))); + }; + Acts.prototype.AddMuteEffect = function (tag) + { + if (api !== API_WEBAUDIO) + return; + tag = tag.toLowerCase(); + addEffectForTag(tag, new GainEffect(0)); // re-use gain effect with 0 gain + }; + Acts.prototype.AddTremoloEffect = function (tag, freq, mix) + { + if (api !== API_WEBAUDIO || !context["createOscillator"]) + return; + tag = tag.toLowerCase(); + mix = mix / 100; + if (mix < 0) mix = 0; + if (mix > 1) mix = 1; + addEffectForTag(tag, new TremoloEffect(freq, mix)); + }; + Acts.prototype.AddRingModEffect = function (tag, freq, mix) + { + if (api !== API_WEBAUDIO || !context["createOscillator"]) + return; + tag = tag.toLowerCase(); + mix = mix / 100; + if (mix < 0) mix = 0; + if (mix > 1) mix = 1; + addEffectForTag(tag, new RingModulatorEffect(freq, mix)); + }; + Acts.prototype.AddDistortionEffect = function (tag, threshold, headroom, drive, makeupgain, mix) + { + if (api !== API_WEBAUDIO || !context["createWaveShaper"]) + return; + tag = tag.toLowerCase(); + mix = mix / 100; + if (mix < 0) mix = 0; + if (mix > 1) mix = 1; + addEffectForTag(tag, new DistortionEffect(threshold, headroom, drive, makeupgain, mix)); + }; + Acts.prototype.AddCompressorEffect = function (tag, threshold, knee, ratio, attack, release) + { + if (api !== API_WEBAUDIO || !context["createDynamicsCompressor"]) + return; + tag = tag.toLowerCase(); + addEffectForTag(tag, new CompressorEffect(threshold, knee, ratio, attack / 1000, release / 1000)); + }; + Acts.prototype.AddAnalyserEffect = function (tag, fftSize, smoothing) + { + if (api !== API_WEBAUDIO) + return; + tag = tag.toLowerCase(); + addEffectForTag(tag, new AnalyserEffect(fftSize, smoothing)); + }; + Acts.prototype.RemoveEffects = function (tag) + { + if (api !== API_WEBAUDIO) + return; + tag = tag.toLowerCase(); + var i, len, arr; + if (effects.hasOwnProperty(tag)) + { + arr = effects[tag]; + if (arr.length) + { + for (i = 0, len = arr.length; i < len; i++) + arr[i].remove(); + cr.clearArray(arr); + reconnectEffects(tag); + } + } + }; + Acts.prototype.SetEffectParameter = function (tag, index, param, value, ramp, time) + { + if (api !== API_WEBAUDIO) + return; + tag = tag.toLowerCase(); + index = Math.floor(index); + var arr; + if (!effects.hasOwnProperty(tag)) + return; + arr = effects[tag]; + if (index < 0 || index >= arr.length) + return; + arr[index].setParam(param, value, ramp, time); + }; + Acts.prototype.SetListenerObject = function (obj_) + { + if (!obj_ || api !== API_WEBAUDIO) + return; + var inst = obj_.getFirstPicked(); + if (!inst) + return; + this.listenerTracker.setObject(inst); + listenerX = inst.x; + listenerY = inst.y; + }; + Acts.prototype.SetListenerZ = function (z) + { + this.listenerZ = z; + }; + Acts.prototype.ScheduleNextPlay = function (t) + { + if (!context) + return; // needs Web Audio API + this.nextPlayTime = t; + }; + Acts.prototype.UnloadAudio = function (file) + { + var is_music = file[1]; + var src = this.runtime.files_subfolder + file[0] + (useOgg ? ".ogg" : ".m4a"); + var b = this.getAudioBuffer(src, is_music, true /* don't create if missing */); + if (!b) + return; // not loaded + b.release(); + cr.arrayFindRemove(audioBuffers, b); + }; + Acts.prototype.UnloadAudioByName = function (folder, filename) + { + var is_music = (folder === 1); + var src = this.runtime.files_subfolder + filename.toLowerCase() + (useOgg ? ".ogg" : ".m4a"); + var b = this.getAudioBuffer(src, is_music, true /* don't create if missing */); + if (!b) + return; // not loaded + b.release(); + cr.arrayFindRemove(audioBuffers, b); + }; + Acts.prototype.UnloadAll = function () + { + var i, len; + for (i = 0, len = audioBuffers.length; i < len; ++i) + { + audioBuffers[i].release(); + }; + cr.clearArray(audioBuffers); + }; + pluginProto.acts = new Acts(); + function Exps() {}; + Exps.prototype.Duration = function (ret, tag) + { + getAudioByTag(tag, true); + if (taggedAudio.length) + ret.set_float(taggedAudio[0].getDuration()); + else + ret.set_float(0); + }; + Exps.prototype.PlaybackTime = function (ret, tag) + { + getAudioByTag(tag, true); + if (taggedAudio.length) + ret.set_float(taggedAudio[0].getPlaybackTime(true)); + else + ret.set_float(0); + }; + Exps.prototype.Volume = function (ret, tag) + { + getAudioByTag(tag, true); + if (taggedAudio.length) + { + var v = taggedAudio[0].getVolume(); + ret.set_float(linearToDb(v)); + } + else + ret.set_float(0); + }; + Exps.prototype.MasterVolume = function (ret) + { + ret.set_float(linearToDb(masterVolume)); + }; + Exps.prototype.EffectCount = function (ret, tag) + { + tag = tag.toLowerCase(); + var arr = null; + if (effects.hasOwnProperty(tag)) + arr = effects[tag]; + ret.set_int(arr ? arr.length : 0); + }; + function getAnalyser(tag, index) + { + var arr = null; + if (effects.hasOwnProperty(tag)) + arr = effects[tag]; + if (arr && index >= 0 && index < arr.length && arr[index].freqBins) + return arr[index]; + else + return null; + }; + Exps.prototype.AnalyserFreqBinCount = function (ret, tag, index) + { + tag = tag.toLowerCase(); + index = Math.floor(index); + var analyser = getAnalyser(tag, index); + ret.set_int(analyser ? analyser.node["frequencyBinCount"] : 0); + }; + Exps.prototype.AnalyserFreqBinAt = function (ret, tag, index, bin) + { + tag = tag.toLowerCase(); + index = Math.floor(index); + bin = Math.floor(bin); + var analyser = getAnalyser(tag, index); + if (!analyser) + ret.set_float(0); + else if (bin < 0 || bin >= analyser.node["frequencyBinCount"]) + ret.set_float(0); + else + ret.set_float(analyser.freqBins[bin]); + }; + Exps.prototype.AnalyserPeakLevel = function (ret, tag, index) + { + tag = tag.toLowerCase(); + index = Math.floor(index); + var analyser = getAnalyser(tag, index); + if (analyser) + ret.set_float(analyser.peak); + else + ret.set_float(0); + }; + Exps.prototype.AnalyserRMSLevel = function (ret, tag, index) + { + tag = tag.toLowerCase(); + index = Math.floor(index); + var analyser = getAnalyser(tag, index); + if (analyser) + ret.set_float(analyser.rms); + else + ret.set_float(0); + }; + Exps.prototype.SampleRate = function (ret) + { + ret.set_int(context ? context.sampleRate : 0); + }; + Exps.prototype.CurrentTime = function (ret) + { + ret.set_float(context ? context.currentTime : cr.performance_now()); + }; + pluginProto.exps = new Exps(); +}()); +; +; +cr.plugins_.Browser = function(runtime) +{ + this.runtime = runtime; +}; +(function () +{ + var pluginProto = cr.plugins_.Browser.prototype; + pluginProto.Type = function(plugin) + { + this.plugin = plugin; + this.runtime = plugin.runtime; + }; + var typeProto = pluginProto.Type.prototype; + typeProto.onCreate = function() + { + }; + var offlineScriptReady = false; + var browserPluginReady = false; + document.addEventListener("DOMContentLoaded", function () + { + if (window["C2_RegisterSW"] && navigator["serviceWorker"]) + { + var offlineClientScript = document.createElement("script"); + offlineClientScript.onload = function () + { + offlineScriptReady = true; + checkReady() + }; + offlineClientScript.src = "offlineClient.js"; + document.head.appendChild(offlineClientScript); + } + }); + var browserInstance = null; + typeProto.onAppBegin = function () + { + browserPluginReady = true; + checkReady(); + }; + function checkReady() + { + if (offlineScriptReady && browserPluginReady && window["OfflineClientInfo"]) + { + window["OfflineClientInfo"]["SetMessageCallback"](function (e) + { + browserInstance.onSWMessage(e); + }); + } + }; + pluginProto.Instance = function(type) + { + this.type = type; + this.runtime = type.runtime; + }; + var instanceProto = pluginProto.Instance.prototype; + instanceProto.onCreate = function() + { + var self = this; + window.addEventListener("resize", function () { + self.runtime.trigger(cr.plugins_.Browser.prototype.cnds.OnResize, self); + }); + browserInstance = this; + if (typeof navigator.onLine !== "undefined") + { + window.addEventListener("online", function() { + self.runtime.trigger(cr.plugins_.Browser.prototype.cnds.OnOnline, self); + }); + window.addEventListener("offline", function() { + self.runtime.trigger(cr.plugins_.Browser.prototype.cnds.OnOffline, self); + }); + } + if (!this.runtime.isDirectCanvas) + { + document.addEventListener("appMobi.device.update.available", function() { + self.runtime.trigger(cr.plugins_.Browser.prototype.cnds.OnUpdateReady, self); + }); + document.addEventListener("backbutton", function() { + self.runtime.trigger(cr.plugins_.Browser.prototype.cnds.OnBackButton, self); + }); + document.addEventListener("menubutton", function() { + self.runtime.trigger(cr.plugins_.Browser.prototype.cnds.OnMenuButton, self); + }); + document.addEventListener("searchbutton", function() { + self.runtime.trigger(cr.plugins_.Browser.prototype.cnds.OnSearchButton, self); + }); + document.addEventListener("tizenhwkey", function (e) { + var ret; + switch (e["keyName"]) { + case "back": + ret = self.runtime.trigger(cr.plugins_.Browser.prototype.cnds.OnBackButton, self); + if (!ret) + { + if (window["tizen"]) + window["tizen"]["application"]["getCurrentApplication"]()["exit"](); + } + break; + case "menu": + ret = self.runtime.trigger(cr.plugins_.Browser.prototype.cnds.OnMenuButton, self); + if (!ret) + e.preventDefault(); + break; + } + }); + } + if (this.runtime.isWindows10 && typeof Windows !== "undefined") + { + Windows["UI"]["Core"]["SystemNavigationManager"]["getForCurrentView"]().addEventListener("backrequested", function (e) + { + var ret = self.runtime.trigger(cr.plugins_.Browser.prototype.cnds.OnBackButton, self); + if (ret) + e["handled"] = true; + }); + } + else if (this.runtime.isWinJS && WinJS["Application"]) + { + WinJS["Application"]["onbackclick"] = function (e) + { + return !!self.runtime.trigger(cr.plugins_.Browser.prototype.cnds.OnBackButton, self); + }; + } + this.runtime.addSuspendCallback(function(s) { + if (s) + { + self.runtime.trigger(cr.plugins_.Browser.prototype.cnds.OnPageHidden, self); + } + else + { + self.runtime.trigger(cr.plugins_.Browser.prototype.cnds.OnPageVisible, self); + } + }); + this.is_arcade = (typeof window["is_scirra_arcade"] !== "undefined"); + }; + instanceProto.onSWMessage = function (e) + { + var messageType = e["data"]["type"]; + if (messageType === "downloading-update") + this.runtime.trigger(cr.plugins_.Browser.prototype.cnds.OnUpdateFound, this); + else if (messageType === "update-ready" || messageType === "update-pending") + this.runtime.trigger(cr.plugins_.Browser.prototype.cnds.OnUpdateReady, this); + else if (messageType === "offline-ready") + this.runtime.trigger(cr.plugins_.Browser.prototype.cnds.OnOfflineReady, this); + }; + var batteryManager = null; + var loadedBatteryManager = false; + function maybeLoadBatteryManager() + { + if (loadedBatteryManager) + return; + if (!navigator["getBattery"]) + return; + var promise = navigator["getBattery"](); + loadedBatteryManager = true; + if (promise) + { + promise.then(function (manager) { + batteryManager = manager; + }); + } + }; + function Cnds() {}; + Cnds.prototype.CookiesEnabled = function() + { + return navigator ? navigator.cookieEnabled : false; + }; + Cnds.prototype.IsOnline = function() + { + return navigator ? navigator.onLine : false; + }; + Cnds.prototype.HasJava = function() + { + return navigator ? navigator.javaEnabled() : false; + }; + Cnds.prototype.OnOnline = function() + { + return true; + }; + Cnds.prototype.OnOffline = function() + { + return true; + }; + Cnds.prototype.IsDownloadingUpdate = function () + { + return false; // deprecated + }; + Cnds.prototype.OnUpdateReady = function () + { + return true; + }; + Cnds.prototype.PageVisible = function () + { + return !this.runtime.isSuspended; + }; + Cnds.prototype.OnPageVisible = function () + { + return true; + }; + Cnds.prototype.OnPageHidden = function () + { + return true; + }; + Cnds.prototype.OnResize = function () + { + return true; + }; + Cnds.prototype.IsFullscreen = function () + { + return !!(document["mozFullScreen"] || document["webkitIsFullScreen"] || document["fullScreen"] || this.runtime.isNodeFullscreen); + }; + Cnds.prototype.OnBackButton = function () + { + return true; + }; + Cnds.prototype.OnMenuButton = function () + { + return true; + }; + Cnds.prototype.OnSearchButton = function () + { + return true; + }; + Cnds.prototype.IsMetered = function () + { + var connection = navigator["connection"] || navigator["mozConnection"] || navigator["webkitConnection"]; + if (!connection) + return false; + return !!connection["metered"]; + }; + Cnds.prototype.IsCharging = function () + { + var battery = navigator["battery"] || navigator["mozBattery"] || navigator["webkitBattery"]; + if (battery) + { + return !!battery["charging"] + } + else + { + maybeLoadBatteryManager(); + if (batteryManager) + { + return !!batteryManager["charging"]; + } + else + { + return true; // if unknown, default to charging (powered) + } + } + }; + Cnds.prototype.IsPortraitLandscape = function (p) + { + var current = (window.innerWidth <= window.innerHeight ? 0 : 1); + return current === p; + }; + Cnds.prototype.SupportsFullscreen = function () + { + if (this.runtime.isNodeWebkit) + return true; + var elem = this.runtime.canvasdiv || this.runtime.canvas; + return !!(elem["requestFullscreen"] || elem["mozRequestFullScreen"] || elem["msRequestFullscreen"] || elem["webkitRequestFullScreen"]); + }; + Cnds.prototype.OnUpdateFound = function () + { + return true; + }; + Cnds.prototype.OnUpdateReady = function () + { + return true; + }; + Cnds.prototype.OnOfflineReady = function () + { + return true; + }; + pluginProto.cnds = new Cnds(); + function Acts() {}; + Acts.prototype.Alert = function (msg) + { + if (!this.runtime.isDomFree) + alert(msg.toString()); + }; + Acts.prototype.Close = function () + { + if (this.runtime.isCocoonJs) + CocoonJS["App"]["forceToFinish"](); + else if (window["tizen"]) + window["tizen"]["application"]["getCurrentApplication"]()["exit"](); + else if (navigator["app"] && navigator["app"]["exitApp"]) + navigator["app"]["exitApp"](); + else if (navigator["device"] && navigator["device"]["exitApp"]) + navigator["device"]["exitApp"](); + else if (!this.is_arcade && !this.runtime.isDomFree) + window.close(); + }; + Acts.prototype.Focus = function () + { + if (this.runtime.isNodeWebkit) + { + var win = window["nwgui"]["Window"]["get"](); + win["focus"](); + } + else if (!this.is_arcade && !this.runtime.isDomFree) + window.focus(); + }; + Acts.prototype.Blur = function () + { + if (this.runtime.isNodeWebkit) + { + var win = window["nwgui"]["Window"]["get"](); + win["blur"](); + } + else if (!this.is_arcade && !this.runtime.isDomFree) + window.blur(); + }; + Acts.prototype.GoBack = function () + { + if (navigator["app"] && navigator["app"]["backHistory"]) + navigator["app"]["backHistory"](); + else if (!this.is_arcade && !this.runtime.isDomFree && window.back) + window.back(); + }; + Acts.prototype.GoForward = function () + { + if (!this.is_arcade && !this.runtime.isDomFree && window.forward) + window.forward(); + }; + Acts.prototype.GoHome = function () + { + if (!this.is_arcade && !this.runtime.isDomFree && window.home) + window.home(); + }; + Acts.prototype.GoToURL = function (url, target) + { + if (this.runtime.isCocoonJs) + CocoonJS["App"]["openURL"](url); + else if (this.runtime.isEjecta) + ejecta["openURL"](url); + else if (this.runtime.isWinJS) + Windows["System"]["Launcher"]["launchUriAsync"](new Windows["Foundation"]["Uri"](url)); + else if (navigator["app"] && navigator["app"]["loadUrl"]) + navigator["app"]["loadUrl"](url, { "openExternal": true }); + else if (this.runtime.isCordova) + window.open(url, "_system"); + else if (!this.is_arcade && !this.runtime.isDomFree) + { + if (target === 2 && !this.is_arcade) // top + window.top.location = url; + else if (target === 1 && !this.is_arcade) // parent + window.parent.location = url; + else // self + window.location = url; + } + }; + Acts.prototype.GoToURLWindow = function (url, tag) + { + if (this.runtime.isCocoonJs) + CocoonJS["App"]["openURL"](url); + else if (this.runtime.isEjecta) + ejecta["openURL"](url); + else if (this.runtime.isWinJS) + Windows["System"]["Launcher"]["launchUriAsync"](new Windows["Foundation"]["Uri"](url)); + else if (navigator["app"] && navigator["app"]["loadUrl"]) + navigator["app"]["loadUrl"](url, { "openExternal": true }); + else if (this.runtime.isCordova) + window.open(url, "_system"); + else if (!this.is_arcade && !this.runtime.isDomFree) + window.open(url, tag); + }; + Acts.prototype.Reload = function () + { + if (!this.is_arcade && !this.runtime.isDomFree) + window.location.reload(); + }; + var firstRequestFullscreen = true; + var crruntime = null; + function onFullscreenError(e) + { + if (console && console.warn) + console.warn("Fullscreen request failed: ", e); + crruntime["setSize"](window.innerWidth, window.innerHeight); + }; + Acts.prototype.RequestFullScreen = function (stretchmode) + { + if (this.runtime.isDomFree) + { + cr.logexport("[Construct 2] Requesting fullscreen is not supported on this platform - the request has been ignored"); + return; + } + if (stretchmode >= 2) + stretchmode += 1; + if (stretchmode === 6) + stretchmode = 2; + if (this.runtime.isNodeWebkit) + { + if (this.runtime.isDebug) + { + debuggerFullscreen(true); + } + else if (!this.runtime.isNodeFullscreen && window["nwgui"]) + { + window["nwgui"]["Window"]["get"]()["enterFullscreen"](); + this.runtime.isNodeFullscreen = true; + this.runtime.fullscreen_scaling = (stretchmode >= 2 ? stretchmode : 0); + } + } + else + { + if (document["mozFullScreen"] || document["webkitIsFullScreen"] || !!document["msFullscreenElement"] || document["fullScreen"] || document["fullScreenElement"]) + { + return; + } + this.runtime.fullscreen_scaling = (stretchmode >= 2 ? stretchmode : 0); + var elem = document.documentElement; + if (firstRequestFullscreen) + { + firstRequestFullscreen = false; + crruntime = this.runtime; + elem.addEventListener("mozfullscreenerror", onFullscreenError); + elem.addEventListener("webkitfullscreenerror", onFullscreenError); + elem.addEventListener("MSFullscreenError", onFullscreenError); + elem.addEventListener("fullscreenerror", onFullscreenError); + } + if (elem["requestFullscreen"]) + elem["requestFullscreen"](); + else if (elem["mozRequestFullScreen"]) + elem["mozRequestFullScreen"](); + else if (elem["msRequestFullscreen"]) + elem["msRequestFullscreen"](); + else if (elem["webkitRequestFullScreen"]) + { + if (typeof Element !== "undefined" && typeof Element["ALLOW_KEYBOARD_INPUT"] !== "undefined") + elem["webkitRequestFullScreen"](Element["ALLOW_KEYBOARD_INPUT"]); + else + elem["webkitRequestFullScreen"](); + } + } + }; + Acts.prototype.CancelFullScreen = function () + { + if (this.runtime.isDomFree) + { + cr.logexport("[Construct 2] Exiting fullscreen is not supported on this platform - the request has been ignored"); + return; + } + if (this.runtime.isNodeWebkit) + { + if (this.runtime.isDebug) + { + debuggerFullscreen(false); + } + else if (this.runtime.isNodeFullscreen && window["nwgui"]) + { + window["nwgui"]["Window"]["get"]()["leaveFullscreen"](); + this.runtime.isNodeFullscreen = false; + } + } + else + { + if (document["exitFullscreen"]) + document["exitFullscreen"](); + else if (document["mozCancelFullScreen"]) + document["mozCancelFullScreen"](); + else if (document["msExitFullscreen"]) + document["msExitFullscreen"](); + else if (document["webkitCancelFullScreen"]) + document["webkitCancelFullScreen"](); + } + }; + Acts.prototype.Vibrate = function (pattern_) + { + try { + var arr = pattern_.split(","); + var i, len; + for (i = 0, len = arr.length; i < len; i++) + { + arr[i] = parseInt(arr[i], 10); + } + if (navigator["vibrate"]) + navigator["vibrate"](arr); + else if (navigator["mozVibrate"]) + navigator["mozVibrate"](arr); + else if (navigator["webkitVibrate"]) + navigator["webkitVibrate"](arr); + else if (navigator["msVibrate"]) + navigator["msVibrate"](arr); + } + catch (e) {} + }; + Acts.prototype.InvokeDownload = function (url_, filename_) + { + var a = document.createElement("a"); + if (typeof a["download"] === "undefined") + { + window.open(url_); + } + else + { + var body = document.getElementsByTagName("body")[0]; + a.textContent = filename_; + a.href = url_; + a["download"] = filename_; + body.appendChild(a); + var clickEvent = new MouseEvent("click"); + a.dispatchEvent(clickEvent); + body.removeChild(a); + } + }; + Acts.prototype.InvokeDownloadString = function (str_, mimetype_, filename_) + { + var datauri = "data:" + mimetype_ + "," + encodeURIComponent(str_); + var a = document.createElement("a"); + if (typeof a["download"] === "undefined") + { + window.open(datauri); + } + else + { + var body = document.getElementsByTagName("body")[0]; + a.textContent = filename_; + a.href = datauri; + a["download"] = filename_; + body.appendChild(a); + var clickEvent = new MouseEvent("click"); + a.dispatchEvent(clickEvent); + body.removeChild(a); + } + }; + Acts.prototype.ConsoleLog = function (type_, msg_) + { + if (typeof console === "undefined") + return; + if (type_ === 0 && console.log) + console.log(msg_.toString()); + if (type_ === 1 && console.warn) + console.warn(msg_.toString()); + if (type_ === 2 && console.error) + console.error(msg_.toString()); + }; + Acts.prototype.ConsoleGroup = function (name_) + { + if (console && console.group) + console.group(name_); + }; + Acts.prototype.ConsoleGroupEnd = function () + { + if (console && console.groupEnd) + console.groupEnd(); + }; + Acts.prototype.ExecJs = function (js_) + { + try { + if (eval) + eval(js_); + } + catch (e) + { + if (console && console.error) + console.error("Error executing Javascript: ", e); + } + }; + var orientations = [ + "portrait", + "landscape", + "portrait-primary", + "portrait-secondary", + "landscape-primary", + "landscape-secondary" + ]; + Acts.prototype.LockOrientation = function (o) + { + o = Math.floor(o); + if (o < 0 || o >= orientations.length) + return; + this.runtime.autoLockOrientation = false; + var orientation = orientations[o]; + if (screen["orientation"] && screen["orientation"]["lock"]) + screen["orientation"]["lock"](orientation); + else if (screen["lockOrientation"]) + screen["lockOrientation"](orientation); + else if (screen["webkitLockOrientation"]) + screen["webkitLockOrientation"](orientation); + else if (screen["mozLockOrientation"]) + screen["mozLockOrientation"](orientation); + else if (screen["msLockOrientation"]) + screen["msLockOrientation"](orientation); + }; + Acts.prototype.UnlockOrientation = function () + { + this.runtime.autoLockOrientation = false; + if (screen["orientation"] && screen["orientation"]["unlock"]) + screen["orientation"]["unlock"](); + else if (screen["unlockOrientation"]) + screen["unlockOrientation"](); + else if (screen["webkitUnlockOrientation"]) + screen["webkitUnlockOrientation"](); + else if (screen["mozUnlockOrientation"]) + screen["mozUnlockOrientation"](); + else if (screen["msUnlockOrientation"]) + screen["msUnlockOrientation"](); + }; + pluginProto.acts = new Acts(); + function Exps() {}; + Exps.prototype.URL = function (ret) + { + ret.set_string(this.runtime.isDomFree ? "" : window.location.toString()); + }; + Exps.prototype.Protocol = function (ret) + { + ret.set_string(this.runtime.isDomFree ? "" : window.location.protocol); + }; + Exps.prototype.Domain = function (ret) + { + ret.set_string(this.runtime.isDomFree ? "" : window.location.hostname); + }; + Exps.prototype.PathName = function (ret) + { + ret.set_string(this.runtime.isDomFree ? "" : window.location.pathname); + }; + Exps.prototype.Hash = function (ret) + { + ret.set_string(this.runtime.isDomFree ? "" : window.location.hash); + }; + Exps.prototype.Referrer = function (ret) + { + ret.set_string(this.runtime.isDomFree ? "" : document.referrer); + }; + Exps.prototype.Title = function (ret) + { + ret.set_string(this.runtime.isDomFree ? "" : document.title); + }; + Exps.prototype.Name = function (ret) + { + ret.set_string(this.runtime.isDomFree ? "" : navigator.appName); + }; + Exps.prototype.Version = function (ret) + { + ret.set_string(this.runtime.isDomFree ? "" : navigator.appVersion); + }; + Exps.prototype.Language = function (ret) + { + if (navigator && navigator.language) + ret.set_string(navigator.language); + else + ret.set_string(""); + }; + Exps.prototype.Platform = function (ret) + { + ret.set_string(this.runtime.isDomFree ? "" : navigator.platform); + }; + Exps.prototype.Product = function (ret) + { + if (navigator && navigator.product) + ret.set_string(navigator.product); + else + ret.set_string(""); + }; + Exps.prototype.Vendor = function (ret) + { + if (navigator && navigator.vendor) + ret.set_string(navigator.vendor); + else + ret.set_string(""); + }; + Exps.prototype.UserAgent = function (ret) + { + ret.set_string(this.runtime.isDomFree ? "" : navigator.userAgent); + }; + Exps.prototype.QueryString = function (ret) + { + ret.set_string(this.runtime.isDomFree ? "" : window.location.search); + }; + Exps.prototype.QueryParam = function (ret, paramname) + { + if (this.runtime.isDomFree) + { + ret.set_string(""); + return; + } + var match = RegExp('[?&]' + paramname + '=([^&]*)').exec(window.location.search); + if (match) + ret.set_string(decodeURIComponent(match[1].replace(/\+/g, ' '))); + else + ret.set_string(""); + }; + Exps.prototype.Bandwidth = function (ret) + { + var connection = navigator["connection"] || navigator["mozConnection"] || navigator["webkitConnection"]; + if (!connection) + ret.set_float(Number.POSITIVE_INFINITY); + else + { + if (typeof connection["bandwidth"] !== "undefined") + ret.set_float(connection["bandwidth"]); + else if (typeof connection["downlinkMax"] !== "undefined") + ret.set_float(connection["downlinkMax"]); + else + ret.set_float(Number.POSITIVE_INFINITY); + } + }; + Exps.prototype.ConnectionType = function (ret) + { + var connection = navigator["connection"] || navigator["mozConnection"] || navigator["webkitConnection"]; + if (!connection) + ret.set_string("unknown"); + else + { + ret.set_string(connection["type"] || "unknown"); + } + }; + Exps.prototype.BatteryLevel = function (ret) + { + var battery = navigator["battery"] || navigator["mozBattery"] || navigator["webkitBattery"]; + if (battery) + { + ret.set_float(battery["level"]); + } + else + { + maybeLoadBatteryManager(); + if (batteryManager) + { + ret.set_float(batteryManager["level"]); + } + else + { + ret.set_float(1); // not supported/unknown: assume charged + } + } + }; + Exps.prototype.BatteryTimeLeft = function (ret) + { + var battery = navigator["battery"] || navigator["mozBattery"] || navigator["webkitBattery"]; + if (battery) + { + ret.set_float(battery["dischargingTime"]); + } + else + { + maybeLoadBatteryManager(); + if (batteryManager) + { + ret.set_float(batteryManager["dischargingTime"]); + } + else + { + ret.set_float(Number.POSITIVE_INFINITY); // not supported/unknown: assume infinite time left + } + } + }; + Exps.prototype.ExecJS = function (ret, js_) + { + if (!eval) + { + ret.set_any(0); + return; + } + var result = 0; + try { + result = eval(js_); + } + catch (e) + { + if (console && console.error) + console.error("Error executing Javascript: ", e); + } + if (typeof result === "number") + ret.set_any(result); + else if (typeof result === "string") + ret.set_any(result); + else if (typeof result === "boolean") + ret.set_any(result ? 1 : 0); + else + ret.set_any(0); + }; + Exps.prototype.ScreenWidth = function (ret) + { + ret.set_int(screen.width); + }; + Exps.prototype.ScreenHeight = function (ret) + { + ret.set_int(screen.height); + }; + Exps.prototype.DevicePixelRatio = function (ret) + { + ret.set_float(this.runtime.devicePixelRatio); + }; + Exps.prototype.WindowInnerWidth = function (ret) + { + ret.set_int(window.innerWidth); + }; + Exps.prototype.WindowInnerHeight = function (ret) + { + ret.set_int(window.innerHeight); + }; + Exps.prototype.WindowOuterWidth = function (ret) + { + ret.set_int(window.outerWidth); + }; + Exps.prototype.WindowOuterHeight = function (ret) + { + ret.set_int(window.outerHeight); + }; + pluginProto.exps = new Exps(); +}()); +; +; +cr.plugins_.Dictionary = function(runtime) +{ + this.runtime = runtime; +}; +(function () +{ + var pluginProto = cr.plugins_.Dictionary.prototype; + pluginProto.Type = function(plugin) + { + this.plugin = plugin; + this.runtime = plugin.runtime; + }; + var typeProto = pluginProto.Type.prototype; + typeProto.onCreate = function() + { + }; + pluginProto.Instance = function(type) + { + this.type = type; + this.runtime = type.runtime; + }; + var instanceProto = pluginProto.Instance.prototype; + instanceProto.onCreate = function() + { + this.dictionary = {}; + this.cur_key = ""; // current key in for-each loop + this.key_count = 0; + }; + instanceProto.saveToJSON = function () + { + return this.dictionary; + }; + instanceProto.loadFromJSON = function (o) + { + this.dictionary = o; + this.key_count = 0; + for (var p in this.dictionary) + { + if (this.dictionary.hasOwnProperty(p)) + this.key_count++; + } + }; + function Cnds() {}; + Cnds.prototype.CompareValue = function (key_, cmp_, value_) + { + return cr.do_cmp(this.dictionary[key_], cmp_, value_); + }; + Cnds.prototype.ForEachKey = function () + { + var current_event = this.runtime.getCurrentEventStack().current_event; + for (var p in this.dictionary) + { + if (this.dictionary.hasOwnProperty(p)) + { + this.cur_key = p; + this.runtime.pushCopySol(current_event.solModifiers); + current_event.retrigger(); + this.runtime.popSol(current_event.solModifiers); + } + } + this.cur_key = ""; + return false; + }; + Cnds.prototype.CompareCurrentValue = function (cmp_, value_) + { + return cr.do_cmp(this.dictionary[this.cur_key], cmp_, value_); + }; + Cnds.prototype.HasKey = function (key_) + { + return this.dictionary.hasOwnProperty(key_); + }; + Cnds.prototype.IsEmpty = function () + { + return this.key_count === 0; + }; + pluginProto.cnds = new Cnds(); + function Acts() {}; + Acts.prototype.AddKey = function (key_, value_) + { + if (!this.dictionary.hasOwnProperty(key_)) + this.key_count++; + this.dictionary[key_] = value_; + }; + Acts.prototype.SetKey = function (key_, value_) + { + if (this.dictionary.hasOwnProperty(key_)) + this.dictionary[key_] = value_; + }; + Acts.prototype.DeleteKey = function (key_) + { + if (this.dictionary.hasOwnProperty(key_)) + { + delete this.dictionary[key_]; + this.key_count--; + } + }; + Acts.prototype.Clear = function () + { + cr.wipe(this.dictionary); // avoid garbaging + this.key_count = 0; + }; + Acts.prototype.JSONLoad = function (json_) + { + var o; + try { + o = JSON.parse(json_); + } + catch(e) { return; } + if (!o["c2dictionary"]) // presumably not a c2dictionary object + return; + this.dictionary = o["data"]; + this.key_count = 0; + for (var p in this.dictionary) + { + if (this.dictionary.hasOwnProperty(p)) + this.key_count++; + } + }; + Acts.prototype.JSONDownload = function (filename) + { + var a = document.createElement("a"); + if (typeof a.download === "undefined") + { + var str = 'data:text/html,' + encodeURIComponent("

Download link

"); + window.open(str); + } + else + { + var body = document.getElementsByTagName("body")[0]; + a.textContent = filename; + a.href = "data:application/json," + encodeURIComponent(JSON.stringify({ + "c2dictionary": true, + "data": this.dictionary + })); + a.download = filename; + body.appendChild(a); + var clickEvent = document.createEvent("MouseEvent"); + clickEvent.initMouseEvent("click", true, true, window, 0, 0, 0, 0, 0, false, false, false, false, 0, null); + a.dispatchEvent(clickEvent); + body.removeChild(a); + } + }; + pluginProto.acts = new Acts(); + function Exps() {}; + Exps.prototype.Get = function (ret, key_) + { + if (this.dictionary.hasOwnProperty(key_)) + ret.set_any(this.dictionary[key_]); + else + ret.set_int(0); + }; + Exps.prototype.KeyCount = function (ret) + { + ret.set_int(this.key_count); + }; + Exps.prototype.CurrentKey = function (ret) + { + ret.set_string(this.cur_key); + }; + Exps.prototype.CurrentValue = function (ret) + { + if (this.dictionary.hasOwnProperty(this.cur_key)) + ret.set_any(this.dictionary[this.cur_key]); + else + ret.set_int(0); + }; + Exps.prototype.AsJSON = function (ret) + { + ret.set_string(JSON.stringify({ + "c2dictionary": true, + "data": this.dictionary + })); + }; + pluginProto.exps = new Exps(); +}()); +; +; +cr.plugins_.Function = function(runtime) +{ + this.runtime = runtime; +}; +(function () +{ + var pluginProto = cr.plugins_.Function.prototype; + pluginProto.Type = function(plugin) + { + this.plugin = plugin; + this.runtime = plugin.runtime; + }; + var typeProto = pluginProto.Type.prototype; + typeProto.onCreate = function() + { + }; + pluginProto.Instance = function(type) + { + this.type = type; + this.runtime = type.runtime; + }; + var instanceProto = pluginProto.Instance.prototype; + var funcStack = []; + var funcStackPtr = -1; + var isInPreview = false; // set in onCreate + function FuncStackEntry() + { + this.name = ""; + this.retVal = 0; + this.params = []; + }; + function pushFuncStack() + { + funcStackPtr++; + if (funcStackPtr === funcStack.length) + funcStack.push(new FuncStackEntry()); + return funcStack[funcStackPtr]; + }; + function getCurrentFuncStack() + { + if (funcStackPtr < 0) + return null; + return funcStack[funcStackPtr]; + }; + function getOneAboveFuncStack() + { + if (!funcStack.length) + return null; + var i = funcStackPtr + 1; + if (i >= funcStack.length) + i = funcStack.length - 1; + return funcStack[i]; + }; + function popFuncStack() + { +; + funcStackPtr--; + }; + instanceProto.onCreate = function() + { + isInPreview = (typeof cr_is_preview !== "undefined"); + var self = this; + window["c2_callFunction"] = function (name_, params_) + { + var i, len, v; + var fs = pushFuncStack(); + fs.name = name_.toLowerCase(); + fs.retVal = 0; + if (params_) + { + fs.params.length = params_.length; + for (i = 0, len = params_.length; i < len; ++i) + { + v = params_[i]; + if (typeof v === "number" || typeof v === "string") + fs.params[i] = v; + else if (typeof v === "boolean") + fs.params[i] = (v ? 1 : 0); + else + fs.params[i] = 0; + } + } + else + { + cr.clearArray(fs.params); + } + self.runtime.trigger(cr.plugins_.Function.prototype.cnds.OnFunction, self, fs.name); + popFuncStack(); + return fs.retVal; + }; + }; + function Cnds() {}; + Cnds.prototype.OnFunction = function (name_) + { + var fs = getCurrentFuncStack(); + if (!fs) + return false; + return cr.equals_nocase(name_, fs.name); + }; + Cnds.prototype.CompareParam = function (index_, cmp_, value_) + { + var fs = getCurrentFuncStack(); + if (!fs) + return false; + index_ = cr.floor(index_); + if (index_ < 0 || index_ >= fs.params.length) + return false; + return cr.do_cmp(fs.params[index_], cmp_, value_); + }; + pluginProto.cnds = new Cnds(); + function Acts() {}; + Acts.prototype.CallFunction = function (name_, params_) + { + var fs = pushFuncStack(); + fs.name = name_.toLowerCase(); + fs.retVal = 0; + cr.shallowAssignArray(fs.params, params_); + var ran = this.runtime.trigger(cr.plugins_.Function.prototype.cnds.OnFunction, this, fs.name); + if (isInPreview && !ran) + { +; + } + popFuncStack(); + }; + Acts.prototype.SetReturnValue = function (value_) + { + var fs = getCurrentFuncStack(); + if (fs) + fs.retVal = value_; + else +; + }; + Acts.prototype.CallExpression = function (unused) + { + }; + pluginProto.acts = new Acts(); + function Exps() {}; + Exps.prototype.ReturnValue = function (ret) + { + var fs = getOneAboveFuncStack(); + if (fs) + ret.set_any(fs.retVal); + else + ret.set_int(0); + }; + Exps.prototype.ParamCount = function (ret) + { + var fs = getCurrentFuncStack(); + if (fs) + ret.set_int(fs.params.length); + else + { +; + ret.set_int(0); + } + }; + Exps.prototype.Param = function (ret, index_) + { + index_ = cr.floor(index_); + var fs = getCurrentFuncStack(); + if (fs) + { + if (index_ >= 0 && index_ < fs.params.length) + { + ret.set_any(fs.params[index_]); + } + else + { +; + ret.set_int(0); + } + } + else + { +; + ret.set_int(0); + } + }; + Exps.prototype.Call = function (ret, name_) + { + var fs = pushFuncStack(); + fs.name = name_.toLowerCase(); + fs.retVal = 0; + cr.clearArray(fs.params); + var i, len; + for (i = 2, len = arguments.length; i < len; i++) + fs.params.push(arguments[i]); + var ran = this.runtime.trigger(cr.plugins_.Function.prototype.cnds.OnFunction, this, fs.name); + if (isInPreview && !ran) + { +; + } + popFuncStack(); + ret.set_any(fs.retVal); + }; + pluginProto.exps = new Exps(); +}()); +; +; +cr.plugins_.IDNet = function(runtime) { + this.runtime = runtime; +}; +(function() { + var pluginProto = cr.plugins_.IDNet.prototype; + pluginProto.Type = function(plugin) { + this.plugin = plugin; + this.runtime = plugin.runtime; + }; + var typeProto = pluginProto.Type.prototype; + var _document = null; + var _unsafeWindow = null; + var idNetRuntime = null; + var idNetInst = null; + var idnetUserName = "Guest"; + var authorized = false; + var userAuthorized = false; + var idnetSessionKey = ""; + var onlineSavesData = ""; + var isBlacklisted = 0; + var isSponsor = 0; + var gotSaveData = 0; + var gameBreakVisible = 1; + typeProto.onCreate = function() { + }; + pluginProto.Instance = function(type) { + this.type = type; + this.runtime = type.runtime; + idNetRuntime = this.runtime; + idNetInst = this; + this._document = window.document; + this._unsafeWindow = this._document.defaultView; + }; + function ShowLeaderBoardCallback(response) { + } + var instanceProto = pluginProto.Instance.prototype; + instanceProto.onCreate = function() + { + }; + instanceProto.onDestroy = function () + { + }; + instanceProto.draw = function(ctx) + { + }; + instanceProto.drawGL = function (glw) + { + }; + function Cnds() {}; + Cnds.prototype.isAuthorized = function () { + return idNetInst.authorized; + }; + Cnds.prototype.isNotAuthorized = function () { + return !idNetInst.authorized; + }; + Cnds.prototype.UserIsAuthorized = function () { + return idNetInst.userAuthorized; + }; + Cnds.prototype.UserIsNotAuthorized = function () { + return !idNetInst.userAuthorized; + }; + Cnds.prototype.blacklisted = function () { + return idNetInst.isBlacklisted; + }; + Cnds.prototype.sponsored = function () { + return idNetInst.isSponsor; + }; + Cnds.prototype.dataReady = function () { + if (idNetInst.gotSaveData === 1) { + idNetInst.gotSaveData = 0; + return 1; + } + }; + Cnds.prototype.menuVisible = function() { + if (window.ID && ID.isVisible()) { + return 1; + } + }; + Cnds.prototype.gameBreakVisible = function() { + return idNetInst.gameBreakVisible; + }; + pluginProto.cnds = new Cnds(); + function Acts() {}; + Acts.prototype.Inititalize = function(appid_) { + console.log('init with appid ' + appid_); + (function(d, s, id){ + var js, fjs = d.getElementsByTagName(s)[0]; + if (d.getElementById(id)) {return;} + js = d.createElement(s); js.id = id; + js.src = document.location.protocol == 'https:' ? "https://cdn.y8.com/api/sdk.js" : "http://cdn.y8.com/api/sdk.js"; + fjs.parentNode.insertBefore(js, fjs); + }(document, 'script', 'id-jssdk')); + window.idAsyncInit = function() { + ID.Event.subscribe("id.init",function() { + window.idnet_autologin = function(response) { + if (response != null && response.user != null) { + console.log("Y8 autologin"); + idNetInst.idnetUserName = response.user.nickname; + idNetInst.userAuthorized = true; + ID.getLoginStatus(function(data) { + if (data.status == 'not_linked') { + ID.login(); + } + }); + } + } + var fjs = document.head.getElementsByTagName('meta')[0]; + if (document.getElementById('id-autologin')) { + var js_auto = document.getElementById('id-autologin'); + } else { + var js_auto = document.createElement('script'); + js_auto.id = 'id-autologin'; + js_auto.src = "https://account.y8.com/api/user_data/autologin?app_id=" + appid_ + "&callback=window.idnet_autologin"; + fjs.parentNode.insertBefore(js_auto, fjs); + } + console.log("Y8 initialized"); + ID.Protection.isBlacklisted(function(blacklisted) { + idNetInst.isBlacklisted = blacklisted; + }); + ID.Protection.isSponsor(function(sponsor) { + idNetInst.isSponsor = sponsor; + }); + }); + ID.init({ + appId : appid_ + }); + idNetInst.authorized = true; + } + }; + Acts.prototype.RegisterPopup = function() { + console.log("open registration menu"); + if (idNetInst.authorized) + ID.register(function (response) { + if(response == null) { + } else { + console.log("Registration complete"); + idNetInst.idnetUserName = response.authResponse.details.nickname; + idNetInst.userAuthorized = true; + } + }); + }; + Acts.prototype.LoginPopup = function() { + console.log("open login menu"); + if (idNetInst.authorized){ + ID.login(function (response) { + if(response == null) { + } else { + console.log("Login complete"); + idNetInst.idnetUserName = response.authResponse.details.nickname; + idNetInst.userAuthorized = true; + } + }); + } + }; + Acts.prototype.ShowLeaderBoard = function(table, mode, highest, allowduplicates) { + if (idNetInst.authorized) { + console.log('oi') + var options = { table: table, mode: mode, highest: !!highest, allowduplicates: !!allowduplicates }; + ID.GameAPI.Leaderboards.list(options); + } + }; + Acts.prototype.SubmitScore = function(score, table, allowduplicates, highest, playername) { + if (idNetInst.authorized) { + var score = { + table: table, + points: score, + allowduplicates: !!allowduplicates, + highest: !!highest, + playername: playername || idNetInst.idnetUserName + }; + ID.GameAPI.Leaderboards.save(score, function(response) { + console.log("score submitted", response); + }); + } + }; + Acts.prototype.SubmitProfileImage = function(image_) { + if (idNetInst.authorized) + ID.submit_image(image_, function(response){ + console.log("screenshot submitted", response); + }); + }; + Acts.prototype.AchievementSave = function(achievementTitle_, achievementKey_, overwrite_, allowduplicates_) { + if (idNetInst.authorized) { + var achievementData = { + achievement: achievementTitle_, + achievementkey: achievementKey_, + overwrite: overwrite_, + allowduplicates: allowduplicates_ + }; + ID.GameAPI.Achievements.save(achievementData, function(response) { + console.log("achievement saved", response); + }); + } + }; + Acts.prototype.ShowAchievements = function() { + if (idNetInst.authorized) { + ID.GameAPI.Achievements.list(); + } + }; + Acts.prototype.OnlineSavesSave = function(key_, value_) { + if (idNetInst.authorized) { + ID.api('user_data/submit', 'POST', {key: key_, value: value_}, function(response) { + console.log("save submitted", response); + }); + } + }; + Acts.prototype.OnlineSavesRemove = function(key_) { + if (idNetInst.authorized) { + ID.api('user_data/remove', 'POST', {key: key_}, function(response) { + console.log("save deleted", response); + }); + } + }; + Acts.prototype.OnlineSavesLoad = function(key_) { + if (idNetInst.authorized) { + ID.api('user_data/retrieve', 'POST', {key: key_}, function(response) { + if(response) { + idNetInst.onlineSavesData = response.jsondata; + idNetInst.gotSaveData = 1; + console.log("save loaded", response); + } + }); + } + }; + Acts.prototype.CheckIsBlacklisted = function () { + ID.Protection.isBlacklisted(function(blacklisted){ + console.log("check blacklist called", blacklisted); + idNetInst.isBlacklisted = blacklisted; + }); + }; + Acts.prototype.CheckIsSponsor = function () { + ID.Protection.isSponsor(function(sponsor){ + console.log("check sponser called", sponser); + idNetInst.isSponsor = sponsor; + }); + }; + Acts.prototype.openProfile = function () { + ID.openProfile(); + }; + Acts.prototype.gameBreak = function () { + idNetInst.gameBreakVisible = 1; + ID.gameBreak(function() { + idNetInst.gameBreakVisible = 0; + }); + }; + pluginProto.acts = new Acts(); + function Exps() {}; + Exps.prototype.UserName = function(ret) { + if(idNetInst.idnetUserName != undefined) { + ret.set_string(idNetInst.idnetUserName); + } + }; + Exps.prototype.SessionKey = function(ret) { + if(idnetSessionKey != undefined) { + ret.set_string(idnetSessionKey); + } + }; + Exps.prototype.GateOnlineSavesData = function (ret) { + ret.set_string(String(idNetInst.onlineSavesData)); + }; + Exps.prototype.GetIsBlacklisted = function(ret) { + if(idNetInst.isBlacklisted) { + ret.set_int(1); + } else { + ret.set_int(0); + } + }; + Exps.prototype.GetIsSponsor = function(ret) { + if(idNetInst.isSponsor) { + ret.set_int(1); + } else { + ret.set_int(0); + } + }; + pluginProto.exps = new Exps(); +}()); +; +; +var localForageInitFailed = false; +try { +/*! + localForage -- Offline Storage, Improved + Version 1.4.0 + https://mozilla.github.io/localForage + (c) 2013-2015 Mozilla, Apache License 2.0 +*/ +!function(){var a,b,c,d;!function(){var e={},f={};a=function(a,b,c){e[a]={deps:b,callback:c}},d=c=b=function(a){function c(b){if("."!==b.charAt(0))return b;for(var c=b.split("/"),d=a.split("/").slice(0,-1),e=0,f=c.length;f>e;e++){var g=c[e];if(".."===g)d.pop();else{if("."===g)continue;d.push(g)}}return d.join("/")}if(d._eak_seen=e,f[a])return f[a];if(f[a]={},!e[a])throw new Error("Could not find module "+a);for(var g,h=e[a],i=h.deps,j=h.callback,k=[],l=0,m=i.length;m>l;l++)"exports"===i[l]?k.push(g={}):k.push(b(c(i[l])));var n=j.apply(this,k);return f[a]=g||n}}(),a("promise/all",["./utils","exports"],function(a,b){"use strict";function c(a){var b=this;if(!d(a))throw new TypeError("You must pass an array to all.");return new b(function(b,c){function d(a){return function(b){f(a,b)}}function f(a,c){h[a]=c,0===--i&&b(h)}var g,h=[],i=a.length;0===i&&b([]);for(var j=0;jc;c++){var e=a[c];this.supports(e)&&b.push(e)}return b},a.prototype._wrapLibraryMethodsWithReady=function(){for(var a=0;ae;e++)d[e]=a.charCodeAt(e);return c}function d(a){return new Promise(function(b,c){var d=new XMLHttpRequest;d.open("GET",a),d.withCredentials=!0,d.responseType="arraybuffer",d.onreadystatechange=function(){return 4===d.readyState?200===d.status?b({response:d.response,type:d.getResponseHeader("Content-Type")}):void c({status:d.status,response:d.response}):void 0},d.send()})}function e(a){return new Promise(function(c,e){var f=b([""],{type:"image/png"}),g=a.transaction([D],"readwrite");g.objectStore(D).put(f,"key"),g.oncomplete=function(){var b=a.transaction([D],"readwrite"),f=b.objectStore(D).get("key");f.onerror=e,f.onsuccess=function(a){var b=a.target.result,e=URL.createObjectURL(b);d(e).then(function(a){c(!(!a||"image/png"!==a.type))},function(){c(!1)}).then(function(){URL.revokeObjectURL(e)})}},g.onerror=g.onabort=e})["catch"](function(){return!1})}function f(a){return"boolean"==typeof B?Promise.resolve(B):e(a).then(function(a){return B=a})}function g(a){return new Promise(function(b,c){var d=new FileReader;d.onerror=c,d.onloadend=function(c){var d=btoa(c.target.result||"");b({__local_forage_encoded_blob:!0,data:d,type:a.type})},d.readAsBinaryString(a)})}function h(a){var d=c(atob(a.data));return b([d],{type:a.type})}function i(a){return a&&a.__local_forage_encoded_blob}function j(a){var b=this,c=b._initReady().then(function(){var a=C[b._dbInfo.name];return a&&a.dbReady?a.dbReady:void 0});return c.then(a,a),c}function k(a){var b=C[a.name],c={};c.promise=new Promise(function(a){c.resolve=a}),b.deferredOperations.push(c),b.dbReady?b.dbReady=b.dbReady.then(function(){return c.promise}):b.dbReady=c.promise}function l(a){var b=C[a.name],c=b.deferredOperations.pop();c&&c.resolve()}function m(a){function b(){return Promise.resolve()}var c=this,d={db:null};if(a)for(var e in a)d[e]=a[e];C||(C={});var f=C[d.name];f||(f={forages:[],db:null,dbReady:null,deferredOperations:[]},C[d.name]=f),f.forages.push(c),c._initReady||(c._initReady=c.ready,c.ready=j);for(var g=[],h=0;hb.db.version;if(e&&(b.version!==c&&a.console.warn('The database "'+b.name+"\" can't be downgraded from version "+b.db.version+" to version "+b.version+"."),b.version=b.db.version),f||d){if(d){var g=b.db.version+1;g>b.version&&(b.version=g)}return!0}return!1}function r(b,c){var d=this;"string"!=typeof b&&(a.console.warn(b+" used as a key, but it is not a string."),b=String(b));var e=new Promise(function(a,c){d.ready().then(function(){var e=d._dbInfo,f=e.db.transaction(e.storeName,"readonly").objectStore(e.storeName),g=f.get(b);g.onsuccess=function(){var b=g.result;void 0===b&&(b=null),i(b)&&(b=h(b)),a(b)},g.onerror=function(){c(g.error)}})["catch"](c)});return z(e,c),e}function s(a,b){var c=this,d=new Promise(function(b,d){c.ready().then(function(){var e=c._dbInfo,f=e.db.transaction(e.storeName,"readonly").objectStore(e.storeName),g=f.openCursor(),j=1;g.onsuccess=function(){var c=g.result;if(c){var d=c.value;i(d)&&(d=h(d));var e=a(d,c.key,j++);void 0!==e?b(e):c["continue"]()}else b()},g.onerror=function(){d(g.error)}})["catch"](d)});return z(d,b),d}function t(b,c,d){var e=this;"string"!=typeof b&&(a.console.warn(b+" used as a key, but it is not a string."),b=String(b));var h=new Promise(function(a,d){var h;e.ready().then(function(){return h=e._dbInfo,c instanceof Blob?f(h.db).then(function(a){return a?c:g(c)}):c}).then(function(c){var e=h.db.transaction(h.storeName,"readwrite"),f=e.objectStore(h.storeName);null===c&&(c=void 0),e.oncomplete=function(){void 0===c&&(c=null),a(c)},e.onabort=e.onerror=function(){var a=g.error?g.error:g.transaction.error;d(a)};var g=f.put(c,b)})["catch"](d)});return z(h,d),h}function u(b,c){var d=this;"string"!=typeof b&&(a.console.warn(b+" used as a key, but it is not a string."),b=String(b));var e=new Promise(function(a,c){d.ready().then(function(){var e=d._dbInfo,f=e.db.transaction(e.storeName,"readwrite"),g=f.objectStore(e.storeName),h=g["delete"](b);f.oncomplete=function(){a()},f.onerror=function(){c(h.error)},f.onabort=function(){var a=h.error?h.error:h.transaction.error;c(a)}})["catch"](c)});return z(e,c),e}function v(a){var b=this,c=new Promise(function(a,c){b.ready().then(function(){var d=b._dbInfo,e=d.db.transaction(d.storeName,"readwrite"),f=e.objectStore(d.storeName),g=f.clear();e.oncomplete=function(){a()},e.onabort=e.onerror=function(){var a=g.error?g.error:g.transaction.error;c(a)}})["catch"](c)});return z(c,a),c}function w(a){var b=this,c=new Promise(function(a,c){b.ready().then(function(){var d=b._dbInfo,e=d.db.transaction(d.storeName,"readonly").objectStore(d.storeName),f=e.count();f.onsuccess=function(){a(f.result)},f.onerror=function(){c(f.error)}})["catch"](c)});return z(c,a),c}function x(a,b){var c=this,d=new Promise(function(b,d){return 0>a?void b(null):void c.ready().then(function(){var e=c._dbInfo,f=e.db.transaction(e.storeName,"readonly").objectStore(e.storeName),g=!1,h=f.openCursor();h.onsuccess=function(){var c=h.result;return c?void(0===a?b(c.key):g?b(c.key):(g=!0,c.advance(a))):void b(null)},h.onerror=function(){d(h.error)}})["catch"](d)});return z(d,b),d}function y(a){var b=this,c=new Promise(function(a,c){b.ready().then(function(){var d=b._dbInfo,e=d.db.transaction(d.storeName,"readonly").objectStore(d.storeName),f=e.openCursor(),g=[];f.onsuccess=function(){var b=f.result;return b?(g.push(b.key),void b["continue"]()):void a(g)},f.onerror=function(){c(f.error)}})["catch"](c)});return z(c,a),c}function z(a,b){b&&a.then(function(a){b(null,a)},function(a){b(a)})}var A=A||a.indexedDB||a.webkitIndexedDB||a.mozIndexedDB||a.OIndexedDB||a.msIndexedDB;if(A){var B,C,D="local-forage-detect-blob-support",E={_driver:"asyncStorage",_initStorage:m,iterate:s,getItem:r,setItem:t,removeItem:u,clear:v,length:w,key:x,keys:y};return E}}("undefined"!=typeof window?window:self);b["default"]=c,a.exports=b["default"]},function(a,b,c){"use strict";b.__esModule=!0;var d=function(a){function b(a){var b=this,d={};if(a)for(var e in a)d[e]=a[e];return d.keyPrefix=d.name+"/",d.storeName!==b._defaultConfig.storeName&&(d.keyPrefix+=d.storeName+"/"),b._dbInfo=d,new Promise(function(a,b){a(c(3))}).then(function(a){return d.serializer=a,Promise.resolve()})}function d(a){var b=this,c=b.ready().then(function(){for(var a=b._dbInfo.keyPrefix,c=m.length-1;c>=0;c--){var d=m.key(c);0===d.indexOf(a)&&m.removeItem(d)}});return l(c,a),c}function e(b,c){var d=this;"string"!=typeof b&&(a.console.warn(b+" used as a key, but it is not a string."),b=String(b));var e=d.ready().then(function(){var a=d._dbInfo,c=m.getItem(a.keyPrefix+b);return c&&(c=a.serializer.deserialize(c)),c});return l(e,c),e}function f(a,b){var c=this,d=c.ready().then(function(){for(var b=c._dbInfo,d=b.keyPrefix,e=d.length,f=m.length,g=1,h=0;f>h;h++){var i=m.key(h);if(0===i.indexOf(d)){var j=m.getItem(i);if(j&&(j=b.serializer.deserialize(j)),j=a(j,i.substring(e),g++),void 0!==j)return j}}});return l(d,b),d}function g(a,b){var c=this,d=c.ready().then(function(){var b,d=c._dbInfo;try{b=m.key(a)}catch(e){b=null}return b&&(b=b.substring(d.keyPrefix.length)),b});return l(d,b),d}function h(a){var b=this,c=b.ready().then(function(){for(var a=b._dbInfo,c=m.length,d=[],e=0;c>e;e++)0===m.key(e).indexOf(a.keyPrefix)&&d.push(m.key(e).substring(a.keyPrefix.length));return d});return l(c,a),c}function i(a){var b=this,c=b.keys().then(function(a){return a.length});return l(c,a),c}function j(b,c){var d=this;"string"!=typeof b&&(a.console.warn(b+" used as a key, but it is not a string."),b=String(b));var e=d.ready().then(function(){var a=d._dbInfo;m.removeItem(a.keyPrefix+b)});return l(e,c),e}function k(b,c,d){var e=this;"string"!=typeof b&&(a.console.warn(b+" used as a key, but it is not a string."),b=String(b));var f=e.ready().then(function(){void 0===c&&(c=null);var a=c;return new Promise(function(d,f){var g=e._dbInfo;g.serializer.serialize(c,function(c,e){if(e)f(e);else try{m.setItem(g.keyPrefix+b,c),d(a)}catch(h){("QuotaExceededError"===h.name||"NS_ERROR_DOM_QUOTA_REACHED"===h.name)&&f(h),f(h)}})})});return l(f,d),f}function l(a,b){b&&a.then(function(a){b(null,a)},function(a){b(a)})}var m=null;try{if(!(a.localStorage&&"setItem"in a.localStorage))return;m=a.localStorage}catch(n){return}var o={_driver:"localStorageWrapper",_initStorage:b,iterate:f,getItem:e,setItem:k,removeItem:j,clear:d,length:i,key:g,keys:h};return o}("undefined"!=typeof window?window:self);b["default"]=d,a.exports=b["default"]},function(a,b){"use strict";b.__esModule=!0;var c=function(a){function b(b,c){b=b||[],c=c||{};try{return new Blob(b,c)}catch(d){if("TypeError"!==d.name)throw d;for(var e=a.BlobBuilder||a.MSBlobBuilder||a.MozBlobBuilder||a.WebKitBlobBuilder,f=new e,g=0;gb;b+=4)c=g.indexOf(a[b]),d=g.indexOf(a[b+1]),e=g.indexOf(a[b+2]),f=g.indexOf(a[b+3]),l[j++]=c<<2|d>>4,l[j++]=(15&d)<<4|e>>2,l[j++]=(3&e)<<6|63&f;return k}function f(a){var b,c=new Uint8Array(a),d="";for(b=0;b>2],d+=g[(3&c[b])<<4|c[b+1]>>4],d+=g[(15&c[b+1])<<2|c[b+2]>>6],d+=g[63&c[b+2]];return c.length%3===2?d=d.substring(0,d.length-1)+"=":c.length%3===1&&(d=d.substring(0,d.length-2)+"=="),d}var g="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",h="~~local_forage_type~",i=/^~~local_forage_type~([^~]+)~/,j="__lfsc__:",k=j.length,l="arbf",m="blob",n="si08",o="ui08",p="uic8",q="si16",r="si32",s="ur16",t="ui32",u="fl32",v="fl64",w=k+l.length,x={serialize:c,deserialize:d,stringToBuffer:e,bufferToString:f};return x}("undefined"!=typeof window?window:self);b["default"]=c,a.exports=b["default"]},function(a,b,c){"use strict";b.__esModule=!0;var d=function(a){function b(a){var b=this,d={db:null};if(a)for(var e in a)d[e]="string"!=typeof a[e]?a[e].toString():a[e];var f=new Promise(function(a,c){try{d.db=m(d.name,String(d.version),d.description,d.size)}catch(e){return c(e)}d.db.transaction(function(e){e.executeSql("CREATE TABLE IF NOT EXISTS "+d.storeName+" (id INTEGER PRIMARY KEY, key unique, value)",[],function(){b._dbInfo=d,a()},function(a,b){c(b)})})});return new Promise(function(a,b){a(c(3))}).then(function(a){return d.serializer=a,f})}function d(b,c){var d=this;"string"!=typeof b&&(a.console.warn(b+" used as a key, but it is not a string."),b=String(b));var e=new Promise(function(a,c){d.ready().then(function(){var e=d._dbInfo;e.db.transaction(function(d){d.executeSql("SELECT * FROM "+e.storeName+" WHERE key = ? LIMIT 1",[b],function(b,c){var d=c.rows.length?c.rows.item(0).value:null;d&&(d=e.serializer.deserialize(d)),a(d)},function(a,b){c(b)})})})["catch"](c)});return l(e,c),e}function e(a,b){var c=this,d=new Promise(function(b,d){c.ready().then(function(){var e=c._dbInfo;e.db.transaction(function(c){c.executeSql("SELECT * FROM "+e.storeName,[],function(c,d){for(var f=d.rows,g=f.length,h=0;g>h;h++){var i=f.item(h),j=i.value;if(j&&(j=e.serializer.deserialize(j)),j=a(j,i.key,h+1),void 0!==j)return void b(j)}b()},function(a,b){d(b)})})})["catch"](d)});return l(d,b),d}function f(b,c,d){var e=this;"string"!=typeof b&&(a.console.warn(b+" used as a key, but it is not a string."),b=String(b));var f=new Promise(function(a,d){e.ready().then(function(){void 0===c&&(c=null);var f=c,g=e._dbInfo;g.serializer.serialize(c,function(c,e){e?d(e):g.db.transaction(function(e){e.executeSql("INSERT OR REPLACE INTO "+g.storeName+" (key, value) VALUES (?, ?)",[b,c],function(){a(f)},function(a,b){d(b)})},function(a){a.code===a.QUOTA_ERR&&d(a)})})})["catch"](d)});return l(f,d),f}function g(b,c){var d=this;"string"!=typeof b&&(a.console.warn(b+" used as a key, but it is not a string."),b=String(b));var e=new Promise(function(a,c){d.ready().then(function(){var e=d._dbInfo;e.db.transaction(function(d){d.executeSql("DELETE FROM "+e.storeName+" WHERE key = ?",[b],function(){a()},function(a,b){c(b)})})})["catch"](c)});return l(e,c),e}function h(a){var b=this,c=new Promise(function(a,c){b.ready().then(function(){var d=b._dbInfo;d.db.transaction(function(b){b.executeSql("DELETE FROM "+d.storeName,[],function(){a()},function(a,b){c(b)})})})["catch"](c)});return l(c,a),c}function i(a){var b=this,c=new Promise(function(a,c){b.ready().then(function(){var d=b._dbInfo;d.db.transaction(function(b){b.executeSql("SELECT COUNT(key) as c FROM "+d.storeName,[],function(b,c){var d=c.rows.item(0).c;a(d)},function(a,b){c(b)})})})["catch"](c)});return l(c,a),c}function j(a,b){var c=this,d=new Promise(function(b,d){c.ready().then(function(){var e=c._dbInfo;e.db.transaction(function(c){c.executeSql("SELECT key FROM "+e.storeName+" WHERE id = ? LIMIT 1",[a+1],function(a,c){var d=c.rows.length?c.rows.item(0).key:null;b(d)},function(a,b){d(b)})})})["catch"](d)});return l(d,b),d}function k(a){var b=this,c=new Promise(function(a,c){b.ready().then(function(){var d=b._dbInfo;d.db.transaction(function(b){b.executeSql("SELECT key FROM "+d.storeName,[],function(b,c){for(var d=[],e=0;e 0; + }; + Cnds.prototype.IsProcessingGets = function () + { + return this.pendingGets > 0; + }; + Cnds.prototype.OnAllSetsComplete = function () + { + return true; + }; + Cnds.prototype.OnAllGetsComplete = function () + { + return true; + }; + pluginProto.cnds = new Cnds(); + function Acts() {}; + Acts.prototype.SetItem = function (keyNoPrefix, value) + { + if (localForageInitFailed) + { + TriggerStorageError(this, "storage failed to initialise - may be disabled in browser settings"); + return; + } + var keyPrefix = prefix + keyNoPrefix; + this.pendingSets++; + var self = this; + localforage["setItem"](keyPrefix, value, function (err, valueSet) + { + debugDataChanged = true; + self.pendingSets--; + if (err) + { + errorMessage = getErrorString(err); + self.runtime.trigger(cr.plugins_.LocalStorage.prototype.cnds.OnError, self); + } + else + { + currentKey = keyNoPrefix; + lastValue = valueSet; + self.runtime.trigger(cr.plugins_.LocalStorage.prototype.cnds.OnAnyItemSet, self); + self.runtime.trigger(cr.plugins_.LocalStorage.prototype.cnds.OnItemSet, self); + currentKey = ""; + lastValue = ""; + } + if (self.pendingSets === 0) + { + self.runtime.trigger(cr.plugins_.LocalStorage.prototype.cnds.OnAllSetsComplete, self); + } + }); + }; + Acts.prototype.GetItem = function (keyNoPrefix) + { + if (localForageInitFailed) + { + TriggerStorageError(this, "storage failed to initialise - may be disabled in browser settings"); + return; + } + var keyPrefix = prefix + keyNoPrefix; + this.pendingGets++; + var self = this; + localforage["getItem"](keyPrefix, function (err, value) + { + self.pendingGets--; + if (err) + { + errorMessage = getErrorString(err); + self.runtime.trigger(cr.plugins_.LocalStorage.prototype.cnds.OnError, self); + } + else + { + currentKey = keyNoPrefix; + lastValue = value; + if (typeof lastValue === "undefined" || lastValue === null) + lastValue = ""; + self.runtime.trigger(cr.plugins_.LocalStorage.prototype.cnds.OnAnyItemGet, self); + self.runtime.trigger(cr.plugins_.LocalStorage.prototype.cnds.OnItemGet, self); + currentKey = ""; + lastValue = ""; + } + if (self.pendingGets === 0) + { + self.runtime.trigger(cr.plugins_.LocalStorage.prototype.cnds.OnAllGetsComplete, self); + } + }); + }; + Acts.prototype.CheckItemExists = function (keyNoPrefix) + { + if (localForageInitFailed) + { + TriggerStorageError(this, "storage failed to initialise - may be disabled in browser settings"); + return; + } + var keyPrefix = prefix + keyNoPrefix; + var self = this; + localforage["getItem"](keyPrefix, function (err, value) + { + if (err) + { + errorMessage = getErrorString(err); + self.runtime.trigger(cr.plugins_.LocalStorage.prototype.cnds.OnError, self); + } + else + { + currentKey = keyNoPrefix; + if (value === null) // null value indicates key missing + { + lastValue = ""; // prevent ItemValue meaning anything + self.runtime.trigger(cr.plugins_.LocalStorage.prototype.cnds.OnItemMissing, self); + } + else + { + lastValue = value; // make available to ItemValue expression + self.runtime.trigger(cr.plugins_.LocalStorage.prototype.cnds.OnItemExists, self); + } + currentKey = ""; + lastValue = ""; + } + }); + }; + Acts.prototype.RemoveItem = function (keyNoPrefix) + { + if (localForageInitFailed) + { + TriggerStorageError(this, "storage failed to initialise - may be disabled in browser settings"); + return; + } + var keyPrefix = prefix + keyNoPrefix; + var self = this; + localforage["removeItem"](keyPrefix, function (err) + { + debugDataChanged = true; + if (err) + { + errorMessage = getErrorString(err); + self.runtime.trigger(cr.plugins_.LocalStorage.prototype.cnds.OnError, self); + } + else + { + currentKey = keyNoPrefix; + lastValue = ""; + self.runtime.trigger(cr.plugins_.LocalStorage.prototype.cnds.OnAnyItemRemoved, self); + self.runtime.trigger(cr.plugins_.LocalStorage.prototype.cnds.OnItemRemoved, self); + currentKey = ""; + } + }); + }; + Acts.prototype.ClearStorage = function () + { + if (localForageInitFailed) + { + TriggerStorageError(this, "storage failed to initialise - may be disabled in browser settings"); + return; + } + if (is_arcade) + return; + var self = this; + localforage["clear"](function (err) + { + debugDataChanged = true; + if (err) + { + errorMessage = getErrorString(err); + self.runtime.trigger(cr.plugins_.LocalStorage.prototype.cnds.OnError, self); + } + else + { + currentKey = ""; + lastValue = ""; + cr.clearArray(keyNamesList); + self.runtime.trigger(cr.plugins_.LocalStorage.prototype.cnds.OnCleared, self); + } + }); + }; + Acts.prototype.GetAllKeyNames = function () + { + if (localForageInitFailed) + { + TriggerStorageError(this, "storage failed to initialise - may be disabled in browser settings"); + return; + } + var self = this; + localforage["keys"](function (err, keyList) + { + var i, len, k; + if (err) + { + errorMessage = getErrorString(err); + self.runtime.trigger(cr.plugins_.LocalStorage.prototype.cnds.OnError, self); + } + else + { + cr.clearArray(keyNamesList); + for (i = 0, len = keyList.length; i < len; ++i) + { + k = keyList[i]; + if (!hasRequiredPrefix(k)) + continue; + keyNamesList.push(removePrefix(k)); + } + self.runtime.trigger(cr.plugins_.LocalStorage.prototype.cnds.OnAllKeyNamesLoaded, self); + } + }); + }; + pluginProto.acts = new Acts(); + function Exps() {}; + Exps.prototype.ItemValue = function (ret) + { + ret.set_any(lastValue); + }; + Exps.prototype.Key = function (ret) + { + ret.set_string(currentKey); + }; + Exps.prototype.KeyCount = function (ret) + { + ret.set_int(keyNamesList.length); + }; + Exps.prototype.KeyAt = function (ret, i) + { + i = Math.floor(i); + if (i < 0 || i >= keyNamesList.length) + { + ret.set_string(""); + return; + } + ret.set_string(keyNamesList[i]); + }; + Exps.prototype.ErrorMessage = function (ret) + { + ret.set_string(errorMessage); + }; + pluginProto.exps = new Exps(); +}()); +; +; +cr.plugins_.Mouse = function(runtime) +{ + this.runtime = runtime; +}; +(function () +{ + var pluginProto = cr.plugins_.Mouse.prototype; + pluginProto.Type = function(plugin) + { + this.plugin = plugin; + this.runtime = plugin.runtime; + }; + var typeProto = pluginProto.Type.prototype; + typeProto.onCreate = function() + { + }; + pluginProto.Instance = function(type) + { + this.type = type; + this.runtime = type.runtime; + this.buttonMap = new Array(4); // mouse down states + this.mouseXcanvas = 0; // mouse position relative to canvas + this.mouseYcanvas = 0; + this.triggerButton = 0; + this.triggerType = 0; + this.triggerDir = 0; + this.handled = false; + }; + var instanceProto = pluginProto.Instance.prototype; + instanceProto.onCreate = function() + { + var self = this; + if (!this.runtime.isDomFree) + { + jQuery(document).mousemove( + function(info) { + self.onMouseMove(info); + } + ); + jQuery(document).mousedown( + function(info) { + self.onMouseDown(info); + } + ); + jQuery(document).mouseup( + function(info) { + self.onMouseUp(info); + } + ); + jQuery(document).dblclick( + function(info) { + self.onDoubleClick(info); + } + ); + var wheelevent = function(info) { + self.onWheel(info); + }; + document.addEventListener("mousewheel", wheelevent, false); + document.addEventListener("DOMMouseScroll", wheelevent, false); + } + }; + var dummyoffset = {left: 0, top: 0}; + instanceProto.onMouseMove = function(info) + { + var offset = this.runtime.isDomFree ? dummyoffset : jQuery(this.runtime.canvas).offset(); + this.mouseXcanvas = info.pageX - offset.left; + this.mouseYcanvas = info.pageY - offset.top; + }; + instanceProto.mouseInGame = function () + { + if (this.runtime.fullscreen_mode > 0) + return true; + return this.mouseXcanvas >= 0 && this.mouseYcanvas >= 0 + && this.mouseXcanvas < this.runtime.width && this.mouseYcanvas < this.runtime.height; + }; + instanceProto.onMouseDown = function(info) + { + if (!this.mouseInGame()) + return; + this.buttonMap[info.which] = true; + this.runtime.isInUserInputEvent = true; + this.runtime.trigger(cr.plugins_.Mouse.prototype.cnds.OnAnyClick, this); + this.triggerButton = info.which - 1; // 1-based + this.triggerType = 0; // single click + this.runtime.trigger(cr.plugins_.Mouse.prototype.cnds.OnClick, this); + this.runtime.trigger(cr.plugins_.Mouse.prototype.cnds.OnObjectClicked, this); + this.runtime.isInUserInputEvent = false; + }; + instanceProto.onMouseUp = function(info) + { + if (!this.buttonMap[info.which]) + return; + if (this.runtime.had_a_click && !this.runtime.isMobile) + info.preventDefault(); + this.runtime.had_a_click = true; + this.buttonMap[info.which] = false; + this.runtime.isInUserInputEvent = true; + this.triggerButton = info.which - 1; // 1-based + this.runtime.trigger(cr.plugins_.Mouse.prototype.cnds.OnRelease, this); + this.runtime.isInUserInputEvent = false; + }; + instanceProto.onDoubleClick = function(info) + { + if (!this.mouseInGame()) + return; + info.preventDefault(); + this.runtime.isInUserInputEvent = true; + this.triggerButton = info.which - 1; // 1-based + this.triggerType = 1; // double click + this.runtime.trigger(cr.plugins_.Mouse.prototype.cnds.OnClick, this); + this.runtime.trigger(cr.plugins_.Mouse.prototype.cnds.OnObjectClicked, this); + this.runtime.isInUserInputEvent = false; + }; + instanceProto.onWheel = function (info) + { + var delta = info.wheelDelta ? info.wheelDelta : info.detail ? -info.detail : 0; + this.triggerDir = (delta < 0 ? 0 : 1); + this.handled = false; + this.runtime.isInUserInputEvent = true; + this.runtime.trigger(cr.plugins_.Mouse.prototype.cnds.OnWheel, this); + this.runtime.isInUserInputEvent = false; + if (this.handled && cr.isCanvasInputEvent(info)) + info.preventDefault(); + }; + instanceProto.onWindowBlur = function () + { + var i, len; + for (i = 0, len = this.buttonMap.length; i < len; ++i) + { + if (!this.buttonMap[i]) + continue; + this.buttonMap[i] = false; + this.triggerButton = i - 1; + this.runtime.trigger(cr.plugins_.Mouse.prototype.cnds.OnRelease, this); + } + }; + function Cnds() {}; + Cnds.prototype.OnClick = function (button, type) + { + return button === this.triggerButton && type === this.triggerType; + }; + Cnds.prototype.OnAnyClick = function () + { + return true; + }; + Cnds.prototype.IsButtonDown = function (button) + { + return this.buttonMap[button + 1]; // jQuery uses 1-based buttons for some reason + }; + Cnds.prototype.OnRelease = function (button) + { + return button === this.triggerButton; + }; + Cnds.prototype.IsOverObject = function (obj) + { + var cnd = this.runtime.getCurrentCondition(); + var mx = this.mouseXcanvas; + var my = this.mouseYcanvas; + return cr.xor(this.runtime.testAndSelectCanvasPointOverlap(obj, mx, my, cnd.inverted), cnd.inverted); + }; + Cnds.prototype.OnObjectClicked = function (button, type, obj) + { + if (button !== this.triggerButton || type !== this.triggerType) + return false; // wrong click type + return this.runtime.testAndSelectCanvasPointOverlap(obj, this.mouseXcanvas, this.mouseYcanvas, false); + }; + Cnds.prototype.OnWheel = function (dir) + { + this.handled = true; + return dir === this.triggerDir; + }; + pluginProto.cnds = new Cnds(); + function Acts() {}; + var lastSetCursor = null; + Acts.prototype.SetCursor = function (c) + { + if (this.runtime.isDomFree) + return; + var cursor_style = ["auto", "pointer", "text", "crosshair", "move", "help", "wait", "none"][c]; + if (lastSetCursor === cursor_style) + return; // redundant + lastSetCursor = cursor_style; + document.body.style.cursor = cursor_style; + }; + Acts.prototype.SetCursorSprite = function (obj) + { + if (this.runtime.isDomFree || this.runtime.isMobile || !obj) + return; + var inst = obj.getFirstPicked(); + if (!inst || !inst.curFrame) + return; + var frame = inst.curFrame; + if (lastSetCursor === frame) + return; // already set this frame + lastSetCursor = frame; + var datauri = frame.getDataUri(); + var cursor_style = "url(" + datauri + ") " + Math.round(frame.hotspotX * frame.width) + " " + Math.round(frame.hotspotY * frame.height) + ", auto"; + document.body.style.cursor = ""; + document.body.style.cursor = cursor_style; + }; + pluginProto.acts = new Acts(); + function Exps() {}; + Exps.prototype.X = function (ret, layerparam) + { + var layer, oldScale, oldZoomRate, oldParallaxX, oldAngle; + if (cr.is_undefined(layerparam)) + { + layer = this.runtime.getLayerByNumber(0); + oldScale = layer.scale; + oldZoomRate = layer.zoomRate; + oldParallaxX = layer.parallaxX; + oldAngle = layer.angle; + layer.scale = 1; + layer.zoomRate = 1.0; + layer.parallaxX = 1.0; + layer.angle = 0; + ret.set_float(layer.canvasToLayer(this.mouseXcanvas, this.mouseYcanvas, true)); + layer.scale = oldScale; + layer.zoomRate = oldZoomRate; + layer.parallaxX = oldParallaxX; + layer.angle = oldAngle; + } + else + { + if (cr.is_number(layerparam)) + layer = this.runtime.getLayerByNumber(layerparam); + else + layer = this.runtime.getLayerByName(layerparam); + if (layer) + ret.set_float(layer.canvasToLayer(this.mouseXcanvas, this.mouseYcanvas, true)); + else + ret.set_float(0); + } + }; + Exps.prototype.Y = function (ret, layerparam) + { + var layer, oldScale, oldZoomRate, oldParallaxY, oldAngle; + if (cr.is_undefined(layerparam)) + { + layer = this.runtime.getLayerByNumber(0); + oldScale = layer.scale; + oldZoomRate = layer.zoomRate; + oldParallaxY = layer.parallaxY; + oldAngle = layer.angle; + layer.scale = 1; + layer.zoomRate = 1.0; + layer.parallaxY = 1.0; + layer.angle = 0; + ret.set_float(layer.canvasToLayer(this.mouseXcanvas, this.mouseYcanvas, false)); + layer.scale = oldScale; + layer.zoomRate = oldZoomRate; + layer.parallaxY = oldParallaxY; + layer.angle = oldAngle; + } + else + { + if (cr.is_number(layerparam)) + layer = this.runtime.getLayerByNumber(layerparam); + else + layer = this.runtime.getLayerByName(layerparam); + if (layer) + ret.set_float(layer.canvasToLayer(this.mouseXcanvas, this.mouseYcanvas, false)); + else + ret.set_float(0); + } + }; + Exps.prototype.AbsoluteX = function (ret) + { + ret.set_float(this.mouseXcanvas); + }; + Exps.prototype.AbsoluteY = function (ret) + { + ret.set_float(this.mouseYcanvas); + }; + pluginProto.exps = new Exps(); +}()); +; +; +cr.plugins_.Rex_Date = function(runtime) +{ + this.runtime = runtime; +}; +(function () +{ + var pluginProto = cr.plugins_.Rex_Date.prototype; + pluginProto.Type = function(plugin) + { + this.plugin = plugin; + this.runtime = plugin.runtime; + }; + var typeProto = pluginProto.Type.prototype; + typeProto.onCreate = function() + { + }; + pluginProto.Instance = function(type) + { + this.type = type; + this.runtime = type.runtime; + }; + var instanceProto = pluginProto.Instance.prototype; + instanceProto.onCreate = function() + { + this._timers = {}; + }; + instanceProto.saveToJSON = function () + { + return { "tims": this._timers, + }; + }; + instanceProto.loadFromJSON = function (o) + { + this._timers = o["tims"]; + }; + function Cnds() {}; + pluginProto.cnds = new Cnds(); + function Acts() {}; + pluginProto.acts = new Acts(); + Acts.prototype.StartTimer = function (name) + { + var timer = new Date(); + this._timers[name] = timer.getTime(); + }; + function Exps() {}; + pluginProto.exps = new Exps(); + Exps.prototype.Year = function (ret, timestamp) + { + var today = (timestamp != null)? new Date(timestamp): new Date(); + ret.set_int(today.getFullYear()); + }; + Exps.prototype.Month = function (ret, timestamp) + { + var today = (timestamp != null)? new Date(timestamp): new Date(); + ret.set_int(today.getMonth()+1); + }; + Exps.prototype.Date = function (ret, timestamp) + { + var today = (timestamp != null)? new Date(timestamp): new Date(); + ret.set_int(today.getDate()); + }; + Exps.prototype.Day = function (ret, timestamp) + { + var today = (timestamp != null)? new Date(timestamp): new Date(); + ret.set_int(today.getDay()); + }; + Exps.prototype.Hours = function (ret, timestamp) + { + var today = (timestamp != null)? new Date(timestamp): new Date(); + ret.set_int(today.getHours()); + }; + Exps.prototype.Minutes = function (ret, timestamp) + { + var today = (timestamp != null)? new Date(timestamp): new Date(); + ret.set_int(today.getMinutes()); + }; + Exps.prototype.Seconds = function (ret, timestamp) + { + var today = (timestamp != null)? new Date(timestamp): new Date(); + ret.set_int(today.getSeconds()); + }; + Exps.prototype.Milliseconds = function (ret, timestamp) + { + var today = (timestamp != null)? new Date(timestamp): new Date(); + ret.set_int(today.getMilliseconds()); + }; + Exps.prototype.Timer = function (ret, name) + { + var delta = 0; + var start_tick = this._timers[name]; + if (start_tick != null) { + var timer = new Date(); + delta = timer.getTime() - start_tick; + } + ret.set_float(delta/1000); + }; + Exps.prototype.CurTicks = function (ret) + { + var today = new Date(); + ret.set_int(today.getTime()); + }; + Exps.prototype.UnixTimestamp = function (ret) + { + var today = new Date(); + ret.set_float(today.getTime()); + }; + Exps.prototype.Date2UnixTimestamp = function (ret, year, month, day, hours, minutes, seconds, milliseconds) + { + year = year || 2000; + month = month || 1; + day = day || 1; + hours = hours || 0; + minutes = minutes || 0; + seconds = seconds || 0; + milliseconds = milliseconds || 0; + var timestamp = new Date(year, month-1, day, hours, minutes, seconds, milliseconds); // build Date object + ret.set_float(timestamp.getTime()); + }; +}()); +; +; +var localForageInitFailed = false; +try { +/*! + localForage -- Offline Storage, Improved + Version 1.4.0 + https://mozilla.github.io/localForage + (c) 2013-2015 Mozilla, Apache License 2.0 +*/ +!function(){var a,b,c,d;!function(){var e={},f={};a=function(a,b,c){e[a]={deps:b,callback:c}},d=c=b=function(a){function c(b){if("."!==b.charAt(0))return b;for(var c=b.split("/"),d=a.split("/").slice(0,-1),e=0,f=c.length;f>e;e++){var g=c[e];if(".."===g)d.pop();else{if("."===g)continue;d.push(g)}}return d.join("/")}if(d._eak_seen=e,f[a])return f[a];if(f[a]={},!e[a])throw new Error("Could not find module "+a);for(var g,h=e[a],i=h.deps,j=h.callback,k=[],l=0,m=i.length;m>l;l++)"exports"===i[l]?k.push(g={}):k.push(b(c(i[l])));var n=j.apply(this,k);return f[a]=g||n}}(),a("promise/all",["./utils","exports"],function(a,b){"use strict";function c(a){var b=this;if(!d(a))throw new TypeError("You must pass an array to all.");return new b(function(b,c){function d(a){return function(b){f(a,b)}}function f(a,c){h[a]=c,0===--i&&b(h)}var g,h=[],i=a.length;0===i&&b([]);for(var j=0;jc;c++){var e=a[c];this.supports(e)&&b.push(e)}return b},a.prototype._wrapLibraryMethodsWithReady=function(){for(var a=0;ae;e++)d[e]=a.charCodeAt(e);return c}function d(a){return new Promise(function(b,c){var d=new XMLHttpRequest;d.open("GET",a),d.withCredentials=!0,d.responseType="arraybuffer",d.onreadystatechange=function(){return 4===d.readyState?200===d.status?b({response:d.response,type:d.getResponseHeader("Content-Type")}):void c({status:d.status,response:d.response}):void 0},d.send()})}function e(a){return new Promise(function(c,e){var f=b([""],{type:"image/png"}),g=a.transaction([D],"readwrite");g.objectStore(D).put(f,"key"),g.oncomplete=function(){var b=a.transaction([D],"readwrite"),f=b.objectStore(D).get("key");f.onerror=e,f.onsuccess=function(a){var b=a.target.result,e=URL.createObjectURL(b);d(e).then(function(a){c(!(!a||"image/png"!==a.type))},function(){c(!1)}).then(function(){URL.revokeObjectURL(e)})}},g.onerror=g.onabort=e})["catch"](function(){return!1})}function f(a){return"boolean"==typeof B?Promise.resolve(B):e(a).then(function(a){return B=a})}function g(a){return new Promise(function(b,c){var d=new FileReader;d.onerror=c,d.onloadend=function(c){var d=btoa(c.target.result||"");b({__local_forage_encoded_blob:!0,data:d,type:a.type})},d.readAsBinaryString(a)})}function h(a){var d=c(atob(a.data));return b([d],{type:a.type})}function i(a){return a&&a.__local_forage_encoded_blob}function j(a){var b=this,c=b._initReady().then(function(){var a=C[b._dbInfo.name];return a&&a.dbReady?a.dbReady:void 0});return c.then(a,a),c}function k(a){var b=C[a.name],c={};c.promise=new Promise(function(a){c.resolve=a}),b.deferredOperations.push(c),b.dbReady?b.dbReady=b.dbReady.then(function(){return c.promise}):b.dbReady=c.promise}function l(a){var b=C[a.name],c=b.deferredOperations.pop();c&&c.resolve()}function m(a){function b(){return Promise.resolve()}var c=this,d={db:null};if(a)for(var e in a)d[e]=a[e];C||(C={});var f=C[d.name];f||(f={forages:[],db:null,dbReady:null,deferredOperations:[]},C[d.name]=f),f.forages.push(c),c._initReady||(c._initReady=c.ready,c.ready=j);for(var g=[],h=0;hb.db.version;if(e&&(b.version!==c&&a.console.warn('The database "'+b.name+"\" can't be downgraded from version "+b.db.version+" to version "+b.version+"."),b.version=b.db.version),f||d){if(d){var g=b.db.version+1;g>b.version&&(b.version=g)}return!0}return!1}function r(b,c){var d=this;"string"!=typeof b&&(a.console.warn(b+" used as a key, but it is not a string."),b=String(b));var e=new Promise(function(a,c){d.ready().then(function(){var e=d._dbInfo,f=e.db.transaction(e.storeName,"readonly").objectStore(e.storeName),g=f.get(b);g.onsuccess=function(){var b=g.result;void 0===b&&(b=null),i(b)&&(b=h(b)),a(b)},g.onerror=function(){c(g.error)}})["catch"](c)});return z(e,c),e}function s(a,b){var c=this,d=new Promise(function(b,d){c.ready().then(function(){var e=c._dbInfo,f=e.db.transaction(e.storeName,"readonly").objectStore(e.storeName),g=f.openCursor(),j=1;g.onsuccess=function(){var c=g.result;if(c){var d=c.value;i(d)&&(d=h(d));var e=a(d,c.key,j++);void 0!==e?b(e):c["continue"]()}else b()},g.onerror=function(){d(g.error)}})["catch"](d)});return z(d,b),d}function t(b,c,d){var e=this;"string"!=typeof b&&(a.console.warn(b+" used as a key, but it is not a string."),b=String(b));var h=new Promise(function(a,d){var h;e.ready().then(function(){return h=e._dbInfo,c instanceof Blob?f(h.db).then(function(a){return a?c:g(c)}):c}).then(function(c){var e=h.db.transaction(h.storeName,"readwrite"),f=e.objectStore(h.storeName);null===c&&(c=void 0),e.oncomplete=function(){void 0===c&&(c=null),a(c)},e.onabort=e.onerror=function(){var a=g.error?g.error:g.transaction.error;d(a)};var g=f.put(c,b)})["catch"](d)});return z(h,d),h}function u(b,c){var d=this;"string"!=typeof b&&(a.console.warn(b+" used as a key, but it is not a string."),b=String(b));var e=new Promise(function(a,c){d.ready().then(function(){var e=d._dbInfo,f=e.db.transaction(e.storeName,"readwrite"),g=f.objectStore(e.storeName),h=g["delete"](b);f.oncomplete=function(){a()},f.onerror=function(){c(h.error)},f.onabort=function(){var a=h.error?h.error:h.transaction.error;c(a)}})["catch"](c)});return z(e,c),e}function v(a){var b=this,c=new Promise(function(a,c){b.ready().then(function(){var d=b._dbInfo,e=d.db.transaction(d.storeName,"readwrite"),f=e.objectStore(d.storeName),g=f.clear();e.oncomplete=function(){a()},e.onabort=e.onerror=function(){var a=g.error?g.error:g.transaction.error;c(a)}})["catch"](c)});return z(c,a),c}function w(a){var b=this,c=new Promise(function(a,c){b.ready().then(function(){var d=b._dbInfo,e=d.db.transaction(d.storeName,"readonly").objectStore(d.storeName),f=e.count();f.onsuccess=function(){a(f.result)},f.onerror=function(){c(f.error)}})["catch"](c)});return z(c,a),c}function x(a,b){var c=this,d=new Promise(function(b,d){return 0>a?void b(null):void c.ready().then(function(){var e=c._dbInfo,f=e.db.transaction(e.storeName,"readonly").objectStore(e.storeName),g=!1,h=f.openCursor();h.onsuccess=function(){var c=h.result;return c?void(0===a?b(c.key):g?b(c.key):(g=!0,c.advance(a))):void b(null)},h.onerror=function(){d(h.error)}})["catch"](d)});return z(d,b),d}function y(a){var b=this,c=new Promise(function(a,c){b.ready().then(function(){var d=b._dbInfo,e=d.db.transaction(d.storeName,"readonly").objectStore(d.storeName),f=e.openCursor(),g=[];f.onsuccess=function(){var b=f.result;return b?(g.push(b.key),void b["continue"]()):void a(g)},f.onerror=function(){c(f.error)}})["catch"](c)});return z(c,a),c}function z(a,b){b&&a.then(function(a){b(null,a)},function(a){b(a)})}var A=A||a.indexedDB||a.webkitIndexedDB||a.mozIndexedDB||a.OIndexedDB||a.msIndexedDB;if(A){var B,C,D="local-forage-detect-blob-support",E={_driver:"asyncStorage",_initStorage:m,iterate:s,getItem:r,setItem:t,removeItem:u,clear:v,length:w,key:x,keys:y};return E}}("undefined"!=typeof window?window:self);b["default"]=c,a.exports=b["default"]},function(a,b,c){"use strict";b.__esModule=!0;var d=function(a){function b(a){var b=this,d={};if(a)for(var e in a)d[e]=a[e];return d.keyPrefix=d.name+"/",d.storeName!==b._defaultConfig.storeName&&(d.keyPrefix+=d.storeName+"/"),b._dbInfo=d,new Promise(function(a,b){a(c(3))}).then(function(a){return d.serializer=a,Promise.resolve()})}function d(a){var b=this,c=b.ready().then(function(){for(var a=b._dbInfo.keyPrefix,c=m.length-1;c>=0;c--){var d=m.key(c);0===d.indexOf(a)&&m.removeItem(d)}});return l(c,a),c}function e(b,c){var d=this;"string"!=typeof b&&(a.console.warn(b+" used as a key, but it is not a string."),b=String(b));var e=d.ready().then(function(){var a=d._dbInfo,c=m.getItem(a.keyPrefix+b);return c&&(c=a.serializer.deserialize(c)),c});return l(e,c),e}function f(a,b){var c=this,d=c.ready().then(function(){for(var b=c._dbInfo,d=b.keyPrefix,e=d.length,f=m.length,g=1,h=0;f>h;h++){var i=m.key(h);if(0===i.indexOf(d)){var j=m.getItem(i);if(j&&(j=b.serializer.deserialize(j)),j=a(j,i.substring(e),g++),void 0!==j)return j}}});return l(d,b),d}function g(a,b){var c=this,d=c.ready().then(function(){var b,d=c._dbInfo;try{b=m.key(a)}catch(e){b=null}return b&&(b=b.substring(d.keyPrefix.length)),b});return l(d,b),d}function h(a){var b=this,c=b.ready().then(function(){for(var a=b._dbInfo,c=m.length,d=[],e=0;c>e;e++)0===m.key(e).indexOf(a.keyPrefix)&&d.push(m.key(e).substring(a.keyPrefix.length));return d});return l(c,a),c}function i(a){var b=this,c=b.keys().then(function(a){return a.length});return l(c,a),c}function j(b,c){var d=this;"string"!=typeof b&&(a.console.warn(b+" used as a key, but it is not a string."),b=String(b));var e=d.ready().then(function(){var a=d._dbInfo;m.removeItem(a.keyPrefix+b)});return l(e,c),e}function k(b,c,d){var e=this;"string"!=typeof b&&(a.console.warn(b+" used as a key, but it is not a string."),b=String(b));var f=e.ready().then(function(){void 0===c&&(c=null);var a=c;return new Promise(function(d,f){var g=e._dbInfo;g.serializer.serialize(c,function(c,e){if(e)f(e);else try{m.setItem(g.keyPrefix+b,c),d(a)}catch(h){("QuotaExceededError"===h.name||"NS_ERROR_DOM_QUOTA_REACHED"===h.name)&&f(h),f(h)}})})});return l(f,d),f}function l(a,b){b&&a.then(function(a){b(null,a)},function(a){b(a)})}var m=null;try{if(!(a.localStorage&&"setItem"in a.localStorage))return;m=a.localStorage}catch(n){return}var o={_driver:"localStorageWrapper",_initStorage:b,iterate:f,getItem:e,setItem:k,removeItem:j,clear:d,length:i,key:g,keys:h};return o}("undefined"!=typeof window?window:self);b["default"]=d,a.exports=b["default"]},function(a,b){"use strict";b.__esModule=!0;var c=function(a){function b(b,c){b=b||[],c=c||{};try{return new Blob(b,c)}catch(d){if("TypeError"!==d.name)throw d;for(var e=a.BlobBuilder||a.MSBlobBuilder||a.MozBlobBuilder||a.WebKitBlobBuilder,f=new e,g=0;gb;b+=4)c=g.indexOf(a[b]),d=g.indexOf(a[b+1]),e=g.indexOf(a[b+2]),f=g.indexOf(a[b+3]),l[j++]=c<<2|d>>4,l[j++]=(15&d)<<4|e>>2,l[j++]=(3&e)<<6|63&f;return k}function f(a){var b,c=new Uint8Array(a),d="";for(b=0;b>2],d+=g[(3&c[b])<<4|c[b+1]>>4],d+=g[(15&c[b+1])<<2|c[b+2]>>6],d+=g[63&c[b+2]];return c.length%3===2?d=d.substring(0,d.length-1)+"=":c.length%3===1&&(d=d.substring(0,d.length-2)+"=="),d}var g="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",h="~~local_forage_type~",i=/^~~local_forage_type~([^~]+)~/,j="__lfsc__:",k=j.length,l="arbf",m="blob",n="si08",o="ui08",p="uic8",q="si16",r="si32",s="ur16",t="ui32",u="fl32",v="fl64",w=k+l.length,x={serialize:c,deserialize:d,stringToBuffer:e,bufferToString:f};return x}("undefined"!=typeof window?window:self);b["default"]=c,a.exports=b["default"]},function(a,b,c){"use strict";b.__esModule=!0;var d=function(a){function b(a){var b=this,d={db:null};if(a)for(var e in a)d[e]="string"!=typeof a[e]?a[e].toString():a[e];var f=new Promise(function(a,c){try{d.db=m(d.name,String(d.version),d.description,d.size)}catch(e){return c(e)}d.db.transaction(function(e){e.executeSql("CREATE TABLE IF NOT EXISTS "+d.storeName+" (id INTEGER PRIMARY KEY, key unique, value)",[],function(){b._dbInfo=d,a()},function(a,b){c(b)})})});return new Promise(function(a,b){a(c(3))}).then(function(a){return d.serializer=a,f})}function d(b,c){var d=this;"string"!=typeof b&&(a.console.warn(b+" used as a key, but it is not a string."),b=String(b));var e=new Promise(function(a,c){d.ready().then(function(){var e=d._dbInfo;e.db.transaction(function(d){d.executeSql("SELECT * FROM "+e.storeName+" WHERE key = ? LIMIT 1",[b],function(b,c){var d=c.rows.length?c.rows.item(0).value:null;d&&(d=e.serializer.deserialize(d)),a(d)},function(a,b){c(b)})})})["catch"](c)});return l(e,c),e}function e(a,b){var c=this,d=new Promise(function(b,d){c.ready().then(function(){var e=c._dbInfo;e.db.transaction(function(c){c.executeSql("SELECT * FROM "+e.storeName,[],function(c,d){for(var f=d.rows,g=f.length,h=0;g>h;h++){var i=f.item(h),j=i.value;if(j&&(j=e.serializer.deserialize(j)),j=a(j,i.key,h+1),void 0!==j)return void b(j)}b()},function(a,b){d(b)})})})["catch"](d)});return l(d,b),d}function f(b,c,d){var e=this;"string"!=typeof b&&(a.console.warn(b+" used as a key, but it is not a string."),b=String(b));var f=new Promise(function(a,d){e.ready().then(function(){void 0===c&&(c=null);var f=c,g=e._dbInfo;g.serializer.serialize(c,function(c,e){e?d(e):g.db.transaction(function(e){e.executeSql("INSERT OR REPLACE INTO "+g.storeName+" (key, value) VALUES (?, ?)",[b,c],function(){a(f)},function(a,b){d(b)})},function(a){a.code===a.QUOTA_ERR&&d(a)})})})["catch"](d)});return l(f,d),f}function g(b,c){var d=this;"string"!=typeof b&&(a.console.warn(b+" used as a key, but it is not a string."),b=String(b));var e=new Promise(function(a,c){d.ready().then(function(){var e=d._dbInfo;e.db.transaction(function(d){d.executeSql("DELETE FROM "+e.storeName+" WHERE key = ?",[b],function(){a()},function(a,b){c(b)})})})["catch"](c)});return l(e,c),e}function h(a){var b=this,c=new Promise(function(a,c){b.ready().then(function(){var d=b._dbInfo;d.db.transaction(function(b){b.executeSql("DELETE FROM "+d.storeName,[],function(){a()},function(a,b){c(b)})})})["catch"](c)});return l(c,a),c}function i(a){var b=this,c=new Promise(function(a,c){b.ready().then(function(){var d=b._dbInfo;d.db.transaction(function(b){b.executeSql("SELECT COUNT(key) as c FROM "+d.storeName,[],function(b,c){var d=c.rows.item(0).c;a(d)},function(a,b){c(b)})})})["catch"](c)});return l(c,a),c}function j(a,b){var c=this,d=new Promise(function(b,d){c.ready().then(function(){var e=c._dbInfo;e.db.transaction(function(c){c.executeSql("SELECT key FROM "+e.storeName+" WHERE id = ? LIMIT 1",[a+1],function(a,c){var d=c.rows.length?c.rows.item(0).key:null;b(d)},function(a,b){d(b)})})})["catch"](d)});return l(d,b),d}function k(a){var b=this,c=new Promise(function(a,c){b.ready().then(function(){var d=b._dbInfo;d.db.transaction(function(b){b.executeSql("SELECT key FROM "+d.storeName,[],function(b,c){for(var d=[],e=0;e= this.cur_animation.frames.length) + this.cur_frame = this.cur_animation.frames.length - 1; + var curanimframe = this.cur_animation.frames[this.cur_frame]; + this.collision_poly.set_pts(curanimframe.poly_pts); + this.hotspotX = curanimframe.hotspotX; + this.hotspotY = curanimframe.hotspotY; + this.cur_anim_speed = this.cur_animation.speed; + this.cur_anim_repeatto = this.cur_animation.repeatto; + if (!(this.type.animations.length === 1 && this.type.animations[0].frames.length === 1) && this.cur_anim_speed !== 0) + { + this.runtime.tickMe(this); + this.isTicking = true; + } + if (this.recycled) + this.animTimer.reset(); + else + this.animTimer = new cr.KahanAdder(); + this.frameStart = this.getNowTime(); + this.animPlaying = true; + this.animRepeats = 0; + this.animForwards = true; + this.animTriggerName = ""; + this.changeAnimName = ""; + this.changeAnimFrom = 0; + this.changeAnimFrame = -1; + this.type.loadTextures(); + var i, leni, j, lenj; + var anim, frame, uv, maintex; + for (i = 0, leni = this.type.animations.length; i < leni; i++) + { + anim = this.type.animations[i]; + for (j = 0, lenj = anim.frames.length; j < lenj; j++) + { + frame = anim.frames[j]; + if (frame.width === 0) + { + frame.width = frame.texture_img.width; + frame.height = frame.texture_img.height; + } + if (frame.spritesheeted) + { + maintex = frame.texture_img; + uv = frame.sheetTex; + uv.left = frame.offx / maintex.width; + uv.top = frame.offy / maintex.height; + uv.right = (frame.offx + frame.width) / maintex.width; + uv.bottom = (frame.offy + frame.height) / maintex.height; + if (frame.offx === 0 && frame.offy === 0 && frame.width === maintex.width && frame.height === maintex.height) + { + frame.spritesheeted = false; + } + } + } + } + this.curFrame = this.cur_animation.frames[this.cur_frame]; + this.curWebGLTexture = this.curFrame.webGL_texture; + }; + instanceProto.saveToJSON = function () + { + var o = { + "a": this.cur_animation.sid, + "f": this.cur_frame, + "cas": this.cur_anim_speed, + "fs": this.frameStart, + "ar": this.animRepeats, + "at": this.animTimer.sum, + "rt": this.cur_anim_repeatto + }; + if (!this.animPlaying) + o["ap"] = this.animPlaying; + if (!this.animForwards) + o["af"] = this.animForwards; + return o; + }; + instanceProto.loadFromJSON = function (o) + { + var anim = this.getAnimationBySid(o["a"]); + if (anim) + this.cur_animation = anim; + this.cur_frame = o["f"]; + if (this.cur_frame < 0) + this.cur_frame = 0; + if (this.cur_frame >= this.cur_animation.frames.length) + this.cur_frame = this.cur_animation.frames.length - 1; + this.cur_anim_speed = o["cas"]; + this.frameStart = o["fs"]; + this.animRepeats = o["ar"]; + this.animTimer.reset(); + this.animTimer.sum = o["at"]; + this.animPlaying = o.hasOwnProperty("ap") ? o["ap"] : true; + this.animForwards = o.hasOwnProperty("af") ? o["af"] : true; + if (o.hasOwnProperty("rt")) + this.cur_anim_repeatto = o["rt"]; + else + this.cur_anim_repeatto = this.cur_animation.repeatto; + this.curFrame = this.cur_animation.frames[this.cur_frame]; + this.curWebGLTexture = this.curFrame.webGL_texture; + this.collision_poly.set_pts(this.curFrame.poly_pts); + this.hotspotX = this.curFrame.hotspotX; + this.hotspotY = this.curFrame.hotspotY; + }; + instanceProto.animationFinish = function (reverse) + { + this.cur_frame = reverse ? 0 : this.cur_animation.frames.length - 1; + this.animPlaying = false; + this.animTriggerName = this.cur_animation.name; + this.inAnimTrigger = true; + this.runtime.trigger(cr.plugins_.Sprite.prototype.cnds.OnAnyAnimFinished, this); + this.runtime.trigger(cr.plugins_.Sprite.prototype.cnds.OnAnimFinished, this); + this.inAnimTrigger = false; + this.animRepeats = 0; + }; + instanceProto.getNowTime = function() + { + return this.animTimer.sum; + }; + instanceProto.tick = function() + { + this.animTimer.add(this.runtime.getDt(this)); + if (this.changeAnimName.length) + this.doChangeAnim(); + if (this.changeAnimFrame >= 0) + this.doChangeAnimFrame(); + var now = this.getNowTime(); + var cur_animation = this.cur_animation; + var prev_frame = cur_animation.frames[this.cur_frame]; + var next_frame; + var cur_frame_time = prev_frame.duration / this.cur_anim_speed; + if (this.animPlaying && now >= this.frameStart + cur_frame_time) + { + if (this.animForwards) + { + this.cur_frame++; + } + else + { + this.cur_frame--; + } + this.frameStart += cur_frame_time; + if (this.cur_frame >= cur_animation.frames.length) + { + if (cur_animation.pingpong) + { + this.animForwards = false; + this.cur_frame = cur_animation.frames.length - 2; + } + else if (cur_animation.loop) + { + this.cur_frame = this.cur_anim_repeatto; + } + else + { + this.animRepeats++; + if (this.animRepeats >= cur_animation.repeatcount) + { + this.animationFinish(false); + } + else + { + this.cur_frame = this.cur_anim_repeatto; + } + } + } + if (this.cur_frame < 0) + { + if (cur_animation.pingpong) + { + this.cur_frame = 1; + this.animForwards = true; + if (!cur_animation.loop) + { + this.animRepeats++; + if (this.animRepeats >= cur_animation.repeatcount) + { + this.animationFinish(true); + } + } + } + else + { + if (cur_animation.loop) + { + this.cur_frame = this.cur_anim_repeatto; + } + else + { + this.animRepeats++; + if (this.animRepeats >= cur_animation.repeatcount) + { + this.animationFinish(true); + } + else + { + this.cur_frame = this.cur_anim_repeatto; + } + } + } + } + if (this.cur_frame < 0) + this.cur_frame = 0; + else if (this.cur_frame >= cur_animation.frames.length) + this.cur_frame = cur_animation.frames.length - 1; + if (now > this.frameStart + (cur_animation.frames[this.cur_frame].duration / this.cur_anim_speed)) + { + this.frameStart = now; + } + next_frame = cur_animation.frames[this.cur_frame]; + this.OnFrameChanged(prev_frame, next_frame); + this.runtime.redraw = true; + } + }; + instanceProto.getAnimationByName = function (name_) + { + var i, len, a; + for (i = 0, len = this.type.animations.length; i < len; i++) + { + a = this.type.animations[i]; + if (cr.equals_nocase(a.name, name_)) + return a; + } + return null; + }; + instanceProto.getAnimationBySid = function (sid_) + { + var i, len, a; + for (i = 0, len = this.type.animations.length; i < len; i++) + { + a = this.type.animations[i]; + if (a.sid === sid_) + return a; + } + return null; + }; + instanceProto.doChangeAnim = function () + { + var prev_frame = this.cur_animation.frames[this.cur_frame]; + var anim = this.getAnimationByName(this.changeAnimName); + this.changeAnimName = ""; + if (!anim) + return; + if (cr.equals_nocase(anim.name, this.cur_animation.name) && this.animPlaying) + return; + this.cur_animation = anim; + this.cur_anim_speed = anim.speed; + this.cur_anim_repeatto = anim.repeatto; + if (this.cur_frame < 0) + this.cur_frame = 0; + if (this.cur_frame >= this.cur_animation.frames.length) + this.cur_frame = this.cur_animation.frames.length - 1; + if (this.changeAnimFrom === 1) + this.cur_frame = 0; + this.animPlaying = true; + this.frameStart = this.getNowTime(); + this.animForwards = true; + this.OnFrameChanged(prev_frame, this.cur_animation.frames[this.cur_frame]); + this.runtime.redraw = true; + }; + instanceProto.doChangeAnimFrame = function () + { + var prev_frame = this.cur_animation.frames[this.cur_frame]; + var prev_frame_number = this.cur_frame; + this.cur_frame = cr.floor(this.changeAnimFrame); + if (this.cur_frame < 0) + this.cur_frame = 0; + if (this.cur_frame >= this.cur_animation.frames.length) + this.cur_frame = this.cur_animation.frames.length - 1; + if (prev_frame_number !== this.cur_frame) + { + this.OnFrameChanged(prev_frame, this.cur_animation.frames[this.cur_frame]); + this.frameStart = this.getNowTime(); + this.runtime.redraw = true; + } + this.changeAnimFrame = -1; + }; + instanceProto.OnFrameChanged = function (prev_frame, next_frame) + { + var oldw = prev_frame.width; + var oldh = prev_frame.height; + var neww = next_frame.width; + var newh = next_frame.height; + if (oldw != neww) + this.width *= (neww / oldw); + if (oldh != newh) + this.height *= (newh / oldh); + this.hotspotX = next_frame.hotspotX; + this.hotspotY = next_frame.hotspotY; + this.collision_poly.set_pts(next_frame.poly_pts); + this.set_bbox_changed(); + this.curFrame = next_frame; + this.curWebGLTexture = next_frame.webGL_texture; + var i, len, b; + for (i = 0, len = this.behavior_insts.length; i < len; i++) + { + b = this.behavior_insts[i]; + if (b.onSpriteFrameChanged) + b.onSpriteFrameChanged(prev_frame, next_frame); + } + this.runtime.trigger(cr.plugins_.Sprite.prototype.cnds.OnFrameChanged, this); + }; + instanceProto.draw = function(ctx) + { + ctx.globalAlpha = this.opacity; + var cur_frame = this.curFrame; + var spritesheeted = cur_frame.spritesheeted; + var cur_image = cur_frame.texture_img; + var myx = this.x; + var myy = this.y; + var w = this.width; + var h = this.height; + if (this.angle === 0 && w >= 0 && h >= 0) + { + myx -= this.hotspotX * w; + myy -= this.hotspotY * h; + if (this.runtime.pixel_rounding) + { + myx = Math.round(myx); + myy = Math.round(myy); + } + if (spritesheeted) + { + ctx.drawImage(cur_image, cur_frame.offx, cur_frame.offy, cur_frame.width, cur_frame.height, + myx, myy, w, h); + } + else + { + ctx.drawImage(cur_image, myx, myy, w, h); + } + } + else + { + if (this.runtime.pixel_rounding) + { + myx = Math.round(myx); + myy = Math.round(myy); + } + ctx.save(); + var widthfactor = w > 0 ? 1 : -1; + var heightfactor = h > 0 ? 1 : -1; + ctx.translate(myx, myy); + if (widthfactor !== 1 || heightfactor !== 1) + ctx.scale(widthfactor, heightfactor); + ctx.rotate(this.angle * widthfactor * heightfactor); + var drawx = 0 - (this.hotspotX * cr.abs(w)) + var drawy = 0 - (this.hotspotY * cr.abs(h)); + if (spritesheeted) + { + ctx.drawImage(cur_image, cur_frame.offx, cur_frame.offy, cur_frame.width, cur_frame.height, + drawx, drawy, cr.abs(w), cr.abs(h)); + } + else + { + ctx.drawImage(cur_image, drawx, drawy, cr.abs(w), cr.abs(h)); + } + ctx.restore(); + } + /* + ctx.strokeStyle = "#f00"; + ctx.lineWidth = 3; + ctx.beginPath(); + this.collision_poly.cache_poly(this.width, this.height, this.angle); + var i, len, ax, ay, bx, by; + for (i = 0, len = this.collision_poly.pts_count; i < len; i++) + { + ax = this.collision_poly.pts_cache[i*2] + this.x; + ay = this.collision_poly.pts_cache[i*2+1] + this.y; + bx = this.collision_poly.pts_cache[((i+1)%len)*2] + this.x; + by = this.collision_poly.pts_cache[((i+1)%len)*2+1] + this.y; + ctx.moveTo(ax, ay); + ctx.lineTo(bx, by); + } + ctx.stroke(); + ctx.closePath(); + */ + /* + if (this.behavior_insts.length >= 1 && this.behavior_insts[0].draw) + { + this.behavior_insts[0].draw(ctx); + } + */ + }; + instanceProto.drawGL_earlyZPass = function(glw) + { + this.drawGL(glw); + }; + instanceProto.drawGL = function(glw) + { + glw.setTexture(this.curWebGLTexture); + glw.setOpacity(this.opacity); + var cur_frame = this.curFrame; + var q = this.bquad; + if (this.runtime.pixel_rounding) + { + var ox = Math.round(this.x) - this.x; + var oy = Math.round(this.y) - this.y; + if (cur_frame.spritesheeted) + glw.quadTex(q.tlx + ox, q.tly + oy, q.trx + ox, q.try_ + oy, q.brx + ox, q.bry + oy, q.blx + ox, q.bly + oy, cur_frame.sheetTex); + else + glw.quad(q.tlx + ox, q.tly + oy, q.trx + ox, q.try_ + oy, q.brx + ox, q.bry + oy, q.blx + ox, q.bly + oy); + } + else + { + if (cur_frame.spritesheeted) + glw.quadTex(q.tlx, q.tly, q.trx, q.try_, q.brx, q.bry, q.blx, q.bly, cur_frame.sheetTex); + else + glw.quad(q.tlx, q.tly, q.trx, q.try_, q.brx, q.bry, q.blx, q.bly); + } + }; + instanceProto.getImagePointIndexByName = function(name_) + { + var cur_frame = this.curFrame; + var i, len; + for (i = 0, len = cur_frame.image_points.length; i < len; i++) + { + if (cr.equals_nocase(name_, cur_frame.image_points[i][0])) + return i; + } + return -1; + }; + instanceProto.getImagePoint = function(imgpt, getX) + { + var cur_frame = this.curFrame; + var image_points = cur_frame.image_points; + var index; + if (cr.is_string(imgpt)) + index = this.getImagePointIndexByName(imgpt); + else + index = imgpt - 1; // 0 is origin + index = cr.floor(index); + if (index < 0 || index >= image_points.length) + return getX ? this.x : this.y; // return origin + var x = (image_points[index][1] - cur_frame.hotspotX) * this.width; + var y = image_points[index][2]; + y = (y - cur_frame.hotspotY) * this.height; + var cosa = Math.cos(this.angle); + var sina = Math.sin(this.angle); + var x_temp = (x * cosa) - (y * sina); + y = (y * cosa) + (x * sina); + x = x_temp; + x += this.x; + y += this.y; + return getX ? x : y; + }; + function Cnds() {}; + var arrCache = []; + function allocArr() + { + if (arrCache.length) + return arrCache.pop(); + else + return [0, 0, 0]; + }; + function freeArr(a) + { + a[0] = 0; + a[1] = 0; + a[2] = 0; + arrCache.push(a); + }; + function makeCollKey(a, b) + { + if (a < b) + return "" + a + "," + b; + else + return "" + b + "," + a; + }; + function collmemory_add(collmemory, a, b, tickcount) + { + var a_uid = a.uid; + var b_uid = b.uid; + var key = makeCollKey(a_uid, b_uid); + if (collmemory.hasOwnProperty(key)) + { + collmemory[key][2] = tickcount; + return; + } + var arr = allocArr(); + arr[0] = a_uid; + arr[1] = b_uid; + arr[2] = tickcount; + collmemory[key] = arr; + }; + function collmemory_remove(collmemory, a, b) + { + var key = makeCollKey(a.uid, b.uid); + if (collmemory.hasOwnProperty(key)) + { + freeArr(collmemory[key]); + delete collmemory[key]; + } + }; + function collmemory_removeInstance(collmemory, inst) + { + var uid = inst.uid; + var p, entry; + for (p in collmemory) + { + if (collmemory.hasOwnProperty(p)) + { + entry = collmemory[p]; + if (entry[0] === uid || entry[1] === uid) + { + freeArr(collmemory[p]); + delete collmemory[p]; + } + } + } + }; + var last_coll_tickcount = -2; + function collmemory_has(collmemory, a, b) + { + var key = makeCollKey(a.uid, b.uid); + if (collmemory.hasOwnProperty(key)) + { + last_coll_tickcount = collmemory[key][2]; + return true; + } + else + { + last_coll_tickcount = -2; + return false; + } + }; + var candidates1 = []; + Cnds.prototype.OnCollision = function (rtype) + { + if (!rtype) + return false; + var runtime = this.runtime; + var cnd = runtime.getCurrentCondition(); + var ltype = cnd.type; + var collmemory = null; + if (cnd.extra["collmemory"]) + { + collmemory = cnd.extra["collmemory"]; + } + else + { + collmemory = {}; + cnd.extra["collmemory"] = collmemory; + } + if (!cnd.extra["spriteCreatedDestroyCallback"]) + { + cnd.extra["spriteCreatedDestroyCallback"] = true; + runtime.addDestroyCallback(function(inst) { + collmemory_removeInstance(cnd.extra["collmemory"], inst); + }); + } + var lsol = ltype.getCurrentSol(); + var rsol = rtype.getCurrentSol(); + var linstances = lsol.getObjects(); + var rinstances; + var registeredInstances; + var l, linst, r, rinst; + var curlsol, currsol; + var tickcount = this.runtime.tickcount; + var lasttickcount = tickcount - 1; + var exists, run; + var current_event = runtime.getCurrentEventStack().current_event; + var orblock = current_event.orblock; + for (l = 0; l < linstances.length; l++) + { + linst = linstances[l]; + if (rsol.select_all) + { + linst.update_bbox(); + this.runtime.getCollisionCandidates(linst.layer, rtype, linst.bbox, candidates1); + rinstances = candidates1; + this.runtime.addRegisteredCollisionCandidates(linst, rtype, rinstances); + } + else + { + rinstances = rsol.getObjects(); + } + for (r = 0; r < rinstances.length; r++) + { + rinst = rinstances[r]; + if (runtime.testOverlap(linst, rinst) || runtime.checkRegisteredCollision(linst, rinst)) + { + exists = collmemory_has(collmemory, linst, rinst); + run = (!exists || (last_coll_tickcount < lasttickcount)); + collmemory_add(collmemory, linst, rinst, tickcount); + if (run) + { + runtime.pushCopySol(current_event.solModifiers); + curlsol = ltype.getCurrentSol(); + currsol = rtype.getCurrentSol(); + curlsol.select_all = false; + currsol.select_all = false; + if (ltype === rtype) + { + curlsol.instances.length = 2; // just use lsol, is same reference as rsol + curlsol.instances[0] = linst; + curlsol.instances[1] = rinst; + ltype.applySolToContainer(); + } + else + { + curlsol.instances.length = 1; + currsol.instances.length = 1; + curlsol.instances[0] = linst; + currsol.instances[0] = rinst; + ltype.applySolToContainer(); + rtype.applySolToContainer(); + } + current_event.retrigger(); + runtime.popSol(current_event.solModifiers); + } + } + else + { + collmemory_remove(collmemory, linst, rinst); + } + } + cr.clearArray(candidates1); + } + return false; + }; + var rpicktype = null; + var rtopick = new cr.ObjectSet(); + var needscollisionfinish = false; + var candidates2 = []; + var temp_bbox = new cr.rect(0, 0, 0, 0); + function DoOverlapCondition(rtype, offx, offy) + { + if (!rtype) + return false; + var do_offset = (offx !== 0 || offy !== 0); + var oldx, oldy, ret = false, r, lenr, rinst; + var cnd = this.runtime.getCurrentCondition(); + var ltype = cnd.type; + var inverted = cnd.inverted; + var rsol = rtype.getCurrentSol(); + var orblock = this.runtime.getCurrentEventStack().current_event.orblock; + var rinstances; + if (rsol.select_all) + { + this.update_bbox(); + temp_bbox.copy(this.bbox); + temp_bbox.offset(offx, offy); + this.runtime.getCollisionCandidates(this.layer, rtype, temp_bbox, candidates2); + rinstances = candidates2; + } + else if (orblock) + { + if (this.runtime.isCurrentConditionFirst() && !rsol.else_instances.length && rsol.instances.length) + rinstances = rsol.instances; + else + rinstances = rsol.else_instances; + } + else + { + rinstances = rsol.instances; + } + rpicktype = rtype; + needscollisionfinish = (ltype !== rtype && !inverted); + if (do_offset) + { + oldx = this.x; + oldy = this.y; + this.x += offx; + this.y += offy; + this.set_bbox_changed(); + } + for (r = 0, lenr = rinstances.length; r < lenr; r++) + { + rinst = rinstances[r]; + if (this.runtime.testOverlap(this, rinst)) + { + ret = true; + if (inverted) + break; + if (ltype !== rtype) + rtopick.add(rinst); + } + } + if (do_offset) + { + this.x = oldx; + this.y = oldy; + this.set_bbox_changed(); + } + cr.clearArray(candidates2); + return ret; + }; + typeProto.finish = function (do_pick) + { + if (!needscollisionfinish) + return; + if (do_pick) + { + var orblock = this.runtime.getCurrentEventStack().current_event.orblock; + var sol = rpicktype.getCurrentSol(); + var topick = rtopick.valuesRef(); + var i, len, inst; + if (sol.select_all) + { + sol.select_all = false; + cr.clearArray(sol.instances); + for (i = 0, len = topick.length; i < len; ++i) + { + sol.instances[i] = topick[i]; + } + if (orblock) + { + cr.clearArray(sol.else_instances); + for (i = 0, len = rpicktype.instances.length; i < len; ++i) + { + inst = rpicktype.instances[i]; + if (!rtopick.contains(inst)) + sol.else_instances.push(inst); + } + } + } + else + { + if (orblock) + { + var initsize = sol.instances.length; + for (i = 0, len = topick.length; i < len; ++i) + { + sol.instances[initsize + i] = topick[i]; + cr.arrayFindRemove(sol.else_instances, topick[i]); + } + } + else + { + cr.shallowAssignArray(sol.instances, topick); + } + } + rpicktype.applySolToContainer(); + } + rtopick.clear(); + needscollisionfinish = false; + }; + Cnds.prototype.IsOverlapping = function (rtype) + { + return DoOverlapCondition.call(this, rtype, 0, 0); + }; + Cnds.prototype.IsOverlappingOffset = function (rtype, offx, offy) + { + return DoOverlapCondition.call(this, rtype, offx, offy); + }; + Cnds.prototype.IsAnimPlaying = function (animname) + { + if (this.changeAnimName.length) + return cr.equals_nocase(this.changeAnimName, animname); + else + return cr.equals_nocase(this.cur_animation.name, animname); + }; + Cnds.prototype.CompareFrame = function (cmp, framenum) + { + return cr.do_cmp(this.cur_frame, cmp, framenum); + }; + Cnds.prototype.CompareAnimSpeed = function (cmp, x) + { + var s = (this.animForwards ? this.cur_anim_speed : -this.cur_anim_speed); + return cr.do_cmp(s, cmp, x); + }; + Cnds.prototype.OnAnimFinished = function (animname) + { + return cr.equals_nocase(this.animTriggerName, animname); + }; + Cnds.prototype.OnAnyAnimFinished = function () + { + return true; + }; + Cnds.prototype.OnFrameChanged = function () + { + return true; + }; + Cnds.prototype.IsMirrored = function () + { + return this.width < 0; + }; + Cnds.prototype.IsFlipped = function () + { + return this.height < 0; + }; + Cnds.prototype.OnURLLoaded = function () + { + return true; + }; + Cnds.prototype.IsCollisionEnabled = function () + { + return this.collisionsEnabled; + }; + pluginProto.cnds = new Cnds(); + function Acts() {}; + Acts.prototype.Spawn = function (obj, layer, imgpt) + { + if (!obj || !layer) + return; + var inst = this.runtime.createInstance(obj, layer, this.getImagePoint(imgpt, true), this.getImagePoint(imgpt, false)); + if (!inst) + return; + if (typeof inst.angle !== "undefined") + { + inst.angle = this.angle; + inst.set_bbox_changed(); + } + this.runtime.isInOnDestroy++; + var i, len, s; + this.runtime.trigger(Object.getPrototypeOf(obj.plugin).cnds.OnCreated, inst); + if (inst.is_contained) + { + for (i = 0, len = inst.siblings.length; i < len; i++) + { + s = inst.siblings[i]; + this.runtime.trigger(Object.getPrototypeOf(s.type.plugin).cnds.OnCreated, s); + } + } + this.runtime.isInOnDestroy--; + var cur_act = this.runtime.getCurrentAction(); + var reset_sol = false; + if (cr.is_undefined(cur_act.extra["Spawn_LastExec"]) || cur_act.extra["Spawn_LastExec"] < this.runtime.execcount) + { + reset_sol = true; + cur_act.extra["Spawn_LastExec"] = this.runtime.execcount; + } + var sol; + if (obj != this.type) + { + sol = obj.getCurrentSol(); + sol.select_all = false; + if (reset_sol) + { + cr.clearArray(sol.instances); + sol.instances[0] = inst; + } + else + sol.instances.push(inst); + if (inst.is_contained) + { + for (i = 0, len = inst.siblings.length; i < len; i++) + { + s = inst.siblings[i]; + sol = s.type.getCurrentSol(); + sol.select_all = false; + if (reset_sol) + { + cr.clearArray(sol.instances); + sol.instances[0] = s; + } + else + sol.instances.push(s); + } + } + } + }; + Acts.prototype.SetEffect = function (effect) + { + this.blend_mode = effect; + this.compositeOp = cr.effectToCompositeOp(effect); + cr.setGLBlend(this, effect, this.runtime.gl); + this.runtime.redraw = true; + }; + Acts.prototype.StopAnim = function () + { + this.animPlaying = false; + }; + Acts.prototype.StartAnim = function (from) + { + this.animPlaying = true; + this.frameStart = this.getNowTime(); + if (from === 1 && this.cur_frame !== 0) + { + this.changeAnimFrame = 0; + if (!this.inAnimTrigger) + this.doChangeAnimFrame(); + } + if (!this.isTicking) + { + this.runtime.tickMe(this); + this.isTicking = true; + } + }; + Acts.prototype.SetAnim = function (animname, from) + { + this.changeAnimName = animname; + this.changeAnimFrom = from; + if (!this.isTicking) + { + this.runtime.tickMe(this); + this.isTicking = true; + } + if (!this.inAnimTrigger) + this.doChangeAnim(); + }; + Acts.prototype.SetAnimFrame = function (framenumber) + { + this.changeAnimFrame = framenumber; + if (!this.isTicking) + { + this.runtime.tickMe(this); + this.isTicking = true; + } + if (!this.inAnimTrigger) + this.doChangeAnimFrame(); + }; + Acts.prototype.SetAnimSpeed = function (s) + { + this.cur_anim_speed = cr.abs(s); + this.animForwards = (s >= 0); + if (!this.isTicking) + { + this.runtime.tickMe(this); + this.isTicking = true; + } + }; + Acts.prototype.SetAnimRepeatToFrame = function (s) + { + s = Math.floor(s); + if (s < 0) + s = 0; + if (s >= this.cur_animation.frames.length) + s = this.cur_animation.frames.length - 1; + this.cur_anim_repeatto = s; + }; + Acts.prototype.SetMirrored = function (m) + { + var neww = cr.abs(this.width) * (m === 0 ? -1 : 1); + if (this.width === neww) + return; + this.width = neww; + this.set_bbox_changed(); + }; + Acts.prototype.SetFlipped = function (f) + { + var newh = cr.abs(this.height) * (f === 0 ? -1 : 1); + if (this.height === newh) + return; + this.height = newh; + this.set_bbox_changed(); + }; + Acts.prototype.SetScale = function (s) + { + var cur_frame = this.curFrame; + var mirror_factor = (this.width < 0 ? -1 : 1); + var flip_factor = (this.height < 0 ? -1 : 1); + var new_width = cur_frame.width * s * mirror_factor; + var new_height = cur_frame.height * s * flip_factor; + if (this.width !== new_width || this.height !== new_height) + { + this.width = new_width; + this.height = new_height; + this.set_bbox_changed(); + } + }; + Acts.prototype.LoadURL = function (url_, resize_, crossOrigin_) + { + var img = new Image(); + var self = this; + var curFrame_ = this.curFrame; + img.onload = function () + { + if (curFrame_.texture_img.src === img.src) + { + if (self.runtime.glwrap && self.curFrame === curFrame_) + self.curWebGLTexture = curFrame_.webGL_texture; + if (resize_ === 0) // resize to image size + { + self.width = img.width; + self.height = img.height; + self.set_bbox_changed(); + } + self.runtime.redraw = true; + self.runtime.trigger(cr.plugins_.Sprite.prototype.cnds.OnURLLoaded, self); + return; + } + curFrame_.texture_img = img; + curFrame_.offx = 0; + curFrame_.offy = 0; + curFrame_.width = img.width; + curFrame_.height = img.height; + curFrame_.spritesheeted = false; + curFrame_.datauri = ""; + curFrame_.pixelformat = 0; // reset to RGBA, since we don't know what type of image will have come in + if (self.runtime.glwrap) + { + if (curFrame_.webGL_texture) + self.runtime.glwrap.deleteTexture(curFrame_.webGL_texture); + curFrame_.webGL_texture = self.runtime.glwrap.loadTexture(img, false, self.runtime.linearSampling); + if (self.curFrame === curFrame_) + self.curWebGLTexture = curFrame_.webGL_texture; + self.type.updateAllCurrentTexture(); + } + if (resize_ === 0) // resize to image size + { + self.width = img.width; + self.height = img.height; + self.set_bbox_changed(); + } + self.runtime.redraw = true; + self.runtime.trigger(cr.plugins_.Sprite.prototype.cnds.OnURLLoaded, self); + }; + if (url_.substr(0, 5) !== "data:" && crossOrigin_ === 0) + img["crossOrigin"] = "anonymous"; + this.runtime.setImageSrc(img, url_); + }; + Acts.prototype.SetCollisions = function (set_) + { + if (this.collisionsEnabled === (set_ !== 0)) + return; // no change + this.collisionsEnabled = (set_ !== 0); + if (this.collisionsEnabled) + this.set_bbox_changed(); // needs to be added back to cells + else + { + if (this.collcells.right >= this.collcells.left) + this.type.collision_grid.update(this, this.collcells, null); + this.collcells.set(0, 0, -1, -1); + } + }; + pluginProto.acts = new Acts(); + function Exps() {}; + Exps.prototype.AnimationFrame = function (ret) + { + ret.set_int(this.cur_frame); + }; + Exps.prototype.AnimationFrameCount = function (ret) + { + ret.set_int(this.cur_animation.frames.length); + }; + Exps.prototype.AnimationName = function (ret) + { + ret.set_string(this.cur_animation.name); + }; + Exps.prototype.AnimationSpeed = function (ret) + { + ret.set_float(this.animForwards ? this.cur_anim_speed : -this.cur_anim_speed); + }; + Exps.prototype.ImagePointX = function (ret, imgpt) + { + ret.set_float(this.getImagePoint(imgpt, true)); + }; + Exps.prototype.ImagePointY = function (ret, imgpt) + { + ret.set_float(this.getImagePoint(imgpt, false)); + }; + Exps.prototype.ImagePointCount = function (ret) + { + ret.set_int(this.curFrame.image_points.length); + }; + Exps.prototype.ImageWidth = function (ret) + { + ret.set_float(this.curFrame.width); + }; + Exps.prototype.ImageHeight = function (ret) + { + ret.set_float(this.curFrame.height); + }; + pluginProto.exps = new Exps(); +}()); +/* global cr,log,assert2 */ +/* jshint globalstrict: true */ +/* jshint strict: true */ +; +; +var jText = ''; +cr.plugins_.SpriteFontPlus = function(runtime) +{ + this.runtime = runtime; +}; +(function () +{ + var pluginProto = cr.plugins_.SpriteFontPlus.prototype; + pluginProto.onCreate = function () + { + }; + pluginProto.Type = function(plugin) + { + this.plugin = plugin; + this.runtime = plugin.runtime; + }; + var typeProto = pluginProto.Type.prototype; + typeProto.onCreate = function() + { + if (this.is_family) + return; + this.texture_img = new Image(); + this.texture_img["idtkLoadDisposed"] = true; + this.texture_img.src = this.texture_file; + this.runtime.wait_for_textures.push(this.texture_img); + this.webGL_texture = null; + }; + typeProto.onLostWebGLContext = function () + { + if (this.is_family) + return; + this.webGL_texture = null; + }; + typeProto.onRestoreWebGLContext = function () + { + if (this.is_family || !this.instances.length) + return; + if (!this.webGL_texture) + { + this.webGL_texture = this.runtime.glwrap.loadTexture(this.texture_img, false, this.runtime.linearSampling, this.texture_pixelformat); + } + var i, len; + for (i = 0, len = this.instances.length; i < len; i++) + this.instances[i].webGL_texture = this.webGL_texture; + }; + typeProto.unloadTextures = function () + { + if (this.is_family || this.instances.length || !this.webGL_texture) + return; + this.runtime.glwrap.deleteTexture(this.webGL_texture); + this.webGL_texture = null; + }; + typeProto.preloadCanvas2D = function (ctx) + { + ctx.drawImage(this.texture_img, 0, 0); + }; + pluginProto.Instance = function(type) + { + this.type = type; + this.runtime = type.runtime; + }; + var instanceProto = pluginProto.Instance.prototype; + instanceProto.onDestroy = function() + { + freeAllLines (this.lines); + freeAllClip (this.clipList); + freeAllClipUV(this.clipUV); + cr.wipe(this.characterWidthList); + }; + instanceProto.onCreate = function() + { + this.texture_img = this.type.texture_img; + this.characterWidth = this.properties[0]; + this.characterHeight = this.properties[1]; + this.characterSet = this.properties[2]; + this.text = this.properties[3]; + this.characterScale = this.properties[4]; + this.visible = (this.properties[5] === 0); // 0=visible, 1=invisible + this.halign = this.properties[6]/2.0; // 0=left, 1=center, 2=right + this.valign = this.properties[7]/2.0; // 0=top, 1=center, 2=bottom + this.wrapbyword = (this.properties[9] === 0); // 0=word, 1=character + this.characterSpacing = this.properties[10]; + this.lineHeight = this.properties[11]; + this.textWidth = 0; + this.textHeight = 0; + this.charWidthJSON = this.properties[12]; + this.spaceWidth = this.properties[13]; + console.log(this.charWidthJSON); + jText = this.charWidthJSON; + if (this.recycled) + { + this.lines.length = 0; + cr.wipe(this.clipList); + cr.wipe(this.clipUV); + cr.wipe(this.characterWidthList); + } + else + { + this.lines = []; + this.clipList = {}; + this.clipUV = {}; + this.characterWidthList = {}; + } + try{ + if(this.charWidthJSON){ + if(this.charWidthJSON.indexOf('""c2array""') !== -1) { + var jStr = jQuery.parseJSON(this.charWidthJSON.replace(/""/g,'"')); + var l = jStr.size[1]; + for(var s = 0; s < l; s++) { + var cs = jStr.data[1][s][0]; + var w = jStr.data[0][s][0]; + for(var c = 0; c < cs.length; c++) { + this.characterWidthList[cs.charAt(c)] = w + } + } + } else { + var jStr = jQuery.parseJSON(this.charWidthJSON); + var l = jStr.length; + for(var s = 0; s < l; s++) { + var cs = jStr[s][1]; + var w = jStr[s][0]; + for(var c = 0; c < cs.length; c++) { + this.characterWidthList[cs.charAt(c)] = w + } + } + } + } + if(this.spaceWidth !== -1) { + this.characterWidthList[' '] = this.spaceWidth; + } + } + catch(e){ + if(window.console && window.console.log) { + window.console.log('SpriteFont+ Failure: ' + e); + } + } + this.text_changed = true; + this.lastwrapwidth = this.width; + if (this.runtime.glwrap) + { + if (!this.type.webGL_texture) + { + this.type.webGL_texture = this.runtime.glwrap.loadTexture(this.type.texture_img, false, this.runtime.linearSampling, this.type.texture_pixelformat); + } + this.webGL_texture = this.type.webGL_texture; + } + this.SplitSheet(); + }; + instanceProto.saveToJSON = function () + { + var save = { + "t": this.text, + "csc": this.characterScale, + "csp": this.characterSpacing, + "lh": this.lineHeight, + "tw": this.textWidth, + "th": this.textHeight, + "lrt": this.last_render_tick, + "cw": {} + }; + for (var ch in this.characterWidthList) + save["cw"][ch] = this.characterWidthList[ch]; + return save; + }; + instanceProto.loadFromJSON = function (o) + { + this.text = o["t"]; + this.characterScale = o["csc"]; + this.characterSpacing = o["csp"]; + this.lineHeight = o["lh"]; + this.textWidth = o["tw"]; + this.textHeight = o["th"]; + this.last_render_tick = o["lrt"]; + for(var ch in o["cw"]) + this.characterWidthList[ch] = o["cw"][ch]; + this.text_changed = true; + this.lastwrapwidth = this.width; + }; + function trimRight(text) + { + return text.replace(/\s\s*$/, ''); + } + var MAX_CACHE_SIZE = 1000; + function alloc(cache,Constructor) + { + if (cache.length) + return cache.pop(); + else + return new Constructor(); + } + function free(cache,data) + { + if (cache.length < MAX_CACHE_SIZE) + { + cache.push(data); + } + } + function freeAll(cache,dataList,isArray) + { + if (isArray) { + var i, len; + for (i = 0, len = dataList.length; i < len; i++) + { + free(cache,dataList[i]); + } + dataList.length = 0; + } else { + var prop; + for(prop in dataList) { + if(Object.prototype.hasOwnProperty.call(dataList,prop)) { + free(cache,dataList[prop]); + delete dataList[prop]; + } + } + } + } + function addLine(inst,lineIndex,cur_line) { + var lines = inst.lines; + var line; + cur_line = trimRight(cur_line); + if (lineIndex >= lines.length) + lines.push(allocLine()); + line = lines[lineIndex]; + line.text = cur_line; + line.width = inst.measureWidth(cur_line); + inst.textWidth = cr.max(inst.textWidth,line.width); + } + var linesCache = []; + function allocLine() { return alloc(linesCache,Object); } + function freeLine(l) { free(linesCache,l); } + function freeAllLines(arr) { freeAll(linesCache,arr,true); } + function addClip(obj,property,x,y,w,h) { + if (obj[property] === undefined) { + obj[property] = alloc(clipCache,Object); + } + obj[property].x = x; + obj[property].y = y; + obj[property].w = w; + obj[property].h = h; + } + var clipCache = []; + function allocClip() { return alloc(clipCache,Object); } + function freeAllClip(obj) { freeAll(clipCache,obj,false);} + function addClipUV(obj,property,left,top,right,bottom) { + if (obj[property] === undefined) { + obj[property] = alloc(clipUVCache,cr.rect); + } + obj[property].left = left; + obj[property].top = top; + obj[property].right = right; + obj[property].bottom = bottom; + } + var clipUVCache = []; + function allocClipUV() { return alloc(clipUVCache,cr.rect);} + function freeAllClipUV(obj) { freeAll(clipUVCache,obj,false);} + instanceProto.SplitSheet = function() { + var texture = this.texture_img; + var texWidth = texture.width; + var texHeight = texture.height; + var charWidth = this.characterWidth; + var charHeight = this.characterHeight; + var charU = charWidth /texWidth; + var charV = charHeight/texHeight; + var charSet = this.characterSet ; + var cols = Math.floor(texWidth/charWidth); + var rows = Math.floor(texHeight/charHeight); + for ( var c = 0; c < charSet.length; c++) { + if (c >= cols * rows) break; + var x = c%cols; + var y = Math.floor(c/cols); + var letter = charSet.charAt(c); + if (this.runtime.glwrap) { + addClipUV( + this.clipUV, letter, + x * charU , + y * charV , + (x+1) * charU , + (y+1) * charV + ); + } else { + addClip( + this.clipList, letter, + x * charWidth, + y * charHeight, + charWidth, + charHeight + ); + } + } + }; + /* + * Word-Wrapping + */ + var wordsCache = []; + pluginProto.TokeniseWords = function (text) + { + wordsCache.length = 0; + var cur_word = ""; + var ch; + var i = 0; + while (i < text.length) + { + ch = text.charAt(i); + if (ch === "\n") + { + if (cur_word.length) + { + wordsCache.push(cur_word); + cur_word = ""; + } + wordsCache.push("\n"); + ++i; + } + else if (ch === " " || ch === "\t" || ch === "-") + { + do { + cur_word += text.charAt(i); + i++; + } + while (i < text.length && (text.charAt(i) === " " || text.charAt(i) === "\t")); + wordsCache.push(cur_word); + cur_word = ""; + } + else if (i < text.length) + { + cur_word += ch; + i++; + } + } + if (cur_word.length) + wordsCache.push(cur_word); + }; + pluginProto.WordWrap = function (inst) + { + var text = inst.text; + var lines = inst.lines; + if (!text || !text.length) + { + freeAllLines(lines); + return; + } + var width = inst.width; + if (width <= 2.0) + { + freeAllLines(lines); + return; + } + var charWidth = inst.characterWidth; + var charScale = inst.characterScale; + var charSpacing = inst.characterSpacing; + if ( (text.length * (charWidth * charScale + charSpacing) - charSpacing) <= width && text.indexOf("\n") === -1) + { + var all_width = inst.measureWidth(text); + if (all_width <= width) + { + freeAllLines(lines); + lines.push(allocLine()); + lines[0].text = text; + lines[0].width = all_width; + inst.textWidth = all_width; + inst.textHeight = inst.characterHeight * charScale + inst.lineHeight; + return; + } + } + var wrapbyword = inst.wrapbyword; + this.WrapText(inst); + inst.textHeight = lines.length * (inst.characterHeight * charScale + inst.lineHeight); + }; + pluginProto.WrapText = function (inst) + { + var wrapbyword = inst.wrapbyword; + var text = inst.text; + var lines = inst.lines; + var width = inst.width; + var wordArray; + if (wrapbyword) { + this.TokeniseWords(text); // writes to wordsCache + wordArray = wordsCache; + } else { + wordArray = text; + } + var cur_line = ""; + var prev_line; + var line_width; + var i; + var lineIndex = 0; + var line; + var ignore_newline = false; + for (i = 0; i < wordArray.length; i++) + { + if (wordArray[i] === "\n") + { + if (ignore_newline === true) { + ignore_newline = false; + } else { + addLine(inst,lineIndex,cur_line); + lineIndex++; + } + cur_line = ""; + continue; + } + ignore_newline = false; + prev_line = cur_line; + cur_line += wordArray[i]; + line_width = inst.measureWidth(trimRight(cur_line)); + if (line_width > width) + { + if (prev_line === "") { + addLine(inst,lineIndex,cur_line); + cur_line = ""; + ignore_newline = true; + } else { + addLine(inst,lineIndex,prev_line); + cur_line = wordArray[i]; + } + lineIndex++; + if (!wrapbyword && cur_line === " ") + cur_line = ""; + } + } + if (trimRight(cur_line).length) + { + addLine(inst,lineIndex,cur_line); + lineIndex++; + } + for (i = lineIndex; i < lines.length; i++) + freeLine(lines[i]); + lines.length = lineIndex; + }; + instanceProto.measureWidth = function(text) { + var spacing = this.characterSpacing; + var len = text.length; + var width = 0; + for (var i = 0; i < len; i++) { + width += this.getCharacterWidth(text.charAt(i)) * this.characterScale + spacing; + } + width -= (width > 0) ? spacing : 0; + return width; + }; + /***/ + instanceProto.getCharacterWidth = function(character) { + var widthList = this.characterWidthList; + if (widthList[character] !== undefined) { + return widthList[character]; + } else { + return this.characterWidth; + } + }; + instanceProto.rebuildText = function() { + if (this.text_changed || this.width !== this.lastwrapwidth) { + this.textWidth = 0; + this.textHeight = 0; + this.type.plugin.WordWrap(this); + this.text_changed = false; + this.lastwrapwidth = this.width; + } + }; + var EPSILON = 0.00001; + instanceProto.draw = function(ctx, glmode) + { + var texture = this.texture_img; + if (this.text !== "" && texture != null) { + this.rebuildText(); + if (this.height < this.characterHeight*this.characterScale + this.lineHeight) { + return; + } + ctx.globalAlpha = this.opacity; + var myx = this.x; + var myy = this.y; + if (this.runtime.pixel_rounding) + { + myx = (myx + 0.5) | 0; + myy = (myy + 0.5) | 0; + } + ctx.save(); + ctx.translate(myx, myy); + ctx.rotate(this.angle); + var ha = this.halign; + var va = this.valign; + var scale = this.characterScale; + var charHeight = this.characterHeight * scale; + var lineHeight = this.lineHeight; + var charSpace = this.characterSpacing; + var lines = this.lines; + var textHeight = this.textHeight; + var halign; + var valign = va * cr.max(0,(this.height - textHeight)); + var offx = -(this.hotspotX * this.width); + var offy = -(this.hotspotY * this.height); + offy += valign; + var drawX ; + var drawY = offy; + for(var i = 0; i < lines.length; i++) { + var line = lines[i].text; + var len = lines[i].width; + halign = ha * cr.max(0,this.width - len); + drawX = offx + halign; + drawY += lineHeight; + for(var j = 0; j < line.length; j++) { + var letter = line.charAt(j); + var clip = this.clipList[letter]; + if ( drawX + this.getCharacterWidth(letter) * scale > this.width + EPSILON ) { + break; + } + if (clip !== undefined) { + ctx.drawImage( this.texture_img, + clip.x, clip.y, clip.w, clip.h, + Math.round(drawX),Math.round(drawY),clip.w*scale,clip.h*scale); + } + drawX += this.getCharacterWidth(letter) * scale + charSpace; + } + drawY += charHeight; + if ( drawY + charHeight + lineHeight > this.height) { + break; + } + } + ctx.restore(); + } + }; + var dQuad = new cr.quad(); + function rotateQuad(quad,cosa,sina) { + var x_temp; + x_temp = (quad.tlx * cosa) - (quad.tly * sina); + quad.tly = (quad.tly * cosa) + (quad.tlx * sina); + quad.tlx = x_temp; + x_temp = (quad.trx * cosa) - (quad.try_ * sina); + quad.try_ = (quad.try_ * cosa) + (quad.trx * sina); + quad.trx = x_temp; + x_temp = (quad.blx * cosa) - (quad.bly * sina); + quad.bly = (quad.bly * cosa) + (quad.blx * sina); + quad.blx = x_temp; + x_temp = (quad.brx * cosa) - (quad.bry * sina); + quad.bry = (quad.bry * cosa) + (quad.brx * sina); + quad.brx = x_temp; + } + instanceProto.drawGL = function(glw) + { + glw.setTexture(this.webGL_texture); + glw.setOpacity(this.opacity); + if (this.text !== "") { + this.rebuildText(); + if (this.height < this.characterHeight*this.characterScale + this.lineHeight) { + return; + } + this.update_bbox(); + var q = this.bquad; + var ox = 0; + var oy = 0; + if (this.runtime.pixel_rounding) + { + ox = ((this.x + 0.5) | 0) - this.x; + oy = ((this.y + 0.5) | 0) - this.y; + } + var angle = this.angle; + var ha = this.halign; + var va = this.valign; + var scale = this.characterScale; + var charHeight = this.characterHeight * scale; // to precalculate in onCreate or on change + var lineHeight = this.lineHeight; + var charSpace = this.characterSpacing; + var lines = this.lines; + var textHeight = this.textHeight; + var cosa,sina; + if (angle !== 0) + { + cosa = Math.cos(angle); + sina = Math.sin(angle); + } + var halign; + var valign = va * cr.max(0,(this.height - textHeight)); + var offx = q.tlx + ox; + var offy = q.tly + oy; + var drawX ; + var drawY = valign; + for(var i = 0; i < lines.length; i++) { + var line = lines[i].text; + var lineWidth = lines[i].width; + halign = ha * cr.max(0,this.width - lineWidth); + drawX = halign; + drawY += lineHeight; + for(var j = 0; j < line.length; j++) { + var letter = line.charAt(j); + var clipUV = this.clipUV[letter]; + if ( drawX + this.getCharacterWidth(letter) * scale > this.width + EPSILON) { + break; + } + if (clipUV !== undefined) { + var clipWidth = this.characterWidth*scale; + var clipHeight = this.characterHeight*scale; + dQuad.tlx = drawX; + dQuad.tly = drawY; + dQuad.trx = drawX + clipWidth; + dQuad.try_ = drawY ; + dQuad.blx = drawX; + dQuad.bly = drawY + clipHeight; + dQuad.brx = drawX + clipWidth; + dQuad.bry = drawY + clipHeight; + if(angle !== 0) + { + rotateQuad(dQuad,cosa,sina); + } + dQuad.offset(offx,offy); + glw.quadTex( + dQuad.tlx, dQuad.tly, + dQuad.trx, dQuad.try_, + dQuad.brx, dQuad.bry, + dQuad.blx, dQuad.bly, + clipUV + ); + } + drawX += this.getCharacterWidth(letter) * scale + charSpace; + } + drawY += charHeight; + if ( drawY + charHeight + lineHeight > this.height) { + break; + } + } + } + }; + function Cnds() {} + Cnds.prototype.CompareText = function(text_to_compare, case_sensitive) + { + if (case_sensitive) + return this.text == text_to_compare; + else + return cr.equals_nocase(this.text, text_to_compare); + }; + pluginProto.cnds = new Cnds(); + function Acts() {} + Acts.prototype.SetText = function(param) + { + if (cr.is_number(param) && param < 1e9) + param = Math.round(param * 1e10) / 1e10; // round to nearest ten billionth - hides floating point errors + var text_to_set = param.toString(); + if (this.text !== text_to_set) + { + this.text = text_to_set; + this.text_changed = true; + this.runtime.redraw = true; + } + }; + Acts.prototype.AppendText = function(param) + { + if (cr.is_number(param)) + param = Math.round(param * 1e10) / 1e10; // round to nearest ten billionth - hides floating point errors + var text_to_append = param.toString(); + if (text_to_append) // not empty + { + this.text += text_to_append; + this.text_changed = true; + this.runtime.redraw = true; + } + }; + Acts.prototype.SetScale = function(param) + { + if (param !== this.characterScale) { + this.characterScale = param; + this.text_changed = true; + this.runtime.redraw = true; + } + }; + Acts.prototype.SetCharacterSpacing = function(param) + { + if (param !== this.CharacterSpacing) { + this.characterSpacing = param; + this.text_changed = true; + this.runtime.redraw = true; + } + }; + Acts.prototype.SetLineHeight = function(param) + { + if (param !== this.lineHeight) { + this.lineHeight = param; + this.text_changed = true; + this.runtime.redraw = true; + } + }; + instanceProto.SetCharWidth = function(character,width) { + var w = parseInt(width,10); + if (this.characterWidthList[character] !== w) { + this.characterWidthList[character] = w; + this.text_changed = true; + this.runtime.redraw = true; + } + }; + Acts.prototype.SetCharacterWidth = function(characterSet,width) + { + if (characterSet !== "") { + for(var c = 0; c < characterSet.length; c++) { + this.SetCharWidth(characterSet.charAt(c),width); + } + } + }; + Acts.prototype.SetEffect = function (effect) + { + this.compositeOp = cr.effectToCompositeOp(effect); + cr.setGLBlend(this, effect, this.runtime.gl); + this.runtime.redraw = true; + }; + pluginProto.acts = new Acts(); + function Exps() {} + Exps.prototype.CharacterWidth = function(ret,character) + { + ret.set_int(this.getCharacterWidth(character)); + }; + Exps.prototype.CharacterHeight = function(ret) + { + ret.set_int(this.characterHeight); + }; + Exps.prototype.CharacterScale = function(ret) + { + ret.set_float(this.characterScale); + }; + Exps.prototype.CharacterSpacing = function(ret) + { + ret.set_int(this.characterSpacing); + }; + Exps.prototype.LineHeight = function(ret) + { + ret.set_int(this.lineHeight); + }; + Exps.prototype.Text = function(ret) + { + ret.set_string(this.text); + }; + Exps.prototype.TextWidth = function (ret) + { + this.rebuildText(); + ret.set_float(this.textWidth); + }; + Exps.prototype.TextHeight = function (ret) + { + this.rebuildText(); + ret.set_float(this.textHeight); + }; + pluginProto.exps = new Exps(); +}()); +/* global cr,log,assert2 */ +/* jshint globalstrict: true */ +/* jshint strict: true */ +; +; +cr.plugins_.Spritefont2 = function(runtime) +{ + this.runtime = runtime; +}; +(function () +{ + var pluginProto = cr.plugins_.Spritefont2.prototype; + pluginProto.onCreate = function () + { + }; + pluginProto.Type = function(plugin) + { + this.plugin = plugin; + this.runtime = plugin.runtime; + }; + var typeProto = pluginProto.Type.prototype; + typeProto.onCreate = function() + { + if (this.is_family) + return; + this.texture_img = new Image(); + this.runtime.waitForImageLoad(this.texture_img, this.texture_file); + this.webGL_texture = null; + }; + typeProto.onLostWebGLContext = function () + { + if (this.is_family) + return; + this.webGL_texture = null; + }; + typeProto.onRestoreWebGLContext = function () + { + if (this.is_family || !this.instances.length) + return; + if (!this.webGL_texture) + { + this.webGL_texture = this.runtime.glwrap.loadTexture(this.texture_img, false, this.runtime.linearSampling, this.texture_pixelformat); + } + var i, len; + for (i = 0, len = this.instances.length; i < len; i++) + this.instances[i].webGL_texture = this.webGL_texture; + }; + typeProto.unloadTextures = function () + { + if (this.is_family || this.instances.length || !this.webGL_texture) + return; + this.runtime.glwrap.deleteTexture(this.webGL_texture); + this.webGL_texture = null; + }; + typeProto.preloadCanvas2D = function (ctx) + { + ctx.drawImage(this.texture_img, 0, 0); + }; + pluginProto.Instance = function(type) + { + this.type = type; + this.runtime = type.runtime; + }; + var instanceProto = pluginProto.Instance.prototype; + instanceProto.onDestroy = function() + { + freeAllLines (this.lines); + freeAllClip (this.clipList); + freeAllClipUV(this.clipUV); + cr.wipe(this.characterWidthList); + }; + instanceProto.onCreate = function() + { + this.texture_img = this.type.texture_img; + this.characterWidth = this.properties[0]; + this.characterHeight = this.properties[1]; + this.characterSet = this.properties[2]; + this.text = this.properties[3]; + this.characterScale = this.properties[4]; + this.visible = (this.properties[5] === 0); // 0=visible, 1=invisible + this.halign = this.properties[6]/2.0; // 0=left, 1=center, 2=right + this.valign = this.properties[7]/2.0; // 0=top, 1=center, 2=bottom + this.wrapbyword = (this.properties[9] === 0); // 0=word, 1=character + this.characterSpacing = this.properties[10]; + this.lineHeight = this.properties[11]; + this.textWidth = 0; + this.textHeight = 0; + if (this.recycled) + { + cr.clearArray(this.lines); + cr.wipe(this.clipList); + cr.wipe(this.clipUV); + cr.wipe(this.characterWidthList); + } + else + { + this.lines = []; + this.clipList = {}; + this.clipUV = {}; + this.characterWidthList = {}; + } + this.text_changed = true; + this.lastwrapwidth = this.width; + if (this.runtime.glwrap) + { + if (!this.type.webGL_texture) + { + this.type.webGL_texture = this.runtime.glwrap.loadTexture(this.type.texture_img, false, this.runtime.linearSampling, this.type.texture_pixelformat); + } + this.webGL_texture = this.type.webGL_texture; + } + this.SplitSheet(); + }; + instanceProto.saveToJSON = function () + { + var save = { + "t": this.text, + "csc": this.characterScale, + "csp": this.characterSpacing, + "lh": this.lineHeight, + "tw": this.textWidth, + "th": this.textHeight, + "lrt": this.last_render_tick, + "ha": this.halign, + "va": this.valign, + "cw": {} + }; + for (var ch in this.characterWidthList) + save["cw"][ch] = this.characterWidthList[ch]; + return save; + }; + instanceProto.loadFromJSON = function (o) + { + this.text = o["t"]; + this.characterScale = o["csc"]; + this.characterSpacing = o["csp"]; + this.lineHeight = o["lh"]; + this.textWidth = o["tw"]; + this.textHeight = o["th"]; + this.last_render_tick = o["lrt"]; + if (o.hasOwnProperty("ha")) + this.halign = o["ha"]; + if (o.hasOwnProperty("va")) + this.valign = o["va"]; + for(var ch in o["cw"]) + this.characterWidthList[ch] = o["cw"][ch]; + this.text_changed = true; + this.lastwrapwidth = this.width; + }; + function trimRight(text) + { + return text.replace(/\s\s*$/, ''); + } + var MAX_CACHE_SIZE = 1000; + function alloc(cache,Constructor) + { + if (cache.length) + return cache.pop(); + else + return new Constructor(); + } + function free(cache,data) + { + if (cache.length < MAX_CACHE_SIZE) + { + cache.push(data); + } + } + function freeAll(cache,dataList,isArray) + { + if (isArray) { + var i, len; + for (i = 0, len = dataList.length; i < len; i++) + { + free(cache,dataList[i]); + } + cr.clearArray(dataList); + } else { + var prop; + for(prop in dataList) { + if(Object.prototype.hasOwnProperty.call(dataList,prop)) { + free(cache,dataList[prop]); + delete dataList[prop]; + } + } + } + } + function addLine(inst,lineIndex,cur_line) { + var lines = inst.lines; + var line; + cur_line = trimRight(cur_line); + if (lineIndex >= lines.length) + lines.push(allocLine()); + line = lines[lineIndex]; + line.text = cur_line; + line.width = inst.measureWidth(cur_line); + inst.textWidth = cr.max(inst.textWidth,line.width); + } + var linesCache = []; + function allocLine() { return alloc(linesCache,Object); } + function freeLine(l) { free(linesCache,l); } + function freeAllLines(arr) { freeAll(linesCache,arr,true); } + function addClip(obj,property,x,y,w,h) { + if (obj[property] === undefined) { + obj[property] = alloc(clipCache,Object); + } + obj[property].x = x; + obj[property].y = y; + obj[property].w = w; + obj[property].h = h; + } + var clipCache = []; + function allocClip() { return alloc(clipCache,Object); } + function freeAllClip(obj) { freeAll(clipCache,obj,false);} + function addClipUV(obj,property,left,top,right,bottom) { + if (obj[property] === undefined) { + obj[property] = alloc(clipUVCache,cr.rect); + } + obj[property].left = left; + obj[property].top = top; + obj[property].right = right; + obj[property].bottom = bottom; + } + var clipUVCache = []; + function allocClipUV() { return alloc(clipUVCache,cr.rect);} + function freeAllClipUV(obj) { freeAll(clipUVCache,obj,false);} + instanceProto.SplitSheet = function() { + var texture = this.texture_img; + var texWidth = texture.width; + var texHeight = texture.height; + var charWidth = this.characterWidth; + var charHeight = this.characterHeight; + var charU = charWidth /texWidth; + var charV = charHeight/texHeight; + var charSet = this.characterSet ; + var cols = Math.floor(texWidth/charWidth); + var rows = Math.floor(texHeight/charHeight); + for ( var c = 0; c < charSet.length; c++) { + if (c >= cols * rows) break; + var x = c%cols; + var y = Math.floor(c/cols); + var letter = charSet.charAt(c); + if (this.runtime.glwrap) { + addClipUV( + this.clipUV, letter, + x * charU , + y * charV , + (x+1) * charU , + (y+1) * charV + ); + } else { + addClip( + this.clipList, letter, + x * charWidth, + y * charHeight, + charWidth, + charHeight + ); + } + } + }; + /* + * Word-Wrapping + */ + var wordsCache = []; + pluginProto.TokeniseWords = function (text) + { + cr.clearArray(wordsCache); + var cur_word = ""; + var ch; + var i = 0; + while (i < text.length) + { + ch = text.charAt(i); + if (ch === "\n") + { + if (cur_word.length) + { + wordsCache.push(cur_word); + cur_word = ""; + } + wordsCache.push("\n"); + ++i; + } + else if (ch === " " || ch === "\t" || ch === "-") + { + do { + cur_word += text.charAt(i); + i++; + } + while (i < text.length && (text.charAt(i) === " " || text.charAt(i) === "\t")); + wordsCache.push(cur_word); + cur_word = ""; + } + else if (i < text.length) + { + cur_word += ch; + i++; + } + } + if (cur_word.length) + wordsCache.push(cur_word); + }; + pluginProto.WordWrap = function (inst) + { + var text = inst.text; + var lines = inst.lines; + if (!text || !text.length) + { + freeAllLines(lines); + return; + } + var width = inst.width; + if (width <= 2.0) + { + freeAllLines(lines); + return; + } + var charWidth = inst.characterWidth; + var charScale = inst.characterScale; + var charSpacing = inst.characterSpacing; + if ( (text.length * (charWidth * charScale + charSpacing) - charSpacing) <= width && text.indexOf("\n") === -1) + { + var all_width = inst.measureWidth(text); + if (all_width <= width) + { + freeAllLines(lines); + lines.push(allocLine()); + lines[0].text = text; + lines[0].width = all_width; + inst.textWidth = all_width; + inst.textHeight = inst.characterHeight * charScale + inst.lineHeight; + return; + } + } + var wrapbyword = inst.wrapbyword; + this.WrapText(inst); + inst.textHeight = lines.length * (inst.characterHeight * charScale + inst.lineHeight); + }; + pluginProto.WrapText = function (inst) + { + var wrapbyword = inst.wrapbyword; + var text = inst.text; + var lines = inst.lines; + var width = inst.width; + var wordArray; + if (wrapbyword) { + this.TokeniseWords(text); // writes to wordsCache + wordArray = wordsCache; + } else { + wordArray = text; + } + var cur_line = ""; + var prev_line; + var line_width; + var i; + var lineIndex = 0; + var line; + var ignore_newline = false; + for (i = 0; i < wordArray.length; i++) + { + if (wordArray[i] === "\n") + { + if (ignore_newline === true) { + ignore_newline = false; + } else { + addLine(inst,lineIndex,cur_line); + lineIndex++; + } + cur_line = ""; + continue; + } + ignore_newline = false; + prev_line = cur_line; + cur_line += wordArray[i]; + line_width = inst.measureWidth(trimRight(cur_line)); + if (line_width > width) + { + if (prev_line === "") { + addLine(inst,lineIndex,cur_line); + cur_line = ""; + ignore_newline = true; + } else { + addLine(inst,lineIndex,prev_line); + cur_line = wordArray[i]; + } + lineIndex++; + if (!wrapbyword && cur_line === " ") + cur_line = ""; + } + } + if (trimRight(cur_line).length) + { + addLine(inst,lineIndex,cur_line); + lineIndex++; + } + for (i = lineIndex; i < lines.length; i++) + freeLine(lines[i]); + lines.length = lineIndex; + }; + instanceProto.measureWidth = function(text) { + var spacing = this.characterSpacing; + var len = text.length; + var width = 0; + for (var i = 0; i < len; i++) { + width += this.getCharacterWidth(text.charAt(i)) * this.characterScale + spacing; + } + width -= (width > 0) ? spacing : 0; + return width; + }; + /***/ + instanceProto.getCharacterWidth = function(character) { + var widthList = this.characterWidthList; + if (widthList[character] !== undefined) { + return widthList[character]; + } else { + return this.characterWidth; + } + }; + instanceProto.rebuildText = function() { + if (this.text_changed || this.width !== this.lastwrapwidth) { + this.textWidth = 0; + this.textHeight = 0; + this.type.plugin.WordWrap(this); + this.text_changed = false; + this.lastwrapwidth = this.width; + } + }; + var EPSILON = 0.00001; + instanceProto.draw = function(ctx, glmode) + { + var texture = this.texture_img; + if (this.text !== "" && texture != null) { + this.rebuildText(); + if (this.height < this.characterHeight*this.characterScale + this.lineHeight) { + return; + } + ctx.globalAlpha = this.opacity; + var myx = this.x; + var myy = this.y; + if (this.runtime.pixel_rounding) + { + myx = Math.round(myx); + myy = Math.round(myy); + } + var viewLeft = this.layer.viewLeft; + var viewTop = this.layer.viewTop; + var viewRight = this.layer.viewRight; + var viewBottom = this.layer.viewBottom; + ctx.save(); + ctx.translate(myx, myy); + ctx.rotate(this.angle); + var angle = this.angle; + var ha = this.halign; + var va = this.valign; + var scale = this.characterScale; + var charHeight = this.characterHeight * scale; + var lineHeight = this.lineHeight; + var charSpace = this.characterSpacing; + var lines = this.lines; + var textHeight = this.textHeight; + var letterWidth; + var halign; + var valign = va * cr.max(0,(this.height - textHeight)); + var offx = -(this.hotspotX * this.width); + var offy = -(this.hotspotY * this.height); + offy += valign; + var drawX ; + var drawY = offy; + var roundX, roundY; + for(var i = 0; i < lines.length; i++) { + var line = lines[i].text; + var len = lines[i].width; + halign = ha * cr.max(0,this.width - len); + drawX = offx + halign; + drawY += lineHeight; + if (angle === 0 && myy + drawY + charHeight < viewTop) + { + drawY += charHeight; + continue; + } + for(var j = 0; j < line.length; j++) { + var letter = line.charAt(j); + letterWidth = this.getCharacterWidth(letter); + var clip = this.clipList[letter]; + if (angle === 0 && myx + drawX + letterWidth * scale + charSpace < viewLeft) + { + drawX += letterWidth * scale + charSpace; + continue; + } + if ( drawX + letterWidth * scale > this.width + EPSILON ) { + break; + } + if (clip !== undefined) { + roundX = drawX; + roundY = drawY; + if (angle === 0 && scale === 1) + { + roundX = Math.round(roundX); + roundY = Math.round(roundY); + } + ctx.drawImage( this.texture_img, + clip.x, clip.y, clip.w, clip.h, + roundX,roundY,clip.w*scale,clip.h*scale); + } + drawX += letterWidth * scale + charSpace; + if (angle === 0 && myx + drawX > viewRight) + break; + } + drawY += charHeight; + if (angle === 0 && (drawY + charHeight + lineHeight > this.height || myy + drawY > viewBottom)) + { + break; + } + } + ctx.restore(); + } + }; + var dQuad = new cr.quad(); + function rotateQuad(quad,cosa,sina) { + var x_temp; + x_temp = (quad.tlx * cosa) - (quad.tly * sina); + quad.tly = (quad.tly * cosa) + (quad.tlx * sina); + quad.tlx = x_temp; + x_temp = (quad.trx * cosa) - (quad.try_ * sina); + quad.try_ = (quad.try_ * cosa) + (quad.trx * sina); + quad.trx = x_temp; + x_temp = (quad.blx * cosa) - (quad.bly * sina); + quad.bly = (quad.bly * cosa) + (quad.blx * sina); + quad.blx = x_temp; + x_temp = (quad.brx * cosa) - (quad.bry * sina); + quad.bry = (quad.bry * cosa) + (quad.brx * sina); + quad.brx = x_temp; + } + instanceProto.drawGL = function(glw) + { + glw.setTexture(this.webGL_texture); + glw.setOpacity(this.opacity); + if (!this.text) + return; + this.rebuildText(); + if (this.height < this.characterHeight*this.characterScale + this.lineHeight) { + return; + } + this.update_bbox(); + var q = this.bquad; + var ox = 0; + var oy = 0; + if (this.runtime.pixel_rounding) + { + ox = Math.round(this.x) - this.x; + oy = Math.round(this.y) - this.y; + } + var viewLeft = this.layer.viewLeft; + var viewTop = this.layer.viewTop; + var viewRight = this.layer.viewRight; + var viewBottom = this.layer.viewBottom; + var angle = this.angle; + var ha = this.halign; + var va = this.valign; + var scale = this.characterScale; + var charHeight = this.characterHeight * scale; // to precalculate in onCreate or on change + var lineHeight = this.lineHeight; + var charSpace = this.characterSpacing; + var lines = this.lines; + var textHeight = this.textHeight; + var letterWidth; + var cosa,sina; + if (angle !== 0) + { + cosa = Math.cos(angle); + sina = Math.sin(angle); + } + var halign; + var valign = va * cr.max(0,(this.height - textHeight)); + var offx = q.tlx + ox; + var offy = q.tly + oy; + var drawX ; + var drawY = valign; + var roundX, roundY; + for(var i = 0; i < lines.length; i++) { + var line = lines[i].text; + var lineWidth = lines[i].width; + halign = ha * cr.max(0,this.width - lineWidth); + drawX = halign; + drawY += lineHeight; + if (angle === 0 && offy + drawY + charHeight < viewTop) + { + drawY += charHeight; + continue; + } + for(var j = 0; j < line.length; j++) { + var letter = line.charAt(j); + letterWidth = this.getCharacterWidth(letter); + var clipUV = this.clipUV[letter]; + if (angle === 0 && offx + drawX + letterWidth * scale + charSpace < viewLeft) + { + drawX += letterWidth * scale + charSpace; + continue; + } + if (drawX + letterWidth * scale > this.width + EPSILON) + { + break; + } + if (clipUV !== undefined) { + var clipWidth = this.characterWidth*scale; + var clipHeight = this.characterHeight*scale; + roundX = drawX; + roundY = drawY; + if (angle === 0 && scale === 1) + { + roundX = Math.round(roundX); + roundY = Math.round(roundY); + } + dQuad.tlx = roundX; + dQuad.tly = roundY; + dQuad.trx = roundX + clipWidth; + dQuad.try_ = roundY ; + dQuad.blx = roundX; + dQuad.bly = roundY + clipHeight; + dQuad.brx = roundX + clipWidth; + dQuad.bry = roundY + clipHeight; + if(angle !== 0) + { + rotateQuad(dQuad,cosa,sina); + } + dQuad.offset(offx,offy); + glw.quadTex( + dQuad.tlx, dQuad.tly, + dQuad.trx, dQuad.try_, + dQuad.brx, dQuad.bry, + dQuad.blx, dQuad.bly, + clipUV + ); + } + drawX += letterWidth * scale + charSpace; + if (angle === 0 && offx + drawX > viewRight) + break; + } + drawY += charHeight; + if (angle === 0 && (drawY + charHeight + lineHeight > this.height || offy + drawY > viewBottom)) + { + break; + } + } + }; + function Cnds() {} + Cnds.prototype.CompareText = function(text_to_compare, case_sensitive) + { + if (case_sensitive) + return this.text == text_to_compare; + else + return cr.equals_nocase(this.text, text_to_compare); + }; + pluginProto.cnds = new Cnds(); + function Acts() {} + Acts.prototype.SetText = function(param) + { + if (cr.is_number(param) && param < 1e9) + param = Math.round(param * 1e10) / 1e10; // round to nearest ten billionth - hides floating point errors + var text_to_set = param.toString(); + if (this.text !== text_to_set) + { + this.text = text_to_set; + this.text_changed = true; + this.runtime.redraw = true; + } + }; + Acts.prototype.AppendText = function(param) + { + if (cr.is_number(param)) + param = Math.round(param * 1e10) / 1e10; // round to nearest ten billionth - hides floating point errors + var text_to_append = param.toString(); + if (text_to_append) // not empty + { + this.text += text_to_append; + this.text_changed = true; + this.runtime.redraw = true; + } + }; + Acts.prototype.SetScale = function(param) + { + if (param !== this.characterScale) { + this.characterScale = param; + this.text_changed = true; + this.runtime.redraw = true; + } + }; + Acts.prototype.SetCharacterSpacing = function(param) + { + if (param !== this.CharacterSpacing) { + this.characterSpacing = param; + this.text_changed = true; + this.runtime.redraw = true; + } + }; + Acts.prototype.SetLineHeight = function(param) + { + if (param !== this.lineHeight) { + this.lineHeight = param; + this.text_changed = true; + this.runtime.redraw = true; + } + }; + instanceProto.SetCharWidth = function(character,width) { + var w = parseInt(width,10); + if (this.characterWidthList[character] !== w) { + this.characterWidthList[character] = w; + this.text_changed = true; + this.runtime.redraw = true; + } + }; + Acts.prototype.SetCharacterWidth = function(characterSet,width) + { + if (characterSet !== "") { + for(var c = 0; c < characterSet.length; c++) { + this.SetCharWidth(characterSet.charAt(c),width); + } + } + }; + Acts.prototype.SetEffect = function (effect) + { + this.blend_mode = effect; + this.compositeOp = cr.effectToCompositeOp(effect); + cr.setGLBlend(this, effect, this.runtime.gl); + this.runtime.redraw = true; + }; + Acts.prototype.SetHAlign = function (a) + { + this.halign = a / 2.0; + this.text_changed = true; + this.runtime.redraw = true; + }; + Acts.prototype.SetVAlign = function (a) + { + this.valign = a / 2.0; + this.text_changed = true; + this.runtime.redraw = true; + }; + pluginProto.acts = new Acts(); + function Exps() {} + Exps.prototype.CharacterWidth = function(ret,character) + { + ret.set_int(this.getCharacterWidth(character)); + }; + Exps.prototype.CharacterHeight = function(ret) + { + ret.set_int(this.characterHeight); + }; + Exps.prototype.CharacterScale = function(ret) + { + ret.set_float(this.characterScale); + }; + Exps.prototype.CharacterSpacing = function(ret) + { + ret.set_int(this.characterSpacing); + }; + Exps.prototype.LineHeight = function(ret) + { + ret.set_int(this.lineHeight); + }; + Exps.prototype.Text = function(ret) + { + ret.set_string(this.text); + }; + Exps.prototype.TextWidth = function (ret) + { + this.rebuildText(); + ret.set_float(this.textWidth); + }; + Exps.prototype.TextHeight = function (ret) + { + this.rebuildText(); + ret.set_float(this.textHeight); + }; + pluginProto.exps = new Exps(); +}()); +; +; +cr.plugins_.Text = function(runtime) +{ + this.runtime = runtime; +}; +(function () +{ + var pluginProto = cr.plugins_.Text.prototype; + pluginProto.onCreate = function () + { + pluginProto.acts.SetWidth = function (w) + { + if (this.width !== w) + { + this.width = w; + this.text_changed = true; // also recalculate text wrapping + this.set_bbox_changed(); + } + }; + }; + pluginProto.Type = function(plugin) + { + this.plugin = plugin; + this.runtime = plugin.runtime; + }; + var typeProto = pluginProto.Type.prototype; + typeProto.onCreate = function() + { + }; + typeProto.onLostWebGLContext = function () + { + if (this.is_family) + return; + var i, len, inst; + for (i = 0, len = this.instances.length; i < len; i++) + { + inst = this.instances[i]; + inst.mycanvas = null; + inst.myctx = null; + inst.mytex = null; + } + }; + pluginProto.Instance = function(type) + { + this.type = type; + this.runtime = type.runtime; + if (this.recycled) + cr.clearArray(this.lines); + else + this.lines = []; // for word wrapping + this.text_changed = true; + }; + var instanceProto = pluginProto.Instance.prototype; + var requestedWebFonts = {}; // already requested web fonts have an entry here + instanceProto.onCreate = function() + { + this.text = this.properties[0]; + this.visible = (this.properties[1] === 0); // 0=visible, 1=invisible + this.font = this.properties[2]; + this.color = this.properties[3]; + this.halign = this.properties[4]; // 0=left, 1=center, 2=right + this.valign = this.properties[5]; // 0=top, 1=center, 2=bottom + this.wrapbyword = (this.properties[7] === 0); // 0=word, 1=character + this.lastwidth = this.width; + this.lastwrapwidth = this.width; + this.lastheight = this.height; + this.line_height_offset = this.properties[8]; + this.facename = ""; + this.fontstyle = ""; + this.ptSize = 0; + this.textWidth = 0; + this.textHeight = 0; + this.parseFont(); + this.mycanvas = null; + this.myctx = null; + this.mytex = null; + this.need_text_redraw = false; + this.last_render_tick = this.runtime.tickcount; + if (this.recycled) + this.rcTex.set(0, 0, 1, 1); + else + this.rcTex = new cr.rect(0, 0, 1, 1); + if (this.runtime.glwrap) + this.runtime.tickMe(this); +; + }; + instanceProto.parseFont = function () + { + var arr = this.font.split(" "); + var i; + for (i = 0; i < arr.length; i++) + { + if (arr[i].substr(arr[i].length - 2, 2) === "pt") + { + this.ptSize = parseInt(arr[i].substr(0, arr[i].length - 2)); + this.pxHeight = Math.ceil((this.ptSize / 72.0) * 96.0) + 4; // assume 96dpi... + if (i > 0) + this.fontstyle = arr[i - 1]; + this.facename = arr[i + 1]; + for (i = i + 2; i < arr.length; i++) + this.facename += " " + arr[i]; + break; + } + } + }; + instanceProto.saveToJSON = function () + { + return { + "t": this.text, + "f": this.font, + "c": this.color, + "ha": this.halign, + "va": this.valign, + "wr": this.wrapbyword, + "lho": this.line_height_offset, + "fn": this.facename, + "fs": this.fontstyle, + "ps": this.ptSize, + "pxh": this.pxHeight, + "tw": this.textWidth, + "th": this.textHeight, + "lrt": this.last_render_tick + }; + }; + instanceProto.loadFromJSON = function (o) + { + this.text = o["t"]; + this.font = o["f"]; + this.color = o["c"]; + this.halign = o["ha"]; + this.valign = o["va"]; + this.wrapbyword = o["wr"]; + this.line_height_offset = o["lho"]; + this.facename = o["fn"]; + this.fontstyle = o["fs"]; + this.ptSize = o["ps"]; + this.pxHeight = o["pxh"]; + this.textWidth = o["tw"]; + this.textHeight = o["th"]; + this.last_render_tick = o["lrt"]; + this.text_changed = true; + this.lastwidth = this.width; + this.lastwrapwidth = this.width; + this.lastheight = this.height; + }; + instanceProto.tick = function () + { + if (this.runtime.glwrap && this.mytex && (this.runtime.tickcount - this.last_render_tick >= 300)) + { + var layer = this.layer; + this.update_bbox(); + var bbox = this.bbox; + if (bbox.right < layer.viewLeft || bbox.bottom < layer.viewTop || bbox.left > layer.viewRight || bbox.top > layer.viewBottom) + { + this.runtime.glwrap.deleteTexture(this.mytex); + this.mytex = null; + this.myctx = null; + this.mycanvas = null; + } + } + }; + instanceProto.onDestroy = function () + { + this.myctx = null; + this.mycanvas = null; + if (this.runtime.glwrap && this.mytex) + this.runtime.glwrap.deleteTexture(this.mytex); + this.mytex = null; + }; + instanceProto.updateFont = function () + { + this.font = this.fontstyle + " " + this.ptSize.toString() + "pt " + this.facename; + this.text_changed = true; + this.runtime.redraw = true; + }; + instanceProto.draw = function(ctx, glmode) + { + ctx.font = this.font; + ctx.textBaseline = "top"; + ctx.fillStyle = this.color; + ctx.globalAlpha = glmode ? 1 : this.opacity; + var myscale = 1; + if (glmode) + { + myscale = Math.abs(this.layer.getScale()); + ctx.save(); + ctx.scale(myscale, myscale); + } + if (this.text_changed || this.width !== this.lastwrapwidth) + { + this.type.plugin.WordWrap(this.text, this.lines, ctx, this.width, this.wrapbyword); + this.text_changed = false; + this.lastwrapwidth = this.width; + } + this.update_bbox(); + var penX = glmode ? 0 : this.bquad.tlx; + var penY = glmode ? 0 : this.bquad.tly; + if (this.runtime.pixel_rounding) + { + penX = (penX + 0.5) | 0; + penY = (penY + 0.5) | 0; + } + if (this.angle !== 0 && !glmode) + { + ctx.save(); + ctx.translate(penX, penY); + ctx.rotate(this.angle); + penX = 0; + penY = 0; + } + var endY = penY + this.height; + var line_height = this.pxHeight; + line_height += this.line_height_offset; + var drawX; + var i; + if (this.valign === 1) // center + penY += Math.max(this.height / 2 - (this.lines.length * line_height) / 2, 0); + else if (this.valign === 2) // bottom + penY += Math.max(this.height - (this.lines.length * line_height) - 2, 0); + for (i = 0; i < this.lines.length; i++) + { + drawX = penX; + if (this.halign === 1) // center + drawX = penX + (this.width - this.lines[i].width) / 2; + else if (this.halign === 2) // right + drawX = penX + (this.width - this.lines[i].width); + ctx.fillText(this.lines[i].text, drawX, penY); + penY += line_height; + if (penY >= endY - line_height) + break; + } + if (this.angle !== 0 || glmode) + ctx.restore(); + this.last_render_tick = this.runtime.tickcount; + }; + instanceProto.drawGL = function(glw) + { + if (this.width < 1 || this.height < 1) + return; + var need_redraw = this.text_changed || this.need_text_redraw; + this.need_text_redraw = false; + var layer_scale = this.layer.getScale(); + var layer_angle = this.layer.getAngle(); + var rcTex = this.rcTex; + var floatscaledwidth = layer_scale * this.width; + var floatscaledheight = layer_scale * this.height; + var scaledwidth = Math.ceil(floatscaledwidth); + var scaledheight = Math.ceil(floatscaledheight); + var absscaledwidth = Math.abs(scaledwidth); + var absscaledheight = Math.abs(scaledheight); + var halfw = this.runtime.draw_width / 2; + var halfh = this.runtime.draw_height / 2; + if (!this.myctx) + { + this.mycanvas = document.createElement("canvas"); + this.mycanvas.width = absscaledwidth; + this.mycanvas.height = absscaledheight; + this.lastwidth = absscaledwidth; + this.lastheight = absscaledheight; + need_redraw = true; + this.myctx = this.mycanvas.getContext("2d"); + } + if (absscaledwidth !== this.lastwidth || absscaledheight !== this.lastheight) + { + this.mycanvas.width = absscaledwidth; + this.mycanvas.height = absscaledheight; + if (this.mytex) + { + glw.deleteTexture(this.mytex); + this.mytex = null; + } + need_redraw = true; + } + if (need_redraw) + { + this.myctx.clearRect(0, 0, absscaledwidth, absscaledheight); + this.draw(this.myctx, true); + if (!this.mytex) + this.mytex = glw.createEmptyTexture(absscaledwidth, absscaledheight, this.runtime.linearSampling, this.runtime.isMobile); + glw.videoToTexture(this.mycanvas, this.mytex, this.runtime.isMobile); + } + this.lastwidth = absscaledwidth; + this.lastheight = absscaledheight; + glw.setTexture(this.mytex); + glw.setOpacity(this.opacity); + glw.resetModelView(); + glw.translate(-halfw, -halfh); + glw.updateModelView(); + var q = this.bquad; + var tlx = this.layer.layerToCanvas(q.tlx, q.tly, true, true); + var tly = this.layer.layerToCanvas(q.tlx, q.tly, false, true); + var trx = this.layer.layerToCanvas(q.trx, q.try_, true, true); + var try_ = this.layer.layerToCanvas(q.trx, q.try_, false, true); + var brx = this.layer.layerToCanvas(q.brx, q.bry, true, true); + var bry = this.layer.layerToCanvas(q.brx, q.bry, false, true); + var blx = this.layer.layerToCanvas(q.blx, q.bly, true, true); + var bly = this.layer.layerToCanvas(q.blx, q.bly, false, true); + if (this.runtime.pixel_rounding || (this.angle === 0 && layer_angle === 0)) + { + var ox = ((tlx + 0.5) | 0) - tlx; + var oy = ((tly + 0.5) | 0) - tly + tlx += ox; + tly += oy; + trx += ox; + try_ += oy; + brx += ox; + bry += oy; + blx += ox; + bly += oy; + } + if (this.angle === 0 && layer_angle === 0) + { + trx = tlx + scaledwidth; + try_ = tly; + brx = trx; + bry = tly + scaledheight; + blx = tlx; + bly = bry; + rcTex.right = 1; + rcTex.bottom = 1; + } + else + { + rcTex.right = floatscaledwidth / scaledwidth; + rcTex.bottom = floatscaledheight / scaledheight; + } + glw.quadTex(tlx, tly, trx, try_, brx, bry, blx, bly, rcTex); + glw.resetModelView(); + glw.scale(layer_scale, layer_scale); + glw.rotateZ(-this.layer.getAngle()); + glw.translate((this.layer.viewLeft + this.layer.viewRight) / -2, (this.layer.viewTop + this.layer.viewBottom) / -2); + glw.updateModelView(); + this.last_render_tick = this.runtime.tickcount; + }; + var wordsCache = []; + pluginProto.TokeniseWords = function (text) + { + cr.clearArray(wordsCache); + var cur_word = ""; + var ch; + var i = 0; + while (i < text.length) + { + ch = text.charAt(i); + if (ch === "\n") + { + if (cur_word.length) + { + wordsCache.push(cur_word); + cur_word = ""; + } + wordsCache.push("\n"); + ++i; + } + else if (ch === " " || ch === "\t" || ch === "-") + { + do { + cur_word += text.charAt(i); + i++; + } + while (i < text.length && (text.charAt(i) === " " || text.charAt(i) === "\t")); + wordsCache.push(cur_word); + cur_word = ""; + } + else if (i < text.length) + { + cur_word += ch; + i++; + } + } + if (cur_word.length) + wordsCache.push(cur_word); + }; + var linesCache = []; + function allocLine() + { + if (linesCache.length) + return linesCache.pop(); + else + return {}; + }; + function freeLine(l) + { + linesCache.push(l); + }; + function freeAllLines(arr) + { + var i, len; + for (i = 0, len = arr.length; i < len; i++) + { + freeLine(arr[i]); + } + cr.clearArray(arr); + }; + pluginProto.WordWrap = function (text, lines, ctx, width, wrapbyword) + { + if (!text || !text.length) + { + freeAllLines(lines); + return; + } + if (width <= 2.0) + { + freeAllLines(lines); + return; + } + if (text.length <= 100 && text.indexOf("\n") === -1) + { + var all_width = ctx.measureText(text).width; + if (all_width <= width) + { + freeAllLines(lines); + lines.push(allocLine()); + lines[0].text = text; + lines[0].width = all_width; + return; + } + } + this.WrapText(text, lines, ctx, width, wrapbyword); + }; + function trimSingleSpaceRight(str) + { + if (!str.length || str.charAt(str.length - 1) !== " ") + return str; + return str.substring(0, str.length - 1); + }; + pluginProto.WrapText = function (text, lines, ctx, width, wrapbyword) + { + var wordArray; + if (wrapbyword) + { + this.TokeniseWords(text); // writes to wordsCache + wordArray = wordsCache; + } + else + wordArray = text; + var cur_line = ""; + var prev_line; + var line_width; + var i; + var lineIndex = 0; + var line; + for (i = 0; i < wordArray.length; i++) + { + if (wordArray[i] === "\n") + { + if (lineIndex >= lines.length) + lines.push(allocLine()); + cur_line = trimSingleSpaceRight(cur_line); // for correct center/right alignment + line = lines[lineIndex]; + line.text = cur_line; + line.width = ctx.measureText(cur_line).width; + lineIndex++; + cur_line = ""; + continue; + } + prev_line = cur_line; + cur_line += wordArray[i]; + line_width = ctx.measureText(cur_line).width; + if (line_width >= width) + { + if (lineIndex >= lines.length) + lines.push(allocLine()); + prev_line = trimSingleSpaceRight(prev_line); + line = lines[lineIndex]; + line.text = prev_line; + line.width = ctx.measureText(prev_line).width; + lineIndex++; + cur_line = wordArray[i]; + if (!wrapbyword && cur_line === " ") + cur_line = ""; + } + } + if (cur_line.length) + { + if (lineIndex >= lines.length) + lines.push(allocLine()); + cur_line = trimSingleSpaceRight(cur_line); + line = lines[lineIndex]; + line.text = cur_line; + line.width = ctx.measureText(cur_line).width; + lineIndex++; + } + for (i = lineIndex; i < lines.length; i++) + freeLine(lines[i]); + lines.length = lineIndex; + }; + function Cnds() {}; + Cnds.prototype.CompareText = function(text_to_compare, case_sensitive) + { + if (case_sensitive) + return this.text == text_to_compare; + else + return cr.equals_nocase(this.text, text_to_compare); + }; + pluginProto.cnds = new Cnds(); + function Acts() {}; + Acts.prototype.SetText = function(param) + { + if (cr.is_number(param) && param < 1e9) + param = Math.round(param * 1e10) / 1e10; // round to nearest ten billionth - hides floating point errors + var text_to_set = param.toString(); + if (this.text !== text_to_set) + { + this.text = text_to_set; + this.text_changed = true; + this.runtime.redraw = true; + } + }; + Acts.prototype.AppendText = function(param) + { + if (cr.is_number(param)) + param = Math.round(param * 1e10) / 1e10; // round to nearest ten billionth - hides floating point errors + var text_to_append = param.toString(); + if (text_to_append) // not empty + { + this.text += text_to_append; + this.text_changed = true; + this.runtime.redraw = true; + } + }; + Acts.prototype.SetFontFace = function (face_, style_) + { + var newstyle = ""; + switch (style_) { + case 1: newstyle = "bold"; break; + case 2: newstyle = "italic"; break; + case 3: newstyle = "bold italic"; break; + } + if (face_ === this.facename && newstyle === this.fontstyle) + return; // no change + this.facename = face_; + this.fontstyle = newstyle; + this.updateFont(); + }; + Acts.prototype.SetFontSize = function (size_) + { + if (this.ptSize === size_) + return; + this.ptSize = size_; + this.pxHeight = Math.ceil((this.ptSize / 72.0) * 96.0) + 4; // assume 96dpi... + this.updateFont(); + }; + Acts.prototype.SetFontColor = function (rgb) + { + var newcolor = "rgb(" + cr.GetRValue(rgb).toString() + "," + cr.GetGValue(rgb).toString() + "," + cr.GetBValue(rgb).toString() + ")"; + if (newcolor === this.color) + return; + this.color = newcolor; + this.need_text_redraw = true; + this.runtime.redraw = true; + }; + Acts.prototype.SetWebFont = function (familyname_, cssurl_) + { + if (this.runtime.isDomFree) + { + cr.logexport("[Construct 2] Text plugin: 'Set web font' not supported on this platform - the action has been ignored"); + return; // DC todo + } + var self = this; + var refreshFunc = (function () { + self.runtime.redraw = true; + self.text_changed = true; + }); + if (requestedWebFonts.hasOwnProperty(cssurl_)) + { + var newfacename = "'" + familyname_ + "'"; + if (this.facename === newfacename) + return; // no change + this.facename = newfacename; + this.updateFont(); + for (var i = 1; i < 10; i++) + { + setTimeout(refreshFunc, i * 100); + setTimeout(refreshFunc, i * 1000); + } + return; + } + var wf = document.createElement("link"); + wf.href = cssurl_; + wf.rel = "stylesheet"; + wf.type = "text/css"; + wf.onload = refreshFunc; + document.getElementsByTagName('head')[0].appendChild(wf); + requestedWebFonts[cssurl_] = true; + this.facename = "'" + familyname_ + "'"; + this.updateFont(); + for (var i = 1; i < 10; i++) + { + setTimeout(refreshFunc, i * 100); + setTimeout(refreshFunc, i * 1000); + } +; + }; + Acts.prototype.SetEffect = function (effect) + { + this.blend_mode = effect; + this.compositeOp = cr.effectToCompositeOp(effect); + cr.setGLBlend(this, effect, this.runtime.gl); + this.runtime.redraw = true; + }; + pluginProto.acts = new Acts(); + function Exps() {}; + Exps.prototype.Text = function(ret) + { + ret.set_string(this.text); + }; + Exps.prototype.FaceName = function (ret) + { + ret.set_string(this.facename); + }; + Exps.prototype.FaceSize = function (ret) + { + ret.set_int(this.ptSize); + }; + Exps.prototype.TextWidth = function (ret) + { + var w = 0; + var i, len, x; + for (i = 0, len = this.lines.length; i < len; i++) + { + x = this.lines[i].width; + if (w < x) + w = x; + } + ret.set_int(w); + }; + Exps.prototype.TextHeight = function (ret) + { + ret.set_int(this.lines.length * (this.pxHeight + this.line_height_offset) - this.line_height_offset); + }; + pluginProto.exps = new Exps(); +}()); +; +; +cr.plugins_.Touch = function(runtime) +{ + this.runtime = runtime; +}; +(function () +{ + var pluginProto = cr.plugins_.Touch.prototype; + pluginProto.Type = function(plugin) + { + this.plugin = plugin; + this.runtime = plugin.runtime; + }; + var typeProto = pluginProto.Type.prototype; + typeProto.onCreate = function() + { + }; + pluginProto.Instance = function(type) + { + this.type = type; + this.runtime = type.runtime; + this.touches = []; + this.mouseDown = false; + }; + var instanceProto = pluginProto.Instance.prototype; + var dummyoffset = {left: 0, top: 0}; + instanceProto.findTouch = function (id) + { + var i, len; + for (i = 0, len = this.touches.length; i < len; i++) + { + if (this.touches[i]["id"] === id) + return i; + } + return -1; + }; + var appmobi_accx = 0; + var appmobi_accy = 0; + var appmobi_accz = 0; + function AppMobiGetAcceleration(evt) + { + appmobi_accx = evt.x; + appmobi_accy = evt.y; + appmobi_accz = evt.z; + }; + var pg_accx = 0; + var pg_accy = 0; + var pg_accz = 0; + function PhoneGapGetAcceleration(evt) + { + pg_accx = evt.x; + pg_accy = evt.y; + pg_accz = evt.z; + }; + var theInstance = null; + var touchinfo_cache = []; + function AllocTouchInfo(x, y, id, index) + { + var ret; + if (touchinfo_cache.length) + ret = touchinfo_cache.pop(); + else + ret = new TouchInfo(); + ret.init(x, y, id, index); + return ret; + }; + function ReleaseTouchInfo(ti) + { + if (touchinfo_cache.length < 100) + touchinfo_cache.push(ti); + }; + var GESTURE_HOLD_THRESHOLD = 15; // max px motion for hold gesture to register + var GESTURE_HOLD_TIMEOUT = 500; // time for hold gesture to register + var GESTURE_TAP_TIMEOUT = 333; // time for tap gesture to register + var GESTURE_DOUBLETAP_THRESHOLD = 25; // max distance apart for taps to be + function TouchInfo() + { + this.starttime = 0; + this.time = 0; + this.lasttime = 0; + this.startx = 0; + this.starty = 0; + this.x = 0; + this.y = 0; + this.lastx = 0; + this.lasty = 0; + this["id"] = 0; + this.startindex = 0; + this.triggeredHold = false; + this.tooFarForHold = false; + }; + TouchInfo.prototype.init = function (x, y, id, index) + { + var nowtime = cr.performance_now(); + this.time = nowtime; + this.lasttime = nowtime; + this.starttime = nowtime; + this.startx = x; + this.starty = y; + this.x = x; + this.y = y; + this.lastx = x; + this.lasty = y; + this.width = 0; + this.height = 0; + this.pressure = 0; + this["id"] = id; + this.startindex = index; + this.triggeredHold = false; + this.tooFarForHold = false; + }; + TouchInfo.prototype.update = function (nowtime, x, y, width, height, pressure) + { + this.lasttime = this.time; + this.time = nowtime; + this.lastx = this.x; + this.lasty = this.y; + this.x = x; + this.y = y; + this.width = width; + this.height = height; + this.pressure = pressure; + if (!this.tooFarForHold && cr.distanceTo(this.startx, this.starty, this.x, this.y) >= GESTURE_HOLD_THRESHOLD) + { + this.tooFarForHold = true; + } + }; + TouchInfo.prototype.maybeTriggerHold = function (inst, index) + { + if (this.triggeredHold) + return; // already triggered this gesture + var nowtime = cr.performance_now(); + if (nowtime - this.starttime >= GESTURE_HOLD_TIMEOUT && !this.tooFarForHold && cr.distanceTo(this.startx, this.starty, this.x, this.y) < GESTURE_HOLD_THRESHOLD) + { + this.triggeredHold = true; + inst.trigger_index = this.startindex; + inst.trigger_id = this["id"]; + inst.getTouchIndex = index; + inst.runtime.trigger(cr.plugins_.Touch.prototype.cnds.OnHoldGesture, inst); + inst.curTouchX = this.x; + inst.curTouchY = this.y; + inst.runtime.trigger(cr.plugins_.Touch.prototype.cnds.OnHoldGestureObject, inst); + inst.getTouchIndex = 0; + } + }; + var lastTapX = -1000; + var lastTapY = -1000; + var lastTapTime = -10000; + TouchInfo.prototype.maybeTriggerTap = function (inst, index) + { + if (this.triggeredHold) + return; + var nowtime = cr.performance_now(); + if (nowtime - this.starttime <= GESTURE_TAP_TIMEOUT && !this.tooFarForHold && cr.distanceTo(this.startx, this.starty, this.x, this.y) < GESTURE_HOLD_THRESHOLD) + { + inst.trigger_index = this.startindex; + inst.trigger_id = this["id"]; + inst.getTouchIndex = index; + if ((nowtime - lastTapTime <= GESTURE_TAP_TIMEOUT * 2) && cr.distanceTo(lastTapX, lastTapY, this.x, this.y) < GESTURE_DOUBLETAP_THRESHOLD) + { + inst.runtime.trigger(cr.plugins_.Touch.prototype.cnds.OnDoubleTapGesture, inst); + inst.curTouchX = this.x; + inst.curTouchY = this.y; + inst.runtime.trigger(cr.plugins_.Touch.prototype.cnds.OnDoubleTapGestureObject, inst); + lastTapX = -1000; + lastTapY = -1000; + lastTapTime = -10000; + } + else + { + inst.runtime.trigger(cr.plugins_.Touch.prototype.cnds.OnTapGesture, inst); + inst.curTouchX = this.x; + inst.curTouchY = this.y; + inst.runtime.trigger(cr.plugins_.Touch.prototype.cnds.OnTapGestureObject, inst); + lastTapX = this.x; + lastTapY = this.y; + lastTapTime = nowtime; + } + inst.getTouchIndex = 0; + } + }; + instanceProto.onCreate = function() + { + theInstance = this; + this.isWindows8 = !!(typeof window["c2isWindows8"] !== "undefined" && window["c2isWindows8"]); + this.orient_alpha = 0; + this.orient_beta = 0; + this.orient_gamma = 0; + this.acc_g_x = 0; + this.acc_g_y = 0; + this.acc_g_z = 0; + this.acc_x = 0; + this.acc_y = 0; + this.acc_z = 0; + this.curTouchX = 0; + this.curTouchY = 0; + this.trigger_index = 0; + this.trigger_id = 0; + this.getTouchIndex = 0; + this.useMouseInput = (this.properties[0] !== 0); + var elem = (this.runtime.fullscreen_mode > 0) ? document : this.runtime.canvas; + var elem2 = document; + if (this.runtime.isDirectCanvas) + elem2 = elem = window["Canvas"]; + else if (this.runtime.isCocoonJs) + elem2 = elem = window; + var self = this; + if (typeof PointerEvent !== "undefined") + { + elem.addEventListener("pointerdown", + function(info) { + self.onPointerStart(info); + }, + false + ); + elem.addEventListener("pointermove", + function(info) { + self.onPointerMove(info); + }, + false + ); + elem2.addEventListener("pointerup", + function(info) { + self.onPointerEnd(info, false); + }, + false + ); + elem2.addEventListener("pointercancel", + function(info) { + self.onPointerEnd(info, true); + }, + false + ); + if (this.runtime.canvas) + { + this.runtime.canvas.addEventListener("MSGestureHold", function(e) { + e.preventDefault(); + }, false); + document.addEventListener("MSGestureHold", function(e) { + e.preventDefault(); + }, false); + this.runtime.canvas.addEventListener("gesturehold", function(e) { + e.preventDefault(); + }, false); + document.addEventListener("gesturehold", function(e) { + e.preventDefault(); + }, false); + } + } + else if (window.navigator["msPointerEnabled"]) + { + elem.addEventListener("MSPointerDown", + function(info) { + self.onPointerStart(info); + }, + false + ); + elem.addEventListener("MSPointerMove", + function(info) { + self.onPointerMove(info); + }, + false + ); + elem2.addEventListener("MSPointerUp", + function(info) { + self.onPointerEnd(info, false); + }, + false + ); + elem2.addEventListener("MSPointerCancel", + function(info) { + self.onPointerEnd(info, true); + }, + false + ); + if (this.runtime.canvas) + { + this.runtime.canvas.addEventListener("MSGestureHold", function(e) { + e.preventDefault(); + }, false); + document.addEventListener("MSGestureHold", function(e) { + e.preventDefault(); + }, false); + } + } + else + { + elem.addEventListener("touchstart", + function(info) { + self.onTouchStart(info); + }, + false + ); + elem.addEventListener("touchmove", + function(info) { + self.onTouchMove(info); + }, + false + ); + elem2.addEventListener("touchend", + function(info) { + self.onTouchEnd(info, false); + }, + false + ); + elem2.addEventListener("touchcancel", + function(info) { + self.onTouchEnd(info, true); + }, + false + ); + } + if (this.isWindows8) + { + var win8accelerometerFn = function(e) { + var reading = e["reading"]; + self.acc_x = reading["accelerationX"]; + self.acc_y = reading["accelerationY"]; + self.acc_z = reading["accelerationZ"]; + }; + var win8inclinometerFn = function(e) { + var reading = e["reading"]; + self.orient_alpha = reading["yawDegrees"]; + self.orient_beta = reading["pitchDegrees"]; + self.orient_gamma = reading["rollDegrees"]; + }; + var accelerometer = Windows["Devices"]["Sensors"]["Accelerometer"]["getDefault"](); + if (accelerometer) + { + accelerometer["reportInterval"] = Math.max(accelerometer["minimumReportInterval"], 16); + accelerometer.addEventListener("readingchanged", win8accelerometerFn); + } + var inclinometer = Windows["Devices"]["Sensors"]["Inclinometer"]["getDefault"](); + if (inclinometer) + { + inclinometer["reportInterval"] = Math.max(inclinometer["minimumReportInterval"], 16); + inclinometer.addEventListener("readingchanged", win8inclinometerFn); + } + document.addEventListener("visibilitychange", function(e) { + if (document["hidden"] || document["msHidden"]) + { + if (accelerometer) + accelerometer.removeEventListener("readingchanged", win8accelerometerFn); + if (inclinometer) + inclinometer.removeEventListener("readingchanged", win8inclinometerFn); + } + else + { + if (accelerometer) + accelerometer.addEventListener("readingchanged", win8accelerometerFn); + if (inclinometer) + inclinometer.addEventListener("readingchanged", win8inclinometerFn); + } + }, false); + } + else + { + window.addEventListener("deviceorientation", function (eventData) { + self.orient_alpha = eventData["alpha"] || 0; + self.orient_beta = eventData["beta"] || 0; + self.orient_gamma = eventData["gamma"] || 0; + }, false); + window.addEventListener("devicemotion", function (eventData) { + if (eventData["accelerationIncludingGravity"]) + { + self.acc_g_x = eventData["accelerationIncludingGravity"]["x"] || 0; + self.acc_g_y = eventData["accelerationIncludingGravity"]["y"] || 0; + self.acc_g_z = eventData["accelerationIncludingGravity"]["z"] || 0; + } + if (eventData["acceleration"]) + { + self.acc_x = eventData["acceleration"]["x"] || 0; + self.acc_y = eventData["acceleration"]["y"] || 0; + self.acc_z = eventData["acceleration"]["z"] || 0; + } + }, false); + } + if (this.useMouseInput && !this.runtime.isDomFree) + { + jQuery(document).mousemove( + function(info) { + self.onMouseMove(info); + } + ); + jQuery(document).mousedown( + function(info) { + self.onMouseDown(info); + } + ); + jQuery(document).mouseup( + function(info) { + self.onMouseUp(info); + } + ); + } + if (!this.runtime.isiOS && this.runtime.isCordova && navigator["accelerometer"] && navigator["accelerometer"]["watchAcceleration"]) + { + navigator["accelerometer"]["watchAcceleration"](PhoneGapGetAcceleration, null, { "frequency": 40 }); + } + this.runtime.tick2Me(this); + }; + instanceProto.onPointerMove = function (info) + { + if (info["pointerType"] === info["MSPOINTER_TYPE_MOUSE"] || info["pointerType"] === "mouse") + return; + if (info.preventDefault) + info.preventDefault(); + var i = this.findTouch(info["pointerId"]); + var nowtime = cr.performance_now(); + if (i >= 0) + { + var offset = this.runtime.isDomFree ? dummyoffset : jQuery(this.runtime.canvas).offset(); + var t = this.touches[i]; + if (nowtime - t.time < 2) + return; + t.update(nowtime, info.pageX - offset.left, info.pageY - offset.top, info.width || 0, info.height || 0, info.pressure || 0); + } + }; + instanceProto.onPointerStart = function (info) + { + if (info["pointerType"] === info["MSPOINTER_TYPE_MOUSE"] || info["pointerType"] === "mouse") + return; + if (info.preventDefault && cr.isCanvasInputEvent(info)) + info.preventDefault(); + var offset = this.runtime.isDomFree ? dummyoffset : jQuery(this.runtime.canvas).offset(); + var touchx = info.pageX - offset.left; + var touchy = info.pageY - offset.top; + var nowtime = cr.performance_now(); + this.trigger_index = this.touches.length; + this.trigger_id = info["pointerId"]; + this.touches.push(AllocTouchInfo(touchx, touchy, info["pointerId"], this.trigger_index)); + this.runtime.isInUserInputEvent = true; + this.runtime.trigger(cr.plugins_.Touch.prototype.cnds.OnNthTouchStart, this); + this.runtime.trigger(cr.plugins_.Touch.prototype.cnds.OnTouchStart, this); + this.curTouchX = touchx; + this.curTouchY = touchy; + this.runtime.trigger(cr.plugins_.Touch.prototype.cnds.OnTouchObject, this); + this.runtime.isInUserInputEvent = false; + }; + instanceProto.onPointerEnd = function (info, isCancel) + { + if (info["pointerType"] === info["MSPOINTER_TYPE_MOUSE"] || info["pointerType"] === "mouse") + return; + if (info.preventDefault && cr.isCanvasInputEvent(info)) + info.preventDefault(); + var i = this.findTouch(info["pointerId"]); + this.trigger_index = (i >= 0 ? this.touches[i].startindex : -1); + this.trigger_id = (i >= 0 ? this.touches[i]["id"] : -1); + this.runtime.isInUserInputEvent = true; + this.runtime.trigger(cr.plugins_.Touch.prototype.cnds.OnNthTouchEnd, this); + this.runtime.trigger(cr.plugins_.Touch.prototype.cnds.OnTouchEnd, this); + if (i >= 0) + { + if (!isCancel) + this.touches[i].maybeTriggerTap(this, i); + ReleaseTouchInfo(this.touches[i]); + this.touches.splice(i, 1); + } + this.runtime.isInUserInputEvent = false; + }; + instanceProto.onTouchMove = function (info) + { + if (info.preventDefault) + info.preventDefault(); + var nowtime = cr.performance_now(); + var i, len, t, u; + for (i = 0, len = info.changedTouches.length; i < len; i++) + { + t = info.changedTouches[i]; + var j = this.findTouch(t["identifier"]); + if (j >= 0) + { + var offset = this.runtime.isDomFree ? dummyoffset : jQuery(this.runtime.canvas).offset(); + u = this.touches[j]; + if (nowtime - u.time < 2) + continue; + var touchWidth = (t.radiusX || t.webkitRadiusX || t.mozRadiusX || t.msRadiusX || 0) * 2; + var touchHeight = (t.radiusY || t.webkitRadiusY || t.mozRadiusY || t.msRadiusY || 0) * 2; + var touchForce = t.force || t.webkitForce || t.mozForce || t.msForce || 0; + u.update(nowtime, t.pageX - offset.left, t.pageY - offset.top, touchWidth, touchHeight, touchForce); + } + } + }; + instanceProto.onTouchStart = function (info) + { + if (info.preventDefault && cr.isCanvasInputEvent(info)) + info.preventDefault(); + var offset = this.runtime.isDomFree ? dummyoffset : jQuery(this.runtime.canvas).offset(); + var nowtime = cr.performance_now(); + this.runtime.isInUserInputEvent = true; + var i, len, t, j; + for (i = 0, len = info.changedTouches.length; i < len; i++) + { + t = info.changedTouches[i]; + j = this.findTouch(t["identifier"]); + if (j !== -1) + continue; + var touchx = t.pageX - offset.left; + var touchy = t.pageY - offset.top; + this.trigger_index = this.touches.length; + this.trigger_id = t["identifier"]; + this.touches.push(AllocTouchInfo(touchx, touchy, t["identifier"], this.trigger_index)); + this.runtime.trigger(cr.plugins_.Touch.prototype.cnds.OnNthTouchStart, this); + this.runtime.trigger(cr.plugins_.Touch.prototype.cnds.OnTouchStart, this); + this.curTouchX = touchx; + this.curTouchY = touchy; + this.runtime.trigger(cr.plugins_.Touch.prototype.cnds.OnTouchObject, this); + } + this.runtime.isInUserInputEvent = false; + }; + instanceProto.onTouchEnd = function (info, isCancel) + { + if (info.preventDefault && cr.isCanvasInputEvent(info)) + info.preventDefault(); + this.runtime.isInUserInputEvent = true; + var i, len, t, j; + for (i = 0, len = info.changedTouches.length; i < len; i++) + { + t = info.changedTouches[i]; + j = this.findTouch(t["identifier"]); + if (j >= 0) + { + this.trigger_index = this.touches[j].startindex; + this.trigger_id = this.touches[j]["id"]; + this.runtime.trigger(cr.plugins_.Touch.prototype.cnds.OnNthTouchEnd, this); + this.runtime.trigger(cr.plugins_.Touch.prototype.cnds.OnTouchEnd, this); + if (!isCancel) + this.touches[j].maybeTriggerTap(this, j); + ReleaseTouchInfo(this.touches[j]); + this.touches.splice(j, 1); + } + } + this.runtime.isInUserInputEvent = false; + }; + instanceProto.getAlpha = function () + { + if (this.runtime.isCordova && this.orient_alpha === 0 && pg_accz !== 0) + return pg_accz * 90; + else + return this.orient_alpha; + }; + instanceProto.getBeta = function () + { + if (this.runtime.isCordova && this.orient_beta === 0 && pg_accy !== 0) + return pg_accy * 90; + else + return this.orient_beta; + }; + instanceProto.getGamma = function () + { + if (this.runtime.isCordova && this.orient_gamma === 0 && pg_accx !== 0) + return pg_accx * 90; + else + return this.orient_gamma; + }; + var noop_func = function(){}; + function isCompatibilityMouseEvent(e) + { + return (e["sourceCapabilities"] && e["sourceCapabilities"]["firesTouchEvents"]) || + (e.originalEvent && e.originalEvent["sourceCapabilities"] && e.originalEvent["sourceCapabilities"]["firesTouchEvents"]); + }; + instanceProto.onMouseDown = function(info) + { + if (isCompatibilityMouseEvent(info)) + return; + var t = { pageX: info.pageX, pageY: info.pageY, "identifier": 0 }; + var fakeinfo = { changedTouches: [t] }; + this.onTouchStart(fakeinfo); + this.mouseDown = true; + }; + instanceProto.onMouseMove = function(info) + { + if (!this.mouseDown) + return; + if (isCompatibilityMouseEvent(info)) + return; + var t = { pageX: info.pageX, pageY: info.pageY, "identifier": 0 }; + var fakeinfo = { changedTouches: [t] }; + this.onTouchMove(fakeinfo); + }; + instanceProto.onMouseUp = function(info) + { + if (info.preventDefault && this.runtime.had_a_click && !this.runtime.isMobile) + info.preventDefault(); + this.runtime.had_a_click = true; + if (isCompatibilityMouseEvent(info)) + return; + var t = { pageX: info.pageX, pageY: info.pageY, "identifier": 0 }; + var fakeinfo = { changedTouches: [t] }; + this.onTouchEnd(fakeinfo); + this.mouseDown = false; + }; + instanceProto.tick2 = function() + { + var i, len, t; + var nowtime = cr.performance_now(); + for (i = 0, len = this.touches.length; i < len; ++i) + { + t = this.touches[i]; + if (t.time <= nowtime - 50) + t.lasttime = nowtime; + t.maybeTriggerHold(this, i); + } + }; + function Cnds() {}; + Cnds.prototype.OnTouchStart = function () + { + return true; + }; + Cnds.prototype.OnTouchEnd = function () + { + return true; + }; + Cnds.prototype.IsInTouch = function () + { + return this.touches.length; + }; + Cnds.prototype.OnTouchObject = function (type) + { + if (!type) + return false; + return this.runtime.testAndSelectCanvasPointOverlap(type, this.curTouchX, this.curTouchY, false); + }; + var touching = []; + Cnds.prototype.IsTouchingObject = function (type) + { + if (!type) + return false; + var sol = type.getCurrentSol(); + var instances = sol.getObjects(); + var px, py; + var i, leni, j, lenj; + for (i = 0, leni = instances.length; i < leni; i++) + { + var inst = instances[i]; + inst.update_bbox(); + for (j = 0, lenj = this.touches.length; j < lenj; j++) + { + var touch = this.touches[j]; + px = inst.layer.canvasToLayer(touch.x, touch.y, true); + py = inst.layer.canvasToLayer(touch.x, touch.y, false); + if (inst.contains_pt(px, py)) + { + touching.push(inst); + break; + } + } + } + if (touching.length) + { + sol.select_all = false; + cr.shallowAssignArray(sol.instances, touching); + type.applySolToContainer(); + cr.clearArray(touching); + return true; + } + else + return false; + }; + Cnds.prototype.CompareTouchSpeed = function (index, cmp, s) + { + index = Math.floor(index); + if (index < 0 || index >= this.touches.length) + return false; + var t = this.touches[index]; + var dist = cr.distanceTo(t.x, t.y, t.lastx, t.lasty); + var timediff = (t.time - t.lasttime) / 1000; + var speed = 0; + if (timediff > 0) + speed = dist / timediff; + return cr.do_cmp(speed, cmp, s); + }; + Cnds.prototype.OrientationSupported = function () + { + return typeof window["DeviceOrientationEvent"] !== "undefined"; + }; + Cnds.prototype.MotionSupported = function () + { + return typeof window["DeviceMotionEvent"] !== "undefined"; + }; + Cnds.prototype.CompareOrientation = function (orientation_, cmp_, angle_) + { + var v = 0; + if (orientation_ === 0) + v = this.getAlpha(); + else if (orientation_ === 1) + v = this.getBeta(); + else + v = this.getGamma(); + return cr.do_cmp(v, cmp_, angle_); + }; + Cnds.prototype.CompareAcceleration = function (acceleration_, cmp_, angle_) + { + var v = 0; + if (acceleration_ === 0) + v = this.acc_g_x; + else if (acceleration_ === 1) + v = this.acc_g_y; + else if (acceleration_ === 2) + v = this.acc_g_z; + else if (acceleration_ === 3) + v = this.acc_x; + else if (acceleration_ === 4) + v = this.acc_y; + else if (acceleration_ === 5) + v = this.acc_z; + return cr.do_cmp(v, cmp_, angle_); + }; + Cnds.prototype.OnNthTouchStart = function (touch_) + { + touch_ = Math.floor(touch_); + return touch_ === this.trigger_index; + }; + Cnds.prototype.OnNthTouchEnd = function (touch_) + { + touch_ = Math.floor(touch_); + return touch_ === this.trigger_index; + }; + Cnds.prototype.HasNthTouch = function (touch_) + { + touch_ = Math.floor(touch_); + return this.touches.length >= touch_ + 1; + }; + Cnds.prototype.OnHoldGesture = function () + { + return true; + }; + Cnds.prototype.OnTapGesture = function () + { + return true; + }; + Cnds.prototype.OnDoubleTapGesture = function () + { + return true; + }; + Cnds.prototype.OnHoldGestureObject = function (type) + { + if (!type) + return false; + return this.runtime.testAndSelectCanvasPointOverlap(type, this.curTouchX, this.curTouchY, false); + }; + Cnds.prototype.OnTapGestureObject = function (type) + { + if (!type) + return false; + return this.runtime.testAndSelectCanvasPointOverlap(type, this.curTouchX, this.curTouchY, false); + }; + Cnds.prototype.OnDoubleTapGestureObject = function (type) + { + if (!type) + return false; + return this.runtime.testAndSelectCanvasPointOverlap(type, this.curTouchX, this.curTouchY, false); + }; + pluginProto.cnds = new Cnds(); + function Exps() {}; + Exps.prototype.TouchCount = function (ret) + { + ret.set_int(this.touches.length); + }; + Exps.prototype.X = function (ret, layerparam) + { + var index = this.getTouchIndex; + if (index < 0 || index >= this.touches.length) + { + ret.set_float(0); + return; + } + var layer, oldScale, oldZoomRate, oldParallaxX, oldAngle; + if (cr.is_undefined(layerparam)) + { + layer = this.runtime.getLayerByNumber(0); + oldScale = layer.scale; + oldZoomRate = layer.zoomRate; + oldParallaxX = layer.parallaxX; + oldAngle = layer.angle; + layer.scale = 1; + layer.zoomRate = 1.0; + layer.parallaxX = 1.0; + layer.angle = 0; + ret.set_float(layer.canvasToLayer(this.touches[index].x, this.touches[index].y, true)); + layer.scale = oldScale; + layer.zoomRate = oldZoomRate; + layer.parallaxX = oldParallaxX; + layer.angle = oldAngle; + } + else + { + if (cr.is_number(layerparam)) + layer = this.runtime.getLayerByNumber(layerparam); + else + layer = this.runtime.getLayerByName(layerparam); + if (layer) + ret.set_float(layer.canvasToLayer(this.touches[index].x, this.touches[index].y, true)); + else + ret.set_float(0); + } + }; + Exps.prototype.XAt = function (ret, index, layerparam) + { + index = Math.floor(index); + if (index < 0 || index >= this.touches.length) + { + ret.set_float(0); + return; + } + var layer, oldScale, oldZoomRate, oldParallaxX, oldAngle; + if (cr.is_undefined(layerparam)) + { + layer = this.runtime.getLayerByNumber(0); + oldScale = layer.scale; + oldZoomRate = layer.zoomRate; + oldParallaxX = layer.parallaxX; + oldAngle = layer.angle; + layer.scale = 1; + layer.zoomRate = 1.0; + layer.parallaxX = 1.0; + layer.angle = 0; + ret.set_float(layer.canvasToLayer(this.touches[index].x, this.touches[index].y, true)); + layer.scale = oldScale; + layer.zoomRate = oldZoomRate; + layer.parallaxX = oldParallaxX; + layer.angle = oldAngle; + } + else + { + if (cr.is_number(layerparam)) + layer = this.runtime.getLayerByNumber(layerparam); + else + layer = this.runtime.getLayerByName(layerparam); + if (layer) + ret.set_float(layer.canvasToLayer(this.touches[index].x, this.touches[index].y, true)); + else + ret.set_float(0); + } + }; + Exps.prototype.XForID = function (ret, id, layerparam) + { + var index = this.findTouch(id); + if (index < 0) + { + ret.set_float(0); + return; + } + var touch = this.touches[index]; + var layer, oldScale, oldZoomRate, oldParallaxX, oldAngle; + if (cr.is_undefined(layerparam)) + { + layer = this.runtime.getLayerByNumber(0); + oldScale = layer.scale; + oldZoomRate = layer.zoomRate; + oldParallaxX = layer.parallaxX; + oldAngle = layer.angle; + layer.scale = 1; + layer.zoomRate = 1.0; + layer.parallaxX = 1.0; + layer.angle = 0; + ret.set_float(layer.canvasToLayer(touch.x, touch.y, true)); + layer.scale = oldScale; + layer.zoomRate = oldZoomRate; + layer.parallaxX = oldParallaxX; + layer.angle = oldAngle; + } + else + { + if (cr.is_number(layerparam)) + layer = this.runtime.getLayerByNumber(layerparam); + else + layer = this.runtime.getLayerByName(layerparam); + if (layer) + ret.set_float(layer.canvasToLayer(touch.x, touch.y, true)); + else + ret.set_float(0); + } + }; + Exps.prototype.Y = function (ret, layerparam) + { + var index = this.getTouchIndex; + if (index < 0 || index >= this.touches.length) + { + ret.set_float(0); + return; + } + var layer, oldScale, oldZoomRate, oldParallaxY, oldAngle; + if (cr.is_undefined(layerparam)) + { + layer = this.runtime.getLayerByNumber(0); + oldScale = layer.scale; + oldZoomRate = layer.zoomRate; + oldParallaxY = layer.parallaxY; + oldAngle = layer.angle; + layer.scale = 1; + layer.zoomRate = 1.0; + layer.parallaxY = 1.0; + layer.angle = 0; + ret.set_float(layer.canvasToLayer(this.touches[index].x, this.touches[index].y, false)); + layer.scale = oldScale; + layer.zoomRate = oldZoomRate; + layer.parallaxY = oldParallaxY; + layer.angle = oldAngle; + } + else + { + if (cr.is_number(layerparam)) + layer = this.runtime.getLayerByNumber(layerparam); + else + layer = this.runtime.getLayerByName(layerparam); + if (layer) + ret.set_float(layer.canvasToLayer(this.touches[index].x, this.touches[index].y, false)); + else + ret.set_float(0); + } + }; + Exps.prototype.YAt = function (ret, index, layerparam) + { + index = Math.floor(index); + if (index < 0 || index >= this.touches.length) + { + ret.set_float(0); + return; + } + var layer, oldScale, oldZoomRate, oldParallaxY, oldAngle; + if (cr.is_undefined(layerparam)) + { + layer = this.runtime.getLayerByNumber(0); + oldScale = layer.scale; + oldZoomRate = layer.zoomRate; + oldParallaxY = layer.parallaxY; + oldAngle = layer.angle; + layer.scale = 1; + layer.zoomRate = 1.0; + layer.parallaxY = 1.0; + layer.angle = 0; + ret.set_float(layer.canvasToLayer(this.touches[index].x, this.touches[index].y, false)); + layer.scale = oldScale; + layer.zoomRate = oldZoomRate; + layer.parallaxY = oldParallaxY; + layer.angle = oldAngle; + } + else + { + if (cr.is_number(layerparam)) + layer = this.runtime.getLayerByNumber(layerparam); + else + layer = this.runtime.getLayerByName(layerparam); + if (layer) + ret.set_float(layer.canvasToLayer(this.touches[index].x, this.touches[index].y, false)); + else + ret.set_float(0); + } + }; + Exps.prototype.YForID = function (ret, id, layerparam) + { + var index = this.findTouch(id); + if (index < 0) + { + ret.set_float(0); + return; + } + var touch = this.touches[index]; + var layer, oldScale, oldZoomRate, oldParallaxY, oldAngle; + if (cr.is_undefined(layerparam)) + { + layer = this.runtime.getLayerByNumber(0); + oldScale = layer.scale; + oldZoomRate = layer.zoomRate; + oldParallaxY = layer.parallaxY; + oldAngle = layer.angle; + layer.scale = 1; + layer.zoomRate = 1.0; + layer.parallaxY = 1.0; + layer.angle = 0; + ret.set_float(layer.canvasToLayer(touch.x, touch.y, false)); + layer.scale = oldScale; + layer.zoomRate = oldZoomRate; + layer.parallaxY = oldParallaxY; + layer.angle = oldAngle; + } + else + { + if (cr.is_number(layerparam)) + layer = this.runtime.getLayerByNumber(layerparam); + else + layer = this.runtime.getLayerByName(layerparam); + if (layer) + ret.set_float(layer.canvasToLayer(touch.x, touch.y, false)); + else + ret.set_float(0); + } + }; + Exps.prototype.AbsoluteX = function (ret) + { + if (this.touches.length) + ret.set_float(this.touches[0].x); + else + ret.set_float(0); + }; + Exps.prototype.AbsoluteXAt = function (ret, index) + { + index = Math.floor(index); + if (index < 0 || index >= this.touches.length) + { + ret.set_float(0); + return; + } + ret.set_float(this.touches[index].x); + }; + Exps.prototype.AbsoluteXForID = function (ret, id) + { + var index = this.findTouch(id); + if (index < 0) + { + ret.set_float(0); + return; + } + var touch = this.touches[index]; + ret.set_float(touch.x); + }; + Exps.prototype.AbsoluteY = function (ret) + { + if (this.touches.length) + ret.set_float(this.touches[0].y); + else + ret.set_float(0); + }; + Exps.prototype.AbsoluteYAt = function (ret, index) + { + index = Math.floor(index); + if (index < 0 || index >= this.touches.length) + { + ret.set_float(0); + return; + } + ret.set_float(this.touches[index].y); + }; + Exps.prototype.AbsoluteYForID = function (ret, id) + { + var index = this.findTouch(id); + if (index < 0) + { + ret.set_float(0); + return; + } + var touch = this.touches[index]; + ret.set_float(touch.y); + }; + Exps.prototype.SpeedAt = function (ret, index) + { + index = Math.floor(index); + if (index < 0 || index >= this.touches.length) + { + ret.set_float(0); + return; + } + var t = this.touches[index]; + var dist = cr.distanceTo(t.x, t.y, t.lastx, t.lasty); + var timediff = (t.time - t.lasttime) / 1000; + if (timediff <= 0) + ret.set_float(0); + else + ret.set_float(dist / timediff); + }; + Exps.prototype.SpeedForID = function (ret, id) + { + var index = this.findTouch(id); + if (index < 0) + { + ret.set_float(0); + return; + } + var touch = this.touches[index]; + var dist = cr.distanceTo(touch.x, touch.y, touch.lastx, touch.lasty); + var timediff = (touch.time - touch.lasttime) / 1000; + if (timediff <= 0) + ret.set_float(0); + else + ret.set_float(dist / timediff); + }; + Exps.prototype.AngleAt = function (ret, index) + { + index = Math.floor(index); + if (index < 0 || index >= this.touches.length) + { + ret.set_float(0); + return; + } + var t = this.touches[index]; + ret.set_float(cr.to_degrees(cr.angleTo(t.lastx, t.lasty, t.x, t.y))); + }; + Exps.prototype.AngleForID = function (ret, id) + { + var index = this.findTouch(id); + if (index < 0) + { + ret.set_float(0); + return; + } + var touch = this.touches[index]; + ret.set_float(cr.to_degrees(cr.angleTo(touch.lastx, touch.lasty, touch.x, touch.y))); + }; + Exps.prototype.Alpha = function (ret) + { + ret.set_float(this.getAlpha()); + }; + Exps.prototype.Beta = function (ret) + { + ret.set_float(this.getBeta()); + }; + Exps.prototype.Gamma = function (ret) + { + ret.set_float(this.getGamma()); + }; + Exps.prototype.AccelerationXWithG = function (ret) + { + ret.set_float(this.acc_g_x); + }; + Exps.prototype.AccelerationYWithG = function (ret) + { + ret.set_float(this.acc_g_y); + }; + Exps.prototype.AccelerationZWithG = function (ret) + { + ret.set_float(this.acc_g_z); + }; + Exps.prototype.AccelerationX = function (ret) + { + ret.set_float(this.acc_x); + }; + Exps.prototype.AccelerationY = function (ret) + { + ret.set_float(this.acc_y); + }; + Exps.prototype.AccelerationZ = function (ret) + { + ret.set_float(this.acc_z); + }; + Exps.prototype.TouchIndex = function (ret) + { + ret.set_int(this.trigger_index); + }; + Exps.prototype.TouchID = function (ret) + { + ret.set_float(this.trigger_id); + }; + Exps.prototype.WidthForID = function (ret, id) + { + var index = this.findTouch(id); + if (index < 0) + { + ret.set_float(0); + return; + } + var touch = this.touches[index]; + ret.set_float(touch.width); + }; + Exps.prototype.HeightForID = function (ret, id) + { + var index = this.findTouch(id); + if (index < 0) + { + ret.set_float(0); + return; + } + var touch = this.touches[index]; + ret.set_float(touch.height); + }; + Exps.prototype.PressureForID = function (ret, id) + { + var index = this.findTouch(id); + if (index < 0) + { + ret.set_float(0); + return; + } + var touch = this.touches[index]; + ret.set_float(touch.pressure); + }; + pluginProto.exps = new Exps(); +}()); +; +; +cr.plugins_.cjs = function(runtime) +{ + this.runtime = runtime; +}; +(function () +{ + var pluginProto = cr.plugins_.cjs.prototype; + pluginProto.Type = function(plugin) + { + this.plugin = plugin; + this.runtime = plugin.runtime; + }; + var typeProto = pluginProto.Type.prototype; + typeProto.onCreate = function() + { + }; + pluginProto.Instance = function(type) + { + this.type = type; + this.runtime = type.runtime; + }; + var instanceProto = pluginProto.Instance.prototype; + instanceProto.onCreate = function() + { + this.nameOfExternalScript = this.properties[0]; + this.returnValue= ""; + var myScriptTag=document.createElement('script'); + myScriptTag.setAttribute("type","text/javascript"); + myScriptTag.setAttribute("src", this.nameOfExternalScript); + if (typeof myScriptTag != "undefined") + document.getElementsByTagName("head")[0].appendChild(myScriptTag); + }; + instanceProto.draw = function(ctx) + { + }; + pluginProto.cnds = {}; + var cnds = pluginProto.cnds; + pluginProto.acts = {}; + var acts = pluginProto.acts; + acts.ExecuteJS = function (myparam) + { + this.returnValue= ""; + try + { + this.returnValue= eval(myparam); + } catch(err) + { + this.returnValue= err; + } + }; + pluginProto.exps = {}; + var exps = pluginProto.exps; + exps.ReadExecutionReturn = function (ret) + { + ret.set_string(this.returnValue); + }; +}()); +; +; +cr.behaviors.Bullet = function(runtime) +{ + this.runtime = runtime; +}; +(function () +{ + var behaviorProto = cr.behaviors.Bullet.prototype; + behaviorProto.Type = function(behavior, objtype) + { + this.behavior = behavior; + this.objtype = objtype; + this.runtime = behavior.runtime; + }; + var behtypeProto = behaviorProto.Type.prototype; + behtypeProto.onCreate = function() + { + }; + behaviorProto.Instance = function(type, inst) + { + this.type = type; + this.behavior = type.behavior; + this.inst = inst; // associated object instance to modify + this.runtime = type.runtime; + }; + var behinstProto = behaviorProto.Instance.prototype; + behinstProto.onCreate = function() + { + var speed = this.properties[0]; + this.acc = this.properties[1]; + this.g = this.properties[2]; + this.bounceOffSolid = (this.properties[3] !== 0); + this.setAngle = (this.properties[4] !== 0); + this.dx = Math.cos(this.inst.angle) * speed; + this.dy = Math.sin(this.inst.angle) * speed; + this.lastx = this.inst.x; + this.lasty = this.inst.y; + this.lastKnownAngle = this.inst.angle; + this.travelled = 0; + this.enabled = (this.properties[5] !== 0); + }; + behinstProto.saveToJSON = function () + { + return { + "acc": this.acc, + "g": this.g, + "dx": this.dx, + "dy": this.dy, + "lx": this.lastx, + "ly": this.lasty, + "lka": this.lastKnownAngle, + "t": this.travelled, + "e": this.enabled + }; + }; + behinstProto.loadFromJSON = function (o) + { + this.acc = o["acc"]; + this.g = o["g"]; + this.dx = o["dx"]; + this.dy = o["dy"]; + this.lastx = o["lx"]; + this.lasty = o["ly"]; + this.lastKnownAngle = o["lka"]; + this.travelled = o["t"]; + this.enabled = o["e"]; + }; + behinstProto.tick = function () + { + if (!this.enabled) + return; + var dt = this.runtime.getDt(this.inst); + var s, a; + var bounceSolid, bounceAngle; + if (this.inst.angle !== this.lastKnownAngle) + { + if (this.setAngle) + { + s = cr.distanceTo(0, 0, this.dx, this.dy); + this.dx = Math.cos(this.inst.angle) * s; + this.dy = Math.sin(this.inst.angle) * s; + } + this.lastKnownAngle = this.inst.angle; + } + if (this.acc !== 0) + { + s = cr.distanceTo(0, 0, this.dx, this.dy); + if (this.dx === 0 && this.dy === 0) + a = this.inst.angle; + else + a = cr.angleTo(0, 0, this.dx, this.dy); + s += this.acc * dt; + if (s < 0) + s = 0; + this.dx = Math.cos(a) * s; + this.dy = Math.sin(a) * s; + } + if (this.g !== 0) + this.dy += this.g * dt; + this.lastx = this.inst.x; + this.lasty = this.inst.y; + if (this.dx !== 0 || this.dy !== 0) + { + this.inst.x += this.dx * dt; + this.inst.y += this.dy * dt; + this.travelled += cr.distanceTo(0, 0, this.dx * dt, this.dy * dt) + if (this.setAngle) + { + this.inst.angle = cr.angleTo(0, 0, this.dx, this.dy); + this.inst.set_bbox_changed(); + this.lastKnownAngle = this.inst.angle; + } + this.inst.set_bbox_changed(); + if (this.bounceOffSolid) + { + bounceSolid = this.runtime.testOverlapSolid(this.inst); + if (bounceSolid) + { + this.runtime.registerCollision(this.inst, bounceSolid); + s = cr.distanceTo(0, 0, this.dx, this.dy); + bounceAngle = this.runtime.calculateSolidBounceAngle(this.inst, this.lastx, this.lasty); + this.dx = Math.cos(bounceAngle) * s; + this.dy = Math.sin(bounceAngle) * s; + this.inst.x += this.dx * dt; // move out for one tick since the object can't have spent a tick in the solid + this.inst.y += this.dy * dt; + this.inst.set_bbox_changed(); + if (this.setAngle) + { + this.inst.angle = bounceAngle; + this.lastKnownAngle = bounceAngle; + this.inst.set_bbox_changed(); + } + if (!this.runtime.pushOutSolid(this.inst, this.dx / s, this.dy / s, Math.max(s * 2.5 * dt, 30))) + this.runtime.pushOutSolidNearest(this.inst, 100); + } + } + } + }; + function Cnds() {}; + Cnds.prototype.CompareSpeed = function (cmp, s) + { + return cr.do_cmp(cr.distanceTo(0, 0, this.dx, this.dy), cmp, s); + }; + Cnds.prototype.CompareTravelled = function (cmp, d) + { + return cr.do_cmp(this.travelled, cmp, d); + }; + behaviorProto.cnds = new Cnds(); + function Acts() {}; + Acts.prototype.SetSpeed = function (s) + { + var a = cr.angleTo(0, 0, this.dx, this.dy); + this.dx = Math.cos(a) * s; + this.dy = Math.sin(a) * s; + }; + Acts.prototype.SetAcceleration = function (a) + { + this.acc = a; + }; + Acts.prototype.SetGravity = function (g) + { + this.g = g; + }; + Acts.prototype.SetAngleOfMotion = function (a) + { + a = cr.to_radians(a); + var s = cr.distanceTo(0, 0, this.dx, this.dy) + this.dx = Math.cos(a) * s; + this.dy = Math.sin(a) * s; + }; + Acts.prototype.Bounce = function (objtype) + { + if (!objtype) + return; + var otherinst = objtype.getFirstPicked(this.inst); + if (!otherinst) + return; + var dt = this.runtime.getDt(this.inst); + var s = cr.distanceTo(0, 0, this.dx, this.dy); + var bounceAngle = this.runtime.calculateSolidBounceAngle(this.inst, this.lastx, this.lasty, otherinst); + this.dx = Math.cos(bounceAngle) * s; + this.dy = Math.sin(bounceAngle) * s; + this.inst.x += this.dx * dt; // move out for one tick since the object can't have spent a tick in the solid + this.inst.y += this.dy * dt; + this.inst.set_bbox_changed(); + if (this.setAngle) + { + this.inst.angle = bounceAngle; + this.lastKnownAngle = bounceAngle; + this.inst.set_bbox_changed(); + } + if (s !== 0) // prevent divide-by-zero + { + if (this.bounceOffSolid) + { + if (!this.runtime.pushOutSolid(this.inst, this.dx / s, this.dy / s, Math.max(s * 2.5 * dt, 30))) + this.runtime.pushOutSolidNearest(this.inst, 100); + } + else + { + this.runtime.pushOut(this.inst, this.dx / s, this.dy / s, Math.max(s * 2.5 * dt, 30), otherinst) + } + } + }; + Acts.prototype.SetDistanceTravelled = function (d) + { + this.travelled = d; + }; + Acts.prototype.SetEnabled = function (en) + { + this.enabled = (en === 1); + }; + behaviorProto.acts = new Acts(); + function Exps() {}; + Exps.prototype.Speed = function (ret) + { + var s = cr.distanceTo(0, 0, this.dx, this.dy); + s = cr.round6dp(s); + ret.set_float(s); + }; + Exps.prototype.Acceleration = function (ret) + { + ret.set_float(this.acc); + }; + Exps.prototype.AngleOfMotion = function (ret) + { + ret.set_float(cr.to_degrees(cr.angleTo(0, 0, this.dx, this.dy))); + }; + Exps.prototype.DistanceTravelled = function (ret) + { + ret.set_float(this.travelled); + }; + Exps.prototype.Gravity = function (ret) + { + ret.set_float(this.g); + }; + behaviorProto.exps = new Exps(); +}()); +; +; +cr.behaviors.Pin = function(runtime) +{ + this.runtime = runtime; +}; +(function () +{ + var behaviorProto = cr.behaviors.Pin.prototype; + behaviorProto.Type = function(behavior, objtype) + { + this.behavior = behavior; + this.objtype = objtype; + this.runtime = behavior.runtime; + }; + var behtypeProto = behaviorProto.Type.prototype; + behtypeProto.onCreate = function() + { + }; + behaviorProto.Instance = function(type, inst) + { + this.type = type; + this.behavior = type.behavior; + this.inst = inst; // associated object instance to modify + this.runtime = type.runtime; + }; + var behinstProto = behaviorProto.Instance.prototype; + behinstProto.onCreate = function() + { + this.pinObject = null; + this.pinObjectUid = -1; // for loading + this.pinAngle = 0; + this.pinDist = 0; + this.myStartAngle = 0; + this.theirStartAngle = 0; + this.lastKnownAngle = 0; + this.mode = 0; // 0 = position & angle; 1 = position; 2 = angle; 3 = rope; 4 = bar + var self = this; + if (!this.recycled) + { + this.myDestroyCallback = (function(inst) { + self.onInstanceDestroyed(inst); + }); + } + this.runtime.addDestroyCallback(this.myDestroyCallback); + }; + behinstProto.saveToJSON = function () + { + return { + "uid": this.pinObject ? this.pinObject.uid : -1, + "pa": this.pinAngle, + "pd": this.pinDist, + "msa": this.myStartAngle, + "tsa": this.theirStartAngle, + "lka": this.lastKnownAngle, + "m": this.mode + }; + }; + behinstProto.loadFromJSON = function (o) + { + this.pinObjectUid = o["uid"]; // wait until afterLoad to look up + this.pinAngle = o["pa"]; + this.pinDist = o["pd"]; + this.myStartAngle = o["msa"]; + this.theirStartAngle = o["tsa"]; + this.lastKnownAngle = o["lka"]; + this.mode = o["m"]; + }; + behinstProto.afterLoad = function () + { + if (this.pinObjectUid === -1) + this.pinObject = null; + else + { + this.pinObject = this.runtime.getObjectByUID(this.pinObjectUid); +; + } + this.pinObjectUid = -1; + }; + behinstProto.onInstanceDestroyed = function (inst) + { + if (this.pinObject == inst) + this.pinObject = null; + }; + behinstProto.onDestroy = function() + { + this.pinObject = null; + this.runtime.removeDestroyCallback(this.myDestroyCallback); + }; + behinstProto.tick = function () + { + }; + behinstProto.tick2 = function () + { + if (!this.pinObject) + return; + if (this.lastKnownAngle !== this.inst.angle) + this.myStartAngle = cr.clamp_angle(this.myStartAngle + (this.inst.angle - this.lastKnownAngle)); + var newx = this.inst.x; + var newy = this.inst.y; + if (this.mode === 3 || this.mode === 4) // rope mode or bar mode + { + var dist = cr.distanceTo(this.inst.x, this.inst.y, this.pinObject.x, this.pinObject.y); + if ((dist > this.pinDist) || (this.mode === 4 && dist < this.pinDist)) + { + var a = cr.angleTo(this.pinObject.x, this.pinObject.y, this.inst.x, this.inst.y); + newx = this.pinObject.x + Math.cos(a) * this.pinDist; + newy = this.pinObject.y + Math.sin(a) * this.pinDist; + } + } + else + { + newx = this.pinObject.x + Math.cos(this.pinObject.angle + this.pinAngle) * this.pinDist; + newy = this.pinObject.y + Math.sin(this.pinObject.angle + this.pinAngle) * this.pinDist; + } + var newangle = cr.clamp_angle(this.myStartAngle + (this.pinObject.angle - this.theirStartAngle)); + this.lastKnownAngle = newangle; + if ((this.mode === 0 || this.mode === 1 || this.mode === 3 || this.mode === 4) + && (this.inst.x !== newx || this.inst.y !== newy)) + { + this.inst.x = newx; + this.inst.y = newy; + this.inst.set_bbox_changed(); + } + if ((this.mode === 0 || this.mode === 2) && (this.inst.angle !== newangle)) + { + this.inst.angle = newangle; + this.inst.set_bbox_changed(); + } + }; + function Cnds() {}; + Cnds.prototype.IsPinned = function () + { + return !!this.pinObject; + }; + behaviorProto.cnds = new Cnds(); + function Acts() {}; + Acts.prototype.Pin = function (obj, mode_) + { + if (!obj) + return; + var otherinst = obj.getFirstPicked(this.inst); + if (!otherinst) + return; + this.pinObject = otherinst; + this.pinAngle = cr.angleTo(otherinst.x, otherinst.y, this.inst.x, this.inst.y) - otherinst.angle; + this.pinDist = cr.distanceTo(otherinst.x, otherinst.y, this.inst.x, this.inst.y); + this.myStartAngle = this.inst.angle; + this.lastKnownAngle = this.inst.angle; + this.theirStartAngle = otherinst.angle; + this.mode = mode_; + }; + Acts.prototype.Unpin = function () + { + this.pinObject = null; + }; + behaviorProto.acts = new Acts(); + function Exps() {}; + Exps.prototype.PinnedUID = function (ret) + { + ret.set_int(this.pinObject ? this.pinObject.uid : -1); + }; + behaviorProto.exps = new Exps(); +}()); +; +; +cr.behaviors.Sin = function(runtime) +{ + this.runtime = runtime; +}; +(function () +{ + var behaviorProto = cr.behaviors.Sin.prototype; + behaviorProto.Type = function(behavior, objtype) + { + this.behavior = behavior; + this.objtype = objtype; + this.runtime = behavior.runtime; + }; + var behtypeProto = behaviorProto.Type.prototype; + behtypeProto.onCreate = function() + { + }; + behaviorProto.Instance = function(type, inst) + { + this.type = type; + this.behavior = type.behavior; + this.inst = inst; // associated object instance to modify + this.runtime = type.runtime; + this.i = 0; // period offset (radians) + }; + var behinstProto = behaviorProto.Instance.prototype; + var _2pi = 2 * Math.PI; + var _pi_2 = Math.PI / 2; + var _3pi_2 = (3 * Math.PI) / 2; + behinstProto.onCreate = function() + { + this.active = (this.properties[0] === 1); + this.movement = this.properties[1]; // 0=Horizontal|1=Vertical|2=Size|3=Width|4=Height|5=Angle|6=Opacity|7=Value only + this.wave = this.properties[2]; // 0=Sine|1=Triangle|2=Sawtooth|3=Reverse sawtooth|4=Square + this.period = this.properties[3]; + this.period += Math.random() * this.properties[4]; // period random + if (this.period === 0) + this.i = 0; + else + { + this.i = (this.properties[5] / this.period) * _2pi; // period offset + this.i += ((Math.random() * this.properties[6]) / this.period) * _2pi; // period offset random + } + this.mag = this.properties[7]; // magnitude + this.mag += Math.random() * this.properties[8]; // magnitude random + this.initialValue = 0; + this.initialValue2 = 0; + this.ratio = 0; + if (this.movement === 5) // angle + this.mag = cr.to_radians(this.mag); + this.init(); + }; + behinstProto.saveToJSON = function () + { + return { + "i": this.i, + "a": this.active, + "mv": this.movement, + "w": this.wave, + "p": this.period, + "mag": this.mag, + "iv": this.initialValue, + "iv2": this.initialValue2, + "r": this.ratio, + "lkv": this.lastKnownValue, + "lkv2": this.lastKnownValue2 + }; + }; + behinstProto.loadFromJSON = function (o) + { + this.i = o["i"]; + this.active = o["a"]; + this.movement = o["mv"]; + this.wave = o["w"]; + this.period = o["p"]; + this.mag = o["mag"]; + this.initialValue = o["iv"]; + this.initialValue2 = o["iv2"] || 0; + this.ratio = o["r"]; + this.lastKnownValue = o["lkv"]; + this.lastKnownValue2 = o["lkv2"] || 0; + }; + behinstProto.init = function () + { + switch (this.movement) { + case 0: // horizontal + this.initialValue = this.inst.x; + break; + case 1: // vertical + this.initialValue = this.inst.y; + break; + case 2: // size + this.initialValue = this.inst.width; + this.ratio = this.inst.height / this.inst.width; + break; + case 3: // width + this.initialValue = this.inst.width; + break; + case 4: // height + this.initialValue = this.inst.height; + break; + case 5: // angle + this.initialValue = this.inst.angle; + break; + case 6: // opacity + this.initialValue = this.inst.opacity; + break; + case 7: + this.initialValue = 0; + break; + case 8: // forwards/backwards + this.initialValue = this.inst.x; + this.initialValue2 = this.inst.y; + break; + default: +; + } + this.lastKnownValue = this.initialValue; + this.lastKnownValue2 = this.initialValue2; + }; + behinstProto.waveFunc = function (x) + { + x = x % _2pi; + switch (this.wave) { + case 0: // sine + return Math.sin(x); + case 1: // triangle + if (x <= _pi_2) + return x / _pi_2; + else if (x <= _3pi_2) + return 1 - (2 * (x - _pi_2) / Math.PI); + else + return (x - _3pi_2) / _pi_2 - 1; + case 2: // sawtooth + return 2 * x / _2pi - 1; + case 3: // reverse sawtooth + return -2 * x / _2pi + 1; + case 4: // square + return x < Math.PI ? -1 : 1; + }; + return 0; + }; + behinstProto.tick = function () + { + var dt = this.runtime.getDt(this.inst); + if (!this.active || dt === 0) + return; + if (this.period === 0) + this.i = 0; + else + { + this.i += (dt / this.period) * _2pi; + this.i = this.i % _2pi; + } + this.updateFromPhase(); + }; + behinstProto.updateFromPhase = function () + { + switch (this.movement) { + case 0: // horizontal + if (this.inst.x !== this.lastKnownValue) + this.initialValue += this.inst.x - this.lastKnownValue; + this.inst.x = this.initialValue + this.waveFunc(this.i) * this.mag; + this.lastKnownValue = this.inst.x; + break; + case 1: // vertical + if (this.inst.y !== this.lastKnownValue) + this.initialValue += this.inst.y - this.lastKnownValue; + this.inst.y = this.initialValue + this.waveFunc(this.i) * this.mag; + this.lastKnownValue = this.inst.y; + break; + case 2: // size + this.inst.width = this.initialValue + this.waveFunc(this.i) * this.mag; + this.inst.height = this.inst.width * this.ratio; + break; + case 3: // width + this.inst.width = this.initialValue + this.waveFunc(this.i) * this.mag; + break; + case 4: // height + this.inst.height = this.initialValue + this.waveFunc(this.i) * this.mag; + break; + case 5: // angle + if (this.inst.angle !== this.lastKnownValue) + this.initialValue = cr.clamp_angle(this.initialValue + (this.inst.angle - this.lastKnownValue)); + this.inst.angle = cr.clamp_angle(this.initialValue + this.waveFunc(this.i) * this.mag); + this.lastKnownValue = this.inst.angle; + break; + case 6: // opacity + this.inst.opacity = this.initialValue + (this.waveFunc(this.i) * this.mag) / 100; + if (this.inst.opacity < 0) + this.inst.opacity = 0; + else if (this.inst.opacity > 1) + this.inst.opacity = 1; + break; + case 8: // forwards/backwards + if (this.inst.x !== this.lastKnownValue) + this.initialValue += this.inst.x - this.lastKnownValue; + if (this.inst.y !== this.lastKnownValue2) + this.initialValue2 += this.inst.y - this.lastKnownValue2; + this.inst.x = this.initialValue + Math.cos(this.inst.angle) * this.waveFunc(this.i) * this.mag; + this.inst.y = this.initialValue2 + Math.sin(this.inst.angle) * this.waveFunc(this.i) * this.mag; + this.lastKnownValue = this.inst.x; + this.lastKnownValue2 = this.inst.y; + break; + } + this.inst.set_bbox_changed(); + }; + behinstProto.onSpriteFrameChanged = function (prev_frame, next_frame) + { + switch (this.movement) { + case 2: // size + this.initialValue *= (next_frame.width / prev_frame.width); + this.ratio = next_frame.height / next_frame.width; + break; + case 3: // width + this.initialValue *= (next_frame.width / prev_frame.width); + break; + case 4: // height + this.initialValue *= (next_frame.height / prev_frame.height); + break; + } + }; + function Cnds() {}; + Cnds.prototype.IsActive = function () + { + return this.active; + }; + Cnds.prototype.CompareMovement = function (m) + { + return this.movement === m; + }; + Cnds.prototype.ComparePeriod = function (cmp, v) + { + return cr.do_cmp(this.period, cmp, v); + }; + Cnds.prototype.CompareMagnitude = function (cmp, v) + { + if (this.movement === 5) + return cr.do_cmp(this.mag, cmp, cr.to_radians(v)); + else + return cr.do_cmp(this.mag, cmp, v); + }; + Cnds.prototype.CompareWave = function (w) + { + return this.wave === w; + }; + behaviorProto.cnds = new Cnds(); + function Acts() {}; + Acts.prototype.SetActive = function (a) + { + this.active = (a === 1); + }; + Acts.prototype.SetPeriod = function (x) + { + this.period = x; + }; + Acts.prototype.SetMagnitude = function (x) + { + this.mag = x; + if (this.movement === 5) // angle + this.mag = cr.to_radians(this.mag); + }; + Acts.prototype.SetMovement = function (m) + { + if (this.movement === 5 && m !== 5) + this.mag = cr.to_degrees(this.mag); + this.movement = m; + this.init(); + }; + Acts.prototype.SetWave = function (w) + { + this.wave = w; + }; + Acts.prototype.SetPhase = function (x) + { + this.i = (x * _2pi) % _2pi; + this.updateFromPhase(); + }; + Acts.prototype.UpdateInitialState = function () + { + this.init(); + }; + behaviorProto.acts = new Acts(); + function Exps() {}; + Exps.prototype.CyclePosition = function (ret) + { + ret.set_float(this.i / _2pi); + }; + Exps.prototype.Period = function (ret) + { + ret.set_float(this.period); + }; + Exps.prototype.Magnitude = function (ret) + { + if (this.movement === 5) // angle + ret.set_float(cr.to_degrees(this.mag)); + else + ret.set_float(this.mag); + }; + Exps.prototype.Value = function (ret) + { + ret.set_float(this.waveFunc(this.i) * this.mag); + }; + behaviorProto.exps = new Exps(); +}()); +var easeOutBounceArray = []; +var easeInElasticArray = []; +var easeOutElasticArray = []; +var easeInOutElasticArray = []; +var easeInCircle = []; +var easeOutCircle = []; +var easeInOutCircle = []; +var easeInBack = []; +var easeOutBack = []; +var easeInOutBack = []; +var litetween_precision = 10000; +var updateLimit = 0; //0.0165; +function easeOutBouncefunc(t) { + var b=0.0; + var c=1.0; + var d=1.0; + if ((t/=d) < (1/2.75)) { + result = c*(7.5625*t*t) + b; + } else if (t < (2/2.75)) { + result = c*(7.5625*(t-=(1.5/2.75))*t + .75) + b; + } else if (t < (2.5/2.75)) { + result = c*(7.5625*(t-=(2.25/2.75))*t + .9375) + b; + } else { + result = c*(7.5625*(t-=(2.625/2.75))*t + .984375) + b; + } + return result; +} +function integerize(t, d) +{ + return Math.round(t/d*litetween_precision); +} +function easeFunc(easing, t, b, c, d, flip, param) +{ + var ret_ease = 0; + switch (easing) { + case 0: // linear + ret_ease = c*t/d + b; + break; + case 1: // easeInQuad + ret_ease = c*(t/=d)*t + b; + break; + case 2: // easeOutQuad + ret_ease = -c *(t/=d)*(t-2) + b; + break; + case 3: // easeInOutQuad + if ((t/=d/2) < 1) + ret_ease = c/2*t*t + b + else + ret_ease = -c/2 * ((--t)*(t-2) - 1) + b; + break; + case 4: // easeInCubic + ret_ease = c*(t/=d)*t*t + b; + break; + case 5: // easeOutCubic + ret_ease = c*((t=t/d-1)*t*t + 1) + b; + break; + case 6: // easeInOutCubic + if ((t/=d/2) < 1) + ret_ease = c/2*t*t*t + b + else + ret_ease = c/2*((t-=2)*t*t + 2) + b; + break; + case 7: // easeInQuart + ret_ease = c*(t/=d)*t*t*t + b; + break; + case 8: // easeOutQuart + ret_ease = -c * ((t=t/d-1)*t*t*t - 1) + b; + break; + case 9: // easeInOutQuart + if ((t/=d/2) < 1) + ret_ease = c/2*t*t*t*t + b + else + ret_ease = -c/2 * ((t-=2)*t*t*t - 2) + b; + break; + case 10: // easeInQuint + ret_ease = c*(t/=d)*t*t*t*t + b; + break; + case 11: // easeOutQuint + ret_ease = c*((t=t/d-1)*t*t*t*t + 1) + b; + break; + case 12: // easeInOutQuint + if ((t/=d/2) < 1) + ret_ease = c/2*t*t*t*t*t + b + else + ret_ease = c/2*((t-=2)*t*t*t*t + 2) + b; + break; + case 13: // easeInCircle + if (param.optimized) { + ret_ease = easeInCircle[integerize(t,d)]; + } else { + ret_ease = -(Math.sqrt(1-t*t) - 1); + } + break; + case 14: // easeOutCircle + if (param.optimized) { + ret_ease = easeOutCircle[integerize(t,d)]; + } else { + ret_ease = Math.sqrt(1 - ((t-1)*(t-1))); + } + break; + case 15: // easeInOutCircle + if (param.optimized) { + ret_ease = easeInOutCircle[integerize(t,d)]; + } else { + if ((t/=d/2) < 1) ret_ease = -c/2 * (Math.sqrt(1 - t*t) - 1) + b + else ret_ease = c/2 * (Math.sqrt(1 - (t-=2)*t) + 1) + b; + } + break; + case 16: // easeInBack + if (param.optimized) { + ret_ease = easeOutBack[integerize(t,d)]; + } else { + var s = param.s; + ret_ease = c*(t/=d)*t*((s+1)*t - s) + b; + } + break; + case 17: // easeOutBack + if (param.optimized) { + ret_ease = easeOutBack[integerize(t,d)]; + } else { + var s = param.s; + ret_ease = c*((t=t/d-1)*t*((s+1)*t + s) + 1) + b; + } + break; + case 18: // easeInOutBack + if (param.optimized) { + ret_ease = easeInOutBack[integerize(t,d)]; + } else { + var s = param.s + if ((t/=d/2) < 1) + ret_ease = c/2*(t*t*(((s*=(1.525))+1)*t - s)) + b + else + ret_ease = c/2*((t-=2)*t*(((s*=(1.525))+1)*t + s) + 2) + b; + } + break; + case 19: //easeInElastic + if (param.optimized) { + ret_ease = easeInElasticArray[integerize(t, d)]; + } else { + var a = param.a; + var p = param.p; + var s = 0; + if (t==0) ret_ease = b; if ((t/=d)==1) ret_ease = b+c; + if (p==0) p=d*.3; if (a==0 || a < Math.abs(c)) { a=c; s=p/4; } + else var s = p/(2*Math.PI) * Math.asin (c/a); + ret_ease = -(a*Math.pow(2,10*(t-=1)) * Math.sin( (t*d-s)*(2*Math.PI)/p )) + b; + } + break; + case 20: //easeOutElastic + if (param.optimized) { + ret_ease = easeOutElasticArray[integerize(t,d)]; + } else { + var a = param.a; + var p = param.p; + var s = 0; + if (t==0) ret_ease= b; if ((t/=d)==1) ret_ease= b+c; if (p == 0) p=d*.3; + if (a==0 || a < Math.abs(c)) { a=c; var s=p/4; } + else var s = p/(2*Math.PI) * Math.asin (c/a); + ret_ease= (a*Math.pow(2,-10*t) * Math.sin( (t*d-s)*(2*Math.PI)/p ) + c + b); + } + break; + case 21: //easeInOutElastic + if (param.optimized) { + ret_ease = easeInOutElasticArray[integerize(t,d)]; + } else { + var a = param.a; + var p = param.p; + var s = 0; + if (t==0) ret_ease = b; + if ((t/=d/2)==2) ret_ease = b+c; + if (p==0) p=d*(.3*1.5); + if (a==0 || a < Math.abs(c)) { a=c; var s=p/4; } + else var s = p/(2*Math.PI) * Math.asin (c/a); + if (t < 1) + ret_ease = -.5*(a*Math.pow(2,10*(t-=1)) * Math.sin( (t*d-s)*(2*Math.PI)/p )) + b + else + ret_ease = a*Math.pow(2,-10*(t-=1)) * Math.sin( (t*d-s)*(2*Math.PI)/p )*.5 + c + b; + } + break; + case 22: //easeInBounce + if (param.optimized) { + ret_ease = c - easeOutBounceArray[integerize(d-t, d)] + b; + } else { + ret_ease = c - easeOutBouncefunc(d-t/d) + b; + } + break; + case 23: //easeOutBounce + if (param.optimized) { + ret_ease = easeOutBounceArray[integerize(t, d)]; + } else { + ret_ease = easeOutBouncefunc(t/d); + } + break; + case 24: //easeInOutBounce + if (param.optimized) { + if (t < d/2) + ret_ease = (c - easeOutBounceArray[integerize(d-(t*2), d)] + b) * 0.5 +b; + else + ret_ease = easeOutBounceArray[integerize(t*2-d, d)] * .5 + c*.5 + b; + } else { + if (t < d/2) + ret_ease = (c - easeOutBouncefunc(d-(t*2)) + b) * 0.5 +b; + else + ret_ease = easeOutBouncefunc((t*2-d)/d) * .5 + c *.5 + b; + } + break; + case 25: //easeInSmoothstep + var mt = (t/d) / 2; + ret_ease = (2*(mt * mt * (3 - 2*mt))); + break; + case 26: //easeOutSmoothstep + var mt = ((t/d) + 1) / 2; + ret_ease = ((2*(mt * mt * (3 - 2*mt))) - 1); + break; + case 27: //easeInOutSmoothstep + var mt = (t / d); + ret_ease = (mt * mt * (3 - 2*mt)); + break; + }; + if (flip) + return (c - b) - ret_ease + else + return ret_ease; +}; +(function preCalculateArray() { + var d = 1.0; + var b = 0.0; + var c = 1.0; + var result = 0.0; + var a = 0.0; + var p = 0.0; + var t = 0.0; + var s = 0.0; + for (var ti = 0; ti <= litetween_precision; ti++) { + t = ti/litetween_precision; + if ((t/=d) < (1/2.75)) { + result = c*(7.5625*t*t) + b; + } else if (t < (2/2.75)) { + result = c*(7.5625*(t-=(1.5/2.75))*t + .75) + b; + } else if (t < (2.5/2.75)) { + result = c*(7.5625*(t-=(2.25/2.75))*t + .9375) + b; + } else { + result = c*(7.5625*(t-=(2.625/2.75))*t + .984375) + b; + } + easeOutBounceArray[ti] = result; + t = ti/litetween_precision; a = 0; p = 0; + if (t==0) result = b; if ((t/=d)==1) result = b+c; + if (p==0) p=d*.3; if (a==0 || a < Math.abs(c)) { a=c; var s=p/4; } + else var s = p/(2*Math.PI) * Math.asin (c/a); + result = -(a*Math.pow(2,10*(t-=1)) * Math.sin( (t*d-s)*(2*Math.PI)/p )) + b; + easeInElasticArray[ti] = result; + t = ti/litetween_precision; a = 0; p = 0; + if (t==0) result= b; if ((t/=d)==1) result= b+c; if (p == 0) p=d*.3; + if (a==0 || a < Math.abs(c)) { a=c; var s=p/4; } + else var s = p/(2*Math.PI) * Math.asin (c/a); + result= (a*Math.pow(2,-10*t) * Math.sin( (t*d-s)*(2*Math.PI)/p ) + c + b); + easeOutElasticArray[ti] = result; + t = ti/litetween_precision; a = 0; p = 0; + if (t==0) result = b; + if ((t/=d/2)==2) result = b+c; + if (p==0) p=d*(.3*1.5); + if (a==0 || a < Math.abs(c)) { a=c; var s=p/4; } + else var s = p/(2*Math.PI) * Math.asin (c/a); + if (t < 1) + result = -.5*(a*Math.pow(2,10*(t-=1)) * Math.sin( (t*d-s)*(2*Math.PI)/p )) + b + else + result = a*Math.pow(2,-10*(t-=1)) * Math.sin( (t*d-s)*(2*Math.PI)/p )*.5 + c + b; + easeInOutElasticArray[ti] = result; + t = ti/litetween_precision; easeInCircle[ti] = -(Math.sqrt(1-t*t) - 1); + t = ti/litetween_precision; easeOutCircle[ti] = Math.sqrt(1 - ((t-1)*(t-1))); + t = ti/litetween_precision; + if ((t/=d/2) < 1) result = -c/2 * (Math.sqrt(1 - t*t) - 1) + b + else result = c/2 * (Math.sqrt(1 - (t-=2)*t) + 1) + b; + easeInOutCircle[ti] = result; + t = ti/litetween_precision; s = 0; + if (s==0) s = 1.70158; + result = c*(t/=d)*t*((s+1)*t - s) + b; + easeInBack[ti] = result; + t = ti/litetween_precision; s = 0; + if (s==0) s = 1.70158; + result = c*((t=t/d-1)*t*((s+1)*t + s) + 1) + b; + easeOutBack[ti] = result; + t = ti/litetween_precision; s = 0; if (s==0) s = 1.70158; + if ((t/=d/2) < 1) + result = c/2*(t*t*(((s*=(1.525))+1)*t - s)) + b + else + result = c/2*((t-=2)*t*(((s*=(1.525))+1)*t + s) + 2) + b; + easeInOutBack[ti] = result; + } +}()); +var TweenObject = function() +{ + var constructor = function (tname, tweened, easefunc, initial, target, duration, enforce) + { + this.name = tname; + this.value = 0; + this.setInitial(initial); + this.setTarget(target); + this.easefunc = easefunc; + this.tweened = tweened; + this.duration = duration; + this.progress = 0; + this.state = 0; + this.onStart = false; + this.onEnd = false; + this.onReverseStart = false; + this.onReverseEnd = false; + this.lastKnownValue = 0; + this.lastKnownValue2 = 0; + this.enforce = enforce; + this.pingpong = 1.0; + this.flipEase = false; + this.easingparam = []; + for (var i=0; i<28; i++) { + this.easingparam[i] = {}; + this.easingparam[i].a = 0.0; + this.easingparam[i].p = 0.0; + this.easingparam[i].t = 0.0; + this.easingparam[i].s = 0.0; + this.easingparam[i].optimized = true; + } + } + return constructor; +}(); +(function () { + TweenObject.prototype = { + }; + TweenObject.prototype.flipTarget = function () + { + var x1 = this.initialparam1; + var x2 = this.initialparam2; + this.initialparam1 = this.targetparam1; + this.initialparam2 = this.targetparam2; + this.targetparam1 = x1; + this.targetparam2 = x2; + this.lastKnownValue = 0; + this.lastKnownValue2 = 0; + } + TweenObject.prototype.setInitial = function (initial) + { + this.initialparam1 = parseFloat(initial.split(",")[0]); + this.initialparam2 = parseFloat(initial.split(",")[1]); + this.lastKnownValue = 0; + this.lastKnownValue2 = 0; + } + TweenObject.prototype.setTarget = function (target) + { + this.targetparam1 = parseFloat(target.split(",")[0]); + this.targetparam2 = parseFloat(target.split(",")[1]); + if (isNaN(this.targetparam2)) this.targetparam2 = this.targetparam1; + } + TweenObject.prototype.OnTick = function(dt) + { + if (this.state === 0) return -1.0; + if (this.state === 1) + this.progress += dt; + if (this.state === 2) + this.progress -= dt; + if (this.state === 3) { + this.state = 0; + } + if ((this.state === 4) || (this.state === 6)) { + this.progress += dt * this.pingpong; + } + if (this.state === 5) { + this.progress += dt * this.pingpong; + } + if (this.progress < 0) { + this.progress = 0; + if (this.state === 4) { + this.pingpong = 1; + } else if (this.state === 6) { + this.pingpong = 1; + this.flipEase = false; + } else { + this.state = 0; + } + this.onReverseEnd = true; + return 0.0; + } else if (this.progress > this.duration) { + this.progress = this.duration; + if (this.state === 4) { + this.pingpong = -1; + } else if (this.state === 6) { + this.pingpong = -1; + this.flipEase = true; + } else if (this.state === 5) { + this.progress = 0.0; + } else { + this.state = 0; + } + this.onEnd = true; + return 1.0; + } else { + if (this.flipEase) { + var factor = easeFunc(this.easefunc, this.duration - this.progress, 0, 1, this.duration, this.flipEase, this.easingparam[this.easefunc]); + } else { + var factor = easeFunc(this.easefunc, this.progress, 0, 1, this.duration, this.flipEase, this.easingparam[this.easefunc]); + } + return factor; + } + }; +}()); +; +; +function trim (str) { + return str.replace(/^\s\s*/, '').replace(/\s\s*$/, ''); +} +cr.behaviors.lunarray_LiteTween = function(runtime) +{ + this.runtime = runtime; +}; +(function () +{ + var behaviorProto = cr.behaviors.lunarray_LiteTween.prototype; + behaviorProto.Type = function(behavior, objtype) + { + this.behavior = behavior; + this.objtype = objtype; + this.runtime = behavior.runtime; + }; + var behtypeProto = behaviorProto.Type.prototype; + behtypeProto.onCreate = function() + { + }; + behaviorProto.Instance = function(type, inst) + { + this.type = type; + this.behavior = type.behavior; + this.inst = inst; // associated object instance to modify + this.runtime = type.runtime; + this.i = 0; // progress + }; + var behinstProto = behaviorProto.Instance.prototype; + behinstProto.onCreate = function() + { + this.playmode = this.properties[0]; + this.active = (this.playmode == 1) || (this.playmode == 2) || (this.playmode == 3) || (this.playmode == 4); + this.tweened = this.properties[1]; // 0=Position|1=Size|2=Width|3=Height|4=Angle|5=Opacity|6=Value only|7=Horizontal|8=Vertical|9=Scale + this.easing = this.properties[2]; + this.target = this.properties[3]; + this.targetmode = this.properties[4]; + this.useCurrent = false; + if (this.targetmode === 1) this.target = "relative("+this.target+")"; + this.duration = this.properties[5]; + this.enforce = (this.properties[6] === 1); + this.value = 0; + this.tween_list = {}; + this.addToTweenList("default", this.tweened, this.easing, "current", this.target, this.duration, this.enforce); + if (this.properties[0] === 1) this.startTween(0) + if (this.properties[0] === 2) this.startTween(2) + if (this.properties[0] === 3) this.startTween(3) + if (this.properties[0] === 4) this.startTween(4) + }; + behinstProto.parseCurrent = function(tweened, parseText) + { + if (parseText === undefined) parseText = "current"; + var parsed = trim(parseText); + parseText = trim(parseText); + var value = this.value; + if (parseText === "current") { + switch (tweened) { + case 0: parsed = this.inst.x + "," + this.inst.y; break; + case 1: parsed = this.inst.width + "," + this.inst.height; break; + case 2: parsed = this.inst.width + "," + this.inst.height; break; + case 3: parsed = this.inst.width + "," + this.inst.height; break; + case 4: parsed = cr.to_degrees(this.inst.angle) + "," + cr.to_degrees(this.inst.angle); break; + case 5: parsed = (this.inst.opacity*100) + "," + (this.inst.opacity*100); break; + case 6: parsed = value + "," + value; break; + case 7: parsed = this.inst.x + "," + this.inst.y; break; + case 8: parsed = this.inst.x + "," + this.inst.y; break; + case 9: + if (this.inst.curFrame !== undefined) + parsed = (this.inst.width/this.inst.curFrame.width) + "," +(this.inst.height/this.inst.curFrame.height) + else + parsed = "1,1"; + break; + default: break; + } + } + if (parseText.substring(0,8) === "relative") { + var param1 = parseText.match(/\((.*?)\)/); + if (param1) { + var relativex = parseFloat(param1[1].split(",")[0]); + var relativey = parseFloat(param1[1].split(",")[1]); + } + if (isNaN(relativex)) relativex = 0; + if (isNaN(relativey)) relativey = 0; + switch (tweened) { + case 0: parsed = (this.inst.x+relativex) + "," + (this.inst.y+relativey); break; + case 1: parsed = (this.inst.width+relativex) + "," + (this.inst.height+relativey); break; + case 2: parsed = (this.inst.width+relativex) + "," + (this.inst.height+relativey); break; + case 3: parsed = (this.inst.width+relativex) + "," + (this.inst.height+relativey); break; + case 4: parsed = (cr.to_degrees(this.inst.angle)+relativex) + "," + (cr.to_degrees(this.inst.angle)+relativey); break; + case 5: parsed = (this.inst.opacity*100+relativex) + "," + (this.inst.opacity*100+relativey); break; + case 6: parsed = value+relativex + "," + value+relativex; break; + case 7: parsed = (this.inst.x+relativex) + "," + (this.inst.y); break; + case 8: parsed = (this.inst.x) + "," + (this.inst.y+relativex); break; + case 9: parsed = (relativex) + "," + (relativey); break; + default: break; + } + } + return parsed; + }; + behinstProto.addToTweenList = function(tname, tweened, easing, init, targ, duration, enforce) + { + init = this.parseCurrent(tweened, init); + targ = this.parseCurrent(tweened, targ); + if (this.tween_list[tname] !== undefined) { + delete this.tween_list[tname] + } + this.tween_list[tname] = new TweenObject(tname, tweened, easing, init, targ, duration, enforce); + this.tween_list[tname].dt = 0; + }; + behinstProto.saveToJSON = function () + { + var v = JSON.stringify(this.tween_list["default"]); + return { + "playmode": this.playmode, + "active": this.active, + "tweened": this.tweened, + "easing": this.easing, + "target": this.target, + "targetmode": this.targetmode, + "useCurrent": this.useCurrent, + "duration": this.duration, + "enforce": this.enforce, + "value": this.value, + "tweenlist": JSON.stringify(this.tween_list["default"]) + }; + }; + TweenObject.Load = function(rawObj, tname, tweened, easing, init, targ, duration, enforce) + { + var obj = new TweenObject(tname, tweened, easing, init, targ, duration, enforce); + for(var i in rawObj) + obj[i] = rawObj[i]; + return obj; + }; + behinstProto.loadFromJSON = function (o) + { + var x = JSON.parse(o["tweenlist"]); + var tempObj = TweenObject.Load(x, x.name, x.tweened, x.easefunc, x.initialparam1+","+x.initialparam2, x.targetparam1+","+x.targetparam2, x.duration, x.enforce); + console.log(tempObj); + this.tween_list["default"] = tempObj; + this.playmode = o["playmode"]; + this.active = o["active"]; + this.movement = o["tweened"]; + this.easing = o["easing"]; + this.target = o["target"]; + this.targetmode = o["targetmode"]; + this.useCurrent = o["useCurrent"]; + this.duration = o["duration"]; + this.enforce = o["enforce"]; + this.value = o["value"]; + }; + behinstProto.setProgressTo = function (mark) + { + if (mark > 1.0) mark = 1.0; + if (mark < 0.0) mark = 0.0; + for (var i in this.tween_list) { + var inst = this.tween_list[i]; + inst.lastKnownValue = 0; + inst.lastKnownValue2 = 0; + inst.state = 3; + inst.progress = mark * inst.duration; + var factor = inst.OnTick(0); + this.updateTween(inst, factor); + } + } + behinstProto.startTween = function (startMode) + { + for (var i in this.tween_list) { + var inst = this.tween_list[i]; + if (this.useCurrent) { + var init = this.parseCurrent(inst.tweened, "current"); + var target = this.parseCurrent(inst.tweened, this.target); + inst.setInitial(init); + inst.setTarget(target); + } + if (startMode === 0) { + inst.progress = 0.000001; + inst.lastKnownValue = 0; + inst.lastKnownValue2 = 0; + inst.onStart = true; + inst.state = 1; + } + if (startMode === 1) { + inst.state = 1; + } + if ((startMode === 2) || (startMode === 4)) { + inst.progress = 0.000001; + inst.lastKnownValue = 0; + inst.lastKnownValue2 = 0; + inst.onStart = true; + if (startMode == 2) inst.state = 4; //state ping pong + if (startMode == 4) inst.state = 6; //state flip flop + } + if (startMode === 3) { + inst.progress = 0.000001; + inst.lastKnownValue = 0; + inst.lastKnownValue2 = 0; + inst.onStart = true; + inst.state = 5; + } + } + } + behinstProto.stopTween = function (stopMode) + { + for (var i in this.tween_list) { + var inst = this.tween_list[i]; + if (stopMode === 1) inst.progress = 0.0; + if (stopMode === 2) inst.progress = inst.duration; + inst.state = 3; + var factor = inst.OnTick(0); + this.updateTween(inst, factor); + } + } + behinstProto.reverseTween = function(reverseMode) + { + for (var i in this.tween_list) { + var inst = this.tween_list[i]; + if (reverseMode === 1) { + inst.progress = inst.duration; + inst.lastKnownValue = 0; + inst.lastKnownValue2 = 0; + inst.onReverseStart = true; + } + inst.state = 2; + } + } + behinstProto.updateTween = function (inst, factor) + { + var isMirrored = 1; + var isFlipped = 1; + if (this.inst.width < 0) isMirrored = -1; + if (this.inst.height < 0) isFlipped = -1; + if (inst.tweened === 0) { + if (inst.enforce) { + this.inst.x = inst.initialparam1 + (inst.targetparam1 - inst.initialparam1) * factor; + this.inst.y = inst.initialparam2 + (inst.targetparam2 - inst.initialparam2) * factor; + } else { + this.inst.x += ((inst.targetparam1 - inst.initialparam1) * factor) - inst.lastKnownValue; + this.inst.y += ((inst.targetparam2 - inst.initialparam2) * factor) - inst.lastKnownValue2; + inst.lastKnownValue = ((inst.targetparam1 - inst.initialparam1) * factor); + inst.lastKnownValue2 = ((inst.targetparam2 - inst.initialparam2) * factor); + } + } else if (inst.tweened === 1) { + if (inst.enforce) { + this.inst.width = (isMirrored * inst.initialparam1 + ((inst.targetparam1 - inst.initialparam1) * (factor * isMirrored))); + this.inst.height = (isFlipped * inst.initialparam2 + ((inst.targetparam2 - inst.initialparam2) * (factor * isFlipped))); + } else { + this.inst.width += (isMirrored *(inst.targetparam1 - inst.initialparam1) * factor) - inst.lastKnownValue; + this.inst.height += (isFlipped *(inst.targetparam2 - inst.initialparam2) * factor) - inst.lastKnownValue2; + inst.lastKnownValue = (isMirrored *(inst.targetparam1 - inst.initialparam1) * factor); + inst.lastKnownValue2 = (isFlipped *(inst.targetparam2 - inst.initialparam2) * factor); + } + } else if (inst.tweened === 2) { + if (inst.enforce) { + this.inst.width = (isMirrored * inst.initialparam1 + ((inst.targetparam1 - inst.initialparam1) * (factor * isMirrored))); + } else { + this.inst.width += (isMirrored *(inst.targetparam1 - inst.initialparam1) * factor) - inst.lastKnownValue; + inst.lastKnownValue = (isMirrored *(inst.targetparam1 - inst.initialparam1) * factor); + } + } else if (inst.tweened === 3) { + if (inst.enforce) { + this.inst.height = (isFlipped * inst.initialparam2 + ((inst.targetparam2 - inst.initialparam2) * (factor * isFlipped))); + } else { + this.inst.height += (isFlipped * (inst.targetparam2 - inst.initialparam2) * factor) - inst.lastKnownValue2; + inst.lastKnownValue2 = (isFlipped * (inst.targetparam2 - inst.initialparam2) * factor); + } + } else if (inst.tweened === 4) { + if (inst.enforce) { + var tangle = inst.initialparam1 + (inst.targetparam1 - inst.initialparam1) * factor; + this.inst.angle = cr.clamp_angle(cr.to_radians(tangle)); + } else { + var tangle = ((inst.targetparam1 - inst.initialparam1) * factor) - inst.lastKnownValue; + this.inst.angle = cr.clamp_angle(this.inst.angle + cr.to_radians(tangle)); + inst.lastKnownValue = (inst.targetparam1 - inst.initialparam1) * factor; + } + } else if (inst.tweened === 5) { + if (inst.enforce) { + this.inst.opacity = (inst.initialparam1 + (inst.targetparam1 - inst.initialparam1) * factor) / 100; + } else { + this.inst.opacity += (((inst.targetparam1 - inst.initialparam1) * factor) - inst.lastKnownValue) / 100; + inst.lastKnownValue = ((inst.targetparam1 - inst.initialparam1) * factor); + } + } else if (inst.tweened === 6) { + if (inst.enforce) { + this.value = (inst.initialparam1 + (inst.targetparam1 - inst.initialparam1) * factor); + } else { + this.value += (((inst.targetparam1 - inst.initialparam1) * factor) - inst.lastKnownValue); + inst.lastKnownValue = ((inst.targetparam1 - inst.initialparam1) * factor); + } + } else if (inst.tweened === 7) { + if (inst.enforce) { + this.inst.x = inst.initialparam1 + (inst.targetparam1 - inst.initialparam1) * factor; + } else { + this.inst.x += ((inst.targetparam1 - inst.initialparam1) * factor) - inst.lastKnownValue; + inst.lastKnownValue = ((inst.targetparam1 - inst.initialparam1) * factor); + } + } else if (inst.tweened === 8) { + if (inst.enforce) { + this.inst.y = inst.initialparam2 + (inst.targetparam2 - inst.initialparam2) * factor; + } else { + this.inst.y += ((inst.targetparam2 - inst.initialparam2) * factor) - inst.lastKnownValue2; + inst.lastKnownValue2 = ((inst.targetparam2 - inst.initialparam2) * factor); + } + } else if (inst.tweened === 9) { + var scalex = inst.initialparam1 + (inst.targetparam1 - inst.initialparam1) * factor; + var scaley = inst.initialparam2 + (inst.targetparam2 - inst.initialparam2) * factor; + if (this.inst.width < 0) scalex = inst.initialparam1 + (inst.targetparam1 + inst.initialparam1) * -factor; + if (this.inst.height < 0) scaley = inst.initialparam2 + (inst.targetparam2 + inst.initialparam2) * -factor; + if (inst.enforce) { + this.inst.width = this.inst.curFrame.width * scalex; + this.inst.height = this.inst.curFrame.height * scaley; + } else { + if (this.inst.width < 0) { + this.inst.width = scalex * (this.inst.width / (-1+inst.lastKnownValue)); + inst.lastKnownValue = scalex + 1 + } else { + this.inst.width = scalex * (this.inst.width / (1+inst.lastKnownValue)); + inst.lastKnownValue = scalex - 1; + } + if (this.inst.height < 0) { + this.inst.height = scaley * (this.inst.height / (-1+inst.lastKnownValue2)); + inst.lastKnownValue2 = scaley + 1 + } else { + this.inst.height = scaley * (this.inst.height / (1+inst.lastKnownValue2)); + inst.lastKnownValue2 = scaley - 1; + } + } + } + this.inst.set_bbox_changed(); + } + behinstProto.tick = function () + { + var dt = this.runtime.getDt(this.inst); + var inst = this.tween_list["default"]; + if (inst.state !== 0) { + if (inst.onStart) { + this.runtime.trigger(cr.behaviors.lunarray_LiteTween.prototype.cnds.OnStart, this.inst); + inst.onStart = false; + } + if (inst.onReverseStart) { + this.runtime.trigger(cr.behaviors.lunarray_LiteTween.prototype.cnds.OnReverseStart, this.inst); + inst.onReverseStart = false; + } + this.active = (inst.state == 1) || (inst.state == 2) || (inst.state == 4) || (inst.state == 5) || (inst.state == 6); + var factor = inst.OnTick(dt); + this.updateTween(inst, factor); + if (inst.onEnd) { + this.runtime.trigger(cr.behaviors.lunarray_LiteTween.prototype.cnds.OnEnd, this.inst); + inst.onEnd = false; + } + if (inst.onReverseEnd) { + this.runtime.trigger(cr.behaviors.lunarray_LiteTween.prototype.cnds.OnReverseEnd, this.inst); + inst.onReverseEnd = false; + } + } + }; + behaviorProto.cnds = {}; + var cnds = behaviorProto.cnds; + cnds.IsActive = function () + { + return (this.tween_list["default"].state !== 0); + }; + cnds.IsReversing = function () + { + return (this.tween_list["default"].state == 2); + }; + cnds.CompareProgress = function (cmp, v) + { + var inst = this.tween_list["default"]; + return cr.do_cmp((inst.progress / inst.duration), cmp, v); + }; + cnds.OnThreshold = function (cmp, v) + { + var inst = this.tween_list["default"]; + this.threshold = (cr.do_cmp((inst.progress / inst.duration), cmp, v)); + var ret = (this.oldthreshold != this.threshold) && (this.threshold); + if (ret) { + this.oldthreshold = this.threshold; + } + return ret; + }; + cnds.OnStart = function () + { + if (this.tween_list["default"] === undefined) + return false; + return this.tween_list["default"].onStart; + }; + cnds.OnReverseStart = function () + { + if (this.tween_list["default"] === undefined) + return false; + return this.tween_list["default"].onReverseStart; + }; + cnds.OnEnd = function () + { + if (this.tween_list["default"] === undefined) + return false; + return this.tween_list["default"].onEnd; + }; + cnds.OnReverseEnd = function () + { + if (this.tween_list["default"] === undefined) + return false; + return this.tween_list["default"].onReverseEnd; + }; + behaviorProto.acts = {}; + var acts = behaviorProto.acts; + acts.Start = function (startmode, current) + { + this.threshold = false; + this.oldthreshold = false; + this.useCurrent = (current == 1); + this.startTween(startmode); + }; + acts.Stop = function (stopmode) + { + this.stopTween(stopmode); + }; + acts.Reverse = function (revMode) + { + this.threshold = false; + this.oldthreshold = false; + this.reverseTween(revMode); + }; + acts.ProgressTo = function (progress) + { + this.setProgressTo(progress); + }; + acts.SetDuration = function (x) + { + if (isNaN(x)) return; + if (x < 0) return; + if (this.tween_list["default"] === undefined) return; + this.tween_list["default"].duration = x; + }; + acts.SetEnforce = function (x) + { + if (this.tween_list["default"] === undefined) return; + this.tween_list["default"].enforce = (x===1); + }; + acts.SetInitial = function (x) + { + if (this.tween_list["default"] === undefined) return; + var init = this.parseCurrent(this.tween_list["default"].tweened, x); + this.tween_list["default"].setInitial(init); + }; + acts.SetTarget = function (targettype, absrel, x) + { + if (this.tween_list["default"] === undefined) return; + if (isNaN(x)) return; + var inst = this.tween_list["default"]; + var parsed = x + ""; + this.targetmode = absrel; + var x1 = ""; + var x2 = ""; + if (absrel === 1) { + this.target = "relative(" + parsed + ")"; + switch (targettype) { + case 0: x1 = (this.inst.x + x); x2 = inst.targetparam2; break; + case 1: x1 = inst.targetparam1; x2 = (this.inst.y + x); break; + case 2: x1 = "" + cr.to_degrees(this.inst.angle + cr.to_radians(x)); x2 = x1; break; //angle + case 3: x1 = "" + (this.inst.opacity*100) + x; x2 = x1; break; //opacity + case 4: x1 = (this.inst.width + x); x2 = inst.targetparam2; break; //width + case 5: x1 = inst.targetparam1; x2 = (this.inst.height + x); break; //height + case 6: x1 = x; x2 = x; break; //value + default: break; + } + parsed = x1 + "," + x2; + } else { + switch (targettype) { + case 0: x1 = x; x2 = inst.targetparam2; break; + case 1: x1 = inst.targetparam1; x2 = x; break; + case 2: x1 = x; x2 = x; break; //angle + case 3: x1 = x; x2 = x; break; //opacity + case 4: x1 = x; x2 = inst.targetparam2; break; //width + case 5: x1 = inst.targetparam1; x2 = x; break; //height + case 6: x1 = x; x2 = x; break; //value + default: break; + } + parsed = x1 + "," + x2; + this.target = parsed; + } + var init = this.parseCurrent(this.tween_list["default"].tweened, "current"); + var targ = this.parseCurrent(this.tween_list["default"].tweened, parsed); + inst.setInitial(init); + inst.setTarget(targ); + }; + acts.SetTweenedProperty = function (x) + { + if (this.tween_list["default"] === undefined) return; + this.tween_list["default"].tweened = x; + }; + acts.SetEasing = function (x) + { + if (this.tween_list["default"] === undefined) return; + this.tween_list["default"].easefunc = x; + }; + acts.SetEasingParam = function (x, a, p, t, s) + { + if (this.tween_list["default"] === undefined) return; + this.tween_list["default"].easingparam[x].optimized = false; + this.tween_list["default"].easingparam[x].a = a; + this.tween_list["default"].easingparam[x].p = p; + this.tween_list["default"].easingparam[x].t = t; + this.tween_list["default"].easingparam[x].s = s; + }; + acts.ResetEasingParam = function () + { + if (this.tween_list["default"] === undefined) return; + this.tween_list["default"].optimized = true; + }; + acts.SetValue = function (x) + { + var inst = this.tween_list["default"]; + this.value = x; + if (inst.tweened === 6) + inst.setInitial( this.parseCurrent(inst.tweened, "current") ); + }; + acts.SetParameter = function (tweened, easefunction, target, duration, enforce) + { + if (this.tween_list["default"] === undefined) { + this.addToTweenList("default", tweened, easefunction, initial, target, duration, enforce, 0); + } else { + var inst = this.tween_list["default"]; + inst.tweened = tweened; + inst.easefunc = easefunction; + inst.setInitial( this.parseCurrent(tweened, "current") ); + inst.setTarget( this.parseCurrent(tweened, target) ); + inst.duration = duration; + inst.enforce = (enforce === 1); + } + }; + behaviorProto.exps = {}; + var exps = behaviorProto.exps; + exps.State = function (ret) + { + var parsed = "N/A"; + switch (this.tween_list["default"].state) { + case 0: parsed = "paused"; break; + case 1: parsed = "playing"; break; + case 2: parsed = "reversing"; break; + case 3: parsed = "seeking"; break; + default: break; + } + ret.set_string(parsed); + }; + exps.Progress = function (ret) + { + var progress = this.tween_list["default"].progress/this.tween_list["default"].duration; + ret.set_float(progress); + }; + exps.Duration = function (ret) + { + ret.set_float(this.tween_list["default"].duration); + }; + exps.Target = function (ret) + { + var inst = this.tween_list["default"]; + var parsed = "N/A"; + switch (inst.tweened) { + case 0: parsed = inst.targetparam1; break; + case 1: parsed = inst.targetparam2; break; + case 2: parsed = inst.targetparam1; break; + case 3: parsed = inst.targetparam1; break; + case 4: parsed = inst.targetparam1; break; + case 5: parsed = inst.targetparam2; break; + case 6: parsed = inst.targetparam1; break; + default: break; + } + ret.set_float(parsed); + }; + exps.Value = function (ret) + { + var tval = this.value; + ret.set_float(tval); + }; + exps.Tween = function (ret, a_, b_, x_, easefunc_) + { + var currX = (x_>1.0?1.0:x_); + var factor = easeFunc(easefunc_, currX<0.0?0.0:currX, 0.0, 1.0, 1.0, false, false); + ret.set_float(a_ + factor * (b_-a_)); + }; +}()); +cr.getObjectRefTable = function () { return [ + cr.plugins_.IDNet, + cr.plugins_.LocalStorage, + cr.plugins_.Mouse, + cr.plugins_.Rex_Date, + cr.plugins_.Arr, + cr.plugins_.Browser, + cr.plugins_.Audio, + cr.plugins_.cjs, + cr.plugins_.Dictionary, + cr.plugins_.Function, + cr.plugins_.Rex_TimeAwayL, + cr.plugins_.Sprite, + cr.plugins_.SpriteFontPlus, + cr.plugins_.Spritefont2, + cr.plugins_.Text, + cr.plugins_.Touch, + cr.behaviors.lunarray_LiteTween, + cr.behaviors.Sin, + cr.behaviors.Bullet, + cr.behaviors.Pin, + cr.system_object.prototype.cnds.IsGroupActive, + cr.system_object.prototype.cnds.OnLayoutStart, + cr.plugins_.Arr.prototype.acts.JSONLoad, + cr.system_object.prototype.cnds.For, + cr.plugins_.Arr.prototype.exps.Height, + cr.plugins_.Spritefont2.prototype.acts.SetCharacterWidth, + cr.plugins_.Arr.prototype.exps.At, + cr.system_object.prototype.exps.loopindex, + cr.plugins_.Spritefont2.prototype.cnds.CompareInstanceVar, + cr.plugins_.Spritefont2.prototype.acts.SetPos, + cr.plugins_.Sprite.prototype.exps.X, + cr.plugins_.Sprite.prototype.exps.Y, + cr.plugins_.Spritefont2.prototype.acts.SetText, + cr.plugins_.Sprite.prototype.cnds.OnCreated, + cr.system_object.prototype.acts.Wait, + cr.behaviors.lunarray_LiteTween.prototype.acts.Start, + cr.plugins_.Function.prototype.cnds.OnFunction, + cr.plugins_.Browser.prototype.acts.ConsoleLog, + cr.system_object.prototype.acts.ResetGlobals, + cr.system_object.prototype.acts.RestartLayout, + cr.system_object.prototype.acts.SetVar, + cr.plugins_.Function.prototype.exps.Param, + cr.plugins_.Touch.prototype.cnds.IsTouchingObject, + cr.plugins_.Sprite.prototype.acts.SetScale, + cr.plugins_.Touch.prototype.cnds.OnTouchEnd, + cr.system_object.prototype.cnds.LayerVisible, + cr.system_object.prototype.acts.GoToLayout, + cr.system_object.prototype.acts.SetLayerVisible, + cr.system_object.prototype.cnds.Compare, + cr.system_object.prototype.exps.tokencount, + cr.system_object.prototype.acts.AddVar, + cr.plugins_.Sprite.prototype.cnds.CompareInstanceVar, + cr.plugins_.Sprite.prototype.cnds.PickTopBottom, + cr.plugins_.Sprite.prototype.exps.AnimationFrame, + cr.plugins_.Dictionary.prototype.acts.AddKey, + cr.plugins_.Function.prototype.acts.CallFunction, + cr.system_object.prototype.cnds.CompareVar, + cr.plugins_.Sprite.prototype.cnds.IsVisible, + cr.system_object.prototype.acts.SubVar, + cr.system_object.prototype.exps.str, + cr.plugins_.Sprite.prototype.acts.SetInstanceVar, + cr.plugins_.Sprite.prototype.acts.SetOpacity, + cr.plugins_.Sprite.prototype.acts.MoveToBottom, + cr.plugins_.Dictionary.prototype.cnds.HasKey, + cr.plugins_.Dictionary.prototype.exps.Get, + cr.system_object.prototype.cnds.LayerCmpOpacity, + cr.system_object.prototype.exps.layoutname, + cr.plugins_.Rex_TimeAwayL.prototype.acts.StartTimer, + cr.plugins_.Sprite.prototype.cnds.IsOnLayer, + cr.plugins_.Browser.prototype.acts.GoToURLWindow, + cr.plugins_.LocalStorage.prototype.acts.CheckItemExists, + cr.system_object.prototype.acts.CreateObject, + cr.system_object.prototype.exps.layoutwidth, + cr.behaviors.lunarray_LiteTween.prototype.acts.Stop, + cr.plugins_.Sprite.prototype.acts.SetAngle, + cr.plugins_.Sprite.prototype.acts.SetVisible, + cr.plugins_.Sprite.prototype.acts.SetMirrored, + cr.plugins_.Sprite.prototype.acts.SetAnimFrame, + cr.plugins_.Sprite.prototype.cnds.CompareOpacity, + cr.system_object.prototype.cnds.TriggerOnce, + cr.system_object.prototype.cnds.ForEach, + cr.system_object.prototype.exps.find, + cr.plugins_.Sprite.prototype.acts.MoveToTop, + cr.plugins_.Sprite.prototype.exps.Angle, + cr.plugins_.Sprite.prototype.acts.SetPos, + cr.plugins_.Sprite.prototype.exps.ImagePointX, + cr.plugins_.Sprite.prototype.exps.ImagePointY, + cr.plugins_.Sprite.prototype.cnds.IsOverlapping, + cr.plugins_.Sprite.prototype.acts.MoveToLayer, + cr.plugins_.Spritefont2.prototype.acts.MoveToLayer, + cr.system_object.prototype.exps.uppercase, + cr.system_object.prototype.exps.tokenat, + cr.system_object.prototype.exps["int"], + cr.system_object.prototype.cnds.Else, + cr.system_object.prototype.cnds.EveryTick, + cr.system_object.prototype.exps.zeropad, + cr.plugins_.Rex_TimeAwayL.prototype.acts.GetTimer, + cr.system_object.prototype.exps.floor, + cr.plugins_.Rex_TimeAwayL.prototype.exps.ElapsedTime, + cr.plugins_.Rex_TimeAwayL.prototype.cnds.OnGetTimer, + cr.plugins_.Rex_TimeAwayL.prototype.cnds.IsValid, + cr.plugins_.Sprite.prototype.acts.Destroy, + cr.system_object.prototype.exps.random, + cr.system_object.prototype.exps.layoutheight, + cr.plugins_.Spritefont2.prototype.acts.SetOpacity, + cr.plugins_.Sprite.prototype.cnds.OnDestroyed, + cr.system_object.prototype.acts.SetLayerOpacity, + cr.system_object.prototype.exps.layeropacity, + cr.plugins_.Sprite.prototype.cnds.CompareFrame, + cr.plugins_.Function.prototype.cnds.CompareParam, + cr.plugins_.Audio.prototype.acts.Play, + cr.plugins_.Touch.prototype.cnds.OnTouchObject, + cr.plugins_.IDNet.prototype.cnds.menuVisible, + cr.plugins_.IDNet.prototype.acts.ShowLeaderBoard, + cr.plugins_.Sprite.prototype.acts.SetPosToObject, + cr.plugins_.Sprite.prototype.exps.Opacity, + cr.system_object.prototype.exps.choose, + cr.plugins_.Sprite.prototype.acts.SetSize, + cr.behaviors.lunarray_LiteTween.prototype.acts.SetTarget, + cr.behaviors.Pin.prototype.acts.Pin, + cr.plugins_.Sprite.prototype.acts.SetAnim, + cr.plugins_.Spritefont2.prototype.acts.SetEffectParam, + cr.plugins_.Sprite.prototype.acts.SetEffectParam, + cr.behaviors.lunarray_LiteTween.prototype.cnds.CompareProgress, + cr.behaviors.lunarray_LiteTween.prototype.acts.SetDuration, + cr.behaviors.Sin.prototype.cnds.IsActive, + cr.behaviors.Sin.prototype.acts.SetActive, + cr.behaviors.Sin.prototype.acts.SetMagnitude, + cr.system_object.prototype.exps.max, + cr.behaviors.Sin.prototype.acts.SetPeriod, + cr.plugins_.Sprite.prototype.exps.UID, + cr.plugins_.Sprite.prototype.cnds.IsOnScreen, + cr.plugins_.Sprite.prototype.cnds.PickByUID, + cr.behaviors.Bullet.prototype.acts.SetEnabled, + cr.behaviors.Bullet.prototype.acts.SetAngleOfMotion, + cr.plugins_.Sprite.prototype.cnds.OnCollision, + cr.behaviors.Pin.prototype.acts.Unpin, + cr.plugins_.Sprite.prototype.acts.MoveAtAngle, + cr.behaviors.Bullet.prototype.acts.SetSpeed, + cr.plugins_.Sprite.prototype.cnds.IsOutsideLayout, + cr.behaviors.Bullet.prototype.acts.SetGravity, + cr.plugins_.Sprite.prototype.cnds.IsAnimPlaying, + cr.behaviors.Pin.prototype.cnds.IsPinned, + cr.plugins_.SpriteFontPlus.prototype.acts.SetText, + cr.system_object.prototype.exps.round, + cr.system_object.prototype.exps.loadingprogress, + cr.system_object.prototype.cnds.OnLoadFinished, + cr.plugins_.Touch.prototype.cnds.OnTouchStart, + cr.plugins_.IDNet.prototype.cnds.blacklisted, + cr.plugins_.Text.prototype.acts.SetText, + cr.plugins_.Mouse.prototype.cnds.OnClick, + cr.plugins_.Arr.prototype.cnds.CompareX, + cr.plugins_.cjs.prototype.acts.ExecuteJS, + cr.plugins_.Arr.prototype.acts.SetX, + cr.plugins_.Audio.prototype.acts.SetSilent, + cr.system_object.prototype.cnds.Every, + cr.plugins_.Browser.prototype.exps.ExecJS, + cr.plugins_.Audio.prototype.cnds.IsSilent, + cr.plugins_.Sprite.prototype.acts.StopAnim, + cr.plugins_.IDNet.prototype.cnds.isNotAuthorized, + cr.plugins_.IDNet.prototype.acts.Inititalize, + cr.plugins_.Touch.prototype.cnds.OnTapGestureObject, + cr.plugins_.IDNet.prototype.cnds.sponsored, + cr.plugins_.Browser.prototype.acts.CancelFullScreen, + cr.plugins_.Browser.prototype.exps.Domain, + cr.plugins_.Mouse.prototype.cnds.IsOverObject, + cr.plugins_.Mouse.prototype.acts.SetCursor, + cr.plugins_.SpriteFontPlus.prototype.acts.SetVisible, + cr.plugins_.IDNet.prototype.cnds.UserIsNotAuthorized, + cr.plugins_.IDNet.prototype.cnds.UserIsAuthorized, + cr.plugins_.IDNet.prototype.cnds.isAuthorized, + cr.plugins_.IDNet.prototype.exps.UserName, + cr.plugins_.IDNet.prototype.acts.OnlineSavesLoad, + cr.plugins_.IDNet.prototype.exps.GateOnlineSavesData, + cr.plugins_.IDNet.prototype.acts.LoginPopup, + cr.plugins_.IDNet.prototype.cnds.dataReady, + cr.plugins_.Dictionary.prototype.acts.JSONLoad, + cr.plugins_.LocalStorage.prototype.cnds.OnItemExists, + cr.plugins_.LocalStorage.prototype.exps.ItemValue, + cr.plugins_.LocalStorage.prototype.cnds.OnItemMissing, + cr.plugins_.LocalStorage.prototype.acts.SetItem, + cr.plugins_.Dictionary.prototype.exps.AsJSON, + cr.plugins_.IDNet.prototype.acts.OnlineSavesSave, + cr.plugins_.LocalStorage.prototype.acts.ClearStorage, + cr.plugins_.IDNet.prototype.acts.OnlineSavesRemove, + cr.plugins_.Dictionary.prototype.acts.Clear, + cr.plugins_.IDNet.prototype.acts.SubmitScore +];}; diff --git a/games/knifehit/data.js b/games/knifehit/data.js new file mode 100644 index 00000000..c91343f9 --- /dev/null +++ b/games/knifehit/data.js @@ -0,0 +1 @@ +{"project": [null,"Loading",[[0,true,false,false,false,false,false,false,false,false],[1,true,false,false,false,false,false,false,false,false],[2,true,false,false,false,false,false,false,false,false],[3,false,false,false,false,false,false,false,false,false],[4,false,false,false,false,false,false,false,false,false],[5,true,false,false,false,false,false,false,false,false],[6,true,false,false,false,false,false,false,false,false],[7,false,false,false,false,false,false,false,false,false],[8,false,false,false,false,false,false,false,false,false],[9,true,false,false,false,false,false,false,false,false],[10,true,false,false,false,false,false,false,false,false],[11,false,true,true,true,true,true,true,true,false],[12,false,true,true,true,true,true,true,true,true],[13,false,true,true,true,true,true,true,true,true],[14,false,true,true,true,true,true,true,true,false],[15,true,false,false,false,false,false,false,false,false]],[["t0",11,false,[431166139140275],0,0,null,[["Default",5,false,1,0,false,836377869511150,[["images/btnfb-sheet0.png",2047,0,0,120,112,1,0.5,0.5089285969734192,[],[],0]]]],[],false,false,209202126811869,[],null],["t1",11,false,[431166139140275],0,0,null,[["Default",5,false,1,0,false,667691559251160,[["images/btngift-sheet0.png",4571,0,0,114,107,1,0.5,0.5046728849411011,[],[],0]]]],[],false,false,692104268120020,[],null],["t2",11,false,[431166139140275],0,0,null,[["Default",5,false,1,0,false,403559938352157,[["images/btnknife-sheet0.png",12183,0,0,148,132,1,0.5067567825317383,0.5075757503509522,[],[],0]]]],[],false,false,153621551187557,[],null],["t3",11,false,[431166139140275],0,0,null,[["Default",5,false,1,0,false,228812989295725,[["images/btnstar-sheet0.png",4923,0,0,117,114,1,0.504273533821106,0.5087719559669495,[],[],0]]]],[],false,false,417192575762115,[],null],["t4",11,false,[431166139140275],0,0,null,[["Default",5,false,1,0,false,440638335021415,[["images/btnplay-sheet0.png",34588,0,0,372,161,1,0.5,0.5031055808067322,[],[],0]]]],[],false,false,120531639497017,[],null],["t5",11,false,[431166139140275],0,0,null,[["Default",5,false,1,0,false,873319324548741,[["images/btnsettings-sheet0.png",1494,0,0,67,67,1,0.5074626803398132,0.5074626803398132,[],[-0.3582086861133575,-0.3582086861133575,-0.01492568850517273,-0.5074626803398132,0.3432832956314087,-0.3582086861133575,0.4925373196601868,-0.01492568850517273,0.3432832956314087,0.3432832956314087,-0.01492568850517273,0.4925373196601868,-0.3582086861133575,0.3432832956314087,-0.5074626803398132,-0.01492568850517273],0]]]],[],false,false,275837703593430,[],null],["t6",11,false,[431166139140275],0,0,null,[["Default",5,false,1,0,false,594965123351672,[["images/btnsetting-sheet0.png",9605,0,0,125,125,1,0.5040000081062317,0.5040000081062317,[],[-0.3373330235481262,-0.3373330235481262,-0.00400000810623169,-0.4895071983337402,0.3365799784660339,-0.3445799946784973,0.4742609858512878,-0.00400000810623169,0.3293330073356628,0.3293330073356628,-0.00400000810623169,0.4525219798088074,-0.3300870060920715,0.3220869898796082,-0.4822609126567841,-0.00400000810623169],0]]]],[],false,false,922101910873832,[],null],["t7",11,false,[],0,0,null,[["Default",5,false,1,0,false,607933404394498,[["images/btnclose-sheet0.png",5976,0,0,101,103,1,0.5049505233764648,0.5048543810844421,[],[],0]]]],[],false,false,917019699575654,[],null],["t8",11,false,[],0,0,null,[["Default",5,false,1,0,false,860741475846068,[["images/btnequip-sheet0.png",19287,0,0,243,105,1,0.5020576119422913,0.5047619342803955,[],[],0]]]],[],false,false,500528901373335,[],null],["t9",11,false,[],0,0,null,[["Default",5,false,1,0,false,218100361907682,[["images/btnrestart-sheet0.png",31426,0,0,313,135,1,0.5015974640846252,0.5037037134170532,[],[],0]]]],[],false,false,698184626980486,[],null],["t10",11,false,[],0,0,null,[["Default",5,false,1,0,false,126370376002175,[["images/btnhome-sheet0.png",4128,0,0,160,36,1,0.5,0.5,[],[],0]]]],[],false,false,818112420051085,[],null],["t11",11,false,[736012786201548,616038726640090],0,0,null,[["Default",5,false,1,0,false,616022793801297,[["images/btnequip2-sheet0.png",5563,0,0,112,48,1,0.5,0.5,[],[],0]]]],[],false,false,839996753166983,[],null],["t12",11,false,[431166139140275],0,0,null,[["Default",5,false,1,0,false,557017980936240,[["images/title1-sheet0.png",38781,0,0,214,611,1,0.5,0.5008183121681213,[],[0.196262001991272,-0.394435316324234,0.3271030187606812,0.438625693321228,0,0.456628680229187,-0.33644899725914,0.4418987035751343,-0.33644899725914,-0.4435352087020874,0,-0.4762684106826782],0]]]],[],false,false,590936227142283,[],null],["t13",11,false,[431166139140275],0,0,null,[["Default",5,false,1,0,false,441789490855397,[["images/title2-sheet0.png",13597,0,0,184,384,1,0.5,0.5,[],[0.1959599852561951,-0.3928529918193817,0.3266000151634216,0.4385910034179688,0,0.4565590023994446,-0.3359310030937195,0.4418579936027527,-0.3359310030937195,-0.4418573975563049,0,-0.4745270907878876],0]]]],[],false,false,986301449517699,[],null],["t14",11,false,[431166139140275],0,0,null,[["Default",0,false,1,0,false,731617339970907,[["images/title3-sheet0.png",9085,0,0,80,571,1,0.5,0.5008756518363953,[],[0.1931599974632263,-0.3944026529788971,0.3219339847564697,0.4384673237800598,0,0.4564653635025024,-0.3311319947242737,0.4417393207550049,-0.3311319947242737,-0.4434906542301178,0,-0.4762163460254669],0]]]],[],false,false,936630381795904,[],null],["t15",11,false,[431166139140275],0,0,null,[["Default",5,false,1,0,false,400855678350603,[["images/menuapple-sheet0.png",3976,0,0,55,69,1,0.5090909004211426,0.5072463750839233,[],[-0.09090891480445862,-0.1739133894443512,-0.01818189024925232,-0.3188403844833374,0.2545450925827026,-0.3188403844833374,0.4545450806617737,-0.01449236273765564,0.3090910911560059,0.3478256464004517,-0.01818189024925232,0.4347826242446899,-0.327272891998291,0.3478256464004517,-0.4909090995788574,-0.01449236273765564],0]]]],[],false,false,753486293987813,[],null],["t16",11,false,[431166139140275],0,0,null,[["Default",5,false,1,0,false,751850628797448,[["images/menuknife-sheet0.png",5743,0,0,47,219,1,0.5106382966041565,0.5022830963134766,[],[-0.1276592910289764,-0.4200913012027741,-0.02127629518508911,-0.456620991230011,0.2127656936645508,-0.4429223835468292,0.3191487193107605,-0.004566103219985962,0.1914896965026856,0.4337899088859558,-0.02127629518508911,0.4977169036865234,-0.1914893090724945,0.429223895072937,-0.3191493153572083,-0.004566103219985962],0]]]],[],false,false,223486249496583,[],null],["t17",11,false,[431166139140275],0,0,null,[["Default",5,false,1,0,false,639856725663192,[["images/square-sheet0.png",94,0,0,50,50,1,0.5,0.5,[],[],4]]]],[],false,false,975027421661722,[],null],["t18",11,false,[],0,0,null,[["Default",5,false,1,0,false,189372914711360,[["images/background-sheet0.png",191062,0,0,900,1350,1,0.5,0.5,[],[],1]]]],[],false,true,136932058168353,[],null],["t19",11,false,[431166139140275],0,0,null,[["Default",5,false,1,0,false,168548034301566,[["images/sprite-sheet0.png",93,0,0,20,20,1,0.5,0.5,[],[],1]]]],[],false,false,831286221768599,[],null],["t20",11,false,[],1,1,null,[["Default",5,false,1,0,false,366227422757136,[["images/twoknives-sheet0.png",1469,0,0,200,200,1,0.5049999952316284,0.5049999952316284,[],[-0.5,-0.449999988079071,0.4950000047683716,-0.449999988079071,0.4950000047683716,0.4449999928474426,-0.5,0.4449999928474426],0]]]],[["LiteTween",16,499654839447603]],false,false,239859068064907,[["setcolor","SetColor"]],null],["t21",11,false,[],0,0,null,[["Default",5,false,1,0,false,132324482506313,[["images/equipbox-sheet0.png",2110,0,0,583,681,1,0.5008576512336731,0.5007342100143433,[],[-0.1743566393852234,0.01132076978683472,-0.0008576512336730957,-0.2688172161579132,0.2443843483924866,-0.1011932194232941,0.2443843483924866,0.09972476959228516,-0.0008576512336730957,0.4992657899856567,-0.1743566393852234,-0.01278921961784363],0]]]],[],false,false,683006986418961,[],null],["t22",11,false,[821709175745471,623385623978381,992460837666681,913624580085849,479242593911568],0,0,null,[["Default",0,false,1,0,false,214578494200268,[["images/knifeback-sheet0.png",394,1,1,100,100,1,0.5,0.5,[],[],0],["images/knifeback-sheet0.png",394,103,1,100,100,1,0.5,0.5,[],[],0]]],["simple",0,false,1,0,false,322922527588873,[["images/knifeback-sheet0.png",394,1,103,100,100,1,0.5,0.5,[],[],0],["images/knifeback-sheet0.png",394,103,103,100,100,1,0.5,0.5,[],[],0]]]],[],false,false,127000747198960,[],null],["t23",11,false,[],0,0,null,[["Default",5,false,1,0,false,268584135787345,[["images/newbest-sheet0.png",34001,0,0,426,199,1,0.5,0.5025125741958618,[],[-0.3873240053653717,-0.2613065838813782,0.4929580092430115,-0.4874371886253357,0.4483569860458374,-0.005025565624237061,0.3990610241889954,0.2814074158668518,0,0.3819094300270081,-0.4906103312969208,0.4773873686790466,-0.4413146078586578,-0.005025565624237061],0]]]],[],false,false,663890693567701,[],null],["t24",11,false,[],0,0,null,[["Default",5,false,1,0,false,990848316555220,[["images/scoreback-sheet0.png",69619,0,0,619,363,1,0.5008077621459961,0.5013774037361145,[],[-0.4426494538784027,-0.4022037982940674,0.4555732607841492,-0.4269972145557404,0.4329562187194824,0.3856745958328247,-0.4474959671497345,0.4077135920524597],0]]]],[],false,false,541072800967072,[],null],["t25",11,false,[873965433483800,779858400756190],0,0,null,[["Default",5,false,1,0,false,244945681566693,[["images/shine-sheet0.png",4906,0,0,186,253,1,0,0.7114624381065369,[],[0.5968189835548401,-0.4761984348297119,0.656682014465332,-0.5096404552459717,0.618369996547699,0.0970955491065979],0]]]],[],false,false,982988734059503,[],null],["t26",11,false,[746631543757030,634735678705796],0,0,null,[["Default",0,false,1,0,false,141899677372220,[["images/knifeborder-sheet0.png",157,0,0,100,100,1,0.5,0.5,[],[],0],["images/knifeborder-sheet1.png",157,0,0,100,100,1,0.5,0.5,[],[],0]]]],[],false,false,288323040335334,[],null],["t27",13,false,[426656415837208],0,0,["images/txtwhite.png",30833,0],null,[],false,false,776183023478076,[],null],["t28",13,false,[191704805214722],0,1,["images/txtorange.png",36109,0],null,[],false,false,112695626368738,[["setcolor","SetColor"]],null],["t29",4,false,[],0,0,null,null,[],true,false,694543781884856,[],null],["t30",4,false,[],0,0,null,null,[],true,false,148330866279437,[],null],["t31",13,false,[967362685564206],0,0,["images/txtyellow.png",30833,0],null,[],false,false,239232006531755,[],null],["t32",15,false,[],0,0,null,null,[],false,false,621548439010877,[],null,[1]],["t33",9,false,[],0,0,null,null,[],false,false,908569386742827,[],null,[]],["t34",1,false,[],0,0,null,null,[],false,false,182366735889023,[],null,[]],["t35",6,false,[],0,0,null,null,[],false,false,826576673464381,[],null,[0,0,0,1,1,600,600,10000,1]],["t36",3,false,[],0,0,null,null,[],true,false,587812338852861,[],null],["t37",10,false,[],0,0,null,null,[],false,false,922719032656167,[],null,[]],["t38",5,false,[],0,0,null,null,[],false,false,981084438285371,[],null,[]],["t39",11,false,[588206941839877,491960460608869,191831116064887],3,0,null,[["Default",5,false,1,0,false,634966353649747,[["images/circle-sheet2.png",9615,0,0,446,445,1,0.5,0.5011236071586609,[],[-0.3520179986953735,-0.3528085947036743,0,-0.4966292381286621,0.3520179986953735,-0.3528085947036743,0.4955160021781921,-0.002247601747512817,0.3520179986953735,0.3505613803863525,0,0.4966294169425964,-0.3520179986953735,0.3505613803863525,-0.4955157041549683,-0.002247601747512817],0]]],["Boss",0,false,1,0,false,222890915517905,[["images/circle-sheet1.png",978924,1,603,450,450,1,0.5,0.5,[],[-0.3466669917106628,-0.3388859927654266,0,-0.4844444096088409,0.3466669917106628,-0.3388859927654266,0.4822220206260681,2.497434616088867e-005,0.3444439768791199,0.3367639780044556,0,0.4844939708709717,-0.3444440066814423,0.3367639780044556,-0.4822221994400024,2.497434616088867e-005],0],["images/circle-sheet1.png",978924,453,603,450,450,1,0.5022222399711609,0.5,[],[-0.3469822406768799,-0.3373299837112427,-0.001111268997192383,-0.4822221994400024,0.3447607755661011,-0.3373299837112427,0.4800047874450684,2.998113632202148e-005,0.3425437808036804,0.3352270126342773,-0.001111268997192383,0.4822819828987122,-0.3447652459144592,0.3352270126342773,-0.4822273254394531,2.998113632202148e-005],0],["images/circle-sheet1.png",978924,905,603,450,450,1,0.5,0.5,[],[-0.3466669917106628,-0.3389289975166321,0,-0.4844940006732941,0.3466669917106628,-0.3389289975166321,0.4822220206260681,0,0.3444439768791199,0.3367559909820557,0,0.4844939708709717,-0.3444440066814423,0.3367559909820557,-0.4822221994400024,0],0],["images/circle-sheet1.png",978924,1357,603,450,450,1,0.5,0.5,[],[-0.3466669917106628,-0.3373299837112427,0,-0.4822221994400024,0.3466669917106628,-0.3373299837112427,0.4822220206260681,2.998113632202148e-005,0.3444439768791199,0.3352270126342773,0,0.4822819828987122,-0.3444440066814423,0.3352270126342773,-0.4822221994400024,2.998113632202148e-005],0],["images/circle-sheet1.png",978924,1,1055,450,450,1,0.5,0.5022222399711609,[],[-0.3466669917106628,-0.3392272591590881,0,-0.4844444394111633,0.3466669917106628,-0.3392272591590881,0.4822220206260681,-0.001111268997192383,0.3444439768791199,0.3348377346992493,0,0.482221782207489,-0.3444440066814423,0.3348377346992493,-0.4822221994400024,-0.001111268997192383],0],["images/circle-sheet1.png",978924,453,1055,450,450,1,0.5022222399711609,0.5022222399711609,[],[-0.3466662466526032,-0.336222231388092,-2.384185791015625e-007,-0.4801481366157532,0.3466667532920837,-0.336222231388092,0.482221782207489,-0.001111268997192383,0.344444751739502,0.3318517804145813,-2.384185791015625e-007,0.4779257774353027,-0.3444442451000214,0.3318517804145813,-0.4822222292423248,-0.001111268997192383],0],["images/circle-sheet1.png",978924,905,1055,450,450,1,0.5,0.504444420337677,[],[-0.3438130021095276,-0.3511114120483398,-0.001085996627807617,-0.4866666197776794,0.3416410088539124,-0.3511114120483398,0.4756569862365723,-0.004444420337677002,0.3394439816474915,0.3399995565414429,-0.001085996627807617,0.4799996018409729,-0.3416160047054291,0.3399995565414429,-0.4778282940387726,-0.004444420337677002],0],["images/circle-sheet1.png",978924,1357,1055,450,450,1,0.4622222185134888,0.5,[],[-0.3088892102241516,-0.3466669917106628,0.03777778148651123,-0.4955555498600006,0.3844447731971741,-0.3466669917106628,0.5199998021125794,0,0.3822217583656311,0.3444439768791199,0.03777778148651123,0.4955559968948364,-0.306666225194931,0.3444439768791199,-0.4444444179534912,0],0],["images/circle-sheet1.png",978924,1,1507,450,450,1,0.5,0.5022222399711609,[],[-0.3387809991836548,-0.3312592506408691,2.497434616088867e-005,-0.4735308289527893,0.3388310074806213,-0.3312592506408691,0.4713129997253418,-2.384185791015625e-007,0.3366590142250061,0.3291357755661011,2.497434616088867e-005,0.4735307693481445,-0.3366090059280396,0.3291357755661011,-0.4712623059749603,-2.384185791015625e-007],0],["images/circle-sheet1.png",978924,453,1507,450,450,1,0.5222222208976746,0.5133333206176758,[],[-0.3666662275791168,-0.3600003123283386,-0.02000021934509277,-0.5088889002799988,0.3266667723655701,-0.3600003123283386,0.4577777981758118,-0.01333332061767578,0.3244447708129883,0.3311106562614441,-0.02000021934509277,0.4822226762771606,-0.364444226026535,0.3311106562614441,-0.5,-0.01333332061767578],0],["images/circle-sheet1.png",978924,905,1507,450,450,1,0.5,0.5,[],[-0.3466669917106628,-0.3358809947967529,0,-0.4801383018493652,0.3466669917106628,-0.3358809947967529,0.4822220206260681,0,0.3444439768791199,0.333728015422821,0,0.4801380038261414,-0.3444440066814423,0.333728015422821,-0.4822221994400024,0],0],["images/circle-sheet1.png",978924,1357,1507,450,450,1,0.5,0.5,[],[-0.3466669917106628,-0.3466669917106628,0,-0.4955555498600006,0.3466669917106628,-0.3466669917106628,0.4822220206260681,0,0.3444439768791199,0.3444439768791199,0,0.4955559968948364,-0.3444440066814423,0.3444439768791199,-0.4822221994400024,0],0]]],["BossA",0,false,1,0,false,109844833715266,[["images/circle-sheet0.png",351351,1300,1215,600,600,1,0.5,0.5,[],[-0.4833332896232605,0.4983329772949219,0.4833329916000366,0.4983329772949219,0.4833329916000366,0.4983329772949219,0.4833329916000366,0.4983329772949219,0.4833329916000366,0.4983329772949219,0.4833329916000366,0.4983329772949219,-0.4833332896232605,0.4983329772949219,-0.4833332896232605,0.4983329772949219],0],["images/circle-sheet0.png",351351,1355,1,605,605,1,0.5008264183998108,0.5008264183998108,[],[-0.4743801057338715,0.1074385643005371,0.4859505891799927,-0.484297513961792,0.4859505891799927,0.4958676099777222,0.4859505891799927,0.4958676099777222,0.4859505891799927,0.4958676099777222,0.4859505891799927,0.4958676099777222,-0.4876033067703247,0.4958676099777222,-0.4876033067703247,0.4958676099777222],0],["images/circle-sheet0.png",351351,608,1270,600,600,1,6.316666603088379,1.763333320617676,[],[-6.296666622161865,-1.15833330154419,-5.699999809265137,-1.754999995231628,-5.334999561309815,-0.7666662931442261,-5.334999561309815,-0.7666662931442261,-5.334999561309815,-0.7666662931442261,-5.699999809265137,-0.7666662931442261,-6.296666622161865,-0.7666662931442261,-6.296666622161865,-0.7666662931442261],0],["images/circle-sheet0.png",351351,1,1300,600,600,1,0.5,0.5,[],[-0.4833332896232605,0.1949999928474426,-0.4833332896232605,-0.4016667008399963,0.1449999809265137,0.4966670274734497,0.3666669726371765,0.4966670274734497,-0.1066670119762421,0.4966670274734497,-0.4833332896232605,0.4966670274734497,-0.4833332896232605,0.4966670274734497,-0.4833332896232605,0.4966670274734497],0],["images/circle-sheet0.png",351351,1355,608,605,605,1,0.5008264183998108,0.5008264183998108,[],[-0.3719004392623901,-0.4975206255912781,0.4842975735664368,-0.4975206255912781,0.4842975735664368,-0.4975206255912781,0.4842975735664368,0.03966957330703735,0.4842975735664368,0.370248556137085,0.4842975735664368,0.4942145943641663,-0.4677686095237732,0.4942145943641663,-0.4809917211532593,0.03966957330703735],0],["images/circle-sheet1.png",978924,1,1,600,600,1,0.5,0.5,[],[-0.4799999892711639,-0.4950000047683716,0.1549999713897705,-0.4950000047683716,0.4816669821739197,-0.4950000047683716,0.4816669821739197,0.04666697978973389,0.4816669821739197,0.3799999952316284,0.1549999713897705,0.4950000047683716,-0.4799999892711639,0.4950000047683716,-0.4799999892711639,0.04666697978973389],0],["images/circle-sheet1.png",978924,603,1,600,600,1,0.5,0.5,[],[-0.4833332896232605,-0.4950000047683716,-0.4833332896232605,-0.4950000047683716,0.2366669774055481,-0.425000011920929,0.4583330154418945,0.1600000262260437,-0.01499998569488525,0.4933339953422546,-0.4833332896232605,0.4966670274734497,-0.4833332896232605,0.4966670274734497,-0.4833332896232605,0.1600000262260437],0],["images/circle-sheet1.png",978924,1205,1,600,600,1,0.5,0.5,[],[-0.3766669929027557,-0.4816667139530182,0.488332986831665,-0.4816667139530182,0.488332986831665,-0.4816667139530182,0.488332986831665,-0.4816667139530182,0.488332986831665,-0.4816667139530182,0.488332986831665,0.4833329916000366,-0.4733332991600037,0.04666697978973389,-0.4866667091846466,-0.4816667139530182],0],["images/circle-sheet0.png",351351,693,663,605,605,1,0.5008264183998108,0.5008264183998108,[],[-0.484297513961792,-0.4991735219955444,0.2099176049232483,-0.4991735219955444,0.4809916019439697,-0.4991735219955444,0.4809916019439697,-0.4991735219955444,0.4809916019439697,-0.4991735219955444,0.2099176049232483,0.4975205659866333,-0.484297513961792,0.06611555814743042,-0.484297513961792,-0.4991735219955444],0],["images/circle-sheet0.png",351351,693,1,660,660,1,0.4621212184429169,0.5,[],[-0.4454545080661774,-0.4939393997192383,-0.4454545080661774,-0.4939393997192383,0.2121208012104034,-0.4939393997192383,0.4136367738246918,-0.4939393997192383,-0.0166662335395813,-0.4939393997192383,-0.4454545080661774,0.4954550266265869,-0.4454545080661774,0.02424198389053345,-0.4454545080661774,-0.4939393997192383],0],["images/circle-sheet0.png",351351,1,693,605,605,1,0.5206611752510071,0.5123966932296753,[],[-0.3851241767406464,-0.5074380040168762,0.4561988115310669,-0.5074380040168762,0.4561988115310669,-0.5074380040168762,0.4561988115310669,-0.5074380040168762,0.4561988115310669,-0.5074380040168762,0.4561988115310669,0.4545453190803528,-0.4809917807579041,-0.5074380040168762,-0.4942148625850678,-0.5074380040168762],0],["images/circle-sheet0.png",351351,1,1,690,690,1,0.5,0.5,[],[-0.4855071902275085,-0.4985507130622864,0.1681159734725952,-0.4985507130622864,0.4855070114135742,-0.4985507130622864,0.4855070114135742,-0.4985507130622864,0.4855070114135742,-0.4985507130622864,0.1681159734725952,0.4739130139350891,-0.4855071902275085,-0.4985507130622864,-0.4855071902275085,-0.4985507130622864],0]]]],[["LiteTween",16,931985477072403],["Sine",17,294080738461626],["L_Create",16,681735708507858]],false,false,806619963876556,[],null],["t40",11,false,[133865536363336,657396939119698,592724106414494,872627611653037,260101219720865],0,0,null,[["Default",0,false,1,0,false,915082415254570,[["images/knife-sheet1.png",91966,693,1,131,617,1,0.5038167834281921,0,[["Imagepoint 1",0.5038167834281921,0.5008103847503662]],[-0.2824427783489227,0.1880059987306595,-0.06488579511642456,0.07293359935283661,0.2061071991920471,0.006482980214059353,0.2977102398872376,1,-0.3206107616424561,1],0],["images/knife-sheet2.png",93014,1,1,127,613,1,0.5039370059967041,0,[["Imagepoint 1",0.5039370059967041,0.5008156895637512]],[-0.3837230205535889,0.3197390139102936,-0.02572602033615112,0.009787970222532749,0.3997119665145874,0.3539969921112061,0.1716060042381287,1,-0.2419910132884979,1],0],["images/knife-sheet1.png",91966,826,1,127,621,1,0.5039370059967041,0,[["Imagepoint 1",0.5039370059967041,0.500805139541626]],[-0.320730984210968,0,0.3128569722175598,0,0.2975900173187256,1,-0.320730984210968,1],0],["images/knife-sheet2.png",93014,757,1,83,622,1,0.5060241222381592,0,[["Imagepoint 1",0.5060241222381592,0.5]],[-0.3228181004524231,0,0.3107698559761047,0,0.2955029010772705,1,-0.3228181004524231,1],0],["images/knife-sheet2.png",93014,669,1,86,608,1,0.5,0,[["Imagepoint 1",0.5,0.5]],[-0.3167939782142639,0,0.3167939782142639,0,0.3015270233154297,1,-0.3167939782142639,1],0],["images/knife-sheet1.png",91966,1,1,137,672,1,0.5036496520042419,0,[["Imagepoint 1",0.5036496520042419,0.5]],[-0.3204436302185059,0,0.313144326210022,0,0.2978773713111877,1,-0.3204436302185059,1],0],["images/knife-sheet2.png",93014,487,1,92,618,1,0.5,0,[["Imagepoint 1",0.5,0.5]],[-0.3167939782142639,0,0.3167939782142639,0,0.3015270233154297,1,-0.3167939782142639,1],0],["images/knife-sheet0.png",70499,1,1,210,659,1,0.5,0,[["Imagepoint 1",0.5,0.500758707523346]],[-0.3167939782142639,0,0.3167939782142639,0,0.3015270233154297,1,-0.3167939782142639,1],0],["images/knife-sheet1.png",91966,277,1,145,622,1,0.5034482479095459,0,[["Imagepoint 1",0.5034482479095459,0.5]],[-0.3202422261238098,0,0.313345730304718,0,0.2980787754058838,1,-0.3202422261238098,1],0],["images/knife-sheet0.png",70499,416,1,181,649,1,0.5027624368667603,0,[["Imagepoint 1",0.5027624368667603,0.5007703900337219]],[-0.153810441493988,0.1063169986009598,-0.01933643221855164,0.01848999969661236,0.1261865496635437,0.09861329942941666,0.1993165612220764,1,-0.2201094329357147,1],0],["images/knife-sheet1.png",91966,140,1,135,668,1,0.5037037134170532,0,[["Imagepoint 1",0.5037037134170532,0.5]],[-0.2316087186336517,0.164671003818512,-0.003703713417053223,0.008982020430266857,0.1945722699165344,0.1766469925642014,0.2978233098983765,1,-0.3204976916313171,1],0],["images/knife-sheet0.png",70499,213,1,201,660,1,0.5024875402450562,0,[["Imagepoint 1",0.5024875402450562,0.5]],[-0.3192815184593201,0,0.3143064379692078,0,0.2990394830703735,1,-0.3192815184593201,1],0],["images/knife-sheet2.png",93014,581,1,86,609,1,0.5,0,[["Imagepoint 1",0.5,0.5008209943771362]],[-0.3167939782142639,0,0.3167939782142639,0,0.3015270233154297,1,-0.3167939782142639,1],0],["images/knife-sheet1.png",91966,424,1,138,625,1,0.5,0,[["Imagepoint 1",0.5,0.5008000135421753]],[-0.3167939782142639,0,0.3167939782142639,0,0.3015270233154297,1,-0.3167939782142639,1],0],["images/knife-sheet0.png",70499,599,1,166,593,1,0.5,0,[["Imagepoint 1",0.5,0.5008431673049927]],[-0.3167939782142639,0,0.3167939782142639,0,0.3015270233154297,1,-0.3167939782142639,1],0],["images/knife-sheet2.png",93014,130,1,124,620,1,0.5,0,[["Imagepoint 1",0.5,0.5]],[-0.3167939782142639,0,0.3167939782142639,0,0.3015270233154297,1,-0.3167939782142639,1],0],["images/knife-sheet0.png",70499,917,1,90,632,1,0.3888888955116272,0,[["Imagepoint 1",0.5,0.5]],[-0.2056828886270523,0,0.4279050827026367,0,0.4126381278038025,1,-0.2056828886270523,1],0],["images/knife-sheet2.png",93014,256,1,114,630,1,0.5,0,[["Imagepoint 1",0.5,0.5]],[-0.3167939782142639,0,0.3167939782142639,0,0.3015270233154297,1,-0.3167939782142639,1],0],["images/knife-sheet0.png",70499,767,1,148,643,1,0.5,0,[["Imagepoint 1",0.5,0.5007776021957398]],[-0.3167939782142639,0,0.3167939782142639,0,0.3015270233154297,1,-0.3167939782142639,1],0],["images/knife-sheet1.png",91966,564,1,127,642,1,0.5039370059967041,0,[["Imagepoint 1",0.5039370059967041,0.5]],[-0.320730984210968,0,0.3128569722175598,0,0.2975900173187256,1,-0.320730984210968,1],0],["images/knife-sheet2.png",93014,372,1,113,604,1,0.5044247508049011,0,[["Imagepoint 1",0.5044247508049011,0.5]],[-0.321218729019165,0,0.3123692274093628,0,0.2971022725105286,1,-0.321218729019165,1],0]]],["m",0,false,1,0,false,919045808725694,[["images/knife-sheet1.png",91966,693,1,131,617,1,0.5038167834281921,-0.5024310946464539,[],[-0.3206107616424561,0.5024310946464539,0.3129771947860718,0.5024310946464539,0.2977102398872376,1.502431154251099,-0.3206107616424561,1.502431154251099],0],["images/knife-sheet2.png",93014,1,1,127,613,1,0.5039370059967041,-0.5024470090866089,[],[-0.320730984210968,0.5024470090866089,0.3128569722175598,0.5024470090866089,0.2975900173187256,1.502447009086609,-0.320730984210968,1.502447009086609],0],["images/knife-sheet1.png",91966,826,1,127,621,1,0.5039370059967041,-0.5024154782295227,[],[-0.320730984210968,0.5024154782295227,0.3128569722175598,0.5024154782295227,0.2975900173187256,1.502415418624878,-0.320730984210968,1.502415418624878],0],["images/knife-sheet2.png",93014,757,1,83,622,1,0.5060241222381592,-0.5032154321670532,[],[-0.3228181004524231,0.5032154321670532,0.3107698559761047,0.5032154321670532,0.2955029010772705,1.503215432167053,-0.3228181004524231,1.503215432167053],0],["images/knife-sheet2.png",93014,669,1,86,608,1,0.5,-0.5016447305679321,[],[-0.3167939782142639,0.5016447305679321,0.3167939782142639,0.5016447305679321,0.3015270233154297,1.501644730567932,-0.3167939782142639,1.501644730567932],0],["images/knife-sheet1.png",91966,1,1,137,672,1,0.5036496520042419,-0.5029761791229248,[],[-0.3204436302185059,0.5029761791229248,0.313144326210022,0.5029761791229248,0.2978773713111877,1.502976179122925,-0.3204436302185059,1.502976179122925],0],["images/knife-sheet2.png",93014,487,1,92,618,1,0.5,-0.5032362341880798,[],[-0.3167939782142639,0.5032362341880798,0.3167939782142639,0.5032362341880798,0.3015270233154297,1.503236293792725,-0.3167939782142639,1.503236293792725],0],["images/knife-sheet0.png",70499,1,1,210,659,1,0.5047619342803955,-0.5022761821746826,[],[-0.3215559124946594,0.5022761821746826,0.3120320439338684,0.5022761821746826,0.2967650890350342,1.502276182174683,-0.3215559124946594,1.502276182174683],0],["images/knife-sheet1.png",91966,277,1,145,622,1,0.5034482479095459,-0.5032154321670532,[],[-0.3202422261238098,0.5032154321670532,0.313345730304718,0.5032154321670532,0.2980787754058838,1.503215432167053,-0.3202422261238098,1.503215432167053],0],["images/knife-sheet0.png",70499,416,1,181,649,1,0.5027624368667603,-0.5023112297058106,[],[-0.2201094329357147,0.5023112297058106,0.1814345717430115,0.5023112297058106,0.1993165612220764,1.502311229705811,-0.2422084510326386,1.502311229705811],0],["images/knife-sheet1.png",91966,140,1,135,668,1,0.5037037134170532,-0.5029940009117127,[],[-0.3204976916313171,0.5029940009117127,0.3130902647972107,0.5029940009117127,0.2978233098983765,1.502994060516357,-0.3204976916313171,1.502994060516357],0],["images/knife-sheet0.png",70499,213,1,201,660,1,0.5024875402450562,-0.5030303001403809,[],[-0.3192815184593201,0.5030303001403809,0.3143064379692078,0.5030303001403809,0.2990394830703735,1.503030300140381,-0.3192815184593201,1.503030300140381],0],["images/knife-sheet2.png",93014,581,1,86,609,1,0.5,-0.5024630427360535,[],[-0.3167939782142639,0.5024630427360535,0.3167939782142639,0.5024630427360535,0.3015270233154297,1.502463102340698,-0.3167939782142639,1.502463102340698],0],["images/knife-sheet1.png",91966,424,1,138,625,1,0.5072463750839233,-0.5023999810218811,[],[-0.3240403532981873,0.5023999810218811,0.3095476031303406,0.5023999810218811,0.2942806482315064,1.502399921417236,-0.3240403532981873,1.502399921417236],0],["images/knife-sheet0.png",70499,599,1,166,593,1,0.5060241222381592,-0.502529501914978,[],[-0.3228181004524231,0.502529501914978,0.3107698559761047,0.502529501914978,0.2955029010772705,1.502529501914978,-0.3228181004524231,1.502529501914978],0],["images/knife-sheet2.png",93014,130,1,124,620,1,0.5,-0.5032258033752441,[],[-0.3167939782142639,0.5032258033752441,0.3167939782142639,0.5032258033752441,0.3015270233154297,1.503225803375244,-0.3167939782142639,1.503225803375244],0],["images/knife-sheet0.png",70499,917,1,90,632,1,0.5,-0.503164529800415,[],[-0.3167939782142639,0.503164529800415,0.3167939782142639,0.503164529800415,0.3015270233154297,1.503164529800415,-0.3167939782142639,1.503164529800415],0],["images/knife-sheet2.png",93014,256,1,114,630,1,0.5,-0.5031746029853821,[],[-0.3167939782142639,0.5031746029853821,0.3167939782142639,0.5031746029853821,0.3015270233154297,1.503174543380737,-0.3167939782142639,1.503174543380737],0],["images/knife-sheet0.png",70499,767,1,148,643,1,0.5067567825317383,-0.5023328065872192,[],[-0.3235507607460022,0.5023328065872192,0.3100371956825256,0.5023328065872192,0.2947702407836914,1.502332806587219,-0.3235507607460022,1.502332806587219],0],["images/knife-sheet1.png",91966,564,1,127,642,1,0.5039370059967041,-0.5031152367591858,[],[-0.320730984210968,0.5031152367591858,0.3128569722175598,0.5031152367591858,0.2975900173187256,1.503115177154541,-0.320730984210968,1.503115177154541],0],["images/knife-sheet2.png",93014,372,1,113,604,1,0.5044247508049011,-0.5132450461387634,[],[-0.321218729019165,0.5132450461387634,0.3123692274093628,0.5132450461387634,0.2971022725105286,1.513245105743408,-0.321218729019165,1.513245105743408],0]]]],[],false,false,789284035161425,[],null],["t41",11,false,[197554051057864],1,0,null,[["Default",0,false,1,0,false,452144292701505,[["images/dot-sheet0.png",481,0,0,80,80,1,0.5,0.5,[],[-0.4625000059604645,-0.4625000059604645,0.4625000357627869,-0.4625000059604645,0.4625000357627869,0.4625000357627869,-0.4625000059604645,0.4625000357627869],0],["images/dot-sheet1.png",484,0,0,80,80,1,0.512499988079071,0.512499988079071,[],[-0.4749999940395355,-0.4749999940395355,0.4625000357627869,-0.4749999940395355,0.4625000357627869,0.4625000357627869,-0.4749999940395355,0.4625000357627869],0]]]],[["LiteTween",16,779504217411942]],false,false,873014188064089,[],null],["t42",11,false,[752346264610943],0,0,null,[["Default",0,false,1,0,false,447208510161196,[["images/miniknife-sheet0.png",1132,0,0,200,200,1,0.5049999952316284,0.5,[],[-0.3949999809265137,-0.4900000095367432,0.3899999856948853,-0.4900000095367432,0.3899999856948853,0.4900000095367432,-0.3949999809265137,0.4900000095367432],0],["images/miniknife-sheet1.png",1061,0,0,157,196,1,0.5031847357749939,0.5,[],[],0]]]],[],false,false,871799435363966,[],null],["t43",11,false,[947710613371733,780224871836678,145196446034341],1,1,null,[["Default",5,false,1,0,false,893042989295943,[["images/circle-sheet2.png",9615,0,0,446,445,1,0.5,0.5011236071586609,[],[-0.3520179986953735,-0.3528085947036743,0,-0.4966292381286621,0.3520179986953735,-0.3528085947036743,0.4955160021781921,-0.002247601747512817,0.3520179986953735,0.3505613803863525,0,0.4966294169425964,-0.3520179986953735,0.3505613803863525,-0.4955157041549683,-0.002247601747512817],0]]]],[["LiteTween",16,122655824363539]],false,false,537343339328693,[["blacknwhite","BlackWhite"]],null],["t44",11,false,[526667105741233],1,0,null,[["a1",0,false,1,0,false,382320852391931,[["images/broken-sheet0.png",62242,1,1,428,418,1,0.4883177578449249,0.559808611869812,[],[],0],["images/broken-sheet0.png",62242,431,1,421,356,1,0.4679335057735443,0.5477527976036072,[],[],0]]],["a2",0,false,1,0,false,107732322700763,[["images/broken-sheet0.png",62242,1,421,192,251,1,0.6458333134651184,0.02390438318252564,[],[-0.6458333134651184,0.1115536093711853,-0.6458333134651184,-0.02390438318252564,0.3541666865348816,-0.02390438318252564,0.3541666865348816,-0.02390438318252564,0.3541666865348816,0.9760956168174744,-0.6458333134651184,0.9760956168174744,0.3541666865348816,-0.02390438318252564,0.3541666865348816,-0.02390438318252564],0],["images/broken-sheet0.png",62242,195,421,194,230,1,0.9226804375648499,0.04782608523964882,[],[],0]]],["a3",0,false,1,0,false,884510781195415,[["images/broken-sheet0.png",62242,431,359,262,351,1,0.9122137427330017,0.692307710647583,[],[-0.8015267252922058,-0.5527067184448242,-0.5458017587661743,-0.6695157289505005,0.08778625726699829,-0.692307710647583,0.08778625726699829,-0.692307710647583,0.08778625726699829,0.307692289352417,-0.5458017587661743,0.307692289352417,0.08778625726699829,-0.692307710647583,0.08778625726699829,-0.692307710647583],0],["images/broken-sheet0.png",62242,695,359,274,276,1,0.9963503479957581,0.3659420311450958,[],[],0]]]],[["Bullet",18,262959893982654]],false,false,326622741172867,[],null],["t45",11,false,[],0,0,null,[["Default",5,false,1,0,false,742639057634525,[["images/detector-sheet0.png",94,0,0,50,50,1,0.5,0.5,[],[],1]]]],[],false,false,274113443132685,[],null],["t46",11,false,[],0,0,null,[["Default",5,false,1,0,false,160925286898027,[["images/particle-sheet0.png",290,0,0,20,20,1,0.5,0.5,[],[],0]]]],[],false,false,704248586762862,[],null],["t47",11,false,[419463444039958],0,0,null,[["Default",0,false,1,0,false,446221904053682,[["images/apple-sheet0.png",3637,0,0,78,90,1,0.5,0.5,[],[0.1576579809188843,-0.461240291595459,0.01351398229598999,-0.282945990562439,0.3108109831809998,0.4069769978523254,0.01351398229598999,0.492247998714447,-0.3243240118026733,0.4069769978523254],0]]]],[],false,false,314239839821024,[],null],["t48",11,false,[670260775719259],0,0,null,[["Default",5,false,1,0,false,623995643155518,[["images/btninstagift-sheet0.png",21617,0,0,226,334,1,0.5,0.5,[],[-0.4159291982650757,-0.4431138038635254,0,-0.4850299060344696,0.4159290194511414,-0.4431138038635254,0.4823009967803955,0,0.429203987121582,0.4520959854125977,0,0.5,-0.4292035102844238,0.4520959854125977,-0.4867256879806519,0],0]]]],[],false,false,129998254356847,[],null],["t49",11,false,[937262195767091],0,0,null,[["Default",5,false,1,0,false,431523549452043,[["images/btnfbgift-sheet0.png",17255,0,0,226,334,1,0.5,0.5,[],[-0.4159291982650757,-0.4431138038635254,0,-0.4850299060344696,0.4159290194511414,-0.4431138038635254,0.4823009967803955,0,0.429203987121582,0.4520959854125977,0,0.5,-0.4292035102844238,0.4520959854125977,-0.4867256879806519,0],0]]]],[],false,false,429009586952403,[],null],["t50",11,false,[],0,0,null,[["Default",0,false,1,0,false,706375960098425,[["images/btnsound-sheet0.png",9420,1,1,192,72,1,0.5,0.5,[],[],0],["images/btnsound-sheet0.png",9420,1,75,192,72,1,0.5,0.5,[],[],0]]]],[],false,false,583179196177197,[],null],["t51",11,false,[858388299868229],0,0,null,[["Default",5,false,1,0,false,760504271534361,[["images/btncleardata-sheet0.png",29850,0,0,332,148,1,0.5,0.5,[],[-0.4608433842658997,-0.412162184715271,0,-0.4662162065505981,0.460843026638031,-0.412162184715271,0.4849399924278259,0,0.4518070220947266,0.3918920159339905,0,0.4256759881973267,-0.4518072009086609,0.3918920159339905,-0.4849398136138916,0],0]]]],[],false,false,227776476511465,[],null],["t52",11,false,[],3,0,null,[["Default",0,false,1,0,false,903963768154928,[["images/apple-sheet0.png",3637,0,0,78,90,1,0.5,3.222222328186035,[],[-0.4833677113056183,-2.697351455688477,-0.2653760015964508,-2.931815385818481,0.003898024559020996,-2.89128041267395,0.2660260200500488,-2.910207271575928,0.4679489731788635,-2.774661302566528,0.5,-2.536337375640869,0.3108109831809998,-2.315245389938355,0.01351398229598999,-2.229974269866943,-0.3243240118026733,-2.315245389938355,-0.4775637984275818,-2.461853265762329],0],["images/apple2-sheet0.png",5334,0,0,78,90,1,0.5,0.5,[],[-0.06410300731658936,-0.1222220063209534,0,-0.2888889908790588,0.294871985912323,-0.3222219944000244,0.4871789813041687,0,0.3717949986457825,0.3888890147209168,0,0.5,-0.3717949986457825,0.3888890147209168,-0.4871794879436493,0],0]]]],[["Pin",19,495917335294658],["Bullet",18,169417070662490],["LiteTween",16,913647190473539]],false,false,152259483316789,[],null],["t53",11,false,[192900747792022],2,0,null,[["Default",5,false,1,0,false,340973268441255,[["images/obj_y8logo-sheet0.png",509,0,0,252,142,1,0.5,0.5070422291755676,[],[],0]]]],[["Pin",19,943690716085647],["LiteTween",16,802860828841500]],false,true,988914227407986,[],null],["t54",12,false,[],0,0,["images/loading_font.png",9589,0],null,[],false,true,682371767716210,[],null],["t55",14,false,[],0,0,null,null,[],false,false,435073790759042,[],null],["t56",14,false,[],0,0,null,null,[],false,false,771887482446327,[],null],["t57",11,false,[],0,0,null,[["Default",5,false,1,0,false,896225588153449,[["images/y8_message-sheet0.png",8362,0,0,481,370,1,0.5010395050048828,0.5,[],[-0.4948025047779083,-0.4918918907642365,0.4948024749755859,-0.4945946037769318,0.4948024749755859,0.4945949912071228,-0.4948025047779083,0.4918919801712036],0],["images/y8_message-sheet1.png",3440,0,0,481,370,1,0.5010395050048828,0.5,[],[-0.4948025047779083,-0.4918918907642365,0.4948024749755859,-0.4945946037769318,0.4948024749755859,0.4945949912071228,-0.4948025047779083,0.4918919801712036],0]]]],[],false,false,940343888352124,[],null],["t58",4,false,[],0,0,null,null,[],true,false,521052617994089,[],null],["t59",7,false,[],0,0,null,null,[],true,false,383943272068910,[],null],["t60",0,false,[],0,0,null,null,[],false,false,161118233713298,[],null,[]],["t61",2,false,[],0,0,null,null,[],false,false,454630466599741,[],null,[]],["t62",11,false,[],0,0,null,[["Default",5,false,1,0,false,167345411639629,[["images/online-sheet0.png",27206,0,0,466,366,1,0.5,0.5027322173118591,[],[],0],["images/online-sheet1.png",23263,0,0,466,366,1,0.5021459460258484,0.5,[],[],0]]]],[],false,false,995630103927724,[],null],["t63",11,false,[],0,0,null,[["Default",5,false,1,0,false,813602645136015,[["images/online2-sheet0.png",22408,0,0,466,366,1,0.5021459460258484,0.5,[],[],0]]]],[],false,false,212720545375282,[],null],["t64",11,false,[],0,0,null,[["Login",5,false,1,0,false,909588517869507,[["images/onlinebtn-sheet0.png",30312,1,1,230,110,1,0.5,0.5,[],[],0],["images/onlinebtn-sheet0.png",30312,1,113,230,110,1,0.5,0.5,[],[],0]]],["Play",5,false,1,0,false,671838822627215,[["images/onlinebtn-sheet1.png",33756,1,1,230,110,1,0.5,0.5,[],[],0],["images/onlinebtn-sheet1.png",33756,1,113,230,110,1,0.5,0.5,[],[],0]]]],[],false,false,900621258036474,[],null],["t65",11,false,[],0,0,null,[["Default",5,false,1,0,false,493222881310339,[["images/localsavebtn-sheet0.png",28316,1,1,230,110,1,0.5,0.5,[],[],0],["images/localsavebtn-sheet0.png",28316,1,113,230,110,1,0.5,0.5,[],[],0]]]],[],false,false,568218693296735,[],null],["t66",12,false,[],0,0,["images/welcomefont.png",13629,0],null,[],false,false,544392491653678,[],null],["t67",8,false,[],0,0,null,null,[],true,false,832942722453207,[],null],["t68",11,false,[431166139140275,523579355515598,384411206219614],1,0,null,[["leaderboard",5,false,1,0,false,195019036597110,[["images/leaderboard-sheet0.png",938,0,0,125,125,1,0.5040000081062317,0.5120000243186951,[],[],0]]]],[["Pin",19,271636730686237]],false,false,210599895114262,[],null],["t69",11,false,[431166139140275,854435207828700,376592436028849],1,0,null,[["leaderboard",5,false,1,0,false,692893052785681,[["images/leaderboard2-sheet0.png",519,0,0,67,67,1,0.5074626803398132,0.5074626803398132,[],[],0]]]],[["Pin",19,377641018586040]],false,false,135106811607357,[],null],["t70",11,false,[],0,0,null,[["Default",5,false,1,0,false,697550648798642,[["images/loadinggamelogo-sheet0.png",83624,0,0,512,512,1,0.5,0.5,[],[-0.4375,-0.4375,0,-0.494140625,0.4374999403953552,-0.4375,0.4941409826278687,0,0.4374999403953552,0.4374999403953552,0,0.4941409826278687,-0.4375,0.4374999403953552,-0.494140625,0],0]]]],[],false,true,687739365229223,[],null],["t71",11,true,[],2,0,null,null,[["Sine",17,317706253126372],["Sine2",17,824118417564251]],false,false,127975151544955,[],null],["t72",11,true,[431166139140275],1,0,null,null,[["LiteTween",16,138972566227287]],false,false,631576229787235,[],null],["t73",11,true,[],0,0,null,null,[],false,false,146485233894511,[],null],["t74",11,true,[133865536363336,657396939119698,592724106414494,872627611653037,260101219720865],4,0,null,null,[["LPos",16,368460822413081],["LOpac",16,709099522652428],["Bullet",18,783715225430065],["Pin",19,765196412521417]],false,false,693128470479198,[],null],["t75",11,true,[],3,0,null,null,[["L_Scale",16,332434586342323],["L_Opac",16,752118652623346],["Bullet",18,819960883216592]],false,false,669571067756202,[],null],["t76",11,true,[419463444039958],2,0,null,null,[["L_Scale",16,182069523765381],["L_Opac",16,590758177037630]],false,false,443762798327858,[],null]],[[71,12,13,14],[72,0,1,2,4,6,5,3,68,69,15,16,19,17,12,13,14],[73,51,7,8,11,0,49,1,10,48,2,4,9,6,5,50,3,68,69],[74,40],[75,46],[76,47]],[["Menu",720,1280,true,"MenuSheet",401328667076244,[["Back",0,347259700441806,true,[4,64,73],false,1,1,1,false,false,1,0,0,[[[360,640,0,900,1350,0,0,1,0.5,0.5,0,0,[]],18,0,[],[],[0,"Default",0,1]]],[]],["Menu",1,431890533903228,true,[255,255,255],true,1,1,1,false,false,1,0,0,[[[383,-241,0,214,611,0,-1.570796370506287,1,0.5,0.5008183121681213,0,0,[]],12,1,[[0.3]],[[1,5,0,6,0,0,0,3,0],[1,0,0,6,0,0,0,15,0],[0,0,17,"377, 195",0,1,1]],[0,"Default",0,1]],[[373,-386,0,184,384,0,-1.570796370506287,1,0.5,0.5,0,0,[]],13,2,[[0.5]],[[1,5,0,-6,0,0,0,3,0],[1,0,0,-6,0,0,0,15,0],[0,0,17,"365, 437",0,1,1]],[0,"Default",0,1]],[[340,-354,0,80,571,0,-1.570796370506287,1,0.5,0.5008756518363953,0,0,[]],14,3,[[0.4]],[[1,5,0,6,0,0,0,3,0],[1,0,0,6,0,0,0,15,0],[0,0,17,"369, 323",0,1,1]],[0,"Default",0,1]],[[374,1663,0,372,161,0,0,1,0.5,0.5031055808067322,0,0,[]],4,4,[[0.2]],[[0,0,14,"360, 992",0,1,1]],[0,"Default",0,1]],[[636,1351,0,114,107,0,0,1,0.5,0.5046728849411011,0,0,[]],1,5,[[0.5]],[[0,0,17,"636, 1190",0,1,1]],[0,"Default",0,1]],[[66,1367,0,148,132,0,0,1,0.5067567825317383,0.5075757503509522,0,0,[]],2,7,[[0.6]],[[0,0,17,"66, 1190",0,1,1]],[0,"Default",0,1]],[[-55,-36,0,67,67,0,0,1,0.5074626803398132,0.5074626803398132,0,0,[]],5,9,[[0.6]],[[0,0,17,"47, 47",0,1,1]],[0,"Default",0,1]],[[360.5,1462,0,47,219,0,0,1,0.5106382966041565,0.5022830963134766,0,0,[]],16,10,[[0]],[[1,0,8,"360,770",0,1,1]],[0,"Default",0,1]],[[763,-33,0,55,69,0,0,1,0.5090909004211426,0.5072463750839233,0,0,[]],15,11,[[0.5]],[[0,0,17,"683, 47",0,1,1]],[0,"Default",0,1]],[[-89,520,0,413,73,0,0,1,1,0.5,0,0,[]],27,12,[["stage"]],[],[96,96,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.,;:?!-_~#\"'&()[]|`\\/@ยฐ+=*$ยฃโ‚ฌ<>","STAGE 21",0.5,0,2,1,5,0,0,0]],[[357,-122,0,36,36,0,0.7853981852531433,1,0.5,0.5,0,0,[]],17,13,[[0.5]],[[0,0,14,"360, 615",0,0.3,1]],[0,"Default",0,1]],[[-480,627,0,413,73,0,0,1,0,0.5,0,0,[]],27,15,[["score"]],[],[96,96,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.,;:?!-_~#\"'&()[]|`\\/@ยฐ+=*$ยฃโ‚ฌ<>","STAGE 21",0.5,0,0,1,3,0,0,0]],[[-252,433,0,186,56,0,0,1,1,0.5,0,0,[[0.94,0.69,0.28]]],28,16,[["apple"]],[],[74,107,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.,;:?!-_~#\"'&()[]|`\\/@ยฐ+=*$ยฃโ‚ฌ<>","Text",0.5,0,2,1,5,0,0,0]],[[596,1501,0,162,73,0,0,1,0.5,0.5,0,0,[]],27,64,[["time"]],[],[96,96,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.,;:?!-_~#\"'&()[]|`\\/@ยฐ+=*$ยฃโ‚ฌ<>","STAGE 21",0.3,0,1,1,4,0,0,0]],[[360,1210,0,242.3424224853516,131.2688140869141,0,0,1,0.5,0.5070422291755676,0,0,[]],53,73,[[""]],[[],[0,0,23,"100,100",0,2.5,1]],[0,"Default",0,1]],[[141,-53,0,67,67,0,0,1,0.5074626803398132,0.5074626803398132,0,0,[]],69,45,[[0.3],[0],[1]],[[0,0,17,"141, 47",0,1,1],[]],[0,"Default",1,1]]],[]],["KnivesList",2,692482106887821,true,[2,30,36],false,1,1,1,false,false,1,0,0,[[[103,45,0,160,36,0,0,1,0.5,0.5,0,0,[]],10,54,[],[],[0,"Default",0,1]],[[-12,-411,0,150,150,0,0,1,0.5,0.5,0,0,[]],22,55,[[0],[""],[""],[0],[0]],[],[0,"Default",0,1]],[[1067,247.5409240722656,0,213.4592590332031,290.3504943847656,0,0,0.5,0,0.7114624381065369,0,0,[]],25,56,[[1],[1]],[],[0,"Default",0,1]],[[1074,242.5409240722656,0,213.4592590332031,290.3504943847656,0,3.141592741012573,0.5,0,0.7114624381065369,0,0,[]],25,57,[[1],[1]],[],[0,"Default",0,1]],[[1055,245.5409240722656,0,213.4592590332031,290.3504943847656,0,0.7853981852531433,0.5,0,0.7114624381065369,0,0,[]],25,58,[[-1],[0.5]],[],[0,"Default",0,1]],[[1062,206.4441223144531,0,163.7592163085938,222.7477569580078,0,-2.181661605834961,1,0,0.7114624381065369,0,0,[]],25,59,[[-1],[0.5]],[],[0,"Default",0,1]],[[1057,254.5409240722656,0,213.4592590332031,290.3504943847656,0,2.179790735244751,0.5,0,0.7114624381065369,0,0,[]],25,60,[[-1],[0.4]],[],[0,"Default",0,1]],[[1064,252.5409393310547,0,213.4592590332031,290.3504943847656,0,-1.069159150123596,0.699999988079071,0,0.7114624381065369,0,0,[]],25,61,[[-1],[0.6]],[],[0,"Default",0,1]],[[1055,248.5409545898438,0,213.4592590332031,290.3504943847656,0,1.246886014938355,0.699999988079071,0,0.7114624381065369,0,0,[]],25,62,[[-1],[0.6]],[],[0,"Default",0,1]],[[1062,257.5409240722656,0,213.4592590332031,290.3504943847656,0,-1.720173716545105,0.5,0,0.7114624381065369,0,0,[]],25,63,[[-1],[0.6]],[],[0,"Default",0,1]],[[360,373,0,678,100,0,0,1,0.5,0.5,0,0,[[0.94,0.69,0.28]]],28,69,[["price"]],[],[74,107,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.,;:?!-_~#\"'&()[]|`\\/@ยฐ+=*$ยฃโ‚ฌ<>","",0.4,0,1,1,4,0,0,0]],[[-730,274,0,150,150,0,0,1,0.5,0.5,0,0,[]],26,70,[[0],[0]],[],[0,"Default",0,1]],[[1015,597,0,51.62139892578125,21.94285774230957,0,0,1,0.5,0.5,0,0,[]],11,71,[[0],[0]],[],[0,"Default",0,1]]],[]],["Black",3,479885003243201,true,[0,0,0],false,1,1,0.8999999761581421,false,false,1,0,0,[],[]],["Apples",4,966910383521965,true,[255,255,255],true,1,1,1,false,false,1,0,0,[[[953.0369262695313,701.6327514648438,0,78,90,0,0,1,0.5,0.5,0,0,[]],47,67,[[0]],[[0,9,18,"0",0,0.5,1],[0,5,16,"0",0,0.7,1]],[0,"Default",0,1]],[[-438,154,0,408,193,0,0,1,0.5,0.5,0,0,[[0.94,0.69,0.28]]],28,68,[["applesnum"]],[],[74,107,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.,;:?!-_~#\"'&()[]|`\\/@ยฐ+=*$ยฃโ‚ฌ<>","Text",1,0,1,1,4,0,0,0]]],[]],["Settings",5,459126986653063,false,[1,23,28],false,1,1,1,false,false,1,0,0,[[[360,631,0,568,73,0,0,1,0.5,0.5,0,0,[]],27,72,[["settings"]],[],[96,96,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.,;:?!-_~#\"'&()[]|`\\/@ยฐ+=*$ยฃโ‚ฌ<>","Sounds",0.6,0,0,1,4,0,0,0]],[[360,460.5,0,494,130,0,0,1,0.5,0.5,0,0,[]],27,75,[["settings"]],[],[96,96,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.,;:?!-_~#\"'&()[]|`\\/@ยฐ+=*$ยฃโ‚ฌ<>","Settings",0.75,0,1,1,4,0,0,0]],[[517,632,0,192,72,0,0,1,0.5,0.5,0,0,[]],50,76,[],[],[0,"Default",0,1]],[[103,42,0,160,36,0,0,1,0.5,0.5,0,0,[]],10,78,[],[],[0,"Default",0,1]],[[360,877,0,332,148,0,0,1,0.5,0.5,0,0,[]],51,79,[[1]],[],[0,"Default",0,1]]],[]],["GoogleAdsBG",6,589311447166352,true,[255,255,255],true,1,1,1,false,false,1,0,0,[],[]]],[[null,29,14,[],[],[10,1,1]],[null,30,17,[],[],[10,1,1]],[null,36,65,[],[],[]],[null,58,91,[],[],[10,1,1]],[null,59,92,[],[],["myScripts.js"]],[null,67,102,[],[],[]]],[]],["Loading",720,1280,true,"Loading",280130386058988,[["Back",0,584284764115993,true,[4,64,73],false,1,1,1,false,false,1,0,0,[[[390,623,0,900,1350,0,0,1,0.5,0.5,0,0,[]],18,81,[],[],[0,"Default",0,1]],[[366,1133,0,300.3751220703125,162.7032012939453,0,0,1,0.5,0.5070422291755676,0,0,[]],53,83,[[""]],[[],[0,0,23,"100,100",0,2.5,1]],[0,"Default",0,1]],[[-30,874,0,780,64,0,0,1,0,0,0,0,[]],54,84,[],[],[29,30,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.,;:?!-_~#\"'&()[]|`\\/@ยฐ+=*$ยฃโ‚ฌ<>%","Loading 0%",2,0,1,1,0,0,0,0,"{\"\"c2array\"\":true,\"\"size\"\":[2,21,1],\"\"data\"\":[[[6],[5],[6],[7],[8],[9],[10],[12],[13],[14],[15],[16],[17],[18],[19],[20],[21],[22],[23],[25],[27]],[[\"\" \"\"],[\"\"|\"\"],[\"\"I.,:!'\"\"],[\"\"il;\"\"],[\"\"`\"\"],[\"\"()\\\\/\"\"],[\"\"j-[]ยฐ\"\"],[\"\"rt1\\\"\"\"\"],[\"\"f*\"\"],[\"\"ks\"\"],[\"\"Jacdeghnquvxyz023568?+=$โ‚ฌ<>\"\"],[\"\"EFLPbop79_~#\"\"],[\"\"BNRSUX4ยฃ\"\"],[\"\"DHKTYZ\"\"],[\"\"CV\"\"],[\"\"AGO&\"\"],[\"\"MQ\"\"],[\"\"mw\"\"],[\"\"%\"\"],[\"\"W\"\"],[\"\"@\"\"]]]}",-1]],[[360,479,0,512,512,0,0,1,0.5,0.5,0,0,[]],70,74,[],[],[0,"Default",0,1]]],[]]],[],[]],["saveWindows",720,1280,true,"saveWindows",709890415688010,[["Back",0,872051023495074,true,[4,64,73],false,1,1,1,false,false,1,0,0,[[[360,640,0,900,1350,0,0,1,0.5,0.5,0,0,[]],18,95,[],[],[0,"Default",0,1]],[[-30,874,0,780,64,0,0,1,0,0,0,0,[]],54,97,[],[],[29,30,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.,;:?!-_~#\"'&()[]|`\\/@ยฐ+=*$ยฃโ‚ฌ<>%","Loading Please Wait",2,0,1,1,0,0,0,0,"{\"\"c2array\"\":true,\"\"size\"\":[2,21,1],\"\"data\"\":[[[6],[5],[6],[7],[8],[9],[10],[12],[13],[14],[15],[16],[17],[18],[19],[20],[21],[22],[23],[25],[27]],[[\"\" \"\"],[\"\"|\"\"],[\"\"I.,:!'\"\"],[\"\"il;\"\"],[\"\"`\"\"],[\"\"()\\\\/\"\"],[\"\"j-[]ยฐ\"\"],[\"\"rt1\\\"\"\"\"],[\"\"f*\"\"],[\"\"ks\"\"],[\"\"Jacdeghnquvxyz023568?+=$โ‚ฌ<>\"\"],[\"\"EFLPbop79_~#\"\"],[\"\"BNRSUX4ยฃ\"\"],[\"\"DHKTYZ\"\"],[\"\"CV\"\"],[\"\"AGO&\"\"],[\"\"MQ\"\"],[\"\"mw\"\"],[\"\"%\"\"],[\"\"W\"\"],[\"\"@\"\"]]]}",-1]]],[]],["saveWindows",1,252983606005122,true,[255,255,255],true,1,1,1,false,false,1,0,0,[[[361,927,0,675.75,506.1749877929688,0,0,1,0.5021459460258484,0.5,0,0,[]],63,96,[],[],[0,"Default",0,1]],[[366,343,0,675.75,506.1749877929688,0,0,1,0.5021459460258484,0.5,0,0,[]],62,98,[],[],[0,"Default",1,1]],[[366,582,0,334.0499877929688,159.375,0,0,1,0.5,0.5,0,0,[]],64,99,[],[],[0,"Default",1,1]],[[361,1158,0,334.0499877929688,159.375,0,0,1,0.5,0.5,0,0,[]],65,100,[],[],[0,"Default",1,1]],[[-24,298,0,776,60,0,0,1,0,0,0,0,[]],66,101,[],[],[39,48,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.,;:?!-_~#\"'&()[]|`\\/@ยฐ+=*$ยฃโ‚ฌ<>%","WELCOME",0.95,0,1,1,0,0,0,0,"{\"\"c2array\"\":true,\"\"size\"\":[2,21,1],\"\"data\"\":[[[8],[8],[9],[10],[11],[12],[14],[15],[16],[17],[18],[20],[22],[23],[24],[25],[27],[28],[29],[30],[37]],[[\"\" \"\"],[\"\"|\"\"],[\"\"'\"\"],[\"\"Ii.,!\"\"],[\"\";:\"\"],[\"\"()[]\"\"],[\"\"ยฐ\"\"],[\"\"1-`>\"\"],[\"\"<\"\"],[\"\"\\\\/\"\"],[\"\"Ll\\\"\"*\"\"],[\"\"Jj\"\"],[\"\"CGScgs+=\"\"],[\"\"EFKPTXefkptx4~ยฃโ‚ฌ\"\"],[\"\"BDHNRUYZbdhnruyz369?$\"\"],[\"\"02578\"\"],[\"\"Vv\"\"],[\"\"Aa#&@%\"\"],[\"\"Mm\"\"],[\"\"OQoq_\"\"],[\"\"Ww\"\"]]]}",-1]]],[]],["GoogleAdsBG",2,431540425950462,true,[255,255,255],true,1,1,1,false,false,1,0,0,[],[]]],[],[]],["Blacklist",720,1280,true,"Blacklist",299791103981716,[["Back",0,900408169857815,true,[4,64,73],false,1,1,1,false,false,1,0,0,[[[360,640,0,900,1350,0,0,1,0.5,0.5,0,0,[]],18,85,[],[],[0,"Default",0,1]],[[365,617,0,202.9020233154297,109.9052658081055,0,0,1,0.5,0.5070422291755676,0,0,[]],53,86,[[""]],[[],[0,0,23,"100,100",0,2.5,1]],[0,"Default",0,1]],[[21,721,0,681,52,0,0,1,0,0,0,0,[]],55,87,[],[],["This website is blacklisted, please go to ",0,"24pt Arial","rgb(255,255,255)",1,0,0,0,0]],[[15,806,0,691,197,0,0,1,0,0,0,0,[]],55,88,[],[],["to play this game. If you are a website owner please unblock games link and request y8.com to remove your website from blacklisted list",0,"24pt Arial Narrow","rgb(255,255,255)",1,0,0,0,0]],[[14,763,0,687,60,0,0,1,0,0,0,0,[]],56,89,[],[],["http://www.y8.com/games/dd_connection",0,"bold 24pt Arial","rgb(255,255,0)",1,0,0,0,0]],[[-472,805,0,672.3265380859375,517.17431640625,0,0,1,0.5010395050048828,0.5,0,0,[]],57,90,[],[],[0,"Default",0,1]]],[]]],[],[]],["Game",720,1280,true,"GameSheet",829363245822988,[["Back",0,609539407129118,true,[4,57,67],false,1,1,1,false,false,1,0,0,[[[360,640,0,900,1350,0,0,1,0.5,0.5,0,0,[]],18,19,[],[],[0,"Default",0,1]]],[]],["Game",1,760025876971140,true,[255,255,255],true,1,1,1,false,false,1,0,0,[[[763,-33,0,55,69,0,0,1,0.5090909004211426,0.5072463750839233,0,0,[]],15,30,[[0]],[[0,0,17,"683, 47",0,0.3,1]],[0,"Default",0,1]],[[506,-160,0,186,56,0,0,1,1,0.5,0,0,[[0.94,0.69,0.28]]],28,34,[["apple"]],[],[74,107,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.,;:?!-_~#\"'&()[]|`\\/@ยฐ+=*$ยฃโ‚ฌ<>","Text",0.5,0,2,1,5,0,0,0]],[[360,504,0,51.96152496337891,51.96152496337891,0,0,1,0.5,0.5011236071586609,0,0,[]],39,20,[[3],[3],[1]],[[0,4,5,"0",0,2,1],[0,5,0,4,0,0,0,50,0],[1,1,17,"411, 411",0,0.5,1]],[0,"Default",0,1]],[[-85,-66,0,229,80,0,0,1,0,0.5,0,0,[[0.94,0.69,0.28]]],28,21,[["score"]],[],[74,107,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.,;:?!-_~#\"'&()[]|`\\/@ยฐ+=*$ยฃโ‚ฌ<>","Text",0.7,0,0,1,3,0,0,0]],[[360,116,0,510,114,0,0,1,0.5,0.5,0,0,[[1,1,1]]],28,22,[["stage"]],[],[74,107,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.,;:?!-_~#\"'&()[]|`\\/@ยฐ+=*$ยฃโ‚ฌ<>","Text",0.8,0,1,1,4,0,0,0]],[[-45,-13,0,20,20,0,0,1,0.5,0.5,0,0,[]],19,23,[[0]],[[0,0,17,"10, 36",0,0.3,1]],[1,"Default",0,1]],[[348.53125,41.70821380615234,0,25,25,0,0,1,0.5,0.5,0,0,[]],41,25,[[3]],[[0,5,8,"0",0,0.5,1]],[0,"Default",0,1]],[[244.53125,41.70821380615234,0,25,25,0,0,1,0.5,0.5,0,0,[]],41,26,[[1]],[[0,5,8,"0",0,0.5,1]],[0,"Default",0,1]],[[296.53125,41.70821380615234,0,25,25,0,0,1,0.5,0.5,0,0,[]],41,27,[[2]],[[0,5,8,"0",0,0.5,1]],[0,"Default",0,1]],[[401.53125,41.70821380615234,0,25,25,0,0,1,0.5,0.5,0,0,[]],41,28,[[4]],[[0,5,8,"0",0,0.5,1]],[0,"Default",0,1]],[[-280,662,0,56.44478225708008,56.44477844238281,0,-0.08726692199707031,0.800000011920929,0.5049999952316284,0.5,0,0,[]],42,29,[[0]],[],[0,"Default",0,1]],[[357,1208,0,44.36901473999023,208.9746704101563,0,0,1,0.5038167834281921,0,0,0,[]],40,32,[[0],[0],[0],[0],[0]],[[1,0,8,"360,1030",0,0.1,1],[1,5,8,"100",0,0.3,1],[5000,0,0,0,0,0],[]],[0,"Default",0,1]],[[360,1136,0,560,128,0,0,0.300000011920929,0.5,0.5,0,0,[]],45,31,[],[],[1,"Default",0,1]],[[-544,477,0,411,411,0,0,1,0.5,0.5011236071586609,0,0,[[0]]],43,33,[[3],[3],[1]],[[0,6,11,"100,100",0,2,1]],[0,"Default",0,1]],[[0,0,0,20,20,0,0,1,0.5,0.5,0,0,[]],46,37,[],[[1,1,5,"0,0",0,0.7,1],[0,5,17,"0",0,0.5,1],[1000,0,1000,0,1,1]],[0,"Default",0,1]],[[-687,1007,0,428,418,0,0,1,0.4883177578449249,0.559808611869812,0,0,[]],44,39,[[0]],[[1000,0,5000,0,0,1]],[0,"Default",0,1]],[[463,40,0,50,50,0,0,1,0.5049999952316284,0.5049999952316284,0,0,[[1,1,1]]],20,24,[],[[0,0,8,"360, 40",0,1,1]],[0,"Default",0,1]],[[954,271,0,78,90,0,0,1,0.5,3.222222328186035,0,0,[]],52,82,[],[[],[1000,0,5000,0,1,0],[0,1,8,"100,100",0,0.3,1]],[0,"Default",0,1]]],[]],["Lose",2,819242897961088,true,[34,34,34],false,1,1,1,false,false,1,0,0,[[[360.4618530273438,502.8104248046875,0,571.769775390625,335.3027954101563,0,0,1,0.5008077621459961,0.5013774037361145,0,0,[]],24,40,[],[],[0,"Default",0,1]],[[360.5,883.6266479492188,0,313,135,0,0,1,0.5015974640846252,0.5037037134170532,0,0,[]],9,41,[],[],[0,"Default",0,1]],[[360,570,0,413,73,0,0,1,0.5,0.5,0,0,[]],31,43,[["stage"]],[],[96,96,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.,;:?!-_~#\"'&()[]|`\\/@ยฐ+=*$ยฃโ‚ฌ<>","STAGE 21",0.6,0,1,1,4,0,0,0]],[[360,480,0,486,109,0,0,1,0.5,0.5,0,0,[]],27,42,[["bigscore"]],[],[96,96,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.,;:?!-_~#\"'&()[]|`\\/@ยฐ+=*$ยฃโ‚ฌ<>","12",1,0,1,1,4,0,0,0]],[[468,645,0,274.8864440917969,128.4093933105469,0,0,1,0.5,0.5025125741958618,0,0,[]],23,35,[],[],[0,"Default",0,1]],[[99,48,0,160,36,0,0,1,0.5,0.5,0,0,[]],10,44,[],[],[0,"Default",0,1]],[[148,1149,0,148,132,0,0,1,0.5067567825317383,0.5075757503509522,0,0,[]],2,46,[[0.6]],[[0,0,17,"148, 1149",0,1,1]],[0,"Default",0,1]],[[584,1147,0,125,125,0,0,1,0.5040000081062317,0.5040000081062317,0,0,[]],6,47,[[0.5]],[[0,0,17,"584, 1147",0,1,1]],[0,"Default",0,1]],[[360,214,0,242.3424224853516,131.2688140869141,0,0,1,0.5,0.5070422291755676,0,0,[]],53,6,[[""]],[[],[0,0,23,"100,100",0,2.5,1]],[0,"Default",0,1]],[[360,1147,0,125,125,0,0,1,0.5040000081062317,0.5120000243186951,0,0,[]],68,8,[[0.3],[0],[1]],[[0,0,17,"360, 1147",0,1,1],[]],[0,"Default",1,1]]],[]],["EquipBack",3,195603651828203,true,[0,0,0],false,1,1,0.699999988079071,false,false,1,0,0,[],[]],["Equip",4,619191869168598,true,[0,0,0],true,1,1,1,false,false,1,0,0,[[[360.5,640.5,0,583,681,0,0,1,0.5008576512336731,0.5007342100143433,0,0,[]],21,48,[],[],[0,"Default",0,1]],[[635,314,0,101,103,0,0,1,0.5049505233764648,0.5048543810844421,0,0,[]],7,49,[],[],[0,"Default",0,1]],[[360.5,883,0,243,105,0,0,1,0.5020576119422913,0.5047619342803955,0,0,[]],8,50,[],[],[0,"Default",0,1]],[[360,451,0,567,273,0,0,1,0.5,0.5,0,0,[]],27,51,[["defeat"]],[],[96,96,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.,;:?!-_~#\"'&()[]|`\\/@ยฐ+=*$ยฃโ‚ฌ<>","STAGE 21",0.8,0,1,0,4,0,0,0]],[[360,778,0,599,88,0,0,1,0.5,0.5,0,0,[]],31,52,[["defeat"]],[],[96,96,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.,;:?!-_~#\"'&()[]|`\\/@ยฐ+=*$ยฃโ‚ฌ<>","BOSS KNIFE UNLOCKE",0.55,0,1,1,4,0,0,0]],[[289,505,0,56.50891494750977,266.1526794433594,0,-0.6435660123825073,1,0.5038167834281921,0,0,0,[]],40,53,[[2],[0],[1],[0],[0]],[[0,0,8,"360,1030",0,0.1,1],[0,5,8,"100",0,0.3,1],[0,0,0,0,0,0],[]],[0,"Default",0,1]]],[]],["GoogleAdsBG",5,410200510997436,true,[255,255,255],true,1,1,1,false,false,1,0,0,[],[]]],[],[]]],[["MenuSheet",[[2,"y8Logo",false],[2,"Blacklist",false],[2,"Adsense",false],[2,"saveData",false],[1,"Flg",0,0,false,false,196253729035175,false],[1,"TimeFlg",0,0,false,false,273227903639865,false],[1,"GoKnivesPage",0,0,false,false,519301831994894,false],[1,"GoSettingsPage",0,0,false,false,593846567963965,false],[1,"ShowNum",0,1,false,false,106316383611608,false],[1,"SelectedKnife",0,0,false,false,802104418619396,false],[1,"UnlockedKnives",1,"",false,false,941254910958818,false],[1,"Stage",0,0,false,false,321561174957908,false],[1,"Score",0,0,false,false,725896990228554,false],[1,"Apples",0,0,false,false,363905107469061,false],[1,"BestScore",0,0,false,false,249539270997596,false],[1,"BestStage",0,0,false,false,198316280449279,false],[1,"Start",0,0,false,false,816326725601659,false],[1,"InKnivePage",0,0,false,false,501013451629344,false],[1,"InSettingsPage",0,0,false,false,900202050468646,false],[1,"GiftReady",0,1,false,false,324033898701440,false],[1,"S",0,0,false,false,132094318059957,false],[1,"H",0,0,false,false,620947376026031,false],[1,"M",0,0,false,false,121066783613645,false],[1,"D",0,0,false,false,498294391246245,false],[1,"BlackFade",0,0,false,false,398907278151151,false],[1,"Sound",0,1,false,false,906753126183405,false],[1,"SocialGift",1,"11",false,false,177381005158070,false],[0,[true,"SpriteFont"],false,null,746347296213907,[[-1,20,null,0,false,false,false,746347296213907,false,[[1,[2,"SpriteFont"]]]]],[],[[0,[true,"Setting Char Width"],false,null,267466132755845,[[-1,20,null,0,false,false,false,267466132755845,false,[[1,[2,"Setting Char Width"]]]]],[],[[0,null,false,null,160220809939084,[[-1,21,null,1,false,false,false,834804932724079,false]],[[29,22,null,560929322288526,false,[[1,[2,"{\"c2array\":true,\"size\":[2,45,1],\"data\":[[[14],[18],[20],[21],[22],[23],[25],[28],[29],[30],[31],[33],[35],[36],[38],[39],[40],[41],[42],[44],[45],[46],[47],[49],[50],[51],[52],[53],[54],[56],[57],[58],[59],[62],[64],[65],[66],[67],[68],[72],[76],[77],[81],[82],[94]],[[\"|\"],[\"'\"],[\"Il\"],[\"i\"],[\".:!\"],[\",;\"],[\"[]\"],[\"-\"],[\"(\"],[\")\"],[\"j\"],[\"`\"],[\"J\"],[\"ยฐ\"],[\"r\"],[\"t\\\"\"],[\"Ff\"],[\"E1\"],[\"s\\\\/\"],[\"z \"],[\"L\"],[\"c?\"],[\"S5~+=*<>\"],[\"P03678_$\"],[\"abp29ยฃ\"],[\"Tdehnq\"],[\"Buโ‚ฌ\"],[\"Zo4\"],[\"Cg\"],[\"k\"],[\"DHRvy\"],[\"KU\"],[\"Gx#\"],[\"Y\"],[\"N\"],[\"V\"],[\"O\"],[\"QX\"],[\"A\"],[\"&\"],[\"M\"],[\"@\"],[\"m\"],[\"w\"],[\"W\"]]]}"]]]],[30,22,null,207897162653603,false,[[1,[2,"{\"c2array\":true,\"size\":[2,33,1],\"data\":[[[12],[14],[15],[25],[27],[30],[31],[33],[34],[35],[37],[38],[40],[42],[43],[44],[45],[46],[47],[48],[49],[50],[51],[52],[53],[56],[57],[58],[59],[60],[66],[67],[72]],[[\"Il'|\"],[\"i.:!\"],[\",;\"],[\"jยฐ\"],[\"1()`\"],[\"r \"],[\"\\\"\\\\/\"],[\"f\"],[\"J[\"],[\"t]<>\"],[\"L\"],[\"~*\"],[\"sz7$\"],[\"ku?\"],[\"chnv-+=\"],[\"F\"],[\"EZx5\"],[\"Se269\"],[\"BHKPRTUay8\"],[\"bg34\"],[\"Nopq\"],[\"DVd0\"],[\"CXY\"],[\"Gยฃ\"],[\"A\"],[\"_&\"],[\"#\"],[\"O\"],[\"Q@โ‚ฌ\"],[\"w\"],[\"M\"],[\"W\"],[\"m\"]]]}"]]]]],[[0,null,false,null,872025034069363,[[-1,23,null,0,true,false,false,691119733807342,false,[[1,[2,""]],[0,[0,0]],[0,[5,[20,29,24,false,null],[0,1]]]]]],[[27,25,null,119772218515716,false,[[1,[20,29,26,false,null,[[0,1],[19,27]]]],[0,[20,29,26,false,null,[[0,0],[19,27]]]]]]]],[0,null,false,null,655204003984582,[[-1,23,null,0,true,false,false,879712321741352,false,[[1,[2,""]],[0,[0,0]],[0,[5,[20,29,24,false,null],[0,1]]]]]],[[31,25,null,189931895636044,false,[[1,[20,29,26,false,null,[[0,1],[19,27]]]],[0,[20,29,26,false,null,[[0,0],[19,27]]]]]]]],[0,null,false,null,966228662492870,[[-1,23,null,0,true,false,false,970881554072344,false,[[1,[2,""]],[0,[0,0]],[0,[5,[20,30,24,false,null],[0,1]]]]]],[[28,25,null,671430474586898,false,[[1,[20,30,26,false,null,[[0,1],[19,27]]]],[0,[20,30,26,false,null,[[0,0],[19,27]]]]]]]]]]]],[0,[true,"SpriteFont Position + Text"],false,null,464914386618484,[[-1,20,null,0,false,false,false,464914386618484,false,[[1,[2,"SpriteFont Position + Text"]]]]],[],[[0,null,false,null,974411097631301,[[27,28,null,0,false,false,false,139158320608732,false,[[10,0],[8,0],[7,[2,"stage"]]]]],[[27,29,null,502462702685133,false,[[0,[5,[20,17,30,false,null],[0,50]]],[0,[20,17,31,false,null]]]],[27,32,null,695528542771368,false,[[7,[10,[2,"STAGE "],[23,"BestStage"]]]]]]],[0,null,false,null,580244079897309,[[27,28,null,0,false,false,false,594966889462298,false,[[10,0],[8,0],[7,[2,"score"]]]]],[[27,29,null,665703190719807,false,[[0,[4,[20,17,30,false,null],[0,50]]],[0,[20,17,31,false,null]]]],[27,32,null,989893931574706,false,[[7,[10,[2,"SCORE "],[23,"BestScore"]]]]]]],[0,null,false,null,897793261035848,[[27,28,null,0,false,false,false,595750943136733,false,[[10,0],[8,0],[7,[2,"bigscore"]]]]],[[27,32,null,568548439105982,false,[[7,[23,"Score"]]]]]],[0,null,false,null,858476356385195,[[28,28,null,0,false,false,false,586160652580615,false,[[10,0],[8,0],[7,[2,"apple"]]]]],[[28,29,null,627642613750622,false,[[0,[5,[20,15,30,false,null],[0,40]]],[0,[4,[20,15,31,false,null],[0,7]]]]],[28,32,null,765665437085563,false,[[7,[23,"Apples"]]]]]],[0,null,false,null,431070170225980,[[28,28,null,0,false,false,false,863232814742920,false,[[10,0],[8,0],[7,[2,"stage"]]]]],[[28,32,null,835552349294259,false,[[7,[10,[2,"STAGE "],[23,"Stage"]]]]]]],[0,null,false,null,286233488081091,[[28,28,null,0,false,false,false,564957672137694,false,[[10,0],[8,0],[7,[2,"score"]]]]],[[28,29,null,420978524768010,false,[[0,[4,[20,19,30,false,null],[0,40]]],[0,[4,[20,15,31,false,null],[0,7]]]]],[28,32,null,814025564324197,false,[[7,[23,"Score"]]]]]],[0,null,false,null,242878811324630,[[28,28,null,0,false,false,false,622108456083246,false,[[10,0],[8,0],[7,[2,"stage"]]]]],[[31,32,null,377102472846197,false,[[7,[10,[2,"STAGE "],[23,"Stage"]]]]]]],[0,null,false,null,166154248757703,[[31,28,null,0,false,false,false,371190534995001,false,[[10,0],[8,0],[7,[2,"defeat"]]]]],[[31,32,null,230041958896189,false,[[7,[2,"BOSS KNIFE UNLOCKED!"]]]]]]]]]],[0,[true,"Menu Start"],false,null,467235709727395,[[-1,20,null,0,false,false,false,467235709727395,false,[[1,[2,"Menu Start"]]]]],[],[[0,null,false,null,677495886582690,[[72,33,null,1,false,false,false,900999309725847,false]],[[-1,34,null,387764677941096,false,[[0,[21,72,false,null,0]]]],[72,35,"LiteTween",202138056685832,false,[[3,0],[3,0]]]]],[0,null,false,null,102990084291626,[],[]]]],[0,[true,"Buttons"],false,null,124418858928883,[[-1,20,null,0,false,false,false,124418858928883,false,[[1,[2,"Buttons"]]]]],[],[[0,null,false,null,567095353927930,[[33,36,null,2,false,false,false,535223138992917,false,[[1,[2,"Reset"]]]]],[[38,37,null,312322204137214,false,[[3,0],[7,[2,"Reset"]]]],[-1,38,null,746754108094333,false],[-1,39,null,990812907852845,false],[-1,40,null,226032477273061,false,[[11,"Stage"],[7,[20,33,41,false,null,[[0,0]]]]]],[-1,40,null,240978961892628,false,[[11,"UnlockedKnives"],[7,[20,33,41,false,null,[[0,1]]]]]],[-1,40,null,747963965884642,false,[[11,"SelectedKnife"],[7,[20,33,41,false,null,[[0,2]]]]]]]],[0,null,false,null,235283630358046,[[32,42,null,0,false,false,false,380157101543199,false,[[4,73]]]],[[73,43,null,576452187461879,false,[[0,[1,0.9]]]]]],[0,null,false,null,298202606228065,[[32,42,null,0,false,true,false,655891561622953,false,[[4,73]]]],[[73,43,null,117074398517329,false,[[0,[0,1]]]]]],[0,null,false,null,186007184108173,[[32,44,null,1,false,false,false,408589059761379,false]],[],[[0,null,false,null,775926361970201,[[32,42,null,0,false,false,false,703215504042706,false,[[4,4]]],[-1,45,null,0,false,true,false,767464641844019,false,[[5,[2,"KnivesList"]]]],[-1,45,null,0,false,true,false,839124397777085,false,[[5,[2,"Settings"]]]],[-1,45,null,0,false,true,false,846714454347327,false,[[5,[2,"Apples"]]]]],[[-1,46,null,723842840159199,false,[[6,"Game"]]],[-1,40,null,238184734262848,false,[[11,"Stage"],[7,[0,1]]]],[-1,34,null,832028970322917,false,[[0,[1,0.1]]]],[-1,40,null,316737782901082,false,[[11,"Start"],[7,[0,1]]]]]],[0,null,false,null,681208692420395,[[32,42,null,0,false,false,false,135951581800407,false,[[4,7]]],[-1,45,null,0,false,false,false,872003594375053,false,[[5,[2,"Equip"]]]]],[[-1,47,null,797814848366423,false,[[5,[2,"Equip"]],[3,0]]]]],[0,null,false,null,419703091150990,[[32,42,null,0,false,false,false,475071879852544,false,[[4,8]]],[-1,45,null,0,false,false,false,139353947185580,false,[[5,[2,"Equip"]]]]],[],[[0,null,false,null,676147034269936,[[-1,48,null,0,false,true,false,892768461165212,false,[[7,[5,[19,49,[[23,"CollectedKnives"],[2,","]]],[0,1]]],[8,0],[7,[23,"CurBoss"]]]]],[[-1,50,null,192249917680301,false,[[11,"CurBoss"],[7,[0,1]]]]]],[0,null,false,null,131581364059264,[[-1,48,null,0,false,false,false,591289443416859,false,[[7,[5,[19,49,[[23,"CollectedKnives"],[2,","]]],[0,1]]],[8,0],[7,[23,"CurBoss"]]]]],[[-1,47,null,731682297073992,false,[[5,[2,"Equip"]],[3,0]]],[-1,47,null,182715207235675,false,[[5,[2,"EquipBack"]],[3,0]]],[-1,34,null,554242329071720,false,[[0,[1,0.1]]]],[-1,40,null,952951180430319,false,[[11,"Start"],[7,[0,1]]]]]],[0,null,false,null,546288704180699,[[40,51,null,0,false,false,false,731055386029111,false,[[10,2],[8,0],[7,[0,1]]]],[40,52,null,0,false,false,true,189327098633449,false,[[3,1]]]],[[-1,40,null,903887859914990,false,[[11,"SelectedKnife"],[7,[20,40,53,false,null]]]],[67,54,null,119092424236049,false,[[1,[2,"KnifeHit-SelectedKnife"]],[7,[20,40,53,false,null]]]],[33,55,null,870813751095346,false,[[1,[2,"saveData"]],[13]]]]]]],[0,null,false,null,698176797180306,[[32,42,null,0,false,false,false,367779568119964,false,[[4,11]]],[-1,56,null,0,false,false,false,994278766883044,false,[[11,"Apples"],[8,4],[7,[21,11,false,null,0]]]],[11,57,null,0,false,false,false,613373430140816,false]],[[-1,58,null,530389511189095,false,[[11,"Apples"],[7,[21,11,false,null,0]]]],[67,54,null,518890888352041,false,[[1,[2,"KnifeHit-Apples"]],[7,[23,"Apples"]]]]],[[0,null,false,null,802431970247310,[[22,51,null,0,false,false,false,998782183281431,false,[[10,0],[8,0],[7,[21,11,false,null,1]]]]],[[-1,40,null,897217950191836,false,[[11,"UnlockedKnives"],[7,[10,[10,[23,"UnlockedKnives"],[19,59,[[21,22,false,null,0]]]],[2,","]]]]],[67,54,null,754698681097993,false,[[1,[2,"KnifeHit-UnlockedKnives"]],[7,[10,[10,[23,"UnlockedKnives"],[19,59,[[21,22,false,null,0]]]],[2,","]]]]],[-1,40,null,529302009651612,false,[[11,"SelectedKnife"],[7,[21,22,false,null,0]]]],[67,54,null,638023198364807,false,[[1,[2,"KnifeHit-SelectedKnife"]],[7,[21,22,false,null,0]]]],[22,60,null,998941718412692,false,[[10,4],[7,[0,1]]]],[22,61,null,327867159301811,false,[[0,[0,100]]]],[22,62,null,278231080293520,false],[26,62,null,925731224371721,false]],[[0,null,false,null,938219242346008,[[67,63,null,0,false,false,false,616980742676781,false,[[1,[2,"KnifeHit-SelectedKnife"]]]]],[[-1,40,null,200653690014976,false,[[11,"SelectedKnife"],[7,[20,67,64,false,null,[[2,"KnifeHit-SelectedKnife"]]]]]]]],[0,null,false,null,115495377150670,[[67,63,null,0,false,true,false,377303970789839,false,[[1,[2,"KnifeHit-SelectedKnife"]]]]],[[-1,40,null,373891646522460,false,[[11,"SelectedKnife"],[7,[0,0]]]]]],[0,null,false,null,431483865449597,[[67,63,null,0,false,false,false,849857348649085,false,[[1,[2,"KnifeHit-UnlockedKnives"]]]]],[[-1,40,null,546361147136007,false,[[11,"UnlockedKnives"],[7,[20,67,64,false,null,[[2,"KnifeHit-UnlockedKnives"]]]]]]]],[0,null,false,null,638756590332031,[[67,63,null,0,false,true,false,393244804838456,false,[[1,[2,"KnifeHit-UnlockedKnives"]]]]],[[-1,40,null,262028536376852,false,[[11,"UnlockedKnives"],[7,[2,""]]]]]],[0,null,false,null,640185450523312,[],[[33,55,null,676809363711203,false,[[1,[2,"saveData"]],[13]]]]]]]]],[0,null,false,null,510898965614962,[[-1,45,null,0,false,false,false,411065483530823,false,[[5,[2,"Lose"]]]],[-1,65,null,0,false,false,false,582146737023133,false,[[5,[2,"Lose"]],[8,4],[0,[0,80]]]],[32,42,null,0,false,false,false,560128286073284,false,[[4,10]]]],[[-1,38,null,301424280143656,false],[-1,46,null,237215153695786,false,[[6,"Menu"]]]]],[0,null,false,null,491357899446589,[[32,42,null,0,false,false,false,312131966909694,false,[[4,10]]],[-1,45,null,0,false,false,false,977436781786849,false,[[5,[2,"KnivesList"]]]]],[[-1,47,null,877721908984258,false,[[5,[2,"KnivesList"]],[3,0]]]]],[0,null,false,null,738863823138861,[[32,42,null,0,false,false,false,103467382726942,false,[[4,2]]],[-1,45,null,0,false,true,false,723293842609129,false,[[5,[2,"Apples"]]]],[-1,45,null,0,false,true,false,230045778679183,false,[[5,[2,"Settings"]]]]],[],[[0,null,false,null,230195204541607,[[-1,45,null,0,false,true,false,996038784336102,false,[[5,[2,"KnivesList"]]]]],[[-1,47,null,294375194988619,false,[[5,[2,"KnivesList"]],[3,1]]]]],[0,null,false,null,815483089223338,[[-1,48,null,0,false,false,false,465375126035140,false,[[7,[19,66]],[8,0],[7,[2,"Game"]]]]],[[-1,38,null,461158803100829,false],[-1,46,null,660055673778256,false,[[6,"Menu"]]],[-1,40,null,209188311721239,false,[[11,"GoKnivesPage"],[7,[0,1]]]]]]]],[0,null,false,null,519020814172251,[[32,42,null,0,false,false,false,945484064295790,false,[[4,6]]]],[[-1,38,null,282313901313928,false],[-1,46,null,777129759896878,false,[[6,"Menu"]]],[-1,40,null,550386649609034,false,[[11,"GoSettingsPage"],[7,[0,1]]]]]],[0,null,false,null,982139585445869,[[32,42,null,0,false,false,false,794558733125814,false,[[4,1]]],[-1,45,null,0,false,true,false,972864490776754,false,[[5,[2,"KnivesList"]]]],[-1,56,null,0,false,false,false,262727193238458,false,[[11,"GiftReady"],[8,0],[7,[0,1]]]],[-1,45,null,0,false,true,false,954385324228086,false,[[5,[2,"Settings"]]]]],[[37,67,null,488927650230580,false,[[1,[2,"TheTimer"]]]],[-1,47,null,472663740865943,false,[[5,[2,"Apples"]],[3,1]]],[-1,47,null,132356583451598,false,[[5,[2,"Black"]],[3,1]]],[38,37,null,203728480495561,false,[[3,0],[7,[2,"G"]]]]]],[0,null,false,null,197483457567539,[[-1,45,null,0,false,false,false,344974771018708,false,[[5,[2,"Lose"]]]],[-1,65,null,0,false,false,false,280854348245618,false,[[5,[2,"Lose"]],[8,4],[0,[0,80]]]],[32,42,null,0,false,false,false,561526235515001,false,[[4,9]]]],[[33,55,null,713245755996095,false,[[1,[2,"Reset"]],[13,[7,[23,"Stage"]],[7,[23,"UnlockedKnives"]],[7,[23,"SelectedKnife"]]]]]]],[0,null,false,null,862427328059381,[[-1,45,null,0,false,true,false,857814348472852,false,[[5,[2,"KnivesList"]]]],[-1,45,null,0,false,true,false,112006497955772,false,[[5,[2,"Apples"]]]],[-1,56,null,0,false,false,false,988588939240085,false,[[11,"InKnivePage"],[8,0],[7,[0,0]]]],[32,42,null,0,false,false,false,392034179473141,false,[[4,5]]]],[[-1,47,null,323113907285730,false,[[5,[2,"Settings"]],[3,1]]],[-1,34,null,883396902896262,false,[[0,[1,0.001]]]],[-1,40,null,613327039455581,false,[[11,"InSettingsPage"],[7,[0,1]]]]]],[0,null,false,null,995832679620066,[[32,42,null,0,false,false,false,250885150134206,false,[[4,10]]],[10,68,null,0,false,false,false,618886078012219,false,[[5,[2,"Settings"]]]],[-1,56,null,0,false,false,false,709976540517843,false,[[11,"InSettingsPage"],[8,0],[7,[0,1]]]]],[[-1,47,null,389578317997046,false,[[5,[2,"Settings"]],[3,0]]],[-1,34,null,445609570378026,false,[[0,[1,0.001]]]],[-1,40,null,455951075831052,false,[[11,"InSettingsPage"],[7,[0,0]]]]]],[0,null,false,null,670757362169848,[[32,42,null,0,false,false,false,832618059907286,false,[[4,51]]],[-1,45,null,0,false,false,false,461718597147770,false,[[5,[2,"Settings"]]]]],[[33,55,null,382520549528352,false,[[1,[2,"clearData"]],[13]]],[33,55,null,232901308529730,false,[[1,[2,"reset1"]],[13,[7,[23,"Sound"]],[7,[0,1]]]]]]],[0,null,false,null,543190210178661,[[32,42,null,0,false,false,false,134116094352726,false,[[4,0]]],[-1,45,null,0,false,true,false,331117867326151,false,[[5,[2,"Settings"]]]],[-1,45,null,0,false,true,false,319753621579420,false,[[5,[2,"Apples"]]]],[-1,45,null,0,false,true,false,157649860397159,false,[[5,[2,"KnivesList"]]]]],[[38,69,null,712108494084298,false,[[1,[2,"http://FB.com/YourPage"]],[1,[2,"NewWindow"]]]]]],[0,null,false,null,864067069091325,[[32,42,null,0,false,false,false,109781742194686,false,[[4,3]]],[-1,45,null,0,false,true,false,141135261087451,false,[[5,[2,"Settings"]]]],[-1,45,null,0,false,true,false,561570136535173,false,[[5,[2,"Apples"]]]],[-1,45,null,0,false,true,false,312871372865994,false,[[5,[2,"KnivesList"]]]]],[[38,69,null,347931319245735,false,[[1,[2,"http://ItemPage.com/"]],[1,[2,"NewWindow"]]]]]]]],[0,null,false,null,386552055822271,[[33,36,null,2,false,false,false,160054261101490,false,[[1,[2,"reset1"]]]]],[[-1,38,null,692404264056799,false],[-1,39,null,893063715935744,false],[-1,40,null,842345283329775,false,[[11,"Sound"],[7,[20,33,41,false,null,[[0,0]]]]]],[-1,40,null,189235869574604,false,[[11,"GoSettingsPage"],[7,[20,33,41,false,null,[[0,1]]]]]]]],[0,null,false,null,717611566586024,[[48,51,null,0,false,false,false,390146100409915,false,[[10,0],[8,0],[7,[0,0]]]]],[[48,61,null,514218767340875,false,[[0,[0,20]]]]]],[0,null,false,null,985271310422522,[[49,51,null,0,false,false,false,426278859471777,false,[[10,0],[8,0],[7,[0,0]]]]],[[49,61,null,238552122824098,false,[[0,[0,20]]]]]],[0,null,false,null,986773729387539,[[-1,56,null,0,false,false,false,239794630220176,false,[[11,"GoKnivesPage"],[8,0],[7,[0,1]]]]],[[-1,47,null,471436938544308,false,[[5,[2,"KnivesList"]],[3,1]]],[-1,40,null,555433312481626,false,[[11,"GoKnivesPage"],[7,[0,0]]]]]],[0,null,false,null,441890946394440,[[-1,56,null,0,false,false,false,272005102096266,false,[[11,"GoSettingsPage"],[8,0],[7,[0,1]]]]],[[-1,47,null,620699361115232,false,[[5,[2,"Settings"]],[3,1]]],[-1,40,null,195760543969624,false,[[11,"InSettingsPage"],[7,[0,1]]]],[-1,40,null,313653752483977,false,[[11,"GoSettingsPage"],[7,[0,0]]]]]]]],[0,[true,"Local Storage"],false,null,974349351504788,[[-1,20,null,0,false,false,false,974349351504788,false,[[1,[2,"Local Storage"]]]]],[],[[0,null,false,null,966812459853744,[[-1,21,null,1,false,false,false,418800532022188,false]],[[34,70,null,674680151011302,false,[[1,[2,"KnifeHit-BestScore"]]]],[34,70,null,147313439513522,false,[[1,[2,"KnifeHit-BestStage"]]]],[34,70,null,484804939437633,false,[[1,[2,"KnifeHit-Apples"]]]],[34,70,null,616051927398357,false,[[1,[2,"KnifeHit-SelectedKnife"]]]],[34,70,null,192206593453200,false,[[1,[2,"KnifeHit-UnlockedKnives"]]]],[34,70,null,961448265491660,false,[[1,[2,"KnifeHit-Time"]]]],[34,70,null,565925884741520,false,[[1,[2,"KnifeHit-TheTimer"]]]],[34,70,null,843833201960597,false,[[1,[2,"KnifeHit-SocialGift"]]]]]],[0,null,false,null,404752951586876,[],[]],[0,null,false,null,115393605365970,[],[]],[0,null,false,null,408688043608913,[],[]],[0,null,false,null,869954672971619,[],[]],[0,null,false,null,749271609635784,[],[]],[0,null,false,null,734483928144585,[],[],[[0,null,false,null,723824377790480,[],[]]]]]],[0,[true,"Knives List"],false,null,826754320729158,[[-1,20,null,0,false,false,false,826754320729158,false,[[1,[2,"Knives List"]]]]],[],[[0,null,false,null,659858683050751,[[-1,21,null,1,false,false,false,911946127746729,false],[-1,48,null,0,false,false,false,653374756725704,false,[[7,[19,66]],[8,0],[7,[2,"Menu"]]]]],[[-1,47,null,185823511268942,false,[[5,[2,"KnivesList"]],[3,0]]],[-1,71,null,805732462031524,false,[[4,40],[5,[2,"KnivesList"]],[0,[4,[7,[19,72],[0,2]],[0,120]]],[0,[0,100]]]],[40,60,null,123578392244805,false,[[10,4],[7,[0,1]]]],[40,73,"LPos",150644173327946,false,[[3,0]]],[40,43,null,115089707939872,false,[[0,[1,0.5]]]],[40,74,null,798872936152341,false,[[0,[0,50]]]],[11,75,null,787605153628772,false,[[3,0]]],[26,75,null,543681922940474,false,[[3,0]]]],[[0,null,false,null,966186997176240,[[-1,23,null,0,true,false,false,321427499259793,false,[[1,[2,"j"]],[0,[0,0]],[0,[0,4]]]],[-1,23,null,0,true,false,false,752191311230650,false,[[1,[2,"i"]],[0,[0,0]],[0,[0,3]]]]],[[-1,71,null,720498802030297,false,[[4,22],[5,[2,"KnivesList"]],[0,[4,[4,[0,50],[6,[19,27,[[2,"i"]]],[1,171.4285714285714]]],[0,50]]],[0,[4,[4,[0,450],[6,[19,27,[[2,"j"]]],[1,171.4285714285714]]],[0,40]]]]],[22,60,null,248302924534255,false,[[10,0],[7,[23,"ShowNum"]]]],[-1,71,null,536531161821442,false,[[4,40],[5,[2,"KnivesList"]],[0,[4,[4,[0,60],[6,[19,27,[[2,"i"]]],[1,171.4285714285714]]],[0,100]]],[0,[5,[4,[0,450],[6,[19,27,[[2,"j"]]],[1,171.4285714285714]]],[0,20]]]]],[40,60,null,966923911822539,false,[[10,2],[7,[0,1]]]],[40,73,"LPos",612215954815780,false,[[3,0]]],[40,74,null,603866029582571,false,[[0,[0,45]]]],[40,76,null,120173300484557,false,[[3,0]]],[40,43,null,769914840218575,false,[[0,[1,0.25]]]],[40,77,null,982014817845268,false,[[0,[23,"ShowNum"]]]],[-1,50,null,775812224638118,false,[[11,"ShowNum"],[7,[0,1]]]]]]]],[0,null,false,null,548723077232541,[[22,51,null,0,false,false,false,596023791439682,false,[[10,0],[8,0],[7,[23,"SelectedKnife"]]]],[22,78,null,0,false,false,false,661442580402440,false,[[8,0],[0,[0,100]]]]],[[22,77,null,514293766228049,false,[[0,[0,1]]]]]],[0,null,false,null,745231944432589,[[22,51,null,0,false,true,false,707235939938603,false,[[10,0],[8,0],[7,[23,"SelectedKnife"]]]]],[[22,77,null,846049827114945,false,[[0,[0,0]]]]]],[0,null,false,null,960917381910256,[[-1,56,null,0,false,true,false,558680439889443,false,[[11,"UnlockedKnives"],[8,0],[7,[2,""]]]],[-1,79,null,0,false,false,false,639822316015581,false]],[],[[0,null,false,null,404987642904549,[[-1,80,null,0,true,false,false,603162482445537,false,[[4,22]]]],[],[[0,null,false,null,550475215216782,[[-1,48,null,0,false,false,false,966398892474382,false,[[7,[19,81,[[23,"UnlockedKnives"],[10,[21,22,false,null,0],[2,","]]]]],[8,0],[7,[0,-1]]]]],[[22,61,null,525833173337694,false,[[0,[0,20]]]],[22,82,null,224344987237608,false]]],[0,null,false,null,911942932141313,[[-1,48,null,0,false,true,false,597028292914746,false,[[7,[19,81,[[23,"UnlockedKnives"],[10,[21,22,false,null,0],[2,","]]]]],[8,0],[7,[0,-1]]]]],[[22,61,null,299964912074454,false,[[0,[0,100]]]]]]]]]],[0,null,false,null,441740249027066,[[-1,56,null,0,false,false,false,957381763792996,false,[[11,"UnlockedKnives"],[8,0],[7,[2,""]]]],[-1,79,null,0,false,false,false,480385899965105,false]],[[22,61,null,726926974474956,false,[[0,[0,20]]]]]],[0,null,false,null,959673783553398,[[40,51,null,0,false,false,false,415019292378494,false,[[10,4],[8,0],[7,[0,1]]]]],[[40,77,null,556941671635705,false,[[0,[23,"SelectedKnife"]]]],[25,74,null,763876803255161,false,[[0,[4,[20,25,83,false,null],[6,[21,25,false,null,0],[21,25,false,null,1]]]]]],[25,62,null,496005020165401,false],[25,84,null,758752678099488,false,[[0,[20,40,85,false,null,[[0,1]]]],[0,[20,40,86,false,null,[[0,1]]]]]]]],[0,null,false,null,934750672347368,[[-1,80,null,0,true,false,false,364159527885469,false,[[4,22]]],[74,87,null,0,false,false,false,199873189396081,false,[[4,22]]]],[],[[0,null,false,null,911828034566646,[[22,78,null,0,false,false,false,980918935785480,false,[[8,0],[0,[0,20]]]]],[[74,61,null,299902618798129,false,[[0,[0,20]]]]]],[0,null,false,null,203550790767911,[[22,78,null,0,false,false,false,676108800123304,false,[[8,0],[0,[0,100]]]]],[[74,61,null,998822996436691,false,[[0,[0,100]]]]]]]],[0,null,false,null,850208857398019,[[-1,45,null,0,false,false,false,549339721902973,false,[[5,[2,"KnivesList"]]]]],[[-1,34,null,609840668723462,false,[[0,[1,0.1]]]],[-1,40,null,613068283801886,false,[[11,"InKnivePage"],[7,[0,1]]]]],[[0,null,false,null,440905721575388,[[28,28,null,0,false,false,false,925627102665654,false,[[10,0],[8,0],[7,[2,"apple"]]]]],[[15,88,null,209399023058611,false,[[5,[2,"KnivesList"]]]],[28,89,null,465096709119952,false,[[5,[2,"KnivesList"]]]]]]]],[0,null,false,null,747609249828755,[[-1,45,null,0,false,true,false,921140226970926,false,[[5,[2,"KnivesList"]]]]],[[-1,40,null,466062866228202,false,[[11,"InKnivePage"],[7,[0,0]]]]],[[0,null,false,null,565146738312512,[[28,28,null,0,false,false,false,550782717104535,false,[[10,0],[8,0],[7,[2,"apple"]]]]],[[15,88,null,252405019571464,false,[[5,[2,"Menu"]]]],[28,89,null,866702101698632,false,[[5,[2,"Menu"]]]]]]]],[0,null,false,null,955665254073678,[[32,44,null,1,false,false,false,464310984426783,false]],[],[[0,null,false,null,156971792152087,[[32,42,null,0,false,false,false,101526646041147,false,[[4,22]]],[22,78,null,0,false,false,false,400714157005882,false,[[8,0],[0,[0,100]]]],[-1,56,null,0,false,false,false,880329020626705,false,[[11,"InKnivePage"],[8,0],[7,[0,1]]]]],[[67,54,null,749376414005011,false,[[1,[2,"KnifeHit-SelectedKnife"]],[7,[21,22,false,null,0]]]],[-1,40,null,170777114658053,false,[[11,"SelectedKnife"],[7,[21,22,false,null,0]]]]],[[0,null,false,null,706798647158689,[[67,63,null,0,false,false,false,356133114775083,false,[[1,[2,"KnifeHit-SelectedKnife"]]]]],[[-1,40,null,697961800353322,false,[[11,"SelectedKnife"],[7,[20,67,64,false,null,[[2,"KnifeHit-SelectedKnife"]]]]]]]],[0,null,false,null,353648938214691,[[67,63,null,0,false,true,false,417945002421315,false,[[1,[2,"KnifeHit-SelectedKnife"]]]]],[[-1,40,null,900664194451154,false,[[11,"SelectedKnife"],[7,[0,0]]]]]]]],[0,null,false,null,799536361264798,[[32,42,null,0,false,false,false,118824543415864,false,[[4,22]]],[28,28,null,0,false,false,false,943453156101011,false,[[10,0],[8,0],[7,[2,"price"]]]],[-1,56,null,0,false,false,false,533297549658617,false,[[11,"InKnivePage"],[8,0],[7,[0,1]]]]],[[26,84,null,946832115408652,false,[[0,[20,22,30,false,null]],[0,[20,22,31,false,null]]]],[26,75,null,472248639080107,false,[[3,1]]]],[[0,null,false,null,693214708764022,[[22,51,null,0,false,false,false,108435937504338,false,[[10,0],[8,3],[7,[0,8]]]],[22,51,null,0,false,false,false,791468548252832,false,[[10,4],[8,0],[7,[0,0]]]]],[[28,32,null,421570623923744,false,[[7,[10,[21,22,false,null,3],[2," Apples"]]]]],[11,84,null,323845734506462,false,[[0,[4,[20,26,30,false,null],[0,50]]],[0,[4,[20,26,31,false,null],[0,55]]]]]],[[0,null,false,null,952855149549778,[[-1,56,null,0,false,false,false,531845066709868,false,[[11,"Apples"],[8,5],[7,[21,22,false,null,3]]]]],[[11,75,null,991301973297882,false,[[3,1]]],[11,60,null,168520209809444,false,[[10,0],[7,[21,22,false,null,3]]]],[11,60,null,260854252467515,false,[[10,1],[7,[21,22,false,null,0]]]]]]]],[0,null,false,null,110747665109518,[[22,51,null,0,false,false,false,924097742106921,false,[[10,0],[8,4],[7,[0,8]]]]],[[11,75,null,766837318776438,false,[[3,0]]],[11,60,null,438508080566978,false,[[10,0],[7,[0,0]]]]],[[0,null,false,null,631235126145767,[[22,78,null,0,false,false,false,921697264221058,false,[[8,0],[0,[0,100]]]]],[[28,32,null,706345941627705,false,[[7,[10,[19,90,[[2,"Boss Defeated: "]]],[19,91,[[23,"BossList"],[5,[21,22,false,null,0],[0,8]],[2,"/"]]]]]]]]]]],[0,null,false,null,122099902425622,[[22,78,null,0,false,false,false,263611892883069,false,[[8,0],[0,[0,100]]]],[22,51,null,0,false,false,false,809772255467352,false,[[10,0],[8,3],[7,[0,8]]]]],[[28,32,null,137061016786672,false,[[7,[2,"Bought"]]]],[22,60,null,458067602532540,false,[[10,4],[7,[0,1]]]],[11,75,null,266401064699968,false,[[3,0]]]]],[0,null,false,null,646384698808518,[[-1,56,null,0,false,false,false,147235608750777,false,[[11,"Apples"],[8,2],[7,[21,22,false,null,3]]]],[22,51,null,0,false,false,false,816953329164235,false,[[10,0],[8,3],[7,[0,8]]]]],[[11,75,null,397291568241543,false,[[3,0]]]]],[0,null,false,null,707751275237383,[[22,51,null,0,false,false,false,277618061169303,false,[[10,0],[8,4],[7,[0,8]]]],[22,78,null,0,false,true,false,749865176266561,false,[[8,0],[0,[0,100]]]]],[[28,32,null,439591862857105,false,[[7,[10,[19,90,[[2,"Boss Defeat: "]]],[19,91,[[23,"BossList"],[5,[21,22,false,null,0],[0,8]],[2,"/"]]]]]]]]],[0,null,false,null,594162212584533,[[-1,56,null,0,false,false,false,704191891598872,false,[[11,"Apples"],[8,4],[7,[19,92,[[21,22,false,null,3]]]]]]],[[26,77,null,836858307231124,false,[[0,[0,1]]]]]],[0,null,false,null,891831516862246,[[-1,93,null,0,false,false,false,398740274825359,false]],[[26,77,null,637252265259410,false,[[0,[0,0]]]]]]]]]],[0,null,false,null,612816982908530,[[22,51,null,0,false,false,false,308849764815176,false,[[10,0],[8,4],[7,[0,8]]]]],[[22,60,null,694955959129029,false,[[10,3],[7,[0,999999]]]]]],[0,null,false,null,602046608137201,[[22,51,null,0,false,false,false,156358397084894,false,[[10,0],[8,3],[7,[0,8]]]]],[[22,60,null,616211592425878,false,[[10,3],[7,[0,250]]]]]],[0,null,false,null,638605325988108,[],[[34,70,null,668530447427308,false,[[1,[2,"KnifeHit-UnlockedKnives"]]]]],[[0,null,false,null,680273322738977,[[67,63,null,0,false,false,false,723958011596396,false,[[1,[2,"KnifeHit-UnlockedKnives"]]]]],[[-1,40,null,358935162257800,false,[[11,"UnlockedKnives"],[7,[20,67,64,false,null,[[2,"KnifeHit-UnlockedKnives"]]]]]]]],[0,null,false,null,579801066111765,[[67,63,null,0,false,true,false,863510994919309,false,[[1,[2,"KnifeHit-UnlockedKnives"]]]]],[[-1,40,null,780748332563255,false,[[11,"UnlockedKnives"],[7,[2,""]]]]]]]]]],[0,[true,"TheTimer"],false,null,737614201870414,[[-1,20,null,0,false,false,false,737614201870414,false,[[1,[2,"TheTimer"]]]]],[],[[0,null,false,null,214802932801062,[[-1,94,null,0,false,false,false,599328043279220,false]],[],[[0,null,false,null,219582142718328,[[27,28,null,0,false,false,false,982646794581366,false,[[10,0],[8,0],[7,[2,"time"]]]]],[[27,29,null,233754050227033,false,[[0,[20,1,30,false,null]],[0,[4,[20,1,31,false,null],[0,70]]]]]],[[0,null,false,null,965156302283513,[[-1,56,null,0,false,false,false,130776827559263,false,[[11,"GiftReady"],[8,0],[7,[0,0]]]]],[[27,32,null,546146192398314,false,[[7,[10,[10,[10,[10,[19,95,[[23,"H"],[0,2]]],[2,":"]],[19,95,[[23,"M"],[0,2]]]],[2,":"]],[19,95,[[23,"S"],[0,2]]]]]]]]],[0,null,false,null,716307160937698,[[-1,56,null,0,false,false,false,227086978441809,false,[[11,"GiftReady"],[8,0],[7,[0,1]]]]],[[27,32,null,551644295840242,false,[[7,[2,"READY!"]]]]]]]]]],[0,null,false,null,552861347917051,[[-1,21,null,1,false,false,false,993173865464831,false]],[[37,96,null,100311797054776,false,[[1,[2,"TheTimer"]]]]]],[0,null,false,null,834576272828773,[[-1,94,null,0,false,false,false,666411526379911,false]],[[-1,40,null,802528515898209,false,[[11,"H"],[7,[19,97,[[8,[7,[5,[0,28800],[19,92,[[20,37,98,false,null,[[2,"TheTimer"]]]]]],[0,3600]],[0,24]]]]]]],[-1,40,null,313415575763736,false,[[11,"M"],[7,[19,97,[[8,[7,[5,[0,28800],[19,92,[[20,37,98,false,null,[[2,"TheTimer"]]]]]],[0,60]],[0,60]]]]]]],[-1,40,null,521513247894183,false,[[11,"S"],[7,[19,97,[[8,[5,[0,28800],[19,92,[[20,37,98,false,null,[[2,"TheTimer"]]]]]],[0,60]]]]]]]],[[0,null,false,null,549606660308080,[[-1,56,null,0,false,false,false,369589618094298,false,[[11,"H"],[8,5],[7,[0,8]]]]],[[-1,40,null,126056359179603,false,[[11,"H"],[7,[0,7]]]]]],[0,null,false,null,218595954968795,[[-1,56,null,0,false,false,false,388350632514744,false,[[11,"H"],[8,3],[7,[0,0]]]]],[[-1,40,null,426289727314037,false,[[11,"H"],[7,[0,0]]]]]],[0,null,false,null,249828657293442,[[-1,56,null,0,false,false,false,171395120389402,false,[[11,"M"],[8,3],[7,[0,0]]]]],[[-1,40,null,757209677716912,false,[[11,"M"],[7,[0,0]]]]]],[0,null,false,null,341282195607786,[[-1,56,null,0,false,false,false,868568978985368,false,[[11,"S"],[8,3],[7,[0,0]]]]],[[-1,40,null,317260436561569,false,[[11,"S"],[7,[0,0]]]]]]]],[0,null,false,null,275581211779444,[[-1,56,null,0,false,false,false,551899244226232,false,[[11,"H"],[8,3],[7,[0,0]]]],[-1,56,null,0,false,false,false,561442581649075,false,[[11,"M"],[8,3],[7,[0,0]]]],[-1,56,null,0,false,false,false,915889628628393,false,[[11,"S"],[8,3],[7,[0,0]]]]],[[-1,40,null,611686611612874,false,[[11,"GiftReady"],[7,[0,1]]]]]],[0,null,false,null,967344900543039,[[-1,93,null,0,false,false,false,316657111040117,false]],[[-1,40,null,241100338548705,false,[[11,"GiftReady"],[7,[0,0]]]]]],[0,null,false,null,637396618049848,[[37,99,null,1,false,false,false,962505147345041,false,[[1,[2,"TheTimer"]]]],[37,100,null,0,false,true,false,848583160449611,false,[[1,[2,"TheTimer"]]]]],[[37,67,null,641757845244391,false,[[1,[2,"TheTimer"]]]]]]]],[1,"ShowApplesNum",0,0,false,false,480872264040777,false],[1,"showAppNum",0,0,false,false,183966188804385,false],[0,[true,"Apples Layer"],false,null,496948341885171,[[-1,20,null,0,false,false,false,496948341885171,false,[[1,[2,"Apples Layer"]]]]],[],[[1,"ApplesNum",0,0,false,false,802729106319253,false],[0,null,false,null,130710050918770,[[-1,21,null,1,false,false,false,604855820666229,false]],[[-1,47,null,348605622619510,false,[[5,[2,"Apples"]],[3,0]]],[-1,47,null,574205094660066,false,[[5,[2,"Black"]],[3,0]]],[47,101,null,663068854867202,false]]],[0,null,false,null,889502126924518,[[-1,45,null,0,false,false,false,880517262383164,false,[[5,[2,"Apples"]]]]],[],[[0,null,false,null,542477577888134,[[-1,79,null,0,false,false,false,891152930444906,false]],[[-1,40,null,505167528873115,false,[[11,"ApplesNum"],[7,[19,92,[[19,102,[[0,100],[0,150]]]]]]]],[-1,40,null,955395746888236,false,[[11,"showAppNum"],[7,[23,"ApplesNum"]]]]],[[0,null,false,null,759900779384177,[[-1,23,null,0,true,false,false,798635882181235,false,[[1,[2,""]],[0,[0,1]],[0,[23,"ApplesNum"]]]]],[[-1,71,null,514451230617534,false,[[4,47],[5,[2,"Apples"]],[0,[19,102,[[0,80],[5,[19,72],[0,80]]]]],[0,[19,102,[[0,80],[5,[19,103],[0,80]]]]]]],[47,60,null,191533492879941,false,[[10,0],[7,[19,102,[[1,0.5],[1,1.5]]]]]],[-1,34,null,430843305772867,false,[[0,[21,47,false,null,0]]]],[47,35,"L_Scale",261535807635801,false,[[3,0],[3,0]]],[47,35,"L_Opac",727003119140495,false,[[3,0],[3,0]]],[-1,34,null,451222926743872,false,[[0,[1,0.5]]]],[47,101,null,411995067704115,false]]]]],[0,null,false,null,514896632919414,[[28,28,null,0,false,false,false,236670315749166,false,[[10,0],[8,0],[7,[2,"applesnum"]]]]],[[28,32,null,382933352770501,false,[[7,[10,[2,"+"],[23,"ShowApplesNum"]]]]],[28,29,null,925055999680093,false,[[0,[7,[19,72],[0,2]]],[0,[7,[19,103],[0,2]]]]],[28,104,null,294347665779140,false,[[0,[7,[6,[23,"ShowApplesNum"],[0,100]],[23,"ApplesNum"]]]]]]],[0,null,false,null,666823051199556,[[47,105,null,1,false,false,false,670697357337419,false]],[[-1,50,null,159230899438755,false,[[11,"ShowApplesNum"],[7,[0,1]]]],[-1,50,null,823172731331598,false,[[11,"Apples"],[7,[0,1]]]],[38,37,null,699688243044749,false,[[3,0],[7,[10,[2,"Apples Num"],[23,"ApplesNum"]]]]]],[[0,null,false,null,307012588886966,[[-1,56,null,0,false,false,false,667476721150521,false,[[11,"showAppNum"],[8,0],[7,[23,"ShowApplesNum"]]]]],[[-1,40,null,400327761650032,false,[[11,"BlackFade"],[7,[0,1]]]],[67,54,null,818388526859837,false,[[1,[2,"KnifeHit-Apples"]],[7,[23,"Apples"]]]],[33,55,null,128762389509736,false,[[1,[2,"saveData"]],[13]]]]]]]]],[0,null,false,null,531309941573922,[[-1,56,null,0,false,false,false,849014116682044,false,[[11,"BlackFade"],[8,0],[7,[0,1]]]]],[[-1,106,null,924645855819396,false,[[5,[2,"Black"]],[0,[5,[19,107,[[2,"Black"]]],[0,5]]]]],[-1,106,null,325663138124679,false,[[5,[2,"Apples"]],[0,[19,107,[[2,"Black"]]]]]],[-1,34,null,463293008903124,false,[[0,[0,1]]]],[-1,40,null,232257719966334,false,[[11,"BlackFade"],[7,[0,2]]]],[-1,47,null,578092798533914,false,[[5,[2,"Apples"]],[3,0]]],[-1,47,null,718764314765115,false,[[5,[2,"Black"]],[3,0]]]]]]],[0,[true,"Sounds"],false,null,659585428066218,[[-1,20,null,0,false,false,false,659585428066218,false,[[1,[2,"Sounds"]]]]],[],[[0,null,false,null,262831422878063,[[32,44,null,1,false,false,false,450886632504425,false]],[],[[0,null,false,null,290300198147848,[[32,42,null,0,false,false,false,974549919093408,false,[[4,50]]]],[],[[0,null,false,null,820518260876672,[[50,108,null,0,false,false,false,488568700044455,false,[[8,0],[0,[0,0]]]]],[[-1,40,null,318132923476920,false,[[11,"Sound"],[7,[0,0]]]]]],[0,null,false,null,587184980648844,[[50,108,null,0,false,false,false,378454705352231,false,[[8,0],[0,[0,1]]]]],[[-1,40,null,792644146228561,false,[[11,"Sound"],[7,[0,1]]]]]]]]]],[0,null,false,null,332837807328100,[[-1,56,null,0,false,false,false,831605758379216,false,[[11,"Sound"],[8,0],[7,[0,1]]]]],[[50,77,null,881687297615425,false,[[0,[0,0]]]]]],[0,null,false,null,843850900710017,[[-1,56,null,0,false,false,false,882430624518359,false,[[11,"Sound"],[8,0],[7,[0,0]]]]],[[50,77,null,692277838798136,false,[[0,[0,1]]]]]],[0,null,false,null,803885662235909,[[33,36,null,2,false,false,false,109241613945429,false,[[1,[2,"PlaySound"]]]],[-1,56,null,0,false,false,false,891975121740762,false,[[11,"Sound"],[8,0],[7,[0,1]]]]],[],[[0,null,false,null,628437056371375,[[33,109,null,0,false,false,false,658025519866844,false,[[0,[0,0]],[8,0],[7,[2,"hit"]]]]],[[35,110,null,558415237327324,false,[[2,["hit",false]],[3,0],[0,[0,0]],[1,[2,""]]]]]],[0,null,false,null,124167593174086,[[33,109,null,0,false,false,false,733313676626736,false,[[0,[0,0]],[8,0],[7,[2,"block"]]]]],[[35,110,null,188172575311825,false,[[2,["block",false]],[3,0],[0,[0,0]],[1,[2,""]]]]]],[0,null,false,null,566693459649937,[[33,109,null,0,false,false,false,482919160092324,false,[[0,[0,0]],[8,0],[7,[2,"break"]]]]],[[35,110,null,330110584716365,false,[[2,["break",false]],[3,0],[0,[0,0]],[1,[2,""]]]]]],[0,null,false,null,119830994076151,[[33,109,null,0,false,false,false,131740360408319,false,[[0,[0,0]],[8,0],[7,[2,"new"]]]]],[[35,110,null,878471776384092,false,[[2,["new",false]],[3,0],[0,[0,0]],[1,[2,""]]]]]]]]]],[0,null,false,null,919533846933421,[[-1,94,null,0,false,false,false,574648113499178,false]],[[11,82,null,428980126002548,false]]],[0,null,false,null,505294083225735,[[32,111,null,1,false,false,false,464325577332586,false,[[4,69]]],[60,112,null,0,false,true,false,124428897487699,false],[-1,56,null,0,false,false,false,693296998663998,false,[[11,"isPaused"],[8,0],[7,[0,0]]]],[69,57,null,0,false,false,false,382655619834437,false],[-1,45,null,0,false,false,false,921426696304618,false,[[5,[2,"Menu"]]]],[-1,45,null,0,false,true,false,940072013748091,false,[[5,[2,"KnivesList"]]]],[-1,45,null,0,false,true,false,909331796945133,false,[[5,[2,"Settings"]]]],[-1,45,null,0,false,true,false,614070100593091,false,[[5,[2,"Apples"]]]]],[],[[0,null,false,null,561960215837812,[],[[-1,34,null,739848930451416,false,[[0,[1,0.2]]]],[60,113,null,877319741343730,false,[[1,[23,"LEADERBOARD_NAME"]],[1,[2,"alltime"]],[0,[0,1]]]]]]]],[0,null,false,null,193441561871939,[[-1,21,null,1,false,false,false,411244759355502,false]],[[53,60,null,389801811193952,false,[[10,0],[7,[23,"Menu_LOGO"]]]],[33,55,null,534646096816146,false,[[1,[2,"loadFunc"]],[13]]]]]]],["GameSheet",[[2,"saveData",false],[2,"y8Logo",false],[2,"Blacklist",false],[2,"Adsense",false],[1,"isSaved",0,0,false,false,922688170630914,false],[2,"MenuSheet",false],[1,"Lose",0,0,false,false,406602779950227,false],[1,"New",0,-1,false,false,372141194302406,false],[1,"Knives",0,10,false,false,649525196294365,false],[1,"AngleList",1,"",false,false,320949326904366,false],[1,"SpeedList",1,"",false,false,290480938274495,false],[1,"Step",0,0,false,false,475144082269633,false],[1,"Last",0,0,false,false,755404532127229,false],[1,"KnifeDone",0,0,false,false,322650881003110,false],[1,"BossList",1,"/CHEESE/TOMATO/LEMON/SUSHI ROLL/FORTUNE WHEEL/THE DONUT/THE TIRE/VIKING SHIELD/THE VINYL/THE GEAR/THE COMPASS/THE DOLL/BAT BADGE/THE MOON/POKER CHIP/THE DIAMOND/",false,false,255748896561766,false],[1,"CollectedKnives",1,",",false,false,906255173384037,false],[1,"CurBoss",0,0,false,false,983754421457604,false],[1,"CurBossFolo",0,0,false,false,537906255249906,false],[1,"LatestBoss",0,0,false,false,238646683990358,false],[1,"ApplesCountRnd",0,0,false,false,382080548228212,false],[1,"CreateApplesRnd",0,0,false,false,924750751967055,false],[0,[true,"General"],false,null,318816922852073,[[-1,20,null,0,false,false,false,318816922852073,false,[[1,[2,"General"]]]]],[],[[0,null,false,null,256705158166968,[[-1,21,null,1,false,false,false,574430953260822,false]],[[52,101,null,654450692516433,false],[46,101,null,281460923146593,false],[-1,40,null,348270215250714,false,[[11,"Stage"],[7,[0,1]]]],[33,55,null,815069992085270,false,[[1,[2,"GetCircle"]],[13,[7,[23,"Stage"]]]]]]],[0,null,false,null,369364736079041,[[-1,94,null,0,false,false,false,725022776728726,false]],[[39,82,null,702417495590419,false],[43,82,null,510524777956620,false],[43,114,null,345598668733330,false,[[4,39],[7,[0,0]]]]],[[0,null,false,null,860207746759467,[[43,78,null,0,false,false,false,908894561899564,false,[[8,4],[0,[0,0]]]]],[[43,61,null,947249720336127,false,[[0,[5,[20,43,115,false,null],[0,20]]]]]]]]]]],[0,[true,"Stages"],false,null,532950947231795,[[-1,20,null,0,false,false,false,532950947231795,false,[[1,[2,"Stages"]]]]],[],[[0,null,false,null,599090608784567,[[39,33,null,1,false,false,false,611428702019306,false]],[[-1,40,null,604574163102523,false,[[11,"CreateApplesRnd"],[7,[19,116,[[0,0],[0,1],[0,1]]]]]],[-1,40,null,160406078409277,false,[[11,"ApplesCountRnd"],[7,[19,92,[[19,102,[[0,1],[0,5]]]]]]]]],[[0,null,false,null,456594431086415,[[-1,56,null,0,false,false,false,825154336775688,false,[[11,"CreateApplesRnd"],[8,0],[7,[0,1]]]],[-1,23,null,0,true,false,false,932538221700169,false,[[1,[2,""]],[0,[0,1]],[0,[23,"ApplesCountRnd"]]]]],[[-1,71,null,467870106609601,false,[[4,52],[5,[2,"Game"]],[0,[20,39,30,false,null]],[0,[20,39,31,false,null]]]],[52,117,null,705664281748010,false,[[0,[0,0]],[0,[0,0]]]],[52,74,null,363916898404616,false,[[0,[7,[0,360],[19,27]]]]],[-1,34,null,491997123999419,false,[[0,[1,0.2]]]],[52,118,"LiteTween",258725120183270,false,[[3,4],[3,0],[0,[0,78]]]],[52,118,"LiteTween",779104817474817,false,[[3,5],[3,0],[0,[0,90]]]],[52,35,"LiteTween",491083563418456,false,[[3,0],[3,0]]],[52,119,"Pin",155280121432423,false,[[4,39],[3,2]]]]]]],[0,null,false,null,328545038790018,[[-1,56,null,0,false,true,false,428903811384599,false,[[11,"Stage"],[8,0],[7,[0,0]]]],[-1,79,null,0,false,false,false,366592904691779,false]],[[-1,40,null,384559354462409,false,[[11,"Step"],[7,[0,0]]]]]],[0,null,false,null,242285772497455,[],[[38,37,null,466959193990021,false,[[3,0],[7,[10,[2,"stage "],[23,"Stage"]]]]]],[[0,null,false,null,180296232041197,[[-1,56,null,0,false,false,false,972417521426553,false,[[11,"Stage"],[8,0],[7,[0,1]]]]],[[33,55,null,206129138669750,false,[[1,[2,"Rotate"]],[13,[7,[2,"simple"]],[7,[0,2]]]]]],[[0,null,false,null,781977378702800,[[-1,79,null,0,false,false,false,317392572701442,false]],[[-1,40,null,602107774215658,false,[[11,"Knives"],[7,[0,5]]]],[33,55,null,520943337411337,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,498643211491886,[[-1,56,null,0,false,false,false,320525505720368,false,[[11,"Stage"],[8,0],[7,[0,2]]]]],[[33,55,null,873962049205370,false,[[1,[2,"Rotate"]],[13,[7,[2,"simple"]],[7,[0,3]]]]]],[[0,null,false,null,550249926749438,[[-1,79,null,0,false,false,false,143775471533252,false]],[[-1,40,null,816318538440718,false,[[11,"Knives"],[7,[0,7]]]],[33,55,null,938971538370155,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,340512981428839,[[-1,56,null,0,false,false,false,620322560070023,false,[[11,"Stage"],[8,0],[7,[0,3]]]]],[[33,55,null,630456852249899,false,[[1,[2,"Rotate"]],[13,[7,[2,"sine"]],[7,[2,"0,359"]],[7,[0,7]]]]]],[[0,null,false,null,315649759333963,[[-1,79,null,0,false,false,false,885768409656796,false]],[[-1,40,null,290018893005726,false,[[11,"Knives"],[7,[0,8]]]],[33,55,null,486830464071518,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,650327081479746,[[-1,56,null,0,false,false,false,612061479301551,false,[[11,"Stage"],[8,0],[7,[0,4]]]]],[[33,55,null,472126330344038,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,359"]],[7,[2,"70"]]]]]],[[0,null,false,null,164385342893433,[[-1,79,null,0,false,false,false,562626331208499,false]],[[-1,40,null,751120252766952,false,[[11,"Knives"],[7,[0,8]]]],[33,55,null,691874379064023,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,702543542487739,[[-1,56,null,0,false,false,false,691826820418366,false,[[11,"Stage"],[8,0],[7,[0,5]]]]],[[33,55,null,558273894602645,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,180,359"]],[7,[2,"75"]]]]]],[[0,null,false,null,373629333816762,[[-1,79,null,0,false,false,false,748328248167859,false]],[[-1,40,null,361684440716230,false,[[11,"Knives"],[7,[0,10]]]],[33,55,null,792447094973740,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,941632137146113,[[-1,56,null,0,false,false,false,692308473989028,false,[[11,"Stage"],[8,0],[7,[0,6]]]]],[[33,55,null,685712333957232,false,[[1,[2,"Rotate"]],[13,[7,[2,"sine"]],[7,[2,"0,359"]],[7,[0,5]]]]]],[[0,null,false,null,668748782388354,[[-1,79,null,0,false,false,false,957815200592524,false]],[[-1,40,null,640959890492683,false,[[11,"Knives"],[7,[0,10]]]],[33,55,null,347558200081627,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,433006134342547,[[-1,56,null,0,false,false,false,475472057269319,false,[[11,"Stage"],[8,0],[7,[0,7]]]]],[[33,55,null,203912747603743,false,[[1,[2,"Rotate"]],[13,[7,[2,"simple"]],[7,[0,4]]]]]],[[0,null,false,null,736879945442954,[[-1,79,null,0,false,false,false,775243595373280,false]],[[-1,40,null,326200438242180,false,[[11,"Knives"],[7,[0,12]]]],[33,55,null,611801413824563,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,751137865092045,[[-1,56,null,0,false,false,false,526390484187332,false,[[11,"Stage"],[8,0],[7,[0,8]]]]],[[33,55,null,514735359749726,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,270"]],[7,[2,"60"]]]]]],[[0,null,false,null,339075220462649,[[-1,79,null,0,false,false,false,263507079507687,false]],[[-1,40,null,755891677108172,false,[[11,"Knives"],[7,[0,10]]]],[33,55,null,529128279133464,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,381681862838448,[[-1,56,null,0,false,false,false,290117369998946,false,[[11,"Stage"],[8,0],[7,[0,9]]]]],[[33,55,null,190756743554214,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"30,350"]],[7,[2,"80"]]]]]],[[0,null,false,null,156007446170539,[[-1,79,null,0,false,false,false,410207508071949,false]],[[-1,40,null,859851380168626,false,[[11,"Knives"],[7,[0,10]]]],[33,55,null,501872440839236,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,421994591050763,[[-1,56,null,0,false,false,false,613487362367772,false,[[11,"Stage"],[8,0],[7,[0,10]]]]],[[33,55,null,488641515473276,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"170,359"]],[7,[2,"90"]]]]]],[[0,null,false,null,452110935890880,[[-1,79,null,0,false,false,false,531345400713913,false]],[[-1,40,null,707614951423210,false,[[11,"Knives"],[7,[0,10]]]],[33,55,null,480614910402842,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,939271946359160,[[-1,56,null,0,false,false,false,102739777833472,false,[[11,"Stage"],[8,0],[7,[0,11]]]]],[[33,55,null,939814071322349,false,[[1,[2,"Rotate"]],[13,[7,[2,"sine"]],[7,[2,"30,280"]],[7,[0,4]]]]]],[[0,null,false,null,548479419872167,[[-1,79,null,0,false,false,false,530278111727771,false]],[[-1,40,null,967153386262633,false,[[11,"Knives"],[7,[0,10]]]],[33,55,null,503082755084176,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,283029114958964,[[-1,56,null,0,false,false,false,515458759901719,false,[[11,"Stage"],[8,0],[7,[0,12]]]]],[[33,55,null,335326976308265,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"170,359,10"]],[7,[2,"70"]]]]]],[[0,null,false,null,658242865837749,[[-1,79,null,0,false,false,false,527356184840505,false]],[[-1,40,null,441622454594470,false,[[11,"Knives"],[7,[0,10]]]],[33,55,null,588842549055813,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,235527684023432,[[-1,56,null,0,false,false,false,579860266722390,false,[[11,"Stage"],[8,0],[7,[0,13]]]]],[[33,55,null,518142505313553,false,[[1,[2,"Rotate"]],[13,[7,[2,"simple"]],[7,[1,-4.3]]]]]],[[0,null,false,null,436819770391469,[[-1,79,null,0,false,false,false,901735187740097,false]],[[-1,40,null,148944398221359,false,[[11,"Knives"],[7,[0,8]]]],[33,55,null,533632515061125,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,764362314969886,[[-1,56,null,0,false,false,false,398318566646331,false,[[11,"Stage"],[8,0],[7,[0,14]]]]],[[33,55,null,394788383193559,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"20,180,10"]],[7,[2,"80"]]]]]],[[0,null,false,null,170515721514006,[[-1,79,null,0,false,false,false,170890625807576,false]],[[-1,40,null,731291623964279,false,[[11,"Knives"],[7,[0,11]]]],[33,55,null,455416337321307,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,286326217582749,[[-1,56,null,0,false,false,false,590118103941289,false,[[11,"Stage"],[8,0],[7,[0,15]]]]],[[33,55,null,345394443013904,false,[[1,[2,"Rotate"]],[13,[7,[2,"sine"]],[7,[2,"1,250"]],[7,[0,3]]]]]],[[0,null,false,null,259560273905387,[[-1,79,null,0,false,false,false,170526505778076,false]],[[-1,40,null,812525742972633,false,[[11,"Knives"],[7,[0,10]]]],[33,55,null,335884863639555,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,688909629126842,[[-1,56,null,0,false,false,false,608808280779869,false,[[11,"Stage"],[8,0],[7,[0,16]]]]],[[33,55,null,331175532566621,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,70,50,200"]],[7,[2,"70"]]]]]],[[0,null,false,null,155176387617515,[[-1,79,null,0,false,false,false,213731365137151,false]],[[-1,40,null,317212219754297,false,[[11,"Knives"],[7,[0,6]]]],[33,55,null,712016164202275,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,661561088826874,[[-1,56,null,0,false,false,false,828079187374780,false,[[11,"Stage"],[8,0],[7,[0,17]]]]],[[33,55,null,834935581648117,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,20,359,200"]],[7,[2,"70"]]]]]],[[0,null,false,null,507866851818997,[[-1,79,null,0,false,false,false,767468537810358,false]],[[-1,40,null,208156599649257,false,[[11,"Knives"],[7,[0,6]]]],[33,55,null,261384027353018,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,207017300370995,[[-1,56,null,0,false,false,false,219875123979388,false,[[11,"Stage"],[8,0],[7,[0,18]]]]],[[33,55,null,772569008727877,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,20,359,100,350"]],[7,[2,"85"]]]]]],[[0,null,false,null,890032223108014,[[-1,79,null,0,false,false,false,858587997662225,false]],[[-1,40,null,282075758475159,false,[[11,"Knives"],[7,[0,13]]]],[33,55,null,120957555031490,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,491797932664059,[[-1,56,null,0,false,false,false,973657535709749,false,[[11,"Stage"],[8,0],[7,[0,19]]]]],[[33,55,null,629586438317312,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,20,359,100,350"]],[7,[2,"100"]]]]]],[[0,null,false,null,699345020713521,[[-1,79,null,0,false,false,false,258501631637034,false]],[[-1,40,null,129733971751974,false,[[11,"Knives"],[7,[0,13]]]],[33,55,null,651464133957699,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,230539990536747,[[-1,56,null,0,false,false,false,303867041073479,false,[[11,"Stage"],[8,0],[7,[0,20]]]]],[[33,55,null,138549038406281,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,20,359,200"]],[7,[2,"80"]]]]]],[[0,null,false,null,502204167218385,[[-1,79,null,0,false,false,false,609135603273165,false]],[[-1,40,null,471226637726348,false,[[11,"Knives"],[7,[0,7]]]],[33,55,null,824185242449979,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,781220515551106,[[-1,56,null,0,false,false,false,848353740830211,false,[[11,"Stage"],[8,0],[7,[0,21]]]]],[[33,55,null,329941502200187,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,70,50,200"]],[7,[2,"70"]]]]]],[[0,null,false,null,661855144619999,[[-1,79,null,0,false,false,false,204794970923309,false]],[[-1,40,null,378128739197469,false,[[11,"Knives"],[7,[0,7]]]],[33,55,null,713072947605203,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,871650357912393,[[-1,56,null,0,false,false,false,647349999300189,false,[[11,"Stage"],[8,0],[7,[0,22]]]]],[[33,55,null,626787693757691,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,70,50,200,350"]],[7,[2,"110"]]]]]],[[0,null,false,null,658362684816556,[[-1,79,null,0,false,false,false,850366836960590,false]],[[-1,40,null,225598838327088,false,[[11,"Knives"],[7,[0,7]]]],[33,55,null,564610208772007,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,102173407694973,[[-1,56,null,0,false,false,false,696697936772505,false,[[11,"Stage"],[8,0],[7,[0,23]]]]],[[33,55,null,705767357540513,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,70,50,210"]],[7,[2,"70"]]]]]],[[0,null,false,null,818942515025168,[[-1,79,null,0,false,false,false,451598811947236,false]],[[-1,40,null,567754936586097,false,[[11,"Knives"],[7,[0,7]]]],[33,55,null,378213973773643,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,211094087918284,[[-1,56,null,0,false,false,false,712909414251877,false,[[11,"Stage"],[8,0],[7,[0,24]]]]],[[33,55,null,969049436313709,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,20,50,200"]],[7,[2,"70"]]]]]],[[0,null,false,null,512739130227174,[[-1,79,null,0,false,false,false,506988886771834,false]],[[-1,40,null,994778083417585,false,[[11,"Knives"],[7,[0,8]]]],[33,55,null,836372825063285,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,289225707409162,[[-1,56,null,0,false,false,false,738852965852869,false,[[11,"Stage"],[8,0],[7,[0,25]]]]],[[33,55,null,425641743027019,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,20,50,200"]],[7,[2,"70"]]]]]],[[0,null,false,null,555463451376412,[[-1,79,null,0,false,false,false,284347215576328,false]],[[-1,40,null,461301691214412,false,[[11,"Knives"],[7,[0,9]]]],[33,55,null,609604655044610,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,270439750997573,[[-1,56,null,0,false,false,false,330182882716774,false,[[11,"Stage"],[8,0],[7,[0,26]]]]],[[33,55,null,391905772835999,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,20,50,200"]],[7,[2,"75"]]]]]],[[0,null,false,null,310324085119021,[[-1,79,null,0,false,false,false,150072015916591,false]],[[-1,40,null,780978446275525,false,[[11,"Knives"],[7,[0,8]]]],[33,55,null,749111437633829,false,[[1,[2,"CreateMiniKnives"]],[13]]]],[[0,null,false,null,450530998884885,[],[]]]]]],[0,null,false,null,103190592506729,[[-1,56,null,0,false,false,false,855408094516917,false,[[11,"Stage"],[8,0],[7,[0,27]]]]],[[33,55,null,111124010270751,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,70,50,200"]],[7,[2,"70"]]]]]],[[0,null,false,null,380506167080581,[[-1,79,null,0,false,false,false,458359161041368,false]],[[-1,40,null,198197030665392,false,[[11,"Knives"],[7,[0,7]]]],[33,55,null,719093417468848,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,562894029248973,[[-1,56,null,0,false,false,false,331451814100252,false,[[11,"Stage"],[8,0],[7,[0,28]]]]],[[33,55,null,733146221119578,false,[[1,[2,"Rotate"]],[13,[7,[2,"sine"]],[7,[2,"0,359"]],[7,[0,4]]]]]],[[0,null,false,null,876343934235836,[[-1,79,null,0,false,false,false,255913968728798,false]],[[-1,40,null,804995358738125,false,[[11,"Knives"],[7,[0,8]]]],[33,55,null,789524241313766,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,857257667601599,[[-1,56,null,0,false,false,false,984551714874360,false,[[11,"Stage"],[8,0],[7,[0,29]]]]],[[33,55,null,186457172240309,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,359"]],[7,[2,"120"]]]]]],[[0,null,false,null,123316582511454,[[-1,79,null,0,false,false,false,955542998190621,false]],[[-1,40,null,794723776076832,false,[[11,"Knives"],[7,[0,11]]]],[33,55,null,514059161159458,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,631440536972913,[[-1,56,null,0,false,false,false,406711561964546,false,[[11,"Stage"],[8,0],[7,[0,30]]]]],[[33,55,null,600403086913217,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,180,359"]],[7,[2,"100"]]]]]],[[0,null,false,null,410749211241725,[[-1,79,null,0,false,false,false,954089439233181,false]],[[-1,40,null,590660572675716,false,[[11,"Knives"],[7,[0,10]]]],[33,55,null,718736501210254,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,950404608053402,[[-1,56,null,0,false,false,false,897496712647139,false,[[11,"Stage"],[8,0],[7,[0,31]]]]],[[33,55,null,727546009914892,false,[[1,[2,"Rotate"]],[13,[7,[2,"sine"]],[7,[2,"0,359"]],[7,[0,5]]]]]],[[0,null,false,null,452187770327013,[[-1,79,null,0,false,false,false,412496975373652,false]],[[-1,40,null,544760748123054,false,[[11,"Knives"],[7,[0,10]]]],[33,55,null,410403756859875,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,138165717406262,[[-1,56,null,0,false,false,false,979496159297885,false,[[11,"Stage"],[8,0],[7,[0,32]]]]],[[33,55,null,209442062367924,false,[[1,[2,"Rotate"]],[13,[7,[2,"simple"]],[7,[0,4]]]]]],[[0,null,false,null,559711601211997,[[-1,79,null,0,false,false,false,910451723697465,false]],[[-1,40,null,316525913224384,false,[[11,"Knives"],[7,[0,12]]]],[33,55,null,207047639825118,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,597111099441020,[[-1,56,null,0,false,false,false,787175499889268,false,[[11,"Stage"],[8,0],[7,[0,33]]]]],[[33,55,null,934540279096894,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,270"]],[7,[2,"60"]]]]]],[[0,null,false,null,524903095891213,[[-1,79,null,0,false,false,false,439196024075653,false]],[[-1,40,null,209323006264340,false,[[11,"Knives"],[7,[0,10]]]],[33,55,null,254787048303579,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,661087081835422,[[-1,56,null,0,false,false,false,231751193811655,false,[[11,"Stage"],[8,0],[7,[0,34]]]]],[[33,55,null,348310965400762,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"30,350"]],[7,[2,"80"]]]]]],[[0,null,false,null,813280706948578,[[-1,79,null,0,false,false,false,598699428742553,false]],[[-1,40,null,352798383666285,false,[[11,"Knives"],[7,[0,10]]]],[33,55,null,606583963617206,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,742223010635671,[[-1,56,null,0,false,false,false,398687215211619,false,[[11,"Stage"],[8,0],[7,[0,35]]]]],[[33,55,null,185253486460261,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"170,359"]],[7,[2,"90"]]]]]],[[0,null,false,null,755277921825499,[[-1,79,null,0,false,false,false,702750152110405,false]],[[-1,40,null,805638649030919,false,[[11,"Knives"],[7,[0,10]]]],[33,55,null,207730072348318,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,720094727475755,[[-1,56,null,0,false,false,false,301345539822145,false,[[11,"Stage"],[8,0],[7,[0,36]]]]],[[33,55,null,580994133716796,false,[[1,[2,"Rotate"]],[13,[7,[2,"sine"]],[7,[2,"30,280"]],[7,[0,4]]]]]],[[0,null,false,null,230991977984966,[[-1,79,null,0,false,false,false,488861288810320,false]],[[-1,40,null,196931528339347,false,[[11,"Knives"],[7,[0,10]]]],[33,55,null,836549230694640,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,964967286872842,[[-1,56,null,0,false,false,false,910740544139697,false,[[11,"Stage"],[8,0],[7,[0,37]]]]],[[33,55,null,461046029394347,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"170,359,10"]],[7,[2,"70"]]]]]],[[0,null,false,null,405316287100629,[[-1,79,null,0,false,false,false,849317457123345,false]],[[-1,40,null,987087628911536,false,[[11,"Knives"],[7,[0,10]]]],[33,55,null,679067623848300,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,202315576917555,[[-1,56,null,0,false,false,false,972458442919792,false,[[11,"Stage"],[8,0],[7,[0,38]]]]],[[33,55,null,573283658465970,false,[[1,[2,"Rotate"]],[13,[7,[2,"simple"]],[7,[1,-4.3]]]]]],[[0,null,false,null,573675099778732,[[-1,79,null,0,false,false,false,489103647885188,false]],[[-1,40,null,259484563407597,false,[[11,"Knives"],[7,[0,8]]]],[33,55,null,820717658508101,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,855620102363485,[[-1,56,null,0,false,false,false,332583879935787,false,[[11,"Stage"],[8,0],[7,[0,39]]]]],[[33,55,null,977615082625245,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"20,180,10"]],[7,[2,"80"]]]]]],[[0,null,false,null,165642334954442,[[-1,79,null,0,false,false,false,571536152952622,false]],[[-1,40,null,320522169624639,false,[[11,"Knives"],[7,[0,11]]]],[33,55,null,486921478547112,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,962742731516082,[[-1,56,null,0,false,false,false,942300119678998,false,[[11,"Stage"],[8,0],[7,[0,40]]]]],[[33,55,null,502440476099119,false,[[1,[2,"Rotate"]],[13,[7,[2,"sine"]],[7,[2,"1,250"]],[7,[0,3]]]]]],[[0,null,false,null,696173903475250,[[-1,79,null,0,false,false,false,822385901855579,false]],[[-1,40,null,779025240326237,false,[[11,"Knives"],[7,[0,10]]]],[33,55,null,230517760216227,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,143548770938033,[[-1,56,null,0,false,false,false,613791307055251,false,[[11,"Stage"],[8,0],[7,[0,41]]]]],[[33,55,null,775590756429004,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,70,50,200"]],[7,[2,"70"]]]]]],[[0,null,false,null,799339323228465,[[-1,79,null,0,false,false,false,300832514185475,false]],[[-1,40,null,327725817290972,false,[[11,"Knives"],[7,[0,6]]]],[33,55,null,788833779405947,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,970796508810781,[[-1,56,null,0,false,false,false,842994616530496,false,[[11,"Stage"],[8,0],[7,[0,42]]]]],[[33,55,null,804104810527404,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,20,359,200"]],[7,[2,"70"]]]]]],[[0,null,false,null,589209660309295,[[-1,79,null,0,false,false,false,236904789415418,false]],[[-1,40,null,148483343603536,false,[[11,"Knives"],[7,[0,6]]]],[33,55,null,609404589563021,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,400623358824584,[[-1,56,null,0,false,false,false,625382244483135,false,[[11,"Stage"],[8,0],[7,[0,43]]]]],[[33,55,null,146371730205441,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,20,359,100,350"]],[7,[2,"85"]]]]]],[[0,null,false,null,868375312782551,[[-1,79,null,0,false,false,false,764002644890161,false]],[[-1,40,null,364432718777342,false,[[11,"Knives"],[7,[0,13]]]],[33,55,null,124778744813025,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,987703600196020,[[-1,56,null,0,false,false,false,253065007877255,false,[[11,"Stage"],[8,0],[7,[0,44]]]]],[[33,55,null,350763400520853,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,20,359,100,350"]],[7,[2,"100"]]]]]],[[0,null,false,null,916580147562495,[[-1,79,null,0,false,false,false,153402027874585,false]],[[-1,40,null,556601710160019,false,[[11,"Knives"],[7,[0,13]]]],[33,55,null,731960040497452,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,488939888247545,[[-1,56,null,0,false,false,false,794997251647400,false,[[11,"Stage"],[8,0],[7,[0,45]]]]],[[33,55,null,689448645471029,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,20,359,200"]],[7,[2,"80"]]]]]],[[0,null,false,null,185665007488690,[[-1,79,null,0,false,false,false,291726606594122,false]],[[-1,40,null,205734277767148,false,[[11,"Knives"],[7,[0,7]]]],[33,55,null,462192949341277,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,953980375308824,[[-1,56,null,0,false,false,false,739281213502235,false,[[11,"Stage"],[8,0],[7,[0,46]]]]],[[33,55,null,430565846173968,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,70,50,200"]],[7,[2,"70"]]]]]],[[0,null,false,null,485441337128277,[[-1,79,null,0,false,false,false,111657269525730,false]],[[-1,40,null,199450698364878,false,[[11,"Knives"],[7,[0,13]]]],[33,55,null,107382414919491,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,566744769421044,[[-1,56,null,0,false,false,false,857303198101936,false,[[11,"Stage"],[8,0],[7,[0,47]]]]],[[33,55,null,205846407528085,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,70,50,200,350"]],[7,[2,"110"]]]]]],[[0,null,false,null,346152300601541,[[-1,79,null,0,false,false,false,547450847982516,false]],[[-1,40,null,605020641136519,false,[[11,"Knives"],[7,[0,7]]]],[33,55,null,116039583846462,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,944984053678769,[[-1,56,null,0,false,false,false,273655627458589,false,[[11,"Stage"],[8,0],[7,[0,48]]]]],[[33,55,null,722280150574653,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,70,50,210"]],[7,[2,"110"]]]]]],[[0,null,false,null,947696483330811,[[-1,79,null,0,false,false,false,360848642752034,false]],[[-1,40,null,381768412700018,false,[[11,"Knives"],[7,[0,7]]]],[33,55,null,103892258688982,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,240742005592949,[[-1,56,null,0,false,false,false,103688998719946,false,[[11,"Stage"],[8,0],[7,[0,49]]]]],[[33,55,null,538896904313609,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,20,50,200"]],[7,[2,"70"]]]]]],[[0,null,false,null,208216760818339,[[-1,79,null,0,false,false,false,780254068069003,false]],[[-1,40,null,419819190489545,false,[[11,"Knives"],[7,[0,15]]]],[33,55,null,328655206171062,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,754074705191502,[[-1,56,null,0,false,false,false,176286456953715,false,[[11,"Stage"],[8,0],[7,[0,50]]]]],[[33,55,null,120996359485033,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,20,50,200"]],[7,[2,"95"]]]]]],[[0,null,false,null,254613886613752,[[-1,79,null,0,false,false,false,242337705690954,false]],[[-1,40,null,281075350461160,false,[[11,"Knives"],[7,[0,14]]]],[33,55,null,161512966659296,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,216157940009158,[[-1,56,null,0,false,false,false,725225924673507,false,[[11,"Stage"],[8,0],[7,[0,51]]]]],[[33,55,null,270253012741998,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,20,50,200"]],[7,[2,"75"]]]]]],[[0,null,false,null,495878946073183,[[-1,79,null,0,false,false,false,571474019220809,false]],[[-1,40,null,901498548220622,false,[[11,"Knives"],[7,[0,15]]]],[33,55,null,292013965839926,false,[[1,[2,"CreateMiniKnives"]],[13]]]],[[0,null,false,null,938992814998292,[],[]]]]]],[0,null,false,null,570070588097540,[[-1,56,null,0,false,false,false,879833981029054,false,[[11,"Stage"],[8,0],[7,[0,52]]]]],[[33,55,null,341077366992317,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,70,50,200"]],[7,[2,"100"]]]]]],[[0,null,false,null,369839481093755,[[-1,79,null,0,false,false,false,517598214416366,false]],[[-1,40,null,766954934212824,false,[[11,"Knives"],[7,[0,7]]]],[33,55,null,109456281151288,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,152362284648357,[[-1,56,null,0,false,false,false,651816863800947,false,[[11,"Stage"],[8,0],[7,[0,53]]]]],[[33,55,null,635186291114559,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,359"]],[7,[2,"120"]]]]]],[[0,null,false,null,201290247438561,[[-1,79,null,0,false,false,false,179723638041477,false]],[[-1,40,null,224905278838484,false,[[11,"Knives"],[7,[0,11]]]],[33,55,null,799223327582456,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,205319733218344,[[-1,56,null,0,false,false,false,118921154676245,false,[[11,"Stage"],[8,0],[7,[0,54]]]]],[[33,55,null,594193815525472,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,180,359"]],[7,[2,"100"]]]]]],[[0,null,false,null,512258007628216,[[-1,79,null,0,false,false,false,250554329897467,false]],[[-1,40,null,417901455920914,false,[[11,"Knives"],[7,[0,10]]]],[33,55,null,383021663759749,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,216972878930685,[[-1,56,null,0,false,false,false,438406636847447,false,[[11,"Stage"],[8,0],[7,[0,55]]]]],[[33,55,null,557227011015445,false,[[1,[2,"Rotate"]],[13,[7,[2,"sine"]],[7,[2,"0,300"]],[7,[0,4]]]]]],[[0,null,false,null,420377189569792,[[-1,79,null,0,false,false,false,750376913923490,false]],[[-1,40,null,204841469870521,false,[[11,"Knives"],[7,[0,13]]]],[33,55,null,521664960455869,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,915921705774014,[[-1,56,null,0,false,false,false,220658738435805,false,[[11,"Stage"],[8,0],[7,[0,56]]]]],[[33,55,null,487276766253764,false,[[1,[2,"Rotate"]],[13,[7,[2,"simple"]],[7,[0,4]]]]]],[[0,null,false,null,166257393705393,[[-1,79,null,0,false,false,false,776065297399321,false]],[[-1,40,null,497814160126067,false,[[11,"Knives"],[7,[0,12]]]],[33,55,null,699481020291935,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,570151549849349,[[-1,56,null,0,false,false,false,694303664651648,false,[[11,"Stage"],[8,0],[7,[0,57]]]]],[[33,55,null,300828383019255,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"1,270"]],[7,[2,"60"]]]]]],[[0,null,false,null,120481003885646,[[-1,79,null,0,false,false,false,579491444371142,false]],[[-1,40,null,709235123100395,false,[[11,"Knives"],[7,[0,10]]]],[33,55,null,591054946468677,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,845414503243798,[[-1,56,null,0,false,false,false,271444294809849,false,[[11,"Stage"],[8,0],[7,[0,58]]]]],[[33,55,null,436934173766811,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"30,350"]],[7,[2,"80"]]]]]],[[0,null,false,null,669007803707116,[[-1,79,null,0,false,false,false,188157154915148,false]],[[-1,40,null,362287146127735,false,[[11,"Knives"],[7,[0,15]]]],[33,55,null,819242422160467,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,377212500419986,[[-1,56,null,0,false,false,false,158260118705542,false,[[11,"Stage"],[8,0],[7,[0,59]]]]],[[33,55,null,876494495395684,false,[[1,[2,"Rotate"]],[13,[7,[2,"complex"]],[7,[2,"170,359"]],[7,[2,"100"]]]]]],[[0,null,false,null,483674357642589,[[-1,79,null,0,false,false,false,560486900825150,false]],[[-1,40,null,114628502726727,false,[[11,"Knives"],[7,[0,14]]]],[33,55,null,419051730408608,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]],[0,null,false,null,196404718870524,[[-1,56,null,0,false,false,false,943278009732767,false,[[11,"Stage"],[8,0],[7,[0,60]]]]],[[33,55,null,252360119467793,false,[[1,[2,"Rotate"]],[13,[7,[2,"sine"]],[7,[2,"30,280"]],[7,[0,4]]]]]],[[0,null,false,null,906670804594722,[[-1,79,null,0,false,false,false,544949766980174,false]],[[-1,40,null,962633106689488,false,[[11,"Knives"],[7,[0,16]]]],[33,55,null,740096132640662,false,[[1,[2,"CreateMiniKnives"]],[13]]]]]]]]],[0,null,false,null,788110747798596,[[33,36,null,2,false,false,false,117750790279542,false,[[1,[2,"GetCircle"]]]]],[[-1,71,null,750412402226103,false,[[4,39],[5,[2,"Game"]],[0,[0,360]],[0,[0,504]]]],[33,55,null,592303559205463,false,[[1,[2,"PlaySound"]],[13,[7,[2,"new"]]]]]]],[0,null,false,null,328696209433090,[[-1,48,null,0,false,false,false,357646179481021,false,[[7,[8,[23,"Stage"],[0,5]]],[8,0],[7,[0,0]]]]],[[39,120,null,446720271645468,false,[[1,[2,"Boss"]],[3,1]]],[39,77,null,475732710932685,false,[[0,[5,[7,[23,"Stage"],[0,5]],[0,1]]]]],[-1,40,null,706080764616083,false,[[11,"LatestBoss"],[7,[7,[23,"Stage"],[0,5]]]]]],[[0,null,false,null,418976289503596,[[-1,79,null,0,false,false,false,835948889032983,false]],[[41,35,"LiteTween",120708840666030,false,[[3,0],[3,0]]],[20,35,"LiteTween",900424613226728,false,[[3,0],[3,0]]]]],[0,null,false,null,562774575474572,[[28,28,null,0,false,false,false,184433025643267,false,[[10,0],[8,0],[7,[2,"stage"]]]]],[[28,32,null,985993973051784,false,[[7,[10,[2,"BOSS: "],[19,91,[[23,"BossList"],[7,[23,"Stage"],[0,5]],[2,"/"]]]]]]],[28,121,null,196690196525176,false,[[1,[2,"SetColor"]],[0,[0,0]],[0,[0,94]]]],[28,121,null,980764894723898,false,[[1,[2,"SetColor"]],[0,[0,1]],[0,[0,42]]]],[28,121,null,987869080089779,false,[[1,[2,"SetColor"]],[0,[0,2]],[0,[0,28]]]]]],[0,null,false,null,762648301853565,[],[[20,122,null,999066591495139,false,[[1,[2,"SetColor"]],[0,[0,0]],[0,[0,94]]]],[20,122,null,651590940573230,false,[[1,[2,"SetColor"]],[0,[0,1]],[0,[0,70]]]],[20,122,null,396258694716264,false,[[1,[2,"SetColor"]],[0,[0,2]],[0,[0,28]]]]]]]],[0,null,false,null,313962681837030,[[-1,48,null,0,false,true,false,834587525430487,false,[[7,[8,[23,"Stage"],[0,5]]],[8,0],[7,[0,0]]]]],[],[[0,null,false,null,676905265978918,[[20,123,"LiteTween",0,false,false,false,662212180060724,false,[[8,0],[0,[0,1]]]],[-1,79,null,0,false,false,false,308343409269968,false]],[[41,118,"LiteTween",469215715053400,false,[[3,3],[3,0],[0,[0,100]]]],[41,35,"LiteTween",348761858206100,false,[[3,0],[3,0]]],[20,124,"LiteTween",809801990434377,false,[[0,[1,0.3]]]],[20,118,"LiteTween",348462087764495,false,[[3,0],[3,0],[0,[0,463]]]],[20,118,"LiteTween",185231988215671,false,[[3,1],[3,0],[0,[20,20,31,false,null]]]],[20,35,"LiteTween",184729805256376,false,[[3,0],[3,0]]]]],[0,null,false,null,722462974436936,[[28,28,null,0,false,false,false,541240359989656,false,[[10,0],[8,0],[7,[2,"stage"]]]]],[[28,121,null,708379501494321,false,[[1,[2,"SetColor"]],[0,[0,0]],[0,[0,100]]]],[28,121,null,394136199508463,false,[[1,[2,"SetColor"]],[0,[0,1]],[0,[0,100]]]],[28,121,null,785640200005824,false,[[1,[2,"SetColor"]],[0,[0,2]],[0,[0,100]]]]]],[0,null,false,null,357076745428536,[],[[20,122,null,738490905517985,false,[[1,[2,"SetColor"]],[0,[0,0]],[0,[0,100]]]],[20,122,null,393446988923386,false,[[1,[2,"SetColor"]],[0,[0,1]],[0,[0,100]]]],[20,122,null,199554522191156,false,[[1,[2,"SetColor"]],[0,[0,2]],[0,[0,100]]]]]]]]]],[0,[true,"Circles"],false,null,466221489825265,[[-1,20,null,0,false,false,false,466221489825265,false,[[1,[2,"Circles"]]]]],[],[[0,null,false,null,928663786641326,[[33,36,null,2,false,false,false,835202723326805,false,[[1,[2,"Rotate"]]]]],[],[[0,null,false,null,415226698950466,[[33,109,null,0,false,false,false,953709389102901,false,[[0,[0,0]],[8,0],[7,[2,"simple"]]]]],[[39,74,null,991691168584045,false,[[0,[4,[20,39,83,false,null],[20,33,41,false,null,[[0,1]]]]]]]]],[0,null,false,null,131911251808020,[[33,109,null,0,false,false,false,918219860009071,false,[[0,[0,0]],[8,0],[7,[2,"complex"]]]]],[[-1,40,null,238921230026596,false,[[11,"AngleList"],[7,[20,33,41,false,null,[[0,1]]]]]],[-1,40,null,966214956647331,false,[[11,"SpeedList"],[7,[20,33,41,false,null,[[0,2]]]]]]],[[0,null,false,null,568700020039031,[[-1,23,null,0,true,false,false,555791416257656,false,[[1,[2,""]],[0,[0,0]],[0,[19,49,[[23,"AngleList"],[2,","]]]]]]],[],[[0,null,false,null,131795916598459,[[-1,48,null,0,false,false,false,506815012048969,false,[[7,[20,39,83,false,null]],[8,0],[7,[19,92,[[19,91,[[23,"AngleList"],[5,[19,27],[0,1]],[2,","]]]]]]]]],[],[[0,null,false,null,109361855598640,[[-1,48,null,0,false,false,false,775807989628393,false,[[7,[19,81,[[20,33,41,false,null,[[0,2]]],[2,","]]]],[8,0],[7,[0,-1]]]]],[[39,124,"LiteTween",656298299905775,false,[[0,[7,[5,[19,92,[[19,91,[[23,"AngleList"],[19,27],[2,","]]]]],[19,92,[[19,91,[[23,"AngleList"],[5,[19,27],[0,1]],[2,","]]]]]],[19,92,[[23,"SpeedList"]]]]]]]]],[0,null,false,null,804896963011440,[[-1,48,null,0,false,true,false,984523179388566,false,[[7,[19,81,[[20,33,41,false,null,[[0,2]]],[2,","]]]],[8,0],[7,[0,-1]]]]],[[39,124,"LiteTween",682446398109750,false,[[0,[7,[5,[19,92,[[19,91,[[23,"AngleList"],[19,27],[2,","]]]]],[19,92,[[19,91,[[23,"AngleList"],[5,[19,27],[0,1]],[2,","]]]]]],[19,92,[[19,91,[[23,"SpeedList"],[5,[19,27],[0,1]],[2,","]]]]]]]]]]],[0,null,false,null,193992797364724,[],[[39,118,"LiteTween",307680310386037,false,[[3,2],[3,0],[0,[19,92,[[19,91,[[23,"AngleList"],[23,"Step"],[2,","]]]]]]]],[39,35,"LiteTween",625865657127765,false,[[3,0],[3,0]]],[-1,50,null,551926675102800,false,[[11,"Step"],[7,[0,1]]]]]]]]]],[0,null,false,null,199511994224992,[[-1,56,null,0,false,false,false,190757237313593,false,[[11,"Step"],[8,0],[7,[4,[19,49,[[23,"AngleList"],[2,","]]],[0,1]]]]]],[[-1,40,null,153492716015015,false,[[11,"Step"],[7,[0,0]]]]]]]],[0,null,false,null,809481618361810,[[33,109,null,0,false,false,false,654183170901287,false,[[0,[0,0]],[8,0],[7,[2,"sine"]]]]],[],[[0,null,false,null,267561576293543,[[39,125,"Sine",0,false,true,false,229200394899860,false]],[[39,74,null,542229569202478,false,[[0,[7,[4,[19,92,[[19,91,[[20,33,41,false,null,[[0,1]]],[0,0],[2,","]]]]],[19,92,[[19,91,[[20,33,41,false,null,[[0,1]]],[0,1],[2,","]]]]]],[0,2]]]]],[39,126,"Sine",800853002848524,false,[[3,1]]]]],[0,null,false,null,194764095677534,[],[[39,127,"Sine",514087052063335,false,[[0,[5,[19,128,[[19,92,[[19,91,[[20,33,41,false,null,[[0,1]]],[0,0],[2,","]]]]],[19,92,[[19,91,[[20,33,41,false,null,[[0,1]]],[0,1],[2,","]]]]]]],[7,[4,[19,92,[[19,91,[[20,33,41,false,null,[[0,1]]],[0,0],[2,","]]]]],[19,92,[[19,91,[[20,33,41,false,null,[[0,1]]],[0,1],[2,","]]]]]],[0,2]]]]]],[39,129,"Sine",775869267253071,false,[[0,[20,33,41,false,null,[[0,2]]]]]]]]]]]]]],[0,[true,"Mini Knives"],false,null,724084101731343,[[-1,20,null,0,false,false,false,724084101731343,false,[[1,[2,"Mini Knives"]]]]],[],[[0,null,false,null,300651560627016,[[33,36,null,2,false,false,false,938003038059340,false,[[1,[2,"CreateMiniKnives"]]]]],[[42,101,null,168549517783861,false]],[[0,null,false,null,689403609850388,[[-1,56,null,0,false,false,false,156103598918661,false,[[11,"Knives"],[8,4],[7,[0,0]]]],[-1,23,null,0,true,false,false,373197120912101,false,[[1,[2,""]],[0,[0,0]],[0,[5,[23,"Knives"],[0,1]]]]]],[[-1,71,null,895135075995154,false,[[4,42],[5,[2,"Game"]],[0,[0,50]],[0,[5,[0,1220],[6,[19,27],[0,50]]]]]],[42,60,null,990149745048737,false,[[10,0],[7,[4,[19,27],[0,1]]]]]]]]],[0,null,false,null,988313222877442,[[42,51,null,0,false,false,false,455189077403846,false,[[10,0],[8,4],[7,[23,"Knives"]]]]],[[42,77,null,996167120170695,false,[[0,[0,1]]]]]]]],[0,[true,"Knives"],false,null,103393353461197,[[-1,20,null,0,false,false,false,103393353461197,false,[[1,[2,"Knives"]]]]],[],[[0,[true,"Creating Knives"],false,null,265625135652593,[[-1,20,null,0,false,false,false,265625135652593,false,[[1,[2,"Creating Knives"]]]]],[],[[0,null,false,null,994486998228689,[[-1,21,null,1,false,false,false,446661551368248,false],[40,51,null,0,false,false,false,869593679193612,false,[[10,2],[8,0],[7,[0,0]]]]],[[40,101,null,865204854453781,false],[40,77,null,619056936165771,false,[[0,[23,"SelectedKnife"]]]]]],[0,null,false,null,623220881573003,[[-1,56,null,0,false,false,false,697707490924345,false,[[11,"New"],[8,0],[7,[0,-1]]]],[-1,56,null,0,false,false,false,175122022686052,false,[[11,"Knives"],[8,4],[7,[0,0]]]]],[[-1,71,null,104787311095935,false,[[4,40],[5,[2,"Game"]],[0,[0,360]],[0,[0,1208]]]],[40,61,null,770315189321112,false,[[0,[0,0]]]],[-1,40,null,804727789237730,false,[[11,"New"],[7,[20,40,130,false,null]]]],[-1,40,null,911810697540606,false,[[11,"Last"],[7,[20,74,130,false,null]]]]]],[0,null,false,null,601995067538662,[[74,51,null,0,false,false,false,362692194220924,false,[[10,3],[8,0],[7,[0,0]]]]],[[74,77,null,671597654909457,false,[[0,[23,"SelectedKnife"]]]]]]]],[0,[true,"Throwing Knives"],false,null,322173826801090,[[-1,20,null,0,false,false,false,322173826801090,false,[[1,[2,"Throwing Knives"]]]]],[],[[0,null,false,null,302196772994205,[[32,44,null,1,false,false,false,705871403026443,false],[-1,56,null,0,false,false,false,489658061124709,false,[[11,"KnifeDone"],[8,0],[7,[0,0]]]],[-1,45,null,0,false,true,false,398209691407024,false,[[5,[2,"Equip"]]]],[-1,56,null,0,false,false,false,332298309074102,false,[[11,"Start"],[8,0],[7,[0,1]]]],[40,51,null,0,false,false,false,175871649960409,false,[[10,2],[8,0],[7,[0,0]]]],[39,131,null,0,false,false,false,165203498281665,false],[-1,56,null,0,false,false,false,555055536473599,false,[[11,"isPaused"],[8,0],[7,[0,0]]]]],[[-1,50,null,696991647864992,false,[[11,"Score"],[7,[0,1]]]]],[[0,null,false,null,292779170920954,[[40,132,null,0,false,false,true,651034392193134,false,[[0,[23,"New"]]]]],[[74,133,"Bullet",305567579487490,false,[[3,1]]],[74,134,"Bullet",246648668977571,false,[[0,[0,270]]]],[-1,40,null,754091662054202,false,[[11,"New"],[7,[0,-1]]]],[-1,58,null,553797346288116,false,[[11,"Knives"],[7,[0,1]]]],[33,55,null,135210672809905,false,[[1,[2,"PlaySound"]],[13,[7,[2,"hit"]]]]]]]]],[0,null,false,null,558215413011423,[[40,135,null,0,false,false,true,229738584269629,false,[[4,74]]],[40,87,null,0,false,false,false,982891400418573,false,[[4,39]]],[-1,56,null,0,false,false,false,366687724801753,false,[[11,"KnifeDone"],[8,0],[7,[0,0]]]],[40,51,null,0,false,false,false,933309494105294,false,[[10,2],[8,0],[7,[0,0]]]],[74,51,null,0,false,false,false,422090546103421,false,[[10,2],[8,0],[7,[0,0]]]]],[[33,55,null,475848073561426,false,[[1,[2,"PlaySound"]],[13,[7,[2,"block"]]]]],[74,136,"Pin",991594254004873,false],[74,137,null,610796100170892,false,[[0,[0,90]],[0,[0,100]]]],[-1,58,null,342015501430529,false,[[11,"Score"],[7,[0,1]]]],[33,55,null,609050618900309,false,[[1,[2,"ShakeCircle"]],[13]]],[74,60,null,289704024412789,false,[[10,0],[7,[0,1]]]],[-1,40,null,743762624192727,false,[[11,"KnifeDone"],[7,[0,1]]]],[-1,34,null,237309708330982,false,[[0,[1,0.6]]]],[-1,40,null,812660119061300,false,[[11,"Lose"],[7,[0,1]]]]]],[0,null,false,null,945124300604617,[[40,135,null,0,false,false,true,343188816831905,false,[[4,39]]],[40,51,null,0,false,false,false,860673392059139,false,[[10,2],[8,0],[7,[0,0]]]]],[[33,55,null,225868568191473,false,[[1,[2,"CreateParticles"]],[13,[7,[20,40,130,false,null]]]]],[33,55,null,521337816773215,false,[[1,[2,"ShakeCircle"]],[13]]],[40,138,"Bullet",310346419603561,false,[[0,[0,0]]]],[40,120,null,876432783373583,false,[[1,[2,"m"]],[3,0]]],[40,84,null,338487414357901,false,[[0,[20,39,30,false,null]],[0,[20,39,31,false,null]]]],[40,119,"Pin",339104328033602,false,[[4,39],[3,0]]],[43,61,null,988846551684377,false,[[0,[0,70]]]]]],[0,null,false,null,370091645180510,[[74,139,null,0,false,false,false,285706445521110,false],[74,51,null,0,false,false,false,167326751156085,false,[[10,0],[8,0],[7,[0,1]]]],[74,51,null,0,false,false,false,148026932043035,false,[[10,2],[8,0],[7,[0,0]]]]],[[74,101,null,635745596246094,false]]],[0,null,false,null,557973625986704,[[33,36,null,2,false,false,false,553911421881482,false,[[1,[2,"CreateParticles"]]]]],[],[[0,null,false,null,201296149838350,[[40,132,null,0,false,false,true,102933707073642,false,[[0,[20,33,41,false,null,[[0,0]]]]]],[-1,23,null,0,true,false,false,634592493621205,false,[[1,[2,""]],[0,[0,0]],[0,[19,116,[[0,2],[0,3],[0,4],[0,5]]]]]]],[[-1,71,null,807174137299912,false,[[4,46],[5,[2,"Game"]],[0,[20,40,30,false,null]],[0,[20,40,31,false,null]]]],[46,43,null,871315121750222,false,[[0,[19,102,[[1,0.5],[0,1]]]]]],[46,134,"Bullet",254612172814438,false,[[0,[19,102,[[0,180]]]]]],[46,138,"Bullet",536387374234849,false,[[0,[19,102,[[0,500],[0,1000]]]]]]]]]],[0,null,false,null,920321986934747,[[33,36,null,2,false,false,false,347409391741297,false,[[1,[2,"ShakeCircle"]]]]],[[39,137,null,805851427978081,false,[[0,[19,102,[[0,360]]]],[0,[0,5]]]],[-1,34,null,505428531319302,false,[[0,[1,0.05]]]],[39,84,null,875808942072790,false,[[0,[0,360]],[0,[0,504]]]]]]]],[0,[true,"Blocked"],false,null,476918183482511,[[-1,20,null,0,false,false,false,476918183482511,false,[[1,[2,"Blocked"]]]]],[],[[0,null,false,null,588622423167995,[[74,51,null,0,false,false,false,927168719376465,false,[[10,0],[8,0],[7,[0,1]]]],[74,51,null,0,false,false,false,814107556037959,false,[[10,2],[8,0],[7,[0,0]]]]],[[74,74,null,845681755789411,false,[[0,[4,[20,74,83,false,null],[6,[21,74,false,null,1],[0,8]]]]]],[74,140,"Bullet",718339731392062,false,[[0,[0,3000]]]],[74,138,"Bullet",761619909262804,false,[[0,[0,2000]]]],[74,134,"Bullet",311166913884225,false,[[0,[4,[0,90],[19,102,[[0,-20],[0,20]]]]]]],[74,137,null,256246783607053,false,[[0,[4,[0,90],[19,102,[[0,30],[0,-30]]]]],[0,[0,10]]]]]],[0,null,false,null,715268948398621,[[74,33,null,1,false,false,false,994935357392507,false]],[[74,60,null,658643398957468,false,[[10,1],[7,[19,116,[[0,-1],[0,1]]]]]]]]]]]],[0,[true,"Broken Circle"],false,null,585184516690692,[[-1,20,null,0,false,false,false,585184516690692,false,[[1,[2,"Broken Circle"]]]]],[],[[0,null,false,null,413942975601639,[[-1,21,null,1,false,false,false,245805989853101,false]],[[44,101,null,384947443208961,false]]],[0,null,false,null,507553407000351,[[44,131,null,0,false,false,false,689288978151720,false]],[[44,74,null,464289727826317,false,[[0,[4,[20,44,83,false,null],[6,[0,5],[21,44,false,null,0]]]]]]]],[0,null,false,null,585111214564222,[[-1,56,null,0,false,false,false,132831295469365,false,[[11,"Knives"],[8,0],[7,[0,0]]]],[-1,79,null,0,false,false,false,582459849602154,false]],[[-1,34,null,636738857720083,false,[[0,[1,0.1]]]],[33,55,null,169094432683017,false,[[1,[2,"MakeBroken"]],[13]]],[38,37,null,570295702068056,false,[[3,0],[7,[2,"Broke"]]]]]],[0,null,false,null,173387164115581,[[33,36,null,2,false,false,false,433755000077592,false,[[1,[2,"MakeBroken"]]]],[-1,56,null,0,false,false,false,977268348066464,false,[[11,"KnifeDone"],[8,0],[7,[0,0]]]],[74,51,null,0,false,false,false,309539899253396,false,[[10,2],[8,0],[7,[0,0]]]]],[[39,101,null,897787649520083,false],[74,136,"Pin",139866396890451,false],[74,140,"Bullet",931332055169616,false,[[0,[0,3000]]]],[74,134,"Bullet",407378250479214,false,[[0,[19,102,[[0,360]]]]]],[74,60,null,965980998590145,false,[[10,0],[7,[0,1]]]],[74,138,"Bullet",241319109118447,false,[[0,[0,500]]]],[33,55,null,550935451314010,false,[[1,[2,"PlaySound"]],[13,[7,[2,"break"]]]]]],[[0,null,false,null,213777303133778,[[39,141,null,0,false,false,false,891939120850961,false,[[1,[2,"Default"]]]],[-1,23,null,0,true,false,false,508239450105741,false,[[1,[2,""]],[0,[0,1]],[0,[0,3]]]]],[[-1,71,null,350365262791874,false,[[4,44],[5,[2,"Game"]],[0,[20,39,30,false,null]],[0,[20,39,31,false,null]]]],[44,120,null,723811568270350,false,[[1,[10,[2,"a"],[19,27]]],[3,1]]],[44,60,null,175586227335106,false,[[10,0],[7,[19,116,[[0,-1],[0,1]]]]]],[44,134,"Bullet",704400639982378,false,[[0,[4,[19,102,[[0,200],[0,300]]],[0,0]]]]]]],[0,null,false,null,911789091244560,[],[[52,101,null,862683238071203,false],[-1,50,null,349446586533757,false,[[11,"Stage"],[7,[0,1]]]],[-1,34,null,324135134353262,false,[[0,[0,1]]]],[33,55,null,571076548070090,false,[[1,[2,"GetCircle"]],[13,[7,[23,"Stage"]]]]],[33,55,null,808304631336917,false,[[1,[2,"showAds"]],[13]]]]]]]]],[0,[true,"Lose"],false,null,953696138713101,[[-1,20,null,0,false,false,false,953696138713101,false,[[1,[2,"Lose"]]]]],[],[[0,null,false,null,965865871584857,[[-1,21,null,1,false,false,false,469588269760539,false]],[[-1,47,null,681349302210666,false,[[5,[2,"Lose"]],[3,0]]],[-1,106,null,867337032978957,false,[[5,[2,"Lose"]],[0,[0,0]]]]]],[0,null,false,null,385757596304033,[[-1,56,null,0,false,false,false,521475481189845,false,[[11,"Lose"],[8,0],[7,[0,1]]]]],[],[[0,null,false,null,530022547336298,[[-1,45,null,0,false,true,false,448095944160382,false,[[5,[2,"Equip"]]]]],[[-1,47,null,572541031342729,false,[[5,[2,"Lose"]],[3,1]]],[-1,106,null,897601816431604,false,[[5,[2,"Lose"]],[0,[4,[19,107,[[2,"Lose"]]],[0,5]]]]],[-1,106,null,234165037870558,false,[[5,[2,"EquipBack"]],[0,[5,[19,107,[[2,"EquipBack"]]],[0,2]]]]]]],[0,null,false,null,298319092954372,[[-1,56,null,0,false,false,false,831323056079878,false,[[11,"Score"],[8,5],[7,[23,"BestScore"]]]],[-1,79,null,0,false,false,false,662928629511694,false]],[[67,54,null,122496490642229,false,[[1,[2,"KnifeHit-BestScore"]],[7,[23,"Score"]]]],[34,70,null,523601803229090,false,[[1,[2,"KnifeHit-BestScore"]]]],[23,75,null,285308783375290,false,[[3,1]]]]],[0,null,false,null,427024913115104,[[-1,56,null,0,false,true,false,773248047661567,false,[[11,"Score"],[8,5],[7,[23,"BestScore"]]]]],[[23,75,null,511782039738208,false,[[3,0]]]]],[0,null,false,null,107986496502731,[[-1,56,null,0,false,false,false,880838502934850,false,[[11,"Stage"],[8,4],[7,[23,"BestStage"]]]]],[[67,54,null,374034258826266,false,[[1,[2,"KnifeHit-BestStage"]],[7,[23,"Stage"]]]]]],[0,null,false,null,261859660552498,[[28,28,null,0,false,false,false,485523422969964,false,[[10,0],[8,0],[7,[2,"apple"]]]]],[[15,88,null,414503853576988,false,[[5,[2,"Lose"]]]],[28,89,null,465493516925594,false,[[5,[2,"Lose"]]]]]],[0,null,false,null,285378874135169,[[-1,56,null,0,false,false,false,276937321136849,false,[[11,"isSaved"],[8,0],[7,[0,0]]]]],[[38,37,null,514885578122710,false,[[3,0],[7,[2,"Loser"]]]],[33,55,null,561071003782865,false,[[1,[2,"saveData"]],[13]]],[-1,40,null,654410017305233,false,[[11,"isSaved"],[7,[0,1]]]]]]]],[0,null,false,null,946180244888782,[[-1,56,null,0,false,false,false,111090232785107,false,[[11,"Lose"],[8,0],[7,[0,0]]]],[-1,65,null,0,false,false,false,814269843632757,false,[[5,[2,"Lose"]],[8,4],[0,[0,0]]]]],[[-1,47,null,418306090693958,false,[[5,[2,"Lose"]],[3,1]]],[-1,106,null,455704481635044,false,[[5,[2,"Lose"]],[0,[5,[19,107,[[2,"Lose"]]],[0,5]]]]]]]]],[0,[true,"Dots"],false,null,808652839507927,[[-1,20,null,0,false,false,false,808652839507927,false,[[1,[2,"Dots"]]]]],[],[[0,null,false,null,307811658486058,[[-1,56,null,0,false,false,false,626260247149286,false,[[11,"Stage"],[8,3],[7,[0,5]]]],[41,51,null,0,false,false,false,543529390965742,false,[[10,0],[8,0],[7,[23,"Stage"]]]]],[[41,77,null,707045983777608,false,[[0,[0,1]]]]]],[0,null,false,null,298627998256671,[[-1,56,null,0,false,false,false,504236838863577,false,[[11,"Stage"],[8,4],[7,[0,5]]]],[41,51,null,0,false,false,false,992806530821003,false,[[10,0],[8,0],[7,[8,[23,"Stage"],[0,5]]]]]],[[41,77,null,520919893484781,false,[[0,[0,1]]]]]]]],[0,[true,"Equip Box"],false,null,517715650641230,[[-1,20,null,0,false,false,false,517715650641230,false,[[1,[2,"Equip Box"]]]]],[],[[0,null,false,null,716777670796920,[[-1,21,null,1,false,false,false,989221181973902,false]],[[-1,47,null,831445826386528,false,[[5,[2,"Equip"]],[3,0]]],[-1,47,null,115103579657211,false,[[5,[2,"EquipBack"]],[3,0]]],[-1,106,null,513099707644087,false,[[5,[2,"EquipBack"]],[0,[0,75]]]],[-1,40,null,134614083133961,false,[[11,"Start"],[7,[0,1]]]]]],[0,null,false,null,374753444557219,[[-1,48,null,0,false,false,false,723292864160989,false,[[7,[19,81,[[23,"UnlockedKnives"],[10,[19,59,[[4,[19,92,[[7,[23,"Stage"],[0,5]]]],[0,8]]]],[2,","]]]]],[8,0],[7,[0,-1]]]],[-1,56,null,0,false,false,false,282612846890519,false,[[11,"Lose"],[8,0],[7,[0,1]]]],[-1,56,null,0,false,false,false,646422340395050,false,[[11,"Stage"],[8,4],[7,[0,5]]]],[-1,79,null,0,false,false,false,499451136578679,false]],[[-1,40,null,381931153731453,false,[[11,"Start"],[7,[0,0]]]],[-1,47,null,578922739882003,false,[[5,[2,"Equip"]],[3,1]]],[-1,47,null,835814138425438,false,[[5,[2,"EquipBack"]],[3,1]]],[-1,50,null,517033883562169,false,[[11,"CollectedKnives"],[7,[10,[19,59,[[19,92,[[7,[23,"Stage"],[0,5]]]]]],[2,","]]]]],[67,54,null,840213177807251,false,[[1,[2,"KnifeHit-UnlockedKnives"]],[7,[10,[10,[23,"UnlockedKnives"],[19,59,[[4,[19,92,[[7,[23,"Stage"],[0,5]]]],[0,8]]]]],[2,","]]]]],[-1,40,null,917552977089435,false,[[11,"UnlockedKnives"],[7,[10,[10,[23,"UnlockedKnives"],[19,59,[[4,[19,92,[[7,[23,"Stage"],[0,5]]]],[0,8]]]]],[2,","]]]]]]],[0,null,false,null,458347253831300,[[-1,56,null,0,false,true,false,416655882080235,false,[[11,"CurBossFolo"],[8,0],[7,[23,"CurBoss"]]]]],[[-1,40,null,170167121062296,false,[[11,"CurBossFolo"],[7,[23,"CurBoss"]]]]],[[0,null,false,null,133247398821068,[[27,28,null,0,false,false,false,288202478618554,false,[[10,0],[8,0],[7,[2,"defeat"]]]]],[[27,32,null,615837600138933,false,[[7,[10,[19,91,[[23,"BossList"],[23,"CurBoss"],[2,"/"]]],[2," DEFEATED!"]]]]]]]]],[0,null,false,null,798024038988766,[[-1,56,null,0,false,false,false,701713613478290,false,[[11,"CurBoss"],[8,0],[7,[0,0]]]]],[[-1,40,null,286453726102590,false,[[11,"CurBoss"],[7,[19,92,[[19,91,[[23,"CollectedKnives"],[0,1],[2,","]]]]]]]]]],[0,null,false,null,320785560544984,[[40,51,null,0,false,false,false,427148349061188,false,[[10,2],[8,0],[7,[0,1]]]]],[[40,77,null,927348013298254,false,[[0,[4,[0,8],[23,"LatestBoss"]]]]],[40,61,null,643937583590373,false,[[0,[0,100]]]]]]]],[0,[true,"Game Apples"],false,null,988221998160927,[[-1,20,null,0,false,false,false,988221998160927,false,[[1,[2,"Game Apples"]]]]],[],[[0,null,false,null,389501788444120,[[74,68,null,0,false,false,false,953132710203706,false,[[5,[2,"Game"]]]],[74,142,"Pin",0,false,false,false,565525201468845,false]],[],[[0,null,false,null,394064342944639,[[52,135,null,0,false,false,true,123834135241443,false,[[4,74]]],[52,108,null,0,false,false,false,860238045424584,false,[[8,0],[0,[0,0]]]]],[[-1,50,null,379131392446018,false,[[11,"Apples"],[7,[0,1]]]],[67,54,null,559235099777694,false,[[1,[2,"KnifeHit-Apples"]],[7,[23,"Apples"]]]],[34,70,null,595769603624759,false,[[1,[2,"KnifeHit-Apples"]]]],[52,101,null,413138441682319,false],[-1,71,null,237938440750123,false,[[4,52],[5,[2,"Game"]],[0,[20,52,30,false,null]],[0,[20,52,31,false,null]]]],[52,77,null,793569430462705,false,[[0,[0,1]]]],[52,134,"Bullet",939740030012462,false,[[0,[4,[0,270],[6,[0,-1],[19,102,[[0,30]]]]]]]],[52,138,"Bullet",885651185468619,false,[[0,[19,102,[[0,800],[0,1500]]]]]],[52,133,"Bullet",249257617166241,false,[[3,1]]],[-1,71,null,889504226565222,false,[[4,52],[5,[2,"Game"]],[0,[20,52,30,false,null]],[0,[20,52,31,false,null]]]],[52,77,null,334816839033216,false,[[0,[0,1]]]],[52,134,"Bullet",962341998599797,false,[[0,[4,[0,270],[6,[0,1],[19,102,[[0,30]]]]]]]],[52,138,"Bullet",906259904781552,false,[[0,[19,102,[[0,800],[0,1500]]]]]],[52,133,"Bullet",254488308592578,false,[[3,1]]]]]]],[0,null,false,null,931377088469170,[[52,108,null,0,false,false,false,781983577207974,false,[[8,0],[0,[0,1]]]]],[[52,82,null,801073078509009,false]],[[0,null,false,null,172363361842457,[[52,139,null,0,false,false,false,756103985176300,false]],[[52,101,null,804901394570935,false]]]]]]],[0,null,false,null,104184589596097,[[-1,21,null,1,false,false,false,530638669782741,false]],[[-1,40,null,358168741353162,false,[[11,"isSaved"],[7,[0,0]]]],[53,60,null,328310928607030,false,[[10,0],[7,[23,"Menu_LOGO"]]]]]],[0,null,false,null,666153290278275,[[32,111,null,1,false,false,false,888367622100744,false,[[4,68]]],[60,112,null,0,false,true,false,455888688109603,false],[-1,56,null,0,false,false,false,271457037371053,false,[[11,"isPaused"],[8,0],[7,[0,0]]]],[68,57,null,0,false,false,false,692599481106386,false],[-1,45,null,0,false,false,false,553971716956565,false,[[5,[2,"Lose"]]]]],[],[[0,null,false,null,569880951779421,[],[[-1,34,null,880875501821772,false,[[0,[1,0.2]]]],[60,113,null,499767321252393,false,[[1,[23,"LEADERBOARD_NAME"]],[1,[2,"alltime"]],[0,[0,1]]]]]]]]]],["Loading",[[1,"isLoaded",0,0,false,false,838500970530333,false],[2,"Adsense",false],[2,"y8Api",false],[2,"y8Logo",false],[2,"Blacklist",false],[0,null,false,null,661342745689388,[[-1,21,null,1,false,false,false,256665012946556,false]],[[53,60,null,643308332171141,false,[[10,0],[7,[23,"PreLoader_LOGO"]]]]]],[0,null,false,null,413939393037736,[[-1,94,null,0,false,false,false,822585020162812,false],[-1,56,null,0,false,false,false,976582747535896,false,[[11,"isLoaded"],[8,0],[7,[0,0]]]]],[[54,143,null,143172646478308,false,[[7,[10,[10,[2,"Loading "],[19,144,[[6,[19,145],[0,100]]]]],[2," %"]]]]]]],[0,null,false,null,679273519795618,[[-1,146,null,1,false,false,false,584524937636841,false]],[[-1,40,null,271752563963199,false,[[11,"isLoaded"],[7,[0,1]]]],[53,60,null,708845483714207,false,[[10,0],[7,[23,"Menu_LOGO"]]]],[54,143,null,672656142824513,false,[[7,[2,"Tap to start"]]]]]],[0,null,false,null,869520103327452,[[32,147,null,1,false,false,false,122385294625776,false],[-1,56,null,0,false,false,false,205337320891201,false,[[11,"isLoaded"],[8,0],[7,[0,1]]]],[32,42,null,0,false,true,false,615919433384542,false,[[4,53]]]],[[-1,46,null,827538149891647,false,[[6,"saveWindows"]]]]]]],["Blacklist",[[0,null,false,null,324122741631151,[[-1,94,null,0,false,false,false,334072277477056,false],[60,148,null,0,false,false,false,231856887463431,false]],[[-1,46,null,836791728927069,false,[[6,"Blacklist"]]],[56,149,null,325159233246914,false,[[7,[10,[2,"http://www.y8.com/games/"],[23,"game_name"]]]]]],[[0,null,false,null,909401254543457,[[61,150,null,1,false,false,false,794088829439109,false,[[3,0],[3,0]]]],[[38,69,null,666193202065036,false,[[1,[10,[2,"http://www.y8.com/games/"],[23,"game_name"]]],[1,[2,"NewWindow"]]]]]]]]]],["Adsense",[[1,"totalSecs",0,120,false,false,371209135271073,false],[1,"adsTimer",0,120,false,false,522338149854120,false],[1,"isPaused",0,0,false,false,135636863706551,false],[1,"isShowAd",0,0,false,false,262255686411950,false],[1,"isAdfinished",0,0,false,false,249412046970854,false],[1,"isShowingBlockMessage",0,0,false,false,212104729848413,false],[1,"bool",0,0,false,false,770857704004567,false],[1,"mesBox_x",0,366,false,false,901304600104894,false],[1,"mesBox_y",0,661,false,false,344384881262936,false],[0,null,false,null,666295448574399,[[33,36,null,2,false,false,false,590903093727229,false,[[1,[2,"showAds"]]]]],[[38,37,null,751628603163654,false,[[3,0],[7,[10,[10,[10,[2,"showAds "],[23,"adsTimer"]],[2," Array "]],[20,58,26,false,null,[[0,5]]]]]]]],[[0,null,false,null,225914740551850,[[58,151,null,0,false,false,false,126138611343163,false,[[0,[0,7]],[8,3],[7,[0,0]]]],[-1,56,null,0,false,false,false,818633204430355,false,[[11,"isShowAd"],[8,0],[7,[0,0]]]]],[[59,152,null,733562526846023,false,[[1,[2,"showNextAd()"]]]],[58,153,null,252999057098602,false,[[0,[0,8]],[7,[0,1]]]],[-1,40,null,940531636942712,false,[[11,"isShowAd"],[7,[0,1]]]]]]]],[0,null,false,null,364373561485482,[[33,36,null,2,false,false,false,105873124942603,false,[[1,[2,"hideAds"]]]]],[],[[0,null,false,null,396861710893932,[[58,151,null,0,false,false,false,953114943245438,false,[[0,[0,8]],[8,0],[7,[0,1]]]]],[[58,153,null,625710831689866,false,[[0,[0,8]],[7,[0,0]]]],[58,153,null,747860066858098,false,[[0,[0,7]],[7,[23,"adsTimer"]]]]]],[0,null,false,null,216035757210469,[[58,151,null,0,false,false,false,927217332525019,false,[[0,[0,5]],[8,0],[7,[0,1]]]]],[[35,154,null,466968517489843,false,[[3,1]]],[58,153,null,110120862948523,false,[[0,[0,5]],[7,[0,0]]]]]]]],[0,null,false,null,147304712018435,[[-1,155,null,0,false,false,false,285903234818435,false,[[0,[1,1]]]]],[[58,153,null,433677720816861,false,[[0,[0,7]],[7,[5,[20,58,26,false,null,[[0,7]]],[0,1]]]]]]],[0,null,false,null,584624002410191,[[-1,94,null,0,false,false,false,672715648728816,false],[-1,56,null,0,false,false,false,132313998427471,false,[[11,"isShowAd"],[8,0],[7,[0,1]]]]],[[-1,40,null,796519120504743,false,[[11,"isAdfinished"],[7,[20,38,156,false,null,[[2,"getVal()"]]]]]]],[[0,null,false,null,909640628513969,[[-1,56,null,0,false,false,false,243118790211288,false,[[11,"isAdfinished"],[8,0],[7,[0,0]]]]],[[-1,40,null,853579127316479,false,[[11,"isShowingBlockMessage"],[7,[0,0]]]]]],[0,null,false,null,940737684647617,[[-1,56,null,0,false,false,false,753613155246106,false,[[11,"isAdfinished"],[8,0],[7,[0,4]]]],[-1,56,null,0,false,false,false,799244814523169,false,[[11,"bool"],[8,0],[7,[0,0]]]]],[[-1,40,null,852949776473368,false,[[11,"isPaused"],[7,[0,1]]]],[-1,71,null,787645439174390,false,[[4,57],[5,[2,"GoogleAdsBG"]],[0,[23,"mesBox_x"]],[0,[23,"mesBox_y"]]]],[57,77,null,692782695398496,false,[[0,[0,1]]]],[-1,40,null,668987520406478,false,[[11,"bool"],[7,[0,1]]]]]],[0,null,false,null,972259037393034,[[-1,56,null,0,false,false,false,291002980080955,false,[[11,"isAdfinished"],[8,0],[7,[0,2]]]]],[[-1,40,null,641754294175019,false,[[11,"isPaused"],[7,[0,0]]]],[-1,40,null,137864800823299,false,[[11,"isShowingBlockMessage"],[7,[0,0]]]],[57,101,null,868259520302139,false],[33,55,null,109401231279499,false,[[1,[2,"hideAds"]],[13]]],[-1,40,null,742175128670697,false,[[11,"isShowAd"],[7,[0,0]]]]]],[0,null,false,null,231147774631800,[[-1,56,null,0,false,false,false,894476363447470,false,[[11,"isAdfinished"],[8,0],[7,[0,1]]]]],[[-1,40,null,724815316610193,false,[[11,"isPaused"],[7,[0,1]]]],[-1,40,null,632671499188566,false,[[11,"isShowingBlockMessage"],[7,[0,0]]]],[57,101,null,205620470181336,false],[-1,40,null,157200618419522,false,[[11,"bool"],[7,[0,0]]]]],[[0,null,false,null,658596498074916,[[35,157,null,0,false,true,false,332924286390355,false]],[[35,154,null,299493874054865,false,[[3,0]]],[58,153,null,102351621219339,false,[[0,[0,5]],[7,[0,1]]]]]]]],[0,null,false,null,919411742404038,[[-1,56,null,0,false,false,false,248743677533835,false,[[11,"isAdfinished"],[8,0],[7,[0,3]]]],[-1,56,null,0,false,false,false,171610813961715,false,[[11,"isShowingBlockMessage"],[8,0],[7,[0,0]]]]],[[-1,40,null,773276204318813,false,[[11,"isPaused"],[7,[0,0]]]],[-1,40,null,303082738639388,false,[[11,"isShowAd"],[7,[0,0]]]],[33,55,null,706101494027694,false,[[1,[2,"showBlock"]],[13]]]]]]],[0,null,false,null,442463770560938,[[33,36,null,2,false,false,false,825972322678926,false,[[1,[2,"showBlock"]]]]],[[57,101,null,155475433571092,false],[38,37,null,978671424324135,false,[[3,0],[7,[2,"showMessage"]]]],[-1,40,null,745187392589213,false,[[11,"isShowingBlockMessage"],[7,[0,1]]]],[-1,71,null,639535046763135,false,[[4,57],[5,[2,"GoogleAdsBG"]],[0,[23,"mesBox_x"]],[0,[23,"mesBox_y"]]]],[57,77,null,590424936344825,false,[[0,[0,0]]]],[57,158,null,251401696223265,false]]],[0,null,false,null,644392164011848,[[32,111,null,1,false,false,false,955322478906081,false,[[4,57]]]],[[57,101,null,178389695672624,false]]]]],["y8Api",[[1,"score2",0,0,false,false,926902030206850,false],[1,"game_name",1,"knife_hit_y8",false,false,476248922224195,false],[1,"LayName",1,"",false,false,556140539145853,false],[1,"ID_APP",1,"5cdfa11de694aab3514b6c7d",false,true,944041642044061,false],[1,"LEADERBOARD_NAME",1,"Leaderboard",false,true,332612279514213,false],[1,"ISTUTORIAL",0,0,false,false,159860316420633,false],[1,"isScoreSaved",0,0,false,false,647330206442677,false],[1,"isStarting",0,0,false,false,752824403829860,false],[1,"isLocal",0,0,false,false,878149743608235,false],[1,"isOnline",0,0,false,false,447605702652791,false],[1,"isNotLogin",0,0,false,false,465801861538036,false],[1,"oneTIme",0,0,false,false,768708512032157,false],[1,"isOneTime",0,0,false,false,510511050559818,false],[0,null,false,null,370628323263851,[[-1,21,null,1,false,false,false,351052905679395,false]],[],[[0,null,false,null,963251616433883,[[60,159,null,0,false,false,false,341115124799461,false]],[[60,160,null,864088018625924,false,[[1,[23,"ID_APP"]]]]]]]]]],["y8Logo",[[1,"Menu_LOGO",1,"g_menulogo",false,false,241966381042886,false],[1,"PreLoader_LOGO",1,"g_prelogo",false,false,971255208553164,false],[0,null,false,null,548199630972857,[[32,161,null,1,false,false,false,780088152893537,false,[[4,53]]],[60,162,null,0,false,true,false,188833443213927,false],[53,57,null,0,false,false,false,581230381093641,false],[-1,45,null,0,false,true,false,911706752894147,false,[[5,[2,"KnivesList"]]]],[-1,45,null,0,false,true,false,655869310417531,false,[[5,[2,"Settings"]]]],[-1,45,null,0,false,true,false,375544404596917,false,[[5,[2,"Apples"]]]]],[[38,163,null,871505501420322,false],[38,69,null,272841651056855,false,[[1,[10,[10,[10,[10,[10,[2,"http://www.y8.com/?utm_source="],[20,38,164,true,null]],[2,"&utm_medium="]],[21,53,true,null,0]],[2,"&utm_campaign="]],[23,"game_name"]]],[1,[2,"NewWindow"]]]]]],[0,null,false,null,683197258241175,[[61,165,null,0,false,false,false,593517950398341,false,[[4,53]]],[60,162,null,0,false,true,false,152862642262047,false],[53,57,null,0,false,false,false,881530803771211,false],[-1,45,null,0,false,true,false,145284128570728,false,[[5,[2,"KnivesList"]]]],[-1,45,null,0,false,true,false,579080292892211,false,[[5,[2,"Settings"]]]],[-1,45,null,0,false,true,false,605886093193594,false,[[5,[2,"Apples"]]]]],[[61,166,null,992534612514009,false,[[3,1]]]]],[0,null,false,null,836290021915953,[[61,165,null,0,false,true,false,198448896423324,false,[[4,53]]],[53,57,null,0,false,false,false,216735979332902,false],[-1,45,null,0,false,true,false,762409176827793,false,[[5,[2,"KnivesList"]]]],[-1,45,null,0,false,true,false,529058520571033,false,[[5,[2,"Settings"]]]],[-1,45,null,0,false,true,false,352698637846452,false,[[5,[2,"Apples"]]]]],[[61,166,null,465442148422726,false,[[3,0]]]]]]],["saveWindows",[[2,"saveData",false],[1,"isOnlineGameLoading",0,0,false,false,109820940476671,false],[0,[true,"y8Menu"],false,null,107493086078861,[[-1,20,null,0,false,false,false,107493086078861,false,[[1,[2,"y8Menu"]]]]],[],[[2,"y8Logo",false],[2,"Blacklist",false],[2,"Adsense",false],[0,null,false,null,163446838572629,[[-1,21,null,1,false,false,false,737874673839258,false]],[[53,60,null,641149583234006,false,[[10,0],[7,[23,"Menu_LOGO"]]]],[54,167,null,583384791171634,false,[[3,0]]],[-1,47,null,396871198931171,false,[[5,[2,"Menu"]],[3,1]]],[-1,47,null,786071878412682,false,[[5,[2,"Layer 1"]],[3,1]]],[-1,40,null,779039229945065,false,[[11,"isOnlineGameLoading"],[7,[0,0]]]],[-1,40,null,352085759279384,false,[[11,"isOneTime"],[7,[0,0]]]],[33,55,null,496673047739130,false,[[1,[2,"showAds"]],[13]]]]],[0,null,false,null,611378029389697,[[60,162,null,0,false,false,false,599911306013368,false]],[]],[0,null,false,null,741666243932209,[[60,168,null,0,false,false,false,229218775820571,false]],[[62,77,null,626567151273583,false,[[0,[0,0]]]],[66,143,null,836480351095101,false,[[7,[2,""]]]],[64,120,null,623025513643461,false,[[1,[2,"Login"]],[3,1]]],[64,77,null,968504628873964,false,[[0,[0,1]]]]]],[0,null,false,null,618815725280368,[[60,169,null,0,false,false,false,200895824055022,false],[60,170,null,0,false,false,false,247707975798448,false]],[[64,120,null,262665406464504,false,[[1,[2,"Play"]],[3,1]]],[64,77,null,223414764797105,false,[[0,[0,1]]]],[62,77,null,100696806780982,false,[[0,[0,1]]]],[66,143,null,122028038114304,false,[[7,[20,60,171,true,null]]]]]],[0,null,false,null,840651452971329,[[32,111,null,1,false,false,false,446487235543371,false,[[4,65]]],[-1,45,null,0,false,false,false,513626961043783,false,[[5,[2,"saveWindows"]]]],[-1,56,null,0,false,false,false,668384391582342,false,[[11,"isPaused"],[8,0],[7,[0,0]]]]],[[-1,40,null,724981231649794,false,[[11,"isLocal"],[7,[0,1]]]],[-1,40,null,873639330618275,false,[[11,"isOnline"],[7,[0,0]]]],[58,153,null,546194563500716,false,[[0,[0,0]],[7,[23,"isLocal"]]]],[58,153,null,763547568872150,false,[[0,[0,1]],[7,[23,"isOnline"]]]],[-1,47,null,945741468983172,false,[[5,[2,"saveWindows"]],[3,0]]],[34,70,null,245533701637899,false,[[1,[2,"saveGame"]]]]]],[0,null,false,null,765579466183839,[[32,111,null,1,false,false,false,605521731729335,false,[[4,64]]],[-1,45,null,0,false,false,false,309610699593131,false,[[5,[2,"saveWindows"]]]],[-1,56,null,0,false,false,false,931296276120292,false,[[11,"isPaused"],[8,0],[7,[0,0]]]]],[],[[0,null,false,null,319106092009913,[[60,169,null,0,false,false,false,166189934579406,false]],[[-1,40,null,776940142568676,false,[[11,"isOnlineGameLoading"],[7,[0,1]]]],[-1,47,null,887805839201008,false,[[5,[2,"saveWindows"]],[3,0]]],[54,167,null,530352564583202,false,[[3,1]]],[-1,34,null,309387020463799,false,[[0,[0,2]]]],[60,172,null,191838542779779,false,[[1,[2,"saveGame"]]]],[38,37,null,498467431385457,false,[[3,0],[7,[20,60,173,true,null]]]]]],[0,null,false,null,752079231295782,[[60,168,null,0,false,false,false,773966802486678,false]],[[60,174,null,451595412296165,false]]]]]]],[0,null,false,null,797401693147414,[[60,175,null,0,false,false,false,673717926078286,false]],[[54,167,null,254563744424804,false,[[3,0]]],[67,176,null,420693493453030,false,[[1,[20,60,173,true,null]]]],[33,55,null,451594275075149,false,[[1,[2,"loadFunc"]],[13]]],[-1,40,null,587722165184753,false,[[11,"isLocal"],[7,[0,0]]]],[-1,40,null,332390918987737,false,[[11,"isOnline"],[7,[0,1]]]],[58,153,null,403067307167069,false,[[0,[0,0]],[7,[23,"isLocal"]]]],[58,153,null,815229435941020,false,[[0,[0,1]],[7,[23,"isOnline"]]]],[-1,46,null,604545883726887,false,[[6,"Menu"]]]]],[0,null,false,null,801836351852563,[[32,111,null,1,false,false,false,465567809437646,false,[[4,68]]],[60,112,null,0,false,true,false,734870294942538,false],[-1,56,null,0,false,false,false,176908022670248,false,[[11,"isPaused"],[8,0],[7,[0,0]]]],[68,57,null,0,false,false,false,988216990183736,false]],[],[[0,null,false,null,893855562157249,[],[[-1,34,null,434796737682181,false,[[0,[1,0.2]]]],[60,113,null,448237160427089,false,[[1,[23,"LEADERBOARD_NAME"]],[1,[2,"alltime"]],[0,[0,1]]]]]]]],[0,null,false,null,627219465529795,[[34,177,null,1,false,false,false,720252015661056,false,[[1,[2,"saveGame"]]]]],[[38,37,null,890918643927963,false,[[3,0],[7,[2,"saveGame Exists"]]]],[67,176,null,323920251215637,false,[[1,[20,34,178,false,null]]]],[33,55,null,555576526146139,false,[[1,[2,"loadFunc"]],[13]]],[-1,40,null,475972279992676,false,[[11,"isOneTime"],[7,[0,0]]]],[54,167,null,218861368067018,false,[[3,1]]],[-1,34,null,964050359031852,false,[[0,[1,0.5]]]],[-1,46,null,555691379259724,false,[[6,"Menu"]]]]],[0,null,false,null,565877785512063,[[34,179,null,1,false,false,false,314240469095895,false,[[1,[2,"saveGame"]]]]],[[38,37,null,687521373291196,false,[[3,0],[7,[2,"saveGame Missing"]]]],[-1,40,null,348664830912630,false,[[11,"isOneTime"],[7,[0,0]]]],[33,55,null,663841440662169,false,[[1,[2,"loadFunc"]],[13]]],[54,167,null,239631726086081,false,[[3,1]]],[-1,34,null,978025935922994,false,[[0,[1,0.5]]]],[-1,46,null,197720377189346,false,[[6,"Menu"]]]]],[0,null,false,null,702688505301960,[[61,165,null,0,false,false,false,837259327599680,false,[[4,65]]]],[[65,77,null,526313172768789,false,[[0,[0,0]]]]]],[0,null,false,null,855986587589436,[[61,165,null,0,false,true,false,748767446762335,false,[[4,65]]]],[[65,77,null,338611913678597,false,[[0,[0,1]]]]]],[0,null,false,null,146412172281829,[[61,165,null,0,false,false,false,662832572263187,false,[[4,64]]]],[[64,77,null,562835105663806,false,[[0,[0,0]]]]]],[0,null,false,null,559791144575072,[[61,165,null,0,false,true,false,405239912632995,false,[[4,64]]]],[[64,77,null,515979555863897,false,[[0,[0,1]]]]]]]],["saveData",[[2,"Adsense",false],[0,null,false,null,305956564595251,[[33,36,null,2,false,false,false,645164878612397,false,[[1,[2,"saveData"]]]]],[[38,37,null,787481693043415,false,[[3,0],[7,[2,"Save User Data"]]]],[33,55,null,350709654421861,false,[[1,[2,"showAds"]],[13]]],[-1,40,null,250197222254666,false,[[11,"isLocal"],[7,[20,58,26,false,null,[[0,0]]]]]],[-1,40,null,835590107369593,false,[[11,"isOnline"],[7,[20,58,26,false,null,[[0,1]]]]]]],[[0,null,false,null,786720684878680,[[-1,56,null,0,false,false,false,697096350359475,false,[[11,"isLocal"],[8,0],[7,[0,1]]]]],[[38,37,null,628939445363281,false,[[3,0],[7,[10,[2,"Dict"],[20,67,64,false,null,[[2,"gemFlight"]]]]]]],[34,180,null,207241470239120,false,[[1,[2,"saveGame"]],[7,[20,67,181,true,null]]]]]],[0,null,false,null,456977349120526,[[-1,56,null,0,false,false,false,923038611553831,false,[[11,"isOnline"],[8,0],[7,[0,1]]]]],[[60,182,null,144833156001386,false,[[1,[2,"saveGame"]],[1,[20,67,181,true,null]]]],[33,55,null,809989603244460,false,[[1,[2,"submitScore"]],[13]]]]]]],[0,null,false,null,998876807480116,[[33,36,null,2,false,false,false,307489547997450,false,[[1,[2,"clearData"]]]]],[[-1,40,null,523317312145520,false,[[11,"isLocal"],[7,[20,58,26,false,null,[[0,0]]]]]],[-1,40,null,624079654256247,false,[[11,"isOnline"],[7,[20,58,26,false,null,[[0,1]]]]]]],[[0,null,false,null,284745072219947,[[-1,56,null,0,false,false,false,406141269957250,false,[[11,"isLocal"],[8,0],[7,[0,1]]]]],[[34,183,null,707741820435234,false]]],[0,null,false,null,859431086395494,[[-1,56,null,0,false,false,false,691350133648380,false,[[11,"isOnline"],[8,0],[7,[0,1]]]]],[[60,184,null,587938279192563,false,[[1,[2,"saveGame"]]]]]],[0,null,false,null,734054255642847,[],[[67,185,null,891785828921695,false],[-1,40,null,865512354127424,false,[[11,"BestScore"],[7,[0,0]]]],[-1,40,null,864721355578623,false,[[11,"BestStage"],[7,[0,0]]]],[-1,40,null,141450557575393,false,[[11,"Apples"],[7,[0,0]]]],[-1,40,null,582562392391993,false,[[11,"SelectedKnife"],[7,[0,0]]]],[-1,40,null,313732446828053,false,[[11,"UnlockedKnives"],[7,[2,""]]]]]]]],[0,null,false,null,562442803175326,[[33,36,null,2,false,false,false,352666434373554,false,[[1,[2,"submitScore"]]]]],[[60,186,null,750402646160423,false,[[0,[23,"Score"]],[1,[2,"Leaderboard"]],[0,[0,0]],[0,[0,1]],[1,[2,""]]]]]],[0,null,false,null,658178315210288,[[33,36,null,2,false,false,false,732135420421088,false,[[1,[2,"loadFunc"]]]]],[[38,37,null,165644311996735,false,[[3,0],[7,[2,"LoadFunc"]]]]],[[0,null,false,null,335258159742685,[[67,63,null,0,false,false,false,859455687345021,false,[[1,[2,"KnifeHit-BestScore"]]]]],[[-1,40,null,582243727422730,false,[[11,"BestScore"],[7,[20,67,64,false,null,[[2,"KnifeHit-BestScore"]]]]]]]],[0,null,false,null,467208395426334,[[67,63,null,0,false,true,false,472599873310711,false,[[1,[2,"KnifeHit-BestScore"]]]]],[[-1,40,null,809487446331036,false,[[11,"BestScore"],[7,[0,0]]]]]],[0,null,false,null,432670655800060,[[67,63,null,0,false,false,false,247183618761484,false,[[1,[2,"KnifeHit-BestStage"]]]]],[[-1,40,null,449121569887412,false,[[11,"BestStage"],[7,[20,67,64,false,null,[[2,"KnifeHit-BestStage"]]]]]]]],[0,null,false,null,523114409260175,[[67,63,null,0,false,true,false,149877580127972,false,[[1,[2,"KnifeHit-BestStage"]]]]],[[-1,40,null,179910557858306,false,[[11,"BestStage"],[7,[0,0]]]]]],[0,null,false,null,248750393669027,[[67,63,null,0,false,false,false,352006993160456,false,[[1,[2,"KnifeHit-Apples"]]]]],[[-1,40,null,714433093409171,false,[[11,"Apples"],[7,[20,67,64,false,null,[[2,"KnifeHit-Apples"]]]]]]]],[0,null,false,null,111724636083565,[[67,63,null,0,false,true,false,516869127175911,false,[[1,[2,"KnifeHit-Apples"]]]]],[[-1,40,null,257963525715481,false,[[11,"Apples"],[7,[0,0]]]]]],[0,null,false,null,249127963580788,[[67,63,null,0,false,false,false,376369280815767,false,[[1,[2,"KnifeHit-SelectedKnife"]]]]],[[-1,40,null,779175056468676,false,[[11,"SelectedKnife"],[7,[20,67,64,false,null,[[2,"KnifeHit-SelectedKnife"]]]]]]]],[0,null,false,null,127683281109315,[[67,63,null,0,false,true,false,413337519173552,false,[[1,[2,"KnifeHit-SelectedKnife"]]]]],[[-1,40,null,924758527172542,false,[[11,"SelectedKnife"],[7,[0,0]]]]]],[0,null,false,null,401132123237674,[[67,63,null,0,false,false,false,411532927685664,false,[[1,[2,"KnifeHit-UnlockedKnives"]]]]],[[-1,40,null,838043670309376,false,[[11,"UnlockedKnives"],[7,[20,67,64,false,null,[[2,"KnifeHit-UnlockedKnives"]]]]]]]],[0,null,false,null,714014882470277,[[67,63,null,0,false,true,false,813744692070564,false,[[1,[2,"KnifeHit-UnlockedKnives"]]]]],[[-1,40,null,722781360667899,false,[[11,"UnlockedKnives"],[7,[2,""]]]]]]]]]]],[["block.m4a",19645],["block.ogg",17719],["break.m4a",15445],["break.ogg",16559],["hit.m4a",12851],["hit.ogg",12030],["new.m4a",11601],["new.ogg",7653]],"media/",false,720,1280,3,true,true,true,"1.0.1",true,true,3,1,104,false,true,1,true,"DD Knife Hit",0,[]]} \ No newline at end of file diff --git a/games/knifehit/icon-256.png b/games/knifehit/icon-256.png new file mode 100644 index 00000000..ff4fcb8f Binary files /dev/null and b/games/knifehit/icon-256.png differ diff --git a/games/knifehit/images/apple-sheet0.png b/games/knifehit/images/apple-sheet0.png new file mode 100644 index 00000000..d5448e40 Binary files /dev/null and b/games/knifehit/images/apple-sheet0.png differ diff --git a/games/knifehit/images/apple2-sheet0.png b/games/knifehit/images/apple2-sheet0.png new file mode 100644 index 00000000..0ed28194 Binary files /dev/null and b/games/knifehit/images/apple2-sheet0.png differ diff --git a/games/knifehit/images/background-sheet0.png b/games/knifehit/images/background-sheet0.png new file mode 100644 index 00000000..b2f4293f Binary files /dev/null and b/games/knifehit/images/background-sheet0.png differ diff --git a/games/knifehit/images/broken-sheet0.png b/games/knifehit/images/broken-sheet0.png new file mode 100644 index 00000000..20127b0d Binary files /dev/null and b/games/knifehit/images/broken-sheet0.png differ diff --git a/games/knifehit/images/btncleardata-sheet0.png b/games/knifehit/images/btncleardata-sheet0.png new file mode 100644 index 00000000..ab90ca43 Binary files /dev/null and b/games/knifehit/images/btncleardata-sheet0.png differ diff --git a/games/knifehit/images/btnclose-sheet0.png b/games/knifehit/images/btnclose-sheet0.png new file mode 100644 index 00000000..06fca8dd Binary files /dev/null and b/games/knifehit/images/btnclose-sheet0.png differ diff --git a/games/knifehit/images/btnequip-sheet0.png b/games/knifehit/images/btnequip-sheet0.png new file mode 100644 index 00000000..97c99754 Binary files /dev/null and b/games/knifehit/images/btnequip-sheet0.png differ diff --git a/games/knifehit/images/btnequip2-sheet0.png b/games/knifehit/images/btnequip2-sheet0.png new file mode 100644 index 00000000..97628217 Binary files /dev/null and b/games/knifehit/images/btnequip2-sheet0.png differ diff --git a/games/knifehit/images/btnfb-sheet0.png b/games/knifehit/images/btnfb-sheet0.png new file mode 100644 index 00000000..9cf1f1d7 Binary files /dev/null and b/games/knifehit/images/btnfb-sheet0.png differ diff --git a/games/knifehit/images/btnfbgift-sheet0.png b/games/knifehit/images/btnfbgift-sheet0.png new file mode 100644 index 00000000..0142498a Binary files /dev/null and b/games/knifehit/images/btnfbgift-sheet0.png differ diff --git a/games/knifehit/images/btngift-sheet0.png b/games/knifehit/images/btngift-sheet0.png new file mode 100644 index 00000000..7bd0ae8b Binary files /dev/null and b/games/knifehit/images/btngift-sheet0.png differ diff --git a/games/knifehit/images/btnhome-sheet0.png b/games/knifehit/images/btnhome-sheet0.png new file mode 100644 index 00000000..0fdacaaa Binary files /dev/null and b/games/knifehit/images/btnhome-sheet0.png differ diff --git a/games/knifehit/images/btninstagift-sheet0.png b/games/knifehit/images/btninstagift-sheet0.png new file mode 100644 index 00000000..222cc1c9 Binary files /dev/null and b/games/knifehit/images/btninstagift-sheet0.png differ diff --git a/games/knifehit/images/btnknife-sheet0.png b/games/knifehit/images/btnknife-sheet0.png new file mode 100644 index 00000000..cb41c329 Binary files /dev/null and b/games/knifehit/images/btnknife-sheet0.png differ diff --git a/games/knifehit/images/btnplay-sheet0.png b/games/knifehit/images/btnplay-sheet0.png new file mode 100644 index 00000000..69d8c549 Binary files /dev/null and b/games/knifehit/images/btnplay-sheet0.png differ diff --git a/games/knifehit/images/btnrestart-sheet0.png b/games/knifehit/images/btnrestart-sheet0.png new file mode 100644 index 00000000..f47c1fcb Binary files /dev/null and b/games/knifehit/images/btnrestart-sheet0.png differ diff --git a/games/knifehit/images/btnsetting-sheet0.png b/games/knifehit/images/btnsetting-sheet0.png new file mode 100644 index 00000000..81aef073 Binary files /dev/null and b/games/knifehit/images/btnsetting-sheet0.png differ diff --git a/games/knifehit/images/btnsettings-sheet0.png b/games/knifehit/images/btnsettings-sheet0.png new file mode 100644 index 00000000..24128769 Binary files /dev/null and b/games/knifehit/images/btnsettings-sheet0.png differ diff --git a/games/knifehit/images/btnsound-sheet0.png b/games/knifehit/images/btnsound-sheet0.png new file mode 100644 index 00000000..35d3cc55 Binary files /dev/null and b/games/knifehit/images/btnsound-sheet0.png differ diff --git a/games/knifehit/images/btnstar-sheet0.png b/games/knifehit/images/btnstar-sheet0.png new file mode 100644 index 00000000..bd84f6d9 Binary files /dev/null and b/games/knifehit/images/btnstar-sheet0.png differ diff --git a/games/knifehit/images/circle-sheet0.png b/games/knifehit/images/circle-sheet0.png new file mode 100644 index 00000000..8535a5b7 Binary files /dev/null and b/games/knifehit/images/circle-sheet0.png differ diff --git a/games/knifehit/images/circle-sheet1.png b/games/knifehit/images/circle-sheet1.png new file mode 100644 index 00000000..8ff32e82 Binary files /dev/null and b/games/knifehit/images/circle-sheet1.png differ diff --git a/games/knifehit/images/circle-sheet2.png b/games/knifehit/images/circle-sheet2.png new file mode 100644 index 00000000..94be2f44 Binary files /dev/null and b/games/knifehit/images/circle-sheet2.png differ diff --git a/games/knifehit/images/detector-sheet0.png b/games/knifehit/images/detector-sheet0.png new file mode 100644 index 00000000..a5c93fc8 Binary files /dev/null and b/games/knifehit/images/detector-sheet0.png differ diff --git a/games/knifehit/images/dot-sheet0.png b/games/knifehit/images/dot-sheet0.png new file mode 100644 index 00000000..6c3e2c41 Binary files /dev/null and b/games/knifehit/images/dot-sheet0.png differ diff --git a/games/knifehit/images/dot-sheet1.png b/games/knifehit/images/dot-sheet1.png new file mode 100644 index 00000000..a2672d76 Binary files /dev/null and b/games/knifehit/images/dot-sheet1.png differ diff --git a/games/knifehit/images/equipbox-sheet0.png b/games/knifehit/images/equipbox-sheet0.png new file mode 100644 index 00000000..382dfe4e Binary files /dev/null and b/games/knifehit/images/equipbox-sheet0.png differ diff --git a/games/knifehit/images/knife-sheet0.png b/games/knifehit/images/knife-sheet0.png new file mode 100644 index 00000000..0c0aa5c8 Binary files /dev/null and b/games/knifehit/images/knife-sheet0.png differ diff --git a/games/knifehit/images/knife-sheet1.png b/games/knifehit/images/knife-sheet1.png new file mode 100644 index 00000000..bc6887fc Binary files /dev/null and b/games/knifehit/images/knife-sheet1.png differ diff --git a/games/knifehit/images/knife-sheet2.png b/games/knifehit/images/knife-sheet2.png new file mode 100644 index 00000000..f96ed853 Binary files /dev/null and b/games/knifehit/images/knife-sheet2.png differ diff --git a/games/knifehit/images/knifeback-sheet0.png b/games/knifehit/images/knifeback-sheet0.png new file mode 100644 index 00000000..f3b355dd Binary files /dev/null and b/games/knifehit/images/knifeback-sheet0.png differ diff --git a/games/knifehit/images/knifeborder-sheet0.png b/games/knifehit/images/knifeborder-sheet0.png new file mode 100644 index 00000000..6263e248 Binary files /dev/null and b/games/knifehit/images/knifeborder-sheet0.png differ diff --git a/games/knifehit/images/knifeborder-sheet1.png b/games/knifehit/images/knifeborder-sheet1.png new file mode 100644 index 00000000..e229c5d6 Binary files /dev/null and b/games/knifehit/images/knifeborder-sheet1.png differ diff --git a/games/knifehit/images/leaderboard-sheet0.png b/games/knifehit/images/leaderboard-sheet0.png new file mode 100644 index 00000000..9696d38c Binary files /dev/null and b/games/knifehit/images/leaderboard-sheet0.png differ diff --git a/games/knifehit/images/leaderboard2-sheet0.png b/games/knifehit/images/leaderboard2-sheet0.png new file mode 100644 index 00000000..179b26da Binary files /dev/null and b/games/knifehit/images/leaderboard2-sheet0.png differ diff --git a/games/knifehit/images/loading_font.png b/games/knifehit/images/loading_font.png new file mode 100644 index 00000000..3a03db06 Binary files /dev/null and b/games/knifehit/images/loading_font.png differ diff --git a/games/knifehit/images/loadinggamelogo-sheet0.png b/games/knifehit/images/loadinggamelogo-sheet0.png new file mode 100644 index 00000000..616af01c Binary files /dev/null and b/games/knifehit/images/loadinggamelogo-sheet0.png differ diff --git a/games/knifehit/images/localsavebtn-sheet0.png b/games/knifehit/images/localsavebtn-sheet0.png new file mode 100644 index 00000000..5016da03 Binary files /dev/null and b/games/knifehit/images/localsavebtn-sheet0.png differ diff --git a/games/knifehit/images/menuapple-sheet0.png b/games/knifehit/images/menuapple-sheet0.png new file mode 100644 index 00000000..b03dd03c Binary files /dev/null and b/games/knifehit/images/menuapple-sheet0.png differ diff --git a/games/knifehit/images/menuknife-sheet0.png b/games/knifehit/images/menuknife-sheet0.png new file mode 100644 index 00000000..2355ac24 Binary files /dev/null and b/games/knifehit/images/menuknife-sheet0.png differ diff --git a/games/knifehit/images/miniknife-sheet0.png b/games/knifehit/images/miniknife-sheet0.png new file mode 100644 index 00000000..aa9a6cc4 Binary files /dev/null and b/games/knifehit/images/miniknife-sheet0.png differ diff --git a/games/knifehit/images/miniknife-sheet1.png b/games/knifehit/images/miniknife-sheet1.png new file mode 100644 index 00000000..5a9bf429 Binary files /dev/null and b/games/knifehit/images/miniknife-sheet1.png differ diff --git a/games/knifehit/images/newbest-sheet0.png b/games/knifehit/images/newbest-sheet0.png new file mode 100644 index 00000000..98330ed4 Binary files /dev/null and b/games/knifehit/images/newbest-sheet0.png differ diff --git a/games/knifehit/images/obj_y8logo-sheet0.png b/games/knifehit/images/obj_y8logo-sheet0.png new file mode 100644 index 00000000..432dcdec Binary files /dev/null and b/games/knifehit/images/obj_y8logo-sheet0.png differ diff --git a/games/knifehit/images/online-sheet0.png b/games/knifehit/images/online-sheet0.png new file mode 100644 index 00000000..7f8ee24d Binary files /dev/null and b/games/knifehit/images/online-sheet0.png differ diff --git a/games/knifehit/images/online-sheet1.png b/games/knifehit/images/online-sheet1.png new file mode 100644 index 00000000..73e8d402 Binary files /dev/null and b/games/knifehit/images/online-sheet1.png differ diff --git a/games/knifehit/images/online2-sheet0.png b/games/knifehit/images/online2-sheet0.png new file mode 100644 index 00000000..ace36b70 Binary files /dev/null and b/games/knifehit/images/online2-sheet0.png differ diff --git a/games/knifehit/images/onlinebtn-sheet0.png b/games/knifehit/images/onlinebtn-sheet0.png new file mode 100644 index 00000000..b2ce6f57 Binary files /dev/null and b/games/knifehit/images/onlinebtn-sheet0.png differ diff --git a/games/knifehit/images/onlinebtn-sheet1.png b/games/knifehit/images/onlinebtn-sheet1.png new file mode 100644 index 00000000..ca1dcf6c Binary files /dev/null and b/games/knifehit/images/onlinebtn-sheet1.png differ diff --git a/games/knifehit/images/particle-sheet0.png b/games/knifehit/images/particle-sheet0.png new file mode 100644 index 00000000..95dde269 Binary files /dev/null and b/games/knifehit/images/particle-sheet0.png differ diff --git a/games/knifehit/images/scoreback-sheet0.png b/games/knifehit/images/scoreback-sheet0.png new file mode 100644 index 00000000..5303b029 Binary files /dev/null and b/games/knifehit/images/scoreback-sheet0.png differ diff --git a/games/knifehit/images/shine-sheet0.png b/games/knifehit/images/shine-sheet0.png new file mode 100644 index 00000000..e0543c8d Binary files /dev/null and b/games/knifehit/images/shine-sheet0.png differ diff --git a/games/knifehit/images/sprite-sheet0.png b/games/knifehit/images/sprite-sheet0.png new file mode 100644 index 00000000..ee767b37 Binary files /dev/null and b/games/knifehit/images/sprite-sheet0.png differ diff --git a/games/knifehit/images/square-sheet0.png b/games/knifehit/images/square-sheet0.png new file mode 100644 index 00000000..c4b7319d Binary files /dev/null and b/games/knifehit/images/square-sheet0.png differ diff --git a/games/knifehit/images/title1-sheet0.png b/games/knifehit/images/title1-sheet0.png new file mode 100644 index 00000000..076ac6db Binary files /dev/null and b/games/knifehit/images/title1-sheet0.png differ diff --git a/games/knifehit/images/title2-sheet0.png b/games/knifehit/images/title2-sheet0.png new file mode 100644 index 00000000..3d97dea8 Binary files /dev/null and b/games/knifehit/images/title2-sheet0.png differ diff --git a/games/knifehit/images/title3-sheet0.png b/games/knifehit/images/title3-sheet0.png new file mode 100644 index 00000000..daea0445 Binary files /dev/null and b/games/knifehit/images/title3-sheet0.png differ diff --git a/games/knifehit/images/twoknives-sheet0.png b/games/knifehit/images/twoknives-sheet0.png new file mode 100644 index 00000000..70f4f3d9 Binary files /dev/null and b/games/knifehit/images/twoknives-sheet0.png differ diff --git a/games/knifehit/images/txtorange.png b/games/knifehit/images/txtorange.png new file mode 100644 index 00000000..00f42d2a Binary files /dev/null and b/games/knifehit/images/txtorange.png differ diff --git a/games/knifehit/images/txtwhite.png b/games/knifehit/images/txtwhite.png new file mode 100644 index 00000000..503461cb Binary files /dev/null and b/games/knifehit/images/txtwhite.png differ diff --git a/games/knifehit/images/txtyellow.png b/games/knifehit/images/txtyellow.png new file mode 100644 index 00000000..c40e1abc Binary files /dev/null and b/games/knifehit/images/txtyellow.png differ diff --git a/games/knifehit/images/welcomefont.png b/games/knifehit/images/welcomefont.png new file mode 100644 index 00000000..c3f88961 Binary files /dev/null and b/games/knifehit/images/welcomefont.png differ diff --git a/games/knifehit/images/y8_message-sheet0.png b/games/knifehit/images/y8_message-sheet0.png new file mode 100644 index 00000000..f859b9a9 Binary files /dev/null and b/games/knifehit/images/y8_message-sheet0.png differ diff --git a/games/knifehit/images/y8_message-sheet1.png b/games/knifehit/images/y8_message-sheet1.png new file mode 100644 index 00000000..faa51444 Binary files /dev/null and b/games/knifehit/images/y8_message-sheet1.png differ diff --git a/games/knifehit/index.html b/games/knifehit/index.html new file mode 100644 index 00000000..035c17e4 --- /dev/null +++ b/games/knifehit/index.html @@ -0,0 +1,150 @@ + + + + + + DD Knife Hit + + + + + + + + + + + + + + + + + + + + + + +
+ + + + +
+ + + + +

Your browser does not appear to support HTML5. Try upgrading your browser to the latest version. What is a browser? +

Microsoft Internet Explorer
+ Mozilla Firefox
+ Google Chrome
+ Apple Safari

+
+ +
+ + + + + + + + + + + + + +
+
+ +
+
+
+ + + + + + \ No newline at end of file diff --git a/games/knifehit/jquery-2.1.1.min.js b/games/knifehit/jquery-2.1.1.min.js new file mode 100644 index 00000000..e5ace116 --- /dev/null +++ b/games/knifehit/jquery-2.1.1.min.js @@ -0,0 +1,4 @@ +/*! jQuery v2.1.1 | (c) 2005, 2014 jQuery Foundation, Inc. | jquery.org/license */ +!function(a,b){"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof window?window:this,function(a,b){var c=[],d=c.slice,e=c.concat,f=c.push,g=c.indexOf,h={},i=h.toString,j=h.hasOwnProperty,k={},l=a.document,m="2.1.1",n=function(a,b){return new n.fn.init(a,b)},o=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,p=/^-ms-/,q=/-([\da-z])/gi,r=function(a,b){return b.toUpperCase()};n.fn=n.prototype={jquery:m,constructor:n,selector:"",length:0,toArray:function(){return d.call(this)},get:function(a){return null!=a?0>a?this[a+this.length]:this[a]:d.call(this)},pushStack:function(a){var b=n.merge(this.constructor(),a);return b.prevObject=this,b.context=this.context,b},each:function(a,b){return n.each(this,a,b)},map:function(a){return this.pushStack(n.map(this,function(b,c){return a.call(b,c,b)}))},slice:function(){return this.pushStack(d.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(a){var b=this.length,c=+a+(0>a?b:0);return this.pushStack(c>=0&&b>c?[this[c]]:[])},end:function(){return this.prevObject||this.constructor(null)},push:f,sort:c.sort,splice:c.splice},n.extend=n.fn.extend=function(){var a,b,c,d,e,f,g=arguments[0]||{},h=1,i=arguments.length,j=!1;for("boolean"==typeof g&&(j=g,g=arguments[h]||{},h++),"object"==typeof g||n.isFunction(g)||(g={}),h===i&&(g=this,h--);i>h;h++)if(null!=(a=arguments[h]))for(b in a)c=g[b],d=a[b],g!==d&&(j&&d&&(n.isPlainObject(d)||(e=n.isArray(d)))?(e?(e=!1,f=c&&n.isArray(c)?c:[]):f=c&&n.isPlainObject(c)?c:{},g[b]=n.extend(j,f,d)):void 0!==d&&(g[b]=d));return g},n.extend({expando:"jQuery"+(m+Math.random()).replace(/\D/g,""),isReady:!0,error:function(a){throw new Error(a)},noop:function(){},isFunction:function(a){return"function"===n.type(a)},isArray:Array.isArray,isWindow:function(a){return null!=a&&a===a.window},isNumeric:function(a){return!n.isArray(a)&&a-parseFloat(a)>=0},isPlainObject:function(a){return"object"!==n.type(a)||a.nodeType||n.isWindow(a)?!1:a.constructor&&!j.call(a.constructor.prototype,"isPrototypeOf")?!1:!0},isEmptyObject:function(a){var b;for(b in a)return!1;return!0},type:function(a){return null==a?a+"":"object"==typeof a||"function"==typeof a?h[i.call(a)]||"object":typeof a},globalEval:function(a){var b,c=eval;a=n.trim(a),a&&(1===a.indexOf("use strict")?(b=l.createElement("script"),b.text=a,l.head.appendChild(b).parentNode.removeChild(b)):c(a))},camelCase:function(a){return a.replace(p,"ms-").replace(q,r)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toLowerCase()===b.toLowerCase()},each:function(a,b,c){var d,e=0,f=a.length,g=s(a);if(c){if(g){for(;f>e;e++)if(d=b.apply(a[e],c),d===!1)break}else for(e in a)if(d=b.apply(a[e],c),d===!1)break}else if(g){for(;f>e;e++)if(d=b.call(a[e],e,a[e]),d===!1)break}else for(e in a)if(d=b.call(a[e],e,a[e]),d===!1)break;return a},trim:function(a){return null==a?"":(a+"").replace(o,"")},makeArray:function(a,b){var c=b||[];return null!=a&&(s(Object(a))?n.merge(c,"string"==typeof a?[a]:a):f.call(c,a)),c},inArray:function(a,b,c){return null==b?-1:g.call(b,a,c)},merge:function(a,b){for(var c=+b.length,d=0,e=a.length;c>d;d++)a[e++]=b[d];return a.length=e,a},grep:function(a,b,c){for(var d,e=[],f=0,g=a.length,h=!c;g>f;f++)d=!b(a[f],f),d!==h&&e.push(a[f]);return e},map:function(a,b,c){var d,f=0,g=a.length,h=s(a),i=[];if(h)for(;g>f;f++)d=b(a[f],f,c),null!=d&&i.push(d);else for(f in a)d=b(a[f],f,c),null!=d&&i.push(d);return e.apply([],i)},guid:1,proxy:function(a,b){var c,e,f;return"string"==typeof b&&(c=a[b],b=a,a=c),n.isFunction(a)?(e=d.call(arguments,2),f=function(){return a.apply(b||this,e.concat(d.call(arguments)))},f.guid=a.guid=a.guid||n.guid++,f):void 0},now:Date.now,support:k}),n.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(a,b){h["[object "+b+"]"]=b.toLowerCase()});function s(a){var b=a.length,c=n.type(a);return"function"===c||n.isWindow(a)?!1:1===a.nodeType&&b?!0:"array"===c||0===b||"number"==typeof b&&b>0&&b-1 in a}var t=function(a){var b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u="sizzle"+-new Date,v=a.document,w=0,x=0,y=gb(),z=gb(),A=gb(),B=function(a,b){return a===b&&(l=!0),0},C="undefined",D=1<<31,E={}.hasOwnProperty,F=[],G=F.pop,H=F.push,I=F.push,J=F.slice,K=F.indexOf||function(a){for(var b=0,c=this.length;c>b;b++)if(this[b]===a)return b;return-1},L="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",M="[\\x20\\t\\r\\n\\f]",N="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",O=N.replace("w","w#"),P="\\["+M+"*("+N+")(?:"+M+"*([*^$|!~]?=)"+M+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+O+"))|)"+M+"*\\]",Q=":("+N+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+P+")*)|.*)\\)|)",R=new RegExp("^"+M+"+|((?:^|[^\\\\])(?:\\\\.)*)"+M+"+$","g"),S=new RegExp("^"+M+"*,"+M+"*"),T=new RegExp("^"+M+"*([>+~]|"+M+")"+M+"*"),U=new RegExp("="+M+"*([^\\]'\"]*?)"+M+"*\\]","g"),V=new RegExp(Q),W=new RegExp("^"+O+"$"),X={ID:new RegExp("^#("+N+")"),CLASS:new RegExp("^\\.("+N+")"),TAG:new RegExp("^("+N.replace("w","w*")+")"),ATTR:new RegExp("^"+P),PSEUDO:new RegExp("^"+Q),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+L+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/^(?:input|select|textarea|button)$/i,Z=/^h\d$/i,$=/^[^{]+\{\s*\[native \w/,_=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ab=/[+~]/,bb=/'|\\/g,cb=new RegExp("\\\\([\\da-f]{1,6}"+M+"?|("+M+")|.)","ig"),db=function(a,b,c){var d="0x"+b-65536;return d!==d||c?b:0>d?String.fromCharCode(d+65536):String.fromCharCode(d>>10|55296,1023&d|56320)};try{I.apply(F=J.call(v.childNodes),v.childNodes),F[v.childNodes.length].nodeType}catch(eb){I={apply:F.length?function(a,b){H.apply(a,J.call(b))}:function(a,b){var c=a.length,d=0;while(a[c++]=b[d++]);a.length=c-1}}}function fb(a,b,d,e){var f,h,j,k,l,o,r,s,w,x;if((b?b.ownerDocument||b:v)!==n&&m(b),b=b||n,d=d||[],!a||"string"!=typeof a)return d;if(1!==(k=b.nodeType)&&9!==k)return[];if(p&&!e){if(f=_.exec(a))if(j=f[1]){if(9===k){if(h=b.getElementById(j),!h||!h.parentNode)return d;if(h.id===j)return d.push(h),d}else if(b.ownerDocument&&(h=b.ownerDocument.getElementById(j))&&t(b,h)&&h.id===j)return d.push(h),d}else{if(f[2])return I.apply(d,b.getElementsByTagName(a)),d;if((j=f[3])&&c.getElementsByClassName&&b.getElementsByClassName)return I.apply(d,b.getElementsByClassName(j)),d}if(c.qsa&&(!q||!q.test(a))){if(s=r=u,w=b,x=9===k&&a,1===k&&"object"!==b.nodeName.toLowerCase()){o=g(a),(r=b.getAttribute("id"))?s=r.replace(bb,"\\$&"):b.setAttribute("id",s),s="[id='"+s+"'] ",l=o.length;while(l--)o[l]=s+qb(o[l]);w=ab.test(a)&&ob(b.parentNode)||b,x=o.join(",")}if(x)try{return I.apply(d,w.querySelectorAll(x)),d}catch(y){}finally{r||b.removeAttribute("id")}}}return i(a.replace(R,"$1"),b,d,e)}function gb(){var a=[];function b(c,e){return a.push(c+" ")>d.cacheLength&&delete b[a.shift()],b[c+" "]=e}return b}function hb(a){return a[u]=!0,a}function ib(a){var b=n.createElement("div");try{return!!a(b)}catch(c){return!1}finally{b.parentNode&&b.parentNode.removeChild(b),b=null}}function jb(a,b){var c=a.split("|"),e=a.length;while(e--)d.attrHandle[c[e]]=b}function kb(a,b){var c=b&&a,d=c&&1===a.nodeType&&1===b.nodeType&&(~b.sourceIndex||D)-(~a.sourceIndex||D);if(d)return d;if(c)while(c=c.nextSibling)if(c===b)return-1;return a?1:-1}function lb(a){return function(b){var c=b.nodeName.toLowerCase();return"input"===c&&b.type===a}}function mb(a){return function(b){var c=b.nodeName.toLowerCase();return("input"===c||"button"===c)&&b.type===a}}function nb(a){return hb(function(b){return b=+b,hb(function(c,d){var e,f=a([],c.length,b),g=f.length;while(g--)c[e=f[g]]&&(c[e]=!(d[e]=c[e]))})})}function ob(a){return a&&typeof a.getElementsByTagName!==C&&a}c=fb.support={},f=fb.isXML=function(a){var b=a&&(a.ownerDocument||a).documentElement;return b?"HTML"!==b.nodeName:!1},m=fb.setDocument=function(a){var b,e=a?a.ownerDocument||a:v,g=e.defaultView;return e!==n&&9===e.nodeType&&e.documentElement?(n=e,o=e.documentElement,p=!f(e),g&&g!==g.top&&(g.addEventListener?g.addEventListener("unload",function(){m()},!1):g.attachEvent&&g.attachEvent("onunload",function(){m()})),c.attributes=ib(function(a){return a.className="i",!a.getAttribute("className")}),c.getElementsByTagName=ib(function(a){return a.appendChild(e.createComment("")),!a.getElementsByTagName("*").length}),c.getElementsByClassName=$.test(e.getElementsByClassName)&&ib(function(a){return a.innerHTML="
",a.firstChild.className="i",2===a.getElementsByClassName("i").length}),c.getById=ib(function(a){return o.appendChild(a).id=u,!e.getElementsByName||!e.getElementsByName(u).length}),c.getById?(d.find.ID=function(a,b){if(typeof b.getElementById!==C&&p){var c=b.getElementById(a);return c&&c.parentNode?[c]:[]}},d.filter.ID=function(a){var b=a.replace(cb,db);return function(a){return a.getAttribute("id")===b}}):(delete d.find.ID,d.filter.ID=function(a){var b=a.replace(cb,db);return function(a){var c=typeof a.getAttributeNode!==C&&a.getAttributeNode("id");return c&&c.value===b}}),d.find.TAG=c.getElementsByTagName?function(a,b){return typeof b.getElementsByTagName!==C?b.getElementsByTagName(a):void 0}:function(a,b){var c,d=[],e=0,f=b.getElementsByTagName(a);if("*"===a){while(c=f[e++])1===c.nodeType&&d.push(c);return d}return f},d.find.CLASS=c.getElementsByClassName&&function(a,b){return typeof b.getElementsByClassName!==C&&p?b.getElementsByClassName(a):void 0},r=[],q=[],(c.qsa=$.test(e.querySelectorAll))&&(ib(function(a){a.innerHTML="",a.querySelectorAll("[msallowclip^='']").length&&q.push("[*^$]="+M+"*(?:''|\"\")"),a.querySelectorAll("[selected]").length||q.push("\\["+M+"*(?:value|"+L+")"),a.querySelectorAll(":checked").length||q.push(":checked")}),ib(function(a){var b=e.createElement("input");b.setAttribute("type","hidden"),a.appendChild(b).setAttribute("name","D"),a.querySelectorAll("[name=d]").length&&q.push("name"+M+"*[*^$|!~]?="),a.querySelectorAll(":enabled").length||q.push(":enabled",":disabled"),a.querySelectorAll("*,:x"),q.push(",.*:")})),(c.matchesSelector=$.test(s=o.matches||o.webkitMatchesSelector||o.mozMatchesSelector||o.oMatchesSelector||o.msMatchesSelector))&&ib(function(a){c.disconnectedMatch=s.call(a,"div"),s.call(a,"[s!='']:x"),r.push("!=",Q)}),q=q.length&&new RegExp(q.join("|")),r=r.length&&new RegExp(r.join("|")),b=$.test(o.compareDocumentPosition),t=b||$.test(o.contains)?function(a,b){var c=9===a.nodeType?a.documentElement:a,d=b&&b.parentNode;return a===d||!(!d||1!==d.nodeType||!(c.contains?c.contains(d):a.compareDocumentPosition&&16&a.compareDocumentPosition(d)))}:function(a,b){if(b)while(b=b.parentNode)if(b===a)return!0;return!1},B=b?function(a,b){if(a===b)return l=!0,0;var d=!a.compareDocumentPosition-!b.compareDocumentPosition;return d?d:(d=(a.ownerDocument||a)===(b.ownerDocument||b)?a.compareDocumentPosition(b):1,1&d||!c.sortDetached&&b.compareDocumentPosition(a)===d?a===e||a.ownerDocument===v&&t(v,a)?-1:b===e||b.ownerDocument===v&&t(v,b)?1:k?K.call(k,a)-K.call(k,b):0:4&d?-1:1)}:function(a,b){if(a===b)return l=!0,0;var c,d=0,f=a.parentNode,g=b.parentNode,h=[a],i=[b];if(!f||!g)return a===e?-1:b===e?1:f?-1:g?1:k?K.call(k,a)-K.call(k,b):0;if(f===g)return kb(a,b);c=a;while(c=c.parentNode)h.unshift(c);c=b;while(c=c.parentNode)i.unshift(c);while(h[d]===i[d])d++;return d?kb(h[d],i[d]):h[d]===v?-1:i[d]===v?1:0},e):n},fb.matches=function(a,b){return fb(a,null,null,b)},fb.matchesSelector=function(a,b){if((a.ownerDocument||a)!==n&&m(a),b=b.replace(U,"='$1']"),!(!c.matchesSelector||!p||r&&r.test(b)||q&&q.test(b)))try{var d=s.call(a,b);if(d||c.disconnectedMatch||a.document&&11!==a.document.nodeType)return d}catch(e){}return fb(b,n,null,[a]).length>0},fb.contains=function(a,b){return(a.ownerDocument||a)!==n&&m(a),t(a,b)},fb.attr=function(a,b){(a.ownerDocument||a)!==n&&m(a);var e=d.attrHandle[b.toLowerCase()],f=e&&E.call(d.attrHandle,b.toLowerCase())?e(a,b,!p):void 0;return void 0!==f?f:c.attributes||!p?a.getAttribute(b):(f=a.getAttributeNode(b))&&f.specified?f.value:null},fb.error=function(a){throw new Error("Syntax error, unrecognized expression: "+a)},fb.uniqueSort=function(a){var b,d=[],e=0,f=0;if(l=!c.detectDuplicates,k=!c.sortStable&&a.slice(0),a.sort(B),l){while(b=a[f++])b===a[f]&&(e=d.push(f));while(e--)a.splice(d[e],1)}return k=null,a},e=fb.getText=function(a){var b,c="",d=0,f=a.nodeType;if(f){if(1===f||9===f||11===f){if("string"==typeof a.textContent)return a.textContent;for(a=a.firstChild;a;a=a.nextSibling)c+=e(a)}else if(3===f||4===f)return a.nodeValue}else while(b=a[d++])c+=e(b);return c},d=fb.selectors={cacheLength:50,createPseudo:hb,match:X,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(a){return a[1]=a[1].replace(cb,db),a[3]=(a[3]||a[4]||a[5]||"").replace(cb,db),"~="===a[2]&&(a[3]=" "+a[3]+" "),a.slice(0,4)},CHILD:function(a){return a[1]=a[1].toLowerCase(),"nth"===a[1].slice(0,3)?(a[3]||fb.error(a[0]),a[4]=+(a[4]?a[5]+(a[6]||1):2*("even"===a[3]||"odd"===a[3])),a[5]=+(a[7]+a[8]||"odd"===a[3])):a[3]&&fb.error(a[0]),a},PSEUDO:function(a){var b,c=!a[6]&&a[2];return X.CHILD.test(a[0])?null:(a[3]?a[2]=a[4]||a[5]||"":c&&V.test(c)&&(b=g(c,!0))&&(b=c.indexOf(")",c.length-b)-c.length)&&(a[0]=a[0].slice(0,b),a[2]=c.slice(0,b)),a.slice(0,3))}},filter:{TAG:function(a){var b=a.replace(cb,db).toLowerCase();return"*"===a?function(){return!0}:function(a){return a.nodeName&&a.nodeName.toLowerCase()===b}},CLASS:function(a){var b=y[a+" "];return b||(b=new RegExp("(^|"+M+")"+a+"("+M+"|$)"))&&y(a,function(a){return b.test("string"==typeof a.className&&a.className||typeof a.getAttribute!==C&&a.getAttribute("class")||"")})},ATTR:function(a,b,c){return function(d){var e=fb.attr(d,a);return null==e?"!="===b:b?(e+="","="===b?e===c:"!="===b?e!==c:"^="===b?c&&0===e.indexOf(c):"*="===b?c&&e.indexOf(c)>-1:"$="===b?c&&e.slice(-c.length)===c:"~="===b?(" "+e+" ").indexOf(c)>-1:"|="===b?e===c||e.slice(0,c.length+1)===c+"-":!1):!0}},CHILD:function(a,b,c,d,e){var f="nth"!==a.slice(0,3),g="last"!==a.slice(-4),h="of-type"===b;return 1===d&&0===e?function(a){return!!a.parentNode}:function(b,c,i){var j,k,l,m,n,o,p=f!==g?"nextSibling":"previousSibling",q=b.parentNode,r=h&&b.nodeName.toLowerCase(),s=!i&&!h;if(q){if(f){while(p){l=b;while(l=l[p])if(h?l.nodeName.toLowerCase()===r:1===l.nodeType)return!1;o=p="only"===a&&!o&&"nextSibling"}return!0}if(o=[g?q.firstChild:q.lastChild],g&&s){k=q[u]||(q[u]={}),j=k[a]||[],n=j[0]===w&&j[1],m=j[0]===w&&j[2],l=n&&q.childNodes[n];while(l=++n&&l&&l[p]||(m=n=0)||o.pop())if(1===l.nodeType&&++m&&l===b){k[a]=[w,n,m];break}}else if(s&&(j=(b[u]||(b[u]={}))[a])&&j[0]===w)m=j[1];else while(l=++n&&l&&l[p]||(m=n=0)||o.pop())if((h?l.nodeName.toLowerCase()===r:1===l.nodeType)&&++m&&(s&&((l[u]||(l[u]={}))[a]=[w,m]),l===b))break;return m-=e,m===d||m%d===0&&m/d>=0}}},PSEUDO:function(a,b){var c,e=d.pseudos[a]||d.setFilters[a.toLowerCase()]||fb.error("unsupported pseudo: "+a);return e[u]?e(b):e.length>1?(c=[a,a,"",b],d.setFilters.hasOwnProperty(a.toLowerCase())?hb(function(a,c){var d,f=e(a,b),g=f.length;while(g--)d=K.call(a,f[g]),a[d]=!(c[d]=f[g])}):function(a){return e(a,0,c)}):e}},pseudos:{not:hb(function(a){var b=[],c=[],d=h(a.replace(R,"$1"));return d[u]?hb(function(a,b,c,e){var f,g=d(a,null,e,[]),h=a.length;while(h--)(f=g[h])&&(a[h]=!(b[h]=f))}):function(a,e,f){return b[0]=a,d(b,null,f,c),!c.pop()}}),has:hb(function(a){return function(b){return fb(a,b).length>0}}),contains:hb(function(a){return function(b){return(b.textContent||b.innerText||e(b)).indexOf(a)>-1}}),lang:hb(function(a){return W.test(a||"")||fb.error("unsupported lang: "+a),a=a.replace(cb,db).toLowerCase(),function(b){var c;do if(c=p?b.lang:b.getAttribute("xml:lang")||b.getAttribute("lang"))return c=c.toLowerCase(),c===a||0===c.indexOf(a+"-");while((b=b.parentNode)&&1===b.nodeType);return!1}}),target:function(b){var c=a.location&&a.location.hash;return c&&c.slice(1)===b.id},root:function(a){return a===o},focus:function(a){return a===n.activeElement&&(!n.hasFocus||n.hasFocus())&&!!(a.type||a.href||~a.tabIndex)},enabled:function(a){return a.disabled===!1},disabled:function(a){return a.disabled===!0},checked:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&!!a.checked||"option"===b&&!!a.selected},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,a.selected===!0},empty:function(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType<6)return!1;return!0},parent:function(a){return!d.pseudos.empty(a)},header:function(a){return Z.test(a.nodeName)},input:function(a){return Y.test(a.nodeName)},button:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&"button"===a.type||"button"===b},text:function(a){var b;return"input"===a.nodeName.toLowerCase()&&"text"===a.type&&(null==(b=a.getAttribute("type"))||"text"===b.toLowerCase())},first:nb(function(){return[0]}),last:nb(function(a,b){return[b-1]}),eq:nb(function(a,b,c){return[0>c?c+b:c]}),even:nb(function(a,b){for(var c=0;b>c;c+=2)a.push(c);return a}),odd:nb(function(a,b){for(var c=1;b>c;c+=2)a.push(c);return a}),lt:nb(function(a,b,c){for(var d=0>c?c+b:c;--d>=0;)a.push(d);return a}),gt:nb(function(a,b,c){for(var d=0>c?c+b:c;++db;b++)d+=a[b].value;return d}function rb(a,b,c){var d=b.dir,e=c&&"parentNode"===d,f=x++;return b.first?function(b,c,f){while(b=b[d])if(1===b.nodeType||e)return a(b,c,f)}:function(b,c,g){var h,i,j=[w,f];if(g){while(b=b[d])if((1===b.nodeType||e)&&a(b,c,g))return!0}else while(b=b[d])if(1===b.nodeType||e){if(i=b[u]||(b[u]={}),(h=i[d])&&h[0]===w&&h[1]===f)return j[2]=h[2];if(i[d]=j,j[2]=a(b,c,g))return!0}}}function sb(a){return a.length>1?function(b,c,d){var e=a.length;while(e--)if(!a[e](b,c,d))return!1;return!0}:a[0]}function tb(a,b,c){for(var d=0,e=b.length;e>d;d++)fb(a,b[d],c);return c}function ub(a,b,c,d,e){for(var f,g=[],h=0,i=a.length,j=null!=b;i>h;h++)(f=a[h])&&(!c||c(f,d,e))&&(g.push(f),j&&b.push(h));return g}function vb(a,b,c,d,e,f){return d&&!d[u]&&(d=vb(d)),e&&!e[u]&&(e=vb(e,f)),hb(function(f,g,h,i){var j,k,l,m=[],n=[],o=g.length,p=f||tb(b||"*",h.nodeType?[h]:h,[]),q=!a||!f&&b?p:ub(p,m,a,h,i),r=c?e||(f?a:o||d)?[]:g:q;if(c&&c(q,r,h,i),d){j=ub(r,n),d(j,[],h,i),k=j.length;while(k--)(l=j[k])&&(r[n[k]]=!(q[n[k]]=l))}if(f){if(e||a){if(e){j=[],k=r.length;while(k--)(l=r[k])&&j.push(q[k]=l);e(null,r=[],j,i)}k=r.length;while(k--)(l=r[k])&&(j=e?K.call(f,l):m[k])>-1&&(f[j]=!(g[j]=l))}}else r=ub(r===g?r.splice(o,r.length):r),e?e(null,g,r,i):I.apply(g,r)})}function wb(a){for(var b,c,e,f=a.length,g=d.relative[a[0].type],h=g||d.relative[" "],i=g?1:0,k=rb(function(a){return a===b},h,!0),l=rb(function(a){return K.call(b,a)>-1},h,!0),m=[function(a,c,d){return!g&&(d||c!==j)||((b=c).nodeType?k(a,c,d):l(a,c,d))}];f>i;i++)if(c=d.relative[a[i].type])m=[rb(sb(m),c)];else{if(c=d.filter[a[i].type].apply(null,a[i].matches),c[u]){for(e=++i;f>e;e++)if(d.relative[a[e].type])break;return vb(i>1&&sb(m),i>1&&qb(a.slice(0,i-1).concat({value:" "===a[i-2].type?"*":""})).replace(R,"$1"),c,e>i&&wb(a.slice(i,e)),f>e&&wb(a=a.slice(e)),f>e&&qb(a))}m.push(c)}return sb(m)}function xb(a,b){var c=b.length>0,e=a.length>0,f=function(f,g,h,i,k){var l,m,o,p=0,q="0",r=f&&[],s=[],t=j,u=f||e&&d.find.TAG("*",k),v=w+=null==t?1:Math.random()||.1,x=u.length;for(k&&(j=g!==n&&g);q!==x&&null!=(l=u[q]);q++){if(e&&l){m=0;while(o=a[m++])if(o(l,g,h)){i.push(l);break}k&&(w=v)}c&&((l=!o&&l)&&p--,f&&r.push(l))}if(p+=q,c&&q!==p){m=0;while(o=b[m++])o(r,s,g,h);if(f){if(p>0)while(q--)r[q]||s[q]||(s[q]=G.call(i));s=ub(s)}I.apply(i,s),k&&!f&&s.length>0&&p+b.length>1&&fb.uniqueSort(i)}return k&&(w=v,j=t),r};return c?hb(f):f}return h=fb.compile=function(a,b){var c,d=[],e=[],f=A[a+" "];if(!f){b||(b=g(a)),c=b.length;while(c--)f=wb(b[c]),f[u]?d.push(f):e.push(f);f=A(a,xb(e,d)),f.selector=a}return f},i=fb.select=function(a,b,e,f){var i,j,k,l,m,n="function"==typeof a&&a,o=!f&&g(a=n.selector||a);if(e=e||[],1===o.length){if(j=o[0]=o[0].slice(0),j.length>2&&"ID"===(k=j[0]).type&&c.getById&&9===b.nodeType&&p&&d.relative[j[1].type]){if(b=(d.find.ID(k.matches[0].replace(cb,db),b)||[])[0],!b)return e;n&&(b=b.parentNode),a=a.slice(j.shift().value.length)}i=X.needsContext.test(a)?0:j.length;while(i--){if(k=j[i],d.relative[l=k.type])break;if((m=d.find[l])&&(f=m(k.matches[0].replace(cb,db),ab.test(j[0].type)&&ob(b.parentNode)||b))){if(j.splice(i,1),a=f.length&&qb(j),!a)return I.apply(e,f),e;break}}}return(n||h(a,o))(f,b,!p,e,ab.test(a)&&ob(b.parentNode)||b),e},c.sortStable=u.split("").sort(B).join("")===u,c.detectDuplicates=!!l,m(),c.sortDetached=ib(function(a){return 1&a.compareDocumentPosition(n.createElement("div"))}),ib(function(a){return a.innerHTML="","#"===a.firstChild.getAttribute("href")})||jb("type|href|height|width",function(a,b,c){return c?void 0:a.getAttribute(b,"type"===b.toLowerCase()?1:2)}),c.attributes&&ib(function(a){return a.innerHTML="",a.firstChild.setAttribute("value",""),""===a.firstChild.getAttribute("value")})||jb("value",function(a,b,c){return c||"input"!==a.nodeName.toLowerCase()?void 0:a.defaultValue}),ib(function(a){return null==a.getAttribute("disabled")})||jb(L,function(a,b,c){var d;return c?void 0:a[b]===!0?b.toLowerCase():(d=a.getAttributeNode(b))&&d.specified?d.value:null}),fb}(a);n.find=t,n.expr=t.selectors,n.expr[":"]=n.expr.pseudos,n.unique=t.uniqueSort,n.text=t.getText,n.isXMLDoc=t.isXML,n.contains=t.contains;var u=n.expr.match.needsContext,v=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,w=/^.[^:#\[\.,]*$/;function x(a,b,c){if(n.isFunction(b))return n.grep(a,function(a,d){return!!b.call(a,d,a)!==c});if(b.nodeType)return n.grep(a,function(a){return a===b!==c});if("string"==typeof b){if(w.test(b))return n.filter(b,a,c);b=n.filter(b,a)}return n.grep(a,function(a){return g.call(b,a)>=0!==c})}n.filter=function(a,b,c){var d=b[0];return c&&(a=":not("+a+")"),1===b.length&&1===d.nodeType?n.find.matchesSelector(d,a)?[d]:[]:n.find.matches(a,n.grep(b,function(a){return 1===a.nodeType}))},n.fn.extend({find:function(a){var b,c=this.length,d=[],e=this;if("string"!=typeof a)return this.pushStack(n(a).filter(function(){for(b=0;c>b;b++)if(n.contains(e[b],this))return!0}));for(b=0;c>b;b++)n.find(a,e[b],d);return d=this.pushStack(c>1?n.unique(d):d),d.selector=this.selector?this.selector+" "+a:a,d},filter:function(a){return this.pushStack(x(this,a||[],!1))},not:function(a){return this.pushStack(x(this,a||[],!0))},is:function(a){return!!x(this,"string"==typeof a&&u.test(a)?n(a):a||[],!1).length}});var y,z=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,A=n.fn.init=function(a,b){var c,d;if(!a)return this;if("string"==typeof a){if(c="<"===a[0]&&">"===a[a.length-1]&&a.length>=3?[null,a,null]:z.exec(a),!c||!c[1]&&b)return!b||b.jquery?(b||y).find(a):this.constructor(b).find(a);if(c[1]){if(b=b instanceof n?b[0]:b,n.merge(this,n.parseHTML(c[1],b&&b.nodeType?b.ownerDocument||b:l,!0)),v.test(c[1])&&n.isPlainObject(b))for(c in b)n.isFunction(this[c])?this[c](b[c]):this.attr(c,b[c]);return this}return d=l.getElementById(c[2]),d&&d.parentNode&&(this.length=1,this[0]=d),this.context=l,this.selector=a,this}return a.nodeType?(this.context=this[0]=a,this.length=1,this):n.isFunction(a)?"undefined"!=typeof y.ready?y.ready(a):a(n):(void 0!==a.selector&&(this.selector=a.selector,this.context=a.context),n.makeArray(a,this))};A.prototype=n.fn,y=n(l);var B=/^(?:parents|prev(?:Until|All))/,C={children:!0,contents:!0,next:!0,prev:!0};n.extend({dir:function(a,b,c){var d=[],e=void 0!==c;while((a=a[b])&&9!==a.nodeType)if(1===a.nodeType){if(e&&n(a).is(c))break;d.push(a)}return d},sibling:function(a,b){for(var c=[];a;a=a.nextSibling)1===a.nodeType&&a!==b&&c.push(a);return c}}),n.fn.extend({has:function(a){var b=n(a,this),c=b.length;return this.filter(function(){for(var a=0;c>a;a++)if(n.contains(this,b[a]))return!0})},closest:function(a,b){for(var c,d=0,e=this.length,f=[],g=u.test(a)||"string"!=typeof a?n(a,b||this.context):0;e>d;d++)for(c=this[d];c&&c!==b;c=c.parentNode)if(c.nodeType<11&&(g?g.index(c)>-1:1===c.nodeType&&n.find.matchesSelector(c,a))){f.push(c);break}return this.pushStack(f.length>1?n.unique(f):f)},index:function(a){return a?"string"==typeof a?g.call(n(a),this[0]):g.call(this,a.jquery?a[0]:a):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(a,b){return this.pushStack(n.unique(n.merge(this.get(),n(a,b))))},addBack:function(a){return this.add(null==a?this.prevObject:this.prevObject.filter(a))}});function D(a,b){while((a=a[b])&&1!==a.nodeType);return a}n.each({parent:function(a){var b=a.parentNode;return b&&11!==b.nodeType?b:null},parents:function(a){return n.dir(a,"parentNode")},parentsUntil:function(a,b,c){return n.dir(a,"parentNode",c)},next:function(a){return D(a,"nextSibling")},prev:function(a){return D(a,"previousSibling")},nextAll:function(a){return n.dir(a,"nextSibling")},prevAll:function(a){return n.dir(a,"previousSibling")},nextUntil:function(a,b,c){return n.dir(a,"nextSibling",c)},prevUntil:function(a,b,c){return n.dir(a,"previousSibling",c)},siblings:function(a){return n.sibling((a.parentNode||{}).firstChild,a)},children:function(a){return n.sibling(a.firstChild)},contents:function(a){return a.contentDocument||n.merge([],a.childNodes)}},function(a,b){n.fn[a]=function(c,d){var e=n.map(this,b,c);return"Until"!==a.slice(-5)&&(d=c),d&&"string"==typeof d&&(e=n.filter(d,e)),this.length>1&&(C[a]||n.unique(e),B.test(a)&&e.reverse()),this.pushStack(e)}});var E=/\S+/g,F={};function G(a){var b=F[a]={};return n.each(a.match(E)||[],function(a,c){b[c]=!0}),b}n.Callbacks=function(a){a="string"==typeof a?F[a]||G(a):n.extend({},a);var b,c,d,e,f,g,h=[],i=!a.once&&[],j=function(l){for(b=a.memory&&l,c=!0,g=e||0,e=0,f=h.length,d=!0;h&&f>g;g++)if(h[g].apply(l[0],l[1])===!1&&a.stopOnFalse){b=!1;break}d=!1,h&&(i?i.length&&j(i.shift()):b?h=[]:k.disable())},k={add:function(){if(h){var c=h.length;!function g(b){n.each(b,function(b,c){var d=n.type(c);"function"===d?a.unique&&k.has(c)||h.push(c):c&&c.length&&"string"!==d&&g(c)})}(arguments),d?f=h.length:b&&(e=c,j(b))}return this},remove:function(){return h&&n.each(arguments,function(a,b){var c;while((c=n.inArray(b,h,c))>-1)h.splice(c,1),d&&(f>=c&&f--,g>=c&&g--)}),this},has:function(a){return a?n.inArray(a,h)>-1:!(!h||!h.length)},empty:function(){return h=[],f=0,this},disable:function(){return h=i=b=void 0,this},disabled:function(){return!h},lock:function(){return i=void 0,b||k.disable(),this},locked:function(){return!i},fireWith:function(a,b){return!h||c&&!i||(b=b||[],b=[a,b.slice?b.slice():b],d?i.push(b):j(b)),this},fire:function(){return k.fireWith(this,arguments),this},fired:function(){return!!c}};return k},n.extend({Deferred:function(a){var b=[["resolve","done",n.Callbacks("once memory"),"resolved"],["reject","fail",n.Callbacks("once memory"),"rejected"],["notify","progress",n.Callbacks("memory")]],c="pending",d={state:function(){return c},always:function(){return e.done(arguments).fail(arguments),this},then:function(){var a=arguments;return n.Deferred(function(c){n.each(b,function(b,f){var g=n.isFunction(a[b])&&a[b];e[f[1]](function(){var a=g&&g.apply(this,arguments);a&&n.isFunction(a.promise)?a.promise().done(c.resolve).fail(c.reject).progress(c.notify):c[f[0]+"With"](this===d?c.promise():this,g?[a]:arguments)})}),a=null}).promise()},promise:function(a){return null!=a?n.extend(a,d):d}},e={};return d.pipe=d.then,n.each(b,function(a,f){var g=f[2],h=f[3];d[f[1]]=g.add,h&&g.add(function(){c=h},b[1^a][2].disable,b[2][2].lock),e[f[0]]=function(){return e[f[0]+"With"](this===e?d:this,arguments),this},e[f[0]+"With"]=g.fireWith}),d.promise(e),a&&a.call(e,e),e},when:function(a){var b=0,c=d.call(arguments),e=c.length,f=1!==e||a&&n.isFunction(a.promise)?e:0,g=1===f?a:n.Deferred(),h=function(a,b,c){return function(e){b[a]=this,c[a]=arguments.length>1?d.call(arguments):e,c===i?g.notifyWith(b,c):--f||g.resolveWith(b,c)}},i,j,k;if(e>1)for(i=new Array(e),j=new Array(e),k=new Array(e);e>b;b++)c[b]&&n.isFunction(c[b].promise)?c[b].promise().done(h(b,k,c)).fail(g.reject).progress(h(b,j,i)):--f;return f||g.resolveWith(k,c),g.promise()}});var H;n.fn.ready=function(a){return n.ready.promise().done(a),this},n.extend({isReady:!1,readyWait:1,holdReady:function(a){a?n.readyWait++:n.ready(!0)},ready:function(a){(a===!0?--n.readyWait:n.isReady)||(n.isReady=!0,a!==!0&&--n.readyWait>0||(H.resolveWith(l,[n]),n.fn.triggerHandler&&(n(l).triggerHandler("ready"),n(l).off("ready"))))}});function I(){l.removeEventListener("DOMContentLoaded",I,!1),a.removeEventListener("load",I,!1),n.ready()}n.ready.promise=function(b){return H||(H=n.Deferred(),"complete"===l.readyState?setTimeout(n.ready):(l.addEventListener("DOMContentLoaded",I,!1),a.addEventListener("load",I,!1))),H.promise(b)},n.ready.promise();var J=n.access=function(a,b,c,d,e,f,g){var h=0,i=a.length,j=null==c;if("object"===n.type(c)){e=!0;for(h in c)n.access(a,b,h,c[h],!0,f,g)}else if(void 0!==d&&(e=!0,n.isFunction(d)||(g=!0),j&&(g?(b.call(a,d),b=null):(j=b,b=function(a,b,c){return j.call(n(a),c)})),b))for(;i>h;h++)b(a[h],c,g?d:d.call(a[h],h,b(a[h],c)));return e?a:j?b.call(a):i?b(a[0],c):f};n.acceptData=function(a){return 1===a.nodeType||9===a.nodeType||!+a.nodeType};function K(){Object.defineProperty(this.cache={},0,{get:function(){return{}}}),this.expando=n.expando+Math.random()}K.uid=1,K.accepts=n.acceptData,K.prototype={key:function(a){if(!K.accepts(a))return 0;var b={},c=a[this.expando];if(!c){c=K.uid++;try{b[this.expando]={value:c},Object.defineProperties(a,b)}catch(d){b[this.expando]=c,n.extend(a,b)}}return this.cache[c]||(this.cache[c]={}),c},set:function(a,b,c){var d,e=this.key(a),f=this.cache[e];if("string"==typeof b)f[b]=c;else if(n.isEmptyObject(f))n.extend(this.cache[e],b);else for(d in b)f[d]=b[d];return f},get:function(a,b){var c=this.cache[this.key(a)];return void 0===b?c:c[b]},access:function(a,b,c){var d;return void 0===b||b&&"string"==typeof b&&void 0===c?(d=this.get(a,b),void 0!==d?d:this.get(a,n.camelCase(b))):(this.set(a,b,c),void 0!==c?c:b)},remove:function(a,b){var c,d,e,f=this.key(a),g=this.cache[f];if(void 0===b)this.cache[f]={};else{n.isArray(b)?d=b.concat(b.map(n.camelCase)):(e=n.camelCase(b),b in g?d=[b,e]:(d=e,d=d in g?[d]:d.match(E)||[])),c=d.length;while(c--)delete g[d[c]]}},hasData:function(a){return!n.isEmptyObject(this.cache[a[this.expando]]||{})},discard:function(a){a[this.expando]&&delete this.cache[a[this.expando]]}};var L=new K,M=new K,N=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,O=/([A-Z])/g;function P(a,b,c){var d;if(void 0===c&&1===a.nodeType)if(d="data-"+b.replace(O,"-$1").toLowerCase(),c=a.getAttribute(d),"string"==typeof c){try{c="true"===c?!0:"false"===c?!1:"null"===c?null:+c+""===c?+c:N.test(c)?n.parseJSON(c):c}catch(e){}M.set(a,b,c)}else c=void 0;return c}n.extend({hasData:function(a){return M.hasData(a)||L.hasData(a)},data:function(a,b,c){return M.access(a,b,c)},removeData:function(a,b){M.remove(a,b) +},_data:function(a,b,c){return L.access(a,b,c)},_removeData:function(a,b){L.remove(a,b)}}),n.fn.extend({data:function(a,b){var c,d,e,f=this[0],g=f&&f.attributes;if(void 0===a){if(this.length&&(e=M.get(f),1===f.nodeType&&!L.get(f,"hasDataAttrs"))){c=g.length;while(c--)g[c]&&(d=g[c].name,0===d.indexOf("data-")&&(d=n.camelCase(d.slice(5)),P(f,d,e[d])));L.set(f,"hasDataAttrs",!0)}return e}return"object"==typeof a?this.each(function(){M.set(this,a)}):J(this,function(b){var c,d=n.camelCase(a);if(f&&void 0===b){if(c=M.get(f,a),void 0!==c)return c;if(c=M.get(f,d),void 0!==c)return c;if(c=P(f,d,void 0),void 0!==c)return c}else this.each(function(){var c=M.get(this,d);M.set(this,d,b),-1!==a.indexOf("-")&&void 0!==c&&M.set(this,a,b)})},null,b,arguments.length>1,null,!0)},removeData:function(a){return this.each(function(){M.remove(this,a)})}}),n.extend({queue:function(a,b,c){var d;return a?(b=(b||"fx")+"queue",d=L.get(a,b),c&&(!d||n.isArray(c)?d=L.access(a,b,n.makeArray(c)):d.push(c)),d||[]):void 0},dequeue:function(a,b){b=b||"fx";var c=n.queue(a,b),d=c.length,e=c.shift(),f=n._queueHooks(a,b),g=function(){n.dequeue(a,b)};"inprogress"===e&&(e=c.shift(),d--),e&&("fx"===b&&c.unshift("inprogress"),delete f.stop,e.call(a,g,f)),!d&&f&&f.empty.fire()},_queueHooks:function(a,b){var c=b+"queueHooks";return L.get(a,c)||L.access(a,c,{empty:n.Callbacks("once memory").add(function(){L.remove(a,[b+"queue",c])})})}}),n.fn.extend({queue:function(a,b){var c=2;return"string"!=typeof a&&(b=a,a="fx",c--),arguments.lengthx",k.noCloneChecked=!!b.cloneNode(!0).lastChild.defaultValue}();var U="undefined";k.focusinBubbles="onfocusin"in a;var V=/^key/,W=/^(?:mouse|pointer|contextmenu)|click/,X=/^(?:focusinfocus|focusoutblur)$/,Y=/^([^.]*)(?:\.(.+)|)$/;function Z(){return!0}function $(){return!1}function _(){try{return l.activeElement}catch(a){}}n.event={global:{},add:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=L.get(a);if(r){c.handler&&(f=c,c=f.handler,e=f.selector),c.guid||(c.guid=n.guid++),(i=r.events)||(i=r.events={}),(g=r.handle)||(g=r.handle=function(b){return typeof n!==U&&n.event.triggered!==b.type?n.event.dispatch.apply(a,arguments):void 0}),b=(b||"").match(E)||[""],j=b.length;while(j--)h=Y.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o&&(l=n.event.special[o]||{},o=(e?l.delegateType:l.bindType)||o,l=n.event.special[o]||{},k=n.extend({type:o,origType:q,data:d,handler:c,guid:c.guid,selector:e,needsContext:e&&n.expr.match.needsContext.test(e),namespace:p.join(".")},f),(m=i[o])||(m=i[o]=[],m.delegateCount=0,l.setup&&l.setup.call(a,d,p,g)!==!1||a.addEventListener&&a.addEventListener(o,g,!1)),l.add&&(l.add.call(a,k),k.handler.guid||(k.handler.guid=c.guid)),e?m.splice(m.delegateCount++,0,k):m.push(k),n.event.global[o]=!0)}},remove:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=L.hasData(a)&&L.get(a);if(r&&(i=r.events)){b=(b||"").match(E)||[""],j=b.length;while(j--)if(h=Y.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o){l=n.event.special[o]||{},o=(d?l.delegateType:l.bindType)||o,m=i[o]||[],h=h[2]&&new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"),g=f=m.length;while(f--)k=m[f],!e&&q!==k.origType||c&&c.guid!==k.guid||h&&!h.test(k.namespace)||d&&d!==k.selector&&("**"!==d||!k.selector)||(m.splice(f,1),k.selector&&m.delegateCount--,l.remove&&l.remove.call(a,k));g&&!m.length&&(l.teardown&&l.teardown.call(a,p,r.handle)!==!1||n.removeEvent(a,o,r.handle),delete i[o])}else for(o in i)n.event.remove(a,o+b[j],c,d,!0);n.isEmptyObject(i)&&(delete r.handle,L.remove(a,"events"))}},trigger:function(b,c,d,e){var f,g,h,i,k,m,o,p=[d||l],q=j.call(b,"type")?b.type:b,r=j.call(b,"namespace")?b.namespace.split("."):[];if(g=h=d=d||l,3!==d.nodeType&&8!==d.nodeType&&!X.test(q+n.event.triggered)&&(q.indexOf(".")>=0&&(r=q.split("."),q=r.shift(),r.sort()),k=q.indexOf(":")<0&&"on"+q,b=b[n.expando]?b:new n.Event(q,"object"==typeof b&&b),b.isTrigger=e?2:3,b.namespace=r.join("."),b.namespace_re=b.namespace?new RegExp("(^|\\.)"+r.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,b.result=void 0,b.target||(b.target=d),c=null==c?[b]:n.makeArray(c,[b]),o=n.event.special[q]||{},e||!o.trigger||o.trigger.apply(d,c)!==!1)){if(!e&&!o.noBubble&&!n.isWindow(d)){for(i=o.delegateType||q,X.test(i+q)||(g=g.parentNode);g;g=g.parentNode)p.push(g),h=g;h===(d.ownerDocument||l)&&p.push(h.defaultView||h.parentWindow||a)}f=0;while((g=p[f++])&&!b.isPropagationStopped())b.type=f>1?i:o.bindType||q,m=(L.get(g,"events")||{})[b.type]&&L.get(g,"handle"),m&&m.apply(g,c),m=k&&g[k],m&&m.apply&&n.acceptData(g)&&(b.result=m.apply(g,c),b.result===!1&&b.preventDefault());return b.type=q,e||b.isDefaultPrevented()||o._default&&o._default.apply(p.pop(),c)!==!1||!n.acceptData(d)||k&&n.isFunction(d[q])&&!n.isWindow(d)&&(h=d[k],h&&(d[k]=null),n.event.triggered=q,d[q](),n.event.triggered=void 0,h&&(d[k]=h)),b.result}},dispatch:function(a){a=n.event.fix(a);var b,c,e,f,g,h=[],i=d.call(arguments),j=(L.get(this,"events")||{})[a.type]||[],k=n.event.special[a.type]||{};if(i[0]=a,a.delegateTarget=this,!k.preDispatch||k.preDispatch.call(this,a)!==!1){h=n.event.handlers.call(this,a,j),b=0;while((f=h[b++])&&!a.isPropagationStopped()){a.currentTarget=f.elem,c=0;while((g=f.handlers[c++])&&!a.isImmediatePropagationStopped())(!a.namespace_re||a.namespace_re.test(g.namespace))&&(a.handleObj=g,a.data=g.data,e=((n.event.special[g.origType]||{}).handle||g.handler).apply(f.elem,i),void 0!==e&&(a.result=e)===!1&&(a.preventDefault(),a.stopPropagation()))}return k.postDispatch&&k.postDispatch.call(this,a),a.result}},handlers:function(a,b){var c,d,e,f,g=[],h=b.delegateCount,i=a.target;if(h&&i.nodeType&&(!a.button||"click"!==a.type))for(;i!==this;i=i.parentNode||this)if(i.disabled!==!0||"click"!==a.type){for(d=[],c=0;h>c;c++)f=b[c],e=f.selector+" ",void 0===d[e]&&(d[e]=f.needsContext?n(e,this).index(i)>=0:n.find(e,this,null,[i]).length),d[e]&&d.push(f);d.length&&g.push({elem:i,handlers:d})}return h]*)\/>/gi,bb=/<([\w:]+)/,cb=/<|&#?\w+;/,db=/<(?:script|style|link)/i,eb=/checked\s*(?:[^=]|=\s*.checked.)/i,fb=/^$|\/(?:java|ecma)script/i,gb=/^true\/(.*)/,hb=/^\s*\s*$/g,ib={option:[1,""],thead:[1,"","
"],col:[2,"","
"],tr:[2,"","
"],td:[3,"","
"],_default:[0,"",""]};ib.optgroup=ib.option,ib.tbody=ib.tfoot=ib.colgroup=ib.caption=ib.thead,ib.th=ib.td;function jb(a,b){return n.nodeName(a,"table")&&n.nodeName(11!==b.nodeType?b:b.firstChild,"tr")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function kb(a){return a.type=(null!==a.getAttribute("type"))+"/"+a.type,a}function lb(a){var b=gb.exec(a.type);return b?a.type=b[1]:a.removeAttribute("type"),a}function mb(a,b){for(var c=0,d=a.length;d>c;c++)L.set(a[c],"globalEval",!b||L.get(b[c],"globalEval"))}function nb(a,b){var c,d,e,f,g,h,i,j;if(1===b.nodeType){if(L.hasData(a)&&(f=L.access(a),g=L.set(b,f),j=f.events)){delete g.handle,g.events={};for(e in j)for(c=0,d=j[e].length;d>c;c++)n.event.add(b,e,j[e][c])}M.hasData(a)&&(h=M.access(a),i=n.extend({},h),M.set(b,i))}}function ob(a,b){var c=a.getElementsByTagName?a.getElementsByTagName(b||"*"):a.querySelectorAll?a.querySelectorAll(b||"*"):[];return void 0===b||b&&n.nodeName(a,b)?n.merge([a],c):c}function pb(a,b){var c=b.nodeName.toLowerCase();"input"===c&&T.test(a.type)?b.checked=a.checked:("input"===c||"textarea"===c)&&(b.defaultValue=a.defaultValue)}n.extend({clone:function(a,b,c){var d,e,f,g,h=a.cloneNode(!0),i=n.contains(a.ownerDocument,a);if(!(k.noCloneChecked||1!==a.nodeType&&11!==a.nodeType||n.isXMLDoc(a)))for(g=ob(h),f=ob(a),d=0,e=f.length;e>d;d++)pb(f[d],g[d]);if(b)if(c)for(f=f||ob(a),g=g||ob(h),d=0,e=f.length;e>d;d++)nb(f[d],g[d]);else nb(a,h);return g=ob(h,"script"),g.length>0&&mb(g,!i&&ob(a,"script")),h},buildFragment:function(a,b,c,d){for(var e,f,g,h,i,j,k=b.createDocumentFragment(),l=[],m=0,o=a.length;o>m;m++)if(e=a[m],e||0===e)if("object"===n.type(e))n.merge(l,e.nodeType?[e]:e);else if(cb.test(e)){f=f||k.appendChild(b.createElement("div")),g=(bb.exec(e)||["",""])[1].toLowerCase(),h=ib[g]||ib._default,f.innerHTML=h[1]+e.replace(ab,"<$1>")+h[2],j=h[0];while(j--)f=f.lastChild;n.merge(l,f.childNodes),f=k.firstChild,f.textContent=""}else l.push(b.createTextNode(e));k.textContent="",m=0;while(e=l[m++])if((!d||-1===n.inArray(e,d))&&(i=n.contains(e.ownerDocument,e),f=ob(k.appendChild(e),"script"),i&&mb(f),c)){j=0;while(e=f[j++])fb.test(e.type||"")&&c.push(e)}return k},cleanData:function(a){for(var b,c,d,e,f=n.event.special,g=0;void 0!==(c=a[g]);g++){if(n.acceptData(c)&&(e=c[L.expando],e&&(b=L.cache[e]))){if(b.events)for(d in b.events)f[d]?n.event.remove(c,d):n.removeEvent(c,d,b.handle);L.cache[e]&&delete L.cache[e]}delete M.cache[c[M.expando]]}}}),n.fn.extend({text:function(a){return J(this,function(a){return void 0===a?n.text(this):this.empty().each(function(){(1===this.nodeType||11===this.nodeType||9===this.nodeType)&&(this.textContent=a)})},null,a,arguments.length)},append:function(){return this.domManip(arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=jb(this,a);b.appendChild(a)}})},prepend:function(){return this.domManip(arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=jb(this,a);b.insertBefore(a,b.firstChild)}})},before:function(){return this.domManip(arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this)})},after:function(){return this.domManip(arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this.nextSibling)})},remove:function(a,b){for(var c,d=a?n.filter(a,this):this,e=0;null!=(c=d[e]);e++)b||1!==c.nodeType||n.cleanData(ob(c)),c.parentNode&&(b&&n.contains(c.ownerDocument,c)&&mb(ob(c,"script")),c.parentNode.removeChild(c));return this},empty:function(){for(var a,b=0;null!=(a=this[b]);b++)1===a.nodeType&&(n.cleanData(ob(a,!1)),a.textContent="");return this},clone:function(a,b){return a=null==a?!1:a,b=null==b?a:b,this.map(function(){return n.clone(this,a,b)})},html:function(a){return J(this,function(a){var b=this[0]||{},c=0,d=this.length;if(void 0===a&&1===b.nodeType)return b.innerHTML;if("string"==typeof a&&!db.test(a)&&!ib[(bb.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(ab,"<$1>");try{for(;d>c;c++)b=this[c]||{},1===b.nodeType&&(n.cleanData(ob(b,!1)),b.innerHTML=a);b=0}catch(e){}}b&&this.empty().append(a)},null,a,arguments.length)},replaceWith:function(){var a=arguments[0];return this.domManip(arguments,function(b){a=this.parentNode,n.cleanData(ob(this)),a&&a.replaceChild(b,this)}),a&&(a.length||a.nodeType)?this:this.remove()},detach:function(a){return this.remove(a,!0)},domManip:function(a,b){a=e.apply([],a);var c,d,f,g,h,i,j=0,l=this.length,m=this,o=l-1,p=a[0],q=n.isFunction(p);if(q||l>1&&"string"==typeof p&&!k.checkClone&&eb.test(p))return this.each(function(c){var d=m.eq(c);q&&(a[0]=p.call(this,c,d.html())),d.domManip(a,b)});if(l&&(c=n.buildFragment(a,this[0].ownerDocument,!1,this),d=c.firstChild,1===c.childNodes.length&&(c=d),d)){for(f=n.map(ob(c,"script"),kb),g=f.length;l>j;j++)h=c,j!==o&&(h=n.clone(h,!0,!0),g&&n.merge(f,ob(h,"script"))),b.call(this[j],h,j);if(g)for(i=f[f.length-1].ownerDocument,n.map(f,lb),j=0;g>j;j++)h=f[j],fb.test(h.type||"")&&!L.access(h,"globalEval")&&n.contains(i,h)&&(h.src?n._evalUrl&&n._evalUrl(h.src):n.globalEval(h.textContent.replace(hb,"")))}return this}}),n.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){n.fn[a]=function(a){for(var c,d=[],e=n(a),g=e.length-1,h=0;g>=h;h++)c=h===g?this:this.clone(!0),n(e[h])[b](c),f.apply(d,c.get());return this.pushStack(d)}});var qb,rb={};function sb(b,c){var d,e=n(c.createElement(b)).appendTo(c.body),f=a.getDefaultComputedStyle&&(d=a.getDefaultComputedStyle(e[0]))?d.display:n.css(e[0],"display");return e.detach(),f}function tb(a){var b=l,c=rb[a];return c||(c=sb(a,b),"none"!==c&&c||(qb=(qb||n(" - - - - + + + + + + + + + + + + + + + + + + Stack | Opium + + + + + + +
+ +
+ + + diff --git a/games/stack/three.min.js b/games/stack/three.min.js index 4aed8246..c951cef5 100644 --- a/games/stack/three.min.js +++ b/games/stack/three.min.js @@ -1,861 +1,861 @@ -// threejs.org/license -(function(l,oa){"object"===typeof exports&&"undefined"!==typeof module?oa(exports):"function"===typeof define&&define.amd?define(["exports"],oa):oa(l.THREE=l.THREE||{})})(this,function(l){function oa(){}function C(a,b){this.x=a||0;this.y=b||0}function ea(a,b,c,d,e,f,g,h,k,m){Object.defineProperty(this,"id",{value:Oe++});this.uuid=Q.generateUUID();this.name="";this.image=void 0!==a?a:ea.DEFAULT_IMAGE;this.mipmaps=[];this.mapping=void 0!==b?b:ea.DEFAULT_MAPPING;this.wrapS=void 0!==c?c:1001;this.wrapT= -void 0!==d?d:1001;this.magFilter=void 0!==e?e:1006;this.minFilter=void 0!==f?f:1008;this.anisotropy=void 0!==k?k:1;this.format=void 0!==g?g:1023;this.type=void 0!==h?h:1009;this.offset=new C(0,0);this.repeat=new C(1,1);this.generateMipmaps=!0;this.premultiplyAlpha=!1;this.flipY=!0;this.unpackAlignment=4;this.encoding=void 0!==m?m:3E3;this.version=0;this.onUpdate=null}function ga(a,b,c,d){this.x=a||0;this.y=b||0;this.z=c||0;this.w=void 0!==d?d:1}function Db(a,b,c){this.uuid=Q.generateUUID();this.width= -a;this.height=b;this.scissor=new ga(0,0,a,b);this.scissorTest=!1;this.viewport=new ga(0,0,a,b);c=c||{};void 0===c.minFilter&&(c.minFilter=1006);this.texture=new ea(void 0,void 0,c.wrapS,c.wrapT,c.magFilter,c.minFilter,c.format,c.type,c.anisotropy,c.encoding);this.depthBuffer=void 0!==c.depthBuffer?c.depthBuffer:!0;this.stencilBuffer=void 0!==c.stencilBuffer?c.stencilBuffer:!0;this.depthTexture=void 0!==c.depthTexture?c.depthTexture:null}function Eb(a,b,c){Db.call(this,a,b,c);this.activeMipMapLevel= -this.activeCubeFace=0}function da(a,b,c,d){this._x=a||0;this._y=b||0;this._z=c||0;this._w=void 0!==d?d:1}function q(a,b,c){this.x=a||0;this.y=b||0;this.z=c||0}function H(){this.elements=new Float32Array([1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]);0= -d||0 0 ) {\nfloat depth = gl_FragCoord.z / gl_FragCoord.w;\nfloat fogFactor = 0.0;\nif ( fogType == 1 ) {\nfogFactor = smoothstep( fogNear, fogFar, depth );\n} else {\nconst float LOG2 = 1.442695;\nfogFactor = exp2( - fogDensity * fogDensity * depth * depth * LOG2 );\nfogFactor = 1.0 - clamp( fogFactor, 0.0, 1.0 );\n}\ngl_FragColor = mix( gl_FragColor, vec4( fogColor, gl_FragColor.w ), fogFactor );\n}\n}"].join("\n")); -z.compileShader(P);z.compileShader(R);z.attachShader(O,P);z.attachShader(O,R);z.linkProgram(O);K=O;t=z.getAttribLocation(K,"position");v=z.getAttribLocation(K,"uv");c=z.getUniformLocation(K,"uvOffset");d=z.getUniformLocation(K,"uvScale");e=z.getUniformLocation(K,"rotation");f=z.getUniformLocation(K,"scale");g=z.getUniformLocation(K,"color");h=z.getUniformLocation(K,"map");k=z.getUniformLocation(K,"opacity");m=z.getUniformLocation(K,"modelViewMatrix");x=z.getUniformLocation(K,"projectionMatrix");p= -z.getUniformLocation(K,"fogType");n=z.getUniformLocation(K,"fogDensity");r=z.getUniformLocation(K,"fogNear");w=z.getUniformLocation(K,"fogFar");l=z.getUniformLocation(K,"fogColor");F=z.getUniformLocation(K,"alphaTest");O=document.createElementNS("http://www.w3.org/1999/xhtml","canvas");O.width=8;O.height=8;P=O.getContext("2d");P.fillStyle="white";P.fillRect(0,0,8,8);la=new ea(O);la.needsUpdate=!0}z.useProgram(K);A.initAttributes();A.enableAttribute(t);A.enableAttribute(v);A.disableUnusedAttributes(); -A.disable(z.CULL_FACE);A.enable(z.BLEND);z.bindBuffer(z.ARRAY_BUFFER,I);z.vertexAttribPointer(t,2,z.FLOAT,!1,16,0);z.vertexAttribPointer(v,2,z.FLOAT,!1,16,8);z.bindBuffer(z.ELEMENT_ARRAY_BUFFER,E);z.uniformMatrix4fv(x,!1,Na.projectionMatrix.elements);A.activeTexture(z.TEXTURE0);z.uniform1i(h,0);P=O=0;(R=q.fog)?(z.uniform3f(l,R.color.r,R.color.g,R.color.b),R.isFog?(z.uniform1f(r,R.near),z.uniform1f(w,R.far),z.uniform1i(p,1),P=O=1):R.isFogExp2&&(z.uniform1f(n,R.density),z.uniform1i(p,2),P=O=2)):(z.uniform1i(p, -0),P=O=0);for(var R=0,T=b.length;R/g,function(a,c){var d=Z[c];if(void 0===d)throw Error("Can not resolve #include <"+c+">");return Md(d)})}function De(a){return a.replace(/for \( int i \= (\d+)\; i < (\d+)\; i \+\+ \) \{([\s\S]+?)(?=\})\}/g,function(a,c,d,e){a="";for(c=parseInt(c);c< -parseInt(d);c++)a+=e.replace(/\[ i \]/g,"[ "+c+" ]");return a})}function zf(a,b,c,d){var e=a.context,f=c.extensions,g=c.defines,h=c.__webglShader.vertexShader,k=c.__webglShader.fragmentShader,m="SHADOWMAP_TYPE_BASIC";1===d.shadowMapType?m="SHADOWMAP_TYPE_PCF":2===d.shadowMapType&&(m="SHADOWMAP_TYPE_PCF_SOFT");var x="ENVMAP_TYPE_CUBE",p="ENVMAP_MODE_REFLECTION",n="ENVMAP_BLENDING_MULTIPLY";if(d.envMap){switch(c.envMap.mapping){case 301:case 302:x="ENVMAP_TYPE_CUBE";break;case 306:case 307:x="ENVMAP_TYPE_CUBE_UV"; -break;case 303:case 304:x="ENVMAP_TYPE_EQUIREC";break;case 305:x="ENVMAP_TYPE_SPHERE"}switch(c.envMap.mapping){case 302:case 304:p="ENVMAP_MODE_REFRACTION"}switch(c.combine){case 0:n="ENVMAP_BLENDING_MULTIPLY";break;case 1:n="ENVMAP_BLENDING_MIX";break;case 2:n="ENVMAP_BLENDING_ADD"}}var r=0b||a.height>b){var c=b/Math.max(a.width,a.height),d=document.createElementNS("http://www.w3.org/1999/xhtml","canvas");d.width=Math.floor(a.width*c);d.height=Math.floor(a.height*c);d.getContext("2d").drawImage(a,0,0,a.width,a.height,0,0,d.width,d.height);console.warn("THREE.WebGLRenderer: image is too big ("+ -a.width+"x"+a.height+"). Resized to "+d.width+"x"+d.height,a);return d}return a}function k(a){return Q.isPowerOfTwo(a.width)&&Q.isPowerOfTwo(a.height)}function m(b){return 1003===b||1004===b||1005===b?a.NEAREST:a.LINEAR}function x(b){b=b.target;b.removeEventListener("dispose",x);a:{var c=d.get(b);if(b.image&&c.__image__webglTextureCube)a.deleteTexture(c.__image__webglTextureCube);else{if(void 0===c.__webglInit)break a;a.deleteTexture(c.__webglTexture)}d["delete"](b)}q.textures--}function p(b){b=b.target; -b.removeEventListener("dispose",p);var c=d.get(b),e=d.get(b.texture);if(b){void 0!==e.__webglTexture&&a.deleteTexture(e.__webglTexture);b.depthTexture&&b.depthTexture.dispose();if(b.isWebGLRenderTargetCube)for(e=0;6>e;e++)a.deleteFramebuffer(c.__webglFramebuffer[e]),c.__webglDepthbuffer&&a.deleteRenderbuffer(c.__webglDepthbuffer[e]);else a.deleteFramebuffer(c.__webglFramebuffer),c.__webglDepthbuffer&&a.deleteRenderbuffer(c.__webglDepthbuffer);d["delete"](b.texture);d["delete"](b)}q.textures--}function n(b, -g){var m=d.get(b);if(0w;w++)l[w]=n||p?p?b.image[w].image:b.image[w]:h(b.image[w],e.maxCubemapSize);var u=k(l[0]),t=f(b.format),ca=f(b.type);r(a.TEXTURE_CUBE_MAP,b,u);for(w=0;6>w;w++)if(n)for(var y,C=l[w].mipmaps,D=0,O=C.length;Dm;m++)e.__webglFramebuffer[m]=a.createFramebuffer()}else e.__webglFramebuffer= -a.createFramebuffer();if(g){c.bindTexture(a.TEXTURE_CUBE_MAP,f.__webglTexture);r(a.TEXTURE_CUBE_MAP,b.texture,h);for(m=0;6>m;m++)l(e.__webglFramebuffer[m],b,a.COLOR_ATTACHMENT0,a.TEXTURE_CUBE_MAP_POSITIVE_X+m);b.texture.generateMipmaps&&h&&a.generateMipmap(a.TEXTURE_CUBE_MAP);c.bindTexture(a.TEXTURE_CUBE_MAP,null)}else c.bindTexture(a.TEXTURE_2D,f.__webglTexture),r(a.TEXTURE_2D,b.texture,h),l(e.__webglFramebuffer,b,a.COLOR_ATTACHMENT0,a.TEXTURE_2D),b.texture.generateMipmaps&&h&&a.generateMipmap(a.TEXTURE_2D), -c.bindTexture(a.TEXTURE_2D,null);if(b.depthBuffer){e=d.get(b);f=!0===b.isWebGLRenderTargetCube;if(b.depthTexture){if(f)throw Error("target.depthTexture not supported in Cube render targets");if(b&&b.isWebGLRenderTargetCube)throw Error("Depth Texture with cube render targets is not supported!");a.bindFramebuffer(a.FRAMEBUFFER,e.__webglFramebuffer);if(!b.depthTexture||!b.depthTexture.isDepthTexture)throw Error("renderTarget.depthTexture must be an instance of THREE.DepthTexture");d.get(b.depthTexture).__webglTexture&& -b.depthTexture.image.width===b.width&&b.depthTexture.image.height===b.height||(b.depthTexture.image.width=b.width,b.depthTexture.image.height=b.height,b.depthTexture.needsUpdate=!0);n(b.depthTexture,0);e=d.get(b.depthTexture).__webglTexture;if(1026===b.depthTexture.format)a.framebufferTexture2D(a.FRAMEBUFFER,a.DEPTH_ATTACHMENT,a.TEXTURE_2D,e,0);else if(1027===b.depthTexture.format)a.framebufferTexture2D(a.FRAMEBUFFER,a.DEPTH_STENCIL_ATTACHMENT,a.TEXTURE_2D,e,0);else throw Error("Unknown depthTexture format"); -}else if(f)for(e.__webglDepthbuffer=[],f=0;6>f;f++)a.bindFramebuffer(a.FRAMEBUFFER,e.__webglFramebuffer[f]),e.__webglDepthbuffer[f]=a.createRenderbuffer(),u(e.__webglDepthbuffer[f],b);else a.bindFramebuffer(a.FRAMEBUFFER,e.__webglFramebuffer),e.__webglDepthbuffer=a.createRenderbuffer(),u(e.__webglDepthbuffer,b);a.bindFramebuffer(a.FRAMEBUFFER,null)}};this.updateRenderTargetMipmap=function(b){var e=b.texture;e.generateMipmaps&&k(b)&&1003!==e.minFilter&&1006!==e.minFilter&&(b=b&&b.isWebGLRenderTargetCube? -a.TEXTURE_CUBE_MAP:a.TEXTURE_2D,e=d.get(e).__webglTexture,c.bindTexture(b,e),a.generateMipmap(b),c.bindTexture(b,null))}}function Ff(){var a={};return{get:function(b){b=b.uuid;var c=a[b];void 0===c&&(c={},a[b]=c);return c},"delete":function(b){delete a[b.uuid]},clear:function(){a={}}}}function Gf(a,b,c){function d(b,c,d){var e=new Uint8Array(4),f=a.createTexture();a.bindTexture(b,f);a.texParameteri(b,a.TEXTURE_MIN_FILTER,a.NEAREST);a.texParameteri(b,a.TEXTURE_MAG_FILTER,a.NEAREST);for(b=0;b=ma.maxTextures&&console.warn("WebGLRenderer: trying to use "+a+" texture units while this GPU supports only "+ma.maxTextures);ea+=1;return a};this.setTexture2D=function(){var a=!1;return function(b,c){b&&b.isWebGLRenderTarget&& -(a||(console.warn("THREE.WebGLRenderer.setTexture2D: don't use render targets as textures. Use their .texture property instead."),a=!0),b=b.texture);va.setTexture2D(b,c)}}();this.setTexture=function(){var a=!1;return function(b,c){a||(console.warn("THREE.WebGLRenderer: .setTexture is deprecated, use setTexture2D instead."),a=!0);va.setTexture2D(b,c)}}();this.setTextureCube=function(){var a=!1;return function(b,c){b&&b.isWebGLRenderTargetCube&&(a||(console.warn("THREE.WebGLRenderer.setTextureCube: don't use cube render targets as textures. Use their .texture property instead."), -a=!0),b=b.texture);b&&b.isCubeTexture||Array.isArray(b.image)&&6===b.image.length?va.setTextureCube(b,c):va.setTextureCubeDynamic(b,c)}}();this.getCurrentRenderTarget=function(){return V};this.setRenderTarget=function(a){(V=a)&&void 0===ha.get(a).__webglFramebuffer&&va.setupRenderTarget(a);var b=a&&a.isWebGLRenderTargetCube,c;a?(c=ha.get(a),c=b?c.__webglFramebuffer[a.activeCubeFace]:c.__webglFramebuffer,X.copy(a.scissor),Ta=a.scissorTest,Z.copy(a.viewport)):(c=null,X.copy(fa).multiplyScalar(Sa),Ta= -ka,Z.copy(ia).multiplyScalar(Sa));S!==c&&(B.bindFramebuffer(B.FRAMEBUFFER,c),S=c);Y.scissor(X);Y.setScissorTest(Ta);Y.viewport(Z);b&&(b=ha.get(a.texture),B.framebufferTexture2D(B.FRAMEBUFFER,B.COLOR_ATTACHMENT0,B.TEXTURE_CUBE_MAP_POSITIVE_X+a.activeCubeFace,b.__webglTexture,a.activeMipMapLevel))};this.readRenderTargetPixels=function(a,b,c,d,e,f){if(!1===(a&&a.isWebGLRenderTarget))console.error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not THREE.WebGLRenderTarget.");else{var g=ha.get(a).__webglFramebuffer; -if(g){var h=!1;g!==S&&(B.bindFramebuffer(B.FRAMEBUFFER,g),h=!0);try{var k=a.texture,m=k.format,n=k.type;1023!==m&&t(m)!==B.getParameter(B.IMPLEMENTATION_COLOR_READ_FORMAT)?console.error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not in RGBA or implementation defined format."):1009===n||t(n)===B.getParameter(B.IMPLEMENTATION_COLOR_READ_TYPE)||1015===n&&(ja.get("OES_texture_float")||ja.get("WEBGL_color_buffer_float"))||1016===n&&ja.get("EXT_color_buffer_half_float")?B.checkFramebufferStatus(B.FRAMEBUFFER)=== -B.FRAMEBUFFER_COMPLETE?0<=b&&b<=a.width-d&&0<=c&&c<=a.height-e&&B.readPixels(b,c,d,e,t(m),t(n),f):console.error("THREE.WebGLRenderer.readRenderTargetPixels: readPixels from renderTarget failed. Framebuffer not complete."):console.error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not in UnsignedByteType or implementation defined type.")}finally{h&&B.bindFramebuffer(B.FRAMEBUFFER,S)}}}}}function Ib(a,b){this.name="";this.color=new N(a);this.density=void 0!==b?b:2.5E-4}function Jb(a, -b,c){this.name="";this.color=new N(a);this.near=void 0!==b?b:1;this.far=void 0!==c?c:1E3}function jb(){G.call(this);this.type="Scene";this.overrideMaterial=this.fog=this.background=null;this.autoUpdate=!0}function Od(a,b,c,d,e){G.call(this);this.lensFlares=[];this.positionScreen=new q;this.customUpdateCallback=void 0;void 0!==a&&this.add(a,b,c,d,e)}function kb(a){W.call(this);this.type="SpriteMaterial";this.color=new N(16777215);this.map=null;this.rotation=0;this.lights=this.fog=!1;this.setValues(a)} -function zc(a){G.call(this);this.type="Sprite";this.material=void 0!==a?a:new kb}function Ac(){G.call(this);this.type="LOD";Object.defineProperties(this,{levels:{enumerable:!0,value:[]}})}function hd(a,b,c){this.useVertexTexture=void 0!==c?c:!0;this.identityMatrix=new H;a=a||[];this.bones=a.slice(0);this.useVertexTexture?(a=Math.sqrt(4*this.bones.length),a=Q.nextPowerOfTwo(Math.ceil(a)),this.boneTextureHeight=this.boneTextureWidth=a=Math.max(a,4),this.boneMatrices=new Float32Array(this.boneTextureWidth* -this.boneTextureHeight*4),this.boneTexture=new db(this.boneMatrices,this.boneTextureWidth,this.boneTextureHeight,1023,1015)):this.boneMatrices=new Float32Array(16*this.bones.length);if(void 0===b)this.calculateInverses();else if(this.bones.length===b.length)this.boneInverses=b.slice(0);else for(console.warn("THREE.Skeleton bonInverses is the wrong length."),this.boneInverses=[],b=0,a=this.bones.length;b=a.HAVE_CURRENT_DATA&&(x.needsUpdate=!0)}ea.call(this,a,b,c,d,e,f,g,h,k);this.generateMipmaps=!1;var x=this;m()}function Lb(a,b,c,d,e,f,g,h,k,m,x,p){ea.call(this,null,f,g,h,k,m,d,e,x,p);this.image={width:b,height:c};this.mipmaps=a;this.generateMipmaps=this.flipY=!1}function ld(a,b,c,d,e,f,g,h,k){ea.call(this,a,b,c,d,e,f,g,h,k);this.needsUpdate=!0}function Cc(a,b,c,d,e,f,g,h,k,m){m=void 0!==m?m:1026;if(1026!==m&&1027!== -m)throw Error("DepthTexture format must be either THREE.DepthFormat or THREE.DepthStencilFormat");void 0===c&&1026===m&&(c=1012);void 0===c&&1027===m&&(c=1020);ea.call(this,null,d,e,f,g,h,m,c,k);this.image={width:a,height:b};this.magFilter=void 0!==g?g:1003;this.minFilter=void 0!==h?h:1003;this.generateMipmaps=this.flipY=!1}function Mb(a){function b(a,b){return a-b}D.call(this);var c=[0,0],d={},e=["a","b","c"];if(a&&a.isGeometry){var f=a.vertices,g=a.faces,h=0,k=new Uint32Array(6*g.length);a=0;for(var m= -g.length;ap;p++){c[0]=x[e[p]];c[1]=x[e[(p+1)%3]];c.sort(b);var n=c.toString();void 0===d[n]&&(k[2*h]=c[0],k[2*h+1]=c[1],d[n]=!0,h++)}c=new Float32Array(6*h);a=0;for(m=h;ap;p++)d=f[k[2*a+p]],h=6*a+3*p,c[h+0]=d.x,c[h+1]=d.y,c[h+2]=d.z;this.addAttribute("position",new y(c,3))}else if(a&&a.isBufferGeometry){if(null!==a.index){m=a.index.array;f=a.attributes.position;e=a.groups;h=0;0===e.length&&a.addGroup(0,m.length);k=new Uint32Array(2*m.length);g=0;for(x= -e.length;gp;p++)c[0]=m[a+p],c[1]=m[a+(p+1)%3],c.sort(b),n=c.toString(),void 0===d[n]&&(k[2*h]=c[0],k[2*h+1]=c[1],d[n]=!0,h++)}c=new Float32Array(6*h);a=0;for(m=h;ap;p++)h=6*a+3*p,d=k[2*a+p],c[h+0]=f.getX(d),c[h+1]=f.getY(d),c[h+2]=f.getZ(d)}else for(f=a.attributes.position.array,h=f.length/3,k=h/3,c=new Float32Array(6*h),a=0,m=k;ap;p++)h=18*a+6*p,k=9*a+3*p,c[h+0]=f[k],c[h+1]=f[k+1],c[h+2]=f[k+ -2],d=9*a+(p+1)%3*3,c[h+3]=f[d],c[h+4]=f[d+1],c[h+5]=f[d+2];this.addAttribute("position",new y(c,3))}}function Nb(a,b,c){D.call(this);this.type="ParametricBufferGeometry";this.parameters={func:a,slices:b,stacks:c};var d=[],e=[],f,g,h,k,m,x=b+1;for(f=0;f<=c;f++)for(m=f/c,g=0;g<=b;g++)k=g/b,h=a(k,m),d.push(h.x,h.y,h.z),e.push(k,m);a=[];var p;for(f=0;fd&&1===a.x&&(k[b]=a.x-1);0===c.x&&0===c.z&&(k[b]=d/2/Math.PI+.5)}D.call(this);this.type="PolyhedronBufferGeometry";this.parameters= -{vertices:a,indices:b,radius:c,detail:d};c=c||1;var h=[],k=[];(function(a){for(var c=new q,d=new q,g=new q,h=0;he&&(.2>b&&(k[a+0]+=1),.2>c&&(k[a+2]+=1),.2>d&&(k[a+4]+=1))})();this.addAttribute("position",new X(h,3));this.addAttribute("normal",new X(h.slice(),3));this.addAttribute("uv",new X(k,2));this.normalizeNormals();this.boundingSphere= -new Fa(new q,c)}function Ob(a,b){xa.call(this,[1,1,1,-1,-1,1,-1,1,-1,1,-1,-1],[2,1,0,0,3,2,1,3,0,2,3,1],a,b);this.type="TetrahedronBufferGeometry";this.parameters={radius:a,detail:b}}function Ec(a,b){S.call(this);this.type="TetrahedronGeometry";this.parameters={radius:a,detail:b};this.fromBufferGeometry(new Ob(a,b));this.mergeVertices()}function lb(a,b){xa.call(this,[1,0,0,-1,0,0,0,1,0,0,-1,0,0,0,1,0,0,-1],[0,2,4,0,4,3,0,3,5,0,5,2,1,2,5,1,5,3,1,3,4,1,4,2],a,b);this.type="OctahedronBufferGeometry"; -this.parameters={radius:a,detail:b}}function Fc(a,b){S.call(this);this.type="OctahedronGeometry";this.parameters={radius:a,detail:b};this.fromBufferGeometry(new lb(a,b));this.mergeVertices()}function Pb(a,b){var c=(1+Math.sqrt(5))/2;xa.call(this,[-1,c,0,1,c,0,-1,-c,0,1,-c,0,0,-1,c,0,1,c,0,-1,-c,0,1,-c,c,0,-1,c,0,1,-c,0,-1,-c,0,1],[0,11,5,0,5,1,0,1,7,0,7,10,0,10,11,1,5,9,5,11,4,11,10,2,10,7,6,7,1,8,3,9,4,3,4,2,3,2,6,3,6,8,3,8,9,4,9,5,2,4,11,6,2,10,8,6,7,9,8,1],a,b);this.type="IcosahedronBufferGeometry"; -this.parameters={radius:a,detail:b}}function Gc(a,b){S.call(this);this.type="IcosahedronGeometry";this.parameters={radius:a,detail:b};this.fromBufferGeometry(new Pb(a,b));this.mergeVertices()}function Qb(a,b){var c=(1+Math.sqrt(5))/2,d=1/c;xa.call(this,[-1,-1,-1,-1,-1,1,-1,1,-1,-1,1,1,1,-1,-1,1,-1,1,1,1,-1,1,1,1,0,-d,-c,0,-d,c,0,d,-c,0,d,c,-d,-c,0,-d,c,0,d,-c,0,d,c,0,-c,0,-d,c,0,-d,-c,0,d,c,0,d],[3,11,7,3,7,15,3,15,13,7,19,17,7,17,6,7,6,15,17,4,8,17,8,10,17,10,6,8,0,16,8,16,2,8,2,10,0,12,1,0,1,18, -0,18,16,6,10,2,6,2,13,6,13,15,2,16,18,2,18,3,2,3,13,18,1,9,18,9,11,18,11,3,4,14,12,4,12,0,4,0,8,11,9,5,11,5,19,11,19,7,19,5,14,19,14,4,19,4,17,1,12,14,1,14,5,1,5,9],a,b);this.type="DodecahedronBufferGeometry";this.parameters={radius:a,detail:b}}function Hc(a,b){S.call(this);this.type="DodecahedronGeometry";this.parameters={radius:a,detail:b};this.fromBufferGeometry(new Qb(a,b));this.mergeVertices()}function Ic(a,b,c,d){S.call(this);this.type="PolyhedronGeometry";this.parameters={vertices:a,indices:b, -radius:c,detail:d};this.fromBufferGeometry(new xa(a,b,c,d));this.mergeVertices()}function Rb(a,b,c,d,e){function f(e){var f=a.getPointAt(e/b),m=g.normals[e];e=g.binormals[e];for(p=0;p<=d;p++){var x=p/d*Math.PI*2,l=Math.sin(x),x=-Math.cos(x);k.x=x*m.x+l*e.x;k.y=x*m.y+l*e.y;k.z=x*m.z+l*e.z;k.normalize();r.push(k.x,k.y,k.z);h.x=f.x+c*k.x;h.y=f.y+c*k.y;h.z=f.z+c*k.z;n.push(h.x,h.y,h.z)}}D.call(this);this.type="TubeBufferGeometry";this.parameters={path:a,tubularSegments:b,radius:c,radialSegments:d,closed:e}; -b=b||64;c=c||1;d=d||8;e=e||!1;var g=a.computeFrenetFrames(b,e);this.tangents=g.tangents;this.normals=g.normals;this.binormals=g.binormals;var h=new q,k=new q,m=new C,x,p,n=[],r=[],l=[],u=[];for(x=0;xn;n++){e[0]=p[g[n]];e[1]=p[g[(n+1)%3]];e.sort(c);var r=e.toString();void 0===f[r]?f[r]={vert1:e[0],vert2:e[1],face1:m,face2:void 0}:f[r].face2=m}e=[];for(r in f)if(g=f[r],void 0===g.face2||h[g.face1].normal.dot(h[g.face2].normal)<=d)m=k[g.vert1],e.push(m.x),e.push(m.y),e.push(m.z),m=k[g.vert2],e.push(m.x),e.push(m.y),e.push(m.z);this.addAttribute("position",new X(e,3))}function Wa(a,b,c,d,e,f,g,h){function k(c){var e,f,k,n=new C,p=new q,l=0,x=!0=== -c?a:b,M=!0===c?1:-1;f=t;for(e=1;e<=d;e++)w.setXYZ(t,0,z*M,0),u.setXYZ(t,0,M,0),n.x=.5,n.y=.5,F.setXY(t,n.x,n.y),t++;k=t;for(e=0;e<=d;e++){var y=e/d*h+g,D=Math.cos(y),y=Math.sin(y);p.x=x*y;p.y=z*M;p.z=x*D;w.setXYZ(t,p.x,p.y,p.z);u.setXYZ(t,0,M,0);n.x=.5*D+.5;n.y=.5*y*M+.5;F.setXY(t,n.x,n.y);t++}for(e=0;ethis.duration&&this.resetDuration();this.optimize()}function Ad(a){this.manager= -void 0!==a?a:va;this.textures={}}function Sd(a){this.manager=void 0!==a?a:va}function wb(){this.onLoadStart=function(){};this.onLoadProgress=function(){};this.onLoadComplete=function(){}}function Td(a){"boolean"===typeof a&&(console.warn("THREE.JSONLoader: showStatus parameter has been removed from constructor."),a=void 0);this.manager=void 0!==a?a:va;this.withCredentials=!1}function Fe(a){this.manager=void 0!==a?a:va;this.texturePath=""}function wa(){}function Qa(a,b){this.v1=a;this.v2=b}function Yc(){this.curves= -[];this.autoClose=!1}function Xa(a,b,c,d,e,f,g,h){this.aX=a;this.aY=b;this.xRadius=c;this.yRadius=d;this.aStartAngle=e;this.aEndAngle=f;this.aClockwise=g;this.aRotation=h||0}function xb(a){this.points=void 0===a?[]:a}function yb(a,b,c,d){this.v0=a;this.v1=b;this.v2=c;this.v3=d}function zb(a,b,c){this.v0=a;this.v1=b;this.v2=c}function Ab(){Zc.apply(this,arguments);this.holes=[]}function Zc(a){Yc.call(this);this.currentPoint=new C;a&&this.fromPoints(a)}function Ud(){this.subPaths=[];this.currentPath= -null}function Vd(a){this.data=a}function Ge(a){this.manager=void 0!==a?a:va}function Wd(a){this.manager=void 0!==a?a:va}function Xd(a,b,c,d){na.call(this,a,b);this.type="RectAreaLight";this.position.set(0,1,0);this.updateMatrix();this.width=void 0!==c?c:10;this.height=void 0!==d?d:10}function He(){this.type="StereoCamera";this.aspect=1;this.eyeSep=.064;this.cameraL=new Ha;this.cameraL.layers.enable(1);this.cameraL.matrixAutoUpdate=!1;this.cameraR=new Ha;this.cameraR.layers.enable(2);this.cameraR.matrixAutoUpdate= -!1}function Bd(a,b,c){G.call(this);this.type="CubeCamera";var d=new Ha(90,1,a,b);d.up.set(0,-1,0);d.lookAt(new q(1,0,0));this.add(d);var e=new Ha(90,1,a,b);e.up.set(0,-1,0);e.lookAt(new q(-1,0,0));this.add(e);var f=new Ha(90,1,a,b);f.up.set(0,0,1);f.lookAt(new q(0,1,0));this.add(f);var g=new Ha(90,1,a,b);g.up.set(0,0,-1);g.lookAt(new q(0,-1,0));this.add(g);var h=new Ha(90,1,a,b);h.up.set(0,-1,0);h.lookAt(new q(0,0,1));this.add(h);var k=new Ha(90,1,a,b);k.up.set(0,-1,0);k.lookAt(new q(0,0,-1));this.add(k); -this.renderTarget=new Eb(c,c,{format:1022,magFilter:1006,minFilter:1006});this.updateCubeMap=function(a,b){null===this.parent&&this.updateMatrixWorld();var c=this.renderTarget,n=c.texture.generateMipmaps;c.texture.generateMipmaps=!1;c.activeCubeFace=0;a.render(b,d,c);c.activeCubeFace=1;a.render(b,e,c);c.activeCubeFace=2;a.render(b,f,c);c.activeCubeFace=3;a.render(b,g,c);c.activeCubeFace=4;a.render(b,h,c);c.texture.generateMipmaps=n;c.activeCubeFace=5;a.render(b,k,c);a.setRenderTarget(null)}}function Yd(){G.call(this); -this.type="AudioListener";this.context=Zd.getContext();this.gain=this.context.createGain();this.gain.connect(this.context.destination);this.filter=null}function ec(a){G.call(this);this.type="Audio";this.context=a.context;this.gain=this.context.createGain();this.gain.connect(a.getInput());this.autoplay=!1;this.buffer=null;this.loop=!1;this.startTime=0;this.playbackRate=1;this.isPlaying=!1;this.hasPlaybackControl=!0;this.sourceType="empty";this.filters=[]}function $d(a){ec.call(this,a);this.panner= -this.context.createPanner();this.panner.connect(this.gain)}function ae(a,b){this.analyser=a.context.createAnalyser();this.analyser.fftSize=void 0!==b?b:2048;this.data=new Uint8Array(this.analyser.frequencyBinCount);a.getOutput().connect(this.analyser)}function Cd(a,b,c){this.binding=a;this.valueSize=c;a=Float64Array;switch(b){case "quaternion":b=this._slerp;break;case "string":case "bool":a=Array;b=this._select;break;default:b=this._lerp}this.buffer=new a(4*c);this._mixBufferRegion=b;this.referenceCount= -this.useCount=this.cumulativeWeight=0}function ka(a,b,c){this.path=b;this.parsedPath=c||ka.parseTrackName(b);this.node=ka.findNode(a,this.parsedPath.nodeName)||a;this.rootNode=a}function be(a){this.uuid=Q.generateUUID();this._objects=Array.prototype.slice.call(arguments);this.nCachedObjects_=0;var b={};this._indicesByUUID=b;for(var c=0,d=arguments.length;c!==d;++c)b[arguments[c].uuid]=c;this._paths=[];this._parsedPaths=[];this._bindings=[];this._bindingsIndicesByPath={};var e=this;this.stats={objects:{get total(){return e._objects.length}, -get inUse(){return this.total-e.nCachedObjects_}},get bindingsPerObject(){return e._bindings.length}}}function ce(a,b,c){this._mixer=a;this._clip=b;this._localRoot=c||null;a=b.tracks;b=a.length;c=Array(b);for(var d={endingStart:2400,endingEnd:2400},e=0;e!==b;++e){var f=a[e].createInterpolant(null);c[e]=f;f.settings=d}this._interpolantSettings=d;this._interpolants=c;this._propertyBindings=Array(b);this._weightInterpolant=this._timeScaleInterpolant=this._byClipCacheIndex=this._cacheIndex=null;this.loop= -2201;this._loopCount=-1;this._startTime=null;this.time=0;this._effectiveWeight=this.weight=this._effectiveTimeScale=this.timeScale=1;this.repetitions=Infinity;this.paused=!1;this.enabled=!0;this.clampWhenFinished=!1;this.zeroSlopeAtEnd=this.zeroSlopeAtStart=!0}function de(a){this._root=a;this._initMemoryManager();this.time=this._accuIndex=0;this.timeScale=1}function Dd(a,b){"string"===typeof a&&(console.warn("THREE.Uniform: Type parameter is no longer needed."),a=b);this.value=a}function Bb(){D.call(this); -this.type="InstancedBufferGeometry";this.maxInstancedCount=void 0}function ee(a,b,c,d){this.uuid=Q.generateUUID();this.data=a;this.itemSize=b;this.offset=c;this.normalized=!0===d}function fc(a,b){this.uuid=Q.generateUUID();this.array=a;this.stride=b;this.count=void 0!==a?a.length/b:0;this.dynamic=!1;this.updateRange={offset:0,count:-1};this.onUploadCallback=function(){};this.version=0}function gc(a,b,c){fc.call(this,a,b);this.meshPerAttribute=c||1}function hc(a,b,c){y.call(this,a,b);this.meshPerAttribute= -c||1}function fe(a,b,c,d){this.ray=new bb(a,b);this.near=c||0;this.far=d||Infinity;this.params={Mesh:{},Line:{},LOD:{},Points:{threshold:1},Sprite:{}};Object.defineProperties(this.params,{PointCloud:{get:function(){console.warn("THREE.Raycaster: params.PointCloud has been renamed to params.Points.");return this.Points}}})}function Ie(a,b){return a.distance-b.distance}function ge(a,b,c,d){if(!1!==a.visible&&(a.raycast(b,c),!0===d)){a=a.children;d=0;for(var e=a.length;dc;c++,d++){var e=c/32*Math.PI*2,f=d/32*Math.PI*2;b.push(Math.cos(e),Math.sin(e),1,Math.cos(f),Math.sin(f),1)}a.addAttribute("position",new X(b,3));b=new ia({fog:!1});this.cone=new fa(a,b);this.add(this.cone);this.update()}function jc(a){this.bones=this.getBoneList(a);for(var b=new D,c=[],d=[],e=new N(0,0,1),f=new N(0,1,0),g=0;ga?-1:0e;e++)8===e||13===e||18===e||23===e?b[e]="-":14===e?b[e]="4": -(2>=c&&(c=33554432+16777216*Math.random()|0),d=c&15,c>>=4,b[e]=a[19===e?d&3|8:d]);return b.join("")}}(),clamp:function(a,b,c){return Math.max(b,Math.min(c,a))},euclideanModulo:function(a,b){return(a%b+b)%b},mapLinear:function(a,b,c,d,e){return d+(a-b)*(e-d)/(c-b)},lerp:function(a,b,c){return(1-c)*a+c*b},smoothstep:function(a,b,c){if(a<=b)return 0;if(a>=c)return 1;a=(a-b)/(c-b);return a*a*(3-2*a)},smootherstep:function(a,b,c){if(a<=b)return 0;if(a>=c)return 1;a=(a-b)/(c-b);return a*a*a*(a*(6*a-15)+ -10)},randInt:function(a,b){return a+Math.floor(Math.random()*(b-a+1))},randFloat:function(a,b){return a+Math.random()*(b-a)},randFloatSpread:function(a){return a*(.5-Math.random())},degToRad:function(a){return a*Q.DEG2RAD},radToDeg:function(a){return a*Q.RAD2DEG},isPowerOfTwo:function(a){return 0===(a&a-1)&&0!==a},nearestPowerOfTwo:function(a){return Math.pow(2,Math.round(Math.log(a)/Math.LN2))},nextPowerOfTwo:function(a){a--;a|=a>>1;a|=a>>2;a|=a>>4;a|=a>>8;a|=a>>16;a++;return a}};C.prototype={constructor:C, -isVector2:!0,get width(){return this.x},set width(a){this.x=a},get height(){return this.y},set height(a){this.y=a},set:function(a,b){this.x=a;this.y=b;return this},setScalar:function(a){this.y=this.x=a;return this},setX:function(a){this.x=a;return this},setY:function(a){this.y=a;return this},setComponent:function(a,b){switch(a){case 0:this.x=b;break;case 1:this.y=b;break;default:throw Error("index is out of range: "+a);}return this},getComponent:function(a){switch(a){case 0:return this.x;case 1:return this.y; -default:throw Error("index is out of range: "+a);}},clone:function(){return new this.constructor(this.x,this.y)},copy:function(a){this.x=a.x;this.y=a.y;return this},add:function(a,b){if(void 0!==b)return console.warn("THREE.Vector2: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(a,b);this.x+=a.x;this.y+=a.y;return this},addScalar:function(a){this.x+=a;this.y+=a;return this},addVectors:function(a,b){this.x=a.x+b.x;this.y=a.y+b.y;return this},addScaledVector:function(a, -b){this.x+=a.x*b;this.y+=a.y*b;return this},sub:function(a,b){if(void 0!==b)return console.warn("THREE.Vector2: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(a,b);this.x-=a.x;this.y-=a.y;return this},subScalar:function(a){this.x-=a;this.y-=a;return this},subVectors:function(a,b){this.x=a.x-b.x;this.y=a.y-b.y;return this},multiply:function(a){this.x*=a.x;this.y*=a.y;return this},multiplyScalar:function(a){isFinite(a)?(this.x*=a,this.y*=a):this.y=this.x=0; -return this},divide:function(a){this.x/=a.x;this.y/=a.y;return this},divideScalar:function(a){return this.multiplyScalar(1/a)},min:function(a){this.x=Math.min(this.x,a.x);this.y=Math.min(this.y,a.y);return this},max:function(a){this.x=Math.max(this.x,a.x);this.y=Math.max(this.y,a.y);return this},clamp:function(a,b){this.x=Math.max(a.x,Math.min(b.x,this.x));this.y=Math.max(a.y,Math.min(b.y,this.y));return this},clampScalar:function(){var a,b;return function(c,d){void 0===a&&(a=new C,b=new C);a.set(c, -c);b.set(d,d);return this.clamp(a,b)}}(),clampLength:function(a,b){var c=this.length();return this.multiplyScalar(Math.max(a,Math.min(b,c))/c)},floor:function(){this.x=Math.floor(this.x);this.y=Math.floor(this.y);return this},ceil:function(){this.x=Math.ceil(this.x);this.y=Math.ceil(this.y);return this},round:function(){this.x=Math.round(this.x);this.y=Math.round(this.y);return this},roundToZero:function(){this.x=0>this.x?Math.ceil(this.x):Math.floor(this.x);this.y=0>this.y?Math.ceil(this.y):Math.floor(this.y); -return this},negate:function(){this.x=-this.x;this.y=-this.y;return this},dot:function(a){return this.x*a.x+this.y*a.y},lengthSq:function(){return this.x*this.x+this.y*this.y},length:function(){return Math.sqrt(this.x*this.x+this.y*this.y)},lengthManhattan:function(){return Math.abs(this.x)+Math.abs(this.y)},normalize:function(){return this.divideScalar(this.length())},angle:function(){var a=Math.atan2(this.y,this.x);0>a&&(a+=2*Math.PI);return a},distanceTo:function(a){return Math.sqrt(this.distanceToSquared(a))}, -distanceToSquared:function(a){var b=this.x-a.x;a=this.y-a.y;return b*b+a*a},distanceToManhattan:function(a){return Math.abs(this.x-a.x)+Math.abs(this.y-a.y)},setLength:function(a){return this.multiplyScalar(a/this.length())},lerp:function(a,b){this.x+=(a.x-this.x)*b;this.y+=(a.y-this.y)*b;return this},lerpVectors:function(a,b,c){return this.subVectors(b,a).multiplyScalar(c).add(a)},equals:function(a){return a.x===this.x&&a.y===this.y},fromArray:function(a,b){void 0===b&&(b=0);this.x=a[b];this.y=a[b+ -1];return this},toArray:function(a,b){void 0===a&&(a=[]);void 0===b&&(b=0);a[b]=this.x;a[b+1]=this.y;return a},fromAttribute:function(a,b,c){void 0!==c&&console.warn("THREE.Vector2: offset has been removed from .fromAttribute().");this.x=a.getX(b);this.y=a.getY(b);return this},rotateAround:function(a,b){var c=Math.cos(b),d=Math.sin(b),e=this.x-a.x,f=this.y-a.y;this.x=e*c-f*d+a.x;this.y=e*d+f*c+a.y;return this}};var Oe=0;ea.DEFAULT_IMAGE=void 0;ea.DEFAULT_MAPPING=300;ea.prototype={constructor:ea,isTexture:!0, -set needsUpdate(a){!0===a&&this.version++},clone:function(){return(new this.constructor).copy(this)},copy:function(a){this.image=a.image;this.mipmaps=a.mipmaps.slice(0);this.mapping=a.mapping;this.wrapS=a.wrapS;this.wrapT=a.wrapT;this.magFilter=a.magFilter;this.minFilter=a.minFilter;this.anisotropy=a.anisotropy;this.format=a.format;this.type=a.type;this.offset.copy(a.offset);this.repeat.copy(a.repeat);this.generateMipmaps=a.generateMipmaps;this.premultiplyAlpha=a.premultiplyAlpha;this.flipY=a.flipY; -this.unpackAlignment=a.unpackAlignment;this.encoding=a.encoding;return this},toJSON:function(a){if(void 0!==a.textures[this.uuid])return a.textures[this.uuid];var b={metadata:{version:4.4,type:"Texture",generator:"Texture.toJSON"},uuid:this.uuid,name:this.name,mapping:this.mapping,repeat:[this.repeat.x,this.repeat.y],offset:[this.offset.x,this.offset.y],wrap:[this.wrapS,this.wrapT],minFilter:this.minFilter,magFilter:this.magFilter,anisotropy:this.anisotropy,flipY:this.flipY};if(void 0!==this.image){var c= -this.image;void 0===c.uuid&&(c.uuid=Q.generateUUID());if(void 0===a.images[c.uuid]){var d=a.images,e=c.uuid,f=c.uuid,g;void 0!==c.toDataURL?g=c:(g=document.createElementNS("http://www.w3.org/1999/xhtml","canvas"),g.width=c.width,g.height=c.height,g.getContext("2d").drawImage(c,0,0,c.width,c.height));g=2048a.x||1a.x?0:1;break;case 1002:a.x=1===Math.abs(Math.floor(a.x)%2)?Math.ceil(a.x)-a.x:a.x-Math.floor(a.x)}if(0>a.y||1a.y?0:1;break;case 1002:a.y=1===Math.abs(Math.floor(a.y)%2)?Math.ceil(a.y)-a.y:a.y-Math.floor(a.y)}this.flipY&&(a.y=1-a.y)}}};Object.assign(ea.prototype, -oa.prototype);ga.prototype={constructor:ga,isVector4:!0,set:function(a,b,c,d){this.x=a;this.y=b;this.z=c;this.w=d;return this},setScalar:function(a){this.w=this.z=this.y=this.x=a;return this},setX:function(a){this.x=a;return this},setY:function(a){this.y=a;return this},setZ:function(a){this.z=a;return this},setW:function(a){this.w=a;return this},setComponent:function(a,b){switch(a){case 0:this.x=b;break;case 1:this.y=b;break;case 2:this.z=b;break;case 3:this.w=b;break;default:throw Error("index is out of range: "+ -a);}return this},getComponent:function(a){switch(a){case 0:return this.x;case 1:return this.y;case 2:return this.z;case 3:return this.w;default:throw Error("index is out of range: "+a);}},clone:function(){return new this.constructor(this.x,this.y,this.z,this.w)},copy:function(a){this.x=a.x;this.y=a.y;this.z=a.z;this.w=void 0!==a.w?a.w:1;return this},add:function(a,b){if(void 0!==b)return console.warn("THREE.Vector4: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(a, -b);this.x+=a.x;this.y+=a.y;this.z+=a.z;this.w+=a.w;return this},addScalar:function(a){this.x+=a;this.y+=a;this.z+=a;this.w+=a;return this},addVectors:function(a,b){this.x=a.x+b.x;this.y=a.y+b.y;this.z=a.z+b.z;this.w=a.w+b.w;return this},addScaledVector:function(a,b){this.x+=a.x*b;this.y+=a.y*b;this.z+=a.z*b;this.w+=a.w*b;return this},sub:function(a,b){if(void 0!==b)return console.warn("THREE.Vector4: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(a,b);this.x-= -a.x;this.y-=a.y;this.z-=a.z;this.w-=a.w;return this},subScalar:function(a){this.x-=a;this.y-=a;this.z-=a;this.w-=a;return this},subVectors:function(a,b){this.x=a.x-b.x;this.y=a.y-b.y;this.z=a.z-b.z;this.w=a.w-b.w;return this},multiplyScalar:function(a){isFinite(a)?(this.x*=a,this.y*=a,this.z*=a,this.w*=a):this.w=this.z=this.y=this.x=0;return this},applyMatrix4:function(a){var b=this.x,c=this.y,d=this.z,e=this.w;a=a.elements;this.x=a[0]*b+a[4]*c+a[8]*d+a[12]*e;this.y=a[1]*b+a[5]*c+a[9]*d+a[13]*e;this.z= -a[2]*b+a[6]*c+a[10]*d+a[14]*e;this.w=a[3]*b+a[7]*c+a[11]*d+a[15]*e;return this},divideScalar:function(a){return this.multiplyScalar(1/a)},setAxisAngleFromQuaternion:function(a){this.w=2*Math.acos(a.w);var b=Math.sqrt(1-a.w*a.w);1E-4>b?(this.x=1,this.z=this.y=0):(this.x=a.x/b,this.y=a.y/b,this.z=a.z/b);return this},setAxisAngleFromRotationMatrix:function(a){var b,c,d;a=a.elements;var e=a[0];d=a[4];var f=a[8],g=a[1],h=a[5],k=a[9];c=a[2];b=a[6];var m=a[10];if(.01>Math.abs(d-g)&&.01>Math.abs(f-c)&&.01> -Math.abs(k-b)){if(.1>Math.abs(d+g)&&.1>Math.abs(f+c)&&.1>Math.abs(k+b)&&.1>Math.abs(e+h+m-3))return this.set(1,0,0,0),this;a=Math.PI;e=(e+1)/2;h=(h+1)/2;m=(m+1)/2;d=(d+g)/4;f=(f+c)/4;k=(k+b)/4;e>h&&e>m?.01>e?(b=0,d=c=.707106781):(b=Math.sqrt(e),c=d/b,d=f/b):h>m?.01>h?(b=.707106781,c=0,d=.707106781):(c=Math.sqrt(h),b=d/c,d=k/c):.01>m?(c=b=.707106781,d=0):(d=Math.sqrt(m),b=f/d,c=k/d);this.set(b,c,d,a);return this}a=Math.sqrt((b-k)*(b-k)+(f-c)*(f-c)+(g-d)*(g-d));.001>Math.abs(a)&&(a=1);this.x=(b-k)/ -a;this.y=(f-c)/a;this.z=(g-d)/a;this.w=Math.acos((e+h+m-1)/2);return this},min:function(a){this.x=Math.min(this.x,a.x);this.y=Math.min(this.y,a.y);this.z=Math.min(this.z,a.z);this.w=Math.min(this.w,a.w);return this},max:function(a){this.x=Math.max(this.x,a.x);this.y=Math.max(this.y,a.y);this.z=Math.max(this.z,a.z);this.w=Math.max(this.w,a.w);return this},clamp:function(a,b){this.x=Math.max(a.x,Math.min(b.x,this.x));this.y=Math.max(a.y,Math.min(b.y,this.y));this.z=Math.max(a.z,Math.min(b.z,this.z)); -this.w=Math.max(a.w,Math.min(b.w,this.w));return this},clampScalar:function(){var a,b;return function(c,d){void 0===a&&(a=new ga,b=new ga);a.set(c,c,c,c);b.set(d,d,d,d);return this.clamp(a,b)}}(),floor:function(){this.x=Math.floor(this.x);this.y=Math.floor(this.y);this.z=Math.floor(this.z);this.w=Math.floor(this.w);return this},ceil:function(){this.x=Math.ceil(this.x);this.y=Math.ceil(this.y);this.z=Math.ceil(this.z);this.w=Math.ceil(this.w);return this},round:function(){this.x=Math.round(this.x); -this.y=Math.round(this.y);this.z=Math.round(this.z);this.w=Math.round(this.w);return this},roundToZero:function(){this.x=0>this.x?Math.ceil(this.x):Math.floor(this.x);this.y=0>this.y?Math.ceil(this.y):Math.floor(this.y);this.z=0>this.z?Math.ceil(this.z):Math.floor(this.z);this.w=0>this.w?Math.ceil(this.w):Math.floor(this.w);return this},negate:function(){this.x=-this.x;this.y=-this.y;this.z=-this.z;this.w=-this.w;return this},dot:function(a){return this.x*a.x+this.y*a.y+this.z*a.z+this.w*a.w},lengthSq:function(){return this.x* -this.x+this.y*this.y+this.z*this.z+this.w*this.w},length:function(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z+this.w*this.w)},lengthManhattan:function(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)+Math.abs(this.w)},normalize:function(){return this.divideScalar(this.length())},setLength:function(a){return this.multiplyScalar(a/this.length())},lerp:function(a,b){this.x+=(a.x-this.x)*b;this.y+=(a.y-this.y)*b;this.z+=(a.z-this.z)*b;this.w+=(a.w-this.w)*b;return this},lerpVectors:function(a, -b,c){return this.subVectors(b,a).multiplyScalar(c).add(a)},equals:function(a){return a.x===this.x&&a.y===this.y&&a.z===this.z&&a.w===this.w},fromArray:function(a,b){void 0===b&&(b=0);this.x=a[b];this.y=a[b+1];this.z=a[b+2];this.w=a[b+3];return this},toArray:function(a,b){void 0===a&&(a=[]);void 0===b&&(b=0);a[b]=this.x;a[b+1]=this.y;a[b+2]=this.z;a[b+3]=this.w;return a},fromAttribute:function(a,b,c){void 0!==c&&console.warn("THREE.Vector4: offset has been removed from .fromAttribute().");this.x=a.getX(b); -this.y=a.getY(b);this.z=a.getZ(b);this.w=a.getW(b);return this}};Object.assign(Db.prototype,oa.prototype,{isWebGLRenderTarget:!0,setSize:function(a,b){if(this.width!==a||this.height!==b)this.width=a,this.height=b,this.dispose();this.viewport.set(0,0,a,b);this.scissor.set(0,0,a,b)},clone:function(){return(new this.constructor).copy(this)},copy:function(a){this.width=a.width;this.height=a.height;this.viewport.copy(a.viewport);this.texture=a.texture.clone();this.depthBuffer=a.depthBuffer;this.stencilBuffer= -a.stencilBuffer;this.depthTexture=a.depthTexture;return this},dispose:function(){this.dispatchEvent({type:"dispose"})}});Eb.prototype=Object.create(Db.prototype);Eb.prototype.constructor=Eb;Eb.prototype.isWebGLRenderTargetCube=!0;da.prototype={constructor:da,get x(){return this._x},set x(a){this._x=a;this.onChangeCallback()},get y(){return this._y},set y(a){this._y=a;this.onChangeCallback()},get z(){return this._z},set z(a){this._z=a;this.onChangeCallback()},get w(){return this._w},set w(a){this._w= -a;this.onChangeCallback()},set:function(a,b,c,d){this._x=a;this._y=b;this._z=c;this._w=d;this.onChangeCallback();return this},clone:function(){return new this.constructor(this._x,this._y,this._z,this._w)},copy:function(a){this._x=a.x;this._y=a.y;this._z=a.z;this._w=a.w;this.onChangeCallback();return this},setFromEuler:function(a,b){if(!1===(a&&a.isEuler))throw Error("THREE.Quaternion: .setFromEuler() now expects an Euler rotation rather than a Vector3 and order.");var c=Math.cos(a._x/2),d=Math.cos(a._y/ -2),e=Math.cos(a._z/2),f=Math.sin(a._x/2),g=Math.sin(a._y/2),h=Math.sin(a._z/2),k=a.order;"XYZ"===k?(this._x=f*d*e+c*g*h,this._y=c*g*e-f*d*h,this._z=c*d*h+f*g*e,this._w=c*d*e-f*g*h):"YXZ"===k?(this._x=f*d*e+c*g*h,this._y=c*g*e-f*d*h,this._z=c*d*h-f*g*e,this._w=c*d*e+f*g*h):"ZXY"===k?(this._x=f*d*e-c*g*h,this._y=c*g*e+f*d*h,this._z=c*d*h+f*g*e,this._w=c*d*e-f*g*h):"ZYX"===k?(this._x=f*d*e-c*g*h,this._y=c*g*e+f*d*h,this._z=c*d*h-f*g*e,this._w=c*d*e+f*g*h):"YZX"===k?(this._x=f*d*e+c*g*h,this._y=c*g*e+ -f*d*h,this._z=c*d*h-f*g*e,this._w=c*d*e-f*g*h):"XZY"===k&&(this._x=f*d*e-c*g*h,this._y=c*g*e-f*d*h,this._z=c*d*h+f*g*e,this._w=c*d*e+f*g*h);if(!1!==b)this.onChangeCallback();return this},setFromAxisAngle:function(a,b){var c=b/2,d=Math.sin(c);this._x=a.x*d;this._y=a.y*d;this._z=a.z*d;this._w=Math.cos(c);this.onChangeCallback();return this},setFromRotationMatrix:function(a){var b=a.elements,c=b[0];a=b[4];var d=b[8],e=b[1],f=b[5],g=b[9],h=b[2],k=b[6],b=b[10],m=c+f+b;0f&&c>b?(c=2*Math.sqrt(1+c-f-b),this._w=(k-g)/c,this._x=.25*c,this._y=(a+e)/c,this._z=(d+h)/c):f>b?(c=2*Math.sqrt(1+f-c-b),this._w=(d-h)/c,this._x=(a+e)/c,this._y=.25*c,this._z=(g+k)/c):(c=2*Math.sqrt(1+b-c-f),this._w=(e-a)/c,this._x=(d+h)/c,this._y=(g+k)/c,this._z=.25*c);this.onChangeCallback();return this},setFromUnitVectors:function(){var a,b;return function(c,d){void 0===a&&(a=new q);b=c.dot(d)+1;1E-6>b?(b=0,Math.abs(c.x)>Math.abs(c.z)?a.set(-c.y, -c.x,0):a.set(0,-c.z,c.y)):a.crossVectors(c,d);this._x=a.x;this._y=a.y;this._z=a.z;this._w=b;return this.normalize()}}(),inverse:function(){return this.conjugate().normalize()},conjugate:function(){this._x*=-1;this._y*=-1;this._z*=-1;this.onChangeCallback();return this},dot:function(a){return this._x*a._x+this._y*a._y+this._z*a._z+this._w*a._w},lengthSq:function(){return this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w},length:function(){return Math.sqrt(this._x*this._x+this._y*this._y+ -this._z*this._z+this._w*this._w)},normalize:function(){var a=this.length();0===a?(this._z=this._y=this._x=0,this._w=1):(a=1/a,this._x*=a,this._y*=a,this._z*=a,this._w*=a);this.onChangeCallback();return this},multiply:function(a,b){return void 0!==b?(console.warn("THREE.Quaternion: .multiply() now only accepts one argument. Use .multiplyQuaternions( a, b ) instead."),this.multiplyQuaternions(a,b)):this.multiplyQuaternions(this,a)},premultiply:function(a){return this.multiplyQuaternions(a,this)},multiplyQuaternions:function(a, -b){var c=a._x,d=a._y,e=a._z,f=a._w,g=b._x,h=b._y,k=b._z,m=b._w;this._x=c*m+f*g+d*k-e*h;this._y=d*m+f*h+e*g-c*k;this._z=e*m+f*k+c*h-d*g;this._w=f*m-c*g-d*h-e*k;this.onChangeCallback();return this},slerp:function(a,b){if(0===b)return this;if(1===b)return this.copy(a);var c=this._x,d=this._y,e=this._z,f=this._w,g=f*a._w+c*a._x+d*a._y+e*a._z;0>g?(this._w=-a._w,this._x=-a._x,this._y=-a._y,this._z=-a._z,g=-g):this.copy(a);if(1<=g)return this._w=f,this._x=c,this._y=d,this._z=e,this;var h=Math.sqrt(1-g*g); -if(.001>Math.abs(h))return this._w=.5*(f+this._w),this._x=.5*(c+this._x),this._y=.5*(d+this._y),this._z=.5*(e+this._z),this;var k=Math.atan2(h,g),g=Math.sin((1-b)*k)/h,h=Math.sin(b*k)/h;this._w=f*g+this._w*h;this._x=c*g+this._x*h;this._y=d*g+this._y*h;this._z=e*g+this._z*h;this.onChangeCallback();return this},equals:function(a){return a._x===this._x&&a._y===this._y&&a._z===this._z&&a._w===this._w},fromArray:function(a,b){void 0===b&&(b=0);this._x=a[b];this._y=a[b+1];this._z=a[b+2];this._w=a[b+3]; -this.onChangeCallback();return this},toArray:function(a,b){void 0===a&&(a=[]);void 0===b&&(b=0);a[b]=this._x;a[b+1]=this._y;a[b+2]=this._z;a[b+3]=this._w;return a},onChange:function(a){this.onChangeCallback=a;return this},onChangeCallback:function(){}};Object.assign(da,{slerp:function(a,b,c,d){return c.copy(a).slerp(b,d)},slerpFlat:function(a,b,c,d,e,f,g){var h=c[d+0],k=c[d+1],m=c[d+2];c=c[d+3];d=e[f+0];var l=e[f+1],p=e[f+2];e=e[f+3];if(c!==e||h!==d||k!==l||m!==p){f=1-g;var n=h*d+k*l+m*p+c*e,r=0<= -n?1:-1,w=1-n*n;w>Number.EPSILON&&(w=Math.sqrt(w),n=Math.atan2(w,n*r),f=Math.sin(f*n)/w,g=Math.sin(g*n)/w);r*=g;h=h*f+d*r;k=k*f+l*r;m=m*f+p*r;c=c*f+e*r;f===1-g&&(g=1/Math.sqrt(h*h+k*k+m*m+c*c),h*=g,k*=g,m*=g,c*=g)}a[b]=h;a[b+1]=k;a[b+2]=m;a[b+3]=c}});q.prototype={constructor:q,isVector3:!0,set:function(a,b,c){this.x=a;this.y=b;this.z=c;return this},setScalar:function(a){this.z=this.y=this.x=a;return this},setX:function(a){this.x=a;return this},setY:function(a){this.y=a;return this},setZ:function(a){this.z= -a;return this},setComponent:function(a,b){switch(a){case 0:this.x=b;break;case 1:this.y=b;break;case 2:this.z=b;break;default:throw Error("index is out of range: "+a);}return this},getComponent:function(a){switch(a){case 0:return this.x;case 1:return this.y;case 2:return this.z;default:throw Error("index is out of range: "+a);}},clone:function(){return new this.constructor(this.x,this.y,this.z)},copy:function(a){this.x=a.x;this.y=a.y;this.z=a.z;return this},add:function(a,b){if(void 0!==b)return console.warn("THREE.Vector3: .add() now only accepts one argument. Use .addVectors( a, b ) instead."), -this.addVectors(a,b);this.x+=a.x;this.y+=a.y;this.z+=a.z;return this},addScalar:function(a){this.x+=a;this.y+=a;this.z+=a;return this},addVectors:function(a,b){this.x=a.x+b.x;this.y=a.y+b.y;this.z=a.z+b.z;return this},addScaledVector:function(a,b){this.x+=a.x*b;this.y+=a.y*b;this.z+=a.z*b;return this},sub:function(a,b){if(void 0!==b)return console.warn("THREE.Vector3: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(a,b);this.x-=a.x;this.y-=a.y;this.z-=a.z; -return this},subScalar:function(a){this.x-=a;this.y-=a;this.z-=a;return this},subVectors:function(a,b){this.x=a.x-b.x;this.y=a.y-b.y;this.z=a.z-b.z;return this},multiply:function(a,b){if(void 0!==b)return console.warn("THREE.Vector3: .multiply() now only accepts one argument. Use .multiplyVectors( a, b ) instead."),this.multiplyVectors(a,b);this.x*=a.x;this.y*=a.y;this.z*=a.z;return this},multiplyScalar:function(a){isFinite(a)?(this.x*=a,this.y*=a,this.z*=a):this.z=this.y=this.x=0;return this},multiplyVectors:function(a, -b){this.x=a.x*b.x;this.y=a.y*b.y;this.z=a.z*b.z;return this},applyEuler:function(){var a;return function(b){!1===(b&&b.isEuler)&&console.error("THREE.Vector3: .applyEuler() now expects an Euler rotation rather than a Vector3 and order.");void 0===a&&(a=new da);return this.applyQuaternion(a.setFromEuler(b))}}(),applyAxisAngle:function(){var a;return function(b,c){void 0===a&&(a=new da);return this.applyQuaternion(a.setFromAxisAngle(b,c))}}(),applyMatrix3:function(a){var b=this.x,c=this.y,d=this.z; -a=a.elements;this.x=a[0]*b+a[3]*c+a[6]*d;this.y=a[1]*b+a[4]*c+a[7]*d;this.z=a[2]*b+a[5]*c+a[8]*d;return this},applyMatrix4:function(a){var b=this.x,c=this.y,d=this.z;a=a.elements;this.x=a[0]*b+a[4]*c+a[8]*d+a[12];this.y=a[1]*b+a[5]*c+a[9]*d+a[13];this.z=a[2]*b+a[6]*c+a[10]*d+a[14];return this},applyProjection:function(a){var b=this.x,c=this.y,d=this.z;a=a.elements;var e=1/(a[3]*b+a[7]*c+a[11]*d+a[15]);this.x=(a[0]*b+a[4]*c+a[8]*d+a[12])*e;this.y=(a[1]*b+a[5]*c+a[9]*d+a[13])*e;this.z=(a[2]*b+a[6]* -c+a[10]*d+a[14])*e;return this},applyQuaternion:function(a){var b=this.x,c=this.y,d=this.z,e=a.x,f=a.y,g=a.z;a=a.w;var h=a*b+f*d-g*c,k=a*c+g*b-e*d,m=a*d+e*c-f*b,b=-e*b-f*c-g*d;this.x=h*a+b*-e+k*-g-m*-f;this.y=k*a+b*-f+m*-e-h*-g;this.z=m*a+b*-g+h*-f-k*-e;return this},project:function(){var a;return function(b){void 0===a&&(a=new H);a.multiplyMatrices(b.projectionMatrix,a.getInverse(b.matrixWorld));return this.applyProjection(a)}}(),unproject:function(){var a;return function(b){void 0===a&&(a=new H); -a.multiplyMatrices(b.matrixWorld,a.getInverse(b.projectionMatrix));return this.applyProjection(a)}}(),transformDirection:function(a){var b=this.x,c=this.y,d=this.z;a=a.elements;this.x=a[0]*b+a[4]*c+a[8]*d;this.y=a[1]*b+a[5]*c+a[9]*d;this.z=a[2]*b+a[6]*c+a[10]*d;return this.normalize()},divide:function(a){this.x/=a.x;this.y/=a.y;this.z/=a.z;return this},divideScalar:function(a){return this.multiplyScalar(1/a)},min:function(a){this.x=Math.min(this.x,a.x);this.y=Math.min(this.y,a.y);this.z=Math.min(this.z, -a.z);return this},max:function(a){this.x=Math.max(this.x,a.x);this.y=Math.max(this.y,a.y);this.z=Math.max(this.z,a.z);return this},clamp:function(a,b){this.x=Math.max(a.x,Math.min(b.x,this.x));this.y=Math.max(a.y,Math.min(b.y,this.y));this.z=Math.max(a.z,Math.min(b.z,this.z));return this},clampScalar:function(){var a,b;return function(c,d){void 0===a&&(a=new q,b=new q);a.set(c,c,c);b.set(d,d,d);return this.clamp(a,b)}}(),clampLength:function(a,b){var c=this.length();return this.multiplyScalar(Math.max(a, -Math.min(b,c))/c)},floor:function(){this.x=Math.floor(this.x);this.y=Math.floor(this.y);this.z=Math.floor(this.z);return this},ceil:function(){this.x=Math.ceil(this.x);this.y=Math.ceil(this.y);this.z=Math.ceil(this.z);return this},round:function(){this.x=Math.round(this.x);this.y=Math.round(this.y);this.z=Math.round(this.z);return this},roundToZero:function(){this.x=0>this.x?Math.ceil(this.x):Math.floor(this.x);this.y=0>this.y?Math.ceil(this.y):Math.floor(this.y);this.z=0>this.z?Math.ceil(this.z): -Math.floor(this.z);return this},negate:function(){this.x=-this.x;this.y=-this.y;this.z=-this.z;return this},dot:function(a){return this.x*a.x+this.y*a.y+this.z*a.z},lengthSq:function(){return this.x*this.x+this.y*this.y+this.z*this.z},length:function(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z)},lengthManhattan:function(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)},normalize:function(){return this.divideScalar(this.length())},setLength:function(a){return this.multiplyScalar(a/ -this.length())},lerp:function(a,b){this.x+=(a.x-this.x)*b;this.y+=(a.y-this.y)*b;this.z+=(a.z-this.z)*b;return this},lerpVectors:function(a,b,c){return this.subVectors(b,a).multiplyScalar(c).add(a)},cross:function(a,b){if(void 0!==b)return console.warn("THREE.Vector3: .cross() now only accepts one argument. Use .crossVectors( a, b ) instead."),this.crossVectors(a,b);var c=this.x,d=this.y,e=this.z;this.x=d*a.z-e*a.y;this.y=e*a.x-c*a.z;this.z=c*a.y-d*a.x;return this},crossVectors:function(a,b){var c= -a.x,d=a.y,e=a.z,f=b.x,g=b.y,h=b.z;this.x=d*h-e*g;this.y=e*f-c*h;this.z=c*g-d*f;return this},projectOnVector:function(a){var b=a.dot(this)/a.lengthSq();return this.copy(a).multiplyScalar(b)},projectOnPlane:function(){var a;return function(b){void 0===a&&(a=new q);a.copy(this).projectOnVector(b);return this.sub(a)}}(),reflect:function(){var a;return function(b){void 0===a&&(a=new q);return this.sub(a.copy(b).multiplyScalar(2*this.dot(b)))}}(),angleTo:function(a){a=this.dot(a)/Math.sqrt(this.lengthSq()* -a.lengthSq());return Math.acos(Q.clamp(a,-1,1))},distanceTo:function(a){return Math.sqrt(this.distanceToSquared(a))},distanceToSquared:function(a){var b=this.x-a.x,c=this.y-a.y;a=this.z-a.z;return b*b+c*c+a*a},distanceToManhattan:function(a){return Math.abs(this.x-a.x)+Math.abs(this.y-a.y)+Math.abs(this.z-a.z)},setFromSpherical:function(a){var b=Math.sin(a.phi)*a.radius;this.x=b*Math.sin(a.theta);this.y=Math.cos(a.phi)*a.radius;this.z=b*Math.cos(a.theta);return this},setFromCylindrical:function(a){this.x= -a.radius*Math.sin(a.theta);this.y=a.y;this.z=a.radius*Math.cos(a.theta);return this},setFromMatrixPosition:function(a){return this.setFromMatrixColumn(a,3)},setFromMatrixScale:function(a){var b=this.setFromMatrixColumn(a,0).length(),c=this.setFromMatrixColumn(a,1).length();a=this.setFromMatrixColumn(a,2).length();this.x=b;this.y=c;this.z=a;return this},setFromMatrixColumn:function(a,b){if("number"===typeof a){console.warn("THREE.Vector3: setFromMatrixColumn now expects ( matrix, index ).");var c= -a;a=b;b=c}return this.fromArray(a.elements,4*b)},equals:function(a){return a.x===this.x&&a.y===this.y&&a.z===this.z},fromArray:function(a,b){void 0===b&&(b=0);this.x=a[b];this.y=a[b+1];this.z=a[b+2];return this},toArray:function(a,b){void 0===a&&(a=[]);void 0===b&&(b=0);a[b]=this.x;a[b+1]=this.y;a[b+2]=this.z;return a},fromAttribute:function(a,b,c){void 0!==c&&console.warn("THREE.Vector3: offset has been removed from .fromAttribute().");this.x=a.getX(b);this.y=a.getY(b);this.z=a.getZ(b);return this}}; -H.prototype={constructor:H,isMatrix4:!0,set:function(a,b,c,d,e,f,g,h,k,m,l,p,n,r,w,u){var q=this.elements;q[0]=a;q[4]=b;q[8]=c;q[12]=d;q[1]=e;q[5]=f;q[9]=g;q[13]=h;q[2]=k;q[6]=m;q[10]=l;q[14]=p;q[3]=n;q[7]=r;q[11]=w;q[15]=u;return this},identity:function(){this.set(1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1);return this},clone:function(){return(new H).fromArray(this.elements)},copy:function(a){this.elements.set(a.elements);return this},copyPosition:function(a){var b=this.elements;a=a.elements;b[12]=a[12];b[13]= -a[13];b[14]=a[14];return this},extractBasis:function(a,b,c){a.setFromMatrixColumn(this,0);b.setFromMatrixColumn(this,1);c.setFromMatrixColumn(this,2);return this},makeBasis:function(a,b,c){this.set(a.x,b.x,c.x,0,a.y,b.y,c.y,0,a.z,b.z,c.z,0,0,0,0,1);return this},extractRotation:function(){var a;return function(b){void 0===a&&(a=new q);var c=this.elements,d=b.elements,e=1/a.setFromMatrixColumn(b,0).length(),f=1/a.setFromMatrixColumn(b,1).length();b=1/a.setFromMatrixColumn(b,2).length();c[0]=d[0]*e; -c[1]=d[1]*e;c[2]=d[2]*e;c[4]=d[4]*f;c[5]=d[5]*f;c[6]=d[6]*f;c[8]=d[8]*b;c[9]=d[9]*b;c[10]=d[10]*b;return this}}(),makeRotationFromEuler:function(a){!1===(a&&a.isEuler)&&console.error("THREE.Matrix: .makeRotationFromEuler() now expects a Euler rotation rather than a Vector3 and order.");var b=this.elements,c=a.x,d=a.y,e=a.z,f=Math.cos(c),c=Math.sin(c),g=Math.cos(d),d=Math.sin(d),h=Math.cos(e),e=Math.sin(e);if("XYZ"===a.order){a=f*h;var k=f*e,m=c*h,l=c*e;b[0]=g*h;b[4]=-g*e;b[8]=d;b[1]=k+m*d;b[5]=a- -l*d;b[9]=-c*g;b[2]=l-a*d;b[6]=m+k*d;b[10]=f*g}else"YXZ"===a.order?(a=g*h,k=g*e,m=d*h,l=d*e,b[0]=a+l*c,b[4]=m*c-k,b[8]=f*d,b[1]=f*e,b[5]=f*h,b[9]=-c,b[2]=k*c-m,b[6]=l+a*c,b[10]=f*g):"ZXY"===a.order?(a=g*h,k=g*e,m=d*h,l=d*e,b[0]=a-l*c,b[4]=-f*e,b[8]=m+k*c,b[1]=k+m*c,b[5]=f*h,b[9]=l-a*c,b[2]=-f*d,b[6]=c,b[10]=f*g):"ZYX"===a.order?(a=f*h,k=f*e,m=c*h,l=c*e,b[0]=g*h,b[4]=m*d-k,b[8]=a*d+l,b[1]=g*e,b[5]=l*d+a,b[9]=k*d-m,b[2]=-d,b[6]=c*g,b[10]=f*g):"YZX"===a.order?(a=f*g,k=f*d,m=c*g,l=c*d,b[0]=g*h,b[4]=l- -a*e,b[8]=m*e+k,b[1]=e,b[5]=f*h,b[9]=-c*h,b[2]=-d*h,b[6]=k*e+m,b[10]=a-l*e):"XZY"===a.order&&(a=f*g,k=f*d,m=c*g,l=c*d,b[0]=g*h,b[4]=-e,b[8]=d*h,b[1]=a*e+l,b[5]=f*h,b[9]=k*e-m,b[2]=m*e-k,b[6]=c*h,b[10]=l*e+a);b[3]=0;b[7]=0;b[11]=0;b[12]=0;b[13]=0;b[14]=0;b[15]=1;return this},makeRotationFromQuaternion:function(a){var b=this.elements,c=a.x,d=a.y,e=a.z,f=a.w,g=c+c,h=d+d,k=e+e;a=c*g;var m=c*h,c=c*k,l=d*h,d=d*k,e=e*k,g=f*g,h=f*h,f=f*k;b[0]=1-(l+e);b[4]=m-f;b[8]=c+h;b[1]=m+f;b[5]=1-(a+e);b[9]=d-g;b[2]=c- -h;b[6]=d+g;b[10]=1-(a+l);b[3]=0;b[7]=0;b[11]=0;b[12]=0;b[13]=0;b[14]=0;b[15]=1;return this},lookAt:function(){var a,b,c;return function(d,e,f){void 0===a&&(a=new q,b=new q,c=new q);var g=this.elements;c.subVectors(d,e).normalize();0===c.lengthSq()&&(c.z=1);a.crossVectors(f,c).normalize();0===a.lengthSq()&&(c.z+=1E-4,a.crossVectors(f,c).normalize());b.crossVectors(c,a);g[0]=a.x;g[4]=b.x;g[8]=c.x;g[1]=a.y;g[5]=b.y;g[9]=c.y;g[2]=a.z;g[6]=b.z;g[10]=c.z;return this}}(),multiply:function(a,b){return void 0!== -b?(console.warn("THREE.Matrix4: .multiply() now only accepts one argument. Use .multiplyMatrices( a, b ) instead."),this.multiplyMatrices(a,b)):this.multiplyMatrices(this,a)},premultiply:function(a){return this.multiplyMatrices(a,this)},multiplyMatrices:function(a,b){var c=a.elements,d=b.elements,e=this.elements,f=c[0],g=c[4],h=c[8],k=c[12],m=c[1],l=c[5],p=c[9],n=c[13],r=c[2],w=c[6],u=c[10],q=c[14],t=c[3],v=c[7],M=c[11],c=c[15],z=d[0],A=d[4],I=d[8],E=d[12],K=d[1],y=d[5],J=d[9],C=d[13],D=d[2],G=d[6], -H=d[10],O=d[14],P=d[3],R=d[7],T=d[11],d=d[15];e[0]=f*z+g*K+h*D+k*P;e[4]=f*A+g*y+h*G+k*R;e[8]=f*I+g*J+h*H+k*T;e[12]=f*E+g*C+h*O+k*d;e[1]=m*z+l*K+p*D+n*P;e[5]=m*A+l*y+p*G+n*R;e[9]=m*I+l*J+p*H+n*T;e[13]=m*E+l*C+p*O+n*d;e[2]=r*z+w*K+u*D+q*P;e[6]=r*A+w*y+u*G+q*R;e[10]=r*I+w*J+u*H+q*T;e[14]=r*E+w*C+u*O+q*d;e[3]=t*z+v*K+M*D+c*P;e[7]=t*A+v*y+M*G+c*R;e[11]=t*I+v*J+M*H+c*T;e[15]=t*E+v*C+M*O+c*d;return this},multiplyToArray:function(a,b,c){var d=this.elements;this.multiplyMatrices(a,b);c[0]=d[0];c[1]=d[1];c[2]= -d[2];c[3]=d[3];c[4]=d[4];c[5]=d[5];c[6]=d[6];c[7]=d[7];c[8]=d[8];c[9]=d[9];c[10]=d[10];c[11]=d[11];c[12]=d[12];c[13]=d[13];c[14]=d[14];c[15]=d[15];return this},multiplyScalar:function(a){var b=this.elements;b[0]*=a;b[4]*=a;b[8]*=a;b[12]*=a;b[1]*=a;b[5]*=a;b[9]*=a;b[13]*=a;b[2]*=a;b[6]*=a;b[10]*=a;b[14]*=a;b[3]*=a;b[7]*=a;b[11]*=a;b[15]*=a;return this},applyToVector3Array:function(){var a;return function(b,c,d){void 0===a&&(a=new q);void 0===c&&(c=0);void 0===d&&(d=b.length);for(var e=0;ethis.determinant()&&(g=-g);c.x= -f[12];c.y=f[13];c.z=f[14];b.elements.set(this.elements);c=1/g;var f=1/h,m=1/k;b.elements[0]*=c;b.elements[1]*=c;b.elements[2]*=c;b.elements[4]*=f;b.elements[5]*=f;b.elements[6]*=f;b.elements[8]*=m;b.elements[9]*=m;b.elements[10]*=m;d.setFromRotationMatrix(b);e.x=g;e.y=h;e.z=k;return this}}(),makeFrustum:function(a,b,c,d,e,f){var g=this.elements;g[0]=2*e/(b-a);g[4]=0;g[8]=(b+a)/(b-a);g[12]=0;g[1]=0;g[5]=2*e/(d-c);g[9]=(d+c)/(d-c);g[13]=0;g[2]=0;g[6]=0;g[10]=-(f+e)/(f-e);g[14]=-2*f*e/(f-e);g[3]=0;g[7]= -0;g[11]=-1;g[15]=0;return this},makePerspective:function(a,b,c,d){a=c*Math.tan(Q.DEG2RAD*a*.5);var e=-a;return this.makeFrustum(e*b,a*b,e,a,c,d)},makeOrthographic:function(a,b,c,d,e,f){var g=this.elements,h=1/(b-a),k=1/(c-d),m=1/(f-e);g[0]=2*h;g[4]=0;g[8]=0;g[12]=-((b+a)*h);g[1]=0;g[5]=2*k;g[9]=0;g[13]=-((c+d)*k);g[2]=0;g[6]=0;g[10]=-2*m;g[14]=-((f+e)*m);g[3]=0;g[7]=0;g[11]=0;g[15]=1;return this},equals:function(a){var b=this.elements;a=a.elements;for(var c=0;16>c;c++)if(b[c]!==a[c])return!1;return!0}, -fromArray:function(a,b){void 0===b&&(b=0);for(var c=0;16>c;c++)this.elements[c]=a[c+b];return this},toArray:function(a,b){void 0===a&&(a=[]);void 0===b&&(b=0);var c=this.elements;a[b]=c[0];a[b+1]=c[1];a[b+2]=c[2];a[b+3]=c[3];a[b+4]=c[4];a[b+5]=c[5];a[b+6]=c[6];a[b+7]=c[7];a[b+8]=c[8];a[b+9]=c[9];a[b+10]=c[10];a[b+11]=c[11];a[b+12]=c[12];a[b+13]=c[13];a[b+14]=c[14];a[b+15]=c[15];return a}};Za.prototype=Object.create(ea.prototype);Za.prototype.constructor=Za;Za.prototype.isCubeTexture=!0;Object.defineProperty(Za.prototype, -"images",{get:function(){return this.image},set:function(a){this.image=a}});var se=new ea,te=new Za,pe=[],re=[];xe.prototype.setValue=function(a,b){for(var c=this.seq,d=0,e=c.length;d!==e;++d){var f=c[d];f.setValue(a,b[f.id])}};var Id=/([\w\d_]+)(\])?(\[|\.)?/g;$a.prototype.setValue=function(a,b,c){b=this.map[b];void 0!==b&&b.setValue(a,c,this.renderer)};$a.prototype.set=function(a,b,c){var d=this.map[c];void 0!==d&&d.setValue(a,b[c],this.renderer)};$a.prototype.setOptional=function(a,b,c){b=b[c]; -void 0!==b&&this.setValue(a,c,b)};$a.upload=function(a,b,c,d){for(var e=0,f=b.length;e!==f;++e){var g=b[e],h=c[g.id];!1!==h.needsUpdate&&g.setValue(a,h.value,d)}};$a.seqWithValue=function(a,b){for(var c=[],d=0,e=a.length;d!==e;++d){var f=a[d];f.id in b&&c.push(f)}return c};var Ja={merge:function(a){for(var b={},c=0;c 0.0 ) {\n#if defined ( PHYSICALLY_CORRECT_LIGHTS )\n\t\t\tfloat distanceFalloff = 1.0 / max( pow( lightDistance, decayExponent ), 0.01 );\n\t\t\tfloat maxDistanceCutoffFactor = pow2( saturate( 1.0 - pow4( lightDistance / cutoffDistance ) ) );\n\t\t\treturn distanceFalloff * maxDistanceCutoffFactor;\n#else\n\t\t\treturn pow( saturate( -lightDistance / cutoffDistance + 1.0 ), decayExponent );\n#endif\n\t\t}\n\t\treturn 1.0;\n}\nvec3 BRDF_Diffuse_Lambert( const in vec3 diffuseColor ) {\n\treturn RECIPROCAL_PI * diffuseColor;\n}\nvec3 F_Schlick( const in vec3 specularColor, const in float dotLH ) {\n\tfloat fresnel = exp2( ( -5.55473 * dotLH - 6.98316 ) * dotLH );\n\treturn ( 1.0 - specularColor ) * fresnel + specularColor;\n}\nfloat G_GGX_Smith( const in float alpha, const in float dotNL, const in float dotNV ) {\n\tfloat a2 = pow2( alpha );\n\tfloat gl = dotNL + sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNL ) );\n\tfloat gv = dotNV + sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNV ) );\n\treturn 1.0 / ( gl * gv );\n}\nfloat G_GGX_SmithCorrelated( const in float alpha, const in float dotNL, const in float dotNV ) {\n\tfloat a2 = pow2( alpha );\n\tfloat gv = dotNL * sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNV ) );\n\tfloat gl = dotNV * sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNL ) );\n\treturn 0.5 / max( gv + gl, EPSILON );\n}\nfloat D_GGX( const in float alpha, const in float dotNH ) {\n\tfloat a2 = pow2( alpha );\n\tfloat denom = pow2( dotNH ) * ( a2 - 1.0 ) + 1.0;\n\treturn RECIPROCAL_PI * a2 / pow2( denom );\n}\nvec3 BRDF_Specular_GGX( const in IncidentLight incidentLight, const in GeometricContext geometry, const in vec3 specularColor, const in float roughness ) {\n\tfloat alpha = pow2( roughness );\n\tvec3 halfDir = normalize( incidentLight.direction + geometry.viewDir );\n\tfloat dotNL = saturate( dot( geometry.normal, incidentLight.direction ) );\n\tfloat dotNV = saturate( dot( geometry.normal, geometry.viewDir ) );\n\tfloat dotNH = saturate( dot( geometry.normal, halfDir ) );\n\tfloat dotLH = saturate( dot( incidentLight.direction, halfDir ) );\n\tvec3 F = F_Schlick( specularColor, dotLH );\n\tfloat G = G_GGX_SmithCorrelated( alpha, dotNL, dotNV );\n\tfloat D = D_GGX( alpha, dotNH );\n\treturn F * ( G * D );\n}\nvec2 ltcTextureCoords( const in GeometricContext geometry, const in float roughness ) {\n\tconst float LUT_SIZE = 64.0;\n\tconst float LUT_SCALE = (LUT_SIZE - 1.0)/LUT_SIZE;\n\tconst float LUT_BIAS = 0.5/LUT_SIZE;\n\tvec3 N = geometry.normal;\n\tvec3 V = geometry.viewDir;\n\tvec3 P = geometry.position;\n\tfloat theta = acos( dot( N, V ) );\n\tvec2 uv = vec2(\n\t\tsqrt( saturate( roughness ) ),\n\t\tsaturate( theta / ( 0.5 * PI ) ) );\n\tuv = uv * LUT_SCALE + LUT_BIAS;\n\treturn uv;\n}\nvoid clipQuadToHorizon( inout vec3 L[5], out int n ) {\n\tint config = 0;\n\tif ( L[0].z > 0.0 ) config += 1;\n\tif ( L[1].z > 0.0 ) config += 2;\n\tif ( L[2].z > 0.0 ) config += 4;\n\tif ( L[3].z > 0.0 ) config += 8;\n\tn = 0;\n\tif ( config == 0 ) {\n\t} else if ( config == 1 ) {\n\t\tn = 3;\n\t\tL[1] = -L[1].z * L[0] + L[0].z * L[1];\n\t\tL[2] = -L[3].z * L[0] + L[0].z * L[3];\n\t} else if ( config == 2 ) {\n\t\tn = 3;\n\t\tL[0] = -L[0].z * L[1] + L[1].z * L[0];\n\t\tL[2] = -L[2].z * L[1] + L[1].z * L[2];\n\t} else if ( config == 3 ) {\n\t\tn = 4;\n\t\tL[2] = -L[2].z * L[1] + L[1].z * L[2];\n\t\tL[3] = -L[3].z * L[0] + L[0].z * L[3];\n\t} else if ( config == 4 ) {\n\t\tn = 3;\n\t\tL[0] = -L[3].z * L[2] + L[2].z * L[3];\n\t\tL[1] = -L[1].z * L[2] + L[2].z * L[1];\n\t} else if ( config == 5 ) {\n\t\tn = 0;\n\t} else if ( config == 6 ) {\n\t\tn = 4;\n\t\tL[0] = -L[0].z * L[1] + L[1].z * L[0];\n\t\tL[3] = -L[3].z * L[2] + L[2].z * L[3];\n\t} else if ( config == 7 ) {\n\t\tn = 5;\n\t\tL[4] = -L[3].z * L[0] + L[0].z * L[3];\n\t\tL[3] = -L[3].z * L[2] + L[2].z * L[3];\n\t} else if ( config == 8 ) {\n\t\tn = 3;\n\t\tL[0] = -L[0].z * L[3] + L[3].z * L[0];\n\t\tL[1] = -L[2].z * L[3] + L[3].z * L[2];\n\t\tL[2] = L[3];\n\t} else if ( config == 9 ) {\n\t\tn = 4;\n\t\tL[1] = -L[1].z * L[0] + L[0].z * L[1];\n\t\tL[2] = -L[2].z * L[3] + L[3].z * L[2];\n\t} else if ( config == 10 ) {\n\t\tn = 0;\n\t} else if ( config == 11 ) {\n\t\tn = 5;\n\t\tL[4] = L[3];\n\t\tL[3] = -L[2].z * L[3] + L[3].z * L[2];\n\t\tL[2] = -L[2].z * L[1] + L[1].z * L[2];\n\t} else if ( config == 12 ) {\n\t\tn = 4;\n\t\tL[1] = -L[1].z * L[2] + L[2].z * L[1];\n\t\tL[0] = -L[0].z * L[3] + L[3].z * L[0];\n\t} else if ( config == 13 ) {\n\t\tn = 5;\n\t\tL[4] = L[3];\n\t\tL[3] = L[2];\n\t\tL[2] = -L[1].z * L[2] + L[2].z * L[1];\n\t\tL[1] = -L[1].z * L[0] + L[0].z * L[1];\n\t} else if ( config == 14 ) {\n\t\tn = 5;\n\t\tL[4] = -L[0].z * L[3] + L[3].z * L[0];\n\t\tL[0] = -L[0].z * L[1] + L[1].z * L[0];\n\t} else if ( config == 15 ) {\n\t\tn = 4;\n\t}\n\tif ( n == 3 )\n\t\tL[3] = L[0];\n\tif ( n == 4 )\n\t\tL[4] = L[0];\n}\nfloat integrateLtcBrdfOverRectEdge( vec3 v1, vec3 v2 ) {\n\tfloat cosTheta = dot( v1, v2 );\n\tfloat theta = acos( cosTheta );\n\tfloat res = cross( v1, v2 ).z * ( ( theta > 0.001 ) ? theta / sin( theta ) : 1.0 );\n\treturn res;\n}\nvoid initRectPoints( const in vec3 pos, const in vec3 halfWidth, const in vec3 halfHeight, out vec3 rectPoints[4] ) {\n\trectPoints[0] = pos - halfWidth - halfHeight;\n\trectPoints[1] = pos + halfWidth - halfHeight;\n\trectPoints[2] = pos + halfWidth + halfHeight;\n\trectPoints[3] = pos - halfWidth + halfHeight;\n}\nvec3 integrateLtcBrdfOverRect( const in GeometricContext geometry, const in mat3 brdfMat, const in vec3 rectPoints[4] ) {\n\tvec3 N = geometry.normal;\n\tvec3 V = geometry.viewDir;\n\tvec3 P = geometry.position;\n\tvec3 T1, T2;\n\tT1 = normalize(V - N * dot( V, N ));\n\tT2 = - cross( N, T1 );\n\tmat3 brdfWrtSurface = brdfMat * transpose( mat3( T1, T2, N ) );\n\tvec3 clippedRect[5];\n\tclippedRect[0] = brdfWrtSurface * ( rectPoints[0] - P );\n\tclippedRect[1] = brdfWrtSurface * ( rectPoints[1] - P );\n\tclippedRect[2] = brdfWrtSurface * ( rectPoints[2] - P );\n\tclippedRect[3] = brdfWrtSurface * ( rectPoints[3] - P );\n\tint n;\n\tclipQuadToHorizon(clippedRect, n);\n\tif ( n == 0 )\n\t\treturn vec3( 0, 0, 0 );\n\tclippedRect[0] = normalize( clippedRect[0] );\n\tclippedRect[1] = normalize( clippedRect[1] );\n\tclippedRect[2] = normalize( clippedRect[2] );\n\tclippedRect[3] = normalize( clippedRect[3] );\n\tclippedRect[4] = normalize( clippedRect[4] );\n\tfloat sum = 0.0;\n\tsum += integrateLtcBrdfOverRectEdge( clippedRect[0], clippedRect[1] );\n\tsum += integrateLtcBrdfOverRectEdge( clippedRect[1], clippedRect[2] );\n\tsum += integrateLtcBrdfOverRectEdge( clippedRect[2], clippedRect[3] );\n\tif (n >= 4)\n\t\tsum += integrateLtcBrdfOverRectEdge( clippedRect[3], clippedRect[4] );\n\tif (n == 5)\n\t\tsum += integrateLtcBrdfOverRectEdge( clippedRect[4], clippedRect[0] );\n\tsum = max( 0.0, sum );\n\tvec3 Lo_i = vec3( sum, sum, sum );\n\treturn Lo_i;\n}\nvec3 Rect_Area_Light_Specular_Reflectance(\n\t\tconst in GeometricContext geometry,\n\t\tconst in vec3 lightPos, const in vec3 lightHalfWidth, const in vec3 lightHalfHeight,\n\t\tconst in float roughness,\n\t\tconst in sampler2D ltcMat, const in sampler2D ltcMag ) {\n\tvec3 rectPoints[4];\n\tinitRectPoints( lightPos, lightHalfWidth, lightHalfHeight, rectPoints );\n\tvec2 uv = ltcTextureCoords( geometry, roughness );\n\tvec4 brdfLtcApproxParams, t;\n\tbrdfLtcApproxParams = texture2D( ltcMat, uv );\n\tt = texture2D( ltcMat, uv );\n\tfloat brdfLtcScalar = texture2D( ltcMag, uv ).a;\n\tmat3 brdfLtcApproxMat = mat3(\n\t\tvec3( 1, 0, t.y ),\n\t\tvec3( 0, t.z, 0 ),\n\t\tvec3( t.w, 0, t.x )\n\t);\n\tvec3 specularReflectance = integrateLtcBrdfOverRect( geometry, brdfLtcApproxMat, rectPoints );\n\tspecularReflectance *= brdfLtcScalar;\n\treturn specularReflectance;\n}\nvec3 Rect_Area_Light_Diffuse_Reflectance(\n\t\tconst in GeometricContext geometry,\n\t\tconst in vec3 lightPos, const in vec3 lightHalfWidth, const in vec3 lightHalfHeight ) {\n\tvec3 rectPoints[4];\n\tinitRectPoints( lightPos, lightHalfWidth, lightHalfHeight, rectPoints );\n\tmat3 diffuseBrdfMat = mat3(1);\n\tvec3 diffuseReflectance = integrateLtcBrdfOverRect( geometry, diffuseBrdfMat, rectPoints );\n\treturn diffuseReflectance;\n}\nvec3 BRDF_Specular_GGX_Environment( const in GeometricContext geometry, const in vec3 specularColor, const in float roughness ) {\n\tfloat dotNV = saturate( dot( geometry.normal, geometry.viewDir ) );\n\tconst vec4 c0 = vec4( - 1, - 0.0275, - 0.572, 0.022 );\n\tconst vec4 c1 = vec4( 1, 0.0425, 1.04, - 0.04 );\n\tvec4 r = roughness * c0 + c1;\n\tfloat a004 = min( r.x * r.x, exp2( - 9.28 * dotNV ) ) * r.x + r.y;\n\tvec2 AB = vec2( -1.04, 1.04 ) * a004 + r.zw;\n\treturn specularColor * AB.x + AB.y;\n}\nfloat G_BlinnPhong_Implicit( ) {\n\treturn 0.25;\n}\nfloat D_BlinnPhong( const in float shininess, const in float dotNH ) {\n\treturn RECIPROCAL_PI * ( shininess * 0.5 + 1.0 ) * pow( dotNH, shininess );\n}\nvec3 BRDF_Specular_BlinnPhong( const in IncidentLight incidentLight, const in GeometricContext geometry, const in vec3 specularColor, const in float shininess ) {\n\tvec3 halfDir = normalize( incidentLight.direction + geometry.viewDir );\n\tfloat dotNH = saturate( dot( geometry.normal, halfDir ) );\n\tfloat dotLH = saturate( dot( incidentLight.direction, halfDir ) );\n\tvec3 F = F_Schlick( specularColor, dotLH );\n\tfloat G = G_BlinnPhong_Implicit( );\n\tfloat D = D_BlinnPhong( shininess, dotNH );\n\treturn F * ( G * D );\n}\nfloat GGXRoughnessToBlinnExponent( const in float ggxRoughness ) {\n\treturn ( 2.0 / pow2( ggxRoughness + 0.0001 ) - 2.0 );\n}\nfloat BlinnExponentToGGXRoughness( const in float blinnExponent ) {\n\treturn sqrt( 2.0 / ( blinnExponent + 2.0 ) );\n}\n", -bumpmap_pars_fragment:"#ifdef USE_BUMPMAP\n\tuniform sampler2D bumpMap;\n\tuniform float bumpScale;\n\tvec2 dHdxy_fwd() {\n\t\tvec2 dSTdx = dFdx( vUv );\n\t\tvec2 dSTdy = dFdy( vUv );\n\t\tfloat Hll = bumpScale * texture2D( bumpMap, vUv ).x;\n\t\tfloat dBx = bumpScale * texture2D( bumpMap, vUv + dSTdx ).x - Hll;\n\t\tfloat dBy = bumpScale * texture2D( bumpMap, vUv + dSTdy ).x - Hll;\n\t\treturn vec2( dBx, dBy );\n\t}\n\tvec3 perturbNormalArb( vec3 surf_pos, vec3 surf_norm, vec2 dHdxy ) {\n\t\tvec3 vSigmaX = dFdx( surf_pos );\n\t\tvec3 vSigmaY = dFdy( surf_pos );\n\t\tvec3 vN = surf_norm;\n\t\tvec3 R1 = cross( vSigmaY, vN );\n\t\tvec3 R2 = cross( vN, vSigmaX );\n\t\tfloat fDet = dot( vSigmaX, R1 );\n\t\tvec3 vGrad = sign( fDet ) * ( dHdxy.x * R1 + dHdxy.y * R2 );\n\t\treturn normalize( abs( fDet ) * surf_norm - vGrad );\n\t}\n#endif\n", -clipping_planes_fragment:"#if NUM_CLIPPING_PLANES > 0\n\tfor ( int i = 0; i < UNION_CLIPPING_PLANES; ++ i ) {\n\t\tvec4 plane = clippingPlanes[ i ];\n\t\tif ( dot( vViewPosition, plane.xyz ) > plane.w ) discard;\n\t}\n\t\t\n\t#if UNION_CLIPPING_PLANES < NUM_CLIPPING_PLANES\n\t\tbool clipped = true;\n\t\tfor ( int i = UNION_CLIPPING_PLANES; i < NUM_CLIPPING_PLANES; ++ i ) {\n\t\t\tvec4 plane = clippingPlanes[ i ];\n\t\t\tclipped = ( dot( vViewPosition, plane.xyz ) > plane.w ) && clipped;\n\t\t}\n\t\tif ( clipped ) discard;\n\t\n\t#endif\n#endif\n", -clipping_planes_pars_fragment:"#if NUM_CLIPPING_PLANES > 0\n\t#if ! defined( PHYSICAL ) && ! defined( PHONG )\n\t\tvarying vec3 vViewPosition;\n\t#endif\n\tuniform vec4 clippingPlanes[ NUM_CLIPPING_PLANES ];\n#endif\n",clipping_planes_pars_vertex:"#if NUM_CLIPPING_PLANES > 0 && ! defined( PHYSICAL ) && ! defined( PHONG )\n\tvarying vec3 vViewPosition;\n#endif\n",clipping_planes_vertex:"#if NUM_CLIPPING_PLANES > 0 && ! defined( PHYSICAL ) && ! defined( PHONG )\n\tvViewPosition = - mvPosition.xyz;\n#endif\n", -color_fragment:"#ifdef USE_COLOR\n\tdiffuseColor.rgb *= vColor;\n#endif",color_pars_fragment:"#ifdef USE_COLOR\n\tvarying vec3 vColor;\n#endif\n",color_pars_vertex:"#ifdef USE_COLOR\n\tvarying vec3 vColor;\n#endif",color_vertex:"#ifdef USE_COLOR\n\tvColor.xyz = color.xyz;\n#endif",common:"#define PI 3.14159265359\n#define PI2 6.28318530718\n#define PI_HALF 1.5707963267949\n#define RECIPROCAL_PI 0.31830988618\n#define RECIPROCAL_PI2 0.15915494\n#define LOG2 1.442695\n#define EPSILON 1e-6\n#define saturate(a) clamp( a, 0.0, 1.0 )\n#define whiteCompliment(a) ( 1.0 - saturate( a ) )\nfloat pow2( const in float x ) { return x*x; }\nfloat pow3( const in float x ) { return x*x*x; }\nfloat pow4( const in float x ) { float x2 = x*x; return x2*x2; }\nfloat average( const in vec3 color ) { return dot( color, vec3( 0.3333 ) ); }\nhighp float rand( const in vec2 uv ) {\n\tconst highp float a = 12.9898, b = 78.233, c = 43758.5453;\n\thighp float dt = dot( uv.xy, vec2( a,b ) ), sn = mod( dt, PI );\n\treturn fract(sin(sn) * c);\n}\nstruct IncidentLight {\n\tvec3 color;\n\tvec3 direction;\n\tbool visible;\n};\nstruct ReflectedLight {\n\tvec3 directDiffuse;\n\tvec3 directSpecular;\n\tvec3 indirectDiffuse;\n\tvec3 indirectSpecular;\n};\nstruct GeometricContext {\n\tvec3 position;\n\tvec3 normal;\n\tvec3 viewDir;\n};\nvec3 transformDirection( in vec3 dir, in mat4 matrix ) {\n\treturn normalize( ( matrix * vec4( dir, 0.0 ) ).xyz );\n}\nvec3 inverseTransformDirection( in vec3 dir, in mat4 matrix ) {\n\treturn normalize( ( vec4( dir, 0.0 ) * matrix ).xyz );\n}\nvec3 projectOnPlane(in vec3 point, in vec3 pointOnPlane, in vec3 planeNormal ) {\n\tfloat distance = dot( planeNormal, point - pointOnPlane );\n\treturn - distance * planeNormal + point;\n}\nfloat sideOfPlane( in vec3 point, in vec3 pointOnPlane, in vec3 planeNormal ) {\n\treturn sign( dot( point - pointOnPlane, planeNormal ) );\n}\nvec3 linePlaneIntersect( in vec3 pointOnLine, in vec3 lineDirection, in vec3 pointOnPlane, in vec3 planeNormal ) {\n\treturn lineDirection * ( dot( planeNormal, pointOnPlane - pointOnLine ) / dot( planeNormal, lineDirection ) ) + pointOnLine;\n}\nmat3 transpose( const in mat3 v ) {\n\tmat3 tmp;\n\ttmp[0] = vec3(v[0].x, v[1].x, v[2].x);\n\ttmp[1] = vec3(v[0].y, v[1].y, v[2].y);\n\ttmp[2] = vec3(v[0].z, v[1].z, v[2].z);\n\treturn tmp;\n}\n", -cube_uv_reflection_fragment:"#ifdef ENVMAP_TYPE_CUBE_UV\n#define cubeUV_textureSize (1024.0)\nint getFaceFromDirection(vec3 direction) {\n\tvec3 absDirection = abs(direction);\n\tint face = -1;\n\tif( absDirection.x > absDirection.z ) {\n\t\tif(absDirection.x > absDirection.y )\n\t\t\tface = direction.x > 0.0 ? 0 : 3;\n\t\telse\n\t\t\tface = direction.y > 0.0 ? 1 : 4;\n\t}\n\telse {\n\t\tif(absDirection.z > absDirection.y )\n\t\t\tface = direction.z > 0.0 ? 2 : 5;\n\t\telse\n\t\t\tface = direction.y > 0.0 ? 1 : 4;\n\t}\n\treturn face;\n}\n#define cubeUV_maxLods1 (log2(cubeUV_textureSize*0.25) - 1.0)\n#define cubeUV_rangeClamp (exp2((6.0 - 1.0) * 2.0))\nvec2 MipLevelInfo( vec3 vec, float roughnessLevel, float roughness ) {\n\tfloat scale = exp2(cubeUV_maxLods1 - roughnessLevel);\n\tfloat dxRoughness = dFdx(roughness);\n\tfloat dyRoughness = dFdy(roughness);\n\tvec3 dx = dFdx( vec * scale * dxRoughness );\n\tvec3 dy = dFdy( vec * scale * dyRoughness );\n\tfloat d = max( dot( dx, dx ), dot( dy, dy ) );\n\td = clamp(d, 1.0, cubeUV_rangeClamp);\n\tfloat mipLevel = 0.5 * log2(d);\n\treturn vec2(floor(mipLevel), fract(mipLevel));\n}\n#define cubeUV_maxLods2 (log2(cubeUV_textureSize*0.25) - 2.0)\n#define cubeUV_rcpTextureSize (1.0 / cubeUV_textureSize)\nvec2 getCubeUV(vec3 direction, float roughnessLevel, float mipLevel) {\n\tmipLevel = roughnessLevel > cubeUV_maxLods2 - 3.0 ? 0.0 : mipLevel;\n\tfloat a = 16.0 * cubeUV_rcpTextureSize;\n\tvec2 exp2_packed = exp2( vec2( roughnessLevel, mipLevel ) );\n\tvec2 rcp_exp2_packed = vec2( 1.0 ) / exp2_packed;\n\tfloat powScale = exp2_packed.x * exp2_packed.y;\n\tfloat scale = rcp_exp2_packed.x * rcp_exp2_packed.y * 0.25;\n\tfloat mipOffset = 0.75*(1.0 - rcp_exp2_packed.y) * rcp_exp2_packed.x;\n\tbool bRes = mipLevel == 0.0;\n\tscale = bRes && (scale < a) ? a : scale;\n\tvec3 r;\n\tvec2 offset;\n\tint face = getFaceFromDirection(direction);\n\tfloat rcpPowScale = 1.0 / powScale;\n\tif( face == 0) {\n\t\tr = vec3(direction.x, -direction.z, direction.y);\n\t\toffset = vec2(0.0+mipOffset,0.75 * rcpPowScale);\n\t\toffset.y = bRes && (offset.y < 2.0*a) ? a : offset.y;\n\t}\n\telse if( face == 1) {\n\t\tr = vec3(direction.y, direction.x, direction.z);\n\t\toffset = vec2(scale+mipOffset, 0.75 * rcpPowScale);\n\t\toffset.y = bRes && (offset.y < 2.0*a) ? a : offset.y;\n\t}\n\telse if( face == 2) {\n\t\tr = vec3(direction.z, direction.x, direction.y);\n\t\toffset = vec2(2.0*scale+mipOffset, 0.75 * rcpPowScale);\n\t\toffset.y = bRes && (offset.y < 2.0*a) ? a : offset.y;\n\t}\n\telse if( face == 3) {\n\t\tr = vec3(direction.x, direction.z, direction.y);\n\t\toffset = vec2(0.0+mipOffset,0.5 * rcpPowScale);\n\t\toffset.y = bRes && (offset.y < 2.0*a) ? 0.0 : offset.y;\n\t}\n\telse if( face == 4) {\n\t\tr = vec3(direction.y, direction.x, -direction.z);\n\t\toffset = vec2(scale+mipOffset, 0.5 * rcpPowScale);\n\t\toffset.y = bRes && (offset.y < 2.0*a) ? 0.0 : offset.y;\n\t}\n\telse {\n\t\tr = vec3(direction.z, -direction.x, direction.y);\n\t\toffset = vec2(2.0*scale+mipOffset, 0.5 * rcpPowScale);\n\t\toffset.y = bRes && (offset.y < 2.0*a) ? 0.0 : offset.y;\n\t}\n\tr = normalize(r);\n\tfloat texelOffset = 0.5 * cubeUV_rcpTextureSize;\n\tvec2 s = ( r.yz / abs( r.x ) + vec2( 1.0 ) ) * 0.5;\n\tvec2 base = offset + vec2( texelOffset );\n\treturn base + s * ( scale - 2.0 * texelOffset );\n}\n#define cubeUV_maxLods3 (log2(cubeUV_textureSize*0.25) - 3.0)\nvec4 textureCubeUV(vec3 reflectedDirection, float roughness ) {\n\tfloat roughnessVal = roughness* cubeUV_maxLods3;\n\tfloat r1 = floor(roughnessVal);\n\tfloat r2 = r1 + 1.0;\n\tfloat t = fract(roughnessVal);\n\tvec2 mipInfo = MipLevelInfo(reflectedDirection, r1, roughness);\n\tfloat s = mipInfo.y;\n\tfloat level0 = mipInfo.x;\n\tfloat level1 = level0 + 1.0;\n\tlevel1 = level1 > 5.0 ? 5.0 : level1;\n\tlevel0 += min( floor( s + 0.5 ), 5.0 );\n\tvec2 uv_10 = getCubeUV(reflectedDirection, r1, level0);\n\tvec4 color10 = envMapTexelToLinear(texture2D(envMap, uv_10));\n\tvec2 uv_20 = getCubeUV(reflectedDirection, r2, level0);\n\tvec4 color20 = envMapTexelToLinear(texture2D(envMap, uv_20));\n\tvec4 result = mix(color10, color20, t);\n\treturn vec4(result.rgb, 1.0);\n}\n#endif\n", -defaultnormal_vertex:"#ifdef FLIP_SIDED\n\tobjectNormal = -objectNormal;\n#endif\nvec3 transformedNormal = normalMatrix * objectNormal;\n",displacementmap_pars_vertex:"#ifdef USE_DISPLACEMENTMAP\n\tuniform sampler2D displacementMap;\n\tuniform float displacementScale;\n\tuniform float displacementBias;\n#endif\n",displacementmap_vertex:"#ifdef USE_DISPLACEMENTMAP\n\ttransformed += normal * ( texture2D( displacementMap, uv ).x * displacementScale + displacementBias );\n#endif\n",emissivemap_fragment:"#ifdef USE_EMISSIVEMAP\n\tvec4 emissiveColor = texture2D( emissiveMap, vUv );\n\temissiveColor.rgb = emissiveMapTexelToLinear( emissiveColor ).rgb;\n\ttotalEmissiveRadiance *= emissiveColor.rgb;\n#endif\n", -emissivemap_pars_fragment:"#ifdef USE_EMISSIVEMAP\n\tuniform sampler2D emissiveMap;\n#endif\n",encodings_fragment:" gl_FragColor = linearToOutputTexel( gl_FragColor );\n",encodings_pars_fragment:"\nvec4 LinearToLinear( in vec4 value ) {\n return value;\n}\nvec4 GammaToLinear( in vec4 value, in float gammaFactor ) {\n return vec4( pow( value.xyz, vec3( gammaFactor ) ), value.w );\n}\nvec4 LinearToGamma( in vec4 value, in float gammaFactor ) {\n return vec4( pow( value.xyz, vec3( 1.0 / gammaFactor ) ), value.w );\n}\nvec4 sRGBToLinear( in vec4 value ) {\n return vec4( mix( pow( value.rgb * 0.9478672986 + vec3( 0.0521327014 ), vec3( 2.4 ) ), value.rgb * 0.0773993808, vec3( lessThanEqual( value.rgb, vec3( 0.04045 ) ) ) ), value.w );\n}\nvec4 LinearTosRGB( in vec4 value ) {\n return vec4( mix( pow( value.rgb, vec3( 0.41666 ) ) * 1.055 - vec3( 0.055 ), value.rgb * 12.92, vec3( lessThanEqual( value.rgb, vec3( 0.0031308 ) ) ) ), value.w );\n}\nvec4 RGBEToLinear( in vec4 value ) {\n return vec4( value.rgb * exp2( value.a * 255.0 - 128.0 ), 1.0 );\n}\nvec4 LinearToRGBE( in vec4 value ) {\n float maxComponent = max( max( value.r, value.g ), value.b );\n float fExp = clamp( ceil( log2( maxComponent ) ), -128.0, 127.0 );\n return vec4( value.rgb / exp2( fExp ), ( fExp + 128.0 ) / 255.0 );\n}\nvec4 RGBMToLinear( in vec4 value, in float maxRange ) {\n return vec4( value.xyz * value.w * maxRange, 1.0 );\n}\nvec4 LinearToRGBM( in vec4 value, in float maxRange ) {\n float maxRGB = max( value.x, max( value.g, value.b ) );\n float M = clamp( maxRGB / maxRange, 0.0, 1.0 );\n M = ceil( M * 255.0 ) / 255.0;\n return vec4( value.rgb / ( M * maxRange ), M );\n}\nvec4 RGBDToLinear( in vec4 value, in float maxRange ) {\n return vec4( value.rgb * ( ( maxRange / 255.0 ) / value.a ), 1.0 );\n}\nvec4 LinearToRGBD( in vec4 value, in float maxRange ) {\n float maxRGB = max( value.x, max( value.g, value.b ) );\n float D = max( maxRange / maxRGB, 1.0 );\n D = min( floor( D ) / 255.0, 1.0 );\n return vec4( value.rgb * ( D * ( 255.0 / maxRange ) ), D );\n}\nconst mat3 cLogLuvM = mat3( 0.2209, 0.3390, 0.4184, 0.1138, 0.6780, 0.7319, 0.0102, 0.1130, 0.2969 );\nvec4 LinearToLogLuv( in vec4 value ) {\n vec3 Xp_Y_XYZp = value.rgb * cLogLuvM;\n Xp_Y_XYZp = max(Xp_Y_XYZp, vec3(1e-6, 1e-6, 1e-6));\n vec4 vResult;\n vResult.xy = Xp_Y_XYZp.xy / Xp_Y_XYZp.z;\n float Le = 2.0 * log2(Xp_Y_XYZp.y) + 127.0;\n vResult.w = fract(Le);\n vResult.z = (Le - (floor(vResult.w*255.0))/255.0)/255.0;\n return vResult;\n}\nconst mat3 cLogLuvInverseM = mat3( 6.0014, -2.7008, -1.7996, -1.3320, 3.1029, -5.7721, 0.3008, -1.0882, 5.6268 );\nvec4 LogLuvToLinear( in vec4 value ) {\n float Le = value.z * 255.0 + value.w;\n vec3 Xp_Y_XYZp;\n Xp_Y_XYZp.y = exp2((Le - 127.0) / 2.0);\n Xp_Y_XYZp.z = Xp_Y_XYZp.y / value.y;\n Xp_Y_XYZp.x = value.x * Xp_Y_XYZp.z;\n vec3 vRGB = Xp_Y_XYZp.rgb * cLogLuvInverseM;\n return vec4( max(vRGB, 0.0), 1.0 );\n}\n", -envmap_fragment:"#ifdef USE_ENVMAP\n\t#if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( PHONG )\n\t\tvec3 cameraToVertex = normalize( vWorldPosition - cameraPosition );\n\t\tvec3 worldNormal = inverseTransformDirection( normal, viewMatrix );\n\t\t#ifdef ENVMAP_MODE_REFLECTION\n\t\t\tvec3 reflectVec = reflect( cameraToVertex, worldNormal );\n\t\t#else\n\t\t\tvec3 reflectVec = refract( cameraToVertex, worldNormal, refractionRatio );\n\t\t#endif\n\t#else\n\t\tvec3 reflectVec = vReflect;\n\t#endif\n\t#ifdef ENVMAP_TYPE_CUBE\n\t\tvec4 envColor = textureCube( envMap, flipNormal * vec3( flipEnvMap * reflectVec.x, reflectVec.yz ) );\n\t#elif defined( ENVMAP_TYPE_EQUIREC )\n\t\tvec2 sampleUV;\n\t\tsampleUV.y = saturate( flipNormal * reflectVec.y * 0.5 + 0.5 );\n\t\tsampleUV.x = atan( flipNormal * reflectVec.z, flipNormal * reflectVec.x ) * RECIPROCAL_PI2 + 0.5;\n\t\tvec4 envColor = texture2D( envMap, sampleUV );\n\t#elif defined( ENVMAP_TYPE_SPHERE )\n\t\tvec3 reflectView = flipNormal * normalize( ( viewMatrix * vec4( reflectVec, 0.0 ) ).xyz + vec3( 0.0, 0.0, 1.0 ) );\n\t\tvec4 envColor = texture2D( envMap, reflectView.xy * 0.5 + 0.5 );\n\t#else\n\t\tvec4 envColor = vec4( 0.0 );\n\t#endif\n\tenvColor = envMapTexelToLinear( envColor );\n\t#ifdef ENVMAP_BLENDING_MULTIPLY\n\t\toutgoingLight = mix( outgoingLight, outgoingLight * envColor.xyz, specularStrength * reflectivity );\n\t#elif defined( ENVMAP_BLENDING_MIX )\n\t\toutgoingLight = mix( outgoingLight, envColor.xyz, specularStrength * reflectivity );\n\t#elif defined( ENVMAP_BLENDING_ADD )\n\t\toutgoingLight += envColor.xyz * specularStrength * reflectivity;\n\t#endif\n#endif\n", -envmap_pars_fragment:"#if defined( USE_ENVMAP ) || defined( PHYSICAL )\n\tuniform float reflectivity;\n\tuniform float envMapIntensity;\n#endif\n#ifdef USE_ENVMAP\n\t#if ! defined( PHYSICAL ) && ( defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( PHONG ) )\n\t\tvarying vec3 vWorldPosition;\n\t#endif\n\t#ifdef ENVMAP_TYPE_CUBE\n\t\tuniform samplerCube envMap;\n\t#else\n\t\tuniform sampler2D envMap;\n\t#endif\n\tuniform float flipEnvMap;\n\t#if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( PHONG ) || defined( PHYSICAL )\n\t\tuniform float refractionRatio;\n\t#else\n\t\tvarying vec3 vReflect;\n\t#endif\n#endif\n", -envmap_pars_vertex:"#ifdef USE_ENVMAP\n\t#if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( PHONG )\n\t\tvarying vec3 vWorldPosition;\n\t#else\n\t\tvarying vec3 vReflect;\n\t\tuniform float refractionRatio;\n\t#endif\n#endif\n",envmap_vertex:"#ifdef USE_ENVMAP\n\t#if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( PHONG )\n\t\tvWorldPosition = worldPosition.xyz;\n\t#else\n\t\tvec3 cameraToVertex = normalize( worldPosition.xyz - cameraPosition );\n\t\tvec3 worldNormal = inverseTransformDirection( transformedNormal, viewMatrix );\n\t\t#ifdef ENVMAP_MODE_REFLECTION\n\t\t\tvReflect = reflect( cameraToVertex, worldNormal );\n\t\t#else\n\t\t\tvReflect = refract( cameraToVertex, worldNormal, refractionRatio );\n\t\t#endif\n\t#endif\n#endif\n", -fog_fragment:"#ifdef USE_FOG\n\t#ifdef USE_LOGDEPTHBUF_EXT\n\t\tfloat depth = gl_FragDepthEXT / gl_FragCoord.w;\n\t#else\n\t\tfloat depth = gl_FragCoord.z / gl_FragCoord.w;\n\t#endif\n\t#ifdef FOG_EXP2\n\t\tfloat fogFactor = whiteCompliment( exp2( - fogDensity * fogDensity * depth * depth * LOG2 ) );\n\t#else\n\t\tfloat fogFactor = smoothstep( fogNear, fogFar, depth );\n\t#endif\n\tgl_FragColor.rgb = mix( gl_FragColor.rgb, fogColor, fogFactor );\n#endif\n",fog_pars_fragment:"#ifdef USE_FOG\n\tuniform vec3 fogColor;\n\t#ifdef FOG_EXP2\n\t\tuniform float fogDensity;\n\t#else\n\t\tuniform float fogNear;\n\t\tuniform float fogFar;\n\t#endif\n#endif", -gradientmap_pars_fragment:"#ifdef TOON\n\tuniform sampler2D gradientMap;\n\tvec3 getGradientIrradiance( vec3 normal, vec3 lightDirection ) {\n\t\tfloat dotNL = dot( normal, lightDirection );\n\t\tvec2 coord = vec2( dotNL * 0.5 + 0.5, 0.0 );\n\t\t#ifdef USE_GRADIENTMAP\n\t\t\treturn texture2D( gradientMap, coord ).rgb;\n\t\t#else\n\t\t\treturn ( coord.x < 0.7 ) ? vec3( 0.7 ) : vec3( 1.0 );\n\t\t#endif\n\t}\n#endif\n",lightmap_fragment:"#ifdef USE_LIGHTMAP\n\treflectedLight.indirectDiffuse += PI * texture2D( lightMap, vUv2 ).xyz * lightMapIntensity;\n#endif\n", -lightmap_pars_fragment:"#ifdef USE_LIGHTMAP\n\tuniform sampler2D lightMap;\n\tuniform float lightMapIntensity;\n#endif",lights_lambert_vertex:"vec3 diffuse = vec3( 1.0 );\nGeometricContext geometry;\ngeometry.position = mvPosition.xyz;\ngeometry.normal = normalize( transformedNormal );\ngeometry.viewDir = normalize( -mvPosition.xyz );\nGeometricContext backGeometry;\nbackGeometry.position = geometry.position;\nbackGeometry.normal = -geometry.normal;\nbackGeometry.viewDir = geometry.viewDir;\nvLightFront = vec3( 0.0 );\n#ifdef DOUBLE_SIDED\n\tvLightBack = vec3( 0.0 );\n#endif\nIncidentLight directLight;\nfloat dotNL;\nvec3 directLightColor_Diffuse;\n#if NUM_POINT_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {\n\t\tgetPointDirectLightIrradiance( pointLights[ i ], geometry, directLight );\n\t\tdotNL = dot( geometry.normal, directLight.direction );\n\t\tdirectLightColor_Diffuse = PI * directLight.color;\n\t\tvLightFront += saturate( dotNL ) * directLightColor_Diffuse;\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvLightBack += saturate( -dotNL ) * directLightColor_Diffuse;\n\t\t#endif\n\t}\n#endif\n#if NUM_SPOT_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {\n\t\tgetSpotDirectLightIrradiance( spotLights[ i ], geometry, directLight );\n\t\tdotNL = dot( geometry.normal, directLight.direction );\n\t\tdirectLightColor_Diffuse = PI * directLight.color;\n\t\tvLightFront += saturate( dotNL ) * directLightColor_Diffuse;\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvLightBack += saturate( -dotNL ) * directLightColor_Diffuse;\n\t\t#endif\n\t}\n#endif\n#if NUM_RECT_AREA_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_RECT_AREA_LIGHTS; i ++ ) {\n\t}\n#endif\n#if NUM_DIR_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {\n\t\tgetDirectionalDirectLightIrradiance( directionalLights[ i ], geometry, directLight );\n\t\tdotNL = dot( geometry.normal, directLight.direction );\n\t\tdirectLightColor_Diffuse = PI * directLight.color;\n\t\tvLightFront += saturate( dotNL ) * directLightColor_Diffuse;\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvLightBack += saturate( -dotNL ) * directLightColor_Diffuse;\n\t\t#endif\n\t}\n#endif\n#if NUM_HEMI_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_HEMI_LIGHTS; i ++ ) {\n\t\tvLightFront += getHemisphereLightIrradiance( hemisphereLights[ i ], geometry );\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvLightBack += getHemisphereLightIrradiance( hemisphereLights[ i ], backGeometry );\n\t\t#endif\n\t}\n#endif\n", -lights_pars:"uniform vec3 ambientLightColor;\nvec3 getAmbientLightIrradiance( const in vec3 ambientLightColor ) {\n\tvec3 irradiance = ambientLightColor;\n\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\tirradiance *= PI;\n\t#endif\n\treturn irradiance;\n}\n#if NUM_DIR_LIGHTS > 0\n\tstruct DirectionalLight {\n\t\tvec3 direction;\n\t\tvec3 color;\n\t\tint shadow;\n\t\tfloat shadowBias;\n\t\tfloat shadowRadius;\n\t\tvec2 shadowMapSize;\n\t};\n\tuniform DirectionalLight directionalLights[ NUM_DIR_LIGHTS ];\n\tvoid getDirectionalDirectLightIrradiance( const in DirectionalLight directionalLight, const in GeometricContext geometry, out IncidentLight directLight ) {\n\t\tdirectLight.color = directionalLight.color;\n\t\tdirectLight.direction = directionalLight.direction;\n\t\tdirectLight.visible = true;\n\t}\n#endif\n#if NUM_POINT_LIGHTS > 0\n\tstruct PointLight {\n\t\tvec3 position;\n\t\tvec3 color;\n\t\tfloat distance;\n\t\tfloat decay;\n\t\tint shadow;\n\t\tfloat shadowBias;\n\t\tfloat shadowRadius;\n\t\tvec2 shadowMapSize;\n\t};\n\tuniform PointLight pointLights[ NUM_POINT_LIGHTS ];\n\tvoid getPointDirectLightIrradiance( const in PointLight pointLight, const in GeometricContext geometry, out IncidentLight directLight ) {\n\t\tvec3 lVector = pointLight.position - geometry.position;\n\t\tdirectLight.direction = normalize( lVector );\n\t\tfloat lightDistance = length( lVector );\n\t\tdirectLight.color = pointLight.color;\n\t\tdirectLight.color *= punctualLightIntensityToIrradianceFactor( lightDistance, pointLight.distance, pointLight.decay );\n\t\tdirectLight.visible = ( directLight.color != vec3( 0.0 ) );\n\t}\n#endif\n#if NUM_SPOT_LIGHTS > 0\n\tstruct SpotLight {\n\t\tvec3 position;\n\t\tvec3 direction;\n\t\tvec3 color;\n\t\tfloat distance;\n\t\tfloat decay;\n\t\tfloat coneCos;\n\t\tfloat penumbraCos;\n\t\tint shadow;\n\t\tfloat shadowBias;\n\t\tfloat shadowRadius;\n\t\tvec2 shadowMapSize;\n\t};\n\tuniform SpotLight spotLights[ NUM_SPOT_LIGHTS ];\n\tvoid getSpotDirectLightIrradiance( const in SpotLight spotLight, const in GeometricContext geometry, out IncidentLight directLight ) {\n\t\tvec3 lVector = spotLight.position - geometry.position;\n\t\tdirectLight.direction = normalize( lVector );\n\t\tfloat lightDistance = length( lVector );\n\t\tfloat angleCos = dot( directLight.direction, spotLight.direction );\n\t\tif ( angleCos > spotLight.coneCos ) {\n\t\t\tfloat spotEffect = smoothstep( spotLight.coneCos, spotLight.penumbraCos, angleCos );\n\t\t\tdirectLight.color = spotLight.color;\n\t\t\tdirectLight.color *= spotEffect * punctualLightIntensityToIrradianceFactor( lightDistance, spotLight.distance, spotLight.decay );\n\t\t\tdirectLight.visible = true;\n\t\t} else {\n\t\t\tdirectLight.color = vec3( 0.0 );\n\t\t\tdirectLight.visible = false;\n\t\t}\n\t}\n#endif\n#if NUM_RECT_AREA_LIGHTS > 0\n\tstruct RectAreaLight {\n\t\tvec3 color;\n\t\tvec3 position;\n\t\tvec3 halfWidth;\n\t\tvec3 halfHeight;\n\t};\n\tuniform sampler2D ltcMat;\tuniform sampler2D ltcMag;\n\tuniform RectAreaLight rectAreaLights[ NUM_RECT_AREA_LIGHTS ];\n#endif\n#if NUM_HEMI_LIGHTS > 0\n\tstruct HemisphereLight {\n\t\tvec3 direction;\n\t\tvec3 skyColor;\n\t\tvec3 groundColor;\n\t};\n\tuniform HemisphereLight hemisphereLights[ NUM_HEMI_LIGHTS ];\n\tvec3 getHemisphereLightIrradiance( const in HemisphereLight hemiLight, const in GeometricContext geometry ) {\n\t\tfloat dotNL = dot( geometry.normal, hemiLight.direction );\n\t\tfloat hemiDiffuseWeight = 0.5 * dotNL + 0.5;\n\t\tvec3 irradiance = mix( hemiLight.groundColor, hemiLight.skyColor, hemiDiffuseWeight );\n\t\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\t\tirradiance *= PI;\n\t\t#endif\n\t\treturn irradiance;\n\t}\n#endif\n#if defined( USE_ENVMAP ) && defined( PHYSICAL )\n\tvec3 getLightProbeIndirectIrradiance( const in GeometricContext geometry, const in int maxMIPLevel ) {\n\t\tvec3 worldNormal = inverseTransformDirection( geometry.normal, viewMatrix );\n\t\t#ifdef ENVMAP_TYPE_CUBE\n\t\t\tvec3 queryVec = vec3( flipEnvMap * worldNormal.x, worldNormal.yz );\n\t\t\t#ifdef TEXTURE_LOD_EXT\n\t\t\t\tvec4 envMapColor = textureCubeLodEXT( envMap, queryVec, float( maxMIPLevel ) );\n\t\t\t#else\n\t\t\t\tvec4 envMapColor = textureCube( envMap, queryVec, float( maxMIPLevel ) );\n\t\t\t#endif\n\t\t\tenvMapColor.rgb = envMapTexelToLinear( envMapColor ).rgb;\n\t\t#elif defined( ENVMAP_TYPE_CUBE_UV )\n\t\t\tvec3 queryVec = vec3( flipEnvMap * worldNormal.x, worldNormal.yz );\n\t\t\tvec4 envMapColor = textureCubeUV( queryVec, 1.0 );\n\t\t#else\n\t\t\tvec4 envMapColor = vec4( 0.0 );\n\t\t#endif\n\t\treturn PI * envMapColor.rgb * envMapIntensity;\n\t}\n\tfloat getSpecularMIPLevel( const in float blinnShininessExponent, const in int maxMIPLevel ) {\n\t\tfloat maxMIPLevelScalar = float( maxMIPLevel );\n\t\tfloat desiredMIPLevel = maxMIPLevelScalar - 0.79248 - 0.5 * log2( pow2( blinnShininessExponent ) + 1.0 );\n\t\treturn clamp( desiredMIPLevel, 0.0, maxMIPLevelScalar );\n\t}\n\tvec3 getLightProbeIndirectRadiance( const in GeometricContext geometry, const in float blinnShininessExponent, const in int maxMIPLevel ) {\n\t\t#ifdef ENVMAP_MODE_REFLECTION\n\t\t\tvec3 reflectVec = reflect( -geometry.viewDir, geometry.normal );\n\t\t#else\n\t\t\tvec3 reflectVec = refract( -geometry.viewDir, geometry.normal, refractionRatio );\n\t\t#endif\n\t\treflectVec = inverseTransformDirection( reflectVec, viewMatrix );\n\t\tfloat specularMIPLevel = getSpecularMIPLevel( blinnShininessExponent, maxMIPLevel );\n\t\t#ifdef ENVMAP_TYPE_CUBE\n\t\t\tvec3 queryReflectVec = vec3( flipEnvMap * reflectVec.x, reflectVec.yz );\n\t\t\t#ifdef TEXTURE_LOD_EXT\n\t\t\t\tvec4 envMapColor = textureCubeLodEXT( envMap, queryReflectVec, specularMIPLevel );\n\t\t\t#else\n\t\t\t\tvec4 envMapColor = textureCube( envMap, queryReflectVec, specularMIPLevel );\n\t\t\t#endif\n\t\t\tenvMapColor.rgb = envMapTexelToLinear( envMapColor ).rgb;\n\t\t#elif defined( ENVMAP_TYPE_CUBE_UV )\n\t\t\tvec3 queryReflectVec = vec3( flipEnvMap * reflectVec.x, reflectVec.yz );\n\t\t\tvec4 envMapColor = textureCubeUV(queryReflectVec, BlinnExponentToGGXRoughness(blinnShininessExponent));\n\t\t#elif defined( ENVMAP_TYPE_EQUIREC )\n\t\t\tvec2 sampleUV;\n\t\t\tsampleUV.y = saturate( reflectVec.y * 0.5 + 0.5 );\n\t\t\tsampleUV.x = atan( reflectVec.z, reflectVec.x ) * RECIPROCAL_PI2 + 0.5;\n\t\t\t#ifdef TEXTURE_LOD_EXT\n\t\t\t\tvec4 envMapColor = texture2DLodEXT( envMap, sampleUV, specularMIPLevel );\n\t\t\t#else\n\t\t\t\tvec4 envMapColor = texture2D( envMap, sampleUV, specularMIPLevel );\n\t\t\t#endif\n\t\t\tenvMapColor.rgb = envMapTexelToLinear( envMapColor ).rgb;\n\t\t#elif defined( ENVMAP_TYPE_SPHERE )\n\t\t\tvec3 reflectView = normalize( ( viewMatrix * vec4( reflectVec, 0.0 ) ).xyz + vec3( 0.0,0.0,1.0 ) );\n\t\t\t#ifdef TEXTURE_LOD_EXT\n\t\t\t\tvec4 envMapColor = texture2DLodEXT( envMap, reflectView.xy * 0.5 + 0.5, specularMIPLevel );\n\t\t\t#else\n\t\t\t\tvec4 envMapColor = texture2D( envMap, reflectView.xy * 0.5 + 0.5, specularMIPLevel );\n\t\t\t#endif\n\t\t\tenvMapColor.rgb = envMapTexelToLinear( envMapColor ).rgb;\n\t\t#endif\n\t\treturn envMapColor.rgb * envMapIntensity;\n\t}\n#endif\n", -lights_phong_fragment:"BlinnPhongMaterial material;\nmaterial.diffuseColor = diffuseColor.rgb;\nmaterial.specularColor = specular;\nmaterial.specularShininess = shininess;\nmaterial.specularStrength = specularStrength;\n",lights_phong_pars_fragment:"varying vec3 vViewPosition;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\nstruct BlinnPhongMaterial {\n\tvec3\tdiffuseColor;\n\tvec3\tspecularColor;\n\tfloat\tspecularShininess;\n\tfloat\tspecularStrength;\n};\n#if NUM_RECT_AREA_LIGHTS > 0\n void RE_Direct_RectArea_BlinnPhong( const in RectAreaLight rectAreaLight, const in GeometricContext geometry, const in BlinnPhongMaterial material, inout ReflectedLight reflectedLight ) {\n vec3 matDiffColor = material.diffuseColor;\n vec3 matSpecColor = material.specularColor;\n vec3 lightColor = rectAreaLight.color;\n float roughness = BlinnExponentToGGXRoughness( material.specularShininess );\n vec3 spec = Rect_Area_Light_Specular_Reflectance(\n geometry,\n rectAreaLight.position, rectAreaLight.halfWidth, rectAreaLight.halfHeight,\n roughness,\n ltcMat, ltcMag );\n vec3 diff = Rect_Area_Light_Diffuse_Reflectance(\n geometry,\n rectAreaLight.position, rectAreaLight.halfWidth, rectAreaLight.halfHeight );\n reflectedLight.directSpecular += lightColor * matSpecColor * spec / PI2;\n reflectedLight.directDiffuse += lightColor * matDiffColor * diff / PI2;\n }\n#endif\nvoid RE_Direct_BlinnPhong( const in IncidentLight directLight, const in GeometricContext geometry, const in BlinnPhongMaterial material, inout ReflectedLight reflectedLight ) {\n\t#ifdef TOON\n\t\tvec3 irradiance = getGradientIrradiance( geometry.normal, directLight.direction ) * directLight.color;\n\t#else\n\t\tfloat dotNL = saturate( dot( geometry.normal, directLight.direction ) );\n\t\tvec3 irradiance = dotNL * directLight.color;\n\t#endif\n\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\tirradiance *= PI;\n\t#endif\n\treflectedLight.directDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\n\treflectedLight.directSpecular += irradiance * BRDF_Specular_BlinnPhong( directLight, geometry, material.specularColor, material.specularShininess ) * material.specularStrength;\n}\nvoid RE_IndirectDiffuse_BlinnPhong( const in vec3 irradiance, const in GeometricContext geometry, const in BlinnPhongMaterial material, inout ReflectedLight reflectedLight ) {\n\treflectedLight.indirectDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\n}\n#define RE_Direct\t\t\t\tRE_Direct_BlinnPhong\n#define RE_Direct_RectArea\t\tRE_Direct_RectArea_BlinnPhong\n#define RE_IndirectDiffuse\t\tRE_IndirectDiffuse_BlinnPhong\n#define Material_LightProbeLOD( material )\t(0)\n", -lights_physical_fragment:"PhysicalMaterial material;\nmaterial.diffuseColor = diffuseColor.rgb * ( 1.0 - metalnessFactor );\nmaterial.specularRoughness = clamp( roughnessFactor, 0.04, 1.0 );\n#ifdef STANDARD\n\tmaterial.specularColor = mix( vec3( DEFAULT_SPECULAR_COEFFICIENT ), diffuseColor.rgb, metalnessFactor );\n#else\n\tmaterial.specularColor = mix( vec3( MAXIMUM_SPECULAR_COEFFICIENT * pow2( reflectivity ) ), diffuseColor.rgb, metalnessFactor );\n\tmaterial.clearCoat = saturate( clearCoat );\tmaterial.clearCoatRoughness = clamp( clearCoatRoughness, 0.04, 1.0 );\n#endif\n", -lights_physical_pars_fragment:"struct PhysicalMaterial {\n\tvec3\tdiffuseColor;\n\tfloat\tspecularRoughness;\n\tvec3\tspecularColor;\n\t#ifndef STANDARD\n\t\tfloat clearCoat;\n\t\tfloat clearCoatRoughness;\n\t#endif\n};\n#define MAXIMUM_SPECULAR_COEFFICIENT 0.16\n#define DEFAULT_SPECULAR_COEFFICIENT 0.04\nfloat clearCoatDHRApprox( const in float roughness, const in float dotNL ) {\n\treturn DEFAULT_SPECULAR_COEFFICIENT + ( 1.0 - DEFAULT_SPECULAR_COEFFICIENT ) * ( pow( 1.0 - dotNL, 5.0 ) * pow( 1.0 - roughness, 2.0 ) );\n}\n#if NUM_RECT_AREA_LIGHTS > 0\n void RE_Direct_RectArea_Physical( const in RectAreaLight rectAreaLight, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\n vec3 matDiffColor = material.diffuseColor;\n vec3 matSpecColor = material.specularColor;\n vec3 lightColor = rectAreaLight.color;\n float roughness = material.specularRoughness;\n vec3 spec = Rect_Area_Light_Specular_Reflectance(\n geometry,\n rectAreaLight.position, rectAreaLight.halfWidth, rectAreaLight.halfHeight,\n roughness,\n ltcMat, ltcMag );\n vec3 diff = Rect_Area_Light_Diffuse_Reflectance(\n geometry,\n rectAreaLight.position, rectAreaLight.halfWidth, rectAreaLight.halfHeight );\n reflectedLight.directSpecular += lightColor * matSpecColor * spec;\n reflectedLight.directDiffuse += lightColor * matDiffColor * diff;\n }\n#endif\nvoid RE_Direct_Physical( const in IncidentLight directLight, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\n\tfloat dotNL = saturate( dot( geometry.normal, directLight.direction ) );\n\tvec3 irradiance = dotNL * directLight.color;\n\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\tirradiance *= PI;\n\t#endif\n\t#ifndef STANDARD\n\t\tfloat clearCoatDHR = material.clearCoat * clearCoatDHRApprox( material.clearCoatRoughness, dotNL );\n\t#else\n\t\tfloat clearCoatDHR = 0.0;\n\t#endif\n\treflectedLight.directSpecular += ( 1.0 - clearCoatDHR ) * irradiance * BRDF_Specular_GGX( directLight, geometry, material.specularColor, material.specularRoughness );\n\treflectedLight.directDiffuse += ( 1.0 - clearCoatDHR ) * irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\n\t#ifndef STANDARD\n\t\treflectedLight.directSpecular += irradiance * material.clearCoat * BRDF_Specular_GGX( directLight, geometry, vec3( DEFAULT_SPECULAR_COEFFICIENT ), material.clearCoatRoughness );\n\t#endif\n}\nvoid RE_IndirectDiffuse_Physical( const in vec3 irradiance, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\n\treflectedLight.indirectDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\n}\nvoid RE_IndirectSpecular_Physical( const in vec3 radiance, const in vec3 clearCoatRadiance, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\n\t#ifndef STANDARD\n\t\tfloat dotNV = saturate( dot( geometry.normal, geometry.viewDir ) );\n\t\tfloat dotNL = dotNV;\n\t\tfloat clearCoatDHR = material.clearCoat * clearCoatDHRApprox( material.clearCoatRoughness, dotNL );\n\t#else\n\t\tfloat clearCoatDHR = 0.0;\n\t#endif\n\treflectedLight.indirectSpecular += ( 1.0 - clearCoatDHR ) * radiance * BRDF_Specular_GGX_Environment( geometry, material.specularColor, material.specularRoughness );\n\t#ifndef STANDARD\n\t\treflectedLight.indirectSpecular += clearCoatRadiance * material.clearCoat * BRDF_Specular_GGX_Environment( geometry, vec3( DEFAULT_SPECULAR_COEFFICIENT ), material.clearCoatRoughness );\n\t#endif\n}\n#define RE_Direct\t\t\t\tRE_Direct_Physical\n#define RE_Direct_RectArea\t\tRE_Direct_RectArea_Physical\n#define RE_IndirectDiffuse\t\tRE_IndirectDiffuse_Physical\n#define RE_IndirectSpecular\t\tRE_IndirectSpecular_Physical\n#define Material_BlinnShininessExponent( material ) GGXRoughnessToBlinnExponent( material.specularRoughness )\n#define Material_ClearCoat_BlinnShininessExponent( material ) GGXRoughnessToBlinnExponent( material.clearCoatRoughness )\nfloat computeSpecularOcclusion( const in float dotNV, const in float ambientOcclusion, const in float roughness ) {\n\treturn saturate( pow( dotNV + ambientOcclusion, exp2( - 16.0 * roughness - 1.0 ) ) - 1.0 + ambientOcclusion );\n}\n", -lights_template:"\nGeometricContext geometry;\ngeometry.position = - vViewPosition;\ngeometry.normal = normal;\ngeometry.viewDir = normalize( vViewPosition );\nIncidentLight directLight;\n#if ( NUM_POINT_LIGHTS > 0 ) && defined( RE_Direct )\n\tPointLight pointLight;\n\tfor ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {\n\t\tpointLight = pointLights[ i ];\n\t\tgetPointDirectLightIrradiance( pointLight, geometry, directLight );\n\t\t#ifdef USE_SHADOWMAP\n\t\tdirectLight.color *= all( bvec2( pointLight.shadow, directLight.visible ) ) ? getPointShadow( pointShadowMap[ i ], pointLight.shadowMapSize, pointLight.shadowBias, pointLight.shadowRadius, vPointShadowCoord[ i ] ) : 1.0;\n\t\t#endif\n\t\tRE_Direct( directLight, geometry, material, reflectedLight );\n\t}\n#endif\n#if ( NUM_SPOT_LIGHTS > 0 ) && defined( RE_Direct )\n\tSpotLight spotLight;\n\tfor ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {\n\t\tspotLight = spotLights[ i ];\n\t\tgetSpotDirectLightIrradiance( spotLight, geometry, directLight );\n\t\t#ifdef USE_SHADOWMAP\n\t\tdirectLight.color *= all( bvec2( spotLight.shadow, directLight.visible ) ) ? getShadow( spotShadowMap[ i ], spotLight.shadowMapSize, spotLight.shadowBias, spotLight.shadowRadius, vSpotShadowCoord[ i ] ) : 1.0;\n\t\t#endif\n\t\tRE_Direct( directLight, geometry, material, reflectedLight );\n\t}\n#endif\n#if ( NUM_DIR_LIGHTS > 0 ) && defined( RE_Direct )\n\tDirectionalLight directionalLight;\n\tfor ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {\n\t\tdirectionalLight = directionalLights[ i ];\n\t\tgetDirectionalDirectLightIrradiance( directionalLight, geometry, directLight );\n\t\t#ifdef USE_SHADOWMAP\n\t\tdirectLight.color *= all( bvec2( directionalLight.shadow, directLight.visible ) ) ? getShadow( directionalShadowMap[ i ], directionalLight.shadowMapSize, directionalLight.shadowBias, directionalLight.shadowRadius, vDirectionalShadowCoord[ i ] ) : 1.0;\n\t\t#endif\n\t\tRE_Direct( directLight, geometry, material, reflectedLight );\n\t}\n#endif\n#if ( NUM_RECT_AREA_LIGHTS > 0 ) && defined( RE_Direct_RectArea )\n\tRectAreaLight rectAreaLight;\n\tfor ( int i = 0; i < NUM_RECT_AREA_LIGHTS; i ++ ) {\n\t\trectAreaLight = rectAreaLights[ i ];\n\t\tRE_Direct_RectArea( rectAreaLight, geometry, material, reflectedLight );\n\t}\n#endif\n#if defined( RE_IndirectDiffuse )\n\tvec3 irradiance = getAmbientLightIrradiance( ambientLightColor );\n\t#ifdef USE_LIGHTMAP\n\t\tvec3 lightMapIrradiance = texture2D( lightMap, vUv2 ).xyz * lightMapIntensity;\n\t\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\t\tlightMapIrradiance *= PI;\n\t\t#endif\n\t\tirradiance += lightMapIrradiance;\n\t#endif\n\t#if ( NUM_HEMI_LIGHTS > 0 )\n\t\tfor ( int i = 0; i < NUM_HEMI_LIGHTS; i ++ ) {\n\t\t\tirradiance += getHemisphereLightIrradiance( hemisphereLights[ i ], geometry );\n\t\t}\n\t#endif\n\t#if defined( USE_ENVMAP ) && defined( PHYSICAL ) && defined( ENVMAP_TYPE_CUBE_UV )\n\t \tirradiance += getLightProbeIndirectIrradiance( geometry, 8 );\n\t#endif\n\tRE_IndirectDiffuse( irradiance, geometry, material, reflectedLight );\n#endif\n#if defined( USE_ENVMAP ) && defined( RE_IndirectSpecular )\n\tvec3 radiance = getLightProbeIndirectRadiance( geometry, Material_BlinnShininessExponent( material ), 8 );\n\t#ifndef STANDARD\n\t\tvec3 clearCoatRadiance = getLightProbeIndirectRadiance( geometry, Material_ClearCoat_BlinnShininessExponent( material ), 8 );\n\t#else\n\t\tvec3 clearCoatRadiance = vec3( 0.0 );\n\t#endif\n\t\t\n\tRE_IndirectSpecular( radiance, clearCoatRadiance, geometry, material, reflectedLight );\n#endif\n", -logdepthbuf_fragment:"#if defined(USE_LOGDEPTHBUF) && defined(USE_LOGDEPTHBUF_EXT)\n\tgl_FragDepthEXT = log2(vFragDepth) * logDepthBufFC * 0.5;\n#endif",logdepthbuf_pars_fragment:"#ifdef USE_LOGDEPTHBUF\n\tuniform float logDepthBufFC;\n\t#ifdef USE_LOGDEPTHBUF_EXT\n\t\tvarying float vFragDepth;\n\t#endif\n#endif\n",logdepthbuf_pars_vertex:"#ifdef USE_LOGDEPTHBUF\n\t#ifdef USE_LOGDEPTHBUF_EXT\n\t\tvarying float vFragDepth;\n\t#endif\n\tuniform float logDepthBufFC;\n#endif",logdepthbuf_vertex:"#ifdef USE_LOGDEPTHBUF\n\tgl_Position.z = log2(max( EPSILON, gl_Position.w + 1.0 )) * logDepthBufFC;\n\t#ifdef USE_LOGDEPTHBUF_EXT\n\t\tvFragDepth = 1.0 + gl_Position.w;\n\t#else\n\t\tgl_Position.z = (gl_Position.z - 1.0) * gl_Position.w;\n\t#endif\n#endif\n", -map_fragment:"#ifdef USE_MAP\n\tvec4 texelColor = texture2D( map, vUv );\n\ttexelColor = mapTexelToLinear( texelColor );\n\tdiffuseColor *= texelColor;\n#endif\n",map_pars_fragment:"#ifdef USE_MAP\n\tuniform sampler2D map;\n#endif\n",map_particle_fragment:"#ifdef USE_MAP\n\tvec4 mapTexel = texture2D( map, vec2( gl_PointCoord.x, 1.0 - gl_PointCoord.y ) * offsetRepeat.zw + offsetRepeat.xy );\n\tdiffuseColor *= mapTexelToLinear( mapTexel );\n#endif\n",map_particle_pars_fragment:"#ifdef USE_MAP\n\tuniform vec4 offsetRepeat;\n\tuniform sampler2D map;\n#endif\n", -metalnessmap_fragment:"float metalnessFactor = metalness;\n#ifdef USE_METALNESSMAP\n\tvec4 texelMetalness = texture2D( metalnessMap, vUv );\n\tmetalnessFactor *= texelMetalness.r;\n#endif\n",metalnessmap_pars_fragment:"#ifdef USE_METALNESSMAP\n\tuniform sampler2D metalnessMap;\n#endif",morphnormal_vertex:"#ifdef USE_MORPHNORMALS\n\tobjectNormal += ( morphNormal0 - normal ) * morphTargetInfluences[ 0 ];\n\tobjectNormal += ( morphNormal1 - normal ) * morphTargetInfluences[ 1 ];\n\tobjectNormal += ( morphNormal2 - normal ) * morphTargetInfluences[ 2 ];\n\tobjectNormal += ( morphNormal3 - normal ) * morphTargetInfluences[ 3 ];\n#endif\n", -morphtarget_pars_vertex:"#ifdef USE_MORPHTARGETS\n\t#ifndef USE_MORPHNORMALS\n\tuniform float morphTargetInfluences[ 8 ];\n\t#else\n\tuniform float morphTargetInfluences[ 4 ];\n\t#endif\n#endif",morphtarget_vertex:"#ifdef USE_MORPHTARGETS\n\ttransformed += ( morphTarget0 - position ) * morphTargetInfluences[ 0 ];\n\ttransformed += ( morphTarget1 - position ) * morphTargetInfluences[ 1 ];\n\ttransformed += ( morphTarget2 - position ) * morphTargetInfluences[ 2 ];\n\ttransformed += ( morphTarget3 - position ) * morphTargetInfluences[ 3 ];\n\t#ifndef USE_MORPHNORMALS\n\ttransformed += ( morphTarget4 - position ) * morphTargetInfluences[ 4 ];\n\ttransformed += ( morphTarget5 - position ) * morphTargetInfluences[ 5 ];\n\ttransformed += ( morphTarget6 - position ) * morphTargetInfluences[ 6 ];\n\ttransformed += ( morphTarget7 - position ) * morphTargetInfluences[ 7 ];\n\t#endif\n#endif\n", -normal_flip:"#ifdef DOUBLE_SIDED\n\tfloat flipNormal = ( float( gl_FrontFacing ) * 2.0 - 1.0 );\n#else\n\tfloat flipNormal = 1.0;\n#endif\n",normal_fragment:"#ifdef FLAT_SHADED\n\tvec3 fdx = vec3( dFdx( vViewPosition.x ), dFdx( vViewPosition.y ), dFdx( vViewPosition.z ) );\n\tvec3 fdy = vec3( dFdy( vViewPosition.x ), dFdy( vViewPosition.y ), dFdy( vViewPosition.z ) );\n\tvec3 normal = normalize( cross( fdx, fdy ) );\n#else\n\tvec3 normal = normalize( vNormal ) * flipNormal;\n#endif\n#ifdef USE_NORMALMAP\n\tnormal = perturbNormal2Arb( -vViewPosition, normal );\n#elif defined( USE_BUMPMAP )\n\tnormal = perturbNormalArb( -vViewPosition, normal, dHdxy_fwd() );\n#endif\n", -normalmap_pars_fragment:"#ifdef USE_NORMALMAP\n\tuniform sampler2D normalMap;\n\tuniform vec2 normalScale;\n\tvec3 perturbNormal2Arb( vec3 eye_pos, vec3 surf_norm ) {\n\t\tvec3 q0 = dFdx( eye_pos.xyz );\n\t\tvec3 q1 = dFdy( eye_pos.xyz );\n\t\tvec2 st0 = dFdx( vUv.st );\n\t\tvec2 st1 = dFdy( vUv.st );\n\t\tvec3 S = normalize( q0 * st1.t - q1 * st0.t );\n\t\tvec3 T = normalize( -q0 * st1.s + q1 * st0.s );\n\t\tvec3 N = normalize( surf_norm );\n\t\tvec3 mapN = texture2D( normalMap, vUv ).xyz * 2.0 - 1.0;\n\t\tmapN.xy = normalScale * mapN.xy;\n\t\tmat3 tsn = mat3( S, T, N );\n\t\treturn normalize( tsn * mapN );\n\t}\n#endif\n", -packing:"vec3 packNormalToRGB( const in vec3 normal ) {\n return normalize( normal ) * 0.5 + 0.5;\n}\nvec3 unpackRGBToNormal( const in vec3 rgb ) {\n return 1.0 - 2.0 * rgb.xyz;\n}\nconst float PackUpscale = 256. / 255.;const float UnpackDownscale = 255. / 256.;\nconst vec3 PackFactors = vec3( 256. * 256. * 256., 256. * 256., 256. );\nconst vec4 UnpackFactors = UnpackDownscale / vec4( PackFactors, 1. );\nconst float ShiftRight8 = 1. / 256.;\nvec4 packDepthToRGBA( const in float v ) {\n\tvec4 r = vec4( fract( v * PackFactors ), v );\n\tr.yzw -= r.xyz * ShiftRight8;\treturn r * PackUpscale;\n}\nfloat unpackRGBAToDepth( const in vec4 v ) {\n\treturn dot( v, UnpackFactors );\n}\nfloat viewZToOrthographicDepth( const in float viewZ, const in float near, const in float far ) {\n return ( viewZ + near ) / ( near - far );\n}\nfloat orthographicDepthToViewZ( const in float linearClipZ, const in float near, const in float far ) {\n return linearClipZ * ( near - far ) - near;\n}\nfloat viewZToPerspectiveDepth( const in float viewZ, const in float near, const in float far ) {\n return (( near + viewZ ) * far ) / (( far - near ) * viewZ );\n}\nfloat perspectiveDepthToViewZ( const in float invClipZ, const in float near, const in float far ) {\n return ( near * far ) / ( ( far - near ) * invClipZ - far );\n}\n", -premultiplied_alpha_fragment:"#ifdef PREMULTIPLIED_ALPHA\n\tgl_FragColor.rgb *= gl_FragColor.a;\n#endif\n",project_vertex:"#ifdef USE_SKINNING\n\tvec4 mvPosition = modelViewMatrix * skinned;\n#else\n\tvec4 mvPosition = modelViewMatrix * vec4( transformed, 1.0 );\n#endif\ngl_Position = projectionMatrix * mvPosition;\n",roughnessmap_fragment:"float roughnessFactor = roughness;\n#ifdef USE_ROUGHNESSMAP\n\tvec4 texelRoughness = texture2D( roughnessMap, vUv );\n\troughnessFactor *= texelRoughness.r;\n#endif\n", -roughnessmap_pars_fragment:"#ifdef USE_ROUGHNESSMAP\n\tuniform sampler2D roughnessMap;\n#endif",shadowmap_pars_fragment:"#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHTS > 0\n\t\tuniform sampler2D directionalShadowMap[ NUM_DIR_LIGHTS ];\n\t\tvarying vec4 vDirectionalShadowCoord[ NUM_DIR_LIGHTS ];\n\t#endif\n\t#if NUM_SPOT_LIGHTS > 0\n\t\tuniform sampler2D spotShadowMap[ NUM_SPOT_LIGHTS ];\n\t\tvarying vec4 vSpotShadowCoord[ NUM_SPOT_LIGHTS ];\n\t#endif\n\t#if NUM_POINT_LIGHTS > 0\n\t\tuniform sampler2D pointShadowMap[ NUM_POINT_LIGHTS ];\n\t\tvarying vec4 vPointShadowCoord[ NUM_POINT_LIGHTS ];\n\t#endif\n #if NUM_RECT_AREA_LIGHTS > 0\n #endif\n\tfloat texture2DCompare( sampler2D depths, vec2 uv, float compare ) {\n\t\treturn step( compare, unpackRGBAToDepth( texture2D( depths, uv ) ) );\n\t}\n\tfloat texture2DShadowLerp( sampler2D depths, vec2 size, vec2 uv, float compare ) {\n\t\tconst vec2 offset = vec2( 0.0, 1.0 );\n\t\tvec2 texelSize = vec2( 1.0 ) / size;\n\t\tvec2 centroidUV = floor( uv * size + 0.5 ) / size;\n\t\tfloat lb = texture2DCompare( depths, centroidUV + texelSize * offset.xx, compare );\n\t\tfloat lt = texture2DCompare( depths, centroidUV + texelSize * offset.xy, compare );\n\t\tfloat rb = texture2DCompare( depths, centroidUV + texelSize * offset.yx, compare );\n\t\tfloat rt = texture2DCompare( depths, centroidUV + texelSize * offset.yy, compare );\n\t\tvec2 f = fract( uv * size + 0.5 );\n\t\tfloat a = mix( lb, lt, f.y );\n\t\tfloat b = mix( rb, rt, f.y );\n\t\tfloat c = mix( a, b, f.x );\n\t\treturn c;\n\t}\n\tfloat getShadow( sampler2D shadowMap, vec2 shadowMapSize, float shadowBias, float shadowRadius, vec4 shadowCoord ) {\n\t\tshadowCoord.xyz /= shadowCoord.w;\n\t\tshadowCoord.z += shadowBias;\n\t\tbvec4 inFrustumVec = bvec4 ( shadowCoord.x >= 0.0, shadowCoord.x <= 1.0, shadowCoord.y >= 0.0, shadowCoord.y <= 1.0 );\n\t\tbool inFrustum = all( inFrustumVec );\n\t\tbvec2 frustumTestVec = bvec2( inFrustum, shadowCoord.z <= 1.0 );\n\t\tbool frustumTest = all( frustumTestVec );\n\t\tif ( frustumTest ) {\n\t\t#if defined( SHADOWMAP_TYPE_PCF )\n\t\t\tvec2 texelSize = vec2( 1.0 ) / shadowMapSize;\n\t\t\tfloat dx0 = - texelSize.x * shadowRadius;\n\t\t\tfloat dy0 = - texelSize.y * shadowRadius;\n\t\t\tfloat dx1 = + texelSize.x * shadowRadius;\n\t\t\tfloat dy1 = + texelSize.y * shadowRadius;\n\t\t\treturn (\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy, shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, dy1 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy1 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, dy1 ), shadowCoord.z )\n\t\t\t) * ( 1.0 / 9.0 );\n\t\t#elif defined( SHADOWMAP_TYPE_PCF_SOFT )\n\t\t\tvec2 texelSize = vec2( 1.0 ) / shadowMapSize;\n\t\t\tfloat dx0 = - texelSize.x * shadowRadius;\n\t\t\tfloat dy0 = - texelSize.y * shadowRadius;\n\t\t\tfloat dx1 = + texelSize.x * shadowRadius;\n\t\t\tfloat dy1 = + texelSize.y * shadowRadius;\n\t\t\treturn (\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( dx0, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( 0.0, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( dx1, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( dx0, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy, shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( dx1, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( dx0, dy1 ), shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( 0.0, dy1 ), shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( dx1, dy1 ), shadowCoord.z )\n\t\t\t) * ( 1.0 / 9.0 );\n\t\t#else\n\t\t\treturn texture2DCompare( shadowMap, shadowCoord.xy, shadowCoord.z );\n\t\t#endif\n\t\t}\n\t\treturn 1.0;\n\t}\n\tvec2 cubeToUV( vec3 v, float texelSizeY ) {\n\t\tvec3 absV = abs( v );\n\t\tfloat scaleToCube = 1.0 / max( absV.x, max( absV.y, absV.z ) );\n\t\tabsV *= scaleToCube;\n\t\tv *= scaleToCube * ( 1.0 - 2.0 * texelSizeY );\n\t\tvec2 planar = v.xy;\n\t\tfloat almostATexel = 1.5 * texelSizeY;\n\t\tfloat almostOne = 1.0 - almostATexel;\n\t\tif ( absV.z >= almostOne ) {\n\t\t\tif ( v.z > 0.0 )\n\t\t\t\tplanar.x = 4.0 - v.x;\n\t\t} else if ( absV.x >= almostOne ) {\n\t\t\tfloat signX = sign( v.x );\n\t\t\tplanar.x = v.z * signX + 2.0 * signX;\n\t\t} else if ( absV.y >= almostOne ) {\n\t\t\tfloat signY = sign( v.y );\n\t\t\tplanar.x = v.x + 2.0 * signY + 2.0;\n\t\t\tplanar.y = v.z * signY - 2.0;\n\t\t}\n\t\treturn vec2( 0.125, 0.25 ) * planar + vec2( 0.375, 0.75 );\n\t}\n\tfloat getPointShadow( sampler2D shadowMap, vec2 shadowMapSize, float shadowBias, float shadowRadius, vec4 shadowCoord ) {\n\t\tvec2 texelSize = vec2( 1.0 ) / ( shadowMapSize * vec2( 4.0, 2.0 ) );\n\t\tvec3 lightToPosition = shadowCoord.xyz;\n\t\tvec3 bd3D = normalize( lightToPosition );\n\t\tfloat dp = ( length( lightToPosition ) - shadowBias ) / 1000.0;\n\t\t#if defined( SHADOWMAP_TYPE_PCF ) || defined( SHADOWMAP_TYPE_PCF_SOFT )\n\t\t\tvec2 offset = vec2( - 1, 1 ) * shadowRadius * texelSize.y;\n\t\t\treturn (\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xyy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yyy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xyx, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yyx, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xxy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yxy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xxx, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yxx, texelSize.y ), dp )\n\t\t\t) * ( 1.0 / 9.0 );\n\t\t#else\n\t\t\treturn texture2DCompare( shadowMap, cubeToUV( bd3D, texelSize.y ), dp );\n\t\t#endif\n\t}\n#endif\n", -shadowmap_pars_vertex:"#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHTS > 0\n\t\tuniform mat4 directionalShadowMatrix[ NUM_DIR_LIGHTS ];\n\t\tvarying vec4 vDirectionalShadowCoord[ NUM_DIR_LIGHTS ];\n\t#endif\n\t#if NUM_SPOT_LIGHTS > 0\n\t\tuniform mat4 spotShadowMatrix[ NUM_SPOT_LIGHTS ];\n\t\tvarying vec4 vSpotShadowCoord[ NUM_SPOT_LIGHTS ];\n\t#endif\n\t#if NUM_POINT_LIGHTS > 0\n\t\tuniform mat4 pointShadowMatrix[ NUM_POINT_LIGHTS ];\n\t\tvarying vec4 vPointShadowCoord[ NUM_POINT_LIGHTS ];\n\t#endif\n #if NUM_RECT_AREA_LIGHTS > 0\n #endif\n#endif\n", -shadowmap_vertex:"#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {\n\t\tvDirectionalShadowCoord[ i ] = directionalShadowMatrix[ i ] * worldPosition;\n\t}\n\t#endif\n\t#if NUM_SPOT_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {\n\t\tvSpotShadowCoord[ i ] = spotShadowMatrix[ i ] * worldPosition;\n\t}\n\t#endif\n\t#if NUM_POINT_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {\n\t\tvPointShadowCoord[ i ] = pointShadowMatrix[ i ] * worldPosition;\n\t}\n\t#endif\n #if NUM_RECT_AREA_LIGHTS > 0\n #endif\n#endif\n", -shadowmask_pars_fragment:"float getShadowMask() {\n\tfloat shadow = 1.0;\n\t#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHTS > 0\n\tDirectionalLight directionalLight;\n\tfor ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {\n\t\tdirectionalLight = directionalLights[ i ];\n\t\tshadow *= bool( directionalLight.shadow ) ? getShadow( directionalShadowMap[ i ], directionalLight.shadowMapSize, directionalLight.shadowBias, directionalLight.shadowRadius, vDirectionalShadowCoord[ i ] ) : 1.0;\n\t}\n\t#endif\n\t#if NUM_SPOT_LIGHTS > 0\n\tSpotLight spotLight;\n\tfor ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {\n\t\tspotLight = spotLights[ i ];\n\t\tshadow *= bool( spotLight.shadow ) ? getShadow( spotShadowMap[ i ], spotLight.shadowMapSize, spotLight.shadowBias, spotLight.shadowRadius, vSpotShadowCoord[ i ] ) : 1.0;\n\t}\n\t#endif\n\t#if NUM_POINT_LIGHTS > 0\n\tPointLight pointLight;\n\tfor ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {\n\t\tpointLight = pointLights[ i ];\n\t\tshadow *= bool( pointLight.shadow ) ? getPointShadow( pointShadowMap[ i ], pointLight.shadowMapSize, pointLight.shadowBias, pointLight.shadowRadius, vPointShadowCoord[ i ] ) : 1.0;\n\t}\n\t#endif\n\t#if NUM_RECT_AREA_LIGHTS > 0\n\t#endif\n\t#endif\n\treturn shadow;\n}\n", -skinbase_vertex:"#ifdef USE_SKINNING\n\tmat4 boneMatX = getBoneMatrix( skinIndex.x );\n\tmat4 boneMatY = getBoneMatrix( skinIndex.y );\n\tmat4 boneMatZ = getBoneMatrix( skinIndex.z );\n\tmat4 boneMatW = getBoneMatrix( skinIndex.w );\n#endif",skinning_pars_vertex:"#ifdef USE_SKINNING\n\tuniform mat4 bindMatrix;\n\tuniform mat4 bindMatrixInverse;\n\t#ifdef BONE_TEXTURE\n\t\tuniform sampler2D boneTexture;\n\t\tuniform int boneTextureWidth;\n\t\tuniform int boneTextureHeight;\n\t\tmat4 getBoneMatrix( const in float i ) {\n\t\t\tfloat j = i * 4.0;\n\t\t\tfloat x = mod( j, float( boneTextureWidth ) );\n\t\t\tfloat y = floor( j / float( boneTextureWidth ) );\n\t\t\tfloat dx = 1.0 / float( boneTextureWidth );\n\t\t\tfloat dy = 1.0 / float( boneTextureHeight );\n\t\t\ty = dy * ( y + 0.5 );\n\t\t\tvec4 v1 = texture2D( boneTexture, vec2( dx * ( x + 0.5 ), y ) );\n\t\t\tvec4 v2 = texture2D( boneTexture, vec2( dx * ( x + 1.5 ), y ) );\n\t\t\tvec4 v3 = texture2D( boneTexture, vec2( dx * ( x + 2.5 ), y ) );\n\t\t\tvec4 v4 = texture2D( boneTexture, vec2( dx * ( x + 3.5 ), y ) );\n\t\t\tmat4 bone = mat4( v1, v2, v3, v4 );\n\t\t\treturn bone;\n\t\t}\n\t#else\n\t\tuniform mat4 boneMatrices[ MAX_BONES ];\n\t\tmat4 getBoneMatrix( const in float i ) {\n\t\t\tmat4 bone = boneMatrices[ int(i) ];\n\t\t\treturn bone;\n\t\t}\n\t#endif\n#endif\n", -skinning_vertex:"#ifdef USE_SKINNING\n\tvec4 skinVertex = bindMatrix * vec4( transformed, 1.0 );\n\tvec4 skinned = vec4( 0.0 );\n\tskinned += boneMatX * skinVertex * skinWeight.x;\n\tskinned += boneMatY * skinVertex * skinWeight.y;\n\tskinned += boneMatZ * skinVertex * skinWeight.z;\n\tskinned += boneMatW * skinVertex * skinWeight.w;\n\tskinned = bindMatrixInverse * skinned;\n#endif\n",skinnormal_vertex:"#ifdef USE_SKINNING\n\tmat4 skinMatrix = mat4( 0.0 );\n\tskinMatrix += skinWeight.x * boneMatX;\n\tskinMatrix += skinWeight.y * boneMatY;\n\tskinMatrix += skinWeight.z * boneMatZ;\n\tskinMatrix += skinWeight.w * boneMatW;\n\tskinMatrix = bindMatrixInverse * skinMatrix * bindMatrix;\n\tobjectNormal = vec4( skinMatrix * vec4( objectNormal, 0.0 ) ).xyz;\n#endif\n", -specularmap_fragment:"float specularStrength;\n#ifdef USE_SPECULARMAP\n\tvec4 texelSpecular = texture2D( specularMap, vUv );\n\tspecularStrength = texelSpecular.r;\n#else\n\tspecularStrength = 1.0;\n#endif",specularmap_pars_fragment:"#ifdef USE_SPECULARMAP\n\tuniform sampler2D specularMap;\n#endif",tonemapping_fragment:"#if defined( TONE_MAPPING )\n gl_FragColor.rgb = toneMapping( gl_FragColor.rgb );\n#endif\n",tonemapping_pars_fragment:"#define saturate(a) clamp( a, 0.0, 1.0 )\nuniform float toneMappingExposure;\nuniform float toneMappingWhitePoint;\nvec3 LinearToneMapping( vec3 color ) {\n return toneMappingExposure * color;\n}\nvec3 ReinhardToneMapping( vec3 color ) {\n color *= toneMappingExposure;\n return saturate( color / ( vec3( 1.0 ) + color ) );\n}\n#define Uncharted2Helper( x ) max( ( ( x * ( 0.15 * x + 0.10 * 0.50 ) + 0.20 * 0.02 ) / ( x * ( 0.15 * x + 0.50 ) + 0.20 * 0.30 ) ) - 0.02 / 0.30, vec3( 0.0 ) )\nvec3 Uncharted2ToneMapping( vec3 color ) {\n color *= toneMappingExposure;\n return saturate( Uncharted2Helper( color ) / Uncharted2Helper( vec3( toneMappingWhitePoint ) ) );\n}\nvec3 OptimizedCineonToneMapping( vec3 color ) {\n color *= toneMappingExposure;\n color = max( vec3( 0.0 ), color - 0.004 );\n return pow( ( color * ( 6.2 * color + 0.5 ) ) / ( color * ( 6.2 * color + 1.7 ) + 0.06 ), vec3( 2.2 ) );\n}\n", -uv_pars_fragment:"#if defined( USE_MAP ) || defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( USE_SPECULARMAP ) || defined( USE_ALPHAMAP ) || defined( USE_EMISSIVEMAP ) || defined( USE_ROUGHNESSMAP ) || defined( USE_METALNESSMAP )\n\tvarying vec2 vUv;\n#endif",uv_pars_vertex:"#if defined( USE_MAP ) || defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( USE_SPECULARMAP ) || defined( USE_ALPHAMAP ) || defined( USE_EMISSIVEMAP ) || defined( USE_ROUGHNESSMAP ) || defined( USE_METALNESSMAP )\n\tvarying vec2 vUv;\n\tuniform vec4 offsetRepeat;\n#endif\n", -uv_vertex:"#if defined( USE_MAP ) || defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( USE_SPECULARMAP ) || defined( USE_ALPHAMAP ) || defined( USE_EMISSIVEMAP ) || defined( USE_ROUGHNESSMAP ) || defined( USE_METALNESSMAP )\n\tvUv = uv * offsetRepeat.zw + offsetRepeat.xy;\n#endif",uv2_pars_fragment:"#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\n\tvarying vec2 vUv2;\n#endif",uv2_pars_vertex:"#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\n\tattribute vec2 uv2;\n\tvarying vec2 vUv2;\n#endif", -uv2_vertex:"#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\n\tvUv2 = uv2;\n#endif",worldpos_vertex:"#if defined( USE_ENVMAP ) || defined( PHONG ) || defined( PHYSICAL ) || defined( LAMBERT ) || defined ( USE_SHADOWMAP )\n\t#ifdef USE_SKINNING\n\t\tvec4 worldPosition = modelMatrix * skinned;\n\t#else\n\t\tvec4 worldPosition = modelMatrix * vec4( transformed, 1.0 );\n\t#endif\n#endif\n",cube_frag:"uniform samplerCube tCube;\nuniform float tFlip;\nuniform float opacity;\nvarying vec3 vWorldPosition;\n#include \nvoid main() {\n\tgl_FragColor = textureCube( tCube, vec3( tFlip * vWorldPosition.x, vWorldPosition.yz ) );\n\tgl_FragColor.a *= opacity;\n}\n", -cube_vert:"varying vec3 vWorldPosition;\n#include \nvoid main() {\n\tvWorldPosition = transformDirection( position, modelMatrix );\n\t#include \n\t#include \n}\n",depth_frag:"#if DEPTH_PACKING == 3200\n\tuniform float opacity;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( 1.0 );\n\t#if DEPTH_PACKING == 3200\n\t\tdiffuseColor.a = opacity;\n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#if DEPTH_PACKING == 3200\n\t\tgl_FragColor = vec4( vec3( gl_FragCoord.z ), opacity );\n\t#elif DEPTH_PACKING == 3201\n\t\tgl_FragColor = packDepthToRGBA( gl_FragCoord.z );\n\t#endif\n}\n", -depth_vert:"#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}\n", -distanceRGBA_frag:"uniform vec3 lightPos;\nvarying vec4 vWorldPosition;\n#include \n#include \n#include \nvoid main () {\n\t#include \n\tgl_FragColor = packDepthToRGBA( length( vWorldPosition.xyz - lightPos.xyz ) / 1000.0 );\n}\n",distanceRGBA_vert:"varying vec4 vWorldPosition;\n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvWorldPosition = worldPosition;\n}\n", -equirect_frag:"uniform sampler2D tEquirect;\nuniform float tFlip;\nvarying vec3 vWorldPosition;\n#include \nvoid main() {\n\tvec3 direction = normalize( vWorldPosition );\n\tvec2 sampleUV;\n\tsampleUV.y = saturate( tFlip * direction.y * -0.5 + 0.5 );\n\tsampleUV.x = atan( direction.z, direction.x ) * RECIPROCAL_PI2 + 0.5;\n\tgl_FragColor = texture2D( tEquirect, sampleUV );\n}\n",equirect_vert:"varying vec3 vWorldPosition;\n#include \nvoid main() {\n\tvWorldPosition = transformDirection( position, modelMatrix );\n\t#include \n\t#include \n}\n", -linedashed_frag:"uniform vec3 diffuse;\nuniform float opacity;\nuniform float dashSize;\nuniform float totalSize;\nvarying float vLineDistance;\n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tif ( mod( vLineDistance, totalSize ) > dashSize ) {\n\t\tdiscard;\n\t}\n\tvec3 outgoingLight = vec3( 0.0 );\n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\toutgoingLight = diffuseColor.rgb;\n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n\t#include \n}\n", -linedashed_vert:"uniform float scale;\nattribute float lineDistance;\nvarying float vLineDistance;\n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvLineDistance = scale * lineDistance;\n\tvec4 mvPosition = modelViewMatrix * vec4( position, 1.0 );\n\tgl_Position = projectionMatrix * mvPosition;\n\t#include \n\t#include \n}\n",meshbasic_frag:"uniform vec3 diffuse;\nuniform float opacity;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\t#ifdef USE_LIGHTMAP\n\t\treflectedLight.indirectDiffuse += texture2D( lightMap, vUv2 ).xyz * lightMapIntensity;\n\t#else\n\t\treflectedLight.indirectDiffuse += vec3( 1.0 );\n\t#endif\n\t#include \n\treflectedLight.indirectDiffuse *= diffuseColor.rgb;\n\tvec3 outgoingLight = reflectedLight.indirectDiffuse;\n\t#include \n\t#include \n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n\t#include \n}\n", -meshbasic_vert:"#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#ifdef USE_ENVMAP\n\t#include \n\t#include \n\t#include \n\t#include \n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}\n", -meshlambert_frag:"uniform vec3 diffuse;\nuniform vec3 emissive;\nuniform float opacity;\nvarying vec3 vLightFront;\n#ifdef DOUBLE_SIDED\n\tvarying vec3 vLightBack;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\tvec3 totalEmissiveRadiance = emissive;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\treflectedLight.indirectDiffuse = getAmbientLightIrradiance( ambientLightColor );\n\t#include \n\treflectedLight.indirectDiffuse *= BRDF_Diffuse_Lambert( diffuseColor.rgb );\n\t#ifdef DOUBLE_SIDED\n\t\treflectedLight.directDiffuse = ( gl_FrontFacing ) ? vLightFront : vLightBack;\n\t#else\n\t\treflectedLight.directDiffuse = vLightFront;\n\t#endif\n\treflectedLight.directDiffuse *= BRDF_Diffuse_Lambert( diffuseColor.rgb ) * getShadowMask();\n\t#include \n\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + totalEmissiveRadiance;\n\t#include \n\t#include \n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n\t#include \n}\n", -meshlambert_vert:"#define LAMBERT\nvarying vec3 vLightFront;\n#ifdef DOUBLE_SIDED\n\tvarying vec3 vLightBack;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}\n", -meshphong_frag:"#define PHONG\nuniform vec3 diffuse;\nuniform vec3 emissive;\nuniform vec3 specular;\nuniform float shininess;\nuniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\tvec3 totalEmissiveRadiance = emissive;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + reflectedLight.directSpecular + reflectedLight.indirectSpecular + totalEmissiveRadiance;\n\t#include \n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n\t#include \n}\n", -meshphong_vert:"#define PHONG\nvarying vec3 vViewPosition;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n#ifndef FLAT_SHADED\n\tvNormal = normalize( transformedNormal );\n#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvViewPosition = - mvPosition.xyz;\n\t#include \n\t#include \n\t#include \n}\n", -meshphysical_frag:"#define PHYSICAL\nuniform vec3 diffuse;\nuniform vec3 emissive;\nuniform float roughness;\nuniform float metalness;\nuniform float opacity;\n#ifndef STANDARD\n\tuniform float clearCoat;\n\tuniform float clearCoatRoughness;\n#endif\nvarying vec3 vViewPosition;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\tvec3 totalEmissiveRadiance = emissive;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + reflectedLight.directSpecular + reflectedLight.indirectSpecular + totalEmissiveRadiance;\n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n\t#include \n}\n", -meshphysical_vert:"#define PHYSICAL\nvarying vec3 vViewPosition;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n#ifndef FLAT_SHADED\n\tvNormal = normalize( transformedNormal );\n#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvViewPosition = - mvPosition.xyz;\n\t#include \n\t#include \n}\n", -normal_frag:"#define NORMAL\nuniform float opacity;\n#if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( USE_NORMALMAP )\n\tvarying vec3 vViewPosition;\n#endif\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\tgl_FragColor = vec4( packNormalToRGB( normal ), opacity );\n\t#include \n\t#include \n}\n", -normal_vert:"#define NORMAL\n#if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( USE_NORMALMAP )\n\tvarying vec3 vViewPosition;\n#endif\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n#ifndef FLAT_SHADED\n\tvNormal = normalize( transformedNormal );\n#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n#if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( USE_NORMALMAP )\n\tvViewPosition = - mvPosition.xyz;\n#endif\n}\n", -points_frag:"uniform vec3 diffuse;\nuniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec3 outgoingLight = vec3( 0.0 );\n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\t#include \n\t#include \n\toutgoingLight = diffuseColor.rgb;\n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n\t#include \n}\n", -points_vert:"uniform float size;\nuniform float scale;\n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#ifdef USE_SIZEATTENUATION\n\t\tgl_PointSize = size * ( scale / - mvPosition.z );\n\t#else\n\t\tgl_PointSize = size;\n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n}\n", -shadow_frag:"uniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\tgl_FragColor = vec4( 0.0, 0.0, 0.0, opacity * ( 1.0 - getShadowMask() ) );\n}\n",shadow_vert:"#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n}\n"};N.prototype={constructor:N, -isColor:!0,r:1,g:1,b:1,set:function(a){a&&a.isColor?this.copy(a):"number"===typeof a?this.setHex(a):"string"===typeof a&&this.setStyle(a);return this},setScalar:function(a){this.b=this.g=this.r=a;return this},setHex:function(a){a=Math.floor(a);this.r=(a>>16&255)/255;this.g=(a>>8&255)/255;this.b=(a&255)/255;return this},setRGB:function(a,b,c){this.r=a;this.g=b;this.b=c;return this},setHSL:function(){function a(a,c,d){0>d&&(d+=1);1d?c:d<2/3?a+6*(c-a)*(2/3-d):a}return function(b, -c,d){b=Q.euclideanModulo(b,1);c=Q.clamp(c,0,1);d=Q.clamp(d,0,1);0===c?this.r=this.g=this.b=d:(c=.5>=d?d*(1+c):d+c-d*c,d=2*d-c,this.r=a(d,c,b+1/3),this.g=a(d,c,b),this.b=a(d,c,b-1/3));return this}}(),setStyle:function(a){function b(b){void 0!==b&&1>parseFloat(b)&&console.warn("THREE.Color: Alpha component of "+a+" will be ignored.")}var c;if(c=/^((?:rgb|hsl)a?)\(\s*([^\)]*)\)/.exec(a)){var d=c[2];switch(c[1]){case "rgb":case "rgba":if(c=/^(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*(,\s*([0-9]*\.?[0-9]+)\s*)?$/.exec(d))return this.r= -Math.min(255,parseInt(c[1],10))/255,this.g=Math.min(255,parseInt(c[2],10))/255,this.b=Math.min(255,parseInt(c[3],10))/255,b(c[5]),this;if(c=/^(\d+)\%\s*,\s*(\d+)\%\s*,\s*(\d+)\%\s*(,\s*([0-9]*\.?[0-9]+)\s*)?$/.exec(d))return this.r=Math.min(100,parseInt(c[1],10))/100,this.g=Math.min(100,parseInt(c[2],10))/100,this.b=Math.min(100,parseInt(c[3],10))/100,b(c[5]),this;break;case "hsl":case "hsla":if(c=/^([0-9]*\.?[0-9]+)\s*,\s*(\d+)\%\s*,\s*(\d+)\%\s*(,\s*([0-9]*\.?[0-9]+)\s*)?$/.exec(d)){var d=parseFloat(c[1])/ -360,e=parseInt(c[2],10)/100,f=parseInt(c[3],10)/100;b(c[5]);return this.setHSL(d,e,f)}}}else if(c=/^\#([A-Fa-f0-9]+)$/.exec(a)){c=c[1];d=c.length;if(3===d)return this.r=parseInt(c.charAt(0)+c.charAt(0),16)/255,this.g=parseInt(c.charAt(1)+c.charAt(1),16)/255,this.b=parseInt(c.charAt(2)+c.charAt(2),16)/255,this;if(6===d)return this.r=parseInt(c.charAt(0)+c.charAt(1),16)/255,this.g=parseInt(c.charAt(2)+c.charAt(3),16)/255,this.b=parseInt(c.charAt(4)+c.charAt(5),16)/255,this}a&&0=h?k/(e+f): -k/(2-e-f);switch(e){case b:g=(c-d)/k+(cthis.max.x||a.ythis.max.y?!1:!0},containsBox:function(a){return this.min.x<=a.min.x&&a.max.x<=this.max.x&&this.min.y<=a.min.y&&a.max.y<=this.max.y},getParameter:function(a,b){return(b||new C).set((a.x-this.min.x)/(this.max.x-this.min.x),(a.y-this.min.y)/(this.max.y- -this.min.y))},intersectsBox:function(a){return a.max.xthis.max.x||a.max.ythis.max.y?!1:!0},clampPoint:function(a,b){return(b||new C).copy(a).clamp(this.min,this.max)},distanceToPoint:function(){var a=new C;return function(b){return a.copy(b).clamp(this.min,this.max).sub(b).length()}}(),intersect:function(a){this.min.max(a.min);this.max.min(a.max);return this},union:function(a){this.min.min(a.min);this.max.max(a.max);return this},translate:function(a){this.min.add(a); -this.max.add(a);return this},equals:function(a){return a.min.equals(this.min)&&a.max.equals(this.max)}};var pf=0;W.prototype={constructor:W,isMaterial:!0,get needsUpdate(){return this._needsUpdate},set needsUpdate(a){!0===a&&this.update();this._needsUpdate=a},setValues:function(a){if(void 0!==a)for(var b in a){var c=a[b];if(void 0===c)console.warn("THREE.Material: '"+b+"' parameter is undefined.");else{var d=this[b];void 0===d?console.warn("THREE."+this.type+": '"+b+"' is not a property of this material."): -d&&d.isColor?d.set(c):d&&d.isVector3&&c&&c.isVector3?d.copy(c):this[b]="overdraw"===b?Number(c):c}}},toJSON:function(a){function b(a){var b=[],c;for(c in a){var d=a[c];delete d.metadata;b.push(d)}return b}var c=void 0===a;c&&(a={textures:{},images:{}});var d={metadata:{version:4.4,type:"Material",generator:"Material.toJSON"}};d.uuid=this.uuid;d.type=this.type;""!==this.name&&(d.name=this.name);this.color&&this.color.isColor&&(d.color=this.color.getHex());void 0!==this.roughness&&(d.roughness=this.roughness); -void 0!==this.metalness&&(d.metalness=this.metalness);this.emissive&&this.emissive.isColor&&(d.emissive=this.emissive.getHex());this.specular&&this.specular.isColor&&(d.specular=this.specular.getHex());void 0!==this.shininess&&(d.shininess=this.shininess);void 0!==this.clearCoat&&(d.clearCoat=this.clearCoat);void 0!==this.clearCoatRoughness&&(d.clearCoatRoughness=this.clearCoatRoughness);this.map&&this.map.isTexture&&(d.map=this.map.toJSON(a).uuid);this.alphaMap&&this.alphaMap.isTexture&&(d.alphaMap= -this.alphaMap.toJSON(a).uuid);this.lightMap&&this.lightMap.isTexture&&(d.lightMap=this.lightMap.toJSON(a).uuid);this.bumpMap&&this.bumpMap.isTexture&&(d.bumpMap=this.bumpMap.toJSON(a).uuid,d.bumpScale=this.bumpScale);this.normalMap&&this.normalMap.isTexture&&(d.normalMap=this.normalMap.toJSON(a).uuid,d.normalScale=this.normalScale.toArray());this.displacementMap&&this.displacementMap.isTexture&&(d.displacementMap=this.displacementMap.toJSON(a).uuid,d.displacementScale=this.displacementScale,d.displacementBias= -this.displacementBias);this.roughnessMap&&this.roughnessMap.isTexture&&(d.roughnessMap=this.roughnessMap.toJSON(a).uuid);this.metalnessMap&&this.metalnessMap.isTexture&&(d.metalnessMap=this.metalnessMap.toJSON(a).uuid);this.emissiveMap&&this.emissiveMap.isTexture&&(d.emissiveMap=this.emissiveMap.toJSON(a).uuid);this.specularMap&&this.specularMap.isTexture&&(d.specularMap=this.specularMap.toJSON(a).uuid);this.envMap&&this.envMap.isTexture&&(d.envMap=this.envMap.toJSON(a).uuid,d.reflectivity=this.reflectivity); -this.gradientMap&&this.gradientMap.isTexture&&(d.gradientMap=this.gradientMap.toJSON(a).uuid);void 0!==this.size&&(d.size=this.size);void 0!==this.sizeAttenuation&&(d.sizeAttenuation=this.sizeAttenuation);1!==this.blending&&(d.blending=this.blending);2!==this.shading&&(d.shading=this.shading);0!==this.side&&(d.side=this.side);0!==this.vertexColors&&(d.vertexColors=this.vertexColors);1>this.opacity&&(d.opacity=this.opacity);!0===this.transparent&&(d.transparent=this.transparent);d.depthFunc=this.depthFunc; -d.depthTest=this.depthTest;d.depthWrite=this.depthWrite;0e&&(e=m);l>f&&(f=l);p>g&&(g=p)}this.min.set(b,c,d);this.max.set(e,f,g)},setFromBufferAttribute:function(a){for(var b=Infinity,c=Infinity,d=Infinity,e=-Infinity,f=-Infinity,g=-Infinity,h=0,k=a.count;he&&(e=m);l>f&&(f=l);p>g&&(g=p)}this.min.set(b,c,d);this.max.set(e,f,g)},setFromPoints:function(a){this.makeEmpty();for(var b=0,c=a.length;bthis.max.x||a.ythis.max.y||a.zthis.max.z?!1:!0},containsBox:function(a){return this.min.x<=a.min.x&&a.max.x<=this.max.x&&this.min.y<=a.min.y&&a.max.y<=this.max.y&&this.min.z<=a.min.z&&a.max.z<=this.max.z},getParameter:function(a,b){return(b||new q).set((a.x-this.min.x)/(this.max.x-this.min.x),(a.y-this.min.y)/ -(this.max.y-this.min.y),(a.z-this.min.z)/(this.max.z-this.min.z))},intersectsBox:function(a){return a.max.xthis.max.x||a.max.ythis.max.y||a.max.zthis.max.z?!1:!0},intersectsSphere:function(){var a;return function(b){void 0===a&&(a=new q);this.clampPoint(b.center,a);return a.distanceToSquared(b.center)<=b.radius*b.radius}}(),intersectsPlane:function(a){var b,c;0=a.constant},clampPoint:function(a,b){return(b||new q).copy(a).clamp(this.min,this.max)},distanceToPoint:function(){var a=new q;return function(b){return a.copy(b).clamp(this.min,this.max).sub(b).length()}}(), -getBoundingSphere:function(){var a=new q;return function(b){b=b||new Fa;this.getCenter(b.center);b.radius=.5*this.getSize(a).length();return b}}(),intersect:function(a){this.min.max(a.min);this.max.min(a.max);this.isEmpty()&&this.makeEmpty();return this},union:function(a){this.min.min(a.min);this.max.max(a.max);return this},applyMatrix4:function(){var a=[new q,new q,new q,new q,new q,new q,new q,new q];return function(b){if(this.isEmpty())return this;a[0].set(this.min.x,this.min.y,this.min.z).applyMatrix4(b); -a[1].set(this.min.x,this.min.y,this.max.z).applyMatrix4(b);a[2].set(this.min.x,this.max.y,this.min.z).applyMatrix4(b);a[3].set(this.min.x,this.max.y,this.max.z).applyMatrix4(b);a[4].set(this.max.x,this.min.y,this.min.z).applyMatrix4(b);a[5].set(this.max.x,this.min.y,this.max.z).applyMatrix4(b);a[6].set(this.max.x,this.max.y,this.min.z).applyMatrix4(b);a[7].set(this.max.x,this.max.y,this.max.z).applyMatrix4(b);this.setFromPoints(a);return this}}(),translate:function(a){this.min.add(a);this.max.add(a); -return this},equals:function(a){return a.min.equals(this.min)&&a.max.equals(this.max)}};Fa.prototype={constructor:Fa,set:function(a,b){this.center.copy(a);this.radius=b;return this},setFromPoints:function(){var a=new ya;return function(b,c){var d=this.center;void 0!==c?d.copy(c):a.setFromPoints(b).getCenter(d);for(var e=0,f=0,g=b.length;f=this.radius},containsPoint:function(a){return a.distanceToSquared(this.center)<=this.radius*this.radius},distanceToPoint:function(a){return a.distanceTo(this.center)-this.radius},intersectsSphere:function(a){var b=this.radius+a.radius;return a.center.distanceToSquared(this.center)<=b*b},intersectsBox:function(a){return a.intersectsSphere(this)},intersectsPlane:function(a){return Math.abs(this.center.dot(a.normal)-a.constant)<=this.radius}, -clampPoint:function(a,b){var c=this.center.distanceToSquared(a),d=b||new q;d.copy(a);c>this.radius*this.radius&&(d.sub(this.center).normalize(),d.multiplyScalar(this.radius).add(this.center));return d},getBoundingBox:function(a){a=a||new ya;a.set(this.center,this.center);a.expandByScalar(this.radius);return a},applyMatrix4:function(a){this.center.applyMatrix4(a);this.radius*=a.getMaxScaleOnAxis();return this},translate:function(a){this.center.add(a);return this},equals:function(a){return a.center.equals(this.center)&& -a.radius===this.radius}};za.prototype={constructor:za,isMatrix3:!0,set:function(a,b,c,d,e,f,g,h,k){var m=this.elements;m[0]=a;m[1]=d;m[2]=g;m[3]=b;m[4]=e;m[5]=h;m[6]=c;m[7]=f;m[8]=k;return this},identity:function(){this.set(1,0,0,0,1,0,0,0,1);return this},clone:function(){return(new this.constructor).fromArray(this.elements)},copy:function(a){a=a.elements;this.set(a[0],a[3],a[6],a[1],a[4],a[7],a[2],a[5],a[8]);return this},setFromMatrix4:function(a){a=a.elements;this.set(a[0],a[4],a[8],a[1],a[5],a[9], -a[2],a[6],a[10]);return this},applyToVector3Array:function(){var a;return function(b,c,d){void 0===a&&(a=new q);void 0===c&&(c=0);void 0===d&&(d=b.length);for(var e=0;ec;c++)this.elements[c]=a[c+b];return this},toArray:function(a,b){void 0===a&&(a=[]);void 0===b&&(b=0);var c=this.elements;a[b]=c[0];a[b+1]=c[1];a[b+2]=c[2];a[b+3]=c[3];a[b+4]=c[4];a[b+5]=c[5];a[b+6]=c[6];a[b+7]=c[7];a[b+8]=c[8];return a}};ma.prototype={constructor:ma,set:function(a,b){this.normal.copy(a); -this.constant=b;return this},setComponents:function(a,b,c,d){this.normal.set(a,b,c);this.constant=d;return this},setFromNormalAndCoplanarPoint:function(a,b){this.normal.copy(a);this.constant=-b.dot(this.normal);return this},setFromCoplanarPoints:function(){var a=new q,b=new q;return function(c,d,e){d=a.subVectors(e,d).cross(b.subVectors(c,d)).normalize();this.setFromNormalAndCoplanarPoint(d,c);return this}}(),clone:function(){return(new this.constructor).copy(this)},copy:function(a){this.normal.copy(a.normal); -this.constant=a.constant;return this},normalize:function(){var a=1/this.normal.length();this.normal.multiplyScalar(a);this.constant*=a;return this},negate:function(){this.constant*=-1;this.normal.negate();return this},distanceToPoint:function(a){return this.normal.dot(a)+this.constant},distanceToSphere:function(a){return this.distanceToPoint(a.center)-a.radius},projectPoint:function(a,b){return this.orthoPoint(a,b).sub(a).negate()},orthoPoint:function(a,b){var c=this.distanceToPoint(a);return(b|| -new q).copy(this.normal).multiplyScalar(c)},intersectLine:function(){var a=new q;return function(b,c){var d=c||new q,e=b.delta(a),f=this.normal.dot(e);if(0===f){if(0===this.distanceToPoint(b.start))return d.copy(b.start)}else return f=-(b.start.dot(this.normal)+this.constant)/f,0>f||1b&&0a&&0c;c++)b[c].copy(a.planes[c]);return this},setFromMatrix:function(a){var b=this.planes,c=a.elements;a=c[0];var d=c[1],e=c[2],f=c[3],g=c[4],h=c[5],k=c[6],m=c[7],l=c[8],p=c[9],n=c[10],r=c[11],q=c[12],u=c[13],F=c[14],c=c[15]; -b[0].setComponents(f-a,m-g,r-l,c-q).normalize();b[1].setComponents(f+a,m+g,r+l,c+q).normalize();b[2].setComponents(f+d,m+h,r+p,c+u).normalize();b[3].setComponents(f-d,m-h,r-p,c-u).normalize();b[4].setComponents(f-e,m-k,r-n,c-F).normalize();b[5].setComponents(f+e,m+k,r+n,c+F).normalize();return this},intersectsObject:function(){var a=new Fa;return function(b){var c=b.geometry;null===c.boundingSphere&&c.computeBoundingSphere();a.copy(c.boundingSphere).applyMatrix4(b.matrixWorld);return this.intersectsSphere(a)}}(), -intersectsSprite:function(){var a=new Fa;return function(b){a.center.set(0,0,0);a.radius=.7071067811865476;a.applyMatrix4(b.matrixWorld);return this.intersectsSphere(a)}}(),intersectsSphere:function(a){var b=this.planes,c=a.center;a=-a.radius;for(var d=0;6>d;d++)if(b[d].distanceToPoint(c)e;e++){var f=d[e];a.x=0g&&0>f)return!1}return!0}}(),containsPoint:function(a){for(var b=this.planes,c=0;6>c;c++)if(0>b[c].distanceToPoint(a))return!1;return!0}};bb.prototype={constructor:bb,set:function(a,b){this.origin.copy(a);this.direction.copy(b);return this},clone:function(){return(new this.constructor).copy(this)},copy:function(a){this.origin.copy(a.origin); -this.direction.copy(a.direction);return this},at:function(a,b){return(b||new q).copy(this.direction).multiplyScalar(a).add(this.origin)},lookAt:function(a){this.direction.copy(a).sub(this.origin).normalize();return this},recast:function(){var a=new q;return function(b){this.origin.copy(this.at(b,a));return this}}(),closestPointToPoint:function(a,b){var c=b||new q;c.subVectors(a,this.origin);var d=c.dot(this.direction);return 0>d?c.copy(this.origin):c.copy(this.direction).multiplyScalar(d).add(this.origin)}, -distanceToPoint:function(a){return Math.sqrt(this.distanceSqToPoint(a))},distanceSqToPoint:function(){var a=new q;return function(b){var c=a.subVectors(b,this.origin).dot(this.direction);if(0>c)return this.origin.distanceToSquared(b);a.copy(this.direction).multiplyScalar(c).add(this.origin);return a.distanceToSquared(b)}}(),distanceSqToSegment:function(){var a=new q,b=new q,c=new q;return function(d,e,f,g){a.copy(d).add(e).multiplyScalar(.5);b.copy(e).sub(d).normalize();c.copy(this.origin).sub(a); -var h=.5*d.distanceTo(e),k=-this.direction.dot(b),m=c.dot(this.direction),l=-c.dot(b),p=c.lengthSq(),n=Math.abs(1-k*k),r;0=-r?e<=r?(h=1/n,d*=h,e*=h,k=d*(d+k*e+2*m)+e*(k*d+e+2*l)+p):(e=h,d=Math.max(0,-(k*e+m)),k=-d*d+e*(e+2*l)+p):(e=-h,d=Math.max(0,-(k*e+m)),k=-d*d+e*(e+2*l)+p):e<=-r?(d=Math.max(0,-(-k*h+m)),e=0f)return null;f=Math.sqrt(f-e);e=d-f;d+=f;return 0>e&&0>d?null:0>e?this.at(d,c):this.at(e,c)}}(),intersectsSphere:function(a){return this.distanceToPoint(a.center)<= -a.radius},distanceToPlane:function(a){var b=a.normal.dot(this.direction);if(0===b)return 0===a.distanceToPoint(this.origin)?0:null;a=-(this.origin.dot(a.normal)+a.constant)/b;return 0<=a?a:null},intersectPlane:function(a,b){var c=this.distanceToPlane(a);return null===c?null:this.at(c,b)},intersectsPlane:function(a){var b=a.distanceToPoint(this.origin);return 0===b||0>a.normal.dot(this.direction)*b?!0:!1},intersectBox:function(a,b){var c,d,e,f,g;d=1/this.direction.x;f=1/this.direction.y;g=1/this.direction.z; -var h=this.origin;0<=d?(c=(a.min.x-h.x)*d,d*=a.max.x-h.x):(c=(a.max.x-h.x)*d,d*=a.min.x-h.x);0<=f?(e=(a.min.y-h.y)*f,f*=a.max.y-h.y):(e=(a.max.y-h.y)*f,f*=a.min.y-h.y);if(c>f||e>d)return null;if(e>c||c!==c)c=e;if(fg||e>d)return null;if(e>c||c!==c)c=e;if(gd?null:this.at(0<=c?c:d,b)},intersectsBox:function(){var a=new q;return function(b){return null!==this.intersectBox(b,a)}}(),intersectTriangle:function(){var a= -new q,b=new q,c=new q,d=new q;return function(e,f,g,h,k){b.subVectors(f,e);c.subVectors(g,e);d.crossVectors(b,c);f=this.direction.dot(d);if(0f)h=-1,f=-f;else return null;a.subVectors(this.origin,e);e=h*this.direction.dot(c.crossVectors(a,c));if(0>e)return null;g=h*this.direction.dot(b.cross(a));if(0>g||e+g>f)return null;e=-h*a.dot(d);return 0>e?null:this.at(e/f,k)}}(),applyMatrix4:function(a){this.direction.add(this.origin).applyMatrix4(a);this.origin.applyMatrix4(a); -this.direction.sub(this.origin);this.direction.normalize();return this},equals:function(a){return a.origin.equals(this.origin)&&a.direction.equals(this.direction)}};cb.RotationOrders="XYZ YZX ZXY XZY YXZ ZYX".split(" ");cb.DefaultOrder="XYZ";cb.prototype={constructor:cb,isEuler:!0,get x(){return this._x},set x(a){this._x=a;this.onChangeCallback()},get y(){return this._y},set y(a){this._y=a;this.onChangeCallback()},get z(){return this._z},set z(a){this._z=a;this.onChangeCallback()},get order(){return this._order}, -set order(a){this._order=a;this.onChangeCallback()},set:function(a,b,c,d){this._x=a;this._y=b;this._z=c;this._order=d||this._order;this.onChangeCallback();return this},clone:function(){return new this.constructor(this._x,this._y,this._z,this._order)},copy:function(a){this._x=a._x;this._y=a._y;this._z=a._z;this._order=a._order;this.onChangeCallback();return this},setFromRotationMatrix:function(a,b,c){var d=Q.clamp,e=a.elements;a=e[0];var f=e[4],g=e[8],h=e[1],k=e[5],m=e[9],l=e[2],p=e[6],e=e[10];b=b|| -this._order;"XYZ"===b?(this._y=Math.asin(d(g,-1,1)),.99999>Math.abs(g)?(this._x=Math.atan2(-m,e),this._z=Math.atan2(-f,a)):(this._x=Math.atan2(p,k),this._z=0)):"YXZ"===b?(this._x=Math.asin(-d(m,-1,1)),.99999>Math.abs(m)?(this._y=Math.atan2(g,e),this._z=Math.atan2(h,k)):(this._y=Math.atan2(-l,a),this._z=0)):"ZXY"===b?(this._x=Math.asin(d(p,-1,1)),.99999>Math.abs(p)?(this._y=Math.atan2(-l,e),this._z=Math.atan2(-f,k)):(this._y=0,this._z=Math.atan2(h,a))):"ZYX"===b?(this._y=Math.asin(-d(l,-1,1)),.99999> -Math.abs(l)?(this._x=Math.atan2(p,e),this._z=Math.atan2(h,a)):(this._x=0,this._z=Math.atan2(-f,k))):"YZX"===b?(this._z=Math.asin(d(h,-1,1)),.99999>Math.abs(h)?(this._x=Math.atan2(-m,k),this._y=Math.atan2(-l,a)):(this._x=0,this._y=Math.atan2(g,e))):"XZY"===b?(this._z=Math.asin(-d(f,-1,1)),.99999>Math.abs(f)?(this._x=Math.atan2(p,k),this._y=Math.atan2(g,a)):(this._x=Math.atan2(-m,e),this._y=0)):console.warn("THREE.Euler: .setFromRotationMatrix() given unsupported order: "+b);this._order=b;if(!1!==c)this.onChangeCallback(); -return this},setFromQuaternion:function(){var a;return function(b,c,d){void 0===a&&(a=new H);a.makeRotationFromQuaternion(b);return this.setFromRotationMatrix(a,c,d)}}(),setFromVector3:function(a,b){return this.set(a.x,a.y,a.z,b||this._order)},reorder:function(){var a=new da;return function(b){a.setFromEuler(this);return this.setFromQuaternion(a,b)}}(),equals:function(a){return a._x===this._x&&a._y===this._y&&a._z===this._z&&a._order===this._order},fromArray:function(a){this._x=a[0];this._y=a[1]; -this._z=a[2];void 0!==a[3]&&(this._order=a[3]);this.onChangeCallback();return this},toArray:function(a,b){void 0===a&&(a=[]);void 0===b&&(b=0);a[b]=this._x;a[b+1]=this._y;a[b+2]=this._z;a[b+3]=this._order;return a},toVector3:function(a){return a?a.set(this._x,this._y,this._z):new q(this._x,this._y,this._z)},onChange:function(a){this.onChangeCallback=a;return this},onChangeCallback:function(){}};gd.prototype={constructor:gd,set:function(a){this.mask=1<=b.x+b.y}}();Aa.prototype={constructor:Aa,set:function(a,b,c){this.a.copy(a);this.b.copy(b);this.c.copy(c);return this},setFromPointsAndIndices:function(a,b,c,d){this.a.copy(a[b]);this.b.copy(a[c]);this.c.copy(a[d]);return this},clone:function(){return(new this.constructor).copy(this)}, -copy:function(a){this.a.copy(a.a);this.b.copy(a.b);this.c.copy(a.c);return this},area:function(){var a=new q,b=new q;return function(){a.subVectors(this.c,this.b);b.subVectors(this.a,this.b);return.5*a.cross(b).length()}}(),midpoint:function(a){return(a||new q).addVectors(this.a,this.b).add(this.c).multiplyScalar(1/3)},normal:function(a){return Aa.normal(this.a,this.b,this.c,a)},plane:function(a){return(a||new ma).setFromCoplanarPoints(this.a,this.b,this.c)},barycoordFromPoint:function(a,b){return Aa.barycoordFromPoint(a, -this.a,this.b,this.c,b)},containsPoint:function(a){return Aa.containsPoint(a,this.a,this.b,this.c)},closestPointToPoint:function(){var a,b,c,d;return function(e,f){void 0===a&&(a=new ma,b=[new gb,new gb,new gb],c=new q,d=new q);var g=f||new q,h=Infinity;a.setFromCoplanarPoints(this.a,this.b,this.c);a.projectPoint(e,c);if(!0===this.containsPoint(c))g.copy(c);else{b[0].set(this.a,this.b);b[1].set(this.b,this.c);b[2].set(this.c,this.a);for(var k=0;kd;d++)if(e[d]===e[(d+1)%3]){a.push(f);break}for(f=a.length-1;0<=f;f--)for(e=a[f],this.faces.splice(e,1),c=0,g=this.faceVertexUvs.length;cb.far?null:{distance:c,point:t.clone(),object:a}}function c(c,d,e,f,m,l,p,q){g.fromArray(f,3*l);h.fromArray(f,3*p);k.fromArray(f,3*q);if(c=b(c,d,e,g,h,k,F))m&&(n.fromArray(m,2*l),r.fromArray(m,2*p),w.fromArray(m,2*q),c.uv=a(F,g,h,k,n,r,w)),c.face= -new ha(l,p,q,Aa.normal(g,h,k)),c.faceIndex=l;return c}var d=new H,e=new bb,f=new Fa,g=new q,h=new q,k=new q,m=new q,l=new q,p=new q,n=new C,r=new C,w=new C,u=new q,F=new q,t=new q;return function(q,u){var t=this.geometry,A=this.material,I=this.matrixWorld;if(void 0!==A&&(null===t.boundingSphere&&t.computeBoundingSphere(),f.copy(t.boundingSphere),f.applyMatrix4(I),!1!==q.ray.intersectsSphere(f)&&(d.getInverse(I),e.copy(q.ray).applyMatrix4(d),null===t.boundingBox||!1!==e.intersectsBox(t.boundingBox)))){var E, -K;if(t.isBufferGeometry){var y,J,A=t.index,I=t.attributes,t=I.position.array;void 0!==I.uv&&(E=I.uv.array);if(null!==A)for(var I=A.array,C=0,D=I.length;Cthis.scale.x*this.scale.y/4||c.push({distance:Math.sqrt(d),point:this.position,face:null,object:this})}}(),clone:function(){return(new this.constructor(this.material)).copy(this)}}); -Ac.prototype=Object.assign(Object.create(G.prototype),{constructor:Ac,copy:function(a){G.prototype.copy.call(this,a,!1);a=a.levels;for(var b=0,c=a.length;b=d[e].distance)d[e-1].object.visible=!1,d[e].object.visible=!0;else break; -for(;ef||(l.applyMatrix4(this.matrixWorld),u=d.ray.origin.distanceTo(l),ud.far||e.push({distance:u,point:h.clone().applyMatrix4(this.matrixWorld),index:g,face:null,faceIndex:null,object:this}))}else for(g=0,w=r.length/3-1;gf||(l.applyMatrix4(this.matrixWorld),u=d.ray.origin.distanceTo(l),ud.far||e.push({distance:u,point:h.clone().applyMatrix4(this.matrixWorld),index:g,face:null,faceIndex:null,object:this}))}else if(g.isGeometry)for(k=g.vertices,m=k.length,g=0;gf||(l.applyMatrix4(this.matrixWorld),u=d.ray.origin.distanceTo(l),ud.far||e.push({distance:u,point:h.clone().applyMatrix4(this.matrixWorld),index:g,face:null,faceIndex:null,object:this}))}}}(),clone:function(){return(new this.constructor(this.geometry,this.material)).copy(this)}});fa.prototype=Object.assign(Object.create(Va.prototype),{constructor:fa,isLineSegments:!0});Oa.prototype=Object.create(W.prototype);Oa.prototype.constructor=Oa;Oa.prototype.isPointsMaterial=!0;Oa.prototype.copy= -function(a){W.prototype.copy.call(this,a);this.color.copy(a.color);this.map=a.map;this.size=a.size;this.sizeAttenuation=a.sizeAttenuation;return this};Kb.prototype=Object.assign(Object.create(G.prototype),{constructor:Kb,isPoints:!0,raycast:function(){var a=new H,b=new bb,c=new Fa;return function(d,e){function f(a,c){var f=b.distanceSqToPoint(a);if(fd.far||e.push({distance:m,distanceToRay:Math.sqrt(f), -point:h.clone(),index:c,face:null,object:g})}}var g=this,h=this.geometry,k=this.matrixWorld,m=d.params.Points.threshold;null===h.boundingSphere&&h.computeBoundingSphere();c.copy(h.boundingSphere);c.applyMatrix4(k);if(!1!==d.ray.intersectsSphere(c)){a.getInverse(k);b.copy(d.ray).applyMatrix4(a);var m=m/((this.scale.x+this.scale.y+this.scale.z)/3),l=m*m,m=new q;if(h.isBufferGeometry){var p=h.index,h=h.attributes.position.array;if(null!==p)for(var n=p.array,p=0,r=n.length;pc)return null;var d=[],e=[],f=[],g,h,k;if(0=m--){console.warn("THREE.ShapeUtils: Unable to triangulate polygon! in triangulate()");break}g=h;c<=g&&(g=0);h=g+1;c<=h&&(h=0);k=h+1;c<=k&&(k=0);var l;a:{var p,n,r,q,u,F,t,v;p=a[e[g]].x;n=a[e[g]].y;r=a[e[h]].x;q=a[e[h]].y;u=a[e[k]].x;F=a[e[k]].y;if(0>=(r-p)*(F-n)-(q-n)*(u-p))l= -!1;else{var M,z,A,I,E,K,y,C,D,G;M=u-r;z=F-q;A=p-u;I=n-F;E=r-p;K=q-n;for(l=0;l=-Number.EPSILON&&C>=-Number.EPSILON&&y>=-Number.EPSILON)){l=!1;break a}l=!0}}if(l){d.push([a[e[g]],a[e[h]],a[e[k]]]);f.push([e[g],e[h],e[k]]);g=h;for(k=h+1;kNumber.EPSILON){if(0q||q>p)return[];k=m*l-k*n;if(0>k||k>p)return[]}else{if(0c?[]:k===c?f?[]:[g]:a<=c?[g,h]:[g,m]} -function f(a,b,c,d){var e=b.x-a.x,f=b.y-a.y;b=c.x-a.x;c=c.y-a.y;var g=d.x-a.x;d=d.y-a.y;a=e*c-f*b;e=e*d-f*g;return Math.abs(a)>Number.EPSILON?(b=g*c-d*b,0e&&(e=d);var g=a+1;g>d&&(g= -0);d=f(h[a],h[e],h[g],k[b]);if(!d)return!1;d=k.length-1;e=b-1;0>e&&(e=d);g=b+1;g>d&&(g=0);return(d=f(k[b],k[e],k[g],h[a]))?!0:!1}function d(a,b){var c,f;for(c=0;cO){console.log("Infinite Loop! Holes left:"+m.length+", Probably Hole outside Shape!");break}for(n=C;nk;k++)l=m[k].x+":"+m[k].y,l=p[l],void 0!==l&&(m[k]=l);return n.concat()},isClockWise:function(a){return 0>pa.area(a)},b2:function(){return function(a,b,c,d){var e=1-a;return e*e*b+2*(1-a)*a*c+a*a*d}}(),b3:function(){return function(a,b,c,d,e){var f=1-a,g=1-a;return f*f*f*b+3*g*g*a*c+3*(1-a)*a*a*d+a*a*a*e}}()};La.prototype=Object.create(S.prototype);La.prototype.constructor=La;La.prototype.addShapeList=function(a,b){for(var c=a.length,d=0;dNumber.EPSILON){var k=Math.sqrt(h),m=Math.sqrt(d*d+g*g),h=b.x-f/k;b=b.y+e/k;g=((c.x-g/m-h)*g-(c.y+d/m-b)*d)/(e*g-f*d);d=h+e*g-a.x;e=b+f*g-a.y;f=d*d+e*e;if(2>=f)return new C(d,e);f=Math.sqrt(f/2)}else a=!1,e>Number.EPSILON?d>Number.EPSILON&& -(a=!0):e<-Number.EPSILON?d<-Number.EPSILON&&(a=!0):Math.sign(f)===Math.sign(g)&&(a=!0),a?(d=-f,f=Math.sqrt(h)):(d=e,e=f,f=Math.sqrt(h/2));return new C(d/f,e/f)}function e(a,b){var c,d;for(L=a.length;0<=--L;){c=L;d=L-1;0>d&&(d=a.length-1);var e,f=r+2*l;for(e=0;eMath.abs(b.y-c.y)?[new C(b.x,1-b.z),new C(c.x,1-c.z),new C(d.x,1-d.z),new C(e.x,1-e.z)]:[new C(b.y,1-b.z),new C(c.y,1-c.z),new C(d.y,1-d.z),new C(e.y,1-e.z)]}};Mc.prototype=Object.create(La.prototype);Mc.prototype.constructor= -Mc;mb.prototype=Object.create(D.prototype);mb.prototype.constructor=mb;Nc.prototype=Object.create(S.prototype);Nc.prototype.constructor=Nc;Ub.prototype=Object.create(D.prototype);Ub.prototype.constructor=Ub;Oc.prototype=Object.create(S.prototype);Oc.prototype.constructor=Oc;Pc.prototype=Object.create(S.prototype);Pc.prototype.constructor=Pc;Vb.prototype=Object.create(D.prototype);Vb.prototype.constructor=Vb;Qc.prototype=Object.create(S.prototype);Qc.prototype.constructor=Qc;Wb.prototype=Object.create(D.prototype); -Wb.prototype.constructor=Wb;Xb.prototype=Object.create(S.prototype);Xb.prototype.constructor=Xb;Yb.prototype=Object.create(D.prototype);Yb.prototype.constructor=Yb;Wa.prototype=Object.create(D.prototype);Wa.prototype.constructor=Wa;nb.prototype=Object.create(S.prototype);nb.prototype.constructor=nb;Rc.prototype=Object.create(nb.prototype);Rc.prototype.constructor=Rc;Sc.prototype=Object.create(Wa.prototype);Sc.prototype.constructor=Sc;Zb.prototype=Object.create(D.prototype);Zb.prototype.constructor= -Zb;Tc.prototype=Object.create(S.prototype);Tc.prototype.constructor=Tc;$b.prototype=Object.create(S.prototype);$b.prototype.constructor=$b;var Ea=Object.freeze({WireframeGeometry:Mb,ParametricGeometry:Dc,ParametricBufferGeometry:Nb,TetrahedronGeometry:Ec,TetrahedronBufferGeometry:Ob,OctahedronGeometry:Fc,OctahedronBufferGeometry:lb,IcosahedronGeometry:Gc,IcosahedronBufferGeometry:Pb,DodecahedronGeometry:Hc,DodecahedronBufferGeometry:Qb,PolyhedronGeometry:Ic,PolyhedronBufferGeometry:xa,TubeGeometry:Jc, -TubeBufferGeometry:Rb,TorusKnotGeometry:Kc,TorusKnotBufferGeometry:Sb,TorusGeometry:Lc,TorusBufferGeometry:Tb,TextGeometry:Mc,SphereBufferGeometry:mb,SphereGeometry:Nc,RingGeometry:Oc,RingBufferGeometry:Ub,PlaneBufferGeometry:ib,PlaneGeometry:Pc,LatheGeometry:Qc,LatheBufferGeometry:Vb,ShapeGeometry:Xb,ShapeBufferGeometry:Wb,ExtrudeGeometry:La,EdgesGeometry:Yb,ConeGeometry:Rc,ConeBufferGeometry:Sc,CylinderGeometry:nb,CylinderBufferGeometry:Wa,CircleBufferGeometry:Zb,CircleGeometry:Tc,BoxBufferGeometry:hb, -BoxGeometry:$b});ac.prototype=Object.create(Ia.prototype);ac.prototype.constructor=ac;ac.prototype.isShadowMaterial=!0;bc.prototype=Object.create(Ia.prototype);bc.prototype.constructor=bc;bc.prototype.isRawShaderMaterial=!0;Uc.prototype={constructor:Uc,isMultiMaterial:!0,toJSON:function(a){for(var b={metadata:{version:4.2,type:"material",generator:"MaterialExporter"},uuid:this.uuid,type:this.type,materials:[]},c=this.materials,d=0,e=c.length;d=e)break a;else{f=b[1];a=e)break b}d=c;c=0}}for(;c>>1,ab;)--f;++f;if(0!==e||f!==d)e>=f&&(f=Math.max(f,1),e=f-1),d=this.getValueSize(),this.times=ba.arraySlice(c,e,f),this.values=ba.arraySlice(this.values,e*d,f*d);return this},validate:function(){var a=!0,b=this.getValueSize();0!==b-Math.floor(b)&&(console.error("invalid value size in track",this),a=!1);var c=this.times,b=this.values,d=c.length;0===d&&(console.error("track is empty", -this),a=!1);for(var e=null,f=0;f!==d;f++){var g=c[f];if("number"===typeof g&&isNaN(g)){console.error("time is not a valid number",this,f,g);a=!1;break}if(null!==e&&e>g){console.error("out of order keys",this,f,g,e);a=!1;break}e=g}if(void 0!==b&&ba.isTypedArray(b))for(f=0,c=b.length;f!==c;++f)if(d=b[f],isNaN(d)){console.error("value is not a valid number",this,f,d);a=!1;break}return a},optimize:function(){for(var a=this.times,b=this.values,c=this.getValueSize(),d=2302===this.getInterpolation(),e=1, -f=a.length-1,g=1;gk.opacity&&(k.transparent=!0);c.setTextures(h);return c.parse(k)}}()};wb.Handlers={handlers:[],add:function(a,b){this.handlers.push(a,b)},get:function(a){for(var b=this.handlers,c=0,d=b.length;cg;g++)n=v[k++],t=F[2*n],n=F[2*n+1],t=new C(t,n),2!==g&&c.faceVertexUvs[d][h].push(t),0!==g&&c.faceVertexUvs[d][h+1].push(t);p&&(p=3*v[k++],r.normal.set(y[p++],y[p++],y[p]),u.normal.copy(r.normal));if(w)for(d=0;4>d;d++)p=3*v[k++],w=new q(y[p++],y[p++],y[p]),2!==d&&r.vertexNormals.push(w),0!==d&&u.vertexNormals.push(w);l&&(l=v[k++], -l=z[l],r.color.setHex(l),u.color.setHex(l));if(b)for(d=0;4>d;d++)l=v[k++],l=z[l],2!==d&&r.vertexColors.push(new N(l)),0!==d&&u.vertexColors.push(new N(l));c.faces.push(r);c.faces.push(u)}else{r=new ha;r.a=v[k++];r.b=v[k++];r.c=v[k++];h&&(h=v[k++],r.materialIndex=h);h=c.faces.length;if(d)for(d=0;dg;g++)n=v[k++],t=F[2*n],n=F[2*n+1],t=new C(t,n),c.faceVertexUvs[d][h].push(t);p&&(p=3*v[k++],r.normal.set(y[p++],y[p++],y[p]));if(w)for(d=0;3>d;d++)p=3* -v[k++],w=new q(y[p++],y[p++],y[p]),r.vertexNormals.push(w);l&&(l=v[k++],r.color.setHex(z[l]));if(b)for(d=0;3>d;d++)l=v[k++],r.vertexColors.push(new N(z[l]));c.faces.push(r)}})(d);(function(){var b=void 0!==a.influencesPerVertex?a.influencesPerVertex:2;if(a.skinWeights)for(var d=0,g=a.skinWeights.length;dk)g=d+1;else if(0b&&(b=0);1Number.EPSILON&&(g.normalize(),c=Math.acos(Q.clamp(d[k-1].dot(d[k]),-1,1)),e[k].applyMatrix4(h.makeRotationAxis(g,c))),f[k].crossVectors(d[k],e[k]);if(!0===b)for(c=Math.acos(Q.clamp(e[0].dot(e[a]),-1,1)),c/=a,0=b)return b=c[a]-b,a=this.curves[a],c=a.getLength(),a.getPointAt(0===c?0:1-b/c);a++}return null},getLength:function(){var a=this.getCurveLengths();return a[a.length-1]},updateArcLengths:function(){this.needsUpdate= -!0;this.cacheLengths=null;this.getLengths()},getCurveLengths:function(){if(this.cacheLengths&&this.cacheLengths.length===this.curves.length)return this.cacheLengths;for(var a=[],b=0,c=0,d=this.curves.length;cc;)c+=b;for(;c>b;)c-=b;cb.length-2?b.length-1:c+1],b=b[c>b.length-3?b.length-1:c+2],c=ed.interpolate;return new C(c(d.x,e.x,f.x,b.x,a),c(d.y,e.y,f.y,b.y,a))};yb.prototype=Object.create(wa.prototype);yb.prototype.constructor=yb;yb.prototype.getPoint=function(a){var b=pa.b3;return new C(b(a,this.v0.x, -this.v1.x,this.v2.x,this.v3.x),b(a,this.v0.y,this.v1.y,this.v2.y,this.v3.y))};yb.prototype.getTangent=function(a){var b=ed.tangentCubicBezier;return(new C(b(a,this.v0.x,this.v1.x,this.v2.x,this.v3.x),b(a,this.v0.y,this.v1.y,this.v2.y,this.v3.y))).normalize()};zb.prototype=Object.create(wa.prototype);zb.prototype.constructor=zb;zb.prototype.getPoint=function(a){var b=pa.b2;return new C(b(a,this.v0.x,this.v1.x,this.v2.x),b(a,this.v0.y,this.v1.y,this.v2.y))};zb.prototype.getTangent=function(a){var b= -ed.tangentQuadraticBezier;return(new C(b(a,this.v0.x,this.v1.x,this.v2.x),b(a,this.v0.y,this.v1.y,this.v2.y))).normalize()};var oe=Object.assign(Object.create(Yc.prototype),{fromPoints:function(a){this.moveTo(a[0].x,a[0].y);for(var b=1,c=a.length;bNumber.EPSILON){if(0>m&&(g=b[f],k=-k,h=b[e],m=-m),!(a.yh.y))if(a.y===g.y){if(a.x===g.x)return!0}else{e=m*(a.x-g.x)-k*(a.y-g.y);if(0===e)return!0;0>e||(d=!d)}}else if(a.y===g.y&&(h.x<= -a.x&&a.x<=g.x||g.x<=a.x&&a.x<=h.x))return!0}return d}var e=pa.isClockWise,f=this.subPaths;if(0===f.length)return[];if(!0===b)return c(f);var g,h,k,m=[];if(1===f.length)return h=f[0],k=new Ab,k.curves=h.curves,m.push(k),m;var l=!e(f[0].getPoints()),l=a?!l:l;k=[];var p=[],n=[],q=0,w;p[q]=void 0;n[q]=[];for(var u=0,y=f.length;ud&& -this._mixBufferRegion(c,a,3*b,1-d,b);for(var d=b,f=b+b;d!==f;++d)if(c[d]!==c[d+b]){e.setValue(c,a);break}},saveOriginalState:function(){var a=this.buffer,b=this.valueSize,c=3*b;this.binding.getValue(a,c);for(var d=b;d!==c;++d)a[d]=a[c+d%b];this.cumulativeWeight=0},restoreOriginalState:function(){this.binding.setValue(this.buffer,3*this.valueSize)},_select:function(a,b,c,d,e){if(.5<=d)for(d=0;d!==e;++d)a[b+d]=a[c+d]},_slerp:function(a,b,c,d,e){da.slerpFlat(a,b,a,b,a,c,d)},_lerp:function(a,b,c,d,e){for(var f= -1-d,g=0;g!==e;++g){var h=b+g;a[h]=a[h]*f+a[c+g]*d}}};ka.prototype={constructor:ka,getValue:function(a,b){this.bind();this.getValue(a,b)},setValue:function(a,b){this.bind();this.setValue(a,b)},bind:function(){var a=this.node,b=this.parsedPath,c=b.objectName,d=b.propertyName,e=b.propertyIndex;a||(this.node=a=ka.findNode(this.rootNode,b.nodeName)||this.rootNode);this.getValue=this._getValue_unavailable;this.setValue=this._setValue_unavailable;if(a){if(c){var f=b.objectIndex;switch(c){case "materials":if(!a.material){console.error(" can not bind to material as node does not have a material", -this);return}if(!a.material.materials){console.error(" can not bind to material.materials as node.material does not have a materials array",this);return}a=a.material.materials;break;case "bones":if(!a.skeleton){console.error(" can not bind to bones as node does not have a skeleton",this);return}a=a.skeleton.bones;for(c=0;c=c){var p=c++,n=b[p];d[n.uuid]=q;b[q]=n;d[l]=p;b[p]= -k;k=0;for(l=f;k!==l;++k){var n=e[k],r=n[q];n[q]=n[p];n[p]=r}}}this.nCachedObjects_=c},uncache:function(a){for(var b=this._objects,c=b.length,d=this.nCachedObjects_,e=this._indicesByUUID,f=this._bindings,g=f.length,h=0,k=arguments.length;h!==k;++h){var l=arguments[h].uuid,q=e[l];if(void 0!==q)if(delete e[l],qb||0===c)return;this._startTime=null;b*=c}b*=this._updateTimeScale(a);c=this._updateTime(b);a=this._updateWeight(a);if(0c.parameterPositions[1]&&(this.stopFading(),0===d&&(this.enabled=!1))}}return this._effectiveWeight=b},_updateTimeScale:function(a){var b=0;if(!this.paused){var b=this.timeScale,c=this._timeScaleInterpolant;if(null!==c){var d=c.evaluate(a)[0],b=b*d;a>c.parameterPositions[1]&&(this.stopWarping(),0=== -b?this.paused=!0:this.timeScale=b)}}return this._effectiveTimeScale=b},_updateTime:function(a){var b=this.time+a;if(0===a)return b;var c=this._clip.duration,d=this.loop,e=this._loopCount;if(2200===d)a:{if(-1===e&&(this._loopCount=0,this._setEndings(!0,!0,!1)),b>=c)b=c;else if(0>b)b=0;else break a;this.clampWhenFinished?this.paused=!0:this.enabled=!1;this._mixer.dispatchEvent({type:"finished",action:this,direction:0>a?-1:1})}else{d=2202===d;-1===e&&(0<=a?(e=0,this._setEndings(!0,0===this.repetitions, -d)):this._setEndings(0===this.repetitions,!0,d));if(b>=c||0>b){var f=Math.floor(b/c),b=b-c*f,e=e+Math.abs(f),g=this.repetitions-e;0>g?(this.clampWhenFinished?this.paused=!0:this.enabled=!1,b=0a,this._setEndings(a,!a,d)):this._setEndings(!1,!1,d),this._loopCount=e,this._mixer.dispatchEvent({type:"loop",action:this,loopDelta:f}))}if(d&&1===(e&1))return this.time=b,c-b}return this.time=b},_setEndings:function(a, -b,c){var d=this._interpolantSettings;c?(d.endingStart=2401,d.endingEnd=2401):(d.endingStart=a?this.zeroSlopeAtStart?2401:2400:2402,d.endingEnd=b?this.zeroSlopeAtEnd?2401:2400:2402)},_scheduleFading:function(a,b,c){var d=this._mixer,e=d.time,f=this._weightInterpolant;null===f&&(this._weightInterpolant=f=d._lendControlInterpolant());d=f.parameterPositions;f=f.sampleValues;d[0]=e;f[0]=b;d[1]=e+a;f[1]=c;return this}};Object.assign(de.prototype,oa.prototype,{clipAction:function(a,b){var c=b||this._root, -d=c.uuid,e="string"===typeof a?ta.findByName(c,a):a,c=null!==e?e.uuid:a,f=this._actionsByClip[c],g=null;if(void 0!==f){g=f.actionByRoot[d];if(void 0!==g)return g;g=f.knownActions[0];null===e&&(e=g._clip)}if(null===e)return null;e=new ce(this,e,b);this._bindAction(e,g);this._addInactiveAction(e,c,d);return e},existingAction:function(a,b){var c=b||this._root,d=c.uuid,c="string"===typeof a?ta.findByName(c,a):a,c=this._actionsByClip[c?c.uuid:a];return void 0!==c?c.actionByRoot[d]||null:null},stopAllAction:function(){for(var a= -this._actions,b=this._nActiveActions,c=this._bindings,d=this._nActiveBindings,e=this._nActiveBindings=this._nActiveActions=0;e!==b;++e)a[e].reset();for(e=0;e!==d;++e)c[e].useCount=0;return this},update:function(a){a*=this.timeScale;for(var b=this._actions,c=this._nActiveActions,d=this.time+=a,e=Math.sign(a),f=this._accuIndex^=1,g=0;g!==c;++g){var h=b[g];h.enabled&&h._update(d,a,e,f)}a=this._bindings;b=this._nActiveBindings;for(g=0;g!==b;++g)a[g].apply(f);return this},getRoot:function(){return this._root}, -uncacheClip:function(a){var b=this._actions;a=a.uuid;var c=this._actionsByClip,d=c[a];if(void 0!==d){for(var d=d.knownActions,e=0,f=d.length;e!==f;++e){var g=d[e];this._deactivateAction(g);var h=g._cacheIndex,k=b[b.length-1];g._cacheIndex=null;g._byClipCacheIndex=null;k._cacheIndex=h;b[h]=k;b.pop();this._removeInactiveBindingsForAction(g)}delete c[a]}},uncacheRoot:function(a){a=a.uuid;var b=this._actionsByClip,c;for(c in b){var d=b[c].actionByRoot[a];void 0!==d&&(this._deactivateAction(d),this._removeInactiveAction(d))}c= -this._bindingsByRootAndName[a];if(void 0!==c)for(var e in c)a=c[e],a.restoreOriginalState(),this._removeInactiveBinding(a)},uncacheAction:function(a,b){var c=this.existingAction(a,b);null!==c&&(this._deactivateAction(c),this._removeInactiveAction(c))}});Object.assign(de.prototype,{_bindAction:function(a,b){var c=a._localRoot||this._root,d=a._clip.tracks,e=d.length,f=a._propertyBindings,g=a._interpolants,h=c.uuid,k=this._bindingsByRootAndName,l=k[h];void 0===l&&(l={},k[h]=l);for(k=0;k!==e;++k){var q= -d[k],p=q.name,n=l[p];if(void 0===n){n=f[k];if(void 0!==n){null===n._cacheIndex&&(++n.referenceCount,this._addInactiveBinding(n,h,p));continue}n=new Cd(ka.create(c,p,b&&b._propertyBindings[k].binding.parsedPath),q.ValueTypeName,q.getValueSize());++n.referenceCount;this._addInactiveBinding(n,h,p)}f[k]=n;g[k].resultBuffer=n.buffer}},_activateAction:function(a){if(!this._isActiveAction(a)){if(null===a._cacheIndex){var b=(a._localRoot||this._root).uuid,c=a._clip.uuid,d=this._actionsByClip[c];this._bindAction(a, -d&&d.knownActions[0]);this._addInactiveAction(a,c,b)}b=a._propertyBindings;c=0;for(d=b.length;c!==d;++c){var e=b[c];0===e.useCount++&&(this._lendBinding(e),e.saveOriginalState())}this._lendAction(a)}},_deactivateAction:function(a){if(this._isActiveAction(a)){for(var b=a._propertyBindings,c=0,d=b.length;c!==d;++c){var e=b[c];0===--e.useCount&&(e.restoreOriginalState(),this._takeBackBinding(e))}this._takeBackAction(a)}},_initMemoryManager:function(){this._actions=[];this._nActiveActions=0;this._actionsByClip= -{};this._bindings=[];this._nActiveBindings=0;this._bindingsByRootAndName={};this._controlInterpolants=[];this._nActiveControlInterpolants=0;var a=this;this.stats={actions:{get total(){return a._actions.length},get inUse(){return a._nActiveActions}},bindings:{get total(){return a._bindings.length},get inUse(){return a._nActiveBindings}},controlInterpolants:{get total(){return a._controlInterpolants.length},get inUse(){return a._nActiveControlInterpolants}}}},_isActiveAction:function(a){a=a._cacheIndex; -return null!==a&&ah.end&&(h.end=f);c||(c=k)}}for(k in d)h=d[k],this.createAnimation(k,h.start,h.end, -a);this.firstAnimation=c};ua.prototype.setAnimationDirectionForward=function(a){if(a=this.animationsMap[a])a.direction=1,a.directionBackwards=!1};ua.prototype.setAnimationDirectionBackward=function(a){if(a=this.animationsMap[a])a.direction=-1,a.directionBackwards=!0};ua.prototype.setAnimationFPS=function(a,b){var c=this.animationsMap[a];c&&(c.fps=b,c.duration=(c.end-c.start)/c.fps)};ua.prototype.setAnimationDuration=function(a,b){var c=this.animationsMap[a];c&&(c.duration=b,c.fps=(c.end-c.start)/ -c.duration)};ua.prototype.setAnimationWeight=function(a,b){var c=this.animationsMap[a];c&&(c.weight=b)};ua.prototype.setAnimationTime=function(a,b){var c=this.animationsMap[a];c&&(c.time=b)};ua.prototype.getAnimationTime=function(a){var b=0;if(a=this.animationsMap[a])b=a.time;return b};ua.prototype.getAnimationDuration=function(a){var b=-1;if(a=this.animationsMap[a])b=a.duration;return b};ua.prototype.playAnimation=function(a){var b=this.animationsMap[a];b?(b.time=0,b.active=!0):console.warn("THREE.MorphBlendMesh: animation["+ -a+"] undefined in .playAnimation()")};ua.prototype.stopAnimation=function(a){if(a=this.animationsMap[a])a.active=!1};ua.prototype.update=function(a){for(var b=0,c=this.animationsList.length;bd.duration||0>d.time)d.direction*=-1,d.time>d.duration&&(d.time=d.duration,d.directionBackwards=!0),0>d.time&&(d.time=0,d.directionBackwards=!1)}else d.time%=d.duration,0>d.time&&(d.time+= -d.duration);var f=d.start+Q.clamp(Math.floor(d.time/e),0,d.length-1),g=d.weight;f!==d.currentFrame&&(this.morphTargetInfluences[d.lastFrame]=0,this.morphTargetInfluences[d.currentFrame]=1*g,this.morphTargetInfluences[f]=0,d.lastFrame=d.currentFrame,d.currentFrame=f);e=d.time%e/e;d.directionBackwards&&(e=1-e);d.currentFrame!==d.lastFrame?(this.morphTargetInfluences[d.currentFrame]=e*g,this.morphTargetInfluences[d.lastFrame]=(1-e)*g):this.morphTargetInfluences[d.currentFrame]=g}}};$c.prototype=Object.create(G.prototype); -$c.prototype.constructor=$c;$c.prototype.isImmediateRenderObject=!0;ad.prototype=Object.create(fa.prototype);ad.prototype.constructor=ad;ad.prototype.update=function(){var a=new q,b=new q,c=new za;return function(){var d=["a","b","c"];this.object.updateMatrixWorld(!0);c.getNormalMatrix(this.object.matrixWorld);var e=this.object.matrixWorld,f=this.geometry.attributes.position,g=this.object.geometry;if(g&&g.isGeometry)for(var h=g.vertices,k=g.faces,l=g=0,q=k.length;lc.y?this.quaternion.set(1,0,0,0):(a.set(c.z,0,-c.x).normalize(), -b=Math.acos(c.y),this.quaternion.setFromAxisAngle(a,b))}}();Cb.prototype.setLength=function(a,b,c){void 0===b&&(b=.2*a);void 0===c&&(c=.2*b);this.line.scale.set(1,Math.max(0,a-b),1);this.line.updateMatrix();this.cone.scale.set(c,b,c);this.cone.position.y=a;this.cone.updateMatrix()};Cb.prototype.setColor=function(a){this.line.material.color.copy(a);this.cone.material.color.copy(a)};Fd.prototype=Object.create(fa.prototype);Fd.prototype.constructor=Fd;var ke=function(){function a(){}var b=new q,c=new a, -d=new a,e=new a;a.prototype.init=function(a,b,c,d){this.c0=a;this.c1=c;this.c2=-3*a+3*b-2*c-d;this.c3=2*a-2*b+c+d};a.prototype.initNonuniformCatmullRom=function(a,b,c,d,e,l,p){this.init(b,c,((b-a)/e-(c-a)/(e+l)+(c-b)/l)*l,((c-b)/l-(d-b)/(l+p)+(d-c)/p)*l)};a.prototype.initCatmullRom=function(a,b,c,d,e){this.init(b,c,e*(c-a),e*(d-b))};a.prototype.calc=function(a){var b=a*a;return this.c0+this.c1*a+this.c2*b+this.c3*b*a};return wa.create(function(a){this.points=a||[];this.closed=!1},function(a){var g= -this.points,h,k;k=g.length;2>k&&console.log("duh, you need at least 2 points");a*=k-(this.closed?0:1);h=Math.floor(a);a-=h;this.closed?h+=0h&&(h=1);1E-4>k&&(k=h);1E-4>n&&(n=h);c.initNonuniformCatmullRom(l.x,x.x,p.x,g.x,k,h,n);d.initNonuniformCatmullRom(l.y,x.y,p.y,g.y,k,h,n);e.initNonuniformCatmullRom(l.z,x.z,p.z,g.z,k,h,n)}else"catmullrom"===this.type&&(k=void 0!==this.tension?this.tension:.5,c.initCatmullRom(l.x,x.x,p.x,g.x,k),d.initCatmullRom(l.y,x.y,p.y,g.y,k),e.initCatmullRom(l.z,x.z,p.z,g.z,k));return new q(c.calc(a), -d.calc(a),e.calc(a))})}(),Nf=wa.create(function(a){console.warn("THREE.SplineCurve3 will be deprecated. Please use THREE.CatmullRomCurve3");this.points=void 0===a?[]:a},function(a){var b=this.points;a*=b.length-1;var c=Math.floor(a);a-=c;var d=b[0==c?c:c-1],e=b[c],f=b[c>b.length-2?b.length-1:c+1],b=b[c>b.length-3?b.length-1:c+2],c=ed.interpolate;return new q(c(d.x,e.x,f.x,b.x,a),c(d.y,e.y,f.y,b.y,a),c(d.z,e.z,f.z,b.z,a))}),Of=wa.create(function(a,b,c,d){this.v0=a;this.v1=b;this.v2=c;this.v3=d},function(a){var b= -pa.b3;return new q(b(a,this.v0.x,this.v1.x,this.v2.x,this.v3.x),b(a,this.v0.y,this.v1.y,this.v2.y,this.v3.y),b(a,this.v0.z,this.v1.z,this.v2.z,this.v3.z))}),Pf=wa.create(function(a,b,c){this.v0=a;this.v1=b;this.v2=c},function(a){var b=pa.b2;return new q(b(a,this.v0.x,this.v1.x,this.v2.x),b(a,this.v0.y,this.v1.y,this.v2.y),b(a,this.v0.z,this.v1.z,this.v2.z))}),Qf=wa.create(function(a,b){this.v1=a;this.v2=b},function(a){if(1===a)return this.v2.clone();var b=new q;b.subVectors(this.v2,this.v1);b.multiplyScalar(a); -b.add(this.v1);return b});Gd.prototype=Object.create(Xa.prototype);Gd.prototype.constructor=Gd;Le.prototype=Object.create(ke.prototype);bd.prototype.setColors=function(){console.error("THREE.GridHelper: setColors() has been deprecated, pass them in the constructor instead.")};Object.assign(pc.prototype,{center:function(a){console.warn("THREE.Box2: .center() has been renamed to .getCenter().");return this.getCenter(a)},empty:function(){console.warn("THREE.Box2: .empty() has been renamed to .isEmpty()."); -return this.isEmpty()},isIntersectionBox:function(a){console.warn("THREE.Box2: .isIntersectionBox() has been renamed to .intersectsBox().");return this.intersectsBox(a)},size:function(a){console.warn("THREE.Box2: .size() has been renamed to .getSize().");return this.getSize(a)}});Object.assign(ya.prototype,{center:function(a){console.warn("THREE.Box3: .center() has been renamed to .getCenter().");return this.getCenter(a)},empty:function(){console.warn("THREE.Box3: .empty() has been renamed to .isEmpty()."); -return this.isEmpty()},isIntersectionBox:function(a){console.warn("THREE.Box3: .isIntersectionBox() has been renamed to .intersectsBox().");return this.intersectsBox(a)},isIntersectionSphere:function(a){console.warn("THREE.Box3: .isIntersectionSphere() has been renamed to .intersectsSphere().");return this.intersectsSphere(a)},size:function(a){console.warn("THREE.Box3: .size() has been renamed to .getSize().");return this.getSize(a)}});gb.prototype.center=function(a){console.warn("THREE.Line3: .center() has been renamed to .getCenter()."); -return this.getCenter(a)};Q.random16=function(){console.warn("THREE.Math.random16() has been deprecated. Use Math.random() instead.");return Math.random()};Object.assign(za.prototype,{flattenToArrayOffset:function(a,b){console.warn("THREE.Matrix3: .flattenToArrayOffset() has been deprecated. Use .toArray() instead.");return this.toArray(a,b)},multiplyVector3:function(a){console.warn("THREE.Matrix3: .multiplyVector3() has been removed. Use vector.applyMatrix3( matrix ) instead.");return a.applyMatrix3(this)}, -multiplyVector3Array:function(a){console.warn("THREE.Matrix3: .multiplyVector3Array() has been renamed. Use matrix.applyToVector3Array( array ) instead.");return this.applyToVector3Array(a)},applyToBuffer:function(a,b,c){console.warn("THREE.Matrix3: .applyToBuffer() has been removed. Use matrix.applyToBufferAttribute( attribute ) instead.");return this.applyToBufferAttribute(a)}});Object.assign(H.prototype,{extractPosition:function(a){console.warn("THREE.Matrix4: .extractPosition() has been renamed to .copyPosition()."); -return this.copyPosition(a)},flattenToArrayOffset:function(a,b){console.warn("THREE.Matrix4: .flattenToArrayOffset() has been deprecated. Use .toArray() instead.");return this.toArray(a,b)},getPosition:function(){var a;return function(){void 0===a&&(a=new q);console.warn("THREE.Matrix4: .getPosition() has been removed. Use Vector3.setFromMatrixPosition( matrix ) instead.");return a.setFromMatrixColumn(this,3)}}(),setRotationFromQuaternion:function(a){console.warn("THREE.Matrix4: .setRotationFromQuaternion() has been renamed to .makeRotationFromQuaternion()."); -return this.makeRotationFromQuaternion(a)},multiplyVector3:function(a){console.warn("THREE.Matrix4: .multiplyVector3() has been removed. Use vector.applyMatrix4( matrix ) or vector.applyProjection( matrix ) instead.");return a.applyProjection(this)},multiplyVector4:function(a){console.warn("THREE.Matrix4: .multiplyVector4() has been removed. Use vector.applyMatrix4( matrix ) instead.");return a.applyMatrix4(this)},multiplyVector3Array:function(a){console.warn("THREE.Matrix4: .multiplyVector3Array() has been renamed. Use matrix.applyToVector3Array( array ) instead."); -return this.applyToVector3Array(a)},rotateAxis:function(a){console.warn("THREE.Matrix4: .rotateAxis() has been removed. Use Vector3.transformDirection( matrix ) instead.");a.transformDirection(this)},crossVector:function(a){console.warn("THREE.Matrix4: .crossVector() has been removed. Use vector.applyMatrix4( matrix ) instead.");return a.applyMatrix4(this)},translate:function(){console.error("THREE.Matrix4: .translate() has been removed.")},rotateX:function(){console.error("THREE.Matrix4: .rotateX() has been removed.")}, -rotateY:function(){console.error("THREE.Matrix4: .rotateY() has been removed.")},rotateZ:function(){console.error("THREE.Matrix4: .rotateZ() has been removed.")},rotateByAxis:function(){console.error("THREE.Matrix4: .rotateByAxis() has been removed.")},applyToBuffer:function(a,b,c){console.warn("THREE.Matrix4: .applyToBuffer() has been removed. Use matrix.applyToBufferAttribute( attribute ) instead.");return this.applyToBufferAttribute(a)}});ma.prototype.isIntersectionLine=function(a){console.warn("THREE.Plane: .isIntersectionLine() has been renamed to .intersectsLine()."); -return this.intersectsLine(a)};da.prototype.multiplyVector3=function(a){console.warn("THREE.Quaternion: .multiplyVector3() has been removed. Use is now vector.applyQuaternion( quaternion ) instead.");return a.applyQuaternion(this)};Object.assign(bb.prototype,{isIntersectionBox:function(a){console.warn("THREE.Ray: .isIntersectionBox() has been renamed to .intersectsBox().");return this.intersectsBox(a)},isIntersectionPlane:function(a){console.warn("THREE.Ray: .isIntersectionPlane() has been renamed to .intersectsPlane()."); -return this.intersectsPlane(a)},isIntersectionSphere:function(a){console.warn("THREE.Ray: .isIntersectionSphere() has been renamed to .intersectsSphere().");return this.intersectsSphere(a)}});Object.assign(Ab.prototype,{extrude:function(a){console.warn("THREE.Shape: .extrude() has been removed. Use ExtrudeGeometry() instead.");return new La(this,a)},makeGeometry:function(a){console.warn("THREE.Shape: .makeGeometry() has been removed. Use ShapeGeometry() instead.");return new Xb(this,a)}});Object.assign(q.prototype, -{setEulerFromRotationMatrix:function(){console.error("THREE.Vector3: .setEulerFromRotationMatrix() has been removed. Use Euler.setFromRotationMatrix() instead.")},setEulerFromQuaternion:function(){console.error("THREE.Vector3: .setEulerFromQuaternion() has been removed. Use Euler.setFromQuaternion() instead.")},getPositionFromMatrix:function(a){console.warn("THREE.Vector3: .getPositionFromMatrix() has been renamed to .setFromMatrixPosition().");return this.setFromMatrixPosition(a)},getScaleFromMatrix:function(a){console.warn("THREE.Vector3: .getScaleFromMatrix() has been renamed to .setFromMatrixScale()."); -return this.setFromMatrixScale(a)},getColumnFromMatrix:function(a,b){console.warn("THREE.Vector3: .getColumnFromMatrix() has been renamed to .setFromMatrixColumn().");return this.setFromMatrixColumn(b,a)}});S.prototype.computeTangents=function(){console.warn("THREE.Geometry: .computeTangents() has been removed.")};Object.assign(G.prototype,{getChildByName:function(a){console.warn("THREE.Object3D: .getChildByName() has been renamed to .getObjectByName().");return this.getObjectByName(a)},renderDepth:function(){console.warn("THREE.Object3D: .renderDepth has been removed. Use .renderOrder, instead.")}, -translate:function(a,b){console.warn("THREE.Object3D: .translate() has been removed. Use .translateOnAxis( axis, distance ) instead.");return this.translateOnAxis(b,a)}});Object.defineProperties(G.prototype,{eulerOrder:{get:function(){console.warn("THREE.Object3D: .eulerOrder is now .rotation.order.");return this.rotation.order},set:function(a){console.warn("THREE.Object3D: .eulerOrder is now .rotation.order.");this.rotation.order=a}},useQuaternion:{get:function(){console.warn("THREE.Object3D: .useQuaternion has been removed. The library now uses quaternions by default.")}, -set:function(){console.warn("THREE.Object3D: .useQuaternion has been removed. The library now uses quaternions by default.")}}});Object.defineProperties(Ac.prototype,{objects:{get:function(){console.warn("THREE.LOD: .objects has been renamed to .levels.");return this.levels}}});Ha.prototype.setLens=function(a,b){console.warn("THREE.PerspectiveCamera.setLens is deprecated. Use .setFocalLength and .filmGauge for a photographic setup.");void 0!==b&&(this.filmGauge=b);this.setFocalLength(a)};Object.defineProperties(na.prototype, -{onlyShadow:{set:function(){console.warn("THREE.Light: .onlyShadow has been removed.")}},shadowCameraFov:{set:function(a){console.warn("THREE.Light: .shadowCameraFov is now .shadow.camera.fov.");this.shadow.camera.fov=a}},shadowCameraLeft:{set:function(a){console.warn("THREE.Light: .shadowCameraLeft is now .shadow.camera.left.");this.shadow.camera.left=a}},shadowCameraRight:{set:function(a){console.warn("THREE.Light: .shadowCameraRight is now .shadow.camera.right.");this.shadow.camera.right=a}},shadowCameraTop:{set:function(a){console.warn("THREE.Light: .shadowCameraTop is now .shadow.camera.top."); -this.shadow.camera.top=a}},shadowCameraBottom:{set:function(a){console.warn("THREE.Light: .shadowCameraBottom is now .shadow.camera.bottom.");this.shadow.camera.bottom=a}},shadowCameraNear:{set:function(a){console.warn("THREE.Light: .shadowCameraNear is now .shadow.camera.near.");this.shadow.camera.near=a}},shadowCameraFar:{set:function(a){console.warn("THREE.Light: .shadowCameraFar is now .shadow.camera.far.");this.shadow.camera.far=a}},shadowCameraVisible:{set:function(){console.warn("THREE.Light: .shadowCameraVisible has been removed. Use new THREE.CameraHelper( light.shadow.camera ) instead.")}}, -shadowBias:{set:function(a){console.warn("THREE.Light: .shadowBias is now .shadow.bias.");this.shadow.bias=a}},shadowDarkness:{set:function(){console.warn("THREE.Light: .shadowDarkness has been removed.")}},shadowMapWidth:{set:function(a){console.warn("THREE.Light: .shadowMapWidth is now .shadow.mapSize.width.");this.shadow.mapSize.width=a}},shadowMapHeight:{set:function(a){console.warn("THREE.Light: .shadowMapHeight is now .shadow.mapSize.height.");this.shadow.mapSize.height=a}}});Object.defineProperties(y.prototype, -{length:{get:function(){console.warn("THREE.BufferAttribute: .length has been deprecated. Use .count instead.");return this.array.length}}});Object.assign(D.prototype,{addIndex:function(a){console.warn("THREE.BufferGeometry: .addIndex() has been renamed to .setIndex().");this.setIndex(a)},addDrawCall:function(a,b,c){void 0!==c&&console.warn("THREE.BufferGeometry: .addDrawCall() no longer supports indexOffset.");console.warn("THREE.BufferGeometry: .addDrawCall() is now .addGroup().");this.addGroup(a, -b)},clearDrawCalls:function(){console.warn("THREE.BufferGeometry: .clearDrawCalls() is now .clearGroups().");this.clearGroups()},computeTangents:function(){console.warn("THREE.BufferGeometry: .computeTangents() has been removed.")},computeOffsets:function(){console.warn("THREE.BufferGeometry: .computeOffsets() has been removed.")}});Object.defineProperties(D.prototype,{drawcalls:{get:function(){console.error("THREE.BufferGeometry: .drawcalls has been renamed to .groups.");return this.groups}},offsets:{get:function(){console.warn("THREE.BufferGeometry: .offsets has been renamed to .groups."); -return this.groups}}});Object.defineProperties(Dd.prototype,{dynamic:{set:function(){console.warn("THREE.Uniform: .dynamic has been removed. Use object.onBeforeRender() instead.")}},onUpdate:{value:function(){console.warn("THREE.Uniform: .onUpdate() has been removed. Use object.onBeforeRender() instead.");return this}}});Object.defineProperties(W.prototype,{wrapAround:{get:function(){console.warn("THREE."+this.type+": .wrapAround has been removed.")},set:function(){console.warn("THREE."+this.type+ -": .wrapAround has been removed.")}},wrapRGB:{get:function(){console.warn("THREE."+this.type+": .wrapRGB has been removed.");return new N}}});Object.defineProperties(Ca.prototype,{metal:{get:function(){console.warn("THREE.MeshPhongMaterial: .metal has been removed. Use THREE.MeshStandardMaterial instead.");return!1},set:function(){console.warn("THREE.MeshPhongMaterial: .metal has been removed. Use THREE.MeshStandardMaterial instead")}}});Object.defineProperties(Ia.prototype,{derivatives:{get:function(){console.warn("THREE.ShaderMaterial: .derivatives has been moved to .extensions.derivatives."); -return this.extensions.derivatives},set:function(a){console.warn("THREE. ShaderMaterial: .derivatives has been moved to .extensions.derivatives.");this.extensions.derivatives=a}}});oa.prototype=Object.assign(Object.create({constructor:oa,apply:function(a){console.warn("THREE.EventDispatcher: .apply is deprecated, just inherit or Object.assign the prototype to mix-in.");Object.assign(a,this)}}),oa.prototype);Object.assign(Nd.prototype,{supportsFloatTextures:function(){console.warn("THREE.WebGLRenderer: .supportsFloatTextures() is now .extensions.get( 'OES_texture_float' )."); -return this.extensions.get("OES_texture_float")},supportsHalfFloatTextures:function(){console.warn("THREE.WebGLRenderer: .supportsHalfFloatTextures() is now .extensions.get( 'OES_texture_half_float' ).");return this.extensions.get("OES_texture_half_float")},supportsStandardDerivatives:function(){console.warn("THREE.WebGLRenderer: .supportsStandardDerivatives() is now .extensions.get( 'OES_standard_derivatives' ).");return this.extensions.get("OES_standard_derivatives")},supportsCompressedTextureS3TC:function(){console.warn("THREE.WebGLRenderer: .supportsCompressedTextureS3TC() is now .extensions.get( 'WEBGL_compressed_texture_s3tc' )."); -return this.extensions.get("WEBGL_compressed_texture_s3tc")},supportsCompressedTexturePVRTC:function(){console.warn("THREE.WebGLRenderer: .supportsCompressedTexturePVRTC() is now .extensions.get( 'WEBGL_compressed_texture_pvrtc' ).");return this.extensions.get("WEBGL_compressed_texture_pvrtc")},supportsBlendMinMax:function(){console.warn("THREE.WebGLRenderer: .supportsBlendMinMax() is now .extensions.get( 'EXT_blend_minmax' ).");return this.extensions.get("EXT_blend_minmax")},supportsVertexTextures:function(){console.warn("THREE.WebGLRenderer: .supportsVertexTextures() is now .capabilities.vertexTextures."); -return this.capabilities.vertexTextures},supportsInstancedArrays:function(){console.warn("THREE.WebGLRenderer: .supportsInstancedArrays() is now .extensions.get( 'ANGLE_instanced_arrays' ).");return this.extensions.get("ANGLE_instanced_arrays")},enableScissorTest:function(a){console.warn("THREE.WebGLRenderer: .enableScissorTest() is now .setScissorTest().");this.setScissorTest(a)},initMaterial:function(){console.warn("THREE.WebGLRenderer: .initMaterial() has been removed.")},addPrePlugin:function(){console.warn("THREE.WebGLRenderer: .addPrePlugin() has been removed.")}, -addPostPlugin:function(){console.warn("THREE.WebGLRenderer: .addPostPlugin() has been removed.")},updateShadowMap:function(){console.warn("THREE.WebGLRenderer: .updateShadowMap() has been removed.")}});Object.defineProperties(Nd.prototype,{shadowMapEnabled:{get:function(){return this.shadowMap.enabled},set:function(a){console.warn("THREE.WebGLRenderer: .shadowMapEnabled is now .shadowMap.enabled.");this.shadowMap.enabled=a}},shadowMapType:{get:function(){return this.shadowMap.type},set:function(a){console.warn("THREE.WebGLRenderer: .shadowMapType is now .shadowMap.type."); -this.shadowMap.type=a}},shadowMapCullFace:{get:function(){return this.shadowMap.cullFace},set:function(a){console.warn("THREE.WebGLRenderer: .shadowMapCullFace is now .shadowMap.cullFace.");this.shadowMap.cullFace=a}}});Object.defineProperties(ye.prototype,{cullFace:{get:function(){return this.renderReverseSided?2:1},set:function(a){a=1!==a;console.warn("WebGLRenderer: .shadowMap.cullFace is deprecated. Set .shadowMap.renderReverseSided to "+a+".");this.renderReverseSided=a}}});Object.defineProperties(Db.prototype, -{wrapS:{get:function(){console.warn("THREE.WebGLRenderTarget: .wrapS is now .texture.wrapS.");return this.texture.wrapS},set:function(a){console.warn("THREE.WebGLRenderTarget: .wrapS is now .texture.wrapS.");this.texture.wrapS=a}},wrapT:{get:function(){console.warn("THREE.WebGLRenderTarget: .wrapT is now .texture.wrapT.");return this.texture.wrapT},set:function(a){console.warn("THREE.WebGLRenderTarget: .wrapT is now .texture.wrapT.");this.texture.wrapT=a}},magFilter:{get:function(){console.warn("THREE.WebGLRenderTarget: .magFilter is now .texture.magFilter."); -return this.texture.magFilter},set:function(a){console.warn("THREE.WebGLRenderTarget: .magFilter is now .texture.magFilter.");this.texture.magFilter=a}},minFilter:{get:function(){console.warn("THREE.WebGLRenderTarget: .minFilter is now .texture.minFilter.");return this.texture.minFilter},set:function(a){console.warn("THREE.WebGLRenderTarget: .minFilter is now .texture.minFilter.");this.texture.minFilter=a}},anisotropy:{get:function(){console.warn("THREE.WebGLRenderTarget: .anisotropy is now .texture.anisotropy."); -return this.texture.anisotropy},set:function(a){console.warn("THREE.WebGLRenderTarget: .anisotropy is now .texture.anisotropy.");this.texture.anisotropy=a}},offset:{get:function(){console.warn("THREE.WebGLRenderTarget: .offset is now .texture.offset.");return this.texture.offset},set:function(a){console.warn("THREE.WebGLRenderTarget: .offset is now .texture.offset.");this.texture.offset=a}},repeat:{get:function(){console.warn("THREE.WebGLRenderTarget: .repeat is now .texture.repeat.");return this.texture.repeat}, -set:function(a){console.warn("THREE.WebGLRenderTarget: .repeat is now .texture.repeat.");this.texture.repeat=a}},format:{get:function(){console.warn("THREE.WebGLRenderTarget: .format is now .texture.format.");return this.texture.format},set:function(a){console.warn("THREE.WebGLRenderTarget: .format is now .texture.format.");this.texture.format=a}},type:{get:function(){console.warn("THREE.WebGLRenderTarget: .type is now .texture.type.");return this.texture.type},set:function(a){console.warn("THREE.WebGLRenderTarget: .type is now .texture.type."); -this.texture.type=a}},generateMipmaps:{get:function(){console.warn("THREE.WebGLRenderTarget: .generateMipmaps is now .texture.generateMipmaps.");return this.texture.generateMipmaps},set:function(a){console.warn("THREE.WebGLRenderTarget: .generateMipmaps is now .texture.generateMipmaps.");this.texture.generateMipmaps=a}}});ec.prototype.load=function(a){console.warn("THREE.Audio: .load has been deprecated. Use THREE.AudioLoader instead.");var b=this;(new Wd).load(a,function(a){b.setBuffer(a)});return this}; -ae.prototype.getData=function(){console.warn("THREE.AudioAnalyser: .getData() is now .getFrequencyData().");return this.getFrequencyData()};l.WebGLRenderTargetCube=Eb;l.WebGLRenderTarget=Db;l.WebGLRenderer=Nd;l.ShaderLib=Gb;l.UniformsLib=U;l.UniformsUtils=Ja;l.ShaderChunk=Z;l.FogExp2=Ib;l.Fog=Jb;l.Scene=jb;l.LensFlare=Od;l.Sprite=zc;l.LOD=Ac;l.SkinnedMesh=jd;l.Skeleton=hd;l.Bone=id;l.Mesh=Ba;l.LineSegments=fa;l.Line=Va;l.Points=Kb;l.Group=Bc;l.VideoTexture=kd;l.DataTexture=db;l.CompressedTexture= -Lb;l.CubeTexture=Za;l.CanvasTexture=ld;l.DepthTexture=Cc;l.Texture=ea;l.CompressedTextureLoader=Ee;l.BinaryTextureLoader=Qd;l.DataTextureLoader=Qd;l.CubeTextureLoader=Rd;l.TextureLoader=md;l.ObjectLoader=Fe;l.MaterialLoader=Ad;l.BufferGeometryLoader=Sd;l.DefaultLoadingManager=va;l.LoadingManager=Pd;l.JSONLoader=Td;l.ImageLoader=Vc;l.FontLoader=Ge;l.FileLoader=Ma;l.Loader=wb;l.Cache=ne;l.AudioLoader=Wd;l.SpotLightShadow=od;l.SpotLight=pd;l.PointLight=qd;l.RectAreaLight=Xd;l.HemisphereLight=nd;l.DirectionalLightShadow= -rd;l.DirectionalLight=sd;l.AmbientLight=td;l.LightShadow=tb;l.Light=na;l.StereoCamera=He;l.PerspectiveCamera=Ha;l.OrthographicCamera=Hb;l.CubeCamera=Bd;l.Camera=sa;l.AudioListener=Yd;l.PositionalAudio=$d;l.AudioContext=Zd;l.AudioAnalyser=ae;l.Audio=ec;l.VectorKeyframeTrack=cc;l.StringKeyframeTrack=xd;l.QuaternionKeyframeTrack=Xc;l.NumberKeyframeTrack=dc;l.ColorKeyframeTrack=zd;l.BooleanKeyframeTrack=yd;l.PropertyMixer=Cd;l.PropertyBinding=ka;l.KeyframeTrack=vb;l.AnimationUtils=ba;l.AnimationObjectGroup= -be;l.AnimationMixer=de;l.AnimationClip=ta;l.Uniform=Dd;l.InstancedBufferGeometry=Bb;l.BufferGeometry=D;l.GeometryIdCount=function(){return Kd++};l.Geometry=S;l.InterleavedBufferAttribute=ee;l.InstancedInterleavedBuffer=gc;l.InterleavedBuffer=fc;l.InstancedBufferAttribute=hc;l.Face3=ha;l.Object3D=G;l.Raycaster=fe;l.Layers=gd;l.EventDispatcher=oa;l.Clock=he;l.QuaternionLinearInterpolant=wd;l.LinearInterpolant=Wc;l.DiscreteInterpolant=vd;l.CubicInterpolant=ud;l.Interpolant=qa;l.Triangle=Aa;l.Spline= -function(a){function b(a,b,c,d,e,f,g){a=.5*(c-a);d=.5*(d-b);return(2*(b-c)+a+d)*g+(-3*(b-c)-2*a-d)*f+a*e+b}this.points=a;var c=[],d={x:0,y:0,z:0},e,f,g,h,k,l,x,p,n;this.initFromArray=function(a){this.points=[];for(var b=0;bthis.points.length-2?this.points.length-1:f+1;c[3]=f>this.points.length-3?this.points.length-1:f+2;l=this.points[c[0]]; -x=this.points[c[1]];p=this.points[c[2]];n=this.points[c[3]];h=g*g;k=g*h;d.x=b(l.x,x.x,p.x,n.x,g,h,k);d.y=b(l.y,x.y,p.y,n.y,g,h,k);d.z=b(l.z,x.z,p.z,n.z,g,h,k);return d};this.getControlPointsArray=function(){var a,b,c=this.points.length,d=[];for(a=0;a= +d||0 0 ) {\nfloat depth = gl_FragCoord.z / gl_FragCoord.w;\nfloat fogFactor = 0.0;\nif ( fogType == 1 ) {\nfogFactor = smoothstep( fogNear, fogFar, depth );\n} else {\nconst float LOG2 = 1.442695;\nfogFactor = exp2( - fogDensity * fogDensity * depth * depth * LOG2 );\nfogFactor = 1.0 - clamp( fogFactor, 0.0, 1.0 );\n}\ngl_FragColor = mix( gl_FragColor, vec4( fogColor, gl_FragColor.w ), fogFactor );\n}\n}"].join("\n")); +z.compileShader(P);z.compileShader(R);z.attachShader(O,P);z.attachShader(O,R);z.linkProgram(O);K=O;t=z.getAttribLocation(K,"position");v=z.getAttribLocation(K,"uv");c=z.getUniformLocation(K,"uvOffset");d=z.getUniformLocation(K,"uvScale");e=z.getUniformLocation(K,"rotation");f=z.getUniformLocation(K,"scale");g=z.getUniformLocation(K,"color");h=z.getUniformLocation(K,"map");k=z.getUniformLocation(K,"opacity");m=z.getUniformLocation(K,"modelViewMatrix");x=z.getUniformLocation(K,"projectionMatrix");p= +z.getUniformLocation(K,"fogType");n=z.getUniformLocation(K,"fogDensity");r=z.getUniformLocation(K,"fogNear");w=z.getUniformLocation(K,"fogFar");l=z.getUniformLocation(K,"fogColor");F=z.getUniformLocation(K,"alphaTest");O=document.createElementNS("http://www.w3.org/1999/xhtml","canvas");O.width=8;O.height=8;P=O.getContext("2d");P.fillStyle="white";P.fillRect(0,0,8,8);la=new ea(O);la.needsUpdate=!0}z.useProgram(K);A.initAttributes();A.enableAttribute(t);A.enableAttribute(v);A.disableUnusedAttributes(); +A.disable(z.CULL_FACE);A.enable(z.BLEND);z.bindBuffer(z.ARRAY_BUFFER,I);z.vertexAttribPointer(t,2,z.FLOAT,!1,16,0);z.vertexAttribPointer(v,2,z.FLOAT,!1,16,8);z.bindBuffer(z.ELEMENT_ARRAY_BUFFER,E);z.uniformMatrix4fv(x,!1,Na.projectionMatrix.elements);A.activeTexture(z.TEXTURE0);z.uniform1i(h,0);P=O=0;(R=q.fog)?(z.uniform3f(l,R.color.r,R.color.g,R.color.b),R.isFog?(z.uniform1f(r,R.near),z.uniform1f(w,R.far),z.uniform1i(p,1),P=O=1):R.isFogExp2&&(z.uniform1f(n,R.density),z.uniform1i(p,2),P=O=2)):(z.uniform1i(p, +0),P=O=0);for(var R=0,T=b.length;R/g,function(a,c){var d=Z[c];if(void 0===d)throw Error("Can not resolve #include <"+c+">");return Md(d)})}function De(a){return a.replace(/for \( int i \= (\d+)\; i < (\d+)\; i \+\+ \) \{([\s\S]+?)(?=\})\}/g,function(a,c,d,e){a="";for(c=parseInt(c);c< +parseInt(d);c++)a+=e.replace(/\[ i \]/g,"[ "+c+" ]");return a})}function zf(a,b,c,d){var e=a.context,f=c.extensions,g=c.defines,h=c.__webglShader.vertexShader,k=c.__webglShader.fragmentShader,m="SHADOWMAP_TYPE_BASIC";1===d.shadowMapType?m="SHADOWMAP_TYPE_PCF":2===d.shadowMapType&&(m="SHADOWMAP_TYPE_PCF_SOFT");var x="ENVMAP_TYPE_CUBE",p="ENVMAP_MODE_REFLECTION",n="ENVMAP_BLENDING_MULTIPLY";if(d.envMap){switch(c.envMap.mapping){case 301:case 302:x="ENVMAP_TYPE_CUBE";break;case 306:case 307:x="ENVMAP_TYPE_CUBE_UV"; +break;case 303:case 304:x="ENVMAP_TYPE_EQUIREC";break;case 305:x="ENVMAP_TYPE_SPHERE"}switch(c.envMap.mapping){case 302:case 304:p="ENVMAP_MODE_REFRACTION"}switch(c.combine){case 0:n="ENVMAP_BLENDING_MULTIPLY";break;case 1:n="ENVMAP_BLENDING_MIX";break;case 2:n="ENVMAP_BLENDING_ADD"}}var r=0b||a.height>b){var c=b/Math.max(a.width,a.height),d=document.createElementNS("http://www.w3.org/1999/xhtml","canvas");d.width=Math.floor(a.width*c);d.height=Math.floor(a.height*c);d.getContext("2d").drawImage(a,0,0,a.width,a.height,0,0,d.width,d.height);console.warn("THREE.WebGLRenderer: image is too big ("+ +a.width+"x"+a.height+"). Resized to "+d.width+"x"+d.height,a);return d}return a}function k(a){return Q.isPowerOfTwo(a.width)&&Q.isPowerOfTwo(a.height)}function m(b){return 1003===b||1004===b||1005===b?a.NEAREST:a.LINEAR}function x(b){b=b.target;b.removeEventListener("dispose",x);a:{var c=d.get(b);if(b.image&&c.__image__webglTextureCube)a.deleteTexture(c.__image__webglTextureCube);else{if(void 0===c.__webglInit)break a;a.deleteTexture(c.__webglTexture)}d["delete"](b)}q.textures--}function p(b){b=b.target; +b.removeEventListener("dispose",p);var c=d.get(b),e=d.get(b.texture);if(b){void 0!==e.__webglTexture&&a.deleteTexture(e.__webglTexture);b.depthTexture&&b.depthTexture.dispose();if(b.isWebGLRenderTargetCube)for(e=0;6>e;e++)a.deleteFramebuffer(c.__webglFramebuffer[e]),c.__webglDepthbuffer&&a.deleteRenderbuffer(c.__webglDepthbuffer[e]);else a.deleteFramebuffer(c.__webglFramebuffer),c.__webglDepthbuffer&&a.deleteRenderbuffer(c.__webglDepthbuffer);d["delete"](b.texture);d["delete"](b)}q.textures--}function n(b, +g){var m=d.get(b);if(0w;w++)l[w]=n||p?p?b.image[w].image:b.image[w]:h(b.image[w],e.maxCubemapSize);var u=k(l[0]),t=f(b.format),ca=f(b.type);r(a.TEXTURE_CUBE_MAP,b,u);for(w=0;6>w;w++)if(n)for(var y,C=l[w].mipmaps,D=0,O=C.length;Dm;m++)e.__webglFramebuffer[m]=a.createFramebuffer()}else e.__webglFramebuffer= +a.createFramebuffer();if(g){c.bindTexture(a.TEXTURE_CUBE_MAP,f.__webglTexture);r(a.TEXTURE_CUBE_MAP,b.texture,h);for(m=0;6>m;m++)l(e.__webglFramebuffer[m],b,a.COLOR_ATTACHMENT0,a.TEXTURE_CUBE_MAP_POSITIVE_X+m);b.texture.generateMipmaps&&h&&a.generateMipmap(a.TEXTURE_CUBE_MAP);c.bindTexture(a.TEXTURE_CUBE_MAP,null)}else c.bindTexture(a.TEXTURE_2D,f.__webglTexture),r(a.TEXTURE_2D,b.texture,h),l(e.__webglFramebuffer,b,a.COLOR_ATTACHMENT0,a.TEXTURE_2D),b.texture.generateMipmaps&&h&&a.generateMipmap(a.TEXTURE_2D), +c.bindTexture(a.TEXTURE_2D,null);if(b.depthBuffer){e=d.get(b);f=!0===b.isWebGLRenderTargetCube;if(b.depthTexture){if(f)throw Error("target.depthTexture not supported in Cube render targets");if(b&&b.isWebGLRenderTargetCube)throw Error("Depth Texture with cube render targets is not supported!");a.bindFramebuffer(a.FRAMEBUFFER,e.__webglFramebuffer);if(!b.depthTexture||!b.depthTexture.isDepthTexture)throw Error("renderTarget.depthTexture must be an instance of THREE.DepthTexture");d.get(b.depthTexture).__webglTexture&& +b.depthTexture.image.width===b.width&&b.depthTexture.image.height===b.height||(b.depthTexture.image.width=b.width,b.depthTexture.image.height=b.height,b.depthTexture.needsUpdate=!0);n(b.depthTexture,0);e=d.get(b.depthTexture).__webglTexture;if(1026===b.depthTexture.format)a.framebufferTexture2D(a.FRAMEBUFFER,a.DEPTH_ATTACHMENT,a.TEXTURE_2D,e,0);else if(1027===b.depthTexture.format)a.framebufferTexture2D(a.FRAMEBUFFER,a.DEPTH_STENCIL_ATTACHMENT,a.TEXTURE_2D,e,0);else throw Error("Unknown depthTexture format"); +}else if(f)for(e.__webglDepthbuffer=[],f=0;6>f;f++)a.bindFramebuffer(a.FRAMEBUFFER,e.__webglFramebuffer[f]),e.__webglDepthbuffer[f]=a.createRenderbuffer(),u(e.__webglDepthbuffer[f],b);else a.bindFramebuffer(a.FRAMEBUFFER,e.__webglFramebuffer),e.__webglDepthbuffer=a.createRenderbuffer(),u(e.__webglDepthbuffer,b);a.bindFramebuffer(a.FRAMEBUFFER,null)}};this.updateRenderTargetMipmap=function(b){var e=b.texture;e.generateMipmaps&&k(b)&&1003!==e.minFilter&&1006!==e.minFilter&&(b=b&&b.isWebGLRenderTargetCube? +a.TEXTURE_CUBE_MAP:a.TEXTURE_2D,e=d.get(e).__webglTexture,c.bindTexture(b,e),a.generateMipmap(b),c.bindTexture(b,null))}}function Ff(){var a={};return{get:function(b){b=b.uuid;var c=a[b];void 0===c&&(c={},a[b]=c);return c},"delete":function(b){delete a[b.uuid]},clear:function(){a={}}}}function Gf(a,b,c){function d(b,c,d){var e=new Uint8Array(4),f=a.createTexture();a.bindTexture(b,f);a.texParameteri(b,a.TEXTURE_MIN_FILTER,a.NEAREST);a.texParameteri(b,a.TEXTURE_MAG_FILTER,a.NEAREST);for(b=0;b=ma.maxTextures&&console.warn("WebGLRenderer: trying to use "+a+" texture units while this GPU supports only "+ma.maxTextures);ea+=1;return a};this.setTexture2D=function(){var a=!1;return function(b,c){b&&b.isWebGLRenderTarget&& +(a||(console.warn("THREE.WebGLRenderer.setTexture2D: don't use render targets as textures. Use their .texture property instead."),a=!0),b=b.texture);va.setTexture2D(b,c)}}();this.setTexture=function(){var a=!1;return function(b,c){a||(console.warn("THREE.WebGLRenderer: .setTexture is deprecated, use setTexture2D instead."),a=!0);va.setTexture2D(b,c)}}();this.setTextureCube=function(){var a=!1;return function(b,c){b&&b.isWebGLRenderTargetCube&&(a||(console.warn("THREE.WebGLRenderer.setTextureCube: don't use cube render targets as textures. Use their .texture property instead."), +a=!0),b=b.texture);b&&b.isCubeTexture||Array.isArray(b.image)&&6===b.image.length?va.setTextureCube(b,c):va.setTextureCubeDynamic(b,c)}}();this.getCurrentRenderTarget=function(){return V};this.setRenderTarget=function(a){(V=a)&&void 0===ha.get(a).__webglFramebuffer&&va.setupRenderTarget(a);var b=a&&a.isWebGLRenderTargetCube,c;a?(c=ha.get(a),c=b?c.__webglFramebuffer[a.activeCubeFace]:c.__webglFramebuffer,X.copy(a.scissor),Ta=a.scissorTest,Z.copy(a.viewport)):(c=null,X.copy(fa).multiplyScalar(Sa),Ta= +ka,Z.copy(ia).multiplyScalar(Sa));S!==c&&(B.bindFramebuffer(B.FRAMEBUFFER,c),S=c);Y.scissor(X);Y.setScissorTest(Ta);Y.viewport(Z);b&&(b=ha.get(a.texture),B.framebufferTexture2D(B.FRAMEBUFFER,B.COLOR_ATTACHMENT0,B.TEXTURE_CUBE_MAP_POSITIVE_X+a.activeCubeFace,b.__webglTexture,a.activeMipMapLevel))};this.readRenderTargetPixels=function(a,b,c,d,e,f){if(!1===(a&&a.isWebGLRenderTarget))console.error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not THREE.WebGLRenderTarget.");else{var g=ha.get(a).__webglFramebuffer; +if(g){var h=!1;g!==S&&(B.bindFramebuffer(B.FRAMEBUFFER,g),h=!0);try{var k=a.texture,m=k.format,n=k.type;1023!==m&&t(m)!==B.getParameter(B.IMPLEMENTATION_COLOR_READ_FORMAT)?console.error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not in RGBA or implementation defined format."):1009===n||t(n)===B.getParameter(B.IMPLEMENTATION_COLOR_READ_TYPE)||1015===n&&(ja.get("OES_texture_float")||ja.get("WEBGL_color_buffer_float"))||1016===n&&ja.get("EXT_color_buffer_half_float")?B.checkFramebufferStatus(B.FRAMEBUFFER)=== +B.FRAMEBUFFER_COMPLETE?0<=b&&b<=a.width-d&&0<=c&&c<=a.height-e&&B.readPixels(b,c,d,e,t(m),t(n),f):console.error("THREE.WebGLRenderer.readRenderTargetPixels: readPixels from renderTarget failed. Framebuffer not complete."):console.error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not in UnsignedByteType or implementation defined type.")}finally{h&&B.bindFramebuffer(B.FRAMEBUFFER,S)}}}}}function Ib(a,b){this.name="";this.color=new N(a);this.density=void 0!==b?b:2.5E-4}function Jb(a, +b,c){this.name="";this.color=new N(a);this.near=void 0!==b?b:1;this.far=void 0!==c?c:1E3}function jb(){G.call(this);this.type="Scene";this.overrideMaterial=this.fog=this.background=null;this.autoUpdate=!0}function Od(a,b,c,d,e){G.call(this);this.lensFlares=[];this.positionScreen=new q;this.customUpdateCallback=void 0;void 0!==a&&this.add(a,b,c,d,e)}function kb(a){W.call(this);this.type="SpriteMaterial";this.color=new N(16777215);this.map=null;this.rotation=0;this.lights=this.fog=!1;this.setValues(a)} +function zc(a){G.call(this);this.type="Sprite";this.material=void 0!==a?a:new kb}function Ac(){G.call(this);this.type="LOD";Object.defineProperties(this,{levels:{enumerable:!0,value:[]}})}function hd(a,b,c){this.useVertexTexture=void 0!==c?c:!0;this.identityMatrix=new H;a=a||[];this.bones=a.slice(0);this.useVertexTexture?(a=Math.sqrt(4*this.bones.length),a=Q.nextPowerOfTwo(Math.ceil(a)),this.boneTextureHeight=this.boneTextureWidth=a=Math.max(a,4),this.boneMatrices=new Float32Array(this.boneTextureWidth* +this.boneTextureHeight*4),this.boneTexture=new db(this.boneMatrices,this.boneTextureWidth,this.boneTextureHeight,1023,1015)):this.boneMatrices=new Float32Array(16*this.bones.length);if(void 0===b)this.calculateInverses();else if(this.bones.length===b.length)this.boneInverses=b.slice(0);else for(console.warn("THREE.Skeleton bonInverses is the wrong length."),this.boneInverses=[],b=0,a=this.bones.length;b=a.HAVE_CURRENT_DATA&&(x.needsUpdate=!0)}ea.call(this,a,b,c,d,e,f,g,h,k);this.generateMipmaps=!1;var x=this;m()}function Lb(a,b,c,d,e,f,g,h,k,m,x,p){ea.call(this,null,f,g,h,k,m,d,e,x,p);this.image={width:b,height:c};this.mipmaps=a;this.generateMipmaps=this.flipY=!1}function ld(a,b,c,d,e,f,g,h,k){ea.call(this,a,b,c,d,e,f,g,h,k);this.needsUpdate=!0}function Cc(a,b,c,d,e,f,g,h,k,m){m=void 0!==m?m:1026;if(1026!==m&&1027!== +m)throw Error("DepthTexture format must be either THREE.DepthFormat or THREE.DepthStencilFormat");void 0===c&&1026===m&&(c=1012);void 0===c&&1027===m&&(c=1020);ea.call(this,null,d,e,f,g,h,m,c,k);this.image={width:a,height:b};this.magFilter=void 0!==g?g:1003;this.minFilter=void 0!==h?h:1003;this.generateMipmaps=this.flipY=!1}function Mb(a){function b(a,b){return a-b}D.call(this);var c=[0,0],d={},e=["a","b","c"];if(a&&a.isGeometry){var f=a.vertices,g=a.faces,h=0,k=new Uint32Array(6*g.length);a=0;for(var m= +g.length;ap;p++){c[0]=x[e[p]];c[1]=x[e[(p+1)%3]];c.sort(b);var n=c.toString();void 0===d[n]&&(k[2*h]=c[0],k[2*h+1]=c[1],d[n]=!0,h++)}c=new Float32Array(6*h);a=0;for(m=h;ap;p++)d=f[k[2*a+p]],h=6*a+3*p,c[h+0]=d.x,c[h+1]=d.y,c[h+2]=d.z;this.addAttribute("position",new y(c,3))}else if(a&&a.isBufferGeometry){if(null!==a.index){m=a.index.array;f=a.attributes.position;e=a.groups;h=0;0===e.length&&a.addGroup(0,m.length);k=new Uint32Array(2*m.length);g=0;for(x= +e.length;gp;p++)c[0]=m[a+p],c[1]=m[a+(p+1)%3],c.sort(b),n=c.toString(),void 0===d[n]&&(k[2*h]=c[0],k[2*h+1]=c[1],d[n]=!0,h++)}c=new Float32Array(6*h);a=0;for(m=h;ap;p++)h=6*a+3*p,d=k[2*a+p],c[h+0]=f.getX(d),c[h+1]=f.getY(d),c[h+2]=f.getZ(d)}else for(f=a.attributes.position.array,h=f.length/3,k=h/3,c=new Float32Array(6*h),a=0,m=k;ap;p++)h=18*a+6*p,k=9*a+3*p,c[h+0]=f[k],c[h+1]=f[k+1],c[h+2]=f[k+ +2],d=9*a+(p+1)%3*3,c[h+3]=f[d],c[h+4]=f[d+1],c[h+5]=f[d+2];this.addAttribute("position",new y(c,3))}}function Nb(a,b,c){D.call(this);this.type="ParametricBufferGeometry";this.parameters={func:a,slices:b,stacks:c};var d=[],e=[],f,g,h,k,m,x=b+1;for(f=0;f<=c;f++)for(m=f/c,g=0;g<=b;g++)k=g/b,h=a(k,m),d.push(h.x,h.y,h.z),e.push(k,m);a=[];var p;for(f=0;fd&&1===a.x&&(k[b]=a.x-1);0===c.x&&0===c.z&&(k[b]=d/2/Math.PI+.5)}D.call(this);this.type="PolyhedronBufferGeometry";this.parameters= +{vertices:a,indices:b,radius:c,detail:d};c=c||1;var h=[],k=[];(function(a){for(var c=new q,d=new q,g=new q,h=0;he&&(.2>b&&(k[a+0]+=1),.2>c&&(k[a+2]+=1),.2>d&&(k[a+4]+=1))})();this.addAttribute("position",new X(h,3));this.addAttribute("normal",new X(h.slice(),3));this.addAttribute("uv",new X(k,2));this.normalizeNormals();this.boundingSphere= +new Fa(new q,c)}function Ob(a,b){xa.call(this,[1,1,1,-1,-1,1,-1,1,-1,1,-1,-1],[2,1,0,0,3,2,1,3,0,2,3,1],a,b);this.type="TetrahedronBufferGeometry";this.parameters={radius:a,detail:b}}function Ec(a,b){S.call(this);this.type="TetrahedronGeometry";this.parameters={radius:a,detail:b};this.fromBufferGeometry(new Ob(a,b));this.mergeVertices()}function lb(a,b){xa.call(this,[1,0,0,-1,0,0,0,1,0,0,-1,0,0,0,1,0,0,-1],[0,2,4,0,4,3,0,3,5,0,5,2,1,2,5,1,5,3,1,3,4,1,4,2],a,b);this.type="OctahedronBufferGeometry"; +this.parameters={radius:a,detail:b}}function Fc(a,b){S.call(this);this.type="OctahedronGeometry";this.parameters={radius:a,detail:b};this.fromBufferGeometry(new lb(a,b));this.mergeVertices()}function Pb(a,b){var c=(1+Math.sqrt(5))/2;xa.call(this,[-1,c,0,1,c,0,-1,-c,0,1,-c,0,0,-1,c,0,1,c,0,-1,-c,0,1,-c,c,0,-1,c,0,1,-c,0,-1,-c,0,1],[0,11,5,0,5,1,0,1,7,0,7,10,0,10,11,1,5,9,5,11,4,11,10,2,10,7,6,7,1,8,3,9,4,3,4,2,3,2,6,3,6,8,3,8,9,4,9,5,2,4,11,6,2,10,8,6,7,9,8,1],a,b);this.type="IcosahedronBufferGeometry"; +this.parameters={radius:a,detail:b}}function Gc(a,b){S.call(this);this.type="IcosahedronGeometry";this.parameters={radius:a,detail:b};this.fromBufferGeometry(new Pb(a,b));this.mergeVertices()}function Qb(a,b){var c=(1+Math.sqrt(5))/2,d=1/c;xa.call(this,[-1,-1,-1,-1,-1,1,-1,1,-1,-1,1,1,1,-1,-1,1,-1,1,1,1,-1,1,1,1,0,-d,-c,0,-d,c,0,d,-c,0,d,c,-d,-c,0,-d,c,0,d,-c,0,d,c,0,-c,0,-d,c,0,-d,-c,0,d,c,0,d],[3,11,7,3,7,15,3,15,13,7,19,17,7,17,6,7,6,15,17,4,8,17,8,10,17,10,6,8,0,16,8,16,2,8,2,10,0,12,1,0,1,18, +0,18,16,6,10,2,6,2,13,6,13,15,2,16,18,2,18,3,2,3,13,18,1,9,18,9,11,18,11,3,4,14,12,4,12,0,4,0,8,11,9,5,11,5,19,11,19,7,19,5,14,19,14,4,19,4,17,1,12,14,1,14,5,1,5,9],a,b);this.type="DodecahedronBufferGeometry";this.parameters={radius:a,detail:b}}function Hc(a,b){S.call(this);this.type="DodecahedronGeometry";this.parameters={radius:a,detail:b};this.fromBufferGeometry(new Qb(a,b));this.mergeVertices()}function Ic(a,b,c,d){S.call(this);this.type="PolyhedronGeometry";this.parameters={vertices:a,indices:b, +radius:c,detail:d};this.fromBufferGeometry(new xa(a,b,c,d));this.mergeVertices()}function Rb(a,b,c,d,e){function f(e){var f=a.getPointAt(e/b),m=g.normals[e];e=g.binormals[e];for(p=0;p<=d;p++){var x=p/d*Math.PI*2,l=Math.sin(x),x=-Math.cos(x);k.x=x*m.x+l*e.x;k.y=x*m.y+l*e.y;k.z=x*m.z+l*e.z;k.normalize();r.push(k.x,k.y,k.z);h.x=f.x+c*k.x;h.y=f.y+c*k.y;h.z=f.z+c*k.z;n.push(h.x,h.y,h.z)}}D.call(this);this.type="TubeBufferGeometry";this.parameters={path:a,tubularSegments:b,radius:c,radialSegments:d,closed:e}; +b=b||64;c=c||1;d=d||8;e=e||!1;var g=a.computeFrenetFrames(b,e);this.tangents=g.tangents;this.normals=g.normals;this.binormals=g.binormals;var h=new q,k=new q,m=new C,x,p,n=[],r=[],l=[],u=[];for(x=0;xn;n++){e[0]=p[g[n]];e[1]=p[g[(n+1)%3]];e.sort(c);var r=e.toString();void 0===f[r]?f[r]={vert1:e[0],vert2:e[1],face1:m,face2:void 0}:f[r].face2=m}e=[];for(r in f)if(g=f[r],void 0===g.face2||h[g.face1].normal.dot(h[g.face2].normal)<=d)m=k[g.vert1],e.push(m.x),e.push(m.y),e.push(m.z),m=k[g.vert2],e.push(m.x),e.push(m.y),e.push(m.z);this.addAttribute("position",new X(e,3))}function Wa(a,b,c,d,e,f,g,h){function k(c){var e,f,k,n=new C,p=new q,l=0,x=!0=== +c?a:b,M=!0===c?1:-1;f=t;for(e=1;e<=d;e++)w.setXYZ(t,0,z*M,0),u.setXYZ(t,0,M,0),n.x=.5,n.y=.5,F.setXY(t,n.x,n.y),t++;k=t;for(e=0;e<=d;e++){var y=e/d*h+g,D=Math.cos(y),y=Math.sin(y);p.x=x*y;p.y=z*M;p.z=x*D;w.setXYZ(t,p.x,p.y,p.z);u.setXYZ(t,0,M,0);n.x=.5*D+.5;n.y=.5*y*M+.5;F.setXY(t,n.x,n.y);t++}for(e=0;ethis.duration&&this.resetDuration();this.optimize()}function Ad(a){this.manager= +void 0!==a?a:va;this.textures={}}function Sd(a){this.manager=void 0!==a?a:va}function wb(){this.onLoadStart=function(){};this.onLoadProgress=function(){};this.onLoadComplete=function(){}}function Td(a){"boolean"===typeof a&&(console.warn("THREE.JSONLoader: showStatus parameter has been removed from constructor."),a=void 0);this.manager=void 0!==a?a:va;this.withCredentials=!1}function Fe(a){this.manager=void 0!==a?a:va;this.texturePath=""}function wa(){}function Qa(a,b){this.v1=a;this.v2=b}function Yc(){this.curves= +[];this.autoClose=!1}function Xa(a,b,c,d,e,f,g,h){this.aX=a;this.aY=b;this.xRadius=c;this.yRadius=d;this.aStartAngle=e;this.aEndAngle=f;this.aClockwise=g;this.aRotation=h||0}function xb(a){this.points=void 0===a?[]:a}function yb(a,b,c,d){this.v0=a;this.v1=b;this.v2=c;this.v3=d}function zb(a,b,c){this.v0=a;this.v1=b;this.v2=c}function Ab(){Zc.apply(this,arguments);this.holes=[]}function Zc(a){Yc.call(this);this.currentPoint=new C;a&&this.fromPoints(a)}function Ud(){this.subPaths=[];this.currentPath= +null}function Vd(a){this.data=a}function Ge(a){this.manager=void 0!==a?a:va}function Wd(a){this.manager=void 0!==a?a:va}function Xd(a,b,c,d){na.call(this,a,b);this.type="RectAreaLight";this.position.set(0,1,0);this.updateMatrix();this.width=void 0!==c?c:10;this.height=void 0!==d?d:10}function He(){this.type="StereoCamera";this.aspect=1;this.eyeSep=.064;this.cameraL=new Ha;this.cameraL.layers.enable(1);this.cameraL.matrixAutoUpdate=!1;this.cameraR=new Ha;this.cameraR.layers.enable(2);this.cameraR.matrixAutoUpdate= +!1}function Bd(a,b,c){G.call(this);this.type="CubeCamera";var d=new Ha(90,1,a,b);d.up.set(0,-1,0);d.lookAt(new q(1,0,0));this.add(d);var e=new Ha(90,1,a,b);e.up.set(0,-1,0);e.lookAt(new q(-1,0,0));this.add(e);var f=new Ha(90,1,a,b);f.up.set(0,0,1);f.lookAt(new q(0,1,0));this.add(f);var g=new Ha(90,1,a,b);g.up.set(0,0,-1);g.lookAt(new q(0,-1,0));this.add(g);var h=new Ha(90,1,a,b);h.up.set(0,-1,0);h.lookAt(new q(0,0,1));this.add(h);var k=new Ha(90,1,a,b);k.up.set(0,-1,0);k.lookAt(new q(0,0,-1));this.add(k); +this.renderTarget=new Eb(c,c,{format:1022,magFilter:1006,minFilter:1006});this.updateCubeMap=function(a,b){null===this.parent&&this.updateMatrixWorld();var c=this.renderTarget,n=c.texture.generateMipmaps;c.texture.generateMipmaps=!1;c.activeCubeFace=0;a.render(b,d,c);c.activeCubeFace=1;a.render(b,e,c);c.activeCubeFace=2;a.render(b,f,c);c.activeCubeFace=3;a.render(b,g,c);c.activeCubeFace=4;a.render(b,h,c);c.texture.generateMipmaps=n;c.activeCubeFace=5;a.render(b,k,c);a.setRenderTarget(null)}}function Yd(){G.call(this); +this.type="AudioListener";this.context=Zd.getContext();this.gain=this.context.createGain();this.gain.connect(this.context.destination);this.filter=null}function ec(a){G.call(this);this.type="Audio";this.context=a.context;this.gain=this.context.createGain();this.gain.connect(a.getInput());this.autoplay=!1;this.buffer=null;this.loop=!1;this.startTime=0;this.playbackRate=1;this.isPlaying=!1;this.hasPlaybackControl=!0;this.sourceType="empty";this.filters=[]}function $d(a){ec.call(this,a);this.panner= +this.context.createPanner();this.panner.connect(this.gain)}function ae(a,b){this.analyser=a.context.createAnalyser();this.analyser.fftSize=void 0!==b?b:2048;this.data=new Uint8Array(this.analyser.frequencyBinCount);a.getOutput().connect(this.analyser)}function Cd(a,b,c){this.binding=a;this.valueSize=c;a=Float64Array;switch(b){case "quaternion":b=this._slerp;break;case "string":case "bool":a=Array;b=this._select;break;default:b=this._lerp}this.buffer=new a(4*c);this._mixBufferRegion=b;this.referenceCount= +this.useCount=this.cumulativeWeight=0}function ka(a,b,c){this.path=b;this.parsedPath=c||ka.parseTrackName(b);this.node=ka.findNode(a,this.parsedPath.nodeName)||a;this.rootNode=a}function be(a){this.uuid=Q.generateUUID();this._objects=Array.prototype.slice.call(arguments);this.nCachedObjects_=0;var b={};this._indicesByUUID=b;for(var c=0,d=arguments.length;c!==d;++c)b[arguments[c].uuid]=c;this._paths=[];this._parsedPaths=[];this._bindings=[];this._bindingsIndicesByPath={};var e=this;this.stats={objects:{get total(){return e._objects.length}, +get inUse(){return this.total-e.nCachedObjects_}},get bindingsPerObject(){return e._bindings.length}}}function ce(a,b,c){this._mixer=a;this._clip=b;this._localRoot=c||null;a=b.tracks;b=a.length;c=Array(b);for(var d={endingStart:2400,endingEnd:2400},e=0;e!==b;++e){var f=a[e].createInterpolant(null);c[e]=f;f.settings=d}this._interpolantSettings=d;this._interpolants=c;this._propertyBindings=Array(b);this._weightInterpolant=this._timeScaleInterpolant=this._byClipCacheIndex=this._cacheIndex=null;this.loop= +2201;this._loopCount=-1;this._startTime=null;this.time=0;this._effectiveWeight=this.weight=this._effectiveTimeScale=this.timeScale=1;this.repetitions=Infinity;this.paused=!1;this.enabled=!0;this.clampWhenFinished=!1;this.zeroSlopeAtEnd=this.zeroSlopeAtStart=!0}function de(a){this._root=a;this._initMemoryManager();this.time=this._accuIndex=0;this.timeScale=1}function Dd(a,b){"string"===typeof a&&(console.warn("THREE.Uniform: Type parameter is no longer needed."),a=b);this.value=a}function Bb(){D.call(this); +this.type="InstancedBufferGeometry";this.maxInstancedCount=void 0}function ee(a,b,c,d){this.uuid=Q.generateUUID();this.data=a;this.itemSize=b;this.offset=c;this.normalized=!0===d}function fc(a,b){this.uuid=Q.generateUUID();this.array=a;this.stride=b;this.count=void 0!==a?a.length/b:0;this.dynamic=!1;this.updateRange={offset:0,count:-1};this.onUploadCallback=function(){};this.version=0}function gc(a,b,c){fc.call(this,a,b);this.meshPerAttribute=c||1}function hc(a,b,c){y.call(this,a,b);this.meshPerAttribute= +c||1}function fe(a,b,c,d){this.ray=new bb(a,b);this.near=c||0;this.far=d||Infinity;this.params={Mesh:{},Line:{},LOD:{},Points:{threshold:1},Sprite:{}};Object.defineProperties(this.params,{PointCloud:{get:function(){console.warn("THREE.Raycaster: params.PointCloud has been renamed to params.Points.");return this.Points}}})}function Ie(a,b){return a.distance-b.distance}function ge(a,b,c,d){if(!1!==a.visible&&(a.raycast(b,c),!0===d)){a=a.children;d=0;for(var e=a.length;dc;c++,d++){var e=c/32*Math.PI*2,f=d/32*Math.PI*2;b.push(Math.cos(e),Math.sin(e),1,Math.cos(f),Math.sin(f),1)}a.addAttribute("position",new X(b,3));b=new ia({fog:!1});this.cone=new fa(a,b);this.add(this.cone);this.update()}function jc(a){this.bones=this.getBoneList(a);for(var b=new D,c=[],d=[],e=new N(0,0,1),f=new N(0,1,0),g=0;ga?-1:0e;e++)8===e||13===e||18===e||23===e?b[e]="-":14===e?b[e]="4": +(2>=c&&(c=33554432+16777216*Math.random()|0),d=c&15,c>>=4,b[e]=a[19===e?d&3|8:d]);return b.join("")}}(),clamp:function(a,b,c){return Math.max(b,Math.min(c,a))},euclideanModulo:function(a,b){return(a%b+b)%b},mapLinear:function(a,b,c,d,e){return d+(a-b)*(e-d)/(c-b)},lerp:function(a,b,c){return(1-c)*a+c*b},smoothstep:function(a,b,c){if(a<=b)return 0;if(a>=c)return 1;a=(a-b)/(c-b);return a*a*(3-2*a)},smootherstep:function(a,b,c){if(a<=b)return 0;if(a>=c)return 1;a=(a-b)/(c-b);return a*a*a*(a*(6*a-15)+ +10)},randInt:function(a,b){return a+Math.floor(Math.random()*(b-a+1))},randFloat:function(a,b){return a+Math.random()*(b-a)},randFloatSpread:function(a){return a*(.5-Math.random())},degToRad:function(a){return a*Q.DEG2RAD},radToDeg:function(a){return a*Q.RAD2DEG},isPowerOfTwo:function(a){return 0===(a&a-1)&&0!==a},nearestPowerOfTwo:function(a){return Math.pow(2,Math.round(Math.log(a)/Math.LN2))},nextPowerOfTwo:function(a){a--;a|=a>>1;a|=a>>2;a|=a>>4;a|=a>>8;a|=a>>16;a++;return a}};C.prototype={constructor:C, +isVector2:!0,get width(){return this.x},set width(a){this.x=a},get height(){return this.y},set height(a){this.y=a},set:function(a,b){this.x=a;this.y=b;return this},setScalar:function(a){this.y=this.x=a;return this},setX:function(a){this.x=a;return this},setY:function(a){this.y=a;return this},setComponent:function(a,b){switch(a){case 0:this.x=b;break;case 1:this.y=b;break;default:throw Error("index is out of range: "+a);}return this},getComponent:function(a){switch(a){case 0:return this.x;case 1:return this.y; +default:throw Error("index is out of range: "+a);}},clone:function(){return new this.constructor(this.x,this.y)},copy:function(a){this.x=a.x;this.y=a.y;return this},add:function(a,b){if(void 0!==b)return console.warn("THREE.Vector2: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(a,b);this.x+=a.x;this.y+=a.y;return this},addScalar:function(a){this.x+=a;this.y+=a;return this},addVectors:function(a,b){this.x=a.x+b.x;this.y=a.y+b.y;return this},addScaledVector:function(a, +b){this.x+=a.x*b;this.y+=a.y*b;return this},sub:function(a,b){if(void 0!==b)return console.warn("THREE.Vector2: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(a,b);this.x-=a.x;this.y-=a.y;return this},subScalar:function(a){this.x-=a;this.y-=a;return this},subVectors:function(a,b){this.x=a.x-b.x;this.y=a.y-b.y;return this},multiply:function(a){this.x*=a.x;this.y*=a.y;return this},multiplyScalar:function(a){isFinite(a)?(this.x*=a,this.y*=a):this.y=this.x=0; +return this},divide:function(a){this.x/=a.x;this.y/=a.y;return this},divideScalar:function(a){return this.multiplyScalar(1/a)},min:function(a){this.x=Math.min(this.x,a.x);this.y=Math.min(this.y,a.y);return this},max:function(a){this.x=Math.max(this.x,a.x);this.y=Math.max(this.y,a.y);return this},clamp:function(a,b){this.x=Math.max(a.x,Math.min(b.x,this.x));this.y=Math.max(a.y,Math.min(b.y,this.y));return this},clampScalar:function(){var a,b;return function(c,d){void 0===a&&(a=new C,b=new C);a.set(c, +c);b.set(d,d);return this.clamp(a,b)}}(),clampLength:function(a,b){var c=this.length();return this.multiplyScalar(Math.max(a,Math.min(b,c))/c)},floor:function(){this.x=Math.floor(this.x);this.y=Math.floor(this.y);return this},ceil:function(){this.x=Math.ceil(this.x);this.y=Math.ceil(this.y);return this},round:function(){this.x=Math.round(this.x);this.y=Math.round(this.y);return this},roundToZero:function(){this.x=0>this.x?Math.ceil(this.x):Math.floor(this.x);this.y=0>this.y?Math.ceil(this.y):Math.floor(this.y); +return this},negate:function(){this.x=-this.x;this.y=-this.y;return this},dot:function(a){return this.x*a.x+this.y*a.y},lengthSq:function(){return this.x*this.x+this.y*this.y},length:function(){return Math.sqrt(this.x*this.x+this.y*this.y)},lengthManhattan:function(){return Math.abs(this.x)+Math.abs(this.y)},normalize:function(){return this.divideScalar(this.length())},angle:function(){var a=Math.atan2(this.y,this.x);0>a&&(a+=2*Math.PI);return a},distanceTo:function(a){return Math.sqrt(this.distanceToSquared(a))}, +distanceToSquared:function(a){var b=this.x-a.x;a=this.y-a.y;return b*b+a*a},distanceToManhattan:function(a){return Math.abs(this.x-a.x)+Math.abs(this.y-a.y)},setLength:function(a){return this.multiplyScalar(a/this.length())},lerp:function(a,b){this.x+=(a.x-this.x)*b;this.y+=(a.y-this.y)*b;return this},lerpVectors:function(a,b,c){return this.subVectors(b,a).multiplyScalar(c).add(a)},equals:function(a){return a.x===this.x&&a.y===this.y},fromArray:function(a,b){void 0===b&&(b=0);this.x=a[b];this.y=a[b+ +1];return this},toArray:function(a,b){void 0===a&&(a=[]);void 0===b&&(b=0);a[b]=this.x;a[b+1]=this.y;return a},fromAttribute:function(a,b,c){void 0!==c&&console.warn("THREE.Vector2: offset has been removed from .fromAttribute().");this.x=a.getX(b);this.y=a.getY(b);return this},rotateAround:function(a,b){var c=Math.cos(b),d=Math.sin(b),e=this.x-a.x,f=this.y-a.y;this.x=e*c-f*d+a.x;this.y=e*d+f*c+a.y;return this}};var Oe=0;ea.DEFAULT_IMAGE=void 0;ea.DEFAULT_MAPPING=300;ea.prototype={constructor:ea,isTexture:!0, +set needsUpdate(a){!0===a&&this.version++},clone:function(){return(new this.constructor).copy(this)},copy:function(a){this.image=a.image;this.mipmaps=a.mipmaps.slice(0);this.mapping=a.mapping;this.wrapS=a.wrapS;this.wrapT=a.wrapT;this.magFilter=a.magFilter;this.minFilter=a.minFilter;this.anisotropy=a.anisotropy;this.format=a.format;this.type=a.type;this.offset.copy(a.offset);this.repeat.copy(a.repeat);this.generateMipmaps=a.generateMipmaps;this.premultiplyAlpha=a.premultiplyAlpha;this.flipY=a.flipY; +this.unpackAlignment=a.unpackAlignment;this.encoding=a.encoding;return this},toJSON:function(a){if(void 0!==a.textures[this.uuid])return a.textures[this.uuid];var b={metadata:{version:4.4,type:"Texture",generator:"Texture.toJSON"},uuid:this.uuid,name:this.name,mapping:this.mapping,repeat:[this.repeat.x,this.repeat.y],offset:[this.offset.x,this.offset.y],wrap:[this.wrapS,this.wrapT],minFilter:this.minFilter,magFilter:this.magFilter,anisotropy:this.anisotropy,flipY:this.flipY};if(void 0!==this.image){var c= +this.image;void 0===c.uuid&&(c.uuid=Q.generateUUID());if(void 0===a.images[c.uuid]){var d=a.images,e=c.uuid,f=c.uuid,g;void 0!==c.toDataURL?g=c:(g=document.createElementNS("http://www.w3.org/1999/xhtml","canvas"),g.width=c.width,g.height=c.height,g.getContext("2d").drawImage(c,0,0,c.width,c.height));g=2048a.x||1a.x?0:1;break;case 1002:a.x=1===Math.abs(Math.floor(a.x)%2)?Math.ceil(a.x)-a.x:a.x-Math.floor(a.x)}if(0>a.y||1a.y?0:1;break;case 1002:a.y=1===Math.abs(Math.floor(a.y)%2)?Math.ceil(a.y)-a.y:a.y-Math.floor(a.y)}this.flipY&&(a.y=1-a.y)}}};Object.assign(ea.prototype, +oa.prototype);ga.prototype={constructor:ga,isVector4:!0,set:function(a,b,c,d){this.x=a;this.y=b;this.z=c;this.w=d;return this},setScalar:function(a){this.w=this.z=this.y=this.x=a;return this},setX:function(a){this.x=a;return this},setY:function(a){this.y=a;return this},setZ:function(a){this.z=a;return this},setW:function(a){this.w=a;return this},setComponent:function(a,b){switch(a){case 0:this.x=b;break;case 1:this.y=b;break;case 2:this.z=b;break;case 3:this.w=b;break;default:throw Error("index is out of range: "+ +a);}return this},getComponent:function(a){switch(a){case 0:return this.x;case 1:return this.y;case 2:return this.z;case 3:return this.w;default:throw Error("index is out of range: "+a);}},clone:function(){return new this.constructor(this.x,this.y,this.z,this.w)},copy:function(a){this.x=a.x;this.y=a.y;this.z=a.z;this.w=void 0!==a.w?a.w:1;return this},add:function(a,b){if(void 0!==b)return console.warn("THREE.Vector4: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(a, +b);this.x+=a.x;this.y+=a.y;this.z+=a.z;this.w+=a.w;return this},addScalar:function(a){this.x+=a;this.y+=a;this.z+=a;this.w+=a;return this},addVectors:function(a,b){this.x=a.x+b.x;this.y=a.y+b.y;this.z=a.z+b.z;this.w=a.w+b.w;return this},addScaledVector:function(a,b){this.x+=a.x*b;this.y+=a.y*b;this.z+=a.z*b;this.w+=a.w*b;return this},sub:function(a,b){if(void 0!==b)return console.warn("THREE.Vector4: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(a,b);this.x-= +a.x;this.y-=a.y;this.z-=a.z;this.w-=a.w;return this},subScalar:function(a){this.x-=a;this.y-=a;this.z-=a;this.w-=a;return this},subVectors:function(a,b){this.x=a.x-b.x;this.y=a.y-b.y;this.z=a.z-b.z;this.w=a.w-b.w;return this},multiplyScalar:function(a){isFinite(a)?(this.x*=a,this.y*=a,this.z*=a,this.w*=a):this.w=this.z=this.y=this.x=0;return this},applyMatrix4:function(a){var b=this.x,c=this.y,d=this.z,e=this.w;a=a.elements;this.x=a[0]*b+a[4]*c+a[8]*d+a[12]*e;this.y=a[1]*b+a[5]*c+a[9]*d+a[13]*e;this.z= +a[2]*b+a[6]*c+a[10]*d+a[14]*e;this.w=a[3]*b+a[7]*c+a[11]*d+a[15]*e;return this},divideScalar:function(a){return this.multiplyScalar(1/a)},setAxisAngleFromQuaternion:function(a){this.w=2*Math.acos(a.w);var b=Math.sqrt(1-a.w*a.w);1E-4>b?(this.x=1,this.z=this.y=0):(this.x=a.x/b,this.y=a.y/b,this.z=a.z/b);return this},setAxisAngleFromRotationMatrix:function(a){var b,c,d;a=a.elements;var e=a[0];d=a[4];var f=a[8],g=a[1],h=a[5],k=a[9];c=a[2];b=a[6];var m=a[10];if(.01>Math.abs(d-g)&&.01>Math.abs(f-c)&&.01> +Math.abs(k-b)){if(.1>Math.abs(d+g)&&.1>Math.abs(f+c)&&.1>Math.abs(k+b)&&.1>Math.abs(e+h+m-3))return this.set(1,0,0,0),this;a=Math.PI;e=(e+1)/2;h=(h+1)/2;m=(m+1)/2;d=(d+g)/4;f=(f+c)/4;k=(k+b)/4;e>h&&e>m?.01>e?(b=0,d=c=.707106781):(b=Math.sqrt(e),c=d/b,d=f/b):h>m?.01>h?(b=.707106781,c=0,d=.707106781):(c=Math.sqrt(h),b=d/c,d=k/c):.01>m?(c=b=.707106781,d=0):(d=Math.sqrt(m),b=f/d,c=k/d);this.set(b,c,d,a);return this}a=Math.sqrt((b-k)*(b-k)+(f-c)*(f-c)+(g-d)*(g-d));.001>Math.abs(a)&&(a=1);this.x=(b-k)/ +a;this.y=(f-c)/a;this.z=(g-d)/a;this.w=Math.acos((e+h+m-1)/2);return this},min:function(a){this.x=Math.min(this.x,a.x);this.y=Math.min(this.y,a.y);this.z=Math.min(this.z,a.z);this.w=Math.min(this.w,a.w);return this},max:function(a){this.x=Math.max(this.x,a.x);this.y=Math.max(this.y,a.y);this.z=Math.max(this.z,a.z);this.w=Math.max(this.w,a.w);return this},clamp:function(a,b){this.x=Math.max(a.x,Math.min(b.x,this.x));this.y=Math.max(a.y,Math.min(b.y,this.y));this.z=Math.max(a.z,Math.min(b.z,this.z)); +this.w=Math.max(a.w,Math.min(b.w,this.w));return this},clampScalar:function(){var a,b;return function(c,d){void 0===a&&(a=new ga,b=new ga);a.set(c,c,c,c);b.set(d,d,d,d);return this.clamp(a,b)}}(),floor:function(){this.x=Math.floor(this.x);this.y=Math.floor(this.y);this.z=Math.floor(this.z);this.w=Math.floor(this.w);return this},ceil:function(){this.x=Math.ceil(this.x);this.y=Math.ceil(this.y);this.z=Math.ceil(this.z);this.w=Math.ceil(this.w);return this},round:function(){this.x=Math.round(this.x); +this.y=Math.round(this.y);this.z=Math.round(this.z);this.w=Math.round(this.w);return this},roundToZero:function(){this.x=0>this.x?Math.ceil(this.x):Math.floor(this.x);this.y=0>this.y?Math.ceil(this.y):Math.floor(this.y);this.z=0>this.z?Math.ceil(this.z):Math.floor(this.z);this.w=0>this.w?Math.ceil(this.w):Math.floor(this.w);return this},negate:function(){this.x=-this.x;this.y=-this.y;this.z=-this.z;this.w=-this.w;return this},dot:function(a){return this.x*a.x+this.y*a.y+this.z*a.z+this.w*a.w},lengthSq:function(){return this.x* +this.x+this.y*this.y+this.z*this.z+this.w*this.w},length:function(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z+this.w*this.w)},lengthManhattan:function(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)+Math.abs(this.w)},normalize:function(){return this.divideScalar(this.length())},setLength:function(a){return this.multiplyScalar(a/this.length())},lerp:function(a,b){this.x+=(a.x-this.x)*b;this.y+=(a.y-this.y)*b;this.z+=(a.z-this.z)*b;this.w+=(a.w-this.w)*b;return this},lerpVectors:function(a, +b,c){return this.subVectors(b,a).multiplyScalar(c).add(a)},equals:function(a){return a.x===this.x&&a.y===this.y&&a.z===this.z&&a.w===this.w},fromArray:function(a,b){void 0===b&&(b=0);this.x=a[b];this.y=a[b+1];this.z=a[b+2];this.w=a[b+3];return this},toArray:function(a,b){void 0===a&&(a=[]);void 0===b&&(b=0);a[b]=this.x;a[b+1]=this.y;a[b+2]=this.z;a[b+3]=this.w;return a},fromAttribute:function(a,b,c){void 0!==c&&console.warn("THREE.Vector4: offset has been removed from .fromAttribute().");this.x=a.getX(b); +this.y=a.getY(b);this.z=a.getZ(b);this.w=a.getW(b);return this}};Object.assign(Db.prototype,oa.prototype,{isWebGLRenderTarget:!0,setSize:function(a,b){if(this.width!==a||this.height!==b)this.width=a,this.height=b,this.dispose();this.viewport.set(0,0,a,b);this.scissor.set(0,0,a,b)},clone:function(){return(new this.constructor).copy(this)},copy:function(a){this.width=a.width;this.height=a.height;this.viewport.copy(a.viewport);this.texture=a.texture.clone();this.depthBuffer=a.depthBuffer;this.stencilBuffer= +a.stencilBuffer;this.depthTexture=a.depthTexture;return this},dispose:function(){this.dispatchEvent({type:"dispose"})}});Eb.prototype=Object.create(Db.prototype);Eb.prototype.constructor=Eb;Eb.prototype.isWebGLRenderTargetCube=!0;da.prototype={constructor:da,get x(){return this._x},set x(a){this._x=a;this.onChangeCallback()},get y(){return this._y},set y(a){this._y=a;this.onChangeCallback()},get z(){return this._z},set z(a){this._z=a;this.onChangeCallback()},get w(){return this._w},set w(a){this._w= +a;this.onChangeCallback()},set:function(a,b,c,d){this._x=a;this._y=b;this._z=c;this._w=d;this.onChangeCallback();return this},clone:function(){return new this.constructor(this._x,this._y,this._z,this._w)},copy:function(a){this._x=a.x;this._y=a.y;this._z=a.z;this._w=a.w;this.onChangeCallback();return this},setFromEuler:function(a,b){if(!1===(a&&a.isEuler))throw Error("THREE.Quaternion: .setFromEuler() now expects an Euler rotation rather than a Vector3 and order.");var c=Math.cos(a._x/2),d=Math.cos(a._y/ +2),e=Math.cos(a._z/2),f=Math.sin(a._x/2),g=Math.sin(a._y/2),h=Math.sin(a._z/2),k=a.order;"XYZ"===k?(this._x=f*d*e+c*g*h,this._y=c*g*e-f*d*h,this._z=c*d*h+f*g*e,this._w=c*d*e-f*g*h):"YXZ"===k?(this._x=f*d*e+c*g*h,this._y=c*g*e-f*d*h,this._z=c*d*h-f*g*e,this._w=c*d*e+f*g*h):"ZXY"===k?(this._x=f*d*e-c*g*h,this._y=c*g*e+f*d*h,this._z=c*d*h+f*g*e,this._w=c*d*e-f*g*h):"ZYX"===k?(this._x=f*d*e-c*g*h,this._y=c*g*e+f*d*h,this._z=c*d*h-f*g*e,this._w=c*d*e+f*g*h):"YZX"===k?(this._x=f*d*e+c*g*h,this._y=c*g*e+ +f*d*h,this._z=c*d*h-f*g*e,this._w=c*d*e-f*g*h):"XZY"===k&&(this._x=f*d*e-c*g*h,this._y=c*g*e-f*d*h,this._z=c*d*h+f*g*e,this._w=c*d*e+f*g*h);if(!1!==b)this.onChangeCallback();return this},setFromAxisAngle:function(a,b){var c=b/2,d=Math.sin(c);this._x=a.x*d;this._y=a.y*d;this._z=a.z*d;this._w=Math.cos(c);this.onChangeCallback();return this},setFromRotationMatrix:function(a){var b=a.elements,c=b[0];a=b[4];var d=b[8],e=b[1],f=b[5],g=b[9],h=b[2],k=b[6],b=b[10],m=c+f+b;0f&&c>b?(c=2*Math.sqrt(1+c-f-b),this._w=(k-g)/c,this._x=.25*c,this._y=(a+e)/c,this._z=(d+h)/c):f>b?(c=2*Math.sqrt(1+f-c-b),this._w=(d-h)/c,this._x=(a+e)/c,this._y=.25*c,this._z=(g+k)/c):(c=2*Math.sqrt(1+b-c-f),this._w=(e-a)/c,this._x=(d+h)/c,this._y=(g+k)/c,this._z=.25*c);this.onChangeCallback();return this},setFromUnitVectors:function(){var a,b;return function(c,d){void 0===a&&(a=new q);b=c.dot(d)+1;1E-6>b?(b=0,Math.abs(c.x)>Math.abs(c.z)?a.set(-c.y, +c.x,0):a.set(0,-c.z,c.y)):a.crossVectors(c,d);this._x=a.x;this._y=a.y;this._z=a.z;this._w=b;return this.normalize()}}(),inverse:function(){return this.conjugate().normalize()},conjugate:function(){this._x*=-1;this._y*=-1;this._z*=-1;this.onChangeCallback();return this},dot:function(a){return this._x*a._x+this._y*a._y+this._z*a._z+this._w*a._w},lengthSq:function(){return this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w},length:function(){return Math.sqrt(this._x*this._x+this._y*this._y+ +this._z*this._z+this._w*this._w)},normalize:function(){var a=this.length();0===a?(this._z=this._y=this._x=0,this._w=1):(a=1/a,this._x*=a,this._y*=a,this._z*=a,this._w*=a);this.onChangeCallback();return this},multiply:function(a,b){return void 0!==b?(console.warn("THREE.Quaternion: .multiply() now only accepts one argument. Use .multiplyQuaternions( a, b ) instead."),this.multiplyQuaternions(a,b)):this.multiplyQuaternions(this,a)},premultiply:function(a){return this.multiplyQuaternions(a,this)},multiplyQuaternions:function(a, +b){var c=a._x,d=a._y,e=a._z,f=a._w,g=b._x,h=b._y,k=b._z,m=b._w;this._x=c*m+f*g+d*k-e*h;this._y=d*m+f*h+e*g-c*k;this._z=e*m+f*k+c*h-d*g;this._w=f*m-c*g-d*h-e*k;this.onChangeCallback();return this},slerp:function(a,b){if(0===b)return this;if(1===b)return this.copy(a);var c=this._x,d=this._y,e=this._z,f=this._w,g=f*a._w+c*a._x+d*a._y+e*a._z;0>g?(this._w=-a._w,this._x=-a._x,this._y=-a._y,this._z=-a._z,g=-g):this.copy(a);if(1<=g)return this._w=f,this._x=c,this._y=d,this._z=e,this;var h=Math.sqrt(1-g*g); +if(.001>Math.abs(h))return this._w=.5*(f+this._w),this._x=.5*(c+this._x),this._y=.5*(d+this._y),this._z=.5*(e+this._z),this;var k=Math.atan2(h,g),g=Math.sin((1-b)*k)/h,h=Math.sin(b*k)/h;this._w=f*g+this._w*h;this._x=c*g+this._x*h;this._y=d*g+this._y*h;this._z=e*g+this._z*h;this.onChangeCallback();return this},equals:function(a){return a._x===this._x&&a._y===this._y&&a._z===this._z&&a._w===this._w},fromArray:function(a,b){void 0===b&&(b=0);this._x=a[b];this._y=a[b+1];this._z=a[b+2];this._w=a[b+3]; +this.onChangeCallback();return this},toArray:function(a,b){void 0===a&&(a=[]);void 0===b&&(b=0);a[b]=this._x;a[b+1]=this._y;a[b+2]=this._z;a[b+3]=this._w;return a},onChange:function(a){this.onChangeCallback=a;return this},onChangeCallback:function(){}};Object.assign(da,{slerp:function(a,b,c,d){return c.copy(a).slerp(b,d)},slerpFlat:function(a,b,c,d,e,f,g){var h=c[d+0],k=c[d+1],m=c[d+2];c=c[d+3];d=e[f+0];var l=e[f+1],p=e[f+2];e=e[f+3];if(c!==e||h!==d||k!==l||m!==p){f=1-g;var n=h*d+k*l+m*p+c*e,r=0<= +n?1:-1,w=1-n*n;w>Number.EPSILON&&(w=Math.sqrt(w),n=Math.atan2(w,n*r),f=Math.sin(f*n)/w,g=Math.sin(g*n)/w);r*=g;h=h*f+d*r;k=k*f+l*r;m=m*f+p*r;c=c*f+e*r;f===1-g&&(g=1/Math.sqrt(h*h+k*k+m*m+c*c),h*=g,k*=g,m*=g,c*=g)}a[b]=h;a[b+1]=k;a[b+2]=m;a[b+3]=c}});q.prototype={constructor:q,isVector3:!0,set:function(a,b,c){this.x=a;this.y=b;this.z=c;return this},setScalar:function(a){this.z=this.y=this.x=a;return this},setX:function(a){this.x=a;return this},setY:function(a){this.y=a;return this},setZ:function(a){this.z= +a;return this},setComponent:function(a,b){switch(a){case 0:this.x=b;break;case 1:this.y=b;break;case 2:this.z=b;break;default:throw Error("index is out of range: "+a);}return this},getComponent:function(a){switch(a){case 0:return this.x;case 1:return this.y;case 2:return this.z;default:throw Error("index is out of range: "+a);}},clone:function(){return new this.constructor(this.x,this.y,this.z)},copy:function(a){this.x=a.x;this.y=a.y;this.z=a.z;return this},add:function(a,b){if(void 0!==b)return console.warn("THREE.Vector3: .add() now only accepts one argument. Use .addVectors( a, b ) instead."), +this.addVectors(a,b);this.x+=a.x;this.y+=a.y;this.z+=a.z;return this},addScalar:function(a){this.x+=a;this.y+=a;this.z+=a;return this},addVectors:function(a,b){this.x=a.x+b.x;this.y=a.y+b.y;this.z=a.z+b.z;return this},addScaledVector:function(a,b){this.x+=a.x*b;this.y+=a.y*b;this.z+=a.z*b;return this},sub:function(a,b){if(void 0!==b)return console.warn("THREE.Vector3: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(a,b);this.x-=a.x;this.y-=a.y;this.z-=a.z; +return this},subScalar:function(a){this.x-=a;this.y-=a;this.z-=a;return this},subVectors:function(a,b){this.x=a.x-b.x;this.y=a.y-b.y;this.z=a.z-b.z;return this},multiply:function(a,b){if(void 0!==b)return console.warn("THREE.Vector3: .multiply() now only accepts one argument. Use .multiplyVectors( a, b ) instead."),this.multiplyVectors(a,b);this.x*=a.x;this.y*=a.y;this.z*=a.z;return this},multiplyScalar:function(a){isFinite(a)?(this.x*=a,this.y*=a,this.z*=a):this.z=this.y=this.x=0;return this},multiplyVectors:function(a, +b){this.x=a.x*b.x;this.y=a.y*b.y;this.z=a.z*b.z;return this},applyEuler:function(){var a;return function(b){!1===(b&&b.isEuler)&&console.error("THREE.Vector3: .applyEuler() now expects an Euler rotation rather than a Vector3 and order.");void 0===a&&(a=new da);return this.applyQuaternion(a.setFromEuler(b))}}(),applyAxisAngle:function(){var a;return function(b,c){void 0===a&&(a=new da);return this.applyQuaternion(a.setFromAxisAngle(b,c))}}(),applyMatrix3:function(a){var b=this.x,c=this.y,d=this.z; +a=a.elements;this.x=a[0]*b+a[3]*c+a[6]*d;this.y=a[1]*b+a[4]*c+a[7]*d;this.z=a[2]*b+a[5]*c+a[8]*d;return this},applyMatrix4:function(a){var b=this.x,c=this.y,d=this.z;a=a.elements;this.x=a[0]*b+a[4]*c+a[8]*d+a[12];this.y=a[1]*b+a[5]*c+a[9]*d+a[13];this.z=a[2]*b+a[6]*c+a[10]*d+a[14];return this},applyProjection:function(a){var b=this.x,c=this.y,d=this.z;a=a.elements;var e=1/(a[3]*b+a[7]*c+a[11]*d+a[15]);this.x=(a[0]*b+a[4]*c+a[8]*d+a[12])*e;this.y=(a[1]*b+a[5]*c+a[9]*d+a[13])*e;this.z=(a[2]*b+a[6]* +c+a[10]*d+a[14])*e;return this},applyQuaternion:function(a){var b=this.x,c=this.y,d=this.z,e=a.x,f=a.y,g=a.z;a=a.w;var h=a*b+f*d-g*c,k=a*c+g*b-e*d,m=a*d+e*c-f*b,b=-e*b-f*c-g*d;this.x=h*a+b*-e+k*-g-m*-f;this.y=k*a+b*-f+m*-e-h*-g;this.z=m*a+b*-g+h*-f-k*-e;return this},project:function(){var a;return function(b){void 0===a&&(a=new H);a.multiplyMatrices(b.projectionMatrix,a.getInverse(b.matrixWorld));return this.applyProjection(a)}}(),unproject:function(){var a;return function(b){void 0===a&&(a=new H); +a.multiplyMatrices(b.matrixWorld,a.getInverse(b.projectionMatrix));return this.applyProjection(a)}}(),transformDirection:function(a){var b=this.x,c=this.y,d=this.z;a=a.elements;this.x=a[0]*b+a[4]*c+a[8]*d;this.y=a[1]*b+a[5]*c+a[9]*d;this.z=a[2]*b+a[6]*c+a[10]*d;return this.normalize()},divide:function(a){this.x/=a.x;this.y/=a.y;this.z/=a.z;return this},divideScalar:function(a){return this.multiplyScalar(1/a)},min:function(a){this.x=Math.min(this.x,a.x);this.y=Math.min(this.y,a.y);this.z=Math.min(this.z, +a.z);return this},max:function(a){this.x=Math.max(this.x,a.x);this.y=Math.max(this.y,a.y);this.z=Math.max(this.z,a.z);return this},clamp:function(a,b){this.x=Math.max(a.x,Math.min(b.x,this.x));this.y=Math.max(a.y,Math.min(b.y,this.y));this.z=Math.max(a.z,Math.min(b.z,this.z));return this},clampScalar:function(){var a,b;return function(c,d){void 0===a&&(a=new q,b=new q);a.set(c,c,c);b.set(d,d,d);return this.clamp(a,b)}}(),clampLength:function(a,b){var c=this.length();return this.multiplyScalar(Math.max(a, +Math.min(b,c))/c)},floor:function(){this.x=Math.floor(this.x);this.y=Math.floor(this.y);this.z=Math.floor(this.z);return this},ceil:function(){this.x=Math.ceil(this.x);this.y=Math.ceil(this.y);this.z=Math.ceil(this.z);return this},round:function(){this.x=Math.round(this.x);this.y=Math.round(this.y);this.z=Math.round(this.z);return this},roundToZero:function(){this.x=0>this.x?Math.ceil(this.x):Math.floor(this.x);this.y=0>this.y?Math.ceil(this.y):Math.floor(this.y);this.z=0>this.z?Math.ceil(this.z): +Math.floor(this.z);return this},negate:function(){this.x=-this.x;this.y=-this.y;this.z=-this.z;return this},dot:function(a){return this.x*a.x+this.y*a.y+this.z*a.z},lengthSq:function(){return this.x*this.x+this.y*this.y+this.z*this.z},length:function(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z)},lengthManhattan:function(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)},normalize:function(){return this.divideScalar(this.length())},setLength:function(a){return this.multiplyScalar(a/ +this.length())},lerp:function(a,b){this.x+=(a.x-this.x)*b;this.y+=(a.y-this.y)*b;this.z+=(a.z-this.z)*b;return this},lerpVectors:function(a,b,c){return this.subVectors(b,a).multiplyScalar(c).add(a)},cross:function(a,b){if(void 0!==b)return console.warn("THREE.Vector3: .cross() now only accepts one argument. Use .crossVectors( a, b ) instead."),this.crossVectors(a,b);var c=this.x,d=this.y,e=this.z;this.x=d*a.z-e*a.y;this.y=e*a.x-c*a.z;this.z=c*a.y-d*a.x;return this},crossVectors:function(a,b){var c= +a.x,d=a.y,e=a.z,f=b.x,g=b.y,h=b.z;this.x=d*h-e*g;this.y=e*f-c*h;this.z=c*g-d*f;return this},projectOnVector:function(a){var b=a.dot(this)/a.lengthSq();return this.copy(a).multiplyScalar(b)},projectOnPlane:function(){var a;return function(b){void 0===a&&(a=new q);a.copy(this).projectOnVector(b);return this.sub(a)}}(),reflect:function(){var a;return function(b){void 0===a&&(a=new q);return this.sub(a.copy(b).multiplyScalar(2*this.dot(b)))}}(),angleTo:function(a){a=this.dot(a)/Math.sqrt(this.lengthSq()* +a.lengthSq());return Math.acos(Q.clamp(a,-1,1))},distanceTo:function(a){return Math.sqrt(this.distanceToSquared(a))},distanceToSquared:function(a){var b=this.x-a.x,c=this.y-a.y;a=this.z-a.z;return b*b+c*c+a*a},distanceToManhattan:function(a){return Math.abs(this.x-a.x)+Math.abs(this.y-a.y)+Math.abs(this.z-a.z)},setFromSpherical:function(a){var b=Math.sin(a.phi)*a.radius;this.x=b*Math.sin(a.theta);this.y=Math.cos(a.phi)*a.radius;this.z=b*Math.cos(a.theta);return this},setFromCylindrical:function(a){this.x= +a.radius*Math.sin(a.theta);this.y=a.y;this.z=a.radius*Math.cos(a.theta);return this},setFromMatrixPosition:function(a){return this.setFromMatrixColumn(a,3)},setFromMatrixScale:function(a){var b=this.setFromMatrixColumn(a,0).length(),c=this.setFromMatrixColumn(a,1).length();a=this.setFromMatrixColumn(a,2).length();this.x=b;this.y=c;this.z=a;return this},setFromMatrixColumn:function(a,b){if("number"===typeof a){console.warn("THREE.Vector3: setFromMatrixColumn now expects ( matrix, index ).");var c= +a;a=b;b=c}return this.fromArray(a.elements,4*b)},equals:function(a){return a.x===this.x&&a.y===this.y&&a.z===this.z},fromArray:function(a,b){void 0===b&&(b=0);this.x=a[b];this.y=a[b+1];this.z=a[b+2];return this},toArray:function(a,b){void 0===a&&(a=[]);void 0===b&&(b=0);a[b]=this.x;a[b+1]=this.y;a[b+2]=this.z;return a},fromAttribute:function(a,b,c){void 0!==c&&console.warn("THREE.Vector3: offset has been removed from .fromAttribute().");this.x=a.getX(b);this.y=a.getY(b);this.z=a.getZ(b);return this}}; +H.prototype={constructor:H,isMatrix4:!0,set:function(a,b,c,d,e,f,g,h,k,m,l,p,n,r,w,u){var q=this.elements;q[0]=a;q[4]=b;q[8]=c;q[12]=d;q[1]=e;q[5]=f;q[9]=g;q[13]=h;q[2]=k;q[6]=m;q[10]=l;q[14]=p;q[3]=n;q[7]=r;q[11]=w;q[15]=u;return this},identity:function(){this.set(1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1);return this},clone:function(){return(new H).fromArray(this.elements)},copy:function(a){this.elements.set(a.elements);return this},copyPosition:function(a){var b=this.elements;a=a.elements;b[12]=a[12];b[13]= +a[13];b[14]=a[14];return this},extractBasis:function(a,b,c){a.setFromMatrixColumn(this,0);b.setFromMatrixColumn(this,1);c.setFromMatrixColumn(this,2);return this},makeBasis:function(a,b,c){this.set(a.x,b.x,c.x,0,a.y,b.y,c.y,0,a.z,b.z,c.z,0,0,0,0,1);return this},extractRotation:function(){var a;return function(b){void 0===a&&(a=new q);var c=this.elements,d=b.elements,e=1/a.setFromMatrixColumn(b,0).length(),f=1/a.setFromMatrixColumn(b,1).length();b=1/a.setFromMatrixColumn(b,2).length();c[0]=d[0]*e; +c[1]=d[1]*e;c[2]=d[2]*e;c[4]=d[4]*f;c[5]=d[5]*f;c[6]=d[6]*f;c[8]=d[8]*b;c[9]=d[9]*b;c[10]=d[10]*b;return this}}(),makeRotationFromEuler:function(a){!1===(a&&a.isEuler)&&console.error("THREE.Matrix: .makeRotationFromEuler() now expects a Euler rotation rather than a Vector3 and order.");var b=this.elements,c=a.x,d=a.y,e=a.z,f=Math.cos(c),c=Math.sin(c),g=Math.cos(d),d=Math.sin(d),h=Math.cos(e),e=Math.sin(e);if("XYZ"===a.order){a=f*h;var k=f*e,m=c*h,l=c*e;b[0]=g*h;b[4]=-g*e;b[8]=d;b[1]=k+m*d;b[5]=a- +l*d;b[9]=-c*g;b[2]=l-a*d;b[6]=m+k*d;b[10]=f*g}else"YXZ"===a.order?(a=g*h,k=g*e,m=d*h,l=d*e,b[0]=a+l*c,b[4]=m*c-k,b[8]=f*d,b[1]=f*e,b[5]=f*h,b[9]=-c,b[2]=k*c-m,b[6]=l+a*c,b[10]=f*g):"ZXY"===a.order?(a=g*h,k=g*e,m=d*h,l=d*e,b[0]=a-l*c,b[4]=-f*e,b[8]=m+k*c,b[1]=k+m*c,b[5]=f*h,b[9]=l-a*c,b[2]=-f*d,b[6]=c,b[10]=f*g):"ZYX"===a.order?(a=f*h,k=f*e,m=c*h,l=c*e,b[0]=g*h,b[4]=m*d-k,b[8]=a*d+l,b[1]=g*e,b[5]=l*d+a,b[9]=k*d-m,b[2]=-d,b[6]=c*g,b[10]=f*g):"YZX"===a.order?(a=f*g,k=f*d,m=c*g,l=c*d,b[0]=g*h,b[4]=l- +a*e,b[8]=m*e+k,b[1]=e,b[5]=f*h,b[9]=-c*h,b[2]=-d*h,b[6]=k*e+m,b[10]=a-l*e):"XZY"===a.order&&(a=f*g,k=f*d,m=c*g,l=c*d,b[0]=g*h,b[4]=-e,b[8]=d*h,b[1]=a*e+l,b[5]=f*h,b[9]=k*e-m,b[2]=m*e-k,b[6]=c*h,b[10]=l*e+a);b[3]=0;b[7]=0;b[11]=0;b[12]=0;b[13]=0;b[14]=0;b[15]=1;return this},makeRotationFromQuaternion:function(a){var b=this.elements,c=a.x,d=a.y,e=a.z,f=a.w,g=c+c,h=d+d,k=e+e;a=c*g;var m=c*h,c=c*k,l=d*h,d=d*k,e=e*k,g=f*g,h=f*h,f=f*k;b[0]=1-(l+e);b[4]=m-f;b[8]=c+h;b[1]=m+f;b[5]=1-(a+e);b[9]=d-g;b[2]=c- +h;b[6]=d+g;b[10]=1-(a+l);b[3]=0;b[7]=0;b[11]=0;b[12]=0;b[13]=0;b[14]=0;b[15]=1;return this},lookAt:function(){var a,b,c;return function(d,e,f){void 0===a&&(a=new q,b=new q,c=new q);var g=this.elements;c.subVectors(d,e).normalize();0===c.lengthSq()&&(c.z=1);a.crossVectors(f,c).normalize();0===a.lengthSq()&&(c.z+=1E-4,a.crossVectors(f,c).normalize());b.crossVectors(c,a);g[0]=a.x;g[4]=b.x;g[8]=c.x;g[1]=a.y;g[5]=b.y;g[9]=c.y;g[2]=a.z;g[6]=b.z;g[10]=c.z;return this}}(),multiply:function(a,b){return void 0!== +b?(console.warn("THREE.Matrix4: .multiply() now only accepts one argument. Use .multiplyMatrices( a, b ) instead."),this.multiplyMatrices(a,b)):this.multiplyMatrices(this,a)},premultiply:function(a){return this.multiplyMatrices(a,this)},multiplyMatrices:function(a,b){var c=a.elements,d=b.elements,e=this.elements,f=c[0],g=c[4],h=c[8],k=c[12],m=c[1],l=c[5],p=c[9],n=c[13],r=c[2],w=c[6],u=c[10],q=c[14],t=c[3],v=c[7],M=c[11],c=c[15],z=d[0],A=d[4],I=d[8],E=d[12],K=d[1],y=d[5],J=d[9],C=d[13],D=d[2],G=d[6], +H=d[10],O=d[14],P=d[3],R=d[7],T=d[11],d=d[15];e[0]=f*z+g*K+h*D+k*P;e[4]=f*A+g*y+h*G+k*R;e[8]=f*I+g*J+h*H+k*T;e[12]=f*E+g*C+h*O+k*d;e[1]=m*z+l*K+p*D+n*P;e[5]=m*A+l*y+p*G+n*R;e[9]=m*I+l*J+p*H+n*T;e[13]=m*E+l*C+p*O+n*d;e[2]=r*z+w*K+u*D+q*P;e[6]=r*A+w*y+u*G+q*R;e[10]=r*I+w*J+u*H+q*T;e[14]=r*E+w*C+u*O+q*d;e[3]=t*z+v*K+M*D+c*P;e[7]=t*A+v*y+M*G+c*R;e[11]=t*I+v*J+M*H+c*T;e[15]=t*E+v*C+M*O+c*d;return this},multiplyToArray:function(a,b,c){var d=this.elements;this.multiplyMatrices(a,b);c[0]=d[0];c[1]=d[1];c[2]= +d[2];c[3]=d[3];c[4]=d[4];c[5]=d[5];c[6]=d[6];c[7]=d[7];c[8]=d[8];c[9]=d[9];c[10]=d[10];c[11]=d[11];c[12]=d[12];c[13]=d[13];c[14]=d[14];c[15]=d[15];return this},multiplyScalar:function(a){var b=this.elements;b[0]*=a;b[4]*=a;b[8]*=a;b[12]*=a;b[1]*=a;b[5]*=a;b[9]*=a;b[13]*=a;b[2]*=a;b[6]*=a;b[10]*=a;b[14]*=a;b[3]*=a;b[7]*=a;b[11]*=a;b[15]*=a;return this},applyToVector3Array:function(){var a;return function(b,c,d){void 0===a&&(a=new q);void 0===c&&(c=0);void 0===d&&(d=b.length);for(var e=0;ethis.determinant()&&(g=-g);c.x= +f[12];c.y=f[13];c.z=f[14];b.elements.set(this.elements);c=1/g;var f=1/h,m=1/k;b.elements[0]*=c;b.elements[1]*=c;b.elements[2]*=c;b.elements[4]*=f;b.elements[5]*=f;b.elements[6]*=f;b.elements[8]*=m;b.elements[9]*=m;b.elements[10]*=m;d.setFromRotationMatrix(b);e.x=g;e.y=h;e.z=k;return this}}(),makeFrustum:function(a,b,c,d,e,f){var g=this.elements;g[0]=2*e/(b-a);g[4]=0;g[8]=(b+a)/(b-a);g[12]=0;g[1]=0;g[5]=2*e/(d-c);g[9]=(d+c)/(d-c);g[13]=0;g[2]=0;g[6]=0;g[10]=-(f+e)/(f-e);g[14]=-2*f*e/(f-e);g[3]=0;g[7]= +0;g[11]=-1;g[15]=0;return this},makePerspective:function(a,b,c,d){a=c*Math.tan(Q.DEG2RAD*a*.5);var e=-a;return this.makeFrustum(e*b,a*b,e,a,c,d)},makeOrthographic:function(a,b,c,d,e,f){var g=this.elements,h=1/(b-a),k=1/(c-d),m=1/(f-e);g[0]=2*h;g[4]=0;g[8]=0;g[12]=-((b+a)*h);g[1]=0;g[5]=2*k;g[9]=0;g[13]=-((c+d)*k);g[2]=0;g[6]=0;g[10]=-2*m;g[14]=-((f+e)*m);g[3]=0;g[7]=0;g[11]=0;g[15]=1;return this},equals:function(a){var b=this.elements;a=a.elements;for(var c=0;16>c;c++)if(b[c]!==a[c])return!1;return!0}, +fromArray:function(a,b){void 0===b&&(b=0);for(var c=0;16>c;c++)this.elements[c]=a[c+b];return this},toArray:function(a,b){void 0===a&&(a=[]);void 0===b&&(b=0);var c=this.elements;a[b]=c[0];a[b+1]=c[1];a[b+2]=c[2];a[b+3]=c[3];a[b+4]=c[4];a[b+5]=c[5];a[b+6]=c[6];a[b+7]=c[7];a[b+8]=c[8];a[b+9]=c[9];a[b+10]=c[10];a[b+11]=c[11];a[b+12]=c[12];a[b+13]=c[13];a[b+14]=c[14];a[b+15]=c[15];return a}};Za.prototype=Object.create(ea.prototype);Za.prototype.constructor=Za;Za.prototype.isCubeTexture=!0;Object.defineProperty(Za.prototype, +"images",{get:function(){return this.image},set:function(a){this.image=a}});var se=new ea,te=new Za,pe=[],re=[];xe.prototype.setValue=function(a,b){for(var c=this.seq,d=0,e=c.length;d!==e;++d){var f=c[d];f.setValue(a,b[f.id])}};var Id=/([\w\d_]+)(\])?(\[|\.)?/g;$a.prototype.setValue=function(a,b,c){b=this.map[b];void 0!==b&&b.setValue(a,c,this.renderer)};$a.prototype.set=function(a,b,c){var d=this.map[c];void 0!==d&&d.setValue(a,b[c],this.renderer)};$a.prototype.setOptional=function(a,b,c){b=b[c]; +void 0!==b&&this.setValue(a,c,b)};$a.upload=function(a,b,c,d){for(var e=0,f=b.length;e!==f;++e){var g=b[e],h=c[g.id];!1!==h.needsUpdate&&g.setValue(a,h.value,d)}};$a.seqWithValue=function(a,b){for(var c=[],d=0,e=a.length;d!==e;++d){var f=a[d];f.id in b&&c.push(f)}return c};var Ja={merge:function(a){for(var b={},c=0;c 0.0 ) {\n#if defined ( PHYSICALLY_CORRECT_LIGHTS )\n\t\t\tfloat distanceFalloff = 1.0 / max( pow( lightDistance, decayExponent ), 0.01 );\n\t\t\tfloat maxDistanceCutoffFactor = pow2( saturate( 1.0 - pow4( lightDistance / cutoffDistance ) ) );\n\t\t\treturn distanceFalloff * maxDistanceCutoffFactor;\n#else\n\t\t\treturn pow( saturate( -lightDistance / cutoffDistance + 1.0 ), decayExponent );\n#endif\n\t\t}\n\t\treturn 1.0;\n}\nvec3 BRDF_Diffuse_Lambert( const in vec3 diffuseColor ) {\n\treturn RECIPROCAL_PI * diffuseColor;\n}\nvec3 F_Schlick( const in vec3 specularColor, const in float dotLH ) {\n\tfloat fresnel = exp2( ( -5.55473 * dotLH - 6.98316 ) * dotLH );\n\treturn ( 1.0 - specularColor ) * fresnel + specularColor;\n}\nfloat G_GGX_Smith( const in float alpha, const in float dotNL, const in float dotNV ) {\n\tfloat a2 = pow2( alpha );\n\tfloat gl = dotNL + sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNL ) );\n\tfloat gv = dotNV + sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNV ) );\n\treturn 1.0 / ( gl * gv );\n}\nfloat G_GGX_SmithCorrelated( const in float alpha, const in float dotNL, const in float dotNV ) {\n\tfloat a2 = pow2( alpha );\n\tfloat gv = dotNL * sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNV ) );\n\tfloat gl = dotNV * sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNL ) );\n\treturn 0.5 / max( gv + gl, EPSILON );\n}\nfloat D_GGX( const in float alpha, const in float dotNH ) {\n\tfloat a2 = pow2( alpha );\n\tfloat denom = pow2( dotNH ) * ( a2 - 1.0 ) + 1.0;\n\treturn RECIPROCAL_PI * a2 / pow2( denom );\n}\nvec3 BRDF_Specular_GGX( const in IncidentLight incidentLight, const in GeometricContext geometry, const in vec3 specularColor, const in float roughness ) {\n\tfloat alpha = pow2( roughness );\n\tvec3 halfDir = normalize( incidentLight.direction + geometry.viewDir );\n\tfloat dotNL = saturate( dot( geometry.normal, incidentLight.direction ) );\n\tfloat dotNV = saturate( dot( geometry.normal, geometry.viewDir ) );\n\tfloat dotNH = saturate( dot( geometry.normal, halfDir ) );\n\tfloat dotLH = saturate( dot( incidentLight.direction, halfDir ) );\n\tvec3 F = F_Schlick( specularColor, dotLH );\n\tfloat G = G_GGX_SmithCorrelated( alpha, dotNL, dotNV );\n\tfloat D = D_GGX( alpha, dotNH );\n\treturn F * ( G * D );\n}\nvec2 ltcTextureCoords( const in GeometricContext geometry, const in float roughness ) {\n\tconst float LUT_SIZE = 64.0;\n\tconst float LUT_SCALE = (LUT_SIZE - 1.0)/LUT_SIZE;\n\tconst float LUT_BIAS = 0.5/LUT_SIZE;\n\tvec3 N = geometry.normal;\n\tvec3 V = geometry.viewDir;\n\tvec3 P = geometry.position;\n\tfloat theta = acos( dot( N, V ) );\n\tvec2 uv = vec2(\n\t\tsqrt( saturate( roughness ) ),\n\t\tsaturate( theta / ( 0.5 * PI ) ) );\n\tuv = uv * LUT_SCALE + LUT_BIAS;\n\treturn uv;\n}\nvoid clipQuadToHorizon( inout vec3 L[5], out int n ) {\n\tint config = 0;\n\tif ( L[0].z > 0.0 ) config += 1;\n\tif ( L[1].z > 0.0 ) config += 2;\n\tif ( L[2].z > 0.0 ) config += 4;\n\tif ( L[3].z > 0.0 ) config += 8;\n\tn = 0;\n\tif ( config == 0 ) {\n\t} else if ( config == 1 ) {\n\t\tn = 3;\n\t\tL[1] = -L[1].z * L[0] + L[0].z * L[1];\n\t\tL[2] = -L[3].z * L[0] + L[0].z * L[3];\n\t} else if ( config == 2 ) {\n\t\tn = 3;\n\t\tL[0] = -L[0].z * L[1] + L[1].z * L[0];\n\t\tL[2] = -L[2].z * L[1] + L[1].z * L[2];\n\t} else if ( config == 3 ) {\n\t\tn = 4;\n\t\tL[2] = -L[2].z * L[1] + L[1].z * L[2];\n\t\tL[3] = -L[3].z * L[0] + L[0].z * L[3];\n\t} else if ( config == 4 ) {\n\t\tn = 3;\n\t\tL[0] = -L[3].z * L[2] + L[2].z * L[3];\n\t\tL[1] = -L[1].z * L[2] + L[2].z * L[1];\n\t} else if ( config == 5 ) {\n\t\tn = 0;\n\t} else if ( config == 6 ) {\n\t\tn = 4;\n\t\tL[0] = -L[0].z * L[1] + L[1].z * L[0];\n\t\tL[3] = -L[3].z * L[2] + L[2].z * L[3];\n\t} else if ( config == 7 ) {\n\t\tn = 5;\n\t\tL[4] = -L[3].z * L[0] + L[0].z * L[3];\n\t\tL[3] = -L[3].z * L[2] + L[2].z * L[3];\n\t} else if ( config == 8 ) {\n\t\tn = 3;\n\t\tL[0] = -L[0].z * L[3] + L[3].z * L[0];\n\t\tL[1] = -L[2].z * L[3] + L[3].z * L[2];\n\t\tL[2] = L[3];\n\t} else if ( config == 9 ) {\n\t\tn = 4;\n\t\tL[1] = -L[1].z * L[0] + L[0].z * L[1];\n\t\tL[2] = -L[2].z * L[3] + L[3].z * L[2];\n\t} else if ( config == 10 ) {\n\t\tn = 0;\n\t} else if ( config == 11 ) {\n\t\tn = 5;\n\t\tL[4] = L[3];\n\t\tL[3] = -L[2].z * L[3] + L[3].z * L[2];\n\t\tL[2] = -L[2].z * L[1] + L[1].z * L[2];\n\t} else if ( config == 12 ) {\n\t\tn = 4;\n\t\tL[1] = -L[1].z * L[2] + L[2].z * L[1];\n\t\tL[0] = -L[0].z * L[3] + L[3].z * L[0];\n\t} else if ( config == 13 ) {\n\t\tn = 5;\n\t\tL[4] = L[3];\n\t\tL[3] = L[2];\n\t\tL[2] = -L[1].z * L[2] + L[2].z * L[1];\n\t\tL[1] = -L[1].z * L[0] + L[0].z * L[1];\n\t} else if ( config == 14 ) {\n\t\tn = 5;\n\t\tL[4] = -L[0].z * L[3] + L[3].z * L[0];\n\t\tL[0] = -L[0].z * L[1] + L[1].z * L[0];\n\t} else if ( config == 15 ) {\n\t\tn = 4;\n\t}\n\tif ( n == 3 )\n\t\tL[3] = L[0];\n\tif ( n == 4 )\n\t\tL[4] = L[0];\n}\nfloat integrateLtcBrdfOverRectEdge( vec3 v1, vec3 v2 ) {\n\tfloat cosTheta = dot( v1, v2 );\n\tfloat theta = acos( cosTheta );\n\tfloat res = cross( v1, v2 ).z * ( ( theta > 0.001 ) ? theta / sin( theta ) : 1.0 );\n\treturn res;\n}\nvoid initRectPoints( const in vec3 pos, const in vec3 halfWidth, const in vec3 halfHeight, out vec3 rectPoints[4] ) {\n\trectPoints[0] = pos - halfWidth - halfHeight;\n\trectPoints[1] = pos + halfWidth - halfHeight;\n\trectPoints[2] = pos + halfWidth + halfHeight;\n\trectPoints[3] = pos - halfWidth + halfHeight;\n}\nvec3 integrateLtcBrdfOverRect( const in GeometricContext geometry, const in mat3 brdfMat, const in vec3 rectPoints[4] ) {\n\tvec3 N = geometry.normal;\n\tvec3 V = geometry.viewDir;\n\tvec3 P = geometry.position;\n\tvec3 T1, T2;\n\tT1 = normalize(V - N * dot( V, N ));\n\tT2 = - cross( N, T1 );\n\tmat3 brdfWrtSurface = brdfMat * transpose( mat3( T1, T2, N ) );\n\tvec3 clippedRect[5];\n\tclippedRect[0] = brdfWrtSurface * ( rectPoints[0] - P );\n\tclippedRect[1] = brdfWrtSurface * ( rectPoints[1] - P );\n\tclippedRect[2] = brdfWrtSurface * ( rectPoints[2] - P );\n\tclippedRect[3] = brdfWrtSurface * ( rectPoints[3] - P );\n\tint n;\n\tclipQuadToHorizon(clippedRect, n);\n\tif ( n == 0 )\n\t\treturn vec3( 0, 0, 0 );\n\tclippedRect[0] = normalize( clippedRect[0] );\n\tclippedRect[1] = normalize( clippedRect[1] );\n\tclippedRect[2] = normalize( clippedRect[2] );\n\tclippedRect[3] = normalize( clippedRect[3] );\n\tclippedRect[4] = normalize( clippedRect[4] );\n\tfloat sum = 0.0;\n\tsum += integrateLtcBrdfOverRectEdge( clippedRect[0], clippedRect[1] );\n\tsum += integrateLtcBrdfOverRectEdge( clippedRect[1], clippedRect[2] );\n\tsum += integrateLtcBrdfOverRectEdge( clippedRect[2], clippedRect[3] );\n\tif (n >= 4)\n\t\tsum += integrateLtcBrdfOverRectEdge( clippedRect[3], clippedRect[4] );\n\tif (n == 5)\n\t\tsum += integrateLtcBrdfOverRectEdge( clippedRect[4], clippedRect[0] );\n\tsum = max( 0.0, sum );\n\tvec3 Lo_i = vec3( sum, sum, sum );\n\treturn Lo_i;\n}\nvec3 Rect_Area_Light_Specular_Reflectance(\n\t\tconst in GeometricContext geometry,\n\t\tconst in vec3 lightPos, const in vec3 lightHalfWidth, const in vec3 lightHalfHeight,\n\t\tconst in float roughness,\n\t\tconst in sampler2D ltcMat, const in sampler2D ltcMag ) {\n\tvec3 rectPoints[4];\n\tinitRectPoints( lightPos, lightHalfWidth, lightHalfHeight, rectPoints );\n\tvec2 uv = ltcTextureCoords( geometry, roughness );\n\tvec4 brdfLtcApproxParams, t;\n\tbrdfLtcApproxParams = texture2D( ltcMat, uv );\n\tt = texture2D( ltcMat, uv );\n\tfloat brdfLtcScalar = texture2D( ltcMag, uv ).a;\n\tmat3 brdfLtcApproxMat = mat3(\n\t\tvec3( 1, 0, t.y ),\n\t\tvec3( 0, t.z, 0 ),\n\t\tvec3( t.w, 0, t.x )\n\t);\n\tvec3 specularReflectance = integrateLtcBrdfOverRect( geometry, brdfLtcApproxMat, rectPoints );\n\tspecularReflectance *= brdfLtcScalar;\n\treturn specularReflectance;\n}\nvec3 Rect_Area_Light_Diffuse_Reflectance(\n\t\tconst in GeometricContext geometry,\n\t\tconst in vec3 lightPos, const in vec3 lightHalfWidth, const in vec3 lightHalfHeight ) {\n\tvec3 rectPoints[4];\n\tinitRectPoints( lightPos, lightHalfWidth, lightHalfHeight, rectPoints );\n\tmat3 diffuseBrdfMat = mat3(1);\n\tvec3 diffuseReflectance = integrateLtcBrdfOverRect( geometry, diffuseBrdfMat, rectPoints );\n\treturn diffuseReflectance;\n}\nvec3 BRDF_Specular_GGX_Environment( const in GeometricContext geometry, const in vec3 specularColor, const in float roughness ) {\n\tfloat dotNV = saturate( dot( geometry.normal, geometry.viewDir ) );\n\tconst vec4 c0 = vec4( - 1, - 0.0275, - 0.572, 0.022 );\n\tconst vec4 c1 = vec4( 1, 0.0425, 1.04, - 0.04 );\n\tvec4 r = roughness * c0 + c1;\n\tfloat a004 = min( r.x * r.x, exp2( - 9.28 * dotNV ) ) * r.x + r.y;\n\tvec2 AB = vec2( -1.04, 1.04 ) * a004 + r.zw;\n\treturn specularColor * AB.x + AB.y;\n}\nfloat G_BlinnPhong_Implicit( ) {\n\treturn 0.25;\n}\nfloat D_BlinnPhong( const in float shininess, const in float dotNH ) {\n\treturn RECIPROCAL_PI * ( shininess * 0.5 + 1.0 ) * pow( dotNH, shininess );\n}\nvec3 BRDF_Specular_BlinnPhong( const in IncidentLight incidentLight, const in GeometricContext geometry, const in vec3 specularColor, const in float shininess ) {\n\tvec3 halfDir = normalize( incidentLight.direction + geometry.viewDir );\n\tfloat dotNH = saturate( dot( geometry.normal, halfDir ) );\n\tfloat dotLH = saturate( dot( incidentLight.direction, halfDir ) );\n\tvec3 F = F_Schlick( specularColor, dotLH );\n\tfloat G = G_BlinnPhong_Implicit( );\n\tfloat D = D_BlinnPhong( shininess, dotNH );\n\treturn F * ( G * D );\n}\nfloat GGXRoughnessToBlinnExponent( const in float ggxRoughness ) {\n\treturn ( 2.0 / pow2( ggxRoughness + 0.0001 ) - 2.0 );\n}\nfloat BlinnExponentToGGXRoughness( const in float blinnExponent ) {\n\treturn sqrt( 2.0 / ( blinnExponent + 2.0 ) );\n}\n", +bumpmap_pars_fragment:"#ifdef USE_BUMPMAP\n\tuniform sampler2D bumpMap;\n\tuniform float bumpScale;\n\tvec2 dHdxy_fwd() {\n\t\tvec2 dSTdx = dFdx( vUv );\n\t\tvec2 dSTdy = dFdy( vUv );\n\t\tfloat Hll = bumpScale * texture2D( bumpMap, vUv ).x;\n\t\tfloat dBx = bumpScale * texture2D( bumpMap, vUv + dSTdx ).x - Hll;\n\t\tfloat dBy = bumpScale * texture2D( bumpMap, vUv + dSTdy ).x - Hll;\n\t\treturn vec2( dBx, dBy );\n\t}\n\tvec3 perturbNormalArb( vec3 surf_pos, vec3 surf_norm, vec2 dHdxy ) {\n\t\tvec3 vSigmaX = dFdx( surf_pos );\n\t\tvec3 vSigmaY = dFdy( surf_pos );\n\t\tvec3 vN = surf_norm;\n\t\tvec3 R1 = cross( vSigmaY, vN );\n\t\tvec3 R2 = cross( vN, vSigmaX );\n\t\tfloat fDet = dot( vSigmaX, R1 );\n\t\tvec3 vGrad = sign( fDet ) * ( dHdxy.x * R1 + dHdxy.y * R2 );\n\t\treturn normalize( abs( fDet ) * surf_norm - vGrad );\n\t}\n#endif\n", +clipping_planes_fragment:"#if NUM_CLIPPING_PLANES > 0\n\tfor ( int i = 0; i < UNION_CLIPPING_PLANES; ++ i ) {\n\t\tvec4 plane = clippingPlanes[ i ];\n\t\tif ( dot( vViewPosition, plane.xyz ) > plane.w ) discard;\n\t}\n\t\t\n\t#if UNION_CLIPPING_PLANES < NUM_CLIPPING_PLANES\n\t\tbool clipped = true;\n\t\tfor ( int i = UNION_CLIPPING_PLANES; i < NUM_CLIPPING_PLANES; ++ i ) {\n\t\t\tvec4 plane = clippingPlanes[ i ];\n\t\t\tclipped = ( dot( vViewPosition, plane.xyz ) > plane.w ) && clipped;\n\t\t}\n\t\tif ( clipped ) discard;\n\t\n\t#endif\n#endif\n", +clipping_planes_pars_fragment:"#if NUM_CLIPPING_PLANES > 0\n\t#if ! defined( PHYSICAL ) && ! defined( PHONG )\n\t\tvarying vec3 vViewPosition;\n\t#endif\n\tuniform vec4 clippingPlanes[ NUM_CLIPPING_PLANES ];\n#endif\n",clipping_planes_pars_vertex:"#if NUM_CLIPPING_PLANES > 0 && ! defined( PHYSICAL ) && ! defined( PHONG )\n\tvarying vec3 vViewPosition;\n#endif\n",clipping_planes_vertex:"#if NUM_CLIPPING_PLANES > 0 && ! defined( PHYSICAL ) && ! defined( PHONG )\n\tvViewPosition = - mvPosition.xyz;\n#endif\n", +color_fragment:"#ifdef USE_COLOR\n\tdiffuseColor.rgb *= vColor;\n#endif",color_pars_fragment:"#ifdef USE_COLOR\n\tvarying vec3 vColor;\n#endif\n",color_pars_vertex:"#ifdef USE_COLOR\n\tvarying vec3 vColor;\n#endif",color_vertex:"#ifdef USE_COLOR\n\tvColor.xyz = color.xyz;\n#endif",common:"#define PI 3.14159265359\n#define PI2 6.28318530718\n#define PI_HALF 1.5707963267949\n#define RECIPROCAL_PI 0.31830988618\n#define RECIPROCAL_PI2 0.15915494\n#define LOG2 1.442695\n#define EPSILON 1e-6\n#define saturate(a) clamp( a, 0.0, 1.0 )\n#define whiteCompliment(a) ( 1.0 - saturate( a ) )\nfloat pow2( const in float x ) { return x*x; }\nfloat pow3( const in float x ) { return x*x*x; }\nfloat pow4( const in float x ) { float x2 = x*x; return x2*x2; }\nfloat average( const in vec3 color ) { return dot( color, vec3( 0.3333 ) ); }\nhighp float rand( const in vec2 uv ) {\n\tconst highp float a = 12.9898, b = 78.233, c = 43758.5453;\n\thighp float dt = dot( uv.xy, vec2( a,b ) ), sn = mod( dt, PI );\n\treturn fract(sin(sn) * c);\n}\nstruct IncidentLight {\n\tvec3 color;\n\tvec3 direction;\n\tbool visible;\n};\nstruct ReflectedLight {\n\tvec3 directDiffuse;\n\tvec3 directSpecular;\n\tvec3 indirectDiffuse;\n\tvec3 indirectSpecular;\n};\nstruct GeometricContext {\n\tvec3 position;\n\tvec3 normal;\n\tvec3 viewDir;\n};\nvec3 transformDirection( in vec3 dir, in mat4 matrix ) {\n\treturn normalize( ( matrix * vec4( dir, 0.0 ) ).xyz );\n}\nvec3 inverseTransformDirection( in vec3 dir, in mat4 matrix ) {\n\treturn normalize( ( vec4( dir, 0.0 ) * matrix ).xyz );\n}\nvec3 projectOnPlane(in vec3 point, in vec3 pointOnPlane, in vec3 planeNormal ) {\n\tfloat distance = dot( planeNormal, point - pointOnPlane );\n\treturn - distance * planeNormal + point;\n}\nfloat sideOfPlane( in vec3 point, in vec3 pointOnPlane, in vec3 planeNormal ) {\n\treturn sign( dot( point - pointOnPlane, planeNormal ) );\n}\nvec3 linePlaneIntersect( in vec3 pointOnLine, in vec3 lineDirection, in vec3 pointOnPlane, in vec3 planeNormal ) {\n\treturn lineDirection * ( dot( planeNormal, pointOnPlane - pointOnLine ) / dot( planeNormal, lineDirection ) ) + pointOnLine;\n}\nmat3 transpose( const in mat3 v ) {\n\tmat3 tmp;\n\ttmp[0] = vec3(v[0].x, v[1].x, v[2].x);\n\ttmp[1] = vec3(v[0].y, v[1].y, v[2].y);\n\ttmp[2] = vec3(v[0].z, v[1].z, v[2].z);\n\treturn tmp;\n}\n", +cube_uv_reflection_fragment:"#ifdef ENVMAP_TYPE_CUBE_UV\n#define cubeUV_textureSize (1024.0)\nint getFaceFromDirection(vec3 direction) {\n\tvec3 absDirection = abs(direction);\n\tint face = -1;\n\tif( absDirection.x > absDirection.z ) {\n\t\tif(absDirection.x > absDirection.y )\n\t\t\tface = direction.x > 0.0 ? 0 : 3;\n\t\telse\n\t\t\tface = direction.y > 0.0 ? 1 : 4;\n\t}\n\telse {\n\t\tif(absDirection.z > absDirection.y )\n\t\t\tface = direction.z > 0.0 ? 2 : 5;\n\t\telse\n\t\t\tface = direction.y > 0.0 ? 1 : 4;\n\t}\n\treturn face;\n}\n#define cubeUV_maxLods1 (log2(cubeUV_textureSize*0.25) - 1.0)\n#define cubeUV_rangeClamp (exp2((6.0 - 1.0) * 2.0))\nvec2 MipLevelInfo( vec3 vec, float roughnessLevel, float roughness ) {\n\tfloat scale = exp2(cubeUV_maxLods1 - roughnessLevel);\n\tfloat dxRoughness = dFdx(roughness);\n\tfloat dyRoughness = dFdy(roughness);\n\tvec3 dx = dFdx( vec * scale * dxRoughness );\n\tvec3 dy = dFdy( vec * scale * dyRoughness );\n\tfloat d = max( dot( dx, dx ), dot( dy, dy ) );\n\td = clamp(d, 1.0, cubeUV_rangeClamp);\n\tfloat mipLevel = 0.5 * log2(d);\n\treturn vec2(floor(mipLevel), fract(mipLevel));\n}\n#define cubeUV_maxLods2 (log2(cubeUV_textureSize*0.25) - 2.0)\n#define cubeUV_rcpTextureSize (1.0 / cubeUV_textureSize)\nvec2 getCubeUV(vec3 direction, float roughnessLevel, float mipLevel) {\n\tmipLevel = roughnessLevel > cubeUV_maxLods2 - 3.0 ? 0.0 : mipLevel;\n\tfloat a = 16.0 * cubeUV_rcpTextureSize;\n\tvec2 exp2_packed = exp2( vec2( roughnessLevel, mipLevel ) );\n\tvec2 rcp_exp2_packed = vec2( 1.0 ) / exp2_packed;\n\tfloat powScale = exp2_packed.x * exp2_packed.y;\n\tfloat scale = rcp_exp2_packed.x * rcp_exp2_packed.y * 0.25;\n\tfloat mipOffset = 0.75*(1.0 - rcp_exp2_packed.y) * rcp_exp2_packed.x;\n\tbool bRes = mipLevel == 0.0;\n\tscale = bRes && (scale < a) ? a : scale;\n\tvec3 r;\n\tvec2 offset;\n\tint face = getFaceFromDirection(direction);\n\tfloat rcpPowScale = 1.0 / powScale;\n\tif( face == 0) {\n\t\tr = vec3(direction.x, -direction.z, direction.y);\n\t\toffset = vec2(0.0+mipOffset,0.75 * rcpPowScale);\n\t\toffset.y = bRes && (offset.y < 2.0*a) ? a : offset.y;\n\t}\n\telse if( face == 1) {\n\t\tr = vec3(direction.y, direction.x, direction.z);\n\t\toffset = vec2(scale+mipOffset, 0.75 * rcpPowScale);\n\t\toffset.y = bRes && (offset.y < 2.0*a) ? a : offset.y;\n\t}\n\telse if( face == 2) {\n\t\tr = vec3(direction.z, direction.x, direction.y);\n\t\toffset = vec2(2.0*scale+mipOffset, 0.75 * rcpPowScale);\n\t\toffset.y = bRes && (offset.y < 2.0*a) ? a : offset.y;\n\t}\n\telse if( face == 3) {\n\t\tr = vec3(direction.x, direction.z, direction.y);\n\t\toffset = vec2(0.0+mipOffset,0.5 * rcpPowScale);\n\t\toffset.y = bRes && (offset.y < 2.0*a) ? 0.0 : offset.y;\n\t}\n\telse if( face == 4) {\n\t\tr = vec3(direction.y, direction.x, -direction.z);\n\t\toffset = vec2(scale+mipOffset, 0.5 * rcpPowScale);\n\t\toffset.y = bRes && (offset.y < 2.0*a) ? 0.0 : offset.y;\n\t}\n\telse {\n\t\tr = vec3(direction.z, -direction.x, direction.y);\n\t\toffset = vec2(2.0*scale+mipOffset, 0.5 * rcpPowScale);\n\t\toffset.y = bRes && (offset.y < 2.0*a) ? 0.0 : offset.y;\n\t}\n\tr = normalize(r);\n\tfloat texelOffset = 0.5 * cubeUV_rcpTextureSize;\n\tvec2 s = ( r.yz / abs( r.x ) + vec2( 1.0 ) ) * 0.5;\n\tvec2 base = offset + vec2( texelOffset );\n\treturn base + s * ( scale - 2.0 * texelOffset );\n}\n#define cubeUV_maxLods3 (log2(cubeUV_textureSize*0.25) - 3.0)\nvec4 textureCubeUV(vec3 reflectedDirection, float roughness ) {\n\tfloat roughnessVal = roughness* cubeUV_maxLods3;\n\tfloat r1 = floor(roughnessVal);\n\tfloat r2 = r1 + 1.0;\n\tfloat t = fract(roughnessVal);\n\tvec2 mipInfo = MipLevelInfo(reflectedDirection, r1, roughness);\n\tfloat s = mipInfo.y;\n\tfloat level0 = mipInfo.x;\n\tfloat level1 = level0 + 1.0;\n\tlevel1 = level1 > 5.0 ? 5.0 : level1;\n\tlevel0 += min( floor( s + 0.5 ), 5.0 );\n\tvec2 uv_10 = getCubeUV(reflectedDirection, r1, level0);\n\tvec4 color10 = envMapTexelToLinear(texture2D(envMap, uv_10));\n\tvec2 uv_20 = getCubeUV(reflectedDirection, r2, level0);\n\tvec4 color20 = envMapTexelToLinear(texture2D(envMap, uv_20));\n\tvec4 result = mix(color10, color20, t);\n\treturn vec4(result.rgb, 1.0);\n}\n#endif\n", +defaultnormal_vertex:"#ifdef FLIP_SIDED\n\tobjectNormal = -objectNormal;\n#endif\nvec3 transformedNormal = normalMatrix * objectNormal;\n",displacementmap_pars_vertex:"#ifdef USE_DISPLACEMENTMAP\n\tuniform sampler2D displacementMap;\n\tuniform float displacementScale;\n\tuniform float displacementBias;\n#endif\n",displacementmap_vertex:"#ifdef USE_DISPLACEMENTMAP\n\ttransformed += normal * ( texture2D( displacementMap, uv ).x * displacementScale + displacementBias );\n#endif\n",emissivemap_fragment:"#ifdef USE_EMISSIVEMAP\n\tvec4 emissiveColor = texture2D( emissiveMap, vUv );\n\temissiveColor.rgb = emissiveMapTexelToLinear( emissiveColor ).rgb;\n\ttotalEmissiveRadiance *= emissiveColor.rgb;\n#endif\n", +emissivemap_pars_fragment:"#ifdef USE_EMISSIVEMAP\n\tuniform sampler2D emissiveMap;\n#endif\n",encodings_fragment:" gl_FragColor = linearToOutputTexel( gl_FragColor );\n",encodings_pars_fragment:"\nvec4 LinearToLinear( in vec4 value ) {\n return value;\n}\nvec4 GammaToLinear( in vec4 value, in float gammaFactor ) {\n return vec4( pow( value.xyz, vec3( gammaFactor ) ), value.w );\n}\nvec4 LinearToGamma( in vec4 value, in float gammaFactor ) {\n return vec4( pow( value.xyz, vec3( 1.0 / gammaFactor ) ), value.w );\n}\nvec4 sRGBToLinear( in vec4 value ) {\n return vec4( mix( pow( value.rgb * 0.9478672986 + vec3( 0.0521327014 ), vec3( 2.4 ) ), value.rgb * 0.0773993808, vec3( lessThanEqual( value.rgb, vec3( 0.04045 ) ) ) ), value.w );\n}\nvec4 LinearTosRGB( in vec4 value ) {\n return vec4( mix( pow( value.rgb, vec3( 0.41666 ) ) * 1.055 - vec3( 0.055 ), value.rgb * 12.92, vec3( lessThanEqual( value.rgb, vec3( 0.0031308 ) ) ) ), value.w );\n}\nvec4 RGBEToLinear( in vec4 value ) {\n return vec4( value.rgb * exp2( value.a * 255.0 - 128.0 ), 1.0 );\n}\nvec4 LinearToRGBE( in vec4 value ) {\n float maxComponent = max( max( value.r, value.g ), value.b );\n float fExp = clamp( ceil( log2( maxComponent ) ), -128.0, 127.0 );\n return vec4( value.rgb / exp2( fExp ), ( fExp + 128.0 ) / 255.0 );\n}\nvec4 RGBMToLinear( in vec4 value, in float maxRange ) {\n return vec4( value.xyz * value.w * maxRange, 1.0 );\n}\nvec4 LinearToRGBM( in vec4 value, in float maxRange ) {\n float maxRGB = max( value.x, max( value.g, value.b ) );\n float M = clamp( maxRGB / maxRange, 0.0, 1.0 );\n M = ceil( M * 255.0 ) / 255.0;\n return vec4( value.rgb / ( M * maxRange ), M );\n}\nvec4 RGBDToLinear( in vec4 value, in float maxRange ) {\n return vec4( value.rgb * ( ( maxRange / 255.0 ) / value.a ), 1.0 );\n}\nvec4 LinearToRGBD( in vec4 value, in float maxRange ) {\n float maxRGB = max( value.x, max( value.g, value.b ) );\n float D = max( maxRange / maxRGB, 1.0 );\n D = min( floor( D ) / 255.0, 1.0 );\n return vec4( value.rgb * ( D * ( 255.0 / maxRange ) ), D );\n}\nconst mat3 cLogLuvM = mat3( 0.2209, 0.3390, 0.4184, 0.1138, 0.6780, 0.7319, 0.0102, 0.1130, 0.2969 );\nvec4 LinearToLogLuv( in vec4 value ) {\n vec3 Xp_Y_XYZp = value.rgb * cLogLuvM;\n Xp_Y_XYZp = max(Xp_Y_XYZp, vec3(1e-6, 1e-6, 1e-6));\n vec4 vResult;\n vResult.xy = Xp_Y_XYZp.xy / Xp_Y_XYZp.z;\n float Le = 2.0 * log2(Xp_Y_XYZp.y) + 127.0;\n vResult.w = fract(Le);\n vResult.z = (Le - (floor(vResult.w*255.0))/255.0)/255.0;\n return vResult;\n}\nconst mat3 cLogLuvInverseM = mat3( 6.0014, -2.7008, -1.7996, -1.3320, 3.1029, -5.7721, 0.3008, -1.0882, 5.6268 );\nvec4 LogLuvToLinear( in vec4 value ) {\n float Le = value.z * 255.0 + value.w;\n vec3 Xp_Y_XYZp;\n Xp_Y_XYZp.y = exp2((Le - 127.0) / 2.0);\n Xp_Y_XYZp.z = Xp_Y_XYZp.y / value.y;\n Xp_Y_XYZp.x = value.x * Xp_Y_XYZp.z;\n vec3 vRGB = Xp_Y_XYZp.rgb * cLogLuvInverseM;\n return vec4( max(vRGB, 0.0), 1.0 );\n}\n", +envmap_fragment:"#ifdef USE_ENVMAP\n\t#if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( PHONG )\n\t\tvec3 cameraToVertex = normalize( vWorldPosition - cameraPosition );\n\t\tvec3 worldNormal = inverseTransformDirection( normal, viewMatrix );\n\t\t#ifdef ENVMAP_MODE_REFLECTION\n\t\t\tvec3 reflectVec = reflect( cameraToVertex, worldNormal );\n\t\t#else\n\t\t\tvec3 reflectVec = refract( cameraToVertex, worldNormal, refractionRatio );\n\t\t#endif\n\t#else\n\t\tvec3 reflectVec = vReflect;\n\t#endif\n\t#ifdef ENVMAP_TYPE_CUBE\n\t\tvec4 envColor = textureCube( envMap, flipNormal * vec3( flipEnvMap * reflectVec.x, reflectVec.yz ) );\n\t#elif defined( ENVMAP_TYPE_EQUIREC )\n\t\tvec2 sampleUV;\n\t\tsampleUV.y = saturate( flipNormal * reflectVec.y * 0.5 + 0.5 );\n\t\tsampleUV.x = atan( flipNormal * reflectVec.z, flipNormal * reflectVec.x ) * RECIPROCAL_PI2 + 0.5;\n\t\tvec4 envColor = texture2D( envMap, sampleUV );\n\t#elif defined( ENVMAP_TYPE_SPHERE )\n\t\tvec3 reflectView = flipNormal * normalize( ( viewMatrix * vec4( reflectVec, 0.0 ) ).xyz + vec3( 0.0, 0.0, 1.0 ) );\n\t\tvec4 envColor = texture2D( envMap, reflectView.xy * 0.5 + 0.5 );\n\t#else\n\t\tvec4 envColor = vec4( 0.0 );\n\t#endif\n\tenvColor = envMapTexelToLinear( envColor );\n\t#ifdef ENVMAP_BLENDING_MULTIPLY\n\t\toutgoingLight = mix( outgoingLight, outgoingLight * envColor.xyz, specularStrength * reflectivity );\n\t#elif defined( ENVMAP_BLENDING_MIX )\n\t\toutgoingLight = mix( outgoingLight, envColor.xyz, specularStrength * reflectivity );\n\t#elif defined( ENVMAP_BLENDING_ADD )\n\t\toutgoingLight += envColor.xyz * specularStrength * reflectivity;\n\t#endif\n#endif\n", +envmap_pars_fragment:"#if defined( USE_ENVMAP ) || defined( PHYSICAL )\n\tuniform float reflectivity;\n\tuniform float envMapIntensity;\n#endif\n#ifdef USE_ENVMAP\n\t#if ! defined( PHYSICAL ) && ( defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( PHONG ) )\n\t\tvarying vec3 vWorldPosition;\n\t#endif\n\t#ifdef ENVMAP_TYPE_CUBE\n\t\tuniform samplerCube envMap;\n\t#else\n\t\tuniform sampler2D envMap;\n\t#endif\n\tuniform float flipEnvMap;\n\t#if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( PHONG ) || defined( PHYSICAL )\n\t\tuniform float refractionRatio;\n\t#else\n\t\tvarying vec3 vReflect;\n\t#endif\n#endif\n", +envmap_pars_vertex:"#ifdef USE_ENVMAP\n\t#if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( PHONG )\n\t\tvarying vec3 vWorldPosition;\n\t#else\n\t\tvarying vec3 vReflect;\n\t\tuniform float refractionRatio;\n\t#endif\n#endif\n",envmap_vertex:"#ifdef USE_ENVMAP\n\t#if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( PHONG )\n\t\tvWorldPosition = worldPosition.xyz;\n\t#else\n\t\tvec3 cameraToVertex = normalize( worldPosition.xyz - cameraPosition );\n\t\tvec3 worldNormal = inverseTransformDirection( transformedNormal, viewMatrix );\n\t\t#ifdef ENVMAP_MODE_REFLECTION\n\t\t\tvReflect = reflect( cameraToVertex, worldNormal );\n\t\t#else\n\t\t\tvReflect = refract( cameraToVertex, worldNormal, refractionRatio );\n\t\t#endif\n\t#endif\n#endif\n", +fog_fragment:"#ifdef USE_FOG\n\t#ifdef USE_LOGDEPTHBUF_EXT\n\t\tfloat depth = gl_FragDepthEXT / gl_FragCoord.w;\n\t#else\n\t\tfloat depth = gl_FragCoord.z / gl_FragCoord.w;\n\t#endif\n\t#ifdef FOG_EXP2\n\t\tfloat fogFactor = whiteCompliment( exp2( - fogDensity * fogDensity * depth * depth * LOG2 ) );\n\t#else\n\t\tfloat fogFactor = smoothstep( fogNear, fogFar, depth );\n\t#endif\n\tgl_FragColor.rgb = mix( gl_FragColor.rgb, fogColor, fogFactor );\n#endif\n",fog_pars_fragment:"#ifdef USE_FOG\n\tuniform vec3 fogColor;\n\t#ifdef FOG_EXP2\n\t\tuniform float fogDensity;\n\t#else\n\t\tuniform float fogNear;\n\t\tuniform float fogFar;\n\t#endif\n#endif", +gradientmap_pars_fragment:"#ifdef TOON\n\tuniform sampler2D gradientMap;\n\tvec3 getGradientIrradiance( vec3 normal, vec3 lightDirection ) {\n\t\tfloat dotNL = dot( normal, lightDirection );\n\t\tvec2 coord = vec2( dotNL * 0.5 + 0.5, 0.0 );\n\t\t#ifdef USE_GRADIENTMAP\n\t\t\treturn texture2D( gradientMap, coord ).rgb;\n\t\t#else\n\t\t\treturn ( coord.x < 0.7 ) ? vec3( 0.7 ) : vec3( 1.0 );\n\t\t#endif\n\t}\n#endif\n",lightmap_fragment:"#ifdef USE_LIGHTMAP\n\treflectedLight.indirectDiffuse += PI * texture2D( lightMap, vUv2 ).xyz * lightMapIntensity;\n#endif\n", +lightmap_pars_fragment:"#ifdef USE_LIGHTMAP\n\tuniform sampler2D lightMap;\n\tuniform float lightMapIntensity;\n#endif",lights_lambert_vertex:"vec3 diffuse = vec3( 1.0 );\nGeometricContext geometry;\ngeometry.position = mvPosition.xyz;\ngeometry.normal = normalize( transformedNormal );\ngeometry.viewDir = normalize( -mvPosition.xyz );\nGeometricContext backGeometry;\nbackGeometry.position = geometry.position;\nbackGeometry.normal = -geometry.normal;\nbackGeometry.viewDir = geometry.viewDir;\nvLightFront = vec3( 0.0 );\n#ifdef DOUBLE_SIDED\n\tvLightBack = vec3( 0.0 );\n#endif\nIncidentLight directLight;\nfloat dotNL;\nvec3 directLightColor_Diffuse;\n#if NUM_POINT_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {\n\t\tgetPointDirectLightIrradiance( pointLights[ i ], geometry, directLight );\n\t\tdotNL = dot( geometry.normal, directLight.direction );\n\t\tdirectLightColor_Diffuse = PI * directLight.color;\n\t\tvLightFront += saturate( dotNL ) * directLightColor_Diffuse;\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvLightBack += saturate( -dotNL ) * directLightColor_Diffuse;\n\t\t#endif\n\t}\n#endif\n#if NUM_SPOT_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {\n\t\tgetSpotDirectLightIrradiance( spotLights[ i ], geometry, directLight );\n\t\tdotNL = dot( geometry.normal, directLight.direction );\n\t\tdirectLightColor_Diffuse = PI * directLight.color;\n\t\tvLightFront += saturate( dotNL ) * directLightColor_Diffuse;\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvLightBack += saturate( -dotNL ) * directLightColor_Diffuse;\n\t\t#endif\n\t}\n#endif\n#if NUM_RECT_AREA_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_RECT_AREA_LIGHTS; i ++ ) {\n\t}\n#endif\n#if NUM_DIR_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {\n\t\tgetDirectionalDirectLightIrradiance( directionalLights[ i ], geometry, directLight );\n\t\tdotNL = dot( geometry.normal, directLight.direction );\n\t\tdirectLightColor_Diffuse = PI * directLight.color;\n\t\tvLightFront += saturate( dotNL ) * directLightColor_Diffuse;\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvLightBack += saturate( -dotNL ) * directLightColor_Diffuse;\n\t\t#endif\n\t}\n#endif\n#if NUM_HEMI_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_HEMI_LIGHTS; i ++ ) {\n\t\tvLightFront += getHemisphereLightIrradiance( hemisphereLights[ i ], geometry );\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvLightBack += getHemisphereLightIrradiance( hemisphereLights[ i ], backGeometry );\n\t\t#endif\n\t}\n#endif\n", +lights_pars:"uniform vec3 ambientLightColor;\nvec3 getAmbientLightIrradiance( const in vec3 ambientLightColor ) {\n\tvec3 irradiance = ambientLightColor;\n\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\tirradiance *= PI;\n\t#endif\n\treturn irradiance;\n}\n#if NUM_DIR_LIGHTS > 0\n\tstruct DirectionalLight {\n\t\tvec3 direction;\n\t\tvec3 color;\n\t\tint shadow;\n\t\tfloat shadowBias;\n\t\tfloat shadowRadius;\n\t\tvec2 shadowMapSize;\n\t};\n\tuniform DirectionalLight directionalLights[ NUM_DIR_LIGHTS ];\n\tvoid getDirectionalDirectLightIrradiance( const in DirectionalLight directionalLight, const in GeometricContext geometry, out IncidentLight directLight ) {\n\t\tdirectLight.color = directionalLight.color;\n\t\tdirectLight.direction = directionalLight.direction;\n\t\tdirectLight.visible = true;\n\t}\n#endif\n#if NUM_POINT_LIGHTS > 0\n\tstruct PointLight {\n\t\tvec3 position;\n\t\tvec3 color;\n\t\tfloat distance;\n\t\tfloat decay;\n\t\tint shadow;\n\t\tfloat shadowBias;\n\t\tfloat shadowRadius;\n\t\tvec2 shadowMapSize;\n\t};\n\tuniform PointLight pointLights[ NUM_POINT_LIGHTS ];\n\tvoid getPointDirectLightIrradiance( const in PointLight pointLight, const in GeometricContext geometry, out IncidentLight directLight ) {\n\t\tvec3 lVector = pointLight.position - geometry.position;\n\t\tdirectLight.direction = normalize( lVector );\n\t\tfloat lightDistance = length( lVector );\n\t\tdirectLight.color = pointLight.color;\n\t\tdirectLight.color *= punctualLightIntensityToIrradianceFactor( lightDistance, pointLight.distance, pointLight.decay );\n\t\tdirectLight.visible = ( directLight.color != vec3( 0.0 ) );\n\t}\n#endif\n#if NUM_SPOT_LIGHTS > 0\n\tstruct SpotLight {\n\t\tvec3 position;\n\t\tvec3 direction;\n\t\tvec3 color;\n\t\tfloat distance;\n\t\tfloat decay;\n\t\tfloat coneCos;\n\t\tfloat penumbraCos;\n\t\tint shadow;\n\t\tfloat shadowBias;\n\t\tfloat shadowRadius;\n\t\tvec2 shadowMapSize;\n\t};\n\tuniform SpotLight spotLights[ NUM_SPOT_LIGHTS ];\n\tvoid getSpotDirectLightIrradiance( const in SpotLight spotLight, const in GeometricContext geometry, out IncidentLight directLight ) {\n\t\tvec3 lVector = spotLight.position - geometry.position;\n\t\tdirectLight.direction = normalize( lVector );\n\t\tfloat lightDistance = length( lVector );\n\t\tfloat angleCos = dot( directLight.direction, spotLight.direction );\n\t\tif ( angleCos > spotLight.coneCos ) {\n\t\t\tfloat spotEffect = smoothstep( spotLight.coneCos, spotLight.penumbraCos, angleCos );\n\t\t\tdirectLight.color = spotLight.color;\n\t\t\tdirectLight.color *= spotEffect * punctualLightIntensityToIrradianceFactor( lightDistance, spotLight.distance, spotLight.decay );\n\t\t\tdirectLight.visible = true;\n\t\t} else {\n\t\t\tdirectLight.color = vec3( 0.0 );\n\t\t\tdirectLight.visible = false;\n\t\t}\n\t}\n#endif\n#if NUM_RECT_AREA_LIGHTS > 0\n\tstruct RectAreaLight {\n\t\tvec3 color;\n\t\tvec3 position;\n\t\tvec3 halfWidth;\n\t\tvec3 halfHeight;\n\t};\n\tuniform sampler2D ltcMat;\tuniform sampler2D ltcMag;\n\tuniform RectAreaLight rectAreaLights[ NUM_RECT_AREA_LIGHTS ];\n#endif\n#if NUM_HEMI_LIGHTS > 0\n\tstruct HemisphereLight {\n\t\tvec3 direction;\n\t\tvec3 skyColor;\n\t\tvec3 groundColor;\n\t};\n\tuniform HemisphereLight hemisphereLights[ NUM_HEMI_LIGHTS ];\n\tvec3 getHemisphereLightIrradiance( const in HemisphereLight hemiLight, const in GeometricContext geometry ) {\n\t\tfloat dotNL = dot( geometry.normal, hemiLight.direction );\n\t\tfloat hemiDiffuseWeight = 0.5 * dotNL + 0.5;\n\t\tvec3 irradiance = mix( hemiLight.groundColor, hemiLight.skyColor, hemiDiffuseWeight );\n\t\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\t\tirradiance *= PI;\n\t\t#endif\n\t\treturn irradiance;\n\t}\n#endif\n#if defined( USE_ENVMAP ) && defined( PHYSICAL )\n\tvec3 getLightProbeIndirectIrradiance( const in GeometricContext geometry, const in int maxMIPLevel ) {\n\t\tvec3 worldNormal = inverseTransformDirection( geometry.normal, viewMatrix );\n\t\t#ifdef ENVMAP_TYPE_CUBE\n\t\t\tvec3 queryVec = vec3( flipEnvMap * worldNormal.x, worldNormal.yz );\n\t\t\t#ifdef TEXTURE_LOD_EXT\n\t\t\t\tvec4 envMapColor = textureCubeLodEXT( envMap, queryVec, float( maxMIPLevel ) );\n\t\t\t#else\n\t\t\t\tvec4 envMapColor = textureCube( envMap, queryVec, float( maxMIPLevel ) );\n\t\t\t#endif\n\t\t\tenvMapColor.rgb = envMapTexelToLinear( envMapColor ).rgb;\n\t\t#elif defined( ENVMAP_TYPE_CUBE_UV )\n\t\t\tvec3 queryVec = vec3( flipEnvMap * worldNormal.x, worldNormal.yz );\n\t\t\tvec4 envMapColor = textureCubeUV( queryVec, 1.0 );\n\t\t#else\n\t\t\tvec4 envMapColor = vec4( 0.0 );\n\t\t#endif\n\t\treturn PI * envMapColor.rgb * envMapIntensity;\n\t}\n\tfloat getSpecularMIPLevel( const in float blinnShininessExponent, const in int maxMIPLevel ) {\n\t\tfloat maxMIPLevelScalar = float( maxMIPLevel );\n\t\tfloat desiredMIPLevel = maxMIPLevelScalar - 0.79248 - 0.5 * log2( pow2( blinnShininessExponent ) + 1.0 );\n\t\treturn clamp( desiredMIPLevel, 0.0, maxMIPLevelScalar );\n\t}\n\tvec3 getLightProbeIndirectRadiance( const in GeometricContext geometry, const in float blinnShininessExponent, const in int maxMIPLevel ) {\n\t\t#ifdef ENVMAP_MODE_REFLECTION\n\t\t\tvec3 reflectVec = reflect( -geometry.viewDir, geometry.normal );\n\t\t#else\n\t\t\tvec3 reflectVec = refract( -geometry.viewDir, geometry.normal, refractionRatio );\n\t\t#endif\n\t\treflectVec = inverseTransformDirection( reflectVec, viewMatrix );\n\t\tfloat specularMIPLevel = getSpecularMIPLevel( blinnShininessExponent, maxMIPLevel );\n\t\t#ifdef ENVMAP_TYPE_CUBE\n\t\t\tvec3 queryReflectVec = vec3( flipEnvMap * reflectVec.x, reflectVec.yz );\n\t\t\t#ifdef TEXTURE_LOD_EXT\n\t\t\t\tvec4 envMapColor = textureCubeLodEXT( envMap, queryReflectVec, specularMIPLevel );\n\t\t\t#else\n\t\t\t\tvec4 envMapColor = textureCube( envMap, queryReflectVec, specularMIPLevel );\n\t\t\t#endif\n\t\t\tenvMapColor.rgb = envMapTexelToLinear( envMapColor ).rgb;\n\t\t#elif defined( ENVMAP_TYPE_CUBE_UV )\n\t\t\tvec3 queryReflectVec = vec3( flipEnvMap * reflectVec.x, reflectVec.yz );\n\t\t\tvec4 envMapColor = textureCubeUV(queryReflectVec, BlinnExponentToGGXRoughness(blinnShininessExponent));\n\t\t#elif defined( ENVMAP_TYPE_EQUIREC )\n\t\t\tvec2 sampleUV;\n\t\t\tsampleUV.y = saturate( reflectVec.y * 0.5 + 0.5 );\n\t\t\tsampleUV.x = atan( reflectVec.z, reflectVec.x ) * RECIPROCAL_PI2 + 0.5;\n\t\t\t#ifdef TEXTURE_LOD_EXT\n\t\t\t\tvec4 envMapColor = texture2DLodEXT( envMap, sampleUV, specularMIPLevel );\n\t\t\t#else\n\t\t\t\tvec4 envMapColor = texture2D( envMap, sampleUV, specularMIPLevel );\n\t\t\t#endif\n\t\t\tenvMapColor.rgb = envMapTexelToLinear( envMapColor ).rgb;\n\t\t#elif defined( ENVMAP_TYPE_SPHERE )\n\t\t\tvec3 reflectView = normalize( ( viewMatrix * vec4( reflectVec, 0.0 ) ).xyz + vec3( 0.0,0.0,1.0 ) );\n\t\t\t#ifdef TEXTURE_LOD_EXT\n\t\t\t\tvec4 envMapColor = texture2DLodEXT( envMap, reflectView.xy * 0.5 + 0.5, specularMIPLevel );\n\t\t\t#else\n\t\t\t\tvec4 envMapColor = texture2D( envMap, reflectView.xy * 0.5 + 0.5, specularMIPLevel );\n\t\t\t#endif\n\t\t\tenvMapColor.rgb = envMapTexelToLinear( envMapColor ).rgb;\n\t\t#endif\n\t\treturn envMapColor.rgb * envMapIntensity;\n\t}\n#endif\n", +lights_phong_fragment:"BlinnPhongMaterial material;\nmaterial.diffuseColor = diffuseColor.rgb;\nmaterial.specularColor = specular;\nmaterial.specularShininess = shininess;\nmaterial.specularStrength = specularStrength;\n",lights_phong_pars_fragment:"varying vec3 vViewPosition;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\nstruct BlinnPhongMaterial {\n\tvec3\tdiffuseColor;\n\tvec3\tspecularColor;\n\tfloat\tspecularShininess;\n\tfloat\tspecularStrength;\n};\n#if NUM_RECT_AREA_LIGHTS > 0\n void RE_Direct_RectArea_BlinnPhong( const in RectAreaLight rectAreaLight, const in GeometricContext geometry, const in BlinnPhongMaterial material, inout ReflectedLight reflectedLight ) {\n vec3 matDiffColor = material.diffuseColor;\n vec3 matSpecColor = material.specularColor;\n vec3 lightColor = rectAreaLight.color;\n float roughness = BlinnExponentToGGXRoughness( material.specularShininess );\n vec3 spec = Rect_Area_Light_Specular_Reflectance(\n geometry,\n rectAreaLight.position, rectAreaLight.halfWidth, rectAreaLight.halfHeight,\n roughness,\n ltcMat, ltcMag );\n vec3 diff = Rect_Area_Light_Diffuse_Reflectance(\n geometry,\n rectAreaLight.position, rectAreaLight.halfWidth, rectAreaLight.halfHeight );\n reflectedLight.directSpecular += lightColor * matSpecColor * spec / PI2;\n reflectedLight.directDiffuse += lightColor * matDiffColor * diff / PI2;\n }\n#endif\nvoid RE_Direct_BlinnPhong( const in IncidentLight directLight, const in GeometricContext geometry, const in BlinnPhongMaterial material, inout ReflectedLight reflectedLight ) {\n\t#ifdef TOON\n\t\tvec3 irradiance = getGradientIrradiance( geometry.normal, directLight.direction ) * directLight.color;\n\t#else\n\t\tfloat dotNL = saturate( dot( geometry.normal, directLight.direction ) );\n\t\tvec3 irradiance = dotNL * directLight.color;\n\t#endif\n\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\tirradiance *= PI;\n\t#endif\n\treflectedLight.directDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\n\treflectedLight.directSpecular += irradiance * BRDF_Specular_BlinnPhong( directLight, geometry, material.specularColor, material.specularShininess ) * material.specularStrength;\n}\nvoid RE_IndirectDiffuse_BlinnPhong( const in vec3 irradiance, const in GeometricContext geometry, const in BlinnPhongMaterial material, inout ReflectedLight reflectedLight ) {\n\treflectedLight.indirectDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\n}\n#define RE_Direct\t\t\t\tRE_Direct_BlinnPhong\n#define RE_Direct_RectArea\t\tRE_Direct_RectArea_BlinnPhong\n#define RE_IndirectDiffuse\t\tRE_IndirectDiffuse_BlinnPhong\n#define Material_LightProbeLOD( material )\t(0)\n", +lights_physical_fragment:"PhysicalMaterial material;\nmaterial.diffuseColor = diffuseColor.rgb * ( 1.0 - metalnessFactor );\nmaterial.specularRoughness = clamp( roughnessFactor, 0.04, 1.0 );\n#ifdef STANDARD\n\tmaterial.specularColor = mix( vec3( DEFAULT_SPECULAR_COEFFICIENT ), diffuseColor.rgb, metalnessFactor );\n#else\n\tmaterial.specularColor = mix( vec3( MAXIMUM_SPECULAR_COEFFICIENT * pow2( reflectivity ) ), diffuseColor.rgb, metalnessFactor );\n\tmaterial.clearCoat = saturate( clearCoat );\tmaterial.clearCoatRoughness = clamp( clearCoatRoughness, 0.04, 1.0 );\n#endif\n", +lights_physical_pars_fragment:"struct PhysicalMaterial {\n\tvec3\tdiffuseColor;\n\tfloat\tspecularRoughness;\n\tvec3\tspecularColor;\n\t#ifndef STANDARD\n\t\tfloat clearCoat;\n\t\tfloat clearCoatRoughness;\n\t#endif\n};\n#define MAXIMUM_SPECULAR_COEFFICIENT 0.16\n#define DEFAULT_SPECULAR_COEFFICIENT 0.04\nfloat clearCoatDHRApprox( const in float roughness, const in float dotNL ) {\n\treturn DEFAULT_SPECULAR_COEFFICIENT + ( 1.0 - DEFAULT_SPECULAR_COEFFICIENT ) * ( pow( 1.0 - dotNL, 5.0 ) * pow( 1.0 - roughness, 2.0 ) );\n}\n#if NUM_RECT_AREA_LIGHTS > 0\n void RE_Direct_RectArea_Physical( const in RectAreaLight rectAreaLight, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\n vec3 matDiffColor = material.diffuseColor;\n vec3 matSpecColor = material.specularColor;\n vec3 lightColor = rectAreaLight.color;\n float roughness = material.specularRoughness;\n vec3 spec = Rect_Area_Light_Specular_Reflectance(\n geometry,\n rectAreaLight.position, rectAreaLight.halfWidth, rectAreaLight.halfHeight,\n roughness,\n ltcMat, ltcMag );\n vec3 diff = Rect_Area_Light_Diffuse_Reflectance(\n geometry,\n rectAreaLight.position, rectAreaLight.halfWidth, rectAreaLight.halfHeight );\n reflectedLight.directSpecular += lightColor * matSpecColor * spec;\n reflectedLight.directDiffuse += lightColor * matDiffColor * diff;\n }\n#endif\nvoid RE_Direct_Physical( const in IncidentLight directLight, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\n\tfloat dotNL = saturate( dot( geometry.normal, directLight.direction ) );\n\tvec3 irradiance = dotNL * directLight.color;\n\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\tirradiance *= PI;\n\t#endif\n\t#ifndef STANDARD\n\t\tfloat clearCoatDHR = material.clearCoat * clearCoatDHRApprox( material.clearCoatRoughness, dotNL );\n\t#else\n\t\tfloat clearCoatDHR = 0.0;\n\t#endif\n\treflectedLight.directSpecular += ( 1.0 - clearCoatDHR ) * irradiance * BRDF_Specular_GGX( directLight, geometry, material.specularColor, material.specularRoughness );\n\treflectedLight.directDiffuse += ( 1.0 - clearCoatDHR ) * irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\n\t#ifndef STANDARD\n\t\treflectedLight.directSpecular += irradiance * material.clearCoat * BRDF_Specular_GGX( directLight, geometry, vec3( DEFAULT_SPECULAR_COEFFICIENT ), material.clearCoatRoughness );\n\t#endif\n}\nvoid RE_IndirectDiffuse_Physical( const in vec3 irradiance, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\n\treflectedLight.indirectDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\n}\nvoid RE_IndirectSpecular_Physical( const in vec3 radiance, const in vec3 clearCoatRadiance, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\n\t#ifndef STANDARD\n\t\tfloat dotNV = saturate( dot( geometry.normal, geometry.viewDir ) );\n\t\tfloat dotNL = dotNV;\n\t\tfloat clearCoatDHR = material.clearCoat * clearCoatDHRApprox( material.clearCoatRoughness, dotNL );\n\t#else\n\t\tfloat clearCoatDHR = 0.0;\n\t#endif\n\treflectedLight.indirectSpecular += ( 1.0 - clearCoatDHR ) * radiance * BRDF_Specular_GGX_Environment( geometry, material.specularColor, material.specularRoughness );\n\t#ifndef STANDARD\n\t\treflectedLight.indirectSpecular += clearCoatRadiance * material.clearCoat * BRDF_Specular_GGX_Environment( geometry, vec3( DEFAULT_SPECULAR_COEFFICIENT ), material.clearCoatRoughness );\n\t#endif\n}\n#define RE_Direct\t\t\t\tRE_Direct_Physical\n#define RE_Direct_RectArea\t\tRE_Direct_RectArea_Physical\n#define RE_IndirectDiffuse\t\tRE_IndirectDiffuse_Physical\n#define RE_IndirectSpecular\t\tRE_IndirectSpecular_Physical\n#define Material_BlinnShininessExponent( material ) GGXRoughnessToBlinnExponent( material.specularRoughness )\n#define Material_ClearCoat_BlinnShininessExponent( material ) GGXRoughnessToBlinnExponent( material.clearCoatRoughness )\nfloat computeSpecularOcclusion( const in float dotNV, const in float ambientOcclusion, const in float roughness ) {\n\treturn saturate( pow( dotNV + ambientOcclusion, exp2( - 16.0 * roughness - 1.0 ) ) - 1.0 + ambientOcclusion );\n}\n", +lights_template:"\nGeometricContext geometry;\ngeometry.position = - vViewPosition;\ngeometry.normal = normal;\ngeometry.viewDir = normalize( vViewPosition );\nIncidentLight directLight;\n#if ( NUM_POINT_LIGHTS > 0 ) && defined( RE_Direct )\n\tPointLight pointLight;\n\tfor ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {\n\t\tpointLight = pointLights[ i ];\n\t\tgetPointDirectLightIrradiance( pointLight, geometry, directLight );\n\t\t#ifdef USE_SHADOWMAP\n\t\tdirectLight.color *= all( bvec2( pointLight.shadow, directLight.visible ) ) ? getPointShadow( pointShadowMap[ i ], pointLight.shadowMapSize, pointLight.shadowBias, pointLight.shadowRadius, vPointShadowCoord[ i ] ) : 1.0;\n\t\t#endif\n\t\tRE_Direct( directLight, geometry, material, reflectedLight );\n\t}\n#endif\n#if ( NUM_SPOT_LIGHTS > 0 ) && defined( RE_Direct )\n\tSpotLight spotLight;\n\tfor ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {\n\t\tspotLight = spotLights[ i ];\n\t\tgetSpotDirectLightIrradiance( spotLight, geometry, directLight );\n\t\t#ifdef USE_SHADOWMAP\n\t\tdirectLight.color *= all( bvec2( spotLight.shadow, directLight.visible ) ) ? getShadow( spotShadowMap[ i ], spotLight.shadowMapSize, spotLight.shadowBias, spotLight.shadowRadius, vSpotShadowCoord[ i ] ) : 1.0;\n\t\t#endif\n\t\tRE_Direct( directLight, geometry, material, reflectedLight );\n\t}\n#endif\n#if ( NUM_DIR_LIGHTS > 0 ) && defined( RE_Direct )\n\tDirectionalLight directionalLight;\n\tfor ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {\n\t\tdirectionalLight = directionalLights[ i ];\n\t\tgetDirectionalDirectLightIrradiance( directionalLight, geometry, directLight );\n\t\t#ifdef USE_SHADOWMAP\n\t\tdirectLight.color *= all( bvec2( directionalLight.shadow, directLight.visible ) ) ? getShadow( directionalShadowMap[ i ], directionalLight.shadowMapSize, directionalLight.shadowBias, directionalLight.shadowRadius, vDirectionalShadowCoord[ i ] ) : 1.0;\n\t\t#endif\n\t\tRE_Direct( directLight, geometry, material, reflectedLight );\n\t}\n#endif\n#if ( NUM_RECT_AREA_LIGHTS > 0 ) && defined( RE_Direct_RectArea )\n\tRectAreaLight rectAreaLight;\n\tfor ( int i = 0; i < NUM_RECT_AREA_LIGHTS; i ++ ) {\n\t\trectAreaLight = rectAreaLights[ i ];\n\t\tRE_Direct_RectArea( rectAreaLight, geometry, material, reflectedLight );\n\t}\n#endif\n#if defined( RE_IndirectDiffuse )\n\tvec3 irradiance = getAmbientLightIrradiance( ambientLightColor );\n\t#ifdef USE_LIGHTMAP\n\t\tvec3 lightMapIrradiance = texture2D( lightMap, vUv2 ).xyz * lightMapIntensity;\n\t\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\t\tlightMapIrradiance *= PI;\n\t\t#endif\n\t\tirradiance += lightMapIrradiance;\n\t#endif\n\t#if ( NUM_HEMI_LIGHTS > 0 )\n\t\tfor ( int i = 0; i < NUM_HEMI_LIGHTS; i ++ ) {\n\t\t\tirradiance += getHemisphereLightIrradiance( hemisphereLights[ i ], geometry );\n\t\t}\n\t#endif\n\t#if defined( USE_ENVMAP ) && defined( PHYSICAL ) && defined( ENVMAP_TYPE_CUBE_UV )\n\t \tirradiance += getLightProbeIndirectIrradiance( geometry, 8 );\n\t#endif\n\tRE_IndirectDiffuse( irradiance, geometry, material, reflectedLight );\n#endif\n#if defined( USE_ENVMAP ) && defined( RE_IndirectSpecular )\n\tvec3 radiance = getLightProbeIndirectRadiance( geometry, Material_BlinnShininessExponent( material ), 8 );\n\t#ifndef STANDARD\n\t\tvec3 clearCoatRadiance = getLightProbeIndirectRadiance( geometry, Material_ClearCoat_BlinnShininessExponent( material ), 8 );\n\t#else\n\t\tvec3 clearCoatRadiance = vec3( 0.0 );\n\t#endif\n\t\t\n\tRE_IndirectSpecular( radiance, clearCoatRadiance, geometry, material, reflectedLight );\n#endif\n", +logdepthbuf_fragment:"#if defined(USE_LOGDEPTHBUF) && defined(USE_LOGDEPTHBUF_EXT)\n\tgl_FragDepthEXT = log2(vFragDepth) * logDepthBufFC * 0.5;\n#endif",logdepthbuf_pars_fragment:"#ifdef USE_LOGDEPTHBUF\n\tuniform float logDepthBufFC;\n\t#ifdef USE_LOGDEPTHBUF_EXT\n\t\tvarying float vFragDepth;\n\t#endif\n#endif\n",logdepthbuf_pars_vertex:"#ifdef USE_LOGDEPTHBUF\n\t#ifdef USE_LOGDEPTHBUF_EXT\n\t\tvarying float vFragDepth;\n\t#endif\n\tuniform float logDepthBufFC;\n#endif",logdepthbuf_vertex:"#ifdef USE_LOGDEPTHBUF\n\tgl_Position.z = log2(max( EPSILON, gl_Position.w + 1.0 )) * logDepthBufFC;\n\t#ifdef USE_LOGDEPTHBUF_EXT\n\t\tvFragDepth = 1.0 + gl_Position.w;\n\t#else\n\t\tgl_Position.z = (gl_Position.z - 1.0) * gl_Position.w;\n\t#endif\n#endif\n", +map_fragment:"#ifdef USE_MAP\n\tvec4 texelColor = texture2D( map, vUv );\n\ttexelColor = mapTexelToLinear( texelColor );\n\tdiffuseColor *= texelColor;\n#endif\n",map_pars_fragment:"#ifdef USE_MAP\n\tuniform sampler2D map;\n#endif\n",map_particle_fragment:"#ifdef USE_MAP\n\tvec4 mapTexel = texture2D( map, vec2( gl_PointCoord.x, 1.0 - gl_PointCoord.y ) * offsetRepeat.zw + offsetRepeat.xy );\n\tdiffuseColor *= mapTexelToLinear( mapTexel );\n#endif\n",map_particle_pars_fragment:"#ifdef USE_MAP\n\tuniform vec4 offsetRepeat;\n\tuniform sampler2D map;\n#endif\n", +metalnessmap_fragment:"float metalnessFactor = metalness;\n#ifdef USE_METALNESSMAP\n\tvec4 texelMetalness = texture2D( metalnessMap, vUv );\n\tmetalnessFactor *= texelMetalness.r;\n#endif\n",metalnessmap_pars_fragment:"#ifdef USE_METALNESSMAP\n\tuniform sampler2D metalnessMap;\n#endif",morphnormal_vertex:"#ifdef USE_MORPHNORMALS\n\tobjectNormal += ( morphNormal0 - normal ) * morphTargetInfluences[ 0 ];\n\tobjectNormal += ( morphNormal1 - normal ) * morphTargetInfluences[ 1 ];\n\tobjectNormal += ( morphNormal2 - normal ) * morphTargetInfluences[ 2 ];\n\tobjectNormal += ( morphNormal3 - normal ) * morphTargetInfluences[ 3 ];\n#endif\n", +morphtarget_pars_vertex:"#ifdef USE_MORPHTARGETS\n\t#ifndef USE_MORPHNORMALS\n\tuniform float morphTargetInfluences[ 8 ];\n\t#else\n\tuniform float morphTargetInfluences[ 4 ];\n\t#endif\n#endif",morphtarget_vertex:"#ifdef USE_MORPHTARGETS\n\ttransformed += ( morphTarget0 - position ) * morphTargetInfluences[ 0 ];\n\ttransformed += ( morphTarget1 - position ) * morphTargetInfluences[ 1 ];\n\ttransformed += ( morphTarget2 - position ) * morphTargetInfluences[ 2 ];\n\ttransformed += ( morphTarget3 - position ) * morphTargetInfluences[ 3 ];\n\t#ifndef USE_MORPHNORMALS\n\ttransformed += ( morphTarget4 - position ) * morphTargetInfluences[ 4 ];\n\ttransformed += ( morphTarget5 - position ) * morphTargetInfluences[ 5 ];\n\ttransformed += ( morphTarget6 - position ) * morphTargetInfluences[ 6 ];\n\ttransformed += ( morphTarget7 - position ) * morphTargetInfluences[ 7 ];\n\t#endif\n#endif\n", +normal_flip:"#ifdef DOUBLE_SIDED\n\tfloat flipNormal = ( float( gl_FrontFacing ) * 2.0 - 1.0 );\n#else\n\tfloat flipNormal = 1.0;\n#endif\n",normal_fragment:"#ifdef FLAT_SHADED\n\tvec3 fdx = vec3( dFdx( vViewPosition.x ), dFdx( vViewPosition.y ), dFdx( vViewPosition.z ) );\n\tvec3 fdy = vec3( dFdy( vViewPosition.x ), dFdy( vViewPosition.y ), dFdy( vViewPosition.z ) );\n\tvec3 normal = normalize( cross( fdx, fdy ) );\n#else\n\tvec3 normal = normalize( vNormal ) * flipNormal;\n#endif\n#ifdef USE_NORMALMAP\n\tnormal = perturbNormal2Arb( -vViewPosition, normal );\n#elif defined( USE_BUMPMAP )\n\tnormal = perturbNormalArb( -vViewPosition, normal, dHdxy_fwd() );\n#endif\n", +normalmap_pars_fragment:"#ifdef USE_NORMALMAP\n\tuniform sampler2D normalMap;\n\tuniform vec2 normalScale;\n\tvec3 perturbNormal2Arb( vec3 eye_pos, vec3 surf_norm ) {\n\t\tvec3 q0 = dFdx( eye_pos.xyz );\n\t\tvec3 q1 = dFdy( eye_pos.xyz );\n\t\tvec2 st0 = dFdx( vUv.st );\n\t\tvec2 st1 = dFdy( vUv.st );\n\t\tvec3 S = normalize( q0 * st1.t - q1 * st0.t );\n\t\tvec3 T = normalize( -q0 * st1.s + q1 * st0.s );\n\t\tvec3 N = normalize( surf_norm );\n\t\tvec3 mapN = texture2D( normalMap, vUv ).xyz * 2.0 - 1.0;\n\t\tmapN.xy = normalScale * mapN.xy;\n\t\tmat3 tsn = mat3( S, T, N );\n\t\treturn normalize( tsn * mapN );\n\t}\n#endif\n", +packing:"vec3 packNormalToRGB( const in vec3 normal ) {\n return normalize( normal ) * 0.5 + 0.5;\n}\nvec3 unpackRGBToNormal( const in vec3 rgb ) {\n return 1.0 - 2.0 * rgb.xyz;\n}\nconst float PackUpscale = 256. / 255.;const float UnpackDownscale = 255. / 256.;\nconst vec3 PackFactors = vec3( 256. * 256. * 256., 256. * 256., 256. );\nconst vec4 UnpackFactors = UnpackDownscale / vec4( PackFactors, 1. );\nconst float ShiftRight8 = 1. / 256.;\nvec4 packDepthToRGBA( const in float v ) {\n\tvec4 r = vec4( fract( v * PackFactors ), v );\n\tr.yzw -= r.xyz * ShiftRight8;\treturn r * PackUpscale;\n}\nfloat unpackRGBAToDepth( const in vec4 v ) {\n\treturn dot( v, UnpackFactors );\n}\nfloat viewZToOrthographicDepth( const in float viewZ, const in float near, const in float far ) {\n return ( viewZ + near ) / ( near - far );\n}\nfloat orthographicDepthToViewZ( const in float linearClipZ, const in float near, const in float far ) {\n return linearClipZ * ( near - far ) - near;\n}\nfloat viewZToPerspectiveDepth( const in float viewZ, const in float near, const in float far ) {\n return (( near + viewZ ) * far ) / (( far - near ) * viewZ );\n}\nfloat perspectiveDepthToViewZ( const in float invClipZ, const in float near, const in float far ) {\n return ( near * far ) / ( ( far - near ) * invClipZ - far );\n}\n", +premultiplied_alpha_fragment:"#ifdef PREMULTIPLIED_ALPHA\n\tgl_FragColor.rgb *= gl_FragColor.a;\n#endif\n",project_vertex:"#ifdef USE_SKINNING\n\tvec4 mvPosition = modelViewMatrix * skinned;\n#else\n\tvec4 mvPosition = modelViewMatrix * vec4( transformed, 1.0 );\n#endif\ngl_Position = projectionMatrix * mvPosition;\n",roughnessmap_fragment:"float roughnessFactor = roughness;\n#ifdef USE_ROUGHNESSMAP\n\tvec4 texelRoughness = texture2D( roughnessMap, vUv );\n\troughnessFactor *= texelRoughness.r;\n#endif\n", +roughnessmap_pars_fragment:"#ifdef USE_ROUGHNESSMAP\n\tuniform sampler2D roughnessMap;\n#endif",shadowmap_pars_fragment:"#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHTS > 0\n\t\tuniform sampler2D directionalShadowMap[ NUM_DIR_LIGHTS ];\n\t\tvarying vec4 vDirectionalShadowCoord[ NUM_DIR_LIGHTS ];\n\t#endif\n\t#if NUM_SPOT_LIGHTS > 0\n\t\tuniform sampler2D spotShadowMap[ NUM_SPOT_LIGHTS ];\n\t\tvarying vec4 vSpotShadowCoord[ NUM_SPOT_LIGHTS ];\n\t#endif\n\t#if NUM_POINT_LIGHTS > 0\n\t\tuniform sampler2D pointShadowMap[ NUM_POINT_LIGHTS ];\n\t\tvarying vec4 vPointShadowCoord[ NUM_POINT_LIGHTS ];\n\t#endif\n #if NUM_RECT_AREA_LIGHTS > 0\n #endif\n\tfloat texture2DCompare( sampler2D depths, vec2 uv, float compare ) {\n\t\treturn step( compare, unpackRGBAToDepth( texture2D( depths, uv ) ) );\n\t}\n\tfloat texture2DShadowLerp( sampler2D depths, vec2 size, vec2 uv, float compare ) {\n\t\tconst vec2 offset = vec2( 0.0, 1.0 );\n\t\tvec2 texelSize = vec2( 1.0 ) / size;\n\t\tvec2 centroidUV = floor( uv * size + 0.5 ) / size;\n\t\tfloat lb = texture2DCompare( depths, centroidUV + texelSize * offset.xx, compare );\n\t\tfloat lt = texture2DCompare( depths, centroidUV + texelSize * offset.xy, compare );\n\t\tfloat rb = texture2DCompare( depths, centroidUV + texelSize * offset.yx, compare );\n\t\tfloat rt = texture2DCompare( depths, centroidUV + texelSize * offset.yy, compare );\n\t\tvec2 f = fract( uv * size + 0.5 );\n\t\tfloat a = mix( lb, lt, f.y );\n\t\tfloat b = mix( rb, rt, f.y );\n\t\tfloat c = mix( a, b, f.x );\n\t\treturn c;\n\t}\n\tfloat getShadow( sampler2D shadowMap, vec2 shadowMapSize, float shadowBias, float shadowRadius, vec4 shadowCoord ) {\n\t\tshadowCoord.xyz /= shadowCoord.w;\n\t\tshadowCoord.z += shadowBias;\n\t\tbvec4 inFrustumVec = bvec4 ( shadowCoord.x >= 0.0, shadowCoord.x <= 1.0, shadowCoord.y >= 0.0, shadowCoord.y <= 1.0 );\n\t\tbool inFrustum = all( inFrustumVec );\n\t\tbvec2 frustumTestVec = bvec2( inFrustum, shadowCoord.z <= 1.0 );\n\t\tbool frustumTest = all( frustumTestVec );\n\t\tif ( frustumTest ) {\n\t\t#if defined( SHADOWMAP_TYPE_PCF )\n\t\t\tvec2 texelSize = vec2( 1.0 ) / shadowMapSize;\n\t\t\tfloat dx0 = - texelSize.x * shadowRadius;\n\t\t\tfloat dy0 = - texelSize.y * shadowRadius;\n\t\t\tfloat dx1 = + texelSize.x * shadowRadius;\n\t\t\tfloat dy1 = + texelSize.y * shadowRadius;\n\t\t\treturn (\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy, shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, dy1 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy1 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, dy1 ), shadowCoord.z )\n\t\t\t) * ( 1.0 / 9.0 );\n\t\t#elif defined( SHADOWMAP_TYPE_PCF_SOFT )\n\t\t\tvec2 texelSize = vec2( 1.0 ) / shadowMapSize;\n\t\t\tfloat dx0 = - texelSize.x * shadowRadius;\n\t\t\tfloat dy0 = - texelSize.y * shadowRadius;\n\t\t\tfloat dx1 = + texelSize.x * shadowRadius;\n\t\t\tfloat dy1 = + texelSize.y * shadowRadius;\n\t\t\treturn (\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( dx0, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( 0.0, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( dx1, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( dx0, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy, shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( dx1, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( dx0, dy1 ), shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( 0.0, dy1 ), shadowCoord.z ) +\n\t\t\t\ttexture2DShadowLerp( shadowMap, shadowMapSize, shadowCoord.xy + vec2( dx1, dy1 ), shadowCoord.z )\n\t\t\t) * ( 1.0 / 9.0 );\n\t\t#else\n\t\t\treturn texture2DCompare( shadowMap, shadowCoord.xy, shadowCoord.z );\n\t\t#endif\n\t\t}\n\t\treturn 1.0;\n\t}\n\tvec2 cubeToUV( vec3 v, float texelSizeY ) {\n\t\tvec3 absV = abs( v );\n\t\tfloat scaleToCube = 1.0 / max( absV.x, max( absV.y, absV.z ) );\n\t\tabsV *= scaleToCube;\n\t\tv *= scaleToCube * ( 1.0 - 2.0 * texelSizeY );\n\t\tvec2 planar = v.xy;\n\t\tfloat almostATexel = 1.5 * texelSizeY;\n\t\tfloat almostOne = 1.0 - almostATexel;\n\t\tif ( absV.z >= almostOne ) {\n\t\t\tif ( v.z > 0.0 )\n\t\t\t\tplanar.x = 4.0 - v.x;\n\t\t} else if ( absV.x >= almostOne ) {\n\t\t\tfloat signX = sign( v.x );\n\t\t\tplanar.x = v.z * signX + 2.0 * signX;\n\t\t} else if ( absV.y >= almostOne ) {\n\t\t\tfloat signY = sign( v.y );\n\t\t\tplanar.x = v.x + 2.0 * signY + 2.0;\n\t\t\tplanar.y = v.z * signY - 2.0;\n\t\t}\n\t\treturn vec2( 0.125, 0.25 ) * planar + vec2( 0.375, 0.75 );\n\t}\n\tfloat getPointShadow( sampler2D shadowMap, vec2 shadowMapSize, float shadowBias, float shadowRadius, vec4 shadowCoord ) {\n\t\tvec2 texelSize = vec2( 1.0 ) / ( shadowMapSize * vec2( 4.0, 2.0 ) );\n\t\tvec3 lightToPosition = shadowCoord.xyz;\n\t\tvec3 bd3D = normalize( lightToPosition );\n\t\tfloat dp = ( length( lightToPosition ) - shadowBias ) / 1000.0;\n\t\t#if defined( SHADOWMAP_TYPE_PCF ) || defined( SHADOWMAP_TYPE_PCF_SOFT )\n\t\t\tvec2 offset = vec2( - 1, 1 ) * shadowRadius * texelSize.y;\n\t\t\treturn (\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xyy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yyy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xyx, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yyx, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xxy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yxy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xxx, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yxx, texelSize.y ), dp )\n\t\t\t) * ( 1.0 / 9.0 );\n\t\t#else\n\t\t\treturn texture2DCompare( shadowMap, cubeToUV( bd3D, texelSize.y ), dp );\n\t\t#endif\n\t}\n#endif\n", +shadowmap_pars_vertex:"#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHTS > 0\n\t\tuniform mat4 directionalShadowMatrix[ NUM_DIR_LIGHTS ];\n\t\tvarying vec4 vDirectionalShadowCoord[ NUM_DIR_LIGHTS ];\n\t#endif\n\t#if NUM_SPOT_LIGHTS > 0\n\t\tuniform mat4 spotShadowMatrix[ NUM_SPOT_LIGHTS ];\n\t\tvarying vec4 vSpotShadowCoord[ NUM_SPOT_LIGHTS ];\n\t#endif\n\t#if NUM_POINT_LIGHTS > 0\n\t\tuniform mat4 pointShadowMatrix[ NUM_POINT_LIGHTS ];\n\t\tvarying vec4 vPointShadowCoord[ NUM_POINT_LIGHTS ];\n\t#endif\n #if NUM_RECT_AREA_LIGHTS > 0\n #endif\n#endif\n", +shadowmap_vertex:"#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {\n\t\tvDirectionalShadowCoord[ i ] = directionalShadowMatrix[ i ] * worldPosition;\n\t}\n\t#endif\n\t#if NUM_SPOT_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {\n\t\tvSpotShadowCoord[ i ] = spotShadowMatrix[ i ] * worldPosition;\n\t}\n\t#endif\n\t#if NUM_POINT_LIGHTS > 0\n\tfor ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {\n\t\tvPointShadowCoord[ i ] = pointShadowMatrix[ i ] * worldPosition;\n\t}\n\t#endif\n #if NUM_RECT_AREA_LIGHTS > 0\n #endif\n#endif\n", +shadowmask_pars_fragment:"float getShadowMask() {\n\tfloat shadow = 1.0;\n\t#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHTS > 0\n\tDirectionalLight directionalLight;\n\tfor ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {\n\t\tdirectionalLight = directionalLights[ i ];\n\t\tshadow *= bool( directionalLight.shadow ) ? getShadow( directionalShadowMap[ i ], directionalLight.shadowMapSize, directionalLight.shadowBias, directionalLight.shadowRadius, vDirectionalShadowCoord[ i ] ) : 1.0;\n\t}\n\t#endif\n\t#if NUM_SPOT_LIGHTS > 0\n\tSpotLight spotLight;\n\tfor ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {\n\t\tspotLight = spotLights[ i ];\n\t\tshadow *= bool( spotLight.shadow ) ? getShadow( spotShadowMap[ i ], spotLight.shadowMapSize, spotLight.shadowBias, spotLight.shadowRadius, vSpotShadowCoord[ i ] ) : 1.0;\n\t}\n\t#endif\n\t#if NUM_POINT_LIGHTS > 0\n\tPointLight pointLight;\n\tfor ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {\n\t\tpointLight = pointLights[ i ];\n\t\tshadow *= bool( pointLight.shadow ) ? getPointShadow( pointShadowMap[ i ], pointLight.shadowMapSize, pointLight.shadowBias, pointLight.shadowRadius, vPointShadowCoord[ i ] ) : 1.0;\n\t}\n\t#endif\n\t#if NUM_RECT_AREA_LIGHTS > 0\n\t#endif\n\t#endif\n\treturn shadow;\n}\n", +skinbase_vertex:"#ifdef USE_SKINNING\n\tmat4 boneMatX = getBoneMatrix( skinIndex.x );\n\tmat4 boneMatY = getBoneMatrix( skinIndex.y );\n\tmat4 boneMatZ = getBoneMatrix( skinIndex.z );\n\tmat4 boneMatW = getBoneMatrix( skinIndex.w );\n#endif",skinning_pars_vertex:"#ifdef USE_SKINNING\n\tuniform mat4 bindMatrix;\n\tuniform mat4 bindMatrixInverse;\n\t#ifdef BONE_TEXTURE\n\t\tuniform sampler2D boneTexture;\n\t\tuniform int boneTextureWidth;\n\t\tuniform int boneTextureHeight;\n\t\tmat4 getBoneMatrix( const in float i ) {\n\t\t\tfloat j = i * 4.0;\n\t\t\tfloat x = mod( j, float( boneTextureWidth ) );\n\t\t\tfloat y = floor( j / float( boneTextureWidth ) );\n\t\t\tfloat dx = 1.0 / float( boneTextureWidth );\n\t\t\tfloat dy = 1.0 / float( boneTextureHeight );\n\t\t\ty = dy * ( y + 0.5 );\n\t\t\tvec4 v1 = texture2D( boneTexture, vec2( dx * ( x + 0.5 ), y ) );\n\t\t\tvec4 v2 = texture2D( boneTexture, vec2( dx * ( x + 1.5 ), y ) );\n\t\t\tvec4 v3 = texture2D( boneTexture, vec2( dx * ( x + 2.5 ), y ) );\n\t\t\tvec4 v4 = texture2D( boneTexture, vec2( dx * ( x + 3.5 ), y ) );\n\t\t\tmat4 bone = mat4( v1, v2, v3, v4 );\n\t\t\treturn bone;\n\t\t}\n\t#else\n\t\tuniform mat4 boneMatrices[ MAX_BONES ];\n\t\tmat4 getBoneMatrix( const in float i ) {\n\t\t\tmat4 bone = boneMatrices[ int(i) ];\n\t\t\treturn bone;\n\t\t}\n\t#endif\n#endif\n", +skinning_vertex:"#ifdef USE_SKINNING\n\tvec4 skinVertex = bindMatrix * vec4( transformed, 1.0 );\n\tvec4 skinned = vec4( 0.0 );\n\tskinned += boneMatX * skinVertex * skinWeight.x;\n\tskinned += boneMatY * skinVertex * skinWeight.y;\n\tskinned += boneMatZ * skinVertex * skinWeight.z;\n\tskinned += boneMatW * skinVertex * skinWeight.w;\n\tskinned = bindMatrixInverse * skinned;\n#endif\n",skinnormal_vertex:"#ifdef USE_SKINNING\n\tmat4 skinMatrix = mat4( 0.0 );\n\tskinMatrix += skinWeight.x * boneMatX;\n\tskinMatrix += skinWeight.y * boneMatY;\n\tskinMatrix += skinWeight.z * boneMatZ;\n\tskinMatrix += skinWeight.w * boneMatW;\n\tskinMatrix = bindMatrixInverse * skinMatrix * bindMatrix;\n\tobjectNormal = vec4( skinMatrix * vec4( objectNormal, 0.0 ) ).xyz;\n#endif\n", +specularmap_fragment:"float specularStrength;\n#ifdef USE_SPECULARMAP\n\tvec4 texelSpecular = texture2D( specularMap, vUv );\n\tspecularStrength = texelSpecular.r;\n#else\n\tspecularStrength = 1.0;\n#endif",specularmap_pars_fragment:"#ifdef USE_SPECULARMAP\n\tuniform sampler2D specularMap;\n#endif",tonemapping_fragment:"#if defined( TONE_MAPPING )\n gl_FragColor.rgb = toneMapping( gl_FragColor.rgb );\n#endif\n",tonemapping_pars_fragment:"#define saturate(a) clamp( a, 0.0, 1.0 )\nuniform float toneMappingExposure;\nuniform float toneMappingWhitePoint;\nvec3 LinearToneMapping( vec3 color ) {\n return toneMappingExposure * color;\n}\nvec3 ReinhardToneMapping( vec3 color ) {\n color *= toneMappingExposure;\n return saturate( color / ( vec3( 1.0 ) + color ) );\n}\n#define Uncharted2Helper( x ) max( ( ( x * ( 0.15 * x + 0.10 * 0.50 ) + 0.20 * 0.02 ) / ( x * ( 0.15 * x + 0.50 ) + 0.20 * 0.30 ) ) - 0.02 / 0.30, vec3( 0.0 ) )\nvec3 Uncharted2ToneMapping( vec3 color ) {\n color *= toneMappingExposure;\n return saturate( Uncharted2Helper( color ) / Uncharted2Helper( vec3( toneMappingWhitePoint ) ) );\n}\nvec3 OptimizedCineonToneMapping( vec3 color ) {\n color *= toneMappingExposure;\n color = max( vec3( 0.0 ), color - 0.004 );\n return pow( ( color * ( 6.2 * color + 0.5 ) ) / ( color * ( 6.2 * color + 1.7 ) + 0.06 ), vec3( 2.2 ) );\n}\n", +uv_pars_fragment:"#if defined( USE_MAP ) || defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( USE_SPECULARMAP ) || defined( USE_ALPHAMAP ) || defined( USE_EMISSIVEMAP ) || defined( USE_ROUGHNESSMAP ) || defined( USE_METALNESSMAP )\n\tvarying vec2 vUv;\n#endif",uv_pars_vertex:"#if defined( USE_MAP ) || defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( USE_SPECULARMAP ) || defined( USE_ALPHAMAP ) || defined( USE_EMISSIVEMAP ) || defined( USE_ROUGHNESSMAP ) || defined( USE_METALNESSMAP )\n\tvarying vec2 vUv;\n\tuniform vec4 offsetRepeat;\n#endif\n", +uv_vertex:"#if defined( USE_MAP ) || defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( USE_SPECULARMAP ) || defined( USE_ALPHAMAP ) || defined( USE_EMISSIVEMAP ) || defined( USE_ROUGHNESSMAP ) || defined( USE_METALNESSMAP )\n\tvUv = uv * offsetRepeat.zw + offsetRepeat.xy;\n#endif",uv2_pars_fragment:"#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\n\tvarying vec2 vUv2;\n#endif",uv2_pars_vertex:"#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\n\tattribute vec2 uv2;\n\tvarying vec2 vUv2;\n#endif", +uv2_vertex:"#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\n\tvUv2 = uv2;\n#endif",worldpos_vertex:"#if defined( USE_ENVMAP ) || defined( PHONG ) || defined( PHYSICAL ) || defined( LAMBERT ) || defined ( USE_SHADOWMAP )\n\t#ifdef USE_SKINNING\n\t\tvec4 worldPosition = modelMatrix * skinned;\n\t#else\n\t\tvec4 worldPosition = modelMatrix * vec4( transformed, 1.0 );\n\t#endif\n#endif\n",cube_frag:"uniform samplerCube tCube;\nuniform float tFlip;\nuniform float opacity;\nvarying vec3 vWorldPosition;\n#include \nvoid main() {\n\tgl_FragColor = textureCube( tCube, vec3( tFlip * vWorldPosition.x, vWorldPosition.yz ) );\n\tgl_FragColor.a *= opacity;\n}\n", +cube_vert:"varying vec3 vWorldPosition;\n#include \nvoid main() {\n\tvWorldPosition = transformDirection( position, modelMatrix );\n\t#include \n\t#include \n}\n",depth_frag:"#if DEPTH_PACKING == 3200\n\tuniform float opacity;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( 1.0 );\n\t#if DEPTH_PACKING == 3200\n\t\tdiffuseColor.a = opacity;\n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#if DEPTH_PACKING == 3200\n\t\tgl_FragColor = vec4( vec3( gl_FragCoord.z ), opacity );\n\t#elif DEPTH_PACKING == 3201\n\t\tgl_FragColor = packDepthToRGBA( gl_FragCoord.z );\n\t#endif\n}\n", +depth_vert:"#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}\n", +distanceRGBA_frag:"uniform vec3 lightPos;\nvarying vec4 vWorldPosition;\n#include \n#include \n#include \nvoid main () {\n\t#include \n\tgl_FragColor = packDepthToRGBA( length( vWorldPosition.xyz - lightPos.xyz ) / 1000.0 );\n}\n",distanceRGBA_vert:"varying vec4 vWorldPosition;\n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvWorldPosition = worldPosition;\n}\n", +equirect_frag:"uniform sampler2D tEquirect;\nuniform float tFlip;\nvarying vec3 vWorldPosition;\n#include \nvoid main() {\n\tvec3 direction = normalize( vWorldPosition );\n\tvec2 sampleUV;\n\tsampleUV.y = saturate( tFlip * direction.y * -0.5 + 0.5 );\n\tsampleUV.x = atan( direction.z, direction.x ) * RECIPROCAL_PI2 + 0.5;\n\tgl_FragColor = texture2D( tEquirect, sampleUV );\n}\n",equirect_vert:"varying vec3 vWorldPosition;\n#include \nvoid main() {\n\tvWorldPosition = transformDirection( position, modelMatrix );\n\t#include \n\t#include \n}\n", +linedashed_frag:"uniform vec3 diffuse;\nuniform float opacity;\nuniform float dashSize;\nuniform float totalSize;\nvarying float vLineDistance;\n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tif ( mod( vLineDistance, totalSize ) > dashSize ) {\n\t\tdiscard;\n\t}\n\tvec3 outgoingLight = vec3( 0.0 );\n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\toutgoingLight = diffuseColor.rgb;\n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n\t#include \n}\n", +linedashed_vert:"uniform float scale;\nattribute float lineDistance;\nvarying float vLineDistance;\n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvLineDistance = scale * lineDistance;\n\tvec4 mvPosition = modelViewMatrix * vec4( position, 1.0 );\n\tgl_Position = projectionMatrix * mvPosition;\n\t#include \n\t#include \n}\n",meshbasic_frag:"uniform vec3 diffuse;\nuniform float opacity;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\t#ifdef USE_LIGHTMAP\n\t\treflectedLight.indirectDiffuse += texture2D( lightMap, vUv2 ).xyz * lightMapIntensity;\n\t#else\n\t\treflectedLight.indirectDiffuse += vec3( 1.0 );\n\t#endif\n\t#include \n\treflectedLight.indirectDiffuse *= diffuseColor.rgb;\n\tvec3 outgoingLight = reflectedLight.indirectDiffuse;\n\t#include \n\t#include \n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n\t#include \n}\n", +meshbasic_vert:"#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#ifdef USE_ENVMAP\n\t#include \n\t#include \n\t#include \n\t#include \n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}\n", +meshlambert_frag:"uniform vec3 diffuse;\nuniform vec3 emissive;\nuniform float opacity;\nvarying vec3 vLightFront;\n#ifdef DOUBLE_SIDED\n\tvarying vec3 vLightBack;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\tvec3 totalEmissiveRadiance = emissive;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\treflectedLight.indirectDiffuse = getAmbientLightIrradiance( ambientLightColor );\n\t#include \n\treflectedLight.indirectDiffuse *= BRDF_Diffuse_Lambert( diffuseColor.rgb );\n\t#ifdef DOUBLE_SIDED\n\t\treflectedLight.directDiffuse = ( gl_FrontFacing ) ? vLightFront : vLightBack;\n\t#else\n\t\treflectedLight.directDiffuse = vLightFront;\n\t#endif\n\treflectedLight.directDiffuse *= BRDF_Diffuse_Lambert( diffuseColor.rgb ) * getShadowMask();\n\t#include \n\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + totalEmissiveRadiance;\n\t#include \n\t#include \n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n\t#include \n}\n", +meshlambert_vert:"#define LAMBERT\nvarying vec3 vLightFront;\n#ifdef DOUBLE_SIDED\n\tvarying vec3 vLightBack;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}\n", +meshphong_frag:"#define PHONG\nuniform vec3 diffuse;\nuniform vec3 emissive;\nuniform vec3 specular;\nuniform float shininess;\nuniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\tvec3 totalEmissiveRadiance = emissive;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + reflectedLight.directSpecular + reflectedLight.indirectSpecular + totalEmissiveRadiance;\n\t#include \n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n\t#include \n}\n", +meshphong_vert:"#define PHONG\nvarying vec3 vViewPosition;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n#ifndef FLAT_SHADED\n\tvNormal = normalize( transformedNormal );\n#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvViewPosition = - mvPosition.xyz;\n\t#include \n\t#include \n\t#include \n}\n", +meshphysical_frag:"#define PHYSICAL\nuniform vec3 diffuse;\nuniform vec3 emissive;\nuniform float roughness;\nuniform float metalness;\nuniform float opacity;\n#ifndef STANDARD\n\tuniform float clearCoat;\n\tuniform float clearCoatRoughness;\n#endif\nvarying vec3 vViewPosition;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\tvec3 totalEmissiveRadiance = emissive;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + reflectedLight.directSpecular + reflectedLight.indirectSpecular + totalEmissiveRadiance;\n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n\t#include \n}\n", +meshphysical_vert:"#define PHYSICAL\nvarying vec3 vViewPosition;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n#ifndef FLAT_SHADED\n\tvNormal = normalize( transformedNormal );\n#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvViewPosition = - mvPosition.xyz;\n\t#include \n\t#include \n}\n", +normal_frag:"#define NORMAL\nuniform float opacity;\n#if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( USE_NORMALMAP )\n\tvarying vec3 vViewPosition;\n#endif\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\tgl_FragColor = vec4( packNormalToRGB( normal ), opacity );\n\t#include \n\t#include \n}\n", +normal_vert:"#define NORMAL\n#if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( USE_NORMALMAP )\n\tvarying vec3 vViewPosition;\n#endif\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n#ifndef FLAT_SHADED\n\tvNormal = normalize( transformedNormal );\n#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n#if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( USE_NORMALMAP )\n\tvViewPosition = - mvPosition.xyz;\n#endif\n}\n", +points_frag:"uniform vec3 diffuse;\nuniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec3 outgoingLight = vec3( 0.0 );\n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\t#include \n\t#include \n\toutgoingLight = diffuseColor.rgb;\n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n\t#include \n}\n", +points_vert:"uniform float size;\nuniform float scale;\n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#ifdef USE_SIZEATTENUATION\n\t\tgl_PointSize = size * ( scale / - mvPosition.z );\n\t#else\n\t\tgl_PointSize = size;\n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n}\n", +shadow_frag:"uniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\tgl_FragColor = vec4( 0.0, 0.0, 0.0, opacity * ( 1.0 - getShadowMask() ) );\n}\n",shadow_vert:"#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n}\n"};N.prototype={constructor:N, +isColor:!0,r:1,g:1,b:1,set:function(a){a&&a.isColor?this.copy(a):"number"===typeof a?this.setHex(a):"string"===typeof a&&this.setStyle(a);return this},setScalar:function(a){this.b=this.g=this.r=a;return this},setHex:function(a){a=Math.floor(a);this.r=(a>>16&255)/255;this.g=(a>>8&255)/255;this.b=(a&255)/255;return this},setRGB:function(a,b,c){this.r=a;this.g=b;this.b=c;return this},setHSL:function(){function a(a,c,d){0>d&&(d+=1);1d?c:d<2/3?a+6*(c-a)*(2/3-d):a}return function(b, +c,d){b=Q.euclideanModulo(b,1);c=Q.clamp(c,0,1);d=Q.clamp(d,0,1);0===c?this.r=this.g=this.b=d:(c=.5>=d?d*(1+c):d+c-d*c,d=2*d-c,this.r=a(d,c,b+1/3),this.g=a(d,c,b),this.b=a(d,c,b-1/3));return this}}(),setStyle:function(a){function b(b){void 0!==b&&1>parseFloat(b)&&console.warn("THREE.Color: Alpha component of "+a+" will be ignored.")}var c;if(c=/^((?:rgb|hsl)a?)\(\s*([^\)]*)\)/.exec(a)){var d=c[2];switch(c[1]){case "rgb":case "rgba":if(c=/^(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*(,\s*([0-9]*\.?[0-9]+)\s*)?$/.exec(d))return this.r= +Math.min(255,parseInt(c[1],10))/255,this.g=Math.min(255,parseInt(c[2],10))/255,this.b=Math.min(255,parseInt(c[3],10))/255,b(c[5]),this;if(c=/^(\d+)\%\s*,\s*(\d+)\%\s*,\s*(\d+)\%\s*(,\s*([0-9]*\.?[0-9]+)\s*)?$/.exec(d))return this.r=Math.min(100,parseInt(c[1],10))/100,this.g=Math.min(100,parseInt(c[2],10))/100,this.b=Math.min(100,parseInt(c[3],10))/100,b(c[5]),this;break;case "hsl":case "hsla":if(c=/^([0-9]*\.?[0-9]+)\s*,\s*(\d+)\%\s*,\s*(\d+)\%\s*(,\s*([0-9]*\.?[0-9]+)\s*)?$/.exec(d)){var d=parseFloat(c[1])/ +360,e=parseInt(c[2],10)/100,f=parseInt(c[3],10)/100;b(c[5]);return this.setHSL(d,e,f)}}}else if(c=/^\#([A-Fa-f0-9]+)$/.exec(a)){c=c[1];d=c.length;if(3===d)return this.r=parseInt(c.charAt(0)+c.charAt(0),16)/255,this.g=parseInt(c.charAt(1)+c.charAt(1),16)/255,this.b=parseInt(c.charAt(2)+c.charAt(2),16)/255,this;if(6===d)return this.r=parseInt(c.charAt(0)+c.charAt(1),16)/255,this.g=parseInt(c.charAt(2)+c.charAt(3),16)/255,this.b=parseInt(c.charAt(4)+c.charAt(5),16)/255,this}a&&0=h?k/(e+f): +k/(2-e-f);switch(e){case b:g=(c-d)/k+(cthis.max.x||a.ythis.max.y?!1:!0},containsBox:function(a){return this.min.x<=a.min.x&&a.max.x<=this.max.x&&this.min.y<=a.min.y&&a.max.y<=this.max.y},getParameter:function(a,b){return(b||new C).set((a.x-this.min.x)/(this.max.x-this.min.x),(a.y-this.min.y)/(this.max.y- +this.min.y))},intersectsBox:function(a){return a.max.xthis.max.x||a.max.ythis.max.y?!1:!0},clampPoint:function(a,b){return(b||new C).copy(a).clamp(this.min,this.max)},distanceToPoint:function(){var a=new C;return function(b){return a.copy(b).clamp(this.min,this.max).sub(b).length()}}(),intersect:function(a){this.min.max(a.min);this.max.min(a.max);return this},union:function(a){this.min.min(a.min);this.max.max(a.max);return this},translate:function(a){this.min.add(a); +this.max.add(a);return this},equals:function(a){return a.min.equals(this.min)&&a.max.equals(this.max)}};var pf=0;W.prototype={constructor:W,isMaterial:!0,get needsUpdate(){return this._needsUpdate},set needsUpdate(a){!0===a&&this.update();this._needsUpdate=a},setValues:function(a){if(void 0!==a)for(var b in a){var c=a[b];if(void 0===c)console.warn("THREE.Material: '"+b+"' parameter is undefined.");else{var d=this[b];void 0===d?console.warn("THREE."+this.type+": '"+b+"' is not a property of this material."): +d&&d.isColor?d.set(c):d&&d.isVector3&&c&&c.isVector3?d.copy(c):this[b]="overdraw"===b?Number(c):c}}},toJSON:function(a){function b(a){var b=[],c;for(c in a){var d=a[c];delete d.metadata;b.push(d)}return b}var c=void 0===a;c&&(a={textures:{},images:{}});var d={metadata:{version:4.4,type:"Material",generator:"Material.toJSON"}};d.uuid=this.uuid;d.type=this.type;""!==this.name&&(d.name=this.name);this.color&&this.color.isColor&&(d.color=this.color.getHex());void 0!==this.roughness&&(d.roughness=this.roughness); +void 0!==this.metalness&&(d.metalness=this.metalness);this.emissive&&this.emissive.isColor&&(d.emissive=this.emissive.getHex());this.specular&&this.specular.isColor&&(d.specular=this.specular.getHex());void 0!==this.shininess&&(d.shininess=this.shininess);void 0!==this.clearCoat&&(d.clearCoat=this.clearCoat);void 0!==this.clearCoatRoughness&&(d.clearCoatRoughness=this.clearCoatRoughness);this.map&&this.map.isTexture&&(d.map=this.map.toJSON(a).uuid);this.alphaMap&&this.alphaMap.isTexture&&(d.alphaMap= +this.alphaMap.toJSON(a).uuid);this.lightMap&&this.lightMap.isTexture&&(d.lightMap=this.lightMap.toJSON(a).uuid);this.bumpMap&&this.bumpMap.isTexture&&(d.bumpMap=this.bumpMap.toJSON(a).uuid,d.bumpScale=this.bumpScale);this.normalMap&&this.normalMap.isTexture&&(d.normalMap=this.normalMap.toJSON(a).uuid,d.normalScale=this.normalScale.toArray());this.displacementMap&&this.displacementMap.isTexture&&(d.displacementMap=this.displacementMap.toJSON(a).uuid,d.displacementScale=this.displacementScale,d.displacementBias= +this.displacementBias);this.roughnessMap&&this.roughnessMap.isTexture&&(d.roughnessMap=this.roughnessMap.toJSON(a).uuid);this.metalnessMap&&this.metalnessMap.isTexture&&(d.metalnessMap=this.metalnessMap.toJSON(a).uuid);this.emissiveMap&&this.emissiveMap.isTexture&&(d.emissiveMap=this.emissiveMap.toJSON(a).uuid);this.specularMap&&this.specularMap.isTexture&&(d.specularMap=this.specularMap.toJSON(a).uuid);this.envMap&&this.envMap.isTexture&&(d.envMap=this.envMap.toJSON(a).uuid,d.reflectivity=this.reflectivity); +this.gradientMap&&this.gradientMap.isTexture&&(d.gradientMap=this.gradientMap.toJSON(a).uuid);void 0!==this.size&&(d.size=this.size);void 0!==this.sizeAttenuation&&(d.sizeAttenuation=this.sizeAttenuation);1!==this.blending&&(d.blending=this.blending);2!==this.shading&&(d.shading=this.shading);0!==this.side&&(d.side=this.side);0!==this.vertexColors&&(d.vertexColors=this.vertexColors);1>this.opacity&&(d.opacity=this.opacity);!0===this.transparent&&(d.transparent=this.transparent);d.depthFunc=this.depthFunc; +d.depthTest=this.depthTest;d.depthWrite=this.depthWrite;0e&&(e=m);l>f&&(f=l);p>g&&(g=p)}this.min.set(b,c,d);this.max.set(e,f,g)},setFromBufferAttribute:function(a){for(var b=Infinity,c=Infinity,d=Infinity,e=-Infinity,f=-Infinity,g=-Infinity,h=0,k=a.count;he&&(e=m);l>f&&(f=l);p>g&&(g=p)}this.min.set(b,c,d);this.max.set(e,f,g)},setFromPoints:function(a){this.makeEmpty();for(var b=0,c=a.length;bthis.max.x||a.ythis.max.y||a.zthis.max.z?!1:!0},containsBox:function(a){return this.min.x<=a.min.x&&a.max.x<=this.max.x&&this.min.y<=a.min.y&&a.max.y<=this.max.y&&this.min.z<=a.min.z&&a.max.z<=this.max.z},getParameter:function(a,b){return(b||new q).set((a.x-this.min.x)/(this.max.x-this.min.x),(a.y-this.min.y)/ +(this.max.y-this.min.y),(a.z-this.min.z)/(this.max.z-this.min.z))},intersectsBox:function(a){return a.max.xthis.max.x||a.max.ythis.max.y||a.max.zthis.max.z?!1:!0},intersectsSphere:function(){var a;return function(b){void 0===a&&(a=new q);this.clampPoint(b.center,a);return a.distanceToSquared(b.center)<=b.radius*b.radius}}(),intersectsPlane:function(a){var b,c;0=a.constant},clampPoint:function(a,b){return(b||new q).copy(a).clamp(this.min,this.max)},distanceToPoint:function(){var a=new q;return function(b){return a.copy(b).clamp(this.min,this.max).sub(b).length()}}(), +getBoundingSphere:function(){var a=new q;return function(b){b=b||new Fa;this.getCenter(b.center);b.radius=.5*this.getSize(a).length();return b}}(),intersect:function(a){this.min.max(a.min);this.max.min(a.max);this.isEmpty()&&this.makeEmpty();return this},union:function(a){this.min.min(a.min);this.max.max(a.max);return this},applyMatrix4:function(){var a=[new q,new q,new q,new q,new q,new q,new q,new q];return function(b){if(this.isEmpty())return this;a[0].set(this.min.x,this.min.y,this.min.z).applyMatrix4(b); +a[1].set(this.min.x,this.min.y,this.max.z).applyMatrix4(b);a[2].set(this.min.x,this.max.y,this.min.z).applyMatrix4(b);a[3].set(this.min.x,this.max.y,this.max.z).applyMatrix4(b);a[4].set(this.max.x,this.min.y,this.min.z).applyMatrix4(b);a[5].set(this.max.x,this.min.y,this.max.z).applyMatrix4(b);a[6].set(this.max.x,this.max.y,this.min.z).applyMatrix4(b);a[7].set(this.max.x,this.max.y,this.max.z).applyMatrix4(b);this.setFromPoints(a);return this}}(),translate:function(a){this.min.add(a);this.max.add(a); +return this},equals:function(a){return a.min.equals(this.min)&&a.max.equals(this.max)}};Fa.prototype={constructor:Fa,set:function(a,b){this.center.copy(a);this.radius=b;return this},setFromPoints:function(){var a=new ya;return function(b,c){var d=this.center;void 0!==c?d.copy(c):a.setFromPoints(b).getCenter(d);for(var e=0,f=0,g=b.length;f=this.radius},containsPoint:function(a){return a.distanceToSquared(this.center)<=this.radius*this.radius},distanceToPoint:function(a){return a.distanceTo(this.center)-this.radius},intersectsSphere:function(a){var b=this.radius+a.radius;return a.center.distanceToSquared(this.center)<=b*b},intersectsBox:function(a){return a.intersectsSphere(this)},intersectsPlane:function(a){return Math.abs(this.center.dot(a.normal)-a.constant)<=this.radius}, +clampPoint:function(a,b){var c=this.center.distanceToSquared(a),d=b||new q;d.copy(a);c>this.radius*this.radius&&(d.sub(this.center).normalize(),d.multiplyScalar(this.radius).add(this.center));return d},getBoundingBox:function(a){a=a||new ya;a.set(this.center,this.center);a.expandByScalar(this.radius);return a},applyMatrix4:function(a){this.center.applyMatrix4(a);this.radius*=a.getMaxScaleOnAxis();return this},translate:function(a){this.center.add(a);return this},equals:function(a){return a.center.equals(this.center)&& +a.radius===this.radius}};za.prototype={constructor:za,isMatrix3:!0,set:function(a,b,c,d,e,f,g,h,k){var m=this.elements;m[0]=a;m[1]=d;m[2]=g;m[3]=b;m[4]=e;m[5]=h;m[6]=c;m[7]=f;m[8]=k;return this},identity:function(){this.set(1,0,0,0,1,0,0,0,1);return this},clone:function(){return(new this.constructor).fromArray(this.elements)},copy:function(a){a=a.elements;this.set(a[0],a[3],a[6],a[1],a[4],a[7],a[2],a[5],a[8]);return this},setFromMatrix4:function(a){a=a.elements;this.set(a[0],a[4],a[8],a[1],a[5],a[9], +a[2],a[6],a[10]);return this},applyToVector3Array:function(){var a;return function(b,c,d){void 0===a&&(a=new q);void 0===c&&(c=0);void 0===d&&(d=b.length);for(var e=0;ec;c++)this.elements[c]=a[c+b];return this},toArray:function(a,b){void 0===a&&(a=[]);void 0===b&&(b=0);var c=this.elements;a[b]=c[0];a[b+1]=c[1];a[b+2]=c[2];a[b+3]=c[3];a[b+4]=c[4];a[b+5]=c[5];a[b+6]=c[6];a[b+7]=c[7];a[b+8]=c[8];return a}};ma.prototype={constructor:ma,set:function(a,b){this.normal.copy(a); +this.constant=b;return this},setComponents:function(a,b,c,d){this.normal.set(a,b,c);this.constant=d;return this},setFromNormalAndCoplanarPoint:function(a,b){this.normal.copy(a);this.constant=-b.dot(this.normal);return this},setFromCoplanarPoints:function(){var a=new q,b=new q;return function(c,d,e){d=a.subVectors(e,d).cross(b.subVectors(c,d)).normalize();this.setFromNormalAndCoplanarPoint(d,c);return this}}(),clone:function(){return(new this.constructor).copy(this)},copy:function(a){this.normal.copy(a.normal); +this.constant=a.constant;return this},normalize:function(){var a=1/this.normal.length();this.normal.multiplyScalar(a);this.constant*=a;return this},negate:function(){this.constant*=-1;this.normal.negate();return this},distanceToPoint:function(a){return this.normal.dot(a)+this.constant},distanceToSphere:function(a){return this.distanceToPoint(a.center)-a.radius},projectPoint:function(a,b){return this.orthoPoint(a,b).sub(a).negate()},orthoPoint:function(a,b){var c=this.distanceToPoint(a);return(b|| +new q).copy(this.normal).multiplyScalar(c)},intersectLine:function(){var a=new q;return function(b,c){var d=c||new q,e=b.delta(a),f=this.normal.dot(e);if(0===f){if(0===this.distanceToPoint(b.start))return d.copy(b.start)}else return f=-(b.start.dot(this.normal)+this.constant)/f,0>f||1b&&0a&&0c;c++)b[c].copy(a.planes[c]);return this},setFromMatrix:function(a){var b=this.planes,c=a.elements;a=c[0];var d=c[1],e=c[2],f=c[3],g=c[4],h=c[5],k=c[6],m=c[7],l=c[8],p=c[9],n=c[10],r=c[11],q=c[12],u=c[13],F=c[14],c=c[15]; +b[0].setComponents(f-a,m-g,r-l,c-q).normalize();b[1].setComponents(f+a,m+g,r+l,c+q).normalize();b[2].setComponents(f+d,m+h,r+p,c+u).normalize();b[3].setComponents(f-d,m-h,r-p,c-u).normalize();b[4].setComponents(f-e,m-k,r-n,c-F).normalize();b[5].setComponents(f+e,m+k,r+n,c+F).normalize();return this},intersectsObject:function(){var a=new Fa;return function(b){var c=b.geometry;null===c.boundingSphere&&c.computeBoundingSphere();a.copy(c.boundingSphere).applyMatrix4(b.matrixWorld);return this.intersectsSphere(a)}}(), +intersectsSprite:function(){var a=new Fa;return function(b){a.center.set(0,0,0);a.radius=.7071067811865476;a.applyMatrix4(b.matrixWorld);return this.intersectsSphere(a)}}(),intersectsSphere:function(a){var b=this.planes,c=a.center;a=-a.radius;for(var d=0;6>d;d++)if(b[d].distanceToPoint(c)e;e++){var f=d[e];a.x=0g&&0>f)return!1}return!0}}(),containsPoint:function(a){for(var b=this.planes,c=0;6>c;c++)if(0>b[c].distanceToPoint(a))return!1;return!0}};bb.prototype={constructor:bb,set:function(a,b){this.origin.copy(a);this.direction.copy(b);return this},clone:function(){return(new this.constructor).copy(this)},copy:function(a){this.origin.copy(a.origin); +this.direction.copy(a.direction);return this},at:function(a,b){return(b||new q).copy(this.direction).multiplyScalar(a).add(this.origin)},lookAt:function(a){this.direction.copy(a).sub(this.origin).normalize();return this},recast:function(){var a=new q;return function(b){this.origin.copy(this.at(b,a));return this}}(),closestPointToPoint:function(a,b){var c=b||new q;c.subVectors(a,this.origin);var d=c.dot(this.direction);return 0>d?c.copy(this.origin):c.copy(this.direction).multiplyScalar(d).add(this.origin)}, +distanceToPoint:function(a){return Math.sqrt(this.distanceSqToPoint(a))},distanceSqToPoint:function(){var a=new q;return function(b){var c=a.subVectors(b,this.origin).dot(this.direction);if(0>c)return this.origin.distanceToSquared(b);a.copy(this.direction).multiplyScalar(c).add(this.origin);return a.distanceToSquared(b)}}(),distanceSqToSegment:function(){var a=new q,b=new q,c=new q;return function(d,e,f,g){a.copy(d).add(e).multiplyScalar(.5);b.copy(e).sub(d).normalize();c.copy(this.origin).sub(a); +var h=.5*d.distanceTo(e),k=-this.direction.dot(b),m=c.dot(this.direction),l=-c.dot(b),p=c.lengthSq(),n=Math.abs(1-k*k),r;0=-r?e<=r?(h=1/n,d*=h,e*=h,k=d*(d+k*e+2*m)+e*(k*d+e+2*l)+p):(e=h,d=Math.max(0,-(k*e+m)),k=-d*d+e*(e+2*l)+p):(e=-h,d=Math.max(0,-(k*e+m)),k=-d*d+e*(e+2*l)+p):e<=-r?(d=Math.max(0,-(-k*h+m)),e=0f)return null;f=Math.sqrt(f-e);e=d-f;d+=f;return 0>e&&0>d?null:0>e?this.at(d,c):this.at(e,c)}}(),intersectsSphere:function(a){return this.distanceToPoint(a.center)<= +a.radius},distanceToPlane:function(a){var b=a.normal.dot(this.direction);if(0===b)return 0===a.distanceToPoint(this.origin)?0:null;a=-(this.origin.dot(a.normal)+a.constant)/b;return 0<=a?a:null},intersectPlane:function(a,b){var c=this.distanceToPlane(a);return null===c?null:this.at(c,b)},intersectsPlane:function(a){var b=a.distanceToPoint(this.origin);return 0===b||0>a.normal.dot(this.direction)*b?!0:!1},intersectBox:function(a,b){var c,d,e,f,g;d=1/this.direction.x;f=1/this.direction.y;g=1/this.direction.z; +var h=this.origin;0<=d?(c=(a.min.x-h.x)*d,d*=a.max.x-h.x):(c=(a.max.x-h.x)*d,d*=a.min.x-h.x);0<=f?(e=(a.min.y-h.y)*f,f*=a.max.y-h.y):(e=(a.max.y-h.y)*f,f*=a.min.y-h.y);if(c>f||e>d)return null;if(e>c||c!==c)c=e;if(fg||e>d)return null;if(e>c||c!==c)c=e;if(gd?null:this.at(0<=c?c:d,b)},intersectsBox:function(){var a=new q;return function(b){return null!==this.intersectBox(b,a)}}(),intersectTriangle:function(){var a= +new q,b=new q,c=new q,d=new q;return function(e,f,g,h,k){b.subVectors(f,e);c.subVectors(g,e);d.crossVectors(b,c);f=this.direction.dot(d);if(0f)h=-1,f=-f;else return null;a.subVectors(this.origin,e);e=h*this.direction.dot(c.crossVectors(a,c));if(0>e)return null;g=h*this.direction.dot(b.cross(a));if(0>g||e+g>f)return null;e=-h*a.dot(d);return 0>e?null:this.at(e/f,k)}}(),applyMatrix4:function(a){this.direction.add(this.origin).applyMatrix4(a);this.origin.applyMatrix4(a); +this.direction.sub(this.origin);this.direction.normalize();return this},equals:function(a){return a.origin.equals(this.origin)&&a.direction.equals(this.direction)}};cb.RotationOrders="XYZ YZX ZXY XZY YXZ ZYX".split(" ");cb.DefaultOrder="XYZ";cb.prototype={constructor:cb,isEuler:!0,get x(){return this._x},set x(a){this._x=a;this.onChangeCallback()},get y(){return this._y},set y(a){this._y=a;this.onChangeCallback()},get z(){return this._z},set z(a){this._z=a;this.onChangeCallback()},get order(){return this._order}, +set order(a){this._order=a;this.onChangeCallback()},set:function(a,b,c,d){this._x=a;this._y=b;this._z=c;this._order=d||this._order;this.onChangeCallback();return this},clone:function(){return new this.constructor(this._x,this._y,this._z,this._order)},copy:function(a){this._x=a._x;this._y=a._y;this._z=a._z;this._order=a._order;this.onChangeCallback();return this},setFromRotationMatrix:function(a,b,c){var d=Q.clamp,e=a.elements;a=e[0];var f=e[4],g=e[8],h=e[1],k=e[5],m=e[9],l=e[2],p=e[6],e=e[10];b=b|| +this._order;"XYZ"===b?(this._y=Math.asin(d(g,-1,1)),.99999>Math.abs(g)?(this._x=Math.atan2(-m,e),this._z=Math.atan2(-f,a)):(this._x=Math.atan2(p,k),this._z=0)):"YXZ"===b?(this._x=Math.asin(-d(m,-1,1)),.99999>Math.abs(m)?(this._y=Math.atan2(g,e),this._z=Math.atan2(h,k)):(this._y=Math.atan2(-l,a),this._z=0)):"ZXY"===b?(this._x=Math.asin(d(p,-1,1)),.99999>Math.abs(p)?(this._y=Math.atan2(-l,e),this._z=Math.atan2(-f,k)):(this._y=0,this._z=Math.atan2(h,a))):"ZYX"===b?(this._y=Math.asin(-d(l,-1,1)),.99999> +Math.abs(l)?(this._x=Math.atan2(p,e),this._z=Math.atan2(h,a)):(this._x=0,this._z=Math.atan2(-f,k))):"YZX"===b?(this._z=Math.asin(d(h,-1,1)),.99999>Math.abs(h)?(this._x=Math.atan2(-m,k),this._y=Math.atan2(-l,a)):(this._x=0,this._y=Math.atan2(g,e))):"XZY"===b?(this._z=Math.asin(-d(f,-1,1)),.99999>Math.abs(f)?(this._x=Math.atan2(p,k),this._y=Math.atan2(g,a)):(this._x=Math.atan2(-m,e),this._y=0)):console.warn("THREE.Euler: .setFromRotationMatrix() given unsupported order: "+b);this._order=b;if(!1!==c)this.onChangeCallback(); +return this},setFromQuaternion:function(){var a;return function(b,c,d){void 0===a&&(a=new H);a.makeRotationFromQuaternion(b);return this.setFromRotationMatrix(a,c,d)}}(),setFromVector3:function(a,b){return this.set(a.x,a.y,a.z,b||this._order)},reorder:function(){var a=new da;return function(b){a.setFromEuler(this);return this.setFromQuaternion(a,b)}}(),equals:function(a){return a._x===this._x&&a._y===this._y&&a._z===this._z&&a._order===this._order},fromArray:function(a){this._x=a[0];this._y=a[1]; +this._z=a[2];void 0!==a[3]&&(this._order=a[3]);this.onChangeCallback();return this},toArray:function(a,b){void 0===a&&(a=[]);void 0===b&&(b=0);a[b]=this._x;a[b+1]=this._y;a[b+2]=this._z;a[b+3]=this._order;return a},toVector3:function(a){return a?a.set(this._x,this._y,this._z):new q(this._x,this._y,this._z)},onChange:function(a){this.onChangeCallback=a;return this},onChangeCallback:function(){}};gd.prototype={constructor:gd,set:function(a){this.mask=1<=b.x+b.y}}();Aa.prototype={constructor:Aa,set:function(a,b,c){this.a.copy(a);this.b.copy(b);this.c.copy(c);return this},setFromPointsAndIndices:function(a,b,c,d){this.a.copy(a[b]);this.b.copy(a[c]);this.c.copy(a[d]);return this},clone:function(){return(new this.constructor).copy(this)}, +copy:function(a){this.a.copy(a.a);this.b.copy(a.b);this.c.copy(a.c);return this},area:function(){var a=new q,b=new q;return function(){a.subVectors(this.c,this.b);b.subVectors(this.a,this.b);return.5*a.cross(b).length()}}(),midpoint:function(a){return(a||new q).addVectors(this.a,this.b).add(this.c).multiplyScalar(1/3)},normal:function(a){return Aa.normal(this.a,this.b,this.c,a)},plane:function(a){return(a||new ma).setFromCoplanarPoints(this.a,this.b,this.c)},barycoordFromPoint:function(a,b){return Aa.barycoordFromPoint(a, +this.a,this.b,this.c,b)},containsPoint:function(a){return Aa.containsPoint(a,this.a,this.b,this.c)},closestPointToPoint:function(){var a,b,c,d;return function(e,f){void 0===a&&(a=new ma,b=[new gb,new gb,new gb],c=new q,d=new q);var g=f||new q,h=Infinity;a.setFromCoplanarPoints(this.a,this.b,this.c);a.projectPoint(e,c);if(!0===this.containsPoint(c))g.copy(c);else{b[0].set(this.a,this.b);b[1].set(this.b,this.c);b[2].set(this.c,this.a);for(var k=0;kd;d++)if(e[d]===e[(d+1)%3]){a.push(f);break}for(f=a.length-1;0<=f;f--)for(e=a[f],this.faces.splice(e,1),c=0,g=this.faceVertexUvs.length;cb.far?null:{distance:c,point:t.clone(),object:a}}function c(c,d,e,f,m,l,p,q){g.fromArray(f,3*l);h.fromArray(f,3*p);k.fromArray(f,3*q);if(c=b(c,d,e,g,h,k,F))m&&(n.fromArray(m,2*l),r.fromArray(m,2*p),w.fromArray(m,2*q),c.uv=a(F,g,h,k,n,r,w)),c.face= +new ha(l,p,q,Aa.normal(g,h,k)),c.faceIndex=l;return c}var d=new H,e=new bb,f=new Fa,g=new q,h=new q,k=new q,m=new q,l=new q,p=new q,n=new C,r=new C,w=new C,u=new q,F=new q,t=new q;return function(q,u){var t=this.geometry,A=this.material,I=this.matrixWorld;if(void 0!==A&&(null===t.boundingSphere&&t.computeBoundingSphere(),f.copy(t.boundingSphere),f.applyMatrix4(I),!1!==q.ray.intersectsSphere(f)&&(d.getInverse(I),e.copy(q.ray).applyMatrix4(d),null===t.boundingBox||!1!==e.intersectsBox(t.boundingBox)))){var E, +K;if(t.isBufferGeometry){var y,J,A=t.index,I=t.attributes,t=I.position.array;void 0!==I.uv&&(E=I.uv.array);if(null!==A)for(var I=A.array,C=0,D=I.length;Cthis.scale.x*this.scale.y/4||c.push({distance:Math.sqrt(d),point:this.position,face:null,object:this})}}(),clone:function(){return(new this.constructor(this.material)).copy(this)}}); +Ac.prototype=Object.assign(Object.create(G.prototype),{constructor:Ac,copy:function(a){G.prototype.copy.call(this,a,!1);a=a.levels;for(var b=0,c=a.length;b=d[e].distance)d[e-1].object.visible=!1,d[e].object.visible=!0;else break; +for(;ef||(l.applyMatrix4(this.matrixWorld),u=d.ray.origin.distanceTo(l),ud.far||e.push({distance:u,point:h.clone().applyMatrix4(this.matrixWorld),index:g,face:null,faceIndex:null,object:this}))}else for(g=0,w=r.length/3-1;gf||(l.applyMatrix4(this.matrixWorld),u=d.ray.origin.distanceTo(l),ud.far||e.push({distance:u,point:h.clone().applyMatrix4(this.matrixWorld),index:g,face:null,faceIndex:null,object:this}))}else if(g.isGeometry)for(k=g.vertices,m=k.length,g=0;gf||(l.applyMatrix4(this.matrixWorld),u=d.ray.origin.distanceTo(l),ud.far||e.push({distance:u,point:h.clone().applyMatrix4(this.matrixWorld),index:g,face:null,faceIndex:null,object:this}))}}}(),clone:function(){return(new this.constructor(this.geometry,this.material)).copy(this)}});fa.prototype=Object.assign(Object.create(Va.prototype),{constructor:fa,isLineSegments:!0});Oa.prototype=Object.create(W.prototype);Oa.prototype.constructor=Oa;Oa.prototype.isPointsMaterial=!0;Oa.prototype.copy= +function(a){W.prototype.copy.call(this,a);this.color.copy(a.color);this.map=a.map;this.size=a.size;this.sizeAttenuation=a.sizeAttenuation;return this};Kb.prototype=Object.assign(Object.create(G.prototype),{constructor:Kb,isPoints:!0,raycast:function(){var a=new H,b=new bb,c=new Fa;return function(d,e){function f(a,c){var f=b.distanceSqToPoint(a);if(fd.far||e.push({distance:m,distanceToRay:Math.sqrt(f), +point:h.clone(),index:c,face:null,object:g})}}var g=this,h=this.geometry,k=this.matrixWorld,m=d.params.Points.threshold;null===h.boundingSphere&&h.computeBoundingSphere();c.copy(h.boundingSphere);c.applyMatrix4(k);if(!1!==d.ray.intersectsSphere(c)){a.getInverse(k);b.copy(d.ray).applyMatrix4(a);var m=m/((this.scale.x+this.scale.y+this.scale.z)/3),l=m*m,m=new q;if(h.isBufferGeometry){var p=h.index,h=h.attributes.position.array;if(null!==p)for(var n=p.array,p=0,r=n.length;pc)return null;var d=[],e=[],f=[],g,h,k;if(0=m--){console.warn("THREE.ShapeUtils: Unable to triangulate polygon! in triangulate()");break}g=h;c<=g&&(g=0);h=g+1;c<=h&&(h=0);k=h+1;c<=k&&(k=0);var l;a:{var p,n,r,q,u,F,t,v;p=a[e[g]].x;n=a[e[g]].y;r=a[e[h]].x;q=a[e[h]].y;u=a[e[k]].x;F=a[e[k]].y;if(0>=(r-p)*(F-n)-(q-n)*(u-p))l= +!1;else{var M,z,A,I,E,K,y,C,D,G;M=u-r;z=F-q;A=p-u;I=n-F;E=r-p;K=q-n;for(l=0;l=-Number.EPSILON&&C>=-Number.EPSILON&&y>=-Number.EPSILON)){l=!1;break a}l=!0}}if(l){d.push([a[e[g]],a[e[h]],a[e[k]]]);f.push([e[g],e[h],e[k]]);g=h;for(k=h+1;kNumber.EPSILON){if(0q||q>p)return[];k=m*l-k*n;if(0>k||k>p)return[]}else{if(0c?[]:k===c?f?[]:[g]:a<=c?[g,h]:[g,m]} +function f(a,b,c,d){var e=b.x-a.x,f=b.y-a.y;b=c.x-a.x;c=c.y-a.y;var g=d.x-a.x;d=d.y-a.y;a=e*c-f*b;e=e*d-f*g;return Math.abs(a)>Number.EPSILON?(b=g*c-d*b,0e&&(e=d);var g=a+1;g>d&&(g= +0);d=f(h[a],h[e],h[g],k[b]);if(!d)return!1;d=k.length-1;e=b-1;0>e&&(e=d);g=b+1;g>d&&(g=0);return(d=f(k[b],k[e],k[g],h[a]))?!0:!1}function d(a,b){var c,f;for(c=0;cO){console.log("Infinite Loop! Holes left:"+m.length+", Probably Hole outside Shape!");break}for(n=C;nk;k++)l=m[k].x+":"+m[k].y,l=p[l],void 0!==l&&(m[k]=l);return n.concat()},isClockWise:function(a){return 0>pa.area(a)},b2:function(){return function(a,b,c,d){var e=1-a;return e*e*b+2*(1-a)*a*c+a*a*d}}(),b3:function(){return function(a,b,c,d,e){var f=1-a,g=1-a;return f*f*f*b+3*g*g*a*c+3*(1-a)*a*a*d+a*a*a*e}}()};La.prototype=Object.create(S.prototype);La.prototype.constructor=La;La.prototype.addShapeList=function(a,b){for(var c=a.length,d=0;dNumber.EPSILON){var k=Math.sqrt(h),m=Math.sqrt(d*d+g*g),h=b.x-f/k;b=b.y+e/k;g=((c.x-g/m-h)*g-(c.y+d/m-b)*d)/(e*g-f*d);d=h+e*g-a.x;e=b+f*g-a.y;f=d*d+e*e;if(2>=f)return new C(d,e);f=Math.sqrt(f/2)}else a=!1,e>Number.EPSILON?d>Number.EPSILON&& +(a=!0):e<-Number.EPSILON?d<-Number.EPSILON&&(a=!0):Math.sign(f)===Math.sign(g)&&(a=!0),a?(d=-f,f=Math.sqrt(h)):(d=e,e=f,f=Math.sqrt(h/2));return new C(d/f,e/f)}function e(a,b){var c,d;for(L=a.length;0<=--L;){c=L;d=L-1;0>d&&(d=a.length-1);var e,f=r+2*l;for(e=0;eMath.abs(b.y-c.y)?[new C(b.x,1-b.z),new C(c.x,1-c.z),new C(d.x,1-d.z),new C(e.x,1-e.z)]:[new C(b.y,1-b.z),new C(c.y,1-c.z),new C(d.y,1-d.z),new C(e.y,1-e.z)]}};Mc.prototype=Object.create(La.prototype);Mc.prototype.constructor= +Mc;mb.prototype=Object.create(D.prototype);mb.prototype.constructor=mb;Nc.prototype=Object.create(S.prototype);Nc.prototype.constructor=Nc;Ub.prototype=Object.create(D.prototype);Ub.prototype.constructor=Ub;Oc.prototype=Object.create(S.prototype);Oc.prototype.constructor=Oc;Pc.prototype=Object.create(S.prototype);Pc.prototype.constructor=Pc;Vb.prototype=Object.create(D.prototype);Vb.prototype.constructor=Vb;Qc.prototype=Object.create(S.prototype);Qc.prototype.constructor=Qc;Wb.prototype=Object.create(D.prototype); +Wb.prototype.constructor=Wb;Xb.prototype=Object.create(S.prototype);Xb.prototype.constructor=Xb;Yb.prototype=Object.create(D.prototype);Yb.prototype.constructor=Yb;Wa.prototype=Object.create(D.prototype);Wa.prototype.constructor=Wa;nb.prototype=Object.create(S.prototype);nb.prototype.constructor=nb;Rc.prototype=Object.create(nb.prototype);Rc.prototype.constructor=Rc;Sc.prototype=Object.create(Wa.prototype);Sc.prototype.constructor=Sc;Zb.prototype=Object.create(D.prototype);Zb.prototype.constructor= +Zb;Tc.prototype=Object.create(S.prototype);Tc.prototype.constructor=Tc;$b.prototype=Object.create(S.prototype);$b.prototype.constructor=$b;var Ea=Object.freeze({WireframeGeometry:Mb,ParametricGeometry:Dc,ParametricBufferGeometry:Nb,TetrahedronGeometry:Ec,TetrahedronBufferGeometry:Ob,OctahedronGeometry:Fc,OctahedronBufferGeometry:lb,IcosahedronGeometry:Gc,IcosahedronBufferGeometry:Pb,DodecahedronGeometry:Hc,DodecahedronBufferGeometry:Qb,PolyhedronGeometry:Ic,PolyhedronBufferGeometry:xa,TubeGeometry:Jc, +TubeBufferGeometry:Rb,TorusKnotGeometry:Kc,TorusKnotBufferGeometry:Sb,TorusGeometry:Lc,TorusBufferGeometry:Tb,TextGeometry:Mc,SphereBufferGeometry:mb,SphereGeometry:Nc,RingGeometry:Oc,RingBufferGeometry:Ub,PlaneBufferGeometry:ib,PlaneGeometry:Pc,LatheGeometry:Qc,LatheBufferGeometry:Vb,ShapeGeometry:Xb,ShapeBufferGeometry:Wb,ExtrudeGeometry:La,EdgesGeometry:Yb,ConeGeometry:Rc,ConeBufferGeometry:Sc,CylinderGeometry:nb,CylinderBufferGeometry:Wa,CircleBufferGeometry:Zb,CircleGeometry:Tc,BoxBufferGeometry:hb, +BoxGeometry:$b});ac.prototype=Object.create(Ia.prototype);ac.prototype.constructor=ac;ac.prototype.isShadowMaterial=!0;bc.prototype=Object.create(Ia.prototype);bc.prototype.constructor=bc;bc.prototype.isRawShaderMaterial=!0;Uc.prototype={constructor:Uc,isMultiMaterial:!0,toJSON:function(a){for(var b={metadata:{version:4.2,type:"material",generator:"MaterialExporter"},uuid:this.uuid,type:this.type,materials:[]},c=this.materials,d=0,e=c.length;d=e)break a;else{f=b[1];a=e)break b}d=c;c=0}}for(;c>>1,ab;)--f;++f;if(0!==e||f!==d)e>=f&&(f=Math.max(f,1),e=f-1),d=this.getValueSize(),this.times=ba.arraySlice(c,e,f),this.values=ba.arraySlice(this.values,e*d,f*d);return this},validate:function(){var a=!0,b=this.getValueSize();0!==b-Math.floor(b)&&(console.error("invalid value size in track",this),a=!1);var c=this.times,b=this.values,d=c.length;0===d&&(console.error("track is empty", +this),a=!1);for(var e=null,f=0;f!==d;f++){var g=c[f];if("number"===typeof g&&isNaN(g)){console.error("time is not a valid number",this,f,g);a=!1;break}if(null!==e&&e>g){console.error("out of order keys",this,f,g,e);a=!1;break}e=g}if(void 0!==b&&ba.isTypedArray(b))for(f=0,c=b.length;f!==c;++f)if(d=b[f],isNaN(d)){console.error("value is not a valid number",this,f,d);a=!1;break}return a},optimize:function(){for(var a=this.times,b=this.values,c=this.getValueSize(),d=2302===this.getInterpolation(),e=1, +f=a.length-1,g=1;gk.opacity&&(k.transparent=!0);c.setTextures(h);return c.parse(k)}}()};wb.Handlers={handlers:[],add:function(a,b){this.handlers.push(a,b)},get:function(a){for(var b=this.handlers,c=0,d=b.length;cg;g++)n=v[k++],t=F[2*n],n=F[2*n+1],t=new C(t,n),2!==g&&c.faceVertexUvs[d][h].push(t),0!==g&&c.faceVertexUvs[d][h+1].push(t);p&&(p=3*v[k++],r.normal.set(y[p++],y[p++],y[p]),u.normal.copy(r.normal));if(w)for(d=0;4>d;d++)p=3*v[k++],w=new q(y[p++],y[p++],y[p]),2!==d&&r.vertexNormals.push(w),0!==d&&u.vertexNormals.push(w);l&&(l=v[k++], +l=z[l],r.color.setHex(l),u.color.setHex(l));if(b)for(d=0;4>d;d++)l=v[k++],l=z[l],2!==d&&r.vertexColors.push(new N(l)),0!==d&&u.vertexColors.push(new N(l));c.faces.push(r);c.faces.push(u)}else{r=new ha;r.a=v[k++];r.b=v[k++];r.c=v[k++];h&&(h=v[k++],r.materialIndex=h);h=c.faces.length;if(d)for(d=0;dg;g++)n=v[k++],t=F[2*n],n=F[2*n+1],t=new C(t,n),c.faceVertexUvs[d][h].push(t);p&&(p=3*v[k++],r.normal.set(y[p++],y[p++],y[p]));if(w)for(d=0;3>d;d++)p=3* +v[k++],w=new q(y[p++],y[p++],y[p]),r.vertexNormals.push(w);l&&(l=v[k++],r.color.setHex(z[l]));if(b)for(d=0;3>d;d++)l=v[k++],r.vertexColors.push(new N(z[l]));c.faces.push(r)}})(d);(function(){var b=void 0!==a.influencesPerVertex?a.influencesPerVertex:2;if(a.skinWeights)for(var d=0,g=a.skinWeights.length;dk)g=d+1;else if(0b&&(b=0);1Number.EPSILON&&(g.normalize(),c=Math.acos(Q.clamp(d[k-1].dot(d[k]),-1,1)),e[k].applyMatrix4(h.makeRotationAxis(g,c))),f[k].crossVectors(d[k],e[k]);if(!0===b)for(c=Math.acos(Q.clamp(e[0].dot(e[a]),-1,1)),c/=a,0=b)return b=c[a]-b,a=this.curves[a],c=a.getLength(),a.getPointAt(0===c?0:1-b/c);a++}return null},getLength:function(){var a=this.getCurveLengths();return a[a.length-1]},updateArcLengths:function(){this.needsUpdate= +!0;this.cacheLengths=null;this.getLengths()},getCurveLengths:function(){if(this.cacheLengths&&this.cacheLengths.length===this.curves.length)return this.cacheLengths;for(var a=[],b=0,c=0,d=this.curves.length;cc;)c+=b;for(;c>b;)c-=b;cb.length-2?b.length-1:c+1],b=b[c>b.length-3?b.length-1:c+2],c=ed.interpolate;return new C(c(d.x,e.x,f.x,b.x,a),c(d.y,e.y,f.y,b.y,a))};yb.prototype=Object.create(wa.prototype);yb.prototype.constructor=yb;yb.prototype.getPoint=function(a){var b=pa.b3;return new C(b(a,this.v0.x, +this.v1.x,this.v2.x,this.v3.x),b(a,this.v0.y,this.v1.y,this.v2.y,this.v3.y))};yb.prototype.getTangent=function(a){var b=ed.tangentCubicBezier;return(new C(b(a,this.v0.x,this.v1.x,this.v2.x,this.v3.x),b(a,this.v0.y,this.v1.y,this.v2.y,this.v3.y))).normalize()};zb.prototype=Object.create(wa.prototype);zb.prototype.constructor=zb;zb.prototype.getPoint=function(a){var b=pa.b2;return new C(b(a,this.v0.x,this.v1.x,this.v2.x),b(a,this.v0.y,this.v1.y,this.v2.y))};zb.prototype.getTangent=function(a){var b= +ed.tangentQuadraticBezier;return(new C(b(a,this.v0.x,this.v1.x,this.v2.x),b(a,this.v0.y,this.v1.y,this.v2.y))).normalize()};var oe=Object.assign(Object.create(Yc.prototype),{fromPoints:function(a){this.moveTo(a[0].x,a[0].y);for(var b=1,c=a.length;bNumber.EPSILON){if(0>m&&(g=b[f],k=-k,h=b[e],m=-m),!(a.yh.y))if(a.y===g.y){if(a.x===g.x)return!0}else{e=m*(a.x-g.x)-k*(a.y-g.y);if(0===e)return!0;0>e||(d=!d)}}else if(a.y===g.y&&(h.x<= +a.x&&a.x<=g.x||g.x<=a.x&&a.x<=h.x))return!0}return d}var e=pa.isClockWise,f=this.subPaths;if(0===f.length)return[];if(!0===b)return c(f);var g,h,k,m=[];if(1===f.length)return h=f[0],k=new Ab,k.curves=h.curves,m.push(k),m;var l=!e(f[0].getPoints()),l=a?!l:l;k=[];var p=[],n=[],q=0,w;p[q]=void 0;n[q]=[];for(var u=0,y=f.length;ud&& +this._mixBufferRegion(c,a,3*b,1-d,b);for(var d=b,f=b+b;d!==f;++d)if(c[d]!==c[d+b]){e.setValue(c,a);break}},saveOriginalState:function(){var a=this.buffer,b=this.valueSize,c=3*b;this.binding.getValue(a,c);for(var d=b;d!==c;++d)a[d]=a[c+d%b];this.cumulativeWeight=0},restoreOriginalState:function(){this.binding.setValue(this.buffer,3*this.valueSize)},_select:function(a,b,c,d,e){if(.5<=d)for(d=0;d!==e;++d)a[b+d]=a[c+d]},_slerp:function(a,b,c,d,e){da.slerpFlat(a,b,a,b,a,c,d)},_lerp:function(a,b,c,d,e){for(var f= +1-d,g=0;g!==e;++g){var h=b+g;a[h]=a[h]*f+a[c+g]*d}}};ka.prototype={constructor:ka,getValue:function(a,b){this.bind();this.getValue(a,b)},setValue:function(a,b){this.bind();this.setValue(a,b)},bind:function(){var a=this.node,b=this.parsedPath,c=b.objectName,d=b.propertyName,e=b.propertyIndex;a||(this.node=a=ka.findNode(this.rootNode,b.nodeName)||this.rootNode);this.getValue=this._getValue_unavailable;this.setValue=this._setValue_unavailable;if(a){if(c){var f=b.objectIndex;switch(c){case "materials":if(!a.material){console.error(" can not bind to material as node does not have a material", +this);return}if(!a.material.materials){console.error(" can not bind to material.materials as node.material does not have a materials array",this);return}a=a.material.materials;break;case "bones":if(!a.skeleton){console.error(" can not bind to bones as node does not have a skeleton",this);return}a=a.skeleton.bones;for(c=0;c=c){var p=c++,n=b[p];d[n.uuid]=q;b[q]=n;d[l]=p;b[p]= +k;k=0;for(l=f;k!==l;++k){var n=e[k],r=n[q];n[q]=n[p];n[p]=r}}}this.nCachedObjects_=c},uncache:function(a){for(var b=this._objects,c=b.length,d=this.nCachedObjects_,e=this._indicesByUUID,f=this._bindings,g=f.length,h=0,k=arguments.length;h!==k;++h){var l=arguments[h].uuid,q=e[l];if(void 0!==q)if(delete e[l],qb||0===c)return;this._startTime=null;b*=c}b*=this._updateTimeScale(a);c=this._updateTime(b);a=this._updateWeight(a);if(0c.parameterPositions[1]&&(this.stopFading(),0===d&&(this.enabled=!1))}}return this._effectiveWeight=b},_updateTimeScale:function(a){var b=0;if(!this.paused){var b=this.timeScale,c=this._timeScaleInterpolant;if(null!==c){var d=c.evaluate(a)[0],b=b*d;a>c.parameterPositions[1]&&(this.stopWarping(),0=== +b?this.paused=!0:this.timeScale=b)}}return this._effectiveTimeScale=b},_updateTime:function(a){var b=this.time+a;if(0===a)return b;var c=this._clip.duration,d=this.loop,e=this._loopCount;if(2200===d)a:{if(-1===e&&(this._loopCount=0,this._setEndings(!0,!0,!1)),b>=c)b=c;else if(0>b)b=0;else break a;this.clampWhenFinished?this.paused=!0:this.enabled=!1;this._mixer.dispatchEvent({type:"finished",action:this,direction:0>a?-1:1})}else{d=2202===d;-1===e&&(0<=a?(e=0,this._setEndings(!0,0===this.repetitions, +d)):this._setEndings(0===this.repetitions,!0,d));if(b>=c||0>b){var f=Math.floor(b/c),b=b-c*f,e=e+Math.abs(f),g=this.repetitions-e;0>g?(this.clampWhenFinished?this.paused=!0:this.enabled=!1,b=0a,this._setEndings(a,!a,d)):this._setEndings(!1,!1,d),this._loopCount=e,this._mixer.dispatchEvent({type:"loop",action:this,loopDelta:f}))}if(d&&1===(e&1))return this.time=b,c-b}return this.time=b},_setEndings:function(a, +b,c){var d=this._interpolantSettings;c?(d.endingStart=2401,d.endingEnd=2401):(d.endingStart=a?this.zeroSlopeAtStart?2401:2400:2402,d.endingEnd=b?this.zeroSlopeAtEnd?2401:2400:2402)},_scheduleFading:function(a,b,c){var d=this._mixer,e=d.time,f=this._weightInterpolant;null===f&&(this._weightInterpolant=f=d._lendControlInterpolant());d=f.parameterPositions;f=f.sampleValues;d[0]=e;f[0]=b;d[1]=e+a;f[1]=c;return this}};Object.assign(de.prototype,oa.prototype,{clipAction:function(a,b){var c=b||this._root, +d=c.uuid,e="string"===typeof a?ta.findByName(c,a):a,c=null!==e?e.uuid:a,f=this._actionsByClip[c],g=null;if(void 0!==f){g=f.actionByRoot[d];if(void 0!==g)return g;g=f.knownActions[0];null===e&&(e=g._clip)}if(null===e)return null;e=new ce(this,e,b);this._bindAction(e,g);this._addInactiveAction(e,c,d);return e},existingAction:function(a,b){var c=b||this._root,d=c.uuid,c="string"===typeof a?ta.findByName(c,a):a,c=this._actionsByClip[c?c.uuid:a];return void 0!==c?c.actionByRoot[d]||null:null},stopAllAction:function(){for(var a= +this._actions,b=this._nActiveActions,c=this._bindings,d=this._nActiveBindings,e=this._nActiveBindings=this._nActiveActions=0;e!==b;++e)a[e].reset();for(e=0;e!==d;++e)c[e].useCount=0;return this},update:function(a){a*=this.timeScale;for(var b=this._actions,c=this._nActiveActions,d=this.time+=a,e=Math.sign(a),f=this._accuIndex^=1,g=0;g!==c;++g){var h=b[g];h.enabled&&h._update(d,a,e,f)}a=this._bindings;b=this._nActiveBindings;for(g=0;g!==b;++g)a[g].apply(f);return this},getRoot:function(){return this._root}, +uncacheClip:function(a){var b=this._actions;a=a.uuid;var c=this._actionsByClip,d=c[a];if(void 0!==d){for(var d=d.knownActions,e=0,f=d.length;e!==f;++e){var g=d[e];this._deactivateAction(g);var h=g._cacheIndex,k=b[b.length-1];g._cacheIndex=null;g._byClipCacheIndex=null;k._cacheIndex=h;b[h]=k;b.pop();this._removeInactiveBindingsForAction(g)}delete c[a]}},uncacheRoot:function(a){a=a.uuid;var b=this._actionsByClip,c;for(c in b){var d=b[c].actionByRoot[a];void 0!==d&&(this._deactivateAction(d),this._removeInactiveAction(d))}c= +this._bindingsByRootAndName[a];if(void 0!==c)for(var e in c)a=c[e],a.restoreOriginalState(),this._removeInactiveBinding(a)},uncacheAction:function(a,b){var c=this.existingAction(a,b);null!==c&&(this._deactivateAction(c),this._removeInactiveAction(c))}});Object.assign(de.prototype,{_bindAction:function(a,b){var c=a._localRoot||this._root,d=a._clip.tracks,e=d.length,f=a._propertyBindings,g=a._interpolants,h=c.uuid,k=this._bindingsByRootAndName,l=k[h];void 0===l&&(l={},k[h]=l);for(k=0;k!==e;++k){var q= +d[k],p=q.name,n=l[p];if(void 0===n){n=f[k];if(void 0!==n){null===n._cacheIndex&&(++n.referenceCount,this._addInactiveBinding(n,h,p));continue}n=new Cd(ka.create(c,p,b&&b._propertyBindings[k].binding.parsedPath),q.ValueTypeName,q.getValueSize());++n.referenceCount;this._addInactiveBinding(n,h,p)}f[k]=n;g[k].resultBuffer=n.buffer}},_activateAction:function(a){if(!this._isActiveAction(a)){if(null===a._cacheIndex){var b=(a._localRoot||this._root).uuid,c=a._clip.uuid,d=this._actionsByClip[c];this._bindAction(a, +d&&d.knownActions[0]);this._addInactiveAction(a,c,b)}b=a._propertyBindings;c=0;for(d=b.length;c!==d;++c){var e=b[c];0===e.useCount++&&(this._lendBinding(e),e.saveOriginalState())}this._lendAction(a)}},_deactivateAction:function(a){if(this._isActiveAction(a)){for(var b=a._propertyBindings,c=0,d=b.length;c!==d;++c){var e=b[c];0===--e.useCount&&(e.restoreOriginalState(),this._takeBackBinding(e))}this._takeBackAction(a)}},_initMemoryManager:function(){this._actions=[];this._nActiveActions=0;this._actionsByClip= +{};this._bindings=[];this._nActiveBindings=0;this._bindingsByRootAndName={};this._controlInterpolants=[];this._nActiveControlInterpolants=0;var a=this;this.stats={actions:{get total(){return a._actions.length},get inUse(){return a._nActiveActions}},bindings:{get total(){return a._bindings.length},get inUse(){return a._nActiveBindings}},controlInterpolants:{get total(){return a._controlInterpolants.length},get inUse(){return a._nActiveControlInterpolants}}}},_isActiveAction:function(a){a=a._cacheIndex; +return null!==a&&ah.end&&(h.end=f);c||(c=k)}}for(k in d)h=d[k],this.createAnimation(k,h.start,h.end, +a);this.firstAnimation=c};ua.prototype.setAnimationDirectionForward=function(a){if(a=this.animationsMap[a])a.direction=1,a.directionBackwards=!1};ua.prototype.setAnimationDirectionBackward=function(a){if(a=this.animationsMap[a])a.direction=-1,a.directionBackwards=!0};ua.prototype.setAnimationFPS=function(a,b){var c=this.animationsMap[a];c&&(c.fps=b,c.duration=(c.end-c.start)/c.fps)};ua.prototype.setAnimationDuration=function(a,b){var c=this.animationsMap[a];c&&(c.duration=b,c.fps=(c.end-c.start)/ +c.duration)};ua.prototype.setAnimationWeight=function(a,b){var c=this.animationsMap[a];c&&(c.weight=b)};ua.prototype.setAnimationTime=function(a,b){var c=this.animationsMap[a];c&&(c.time=b)};ua.prototype.getAnimationTime=function(a){var b=0;if(a=this.animationsMap[a])b=a.time;return b};ua.prototype.getAnimationDuration=function(a){var b=-1;if(a=this.animationsMap[a])b=a.duration;return b};ua.prototype.playAnimation=function(a){var b=this.animationsMap[a];b?(b.time=0,b.active=!0):console.warn("THREE.MorphBlendMesh: animation["+ +a+"] undefined in .playAnimation()")};ua.prototype.stopAnimation=function(a){if(a=this.animationsMap[a])a.active=!1};ua.prototype.update=function(a){for(var b=0,c=this.animationsList.length;bd.duration||0>d.time)d.direction*=-1,d.time>d.duration&&(d.time=d.duration,d.directionBackwards=!0),0>d.time&&(d.time=0,d.directionBackwards=!1)}else d.time%=d.duration,0>d.time&&(d.time+= +d.duration);var f=d.start+Q.clamp(Math.floor(d.time/e),0,d.length-1),g=d.weight;f!==d.currentFrame&&(this.morphTargetInfluences[d.lastFrame]=0,this.morphTargetInfluences[d.currentFrame]=1*g,this.morphTargetInfluences[f]=0,d.lastFrame=d.currentFrame,d.currentFrame=f);e=d.time%e/e;d.directionBackwards&&(e=1-e);d.currentFrame!==d.lastFrame?(this.morphTargetInfluences[d.currentFrame]=e*g,this.morphTargetInfluences[d.lastFrame]=(1-e)*g):this.morphTargetInfluences[d.currentFrame]=g}}};$c.prototype=Object.create(G.prototype); +$c.prototype.constructor=$c;$c.prototype.isImmediateRenderObject=!0;ad.prototype=Object.create(fa.prototype);ad.prototype.constructor=ad;ad.prototype.update=function(){var a=new q,b=new q,c=new za;return function(){var d=["a","b","c"];this.object.updateMatrixWorld(!0);c.getNormalMatrix(this.object.matrixWorld);var e=this.object.matrixWorld,f=this.geometry.attributes.position,g=this.object.geometry;if(g&&g.isGeometry)for(var h=g.vertices,k=g.faces,l=g=0,q=k.length;lc.y?this.quaternion.set(1,0,0,0):(a.set(c.z,0,-c.x).normalize(), +b=Math.acos(c.y),this.quaternion.setFromAxisAngle(a,b))}}();Cb.prototype.setLength=function(a,b,c){void 0===b&&(b=.2*a);void 0===c&&(c=.2*b);this.line.scale.set(1,Math.max(0,a-b),1);this.line.updateMatrix();this.cone.scale.set(c,b,c);this.cone.position.y=a;this.cone.updateMatrix()};Cb.prototype.setColor=function(a){this.line.material.color.copy(a);this.cone.material.color.copy(a)};Fd.prototype=Object.create(fa.prototype);Fd.prototype.constructor=Fd;var ke=function(){function a(){}var b=new q,c=new a, +d=new a,e=new a;a.prototype.init=function(a,b,c,d){this.c0=a;this.c1=c;this.c2=-3*a+3*b-2*c-d;this.c3=2*a-2*b+c+d};a.prototype.initNonuniformCatmullRom=function(a,b,c,d,e,l,p){this.init(b,c,((b-a)/e-(c-a)/(e+l)+(c-b)/l)*l,((c-b)/l-(d-b)/(l+p)+(d-c)/p)*l)};a.prototype.initCatmullRom=function(a,b,c,d,e){this.init(b,c,e*(c-a),e*(d-b))};a.prototype.calc=function(a){var b=a*a;return this.c0+this.c1*a+this.c2*b+this.c3*b*a};return wa.create(function(a){this.points=a||[];this.closed=!1},function(a){var g= +this.points,h,k;k=g.length;2>k&&console.log("duh, you need at least 2 points");a*=k-(this.closed?0:1);h=Math.floor(a);a-=h;this.closed?h+=0h&&(h=1);1E-4>k&&(k=h);1E-4>n&&(n=h);c.initNonuniformCatmullRom(l.x,x.x,p.x,g.x,k,h,n);d.initNonuniformCatmullRom(l.y,x.y,p.y,g.y,k,h,n);e.initNonuniformCatmullRom(l.z,x.z,p.z,g.z,k,h,n)}else"catmullrom"===this.type&&(k=void 0!==this.tension?this.tension:.5,c.initCatmullRom(l.x,x.x,p.x,g.x,k),d.initCatmullRom(l.y,x.y,p.y,g.y,k),e.initCatmullRom(l.z,x.z,p.z,g.z,k));return new q(c.calc(a), +d.calc(a),e.calc(a))})}(),Nf=wa.create(function(a){console.warn("THREE.SplineCurve3 will be deprecated. Please use THREE.CatmullRomCurve3");this.points=void 0===a?[]:a},function(a){var b=this.points;a*=b.length-1;var c=Math.floor(a);a-=c;var d=b[0==c?c:c-1],e=b[c],f=b[c>b.length-2?b.length-1:c+1],b=b[c>b.length-3?b.length-1:c+2],c=ed.interpolate;return new q(c(d.x,e.x,f.x,b.x,a),c(d.y,e.y,f.y,b.y,a),c(d.z,e.z,f.z,b.z,a))}),Of=wa.create(function(a,b,c,d){this.v0=a;this.v1=b;this.v2=c;this.v3=d},function(a){var b= +pa.b3;return new q(b(a,this.v0.x,this.v1.x,this.v2.x,this.v3.x),b(a,this.v0.y,this.v1.y,this.v2.y,this.v3.y),b(a,this.v0.z,this.v1.z,this.v2.z,this.v3.z))}),Pf=wa.create(function(a,b,c){this.v0=a;this.v1=b;this.v2=c},function(a){var b=pa.b2;return new q(b(a,this.v0.x,this.v1.x,this.v2.x),b(a,this.v0.y,this.v1.y,this.v2.y),b(a,this.v0.z,this.v1.z,this.v2.z))}),Qf=wa.create(function(a,b){this.v1=a;this.v2=b},function(a){if(1===a)return this.v2.clone();var b=new q;b.subVectors(this.v2,this.v1);b.multiplyScalar(a); +b.add(this.v1);return b});Gd.prototype=Object.create(Xa.prototype);Gd.prototype.constructor=Gd;Le.prototype=Object.create(ke.prototype);bd.prototype.setColors=function(){console.error("THREE.GridHelper: setColors() has been deprecated, pass them in the constructor instead.")};Object.assign(pc.prototype,{center:function(a){console.warn("THREE.Box2: .center() has been renamed to .getCenter().");return this.getCenter(a)},empty:function(){console.warn("THREE.Box2: .empty() has been renamed to .isEmpty()."); +return this.isEmpty()},isIntersectionBox:function(a){console.warn("THREE.Box2: .isIntersectionBox() has been renamed to .intersectsBox().");return this.intersectsBox(a)},size:function(a){console.warn("THREE.Box2: .size() has been renamed to .getSize().");return this.getSize(a)}});Object.assign(ya.prototype,{center:function(a){console.warn("THREE.Box3: .center() has been renamed to .getCenter().");return this.getCenter(a)},empty:function(){console.warn("THREE.Box3: .empty() has been renamed to .isEmpty()."); +return this.isEmpty()},isIntersectionBox:function(a){console.warn("THREE.Box3: .isIntersectionBox() has been renamed to .intersectsBox().");return this.intersectsBox(a)},isIntersectionSphere:function(a){console.warn("THREE.Box3: .isIntersectionSphere() has been renamed to .intersectsSphere().");return this.intersectsSphere(a)},size:function(a){console.warn("THREE.Box3: .size() has been renamed to .getSize().");return this.getSize(a)}});gb.prototype.center=function(a){console.warn("THREE.Line3: .center() has been renamed to .getCenter()."); +return this.getCenter(a)};Q.random16=function(){console.warn("THREE.Math.random16() has been deprecated. Use Math.random() instead.");return Math.random()};Object.assign(za.prototype,{flattenToArrayOffset:function(a,b){console.warn("THREE.Matrix3: .flattenToArrayOffset() has been deprecated. Use .toArray() instead.");return this.toArray(a,b)},multiplyVector3:function(a){console.warn("THREE.Matrix3: .multiplyVector3() has been removed. Use vector.applyMatrix3( matrix ) instead.");return a.applyMatrix3(this)}, +multiplyVector3Array:function(a){console.warn("THREE.Matrix3: .multiplyVector3Array() has been renamed. Use matrix.applyToVector3Array( array ) instead.");return this.applyToVector3Array(a)},applyToBuffer:function(a,b,c){console.warn("THREE.Matrix3: .applyToBuffer() has been removed. Use matrix.applyToBufferAttribute( attribute ) instead.");return this.applyToBufferAttribute(a)}});Object.assign(H.prototype,{extractPosition:function(a){console.warn("THREE.Matrix4: .extractPosition() has been renamed to .copyPosition()."); +return this.copyPosition(a)},flattenToArrayOffset:function(a,b){console.warn("THREE.Matrix4: .flattenToArrayOffset() has been deprecated. Use .toArray() instead.");return this.toArray(a,b)},getPosition:function(){var a;return function(){void 0===a&&(a=new q);console.warn("THREE.Matrix4: .getPosition() has been removed. Use Vector3.setFromMatrixPosition( matrix ) instead.");return a.setFromMatrixColumn(this,3)}}(),setRotationFromQuaternion:function(a){console.warn("THREE.Matrix4: .setRotationFromQuaternion() has been renamed to .makeRotationFromQuaternion()."); +return this.makeRotationFromQuaternion(a)},multiplyVector3:function(a){console.warn("THREE.Matrix4: .multiplyVector3() has been removed. Use vector.applyMatrix4( matrix ) or vector.applyProjection( matrix ) instead.");return a.applyProjection(this)},multiplyVector4:function(a){console.warn("THREE.Matrix4: .multiplyVector4() has been removed. Use vector.applyMatrix4( matrix ) instead.");return a.applyMatrix4(this)},multiplyVector3Array:function(a){console.warn("THREE.Matrix4: .multiplyVector3Array() has been renamed. Use matrix.applyToVector3Array( array ) instead."); +return this.applyToVector3Array(a)},rotateAxis:function(a){console.warn("THREE.Matrix4: .rotateAxis() has been removed. Use Vector3.transformDirection( matrix ) instead.");a.transformDirection(this)},crossVector:function(a){console.warn("THREE.Matrix4: .crossVector() has been removed. Use vector.applyMatrix4( matrix ) instead.");return a.applyMatrix4(this)},translate:function(){console.error("THREE.Matrix4: .translate() has been removed.")},rotateX:function(){console.error("THREE.Matrix4: .rotateX() has been removed.")}, +rotateY:function(){console.error("THREE.Matrix4: .rotateY() has been removed.")},rotateZ:function(){console.error("THREE.Matrix4: .rotateZ() has been removed.")},rotateByAxis:function(){console.error("THREE.Matrix4: .rotateByAxis() has been removed.")},applyToBuffer:function(a,b,c){console.warn("THREE.Matrix4: .applyToBuffer() has been removed. Use matrix.applyToBufferAttribute( attribute ) instead.");return this.applyToBufferAttribute(a)}});ma.prototype.isIntersectionLine=function(a){console.warn("THREE.Plane: .isIntersectionLine() has been renamed to .intersectsLine()."); +return this.intersectsLine(a)};da.prototype.multiplyVector3=function(a){console.warn("THREE.Quaternion: .multiplyVector3() has been removed. Use is now vector.applyQuaternion( quaternion ) instead.");return a.applyQuaternion(this)};Object.assign(bb.prototype,{isIntersectionBox:function(a){console.warn("THREE.Ray: .isIntersectionBox() has been renamed to .intersectsBox().");return this.intersectsBox(a)},isIntersectionPlane:function(a){console.warn("THREE.Ray: .isIntersectionPlane() has been renamed to .intersectsPlane()."); +return this.intersectsPlane(a)},isIntersectionSphere:function(a){console.warn("THREE.Ray: .isIntersectionSphere() has been renamed to .intersectsSphere().");return this.intersectsSphere(a)}});Object.assign(Ab.prototype,{extrude:function(a){console.warn("THREE.Shape: .extrude() has been removed. Use ExtrudeGeometry() instead.");return new La(this,a)},makeGeometry:function(a){console.warn("THREE.Shape: .makeGeometry() has been removed. Use ShapeGeometry() instead.");return new Xb(this,a)}});Object.assign(q.prototype, +{setEulerFromRotationMatrix:function(){console.error("THREE.Vector3: .setEulerFromRotationMatrix() has been removed. Use Euler.setFromRotationMatrix() instead.")},setEulerFromQuaternion:function(){console.error("THREE.Vector3: .setEulerFromQuaternion() has been removed. Use Euler.setFromQuaternion() instead.")},getPositionFromMatrix:function(a){console.warn("THREE.Vector3: .getPositionFromMatrix() has been renamed to .setFromMatrixPosition().");return this.setFromMatrixPosition(a)},getScaleFromMatrix:function(a){console.warn("THREE.Vector3: .getScaleFromMatrix() has been renamed to .setFromMatrixScale()."); +return this.setFromMatrixScale(a)},getColumnFromMatrix:function(a,b){console.warn("THREE.Vector3: .getColumnFromMatrix() has been renamed to .setFromMatrixColumn().");return this.setFromMatrixColumn(b,a)}});S.prototype.computeTangents=function(){console.warn("THREE.Geometry: .computeTangents() has been removed.")};Object.assign(G.prototype,{getChildByName:function(a){console.warn("THREE.Object3D: .getChildByName() has been renamed to .getObjectByName().");return this.getObjectByName(a)},renderDepth:function(){console.warn("THREE.Object3D: .renderDepth has been removed. Use .renderOrder, instead.")}, +translate:function(a,b){console.warn("THREE.Object3D: .translate() has been removed. Use .translateOnAxis( axis, distance ) instead.");return this.translateOnAxis(b,a)}});Object.defineProperties(G.prototype,{eulerOrder:{get:function(){console.warn("THREE.Object3D: .eulerOrder is now .rotation.order.");return this.rotation.order},set:function(a){console.warn("THREE.Object3D: .eulerOrder is now .rotation.order.");this.rotation.order=a}},useQuaternion:{get:function(){console.warn("THREE.Object3D: .useQuaternion has been removed. The library now uses quaternions by default.")}, +set:function(){console.warn("THREE.Object3D: .useQuaternion has been removed. The library now uses quaternions by default.")}}});Object.defineProperties(Ac.prototype,{objects:{get:function(){console.warn("THREE.LOD: .objects has been renamed to .levels.");return this.levels}}});Ha.prototype.setLens=function(a,b){console.warn("THREE.PerspectiveCamera.setLens is deprecated. Use .setFocalLength and .filmGauge for a photographic setup.");void 0!==b&&(this.filmGauge=b);this.setFocalLength(a)};Object.defineProperties(na.prototype, +{onlyShadow:{set:function(){console.warn("THREE.Light: .onlyShadow has been removed.")}},shadowCameraFov:{set:function(a){console.warn("THREE.Light: .shadowCameraFov is now .shadow.camera.fov.");this.shadow.camera.fov=a}},shadowCameraLeft:{set:function(a){console.warn("THREE.Light: .shadowCameraLeft is now .shadow.camera.left.");this.shadow.camera.left=a}},shadowCameraRight:{set:function(a){console.warn("THREE.Light: .shadowCameraRight is now .shadow.camera.right.");this.shadow.camera.right=a}},shadowCameraTop:{set:function(a){console.warn("THREE.Light: .shadowCameraTop is now .shadow.camera.top."); +this.shadow.camera.top=a}},shadowCameraBottom:{set:function(a){console.warn("THREE.Light: .shadowCameraBottom is now .shadow.camera.bottom.");this.shadow.camera.bottom=a}},shadowCameraNear:{set:function(a){console.warn("THREE.Light: .shadowCameraNear is now .shadow.camera.near.");this.shadow.camera.near=a}},shadowCameraFar:{set:function(a){console.warn("THREE.Light: .shadowCameraFar is now .shadow.camera.far.");this.shadow.camera.far=a}},shadowCameraVisible:{set:function(){console.warn("THREE.Light: .shadowCameraVisible has been removed. Use new THREE.CameraHelper( light.shadow.camera ) instead.")}}, +shadowBias:{set:function(a){console.warn("THREE.Light: .shadowBias is now .shadow.bias.");this.shadow.bias=a}},shadowDarkness:{set:function(){console.warn("THREE.Light: .shadowDarkness has been removed.")}},shadowMapWidth:{set:function(a){console.warn("THREE.Light: .shadowMapWidth is now .shadow.mapSize.width.");this.shadow.mapSize.width=a}},shadowMapHeight:{set:function(a){console.warn("THREE.Light: .shadowMapHeight is now .shadow.mapSize.height.");this.shadow.mapSize.height=a}}});Object.defineProperties(y.prototype, +{length:{get:function(){console.warn("THREE.BufferAttribute: .length has been deprecated. Use .count instead.");return this.array.length}}});Object.assign(D.prototype,{addIndex:function(a){console.warn("THREE.BufferGeometry: .addIndex() has been renamed to .setIndex().");this.setIndex(a)},addDrawCall:function(a,b,c){void 0!==c&&console.warn("THREE.BufferGeometry: .addDrawCall() no longer supports indexOffset.");console.warn("THREE.BufferGeometry: .addDrawCall() is now .addGroup().");this.addGroup(a, +b)},clearDrawCalls:function(){console.warn("THREE.BufferGeometry: .clearDrawCalls() is now .clearGroups().");this.clearGroups()},computeTangents:function(){console.warn("THREE.BufferGeometry: .computeTangents() has been removed.")},computeOffsets:function(){console.warn("THREE.BufferGeometry: .computeOffsets() has been removed.")}});Object.defineProperties(D.prototype,{drawcalls:{get:function(){console.error("THREE.BufferGeometry: .drawcalls has been renamed to .groups.");return this.groups}},offsets:{get:function(){console.warn("THREE.BufferGeometry: .offsets has been renamed to .groups."); +return this.groups}}});Object.defineProperties(Dd.prototype,{dynamic:{set:function(){console.warn("THREE.Uniform: .dynamic has been removed. Use object.onBeforeRender() instead.")}},onUpdate:{value:function(){console.warn("THREE.Uniform: .onUpdate() has been removed. Use object.onBeforeRender() instead.");return this}}});Object.defineProperties(W.prototype,{wrapAround:{get:function(){console.warn("THREE."+this.type+": .wrapAround has been removed.")},set:function(){console.warn("THREE."+this.type+ +": .wrapAround has been removed.")}},wrapRGB:{get:function(){console.warn("THREE."+this.type+": .wrapRGB has been removed.");return new N}}});Object.defineProperties(Ca.prototype,{metal:{get:function(){console.warn("THREE.MeshPhongMaterial: .metal has been removed. Use THREE.MeshStandardMaterial instead.");return!1},set:function(){console.warn("THREE.MeshPhongMaterial: .metal has been removed. Use THREE.MeshStandardMaterial instead")}}});Object.defineProperties(Ia.prototype,{derivatives:{get:function(){console.warn("THREE.ShaderMaterial: .derivatives has been moved to .extensions.derivatives."); +return this.extensions.derivatives},set:function(a){console.warn("THREE. ShaderMaterial: .derivatives has been moved to .extensions.derivatives.");this.extensions.derivatives=a}}});oa.prototype=Object.assign(Object.create({constructor:oa,apply:function(a){console.warn("THREE.EventDispatcher: .apply is deprecated, just inherit or Object.assign the prototype to mix-in.");Object.assign(a,this)}}),oa.prototype);Object.assign(Nd.prototype,{supportsFloatTextures:function(){console.warn("THREE.WebGLRenderer: .supportsFloatTextures() is now .extensions.get( 'OES_texture_float' )."); +return this.extensions.get("OES_texture_float")},supportsHalfFloatTextures:function(){console.warn("THREE.WebGLRenderer: .supportsHalfFloatTextures() is now .extensions.get( 'OES_texture_half_float' ).");return this.extensions.get("OES_texture_half_float")},supportsStandardDerivatives:function(){console.warn("THREE.WebGLRenderer: .supportsStandardDerivatives() is now .extensions.get( 'OES_standard_derivatives' ).");return this.extensions.get("OES_standard_derivatives")},supportsCompressedTextureS3TC:function(){console.warn("THREE.WebGLRenderer: .supportsCompressedTextureS3TC() is now .extensions.get( 'WEBGL_compressed_texture_s3tc' )."); +return this.extensions.get("WEBGL_compressed_texture_s3tc")},supportsCompressedTexturePVRTC:function(){console.warn("THREE.WebGLRenderer: .supportsCompressedTexturePVRTC() is now .extensions.get( 'WEBGL_compressed_texture_pvrtc' ).");return this.extensions.get("WEBGL_compressed_texture_pvrtc")},supportsBlendMinMax:function(){console.warn("THREE.WebGLRenderer: .supportsBlendMinMax() is now .extensions.get( 'EXT_blend_minmax' ).");return this.extensions.get("EXT_blend_minmax")},supportsVertexTextures:function(){console.warn("THREE.WebGLRenderer: .supportsVertexTextures() is now .capabilities.vertexTextures."); +return this.capabilities.vertexTextures},supportsInstancedArrays:function(){console.warn("THREE.WebGLRenderer: .supportsInstancedArrays() is now .extensions.get( 'ANGLE_instanced_arrays' ).");return this.extensions.get("ANGLE_instanced_arrays")},enableScissorTest:function(a){console.warn("THREE.WebGLRenderer: .enableScissorTest() is now .setScissorTest().");this.setScissorTest(a)},initMaterial:function(){console.warn("THREE.WebGLRenderer: .initMaterial() has been removed.")},addPrePlugin:function(){console.warn("THREE.WebGLRenderer: .addPrePlugin() has been removed.")}, +addPostPlugin:function(){console.warn("THREE.WebGLRenderer: .addPostPlugin() has been removed.")},updateShadowMap:function(){console.warn("THREE.WebGLRenderer: .updateShadowMap() has been removed.")}});Object.defineProperties(Nd.prototype,{shadowMapEnabled:{get:function(){return this.shadowMap.enabled},set:function(a){console.warn("THREE.WebGLRenderer: .shadowMapEnabled is now .shadowMap.enabled.");this.shadowMap.enabled=a}},shadowMapType:{get:function(){return this.shadowMap.type},set:function(a){console.warn("THREE.WebGLRenderer: .shadowMapType is now .shadowMap.type."); +this.shadowMap.type=a}},shadowMapCullFace:{get:function(){return this.shadowMap.cullFace},set:function(a){console.warn("THREE.WebGLRenderer: .shadowMapCullFace is now .shadowMap.cullFace.");this.shadowMap.cullFace=a}}});Object.defineProperties(ye.prototype,{cullFace:{get:function(){return this.renderReverseSided?2:1},set:function(a){a=1!==a;console.warn("WebGLRenderer: .shadowMap.cullFace is deprecated. Set .shadowMap.renderReverseSided to "+a+".");this.renderReverseSided=a}}});Object.defineProperties(Db.prototype, +{wrapS:{get:function(){console.warn("THREE.WebGLRenderTarget: .wrapS is now .texture.wrapS.");return this.texture.wrapS},set:function(a){console.warn("THREE.WebGLRenderTarget: .wrapS is now .texture.wrapS.");this.texture.wrapS=a}},wrapT:{get:function(){console.warn("THREE.WebGLRenderTarget: .wrapT is now .texture.wrapT.");return this.texture.wrapT},set:function(a){console.warn("THREE.WebGLRenderTarget: .wrapT is now .texture.wrapT.");this.texture.wrapT=a}},magFilter:{get:function(){console.warn("THREE.WebGLRenderTarget: .magFilter is now .texture.magFilter."); +return this.texture.magFilter},set:function(a){console.warn("THREE.WebGLRenderTarget: .magFilter is now .texture.magFilter.");this.texture.magFilter=a}},minFilter:{get:function(){console.warn("THREE.WebGLRenderTarget: .minFilter is now .texture.minFilter.");return this.texture.minFilter},set:function(a){console.warn("THREE.WebGLRenderTarget: .minFilter is now .texture.minFilter.");this.texture.minFilter=a}},anisotropy:{get:function(){console.warn("THREE.WebGLRenderTarget: .anisotropy is now .texture.anisotropy."); +return this.texture.anisotropy},set:function(a){console.warn("THREE.WebGLRenderTarget: .anisotropy is now .texture.anisotropy.");this.texture.anisotropy=a}},offset:{get:function(){console.warn("THREE.WebGLRenderTarget: .offset is now .texture.offset.");return this.texture.offset},set:function(a){console.warn("THREE.WebGLRenderTarget: .offset is now .texture.offset.");this.texture.offset=a}},repeat:{get:function(){console.warn("THREE.WebGLRenderTarget: .repeat is now .texture.repeat.");return this.texture.repeat}, +set:function(a){console.warn("THREE.WebGLRenderTarget: .repeat is now .texture.repeat.");this.texture.repeat=a}},format:{get:function(){console.warn("THREE.WebGLRenderTarget: .format is now .texture.format.");return this.texture.format},set:function(a){console.warn("THREE.WebGLRenderTarget: .format is now .texture.format.");this.texture.format=a}},type:{get:function(){console.warn("THREE.WebGLRenderTarget: .type is now .texture.type.");return this.texture.type},set:function(a){console.warn("THREE.WebGLRenderTarget: .type is now .texture.type."); +this.texture.type=a}},generateMipmaps:{get:function(){console.warn("THREE.WebGLRenderTarget: .generateMipmaps is now .texture.generateMipmaps.");return this.texture.generateMipmaps},set:function(a){console.warn("THREE.WebGLRenderTarget: .generateMipmaps is now .texture.generateMipmaps.");this.texture.generateMipmaps=a}}});ec.prototype.load=function(a){console.warn("THREE.Audio: .load has been deprecated. Use THREE.AudioLoader instead.");var b=this;(new Wd).load(a,function(a){b.setBuffer(a)});return this}; +ae.prototype.getData=function(){console.warn("THREE.AudioAnalyser: .getData() is now .getFrequencyData().");return this.getFrequencyData()};l.WebGLRenderTargetCube=Eb;l.WebGLRenderTarget=Db;l.WebGLRenderer=Nd;l.ShaderLib=Gb;l.UniformsLib=U;l.UniformsUtils=Ja;l.ShaderChunk=Z;l.FogExp2=Ib;l.Fog=Jb;l.Scene=jb;l.LensFlare=Od;l.Sprite=zc;l.LOD=Ac;l.SkinnedMesh=jd;l.Skeleton=hd;l.Bone=id;l.Mesh=Ba;l.LineSegments=fa;l.Line=Va;l.Points=Kb;l.Group=Bc;l.VideoTexture=kd;l.DataTexture=db;l.CompressedTexture= +Lb;l.CubeTexture=Za;l.CanvasTexture=ld;l.DepthTexture=Cc;l.Texture=ea;l.CompressedTextureLoader=Ee;l.BinaryTextureLoader=Qd;l.DataTextureLoader=Qd;l.CubeTextureLoader=Rd;l.TextureLoader=md;l.ObjectLoader=Fe;l.MaterialLoader=Ad;l.BufferGeometryLoader=Sd;l.DefaultLoadingManager=va;l.LoadingManager=Pd;l.JSONLoader=Td;l.ImageLoader=Vc;l.FontLoader=Ge;l.FileLoader=Ma;l.Loader=wb;l.Cache=ne;l.AudioLoader=Wd;l.SpotLightShadow=od;l.SpotLight=pd;l.PointLight=qd;l.RectAreaLight=Xd;l.HemisphereLight=nd;l.DirectionalLightShadow= +rd;l.DirectionalLight=sd;l.AmbientLight=td;l.LightShadow=tb;l.Light=na;l.StereoCamera=He;l.PerspectiveCamera=Ha;l.OrthographicCamera=Hb;l.CubeCamera=Bd;l.Camera=sa;l.AudioListener=Yd;l.PositionalAudio=$d;l.AudioContext=Zd;l.AudioAnalyser=ae;l.Audio=ec;l.VectorKeyframeTrack=cc;l.StringKeyframeTrack=xd;l.QuaternionKeyframeTrack=Xc;l.NumberKeyframeTrack=dc;l.ColorKeyframeTrack=zd;l.BooleanKeyframeTrack=yd;l.PropertyMixer=Cd;l.PropertyBinding=ka;l.KeyframeTrack=vb;l.AnimationUtils=ba;l.AnimationObjectGroup= +be;l.AnimationMixer=de;l.AnimationClip=ta;l.Uniform=Dd;l.InstancedBufferGeometry=Bb;l.BufferGeometry=D;l.GeometryIdCount=function(){return Kd++};l.Geometry=S;l.InterleavedBufferAttribute=ee;l.InstancedInterleavedBuffer=gc;l.InterleavedBuffer=fc;l.InstancedBufferAttribute=hc;l.Face3=ha;l.Object3D=G;l.Raycaster=fe;l.Layers=gd;l.EventDispatcher=oa;l.Clock=he;l.QuaternionLinearInterpolant=wd;l.LinearInterpolant=Wc;l.DiscreteInterpolant=vd;l.CubicInterpolant=ud;l.Interpolant=qa;l.Triangle=Aa;l.Spline= +function(a){function b(a,b,c,d,e,f,g){a=.5*(c-a);d=.5*(d-b);return(2*(b-c)+a+d)*g+(-3*(b-c)-2*a-d)*f+a*e+b}this.points=a;var c=[],d={x:0,y:0,z:0},e,f,g,h,k,l,x,p,n;this.initFromArray=function(a){this.points=[];for(var b=0;bthis.points.length-2?this.points.length-1:f+1;c[3]=f>this.points.length-3?this.points.length-1:f+2;l=this.points[c[0]]; +x=this.points[c[1]];p=this.points[c[2]];n=this.points[c[3]];h=g*g;k=g*h;d.x=b(l.x,x.x,p.x,n.x,g,h,k);d.y=b(l.y,x.y,p.y,n.y,g,h,k);d.z=b(l.z,x.z,p.z,n.z,g,h,k);return d};this.getControlPointsArray=function(){var a,b,c=this.points.length,d=[];for(a=0;a"+e.outerHTML+"":e.outerHTML;L.call(document,i);var a=document.querySelector("["+r+"]");if(a){a.removeAttribute(r);var c=n&&a.parentNode;c&&o(c)}return a}function f(t){if(t&&"handleEvent"in t){var e=t.handleEvent;return"function"==typeof e?e.bind(t):e}return t}function h(t,e,n){var r=n?function(t){return e.insertBefore(t,n)}:function(t){return e.appendChild(t)};Array.prototype.slice.call(t).forEach(r)}function v(){return/chrome/i.test(navigator.userAgent)&&/google/i.test(navigator.vendor)}function y(t,e){function n(){this.constructor=t}H(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}function m(t){return t instanceof Window?["load"]:t instanceof Document?["DOMContentLoaded","readystatechange"]:[]}function b(t){var e=t.getAttribute(R);if(!e)return null;var n=e.split(T);return{nonce:n[0],handlerPrefixLength:+n[1],bailout:!t.hasAttribute("defer")}}function g(t){var e=B+t.nonce;Array.prototype.forEach.call(document.querySelectorAll("["+e+"]"),function(n){n.removeAttribute(e),Array.prototype.forEach.call(n.attributes,function(e){/^on/.test(e.name)&&"function"!=typeof n[e.name]&&n.setAttribute(e.name,e.value.substring(t.handlerPrefixLength))})})}function S(){var t=window;"undefined"!=typeof Promise&&(t.__cfQR={done:new Promise(function(t){return U=t})})}function w(t){var e=new N(t),n=new C(e);e.harvestScriptsInDocument(),new W(e,{nonce:t,blocking:!0,docWriteSimulator:n,callback:function(){}}).run()}function x(t){var e=new N(t),n=new C(e);e.harvestScriptsInDocument();var r=new W(e,{nonce:t,blocking:!1,docWriteSimulator:n,callback:function(){window.__cfRLUnblockHandlers=!0,r.removePreloadHints(),P(t)}});r.insertPreloadHints(),M.runOnLoad(function(){r.run()})}function P(t){var e=new O(t);M.simulateStateBeforeDeferScriptsActivation(),e.harvestDeferScriptsInDocument(),new W(e,{nonce:t,blocking:!1,callback:function(){M.simulateStateAfterDeferScriptsActivation(),U&&U()}}).run()}var A="http://www.w3.org/2000/svg",E={"application/ecmascript":!0,"application/javascript":!0,"application/x-ecmascript":!0,"application/x-javascript":!0,"text/ecmascript":!0,"text/javascript":!0,"text/javascript1.0":!0,"text/javascript1.1":!0,"text/javascript1.2":!0,"text/javascript1.3":!0,"text/javascript1.4":!0,"text/javascript1.5":!0,"text/jscript":!0,"text/livescript":!0,"text/x-ecmascript":!0,"text/x-javascript":!0,module:!0},k=void 0!==document.createElement("script").noModule,I=function(){var t=window;return t.__rocketLoaderEventCtor||Object.defineProperty(t,"__rocketLoaderEventCtor",{value:Event}),t.__rocketLoaderEventCtor}(),L=document.write,_=document.writeln,H=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},D=function(){function t(t){this.nonce=t,this.items=[]}return Object.defineProperty(t.prototype,"hasItems",{get:function(){return this.items.length>0},enumerable:!0,configurable:!0}),t.prototype.pop=function(){return this.items.pop()},t.prototype.forEach=function(t){this.items.forEach(function(e){var n=e.script;return t(n)})},t.prototype.harvestScripts=function(t,e){var n=this,r=e.filter,o=e.mutate;Array.prototype.slice.call(t.querySelectorAll("script")).filter(r).reverse().forEach(function(t){o(t),n.pushScriptOnStack(t)})},t.prototype.pushScriptOnStack=function(t){var e=t.parentNode,n=this.createPlaceholder(t),r=!!i(t);e.replaceChild(n,t),this.items.push({script:t,placeholder:n,external:r,async:r&&t.hasAttribute("async"),executable:c(t)})},t.prototype.hasNonce=function(t){return 0===(t.getAttribute("type")||"").indexOf(this.nonce)},t.prototype.removeNonce=function(t){t.type=t.type.substr(this.nonce.length)},t.prototype.makeNonExecutable=function(t){t.type=this.nonce+t.type},t.prototype.isPendingDeferScript=function(t){return t.hasAttribute("defer")||t.type===this.nonce+"module"&&!t.hasAttribute("async")},t}(),N=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return y(e,t),e.prototype.harvestScriptsInDocument=function(){var t=this;this.harvestScripts(document,{filter:function(e){return t.hasNonce(e)},mutate:function(e){t.isPendingDeferScript(e)||t.removeNonce(e)}})},e.prototype.harvestScriptsAfterDocWrite=function(t){var e=this;this.harvestScripts(t,{filter:c,mutate:function(t){e.isPendingDeferScript(t)&&e.makeNonExecutable(t)}})},e.prototype.createPlaceholder=function(t){return document.createComment(t.outerHTML)},e}(D),O=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return y(e,t),e.prototype.harvestDeferScriptsInDocument=function(){var t=this;this.harvestScripts(document,{filter:function(e){return t.hasNonce(e)&&t.isPendingDeferScript(e)},mutate:function(e){return t.removeNonce(e)}})},e.prototype.createPlaceholder=function(t){var e=p(t);return this.makeNonExecutable(e),e},e}(D),C=function(){function t(t){this.scriptStack=t}return t.prototype.enable=function(t){var e=this;this.insertionPointMarker=t,this.buffer="",document.write=function(){for(var t=[],n=0;n",o=t.parseFromString(e,"text/html");if(this.scriptStack.harvestScriptsAfterDocWrite(o),n(o.head.childNodes,this.insertionPointMarker),o.body.childNodes.length){for(var i=Array.prototype.slice.call(o.body.childNodes),a=this.insertionPointMarker.nextSibling;a;)i.push(a),a=a.nextSibling;document.body||L.call(document,""),r(i,document.body)}},t.prototype.insertContentInBody=function(){var t=this.insertionPointMarker.parentElement,e=document.createElement(t.tagName);e.innerHTML=this.buffer,this.scriptStack.harvestScriptsAfterDocWrite(e),n(e.childNodes,this.insertionPointMarker)},t.prototype.write=function(t,e){var n=document.currentScript;n&&i(n)&&n.hasAttribute("async")?(r=e?_:L).call.apply(r,[document].concat(t)):this.buffer+=t.map(String).join(e?"\n":"");var r},t}(),j=function(){function t(){var t=this;this.simulatedReadyState="loading",this.bypassEventsInProxies=!1,this.nativeWindowAddEventListener=window.addEventListener;try{Object.defineProperty(document,"readyState",{get:function(){return t.simulatedReadyState}})}catch(e){}this.setupEventListenerProxy(),this.updateInlineHandlers()}return t.prototype.runOnLoad=function(t){var e=this;this.nativeWindowAddEventListener.call(window,"load",function(n){if(!e.bypassEventsInProxies)return t(n)})},t.prototype.updateInlineHandlers=function(){this.proxyInlineHandler(document,"onreadystatechange"),this.proxyInlineHandler(window,"onload"),document.body&&this.proxyInlineHandler(document.body,"onload")},t.prototype.simulateStateBeforeDeferScriptsActivation=function(){this.bypassEventsInProxies=!0,this.simulatedReadyState="interactive",l(document,"readystatechange"),this.bypassEventsInProxies=!1},t.prototype.simulateStateAfterDeferScriptsActivation=function(){var t=this;this.bypassEventsInProxies=!0,l(document,"DOMContentLoaded"),this.simulatedReadyState="complete",l(document,"readystatechange"),l(window,"load"),this.bypassEventsInProxies=!1,window.setTimeout(function(){return t.bypassEventsInProxies=!0},0)},t.prototype.setupEventListenerProxy=function(){var t=this;("undefined"!=typeof EventTarget?[EventTarget.prototype]:[Node.prototype,Window.prototype]).forEach(function(e){return t.patchEventTargetMethods(e)})},t.prototype.patchEventTargetMethods=function(t){var e=this,n=t.addEventListener,r=t.removeEventListener;t.addEventListener=function(t,r){for(var o=[],i=2;i_0x4d1159['x']?_0x4d1159['x']:_0x43c9f9)<_0x49ec0e['x']?_0x49ec0e['x']:_0x43c9f9;var _0x2af598=_0x1bd710['y'];return new _0x16391e(_0x43c9f9,_0x2af598=(_0x2af598=_0x2af598>_0x4d1159['y']?_0x4d1159['y']:_0x2af598)<_0x49ec0e['y']?_0x49ec0e['y']:_0x2af598);},_0x16391e['Hermite']=function(_0x1eb971,_0x31c673,_0x477013,_0x4f7451,_0x2e9444){var _0x272dad=_0x2e9444*_0x2e9444,_0x139d5e=_0x2e9444*_0x272dad,_0xdb64eb=0x2*_0x139d5e-0x3*_0x272dad+0x1,_0x40aa43=-0x2*_0x139d5e+0x3*_0x272dad,_0x2565ed=_0x139d5e-0x2*_0x272dad+_0x2e9444,_0x18e9e7=_0x139d5e-_0x272dad;return new _0x16391e(_0x1eb971['x']*_0xdb64eb+_0x477013['x']*_0x40aa43+_0x31c673['x']*_0x2565ed+_0x4f7451['x']*_0x18e9e7,_0x1eb971['y']*_0xdb64eb+_0x477013['y']*_0x40aa43+_0x31c673['y']*_0x2565ed+_0x4f7451['y']*_0x18e9e7);},_0x16391e['Lerp']=function(_0x5eec1a,_0x16dc7e,_0x2f30d2){return new _0x16391e(_0x5eec1a['x']+(_0x16dc7e['x']-_0x5eec1a['x'])*_0x2f30d2,_0x5eec1a['y']+(_0x16dc7e['y']-_0x5eec1a['y'])*_0x2f30d2);},_0x16391e['Dot']=function(_0x558a28,_0x4e87d4){return _0x558a28['x']*_0x4e87d4['x']+_0x558a28['y']*_0x4e87d4['y'];},_0x16391e['Normalize']=function(_0x373f83){var _0x10ca16=_0x373f83['clone']();return _0x10ca16['normalize'](),_0x10ca16;},_0x16391e['Minimize']=function(_0x5818c5,_0x428c80){return new _0x16391e(_0x5818c5['x']<_0x428c80['x']?_0x5818c5['x']:_0x428c80['x'],_0x5818c5['y']<_0x428c80['y']?_0x5818c5['y']:_0x428c80['y']);},_0x16391e['Maximize']=function(_0x2297fc,_0x2a593f){return new _0x16391e(_0x2297fc['x']>_0x2a593f['x']?_0x2297fc['x']:_0x2a593f['x'],_0x2297fc['y']>_0x2a593f['y']?_0x2297fc['y']:_0x2a593f['y']);},_0x16391e['Transform']=function(_0x5b929c,_0x211539){var _0x2d76e6=_0x16391e['Zero']();return _0x16391e['TransformToRef'](_0x5b929c,_0x211539,_0x2d76e6),_0x2d76e6;},_0x16391e['TransformToRef']=function(_0x2a87f1,_0x3e8957,_0x244287){var _0x234abd=_0x3e8957['m'],_0x48d6a4=_0x2a87f1['x']*_0x234abd[0x0]+_0x2a87f1['y']*_0x234abd[0x4]+_0x234abd[0xc],_0x58affd=_0x2a87f1['x']*_0x234abd[0x1]+_0x2a87f1['y']*_0x234abd[0x5]+_0x234abd[0xd];_0x244287['x']=_0x48d6a4,_0x244287['y']=_0x58affd;},_0x16391e['PointInTriangle']=function(_0x475d71,_0x337bc8,_0x6d98d9,_0x1a54d1){var _0x549263=0.5*(-_0x6d98d9['y']*_0x1a54d1['x']+_0x337bc8['y']*(-_0x6d98d9['x']+_0x1a54d1['x'])+_0x337bc8['x']*(_0x6d98d9['y']-_0x1a54d1['y'])+_0x6d98d9['x']*_0x1a54d1['y']),_0x19e18d=_0x549263<0x0?-0x1:0x1,_0xdd967f=(_0x337bc8['y']*_0x1a54d1['x']-_0x337bc8['x']*_0x1a54d1['y']+(_0x1a54d1['y']-_0x337bc8['y'])*_0x475d71['x']+(_0x337bc8['x']-_0x1a54d1['x'])*_0x475d71['y'])*_0x19e18d,_0x1e91a8=(_0x337bc8['x']*_0x6d98d9['y']-_0x337bc8['y']*_0x6d98d9['x']+(_0x337bc8['y']-_0x6d98d9['y'])*_0x475d71['x']+(_0x6d98d9['x']-_0x337bc8['x'])*_0x475d71['y'])*_0x19e18d;return _0xdd967f>0x0&&_0x1e91a8>0x0&&_0xdd967f+_0x1e91a8<0x2*_0x549263*_0x19e18d;},_0x16391e['Distance']=function(_0x2043dd,_0x213c91){return Math['sqrt'](_0x16391e['DistanceSquared'](_0x2043dd,_0x213c91));},_0x16391e['DistanceSquared']=function(_0x3ec4c2,_0x398265){var _0x13f982=_0x3ec4c2['x']-_0x398265['x'],_0x5a0a01=_0x3ec4c2['y']-_0x398265['y'];return _0x13f982*_0x13f982+_0x5a0a01*_0x5a0a01;},_0x16391e['Center']=function(_0x5ef332,_0x337b42){var _0x54be3f=_0x5ef332['add'](_0x337b42);return _0x54be3f['scaleInPlace'](0.5),_0x54be3f;},_0x16391e['DistanceOfPointFromSegment']=function(_0x38e31a,_0x31e907,_0x37c43b){var _0x3e341f=_0x16391e['DistanceSquared'](_0x31e907,_0x37c43b);if(0x0===_0x3e341f)return _0x16391e['Distance'](_0x38e31a,_0x31e907);var _0x898257=_0x37c43b['subtract'](_0x31e907),_0x2c20cd=Math['max'](0x0,Math['min'](0x1,_0x16391e['Dot'](_0x38e31a['subtract'](_0x31e907),_0x898257)/_0x3e341f)),_0x36268e=_0x31e907['add'](_0x898257['multiplyByFloats'](_0x2c20cd,_0x2c20cd));return _0x16391e['Distance'](_0x38e31a,_0x36268e);},_0x16391e;}()),_0x39af4b=(function(){function _0x4d7c8e(_0x286586,_0x48c5ba,_0x3e59e4){void 0x0===_0x286586&&(_0x286586=0x0),void 0x0===_0x48c5ba&&(_0x48c5ba=0x0),void 0x0===_0x3e59e4&&(_0x3e59e4=0x0),this['_isDirty']=!0x0,this['_x']=_0x286586,this['_y']=_0x48c5ba,this['_z']=_0x3e59e4;}return Object['defineProperty'](_0x4d7c8e['prototype'],'x',{'get':function(){return this['_x'];},'set':function(_0x3edc68){this['_x']=_0x3edc68,this['_isDirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4d7c8e['prototype'],'y',{'get':function(){return this['_y'];},'set':function(_0x144342){this['_y']=_0x144342,this['_isDirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4d7c8e['prototype'],'z',{'get':function(){return this['_z'];},'set':function(_0xb44090){this['_z']=_0xb44090,this['_isDirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),_0x4d7c8e['prototype']['toString']=function(){return'{X:\x20'+this['_x']+'\x20Y:'+this['_y']+'\x20Z:'+this['_z']+'}';},_0x4d7c8e['prototype']['getClassName']=function(){return'Vector3';},_0x4d7c8e['prototype']['getHashCode']=function(){var _0xad6174=0x0|this['_x'];return _0xad6174=0x18d*(_0xad6174=0x18d*_0xad6174^(0x0|this['_y']))^(0x0|this['_z']);},_0x4d7c8e['prototype']['asArray']=function(){var _0x108f98=[];return this['toArray'](_0x108f98,0x0),_0x108f98;},_0x4d7c8e['prototype']['toArray']=function(_0x4dad7e,_0x5814d2){return void 0x0===_0x5814d2&&(_0x5814d2=0x0),_0x4dad7e[_0x5814d2]=this['_x'],_0x4dad7e[_0x5814d2+0x1]=this['_y'],_0x4dad7e[_0x5814d2+0x2]=this['_z'],this;},_0x4d7c8e['prototype']['fromArray']=function(_0x57165e,_0x2f3ea4){return void 0x0===_0x2f3ea4&&(_0x2f3ea4=0x0),_0x4d7c8e['FromArrayToRef'](_0x57165e,_0x2f3ea4,this),this;},_0x4d7c8e['prototype']['toQuaternion']=function(){return _0x336fc5['RotationYawPitchRoll'](this['_y'],this['_x'],this['_z']);},_0x4d7c8e['prototype']['addInPlace']=function(_0x412e88){return this['addInPlaceFromFloats'](_0x412e88['_x'],_0x412e88['_y'],_0x412e88['_z']);},_0x4d7c8e['prototype']['addInPlaceFromFloats']=function(_0x4328dd,_0x650225,_0x18fcaa){return this['x']+=_0x4328dd,this['y']+=_0x650225,this['z']+=_0x18fcaa,this;},_0x4d7c8e['prototype']['add']=function(_0x102887){return new _0x4d7c8e(this['_x']+_0x102887['_x'],this['_y']+_0x102887['_y'],this['_z']+_0x102887['_z']);},_0x4d7c8e['prototype']['addToRef']=function(_0x4f5b7a,_0x344121){return _0x344121['copyFromFloats'](this['_x']+_0x4f5b7a['_x'],this['_y']+_0x4f5b7a['_y'],this['_z']+_0x4f5b7a['_z']);},_0x4d7c8e['prototype']['subtractInPlace']=function(_0x2927e7){return this['x']-=_0x2927e7['_x'],this['y']-=_0x2927e7['_y'],this['z']-=_0x2927e7['_z'],this;},_0x4d7c8e['prototype']['subtract']=function(_0xd1a5cd){return new _0x4d7c8e(this['_x']-_0xd1a5cd['_x'],this['_y']-_0xd1a5cd['_y'],this['_z']-_0xd1a5cd['_z']);},_0x4d7c8e['prototype']['subtractToRef']=function(_0x490877,_0x4d4787){return this['subtractFromFloatsToRef'](_0x490877['_x'],_0x490877['_y'],_0x490877['_z'],_0x4d4787);},_0x4d7c8e['prototype']['subtractFromFloats']=function(_0xa04965,_0x42ad9f,_0x8f6c61){return new _0x4d7c8e(this['_x']-_0xa04965,this['_y']-_0x42ad9f,this['_z']-_0x8f6c61);},_0x4d7c8e['prototype']['subtractFromFloatsToRef']=function(_0x469d8a,_0x250a0d,_0x3babb4,_0x56d1b0){return _0x56d1b0['copyFromFloats'](this['_x']-_0x469d8a,this['_y']-_0x250a0d,this['_z']-_0x3babb4);},_0x4d7c8e['prototype']['negate']=function(){return new _0x4d7c8e(-this['_x'],-this['_y'],-this['_z']);},_0x4d7c8e['prototype']['negateInPlace']=function(){return this['x']*=-0x1,this['y']*=-0x1,this['z']*=-0x1,this;},_0x4d7c8e['prototype']['negateToRef']=function(_0x1ca51a){return _0x1ca51a['copyFromFloats'](-0x1*this['_x'],-0x1*this['_y'],-0x1*this['_z']);},_0x4d7c8e['prototype']['scaleInPlace']=function(_0x5831a6){return this['x']*=_0x5831a6,this['y']*=_0x5831a6,this['z']*=_0x5831a6,this;},_0x4d7c8e['prototype']['scale']=function(_0xb11d2d){return new _0x4d7c8e(this['_x']*_0xb11d2d,this['_y']*_0xb11d2d,this['_z']*_0xb11d2d);},_0x4d7c8e['prototype']['scaleToRef']=function(_0x311e6a,_0xa03170){return _0xa03170['copyFromFloats'](this['_x']*_0x311e6a,this['_y']*_0x311e6a,this['_z']*_0x311e6a);},_0x4d7c8e['prototype']['scaleAndAddToRef']=function(_0x2df9ba,_0x2b6ba4){return _0x2b6ba4['addInPlaceFromFloats'](this['_x']*_0x2df9ba,this['_y']*_0x2df9ba,this['_z']*_0x2df9ba);},_0x4d7c8e['prototype']['projectOnPlane']=function(_0xb8abe0,_0x590b46){var _0x23f2f0=_0x4d7c8e['Zero']();return this['projectOnPlaneToRef'](_0xb8abe0,_0x590b46,_0x23f2f0),_0x23f2f0;},_0x4d7c8e['prototype']['projectOnPlaneToRef']=function(_0x178d60,_0x418994,_0x34d27e){var _0x2daed8=_0x178d60['normal'],_0x5881fd=_0x178d60['d'],_0x4fdb43=_0x4e1745['Vector3'][0x0];this['subtractToRef'](_0x418994,_0x4fdb43),_0x4fdb43['normalize']();var _0x4f3050=_0x4d7c8e['Dot'](_0x4fdb43,_0x2daed8),_0x3f4fa9=-(_0x4d7c8e['Dot'](_0x418994,_0x2daed8)+_0x5881fd)/_0x4f3050,_0xfd649c=_0x4fdb43['scaleInPlace'](_0x3f4fa9);_0x418994['addToRef'](_0xfd649c,_0x34d27e);},_0x4d7c8e['prototype']['equals']=function(_0x1f00a8){return _0x1f00a8&&this['_x']===_0x1f00a8['_x']&&this['_y']===_0x1f00a8['_y']&&this['_z']===_0x1f00a8['_z'];},_0x4d7c8e['prototype']['equalsWithEpsilon']=function(_0x130bb1,_0x37b309){return void 0x0===_0x37b309&&(_0x37b309=_0x9e8480['a']),_0x130bb1&&_0x109042['a']['WithinEpsilon'](this['_x'],_0x130bb1['_x'],_0x37b309)&&_0x109042['a']['WithinEpsilon'](this['_y'],_0x130bb1['_y'],_0x37b309)&&_0x109042['a']['WithinEpsilon'](this['_z'],_0x130bb1['_z'],_0x37b309);},_0x4d7c8e['prototype']['equalsToFloats']=function(_0x5baba2,_0x332134,_0x216a49){return this['_x']===_0x5baba2&&this['_y']===_0x332134&&this['_z']===_0x216a49;},_0x4d7c8e['prototype']['multiplyInPlace']=function(_0x53134f){return this['x']*=_0x53134f['_x'],this['y']*=_0x53134f['_y'],this['z']*=_0x53134f['_z'],this;},_0x4d7c8e['prototype']['multiply']=function(_0x157489){return this['multiplyByFloats'](_0x157489['_x'],_0x157489['_y'],_0x157489['_z']);},_0x4d7c8e['prototype']['multiplyToRef']=function(_0x45e176,_0x56a137){return _0x56a137['copyFromFloats'](this['_x']*_0x45e176['_x'],this['_y']*_0x45e176['_y'],this['_z']*_0x45e176['_z']);},_0x4d7c8e['prototype']['multiplyByFloats']=function(_0x4b99e6,_0x56db20,_0x1ddbd9){return new _0x4d7c8e(this['_x']*_0x4b99e6,this['_y']*_0x56db20,this['_z']*_0x1ddbd9);},_0x4d7c8e['prototype']['divide']=function(_0x210f9d){return new _0x4d7c8e(this['_x']/_0x210f9d['_x'],this['_y']/_0x210f9d['_y'],this['_z']/_0x210f9d['_z']);},_0x4d7c8e['prototype']['divideToRef']=function(_0x57ad08,_0x311c47){return _0x311c47['copyFromFloats'](this['_x']/_0x57ad08['_x'],this['_y']/_0x57ad08['_y'],this['_z']/_0x57ad08['_z']);},_0x4d7c8e['prototype']['divideInPlace']=function(_0x48615d){return this['divideToRef'](_0x48615d,this);},_0x4d7c8e['prototype']['minimizeInPlace']=function(_0x4d615e){return this['minimizeInPlaceFromFloats'](_0x4d615e['_x'],_0x4d615e['_y'],_0x4d615e['_z']);},_0x4d7c8e['prototype']['maximizeInPlace']=function(_0x3ae242){return this['maximizeInPlaceFromFloats'](_0x3ae242['_x'],_0x3ae242['_y'],_0x3ae242['_z']);},_0x4d7c8e['prototype']['minimizeInPlaceFromFloats']=function(_0x34c099,_0x2f6835,_0x56c043){return _0x34c099this['_x']&&(this['x']=_0x307ff9),_0x3a5190>this['_y']&&(this['y']=_0x3a5190),_0x1b23fd>this['_z']&&(this['z']=_0x1b23fd),this;},_0x4d7c8e['prototype']['isNonUniformWithinEpsilon']=function(_0x3f580f){var _0xa63688=Math['abs'](this['_x']),_0x4fbe6d=Math['abs'](this['_y']);if(!_0x109042['a']['WithinEpsilon'](_0xa63688,_0x4fbe6d,_0x3f580f))return!0x0;var _0x13ad0a=Math['abs'](this['_z']);return!_0x109042['a']['WithinEpsilon'](_0xa63688,_0x13ad0a,_0x3f580f)||!_0x109042['a']['WithinEpsilon'](_0x4fbe6d,_0x13ad0a,_0x3f580f);},Object['defineProperty'](_0x4d7c8e['prototype'],'isNonUniform',{'get':function(){var _0xd25db3=Math['abs'](this['_x']);return _0xd25db3!==Math['abs'](this['_y'])||_0xd25db3!==Math['abs'](this['_z']);},'enumerable':!0x1,'configurable':!0x0}),_0x4d7c8e['prototype']['floor']=function(){return new _0x4d7c8e(Math['floor'](this['_x']),Math['floor'](this['_y']),Math['floor'](this['_z']));},_0x4d7c8e['prototype']['fract']=function(){return new _0x4d7c8e(this['_x']-Math['floor'](this['_x']),this['_y']-Math['floor'](this['_y']),this['_z']-Math['floor'](this['_z']));},_0x4d7c8e['prototype']['length']=function(){return Math['sqrt'](this['_x']*this['_x']+this['_y']*this['_y']+this['_z']*this['_z']);},_0x4d7c8e['prototype']['lengthSquared']=function(){return this['_x']*this['_x']+this['_y']*this['_y']+this['_z']*this['_z'];},_0x4d7c8e['prototype']['normalize']=function(){return this['normalizeFromLength'](this['length']());},_0x4d7c8e['prototype']['reorderInPlace']=function(_0x50cf9d){var _0x2033c6=this;return'xyz'===(_0x50cf9d=_0x50cf9d['toLowerCase']())||(_0x4e1745['Vector3'][0x0]['copyFrom'](this),['x','y','z']['forEach'](function(_0x4dfac1,_0x322c59){_0x2033c6[_0x4dfac1]=_0x4e1745['Vector3'][0x0][_0x50cf9d[_0x322c59]];})),this;},_0x4d7c8e['prototype']['rotateByQuaternionToRef']=function(_0x58a71f,_0x47b733){return _0x58a71f['toRotationMatrix'](_0x4e1745['Matrix'][0x0]),_0x4d7c8e['TransformCoordinatesToRef'](this,_0x4e1745['Matrix'][0x0],_0x47b733),_0x47b733;},_0x4d7c8e['prototype']['rotateByQuaternionAroundPointToRef']=function(_0x392d91,_0x33d899,_0x8fea9b){return this['subtractToRef'](_0x33d899,_0x4e1745['Vector3'][0x0]),_0x4e1745['Vector3'][0x0]['rotateByQuaternionToRef'](_0x392d91,_0x4e1745['Vector3'][0x0]),_0x33d899['addToRef'](_0x4e1745['Vector3'][0x0],_0x8fea9b),_0x8fea9b;},_0x4d7c8e['prototype']['cross']=function(_0x121e3d){return _0x4d7c8e['Cross'](this,_0x121e3d);},_0x4d7c8e['prototype']['normalizeFromLength']=function(_0x54262e){return 0x0===_0x54262e||0x1===_0x54262e?this:this['scaleInPlace'](0x1/_0x54262e);},_0x4d7c8e['prototype']['normalizeToNew']=function(){var _0x2807ea=new _0x4d7c8e(0x0,0x0,0x0);return this['normalizeToRef'](_0x2807ea),_0x2807ea;},_0x4d7c8e['prototype']['normalizeToRef']=function(_0x2c1a33){var _0xc5e834=this['length']();return 0x0===_0xc5e834||0x1===_0xc5e834?_0x2c1a33['copyFromFloats'](this['_x'],this['_y'],this['_z']):this['scaleToRef'](0x1/_0xc5e834,_0x2c1a33);},_0x4d7c8e['prototype']['clone']=function(){return new _0x4d7c8e(this['_x'],this['_y'],this['_z']);},_0x4d7c8e['prototype']['copyFrom']=function(_0x417c5d){return this['copyFromFloats'](_0x417c5d['_x'],_0x417c5d['_y'],_0x417c5d['_z']);},_0x4d7c8e['prototype']['copyFromFloats']=function(_0x462e3f,_0x7881f8,_0x164845){return this['x']=_0x462e3f,this['y']=_0x7881f8,this['z']=_0x164845,this;},_0x4d7c8e['prototype']['set']=function(_0x177cbb,_0x5284f4,_0x53b760){return this['copyFromFloats'](_0x177cbb,_0x5284f4,_0x53b760);},_0x4d7c8e['prototype']['setAll']=function(_0x350103){return this['x']=this['y']=this['z']=_0x350103,this;},_0x4d7c8e['GetClipFactor']=function(_0x4dbf21,_0x4ead81,_0x1b6d43,_0x50d2bc){var _0x4c7471=_0x4d7c8e['Dot'](_0x4dbf21,_0x1b6d43)-_0x50d2bc;return _0x4c7471/(_0x4c7471-(_0x4d7c8e['Dot'](_0x4ead81,_0x1b6d43)-_0x50d2bc));},_0x4d7c8e['GetAngleBetweenVectors']=function(_0x17a5c9,_0x481a7b,_0x49fe4a){var _0x3471c7=_0x17a5c9['normalizeToRef'](_0x4e1745['Vector3'][0x1]),_0x7cd3c5=_0x481a7b['normalizeToRef'](_0x4e1745['Vector3'][0x2]),_0x365090=_0x4d7c8e['Dot'](_0x3471c7,_0x7cd3c5),_0x5822cf=_0x4e1745['Vector3'][0x3];return _0x4d7c8e['CrossToRef'](_0x3471c7,_0x7cd3c5,_0x5822cf),_0x4d7c8e['Dot'](_0x5822cf,_0x49fe4a)>0x0?Math['acos'](_0x365090):-Math['acos'](_0x365090);},_0x4d7c8e['FromArray']=function(_0x6183a,_0x30e68f){return void 0x0===_0x30e68f&&(_0x30e68f=0x0),new _0x4d7c8e(_0x6183a[_0x30e68f],_0x6183a[_0x30e68f+0x1],_0x6183a[_0x30e68f+0x2]);},_0x4d7c8e['FromFloatArray']=function(_0x4653dd,_0x360e9f){return _0x4d7c8e['FromArray'](_0x4653dd,_0x360e9f);},_0x4d7c8e['FromArrayToRef']=function(_0x14ee39,_0x238223,_0x34dddc){_0x34dddc['x']=_0x14ee39[_0x238223],_0x34dddc['y']=_0x14ee39[_0x238223+0x1],_0x34dddc['z']=_0x14ee39[_0x238223+0x2];},_0x4d7c8e['FromFloatArrayToRef']=function(_0x404616,_0x2ea723,_0x523db8){return _0x4d7c8e['FromArrayToRef'](_0x404616,_0x2ea723,_0x523db8);},_0x4d7c8e['FromFloatsToRef']=function(_0x3d0023,_0x2ae130,_0x4490b6,_0x225254){_0x225254['copyFromFloats'](_0x3d0023,_0x2ae130,_0x4490b6);},_0x4d7c8e['Zero']=function(){return new _0x4d7c8e(0x0,0x0,0x0);},_0x4d7c8e['One']=function(){return new _0x4d7c8e(0x1,0x1,0x1);},_0x4d7c8e['Up']=function(){return new _0x4d7c8e(0x0,0x1,0x0);},Object['defineProperty'](_0x4d7c8e,'UpReadOnly',{'get':function(){return _0x4d7c8e['_UpReadOnly'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4d7c8e,'ZeroReadOnly',{'get':function(){return _0x4d7c8e['_ZeroReadOnly'];},'enumerable':!0x1,'configurable':!0x0}),_0x4d7c8e['Down']=function(){return new _0x4d7c8e(0x0,-0x1,0x0);},_0x4d7c8e['Forward']=function(_0x262ad0){return void 0x0===_0x262ad0&&(_0x262ad0=!0x1),new _0x4d7c8e(0x0,0x0,_0x262ad0?-0x1:0x1);},_0x4d7c8e['Backward']=function(_0x452b24){return void 0x0===_0x452b24&&(_0x452b24=!0x1),new _0x4d7c8e(0x0,0x0,_0x452b24?0x1:-0x1);},_0x4d7c8e['Right']=function(){return new _0x4d7c8e(0x1,0x0,0x0);},_0x4d7c8e['Left']=function(){return new _0x4d7c8e(-0x1,0x0,0x0);},_0x4d7c8e['TransformCoordinates']=function(_0x44e722,_0x414b38){var _0x4b2c5a=_0x4d7c8e['Zero']();return _0x4d7c8e['TransformCoordinatesToRef'](_0x44e722,_0x414b38,_0x4b2c5a),_0x4b2c5a;},_0x4d7c8e['TransformCoordinatesToRef']=function(_0x5be8fe,_0x289361,_0x2dba89){_0x4d7c8e['TransformCoordinatesFromFloatsToRef'](_0x5be8fe['_x'],_0x5be8fe['_y'],_0x5be8fe['_z'],_0x289361,_0x2dba89);},_0x4d7c8e['TransformCoordinatesFromFloatsToRef']=function(_0x114296,_0x4429d4,_0x132b7b,_0x2effe7,_0x1ae912){var _0x4a97b2=_0x2effe7['m'],_0x5b42c6=_0x114296*_0x4a97b2[0x0]+_0x4429d4*_0x4a97b2[0x4]+_0x132b7b*_0x4a97b2[0x8]+_0x4a97b2[0xc],_0x3b3d3b=_0x114296*_0x4a97b2[0x1]+_0x4429d4*_0x4a97b2[0x5]+_0x132b7b*_0x4a97b2[0x9]+_0x4a97b2[0xd],_0x233301=_0x114296*_0x4a97b2[0x2]+_0x4429d4*_0x4a97b2[0x6]+_0x132b7b*_0x4a97b2[0xa]+_0x4a97b2[0xe],_0x178409=0x1/(_0x114296*_0x4a97b2[0x3]+_0x4429d4*_0x4a97b2[0x7]+_0x132b7b*_0x4a97b2[0xb]+_0x4a97b2[0xf]);_0x1ae912['x']=_0x5b42c6*_0x178409,_0x1ae912['y']=_0x3b3d3b*_0x178409,_0x1ae912['z']=_0x233301*_0x178409;},_0x4d7c8e['TransformNormal']=function(_0x5d7d64,_0x22217e){var _0x231351=_0x4d7c8e['Zero']();return _0x4d7c8e['TransformNormalToRef'](_0x5d7d64,_0x22217e,_0x231351),_0x231351;},_0x4d7c8e['TransformNormalToRef']=function(_0xeb3857,_0x5ce388,_0x1cb910){this['TransformNormalFromFloatsToRef'](_0xeb3857['_x'],_0xeb3857['_y'],_0xeb3857['_z'],_0x5ce388,_0x1cb910);},_0x4d7c8e['TransformNormalFromFloatsToRef']=function(_0x33a4b2,_0x272e96,_0x11987e,_0x1bc09d,_0x473c40){var _0x3416d9=_0x1bc09d['m'];_0x473c40['x']=_0x33a4b2*_0x3416d9[0x0]+_0x272e96*_0x3416d9[0x4]+_0x11987e*_0x3416d9[0x8],_0x473c40['y']=_0x33a4b2*_0x3416d9[0x1]+_0x272e96*_0x3416d9[0x5]+_0x11987e*_0x3416d9[0x9],_0x473c40['z']=_0x33a4b2*_0x3416d9[0x2]+_0x272e96*_0x3416d9[0x6]+_0x11987e*_0x3416d9[0xa];},_0x4d7c8e['CatmullRom']=function(_0x57d9ae,_0x18876a,_0x212b04,_0xc3cab5,_0x2b5d34){var _0x417911=_0x2b5d34*_0x2b5d34,_0x207b55=_0x2b5d34*_0x417911;return new _0x4d7c8e(0.5*(0x2*_0x18876a['_x']+(-_0x57d9ae['_x']+_0x212b04['_x'])*_0x2b5d34+(0x2*_0x57d9ae['_x']-0x5*_0x18876a['_x']+0x4*_0x212b04['_x']-_0xc3cab5['_x'])*_0x417911+(-_0x57d9ae['_x']+0x3*_0x18876a['_x']-0x3*_0x212b04['_x']+_0xc3cab5['_x'])*_0x207b55),0.5*(0x2*_0x18876a['_y']+(-_0x57d9ae['_y']+_0x212b04['_y'])*_0x2b5d34+(0x2*_0x57d9ae['_y']-0x5*_0x18876a['_y']+0x4*_0x212b04['_y']-_0xc3cab5['_y'])*_0x417911+(-_0x57d9ae['_y']+0x3*_0x18876a['_y']-0x3*_0x212b04['_y']+_0xc3cab5['_y'])*_0x207b55),0.5*(0x2*_0x18876a['_z']+(-_0x57d9ae['_z']+_0x212b04['_z'])*_0x2b5d34+(0x2*_0x57d9ae['_z']-0x5*_0x18876a['_z']+0x4*_0x212b04['_z']-_0xc3cab5['_z'])*_0x417911+(-_0x57d9ae['_z']+0x3*_0x18876a['_z']-0x3*_0x212b04['_z']+_0xc3cab5['_z'])*_0x207b55));},_0x4d7c8e['Clamp']=function(_0x391098,_0x4147ff,_0x4d1e2b){var _0x12ba38=new _0x4d7c8e();return _0x4d7c8e['ClampToRef'](_0x391098,_0x4147ff,_0x4d1e2b,_0x12ba38),_0x12ba38;},_0x4d7c8e['ClampToRef']=function(_0x2ba81e,_0x13a063,_0x5c09eb,_0x313944){var _0x1d155f=_0x2ba81e['_x'];_0x1d155f=(_0x1d155f=_0x1d155f>_0x5c09eb['_x']?_0x5c09eb['_x']:_0x1d155f)<_0x13a063['_x']?_0x13a063['_x']:_0x1d155f;var _0x5d93ca=_0x2ba81e['_y'];_0x5d93ca=(_0x5d93ca=_0x5d93ca>_0x5c09eb['_y']?_0x5c09eb['_y']:_0x5d93ca)<_0x13a063['_y']?_0x13a063['_y']:_0x5d93ca;var _0x363cda=_0x2ba81e['_z'];_0x363cda=(_0x363cda=_0x363cda>_0x5c09eb['_z']?_0x5c09eb['_z']:_0x363cda)<_0x13a063['_z']?_0x13a063['_z']:_0x363cda,_0x313944['copyFromFloats'](_0x1d155f,_0x5d93ca,_0x363cda);},_0x4d7c8e['CheckExtends']=function(_0x3c739c,_0xd7ee71,_0x1d3f65){_0xd7ee71['minimizeInPlace'](_0x3c739c),_0x1d3f65['maximizeInPlace'](_0x3c739c);},_0x4d7c8e['Hermite']=function(_0x1d9f5e,_0x32903a,_0x374c0b,_0x1db988,_0x54b378){var _0x102728=_0x54b378*_0x54b378,_0x2ba57f=_0x54b378*_0x102728,_0x27a16a=0x2*_0x2ba57f-0x3*_0x102728+0x1,_0x115b46=-0x2*_0x2ba57f+0x3*_0x102728,_0xef3abe=_0x2ba57f-0x2*_0x102728+_0x54b378,_0x4bec86=_0x2ba57f-_0x102728;return new _0x4d7c8e(_0x1d9f5e['_x']*_0x27a16a+_0x374c0b['_x']*_0x115b46+_0x32903a['_x']*_0xef3abe+_0x1db988['_x']*_0x4bec86,_0x1d9f5e['_y']*_0x27a16a+_0x374c0b['_y']*_0x115b46+_0x32903a['_y']*_0xef3abe+_0x1db988['_y']*_0x4bec86,_0x1d9f5e['_z']*_0x27a16a+_0x374c0b['_z']*_0x115b46+_0x32903a['_z']*_0xef3abe+_0x1db988['_z']*_0x4bec86);},_0x4d7c8e['Lerp']=function(_0x30ef30,_0x26d7ea,_0x4d7f01){var _0x24c1e5=new _0x4d7c8e(0x0,0x0,0x0);return _0x4d7c8e['LerpToRef'](_0x30ef30,_0x26d7ea,_0x4d7f01,_0x24c1e5),_0x24c1e5;},_0x4d7c8e['LerpToRef']=function(_0xc58df0,_0x9a9fd2,_0x46e7a2,_0x353290){_0x353290['x']=_0xc58df0['_x']+(_0x9a9fd2['_x']-_0xc58df0['_x'])*_0x46e7a2,_0x353290['y']=_0xc58df0['_y']+(_0x9a9fd2['_y']-_0xc58df0['_y'])*_0x46e7a2,_0x353290['z']=_0xc58df0['_z']+(_0x9a9fd2['_z']-_0xc58df0['_z'])*_0x46e7a2;},_0x4d7c8e['Dot']=function(_0x7bf992,_0x259263){return _0x7bf992['_x']*_0x259263['_x']+_0x7bf992['_y']*_0x259263['_y']+_0x7bf992['_z']*_0x259263['_z'];},_0x4d7c8e['Cross']=function(_0x45a785,_0x1f3646){var _0x3164c9=_0x4d7c8e['Zero']();return _0x4d7c8e['CrossToRef'](_0x45a785,_0x1f3646,_0x3164c9),_0x3164c9;},_0x4d7c8e['CrossToRef']=function(_0x455c85,_0x21c692,_0x1dd2f2){var _0x1e5c33=_0x455c85['_y']*_0x21c692['_z']-_0x455c85['_z']*_0x21c692['_y'],_0x2acabf=_0x455c85['_z']*_0x21c692['_x']-_0x455c85['_x']*_0x21c692['_z'],_0x428612=_0x455c85['_x']*_0x21c692['_y']-_0x455c85['_y']*_0x21c692['_x'];_0x1dd2f2['copyFromFloats'](_0x1e5c33,_0x2acabf,_0x428612);},_0x4d7c8e['Normalize']=function(_0x13c12f){var _0x3aedeb=_0x4d7c8e['Zero']();return _0x4d7c8e['NormalizeToRef'](_0x13c12f,_0x3aedeb),_0x3aedeb;},_0x4d7c8e['NormalizeToRef']=function(_0x1cf84a,_0x520922){_0x1cf84a['normalizeToRef'](_0x520922);},_0x4d7c8e['Project']=function(_0x180a23,_0x35ce17,_0x4aa822,_0x1716b4){var _0x5ce2fc=new _0x4d7c8e();return _0x4d7c8e['ProjectToRef'](_0x180a23,_0x35ce17,_0x4aa822,_0x1716b4,_0x5ce2fc),_0x5ce2fc;},_0x4d7c8e['ProjectToRef']=function(_0x264371,_0x1534d9,_0x5a4951,_0x54efe4,_0x8e935){var _0x148954=_0x54efe4['width'],_0x12e976=_0x54efe4['height'],_0x2bdaf0=_0x54efe4['x'],_0x3cc510=_0x54efe4['y'],_0x148da8=_0x4e1745['Matrix'][0x1];_0x54ba40['FromValuesToRef'](_0x148954/0x2,0x0,0x0,0x0,0x0,-_0x12e976/0x2,0x0,0x0,0x0,0x0,0.5,0x0,_0x2bdaf0+_0x148954/0x2,_0x12e976/0x2+_0x3cc510,0.5,0x1,_0x148da8);var _0x2b0414=_0x4e1745['Matrix'][0x0];return _0x1534d9['multiplyToRef'](_0x5a4951,_0x2b0414),_0x2b0414['multiplyToRef'](_0x148da8,_0x2b0414),_0x4d7c8e['TransformCoordinatesToRef'](_0x264371,_0x2b0414,_0x8e935),_0x8e935;},_0x4d7c8e['_UnprojectFromInvertedMatrixToRef']=function(_0x77fe8c,_0x30a3fd,_0xfc4b63){_0x4d7c8e['TransformCoordinatesToRef'](_0x77fe8c,_0x30a3fd,_0xfc4b63);var _0x170019=_0x30a3fd['m'],_0x5ab183=_0x77fe8c['_x']*_0x170019[0x3]+_0x77fe8c['_y']*_0x170019[0x7]+_0x77fe8c['_z']*_0x170019[0xb]+_0x170019[0xf];_0x109042['a']['WithinEpsilon'](_0x5ab183,0x1)&&_0xfc4b63['scaleInPlace'](0x1/_0x5ab183);},_0x4d7c8e['UnprojectFromTransform']=function(_0x38d84a,_0x3e13e4,_0x4414d5,_0x72c91f,_0x1245b7){var _0x2b89c9=_0x4e1745['Matrix'][0x0];_0x72c91f['multiplyToRef'](_0x1245b7,_0x2b89c9),_0x2b89c9['invert'](),_0x38d84a['x']=_0x38d84a['_x']/_0x3e13e4*0x2-0x1,_0x38d84a['y']=-(_0x38d84a['_y']/_0x4414d5*0x2-0x1);var _0x37442f=new _0x4d7c8e();return _0x4d7c8e['_UnprojectFromInvertedMatrixToRef'](_0x38d84a,_0x2b89c9,_0x37442f),_0x37442f;},_0x4d7c8e['Unproject']=function(_0x2453e9,_0x4a0ebf,_0x112949,_0x163a86,_0x1eb08a,_0x5e8a9e){var _0xe0187f=_0x4d7c8e['Zero']();return _0x4d7c8e['UnprojectToRef'](_0x2453e9,_0x4a0ebf,_0x112949,_0x163a86,_0x1eb08a,_0x5e8a9e,_0xe0187f),_0xe0187f;},_0x4d7c8e['UnprojectToRef']=function(_0x59a339,_0x2631bc,_0x8470cf,_0x28b1f0,_0x42c52d,_0x318456,_0x3e1f25){_0x4d7c8e['UnprojectFloatsToRef'](_0x59a339['_x'],_0x59a339['_y'],_0x59a339['_z'],_0x2631bc,_0x8470cf,_0x28b1f0,_0x42c52d,_0x318456,_0x3e1f25);},_0x4d7c8e['UnprojectFloatsToRef']=function(_0xdbbb00,_0x3ef714,_0x1ea473,_0x13a5a3,_0x200ced,_0x5e1978,_0x7693c5,_0x507766,_0x1ebff4){var _0x45b39a=_0x4e1745['Matrix'][0x0];_0x5e1978['multiplyToRef'](_0x7693c5,_0x45b39a),_0x45b39a['multiplyToRef'](_0x507766,_0x45b39a),_0x45b39a['invert']();var _0x2e72d1=_0x4e1745['Vector3'][0x0];_0x2e72d1['x']=_0xdbbb00/_0x13a5a3*0x2-0x1,_0x2e72d1['y']=-(_0x3ef714/_0x200ced*0x2-0x1),_0x2e72d1['z']=0x2*_0x1ea473-0x1,_0x4d7c8e['_UnprojectFromInvertedMatrixToRef'](_0x2e72d1,_0x45b39a,_0x1ebff4);},_0x4d7c8e['Minimize']=function(_0x57a706,_0x2bcdfb){var _0x533953=_0x57a706['clone']();return _0x533953['minimizeInPlace'](_0x2bcdfb),_0x533953;},_0x4d7c8e['Maximize']=function(_0x45ba0f,_0x380088){var _0x217274=_0x45ba0f['clone']();return _0x217274['maximizeInPlace'](_0x380088),_0x217274;},_0x4d7c8e['Distance']=function(_0x2145d6,_0x41013e){return Math['sqrt'](_0x4d7c8e['DistanceSquared'](_0x2145d6,_0x41013e));},_0x4d7c8e['DistanceSquared']=function(_0xcdbde3,_0x5e39e3){var _0x35ef96=_0xcdbde3['_x']-_0x5e39e3['_x'],_0x277dc2=_0xcdbde3['_y']-_0x5e39e3['_y'],_0x2edd75=_0xcdbde3['_z']-_0x5e39e3['_z'];return _0x35ef96*_0x35ef96+_0x277dc2*_0x277dc2+_0x2edd75*_0x2edd75;},_0x4d7c8e['Center']=function(_0x5df36a,_0x5a9049){var _0x44e976=_0x5df36a['add'](_0x5a9049);return _0x44e976['scaleInPlace'](0.5),_0x44e976;},_0x4d7c8e['RotationFromAxis']=function(_0x4b9152,_0x358ee5,_0x3bd93b){var _0xb86582=_0x4d7c8e['Zero']();return _0x4d7c8e['RotationFromAxisToRef'](_0x4b9152,_0x358ee5,_0x3bd93b,_0xb86582),_0xb86582;},_0x4d7c8e['RotationFromAxisToRef']=function(_0x282882,_0x5d4899,_0x523ca9,_0x33cea1){var _0x10f504=_0x4e1745['Quaternion'][0x0];_0x336fc5['RotationQuaternionFromAxisToRef'](_0x282882,_0x5d4899,_0x523ca9,_0x10f504),_0x10f504['toEulerAnglesToRef'](_0x33cea1);},_0x4d7c8e['_UpReadOnly']=_0x4d7c8e['Up'](),_0x4d7c8e['_ZeroReadOnly']=_0x4d7c8e['Zero'](),_0x4d7c8e;}()),_0xfab42b=(function(){function _0x44519f(_0x376d4e,_0x43db45,_0x137635,_0x514715){this['x']=_0x376d4e,this['y']=_0x43db45,this['z']=_0x137635,this['w']=_0x514715;}return _0x44519f['prototype']['toString']=function(){return'{X:\x20'+this['x']+'\x20Y:'+this['y']+'\x20Z:'+this['z']+'\x20W:'+this['w']+'}';},_0x44519f['prototype']['getClassName']=function(){return'Vector4';},_0x44519f['prototype']['getHashCode']=function(){var _0x528808=0x0|this['x'];return _0x528808=0x18d*(_0x528808=0x18d*(_0x528808=0x18d*_0x528808^(0x0|this['y']))^(0x0|this['z']))^(0x0|this['w']);},_0x44519f['prototype']['asArray']=function(){var _0x4fba69=new Array();return this['toArray'](_0x4fba69,0x0),_0x4fba69;},_0x44519f['prototype']['toArray']=function(_0x5a5a62,_0x1a715b){return void 0x0===_0x1a715b&&(_0x1a715b=0x0),_0x5a5a62[_0x1a715b]=this['x'],_0x5a5a62[_0x1a715b+0x1]=this['y'],_0x5a5a62[_0x1a715b+0x2]=this['z'],_0x5a5a62[_0x1a715b+0x3]=this['w'],this;},_0x44519f['prototype']['fromArray']=function(_0x3d38a7,_0x4e419d){return void 0x0===_0x4e419d&&(_0x4e419d=0x0),_0x44519f['FromArrayToRef'](_0x3d38a7,_0x4e419d,this),this;},_0x44519f['prototype']['addInPlace']=function(_0x54732d){return this['x']+=_0x54732d['x'],this['y']+=_0x54732d['y'],this['z']+=_0x54732d['z'],this['w']+=_0x54732d['w'],this;},_0x44519f['prototype']['add']=function(_0xe51534){return new _0x44519f(this['x']+_0xe51534['x'],this['y']+_0xe51534['y'],this['z']+_0xe51534['z'],this['w']+_0xe51534['w']);},_0x44519f['prototype']['addToRef']=function(_0x967fa1,_0x3dd2a7){return _0x3dd2a7['x']=this['x']+_0x967fa1['x'],_0x3dd2a7['y']=this['y']+_0x967fa1['y'],_0x3dd2a7['z']=this['z']+_0x967fa1['z'],_0x3dd2a7['w']=this['w']+_0x967fa1['w'],this;},_0x44519f['prototype']['subtractInPlace']=function(_0x35ff0a){return this['x']-=_0x35ff0a['x'],this['y']-=_0x35ff0a['y'],this['z']-=_0x35ff0a['z'],this['w']-=_0x35ff0a['w'],this;},_0x44519f['prototype']['subtract']=function(_0x4cea58){return new _0x44519f(this['x']-_0x4cea58['x'],this['y']-_0x4cea58['y'],this['z']-_0x4cea58['z'],this['w']-_0x4cea58['w']);},_0x44519f['prototype']['subtractToRef']=function(_0x2bdacc,_0xb0576d){return _0xb0576d['x']=this['x']-_0x2bdacc['x'],_0xb0576d['y']=this['y']-_0x2bdacc['y'],_0xb0576d['z']=this['z']-_0x2bdacc['z'],_0xb0576d['w']=this['w']-_0x2bdacc['w'],this;},_0x44519f['prototype']['subtractFromFloats']=function(_0x5dc04e,_0x1cc1be,_0x5a71d6,_0x1bb18d){return new _0x44519f(this['x']-_0x5dc04e,this['y']-_0x1cc1be,this['z']-_0x5a71d6,this['w']-_0x1bb18d);},_0x44519f['prototype']['subtractFromFloatsToRef']=function(_0x37adfb,_0x3e49ab,_0x23d821,_0x47f36f,_0x30d0d6){return _0x30d0d6['x']=this['x']-_0x37adfb,_0x30d0d6['y']=this['y']-_0x3e49ab,_0x30d0d6['z']=this['z']-_0x23d821,_0x30d0d6['w']=this['w']-_0x47f36f,this;},_0x44519f['prototype']['negate']=function(){return new _0x44519f(-this['x'],-this['y'],-this['z'],-this['w']);},_0x44519f['prototype']['negateInPlace']=function(){return this['x']*=-0x1,this['y']*=-0x1,this['z']*=-0x1,this['w']*=-0x1,this;},_0x44519f['prototype']['negateToRef']=function(_0x4710de){return _0x4710de['copyFromFloats'](-0x1*this['x'],-0x1*this['y'],-0x1*this['z'],-0x1*this['w']);},_0x44519f['prototype']['scaleInPlace']=function(_0x4ec305){return this['x']*=_0x4ec305,this['y']*=_0x4ec305,this['z']*=_0x4ec305,this['w']*=_0x4ec305,this;},_0x44519f['prototype']['scale']=function(_0x21dab1){return new _0x44519f(this['x']*_0x21dab1,this['y']*_0x21dab1,this['z']*_0x21dab1,this['w']*_0x21dab1);},_0x44519f['prototype']['scaleToRef']=function(_0x46a7f0,_0x2d5285){return _0x2d5285['x']=this['x']*_0x46a7f0,_0x2d5285['y']=this['y']*_0x46a7f0,_0x2d5285['z']=this['z']*_0x46a7f0,_0x2d5285['w']=this['w']*_0x46a7f0,this;},_0x44519f['prototype']['scaleAndAddToRef']=function(_0x186335,_0x4948e0){return _0x4948e0['x']+=this['x']*_0x186335,_0x4948e0['y']+=this['y']*_0x186335,_0x4948e0['z']+=this['z']*_0x186335,_0x4948e0['w']+=this['w']*_0x186335,this;},_0x44519f['prototype']['equals']=function(_0x11be7d){return _0x11be7d&&this['x']===_0x11be7d['x']&&this['y']===_0x11be7d['y']&&this['z']===_0x11be7d['z']&&this['w']===_0x11be7d['w'];},_0x44519f['prototype']['equalsWithEpsilon']=function(_0x51ead9,_0x5134fc){return void 0x0===_0x5134fc&&(_0x5134fc=_0x9e8480['a']),_0x51ead9&&_0x109042['a']['WithinEpsilon'](this['x'],_0x51ead9['x'],_0x5134fc)&&_0x109042['a']['WithinEpsilon'](this['y'],_0x51ead9['y'],_0x5134fc)&&_0x109042['a']['WithinEpsilon'](this['z'],_0x51ead9['z'],_0x5134fc)&&_0x109042['a']['WithinEpsilon'](this['w'],_0x51ead9['w'],_0x5134fc);},_0x44519f['prototype']['equalsToFloats']=function(_0x78811f,_0x589584,_0x4f420d,_0x27ae8e){return this['x']===_0x78811f&&this['y']===_0x589584&&this['z']===_0x4f420d&&this['w']===_0x27ae8e;},_0x44519f['prototype']['multiplyInPlace']=function(_0x2b3b36){return this['x']*=_0x2b3b36['x'],this['y']*=_0x2b3b36['y'],this['z']*=_0x2b3b36['z'],this['w']*=_0x2b3b36['w'],this;},_0x44519f['prototype']['multiply']=function(_0x4e535e){return new _0x44519f(this['x']*_0x4e535e['x'],this['y']*_0x4e535e['y'],this['z']*_0x4e535e['z'],this['w']*_0x4e535e['w']);},_0x44519f['prototype']['multiplyToRef']=function(_0x3b35d0,_0x152189){return _0x152189['x']=this['x']*_0x3b35d0['x'],_0x152189['y']=this['y']*_0x3b35d0['y'],_0x152189['z']=this['z']*_0x3b35d0['z'],_0x152189['w']=this['w']*_0x3b35d0['w'],this;},_0x44519f['prototype']['multiplyByFloats']=function(_0xf0729b,_0x3bf08a,_0x2f6195,_0x3e5bc6){return new _0x44519f(this['x']*_0xf0729b,this['y']*_0x3bf08a,this['z']*_0x2f6195,this['w']*_0x3e5bc6);},_0x44519f['prototype']['divide']=function(_0xb54748){return new _0x44519f(this['x']/_0xb54748['x'],this['y']/_0xb54748['y'],this['z']/_0xb54748['z'],this['w']/_0xb54748['w']);},_0x44519f['prototype']['divideToRef']=function(_0x4f2a51,_0xbfbc70){return _0xbfbc70['x']=this['x']/_0x4f2a51['x'],_0xbfbc70['y']=this['y']/_0x4f2a51['y'],_0xbfbc70['z']=this['z']/_0x4f2a51['z'],_0xbfbc70['w']=this['w']/_0x4f2a51['w'],this;},_0x44519f['prototype']['divideInPlace']=function(_0x210eef){return this['divideToRef'](_0x210eef,this);},_0x44519f['prototype']['minimizeInPlace']=function(_0x1e4b08){return _0x1e4b08['x']this['x']&&(this['x']=_0x5d768a['x']),_0x5d768a['y']>this['y']&&(this['y']=_0x5d768a['y']),_0x5d768a['z']>this['z']&&(this['z']=_0x5d768a['z']),_0x5d768a['w']>this['w']&&(this['w']=_0x5d768a['w']),this;},_0x44519f['prototype']['floor']=function(){return new _0x44519f(Math['floor'](this['x']),Math['floor'](this['y']),Math['floor'](this['z']),Math['floor'](this['w']));},_0x44519f['prototype']['fract']=function(){return new _0x44519f(this['x']-Math['floor'](this['x']),this['y']-Math['floor'](this['y']),this['z']-Math['floor'](this['z']),this['w']-Math['floor'](this['w']));},_0x44519f['prototype']['length']=function(){return Math['sqrt'](this['x']*this['x']+this['y']*this['y']+this['z']*this['z']+this['w']*this['w']);},_0x44519f['prototype']['lengthSquared']=function(){return this['x']*this['x']+this['y']*this['y']+this['z']*this['z']+this['w']*this['w'];},_0x44519f['prototype']['normalize']=function(){var _0x215767=this['length']();return 0x0===_0x215767?this:this['scaleInPlace'](0x1/_0x215767);},_0x44519f['prototype']['toVector3']=function(){return new _0x39af4b(this['x'],this['y'],this['z']);},_0x44519f['prototype']['clone']=function(){return new _0x44519f(this['x'],this['y'],this['z'],this['w']);},_0x44519f['prototype']['copyFrom']=function(_0x393c14){return this['x']=_0x393c14['x'],this['y']=_0x393c14['y'],this['z']=_0x393c14['z'],this['w']=_0x393c14['w'],this;},_0x44519f['prototype']['copyFromFloats']=function(_0x57c268,_0x34b0cf,_0x33d72a,_0x503e3c){return this['x']=_0x57c268,this['y']=_0x34b0cf,this['z']=_0x33d72a,this['w']=_0x503e3c,this;},_0x44519f['prototype']['set']=function(_0x1a36fa,_0x91f0e2,_0x3b63c6,_0x5a9e24){return this['copyFromFloats'](_0x1a36fa,_0x91f0e2,_0x3b63c6,_0x5a9e24);},_0x44519f['prototype']['setAll']=function(_0x26e4f5){return this['x']=this['y']=this['z']=this['w']=_0x26e4f5,this;},_0x44519f['FromArray']=function(_0x286c65,_0x5a5fa2){return _0x5a5fa2||(_0x5a5fa2=0x0),new _0x44519f(_0x286c65[_0x5a5fa2],_0x286c65[_0x5a5fa2+0x1],_0x286c65[_0x5a5fa2+0x2],_0x286c65[_0x5a5fa2+0x3]);},_0x44519f['FromArrayToRef']=function(_0x495043,_0x350b4f,_0x13e99e){_0x13e99e['x']=_0x495043[_0x350b4f],_0x13e99e['y']=_0x495043[_0x350b4f+0x1],_0x13e99e['z']=_0x495043[_0x350b4f+0x2],_0x13e99e['w']=_0x495043[_0x350b4f+0x3];},_0x44519f['FromFloatArrayToRef']=function(_0x4bbdf9,_0x459629,_0x110ca4){_0x44519f['FromArrayToRef'](_0x4bbdf9,_0x459629,_0x110ca4);},_0x44519f['FromFloatsToRef']=function(_0x1b6c3f,_0x1a664a,_0x18e5ee,_0x314892,_0x1b3192){_0x1b3192['x']=_0x1b6c3f,_0x1b3192['y']=_0x1a664a,_0x1b3192['z']=_0x18e5ee,_0x1b3192['w']=_0x314892;},_0x44519f['Zero']=function(){return new _0x44519f(0x0,0x0,0x0,0x0);},_0x44519f['One']=function(){return new _0x44519f(0x1,0x1,0x1,0x1);},_0x44519f['Normalize']=function(_0x57156d){var _0x52908f=_0x44519f['Zero']();return _0x44519f['NormalizeToRef'](_0x57156d,_0x52908f),_0x52908f;},_0x44519f['NormalizeToRef']=function(_0x81eaa5,_0x1a2570){_0x1a2570['copyFrom'](_0x81eaa5),_0x1a2570['normalize']();},_0x44519f['Minimize']=function(_0x55dfc3,_0x40a39f){var _0x5895f1=_0x55dfc3['clone']();return _0x5895f1['minimizeInPlace'](_0x40a39f),_0x5895f1;},_0x44519f['Maximize']=function(_0x2fdf25,_0x459b29){var _0x5c8775=_0x2fdf25['clone']();return _0x5c8775['maximizeInPlace'](_0x459b29),_0x5c8775;},_0x44519f['Distance']=function(_0x612f3e,_0x24723a){return Math['sqrt'](_0x44519f['DistanceSquared'](_0x612f3e,_0x24723a));},_0x44519f['DistanceSquared']=function(_0x53b862,_0x535145){var _0x2efedd=_0x53b862['x']-_0x535145['x'],_0x5c3e29=_0x53b862['y']-_0x535145['y'],_0x2dd935=_0x53b862['z']-_0x535145['z'],_0x44432c=_0x53b862['w']-_0x535145['w'];return _0x2efedd*_0x2efedd+_0x5c3e29*_0x5c3e29+_0x2dd935*_0x2dd935+_0x44432c*_0x44432c;},_0x44519f['Center']=function(_0x3a260d,_0x4e925f){var _0x32e6b8=_0x3a260d['add'](_0x4e925f);return _0x32e6b8['scaleInPlace'](0.5),_0x32e6b8;},_0x44519f['TransformNormal']=function(_0x4a44b6,_0x9491fd){var _0xf881dd=_0x44519f['Zero']();return _0x44519f['TransformNormalToRef'](_0x4a44b6,_0x9491fd,_0xf881dd),_0xf881dd;},_0x44519f['TransformNormalToRef']=function(_0x2e8791,_0x46fcb2,_0x3d867b){var _0x3cdb93=_0x46fcb2['m'],_0x357c3c=_0x2e8791['x']*_0x3cdb93[0x0]+_0x2e8791['y']*_0x3cdb93[0x4]+_0x2e8791['z']*_0x3cdb93[0x8],_0x347c26=_0x2e8791['x']*_0x3cdb93[0x1]+_0x2e8791['y']*_0x3cdb93[0x5]+_0x2e8791['z']*_0x3cdb93[0x9],_0x3abfc9=_0x2e8791['x']*_0x3cdb93[0x2]+_0x2e8791['y']*_0x3cdb93[0x6]+_0x2e8791['z']*_0x3cdb93[0xa];_0x3d867b['x']=_0x357c3c,_0x3d867b['y']=_0x347c26,_0x3d867b['z']=_0x3abfc9,_0x3d867b['w']=_0x2e8791['w'];},_0x44519f['TransformNormalFromFloatsToRef']=function(_0x2b302b,_0x1ebd16,_0x4b99e3,_0x2c4482,_0x1f3e1e,_0x3516f9){var _0x52b799=_0x1f3e1e['m'];_0x3516f9['x']=_0x2b302b*_0x52b799[0x0]+_0x1ebd16*_0x52b799[0x4]+_0x4b99e3*_0x52b799[0x8],_0x3516f9['y']=_0x2b302b*_0x52b799[0x1]+_0x1ebd16*_0x52b799[0x5]+_0x4b99e3*_0x52b799[0x9],_0x3516f9['z']=_0x2b302b*_0x52b799[0x2]+_0x1ebd16*_0x52b799[0x6]+_0x4b99e3*_0x52b799[0xa],_0x3516f9['w']=_0x2c4482;},_0x44519f['FromVector3']=function(_0x5e16cd,_0x1764cc){return void 0x0===_0x1764cc&&(_0x1764cc=0x0),new _0x44519f(_0x5e16cd['_x'],_0x5e16cd['_y'],_0x5e16cd['_z'],_0x1764cc);},_0x44519f;}()),_0x336fc5=(function(){function _0x2b1c0b(_0x4d566d,_0x269a43,_0x1fab22,_0x131847){void 0x0===_0x4d566d&&(_0x4d566d=0x0),void 0x0===_0x269a43&&(_0x269a43=0x0),void 0x0===_0x1fab22&&(_0x1fab22=0x0),void 0x0===_0x131847&&(_0x131847=0x1),this['_isDirty']=!0x0,this['_x']=_0x4d566d,this['_y']=_0x269a43,this['_z']=_0x1fab22,this['_w']=_0x131847;}return Object['defineProperty'](_0x2b1c0b['prototype'],'x',{'get':function(){return this['_x'];},'set':function(_0x39581c){this['_x']=_0x39581c,this['_isDirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2b1c0b['prototype'],'y',{'get':function(){return this['_y'];},'set':function(_0x2c1ebb){this['_y']=_0x2c1ebb,this['_isDirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2b1c0b['prototype'],'z',{'get':function(){return this['_z'];},'set':function(_0x2c8118){this['_z']=_0x2c8118,this['_isDirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2b1c0b['prototype'],'w',{'get':function(){return this['_w'];},'set':function(_0x268c0a){this['_w']=_0x268c0a,this['_isDirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),_0x2b1c0b['prototype']['toString']=function(){return'{X:\x20'+this['_x']+'\x20Y:'+this['_y']+'\x20Z:'+this['_z']+'\x20W:'+this['_w']+'}';},_0x2b1c0b['prototype']['getClassName']=function(){return'Quaternion';},_0x2b1c0b['prototype']['getHashCode']=function(){var _0x4c7249=0x0|this['_x'];return _0x4c7249=0x18d*(_0x4c7249=0x18d*(_0x4c7249=0x18d*_0x4c7249^(0x0|this['_y']))^(0x0|this['_z']))^(0x0|this['_w']);},_0x2b1c0b['prototype']['asArray']=function(){return[this['_x'],this['_y'],this['_z'],this['_w']];},_0x2b1c0b['prototype']['equals']=function(_0x2b20a7){return _0x2b20a7&&this['_x']===_0x2b20a7['_x']&&this['_y']===_0x2b20a7['_y']&&this['_z']===_0x2b20a7['_z']&&this['_w']===_0x2b20a7['_w'];},_0x2b1c0b['prototype']['equalsWithEpsilon']=function(_0x43afc5,_0x16837f){return void 0x0===_0x16837f&&(_0x16837f=_0x9e8480['a']),_0x43afc5&&_0x109042['a']['WithinEpsilon'](this['_x'],_0x43afc5['_x'],_0x16837f)&&_0x109042['a']['WithinEpsilon'](this['_y'],_0x43afc5['_y'],_0x16837f)&&_0x109042['a']['WithinEpsilon'](this['_z'],_0x43afc5['_z'],_0x16837f)&&_0x109042['a']['WithinEpsilon'](this['_w'],_0x43afc5['_w'],_0x16837f);},_0x2b1c0b['prototype']['clone']=function(){return new _0x2b1c0b(this['_x'],this['_y'],this['_z'],this['_w']);},_0x2b1c0b['prototype']['copyFrom']=function(_0x53efe9){return this['x']=_0x53efe9['_x'],this['y']=_0x53efe9['_y'],this['z']=_0x53efe9['_z'],this['w']=_0x53efe9['_w'],this;},_0x2b1c0b['prototype']['copyFromFloats']=function(_0x575f12,_0x5b5bd4,_0x2778ab,_0x1f4fc9){return this['x']=_0x575f12,this['y']=_0x5b5bd4,this['z']=_0x2778ab,this['w']=_0x1f4fc9,this;},_0x2b1c0b['prototype']['set']=function(_0x6f3a62,_0x3586bc,_0x283cd0,_0x311d0e){return this['copyFromFloats'](_0x6f3a62,_0x3586bc,_0x283cd0,_0x311d0e);},_0x2b1c0b['prototype']['add']=function(_0x588ffa){return new _0x2b1c0b(this['_x']+_0x588ffa['_x'],this['_y']+_0x588ffa['_y'],this['_z']+_0x588ffa['_z'],this['_w']+_0x588ffa['_w']);},_0x2b1c0b['prototype']['addInPlace']=function(_0x59e376){return this['_x']+=_0x59e376['_x'],this['_y']+=_0x59e376['_y'],this['_z']+=_0x59e376['_z'],this['_w']+=_0x59e376['_w'],this;},_0x2b1c0b['prototype']['subtract']=function(_0x15eadd){return new _0x2b1c0b(this['_x']-_0x15eadd['_x'],this['_y']-_0x15eadd['_y'],this['_z']-_0x15eadd['_z'],this['_w']-_0x15eadd['_w']);},_0x2b1c0b['prototype']['scale']=function(_0x35e2b4){return new _0x2b1c0b(this['_x']*_0x35e2b4,this['_y']*_0x35e2b4,this['_z']*_0x35e2b4,this['_w']*_0x35e2b4);},_0x2b1c0b['prototype']['scaleToRef']=function(_0x1246fc,_0x3b15a6){return _0x3b15a6['x']=this['_x']*_0x1246fc,_0x3b15a6['y']=this['_y']*_0x1246fc,_0x3b15a6['z']=this['_z']*_0x1246fc,_0x3b15a6['w']=this['_w']*_0x1246fc,this;},_0x2b1c0b['prototype']['scaleInPlace']=function(_0x3c0caa){return this['x']*=_0x3c0caa,this['y']*=_0x3c0caa,this['z']*=_0x3c0caa,this['w']*=_0x3c0caa,this;},_0x2b1c0b['prototype']['scaleAndAddToRef']=function(_0x1e56b6,_0xe909f1){return _0xe909f1['x']+=this['_x']*_0x1e56b6,_0xe909f1['y']+=this['_y']*_0x1e56b6,_0xe909f1['z']+=this['_z']*_0x1e56b6,_0xe909f1['w']+=this['_w']*_0x1e56b6,this;},_0x2b1c0b['prototype']['multiply']=function(_0x7c039e){var _0x53566f=new _0x2b1c0b(0x0,0x0,0x0,0x1);return this['multiplyToRef'](_0x7c039e,_0x53566f),_0x53566f;},_0x2b1c0b['prototype']['multiplyToRef']=function(_0x3cecbb,_0x1c4efb){var _0xbbaa67=this['_x']*_0x3cecbb['_w']+this['_y']*_0x3cecbb['_z']-this['_z']*_0x3cecbb['_y']+this['_w']*_0x3cecbb['_x'],_0x51cb8d=-this['_x']*_0x3cecbb['_z']+this['_y']*_0x3cecbb['_w']+this['_z']*_0x3cecbb['_x']+this['_w']*_0x3cecbb['_y'],_0x1b5be1=this['_x']*_0x3cecbb['_y']-this['_y']*_0x3cecbb['_x']+this['_z']*_0x3cecbb['_w']+this['_w']*_0x3cecbb['_z'],_0x5ed5ec=-this['_x']*_0x3cecbb['_x']-this['_y']*_0x3cecbb['_y']-this['_z']*_0x3cecbb['_z']+this['_w']*_0x3cecbb['_w'];return _0x1c4efb['copyFromFloats'](_0xbbaa67,_0x51cb8d,_0x1b5be1,_0x5ed5ec),this;},_0x2b1c0b['prototype']['multiplyInPlace']=function(_0x53c643){return this['multiplyToRef'](_0x53c643,this),this;},_0x2b1c0b['prototype']['conjugateToRef']=function(_0x42077f){return _0x42077f['copyFromFloats'](-this['_x'],-this['_y'],-this['_z'],this['_w']),this;},_0x2b1c0b['prototype']['conjugateInPlace']=function(){return this['x']*=-0x1,this['y']*=-0x1,this['z']*=-0x1,this;},_0x2b1c0b['prototype']['conjugate']=function(){return new _0x2b1c0b(-this['_x'],-this['_y'],-this['_z'],this['_w']);},_0x2b1c0b['prototype']['length']=function(){return Math['sqrt'](this['_x']*this['_x']+this['_y']*this['_y']+this['_z']*this['_z']+this['_w']*this['_w']);},_0x2b1c0b['prototype']['normalize']=function(){var _0x3449d6=this['length']();if(0x0===_0x3449d6)return this;var _0x298e59=0x1/_0x3449d6;return this['x']*=_0x298e59,this['y']*=_0x298e59,this['z']*=_0x298e59,this['w']*=_0x298e59,this;},_0x2b1c0b['prototype']['toEulerAngles']=function(_0x6b6a3d){void 0x0===_0x6b6a3d&&(_0x6b6a3d='YZX');var _0x1fed55=_0x39af4b['Zero']();return this['toEulerAnglesToRef'](_0x1fed55),_0x1fed55;},_0x2b1c0b['prototype']['toEulerAnglesToRef']=function(_0x4bfd9e){var _0x51dc5a=this['_z'],_0x404a58=this['_x'],_0x567199=this['_y'],_0x550809=this['_w'],_0x242351=_0x550809*_0x550809,_0x33bff6=_0x51dc5a*_0x51dc5a,_0x36bb36=_0x404a58*_0x404a58,_0x2b1a12=_0x567199*_0x567199,_0x42dd10=_0x567199*_0x51dc5a-_0x404a58*_0x550809;return _0x42dd10<-0.4999999?(_0x4bfd9e['y']=0x2*Math['atan2'](_0x567199,_0x550809),_0x4bfd9e['x']=Math['PI']/0x2,_0x4bfd9e['z']=0x0):_0x42dd10>0.4999999?(_0x4bfd9e['y']=0x2*Math['atan2'](_0x567199,_0x550809),_0x4bfd9e['x']=-Math['PI']/0x2,_0x4bfd9e['z']=0x0):(_0x4bfd9e['z']=Math['atan2'](0x2*(_0x404a58*_0x567199+_0x51dc5a*_0x550809),-_0x33bff6-_0x36bb36+_0x2b1a12+_0x242351),_0x4bfd9e['x']=Math['asin'](-0x2*(_0x51dc5a*_0x567199-_0x404a58*_0x550809)),_0x4bfd9e['y']=Math['atan2'](0x2*(_0x51dc5a*_0x404a58+_0x567199*_0x550809),_0x33bff6-_0x36bb36-_0x2b1a12+_0x242351)),this;},_0x2b1c0b['prototype']['toRotationMatrix']=function(_0x2e8b8a){return _0x54ba40['FromQuaternionToRef'](this,_0x2e8b8a),this;},_0x2b1c0b['prototype']['fromRotationMatrix']=function(_0x35f63){return _0x2b1c0b['FromRotationMatrixToRef'](_0x35f63,this),this;},_0x2b1c0b['FromRotationMatrix']=function(_0x243803){var _0x2e33a6=new _0x2b1c0b();return _0x2b1c0b['FromRotationMatrixToRef'](_0x243803,_0x2e33a6),_0x2e33a6;},_0x2b1c0b['FromRotationMatrixToRef']=function(_0x32858f,_0x212711){var _0x5937f2,_0x188cde=_0x32858f['m'],_0x347887=_0x188cde[0x0],_0x5697aa=_0x188cde[0x4],_0x5d74e4=_0x188cde[0x8],_0x58f050=_0x188cde[0x1],_0x440a57=_0x188cde[0x5],_0x2f0c07=_0x188cde[0x9],_0x3826eb=_0x188cde[0x2],_0x4fafdf=_0x188cde[0x6],_0x384ff4=_0x188cde[0xa],_0x22da54=_0x347887+_0x440a57+_0x384ff4;_0x22da54>0x0?(_0x5937f2=0.5/Math['sqrt'](_0x22da54+0x1),_0x212711['w']=0.25/_0x5937f2,_0x212711['x']=(_0x4fafdf-_0x2f0c07)*_0x5937f2,_0x212711['y']=(_0x5d74e4-_0x3826eb)*_0x5937f2,_0x212711['z']=(_0x58f050-_0x5697aa)*_0x5937f2):_0x347887>_0x440a57&&_0x347887>_0x384ff4?(_0x5937f2=0x2*Math['sqrt'](0x1+_0x347887-_0x440a57-_0x384ff4),_0x212711['w']=(_0x4fafdf-_0x2f0c07)/_0x5937f2,_0x212711['x']=0.25*_0x5937f2,_0x212711['y']=(_0x5697aa+_0x58f050)/_0x5937f2,_0x212711['z']=(_0x5d74e4+_0x3826eb)/_0x5937f2):_0x440a57>_0x384ff4?(_0x5937f2=0x2*Math['sqrt'](0x1+_0x440a57-_0x347887-_0x384ff4),_0x212711['w']=(_0x5d74e4-_0x3826eb)/_0x5937f2,_0x212711['x']=(_0x5697aa+_0x58f050)/_0x5937f2,_0x212711['y']=0.25*_0x5937f2,_0x212711['z']=(_0x2f0c07+_0x4fafdf)/_0x5937f2):(_0x5937f2=0x2*Math['sqrt'](0x1+_0x384ff4-_0x347887-_0x440a57),_0x212711['w']=(_0x58f050-_0x5697aa)/_0x5937f2,_0x212711['x']=(_0x5d74e4+_0x3826eb)/_0x5937f2,_0x212711['y']=(_0x2f0c07+_0x4fafdf)/_0x5937f2,_0x212711['z']=0.25*_0x5937f2);},_0x2b1c0b['Dot']=function(_0x587d23,_0x163ecd){return _0x587d23['_x']*_0x163ecd['_x']+_0x587d23['_y']*_0x163ecd['_y']+_0x587d23['_z']*_0x163ecd['_z']+_0x587d23['_w']*_0x163ecd['_w'];},_0x2b1c0b['AreClose']=function(_0x5d4f8c,_0x22373c){return _0x2b1c0b['Dot'](_0x5d4f8c,_0x22373c)>=0x0;},_0x2b1c0b['Zero']=function(){return new _0x2b1c0b(0x0,0x0,0x0,0x0);},_0x2b1c0b['Inverse']=function(_0x23949a){return new _0x2b1c0b(-_0x23949a['_x'],-_0x23949a['_y'],-_0x23949a['_z'],_0x23949a['_w']);},_0x2b1c0b['InverseToRef']=function(_0x41da21,_0x18994a){return _0x18994a['set'](-_0x41da21['_x'],-_0x41da21['_y'],-_0x41da21['_z'],_0x41da21['_w']),_0x18994a;},_0x2b1c0b['Identity']=function(){return new _0x2b1c0b(0x0,0x0,0x0,0x1);},_0x2b1c0b['IsIdentity']=function(_0x3b21df){return _0x3b21df&&0x0===_0x3b21df['_x']&&0x0===_0x3b21df['_y']&&0x0===_0x3b21df['_z']&&0x1===_0x3b21df['_w'];},_0x2b1c0b['RotationAxis']=function(_0x1babec,_0x4c7684){return _0x2b1c0b['RotationAxisToRef'](_0x1babec,_0x4c7684,new _0x2b1c0b());},_0x2b1c0b['RotationAxisToRef']=function(_0x37082c,_0x10c37f,_0x5e4e0f){var _0x596ef0=Math['sin'](_0x10c37f/0x2);return _0x37082c['normalize'](),_0x5e4e0f['w']=Math['cos'](_0x10c37f/0x2),_0x5e4e0f['x']=_0x37082c['_x']*_0x596ef0,_0x5e4e0f['y']=_0x37082c['_y']*_0x596ef0,_0x5e4e0f['z']=_0x37082c['_z']*_0x596ef0,_0x5e4e0f;},_0x2b1c0b['FromArray']=function(_0x3ca3af,_0x5e1238){return _0x5e1238||(_0x5e1238=0x0),new _0x2b1c0b(_0x3ca3af[_0x5e1238],_0x3ca3af[_0x5e1238+0x1],_0x3ca3af[_0x5e1238+0x2],_0x3ca3af[_0x5e1238+0x3]);},_0x2b1c0b['FromArrayToRef']=function(_0x44c17f,_0x33a077,_0x1953ad){_0x1953ad['x']=_0x44c17f[_0x33a077],_0x1953ad['y']=_0x44c17f[_0x33a077+0x1],_0x1953ad['z']=_0x44c17f[_0x33a077+0x2],_0x1953ad['w']=_0x44c17f[_0x33a077+0x3];},_0x2b1c0b['FromEulerAngles']=function(_0x23e51e,_0x4d558c,_0x53e444){var _0x2a7116=new _0x2b1c0b();return _0x2b1c0b['RotationYawPitchRollToRef'](_0x4d558c,_0x23e51e,_0x53e444,_0x2a7116),_0x2a7116;},_0x2b1c0b['FromEulerAnglesToRef']=function(_0x266cfb,_0x3590ab,_0x283336,_0x380cbc){return _0x2b1c0b['RotationYawPitchRollToRef'](_0x3590ab,_0x266cfb,_0x283336,_0x380cbc),_0x380cbc;},_0x2b1c0b['FromEulerVector']=function(_0x319d85){var _0x5196d7=new _0x2b1c0b();return _0x2b1c0b['RotationYawPitchRollToRef'](_0x319d85['_y'],_0x319d85['_x'],_0x319d85['_z'],_0x5196d7),_0x5196d7;},_0x2b1c0b['FromEulerVectorToRef']=function(_0x44b40f,_0x1441a9){return _0x2b1c0b['RotationYawPitchRollToRef'](_0x44b40f['_y'],_0x44b40f['_x'],_0x44b40f['_z'],_0x1441a9),_0x1441a9;},_0x2b1c0b['RotationYawPitchRoll']=function(_0x21b6f2,_0x3c87f6,_0x29e340){var _0x5ba684=new _0x2b1c0b();return _0x2b1c0b['RotationYawPitchRollToRef'](_0x21b6f2,_0x3c87f6,_0x29e340,_0x5ba684),_0x5ba684;},_0x2b1c0b['RotationYawPitchRollToRef']=function(_0x2c74f1,_0x367d9e,_0x57011c,_0x145041){var _0x1d2b2d=0.5*_0x57011c,_0x5dceeb=0.5*_0x367d9e,_0x54dbc6=0.5*_0x2c74f1,_0x4467ff=Math['sin'](_0x1d2b2d),_0x2e1141=Math['cos'](_0x1d2b2d),_0x1a2260=Math['sin'](_0x5dceeb),_0x5b10a5=Math['cos'](_0x5dceeb),_0x432f9b=Math['sin'](_0x54dbc6),_0x26647d=Math['cos'](_0x54dbc6);_0x145041['x']=_0x26647d*_0x1a2260*_0x2e1141+_0x432f9b*_0x5b10a5*_0x4467ff,_0x145041['y']=_0x432f9b*_0x5b10a5*_0x2e1141-_0x26647d*_0x1a2260*_0x4467ff,_0x145041['z']=_0x26647d*_0x5b10a5*_0x4467ff-_0x432f9b*_0x1a2260*_0x2e1141,_0x145041['w']=_0x26647d*_0x5b10a5*_0x2e1141+_0x432f9b*_0x1a2260*_0x4467ff;},_0x2b1c0b['RotationAlphaBetaGamma']=function(_0x408640,_0x12fbae,_0x2406e5){var _0x971fd7=new _0x2b1c0b();return _0x2b1c0b['RotationAlphaBetaGammaToRef'](_0x408640,_0x12fbae,_0x2406e5,_0x971fd7),_0x971fd7;},_0x2b1c0b['RotationAlphaBetaGammaToRef']=function(_0x5aa7c8,_0x855699,_0x152922,_0x30bc1c){var _0x129a58=0.5*(_0x152922+_0x5aa7c8),_0x1c817a=0.5*(_0x152922-_0x5aa7c8),_0xa91d89=0.5*_0x855699;_0x30bc1c['x']=Math['cos'](_0x1c817a)*Math['sin'](_0xa91d89),_0x30bc1c['y']=Math['sin'](_0x1c817a)*Math['sin'](_0xa91d89),_0x30bc1c['z']=Math['sin'](_0x129a58)*Math['cos'](_0xa91d89),_0x30bc1c['w']=Math['cos'](_0x129a58)*Math['cos'](_0xa91d89);},_0x2b1c0b['RotationQuaternionFromAxis']=function(_0xb2b299,_0x3a4cb4,_0x234aa0){var _0x48bc54=new _0x2b1c0b(0x0,0x0,0x0,0x0);return _0x2b1c0b['RotationQuaternionFromAxisToRef'](_0xb2b299,_0x3a4cb4,_0x234aa0,_0x48bc54),_0x48bc54;},_0x2b1c0b['RotationQuaternionFromAxisToRef']=function(_0x576986,_0x126a05,_0x47fea7,_0x46ed4a){var _0x571c1b=_0x4e1745['Matrix'][0x0];_0x54ba40['FromXYZAxesToRef'](_0x576986['normalize'](),_0x126a05['normalize'](),_0x47fea7['normalize'](),_0x571c1b),_0x2b1c0b['FromRotationMatrixToRef'](_0x571c1b,_0x46ed4a);},_0x2b1c0b['Slerp']=function(_0x572be7,_0x33757e,_0x4222cf){var _0x2c3b33=_0x2b1c0b['Identity']();return _0x2b1c0b['SlerpToRef'](_0x572be7,_0x33757e,_0x4222cf,_0x2c3b33),_0x2c3b33;},_0x2b1c0b['SlerpToRef']=function(_0x1dc4e8,_0x44e524,_0x1a98b4,_0x2e2393){var _0x26385a,_0x53fec5,_0x38b99e=_0x1dc4e8['_x']*_0x44e524['_x']+_0x1dc4e8['_y']*_0x44e524['_y']+_0x1dc4e8['_z']*_0x44e524['_z']+_0x1dc4e8['_w']*_0x44e524['_w'],_0x99f778=!0x1;if(_0x38b99e<0x0&&(_0x99f778=!0x0,_0x38b99e=-_0x38b99e),_0x38b99e>0.999999)_0x53fec5=0x1-_0x1a98b4,_0x26385a=_0x99f778?-_0x1a98b4:_0x1a98b4;else{var _0x38e683=Math['acos'](_0x38b99e),_0x560e45=0x1/Math['sin'](_0x38e683);_0x53fec5=Math['sin']((0x1-_0x1a98b4)*_0x38e683)*_0x560e45,_0x26385a=_0x99f778?-Math['sin'](_0x1a98b4*_0x38e683)*_0x560e45:Math['sin'](_0x1a98b4*_0x38e683)*_0x560e45;}_0x2e2393['x']=_0x53fec5*_0x1dc4e8['_x']+_0x26385a*_0x44e524['_x'],_0x2e2393['y']=_0x53fec5*_0x1dc4e8['_y']+_0x26385a*_0x44e524['_y'],_0x2e2393['z']=_0x53fec5*_0x1dc4e8['_z']+_0x26385a*_0x44e524['_z'],_0x2e2393['w']=_0x53fec5*_0x1dc4e8['_w']+_0x26385a*_0x44e524['_w'];},_0x2b1c0b['Hermite']=function(_0x2256ea,_0x2810ff,_0x39e88b,_0x4f627b,_0x4be2a7){var _0x240825=_0x4be2a7*_0x4be2a7,_0x5060d3=_0x4be2a7*_0x240825,_0x4648fd=0x2*_0x5060d3-0x3*_0x240825+0x1,_0x57436a=-0x2*_0x5060d3+0x3*_0x240825,_0x3b5a1c=_0x5060d3-0x2*_0x240825+_0x4be2a7,_0x2a60a6=_0x5060d3-_0x240825;return new _0x2b1c0b(_0x2256ea['_x']*_0x4648fd+_0x39e88b['_x']*_0x57436a+_0x2810ff['_x']*_0x3b5a1c+_0x4f627b['_x']*_0x2a60a6,_0x2256ea['_y']*_0x4648fd+_0x39e88b['_y']*_0x57436a+_0x2810ff['_y']*_0x3b5a1c+_0x4f627b['_y']*_0x2a60a6,_0x2256ea['_z']*_0x4648fd+_0x39e88b['_z']*_0x57436a+_0x2810ff['_z']*_0x3b5a1c+_0x4f627b['_z']*_0x2a60a6,_0x2256ea['_w']*_0x4648fd+_0x39e88b['_w']*_0x57436a+_0x2810ff['_w']*_0x3b5a1c+_0x4f627b['_w']*_0x2a60a6);},_0x2b1c0b;}()),_0x54ba40=(function(){function _0x1eb00c(){this['_isIdentity']=!0x1,this['_isIdentityDirty']=!0x0,this['_isIdentity3x2']=!0x0,this['_isIdentity3x2Dirty']=!0x0,this['updateFlag']=-0x1,_0x5e0c90['a']['MatrixTrackPrecisionChange']&&_0x5e0c90['a']['MatrixTrackedMatrices']['push'](this),this['_m']=new _0x5e0c90['a']['MatrixCurrentType'](0x10),this['_updateIdentityStatus'](!0x1);}return Object['defineProperty'](_0x1eb00c,'Use64Bits',{'get':function(){return _0x5e0c90['a']['MatrixUse64Bits'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1eb00c['prototype'],'m',{'get':function(){return this['_m'];},'enumerable':!0x1,'configurable':!0x0}),_0x1eb00c['prototype']['_markAsUpdated']=function(){this['updateFlag']=_0x1eb00c['_updateFlagSeed']++,this['_isIdentity']=!0x1,this['_isIdentity3x2']=!0x1,this['_isIdentityDirty']=!0x0,this['_isIdentity3x2Dirty']=!0x0;},_0x1eb00c['prototype']['_updateIdentityStatus']=function(_0x309e7c,_0x3dd2ea,_0x13f9d5,_0x36bbf2){void 0x0===_0x3dd2ea&&(_0x3dd2ea=!0x1),void 0x0===_0x13f9d5&&(_0x13f9d5=!0x1),void 0x0===_0x36bbf2&&(_0x36bbf2=!0x0),this['updateFlag']=_0x1eb00c['_updateFlagSeed']++,this['_isIdentity']=_0x309e7c,this['_isIdentity3x2']=_0x309e7c||_0x13f9d5,this['_isIdentityDirty']=!this['_isIdentity']&&_0x3dd2ea,this['_isIdentity3x2Dirty']=!this['_isIdentity3x2']&&_0x36bbf2;},_0x1eb00c['prototype']['isIdentity']=function(){if(this['_isIdentityDirty']){this['_isIdentityDirty']=!0x1;var _0x14fb63=this['_m'];this['_isIdentity']=0x1===_0x14fb63[0x0]&&0x0===_0x14fb63[0x1]&&0x0===_0x14fb63[0x2]&&0x0===_0x14fb63[0x3]&&0x0===_0x14fb63[0x4]&&0x1===_0x14fb63[0x5]&&0x0===_0x14fb63[0x6]&&0x0===_0x14fb63[0x7]&&0x0===_0x14fb63[0x8]&&0x0===_0x14fb63[0x9]&&0x1===_0x14fb63[0xa]&&0x0===_0x14fb63[0xb]&&0x0===_0x14fb63[0xc]&&0x0===_0x14fb63[0xd]&&0x0===_0x14fb63[0xe]&&0x1===_0x14fb63[0xf];}return this['_isIdentity'];},_0x1eb00c['prototype']['isIdentityAs3x2']=function(){return this['_isIdentity3x2Dirty']&&(this['_isIdentity3x2Dirty']=!0x1,0x1!==this['_m'][0x0]||0x1!==this['_m'][0x5]||0x1!==this['_m'][0xf]||0x0!==this['_m'][0x1]||0x0!==this['_m'][0x2]||0x0!==this['_m'][0x3]||0x0!==this['_m'][0x4]||0x0!==this['_m'][0x6]||0x0!==this['_m'][0x7]||0x0!==this['_m'][0x8]||0x0!==this['_m'][0x9]||0x0!==this['_m'][0xa]||0x0!==this['_m'][0xb]||0x0!==this['_m'][0xc]||0x0!==this['_m'][0xd]||0x0!==this['_m'][0xe]?this['_isIdentity3x2']=!0x1:this['_isIdentity3x2']=!0x0),this['_isIdentity3x2'];},_0x1eb00c['prototype']['determinant']=function(){if(!0x0===this['_isIdentity'])return 0x1;var _0x3893f9=this['_m'],_0x3afa2a=_0x3893f9[0x0],_0x57d906=_0x3893f9[0x1],_0x2b5eb6=_0x3893f9[0x2],_0x4bd3bd=_0x3893f9[0x3],_0x16e66d=_0x3893f9[0x4],_0x3086a6=_0x3893f9[0x5],_0x10861e=_0x3893f9[0x6],_0x5c3fe2=_0x3893f9[0x7],_0x209ea4=_0x3893f9[0x8],_0x24dcf9=_0x3893f9[0x9],_0x2ae8d9=_0x3893f9[0xa],_0x398385=_0x3893f9[0xb],_0x3e36ce=_0x3893f9[0xc],_0x430615=_0x3893f9[0xd],_0x1c6e4a=_0x3893f9[0xe],_0x9d0589=_0x3893f9[0xf],_0x1a001a=_0x2ae8d9*_0x9d0589-_0x1c6e4a*_0x398385,_0x4f9e34=_0x24dcf9*_0x9d0589-_0x430615*_0x398385,_0x2451ce=_0x24dcf9*_0x1c6e4a-_0x430615*_0x2ae8d9,_0x3d724c=_0x209ea4*_0x9d0589-_0x3e36ce*_0x398385,_0x5ea919=_0x209ea4*_0x1c6e4a-_0x2ae8d9*_0x3e36ce,_0x1204ed=_0x209ea4*_0x430615-_0x3e36ce*_0x24dcf9;return _0x3afa2a*+(_0x3086a6*_0x1a001a-_0x10861e*_0x4f9e34+_0x5c3fe2*_0x2451ce)+_0x57d906*-(_0x16e66d*_0x1a001a-_0x10861e*_0x3d724c+_0x5c3fe2*_0x5ea919)+_0x2b5eb6*+(_0x16e66d*_0x4f9e34-_0x3086a6*_0x3d724c+_0x5c3fe2*_0x1204ed)+_0x4bd3bd*-(_0x16e66d*_0x2451ce-_0x3086a6*_0x5ea919+_0x10861e*_0x1204ed);},_0x1eb00c['prototype']['toArray']=function(){return this['_m'];},_0x1eb00c['prototype']['asArray']=function(){return this['_m'];},_0x1eb00c['prototype']['invert']=function(){return this['invertToRef'](this),this;},_0x1eb00c['prototype']['reset']=function(){return _0x1eb00c['FromValuesToRef'](0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,this),this['_updateIdentityStatus'](!0x1),this;},_0x1eb00c['prototype']['add']=function(_0x1ddbd1){var _0x2948ba=new _0x1eb00c();return this['addToRef'](_0x1ddbd1,_0x2948ba),_0x2948ba;},_0x1eb00c['prototype']['addToRef']=function(_0x5100c8,_0x5543bf){for(var _0x551907=this['_m'],_0x216382=_0x5543bf['_m'],_0x1a8474=_0x5100c8['m'],_0x570600=0x0;_0x570600<0x10;_0x570600++)_0x216382[_0x570600]=_0x551907[_0x570600]+_0x1a8474[_0x570600];return _0x5543bf['_markAsUpdated'](),this;},_0x1eb00c['prototype']['addToSelf']=function(_0xe23cd){for(var _0x5bb825=this['_m'],_0x5da107=_0xe23cd['m'],_0x24f66d=0x0;_0x24f66d<0x10;_0x24f66d++)_0x5bb825[_0x24f66d]+=_0x5da107[_0x24f66d];return this['_markAsUpdated'](),this;},_0x1eb00c['prototype']['invertToRef']=function(_0x48c9dc){if(!0x0===this['_isIdentity'])return _0x1eb00c['IdentityToRef'](_0x48c9dc),this;var _0x31d0fe=this['_m'],_0xaa178f=_0x31d0fe[0x0],_0x28abf2=_0x31d0fe[0x1],_0x2b68fc=_0x31d0fe[0x2],_0x59dbde=_0x31d0fe[0x3],_0x1fe922=_0x31d0fe[0x4],_0xb078e8=_0x31d0fe[0x5],_0x2f5b69=_0x31d0fe[0x6],_0x5bc164=_0x31d0fe[0x7],_0x14d14d=_0x31d0fe[0x8],_0x54187a=_0x31d0fe[0x9],_0x4e3404=_0x31d0fe[0xa],_0x5909a1=_0x31d0fe[0xb],_0x54d320=_0x31d0fe[0xc],_0x32b695=_0x31d0fe[0xd],_0x17c4e5=_0x31d0fe[0xe],_0x23f911=_0x31d0fe[0xf],_0x511348=_0x4e3404*_0x23f911-_0x17c4e5*_0x5909a1,_0x5a7ad6=_0x54187a*_0x23f911-_0x32b695*_0x5909a1,_0x22a94f=_0x54187a*_0x17c4e5-_0x32b695*_0x4e3404,_0x3b5eb3=_0x14d14d*_0x23f911-_0x54d320*_0x5909a1,_0x2b9180=_0x14d14d*_0x17c4e5-_0x4e3404*_0x54d320,_0x31e99e=_0x14d14d*_0x32b695-_0x54d320*_0x54187a,_0x1d050c=+(_0xb078e8*_0x511348-_0x2f5b69*_0x5a7ad6+_0x5bc164*_0x22a94f),_0x1d6a71=-(_0x1fe922*_0x511348-_0x2f5b69*_0x3b5eb3+_0x5bc164*_0x2b9180),_0x1e402d=+(_0x1fe922*_0x5a7ad6-_0xb078e8*_0x3b5eb3+_0x5bc164*_0x31e99e),_0x4fe504=-(_0x1fe922*_0x22a94f-_0xb078e8*_0x2b9180+_0x2f5b69*_0x31e99e),_0x44d864=_0xaa178f*_0x1d050c+_0x28abf2*_0x1d6a71+_0x2b68fc*_0x1e402d+_0x59dbde*_0x4fe504;if(0x0===_0x44d864)return _0x48c9dc['copyFrom'](this),this;var _0x1ce0f1=0x1/_0x44d864,_0x4cb40d=_0x2f5b69*_0x23f911-_0x17c4e5*_0x5bc164,_0x1d542b=_0xb078e8*_0x23f911-_0x32b695*_0x5bc164,_0xbb602e=_0xb078e8*_0x17c4e5-_0x32b695*_0x2f5b69,_0x32ecf7=_0x1fe922*_0x23f911-_0x54d320*_0x5bc164,_0x31b81a=_0x1fe922*_0x17c4e5-_0x54d320*_0x2f5b69,_0x1d31d9=_0x1fe922*_0x32b695-_0x54d320*_0xb078e8,_0x988406=_0x2f5b69*_0x5909a1-_0x4e3404*_0x5bc164,_0x1df422=_0xb078e8*_0x5909a1-_0x54187a*_0x5bc164,_0x5b383d=_0xb078e8*_0x4e3404-_0x54187a*_0x2f5b69,_0x467f8f=_0x1fe922*_0x5909a1-_0x14d14d*_0x5bc164,_0x5e55c4=_0x1fe922*_0x4e3404-_0x14d14d*_0x2f5b69,_0x111785=_0x1fe922*_0x54187a-_0x14d14d*_0xb078e8,_0x1638ae=-(_0x28abf2*_0x511348-_0x2b68fc*_0x5a7ad6+_0x59dbde*_0x22a94f),_0xc2969b=+(_0xaa178f*_0x511348-_0x2b68fc*_0x3b5eb3+_0x59dbde*_0x2b9180),_0x2a9c08=-(_0xaa178f*_0x5a7ad6-_0x28abf2*_0x3b5eb3+_0x59dbde*_0x31e99e),_0x706707=+(_0xaa178f*_0x22a94f-_0x28abf2*_0x2b9180+_0x2b68fc*_0x31e99e),_0x3b95fe=+(_0x28abf2*_0x4cb40d-_0x2b68fc*_0x1d542b+_0x59dbde*_0xbb602e),_0x4df9a7=-(_0xaa178f*_0x4cb40d-_0x2b68fc*_0x32ecf7+_0x59dbde*_0x31b81a),_0x29c7dd=+(_0xaa178f*_0x1d542b-_0x28abf2*_0x32ecf7+_0x59dbde*_0x1d31d9),_0x4fcd0c=-(_0xaa178f*_0xbb602e-_0x28abf2*_0x31b81a+_0x2b68fc*_0x1d31d9),_0x15bc40=-(_0x28abf2*_0x988406-_0x2b68fc*_0x1df422+_0x59dbde*_0x5b383d),_0x48569e=+(_0xaa178f*_0x988406-_0x2b68fc*_0x467f8f+_0x59dbde*_0x5e55c4),_0x598b3c=-(_0xaa178f*_0x1df422-_0x28abf2*_0x467f8f+_0x59dbde*_0x111785),_0x2557b9=+(_0xaa178f*_0x5b383d-_0x28abf2*_0x5e55c4+_0x2b68fc*_0x111785);return _0x1eb00c['FromValuesToRef'](_0x1d050c*_0x1ce0f1,_0x1638ae*_0x1ce0f1,_0x3b95fe*_0x1ce0f1,_0x15bc40*_0x1ce0f1,_0x1d6a71*_0x1ce0f1,_0xc2969b*_0x1ce0f1,_0x4df9a7*_0x1ce0f1,_0x48569e*_0x1ce0f1,_0x1e402d*_0x1ce0f1,_0x2a9c08*_0x1ce0f1,_0x29c7dd*_0x1ce0f1,_0x598b3c*_0x1ce0f1,_0x4fe504*_0x1ce0f1,_0x706707*_0x1ce0f1,_0x4fcd0c*_0x1ce0f1,_0x2557b9*_0x1ce0f1,_0x48c9dc),this;},_0x1eb00c['prototype']['addAtIndex']=function(_0x2682df,_0x597e9e){return this['_m'][_0x2682df]+=_0x597e9e,this['_markAsUpdated'](),this;},_0x1eb00c['prototype']['multiplyAtIndex']=function(_0x4d47e1,_0x480b92){return this['_m'][_0x4d47e1]*=_0x480b92,this['_markAsUpdated'](),this;},_0x1eb00c['prototype']['setTranslationFromFloats']=function(_0x4b99fc,_0x22fd19,_0x3c107d){return this['_m'][0xc]=_0x4b99fc,this['_m'][0xd]=_0x22fd19,this['_m'][0xe]=_0x3c107d,this['_markAsUpdated'](),this;},_0x1eb00c['prototype']['addTranslationFromFloats']=function(_0x6994c8,_0x2c2bff,_0x17bec3){return this['_m'][0xc]+=_0x6994c8,this['_m'][0xd]+=_0x2c2bff,this['_m'][0xe]+=_0x17bec3,this['_markAsUpdated'](),this;},_0x1eb00c['prototype']['setTranslation']=function(_0x3ee9c6){return this['setTranslationFromFloats'](_0x3ee9c6['_x'],_0x3ee9c6['_y'],_0x3ee9c6['_z']);},_0x1eb00c['prototype']['getTranslation']=function(){return new _0x39af4b(this['_m'][0xc],this['_m'][0xd],this['_m'][0xe]);},_0x1eb00c['prototype']['getTranslationToRef']=function(_0x594ded){return _0x594ded['x']=this['_m'][0xc],_0x594ded['y']=this['_m'][0xd],_0x594ded['z']=this['_m'][0xe],this;},_0x1eb00c['prototype']['removeRotationAndScaling']=function(){var _0x19651f=this['m'];return _0x1eb00c['FromValuesToRef'](0x1,0x0,0x0,0x0,0x0,0x1,0x0,0x0,0x0,0x0,0x1,0x0,_0x19651f[0xc],_0x19651f[0xd],_0x19651f[0xe],_0x19651f[0xf],this),this['_updateIdentityStatus'](0x0===_0x19651f[0xc]&&0x0===_0x19651f[0xd]&&0x0===_0x19651f[0xe]&&0x1===_0x19651f[0xf]),this;},_0x1eb00c['prototype']['multiply']=function(_0x505776){var _0x56b5b2=new _0x1eb00c();return this['multiplyToRef'](_0x505776,_0x56b5b2),_0x56b5b2;},_0x1eb00c['prototype']['copyFrom']=function(_0x28c255){_0x28c255['copyToArray'](this['_m']);var _0x9ed4a9=_0x28c255;return this['_updateIdentityStatus'](_0x9ed4a9['_isIdentity'],_0x9ed4a9['_isIdentityDirty'],_0x9ed4a9['_isIdentity3x2'],_0x9ed4a9['_isIdentity3x2Dirty']),this;},_0x1eb00c['prototype']['copyToArray']=function(_0x334ca0,_0x3a8469){void 0x0===_0x3a8469&&(_0x3a8469=0x0);var _0x55b276=this['_m'];return _0x334ca0[_0x3a8469]=_0x55b276[0x0],_0x334ca0[_0x3a8469+0x1]=_0x55b276[0x1],_0x334ca0[_0x3a8469+0x2]=_0x55b276[0x2],_0x334ca0[_0x3a8469+0x3]=_0x55b276[0x3],_0x334ca0[_0x3a8469+0x4]=_0x55b276[0x4],_0x334ca0[_0x3a8469+0x5]=_0x55b276[0x5],_0x334ca0[_0x3a8469+0x6]=_0x55b276[0x6],_0x334ca0[_0x3a8469+0x7]=_0x55b276[0x7],_0x334ca0[_0x3a8469+0x8]=_0x55b276[0x8],_0x334ca0[_0x3a8469+0x9]=_0x55b276[0x9],_0x334ca0[_0x3a8469+0xa]=_0x55b276[0xa],_0x334ca0[_0x3a8469+0xb]=_0x55b276[0xb],_0x334ca0[_0x3a8469+0xc]=_0x55b276[0xc],_0x334ca0[_0x3a8469+0xd]=_0x55b276[0xd],_0x334ca0[_0x3a8469+0xe]=_0x55b276[0xe],_0x334ca0[_0x3a8469+0xf]=_0x55b276[0xf],this;},_0x1eb00c['prototype']['multiplyToRef']=function(_0x1ce4af,_0x3371de){return this['_isIdentity']?(_0x3371de['copyFrom'](_0x1ce4af),this):_0x1ce4af['_isIdentity']?(_0x3371de['copyFrom'](this),this):(this['multiplyToArray'](_0x1ce4af,_0x3371de['_m'],0x0),_0x3371de['_markAsUpdated'](),this);},_0x1eb00c['prototype']['multiplyToArray']=function(_0x127d63,_0x9e0cb2,_0x203ccc){var _0x4c5c1c=this['_m'],_0x3bbdf2=_0x127d63['m'],_0x2d077a=_0x4c5c1c[0x0],_0xaa3e22=_0x4c5c1c[0x1],_0x154fdd=_0x4c5c1c[0x2],_0x5db896=_0x4c5c1c[0x3],_0x501aa3=_0x4c5c1c[0x4],_0x5c95ce=_0x4c5c1c[0x5],_0xfa4208=_0x4c5c1c[0x6],_0x5f4186=_0x4c5c1c[0x7],_0x210451=_0x4c5c1c[0x8],_0x2b7c6=_0x4c5c1c[0x9],_0x1c040b=_0x4c5c1c[0xa],_0xa9eaf8=_0x4c5c1c[0xb],_0x55574d=_0x4c5c1c[0xc],_0x3ca020=_0x4c5c1c[0xd],_0x26f4a8=_0x4c5c1c[0xe],_0x5bdfe8=_0x4c5c1c[0xf],_0x455021=_0x3bbdf2[0x0],_0x25a13f=_0x3bbdf2[0x1],_0x4e71c1=_0x3bbdf2[0x2],_0x4bdb1b=_0x3bbdf2[0x3],_0x2fe133=_0x3bbdf2[0x4],_0x382216=_0x3bbdf2[0x5],_0x3ef656=_0x3bbdf2[0x6],_0x294d25=_0x3bbdf2[0x7],_0x5ed75f=_0x3bbdf2[0x8],_0x17584f=_0x3bbdf2[0x9],_0x3c92b9=_0x3bbdf2[0xa],_0x56e315=_0x3bbdf2[0xb],_0x4e0957=_0x3bbdf2[0xc],_0x4a8757=_0x3bbdf2[0xd],_0x46f90e=_0x3bbdf2[0xe],_0x384b10=_0x3bbdf2[0xf];return _0x9e0cb2[_0x203ccc]=_0x2d077a*_0x455021+_0xaa3e22*_0x2fe133+_0x154fdd*_0x5ed75f+_0x5db896*_0x4e0957,_0x9e0cb2[_0x203ccc+0x1]=_0x2d077a*_0x25a13f+_0xaa3e22*_0x382216+_0x154fdd*_0x17584f+_0x5db896*_0x4a8757,_0x9e0cb2[_0x203ccc+0x2]=_0x2d077a*_0x4e71c1+_0xaa3e22*_0x3ef656+_0x154fdd*_0x3c92b9+_0x5db896*_0x46f90e,_0x9e0cb2[_0x203ccc+0x3]=_0x2d077a*_0x4bdb1b+_0xaa3e22*_0x294d25+_0x154fdd*_0x56e315+_0x5db896*_0x384b10,_0x9e0cb2[_0x203ccc+0x4]=_0x501aa3*_0x455021+_0x5c95ce*_0x2fe133+_0xfa4208*_0x5ed75f+_0x5f4186*_0x4e0957,_0x9e0cb2[_0x203ccc+0x5]=_0x501aa3*_0x25a13f+_0x5c95ce*_0x382216+_0xfa4208*_0x17584f+_0x5f4186*_0x4a8757,_0x9e0cb2[_0x203ccc+0x6]=_0x501aa3*_0x4e71c1+_0x5c95ce*_0x3ef656+_0xfa4208*_0x3c92b9+_0x5f4186*_0x46f90e,_0x9e0cb2[_0x203ccc+0x7]=_0x501aa3*_0x4bdb1b+_0x5c95ce*_0x294d25+_0xfa4208*_0x56e315+_0x5f4186*_0x384b10,_0x9e0cb2[_0x203ccc+0x8]=_0x210451*_0x455021+_0x2b7c6*_0x2fe133+_0x1c040b*_0x5ed75f+_0xa9eaf8*_0x4e0957,_0x9e0cb2[_0x203ccc+0x9]=_0x210451*_0x25a13f+_0x2b7c6*_0x382216+_0x1c040b*_0x17584f+_0xa9eaf8*_0x4a8757,_0x9e0cb2[_0x203ccc+0xa]=_0x210451*_0x4e71c1+_0x2b7c6*_0x3ef656+_0x1c040b*_0x3c92b9+_0xa9eaf8*_0x46f90e,_0x9e0cb2[_0x203ccc+0xb]=_0x210451*_0x4bdb1b+_0x2b7c6*_0x294d25+_0x1c040b*_0x56e315+_0xa9eaf8*_0x384b10,_0x9e0cb2[_0x203ccc+0xc]=_0x55574d*_0x455021+_0x3ca020*_0x2fe133+_0x26f4a8*_0x5ed75f+_0x5bdfe8*_0x4e0957,_0x9e0cb2[_0x203ccc+0xd]=_0x55574d*_0x25a13f+_0x3ca020*_0x382216+_0x26f4a8*_0x17584f+_0x5bdfe8*_0x4a8757,_0x9e0cb2[_0x203ccc+0xe]=_0x55574d*_0x4e71c1+_0x3ca020*_0x3ef656+_0x26f4a8*_0x3c92b9+_0x5bdfe8*_0x46f90e,_0x9e0cb2[_0x203ccc+0xf]=_0x55574d*_0x4bdb1b+_0x3ca020*_0x294d25+_0x26f4a8*_0x56e315+_0x5bdfe8*_0x384b10,this;},_0x1eb00c['prototype']['equals']=function(_0x4ba7a3){var _0x45ec13=_0x4ba7a3;if(!_0x45ec13)return!0x1;if((this['_isIdentity']||_0x45ec13['_isIdentity'])&&!this['_isIdentityDirty']&&!_0x45ec13['_isIdentityDirty'])return this['_isIdentity']&&_0x45ec13['_isIdentity'];var _0x3dca6b=this['m'],_0x22c62c=_0x45ec13['m'];return _0x3dca6b[0x0]===_0x22c62c[0x0]&&_0x3dca6b[0x1]===_0x22c62c[0x1]&&_0x3dca6b[0x2]===_0x22c62c[0x2]&&_0x3dca6b[0x3]===_0x22c62c[0x3]&&_0x3dca6b[0x4]===_0x22c62c[0x4]&&_0x3dca6b[0x5]===_0x22c62c[0x5]&&_0x3dca6b[0x6]===_0x22c62c[0x6]&&_0x3dca6b[0x7]===_0x22c62c[0x7]&&_0x3dca6b[0x8]===_0x22c62c[0x8]&&_0x3dca6b[0x9]===_0x22c62c[0x9]&&_0x3dca6b[0xa]===_0x22c62c[0xa]&&_0x3dca6b[0xb]===_0x22c62c[0xb]&&_0x3dca6b[0xc]===_0x22c62c[0xc]&&_0x3dca6b[0xd]===_0x22c62c[0xd]&&_0x3dca6b[0xe]===_0x22c62c[0xe]&&_0x3dca6b[0xf]===_0x22c62c[0xf];},_0x1eb00c['prototype']['clone']=function(){var _0x45c0aa=new _0x1eb00c();return _0x45c0aa['copyFrom'](this),_0x45c0aa;},_0x1eb00c['prototype']['getClassName']=function(){return'Matrix';},_0x1eb00c['prototype']['getHashCode']=function(){for(var _0x293fde=0x0|this['_m'][0x0],_0x5ae7ab=0x1;_0x5ae7ab<0x10;_0x5ae7ab++)_0x293fde=0x18d*_0x293fde^(0x0|this['_m'][_0x5ae7ab]);return _0x293fde;},_0x1eb00c['prototype']['decompose']=function(_0x150f93,_0x360e23,_0x3e2407){if(this['_isIdentity'])return _0x3e2407&&_0x3e2407['setAll'](0x0),_0x150f93&&_0x150f93['setAll'](0x1),_0x360e23&&_0x360e23['copyFromFloats'](0x0,0x0,0x0,0x1),!0x0;var _0x5887a6=this['_m'];if(_0x3e2407&&_0x3e2407['copyFromFloats'](_0x5887a6[0xc],_0x5887a6[0xd],_0x5887a6[0xe]),(_0x150f93=_0x150f93||_0x4e1745['Vector3'][0x0])['x']=Math['sqrt'](_0x5887a6[0x0]*_0x5887a6[0x0]+_0x5887a6[0x1]*_0x5887a6[0x1]+_0x5887a6[0x2]*_0x5887a6[0x2]),_0x150f93['y']=Math['sqrt'](_0x5887a6[0x4]*_0x5887a6[0x4]+_0x5887a6[0x5]*_0x5887a6[0x5]+_0x5887a6[0x6]*_0x5887a6[0x6]),_0x150f93['z']=Math['sqrt'](_0x5887a6[0x8]*_0x5887a6[0x8]+_0x5887a6[0x9]*_0x5887a6[0x9]+_0x5887a6[0xa]*_0x5887a6[0xa]),this['determinant']()<=0x0&&(_0x150f93['y']*=-0x1),0x0===_0x150f93['_x']||0x0===_0x150f93['_y']||0x0===_0x150f93['_z'])return _0x360e23&&_0x360e23['copyFromFloats'](0x0,0x0,0x0,0x1),!0x1;if(_0x360e23){var _0x5d8cf3=0x1/_0x150f93['_x'],_0x47cfc9=0x1/_0x150f93['_y'],_0x2068ca=0x1/_0x150f93['_z'];_0x1eb00c['FromValuesToRef'](_0x5887a6[0x0]*_0x5d8cf3,_0x5887a6[0x1]*_0x5d8cf3,_0x5887a6[0x2]*_0x5d8cf3,0x0,_0x5887a6[0x4]*_0x47cfc9,_0x5887a6[0x5]*_0x47cfc9,_0x5887a6[0x6]*_0x47cfc9,0x0,_0x5887a6[0x8]*_0x2068ca,_0x5887a6[0x9]*_0x2068ca,_0x5887a6[0xa]*_0x2068ca,0x0,0x0,0x0,0x0,0x1,_0x4e1745['Matrix'][0x0]),_0x336fc5['FromRotationMatrixToRef'](_0x4e1745['Matrix'][0x0],_0x360e23);}return!0x0;},_0x1eb00c['prototype']['getRow']=function(_0x2b2b50){if(_0x2b2b50<0x0||_0x2b2b50>0x3)return null;var _0x542c6d=0x4*_0x2b2b50;return new _0xfab42b(this['_m'][_0x542c6d+0x0],this['_m'][_0x542c6d+0x1],this['_m'][_0x542c6d+0x2],this['_m'][_0x542c6d+0x3]);},_0x1eb00c['prototype']['setRow']=function(_0x591c73,_0x59bea3){return this['setRowFromFloats'](_0x591c73,_0x59bea3['x'],_0x59bea3['y'],_0x59bea3['z'],_0x59bea3['w']);},_0x1eb00c['prototype']['transpose']=function(){return _0x1eb00c['Transpose'](this);},_0x1eb00c['prototype']['transposeToRef']=function(_0x5c18a8){return _0x1eb00c['TransposeToRef'](this,_0x5c18a8),this;},_0x1eb00c['prototype']['setRowFromFloats']=function(_0x32204e,_0x1efd1e,_0x58192e,_0x1b7da9,_0x3c2d5b){if(_0x32204e<0x0||_0x32204e>0x3)return this;var _0x472f25=0x4*_0x32204e;return this['_m'][_0x472f25+0x0]=_0x1efd1e,this['_m'][_0x472f25+0x1]=_0x58192e,this['_m'][_0x472f25+0x2]=_0x1b7da9,this['_m'][_0x472f25+0x3]=_0x3c2d5b,this['_markAsUpdated'](),this;},_0x1eb00c['prototype']['scale']=function(_0x202158){var _0x5e738b=new _0x1eb00c();return this['scaleToRef'](_0x202158,_0x5e738b),_0x5e738b;},_0x1eb00c['prototype']['scaleToRef']=function(_0x28b57f,_0x289407){for(var _0x1c0aa3=0x0;_0x1c0aa3<0x10;_0x1c0aa3++)_0x289407['_m'][_0x1c0aa3]=this['_m'][_0x1c0aa3]*_0x28b57f;return _0x289407['_markAsUpdated'](),this;},_0x1eb00c['prototype']['scaleAndAddToRef']=function(_0x538cca,_0x4ba8d4){for(var _0x22a7bd=0x0;_0x22a7bd<0x10;_0x22a7bd++)_0x4ba8d4['_m'][_0x22a7bd]+=this['_m'][_0x22a7bd]*_0x538cca;return _0x4ba8d4['_markAsUpdated'](),this;},_0x1eb00c['prototype']['toNormalMatrix']=function(_0x13c2a4){var _0x125553=_0x4e1745['Matrix'][0x0];this['invertToRef'](_0x125553),_0x125553['transposeToRef'](_0x13c2a4);var _0x31cfc5=_0x13c2a4['_m'];_0x1eb00c['FromValuesToRef'](_0x31cfc5[0x0],_0x31cfc5[0x1],_0x31cfc5[0x2],0x0,_0x31cfc5[0x4],_0x31cfc5[0x5],_0x31cfc5[0x6],0x0,_0x31cfc5[0x8],_0x31cfc5[0x9],_0x31cfc5[0xa],0x0,0x0,0x0,0x0,0x1,_0x13c2a4);},_0x1eb00c['prototype']['getRotationMatrix']=function(){var _0x463490=new _0x1eb00c();return this['getRotationMatrixToRef'](_0x463490),_0x463490;},_0x1eb00c['prototype']['getRotationMatrixToRef']=function(_0x352941){var _0x119346=_0x4e1745['Vector3'][0x0];if(!this['decompose'](_0x119346))return _0x1eb00c['IdentityToRef'](_0x352941),this;var _0x180fa4=this['_m'],_0x535fab=0x1/_0x119346['_x'],_0x9e9675=0x1/_0x119346['_y'],_0x8aad7b=0x1/_0x119346['_z'];return _0x1eb00c['FromValuesToRef'](_0x180fa4[0x0]*_0x535fab,_0x180fa4[0x1]*_0x535fab,_0x180fa4[0x2]*_0x535fab,0x0,_0x180fa4[0x4]*_0x9e9675,_0x180fa4[0x5]*_0x9e9675,_0x180fa4[0x6]*_0x9e9675,0x0,_0x180fa4[0x8]*_0x8aad7b,_0x180fa4[0x9]*_0x8aad7b,_0x180fa4[0xa]*_0x8aad7b,0x0,0x0,0x0,0x0,0x1,_0x352941),this;},_0x1eb00c['prototype']['toggleModelMatrixHandInPlace']=function(){var _0x1b4f3e=this['_m'];_0x1b4f3e[0x2]*=-0x1,_0x1b4f3e[0x6]*=-0x1,_0x1b4f3e[0x8]*=-0x1,_0x1b4f3e[0x9]*=-0x1,_0x1b4f3e[0xe]*=-0x1,this['_markAsUpdated']();},_0x1eb00c['prototype']['toggleProjectionMatrixHandInPlace']=function(){var _0x529ac3=this['_m'];_0x529ac3[0x8]*=-0x1,_0x529ac3[0x9]*=-0x1,_0x529ac3[0xa]*=-0x1,_0x529ac3[0xb]*=-0x1,this['_markAsUpdated']();},_0x1eb00c['FromArray']=function(_0x445325,_0x3389ee){void 0x0===_0x3389ee&&(_0x3389ee=0x0);var _0x2d7f39=new _0x1eb00c();return _0x1eb00c['FromArrayToRef'](_0x445325,_0x3389ee,_0x2d7f39),_0x2d7f39;},_0x1eb00c['FromArrayToRef']=function(_0x4bce29,_0x232dea,_0x5cc713){for(var _0x3e3643=0x0;_0x3e3643<0x10;_0x3e3643++)_0x5cc713['_m'][_0x3e3643]=_0x4bce29[_0x3e3643+_0x232dea];_0x5cc713['_markAsUpdated']();},_0x1eb00c['FromFloat32ArrayToRefScaled']=function(_0x3288e5,_0x2b222f,_0x32c639,_0x1fd21c){for(var _0x259965=0x0;_0x259965<0x10;_0x259965++)_0x1fd21c['_m'][_0x259965]=_0x3288e5[_0x259965+_0x2b222f]*_0x32c639;_0x1fd21c['_markAsUpdated']();},Object['defineProperty'](_0x1eb00c,'IdentityReadOnly',{'get':function(){return _0x1eb00c['_identityReadOnly'];},'enumerable':!0x1,'configurable':!0x0}),_0x1eb00c['FromValuesToRef']=function(_0x356da7,_0xc41c83,_0xdb1252,_0x11224b,_0x443ed2,_0x48c738,_0x42171c,_0x2e9178,_0xff7af1,_0x54e2a1,_0x5e9a1f,_0xd90df0,_0x54a720,_0x2735a4,_0x32dffb,_0x39bd3b,_0x21842e){var _0x61a0fd=_0x21842e['_m'];_0x61a0fd[0x0]=_0x356da7,_0x61a0fd[0x1]=_0xc41c83,_0x61a0fd[0x2]=_0xdb1252,_0x61a0fd[0x3]=_0x11224b,_0x61a0fd[0x4]=_0x443ed2,_0x61a0fd[0x5]=_0x48c738,_0x61a0fd[0x6]=_0x42171c,_0x61a0fd[0x7]=_0x2e9178,_0x61a0fd[0x8]=_0xff7af1,_0x61a0fd[0x9]=_0x54e2a1,_0x61a0fd[0xa]=_0x5e9a1f,_0x61a0fd[0xb]=_0xd90df0,_0x61a0fd[0xc]=_0x54a720,_0x61a0fd[0xd]=_0x2735a4,_0x61a0fd[0xe]=_0x32dffb,_0x61a0fd[0xf]=_0x39bd3b,_0x21842e['_markAsUpdated']();},_0x1eb00c['FromValues']=function(_0x257530,_0x35c644,_0x4a7a52,_0x1f2bf1,_0x90c015,_0x5efcd9,_0x51c92c,_0x54634d,_0x273d03,_0x5662bc,_0x13e465,_0x4162b6,_0x3caac7,_0x20d3ac,_0xc9b53e,_0x3d1e18){var _0x134ca7=new _0x1eb00c(),_0x4fc853=_0x134ca7['_m'];return _0x4fc853[0x0]=_0x257530,_0x4fc853[0x1]=_0x35c644,_0x4fc853[0x2]=_0x4a7a52,_0x4fc853[0x3]=_0x1f2bf1,_0x4fc853[0x4]=_0x90c015,_0x4fc853[0x5]=_0x5efcd9,_0x4fc853[0x6]=_0x51c92c,_0x4fc853[0x7]=_0x54634d,_0x4fc853[0x8]=_0x273d03,_0x4fc853[0x9]=_0x5662bc,_0x4fc853[0xa]=_0x13e465,_0x4fc853[0xb]=_0x4162b6,_0x4fc853[0xc]=_0x3caac7,_0x4fc853[0xd]=_0x20d3ac,_0x4fc853[0xe]=_0xc9b53e,_0x4fc853[0xf]=_0x3d1e18,_0x134ca7['_markAsUpdated'](),_0x134ca7;},_0x1eb00c['Compose']=function(_0x432a81,_0x36a585,_0x3e891f){var _0x55a0b3=new _0x1eb00c();return _0x1eb00c['ComposeToRef'](_0x432a81,_0x36a585,_0x3e891f,_0x55a0b3),_0x55a0b3;},_0x1eb00c['ComposeToRef']=function(_0x7d8f16,_0x58dace,_0x339933,_0x2500c8){var _0x4ae52f=_0x2500c8['_m'],_0x526ca5=_0x58dace['_x'],_0x5b032e=_0x58dace['_y'],_0x4724e6=_0x58dace['_z'],_0x4e57e6=_0x58dace['_w'],_0x272c96=_0x526ca5+_0x526ca5,_0x1f84c=_0x5b032e+_0x5b032e,_0x93b0a5=_0x4724e6+_0x4724e6,_0x14eee6=_0x526ca5*_0x272c96,_0x2dd353=_0x526ca5*_0x1f84c,_0x57ee80=_0x526ca5*_0x93b0a5,_0x2b32b6=_0x5b032e*_0x1f84c,_0x571e6a=_0x5b032e*_0x93b0a5,_0x2ff274=_0x4724e6*_0x93b0a5,_0x5a00ec=_0x4e57e6*_0x272c96,_0x2babff=_0x4e57e6*_0x1f84c,_0x30ef62=_0x4e57e6*_0x93b0a5,_0x409368=_0x7d8f16['_x'],_0x33f6f4=_0x7d8f16['_y'],_0x24bf5a=_0x7d8f16['_z'];_0x4ae52f[0x0]=(0x1-(_0x2b32b6+_0x2ff274))*_0x409368,_0x4ae52f[0x1]=(_0x2dd353+_0x30ef62)*_0x409368,_0x4ae52f[0x2]=(_0x57ee80-_0x2babff)*_0x409368,_0x4ae52f[0x3]=0x0,_0x4ae52f[0x4]=(_0x2dd353-_0x30ef62)*_0x33f6f4,_0x4ae52f[0x5]=(0x1-(_0x14eee6+_0x2ff274))*_0x33f6f4,_0x4ae52f[0x6]=(_0x571e6a+_0x5a00ec)*_0x33f6f4,_0x4ae52f[0x7]=0x0,_0x4ae52f[0x8]=(_0x57ee80+_0x2babff)*_0x24bf5a,_0x4ae52f[0x9]=(_0x571e6a-_0x5a00ec)*_0x24bf5a,_0x4ae52f[0xa]=(0x1-(_0x14eee6+_0x2b32b6))*_0x24bf5a,_0x4ae52f[0xb]=0x0,_0x4ae52f[0xc]=_0x339933['_x'],_0x4ae52f[0xd]=_0x339933['_y'],_0x4ae52f[0xe]=_0x339933['_z'],_0x4ae52f[0xf]=0x1,_0x2500c8['_markAsUpdated']();},_0x1eb00c['Identity']=function(){var _0x5c4b94=_0x1eb00c['FromValues'](0x1,0x0,0x0,0x0,0x0,0x1,0x0,0x0,0x0,0x0,0x1,0x0,0x0,0x0,0x0,0x1);return _0x5c4b94['_updateIdentityStatus'](!0x0),_0x5c4b94;},_0x1eb00c['IdentityToRef']=function(_0x3ca96d){_0x1eb00c['FromValuesToRef'](0x1,0x0,0x0,0x0,0x0,0x1,0x0,0x0,0x0,0x0,0x1,0x0,0x0,0x0,0x0,0x1,_0x3ca96d),_0x3ca96d['_updateIdentityStatus'](!0x0);},_0x1eb00c['Zero']=function(){var _0x20f245=_0x1eb00c['FromValues'](0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0);return _0x20f245['_updateIdentityStatus'](!0x1),_0x20f245;},_0x1eb00c['RotationX']=function(_0x13cd5b){var _0x51a34a=new _0x1eb00c();return _0x1eb00c['RotationXToRef'](_0x13cd5b,_0x51a34a),_0x51a34a;},_0x1eb00c['Invert']=function(_0x2a7026){var _0x591ccd=new _0x1eb00c();return _0x2a7026['invertToRef'](_0x591ccd),_0x591ccd;},_0x1eb00c['RotationXToRef']=function(_0x17d6bd,_0x29e6f9){var _0x44c7b9=Math['sin'](_0x17d6bd),_0x591417=Math['cos'](_0x17d6bd);_0x1eb00c['FromValuesToRef'](0x1,0x0,0x0,0x0,0x0,_0x591417,_0x44c7b9,0x0,0x0,-_0x44c7b9,_0x591417,0x0,0x0,0x0,0x0,0x1,_0x29e6f9),_0x29e6f9['_updateIdentityStatus'](0x1===_0x591417&&0x0===_0x44c7b9);},_0x1eb00c['RotationY']=function(_0x471bb7){var _0x3a3e99=new _0x1eb00c();return _0x1eb00c['RotationYToRef'](_0x471bb7,_0x3a3e99),_0x3a3e99;},_0x1eb00c['RotationYToRef']=function(_0x25d65a,_0x5a0f18){var _0x48942a=Math['sin'](_0x25d65a),_0x72f8e1=Math['cos'](_0x25d65a);_0x1eb00c['FromValuesToRef'](_0x72f8e1,0x0,-_0x48942a,0x0,0x0,0x1,0x0,0x0,_0x48942a,0x0,_0x72f8e1,0x0,0x0,0x0,0x0,0x1,_0x5a0f18),_0x5a0f18['_updateIdentityStatus'](0x1===_0x72f8e1&&0x0===_0x48942a);},_0x1eb00c['RotationZ']=function(_0x717c0e){var _0x111489=new _0x1eb00c();return _0x1eb00c['RotationZToRef'](_0x717c0e,_0x111489),_0x111489;},_0x1eb00c['RotationZToRef']=function(_0x5dd13a,_0x584de6){var _0x1f02d7=Math['sin'](_0x5dd13a),_0xbf8e15=Math['cos'](_0x5dd13a);_0x1eb00c['FromValuesToRef'](_0xbf8e15,_0x1f02d7,0x0,0x0,-_0x1f02d7,_0xbf8e15,0x0,0x0,0x0,0x0,0x1,0x0,0x0,0x0,0x0,0x1,_0x584de6),_0x584de6['_updateIdentityStatus'](0x1===_0xbf8e15&&0x0===_0x1f02d7);},_0x1eb00c['RotationAxis']=function(_0x4f7bbe,_0x38a091){var _0x144358=new _0x1eb00c();return _0x1eb00c['RotationAxisToRef'](_0x4f7bbe,_0x38a091,_0x144358),_0x144358;},_0x1eb00c['RotationAxisToRef']=function(_0x96afb6,_0x38b84f,_0x37ff88){var _0x22c66e=Math['sin'](-_0x38b84f),_0x1cd969=Math['cos'](-_0x38b84f),_0x423c80=0x1-_0x1cd969;_0x96afb6['normalize']();var _0x2a4221=_0x37ff88['_m'];_0x2a4221[0x0]=_0x96afb6['_x']*_0x96afb6['_x']*_0x423c80+_0x1cd969,_0x2a4221[0x1]=_0x96afb6['_x']*_0x96afb6['_y']*_0x423c80-_0x96afb6['_z']*_0x22c66e,_0x2a4221[0x2]=_0x96afb6['_x']*_0x96afb6['_z']*_0x423c80+_0x96afb6['_y']*_0x22c66e,_0x2a4221[0x3]=0x0,_0x2a4221[0x4]=_0x96afb6['_y']*_0x96afb6['_x']*_0x423c80+_0x96afb6['_z']*_0x22c66e,_0x2a4221[0x5]=_0x96afb6['_y']*_0x96afb6['_y']*_0x423c80+_0x1cd969,_0x2a4221[0x6]=_0x96afb6['_y']*_0x96afb6['_z']*_0x423c80-_0x96afb6['_x']*_0x22c66e,_0x2a4221[0x7]=0x0,_0x2a4221[0x8]=_0x96afb6['_z']*_0x96afb6['_x']*_0x423c80-_0x96afb6['_y']*_0x22c66e,_0x2a4221[0x9]=_0x96afb6['_z']*_0x96afb6['_y']*_0x423c80+_0x96afb6['_x']*_0x22c66e,_0x2a4221[0xa]=_0x96afb6['_z']*_0x96afb6['_z']*_0x423c80+_0x1cd969,_0x2a4221[0xb]=0x0,_0x2a4221[0xc]=0x0,_0x2a4221[0xd]=0x0,_0x2a4221[0xe]=0x0,_0x2a4221[0xf]=0x1,_0x37ff88['_markAsUpdated']();},_0x1eb00c['RotationAlignToRef']=function(_0x1e81a2,_0x2767e0,_0x2bf652){var _0x3281aa=_0x39af4b['Cross'](_0x2767e0,_0x1e81a2),_0x34b023=_0x39af4b['Dot'](_0x2767e0,_0x1e81a2),_0x21ba47=0x1/(0x1+_0x34b023),_0x2fafbf=_0x2bf652['_m'];_0x2fafbf[0x0]=_0x3281aa['_x']*_0x3281aa['_x']*_0x21ba47+_0x34b023,_0x2fafbf[0x1]=_0x3281aa['_y']*_0x3281aa['_x']*_0x21ba47-_0x3281aa['_z'],_0x2fafbf[0x2]=_0x3281aa['_z']*_0x3281aa['_x']*_0x21ba47+_0x3281aa['_y'],_0x2fafbf[0x3]=0x0,_0x2fafbf[0x4]=_0x3281aa['_x']*_0x3281aa['_y']*_0x21ba47+_0x3281aa['_z'],_0x2fafbf[0x5]=_0x3281aa['_y']*_0x3281aa['_y']*_0x21ba47+_0x34b023,_0x2fafbf[0x6]=_0x3281aa['_z']*_0x3281aa['_y']*_0x21ba47-_0x3281aa['_x'],_0x2fafbf[0x7]=0x0,_0x2fafbf[0x8]=_0x3281aa['_x']*_0x3281aa['_z']*_0x21ba47-_0x3281aa['_y'],_0x2fafbf[0x9]=_0x3281aa['_y']*_0x3281aa['_z']*_0x21ba47+_0x3281aa['_x'],_0x2fafbf[0xa]=_0x3281aa['_z']*_0x3281aa['_z']*_0x21ba47+_0x34b023,_0x2fafbf[0xb]=0x0,_0x2fafbf[0xc]=0x0,_0x2fafbf[0xd]=0x0,_0x2fafbf[0xe]=0x0,_0x2fafbf[0xf]=0x1,_0x2bf652['_markAsUpdated']();},_0x1eb00c['RotationYawPitchRoll']=function(_0x7a8029,_0x40adb3,_0x56283e){var _0x452c35=new _0x1eb00c();return _0x1eb00c['RotationYawPitchRollToRef'](_0x7a8029,_0x40adb3,_0x56283e,_0x452c35),_0x452c35;},_0x1eb00c['RotationYawPitchRollToRef']=function(_0x32f012,_0x10b1c0,_0x1516bc,_0x3a871c){_0x336fc5['RotationYawPitchRollToRef'](_0x32f012,_0x10b1c0,_0x1516bc,_0x4e1745['Quaternion'][0x0]),_0x4e1745['Quaternion'][0x0]['toRotationMatrix'](_0x3a871c);},_0x1eb00c['Scaling']=function(_0x4e29da,_0x2edf49,_0x179f8a){var _0x3fc844=new _0x1eb00c();return _0x1eb00c['ScalingToRef'](_0x4e29da,_0x2edf49,_0x179f8a,_0x3fc844),_0x3fc844;},_0x1eb00c['ScalingToRef']=function(_0x4aee69,_0x2d4cba,_0x482020,_0xadb196){_0x1eb00c['FromValuesToRef'](_0x4aee69,0x0,0x0,0x0,0x0,_0x2d4cba,0x0,0x0,0x0,0x0,_0x482020,0x0,0x0,0x0,0x0,0x1,_0xadb196),_0xadb196['_updateIdentityStatus'](0x1===_0x4aee69&&0x1===_0x2d4cba&&0x1===_0x482020);},_0x1eb00c['Translation']=function(_0x4174c8,_0x246188,_0x2399b2){var _0x19fa56=new _0x1eb00c();return _0x1eb00c['TranslationToRef'](_0x4174c8,_0x246188,_0x2399b2,_0x19fa56),_0x19fa56;},_0x1eb00c['TranslationToRef']=function(_0xf0aa1e,_0x14e15d,_0x238392,_0x49bcbe){_0x1eb00c['FromValuesToRef'](0x1,0x0,0x0,0x0,0x0,0x1,0x0,0x0,0x0,0x0,0x1,0x0,_0xf0aa1e,_0x14e15d,_0x238392,0x1,_0x49bcbe),_0x49bcbe['_updateIdentityStatus'](0x0===_0xf0aa1e&&0x0===_0x14e15d&&0x0===_0x238392);},_0x1eb00c['Lerp']=function(_0x98e504,_0x26c9cb,_0x10d22e){var _0x593579=new _0x1eb00c();return _0x1eb00c['LerpToRef'](_0x98e504,_0x26c9cb,_0x10d22e,_0x593579),_0x593579;},_0x1eb00c['LerpToRef']=function(_0xea8a2c,_0x466a31,_0x4d8976,_0x2ca5d3){for(var _0xf0a637=_0x2ca5d3['_m'],_0x2d9653=_0xea8a2c['m'],_0x3c1dd1=_0x466a31['m'],_0x22a94a=0x0;_0x22a94a<0x10;_0x22a94a++)_0xf0a637[_0x22a94a]=_0x2d9653[_0x22a94a]*(0x1-_0x4d8976)+_0x3c1dd1[_0x22a94a]*_0x4d8976;_0x2ca5d3['_markAsUpdated']();},_0x1eb00c['DecomposeLerp']=function(_0x17c11c,_0x3400c7,_0x1cff4c){var _0xf099ef=new _0x1eb00c();return _0x1eb00c['DecomposeLerpToRef'](_0x17c11c,_0x3400c7,_0x1cff4c,_0xf099ef),_0xf099ef;},_0x1eb00c['DecomposeLerpToRef']=function(_0x30a542,_0x28862d,_0x5e6565,_0x106fa0){var _0x543753=_0x4e1745['Vector3'][0x0],_0x3801cc=_0x4e1745['Quaternion'][0x0],_0x1c77b1=_0x4e1745['Vector3'][0x1];_0x30a542['decompose'](_0x543753,_0x3801cc,_0x1c77b1);var _0x124dc6=_0x4e1745['Vector3'][0x2],_0x5a399d=_0x4e1745['Quaternion'][0x1],_0x3ae1d6=_0x4e1745['Vector3'][0x3];_0x28862d['decompose'](_0x124dc6,_0x5a399d,_0x3ae1d6);var _0x47ee7c=_0x4e1745['Vector3'][0x4];_0x39af4b['LerpToRef'](_0x543753,_0x124dc6,_0x5e6565,_0x47ee7c);var _0x59bf61=_0x4e1745['Quaternion'][0x2];_0x336fc5['SlerpToRef'](_0x3801cc,_0x5a399d,_0x5e6565,_0x59bf61);var _0x191ffe=_0x4e1745['Vector3'][0x5];_0x39af4b['LerpToRef'](_0x1c77b1,_0x3ae1d6,_0x5e6565,_0x191ffe),_0x1eb00c['ComposeToRef'](_0x47ee7c,_0x59bf61,_0x191ffe,_0x106fa0);},_0x1eb00c['LookAtLH']=function(_0x37f356,_0x1b68f5,_0xcfdab5){var _0x93edf5=new _0x1eb00c();return _0x1eb00c['LookAtLHToRef'](_0x37f356,_0x1b68f5,_0xcfdab5,_0x93edf5),_0x93edf5;},_0x1eb00c['LookAtLHToRef']=function(_0x48c84c,_0x570b40,_0x566d32,_0x304e17){var _0x1c10ac=_0x4e1745['Vector3'][0x0],_0x8ec985=_0x4e1745['Vector3'][0x1],_0x5a4f98=_0x4e1745['Vector3'][0x2];_0x570b40['subtractToRef'](_0x48c84c,_0x5a4f98),_0x5a4f98['normalize'](),_0x39af4b['CrossToRef'](_0x566d32,_0x5a4f98,_0x1c10ac);var _0x3e5216=_0x1c10ac['lengthSquared']();0x0===_0x3e5216?_0x1c10ac['x']=0x1:_0x1c10ac['normalizeFromLength'](Math['sqrt'](_0x3e5216)),_0x39af4b['CrossToRef'](_0x5a4f98,_0x1c10ac,_0x8ec985),_0x8ec985['normalize']();var _0x25c130=-_0x39af4b['Dot'](_0x1c10ac,_0x48c84c),_0x5f48db=-_0x39af4b['Dot'](_0x8ec985,_0x48c84c),_0x3eda1b=-_0x39af4b['Dot'](_0x5a4f98,_0x48c84c);_0x1eb00c['FromValuesToRef'](_0x1c10ac['_x'],_0x8ec985['_x'],_0x5a4f98['_x'],0x0,_0x1c10ac['_y'],_0x8ec985['_y'],_0x5a4f98['_y'],0x0,_0x1c10ac['_z'],_0x8ec985['_z'],_0x5a4f98['_z'],0x0,_0x25c130,_0x5f48db,_0x3eda1b,0x1,_0x304e17);},_0x1eb00c['LookAtRH']=function(_0x12e865,_0x3a9342,_0x160b0c){var _0x59e87d=new _0x1eb00c();return _0x1eb00c['LookAtRHToRef'](_0x12e865,_0x3a9342,_0x160b0c,_0x59e87d),_0x59e87d;},_0x1eb00c['LookAtRHToRef']=function(_0x10a85e,_0x38e8a3,_0xe38a9c,_0x2d8e2a){var _0x5b0446=_0x4e1745['Vector3'][0x0],_0x1100fd=_0x4e1745['Vector3'][0x1],_0x452921=_0x4e1745['Vector3'][0x2];_0x10a85e['subtractToRef'](_0x38e8a3,_0x452921),_0x452921['normalize'](),_0x39af4b['CrossToRef'](_0xe38a9c,_0x452921,_0x5b0446);var _0x4e7365=_0x5b0446['lengthSquared']();0x0===_0x4e7365?_0x5b0446['x']=0x1:_0x5b0446['normalizeFromLength'](Math['sqrt'](_0x4e7365)),_0x39af4b['CrossToRef'](_0x452921,_0x5b0446,_0x1100fd),_0x1100fd['normalize']();var _0x344a72=-_0x39af4b['Dot'](_0x5b0446,_0x10a85e),_0x206b18=-_0x39af4b['Dot'](_0x1100fd,_0x10a85e),_0x159f1b=-_0x39af4b['Dot'](_0x452921,_0x10a85e);_0x1eb00c['FromValuesToRef'](_0x5b0446['_x'],_0x1100fd['_x'],_0x452921['_x'],0x0,_0x5b0446['_y'],_0x1100fd['_y'],_0x452921['_y'],0x0,_0x5b0446['_z'],_0x1100fd['_z'],_0x452921['_z'],0x0,_0x344a72,_0x206b18,_0x159f1b,0x1,_0x2d8e2a);},_0x1eb00c['OrthoLH']=function(_0x33297c,_0x1746b3,_0x3aa60a,_0x14734d){var _0x358d95=new _0x1eb00c();return _0x1eb00c['OrthoLHToRef'](_0x33297c,_0x1746b3,_0x3aa60a,_0x14734d,_0x358d95),_0x358d95;},_0x1eb00c['OrthoLHToRef']=function(_0xc67d6f,_0x149ed7,_0x21ccf2,_0x1ecff9,_0x7a3022){var _0x386dd4=0x2/_0xc67d6f,_0x3596a7=0x2/_0x149ed7,_0x2533db=0x2/(_0x1ecff9-_0x21ccf2),_0x4155b4=-(_0x1ecff9+_0x21ccf2)/(_0x1ecff9-_0x21ccf2);_0x1eb00c['FromValuesToRef'](_0x386dd4,0x0,0x0,0x0,0x0,_0x3596a7,0x0,0x0,0x0,0x0,_0x2533db,0x0,0x0,0x0,_0x4155b4,0x1,_0x7a3022),_0x7a3022['_updateIdentityStatus'](0x1===_0x386dd4&&0x1===_0x3596a7&&0x1===_0x2533db&&0x0===_0x4155b4);},_0x1eb00c['OrthoOffCenterLH']=function(_0xea59d,_0x38be7a,_0x39f455,_0x14b995,_0x5d7315,_0x573ca7){var _0x38e1c5=new _0x1eb00c();return _0x1eb00c['OrthoOffCenterLHToRef'](_0xea59d,_0x38be7a,_0x39f455,_0x14b995,_0x5d7315,_0x573ca7,_0x38e1c5),_0x38e1c5;},_0x1eb00c['OrthoOffCenterLHToRef']=function(_0xb61c67,_0x5ee2fc,_0xa07827,_0x17d86f,_0x28b201,_0x578ae7,_0x5b3e5e){var _0x203c46=0x2/(_0x5ee2fc-_0xb61c67),_0x1abef7=0x2/(_0x17d86f-_0xa07827),_0xde3f53=0x2/(_0x578ae7-_0x28b201),_0x4f308c=-(_0x578ae7+_0x28b201)/(_0x578ae7-_0x28b201),_0x2ddae7=(_0xb61c67+_0x5ee2fc)/(_0xb61c67-_0x5ee2fc),_0x171bc4=(_0x17d86f+_0xa07827)/(_0xa07827-_0x17d86f);_0x1eb00c['FromValuesToRef'](_0x203c46,0x0,0x0,0x0,0x0,_0x1abef7,0x0,0x0,0x0,0x0,_0xde3f53,0x0,_0x2ddae7,_0x171bc4,_0x4f308c,0x1,_0x5b3e5e),_0x5b3e5e['_markAsUpdated']();},_0x1eb00c['OrthoOffCenterRH']=function(_0x3272e2,_0x5a1dd0,_0x271f4e,_0x394f91,_0x156d80,_0x6241a6){var _0x42684c=new _0x1eb00c();return _0x1eb00c['OrthoOffCenterRHToRef'](_0x3272e2,_0x5a1dd0,_0x271f4e,_0x394f91,_0x156d80,_0x6241a6,_0x42684c),_0x42684c;},_0x1eb00c['OrthoOffCenterRHToRef']=function(_0x20bfb0,_0xfd0d47,_0x479552,_0x3875f2,_0x28cfad,_0x2c908e,_0x169e85){_0x1eb00c['OrthoOffCenterLHToRef'](_0x20bfb0,_0xfd0d47,_0x479552,_0x3875f2,_0x28cfad,_0x2c908e,_0x169e85),_0x169e85['_m'][0xa]*=-0x1;},_0x1eb00c['PerspectiveLH']=function(_0x348b19,_0x32f089,_0x50a046,_0x36ed7c){var _0x21a269=new _0x1eb00c(),_0x53d477=0x2*_0x50a046/_0x348b19,_0x4dbe4d=0x2*_0x50a046/_0x32f089,_0xc01840=(_0x36ed7c+_0x50a046)/(_0x36ed7c-_0x50a046),_0x39db88=-0x2*_0x36ed7c*_0x50a046/(_0x36ed7c-_0x50a046);return _0x1eb00c['FromValuesToRef'](_0x53d477,0x0,0x0,0x0,0x0,_0x4dbe4d,0x0,0x0,0x0,0x0,_0xc01840,0x1,0x0,0x0,_0x39db88,0x0,_0x21a269),_0x21a269['_updateIdentityStatus'](!0x1),_0x21a269;},_0x1eb00c['PerspectiveFovLH']=function(_0x64bd9a,_0x3ec482,_0x16de1b,_0x44d16e){var _0x235a90=new _0x1eb00c();return _0x1eb00c['PerspectiveFovLHToRef'](_0x64bd9a,_0x3ec482,_0x16de1b,_0x44d16e,_0x235a90),_0x235a90;},_0x1eb00c['PerspectiveFovLHToRef']=function(_0x37d121,_0x9c4639,_0x1dd07e,_0x1f1cf4,_0x2ecd40,_0x302796){void 0x0===_0x302796&&(_0x302796=!0x0);var _0x4214a0=_0x1dd07e,_0x325348=_0x1f1cf4,_0x499e11=0x1/Math['tan'](0.5*_0x37d121),_0x2c19bc=_0x302796?_0x499e11/_0x9c4639:_0x499e11,_0x33cd7e=_0x302796?_0x499e11:_0x499e11*_0x9c4639,_0x1ff630=(_0x325348+_0x4214a0)/(_0x325348-_0x4214a0),_0xe306ba=-0x2*_0x325348*_0x4214a0/(_0x325348-_0x4214a0);_0x1eb00c['FromValuesToRef'](_0x2c19bc,0x0,0x0,0x0,0x0,_0x33cd7e,0x0,0x0,0x0,0x0,_0x1ff630,0x1,0x0,0x0,_0xe306ba,0x0,_0x2ecd40),_0x2ecd40['_updateIdentityStatus'](!0x1);},_0x1eb00c['PerspectiveFovReverseLHToRef']=function(_0xa13f2b,_0x2f5927,_0xa6c01,_0x86e6db,_0x2b9ed4,_0xdc8cf4){void 0x0===_0xdc8cf4&&(_0xdc8cf4=!0x0);var _0x25c39d=0x1/Math['tan'](0.5*_0xa13f2b),_0x38186c=_0xdc8cf4?_0x25c39d/_0x2f5927:_0x25c39d,_0xba4437=_0xdc8cf4?_0x25c39d:_0x25c39d*_0x2f5927;_0x1eb00c['FromValuesToRef'](_0x38186c,0x0,0x0,0x0,0x0,_0xba4437,0x0,0x0,0x0,0x0,-_0xa6c01,0x1,0x0,0x0,0x1,0x0,_0x2b9ed4),_0x2b9ed4['_updateIdentityStatus'](!0x1);},_0x1eb00c['PerspectiveFovRH']=function(_0x1f5781,_0x40eeee,_0x416a7b,_0x1756d2){var _0x20d820=new _0x1eb00c();return _0x1eb00c['PerspectiveFovRHToRef'](_0x1f5781,_0x40eeee,_0x416a7b,_0x1756d2,_0x20d820),_0x20d820;},_0x1eb00c['PerspectiveFovRHToRef']=function(_0x56d9cb,_0x53e3f1,_0x3a4b68,_0xe90c39,_0x58a763,_0x36bd88){void 0x0===_0x36bd88&&(_0x36bd88=!0x0);var _0x2d90fb=_0x3a4b68,_0x33ca57=_0xe90c39,_0x4bd852=0x1/Math['tan'](0.5*_0x56d9cb),_0x1e3d7b=_0x36bd88?_0x4bd852/_0x53e3f1:_0x4bd852,_0xf9c749=_0x36bd88?_0x4bd852:_0x4bd852*_0x53e3f1,_0x5cd79b=-(_0x33ca57+_0x2d90fb)/(_0x33ca57-_0x2d90fb),_0x1bfe4a=-0x2*_0x33ca57*_0x2d90fb/(_0x33ca57-_0x2d90fb);_0x1eb00c['FromValuesToRef'](_0x1e3d7b,0x0,0x0,0x0,0x0,_0xf9c749,0x0,0x0,0x0,0x0,_0x5cd79b,-0x1,0x0,0x0,_0x1bfe4a,0x0,_0x58a763),_0x58a763['_updateIdentityStatus'](!0x1);},_0x1eb00c['PerspectiveFovReverseRHToRef']=function(_0x22d2d1,_0x1df806,_0x58e8b8,_0x2c7193,_0x16b704,_0x1745b0){void 0x0===_0x1745b0&&(_0x1745b0=!0x0);var _0x4966df=0x1/Math['tan'](0.5*_0x22d2d1),_0x3034d0=_0x1745b0?_0x4966df/_0x1df806:_0x4966df,_0x13ac24=_0x1745b0?_0x4966df:_0x4966df*_0x1df806;_0x1eb00c['FromValuesToRef'](_0x3034d0,0x0,0x0,0x0,0x0,_0x13ac24,0x0,0x0,0x0,0x0,-_0x58e8b8,-0x1,0x0,0x0,-0x1,0x0,_0x16b704),_0x16b704['_updateIdentityStatus'](!0x1);},_0x1eb00c['PerspectiveFovWebVRToRef']=function(_0x1cbdca,_0xa7461c,_0x2cff5d,_0x1fd2e3,_0x4dc4e0){void 0x0===_0x4dc4e0&&(_0x4dc4e0=!0x1);var _0xbc42d4=_0x4dc4e0?-0x1:0x1,_0x452b85=Math['tan'](_0x1cbdca['upDegrees']*Math['PI']/0xb4),_0x5a1b89=Math['tan'](_0x1cbdca['downDegrees']*Math['PI']/0xb4),_0x35b8bb=Math['tan'](_0x1cbdca['leftDegrees']*Math['PI']/0xb4),_0x3df366=Math['tan'](_0x1cbdca['rightDegrees']*Math['PI']/0xb4),_0x157723=0x2/(_0x35b8bb+_0x3df366),_0x357f0e=0x2/(_0x452b85+_0x5a1b89),_0x528414=_0x1fd2e3['_m'];_0x528414[0x0]=_0x157723,_0x528414[0x1]=_0x528414[0x2]=_0x528414[0x3]=_0x528414[0x4]=0x0,_0x528414[0x5]=_0x357f0e,_0x528414[0x6]=_0x528414[0x7]=0x0,_0x528414[0x8]=(_0x35b8bb-_0x3df366)*_0x157723*0.5,_0x528414[0x9]=-(_0x452b85-_0x5a1b89)*_0x357f0e*0.5,_0x528414[0xa]=-_0x2cff5d/(_0xa7461c-_0x2cff5d),_0x528414[0xb]=0x1*_0xbc42d4,_0x528414[0xc]=_0x528414[0xd]=_0x528414[0xf]=0x0,_0x528414[0xe]=-0x2*_0x2cff5d*_0xa7461c/(_0x2cff5d-_0xa7461c),_0x1fd2e3['_markAsUpdated']();},_0x1eb00c['GetFinalMatrix']=function(_0x2a3001,_0x502196,_0x34cef3,_0x1be6a5,_0x361d75,_0x401e29){var _0x267472=_0x2a3001['width'],_0x2285d2=_0x2a3001['height'],_0xc72293=_0x2a3001['x'],_0x1e73b2=_0x2a3001['y'],_0x3a0a45=_0x1eb00c['FromValues'](_0x267472/0x2,0x0,0x0,0x0,0x0,-_0x2285d2/0x2,0x0,0x0,0x0,0x0,_0x401e29-_0x361d75,0x0,_0xc72293+_0x267472/0x2,_0x2285d2/0x2+_0x1e73b2,_0x361d75,0x1),_0x1c512a=_0x4e1745['Matrix'][0x0];return _0x502196['multiplyToRef'](_0x34cef3,_0x1c512a),_0x1c512a['multiplyToRef'](_0x1be6a5,_0x1c512a),_0x1c512a['multiply'](_0x3a0a45);},_0x1eb00c['GetAsMatrix2x2']=function(_0x129dbf){var _0x4734a6=_0x129dbf['m'],_0x2eaf09=[_0x4734a6[0x0],_0x4734a6[0x1],_0x4734a6[0x4],_0x4734a6[0x5]];return _0x5e0c90['a']['MatrixUse64Bits']?_0x2eaf09:new Float32Array(_0x2eaf09);},_0x1eb00c['GetAsMatrix3x3']=function(_0x2a5a14){var _0x4c5aa7=_0x2a5a14['m'],_0x337592=[_0x4c5aa7[0x0],_0x4c5aa7[0x1],_0x4c5aa7[0x2],_0x4c5aa7[0x4],_0x4c5aa7[0x5],_0x4c5aa7[0x6],_0x4c5aa7[0x8],_0x4c5aa7[0x9],_0x4c5aa7[0xa]];return _0x5e0c90['a']['MatrixUse64Bits']?_0x337592:new Float32Array(_0x337592);},_0x1eb00c['Transpose']=function(_0xbf2fdb){var _0xdc221c=new _0x1eb00c();return _0x1eb00c['TransposeToRef'](_0xbf2fdb,_0xdc221c),_0xdc221c;},_0x1eb00c['TransposeToRef']=function(_0x2f7bed,_0xd5c6eb){var _0x8c51db=_0xd5c6eb['_m'],_0x9c6664=_0x2f7bed['m'];_0x8c51db[0x0]=_0x9c6664[0x0],_0x8c51db[0x1]=_0x9c6664[0x4],_0x8c51db[0x2]=_0x9c6664[0x8],_0x8c51db[0x3]=_0x9c6664[0xc],_0x8c51db[0x4]=_0x9c6664[0x1],_0x8c51db[0x5]=_0x9c6664[0x5],_0x8c51db[0x6]=_0x9c6664[0x9],_0x8c51db[0x7]=_0x9c6664[0xd],_0x8c51db[0x8]=_0x9c6664[0x2],_0x8c51db[0x9]=_0x9c6664[0x6],_0x8c51db[0xa]=_0x9c6664[0xa],_0x8c51db[0xb]=_0x9c6664[0xe],_0x8c51db[0xc]=_0x9c6664[0x3],_0x8c51db[0xd]=_0x9c6664[0x7],_0x8c51db[0xe]=_0x9c6664[0xb],_0x8c51db[0xf]=_0x9c6664[0xf],_0xd5c6eb['_updateIdentityStatus'](_0x2f7bed['_isIdentity'],_0x2f7bed['_isIdentityDirty']);},_0x1eb00c['Reflection']=function(_0x3b1595){var _0x44e9e1=new _0x1eb00c();return _0x1eb00c['ReflectionToRef'](_0x3b1595,_0x44e9e1),_0x44e9e1;},_0x1eb00c['ReflectionToRef']=function(_0x53546b,_0x2c4eaa){_0x53546b['normalize']();var _0xa2996a=_0x53546b['normal']['x'],_0x74a080=_0x53546b['normal']['y'],_0x5f0f97=_0x53546b['normal']['z'],_0x11c3be=-0x2*_0xa2996a,_0x2c606c=-0x2*_0x74a080,_0x2d5184=-0x2*_0x5f0f97;_0x1eb00c['FromValuesToRef'](_0x11c3be*_0xa2996a+0x1,_0x2c606c*_0xa2996a,_0x2d5184*_0xa2996a,0x0,_0x11c3be*_0x74a080,_0x2c606c*_0x74a080+0x1,_0x2d5184*_0x74a080,0x0,_0x11c3be*_0x5f0f97,_0x2c606c*_0x5f0f97,_0x2d5184*_0x5f0f97+0x1,0x0,_0x11c3be*_0x53546b['d'],_0x2c606c*_0x53546b['d'],_0x2d5184*_0x53546b['d'],0x1,_0x2c4eaa);},_0x1eb00c['FromXYZAxesToRef']=function(_0x298f79,_0x8e56dc,_0x168882,_0x8c84ae){_0x1eb00c['FromValuesToRef'](_0x298f79['_x'],_0x298f79['_y'],_0x298f79['_z'],0x0,_0x8e56dc['_x'],_0x8e56dc['_y'],_0x8e56dc['_z'],0x0,_0x168882['_x'],_0x168882['_y'],_0x168882['_z'],0x0,0x0,0x0,0x0,0x1,_0x8c84ae);},_0x1eb00c['FromQuaternionToRef']=function(_0x475a04,_0x2cbbf1){var _0x5c6a01=_0x475a04['_x']*_0x475a04['_x'],_0x4eb9a4=_0x475a04['_y']*_0x475a04['_y'],_0x30247e=_0x475a04['_z']*_0x475a04['_z'],_0x3b3741=_0x475a04['_x']*_0x475a04['_y'],_0x3cc2b0=_0x475a04['_z']*_0x475a04['_w'],_0x779f71=_0x475a04['_z']*_0x475a04['_x'],_0x5b21ad=_0x475a04['_y']*_0x475a04['_w'],_0x21a4c3=_0x475a04['_y']*_0x475a04['_z'],_0x3607b8=_0x475a04['_x']*_0x475a04['_w'];_0x2cbbf1['_m'][0x0]=0x1-0x2*(_0x4eb9a4+_0x30247e),_0x2cbbf1['_m'][0x1]=0x2*(_0x3b3741+_0x3cc2b0),_0x2cbbf1['_m'][0x2]=0x2*(_0x779f71-_0x5b21ad),_0x2cbbf1['_m'][0x3]=0x0,_0x2cbbf1['_m'][0x4]=0x2*(_0x3b3741-_0x3cc2b0),_0x2cbbf1['_m'][0x5]=0x1-0x2*(_0x30247e+_0x5c6a01),_0x2cbbf1['_m'][0x6]=0x2*(_0x21a4c3+_0x3607b8),_0x2cbbf1['_m'][0x7]=0x0,_0x2cbbf1['_m'][0x8]=0x2*(_0x779f71+_0x5b21ad),_0x2cbbf1['_m'][0x9]=0x2*(_0x21a4c3-_0x3607b8),_0x2cbbf1['_m'][0xa]=0x1-0x2*(_0x4eb9a4+_0x5c6a01),_0x2cbbf1['_m'][0xb]=0x0,_0x2cbbf1['_m'][0xc]=0x0,_0x2cbbf1['_m'][0xd]=0x0,_0x2cbbf1['_m'][0xe]=0x0,_0x2cbbf1['_m'][0xf]=0x1,_0x2cbbf1['_markAsUpdated']();},_0x1eb00c['_updateFlagSeed']=0x0,_0x1eb00c['_identityReadOnly']=_0x1eb00c['Identity'](),_0x1eb00c;}()),_0x4e1745=(function(){function _0x4091e5(){}return _0x4091e5['Vector3']=_0x511cc6['a']['BuildArray'](0x6,_0x39af4b['Zero']),_0x4091e5['Matrix']=_0x511cc6['a']['BuildArray'](0x2,_0x54ba40['Identity']),_0x4091e5['Quaternion']=_0x511cc6['a']['BuildArray'](0x3,_0x336fc5['Zero']),_0x4091e5;}()),_0x4c18fb=(function(){function _0x2b82f1(){}return _0x2b82f1['Vector2']=_0x511cc6['a']['BuildArray'](0x3,_0x320d63['Zero']),_0x2b82f1['Vector3']=_0x511cc6['a']['BuildArray'](0xd,_0x39af4b['Zero']),_0x2b82f1['Vector4']=_0x511cc6['a']['BuildArray'](0x3,_0xfab42b['Zero']),_0x2b82f1['Quaternion']=_0x511cc6['a']['BuildArray'](0x2,_0x336fc5['Zero']),_0x2b82f1['Matrix']=_0x511cc6['a']['BuildArray'](0x8,_0x54ba40['Identity']),_0x2b82f1;}());_0x5633c1['a']['RegisteredTypes']['BABYLON.Vector2']=_0x320d63,_0x5633c1['a']['RegisteredTypes']['BABYLON.Vector3']=_0x39af4b,_0x5633c1['a']['RegisteredTypes']['BABYLON.Vector4']=_0xfab42b,_0x5633c1['a']['RegisteredTypes']['BABYLON.Matrix']=_0x54ba40;},function(_0x47ddb8,_0x3ed7ea,_0x465090){'use strict';_0x465090['d'](_0x3ed7ea,'d',function(){return _0x1e517c;}),_0x465090['d'](_0x3ed7ea,'a',function(){return _0x26f5e3;}),_0x465090['d'](_0x3ed7ea,'c',function(){return _0x4d97aa;}),_0x465090['d'](_0x3ed7ea,'b',function(){return _0xe12797;}),_0x465090['d'](_0x3ed7ea,'e',function(){return _0xe1c102;}),_0x465090['d'](_0x3ed7ea,'f',function(){return _0x582fb4;});var _0x5a02bd=function(_0x474649,_0x3a3d16){return(_0x5a02bd=Object['setPrototypeOf']||{'__proto__':[]}instanceof Array&&function(_0x331efc,_0x12960a){_0x331efc['__proto__']=_0x12960a;}||function(_0x21b81a,_0x51bbc3){for(var _0x1b8a68 in _0x51bbc3)Object['prototype']['hasOwnProperty']['call'](_0x51bbc3,_0x1b8a68)&&(_0x21b81a[_0x1b8a68]=_0x51bbc3[_0x1b8a68]);})(_0x474649,_0x3a3d16);};function _0x1e517c(_0x6b2955,_0x586f42){if('function'!=typeof _0x586f42&&null!==_0x586f42)throw new TypeError('Class\x20extends\x20value\x20'+String(_0x586f42)+'\x20is\x20not\x20a\x20constructor\x20or\x20null');function _0x312664(){this['constructor']=_0x6b2955;}_0x5a02bd(_0x6b2955,_0x586f42),_0x6b2955['prototype']=null===_0x586f42?Object['create'](_0x586f42):(_0x312664['prototype']=_0x586f42['prototype'],new _0x312664());}var _0x26f5e3=function(){return(_0x26f5e3=Object['assign']||function(_0xc04b28){for(var _0x1dd88c,_0x3158c6=0x1,_0x4fb3a9=arguments['length'];_0x3158c6<_0x4fb3a9;_0x3158c6++)for(var _0x142365 in _0x1dd88c=arguments[_0x3158c6])Object['prototype']['hasOwnProperty']['call'](_0x1dd88c,_0x142365)&&(_0xc04b28[_0x142365]=_0x1dd88c[_0x142365]);return _0xc04b28;})['apply'](this,arguments);};function _0x4d97aa(_0xc5a79e,_0x3a0b79,_0x1c4dd5,_0x13f69b){var _0x427794,_0x5bddbc=arguments['length'],_0x15b1e6=_0x5bddbc<0x3?_0x3a0b79:null===_0x13f69b?_0x13f69b=Object['getOwnPropertyDescriptor'](_0x3a0b79,_0x1c4dd5):_0x13f69b;if('object'==typeof Reflect&&'function'==typeof Reflect['decorate'])_0x15b1e6=Reflect['decorate'](_0xc5a79e,_0x3a0b79,_0x1c4dd5,_0x13f69b);else{for(var _0x59e287=_0xc5a79e['length']-0x1;_0x59e287>=0x0;_0x59e287--)(_0x427794=_0xc5a79e[_0x59e287])&&(_0x15b1e6=(_0x5bddbc<0x3?_0x427794(_0x15b1e6):_0x5bddbc>0x3?_0x427794(_0x3a0b79,_0x1c4dd5,_0x15b1e6):_0x427794(_0x3a0b79,_0x1c4dd5))||_0x15b1e6);}return _0x5bddbc>0x3&&_0x15b1e6&&Object['defineProperty'](_0x3a0b79,_0x1c4dd5,_0x15b1e6),_0x15b1e6;}function _0xe12797(_0x3aa3cc,_0x5758a8,_0x37d24c,_0x1e1d4d){return new(_0x37d24c||(_0x37d24c=Promise))(function(_0x472023,_0x19c6e1){function _0x2431b4(_0x51727e){try{_0x27127f(_0x1e1d4d['next'](_0x51727e));}catch(_0x5a2872){_0x19c6e1(_0x5a2872);}}function _0x1314b8(_0x18c851){try{_0x27127f(_0x1e1d4d['throw'](_0x18c851));}catch(_0x475642){_0x19c6e1(_0x475642);}}function _0x27127f(_0x414af3){var _0x4cfcf7;_0x414af3['done']?_0x472023(_0x414af3['value']):(_0x4cfcf7=_0x414af3['value'],_0x4cfcf7 instanceof _0x37d24c?_0x4cfcf7:new _0x37d24c(function(_0x148f19){_0x148f19(_0x4cfcf7);}))['then'](_0x2431b4,_0x1314b8);}_0x27127f((_0x1e1d4d=_0x1e1d4d['apply'](_0x3aa3cc,_0x5758a8||[]))['next']());});}function _0xe1c102(_0x2d4b0d,_0x1ea2c7){var _0x43125f,_0x52dfef,_0x355950,_0x37c71b,_0x18c242={'label':0x0,'sent':function(){if(0x1&_0x355950[0x0])throw _0x355950[0x1];return _0x355950[0x1];},'trys':[],'ops':[]};return _0x37c71b={'next':_0xaf9a15(0x0),'throw':_0xaf9a15(0x1),'return':_0xaf9a15(0x2)},'function'==typeof Symbol&&(_0x37c71b[Symbol['iterator']]=function(){return this;}),_0x37c71b;function _0xaf9a15(_0x23b005){return function(_0x3cc3aa){return function(_0x236a2){if(_0x43125f)throw new TypeError('Generator\x20is\x20already\x20executing.');for(;_0x18c242;)try{if(_0x43125f=0x1,_0x52dfef&&(_0x355950=0x2&_0x236a2[0x0]?_0x52dfef['return']:_0x236a2[0x0]?_0x52dfef['throw']||((_0x355950=_0x52dfef['return'])&&_0x355950['call'](_0x52dfef),0x0):_0x52dfef['next'])&&!(_0x355950=_0x355950['call'](_0x52dfef,_0x236a2[0x1]))['done'])return _0x355950;switch(_0x52dfef=0x0,_0x355950&&(_0x236a2=[0x2&_0x236a2[0x0],_0x355950['value']]),_0x236a2[0x0]){case 0x0:case 0x1:_0x355950=_0x236a2;break;case 0x4:return _0x18c242['label']++,{'value':_0x236a2[0x1],'done':!0x1};case 0x5:_0x18c242['label']++,_0x52dfef=_0x236a2[0x1],_0x236a2=[0x0];continue;case 0x7:_0x236a2=_0x18c242['ops']['pop'](),_0x18c242['trys']['pop']();continue;default:if(!(_0x355950=_0x18c242['trys'],(_0x355950=_0x355950['length']>0x0&&_0x355950[_0x355950['length']-0x1])||0x6!==_0x236a2[0x0]&&0x2!==_0x236a2[0x0])){_0x18c242=0x0;continue;}if(0x3===_0x236a2[0x0]&&(!_0x355950||_0x236a2[0x1]>_0x355950[0x0]&&_0x236a2[0x1]<_0x355950[0x3])){_0x18c242['label']=_0x236a2[0x1];break;}if(0x6===_0x236a2[0x0]&&_0x18c242['label']<_0x355950[0x1]){_0x18c242['label']=_0x355950[0x1],_0x355950=_0x236a2;break;}if(_0x355950&&_0x18c242['label']<_0x355950[0x2]){_0x18c242['label']=_0x355950[0x2],_0x18c242['ops']['push'](_0x236a2);break;}_0x355950[0x2]&&_0x18c242['ops']['pop'](),_0x18c242['trys']['pop']();continue;}_0x236a2=_0x1ea2c7['call'](_0x2d4b0d,_0x18c242);}catch(_0x4717b6){_0x236a2=[0x6,_0x4717b6],_0x52dfef=0x0;}finally{_0x43125f=_0x355950=0x0;}if(0x5&_0x236a2[0x0])throw _0x236a2[0x1];return{'value':_0x236a2[0x0]?_0x236a2[0x1]:void 0x0,'done':!0x0};}([_0x23b005,_0x3cc3aa]);};}}Object['create'];function _0x582fb4(){for(var _0x5d18f5=0x0,_0x3bf3d1=0x0,_0x1b26f7=arguments['length'];_0x3bf3d1<_0x1b26f7;_0x3bf3d1++)_0x5d18f5+=arguments[_0x3bf3d1]['length'];var _0x54ea7=Array(_0x5d18f5),_0x52a0df=0x0;for(_0x3bf3d1=0x0;_0x3bf3d1<_0x1b26f7;_0x3bf3d1++)for(var _0x416f3a=arguments[_0x3bf3d1],_0x3d4f22=0x0,_0x54deb3=_0x416f3a['length'];_0x3d4f22<_0x54deb3;_0x3d4f22++,_0x52a0df++)_0x54ea7[_0x52a0df]=_0x416f3a[_0x3d4f22];return _0x54ea7;}Object['create'];},function(_0x1707ab,_0x52b8a1,_0x5b080a){'use strict';_0x5b080a['d'](_0x52b8a1,'a',function(){return _0x25acc8;});var _0x25acc8=(function(){function _0x5f2491(){}return _0x5f2491['ALPHA_DISABLE']=0x0,_0x5f2491['ALPHA_ADD']=0x1,_0x5f2491['ALPHA_COMBINE']=0x2,_0x5f2491['ALPHA_SUBTRACT']=0x3,_0x5f2491['ALPHA_MULTIPLY']=0x4,_0x5f2491['ALPHA_MAXIMIZED']=0x5,_0x5f2491['ALPHA_ONEONE']=0x6,_0x5f2491['ALPHA_PREMULTIPLIED']=0x7,_0x5f2491['ALPHA_PREMULTIPLIED_PORTERDUFF']=0x8,_0x5f2491['ALPHA_INTERPOLATE']=0x9,_0x5f2491['ALPHA_SCREENMODE']=0xa,_0x5f2491['ALPHA_ONEONE_ONEONE']=0xb,_0x5f2491['ALPHA_ALPHATOCOLOR']=0xc,_0x5f2491['ALPHA_REVERSEONEMINUS']=0xd,_0x5f2491['ALPHA_SRC_DSTONEMINUSSRCALPHA']=0xe,_0x5f2491['ALPHA_ONEONE_ONEZERO']=0xf,_0x5f2491['ALPHA_EXCLUSION']=0x10,_0x5f2491['ALPHA_EQUATION_ADD']=0x0,_0x5f2491['ALPHA_EQUATION_SUBSTRACT']=0x1,_0x5f2491['ALPHA_EQUATION_REVERSE_SUBTRACT']=0x2,_0x5f2491['ALPHA_EQUATION_MAX']=0x3,_0x5f2491['ALPHA_EQUATION_MIN']=0x4,_0x5f2491['ALPHA_EQUATION_DARKEN']=0x5,_0x5f2491['DELAYLOADSTATE_NONE']=0x0,_0x5f2491['DELAYLOADSTATE_LOADED']=0x1,_0x5f2491['DELAYLOADSTATE_LOADING']=0x2,_0x5f2491['DELAYLOADSTATE_NOTLOADED']=0x4,_0x5f2491['NEVER']=0x200,_0x5f2491['ALWAYS']=0x207,_0x5f2491['LESS']=0x201,_0x5f2491['EQUAL']=0x202,_0x5f2491['LEQUAL']=0x203,_0x5f2491['GREATER']=0x204,_0x5f2491['GEQUAL']=0x206,_0x5f2491['NOTEQUAL']=0x205,_0x5f2491['KEEP']=0x1e00,_0x5f2491['REPLACE']=0x1e01,_0x5f2491['INCR']=0x1e02,_0x5f2491['DECR']=0x1e03,_0x5f2491['INVERT']=0x150a,_0x5f2491['INCR_WRAP']=0x8507,_0x5f2491['DECR_WRAP']=0x8508,_0x5f2491['TEXTURE_CLAMP_ADDRESSMODE']=0x0,_0x5f2491['TEXTURE_WRAP_ADDRESSMODE']=0x1,_0x5f2491['TEXTURE_MIRROR_ADDRESSMODE']=0x2,_0x5f2491['TEXTUREFORMAT_ALPHA']=0x0,_0x5f2491['TEXTUREFORMAT_LUMINANCE']=0x1,_0x5f2491['TEXTUREFORMAT_LUMINANCE_ALPHA']=0x2,_0x5f2491['TEXTUREFORMAT_RGB']=0x4,_0x5f2491['TEXTUREFORMAT_RGBA']=0x5,_0x5f2491['TEXTUREFORMAT_RED']=0x6,_0x5f2491['TEXTUREFORMAT_R']=0x6,_0x5f2491['TEXTUREFORMAT_RG']=0x7,_0x5f2491['TEXTUREFORMAT_RED_INTEGER']=0x8,_0x5f2491['TEXTUREFORMAT_R_INTEGER']=0x8,_0x5f2491['TEXTUREFORMAT_RG_INTEGER']=0x9,_0x5f2491['TEXTUREFORMAT_RGB_INTEGER']=0xa,_0x5f2491['TEXTUREFORMAT_RGBA_INTEGER']=0xb,_0x5f2491['TEXTURETYPE_UNSIGNED_BYTE']=0x0,_0x5f2491['TEXTURETYPE_UNSIGNED_INT']=0x0,_0x5f2491['TEXTURETYPE_FLOAT']=0x1,_0x5f2491['TEXTURETYPE_HALF_FLOAT']=0x2,_0x5f2491['TEXTURETYPE_BYTE']=0x3,_0x5f2491['TEXTURETYPE_SHORT']=0x4,_0x5f2491['TEXTURETYPE_UNSIGNED_SHORT']=0x5,_0x5f2491['TEXTURETYPE_INT']=0x6,_0x5f2491['TEXTURETYPE_UNSIGNED_INTEGER']=0x7,_0x5f2491['TEXTURETYPE_UNSIGNED_SHORT_4_4_4_4']=0x8,_0x5f2491['TEXTURETYPE_UNSIGNED_SHORT_5_5_5_1']=0x9,_0x5f2491['TEXTURETYPE_UNSIGNED_SHORT_5_6_5']=0xa,_0x5f2491['TEXTURETYPE_UNSIGNED_INT_2_10_10_10_REV']=0xb,_0x5f2491['TEXTURETYPE_UNSIGNED_INT_24_8']=0xc,_0x5f2491['TEXTURETYPE_UNSIGNED_INT_10F_11F_11F_REV']=0xd,_0x5f2491['TEXTURETYPE_UNSIGNED_INT_5_9_9_9_REV']=0xe,_0x5f2491['TEXTURETYPE_FLOAT_32_UNSIGNED_INT_24_8_REV']=0xf,_0x5f2491['TEXTURE_NEAREST_SAMPLINGMODE']=0x1,_0x5f2491['TEXTURE_NEAREST_NEAREST']=0x1,_0x5f2491['TEXTURE_BILINEAR_SAMPLINGMODE']=0x2,_0x5f2491['TEXTURE_LINEAR_LINEAR']=0x2,_0x5f2491['TEXTURE_TRILINEAR_SAMPLINGMODE']=0x3,_0x5f2491['TEXTURE_LINEAR_LINEAR_MIPLINEAR']=0x3,_0x5f2491['TEXTURE_NEAREST_NEAREST_MIPNEAREST']=0x4,_0x5f2491['TEXTURE_NEAREST_LINEAR_MIPNEAREST']=0x5,_0x5f2491['TEXTURE_NEAREST_LINEAR_MIPLINEAR']=0x6,_0x5f2491['TEXTURE_NEAREST_LINEAR']=0x7,_0x5f2491['TEXTURE_NEAREST_NEAREST_MIPLINEAR']=0x8,_0x5f2491['TEXTURE_LINEAR_NEAREST_MIPNEAREST']=0x9,_0x5f2491['TEXTURE_LINEAR_NEAREST_MIPLINEAR']=0xa,_0x5f2491['TEXTURE_LINEAR_LINEAR_MIPNEAREST']=0xb,_0x5f2491['TEXTURE_LINEAR_NEAREST']=0xc,_0x5f2491['TEXTURE_EXPLICIT_MODE']=0x0,_0x5f2491['TEXTURE_SPHERICAL_MODE']=0x1,_0x5f2491['TEXTURE_PLANAR_MODE']=0x2,_0x5f2491['TEXTURE_CUBIC_MODE']=0x3,_0x5f2491['TEXTURE_PROJECTION_MODE']=0x4,_0x5f2491['TEXTURE_SKYBOX_MODE']=0x5,_0x5f2491['TEXTURE_INVCUBIC_MODE']=0x6,_0x5f2491['TEXTURE_EQUIRECTANGULAR_MODE']=0x7,_0x5f2491['TEXTURE_FIXED_EQUIRECTANGULAR_MODE']=0x8,_0x5f2491['TEXTURE_FIXED_EQUIRECTANGULAR_MIRRORED_MODE']=0x9,_0x5f2491['TEXTURE_FILTERING_QUALITY_OFFLINE']=0x1000,_0x5f2491['TEXTURE_FILTERING_QUALITY_HIGH']=0x40,_0x5f2491['TEXTURE_FILTERING_QUALITY_MEDIUM']=0x10,_0x5f2491['TEXTURE_FILTERING_QUALITY_LOW']=0x8,_0x5f2491['SCALEMODE_FLOOR']=0x1,_0x5f2491['SCALEMODE_NEAREST']=0x2,_0x5f2491['SCALEMODE_CEILING']=0x3,_0x5f2491['MATERIAL_TextureDirtyFlag']=0x1,_0x5f2491['MATERIAL_LightDirtyFlag']=0x2,_0x5f2491['MATERIAL_FresnelDirtyFlag']=0x4,_0x5f2491['MATERIAL_AttributesDirtyFlag']=0x8,_0x5f2491['MATERIAL_MiscDirtyFlag']=0x10,_0x5f2491['MATERIAL_PrePassDirtyFlag']=0x20,_0x5f2491['MATERIAL_AllDirtyFlag']=0x3f,_0x5f2491['MATERIAL_TriangleFillMode']=0x0,_0x5f2491['MATERIAL_WireFrameFillMode']=0x1,_0x5f2491['MATERIAL_PointFillMode']=0x2,_0x5f2491['MATERIAL_PointListDrawMode']=0x3,_0x5f2491['MATERIAL_LineListDrawMode']=0x4,_0x5f2491['MATERIAL_LineLoopDrawMode']=0x5,_0x5f2491['MATERIAL_LineStripDrawMode']=0x6,_0x5f2491['MATERIAL_TriangleStripDrawMode']=0x7,_0x5f2491['MATERIAL_TriangleFanDrawMode']=0x8,_0x5f2491['MATERIAL_ClockWiseSideOrientation']=0x0,_0x5f2491['MATERIAL_CounterClockWiseSideOrientation']=0x1,_0x5f2491['ACTION_NothingTrigger']=0x0,_0x5f2491['ACTION_OnPickTrigger']=0x1,_0x5f2491['ACTION_OnLeftPickTrigger']=0x2,_0x5f2491['ACTION_OnRightPickTrigger']=0x3,_0x5f2491['ACTION_OnCenterPickTrigger']=0x4,_0x5f2491['ACTION_OnPickDownTrigger']=0x5,_0x5f2491['ACTION_OnDoublePickTrigger']=0x6,_0x5f2491['ACTION_OnPickUpTrigger']=0x7,_0x5f2491['ACTION_OnPickOutTrigger']=0x10,_0x5f2491['ACTION_OnLongPressTrigger']=0x8,_0x5f2491['ACTION_OnPointerOverTrigger']=0x9,_0x5f2491['ACTION_OnPointerOutTrigger']=0xa,_0x5f2491['ACTION_OnEveryFrameTrigger']=0xb,_0x5f2491['ACTION_OnIntersectionEnterTrigger']=0xc,_0x5f2491['ACTION_OnIntersectionExitTrigger']=0xd,_0x5f2491['ACTION_OnKeyDownTrigger']=0xe,_0x5f2491['ACTION_OnKeyUpTrigger']=0xf,_0x5f2491['PARTICLES_BILLBOARDMODE_Y']=0x2,_0x5f2491['PARTICLES_BILLBOARDMODE_ALL']=0x7,_0x5f2491['PARTICLES_BILLBOARDMODE_STRETCHED']=0x8,_0x5f2491['MESHES_CULLINGSTRATEGY_STANDARD']=0x0,_0x5f2491['MESHES_CULLINGSTRATEGY_BOUNDINGSPHERE_ONLY']=0x1,_0x5f2491['MESHES_CULLINGSTRATEGY_OPTIMISTIC_INCLUSION']=0x2,_0x5f2491['MESHES_CULLINGSTRATEGY_OPTIMISTIC_INCLUSION_THEN_BSPHERE_ONLY']=0x3,_0x5f2491['SCENELOADER_NO_LOGGING']=0x0,_0x5f2491['SCENELOADER_MINIMAL_LOGGING']=0x1,_0x5f2491['SCENELOADER_SUMMARY_LOGGING']=0x2,_0x5f2491['SCENELOADER_DETAILED_LOGGING']=0x3,_0x5f2491['PREPASS_IRRADIANCE_TEXTURE_TYPE']=0x0,_0x5f2491['PREPASS_POSITION_TEXTURE_TYPE']=0x1,_0x5f2491['PREPASS_VELOCITY_TEXTURE_TYPE']=0x2,_0x5f2491['PREPASS_REFLECTIVITY_TEXTURE_TYPE']=0x3,_0x5f2491['PREPASS_COLOR_TEXTURE_TYPE']=0x4,_0x5f2491['PREPASS_DEPTHNORMAL_TEXTURE_TYPE']=0x5,_0x5f2491['PREPASS_ALBEDO_TEXTURE_TYPE']=0x6,_0x5f2491;}());},function(_0x88b44b,_0x4d2c9d,_0x5afd4d){'use strict';_0x5afd4d['d'](_0x4d2c9d,'b',function(){return _0x2e68a8;}),_0x5afd4d['d'](_0x4d2c9d,'c',function(){return _0x2bb137;}),_0x5afd4d['d'](_0x4d2c9d,'m',function(){return _0x5d1807;}),_0x5afd4d['d'](_0x4d2c9d,'e',function(){return _0xfb3981;}),_0x5afd4d['d'](_0x4d2c9d,'h',function(){return _0x5f44fa;}),_0x5afd4d['d'](_0x4d2c9d,'n',function(){return _0x249320;}),_0x5afd4d['d'](_0x4d2c9d,'o',function(){return _0x344192;}),_0x5afd4d['d'](_0x4d2c9d,'k',function(){return _0x549e62;}),_0x5afd4d['d'](_0x4d2c9d,'g',function(){return _0x237c55;}),_0x5afd4d['d'](_0x4d2c9d,'f',function(){return _0xef11e6;}),_0x5afd4d['d'](_0x4d2c9d,'i',function(){return _0xb0456;}),_0x5afd4d['d'](_0x4d2c9d,'l',function(){return _0x104237;}),_0x5afd4d['d'](_0x4d2c9d,'j',function(){return _0x569138;}),_0x5afd4d['d'](_0x4d2c9d,'d',function(){return _0x262cbd;}),_0x5afd4d['d'](_0x4d2c9d,'a',function(){return _0x78b3d9;});var _0x4c307c=_0x5afd4d(0x25),_0x476055=_0x5afd4d(0x0),_0x3fbca7=_0x5afd4d(0x15),_0x46d07d=_0x5afd4d(0x9),_0x449816={},_0x51e1e4={},_0x3cbf78=function(_0x131ca2,_0x66ffa0,_0x18bfcd){var _0x1f5994=_0x131ca2();_0x4c307c['a']&&_0x4c307c['a']['AddTagsTo'](_0x1f5994,_0x66ffa0['tags']);var _0x213e58=_0x464e1e(_0x1f5994);for(var _0x203312 in _0x213e58){var _0x21ddb4=_0x213e58[_0x203312],_0x48bc49=_0x66ffa0[_0x203312],_0x3c4347=_0x21ddb4['type'];if(null!=_0x48bc49&&'uniqueId'!==_0x203312)switch(_0x3c4347){case 0x0:case 0x6:case 0xb:_0x1f5994[_0x203312]=_0x48bc49;break;case 0x1:_0x1f5994[_0x203312]=_0x18bfcd||_0x48bc49['isRenderTarget']?_0x48bc49:_0x48bc49['clone']();break;case 0x2:case 0x3:case 0x4:case 0x5:case 0x7:case 0xa:case 0xc:_0x1f5994[_0x203312]=_0x18bfcd?_0x48bc49:_0x48bc49['clone']();}}return _0x1f5994;};function _0x464e1e(_0x5c87d2){var _0x56ffe8=_0x5c87d2['getClassName']();if(_0x51e1e4[_0x56ffe8])return _0x51e1e4[_0x56ffe8];_0x51e1e4[_0x56ffe8]={};for(var _0x28a2ab=_0x51e1e4[_0x56ffe8],_0x21896b=_0x5c87d2,_0x33aade=_0x56ffe8;_0x33aade;){var _0xb41712=_0x449816[_0x33aade];for(var _0x268720 in _0xb41712)_0x28a2ab[_0x268720]=_0xb41712[_0x268720];var _0x14be75=void 0x0,_0x3ece9f=!0x1;do{if(!(_0x14be75=Object['getPrototypeOf'](_0x21896b))['getClassName']){_0x3ece9f=!0x0;break;}if(_0x14be75['getClassName']()!==_0x33aade)break;_0x21896b=_0x14be75;}while(_0x14be75);if(_0x3ece9f)break;_0x33aade=_0x14be75['getClassName'](),_0x21896b=_0x14be75;}return _0x28a2ab;}function _0x4455a1(_0x18564d,_0x5b753d){return function(_0x2df2b3,_0xc63fa7){var _0x388d0=function(_0x57bdd8){var _0x135cfb=_0x57bdd8['getClassName']();return _0x449816[_0x135cfb]||(_0x449816[_0x135cfb]={}),_0x449816[_0x135cfb];}(_0x2df2b3);_0x388d0[_0xc63fa7]||(_0x388d0[_0xc63fa7]={'type':_0x18564d,'sourceName':_0x5b753d});};}function _0x2e68a8(_0x105d55,_0x390be1){return void 0x0===_0x390be1&&(_0x390be1=null),function(_0x3c6d89,_0x5b2efd){return void 0x0===_0x5b2efd&&(_0x5b2efd=null),function(_0x1fef7a,_0x119298){var _0x4ff097=_0x5b2efd||'_'+_0x119298;Object['defineProperty'](_0x1fef7a,_0x119298,{'get':function(){return this[_0x4ff097];},'set':function(_0x576fa8){this[_0x4ff097]!==_0x576fa8&&(this[_0x4ff097]=_0x576fa8,_0x1fef7a[_0x3c6d89]['apply'](this));},'enumerable':!0x0,'configurable':!0x0});};}(_0x105d55,_0x390be1);}function _0x2bb137(_0x4d122c){return _0x4455a1(0x0,_0x4d122c);}function _0x5d1807(_0x178d78){return _0x4455a1(0x1,_0x178d78);}function _0xfb3981(_0x3bb746){return _0x4455a1(0x2,_0x3bb746);}function _0x5f44fa(_0x56b43a){return _0x4455a1(0x3,_0x56b43a);}function _0x249320(_0x4a35e3){return _0x4455a1(0x4,_0x4a35e3);}function _0x344192(_0x21301d){return _0x4455a1(0x5,_0x21301d);}function _0x549e62(_0x3318d6){return _0x4455a1(0x6,_0x3318d6);}function _0x237c55(_0x3088ee){return _0x4455a1(0x7,_0x3088ee);}function _0xef11e6(_0x34d596){return _0x4455a1(0x8,_0x34d596);}function _0xb0456(_0x3051ed){return _0x4455a1(0x9,_0x3051ed);}function _0x104237(_0x5736b7){return _0x4455a1(0xa,_0x5736b7);}function _0x569138(_0x265bae){return _0x4455a1(0xc,_0x265bae);}function _0x262cbd(_0x378de7){return _0x4455a1(0xb,_0x378de7);}var _0x78b3d9=(function(){function _0x3dff94(){}return _0x3dff94['AppendSerializedAnimations']=function(_0x5b5d3a,_0x5b3e3d){if(_0x5b5d3a['animations']){_0x5b3e3d['animations']=[];for(var _0x2a5466=0x0;_0x2a5466<_0x5b5d3a['animations']['length'];_0x2a5466++){var _0xa2b185=_0x5b5d3a['animations'][_0x2a5466];_0x5b3e3d['animations']['push'](_0xa2b185['serialize']());}}},_0x3dff94['Serialize']=function(_0x473885,_0x4294ef){_0x4294ef||(_0x4294ef={}),_0x4c307c['a']&&(_0x4294ef['tags']=_0x4c307c['a']['GetTags'](_0x473885));var _0x577b9f=_0x464e1e(_0x473885);for(var _0x476972 in _0x577b9f){var _0x2dc43d=_0x577b9f[_0x476972],_0x46642c=_0x2dc43d['sourceName']||_0x476972,_0x58d280=_0x2dc43d['type'],_0x198784=_0x473885[_0x476972];if(null!=_0x198784&&'uniqueId'!==_0x476972)switch(_0x58d280){case 0x0:_0x4294ef[_0x46642c]=_0x198784;break;case 0x1:_0x4294ef[_0x46642c]=_0x198784['serialize']();break;case 0x2:_0x4294ef[_0x46642c]=_0x198784['asArray']();break;case 0x3:_0x4294ef[_0x46642c]=_0x198784['serialize']();break;case 0x4:case 0x5:_0x4294ef[_0x46642c]=_0x198784['asArray']();break;case 0x6:_0x4294ef[_0x46642c]=_0x198784['id'];break;case 0x7:_0x4294ef[_0x46642c]=_0x198784['serialize']();break;case 0x8:_0x4294ef[_0x46642c]=_0x198784['asArray']();break;case 0x9:_0x4294ef[_0x46642c]=_0x198784['serialize']();break;case 0xa:_0x4294ef[_0x46642c]=_0x198784['asArray']();break;case 0xb:_0x4294ef[_0x46642c]=_0x198784['id'];case 0xc:_0x4294ef[_0x46642c]=_0x198784['asArray']();}}return _0x4294ef;},_0x3dff94['Parse']=function(_0x4b8f6d,_0x1fe0c5,_0x443d11,_0x31fab5){void 0x0===_0x31fab5&&(_0x31fab5=null);var _0x2f76a2=_0x4b8f6d();_0x31fab5||(_0x31fab5=''),_0x4c307c['a']&&_0x4c307c['a']['AddTagsTo'](_0x2f76a2,_0x1fe0c5['tags']);var _0x176d94=_0x464e1e(_0x2f76a2);for(var _0x17bbaa in _0x176d94){var _0x521bec=_0x176d94[_0x17bbaa],_0x4be71c=_0x1fe0c5[_0x521bec['sourceName']||_0x17bbaa],_0x3ea4dd=_0x521bec['type'];if(null!=_0x4be71c&&'uniqueId'!==_0x17bbaa){var _0xeb40f1=_0x2f76a2;switch(_0x3ea4dd){case 0x0:_0xeb40f1[_0x17bbaa]=_0x4be71c;break;case 0x1:_0x443d11&&(_0xeb40f1[_0x17bbaa]=_0x3dff94['_TextureParser'](_0x4be71c,_0x443d11,_0x31fab5));break;case 0x2:_0xeb40f1[_0x17bbaa]=_0x46d07d['a']['FromArray'](_0x4be71c);break;case 0x3:_0xeb40f1[_0x17bbaa]=_0x3dff94['_FresnelParametersParser'](_0x4be71c);break;case 0x4:_0xeb40f1[_0x17bbaa]=_0x476055['d']['FromArray'](_0x4be71c);break;case 0x5:_0xeb40f1[_0x17bbaa]=_0x476055['e']['FromArray'](_0x4be71c);break;case 0x6:_0x443d11&&(_0xeb40f1[_0x17bbaa]=_0x443d11['getLastMeshByID'](_0x4be71c));break;case 0x7:_0xeb40f1[_0x17bbaa]=_0x3dff94['_ColorCurvesParser'](_0x4be71c);break;case 0x8:_0xeb40f1[_0x17bbaa]=_0x46d07d['b']['FromArray'](_0x4be71c);break;case 0x9:_0xeb40f1[_0x17bbaa]=_0x3dff94['_ImageProcessingConfigurationParser'](_0x4be71c);break;case 0xa:_0xeb40f1[_0x17bbaa]=_0x476055['b']['FromArray'](_0x4be71c);break;case 0xb:_0x443d11&&(_0xeb40f1[_0x17bbaa]=_0x443d11['getCameraByID'](_0x4be71c));case 0xc:_0xeb40f1[_0x17bbaa]=_0x476055['a']['FromArray'](_0x4be71c);}}}return _0x2f76a2;},_0x3dff94['Clone']=function(_0xfb084f,_0x4c4365){return _0x3cbf78(_0xfb084f,_0x4c4365,!0x1);},_0x3dff94['Instanciate']=function(_0x6aafd7,_0x5e2d81){return _0x3cbf78(_0x6aafd7,_0x5e2d81,!0x0);},_0x3dff94['_ImageProcessingConfigurationParser']=function(_0x44e41c){throw _0x3fbca7['a']['WarnImport']('ImageProcessingConfiguration');},_0x3dff94['_FresnelParametersParser']=function(_0x1068d4){throw _0x3fbca7['a']['WarnImport']('FresnelParameters');},_0x3dff94['_ColorCurvesParser']=function(_0x16bd10){throw _0x3fbca7['a']['WarnImport']('ColorCurves');},_0x3dff94['_TextureParser']=function(_0x359251,_0x29d194,_0x217c8a){throw _0x3fbca7['a']['WarnImport']('Texture');},_0x3dff94;}());},function(_0x2b3d49,_0x433b64,_0x2a96d0){'use strict';_0x2a96d0['d'](_0x433b64,'a',function(){return _0x14bfe4;}),_0x2a96d0['d'](_0x433b64,'b',function(){return _0x253e44;});var _0x14bfe4=(function(){function _0x4924aa(_0x4a4fc6,_0x502133,_0x1bfcf0,_0x1693d2,_0x3126bf,_0x43e03c,_0x1ab33c,_0x150fbd){void 0x0===_0x1693d2&&(_0x1693d2=0x0),void 0x0===_0x3126bf&&(_0x3126bf=!0x1),void 0x0===_0x43e03c&&(_0x43e03c=!0x1),void 0x0===_0x1ab33c&&(_0x1ab33c=!0x1),this['_isAlreadyOwned']=!0x1,_0x4a4fc6['getScene']?this['_engine']=_0x4a4fc6['getScene']()['getEngine']():this['_engine']=_0x4a4fc6,this['_updatable']=_0x1bfcf0,this['_instanced']=_0x43e03c,this['_divisor']=_0x150fbd||0x1,this['_data']=_0x502133,this['byteStride']=_0x1ab33c?_0x1693d2:_0x1693d2*Float32Array['BYTES_PER_ELEMENT'],_0x3126bf||this['create']();}return _0x4924aa['prototype']['createVertexBuffer']=function(_0x1e8dd1,_0x11cc7e,_0x10da25,_0x1b77a0,_0x33bdd3,_0x4c38b1,_0x8b6b03){void 0x0===_0x4c38b1&&(_0x4c38b1=!0x1);var _0x2f87c1=_0x4c38b1?_0x11cc7e:_0x11cc7e*Float32Array['BYTES_PER_ELEMENT'],_0x1ba5c2=_0x1b77a0?_0x4c38b1?_0x1b77a0:_0x1b77a0*Float32Array['BYTES_PER_ELEMENT']:this['byteStride'];return new _0x253e44(this['_engine'],this,_0x1e8dd1,this['_updatable'],!0x0,_0x1ba5c2,void 0x0===_0x33bdd3?this['_instanced']:_0x33bdd3,_0x2f87c1,_0x10da25,void 0x0,void 0x0,!0x0,this['_divisor']||_0x8b6b03);},_0x4924aa['prototype']['isUpdatable']=function(){return this['_updatable'];},_0x4924aa['prototype']['getData']=function(){return this['_data'];},_0x4924aa['prototype']['getBuffer']=function(){return this['_buffer'];},_0x4924aa['prototype']['getStrideSize']=function(){return this['byteStride']/Float32Array['BYTES_PER_ELEMENT'];},_0x4924aa['prototype']['create']=function(_0x2c3c2a){void 0x0===_0x2c3c2a&&(_0x2c3c2a=null),!_0x2c3c2a&&this['_buffer']||(_0x2c3c2a=_0x2c3c2a||this['_data'])&&(this['_buffer']?this['_updatable']&&(this['_engine']['updateDynamicVertexBuffer'](this['_buffer'],_0x2c3c2a),this['_data']=_0x2c3c2a):this['_updatable']?(this['_buffer']=this['_engine']['createDynamicVertexBuffer'](_0x2c3c2a),this['_data']=_0x2c3c2a):this['_buffer']=this['_engine']['createVertexBuffer'](_0x2c3c2a));},_0x4924aa['prototype']['_rebuild']=function(){this['_buffer']=null,this['create'](this['_data']);},_0x4924aa['prototype']['update']=function(_0x360bbe){this['create'](_0x360bbe);},_0x4924aa['prototype']['updateDirectly']=function(_0x59aa48,_0x106e69,_0x2554bb,_0x556fef){void 0x0===_0x556fef&&(_0x556fef=!0x1),this['_buffer']&&this['_updatable']&&(this['_engine']['updateDynamicVertexBuffer'](this['_buffer'],_0x59aa48,_0x556fef?_0x106e69:_0x106e69*Float32Array['BYTES_PER_ELEMENT'],_0x2554bb?_0x2554bb*this['byteStride']:void 0x0),this['_data']=null);},_0x4924aa['prototype']['_increaseReferences']=function(){this['_buffer']&&(this['_isAlreadyOwned']?this['_buffer']['references']++:this['_isAlreadyOwned']=!0x0);},_0x4924aa['prototype']['dispose']=function(){this['_buffer']&&this['_engine']['_releaseBuffer'](this['_buffer'])&&(this['_buffer']=null);},_0x4924aa;}()),_0x253e44=(function(){function _0x2dfc17(_0x1824ea,_0x45cea1,_0x73f76c,_0xe8b322,_0x3fe62e,_0x43a105,_0x2c2c35,_0x1d07c0,_0x1a8629,_0x33351d,_0x14c2d6,_0x28c025,_0x47f3b6,_0x32d135){if(void 0x0===_0x14c2d6&&(_0x14c2d6=!0x1),void 0x0===_0x28c025&&(_0x28c025=!0x1),void 0x0===_0x47f3b6&&(_0x47f3b6=0x1),void 0x0===_0x32d135&&(_0x32d135=!0x1),_0x45cea1 instanceof _0x14bfe4?(this['_buffer']=_0x45cea1,this['_ownsBuffer']=_0x32d135,_0x32d135&&this['_buffer']['_increaseReferences']()):(this['_buffer']=new _0x14bfe4(_0x1824ea,_0x45cea1,_0xe8b322,_0x43a105,_0x3fe62e,_0x2c2c35,_0x28c025),this['_ownsBuffer']=!0x0),this['_kind']=_0x73f76c,null==_0x33351d){var _0x3b7f93=this['getData']();this['type']=_0x2dfc17['FLOAT'],_0x3b7f93 instanceof Int8Array?this['type']=_0x2dfc17['BYTE']:_0x3b7f93 instanceof Uint8Array?this['type']=_0x2dfc17['UNSIGNED_BYTE']:_0x3b7f93 instanceof Int16Array?this['type']=_0x2dfc17['SHORT']:_0x3b7f93 instanceof Uint16Array?this['type']=_0x2dfc17['UNSIGNED_SHORT']:_0x3b7f93 instanceof Int32Array?this['type']=_0x2dfc17['INT']:_0x3b7f93 instanceof Uint32Array&&(this['type']=_0x2dfc17['UNSIGNED_INT']);}else this['type']=_0x33351d;var _0x5d131e=_0x2dfc17['GetTypeByteLength'](this['type']);_0x28c025?(this['_size']=_0x1a8629||(_0x43a105?_0x43a105/_0x5d131e:_0x2dfc17['DeduceStride'](_0x73f76c)),this['byteStride']=_0x43a105||this['_buffer']['byteStride']||this['_size']*_0x5d131e,this['byteOffset']=_0x1d07c0||0x0):(this['_size']=_0x1a8629||_0x43a105||_0x2dfc17['DeduceStride'](_0x73f76c),this['byteStride']=_0x43a105?_0x43a105*_0x5d131e:this['_buffer']['byteStride']||this['_size']*_0x5d131e,this['byteOffset']=(_0x1d07c0||0x0)*_0x5d131e),this['normalized']=_0x14c2d6,this['_instanced']=void 0x0!==_0x2c2c35&&_0x2c2c35,this['_instanceDivisor']=_0x2c2c35?_0x47f3b6:0x0;}return Object['defineProperty'](_0x2dfc17['prototype'],'instanceDivisor',{'get':function(){return this['_instanceDivisor'];},'set':function(_0x402b85){this['_instanceDivisor']=_0x402b85,this['_instanced']=0x0!=_0x402b85;},'enumerable':!0x1,'configurable':!0x0}),_0x2dfc17['prototype']['_rebuild']=function(){this['_buffer']&&this['_buffer']['_rebuild']();},_0x2dfc17['prototype']['getKind']=function(){return this['_kind'];},_0x2dfc17['prototype']['isUpdatable']=function(){return this['_buffer']['isUpdatable']();},_0x2dfc17['prototype']['getData']=function(){return this['_buffer']['getData']();},_0x2dfc17['prototype']['getBuffer']=function(){return this['_buffer']['getBuffer']();},_0x2dfc17['prototype']['getStrideSize']=function(){return this['byteStride']/_0x2dfc17['GetTypeByteLength'](this['type']);},_0x2dfc17['prototype']['getOffset']=function(){return this['byteOffset']/_0x2dfc17['GetTypeByteLength'](this['type']);},_0x2dfc17['prototype']['getSize']=function(){return this['_size'];},_0x2dfc17['prototype']['getIsInstanced']=function(){return this['_instanced'];},_0x2dfc17['prototype']['getInstanceDivisor']=function(){return this['_instanceDivisor'];},_0x2dfc17['prototype']['create']=function(_0x20b79e){this['_buffer']['create'](_0x20b79e);},_0x2dfc17['prototype']['update']=function(_0x1ac6d5){this['_buffer']['update'](_0x1ac6d5);},_0x2dfc17['prototype']['updateDirectly']=function(_0x161874,_0x261d27,_0x4b2d72){void 0x0===_0x4b2d72&&(_0x4b2d72=!0x1),this['_buffer']['updateDirectly'](_0x161874,_0x261d27,void 0x0,_0x4b2d72);},_0x2dfc17['prototype']['dispose']=function(){this['_ownsBuffer']&&this['_buffer']['dispose']();},_0x2dfc17['prototype']['forEach']=function(_0x579c3d,_0x1daba1){_0x2dfc17['ForEach'](this['_buffer']['getData'](),this['byteOffset'],this['byteStride'],this['_size'],this['type'],_0x579c3d,this['normalized'],_0x1daba1);},_0x2dfc17['DeduceStride']=function(_0x5120ce){switch(_0x5120ce){case _0x2dfc17['UVKind']:case _0x2dfc17['UV2Kind']:case _0x2dfc17['UV3Kind']:case _0x2dfc17['UV4Kind']:case _0x2dfc17['UV5Kind']:case _0x2dfc17['UV6Kind']:return 0x2;case _0x2dfc17['NormalKind']:case _0x2dfc17['PositionKind']:return 0x3;case _0x2dfc17['ColorKind']:case _0x2dfc17['MatricesIndicesKind']:case _0x2dfc17['MatricesIndicesExtraKind']:case _0x2dfc17['MatricesWeightsKind']:case _0x2dfc17['MatricesWeightsExtraKind']:case _0x2dfc17['TangentKind']:return 0x4;default:throw new Error('Invalid\x20kind\x20\x27'+_0x5120ce+'\x27');}},_0x2dfc17['GetTypeByteLength']=function(_0x268b82){switch(_0x268b82){case _0x2dfc17['BYTE']:case _0x2dfc17['UNSIGNED_BYTE']:return 0x1;case _0x2dfc17['SHORT']:case _0x2dfc17['UNSIGNED_SHORT']:return 0x2;case _0x2dfc17['INT']:case _0x2dfc17['UNSIGNED_INT']:case _0x2dfc17['FLOAT']:return 0x4;default:throw new Error('Invalid\x20type\x20\x27'+_0x268b82+'\x27');}},_0x2dfc17['ForEach']=function(_0x4bdda4,_0x2648f6,_0x117cbe,_0x3dd1ae,_0x139fdb,_0xd470f9,_0x474caa,_0x5aad16){if(_0x4bdda4 instanceof Array)for(var _0x49164e=_0x2648f6/0x4,_0x121523=_0x117cbe/0x4,_0x26e3f8=0x0;_0x26e3f8<_0xd470f9;_0x26e3f8+=_0x3dd1ae){for(var _0x405beb=0x0;_0x405beb<_0x3dd1ae;_0x405beb++)_0x5aad16(_0x4bdda4[_0x49164e+_0x405beb],_0x26e3f8+_0x405beb);_0x49164e+=_0x121523;}else{var _0xc941e7=_0x4bdda4 instanceof ArrayBuffer?new DataView(_0x4bdda4):new DataView(_0x4bdda4['buffer'],_0x4bdda4['byteOffset'],_0x4bdda4['byteLength']),_0x305178=_0x2dfc17['GetTypeByteLength'](_0x139fdb);for(_0x26e3f8=0x0;_0x26e3f8<_0xd470f9;_0x26e3f8+=_0x3dd1ae){var _0x4bf426=_0x2648f6;for(_0x405beb=0x0;_0x405beb<_0x3dd1ae;_0x405beb++){_0x5aad16(_0x2dfc17['_GetFloatValue'](_0xc941e7,_0x139fdb,_0x4bf426,_0x474caa),_0x26e3f8+_0x405beb),_0x4bf426+=_0x305178;}_0x2648f6+=_0x117cbe;}}},_0x2dfc17['_GetFloatValue']=function(_0x58cff1,_0x52e640,_0x2baeef,_0x1dc130){switch(_0x52e640){case _0x2dfc17['BYTE']:var _0x14b7f7=_0x58cff1['getInt8'](_0x2baeef);return _0x1dc130&&(_0x14b7f7=Math['max'](_0x14b7f7/0x7f,-0x1)),_0x14b7f7;case _0x2dfc17['UNSIGNED_BYTE']:_0x14b7f7=_0x58cff1['getUint8'](_0x2baeef);return _0x1dc130&&(_0x14b7f7/=0xff),_0x14b7f7;case _0x2dfc17['SHORT']:_0x14b7f7=_0x58cff1['getInt16'](_0x2baeef,!0x0);return _0x1dc130&&(_0x14b7f7=Math['max'](_0x14b7f7/0x7fff,-0x1)),_0x14b7f7;case _0x2dfc17['UNSIGNED_SHORT']:_0x14b7f7=_0x58cff1['getUint16'](_0x2baeef,!0x0);return _0x1dc130&&(_0x14b7f7/=0xffff),_0x14b7f7;case _0x2dfc17['INT']:return _0x58cff1['getInt32'](_0x2baeef,!0x0);case _0x2dfc17['UNSIGNED_INT']:return _0x58cff1['getUint32'](_0x2baeef,!0x0);case _0x2dfc17['FLOAT']:return _0x58cff1['getFloat32'](_0x2baeef,!0x0);default:throw new Error('Invalid\x20component\x20type\x20'+_0x52e640);}},_0x2dfc17['BYTE']=0x1400,_0x2dfc17['UNSIGNED_BYTE']=0x1401,_0x2dfc17['SHORT']=0x1402,_0x2dfc17['UNSIGNED_SHORT']=0x1403,_0x2dfc17['INT']=0x1404,_0x2dfc17['UNSIGNED_INT']=0x1405,_0x2dfc17['FLOAT']=0x1406,_0x2dfc17['PositionKind']='position',_0x2dfc17['NormalKind']='normal',_0x2dfc17['TangentKind']='tangent',_0x2dfc17['UVKind']='uv',_0x2dfc17['UV2Kind']='uv2',_0x2dfc17['UV3Kind']='uv3',_0x2dfc17['UV4Kind']='uv4',_0x2dfc17['UV5Kind']='uv5',_0x2dfc17['UV6Kind']='uv6',_0x2dfc17['ColorKind']='color',_0x2dfc17['MatricesIndicesKind']='matricesIndices',_0x2dfc17['MatricesWeightsKind']='matricesWeights',_0x2dfc17['MatricesIndicesExtraKind']='matricesIndicesExtra',_0x2dfc17['MatricesWeightsExtraKind']='matricesWeightsExtra',_0x2dfc17;}());},function(_0x4b556f,_0xdca84d,_0x1673be){'use strict';_0x1673be['d'](_0xdca84d,'a',function(){return _0x3da88b;});var _0x1a092c=_0x1673be(0x6),_0x1a9ab2=_0x1673be(0x2),_0xa2fee1=_0x1673be(0x26),_0x450eb8=_0x1673be(0x8),_0x3f1b8e=_0x1673be(0x80),_0x3da88b=(function(){function _0xf743de(_0x3f8d5a,_0x247fea,_0x18108e,_0x140787,_0x31175a,_0x423ffd,_0x71f139,_0x39a770,_0x343880,_0x29a02a){var _0xd318,_0x9b28d6=this;void 0x0===_0x140787&&(_0x140787=null),void 0x0===_0x423ffd&&(_0x423ffd=null),void 0x0===_0x71f139&&(_0x71f139=null),void 0x0===_0x39a770&&(_0x39a770=null),void 0x0===_0x343880&&(_0x343880=null),this['name']=null,this['defines']='',this['onCompiled']=null,this['onError']=null,this['onBind']=null,this['uniqueId']=0x0,this['onCompileObservable']=new _0x1a092c['c'](),this['onErrorObservable']=new _0x1a092c['c'](),this['_onBindObservable']=null,this['_wasPreviouslyReady']=!0x1,this['_bonesComputationForcedToCPU']=!0x1,this['_multiTarget']=!0x1,this['_uniformBuffersNames']={},this['_samplers']={},this['_isReady']=!0x1,this['_compilationError']='',this['_allFallbacksProcessed']=!0x1,this['_uniforms']={},this['_key']='',this['_fallbacks']=null,this['_vertexSourceCode']='',this['_fragmentSourceCode']='',this['_vertexSourceCodeOverride']='',this['_fragmentSourceCodeOverride']='',this['_transformFeedbackVaryings']=null,this['_rawVertexSourceCode']='',this['_rawFragmentSourceCode']='',this['_pipelineContext']=null,this['_valueCache']={},this['name']=_0x3f8d5a;var _0x378c06,_0x376f4c,_0x38de7c=null;if(_0x247fea['attributes']){var _0x497a59=_0x247fea;if(this['_engine']=_0x18108e,this['_attributesNames']=_0x497a59['attributes'],this['_uniformsNames']=_0x497a59['uniformsNames']['concat'](_0x497a59['samplers']),this['_samplerList']=_0x497a59['samplers']['slice'](),this['defines']=_0x497a59['defines'],this['onError']=_0x497a59['onError'],this['onCompiled']=_0x497a59['onCompiled'],this['_fallbacks']=_0x497a59['fallbacks'],this['_indexParameters']=_0x497a59['indexParameters'],this['_transformFeedbackVaryings']=_0x497a59['transformFeedbackVaryings']||null,this['_multiTarget']=!!_0x497a59['multiTarget'],_0x497a59['uniformBuffersNames']){this['_uniformBuffersNamesList']=_0x497a59['uniformBuffersNames']['slice']();for(var _0x319702=0x0;_0x319702<_0x497a59['uniformBuffersNames']['length'];_0x319702++)this['_uniformBuffersNames'][_0x497a59['uniformBuffersNames'][_0x319702]]=_0x319702;}_0x38de7c=null!==(_0xd318=_0x497a59['processFinalCode'])&&void 0x0!==_0xd318?_0xd318:null;}else this['_engine']=_0x31175a,this['defines']=null==_0x423ffd?'':_0x423ffd,this['_uniformsNames']=_0x18108e['concat'](_0x140787),this['_samplerList']=_0x140787?_0x140787['slice']():[],this['_attributesNames']=_0x247fea,this['_uniformBuffersNamesList']=[],this['onError']=_0x343880,this['onCompiled']=_0x39a770,this['_indexParameters']=_0x29a02a,this['_fallbacks']=_0x71f139;this['_attributeLocationByName']={},this['uniqueId']=_0xf743de['_uniqueIdSeed']++;var _0x540c78=_0xa2fee1['a']['IsWindowObjectExist']()?this['_engine']['getHostDocument']():null;_0x3f8d5a['vertexSource']?_0x378c06='source:'+_0x3f8d5a['vertexSource']:_0x3f8d5a['vertexElement']?(_0x378c06=_0x540c78?_0x540c78['getElementById'](_0x3f8d5a['vertexElement']):null)||(_0x378c06=_0x3f8d5a['vertexElement']):_0x378c06=_0x3f8d5a['vertex']||_0x3f8d5a,_0x3f8d5a['fragmentSource']?_0x376f4c='source:'+_0x3f8d5a['fragmentSource']:_0x3f8d5a['fragmentElement']?(_0x376f4c=_0x540c78?_0x540c78['getElementById'](_0x3f8d5a['fragmentElement']):null)||(_0x376f4c=_0x3f8d5a['fragmentElement']):_0x376f4c=_0x3f8d5a['fragment']||_0x3f8d5a;var _0x27dc11={'defines':this['defines']['split']('\x0a'),'indexParameters':this['_indexParameters'],'isFragment':!0x1,'shouldUseHighPrecisionShader':this['_engine']['_shouldUseHighPrecisionShader'],'processor':this['_engine']['_shaderProcessor'],'supportsUniformBuffers':this['_engine']['supportsUniformBuffers'],'shadersRepository':_0xf743de['ShadersRepository'],'includesShadersStore':_0xf743de['IncludesShadersStore'],'version':(0x64*this['_engine']['webGLVersion'])['toString'](),'platformName':this['_engine']['webGLVersion']>=0x2?'WEBGL2':'WEBGL1'};this['_loadShader'](_0x378c06,'Vertex','',function(_0x2cbc76){_0x9b28d6['_rawVertexSourceCode']=_0x2cbc76,_0x9b28d6['_loadShader'](_0x376f4c,'Fragment','Pixel',function(_0x546927){_0x9b28d6['_rawFragmentSourceCode']=_0x546927,_0x3f1b8e['a']['Process'](_0x2cbc76,_0x27dc11,function(_0x7b6de4){_0x38de7c&&(_0x7b6de4=_0x38de7c('vertex',_0x7b6de4)),_0x27dc11['isFragment']=!0x0,_0x3f1b8e['a']['Process'](_0x546927,_0x27dc11,function(_0x280750){_0x38de7c&&(_0x280750=_0x38de7c('fragment',_0x280750)),_0x9b28d6['_useFinalCode'](_0x7b6de4,_0x280750,_0x3f8d5a);},_0x9b28d6['_engine']);},_0x9b28d6['_engine']);});});}return Object['defineProperty'](_0xf743de['prototype'],'onBindObservable',{'get':function(){return this['_onBindObservable']||(this['_onBindObservable']=new _0x1a092c['c']()),this['_onBindObservable'];},'enumerable':!0x1,'configurable':!0x0}),_0xf743de['prototype']['_useFinalCode']=function(_0xb040fa,_0x21c870,_0x1b0f7a){if(_0x1b0f7a){var _0x42ab37=_0x1b0f7a['vertexElement']||_0x1b0f7a['vertex']||_0x1b0f7a['spectorName']||_0x1b0f7a,_0x2649af=_0x1b0f7a['fragmentElement']||_0x1b0f7a['fragment']||_0x1b0f7a['spectorName']||_0x1b0f7a;this['_vertexSourceCode']='#define\x20SHADER_NAME\x20vertex:'+_0x42ab37+'\x0a'+_0xb040fa,this['_fragmentSourceCode']='#define\x20SHADER_NAME\x20fragment:'+_0x2649af+'\x0a'+_0x21c870;}else this['_vertexSourceCode']=_0xb040fa,this['_fragmentSourceCode']=_0x21c870;this['_prepareEffect']();},Object['defineProperty'](_0xf743de['prototype'],'key',{'get':function(){return this['_key'];},'enumerable':!0x1,'configurable':!0x0}),_0xf743de['prototype']['isReady']=function(){try{return this['_isReadyInternal']();}catch(_0x4239bf){return!0x1;}},_0xf743de['prototype']['_isReadyInternal']=function(){return!!this['_isReady']||!!this['_pipelineContext']&&this['_pipelineContext']['isReady'];},_0xf743de['prototype']['getEngine']=function(){return this['_engine'];},_0xf743de['prototype']['getPipelineContext']=function(){return this['_pipelineContext'];},_0xf743de['prototype']['getAttributesNames']=function(){return this['_attributesNames'];},_0xf743de['prototype']['getAttributeLocation']=function(_0xf3a4a){return this['_attributes'][_0xf3a4a];},_0xf743de['prototype']['getAttributeLocationByName']=function(_0x149557){return this['_attributeLocationByName'][_0x149557];},_0xf743de['prototype']['getAttributesCount']=function(){return this['_attributes']['length'];},_0xf743de['prototype']['getUniformIndex']=function(_0x1716ad){return this['_uniformsNames']['indexOf'](_0x1716ad);},_0xf743de['prototype']['getUniform']=function(_0x48e9dc){return this['_uniforms'][_0x48e9dc];},_0xf743de['prototype']['getSamplers']=function(){return this['_samplerList'];},_0xf743de['prototype']['getUniformNames']=function(){return this['_uniformsNames'];},_0xf743de['prototype']['getUniformBuffersNames']=function(){return this['_uniformBuffersNamesList'];},_0xf743de['prototype']['getIndexParameters']=function(){return this['_indexParameters'];},_0xf743de['prototype']['getCompilationError']=function(){return this['_compilationError'];},_0xf743de['prototype']['allFallbacksProcessed']=function(){return this['_allFallbacksProcessed'];},_0xf743de['prototype']['executeWhenCompiled']=function(_0x382a0a){var _0x44c083=this;this['isReady']()?_0x382a0a(this):(this['onCompileObservable']['add'](function(_0x2017b4){_0x382a0a(_0x2017b4);}),this['_pipelineContext']&&!this['_pipelineContext']['isAsync']||setTimeout(function(){_0x44c083['_checkIsReady'](null);},0x10));},_0xf743de['prototype']['_checkIsReady']=function(_0x2d9d47){var _0x1b4f50=this;try{if(this['_isReadyInternal']())return;}catch(_0x21d910){return void this['_processCompilationErrors'](_0x21d910,_0x2d9d47);}setTimeout(function(){_0x1b4f50['_checkIsReady'](_0x2d9d47);},0x10);},_0xf743de['prototype']['_loadShader']=function(_0x577d9e,_0x265714,_0x414680,_0x235e79){var _0x391324;if('undefined'!=typeof HTMLElement&&_0x577d9e instanceof HTMLElement)return void _0x235e79(_0xa2fee1['a']['GetDOMTextContent'](_0x577d9e));'source:'!==_0x577d9e['substr'](0x0,0x7)?'base64:'!==_0x577d9e['substr'](0x0,0x7)?_0xf743de['ShadersStore'][_0x577d9e+_0x265714+'Shader']?_0x235e79(_0xf743de['ShadersStore'][_0x577d9e+_0x265714+'Shader']):_0x414680&&_0xf743de['ShadersStore'][_0x577d9e+_0x414680+'Shader']?_0x235e79(_0xf743de['ShadersStore'][_0x577d9e+_0x414680+'Shader']):(_0x391324='.'===_0x577d9e[0x0]||'/'===_0x577d9e[0x0]||_0x577d9e['indexOf']('http')>-0x1?_0x577d9e:_0xf743de['ShadersRepository']+_0x577d9e,this['_engine']['_loadFile'](_0x391324+'.'+_0x265714['toLowerCase']()+'.fx',_0x235e79)):_0x235e79(window['atob'](_0x577d9e['substr'](0x7))):_0x235e79(_0x577d9e['substr'](0x7));},Object['defineProperty'](_0xf743de['prototype'],'vertexSourceCode',{'get':function(){return this['_vertexSourceCodeOverride']&&this['_fragmentSourceCodeOverride']?this['_vertexSourceCodeOverride']:this['_vertexSourceCode'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xf743de['prototype'],'fragmentSourceCode',{'get':function(){return this['_vertexSourceCodeOverride']&&this['_fragmentSourceCodeOverride']?this['_fragmentSourceCodeOverride']:this['_fragmentSourceCode'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xf743de['prototype'],'rawVertexSourceCode',{'get':function(){return this['_rawVertexSourceCode'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xf743de['prototype'],'rawFragmentSourceCode',{'get':function(){return this['_rawFragmentSourceCode'];},'enumerable':!0x1,'configurable':!0x0}),_0xf743de['prototype']['_rebuildProgram']=function(_0x1e4b6f,_0x2c53a8,_0x366486,_0x43e9a6){var _0x25335f=this;this['_isReady']=!0x1,this['_vertexSourceCodeOverride']=_0x1e4b6f,this['_fragmentSourceCodeOverride']=_0x2c53a8,this['onError']=function(_0x5c9a1d,_0x7b8d0d){_0x43e9a6&&_0x43e9a6(_0x7b8d0d);},this['onCompiled']=function(){var _0x2dee9d=_0x25335f['getEngine']()['scenes'];if(_0x2dee9d){for(var _0x5872a6=0x0;_0x5872a6<_0x2dee9d['length'];_0x5872a6++)_0x2dee9d[_0x5872a6]['markAllMaterialsAsDirty'](_0x1a9ab2['a']['MATERIAL_AllDirtyFlag']);}_0x25335f['_pipelineContext']['_handlesSpectorRebuildCallback'](_0x366486);},this['_fallbacks']=null,this['_prepareEffect']();},_0xf743de['prototype']['_prepareEffect']=function(){var _0x3a1a2e=this,_0x2db424=this['_attributesNames'],_0x679352=this['defines'];this['_valueCache']={};var _0x52d2a9=this['_pipelineContext'];try{var _0x144054=this['_engine'];this['_pipelineContext']=_0x144054['createPipelineContext']();var _0x36f8bb=this['_rebuildProgram']['bind'](this);this['_vertexSourceCodeOverride']&&this['_fragmentSourceCodeOverride']?_0x144054['_preparePipelineContext'](this['_pipelineContext'],this['_vertexSourceCodeOverride'],this['_fragmentSourceCodeOverride'],!0x0,_0x36f8bb,null,this['_transformFeedbackVaryings']):_0x144054['_preparePipelineContext'](this['_pipelineContext'],this['_vertexSourceCode'],this['_fragmentSourceCode'],!0x1,_0x36f8bb,_0x679352,this['_transformFeedbackVaryings']),_0x144054['_executeWhenRenderingStateIsCompiled'](this['_pipelineContext'],function(){if(_0x144054['supportsUniformBuffers']){for(var _0x4b6e48 in _0x3a1a2e['_uniformBuffersNames'])_0x3a1a2e['bindUniformBlock'](_0x4b6e48,_0x3a1a2e['_uniformBuffersNames'][_0x4b6e48]);}var _0x53f392;if(_0x144054['getUniforms'](_0x3a1a2e['_pipelineContext'],_0x3a1a2e['_uniformsNames'])['forEach'](function(_0x27a174,_0x4f6aa1){_0x3a1a2e['_uniforms'][_0x3a1a2e['_uniformsNames'][_0x4f6aa1]]=_0x27a174;}),_0x3a1a2e['_attributes']=_0x144054['getAttributes'](_0x3a1a2e['_pipelineContext'],_0x2db424),_0x2db424)for(var _0x1e173f=0x0;_0x1e173f<_0x2db424['length'];_0x1e173f++){var _0x4ce909=_0x2db424[_0x1e173f];_0x3a1a2e['_attributeLocationByName'][_0x4ce909]=_0x3a1a2e['_attributes'][_0x1e173f];}for(_0x53f392=0x0;_0x53f392<_0x3a1a2e['_samplerList']['length'];_0x53f392++){null==_0x3a1a2e['getUniform'](_0x3a1a2e['_samplerList'][_0x53f392])&&(_0x3a1a2e['_samplerList']['splice'](_0x53f392,0x1),_0x53f392--);}_0x3a1a2e['_samplerList']['forEach'](function(_0x5c44ce,_0x1f363a){_0x3a1a2e['_samplers'][_0x5c44ce]=_0x1f363a;}),_0x144054['bindSamplers'](_0x3a1a2e),_0x3a1a2e['_compilationError']='',_0x3a1a2e['_isReady']=!0x0,_0x3a1a2e['onCompiled']&&_0x3a1a2e['onCompiled'](_0x3a1a2e),_0x3a1a2e['onCompileObservable']['notifyObservers'](_0x3a1a2e),_0x3a1a2e['onCompileObservable']['clear'](),_0x3a1a2e['_fallbacks']&&_0x3a1a2e['_fallbacks']['unBindMesh'](),_0x52d2a9&&_0x3a1a2e['getEngine']()['_deletePipelineContext'](_0x52d2a9);}),this['_pipelineContext']['isAsync']&&this['_checkIsReady'](_0x52d2a9);}catch(_0x325d23){this['_processCompilationErrors'](_0x325d23,_0x52d2a9);}},_0xf743de['prototype']['_getShaderCodeAndErrorLine']=function(_0x2ce03b,_0x274f23,_0xba59c4){var _0x4e6878=_0xba59c4?/FRAGMENT SHADER ERROR: 0:(\d+?):/:/VERTEX SHADER ERROR: 0:(\d+?):/,_0x20df7b=null;if(_0x274f23&&_0x2ce03b){var _0x1b94bc=_0x274f23['match'](_0x4e6878);if(_0x1b94bc&&0x2===_0x1b94bc['length']){var _0x6bc4d5=parseInt(_0x1b94bc[0x1]),_0x4e8111=_0x2ce03b['split']('\x0a',-0x1);_0x4e8111['length']>=_0x6bc4d5&&(_0x20df7b='Offending\x20line\x20['+_0x6bc4d5+']\x20in\x20'+(_0xba59c4?'fragment':'vertex')+'\x20code:\x20'+_0x4e8111[_0x6bc4d5-0x1]);}}return[_0x2ce03b,_0x20df7b];},_0xf743de['prototype']['_processCompilationErrors']=function(_0x41ebd1,_0x366458){var _0x3dcd5b,_0x2b89c8,_0x5a300a,_0x3e384,_0x4b9b46;void 0x0===_0x366458&&(_0x366458=null),this['_compilationError']=_0x41ebd1['message'];var _0x23c505=this['_attributesNames'],_0x2d80f9=this['_fallbacks'];if(_0x450eb8['a']['Error']('Unable\x20to\x20compile\x20effect:'),_0x450eb8['a']['Error']('Uniforms:\x20'+this['_uniformsNames']['map'](function(_0x52caec){return'\x20'+_0x52caec;})),_0x450eb8['a']['Error']('Attributes:\x20'+_0x23c505['map'](function(_0x1aa2a6){return'\x20'+_0x1aa2a6;})),_0x450eb8['a']['Error']('Defines:\x0d\x0a'+this['defines']),_0xf743de['LogShaderCodeOnCompilationError']){var _0xe88026=null,_0x413080=null,_0x159cd7=null;(null===(_0x5a300a=this['_pipelineContext'])||void 0x0===_0x5a300a?void 0x0:_0x5a300a['_getVertexShaderCode']())&&(_0x159cd7=(_0x3dcd5b=this['_getShaderCodeAndErrorLine'](this['_pipelineContext']['_getVertexShaderCode'](),this['_compilationError'],!0x1))[0x0],_0xe88026=_0x3dcd5b[0x1],_0x159cd7&&(_0x450eb8['a']['Error']('Vertex\x20code:'),_0x450eb8['a']['Error'](_0x159cd7))),(null===(_0x3e384=this['_pipelineContext'])||void 0x0===_0x3e384?void 0x0:_0x3e384['_getFragmentShaderCode']())&&(_0x159cd7=(_0x2b89c8=this['_getShaderCodeAndErrorLine'](null===(_0x4b9b46=this['_pipelineContext'])||void 0x0===_0x4b9b46?void 0x0:_0x4b9b46['_getFragmentShaderCode'](),this['_compilationError'],!0x0))[0x0],_0x413080=_0x2b89c8[0x1],_0x159cd7&&(_0x450eb8['a']['Error']('Fragment\x20code:'),_0x450eb8['a']['Error'](_0x159cd7))),_0xe88026&&_0x450eb8['a']['Error'](_0xe88026),_0x413080&&_0x450eb8['a']['Error'](_0x413080);}_0x450eb8['a']['Error']('Error:\x20'+this['_compilationError']),_0x366458&&(this['_pipelineContext']=_0x366458,this['_isReady']=!0x0,this['onError']&&this['onError'](this,this['_compilationError']),this['onErrorObservable']['notifyObservers'](this)),_0x2d80f9?(this['_pipelineContext']=null,_0x2d80f9['hasMoreFallbacks']?(this['_allFallbacksProcessed']=!0x1,_0x450eb8['a']['Error']('Trying\x20next\x20fallback.'),this['defines']=_0x2d80f9['reduce'](this['defines'],this),this['_prepareEffect']()):(this['_allFallbacksProcessed']=!0x0,this['onError']&&this['onError'](this,this['_compilationError']),this['onErrorObservable']['notifyObservers'](this),this['onErrorObservable']['clear'](),this['_fallbacks']&&this['_fallbacks']['unBindMesh']())):this['_allFallbacksProcessed']=!0x0;},Object['defineProperty'](_0xf743de['prototype'],'isSupported',{'get':function(){return''===this['_compilationError'];},'enumerable':!0x1,'configurable':!0x0}),_0xf743de['prototype']['_bindTexture']=function(_0x59a157,_0x9608c2){this['_engine']['_bindTexture'](this['_samplers'][_0x59a157],_0x9608c2);},_0xf743de['prototype']['setTexture']=function(_0xe9fe31,_0x4153db){this['_engine']['setTexture'](this['_samplers'][_0xe9fe31],this['_uniforms'][_0xe9fe31],_0x4153db);},_0xf743de['prototype']['setDepthStencilTexture']=function(_0x5138ba,_0x42da56){this['_engine']['setDepthStencilTexture'](this['_samplers'][_0x5138ba],this['_uniforms'][_0x5138ba],_0x42da56);},_0xf743de['prototype']['setTextureArray']=function(_0x44bdd3,_0x351bd8){var _0xabd3fb=_0x44bdd3+'Ex';if(-0x1===this['_samplerList']['indexOf'](_0xabd3fb+'0')){for(var _0x151308=this['_samplerList']['indexOf'](_0x44bdd3),_0x3b57d0=0x1;_0x3b57d0<_0x351bd8['length'];_0x3b57d0++){var _0x531176=_0xabd3fb+(_0x3b57d0-0x1)['toString']();this['_samplerList']['splice'](_0x151308+_0x3b57d0,0x0,_0x531176);}for(var _0x5afd44=0x0,_0x4e4b3f=0x0,_0x13956c=this['_samplerList'];_0x4e4b3f<_0x13956c['length'];_0x4e4b3f++){var _0x16d514=_0x13956c[_0x4e4b3f];this['_samplers'][_0x16d514]=_0x5afd44,_0x5afd44+=0x1;}}this['_engine']['setTextureArray'](this['_samplers'][_0x44bdd3],this['_uniforms'][_0x44bdd3],_0x351bd8);},_0xf743de['prototype']['setTextureFromPostProcess']=function(_0x5c1108,_0x52743c){this['_engine']['setTextureFromPostProcess'](this['_samplers'][_0x5c1108],_0x52743c);},_0xf743de['prototype']['setTextureFromPostProcessOutput']=function(_0x422559,_0x1ccc26){this['_engine']['setTextureFromPostProcessOutput'](this['_samplers'][_0x422559],_0x1ccc26);},_0xf743de['prototype']['_cacheMatrix']=function(_0x25b495,_0x2e524a){var _0x42fc76=this['_valueCache'][_0x25b495],_0xc4e7c1=_0x2e524a['updateFlag'];return(void 0x0===_0x42fc76||_0x42fc76!==_0xc4e7c1)&&(this['_valueCache'][_0x25b495]=_0xc4e7c1,!0x0);},_0xf743de['prototype']['_cacheFloat2']=function(_0x280184,_0x4153b2,_0x5358b2){var _0x3f8401=this['_valueCache'][_0x280184];if(!_0x3f8401||0x2!==_0x3f8401['length'])return _0x3f8401=[_0x4153b2,_0x5358b2],this['_valueCache'][_0x280184]=_0x3f8401,!0x0;var _0x483e40=!0x1;return _0x3f8401[0x0]!==_0x4153b2&&(_0x3f8401[0x0]=_0x4153b2,_0x483e40=!0x0),_0x3f8401[0x1]!==_0x5358b2&&(_0x3f8401[0x1]=_0x5358b2,_0x483e40=!0x0),_0x483e40;},_0xf743de['prototype']['_cacheFloat3']=function(_0x2bab7a,_0x4f8c1b,_0x4048f6,_0x46c78f){var _0x416ddc=this['_valueCache'][_0x2bab7a];if(!_0x416ddc||0x3!==_0x416ddc['length'])return _0x416ddc=[_0x4f8c1b,_0x4048f6,_0x46c78f],this['_valueCache'][_0x2bab7a]=_0x416ddc,!0x0;var _0x3e9363=!0x1;return _0x416ddc[0x0]!==_0x4f8c1b&&(_0x416ddc[0x0]=_0x4f8c1b,_0x3e9363=!0x0),_0x416ddc[0x1]!==_0x4048f6&&(_0x416ddc[0x1]=_0x4048f6,_0x3e9363=!0x0),_0x416ddc[0x2]!==_0x46c78f&&(_0x416ddc[0x2]=_0x46c78f,_0x3e9363=!0x0),_0x3e9363;},_0xf743de['prototype']['_cacheFloat4']=function(_0x3d17e1,_0x3d47c9,_0x23b59d,_0x550a9d,_0x5f2a4c){var _0x5a3386=this['_valueCache'][_0x3d17e1];if(!_0x5a3386||0x4!==_0x5a3386['length'])return _0x5a3386=[_0x3d47c9,_0x23b59d,_0x550a9d,_0x5f2a4c],this['_valueCache'][_0x3d17e1]=_0x5a3386,!0x0;var _0x3d2d1e=!0x1;return _0x5a3386[0x0]!==_0x3d47c9&&(_0x5a3386[0x0]=_0x3d47c9,_0x3d2d1e=!0x0),_0x5a3386[0x1]!==_0x23b59d&&(_0x5a3386[0x1]=_0x23b59d,_0x3d2d1e=!0x0),_0x5a3386[0x2]!==_0x550a9d&&(_0x5a3386[0x2]=_0x550a9d,_0x3d2d1e=!0x0),_0x5a3386[0x3]!==_0x5f2a4c&&(_0x5a3386[0x3]=_0x5f2a4c,_0x3d2d1e=!0x0),_0x3d2d1e;},_0xf743de['prototype']['bindUniformBuffer']=function(_0xa6eac4,_0x5f5587){var _0x3a6c55=this['_uniformBuffersNames'][_0x5f5587];void 0x0!==_0x3a6c55&&_0xf743de['_baseCache'][_0x3a6c55]!==_0xa6eac4&&(_0xf743de['_baseCache'][_0x3a6c55]=_0xa6eac4,this['_engine']['bindUniformBufferBase'](_0xa6eac4,_0x3a6c55));},_0xf743de['prototype']['bindUniformBlock']=function(_0x5051a5,_0x51c69d){this['_engine']['bindUniformBlock'](this['_pipelineContext'],_0x5051a5,_0x51c69d);},_0xf743de['prototype']['setInt']=function(_0x2989bf,_0x1b22f0){var _0x313c60=this['_valueCache'][_0x2989bf];return void 0x0!==_0x313c60&&_0x313c60===_0x1b22f0||this['_engine']['setInt'](this['_uniforms'][_0x2989bf],_0x1b22f0)&&(this['_valueCache'][_0x2989bf]=_0x1b22f0),this;},_0xf743de['prototype']['setIntArray']=function(_0x41ebec,_0x4f53cb){return this['_valueCache'][_0x41ebec]=null,this['_engine']['setIntArray'](this['_uniforms'][_0x41ebec],_0x4f53cb),this;},_0xf743de['prototype']['setIntArray2']=function(_0xb35064,_0x19b173){return this['_valueCache'][_0xb35064]=null,this['_engine']['setIntArray2'](this['_uniforms'][_0xb35064],_0x19b173),this;},_0xf743de['prototype']['setIntArray3']=function(_0x43b8fc,_0x2aab45){return this['_valueCache'][_0x43b8fc]=null,this['_engine']['setIntArray3'](this['_uniforms'][_0x43b8fc],_0x2aab45),this;},_0xf743de['prototype']['setIntArray4']=function(_0x1b6b18,_0x13b968){return this['_valueCache'][_0x1b6b18]=null,this['_engine']['setIntArray4'](this['_uniforms'][_0x1b6b18],_0x13b968),this;},_0xf743de['prototype']['setFloatArray']=function(_0x54eb8f,_0x27b8a2){return this['_valueCache'][_0x54eb8f]=null,this['_engine']['setArray'](this['_uniforms'][_0x54eb8f],_0x27b8a2),this;},_0xf743de['prototype']['setFloatArray2']=function(_0x49b4b2,_0x21ecb2){return this['_valueCache'][_0x49b4b2]=null,this['_engine']['setArray2'](this['_uniforms'][_0x49b4b2],_0x21ecb2),this;},_0xf743de['prototype']['setFloatArray3']=function(_0x338aa3,_0x324e39){return this['_valueCache'][_0x338aa3]=null,this['_engine']['setArray3'](this['_uniforms'][_0x338aa3],_0x324e39),this;},_0xf743de['prototype']['setFloatArray4']=function(_0x1f31fe,_0x82b695){return this['_valueCache'][_0x1f31fe]=null,this['_engine']['setArray4'](this['_uniforms'][_0x1f31fe],_0x82b695),this;},_0xf743de['prototype']['setArray']=function(_0x1a4e38,_0x33a1dc){return this['_valueCache'][_0x1a4e38]=null,this['_engine']['setArray'](this['_uniforms'][_0x1a4e38],_0x33a1dc),this;},_0xf743de['prototype']['setArray2']=function(_0x18b63b,_0x1a2e3c){return this['_valueCache'][_0x18b63b]=null,this['_engine']['setArray2'](this['_uniforms'][_0x18b63b],_0x1a2e3c),this;},_0xf743de['prototype']['setArray3']=function(_0x2f16eb,_0x3bff44){return this['_valueCache'][_0x2f16eb]=null,this['_engine']['setArray3'](this['_uniforms'][_0x2f16eb],_0x3bff44),this;},_0xf743de['prototype']['setArray4']=function(_0x1424bf,_0x56163a){return this['_valueCache'][_0x1424bf]=null,this['_engine']['setArray4'](this['_uniforms'][_0x1424bf],_0x56163a),this;},_0xf743de['prototype']['setMatrices']=function(_0x291fe1,_0x22984b){return _0x22984b?(this['_valueCache'][_0x291fe1]=null,this['_engine']['setMatrices'](this['_uniforms'][_0x291fe1],_0x22984b),this):this;},_0xf743de['prototype']['setMatrix']=function(_0x842f97,_0x33d384){return this['_cacheMatrix'](_0x842f97,_0x33d384)&&(this['_engine']['setMatrices'](this['_uniforms'][_0x842f97],_0x33d384['toArray']())||(this['_valueCache'][_0x842f97]=null)),this;},_0xf743de['prototype']['setMatrix3x3']=function(_0x572a15,_0x5841a0){return this['_valueCache'][_0x572a15]=null,this['_engine']['setMatrix3x3'](this['_uniforms'][_0x572a15],_0x5841a0),this;},_0xf743de['prototype']['setMatrix2x2']=function(_0x3377f3,_0x36e71c){return this['_valueCache'][_0x3377f3]=null,this['_engine']['setMatrix2x2'](this['_uniforms'][_0x3377f3],_0x36e71c),this;},_0xf743de['prototype']['setFloat']=function(_0x329a1c,_0x2a5ebf){var _0x2616c6=this['_valueCache'][_0x329a1c];return void 0x0!==_0x2616c6&&_0x2616c6===_0x2a5ebf||this['_engine']['setFloat'](this['_uniforms'][_0x329a1c],_0x2a5ebf)&&(this['_valueCache'][_0x329a1c]=_0x2a5ebf),this;},_0xf743de['prototype']['setBool']=function(_0x3a347f,_0xb7914a){var _0x44d0af=this['_valueCache'][_0x3a347f];return void 0x0!==_0x44d0af&&_0x44d0af===_0xb7914a||this['_engine']['setInt'](this['_uniforms'][_0x3a347f],_0xb7914a?0x1:0x0)&&(this['_valueCache'][_0x3a347f]=_0xb7914a),this;},_0xf743de['prototype']['setVector2']=function(_0x3f8c61,_0xa5c33){return this['_cacheFloat2'](_0x3f8c61,_0xa5c33['x'],_0xa5c33['y'])&&(this['_engine']['setFloat2'](this['_uniforms'][_0x3f8c61],_0xa5c33['x'],_0xa5c33['y'])||(this['_valueCache'][_0x3f8c61]=null)),this;},_0xf743de['prototype']['setFloat2']=function(_0x98da10,_0x35fe7f,_0x1ce1f2){return this['_cacheFloat2'](_0x98da10,_0x35fe7f,_0x1ce1f2)&&(this['_engine']['setFloat2'](this['_uniforms'][_0x98da10],_0x35fe7f,_0x1ce1f2)||(this['_valueCache'][_0x98da10]=null)),this;},_0xf743de['prototype']['setVector3']=function(_0x25eef3,_0x3250cb){return this['_cacheFloat3'](_0x25eef3,_0x3250cb['x'],_0x3250cb['y'],_0x3250cb['z'])&&(this['_engine']['setFloat3'](this['_uniforms'][_0x25eef3],_0x3250cb['x'],_0x3250cb['y'],_0x3250cb['z'])||(this['_valueCache'][_0x25eef3]=null)),this;},_0xf743de['prototype']['setFloat3']=function(_0x46f87b,_0x41b237,_0x2763ee,_0x34318a){return this['_cacheFloat3'](_0x46f87b,_0x41b237,_0x2763ee,_0x34318a)&&(this['_engine']['setFloat3'](this['_uniforms'][_0x46f87b],_0x41b237,_0x2763ee,_0x34318a)||(this['_valueCache'][_0x46f87b]=null)),this;},_0xf743de['prototype']['setVector4']=function(_0x509e1c,_0x167195){return this['_cacheFloat4'](_0x509e1c,_0x167195['x'],_0x167195['y'],_0x167195['z'],_0x167195['w'])&&(this['_engine']['setFloat4'](this['_uniforms'][_0x509e1c],_0x167195['x'],_0x167195['y'],_0x167195['z'],_0x167195['w'])||(this['_valueCache'][_0x509e1c]=null)),this;},_0xf743de['prototype']['setFloat4']=function(_0x4d5529,_0x1b8ba5,_0x4f8e85,_0x26db98,_0x285f19){return this['_cacheFloat4'](_0x4d5529,_0x1b8ba5,_0x4f8e85,_0x26db98,_0x285f19)&&(this['_engine']['setFloat4'](this['_uniforms'][_0x4d5529],_0x1b8ba5,_0x4f8e85,_0x26db98,_0x285f19)||(this['_valueCache'][_0x4d5529]=null)),this;},_0xf743de['prototype']['setColor3']=function(_0xceacdd,_0x5f3910){return this['_cacheFloat3'](_0xceacdd,_0x5f3910['r'],_0x5f3910['g'],_0x5f3910['b'])&&(this['_engine']['setFloat3'](this['_uniforms'][_0xceacdd],_0x5f3910['r'],_0x5f3910['g'],_0x5f3910['b'])||(this['_valueCache'][_0xceacdd]=null)),this;},_0xf743de['prototype']['setColor4']=function(_0x4a886e,_0x43e6f7,_0x465823){return this['_cacheFloat4'](_0x4a886e,_0x43e6f7['r'],_0x43e6f7['g'],_0x43e6f7['b'],_0x465823)&&(this['_engine']['setFloat4'](this['_uniforms'][_0x4a886e],_0x43e6f7['r'],_0x43e6f7['g'],_0x43e6f7['b'],_0x465823)||(this['_valueCache'][_0x4a886e]=null)),this;},_0xf743de['prototype']['setDirectColor4']=function(_0x6aa08a,_0x204f7c){return this['_cacheFloat4'](_0x6aa08a,_0x204f7c['r'],_0x204f7c['g'],_0x204f7c['b'],_0x204f7c['a'])&&(this['_engine']['setFloat4'](this['_uniforms'][_0x6aa08a],_0x204f7c['r'],_0x204f7c['g'],_0x204f7c['b'],_0x204f7c['a'])||(this['_valueCache'][_0x6aa08a]=null)),this;},_0xf743de['prototype']['dispose']=function(){this['_engine']['_releaseEffect'](this);},_0xf743de['RegisterShader']=function(_0x4c3679,_0x4d3e30,_0x7b0555){_0x4d3e30&&(_0xf743de['ShadersStore'][_0x4c3679+'PixelShader']=_0x4d3e30),_0x7b0555&&(_0xf743de['ShadersStore'][_0x4c3679+'VertexShader']=_0x7b0555);},_0xf743de['ResetCache']=function(){_0xf743de['_baseCache']={};},_0xf743de['ShadersRepository']='src/Shaders/',_0xf743de['LogShaderCodeOnCompilationError']=!0x0,_0xf743de['_uniqueIdSeed']=0x0,_0xf743de['_baseCache']={},_0xf743de['ShadersStore']={},_0xf743de['IncludesShadersStore']={},_0xf743de;}());},function(_0x30c7c4,_0x2f04df,_0x3100c6){'use strict';_0x3100c6['d'](_0x2f04df,'a',function(){return _0x332590;}),_0x3100c6['d'](_0x2f04df,'d',function(){return _0x20ebd8;}),_0x3100c6['d'](_0x2f04df,'b',function(){return _0xdef87;}),_0x3100c6['d'](_0x2f04df,'c',function(){return _0x6278e0;});var _0x332590=(function(){function _0x34c684(_0x545953,_0x3bb2bf,_0x499f1c,_0x3fcde8){void 0x0===_0x3bb2bf&&(_0x3bb2bf=!0x1),this['initalize'](_0x545953,_0x3bb2bf,_0x499f1c,_0x3fcde8);}return _0x34c684['prototype']['initalize']=function(_0x568490,_0x576da4,_0x16b5d6,_0x2e6eb2){return void 0x0===_0x576da4&&(_0x576da4=!0x1),this['mask']=_0x568490,this['skipNextObservers']=_0x576da4,this['target']=_0x16b5d6,this['currentTarget']=_0x2e6eb2,this;},_0x34c684;}()),_0x20ebd8=function(_0x110f50,_0x368e41,_0x32eb96){void 0x0===_0x32eb96&&(_0x32eb96=null),this['callback']=_0x110f50,this['mask']=_0x368e41,this['scope']=_0x32eb96,this['_willBeUnregistered']=!0x1,this['unregisterOnNextCall']=!0x1;},_0xdef87=(function(){function _0x300b41(){}return _0x300b41['prototype']['dispose']=function(){if(this['_observers']&&this['_observables']){for(var _0x210db7=0x0;_0x210db70x0;},_0x43b9bb['prototype']['clear']=function(){this['_observers']=new Array(),this['_onObserverAdded']=null;},_0x43b9bb['prototype']['clone']=function(){var _0x5ccc03=new _0x43b9bb();return _0x5ccc03['_observers']=this['_observers']['slice'](0x0),_0x5ccc03;},_0x43b9bb['prototype']['hasSpecificMask']=function(_0xaa6bc8){void 0x0===_0xaa6bc8&&(_0xaa6bc8=-0x1);for(var _0x5dce02=0x0,_0x1f2308=this['_observers'];_0x5dce02<_0x1f2308['length'];_0x5dce02++){var _0x1a4624=_0x1f2308[_0x5dce02];if(_0x1a4624['mask']&_0xaa6bc8||_0x1a4624['mask']===_0xaa6bc8)return!0x0;}return!0x1;},_0x43b9bb;}());},function(_0x2a7173,_0x38349e,_0x12c983){'use strict';_0x12c983['d'](_0x38349e,'b',function(){return _0xc38506;}),_0x12c983['d'](_0x38349e,'c',function(){return _0x749c40;}),_0x12c983['d'](_0x38349e,'a',function(){return _0x55a7d7;});var _0x2bfd19=_0x12c983(0x1),_0x304b63=_0x12c983(0x6),_0x15f0a7=_0x12c983(0xc),_0x4b9127=_0x12c983(0x29),_0x11e731=_0x12c983(0x25),_0xfcdde3=_0x12c983(0x0),_0x29dc88=_0x12c983(0x9),_0x131ca8=_0x12c983(0x1d),_0x46dc40=_0x12c983(0x4),_0x148cfc=_0x12c983(0x10),_0x21ffea=_0x12c983(0x47),_0x550af6=_0x12c983(0x1f),_0x452130=_0x12c983(0x3d),_0x569871=_0x12c983(0x2b),_0x24f49e=_0x12c983(0x19),_0x352df0=_0x12c983(0x44),_0x2ec963=_0x12c983(0x45),_0x4503b0=_0x12c983(0x2),_0xfa0249=_0x12c983(0x3),_0x1242ee=_0x12c983(0x8),_0x1268fb=_0x12c983(0xb),_0x3f0030=_0x12c983(0x15),_0x1bbc1c=_0x12c983(0x11),_0x5984f7=_0x12c983(0x95),_0x34c45a=_0x12c983(0x46),_0xc38506=function(){},_0x598a06=function(){this['visibleInstances']={},this['batchCache']=new _0x749c40(),this['instancesBufferSize']=0x800;},_0x749c40=function(){this['mustReturn']=!0x1,this['visibleInstances']=new Array(),this['renderSelf']=new Array(),this['hardwareInstancedRendering']=new Array();},_0x37d89e=function(){this['instancesCount']=0x0,this['matrixBuffer']=null,this['matrixBufferSize']=0x200,this['boundingVectors']=[],this['worldMatrices']=null;},_0xce4190=function(){this['_areNormalsFrozen']=!0x1,this['_source']=null,this['meshMap']=null,this['_preActivateId']=-0x1,this['_LODLevels']=new Array(),this['_morphTargetManager']=null;},_0x55a7d7=function(_0x8effd0){function _0x249c5c(_0x5b6fcd,_0x389839,_0x53f83c,_0x4743b6,_0x3f4483,_0x1d106f){void 0x0===_0x389839&&(_0x389839=null),void 0x0===_0x53f83c&&(_0x53f83c=null),void 0x0===_0x4743b6&&(_0x4743b6=null),void 0x0===_0x1d106f&&(_0x1d106f=!0x0);var _0xf8ab56=_0x8effd0['call'](this,_0x5b6fcd,_0x389839)||this;if(_0xf8ab56['_internalMeshDataInfo']=new _0xce4190(),_0xf8ab56['delayLoadState']=_0x4503b0['a']['DELAYLOADSTATE_NONE'],_0xf8ab56['instances']=new Array(),_0xf8ab56['_creationDataStorage']=null,_0xf8ab56['_geometry']=null,_0xf8ab56['_instanceDataStorage']=new _0x598a06(),_0xf8ab56['_thinInstanceDataStorage']=new _0x37d89e(),_0xf8ab56['_effectiveMaterial']=null,_0xf8ab56['_shouldGenerateFlatShading']=!0x1,_0xf8ab56['_originalBuilderSideOrientation']=_0x249c5c['DEFAULTSIDE'],_0xf8ab56['overrideMaterialSideOrientation']=null,_0x389839=_0xf8ab56['getScene'](),_0x4743b6){if(_0x4743b6['_geometry']&&_0x4743b6['_geometry']['applyToMesh'](_0xf8ab56),_0x4b9127['a']['DeepCopy'](_0x4743b6,_0xf8ab56,['name','material','skeleton','instances','parent','uniqueId','source','metadata','morphTargetManager','hasInstances','source','worldMatrixInstancedBuffer','hasLODLevels','geometry','isBlocked','areNormalsFrozen','facetNb','isFacetDataEnabled','lightSources','useBones','isAnInstance','collider','edgesRenderer','forward','up','right','absolutePosition','absoluteScaling','absoluteRotationQuaternion','isWorldMatrixFrozen','nonUniformScaling','behaviors','worldMatrixFromCache','hasThinInstances','cloneMeshMap'],['_poseMatrix']),_0xf8ab56['_internalMeshDataInfo']['_source']=_0x4743b6,_0x389839['useClonedMeshMap']&&(_0x4743b6['_internalMeshDataInfo']['meshMap']||(_0x4743b6['_internalMeshDataInfo']['meshMap']={}),_0x4743b6['_internalMeshDataInfo']['meshMap'][_0xf8ab56['uniqueId']]=_0xf8ab56),_0xf8ab56['_originalBuilderSideOrientation']=_0x4743b6['_originalBuilderSideOrientation'],_0xf8ab56['_creationDataStorage']=_0x4743b6['_creationDataStorage'],_0x4743b6['_ranges']){var _0x50f40f=_0x4743b6['_ranges'];for(var _0x5b6fcd in _0x50f40f)_0x50f40f['hasOwnProperty'](_0x5b6fcd)&&_0x50f40f[_0x5b6fcd]&&_0xf8ab56['createAnimationRange'](_0x5b6fcd,_0x50f40f[_0x5b6fcd]['from'],_0x50f40f[_0x5b6fcd]['to']);}var _0x1f1b49;if(_0x4743b6['metadata']&&_0x4743b6['metadata']['clone']?_0xf8ab56['metadata']=_0x4743b6['metadata']['clone']():_0xf8ab56['metadata']=_0x4743b6['metadata'],_0x11e731['a']&&_0x11e731['a']['HasTags'](_0x4743b6)&&_0x11e731['a']['AddTagsTo'](_0xf8ab56,_0x11e731['a']['GetTags'](_0x4743b6,!0x0)),_0xf8ab56['setEnabled'](_0x4743b6['isEnabled']()),_0xf8ab56['parent']=_0x4743b6['parent'],_0xf8ab56['setPivotMatrix'](_0x4743b6['getPivotMatrix']()),_0xf8ab56['id']=_0x5b6fcd+'.'+_0x4743b6['id'],_0xf8ab56['material']=_0x4743b6['material'],!_0x3f4483)for(var _0x1411d8=_0x4743b6['getDescendants'](!0x0),_0xe2efe7=0x0;_0xe2efe7<_0x1411d8['length'];_0xe2efe7++){var _0x4ed7e5=_0x1411d8[_0xe2efe7];_0x4ed7e5['clone']&&_0x4ed7e5['clone'](_0x5b6fcd+'.'+_0x4ed7e5['name'],_0xf8ab56);}if(_0x4743b6['morphTargetManager']&&(_0xf8ab56['morphTargetManager']=_0x4743b6['morphTargetManager']),_0x389839['getPhysicsEngine']){var _0x3f8a70=_0x389839['getPhysicsEngine']();if(_0x1d106f&&_0x3f8a70){var _0x14b899=_0x3f8a70['getImpostorForPhysicsObject'](_0x4743b6);_0x14b899&&(_0xf8ab56['physicsImpostor']=_0x14b899['clone'](_0xf8ab56));}}for(_0x1f1b49=0x0;_0x1f1b49<_0x389839['particleSystems']['length'];_0x1f1b49++){var _0x562b3f=_0x389839['particleSystems'][_0x1f1b49];_0x562b3f['emitter']===_0x4743b6&&_0x562b3f['clone'](_0x562b3f['name'],_0xf8ab56);}_0xf8ab56['refreshBoundingInfo'](),_0xf8ab56['computeWorldMatrix'](!0x0);}return null!==_0x53f83c&&(_0xf8ab56['parent']=_0x53f83c),_0xf8ab56['_instanceDataStorage']['hardwareInstancedRendering']=_0xf8ab56['getEngine']()['getCaps']()['instancedArrays'],_0xf8ab56;}return Object(_0x2bfd19['d'])(_0x249c5c,_0x8effd0),_0x249c5c['_GetDefaultSideOrientation']=function(_0x5bdd37){return _0x5bdd37||_0x249c5c['FRONTSIDE'];},Object['defineProperty'](_0x249c5c['prototype'],'computeBonesUsingShaders',{'get':function(){return this['_internalAbstractMeshDataInfo']['_computeBonesUsingShaders'];},'set':function(_0x165e95){this['_internalAbstractMeshDataInfo']['_computeBonesUsingShaders']!==_0x165e95&&(_0x165e95&&this['_internalMeshDataInfo']['_sourcePositions']&&(this['setVerticesData'](_0x46dc40['b']['PositionKind'],this['_internalMeshDataInfo']['_sourcePositions']['slice'](),!0x0),this['_internalMeshDataInfo']['_sourceNormals']&&this['setVerticesData'](_0x46dc40['b']['NormalKind'],this['_internalMeshDataInfo']['_sourceNormals']['slice'](),!0x0)),this['_internalAbstractMeshDataInfo']['_computeBonesUsingShaders']=_0x165e95,this['_markSubMeshesAsAttributesDirty']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x249c5c['prototype'],'onBeforeRenderObservable',{'get':function(){return this['_internalMeshDataInfo']['_onBeforeRenderObservable']||(this['_internalMeshDataInfo']['_onBeforeRenderObservable']=new _0x304b63['c']()),this['_internalMeshDataInfo']['_onBeforeRenderObservable'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x249c5c['prototype'],'onBeforeBindObservable',{'get':function(){return this['_internalMeshDataInfo']['_onBeforeBindObservable']||(this['_internalMeshDataInfo']['_onBeforeBindObservable']=new _0x304b63['c']()),this['_internalMeshDataInfo']['_onBeforeBindObservable'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x249c5c['prototype'],'onAfterRenderObservable',{'get':function(){return this['_internalMeshDataInfo']['_onAfterRenderObservable']||(this['_internalMeshDataInfo']['_onAfterRenderObservable']=new _0x304b63['c']()),this['_internalMeshDataInfo']['_onAfterRenderObservable'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x249c5c['prototype'],'onBeforeDrawObservable',{'get':function(){return this['_internalMeshDataInfo']['_onBeforeDrawObservable']||(this['_internalMeshDataInfo']['_onBeforeDrawObservable']=new _0x304b63['c']()),this['_internalMeshDataInfo']['_onBeforeDrawObservable'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x249c5c['prototype'],'onBeforeDraw',{'set':function(_0x52226b){this['_onBeforeDrawObserver']&&this['onBeforeDrawObservable']['remove'](this['_onBeforeDrawObserver']),this['_onBeforeDrawObserver']=this['onBeforeDrawObservable']['add'](_0x52226b);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x249c5c['prototype'],'hasInstances',{'get':function(){return this['instances']['length']>0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x249c5c['prototype'],'hasThinInstances',{'get':function(){var _0x273a1c;return(null!==(_0x273a1c=this['_thinInstanceDataStorage']['instancesCount'])&&void 0x0!==_0x273a1c?_0x273a1c:0x0)>0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x249c5c['prototype'],'morphTargetManager',{'get':function(){return this['_internalMeshDataInfo']['_morphTargetManager'];},'set':function(_0x447189){this['_internalMeshDataInfo']['_morphTargetManager']!==_0x447189&&(this['_internalMeshDataInfo']['_morphTargetManager']=_0x447189,this['_syncGeometryWithMorphTargetManager']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x249c5c['prototype'],'source',{'get':function(){return this['_internalMeshDataInfo']['_source'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x249c5c['prototype'],'cloneMeshMap',{'get':function(){return this['_internalMeshDataInfo']['meshMap'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x249c5c['prototype'],'isUnIndexed',{'get':function(){return this['_unIndexed'];},'set':function(_0x12d369){this['_unIndexed']!==_0x12d369&&(this['_unIndexed']=_0x12d369,this['_markSubMeshesAsAttributesDirty']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x249c5c['prototype'],'worldMatrixInstancedBuffer',{'get':function(){return this['_instanceDataStorage']['instancesData'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x249c5c['prototype'],'manualUpdateOfWorldMatrixInstancedBuffer',{'get':function(){return this['_instanceDataStorage']['manualUpdate'];},'set':function(_0x5541d1){this['_instanceDataStorage']['manualUpdate']=_0x5541d1;},'enumerable':!0x1,'configurable':!0x0}),_0x249c5c['prototype']['instantiateHierarchy']=function(_0x403b2f,_0xfd2bf6,_0x283c5d){void 0x0===_0x403b2f&&(_0x403b2f=null);var _0x438310=!(this['getTotalVertices']()>0x0)||_0xfd2bf6&&_0xfd2bf6['doNotInstantiate']?this['clone']('Clone\x20of\x20'+(this['name']||this['id']),_0x403b2f||this['parent'],!0x0):this['createInstance']('instance\x20of\x20'+(this['name']||this['id']));_0x438310&&(_0x438310['parent']=_0x403b2f||this['parent'],_0x438310['position']=this['position']['clone'](),_0x438310['scaling']=this['scaling']['clone'](),this['rotationQuaternion']?_0x438310['rotationQuaternion']=this['rotationQuaternion']['clone']():_0x438310['rotation']=this['rotation']['clone'](),_0x283c5d&&_0x283c5d(this,_0x438310));for(var _0x1db9a2=0x0,_0x6105f=this['getChildTransformNodes'](!0x0);_0x1db9a2<_0x6105f['length'];_0x1db9a2++){_0x6105f[_0x1db9a2]['instantiateHierarchy'](_0x438310,_0xfd2bf6,_0x283c5d);}return _0x438310;},_0x249c5c['prototype']['getClassName']=function(){return'Mesh';},Object['defineProperty'](_0x249c5c['prototype'],'_isMesh',{'get':function(){return!0x0;},'enumerable':!0x1,'configurable':!0x0}),_0x249c5c['prototype']['toString']=function(_0x1af4a2){var _0x450627=_0x8effd0['prototype']['toString']['call'](this,_0x1af4a2);if(_0x450627+=',\x20n\x20vertices:\x20'+this['getTotalVertices'](),_0x450627+=',\x20parent:\x20'+(this['_waitingParentId']?this['_waitingParentId']:this['parent']?this['parent']['name']:'NONE'),this['animations']){for(var _0x3a28df=0x0;_0x3a28df0x0;},'enumerable':!0x1,'configurable':!0x0}),_0x249c5c['prototype']['getLODLevels']=function(){return this['_internalMeshDataInfo']['_LODLevels'];},_0x249c5c['prototype']['_sortLODLevels']=function(){this['_internalMeshDataInfo']['_LODLevels']['sort'](function(_0x25b925,_0x71cba3){return _0x25b925['distance']<_0x71cba3['distance']?0x1:_0x25b925['distance']>_0x71cba3['distance']?-0x1:0x0;});},_0x249c5c['prototype']['addLODLevel']=function(_0x3830ce,_0x45c266){if(_0x45c266&&_0x45c266['_masterMesh'])return _0x1242ee['a']['Warn']('You\x20cannot\x20use\x20a\x20mesh\x20as\x20LOD\x20level\x20twice'),this;var _0x9afaa2=new _0x5984f7['a'](_0x3830ce,_0x45c266);return this['_internalMeshDataInfo']['_LODLevels']['push'](_0x9afaa2),_0x45c266&&(_0x45c266['_masterMesh']=this),this['_sortLODLevels'](),this;},_0x249c5c['prototype']['getLODLevelAtDistance']=function(_0x294173){for(var _0x3ad7ae=this['_internalMeshDataInfo'],_0x3c8fc0=0x0;_0x3c8fc0<_0x3ad7ae['_LODLevels']['length'];_0x3c8fc0++){var _0x3c198e=_0x3ad7ae['_LODLevels'][_0x3c8fc0];if(_0x3c198e['distance']===_0x294173)return _0x3c198e['mesh'];}return null;},_0x249c5c['prototype']['removeLODLevel']=function(_0x3398e6){for(var _0xdf5d0c=this['_internalMeshDataInfo'],_0x4aa838=0x0;_0x4aa838<_0xdf5d0c['_LODLevels']['length'];_0x4aa838++)_0xdf5d0c['_LODLevels'][_0x4aa838]['mesh']===_0x3398e6&&(_0xdf5d0c['_LODLevels']['splice'](_0x4aa838,0x1),_0x3398e6&&(_0x3398e6['_masterMesh']=null));return this['_sortLODLevels'](),this;},_0x249c5c['prototype']['getLOD']=function(_0x236853,_0x4582ef){var _0x3f43cb,_0x1c42e3=this['_internalMeshDataInfo'];if(!_0x1c42e3['_LODLevels']||0x0===_0x1c42e3['_LODLevels']['length'])return this;_0x4582ef?_0x3f43cb=_0x4582ef:_0x3f43cb=this['getBoundingInfo']()['boundingSphere'];var _0x467324=_0x3f43cb['centerWorld']['subtract'](_0x236853['globalPosition'])['length']();if(_0x1c42e3['_LODLevels'][_0x1c42e3['_LODLevels']['length']-0x1]['distance']>_0x467324)return this['onLODLevelSelection']&&this['onLODLevelSelection'](_0x467324,this,this),this;for(var _0x11a3ae=0x0;_0x11a3ae<_0x1c42e3['_LODLevels']['length'];_0x11a3ae++){var _0x5588f7=_0x1c42e3['_LODLevels'][_0x11a3ae];if(_0x5588f7['distance']<_0x467324){if(_0x5588f7['mesh']){if(_0x5588f7['mesh']['delayLoadState']===_0x4503b0['a']['DELAYLOADSTATE_NOTLOADED'])return _0x5588f7['mesh']['_checkDelayState'](),this;if(_0x5588f7['mesh']['delayLoadState']===_0x4503b0['a']['DELAYLOADSTATE_LOADING'])return this;_0x5588f7['mesh']['_preActivate'](),_0x5588f7['mesh']['_updateSubMeshesBoundingInfo'](this['worldMatrixFromCache']);}return this['onLODLevelSelection']&&this['onLODLevelSelection'](_0x467324,this,_0x5588f7['mesh']),_0x5588f7['mesh'];}}return this['onLODLevelSelection']&&this['onLODLevelSelection'](_0x467324,this,this),this;},Object['defineProperty'](_0x249c5c['prototype'],'geometry',{'get':function(){return this['_geometry'];},'enumerable':!0x1,'configurable':!0x0}),_0x249c5c['prototype']['getTotalVertices']=function(){return null===this['_geometry']||void 0x0===this['_geometry']?0x0:this['_geometry']['getTotalVertices']();},_0x249c5c['prototype']['getVerticesData']=function(_0x495f7e,_0x275653,_0x43a6b0){return this['_geometry']?this['_geometry']['getVerticesData'](_0x495f7e,_0x275653,_0x43a6b0):null;},_0x249c5c['prototype']['getVertexBuffer']=function(_0x33b9bd){return this['_geometry']?this['_geometry']['getVertexBuffer'](_0x33b9bd):null;},_0x249c5c['prototype']['isVerticesDataPresent']=function(_0x3c67cd){return this['_geometry']?this['_geometry']['isVerticesDataPresent'](_0x3c67cd):!!this['_delayInfo']&&-0x1!==this['_delayInfo']['indexOf'](_0x3c67cd);},_0x249c5c['prototype']['isVertexBufferUpdatable']=function(_0x32aae8){return this['_geometry']?this['_geometry']['isVertexBufferUpdatable'](_0x32aae8):!!this['_delayInfo']&&-0x1!==this['_delayInfo']['indexOf'](_0x32aae8);},_0x249c5c['prototype']['getVerticesDataKinds']=function(){if(!this['_geometry']){var _0x2ca361=new Array();return this['_delayInfo']&&this['_delayInfo']['forEach'](function(_0x1f45a2){_0x2ca361['push'](_0x1f45a2);}),_0x2ca361;}return this['_geometry']['getVerticesDataKinds']();},_0x249c5c['prototype']['getTotalIndices']=function(){return this['_geometry']?this['_geometry']['getTotalIndices']():0x0;},_0x249c5c['prototype']['getIndices']=function(_0x215f04,_0x43b9e3){return this['_geometry']?this['_geometry']['getIndices'](_0x215f04,_0x43b9e3):[];},Object['defineProperty'](_0x249c5c['prototype'],'isBlocked',{'get':function(){return null!==this['_masterMesh']&&void 0x0!==this['_masterMesh'];},'enumerable':!0x1,'configurable':!0x0}),_0x249c5c['prototype']['isReady']=function(_0x134bba,_0x125dd8){var _0x5df1f7,_0x906574,_0x17b7c9,_0xd26156,_0x1c56d5,_0x1b0946;if(void 0x0===_0x134bba&&(_0x134bba=!0x1),void 0x0===_0x125dd8&&(_0x125dd8=!0x1),this['delayLoadState']===_0x4503b0['a']['DELAYLOADSTATE_LOADING'])return!0x1;if(!_0x8effd0['prototype']['isReady']['call'](this,_0x134bba))return!0x1;if(!this['subMeshes']||0x0===this['subMeshes']['length'])return!0x0;if(!_0x134bba)return!0x0;var _0x1d806d=this['getEngine'](),_0x563147=this['getScene'](),_0x254ac6=_0x125dd8||_0x1d806d['getCaps']()['instancedArrays']&&(this['instances']['length']>0x0||this['hasThinInstances']);this['computeWorldMatrix']();var _0x3fe236=this['material']||_0x563147['defaultMaterial'];if(_0x3fe236){if(_0x3fe236['_storeEffectOnSubMeshes'])for(var _0x376a4d=0x0,_0x41cf3a=this['subMeshes'];_0x376a4d<_0x41cf3a['length'];_0x376a4d++){var _0x433209=(_0x54ffbc=_0x41cf3a[_0x376a4d])['getMaterial']();if(_0x433209){if(_0x433209['_storeEffectOnSubMeshes']){if(!_0x433209['isReadyForSubMesh'](this,_0x54ffbc,_0x254ac6))return!0x1;}else{if(!_0x433209['isReady'](this,_0x254ac6))return!0x1;}}}else{if(!_0x3fe236['isReady'](this,_0x254ac6))return!0x1;}}for(var _0x445577=0x0,_0x17b41b=this['lightSources'];_0x445577<_0x17b41b['length'];_0x445577++){var _0x211ad1=_0x17b41b[_0x445577]['getShadowGenerator']();if(_0x211ad1&&(!(null===(_0x5df1f7=_0x211ad1['getShadowMap']())||void 0x0===_0x5df1f7?void 0x0:_0x5df1f7['renderList'])||(null===(_0x906574=_0x211ad1['getShadowMap']())||void 0x0===_0x906574?void 0x0:_0x906574['renderList'])&&-0x1!==(null===(_0xd26156=null===(_0x17b7c9=_0x211ad1['getShadowMap']())||void 0x0===_0x17b7c9?void 0x0:_0x17b7c9['renderList'])||void 0x0===_0xd26156?void 0x0:_0xd26156['indexOf'](this))))for(var _0x3a9b4e=0x0,_0x39c7c1=this['subMeshes'];_0x3a9b4e<_0x39c7c1['length'];_0x3a9b4e++){var _0x54ffbc=_0x39c7c1[_0x3a9b4e];if(!_0x211ad1['isReady'](_0x54ffbc,_0x254ac6,null!==(_0x1b0946=null===(_0x1c56d5=_0x54ffbc['getMaterial']())||void 0x0===_0x1c56d5?void 0x0:_0x1c56d5['needAlphaBlendingForMesh'](this))&&void 0x0!==_0x1b0946&&_0x1b0946))return!0x1;}}for(var _0x42f10e=0x0,_0x24fac9=this['_internalMeshDataInfo']['_LODLevels'];_0x42f10e<_0x24fac9['length'];_0x42f10e++){var _0x2af197=_0x24fac9[_0x42f10e];if(_0x2af197['mesh']&&!_0x2af197['mesh']['isReady'](_0x254ac6))return!0x1;}return!0x0;},Object['defineProperty'](_0x249c5c['prototype'],'areNormalsFrozen',{'get':function(){return this['_internalMeshDataInfo']['_areNormalsFrozen'];},'enumerable':!0x1,'configurable':!0x0}),_0x249c5c['prototype']['freezeNormals']=function(){return this['_internalMeshDataInfo']['_areNormalsFrozen']=!0x0,this;},_0x249c5c['prototype']['unfreezeNormals']=function(){return this['_internalMeshDataInfo']['_areNormalsFrozen']=!0x1,this;},Object['defineProperty'](_0x249c5c['prototype'],'overridenInstanceCount',{'set':function(_0x55e93a){this['_instanceDataStorage']['overridenInstanceCount']=_0x55e93a;},'enumerable':!0x1,'configurable':!0x0}),_0x249c5c['prototype']['_preActivate']=function(){var _0x4b638f=this['_internalMeshDataInfo'],_0xc8a70e=this['getScene']()['getRenderId']();return _0x4b638f['_preActivateId']===_0xc8a70e||(_0x4b638f['_preActivateId']=_0xc8a70e,this['_instanceDataStorage']['visibleInstances']=null),this;},_0x249c5c['prototype']['_preActivateForIntermediateRendering']=function(_0x4c2c9c){return this['_instanceDataStorage']['visibleInstances']&&(this['_instanceDataStorage']['visibleInstances']['intermediateDefaultRenderId']=_0x4c2c9c),this;},_0x249c5c['prototype']['_registerInstanceForRenderId']=function(_0x3f6c36,_0x35af4f){return this['_instanceDataStorage']['visibleInstances']||(this['_instanceDataStorage']['visibleInstances']={'defaultRenderId':_0x35af4f,'selfDefaultRenderId':this['_renderId']}),this['_instanceDataStorage']['visibleInstances'][_0x35af4f]||(void 0x0!==this['_instanceDataStorage']['previousRenderId']&&this['_instanceDataStorage']['isFrozen']&&(this['_instanceDataStorage']['visibleInstances'][this['_instanceDataStorage']['previousRenderId']]=null),this['_instanceDataStorage']['previousRenderId']=_0x35af4f,this['_instanceDataStorage']['visibleInstances'][_0x35af4f]=new Array()),this['_instanceDataStorage']['visibleInstances'][_0x35af4f]['push'](_0x3f6c36),this;},_0x249c5c['prototype']['_afterComputeWorldMatrix']=function(){_0x8effd0['prototype']['_afterComputeWorldMatrix']['call'](this),this['hasThinInstances']&&(this['doNotSyncBoundingInfo']||this['thinInstanceRefreshBoundingInfo'](!0x1));},_0x249c5c['prototype']['_postActivate']=function(){this['edgesShareWithInstances']&&this['edgesRenderer']&&this['edgesRenderer']['isEnabled']&&this['_renderingGroup']&&(this['_renderingGroup']['_edgesRenderers']['pushNoDuplicate'](this['edgesRenderer']),this['edgesRenderer']['customInstances']['push'](this['getWorldMatrix']()));},_0x249c5c['prototype']['refreshBoundingInfo']=function(_0x5232a0){if(void 0x0===_0x5232a0&&(_0x5232a0=!0x1),this['_boundingInfo']&&this['_boundingInfo']['isLocked'])return this;var _0x5a232f=this['geometry']?this['geometry']['boundingBias']:null;return this['_refreshBoundingInfo'](this['_getPositionData'](_0x5232a0),_0x5a232f),this;},_0x249c5c['prototype']['_createGlobalSubMesh']=function(_0x2743f4){var _0x1cbbd7=this['getTotalVertices']();if(!_0x1cbbd7||!this['getIndices']())return null;if(this['subMeshes']&&this['subMeshes']['length']>0x0){var _0x2e618f=this['getIndices']();if(!_0x2e618f)return null;var _0x388c36=_0x2e618f['length'],_0x3e2800=!0x1;if(_0x2743f4)_0x3e2800=!0x0;else for(var _0x1bfa83=0x0,_0x56f878=this['subMeshes'];_0x1bfa83<_0x56f878['length'];_0x1bfa83++){var _0x2c1658=_0x56f878[_0x1bfa83];if(_0x2c1658['indexStart']+_0x2c1658['indexCount']>_0x388c36){_0x3e2800=!0x0;break;}if(_0x2c1658['verticesStart']+_0x2c1658['verticesCount']>_0x1cbbd7){_0x3e2800=!0x0;break;}}if(!_0x3e2800)return this['subMeshes'][0x0];}return this['releaseSubMeshes'](),new _0x452130['a'](0x0,0x0,_0x1cbbd7,0x0,this['getTotalIndices'](),this);},_0x249c5c['prototype']['subdivide']=function(_0x1a908e){if(!(_0x1a908e<0x1)){for(var _0x6171b5=this['getTotalIndices'](),_0x38ee22=_0x6171b5/_0x1a908e|0x0,_0x4c2ed9=0x0;_0x38ee22%0x3!=0x0;)_0x38ee22++;this['releaseSubMeshes']();for(var _0x1e3169=0x0;_0x1e3169<_0x1a908e&&!(_0x4c2ed9>=_0x6171b5);_0x1e3169++)_0x452130['a']['CreateFromIndices'](0x0,_0x4c2ed9,_0x1e3169===_0x1a908e-0x1?_0x6171b5-_0x4c2ed9:_0x38ee22,this),_0x4c2ed9+=_0x38ee22;this['synchronizeInstances']();}},_0x249c5c['prototype']['setVerticesData']=function(_0x54b129,_0x192a80,_0x40947c,_0x549840){if(void 0x0===_0x40947c&&(_0x40947c=!0x1),this['_geometry'])this['_geometry']['setVerticesData'](_0x54b129,_0x192a80,_0x40947c,_0x549840);else{var _0x5725c6=new _0x148cfc['a']();_0x5725c6['set'](_0x192a80,_0x54b129);var _0x46e555=this['getScene']();new _0x21ffea['a'](_0x21ffea['a']['RandomId'](),_0x46e555,_0x5725c6,_0x40947c,this);}return this;},_0x249c5c['prototype']['removeVerticesData']=function(_0x27cb05){this['_geometry']&&this['_geometry']['removeVerticesData'](_0x27cb05);},_0x249c5c['prototype']['markVerticesDataAsUpdatable']=function(_0x2ef1ce,_0x5dd143){void 0x0===_0x5dd143&&(_0x5dd143=!0x0);var _0x2396c9=this['getVertexBuffer'](_0x2ef1ce);_0x2396c9&&_0x2396c9['isUpdatable']()!==_0x5dd143&&this['setVerticesData'](_0x2ef1ce,this['getVerticesData'](_0x2ef1ce),_0x5dd143);},_0x249c5c['prototype']['setVerticesBuffer']=function(_0x4a934e){return this['_geometry']||(this['_geometry']=_0x21ffea['a']['CreateGeometryForMesh'](this)),this['_geometry']['setVerticesBuffer'](_0x4a934e),this;},_0x249c5c['prototype']['updateVerticesData']=function(_0x2e1fa1,_0x59a5be,_0x2bb507,_0x52b02d){return this['_geometry']?(_0x52b02d?(this['makeGeometryUnique'](),this['updateVerticesData'](_0x2e1fa1,_0x59a5be,_0x2bb507,!0x1)):this['_geometry']['updateVerticesData'](_0x2e1fa1,_0x59a5be,_0x2bb507),this):this;},_0x249c5c['prototype']['updateMeshPositions']=function(_0x3c066d,_0x435952){void 0x0===_0x435952&&(_0x435952=!0x0);var _0x2cac21=this['getVerticesData'](_0x46dc40['b']['PositionKind']);if(!_0x2cac21)return this;if(_0x3c066d(_0x2cac21),this['updateVerticesData'](_0x46dc40['b']['PositionKind'],_0x2cac21,!0x1,!0x1),_0x435952){var _0x479085=this['getIndices'](),_0x48907a=this['getVerticesData'](_0x46dc40['b']['NormalKind']);if(!_0x48907a)return this;_0x148cfc['a']['ComputeNormals'](_0x2cac21,_0x479085,_0x48907a),this['updateVerticesData'](_0x46dc40['b']['NormalKind'],_0x48907a,!0x1,!0x1);}return this;},_0x249c5c['prototype']['makeGeometryUnique']=function(){if(!this['_geometry'])return this;if(0x1===this['_geometry']['meshes']['length'])return this;var _0x3f06a0=this['_geometry'],_0x404884=this['_geometry']['copy'](_0x21ffea['a']['RandomId']());return _0x3f06a0['releaseForMesh'](this,!0x0),_0x404884['applyToMesh'](this),this;},_0x249c5c['prototype']['setIndices']=function(_0x48784a,_0x3d94cd,_0x458fcd){if(void 0x0===_0x3d94cd&&(_0x3d94cd=null),void 0x0===_0x458fcd&&(_0x458fcd=!0x1),this['_geometry'])this['_geometry']['setIndices'](_0x48784a,_0x3d94cd,_0x458fcd);else{var _0x16f8bb=new _0x148cfc['a']();_0x16f8bb['indices']=_0x48784a;var _0x5d1bfd=this['getScene']();new _0x21ffea['a'](_0x21ffea['a']['RandomId'](),_0x5d1bfd,_0x16f8bb,_0x458fcd,this);}return this;},_0x249c5c['prototype']['updateIndices']=function(_0x235398,_0x1eee0f,_0x1032b2){return void 0x0===_0x1032b2&&(_0x1032b2=!0x1),this['_geometry']?(this['_geometry']['updateIndices'](_0x235398,_0x1eee0f,_0x1032b2),this):this;},_0x249c5c['prototype']['toLeftHanded']=function(){return this['_geometry']?(this['_geometry']['toLeftHanded'](),this):this;},_0x249c5c['prototype']['_bind']=function(_0x19e889,_0x3e7b1a,_0x14e09e){if(!this['_geometry'])return this;var _0x3e2904,_0x47e407=this['getScene']()['getEngine']();if(this['_unIndexed'])_0x3e2904=null;else switch(_0x14e09e){case _0x24f49e['a']['PointFillMode']:_0x3e2904=null;break;case _0x24f49e['a']['WireFrameFillMode']:_0x3e2904=_0x19e889['_getLinesIndexBuffer'](this['getIndices'](),_0x47e407);break;default:case _0x24f49e['a']['TriangleFillMode']:_0x3e2904=this['_geometry']['getIndexBuffer']();}return this['_geometry']['_bind'](_0x3e7b1a,_0x3e2904),this;},_0x249c5c['prototype']['_draw']=function(_0x5466fe,_0x258b45,_0x474fea){if(!this['_geometry']||!this['_geometry']['getVertexBuffers']()||!this['_unIndexed']&&!this['_geometry']['getIndexBuffer']())return this;this['_internalMeshDataInfo']['_onBeforeDrawObservable']&&this['_internalMeshDataInfo']['_onBeforeDrawObservable']['notifyObservers'](this);var _0x24cbff=this['getScene']()['getEngine']();return this['_unIndexed']||_0x258b45==_0x24f49e['a']['PointFillMode']?_0x24cbff['drawArraysType'](_0x258b45,_0x5466fe['verticesStart'],_0x5466fe['verticesCount'],_0x474fea):_0x258b45==_0x24f49e['a']['WireFrameFillMode']?_0x24cbff['drawElementsType'](_0x258b45,0x0,_0x5466fe['_linesIndexCount'],_0x474fea):_0x24cbff['drawElementsType'](_0x258b45,_0x5466fe['indexStart'],_0x5466fe['indexCount'],_0x474fea),this;},_0x249c5c['prototype']['registerBeforeRender']=function(_0x25b12a){return this['onBeforeRenderObservable']['add'](_0x25b12a),this;},_0x249c5c['prototype']['unregisterBeforeRender']=function(_0x441f8b){return this['onBeforeRenderObservable']['removeCallback'](_0x441f8b),this;},_0x249c5c['prototype']['registerAfterRender']=function(_0xb6e3fd){return this['onAfterRenderObservable']['add'](_0xb6e3fd),this;},_0x249c5c['prototype']['unregisterAfterRender']=function(_0x3d91a7){return this['onAfterRenderObservable']['removeCallback'](_0x3d91a7),this;},_0x249c5c['prototype']['_getInstancesRenderList']=function(_0x136eff,_0x3588c3){if(void 0x0===_0x3588c3&&(_0x3588c3=!0x1),this['_instanceDataStorage']['isFrozen']&&this['_instanceDataStorage']['previousBatch'])return this['_instanceDataStorage']['previousBatch'];var _0xd04008=this['getScene'](),_0x408a83=_0xd04008['_isInIntermediateRendering'](),_0x2deca1=_0x408a83?this['_internalAbstractMeshDataInfo']['_onlyForInstancesIntermediate']:this['_internalAbstractMeshDataInfo']['_onlyForInstances'],_0xb9dcbc=this['_instanceDataStorage']['batchCache'];if(_0xb9dcbc['mustReturn']=!0x1,_0xb9dcbc['renderSelf'][_0x136eff]=_0x3588c3||!_0x2deca1&&this['isEnabled']()&&this['isVisible'],_0xb9dcbc['visibleInstances'][_0x136eff]=null,this['_instanceDataStorage']['visibleInstances']&&!_0x3588c3){var _0xe1dcb7=this['_instanceDataStorage']['visibleInstances'],_0x3a4967=_0xd04008['getRenderId'](),_0x11c2cc=_0x408a83?_0xe1dcb7['intermediateDefaultRenderId']:_0xe1dcb7['defaultRenderId'];_0xb9dcbc['visibleInstances'][_0x136eff]=_0xe1dcb7[_0x3a4967],!_0xb9dcbc['visibleInstances'][_0x136eff]&&_0x11c2cc&&(_0xb9dcbc['visibleInstances'][_0x136eff]=_0xe1dcb7[_0x11c2cc]);}return _0xb9dcbc['hardwareInstancedRendering'][_0x136eff]=!_0x3588c3&&this['_instanceDataStorage']['hardwareInstancedRendering']&&null!==_0xb9dcbc['visibleInstances'][_0x136eff]&&void 0x0!==_0xb9dcbc['visibleInstances'][_0x136eff],this['_instanceDataStorage']['previousBatch']=_0xb9dcbc,_0xb9dcbc;},_0x249c5c['prototype']['_renderWithInstances']=function(_0x2e69bd,_0x443d07,_0xbad911,_0x5758b9,_0x1cd9e1){var _0x5e9351=_0xbad911['visibleInstances'][_0x2e69bd['_id']];if(!_0x5e9351)return this;for(var _0x3948df=this['_instanceDataStorage'],_0x438f30=_0x3948df['instancesBufferSize'],_0x5c4b03=_0x3948df['instancesBuffer'],_0x9c448a=0x10*(_0x5e9351['length']+0x1)*0x4;_0x3948df['instancesBufferSize']<_0x9c448a;)_0x3948df['instancesBufferSize']*=0x2;_0x3948df['instancesData']&&_0x438f30==_0x3948df['instancesBufferSize']||(_0x3948df['instancesData']=new Float32Array(_0x3948df['instancesBufferSize']/0x4));var _0x343623=0x0,_0x2f076e=0x0,_0x3b9ec3=_0xbad911['renderSelf'][_0x2e69bd['_id']],_0x11ec35=!_0x5c4b03||_0x438f30!==_0x3948df['instancesBufferSize'];if(this['_instanceDataStorage']['manualUpdate']||_0x3948df['isFrozen']&&!_0x11ec35)_0x2f076e=(_0x3b9ec3?0x1:0x0)+_0x5e9351['length'];else{var _0x122281=this['_effectiveMesh']['getWorldMatrix']();if(_0x3b9ec3&&(_0x122281['copyToArray'](_0x3948df['instancesData'],_0x343623),_0x343623+=0x10,_0x2f076e++),_0x5e9351)for(var _0x3a0476=0x0;_0x3a0476<_0x5e9351['length'];_0x3a0476++){_0x5e9351[_0x3a0476]['getWorldMatrix']()['copyToArray'](_0x3948df['instancesData'],_0x343623),_0x343623+=0x10,_0x2f076e++;}}return _0x11ec35?(_0x5c4b03&&_0x5c4b03['dispose'](),_0x5c4b03=new _0x46dc40['a'](_0x1cd9e1,_0x3948df['instancesData'],!0x0,0x10,!0x1,!0x0),_0x3948df['instancesBuffer']=_0x5c4b03,this['setVerticesBuffer'](_0x5c4b03['createVertexBuffer']('world0',0x0,0x4)),this['setVerticesBuffer'](_0x5c4b03['createVertexBuffer']('world1',0x4,0x4)),this['setVerticesBuffer'](_0x5c4b03['createVertexBuffer']('world2',0x8,0x4)),this['setVerticesBuffer'](_0x5c4b03['createVertexBuffer']('world3',0xc,0x4))):this['_instanceDataStorage']['isFrozen']||_0x5c4b03['updateDirectly'](_0x3948df['instancesData'],0x0,_0x2f076e),this['_processInstancedBuffers'](_0x5e9351,_0x3b9ec3),this['getScene']()['_activeIndices']['addCount'](_0x2e69bd['indexCount']*_0x2f076e,!0x1),this['_bind'](_0x2e69bd,_0x5758b9,_0x443d07),this['_draw'](_0x2e69bd,_0x443d07,_0x2f076e),_0x1cd9e1['unbindInstanceAttributes'](),this;},_0x249c5c['prototype']['_renderWithThinInstances']=function(_0x36a24d,_0x2a7fa3,_0x45bfd9,_0x34d916){var _0x20a46b,_0x2edbba,_0x4c1373=null!==(_0x2edbba=null===(_0x20a46b=this['_thinInstanceDataStorage'])||void 0x0===_0x20a46b?void 0x0:_0x20a46b['instancesCount'])&&void 0x0!==_0x2edbba?_0x2edbba:0x0;this['getScene']()['_activeIndices']['addCount'](_0x36a24d['indexCount']*_0x4c1373,!0x1),this['_bind'](_0x36a24d,_0x45bfd9,_0x2a7fa3),this['_draw'](_0x36a24d,_0x2a7fa3,_0x4c1373),_0x34d916['unbindInstanceAttributes']();},_0x249c5c['prototype']['_processInstancedBuffers']=function(_0x1f4c70,_0x22c42b){},_0x249c5c['prototype']['_processRendering']=function(_0x97f9e6,_0x316d86,_0x405962,_0x8dd2be,_0x877d1c,_0x755447,_0x2ce35a,_0x54cc51){var _0x424ed8=this['getScene'](),_0x5e118c=_0x424ed8['getEngine']();if(_0x755447&&_0x316d86['getRenderingMesh']()['hasThinInstances'])return this['_renderWithThinInstances'](_0x316d86,_0x8dd2be,_0x405962,_0x5e118c),this;if(_0x755447)this['_renderWithInstances'](_0x316d86,_0x8dd2be,_0x877d1c,_0x405962,_0x5e118c);else{var _0x3f69c2=0x0;_0x877d1c['renderSelf'][_0x316d86['_id']]&&(_0x2ce35a&&_0x2ce35a(!0x1,_0x97f9e6['_effectiveMesh']['getWorldMatrix'](),_0x54cc51),_0x3f69c2++,this['_draw'](_0x316d86,_0x8dd2be,this['_instanceDataStorage']['overridenInstanceCount']));var _0x2a6ed5=_0x877d1c['visibleInstances'][_0x316d86['_id']];if(_0x2a6ed5){var _0x57b66b=_0x2a6ed5['length'];_0x3f69c2+=_0x57b66b;for(var _0x471577=0x0;_0x471577<_0x57b66b;_0x471577++){var _0x324d35=_0x2a6ed5[_0x471577]['getWorldMatrix']();_0x2ce35a&&_0x2ce35a(!0x0,_0x324d35,_0x54cc51),this['_draw'](_0x316d86,_0x8dd2be);}}_0x424ed8['_activeIndices']['addCount'](_0x316d86['indexCount']*_0x3f69c2,!0x1);}return this;},_0x249c5c['prototype']['_rebuild']=function(){this['_instanceDataStorage']['instancesBuffer']&&(this['_instanceDataStorage']['instancesBuffer']['dispose'](),this['_instanceDataStorage']['instancesBuffer']=null),_0x8effd0['prototype']['_rebuild']['call'](this);},_0x249c5c['prototype']['_freeze']=function(){if(this['subMeshes']){for(var _0x4ca481=0x0;_0x4ca481_0x4cf051&&_0x47701c++,0x0!==_0x216a25&&_0x2b0dda++,_0x1b832d+=_0x216a25,_0x4cf051=_0x216a25;}if(_0x469fb3[_0x2b0dda]++,_0x2b0dda>_0x600931&&(_0x600931=_0x2b0dda),0x0===_0x1b832d)_0x37a66b++;else{var _0x153abd=0x1/_0x1b832d,_0x57b6ad=0x0;for(_0x4c322b=0x0;_0x4c322b<_0x11a87e;_0x4c322b++)_0x57b6ad+=_0x4c322b<0x4?Math['abs'](_0x265e76[_0x1f2459+_0x4c322b]-_0x265e76[_0x1f2459+_0x4c322b]*_0x153abd):Math['abs'](_0x1d6421[_0x1f2459+_0x4c322b-0x4]-_0x1d6421[_0x1f2459+_0x4c322b-0x4]*_0x153abd);_0x57b6ad>0.001&&_0x1ace1d++;}}var _0x51610c=this['skeleton']['bones']['length'],_0x2f38f7=this['getVerticesData'](_0x46dc40['b']['MatricesIndicesKind']),_0x404f36=this['getVerticesData'](_0x46dc40['b']['MatricesIndicesExtraKind']),_0x1f7e05=0x0;for(_0x1f2459=0x0;_0x1f2459<_0x2f71a5;_0x1f2459+=0x4)for(_0x4c322b=0x0;_0x4c322b<_0x11a87e;_0x4c322b++){var _0x21c0cd=_0x4c322b<0x4?_0x2f38f7[_0x1f2459+_0x4c322b]:_0x404f36[_0x1f2459+_0x4c322b-0x4];(_0x21c0cd>=_0x51610c||_0x21c0cd<0x0)&&_0x1f7e05++;}return{'skinned':!0x0,'valid':0x0===_0x37a66b&&0x0===_0x1ace1d&&0x0===_0x1f7e05,'report':'Number\x20of\x20Weights\x20=\x20'+_0x2f71a5/0x4+'\x0aMaximum\x20influences\x20=\x20'+_0x600931+'\x0aMissing\x20Weights\x20=\x20'+_0x37a66b+'\x0aNot\x20Sorted\x20=\x20'+_0x47701c+'\x0aNot\x20Normalized\x20=\x20'+_0x1ace1d+'\x0aWeightCounts\x20=\x20['+_0x469fb3+']\x0aNumber\x20of\x20bones\x20=\x20'+_0x51610c+'\x0aBad\x20Bone\x20Indices\x20=\x20'+_0x1f7e05};},_0x249c5c['prototype']['_checkDelayState']=function(){var _0x6b47ac=this['getScene']();return this['_geometry']?this['_geometry']['load'](_0x6b47ac):this['delayLoadState']===_0x4503b0['a']['DELAYLOADSTATE_NOTLOADED']&&(this['delayLoadState']=_0x4503b0['a']['DELAYLOADSTATE_LOADING'],this['_queueLoad'](_0x6b47ac)),this;},_0x249c5c['prototype']['_queueLoad']=function(_0x20147d){var _0x555bad=this;_0x20147d['_addPendingData'](this);var _0x341b8f=-0x1!==this['delayLoadingFile']['indexOf']('.babylonbinarymeshdata');return _0x15f0a7['b']['LoadFile'](this['delayLoadingFile'],function(_0x4a4e5d){_0x4a4e5d instanceof ArrayBuffer?_0x555bad['_delayLoadingFunction'](_0x4a4e5d,_0x555bad):_0x555bad['_delayLoadingFunction'](JSON['parse'](_0x4a4e5d),_0x555bad),_0x555bad['instances']['forEach'](function(_0x2c53a1){_0x2c53a1['refreshBoundingInfo'](),_0x2c53a1['_syncSubMeshes']();}),_0x555bad['delayLoadState']=_0x4503b0['a']['DELAYLOADSTATE_LOADED'],_0x20147d['_removePendingData'](_0x555bad);},function(){},_0x20147d['offlineProvider'],_0x341b8f),this;},_0x249c5c['prototype']['isInFrustum']=function(_0x3e0be6){return this['delayLoadState']!==_0x4503b0['a']['DELAYLOADSTATE_LOADING']&&(!!_0x8effd0['prototype']['isInFrustum']['call'](this,_0x3e0be6)&&(this['_checkDelayState'](),!0x0));},_0x249c5c['prototype']['setMaterialByID']=function(_0x49debe){var _0xa5c22a,_0x3afc33=this['getScene']()['materials'];for(_0xa5c22a=_0x3afc33['length']-0x1;_0xa5c22a>-0x1;_0xa5c22a--)if(_0x3afc33[_0xa5c22a]['id']===_0x49debe)return this['material']=_0x3afc33[_0xa5c22a],this;var _0x5a7cd7=this['getScene']()['multiMaterials'];for(_0xa5c22a=_0x5a7cd7['length']-0x1;_0xa5c22a>-0x1;_0xa5c22a--)if(_0x5a7cd7[_0xa5c22a]['id']===_0x49debe)return this['material']=_0x5a7cd7[_0xa5c22a],this;return this;},_0x249c5c['prototype']['getAnimatables']=function(){var _0x536ef1=new Array();return this['material']&&_0x536ef1['push'](this['material']),this['skeleton']&&_0x536ef1['push'](this['skeleton']),_0x536ef1;},_0x249c5c['prototype']['bakeTransformIntoVertices']=function(_0x13d8be){if(!this['isVerticesDataPresent'](_0x46dc40['b']['PositionKind']))return this;var _0x3243eb=this['subMeshes']['splice'](0x0);this['_resetPointsArrayCache']();var _0x5551d0,_0x16ef16=this['getVerticesData'](_0x46dc40['b']['PositionKind']),_0x1f55eb=new Array();for(_0x5551d0=0x0;_0x5551d0<_0x16ef16['length'];_0x5551d0+=0x3)_0xfcdde3['e']['TransformCoordinates'](_0xfcdde3['e']['FromArray'](_0x16ef16,_0x5551d0),_0x13d8be)['toArray'](_0x1f55eb,_0x5551d0);if(this['setVerticesData'](_0x46dc40['b']['PositionKind'],_0x1f55eb,this['getVertexBuffer'](_0x46dc40['b']['PositionKind'])['isUpdatable']()),this['isVerticesDataPresent'](_0x46dc40['b']['NormalKind'])){for(_0x16ef16=this['getVerticesData'](_0x46dc40['b']['NormalKind']),_0x1f55eb=[],_0x5551d0=0x0;_0x5551d0<_0x16ef16['length'];_0x5551d0+=0x3)_0xfcdde3['e']['TransformNormal'](_0xfcdde3['e']['FromArray'](_0x16ef16,_0x5551d0),_0x13d8be)['normalize']()['toArray'](_0x1f55eb,_0x5551d0);this['setVerticesData'](_0x46dc40['b']['NormalKind'],_0x1f55eb,this['getVertexBuffer'](_0x46dc40['b']['NormalKind'])['isUpdatable']());}return _0x13d8be['m'][0x0]*_0x13d8be['m'][0x5]*_0x13d8be['m'][0xa]<0x0&&this['flipFaces'](),this['releaseSubMeshes'](),this['subMeshes']=_0x3243eb,this;},_0x249c5c['prototype']['bakeCurrentTransformIntoVertices']=function(_0x46ff58){return void 0x0===_0x46ff58&&(_0x46ff58=!0x0),this['bakeTransformIntoVertices'](this['computeWorldMatrix'](!0x0)),this['resetLocalMatrix'](_0x46ff58),this;},Object['defineProperty'](_0x249c5c['prototype'],'_positions',{'get':function(){return this['_geometry']?this['_geometry']['_positions']:null;},'enumerable':!0x1,'configurable':!0x0}),_0x249c5c['prototype']['_resetPointsArrayCache']=function(){return this['_geometry']&&this['_geometry']['_resetPointsArrayCache'](),this;},_0x249c5c['prototype']['_generatePointsArray']=function(){return!!this['_geometry']&&this['_geometry']['_generatePointsArray']();},_0x249c5c['prototype']['clone']=function(_0x30c0f3,_0x24704b,_0x3b8366,_0x4d6e55){return void 0x0===_0x30c0f3&&(_0x30c0f3=''),void 0x0===_0x24704b&&(_0x24704b=null),void 0x0===_0x4d6e55&&(_0x4d6e55=!0x0),new _0x249c5c(_0x30c0f3,this['getScene'](),_0x24704b,this,_0x3b8366,_0x4d6e55);},_0x249c5c['prototype']['dispose']=function(_0x2101ec,_0x5c28a3){void 0x0===_0x5c28a3&&(_0x5c28a3=!0x1),this['morphTargetManager']=null,this['_geometry']&&this['_geometry']['releaseForMesh'](this,!0x0);var _0x55cea7=this['_internalMeshDataInfo'];if(_0x55cea7['_onBeforeDrawObservable']&&_0x55cea7['_onBeforeDrawObservable']['clear'](),_0x55cea7['_onBeforeBindObservable']&&_0x55cea7['_onBeforeBindObservable']['clear'](),_0x55cea7['_onBeforeRenderObservable']&&_0x55cea7['_onBeforeRenderObservable']['clear'](),_0x55cea7['_onAfterRenderObservable']&&_0x55cea7['_onAfterRenderObservable']['clear'](),this['_scene']['useClonedMeshMap']){if(_0x55cea7['meshMap'])for(var _0x1fcfd4 in _0x55cea7['meshMap']){(_0x5857d7=_0x55cea7['meshMap'][_0x1fcfd4])&&(_0x5857d7['_internalMeshDataInfo']['_source']=null,_0x55cea7['meshMap'][_0x1fcfd4]=void 0x0);}_0x55cea7['_source']&&_0x55cea7['_source']['_internalMeshDataInfo']['meshMap']&&(_0x55cea7['_source']['_internalMeshDataInfo']['meshMap'][this['uniqueId']]=void 0x0);}else for(var _0x908d56=0x0,_0x3bc6e0=this['getScene']()['meshes'];_0x908d56<_0x3bc6e0['length'];_0x908d56++){var _0x5857d7;(_0x5857d7=_0x3bc6e0[_0x908d56])['_internalMeshDataInfo']&&_0x5857d7['_internalMeshDataInfo']['_source']&&_0x5857d7['_internalMeshDataInfo']['_source']===this&&(_0x5857d7['_internalMeshDataInfo']['_source']=null);}_0x55cea7['_source']=null,this['_disposeInstanceSpecificData'](),this['_disposeThinInstanceSpecificData'](),_0x8effd0['prototype']['dispose']['call'](this,_0x2101ec,_0x5c28a3);},_0x249c5c['prototype']['_disposeInstanceSpecificData']=function(){},_0x249c5c['prototype']['_disposeThinInstanceSpecificData']=function(){},_0x249c5c['prototype']['applyDisplacementMap']=function(_0xdee93a,_0x33f080,_0xfb5c9,_0x3bfef8,_0x327bae,_0x23df2a,_0x53ec16){var _0x3d6895=this;void 0x0===_0x53ec16&&(_0x53ec16=!0x1);var _0x46c193=this['getScene']();return _0x15f0a7['b']['LoadImage'](_0xdee93a,function(_0x15faaa){var _0x5cf892=_0x15faaa['width'],_0x31b16c=_0x15faaa['height'],_0x342259=_0x34c45a['a']['CreateCanvas'](_0x5cf892,_0x31b16c)['getContext']('2d');_0x342259['drawImage'](_0x15faaa,0x0,0x0);var _0x15a025=_0x342259['getImageData'](0x0,0x0,_0x5cf892,_0x31b16c)['data'];_0x3d6895['applyDisplacementMapFromBuffer'](_0x15a025,_0x5cf892,_0x31b16c,_0x33f080,_0xfb5c9,_0x327bae,_0x23df2a,_0x53ec16),_0x3bfef8&&_0x3bfef8(_0x3d6895);},function(){},_0x46c193['offlineProvider']),this;},_0x249c5c['prototype']['applyDisplacementMapFromBuffer']=function(_0x7d7aa6,_0x3e0751,_0x182ee1,_0x385d35,_0xa55449,_0x5ef2ca,_0x346293,_0x5bc19a){if(void 0x0===_0x5bc19a&&(_0x5bc19a=!0x1),!this['isVerticesDataPresent'](_0x46dc40['b']['PositionKind'])||!this['isVerticesDataPresent'](_0x46dc40['b']['NormalKind'])||!this['isVerticesDataPresent'](_0x46dc40['b']['UVKind']))return _0x1242ee['a']['Warn']('Cannot\x20call\x20applyDisplacementMap:\x20Given\x20mesh\x20is\x20not\x20complete.\x20Position,\x20Normal\x20or\x20UV\x20are\x20missing'),this;var _0x17e038=this['getVerticesData'](_0x46dc40['b']['PositionKind'],!0x0,!0x0),_0xb241e1=this['getVerticesData'](_0x46dc40['b']['NormalKind']),_0x3bb468=this['getVerticesData'](_0x46dc40['b']['UVKind']),_0x5956ae=_0xfcdde3['e']['Zero'](),_0x17c76a=_0xfcdde3['e']['Zero'](),_0x1f82ad=_0xfcdde3['d']['Zero']();_0x5ef2ca=_0x5ef2ca||_0xfcdde3['d']['Zero'](),_0x346293=_0x346293||new _0xfcdde3['d'](0x1,0x1);for(var _0x56ca40=0x0;_0x56ca40<_0x17e038['length'];_0x56ca40+=0x3){_0xfcdde3['e']['FromArrayToRef'](_0x17e038,_0x56ca40,_0x5956ae),_0xfcdde3['e']['FromArrayToRef'](_0xb241e1,_0x56ca40,_0x17c76a),_0xfcdde3['d']['FromArrayToRef'](_0x3bb468,_0x56ca40/0x3*0x2,_0x1f82ad);var _0x138cc6=0x4*((Math['abs'](_0x1f82ad['x']*_0x346293['x']+_0x5ef2ca['x']%0x1)*(_0x3e0751-0x1)%_0x3e0751|0x0)+(Math['abs'](_0x1f82ad['y']*_0x346293['y']+_0x5ef2ca['y']%0x1)*(_0x182ee1-0x1)%_0x182ee1|0x0)*_0x3e0751),_0x1b6aec=0.3*(_0x7d7aa6[_0x138cc6]/0xff)+0.59*(_0x7d7aa6[_0x138cc6+0x1]/0xff)+0.11*(_0x7d7aa6[_0x138cc6+0x2]/0xff);_0x17c76a['normalize'](),_0x17c76a['scaleInPlace'](_0x385d35+(_0xa55449-_0x385d35)*_0x1b6aec),(_0x5956ae=_0x5956ae['add'](_0x17c76a))['toArray'](_0x17e038,_0x56ca40);}return _0x148cfc['a']['ComputeNormals'](_0x17e038,this['getIndices'](),_0xb241e1),_0x5bc19a?(this['setVerticesData'](_0x46dc40['b']['PositionKind'],_0x17e038),this['setVerticesData'](_0x46dc40['b']['NormalKind'],_0xb241e1)):(this['updateVerticesData'](_0x46dc40['b']['PositionKind'],_0x17e038),this['updateVerticesData'](_0x46dc40['b']['NormalKind'],_0xb241e1)),this;},_0x249c5c['prototype']['convertToFlatShadedMesh']=function(){var _0x608ebd,_0x543f6f,_0x3d4762=this['getVerticesDataKinds'](),_0x506a9e={},_0xb289ed={},_0x353e3c={},_0x148769=!0x1;for(_0x608ebd=0x0;_0x608ebd<_0x3d4762['length'];_0x608ebd++){_0x543f6f=_0x3d4762[_0x608ebd];var _0x45806b=this['getVertexBuffer'](_0x543f6f);_0x543f6f!==_0x46dc40['b']['NormalKind']?(_0x506a9e[_0x543f6f]=_0x45806b,_0xb289ed[_0x543f6f]=_0x506a9e[_0x543f6f]['getData'](),_0x353e3c[_0x543f6f]=[]):(_0x148769=_0x45806b['isUpdatable'](),_0x3d4762['splice'](_0x608ebd,0x1),_0x608ebd--);}var _0x9fbf5,_0x2779aa=this['subMeshes']['slice'](0x0),_0x49e8b4=this['getIndices'](),_0x10ea6e=this['getTotalIndices']();for(_0x9fbf5=0x0;_0x9fbf5<_0x10ea6e;_0x9fbf5++){var _0x105bb7=_0x49e8b4[_0x9fbf5];for(_0x608ebd=0x0;_0x608ebd<_0x3d4762['length'];_0x608ebd++)for(var _0x257501=_0x506a9e[_0x543f6f=_0x3d4762[_0x608ebd]]['getStrideSize'](),_0x21a096=0x0;_0x21a096<_0x257501;_0x21a096++)_0x353e3c[_0x543f6f]['push'](_0xb289ed[_0x543f6f][_0x105bb7*_0x257501+_0x21a096]);}var _0x3bda58=[],_0xe1f21=_0x353e3c[_0x46dc40['b']['PositionKind']];for(_0x9fbf5=0x0;_0x9fbf5<_0x10ea6e;_0x9fbf5+=0x3){_0x49e8b4[_0x9fbf5]=_0x9fbf5,_0x49e8b4[_0x9fbf5+0x1]=_0x9fbf5+0x1,_0x49e8b4[_0x9fbf5+0x2]=_0x9fbf5+0x2;for(var _0x5b0a25=_0xfcdde3['e']['FromArray'](_0xe1f21,0x3*_0x9fbf5),_0x2e5c0e=_0xfcdde3['e']['FromArray'](_0xe1f21,0x3*(_0x9fbf5+0x1)),_0x3d5cb8=_0xfcdde3['e']['FromArray'](_0xe1f21,0x3*(_0x9fbf5+0x2)),_0x52716c=_0x5b0a25['subtract'](_0x2e5c0e),_0x95bf43=_0x3d5cb8['subtract'](_0x2e5c0e),_0x13a5c6=_0xfcdde3['e']['Normalize'](_0xfcdde3['e']['Cross'](_0x52716c,_0x95bf43)),_0x13e8dc=0x0;_0x13e8dc<0x3;_0x13e8dc++)_0x3bda58['push'](_0x13a5c6['x']),_0x3bda58['push'](_0x13a5c6['y']),_0x3bda58['push'](_0x13a5c6['z']);}for(this['setIndices'](_0x49e8b4),this['setVerticesData'](_0x46dc40['b']['NormalKind'],_0x3bda58,_0x148769),_0x608ebd=0x0;_0x608ebd<_0x3d4762['length'];_0x608ebd++)_0x543f6f=_0x3d4762[_0x608ebd],this['setVerticesData'](_0x543f6f,_0x353e3c[_0x543f6f],_0x506a9e[_0x543f6f]['isUpdatable']());this['releaseSubMeshes']();for(var _0x5bcee5=0x0;_0x5bcee5<_0x2779aa['length'];_0x5bcee5++){var _0x4ef10e=_0x2779aa[_0x5bcee5];_0x452130['a']['AddToMesh'](_0x4ef10e['materialIndex'],_0x4ef10e['indexStart'],_0x4ef10e['indexCount'],_0x4ef10e['indexStart'],_0x4ef10e['indexCount'],this);}return this['synchronizeInstances'](),this;},_0x249c5c['prototype']['convertToUnIndexedMesh']=function(){var _0x9cb81f,_0x27b7f7,_0x23fe80=this['getVerticesDataKinds'](),_0x159f27={},_0x1f333a={},_0x4b0191={};for(_0x9cb81f=0x0;_0x9cb81f<_0x23fe80['length'];_0x9cb81f++){_0x27b7f7=_0x23fe80[_0x9cb81f];var _0x326c62=this['getVertexBuffer'](_0x27b7f7);_0x159f27[_0x27b7f7]=_0x326c62,_0x1f333a[_0x27b7f7]=_0x159f27[_0x27b7f7]['getData'](),_0x4b0191[_0x27b7f7]=[];}var _0x558c7b,_0x487f36=this['subMeshes']['slice'](0x0),_0x4bbc54=this['getIndices'](),_0x14ee13=this['getTotalIndices']();for(_0x558c7b=0x0;_0x558c7b<_0x14ee13;_0x558c7b++){var _0x283a6f=_0x4bbc54[_0x558c7b];for(_0x9cb81f=0x0;_0x9cb81f<_0x23fe80['length'];_0x9cb81f++)for(var _0x57ecb4=_0x159f27[_0x27b7f7=_0x23fe80[_0x9cb81f]]['getStrideSize'](),_0x44e366=0x0;_0x44e366<_0x57ecb4;_0x44e366++)_0x4b0191[_0x27b7f7]['push'](_0x1f333a[_0x27b7f7][_0x283a6f*_0x57ecb4+_0x44e366]);}for(_0x558c7b=0x0;_0x558c7b<_0x14ee13;_0x558c7b+=0x3)_0x4bbc54[_0x558c7b]=_0x558c7b,_0x4bbc54[_0x558c7b+0x1]=_0x558c7b+0x1,_0x4bbc54[_0x558c7b+0x2]=_0x558c7b+0x2;for(this['setIndices'](_0x4bbc54),_0x9cb81f=0x0;_0x9cb81f<_0x23fe80['length'];_0x9cb81f++)_0x27b7f7=_0x23fe80[_0x9cb81f],this['setVerticesData'](_0x27b7f7,_0x4b0191[_0x27b7f7],_0x159f27[_0x27b7f7]['isUpdatable']());this['releaseSubMeshes']();for(var _0x4844e6=0x0;_0x4844e6<_0x487f36['length'];_0x4844e6++){var _0x627d7=_0x487f36[_0x4844e6];_0x452130['a']['AddToMesh'](_0x627d7['materialIndex'],_0x627d7['indexStart'],_0x627d7['indexCount'],_0x627d7['indexStart'],_0x627d7['indexCount'],this);}return this['_unIndexed']=!0x0,this['synchronizeInstances'](),this;},_0x249c5c['prototype']['flipFaces']=function(_0x5ab56d){void 0x0===_0x5ab56d&&(_0x5ab56d=!0x1);var _0x450d8d,_0x1c3f9b,_0x19a9f2=_0x148cfc['a']['ExtractFromMesh'](this);if(_0x5ab56d&&this['isVerticesDataPresent'](_0x46dc40['b']['NormalKind'])&&_0x19a9f2['normals']){for(_0x450d8d=0x0;_0x450d8d<_0x19a9f2['normals']['length'];_0x450d8d++)_0x19a9f2['normals'][_0x450d8d]*=-0x1;}if(_0x19a9f2['indices']){for(_0x450d8d=0x0;_0x450d8d<_0x19a9f2['indices']['length'];_0x450d8d+=0x3)_0x1c3f9b=_0x19a9f2['indices'][_0x450d8d+0x1],_0x19a9f2['indices'][_0x450d8d+0x1]=_0x19a9f2['indices'][_0x450d8d+0x2],_0x19a9f2['indices'][_0x450d8d+0x2]=_0x1c3f9b;}return _0x19a9f2['applyToMesh'](this,this['isVertexBufferUpdatable'](_0x46dc40['b']['PositionKind'])),this;},_0x249c5c['prototype']['increaseVertices']=function(_0x5e38a1){var _0x195e25=_0x148cfc['a']['ExtractFromMesh'](this),_0x3d0f2f=_0x195e25['uvs'],_0xef529e=_0x195e25['indices'],_0x4543a8=_0x195e25['positions'],_0x108201=_0x195e25['normals'];if(_0xef529e&&_0x4543a8&&_0x108201&&_0x3d0f2f){for(var _0x2cd79d,_0x267227,_0x466106=_0x5e38a1+0x1,_0x70d617=new Array(),_0x3a5664=0x0;_0x3a5664<_0x466106+0x1;_0x3a5664++)_0x70d617[_0x3a5664]=new Array();var _0x2697c4,_0x4bc255=new _0xfcdde3['e'](0x0,0x0,0x0),_0x2e30e7=new _0xfcdde3['e'](0x0,0x0,0x0),_0x5e574d=new _0xfcdde3['d'](0x0,0x0),_0x4197a3=new Array(),_0x26412a=new Array(),_0x197cfa=new Array(),_0x3acb0d=_0x4543a8['length'],_0x336368=_0x3d0f2f['length'];for(_0x3a5664=0x0;_0x3a5664<_0xef529e['length'];_0x3a5664+=0x3){_0x26412a[0x0]=_0xef529e[_0x3a5664],_0x26412a[0x1]=_0xef529e[_0x3a5664+0x1],_0x26412a[0x2]=_0xef529e[_0x3a5664+0x2];for(var _0x337890=0x0;_0x337890<0x3;_0x337890++)if(_0x2cd79d=_0x26412a[_0x337890],_0x267227=_0x26412a[(_0x337890+0x1)%0x3],void 0x0===_0x197cfa[_0x2cd79d]&&void 0x0===_0x197cfa[_0x267227]?(_0x197cfa[_0x2cd79d]=new Array(),_0x197cfa[_0x267227]=new Array()):(void 0x0===_0x197cfa[_0x2cd79d]&&(_0x197cfa[_0x2cd79d]=new Array()),void 0x0===_0x197cfa[_0x267227]&&(_0x197cfa[_0x267227]=new Array())),void 0x0===_0x197cfa[_0x2cd79d][_0x267227]&&void 0x0===_0x197cfa[_0x267227][_0x2cd79d]){_0x197cfa[_0x2cd79d][_0x267227]=[],_0x4bc255['x']=(_0x4543a8[0x3*_0x267227]-_0x4543a8[0x3*_0x2cd79d])/_0x466106,_0x4bc255['y']=(_0x4543a8[0x3*_0x267227+0x1]-_0x4543a8[0x3*_0x2cd79d+0x1])/_0x466106,_0x4bc255['z']=(_0x4543a8[0x3*_0x267227+0x2]-_0x4543a8[0x3*_0x2cd79d+0x2])/_0x466106,_0x2e30e7['x']=(_0x108201[0x3*_0x267227]-_0x108201[0x3*_0x2cd79d])/_0x466106,_0x2e30e7['y']=(_0x108201[0x3*_0x267227+0x1]-_0x108201[0x3*_0x2cd79d+0x1])/_0x466106,_0x2e30e7['z']=(_0x108201[0x3*_0x267227+0x2]-_0x108201[0x3*_0x2cd79d+0x2])/_0x466106,_0x5e574d['x']=(_0x3d0f2f[0x2*_0x267227]-_0x3d0f2f[0x2*_0x2cd79d])/_0x466106,_0x5e574d['y']=(_0x3d0f2f[0x2*_0x267227+0x1]-_0x3d0f2f[0x2*_0x2cd79d+0x1])/_0x466106,_0x197cfa[_0x2cd79d][_0x267227]['push'](_0x2cd79d);for(var _0x4e5049=0x1;_0x4e5049<_0x466106;_0x4e5049++)_0x197cfa[_0x2cd79d][_0x267227]['push'](_0x4543a8['length']/0x3),_0x4543a8[_0x3acb0d]=_0x4543a8[0x3*_0x2cd79d]+_0x4e5049*_0x4bc255['x'],_0x108201[_0x3acb0d++]=_0x108201[0x3*_0x2cd79d]+_0x4e5049*_0x2e30e7['x'],_0x4543a8[_0x3acb0d]=_0x4543a8[0x3*_0x2cd79d+0x1]+_0x4e5049*_0x4bc255['y'],_0x108201[_0x3acb0d++]=_0x108201[0x3*_0x2cd79d+0x1]+_0x4e5049*_0x2e30e7['y'],_0x4543a8[_0x3acb0d]=_0x4543a8[0x3*_0x2cd79d+0x2]+_0x4e5049*_0x4bc255['z'],_0x108201[_0x3acb0d++]=_0x108201[0x3*_0x2cd79d+0x2]+_0x4e5049*_0x2e30e7['z'],_0x3d0f2f[_0x336368++]=_0x3d0f2f[0x2*_0x2cd79d]+_0x4e5049*_0x5e574d['x'],_0x3d0f2f[_0x336368++]=_0x3d0f2f[0x2*_0x2cd79d+0x1]+_0x4e5049*_0x5e574d['y'];_0x197cfa[_0x2cd79d][_0x267227]['push'](_0x267227),_0x197cfa[_0x267227][_0x2cd79d]=new Array(),_0x2697c4=_0x197cfa[_0x2cd79d][_0x267227]['length'];for(var _0x45e1ec=0x0;_0x45e1ec<_0x2697c4;_0x45e1ec++)_0x197cfa[_0x267227][_0x2cd79d][_0x45e1ec]=_0x197cfa[_0x2cd79d][_0x267227][_0x2697c4-0x1-_0x45e1ec];}_0x70d617[0x0][0x0]=_0xef529e[_0x3a5664],_0x70d617[0x1][0x0]=_0x197cfa[_0xef529e[_0x3a5664]][_0xef529e[_0x3a5664+0x1]][0x1],_0x70d617[0x1][0x1]=_0x197cfa[_0xef529e[_0x3a5664]][_0xef529e[_0x3a5664+0x2]][0x1];for(_0x4e5049=0x2;_0x4e5049<_0x466106;_0x4e5049++){_0x70d617[_0x4e5049][0x0]=_0x197cfa[_0xef529e[_0x3a5664]][_0xef529e[_0x3a5664+0x1]][_0x4e5049],_0x70d617[_0x4e5049][_0x4e5049]=_0x197cfa[_0xef529e[_0x3a5664]][_0xef529e[_0x3a5664+0x2]][_0x4e5049],_0x4bc255['x']=(_0x4543a8[0x3*_0x70d617[_0x4e5049][_0x4e5049]]-_0x4543a8[0x3*_0x70d617[_0x4e5049][0x0]])/_0x4e5049,_0x4bc255['y']=(_0x4543a8[0x3*_0x70d617[_0x4e5049][_0x4e5049]+0x1]-_0x4543a8[0x3*_0x70d617[_0x4e5049][0x0]+0x1])/_0x4e5049,_0x4bc255['z']=(_0x4543a8[0x3*_0x70d617[_0x4e5049][_0x4e5049]+0x2]-_0x4543a8[0x3*_0x70d617[_0x4e5049][0x0]+0x2])/_0x4e5049,_0x2e30e7['x']=(_0x108201[0x3*_0x70d617[_0x4e5049][_0x4e5049]]-_0x108201[0x3*_0x70d617[_0x4e5049][0x0]])/_0x4e5049,_0x2e30e7['y']=(_0x108201[0x3*_0x70d617[_0x4e5049][_0x4e5049]+0x1]-_0x108201[0x3*_0x70d617[_0x4e5049][0x0]+0x1])/_0x4e5049,_0x2e30e7['z']=(_0x108201[0x3*_0x70d617[_0x4e5049][_0x4e5049]+0x2]-_0x108201[0x3*_0x70d617[_0x4e5049][0x0]+0x2])/_0x4e5049,_0x5e574d['x']=(_0x3d0f2f[0x2*_0x70d617[_0x4e5049][_0x4e5049]]-_0x3d0f2f[0x2*_0x70d617[_0x4e5049][0x0]])/_0x4e5049,_0x5e574d['y']=(_0x3d0f2f[0x2*_0x70d617[_0x4e5049][_0x4e5049]+0x1]-_0x3d0f2f[0x2*_0x70d617[_0x4e5049][0x0]+0x1])/_0x4e5049;for(_0x337890=0x1;_0x337890<_0x4e5049;_0x337890++)_0x70d617[_0x4e5049][_0x337890]=_0x4543a8['length']/0x3,_0x4543a8[_0x3acb0d]=_0x4543a8[0x3*_0x70d617[_0x4e5049][0x0]]+_0x337890*_0x4bc255['x'],_0x108201[_0x3acb0d++]=_0x108201[0x3*_0x70d617[_0x4e5049][0x0]]+_0x337890*_0x2e30e7['x'],_0x4543a8[_0x3acb0d]=_0x4543a8[0x3*_0x70d617[_0x4e5049][0x0]+0x1]+_0x337890*_0x4bc255['y'],_0x108201[_0x3acb0d++]=_0x108201[0x3*_0x70d617[_0x4e5049][0x0]+0x1]+_0x337890*_0x2e30e7['y'],_0x4543a8[_0x3acb0d]=_0x4543a8[0x3*_0x70d617[_0x4e5049][0x0]+0x2]+_0x337890*_0x4bc255['z'],_0x108201[_0x3acb0d++]=_0x108201[0x3*_0x70d617[_0x4e5049][0x0]+0x2]+_0x337890*_0x2e30e7['z'],_0x3d0f2f[_0x336368++]=_0x3d0f2f[0x2*_0x70d617[_0x4e5049][0x0]]+_0x337890*_0x5e574d['x'],_0x3d0f2f[_0x336368++]=_0x3d0f2f[0x2*_0x70d617[_0x4e5049][0x0]+0x1]+_0x337890*_0x5e574d['y'];}_0x70d617[_0x466106]=_0x197cfa[_0xef529e[_0x3a5664+0x1]][_0xef529e[_0x3a5664+0x2]],_0x4197a3['push'](_0x70d617[0x0][0x0],_0x70d617[0x1][0x0],_0x70d617[0x1][0x1]);for(_0x4e5049=0x1;_0x4e5049<_0x466106;_0x4e5049++){for(_0x337890=0x0;_0x337890<_0x4e5049;_0x337890++)_0x4197a3['push'](_0x70d617[_0x4e5049][_0x337890],_0x70d617[_0x4e5049+0x1][_0x337890],_0x70d617[_0x4e5049+0x1][_0x337890+0x1]),_0x4197a3['push'](_0x70d617[_0x4e5049][_0x337890],_0x70d617[_0x4e5049+0x1][_0x337890+0x1],_0x70d617[_0x4e5049][_0x337890+0x1]);_0x4197a3['push'](_0x70d617[_0x4e5049][_0x337890],_0x70d617[_0x4e5049+0x1][_0x337890],_0x70d617[_0x4e5049+0x1][_0x337890+0x1]);}}_0x195e25['indices']=_0x4197a3,_0x195e25['applyToMesh'](this,this['isVertexBufferUpdatable'](_0x46dc40['b']['PositionKind']));}else _0x1242ee['a']['Warn']('VertexData\x20contains\x20null\x20entries');},_0x249c5c['prototype']['forceSharedVertices']=function(){var _0x5ce343=_0x148cfc['a']['ExtractFromMesh'](this),_0x3b8af2=_0x5ce343['uvs'],_0x46350d=_0x5ce343['indices'],_0x250d8=_0x5ce343['positions'],_0x458de8=_0x5ce343['colors'];if(void 0x0===_0x46350d||void 0x0===_0x250d8||null===_0x46350d||null===_0x250d8)_0x1242ee['a']['Warn']('VertexData\x20contains\x20empty\x20entries');else{for(var _0x52f99f,_0x2ed670,_0x5a3cfe=new Array(),_0x84b2e6=new Array(),_0x173cd6=new Array(),_0x3ae7d5=new Array(),_0xf2ce32=new Array(),_0x24900f=0x0,_0xa9a82b={},_0x35f219=0x0;_0x35f219<_0x46350d['length'];_0x35f219+=0x3){_0x2ed670=[_0x46350d[_0x35f219],_0x46350d[_0x35f219+0x1],_0x46350d[_0x35f219+0x2]],_0xf2ce32=new Array();for(var _0xa9d01e=0x0;_0xa9d01e<0x3;_0xa9d01e++){_0xf2ce32[_0xa9d01e]='';for(var _0x511a17=0x0;_0x511a17<0x3;_0x511a17++)Math['abs'](_0x250d8[0x3*_0x2ed670[_0xa9d01e]+_0x511a17])<1e-8&&(_0x250d8[0x3*_0x2ed670[_0xa9d01e]+_0x511a17]=0x0),_0xf2ce32[_0xa9d01e]+=_0x250d8[0x3*_0x2ed670[_0xa9d01e]+_0x511a17]+'|';}if(_0xf2ce32[0x0]!=_0xf2ce32[0x1]&&_0xf2ce32[0x0]!=_0xf2ce32[0x2]&&_0xf2ce32[0x1]!=_0xf2ce32[0x2])for(_0xa9d01e=0x0;_0xa9d01e<0x3;_0xa9d01e++){if(void 0x0===(_0x52f99f=_0xa9a82b[_0xf2ce32[_0xa9d01e]])){_0xa9a82b[_0xf2ce32[_0xa9d01e]]=_0x24900f,_0x52f99f=_0x24900f++;for(_0x511a17=0x0;_0x511a17<0x3;_0x511a17++)_0x5a3cfe['push'](_0x250d8[0x3*_0x2ed670[_0xa9d01e]+_0x511a17]);if(null!=_0x458de8){for(_0x511a17=0x0;_0x511a17<0x4;_0x511a17++)_0x3ae7d5['push'](_0x458de8[0x4*_0x2ed670[_0xa9d01e]+_0x511a17]);}if(null!=_0x3b8af2){for(_0x511a17=0x0;_0x511a17<0x2;_0x511a17++)_0x173cd6['push'](_0x3b8af2[0x2*_0x2ed670[_0xa9d01e]+_0x511a17]);}}_0x84b2e6['push'](_0x52f99f);}}var _0x2c1c3f=new Array();_0x148cfc['a']['ComputeNormals'](_0x5a3cfe,_0x84b2e6,_0x2c1c3f),_0x5ce343['positions']=_0x5a3cfe,_0x5ce343['indices']=_0x84b2e6,_0x5ce343['normals']=_0x2c1c3f,null!=_0x3b8af2&&(_0x5ce343['uvs']=_0x173cd6),null!=_0x458de8&&(_0x5ce343['colors']=_0x3ae7d5),_0x5ce343['applyToMesh'](this,this['isVertexBufferUpdatable'](_0x46dc40['b']['PositionKind']));}},_0x249c5c['_instancedMeshFactory']=function(_0x3ce456,_0x436f10){throw _0x3f0030['a']['WarnImport']('InstancedMesh');},_0x249c5c['_PhysicsImpostorParser']=function(_0x2e8f26,_0x13728f,_0x370d66){throw _0x3f0030['a']['WarnImport']('PhysicsImpostor');},_0x249c5c['prototype']['createInstance']=function(_0x17fb97){var _0x35da55=this['geometry'];if(_0x35da55&&_0x35da55['meshes']['length']>0x1)for(var _0x477338=0x0,_0xe3bf20=_0x35da55['meshes']['slice'](0x0);_0x477338<_0xe3bf20['length'];_0x477338++){var _0x188c28=_0xe3bf20[_0x477338];_0x188c28!==this&&_0x188c28['makeGeometryUnique']();}return _0x249c5c['_instancedMeshFactory'](_0x17fb97,this);},_0x249c5c['prototype']['synchronizeInstances']=function(){this['_geometry']&&0x1!==this['_geometry']['meshes']['length']&&this['instances']['length']&&this['makeGeometryUnique']();for(var _0x57ebd7=0x0;_0x57ebd7-0x1&&(_0x487d77['morphTargetManager']=_0x27d11a['getMorphTargetManagerById'](_0x5ab5da['morphTargetManagerId'])),void 0x0!==_0x5ab5da['skeletonId']&&null!==_0x5ab5da['skeletonId']&&(_0x487d77['skeleton']=_0x27d11a['getLastSkeletonByID'](_0x5ab5da['skeletonId']),_0x5ab5da['numBoneInfluencers']&&(_0x487d77['numBoneInfluencers']=_0x5ab5da['numBoneInfluencers'])),_0x5ab5da['animations']){for(var _0x28624c=0x0;_0x28624c<_0x5ab5da['animations']['length'];_0x28624c++){var _0x186d94=_0x5ab5da['animations'][_0x28624c];(_0x2d8482=_0x1268fb['a']['GetClass']('BABYLON.Animation'))&&_0x487d77['animations']['push'](_0x2d8482['Parse'](_0x186d94));}_0x131ca8['a']['ParseAnimationRanges'](_0x487d77,_0x5ab5da,_0x27d11a);}if(_0x5ab5da['autoAnimate']&&_0x27d11a['beginAnimation'](_0x487d77,_0x5ab5da['autoAnimateFrom'],_0x5ab5da['autoAnimateTo'],_0x5ab5da['autoAnimateLoop'],_0x5ab5da['autoAnimateSpeed']||0x1),_0x5ab5da['layerMask']&&!isNaN(_0x5ab5da['layerMask'])?_0x487d77['layerMask']=Math['abs'](parseInt(_0x5ab5da['layerMask'])):_0x487d77['layerMask']=0xfffffff,_0x5ab5da['physicsImpostor']&&_0x249c5c['_PhysicsImpostorParser'](_0x27d11a,_0x487d77,_0x5ab5da),_0x5ab5da['lodMeshIds']&&(_0x487d77['_waitingData']['lods']={'ids':_0x5ab5da['lodMeshIds'],'distances':_0x5ab5da['lodDistances']?_0x5ab5da['lodDistances']:null,'coverages':_0x5ab5da['lodCoverages']?_0x5ab5da['lodCoverages']:null}),_0x5ab5da['instances'])for(var _0x559573=0x0;_0x559573<_0x5ab5da['instances']['length'];_0x559573++){var _0x1cf179=_0x5ab5da['instances'][_0x559573],_0x2ba783=_0x487d77['createInstance'](_0x1cf179['name']);if(_0x1cf179['id']&&(_0x2ba783['id']=_0x1cf179['id']),_0x11e731['a']&&(_0x1cf179['tags']?_0x11e731['a']['AddTagsTo'](_0x2ba783,_0x1cf179['tags']):_0x11e731['a']['AddTagsTo'](_0x2ba783,_0x5ab5da['tags'])),_0x2ba783['position']=_0xfcdde3['e']['FromArray'](_0x1cf179['position']),void 0x0!==_0x1cf179['metadata']&&(_0x2ba783['metadata']=_0x1cf179['metadata']),_0x1cf179['parentId']&&(_0x2ba783['_waitingParentId']=_0x1cf179['parentId']),void 0x0!==_0x1cf179['isEnabled']&&null!==_0x1cf179['isEnabled']&&_0x2ba783['setEnabled'](_0x1cf179['isEnabled']),void 0x0!==_0x1cf179['isVisible']&&null!==_0x1cf179['isVisible']&&(_0x2ba783['isVisible']=_0x1cf179['isVisible']),void 0x0!==_0x1cf179['isPickable']&&null!==_0x1cf179['isPickable']&&(_0x2ba783['isPickable']=_0x1cf179['isPickable']),_0x1cf179['rotationQuaternion']?_0x2ba783['rotationQuaternion']=_0xfcdde3['b']['FromArray'](_0x1cf179['rotationQuaternion']):_0x1cf179['rotation']&&(_0x2ba783['rotation']=_0xfcdde3['e']['FromArray'](_0x1cf179['rotation'])),_0x2ba783['scaling']=_0xfcdde3['e']['FromArray'](_0x1cf179['scaling']),null!=_0x1cf179['checkCollisions']&&null!=_0x1cf179['checkCollisions']&&(_0x2ba783['checkCollisions']=_0x1cf179['checkCollisions']),null!=_0x1cf179['pickable']&&null!=_0x1cf179['pickable']&&(_0x2ba783['isPickable']=_0x1cf179['pickable']),null!=_0x1cf179['showBoundingBox']&&null!=_0x1cf179['showBoundingBox']&&(_0x2ba783['showBoundingBox']=_0x1cf179['showBoundingBox']),null!=_0x1cf179['showSubMeshesBoundingBox']&&null!=_0x1cf179['showSubMeshesBoundingBox']&&(_0x2ba783['showSubMeshesBoundingBox']=_0x1cf179['showSubMeshesBoundingBox']),null!=_0x1cf179['alphaIndex']&&null!=_0x1cf179['showSubMeshesBoundingBox']&&(_0x2ba783['alphaIndex']=_0x1cf179['alphaIndex']),_0x1cf179['physicsImpostor']&&_0x249c5c['_PhysicsImpostorParser'](_0x27d11a,_0x2ba783,_0x1cf179),_0x1cf179['animations']){for(_0x28624c=0x0;_0x28624c<_0x1cf179['animations']['length'];_0x28624c++){var _0x2d8482;_0x186d94=_0x1cf179['animations'][_0x28624c],(_0x2d8482=_0x1268fb['a']['GetClass']('BABYLON.Animation'))&&_0x2ba783['animations']['push'](_0x2d8482['Parse'](_0x186d94));}_0x131ca8['a']['ParseAnimationRanges'](_0x2ba783,_0x1cf179,_0x27d11a),_0x1cf179['autoAnimate']&&_0x27d11a['beginAnimation'](_0x2ba783,_0x1cf179['autoAnimateFrom'],_0x1cf179['autoAnimateTo'],_0x1cf179['autoAnimateLoop'],_0x1cf179['autoAnimateSpeed']||0x1);}}if(_0x5ab5da['thinInstances']){var _0x28b729=_0x5ab5da['thinInstances'];if(_0x28b729['matrixData']?(_0x487d77['thinInstanceSetBuffer']('matrix',new Float32Array(_0x28b729['matrixData']),0x10,!0x1),_0x487d77['_thinInstanceDataStorage']['matrixBufferSize']=_0x28b729['matrixBufferSize'],_0x487d77['_thinInstanceDataStorage']['instancesCount']=_0x28b729['instancesCount']):_0x487d77['_thinInstanceDataStorage']['matrixBufferSize']=_0x28b729['matrixBufferSize'],_0x5ab5da['thinInstances']['userThinInstance']){var _0x2693c6=_0x5ab5da['thinInstances']['userThinInstance'];for(var _0x135788 in _0x2693c6['data'])_0x487d77['thinInstanceSetBuffer'](_0x135788,new Float32Array(_0x2693c6['data'][_0x135788]),_0x2693c6['strides'][_0x135788],!0x1),_0x487d77['_userThinInstanceBuffersStorage']['sizes'][_0x135788]=_0x2693c6['sizes'][_0x135788];}}return _0x487d77;},_0x249c5c['CreateRibbon']=function(_0x5c55b4,_0x2bb6f6,_0x50caab,_0x350239,_0xf55a36,_0x5a3570,_0x23e53c,_0x29cdb1,_0x1577f5){throw _0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['CreateDisc']=function(_0x35402a,_0x376a9b,_0x28272d,_0x34740c,_0x5a2798,_0x30973a){throw void 0x0===_0x34740c&&(_0x34740c=null),_0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['CreateBox']=function(_0x5c1b15,_0x132291,_0x6b18fa,_0xfd784b,_0x462435){throw void 0x0===_0x6b18fa&&(_0x6b18fa=null),_0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['CreateSphere']=function(_0x5044ca,_0x541811,_0x4c6e86,_0x5b7536,_0x1b8693,_0x14678d){throw _0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['CreateHemisphere']=function(_0x13346a,_0x56d68d,_0x1368c6,_0x4b06c2){throw _0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['CreateCylinder']=function(_0x3fd9b0,_0x1af69f,_0x22b15d,_0x12e4d7,_0x4c7bb7,_0xa052fa,_0x2a539,_0x49010b,_0x1a3dd6){throw _0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['CreateTorus']=function(_0x3ae807,_0x108c81,_0x58ca08,_0x10dd39,_0x26fadc,_0x39c863,_0x5d4766){throw _0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['CreateTorusKnot']=function(_0x88e6c6,_0x38b34c,_0x43800e,_0x10a02e,_0x167f05,_0x22f580,_0x4f73ce,_0x3322e7,_0x2a45ed,_0x196805){throw _0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['CreateLines']=function(_0x4da5db,_0x5aaa09,_0x27115e,_0xd2a4ad,_0x35472b){throw void 0x0===_0x27115e&&(_0x27115e=null),void 0x0===_0xd2a4ad&&(_0xd2a4ad=!0x1),void 0x0===_0x35472b&&(_0x35472b=null),_0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['CreateDashedLines']=function(_0x5ef81c,_0x4ac118,_0x481b2f,_0x22cb14,_0x402228,_0x72608f,_0xc78d25,_0x2f92c0){throw void 0x0===_0x72608f&&(_0x72608f=null),_0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['CreatePolygon']=function(_0x1e8488,_0x243771,_0x1f89ff,_0x42d350,_0x2365f8,_0x29bcbe,_0x4861d0){throw void 0x0===_0x4861d0&&(_0x4861d0=earcut),_0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['ExtrudePolygon']=function(_0x80aec1,_0x53659b,_0x14a466,_0x16ed8f,_0x19e92a,_0x4ddb12,_0x36aead,_0x4f17cb){throw void 0x0===_0x4f17cb&&(_0x4f17cb=earcut),_0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['ExtrudeShape']=function(_0x30f707,_0x1984cf,_0x2b36f6,_0x4f96bf,_0x457c1b,_0xdbc415,_0x389a6c,_0x15089b,_0x4331bb,_0x3e3bc8){throw void 0x0===_0x389a6c&&(_0x389a6c=null),_0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['ExtrudeShapeCustom']=function(_0x4d5716,_0xd88e2c,_0x310f04,_0x47db97,_0x2c311d,_0x27496d,_0x8ee9b2,_0x5764f0,_0x449c84,_0x244c2e,_0x2f79a2,_0x5600ad){throw _0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['CreateLathe']=function(_0x491462,_0x25caca,_0x5274a6,_0xb16b1a,_0x3adad1,_0x4a6c96,_0x56db19){throw _0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['CreatePlane']=function(_0x545155,_0x2c2e6,_0x2ea52b,_0x1e6d07,_0x7ed7aa){throw _0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['CreateGround']=function(_0x52f83d,_0x11ea9d,_0x141b8d,_0x3c4390,_0x29aedf,_0x73ae44){throw _0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['CreateTiledGround']=function(_0x4aa4d6,_0x2e9753,_0x2f5dc7,_0x382f3c,_0x3023bc,_0x461377,_0x10f3a4,_0x45bf5e,_0x1f8a84){throw _0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['CreateGroundFromHeightMap']=function(_0x2650c4,_0x2a5add,_0x58ad7a,_0x3b6fc4,_0x18a965,_0x294005,_0x26c06f,_0x455437,_0x3c2e9e,_0x40acd2,_0xcfc4e3){throw _0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['CreateTube']=function(_0x3c22b6,_0x5a84ee,_0x370fe5,_0x26e09f,_0x2c3e13,_0x3c11c1,_0x4bcdf8,_0x83f156,_0x4324cf,_0x54769d){throw _0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['CreatePolyhedron']=function(_0x4efc7d,_0x4e589b,_0x277cbb){throw _0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['CreateIcoSphere']=function(_0x2280dd,_0x578537,_0x238c4a){throw _0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['CreateDecal']=function(_0x340488,_0x1ae4d0,_0x112b7a,_0x3c08fb,_0x502b49,_0xc04980){throw _0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['CreateCapsule']=function(_0x2b5e9d,_0x47bb10,_0x58e3fb){throw _0x3f0030['a']['WarnImport']('MeshBuilder');},_0x249c5c['prototype']['setPositionsForCPUSkinning']=function(){var _0x31cd4d=this['_internalMeshDataInfo'];if(!_0x31cd4d['_sourcePositions']){var _0x323735=this['getVerticesData'](_0x46dc40['b']['PositionKind']);if(!_0x323735)return _0x31cd4d['_sourcePositions'];_0x31cd4d['_sourcePositions']=new Float32Array(_0x323735),this['isVertexBufferUpdatable'](_0x46dc40['b']['PositionKind'])||this['setVerticesData'](_0x46dc40['b']['PositionKind'],_0x323735,!0x0);}return _0x31cd4d['_sourcePositions'];},_0x249c5c['prototype']['setNormalsForCPUSkinning']=function(){var _0x1c8812=this['_internalMeshDataInfo'];if(!_0x1c8812['_sourceNormals']){var _0x426497=this['getVerticesData'](_0x46dc40['b']['NormalKind']);if(!_0x426497)return _0x1c8812['_sourceNormals'];_0x1c8812['_sourceNormals']=new Float32Array(_0x426497),this['isVertexBufferUpdatable'](_0x46dc40['b']['NormalKind'])||this['setVerticesData'](_0x46dc40['b']['NormalKind'],_0x426497,!0x0);}return _0x1c8812['_sourceNormals'];},_0x249c5c['prototype']['applySkeleton']=function(_0x110659){if(!this['geometry'])return this;if(this['geometry']['_softwareSkinningFrameId']==this['getScene']()['getFrameId']())return this;if(this['geometry']['_softwareSkinningFrameId']=this['getScene']()['getFrameId'](),!this['isVerticesDataPresent'](_0x46dc40['b']['PositionKind']))return this;if(!this['isVerticesDataPresent'](_0x46dc40['b']['MatricesIndicesKind']))return this;if(!this['isVerticesDataPresent'](_0x46dc40['b']['MatricesWeightsKind']))return this;var _0x6465eb=this['isVerticesDataPresent'](_0x46dc40['b']['NormalKind']),_0x18ce19=this['_internalMeshDataInfo'];if(!_0x18ce19['_sourcePositions']){var _0x3a2fad=this['subMeshes']['slice']();this['setPositionsForCPUSkinning'](),this['subMeshes']=_0x3a2fad;}_0x6465eb&&!_0x18ce19['_sourceNormals']&&this['setNormalsForCPUSkinning']();var _0x1d422c=this['getVerticesData'](_0x46dc40['b']['PositionKind']);if(!_0x1d422c)return this;_0x1d422c instanceof Float32Array||(_0x1d422c=new Float32Array(_0x1d422c));var _0x40c988=this['getVerticesData'](_0x46dc40['b']['NormalKind']);if(_0x6465eb){if(!_0x40c988)return this;_0x40c988 instanceof Float32Array||(_0x40c988=new Float32Array(_0x40c988));}var _0x4fb8e6=this['getVerticesData'](_0x46dc40['b']['MatricesIndicesKind']),_0x53492c=this['getVerticesData'](_0x46dc40['b']['MatricesWeightsKind']);if(!_0x53492c||!_0x4fb8e6)return this;for(var _0x215f1f,_0x1bcf43=this['numBoneInfluencers']>0x4,_0x50ab0c=_0x1bcf43?this['getVerticesData'](_0x46dc40['b']['MatricesIndicesExtraKind']):null,_0x586648=_0x1bcf43?this['getVerticesData'](_0x46dc40['b']['MatricesWeightsExtraKind']):null,_0x679190=_0x110659['getTransformMatrices'](this),_0x3eb6d0=_0xfcdde3['e']['Zero'](),_0x214f87=new _0xfcdde3['a'](),_0x124169=new _0xfcdde3['a'](),_0x1ad17a=0x0,_0x32457e=0x0;_0x32457e<_0x1d422c['length'];_0x32457e+=0x3,_0x1ad17a+=0x4){var _0x56c74d;for(_0x215f1f=0x0;_0x215f1f<0x4;_0x215f1f++)(_0x56c74d=_0x53492c[_0x1ad17a+_0x215f1f])>0x0&&(_0xfcdde3['a']['FromFloat32ArrayToRefScaled'](_0x679190,Math['floor'](0x10*_0x4fb8e6[_0x1ad17a+_0x215f1f]),_0x56c74d,_0x124169),_0x214f87['addToSelf'](_0x124169));if(_0x1bcf43){for(_0x215f1f=0x0;_0x215f1f<0x4;_0x215f1f++)(_0x56c74d=_0x586648[_0x1ad17a+_0x215f1f])>0x0&&(_0xfcdde3['a']['FromFloat32ArrayToRefScaled'](_0x679190,Math['floor'](0x10*_0x50ab0c[_0x1ad17a+_0x215f1f]),_0x56c74d,_0x124169),_0x214f87['addToSelf'](_0x124169));}_0xfcdde3['e']['TransformCoordinatesFromFloatsToRef'](_0x18ce19['_sourcePositions'][_0x32457e],_0x18ce19['_sourcePositions'][_0x32457e+0x1],_0x18ce19['_sourcePositions'][_0x32457e+0x2],_0x214f87,_0x3eb6d0),_0x3eb6d0['toArray'](_0x1d422c,_0x32457e),_0x6465eb&&(_0xfcdde3['e']['TransformNormalFromFloatsToRef'](_0x18ce19['_sourceNormals'][_0x32457e],_0x18ce19['_sourceNormals'][_0x32457e+0x1],_0x18ce19['_sourceNormals'][_0x32457e+0x2],_0x214f87,_0x3eb6d0),_0x3eb6d0['toArray'](_0x40c988,_0x32457e)),_0x214f87['reset']();}return this['updateVerticesData'](_0x46dc40['b']['PositionKind'],_0x1d422c),_0x6465eb&&this['updateVerticesData'](_0x46dc40['b']['NormalKind'],_0x40c988),this;},_0x249c5c['MinMax']=function(_0x1a3f10){var _0x667217=null,_0x1dc938=null;return _0x1a3f10['forEach'](function(_0x17555e){var _0x1ee1c2=_0x17555e['getBoundingInfo']()['boundingBox'];_0x667217&&_0x1dc938?(_0x667217['minimizeInPlace'](_0x1ee1c2['minimumWorld']),_0x1dc938['maximizeInPlace'](_0x1ee1c2['maximumWorld'])):(_0x667217=_0x1ee1c2['minimumWorld'],_0x1dc938=_0x1ee1c2['maximumWorld']);}),_0x667217&&_0x1dc938?{'min':_0x667217,'max':_0x1dc938}:{'min':_0xfcdde3['e']['Zero'](),'max':_0xfcdde3['e']['Zero']()};},_0x249c5c['Center']=function(_0x5c9924){var _0x3942e8=_0x5c9924 instanceof Array?_0x249c5c['MinMax'](_0x5c9924):_0x5c9924;return _0xfcdde3['e']['Center'](_0x3942e8['min'],_0x3942e8['max']);},_0x249c5c['MergeMeshes']=function(_0x57853c,_0x365a67,_0x5e9e25,_0x3daabc,_0x2d33af,_0x4b9d62){var _0x1ff2eb;if(void 0x0===_0x365a67&&(_0x365a67=!0x0),!_0x5e9e25){var _0x5d7177=0x0;for(_0x1ff2eb=0x0;_0x1ff2eb<_0x57853c['length'];_0x1ff2eb++)if(_0x57853c[_0x1ff2eb]&&(_0x5d7177+=_0x57853c[_0x1ff2eb]['getTotalVertices']())>=0x10000)return _0x1242ee['a']['Warn']('Cannot\x20merge\x20meshes\x20because\x20resulting\x20mesh\x20will\x20have\x20more\x20than\x2065536\x20vertices.\x20Please\x20use\x20allow32BitsIndices\x20=\x20true\x20to\x20use\x2032\x20bits\x20indices'),null;}if(_0x4b9d62){var _0x1e3e38,_0x576490,_0x5dcd41=null;_0x2d33af=!0x1;}var _0x38ded1,_0x1f8b3d=new Array(),_0x56c724=new Array(),_0x797b24=null,_0x3ad84a=new Array(),_0x5764a9=null;for(_0x1ff2eb=0x0;_0x1ff2eb<_0x57853c['length'];_0x1ff2eb++)if(_0x57853c[_0x1ff2eb]){var _0x62efae=_0x57853c[_0x1ff2eb];if(_0x62efae['isAnInstance'])return _0x1242ee['a']['Warn']('Cannot\x20merge\x20instance\x20meshes.'),null;var _0x38fa35=_0x62efae['computeWorldMatrix'](!0x0);if((_0x38ded1=_0x148cfc['a']['ExtractFromMesh'](_0x62efae,!0x0,!0x0))['transform'](_0x38fa35),_0x797b24?_0x797b24['merge'](_0x38ded1,_0x5e9e25):(_0x797b24=_0x38ded1,_0x5764a9=_0x62efae),_0x2d33af&&_0x3ad84a['push'](_0x62efae['getTotalIndices']()),_0x4b9d62){if(_0x62efae['material']){var _0x36a7c2=_0x62efae['material'];if(_0x36a7c2 instanceof _0x352df0['a']){for(_0x576490=0x0;_0x576490<_0x36a7c2['subMaterials']['length'];_0x576490++)_0x1f8b3d['indexOf'](_0x36a7c2['subMaterials'][_0x576490])<0x0&&_0x1f8b3d['push'](_0x36a7c2['subMaterials'][_0x576490]);for(_0x1e3e38=0x0;_0x1e3e38<_0x62efae['subMeshes']['length'];_0x1e3e38++)_0x56c724['push'](_0x1f8b3d['indexOf'](_0x36a7c2['subMaterials'][_0x62efae['subMeshes'][_0x1e3e38]['materialIndex']])),_0x3ad84a['push'](_0x62efae['subMeshes'][_0x1e3e38]['indexCount']);}else{for(_0x1f8b3d['indexOf'](_0x36a7c2)<0x0&&_0x1f8b3d['push'](_0x36a7c2),_0x1e3e38=0x0;_0x1e3e38<_0x62efae['subMeshes']['length'];_0x1e3e38++)_0x56c724['push'](_0x1f8b3d['indexOf'](_0x36a7c2)),_0x3ad84a['push'](_0x62efae['subMeshes'][_0x1e3e38]['indexCount']);}}else{for(_0x1e3e38=0x0;_0x1e3e38<_0x62efae['subMeshes']['length'];_0x1e3e38++)_0x56c724['push'](0x0),_0x3ad84a['push'](_0x62efae['subMeshes'][_0x1e3e38]['indexCount']);}}}if(_0x5764a9=_0x5764a9,_0x3daabc||(_0x3daabc=new _0x249c5c(_0x5764a9['name']+'_merged',_0x5764a9['getScene']())),_0x797b24['applyToMesh'](_0x3daabc),_0x3daabc['checkCollisions']=_0x5764a9['checkCollisions'],_0x3daabc['overrideMaterialSideOrientation']=_0x5764a9['overrideMaterialSideOrientation'],_0x365a67){for(_0x1ff2eb=0x0;_0x1ff2eb<_0x57853c['length'];_0x1ff2eb++)_0x57853c[_0x1ff2eb]&&_0x57853c[_0x1ff2eb]['dispose']();}if(_0x2d33af||_0x4b9d62){_0x3daabc['releaseSubMeshes'](),_0x1ff2eb=0x0;for(var _0x3309c3=0x0;_0x1ff2eb<_0x3ad84a['length'];)_0x452130['a']['CreateFromIndices'](0x0,_0x3309c3,_0x3ad84a[_0x1ff2eb],_0x3daabc),_0x3309c3+=_0x3ad84a[_0x1ff2eb],_0x1ff2eb++;}if(_0x4b9d62){for((_0x5dcd41=new _0x352df0['a'](_0x5764a9['name']+'_merged',_0x5764a9['getScene']()))['subMaterials']=_0x1f8b3d,_0x1e3e38=0x0;_0x1e3e38<_0x3daabc['subMeshes']['length'];_0x1e3e38++)_0x3daabc['subMeshes'][_0x1e3e38]['materialIndex']=_0x56c724[_0x1e3e38];_0x3daabc['material']=_0x5dcd41;}else _0x3daabc['material']=_0x5764a9['material'];return _0x3daabc;},_0x249c5c['prototype']['addInstance']=function(_0x10ef6d){_0x10ef6d['_indexInSourceMeshInstanceArray']=this['instances']['length'],this['instances']['push'](_0x10ef6d);},_0x249c5c['prototype']['removeInstance']=function(_0x4afc0b){var _0x38ce63=_0x4afc0b['_indexInSourceMeshInstanceArray'];if(-0x1!=_0x38ce63){if(_0x38ce63!==this['instances']['length']-0x1){var _0x1d9eb2=this['instances'][this['instances']['length']-0x1];this['instances'][_0x38ce63]=_0x1d9eb2,_0x1d9eb2['_indexInSourceMeshInstanceArray']=_0x38ce63;}_0x4afc0b['_indexInSourceMeshInstanceArray']=-0x1,this['instances']['pop']();}},_0x249c5c['FRONTSIDE']=_0x148cfc['a']['FRONTSIDE'],_0x249c5c['BACKSIDE']=_0x148cfc['a']['BACKSIDE'],_0x249c5c['DOUBLESIDE']=_0x148cfc['a']['DOUBLESIDE'],_0x249c5c['DEFAULTSIDE']=_0x148cfc['a']['DEFAULTSIDE'],_0x249c5c['NO_CAP']=0x0,_0x249c5c['CAP_START']=0x1,_0x249c5c['CAP_END']=0x2,_0x249c5c['CAP_ALL']=0x3,_0x249c5c['NO_FLIP']=0x0,_0x249c5c['FLIP_TILE']=0x1,_0x249c5c['ROTATE_TILE']=0x2,_0x249c5c['FLIP_ROW']=0x3,_0x249c5c['ROTATE_ROW']=0x4,_0x249c5c['FLIP_N_ROTATE_TILE']=0x5,_0x249c5c['FLIP_N_ROTATE_ROW']=0x6,_0x249c5c['CENTER']=0x0,_0x249c5c['LEFT']=0x1,_0x249c5c['RIGHT']=0x2,_0x249c5c['TOP']=0x3,_0x249c5c['BOTTOM']=0x4,_0x249c5c['_GroundMeshParser']=function(_0x22b7f8,_0x25a7cf){throw _0x3f0030['a']['WarnImport']('GroundMesh');},_0x249c5c;}(_0x550af6['a']);_0x1268fb['a']['RegisteredTypes']['BABYLON.Mesh']=_0x55a7d7;},function(_0x4c1ef1,_0x289c49,_0x50d16d){'use strict';_0x50d16d['d'](_0x289c49,'a',function(){return _0x488b0f;});var _0x488b0f=(function(){function _0x24eb36(){}return _0x24eb36['_AddLogEntry']=function(_0x4111da){_0x24eb36['_LogCache']=_0x4111da+_0x24eb36['_LogCache'],_0x24eb36['OnNewCacheEntry']&&_0x24eb36['OnNewCacheEntry'](_0x4111da);},_0x24eb36['_FormatMessage']=function(_0x160a67){var _0x3116bc=function(_0x3d7b00){return _0x3d7b00<0xa?'0'+_0x3d7b00:''+_0x3d7b00;},_0x378406=new Date();return'['+_0x3116bc(_0x378406['getHours']())+':'+_0x3116bc(_0x378406['getMinutes']())+':'+_0x3116bc(_0x378406['getSeconds']())+']:\x20'+_0x160a67;},_0x24eb36['_LogDisabled']=function(_0x156451){},_0x24eb36['_LogEnabled']=function(_0x101db5){var _0x189f27=_0x24eb36['_FormatMessage'](_0x101db5);console['log']('BJS\x20-\x20'+_0x189f27);var _0x48e60e=''+_0x189f27+'
';_0x24eb36['_AddLogEntry'](_0x48e60e);},_0x24eb36['_WarnDisabled']=function(_0x5b62cc){},_0x24eb36['_WarnEnabled']=function(_0x3b5cfa){var _0x48486d=_0x24eb36['_FormatMessage'](_0x3b5cfa);console['warn']('BJS\x20-\x20'+_0x48486d);var _0x2dff42=''+_0x48486d+'
';_0x24eb36['_AddLogEntry'](_0x2dff42);},_0x24eb36['_ErrorDisabled']=function(_0x47367d){},_0x24eb36['_ErrorEnabled']=function(_0x2df0b8){_0x24eb36['errorsCount']++;var _0x243fa2=_0x24eb36['_FormatMessage'](_0x2df0b8);console['error']('BJS\x20-\x20'+_0x243fa2);var _0x1338d7=''+_0x243fa2+'
';_0x24eb36['_AddLogEntry'](_0x1338d7);},Object['defineProperty'](_0x24eb36,'LogCache',{'get':function(){return _0x24eb36['_LogCache'];},'enumerable':!0x1,'configurable':!0x0}),_0x24eb36['ClearLogCache']=function(){_0x24eb36['_LogCache']='',_0x24eb36['errorsCount']=0x0;},Object['defineProperty'](_0x24eb36,'LogLevels',{'set':function(_0x1b1afe){(_0x1b1afe&_0x24eb36['MessageLogLevel'])===_0x24eb36['MessageLogLevel']?_0x24eb36['Log']=_0x24eb36['_LogEnabled']:_0x24eb36['Log']=_0x24eb36['_LogDisabled'],(_0x1b1afe&_0x24eb36['WarningLogLevel'])===_0x24eb36['WarningLogLevel']?_0x24eb36['Warn']=_0x24eb36['_WarnEnabled']:_0x24eb36['Warn']=_0x24eb36['_WarnDisabled'],(_0x1b1afe&_0x24eb36['ErrorLogLevel'])===_0x24eb36['ErrorLogLevel']?_0x24eb36['Error']=_0x24eb36['_ErrorEnabled']:_0x24eb36['Error']=_0x24eb36['_ErrorDisabled'];},'enumerable':!0x1,'configurable':!0x0}),_0x24eb36['NoneLogLevel']=0x0,_0x24eb36['MessageLogLevel']=0x1,_0x24eb36['WarningLogLevel']=0x2,_0x24eb36['ErrorLogLevel']=0x4,_0x24eb36['AllLogLevel']=0x7,_0x24eb36['_LogCache']='',_0x24eb36['errorsCount']=0x0,_0x24eb36['Log']=_0x24eb36['_LogEnabled'],_0x24eb36['Warn']=_0x24eb36['_WarnEnabled'],_0x24eb36['Error']=_0x24eb36['_ErrorEnabled'],_0x24eb36;}());},function(_0x228270,_0x4470b4,_0x2114fa){'use strict';_0x2114fa['d'](_0x4470b4,'a',function(){return _0x58c5f2;}),_0x2114fa['d'](_0x4470b4,'b',function(){return _0x33e572;}),_0x2114fa['d'](_0x4470b4,'c',function(){return _0x4a5417;});var _0x230350=_0x2114fa(0xe),_0x4b6077=_0x2114fa(0x1c),_0x3bb546=_0x2114fa(0x2c),_0x5dfba7=_0x2114fa(0xb),_0x58c5f2=(function(){function _0x371944(_0x1fd0ea,_0x4ba99f,_0x13c933){void 0x0===_0x1fd0ea&&(_0x1fd0ea=0x0),void 0x0===_0x4ba99f&&(_0x4ba99f=0x0),void 0x0===_0x13c933&&(_0x13c933=0x0),this['r']=_0x1fd0ea,this['g']=_0x4ba99f,this['b']=_0x13c933;}return _0x371944['prototype']['toString']=function(){return'{R:\x20'+this['r']+'\x20G:'+this['g']+'\x20B:'+this['b']+'}';},_0x371944['prototype']['getClassName']=function(){return'Color3';},_0x371944['prototype']['getHashCode']=function(){var _0x2707d2=0xff*this['r']|0x0;return _0x2707d2=0x18d*(_0x2707d2=0x18d*_0x2707d2^(0xff*this['g']|0x0))^(0xff*this['b']|0x0);},_0x371944['prototype']['toArray']=function(_0x3885e8,_0x6df847){return void 0x0===_0x6df847&&(_0x6df847=0x0),_0x3885e8[_0x6df847]=this['r'],_0x3885e8[_0x6df847+0x1]=this['g'],_0x3885e8[_0x6df847+0x2]=this['b'],this;},_0x371944['prototype']['fromArray']=function(_0x3738d4,_0x5b048b){return void 0x0===_0x5b048b&&(_0x5b048b=0x0),_0x371944['FromArrayToRef'](_0x3738d4,_0x5b048b,this),this;},_0x371944['prototype']['toColor4']=function(_0x2299b1){return void 0x0===_0x2299b1&&(_0x2299b1=0x1),new _0x33e572(this['r'],this['g'],this['b'],_0x2299b1);},_0x371944['prototype']['asArray']=function(){var _0x5ad852=new Array();return this['toArray'](_0x5ad852,0x0),_0x5ad852;},_0x371944['prototype']['toLuminance']=function(){return 0.3*this['r']+0.59*this['g']+0.11*this['b'];},_0x371944['prototype']['multiply']=function(_0x510f14){return new _0x371944(this['r']*_0x510f14['r'],this['g']*_0x510f14['g'],this['b']*_0x510f14['b']);},_0x371944['prototype']['multiplyToRef']=function(_0x5d9881,_0x57dfb0){return _0x57dfb0['r']=this['r']*_0x5d9881['r'],_0x57dfb0['g']=this['g']*_0x5d9881['g'],_0x57dfb0['b']=this['b']*_0x5d9881['b'],this;},_0x371944['prototype']['equals']=function(_0x346b4b){return _0x346b4b&&this['r']===_0x346b4b['r']&&this['g']===_0x346b4b['g']&&this['b']===_0x346b4b['b'];},_0x371944['prototype']['equalsFloats']=function(_0x1a23e4,_0x168ed0,_0x3cfc97){return this['r']===_0x1a23e4&&this['g']===_0x168ed0&&this['b']===_0x3cfc97;},_0x371944['prototype']['scale']=function(_0x1c1e67){return new _0x371944(this['r']*_0x1c1e67,this['g']*_0x1c1e67,this['b']*_0x1c1e67);},_0x371944['prototype']['scaleToRef']=function(_0x15112c,_0x4cee1b){return _0x4cee1b['r']=this['r']*_0x15112c,_0x4cee1b['g']=this['g']*_0x15112c,_0x4cee1b['b']=this['b']*_0x15112c,this;},_0x371944['prototype']['scaleAndAddToRef']=function(_0xb44e9e,_0x16dd75){return _0x16dd75['r']+=this['r']*_0xb44e9e,_0x16dd75['g']+=this['g']*_0xb44e9e,_0x16dd75['b']+=this['b']*_0xb44e9e,this;},_0x371944['prototype']['clampToRef']=function(_0x4d357a,_0x29ac99,_0x448a93){return void 0x0===_0x4d357a&&(_0x4d357a=0x0),void 0x0===_0x29ac99&&(_0x29ac99=0x1),_0x448a93['r']=_0x230350['a']['Clamp'](this['r'],_0x4d357a,_0x29ac99),_0x448a93['g']=_0x230350['a']['Clamp'](this['g'],_0x4d357a,_0x29ac99),_0x448a93['b']=_0x230350['a']['Clamp'](this['b'],_0x4d357a,_0x29ac99),this;},_0x371944['prototype']['add']=function(_0x581fd4){return new _0x371944(this['r']+_0x581fd4['r'],this['g']+_0x581fd4['g'],this['b']+_0x581fd4['b']);},_0x371944['prototype']['addToRef']=function(_0x204007,_0xf14a1f){return _0xf14a1f['r']=this['r']+_0x204007['r'],_0xf14a1f['g']=this['g']+_0x204007['g'],_0xf14a1f['b']=this['b']+_0x204007['b'],this;},_0x371944['prototype']['subtract']=function(_0x76c3db){return new _0x371944(this['r']-_0x76c3db['r'],this['g']-_0x76c3db['g'],this['b']-_0x76c3db['b']);},_0x371944['prototype']['subtractToRef']=function(_0x25f4bf,_0x148ceb){return _0x148ceb['r']=this['r']-_0x25f4bf['r'],_0x148ceb['g']=this['g']-_0x25f4bf['g'],_0x148ceb['b']=this['b']-_0x25f4bf['b'],this;},_0x371944['prototype']['clone']=function(){return new _0x371944(this['r'],this['g'],this['b']);},_0x371944['prototype']['copyFrom']=function(_0x11f418){return this['r']=_0x11f418['r'],this['g']=_0x11f418['g'],this['b']=_0x11f418['b'],this;},_0x371944['prototype']['copyFromFloats']=function(_0x51ef0e,_0x52d9d7,_0x425056){return this['r']=_0x51ef0e,this['g']=_0x52d9d7,this['b']=_0x425056,this;},_0x371944['prototype']['set']=function(_0x1887c9,_0x5b6121,_0x331950){return this['copyFromFloats'](_0x1887c9,_0x5b6121,_0x331950);},_0x371944['prototype']['toHexString']=function(){var _0xea88c6=0xff*this['r']|0x0,_0x538bbe=0xff*this['g']|0x0,_0x366612=0xff*this['b']|0x0;return'#'+_0x230350['a']['ToHex'](_0xea88c6)+_0x230350['a']['ToHex'](_0x538bbe)+_0x230350['a']['ToHex'](_0x366612);},_0x371944['prototype']['toLinearSpace']=function(){var _0xcfe78e=new _0x371944();return this['toLinearSpaceToRef'](_0xcfe78e),_0xcfe78e;},_0x371944['prototype']['toHSV']=function(){var _0x350149=new _0x371944();return this['toHSVToRef'](_0x350149),_0x350149;},_0x371944['prototype']['toHSVToRef']=function(_0x12a429){var _0x266943=this['r'],_0x580221=this['g'],_0x486bb1=this['b'],_0xe62174=Math['max'](_0x266943,_0x580221,_0x486bb1),_0x21db13=Math['min'](_0x266943,_0x580221,_0x486bb1),_0x271a7f=0x0,_0x5849da=0x0,_0xcae501=_0xe62174,_0x2fb2ec=_0xe62174-_0x21db13;0x0!==_0xe62174&&(_0x5849da=_0x2fb2ec/_0xe62174),_0xe62174!=_0x21db13&&(_0xe62174==_0x266943?(_0x271a7f=(_0x580221-_0x486bb1)/_0x2fb2ec,_0x580221<_0x486bb1&&(_0x271a7f+=0x6)):_0xe62174==_0x580221?_0x271a7f=(_0x486bb1-_0x266943)/_0x2fb2ec+0x2:_0xe62174==_0x486bb1&&(_0x271a7f=(_0x266943-_0x580221)/_0x2fb2ec+0x4),_0x271a7f*=0x3c),_0x12a429['r']=_0x271a7f,_0x12a429['g']=_0x5849da,_0x12a429['b']=_0xcae501;},_0x371944['prototype']['toLinearSpaceToRef']=function(_0xb90d15){return _0xb90d15['r']=Math['pow'](this['r'],_0x4b6077['c']),_0xb90d15['g']=Math['pow'](this['g'],_0x4b6077['c']),_0xb90d15['b']=Math['pow'](this['b'],_0x4b6077['c']),this;},_0x371944['prototype']['toGammaSpace']=function(){var _0x15819f=new _0x371944();return this['toGammaSpaceToRef'](_0x15819f),_0x15819f;},_0x371944['prototype']['toGammaSpaceToRef']=function(_0x51b21c){return _0x51b21c['r']=Math['pow'](this['r'],_0x4b6077['b']),_0x51b21c['g']=Math['pow'](this['g'],_0x4b6077['b']),_0x51b21c['b']=Math['pow'](this['b'],_0x4b6077['b']),this;},_0x371944['HSVtoRGBToRef']=function(_0x13f150,_0x4993b9,_0x303c34,_0x5af3f9){var _0x5ac4de=_0x303c34*_0x4993b9,_0x144536=_0x13f150/0x3c,_0x48b560=_0x5ac4de*(0x1-Math['abs'](_0x144536%0x2-0x1)),_0x1a992e=0x0,_0x1ae706=0x0,_0x28a8e9=0x0;_0x144536>=0x0&&_0x144536<=0x1?(_0x1a992e=_0x5ac4de,_0x1ae706=_0x48b560):_0x144536>=0x1&&_0x144536<=0x2?(_0x1a992e=_0x48b560,_0x1ae706=_0x5ac4de):_0x144536>=0x2&&_0x144536<=0x3?(_0x1ae706=_0x5ac4de,_0x28a8e9=_0x48b560):_0x144536>=0x3&&_0x144536<=0x4?(_0x1ae706=_0x48b560,_0x28a8e9=_0x5ac4de):_0x144536>=0x4&&_0x144536<=0x5?(_0x1a992e=_0x48b560,_0x28a8e9=_0x5ac4de):_0x144536>=0x5&&_0x144536<=0x6&&(_0x1a992e=_0x5ac4de,_0x28a8e9=_0x48b560);var _0x573b07=_0x303c34-_0x5ac4de;_0x5af3f9['set'](_0x1a992e+_0x573b07,_0x1ae706+_0x573b07,_0x28a8e9+_0x573b07);},_0x371944['FromHexString']=function(_0xaf793){if('#'!==_0xaf793['substring'](0x0,0x1)||0x7!==_0xaf793['length'])return new _0x371944(0x0,0x0,0x0);var _0x63c348=parseInt(_0xaf793['substring'](0x1,0x3),0x10),_0x1a3be6=parseInt(_0xaf793['substring'](0x3,0x5),0x10),_0x5ec898=parseInt(_0xaf793['substring'](0x5,0x7),0x10);return _0x371944['FromInts'](_0x63c348,_0x1a3be6,_0x5ec898);},_0x371944['FromArray']=function(_0x13f5c2,_0x1fde58){return void 0x0===_0x1fde58&&(_0x1fde58=0x0),new _0x371944(_0x13f5c2[_0x1fde58],_0x13f5c2[_0x1fde58+0x1],_0x13f5c2[_0x1fde58+0x2]);},_0x371944['FromArrayToRef']=function(_0xbe7bb8,_0x42420c,_0x5e8609){void 0x0===_0x42420c&&(_0x42420c=0x0),_0x5e8609['r']=_0xbe7bb8[_0x42420c],_0x5e8609['g']=_0xbe7bb8[_0x42420c+0x1],_0x5e8609['b']=_0xbe7bb8[_0x42420c+0x2];},_0x371944['FromInts']=function(_0x23ad55,_0x549444,_0x16caf0){return new _0x371944(_0x23ad55/0xff,_0x549444/0xff,_0x16caf0/0xff);},_0x371944['Lerp']=function(_0xeee397,_0x269063,_0xbf6255){var _0x4429d3=new _0x371944(0x0,0x0,0x0);return _0x371944['LerpToRef'](_0xeee397,_0x269063,_0xbf6255,_0x4429d3),_0x4429d3;},_0x371944['LerpToRef']=function(_0x3e5534,_0x40b51b,_0x2b7545,_0x2d36b0){_0x2d36b0['r']=_0x3e5534['r']+(_0x40b51b['r']-_0x3e5534['r'])*_0x2b7545,_0x2d36b0['g']=_0x3e5534['g']+(_0x40b51b['g']-_0x3e5534['g'])*_0x2b7545,_0x2d36b0['b']=_0x3e5534['b']+(_0x40b51b['b']-_0x3e5534['b'])*_0x2b7545;},_0x371944['Red']=function(){return new _0x371944(0x1,0x0,0x0);},_0x371944['Green']=function(){return new _0x371944(0x0,0x1,0x0);},_0x371944['Blue']=function(){return new _0x371944(0x0,0x0,0x1);},_0x371944['Black']=function(){return new _0x371944(0x0,0x0,0x0);},Object['defineProperty'](_0x371944,'BlackReadOnly',{'get':function(){return _0x371944['_BlackReadOnly'];},'enumerable':!0x1,'configurable':!0x0}),_0x371944['White']=function(){return new _0x371944(0x1,0x1,0x1);},_0x371944['Purple']=function(){return new _0x371944(0.5,0x0,0.5);},_0x371944['Magenta']=function(){return new _0x371944(0x1,0x0,0x1);},_0x371944['Yellow']=function(){return new _0x371944(0x1,0x1,0x0);},_0x371944['Gray']=function(){return new _0x371944(0.5,0.5,0.5);},_0x371944['Teal']=function(){return new _0x371944(0x0,0x1,0x1);},_0x371944['Random']=function(){return new _0x371944(Math['random'](),Math['random'](),Math['random']());},_0x371944['_BlackReadOnly']=_0x371944['Black'](),_0x371944;}()),_0x33e572=(function(){function _0x22eba0(_0x3b9025,_0x347aa2,_0x484a20,_0x5596a2){void 0x0===_0x3b9025&&(_0x3b9025=0x0),void 0x0===_0x347aa2&&(_0x347aa2=0x0),void 0x0===_0x484a20&&(_0x484a20=0x0),void 0x0===_0x5596a2&&(_0x5596a2=0x1),this['r']=_0x3b9025,this['g']=_0x347aa2,this['b']=_0x484a20,this['a']=_0x5596a2;}return _0x22eba0['prototype']['addInPlace']=function(_0x35a195){return this['r']+=_0x35a195['r'],this['g']+=_0x35a195['g'],this['b']+=_0x35a195['b'],this['a']+=_0x35a195['a'],this;},_0x22eba0['prototype']['asArray']=function(){var _0x501e41=new Array();return this['toArray'](_0x501e41,0x0),_0x501e41;},_0x22eba0['prototype']['toArray']=function(_0x5c34db,_0x2cb06f){return void 0x0===_0x2cb06f&&(_0x2cb06f=0x0),_0x5c34db[_0x2cb06f]=this['r'],_0x5c34db[_0x2cb06f+0x1]=this['g'],_0x5c34db[_0x2cb06f+0x2]=this['b'],_0x5c34db[_0x2cb06f+0x3]=this['a'],this;},_0x22eba0['prototype']['fromArray']=function(_0x25847b,_0x23160b){return void 0x0===_0x23160b&&(_0x23160b=0x0),_0x22eba0['FromArrayToRef'](_0x25847b,_0x23160b,this),this;},_0x22eba0['prototype']['equals']=function(_0x240a8a){return _0x240a8a&&this['r']===_0x240a8a['r']&&this['g']===_0x240a8a['g']&&this['b']===_0x240a8a['b']&&this['a']===_0x240a8a['a'];},_0x22eba0['prototype']['add']=function(_0x299b24){return new _0x22eba0(this['r']+_0x299b24['r'],this['g']+_0x299b24['g'],this['b']+_0x299b24['b'],this['a']+_0x299b24['a']);},_0x22eba0['prototype']['subtract']=function(_0x45aa34){return new _0x22eba0(this['r']-_0x45aa34['r'],this['g']-_0x45aa34['g'],this['b']-_0x45aa34['b'],this['a']-_0x45aa34['a']);},_0x22eba0['prototype']['subtractToRef']=function(_0x406757,_0x5d0f51){return _0x5d0f51['r']=this['r']-_0x406757['r'],_0x5d0f51['g']=this['g']-_0x406757['g'],_0x5d0f51['b']=this['b']-_0x406757['b'],_0x5d0f51['a']=this['a']-_0x406757['a'],this;},_0x22eba0['prototype']['scale']=function(_0x3c4a8b){return new _0x22eba0(this['r']*_0x3c4a8b,this['g']*_0x3c4a8b,this['b']*_0x3c4a8b,this['a']*_0x3c4a8b);},_0x22eba0['prototype']['scaleToRef']=function(_0x2cb447,_0x2ccab1){return _0x2ccab1['r']=this['r']*_0x2cb447,_0x2ccab1['g']=this['g']*_0x2cb447,_0x2ccab1['b']=this['b']*_0x2cb447,_0x2ccab1['a']=this['a']*_0x2cb447,this;},_0x22eba0['prototype']['scaleAndAddToRef']=function(_0x52ff20,_0x4b0cca){return _0x4b0cca['r']+=this['r']*_0x52ff20,_0x4b0cca['g']+=this['g']*_0x52ff20,_0x4b0cca['b']+=this['b']*_0x52ff20,_0x4b0cca['a']+=this['a']*_0x52ff20,this;},_0x22eba0['prototype']['clampToRef']=function(_0x254f7e,_0x24a113,_0x57bfa5){return void 0x0===_0x254f7e&&(_0x254f7e=0x0),void 0x0===_0x24a113&&(_0x24a113=0x1),_0x57bfa5['r']=_0x230350['a']['Clamp'](this['r'],_0x254f7e,_0x24a113),_0x57bfa5['g']=_0x230350['a']['Clamp'](this['g'],_0x254f7e,_0x24a113),_0x57bfa5['b']=_0x230350['a']['Clamp'](this['b'],_0x254f7e,_0x24a113),_0x57bfa5['a']=_0x230350['a']['Clamp'](this['a'],_0x254f7e,_0x24a113),this;},_0x22eba0['prototype']['multiply']=function(_0x4451ea){return new _0x22eba0(this['r']*_0x4451ea['r'],this['g']*_0x4451ea['g'],this['b']*_0x4451ea['b'],this['a']*_0x4451ea['a']);},_0x22eba0['prototype']['multiplyToRef']=function(_0x509103,_0x329159){return _0x329159['r']=this['r']*_0x509103['r'],_0x329159['g']=this['g']*_0x509103['g'],_0x329159['b']=this['b']*_0x509103['b'],_0x329159['a']=this['a']*_0x509103['a'],_0x329159;},_0x22eba0['prototype']['toString']=function(){return'{R:\x20'+this['r']+'\x20G:'+this['g']+'\x20B:'+this['b']+'\x20A:'+this['a']+'}';},_0x22eba0['prototype']['getClassName']=function(){return'Color4';},_0x22eba0['prototype']['getHashCode']=function(){var _0x42ce11=0xff*this['r']|0x0;return _0x42ce11=0x18d*(_0x42ce11=0x18d*(_0x42ce11=0x18d*_0x42ce11^(0xff*this['g']|0x0))^(0xff*this['b']|0x0))^(0xff*this['a']|0x0);},_0x22eba0['prototype']['clone']=function(){return new _0x22eba0(this['r'],this['g'],this['b'],this['a']);},_0x22eba0['prototype']['copyFrom']=function(_0x5683b6){return this['r']=_0x5683b6['r'],this['g']=_0x5683b6['g'],this['b']=_0x5683b6['b'],this['a']=_0x5683b6['a'],this;},_0x22eba0['prototype']['copyFromFloats']=function(_0x673964,_0x3b78ed,_0x50a14c,_0x42678d){return this['r']=_0x673964,this['g']=_0x3b78ed,this['b']=_0x50a14c,this['a']=_0x42678d,this;},_0x22eba0['prototype']['set']=function(_0x218bdf,_0x3dbb78,_0x5dec8c,_0x2fb29b){return this['copyFromFloats'](_0x218bdf,_0x3dbb78,_0x5dec8c,_0x2fb29b);},_0x22eba0['prototype']['toHexString']=function(_0x5cf003){void 0x0===_0x5cf003&&(_0x5cf003=!0x1);var _0x4d4072=0xff*this['r']|0x0,_0x1becbc=0xff*this['g']|0x0,_0x12b94b=0xff*this['b']|0x0;if(_0x5cf003)return'#'+_0x230350['a']['ToHex'](_0x4d4072)+_0x230350['a']['ToHex'](_0x1becbc)+_0x230350['a']['ToHex'](_0x12b94b);var _0x1e509b=0xff*this['a']|0x0;return'#'+_0x230350['a']['ToHex'](_0x4d4072)+_0x230350['a']['ToHex'](_0x1becbc)+_0x230350['a']['ToHex'](_0x12b94b)+_0x230350['a']['ToHex'](_0x1e509b);},_0x22eba0['prototype']['toLinearSpace']=function(){var _0x4bef89=new _0x22eba0();return this['toLinearSpaceToRef'](_0x4bef89),_0x4bef89;},_0x22eba0['prototype']['toLinearSpaceToRef']=function(_0x449bfa){return _0x449bfa['r']=Math['pow'](this['r'],_0x4b6077['c']),_0x449bfa['g']=Math['pow'](this['g'],_0x4b6077['c']),_0x449bfa['b']=Math['pow'](this['b'],_0x4b6077['c']),_0x449bfa['a']=this['a'],this;},_0x22eba0['prototype']['toGammaSpace']=function(){var _0x4d53d2=new _0x22eba0();return this['toGammaSpaceToRef'](_0x4d53d2),_0x4d53d2;},_0x22eba0['prototype']['toGammaSpaceToRef']=function(_0x4557a6){return _0x4557a6['r']=Math['pow'](this['r'],_0x4b6077['b']),_0x4557a6['g']=Math['pow'](this['g'],_0x4b6077['b']),_0x4557a6['b']=Math['pow'](this['b'],_0x4b6077['b']),_0x4557a6['a']=this['a'],this;},_0x22eba0['FromHexString']=function(_0x3ef6c5){if('#'!==_0x3ef6c5['substring'](0x0,0x1)||0x9!==_0x3ef6c5['length'])return new _0x22eba0(0x0,0x0,0x0,0x0);var _0x968448=parseInt(_0x3ef6c5['substring'](0x1,0x3),0x10),_0x31624d=parseInt(_0x3ef6c5['substring'](0x3,0x5),0x10),_0x35be42=parseInt(_0x3ef6c5['substring'](0x5,0x7),0x10),_0x2d74ef=parseInt(_0x3ef6c5['substring'](0x7,0x9),0x10);return _0x22eba0['FromInts'](_0x968448,_0x31624d,_0x35be42,_0x2d74ef);},_0x22eba0['Lerp']=function(_0x6b28f7,_0x159854,_0x139e23){var _0x3be716=new _0x22eba0(0x0,0x0,0x0,0x0);return _0x22eba0['LerpToRef'](_0x6b28f7,_0x159854,_0x139e23,_0x3be716),_0x3be716;},_0x22eba0['LerpToRef']=function(_0x1be243,_0x4dda19,_0x288881,_0x11b0f7){_0x11b0f7['r']=_0x1be243['r']+(_0x4dda19['r']-_0x1be243['r'])*_0x288881,_0x11b0f7['g']=_0x1be243['g']+(_0x4dda19['g']-_0x1be243['g'])*_0x288881,_0x11b0f7['b']=_0x1be243['b']+(_0x4dda19['b']-_0x1be243['b'])*_0x288881,_0x11b0f7['a']=_0x1be243['a']+(_0x4dda19['a']-_0x1be243['a'])*_0x288881;},_0x22eba0['FromColor3']=function(_0xc5662f,_0x103f4e){return void 0x0===_0x103f4e&&(_0x103f4e=0x1),new _0x22eba0(_0xc5662f['r'],_0xc5662f['g'],_0xc5662f['b'],_0x103f4e);},_0x22eba0['FromArray']=function(_0x633443,_0x24139e){return void 0x0===_0x24139e&&(_0x24139e=0x0),new _0x22eba0(_0x633443[_0x24139e],_0x633443[_0x24139e+0x1],_0x633443[_0x24139e+0x2],_0x633443[_0x24139e+0x3]);},_0x22eba0['FromArrayToRef']=function(_0x4d3938,_0x3e5165,_0x2e2422){void 0x0===_0x3e5165&&(_0x3e5165=0x0),_0x2e2422['r']=_0x4d3938[_0x3e5165],_0x2e2422['g']=_0x4d3938[_0x3e5165+0x1],_0x2e2422['b']=_0x4d3938[_0x3e5165+0x2],_0x2e2422['a']=_0x4d3938[_0x3e5165+0x3];},_0x22eba0['FromInts']=function(_0x34d1a6,_0x38cdb2,_0x20394e,_0x273ef5){return new _0x22eba0(_0x34d1a6/0xff,_0x38cdb2/0xff,_0x20394e/0xff,_0x273ef5/0xff);},_0x22eba0['CheckColors4']=function(_0x44d810,_0x13e250){if(_0x44d810['length']===0x3*_0x13e250){for(var _0x10b3ac=[],_0x3c7cf3=0x0;_0x3c7cf3<_0x44d810['length'];_0x3c7cf3+=0x3){var _0x2783f7=_0x3c7cf3/0x3*0x4;_0x10b3ac[_0x2783f7]=_0x44d810[_0x3c7cf3],_0x10b3ac[_0x2783f7+0x1]=_0x44d810[_0x3c7cf3+0x1],_0x10b3ac[_0x2783f7+0x2]=_0x44d810[_0x3c7cf3+0x2],_0x10b3ac[_0x2783f7+0x3]=0x1;}return _0x10b3ac;}return _0x44d810;},_0x22eba0;}()),_0x4a5417=(function(){function _0x957b68(){}return _0x957b68['Color3']=_0x3bb546['a']['BuildArray'](0x3,_0x58c5f2['Black']),_0x957b68['Color4']=_0x3bb546['a']['BuildArray'](0x3,function(){return new _0x33e572(0x0,0x0,0x0,0x0);}),_0x957b68;}());_0x5dfba7['a']['RegisteredTypes']['BABYLON.Color3']=_0x58c5f2,_0x5dfba7['a']['RegisteredTypes']['BABYLON.Color4']=_0x33e572;},function(_0x293370,_0x3cb454,_0x461f8a){'use strict';_0x461f8a['d'](_0x3cb454,'a',function(){return _0x41bccd;});var _0x1d39d1=_0x461f8a(0x1),_0x5b095a=_0x461f8a(0x3),_0x270060=_0x461f8a(0x6),_0x58a0c3=_0x461f8a(0x0),_0x53e341=_0x461f8a(0x34),_0x8357bd=_0x461f8a(0x2),_0x461b91=_0x461f8a(0xb),_0x19112c=_0x461f8a(0x15),_0x15354e=_0x461f8a(0x68),_0x2dc106=_0x461f8a(0x7a),_0x202674=_0x461f8a(0x40),_0x2c1746=_0x461f8a(0x22),_0x7651ab=_0x461f8a(0x96),_0x41bccd=function(_0xa47b83){function _0x5a0ced(_0x414a5f,_0x3ab49c,_0x1da7be,_0xd41e21,_0xa03227,_0x4c9a89,_0x4d4753,_0x865bdf,_0x4bf5f6,_0x325708,_0x37570d,_0x181824){void 0x0===_0x1da7be&&(_0x1da7be=!0x1),void 0x0===_0xd41e21&&(_0xd41e21=!0x0),void 0x0===_0xa03227&&(_0xa03227=_0x5a0ced['TRILINEAR_SAMPLINGMODE']),void 0x0===_0x4c9a89&&(_0x4c9a89=null),void 0x0===_0x4d4753&&(_0x4d4753=null),void 0x0===_0x865bdf&&(_0x865bdf=null),void 0x0===_0x4bf5f6&&(_0x4bf5f6=!0x1);var _0x831280=_0xa47b83['call'](this,_0x3ab49c)||this;_0x831280['url']=null,_0x831280['uOffset']=0x0,_0x831280['vOffset']=0x0,_0x831280['uScale']=0x1,_0x831280['vScale']=0x1,_0x831280['uAng']=0x0,_0x831280['vAng']=0x0,_0x831280['wAng']=0x0,_0x831280['uRotationCenter']=0.5,_0x831280['vRotationCenter']=0.5,_0x831280['wRotationCenter']=0.5,_0x831280['homogeneousRotationInUVTransform']=!0x1,_0x831280['inspectableCustomProperties']=null,_0x831280['_noMipmap']=!0x1,_0x831280['_invertY']=!0x1,_0x831280['_rowGenerationMatrix']=null,_0x831280['_cachedTextureMatrix']=null,_0x831280['_projectionModeMatrix']=null,_0x831280['_t0']=null,_0x831280['_t1']=null,_0x831280['_t2']=null,_0x831280['_cachedUOffset']=-0x1,_0x831280['_cachedVOffset']=-0x1,_0x831280['_cachedUScale']=0x0,_0x831280['_cachedVScale']=0x0,_0x831280['_cachedUAng']=-0x1,_0x831280['_cachedVAng']=-0x1,_0x831280['_cachedWAng']=-0x1,_0x831280['_cachedProjectionMatrixId']=-0x1,_0x831280['_cachedURotationCenter']=-0x1,_0x831280['_cachedVRotationCenter']=-0x1,_0x831280['_cachedWRotationCenter']=-0x1,_0x831280['_cachedHomogeneousRotationInUVTransform']=!0x1,_0x831280['_cachedCoordinatesMode']=-0x1,_0x831280['_initialSamplingMode']=_0x5a0ced['BILINEAR_SAMPLINGMODE'],_0x831280['_buffer']=null,_0x831280['_deleteBuffer']=!0x1,_0x831280['_format']=null,_0x831280['_delayedOnLoad']=null,_0x831280['_delayedOnError']=null,_0x831280['onLoadObservable']=new _0x270060['c'](),_0x831280['_isBlocking']=!0x0,_0x831280['name']=_0x414a5f||'',_0x831280['url']=_0x414a5f,_0x831280['_noMipmap']=_0x1da7be,_0x831280['_invertY']=_0xd41e21,_0x831280['_initialSamplingMode']=_0xa03227,_0x831280['_buffer']=_0x865bdf,_0x831280['_deleteBuffer']=_0x4bf5f6,_0x831280['_mimeType']=_0x37570d,_0x831280['_loaderOptions']=_0x181824,_0x325708&&(_0x831280['_format']=_0x325708);var _0x48d0cd=_0x831280['getScene'](),_0x59be37=_0x831280['_getEngine']();if(!_0x59be37)return _0x831280;_0x59be37['onBeforeTextureInitObservable']['notifyObservers'](_0x831280);var _0x53471f=function(){_0x831280['_texture']&&(_0x831280['_texture']['_invertVScale']&&(_0x831280['vScale']*=-0x1,_0x831280['vOffset']+=0x1),null!==_0x831280['_texture']['_cachedWrapU']&&(_0x831280['wrapU']=_0x831280['_texture']['_cachedWrapU'],_0x831280['_texture']['_cachedWrapU']=null),null!==_0x831280['_texture']['_cachedWrapV']&&(_0x831280['wrapV']=_0x831280['_texture']['_cachedWrapV'],_0x831280['_texture']['_cachedWrapV']=null),null!==_0x831280['_texture']['_cachedWrapR']&&(_0x831280['wrapR']=_0x831280['_texture']['_cachedWrapR'],_0x831280['_texture']['_cachedWrapR']=null)),_0x831280['onLoadObservable']['hasObservers']()&&_0x831280['onLoadObservable']['notifyObservers'](_0x831280),_0x4c9a89&&_0x4c9a89(),!_0x831280['isBlocking']&&_0x48d0cd&&_0x48d0cd['resetCachedMaterial']();};return _0x831280['url']?(_0x831280['_texture']=_0x831280['_getFromCache'](_0x831280['url'],_0x1da7be,_0xa03227,_0xd41e21),_0x831280['_texture']?_0x831280['_texture']['isReady']?_0x15354e['a']['SetImmediate'](function(){return _0x53471f();}):_0x831280['_texture']['onLoadedObservable']['add'](_0x53471f):_0x48d0cd&&_0x48d0cd['useDelayedTextureLoading']?(_0x831280['delayLoadState']=_0x8357bd['a']['DELAYLOADSTATE_NOTLOADED'],_0x831280['_delayedOnLoad']=_0x53471f,_0x831280['_delayedOnError']=_0x4d4753):(_0x831280['_texture']=_0x59be37['createTexture'](_0x831280['url'],_0x1da7be,_0xd41e21,_0x48d0cd,_0xa03227,_0x53471f,_0x4d4753,_0x831280['_buffer'],void 0x0,_0x831280['_format'],null,_0x37570d,_0x181824),_0x4bf5f6&&(_0x831280['_buffer']=null)),_0x831280):(_0x831280['_delayedOnLoad']=_0x53471f,_0x831280['_delayedOnError']=_0x4d4753,_0x831280);}return Object(_0x1d39d1['d'])(_0x5a0ced,_0xa47b83),Object['defineProperty'](_0x5a0ced['prototype'],'noMipmap',{'get':function(){return this['_noMipmap'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5a0ced['prototype'],'mimeType',{'get':function(){return this['_mimeType'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5a0ced['prototype'],'isBlocking',{'get':function(){return this['_isBlocking'];},'set':function(_0x5d72a8){this['_isBlocking']=_0x5d72a8;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5a0ced['prototype'],'samplingMode',{'get':function(){return this['_texture']?this['_texture']['samplingMode']:this['_initialSamplingMode'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5a0ced['prototype'],'invertY',{'get':function(){return this['_invertY'];},'enumerable':!0x1,'configurable':!0x0}),_0x5a0ced['prototype']['updateURL']=function(_0x10c584,_0x2b93e0,_0x4ecd2e){void 0x0===_0x2b93e0&&(_0x2b93e0=null),this['url']&&(this['releaseInternalTexture'](),this['getScene']()['markAllMaterialsAsDirty'](_0x8357bd['a']['MATERIAL_TextureDirtyFlag'])),this['name']&&!_0x2c1746['a']['StartsWith'](this['name'],'data:')||(this['name']=_0x10c584),this['url']=_0x10c584,this['_buffer']=_0x2b93e0,this['delayLoadState']=_0x8357bd['a']['DELAYLOADSTATE_NOTLOADED'],_0x4ecd2e&&(this['_delayedOnLoad']=_0x4ecd2e),this['delayLoad']();},_0x5a0ced['prototype']['delayLoad']=function(){if(this['delayLoadState']===_0x8357bd['a']['DELAYLOADSTATE_NOTLOADED']){var _0x194951=this['getScene']();_0x194951&&(this['delayLoadState']=_0x8357bd['a']['DELAYLOADSTATE_LOADED'],this['_texture']=this['_getFromCache'](this['url'],this['_noMipmap'],this['samplingMode'],this['_invertY']),this['_texture']?this['_delayedOnLoad']&&(this['_texture']['isReady']?_0x15354e['a']['SetImmediate'](this['_delayedOnLoad']):this['_texture']['onLoadedObservable']['add'](this['_delayedOnLoad'])):(this['_texture']=_0x194951['getEngine']()['createTexture'](this['url'],this['_noMipmap'],this['_invertY'],_0x194951,this['samplingMode'],this['_delayedOnLoad'],this['_delayedOnError'],this['_buffer'],null,this['_format'],null,this['_mimeType'],this['_loaderOptions']),this['_deleteBuffer']&&(this['_buffer']=null)),this['_delayedOnLoad']=null,this['_delayedOnError']=null);}},_0x5a0ced['prototype']['_prepareRowForTextureGeneration']=function(_0x5d1f4c,_0x3b2ef2,_0xe6798,_0x2c209e){_0x5d1f4c*=this['_cachedUScale'],_0x3b2ef2*=this['_cachedVScale'],_0x5d1f4c-=this['uRotationCenter']*this['_cachedUScale'],_0x3b2ef2-=this['vRotationCenter']*this['_cachedVScale'],_0xe6798-=this['wRotationCenter'],_0x58a0c3['e']['TransformCoordinatesFromFloatsToRef'](_0x5d1f4c,_0x3b2ef2,_0xe6798,this['_rowGenerationMatrix'],_0x2c209e),_0x2c209e['x']+=this['uRotationCenter']*this['_cachedUScale']+this['_cachedUOffset'],_0x2c209e['y']+=this['vRotationCenter']*this['_cachedVScale']+this['_cachedVOffset'],_0x2c209e['z']+=this['wRotationCenter'];},_0x5a0ced['prototype']['checkTransformsAreIdentical']=function(_0x31e90f){return null!==_0x31e90f&&this['uOffset']===_0x31e90f['uOffset']&&this['vOffset']===_0x31e90f['vOffset']&&this['uScale']===_0x31e90f['uScale']&&this['vScale']===_0x31e90f['vScale']&&this['uAng']===_0x31e90f['uAng']&&this['vAng']===_0x31e90f['vAng']&&this['wAng']===_0x31e90f['wAng'];},_0x5a0ced['prototype']['getTextureMatrix']=function(_0x1d0a8a){var _0xb43b7c=this;if(void 0x0===_0x1d0a8a&&(_0x1d0a8a=0x1),this['uOffset']===this['_cachedUOffset']&&this['vOffset']===this['_cachedVOffset']&&this['uScale']*_0x1d0a8a===this['_cachedUScale']&&this['vScale']===this['_cachedVScale']&&this['uAng']===this['_cachedUAng']&&this['vAng']===this['_cachedVAng']&&this['wAng']===this['_cachedWAng']&&this['uRotationCenter']===this['_cachedURotationCenter']&&this['vRotationCenter']===this['_cachedVRotationCenter']&&this['wRotationCenter']===this['_cachedWRotationCenter']&&this['homogeneousRotationInUVTransform']===this['_cachedHomogeneousRotationInUVTransform'])return this['_cachedTextureMatrix'];this['_cachedUOffset']=this['uOffset'],this['_cachedVOffset']=this['vOffset'],this['_cachedUScale']=this['uScale']*_0x1d0a8a,this['_cachedVScale']=this['vScale'],this['_cachedUAng']=this['uAng'],this['_cachedVAng']=this['vAng'],this['_cachedWAng']=this['wAng'],this['_cachedURotationCenter']=this['uRotationCenter'],this['_cachedVRotationCenter']=this['vRotationCenter'],this['_cachedWRotationCenter']=this['wRotationCenter'],this['_cachedHomogeneousRotationInUVTransform']=this['homogeneousRotationInUVTransform'],this['_cachedTextureMatrix']&&this['_rowGenerationMatrix']||(this['_cachedTextureMatrix']=_0x58a0c3['a']['Zero'](),this['_rowGenerationMatrix']=new _0x58a0c3['a'](),this['_t0']=_0x58a0c3['e']['Zero'](),this['_t1']=_0x58a0c3['e']['Zero'](),this['_t2']=_0x58a0c3['e']['Zero']()),_0x58a0c3['a']['RotationYawPitchRollToRef'](this['vAng'],this['uAng'],this['wAng'],this['_rowGenerationMatrix']),this['homogeneousRotationInUVTransform']?(_0x58a0c3['a']['TranslationToRef'](-this['_cachedURotationCenter'],-this['_cachedVRotationCenter'],-this['_cachedWRotationCenter'],_0x58a0c3['c']['Matrix'][0x0]),_0x58a0c3['a']['TranslationToRef'](this['_cachedURotationCenter'],this['_cachedVRotationCenter'],this['_cachedWRotationCenter'],_0x58a0c3['c']['Matrix'][0x1]),_0x58a0c3['a']['ScalingToRef'](this['_cachedUScale'],this['_cachedVScale'],0x0,_0x58a0c3['c']['Matrix'][0x2]),_0x58a0c3['a']['TranslationToRef'](this['_cachedUOffset'],this['_cachedVOffset'],0x0,_0x58a0c3['c']['Matrix'][0x3]),_0x58a0c3['c']['Matrix'][0x0]['multiplyToRef'](this['_rowGenerationMatrix'],this['_cachedTextureMatrix']),this['_cachedTextureMatrix']['multiplyToRef'](_0x58a0c3['c']['Matrix'][0x1],this['_cachedTextureMatrix']),this['_cachedTextureMatrix']['multiplyToRef'](_0x58a0c3['c']['Matrix'][0x2],this['_cachedTextureMatrix']),this['_cachedTextureMatrix']['multiplyToRef'](_0x58a0c3['c']['Matrix'][0x3],this['_cachedTextureMatrix']),this['_cachedTextureMatrix']['setRowFromFloats'](0x2,this['_cachedTextureMatrix']['m'][0xc],this['_cachedTextureMatrix']['m'][0xd],this['_cachedTextureMatrix']['m'][0xe],0x1)):(this['_prepareRowForTextureGeneration'](0x0,0x0,0x0,this['_t0']),this['_prepareRowForTextureGeneration'](0x1,0x0,0x0,this['_t1']),this['_prepareRowForTextureGeneration'](0x0,0x1,0x0,this['_t2']),this['_t1']['subtractInPlace'](this['_t0']),this['_t2']['subtractInPlace'](this['_t0']),_0x58a0c3['a']['FromValuesToRef'](this['_t1']['x'],this['_t1']['y'],this['_t1']['z'],0x0,this['_t2']['x'],this['_t2']['y'],this['_t2']['z'],0x0,this['_t0']['x'],this['_t0']['y'],this['_t0']['z'],0x0,0x0,0x0,0x0,0x1,this['_cachedTextureMatrix']));var _0x1b2c60=this['getScene']();return _0x1b2c60?(_0x1b2c60['markAllMaterialsAsDirty'](_0x8357bd['a']['MATERIAL_TextureDirtyFlag'],function(_0x8f3541){return _0x8f3541['hasTexture'](_0xb43b7c);}),this['_cachedTextureMatrix']):this['_cachedTextureMatrix'];},_0x5a0ced['prototype']['getReflectionTextureMatrix']=function(){var _0x361879=this,_0x5d1fa0=this['getScene']();if(!_0x5d1fa0)return this['_cachedTextureMatrix'];if(this['uOffset']===this['_cachedUOffset']&&this['vOffset']===this['_cachedVOffset']&&this['uScale']===this['_cachedUScale']&&this['vScale']===this['_cachedVScale']&&this['coordinatesMode']===this['_cachedCoordinatesMode']){if(this['coordinatesMode']!==_0x5a0ced['PROJECTION_MODE'])return this['_cachedTextureMatrix'];if(this['_cachedProjectionMatrixId']===_0x5d1fa0['getProjectionMatrix']()['updateFlag'])return this['_cachedTextureMatrix'];}switch(this['_cachedTextureMatrix']||(this['_cachedTextureMatrix']=_0x58a0c3['a']['Zero']()),this['_projectionModeMatrix']||(this['_projectionModeMatrix']=_0x58a0c3['a']['Zero']()),this['_cachedUOffset']=this['uOffset'],this['_cachedVOffset']=this['vOffset'],this['_cachedUScale']=this['uScale'],this['_cachedVScale']=this['vScale'],this['_cachedCoordinatesMode']=this['coordinatesMode'],this['coordinatesMode']){case _0x5a0ced['PLANAR_MODE']:_0x58a0c3['a']['IdentityToRef'](this['_cachedTextureMatrix']),this['_cachedTextureMatrix'][0x0]=this['uScale'],this['_cachedTextureMatrix'][0x5]=this['vScale'],this['_cachedTextureMatrix'][0xc]=this['uOffset'],this['_cachedTextureMatrix'][0xd]=this['vOffset'];break;case _0x5a0ced['PROJECTION_MODE']:_0x58a0c3['a']['FromValuesToRef'](0.5,0x0,0x0,0x0,0x0,-0.5,0x0,0x0,0x0,0x0,0x0,0x0,0.5,0.5,0x1,0x1,this['_projectionModeMatrix']);var _0xea04a5=_0x5d1fa0['getProjectionMatrix']();this['_cachedProjectionMatrixId']=_0xea04a5['updateFlag'],_0xea04a5['multiplyToRef'](this['_projectionModeMatrix'],this['_cachedTextureMatrix']);break;default:_0x58a0c3['a']['IdentityToRef'](this['_cachedTextureMatrix']);}return _0x5d1fa0['markAllMaterialsAsDirty'](_0x8357bd['a']['MATERIAL_TextureDirtyFlag'],function(_0x1b35b7){return-0x1!==_0x1b35b7['getActiveTextures']()['indexOf'](_0x361879);}),this['_cachedTextureMatrix'];},_0x5a0ced['prototype']['clone']=function(){var _0x549ce5=this;return _0x5b095a['a']['Clone'](function(){return new _0x5a0ced(_0x549ce5['_texture']?_0x549ce5['_texture']['url']:null,_0x549ce5['getScene'](),_0x549ce5['_noMipmap'],_0x549ce5['_invertY'],_0x549ce5['samplingMode'],void 0x0,void 0x0,_0x549ce5['_texture']?_0x549ce5['_texture']['_buffer']:void 0x0);},this);},_0x5a0ced['prototype']['serialize']=function(){var _0x27f584=this['name'];_0x5a0ced['SerializeBuffers']||_0x2c1746['a']['StartsWith'](this['name'],'data:')&&(this['name']=''),_0x2c1746['a']['StartsWith'](this['name'],'data:')&&this['url']===this['name']&&(this['url']='');var _0x22d56c=_0xa47b83['prototype']['serialize']['call'](this);return _0x22d56c?((_0x5a0ced['SerializeBuffers']||_0x5a0ced['ForceSerializeBuffers'])&&('string'==typeof this['_buffer']&&'data:'===this['_buffer']['substr'](0x0,0x5)?(_0x22d56c['base64String']=this['_buffer'],_0x22d56c['name']=_0x22d56c['name']['replace']('data:','')):this['url']&&_0x2c1746['a']['StartsWith'](this['url'],'data:')&&this['_buffer']instanceof Uint8Array?_0x22d56c['base64String']='data:image/png;base64,'+_0x2c1746['a']['EncodeArrayBufferToBase64'](this['_buffer']):_0x5a0ced['ForceSerializeBuffers']&&(_0x22d56c['base64String']=_0x7651ab['a']['GenerateBase64StringFromTexture'](this))),_0x22d56c['invertY']=this['_invertY'],_0x22d56c['samplingMode']=this['samplingMode'],this['name']=_0x27f584,_0x22d56c):null;},_0x5a0ced['prototype']['getClassName']=function(){return'Texture';},_0x5a0ced['prototype']['dispose']=function(){_0xa47b83['prototype']['dispose']['call'](this),this['onLoadObservable']['clear'](),this['_delayedOnLoad']=null,this['_delayedOnError']=null;},_0x5a0ced['Parse']=function(_0x5983e9,_0x8ad946,_0x177e5a){if(_0x5983e9['customType']){var _0x443a6c=_0x2dc106['a']['Instantiate'](_0x5983e9['customType'])['Parse'](_0x5983e9,_0x8ad946,_0x177e5a);return _0x5983e9['samplingMode']&&_0x443a6c['updateSamplingMode']&&_0x443a6c['_samplingMode']&&_0x443a6c['_samplingMode']!==_0x5983e9['samplingMode']&&_0x443a6c['updateSamplingMode'](_0x5983e9['samplingMode']),_0x443a6c;}if(_0x5983e9['isCube']&&!_0x5983e9['isRenderTarget'])return _0x5a0ced['_CubeTextureParser'](_0x5983e9,_0x8ad946,_0x177e5a);if(!_0x5983e9['name']&&!_0x5983e9['isRenderTarget'])return null;var _0x22ebf5=function(){if(_0x43073d&&_0x43073d['_texture']&&(_0x43073d['_texture']['_cachedWrapU']=null,_0x43073d['_texture']['_cachedWrapV']=null,_0x43073d['_texture']['_cachedWrapR']=null),_0x5983e9['samplingMode']){var _0x307ea3=_0x5983e9['samplingMode'];_0x43073d&&_0x43073d['samplingMode']!==_0x307ea3&&_0x43073d['updateSamplingMode'](_0x307ea3);}if(_0x43073d&&_0x5983e9['animations'])for(var _0x1aef92=0x0;_0x1aef92<_0x5983e9['animations']['length'];_0x1aef92++){var _0x2592e6=_0x5983e9['animations'][_0x1aef92],_0x450fc8=_0x461b91['a']['GetClass']('BABYLON.Animation');_0x450fc8&&_0x43073d['animations']['push'](_0x450fc8['Parse'](_0x2592e6));}},_0x43073d=_0x5b095a['a']['Parse'](function(){var _0x20bb0d,_0x3d9b67=!0x0;if(_0x5983e9['noMipmap']&&(_0x3d9b67=!0x1),_0x5983e9['mirrorPlane']){var _0x4facb1=_0x5a0ced['_CreateMirror'](_0x5983e9['name'],_0x5983e9['renderTargetSize'],_0x8ad946,_0x3d9b67);return _0x4facb1['_waitingRenderList']=_0x5983e9['renderList'],_0x4facb1['mirrorPlane']=_0x202674['a']['FromArray'](_0x5983e9['mirrorPlane']),_0x22ebf5(),_0x4facb1;}if(_0x5983e9['isRenderTarget']){var _0x1511bf=null;if(_0x5983e9['isCube']){if(_0x8ad946['reflectionProbes'])for(var _0x226706=0x0;_0x226706<_0x8ad946['reflectionProbes']['length'];_0x226706++){var _0xd61586=_0x8ad946['reflectionProbes'][_0x226706];if(_0xd61586['name']===_0x5983e9['name'])return _0xd61586['cubeTexture'];}}else(_0x1511bf=_0x5a0ced['_CreateRenderTargetTexture'](_0x5983e9['name'],_0x5983e9['renderTargetSize'],_0x8ad946,_0x3d9b67))['_waitingRenderList']=_0x5983e9['renderList'];return _0x22ebf5(),_0x1511bf;}if(_0x5983e9['base64String'])_0x20bb0d=_0x5a0ced['CreateFromBase64String'](_0x5983e9['base64String'],_0x5983e9['name'],_0x8ad946,!_0x3d9b67,_0x5983e9['invertY'],void 0x0,_0x22ebf5);else{var _0x29dd54=void 0x0;_0x29dd54=_0x5983e9['name']&&_0x5983e9['name']['indexOf']('://')>0x0?_0x5983e9['name']:_0x177e5a+_0x5983e9['name'],(_0x2c1746['a']['StartsWith'](_0x5983e9['url'],'data:')||_0x5a0ced['UseSerializedUrlIfAny']&&_0x5983e9['url'])&&(_0x29dd54=_0x5983e9['url']),_0x20bb0d=new _0x5a0ced(_0x29dd54,_0x8ad946,!_0x3d9b67,_0x5983e9['invertY'],void 0x0,_0x22ebf5);}return _0x20bb0d;},_0x5983e9,_0x8ad946);return _0x43073d;},_0x5a0ced['CreateFromBase64String']=function(_0x1c5ca3,_0x4f73dc,_0x549bd0,_0x26526b,_0x316a90,_0x1cba3c,_0x49aff9,_0x5777b8,_0x27569a){return void 0x0===_0x1cba3c&&(_0x1cba3c=_0x5a0ced['TRILINEAR_SAMPLINGMODE']),void 0x0===_0x49aff9&&(_0x49aff9=null),void 0x0===_0x5777b8&&(_0x5777b8=null),void 0x0===_0x27569a&&(_0x27569a=_0x8357bd['a']['TEXTUREFORMAT_RGBA']),new _0x5a0ced('data:'+_0x4f73dc,_0x549bd0,_0x26526b,_0x316a90,_0x1cba3c,_0x49aff9,_0x5777b8,_0x1c5ca3,!0x1,_0x27569a);},_0x5a0ced['LoadFromDataString']=function(_0xf3f5ee,_0x47fefa,_0x14ed9d,_0x390736,_0x168392,_0x129013,_0x725fb3,_0x39ab21,_0x17f363,_0x5ca8d4){return void 0x0===_0x390736&&(_0x390736=!0x1),void 0x0===_0x168392&&(_0x168392=!0x1),void 0x0===_0x129013&&(_0x129013=!0x0),void 0x0===_0x725fb3&&(_0x725fb3=_0x5a0ced['TRILINEAR_SAMPLINGMODE']),void 0x0===_0x39ab21&&(_0x39ab21=null),void 0x0===_0x17f363&&(_0x17f363=null),void 0x0===_0x5ca8d4&&(_0x5ca8d4=_0x8357bd['a']['TEXTUREFORMAT_RGBA']),'data:'!==_0xf3f5ee['substr'](0x0,0x5)&&(_0xf3f5ee='data:'+_0xf3f5ee),new _0x5a0ced(_0xf3f5ee,_0x14ed9d,_0x168392,_0x129013,_0x725fb3,_0x39ab21,_0x17f363,_0x47fefa,_0x390736,_0x5ca8d4);},_0x5a0ced['SerializeBuffers']=!0x0,_0x5a0ced['ForceSerializeBuffers']=!0x1,_0x5a0ced['_CubeTextureParser']=function(_0x3c3797,_0x59c087,_0x53bcf6){throw _0x19112c['a']['WarnImport']('CubeTexture');},_0x5a0ced['_CreateMirror']=function(_0x343aa8,_0x48d3e3,_0x37da5a,_0x128e07){throw _0x19112c['a']['WarnImport']('MirrorTexture');},_0x5a0ced['_CreateRenderTargetTexture']=function(_0x306fcc,_0x5cd67f,_0x41f4d9,_0x3558b8){throw _0x19112c['a']['WarnImport']('RenderTargetTexture');},_0x5a0ced['NEAREST_SAMPLINGMODE']=_0x8357bd['a']['TEXTURE_NEAREST_SAMPLINGMODE'],_0x5a0ced['NEAREST_NEAREST_MIPLINEAR']=_0x8357bd['a']['TEXTURE_NEAREST_NEAREST_MIPLINEAR'],_0x5a0ced['BILINEAR_SAMPLINGMODE']=_0x8357bd['a']['TEXTURE_BILINEAR_SAMPLINGMODE'],_0x5a0ced['LINEAR_LINEAR_MIPNEAREST']=_0x8357bd['a']['TEXTURE_LINEAR_LINEAR_MIPNEAREST'],_0x5a0ced['TRILINEAR_SAMPLINGMODE']=_0x8357bd['a']['TEXTURE_TRILINEAR_SAMPLINGMODE'],_0x5a0ced['LINEAR_LINEAR_MIPLINEAR']=_0x8357bd['a']['TEXTURE_LINEAR_LINEAR_MIPLINEAR'],_0x5a0ced['NEAREST_NEAREST_MIPNEAREST']=_0x8357bd['a']['TEXTURE_NEAREST_NEAREST_MIPNEAREST'],_0x5a0ced['NEAREST_LINEAR_MIPNEAREST']=_0x8357bd['a']['TEXTURE_NEAREST_LINEAR_MIPNEAREST'],_0x5a0ced['NEAREST_LINEAR_MIPLINEAR']=_0x8357bd['a']['TEXTURE_NEAREST_LINEAR_MIPLINEAR'],_0x5a0ced['NEAREST_LINEAR']=_0x8357bd['a']['TEXTURE_NEAREST_LINEAR'],_0x5a0ced['NEAREST_NEAREST']=_0x8357bd['a']['TEXTURE_NEAREST_NEAREST'],_0x5a0ced['LINEAR_NEAREST_MIPNEAREST']=_0x8357bd['a']['TEXTURE_LINEAR_NEAREST_MIPNEAREST'],_0x5a0ced['LINEAR_NEAREST_MIPLINEAR']=_0x8357bd['a']['TEXTURE_LINEAR_NEAREST_MIPLINEAR'],_0x5a0ced['LINEAR_LINEAR']=_0x8357bd['a']['TEXTURE_LINEAR_LINEAR'],_0x5a0ced['LINEAR_NEAREST']=_0x8357bd['a']['TEXTURE_LINEAR_NEAREST'],_0x5a0ced['EXPLICIT_MODE']=_0x8357bd['a']['TEXTURE_EXPLICIT_MODE'],_0x5a0ced['SPHERICAL_MODE']=_0x8357bd['a']['TEXTURE_SPHERICAL_MODE'],_0x5a0ced['PLANAR_MODE']=_0x8357bd['a']['TEXTURE_PLANAR_MODE'],_0x5a0ced['CUBIC_MODE']=_0x8357bd['a']['TEXTURE_CUBIC_MODE'],_0x5a0ced['PROJECTION_MODE']=_0x8357bd['a']['TEXTURE_PROJECTION_MODE'],_0x5a0ced['SKYBOX_MODE']=_0x8357bd['a']['TEXTURE_SKYBOX_MODE'],_0x5a0ced['INVCUBIC_MODE']=_0x8357bd['a']['TEXTURE_INVCUBIC_MODE'],_0x5a0ced['EQUIRECTANGULAR_MODE']=_0x8357bd['a']['TEXTURE_EQUIRECTANGULAR_MODE'],_0x5a0ced['FIXED_EQUIRECTANGULAR_MODE']=_0x8357bd['a']['TEXTURE_FIXED_EQUIRECTANGULAR_MODE'],_0x5a0ced['FIXED_EQUIRECTANGULAR_MIRRORED_MODE']=_0x8357bd['a']['TEXTURE_FIXED_EQUIRECTANGULAR_MIRRORED_MODE'],_0x5a0ced['CLAMP_ADDRESSMODE']=_0x8357bd['a']['TEXTURE_CLAMP_ADDRESSMODE'],_0x5a0ced['WRAP_ADDRESSMODE']=_0x8357bd['a']['TEXTURE_WRAP_ADDRESSMODE'],_0x5a0ced['MIRROR_ADDRESSMODE']=_0x8357bd['a']['TEXTURE_MIRROR_ADDRESSMODE'],_0x5a0ced['UseSerializedUrlIfAny']=!0x1,Object(_0x1d39d1['c'])([Object(_0x5b095a['c'])()],_0x5a0ced['prototype'],'url',void 0x0),Object(_0x1d39d1['c'])([Object(_0x5b095a['c'])()],_0x5a0ced['prototype'],'uOffset',void 0x0),Object(_0x1d39d1['c'])([Object(_0x5b095a['c'])()],_0x5a0ced['prototype'],'vOffset',void 0x0),Object(_0x1d39d1['c'])([Object(_0x5b095a['c'])()],_0x5a0ced['prototype'],'uScale',void 0x0),Object(_0x1d39d1['c'])([Object(_0x5b095a['c'])()],_0x5a0ced['prototype'],'vScale',void 0x0),Object(_0x1d39d1['c'])([Object(_0x5b095a['c'])()],_0x5a0ced['prototype'],'uAng',void 0x0),Object(_0x1d39d1['c'])([Object(_0x5b095a['c'])()],_0x5a0ced['prototype'],'vAng',void 0x0),Object(_0x1d39d1['c'])([Object(_0x5b095a['c'])()],_0x5a0ced['prototype'],'wAng',void 0x0),Object(_0x1d39d1['c'])([Object(_0x5b095a['c'])()],_0x5a0ced['prototype'],'uRotationCenter',void 0x0),Object(_0x1d39d1['c'])([Object(_0x5b095a['c'])()],_0x5a0ced['prototype'],'vRotationCenter',void 0x0),Object(_0x1d39d1['c'])([Object(_0x5b095a['c'])()],_0x5a0ced['prototype'],'wRotationCenter',void 0x0),Object(_0x1d39d1['c'])([Object(_0x5b095a['c'])()],_0x5a0ced['prototype'],'homogeneousRotationInUVTransform',void 0x0),Object(_0x1d39d1['c'])([Object(_0x5b095a['c'])()],_0x5a0ced['prototype'],'isBlocking',null),_0x5a0ced;}(_0x53e341['a']);_0x461b91['a']['RegisteredTypes']['BABYLON.Texture']=_0x41bccd,_0x5b095a['a']['_TextureParser']=_0x41bccd['Parse'];},function(_0x2df338,_0x2dd54f,_0x1b61f4){'use strict';_0x1b61f4['d'](_0x2dd54f,'a',function(){return _0x1677e8;});var _0x1677e8=(function(){function _0x6d812(){}return _0x6d812['GetClass']=function(_0x591c06){return this['RegisteredTypes']&&this['RegisteredTypes'][_0x591c06]?this['RegisteredTypes'][_0x591c06]:null;},_0x6d812['RegisteredTypes']={},_0x6d812;}());},function(_0x37f4a6,_0x9dc418,_0x570659){'use strict';_0x570659['d'](_0x9dc418,'b',function(){return _0x1c038c;}),_0x570659['d'](_0x9dc418,'c',function(){return _0x329b3c;}),_0x570659['d'](_0x9dc418,'a',function(){return _0x5bff7d;});var _0x150264=_0x570659(0x6),_0x3ea217=_0x570659(0x26),_0x439fdb=_0x570659(0x8),_0x15a4dd=_0x570659(0x29),_0x17c643=_0x570659(0x39),_0x14256a=_0x570659(0x15),_0x4e9be2=_0x570659(0x31),_0x3b3bee=_0x570659(0x16),_0x399699=_0x570659(0x38),_0x53110d=_0x570659(0x91),_0x4e266d=_0x570659(0x68),_0x2294d2=_0x570659(0x7a),_0x1812a5=_0x570659(0x78),_0x1c038c=(function(){function _0x50cd34(){}return Object['defineProperty'](_0x50cd34,'BaseUrl',{'get':function(){return _0x399699['a']['BaseUrl'];},'set':function(_0x2397a7){_0x399699['a']['BaseUrl']=_0x2397a7;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x50cd34,'DefaultRetryStrategy',{'get':function(){return _0x399699['a']['DefaultRetryStrategy'];},'set':function(_0x522c07){_0x399699['a']['DefaultRetryStrategy']=_0x522c07;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x50cd34,'CorsBehavior',{'get':function(){return _0x399699['a']['CorsBehavior'];},'set':function(_0x47d34b){_0x399699['a']['CorsBehavior']=_0x47d34b;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x50cd34,'UseFallbackTexture',{'get':function(){return _0x3b3bee['a']['UseFallbackTexture'];},'set':function(_0x5d6575){_0x3b3bee['a']['UseFallbackTexture']=_0x5d6575;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x50cd34,'RegisteredExternalClasses',{'get':function(){return _0x2294d2['a']['RegisteredExternalClasses'];},'set':function(_0x183dcb){_0x2294d2['a']['RegisteredExternalClasses']=_0x183dcb;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x50cd34,'fallbackTexture',{'get':function(){return _0x3b3bee['a']['FallbackTexture'];},'set':function(_0x4e4edc){_0x3b3bee['a']['FallbackTexture']=_0x4e4edc;},'enumerable':!0x1,'configurable':!0x0}),_0x50cd34['FetchToRef']=function(_0x3bbb60,_0x1bd7a5,_0x4a11d9,_0x6a2cc7,_0x47e7b3,_0x3ac9c7){var _0x14c7a9=0x4*((Math['abs'](_0x3bbb60)*_0x4a11d9%_0x4a11d9|0x0)+(Math['abs'](_0x1bd7a5)*_0x6a2cc7%_0x6a2cc7|0x0)*_0x4a11d9);_0x3ac9c7['r']=_0x47e7b3[_0x14c7a9]/0xff,_0x3ac9c7['g']=_0x47e7b3[_0x14c7a9+0x1]/0xff,_0x3ac9c7['b']=_0x47e7b3[_0x14c7a9+0x2]/0xff,_0x3ac9c7['a']=_0x47e7b3[_0x14c7a9+0x3]/0xff;},_0x50cd34['Mix']=function(_0x563e70,_0x1a0f4e,_0x5f3b82){return _0x563e70*(0x1-_0x5f3b82)+_0x1a0f4e*_0x5f3b82;},_0x50cd34['Instantiate']=function(_0x2f63a1){return _0x2294d2['a']['Instantiate'](_0x2f63a1);},_0x50cd34['Slice']=function(_0x39ee9e,_0x109805,_0x40ab7a){return _0x39ee9e['slice']?_0x39ee9e['slice'](_0x109805,_0x40ab7a):Array['prototype']['slice']['call'](_0x39ee9e,_0x109805,_0x40ab7a);},_0x50cd34['SliceToArray']=function(_0x4d034a,_0x99a14,_0x4072da){return Array['isArray'](_0x4d034a)?_0x4d034a['slice'](_0x99a14,_0x4072da):Array['prototype']['slice']['call'](_0x4d034a,_0x99a14,_0x4072da);},_0x50cd34['SetImmediate']=function(_0x43e209){_0x4e266d['a']['SetImmediate'](_0x43e209);},_0x50cd34['IsExponentOfTwo']=function(_0x4fe90f){var _0x58b947=0x1;do{_0x58b947*=0x2;}while(_0x58b947<_0x4fe90f);return _0x58b947===_0x4fe90f;},_0x50cd34['FloatRound']=function(_0x1f6c92){return Math['fround']?Math['fround'](_0x1f6c92):_0x50cd34['_tmpFloatArray'][0x0]=_0x1f6c92;},_0x50cd34['GetFilename']=function(_0x1f4cf8){var _0x1f8aa1=_0x1f4cf8['lastIndexOf']('/');return _0x1f8aa1<0x0?_0x1f4cf8:_0x1f4cf8['substring'](_0x1f8aa1+0x1);},_0x50cd34['GetFolderPath']=function(_0x1a104e,_0x361a27){void 0x0===_0x361a27&&(_0x361a27=!0x1);var _0x1d7d6c=_0x1a104e['lastIndexOf']('/');return _0x1d7d6c<0x0?_0x361a27?_0x1a104e:'':_0x1a104e['substring'](0x0,_0x1d7d6c+0x1);},_0x50cd34['ToDegrees']=function(_0x34848e){return 0xb4*_0x34848e/Math['PI'];},_0x50cd34['ToRadians']=function(_0x361c96){return _0x361c96*Math['PI']/0xb4;},_0x50cd34['MakeArray']=function(_0x17f20d,_0x46d2b9){return!0x0===_0x46d2b9||void 0x0!==_0x17f20d&&null!=_0x17f20d?Array['isArray'](_0x17f20d)?_0x17f20d:[_0x17f20d]:null;},_0x50cd34['GetPointerPrefix']=function(_0x47e597){var _0x50bca0='pointer';return _0x3ea217['a']['IsWindowObjectExist']()&&!window['PointerEvent']&&_0x3ea217['a']['IsNavigatorAvailable']()&&!navigator['pointerEnabled']&&(_0x50bca0='mouse'),!_0x47e597['_badDesktopOS']||_0x47e597['_badOS']||document&&'ontouchend'in document||(_0x50bca0='mouse'),_0x50bca0;},_0x50cd34['SetCorsBehavior']=function(_0x38cf3c,_0x3a039c){_0x399699['a']['SetCorsBehavior'](_0x38cf3c,_0x3a039c);},_0x50cd34['CleanUrl']=function(_0x118938){return _0x118938=_0x118938['replace'](/#/gm,'%23');},Object['defineProperty'](_0x50cd34,'PreprocessUrl',{'get':function(){return _0x399699['a']['PreprocessUrl'];},'set':function(_0x193f88){_0x399699['a']['PreprocessUrl']=_0x193f88;},'enumerable':!0x1,'configurable':!0x0}),_0x50cd34['LoadImage']=function(_0x1b967b,_0x2c6b5b,_0xa9b03c,_0x463619,_0x23939c){return _0x399699['a']['LoadImage'](_0x1b967b,_0x2c6b5b,_0xa9b03c,_0x463619,_0x23939c);},_0x50cd34['LoadFile']=function(_0x2b70f4,_0x5d4ce2,_0x19e3eb,_0x48a0cb,_0x455b1a,_0x329ac3){return _0x399699['a']['LoadFile'](_0x2b70f4,_0x5d4ce2,_0x19e3eb,_0x48a0cb,_0x455b1a,_0x329ac3);},_0x50cd34['LoadFileAsync']=function(_0x30464b,_0x94a269){return void 0x0===_0x94a269&&(_0x94a269=!0x0),new Promise(function(_0x2074a1,_0x4c9309){_0x399699['a']['LoadFile'](_0x30464b,function(_0xbfb30){_0x2074a1(_0xbfb30);},void 0x0,void 0x0,_0x94a269,function(_0x1a91bc,_0x43bd72){_0x4c9309(_0x43bd72);});});},_0x50cd34['LoadScript']=function(_0x3c7743,_0x32ecbd,_0x4e309a,_0x265456){if(_0x3ea217['a']['IsWindowObjectExist']()){var _0x206f65=document['getElementsByTagName']('head')[0x0],_0x35b5e5=document['createElement']('script');_0x35b5e5['setAttribute']('type','text/javascript'),_0x35b5e5['setAttribute']('src',_0x3c7743),_0x265456&&(_0x35b5e5['id']=_0x265456),_0x35b5e5['onload']=function(){_0x32ecbd&&_0x32ecbd();},_0x35b5e5['onerror']=function(_0x2718af){_0x4e309a&&_0x4e309a('Unable\x20to\x20load\x20script\x20\x27'+_0x3c7743+'\x27',_0x2718af);},_0x206f65['appendChild'](_0x35b5e5);}},_0x50cd34['LoadScriptAsync']=function(_0x52e77e,_0x42a6d4){var _0x10a964=this;return new Promise(function(_0x219c90,_0x1714d8){_0x10a964['LoadScript'](_0x52e77e,function(){_0x219c90();},function(_0xc183d4,_0x5c3b01){_0x1714d8(_0x5c3b01);});});},_0x50cd34['ReadFileAsDataURL']=function(_0x4c2200,_0x1329d5,_0x13c395){var _0x54833f=new FileReader(),_0x252136={'onCompleteObservable':new _0x150264['c'](),'abort':function(){return _0x54833f['abort']();}};return _0x54833f['onloadend']=function(_0x39800c){_0x252136['onCompleteObservable']['notifyObservers'](_0x252136);},_0x54833f['onload']=function(_0x748cc5){_0x1329d5(_0x748cc5['target']['result']);},_0x54833f['onprogress']=_0x13c395,_0x54833f['readAsDataURL'](_0x4c2200),_0x252136;},_0x50cd34['ReadFile']=function(_0x19c444,_0x269fbd,_0x47e979,_0x4f7d43,_0x205433){return _0x399699['a']['ReadFile'](_0x19c444,_0x269fbd,_0x47e979,_0x4f7d43,_0x205433);},_0x50cd34['FileAsURL']=function(_0x2979cc){var _0x15da54=new Blob([_0x2979cc]);return(window['URL']||window['webkitURL'])['createObjectURL'](_0x15da54);},_0x50cd34['Format']=function(_0x1fc3bf,_0x188427){return void 0x0===_0x188427&&(_0x188427=0x2),_0x1fc3bf['toFixed'](_0x188427);},_0x50cd34['DeepCopy']=function(_0x41f57b,_0x1acee5,_0x422298,_0x43ae93){_0x15a4dd['a']['DeepCopy'](_0x41f57b,_0x1acee5,_0x422298,_0x43ae93);},_0x50cd34['IsEmpty']=function(_0x4ec90d){for(var _0x5181de in _0x4ec90d)if(_0x4ec90d['hasOwnProperty'](_0x5181de))return!0x1;return!0x0;},_0x50cd34['RegisterTopRootEvents']=function(_0x32b369,_0x4c31fb){for(var _0xb5bb=0x0;_0xb5bb<_0x4c31fb['length'];_0xb5bb++){var _0x139bf0=_0x4c31fb[_0xb5bb];_0x32b369['addEventListener'](_0x139bf0['name'],_0x139bf0['handler'],!0x1);try{window['parent']&&window['parent']['addEventListener'](_0x139bf0['name'],_0x139bf0['handler'],!0x1);}catch(_0x350698){}}},_0x50cd34['UnregisterTopRootEvents']=function(_0x94ab1d,_0x18dbde){for(var _0x267c22=0x0;_0x267c22<_0x18dbde['length'];_0x267c22++){var _0x391f92=_0x18dbde[_0x267c22];_0x94ab1d['removeEventListener'](_0x391f92['name'],_0x391f92['handler']);try{_0x94ab1d['parent']&&_0x94ab1d['parent']['removeEventListener'](_0x391f92['name'],_0x391f92['handler']);}catch(_0x3e5f92){}}},_0x50cd34['DumpFramebuffer']=function(_0x5dc02b,_0x54b9a1,_0x38bc2d,_0x401816,_0x7d5f5e,_0x358207){void 0x0===_0x7d5f5e&&(_0x7d5f5e='image/png');for(var _0x10f411=0x4*_0x5dc02b,_0x28e3a0=_0x54b9a1/0x2,_0x5c2ccb=_0x38bc2d['readPixels'](0x0,0x0,_0x5dc02b,_0x54b9a1),_0x4a652a=0x0;_0x4a652a<_0x28e3a0;_0x4a652a++)for(var _0x444a8c=0x0;_0x444a8c<_0x10f411;_0x444a8c++){var _0x3befb0=_0x444a8c+_0x4a652a*_0x10f411,_0x4ffb1c=_0x444a8c+(_0x54b9a1-_0x4a652a-0x1)*_0x10f411,_0x43fe4f=_0x5c2ccb[_0x3befb0];_0x5c2ccb[_0x3befb0]=_0x5c2ccb[_0x4ffb1c],_0x5c2ccb[_0x4ffb1c]=_0x43fe4f;}_0x50cd34['_ScreenshotCanvas']||(_0x50cd34['_ScreenshotCanvas']=document['createElement']('canvas')),_0x50cd34['_ScreenshotCanvas']['width']=_0x5dc02b,_0x50cd34['_ScreenshotCanvas']['height']=_0x54b9a1;var _0xb6ebd7=_0x50cd34['_ScreenshotCanvas']['getContext']('2d');if(_0xb6ebd7){var _0x1df46c=_0xb6ebd7['createImageData'](_0x5dc02b,_0x54b9a1);_0x1df46c['data']['set'](_0x5c2ccb),_0xb6ebd7['putImageData'](_0x1df46c,0x0,0x0),_0x50cd34['EncodeScreenshotCanvasData'](_0x401816,_0x7d5f5e,_0x358207);}},_0x50cd34['ToBlob']=function(_0xa0c7c3,_0x147d23,_0x5e8e70){void 0x0===_0x5e8e70&&(_0x5e8e70='image/png'),_0xa0c7c3['toBlob']||(_0xa0c7c3['toBlob']=function(_0x1f0eb4,_0x3cba1e,_0x67d5f0){var _0x5410b4=this;setTimeout(function(){for(var _0x129290=atob(_0x5410b4['toDataURL'](_0x3cba1e,_0x67d5f0)['split'](',')[0x1]),_0x548ca8=_0x129290['length'],_0x485541=new Uint8Array(_0x548ca8),_0x5d8bd5=0x0;_0x5d8bd5<_0x548ca8;_0x5d8bd5++)_0x485541[_0x5d8bd5]=_0x129290['charCodeAt'](_0x5d8bd5);_0x1f0eb4(new Blob([_0x485541]));});}),_0xa0c7c3['toBlob'](function(_0x4bd7bd){_0x147d23(_0x4bd7bd);},_0x5e8e70);},_0x50cd34['EncodeScreenshotCanvasData']=function(_0x567466,_0x39ec1a,_0x4f6b28){(void 0x0===_0x39ec1a&&(_0x39ec1a='image/png'),_0x567466)?_0x567466(_0x50cd34['_ScreenshotCanvas']['toDataURL'](_0x39ec1a)):this['ToBlob'](_0x50cd34['_ScreenshotCanvas'],function(_0x17445b){if('download'in document['createElement']('a')){if(!_0x4f6b28){var _0x1e3933=new Date(),_0x38b7a5=(_0x1e3933['getFullYear']()+'-'+(_0x1e3933['getMonth']()+0x1))['slice'](0x2)+'-'+_0x1e3933['getDate']()+'_'+_0x1e3933['getHours']()+'-'+('0'+_0x1e3933['getMinutes']())['slice'](-0x2);_0x4f6b28='screenshot_'+_0x38b7a5+'.png';}_0x50cd34['Download'](_0x17445b,_0x4f6b28);}else{var _0xdf2620=URL['createObjectURL'](_0x17445b),_0xce15e0=window['open']('');if(!_0xce15e0)return;var _0x3db4ae=_0xce15e0['document']['createElement']('img');_0x3db4ae['onload']=function(){URL['revokeObjectURL'](_0xdf2620);},_0x3db4ae['src']=_0xdf2620,_0xce15e0['document']['body']['appendChild'](_0x3db4ae);}},_0x39ec1a);},_0x50cd34['Download']=function(_0x49a1bf,_0x2a3516){if(navigator&&navigator['msSaveBlob'])navigator['msSaveBlob'](_0x49a1bf,_0x2a3516);else{var _0x235b71=window['URL']['createObjectURL'](_0x49a1bf),_0x231c45=document['createElement']('a');document['body']['appendChild'](_0x231c45),_0x231c45['style']['display']='none',_0x231c45['href']=_0x235b71,_0x231c45['download']=_0x2a3516,_0x231c45['addEventListener']('click',function(){_0x231c45['parentElement']&&_0x231c45['parentElement']['removeChild'](_0x231c45);}),_0x231c45['click'](),window['URL']['revokeObjectURL'](_0x235b71);}},_0x50cd34['BackCompatCameraNoPreventDefault']=function(_0x25d289){return'boolean'==typeof _0x25d289[0x0]?_0x25d289[0x0]:'boolean'==typeof _0x25d289[0x1]&&_0x25d289[0x1];},_0x50cd34['CreateScreenshot']=function(_0xc89751,_0x2e38b1,_0x54e103,_0xf86f1d,_0x40e783){throw void 0x0===_0x40e783&&(_0x40e783='image/png'),_0x14256a['a']['WarnImport']('ScreenshotTools');},_0x50cd34['CreateScreenshotAsync']=function(_0x3f01c8,_0x15097f,_0x38a011,_0x4ff88a){throw void 0x0===_0x4ff88a&&(_0x4ff88a='image/png'),_0x14256a['a']['WarnImport']('ScreenshotTools');},_0x50cd34['CreateScreenshotUsingRenderTarget']=function(_0x2a3591,_0xf0071a,_0x24d629,_0x1c7eed,_0x253f91,_0x2d38c3,_0x3d5fa4,_0x397dc8){throw void 0x0===_0x253f91&&(_0x253f91='image/png'),void 0x0===_0x2d38c3&&(_0x2d38c3=0x1),void 0x0===_0x3d5fa4&&(_0x3d5fa4=!0x1),_0x14256a['a']['WarnImport']('ScreenshotTools');},_0x50cd34['CreateScreenshotUsingRenderTargetAsync']=function(_0x2c73b5,_0x2c76ad,_0xf4b922,_0x411cac,_0x4f3963,_0x19047e,_0x1cfbb7){throw void 0x0===_0x411cac&&(_0x411cac='image/png'),void 0x0===_0x4f3963&&(_0x4f3963=0x1),void 0x0===_0x19047e&&(_0x19047e=!0x1),_0x14256a['a']['WarnImport']('ScreenshotTools');},_0x50cd34['RandomId']=function(){return _0x1812a5['a']['RandomId']();},_0x50cd34['IsBase64']=function(_0x2c9c66){return!(_0x2c9c66['length']<0x5)&&'data:'===_0x2c9c66['substr'](0x0,0x5);},_0x50cd34['DecodeBase64']=function(_0x871830){for(var _0x472264=atob(_0x871830['split'](',')[0x1]),_0x48b27b=_0x472264['length'],_0x2dcaea=new Uint8Array(new ArrayBuffer(_0x48b27b)),_0x479b64=0x0;_0x479b64<_0x48b27b;_0x479b64++)_0x2dcaea[_0x479b64]=_0x472264['charCodeAt'](_0x479b64);return _0x2dcaea['buffer'];},_0x50cd34['GetAbsoluteUrl']=function(_0x33b1fb){var _0x3a127e=document['createElement']('a');return _0x3a127e['href']=_0x33b1fb,_0x3a127e['href'];},Object['defineProperty'](_0x50cd34,'errorsCount',{'get':function(){return _0x439fdb['a']['errorsCount'];},'enumerable':!0x1,'configurable':!0x0}),_0x50cd34['Log']=function(_0x487878){_0x439fdb['a']['Log'](_0x487878);},_0x50cd34['Warn']=function(_0xa9b23f){_0x439fdb['a']['Warn'](_0xa9b23f);},_0x50cd34['Error']=function(_0x1f4523){_0x439fdb['a']['Error'](_0x1f4523);},Object['defineProperty'](_0x50cd34,'LogCache',{'get':function(){return _0x439fdb['a']['LogCache'];},'enumerable':!0x1,'configurable':!0x0}),_0x50cd34['ClearLogCache']=function(){_0x439fdb['a']['ClearLogCache']();},Object['defineProperty'](_0x50cd34,'LogLevels',{'set':function(_0x244bd4){_0x439fdb['a']['LogLevels']=_0x244bd4;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x50cd34,'PerformanceLogLevel',{'set':function(_0x327490){return(_0x327490&_0x50cd34['PerformanceUserMarkLogLevel'])===_0x50cd34['PerformanceUserMarkLogLevel']?(_0x50cd34['StartPerformanceCounter']=_0x50cd34['_StartUserMark'],void(_0x50cd34['EndPerformanceCounter']=_0x50cd34['_EndUserMark'])):(_0x327490&_0x50cd34['PerformanceConsoleLogLevel'])===_0x50cd34['PerformanceConsoleLogLevel']?(_0x50cd34['StartPerformanceCounter']=_0x50cd34['_StartPerformanceConsole'],void(_0x50cd34['EndPerformanceCounter']=_0x50cd34['_EndPerformanceConsole'])):(_0x50cd34['StartPerformanceCounter']=_0x50cd34['_StartPerformanceCounterDisabled'],void(_0x50cd34['EndPerformanceCounter']=_0x50cd34['_EndPerformanceCounterDisabled']));},'enumerable':!0x1,'configurable':!0x0}),_0x50cd34['_StartPerformanceCounterDisabled']=function(_0x4f0e7b,_0x524d74){},_0x50cd34['_EndPerformanceCounterDisabled']=function(_0x228593,_0x198b5f){},_0x50cd34['_StartUserMark']=function(_0x2133d4,_0x5e44){if(void 0x0===_0x5e44&&(_0x5e44=!0x0),!_0x50cd34['_performance']){if(!_0x3ea217['a']['IsWindowObjectExist']())return;_0x50cd34['_performance']=window['performance'];}_0x5e44&&_0x50cd34['_performance']['mark']&&_0x50cd34['_performance']['mark'](_0x2133d4+'-Begin');},_0x50cd34['_EndUserMark']=function(_0x18f8d8,_0x815430){void 0x0===_0x815430&&(_0x815430=!0x0),_0x815430&&_0x50cd34['_performance']['mark']&&(_0x50cd34['_performance']['mark'](_0x18f8d8+'-End'),_0x50cd34['_performance']['measure'](_0x18f8d8,_0x18f8d8+'-Begin',_0x18f8d8+'-End'));},_0x50cd34['_StartPerformanceConsole']=function(_0x35832f,_0x295389){void 0x0===_0x295389&&(_0x295389=!0x0),_0x295389&&(_0x50cd34['_StartUserMark'](_0x35832f,_0x295389),console['time']&&console['time'](_0x35832f));},_0x50cd34['_EndPerformanceConsole']=function(_0x1a7002,_0x526108){void 0x0===_0x526108&&(_0x526108=!0x0),_0x526108&&(_0x50cd34['_EndUserMark'](_0x1a7002,_0x526108),console['timeEnd'](_0x1a7002));},Object['defineProperty'](_0x50cd34,'Now',{'get':function(){return _0x17c643['a']['Now'];},'enumerable':!0x1,'configurable':!0x0}),_0x50cd34['GetClassName']=function(_0xb9159a,_0x229c0a){void 0x0===_0x229c0a&&(_0x229c0a=!0x1);var _0xc14999=null;if(!_0x229c0a&&_0xb9159a['getClassName'])_0xc14999=_0xb9159a['getClassName']();else{if(_0xb9159a instanceof Object)_0xc14999=(_0x229c0a?_0xb9159a:Object['getPrototypeOf'](_0xb9159a))['constructor']['__bjsclassName__'];_0xc14999||(_0xc14999=typeof _0xb9159a);}return _0xc14999;},_0x50cd34['First']=function(_0x2db124,_0x4a1689){for(var _0x15d56d=0x0,_0x4250ef=_0x2db124;_0x15d56d<_0x4250ef['length'];_0x15d56d++){var _0x3e2d49=_0x4250ef[_0x15d56d];if(_0x4a1689(_0x3e2d49))return _0x3e2d49;}return null;},_0x50cd34['getFullClassName']=function(_0x53d3c4,_0x533c1a){void 0x0===_0x533c1a&&(_0x533c1a=!0x1);var _0x4905ee=null,_0xdb1222=null;if(!_0x533c1a&&_0x53d3c4['getClassName'])_0x4905ee=_0x53d3c4['getClassName']();else{if(_0x53d3c4 instanceof Object){var _0x296c1f=_0x533c1a?_0x53d3c4:Object['getPrototypeOf'](_0x53d3c4);_0x4905ee=_0x296c1f['constructor']['__bjsclassName__'],_0xdb1222=_0x296c1f['constructor']['__bjsmoduleName__'];}_0x4905ee||(_0x4905ee=typeof _0x53d3c4);}return _0x4905ee?(null!=_0xdb1222?_0xdb1222+'.':'')+_0x4905ee:null;},_0x50cd34['DelayAsync']=function(_0x76495a){return new Promise(function(_0x494944){setTimeout(function(){_0x494944();},_0x76495a);});},_0x50cd34['IsSafari']=function(){return/^((?!chrome|android).)*safari/i['test'](navigator['userAgent']);},_0x50cd34['UseCustomRequestHeaders']=!0x1,_0x50cd34['CustomRequestHeaders']=_0x4e9be2['a']['CustomRequestHeaders'],_0x50cd34['_tmpFloatArray']=new Float32Array(0x1),_0x50cd34['GetDOMTextContent']=_0x3ea217['a']['GetDOMTextContent'],_0x50cd34['NoneLogLevel']=_0x439fdb['a']['NoneLogLevel'],_0x50cd34['MessageLogLevel']=_0x439fdb['a']['MessageLogLevel'],_0x50cd34['WarningLogLevel']=_0x439fdb['a']['WarningLogLevel'],_0x50cd34['ErrorLogLevel']=_0x439fdb['a']['ErrorLogLevel'],_0x50cd34['AllLogLevel']=_0x439fdb['a']['AllLogLevel'],_0x50cd34['IsWindowObjectExist']=_0x3ea217['a']['IsWindowObjectExist'],_0x50cd34['PerformanceNoneLogLevel']=0x0,_0x50cd34['PerformanceUserMarkLogLevel']=0x1,_0x50cd34['PerformanceConsoleLogLevel']=0x2,_0x50cd34['StartPerformanceCounter']=_0x50cd34['_StartPerformanceCounterDisabled'],_0x50cd34['EndPerformanceCounter']=_0x50cd34['_EndPerformanceCounterDisabled'],_0x50cd34;}());function _0x329b3c(_0x2b70b4,_0x542276){return function(_0x58a6c3){_0x58a6c3['__bjsclassName__']=_0x2b70b4,_0x58a6c3['__bjsmoduleName__']=null!=_0x542276?_0x542276:null;};}var _0x5bff7d=(function(){function _0xdb72fb(_0xa9dea9,_0x1d0d60,_0x54ee1a,_0x5652ca){void 0x0===_0x5652ca&&(_0x5652ca=0x0),this['iterations']=_0xa9dea9,this['index']=_0x5652ca-0x1,this['_done']=!0x1,this['_fn']=_0x1d0d60,this['_successCallback']=_0x54ee1a;}return _0xdb72fb['prototype']['executeNext']=function(){this['_done']||(this['index']+0x1=_0x9f31f7)break;if(_0x262518(_0x18b0dd),_0x48f556&&_0x48f556()){_0xdb92af['breakLoop']();break;}}_0xdb92af['executeNext']();},_0x4dfe50);},_0x518550);},_0xdb72fb;}());_0x3b3bee['a']['FallbackTexture']='data:image/jpg;base64,/9j/4AAQSkZJRgABAQEAYABgAAD/4QBmRXhpZgAATU0AKgAAAAgABAEaAAUAAAABAAAAPgEbAAUAAAABAAAARgEoAAMAAAABAAIAAAExAAIAAAAQAAAATgAAAAAAAABgAAAAAQAAAGAAAAABcGFpbnQubmV0IDQuMC41AP/bAEMABAIDAwMCBAMDAwQEBAQFCQYFBQUFCwgIBgkNCw0NDQsMDA4QFBEODxMPDAwSGBITFRYXFxcOERkbGRYaFBYXFv/bAEMBBAQEBQUFCgYGChYPDA8WFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFv/AABEIAQABAAMBIgACEQEDEQH/xAAfAAABBQEBAQEBAQAAAAAAAAAAAQIDBAUGBwgJCgv/xAC1EAACAQMDAgQDBQUEBAAAAX0BAgMABBEFEiExQQYTUWEHInEUMoGRoQgjQrHBFVLR8CQzYnKCCQoWFxgZGiUmJygpKjQ1Njc4OTpDREVGR0hJSlNUVVZXWFlaY2RlZmdoaWpzdHV2d3h5eoOEhYaHiImKkpOUlZaXmJmaoqOkpaanqKmqsrO0tba3uLm6wsPExcbHyMnK0tPU1dbX2Nna4eLj5OXm5+jp6vHy8/T19vf4+fr/xAAfAQADAQEBAQEBAQEBAAAAAAAAAQIDBAUGBwgJCgv/xAC1EQACAQIEBAMEBwUEBAABAncAAQIDEQQFITEGEkFRB2FxEyIygQgUQpGhscEJIzNS8BVictEKFiQ04SXxFxgZGiYnKCkqNTY3ODk6Q0RFRkdISUpTVFVWV1hZWmNkZWZnaGlqc3R1dnd4eXqCg4SFhoeIiYqSk5SVlpeYmZqio6Slpqeoqaqys7S1tre4ubrCw8TFxsfIycrS09TV1tfY2dri4+Tl5ufo6ery8/T19vf4+fr/2gAMAwEAAhEDEQA/APH6KKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FCiiigD6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++gooooA+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gUKKKKAPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76CiiigD5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BQooooA+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/voKKKKAPl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FCiiigD6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++gooooA+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gUKKKKAPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76CiiigD5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BQooooA+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/voKKKKAPl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FCiiigD6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++gooooA+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gUKKKKAPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76P//Z',_0x53110d['a']['Apply']();},function(_0xb52daa,_0x170ad0,_0x5ea8e0){'use strict';_0x5ea8e0['d'](_0x170ad0,'a',function(){return _0xd8c4f4;});var _0x46fe6e=_0x5ea8e0(0x1),_0x30aa9c=_0x5ea8e0(0x6),_0x4deaec=_0x5ea8e0(0x26),_0x2651f1=_0x5ea8e0(0x16),_0x54497d=_0x5ea8e0(0x15),_0x100c28=_0x5ea8e0(0x1a),_0x488a1f=_0x5ea8e0(0x2),_0x3c3b24=_0x5ea8e0(0x92),_0x3dfceb=_0x5ea8e0(0x37),_0x13e011=_0x5ea8e0(0x58),_0x30866d=_0x5ea8e0(0x8),_0xd8c4f4=(_0x5ea8e0(0x7b),_0x5ea8e0(0x81),_0x5ea8e0(0x7c),function(_0x12ca78){function _0x16dc90(_0x35e0b7,_0x2d0e21,_0x35fc06,_0x4ff0b4){void 0x0===_0x4ff0b4&&(_0x4ff0b4=!0x1);var _0x7ad8d8=_0x12ca78['call'](this,_0x35e0b7,_0x2d0e21,_0x35fc06,_0x4ff0b4)||this;if(_0x7ad8d8['enableOfflineSupport']=!0x1,_0x7ad8d8['disableManifestCheck']=!0x1,_0x7ad8d8['scenes']=new Array(),_0x7ad8d8['onNewSceneAddedObservable']=new _0x30aa9c['c'](),_0x7ad8d8['postProcesses']=new Array(),_0x7ad8d8['isPointerLock']=!0x1,_0x7ad8d8['onResizeObservable']=new _0x30aa9c['c'](),_0x7ad8d8['onCanvasBlurObservable']=new _0x30aa9c['c'](),_0x7ad8d8['onCanvasFocusObservable']=new _0x30aa9c['c'](),_0x7ad8d8['onCanvasPointerOutObservable']=new _0x30aa9c['c'](),_0x7ad8d8['onBeginFrameObservable']=new _0x30aa9c['c'](),_0x7ad8d8['customAnimationFrameRequester']=null,_0x7ad8d8['onEndFrameObservable']=new _0x30aa9c['c'](),_0x7ad8d8['onBeforeShaderCompilationObservable']=new _0x30aa9c['c'](),_0x7ad8d8['onAfterShaderCompilationObservable']=new _0x30aa9c['c'](),_0x7ad8d8['_deterministicLockstep']=!0x1,_0x7ad8d8['_lockstepMaxSteps']=0x4,_0x7ad8d8['_timeStep']=0x1/0x3c,_0x7ad8d8['_fps']=0x3c,_0x7ad8d8['_deltaTime']=0x0,_0x7ad8d8['_drawCalls']=new _0x3dfceb['a'](),_0x7ad8d8['canvasTabIndex']=0x1,_0x7ad8d8['disablePerformanceMonitorInBackground']=!0x1,_0x7ad8d8['_performanceMonitor']=new _0x3c3b24['a'](),_0x16dc90['Instances']['push'](_0x7ad8d8),!_0x35e0b7)return _0x7ad8d8;if(_0x35fc06=_0x7ad8d8['_creationOptions'],_0x35e0b7['getContext']){var _0x2edadd=_0x35e0b7;if(_0x7ad8d8['_onCanvasFocus']=function(){_0x7ad8d8['onCanvasFocusObservable']['notifyObservers'](_0x7ad8d8);},_0x7ad8d8['_onCanvasBlur']=function(){_0x7ad8d8['onCanvasBlurObservable']['notifyObservers'](_0x7ad8d8);},_0x2edadd['addEventListener']('focus',_0x7ad8d8['_onCanvasFocus']),_0x2edadd['addEventListener']('blur',_0x7ad8d8['_onCanvasBlur']),_0x7ad8d8['_onBlur']=function(){_0x7ad8d8['disablePerformanceMonitorInBackground']&&_0x7ad8d8['_performanceMonitor']['disable'](),_0x7ad8d8['_windowIsBackground']=!0x0;},_0x7ad8d8['_onFocus']=function(){_0x7ad8d8['disablePerformanceMonitorInBackground']&&_0x7ad8d8['_performanceMonitor']['enable'](),_0x7ad8d8['_windowIsBackground']=!0x1;},_0x7ad8d8['_onCanvasPointerOut']=function(_0x3cd8eb){_0x7ad8d8['onCanvasPointerOutObservable']['notifyObservers'](_0x3cd8eb);},_0x2edadd['addEventListener']('pointerout',_0x7ad8d8['_onCanvasPointerOut']),_0x4deaec['a']['IsWindowObjectExist']()){var _0x1b0dc7=_0x7ad8d8['getHostWindow']();_0x1b0dc7['addEventListener']('blur',_0x7ad8d8['_onBlur']),_0x1b0dc7['addEventListener']('focus',_0x7ad8d8['_onFocus']);var _0x3a6652=document;_0x7ad8d8['_onFullscreenChange']=function(){void 0x0!==_0x3a6652['fullscreen']?_0x7ad8d8['isFullscreen']=_0x3a6652['fullscreen']:void 0x0!==_0x3a6652['mozFullScreen']?_0x7ad8d8['isFullscreen']=_0x3a6652['mozFullScreen']:void 0x0!==_0x3a6652['webkitIsFullScreen']?_0x7ad8d8['isFullscreen']=_0x3a6652['webkitIsFullScreen']:void 0x0!==_0x3a6652['msIsFullScreen']&&(_0x7ad8d8['isFullscreen']=_0x3a6652['msIsFullScreen']),_0x7ad8d8['isFullscreen']&&_0x7ad8d8['_pointerLockRequested']&&_0x2edadd&&_0x16dc90['_RequestPointerlock'](_0x2edadd);},document['addEventListener']('fullscreenchange',_0x7ad8d8['_onFullscreenChange'],!0x1),document['addEventListener']('mozfullscreenchange',_0x7ad8d8['_onFullscreenChange'],!0x1),document['addEventListener']('webkitfullscreenchange',_0x7ad8d8['_onFullscreenChange'],!0x1),document['addEventListener']('msfullscreenchange',_0x7ad8d8['_onFullscreenChange'],!0x1),_0x7ad8d8['_onPointerLockChange']=function(){_0x7ad8d8['isPointerLock']=_0x3a6652['mozPointerLockElement']===_0x2edadd||_0x3a6652['webkitPointerLockElement']===_0x2edadd||_0x3a6652['msPointerLockElement']===_0x2edadd||_0x3a6652['pointerLockElement']===_0x2edadd;},document['addEventListener']('pointerlockchange',_0x7ad8d8['_onPointerLockChange'],!0x1),document['addEventListener']('mspointerlockchange',_0x7ad8d8['_onPointerLockChange'],!0x1),document['addEventListener']('mozpointerlockchange',_0x7ad8d8['_onPointerLockChange'],!0x1),document['addEventListener']('webkitpointerlockchange',_0x7ad8d8['_onPointerLockChange'],!0x1),!_0x16dc90['audioEngine']&&_0x35fc06['audioEngine']&&_0x16dc90['AudioEngineFactory']&&(_0x16dc90['audioEngine']=_0x16dc90['AudioEngineFactory'](_0x7ad8d8['getRenderingCanvas']()));}_0x7ad8d8['_connectVREvents'](),_0x7ad8d8['enableOfflineSupport']=void 0x0!==_0x16dc90['OfflineProviderFactory'],_0x35fc06['doNotHandleTouchAction']||_0x7ad8d8['_disableTouchAction'](),_0x7ad8d8['_deterministicLockstep']=!!_0x35fc06['deterministicLockstep'],_0x7ad8d8['_lockstepMaxSteps']=_0x35fc06['lockstepMaxSteps']||0x0,_0x7ad8d8['_timeStep']=_0x35fc06['timeStep']||0x1/0x3c;}return _0x7ad8d8['_prepareVRComponent'](),_0x35fc06['autoEnableWebVR']&&_0x7ad8d8['initWebVR'](),_0x7ad8d8;}return Object(_0x46fe6e['d'])(_0x16dc90,_0x12ca78),Object['defineProperty'](_0x16dc90,'NpmPackage',{'get':function(){return _0x100c28['a']['NpmPackage'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x16dc90,'Version',{'get':function(){return _0x100c28['a']['Version'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x16dc90,'Instances',{'get':function(){return _0x2651f1['a']['Instances'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x16dc90,'LastCreatedEngine',{'get':function(){return _0x2651f1['a']['LastCreatedEngine'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x16dc90,'LastCreatedScene',{'get':function(){return _0x2651f1['a']['LastCreatedScene'];},'enumerable':!0x1,'configurable':!0x0}),_0x16dc90['MarkAllMaterialsAsDirty']=function(_0xb9e88b,_0x4b334b){for(var _0x151774=0x0;_0x151774<_0x16dc90['Instances']['length'];_0x151774++)for(var _0x2663cc=_0x16dc90['Instances'][_0x151774],_0x50ed7b=0x0;_0x50ed7b<_0x2663cc['scenes']['length'];_0x50ed7b++)_0x2663cc['scenes'][_0x50ed7b]['markAllMaterialsAsDirty'](_0xb9e88b,_0x4b334b);},_0x16dc90['DefaultLoadingScreenFactory']=function(_0x64b2a1){throw _0x54497d['a']['WarnImport']('LoadingScreen');},Object['defineProperty'](_0x16dc90['prototype'],'_supportsHardwareTextureRescaling',{'get':function(){return!!_0x16dc90['_RescalePostProcessFactory'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x16dc90['prototype'],'performanceMonitor',{'get':function(){return this['_performanceMonitor'];},'enumerable':!0x1,'configurable':!0x0}),_0x16dc90['prototype']['getInputElement']=function(){return this['_renderingCanvas'];},_0x16dc90['prototype']['getAspectRatio']=function(_0x3401b4,_0x218cb8){void 0x0===_0x218cb8&&(_0x218cb8=!0x1);var _0x51a69c=_0x3401b4['viewport'];return this['getRenderWidth'](_0x218cb8)*_0x51a69c['width']/(this['getRenderHeight'](_0x218cb8)*_0x51a69c['height']);},_0x16dc90['prototype']['getScreenAspectRatio']=function(){return this['getRenderWidth'](!0x0)/this['getRenderHeight'](!0x0);},_0x16dc90['prototype']['getRenderingCanvasClientRect']=function(){return this['_renderingCanvas']?this['_renderingCanvas']['getBoundingClientRect']():null;},_0x16dc90['prototype']['getInputElementClientRect']=function(){return this['_renderingCanvas']?this['getInputElement']()['getBoundingClientRect']():null;},_0x16dc90['prototype']['isDeterministicLockStep']=function(){return this['_deterministicLockstep'];},_0x16dc90['prototype']['getLockstepMaxSteps']=function(){return this['_lockstepMaxSteps'];},_0x16dc90['prototype']['getTimeStep']=function(){return 0x3e8*this['_timeStep'];},_0x16dc90['prototype']['generateMipMapsForCubemap']=function(_0x1b18a4,_0x246787){if(void 0x0===_0x246787&&(_0x246787=!0x0),_0x1b18a4['generateMipMaps']){var _0x431d61=this['_gl'];this['_bindTextureDirectly'](_0x431d61['TEXTURE_CUBE_MAP'],_0x1b18a4,!0x0),_0x431d61['generateMipmap'](_0x431d61['TEXTURE_CUBE_MAP']),_0x246787&&this['_bindTextureDirectly'](_0x431d61['TEXTURE_CUBE_MAP'],null);}},_0x16dc90['prototype']['setState']=function(_0x528ff2,_0x1117f8,_0x42efda,_0x4e79ae){void 0x0===_0x1117f8&&(_0x1117f8=0x0),void 0x0===_0x4e79ae&&(_0x4e79ae=!0x1),(this['_depthCullingState']['cull']!==_0x528ff2||_0x42efda)&&(this['_depthCullingState']['cull']=_0x528ff2);var _0x3c35eb=this['cullBackFaces']?this['_gl']['BACK']:this['_gl']['FRONT'];(this['_depthCullingState']['cullFace']!==_0x3c35eb||_0x42efda)&&(this['_depthCullingState']['cullFace']=_0x3c35eb),this['setZOffset'](_0x1117f8);var _0x49a5b2=_0x4e79ae?this['_gl']['CW']:this['_gl']['CCW'];(this['_depthCullingState']['frontFace']!==_0x49a5b2||_0x42efda)&&(this['_depthCullingState']['frontFace']=_0x49a5b2);},_0x16dc90['prototype']['setZOffset']=function(_0x25b1c2){this['_depthCullingState']['zOffset']=_0x25b1c2;},_0x16dc90['prototype']['getZOffset']=function(){return this['_depthCullingState']['zOffset'];},_0x16dc90['prototype']['setDepthBuffer']=function(_0x38d3fa){this['_depthCullingState']['depthTest']=_0x38d3fa;},_0x16dc90['prototype']['getDepthWrite']=function(){return this['_depthCullingState']['depthMask'];},_0x16dc90['prototype']['setDepthWrite']=function(_0x164fac){this['_depthCullingState']['depthMask']=_0x164fac;},_0x16dc90['prototype']['getStencilBuffer']=function(){return this['_stencilState']['stencilTest'];},_0x16dc90['prototype']['setStencilBuffer']=function(_0x5a1e86){this['_stencilState']['stencilTest']=_0x5a1e86;},_0x16dc90['prototype']['getStencilMask']=function(){return this['_stencilState']['stencilMask'];},_0x16dc90['prototype']['setStencilMask']=function(_0x4ae66e){this['_stencilState']['stencilMask']=_0x4ae66e;},_0x16dc90['prototype']['getStencilFunction']=function(){return this['_stencilState']['stencilFunc'];},_0x16dc90['prototype']['getStencilFunctionReference']=function(){return this['_stencilState']['stencilFuncRef'];},_0x16dc90['prototype']['getStencilFunctionMask']=function(){return this['_stencilState']['stencilFuncMask'];},_0x16dc90['prototype']['setStencilFunction']=function(_0x4c0f5d){this['_stencilState']['stencilFunc']=_0x4c0f5d;},_0x16dc90['prototype']['setStencilFunctionReference']=function(_0x152f67){this['_stencilState']['stencilFuncRef']=_0x152f67;},_0x16dc90['prototype']['setStencilFunctionMask']=function(_0x25b80e){this['_stencilState']['stencilFuncMask']=_0x25b80e;},_0x16dc90['prototype']['getStencilOperationFail']=function(){return this['_stencilState']['stencilOpStencilFail'];},_0x16dc90['prototype']['getStencilOperationDepthFail']=function(){return this['_stencilState']['stencilOpDepthFail'];},_0x16dc90['prototype']['getStencilOperationPass']=function(){return this['_stencilState']['stencilOpStencilDepthPass'];},_0x16dc90['prototype']['setStencilOperationFail']=function(_0x395a42){this['_stencilState']['stencilOpStencilFail']=_0x395a42;},_0x16dc90['prototype']['setStencilOperationDepthFail']=function(_0x8b0cc8){this['_stencilState']['stencilOpDepthFail']=_0x8b0cc8;},_0x16dc90['prototype']['setStencilOperationPass']=function(_0x5a3212){this['_stencilState']['stencilOpStencilDepthPass']=_0x5a3212;},_0x16dc90['prototype']['setDitheringState']=function(_0x5df91b){_0x5df91b?this['_gl']['enable'](this['_gl']['DITHER']):this['_gl']['disable'](this['_gl']['DITHER']);},_0x16dc90['prototype']['setRasterizerState']=function(_0x31a8d5){_0x31a8d5?this['_gl']['disable'](this['_gl']['RASTERIZER_DISCARD']):this['_gl']['enable'](this['_gl']['RASTERIZER_DISCARD']);},_0x16dc90['prototype']['getDepthFunction']=function(){return this['_depthCullingState']['depthFunc'];},_0x16dc90['prototype']['setDepthFunction']=function(_0x16344f){this['_depthCullingState']['depthFunc']=_0x16344f;},_0x16dc90['prototype']['setDepthFunctionToGreater']=function(){this['_depthCullingState']['depthFunc']=this['_gl']['GREATER'];},_0x16dc90['prototype']['setDepthFunctionToGreaterOrEqual']=function(){this['_depthCullingState']['depthFunc']=this['_gl']['GEQUAL'];},_0x16dc90['prototype']['setDepthFunctionToLess']=function(){this['_depthCullingState']['depthFunc']=this['_gl']['LESS'];},_0x16dc90['prototype']['setDepthFunctionToLessOrEqual']=function(){this['_depthCullingState']['depthFunc']=this['_gl']['LEQUAL'];},_0x16dc90['prototype']['cacheStencilState']=function(){this['_cachedStencilBuffer']=this['getStencilBuffer'](),this['_cachedStencilFunction']=this['getStencilFunction'](),this['_cachedStencilMask']=this['getStencilMask'](),this['_cachedStencilOperationPass']=this['getStencilOperationPass'](),this['_cachedStencilOperationFail']=this['getStencilOperationFail'](),this['_cachedStencilOperationDepthFail']=this['getStencilOperationDepthFail'](),this['_cachedStencilReference']=this['getStencilFunctionReference']();},_0x16dc90['prototype']['restoreStencilState']=function(){this['setStencilFunction'](this['_cachedStencilFunction']),this['setStencilMask'](this['_cachedStencilMask']),this['setStencilBuffer'](this['_cachedStencilBuffer']),this['setStencilOperationPass'](this['_cachedStencilOperationPass']),this['setStencilOperationFail'](this['_cachedStencilOperationFail']),this['setStencilOperationDepthFail'](this['_cachedStencilOperationDepthFail']),this['setStencilFunctionReference'](this['_cachedStencilReference']);},_0x16dc90['prototype']['setDirectViewport']=function(_0xa6ceff,_0xb20518,_0x50ac9d,_0x20f94a){var _0x17352e=this['_cachedViewport'];return this['_cachedViewport']=null,this['_viewport'](_0xa6ceff,_0xb20518,_0x50ac9d,_0x20f94a),_0x17352e;},_0x16dc90['prototype']['scissorClear']=function(_0x49d728,_0x354527,_0x523210,_0xb8a039,_0x4a668d){this['enableScissor'](_0x49d728,_0x354527,_0x523210,_0xb8a039),this['clear'](_0x4a668d,!0x0,!0x0,!0x0),this['disableScissor']();},_0x16dc90['prototype']['enableScissor']=function(_0x31e36a,_0x28d4bd,_0x536697,_0x545d0e){var _0x2b96d3=this['_gl'];_0x2b96d3['enable'](_0x2b96d3['SCISSOR_TEST']),_0x2b96d3['scissor'](_0x31e36a,_0x28d4bd,_0x536697,_0x545d0e);},_0x16dc90['prototype']['disableScissor']=function(){var _0x1d92ef=this['_gl'];_0x1d92ef['disable'](_0x1d92ef['SCISSOR_TEST']);},_0x16dc90['prototype']['_reportDrawCall']=function(){this['_drawCalls']['addCount'](0x1,!0x1);},_0x16dc90['prototype']['initWebVR']=function(){throw _0x54497d['a']['WarnImport']('WebVRCamera');},_0x16dc90['prototype']['_prepareVRComponent']=function(){},_0x16dc90['prototype']['_connectVREvents']=function(_0x985e34,_0x50e05e){},_0x16dc90['prototype']['_submitVRFrame']=function(){},_0x16dc90['prototype']['disableVR']=function(){},_0x16dc90['prototype']['isVRPresenting']=function(){return!0x1;},_0x16dc90['prototype']['_requestVRFrame']=function(){},_0x16dc90['prototype']['_loadFileAsync']=function(_0x5491bf,_0x3daab5,_0x365b02){var _0x4b93ee=this;return new Promise(function(_0x40729e,_0x59c410){_0x4b93ee['_loadFile'](_0x5491bf,function(_0x420fda){_0x40729e(_0x420fda);},void 0x0,_0x3daab5,_0x365b02,function(_0x4055b5,_0x48c459){_0x59c410(_0x48c459);});});},_0x16dc90['prototype']['getVertexShaderSource']=function(_0x4c2f05){var _0x1decbb=this['_gl']['getAttachedShaders'](_0x4c2f05);return _0x1decbb?this['_gl']['getShaderSource'](_0x1decbb[0x0]):null;},_0x16dc90['prototype']['getFragmentShaderSource']=function(_0xb51bf9){var _0x1416c0=this['_gl']['getAttachedShaders'](_0xb51bf9);return _0x1416c0?this['_gl']['getShaderSource'](_0x1416c0[0x1]):null;},_0x16dc90['prototype']['setDepthStencilTexture']=function(_0x533092,_0x2c7105,_0xf2ee59){void 0x0!==_0x533092&&(_0x2c7105&&(this['_boundUniforms'][_0x533092]=_0x2c7105),_0xf2ee59&&_0xf2ee59['depthStencilTexture']?this['_setTexture'](_0x533092,_0xf2ee59,!0x1,!0x0):this['_setTexture'](_0x533092,null));},_0x16dc90['prototype']['setTextureFromPostProcess']=function(_0x406d0d,_0x5693e3){this['_bindTexture'](_0x406d0d,_0x5693e3?_0x5693e3['_textures']['data'][_0x5693e3['_currentRenderTextureInd']]:null);},_0x16dc90['prototype']['setTextureFromPostProcessOutput']=function(_0xa7c0b1,_0x4f33dd){this['_bindTexture'](_0xa7c0b1,_0x4f33dd?_0x4f33dd['_outputTexture']:null);},_0x16dc90['prototype']['_rebuildBuffers']=function(){for(var _0x50b984=0x0,_0x37150c=this['scenes'];_0x50b984<_0x37150c['length'];_0x50b984++){var _0x355358=_0x37150c[_0x50b984];_0x355358['resetCachedMaterial'](),_0x355358['_rebuildGeometries'](),_0x355358['_rebuildTextures']();}_0x12ca78['prototype']['_rebuildBuffers']['call'](this);},_0x16dc90['prototype']['_renderFrame']=function(){for(var _0x499958=0x0;_0x4999580x0?this['customAnimationFrameRequester']?(this['customAnimationFrameRequester']['requestID']=this['_queueNewFrame'](this['customAnimationFrameRequester']['renderFunction']||this['_boundRenderFunction'],this['customAnimationFrameRequester']),this['_frameHandler']=this['customAnimationFrameRequester']['requestID']):this['isVRPresenting']()?this['_requestVRFrame']():this['_frameHandler']=this['_queueNewFrame'](this['_boundRenderFunction'],this['getHostWindow']()):this['_renderingQueueLaunched']=!0x1;},_0x16dc90['prototype']['_renderViews']=function(){return!0x1;},_0x16dc90['prototype']['switchFullscreen']=function(_0x4e71a3){this['isFullscreen']?this['exitFullscreen']():this['enterFullscreen'](_0x4e71a3);},_0x16dc90['prototype']['enterFullscreen']=function(_0x2292d2){this['isFullscreen']||(this['_pointerLockRequested']=_0x2292d2,this['_renderingCanvas']&&_0x16dc90['_RequestFullscreen'](this['_renderingCanvas']));},_0x16dc90['prototype']['exitFullscreen']=function(){this['isFullscreen']&&_0x16dc90['_ExitFullscreen']();},_0x16dc90['prototype']['enterPointerlock']=function(){this['_renderingCanvas']&&_0x16dc90['_RequestPointerlock'](this['_renderingCanvas']);},_0x16dc90['prototype']['exitPointerlock']=function(){_0x16dc90['_ExitPointerlock']();},_0x16dc90['prototype']['beginFrame']=function(){this['_measureFps'](),this['onBeginFrameObservable']['notifyObservers'](this),_0x12ca78['prototype']['beginFrame']['call'](this);},_0x16dc90['prototype']['endFrame']=function(){_0x12ca78['prototype']['endFrame']['call'](this),this['_submitVRFrame'](),this['onEndFrameObservable']['notifyObservers'](this);},_0x16dc90['prototype']['resize']=function(){this['isVRPresenting']()||_0x12ca78['prototype']['resize']['call'](this);},_0x16dc90['prototype']['setSize']=function(_0x26000f,_0x23550b){if(!this['_renderingCanvas'])return!0x1;if(!_0x12ca78['prototype']['setSize']['call'](this,_0x26000f,_0x23550b))return!0x1;if(this['scenes']){for(var _0x11d1b8=0x0;_0x11d1b80x1&&_0x4e6269){var _0x2c9ee7=this['createTransformFeedback']();this['bindTransformFeedback'](_0x2c9ee7),this['setTranformFeedbackVaryings'](_0x3e8ed7,_0x4e6269),_0x20908f['transformFeedback']=_0x2c9ee7;}return _0x149634['linkProgram'](_0x3e8ed7),this['webGLVersion']>0x1&&_0x4e6269&&this['bindTransformFeedback'](null),_0x20908f['context']=_0x149634,_0x20908f['vertexShader']=_0x58a8fd,_0x20908f['fragmentShader']=_0x2787b2,_0x20908f['isParallelCompiled']||this['_finalizePipelineContext'](_0x20908f),_0x3e8ed7;},_0x16dc90['prototype']['_releaseTexture']=function(_0x1de66a){_0x12ca78['prototype']['_releaseTexture']['call'](this,_0x1de66a),this['scenes']['forEach'](function(_0x57fa90){_0x57fa90['postProcesses']['forEach'](function(_0x2c4d76){_0x2c4d76['_outputTexture']==_0x1de66a&&(_0x2c4d76['_outputTexture']=null);}),_0x57fa90['cameras']['forEach'](function(_0x402e5a){_0x402e5a['_postProcesses']['forEach'](function(_0x1e9091){_0x1e9091&&_0x1e9091['_outputTexture']==_0x1de66a&&(_0x1e9091['_outputTexture']=null);});});});},_0x16dc90['prototype']['_rescaleTexture']=function(_0x4eb761,_0x23e092,_0x4d69e3,_0x572d2e,_0x983738){var _0x1eacec=this;this['_gl']['texParameteri'](this['_gl']['TEXTURE_2D'],this['_gl']['TEXTURE_MAG_FILTER'],this['_gl']['LINEAR']),this['_gl']['texParameteri'](this['_gl']['TEXTURE_2D'],this['_gl']['TEXTURE_MIN_FILTER'],this['_gl']['LINEAR']),this['_gl']['texParameteri'](this['_gl']['TEXTURE_2D'],this['_gl']['TEXTURE_WRAP_S'],this['_gl']['CLAMP_TO_EDGE']),this['_gl']['texParameteri'](this['_gl']['TEXTURE_2D'],this['_gl']['TEXTURE_WRAP_T'],this['_gl']['CLAMP_TO_EDGE']);var _0x4e4ecc=this['createRenderTargetTexture']({'width':_0x23e092['width'],'height':_0x23e092['height']},{'generateMipMaps':!0x1,'type':_0x488a1f['a']['TEXTURETYPE_UNSIGNED_INT'],'samplingMode':_0x488a1f['a']['TEXTURE_BILINEAR_SAMPLINGMODE'],'generateDepthBuffer':!0x1,'generateStencilBuffer':!0x1});!this['_rescalePostProcess']&&_0x16dc90['_RescalePostProcessFactory']&&(this['_rescalePostProcess']=_0x16dc90['_RescalePostProcessFactory'](this)),this['_rescalePostProcess']['getEffect']()['executeWhenCompiled'](function(){_0x1eacec['_rescalePostProcess']['onApply']=function(_0x2af631){_0x2af631['_bindTexture']('textureSampler',_0x4eb761);};var _0x1791ec=_0x4d69e3;_0x1791ec||(_0x1791ec=_0x1eacec['scenes'][_0x1eacec['scenes']['length']-0x1]),_0x1791ec['postProcessManager']['directRender']([_0x1eacec['_rescalePostProcess']],_0x4e4ecc,!0x0),_0x1eacec['_bindTextureDirectly'](_0x1eacec['_gl']['TEXTURE_2D'],_0x23e092,!0x0),_0x1eacec['_gl']['copyTexImage2D'](_0x1eacec['_gl']['TEXTURE_2D'],0x0,_0x572d2e,0x0,0x0,_0x23e092['width'],_0x23e092['height'],0x0),_0x1eacec['unBindFramebuffer'](_0x4e4ecc),_0x1eacec['_releaseTexture'](_0x4e4ecc),_0x983738&&_0x983738();});},_0x16dc90['prototype']['getFps']=function(){return this['_fps'];},_0x16dc90['prototype']['getDeltaTime']=function(){return this['_deltaTime'];},_0x16dc90['prototype']['_measureFps']=function(){this['_performanceMonitor']['sampleFrame'](),this['_fps']=this['_performanceMonitor']['averageFPS'],this['_deltaTime']=this['_performanceMonitor']['instantaneousFrameTime']||0x0;},_0x16dc90['prototype']['_uploadImageToTexture']=function(_0x1ac5d8,_0x125315,_0x6e8f3f,_0x3710b1){void 0x0===_0x6e8f3f&&(_0x6e8f3f=0x0),void 0x0===_0x3710b1&&(_0x3710b1=0x0);var _0x310a35=this['_gl'],_0x3e1444=this['_getWebGLTextureType'](_0x1ac5d8['type']),_0x1ce09c=this['_getInternalFormat'](_0x1ac5d8['format']),_0x7437aa=this['_getRGBABufferInternalSizedFormat'](_0x1ac5d8['type'],_0x1ce09c),_0xb7c5b4=_0x1ac5d8['isCube']?_0x310a35['TEXTURE_CUBE_MAP']:_0x310a35['TEXTURE_2D'];this['_bindTextureDirectly'](_0xb7c5b4,_0x1ac5d8,!0x0),this['_unpackFlipY'](_0x1ac5d8['invertY']);var _0x1a1d36=_0x310a35['TEXTURE_2D'];_0x1ac5d8['isCube']&&(_0x1a1d36=_0x310a35['TEXTURE_CUBE_MAP_POSITIVE_X']+_0x6e8f3f),_0x310a35['texImage2D'](_0x1a1d36,_0x3710b1,_0x7437aa,_0x1ce09c,_0x3e1444,_0x125315),this['_bindTextureDirectly'](_0xb7c5b4,null,!0x0);},_0x16dc90['prototype']['updateRenderTargetTextureSampleCount']=function(_0x190526,_0xdd677a){if(this['webGLVersion']<0x2||!_0x190526)return 0x1;if(_0x190526['samples']===_0xdd677a)return _0xdd677a;var _0x1c76ec=this['_gl'];if(_0xdd677a=Math['min'](_0xdd677a,this['getCaps']()['maxMSAASamples']),_0x190526['_depthStencilBuffer']&&(_0x1c76ec['deleteRenderbuffer'](_0x190526['_depthStencilBuffer']),_0x190526['_depthStencilBuffer']=null),_0x190526['_MSAAFramebuffer']&&(_0x1c76ec['deleteFramebuffer'](_0x190526['_MSAAFramebuffer']),_0x190526['_MSAAFramebuffer']=null),_0x190526['_MSAARenderBuffer']&&(_0x1c76ec['deleteRenderbuffer'](_0x190526['_MSAARenderBuffer']),_0x190526['_MSAARenderBuffer']=null),_0xdd677a>0x1&&_0x1c76ec['renderbufferStorageMultisample']){var _0x282e5c=_0x1c76ec['createFramebuffer']();if(!_0x282e5c)throw new Error('Unable\x20to\x20create\x20multi\x20sampled\x20framebuffer');_0x190526['_MSAAFramebuffer']=_0x282e5c,this['_bindUnboundFramebuffer'](_0x190526['_MSAAFramebuffer']);var _0x262f14=_0x1c76ec['createRenderbuffer']();if(!_0x262f14)throw new Error('Unable\x20to\x20create\x20multi\x20sampled\x20framebuffer');_0x1c76ec['bindRenderbuffer'](_0x1c76ec['RENDERBUFFER'],_0x262f14),_0x1c76ec['renderbufferStorageMultisample'](_0x1c76ec['RENDERBUFFER'],_0xdd677a,this['_getRGBAMultiSampleBufferFormat'](_0x190526['type']),_0x190526['width'],_0x190526['height']),_0x1c76ec['framebufferRenderbuffer'](_0x1c76ec['FRAMEBUFFER'],_0x1c76ec['COLOR_ATTACHMENT0'],_0x1c76ec['RENDERBUFFER'],_0x262f14),_0x190526['_MSAARenderBuffer']=_0x262f14;}else this['_bindUnboundFramebuffer'](_0x190526['_framebuffer']);return _0x190526['samples']=_0xdd677a,_0x190526['_depthStencilBuffer']=this['_setupFramebufferDepthAttachments'](_0x190526['_generateStencilBuffer'],_0x190526['_generateDepthBuffer'],_0x190526['width'],_0x190526['height'],_0xdd677a),this['_bindUnboundFramebuffer'](null),_0xdd677a;},_0x16dc90['prototype']['updateTextureComparisonFunction']=function(_0x3f798b,_0x2c8af6){if(0x1!==this['webGLVersion']){var _0x73c39=this['_gl'];_0x3f798b['isCube']?(this['_bindTextureDirectly'](this['_gl']['TEXTURE_CUBE_MAP'],_0x3f798b,!0x0),0x0===_0x2c8af6?(_0x73c39['texParameteri'](_0x73c39['TEXTURE_CUBE_MAP'],_0x73c39['TEXTURE_COMPARE_FUNC'],_0x488a1f['a']['LEQUAL']),_0x73c39['texParameteri'](_0x73c39['TEXTURE_CUBE_MAP'],_0x73c39['TEXTURE_COMPARE_MODE'],_0x73c39['NONE'])):(_0x73c39['texParameteri'](_0x73c39['TEXTURE_CUBE_MAP'],_0x73c39['TEXTURE_COMPARE_FUNC'],_0x2c8af6),_0x73c39['texParameteri'](_0x73c39['TEXTURE_CUBE_MAP'],_0x73c39['TEXTURE_COMPARE_MODE'],_0x73c39['COMPARE_REF_TO_TEXTURE'])),this['_bindTextureDirectly'](this['_gl']['TEXTURE_CUBE_MAP'],null)):(this['_bindTextureDirectly'](this['_gl']['TEXTURE_2D'],_0x3f798b,!0x0),0x0===_0x2c8af6?(_0x73c39['texParameteri'](_0x73c39['TEXTURE_2D'],_0x73c39['TEXTURE_COMPARE_FUNC'],_0x488a1f['a']['LEQUAL']),_0x73c39['texParameteri'](_0x73c39['TEXTURE_2D'],_0x73c39['TEXTURE_COMPARE_MODE'],_0x73c39['NONE'])):(_0x73c39['texParameteri'](_0x73c39['TEXTURE_2D'],_0x73c39['TEXTURE_COMPARE_FUNC'],_0x2c8af6),_0x73c39['texParameteri'](_0x73c39['TEXTURE_2D'],_0x73c39['TEXTURE_COMPARE_MODE'],_0x73c39['COMPARE_REF_TO_TEXTURE'])),this['_bindTextureDirectly'](this['_gl']['TEXTURE_2D'],null)),_0x3f798b['_comparisonFunction']=_0x2c8af6;}else _0x30866d['a']['Error']('WebGL\x201\x20does\x20not\x20support\x20texture\x20comparison.');},_0x16dc90['prototype']['createInstancesBuffer']=function(_0x11e37c){var _0x210774=this['_gl']['createBuffer']();if(!_0x210774)throw new Error('Unable\x20to\x20create\x20instance\x20buffer');var _0x1019d1=new _0x13e011['a'](_0x210774);return _0x1019d1['capacity']=_0x11e37c,this['bindArrayBuffer'](_0x1019d1),this['_gl']['bufferData'](this['_gl']['ARRAY_BUFFER'],_0x11e37c,this['_gl']['DYNAMIC_DRAW']),_0x1019d1;},_0x16dc90['prototype']['deleteInstancesBuffer']=function(_0x5d0e87){this['_gl']['deleteBuffer'](_0x5d0e87);},_0x16dc90['prototype']['_clientWaitAsync']=function(_0xbbcc66,_0x40892a,_0x258568){void 0x0===_0x40892a&&(_0x40892a=0x0),void 0x0===_0x258568&&(_0x258568=0xa);var _0x3047bb=this['_gl'];return new Promise(function(_0x209aed,_0x2fbd92){var _0x413056=function(){var _0x215851=_0x3047bb['clientWaitSync'](_0xbbcc66,_0x40892a,0x0);_0x215851!=_0x3047bb['WAIT_FAILED']?_0x215851!=_0x3047bb['TIMEOUT_EXPIRED']?_0x209aed():setTimeout(_0x413056,_0x258568):_0x2fbd92();};_0x413056();});},_0x16dc90['prototype']['_readPixelsAsync']=function(_0xbf2e65,_0x4070f4,_0x58e668,_0xd87d13,_0x2ad08e,_0x4582ca,_0x2d96b6){if(this['_webGLVersion']<0x2)throw new Error('_readPixelsAsync\x20only\x20work\x20on\x20WebGL2+');var _0x242f9d=this['_gl'],_0x3636c5=_0x242f9d['createBuffer']();_0x242f9d['bindBuffer'](_0x242f9d['PIXEL_PACK_BUFFER'],_0x3636c5),_0x242f9d['bufferData'](_0x242f9d['PIXEL_PACK_BUFFER'],_0x2d96b6['byteLength'],_0x242f9d['STREAM_READ']),_0x242f9d['readPixels'](_0xbf2e65,_0x4070f4,_0x58e668,_0xd87d13,_0x2ad08e,_0x4582ca,0x0),_0x242f9d['bindBuffer'](_0x242f9d['PIXEL_PACK_BUFFER'],null);var _0x3354e7=_0x242f9d['fenceSync'](_0x242f9d['SYNC_GPU_COMMANDS_COMPLETE'],0x0);return _0x3354e7?(_0x242f9d['flush'](),this['_clientWaitAsync'](_0x3354e7,0x0,0xa)['then'](function(){return _0x242f9d['deleteSync'](_0x3354e7),_0x242f9d['bindBuffer'](_0x242f9d['PIXEL_PACK_BUFFER'],_0x3636c5),_0x242f9d['getBufferSubData'](_0x242f9d['PIXEL_PACK_BUFFER'],0x0,_0x2d96b6),_0x242f9d['bindBuffer'](_0x242f9d['PIXEL_PACK_BUFFER'],null),_0x242f9d['deleteBuffer'](_0x3636c5),_0x2d96b6;})):null;},_0x16dc90['prototype']['dispose']=function(){for(this['hideLoadingUI'](),this['onNewSceneAddedObservable']['clear']();this['postProcesses']['length'];)this['postProcesses'][0x0]['dispose']();for(this['_rescalePostProcess']&&this['_rescalePostProcess']['dispose']();this['scenes']['length'];)this['scenes'][0x0]['dispose']();0x1===_0x16dc90['Instances']['length']&&_0x16dc90['audioEngine']&&_0x16dc90['audioEngine']['dispose'](),this['disableVR'](),_0x4deaec['a']['IsWindowObjectExist']()&&(window['removeEventListener']('blur',this['_onBlur']),window['removeEventListener']('focus',this['_onFocus']),this['_renderingCanvas']&&(this['_renderingCanvas']['removeEventListener']('focus',this['_onCanvasFocus']),this['_renderingCanvas']['removeEventListener']('blur',this['_onCanvasBlur']),this['_renderingCanvas']['removeEventListener']('pointerout',this['_onCanvasPointerOut'])),_0x4deaec['a']['IsDocumentAvailable']()&&(document['removeEventListener']('fullscreenchange',this['_onFullscreenChange']),document['removeEventListener']('mozfullscreenchange',this['_onFullscreenChange']),document['removeEventListener']('webkitfullscreenchange',this['_onFullscreenChange']),document['removeEventListener']('msfullscreenchange',this['_onFullscreenChange']),document['removeEventListener']('pointerlockchange',this['_onPointerLockChange']),document['removeEventListener']('mspointerlockchange',this['_onPointerLockChange']),document['removeEventListener']('mozpointerlockchange',this['_onPointerLockChange']),document['removeEventListener']('webkitpointerlockchange',this['_onPointerLockChange']))),_0x12ca78['prototype']['dispose']['call'](this);var _0x35b587=_0x16dc90['Instances']['indexOf'](this);_0x35b587>=0x0&&_0x16dc90['Instances']['splice'](_0x35b587,0x1),this['onResizeObservable']['clear'](),this['onCanvasBlurObservable']['clear'](),this['onCanvasFocusObservable']['clear'](),this['onCanvasPointerOutObservable']['clear'](),this['onBeginFrameObservable']['clear'](),this['onEndFrameObservable']['clear']();},_0x16dc90['prototype']['_disableTouchAction']=function(){this['_renderingCanvas']&&this['_renderingCanvas']['setAttribute']&&(this['_renderingCanvas']['setAttribute']('touch-action','none'),this['_renderingCanvas']['style']['touchAction']='none',this['_renderingCanvas']['style']['msTouchAction']='none');},_0x16dc90['prototype']['displayLoadingUI']=function(){if(_0x4deaec['a']['IsWindowObjectExist']()){var _0x1d17d3=this['loadingScreen'];_0x1d17d3&&_0x1d17d3['displayLoadingUI']();}},_0x16dc90['prototype']['hideLoadingUI']=function(){if(_0x4deaec['a']['IsWindowObjectExist']()){var _0x120ff9=this['_loadingScreen'];_0x120ff9&&_0x120ff9['hideLoadingUI']();}},Object['defineProperty'](_0x16dc90['prototype'],'loadingScreen',{'get':function(){return!this['_loadingScreen']&&this['_renderingCanvas']&&(this['_loadingScreen']=_0x16dc90['DefaultLoadingScreenFactory'](this['_renderingCanvas'])),this['_loadingScreen'];},'set':function(_0x361521){this['_loadingScreen']=_0x361521;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x16dc90['prototype'],'loadingUIText',{'set':function(_0x1bc4d6){this['loadingScreen']['loadingUIText']=_0x1bc4d6;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x16dc90['prototype'],'loadingUIBackgroundColor',{'set':function(_0x452e1c){this['loadingScreen']['loadingUIBackgroundColor']=_0x452e1c;},'enumerable':!0x1,'configurable':!0x0}),_0x16dc90['_RequestPointerlock']=function(_0x54c3b7){_0x54c3b7['requestPointerLock']=_0x54c3b7['requestPointerLock']||_0x54c3b7['msRequestPointerLock']||_0x54c3b7['mozRequestPointerLock']||_0x54c3b7['webkitRequestPointerLock'],_0x54c3b7['requestPointerLock']&&_0x54c3b7['requestPointerLock']();},_0x16dc90['_ExitPointerlock']=function(){var _0x4899cb=document;document['exitPointerLock']=document['exitPointerLock']||_0x4899cb['msExitPointerLock']||_0x4899cb['mozExitPointerLock']||_0x4899cb['webkitExitPointerLock'],document['exitPointerLock']&&document['exitPointerLock']();},_0x16dc90['_RequestFullscreen']=function(_0x5e7bde){var _0x1be75c=_0x5e7bde['requestFullscreen']||_0x5e7bde['msRequestFullscreen']||_0x5e7bde['webkitRequestFullscreen']||_0x5e7bde['mozRequestFullScreen'];_0x1be75c&&_0x1be75c['call'](_0x5e7bde);},_0x16dc90['_ExitFullscreen']=function(){var _0x137ec5=document;document['exitFullscreen']?document['exitFullscreen']():_0x137ec5['mozCancelFullScreen']?_0x137ec5['mozCancelFullScreen']():_0x137ec5['webkitCancelFullScreen']?_0x137ec5['webkitCancelFullScreen']():_0x137ec5['msCancelFullScreen']&&_0x137ec5['msCancelFullScreen']();},_0x16dc90['ALPHA_DISABLE']=_0x488a1f['a']['ALPHA_DISABLE'],_0x16dc90['ALPHA_ADD']=_0x488a1f['a']['ALPHA_ADD'],_0x16dc90['ALPHA_COMBINE']=_0x488a1f['a']['ALPHA_COMBINE'],_0x16dc90['ALPHA_SUBTRACT']=_0x488a1f['a']['ALPHA_SUBTRACT'],_0x16dc90['ALPHA_MULTIPLY']=_0x488a1f['a']['ALPHA_MULTIPLY'],_0x16dc90['ALPHA_MAXIMIZED']=_0x488a1f['a']['ALPHA_MAXIMIZED'],_0x16dc90['ALPHA_ONEONE']=_0x488a1f['a']['ALPHA_ONEONE'],_0x16dc90['ALPHA_PREMULTIPLIED']=_0x488a1f['a']['ALPHA_PREMULTIPLIED'],_0x16dc90['ALPHA_PREMULTIPLIED_PORTERDUFF']=_0x488a1f['a']['ALPHA_PREMULTIPLIED_PORTERDUFF'],_0x16dc90['ALPHA_INTERPOLATE']=_0x488a1f['a']['ALPHA_INTERPOLATE'],_0x16dc90['ALPHA_SCREENMODE']=_0x488a1f['a']['ALPHA_SCREENMODE'],_0x16dc90['DELAYLOADSTATE_NONE']=_0x488a1f['a']['DELAYLOADSTATE_NONE'],_0x16dc90['DELAYLOADSTATE_LOADED']=_0x488a1f['a']['DELAYLOADSTATE_LOADED'],_0x16dc90['DELAYLOADSTATE_LOADING']=_0x488a1f['a']['DELAYLOADSTATE_LOADING'],_0x16dc90['DELAYLOADSTATE_NOTLOADED']=_0x488a1f['a']['DELAYLOADSTATE_NOTLOADED'],_0x16dc90['NEVER']=_0x488a1f['a']['NEVER'],_0x16dc90['ALWAYS']=_0x488a1f['a']['ALWAYS'],_0x16dc90['LESS']=_0x488a1f['a']['LESS'],_0x16dc90['EQUAL']=_0x488a1f['a']['EQUAL'],_0x16dc90['LEQUAL']=_0x488a1f['a']['LEQUAL'],_0x16dc90['GREATER']=_0x488a1f['a']['GREATER'],_0x16dc90['GEQUAL']=_0x488a1f['a']['GEQUAL'],_0x16dc90['NOTEQUAL']=_0x488a1f['a']['NOTEQUAL'],_0x16dc90['KEEP']=_0x488a1f['a']['KEEP'],_0x16dc90['REPLACE']=_0x488a1f['a']['REPLACE'],_0x16dc90['INCR']=_0x488a1f['a']['INCR'],_0x16dc90['DECR']=_0x488a1f['a']['DECR'],_0x16dc90['INVERT']=_0x488a1f['a']['INVERT'],_0x16dc90['INCR_WRAP']=_0x488a1f['a']['INCR_WRAP'],_0x16dc90['DECR_WRAP']=_0x488a1f['a']['DECR_WRAP'],_0x16dc90['TEXTURE_CLAMP_ADDRESSMODE']=_0x488a1f['a']['TEXTURE_CLAMP_ADDRESSMODE'],_0x16dc90['TEXTURE_WRAP_ADDRESSMODE']=_0x488a1f['a']['TEXTURE_WRAP_ADDRESSMODE'],_0x16dc90['TEXTURE_MIRROR_ADDRESSMODE']=_0x488a1f['a']['TEXTURE_MIRROR_ADDRESSMODE'],_0x16dc90['TEXTUREFORMAT_ALPHA']=_0x488a1f['a']['TEXTUREFORMAT_ALPHA'],_0x16dc90['TEXTUREFORMAT_LUMINANCE']=_0x488a1f['a']['TEXTUREFORMAT_LUMINANCE'],_0x16dc90['TEXTUREFORMAT_LUMINANCE_ALPHA']=_0x488a1f['a']['TEXTUREFORMAT_LUMINANCE_ALPHA'],_0x16dc90['TEXTUREFORMAT_RGB']=_0x488a1f['a']['TEXTUREFORMAT_RGB'],_0x16dc90['TEXTUREFORMAT_RGBA']=_0x488a1f['a']['TEXTUREFORMAT_RGBA'],_0x16dc90['TEXTUREFORMAT_RED']=_0x488a1f['a']['TEXTUREFORMAT_RED'],_0x16dc90['TEXTUREFORMAT_R']=_0x488a1f['a']['TEXTUREFORMAT_R'],_0x16dc90['TEXTUREFORMAT_RG']=_0x488a1f['a']['TEXTUREFORMAT_RG'],_0x16dc90['TEXTUREFORMAT_RED_INTEGER']=_0x488a1f['a']['TEXTUREFORMAT_RED_INTEGER'],_0x16dc90['TEXTUREFORMAT_R_INTEGER']=_0x488a1f['a']['TEXTUREFORMAT_R_INTEGER'],_0x16dc90['TEXTUREFORMAT_RG_INTEGER']=_0x488a1f['a']['TEXTUREFORMAT_RG_INTEGER'],_0x16dc90['TEXTUREFORMAT_RGB_INTEGER']=_0x488a1f['a']['TEXTUREFORMAT_RGB_INTEGER'],_0x16dc90['TEXTUREFORMAT_RGBA_INTEGER']=_0x488a1f['a']['TEXTUREFORMAT_RGBA_INTEGER'],_0x16dc90['TEXTURETYPE_UNSIGNED_BYTE']=_0x488a1f['a']['TEXTURETYPE_UNSIGNED_BYTE'],_0x16dc90['TEXTURETYPE_UNSIGNED_INT']=_0x488a1f['a']['TEXTURETYPE_UNSIGNED_INT'],_0x16dc90['TEXTURETYPE_FLOAT']=_0x488a1f['a']['TEXTURETYPE_FLOAT'],_0x16dc90['TEXTURETYPE_HALF_FLOAT']=_0x488a1f['a']['TEXTURETYPE_HALF_FLOAT'],_0x16dc90['TEXTURETYPE_BYTE']=_0x488a1f['a']['TEXTURETYPE_BYTE'],_0x16dc90['TEXTURETYPE_SHORT']=_0x488a1f['a']['TEXTURETYPE_SHORT'],_0x16dc90['TEXTURETYPE_UNSIGNED_SHORT']=_0x488a1f['a']['TEXTURETYPE_UNSIGNED_SHORT'],_0x16dc90['TEXTURETYPE_INT']=_0x488a1f['a']['TEXTURETYPE_INT'],_0x16dc90['TEXTURETYPE_UNSIGNED_INTEGER']=_0x488a1f['a']['TEXTURETYPE_UNSIGNED_INTEGER'],_0x16dc90['TEXTURETYPE_UNSIGNED_SHORT_4_4_4_4']=_0x488a1f['a']['TEXTURETYPE_UNSIGNED_SHORT_4_4_4_4'],_0x16dc90['TEXTURETYPE_UNSIGNED_SHORT_5_5_5_1']=_0x488a1f['a']['TEXTURETYPE_UNSIGNED_SHORT_5_5_5_1'],_0x16dc90['TEXTURETYPE_UNSIGNED_SHORT_5_6_5']=_0x488a1f['a']['TEXTURETYPE_UNSIGNED_SHORT_5_6_5'],_0x16dc90['TEXTURETYPE_UNSIGNED_INT_2_10_10_10_REV']=_0x488a1f['a']['TEXTURETYPE_UNSIGNED_INT_2_10_10_10_REV'],_0x16dc90['TEXTURETYPE_UNSIGNED_INT_24_8']=_0x488a1f['a']['TEXTURETYPE_UNSIGNED_INT_24_8'],_0x16dc90['TEXTURETYPE_UNSIGNED_INT_10F_11F_11F_REV']=_0x488a1f['a']['TEXTURETYPE_UNSIGNED_INT_10F_11F_11F_REV'],_0x16dc90['TEXTURETYPE_UNSIGNED_INT_5_9_9_9_REV']=_0x488a1f['a']['TEXTURETYPE_UNSIGNED_INT_5_9_9_9_REV'],_0x16dc90['TEXTURETYPE_FLOAT_32_UNSIGNED_INT_24_8_REV']=_0x488a1f['a']['TEXTURETYPE_FLOAT_32_UNSIGNED_INT_24_8_REV'],_0x16dc90['TEXTURE_NEAREST_SAMPLINGMODE']=_0x488a1f['a']['TEXTURE_NEAREST_SAMPLINGMODE'],_0x16dc90['TEXTURE_BILINEAR_SAMPLINGMODE']=_0x488a1f['a']['TEXTURE_BILINEAR_SAMPLINGMODE'],_0x16dc90['TEXTURE_TRILINEAR_SAMPLINGMODE']=_0x488a1f['a']['TEXTURE_TRILINEAR_SAMPLINGMODE'],_0x16dc90['TEXTURE_NEAREST_NEAREST_MIPLINEAR']=_0x488a1f['a']['TEXTURE_NEAREST_NEAREST_MIPLINEAR'],_0x16dc90['TEXTURE_LINEAR_LINEAR_MIPNEAREST']=_0x488a1f['a']['TEXTURE_LINEAR_LINEAR_MIPNEAREST'],_0x16dc90['TEXTURE_LINEAR_LINEAR_MIPLINEAR']=_0x488a1f['a']['TEXTURE_LINEAR_LINEAR_MIPLINEAR'],_0x16dc90['TEXTURE_NEAREST_NEAREST_MIPNEAREST']=_0x488a1f['a']['TEXTURE_NEAREST_NEAREST_MIPNEAREST'],_0x16dc90['TEXTURE_NEAREST_LINEAR_MIPNEAREST']=_0x488a1f['a']['TEXTURE_NEAREST_LINEAR_MIPNEAREST'],_0x16dc90['TEXTURE_NEAREST_LINEAR_MIPLINEAR']=_0x488a1f['a']['TEXTURE_NEAREST_LINEAR_MIPLINEAR'],_0x16dc90['TEXTURE_NEAREST_LINEAR']=_0x488a1f['a']['TEXTURE_NEAREST_LINEAR'],_0x16dc90['TEXTURE_NEAREST_NEAREST']=_0x488a1f['a']['TEXTURE_NEAREST_NEAREST'],_0x16dc90['TEXTURE_LINEAR_NEAREST_MIPNEAREST']=_0x488a1f['a']['TEXTURE_LINEAR_NEAREST_MIPNEAREST'],_0x16dc90['TEXTURE_LINEAR_NEAREST_MIPLINEAR']=_0x488a1f['a']['TEXTURE_LINEAR_NEAREST_MIPLINEAR'],_0x16dc90['TEXTURE_LINEAR_LINEAR']=_0x488a1f['a']['TEXTURE_LINEAR_LINEAR'],_0x16dc90['TEXTURE_LINEAR_NEAREST']=_0x488a1f['a']['TEXTURE_LINEAR_NEAREST'],_0x16dc90['TEXTURE_EXPLICIT_MODE']=_0x488a1f['a']['TEXTURE_EXPLICIT_MODE'],_0x16dc90['TEXTURE_SPHERICAL_MODE']=_0x488a1f['a']['TEXTURE_SPHERICAL_MODE'],_0x16dc90['TEXTURE_PLANAR_MODE']=_0x488a1f['a']['TEXTURE_PLANAR_MODE'],_0x16dc90['TEXTURE_CUBIC_MODE']=_0x488a1f['a']['TEXTURE_CUBIC_MODE'],_0x16dc90['TEXTURE_PROJECTION_MODE']=_0x488a1f['a']['TEXTURE_PROJECTION_MODE'],_0x16dc90['TEXTURE_SKYBOX_MODE']=_0x488a1f['a']['TEXTURE_SKYBOX_MODE'],_0x16dc90['TEXTURE_INVCUBIC_MODE']=_0x488a1f['a']['TEXTURE_INVCUBIC_MODE'],_0x16dc90['TEXTURE_EQUIRECTANGULAR_MODE']=_0x488a1f['a']['TEXTURE_EQUIRECTANGULAR_MODE'],_0x16dc90['TEXTURE_FIXED_EQUIRECTANGULAR_MODE']=_0x488a1f['a']['TEXTURE_FIXED_EQUIRECTANGULAR_MODE'],_0x16dc90['TEXTURE_FIXED_EQUIRECTANGULAR_MIRRORED_MODE']=_0x488a1f['a']['TEXTURE_FIXED_EQUIRECTANGULAR_MIRRORED_MODE'],_0x16dc90['SCALEMODE_FLOOR']=_0x488a1f['a']['SCALEMODE_FLOOR'],_0x16dc90['SCALEMODE_NEAREST']=_0x488a1f['a']['SCALEMODE_NEAREST'],_0x16dc90['SCALEMODE_CEILING']=_0x488a1f['a']['SCALEMODE_CEILING'],_0x16dc90['_RescalePostProcessFactory']=null,_0x16dc90;}(_0x100c28['a']));},function(_0x24aacb,_0x54e3bf,_0x259475){'use strict';_0x259475['d'](_0x54e3bf,'a',function(){return _0x50f57e;});var _0x50f57e=(function(){function _0x228fb6(){}return _0x228fb6['WithinEpsilon']=function(_0x6fd2a5,_0x2a3b17,_0x7c3f27){void 0x0===_0x7c3f27&&(_0x7c3f27=1.401298e-45);var _0x939ef5=_0x6fd2a5-_0x2a3b17;return-_0x7c3f27<=_0x939ef5&&_0x939ef5<=_0x7c3f27;},_0x228fb6['ToHex']=function(_0x13a331){var _0x137c16=_0x13a331['toString'](0x10);return _0x13a331<=0xf?('0'+_0x137c16)['toUpperCase']():_0x137c16['toUpperCase']();},_0x228fb6['Sign']=function(_0x44caff){return 0x0===(_0x44caff=+_0x44caff)||isNaN(_0x44caff)?_0x44caff:_0x44caff>0x0?0x1:-0x1;},_0x228fb6['Clamp']=function(_0x4513b4,_0x20b6c4,_0x3d0ce3){return void 0x0===_0x20b6c4&&(_0x20b6c4=0x0),void 0x0===_0x3d0ce3&&(_0x3d0ce3=0x1),Math['min'](_0x3d0ce3,Math['max'](_0x20b6c4,_0x4513b4));},_0x228fb6['Log2']=function(_0x17f1bd){return Math['log'](_0x17f1bd)*Math['LOG2E'];},_0x228fb6['Repeat']=function(_0x4f1742,_0x5513bc){return _0x4f1742-Math['floor'](_0x4f1742/_0x5513bc)*_0x5513bc;},_0x228fb6['Normalize']=function(_0x4477b3,_0x4c96ce,_0x34fc88){return(_0x4477b3-_0x4c96ce)/(_0x34fc88-_0x4c96ce);},_0x228fb6['Denormalize']=function(_0x422b4a,_0x3f9fc3,_0xe9facc){return _0x422b4a*(_0xe9facc-_0x3f9fc3)+_0x3f9fc3;},_0x228fb6['DeltaAngle']=function(_0x2cb77b,_0x123597){var _0x14bc2f=_0x228fb6['Repeat'](_0x123597-_0x2cb77b,0x168);return _0x14bc2f>0xb4&&(_0x14bc2f-=0x168),_0x14bc2f;},_0x228fb6['PingPong']=function(_0xefb719,_0x4fe4fd){var _0x9023a9=_0x228fb6['Repeat'](_0xefb719,0x2*_0x4fe4fd);return _0x4fe4fd-Math['abs'](_0x9023a9-_0x4fe4fd);},_0x228fb6['SmoothStep']=function(_0x4ae52a,_0x378f8a,_0x3591d8){var _0x1c9755=_0x228fb6['Clamp'](_0x3591d8);return _0x378f8a*(_0x1c9755=-0x2*_0x1c9755*_0x1c9755*_0x1c9755+0x3*_0x1c9755*_0x1c9755)+_0x4ae52a*(0x1-_0x1c9755);},_0x228fb6['MoveTowards']=function(_0x476443,_0x140670,_0x49b0e0){return Math['abs'](_0x140670-_0x476443)<=_0x49b0e0?_0x140670:_0x476443+_0x228fb6['Sign'](_0x140670-_0x476443)*_0x49b0e0;},_0x228fb6['MoveTowardsAngle']=function(_0x5dfa4a,_0x20ce8f,_0x540719){var _0x529fa4=_0x228fb6['DeltaAngle'](_0x5dfa4a,_0x20ce8f),_0x5bd032=0x0;return-_0x540719<_0x529fa4&&_0x529fa4<_0x540719?_0x5bd032=_0x20ce8f:(_0x20ce8f=_0x5dfa4a+_0x529fa4,_0x5bd032=_0x228fb6['MoveTowards'](_0x5dfa4a,_0x20ce8f,_0x540719)),_0x5bd032;},_0x228fb6['Lerp']=function(_0x3c0730,_0x4dfdaf,_0x3c83e7){return _0x3c0730+(_0x4dfdaf-_0x3c0730)*_0x3c83e7;},_0x228fb6['LerpAngle']=function(_0x4f36d1,_0x2e6d06,_0x16f79e){var _0x483f2d=_0x228fb6['Repeat'](_0x2e6d06-_0x4f36d1,0x168);return _0x483f2d>0xb4&&(_0x483f2d-=0x168),_0x4f36d1+_0x483f2d*_0x228fb6['Clamp'](_0x16f79e);},_0x228fb6['InverseLerp']=function(_0x484d15,_0x547b8e,_0x3e84a6){return _0x484d15!=_0x547b8e?_0x228fb6['Clamp']((_0x3e84a6-_0x484d15)/(_0x547b8e-_0x484d15)):0x0;},_0x228fb6['Hermite']=function(_0x30bc46,_0x5e1d8e,_0x528582,_0x34a792,_0x444ba4){var _0x3f3af5=_0x444ba4*_0x444ba4,_0x1439c2=_0x444ba4*_0x3f3af5;return _0x30bc46*(0x2*_0x1439c2-0x3*_0x3f3af5+0x1)+_0x528582*(-0x2*_0x1439c2+0x3*_0x3f3af5)+_0x5e1d8e*(_0x1439c2-0x2*_0x3f3af5+_0x444ba4)+_0x34a792*(_0x1439c2-_0x3f3af5);},_0x228fb6['RandomRange']=function(_0x38b595,_0x4364ce){return _0x38b595===_0x4364ce?_0x38b595:Math['random']()*(_0x4364ce-_0x38b595)+_0x38b595;},_0x228fb6['RangeToPercent']=function(_0x25a566,_0x159f46,_0x3f6e80){return(_0x25a566-_0x159f46)/(_0x3f6e80-_0x159f46);},_0x228fb6['PercentToRange']=function(_0x345354,_0x5950cd,_0x276ee6){return(_0x276ee6-_0x5950cd)*_0x345354+_0x5950cd;},_0x228fb6['NormalizeRadians']=function(_0x4c6e96){return _0x4c6e96-=_0x228fb6['TwoPi']*Math['floor']((_0x4c6e96+Math['PI'])/_0x228fb6['TwoPi']);},_0x228fb6['TwoPi']=0x2*Math['PI'],_0x228fb6;}());},function(_0xa3df46,_0x353c72,_0x5d5d20){'use strict';_0x5d5d20['d'](_0x353c72,'a',function(){return _0x17c3bb;});var _0x23b912=_0x5d5d20(0x8),_0x570a0b=_0x5d5d20(0x14),_0x45aa07=_0x5d5d20(0x16),_0x422b24=_0x5d5d20(0x4),_0x4cafa5=_0x5d5d20(0x30),_0x5b750f=_0x5d5d20(0x2),_0x551e3e=_0x5d5d20(0x9),_0x4c3334=_0x5d5d20(0x77),_0x17c3bb=(function(){function _0x3ab94b(){}return _0x3ab94b['BindEyePosition']=function(_0x812ca4,_0x52ebd1,_0x5d8620){if(void 0x0===_0x5d8620&&(_0x5d8620='vEyePosition'),_0x52ebd1['_forcedViewPosition'])_0x812ca4['setVector3'](_0x5d8620,_0x52ebd1['_forcedViewPosition']);else{var _0x10a998=_0x52ebd1['activeCamera']['globalPosition'];_0x10a998||(_0x10a998=_0x52ebd1['activeCamera']['devicePosition']),_0x812ca4['setVector3'](_0x5d8620,_0x52ebd1['_mirroredCameraPosition']?_0x52ebd1['_mirroredCameraPosition']:_0x10a998);}},_0x3ab94b['PrepareDefinesForMergedUV']=function(_0x3910de,_0x3346dd,_0x41f027){_0x3346dd['_needUVs']=!0x0,_0x3346dd[_0x41f027]=!0x0,_0x3910de['getTextureMatrix']()['isIdentityAs3x2']()?(_0x3346dd[_0x41f027+'DIRECTUV']=_0x3910de['coordinatesIndex']+0x1,0x0===_0x3910de['coordinatesIndex']?_0x3346dd['MAINUV1']=!0x0:_0x3346dd['MAINUV2']=!0x0):_0x3346dd[_0x41f027+'DIRECTUV']=0x0;},_0x3ab94b['BindTextureMatrix']=function(_0x4fe18f,_0x34b5c5,_0x5a049a){var _0x2be77d=_0x4fe18f['getTextureMatrix']();_0x34b5c5['updateMatrix'](_0x5a049a+'Matrix',_0x2be77d);},_0x3ab94b['GetFogState']=function(_0x4c67f0,_0x7bf37){return _0x7bf37['fogEnabled']&&_0x4c67f0['applyFog']&&_0x7bf37['fogMode']!==_0x570a0b['a']['FOGMODE_NONE'];},_0x3ab94b['PrepareDefinesForMisc']=function(_0x3babed,_0x32c6e1,_0x3aeabb,_0x1991bd,_0x22e7e2,_0xf5603f,_0x37d897){_0x37d897['_areMiscDirty']&&(_0x37d897['LOGARITHMICDEPTH']=_0x3aeabb,_0x37d897['POINTSIZE']=_0x1991bd,_0x37d897['FOG']=_0x22e7e2&&this['GetFogState'](_0x3babed,_0x32c6e1),_0x37d897['NONUNIFORMSCALING']=_0x3babed['nonUniformScaling'],_0x37d897['ALPHATEST']=_0xf5603f);},_0x3ab94b['PrepareDefinesForFrameBoundValues']=function(_0x469b3f,_0xddd03c,_0x598cdb,_0x352b34,_0x20ced4,_0x2afb9f){void 0x0===_0x20ced4&&(_0x20ced4=null),void 0x0===_0x2afb9f&&(_0x2afb9f=!0x1);var _0x147718,_0x31ac07,_0x19e964,_0x494fa0,_0x3a420c,_0x534286,_0x41cf5b=!0x1;_0x147718=null==_0x20ced4?void 0x0!==_0x469b3f['clipPlane']&&null!==_0x469b3f['clipPlane']:_0x20ced4,_0x31ac07=null==_0x20ced4?void 0x0!==_0x469b3f['clipPlane2']&&null!==_0x469b3f['clipPlane2']:_0x20ced4,_0x19e964=null==_0x20ced4?void 0x0!==_0x469b3f['clipPlane3']&&null!==_0x469b3f['clipPlane3']:_0x20ced4,_0x494fa0=null==_0x20ced4?void 0x0!==_0x469b3f['clipPlane4']&&null!==_0x469b3f['clipPlane4']:_0x20ced4,_0x3a420c=null==_0x20ced4?void 0x0!==_0x469b3f['clipPlane5']&&null!==_0x469b3f['clipPlane5']:_0x20ced4,_0x534286=null==_0x20ced4?void 0x0!==_0x469b3f['clipPlane6']&&null!==_0x469b3f['clipPlane6']:_0x20ced4,_0x598cdb['CLIPPLANE']!==_0x147718&&(_0x598cdb['CLIPPLANE']=_0x147718,_0x41cf5b=!0x0),_0x598cdb['CLIPPLANE2']!==_0x31ac07&&(_0x598cdb['CLIPPLANE2']=_0x31ac07,_0x41cf5b=!0x0),_0x598cdb['CLIPPLANE3']!==_0x19e964&&(_0x598cdb['CLIPPLANE3']=_0x19e964,_0x41cf5b=!0x0),_0x598cdb['CLIPPLANE4']!==_0x494fa0&&(_0x598cdb['CLIPPLANE4']=_0x494fa0,_0x41cf5b=!0x0),_0x598cdb['CLIPPLANE5']!==_0x3a420c&&(_0x598cdb['CLIPPLANE5']=_0x3a420c,_0x41cf5b=!0x0),_0x598cdb['CLIPPLANE6']!==_0x534286&&(_0x598cdb['CLIPPLANE6']=_0x534286,_0x41cf5b=!0x0),_0x598cdb['DEPTHPREPASS']!==!_0xddd03c['getColorWrite']()&&(_0x598cdb['DEPTHPREPASS']=!_0x598cdb['DEPTHPREPASS'],_0x41cf5b=!0x0),_0x598cdb['INSTANCES']!==_0x352b34&&(_0x598cdb['INSTANCES']=_0x352b34,_0x41cf5b=!0x0),_0x598cdb['THIN_INSTANCES']!==_0x2afb9f&&(_0x598cdb['THIN_INSTANCES']=_0x2afb9f,_0x41cf5b=!0x0),_0x41cf5b&&_0x598cdb['markAsUnprocessed']();},_0x3ab94b['PrepareDefinesForBones']=function(_0x382e84,_0x5253cf){if(_0x382e84['useBones']&&_0x382e84['computeBonesUsingShaders']&&_0x382e84['skeleton']){_0x5253cf['NUM_BONE_INFLUENCERS']=_0x382e84['numBoneInfluencers'];var _0x3f2ed0=void 0x0!==_0x5253cf['BONETEXTURE'];if(_0x382e84['skeleton']['isUsingTextureForMatrices']&&_0x3f2ed0)_0x5253cf['BONETEXTURE']=!0x0;else{_0x5253cf['BonesPerMesh']=_0x382e84['skeleton']['bones']['length']+0x1,_0x5253cf['BONETEXTURE']=!_0x3f2ed0&&void 0x0;var _0x45b67f=_0x382e84['getScene']()['prePassRenderer'];if(_0x45b67f&&_0x45b67f['enabled']){var _0x501590=-0x1===_0x45b67f['excludedSkinnedMesh']['indexOf'](_0x382e84);_0x5253cf['BONES_VELOCITY_ENABLED']=_0x501590;}}}else _0x5253cf['NUM_BONE_INFLUENCERS']=0x0,_0x5253cf['BonesPerMesh']=0x0;},_0x3ab94b['PrepareDefinesForMorphTargets']=function(_0x5dc5d1,_0x181b4a){var _0x485fda=_0x5dc5d1['morphTargetManager'];_0x485fda?(_0x181b4a['MORPHTARGETS_UV']=_0x485fda['supportsUVs']&&_0x181b4a['UV1'],_0x181b4a['MORPHTARGETS_TANGENT']=_0x485fda['supportsTangents']&&_0x181b4a['TANGENT'],_0x181b4a['MORPHTARGETS_NORMAL']=_0x485fda['supportsNormals']&&_0x181b4a['NORMAL'],_0x181b4a['MORPHTARGETS']=_0x485fda['numInfluencers']>0x0,_0x181b4a['NUM_MORPH_INFLUENCERS']=_0x485fda['numInfluencers']):(_0x181b4a['MORPHTARGETS_UV']=!0x1,_0x181b4a['MORPHTARGETS_TANGENT']=!0x1,_0x181b4a['MORPHTARGETS_NORMAL']=!0x1,_0x181b4a['MORPHTARGETS']=!0x1,_0x181b4a['NUM_MORPH_INFLUENCERS']=0x0);},_0x3ab94b['PrepareDefinesForAttributes']=function(_0x1a98cc,_0x2c0875,_0x57a695,_0x342a8c,_0xb9148b,_0x4a6a8c){if(void 0x0===_0xb9148b&&(_0xb9148b=!0x1),void 0x0===_0x4a6a8c&&(_0x4a6a8c=!0x0),!_0x2c0875['_areAttributesDirty']&&_0x2c0875['_needNormals']===_0x2c0875['_normals']&&_0x2c0875['_needUVs']===_0x2c0875['_uvs'])return!0x1;if(_0x2c0875['_normals']=_0x2c0875['_needNormals'],_0x2c0875['_uvs']=_0x2c0875['_needUVs'],_0x2c0875['NORMAL']=_0x2c0875['_needNormals']&&_0x1a98cc['isVerticesDataPresent'](_0x422b24['b']['NormalKind']),_0x2c0875['_needNormals']&&_0x1a98cc['isVerticesDataPresent'](_0x422b24['b']['TangentKind'])&&(_0x2c0875['TANGENT']=!0x0),_0x2c0875['_needUVs']?(_0x2c0875['UV1']=_0x1a98cc['isVerticesDataPresent'](_0x422b24['b']['UVKind']),_0x2c0875['UV2']=_0x1a98cc['isVerticesDataPresent'](_0x422b24['b']['UV2Kind'])):(_0x2c0875['UV1']=!0x1,_0x2c0875['UV2']=!0x1),_0x57a695){var _0x286d5f=_0x1a98cc['useVertexColors']&&_0x1a98cc['isVerticesDataPresent'](_0x422b24['b']['ColorKind']);_0x2c0875['VERTEXCOLOR']=_0x286d5f,_0x2c0875['VERTEXALPHA']=_0x1a98cc['hasVertexAlpha']&&_0x286d5f&&_0x4a6a8c;}return _0x342a8c&&this['PrepareDefinesForBones'](_0x1a98cc,_0x2c0875),_0xb9148b&&this['PrepareDefinesForMorphTargets'](_0x1a98cc,_0x2c0875),!0x0;},_0x3ab94b['PrepareDefinesForMultiview']=function(_0x2800cf,_0x5d0ec5){if(_0x2800cf['activeCamera']){var _0x4d3e0f=_0x5d0ec5['MULTIVIEW'];_0x5d0ec5['MULTIVIEW']=null!==_0x2800cf['activeCamera']['outputRenderTarget']&&_0x2800cf['activeCamera']['outputRenderTarget']['getViewCount']()>0x1,_0x5d0ec5['MULTIVIEW']!=_0x4d3e0f&&_0x5d0ec5['markAsUnprocessed']();}},_0x3ab94b['PrepareDefinesForPrePass']=function(_0x2651cb,_0x35fcd8,_0x1fe325){var _0x3b8f90=_0x35fcd8['PREPASS'];if(_0x35fcd8['_arePrePassDirty']){var _0x24fa25=[{'type':_0x5b750f['a']['PREPASS_POSITION_TEXTURE_TYPE'],'define':'PREPASS_POSITION','index':'PREPASS_POSITION_INDEX'},{'type':_0x5b750f['a']['PREPASS_VELOCITY_TEXTURE_TYPE'],'define':'PREPASS_VELOCITY','index':'PREPASS_VELOCITY_INDEX'},{'type':_0x5b750f['a']['PREPASS_REFLECTIVITY_TEXTURE_TYPE'],'define':'PREPASS_REFLECTIVITY','index':'PREPASS_REFLECTIVITY_INDEX'},{'type':_0x5b750f['a']['PREPASS_IRRADIANCE_TEXTURE_TYPE'],'define':'PREPASS_IRRADIANCE','index':'PREPASS_IRRADIANCE_INDEX'},{'type':_0x5b750f['a']['PREPASS_ALBEDO_TEXTURE_TYPE'],'define':'PREPASS_ALBEDO','index':'PREPASS_ALBEDO_INDEX'},{'type':_0x5b750f['a']['PREPASS_DEPTHNORMAL_TEXTURE_TYPE'],'define':'PREPASS_DEPTHNORMAL','index':'PREPASS_DEPTHNORMAL_INDEX'}];if(_0x2651cb['prePassRenderer']&&_0x2651cb['prePassRenderer']['enabled']&&_0x1fe325){_0x35fcd8['PREPASS']=!0x0,_0x35fcd8['SCENE_MRT_COUNT']=_0x2651cb['prePassRenderer']['mrtCount'];for(var _0x1621f4=0x0;_0x1621f4<_0x24fa25['length'];_0x1621f4++){var _0x3ab1bf=_0x2651cb['prePassRenderer']['getIndex'](_0x24fa25[_0x1621f4]['type']);-0x1!==_0x3ab1bf?(_0x35fcd8[_0x24fa25[_0x1621f4]['define']]=!0x0,_0x35fcd8[_0x24fa25[_0x1621f4]['index']]=_0x3ab1bf):_0x35fcd8[_0x24fa25[_0x1621f4]['define']]=!0x1;}}else{_0x35fcd8['PREPASS']=!0x1;for(_0x1621f4=0x0;_0x1621f4<_0x24fa25['length'];_0x1621f4++)_0x35fcd8[_0x24fa25[_0x1621f4]['define']]=!0x1;}_0x35fcd8['PREPASS']!=_0x3b8f90&&(_0x35fcd8['markAsUnprocessed'](),_0x35fcd8['markAsImageProcessingDirty']());}},_0x3ab94b['PrepareDefinesForLight']=function(_0x5436f5,_0x2d296e,_0x47dddd,_0x29b0b2,_0x376d2b,_0xb0542a,_0x23b17c){switch(_0x23b17c['needNormals']=!0x0,void 0x0===_0x376d2b['LIGHT'+_0x29b0b2]&&(_0x23b17c['needRebuild']=!0x0),_0x376d2b['LIGHT'+_0x29b0b2]=!0x0,_0x376d2b['SPOTLIGHT'+_0x29b0b2]=!0x1,_0x376d2b['HEMILIGHT'+_0x29b0b2]=!0x1,_0x376d2b['POINTLIGHT'+_0x29b0b2]=!0x1,_0x376d2b['DIRLIGHT'+_0x29b0b2]=!0x1,_0x47dddd['prepareLightSpecificDefines'](_0x376d2b,_0x29b0b2),_0x376d2b['LIGHT_FALLOFF_PHYSICAL'+_0x29b0b2]=!0x1,_0x376d2b['LIGHT_FALLOFF_GLTF'+_0x29b0b2]=!0x1,_0x376d2b['LIGHT_FALLOFF_STANDARD'+_0x29b0b2]=!0x1,_0x47dddd['falloffType']){case _0x4cafa5['a']['FALLOFF_GLTF']:_0x376d2b['LIGHT_FALLOFF_GLTF'+_0x29b0b2]=!0x0;break;case _0x4cafa5['a']['FALLOFF_PHYSICAL']:_0x376d2b['LIGHT_FALLOFF_PHYSICAL'+_0x29b0b2]=!0x0;break;case _0x4cafa5['a']['FALLOFF_STANDARD']:_0x376d2b['LIGHT_FALLOFF_STANDARD'+_0x29b0b2]=!0x0;}if(_0xb0542a&&!_0x47dddd['specular']['equalsFloats'](0x0,0x0,0x0)&&(_0x23b17c['specularEnabled']=!0x0),_0x376d2b['SHADOW'+_0x29b0b2]=!0x1,_0x376d2b['SHADOWCSM'+_0x29b0b2]=!0x1,_0x376d2b['SHADOWCSMDEBUG'+_0x29b0b2]=!0x1,_0x376d2b['SHADOWCSMNUM_CASCADES'+_0x29b0b2]=!0x1,_0x376d2b['SHADOWCSMUSESHADOWMAXZ'+_0x29b0b2]=!0x1,_0x376d2b['SHADOWCSMNOBLEND'+_0x29b0b2]=!0x1,_0x376d2b['SHADOWCSM_RIGHTHANDED'+_0x29b0b2]=!0x1,_0x376d2b['SHADOWPCF'+_0x29b0b2]=!0x1,_0x376d2b['SHADOWPCSS'+_0x29b0b2]=!0x1,_0x376d2b['SHADOWPOISSON'+_0x29b0b2]=!0x1,_0x376d2b['SHADOWESM'+_0x29b0b2]=!0x1,_0x376d2b['SHADOWCLOSEESM'+_0x29b0b2]=!0x1,_0x376d2b['SHADOWCUBE'+_0x29b0b2]=!0x1,_0x376d2b['SHADOWLOWQUALITY'+_0x29b0b2]=!0x1,_0x376d2b['SHADOWMEDIUMQUALITY'+_0x29b0b2]=!0x1,_0x2d296e&&_0x2d296e['receiveShadows']&&_0x5436f5['shadowsEnabled']&&_0x47dddd['shadowEnabled']){var _0x27dc1e=_0x47dddd['getShadowGenerator']();if(_0x27dc1e){var _0x5f7dbd=_0x27dc1e['getShadowMap']();_0x5f7dbd&&_0x5f7dbd['renderList']&&_0x5f7dbd['renderList']['length']>0x0&&(_0x23b17c['shadowEnabled']=!0x0,_0x27dc1e['prepareDefines'](_0x376d2b,_0x29b0b2));}}_0x47dddd['lightmapMode']!=_0x4cafa5['a']['LIGHTMAP_DEFAULT']?(_0x23b17c['lightmapMode']=!0x0,_0x376d2b['LIGHTMAPEXCLUDED'+_0x29b0b2]=!0x0,_0x376d2b['LIGHTMAPNOSPECULAR'+_0x29b0b2]=_0x47dddd['lightmapMode']==_0x4cafa5['a']['LIGHTMAP_SHADOWSONLY']):(_0x376d2b['LIGHTMAPEXCLUDED'+_0x29b0b2]=!0x1,_0x376d2b['LIGHTMAPNOSPECULAR'+_0x29b0b2]=!0x1);},_0x3ab94b['PrepareDefinesForLights']=function(_0x3925a7,_0x1cfed7,_0x4a4e21,_0x5f5e0c,_0x48c0db,_0x338c9d){if(void 0x0===_0x48c0db&&(_0x48c0db=0x4),void 0x0===_0x338c9d&&(_0x338c9d=!0x1),!_0x4a4e21['_areLightsDirty'])return _0x4a4e21['_needNormals'];var _0x33507a=0x0,_0x3d74f1={'needNormals':!0x1,'needRebuild':!0x1,'lightmapMode':!0x1,'shadowEnabled':!0x1,'specularEnabled':!0x1};if(_0x3925a7['lightsEnabled']&&!_0x338c9d)for(var _0x2031ab=0x0,_0xff79b2=_0x1cfed7['lightSources'];_0x2031ab<_0xff79b2['length'];_0x2031ab++){var _0xfe19d3=_0xff79b2[_0x2031ab];if(this['PrepareDefinesForLight'](_0x3925a7,_0x1cfed7,_0xfe19d3,_0x33507a,_0x4a4e21,_0x5f5e0c,_0x3d74f1),++_0x33507a===_0x48c0db)break;}_0x4a4e21['SPECULARTERM']=_0x3d74f1['specularEnabled'],_0x4a4e21['SHADOWS']=_0x3d74f1['shadowEnabled'];for(var _0x23d5b8=_0x33507a;_0x23d5b8<_0x48c0db;_0x23d5b8++)void 0x0!==_0x4a4e21['LIGHT'+_0x23d5b8]&&(_0x4a4e21['LIGHT'+_0x23d5b8]=!0x1,_0x4a4e21['HEMILIGHT'+_0x23d5b8]=!0x1,_0x4a4e21['POINTLIGHT'+_0x23d5b8]=!0x1,_0x4a4e21['DIRLIGHT'+_0x23d5b8]=!0x1,_0x4a4e21['SPOTLIGHT'+_0x23d5b8]=!0x1,_0x4a4e21['SHADOW'+_0x23d5b8]=!0x1,_0x4a4e21['SHADOWCSM'+_0x23d5b8]=!0x1,_0x4a4e21['SHADOWCSMDEBUG'+_0x23d5b8]=!0x1,_0x4a4e21['SHADOWCSMNUM_CASCADES'+_0x23d5b8]=!0x1,_0x4a4e21['SHADOWCSMUSESHADOWMAXZ'+_0x23d5b8]=!0x1,_0x4a4e21['SHADOWCSMNOBLEND'+_0x23d5b8]=!0x1,_0x4a4e21['SHADOWCSM_RIGHTHANDED'+_0x23d5b8]=!0x1,_0x4a4e21['SHADOWPCF'+_0x23d5b8]=!0x1,_0x4a4e21['SHADOWPCSS'+_0x23d5b8]=!0x1,_0x4a4e21['SHADOWPOISSON'+_0x23d5b8]=!0x1,_0x4a4e21['SHADOWESM'+_0x23d5b8]=!0x1,_0x4a4e21['SHADOWCLOSEESM'+_0x23d5b8]=!0x1,_0x4a4e21['SHADOWCUBE'+_0x23d5b8]=!0x1,_0x4a4e21['SHADOWLOWQUALITY'+_0x23d5b8]=!0x1,_0x4a4e21['SHADOWMEDIUMQUALITY'+_0x23d5b8]=!0x1);var _0x19e67a=_0x3925a7['getEngine']()['getCaps']();return void 0x0===_0x4a4e21['SHADOWFLOAT']&&(_0x3d74f1['needRebuild']=!0x0),_0x4a4e21['SHADOWFLOAT']=_0x3d74f1['shadowEnabled']&&(_0x19e67a['textureFloatRender']&&_0x19e67a['textureFloatLinearFiltering']||_0x19e67a['textureHalfFloatRender']&&_0x19e67a['textureHalfFloatLinearFiltering']),_0x4a4e21['LIGHTMAPEXCLUDED']=_0x3d74f1['lightmapMode'],_0x3d74f1['needRebuild']&&_0x4a4e21['rebuild'](),_0x3d74f1['needNormals'];},_0x3ab94b['PrepareUniformsAndSamplersForLight']=function(_0x3e56b8,_0x364dc7,_0x15419b,_0x28415c,_0x3ccfa0,_0x58671b){void 0x0===_0x3ccfa0&&(_0x3ccfa0=null),void 0x0===_0x58671b&&(_0x58671b=!0x1),_0x3ccfa0&&_0x3ccfa0['push']('Light'+_0x3e56b8),_0x58671b||(_0x364dc7['push']('vLightData'+_0x3e56b8,'vLightDiffuse'+_0x3e56b8,'vLightSpecular'+_0x3e56b8,'vLightDirection'+_0x3e56b8,'vLightFalloff'+_0x3e56b8,'vLightGround'+_0x3e56b8,'lightMatrix'+_0x3e56b8,'shadowsInfo'+_0x3e56b8,'depthValues'+_0x3e56b8),_0x15419b['push']('shadowSampler'+_0x3e56b8),_0x15419b['push']('depthSampler'+_0x3e56b8),_0x364dc7['push']('viewFrustumZ'+_0x3e56b8,'cascadeBlendFactor'+_0x3e56b8,'lightSizeUVCorrection'+_0x3e56b8,'depthCorrection'+_0x3e56b8,'penumbraDarkness'+_0x3e56b8,'frustumLengths'+_0x3e56b8),_0x28415c&&(_0x15419b['push']('projectionLightSampler'+_0x3e56b8),_0x364dc7['push']('textureProjectionMatrix'+_0x3e56b8)));},_0x3ab94b['PrepareUniformsAndSamplersList']=function(_0x38c08d,_0xe8a98b,_0x1ddb3c,_0x44e646){var _0x16c2dd;void 0x0===_0x44e646&&(_0x44e646=0x4);var _0x5129ea=null;if(_0x38c08d['uniformsNames']){var _0x2be8a2=_0x38c08d;_0x16c2dd=_0x2be8a2['uniformsNames'],_0x5129ea=_0x2be8a2['uniformBuffersNames'],_0xe8a98b=_0x2be8a2['samplers'],_0x1ddb3c=_0x2be8a2['defines'],_0x44e646=_0x2be8a2['maxSimultaneousLights']||0x0;}else _0x16c2dd=_0x38c08d,_0xe8a98b||(_0xe8a98b=[]);for(var _0x4d613c=0x0;_0x4d613c<_0x44e646&&_0x1ddb3c['LIGHT'+_0x4d613c];_0x4d613c++)this['PrepareUniformsAndSamplersForLight'](_0x4d613c,_0x16c2dd,_0xe8a98b,_0x1ddb3c['PROJECTEDLIGHTTEXTURE'+_0x4d613c],_0x5129ea);_0x1ddb3c['NUM_MORPH_INFLUENCERS']&&_0x16c2dd['push']('morphTargetInfluences');},_0x3ab94b['HandleFallbacksForShadows']=function(_0x53e311,_0x549f9e,_0x2f196a,_0x3f1cbd){void 0x0===_0x2f196a&&(_0x2f196a=0x4),void 0x0===_0x3f1cbd&&(_0x3f1cbd=0x0);for(var _0x339ecf=0x0,_0x30df4c=0x0;_0x30df4c<_0x2f196a&&_0x53e311['LIGHT'+_0x30df4c];_0x30df4c++)_0x30df4c>0x0&&(_0x339ecf=_0x3f1cbd+_0x30df4c,_0x549f9e['addFallback'](_0x339ecf,'LIGHT'+_0x30df4c)),_0x53e311['SHADOWS']||(_0x53e311['SHADOW'+_0x30df4c]&&_0x549f9e['addFallback'](_0x3f1cbd,'SHADOW'+_0x30df4c),_0x53e311['SHADOWPCF'+_0x30df4c]&&_0x549f9e['addFallback'](_0x3f1cbd,'SHADOWPCF'+_0x30df4c),_0x53e311['SHADOWPCSS'+_0x30df4c]&&_0x549f9e['addFallback'](_0x3f1cbd,'SHADOWPCSS'+_0x30df4c),_0x53e311['SHADOWPOISSON'+_0x30df4c]&&_0x549f9e['addFallback'](_0x3f1cbd,'SHADOWPOISSON'+_0x30df4c),_0x53e311['SHADOWESM'+_0x30df4c]&&_0x549f9e['addFallback'](_0x3f1cbd,'SHADOWESM'+_0x30df4c),_0x53e311['SHADOWCLOSEESM'+_0x30df4c]&&_0x549f9e['addFallback'](_0x3f1cbd,'SHADOWCLOSEESM'+_0x30df4c));return _0x339ecf++;},_0x3ab94b['PrepareAttributesForMorphTargetsInfluencers']=function(_0x3124a8,_0x5e4406,_0x2da06f){this['_TmpMorphInfluencers']['NUM_MORPH_INFLUENCERS']=_0x2da06f,this['PrepareAttributesForMorphTargets'](_0x3124a8,_0x5e4406,this['_TmpMorphInfluencers']);},_0x3ab94b['PrepareAttributesForMorphTargets']=function(_0x266ac5,_0x1b5e9d,_0x4e7fd2){var _0x5c6f9c=_0x4e7fd2['NUM_MORPH_INFLUENCERS'];if(_0x5c6f9c>0x0&&_0x45aa07['a']['LastCreatedEngine']){for(var _0x10d1a2=_0x45aa07['a']['LastCreatedEngine']['getCaps']()['maxVertexAttribs'],_0x3cd7d1=_0x1b5e9d['morphTargetManager'],_0xf29639=_0x3cd7d1&&_0x3cd7d1['supportsNormals']&&_0x4e7fd2['NORMAL'],_0x3ea0a0=_0x3cd7d1&&_0x3cd7d1['supportsTangents']&&_0x4e7fd2['TANGENT'],_0x493b8b=_0x3cd7d1&&_0x3cd7d1['supportsUVs']&&_0x4e7fd2['UV1'],_0x1def17=0x0;_0x1def17<_0x5c6f9c;_0x1def17++)_0x266ac5['push'](_0x422b24['b']['PositionKind']+_0x1def17),_0xf29639&&_0x266ac5['push'](_0x422b24['b']['NormalKind']+_0x1def17),_0x3ea0a0&&_0x266ac5['push'](_0x422b24['b']['TangentKind']+_0x1def17),_0x493b8b&&_0x266ac5['push'](_0x422b24['b']['UVKind']+'_'+_0x1def17),_0x266ac5['length']>_0x10d1a2&&_0x23b912['a']['Error']('Cannot\x20add\x20more\x20vertex\x20attributes\x20for\x20mesh\x20'+_0x1b5e9d['name']);}},_0x3ab94b['PrepareAttributesForBones']=function(_0x2e4ec5,_0x2a5c1f,_0x1ced14,_0x5ed48e){_0x1ced14['NUM_BONE_INFLUENCERS']>0x0&&(_0x5ed48e['addCPUSkinningFallback'](0x0,_0x2a5c1f),_0x2e4ec5['push'](_0x422b24['b']['MatricesIndicesKind']),_0x2e4ec5['push'](_0x422b24['b']['MatricesWeightsKind']),_0x1ced14['NUM_BONE_INFLUENCERS']>0x4&&(_0x2e4ec5['push'](_0x422b24['b']['MatricesIndicesExtraKind']),_0x2e4ec5['push'](_0x422b24['b']['MatricesWeightsExtraKind'])));},_0x3ab94b['PrepareAttributesForInstances']=function(_0x2e01a8,_0x3d235a){(_0x3d235a['INSTANCES']||_0x3d235a['THIN_INSTANCES'])&&this['PushAttributesForInstances'](_0x2e01a8);},_0x3ab94b['PushAttributesForInstances']=function(_0x14d014){_0x14d014['push']('world0'),_0x14d014['push']('world1'),_0x14d014['push']('world2'),_0x14d014['push']('world3');},_0x3ab94b['BindLightProperties']=function(_0x35e54a,_0x11c76c,_0x5ef978){_0x35e54a['transferToEffect'](_0x11c76c,_0x5ef978+'');},_0x3ab94b['BindLight']=function(_0x31ef3d,_0x1c2f40,_0x89866f,_0x54c63e,_0x2183c1,_0x312d82){void 0x0===_0x312d82&&(_0x312d82=!0x1),_0x31ef3d['_bindLight'](_0x1c2f40,_0x89866f,_0x54c63e,_0x2183c1,_0x312d82);},_0x3ab94b['BindLights']=function(_0x559d20,_0x374947,_0x2ffa80,_0x3bd59c,_0x19491a,_0x46173f){void 0x0===_0x19491a&&(_0x19491a=0x4),void 0x0===_0x46173f&&(_0x46173f=!0x1);for(var _0x8d4177=Math['min'](_0x374947['lightSources']['length'],_0x19491a),_0x29dae6=0x0;_0x29dae6<_0x8d4177;_0x29dae6++){var _0x103a69=_0x374947['lightSources'][_0x29dae6];this['BindLight'](_0x103a69,_0x29dae6,_0x559d20,_0x2ffa80,'boolean'==typeof _0x3bd59c?_0x3bd59c:_0x3bd59c['SPECULARTERM'],_0x46173f);}},_0x3ab94b['BindFogParameters']=function(_0x54347b,_0x3a0e5b,_0xbda41d,_0x16c958){void 0x0===_0x16c958&&(_0x16c958=!0x1),_0x54347b['fogEnabled']&&_0x3a0e5b['applyFog']&&_0x54347b['fogMode']!==_0x570a0b['a']['FOGMODE_NONE']&&(_0xbda41d['setFloat4']('vFogInfos',_0x54347b['fogMode'],_0x54347b['fogStart'],_0x54347b['fogEnd'],_0x54347b['fogDensity']),_0x16c958?(_0x54347b['fogColor']['toLinearSpaceToRef'](this['_tempFogColor']),_0xbda41d['setColor3']('vFogColor',this['_tempFogColor'])):_0xbda41d['setColor3']('vFogColor',_0x54347b['fogColor']));},_0x3ab94b['BindBonesParameters']=function(_0x43588b,_0x2c5622,_0x3a490f){if(_0x2c5622&&_0x43588b&&(_0x43588b['computeBonesUsingShaders']&&_0x2c5622['_bonesComputationForcedToCPU']&&(_0x43588b['computeBonesUsingShaders']=!0x1),_0x43588b['useBones']&&_0x43588b['computeBonesUsingShaders']&&_0x43588b['skeleton'])){var _0x5df653=_0x43588b['skeleton'];if(_0x5df653['isUsingTextureForMatrices']&&_0x2c5622['getUniformIndex']('boneTextureWidth')>-0x1){var _0xbf18c=_0x5df653['getTransformMatrixTexture'](_0x43588b);_0x2c5622['setTexture']('boneSampler',_0xbf18c),_0x2c5622['setFloat']('boneTextureWidth',0x4*(_0x5df653['bones']['length']+0x1));}else{var _0x19f345=_0x5df653['getTransformMatrices'](_0x43588b);_0x19f345&&(_0x2c5622['setMatrices']('mBones',_0x19f345),_0x3a490f&&_0x43588b['getScene']()['prePassRenderer']&&_0x43588b['getScene']()['prePassRenderer']['getIndex'](_0x5b750f['a']['PREPASS_VELOCITY_TEXTURE_TYPE'])&&(_0x3a490f['previousBones'][_0x43588b['uniqueId']]&&_0x2c5622['setMatrices']('mPreviousBones',_0x3a490f['previousBones'][_0x43588b['uniqueId']]),_0x3ab94b['_CopyBonesTransformationMatrices'](_0x19f345,_0x3a490f['previousBones'][_0x43588b['uniqueId']])));}}},_0x3ab94b['_CopyBonesTransformationMatrices']=function(_0x1d5aad,_0xd45322){return _0xd45322['set'](_0x1d5aad),_0xd45322;},_0x3ab94b['BindMorphTargetParameters']=function(_0xb99c68,_0x5a9992){var _0x1d2680=_0xb99c68['morphTargetManager'];_0xb99c68&&_0x1d2680&&_0x5a9992['setFloatArray']('morphTargetInfluences',_0x1d2680['influences']);},_0x3ab94b['BindLogDepth']=function(_0x475447,_0x15ec51,_0x2b6659){_0x475447['LOGARITHMICDEPTH']&&_0x15ec51['setFloat']('logarithmicDepthConstant',0x2/(Math['log'](_0x2b6659['activeCamera']['maxZ']+0x1)/Math['LN2']));},_0x3ab94b['BindClipPlane']=function(_0x24bc98,_0x2f86fe){_0x4c3334['a']['BindClipPlane'](_0x24bc98,_0x2f86fe);},_0x3ab94b['_TmpMorphInfluencers']={'NUM_MORPH_INFLUENCERS':0x0},_0x3ab94b['_tempFogColor']=_0x551e3e['a']['Black'](),_0x3ab94b;}());},function(_0x56195d,_0x32e2dd,_0x1345e7){'use strict';_0x1345e7['d'](_0x32e2dd,'a',function(){return _0x25a407;});var _0x5b656d=_0x1345e7(0x0),_0x54805c=_0x1345e7(0x4),_0x159e0e=_0x1345e7(0x15),_0x51ca4d=_0x1345e7(0x9),_0xe3951e=_0x1345e7(0x8),_0x25a407=(function(){function _0x417a7f(){}return _0x417a7f['prototype']['set']=function(_0xb924d4,_0x55e9af){switch(_0xb924d4['length']||_0xe3951e['a']['Warn']('Setting\x20vertex\x20data\x20kind\x20\x27'+_0x55e9af+'\x27\x20with\x20an\x20empty\x20array'),_0x55e9af){case _0x54805c['b']['PositionKind']:this['positions']=_0xb924d4;break;case _0x54805c['b']['NormalKind']:this['normals']=_0xb924d4;break;case _0x54805c['b']['TangentKind']:this['tangents']=_0xb924d4;break;case _0x54805c['b']['UVKind']:this['uvs']=_0xb924d4;break;case _0x54805c['b']['UV2Kind']:this['uvs2']=_0xb924d4;break;case _0x54805c['b']['UV3Kind']:this['uvs3']=_0xb924d4;break;case _0x54805c['b']['UV4Kind']:this['uvs4']=_0xb924d4;break;case _0x54805c['b']['UV5Kind']:this['uvs5']=_0xb924d4;break;case _0x54805c['b']['UV6Kind']:this['uvs6']=_0xb924d4;break;case _0x54805c['b']['ColorKind']:this['colors']=_0xb924d4;break;case _0x54805c['b']['MatricesIndicesKind']:this['matricesIndices']=_0xb924d4;break;case _0x54805c['b']['MatricesWeightsKind']:this['matricesWeights']=_0xb924d4;break;case _0x54805c['b']['MatricesIndicesExtraKind']:this['matricesIndicesExtra']=_0xb924d4;break;case _0x54805c['b']['MatricesWeightsExtraKind']:this['matricesWeightsExtra']=_0xb924d4;}},_0x417a7f['prototype']['applyToMesh']=function(_0xb6d7b1,_0x9bb27c){return this['_applyTo'](_0xb6d7b1,_0x9bb27c),this;},_0x417a7f['prototype']['applyToGeometry']=function(_0x2c1246,_0xe96c5a){return this['_applyTo'](_0x2c1246,_0xe96c5a),this;},_0x417a7f['prototype']['updateMesh']=function(_0x25638c){return this['_update'](_0x25638c),this;},_0x417a7f['prototype']['updateGeometry']=function(_0x37fa00){return this['_update'](_0x37fa00),this;},_0x417a7f['prototype']['_applyTo']=function(_0x409a15,_0x4f8ac7){return void 0x0===_0x4f8ac7&&(_0x4f8ac7=!0x1),this['positions']&&_0x409a15['setVerticesData'](_0x54805c['b']['PositionKind'],this['positions'],_0x4f8ac7),this['normals']&&_0x409a15['setVerticesData'](_0x54805c['b']['NormalKind'],this['normals'],_0x4f8ac7),this['tangents']&&_0x409a15['setVerticesData'](_0x54805c['b']['TangentKind'],this['tangents'],_0x4f8ac7),this['uvs']&&_0x409a15['setVerticesData'](_0x54805c['b']['UVKind'],this['uvs'],_0x4f8ac7),this['uvs2']&&_0x409a15['setVerticesData'](_0x54805c['b']['UV2Kind'],this['uvs2'],_0x4f8ac7),this['uvs3']&&_0x409a15['setVerticesData'](_0x54805c['b']['UV3Kind'],this['uvs3'],_0x4f8ac7),this['uvs4']&&_0x409a15['setVerticesData'](_0x54805c['b']['UV4Kind'],this['uvs4'],_0x4f8ac7),this['uvs5']&&_0x409a15['setVerticesData'](_0x54805c['b']['UV5Kind'],this['uvs5'],_0x4f8ac7),this['uvs6']&&_0x409a15['setVerticesData'](_0x54805c['b']['UV6Kind'],this['uvs6'],_0x4f8ac7),this['colors']&&_0x409a15['setVerticesData'](_0x54805c['b']['ColorKind'],this['colors'],_0x4f8ac7),this['matricesIndices']&&_0x409a15['setVerticesData'](_0x54805c['b']['MatricesIndicesKind'],this['matricesIndices'],_0x4f8ac7),this['matricesWeights']&&_0x409a15['setVerticesData'](_0x54805c['b']['MatricesWeightsKind'],this['matricesWeights'],_0x4f8ac7),this['matricesIndicesExtra']&&_0x409a15['setVerticesData'](_0x54805c['b']['MatricesIndicesExtraKind'],this['matricesIndicesExtra'],_0x4f8ac7),this['matricesWeightsExtra']&&_0x409a15['setVerticesData'](_0x54805c['b']['MatricesWeightsExtraKind'],this['matricesWeightsExtra'],_0x4f8ac7),this['indices']?_0x409a15['setIndices'](this['indices'],null,_0x4f8ac7):_0x409a15['setIndices']([],null),this;},_0x417a7f['prototype']['_update']=function(_0x4bf450,_0x18592d,_0x836c8f){return this['positions']&&_0x4bf450['updateVerticesData'](_0x54805c['b']['PositionKind'],this['positions'],_0x18592d,_0x836c8f),this['normals']&&_0x4bf450['updateVerticesData'](_0x54805c['b']['NormalKind'],this['normals'],_0x18592d,_0x836c8f),this['tangents']&&_0x4bf450['updateVerticesData'](_0x54805c['b']['TangentKind'],this['tangents'],_0x18592d,_0x836c8f),this['uvs']&&_0x4bf450['updateVerticesData'](_0x54805c['b']['UVKind'],this['uvs'],_0x18592d,_0x836c8f),this['uvs2']&&_0x4bf450['updateVerticesData'](_0x54805c['b']['UV2Kind'],this['uvs2'],_0x18592d,_0x836c8f),this['uvs3']&&_0x4bf450['updateVerticesData'](_0x54805c['b']['UV3Kind'],this['uvs3'],_0x18592d,_0x836c8f),this['uvs4']&&_0x4bf450['updateVerticesData'](_0x54805c['b']['UV4Kind'],this['uvs4'],_0x18592d,_0x836c8f),this['uvs5']&&_0x4bf450['updateVerticesData'](_0x54805c['b']['UV5Kind'],this['uvs5'],_0x18592d,_0x836c8f),this['uvs6']&&_0x4bf450['updateVerticesData'](_0x54805c['b']['UV6Kind'],this['uvs6'],_0x18592d,_0x836c8f),this['colors']&&_0x4bf450['updateVerticesData'](_0x54805c['b']['ColorKind'],this['colors'],_0x18592d,_0x836c8f),this['matricesIndices']&&_0x4bf450['updateVerticesData'](_0x54805c['b']['MatricesIndicesKind'],this['matricesIndices'],_0x18592d,_0x836c8f),this['matricesWeights']&&_0x4bf450['updateVerticesData'](_0x54805c['b']['MatricesWeightsKind'],this['matricesWeights'],_0x18592d,_0x836c8f),this['matricesIndicesExtra']&&_0x4bf450['updateVerticesData'](_0x54805c['b']['MatricesIndicesExtraKind'],this['matricesIndicesExtra'],_0x18592d,_0x836c8f),this['matricesWeightsExtra']&&_0x4bf450['updateVerticesData'](_0x54805c['b']['MatricesWeightsExtraKind'],this['matricesWeightsExtra'],_0x18592d,_0x836c8f),this['indices']&&_0x4bf450['setIndices'](this['indices'],null),this;},_0x417a7f['prototype']['transform']=function(_0x545270){var _0x25da8c,_0x2657a8=_0x545270['determinant']()<0x0,_0x2107ce=_0x5b656d['e']['Zero']();if(this['positions']){var _0x13c992=_0x5b656d['e']['Zero']();for(_0x25da8c=0x0;_0x25da8c_0x1a8d80['bbSize']['y']?_0x1a8d80['bbSize']['x']:_0x1a8d80['bbSize']['y'];_0x363386=_0x363386>_0x1a8d80['bbSize']['z']?_0x363386:_0x1a8d80['bbSize']['z'],_0x1425b0=_0x1a8d80['subDiv']['X']*_0x376d02/_0x1a8d80['bbSize']['x'],_0x13383b=_0x1a8d80['subDiv']['Y']*_0x376d02/_0x1a8d80['bbSize']['y'],_0x15d7c4=_0x1a8d80['subDiv']['Z']*_0x376d02/_0x1a8d80['bbSize']['z'],_0x312f1f=_0x1a8d80['subDiv']['max']*_0x1a8d80['subDiv']['max'],_0x1a8d80['facetPartitioning']['length']=0x0;}for(_0x5c9923=0x0;_0x5c9923<_0x36b8c7['length'];_0x5c9923++)_0x24f41a[_0x5c9923]=0x0;var _0x28c32c=_0x108794['length']/0x3|0x0;for(_0x5c9923=0x0;_0x5c9923<_0x28c32c;_0x5c9923++){if(_0x49ce34=(_0x407f76=0x3*_0x108794[0x3*_0x5c9923])+0x1,_0x5a4105=_0x407f76+0x2,_0x8cbc4d=(_0x12a4e9=0x3*_0x108794[0x3*_0x5c9923+0x1])+0x1,_0x1b0035=_0x12a4e9+0x2,_0x37a7dc=(_0x27fdf4=0x3*_0x108794[0x3*_0x5c9923+0x2])+0x1,_0x561481=_0x27fdf4+0x2,_0x3c1f60=_0x36b8c7[_0x407f76]-_0x36b8c7[_0x12a4e9],_0x48c4d0=_0x36b8c7[_0x49ce34]-_0x36b8c7[_0x8cbc4d],_0x51756a=_0x36b8c7[_0x5a4105]-_0x36b8c7[_0x1b0035],_0x1f7f20=_0x36b8c7[_0x27fdf4]-_0x36b8c7[_0x12a4e9],_0x20e91c=_0x36b8c7[_0x37a7dc]-_0x36b8c7[_0x8cbc4d],_0x39f5cb=_0x3aaf73*(_0x48c4d0*(_0x4ff1fd=_0x36b8c7[_0x561481]-_0x36b8c7[_0x1b0035])-_0x51756a*_0x20e91c),_0x4c56ea=_0x3aaf73*(_0x51756a*_0x1f7f20-_0x3c1f60*_0x4ff1fd),_0x4f6a51=_0x3aaf73*(_0x3c1f60*_0x20e91c-_0x48c4d0*_0x1f7f20),_0x39f5cb/=_0x44c9bf=0x0===(_0x44c9bf=Math['sqrt'](_0x39f5cb*_0x39f5cb+_0x4c56ea*_0x4c56ea+_0x4f6a51*_0x4f6a51))?0x1:_0x44c9bf,_0x4c56ea/=_0x44c9bf,_0x4f6a51/=_0x44c9bf,_0x414943&&_0x1a8d80&&(_0x1a8d80['facetNormals'][_0x5c9923]['x']=_0x39f5cb,_0x1a8d80['facetNormals'][_0x5c9923]['y']=_0x4c56ea,_0x1a8d80['facetNormals'][_0x5c9923]['z']=_0x4f6a51),_0x4dc8e0&&_0x1a8d80&&(_0x1a8d80['facetPositions'][_0x5c9923]['x']=(_0x36b8c7[_0x407f76]+_0x36b8c7[_0x12a4e9]+_0x36b8c7[_0x27fdf4])/0x3,_0x1a8d80['facetPositions'][_0x5c9923]['y']=(_0x36b8c7[_0x49ce34]+_0x36b8c7[_0x8cbc4d]+_0x36b8c7[_0x37a7dc])/0x3,_0x1a8d80['facetPositions'][_0x5c9923]['z']=(_0x36b8c7[_0x5a4105]+_0x36b8c7[_0x1b0035]+_0x36b8c7[_0x561481])/0x3),_0x33702f&&_0x1a8d80&&(_0x6618a3=Math['floor']((_0x1a8d80['facetPositions'][_0x5c9923]['x']-_0x1a8d80['bInfo']['minimum']['x']*_0x376d02)*_0x1425b0),_0x311bd5=Math['floor']((_0x1a8d80['facetPositions'][_0x5c9923]['y']-_0x1a8d80['bInfo']['minimum']['y']*_0x376d02)*_0x13383b),_0x28c31c=Math['floor']((_0x1a8d80['facetPositions'][_0x5c9923]['z']-_0x1a8d80['bInfo']['minimum']['z']*_0x376d02)*_0x15d7c4),_0x4969a8=Math['floor']((_0x36b8c7[_0x407f76]-_0x1a8d80['bInfo']['minimum']['x']*_0x376d02)*_0x1425b0),_0x1f24a1=Math['floor']((_0x36b8c7[_0x49ce34]-_0x1a8d80['bInfo']['minimum']['y']*_0x376d02)*_0x13383b),_0xb9b352=Math['floor']((_0x36b8c7[_0x5a4105]-_0x1a8d80['bInfo']['minimum']['z']*_0x376d02)*_0x15d7c4),_0x1b1eb0=Math['floor']((_0x36b8c7[_0x12a4e9]-_0x1a8d80['bInfo']['minimum']['x']*_0x376d02)*_0x1425b0),_0x5f0e1e=Math['floor']((_0x36b8c7[_0x8cbc4d]-_0x1a8d80['bInfo']['minimum']['y']*_0x376d02)*_0x13383b),_0x162484=Math['floor']((_0x36b8c7[_0x1b0035]-_0x1a8d80['bInfo']['minimum']['z']*_0x376d02)*_0x15d7c4),_0x4ba87d=Math['floor']((_0x36b8c7[_0x27fdf4]-_0x1a8d80['bInfo']['minimum']['x']*_0x376d02)*_0x1425b0),_0x85298d=Math['floor']((_0x36b8c7[_0x37a7dc]-_0x1a8d80['bInfo']['minimum']['y']*_0x376d02)*_0x13383b),_0x3a504a=Math['floor']((_0x36b8c7[_0x561481]-_0x1a8d80['bInfo']['minimum']['z']*_0x376d02)*_0x15d7c4),_0x2b3c70=_0x4969a8+_0x1a8d80['subDiv']['max']*_0x1f24a1+_0x312f1f*_0xb9b352,_0x57cec4=_0x1b1eb0+_0x1a8d80['subDiv']['max']*_0x5f0e1e+_0x312f1f*_0x162484,_0x563e06=_0x4ba87d+_0x1a8d80['subDiv']['max']*_0x85298d+_0x312f1f*_0x3a504a,_0x3cb930=_0x6618a3+_0x1a8d80['subDiv']['max']*_0x311bd5+_0x312f1f*_0x28c31c,_0x1a8d80['facetPartitioning'][_0x3cb930]=_0x1a8d80['facetPartitioning'][_0x3cb930]?_0x1a8d80['facetPartitioning'][_0x3cb930]:new Array(),_0x1a8d80['facetPartitioning'][_0x2b3c70]=_0x1a8d80['facetPartitioning'][_0x2b3c70]?_0x1a8d80['facetPartitioning'][_0x2b3c70]:new Array(),_0x1a8d80['facetPartitioning'][_0x57cec4]=_0x1a8d80['facetPartitioning'][_0x57cec4]?_0x1a8d80['facetPartitioning'][_0x57cec4]:new Array(),_0x1a8d80['facetPartitioning'][_0x563e06]=_0x1a8d80['facetPartitioning'][_0x563e06]?_0x1a8d80['facetPartitioning'][_0x563e06]:new Array(),_0x1a8d80['facetPartitioning'][_0x2b3c70]['push'](_0x5c9923),_0x57cec4!=_0x2b3c70&&_0x1a8d80['facetPartitioning'][_0x57cec4]['push'](_0x5c9923),_0x563e06!=_0x57cec4&&_0x563e06!=_0x2b3c70&&_0x1a8d80['facetPartitioning'][_0x563e06]['push'](_0x5c9923),_0x3cb930!=_0x2b3c70&&_0x3cb930!=_0x57cec4&&_0x3cb930!=_0x563e06&&_0x1a8d80['facetPartitioning'][_0x3cb930]['push'](_0x5c9923)),_0x16410&&_0x1a8d80&&_0x1a8d80['facetPositions']){var _0x469970=_0x191eaa[_0x5c9923];_0x469970['ind']=0x3*_0x5c9923,_0x469970['sqDistance']=_0x5b656d['e']['DistanceSquared'](_0x1a8d80['facetPositions'][_0x5c9923],_0x55efd1);}_0x24f41a[_0x407f76]+=_0x39f5cb,_0x24f41a[_0x49ce34]+=_0x4c56ea,_0x24f41a[_0x5a4105]+=_0x4f6a51,_0x24f41a[_0x12a4e9]+=_0x39f5cb,_0x24f41a[_0x8cbc4d]+=_0x4c56ea,_0x24f41a[_0x1b0035]+=_0x4f6a51,_0x24f41a[_0x27fdf4]+=_0x39f5cb,_0x24f41a[_0x37a7dc]+=_0x4c56ea,_0x24f41a[_0x561481]+=_0x4f6a51;}for(_0x5c9923=0x0;_0x5c9923<_0x24f41a['length']/0x3;_0x5c9923++)_0x39f5cb=_0x24f41a[0x3*_0x5c9923],_0x4c56ea=_0x24f41a[0x3*_0x5c9923+0x1],_0x4f6a51=_0x24f41a[0x3*_0x5c9923+0x2],_0x39f5cb/=_0x44c9bf=0x0===(_0x44c9bf=Math['sqrt'](_0x39f5cb*_0x39f5cb+_0x4c56ea*_0x4c56ea+_0x4f6a51*_0x4f6a51))?0x1:_0x44c9bf,_0x4c56ea/=_0x44c9bf,_0x4f6a51/=_0x44c9bf,_0x24f41a[0x3*_0x5c9923]=_0x39f5cb,_0x24f41a[0x3*_0x5c9923+0x1]=_0x4c56ea,_0x24f41a[0x3*_0x5c9923+0x2]=_0x4f6a51;},_0x417a7f['_ComputeSides']=function(_0x26f3c7,_0x11e102,_0x116b97,_0x2e1cce,_0x2e834a,_0x1eb9f1,_0x5afed5){var _0x3fff68,_0x5a3372,_0x19e64b=_0x116b97['length'],_0x4827c6=_0x2e1cce['length'];switch(_0x26f3c7=_0x26f3c7||_0x417a7f['DEFAULTSIDE']){case _0x417a7f['FRONTSIDE']:break;case _0x417a7f['BACKSIDE']:var _0x45a57e;for(_0x3fff68=0x0;_0x3fff68<_0x19e64b;_0x3fff68+=0x3)_0x45a57e=_0x116b97[_0x3fff68],_0x116b97[_0x3fff68]=_0x116b97[_0x3fff68+0x2],_0x116b97[_0x3fff68+0x2]=_0x45a57e;for(_0x5a3372=0x0;_0x5a3372<_0x4827c6;_0x5a3372++)_0x2e1cce[_0x5a3372]=-_0x2e1cce[_0x5a3372];break;case _0x417a7f['DOUBLESIDE']:for(var _0x2e7203=_0x11e102['length'],_0x3ac8f0=_0x2e7203/0x3,_0x114445=0x0;_0x114445<_0x2e7203;_0x114445++)_0x11e102[_0x2e7203+_0x114445]=_0x11e102[_0x114445];for(_0x3fff68=0x0;_0x3fff68<_0x19e64b;_0x3fff68+=0x3)_0x116b97[_0x3fff68+_0x19e64b]=_0x116b97[_0x3fff68+0x2]+_0x3ac8f0,_0x116b97[_0x3fff68+0x1+_0x19e64b]=_0x116b97[_0x3fff68+0x1]+_0x3ac8f0,_0x116b97[_0x3fff68+0x2+_0x19e64b]=_0x116b97[_0x3fff68]+_0x3ac8f0;for(_0x5a3372=0x0;_0x5a3372<_0x4827c6;_0x5a3372++)_0x2e1cce[_0x4827c6+_0x5a3372]=-_0x2e1cce[_0x5a3372];var _0x33d466=_0x2e834a['length'],_0x9b783a=0x0;for(_0x9b783a=0x0;_0x9b783a<_0x33d466;_0x9b783a++)_0x2e834a[_0x9b783a+_0x33d466]=_0x2e834a[_0x9b783a];for(_0x1eb9f1=_0x1eb9f1||new _0x5b656d['f'](0x0,0x0,0x1,0x1),_0x5afed5=_0x5afed5||new _0x5b656d['f'](0x0,0x0,0x1,0x1),_0x9b783a=0x0,_0x3fff68=0x0;_0x3fff68<_0x33d466/0x2;_0x3fff68++)_0x2e834a[_0x9b783a]=_0x1eb9f1['x']+(_0x1eb9f1['z']-_0x1eb9f1['x'])*_0x2e834a[_0x9b783a],_0x2e834a[_0x9b783a+0x1]=_0x1eb9f1['y']+(_0x1eb9f1['w']-_0x1eb9f1['y'])*_0x2e834a[_0x9b783a+0x1],_0x2e834a[_0x9b783a+_0x33d466]=_0x5afed5['x']+(_0x5afed5['z']-_0x5afed5['x'])*_0x2e834a[_0x9b783a+_0x33d466],_0x2e834a[_0x9b783a+_0x33d466+0x1]=_0x5afed5['y']+(_0x5afed5['w']-_0x5afed5['y'])*_0x2e834a[_0x9b783a+_0x33d466+0x1],_0x9b783a+=0x2;}},_0x417a7f['ImportVertexData']=function(_0x5f528f,_0x4a6695){var _0x7af1c1=new _0x417a7f(),_0x24d59d=_0x5f528f['positions'];_0x24d59d&&_0x7af1c1['set'](_0x24d59d,_0x54805c['b']['PositionKind']);var _0x5275ea=_0x5f528f['normals'];_0x5275ea&&_0x7af1c1['set'](_0x5275ea,_0x54805c['b']['NormalKind']);var _0x596769=_0x5f528f['tangents'];_0x596769&&_0x7af1c1['set'](_0x596769,_0x54805c['b']['TangentKind']);var _0x3aae1c=_0x5f528f['uvs'];_0x3aae1c&&_0x7af1c1['set'](_0x3aae1c,_0x54805c['b']['UVKind']);var _0x23c28c=_0x5f528f['uv2s'];_0x23c28c&&_0x7af1c1['set'](_0x23c28c,_0x54805c['b']['UV2Kind']);var _0xea84f=_0x5f528f['uv3s'];_0xea84f&&_0x7af1c1['set'](_0xea84f,_0x54805c['b']['UV3Kind']);var _0xd7b35d=_0x5f528f['uv4s'];_0xd7b35d&&_0x7af1c1['set'](_0xd7b35d,_0x54805c['b']['UV4Kind']);var _0x1d59af=_0x5f528f['uv5s'];_0x1d59af&&_0x7af1c1['set'](_0x1d59af,_0x54805c['b']['UV5Kind']);var _0x1475f2=_0x5f528f['uv6s'];_0x1475f2&&_0x7af1c1['set'](_0x1475f2,_0x54805c['b']['UV6Kind']);var _0x4025b3=_0x5f528f['colors'];_0x4025b3&&_0x7af1c1['set'](_0x51ca4d['b']['CheckColors4'](_0x4025b3,_0x24d59d['length']/0x3),_0x54805c['b']['ColorKind']);var _0x18e938=_0x5f528f['matricesIndices'];_0x18e938&&_0x7af1c1['set'](_0x18e938,_0x54805c['b']['MatricesIndicesKind']);var _0x290cee=_0x5f528f['matricesWeights'];_0x290cee&&_0x7af1c1['set'](_0x290cee,_0x54805c['b']['MatricesWeightsKind']);var _0xc5a5d6=_0x5f528f['indices'];_0xc5a5d6&&(_0x7af1c1['indices']=_0xc5a5d6),_0x4a6695['setAllVerticesData'](_0x7af1c1,_0x5f528f['updatable']);},_0x417a7f['FRONTSIDE']=0x0,_0x417a7f['BACKSIDE']=0x1,_0x417a7f['DOUBLESIDE']=0x2,_0x417a7f['DEFAULTSIDE']=0x0,_0x417a7f;}());},function(_0x4f8fc7,_0x142c58,_0x4a53e1){'use strict';_0x4a53e1['d'](_0x142c58,'a',function(){return _0x5cb351;}),_0x4a53e1['d'](_0x142c58,'b',function(){return _0x583d4c;});var _0x182056=_0x4a53e1(0x1),_0x5cb351=(function(){function _0x12d48d(){}return _0x12d48d['NAME_EFFECTLAYER']='EffectLayer',_0x12d48d['NAME_LAYER']='Layer',_0x12d48d['NAME_LENSFLARESYSTEM']='LensFlareSystem',_0x12d48d['NAME_BOUNDINGBOXRENDERER']='BoundingBoxRenderer',_0x12d48d['NAME_PARTICLESYSTEM']='ParticleSystem',_0x12d48d['NAME_GAMEPAD']='Gamepad',_0x12d48d['NAME_SIMPLIFICATIONQUEUE']='SimplificationQueue',_0x12d48d['NAME_GEOMETRYBUFFERRENDERER']='GeometryBufferRenderer',_0x12d48d['NAME_PREPASSRENDERER']='PrePassRenderer',_0x12d48d['NAME_DEPTHRENDERER']='DepthRenderer',_0x12d48d['NAME_POSTPROCESSRENDERPIPELINEMANAGER']='PostProcessRenderPipelineManager',_0x12d48d['NAME_SPRITE']='Sprite',_0x12d48d['NAME_SUBSURFACE']='SubSurface',_0x12d48d['NAME_OUTLINERENDERER']='Outline',_0x12d48d['NAME_PROCEDURALTEXTURE']='ProceduralTexture',_0x12d48d['NAME_SHADOWGENERATOR']='ShadowGenerator',_0x12d48d['NAME_OCTREE']='Octree',_0x12d48d['NAME_PHYSICSENGINE']='PhysicsEngine',_0x12d48d['NAME_AUDIO']='Audio',_0x12d48d['STEP_ISREADYFORMESH_EFFECTLAYER']=0x0,_0x12d48d['STEP_BEFOREEVALUATEACTIVEMESH_BOUNDINGBOXRENDERER']=0x0,_0x12d48d['STEP_EVALUATESUBMESH_BOUNDINGBOXRENDERER']=0x0,_0x12d48d['STEP_PREACTIVEMESH_BOUNDINGBOXRENDERER']=0x0,_0x12d48d['STEP_CAMERADRAWRENDERTARGET_EFFECTLAYER']=0x1,_0x12d48d['STEP_BEFORECAMERADRAW_EFFECTLAYER']=0x0,_0x12d48d['STEP_BEFORECAMERADRAW_LAYER']=0x1,_0x12d48d['STEP_BEFORECAMERADRAW_PREPASS']=0x2,_0x12d48d['STEP_BEFORERENDERTARGETDRAW_LAYER']=0x0,_0x12d48d['STEP_BEFORERENDERINGMESH_PREPASS']=0x0,_0x12d48d['STEP_BEFORERENDERINGMESH_OUTLINE']=0x1,_0x12d48d['STEP_AFTERRENDERINGMESH_PREPASS']=0x0,_0x12d48d['STEP_AFTERRENDERINGMESH_OUTLINE']=0x1,_0x12d48d['STEP_AFTERRENDERINGGROUPDRAW_EFFECTLAYER_DRAW']=0x0,_0x12d48d['STEP_AFTERRENDERINGGROUPDRAW_BOUNDINGBOXRENDERER']=0x1,_0x12d48d['STEP_BEFORECAMERAUPDATE_SIMPLIFICATIONQUEUE']=0x0,_0x12d48d['STEP_BEFORECAMERAUPDATE_GAMEPAD']=0x1,_0x12d48d['STEP_BEFORECLEAR_PROCEDURALTEXTURE']=0x0,_0x12d48d['STEP_AFTERRENDERTARGETDRAW_LAYER']=0x0,_0x12d48d['STEP_AFTERCAMERADRAW_EFFECTLAYER']=0x0,_0x12d48d['STEP_AFTERCAMERADRAW_LENSFLARESYSTEM']=0x1,_0x12d48d['STEP_AFTERCAMERADRAW_EFFECTLAYER_DRAW']=0x2,_0x12d48d['STEP_AFTERCAMERADRAW_LAYER']=0x3,_0x12d48d['STEP_AFTERCAMERADRAW_PREPASS']=0x4,_0x12d48d['STEP_AFTERRENDER_AUDIO']=0x0,_0x12d48d['STEP_GATHERRENDERTARGETS_DEPTHRENDERER']=0x0,_0x12d48d['STEP_GATHERRENDERTARGETS_GEOMETRYBUFFERRENDERER']=0x1,_0x12d48d['STEP_GATHERRENDERTARGETS_SHADOWGENERATOR']=0x2,_0x12d48d['STEP_GATHERRENDERTARGETS_POSTPROCESSRENDERPIPELINEMANAGER']=0x3,_0x12d48d['STEP_GATHERACTIVECAMERARENDERTARGETS_DEPTHRENDERER']=0x0,_0x12d48d['STEP_BEFORECLEARSTAGE_PREPASS']=0x0,_0x12d48d['STEP_POINTERMOVE_SPRITE']=0x0,_0x12d48d['STEP_POINTERDOWN_SPRITE']=0x0,_0x12d48d['STEP_POINTERUP_SPRITE']=0x0,_0x12d48d;}()),_0x583d4c=function(_0x568fce){function _0x13c3a7(_0x482218){return _0x568fce['apply'](this,_0x482218)||this;}return Object(_0x182056['d'])(_0x13c3a7,_0x568fce),_0x13c3a7['Create']=function(){return Object['create'](_0x13c3a7['prototype']);},_0x13c3a7['prototype']['registerStep']=function(_0x541c9e,_0x51c26e,_0x3178aa){var _0xf23b8d=0x0;for(Number['MAX_VALUE'];_0xf23b8d_0x284d15['LongPressDelay']&&!_0x2d3b3b['_isPointerSwiping']()&&(_0x2d3b3b['_startingPointerTime']=0x0,_0x2b40c7['processTrigger'](_0x244e90['a']['ACTION_OnLongPressTrigger'],_0x3cad45['a']['CreateNew'](_0x53bc0d['pickedMesh'],_0x5f1b4e)));},_0x284d15['LongPressDelay']);}}else for(var _0x1852e3=0x0,_0x153856=_0x4cdfc0['_pointerDownStage'];_0x1852e3<_0x153856['length'];_0x1852e3++){_0x1dc17b=_0x153856[_0x1852e3]['action'](this['_unTranslatedPointerX'],this['_unTranslatedPointerY'],_0x1dc17b,_0x5f1b4e);}if(_0x1dc17b){var _0x1115e1=_0x5e7526['a']['POINTERDOWN'];if(_0x4cdfc0['onPointerDown']&&_0x4cdfc0['onPointerDown'](_0x5f1b4e,_0x1dc17b,_0x1115e1),_0x4cdfc0['onPointerObservable']['hasObservers']()){var _0x5209a1=new _0x5e7526['b'](_0x1115e1,_0x5f1b4e,_0x1dc17b);this['_setRayOnPointerInfo'](_0x5209a1),_0x4cdfc0['onPointerObservable']['notifyObservers'](_0x5209a1,_0x1115e1);}}},_0x284d15['prototype']['_isPointerSwiping']=function(){return Math['abs'](this['_startingPointerPosition']['x']-this['_pointerX'])>_0x284d15['DragMovementThreshold']||Math['abs'](this['_startingPointerPosition']['y']-this['_pointerY'])>_0x284d15['DragMovementThreshold'];},_0x284d15['prototype']['simulatePointerUp']=function(_0x36f9a6,_0x1fbf85,_0x18c3ef){var _0x4405b3=new PointerEvent('pointerup',_0x1fbf85),_0x206140=new _0x293b8d();_0x18c3ef?_0x206140['doubleClick']=!0x0:_0x206140['singleClick']=!0x0,this['_checkPrePointerObservable'](_0x36f9a6,_0x4405b3,_0x5e7526['a']['POINTERUP'])||this['_processPointerUp'](_0x36f9a6,_0x4405b3,_0x206140);},_0x284d15['prototype']['_processPointerUp']=function(_0x1d5351,_0x23b48e,_0x140d45){var _0x32e951=this['_scene'];if(_0x1d5351&&_0x1d5351&&_0x1d5351['pickedMesh']){if(this['_pickedUpMesh']=_0x1d5351['pickedMesh'],this['_pickedDownMesh']===this['_pickedUpMesh']&&(_0x32e951['onPointerPick']&&_0x32e951['onPointerPick'](_0x23b48e,_0x1d5351),_0x140d45['singleClick']&&!_0x140d45['ignore']&&_0x32e951['onPointerObservable']['hasObservers']())){var _0x527e78=_0x5e7526['a']['POINTERPICK'],_0x31c255=new _0x5e7526['b'](_0x527e78,_0x23b48e,_0x1d5351);this['_setRayOnPointerInfo'](_0x31c255),_0x32e951['onPointerObservable']['notifyObservers'](_0x31c255,_0x527e78);}var _0x32ab90=_0x1d5351['pickedMesh']['_getActionManagerForTrigger']();if(_0x32ab90&&!_0x140d45['ignore']){_0x32ab90['processTrigger'](_0x244e90['a']['ACTION_OnPickUpTrigger'],_0x3cad45['a']['CreateNew'](_0x1d5351['pickedMesh'],_0x23b48e)),!_0x140d45['hasSwiped']&&_0x140d45['singleClick']&&_0x32ab90['processTrigger'](_0x244e90['a']['ACTION_OnPickTrigger'],_0x3cad45['a']['CreateNew'](_0x1d5351['pickedMesh'],_0x23b48e));var _0x5d1753=_0x1d5351['pickedMesh']['_getActionManagerForTrigger'](_0x244e90['a']['ACTION_OnDoublePickTrigger']);_0x140d45['doubleClick']&&_0x5d1753&&_0x5d1753['processTrigger'](_0x244e90['a']['ACTION_OnDoublePickTrigger'],_0x3cad45['a']['CreateNew'](_0x1d5351['pickedMesh'],_0x23b48e));}}else{if(!_0x140d45['ignore'])for(var _0x11343c=0x0,_0x4c63eb=_0x32e951['_pointerUpStage'];_0x11343c<_0x4c63eb['length'];_0x11343c++){_0x1d5351=_0x4c63eb[_0x11343c]['action'](this['_unTranslatedPointerX'],this['_unTranslatedPointerY'],_0x1d5351,_0x23b48e);}}if(this['_pickedDownMesh']&&this['_pickedDownMesh']!==this['_pickedUpMesh']){var _0x4c0943=this['_pickedDownMesh']['_getActionManagerForTrigger'](_0x244e90['a']['ACTION_OnPickOutTrigger']);_0x4c0943&&_0x4c0943['processTrigger'](_0x244e90['a']['ACTION_OnPickOutTrigger'],_0x3cad45['a']['CreateNew'](this['_pickedDownMesh'],_0x23b48e));}var _0x3a8e86=0x0;_0x32e951['onPointerObservable']['hasObservers']()&&(!_0x140d45['ignore']&&!_0x140d45['hasSwiped']&&(_0x140d45['singleClick']&&_0x32e951['onPointerObservable']['hasSpecificMask'](_0x5e7526['a']['POINTERTAP'])?_0x3a8e86=_0x5e7526['a']['POINTERTAP']:_0x140d45['doubleClick']&&_0x32e951['onPointerObservable']['hasSpecificMask'](_0x5e7526['a']['POINTERDOUBLETAP'])&&(_0x3a8e86=_0x5e7526['a']['POINTERDOUBLETAP']),_0x3a8e86)&&(_0x31c255=new _0x5e7526['b'](_0x3a8e86,_0x23b48e,_0x1d5351),(this['_setRayOnPointerInfo'](_0x31c255),_0x32e951['onPointerObservable']['notifyObservers'](_0x31c255,_0x3a8e86))),!_0x140d45['ignore']&&(_0x3a8e86=_0x5e7526['a']['POINTERUP'],_0x31c255=new _0x5e7526['b'](_0x3a8e86,_0x23b48e,_0x1d5351),(this['_setRayOnPointerInfo'](_0x31c255),_0x32e951['onPointerObservable']['notifyObservers'](_0x31c255,_0x3a8e86)))),_0x32e951['onPointerUp']&&!_0x140d45['ignore']&&_0x32e951['onPointerUp'](_0x23b48e,_0x1d5351,_0x3a8e86);},_0x284d15['prototype']['isPointerCaptured']=function(_0x50c506){return void 0x0===_0x50c506&&(_0x50c506=0x0),this['_pointerCaptures'][_0x50c506];},_0x284d15['prototype']['attachControl']=function(_0x17e44e,_0x3252b9,_0x2d2dda,_0x1e625f){var _0x2ef84b=this;void 0x0===_0x17e44e&&(_0x17e44e=!0x0),void 0x0===_0x3252b9&&(_0x3252b9=!0x0),void 0x0===_0x2d2dda&&(_0x2d2dda=!0x0),void 0x0===_0x1e625f&&(_0x1e625f=null);var _0x1898e9=this['_scene'];if(_0x1e625f||(_0x1e625f=_0x1898e9['getEngine']()['getInputElement']()),_0x1e625f){this['_alreadyAttached']&&this['detachControl'](),this['_alreadyAttachedTo']=_0x1e625f;var _0x51b7ec=_0x1898e9['getEngine']();this['_initActionManager']=function(_0x305b00,_0x1e352c){if(!_0x2ef84b['_meshPickProceed']){var _0x2f90e3=_0x1898e9['pick'](_0x2ef84b['_unTranslatedPointerX'],_0x2ef84b['_unTranslatedPointerY'],_0x1898e9['pointerDownPredicate'],!0x1,_0x1898e9['cameraToUseForPointers']);_0x2ef84b['_currentPickResult']=_0x2f90e3,_0x2f90e3&&(_0x305b00=_0x2f90e3['hit']&&_0x2f90e3['pickedMesh']?_0x2f90e3['pickedMesh']['_getActionManagerForTrigger']():null),_0x2ef84b['_meshPickProceed']=!0x0;}return _0x305b00;},this['_delayedSimpleClick']=function(_0x2d759e,_0x4f2b06,_0x1ea2c1){(Date['now']()-_0x2ef84b['_previousStartingPointerTime']>_0x284d15['DoubleClickDelay']&&!_0x2ef84b['_doubleClickOccured']||_0x2d759e!==_0x2ef84b['_previousButtonPressed'])&&(_0x2ef84b['_doubleClickOccured']=!0x1,_0x4f2b06['singleClick']=!0x0,_0x4f2b06['ignore']=!0x1,_0x1ea2c1(_0x4f2b06,_0x2ef84b['_currentPickResult']));},this['_initClickEvent']=function(_0x352ac5,_0x46db84,_0x13836d,_0x45d0fb){var _0x40e67a=new _0x293b8d();_0x2ef84b['_currentPickResult']=null;var _0x29e250=null,_0x1e4e5c=_0x352ac5['hasSpecificMask'](_0x5e7526['a']['POINTERPICK'])||_0x46db84['hasSpecificMask'](_0x5e7526['a']['POINTERPICK'])||_0x352ac5['hasSpecificMask'](_0x5e7526['a']['POINTERTAP'])||_0x46db84['hasSpecificMask'](_0x5e7526['a']['POINTERTAP'])||_0x352ac5['hasSpecificMask'](_0x5e7526['a']['POINTERDOUBLETAP'])||_0x46db84['hasSpecificMask'](_0x5e7526['a']['POINTERDOUBLETAP']);!_0x1e4e5c&&_0x2e609b['a']&&(_0x29e250=_0x2ef84b['_initActionManager'](_0x29e250,_0x40e67a))&&(_0x1e4e5c=_0x29e250['hasPickTriggers']);var _0x260394=!0x1;if(_0x1e4e5c){var _0x4866fa=_0x13836d['button'];if(_0x40e67a['hasSwiped']=_0x2ef84b['_isPointerSwiping'](),!_0x40e67a['hasSwiped']){var _0x2e2860=!_0x284d15['ExclusiveDoubleClickMode'];_0x2e2860||(_0x2e2860=!_0x352ac5['hasSpecificMask'](_0x5e7526['a']['POINTERDOUBLETAP'])&&!_0x46db84['hasSpecificMask'](_0x5e7526['a']['POINTERDOUBLETAP']))&&!_0x2e609b['a']['HasSpecificTrigger'](_0x244e90['a']['ACTION_OnDoublePickTrigger'])&&(_0x29e250=_0x2ef84b['_initActionManager'](_0x29e250,_0x40e67a))&&(_0x2e2860=!_0x29e250['hasSpecificTrigger'](_0x244e90['a']['ACTION_OnDoublePickTrigger'])),_0x2e2860?(Date['now']()-_0x2ef84b['_previousStartingPointerTime']>_0x284d15['DoubleClickDelay']||_0x4866fa!==_0x2ef84b['_previousButtonPressed'])&&(_0x40e67a['singleClick']=!0x0,_0x45d0fb(_0x40e67a,_0x2ef84b['_currentPickResult']),_0x260394=!0x0):(_0x2ef84b['_previousDelayedSimpleClickTimeout']=_0x2ef84b['_delayedSimpleClickTimeout'],_0x2ef84b['_delayedSimpleClickTimeout']=window['setTimeout'](_0x2ef84b['_delayedSimpleClick']['bind'](_0x2ef84b,_0x4866fa,_0x40e67a,_0x45d0fb),_0x284d15['DoubleClickDelay']));var _0x466c0a=_0x352ac5['hasSpecificMask'](_0x5e7526['a']['POINTERDOUBLETAP'])||_0x46db84['hasSpecificMask'](_0x5e7526['a']['POINTERDOUBLETAP']);!_0x466c0a&&_0x2e609b['a']['HasSpecificTrigger'](_0x244e90['a']['ACTION_OnDoublePickTrigger'])&&(_0x29e250=_0x2ef84b['_initActionManager'](_0x29e250,_0x40e67a))&&(_0x466c0a=_0x29e250['hasSpecificTrigger'](_0x244e90['a']['ACTION_OnDoublePickTrigger'])),_0x466c0a&&(_0x4866fa===_0x2ef84b['_previousButtonPressed']&&Date['now']()-_0x2ef84b['_previousStartingPointerTime']<_0x284d15['DoubleClickDelay']&&!_0x2ef84b['_doubleClickOccured']?(_0x40e67a['hasSwiped']||_0x2ef84b['_isPointerSwiping']()?(_0x2ef84b['_doubleClickOccured']=!0x1,_0x2ef84b['_previousStartingPointerTime']=_0x2ef84b['_startingPointerTime'],_0x2ef84b['_previousStartingPointerPosition']['x']=_0x2ef84b['_startingPointerPosition']['x'],_0x2ef84b['_previousStartingPointerPosition']['y']=_0x2ef84b['_startingPointerPosition']['y'],_0x2ef84b['_previousButtonPressed']=_0x4866fa,_0x284d15['ExclusiveDoubleClickMode']?(_0x2ef84b['_previousDelayedSimpleClickTimeout']&&clearTimeout(_0x2ef84b['_previousDelayedSimpleClickTimeout']),_0x2ef84b['_previousDelayedSimpleClickTimeout']=_0x2ef84b['_delayedSimpleClickTimeout'],_0x45d0fb(_0x40e67a,_0x2ef84b['_previousPickResult'])):_0x45d0fb(_0x40e67a,_0x2ef84b['_currentPickResult'])):(_0x2ef84b['_previousStartingPointerTime']=0x0,_0x2ef84b['_doubleClickOccured']=!0x0,_0x40e67a['doubleClick']=!0x0,_0x40e67a['ignore']=!0x1,_0x284d15['ExclusiveDoubleClickMode']&&_0x2ef84b['_previousDelayedSimpleClickTimeout']&&clearTimeout(_0x2ef84b['_previousDelayedSimpleClickTimeout']),_0x2ef84b['_previousDelayedSimpleClickTimeout']=_0x2ef84b['_delayedSimpleClickTimeout'],_0x45d0fb(_0x40e67a,_0x2ef84b['_currentPickResult'])),_0x260394=!0x0):(_0x2ef84b['_doubleClickOccured']=!0x1,_0x2ef84b['_previousStartingPointerTime']=_0x2ef84b['_startingPointerTime'],_0x2ef84b['_previousStartingPointerPosition']['x']=_0x2ef84b['_startingPointerPosition']['x'],_0x2ef84b['_previousStartingPointerPosition']['y']=_0x2ef84b['_startingPointerPosition']['y'],_0x2ef84b['_previousButtonPressed']=_0x4866fa));}}_0x260394||_0x45d0fb(_0x40e67a,_0x2ef84b['_currentPickResult']);},this['_onPointerMove']=function(_0x1ff352){if(void 0x0===_0x1ff352['pointerId']&&(_0x1ff352['pointerId']=0x0),_0x2ef84b['_updatePointerPosition'](_0x1ff352),!_0x2ef84b['_checkPrePointerObservable'](null,_0x1ff352,_0x1ff352['type']===_0x2ef84b['_wheelEventName']?_0x5e7526['a']['POINTERWHEEL']:_0x5e7526['a']['POINTERMOVE'])&&(_0x1898e9['cameraToUseForPointers']||_0x1898e9['activeCamera'])){_0x1898e9['pointerMovePredicate']||(_0x1898e9['pointerMovePredicate']=function(_0x280d24){return _0x280d24['isPickable']&&_0x280d24['isVisible']&&_0x280d24['isReady']()&&_0x280d24['isEnabled']()&&(_0x280d24['enablePointerMoveEvents']||_0x1898e9['constantlyUpdateMeshUnderPointer']||null!=_0x280d24['_getActionManagerForTrigger']())&&(!_0x1898e9['cameraToUseForPointers']||0x0!=(_0x1898e9['cameraToUseForPointers']['layerMask']&_0x280d24['layerMask']));});var _0xde95ed=_0x1898e9['pick'](_0x2ef84b['_unTranslatedPointerX'],_0x2ef84b['_unTranslatedPointerY'],_0x1898e9['pointerMovePredicate'],!0x1,_0x1898e9['cameraToUseForPointers']);_0x2ef84b['_processPointerMove'](_0xde95ed,_0x1ff352);}},this['_onPointerDown']=function(_0x39929e){if(_0x2ef84b['_totalPointersPressed']++,_0x2ef84b['_pickedDownMesh']=null,_0x2ef84b['_meshPickProceed']=!0x1,void 0x0===_0x39929e['pointerId']&&(_0x39929e['pointerId']=0x0),_0x2ef84b['_updatePointerPosition'](_0x39929e),_0x1898e9['preventDefaultOnPointerDown']&&_0x1e625f&&(_0x39929e['preventDefault'](),_0x1e625f['focus']()),_0x2ef84b['_startingPointerPosition']['x']=_0x2ef84b['_pointerX'],_0x2ef84b['_startingPointerPosition']['y']=_0x2ef84b['_pointerY'],_0x2ef84b['_startingPointerTime']=Date['now'](),!_0x2ef84b['_checkPrePointerObservable'](null,_0x39929e,_0x5e7526['a']['POINTERDOWN'])&&(_0x1898e9['cameraToUseForPointers']||_0x1898e9['activeCamera'])){_0x2ef84b['_pointerCaptures'][_0x39929e['pointerId']]=!0x0,_0x1898e9['pointerDownPredicate']||(_0x1898e9['pointerDownPredicate']=function(_0x20feb0){return _0x20feb0['isPickable']&&_0x20feb0['isVisible']&&_0x20feb0['isReady']()&&_0x20feb0['isEnabled']()&&(!_0x1898e9['cameraToUseForPointers']||0x0!=(_0x1898e9['cameraToUseForPointers']['layerMask']&_0x20feb0['layerMask']));}),_0x2ef84b['_pickedDownMesh']=null;var _0x44a0a7=_0x1898e9['pick'](_0x2ef84b['_unTranslatedPointerX'],_0x2ef84b['_unTranslatedPointerY'],_0x1898e9['pointerDownPredicate'],!0x1,_0x1898e9['cameraToUseForPointers']);_0x2ef84b['_processPointerDown'](_0x44a0a7,_0x39929e);}},this['_onPointerUp']=function(_0x393592){0x0!==_0x2ef84b['_totalPointersPressed']&&(_0x2ef84b['_totalPointersPressed']--,_0x2ef84b['_pickedUpMesh']=null,_0x2ef84b['_meshPickProceed']=!0x1,void 0x0===_0x393592['pointerId']&&(_0x393592['pointerId']=0x0),_0x2ef84b['_updatePointerPosition'](_0x393592),_0x1898e9['preventDefaultOnPointerUp']&&_0x1e625f&&(_0x393592['preventDefault'](),_0x1e625f['focus']()),_0x2ef84b['_initClickEvent'](_0x1898e9['onPrePointerObservable'],_0x1898e9['onPointerObservable'],_0x393592,function(_0x208969,_0x5cd6a8){if(_0x1898e9['onPrePointerObservable']['hasObservers']()&&!_0x208969['ignore']){if(!_0x208969['hasSwiped']){if(_0x208969['singleClick']&&_0x1898e9['onPrePointerObservable']['hasSpecificMask'](_0x5e7526['a']['POINTERTAP'])&&_0x2ef84b['_checkPrePointerObservable'](null,_0x393592,_0x5e7526['a']['POINTERTAP']))return;if(_0x208969['doubleClick']&&_0x1898e9['onPrePointerObservable']['hasSpecificMask'](_0x5e7526['a']['POINTERDOUBLETAP'])&&_0x2ef84b['_checkPrePointerObservable'](null,_0x393592,_0x5e7526['a']['POINTERDOUBLETAP']))return;}if(_0x2ef84b['_checkPrePointerObservable'](null,_0x393592,_0x5e7526['a']['POINTERUP']))return;}_0x2ef84b['_pointerCaptures'][_0x393592['pointerId']]&&(_0x2ef84b['_pointerCaptures'][_0x393592['pointerId']]=!0x1,(_0x1898e9['cameraToUseForPointers']||_0x1898e9['activeCamera'])&&(_0x1898e9['pointerUpPredicate']||(_0x1898e9['pointerUpPredicate']=function(_0x58db44){return _0x58db44['isPickable']&&_0x58db44['isVisible']&&_0x58db44['isReady']()&&_0x58db44['isEnabled']()&&(!_0x1898e9['cameraToUseForPointers']||0x0!=(_0x1898e9['cameraToUseForPointers']['layerMask']&_0x58db44['layerMask']));}),!_0x2ef84b['_meshPickProceed']&&(_0x2e609b['a']&&_0x2e609b['a']['HasTriggers']||_0x1898e9['onPointerObservable']['hasObservers']())&&_0x2ef84b['_initActionManager'](null,_0x208969),_0x5cd6a8||(_0x5cd6a8=_0x2ef84b['_currentPickResult']),_0x2ef84b['_processPointerUp'](_0x5cd6a8,_0x393592,_0x208969),_0x2ef84b['_previousPickResult']=_0x2ef84b['_currentPickResult']));}));},this['_onKeyDown']=function(_0x233635){var _0x1cd03b=_0x1030e6['a']['KEYDOWN'];if(_0x1898e9['onPreKeyboardObservable']['hasObservers']()){var _0x3049ae=new _0x1030e6['c'](_0x1cd03b,_0x233635);if(_0x1898e9['onPreKeyboardObservable']['notifyObservers'](_0x3049ae,_0x1cd03b),_0x3049ae['skipOnPointerObservable'])return;}_0x1898e9['onKeyboardObservable']['hasObservers']()&&(_0x3049ae=new _0x1030e6['b'](_0x1cd03b,_0x233635),_0x1898e9['onKeyboardObservable']['notifyObservers'](_0x3049ae,_0x1cd03b)),_0x1898e9['actionManager']&&_0x1898e9['actionManager']['processTrigger'](_0x244e90['a']['ACTION_OnKeyDownTrigger'],_0x3cad45['a']['CreateNewFromScene'](_0x1898e9,_0x233635));},this['_onKeyUp']=function(_0x48e85f){var _0xf3dae=_0x1030e6['a']['KEYUP'];if(_0x1898e9['onPreKeyboardObservable']['hasObservers']()){var _0xad6a24=new _0x1030e6['c'](_0xf3dae,_0x48e85f);if(_0x1898e9['onPreKeyboardObservable']['notifyObservers'](_0xad6a24,_0xf3dae),_0xad6a24['skipOnPointerObservable'])return;}_0x1898e9['onKeyboardObservable']['hasObservers']()&&(_0xad6a24=new _0x1030e6['b'](_0xf3dae,_0x48e85f),_0x1898e9['onKeyboardObservable']['notifyObservers'](_0xad6a24,_0xf3dae)),_0x1898e9['actionManager']&&_0x1898e9['actionManager']['processTrigger'](_0x244e90['a']['ACTION_OnKeyUpTrigger'],_0x3cad45['a']['CreateNewFromScene'](_0x1898e9,_0x48e85f));};var _0xf38be5=function(){_0x1e625f&&!_0x2ef84b['_keyboardIsAttached']&&(_0x1e625f['addEventListener']('keydown',_0x2ef84b['_onKeyDown'],!0x1),_0x1e625f['addEventListener']('keyup',_0x2ef84b['_onKeyUp'],!0x1),_0x2ef84b['_keyboardIsAttached']=!0x0);};this['_onCanvasFocusObserver']=_0x51b7ec['onCanvasFocusObservable']['add']((document['activeElement']===_0x1e625f&&_0xf38be5(),_0xf38be5)),this['_onCanvasBlurObserver']=_0x51b7ec['onCanvasBlurObservable']['add'](function(){_0x1e625f&&(_0x1e625f['removeEventListener']('keydown',_0x2ef84b['_onKeyDown']),_0x1e625f['removeEventListener']('keyup',_0x2ef84b['_onKeyUp']),_0x2ef84b['_keyboardIsAttached']=!0x1);}),_0xf38be5();var _0x4c6780=_0x31470f['b']['GetPointerPrefix'](_0x51b7ec);if(_0x2d2dda&&(_0x1e625f['addEventListener'](_0x4c6780+'move',this['_onPointerMove'],!0x1),this['_wheelEventName']='onwheel'in document['createElement']('div')?'wheel':void 0x0!==document['onmousewheel']?'mousewheel':'DOMMouseScroll',_0x1e625f['addEventListener'](this['_wheelEventName'],this['_onPointerMove'],!0x1)),_0x3252b9&&_0x1e625f['addEventListener'](_0x4c6780+'down',this['_onPointerDown'],!0x1),_0x17e44e){var _0x13dc93=_0x1898e9['getEngine']()['getHostWindow']();_0x13dc93&&_0x13dc93['addEventListener'](_0x4c6780+'up',this['_onPointerUp'],!0x1);}this['_alreadyAttached']=!0x0;}},_0x284d15['prototype']['detachControl']=function(){var _0x5782a7=this['_scene']['getEngine'](),_0x3b9146=_0x31470f['b']['GetPointerPrefix'](_0x5782a7);this['_alreadyAttachedTo']&&this['_alreadyAttached']&&(this['_alreadyAttachedTo']['removeEventListener'](_0x3b9146+'move',this['_onPointerMove']),this['_alreadyAttachedTo']['removeEventListener'](this['_wheelEventName'],this['_onPointerMove']),this['_alreadyAttachedTo']['removeEventListener'](_0x3b9146+'down',this['_onPointerDown']),window['removeEventListener'](_0x3b9146+'up',this['_onPointerUp']),this['_onCanvasBlurObserver']&&_0x5782a7['onCanvasBlurObservable']['remove'](this['_onCanvasBlurObserver']),this['_onCanvasFocusObserver']&&_0x5782a7['onCanvasFocusObservable']['remove'](this['_onCanvasFocusObserver']),this['_alreadyAttachedTo']['removeEventListener']('keydown',this['_onKeyDown']),this['_alreadyAttachedTo']['removeEventListener']('keyup',this['_onKeyUp']),this['_scene']['doNotHandleCursors']||(this['_alreadyAttachedTo']['style']['cursor']=this['_scene']['defaultCursor']),this['_alreadyAttached']=!0x1);},_0x284d15['prototype']['setPointerOverMesh']=function(_0xdce7dc,_0x1bfaee){if(void 0x0===_0x1bfaee&&(_0x1bfaee=0x0),_0x1bfaee<0x0&&(_0x1bfaee=0x0),this['_meshUnderPointerId'][_0x1bfaee]!==_0xdce7dc){var _0x1aeb36,_0x3c2333=this['_meshUnderPointerId'][_0x1bfaee];_0x3c2333&&(_0x1aeb36=_0x3c2333['_getActionManagerForTrigger'](_0x244e90['a']['ACTION_OnPointerOutTrigger']))&&_0x1aeb36['processTrigger'](_0x244e90['a']['ACTION_OnPointerOutTrigger'],_0x3cad45['a']['CreateNew'](_0x3c2333,void 0x0,{'pointerId':_0x1bfaee})),this['_meshUnderPointerId'][_0x1bfaee]=_0xdce7dc,this['_pointerOverMesh']=_0xdce7dc,(_0x3c2333=this['_meshUnderPointerId'][_0x1bfaee])&&(_0x1aeb36=_0x3c2333['_getActionManagerForTrigger'](_0x244e90['a']['ACTION_OnPointerOverTrigger']))&&_0x1aeb36['processTrigger'](_0x244e90['a']['ACTION_OnPointerOverTrigger'],_0x3cad45['a']['CreateNew'](_0x3c2333,void 0x0,{'pointerId':_0x1bfaee}));}},_0x284d15['prototype']['getPointerOverMesh']=function(){return this['_pointerOverMesh'];},_0x284d15['DragMovementThreshold']=0xa,_0x284d15['LongPressDelay']=0x1f4,_0x284d15['DoubleClickDelay']=0x12c,_0x284d15['ExclusiveDoubleClickMode']=!0x1,_0x284d15;}()),_0x4c66c0=_0xa776f7(0x37),_0x998230=_0xa776f7(0x9),_0x9e2e7f=_0xa776f7(0x5a),_0x2bb0c4=_0xa776f7(0x98),_0x2d59e0=_0xa776f7(0x38),_0x4e5557=function(_0x56878b){function _0x489b08(_0x3240c1,_0x36d7b7){var _0x20a5c2=_0x56878b['call'](this)||this;_0x20a5c2['_inputManager']=new _0x43d12f(_0x20a5c2),_0x20a5c2['cameraToUseForPointers']=null,_0x20a5c2['_isScene']=!0x0,_0x20a5c2['_blockEntityCollection']=!0x1,_0x20a5c2['autoClear']=!0x0,_0x20a5c2['autoClearDepthAndStencil']=!0x0,_0x20a5c2['clearColor']=new _0x998230['b'](0.2,0.2,0.3,0x1),_0x20a5c2['ambientColor']=new _0x998230['a'](0x0,0x0,0x0),_0x20a5c2['_environmentIntensity']=0x1,_0x20a5c2['_forceWireframe']=!0x1,_0x20a5c2['_skipFrustumClipping']=!0x1,_0x20a5c2['_forcePointsCloud']=!0x1,_0x20a5c2['animationsEnabled']=!0x0,_0x20a5c2['_animationPropertiesOverride']=null,_0x20a5c2['useConstantAnimationDeltaTime']=!0x1,_0x20a5c2['constantlyUpdateMeshUnderPointer']=!0x1,_0x20a5c2['hoverCursor']='pointer',_0x20a5c2['defaultCursor']='',_0x20a5c2['doNotHandleCursors']=!0x1,_0x20a5c2['preventDefaultOnPointerDown']=!0x0,_0x20a5c2['preventDefaultOnPointerUp']=!0x0,_0x20a5c2['metadata']=null,_0x20a5c2['reservedDataStore']=null,_0x20a5c2['disableOfflineSupportExceptionRules']=new Array(),_0x20a5c2['onDisposeObservable']=new _0x421b67['c'](),_0x20a5c2['_onDisposeObserver']=null,_0x20a5c2['onBeforeRenderObservable']=new _0x421b67['c'](),_0x20a5c2['_onBeforeRenderObserver']=null,_0x20a5c2['onAfterRenderObservable']=new _0x421b67['c'](),_0x20a5c2['onAfterRenderCameraObservable']=new _0x421b67['c'](),_0x20a5c2['_onAfterRenderObserver']=null,_0x20a5c2['onBeforeAnimationsObservable']=new _0x421b67['c'](),_0x20a5c2['onAfterAnimationsObservable']=new _0x421b67['c'](),_0x20a5c2['onBeforeDrawPhaseObservable']=new _0x421b67['c'](),_0x20a5c2['onAfterDrawPhaseObservable']=new _0x421b67['c'](),_0x20a5c2['onReadyObservable']=new _0x421b67['c'](),_0x20a5c2['onBeforeCameraRenderObservable']=new _0x421b67['c'](),_0x20a5c2['_onBeforeCameraRenderObserver']=null,_0x20a5c2['onAfterCameraRenderObservable']=new _0x421b67['c'](),_0x20a5c2['_onAfterCameraRenderObserver']=null,_0x20a5c2['onBeforeActiveMeshesEvaluationObservable']=new _0x421b67['c'](),_0x20a5c2['onAfterActiveMeshesEvaluationObservable']=new _0x421b67['c'](),_0x20a5c2['onBeforeParticlesRenderingObservable']=new _0x421b67['c'](),_0x20a5c2['onAfterParticlesRenderingObservable']=new _0x421b67['c'](),_0x20a5c2['onDataLoadedObservable']=new _0x421b67['c'](),_0x20a5c2['onNewCameraAddedObservable']=new _0x421b67['c'](),_0x20a5c2['onCameraRemovedObservable']=new _0x421b67['c'](),_0x20a5c2['onNewLightAddedObservable']=new _0x421b67['c'](),_0x20a5c2['onLightRemovedObservable']=new _0x421b67['c'](),_0x20a5c2['onNewGeometryAddedObservable']=new _0x421b67['c'](),_0x20a5c2['onGeometryRemovedObservable']=new _0x421b67['c'](),_0x20a5c2['onNewTransformNodeAddedObservable']=new _0x421b67['c'](),_0x20a5c2['onTransformNodeRemovedObservable']=new _0x421b67['c'](),_0x20a5c2['onNewMeshAddedObservable']=new _0x421b67['c'](),_0x20a5c2['onMeshRemovedObservable']=new _0x421b67['c'](),_0x20a5c2['onNewSkeletonAddedObservable']=new _0x421b67['c'](),_0x20a5c2['onSkeletonRemovedObservable']=new _0x421b67['c'](),_0x20a5c2['onNewMaterialAddedObservable']=new _0x421b67['c'](),_0x20a5c2['onNewMultiMaterialAddedObservable']=new _0x421b67['c'](),_0x20a5c2['onMaterialRemovedObservable']=new _0x421b67['c'](),_0x20a5c2['onMultiMaterialRemovedObservable']=new _0x421b67['c'](),_0x20a5c2['onNewTextureAddedObservable']=new _0x421b67['c'](),_0x20a5c2['onTextureRemovedObservable']=new _0x421b67['c'](),_0x20a5c2['onBeforeRenderTargetsRenderObservable']=new _0x421b67['c'](),_0x20a5c2['onAfterRenderTargetsRenderObservable']=new _0x421b67['c'](),_0x20a5c2['onBeforeStepObservable']=new _0x421b67['c'](),_0x20a5c2['onAfterStepObservable']=new _0x421b67['c'](),_0x20a5c2['onActiveCameraChanged']=new _0x421b67['c'](),_0x20a5c2['onBeforeRenderingGroupObservable']=new _0x421b67['c'](),_0x20a5c2['onAfterRenderingGroupObservable']=new _0x421b67['c'](),_0x20a5c2['onMeshImportedObservable']=new _0x421b67['c'](),_0x20a5c2['onAnimationFileImportedObservable']=new _0x421b67['c'](),_0x20a5c2['_registeredForLateAnimationBindings']=new _0x45e569['b'](0x100),_0x20a5c2['onPrePointerObservable']=new _0x421b67['c'](),_0x20a5c2['onPointerObservable']=new _0x421b67['c'](),_0x20a5c2['onPreKeyboardObservable']=new _0x421b67['c'](),_0x20a5c2['onKeyboardObservable']=new _0x421b67['c'](),_0x20a5c2['_useRightHandedSystem']=!0x1,_0x20a5c2['_timeAccumulator']=0x0,_0x20a5c2['_currentStepId']=0x0,_0x20a5c2['_currentInternalStep']=0x0,_0x20a5c2['_fogEnabled']=!0x0,_0x20a5c2['_fogMode']=_0x489b08['FOGMODE_NONE'],_0x20a5c2['fogColor']=new _0x998230['a'](0.2,0.2,0.3),_0x20a5c2['fogDensity']=0.1,_0x20a5c2['fogStart']=0x0,_0x20a5c2['fogEnd']=0x3e8,_0x20a5c2['prePass']=!0x1,_0x20a5c2['_shadowsEnabled']=!0x0,_0x20a5c2['_lightsEnabled']=!0x0,_0x20a5c2['activeCameras']=new Array(),_0x20a5c2['_texturesEnabled']=!0x0,_0x20a5c2['physicsEnabled']=!0x0,_0x20a5c2['particlesEnabled']=!0x0,_0x20a5c2['spritesEnabled']=!0x0,_0x20a5c2['_skeletonsEnabled']=!0x0,_0x20a5c2['lensFlaresEnabled']=!0x0,_0x20a5c2['collisionsEnabled']=!0x0,_0x20a5c2['gravity']=new _0x40b8e8['e'](0x0,-9.807,0x0),_0x20a5c2['postProcessesEnabled']=!0x0,_0x20a5c2['renderTargetsEnabled']=!0x0,_0x20a5c2['dumpNextRenderTargets']=!0x1,_0x20a5c2['customRenderTargets']=new Array(),_0x20a5c2['importedMeshesFiles']=new Array(),_0x20a5c2['probesEnabled']=!0x0,_0x20a5c2['_meshesForIntersections']=new _0x45e569['b'](0x100),_0x20a5c2['proceduralTexturesEnabled']=!0x0,_0x20a5c2['_totalVertices']=new _0x4c66c0['a'](),_0x20a5c2['_activeIndices']=new _0x4c66c0['a'](),_0x20a5c2['_activeParticles']=new _0x4c66c0['a'](),_0x20a5c2['_activeBones']=new _0x4c66c0['a'](),_0x20a5c2['_animationTime']=0x0,_0x20a5c2['animationTimeScale']=0x1,_0x20a5c2['_renderId']=0x0,_0x20a5c2['_frameId']=0x0,_0x20a5c2['_executeWhenReadyTimeoutId']=-0x1,_0x20a5c2['_intermediateRendering']=!0x1,_0x20a5c2['_viewUpdateFlag']=-0x1,_0x20a5c2['_projectionUpdateFlag']=-0x1,_0x20a5c2['_toBeDisposed']=new Array(0x100),_0x20a5c2['_activeRequests']=new Array(),_0x20a5c2['_pendingData']=new Array(),_0x20a5c2['_isDisposed']=!0x1,_0x20a5c2['dispatchAllSubMeshesOfActiveMeshes']=!0x1,_0x20a5c2['_activeMeshes']=new _0x45e569['a'](0x100),_0x20a5c2['_processedMaterials']=new _0x45e569['a'](0x100),_0x20a5c2['_renderTargets']=new _0x45e569['b'](0x100),_0x20a5c2['_activeParticleSystems']=new _0x45e569['a'](0x100),_0x20a5c2['_activeSkeletons']=new _0x45e569['b'](0x20),_0x20a5c2['_softwareSkinnedMeshes']=new _0x45e569['b'](0x20),_0x20a5c2['_activeAnimatables']=new Array(),_0x20a5c2['_transformMatrix']=_0x40b8e8['a']['Zero'](),_0x20a5c2['requireLightSorting']=!0x1,_0x20a5c2['_components']=[],_0x20a5c2['_serializableComponents']=[],_0x20a5c2['_transientComponents']=[],_0x20a5c2['_beforeCameraUpdateStage']=_0x36a3e0['b']['Create'](),_0x20a5c2['_beforeClearStage']=_0x36a3e0['b']['Create'](),_0x20a5c2['_gatherRenderTargetsStage']=_0x36a3e0['b']['Create'](),_0x20a5c2['_gatherActiveCameraRenderTargetsStage']=_0x36a3e0['b']['Create'](),_0x20a5c2['_isReadyForMeshStage']=_0x36a3e0['b']['Create'](),_0x20a5c2['_beforeEvaluateActiveMeshStage']=_0x36a3e0['b']['Create'](),_0x20a5c2['_evaluateSubMeshStage']=_0x36a3e0['b']['Create'](),_0x20a5c2['_preActiveMeshStage']=_0x36a3e0['b']['Create'](),_0x20a5c2['_cameraDrawRenderTargetStage']=_0x36a3e0['b']['Create'](),_0x20a5c2['_beforeCameraDrawStage']=_0x36a3e0['b']['Create'](),_0x20a5c2['_beforeRenderTargetDrawStage']=_0x36a3e0['b']['Create'](),_0x20a5c2['_beforeRenderingGroupDrawStage']=_0x36a3e0['b']['Create'](),_0x20a5c2['_beforeRenderingMeshStage']=_0x36a3e0['b']['Create'](),_0x20a5c2['_afterRenderingMeshStage']=_0x36a3e0['b']['Create'](),_0x20a5c2['_afterRenderingGroupDrawStage']=_0x36a3e0['b']['Create'](),_0x20a5c2['_afterCameraDrawStage']=_0x36a3e0['b']['Create'](),_0x20a5c2['_afterRenderTargetDrawStage']=_0x36a3e0['b']['Create'](),_0x20a5c2['_afterRenderStage']=_0x36a3e0['b']['Create'](),_0x20a5c2['_pointerMoveStage']=_0x36a3e0['b']['Create'](),_0x20a5c2['_pointerDownStage']=_0x36a3e0['b']['Create'](),_0x20a5c2['_pointerUpStage']=_0x36a3e0['b']['Create'](),_0x20a5c2['geometriesByUniqueId']=null,_0x20a5c2['_defaultMeshCandidates']={'data':[],'length':0x0},_0x20a5c2['_defaultSubMeshCandidates']={'data':[],'length':0x0},_0x20a5c2['_preventFreeActiveMeshesAndRenderingGroups']=!0x1,_0x20a5c2['_activeMeshesFrozen']=!0x1,_0x20a5c2['_skipEvaluateActiveMeshesCompletely']=!0x1,_0x20a5c2['_allowPostProcessClearColor']=!0x0,_0x20a5c2['getDeterministicFrameTime']=function(){return _0x20a5c2['_engine']['getTimeStep']();},_0x20a5c2['_blockMaterialDirtyMechanism']=!0x1;var _0x45a5c3=Object(_0x4613a4['a'])({'useGeometryUniqueIdsMap':!0x0,'useMaterialMeshMap':!0x0,'useClonedMeshMap':!0x0,'virtual':!0x1},_0x36d7b7);return _0x20a5c2['_engine']=_0x3240c1||_0x56f721['a']['LastCreatedEngine'],_0x45a5c3['virtual']||(_0x56f721['a']['_LastCreatedScene']=_0x20a5c2,_0x20a5c2['_engine']['scenes']['push'](_0x20a5c2)),_0x20a5c2['_uid']=null,_0x20a5c2['_renderingManager']=new _0x18f8a0['b'](_0x20a5c2),_0x7242fe['a']&&(_0x20a5c2['postProcessManager']=new _0x7242fe['a'](_0x20a5c2)),_0x4492f2['a']['IsWindowObjectExist']()&&_0x20a5c2['attachControl'](),_0x20a5c2['_createUbo'](),_0x5e6591['a']&&(_0x20a5c2['_imageProcessingConfiguration']=new _0x5e6591['a']()),_0x20a5c2['setDefaultCandidateProviders'](),_0x45a5c3['useGeometryUniqueIdsMap']&&(_0x20a5c2['geometriesByUniqueId']={}),_0x20a5c2['useMaterialMeshMap']=_0x45a5c3['useMaterialMeshMap'],_0x20a5c2['useClonedMeshMap']=_0x45a5c3['useClonedMeshMap'],_0x36d7b7&&_0x36d7b7['virtual']||_0x20a5c2['_engine']['onNewSceneAddedObservable']['notifyObservers'](_0x20a5c2),_0x20a5c2;}return Object(_0x4613a4['d'])(_0x489b08,_0x56878b),_0x489b08['DefaultMaterialFactory']=function(_0x11c66c){throw _0x2b0777['a']['WarnImport']('StandardMaterial');},_0x489b08['CollisionCoordinatorFactory']=function(){throw _0x2b0777['a']['WarnImport']('DefaultCollisionCoordinator');},Object['defineProperty'](_0x489b08['prototype'],'environmentTexture',{'get':function(){return this['_environmentTexture'];},'set':function(_0x4f9ab4){this['_environmentTexture']!==_0x4f9ab4&&(this['_environmentTexture']=_0x4f9ab4,this['markAllMaterialsAsDirty'](_0x244e90['a']['MATERIAL_TextureDirtyFlag']));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'environmentIntensity',{'get':function(){return this['_environmentIntensity'];},'set':function(_0x148559){this['_environmentIntensity']!==_0x148559&&(this['_environmentIntensity']=_0x148559,this['markAllMaterialsAsDirty'](_0x244e90['a']['MATERIAL_TextureDirtyFlag']));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'imageProcessingConfiguration',{'get':function(){return this['_imageProcessingConfiguration'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'forceWireframe',{'get':function(){return this['_forceWireframe'];},'set':function(_0x39fe44){this['_forceWireframe']!==_0x39fe44&&(this['_forceWireframe']=_0x39fe44,this['markAllMaterialsAsDirty'](_0x244e90['a']['MATERIAL_MiscDirtyFlag']));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'skipFrustumClipping',{'get':function(){return this['_skipFrustumClipping'];},'set':function(_0x378d39){this['_skipFrustumClipping']!==_0x378d39&&(this['_skipFrustumClipping']=_0x378d39);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'forcePointsCloud',{'get':function(){return this['_forcePointsCloud'];},'set':function(_0x1c4476){this['_forcePointsCloud']!==_0x1c4476&&(this['_forcePointsCloud']=_0x1c4476,this['markAllMaterialsAsDirty'](_0x244e90['a']['MATERIAL_MiscDirtyFlag']));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'animationPropertiesOverride',{'get':function(){return this['_animationPropertiesOverride'];},'set':function(_0x31ab3f){this['_animationPropertiesOverride']=_0x31ab3f;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'onDispose',{'set':function(_0x166a6d){this['_onDisposeObserver']&&this['onDisposeObservable']['remove'](this['_onDisposeObserver']),this['_onDisposeObserver']=this['onDisposeObservable']['add'](_0x166a6d);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'beforeRender',{'set':function(_0x23fb9d){this['_onBeforeRenderObserver']&&this['onBeforeRenderObservable']['remove'](this['_onBeforeRenderObserver']),_0x23fb9d&&(this['_onBeforeRenderObserver']=this['onBeforeRenderObservable']['add'](_0x23fb9d));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'afterRender',{'set':function(_0x453062){this['_onAfterRenderObserver']&&this['onAfterRenderObservable']['remove'](this['_onAfterRenderObserver']),_0x453062&&(this['_onAfterRenderObserver']=this['onAfterRenderObservable']['add'](_0x453062));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'beforeCameraRender',{'set':function(_0x32a5c4){this['_onBeforeCameraRenderObserver']&&this['onBeforeCameraRenderObservable']['remove'](this['_onBeforeCameraRenderObserver']),this['_onBeforeCameraRenderObserver']=this['onBeforeCameraRenderObservable']['add'](_0x32a5c4);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'afterCameraRender',{'set':function(_0x14ae1b){this['_onAfterCameraRenderObserver']&&this['onAfterCameraRenderObservable']['remove'](this['_onAfterCameraRenderObserver']),this['_onAfterCameraRenderObserver']=this['onAfterCameraRenderObservable']['add'](_0x14ae1b);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'unTranslatedPointer',{'get':function(){return this['_inputManager']['unTranslatedPointer'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08,'DragMovementThreshold',{'get':function(){return _0x43d12f['DragMovementThreshold'];},'set':function(_0x7aa500){_0x43d12f['DragMovementThreshold']=_0x7aa500;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08,'LongPressDelay',{'get':function(){return _0x43d12f['LongPressDelay'];},'set':function(_0x4db432){_0x43d12f['LongPressDelay']=_0x4db432;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08,'DoubleClickDelay',{'get':function(){return _0x43d12f['DoubleClickDelay'];},'set':function(_0x3cdd52){_0x43d12f['DoubleClickDelay']=_0x3cdd52;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08,'ExclusiveDoubleClickMode',{'get':function(){return _0x43d12f['ExclusiveDoubleClickMode'];},'set':function(_0x5b3bbb){_0x43d12f['ExclusiveDoubleClickMode']=_0x5b3bbb;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'useRightHandedSystem',{'get':function(){return this['_useRightHandedSystem'];},'set':function(_0x546e1c){this['_useRightHandedSystem']!==_0x546e1c&&(this['_useRightHandedSystem']=_0x546e1c,this['markAllMaterialsAsDirty'](_0x244e90['a']['MATERIAL_MiscDirtyFlag']));},'enumerable':!0x1,'configurable':!0x0}),_0x489b08['prototype']['setStepId']=function(_0x2cf3db){this['_currentStepId']=_0x2cf3db;},_0x489b08['prototype']['getStepId']=function(){return this['_currentStepId'];},_0x489b08['prototype']['getInternalStep']=function(){return this['_currentInternalStep'];},Object['defineProperty'](_0x489b08['prototype'],'fogEnabled',{'get':function(){return this['_fogEnabled'];},'set':function(_0x527acf){this['_fogEnabled']!==_0x527acf&&(this['_fogEnabled']=_0x527acf,this['markAllMaterialsAsDirty'](_0x244e90['a']['MATERIAL_MiscDirtyFlag']));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'fogMode',{'get':function(){return this['_fogMode'];},'set':function(_0xd48493){this['_fogMode']!==_0xd48493&&(this['_fogMode']=_0xd48493,this['markAllMaterialsAsDirty'](_0x244e90['a']['MATERIAL_MiscDirtyFlag']));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'shadowsEnabled',{'get':function(){return this['_shadowsEnabled'];},'set':function(_0x2263bf){this['_shadowsEnabled']!==_0x2263bf&&(this['_shadowsEnabled']=_0x2263bf,this['markAllMaterialsAsDirty'](_0x244e90['a']['MATERIAL_LightDirtyFlag']));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'lightsEnabled',{'get':function(){return this['_lightsEnabled'];},'set':function(_0x3b2eca){this['_lightsEnabled']!==_0x3b2eca&&(this['_lightsEnabled']=_0x3b2eca,this['markAllMaterialsAsDirty'](_0x244e90['a']['MATERIAL_LightDirtyFlag']));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'activeCamera',{'get':function(){return this['_activeCamera'];},'set':function(_0x35a42f){_0x35a42f!==this['_activeCamera']&&(this['_activeCamera']=_0x35a42f,this['onActiveCameraChanged']['notifyObservers'](this));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'defaultMaterial',{'get':function(){return this['_defaultMaterial']||(this['_defaultMaterial']=_0x489b08['DefaultMaterialFactory'](this)),this['_defaultMaterial'];},'set':function(_0x2c430b){this['_defaultMaterial']=_0x2c430b;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'texturesEnabled',{'get':function(){return this['_texturesEnabled'];},'set':function(_0x1b6c27){this['_texturesEnabled']!==_0x1b6c27&&(this['_texturesEnabled']=_0x1b6c27,this['markAllMaterialsAsDirty'](_0x244e90['a']['MATERIAL_TextureDirtyFlag']));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'skeletonsEnabled',{'get':function(){return this['_skeletonsEnabled'];},'set':function(_0x2eaf32){this['_skeletonsEnabled']!==_0x2eaf32&&(this['_skeletonsEnabled']=_0x2eaf32,this['markAllMaterialsAsDirty'](_0x244e90['a']['MATERIAL_AttributesDirtyFlag']));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'collisionCoordinator',{'get':function(){return this['_collisionCoordinator']||(this['_collisionCoordinator']=_0x489b08['CollisionCoordinatorFactory'](),this['_collisionCoordinator']['init'](this)),this['_collisionCoordinator'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'frustumPlanes',{'get':function(){return this['_frustumPlanes'];},'enumerable':!0x1,'configurable':!0x0}),_0x489b08['prototype']['_registerTransientComponents']=function(){if(this['_transientComponents']['length']>0x0){for(var _0x25297b=0x0,_0x12573f=this['_transientComponents'];_0x25297b<_0x12573f['length'];_0x25297b++){_0x12573f[_0x25297b]['register']();}this['_transientComponents']=[];}},_0x489b08['prototype']['_addComponent']=function(_0x2a0cbb){this['_components']['push'](_0x2a0cbb),this['_transientComponents']['push'](_0x2a0cbb);var _0x151a64=_0x2a0cbb;_0x151a64['addFromContainer']&&_0x151a64['serialize']&&this['_serializableComponents']['push'](_0x151a64);},_0x489b08['prototype']['_getComponent']=function(_0x5c65ba){for(var _0x5ed634=0x0,_0x2d94e2=this['_components'];_0x5ed634<_0x2d94e2['length'];_0x5ed634++){var _0x27c29d=_0x2d94e2[_0x5ed634];if(_0x27c29d['name']===_0x5c65ba)return _0x27c29d;}return null;},_0x489b08['prototype']['getClassName']=function(){return'Scene';},_0x489b08['prototype']['_getDefaultMeshCandidates']=function(){return this['_defaultMeshCandidates']['data']=this['meshes'],this['_defaultMeshCandidates']['length']=this['meshes']['length'],this['_defaultMeshCandidates'];},_0x489b08['prototype']['_getDefaultSubMeshCandidates']=function(_0x411750){return this['_defaultSubMeshCandidates']['data']=_0x411750['subMeshes'],this['_defaultSubMeshCandidates']['length']=_0x411750['subMeshes']['length'],this['_defaultSubMeshCandidates'];},_0x489b08['prototype']['setDefaultCandidateProviders']=function(){this['getActiveMeshCandidates']=this['_getDefaultMeshCandidates']['bind'](this),this['getActiveSubMeshCandidates']=this['_getDefaultSubMeshCandidates']['bind'](this),this['getIntersectingSubMeshCandidates']=this['_getDefaultSubMeshCandidates']['bind'](this),this['getCollidingSubMeshCandidates']=this['_getDefaultSubMeshCandidates']['bind'](this);},Object['defineProperty'](_0x489b08['prototype'],'meshUnderPointer',{'get':function(){return this['_inputManager']['meshUnderPointer'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'pointerX',{'get':function(){return this['_inputManager']['pointerX'];},'set':function(_0x178a33){this['_inputManager']['pointerX']=_0x178a33;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x489b08['prototype'],'pointerY',{'get':function(){return this['_inputManager']['pointerY'];},'set':function(_0x4eb08c){this['_inputManager']['pointerY']=_0x4eb08c;},'enumerable':!0x1,'configurable':!0x0}),_0x489b08['prototype']['getCachedMaterial']=function(){return this['_cachedMaterial'];},_0x489b08['prototype']['getCachedEffect']=function(){return this['_cachedEffect'];},_0x489b08['prototype']['getCachedVisibility']=function(){return this['_cachedVisibility'];},_0x489b08['prototype']['isCachedMaterialInvalid']=function(_0x45b62d,_0xb7ebd3,_0x23753f){return void 0x0===_0x23753f&&(_0x23753f=0x1),this['_cachedEffect']!==_0xb7ebd3||this['_cachedMaterial']!==_0x45b62d||this['_cachedVisibility']!==_0x23753f;},_0x489b08['prototype']['getEngine']=function(){return this['_engine'];},_0x489b08['prototype']['getTotalVertices']=function(){return this['_totalVertices']['current'];},Object['defineProperty'](_0x489b08['prototype'],'totalVerticesPerfCounter',{'get':function(){return this['_totalVertices'];},'enumerable':!0x1,'configurable':!0x0}),_0x489b08['prototype']['getActiveIndices']=function(){return this['_activeIndices']['current'];},Object['defineProperty'](_0x489b08['prototype'],'totalActiveIndicesPerfCounter',{'get':function(){return this['_activeIndices'];},'enumerable':!0x1,'configurable':!0x0}),_0x489b08['prototype']['getActiveParticles']=function(){return this['_activeParticles']['current'];},Object['defineProperty'](_0x489b08['prototype'],'activeParticlesPerfCounter',{'get':function(){return this['_activeParticles'];},'enumerable':!0x1,'configurable':!0x0}),_0x489b08['prototype']['getActiveBones']=function(){return this['_activeBones']['current'];},Object['defineProperty'](_0x489b08['prototype'],'activeBonesPerfCounter',{'get':function(){return this['_activeBones'];},'enumerable':!0x1,'configurable':!0x0}),_0x489b08['prototype']['getActiveMeshes']=function(){return this['_activeMeshes'];},_0x489b08['prototype']['getAnimationRatio']=function(){return void 0x0!==this['_animationRatio']?this['_animationRatio']:0x1;},_0x489b08['prototype']['getRenderId']=function(){return this['_renderId'];},_0x489b08['prototype']['getFrameId']=function(){return this['_frameId'];},_0x489b08['prototype']['incrementRenderId']=function(){this['_renderId']++;},_0x489b08['prototype']['_createUbo']=function(){this['_sceneUbo']=new _0x49f34d['a'](this['_engine'],void 0x0,!0x0),this['_sceneUbo']['addUniform']('viewProjection',0x10),this['_sceneUbo']['addUniform']('view',0x10);},_0x489b08['prototype']['simulatePointerMove']=function(_0x193a9e,_0x3f6611){return this['_inputManager']['simulatePointerMove'](_0x193a9e,_0x3f6611),this;},_0x489b08['prototype']['simulatePointerDown']=function(_0x2026de,_0x2e579b){return this['_inputManager']['simulatePointerDown'](_0x2026de,_0x2e579b),this;},_0x489b08['prototype']['simulatePointerUp']=function(_0x39d2c2,_0xb0cfe0,_0x29e6b3){return this['_inputManager']['simulatePointerUp'](_0x39d2c2,_0xb0cfe0,_0x29e6b3),this;},_0x489b08['prototype']['isPointerCaptured']=function(_0x22cdf8){return void 0x0===_0x22cdf8&&(_0x22cdf8=0x0),this['_inputManager']['isPointerCaptured'](_0x22cdf8);},_0x489b08['prototype']['attachControl']=function(_0x35573c,_0x2a8af1,_0x1b9973){void 0x0===_0x35573c&&(_0x35573c=!0x0),void 0x0===_0x2a8af1&&(_0x2a8af1=!0x0),void 0x0===_0x1b9973&&(_0x1b9973=!0x0),this['_inputManager']['attachControl'](_0x35573c,_0x2a8af1,_0x1b9973);},_0x489b08['prototype']['detachControl']=function(){this['_inputManager']['detachControl']();},_0x489b08['prototype']['isReady']=function(){if(this['_isDisposed'])return!0x1;var _0x57ed84,_0x3f62d6=this['getEngine']();if(!_0x3f62d6['areAllEffectsReady']())return!0x1;if(this['_pendingData']['length']>0x0)return!0x1;for(_0x57ed84=0x0;_0x57ed840x0,_0x303648=0x0,_0x2b4ba6=this['_isReadyForMeshStage'];_0x303648<_0x2b4ba6['length'];_0x303648++){if(!_0x2b4ba6[_0x303648]['action'](_0x2c6863,_0x529c0f))return!0x1;}}}for(_0x57ed84=0x0;_0x57ed840x0)for(var _0x11e00f=0x0,_0x2b2196=this['activeCameras'];_0x11e00f<_0x2b2196['length'];_0x11e00f++){if(!_0x2b2196[_0x11e00f]['isReady'](!0x0))return!0x1;}else{if(this['activeCamera']&&!this['activeCamera']['isReady'](!0x0))return!0x1;}for(var _0x2b7c0e=0x0,_0x1fcd3a=this['particleSystems'];_0x2b7c0e<_0x1fcd3a['length'];_0x2b7c0e++){if(!_0x1fcd3a[_0x2b7c0e]['isReady']())return!0x1;}return!0x0;},_0x489b08['prototype']['resetCachedMaterial']=function(){this['_cachedMaterial']=null,this['_cachedEffect']=null,this['_cachedVisibility']=null;},_0x489b08['prototype']['registerBeforeRender']=function(_0x38a1bc){this['onBeforeRenderObservable']['add'](_0x38a1bc);},_0x489b08['prototype']['unregisterBeforeRender']=function(_0x39696e){this['onBeforeRenderObservable']['removeCallback'](_0x39696e);},_0x489b08['prototype']['registerAfterRender']=function(_0x2c8e2f){this['onAfterRenderObservable']['add'](_0x2c8e2f);},_0x489b08['prototype']['unregisterAfterRender']=function(_0x4e840a){this['onAfterRenderObservable']['removeCallback'](_0x4e840a);},_0x489b08['prototype']['_executeOnceBeforeRender']=function(_0x26fe0b){var _0x396af7=this,_0xbd764c=function(){_0x26fe0b(),setTimeout(function(){_0x396af7['unregisterBeforeRender'](_0xbd764c);});};this['registerBeforeRender'](_0xbd764c);},_0x489b08['prototype']['executeOnceBeforeRender']=function(_0x3c3509,_0xd6673c){var _0x1f1a90=this;void 0x0!==_0xd6673c?setTimeout(function(){_0x1f1a90['_executeOnceBeforeRender'](_0x3c3509);},_0xd6673c):this['_executeOnceBeforeRender'](_0x3c3509);},_0x489b08['prototype']['_addPendingData']=function(_0x1ef55e){this['_pendingData']['push'](_0x1ef55e);},_0x489b08['prototype']['_removePendingData']=function(_0x2dbb87){var _0x12ff1c=this['isLoading'],_0x26d541=this['_pendingData']['indexOf'](_0x2dbb87);-0x1!==_0x26d541&&this['_pendingData']['splice'](_0x26d541,0x1),_0x12ff1c&&!this['isLoading']&&this['onDataLoadedObservable']['notifyObservers'](this);},_0x489b08['prototype']['getWaitingItemsCount']=function(){return this['_pendingData']['length'];},Object['defineProperty'](_0x489b08['prototype'],'isLoading',{'get':function(){return this['_pendingData']['length']>0x0;},'enumerable':!0x1,'configurable':!0x0}),_0x489b08['prototype']['executeWhenReady']=function(_0x31a83f){var _0x565200=this;this['onReadyObservable']['add'](_0x31a83f),-0x1===this['_executeWhenReadyTimeoutId']&&(this['_executeWhenReadyTimeoutId']=setTimeout(function(){_0x565200['_checkIsReady']();},0x96));},_0x489b08['prototype']['whenReadyAsync']=function(){var _0xc35e0f=this;return new Promise(function(_0x2c18e6){_0xc35e0f['executeWhenReady'](function(){_0x2c18e6();});});},_0x489b08['prototype']['_checkIsReady']=function(){var _0x2527f4=this;return this['_registerTransientComponents'](),this['isReady']()?(this['onReadyObservable']['notifyObservers'](this),this['onReadyObservable']['clear'](),void(this['_executeWhenReadyTimeoutId']=-0x1)):this['_isDisposed']?(this['onReadyObservable']['clear'](),void(this['_executeWhenReadyTimeoutId']=-0x1)):void(this['_executeWhenReadyTimeoutId']=setTimeout(function(){_0x2527f4['_checkIsReady']();},0x96));},Object['defineProperty'](_0x489b08['prototype'],'animatables',{'get':function(){return this['_activeAnimatables'];},'enumerable':!0x1,'configurable':!0x0}),_0x489b08['prototype']['resetLastAnimationTimeFrame']=function(){this['_animationTimeLast']=_0x2af79d['a']['Now'];},_0x489b08['prototype']['getViewMatrix']=function(){return this['_viewMatrix'];},_0x489b08['prototype']['getProjectionMatrix']=function(){return this['_projectionMatrix'];},_0x489b08['prototype']['getTransformMatrix']=function(){return this['_transformMatrix'];},_0x489b08['prototype']['setTransformMatrix']=function(_0x565235,_0x84aaa2,_0x2bda04,_0x1d1cdc){this['_viewUpdateFlag']===_0x565235['updateFlag']&&this['_projectionUpdateFlag']===_0x84aaa2['updateFlag']||(this['_viewUpdateFlag']=_0x565235['updateFlag'],this['_projectionUpdateFlag']=_0x84aaa2['updateFlag'],this['_viewMatrix']=_0x565235,this['_projectionMatrix']=_0x84aaa2,this['_viewMatrix']['multiplyToRef'](this['_projectionMatrix'],this['_transformMatrix']),this['_frustumPlanes']?_0x9e2e7f['a']['GetPlanesToRef'](this['_transformMatrix'],this['_frustumPlanes']):this['_frustumPlanes']=_0x9e2e7f['a']['GetPlanes'](this['_transformMatrix']),this['_multiviewSceneUbo']&&this['_multiviewSceneUbo']['useUbo']?this['_updateMultiviewUbo'](_0x2bda04,_0x1d1cdc):this['_sceneUbo']['useUbo']&&(this['_sceneUbo']['updateMatrix']('viewProjection',this['_transformMatrix']),this['_sceneUbo']['updateMatrix']('view',this['_viewMatrix']),this['_sceneUbo']['update']()));},_0x489b08['prototype']['getSceneUniformBuffer']=function(){return this['_multiviewSceneUbo']?this['_multiviewSceneUbo']:this['_sceneUbo'];},_0x489b08['prototype']['getUniqueId']=function(){return _0x2bb0c4['a']['UniqueId'];},_0x489b08['prototype']['addMesh']=function(_0x194d2d,_0x1465b7){var _0xb8905a=this;void 0x0===_0x1465b7&&(_0x1465b7=!0x1),this['_blockEntityCollection']||(this['meshes']['push'](_0x194d2d),_0x194d2d['_resyncLightSources'](),_0x194d2d['parent']||_0x194d2d['_addToSceneRootNodes'](),this['onNewMeshAddedObservable']['notifyObservers'](_0x194d2d),_0x1465b7&&_0x194d2d['getChildMeshes']()['forEach'](function(_0x303385){_0xb8905a['addMesh'](_0x303385);}));},_0x489b08['prototype']['removeMesh']=function(_0x9218fe,_0x88bf3e){var _0x53623e=this;void 0x0===_0x88bf3e&&(_0x88bf3e=!0x1);var _0x402b96=this['meshes']['indexOf'](_0x9218fe);return-0x1!==_0x402b96&&(this['meshes'][_0x402b96]=this['meshes'][this['meshes']['length']-0x1],this['meshes']['pop'](),_0x9218fe['parent']||_0x9218fe['_removeFromSceneRootNodes']()),this['onMeshRemovedObservable']['notifyObservers'](_0x9218fe),_0x88bf3e&&_0x9218fe['getChildMeshes']()['forEach'](function(_0x15ef0b){_0x53623e['removeMesh'](_0x15ef0b);}),_0x402b96;},_0x489b08['prototype']['addTransformNode']=function(_0x466e99){this['_blockEntityCollection']||(_0x466e99['_indexInSceneTransformNodesArray']=this['transformNodes']['length'],this['transformNodes']['push'](_0x466e99),_0x466e99['parent']||_0x466e99['_addToSceneRootNodes'](),this['onNewTransformNodeAddedObservable']['notifyObservers'](_0x466e99));},_0x489b08['prototype']['removeTransformNode']=function(_0x439fce){var _0x549e86=_0x439fce['_indexInSceneTransformNodesArray'];if(-0x1!==_0x549e86){if(_0x549e86!==this['transformNodes']['length']-0x1){var _0x1970e9=this['transformNodes'][this['transformNodes']['length']-0x1];this['transformNodes'][_0x549e86]=_0x1970e9,_0x1970e9['_indexInSceneTransformNodesArray']=_0x549e86;}_0x439fce['_indexInSceneTransformNodesArray']=-0x1,this['transformNodes']['pop'](),_0x439fce['parent']||_0x439fce['_removeFromSceneRootNodes']();}return this['onTransformNodeRemovedObservable']['notifyObservers'](_0x439fce),_0x549e86;},_0x489b08['prototype']['removeSkeleton']=function(_0x204eb7){var _0x1f4319=this['skeletons']['indexOf'](_0x204eb7);return-0x1!==_0x1f4319&&(this['skeletons']['splice'](_0x1f4319,0x1),this['onSkeletonRemovedObservable']['notifyObservers'](_0x204eb7)),_0x1f4319;},_0x489b08['prototype']['removeMorphTargetManager']=function(_0x16cd3a){var _0x5b83da=this['morphTargetManagers']['indexOf'](_0x16cd3a);return-0x1!==_0x5b83da&&this['morphTargetManagers']['splice'](_0x5b83da,0x1),_0x5b83da;},_0x489b08['prototype']['removeLight']=function(_0x50b24e){var _0x10ac5f=this['lights']['indexOf'](_0x50b24e);if(-0x1!==_0x10ac5f){for(var _0x5bbb01=0x0,_0xd60f22=this['meshes'];_0x5bbb01<_0xd60f22['length'];_0x5bbb01++){_0xd60f22[_0x5bbb01]['_removeLightSource'](_0x50b24e,!0x1);}this['lights']['splice'](_0x10ac5f,0x1),this['sortLightsByPriority'](),_0x50b24e['parent']||_0x50b24e['_removeFromSceneRootNodes']();}return this['onLightRemovedObservable']['notifyObservers'](_0x50b24e),_0x10ac5f;},_0x489b08['prototype']['removeCamera']=function(_0x32781f){var _0x3a4d89=this['cameras']['indexOf'](_0x32781f);if(-0x1!==_0x3a4d89&&(this['cameras']['splice'](_0x3a4d89,0x1),_0x32781f['parent']||_0x32781f['_removeFromSceneRootNodes']()),this['activeCameras']){var _0xf4f24e=this['activeCameras']['indexOf'](_0x32781f);-0x1!==_0xf4f24e&&this['activeCameras']['splice'](_0xf4f24e,0x1);}return this['activeCamera']===_0x32781f&&(this['cameras']['length']>0x0?this['activeCamera']=this['cameras'][0x0]:this['activeCamera']=null),this['onCameraRemovedObservable']['notifyObservers'](_0x32781f),_0x3a4d89;},_0x489b08['prototype']['removeParticleSystem']=function(_0x28de64){var _0x4af670=this['particleSystems']['indexOf'](_0x28de64);return-0x1!==_0x4af670&&this['particleSystems']['splice'](_0x4af670,0x1),_0x4af670;},_0x489b08['prototype']['removeAnimation']=function(_0x15f5aa){var _0x22e583=this['animations']['indexOf'](_0x15f5aa);return-0x1!==_0x22e583&&this['animations']['splice'](_0x22e583,0x1),_0x22e583;},_0x489b08['prototype']['stopAnimation']=function(_0x3e1d5e,_0x2d2c3a,_0x16eb75){},_0x489b08['prototype']['removeAnimationGroup']=function(_0x219e5b){var _0x50bc50=this['animationGroups']['indexOf'](_0x219e5b);return-0x1!==_0x50bc50&&this['animationGroups']['splice'](_0x50bc50,0x1),_0x50bc50;},_0x489b08['prototype']['removeMultiMaterial']=function(_0x1dbddc){var _0x847e27=this['multiMaterials']['indexOf'](_0x1dbddc);return-0x1!==_0x847e27&&this['multiMaterials']['splice'](_0x847e27,0x1),this['onMultiMaterialRemovedObservable']['notifyObservers'](_0x1dbddc),_0x847e27;},_0x489b08['prototype']['removeMaterial']=function(_0x18b3ee){var _0x5635ac=_0x18b3ee['_indexInSceneMaterialArray'];if(-0x1!==_0x5635ac&&_0x5635ac=0x0;_0x3669ef--)if(this['materials'][_0x3669ef]['id']===_0x268eaf)return this['materials'][_0x3669ef];return null;},_0x489b08['prototype']['getMaterialByName']=function(_0x3dc166){for(var _0x22f581=0x0;_0x22f581=0x0;_0x2c62c8--)if(this['meshes'][_0x2c62c8]['id']===_0x492cef)return this['meshes'][_0x2c62c8];return null;},_0x489b08['prototype']['getLastEntryByID']=function(_0x350db8){var _0xd8a678;for(_0xd8a678=this['meshes']['length']-0x1;_0xd8a678>=0x0;_0xd8a678--)if(this['meshes'][_0xd8a678]['id']===_0x350db8)return this['meshes'][_0xd8a678];for(_0xd8a678=this['transformNodes']['length']-0x1;_0xd8a678>=0x0;_0xd8a678--)if(this['transformNodes'][_0xd8a678]['id']===_0x350db8)return this['transformNodes'][_0xd8a678];for(_0xd8a678=this['cameras']['length']-0x1;_0xd8a678>=0x0;_0xd8a678--)if(this['cameras'][_0xd8a678]['id']===_0x350db8)return this['cameras'][_0xd8a678];for(_0xd8a678=this['lights']['length']-0x1;_0xd8a678>=0x0;_0xd8a678--)if(this['lights'][_0xd8a678]['id']===_0x350db8)return this['lights'][_0xd8a678];return null;},_0x489b08['prototype']['getNodeByID']=function(_0x55e5bc){var _0xa6b887=this['getMeshByID'](_0x55e5bc);if(_0xa6b887)return _0xa6b887;var _0x18224e=this['getTransformNodeByID'](_0x55e5bc);if(_0x18224e)return _0x18224e;var _0x139c8d=this['getLightByID'](_0x55e5bc);if(_0x139c8d)return _0x139c8d;var _0xf32bc6=this['getCameraByID'](_0x55e5bc);if(_0xf32bc6)return _0xf32bc6;var _0x22a949=this['getBoneByID'](_0x55e5bc);return _0x22a949||null;},_0x489b08['prototype']['getNodeByName']=function(_0x54e2a8){var _0x6ad3fe=this['getMeshByName'](_0x54e2a8);if(_0x6ad3fe)return _0x6ad3fe;var _0x57462c=this['getTransformNodeByName'](_0x54e2a8);if(_0x57462c)return _0x57462c;var _0x251917=this['getLightByName'](_0x54e2a8);if(_0x251917)return _0x251917;var _0x5f12e3=this['getCameraByName'](_0x54e2a8);if(_0x5f12e3)return _0x5f12e3;var _0x29e75b=this['getBoneByName'](_0x54e2a8);return _0x29e75b||null;},_0x489b08['prototype']['getMeshByName']=function(_0x31960a){for(var _0x1424d6=0x0;_0x1424d6=0x0;_0x2aa8f9--)if(this['skeletons'][_0x2aa8f9]['id']===_0x34010d)return this['skeletons'][_0x2aa8f9];return null;},_0x489b08['prototype']['getSkeletonByUniqueId']=function(_0x5ea215){for(var _0xb62575=0x0;_0xb625750x0&&0x0!=(_0x2cfed3['layerMask']&this['activeCamera']['layerMask'])&&(this['_skipFrustumClipping']||_0x2cfed3['alwaysSelectAsActiveMesh']||_0x2cfed3['isInFrustum'](this['_frustumPlanes'])))){this['_activeMeshes']['push'](_0x2cfed3),this['activeCamera']['_activeMeshes']['push'](_0x2cfed3),_0x5929bb!==_0x2cfed3&&_0x5929bb['_activate'](this['_renderId'],!0x1);for(var _0x3ba87d=0x0,_0x5b8a4d=this['_preActiveMeshStage'];_0x3ba87d<_0x5b8a4d['length'];_0x3ba87d++){_0x5b8a4d[_0x3ba87d]['action'](_0x2cfed3);}_0x2cfed3['_activate'](this['_renderId'],!0x1)&&(_0x2cfed3['isAnInstance']?_0x2cfed3['_internalAbstractMeshDataInfo']['_actAsRegularMesh']&&(_0x5929bb=_0x2cfed3):_0x5929bb['_internalAbstractMeshDataInfo']['_onlyForInstances']=!0x1,_0x5929bb['_internalAbstractMeshDataInfo']['_isActive']=!0x0,this['_activeMesh'](_0x2cfed3,_0x5929bb)),_0x2cfed3['_postActivate']();}}}if(this['onAfterActiveMeshesEvaluationObservable']['notifyObservers'](this),this['particlesEnabled']){this['onBeforeParticlesRenderingObservable']['notifyObservers'](this);for(var _0x57f617=0x0;_0x57f6170x0)for(var _0x1bd7a0=this['getActiveSubMeshCandidates'](_0x4679ff),_0x308a29=_0x1bd7a0['length'],_0x8eaf34=0x0;_0x8eaf34<_0x308a29;_0x8eaf34++){var _0xbfe8c1=_0x1bd7a0['data'][_0x8eaf34];this['_evaluateSubMesh'](_0xbfe8c1,_0x4679ff,_0x3e0b6c);}},_0x489b08['prototype']['updateTransformMatrix']=function(_0x4bcee5){this['activeCamera']&&this['setTransformMatrix'](this['activeCamera']['getViewMatrix'](),this['activeCamera']['getProjectionMatrix'](_0x4bcee5));},_0x489b08['prototype']['_bindFrameBuffer']=function(){if(this['activeCamera']&&this['activeCamera']['_multiviewTexture'])this['activeCamera']['_multiviewTexture']['_bindFrameBuffer']();else{if(this['activeCamera']&&this['activeCamera']['outputRenderTarget']){if(this['getEngine']()['getCaps']()['multiview']&&this['activeCamera']['outputRenderTarget']&&this['activeCamera']['outputRenderTarget']['getViewCount']()>0x1)this['activeCamera']['outputRenderTarget']['_bindFrameBuffer']();else{var _0x19a322=this['activeCamera']['outputRenderTarget']['getInternalTexture']();_0x19a322?this['getEngine']()['bindFramebuffer'](_0x19a322):_0x3cf74c['a']['Error']('Camera\x20contains\x20invalid\x20customDefaultRenderTarget');}}else this['getEngine']()['restoreDefaultFramebuffer']();}},_0x489b08['prototype']['_renderForCamera']=function(_0x39a728,_0x351b02){if(!_0x39a728||!_0x39a728['_skipRendering']){var _0x58ed87=this['_engine'];if(this['_activeCamera']=_0x39a728,!this['activeCamera'])throw new Error('Active\x20camera\x20not\x20set');_0x58ed87['setViewport'](this['activeCamera']['viewport']),this['resetCachedMaterial'](),this['_renderId']++,this['getEngine']()['getCaps']()['multiview']&&_0x39a728['outputRenderTarget']&&_0x39a728['outputRenderTarget']['getViewCount']()>0x1?this['setTransformMatrix'](_0x39a728['_rigCameras'][0x0]['getViewMatrix'](),_0x39a728['_rigCameras'][0x0]['getProjectionMatrix'](),_0x39a728['_rigCameras'][0x1]['getViewMatrix'](),_0x39a728['_rigCameras'][0x1]['getProjectionMatrix']()):this['updateTransformMatrix'](),this['onBeforeCameraRenderObservable']['notifyObservers'](this['activeCamera']),this['_evaluateActiveMeshes']();for(var _0x57d7b5=0x0;_0x57d7b50x0&&this['_renderTargets']['concatWithNoDuplicate'](_0x39a728['customRenderTargets']),_0x351b02&&_0x351b02['customRenderTargets']&&_0x351b02['customRenderTargets']['length']>0x0&&this['_renderTargets']['concatWithNoDuplicate'](_0x351b02['customRenderTargets']);for(var _0x1ea2e8=0x0,_0x5ef897=this['_gatherActiveCameraRenderTargetsStage'];_0x1ea2e8<_0x5ef897['length'];_0x1ea2e8++){_0x5ef897[_0x1ea2e8]['action'](this['_renderTargets']);}var _0x4e0d7c=!0x1;if(this['renderTargetsEnabled']){if(this['_intermediateRendering']=!0x0,this['_renderTargets']['length']>0x0){_0x31470f['b']['StartPerformanceCounter']('Render\x20targets',this['_renderTargets']['length']>0x0);for(var _0x1c881b=0x0;_0x1c881b0x0),this['_renderId']++;}for(var _0x4dc95e=0x0,_0x57c312=this['_cameraDrawRenderTargetStage'];_0x4dc95e<_0x57c312['length'];_0x4dc95e++){_0x4e0d7c=_0x57c312[_0x4dc95e]['action'](this['activeCamera'])||_0x4e0d7c;}this['_intermediateRendering']=!0x1,this['activeCamera']&&this['activeCamera']['outputRenderTarget']&&(_0x4e0d7c=!0x0);}_0x4e0d7c&&!this['prePass']&&this['_bindFrameBuffer'](),this['onAfterRenderTargetsRenderObservable']['notifyObservers'](this),!this['postProcessManager']||_0x39a728['_multiviewTexture']||this['prePass']||this['postProcessManager']['_prepareFrame']();for(var _0x2cff64=0x0,_0xf6268a=this['_beforeCameraDrawStage'];_0x2cff64<_0xf6268a['length'];_0x2cff64++){_0xf6268a[_0x2cff64]['action'](this['activeCamera']);}this['onBeforeDrawPhaseObservable']['notifyObservers'](this),this['_renderingManager']['render'](null,null,!0x0,!0x0),this['onAfterDrawPhaseObservable']['notifyObservers'](this);for(var _0x27fe15=0x0,_0x477b5f=this['_afterCameraDrawStage'];_0x27fe15<_0x477b5f['length'];_0x27fe15++){_0x477b5f[_0x27fe15]['action'](this['activeCamera']);}if(this['postProcessManager']&&!_0x39a728['_multiviewTexture']){var _0x4dc9ad=_0x39a728['outputRenderTarget']?_0x39a728['outputRenderTarget']['getInternalTexture']():void 0x0;this['postProcessManager']['_finalizeFrame'](_0x39a728['isIntermediate'],_0x4dc9ad);}this['_renderTargets']['reset'](),this['onAfterCameraRenderObservable']['notifyObservers'](this['activeCamera']);}},_0x489b08['prototype']['_processSubCameras']=function(_0x15a795){if(_0x15a795['cameraRigMode']===_0x39925e['a']['RIG_MODE_NONE']||_0x15a795['outputRenderTarget']&&_0x15a795['outputRenderTarget']['getViewCount']()>0x1&&this['getEngine']()['getCaps']()['multiview'])return this['_renderForCamera'](_0x15a795),void this['onAfterRenderCameraObservable']['notifyObservers'](_0x15a795);if(_0x15a795['_useMultiviewToSingleView'])this['_renderMultiviewToSingleView'](_0x15a795);else{for(var _0x44ebf9=0x0;_0x44ebf9<_0x15a795['_rigCameras']['length'];_0x44ebf9++)this['_renderForCamera'](_0x15a795['_rigCameras'][_0x44ebf9],_0x15a795);}this['_activeCamera']=_0x15a795,this['setTransformMatrix'](this['_activeCamera']['getViewMatrix'](),this['_activeCamera']['getProjectionMatrix']()),this['onAfterRenderCameraObservable']['notifyObservers'](_0x15a795);},_0x489b08['prototype']['_checkIntersections']=function(){for(var _0x7aad7f=0x0;_0x7aad7f-0x1&&(_0x5dbfff['trigger']===_0x244e90['a']['ACTION_OnIntersectionExitTrigger']&&_0x5dbfff['_executeCurrent'](_0x3cad45['a']['CreateNew'](_0x2e94b1,void 0x0,_0x3240ca)),_0x2e94b1['actionManager']['hasSpecificTrigger'](_0x244e90['a']['ACTION_OnIntersectionExitTrigger'],function(_0x52d621){var _0x5b05e1=_0x52d621 instanceof _0x4d4567['a']?_0x52d621:_0x52d621['mesh'];return _0x3240ca===_0x5b05e1;})&&_0x5dbfff['trigger']!==_0x244e90['a']['ACTION_OnIntersectionExitTrigger']||_0x2e94b1['_intersectionsInProgress']['splice'](_0x511bfc,0x1));}}}},_0x489b08['prototype']['_advancePhysicsEngineStep']=function(_0x1ef923){},_0x489b08['prototype']['_animate']=function(){},_0x489b08['prototype']['animate']=function(){if(this['_engine']['isDeterministicLockStep']()){var _0xc4e2cd=Math['max'](_0x489b08['MinDeltaTime'],Math['min'](this['_engine']['getDeltaTime'](),_0x489b08['MaxDeltaTime']))+this['_timeAccumulator'],_0x4500c5=this['_engine']['getTimeStep'](),_0x549aee=0x3e8/_0x4500c5/0x3e8,_0xf29a8a=0x0,_0x1b815a=this['_engine']['getLockstepMaxSteps'](),_0x4b0542=Math['floor'](_0xc4e2cd/_0x4500c5);for(_0x4b0542=Math['min'](_0x4b0542,_0x1b815a);_0xc4e2cd>0x0&&_0xf29a8a<_0x4b0542;)this['onBeforeStepObservable']['notifyObservers'](this),this['_animationRatio']=_0x4500c5*_0x549aee,this['_animate'](),this['onAfterAnimationsObservable']['notifyObservers'](this),this['physicsEnabled']&&this['_advancePhysicsEngineStep'](_0x4500c5),this['onAfterStepObservable']['notifyObservers'](this),this['_currentStepId']++,_0xf29a8a++,_0xc4e2cd-=_0x4500c5;this['_timeAccumulator']=_0xc4e2cd<0x0?0x0:_0xc4e2cd;}else _0xc4e2cd=this['useConstantAnimationDeltaTime']?0x10:Math['max'](_0x489b08['MinDeltaTime'],Math['min'](this['_engine']['getDeltaTime'](),_0x489b08['MaxDeltaTime'])),(this['_animationRatio']=0.06*_0xc4e2cd,this['_animate'](),this['onAfterAnimationsObservable']['notifyObservers'](this),this['physicsEnabled']&&this['_advancePhysicsEngineStep'](_0xc4e2cd));},_0x489b08['prototype']['render']=function(_0x3e5a35,_0xba424e){if(void 0x0===_0x3e5a35&&(_0x3e5a35=!0x0),void 0x0===_0xba424e&&(_0xba424e=!0x1),!this['isDisposed']){this['onReadyObservable']['hasObservers']()&&-0x1===this['_executeWhenReadyTimeoutId']&&this['_checkIsReady'](),this['_frameId']++,this['_registerTransientComponents'](),this['_activeParticles']['fetchNewFrame'](),this['_totalVertices']['fetchNewFrame'](),this['_activeIndices']['fetchNewFrame'](),this['_activeBones']['fetchNewFrame'](),this['_meshesForIntersections']['reset'](),this['resetCachedMaterial'](),this['onBeforeAnimationsObservable']['notifyObservers'](this),this['actionManager']&&this['actionManager']['processTrigger'](_0x244e90['a']['ACTION_OnEveryFrameTrigger']),_0xba424e||this['animate']();for(var _0x51e276=0x0,_0x28c35c=this['_beforeCameraUpdateStage'];_0x51e276<_0x28c35c['length'];_0x51e276++){_0x28c35c[_0x51e276]['action']();}if(_0x3e5a35){if(this['activeCameras']&&this['activeCameras']['length']>0x0)for(var _0x18fdb4=0x0;_0x18fdb40x0),this['_intermediateRendering']=!0x0;for(var _0xa2bf13=0x0;_0xa2bf130x0),this['_intermediateRendering']=!0x1,this['_renderId']++;}this['activeCamera']=_0x158061,this['_activeCamera']&&this['_activeCamera']['cameraRigMode']!==_0x39925e['a']['RIG_MODE_CUSTOM']&&!this['prePass']&&this['_bindFrameBuffer'](),this['onAfterRenderTargetsRenderObservable']['notifyObservers'](this);for(var _0x460433=0x0,_0x200e74=this['_beforeClearStage'];_0x460433<_0x200e74['length'];_0x460433++){_0x200e74[_0x460433]['action']();}!this['autoClearDepthAndStencil']&&!this['autoClear']||this['prePass']||this['_engine']['clear'](this['clearColor'],this['autoClear']||this['forceWireframe']||this['forcePointsCloud'],this['autoClearDepthAndStencil'],this['autoClearDepthAndStencil']);for(var _0x33a905=0x0,_0x57c1e3=this['_gatherRenderTargetsStage'];_0x33a905<_0x57c1e3['length'];_0x33a905++){_0x57c1e3[_0x33a905]['action'](this['_renderTargets']);}if(this['activeCameras']&&this['activeCameras']['length']>0x0){for(_0x18fdb4=0x0;_0x18fdb40x0&&this['_engine']['clear'](null,!0x1,!0x0,!0x0),this['_processSubCameras'](this['activeCameras'][_0x18fdb4]);}else{if(!this['activeCamera'])throw new Error('No\x20camera\x20defined');this['_processSubCameras'](this['activeCamera']);}this['_checkIntersections']();for(var _0x461f89=0x0,_0x330805=this['_afterRenderStage'];_0x461f89<_0x330805['length'];_0x461f89++){_0x330805[_0x461f89]['action']();}if(this['afterRender']&&this['afterRender'](),this['onAfterRenderObservable']['notifyObservers'](this),this['_toBeDisposed']['length']){for(_0x3cc5e5=0x0;_0x3cc5e5-0x1&&this['_engine']['scenes']['splice'](_0x3e0b25,0x1),this['_engine']['wipeCaches'](!0x0),this['_isDisposed']=!0x0;},Object['defineProperty'](_0x489b08['prototype'],'isDisposed',{'get':function(){return this['_isDisposed'];},'enumerable':!0x1,'configurable':!0x0}),_0x489b08['prototype']['clearCachedVertexData']=function(){for(var _0x82c45f=0x0;_0x82c45f-0x1?(_0x270c3c['a']['Error']('You\x27re\x20trying\x20to\x20reuse\x20a\x20post\x20process\x20not\x20defined\x20as\x20reusable.'),0x0):(null==_0x5e6ef9||_0x5e6ef9<0x0?this['_postProcesses']['push'](_0x3def94):null===this['_postProcesses'][_0x5e6ef9]?this['_postProcesses'][_0x5e6ef9]=_0x3def94:this['_postProcesses']['splice'](_0x5e6ef9,0x0,_0x3def94),this['_cascadePostProcessesToRigCams'](),this['_scene']['prePassRenderer']&&this['_scene']['prePassRenderer']['markAsDirty'](),this['_postProcesses']['indexOf'](_0x3def94));},_0x215b69['prototype']['detachPostProcess']=function(_0x1201ed){var _0x5825d5=this['_postProcesses']['indexOf'](_0x1201ed);-0x1!==_0x5825d5&&(this['_postProcesses'][_0x5825d5]=null),this['_scene']['prePassRenderer']&&this['_scene']['prePassRenderer']['markAsDirty'](),this['_cascadePostProcessesToRigCams']();},_0x215b69['prototype']['getWorldMatrix']=function(){return this['_isSynchronizedViewMatrix']()||this['getViewMatrix'](),this['_worldMatrix'];},_0x215b69['prototype']['_getViewMatrix']=function(){return _0x1e7fe8['a']['Identity']();},_0x215b69['prototype']['getViewMatrix']=function(_0x4e6044){return!_0x4e6044&&this['_isSynchronizedViewMatrix']()||(this['updateCache'](),this['_computedViewMatrix']=this['_getViewMatrix'](),this['_currentRenderId']=this['getScene']()['getRenderId'](),this['_childUpdateId']++,this['_refreshFrustumPlanes']=!0x0,this['_cameraRigParams']&&this['_cameraRigParams']['vrPreViewMatrix']&&this['_computedViewMatrix']['multiplyToRef'](this['_cameraRigParams']['vrPreViewMatrix'],this['_computedViewMatrix']),this['parent']&&this['parent']['onViewMatrixChangedObservable']&&this['parent']['onViewMatrixChangedObservable']['notifyObservers'](this['parent']),this['onViewMatrixChangedObservable']['notifyObservers'](this),this['_computedViewMatrix']['invertToRef'](this['_worldMatrix'])),this['_computedViewMatrix'];},_0x215b69['prototype']['freezeProjectionMatrix']=function(_0x4a8c20){this['_doNotComputeProjectionMatrix']=!0x0,void 0x0!==_0x4a8c20&&(this['_projectionMatrix']=_0x4a8c20);},_0x215b69['prototype']['unfreezeProjectionMatrix']=function(){this['_doNotComputeProjectionMatrix']=!0x1;},_0x215b69['prototype']['getProjectionMatrix']=function(_0x461cc9){var _0x262075,_0xe2773e,_0x41d6d3,_0x3a1fa4,_0x34681a,_0xb98ade,_0x54ce12,_0x271501;if(this['_doNotComputeProjectionMatrix']||!_0x461cc9&&this['_isSynchronizedProjectionMatrix']())return this['_projectionMatrix'];this['_cache']['mode']=this['mode'],this['_cache']['minZ']=this['minZ'],this['_cache']['maxZ']=this['maxZ'],this['_refreshFrustumPlanes']=!0x0;var _0x388a89=this['getEngine'](),_0x5ecdea=this['getScene']();if(this['mode']===_0x215b69['PERSPECTIVE_CAMERA']){this['_cache']['fov']=this['fov'],this['_cache']['fovMode']=this['fovMode'],this['_cache']['aspectRatio']=_0x388a89['getAspectRatio'](this),this['minZ']<=0x0&&(this['minZ']=0.1);var _0x512171=_0x388a89['useReverseDepthBuffer'];(_0x5ecdea['useRightHandedSystem']?_0x512171?_0x1e7fe8['a']['PerspectiveFovReverseRHToRef']:_0x1e7fe8['a']['PerspectiveFovRHToRef']:_0x512171?_0x1e7fe8['a']['PerspectiveFovReverseLHToRef']:_0x1e7fe8['a']['PerspectiveFovLHToRef'])(this['fov'],_0x388a89['getAspectRatio'](this),this['minZ'],this['maxZ'],this['_projectionMatrix'],this['fovMode']===_0x215b69['FOVMODE_VERTICAL_FIXED']);}else{var _0x339898=_0x388a89['getRenderWidth']()/0x2,_0x40a1e1=_0x388a89['getRenderHeight']()/0x2;_0x5ecdea['useRightHandedSystem']?_0x1e7fe8['a']['OrthoOffCenterRHToRef'](null!==(_0x262075=this['orthoLeft'])&&void 0x0!==_0x262075?_0x262075:-_0x339898,null!==(_0xe2773e=this['orthoRight'])&&void 0x0!==_0xe2773e?_0xe2773e:_0x339898,null!==(_0x41d6d3=this['orthoBottom'])&&void 0x0!==_0x41d6d3?_0x41d6d3:-_0x40a1e1,null!==(_0x3a1fa4=this['orthoTop'])&&void 0x0!==_0x3a1fa4?_0x3a1fa4:_0x40a1e1,this['minZ'],this['maxZ'],this['_projectionMatrix']):_0x1e7fe8['a']['OrthoOffCenterLHToRef'](null!==(_0x34681a=this['orthoLeft'])&&void 0x0!==_0x34681a?_0x34681a:-_0x339898,null!==(_0xb98ade=this['orthoRight'])&&void 0x0!==_0xb98ade?_0xb98ade:_0x339898,null!==(_0x54ce12=this['orthoBottom'])&&void 0x0!==_0x54ce12?_0x54ce12:-_0x40a1e1,null!==(_0x271501=this['orthoTop'])&&void 0x0!==_0x271501?_0x271501:_0x40a1e1,this['minZ'],this['maxZ'],this['_projectionMatrix']),this['_cache']['orthoLeft']=this['orthoLeft'],this['_cache']['orthoRight']=this['orthoRight'],this['_cache']['orthoBottom']=this['orthoBottom'],this['_cache']['orthoTop']=this['orthoTop'],this['_cache']['renderWidth']=_0x388a89['getRenderWidth'](),this['_cache']['renderHeight']=_0x388a89['getRenderHeight']();}return this['onProjectionMatrixChangedObservable']['notifyObservers'](this),this['_projectionMatrix'];},_0x215b69['prototype']['getTransformationMatrix']=function(){return this['_computedViewMatrix']['multiplyToRef'](this['_projectionMatrix'],this['_transformMatrix']),this['_transformMatrix'];},_0x215b69['prototype']['_updateFrustumPlanes']=function(){this['_refreshFrustumPlanes']&&(this['getTransformationMatrix'](),this['_frustumPlanes']?_0x2af540['a']['GetPlanesToRef'](this['_transformMatrix'],this['_frustumPlanes']):this['_frustumPlanes']=_0x2af540['a']['GetPlanes'](this['_transformMatrix']),this['_refreshFrustumPlanes']=!0x1);},_0x215b69['prototype']['isInFrustum']=function(_0x11ee11,_0x5d6737){if(void 0x0===_0x5d6737&&(_0x5d6737=!0x1),this['_updateFrustumPlanes'](),_0x5d6737&&this['rigCameras']['length']>0x0){var _0x12670e=!0x1;return this['rigCameras']['forEach'](function(_0x450e9e){_0x450e9e['_updateFrustumPlanes'](),_0x12670e=_0x12670e||_0x11ee11['isInFrustum'](_0x450e9e['_frustumPlanes']);}),_0x12670e;}return _0x11ee11['isInFrustum'](this['_frustumPlanes']);},_0x215b69['prototype']['isCompletelyInFrustum']=function(_0x42c166){return this['_updateFrustumPlanes'](),_0x42c166['isCompletelyInFrustum'](this['_frustumPlanes']);},_0x215b69['prototype']['getForwardRay']=function(_0x3fd8d2,_0x93ab72,_0x4482bf){throw void 0x0===_0x3fd8d2&&(_0x3fd8d2=0x64),_0x457f43['a']['WarnImport']('Ray');},_0x215b69['prototype']['getForwardRayToRef']=function(_0x2298e0,_0x54772e,_0x83c82e,_0x3297bf){throw void 0x0===_0x54772e&&(_0x54772e=0x64),_0x457f43['a']['WarnImport']('Ray');},_0x215b69['prototype']['dispose']=function(_0x134c94,_0x469693){for(void 0x0===_0x469693&&(_0x469693=!0x1),this['onViewMatrixChangedObservable']['clear'](),this['onProjectionMatrixChangedObservable']['clear'](),this['onAfterCheckInputsObservable']['clear'](),this['onRestoreStateObservable']['clear'](),this['inputs']&&this['inputs']['clear'](),this['getScene']()['stopAnimation'](this),this['getScene']()['removeCamera'](this);this['_rigCameras']['length']>0x0;){var _0x5c5bd7=this['_rigCameras']['pop']();_0x5c5bd7&&_0x5c5bd7['dispose']();}if(this['_rigPostProcess'])this['_rigPostProcess']['dispose'](this),this['_rigPostProcess']=null,this['_postProcesses']=[];else{if(this['cameraRigMode']!==_0x215b69['RIG_MODE_NONE'])this['_rigPostProcess']=null,this['_postProcesses']=[];else for(var _0x4c4cc9=this['_postProcesses']['length'];--_0x4c4cc9>=0x0;){var _0x35ec36=this['_postProcesses'][_0x4c4cc9];_0x35ec36&&_0x35ec36['dispose'](this);}}for(_0x4c4cc9=this['customRenderTargets']['length'];--_0x4c4cc9>=0x0;)this['customRenderTargets'][_0x4c4cc9]['dispose']();this['customRenderTargets']=[],this['_activeMeshes']['dispose'](),_0x576beb['prototype']['dispose']['call'](this,_0x134c94,_0x469693);},Object['defineProperty'](_0x215b69['prototype'],'isLeftCamera',{'get':function(){return this['_isLeftCamera'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x215b69['prototype'],'isRightCamera',{'get':function(){return this['_isRightCamera'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x215b69['prototype'],'leftCamera',{'get':function(){return this['_rigCameras']['length']<0x1?null:this['_rigCameras'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x215b69['prototype'],'rightCamera',{'get':function(){return this['_rigCameras']['length']<0x2?null:this['_rigCameras'][0x1];},'enumerable':!0x1,'configurable':!0x0}),_0x215b69['prototype']['getLeftTarget']=function(){return this['_rigCameras']['length']<0x1?null:this['_rigCameras'][0x0]['getTarget']();},_0x215b69['prototype']['getRightTarget']=function(){return this['_rigCameras']['length']<0x2?null:this['_rigCameras'][0x1]['getTarget']();},_0x215b69['prototype']['setCameraRigMode']=function(_0x239c30,_0x3130be){if(this['cameraRigMode']!==_0x239c30){for(;this['_rigCameras']['length']>0x0;){var _0x3946b2=this['_rigCameras']['pop']();_0x3946b2&&_0x3946b2['dispose']();}if(this['cameraRigMode']=_0x239c30,this['_cameraRigParams']={},this['_cameraRigParams']['interaxialDistance']=_0x3130be['interaxialDistance']||0.0637,this['_cameraRigParams']['stereoHalfAngle']=_0x547738['b']['ToRadians'](this['_cameraRigParams']['interaxialDistance']/0.0637),this['cameraRigMode']!==_0x215b69['RIG_MODE_NONE']){var _0x557ef3=this['createRigCamera'](this['name']+'_L',0x0);_0x557ef3&&(_0x557ef3['_isLeftCamera']=!0x0);var _0x426c93=this['createRigCamera'](this['name']+'_R',0x1);_0x426c93&&(_0x426c93['_isRightCamera']=!0x0),_0x557ef3&&_0x426c93&&(this['_rigCameras']['push'](_0x557ef3),this['_rigCameras']['push'](_0x426c93));}switch(this['cameraRigMode']){case _0x215b69['RIG_MODE_STEREOSCOPIC_ANAGLYPH']:_0x215b69['_setStereoscopicAnaglyphRigMode'](this);break;case _0x215b69['RIG_MODE_STEREOSCOPIC_SIDEBYSIDE_PARALLEL']:case _0x215b69['RIG_MODE_STEREOSCOPIC_SIDEBYSIDE_CROSSEYED']:case _0x215b69['RIG_MODE_STEREOSCOPIC_OVERUNDER']:case _0x215b69['RIG_MODE_STEREOSCOPIC_INTERLACED']:_0x215b69['_setStereoscopicRigMode'](this);break;case _0x215b69['RIG_MODE_VR']:_0x215b69['_setVRRigMode'](this,_0x3130be);break;case _0x215b69['RIG_MODE_WEBVR']:_0x215b69['_setWebVRRigMode'](this,_0x3130be);}this['_cascadePostProcessesToRigCams'](),this['update']();}},_0x215b69['_setStereoscopicRigMode']=function(_0x2d6a39){throw'Import\x20Cameras/RigModes/stereoscopicRigMode\x20before\x20using\x20stereoscopic\x20rig\x20mode';},_0x215b69['_setStereoscopicAnaglyphRigMode']=function(_0x280a4e){throw'Import\x20Cameras/RigModes/stereoscopicAnaglyphRigMode\x20before\x20using\x20stereoscopic\x20anaglyph\x20rig\x20mode';},_0x215b69['_setVRRigMode']=function(_0x41b231,_0x1c65cd){throw'Import\x20Cameras/RigModes/vrRigMode\x20before\x20using\x20VR\x20rig\x20mode';},_0x215b69['_setWebVRRigMode']=function(_0x375618,_0x3d354c){throw'Import\x20Cameras/RigModes/WebVRRigMode\x20before\x20using\x20Web\x20VR\x20rig\x20mode';},_0x215b69['prototype']['_getVRProjectionMatrix']=function(){return _0x1e7fe8['a']['PerspectiveFovLHToRef'](this['_cameraRigParams']['vrMetrics']['aspectRatioFov'],this['_cameraRigParams']['vrMetrics']['aspectRatio'],this['minZ'],this['maxZ'],this['_cameraRigParams']['vrWorkMatrix']),this['_cameraRigParams']['vrWorkMatrix']['multiplyToRef'](this['_cameraRigParams']['vrHMatrix'],this['_projectionMatrix']),this['_projectionMatrix'];},_0x215b69['prototype']['_updateCameraRotationMatrix']=function(){},_0x215b69['prototype']['_updateWebVRCameraRotationMatrix']=function(){},_0x215b69['prototype']['_getWebVRProjectionMatrix']=function(){return _0x1e7fe8['a']['Identity']();},_0x215b69['prototype']['_getWebVRViewMatrix']=function(){return _0x1e7fe8['a']['Identity']();},_0x215b69['prototype']['setCameraRigParameter']=function(_0x4a9b93,_0x7add08){this['_cameraRigParams']||(this['_cameraRigParams']={}),this['_cameraRigParams'][_0x4a9b93]=_0x7add08,'interaxialDistance'===_0x4a9b93&&(this['_cameraRigParams']['stereoHalfAngle']=_0x547738['b']['ToRadians'](_0x7add08/0.0637));},_0x215b69['prototype']['createRigCamera']=function(_0x2d7f00,_0x1dac80){return null;},_0x215b69['prototype']['_updateRigCameras']=function(){for(var _0x45a1d1=0x0;_0x45a1d1=0x1)&&(this['needAlphaBlending']()||_0x3d3db2['visibility']<0x1||_0x3d3db2['hasVertexAlpha']);},_0x26e5b5['prototype']['needAlphaTesting']=function(){return!!this['_forceAlphaTest'];},_0x26e5b5['prototype']['_shouldTurnAlphaTestOn']=function(_0x425bed){return!this['needAlphaBlendingForMesh'](_0x425bed)&&this['needAlphaTesting']();},_0x26e5b5['prototype']['getAlphaTestTexture']=function(){return null;},_0x26e5b5['prototype']['markDirty']=function(){for(var _0x3d4c22=0x0,_0x2029b0=this['getScene']()['meshes'];_0x3d4c22<_0x2029b0['length'];_0x3d4c22++){var _0x3b20e4=_0x2029b0[_0x3d4c22];if(_0x3b20e4['subMeshes'])for(var _0x15c77d=0x0,_0x4a2b7f=_0x3b20e4['subMeshes'];_0x15c77d<_0x4a2b7f['length'];_0x15c77d++){var _0x367117=_0x4a2b7f[_0x15c77d];_0x367117['getMaterial']()===this&&(_0x367117['effect']&&(_0x367117['effect']['_wasPreviouslyReady']=!0x1));}}},_0x26e5b5['prototype']['_preBind']=function(_0x55e2c5,_0x33dcb2){void 0x0===_0x33dcb2&&(_0x33dcb2=null);var _0x1deafd=this['_scene']['getEngine'](),_0x15630b=(null==_0x33dcb2?this['sideOrientation']:_0x33dcb2)===_0x26e5b5['ClockWiseSideOrientation'];return _0x1deafd['enableEffect'](_0x55e2c5||this['_effect']),_0x1deafd['setState'](this['backFaceCulling'],this['zOffset'],!0x1,_0x15630b),_0x15630b;},_0x26e5b5['prototype']['bind']=function(_0x2e4051,_0xc4694f){},_0x26e5b5['prototype']['bindForSubMesh']=function(_0x3b55ab,_0x53b311,_0xeb4808){},_0x26e5b5['prototype']['bindOnlyWorldMatrix']=function(_0x257243){},_0x26e5b5['prototype']['bindSceneUniformBuffer']=function(_0x405d1b,_0x2d35c0){_0x2d35c0['bindToEffect'](_0x405d1b,'Scene');},_0x26e5b5['prototype']['bindView']=function(_0x33a5c9){this['_useUBO']?this['bindSceneUniformBuffer'](_0x33a5c9,this['getScene']()['getSceneUniformBuffer']()):_0x33a5c9['setMatrix']('view',this['getScene']()['getViewMatrix']());},_0x26e5b5['prototype']['bindViewProjection']=function(_0x32f808){this['_useUBO']?this['bindSceneUniformBuffer'](_0x32f808,this['getScene']()['getSceneUniformBuffer']()):_0x32f808['setMatrix']('viewProjection',this['getScene']()['getTransformMatrix']());},_0x26e5b5['prototype']['_afterBind']=function(_0x591838){if(this['_scene']['_cachedMaterial']=this,this['_scene']['_cachedVisibility']=_0x591838?_0x591838['visibility']:0x1,this['_onBindObservable']&&_0x591838&&this['_onBindObservable']['notifyObservers'](_0x591838),this['disableDepthWrite']){var _0x51f2eb=this['_scene']['getEngine']();this['_cachedDepthWriteState']=_0x51f2eb['getDepthWrite'](),_0x51f2eb['setDepthWrite'](!0x1);}this['disableColorWrite']&&(_0x51f2eb=this['_scene']['getEngine'](),(this['_cachedColorWriteState']=_0x51f2eb['getColorWrite'](),_0x51f2eb['setColorWrite'](!0x1))),0x0!==this['depthFunction']&&(_0x51f2eb=this['_scene']['getEngine'](),(this['_cachedDepthFunctionState']=_0x51f2eb['getDepthFunction']()||0x0,_0x51f2eb['setDepthFunction'](this['depthFunction'])));},_0x26e5b5['prototype']['unbind']=function(){(this['_onUnBindObservable']&&this['_onUnBindObservable']['notifyObservers'](this),0x0!==this['depthFunction'])&&this['_scene']['getEngine']()['setDepthFunction'](this['_cachedDepthFunctionState']),this['disableDepthWrite']&&this['_scene']['getEngine']()['setDepthWrite'](this['_cachedDepthWriteState']),this['disableColorWrite']&&this['_scene']['getEngine']()['setColorWrite'](this['_cachedColorWriteState']);},_0x26e5b5['prototype']['getActiveTextures']=function(){return[];},_0x26e5b5['prototype']['hasTexture']=function(_0x1ffcf3){return!0x1;},_0x26e5b5['prototype']['clone']=function(_0x4c65b9){return null;},_0x26e5b5['prototype']['getBindedMeshes']=function(){var _0x279e87=this;if(this['meshMap']){var _0x289e99=new Array();for(var _0x1e2559 in this['meshMap']){var _0x58daee=this['meshMap'][_0x1e2559];_0x58daee&&_0x289e99['push'](_0x58daee);}return _0x289e99;}return this['_scene']['meshes']['filter'](function(_0x463cf4){return _0x463cf4['material']===_0x279e87;});},_0x26e5b5['prototype']['forceCompilation']=function(_0x6e695d,_0x515e1a,_0x2d966d,_0x307c54){var _0x487989=this,_0x29ffc6=Object(_0x1b91ad['a'])({'clipPlane':!0x1,'useInstances':!0x1},_0x2d966d),_0x38f58a=this['getScene'](),_0x541aef=this['allowShaderHotSwapping'];this['allowShaderHotSwapping']=!0x1;var _0x256156=function(){if(_0x487989['_scene']&&_0x487989['_scene']['getEngine']()){var _0x1ffbb2=_0x38f58a['clipPlane'];if(_0x29ffc6['clipPlane']&&(_0x38f58a['clipPlane']=new _0x25479e['a'](0x0,0x0,0x0,0x1)),_0x487989['_storeEffectOnSubMeshes']){var _0x33a8f2=!0x0,_0x4f51c2=null;if(_0x6e695d['subMeshes']){var _0xb319aa=new _0x555459['a'](0x0,0x0,0x0,0x0,0x0,_0x6e695d,void 0x0,!0x1,!0x1);_0xb319aa['_materialDefines']&&(_0xb319aa['_materialDefines']['_renderId']=-0x1),_0x487989['isReadyForSubMesh'](_0x6e695d,_0xb319aa,_0x29ffc6['useInstances'])||(_0xb319aa['effect']&&_0xb319aa['effect']['getCompilationError']()&&_0xb319aa['effect']['allFallbacksProcessed']()?_0x4f51c2=_0xb319aa['effect']['getCompilationError']():(_0x33a8f2=!0x1,setTimeout(_0x256156,0x10)));}_0x33a8f2&&(_0x487989['allowShaderHotSwapping']=_0x541aef,_0x4f51c2&&_0x307c54&&_0x307c54(_0x4f51c2),_0x515e1a&&_0x515e1a(_0x487989));}else _0x487989['isReady']()?(_0x487989['allowShaderHotSwapping']=_0x541aef,_0x515e1a&&_0x515e1a(_0x487989)):setTimeout(_0x256156,0x10);_0x29ffc6['clipPlane']&&(_0x38f58a['clipPlane']=_0x1ffbb2);}};_0x256156();},_0x26e5b5['prototype']['forceCompilationAsync']=function(_0x32b458,_0x5a26b3){var _0x365bc4=this;return new Promise(function(_0x12a39f,_0x33f385){_0x365bc4['forceCompilation'](_0x32b458,function(){_0x12a39f();},_0x5a26b3,function(_0x5a5421){_0x33f385(_0x5a5421);});});},_0x26e5b5['prototype']['markAsDirty']=function(_0x1a452d){this['getScene']()['blockMaterialDirtyMechanism']||(_0x26e5b5['_DirtyCallbackArray']['length']=0x0,_0x1a452d&_0x26e5b5['TextureDirtyFlag']&&_0x26e5b5['_DirtyCallbackArray']['push'](_0x26e5b5['_TextureDirtyCallBack']),_0x1a452d&_0x26e5b5['LightDirtyFlag']&&_0x26e5b5['_DirtyCallbackArray']['push'](_0x26e5b5['_LightsDirtyCallBack']),_0x1a452d&_0x26e5b5['FresnelDirtyFlag']&&_0x26e5b5['_DirtyCallbackArray']['push'](_0x26e5b5['_FresnelDirtyCallBack']),_0x1a452d&_0x26e5b5['AttributesDirtyFlag']&&_0x26e5b5['_DirtyCallbackArray']['push'](_0x26e5b5['_AttributeDirtyCallBack']),_0x1a452d&_0x26e5b5['MiscDirtyFlag']&&_0x26e5b5['_DirtyCallbackArray']['push'](_0x26e5b5['_MiscDirtyCallBack']),_0x1a452d&_0x26e5b5['PrePassDirtyFlag']&&_0x26e5b5['_DirtyCallbackArray']['push'](_0x26e5b5['_PrePassDirtyCallBack']),_0x26e5b5['_DirtyCallbackArray']['length']&&this['_markAllSubMeshesAsDirty'](_0x26e5b5['_RunDirtyCallBacks']),this['getScene']()['resetCachedMaterial']());},_0x26e5b5['prototype']['_markAllSubMeshesAsDirty']=function(_0x3bec39){if(!this['getScene']()['blockMaterialDirtyMechanism'])for(var _0x5901be=0x0,_0x50efe8=this['getScene']()['meshes'];_0x5901be<_0x50efe8['length'];_0x5901be++){var _0x455df3=_0x50efe8[_0x5901be];if(_0x455df3['subMeshes'])for(var _0x4535d0=0x0,_0x389078=_0x455df3['subMeshes'];_0x4535d0<_0x389078['length'];_0x4535d0++){var _0x348604=_0x389078[_0x4535d0];_0x348604['getMaterial']()===this&&(_0x348604['_materialDefines']&&_0x3bec39(_0x348604['_materialDefines']));}}},_0x26e5b5['prototype']['_markScenePrePassDirty']=function(){if(!this['getScene']()['blockMaterialDirtyMechanism']){var _0x20559a=this['getScene']()['enablePrePassRenderer']();_0x20559a&&_0x20559a['markAsDirty']();}},_0x26e5b5['prototype']['_markAllSubMeshesAsAllDirty']=function(){this['_markAllSubMeshesAsDirty'](_0x26e5b5['_AllDirtyCallBack']);},_0x26e5b5['prototype']['_markAllSubMeshesAsImageProcessingDirty']=function(){this['_markAllSubMeshesAsDirty'](_0x26e5b5['_ImageProcessingDirtyCallBack']);},_0x26e5b5['prototype']['_markAllSubMeshesAsTexturesDirty']=function(){this['_markAllSubMeshesAsDirty'](_0x26e5b5['_TextureDirtyCallBack']);},_0x26e5b5['prototype']['_markAllSubMeshesAsFresnelDirty']=function(){this['_markAllSubMeshesAsDirty'](_0x26e5b5['_FresnelDirtyCallBack']);},_0x26e5b5['prototype']['_markAllSubMeshesAsFresnelAndMiscDirty']=function(){this['_markAllSubMeshesAsDirty'](_0x26e5b5['_FresnelAndMiscDirtyCallBack']);},_0x26e5b5['prototype']['_markAllSubMeshesAsLightsDirty']=function(){this['_markAllSubMeshesAsDirty'](_0x26e5b5['_LightsDirtyCallBack']);},_0x26e5b5['prototype']['_markAllSubMeshesAsAttributesDirty']=function(){this['_markAllSubMeshesAsDirty'](_0x26e5b5['_AttributeDirtyCallBack']);},_0x26e5b5['prototype']['_markAllSubMeshesAsMiscDirty']=function(){this['_markAllSubMeshesAsDirty'](_0x26e5b5['_MiscDirtyCallBack']);},_0x26e5b5['prototype']['_markAllSubMeshesAsPrePassDirty']=function(){this['_markAllSubMeshesAsDirty'](_0x26e5b5['_MiscDirtyCallBack']);},_0x26e5b5['prototype']['_markAllSubMeshesAsTexturesAndMiscDirty']=function(){this['_markAllSubMeshesAsDirty'](_0x26e5b5['_TextureAndMiscDirtyCallBack']);},_0x26e5b5['prototype']['setPrePassRenderer']=function(_0x2abda3){return!0x1;},_0x26e5b5['prototype']['dispose']=function(_0xcd15bc,_0x3ee22a,_0x46d10c){var _0x5b3881=this['getScene']();if(_0x5b3881['stopAnimation'](this),_0x5b3881['freeProcessedMaterials'](),_0x5b3881['removeMaterial'](this),!0x0!==_0x46d10c){if(this['meshMap'])for(var _0x4a82cf in this['meshMap']){(_0x37eedf=this['meshMap'][_0x4a82cf])&&(_0x37eedf['material']=null,this['releaseVertexArrayObject'](_0x37eedf,_0xcd15bc));}else for(var _0x5065ae=0x0,_0x288c63=_0x5b3881['meshes'];_0x5065ae<_0x288c63['length'];_0x5065ae++){var _0x37eedf;(_0x37eedf=_0x288c63[_0x5065ae])['material']!==this||_0x37eedf['sourceMesh']||(_0x37eedf['material']=null,this['releaseVertexArrayObject'](_0x37eedf,_0xcd15bc));}}this['_uniformBuffer']['dispose'](),_0xcd15bc&&this['_effect']&&(this['_storeEffectOnSubMeshes']||this['_effect']['dispose'](),this['_effect']=null),this['onDisposeObservable']['notifyObservers'](this),this['onDisposeObservable']['clear'](),this['_onBindObservable']&&this['_onBindObservable']['clear'](),this['_onUnBindObservable']&&this['_onUnBindObservable']['clear'](),this['_onEffectCreatedObservable']&&this['_onEffectCreatedObservable']['clear']();},_0x26e5b5['prototype']['releaseVertexArrayObject']=function(_0x382a3d,_0x488eb6){if(_0x382a3d['geometry']){var _0x243e87=_0x382a3d['geometry'];if(this['_storeEffectOnSubMeshes'])for(var _0x206c25=0x0,_0x4df19d=_0x382a3d['subMeshes'];_0x206c25<_0x4df19d['length'];_0x206c25++){var _0x53e6ce=_0x4df19d[_0x206c25];_0x243e87['_releaseVertexArrayObject'](_0x53e6ce['_materialEffect']),_0x488eb6&&_0x53e6ce['_materialEffect']&&_0x53e6ce['_materialEffect']['dispose']();}else _0x243e87['_releaseVertexArrayObject'](this['_effect']);}},_0x26e5b5['prototype']['serialize']=function(){return _0x4a27aa['a']['Serialize'](this);},_0x26e5b5['Parse']=function(_0x790a99,_0x46460d,_0x1a8d5c){if(_0x790a99['customType']){if('BABYLON.PBRMaterial'===_0x790a99['customType']&&_0x790a99['overloadedAlbedo']&&(_0x790a99['customType']='BABYLON.LegacyPBRMaterial',!BABYLON['LegacyPBRMaterial']))return _0x3590fd['a']['Error']('Your\x20scene\x20is\x20trying\x20to\x20load\x20a\x20legacy\x20version\x20of\x20the\x20PBRMaterial,\x20please,\x20include\x20it\x20from\x20the\x20materials\x20library.'),null;}else _0x790a99['customType']='BABYLON.StandardMaterial';return _0x282a90['b']['Instantiate'](_0x790a99['customType'])['Parse'](_0x790a99,_0x46460d,_0x1a8d5c);},_0x26e5b5['TriangleFillMode']=_0x2b0f57['a']['MATERIAL_TriangleFillMode'],_0x26e5b5['WireFrameFillMode']=_0x2b0f57['a']['MATERIAL_WireFrameFillMode'],_0x26e5b5['PointFillMode']=_0x2b0f57['a']['MATERIAL_PointFillMode'],_0x26e5b5['PointListDrawMode']=_0x2b0f57['a']['MATERIAL_PointListDrawMode'],_0x26e5b5['LineListDrawMode']=_0x2b0f57['a']['MATERIAL_LineListDrawMode'],_0x26e5b5['LineLoopDrawMode']=_0x2b0f57['a']['MATERIAL_LineLoopDrawMode'],_0x26e5b5['LineStripDrawMode']=_0x2b0f57['a']['MATERIAL_LineStripDrawMode'],_0x26e5b5['TriangleStripDrawMode']=_0x2b0f57['a']['MATERIAL_TriangleStripDrawMode'],_0x26e5b5['TriangleFanDrawMode']=_0x2b0f57['a']['MATERIAL_TriangleFanDrawMode'],_0x26e5b5['ClockWiseSideOrientation']=_0x2b0f57['a']['MATERIAL_ClockWiseSideOrientation'],_0x26e5b5['CounterClockWiseSideOrientation']=_0x2b0f57['a']['MATERIAL_CounterClockWiseSideOrientation'],_0x26e5b5['TextureDirtyFlag']=_0x2b0f57['a']['MATERIAL_TextureDirtyFlag'],_0x26e5b5['LightDirtyFlag']=_0x2b0f57['a']['MATERIAL_LightDirtyFlag'],_0x26e5b5['FresnelDirtyFlag']=_0x2b0f57['a']['MATERIAL_FresnelDirtyFlag'],_0x26e5b5['AttributesDirtyFlag']=_0x2b0f57['a']['MATERIAL_AttributesDirtyFlag'],_0x26e5b5['MiscDirtyFlag']=_0x2b0f57['a']['MATERIAL_MiscDirtyFlag'],_0x26e5b5['PrePassDirtyFlag']=_0x2b0f57['a']['MATERIAL_PrePassDirtyFlag'],_0x26e5b5['AllDirtyFlag']=_0x2b0f57['a']['MATERIAL_AllDirtyFlag'],_0x26e5b5['MATERIAL_OPAQUE']=0x0,_0x26e5b5['MATERIAL_ALPHATEST']=0x1,_0x26e5b5['MATERIAL_ALPHABLEND']=0x2,_0x26e5b5['MATERIAL_ALPHATESTANDBLEND']=0x3,_0x26e5b5['MATERIAL_NORMALBLENDMETHOD_WHITEOUT']=0x0,_0x26e5b5['MATERIAL_NORMALBLENDMETHOD_RNM']=0x1,_0x26e5b5['_AllDirtyCallBack']=function(_0x8e94a1){return _0x8e94a1['markAllAsDirty']();},_0x26e5b5['_ImageProcessingDirtyCallBack']=function(_0x156d0a){return _0x156d0a['markAsImageProcessingDirty']();},_0x26e5b5['_TextureDirtyCallBack']=function(_0x5bb44f){return _0x5bb44f['markAsTexturesDirty']();},_0x26e5b5['_FresnelDirtyCallBack']=function(_0x18a72b){return _0x18a72b['markAsFresnelDirty']();},_0x26e5b5['_MiscDirtyCallBack']=function(_0x15d7dc){return _0x15d7dc['markAsMiscDirty']();},_0x26e5b5['_PrePassDirtyCallBack']=function(_0x5d8e3b){return _0x5d8e3b['markAsPrePassDirty']();},_0x26e5b5['_LightsDirtyCallBack']=function(_0x51d0ab){return _0x51d0ab['markAsLightDirty']();},_0x26e5b5['_AttributeDirtyCallBack']=function(_0x31646a){return _0x31646a['markAsAttributesDirty']();},_0x26e5b5['_FresnelAndMiscDirtyCallBack']=function(_0x4007a3){_0x26e5b5['_FresnelDirtyCallBack'](_0x4007a3),_0x26e5b5['_MiscDirtyCallBack'](_0x4007a3);},_0x26e5b5['_TextureAndMiscDirtyCallBack']=function(_0x1c50ed){_0x26e5b5['_TextureDirtyCallBack'](_0x1c50ed),_0x26e5b5['_MiscDirtyCallBack'](_0x1c50ed);},_0x26e5b5['_DirtyCallbackArray']=[],_0x26e5b5['_RunDirtyCallBacks']=function(_0x415303){for(var _0x1c6645=0x0,_0x104136=_0x26e5b5['_DirtyCallbackArray'];_0x1c6645<_0x104136['length'];_0x1c6645++){(0x0,_0x104136[_0x1c6645])(_0x415303);}},Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])()],_0x26e5b5['prototype'],'id',void 0x0),Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])()],_0x26e5b5['prototype'],'uniqueId',void 0x0),Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])()],_0x26e5b5['prototype'],'name',void 0x0),Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])()],_0x26e5b5['prototype'],'checkReadyOnEveryCall',void 0x0),Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])()],_0x26e5b5['prototype'],'checkReadyOnlyOnce',void 0x0),Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])()],_0x26e5b5['prototype'],'state',void 0x0),Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])('alpha')],_0x26e5b5['prototype'],'_alpha',void 0x0),Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])('backFaceCulling')],_0x26e5b5['prototype'],'_backFaceCulling',void 0x0),Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])()],_0x26e5b5['prototype'],'sideOrientation',void 0x0),Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])('alphaMode')],_0x26e5b5['prototype'],'_alphaMode',void 0x0),Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])()],_0x26e5b5['prototype'],'_needDepthPrePass',void 0x0),Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])()],_0x26e5b5['prototype'],'disableDepthWrite',void 0x0),Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])()],_0x26e5b5['prototype'],'disableColorWrite',void 0x0),Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])()],_0x26e5b5['prototype'],'forceDepthWrite',void 0x0),Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])()],_0x26e5b5['prototype'],'depthFunction',void 0x0),Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])()],_0x26e5b5['prototype'],'separateCullingPass',void 0x0),Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])('fogEnabled')],_0x26e5b5['prototype'],'_fogEnabled',void 0x0),Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])()],_0x26e5b5['prototype'],'pointSize',void 0x0),Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])()],_0x26e5b5['prototype'],'zOffset',void 0x0),Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])()],_0x26e5b5['prototype'],'pointsCloud',null),Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])()],_0x26e5b5['prototype'],'fillMode',null),Object(_0x1b91ad['c'])([Object(_0x4a27aa['c'])()],_0x26e5b5['prototype'],'transparencyMode',null),_0x26e5b5;}());},function(_0x5ce3a8,_0x5821fd,_0x49667a){'use strict';_0x49667a['d'](_0x5821fd,'a',function(){return _0x3b18a0;});var _0x58c4cf=_0x49667a(0x16),_0x589ad5=_0x49667a(0x5),_0x826132=_0x49667a(0x15),_0x44aedd=_0x49667a(0x6),_0x1f5eb6=_0x49667a(0x8d),_0x59e46f=_0x49667a(0x8e),_0xcea047=_0x49667a(0x8f),_0x585107=_0x49667a(0x2),_0x226a67=_0x49667a(0x1b),_0x4f5c06=_0x49667a(0x8),_0x5bca26=_0x49667a(0x26),_0x267dc5=(function(){function _0x27c707(){}return _0x27c707['prototype']['postProcessor']=function(_0x52eb65,_0x5e5490,_0x19cacd,_0x34aa70){return!_0x34aa70['getCaps']()['drawBuffersExtension']&&(_0x52eb65=_0x52eb65['replace'](/#extension.+GL_EXT_draw_buffers.+(enable|require)/g,'')),_0x52eb65;},_0x27c707;}()),_0x4eb227=_0x49667a(0x76),_0x2157b1=_0x49667a(0x58),_0x9fd0de=_0x49667a(0x90),_0xc6dceb=_0x49667a(0x46),_0x470050=_0x49667a(0x4a),_0x5f3d22=function(){},_0x3b18a0=(function(){function _0x5b5c13(_0x2d4052,_0x45b8be,_0xc29d05,_0xc820ff){var _0x4a5c07=this;void 0x0===_0xc820ff&&(_0xc820ff=!0x1),this['forcePOTTextures']=!0x1,this['isFullscreen']=!0x1,this['cullBackFaces']=!0x0,this['renderEvenInBackground']=!0x0,this['preventCacheWipeBetweenFrames']=!0x1,this['validateShaderPrograms']=!0x1,this['useReverseDepthBuffer']=!0x1,this['disableUniformBuffers']=!0x1,this['_uniformBuffers']=new Array(),this['_webGLVersion']=0x1,this['_windowIsBackground']=!0x1,this['_highPrecisionShadersAllowed']=!0x0,this['_badOS']=!0x1,this['_badDesktopOS']=!0x1,this['_renderingQueueLaunched']=!0x1,this['_activeRenderLoops']=new Array(),this['onContextLostObservable']=new _0x44aedd['c'](),this['onContextRestoredObservable']=new _0x44aedd['c'](),this['_contextWasLost']=!0x1,this['_doNotHandleContextLost']=!0x1,this['disableVertexArrayObjects']=!0x1,this['_colorWrite']=!0x0,this['_colorWriteChanged']=!0x0,this['_depthCullingState']=new _0x1f5eb6['a'](),this['_stencilState']=new _0x59e46f['a'](),this['_alphaState']=new _0xcea047['a'](),this['_alphaMode']=_0x585107['a']['ALPHA_ADD'],this['_alphaEquation']=_0x585107['a']['ALPHA_DISABLE'],this['_internalTexturesCache']=new Array(),this['_activeChannel']=0x0,this['_currentTextureChannel']=-0x1,this['_boundTexturesCache']={},this['_compiledEffects']={},this['_vertexAttribArraysEnabled']=[],this['_uintIndicesCurrentlySet']=!0x1,this['_currentBoundBuffer']=new Array(),this['_currentFramebuffer']=null,this['_dummyFramebuffer']=null,this['_currentBufferPointers']=new Array(),this['_currentInstanceLocations']=new Array(),this['_currentInstanceBuffers']=new Array(),this['_vaoRecordInProgress']=!0x1,this['_mustWipeVertexAttributes']=!0x1,this['_nextFreeTextureSlots']=new Array(),this['_maxSimultaneousTextures']=0x0,this['_activeRequests']=new Array(),this['_transformTextureUrl']=null,this['hostInformation']={'isMobile':!0x1},this['premultipliedAlpha']=!0x0,this['onBeforeTextureInitObservable']=new _0x44aedd['c'](),this['_viewportCached']={'x':0x0,'y':0x0,'z':0x0,'w':0x0},this['_unpackFlipYCached']=null,this['enableUnpackFlipYCached']=!0x0,this['_getDepthStencilBuffer']=function(_0x468092,_0x345114,_0x5e66ad,_0x1cf0e4,_0xd59557,_0x21b643){var _0x2409fd=_0x4a5c07['_gl'],_0x5e6ed0=_0x2409fd['createRenderbuffer']();return _0x2409fd['bindRenderbuffer'](_0x2409fd['RENDERBUFFER'],_0x5e6ed0),_0x5e66ad>0x1&&_0x2409fd['renderbufferStorageMultisample']?_0x2409fd['renderbufferStorageMultisample'](_0x2409fd['RENDERBUFFER'],_0x5e66ad,_0xd59557,_0x468092,_0x345114):_0x2409fd['renderbufferStorage'](_0x2409fd['RENDERBUFFER'],_0x1cf0e4,_0x468092,_0x345114),_0x2409fd['framebufferRenderbuffer'](_0x2409fd['FRAMEBUFFER'],_0x21b643,_0x2409fd['RENDERBUFFER'],_0x5e6ed0),_0x2409fd['bindRenderbuffer'](_0x2409fd['RENDERBUFFER'],null),_0x5e6ed0;},this['_boundUniforms']={};var _0x405280=null;if(_0x2d4052){if(_0xc29d05=_0xc29d05||{},_0x470050['a']['SetMatrixPrecision'](!!_0xc29d05['useHighPrecisionMatrix']),_0x2d4052['getContext']){if(_0x405280=_0x2d4052,this['_renderingCanvas']=_0x405280,null!=_0x45b8be&&(_0xc29d05['antialias']=_0x45b8be),void 0x0===_0xc29d05['deterministicLockstep']&&(_0xc29d05['deterministicLockstep']=!0x1),void 0x0===_0xc29d05['lockstepMaxSteps']&&(_0xc29d05['lockstepMaxSteps']=0x4),void 0x0===_0xc29d05['timeStep']&&(_0xc29d05['timeStep']=0x1/0x3c),void 0x0===_0xc29d05['preserveDrawingBuffer']&&(_0xc29d05['preserveDrawingBuffer']=!0x1),void 0x0===_0xc29d05['audioEngine']&&(_0xc29d05['audioEngine']=!0x0),void 0x0===_0xc29d05['stencil']&&(_0xc29d05['stencil']=!0x0),!0x1===_0xc29d05['premultipliedAlpha']&&(this['premultipliedAlpha']=!0x1),void 0x0===_0xc29d05['xrCompatible']&&(_0xc29d05['xrCompatible']=!0x0),this['_doNotHandleContextLost']=!!_0xc29d05['doNotHandleContextLost'],navigator&&navigator['userAgent']){var _0x4e8057=navigator['userAgent'];this['hostInformation']['isMobile']=-0x1!==_0x4e8057['indexOf']('Mobile');for(var _0x3de39e=0x0,_0x1c52bc=_0x5b5c13['ExceptionList'];_0x3de39e<_0x1c52bc['length'];_0x3de39e++){var _0x69374f=_0x1c52bc[_0x3de39e],_0x5e986b=_0x69374f['key'],_0x6bb488=_0x69374f['targets'];if(new RegExp(_0x5e986b)['test'](_0x4e8057)){if(_0x69374f['capture']&&_0x69374f['captureConstraint']){var _0x52b81e=_0x69374f['capture'],_0x5b2533=_0x69374f['captureConstraint'],_0x5468c9=new RegExp(_0x52b81e)['exec'](_0x4e8057);if(_0x5468c9&&_0x5468c9['length']>0x0){if(parseInt(_0x5468c9[_0x5468c9['length']-0x1])>=_0x5b2533)continue;}}for(var _0x58b5b9=0x0,_0x3eeaf6=_0x6bb488;_0x58b5b9<_0x3eeaf6['length'];_0x58b5b9++){switch(_0x3eeaf6[_0x58b5b9]){case'uniformBuffer':this['disableUniformBuffers']=!0x0;break;case'vao':this['disableVertexArrayObjects']=!0x0;}}}}}if(this['_doNotHandleContextLost']||(this['_onContextLost']=function(_0x594379){_0x594379['preventDefault'](),_0x4a5c07['_contextWasLost']=!0x0,_0x4f5c06['a']['Warn']('WebGL\x20context\x20lost.'),_0x4a5c07['onContextLostObservable']['notifyObservers'](_0x4a5c07);},this['_onContextRestored']=function(){setTimeout(function(){_0x4a5c07['_initGLContext'](),_0x4a5c07['_rebuildEffects'](),_0x4a5c07['_rebuildInternalTextures'](),_0x4a5c07['_rebuildBuffers'](),_0x4a5c07['wipeCaches'](!0x0),_0x4f5c06['a']['Warn']('WebGL\x20context\x20successfully\x20restored.'),_0x4a5c07['onContextRestoredObservable']['notifyObservers'](_0x4a5c07),_0x4a5c07['_contextWasLost']=!0x1;},0x0);},_0x405280['addEventListener']('webglcontextlost',this['_onContextLost'],!0x1),_0x405280['addEventListener']('webglcontextrestored',this['_onContextRestored'],!0x1),_0xc29d05['powerPreference']='high-performance'),!_0xc29d05['disableWebGL2Support'])try{this['_gl']=_0x405280['getContext']('webgl2',_0xc29d05)||_0x405280['getContext']('experimental-webgl2',_0xc29d05),this['_gl']&&(this['_webGLVersion']=0x2,this['_gl']['deleteQuery']||(this['_webGLVersion']=0x1));}catch(_0x59e49e){}if(!this['_gl']){if(!_0x405280)throw new Error('The\x20provided\x20canvas\x20is\x20null\x20or\x20undefined.');try{this['_gl']=_0x405280['getContext']('webgl',_0xc29d05)||_0x405280['getContext']('experimental-webgl',_0xc29d05);}catch(_0x273f08){throw new Error('WebGL\x20not\x20supported');}}if(!this['_gl'])throw new Error('WebGL\x20not\x20supported');}else{this['_gl']=_0x2d4052,this['_renderingCanvas']=this['_gl']['canvas'],this['_gl']['renderbufferStorageMultisample']&&(this['_webGLVersion']=0x2);var _0xc8f647=this['_gl']['getContextAttributes']();_0xc8f647&&(_0xc29d05['stencil']=_0xc8f647['stencil']);}this['_gl']['pixelStorei'](this['_gl']['UNPACK_COLORSPACE_CONVERSION_WEBGL'],this['_gl']['NONE']),void 0x0!==_0xc29d05['useHighPrecisionFloats']&&(this['_highPrecisionShadersAllowed']=_0xc29d05['useHighPrecisionFloats']);var _0x3e01df=_0x5bca26['a']['IsWindowObjectExist']()&&window['devicePixelRatio']||0x1,_0x1d4d8c=_0xc29d05['limitDeviceRatio']||_0x3e01df;this['_hardwareScalingLevel']=_0xc820ff?0x1/Math['min'](_0x1d4d8c,_0x3e01df):0x1,this['resize'](),this['_isStencilEnable']=!!_0xc29d05['stencil'],this['_initGLContext']();for(var _0x223fc4=0x0;_0x223fc40x1?this['_shaderProcessor']=new _0x4eb227['a']():this['_shaderProcessor']=new _0x267dc5(),this['_badOS']=/iPad/i['test'](navigator['userAgent'])||/iPhone/i['test'](navigator['userAgent']),this['_badDesktopOS']=/^((?!chrome|android).)*safari/i['test'](navigator['userAgent']),this['_creationOptions']=_0xc29d05,console['log']('Babylon.js\x20v'+_0x5b5c13['Version']+'\x20-\x20'+this['description']);}}return Object['defineProperty'](_0x5b5c13,'NpmPackage',{'get':function(){return'babylonjs@4.2.1';},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5b5c13,'Version',{'get':function(){return'4.2.1';},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5b5c13['prototype'],'description',{'get':function(){var _0x5cfad3='WebGL'+this['webGLVersion'];return this['_caps']['parallelShaderCompile']&&(_0x5cfad3+='\x20-\x20Parallel\x20shader\x20compilation'),_0x5cfad3;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5b5c13,'ShadersRepository',{'get':function(){return _0x589ad5['a']['ShadersRepository'];},'set':function(_0x1a9b41){_0x589ad5['a']['ShadersRepository']=_0x1a9b41;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5b5c13['prototype'],'supportsUniformBuffers',{'get':function(){return this['webGLVersion']>0x1&&!this['disableUniformBuffers'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5b5c13['prototype'],'_shouldUseHighPrecisionShader',{'get':function(){return!(!this['_caps']['highPrecisionShaderSupported']||!this['_highPrecisionShadersAllowed']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5b5c13['prototype'],'needPOTTextures',{'get':function(){return this['_webGLVersion']<0x2||this['forcePOTTextures'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5b5c13['prototype'],'doNotHandleContextLost',{'get':function(){return this['_doNotHandleContextLost'];},'set':function(_0x4320ca){this['_doNotHandleContextLost']=_0x4320ca;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5b5c13['prototype'],'_supportsHardwareTextureRescaling',{'get':function(){return!0x1;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5b5c13['prototype'],'framebufferDimensionsObject',{'set':function(_0x2ed9f9){this['_framebufferDimensionsObject']=_0x2ed9f9;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5b5c13['prototype'],'currentViewport',{'get':function(){return this['_cachedViewport'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5b5c13['prototype'],'emptyTexture',{'get':function(){return this['_emptyTexture']||(this['_emptyTexture']=this['createRawTexture'](new Uint8Array(0x4),0x1,0x1,_0x585107['a']['TEXTUREFORMAT_RGBA'],!0x1,!0x1,_0x585107['a']['TEXTURE_NEAREST_SAMPLINGMODE'])),this['_emptyTexture'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5b5c13['prototype'],'emptyTexture3D',{'get':function(){return this['_emptyTexture3D']||(this['_emptyTexture3D']=this['createRawTexture3D'](new Uint8Array(0x4),0x1,0x1,0x1,_0x585107['a']['TEXTUREFORMAT_RGBA'],!0x1,!0x1,_0x585107['a']['TEXTURE_NEAREST_SAMPLINGMODE'])),this['_emptyTexture3D'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5b5c13['prototype'],'emptyTexture2DArray',{'get':function(){return this['_emptyTexture2DArray']||(this['_emptyTexture2DArray']=this['createRawTexture2DArray'](new Uint8Array(0x4),0x1,0x1,0x1,_0x585107['a']['TEXTUREFORMAT_RGBA'],!0x1,!0x1,_0x585107['a']['TEXTURE_NEAREST_SAMPLINGMODE'])),this['_emptyTexture2DArray'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5b5c13['prototype'],'emptyCubeTexture',{'get':function(){if(!this['_emptyCubeTexture']){var _0x1b2727=new Uint8Array(0x4),_0x2d2c8a=[_0x1b2727,_0x1b2727,_0x1b2727,_0x1b2727,_0x1b2727,_0x1b2727];this['_emptyCubeTexture']=this['createRawCubeTexture'](_0x2d2c8a,0x1,_0x585107['a']['TEXTUREFORMAT_RGBA'],_0x585107['a']['TEXTURETYPE_UNSIGNED_INT'],!0x1,!0x1,_0x585107['a']['TEXTURE_NEAREST_SAMPLINGMODE']);}return this['_emptyCubeTexture'];},'enumerable':!0x1,'configurable':!0x0}),_0x5b5c13['prototype']['_rebuildInternalTextures']=function(){for(var _0x47d4f0=0x0,_0x26e237=this['_internalTexturesCache']['slice']();_0x47d4f0<_0x26e237['length'];_0x47d4f0++){_0x26e237[_0x47d4f0]['_rebuild']();}},_0x5b5c13['prototype']['_rebuildEffects']=function(){for(var _0x160d97 in this['_compiledEffects']){this['_compiledEffects'][_0x160d97]['_prepareEffect']();}_0x589ad5['a']['ResetCache']();},_0x5b5c13['prototype']['areAllEffectsReady']=function(){for(var _0x52c110 in this['_compiledEffects']){if(!this['_compiledEffects'][_0x52c110]['isReady']())return!0x1;}return!0x0;},_0x5b5c13['prototype']['_rebuildBuffers']=function(){for(var _0x4a8e01=0x0,_0x8389f1=this['_uniformBuffers'];_0x4a8e01<_0x8389f1['length'];_0x4a8e01++){_0x8389f1[_0x4a8e01]['_rebuild']();}},_0x5b5c13['prototype']['_initGLContext']=function(){this['_caps']={'maxTexturesImageUnits':this['_gl']['getParameter'](this['_gl']['MAX_TEXTURE_IMAGE_UNITS']),'maxCombinedTexturesImageUnits':this['_gl']['getParameter'](this['_gl']['MAX_COMBINED_TEXTURE_IMAGE_UNITS']),'maxVertexTextureImageUnits':this['_gl']['getParameter'](this['_gl']['MAX_VERTEX_TEXTURE_IMAGE_UNITS']),'maxTextureSize':this['_gl']['getParameter'](this['_gl']['MAX_TEXTURE_SIZE']),'maxSamples':this['_webGLVersion']>0x1?this['_gl']['getParameter'](this['_gl']['MAX_SAMPLES']):0x1,'maxCubemapTextureSize':this['_gl']['getParameter'](this['_gl']['MAX_CUBE_MAP_TEXTURE_SIZE']),'maxRenderTextureSize':this['_gl']['getParameter'](this['_gl']['MAX_RENDERBUFFER_SIZE']),'maxVertexAttribs':this['_gl']['getParameter'](this['_gl']['MAX_VERTEX_ATTRIBS']),'maxVaryingVectors':this['_gl']['getParameter'](this['_gl']['MAX_VARYING_VECTORS']),'maxFragmentUniformVectors':this['_gl']['getParameter'](this['_gl']['MAX_FRAGMENT_UNIFORM_VECTORS']),'maxVertexUniformVectors':this['_gl']['getParameter'](this['_gl']['MAX_VERTEX_UNIFORM_VECTORS']),'parallelShaderCompile':this['_gl']['getExtension']('KHR_parallel_shader_compile'),'standardDerivatives':this['_webGLVersion']>0x1||null!==this['_gl']['getExtension']('OES_standard_derivatives'),'maxAnisotropy':0x1,'astc':this['_gl']['getExtension']('WEBGL_compressed_texture_astc')||this['_gl']['getExtension']('WEBKIT_WEBGL_compressed_texture_astc'),'bptc':this['_gl']['getExtension']('EXT_texture_compression_bptc')||this['_gl']['getExtension']('WEBKIT_EXT_texture_compression_bptc'),'s3tc':this['_gl']['getExtension']('WEBGL_compressed_texture_s3tc')||this['_gl']['getExtension']('WEBKIT_WEBGL_compressed_texture_s3tc'),'pvrtc':this['_gl']['getExtension']('WEBGL_compressed_texture_pvrtc')||this['_gl']['getExtension']('WEBKIT_WEBGL_compressed_texture_pvrtc'),'etc1':this['_gl']['getExtension']('WEBGL_compressed_texture_etc1')||this['_gl']['getExtension']('WEBKIT_WEBGL_compressed_texture_etc1'),'etc2':this['_gl']['getExtension']('WEBGL_compressed_texture_etc')||this['_gl']['getExtension']('WEBKIT_WEBGL_compressed_texture_etc')||this['_gl']['getExtension']('WEBGL_compressed_texture_es3_0'),'textureAnisotropicFilterExtension':this['_gl']['getExtension']('EXT_texture_filter_anisotropic')||this['_gl']['getExtension']('WEBKIT_EXT_texture_filter_anisotropic')||this['_gl']['getExtension']('MOZ_EXT_texture_filter_anisotropic'),'uintIndices':this['_webGLVersion']>0x1||null!==this['_gl']['getExtension']('OES_element_index_uint'),'fragmentDepthSupported':this['_webGLVersion']>0x1||null!==this['_gl']['getExtension']('EXT_frag_depth'),'highPrecisionShaderSupported':!0x1,'timerQuery':this['_gl']['getExtension']('EXT_disjoint_timer_query_webgl2')||this['_gl']['getExtension']('EXT_disjoint_timer_query'),'canUseTimestampForTimerQuery':!0x1,'drawBuffersExtension':!0x1,'maxMSAASamples':0x1,'colorBufferFloat':this['_webGLVersion']>0x1&&this['_gl']['getExtension']('EXT_color_buffer_float'),'textureFloat':!!(this['_webGLVersion']>0x1||this['_gl']['getExtension']('OES_texture_float')),'textureHalfFloat':!!(this['_webGLVersion']>0x1||this['_gl']['getExtension']('OES_texture_half_float')),'textureHalfFloatRender':!0x1,'textureFloatLinearFiltering':!0x1,'textureFloatRender':!0x1,'textureHalfFloatLinearFiltering':!0x1,'vertexArrayObject':!0x1,'instancedArrays':!0x1,'textureLOD':!!(this['_webGLVersion']>0x1||this['_gl']['getExtension']('EXT_shader_texture_lod')),'blendMinMax':!0x1,'multiview':this['_gl']['getExtension']('OVR_multiview2'),'oculusMultiview':this['_gl']['getExtension']('OCULUS_multiview'),'depthTextureExtension':!0x1},this['_glVersion']=this['_gl']['getParameter'](this['_gl']['VERSION']);var _0x157bc7=this['_gl']['getExtension']('WEBGL_debug_renderer_info');if(null!=_0x157bc7&&(this['_glRenderer']=this['_gl']['getParameter'](_0x157bc7['UNMASKED_RENDERER_WEBGL']),this['_glVendor']=this['_gl']['getParameter'](_0x157bc7['UNMASKED_VENDOR_WEBGL'])),this['_glVendor']||(this['_glVendor']='Unknown\x20vendor'),this['_glRenderer']||(this['_glRenderer']='Unknown\x20renderer'),0x8d61!==this['_gl']['HALF_FLOAT_OES']&&(this['_gl']['HALF_FLOAT_OES']=0x8d61),0x881a!==this['_gl']['RGBA16F']&&(this['_gl']['RGBA16F']=0x881a),0x8814!==this['_gl']['RGBA32F']&&(this['_gl']['RGBA32F']=0x8814),0x88f0!==this['_gl']['DEPTH24_STENCIL8']&&(this['_gl']['DEPTH24_STENCIL8']=0x88f0),this['_caps']['timerQuery']&&(0x1===this['_webGLVersion']&&(this['_gl']['getQuery']=this['_caps']['timerQuery']['getQueryEXT']['bind'](this['_caps']['timerQuery'])),this['_caps']['canUseTimestampForTimerQuery']=this['_gl']['getQuery'](this['_caps']['timerQuery']['TIMESTAMP_EXT'],this['_caps']['timerQuery']['QUERY_COUNTER_BITS_EXT'])>0x0),this['_caps']['maxAnisotropy']=this['_caps']['textureAnisotropicFilterExtension']?this['_gl']['getParameter'](this['_caps']['textureAnisotropicFilterExtension']['MAX_TEXTURE_MAX_ANISOTROPY_EXT']):0x0,this['_caps']['textureFloatLinearFiltering']=!(!this['_caps']['textureFloat']||!this['_gl']['getExtension']('OES_texture_float_linear')),this['_caps']['textureFloatRender']=!(!this['_caps']['textureFloat']||!this['_canRenderToFloatFramebuffer']()),this['_caps']['textureHalfFloatLinearFiltering']=!!(this['_webGLVersion']>0x1||this['_caps']['textureHalfFloat']&&this['_gl']['getExtension']('OES_texture_half_float_linear')),this['_webGLVersion']>0x1&&0x140b!==this['_gl']['HALF_FLOAT_OES']&&(this['_gl']['HALF_FLOAT_OES']=0x140b),this['_caps']['textureHalfFloatRender']=this['_caps']['textureHalfFloat']&&this['_canRenderToHalfFloatFramebuffer'](),this['_webGLVersion']>0x1)this['_caps']['drawBuffersExtension']=!0x0,this['_caps']['maxMSAASamples']=this['_gl']['getParameter'](this['_gl']['MAX_SAMPLES']);else{var _0x45269c=this['_gl']['getExtension']('WEBGL_draw_buffers');if(null!==_0x45269c){this['_caps']['drawBuffersExtension']=!0x0,this['_gl']['drawBuffers']=_0x45269c['drawBuffersWEBGL']['bind'](_0x45269c),this['_gl']['DRAW_FRAMEBUFFER']=this['_gl']['FRAMEBUFFER'];for(var _0x2becc3=0x0;_0x2becc3<0x10;_0x2becc3++)this['_gl']['COLOR_ATTACHMENT'+_0x2becc3+'_WEBGL']=_0x45269c['COLOR_ATTACHMENT'+_0x2becc3+'_WEBGL'];}}if(this['_webGLVersion']>0x1)this['_caps']['depthTextureExtension']=!0x0;else{var _0x4a981a=this['_gl']['getExtension']('WEBGL_depth_texture');null!=_0x4a981a&&(this['_caps']['depthTextureExtension']=!0x0,this['_gl']['UNSIGNED_INT_24_8']=_0x4a981a['UNSIGNED_INT_24_8_WEBGL']);}if(this['disableVertexArrayObjects'])this['_caps']['vertexArrayObject']=!0x1;else{if(this['_webGLVersion']>0x1)this['_caps']['vertexArrayObject']=!0x0;else{var _0x30e3db=this['_gl']['getExtension']('OES_vertex_array_object');null!=_0x30e3db&&(this['_caps']['vertexArrayObject']=!0x0,this['_gl']['createVertexArray']=_0x30e3db['createVertexArrayOES']['bind'](_0x30e3db),this['_gl']['bindVertexArray']=_0x30e3db['bindVertexArrayOES']['bind'](_0x30e3db),this['_gl']['deleteVertexArray']=_0x30e3db['deleteVertexArrayOES']['bind'](_0x30e3db));}}if(this['_webGLVersion']>0x1)this['_caps']['instancedArrays']=!0x0;else{var _0x39be95=this['_gl']['getExtension']('ANGLE_instanced_arrays');null!=_0x39be95?(this['_caps']['instancedArrays']=!0x0,this['_gl']['drawArraysInstanced']=_0x39be95['drawArraysInstancedANGLE']['bind'](_0x39be95),this['_gl']['drawElementsInstanced']=_0x39be95['drawElementsInstancedANGLE']['bind'](_0x39be95),this['_gl']['vertexAttribDivisor']=_0x39be95['vertexAttribDivisorANGLE']['bind'](_0x39be95)):this['_caps']['instancedArrays']=!0x1;}if(this['_gl']['getShaderPrecisionFormat']){var _0x12f2a5=this['_gl']['getShaderPrecisionFormat'](this['_gl']['VERTEX_SHADER'],this['_gl']['HIGH_FLOAT']),_0x55dddc=this['_gl']['getShaderPrecisionFormat'](this['_gl']['FRAGMENT_SHADER'],this['_gl']['HIGH_FLOAT']);_0x12f2a5&&_0x55dddc&&(this['_caps']['highPrecisionShaderSupported']=0x0!==_0x12f2a5['precision']&&0x0!==_0x55dddc['precision']);}if(this['_webGLVersion']>0x1)this['_caps']['blendMinMax']=!0x0;else{var _0x3faeb7=this['_gl']['getExtension']('EXT_blend_minmax');null!=_0x3faeb7&&(this['_caps']['blendMinMax']=!0x0,this['_gl']['MAX']=_0x3faeb7['MAX_EXT'],this['_gl']['MIN']=_0x3faeb7['MIN_EXT']);}this['_depthCullingState']['depthTest']=!0x0,this['_depthCullingState']['depthFunc']=this['_gl']['LEQUAL'],this['_depthCullingState']['depthMask']=!0x0,this['_maxSimultaneousTextures']=this['_caps']['maxCombinedTexturesImageUnits'];for(var _0x1fef54=0x0;_0x1fef54=0x0&&this['_activeRenderLoops']['splice'](_0x14cf97,0x1);}else this['_activeRenderLoops']=[];},_0x5b5c13['prototype']['_renderLoop']=function(){if(!this['_contextWasLost']){var _0xc705be=!0x0;if(!this['renderEvenInBackground']&&this['_windowIsBackground']&&(_0xc705be=!0x1),_0xc705be){this['beginFrame']();for(var _0x1b0aef=0x0;_0x1b0aef0x0?this['_frameHandler']=this['_queueNewFrame'](this['_boundRenderFunction'],this['getHostWindow']()):this['_renderingQueueLaunched']=!0x1;},_0x5b5c13['prototype']['getRenderingCanvas']=function(){return this['_renderingCanvas'];},_0x5b5c13['prototype']['getHostWindow']=function(){return _0x5bca26['a']['IsWindowObjectExist']()?this['_renderingCanvas']&&this['_renderingCanvas']['ownerDocument']&&this['_renderingCanvas']['ownerDocument']['defaultView']?this['_renderingCanvas']['ownerDocument']['defaultView']:window:null;},_0x5b5c13['prototype']['getRenderWidth']=function(_0x1f94d3){return void 0x0===_0x1f94d3&&(_0x1f94d3=!0x1),!_0x1f94d3&&this['_currentRenderTarget']?this['_currentRenderTarget']['width']:this['_framebufferDimensionsObject']?this['_framebufferDimensionsObject']['framebufferWidth']:this['_gl']['drawingBufferWidth'];},_0x5b5c13['prototype']['getRenderHeight']=function(_0x2b5216){return void 0x0===_0x2b5216&&(_0x2b5216=!0x1),!_0x2b5216&&this['_currentRenderTarget']?this['_currentRenderTarget']['height']:this['_framebufferDimensionsObject']?this['_framebufferDimensionsObject']['framebufferHeight']:this['_gl']['drawingBufferHeight'];},_0x5b5c13['prototype']['_queueNewFrame']=function(_0x5b32d0,_0x2fba78){return _0x5b5c13['QueueNewFrame'](_0x5b32d0,_0x2fba78);},_0x5b5c13['prototype']['runRenderLoop']=function(_0x2a2858){-0x1===this['_activeRenderLoops']['indexOf'](_0x2a2858)&&(this['_activeRenderLoops']['push'](_0x2a2858),this['_renderingQueueLaunched']||(this['_renderingQueueLaunched']=!0x0,this['_boundRenderFunction']=this['_renderLoop']['bind'](this),this['_frameHandler']=this['_queueNewFrame'](this['_boundRenderFunction'],this['getHostWindow']())));},_0x5b5c13['prototype']['clear']=function(_0x21bf48,_0x4c5c17,_0x1bc9b1,_0x29fb40){void 0x0===_0x29fb40&&(_0x29fb40=!0x1),this['applyStates']();var _0x4d8e74=0x0;_0x4c5c17&&_0x21bf48&&(this['_gl']['clearColor'](_0x21bf48['r'],_0x21bf48['g'],_0x21bf48['b'],void 0x0!==_0x21bf48['a']?_0x21bf48['a']:0x1),_0x4d8e74|=this['_gl']['COLOR_BUFFER_BIT']),_0x1bc9b1&&(this['useReverseDepthBuffer']?(this['_depthCullingState']['depthFunc']=this['_gl']['GREATER'],this['_gl']['clearDepth'](0x0)):this['_gl']['clearDepth'](0x1),_0x4d8e74|=this['_gl']['DEPTH_BUFFER_BIT']),_0x29fb40&&(this['_gl']['clearStencil'](0x0),_0x4d8e74|=this['_gl']['STENCIL_BUFFER_BIT']),this['_gl']['clear'](_0x4d8e74);},_0x5b5c13['prototype']['_viewport']=function(_0x2ae07d,_0x5e8a5f,_0x1ec488,_0x11c765){_0x2ae07d===this['_viewportCached']['x']&&_0x5e8a5f===this['_viewportCached']['y']&&_0x1ec488===this['_viewportCached']['z']&&_0x11c765===this['_viewportCached']['w']||(this['_viewportCached']['x']=_0x2ae07d,this['_viewportCached']['y']=_0x5e8a5f,this['_viewportCached']['z']=_0x1ec488,this['_viewportCached']['w']=_0x11c765,this['_gl']['viewport'](_0x2ae07d,_0x5e8a5f,_0x1ec488,_0x11c765));},_0x5b5c13['prototype']['setViewport']=function(_0x5f386b,_0x3400cf,_0x156900){var _0x5efcdc=_0x3400cf||this['getRenderWidth'](),_0x2052fe=_0x156900||this['getRenderHeight'](),_0x4482b9=_0x5f386b['x']||0x0,_0x239438=_0x5f386b['y']||0x0;this['_cachedViewport']=_0x5f386b,this['_viewport'](_0x4482b9*_0x5efcdc,_0x239438*_0x2052fe,_0x5efcdc*_0x5f386b['width'],_0x2052fe*_0x5f386b['height']);},_0x5b5c13['prototype']['beginFrame']=function(){},_0x5b5c13['prototype']['endFrame']=function(){this['_badOS']&&this['flushFramebuffer']();},_0x5b5c13['prototype']['resize']=function(){var _0x382db9,_0x4aa69c;_0x5bca26['a']['IsWindowObjectExist']()?(_0x382db9=this['_renderingCanvas']?this['_renderingCanvas']['clientWidth']||this['_renderingCanvas']['width']:window['innerWidth'],_0x4aa69c=this['_renderingCanvas']?this['_renderingCanvas']['clientHeight']||this['_renderingCanvas']['height']:window['innerHeight']):(_0x382db9=this['_renderingCanvas']?this['_renderingCanvas']['width']:0x64,_0x4aa69c=this['_renderingCanvas']?this['_renderingCanvas']['height']:0x64),this['setSize'](_0x382db9/this['_hardwareScalingLevel'],_0x4aa69c/this['_hardwareScalingLevel']);},_0x5b5c13['prototype']['setSize']=function(_0x545030,_0x5d5903){return!!this['_renderingCanvas']&&(_0x545030|=0x0,_0x5d5903|=0x0,(this['_renderingCanvas']['width']!==_0x545030||this['_renderingCanvas']['height']!==_0x5d5903)&&(this['_renderingCanvas']['width']=_0x545030,this['_renderingCanvas']['height']=_0x5d5903,!0x0));},_0x5b5c13['prototype']['bindFramebuffer']=function(_0x5d3b0d,_0x2ff2b2,_0x2eea5a,_0x43a2c1,_0x2b53e3,_0x10f9a5,_0xc23d08){void 0x0===_0x2ff2b2&&(_0x2ff2b2=0x0),void 0x0===_0x10f9a5&&(_0x10f9a5=0x0),void 0x0===_0xc23d08&&(_0xc23d08=0x0),this['_currentRenderTarget']&&this['unBindFramebuffer'](this['_currentRenderTarget']),this['_currentRenderTarget']=_0x5d3b0d,this['_bindUnboundFramebuffer'](_0x5d3b0d['_MSAAFramebuffer']?_0x5d3b0d['_MSAAFramebuffer']:_0x5d3b0d['_framebuffer']);var _0x57beb3=this['_gl'];_0x5d3b0d['is2DArray']?_0x57beb3['framebufferTextureLayer'](_0x57beb3['FRAMEBUFFER'],_0x57beb3['COLOR_ATTACHMENT0'],_0x5d3b0d['_webGLTexture'],_0x10f9a5,_0xc23d08):_0x5d3b0d['isCube']&&_0x57beb3['framebufferTexture2D'](_0x57beb3['FRAMEBUFFER'],_0x57beb3['COLOR_ATTACHMENT0'],_0x57beb3['TEXTURE_CUBE_MAP_POSITIVE_X']+_0x2ff2b2,_0x5d3b0d['_webGLTexture'],_0x10f9a5);var _0x1cb926=_0x5d3b0d['_depthStencilTexture'];if(_0x1cb926){var _0x1b1a11=_0x1cb926['_generateStencilBuffer']?_0x57beb3['DEPTH_STENCIL_ATTACHMENT']:_0x57beb3['DEPTH_ATTACHMENT'];_0x5d3b0d['is2DArray']?_0x57beb3['framebufferTextureLayer'](_0x57beb3['FRAMEBUFFER'],_0x1b1a11,_0x1cb926['_webGLTexture'],_0x10f9a5,_0xc23d08):_0x5d3b0d['isCube']?_0x57beb3['framebufferTexture2D'](_0x57beb3['FRAMEBUFFER'],_0x1b1a11,_0x57beb3['TEXTURE_CUBE_MAP_POSITIVE_X']+_0x2ff2b2,_0x1cb926['_webGLTexture'],_0x10f9a5):_0x57beb3['framebufferTexture2D'](_0x57beb3['FRAMEBUFFER'],_0x1b1a11,_0x57beb3['TEXTURE_2D'],_0x1cb926['_webGLTexture'],_0x10f9a5);}this['_cachedViewport']&&!_0x2b53e3?this['setViewport'](this['_cachedViewport'],_0x2eea5a,_0x43a2c1):(_0x2eea5a||(_0x2eea5a=_0x5d3b0d['width'],_0x10f9a5&&(_0x2eea5a/=Math['pow'](0x2,_0x10f9a5))),_0x43a2c1||(_0x43a2c1=_0x5d3b0d['height'],_0x10f9a5&&(_0x43a2c1/=Math['pow'](0x2,_0x10f9a5))),this['_viewport'](0x0,0x0,_0x2eea5a,_0x43a2c1)),this['wipeCaches']();},_0x5b5c13['prototype']['_bindUnboundFramebuffer']=function(_0xed492d){this['_currentFramebuffer']!==_0xed492d&&(this['_gl']['bindFramebuffer'](this['_gl']['FRAMEBUFFER'],_0xed492d),this['_currentFramebuffer']=_0xed492d);},_0x5b5c13['prototype']['unBindFramebuffer']=function(_0x435d96,_0x103fd2,_0x11b05f){void 0x0===_0x103fd2&&(_0x103fd2=!0x1),this['_currentRenderTarget']=null;var _0x57f8b0=this['_gl'];if(_0x435d96['_MSAAFramebuffer']){if(_0x435d96['_textureArray'])return void this['unBindMultiColorAttachmentFramebuffer'](_0x435d96['_textureArray'],_0x103fd2,_0x11b05f);_0x57f8b0['bindFramebuffer'](_0x57f8b0['READ_FRAMEBUFFER'],_0x435d96['_MSAAFramebuffer']),_0x57f8b0['bindFramebuffer'](_0x57f8b0['DRAW_FRAMEBUFFER'],_0x435d96['_framebuffer']),_0x57f8b0['blitFramebuffer'](0x0,0x0,_0x435d96['width'],_0x435d96['height'],0x0,0x0,_0x435d96['width'],_0x435d96['height'],_0x57f8b0['COLOR_BUFFER_BIT'],_0x57f8b0['NEAREST']);}!_0x435d96['generateMipMaps']||_0x103fd2||_0x435d96['isCube']||(this['_bindTextureDirectly'](_0x57f8b0['TEXTURE_2D'],_0x435d96,!0x0),_0x57f8b0['generateMipmap'](_0x57f8b0['TEXTURE_2D']),this['_bindTextureDirectly'](_0x57f8b0['TEXTURE_2D'],null)),_0x11b05f&&(_0x435d96['_MSAAFramebuffer']&&this['_bindUnboundFramebuffer'](_0x435d96['_framebuffer']),_0x11b05f()),this['_bindUnboundFramebuffer'](null);},_0x5b5c13['prototype']['flushFramebuffer']=function(){this['_gl']['flush']();},_0x5b5c13['prototype']['restoreDefaultFramebuffer']=function(){this['_currentRenderTarget']?this['unBindFramebuffer'](this['_currentRenderTarget']):this['_bindUnboundFramebuffer'](null),this['_cachedViewport']&&this['setViewport'](this['_cachedViewport']),this['wipeCaches']();},_0x5b5c13['prototype']['_resetVertexBufferBinding']=function(){this['bindArrayBuffer'](null),this['_cachedVertexBuffers']=null;},_0x5b5c13['prototype']['createVertexBuffer']=function(_0x4f86e9){return this['_createVertexBuffer'](_0x4f86e9,this['_gl']['STATIC_DRAW']);},_0x5b5c13['prototype']['_createVertexBuffer']=function(_0x407393,_0x1fe9db){var _0xef7432=this['_gl']['createBuffer']();if(!_0xef7432)throw new Error('Unable\x20to\x20create\x20vertex\x20buffer');var _0x18faef=new _0x2157b1['a'](_0xef7432);return this['bindArrayBuffer'](_0x18faef),_0x407393 instanceof Array?this['_gl']['bufferData'](this['_gl']['ARRAY_BUFFER'],new Float32Array(_0x407393),this['_gl']['STATIC_DRAW']):this['_gl']['bufferData'](this['_gl']['ARRAY_BUFFER'],_0x407393,this['_gl']['STATIC_DRAW']),this['_resetVertexBufferBinding'](),_0x18faef['references']=0x1,_0x18faef;},_0x5b5c13['prototype']['createDynamicVertexBuffer']=function(_0x122b79){return this['_createVertexBuffer'](_0x122b79,this['_gl']['DYNAMIC_DRAW']);},_0x5b5c13['prototype']['_resetIndexBufferBinding']=function(){this['bindIndexBuffer'](null),this['_cachedIndexBuffer']=null;},_0x5b5c13['prototype']['createIndexBuffer']=function(_0x4365a8,_0x375cec){var _0x41ca04=this['_gl']['createBuffer'](),_0x172dcd=new _0x2157b1['a'](_0x41ca04);if(!_0x41ca04)throw new Error('Unable\x20to\x20create\x20index\x20buffer');this['bindIndexBuffer'](_0x172dcd);var _0x1c34bc=this['_normalizeIndexData'](_0x4365a8);return this['_gl']['bufferData'](this['_gl']['ELEMENT_ARRAY_BUFFER'],_0x1c34bc,_0x375cec?this['_gl']['DYNAMIC_DRAW']:this['_gl']['STATIC_DRAW']),this['_resetIndexBufferBinding'](),_0x172dcd['references']=0x1,_0x172dcd['is32Bits']=0x4===_0x1c34bc['BYTES_PER_ELEMENT'],_0x172dcd;},_0x5b5c13['prototype']['_normalizeIndexData']=function(_0x20d700){if(_0x20d700 instanceof Uint16Array)return _0x20d700;if(this['_caps']['uintIndices']){if(_0x20d700 instanceof Uint32Array)return _0x20d700;for(var _0x384814=0x0;_0x384814<_0x20d700['length'];_0x384814++)if(_0x20d700[_0x384814]>=0xffff)return new Uint32Array(_0x20d700);return new Uint16Array(_0x20d700);}return new Uint16Array(_0x20d700);},_0x5b5c13['prototype']['bindArrayBuffer']=function(_0x443027){this['_vaoRecordInProgress']||this['_unbindVertexArrayObject'](),this['bindBuffer'](_0x443027,this['_gl']['ARRAY_BUFFER']);},_0x5b5c13['prototype']['bindUniformBlock']=function(_0x292cbb,_0x480f5c,_0x558fc6){var _0x302adf=_0x292cbb['program'],_0x1933ba=this['_gl']['getUniformBlockIndex'](_0x302adf,_0x480f5c);this['_gl']['uniformBlockBinding'](_0x302adf,_0x1933ba,_0x558fc6);},_0x5b5c13['prototype']['bindIndexBuffer']=function(_0x13d8a8){this['_vaoRecordInProgress']||this['_unbindVertexArrayObject'](),this['bindBuffer'](_0x13d8a8,this['_gl']['ELEMENT_ARRAY_BUFFER']);},_0x5b5c13['prototype']['bindBuffer']=function(_0x11c977,_0x55db7b){(this['_vaoRecordInProgress']||this['_currentBoundBuffer'][_0x55db7b]!==_0x11c977)&&(this['_gl']['bindBuffer'](_0x55db7b,_0x11c977?_0x11c977['underlyingResource']:null),this['_currentBoundBuffer'][_0x55db7b]=_0x11c977);},_0x5b5c13['prototype']['updateArrayBuffer']=function(_0x14257){this['_gl']['bufferSubData'](this['_gl']['ARRAY_BUFFER'],0x0,_0x14257);},_0x5b5c13['prototype']['_vertexAttribPointer']=function(_0x585cdd,_0x519c93,_0x19b9d3,_0x59508c,_0x3ecb65,_0x3da521,_0xd2710f){var _0x457c05=this['_currentBufferPointers'][_0x519c93];if(_0x457c05){var _0xf9eaf9=!0x1;_0x457c05['active']?(_0x457c05['buffer']!==_0x585cdd&&(_0x457c05['buffer']=_0x585cdd,_0xf9eaf9=!0x0),_0x457c05['size']!==_0x19b9d3&&(_0x457c05['size']=_0x19b9d3,_0xf9eaf9=!0x0),_0x457c05['type']!==_0x59508c&&(_0x457c05['type']=_0x59508c,_0xf9eaf9=!0x0),_0x457c05['normalized']!==_0x3ecb65&&(_0x457c05['normalized']=_0x3ecb65,_0xf9eaf9=!0x0),_0x457c05['stride']!==_0x3da521&&(_0x457c05['stride']=_0x3da521,_0xf9eaf9=!0x0),_0x457c05['offset']!==_0xd2710f&&(_0x457c05['offset']=_0xd2710f,_0xf9eaf9=!0x0)):(_0xf9eaf9=!0x0,_0x457c05['active']=!0x0,_0x457c05['index']=_0x519c93,_0x457c05['size']=_0x19b9d3,_0x457c05['type']=_0x59508c,_0x457c05['normalized']=_0x3ecb65,_0x457c05['stride']=_0x3da521,_0x457c05['offset']=_0xd2710f,_0x457c05['buffer']=_0x585cdd),(_0xf9eaf9||this['_vaoRecordInProgress'])&&(this['bindArrayBuffer'](_0x585cdd),this['_gl']['vertexAttribPointer'](_0x519c93,_0x19b9d3,_0x59508c,_0x3ecb65,_0x3da521,_0xd2710f));}},_0x5b5c13['prototype']['_bindIndexBufferWithCache']=function(_0x3c0110){null!=_0x3c0110&&this['_cachedIndexBuffer']!==_0x3c0110&&(this['_cachedIndexBuffer']=_0x3c0110,this['bindIndexBuffer'](_0x3c0110),this['_uintIndicesCurrentlySet']=_0x3c0110['is32Bits']);},_0x5b5c13['prototype']['_bindVertexBuffersAttributes']=function(_0x4f2ebf,_0x97a294){var _0x24af42=_0x97a294['getAttributesNames']();this['_vaoRecordInProgress']||this['_unbindVertexArrayObject'](),this['unbindAllAttributes']();for(var _0x42ddd1=0x0;_0x42ddd1<_0x24af42['length'];_0x42ddd1++){var _0x5577af=_0x97a294['getAttributeLocation'](_0x42ddd1);if(_0x5577af>=0x0){var _0x2bf314=_0x4f2ebf[_0x24af42[_0x42ddd1]];if(!_0x2bf314)continue;this['_gl']['enableVertexAttribArray'](_0x5577af),this['_vaoRecordInProgress']||(this['_vertexAttribArraysEnabled'][_0x5577af]=!0x0);var _0x2cc84f=_0x2bf314['getBuffer']();_0x2cc84f&&(this['_vertexAttribPointer'](_0x2cc84f,_0x5577af,_0x2bf314['getSize'](),_0x2bf314['type'],_0x2bf314['normalized'],_0x2bf314['byteStride'],_0x2bf314['byteOffset']),_0x2bf314['getIsInstanced']()&&(this['_gl']['vertexAttribDivisor'](_0x5577af,_0x2bf314['getInstanceDivisor']()),this['_vaoRecordInProgress']||(this['_currentInstanceLocations']['push'](_0x5577af),this['_currentInstanceBuffers']['push'](_0x2cc84f))));}}},_0x5b5c13['prototype']['recordVertexArrayObject']=function(_0x58d354,_0x34f8c2,_0x27f53f){var _0x3583c0=this['_gl']['createVertexArray']();return this['_vaoRecordInProgress']=!0x0,this['_gl']['bindVertexArray'](_0x3583c0),this['_mustWipeVertexAttributes']=!0x0,this['_bindVertexBuffersAttributes'](_0x58d354,_0x27f53f),this['bindIndexBuffer'](_0x34f8c2),this['_vaoRecordInProgress']=!0x1,this['_gl']['bindVertexArray'](null),_0x3583c0;},_0x5b5c13['prototype']['bindVertexArrayObject']=function(_0x218903,_0x290939){this['_cachedVertexArrayObject']!==_0x218903&&(this['_cachedVertexArrayObject']=_0x218903,this['_gl']['bindVertexArray'](_0x218903),this['_cachedVertexBuffers']=null,this['_cachedIndexBuffer']=null,this['_uintIndicesCurrentlySet']=null!=_0x290939&&_0x290939['is32Bits'],this['_mustWipeVertexAttributes']=!0x0);},_0x5b5c13['prototype']['bindBuffersDirectly']=function(_0x5357a8,_0x487d2d,_0x328262,_0x44c87a,_0x3107a8){if(this['_cachedVertexBuffers']!==_0x5357a8||this['_cachedEffectForVertexBuffers']!==_0x3107a8){this['_cachedVertexBuffers']=_0x5357a8,this['_cachedEffectForVertexBuffers']=_0x3107a8;var _0x47e946=_0x3107a8['getAttributesCount']();this['_unbindVertexArrayObject'](),this['unbindAllAttributes']();for(var _0x4d925f=0x0,_0x3fea75=0x0;_0x3fea75<_0x47e946;_0x3fea75++)if(_0x3fea75<_0x328262['length']){var _0x2e62cd=_0x3107a8['getAttributeLocation'](_0x3fea75);_0x2e62cd>=0x0&&(this['_gl']['enableVertexAttribArray'](_0x2e62cd),this['_vertexAttribArraysEnabled'][_0x2e62cd]=!0x0,this['_vertexAttribPointer'](_0x5357a8,_0x2e62cd,_0x328262[_0x3fea75],this['_gl']['FLOAT'],!0x1,_0x44c87a,_0x4d925f)),_0x4d925f+=0x4*_0x328262[_0x3fea75];}}this['_bindIndexBufferWithCache'](_0x487d2d);},_0x5b5c13['prototype']['_unbindVertexArrayObject']=function(){this['_cachedVertexArrayObject']&&(this['_cachedVertexArrayObject']=null,this['_gl']['bindVertexArray'](null));},_0x5b5c13['prototype']['bindBuffers']=function(_0x31ad64,_0x3c908b,_0xe76a41){this['_cachedVertexBuffers']===_0x31ad64&&this['_cachedEffectForVertexBuffers']===_0xe76a41||(this['_cachedVertexBuffers']=_0x31ad64,this['_cachedEffectForVertexBuffers']=_0xe76a41,this['_bindVertexBuffersAttributes'](_0x31ad64,_0xe76a41)),this['_bindIndexBufferWithCache'](_0x3c908b);},_0x5b5c13['prototype']['unbindInstanceAttributes']=function(){for(var _0x36d84e,_0x2d316=0x0,_0x345576=this['_currentInstanceLocations']['length'];_0x2d316<_0x345576;_0x2d316++){var _0x2486f6=this['_currentInstanceBuffers'][_0x2d316];_0x36d84e!=_0x2486f6&&_0x2486f6['references']&&(_0x36d84e=_0x2486f6,this['bindArrayBuffer'](_0x2486f6));var _0x558176=this['_currentInstanceLocations'][_0x2d316];this['_gl']['vertexAttribDivisor'](_0x558176,0x0);}this['_currentInstanceBuffers']['length']=0x0,this['_currentInstanceLocations']['length']=0x0;},_0x5b5c13['prototype']['releaseVertexArrayObject']=function(_0x314571){this['_gl']['deleteVertexArray'](_0x314571);},_0x5b5c13['prototype']['_releaseBuffer']=function(_0x1d2366){return _0x1d2366['references']--,0x0===_0x1d2366['references']&&(this['_deleteBuffer'](_0x1d2366),!0x0);},_0x5b5c13['prototype']['_deleteBuffer']=function(_0x1d81ca){this['_gl']['deleteBuffer'](_0x1d81ca['underlyingResource']);},_0x5b5c13['prototype']['updateAndBindInstancesBuffer']=function(_0x47ee7b,_0x3dc738,_0x5ee22e){if(this['bindArrayBuffer'](_0x47ee7b),_0x3dc738&&this['_gl']['bufferSubData'](this['_gl']['ARRAY_BUFFER'],0x0,_0x3dc738),void 0x0!==_0x5ee22e[0x0]['index'])this['bindInstancesBuffer'](_0x47ee7b,_0x5ee22e,!0x0);else for(var _0x4410a4=0x0;_0x4410a4<0x4;_0x4410a4++){var _0x1b7b11=_0x5ee22e[_0x4410a4];this['_vertexAttribArraysEnabled'][_0x1b7b11]||(this['_gl']['enableVertexAttribArray'](_0x1b7b11),this['_vertexAttribArraysEnabled'][_0x1b7b11]=!0x0),this['_vertexAttribPointer'](_0x47ee7b,_0x1b7b11,0x4,this['_gl']['FLOAT'],!0x1,0x40,0x10*_0x4410a4),this['_gl']['vertexAttribDivisor'](_0x1b7b11,0x1),this['_currentInstanceLocations']['push'](_0x1b7b11),this['_currentInstanceBuffers']['push'](_0x47ee7b);}},_0x5b5c13['prototype']['bindInstancesBuffer']=function(_0x434163,_0x68d628,_0x508ad3){void 0x0===_0x508ad3&&(_0x508ad3=!0x0),this['bindArrayBuffer'](_0x434163);var _0x3e307b=0x0;if(_0x508ad3)for(var _0x277dde=0x0;_0x277dde<_0x68d628['length'];_0x277dde++){_0x3e307b+=0x4*(_0x4193b0=_0x68d628[_0x277dde])['attributeSize'];}for(_0x277dde=0x0;_0x277dde<_0x68d628['length'];_0x277dde++){var _0x4193b0;void 0x0===(_0x4193b0=_0x68d628[_0x277dde])['index']&&(_0x4193b0['index']=this['_currentEffect']['getAttributeLocationByName'](_0x4193b0['attributeName'])),_0x4193b0['index']<0x0||(this['_vertexAttribArraysEnabled'][_0x4193b0['index']]||(this['_gl']['enableVertexAttribArray'](_0x4193b0['index']),this['_vertexAttribArraysEnabled'][_0x4193b0['index']]=!0x0),this['_vertexAttribPointer'](_0x434163,_0x4193b0['index'],_0x4193b0['attributeSize'],_0x4193b0['attributeType']||this['_gl']['FLOAT'],_0x4193b0['normalized']||!0x1,_0x3e307b,_0x4193b0['offset']),this['_gl']['vertexAttribDivisor'](_0x4193b0['index'],void 0x0===_0x4193b0['divisor']?0x1:_0x4193b0['divisor']),this['_currentInstanceLocations']['push'](_0x4193b0['index']),this['_currentInstanceBuffers']['push'](_0x434163));}},_0x5b5c13['prototype']['disableInstanceAttributeByName']=function(_0x530c54){if(this['_currentEffect']){var _0x44f1da=this['_currentEffect']['getAttributeLocationByName'](_0x530c54);this['disableInstanceAttribute'](_0x44f1da);}},_0x5b5c13['prototype']['disableInstanceAttribute']=function(_0x1b8f01){for(var _0x4545e8,_0x540a6f=!0x1;-0x1!==(_0x4545e8=this['_currentInstanceLocations']['indexOf'](_0x1b8f01));)this['_currentInstanceLocations']['splice'](_0x4545e8,0x1),this['_currentInstanceBuffers']['splice'](_0x4545e8,0x1),_0x540a6f=!0x0,_0x4545e8=this['_currentInstanceLocations']['indexOf'](_0x1b8f01);_0x540a6f&&(this['_gl']['vertexAttribDivisor'](_0x1b8f01,0x0),this['disableAttributeByIndex'](_0x1b8f01));},_0x5b5c13['prototype']['disableAttributeByIndex']=function(_0x293858){this['_gl']['disableVertexAttribArray'](_0x293858),this['_vertexAttribArraysEnabled'][_0x293858]=!0x1,this['_currentBufferPointers'][_0x293858]['active']=!0x1;},_0x5b5c13['prototype']['draw']=function(_0x4bff45,_0x591ed9,_0x25a632,_0x249767){this['drawElementsType'](_0x4bff45?_0x585107['a']['MATERIAL_TriangleFillMode']:_0x585107['a']['MATERIAL_WireFrameFillMode'],_0x591ed9,_0x25a632,_0x249767);},_0x5b5c13['prototype']['drawPointClouds']=function(_0x1a8ef0,_0x5da613,_0x310f2b){this['drawArraysType'](_0x585107['a']['MATERIAL_PointFillMode'],_0x1a8ef0,_0x5da613,_0x310f2b);},_0x5b5c13['prototype']['drawUnIndexed']=function(_0x561886,_0x23093d,_0xa8dcf4,_0x122854){this['drawArraysType'](_0x561886?_0x585107['a']['MATERIAL_TriangleFillMode']:_0x585107['a']['MATERIAL_WireFrameFillMode'],_0x23093d,_0xa8dcf4,_0x122854);},_0x5b5c13['prototype']['drawElementsType']=function(_0x19efc9,_0x4f35b5,_0x1602d4,_0x4fae1a){this['applyStates'](),this['_reportDrawCall']();var _0x13fcf0=this['_drawMode'](_0x19efc9),_0x35901a=this['_uintIndicesCurrentlySet']?this['_gl']['UNSIGNED_INT']:this['_gl']['UNSIGNED_SHORT'],_0x22ce11=this['_uintIndicesCurrentlySet']?0x4:0x2;_0x4fae1a?this['_gl']['drawElementsInstanced'](_0x13fcf0,_0x1602d4,_0x35901a,_0x4f35b5*_0x22ce11,_0x4fae1a):this['_gl']['drawElements'](_0x13fcf0,_0x1602d4,_0x35901a,_0x4f35b5*_0x22ce11);},_0x5b5c13['prototype']['drawArraysType']=function(_0x5c4b26,_0x73a455,_0x28a2aa,_0x22423a){this['applyStates'](),this['_reportDrawCall']();var _0x3b8836=this['_drawMode'](_0x5c4b26);_0x22423a?this['_gl']['drawArraysInstanced'](_0x3b8836,_0x73a455,_0x28a2aa,_0x22423a):this['_gl']['drawArrays'](_0x3b8836,_0x73a455,_0x28a2aa);},_0x5b5c13['prototype']['_drawMode']=function(_0x3bab4d){switch(_0x3bab4d){case _0x585107['a']['MATERIAL_TriangleFillMode']:return this['_gl']['TRIANGLES'];case _0x585107['a']['MATERIAL_PointFillMode']:return this['_gl']['POINTS'];case _0x585107['a']['MATERIAL_WireFrameFillMode']:return this['_gl']['LINES'];case _0x585107['a']['MATERIAL_PointListDrawMode']:return this['_gl']['POINTS'];case _0x585107['a']['MATERIAL_LineListDrawMode']:return this['_gl']['LINES'];case _0x585107['a']['MATERIAL_LineLoopDrawMode']:return this['_gl']['LINE_LOOP'];case _0x585107['a']['MATERIAL_LineStripDrawMode']:return this['_gl']['LINE_STRIP'];case _0x585107['a']['MATERIAL_TriangleStripDrawMode']:return this['_gl']['TRIANGLE_STRIP'];case _0x585107['a']['MATERIAL_TriangleFanDrawMode']:return this['_gl']['TRIANGLE_FAN'];default:return this['_gl']['TRIANGLES'];}},_0x5b5c13['prototype']['_reportDrawCall']=function(){},_0x5b5c13['prototype']['_releaseEffect']=function(_0x4d26a7){this['_compiledEffects'][_0x4d26a7['_key']]&&(delete this['_compiledEffects'][_0x4d26a7['_key']],this['_deletePipelineContext'](_0x4d26a7['getPipelineContext']()));},_0x5b5c13['prototype']['_deletePipelineContext']=function(_0x3c00ff){var _0x25cd27=_0x3c00ff;_0x25cd27&&_0x25cd27['program']&&(_0x25cd27['program']['__SPECTOR_rebuildProgram']=null,this['_gl']['deleteProgram'](_0x25cd27['program']));},_0x5b5c13['prototype']['createEffect']=function(_0x1a5887,_0x171be7,_0x1a33be,_0xe1c9d5,_0x9b50a4,_0x4ca1d4,_0x57a3fb,_0x231708,_0xf20119){var _0x2b796b=(_0x1a5887['vertexElement']||_0x1a5887['vertex']||_0x1a5887['vertexToken']||_0x1a5887['vertexSource']||_0x1a5887)+'+'+(_0x1a5887['fragmentElement']||_0x1a5887['fragment']||_0x1a5887['fragmentToken']||_0x1a5887['fragmentSource']||_0x1a5887)+'@'+(_0x9b50a4||_0x171be7['defines']);if(this['_compiledEffects'][_0x2b796b]){var _0x2e9643=this['_compiledEffects'][_0x2b796b];return _0x57a3fb&&_0x2e9643['isReady']()&&_0x57a3fb(_0x2e9643),_0x2e9643;}var _0x3b590d=new _0x589ad5['a'](_0x1a5887,_0x171be7,_0x1a33be,_0xe1c9d5,this,_0x9b50a4,_0x4ca1d4,_0x57a3fb,_0x231708,_0xf20119);return _0x3b590d['_key']=_0x2b796b,this['_compiledEffects'][_0x2b796b]=_0x3b590d,_0x3b590d;},_0x5b5c13['_ConcatenateShader']=function(_0x4d61e1,_0x23fb80,_0x15e27b){return void 0x0===_0x15e27b&&(_0x15e27b=''),_0x15e27b+(_0x23fb80?_0x23fb80+'\x0a':'')+_0x4d61e1;},_0x5b5c13['prototype']['_compileShader']=function(_0x464202,_0x587974,_0x2f34a3,_0x4a5ef6){return this['_compileRawShader'](_0x5b5c13['_ConcatenateShader'](_0x464202,_0x2f34a3,_0x4a5ef6),_0x587974);},_0x5b5c13['prototype']['_compileRawShader']=function(_0x39bcf2,_0x274d94){var _0x3ba585=this['_gl'],_0x3c862c=_0x3ba585['createShader']('vertex'===_0x274d94?_0x3ba585['VERTEX_SHADER']:_0x3ba585['FRAGMENT_SHADER']);if(!_0x3c862c)throw new Error('Something\x20went\x20wrong\x20while\x20compile\x20the\x20shader.');return _0x3ba585['shaderSource'](_0x3c862c,_0x39bcf2),_0x3ba585['compileShader'](_0x3c862c),_0x3c862c;},_0x5b5c13['prototype']['_getShaderSource']=function(_0x287cb7){return this['_gl']['getShaderSource'](_0x287cb7);},_0x5b5c13['prototype']['createRawShaderProgram']=function(_0xca4106,_0x1533b9,_0x32f160,_0x3d5354,_0x1ac63c){void 0x0===_0x1ac63c&&(_0x1ac63c=null),_0x3d5354=_0x3d5354||this['_gl'];var _0x33a2a4=this['_compileRawShader'](_0x1533b9,'vertex'),_0x7f356e=this['_compileRawShader'](_0x32f160,'fragment');return this['_createShaderProgram'](_0xca4106,_0x33a2a4,_0x7f356e,_0x3d5354,_0x1ac63c);},_0x5b5c13['prototype']['createShaderProgram']=function(_0x6c9732,_0x407eab,_0x1ca553,_0x192225,_0x19ff9c,_0xf2e1f6){void 0x0===_0xf2e1f6&&(_0xf2e1f6=null),_0x19ff9c=_0x19ff9c||this['_gl'];var _0xd3943e=this['_webGLVersion']>0x1?'#version\x20300\x20es\x0a#define\x20WEBGL2\x20\x0a':'',_0x3babf9=this['_compileShader'](_0x407eab,'vertex',_0x192225,_0xd3943e),_0x10646e=this['_compileShader'](_0x1ca553,'fragment',_0x192225,_0xd3943e);return this['_createShaderProgram'](_0x6c9732,_0x3babf9,_0x10646e,_0x19ff9c,_0xf2e1f6);},_0x5b5c13['prototype']['createPipelineContext']=function(){var _0x4ba185=new _0x9fd0de['a']();return _0x4ba185['engine']=this,this['_caps']['parallelShaderCompile']&&(_0x4ba185['isParallelCompiled']=!0x0),_0x4ba185;},_0x5b5c13['prototype']['_createShaderProgram']=function(_0x5ebd4b,_0x3ca04c,_0x42500c,_0x5bb12f,_0x3f6152){void 0x0===_0x3f6152&&(_0x3f6152=null);var _0x40ab79=_0x5bb12f['createProgram']();if(_0x5ebd4b['program']=_0x40ab79,!_0x40ab79)throw new Error('Unable\x20to\x20create\x20program');return _0x5bb12f['attachShader'](_0x40ab79,_0x3ca04c),_0x5bb12f['attachShader'](_0x40ab79,_0x42500c),_0x5bb12f['linkProgram'](_0x40ab79),_0x5ebd4b['context']=_0x5bb12f,_0x5ebd4b['vertexShader']=_0x3ca04c,_0x5ebd4b['fragmentShader']=_0x42500c,_0x5ebd4b['isParallelCompiled']||this['_finalizePipelineContext'](_0x5ebd4b),_0x40ab79;},_0x5b5c13['prototype']['_finalizePipelineContext']=function(_0xa18cfd){var _0x4eaeed=_0xa18cfd['context'],_0x3ee47e=_0xa18cfd['vertexShader'],_0x47a3c5=_0xa18cfd['fragmentShader'],_0x188c69=_0xa18cfd['program'];if(!_0x4eaeed['getProgramParameter'](_0x188c69,_0x4eaeed['LINK_STATUS'])){var _0x218fa5,_0x377059;if(!this['_gl']['getShaderParameter'](_0x3ee47e,this['_gl']['COMPILE_STATUS'])){if(_0x218fa5=this['_gl']['getShaderInfoLog'](_0x3ee47e))throw _0xa18cfd['vertexCompilationError']=_0x218fa5,new Error('VERTEX\x20SHADER\x20'+_0x218fa5);}if(!this['_gl']['getShaderParameter'](_0x47a3c5,this['_gl']['COMPILE_STATUS'])){if(_0x218fa5=this['_gl']['getShaderInfoLog'](_0x47a3c5))throw _0xa18cfd['fragmentCompilationError']=_0x218fa5,new Error('FRAGMENT\x20SHADER\x20'+_0x218fa5);}if(_0x377059=_0x4eaeed['getProgramInfoLog'](_0x188c69))throw _0xa18cfd['programLinkError']=_0x377059,new Error(_0x377059);}if(this['validateShaderPrograms']&&(_0x4eaeed['validateProgram'](_0x188c69),!_0x4eaeed['getProgramParameter'](_0x188c69,_0x4eaeed['VALIDATE_STATUS'])&&(_0x377059=_0x4eaeed['getProgramInfoLog'](_0x188c69))))throw _0xa18cfd['programValidationError']=_0x377059,new Error(_0x377059);_0x4eaeed['deleteShader'](_0x3ee47e),_0x4eaeed['deleteShader'](_0x47a3c5),_0xa18cfd['vertexShader']=void 0x0,_0xa18cfd['fragmentShader']=void 0x0,_0xa18cfd['onCompiled']&&(_0xa18cfd['onCompiled'](),_0xa18cfd['onCompiled']=void 0x0);},_0x5b5c13['prototype']['_preparePipelineContext']=function(_0x262e50,_0x2a91c4,_0x2e51bd,_0x2f18e8,_0x5bbd90,_0x2e68d8,_0x35c23d){var _0x452c6a=_0x262e50;_0x452c6a['program']=_0x2f18e8?this['createRawShaderProgram'](_0x452c6a,_0x2a91c4,_0x2e51bd,void 0x0,_0x35c23d):this['createShaderProgram'](_0x452c6a,_0x2a91c4,_0x2e51bd,_0x2e68d8,void 0x0,_0x35c23d),_0x452c6a['program']['__SPECTOR_rebuildProgram']=_0x5bbd90;},_0x5b5c13['prototype']['_isRenderingStateCompiled']=function(_0x18aad8){var _0xe9a4d=_0x18aad8;return!!this['_gl']['getProgramParameter'](_0xe9a4d['program'],this['_caps']['parallelShaderCompile']['COMPLETION_STATUS_KHR'])&&(this['_finalizePipelineContext'](_0xe9a4d),!0x0);},_0x5b5c13['prototype']['_executeWhenRenderingStateIsCompiled']=function(_0x5ed4d8,_0x48df55){var _0x2737c2=_0x5ed4d8;if(_0x2737c2['isParallelCompiled']){var _0x208f03=_0x2737c2['onCompiled'];_0x2737c2['onCompiled']=_0x208f03?function(){_0x208f03(),_0x48df55();}:_0x48df55;}else _0x48df55();},_0x5b5c13['prototype']['getUniforms']=function(_0x48dded,_0x13161e){for(var _0xc149d4=new Array(),_0x254f59=_0x48dded,_0x58db51=0x0;_0x58db51<_0x13161e['length'];_0x58db51++)_0xc149d4['push'](this['_gl']['getUniformLocation'](_0x254f59['program'],_0x13161e[_0x58db51]));return _0xc149d4;},_0x5b5c13['prototype']['getAttributes']=function(_0x5c67b2,_0x29a43c){for(var _0x5b2270=[],_0x3ecaf6=_0x5c67b2,_0x2d1337=0x0;_0x2d1337<_0x29a43c['length'];_0x2d1337++)try{_0x5b2270['push'](this['_gl']['getAttribLocation'](_0x3ecaf6['program'],_0x29a43c[_0x2d1337]));}catch(_0x4c35ad){_0x5b2270['push'](-0x1);}return _0x5b2270;},_0x5b5c13['prototype']['enableEffect']=function(_0x51e1bb){_0x51e1bb&&_0x51e1bb!==this['_currentEffect']&&(this['bindSamplers'](_0x51e1bb),this['_currentEffect']=_0x51e1bb,_0x51e1bb['onBind']&&_0x51e1bb['onBind'](_0x51e1bb),_0x51e1bb['_onBindObservable']&&_0x51e1bb['_onBindObservable']['notifyObservers'](_0x51e1bb));},_0x5b5c13['prototype']['setInt']=function(_0x58d22b,_0x23a613){return!!_0x58d22b&&(this['_gl']['uniform1i'](_0x58d22b,_0x23a613),!0x0);},_0x5b5c13['prototype']['setIntArray']=function(_0x88d729,_0x1c02f0){return!!_0x88d729&&(this['_gl']['uniform1iv'](_0x88d729,_0x1c02f0),!0x0);},_0x5b5c13['prototype']['setIntArray2']=function(_0x51a0a6,_0x144cb8){return!(!_0x51a0a6||_0x144cb8['length']%0x2!=0x0)&&(this['_gl']['uniform2iv'](_0x51a0a6,_0x144cb8),!0x0);},_0x5b5c13['prototype']['setIntArray3']=function(_0x454071,_0x5c75e5){return!(!_0x454071||_0x5c75e5['length']%0x3!=0x0)&&(this['_gl']['uniform3iv'](_0x454071,_0x5c75e5),!0x0);},_0x5b5c13['prototype']['setIntArray4']=function(_0x15374a,_0x483e14){return!(!_0x15374a||_0x483e14['length']%0x4!=0x0)&&(this['_gl']['uniform4iv'](_0x15374a,_0x483e14),!0x0);},_0x5b5c13['prototype']['setArray']=function(_0x192246,_0x5844fb){return!!_0x192246&&(this['_gl']['uniform1fv'](_0x192246,_0x5844fb),!0x0);},_0x5b5c13['prototype']['setArray2']=function(_0xdfd12d,_0x5a0eab){return!(!_0xdfd12d||_0x5a0eab['length']%0x2!=0x0)&&(this['_gl']['uniform2fv'](_0xdfd12d,_0x5a0eab),!0x0);},_0x5b5c13['prototype']['setArray3']=function(_0x445369,_0xc162a1){return!(!_0x445369||_0xc162a1['length']%0x3!=0x0)&&(this['_gl']['uniform3fv'](_0x445369,_0xc162a1),!0x0);},_0x5b5c13['prototype']['setArray4']=function(_0x12456e,_0x370700){return!(!_0x12456e||_0x370700['length']%0x4!=0x0)&&(this['_gl']['uniform4fv'](_0x12456e,_0x370700),!0x0);},_0x5b5c13['prototype']['setMatrices']=function(_0x308749,_0x3f8271){return!!_0x308749&&(this['_gl']['uniformMatrix4fv'](_0x308749,!0x1,_0x3f8271),!0x0);},_0x5b5c13['prototype']['setMatrix3x3']=function(_0x4f2e79,_0x44e569){return!!_0x4f2e79&&(this['_gl']['uniformMatrix3fv'](_0x4f2e79,!0x1,_0x44e569),!0x0);},_0x5b5c13['prototype']['setMatrix2x2']=function(_0x5b226f,_0x3a71f0){return!!_0x5b226f&&(this['_gl']['uniformMatrix2fv'](_0x5b226f,!0x1,_0x3a71f0),!0x0);},_0x5b5c13['prototype']['setFloat']=function(_0x4afb83,_0x438497){return!!_0x4afb83&&(this['_gl']['uniform1f'](_0x4afb83,_0x438497),!0x0);},_0x5b5c13['prototype']['setFloat2']=function(_0x3dcd7a,_0x2936d3,_0x1eec15){return!!_0x3dcd7a&&(this['_gl']['uniform2f'](_0x3dcd7a,_0x2936d3,_0x1eec15),!0x0);},_0x5b5c13['prototype']['setFloat3']=function(_0x5c646c,_0x4bca1b,_0x419061,_0x375b8f){return!!_0x5c646c&&(this['_gl']['uniform3f'](_0x5c646c,_0x4bca1b,_0x419061,_0x375b8f),!0x0);},_0x5b5c13['prototype']['setFloat4']=function(_0x1185d9,_0x20a9be,_0x49e14c,_0x4be351,_0x517082){return!!_0x1185d9&&(this['_gl']['uniform4f'](_0x1185d9,_0x20a9be,_0x49e14c,_0x4be351,_0x517082),!0x0);},_0x5b5c13['prototype']['applyStates']=function(){if(this['_depthCullingState']['apply'](this['_gl']),this['_stencilState']['apply'](this['_gl']),this['_alphaState']['apply'](this['_gl']),this['_colorWriteChanged']){this['_colorWriteChanged']=!0x1;var _0x8b87c8=this['_colorWrite'];this['_gl']['colorMask'](_0x8b87c8,_0x8b87c8,_0x8b87c8,_0x8b87c8);}},_0x5b5c13['prototype']['setColorWrite']=function(_0x17f0fe){_0x17f0fe!==this['_colorWrite']&&(this['_colorWriteChanged']=!0x0,this['_colorWrite']=_0x17f0fe);},_0x5b5c13['prototype']['getColorWrite']=function(){return this['_colorWrite'];},Object['defineProperty'](_0x5b5c13['prototype'],'depthCullingState',{'get':function(){return this['_depthCullingState'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5b5c13['prototype'],'alphaState',{'get':function(){return this['_alphaState'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5b5c13['prototype'],'stencilState',{'get':function(){return this['_stencilState'];},'enumerable':!0x1,'configurable':!0x0}),_0x5b5c13['prototype']['clearInternalTexturesCache']=function(){this['_internalTexturesCache']=[];},_0x5b5c13['prototype']['wipeCaches']=function(_0x58ce1a){this['preventCacheWipeBetweenFrames']&&!_0x58ce1a||(this['_currentEffect']=null,this['_viewportCached']['x']=0x0,this['_viewportCached']['y']=0x0,this['_viewportCached']['z']=0x0,this['_viewportCached']['w']=0x0,this['_unbindVertexArrayObject'](),_0x58ce1a&&(this['_currentProgram']=null,this['resetTextureCache'](),this['_stencilState']['reset'](),this['_depthCullingState']['reset'](),this['_depthCullingState']['depthFunc']=this['_gl']['LEQUAL'],this['_alphaState']['reset'](),this['_alphaMode']=_0x585107['a']['ALPHA_ADD'],this['_alphaEquation']=_0x585107['a']['ALPHA_DISABLE'],this['_colorWrite']=!0x0,this['_colorWriteChanged']=!0x0,this['_unpackFlipYCached']=null,this['_gl']['pixelStorei'](this['_gl']['UNPACK_COLORSPACE_CONVERSION_WEBGL'],this['_gl']['NONE']),this['_gl']['pixelStorei'](this['_gl']['UNPACK_PREMULTIPLY_ALPHA_WEBGL'],0x0),this['_mustWipeVertexAttributes']=!0x0,this['unbindAllAttributes']()),this['_resetVertexBufferBinding'](),this['_cachedIndexBuffer']=null,this['_cachedEffectForVertexBuffers']=null,this['bindIndexBuffer'](null));},_0x5b5c13['prototype']['_getSamplingParameters']=function(_0x497614,_0x8da5b3){var _0x1e4485=this['_gl'],_0x2a25fd=_0x1e4485['NEAREST'],_0xee9a5c=_0x1e4485['NEAREST'];switch(_0x497614){case _0x585107['a']['TEXTURE_LINEAR_LINEAR_MIPNEAREST']:_0x2a25fd=_0x1e4485['LINEAR'],_0xee9a5c=_0x8da5b3?_0x1e4485['LINEAR_MIPMAP_NEAREST']:_0x1e4485['LINEAR'];break;case _0x585107['a']['TEXTURE_LINEAR_LINEAR_MIPLINEAR']:_0x2a25fd=_0x1e4485['LINEAR'],_0xee9a5c=_0x8da5b3?_0x1e4485['LINEAR_MIPMAP_LINEAR']:_0x1e4485['LINEAR'];break;case _0x585107['a']['TEXTURE_NEAREST_NEAREST_MIPLINEAR']:_0x2a25fd=_0x1e4485['NEAREST'],_0xee9a5c=_0x8da5b3?_0x1e4485['NEAREST_MIPMAP_LINEAR']:_0x1e4485['NEAREST'];break;case _0x585107['a']['TEXTURE_NEAREST_NEAREST_MIPNEAREST']:_0x2a25fd=_0x1e4485['NEAREST'],_0xee9a5c=_0x8da5b3?_0x1e4485['NEAREST_MIPMAP_NEAREST']:_0x1e4485['NEAREST'];break;case _0x585107['a']['TEXTURE_NEAREST_LINEAR_MIPNEAREST']:_0x2a25fd=_0x1e4485['NEAREST'],_0xee9a5c=_0x8da5b3?_0x1e4485['LINEAR_MIPMAP_NEAREST']:_0x1e4485['LINEAR'];break;case _0x585107['a']['TEXTURE_NEAREST_LINEAR_MIPLINEAR']:_0x2a25fd=_0x1e4485['NEAREST'],_0xee9a5c=_0x8da5b3?_0x1e4485['LINEAR_MIPMAP_LINEAR']:_0x1e4485['LINEAR'];break;case _0x585107['a']['TEXTURE_NEAREST_LINEAR']:_0x2a25fd=_0x1e4485['NEAREST'],_0xee9a5c=_0x1e4485['LINEAR'];break;case _0x585107['a']['TEXTURE_NEAREST_NEAREST']:_0x2a25fd=_0x1e4485['NEAREST'],_0xee9a5c=_0x1e4485['NEAREST'];break;case _0x585107['a']['TEXTURE_LINEAR_NEAREST_MIPNEAREST']:_0x2a25fd=_0x1e4485['LINEAR'],_0xee9a5c=_0x8da5b3?_0x1e4485['NEAREST_MIPMAP_NEAREST']:_0x1e4485['NEAREST'];break;case _0x585107['a']['TEXTURE_LINEAR_NEAREST_MIPLINEAR']:_0x2a25fd=_0x1e4485['LINEAR'],_0xee9a5c=_0x8da5b3?_0x1e4485['NEAREST_MIPMAP_LINEAR']:_0x1e4485['NEAREST'];break;case _0x585107['a']['TEXTURE_LINEAR_LINEAR']:_0x2a25fd=_0x1e4485['LINEAR'],_0xee9a5c=_0x1e4485['LINEAR'];break;case _0x585107['a']['TEXTURE_LINEAR_NEAREST']:_0x2a25fd=_0x1e4485['LINEAR'],_0xee9a5c=_0x1e4485['NEAREST'];}return{'min':_0xee9a5c,'mag':_0x2a25fd};},_0x5b5c13['prototype']['_createTexture']=function(){var _0x3b2ff5=this['_gl']['createTexture']();if(!_0x3b2ff5)throw new Error('Unable\x20to\x20create\x20texture');return _0x3b2ff5;},_0x5b5c13['prototype']['createTexture']=function(_0x244e08,_0x4ae980,_0x46bf5a,_0x1b78f4,_0x128565,_0x3bae07,_0x5568bd,_0x34f58e,_0x791fa,_0x68bfc0,_0x108834,_0x47695c,_0x37a421){var _0x252f8a=this;void 0x0===_0x128565&&(_0x128565=_0x585107['a']['TEXTURE_TRILINEAR_SAMPLINGMODE']),void 0x0===_0x3bae07&&(_0x3bae07=null),void 0x0===_0x5568bd&&(_0x5568bd=null),void 0x0===_0x34f58e&&(_0x34f58e=null),void 0x0===_0x791fa&&(_0x791fa=null),void 0x0===_0x68bfc0&&(_0x68bfc0=null),void 0x0===_0x108834&&(_0x108834=null);var _0x2b5c34='data:'===(_0x244e08=_0x244e08||'')['substr'](0x0,0x5),_0x345c7a='blob:'===_0x244e08['substr'](0x0,0x5),_0x2faf0a=_0x2b5c34&&-0x1!==_0x244e08['indexOf'](';base64,'),_0x59fce0=_0x791fa||new _0x226a67['a'](this,_0x226a67['b']['Url']),_0x4bb7c8=_0x244e08;!this['_transformTextureUrl']||_0x2faf0a||_0x791fa||_0x34f58e||(_0x244e08=this['_transformTextureUrl'](_0x244e08)),_0x4bb7c8!==_0x244e08&&(_0x59fce0['_originalUrl']=_0x4bb7c8);var _0x12edce=_0x244e08['lastIndexOf']('.'),_0xb17fd9=_0x108834||(_0x12edce>-0x1?_0x244e08['substring'](_0x12edce)['toLowerCase']():''),_0x359d13=null;_0xb17fd9['indexOf']('?')>-0x1&&(_0xb17fd9=_0xb17fd9['split']('?')[0x0]);for(var _0x1b58fd=0x0,_0x14ece9=_0x5b5c13['_TextureLoaders'];_0x1b58fd<_0x14ece9['length'];_0x1b58fd++){var _0x487560=_0x14ece9[_0x1b58fd];if(_0x487560['canLoad'](_0xb17fd9,_0x47695c)){_0x359d13=_0x487560;break;}}_0x1b78f4&&_0x1b78f4['_addPendingData'](_0x59fce0),_0x59fce0['url']=_0x244e08,_0x59fce0['generateMipMaps']=!_0x4ae980,_0x59fce0['samplingMode']=_0x128565,_0x59fce0['invertY']=_0x46bf5a,this['_doNotHandleContextLost']||(_0x59fce0['_buffer']=_0x34f58e);var _0x1f6ad2=null;_0x3bae07&&!_0x791fa&&(_0x1f6ad2=_0x59fce0['onLoadedObservable']['add'](_0x3bae07)),_0x791fa||this['_internalTexturesCache']['push'](_0x59fce0);var _0x22ab92=function(_0x459242,_0x542c9a){_0x1b78f4&&_0x1b78f4['_removePendingData'](_0x59fce0),_0x244e08===_0x4bb7c8?(_0x1f6ad2&&_0x59fce0['onLoadedObservable']['remove'](_0x1f6ad2),_0x58c4cf['a']['UseFallbackTexture']&&_0x252f8a['createTexture'](_0x58c4cf['a']['FallbackTexture'],_0x4ae980,_0x59fce0['invertY'],_0x1b78f4,_0x128565,null,_0x5568bd,_0x34f58e,_0x59fce0),_0x5568bd&&_0x5568bd((_0x459242||'Unknown\x20error')+(_0x58c4cf['a']['UseFallbackTexture']?'\x20-\x20Fallback\x20texture\x20was\x20used':''),_0x542c9a)):(_0x4f5c06['a']['Warn']('Failed\x20to\x20load\x20'+_0x244e08+',\x20falling\x20back\x20to\x20'+_0x4bb7c8),_0x252f8a['createTexture'](_0x4bb7c8,_0x4ae980,_0x59fce0['invertY'],_0x1b78f4,_0x128565,_0x3bae07,_0x5568bd,_0x34f58e,_0x59fce0,_0x68bfc0,_0x108834,_0x47695c,_0x37a421));};if(_0x359d13){var _0x2ef108=function(_0x4017fb){_0x359d13['loadData'](_0x4017fb,_0x59fce0,function(_0x31b6ba,_0x35f350,_0x3c62ed,_0x2ae691,_0x299f81,_0x40cb44){_0x40cb44?_0x22ab92('TextureLoader\x20failed\x20to\x20load\x20data'):_0x252f8a['_prepareWebGLTexture'](_0x59fce0,_0x1b78f4,_0x31b6ba,_0x35f350,_0x59fce0['invertY'],!_0x3c62ed,_0x2ae691,function(){return _0x299f81(),!0x1;},_0x128565);},_0x37a421);};_0x34f58e?_0x34f58e instanceof ArrayBuffer?_0x2ef108(new Uint8Array(_0x34f58e)):ArrayBuffer['isView'](_0x34f58e)?_0x2ef108(_0x34f58e):_0x5568bd&&_0x5568bd('Unable\x20to\x20load:\x20only\x20ArrayBuffer\x20or\x20ArrayBufferView\x20is\x20supported',null):this['_loadFile'](_0x244e08,function(_0x55a2b9){return _0x2ef108(new Uint8Array(_0x55a2b9));},void 0x0,_0x1b78f4?_0x1b78f4['offlineProvider']:void 0x0,!0x0,function(_0x3864a6,_0x54584b){_0x22ab92('Unable\x20to\x20load\x20'+(_0x3864a6&&_0x3864a6['responseURL'],_0x54584b));});}else{var _0x5cc72c=function(_0x5be3e5){_0x345c7a&&!_0x252f8a['_doNotHandleContextLost']&&(_0x59fce0['_buffer']=_0x5be3e5),_0x252f8a['_prepareWebGLTexture'](_0x59fce0,_0x1b78f4,_0x5be3e5['width'],_0x5be3e5['height'],_0x59fce0['invertY'],_0x4ae980,!0x1,function(_0x330551,_0x3edffc,_0x1a264d){var _0x10d852=_0x252f8a['_gl'],_0x5156eb=_0x5be3e5['width']===_0x330551&&_0x5be3e5['height']===_0x3edffc,_0x5abcc4=_0x68bfc0?_0x252f8a['_getInternalFormat'](_0x68bfc0):'.jpg'===_0xb17fd9?_0x10d852['RGB']:_0x10d852['RGBA'];if(_0x5156eb)return _0x10d852['texImage2D'](_0x10d852['TEXTURE_2D'],0x0,_0x5abcc4,_0x5abcc4,_0x10d852['UNSIGNED_BYTE'],_0x5be3e5),!0x1;var _0x4b1644=_0x252f8a['_caps']['maxTextureSize'];if(_0x5be3e5['width']>_0x4b1644||_0x5be3e5['height']>_0x4b1644||!_0x252f8a['_supportsHardwareTextureRescaling'])return _0x252f8a['_prepareWorkingCanvas'](),!(!_0x252f8a['_workingCanvas']||!_0x252f8a['_workingContext'])&&(_0x252f8a['_workingCanvas']['width']=_0x330551,_0x252f8a['_workingCanvas']['height']=_0x3edffc,_0x252f8a['_workingContext']['drawImage'](_0x5be3e5,0x0,0x0,_0x5be3e5['width'],_0x5be3e5['height'],0x0,0x0,_0x330551,_0x3edffc),_0x10d852['texImage2D'](_0x10d852['TEXTURE_2D'],0x0,_0x5abcc4,_0x5abcc4,_0x10d852['UNSIGNED_BYTE'],_0x252f8a['_workingCanvas']),_0x59fce0['width']=_0x330551,_0x59fce0['height']=_0x3edffc,!0x1);var _0x79450=new _0x226a67['a'](_0x252f8a,_0x226a67['b']['Temp']);return _0x252f8a['_bindTextureDirectly'](_0x10d852['TEXTURE_2D'],_0x79450,!0x0),_0x10d852['texImage2D'](_0x10d852['TEXTURE_2D'],0x0,_0x5abcc4,_0x5abcc4,_0x10d852['UNSIGNED_BYTE'],_0x5be3e5),_0x252f8a['_rescaleTexture'](_0x79450,_0x59fce0,_0x1b78f4,_0x5abcc4,function(){_0x252f8a['_releaseTexture'](_0x79450),_0x252f8a['_bindTextureDirectly'](_0x10d852['TEXTURE_2D'],_0x59fce0,!0x0),_0x1a264d();}),!0x0;},_0x128565);};!_0x2b5c34||_0x2faf0a?_0x34f58e&&(_0x34f58e['decoding']||_0x34f58e['close'])?_0x5cc72c(_0x34f58e):_0x5b5c13['_FileToolsLoadImage'](_0x244e08,_0x5cc72c,_0x22ab92,_0x1b78f4?_0x1b78f4['offlineProvider']:null,_0x47695c):'string'==typeof _0x34f58e||_0x34f58e instanceof ArrayBuffer||ArrayBuffer['isView'](_0x34f58e)||_0x34f58e instanceof Blob?_0x5b5c13['_FileToolsLoadImage'](_0x34f58e,_0x5cc72c,_0x22ab92,_0x1b78f4?_0x1b78f4['offlineProvider']:null,_0x47695c):_0x34f58e&&_0x5cc72c(_0x34f58e);}return _0x59fce0;},_0x5b5c13['_FileToolsLoadImage']=function(_0x40ab6d,_0x3f58f0,_0x5433b6,_0x174805,_0xc932cb){throw _0x826132['a']['WarnImport']('FileTools');},_0x5b5c13['prototype']['_rescaleTexture']=function(_0x465200,_0x3b8b0f,_0x33efb6,_0x3b3d9c,_0x211b83){},_0x5b5c13['prototype']['createRawTexture']=function(_0xd6292e,_0x428777,_0x3d97e9,_0x2390e2,_0x559199,_0x291932,_0x6b3b68,_0x4247d2,_0x45d550){throw void 0x0===_0x4247d2&&(_0x4247d2=null),void 0x0===_0x45d550&&(_0x45d550=_0x585107['a']['TEXTURETYPE_UNSIGNED_INT']),_0x826132['a']['WarnImport']('Engine.RawTexture');},_0x5b5c13['prototype']['createRawCubeTexture']=function(_0x366e1c,_0x469e93,_0x254692,_0x2266e9,_0x3878ba,_0x4d8f1e,_0x541690,_0x2ab962){throw void 0x0===_0x2ab962&&(_0x2ab962=null),_0x826132['a']['WarnImport']('Engine.RawTexture');},_0x5b5c13['prototype']['createRawTexture3D']=function(_0xf6542d,_0x1cf869,_0x4826f2,_0x24984d,_0x277de0,_0x55efd3,_0x12ef91,_0x3c5715,_0x5bbddb,_0x506f2f){throw void 0x0===_0x5bbddb&&(_0x5bbddb=null),void 0x0===_0x506f2f&&(_0x506f2f=_0x585107['a']['TEXTURETYPE_UNSIGNED_INT']),_0x826132['a']['WarnImport']('Engine.RawTexture');},_0x5b5c13['prototype']['createRawTexture2DArray']=function(_0x51c523,_0x196648,_0x3908c1,_0x82e13c,_0x50b9bf,_0x33c51b,_0x12b4da,_0x1ac6fd,_0x3efc6f,_0x573f90){throw void 0x0===_0x3efc6f&&(_0x3efc6f=null),void 0x0===_0x573f90&&(_0x573f90=_0x585107['a']['TEXTURETYPE_UNSIGNED_INT']),_0x826132['a']['WarnImport']('Engine.RawTexture');},_0x5b5c13['prototype']['_unpackFlipY']=function(_0x17a60f){this['_unpackFlipYCached']!==_0x17a60f&&(this['_gl']['pixelStorei'](this['_gl']['UNPACK_FLIP_Y_WEBGL'],_0x17a60f?0x1:0x0),this['enableUnpackFlipYCached']&&(this['_unpackFlipYCached']=_0x17a60f));},_0x5b5c13['prototype']['_getUnpackAlignement']=function(){return this['_gl']['getParameter'](this['_gl']['UNPACK_ALIGNMENT']);},_0x5b5c13['prototype']['_getTextureTarget']=function(_0xa60f99){return _0xa60f99['isCube']?this['_gl']['TEXTURE_CUBE_MAP']:_0xa60f99['is3D']?this['_gl']['TEXTURE_3D']:_0xa60f99['is2DArray']||_0xa60f99['isMultiview']?this['_gl']['TEXTURE_2D_ARRAY']:this['_gl']['TEXTURE_2D'];},_0x5b5c13['prototype']['updateTextureSamplingMode']=function(_0x304f99,_0xd72ce8,_0x45f8d5){void 0x0===_0x45f8d5&&(_0x45f8d5=!0x1);var _0x296d33=this['_getTextureTarget'](_0xd72ce8),_0x465922=this['_getSamplingParameters'](_0x304f99,_0xd72ce8['generateMipMaps']||_0x45f8d5);this['_setTextureParameterInteger'](_0x296d33,this['_gl']['TEXTURE_MAG_FILTER'],_0x465922['mag'],_0xd72ce8),this['_setTextureParameterInteger'](_0x296d33,this['_gl']['TEXTURE_MIN_FILTER'],_0x465922['min']),_0x45f8d5&&(_0xd72ce8['generateMipMaps']=!0x0,this['_gl']['generateMipmap'](_0x296d33)),this['_bindTextureDirectly'](_0x296d33,null),_0xd72ce8['samplingMode']=_0x304f99;},_0x5b5c13['prototype']['updateTextureWrappingMode']=function(_0x93413f,_0x559177,_0xba8014,_0x5a00be){void 0x0===_0xba8014&&(_0xba8014=null),void 0x0===_0x5a00be&&(_0x5a00be=null);var _0x1b2e16=this['_getTextureTarget'](_0x93413f);null!==_0x559177&&(this['_setTextureParameterInteger'](_0x1b2e16,this['_gl']['TEXTURE_WRAP_S'],this['_getTextureWrapMode'](_0x559177),_0x93413f),_0x93413f['_cachedWrapU']=_0x559177),null!==_0xba8014&&(this['_setTextureParameterInteger'](_0x1b2e16,this['_gl']['TEXTURE_WRAP_T'],this['_getTextureWrapMode'](_0xba8014),_0x93413f),_0x93413f['_cachedWrapV']=_0xba8014),(_0x93413f['is2DArray']||_0x93413f['is3D'])&&null!==_0x5a00be&&(this['_setTextureParameterInteger'](_0x1b2e16,this['_gl']['TEXTURE_WRAP_R'],this['_getTextureWrapMode'](_0x5a00be),_0x93413f),_0x93413f['_cachedWrapR']=_0x5a00be),this['_bindTextureDirectly'](_0x1b2e16,null);},_0x5b5c13['prototype']['_setupDepthStencilTexture']=function(_0xed1d40,_0x3c42ae,_0x7797c0,_0x4d86ba,_0x3f4b76){var _0xb150ad=_0x3c42ae['width']||_0x3c42ae,_0x5a2b2d=_0x3c42ae['height']||_0x3c42ae,_0xd42aa9=_0x3c42ae['layers']||0x0;_0xed1d40['baseWidth']=_0xb150ad,_0xed1d40['baseHeight']=_0x5a2b2d,_0xed1d40['width']=_0xb150ad,_0xed1d40['height']=_0x5a2b2d,_0xed1d40['is2DArray']=_0xd42aa9>0x0,_0xed1d40['depth']=_0xd42aa9,_0xed1d40['isReady']=!0x0,_0xed1d40['samples']=0x1,_0xed1d40['generateMipMaps']=!0x1,_0xed1d40['_generateDepthBuffer']=!0x0,_0xed1d40['_generateStencilBuffer']=_0x7797c0,_0xed1d40['samplingMode']=_0x4d86ba?_0x585107['a']['TEXTURE_BILINEAR_SAMPLINGMODE']:_0x585107['a']['TEXTURE_NEAREST_SAMPLINGMODE'],_0xed1d40['type']=_0x585107['a']['TEXTURETYPE_UNSIGNED_INT'],_0xed1d40['_comparisonFunction']=_0x3f4b76;var _0x5be061=this['_gl'],_0xa9a2ab=this['_getTextureTarget'](_0xed1d40),_0x462b60=this['_getSamplingParameters'](_0xed1d40['samplingMode'],!0x1);_0x5be061['texParameteri'](_0xa9a2ab,_0x5be061['TEXTURE_MAG_FILTER'],_0x462b60['mag']),_0x5be061['texParameteri'](_0xa9a2ab,_0x5be061['TEXTURE_MIN_FILTER'],_0x462b60['min']),_0x5be061['texParameteri'](_0xa9a2ab,_0x5be061['TEXTURE_WRAP_S'],_0x5be061['CLAMP_TO_EDGE']),_0x5be061['texParameteri'](_0xa9a2ab,_0x5be061['TEXTURE_WRAP_T'],_0x5be061['CLAMP_TO_EDGE']),0x0===_0x3f4b76?(_0x5be061['texParameteri'](_0xa9a2ab,_0x5be061['TEXTURE_COMPARE_FUNC'],_0x585107['a']['LEQUAL']),_0x5be061['texParameteri'](_0xa9a2ab,_0x5be061['TEXTURE_COMPARE_MODE'],_0x5be061['NONE'])):(_0x5be061['texParameteri'](_0xa9a2ab,_0x5be061['TEXTURE_COMPARE_FUNC'],_0x3f4b76),_0x5be061['texParameteri'](_0xa9a2ab,_0x5be061['TEXTURE_COMPARE_MODE'],_0x5be061['COMPARE_REF_TO_TEXTURE']));},_0x5b5c13['prototype']['_uploadCompressedDataToTextureDirectly']=function(_0xbb6e22,_0x4df0c0,_0x1b64c2,_0x25422f,_0x21004d,_0x41d0d0,_0x5e6514){void 0x0===_0x41d0d0&&(_0x41d0d0=0x0),void 0x0===_0x5e6514&&(_0x5e6514=0x0);var _0x17e76f=this['_gl'],_0x3d196d=_0x17e76f['TEXTURE_2D'];_0xbb6e22['isCube']&&(_0x3d196d=_0x17e76f['TEXTURE_CUBE_MAP_POSITIVE_X']+_0x41d0d0),this['_gl']['compressedTexImage2D'](_0x3d196d,_0x5e6514,_0x4df0c0,_0x1b64c2,_0x25422f,0x0,_0x21004d);},_0x5b5c13['prototype']['_uploadDataToTextureDirectly']=function(_0x30a62f,_0x2b6d7a,_0x507cbf,_0x28cc20,_0x2f2c06,_0x2d7e51){void 0x0===_0x507cbf&&(_0x507cbf=0x0),void 0x0===_0x28cc20&&(_0x28cc20=0x0),void 0x0===_0x2d7e51&&(_0x2d7e51=!0x1);var _0x419642=this['_gl'],_0x3615ed=this['_getWebGLTextureType'](_0x30a62f['type']),_0x227223=this['_getInternalFormat'](_0x30a62f['format']),_0x30429d=void 0x0===_0x2f2c06?this['_getRGBABufferInternalSizedFormat'](_0x30a62f['type'],_0x30a62f['format']):this['_getInternalFormat'](_0x2f2c06);this['_unpackFlipY'](_0x30a62f['invertY']);var _0x5234aa=_0x419642['TEXTURE_2D'];_0x30a62f['isCube']&&(_0x5234aa=_0x419642['TEXTURE_CUBE_MAP_POSITIVE_X']+_0x507cbf);var _0x20fed=Math['round'](Math['log'](_0x30a62f['width'])*Math['LOG2E']),_0x1b1903=Math['round'](Math['log'](_0x30a62f['height'])*Math['LOG2E']),_0x107330=_0x2d7e51?_0x30a62f['width']:Math['pow'](0x2,Math['max'](_0x20fed-_0x28cc20,0x0)),_0xbea06=_0x2d7e51?_0x30a62f['height']:Math['pow'](0x2,Math['max'](_0x1b1903-_0x28cc20,0x0));_0x419642['texImage2D'](_0x5234aa,_0x28cc20,_0x30429d,_0x107330,_0xbea06,0x0,_0x227223,_0x3615ed,_0x2b6d7a);},_0x5b5c13['prototype']['updateTextureData']=function(_0x359e59,_0x1657e8,_0x5221dc,_0x3b7db0,_0x5404bd,_0x3036ab,_0x104a3a,_0x387cf9){void 0x0===_0x104a3a&&(_0x104a3a=0x0),void 0x0===_0x387cf9&&(_0x387cf9=0x0);var _0x1e38d6=this['_gl'],_0x4075b3=this['_getWebGLTextureType'](_0x359e59['type']),_0x1fae44=this['_getInternalFormat'](_0x359e59['format']);this['_unpackFlipY'](_0x359e59['invertY']);var _0x5ece98=_0x1e38d6['TEXTURE_2D'];_0x359e59['isCube']&&(_0x5ece98=_0x1e38d6['TEXTURE_CUBE_MAP_POSITIVE_X']+_0x104a3a),_0x1e38d6['texSubImage2D'](_0x5ece98,_0x387cf9,_0x5221dc,_0x3b7db0,_0x5404bd,_0x3036ab,_0x1fae44,_0x4075b3,_0x1657e8);},_0x5b5c13['prototype']['_uploadArrayBufferViewToTexture']=function(_0x19f1ab,_0x227207,_0x7da15d,_0x202099){void 0x0===_0x7da15d&&(_0x7da15d=0x0),void 0x0===_0x202099&&(_0x202099=0x0);var _0x35f2d1=this['_gl'],_0x1a24f9=_0x19f1ab['isCube']?_0x35f2d1['TEXTURE_CUBE_MAP']:_0x35f2d1['TEXTURE_2D'];this['_bindTextureDirectly'](_0x1a24f9,_0x19f1ab,!0x0),this['_uploadDataToTextureDirectly'](_0x19f1ab,_0x227207,_0x7da15d,_0x202099),this['_bindTextureDirectly'](_0x1a24f9,null,!0x0);},_0x5b5c13['prototype']['_prepareWebGLTextureContinuation']=function(_0x471968,_0x2eb032,_0xb7e8bd,_0x130444,_0x1cc646){var _0x2bac43=this['_gl'];if(_0x2bac43){var _0x5666d0=this['_getSamplingParameters'](_0x1cc646,!_0xb7e8bd);_0x2bac43['texParameteri'](_0x2bac43['TEXTURE_2D'],_0x2bac43['TEXTURE_MAG_FILTER'],_0x5666d0['mag']),_0x2bac43['texParameteri'](_0x2bac43['TEXTURE_2D'],_0x2bac43['TEXTURE_MIN_FILTER'],_0x5666d0['min']),_0xb7e8bd||_0x130444||_0x2bac43['generateMipmap'](_0x2bac43['TEXTURE_2D']),this['_bindTextureDirectly'](_0x2bac43['TEXTURE_2D'],null),_0x2eb032&&_0x2eb032['_removePendingData'](_0x471968),_0x471968['onLoadedObservable']['notifyObservers'](_0x471968),_0x471968['onLoadedObservable']['clear']();}},_0x5b5c13['prototype']['_prepareWebGLTexture']=function(_0x5b62bd,_0xe01c4b,_0xbd2dc3,_0x1dc19c,_0x5c9209,_0x5223eb,_0x2839af,_0x2cfb1f,_0x4ce472){var _0xf3f42a=this;void 0x0===_0x4ce472&&(_0x4ce472=_0x585107['a']['TEXTURE_TRILINEAR_SAMPLINGMODE']);var _0x2e9a82=this['getCaps']()['maxTextureSize'],_0x57b988=Math['min'](_0x2e9a82,this['needPOTTextures']?_0x5b5c13['GetExponentOfTwo'](_0xbd2dc3,_0x2e9a82):_0xbd2dc3),_0x54c774=Math['min'](_0x2e9a82,this['needPOTTextures']?_0x5b5c13['GetExponentOfTwo'](_0x1dc19c,_0x2e9a82):_0x1dc19c),_0xa4c09d=this['_gl'];_0xa4c09d&&(_0x5b62bd['_webGLTexture']?(this['_bindTextureDirectly'](_0xa4c09d['TEXTURE_2D'],_0x5b62bd,!0x0),this['_unpackFlipY'](void 0x0===_0x5c9209||!!_0x5c9209),_0x5b62bd['baseWidth']=_0xbd2dc3,_0x5b62bd['baseHeight']=_0x1dc19c,_0x5b62bd['width']=_0x57b988,_0x5b62bd['height']=_0x54c774,_0x5b62bd['isReady']=!0x0,_0x2cfb1f(_0x57b988,_0x54c774,function(){_0xf3f42a['_prepareWebGLTextureContinuation'](_0x5b62bd,_0xe01c4b,_0x5223eb,_0x2839af,_0x4ce472);})||this['_prepareWebGLTextureContinuation'](_0x5b62bd,_0xe01c4b,_0x5223eb,_0x2839af,_0x4ce472)):_0xe01c4b&&_0xe01c4b['_removePendingData'](_0x5b62bd));},_0x5b5c13['prototype']['_setupFramebufferDepthAttachments']=function(_0x3e1297,_0x3388c0,_0x2bbd27,_0x22bd0c,_0x38cb52){void 0x0===_0x38cb52&&(_0x38cb52=0x1);var _0x1a287d=this['_gl'];if(_0x3e1297&&_0x3388c0)return this['_getDepthStencilBuffer'](_0x2bbd27,_0x22bd0c,_0x38cb52,_0x1a287d['DEPTH_STENCIL'],_0x1a287d['DEPTH24_STENCIL8'],_0x1a287d['DEPTH_STENCIL_ATTACHMENT']);if(_0x3388c0){var _0x53382e=_0x1a287d['DEPTH_COMPONENT16'];return this['_webGLVersion']>0x1&&(_0x53382e=_0x1a287d['DEPTH_COMPONENT32F']),this['_getDepthStencilBuffer'](_0x2bbd27,_0x22bd0c,_0x38cb52,_0x53382e,_0x53382e,_0x1a287d['DEPTH_ATTACHMENT']);}return _0x3e1297?this['_getDepthStencilBuffer'](_0x2bbd27,_0x22bd0c,_0x38cb52,_0x1a287d['STENCIL_INDEX8'],_0x1a287d['STENCIL_INDEX8'],_0x1a287d['STENCIL_ATTACHMENT']):null;},_0x5b5c13['prototype']['_releaseFramebufferObjects']=function(_0x57e894){var _0x55098a=this['_gl'];_0x57e894['_framebuffer']&&(_0x55098a['deleteFramebuffer'](_0x57e894['_framebuffer']),_0x57e894['_framebuffer']=null),_0x57e894['_depthStencilBuffer']&&(_0x55098a['deleteRenderbuffer'](_0x57e894['_depthStencilBuffer']),_0x57e894['_depthStencilBuffer']=null),_0x57e894['_MSAAFramebuffer']&&(_0x55098a['deleteFramebuffer'](_0x57e894['_MSAAFramebuffer']),_0x57e894['_MSAAFramebuffer']=null),_0x57e894['_MSAARenderBuffer']&&(_0x55098a['deleteRenderbuffer'](_0x57e894['_MSAARenderBuffer']),_0x57e894['_MSAARenderBuffer']=null);},_0x5b5c13['prototype']['_releaseTexture']=function(_0x3428c4){this['_releaseFramebufferObjects'](_0x3428c4),this['_deleteTexture'](_0x3428c4['_webGLTexture']),this['unbindAllTextures']();var _0x4d1380=this['_internalTexturesCache']['indexOf'](_0x3428c4);-0x1!==_0x4d1380&&this['_internalTexturesCache']['splice'](_0x4d1380,0x1),_0x3428c4['_lodTextureHigh']&&_0x3428c4['_lodTextureHigh']['dispose'](),_0x3428c4['_lodTextureMid']&&_0x3428c4['_lodTextureMid']['dispose'](),_0x3428c4['_lodTextureLow']&&_0x3428c4['_lodTextureLow']['dispose'](),_0x3428c4['_irradianceTexture']&&_0x3428c4['_irradianceTexture']['dispose']();},_0x5b5c13['prototype']['_deleteTexture']=function(_0x27fa84){this['_gl']['deleteTexture'](_0x27fa84);},_0x5b5c13['prototype']['_setProgram']=function(_0x600826){this['_currentProgram']!==_0x600826&&(this['_gl']['useProgram'](_0x600826),this['_currentProgram']=_0x600826);},_0x5b5c13['prototype']['bindSamplers']=function(_0x45422b){var _0x32131c=_0x45422b['getPipelineContext']();this['_setProgram'](_0x32131c['program']);for(var _0x27fcaf=_0x45422b['getSamplers'](),_0x6d9623=0x0;_0x6d9623<_0x27fcaf['length'];_0x6d9623++){var _0x13a130=_0x45422b['getUniform'](_0x27fcaf[_0x6d9623]);_0x13a130&&(this['_boundUniforms'][_0x6d9623]=_0x13a130);}this['_currentEffect']=null;},_0x5b5c13['prototype']['_activateCurrentTexture']=function(){this['_currentTextureChannel']!==this['_activeChannel']&&(this['_gl']['activeTexture'](this['_gl']['TEXTURE0']+this['_activeChannel']),this['_currentTextureChannel']=this['_activeChannel']);},_0x5b5c13['prototype']['_bindTextureDirectly']=function(_0x259c64,_0x4ab220,_0x42fa8d,_0x2f0690){void 0x0===_0x42fa8d&&(_0x42fa8d=!0x1),void 0x0===_0x2f0690&&(_0x2f0690=!0x1);var _0x589644=!0x1,_0x59a872=_0x4ab220&&_0x4ab220['_associatedChannel']>-0x1;return _0x42fa8d&&_0x59a872&&(this['_activeChannel']=_0x4ab220['_associatedChannel']),this['_boundTexturesCache'][this['_activeChannel']]!==_0x4ab220||_0x2f0690?(this['_activateCurrentTexture'](),_0x4ab220&&_0x4ab220['isMultiview']?this['_gl']['bindTexture'](_0x259c64,_0x4ab220?_0x4ab220['_colorTextureArray']:null):this['_gl']['bindTexture'](_0x259c64,_0x4ab220?_0x4ab220['_webGLTexture']:null),this['_boundTexturesCache'][this['_activeChannel']]=_0x4ab220,_0x4ab220&&(_0x4ab220['_associatedChannel']=this['_activeChannel'])):_0x42fa8d&&(_0x589644=!0x0,this['_activateCurrentTexture']()),_0x59a872&&!_0x42fa8d&&this['_bindSamplerUniformToChannel'](_0x4ab220['_associatedChannel'],this['_activeChannel']),_0x589644;},_0x5b5c13['prototype']['_bindTexture']=function(_0x318a29,_0x58c8a8){if(void 0x0!==_0x318a29){_0x58c8a8&&(_0x58c8a8['_associatedChannel']=_0x318a29),this['_activeChannel']=_0x318a29;var _0x6915a1=_0x58c8a8?this['_getTextureTarget'](_0x58c8a8):this['_gl']['TEXTURE_2D'];this['_bindTextureDirectly'](_0x6915a1,_0x58c8a8);}},_0x5b5c13['prototype']['unbindAllTextures']=function(){for(var _0x57fe74=0x0;_0x57fe740x1&&(this['_bindTextureDirectly'](this['_gl']['TEXTURE_3D'],null),this['_bindTextureDirectly'](this['_gl']['TEXTURE_2D_ARRAY'],null));},_0x5b5c13['prototype']['setTexture']=function(_0x39296c,_0x46679e,_0x122ae1){void 0x0!==_0x39296c&&(_0x46679e&&(this['_boundUniforms'][_0x39296c]=_0x46679e),this['_setTexture'](_0x39296c,_0x122ae1));},_0x5b5c13['prototype']['_bindSamplerUniformToChannel']=function(_0x113f74,_0x561680){var _0x102c3e=this['_boundUniforms'][_0x113f74];_0x102c3e&&_0x102c3e['_currentState']!==_0x561680&&(this['_gl']['uniform1i'](_0x102c3e,_0x561680),_0x102c3e['_currentState']=_0x561680);},_0x5b5c13['prototype']['_getTextureWrapMode']=function(_0x24e94d){switch(_0x24e94d){case _0x585107['a']['TEXTURE_WRAP_ADDRESSMODE']:return this['_gl']['REPEAT'];case _0x585107['a']['TEXTURE_CLAMP_ADDRESSMODE']:return this['_gl']['CLAMP_TO_EDGE'];case _0x585107['a']['TEXTURE_MIRROR_ADDRESSMODE']:return this['_gl']['MIRRORED_REPEAT'];}return this['_gl']['REPEAT'];},_0x5b5c13['prototype']['_setTexture']=function(_0x499b97,_0x2a5610,_0x2c8e08,_0x4ffddf){if(void 0x0===_0x2c8e08&&(_0x2c8e08=!0x1),void 0x0===_0x4ffddf&&(_0x4ffddf=!0x1),!_0x2a5610)return null!=this['_boundTexturesCache'][_0x499b97]&&(this['_activeChannel']=_0x499b97,this['_bindTextureDirectly'](this['_gl']['TEXTURE_2D'],null),this['_bindTextureDirectly'](this['_gl']['TEXTURE_CUBE_MAP'],null),this['webGLVersion']>0x1&&(this['_bindTextureDirectly'](this['_gl']['TEXTURE_3D'],null),this['_bindTextureDirectly'](this['_gl']['TEXTURE_2D_ARRAY'],null))),!0x1;if(_0x2a5610['video'])this['_activeChannel']=_0x499b97,_0x2a5610['update']();else{if(_0x2a5610['delayLoadState']===_0x585107['a']['DELAYLOADSTATE_NOTLOADED'])return _0x2a5610['delayLoad'](),!0x1;}var _0x5f231a;_0x5f231a=_0x4ffddf?_0x2a5610['depthStencilTexture']:_0x2a5610['isReady']()?_0x2a5610['getInternalTexture']():_0x2a5610['isCube']?this['emptyCubeTexture']:_0x2a5610['is3D']?this['emptyTexture3D']:_0x2a5610['is2DArray']?this['emptyTexture2DArray']:this['emptyTexture'],!_0x2c8e08&&_0x5f231a&&(_0x5f231a['_associatedChannel']=_0x499b97);var _0x196904=!0x0;this['_boundTexturesCache'][_0x499b97]===_0x5f231a&&(_0x2c8e08||this['_bindSamplerUniformToChannel'](_0x5f231a['_associatedChannel'],_0x499b97),_0x196904=!0x1),this['_activeChannel']=_0x499b97;var _0x286de5=this['_getTextureTarget'](_0x5f231a);if(_0x196904&&this['_bindTextureDirectly'](_0x286de5,_0x5f231a,_0x2c8e08),_0x5f231a&&!_0x5f231a['isMultiview']){if(_0x5f231a['isCube']&&_0x5f231a['_cachedCoordinatesMode']!==_0x2a5610['coordinatesMode']){_0x5f231a['_cachedCoordinatesMode']=_0x2a5610['coordinatesMode'];var _0x4b0346=_0x2a5610['coordinatesMode']!==_0x585107['a']['TEXTURE_CUBIC_MODE']&&_0x2a5610['coordinatesMode']!==_0x585107['a']['TEXTURE_SKYBOX_MODE']?_0x585107['a']['TEXTURE_WRAP_ADDRESSMODE']:_0x585107['a']['TEXTURE_CLAMP_ADDRESSMODE'];_0x2a5610['wrapU']=_0x4b0346,_0x2a5610['wrapV']=_0x4b0346;}_0x5f231a['_cachedWrapU']!==_0x2a5610['wrapU']&&(_0x5f231a['_cachedWrapU']=_0x2a5610['wrapU'],this['_setTextureParameterInteger'](_0x286de5,this['_gl']['TEXTURE_WRAP_S'],this['_getTextureWrapMode'](_0x2a5610['wrapU']),_0x5f231a)),_0x5f231a['_cachedWrapV']!==_0x2a5610['wrapV']&&(_0x5f231a['_cachedWrapV']=_0x2a5610['wrapV'],this['_setTextureParameterInteger'](_0x286de5,this['_gl']['TEXTURE_WRAP_T'],this['_getTextureWrapMode'](_0x2a5610['wrapV']),_0x5f231a)),_0x5f231a['is3D']&&_0x5f231a['_cachedWrapR']!==_0x2a5610['wrapR']&&(_0x5f231a['_cachedWrapR']=_0x2a5610['wrapR'],this['_setTextureParameterInteger'](_0x286de5,this['_gl']['TEXTURE_WRAP_R'],this['_getTextureWrapMode'](_0x2a5610['wrapR']),_0x5f231a)),this['_setAnisotropicLevel'](_0x286de5,_0x5f231a,_0x2a5610['anisotropicFilteringLevel']);}return!0x0;},_0x5b5c13['prototype']['setTextureArray']=function(_0x5d1be7,_0x1e9a50,_0x489f29){if(void 0x0!==_0x5d1be7&&_0x1e9a50){this['_textureUnits']&&this['_textureUnits']['length']===_0x489f29['length']||(this['_textureUnits']=new Int32Array(_0x489f29['length']));for(var _0x4d4eaf=0x0;_0x4d4eaf<_0x489f29['length'];_0x4d4eaf++){var _0x1c2ed7=_0x489f29[_0x4d4eaf]['getInternalTexture']();_0x1c2ed7?(this['_textureUnits'][_0x4d4eaf]=_0x5d1be7+_0x4d4eaf,_0x1c2ed7['_associatedChannel']=_0x5d1be7+_0x4d4eaf):this['_textureUnits'][_0x4d4eaf]=-0x1;}this['_gl']['uniform1iv'](_0x1e9a50,this['_textureUnits']);for(var _0x32ab3d=0x0;_0x32ab3d<_0x489f29['length'];_0x32ab3d++)this['_setTexture'](this['_textureUnits'][_0x32ab3d],_0x489f29[_0x32ab3d],!0x0);}},_0x5b5c13['prototype']['_setAnisotropicLevel']=function(_0x50bfc7,_0x11feec,_0x48e814){var _0x314c03=this['_caps']['textureAnisotropicFilterExtension'];_0x11feec['samplingMode']!==_0x585107['a']['TEXTURE_LINEAR_LINEAR_MIPNEAREST']&&_0x11feec['samplingMode']!==_0x585107['a']['TEXTURE_LINEAR_LINEAR_MIPLINEAR']&&_0x11feec['samplingMode']!==_0x585107['a']['TEXTURE_LINEAR_LINEAR']&&(_0x48e814=0x1),_0x314c03&&_0x11feec['_cachedAnisotropicFilteringLevel']!==_0x48e814&&(this['_setTextureParameterFloat'](_0x50bfc7,_0x314c03['TEXTURE_MAX_ANISOTROPY_EXT'],Math['min'](_0x48e814,this['_caps']['maxAnisotropy']),_0x11feec),_0x11feec['_cachedAnisotropicFilteringLevel']=_0x48e814);},_0x5b5c13['prototype']['_setTextureParameterFloat']=function(_0x38072c,_0x323acf,_0x27c4b0,_0x2c54f4){this['_bindTextureDirectly'](_0x38072c,_0x2c54f4,!0x0,!0x0),this['_gl']['texParameterf'](_0x38072c,_0x323acf,_0x27c4b0);},_0x5b5c13['prototype']['_setTextureParameterInteger']=function(_0x118d30,_0x4b7a6e,_0x34e66a,_0xffffec){_0xffffec&&this['_bindTextureDirectly'](_0x118d30,_0xffffec,!0x0,!0x0),this['_gl']['texParameteri'](_0x118d30,_0x4b7a6e,_0x34e66a);},_0x5b5c13['prototype']['unbindAllAttributes']=function(){if(this['_mustWipeVertexAttributes']){this['_mustWipeVertexAttributes']=!0x1;for(var _0x53deb4=0x0;_0x53deb4=this['_caps']['maxVertexAttribs']||!this['_vertexAttribArraysEnabled'][_0x53deb4]||this['disableAttributeByIndex'](_0x53deb4);}},_0x5b5c13['prototype']['releaseEffects']=function(){for(var _0x13ff79 in this['_compiledEffects']){var _0x5367c1=this['_compiledEffects'][_0x13ff79]['getPipelineContext']();this['_deletePipelineContext'](_0x5367c1);}this['_compiledEffects']={};},_0x5b5c13['prototype']['dispose']=function(){this['stopRenderLoop'](),this['onBeforeTextureInitObservable']&&this['onBeforeTextureInitObservable']['clear'](),this['_emptyTexture']&&(this['_releaseTexture'](this['_emptyTexture']),this['_emptyTexture']=null),this['_emptyCubeTexture']&&(this['_releaseTexture'](this['_emptyCubeTexture']),this['_emptyCubeTexture']=null),this['_dummyFramebuffer']&&this['_gl']['deleteFramebuffer'](this['_dummyFramebuffer']),this['releaseEffects'](),this['unbindAllAttributes'](),this['_boundUniforms']=[],_0x5bca26['a']['IsWindowObjectExist']()&&this['_renderingCanvas']&&(this['_doNotHandleContextLost']||(this['_renderingCanvas']['removeEventListener']('webglcontextlost',this['_onContextLost']),this['_renderingCanvas']['removeEventListener']('webglcontextrestored',this['_onContextRestored']))),this['_workingCanvas']=null,this['_workingContext']=null,this['_currentBufferPointers']=[],this['_renderingCanvas']=null,this['_currentProgram']=null,this['_boundRenderFunction']=null,_0x589ad5['a']['ResetCache']();for(var _0x19bf22=0x0,_0x439564=this['_activeRequests'];_0x19bf22<_0x439564['length'];_0x19bf22++){_0x439564[_0x19bf22]['abort']();}},_0x5b5c13['prototype']['attachContextLostEvent']=function(_0x3033cb){this['_renderingCanvas']&&this['_renderingCanvas']['addEventListener']('webglcontextlost',_0x3033cb,!0x1);},_0x5b5c13['prototype']['attachContextRestoredEvent']=function(_0x1753dc){this['_renderingCanvas']&&this['_renderingCanvas']['addEventListener']('webglcontextrestored',_0x1753dc,!0x1);},_0x5b5c13['prototype']['getError']=function(){return this['_gl']['getError']();},_0x5b5c13['prototype']['_canRenderToFloatFramebuffer']=function(){return this['_webGLVersion']>0x1?this['_caps']['colorBufferFloat']:this['_canRenderToFramebuffer'](_0x585107['a']['TEXTURETYPE_FLOAT']);},_0x5b5c13['prototype']['_canRenderToHalfFloatFramebuffer']=function(){return this['_webGLVersion']>0x1?this['_caps']['colorBufferFloat']:this['_canRenderToFramebuffer'](_0x585107['a']['TEXTURETYPE_HALF_FLOAT']);},_0x5b5c13['prototype']['_canRenderToFramebuffer']=function(_0xa44c38){for(var _0x5d92fa=this['_gl'];_0x5d92fa['getError']()!==_0x5d92fa['NO_ERROR'];);var _0x43f89f=!0x0,_0xf70c0c=_0x5d92fa['createTexture']();_0x5d92fa['bindTexture'](_0x5d92fa['TEXTURE_2D'],_0xf70c0c),_0x5d92fa['texImage2D'](_0x5d92fa['TEXTURE_2D'],0x0,this['_getRGBABufferInternalSizedFormat'](_0xa44c38),0x1,0x1,0x0,_0x5d92fa['RGBA'],this['_getWebGLTextureType'](_0xa44c38),null),_0x5d92fa['texParameteri'](_0x5d92fa['TEXTURE_2D'],_0x5d92fa['TEXTURE_MIN_FILTER'],_0x5d92fa['NEAREST']),_0x5d92fa['texParameteri'](_0x5d92fa['TEXTURE_2D'],_0x5d92fa['TEXTURE_MAG_FILTER'],_0x5d92fa['NEAREST']);var _0x2badb9=_0x5d92fa['createFramebuffer']();_0x5d92fa['bindFramebuffer'](_0x5d92fa['FRAMEBUFFER'],_0x2badb9),_0x5d92fa['framebufferTexture2D'](_0x5d92fa['FRAMEBUFFER'],_0x5d92fa['COLOR_ATTACHMENT0'],_0x5d92fa['TEXTURE_2D'],_0xf70c0c,0x0);var _0x5bdf4c=_0x5d92fa['checkFramebufferStatus'](_0x5d92fa['FRAMEBUFFER']);if((_0x43f89f=(_0x43f89f=_0x43f89f&&_0x5bdf4c===_0x5d92fa['FRAMEBUFFER_COMPLETE'])&&_0x5d92fa['getError']()===_0x5d92fa['NO_ERROR'])&&(_0x5d92fa['clear'](_0x5d92fa['COLOR_BUFFER_BIT']),_0x43f89f=_0x43f89f&&_0x5d92fa['getError']()===_0x5d92fa['NO_ERROR']),_0x43f89f){_0x5d92fa['bindFramebuffer'](_0x5d92fa['FRAMEBUFFER'],null);var _0x240543=_0x5d92fa['RGBA'],_0x327e82=_0x5d92fa['UNSIGNED_BYTE'],_0x175bc5=new Uint8Array(0x4);_0x5d92fa['readPixels'](0x0,0x0,0x1,0x1,_0x240543,_0x327e82,_0x175bc5),_0x43f89f=_0x43f89f&&_0x5d92fa['getError']()===_0x5d92fa['NO_ERROR'];}for(_0x5d92fa['deleteTexture'](_0xf70c0c),_0x5d92fa['deleteFramebuffer'](_0x2badb9),_0x5d92fa['bindFramebuffer'](_0x5d92fa['FRAMEBUFFER'],null);!_0x43f89f&&_0x5d92fa['getError']()!==_0x5d92fa['NO_ERROR'];);return _0x43f89f;},_0x5b5c13['prototype']['_getWebGLTextureType']=function(_0x472620){if(0x1===this['_webGLVersion']){switch(_0x472620){case _0x585107['a']['TEXTURETYPE_FLOAT']:return this['_gl']['FLOAT'];case _0x585107['a']['TEXTURETYPE_HALF_FLOAT']:return this['_gl']['HALF_FLOAT_OES'];case _0x585107['a']['TEXTURETYPE_UNSIGNED_BYTE']:return this['_gl']['UNSIGNED_BYTE'];case _0x585107['a']['TEXTURETYPE_UNSIGNED_SHORT_4_4_4_4']:return this['_gl']['UNSIGNED_SHORT_4_4_4_4'];case _0x585107['a']['TEXTURETYPE_UNSIGNED_SHORT_5_5_5_1']:return this['_gl']['UNSIGNED_SHORT_5_5_5_1'];case _0x585107['a']['TEXTURETYPE_UNSIGNED_SHORT_5_6_5']:return this['_gl']['UNSIGNED_SHORT_5_6_5'];}return this['_gl']['UNSIGNED_BYTE'];}switch(_0x472620){case _0x585107['a']['TEXTURETYPE_BYTE']:return this['_gl']['BYTE'];case _0x585107['a']['TEXTURETYPE_UNSIGNED_BYTE']:return this['_gl']['UNSIGNED_BYTE'];case _0x585107['a']['TEXTURETYPE_SHORT']:return this['_gl']['SHORT'];case _0x585107['a']['TEXTURETYPE_UNSIGNED_SHORT']:return this['_gl']['UNSIGNED_SHORT'];case _0x585107['a']['TEXTURETYPE_INT']:return this['_gl']['INT'];case _0x585107['a']['TEXTURETYPE_UNSIGNED_INTEGER']:return this['_gl']['UNSIGNED_INT'];case _0x585107['a']['TEXTURETYPE_FLOAT']:return this['_gl']['FLOAT'];case _0x585107['a']['TEXTURETYPE_HALF_FLOAT']:return this['_gl']['HALF_FLOAT'];case _0x585107['a']['TEXTURETYPE_UNSIGNED_SHORT_4_4_4_4']:return this['_gl']['UNSIGNED_SHORT_4_4_4_4'];case _0x585107['a']['TEXTURETYPE_UNSIGNED_SHORT_5_5_5_1']:return this['_gl']['UNSIGNED_SHORT_5_5_5_1'];case _0x585107['a']['TEXTURETYPE_UNSIGNED_SHORT_5_6_5']:return this['_gl']['UNSIGNED_SHORT_5_6_5'];case _0x585107['a']['TEXTURETYPE_UNSIGNED_INT_2_10_10_10_REV']:return this['_gl']['UNSIGNED_INT_2_10_10_10_REV'];case _0x585107['a']['TEXTURETYPE_UNSIGNED_INT_24_8']:return this['_gl']['UNSIGNED_INT_24_8'];case _0x585107['a']['TEXTURETYPE_UNSIGNED_INT_10F_11F_11F_REV']:return this['_gl']['UNSIGNED_INT_10F_11F_11F_REV'];case _0x585107['a']['TEXTURETYPE_UNSIGNED_INT_5_9_9_9_REV']:return this['_gl']['UNSIGNED_INT_5_9_9_9_REV'];case _0x585107['a']['TEXTURETYPE_FLOAT_32_UNSIGNED_INT_24_8_REV']:return this['_gl']['FLOAT_32_UNSIGNED_INT_24_8_REV'];}return this['_gl']['UNSIGNED_BYTE'];},_0x5b5c13['prototype']['_getInternalFormat']=function(_0x34f5a1){var _0x5bfa9a=this['_gl']['RGBA'];switch(_0x34f5a1){case _0x585107['a']['TEXTUREFORMAT_ALPHA']:_0x5bfa9a=this['_gl']['ALPHA'];break;case _0x585107['a']['TEXTUREFORMAT_LUMINANCE']:_0x5bfa9a=this['_gl']['LUMINANCE'];break;case _0x585107['a']['TEXTUREFORMAT_LUMINANCE_ALPHA']:_0x5bfa9a=this['_gl']['LUMINANCE_ALPHA'];break;case _0x585107['a']['TEXTUREFORMAT_RED']:_0x5bfa9a=this['_gl']['RED'];break;case _0x585107['a']['TEXTUREFORMAT_RG']:_0x5bfa9a=this['_gl']['RG'];break;case _0x585107['a']['TEXTUREFORMAT_RGB']:_0x5bfa9a=this['_gl']['RGB'];break;case _0x585107['a']['TEXTUREFORMAT_RGBA']:_0x5bfa9a=this['_gl']['RGBA'];}if(this['_webGLVersion']>0x1)switch(_0x34f5a1){case _0x585107['a']['TEXTUREFORMAT_RED_INTEGER']:_0x5bfa9a=this['_gl']['RED_INTEGER'];break;case _0x585107['a']['TEXTUREFORMAT_RG_INTEGER']:_0x5bfa9a=this['_gl']['RG_INTEGER'];break;case _0x585107['a']['TEXTUREFORMAT_RGB_INTEGER']:_0x5bfa9a=this['_gl']['RGB_INTEGER'];break;case _0x585107['a']['TEXTUREFORMAT_RGBA_INTEGER']:_0x5bfa9a=this['_gl']['RGBA_INTEGER'];}return _0x5bfa9a;},_0x5b5c13['prototype']['_getRGBABufferInternalSizedFormat']=function(_0x544bfb,_0x1b5c67){if(0x1===this['_webGLVersion']){if(void 0x0!==_0x1b5c67)switch(_0x1b5c67){case _0x585107['a']['TEXTUREFORMAT_ALPHA']:return this['_gl']['ALPHA'];case _0x585107['a']['TEXTUREFORMAT_LUMINANCE']:return this['_gl']['LUMINANCE'];case _0x585107['a']['TEXTUREFORMAT_LUMINANCE_ALPHA']:return this['_gl']['LUMINANCE_ALPHA'];case _0x585107['a']['TEXTUREFORMAT_RGB']:return this['_gl']['RGB'];}return this['_gl']['RGBA'];}switch(_0x544bfb){case _0x585107['a']['TEXTURETYPE_BYTE']:switch(_0x1b5c67){case _0x585107['a']['TEXTUREFORMAT_RED']:return this['_gl']['R8_SNORM'];case _0x585107['a']['TEXTUREFORMAT_RG']:return this['_gl']['RG8_SNORM'];case _0x585107['a']['TEXTUREFORMAT_RGB']:return this['_gl']['RGB8_SNORM'];case _0x585107['a']['TEXTUREFORMAT_RED_INTEGER']:return this['_gl']['R8I'];case _0x585107['a']['TEXTUREFORMAT_RG_INTEGER']:return this['_gl']['RG8I'];case _0x585107['a']['TEXTUREFORMAT_RGB_INTEGER']:return this['_gl']['RGB8I'];case _0x585107['a']['TEXTUREFORMAT_RGBA_INTEGER']:return this['_gl']['RGBA8I'];default:return this['_gl']['RGBA8_SNORM'];}case _0x585107['a']['TEXTURETYPE_UNSIGNED_BYTE']:switch(_0x1b5c67){case _0x585107['a']['TEXTUREFORMAT_RED']:return this['_gl']['R8'];case _0x585107['a']['TEXTUREFORMAT_RG']:return this['_gl']['RG8'];case _0x585107['a']['TEXTUREFORMAT_RGB']:return this['_gl']['RGB8'];case _0x585107['a']['TEXTUREFORMAT_RGBA']:return this['_gl']['RGBA8'];case _0x585107['a']['TEXTUREFORMAT_RED_INTEGER']:return this['_gl']['R8UI'];case _0x585107['a']['TEXTUREFORMAT_RG_INTEGER']:return this['_gl']['RG8UI'];case _0x585107['a']['TEXTUREFORMAT_RGB_INTEGER']:return this['_gl']['RGB8UI'];case _0x585107['a']['TEXTUREFORMAT_RGBA_INTEGER']:return this['_gl']['RGBA8UI'];case _0x585107['a']['TEXTUREFORMAT_ALPHA']:return this['_gl']['ALPHA'];case _0x585107['a']['TEXTUREFORMAT_LUMINANCE']:return this['_gl']['LUMINANCE'];case _0x585107['a']['TEXTUREFORMAT_LUMINANCE_ALPHA']:return this['_gl']['LUMINANCE_ALPHA'];default:return this['_gl']['RGBA8'];}case _0x585107['a']['TEXTURETYPE_SHORT']:switch(_0x1b5c67){case _0x585107['a']['TEXTUREFORMAT_RED_INTEGER']:return this['_gl']['R16I'];case _0x585107['a']['TEXTUREFORMAT_RG_INTEGER']:return this['_gl']['RG16I'];case _0x585107['a']['TEXTUREFORMAT_RGB_INTEGER']:return this['_gl']['RGB16I'];case _0x585107['a']['TEXTUREFORMAT_RGBA_INTEGER']:default:return this['_gl']['RGBA16I'];}case _0x585107['a']['TEXTURETYPE_UNSIGNED_SHORT']:switch(_0x1b5c67){case _0x585107['a']['TEXTUREFORMAT_RED_INTEGER']:return this['_gl']['R16UI'];case _0x585107['a']['TEXTUREFORMAT_RG_INTEGER']:return this['_gl']['RG16UI'];case _0x585107['a']['TEXTUREFORMAT_RGB_INTEGER']:return this['_gl']['RGB16UI'];case _0x585107['a']['TEXTUREFORMAT_RGBA_INTEGER']:default:return this['_gl']['RGBA16UI'];}case _0x585107['a']['TEXTURETYPE_INT']:switch(_0x1b5c67){case _0x585107['a']['TEXTUREFORMAT_RED_INTEGER']:return this['_gl']['R32I'];case _0x585107['a']['TEXTUREFORMAT_RG_INTEGER']:return this['_gl']['RG32I'];case _0x585107['a']['TEXTUREFORMAT_RGB_INTEGER']:return this['_gl']['RGB32I'];case _0x585107['a']['TEXTUREFORMAT_RGBA_INTEGER']:default:return this['_gl']['RGBA32I'];}case _0x585107['a']['TEXTURETYPE_UNSIGNED_INTEGER']:switch(_0x1b5c67){case _0x585107['a']['TEXTUREFORMAT_RED_INTEGER']:return this['_gl']['R32UI'];case _0x585107['a']['TEXTUREFORMAT_RG_INTEGER']:return this['_gl']['RG32UI'];case _0x585107['a']['TEXTUREFORMAT_RGB_INTEGER']:return this['_gl']['RGB32UI'];case _0x585107['a']['TEXTUREFORMAT_RGBA_INTEGER']:default:return this['_gl']['RGBA32UI'];}case _0x585107['a']['TEXTURETYPE_FLOAT']:switch(_0x1b5c67){case _0x585107['a']['TEXTUREFORMAT_RED']:return this['_gl']['R32F'];case _0x585107['a']['TEXTUREFORMAT_RG']:return this['_gl']['RG32F'];case _0x585107['a']['TEXTUREFORMAT_RGB']:return this['_gl']['RGB32F'];case _0x585107['a']['TEXTUREFORMAT_RGBA']:default:return this['_gl']['RGBA32F'];}case _0x585107['a']['TEXTURETYPE_HALF_FLOAT']:switch(_0x1b5c67){case _0x585107['a']['TEXTUREFORMAT_RED']:return this['_gl']['R16F'];case _0x585107['a']['TEXTUREFORMAT_RG']:return this['_gl']['RG16F'];case _0x585107['a']['TEXTUREFORMAT_RGB']:return this['_gl']['RGB16F'];case _0x585107['a']['TEXTUREFORMAT_RGBA']:default:return this['_gl']['RGBA16F'];}case _0x585107['a']['TEXTURETYPE_UNSIGNED_SHORT_5_6_5']:return this['_gl']['RGB565'];case _0x585107['a']['TEXTURETYPE_UNSIGNED_INT_10F_11F_11F_REV']:return this['_gl']['R11F_G11F_B10F'];case _0x585107['a']['TEXTURETYPE_UNSIGNED_INT_5_9_9_9_REV']:return this['_gl']['RGB9_E5'];case _0x585107['a']['TEXTURETYPE_UNSIGNED_SHORT_4_4_4_4']:return this['_gl']['RGBA4'];case _0x585107['a']['TEXTURETYPE_UNSIGNED_SHORT_5_5_5_1']:return this['_gl']['RGB5_A1'];case _0x585107['a']['TEXTURETYPE_UNSIGNED_INT_2_10_10_10_REV']:switch(_0x1b5c67){case _0x585107['a']['TEXTUREFORMAT_RGBA']:return this['_gl']['RGB10_A2'];case _0x585107['a']['TEXTUREFORMAT_RGBA_INTEGER']:return this['_gl']['RGB10_A2UI'];default:return this['_gl']['RGB10_A2'];}}return this['_gl']['RGBA8'];},_0x5b5c13['prototype']['_getRGBAMultiSampleBufferFormat']=function(_0x11a3ba){return _0x11a3ba===_0x585107['a']['TEXTURETYPE_FLOAT']?this['_gl']['RGBA32F']:_0x11a3ba===_0x585107['a']['TEXTURETYPE_HALF_FLOAT']?this['_gl']['RGBA16F']:this['_gl']['RGBA8'];},_0x5b5c13['prototype']['_loadFile']=function(_0x1a0f33,_0x8dbd72,_0x3ad310,_0x100115,_0xbf7ca1,_0xf0b71e){var _0x2e1acc=this,_0x2af7d6=_0x5b5c13['_FileToolsLoadFile'](_0x1a0f33,_0x8dbd72,_0x3ad310,_0x100115,_0xbf7ca1,_0xf0b71e);return this['_activeRequests']['push'](_0x2af7d6),_0x2af7d6['onCompleteObservable']['add'](function(_0x4147eb){_0x2e1acc['_activeRequests']['splice'](_0x2e1acc['_activeRequests']['indexOf'](_0x4147eb),0x1);}),_0x2af7d6;},_0x5b5c13['_FileToolsLoadFile']=function(_0x3adeb7,_0x953d3d,_0xf3e359,_0x17f609,_0x163317,_0x2a1c6d){throw _0x826132['a']['WarnImport']('FileTools');},_0x5b5c13['prototype']['readPixels']=function(_0x284f7b,_0x74bbda,_0x123d61,_0x2f1055,_0xd0d599){void 0x0===_0xd0d599&&(_0xd0d599=!0x0);var _0x1d39b6=_0xd0d599?0x4:0x3,_0x24a478=_0xd0d599?this['_gl']['RGBA']:this['_gl']['RGB'],_0x504694=new Uint8Array(_0x2f1055*_0x123d61*_0x1d39b6);return this['_gl']['readPixels'](_0x284f7b,_0x74bbda,_0x123d61,_0x2f1055,_0x24a478,this['_gl']['UNSIGNED_BYTE'],_0x504694),_0x504694;},Object['defineProperty'](_0x5b5c13,'IsSupported',{'get':function(){return this['isSupported']();},'enumerable':!0x1,'configurable':!0x0}),_0x5b5c13['isSupported']=function(){if(null!==this['_HasMajorPerformanceCaveat'])return!this['_HasMajorPerformanceCaveat'];if(null===this['_IsSupported'])try{var _0x459cfd=_0xc6dceb['a']['CreateCanvas'](0x1,0x1),_0x37a596=_0x459cfd['getContext']('webgl')||_0x459cfd['getContext']('experimental-webgl');this['_IsSupported']=null!=_0x37a596&&!!window['WebGLRenderingContext'];}catch(_0x2dcfc0){this['_IsSupported']=!0x1;}return this['_IsSupported'];},Object['defineProperty'](_0x5b5c13,'HasMajorPerformanceCaveat',{'get':function(){if(null===this['_HasMajorPerformanceCaveat'])try{var _0x439cd2=_0xc6dceb['a']['CreateCanvas'](0x1,0x1),_0x18f0bd=_0x439cd2['getContext']('webgl',{'failIfMajorPerformanceCaveat':!0x0})||_0x439cd2['getContext']('experimental-webgl',{'failIfMajorPerformanceCaveat':!0x0});this['_HasMajorPerformanceCaveat']=!_0x18f0bd;}catch(_0x9f75a5){this['_HasMajorPerformanceCaveat']=!0x1;}return this['_HasMajorPerformanceCaveat'];},'enumerable':!0x1,'configurable':!0x0}),_0x5b5c13['CeilingPOT']=function(_0xa9a929){return _0xa9a929--,_0xa9a929|=_0xa9a929>>0x1,_0xa9a929|=_0xa9a929>>0x2,_0xa9a929|=_0xa9a929>>0x4,_0xa9a929|=_0xa9a929>>0x8,_0xa9a929|=_0xa9a929>>0x10,++_0xa9a929;},_0x5b5c13['FloorPOT']=function(_0x259c58){return _0x259c58|=_0x259c58>>0x1,_0x259c58|=_0x259c58>>0x2,_0x259c58|=_0x259c58>>0x4,_0x259c58|=_0x259c58>>0x8,(_0x259c58|=_0x259c58>>0x10)-(_0x259c58>>0x1);},_0x5b5c13['NearestPOT']=function(_0x5396de){var _0x320a65=_0x5b5c13['CeilingPOT'](_0x5396de),_0x1978ef=_0x5b5c13['FloorPOT'](_0x5396de);return _0x320a65-_0x5396de>_0x5396de-_0x1978ef?_0x1978ef:_0x320a65;},_0x5b5c13['GetExponentOfTwo']=function(_0x3bcdf1,_0x307d05,_0x360743){var _0x5bf80f;switch(void 0x0===_0x360743&&(_0x360743=_0x585107['a']['SCALEMODE_NEAREST']),_0x360743){case _0x585107['a']['SCALEMODE_FLOOR']:_0x5bf80f=_0x5b5c13['FloorPOT'](_0x3bcdf1);break;case _0x585107['a']['SCALEMODE_NEAREST']:_0x5bf80f=_0x5b5c13['NearestPOT'](_0x3bcdf1);break;case _0x585107['a']['SCALEMODE_CEILING']:default:_0x5bf80f=_0x5b5c13['CeilingPOT'](_0x3bcdf1);}return Math['min'](_0x5bf80f,_0x307d05);},_0x5b5c13['QueueNewFrame']=function(_0x2b9b35,_0xdd8b03){return _0x5bca26['a']['IsWindowObjectExist']()?(_0xdd8b03||(_0xdd8b03=window),_0xdd8b03['requestPostAnimationFrame']?_0xdd8b03['requestPostAnimationFrame'](_0x2b9b35):_0xdd8b03['requestAnimationFrame']?_0xdd8b03['requestAnimationFrame'](_0x2b9b35):_0xdd8b03['msRequestAnimationFrame']?_0xdd8b03['msRequestAnimationFrame'](_0x2b9b35):_0xdd8b03['webkitRequestAnimationFrame']?_0xdd8b03['webkitRequestAnimationFrame'](_0x2b9b35):_0xdd8b03['mozRequestAnimationFrame']?_0xdd8b03['mozRequestAnimationFrame'](_0x2b9b35):_0xdd8b03['oRequestAnimationFrame']?_0xdd8b03['oRequestAnimationFrame'](_0x2b9b35):window['setTimeout'](_0x2b9b35,0x10)):'undefined'!=typeof requestAnimationFrame?requestAnimationFrame(_0x2b9b35):setTimeout(_0x2b9b35,0x10);},_0x5b5c13['prototype']['getHostDocument']=function(){return this['_renderingCanvas']&&this['_renderingCanvas']['ownerDocument']?this['_renderingCanvas']['ownerDocument']:document;},_0x5b5c13['ExceptionList']=[{'key':'Chrome/63.0','capture':'63\x5c.0\x5c.3239\x5c.(\x5cd+)','captureConstraint':0x6c,'targets':['uniformBuffer']},{'key':'Firefox/58','capture':null,'captureConstraint':null,'targets':['uniformBuffer']},{'key':'Firefox/59','capture':null,'captureConstraint':null,'targets':['uniformBuffer']},{'key':'Chrome/72.+?Mobile','capture':null,'captureConstraint':null,'targets':['vao']},{'key':'Chrome/73.+?Mobile','capture':null,'captureConstraint':null,'targets':['vao']},{'key':'Chrome/74.+?Mobile','capture':null,'captureConstraint':null,'targets':['vao']},{'key':'Mac\x20OS.+Chrome/71','capture':null,'captureConstraint':null,'targets':['vao']},{'key':'Mac\x20OS.+Chrome/72','capture':null,'captureConstraint':null,'targets':['vao']}],_0x5b5c13['_TextureLoaders']=[],_0x5b5c13['CollisionsEpsilon']=0.001,_0x5b5c13['_IsSupported']=null,_0x5b5c13['_HasMajorPerformanceCaveat']=null,_0x5b5c13;}());},function(_0x5666d3,_0x3216c8,_0x5f32c0){'use strict';_0x5f32c0['d'](_0x3216c8,'b',function(){return _0x2544a0;}),_0x5f32c0['d'](_0x3216c8,'a',function(){return _0x5e9df3;});var _0x2544a0,_0x5d9fa4=_0x5f32c0(0x6),_0x5281ce=_0x5f32c0(0x66),_0x27c64e=_0x5f32c0(0x2),_0x3cbdd4=_0x5f32c0(0x15);!function(_0x4cc36d){_0x4cc36d[_0x4cc36d['Unknown']=0x0]='Unknown',_0x4cc36d[_0x4cc36d['Url']=0x1]='Url',_0x4cc36d[_0x4cc36d['Temp']=0x2]='Temp',_0x4cc36d[_0x4cc36d['Raw']=0x3]='Raw',_0x4cc36d[_0x4cc36d['Dynamic']=0x4]='Dynamic',_0x4cc36d[_0x4cc36d['RenderTarget']=0x5]='RenderTarget',_0x4cc36d[_0x4cc36d['MultiRenderTarget']=0x6]='MultiRenderTarget',_0x4cc36d[_0x4cc36d['Cube']=0x7]='Cube',_0x4cc36d[_0x4cc36d['CubeRaw']=0x8]='CubeRaw',_0x4cc36d[_0x4cc36d['CubePrefiltered']=0x9]='CubePrefiltered',_0x4cc36d[_0x4cc36d['Raw3D']=0xa]='Raw3D',_0x4cc36d[_0x4cc36d['Raw2DArray']=0xb]='Raw2DArray',_0x4cc36d[_0x4cc36d['Depth']=0xc]='Depth',_0x4cc36d[_0x4cc36d['CubeRawRGBD']=0xd]='CubeRawRGBD';}(_0x2544a0||(_0x2544a0={}));var _0x5e9df3=(function(){function _0x269389(_0x47b299,_0xe38a03,_0x190cdb){void 0x0===_0x190cdb&&(_0x190cdb=!0x1),this['isReady']=!0x1,this['isCube']=!0x1,this['is3D']=!0x1,this['is2DArray']=!0x1,this['isMultiview']=!0x1,this['url']='',this['samplingMode']=-0x1,this['generateMipMaps']=!0x1,this['samples']=0x0,this['type']=-0x1,this['format']=-0x1,this['onLoadedObservable']=new _0x5d9fa4['c'](),this['width']=0x0,this['height']=0x0,this['depth']=0x0,this['baseWidth']=0x0,this['baseHeight']=0x0,this['baseDepth']=0x0,this['invertY']=!0x1,this['_invertVScale']=!0x1,this['_associatedChannel']=-0x1,this['_source']=_0x2544a0['Unknown'],this['_buffer']=null,this['_bufferView']=null,this['_bufferViewArray']=null,this['_bufferViewArrayArray']=null,this['_size']=0x0,this['_extension']='',this['_files']=null,this['_workingCanvas']=null,this['_workingContext']=null,this['_framebuffer']=null,this['_depthStencilBuffer']=null,this['_MSAAFramebuffer']=null,this['_MSAARenderBuffer']=null,this['_attachments']=null,this['_textureArray']=null,this['_cachedCoordinatesMode']=null,this['_cachedWrapU']=null,this['_cachedWrapV']=null,this['_cachedWrapR']=null,this['_cachedAnisotropicFilteringLevel']=null,this['_isDisabled']=!0x1,this['_compression']=null,this['_generateStencilBuffer']=!0x1,this['_generateDepthBuffer']=!0x1,this['_comparisonFunction']=0x0,this['_sphericalPolynomial']=null,this['_lodGenerationScale']=0x0,this['_lodGenerationOffset']=0x0,this['_colorTextureArray']=null,this['_depthStencilTextureArray']=null,this['_lodTextureHigh']=null,this['_lodTextureMid']=null,this['_lodTextureLow']=null,this['_isRGBD']=!0x1,this['_linearSpecularLOD']=!0x1,this['_irradianceTexture']=null,this['_webGLTexture']=null,this['_references']=0x1,this['_gammaSpace']=null,this['_engine']=_0x47b299,this['_source']=_0xe38a03,_0x190cdb||(this['_webGLTexture']=_0x47b299['_createTexture']());}return _0x269389['prototype']['getEngine']=function(){return this['_engine'];},Object['defineProperty'](_0x269389['prototype'],'source',{'get':function(){return this['_source'];},'enumerable':!0x1,'configurable':!0x0}),_0x269389['prototype']['incrementReferences']=function(){this['_references']++;},_0x269389['prototype']['updateSize']=function(_0x12f710,_0x47fcfd,_0x3da880){void 0x0===_0x3da880&&(_0x3da880=0x1),this['width']=_0x12f710,this['height']=_0x47fcfd,this['depth']=_0x3da880,this['baseWidth']=_0x12f710,this['baseHeight']=_0x47fcfd,this['baseDepth']=_0x3da880,this['_size']=_0x12f710*_0x47fcfd*_0x3da880;},_0x269389['prototype']['_rebuild']=function(){var _0x44d560,_0xba079a,_0x4e5138=this;switch(this['isReady']=!0x1,this['_cachedCoordinatesMode']=null,this['_cachedWrapU']=null,this['_cachedWrapV']=null,this['_cachedAnisotropicFilteringLevel']=null,this['source']){case _0x2544a0['Temp']:return;case _0x2544a0['Url']:return void(_0xba079a=this['_engine']['createTexture'](null!==(_0x44d560=this['_originalUrl'])&&void 0x0!==_0x44d560?_0x44d560:this['url'],!this['generateMipMaps'],this['invertY'],null,this['samplingMode'],function(){_0xba079a['_swapAndDie'](_0x4e5138),_0x4e5138['isReady']=!0x0;},null,this['_buffer'],void 0x0,this['format']));case _0x2544a0['Raw']:return(_0xba079a=this['_engine']['createRawTexture'](this['_bufferView'],this['baseWidth'],this['baseHeight'],this['format'],this['generateMipMaps'],this['invertY'],this['samplingMode'],this['_compression']))['_swapAndDie'](this),void(this['isReady']=!0x0);case _0x2544a0['Raw3D']:return(_0xba079a=this['_engine']['createRawTexture3D'](this['_bufferView'],this['baseWidth'],this['baseHeight'],this['baseDepth'],this['format'],this['generateMipMaps'],this['invertY'],this['samplingMode'],this['_compression']))['_swapAndDie'](this),void(this['isReady']=!0x0);case _0x2544a0['Raw2DArray']:return(_0xba079a=this['_engine']['createRawTexture2DArray'](this['_bufferView'],this['baseWidth'],this['baseHeight'],this['baseDepth'],this['format'],this['generateMipMaps'],this['invertY'],this['samplingMode'],this['_compression']))['_swapAndDie'](this),void(this['isReady']=!0x0);case _0x2544a0['Dynamic']:return(_0xba079a=this['_engine']['createDynamicTexture'](this['baseWidth'],this['baseHeight'],this['generateMipMaps'],this['samplingMode']))['_swapAndDie'](this),void this['_engine']['updateDynamicTexture'](this,this['_engine']['getRenderingCanvas'](),this['invertY'],void 0x0,void 0x0,!0x0);case _0x2544a0['RenderTarget']:var _0x2b458b=new _0x5281ce['a']();if(_0x2b458b['generateDepthBuffer']=this['_generateDepthBuffer'],_0x2b458b['generateMipMaps']=this['generateMipMaps'],_0x2b458b['generateStencilBuffer']=this['_generateStencilBuffer'],_0x2b458b['samplingMode']=this['samplingMode'],_0x2b458b['type']=this['type'],this['isCube'])_0xba079a=this['_engine']['createRenderTargetCubeTexture'](this['width'],_0x2b458b);else{var _0x10f7c1={'width':this['width'],'height':this['height'],'layers':this['is2DArray']?this['depth']:void 0x0};_0xba079a=this['_engine']['createRenderTargetTexture'](_0x10f7c1,_0x2b458b);}return _0xba079a['_swapAndDie'](this),void(this['isReady']=!0x0);case _0x2544a0['Depth']:var _0x17da01={'bilinearFiltering':this['samplingMode']!==_0x27c64e['a']['TEXTURE_BILINEAR_SAMPLINGMODE'],'comparisonFunction':this['_comparisonFunction'],'generateStencil':this['_generateStencilBuffer'],'isCube':this['isCube']},_0x28b50e={'width':this['width'],'height':this['height'],'layers':this['is2DArray']?this['depth']:void 0x0};return(_0xba079a=this['_engine']['createDepthStencilTexture'](_0x28b50e,_0x17da01))['_swapAndDie'](this),void(this['isReady']=!0x0);case _0x2544a0['Cube']:return void(_0xba079a=this['_engine']['createCubeTexture'](this['url'],null,this['_files'],!this['generateMipMaps'],function(){_0xba079a['_swapAndDie'](_0x4e5138),_0x4e5138['isReady']=!0x0;},null,this['format'],this['_extension']));case _0x2544a0['CubeRaw']:return(_0xba079a=this['_engine']['createRawCubeTexture'](this['_bufferViewArray'],this['width'],this['format'],this['type'],this['generateMipMaps'],this['invertY'],this['samplingMode'],this['_compression']))['_swapAndDie'](this),void(this['isReady']=!0x0);case _0x2544a0['CubeRawRGBD']:return _0xba079a=this['_engine']['createRawCubeTexture'](null,this['width'],this['format'],this['type'],this['generateMipMaps'],this['invertY'],this['samplingMode'],this['_compression']),void _0x269389['_UpdateRGBDAsync'](_0xba079a,this['_bufferViewArrayArray'],this['_sphericalPolynomial'],this['_lodGenerationScale'],this['_lodGenerationOffset'])['then'](function(){_0xba079a['_swapAndDie'](_0x4e5138),_0x4e5138['isReady']=!0x0;});case _0x2544a0['CubePrefiltered']:return void((_0xba079a=this['_engine']['createPrefilteredCubeTexture'](this['url'],null,this['_lodGenerationScale'],this['_lodGenerationOffset'],function(_0x5ecf72){_0x5ecf72&&_0x5ecf72['_swapAndDie'](_0x4e5138),_0x4e5138['isReady']=!0x0;},null,this['format'],this['_extension']))['_sphericalPolynomial']=this['_sphericalPolynomial']);}},_0x269389['prototype']['_swapAndDie']=function(_0x2d0566){_0x2d0566['_webGLTexture']=this['_webGLTexture'],_0x2d0566['_isRGBD']=this['_isRGBD'],this['_framebuffer']&&(_0x2d0566['_framebuffer']=this['_framebuffer']),this['_depthStencilBuffer']&&(_0x2d0566['_depthStencilBuffer']=this['_depthStencilBuffer']),_0x2d0566['_depthStencilTexture']=this['_depthStencilTexture'],this['_lodTextureHigh']&&(_0x2d0566['_lodTextureHigh']&&_0x2d0566['_lodTextureHigh']['dispose'](),_0x2d0566['_lodTextureHigh']=this['_lodTextureHigh']),this['_lodTextureMid']&&(_0x2d0566['_lodTextureMid']&&_0x2d0566['_lodTextureMid']['dispose'](),_0x2d0566['_lodTextureMid']=this['_lodTextureMid']),this['_lodTextureLow']&&(_0x2d0566['_lodTextureLow']&&_0x2d0566['_lodTextureLow']['dispose'](),_0x2d0566['_lodTextureLow']=this['_lodTextureLow']),this['_irradianceTexture']&&(_0x2d0566['_irradianceTexture']&&_0x2d0566['_irradianceTexture']['dispose'](),_0x2d0566['_irradianceTexture']=this['_irradianceTexture']);var _0x14821c,_0x2e9526=this['_engine']['getLoadedTexturesCache']();-0x1!==(_0x14821c=_0x2e9526['indexOf'](this))&&_0x2e9526['splice'](_0x14821c,0x1),-0x1===(_0x14821c=_0x2e9526['indexOf'](_0x2d0566))&&_0x2e9526['push'](_0x2d0566);},_0x269389['prototype']['dispose']=function(){this['_webGLTexture']&&(this['_references']--,0x0===this['_references']&&(this['_engine']['_releaseTexture'](this),this['_webGLTexture']=null));},_0x269389['_UpdateRGBDAsync']=function(_0x3a2e73,_0x237552,_0x491ccf,_0x3abfa3,_0x56b182){throw _0x3cbdd4['a']['WarnImport']('environmentTextureTools');},_0x269389;}());},function(_0x670a41,_0x2bab6e,_0x20d1f6){'use strict';_0x20d1f6['d'](_0x2bab6e,'b',function(){return _0x1d6c36;}),_0x20d1f6['d'](_0x2bab6e,'c',function(){return _0x4aab23;}),_0x20d1f6['d'](_0x2bab6e,'a',function(){return _0x5e4d9c;});var _0x1d6c36=0x1/2.2,_0x4aab23=2.2,_0x5e4d9c=0.001;},function(_0x429837,_0x3cd3cd,_0x4ccf8a){'use strict';_0x4ccf8a['d'](_0x3cd3cd,'a',function(){return _0x4ad4f1;});var _0xac95f6=_0x4ccf8a(0x1),_0x1683fe=_0x4ccf8a(0x0),_0x35209e=_0x4ccf8a(0x3),_0x3fe705=_0x4ccf8a(0x6),_0x42a5bc=_0x4ccf8a(0x16),_0x5a6493=_0x4ccf8a(0x15),_0x4ad4f1=(function(){function _0x1850d8(_0x3d0fe9,_0x19422a){void 0x0===_0x19422a&&(_0x19422a=null),this['state']='',this['metadata']=null,this['reservedDataStore']=null,this['_doNotSerialize']=!0x1,this['_isDisposed']=!0x1,this['animations']=new Array(),this['_ranges']={},this['onReady']=null,this['_isEnabled']=!0x0,this['_isParentEnabled']=!0x0,this['_isReady']=!0x0,this['_currentRenderId']=-0x1,this['_parentUpdateId']=-0x1,this['_childUpdateId']=-0x1,this['_waitingParentId']=null,this['_cache']={},this['_parentNode']=null,this['_children']=null,this['_worldMatrix']=_0x1683fe['a']['Identity'](),this['_worldMatrixDeterminant']=0x0,this['_worldMatrixDeterminantIsDirty']=!0x0,this['_sceneRootNodesIndex']=-0x1,this['_animationPropertiesOverride']=null,this['_isNode']=!0x0,this['onDisposeObservable']=new _0x3fe705['c'](),this['_onDisposeObserver']=null,this['_behaviors']=new Array(),this['name']=_0x3d0fe9,this['id']=_0x3d0fe9,this['_scene']=_0x19422a||_0x42a5bc['a']['LastCreatedScene'],this['uniqueId']=this['_scene']['getUniqueId'](),this['_initCache']();}return _0x1850d8['AddNodeConstructor']=function(_0x54fe5a,_0x33d640){this['_NodeConstructors'][_0x54fe5a]=_0x33d640;},_0x1850d8['Construct']=function(_0x35a589,_0x48a93e,_0x3396e1,_0x95cfa3){var _0x5608a7=this['_NodeConstructors'][_0x35a589];return _0x5608a7?_0x5608a7(_0x48a93e,_0x3396e1,_0x95cfa3):null;},Object['defineProperty'](_0x1850d8['prototype'],'doNotSerialize',{'get':function(){return!!this['_doNotSerialize']||!!this['_parentNode']&&this['_parentNode']['doNotSerialize'];},'set':function(_0x536d90){this['_doNotSerialize']=_0x536d90;},'enumerable':!0x1,'configurable':!0x0}),_0x1850d8['prototype']['isDisposed']=function(){return this['_isDisposed'];},Object['defineProperty'](_0x1850d8['prototype'],'parent',{'get':function(){return this['_parentNode'];},'set':function(_0x5f3dbb){if(this['_parentNode']!==_0x5f3dbb){var _0x29a5a5=this['_parentNode'];if(this['_parentNode']&&void 0x0!==this['_parentNode']['_children']&&null!==this['_parentNode']['_children']){var _0x25de7d=this['_parentNode']['_children']['indexOf'](this);-0x1!==_0x25de7d&&this['_parentNode']['_children']['splice'](_0x25de7d,0x1),_0x5f3dbb||this['_isDisposed']||this['_addToSceneRootNodes']();}this['_parentNode']=_0x5f3dbb,this['_parentNode']&&(void 0x0!==this['_parentNode']['_children']&&null!==this['_parentNode']['_children']||(this['_parentNode']['_children']=new Array()),this['_parentNode']['_children']['push'](this),_0x29a5a5||this['_removeFromSceneRootNodes']()),this['_syncParentEnabledState']();}},'enumerable':!0x1,'configurable':!0x0}),_0x1850d8['prototype']['_addToSceneRootNodes']=function(){-0x1===this['_sceneRootNodesIndex']&&(this['_sceneRootNodesIndex']=this['_scene']['rootNodes']['length'],this['_scene']['rootNodes']['push'](this));},_0x1850d8['prototype']['_removeFromSceneRootNodes']=function(){if(-0x1!==this['_sceneRootNodesIndex']){var _0x13c48e=this['_scene']['rootNodes'],_0xbd1935=_0x13c48e['length']-0x1;_0x13c48e[this['_sceneRootNodesIndex']]=_0x13c48e[_0xbd1935],_0x13c48e[this['_sceneRootNodesIndex']]['_sceneRootNodesIndex']=this['_sceneRootNodesIndex'],this['_scene']['rootNodes']['pop'](),this['_sceneRootNodesIndex']=-0x1;}},Object['defineProperty'](_0x1850d8['prototype'],'animationPropertiesOverride',{'get':function(){return this['_animationPropertiesOverride']?this['_animationPropertiesOverride']:this['_scene']['animationPropertiesOverride'];},'set':function(_0x20c7b2){this['_animationPropertiesOverride']=_0x20c7b2;},'enumerable':!0x1,'configurable':!0x0}),_0x1850d8['prototype']['getClassName']=function(){return'Node';},Object['defineProperty'](_0x1850d8['prototype'],'onDispose',{'set':function(_0x2d8f7e){this['_onDisposeObserver']&&this['onDisposeObservable']['remove'](this['_onDisposeObserver']),this['_onDisposeObserver']=this['onDisposeObservable']['add'](_0x2d8f7e);},'enumerable':!0x1,'configurable':!0x0}),_0x1850d8['prototype']['getScene']=function(){return this['_scene'];},_0x1850d8['prototype']['getEngine']=function(){return this['_scene']['getEngine']();},_0x1850d8['prototype']['addBehavior']=function(_0x456770,_0x43623c){var _0xb8ca4a=this;return void 0x0===_0x43623c&&(_0x43623c=!0x1),-0x1!==this['_behaviors']['indexOf'](_0x456770)||(_0x456770['init'](),this['_scene']['isLoading']&&!_0x43623c?this['_scene']['onDataLoadedObservable']['addOnce'](function(){_0x456770['attach'](_0xb8ca4a);}):_0x456770['attach'](this),this['_behaviors']['push'](_0x456770)),this;},_0x1850d8['prototype']['removeBehavior']=function(_0x168715){var _0x22f1b4=this['_behaviors']['indexOf'](_0x168715);return-0x1===_0x22f1b4||(this['_behaviors'][_0x22f1b4]['detach'](),this['_behaviors']['splice'](_0x22f1b4,0x1)),this;},Object['defineProperty'](_0x1850d8['prototype'],'behaviors',{'get':function(){return this['_behaviors'];},'enumerable':!0x1,'configurable':!0x0}),_0x1850d8['prototype']['getBehaviorByName']=function(_0x39abcc){for(var _0x282d5f=0x0,_0x483525=this['_behaviors'];_0x282d5f<_0x483525['length'];_0x282d5f++){var _0x25d533=_0x483525[_0x282d5f];if(_0x25d533['name']===_0x39abcc)return _0x25d533;}return null;},_0x1850d8['prototype']['getWorldMatrix']=function(){return this['_currentRenderId']!==this['_scene']['getRenderId']()&&this['computeWorldMatrix'](),this['_worldMatrix'];},_0x1850d8['prototype']['_getWorldMatrixDeterminant']=function(){return this['_worldMatrixDeterminantIsDirty']&&(this['_worldMatrixDeterminantIsDirty']=!0x1,this['_worldMatrixDeterminant']=this['_worldMatrix']['determinant']()),this['_worldMatrixDeterminant'];},Object['defineProperty'](_0x1850d8['prototype'],'worldMatrixFromCache',{'get':function(){return this['_worldMatrix'];},'enumerable':!0x1,'configurable':!0x0}),_0x1850d8['prototype']['_initCache']=function(){this['_cache']={},this['_cache']['parent']=void 0x0;},_0x1850d8['prototype']['updateCache']=function(_0x324d7c){!_0x324d7c&&this['isSynchronized']()||(this['_cache']['parent']=this['parent'],this['_updateCache']());},_0x1850d8['prototype']['_getActionManagerForTrigger']=function(_0x58a1c4,_0x289ec8){return void 0x0===_0x289ec8&&(_0x289ec8=!0x0),this['parent']?this['parent']['_getActionManagerForTrigger'](_0x58a1c4,!0x1):null;},_0x1850d8['prototype']['_updateCache']=function(_0x1f3431){},_0x1850d8['prototype']['_isSynchronized']=function(){return!0x0;},_0x1850d8['prototype']['_markSyncedWithParent']=function(){this['_parentNode']&&(this['_parentUpdateId']=this['_parentNode']['_childUpdateId']);},_0x1850d8['prototype']['isSynchronizedWithParent']=function(){return!this['_parentNode']||this['_parentUpdateId']===this['_parentNode']['_childUpdateId']&&this['_parentNode']['isSynchronized']();},_0x1850d8['prototype']['isSynchronized']=function(){return this['_cache']['parent']!=this['_parentNode']?(this['_cache']['parent']=this['_parentNode'],!0x1):!(this['_parentNode']&&!this['isSynchronizedWithParent']())&&this['_isSynchronized']();},_0x1850d8['prototype']['isReady']=function(_0x4fa809){return void 0x0===_0x4fa809&&(_0x4fa809=!0x1),this['_isReady'];},_0x1850d8['prototype']['isEnabled']=function(_0x59095e){return void 0x0===_0x59095e&&(_0x59095e=!0x0),!0x1===_0x59095e?this['_isEnabled']:!!this['_isEnabled']&&this['_isParentEnabled'];},_0x1850d8['prototype']['_syncParentEnabledState']=function(){this['_isParentEnabled']=!this['_parentNode']||this['_parentNode']['isEnabled'](),this['_children']&&this['_children']['forEach'](function(_0x5aaecb){_0x5aaecb['_syncParentEnabledState']();});},_0x1850d8['prototype']['setEnabled']=function(_0x70d191){this['_isEnabled']=_0x70d191,this['_syncParentEnabledState']();},_0x1850d8['prototype']['isDescendantOf']=function(_0x1fe9b1){return!!this['parent']&&(this['parent']===_0x1fe9b1||this['parent']['isDescendantOf'](_0x1fe9b1));},_0x1850d8['prototype']['_getDescendants']=function(_0x3a7ea4,_0x29ded1,_0x2a015e){if(void 0x0===_0x29ded1&&(_0x29ded1=!0x1),this['_children'])for(var _0x48473c=0x0;_0x48473c0x0,_0x48c0ad['REFLECTIONOVERALPHA']=this['_useReflectionOverAlpha'],_0x48c0ad['INVERTCUBICMAP']=this['_reflectionTexture']['coordinatesMode']===_0x484f5e['a']['INVCUBIC_MODE'],_0x48c0ad['REFLECTIONMAP_3D']=this['_reflectionTexture']['isCube'],_0x48c0ad['RGBDREFLECTION']=this['_reflectionTexture']['isRGBD'],this['_reflectionTexture']['coordinatesMode']){case _0x484f5e['a']['EXPLICIT_MODE']:_0x48c0ad['setReflectionMode']('REFLECTIONMAP_EXPLICIT');break;case _0x484f5e['a']['PLANAR_MODE']:_0x48c0ad['setReflectionMode']('REFLECTIONMAP_PLANAR');break;case _0x484f5e['a']['PROJECTION_MODE']:_0x48c0ad['setReflectionMode']('REFLECTIONMAP_PROJECTION');break;case _0x484f5e['a']['SKYBOX_MODE']:_0x48c0ad['setReflectionMode']('REFLECTIONMAP_SKYBOX');break;case _0x484f5e['a']['SPHERICAL_MODE']:_0x48c0ad['setReflectionMode']('REFLECTIONMAP_SPHERICAL');break;case _0x484f5e['a']['EQUIRECTANGULAR_MODE']:_0x48c0ad['setReflectionMode']('REFLECTIONMAP_EQUIRECTANGULAR');break;case _0x484f5e['a']['FIXED_EQUIRECTANGULAR_MODE']:_0x48c0ad['setReflectionMode']('REFLECTIONMAP_EQUIRECTANGULAR_FIXED');break;case _0x484f5e['a']['FIXED_EQUIRECTANGULAR_MIRRORED_MODE']:_0x48c0ad['setReflectionMode']('REFLECTIONMAP_MIRROREDEQUIRECTANGULAR_FIXED');break;case _0x484f5e['a']['CUBIC_MODE']:case _0x484f5e['a']['INVCUBIC_MODE']:default:_0x48c0ad['setReflectionMode']('REFLECTIONMAP_CUBIC');}_0x48c0ad['USE_LOCAL_REFLECTIONMAP_CUBIC']=!!this['_reflectionTexture']['boundingBoxSize'];}else _0x48c0ad['REFLECTION']=!0x1;if(this['_emissiveTexture']&&_0x533010['EmissiveTextureEnabled']){if(!this['_emissiveTexture']['isReadyOrNotBlocking']())return!0x1;_0xd948c4['a']['PrepareDefinesForMergedUV'](this['_emissiveTexture'],_0x48c0ad,'EMISSIVE');}else _0x48c0ad['EMISSIVE']=!0x1;if(this['_lightmapTexture']&&_0x533010['LightmapTextureEnabled']){if(!this['_lightmapTexture']['isReadyOrNotBlocking']())return!0x1;_0xd948c4['a']['PrepareDefinesForMergedUV'](this['_lightmapTexture'],_0x48c0ad,'LIGHTMAP'),_0x48c0ad['USELIGHTMAPASSHADOWMAP']=this['_useLightmapAsShadowmap'],_0x48c0ad['RGBDLIGHTMAP']=this['_lightmapTexture']['isRGBD'];}else _0x48c0ad['LIGHTMAP']=!0x1;if(this['_specularTexture']&&_0x533010['SpecularTextureEnabled']){if(!this['_specularTexture']['isReadyOrNotBlocking']())return!0x1;_0xd948c4['a']['PrepareDefinesForMergedUV'](this['_specularTexture'],_0x48c0ad,'SPECULAR'),_0x48c0ad['GLOSSINESS']=this['_useGlossinessFromSpecularMapAlpha'];}else _0x48c0ad['SPECULAR']=!0x1;if(_0x34e176['getEngine']()['getCaps']()['standardDerivatives']&&this['_bumpTexture']&&_0x533010['BumpTextureEnabled']){if(!this['_bumpTexture']['isReady']())return!0x1;_0xd948c4['a']['PrepareDefinesForMergedUV'](this['_bumpTexture'],_0x48c0ad,'BUMP'),_0x48c0ad['PARALLAX']=this['_useParallax'],_0x48c0ad['PARALLAXOCCLUSION']=this['_useParallaxOcclusion'],_0x48c0ad['OBJECTSPACE_NORMALMAP']=this['_useObjectSpaceNormalMap'];}else _0x48c0ad['BUMP']=!0x1;if(this['_refractionTexture']&&_0x533010['RefractionTextureEnabled']){if(!this['_refractionTexture']['isReadyOrNotBlocking']())return!0x1;_0x48c0ad['_needUVs']=!0x0,_0x48c0ad['REFRACTION']=!0x0,_0x48c0ad['REFRACTIONMAP_3D']=this['_refractionTexture']['isCube'],_0x48c0ad['RGBDREFRACTION']=this['_refractionTexture']['isRGBD'];}else _0x48c0ad['REFRACTION']=!0x1;_0x48c0ad['TWOSIDEDLIGHTING']=!this['_backFaceCulling']&&this['_twoSidedLighting'];}else _0x48c0ad['DIFFUSE']=!0x1,_0x48c0ad['AMBIENT']=!0x1,_0x48c0ad['OPACITY']=!0x1,_0x48c0ad['REFLECTION']=!0x1,_0x48c0ad['EMISSIVE']=!0x1,_0x48c0ad['LIGHTMAP']=!0x1,_0x48c0ad['BUMP']=!0x1,_0x48c0ad['REFRACTION']=!0x1;_0x48c0ad['ALPHAFROMDIFFUSE']=this['_shouldUseAlphaFromDiffuseTexture'](),_0x48c0ad['EMISSIVEASILLUMINATION']=this['_useEmissiveAsIllumination'],_0x48c0ad['LINKEMISSIVEWITHDIFFUSE']=this['_linkEmissiveWithDiffuse'],_0x48c0ad['SPECULAROVERALPHA']=this['_useSpecularOverAlpha'],_0x48c0ad['PREMULTIPLYALPHA']=this['alphaMode']===_0x15b63a['a']['ALPHA_PREMULTIPLIED']||this['alphaMode']===_0x15b63a['a']['ALPHA_PREMULTIPLIED_PORTERDUFF'],_0x48c0ad['ALPHATEST_AFTERALLALPHACOMPUTATIONS']=null!==this['transparencyMode'],_0x48c0ad['ALPHABLEND']=null===this['transparencyMode']||this['needAlphaBlendingForMesh'](_0x27a79b);}if(!this['detailMap']['isReadyForSubMesh'](_0x48c0ad,_0x34e176))return!0x1;if(_0x48c0ad['_areImageProcessingDirty']&&this['_imageProcessingConfiguration']){if(!this['_imageProcessingConfiguration']['isReady']())return!0x1;this['_imageProcessingConfiguration']['prepareDefines'](_0x48c0ad),_0x48c0ad['IS_REFLECTION_LINEAR']=null!=this['reflectionTexture']&&!this['reflectionTexture']['gammaSpace'],_0x48c0ad['IS_REFRACTION_LINEAR']=null!=this['refractionTexture']&&!this['refractionTexture']['gammaSpace'];}if(_0x48c0ad['_areFresnelDirty']&&(_0x533010['FresnelEnabled']?(this['_diffuseFresnelParameters']||this['_opacityFresnelParameters']||this['_emissiveFresnelParameters']||this['_refractionFresnelParameters']||this['_reflectionFresnelParameters'])&&(_0x48c0ad['DIFFUSEFRESNEL']=this['_diffuseFresnelParameters']&&this['_diffuseFresnelParameters']['isEnabled'],_0x48c0ad['OPACITYFRESNEL']=this['_opacityFresnelParameters']&&this['_opacityFresnelParameters']['isEnabled'],_0x48c0ad['REFLECTIONFRESNEL']=this['_reflectionFresnelParameters']&&this['_reflectionFresnelParameters']['isEnabled'],_0x48c0ad['REFLECTIONFRESNELFROMSPECULAR']=this['_useReflectionFresnelFromSpecular'],_0x48c0ad['REFRACTIONFRESNEL']=this['_refractionFresnelParameters']&&this['_refractionFresnelParameters']['isEnabled'],_0x48c0ad['EMISSIVEFRESNEL']=this['_emissiveFresnelParameters']&&this['_emissiveFresnelParameters']['isEnabled'],_0x48c0ad['_needNormals']=!0x0,_0x48c0ad['FRESNEL']=!0x0):_0x48c0ad['FRESNEL']=!0x1),_0xd948c4['a']['PrepareDefinesForMisc'](_0x27a79b,_0x34e176,this['_useLogarithmicDepth'],this['pointsCloud'],this['fogEnabled'],this['_shouldTurnAlphaTestOn'](_0x27a79b)||this['_forceAlphaTest'],_0x48c0ad),_0xd948c4['a']['PrepareDefinesForAttributes'](_0x27a79b,_0x48c0ad,!0x0,!0x0,!0x0),_0xd948c4['a']['PrepareDefinesForFrameBoundValues'](_0x34e176,_0x54b602,_0x48c0ad,_0x5d5694,null,_0x5a7aff['getRenderingMesh']()['hasThinInstances']),this['detailMap']['prepareDefines'](_0x48c0ad,_0x34e176),_0x48c0ad['isDirty']){var _0x230de4=_0x48c0ad['_areLightsDisposed'];_0x48c0ad['markAsProcessed']();var _0x2a84de=new _0x49c2e1['a']();_0x48c0ad['REFLECTION']&&_0x2a84de['addFallback'](0x0,'REFLECTION'),_0x48c0ad['SPECULAR']&&_0x2a84de['addFallback'](0x0,'SPECULAR'),_0x48c0ad['BUMP']&&_0x2a84de['addFallback'](0x0,'BUMP'),_0x48c0ad['PARALLAX']&&_0x2a84de['addFallback'](0x1,'PARALLAX'),_0x48c0ad['PARALLAXOCCLUSION']&&_0x2a84de['addFallback'](0x0,'PARALLAXOCCLUSION'),_0x48c0ad['SPECULAROVERALPHA']&&_0x2a84de['addFallback'](0x0,'SPECULAROVERALPHA'),_0x48c0ad['FOG']&&_0x2a84de['addFallback'](0x1,'FOG'),_0x48c0ad['POINTSIZE']&&_0x2a84de['addFallback'](0x0,'POINTSIZE'),_0x48c0ad['LOGARITHMICDEPTH']&&_0x2a84de['addFallback'](0x0,'LOGARITHMICDEPTH'),_0xd948c4['a']['HandleFallbacksForShadows'](_0x48c0ad,_0x2a84de,this['_maxSimultaneousLights']),_0x48c0ad['SPECULARTERM']&&_0x2a84de['addFallback'](0x0,'SPECULARTERM'),_0x48c0ad['DIFFUSEFRESNEL']&&_0x2a84de['addFallback'](0x1,'DIFFUSEFRESNEL'),_0x48c0ad['OPACITYFRESNEL']&&_0x2a84de['addFallback'](0x2,'OPACITYFRESNEL'),_0x48c0ad['REFLECTIONFRESNEL']&&_0x2a84de['addFallback'](0x3,'REFLECTIONFRESNEL'),_0x48c0ad['EMISSIVEFRESNEL']&&_0x2a84de['addFallback'](0x4,'EMISSIVEFRESNEL'),_0x48c0ad['FRESNEL']&&_0x2a84de['addFallback'](0x4,'FRESNEL'),_0x48c0ad['MULTIVIEW']&&_0x2a84de['addFallback'](0x0,'MULTIVIEW');var _0x20dd1c=[_0x291d1e['b']['PositionKind']];_0x48c0ad['NORMAL']&&_0x20dd1c['push'](_0x291d1e['b']['NormalKind']),_0x48c0ad['UV1']&&_0x20dd1c['push'](_0x291d1e['b']['UVKind']),_0x48c0ad['UV2']&&_0x20dd1c['push'](_0x291d1e['b']['UV2Kind']),_0x48c0ad['VERTEXCOLOR']&&_0x20dd1c['push'](_0x291d1e['b']['ColorKind']),_0xd948c4['a']['PrepareAttributesForBones'](_0x20dd1c,_0x27a79b,_0x48c0ad,_0x2a84de),_0xd948c4['a']['PrepareAttributesForInstances'](_0x20dd1c,_0x48c0ad),_0xd948c4['a']['PrepareAttributesForMorphTargets'](_0x20dd1c,_0x27a79b,_0x48c0ad);var _0x5659c6='default',_0x5da63e=['world','view','viewProjection','vEyePosition','vLightsType','vAmbientColor','vDiffuseColor','vSpecularColor','vEmissiveColor','visibility','vFogInfos','vFogColor','pointSize','vDiffuseInfos','vAmbientInfos','vOpacityInfos','vReflectionInfos','vEmissiveInfos','vSpecularInfos','vBumpInfos','vLightmapInfos','vRefractionInfos','mBones','vClipPlane','vClipPlane2','vClipPlane3','vClipPlane4','vClipPlane5','vClipPlane6','diffuseMatrix','ambientMatrix','opacityMatrix','reflectionMatrix','emissiveMatrix','specularMatrix','bumpMatrix','normalMatrix','lightmapMatrix','refractionMatrix','diffuseLeftColor','diffuseRightColor','opacityParts','reflectionLeftColor','reflectionRightColor','emissiveLeftColor','emissiveRightColor','refractionLeftColor','refractionRightColor','vReflectionPosition','vReflectionSize','logarithmicDepthConstant','vTangentSpaceParams','alphaCutOff','boneTextureWidth'],_0x33dd59=['diffuseSampler','ambientSampler','opacitySampler','reflectionCubeSampler','reflection2DSampler','emissiveSampler','specularSampler','bumpSampler','lightmapSampler','refractionCubeSampler','refraction2DSampler','boneSampler'],_0x2eaef3=['Material','Scene'];_0x1bd205['a']['AddUniforms'](_0x5da63e),_0x1bd205['a']['AddSamplers'](_0x33dd59),_0x2ab302['a']['AddUniforms'](_0x5da63e),_0x2ab302['a']['AddSamplers'](_0x5da63e),_0x2f5784['a']&&(_0x2f5784['a']['PrepareUniforms'](_0x5da63e,_0x48c0ad),_0x2f5784['a']['PrepareSamplers'](_0x33dd59,_0x48c0ad)),_0xd948c4['a']['PrepareUniformsAndSamplersList']({'uniformsNames':_0x5da63e,'uniformBuffersNames':_0x2eaef3,'samplers':_0x33dd59,'defines':_0x48c0ad,'maxSimultaneousLights':this['_maxSimultaneousLights']});var _0x46b499={};this['customShaderNameResolve']&&(_0x5659c6=this['customShaderNameResolve'](_0x5659c6,_0x5da63e,_0x2eaef3,_0x33dd59,_0x48c0ad,_0x20dd1c,_0x46b499));var _0x50851a=_0x48c0ad['toString'](),_0x41a482=_0x5a7aff['effect'],_0x519cf3=_0x34e176['getEngine']()['createEffect'](_0x5659c6,{'attributes':_0x20dd1c,'uniformsNames':_0x5da63e,'uniformBuffersNames':_0x2eaef3,'samplers':_0x33dd59,'defines':_0x50851a,'fallbacks':_0x2a84de,'onCompiled':this['onCompiled'],'onError':this['onError'],'indexParameters':{'maxSimultaneousLights':this['_maxSimultaneousLights'],'maxSimultaneousMorphTargets':_0x48c0ad['NUM_MORPH_INFLUENCERS']},'processFinalCode':_0x46b499['processFinalCode'],'multiTarget':_0x48c0ad['PREPASS']},_0x54b602);if(_0x519cf3){if(this['_onEffectCreatedObservable']&&(_0x31409c['effect']=_0x519cf3,_0x31409c['subMesh']=_0x5a7aff,this['_onEffectCreatedObservable']['notifyObservers'](_0x31409c)),this['allowShaderHotSwapping']&&_0x41a482&&!_0x519cf3['isReady']()){if(_0x519cf3=_0x41a482,this['_rebuildInParallel']=!0x0,_0x48c0ad['markAsUnprocessed'](),_0x230de4)return _0x48c0ad['_areLightsDisposed']=!0x0,!0x1;}else this['_rebuildInParallel']=!0x1,_0x34e176['resetCachedMaterial'](),_0x5a7aff['setEffect'](_0x519cf3,_0x48c0ad),this['buildUniformLayout']();}}return!(!_0x5a7aff['effect']||!_0x5a7aff['effect']['isReady']())&&(_0x48c0ad['_renderId']=_0x34e176['getRenderId'](),_0x5a7aff['effect']['_wasPreviouslyReady']=!0x0,!0x0);},_0x533010['prototype']['buildUniformLayout']=function(){var _0x2a68fe=this['_uniformBuffer'];_0x2a68fe['addUniform']('diffuseLeftColor',0x4),_0x2a68fe['addUniform']('diffuseRightColor',0x4),_0x2a68fe['addUniform']('opacityParts',0x4),_0x2a68fe['addUniform']('reflectionLeftColor',0x4),_0x2a68fe['addUniform']('reflectionRightColor',0x4),_0x2a68fe['addUniform']('refractionLeftColor',0x4),_0x2a68fe['addUniform']('refractionRightColor',0x4),_0x2a68fe['addUniform']('emissiveLeftColor',0x4),_0x2a68fe['addUniform']('emissiveRightColor',0x4),_0x2a68fe['addUniform']('vDiffuseInfos',0x2),_0x2a68fe['addUniform']('vAmbientInfos',0x2),_0x2a68fe['addUniform']('vOpacityInfos',0x2),_0x2a68fe['addUniform']('vReflectionInfos',0x2),_0x2a68fe['addUniform']('vReflectionPosition',0x3),_0x2a68fe['addUniform']('vReflectionSize',0x3),_0x2a68fe['addUniform']('vEmissiveInfos',0x2),_0x2a68fe['addUniform']('vLightmapInfos',0x2),_0x2a68fe['addUniform']('vSpecularInfos',0x2),_0x2a68fe['addUniform']('vBumpInfos',0x3),_0x2a68fe['addUniform']('diffuseMatrix',0x10),_0x2a68fe['addUniform']('ambientMatrix',0x10),_0x2a68fe['addUniform']('opacityMatrix',0x10),_0x2a68fe['addUniform']('reflectionMatrix',0x10),_0x2a68fe['addUniform']('emissiveMatrix',0x10),_0x2a68fe['addUniform']('lightmapMatrix',0x10),_0x2a68fe['addUniform']('specularMatrix',0x10),_0x2a68fe['addUniform']('bumpMatrix',0x10),_0x2a68fe['addUniform']('vTangentSpaceParams',0x2),_0x2a68fe['addUniform']('pointSize',0x1),_0x2a68fe['addUniform']('refractionMatrix',0x10),_0x2a68fe['addUniform']('vRefractionInfos',0x4),_0x2a68fe['addUniform']('vSpecularColor',0x4),_0x2a68fe['addUniform']('vEmissiveColor',0x3),_0x2a68fe['addUniform']('visibility',0x1),_0x2a68fe['addUniform']('vDiffuseColor',0x4),_0x1bd205['a']['PrepareUniformBuffer'](_0x2a68fe),_0x2a68fe['create']();},_0x533010['prototype']['unbind']=function(){if(this['_activeEffect']){var _0x129aaa=!0x1;this['_reflectionTexture']&&this['_reflectionTexture']['isRenderTarget']&&(this['_activeEffect']['setTexture']('reflection2DSampler',null),_0x129aaa=!0x0),this['_refractionTexture']&&this['_refractionTexture']['isRenderTarget']&&(this['_activeEffect']['setTexture']('refraction2DSampler',null),_0x129aaa=!0x0),_0x129aaa&&this['_markAllSubMeshesAsTexturesDirty']();}_0x3132dc['prototype']['unbind']['call'](this);},_0x533010['prototype']['bindForSubMesh']=function(_0x3b7c65,_0xb750b4,_0x455b6e){var _0x24888a=this['getScene'](),_0xb5c09a=_0x455b6e['_materialDefines'];if(_0xb5c09a){var _0x58b5f6=_0x455b6e['effect'];if(_0x58b5f6){this['_activeEffect']=_0x58b5f6,_0xb5c09a['INSTANCES']&&!_0xb5c09a['THIN_INSTANCES']||this['bindOnlyWorldMatrix'](_0x3b7c65),this['prePassConfiguration']['bindForSubMesh'](this['_activeEffect'],_0x24888a,_0xb750b4,_0x3b7c65,this['isFrozen']),_0xb5c09a['OBJECTSPACE_NORMALMAP']&&(_0x3b7c65['toNormalMatrix'](this['_normalMatrix']),this['bindOnlyNormalMatrix'](this['_normalMatrix']));var _0xb80498=this['_mustRebind'](_0x24888a,_0x58b5f6,_0xb750b4['visibility']);_0xd948c4['a']['BindBonesParameters'](_0xb750b4,_0x58b5f6);var _0x24f115=this['_uniformBuffer'];if(_0xb80498){if(_0x24f115['bindToEffect'](_0x58b5f6,'Material'),this['bindViewProjection'](_0x58b5f6),!_0x24f115['useUbo']||!this['isFrozen']||!_0x24f115['isSync']){if(_0x533010['FresnelEnabled']&&_0xb5c09a['FRESNEL']&&(this['diffuseFresnelParameters']&&this['diffuseFresnelParameters']['isEnabled']&&(_0x24f115['updateColor4']('diffuseLeftColor',this['diffuseFresnelParameters']['leftColor'],this['diffuseFresnelParameters']['power']),_0x24f115['updateColor4']('diffuseRightColor',this['diffuseFresnelParameters']['rightColor'],this['diffuseFresnelParameters']['bias'])),this['opacityFresnelParameters']&&this['opacityFresnelParameters']['isEnabled']&&_0x24f115['updateColor4']('opacityParts',new _0x313da2['a'](this['opacityFresnelParameters']['leftColor']['toLuminance'](),this['opacityFresnelParameters']['rightColor']['toLuminance'](),this['opacityFresnelParameters']['bias']),this['opacityFresnelParameters']['power']),this['reflectionFresnelParameters']&&this['reflectionFresnelParameters']['isEnabled']&&(_0x24f115['updateColor4']('reflectionLeftColor',this['reflectionFresnelParameters']['leftColor'],this['reflectionFresnelParameters']['power']),_0x24f115['updateColor4']('reflectionRightColor',this['reflectionFresnelParameters']['rightColor'],this['reflectionFresnelParameters']['bias'])),this['refractionFresnelParameters']&&this['refractionFresnelParameters']['isEnabled']&&(_0x24f115['updateColor4']('refractionLeftColor',this['refractionFresnelParameters']['leftColor'],this['refractionFresnelParameters']['power']),_0x24f115['updateColor4']('refractionRightColor',this['refractionFresnelParameters']['rightColor'],this['refractionFresnelParameters']['bias'])),this['emissiveFresnelParameters']&&this['emissiveFresnelParameters']['isEnabled']&&(_0x24f115['updateColor4']('emissiveLeftColor',this['emissiveFresnelParameters']['leftColor'],this['emissiveFresnelParameters']['power']),_0x24f115['updateColor4']('emissiveRightColor',this['emissiveFresnelParameters']['rightColor'],this['emissiveFresnelParameters']['bias']))),_0x24888a['texturesEnabled']){if(this['_diffuseTexture']&&_0x533010['DiffuseTextureEnabled']&&(_0x24f115['updateFloat2']('vDiffuseInfos',this['_diffuseTexture']['coordinatesIndex'],this['_diffuseTexture']['level']),_0xd948c4['a']['BindTextureMatrix'](this['_diffuseTexture'],_0x24f115,'diffuse')),this['_ambientTexture']&&_0x533010['AmbientTextureEnabled']&&(_0x24f115['updateFloat2']('vAmbientInfos',this['_ambientTexture']['coordinatesIndex'],this['_ambientTexture']['level']),_0xd948c4['a']['BindTextureMatrix'](this['_ambientTexture'],_0x24f115,'ambient')),this['_opacityTexture']&&_0x533010['OpacityTextureEnabled']&&(_0x24f115['updateFloat2']('vOpacityInfos',this['_opacityTexture']['coordinatesIndex'],this['_opacityTexture']['level']),_0xd948c4['a']['BindTextureMatrix'](this['_opacityTexture'],_0x24f115,'opacity')),this['_hasAlphaChannel']()&&_0x58b5f6['setFloat']('alphaCutOff',this['alphaCutOff']),this['_reflectionTexture']&&_0x533010['ReflectionTextureEnabled']&&(_0x24f115['updateFloat2']('vReflectionInfos',this['_reflectionTexture']['level'],this['roughness']),_0x24f115['updateMatrix']('reflectionMatrix',this['_reflectionTexture']['getReflectionTextureMatrix']()),this['_reflectionTexture']['boundingBoxSize'])){var _0x46ea7b=this['_reflectionTexture'];_0x24f115['updateVector3']('vReflectionPosition',_0x46ea7b['boundingBoxPosition']),_0x24f115['updateVector3']('vReflectionSize',_0x46ea7b['boundingBoxSize']);}if(this['_emissiveTexture']&&_0x533010['EmissiveTextureEnabled']&&(_0x24f115['updateFloat2']('vEmissiveInfos',this['_emissiveTexture']['coordinatesIndex'],this['_emissiveTexture']['level']),_0xd948c4['a']['BindTextureMatrix'](this['_emissiveTexture'],_0x24f115,'emissive')),this['_lightmapTexture']&&_0x533010['LightmapTextureEnabled']&&(_0x24f115['updateFloat2']('vLightmapInfos',this['_lightmapTexture']['coordinatesIndex'],this['_lightmapTexture']['level']),_0xd948c4['a']['BindTextureMatrix'](this['_lightmapTexture'],_0x24f115,'lightmap')),this['_specularTexture']&&_0x533010['SpecularTextureEnabled']&&(_0x24f115['updateFloat2']('vSpecularInfos',this['_specularTexture']['coordinatesIndex'],this['_specularTexture']['level']),_0xd948c4['a']['BindTextureMatrix'](this['_specularTexture'],_0x24f115,'specular')),this['_bumpTexture']&&_0x24888a['getEngine']()['getCaps']()['standardDerivatives']&&_0x533010['BumpTextureEnabled']&&(_0x24f115['updateFloat3']('vBumpInfos',this['_bumpTexture']['coordinatesIndex'],0x1/this['_bumpTexture']['level'],this['parallaxScaleBias']),_0xd948c4['a']['BindTextureMatrix'](this['_bumpTexture'],_0x24f115,'bump'),_0x24888a['_mirroredCameraPosition']?_0x24f115['updateFloat2']('vTangentSpaceParams',this['_invertNormalMapX']?0x1:-0x1,this['_invertNormalMapY']?0x1:-0x1):_0x24f115['updateFloat2']('vTangentSpaceParams',this['_invertNormalMapX']?-0x1:0x1,this['_invertNormalMapY']?-0x1:0x1)),this['_refractionTexture']&&_0x533010['RefractionTextureEnabled']){var _0x47c36c=0x1;this['_refractionTexture']['isCube']||(_0x24f115['updateMatrix']('refractionMatrix',this['_refractionTexture']['getReflectionTextureMatrix']()),this['_refractionTexture']['depth']&&(_0x47c36c=this['_refractionTexture']['depth'])),_0x24f115['updateFloat4']('vRefractionInfos',this['_refractionTexture']['level'],this['indexOfRefraction'],_0x47c36c,this['invertRefractionY']?-0x1:0x1);}}this['pointsCloud']&&_0x24f115['updateFloat']('pointSize',this['pointSize']),_0xb5c09a['SPECULARTERM']&&_0x24f115['updateColor4']('vSpecularColor',this['specularColor'],this['specularPower']),_0x24f115['updateColor3']('vEmissiveColor',_0x533010['EmissiveTextureEnabled']?this['emissiveColor']:_0x313da2['a']['BlackReadOnly']),_0x24f115['updateColor4']('vDiffuseColor',this['diffuseColor'],this['alpha']);}(_0x24f115['updateFloat']('visibility',_0xb750b4['visibility']),_0x24888a['texturesEnabled']&&(this['_diffuseTexture']&&_0x533010['DiffuseTextureEnabled']&&_0x58b5f6['setTexture']('diffuseSampler',this['_diffuseTexture']),this['_ambientTexture']&&_0x533010['AmbientTextureEnabled']&&_0x58b5f6['setTexture']('ambientSampler',this['_ambientTexture']),this['_opacityTexture']&&_0x533010['OpacityTextureEnabled']&&_0x58b5f6['setTexture']('opacitySampler',this['_opacityTexture']),this['_reflectionTexture']&&_0x533010['ReflectionTextureEnabled']&&(this['_reflectionTexture']['isCube']?_0x58b5f6['setTexture']('reflectionCubeSampler',this['_reflectionTexture']):_0x58b5f6['setTexture']('reflection2DSampler',this['_reflectionTexture'])),this['_emissiveTexture']&&_0x533010['EmissiveTextureEnabled']&&_0x58b5f6['setTexture']('emissiveSampler',this['_emissiveTexture']),this['_lightmapTexture']&&_0x533010['LightmapTextureEnabled']&&_0x58b5f6['setTexture']('lightmapSampler',this['_lightmapTexture']),this['_specularTexture']&&_0x533010['SpecularTextureEnabled']&&_0x58b5f6['setTexture']('specularSampler',this['_specularTexture']),this['_bumpTexture']&&_0x24888a['getEngine']()['getCaps']()['standardDerivatives']&&_0x533010['BumpTextureEnabled']&&_0x58b5f6['setTexture']('bumpSampler',this['_bumpTexture']),this['_refractionTexture']&&_0x533010['RefractionTextureEnabled']))&&(_0x47c36c=0x1,this['_refractionTexture']['isCube']?_0x58b5f6['setTexture']('refractionCubeSampler',this['_refractionTexture']):_0x58b5f6['setTexture']('refraction2DSampler',this['_refractionTexture'])),this['detailMap']['bindForSubMesh'](_0x24f115,_0x24888a,this['isFrozen']),_0xd948c4['a']['BindClipPlane'](_0x58b5f6,_0x24888a),_0x24888a['ambientColor']['multiplyToRef'](this['ambientColor'],this['_globalAmbientColor']),_0xd948c4['a']['BindEyePosition'](_0x58b5f6,_0x24888a),_0x58b5f6['setColor3']('vAmbientColor',this['_globalAmbientColor']);}!_0xb80498&&this['isFrozen']||(_0x24888a['lightsEnabled']&&!this['_disableLighting']&&_0xd948c4['a']['BindLights'](_0x24888a,_0xb750b4,_0x58b5f6,_0xb5c09a,this['_maxSimultaneousLights'],this['_rebuildInParallel']),(_0x24888a['fogEnabled']&&_0xb750b4['applyFog']&&_0x24888a['fogMode']!==_0x479f57['a']['FOGMODE_NONE']||this['_reflectionTexture']||this['_refractionTexture'])&&this['bindView'](_0x58b5f6),_0xd948c4['a']['BindFogParameters'](_0x24888a,_0xb750b4,_0x58b5f6),_0xb5c09a['NUM_MORPH_INFLUENCERS']&&_0xd948c4['a']['BindMorphTargetParameters'](_0xb750b4,_0x58b5f6),this['useLogarithmicDepth']&&_0xd948c4['a']['BindLogDepth'](_0xb5c09a,_0x58b5f6,_0x24888a),this['_imageProcessingConfiguration']&&!this['_imageProcessingConfiguration']['applyByPostProcess']&&this['_imageProcessingConfiguration']['bind'](this['_activeEffect'])),_0x24f115['update'](),this['_afterBind'](_0xb750b4,this['_activeEffect']);}}},_0x533010['prototype']['getAnimatables']=function(){var _0x50a37a=[];return this['_diffuseTexture']&&this['_diffuseTexture']['animations']&&this['_diffuseTexture']['animations']['length']>0x0&&_0x50a37a['push'](this['_diffuseTexture']),this['_ambientTexture']&&this['_ambientTexture']['animations']&&this['_ambientTexture']['animations']['length']>0x0&&_0x50a37a['push'](this['_ambientTexture']),this['_opacityTexture']&&this['_opacityTexture']['animations']&&this['_opacityTexture']['animations']['length']>0x0&&_0x50a37a['push'](this['_opacityTexture']),this['_reflectionTexture']&&this['_reflectionTexture']['animations']&&this['_reflectionTexture']['animations']['length']>0x0&&_0x50a37a['push'](this['_reflectionTexture']),this['_emissiveTexture']&&this['_emissiveTexture']['animations']&&this['_emissiveTexture']['animations']['length']>0x0&&_0x50a37a['push'](this['_emissiveTexture']),this['_specularTexture']&&this['_specularTexture']['animations']&&this['_specularTexture']['animations']['length']>0x0&&_0x50a37a['push'](this['_specularTexture']),this['_bumpTexture']&&this['_bumpTexture']['animations']&&this['_bumpTexture']['animations']['length']>0x0&&_0x50a37a['push'](this['_bumpTexture']),this['_lightmapTexture']&&this['_lightmapTexture']['animations']&&this['_lightmapTexture']['animations']['length']>0x0&&_0x50a37a['push'](this['_lightmapTexture']),this['_refractionTexture']&&this['_refractionTexture']['animations']&&this['_refractionTexture']['animations']['length']>0x0&&_0x50a37a['push'](this['_refractionTexture']),this['detailMap']['getAnimatables'](_0x50a37a),_0x50a37a;},_0x533010['prototype']['getActiveTextures']=function(){var _0x197a25=_0x3132dc['prototype']['getActiveTextures']['call'](this);return this['_diffuseTexture']&&_0x197a25['push'](this['_diffuseTexture']),this['_ambientTexture']&&_0x197a25['push'](this['_ambientTexture']),this['_opacityTexture']&&_0x197a25['push'](this['_opacityTexture']),this['_reflectionTexture']&&_0x197a25['push'](this['_reflectionTexture']),this['_emissiveTexture']&&_0x197a25['push'](this['_emissiveTexture']),this['_specularTexture']&&_0x197a25['push'](this['_specularTexture']),this['_bumpTexture']&&_0x197a25['push'](this['_bumpTexture']),this['_lightmapTexture']&&_0x197a25['push'](this['_lightmapTexture']),this['_refractionTexture']&&_0x197a25['push'](this['_refractionTexture']),this['detailMap']['getActiveTextures'](_0x197a25),_0x197a25;},_0x533010['prototype']['hasTexture']=function(_0x32223b){return!!_0x3132dc['prototype']['hasTexture']['call'](this,_0x32223b)||(this['_diffuseTexture']===_0x32223b||(this['_ambientTexture']===_0x32223b||(this['_opacityTexture']===_0x32223b||(this['_reflectionTexture']===_0x32223b||(this['_emissiveTexture']===_0x32223b||(this['_specularTexture']===_0x32223b||(this['_bumpTexture']===_0x32223b||(this['_lightmapTexture']===_0x32223b||(this['_refractionTexture']===_0x32223b||this['detailMap']['hasTexture'](_0x32223b))))))))));},_0x533010['prototype']['dispose']=function(_0x5e8a76,_0x21388f){var _0x1810e3,_0xacbe50,_0x6fea5c,_0x22bfd7,_0x53c6e1,_0x5596a7,_0x586e2d,_0x4b4626,_0x244bb7;_0x21388f&&(null===(_0x1810e3=this['_diffuseTexture'])||void 0x0===_0x1810e3||_0x1810e3['dispose'](),null===(_0xacbe50=this['_ambientTexture'])||void 0x0===_0xacbe50||_0xacbe50['dispose'](),null===(_0x6fea5c=this['_opacityTexture'])||void 0x0===_0x6fea5c||_0x6fea5c['dispose'](),null===(_0x22bfd7=this['_reflectionTexture'])||void 0x0===_0x22bfd7||_0x22bfd7['dispose'](),null===(_0x53c6e1=this['_emissiveTexture'])||void 0x0===_0x53c6e1||_0x53c6e1['dispose'](),null===(_0x5596a7=this['_specularTexture'])||void 0x0===_0x5596a7||_0x5596a7['dispose'](),null===(_0x586e2d=this['_bumpTexture'])||void 0x0===_0x586e2d||_0x586e2d['dispose'](),null===(_0x4b4626=this['_lightmapTexture'])||void 0x0===_0x4b4626||_0x4b4626['dispose'](),null===(_0x244bb7=this['_refractionTexture'])||void 0x0===_0x244bb7||_0x244bb7['dispose']()),this['detailMap']['dispose'](_0x21388f),this['_imageProcessingConfiguration']&&this['_imageProcessingObserver']&&this['_imageProcessingConfiguration']['onUpdateParameters']['remove'](this['_imageProcessingObserver']),_0x3132dc['prototype']['dispose']['call'](this,_0x5e8a76,_0x21388f);},_0x533010['prototype']['clone']=function(_0x39088e){var _0x33d124=this,_0x1df36b=_0xc48114['a']['Clone'](function(){return new _0x533010(_0x39088e,_0x33d124['getScene']());},this);return _0x1df36b['name']=_0x39088e,_0x1df36b['id']=_0x39088e,_0x1df36b;},_0x533010['prototype']['serialize']=function(){return _0xc48114['a']['Serialize'](this);},_0x533010['Parse']=function(_0x86e6cd,_0x10d227,_0x30416b){return _0xc48114['a']['Parse'](function(){return new _0x533010(_0x86e6cd['name'],_0x10d227);},_0x86e6cd,_0x10d227,_0x30416b);},Object['defineProperty'](_0x533010,'DiffuseTextureEnabled',{'get':function(){return _0x4e93a4['a']['DiffuseTextureEnabled'];},'set':function(_0x3038ed){_0x4e93a4['a']['DiffuseTextureEnabled']=_0x3038ed;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x533010,'DetailTextureEnabled',{'get':function(){return _0x4e93a4['a']['DetailTextureEnabled'];},'set':function(_0x42444d){_0x4e93a4['a']['DetailTextureEnabled']=_0x42444d;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x533010,'AmbientTextureEnabled',{'get':function(){return _0x4e93a4['a']['AmbientTextureEnabled'];},'set':function(_0x3e2830){_0x4e93a4['a']['AmbientTextureEnabled']=_0x3e2830;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x533010,'OpacityTextureEnabled',{'get':function(){return _0x4e93a4['a']['OpacityTextureEnabled'];},'set':function(_0x3b3fde){_0x4e93a4['a']['OpacityTextureEnabled']=_0x3b3fde;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x533010,'ReflectionTextureEnabled',{'get':function(){return _0x4e93a4['a']['ReflectionTextureEnabled'];},'set':function(_0x38a86b){_0x4e93a4['a']['ReflectionTextureEnabled']=_0x38a86b;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x533010,'EmissiveTextureEnabled',{'get':function(){return _0x4e93a4['a']['EmissiveTextureEnabled'];},'set':function(_0x2437ca){_0x4e93a4['a']['EmissiveTextureEnabled']=_0x2437ca;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x533010,'SpecularTextureEnabled',{'get':function(){return _0x4e93a4['a']['SpecularTextureEnabled'];},'set':function(_0x406940){_0x4e93a4['a']['SpecularTextureEnabled']=_0x406940;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x533010,'BumpTextureEnabled',{'get':function(){return _0x4e93a4['a']['BumpTextureEnabled'];},'set':function(_0x3402f6){_0x4e93a4['a']['BumpTextureEnabled']=_0x3402f6;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x533010,'LightmapTextureEnabled',{'get':function(){return _0x4e93a4['a']['LightmapTextureEnabled'];},'set':function(_0x2d53ff){_0x4e93a4['a']['LightmapTextureEnabled']=_0x2d53ff;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x533010,'RefractionTextureEnabled',{'get':function(){return _0x4e93a4['a']['RefractionTextureEnabled'];},'set':function(_0x27251a){_0x4e93a4['a']['RefractionTextureEnabled']=_0x27251a;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x533010,'ColorGradingTextureEnabled',{'get':function(){return _0x4e93a4['a']['ColorGradingTextureEnabled'];},'set':function(_0xdcfcfc){_0x4e93a4['a']['ColorGradingTextureEnabled']=_0xdcfcfc;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x533010,'FresnelEnabled',{'get':function(){return _0x4e93a4['a']['FresnelEnabled'];},'set':function(_0x45284c){_0x4e93a4['a']['FresnelEnabled']=_0x45284c;},'enumerable':!0x1,'configurable':!0x0}),Object(_0x29185a['c'])([Object(_0xc48114['m'])('diffuseTexture')],_0x533010['prototype'],'_diffuseTexture',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesAndMiscDirty')],_0x533010['prototype'],'diffuseTexture',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['m'])('ambientTexture')],_0x533010['prototype'],'_ambientTexture',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesDirty')],_0x533010['prototype'],'ambientTexture',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['m'])('opacityTexture')],_0x533010['prototype'],'_opacityTexture',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesAndMiscDirty')],_0x533010['prototype'],'opacityTexture',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['m'])('reflectionTexture')],_0x533010['prototype'],'_reflectionTexture',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesDirty')],_0x533010['prototype'],'reflectionTexture',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['m'])('emissiveTexture')],_0x533010['prototype'],'_emissiveTexture',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesDirty')],_0x533010['prototype'],'emissiveTexture',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['m'])('specularTexture')],_0x533010['prototype'],'_specularTexture',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesDirty')],_0x533010['prototype'],'specularTexture',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['m'])('bumpTexture')],_0x533010['prototype'],'_bumpTexture',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesDirty')],_0x533010['prototype'],'bumpTexture',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['m'])('lightmapTexture')],_0x533010['prototype'],'_lightmapTexture',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesDirty')],_0x533010['prototype'],'lightmapTexture',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['m'])('refractionTexture')],_0x533010['prototype'],'_refractionTexture',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesDirty')],_0x533010['prototype'],'refractionTexture',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['e'])('ambient')],_0x533010['prototype'],'ambientColor',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['e'])('diffuse')],_0x533010['prototype'],'diffuseColor',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['e'])('specular')],_0x533010['prototype'],'specularColor',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['e'])('emissive')],_0x533010['prototype'],'emissiveColor',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])()],_0x533010['prototype'],'specularPower',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])('useAlphaFromDiffuseTexture')],_0x533010['prototype'],'_useAlphaFromDiffuseTexture',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesAndMiscDirty')],_0x533010['prototype'],'useAlphaFromDiffuseTexture',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])('useEmissiveAsIllumination')],_0x533010['prototype'],'_useEmissiveAsIllumination',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesDirty')],_0x533010['prototype'],'useEmissiveAsIllumination',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])('linkEmissiveWithDiffuse')],_0x533010['prototype'],'_linkEmissiveWithDiffuse',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesDirty')],_0x533010['prototype'],'linkEmissiveWithDiffuse',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])('useSpecularOverAlpha')],_0x533010['prototype'],'_useSpecularOverAlpha',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesDirty')],_0x533010['prototype'],'useSpecularOverAlpha',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])('useReflectionOverAlpha')],_0x533010['prototype'],'_useReflectionOverAlpha',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesDirty')],_0x533010['prototype'],'useReflectionOverAlpha',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])('disableLighting')],_0x533010['prototype'],'_disableLighting',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsLightsDirty')],_0x533010['prototype'],'disableLighting',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])('useObjectSpaceNormalMap')],_0x533010['prototype'],'_useObjectSpaceNormalMap',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesDirty')],_0x533010['prototype'],'useObjectSpaceNormalMap',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])('useParallax')],_0x533010['prototype'],'_useParallax',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesDirty')],_0x533010['prototype'],'useParallax',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])('useParallaxOcclusion')],_0x533010['prototype'],'_useParallaxOcclusion',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesDirty')],_0x533010['prototype'],'useParallaxOcclusion',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])()],_0x533010['prototype'],'parallaxScaleBias',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])('roughness')],_0x533010['prototype'],'_roughness',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesDirty')],_0x533010['prototype'],'roughness',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])()],_0x533010['prototype'],'indexOfRefraction',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])()],_0x533010['prototype'],'invertRefractionY',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])()],_0x533010['prototype'],'alphaCutOff',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])('useLightmapAsShadowmap')],_0x533010['prototype'],'_useLightmapAsShadowmap',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesDirty')],_0x533010['prototype'],'useLightmapAsShadowmap',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['h'])('diffuseFresnelParameters')],_0x533010['prototype'],'_diffuseFresnelParameters',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsFresnelDirty')],_0x533010['prototype'],'diffuseFresnelParameters',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['h'])('opacityFresnelParameters')],_0x533010['prototype'],'_opacityFresnelParameters',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsFresnelAndMiscDirty')],_0x533010['prototype'],'opacityFresnelParameters',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['h'])('reflectionFresnelParameters')],_0x533010['prototype'],'_reflectionFresnelParameters',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsFresnelDirty')],_0x533010['prototype'],'reflectionFresnelParameters',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['h'])('refractionFresnelParameters')],_0x533010['prototype'],'_refractionFresnelParameters',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsFresnelDirty')],_0x533010['prototype'],'refractionFresnelParameters',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['h'])('emissiveFresnelParameters')],_0x533010['prototype'],'_emissiveFresnelParameters',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsFresnelDirty')],_0x533010['prototype'],'emissiveFresnelParameters',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])('useReflectionFresnelFromSpecular')],_0x533010['prototype'],'_useReflectionFresnelFromSpecular',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsFresnelDirty')],_0x533010['prototype'],'useReflectionFresnelFromSpecular',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])('useGlossinessFromSpecularMapAlpha')],_0x533010['prototype'],'_useGlossinessFromSpecularMapAlpha',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesDirty')],_0x533010['prototype'],'useGlossinessFromSpecularMapAlpha',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])('maxSimultaneousLights')],_0x533010['prototype'],'_maxSimultaneousLights',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsLightsDirty')],_0x533010['prototype'],'maxSimultaneousLights',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])('invertNormalMapX')],_0x533010['prototype'],'_invertNormalMapX',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesDirty')],_0x533010['prototype'],'invertNormalMapX',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])('invertNormalMapY')],_0x533010['prototype'],'_invertNormalMapY',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesDirty')],_0x533010['prototype'],'invertNormalMapY',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])('twoSidedLighting')],_0x533010['prototype'],'_twoSidedLighting',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['b'])('_markAllSubMeshesAsTexturesDirty')],_0x533010['prototype'],'twoSidedLighting',void 0x0),Object(_0x29185a['c'])([Object(_0xc48114['c'])()],_0x533010['prototype'],'useLogarithmicDepth',null),_0x533010;}(_0x12e42d['a']);_0x24022c['a']['RegisteredTypes']['BABYLON.StandardMaterial']=_0x129746,_0x479f57['a']['DefaultMaterialFactory']=function(_0x100bf3){return new _0x129746('default\x20material',_0x100bf3);};},function(_0x159f97,_0x12d9ce,_0x44b9b7){'use strict';_0x44b9b7['d'](_0x12d9ce,'a',function(){return _0x41ac3c;});var _0x466435=_0x44b9b7(0x1),_0x121778=_0x44b9b7(0xc),_0x48c622=_0x44b9b7(0x6),_0x61fa0a=_0x44b9b7(0x0),_0x35e36e=_0x44b9b7(0xd),_0x5de82f=_0x44b9b7(0x4),_0xcff5cc=_0x44b9b7(0x10),_0x13bd42=_0x44b9b7(0x2e),_0x5724b0=_0x44b9b7(0x36),_0x56811a=_0x44b9b7(0x2b),_0x419e0a=_0x44b9b7(0x2),_0x4d423c=_0x44b9b7(0x93),_0x11193c=_0x44b9b7(0x15),_0x4116c6=_0x44b9b7(0x65),_0x1518a3=_0x44b9b7(0x9),_0x29212b=_0x44b9b7(0x1c),_0x3465d2=_0x44b9b7(0x17),_0x6a263c=_0x44b9b7(0xb),_0x3f49f1=function(){this['facetNb']=0x0,this['partitioningSubdivisions']=0xa,this['partitioningBBoxRatio']=1.01,this['facetDataEnabled']=!0x1,this['facetParameters']={},this['bbSize']=_0x61fa0a['e']['Zero'](),this['subDiv']={'max':0x1,'X':0x1,'Y':0x1,'Z':0x1},this['facetDepthSort']=!0x1,this['facetDepthSortEnabled']=!0x1;},_0x402536=function(){this['_hasVertexAlpha']=!0x1,this['_useVertexColors']=!0x0,this['_numBoneInfluencers']=0x4,this['_applyFog']=!0x0,this['_receiveShadows']=!0x1,this['_facetData']=new _0x3f49f1(),this['_visibility']=0x1,this['_skeleton']=null,this['_layerMask']=0xfffffff,this['_computeBonesUsingShaders']=!0x0,this['_isActive']=!0x1,this['_onlyForInstances']=!0x1,this['_isActiveIntermediate']=!0x1,this['_onlyForInstancesIntermediate']=!0x1,this['_actAsRegularMesh']=!0x1,this['_currentLOD']=null,this['_currentLODIsUpToDate']=!0x1;},_0x41ac3c=function(_0x203b91){function _0x5db440(_0xb2df1,_0x37dd45){void 0x0===_0x37dd45&&(_0x37dd45=null);var _0x4f1dfa=_0x203b91['call'](this,_0xb2df1,_0x37dd45,!0x1)||this;return _0x4f1dfa['_internalAbstractMeshDataInfo']=new _0x402536(),_0x4f1dfa['cullingStrategy']=_0x5db440['CULLINGSTRATEGY_BOUNDINGSPHERE_ONLY'],_0x4f1dfa['onCollideObservable']=new _0x48c622['c'](),_0x4f1dfa['onCollisionPositionChangeObservable']=new _0x48c622['c'](),_0x4f1dfa['onMaterialChangedObservable']=new _0x48c622['c'](),_0x4f1dfa['definedFacingForward']=!0x0,_0x4f1dfa['_occlusionQuery']=null,_0x4f1dfa['_renderingGroup']=null,_0x4f1dfa['alphaIndex']=Number['MAX_VALUE'],_0x4f1dfa['isVisible']=!0x0,_0x4f1dfa['isPickable']=!0x0,_0x4f1dfa['showSubMeshesBoundingBox']=!0x1,_0x4f1dfa['isBlocker']=!0x1,_0x4f1dfa['enablePointerMoveEvents']=!0x1,_0x4f1dfa['_renderingGroupId']=0x0,_0x4f1dfa['_material']=null,_0x4f1dfa['outlineColor']=_0x1518a3['a']['Red'](),_0x4f1dfa['outlineWidth']=0.02,_0x4f1dfa['overlayColor']=_0x1518a3['a']['Red'](),_0x4f1dfa['overlayAlpha']=0.5,_0x4f1dfa['useOctreeForRenderingSelection']=!0x0,_0x4f1dfa['useOctreeForPicking']=!0x0,_0x4f1dfa['useOctreeForCollisions']=!0x0,_0x4f1dfa['alwaysSelectAsActiveMesh']=!0x1,_0x4f1dfa['doNotSyncBoundingInfo']=!0x1,_0x4f1dfa['actionManager']=null,_0x4f1dfa['_meshCollisionData']=new _0x4d423c['a'](),_0x4f1dfa['ellipsoid']=new _0x61fa0a['e'](0.5,0x1,0.5),_0x4f1dfa['ellipsoidOffset']=new _0x61fa0a['e'](0x0,0x0,0x0),_0x4f1dfa['edgesWidth']=0x1,_0x4f1dfa['edgesColor']=new _0x1518a3['b'](0x1,0x0,0x0,0x1),_0x4f1dfa['_edgesRenderer']=null,_0x4f1dfa['_masterMesh']=null,_0x4f1dfa['_boundingInfo']=null,_0x4f1dfa['_renderId']=0x0,_0x4f1dfa['_intersectionsInProgress']=new Array(),_0x4f1dfa['_unIndexed']=!0x1,_0x4f1dfa['_lightSources']=new Array(),_0x4f1dfa['_waitingData']={'lods':null,'actions':null,'freezeWorldMatrix':null},_0x4f1dfa['_bonesTransformMatrices']=null,_0x4f1dfa['_transformMatrixTexture']=null,_0x4f1dfa['onRebuildObservable']=new _0x48c622['c'](),_0x4f1dfa['_onCollisionPositionChange']=function(_0x41fab1,_0x462d0c,_0x40e237){void 0x0===_0x40e237&&(_0x40e237=null),_0x462d0c['subtractToRef'](_0x4f1dfa['_meshCollisionData']['_oldPositionForCollisions'],_0x4f1dfa['_meshCollisionData']['_diffPositionForCollisions']),_0x4f1dfa['_meshCollisionData']['_diffPositionForCollisions']['length']()>_0x35e36e['a']['CollisionsEpsilon']&&_0x4f1dfa['position']['addInPlace'](_0x4f1dfa['_meshCollisionData']['_diffPositionForCollisions']),_0x40e237&&_0x4f1dfa['onCollideObservable']['notifyObservers'](_0x40e237),_0x4f1dfa['onCollisionPositionChangeObservable']['notifyObservers'](_0x4f1dfa['position']);},_0x4f1dfa['getScene']()['addMesh'](_0x4f1dfa),_0x4f1dfa['_resyncLightSources'](),_0x4f1dfa;}return Object(_0x466435['d'])(_0x5db440,_0x203b91),Object['defineProperty'](_0x5db440,'BILLBOARDMODE_NONE',{'get':function(){return _0x13bd42['a']['BILLBOARDMODE_NONE'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440,'BILLBOARDMODE_X',{'get':function(){return _0x13bd42['a']['BILLBOARDMODE_X'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440,'BILLBOARDMODE_Y',{'get':function(){return _0x13bd42['a']['BILLBOARDMODE_Y'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440,'BILLBOARDMODE_Z',{'get':function(){return _0x13bd42['a']['BILLBOARDMODE_Z'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440,'BILLBOARDMODE_ALL',{'get':function(){return _0x13bd42['a']['BILLBOARDMODE_ALL'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440,'BILLBOARDMODE_USE_POSITION',{'get':function(){return _0x13bd42['a']['BILLBOARDMODE_USE_POSITION'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'facetNb',{'get':function(){return this['_internalAbstractMeshDataInfo']['_facetData']['facetNb'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'partitioningSubdivisions',{'get':function(){return this['_internalAbstractMeshDataInfo']['_facetData']['partitioningSubdivisions'];},'set':function(_0x4ce7a1){this['_internalAbstractMeshDataInfo']['_facetData']['partitioningSubdivisions']=_0x4ce7a1;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'partitioningBBoxRatio',{'get':function(){return this['_internalAbstractMeshDataInfo']['_facetData']['partitioningBBoxRatio'];},'set':function(_0xfe8360){this['_internalAbstractMeshDataInfo']['_facetData']['partitioningBBoxRatio']=_0xfe8360;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'mustDepthSortFacets',{'get':function(){return this['_internalAbstractMeshDataInfo']['_facetData']['facetDepthSort'];},'set':function(_0x315638){this['_internalAbstractMeshDataInfo']['_facetData']['facetDepthSort']=_0x315638;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'facetDepthSortFrom',{'get':function(){return this['_internalAbstractMeshDataInfo']['_facetData']['facetDepthSortFrom'];},'set':function(_0x518430){this['_internalAbstractMeshDataInfo']['_facetData']['facetDepthSortFrom']=_0x518430;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'isFacetDataEnabled',{'get':function(){return this['_internalAbstractMeshDataInfo']['_facetData']['facetDataEnabled'];},'enumerable':!0x1,'configurable':!0x0}),_0x5db440['prototype']['_updateNonUniformScalingState']=function(_0x3fedd3){return!!_0x203b91['prototype']['_updateNonUniformScalingState']['call'](this,_0x3fedd3)&&(this['_markSubMeshesAsMiscDirty'](),!0x0);},Object['defineProperty'](_0x5db440['prototype'],'onCollide',{'set':function(_0x4fc0b5){this['_meshCollisionData']['_onCollideObserver']&&this['onCollideObservable']['remove'](this['_meshCollisionData']['_onCollideObserver']),this['_meshCollisionData']['_onCollideObserver']=this['onCollideObservable']['add'](_0x4fc0b5);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'onCollisionPositionChange',{'set':function(_0x34f32a){this['_meshCollisionData']['_onCollisionPositionChangeObserver']&&this['onCollisionPositionChangeObservable']['remove'](this['_meshCollisionData']['_onCollisionPositionChangeObserver']),this['_meshCollisionData']['_onCollisionPositionChangeObserver']=this['onCollisionPositionChangeObservable']['add'](_0x34f32a);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'visibility',{'get':function(){return this['_internalAbstractMeshDataInfo']['_visibility'];},'set':function(_0x16b6c6){this['_internalAbstractMeshDataInfo']['_visibility']!==_0x16b6c6&&(this['_internalAbstractMeshDataInfo']['_visibility']=_0x16b6c6,this['_markSubMeshesAsMiscDirty']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'renderingGroupId',{'get':function(){return this['_renderingGroupId'];},'set':function(_0x29fa77){this['_renderingGroupId']=_0x29fa77;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'material',{'get':function(){return this['_material'];},'set':function(_0x9c385f){this['_material']!==_0x9c385f&&(this['_material']&&this['_material']['meshMap']&&(this['_material']['meshMap'][this['uniqueId']]=void 0x0),this['_material']=_0x9c385f,_0x9c385f&&_0x9c385f['meshMap']&&(_0x9c385f['meshMap'][this['uniqueId']]=this),this['onMaterialChangedObservable']['hasObservers']()&&this['onMaterialChangedObservable']['notifyObservers'](this),this['subMeshes']&&this['_unBindEffect']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'receiveShadows',{'get':function(){return this['_internalAbstractMeshDataInfo']['_receiveShadows'];},'set':function(_0x2cfa31){this['_internalAbstractMeshDataInfo']['_receiveShadows']!==_0x2cfa31&&(this['_internalAbstractMeshDataInfo']['_receiveShadows']=_0x2cfa31,this['_markSubMeshesAsLightDirty']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'hasVertexAlpha',{'get':function(){return this['_internalAbstractMeshDataInfo']['_hasVertexAlpha'];},'set':function(_0x1e8aa3){this['_internalAbstractMeshDataInfo']['_hasVertexAlpha']!==_0x1e8aa3&&(this['_internalAbstractMeshDataInfo']['_hasVertexAlpha']=_0x1e8aa3,this['_markSubMeshesAsAttributesDirty'](),this['_markSubMeshesAsMiscDirty']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'useVertexColors',{'get':function(){return this['_internalAbstractMeshDataInfo']['_useVertexColors'];},'set':function(_0x4747e3){this['_internalAbstractMeshDataInfo']['_useVertexColors']!==_0x4747e3&&(this['_internalAbstractMeshDataInfo']['_useVertexColors']=_0x4747e3,this['_markSubMeshesAsAttributesDirty']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'computeBonesUsingShaders',{'get':function(){return this['_internalAbstractMeshDataInfo']['_computeBonesUsingShaders'];},'set':function(_0x5ebcfa){this['_internalAbstractMeshDataInfo']['_computeBonesUsingShaders']!==_0x5ebcfa&&(this['_internalAbstractMeshDataInfo']['_computeBonesUsingShaders']=_0x5ebcfa,this['_markSubMeshesAsAttributesDirty']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'numBoneInfluencers',{'get':function(){return this['_internalAbstractMeshDataInfo']['_numBoneInfluencers'];},'set':function(_0x1178f5){this['_internalAbstractMeshDataInfo']['_numBoneInfluencers']!==_0x1178f5&&(this['_internalAbstractMeshDataInfo']['_numBoneInfluencers']=_0x1178f5,this['_markSubMeshesAsAttributesDirty']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'applyFog',{'get':function(){return this['_internalAbstractMeshDataInfo']['_applyFog'];},'set':function(_0x2cb90f){this['_internalAbstractMeshDataInfo']['_applyFog']!==_0x2cb90f&&(this['_internalAbstractMeshDataInfo']['_applyFog']=_0x2cb90f,this['_markSubMeshesAsMiscDirty']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'layerMask',{'get':function(){return this['_internalAbstractMeshDataInfo']['_layerMask'];},'set':function(_0x23052d){_0x23052d!==this['_internalAbstractMeshDataInfo']['_layerMask']&&(this['_internalAbstractMeshDataInfo']['_layerMask']=_0x23052d,this['_resyncLightSources']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'collisionMask',{'get':function(){return this['_meshCollisionData']['_collisionMask'];},'set':function(_0x368715){this['_meshCollisionData']['_collisionMask']=isNaN(_0x368715)?-0x1:_0x368715;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'collisionResponse',{'get':function(){return this['_meshCollisionData']['_collisionResponse'];},'set':function(_0x2cb8c4){this['_meshCollisionData']['_collisionResponse']=_0x2cb8c4;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'collisionGroup',{'get':function(){return this['_meshCollisionData']['_collisionGroup'];},'set':function(_0x55dcfe){this['_meshCollisionData']['_collisionGroup']=isNaN(_0x55dcfe)?-0x1:_0x55dcfe;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'surroundingMeshes',{'get':function(){return this['_meshCollisionData']['_surroundingMeshes'];},'set':function(_0x5856cc){this['_meshCollisionData']['_surroundingMeshes']=_0x5856cc;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'lightSources',{'get':function(){return this['_lightSources'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'_positions',{'get':function(){return null;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'skeleton',{'get':function(){return this['_internalAbstractMeshDataInfo']['_skeleton'];},'set':function(_0x13a7f7){var _0x278a84=this['_internalAbstractMeshDataInfo']['_skeleton'];_0x278a84&&_0x278a84['needInitialSkinMatrix']&&_0x278a84['_unregisterMeshWithPoseMatrix'](this),_0x13a7f7&&_0x13a7f7['needInitialSkinMatrix']&&_0x13a7f7['_registerMeshWithPoseMatrix'](this),this['_internalAbstractMeshDataInfo']['_skeleton']=_0x13a7f7,this['_internalAbstractMeshDataInfo']['_skeleton']||(this['_bonesTransformMatrices']=null),this['_markSubMeshesAsAttributesDirty']();},'enumerable':!0x1,'configurable':!0x0}),_0x5db440['prototype']['getClassName']=function(){return'AbstractMesh';},_0x5db440['prototype']['toString']=function(_0xa24079){var _0x510bf3='Name:\x20'+this['name']+',\x20isInstance:\x20'+('InstancedMesh'!==this['getClassName']()?'YES':'NO');_0x510bf3+=',\x20#\x20of\x20submeshes:\x20'+(this['subMeshes']?this['subMeshes']['length']:0x0);var _0xfce83c=this['_internalAbstractMeshDataInfo']['_skeleton'];return _0xfce83c&&(_0x510bf3+=',\x20skeleton:\x20'+_0xfce83c['name']),_0xa24079&&(_0x510bf3+=',\x20billboard\x20mode:\x20'+['NONE','X','Y',null,'Z',null,null,'ALL'][this['billboardMode']],_0x510bf3+=',\x20freeze\x20wrld\x20mat:\x20'+(this['_isWorldMatrixFrozen']||this['_waitingData']['freezeWorldMatrix']?'YES':'NO')),_0x510bf3;},_0x5db440['prototype']['_getEffectiveParent']=function(){return this['_masterMesh']&&this['billboardMode']!==_0x13bd42['a']['BILLBOARDMODE_NONE']?this['_masterMesh']:_0x203b91['prototype']['_getEffectiveParent']['call'](this);},_0x5db440['prototype']['_getActionManagerForTrigger']=function(_0x23fa6e,_0x37ce55){if(void 0x0===_0x37ce55&&(_0x37ce55=!0x0),this['actionManager']&&(_0x37ce55||this['actionManager']['isRecursive'])){if(!_0x23fa6e)return this['actionManager'];if(this['actionManager']['hasSpecificTrigger'](_0x23fa6e))return this['actionManager'];}return this['parent']?this['parent']['_getActionManagerForTrigger'](_0x23fa6e,!0x1):null;},_0x5db440['prototype']['_rebuild']=function(){if(this['onRebuildObservable']['notifyObservers'](this),this['_occlusionQuery']&&(this['_occlusionQuery']=null),this['subMeshes'])for(var _0x291436=0x0,_0x57c074=this['subMeshes'];_0x291436<_0x57c074['length'];_0x291436++){_0x57c074[_0x291436]['_rebuild']();}},_0x5db440['prototype']['_resyncLightSources']=function(){this['_lightSources']['length']=0x0;for(var _0x282142=0x0,_0xa0f5c5=this['getScene']()['lights'];_0x282142<_0xa0f5c5['length'];_0x282142++){var _0x20c726=_0xa0f5c5[_0x282142];_0x20c726['isEnabled']()&&(_0x20c726['canAffectMesh'](this)&&this['_lightSources']['push'](_0x20c726));}this['_markSubMeshesAsLightDirty']();},_0x5db440['prototype']['_resyncLightSource']=function(_0x55d44c){var _0x270663=_0x55d44c['isEnabled']()&&_0x55d44c['canAffectMesh'](this),_0x5360ab=this['_lightSources']['indexOf'](_0x55d44c),_0x594360=!0x1;if(-0x1===_0x5360ab){if(!_0x270663)return;this['_lightSources']['push'](_0x55d44c);}else{if(_0x270663)return;_0x594360=!0x0,this['_lightSources']['splice'](_0x5360ab,0x1);}this['_markSubMeshesAsLightDirty'](_0x594360);},_0x5db440['prototype']['_unBindEffect']=function(){for(var _0x547755=0x0,_0x3d7510=this['subMeshes'];_0x547755<_0x3d7510['length'];_0x547755++){_0x3d7510[_0x547755]['setEffect'](null);}},_0x5db440['prototype']['_removeLightSource']=function(_0x382f31,_0x3dc0a2){var _0x1f3767=this['_lightSources']['indexOf'](_0x382f31);-0x1!==_0x1f3767&&(this['_lightSources']['splice'](_0x1f3767,0x1),this['_markSubMeshesAsLightDirty'](_0x3dc0a2));},_0x5db440['prototype']['_markSubMeshesAsDirty']=function(_0x22c72c){if(this['subMeshes'])for(var _0xd7b3e=0x0,_0x235d89=this['subMeshes'];_0xd7b3e<_0x235d89['length'];_0xd7b3e++){var _0x5c75d7=_0x235d89[_0xd7b3e];_0x5c75d7['_materialDefines']&&_0x22c72c(_0x5c75d7['_materialDefines']);}},_0x5db440['prototype']['_markSubMeshesAsLightDirty']=function(_0x417a05){void 0x0===_0x417a05&&(_0x417a05=!0x1),this['_markSubMeshesAsDirty'](function(_0x2a1b04){return _0x2a1b04['markAsLightDirty'](_0x417a05);});},_0x5db440['prototype']['_markSubMeshesAsAttributesDirty']=function(){this['_markSubMeshesAsDirty'](function(_0x1aa745){return _0x1aa745['markAsAttributesDirty']();});},_0x5db440['prototype']['_markSubMeshesAsMiscDirty']=function(){this['_markSubMeshesAsDirty'](function(_0x1e0f48){return _0x1e0f48['markAsMiscDirty']();});},Object['defineProperty'](_0x5db440['prototype'],'scaling',{'get':function(){return this['_scaling'];},'set':function(_0xe65e8d){this['_scaling']=_0xe65e8d;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'isBlocked',{'get':function(){return!0x1;},'enumerable':!0x1,'configurable':!0x0}),_0x5db440['prototype']['getLOD']=function(_0x414e19){return this;},_0x5db440['prototype']['getTotalVertices']=function(){return 0x0;},_0x5db440['prototype']['getTotalIndices']=function(){return 0x0;},_0x5db440['prototype']['getIndices']=function(){return null;},_0x5db440['prototype']['getVerticesData']=function(_0x33ded1){return null;},_0x5db440['prototype']['setVerticesData']=function(_0x570b2b,_0x20f830,_0x1e6afd,_0x10b6b1){return this;},_0x5db440['prototype']['updateVerticesData']=function(_0xbd0fb0,_0x3fd234,_0x5bd635,_0x3d8bb1){return this;},_0x5db440['prototype']['setIndices']=function(_0x19b3f7,_0x32a0aa){return this;},_0x5db440['prototype']['isVerticesDataPresent']=function(_0x323e8c){return!0x1;},_0x5db440['prototype']['getBoundingInfo']=function(){return this['_masterMesh']?this['_masterMesh']['getBoundingInfo']():(this['_boundingInfo']||this['_updateBoundingInfo'](),this['_boundingInfo']);},_0x5db440['prototype']['normalizeToUnitCube']=function(_0x113b1f,_0x4bb670,_0x5ddc4a){return void 0x0===_0x113b1f&&(_0x113b1f=!0x0),void 0x0===_0x4bb670&&(_0x4bb670=!0x1),_0x203b91['prototype']['normalizeToUnitCube']['call'](this,_0x113b1f,_0x4bb670,_0x5ddc4a);},_0x5db440['prototype']['setBoundingInfo']=function(_0x5a1869){return this['_boundingInfo']=_0x5a1869,this;},Object['defineProperty'](_0x5db440['prototype'],'useBones',{'get':function(){return this['skeleton']&&this['getScene']()['skeletonsEnabled']&&this['isVerticesDataPresent'](_0x5de82f['b']['MatricesIndicesKind'])&&this['isVerticesDataPresent'](_0x5de82f['b']['MatricesWeightsKind']);},'enumerable':!0x1,'configurable':!0x0}),_0x5db440['prototype']['_preActivate']=function(){},_0x5db440['prototype']['_preActivateForIntermediateRendering']=function(_0x2d1f81){},_0x5db440['prototype']['_activate']=function(_0x3ab99a,_0x51e284){return this['_renderId']=_0x3ab99a,!0x0;},_0x5db440['prototype']['_postActivate']=function(){},_0x5db440['prototype']['_freeze']=function(){},_0x5db440['prototype']['_unFreeze']=function(){},_0x5db440['prototype']['getWorldMatrix']=function(){return this['_masterMesh']&&this['billboardMode']===_0x13bd42['a']['BILLBOARDMODE_NONE']?this['_masterMesh']['getWorldMatrix']():_0x203b91['prototype']['getWorldMatrix']['call'](this);},_0x5db440['prototype']['_getWorldMatrixDeterminant']=function(){return this['_masterMesh']?this['_masterMesh']['_getWorldMatrixDeterminant']():_0x203b91['prototype']['_getWorldMatrixDeterminant']['call'](this);},Object['defineProperty'](_0x5db440['prototype'],'isAnInstance',{'get':function(){return!0x1;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'hasInstances',{'get':function(){return!0x1;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'hasThinInstances',{'get':function(){return!0x1;},'enumerable':!0x1,'configurable':!0x0}),_0x5db440['prototype']['movePOV']=function(_0x14f5fc,_0x84f717,_0x4c24a5){return this['position']['addInPlace'](this['calcMovePOV'](_0x14f5fc,_0x84f717,_0x4c24a5)),this;},_0x5db440['prototype']['calcMovePOV']=function(_0x249d00,_0x9836c2,_0x2b6bf1){var _0x394e49=new _0x61fa0a['a']();(this['rotationQuaternion']?this['rotationQuaternion']:_0x61fa0a['b']['RotationYawPitchRoll'](this['rotation']['y'],this['rotation']['x'],this['rotation']['z']))['toRotationMatrix'](_0x394e49);var _0x30bb2b=_0x61fa0a['e']['Zero'](),_0x30f5d7=this['definedFacingForward']?-0x1:0x1;return _0x61fa0a['e']['TransformCoordinatesFromFloatsToRef'](_0x249d00*_0x30f5d7,_0x9836c2,_0x2b6bf1*_0x30f5d7,_0x394e49,_0x30bb2b),_0x30bb2b;},_0x5db440['prototype']['rotatePOV']=function(_0xa9fb78,_0x3b39de,_0x1e6154){return this['rotation']['addInPlace'](this['calcRotatePOV'](_0xa9fb78,_0x3b39de,_0x1e6154)),this;},_0x5db440['prototype']['calcRotatePOV']=function(_0x426fdb,_0x2c8d37,_0x58ec81){var _0x5a421d=this['definedFacingForward']?0x1:-0x1;return new _0x61fa0a['e'](_0x426fdb*_0x5a421d,_0x2c8d37,_0x58ec81*_0x5a421d);},_0x5db440['prototype']['refreshBoundingInfo']=function(_0x14bd3e){return void 0x0===_0x14bd3e&&(_0x14bd3e=!0x1),this['_boundingInfo']&&this['_boundingInfo']['isLocked']||this['_refreshBoundingInfo'](this['_getPositionData'](_0x14bd3e),null),this;},_0x5db440['prototype']['_refreshBoundingInfo']=function(_0x3779b4,_0x455426){if(_0x3779b4){var _0x90cdd=Object(_0x4116c6['a'])(_0x3779b4,0x0,this['getTotalVertices'](),_0x455426);this['_boundingInfo']?this['_boundingInfo']['reConstruct'](_0x90cdd['minimum'],_0x90cdd['maximum']):this['_boundingInfo']=new _0x56811a['a'](_0x90cdd['minimum'],_0x90cdd['maximum']);}if(this['subMeshes']){for(var _0x5a11a9=0x0;_0x5a11a90x4,_0x1deb54=_0x395bbf?this['getVerticesData'](_0x5de82f['b']['MatricesIndicesExtraKind']):null,_0x1471d8=_0x395bbf?this['getVerticesData'](_0x5de82f['b']['MatricesWeightsExtraKind']):null;this['skeleton']['prepare']();for(var _0x35b431=this['skeleton']['getTransformMatrices'](this),_0x498942=_0x61fa0a['c']['Vector3'][0x0],_0x1e4cc6=_0x61fa0a['c']['Matrix'][0x0],_0x147e6f=_0x61fa0a['c']['Matrix'][0x1],_0x285e13=0x0,_0x2c332a=0x0;_0x2c332a<_0x3255fe['length'];_0x2c332a+=0x3,_0x285e13+=0x4){var _0x3baad8,_0x95ec8;for(_0x1e4cc6['reset'](),_0x3baad8=0x0;_0x3baad8<0x4;_0x3baad8++)(_0x95ec8=_0x240e45[_0x285e13+_0x3baad8])>0x0&&(_0x61fa0a['a']['FromFloat32ArrayToRefScaled'](_0x35b431,Math['floor'](0x10*_0x318c65[_0x285e13+_0x3baad8]),_0x95ec8,_0x147e6f),_0x1e4cc6['addToSelf'](_0x147e6f));if(_0x395bbf){for(_0x3baad8=0x0;_0x3baad8<0x4;_0x3baad8++)(_0x95ec8=_0x1471d8[_0x285e13+_0x3baad8])>0x0&&(_0x61fa0a['a']['FromFloat32ArrayToRefScaled'](_0x35b431,Math['floor'](0x10*_0x1deb54[_0x285e13+_0x3baad8]),_0x95ec8,_0x147e6f),_0x1e4cc6['addToSelf'](_0x147e6f));}_0x61fa0a['e']['TransformCoordinatesFromFloatsToRef'](_0x3255fe[_0x2c332a],_0x3255fe[_0x2c332a+0x1],_0x3255fe[_0x2c332a+0x2],_0x1e4cc6,_0x498942),_0x498942['toArray'](_0x3255fe,_0x2c332a),this['_positions']&&this['_positions'][_0x2c332a/0x3]['copyFrom'](_0x498942);}}}return _0x3255fe;},_0x5db440['prototype']['_updateBoundingInfo']=function(){var _0x2dd8f9=this['_effectiveMesh'];return this['_boundingInfo']?this['_boundingInfo']['update'](_0x2dd8f9['worldMatrixFromCache']):this['_boundingInfo']=new _0x56811a['a'](this['absolutePosition'],this['absolutePosition'],_0x2dd8f9['worldMatrixFromCache']),this['_updateSubMeshesBoundingInfo'](_0x2dd8f9['worldMatrixFromCache']),this;},_0x5db440['prototype']['_updateSubMeshesBoundingInfo']=function(_0x16743e){if(!this['subMeshes'])return this;for(var _0x1d867c=this['subMeshes']['length'],_0x2ea0f9=0x0;_0x2ea0f9<_0x1d867c;_0x2ea0f9++){var _0x2c98aa=this['subMeshes'][_0x2ea0f9];(_0x1d867c>0x1||!_0x2c98aa['IsGlobal'])&&_0x2c98aa['updateBoundingInfo'](_0x16743e);}return this;},_0x5db440['prototype']['_afterComputeWorldMatrix']=function(){this['doNotSyncBoundingInfo']||this['_updateBoundingInfo']();},Object['defineProperty'](_0x5db440['prototype'],'_effectiveMesh',{'get':function(){return this['skeleton']&&this['skeleton']['overrideMesh']||this;},'enumerable':!0x1,'configurable':!0x0}),_0x5db440['prototype']['isInFrustum']=function(_0x439a4c){return null!==this['_boundingInfo']&&this['_boundingInfo']['isInFrustum'](_0x439a4c,this['cullingStrategy']);},_0x5db440['prototype']['isCompletelyInFrustum']=function(_0x1a369d){return null!==this['_boundingInfo']&&this['_boundingInfo']['isCompletelyInFrustum'](_0x1a369d);},_0x5db440['prototype']['intersectsMesh']=function(_0x1061c6,_0x5e5128,_0x16f5a2){if(void 0x0===_0x5e5128&&(_0x5e5128=!0x1),!this['_boundingInfo']||!_0x1061c6['_boundingInfo'])return!0x1;if(this['_boundingInfo']['intersects'](_0x1061c6['_boundingInfo'],_0x5e5128))return!0x0;if(_0x16f5a2)for(var _0x491846=0x0,_0x9b5ea5=this['getChildMeshes']();_0x491846<_0x9b5ea5['length'];_0x491846++){if(_0x9b5ea5[_0x491846]['intersectsMesh'](_0x1061c6,_0x5e5128,!0x0))return!0x0;}return!0x1;},_0x5db440['prototype']['intersectsPoint']=function(_0x38bd6e){return!!this['_boundingInfo']&&this['_boundingInfo']['intersectsPoint'](_0x38bd6e);},Object['defineProperty'](_0x5db440['prototype'],'checkCollisions',{'get':function(){return this['_meshCollisionData']['_checkCollisions'];},'set':function(_0x12ca5e){this['_meshCollisionData']['_checkCollisions']=_0x12ca5e;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5db440['prototype'],'collider',{'get':function(){return this['_meshCollisionData']['_collider'];},'enumerable':!0x1,'configurable':!0x0}),_0x5db440['prototype']['moveWithCollisions']=function(_0x5b8901){this['getAbsolutePosition']()['addToRef'](this['ellipsoidOffset'],this['_meshCollisionData']['_oldPositionForCollisions']);var _0x58ac46=this['getScene']()['collisionCoordinator'];return this['_meshCollisionData']['_collider']||(this['_meshCollisionData']['_collider']=_0x58ac46['createCollider']()),this['_meshCollisionData']['_collider']['_radius']=this['ellipsoid'],_0x58ac46['getNewPosition'](this['_meshCollisionData']['_oldPositionForCollisions'],_0x5b8901,this['_meshCollisionData']['_collider'],0x3,this,this['_onCollisionPositionChange'],this['uniqueId']),this;},_0x5db440['prototype']['_collideForSubMesh']=function(_0x25c209,_0xf00103,_0x37d3cc){if(this['_generatePointsArray'](),!this['_positions'])return this;if(!_0x25c209['_lastColliderWorldVertices']||!_0x25c209['_lastColliderTransformMatrix']['equals'](_0xf00103)){_0x25c209['_lastColliderTransformMatrix']=_0xf00103['clone'](),_0x25c209['_lastColliderWorldVertices']=[],_0x25c209['_trianglePlanes']=[];for(var _0x56966a=_0x25c209['verticesStart'],_0x353ffe=_0x25c209['verticesStart']+_0x25c209['verticesCount'],_0x245214=_0x56966a;_0x245214<_0x353ffe;_0x245214++)_0x25c209['_lastColliderWorldVertices']['push'](_0x61fa0a['e']['TransformCoordinates'](this['_positions'][_0x245214],_0xf00103));}return _0x37d3cc['_collide'](_0x25c209['_trianglePlanes'],_0x25c209['_lastColliderWorldVertices'],this['getIndices'](),_0x25c209['indexStart'],_0x25c209['indexStart']+_0x25c209['indexCount'],_0x25c209['verticesStart'],!!_0x25c209['getMaterial'](),this),this;},_0x5db440['prototype']['_processCollisionsForSubMeshes']=function(_0x5736d5,_0x5d1553){for(var _0x168541=this['_scene']['getCollidingSubMeshCandidates'](this,_0x5736d5),_0x3cd4e8=_0x168541['length'],_0x18db8f=0x0;_0x18db8f<_0x3cd4e8;_0x18db8f++){var _0x1b4e4a=_0x168541['data'][_0x18db8f];_0x3cd4e8>0x1&&!_0x1b4e4a['_checkCollision'](_0x5736d5)||this['_collideForSubMesh'](_0x1b4e4a,_0x5d1553,_0x5736d5);}return this;},_0x5db440['prototype']['_checkCollision']=function(_0x4e4386){if(!this['_boundingInfo']||!this['_boundingInfo']['_checkCollision'](_0x4e4386))return this;var _0x3b9321=_0x61fa0a['c']['Matrix'][0x0],_0x3eb4dc=_0x61fa0a['c']['Matrix'][0x1];return _0x61fa0a['a']['ScalingToRef'](0x1/_0x4e4386['_radius']['x'],0x1/_0x4e4386['_radius']['y'],0x1/_0x4e4386['_radius']['z'],_0x3b9321),this['worldMatrixFromCache']['multiplyToRef'](_0x3b9321,_0x3eb4dc),this['_processCollisionsForSubMeshes'](_0x4e4386,_0x3eb4dc),this;},_0x5db440['prototype']['_generatePointsArray']=function(){return!0x1;},_0x5db440['prototype']['intersects']=function(_0x3ad76b,_0x514626,_0x24e174,_0x5285ce,_0x19c949,_0x5d94f3){var _0x347d28;void 0x0===_0x5285ce&&(_0x5285ce=!0x1),void 0x0===_0x5d94f3&&(_0x5d94f3=!0x1);var _0x23e610=new _0x5724b0['a'](),_0xfadd44='InstancedLinesMesh'===this['getClassName']()||'LinesMesh'===this['getClassName']()?this['intersectionThreshold']:0x0,_0x130844=this['_boundingInfo'];if(!this['subMeshes']||!_0x130844)return _0x23e610;if(!(_0x5d94f3||_0x3ad76b['intersectsSphere'](_0x130844['boundingSphere'],_0xfadd44)&&_0x3ad76b['intersectsBox'](_0x130844['boundingBox'],_0xfadd44)))return _0x23e610;if(_0x5285ce)return _0x23e610['hit']=!_0x5d94f3,_0x23e610['pickedMesh']=_0x5d94f3?null:this,_0x23e610['distance']=_0x5d94f3?0x0:_0x61fa0a['e']['Distance'](_0x3ad76b['origin'],_0x130844['boundingSphere']['center']),_0x23e610['subMeshId']=0x0,_0x23e610;if(!this['_generatePointsArray']())return _0x23e610;for(var _0x32e2a8=null,_0x5becdd=this['_scene']['getIntersectingSubMeshCandidates'](this,_0x3ad76b),_0x1a9915=_0x5becdd['length'],_0x3447cb=!0x1,_0x3db88b=0x0;_0x3db88b<_0x1a9915;_0x3db88b++){var _0x6bf727=(_0x2a8023=_0x5becdd['data'][_0x3db88b])['getMaterial']();if(_0x6bf727&&((null===(_0x347d28=this['getIndices']())||void 0x0===_0x347d28?void 0x0:_0x347d28['length'])&&(_0x6bf727['fillMode']==_0x419e0a['a']['MATERIAL_TriangleStripDrawMode']||_0x6bf727['fillMode']==_0x419e0a['a']['MATERIAL_TriangleFillMode']||_0x6bf727['fillMode']==_0x419e0a['a']['MATERIAL_WireFrameFillMode']||_0x6bf727['fillMode']==_0x419e0a['a']['MATERIAL_PointFillMode']))){_0x3447cb=!0x0;break;}}if(!_0x3447cb)return _0x23e610['hit']=!0x0,_0x23e610['pickedMesh']=this,_0x23e610['distance']=_0x61fa0a['e']['Distance'](_0x3ad76b['origin'],_0x130844['boundingSphere']['center']),_0x23e610['subMeshId']=-0x1,_0x23e610;for(_0x3db88b=0x0;_0x3db88b<_0x1a9915;_0x3db88b++){var _0x2a8023=_0x5becdd['data'][_0x3db88b];if(!(_0x1a9915>0x1)||_0x2a8023['canIntersects'](_0x3ad76b)){var _0x16a290=_0x2a8023['intersects'](_0x3ad76b,this['_positions'],this['getIndices'](),_0x514626,_0x24e174);if(_0x16a290&&(_0x514626||!_0x32e2a8||_0x16a290['distance']<_0x32e2a8['distance'])&&((_0x32e2a8=_0x16a290)['subMeshId']=_0x3db88b,_0x514626))break;}}if(_0x32e2a8){var _0x12926e=null!=_0x19c949?_0x19c949:this['skeleton']&&this['skeleton']['overrideMesh']?this['skeleton']['overrideMesh']['getWorldMatrix']():this['getWorldMatrix'](),_0x514c69=_0x61fa0a['c']['Vector3'][0x0],_0x4fb0ad=_0x61fa0a['c']['Vector3'][0x1];_0x61fa0a['e']['TransformCoordinatesToRef'](_0x3ad76b['origin'],_0x12926e,_0x514c69),_0x3ad76b['direction']['scaleToRef'](_0x32e2a8['distance'],_0x4fb0ad);var _0x5d8b50=_0x61fa0a['e']['TransformNormal'](_0x4fb0ad,_0x12926e)['addInPlace'](_0x514c69);return _0x23e610['hit']=!0x0,_0x23e610['distance']=_0x61fa0a['e']['Distance'](_0x514c69,_0x5d8b50),_0x23e610['pickedPoint']=_0x5d8b50,_0x23e610['pickedMesh']=this,_0x23e610['bu']=_0x32e2a8['bu']||0x0,_0x23e610['bv']=_0x32e2a8['bv']||0x0,_0x23e610['subMeshFaceId']=_0x32e2a8['faceId'],_0x23e610['faceId']=_0x32e2a8['faceId']+_0x5becdd['data'][_0x32e2a8['subMeshId']]['indexStart']/(-0x1!==this['getClassName']()['indexOf']('LinesMesh')?0x2:0x3),_0x23e610['subMeshId']=_0x32e2a8['subMeshId'],_0x23e610;}return _0x23e610;},_0x5db440['prototype']['clone']=function(_0x42a1a9,_0x4acb7c,_0x14d0f8){return null;},_0x5db440['prototype']['releaseSubMeshes']=function(){if(this['subMeshes']){for(;this['subMeshes']['length'];)this['subMeshes'][0x0]['dispose']();}else this['subMeshes']=new Array();return this;},_0x5db440['prototype']['dispose']=function(_0xb3331e,_0x5546f2){var _0x530eef,_0x5edd89=this;for(void 0x0===_0x5546f2&&(_0x5546f2=!0x1),this['_scene']['useMaterialMeshMap']&&this['_material']&&this['_material']['meshMap']&&(this['_material']['meshMap'][this['uniqueId']]=void 0x0),this['getScene']()['freeActiveMeshes'](),this['getScene']()['freeRenderingGroups'](),void 0x0!==this['actionManager']&&null!==this['actionManager']&&(this['actionManager']['dispose'](),this['actionManager']=null),this['_internalAbstractMeshDataInfo']['_skeleton']=null,this['_transformMatrixTexture']&&(this['_transformMatrixTexture']['dispose'](),this['_transformMatrixTexture']=null),_0x530eef=0x0;_0x530eef0xffff){_0x59451d=!0x0;break;}_0x3956e4['depthSortedIndices']=_0x59451d?new Uint32Array(_0x3c3c3d):new Uint16Array(_0x3c3c3d);}}if(_0x3956e4['facetDepthSortFunction']=function(_0x41de55,_0x25f238){return _0x25f238['sqDistance']-_0x41de55['sqDistance'];},!_0x3956e4['facetDepthSortFrom']){var _0x21fa47=this['getScene']()['activeCamera'];_0x3956e4['facetDepthSortFrom']=_0x21fa47?_0x21fa47['position']:_0x61fa0a['e']['Zero']();}_0x3956e4['depthSortedFacets']=[];for(var _0x146518=0x0;_0x146518<_0x3956e4['facetNb'];_0x146518++){var _0x1610d8={'ind':0x3*_0x146518,'sqDistance':0x0};_0x3956e4['depthSortedFacets']['push'](_0x1610d8);}_0x3956e4['invertedMatrix']=_0x61fa0a['a']['Identity'](),_0x3956e4['facetDepthSortOrigin']=_0x61fa0a['e']['Zero']();}_0x3956e4['bbSize']['x']=_0x9e2f6e['maximum']['x']-_0x9e2f6e['minimum']['x']>_0x29212b['a']?_0x9e2f6e['maximum']['x']-_0x9e2f6e['minimum']['x']:_0x29212b['a'],_0x3956e4['bbSize']['y']=_0x9e2f6e['maximum']['y']-_0x9e2f6e['minimum']['y']>_0x29212b['a']?_0x9e2f6e['maximum']['y']-_0x9e2f6e['minimum']['y']:_0x29212b['a'],_0x3956e4['bbSize']['z']=_0x9e2f6e['maximum']['z']-_0x9e2f6e['minimum']['z']>_0x29212b['a']?_0x9e2f6e['maximum']['z']-_0x9e2f6e['minimum']['z']:_0x29212b['a'];var _0x10791d=_0x3956e4['bbSize']['x']>_0x3956e4['bbSize']['y']?_0x3956e4['bbSize']['x']:_0x3956e4['bbSize']['y'];if(_0x10791d=_0x10791d>_0x3956e4['bbSize']['z']?_0x10791d:_0x3956e4['bbSize']['z'],_0x3956e4['subDiv']['max']=_0x3956e4['partitioningSubdivisions'],_0x3956e4['subDiv']['X']=Math['floor'](_0x3956e4['subDiv']['max']*_0x3956e4['bbSize']['x']/_0x10791d),_0x3956e4['subDiv']['Y']=Math['floor'](_0x3956e4['subDiv']['max']*_0x3956e4['bbSize']['y']/_0x10791d),_0x3956e4['subDiv']['Z']=Math['floor'](_0x3956e4['subDiv']['max']*_0x3956e4['bbSize']['z']/_0x10791d),_0x3956e4['subDiv']['X']=_0x3956e4['subDiv']['X']<0x1?0x1:_0x3956e4['subDiv']['X'],_0x3956e4['subDiv']['Y']=_0x3956e4['subDiv']['Y']<0x1?0x1:_0x3956e4['subDiv']['Y'],_0x3956e4['subDiv']['Z']=_0x3956e4['subDiv']['Z']<0x1?0x1:_0x3956e4['subDiv']['Z'],_0x3956e4['facetParameters']['facetNormals']=this['getFacetLocalNormals'](),_0x3956e4['facetParameters']['facetPositions']=this['getFacetLocalPositions'](),_0x3956e4['facetParameters']['facetPartitioning']=this['getFacetLocalPartitioning'](),_0x3956e4['facetParameters']['bInfo']=_0x9e2f6e,_0x3956e4['facetParameters']['bbSize']=_0x3956e4['bbSize'],_0x3956e4['facetParameters']['subDiv']=_0x3956e4['subDiv'],_0x3956e4['facetParameters']['ratio']=this['partitioningBBoxRatio'],_0x3956e4['facetParameters']['depthSort']=_0x3956e4['facetDepthSort'],_0x3956e4['facetDepthSort']&&_0x3956e4['facetDepthSortEnabled']&&(this['computeWorldMatrix'](!0x0),this['_worldMatrix']['invertToRef'](_0x3956e4['invertedMatrix']),_0x61fa0a['e']['TransformCoordinatesToRef'](_0x3956e4['facetDepthSortFrom'],_0x3956e4['invertedMatrix'],_0x3956e4['facetDepthSortOrigin']),_0x3956e4['facetParameters']['distanceTo']=_0x3956e4['facetDepthSortOrigin']),_0x3956e4['facetParameters']['depthSortedFacets']=_0x3956e4['depthSortedFacets'],_0xcff5cc['a']['ComputeNormals'](_0x2f8a34,_0x3c3c3d,_0x5d1eac,_0x3956e4['facetParameters']),_0x3956e4['facetDepthSort']&&_0x3956e4['facetDepthSortEnabled']){_0x3956e4['depthSortedFacets']['sort'](_0x3956e4['facetDepthSortFunction']);var _0x577883=_0x3956e4['depthSortedIndices']['length']/0x3|0x0;for(_0x146518=0x0;_0x146518<_0x577883;_0x146518++){var _0x50b59f=_0x3956e4['depthSortedFacets'][_0x146518]['ind'];_0x3956e4['depthSortedIndices'][0x3*_0x146518]=_0x3c3c3d[_0x50b59f],_0x3956e4['depthSortedIndices'][0x3*_0x146518+0x1]=_0x3c3c3d[_0x50b59f+0x1],_0x3956e4['depthSortedIndices'][0x3*_0x146518+0x2]=_0x3c3c3d[_0x50b59f+0x2];}this['updateIndices'](_0x3956e4['depthSortedIndices'],void 0x0,!0x0);}return this;},_0x5db440['prototype']['getFacetLocalNormals']=function(){var _0x11ab64=this['_internalAbstractMeshDataInfo']['_facetData'];return _0x11ab64['facetNormals']||this['updateFacetData'](),_0x11ab64['facetNormals'];},_0x5db440['prototype']['getFacetLocalPositions']=function(){var _0x487144=this['_internalAbstractMeshDataInfo']['_facetData'];return _0x487144['facetPositions']||this['updateFacetData'](),_0x487144['facetPositions'];},_0x5db440['prototype']['getFacetLocalPartitioning']=function(){var _0x524043=this['_internalAbstractMeshDataInfo']['_facetData'];return _0x524043['facetPartitioning']||this['updateFacetData'](),_0x524043['facetPartitioning'];},_0x5db440['prototype']['getFacetPosition']=function(_0x272394){var _0x3a6f78=_0x61fa0a['e']['Zero']();return this['getFacetPositionToRef'](_0x272394,_0x3a6f78),_0x3a6f78;},_0x5db440['prototype']['getFacetPositionToRef']=function(_0xc303dd,_0x4be0a6){var _0x20918b=this['getFacetLocalPositions']()[_0xc303dd],_0x28165e=this['getWorldMatrix']();return _0x61fa0a['e']['TransformCoordinatesToRef'](_0x20918b,_0x28165e,_0x4be0a6),this;},_0x5db440['prototype']['getFacetNormal']=function(_0x12d956){var _0x3f1c37=_0x61fa0a['e']['Zero']();return this['getFacetNormalToRef'](_0x12d956,_0x3f1c37),_0x3f1c37;},_0x5db440['prototype']['getFacetNormalToRef']=function(_0x2ac212,_0xd0cce5){var _0x590c89=this['getFacetLocalNormals']()[_0x2ac212];return _0x61fa0a['e']['TransformNormalToRef'](_0x590c89,this['getWorldMatrix'](),_0xd0cce5),this;},_0x5db440['prototype']['getFacetsAtLocalCoordinates']=function(_0x52ba97,_0x2d4b95,_0x2c6882){var _0xd4f8d7=this['getBoundingInfo'](),_0x347232=this['_internalAbstractMeshDataInfo']['_facetData'],_0x13889b=Math['floor']((_0x52ba97-_0xd4f8d7['minimum']['x']*_0x347232['partitioningBBoxRatio'])*_0x347232['subDiv']['X']*_0x347232['partitioningBBoxRatio']/_0x347232['bbSize']['x']),_0x23976d=Math['floor']((_0x2d4b95-_0xd4f8d7['minimum']['y']*_0x347232['partitioningBBoxRatio'])*_0x347232['subDiv']['Y']*_0x347232['partitioningBBoxRatio']/_0x347232['bbSize']['y']),_0xeaf108=Math['floor']((_0x2c6882-_0xd4f8d7['minimum']['z']*_0x347232['partitioningBBoxRatio'])*_0x347232['subDiv']['Z']*_0x347232['partitioningBBoxRatio']/_0x347232['bbSize']['z']);return _0x13889b<0x0||_0x13889b>_0x347232['subDiv']['max']||_0x23976d<0x0||_0x23976d>_0x347232['subDiv']['max']||_0xeaf108<0x0||_0xeaf108>_0x347232['subDiv']['max']?null:_0x347232['facetPartitioning'][_0x13889b+_0x347232['subDiv']['max']*_0x23976d+_0x347232['subDiv']['max']*_0x347232['subDiv']['max']*_0xeaf108];},_0x5db440['prototype']['getClosestFacetAtCoordinates']=function(_0x53faea,_0x4d4391,_0x459c6a,_0x4fd3fe,_0x41e659,_0x235ad4){void 0x0===_0x41e659&&(_0x41e659=!0x1),void 0x0===_0x235ad4&&(_0x235ad4=!0x0);var _0x270a0f=this['getWorldMatrix'](),_0x24c440=_0x61fa0a['c']['Matrix'][0x5];_0x270a0f['invertToRef'](_0x24c440);var _0x3cd3c2=_0x61fa0a['c']['Vector3'][0x8];_0x61fa0a['e']['TransformCoordinatesFromFloatsToRef'](_0x53faea,_0x4d4391,_0x459c6a,_0x24c440,_0x3cd3c2);var _0x52c13f=this['getClosestFacetAtLocalCoordinates'](_0x3cd3c2['x'],_0x3cd3c2['y'],_0x3cd3c2['z'],_0x4fd3fe,_0x41e659,_0x235ad4);return _0x4fd3fe&&_0x61fa0a['e']['TransformCoordinatesFromFloatsToRef'](_0x4fd3fe['x'],_0x4fd3fe['y'],_0x4fd3fe['z'],_0x270a0f,_0x4fd3fe),_0x52c13f;},_0x5db440['prototype']['getClosestFacetAtLocalCoordinates']=function(_0x19a462,_0x3afc0b,_0xb279e6,_0xd1f03f,_0x1ec44f,_0x263069){void 0x0===_0x1ec44f&&(_0x1ec44f=!0x1),void 0x0===_0x263069&&(_0x263069=!0x0);var _0x3f58b2=null,_0x18262b=0x0,_0x2e53fe=0x0,_0x2647eb=0x0,_0x40032a=0x0,_0x44230c=0x0,_0x38277c=0x0,_0x1f17fd=0x0,_0x502068=0x0,_0x524bb4=this['getFacetLocalPositions'](),_0x4a7cff=this['getFacetLocalNormals'](),_0x3942d6=this['getFacetsAtLocalCoordinates'](_0x19a462,_0x3afc0b,_0xb279e6);if(!_0x3942d6)return null;for(var _0x318662,_0x5d7815,_0x2bf711,_0xb16013=Number['MAX_VALUE'],_0x1b9139=_0xb16013,_0x127856=0x0;_0x127856<_0x3942d6['length'];_0x127856++)_0x5d7815=_0x4a7cff[_0x318662=_0x3942d6[_0x127856]],_0x40032a=(_0x19a462-(_0x2bf711=_0x524bb4[_0x318662])['x'])*_0x5d7815['x']+(_0x3afc0b-_0x2bf711['y'])*_0x5d7815['y']+(_0xb279e6-_0x2bf711['z'])*_0x5d7815['z'],(!_0x1ec44f||_0x1ec44f&&_0x263069&&_0x40032a>=0x0||_0x1ec44f&&!_0x263069&&_0x40032a<=0x0)&&(_0x40032a=_0x5d7815['x']*_0x2bf711['x']+_0x5d7815['y']*_0x2bf711['y']+_0x5d7815['z']*_0x2bf711['z'],_0x44230c=-(_0x5d7815['x']*_0x19a462+_0x5d7815['y']*_0x3afc0b+_0x5d7815['z']*_0xb279e6-_0x40032a)/(_0x5d7815['x']*_0x5d7815['x']+_0x5d7815['y']*_0x5d7815['y']+_0x5d7815['z']*_0x5d7815['z']),(_0x1b9139=(_0x18262b=(_0x38277c=_0x19a462+_0x5d7815['x']*_0x44230c)-_0x19a462)*_0x18262b+(_0x2e53fe=(_0x1f17fd=_0x3afc0b+_0x5d7815['y']*_0x44230c)-_0x3afc0b)*_0x2e53fe+(_0x2647eb=(_0x502068=_0xb279e6+_0x5d7815['z']*_0x44230c)-_0xb279e6)*_0x2647eb)<_0xb16013&&(_0xb16013=_0x1b9139,_0x3f58b2=_0x318662,_0xd1f03f&&(_0xd1f03f['x']=_0x38277c,_0xd1f03f['y']=_0x1f17fd,_0xd1f03f['z']=_0x502068)));return _0x3f58b2;},_0x5db440['prototype']['getFacetDataParameters']=function(){return this['_internalAbstractMeshDataInfo']['_facetData']['facetParameters'];},_0x5db440['prototype']['disableFacetData']=function(){var _0x4b58a3=this['_internalAbstractMeshDataInfo']['_facetData'];return _0x4b58a3['facetDataEnabled']&&(_0x4b58a3['facetDataEnabled']=!0x1,_0x4b58a3['facetPositions']=new Array(),_0x4b58a3['facetNormals']=new Array(),_0x4b58a3['facetPartitioning']=new Array(),_0x4b58a3['facetParameters']=null,_0x4b58a3['depthSortedIndices']=new Uint32Array(0x0)),this;},_0x5db440['prototype']['updateIndices']=function(_0x47c907,_0x3dfd0a,_0x2d0680){return void 0x0===_0x2d0680&&(_0x2d0680=!0x1),this;},_0x5db440['prototype']['createNormals']=function(_0x294b18){var _0x2038de,_0x390863=this['getVerticesData'](_0x5de82f['b']['PositionKind']),_0x5377ef=this['getIndices']();return _0x2038de=this['isVerticesDataPresent'](_0x5de82f['b']['NormalKind'])?this['getVerticesData'](_0x5de82f['b']['NormalKind']):[],_0xcff5cc['a']['ComputeNormals'](_0x390863,_0x5377ef,_0x2038de,{'useRightHandedSystem':this['getScene']()['useRightHandedSystem']}),this['setVerticesData'](_0x5de82f['b']['NormalKind'],_0x2038de,_0x294b18),this;},_0x5db440['prototype']['alignWithNormal']=function(_0x52966b,_0x376e40){_0x376e40||(_0x376e40=_0x3465d2['a']['Y']);var _0xfcfb8a=_0x61fa0a['c']['Vector3'][0x0],_0x5f1f82=_0x61fa0a['c']['Vector3'][0x1];return _0x61fa0a['e']['CrossToRef'](_0x376e40,_0x52966b,_0x5f1f82),_0x61fa0a['e']['CrossToRef'](_0x52966b,_0x5f1f82,_0xfcfb8a),this['rotationQuaternion']?_0x61fa0a['b']['RotationQuaternionFromAxisToRef'](_0xfcfb8a,_0x52966b,_0x5f1f82,this['rotationQuaternion']):_0x61fa0a['e']['RotationFromAxisToRef'](_0xfcfb8a,_0x52966b,_0x5f1f82,this['rotation']),this;},_0x5db440['prototype']['_checkOcclusionQuery']=function(){return!0x1;},_0x5db440['prototype']['disableEdgesRendering']=function(){throw _0x11193c['a']['WarnImport']('EdgesRenderer');},_0x5db440['prototype']['enableEdgesRendering']=function(_0x1d25b7,_0x96436b,_0x314b8f){throw _0x11193c['a']['WarnImport']('EdgesRenderer');},_0x5db440['prototype']['getConnectedParticleSystems']=function(){var _0x27ff66=this;return this['_scene']['particleSystems']['filter'](function(_0x2534dd){return _0x2534dd['emitter']===_0x27ff66;});},_0x5db440['OCCLUSION_TYPE_NONE']=0x0,_0x5db440['OCCLUSION_TYPE_OPTIMISTIC']=0x1,_0x5db440['OCCLUSION_TYPE_STRICT']=0x2,_0x5db440['OCCLUSION_ALGORITHM_TYPE_ACCURATE']=0x0,_0x5db440['OCCLUSION_ALGORITHM_TYPE_CONSERVATIVE']=0x1,_0x5db440['CULLINGSTRATEGY_STANDARD']=_0x419e0a['a']['MESHES_CULLINGSTRATEGY_STANDARD'],_0x5db440['CULLINGSTRATEGY_BOUNDINGSPHERE_ONLY']=_0x419e0a['a']['MESHES_CULLINGSTRATEGY_BOUNDINGSPHERE_ONLY'],_0x5db440['CULLINGSTRATEGY_OPTIMISTIC_INCLUSION']=_0x419e0a['a']['MESHES_CULLINGSTRATEGY_OPTIMISTIC_INCLUSION'],_0x5db440['CULLINGSTRATEGY_OPTIMISTIC_INCLUSION_THEN_BSPHERE_ONLY']=_0x419e0a['a']['MESHES_CULLINGSTRATEGY_OPTIMISTIC_INCLUSION_THEN_BSPHERE_ONLY'],_0x5db440;}(_0x13bd42['a']);_0x6a263c['a']['RegisteredTypes']['BABYLON.AbstractMesh']=_0x41ac3c;},function(_0x902d54,_0x5b774e,_0x19528d){'use strict';_0x19528d['d'](_0x5b774e,'a',function(){return _0x167b95;});var _0x3efacb=_0x19528d(0x8),_0x313c4b=_0x19528d(0x2c),_0x304cf9=_0x19528d(0x0),_0x8e1d1a=_0x19528d(0x1f),_0x16c3f8=_0x19528d(0x7),_0x12b3aa=_0x19528d(0x32),_0x74bc37=_0x19528d(0x17);_0x16c3f8['a']['_PhysicsImpostorParser']=function(_0x1e4212,_0x34b43e,_0x426958){return new _0x167b95(_0x34b43e,_0x426958['physicsImpostor'],{'mass':_0x426958['physicsMass'],'friction':_0x426958['physicsFriction'],'restitution':_0x426958['physicsRestitution']},_0x1e4212);};var _0x167b95=(function(){function _0x158cd5(_0x16661a,_0x3e520b,_0x508bfd,_0x19eb47){var _0x5cd0cd=this;void 0x0===_0x508bfd&&(_0x508bfd={'mass':0x0}),this['object']=_0x16661a,this['type']=_0x3e520b,this['_options']=_0x508bfd,this['_scene']=_0x19eb47,this['_pluginData']={},this['_bodyUpdateRequired']=!0x1,this['_onBeforePhysicsStepCallbacks']=new Array(),this['_onAfterPhysicsStepCallbacks']=new Array(),this['_onPhysicsCollideCallbacks']=[],this['_deltaPosition']=_0x304cf9['e']['Zero'](),this['_isDisposed']=!0x1,this['soft']=!0x1,this['segments']=0x0,this['_tmpQuat']=new _0x304cf9['b'](),this['_tmpQuat2']=new _0x304cf9['b'](),this['beforeStep']=function(){_0x5cd0cd['_physicsEngine']&&(_0x5cd0cd['object']['translate'](_0x5cd0cd['_deltaPosition'],-0x1),_0x5cd0cd['_deltaRotationConjugated']&&_0x5cd0cd['object']['rotationQuaternion']&&_0x5cd0cd['object']['rotationQuaternion']['multiplyToRef'](_0x5cd0cd['_deltaRotationConjugated'],_0x5cd0cd['object']['rotationQuaternion']),_0x5cd0cd['object']['computeWorldMatrix'](!0x1),_0x5cd0cd['object']['parent']&&_0x5cd0cd['object']['rotationQuaternion']?(_0x5cd0cd['getParentsRotation'](),_0x5cd0cd['_tmpQuat']['multiplyToRef'](_0x5cd0cd['object']['rotationQuaternion'],_0x5cd0cd['_tmpQuat'])):_0x5cd0cd['_tmpQuat']['copyFrom'](_0x5cd0cd['object']['rotationQuaternion']||new _0x304cf9['b']()),_0x5cd0cd['_options']['disableBidirectionalTransformation']||_0x5cd0cd['object']['rotationQuaternion']&&_0x5cd0cd['_physicsEngine']['getPhysicsPlugin']()['setPhysicsBodyTransformation'](_0x5cd0cd,_0x5cd0cd['object']['getAbsolutePosition'](),_0x5cd0cd['_tmpQuat']),_0x5cd0cd['_onBeforePhysicsStepCallbacks']['forEach'](function(_0x1450b4){_0x1450b4(_0x5cd0cd);}));},this['afterStep']=function(){_0x5cd0cd['_physicsEngine']&&(_0x5cd0cd['_onAfterPhysicsStepCallbacks']['forEach'](function(_0x3cc77b){_0x3cc77b(_0x5cd0cd);}),_0x5cd0cd['_physicsEngine']['getPhysicsPlugin']()['setTransformationFromPhysicsBody'](_0x5cd0cd),_0x5cd0cd['object']['parent']&&_0x5cd0cd['object']['rotationQuaternion']&&(_0x5cd0cd['getParentsRotation'](),_0x5cd0cd['_tmpQuat']['conjugateInPlace'](),_0x5cd0cd['_tmpQuat']['multiplyToRef'](_0x5cd0cd['object']['rotationQuaternion'],_0x5cd0cd['object']['rotationQuaternion'])),_0x5cd0cd['object']['setAbsolutePosition'](_0x5cd0cd['object']['position']),_0x5cd0cd['_deltaRotation']&&_0x5cd0cd['object']['rotationQuaternion']&&_0x5cd0cd['object']['rotationQuaternion']['multiplyToRef'](_0x5cd0cd['_deltaRotation'],_0x5cd0cd['object']['rotationQuaternion']),_0x5cd0cd['object']['translate'](_0x5cd0cd['_deltaPosition'],0x1));},this['onCollideEvent']=null,this['onCollide']=function(_0x1c43e4){if((_0x5cd0cd['_onPhysicsCollideCallbacks']['length']||_0x5cd0cd['onCollideEvent'])&&_0x5cd0cd['_physicsEngine']){var _0x5c4864=_0x5cd0cd['_physicsEngine']['getImpostorWithPhysicsBody'](_0x1c43e4['body']);_0x5c4864&&(_0x5cd0cd['onCollideEvent']&&_0x5cd0cd['onCollideEvent'](_0x5cd0cd,_0x5c4864),_0x5cd0cd['_onPhysicsCollideCallbacks']['filter'](function(_0x4d6c94){return-0x1!==_0x4d6c94['otherImpostors']['indexOf'](_0x5c4864);})['forEach'](function(_0x5cd591){_0x5cd591['callback'](_0x5cd0cd,_0x5c4864,_0x1c43e4['point']);}));}},this['object']?(this['object']['parent']&&0x0!==_0x508bfd['mass']&&_0x3efacb['a']['Warn']('A\x20physics\x20impostor\x20has\x20been\x20created\x20for\x20an\x20object\x20which\x20has\x20a\x20parent.\x20Babylon\x20physics\x20currently\x20works\x20in\x20local\x20space\x20so\x20unexpected\x20issues\x20may\x20occur.'),!this['_scene']&&_0x16661a['getScene']&&(this['_scene']=_0x16661a['getScene']()),this['_scene']&&(this['type']>0x64&&(this['soft']=!0x0),this['_physicsEngine']=this['_scene']['getPhysicsEngine'](),this['_physicsEngine']?(this['object']['rotationQuaternion']||(this['object']['rotation']?this['object']['rotationQuaternion']=_0x304cf9['b']['RotationYawPitchRoll'](this['object']['rotation']['y'],this['object']['rotation']['x'],this['object']['rotation']['z']):this['object']['rotationQuaternion']=new _0x304cf9['b']()),this['_options']['mass']=void 0x0===_0x508bfd['mass']?0x0:_0x508bfd['mass'],this['_options']['friction']=void 0x0===_0x508bfd['friction']?0.2:_0x508bfd['friction'],this['_options']['restitution']=void 0x0===_0x508bfd['restitution']?0.2:_0x508bfd['restitution'],this['soft']&&(this['_options']['mass']=this['_options']['mass']>0x0?this['_options']['mass']:0x1,this['_options']['pressure']=void 0x0===_0x508bfd['pressure']?0xc8:_0x508bfd['pressure'],this['_options']['stiffness']=void 0x0===_0x508bfd['stiffness']?0x1:_0x508bfd['stiffness'],this['_options']['velocityIterations']=void 0x0===_0x508bfd['velocityIterations']?0x14:_0x508bfd['velocityIterations'],this['_options']['positionIterations']=void 0x0===_0x508bfd['positionIterations']?0x14:_0x508bfd['positionIterations'],this['_options']['fixedPoints']=void 0x0===_0x508bfd['fixedPoints']?0x0:_0x508bfd['fixedPoints'],this['_options']['margin']=void 0x0===_0x508bfd['margin']?0x0:_0x508bfd['margin'],this['_options']['damping']=void 0x0===_0x508bfd['damping']?0x0:_0x508bfd['damping'],this['_options']['path']=void 0x0===_0x508bfd['path']?null:_0x508bfd['path'],this['_options']['shape']=void 0x0===_0x508bfd['shape']?null:_0x508bfd['shape']),this['_joints']=[],!this['object']['parent']||this['_options']['ignoreParent']?this['_init']():this['object']['parent']['physicsImpostor']&&_0x3efacb['a']['Warn']('You\x20must\x20affect\x20impostors\x20to\x20children\x20before\x20affecting\x20impostor\x20to\x20parent.')):_0x3efacb['a']['Error']('Physics\x20not\x20enabled.\x20Please\x20use\x20scene.enablePhysics(...)\x20before\x20creating\x20impostors.'))):_0x3efacb['a']['Error']('No\x20object\x20was\x20provided.\x20A\x20physics\x20object\x20is\x20obligatory');}return Object['defineProperty'](_0x158cd5['prototype'],'isDisposed',{'get':function(){return this['_isDisposed'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x158cd5['prototype'],'mass',{'get':function(){return this['_physicsEngine']?this['_physicsEngine']['getPhysicsPlugin']()['getBodyMass'](this):0x0;},'set':function(_0x27e294){this['setMass'](_0x27e294);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x158cd5['prototype'],'friction',{'get':function(){return this['_physicsEngine']?this['_physicsEngine']['getPhysicsPlugin']()['getBodyFriction'](this):0x0;},'set':function(_0x58f95b){this['_physicsEngine']&&this['_physicsEngine']['getPhysicsPlugin']()['setBodyFriction'](this,_0x58f95b);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x158cd5['prototype'],'restitution',{'get':function(){return this['_physicsEngine']?this['_physicsEngine']['getPhysicsPlugin']()['getBodyRestitution'](this):0x0;},'set':function(_0x1a7b6b){this['_physicsEngine']&&this['_physicsEngine']['getPhysicsPlugin']()['setBodyRestitution'](this,_0x1a7b6b);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x158cd5['prototype'],'pressure',{'get':function(){if(!this['_physicsEngine'])return 0x0;var _0x3b7b93=this['_physicsEngine']['getPhysicsPlugin']();return _0x3b7b93['setBodyPressure']?_0x3b7b93['getBodyPressure'](this):0x0;},'set':function(_0x25f17a){if(this['_physicsEngine']){var _0x2f99bf=this['_physicsEngine']['getPhysicsPlugin']();_0x2f99bf['setBodyPressure']&&_0x2f99bf['setBodyPressure'](this,_0x25f17a);}},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x158cd5['prototype'],'stiffness',{'get':function(){if(!this['_physicsEngine'])return 0x0;var _0x510737=this['_physicsEngine']['getPhysicsPlugin']();return _0x510737['getBodyStiffness']?_0x510737['getBodyStiffness'](this):0x0;},'set':function(_0x417c2b){if(this['_physicsEngine']){var _0x277677=this['_physicsEngine']['getPhysicsPlugin']();_0x277677['setBodyStiffness']&&_0x277677['setBodyStiffness'](this,_0x417c2b);}},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x158cd5['prototype'],'velocityIterations',{'get':function(){if(!this['_physicsEngine'])return 0x0;var _0x32fe2d=this['_physicsEngine']['getPhysicsPlugin']();return _0x32fe2d['getBodyVelocityIterations']?_0x32fe2d['getBodyVelocityIterations'](this):0x0;},'set':function(_0x16591d){if(this['_physicsEngine']){var _0x3484f5=this['_physicsEngine']['getPhysicsPlugin']();_0x3484f5['setBodyVelocityIterations']&&_0x3484f5['setBodyVelocityIterations'](this,_0x16591d);}},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x158cd5['prototype'],'positionIterations',{'get':function(){if(!this['_physicsEngine'])return 0x0;var _0x236444=this['_physicsEngine']['getPhysicsPlugin']();return _0x236444['getBodyPositionIterations']?_0x236444['getBodyPositionIterations'](this):0x0;},'set':function(_0x16fb95){if(this['_physicsEngine']){var _0x4ea7f1=this['_physicsEngine']['getPhysicsPlugin']();_0x4ea7f1['setBodyPositionIterations']&&_0x4ea7f1['setBodyPositionIterations'](this,_0x16fb95);}},'enumerable':!0x1,'configurable':!0x0}),_0x158cd5['prototype']['_init']=function(){this['_physicsEngine']&&(this['_physicsEngine']['removeImpostor'](this),this['physicsBody']=null,this['_parent']=this['_parent']||this['_getPhysicsParent'](),this['_isDisposed']||this['parent']&&!this['_options']['ignoreParent']||this['_physicsEngine']['addImpostor'](this));},_0x158cd5['prototype']['_getPhysicsParent']=function(){return this['object']['parent']instanceof _0x8e1d1a['a']?this['object']['parent']['physicsImpostor']:null;},_0x158cd5['prototype']['isBodyInitRequired']=function(){return this['_bodyUpdateRequired']||!this['_physicsBody']&&!this['_parent'];},_0x158cd5['prototype']['setScalingUpdated']=function(){this['forceUpdate']();},_0x158cd5['prototype']['forceUpdate']=function(){this['_init'](),this['parent']&&!this['_options']['ignoreParent']&&this['parent']['forceUpdate']();},Object['defineProperty'](_0x158cd5['prototype'],'physicsBody',{'get':function(){return this['_parent']&&!this['_options']['ignoreParent']?this['_parent']['physicsBody']:this['_physicsBody'];},'set':function(_0x1aa176){this['_physicsBody']&&this['_physicsEngine']&&this['_physicsEngine']['getPhysicsPlugin']()['removePhysicsBody'](this),this['_physicsBody']=_0x1aa176,this['resetUpdateFlags']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x158cd5['prototype'],'parent',{'get':function(){return!this['_options']['ignoreParent']&&this['_parent']?this['_parent']:null;},'set':function(_0x4fbdd8){this['_parent']=_0x4fbdd8;},'enumerable':!0x1,'configurable':!0x0}),_0x158cd5['prototype']['resetUpdateFlags']=function(){this['_bodyUpdateRequired']=!0x1;},_0x158cd5['prototype']['getObjectExtendSize']=function(){if(this['object']['getBoundingInfo']){var _0x27d965=this['object']['rotationQuaternion'],_0x2a74a6=this['object']['scaling']['clone']();this['object']['rotationQuaternion']=_0x158cd5['IDENTITY_QUATERNION'];var _0x371d56=this['object']['computeWorldMatrix']&&this['object']['computeWorldMatrix'](!0x0);_0x371d56&&_0x371d56['decompose'](_0x2a74a6,void 0x0,void 0x0);var _0x27c8a0=this['object']['getBoundingInfo']()['boundingBox']['extendSize']['scale'](0x2)['multiplyInPlace'](_0x2a74a6);return this['object']['rotationQuaternion']=_0x27d965,this['object']['computeWorldMatrix']&&this['object']['computeWorldMatrix'](!0x0),_0x27c8a0;}return _0x158cd5['DEFAULT_OBJECT_SIZE'];},_0x158cd5['prototype']['getObjectCenter']=function(){return this['object']['getBoundingInfo']?this['object']['getBoundingInfo']()['boundingBox']['centerWorld']:this['object']['position'];},_0x158cd5['prototype']['getParam']=function(_0x588315){return this['_options'][_0x588315];},_0x158cd5['prototype']['setParam']=function(_0x21fbfd,_0x4f1bc7){this['_options'][_0x21fbfd]=_0x4f1bc7,this['_bodyUpdateRequired']=!0x0;},_0x158cd5['prototype']['setMass']=function(_0x4ba765){this['getParam']('mass')!==_0x4ba765&&this['setParam']('mass',_0x4ba765),this['_physicsEngine']&&this['_physicsEngine']['getPhysicsPlugin']()['setBodyMass'](this,_0x4ba765);},_0x158cd5['prototype']['getLinearVelocity']=function(){return this['_physicsEngine']?this['_physicsEngine']['getPhysicsPlugin']()['getLinearVelocity'](this):_0x304cf9['e']['Zero']();},_0x158cd5['prototype']['setLinearVelocity']=function(_0x22413f){this['_physicsEngine']&&this['_physicsEngine']['getPhysicsPlugin']()['setLinearVelocity'](this,_0x22413f);},_0x158cd5['prototype']['getAngularVelocity']=function(){return this['_physicsEngine']?this['_physicsEngine']['getPhysicsPlugin']()['getAngularVelocity'](this):_0x304cf9['e']['Zero']();},_0x158cd5['prototype']['setAngularVelocity']=function(_0xb1ab76){this['_physicsEngine']&&this['_physicsEngine']['getPhysicsPlugin']()['setAngularVelocity'](this,_0xb1ab76);},_0x158cd5['prototype']['executeNativeFunction']=function(_0x1d27b1){this['_physicsEngine']&&_0x1d27b1(this['_physicsEngine']['getPhysicsPlugin']()['world'],this['physicsBody']);},_0x158cd5['prototype']['registerBeforePhysicsStep']=function(_0x7e53a0){this['_onBeforePhysicsStepCallbacks']['push'](_0x7e53a0);},_0x158cd5['prototype']['unregisterBeforePhysicsStep']=function(_0x31017b){var _0x18cdc3=this['_onBeforePhysicsStepCallbacks']['indexOf'](_0x31017b);_0x18cdc3>-0x1?this['_onBeforePhysicsStepCallbacks']['splice'](_0x18cdc3,0x1):_0x3efacb['a']['Warn']('Function\x20to\x20remove\x20was\x20not\x20found');},_0x158cd5['prototype']['registerAfterPhysicsStep']=function(_0x2cc237){this['_onAfterPhysicsStepCallbacks']['push'](_0x2cc237);},_0x158cd5['prototype']['unregisterAfterPhysicsStep']=function(_0x1cab6b){var _0x1b491f=this['_onAfterPhysicsStepCallbacks']['indexOf'](_0x1cab6b);_0x1b491f>-0x1?this['_onAfterPhysicsStepCallbacks']['splice'](_0x1b491f,0x1):_0x3efacb['a']['Warn']('Function\x20to\x20remove\x20was\x20not\x20found');},_0x158cd5['prototype']['registerOnPhysicsCollide']=function(_0x27f8cf,_0x109728){var _0x111e51=_0x27f8cf instanceof Array?_0x27f8cf:[_0x27f8cf];this['_onPhysicsCollideCallbacks']['push']({'callback':_0x109728,'otherImpostors':_0x111e51});},_0x158cd5['prototype']['unregisterOnPhysicsCollide']=function(_0x120df9,_0x45a7d){var _0x444e2c=_0x120df9 instanceof Array?_0x120df9:[_0x120df9],_0x55cb0f=-0x1;this['_onPhysicsCollideCallbacks']['some'](function(_0x5a883d,_0x52bfa3){if(_0x5a883d['callback']===_0x45a7d&&_0x5a883d['otherImpostors']['length']===_0x444e2c['length']){var _0xa38a37=_0x5a883d['otherImpostors']['every'](function(_0x58e9a5){return _0x444e2c['indexOf'](_0x58e9a5)>-0x1;});return _0xa38a37&&(_0x55cb0f=_0x52bfa3),_0xa38a37;}return!0x1;})?this['_onPhysicsCollideCallbacks']['splice'](_0x55cb0f,0x1):_0x3efacb['a']['Warn']('Function\x20to\x20remove\x20was\x20not\x20found');},_0x158cd5['prototype']['getParentsRotation']=function(){var _0x326563=this['object']['parent'];for(this['_tmpQuat']['copyFromFloats'](0x0,0x0,0x0,0x1);_0x326563;)_0x326563['rotationQuaternion']?this['_tmpQuat2']['copyFrom'](_0x326563['rotationQuaternion']):_0x304cf9['b']['RotationYawPitchRollToRef'](_0x326563['rotation']['y'],_0x326563['rotation']['x'],_0x326563['rotation']['z'],this['_tmpQuat2']),this['_tmpQuat']['multiplyToRef'](this['_tmpQuat2'],this['_tmpQuat']),_0x326563=_0x326563['parent'];return this['_tmpQuat'];},_0x158cd5['prototype']['applyForce']=function(_0x397f46,_0x26ed42){return this['_physicsEngine']&&this['_physicsEngine']['getPhysicsPlugin']()['applyForce'](this,_0x397f46,_0x26ed42),this;},_0x158cd5['prototype']['applyImpulse']=function(_0x477954,_0x45e1af){return this['_physicsEngine']&&this['_physicsEngine']['getPhysicsPlugin']()['applyImpulse'](this,_0x477954,_0x45e1af),this;},_0x158cd5['prototype']['createJoint']=function(_0x9e992f,_0xcfd1e6,_0xbc6f98){var _0x575361=new _0x12b3aa['e'](_0xcfd1e6,_0xbc6f98);return this['addJoint'](_0x9e992f,_0x575361),this;},_0x158cd5['prototype']['addJoint']=function(_0x277a73,_0x100dd5){return this['_joints']['push']({'otherImpostor':_0x277a73,'joint':_0x100dd5}),this['_physicsEngine']&&this['_physicsEngine']['addJoint'](this,_0x277a73,_0x100dd5),this;},_0x158cd5['prototype']['addAnchor']=function(_0x48fe49,_0x3538e6,_0xa276a9,_0x5696e7,_0x161813){if(!this['_physicsEngine'])return this;var _0x29a983=this['_physicsEngine']['getPhysicsPlugin']();return _0x29a983['appendAnchor']?(this['_physicsEngine']&&_0x29a983['appendAnchor'](this,_0x48fe49,_0x3538e6,_0xa276a9,_0x5696e7,_0x161813),this):this;},_0x158cd5['prototype']['addHook']=function(_0x311f9a,_0x3415b5,_0x48cd75,_0x2b23a2){if(!this['_physicsEngine'])return this;var _0x4ee24e=this['_physicsEngine']['getPhysicsPlugin']();return _0x4ee24e['appendAnchor']?(this['_physicsEngine']&&_0x4ee24e['appendHook'](this,_0x311f9a,_0x3415b5,_0x48cd75,_0x2b23a2),this):this;},_0x158cd5['prototype']['sleep']=function(){return this['_physicsEngine']&&this['_physicsEngine']['getPhysicsPlugin']()['sleepBody'](this),this;},_0x158cd5['prototype']['wakeUp']=function(){return this['_physicsEngine']&&this['_physicsEngine']['getPhysicsPlugin']()['wakeUpBody'](this),this;},_0x158cd5['prototype']['clone']=function(_0x5049c4){return _0x5049c4?new _0x158cd5(_0x5049c4,this['type'],this['_options'],this['_scene']):null;},_0x158cd5['prototype']['dispose']=function(){var _0x2448d2=this;this['_physicsEngine']&&(this['_joints']['forEach'](function(_0x6ef086){_0x2448d2['_physicsEngine']&&_0x2448d2['_physicsEngine']['removeJoint'](_0x2448d2,_0x6ef086['otherImpostor'],_0x6ef086['joint']);}),this['_physicsEngine']['removeImpostor'](this),this['parent']&&this['parent']['forceUpdate'](),this['_isDisposed']=!0x0);},_0x158cd5['prototype']['setDeltaPosition']=function(_0x34abe6){this['_deltaPosition']['copyFrom'](_0x34abe6);},_0x158cd5['prototype']['setDeltaRotation']=function(_0x247b52){this['_deltaRotation']||(this['_deltaRotation']=new _0x304cf9['b']()),this['_deltaRotation']['copyFrom'](_0x247b52),this['_deltaRotationConjugated']=this['_deltaRotation']['conjugate']();},_0x158cd5['prototype']['getBoxSizeToRef']=function(_0x2c8c87){return this['_physicsEngine']&&this['_physicsEngine']['getPhysicsPlugin']()['getBoxSizeToRef'](this,_0x2c8c87),this;},_0x158cd5['prototype']['getRadius']=function(){return this['_physicsEngine']?this['_physicsEngine']['getPhysicsPlugin']()['getRadius'](this):0x0;},_0x158cd5['prototype']['syncBoneWithImpostor']=function(_0x13df37,_0x594da7,_0x1adcd2,_0x43cfce,_0xbd0c01){var _0x24a2f2=_0x158cd5['_tmpVecs'][0x0],_0x2f4ace=this['object'];if(_0x2f4ace['rotationQuaternion']){if(_0xbd0c01){var _0x4d4ecb=_0x158cd5['_tmpQuat'];_0x2f4ace['rotationQuaternion']['multiplyToRef'](_0xbd0c01,_0x4d4ecb),_0x13df37['setRotationQuaternion'](_0x4d4ecb,_0x74bc37['c']['WORLD'],_0x594da7);}else _0x13df37['setRotationQuaternion'](_0x2f4ace['rotationQuaternion'],_0x74bc37['c']['WORLD'],_0x594da7);}_0x24a2f2['x']=0x0,_0x24a2f2['y']=0x0,_0x24a2f2['z']=0x0,_0x1adcd2&&(_0x24a2f2['x']=_0x1adcd2['x'],_0x24a2f2['y']=_0x1adcd2['y'],_0x24a2f2['z']=_0x1adcd2['z'],_0x13df37['getDirectionToRef'](_0x24a2f2,_0x594da7,_0x24a2f2),null==_0x43cfce&&(_0x43cfce=_0x1adcd2['length']()),_0x24a2f2['x']*=_0x43cfce,_0x24a2f2['y']*=_0x43cfce,_0x24a2f2['z']*=_0x43cfce),_0x13df37['getParent']()?(_0x24a2f2['addInPlace'](_0x2f4ace['getAbsolutePosition']()),_0x13df37['setAbsolutePosition'](_0x24a2f2,_0x594da7)):(_0x594da7['setAbsolutePosition'](_0x2f4ace['getAbsolutePosition']()),_0x594da7['position']['x']-=_0x24a2f2['x'],_0x594da7['position']['y']-=_0x24a2f2['y'],_0x594da7['position']['z']-=_0x24a2f2['z']);},_0x158cd5['prototype']['syncImpostorWithBone']=function(_0x1ab68a,_0x240160,_0x55b832,_0x17adb3,_0x43335b,_0x14b0ef){var _0x392f3e=this['object'];if(_0x392f3e['rotationQuaternion']){if(_0x43335b){var _0x519a46=_0x158cd5['_tmpQuat'];_0x1ab68a['getRotationQuaternionToRef'](_0x74bc37['c']['WORLD'],_0x240160,_0x519a46),_0x519a46['multiplyToRef'](_0x43335b,_0x392f3e['rotationQuaternion']);}else _0x1ab68a['getRotationQuaternionToRef'](_0x74bc37['c']['WORLD'],_0x240160,_0x392f3e['rotationQuaternion']);}var _0x33175e=_0x158cd5['_tmpVecs'][0x0],_0x351149=_0x158cd5['_tmpVecs'][0x1];_0x14b0ef||((_0x14b0ef=_0x158cd5['_tmpVecs'][0x2])['x']=0x0,_0x14b0ef['y']=0x1,_0x14b0ef['z']=0x0),_0x1ab68a['getDirectionToRef'](_0x14b0ef,_0x240160,_0x351149),_0x1ab68a['getAbsolutePositionToRef'](_0x240160,_0x33175e),null==_0x17adb3&&_0x55b832&&(_0x17adb3=_0x55b832['length']()),null!=_0x17adb3&&(_0x33175e['x']+=_0x351149['x']*_0x17adb3,_0x33175e['y']+=_0x351149['y']*_0x17adb3,_0x33175e['z']+=_0x351149['z']*_0x17adb3),_0x392f3e['setAbsolutePosition'](_0x33175e);},_0x158cd5['DEFAULT_OBJECT_SIZE']=new _0x304cf9['e'](0x1,0x1,0x1),_0x158cd5['IDENTITY_QUATERNION']=_0x304cf9['b']['Identity'](),_0x158cd5['_tmpVecs']=_0x313c4b['a']['BuildArray'](0x3,_0x304cf9['e']['Zero']),_0x158cd5['_tmpQuat']=_0x304cf9['b']['Identity'](),_0x158cd5['NoImpostor']=0x0,_0x158cd5['SphereImpostor']=0x1,_0x158cd5['BoxImpostor']=0x2,_0x158cd5['PlaneImpostor']=0x3,_0x158cd5['MeshImpostor']=0x4,_0x158cd5['CapsuleImpostor']=0x6,_0x158cd5['CylinderImpostor']=0x7,_0x158cd5['ParticleImpostor']=0x8,_0x158cd5['HeightmapImpostor']=0x9,_0x158cd5['ConvexHullImpostor']=0xa,_0x158cd5['CustomImpostor']=0x64,_0x158cd5['RopeImpostor']=0x65,_0x158cd5['ClothImpostor']=0x66,_0x158cd5['SoftbodyImpostor']=0x67,_0x158cd5;}());},function(_0x4a026f,_0x575dda,_0x3c8a54){'use strict';_0x3c8a54['d'](_0x575dda,'a',function(){return _0x197961;}),_0x3c8a54['d'](_0x575dda,'b',function(){return _0x369fc1;});var _0x2d01b1=_0x3c8a54(0x1),_0x197961=(function(){function _0x7fe816(_0xd11bed){this['length']=0x0,this['data']=new Array(_0xd11bed),this['_id']=_0x7fe816['_GlobalId']++;}return _0x7fe816['prototype']['push']=function(_0xede4ac){this['data'][this['length']++]=_0xede4ac,this['length']>this['data']['length']&&(this['data']['length']*=0x2);},_0x7fe816['prototype']['forEach']=function(_0x70c5c2){for(var _0x582426=0x0;_0x582426this['data']['length']&&(this['data']['length']=0x2*(this['length']+_0x59086c['length']));for(var _0x4e0df2=0x0;_0x4e0df2<_0x59086c['length'];_0x4e0df2++)this['data'][this['length']++]=(_0x59086c['data']||_0x59086c)[_0x4e0df2];}},_0x7fe816['prototype']['indexOf']=function(_0x25649a){var _0x35c699=this['data']['indexOf'](_0x25649a);return _0x35c699>=this['length']?-0x1:_0x35c699;},_0x7fe816['prototype']['contains']=function(_0x2b9dc1){return-0x1!==this['indexOf'](_0x2b9dc1);},_0x7fe816['_GlobalId']=0x0,_0x7fe816;}()),_0x369fc1=function(_0x13da07){function _0x338ba3(){var _0x212a20=null!==_0x13da07&&_0x13da07['apply'](this,arguments)||this;return _0x212a20['_duplicateId']=0x0,_0x212a20;}return Object(_0x2d01b1['d'])(_0x338ba3,_0x13da07),_0x338ba3['prototype']['push']=function(_0x2e4336){_0x13da07['prototype']['push']['call'](this,_0x2e4336),_0x2e4336['__smartArrayFlags']||(_0x2e4336['__smartArrayFlags']={}),_0x2e4336['__smartArrayFlags'][this['_id']]=this['_duplicateId'];},_0x338ba3['prototype']['pushNoDuplicate']=function(_0xb4c8db){return(!_0xb4c8db['__smartArrayFlags']||_0xb4c8db['__smartArrayFlags'][this['_id']]!==this['_duplicateId'])&&(this['push'](_0xb4c8db),!0x0);},_0x338ba3['prototype']['reset']=function(){_0x13da07['prototype']['reset']['call'](this),this['_duplicateId']++;},_0x338ba3['prototype']['concatWithNoDuplicate']=function(_0x22d0ef){if(0x0!==_0x22d0ef['length']){this['length']+_0x22d0ef['length']>this['data']['length']&&(this['data']['length']=0x2*(this['length']+_0x22d0ef['length']));for(var _0x399936=0x0;_0x399936<_0x22d0ef['length'];_0x399936++){var _0x3bbae6=(_0x22d0ef['data']||_0x22d0ef)[_0x399936];this['pushNoDuplicate'](_0x3bbae6);}}},_0x338ba3;}(_0x197961);},function(_0x28ad93,_0x3a69a4,_0x93121){'use strict';_0x93121['d'](_0x3a69a4,'a',function(){return _0x1bcd60;});var _0x1bcd60=(function(){function _0x3a3495(){}return _0x3a3495['EndsWith']=function(_0x2c26ef,_0x182b2b){return-0x1!==_0x2c26ef['indexOf'](_0x182b2b,_0x2c26ef['length']-_0x182b2b['length']);},_0x3a3495['StartsWith']=function(_0x22534f,_0x44501e){return!!_0x22534f&&0x0===_0x22534f['indexOf'](_0x44501e);},_0x3a3495['Decode']=function(_0x492c68){if('undefined'!=typeof TextDecoder)return new TextDecoder()['decode'](_0x492c68);for(var _0x55af2f='',_0x5dacb0=0x0;_0x5dacb0<_0x492c68['byteLength'];_0x5dacb0++)_0x55af2f+=String['fromCharCode'](_0x492c68[_0x5dacb0]);return _0x55af2f;},_0x3a3495['EncodeArrayBufferToBase64']=function(_0x3f0feb){for(var _0x438fcd,_0x24ab25,_0x1d9a77,_0x32a641,_0x40d230,_0x3a8ebc,_0x162ec9,_0x423999='ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=',_0x4c19fd='',_0x45f4d6=0x0,_0x2d86a8=ArrayBuffer['isView'](_0x3f0feb)?new Uint8Array(_0x3f0feb['buffer'],_0x3f0feb['byteOffset'],_0x3f0feb['byteLength']):new Uint8Array(_0x3f0feb);_0x45f4d6<_0x2d86a8['length'];)_0x32a641=(_0x438fcd=_0x2d86a8[_0x45f4d6++])>>0x2,_0x40d230=(0x3&_0x438fcd)<<0x4|(_0x24ab25=_0x45f4d6<_0x2d86a8['length']?_0x2d86a8[_0x45f4d6++]:Number['NaN'])>>0x4,_0x3a8ebc=(0xf&_0x24ab25)<<0x2|(_0x1d9a77=_0x45f4d6<_0x2d86a8['length']?_0x2d86a8[_0x45f4d6++]:Number['NaN'])>>0x6,_0x162ec9=0x3f&_0x1d9a77,isNaN(_0x24ab25)?_0x3a8ebc=_0x162ec9=0x40:isNaN(_0x1d9a77)&&(_0x162ec9=0x40),_0x4c19fd+=_0x423999['charAt'](_0x32a641)+_0x423999['charAt'](_0x40d230)+_0x423999['charAt'](_0x3a8ebc)+_0x423999['charAt'](_0x162ec9);return _0x4c19fd;},_0x3a3495['PadNumber']=function(_0x3ffb87,_0x17c8c7){for(var _0x1e0a7f=String(_0x3ffb87);_0x1e0a7f['length']<_0x17c8c7;)_0x1e0a7f='0'+_0x1e0a7f;return _0x1e0a7f;},_0x3a3495;}());},function(_0x16d75a,_0x4de3ae,_0x146f95){'use strict';_0x146f95['d'](_0x4de3ae,'a',function(){return _0x40c6f1;});var _0x40c6f1=(function(){function _0x4cb51d(){this['rootNodes']=new Array(),this['cameras']=new Array(),this['lights']=new Array(),this['meshes']=new Array(),this['skeletons']=new Array(),this['particleSystems']=new Array(),this['animations']=[],this['animationGroups']=new Array(),this['multiMaterials']=new Array(),this['materials']=new Array(),this['morphTargetManagers']=new Array(),this['geometries']=new Array(),this['transformNodes']=new Array(),this['actionManagers']=new Array(),this['textures']=new Array(),this['_environmentTexture']=null,this['postProcesses']=new Array();}return _0x4cb51d['AddParser']=function(_0x4e554c,_0x238f66){this['_BabylonFileParsers'][_0x4e554c]=_0x238f66;},_0x4cb51d['GetParser']=function(_0x5856a0){return this['_BabylonFileParsers'][_0x5856a0]?this['_BabylonFileParsers'][_0x5856a0]:null;},_0x4cb51d['AddIndividualParser']=function(_0x1f74d8,_0x404919){this['_IndividualBabylonFileParsers'][_0x1f74d8]=_0x404919;},_0x4cb51d['GetIndividualParser']=function(_0x253eb6){return this['_IndividualBabylonFileParsers'][_0x253eb6]?this['_IndividualBabylonFileParsers'][_0x253eb6]:null;},_0x4cb51d['Parse']=function(_0x559a14,_0x18d9a1,_0x38252f,_0x55b819){for(var _0x2652b5 in this['_BabylonFileParsers'])this['_BabylonFileParsers']['hasOwnProperty'](_0x2652b5)&&this['_BabylonFileParsers'][_0x2652b5](_0x559a14,_0x18d9a1,_0x38252f,_0x55b819);},Object['defineProperty'](_0x4cb51d['prototype'],'environmentTexture',{'get':function(){return this['_environmentTexture'];},'set':function(_0x2bc59d){this['_environmentTexture']=_0x2bc59d;},'enumerable':!0x1,'configurable':!0x0}),_0x4cb51d['prototype']['getNodes']=function(){var _0xcf1ee9=new Array();return _0xcf1ee9=(_0xcf1ee9=(_0xcf1ee9=(_0xcf1ee9=_0xcf1ee9['concat'](this['meshes']))['concat'](this['lights']))['concat'](this['cameras']))['concat'](this['transformNodes']),this['skeletons']['forEach'](function(_0x37d5ca){return _0xcf1ee9=_0xcf1ee9['concat'](_0x37d5ca['bones']);}),_0xcf1ee9;},_0x4cb51d['_BabylonFileParsers']={},_0x4cb51d['_IndividualBabylonFileParsers']={},_0x4cb51d;}());},function(_0x2398ef,_0x2bc2b3,_0x11dc96){'use strict';_0x11dc96['d'](_0x2bc2b3,'a',function(){return _0xfc3667;});var _0x44a9a1=_0x11dc96(0x14),_0x2086b8=_0x11dc96(0x6),_0x5d0dda=_0x11dc96(0x12),_0x147bf1=_0x11dc96(0x16),_0x1e034f=_0x11dc96(0x56),_0x4ea89d=_0x11dc96(0x0),_0x27b2bd=_0x11dc96(0x9),_0xfc3667=(function(){function _0x114b65(_0x10b059,_0x3a814c){var _0x3b390f=this;void 0x0===_0x3a814c&&(_0x3a814c=!0x0),this['originalScene']=_0x10b059,this['_pointerCaptures']={},this['_lastPointerEvents']={},this['_sharedGizmoLight']=null,this['_renderCamera']=null,this['pickUtilitySceneFirst']=!0x0,this['shouldRender']=!0x0,this['onlyCheckPointerDownEvents']=!0x0,this['processAllEvents']=!0x1,this['onPointerOutObservable']=new _0x2086b8['c'](),this['utilityLayerScene']=new _0x44a9a1['a'](_0x10b059['getEngine'](),{'virtual':!0x0}),this['utilityLayerScene']['useRightHandedSystem']=_0x10b059['useRightHandedSystem'],this['utilityLayerScene']['_allowPostProcessClearColor']=!0x1,this['utilityLayerScene']['detachControl'](),_0x3a814c&&(this['_originalPointerObserver']=_0x10b059['onPrePointerObservable']['add'](function(_0x26972e,_0xc0cb99){if(_0x3b390f['utilityLayerScene']['activeCamera']&&(_0x3b390f['processAllEvents']||_0x26972e['type']===_0x5d0dda['a']['POINTERMOVE']||_0x26972e['type']===_0x5d0dda['a']['POINTERUP']||_0x26972e['type']===_0x5d0dda['a']['POINTERDOWN']||_0x26972e['type']===_0x5d0dda['a']['POINTERDOUBLETAP'])){_0x3b390f['utilityLayerScene']['pointerX']=_0x10b059['pointerX'],_0x3b390f['utilityLayerScene']['pointerY']=_0x10b059['pointerY'];var _0x270d7c=_0x26972e['event'];if(_0x10b059['isPointerCaptured'](_0x270d7c['pointerId']))_0x3b390f['_pointerCaptures'][_0x270d7c['pointerId']]=!0x1;else{var _0x33c4f5=_0x26972e['ray']?_0x3b390f['utilityLayerScene']['pickWithRay'](_0x26972e['ray']):_0x3b390f['utilityLayerScene']['pick'](_0x10b059['pointerX'],_0x10b059['pointerY']);if(!_0x26972e['ray']&&_0x33c4f5&&(_0x26972e['ray']=_0x33c4f5['ray']),_0x3b390f['utilityLayerScene']['onPrePointerObservable']['notifyObservers'](_0x26972e),_0x3b390f['onlyCheckPointerDownEvents']&&_0x26972e['type']!=_0x5d0dda['a']['POINTERDOWN'])return _0x26972e['skipOnPointerObservable']||_0x3b390f['utilityLayerScene']['onPointerObservable']['notifyObservers'](new _0x5d0dda['b'](_0x26972e['type'],_0x26972e['event'],_0x33c4f5),_0x26972e['type']),void(_0x26972e['type']===_0x5d0dda['a']['POINTERUP']&&_0x3b390f['_pointerCaptures'][_0x270d7c['pointerId']]&&(_0x3b390f['_pointerCaptures'][_0x270d7c['pointerId']]=!0x1));if(_0x3b390f['utilityLayerScene']['autoClearDepthAndStencil']||_0x3b390f['pickUtilitySceneFirst'])_0x33c4f5&&_0x33c4f5['hit']&&(_0x26972e['skipOnPointerObservable']||_0x3b390f['utilityLayerScene']['onPointerObservable']['notifyObservers'](new _0x5d0dda['b'](_0x26972e['type'],_0x26972e['event'],_0x33c4f5),_0x26972e['type']),_0x26972e['skipOnPointerObservable']=!0x0);else{var _0x30be1f=_0x26972e['ray']?_0x10b059['pickWithRay'](_0x26972e['ray']):_0x10b059['pick'](_0x10b059['pointerX'],_0x10b059['pointerY']),_0x894f62=_0x26972e['event'];_0x30be1f&&_0x33c4f5&&(0x0===_0x33c4f5['distance']&&_0x30be1f['pickedMesh']?_0x3b390f['mainSceneTrackerPredicate']&&_0x3b390f['mainSceneTrackerPredicate'](_0x30be1f['pickedMesh'])?(_0x3b390f['_notifyObservers'](_0x26972e,_0x30be1f,_0x894f62),_0x26972e['skipOnPointerObservable']=!0x0):_0x26972e['type']===_0x5d0dda['a']['POINTERDOWN']?_0x3b390f['_pointerCaptures'][_0x894f62['pointerId']]=!0x0:_0x3b390f['_lastPointerEvents'][_0x894f62['pointerId']]&&(_0x3b390f['onPointerOutObservable']['notifyObservers'](_0x894f62['pointerId']),delete _0x3b390f['_lastPointerEvents'][_0x894f62['pointerId']]):!_0x3b390f['_pointerCaptures'][_0x894f62['pointerId']]&&(_0x33c4f5['distance']<_0x30be1f['distance']||0x0===_0x30be1f['distance'])?(_0x3b390f['_notifyObservers'](_0x26972e,_0x33c4f5,_0x894f62),_0x26972e['skipOnPointerObservable']||(_0x26972e['skipOnPointerObservable']=_0x33c4f5['distance']>0x0)):!_0x3b390f['_pointerCaptures'][_0x894f62['pointerId']]&&_0x33c4f5['distance']>_0x30be1f['distance']&&(_0x3b390f['mainSceneTrackerPredicate']&&_0x3b390f['mainSceneTrackerPredicate'](_0x30be1f['pickedMesh'])?(_0x3b390f['_notifyObservers'](_0x26972e,_0x30be1f,_0x894f62),_0x26972e['skipOnPointerObservable']=!0x0):_0x3b390f['_lastPointerEvents'][_0x894f62['pointerId']]&&(_0x3b390f['onPointerOutObservable']['notifyObservers'](_0x894f62['pointerId']),delete _0x3b390f['_lastPointerEvents'][_0x894f62['pointerId']])),_0x26972e['type']===_0x5d0dda['a']['POINTERUP']&&_0x3b390f['_pointerCaptures'][_0x894f62['pointerId']]&&(_0x3b390f['_pointerCaptures'][_0x894f62['pointerId']]=!0x1));}}}}),this['_originalPointerObserver']&&_0x10b059['onPrePointerObservable']['makeObserverTopPriority'](this['_originalPointerObserver'])),this['utilityLayerScene']['autoClear']=!0x1,this['_afterRenderObserver']=this['originalScene']['onAfterCameraRenderObservable']['add'](function(_0x4a7ce3){_0x3b390f['shouldRender']&&_0x4a7ce3==_0x3b390f['getRenderCamera']()&&_0x3b390f['render']();}),this['_sceneDisposeObserver']=this['originalScene']['onDisposeObservable']['add'](function(){_0x3b390f['dispose']();}),this['_updateCamera']();}return _0x114b65['prototype']['getRenderCamera']=function(_0x231a63){if(this['_renderCamera'])return this['_renderCamera'];var _0x217352=void 0x0;return _0x217352=this['originalScene']['activeCameras']&&this['originalScene']['activeCameras']['length']>0x1?this['originalScene']['activeCameras'][this['originalScene']['activeCameras']['length']-0x1]:this['originalScene']['activeCamera'],_0x231a63&&_0x217352&&_0x217352['isRigCamera']?_0x217352['rigParent']:_0x217352;},_0x114b65['prototype']['setRenderCamera']=function(_0x13fc80){this['_renderCamera']=_0x13fc80;},_0x114b65['prototype']['_getSharedGizmoLight']=function(){return this['_sharedGizmoLight']||(this['_sharedGizmoLight']=new _0x1e034f['a']('shared\x20gizmo\x20light',new _0x4ea89d['e'](0x0,0x1,0x0),this['utilityLayerScene']),this['_sharedGizmoLight']['intensity']=0x2,this['_sharedGizmoLight']['groundColor']=_0x27b2bd['a']['Gray']()),this['_sharedGizmoLight'];},Object['defineProperty'](_0x114b65,'DefaultUtilityLayer',{'get':function(){return null==_0x114b65['_DefaultUtilityLayer']&&(_0x114b65['_DefaultUtilityLayer']=new _0x114b65(_0x147bf1['a']['LastCreatedScene']),_0x114b65['_DefaultUtilityLayer']['originalScene']['onDisposeObservable']['addOnce'](function(){_0x114b65['_DefaultUtilityLayer']=null;})),_0x114b65['_DefaultUtilityLayer'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x114b65,'DefaultKeepDepthUtilityLayer',{'get':function(){return null==_0x114b65['_DefaultKeepDepthUtilityLayer']&&(_0x114b65['_DefaultKeepDepthUtilityLayer']=new _0x114b65(_0x147bf1['a']['LastCreatedScene']),_0x114b65['_DefaultKeepDepthUtilityLayer']['utilityLayerScene']['autoClearDepthAndStencil']=!0x1,_0x114b65['_DefaultKeepDepthUtilityLayer']['originalScene']['onDisposeObservable']['addOnce'](function(){_0x114b65['_DefaultKeepDepthUtilityLayer']=null;})),_0x114b65['_DefaultKeepDepthUtilityLayer'];},'enumerable':!0x1,'configurable':!0x0}),_0x114b65['prototype']['_notifyObservers']=function(_0x537596,_0x287064,_0x239941){_0x537596['skipOnPointerObservable']||(this['utilityLayerScene']['onPointerObservable']['notifyObservers'](new _0x5d0dda['b'](_0x537596['type'],_0x537596['event'],_0x287064),_0x537596['type']),this['_lastPointerEvents'][_0x239941['pointerId']]=!0x0);},_0x114b65['prototype']['render']=function(){if(this['_updateCamera'](),this['utilityLayerScene']['activeCamera']){var _0x4384fd=this['utilityLayerScene']['activeCamera']['getScene'](),_0x201065=this['utilityLayerScene']['activeCamera'];_0x201065['_scene']=this['utilityLayerScene'],_0x201065['leftCamera']&&(_0x201065['leftCamera']['_scene']=this['utilityLayerScene']),_0x201065['rightCamera']&&(_0x201065['rightCamera']['_scene']=this['utilityLayerScene']),this['utilityLayerScene']['render'](!0x1),_0x201065['_scene']=_0x4384fd,_0x201065['leftCamera']&&(_0x201065['leftCamera']['_scene']=_0x4384fd),_0x201065['rightCamera']&&(_0x201065['rightCamera']['_scene']=_0x4384fd);}},_0x114b65['prototype']['dispose']=function(){this['onPointerOutObservable']['clear'](),this['_afterRenderObserver']&&this['originalScene']['onAfterCameraRenderObservable']['remove'](this['_afterRenderObserver']),this['_sceneDisposeObserver']&&this['originalScene']['onDisposeObservable']['remove'](this['_sceneDisposeObserver']),this['_originalPointerObserver']&&this['originalScene']['onPrePointerObservable']['remove'](this['_originalPointerObserver']),this['utilityLayerScene']['dispose']();},_0x114b65['prototype']['_updateCamera']=function(){this['utilityLayerScene']['cameraToUseForPointers']=this['getRenderCamera'](),this['utilityLayerScene']['activeCamera']=this['getRenderCamera']();},_0x114b65['_DefaultUtilityLayer']=null,_0x114b65['_DefaultKeepDepthUtilityLayer']=null,_0x114b65;}());},function(_0x4fdb25,_0x2a63ac,_0x272fd7){'use strict';_0x272fd7['d'](_0x2a63ac,'a',function(){return _0x5ab2c9;});var _0x4f8fbf=_0x272fd7(0x8b),_0x5ab2c9=(function(){function _0x5299d8(){}return _0x5299d8['EnableFor']=function(_0x2e163b){_0x2e163b['_tags']=_0x2e163b['_tags']||{},_0x2e163b['hasTags']=function(){return _0x5299d8['HasTags'](_0x2e163b);},_0x2e163b['addTags']=function(_0x1c8b2f){return _0x5299d8['AddTagsTo'](_0x2e163b,_0x1c8b2f);},_0x2e163b['removeTags']=function(_0x2254bb){return _0x5299d8['RemoveTagsFrom'](_0x2e163b,_0x2254bb);},_0x2e163b['matchesTagsQuery']=function(_0x5f53e9){return _0x5299d8['MatchesQuery'](_0x2e163b,_0x5f53e9);};},_0x5299d8['DisableFor']=function(_0x432b43){delete _0x432b43['_tags'],delete _0x432b43['hasTags'],delete _0x432b43['addTags'],delete _0x432b43['removeTags'],delete _0x432b43['matchesTagsQuery'];},_0x5299d8['HasTags']=function(_0x142521){if(!_0x142521['_tags'])return!0x1;var _0x3828c6=_0x142521['_tags'];for(var _0x375af1 in _0x3828c6)if(_0x3828c6['hasOwnProperty'](_0x375af1))return!0x0;return!0x1;},_0x5299d8['GetTags']=function(_0x6c528,_0x37129f){if(void 0x0===_0x37129f&&(_0x37129f=!0x0),!_0x6c528['_tags'])return null;if(_0x37129f){var _0x1e4d68=[];for(var _0x4017f4 in _0x6c528['_tags'])_0x6c528['_tags']['hasOwnProperty'](_0x4017f4)&&!0x0===_0x6c528['_tags'][_0x4017f4]&&_0x1e4d68['push'](_0x4017f4);return _0x1e4d68['join']('\x20');}return _0x6c528['_tags'];},_0x5299d8['AddTagsTo']=function(_0x2a6e78,_0x5e0fee){_0x5e0fee&&('string'==typeof _0x5e0fee&&_0x5e0fee['split']('\x20')['forEach'](function(_0x41e4b3,_0x4504bc,_0x1f16fb){_0x5299d8['_AddTagTo'](_0x2a6e78,_0x41e4b3);}));},_0x5299d8['_AddTagTo']=function(_0x454dbc,_0x7378){''!==(_0x7378=_0x7378['trim']())&&'true'!==_0x7378&&'false'!==_0x7378&&(_0x7378['match'](/[\s]/)||_0x7378['match'](/^([!]|([|]|[&]){2})/)||(_0x5299d8['EnableFor'](_0x454dbc),_0x454dbc['_tags'][_0x7378]=!0x0));},_0x5299d8['RemoveTagsFrom']=function(_0x4a3bc3,_0x48ed35){if(_0x5299d8['HasTags'](_0x4a3bc3)){var _0x33a909=_0x48ed35['split']('\x20');for(var _0x20331b in _0x33a909)_0x5299d8['_RemoveTagFrom'](_0x4a3bc3,_0x33a909[_0x20331b]);}},_0x5299d8['_RemoveTagFrom']=function(_0x1c3436,_0x3f2096){delete _0x1c3436['_tags'][_0x3f2096];},_0x5299d8['MatchesQuery']=function(_0x308b67,_0x1dfacb){return void 0x0===_0x1dfacb||(''===_0x1dfacb?_0x5299d8['HasTags'](_0x308b67):_0x4f8fbf['a']['Eval'](_0x1dfacb,function(_0x12cda5){return _0x5299d8['HasTags'](_0x308b67)&&_0x308b67['_tags'][_0x12cda5];}));},_0x5299d8;}());},function(_0x1b5fa8,_0x1e2f49,_0x5c6d5c){'use strict';_0x5c6d5c['d'](_0x1e2f49,'a',function(){return _0x1bd80a;});var _0x1bd80a=(function(){function _0x375ddb(){}return _0x375ddb['IsWindowObjectExist']=function(){return'undefined'!=typeof window;},_0x375ddb['IsNavigatorAvailable']=function(){return'undefined'!=typeof navigator;},_0x375ddb['IsDocumentAvailable']=function(){return'undefined'!=typeof document;},_0x375ddb['GetDOMTextContent']=function(_0x4b9f8c){for(var _0x3fcd38='',_0x44c5f8=_0x4b9f8c['firstChild'];_0x44c5f8;)0x3===_0x44c5f8['nodeType']&&(_0x3fcd38+=_0x44c5f8['textContent']),_0x44c5f8=_0x44c5f8['nextSibling'];return _0x3fcd38;},_0x375ddb;}());},function(_0x130c5c,_0x4db9ae,_0x1a8001){'use strict';_0x1a8001['d'](_0x4db9ae,'a',function(){return _0x5aee8d;});var _0x9dc3db=_0x1a8001(0x2c),_0x33cbf4=_0x1a8001(0x0),_0x13e578=_0x1a8001(0x36),_0x385a6d=_0x1a8001(0x72),_0x2975d1=_0x1a8001(0x14),_0x2fa742=_0x1a8001(0x18),_0x5aee8d=(function(){function _0x128e9b(_0x1f8c0b,_0x580ad6,_0x2c7687){void 0x0===_0x2c7687&&(_0x2c7687=Number['MAX_VALUE']),this['origin']=_0x1f8c0b,this['direction']=_0x580ad6,this['length']=_0x2c7687;}return _0x128e9b['prototype']['intersectsBoxMinMax']=function(_0x58569e,_0x56047c,_0x31c07d){void 0x0===_0x31c07d&&(_0x31c07d=0x0);var _0x1a81be,_0x48d49d,_0xa969d2,_0x402ed6,_0x2a907c=_0x128e9b['_TmpVector3'][0x0]['copyFromFloats'](_0x58569e['x']-_0x31c07d,_0x58569e['y']-_0x31c07d,_0x58569e['z']-_0x31c07d),_0x507880=_0x128e9b['_TmpVector3'][0x1]['copyFromFloats'](_0x56047c['x']+_0x31c07d,_0x56047c['y']+_0x31c07d,_0x56047c['z']+_0x31c07d),_0x16c005=0x0,_0x504f04=Number['MAX_VALUE'];if(Math['abs'](this['direction']['x'])<1e-7){if(this['origin']['x']<_0x2a907c['x']||this['origin']['x']>_0x507880['x'])return!0x1;}else{if(_0x1a81be=0x1/this['direction']['x'],_0x48d49d=(_0x2a907c['x']-this['origin']['x'])*_0x1a81be,(_0xa969d2=(_0x507880['x']-this['origin']['x'])*_0x1a81be)===-0x1/0x0&&(_0xa969d2=0x1/0x0),_0x48d49d>_0xa969d2&&(_0x402ed6=_0x48d49d,_0x48d49d=_0xa969d2,_0xa969d2=_0x402ed6),(_0x16c005=Math['max'](_0x48d49d,_0x16c005))>(_0x504f04=Math['min'](_0xa969d2,_0x504f04)))return!0x1;}if(Math['abs'](this['direction']['y'])<1e-7){if(this['origin']['y']<_0x2a907c['y']||this['origin']['y']>_0x507880['y'])return!0x1;}else{if(_0x1a81be=0x1/this['direction']['y'],_0x48d49d=(_0x2a907c['y']-this['origin']['y'])*_0x1a81be,(_0xa969d2=(_0x507880['y']-this['origin']['y'])*_0x1a81be)===-0x1/0x0&&(_0xa969d2=0x1/0x0),_0x48d49d>_0xa969d2&&(_0x402ed6=_0x48d49d,_0x48d49d=_0xa969d2,_0xa969d2=_0x402ed6),(_0x16c005=Math['max'](_0x48d49d,_0x16c005))>(_0x504f04=Math['min'](_0xa969d2,_0x504f04)))return!0x1;}if(Math['abs'](this['direction']['z'])<1e-7){if(this['origin']['z']<_0x2a907c['z']||this['origin']['z']>_0x507880['z'])return!0x1;}else{if(_0x1a81be=0x1/this['direction']['z'],_0x48d49d=(_0x2a907c['z']-this['origin']['z'])*_0x1a81be,(_0xa969d2=(_0x507880['z']-this['origin']['z'])*_0x1a81be)===-0x1/0x0&&(_0xa969d2=0x1/0x0),_0x48d49d>_0xa969d2&&(_0x402ed6=_0x48d49d,_0x48d49d=_0xa969d2,_0xa969d2=_0x402ed6),(_0x16c005=Math['max'](_0x48d49d,_0x16c005))>(_0x504f04=Math['min'](_0xa969d2,_0x504f04)))return!0x1;}return!0x0;},_0x128e9b['prototype']['intersectsBox']=function(_0x6f0955,_0x4b85ce){return void 0x0===_0x4b85ce&&(_0x4b85ce=0x0),this['intersectsBoxMinMax'](_0x6f0955['minimum'],_0x6f0955['maximum'],_0x4b85ce);},_0x128e9b['prototype']['intersectsSphere']=function(_0x3d63ec,_0x20f011){void 0x0===_0x20f011&&(_0x20f011=0x0);var _0x41ae58=_0x3d63ec['center']['x']-this['origin']['x'],_0x1fed2d=_0x3d63ec['center']['y']-this['origin']['y'],_0x39e4b1=_0x3d63ec['center']['z']-this['origin']['z'],_0x26fe63=_0x41ae58*_0x41ae58+_0x1fed2d*_0x1fed2d+_0x39e4b1*_0x39e4b1,_0x3e09be=_0x3d63ec['radius']+_0x20f011,_0x35cd16=_0x3e09be*_0x3e09be;if(_0x26fe63<=_0x35cd16)return!0x0;var _0xf51341=_0x41ae58*this['direction']['x']+_0x1fed2d*this['direction']['y']+_0x39e4b1*this['direction']['z'];return!(_0xf51341<0x0)&&_0x26fe63-_0xf51341*_0xf51341<=_0x35cd16;},_0x128e9b['prototype']['intersectsTriangle']=function(_0x57fddd,_0x1d2fee,_0xe18ba4){var _0x13f2af=_0x128e9b['_TmpVector3'][0x0],_0x2df772=_0x128e9b['_TmpVector3'][0x1],_0x1061bb=_0x128e9b['_TmpVector3'][0x2],_0x45d45f=_0x128e9b['_TmpVector3'][0x3],_0x14f886=_0x128e9b['_TmpVector3'][0x4];_0x1d2fee['subtractToRef'](_0x57fddd,_0x13f2af),_0xe18ba4['subtractToRef'](_0x57fddd,_0x2df772),_0x33cbf4['e']['CrossToRef'](this['direction'],_0x2df772,_0x1061bb);var _0xa756f1=_0x33cbf4['e']['Dot'](_0x13f2af,_0x1061bb);if(0x0===_0xa756f1)return null;var _0x36c4ed=0x1/_0xa756f1;this['origin']['subtractToRef'](_0x57fddd,_0x45d45f);var _0x33884c=_0x33cbf4['e']['Dot'](_0x45d45f,_0x1061bb)*_0x36c4ed;if(_0x33884c<0x0||_0x33884c>0x1)return null;_0x33cbf4['e']['CrossToRef'](_0x45d45f,_0x13f2af,_0x14f886);var _0x13f869=_0x33cbf4['e']['Dot'](this['direction'],_0x14f886)*_0x36c4ed;if(_0x13f869<0x0||_0x33884c+_0x13f869>0x1)return null;var _0x5c4622=_0x33cbf4['e']['Dot'](_0x2df772,_0x14f886)*_0x36c4ed;return _0x5c4622>this['length']?null:new _0x385a6d['a'](0x1-_0x33884c-_0x13f869,_0x33884c,_0x5c4622);},_0x128e9b['prototype']['intersectsPlane']=function(_0x50850d){var _0x43787e,_0x5612dd=_0x33cbf4['e']['Dot'](_0x50850d['normal'],this['direction']);if(Math['abs'](_0x5612dd)<9.99999997475243e-7)return null;var _0x2708a=_0x33cbf4['e']['Dot'](_0x50850d['normal'],this['origin']);return(_0x43787e=(-_0x50850d['d']-_0x2708a)/_0x5612dd)<0x0?_0x43787e<-9.99999997475243e-7?null:0x0:_0x43787e;},_0x128e9b['prototype']['intersectsAxis']=function(_0xacfb77,_0xeed7a0){switch(void 0x0===_0xeed7a0&&(_0xeed7a0=0x0),_0xacfb77){case'y':return(_0x3a15cb=(this['origin']['y']-_0xeed7a0)/this['direction']['y'])>0x0?null:new _0x33cbf4['e'](this['origin']['x']+this['direction']['x']*-_0x3a15cb,_0xeed7a0,this['origin']['z']+this['direction']['z']*-_0x3a15cb);case'x':return(_0x3a15cb=(this['origin']['x']-_0xeed7a0)/this['direction']['x'])>0x0?null:new _0x33cbf4['e'](_0xeed7a0,this['origin']['y']+this['direction']['y']*-_0x3a15cb,this['origin']['z']+this['direction']['z']*-_0x3a15cb);case'z':var _0x3a15cb;return(_0x3a15cb=(this['origin']['z']-_0xeed7a0)/this['direction']['z'])>0x0?null:new _0x33cbf4['e'](this['origin']['x']+this['direction']['x']*-_0x3a15cb,this['origin']['y']+this['direction']['y']*-_0x3a15cb,_0xeed7a0);default:return null;}},_0x128e9b['prototype']['intersectsMesh']=function(_0x4e6363,_0x414b7e){var _0x39a990=_0x33cbf4['c']['Matrix'][0x0];return _0x4e6363['getWorldMatrix']()['invertToRef'](_0x39a990),this['_tmpRay']?_0x128e9b['TransformToRef'](this,_0x39a990,this['_tmpRay']):this['_tmpRay']=_0x128e9b['Transform'](this,_0x39a990),_0x4e6363['intersects'](this['_tmpRay'],_0x414b7e);},_0x128e9b['prototype']['intersectsMeshes']=function(_0x5aa0c5,_0x13ab88,_0x5c7846){_0x5c7846?_0x5c7846['length']=0x0:_0x5c7846=[];for(var _0x1bd828=0x0;_0x1bd828<_0x5aa0c5['length'];_0x1bd828++){var _0x112bd3=this['intersectsMesh'](_0x5aa0c5[_0x1bd828],_0x13ab88);_0x112bd3['hit']&&_0x5c7846['push'](_0x112bd3);}return _0x5c7846['sort'](this['_comparePickingInfo']),_0x5c7846;},_0x128e9b['prototype']['_comparePickingInfo']=function(_0x30a445,_0x35e58e){return _0x30a445['distance']<_0x35e58e['distance']?-0x1:_0x30a445['distance']>_0x35e58e['distance']?0x1:0x0;},_0x128e9b['prototype']['intersectionSegment']=function(_0xddac5,_0x51366c,_0x28da4e){var _0xe01978=this['origin'],_0x12abf8=_0x33cbf4['c']['Vector3'][0x0],_0x46b878=_0x33cbf4['c']['Vector3'][0x1],_0x1d49ff=_0x33cbf4['c']['Vector3'][0x2],_0x240cd5=_0x33cbf4['c']['Vector3'][0x3];_0x51366c['subtractToRef'](_0xddac5,_0x12abf8),this['direction']['scaleToRef'](_0x128e9b['rayl'],_0x1d49ff),_0xe01978['addToRef'](_0x1d49ff,_0x46b878),_0xddac5['subtractToRef'](_0xe01978,_0x240cd5);var _0x168c31,_0x4387af,_0x486e51,_0x161915,_0x3901d3=_0x33cbf4['e']['Dot'](_0x12abf8,_0x12abf8),_0x1fcba0=_0x33cbf4['e']['Dot'](_0x12abf8,_0x1d49ff),_0x149da9=_0x33cbf4['e']['Dot'](_0x1d49ff,_0x1d49ff),_0x4c2282=_0x33cbf4['e']['Dot'](_0x12abf8,_0x240cd5),_0x142dd9=_0x33cbf4['e']['Dot'](_0x1d49ff,_0x240cd5),_0xff0fd3=_0x3901d3*_0x149da9-_0x1fcba0*_0x1fcba0,_0x29c3d3=_0xff0fd3,_0x4c07cb=_0xff0fd3;_0xff0fd3<_0x128e9b['smallnum']?(_0x4387af=0x0,_0x29c3d3=0x1,_0x161915=_0x142dd9,_0x4c07cb=_0x149da9):(_0x161915=_0x3901d3*_0x142dd9-_0x1fcba0*_0x4c2282,(_0x4387af=_0x1fcba0*_0x142dd9-_0x149da9*_0x4c2282)<0x0?(_0x4387af=0x0,_0x161915=_0x142dd9,_0x4c07cb=_0x149da9):_0x4387af>_0x29c3d3&&(_0x4387af=_0x29c3d3,_0x161915=_0x142dd9+_0x1fcba0,_0x4c07cb=_0x149da9)),_0x161915<0x0?(_0x161915=0x0,-_0x4c2282<0x0?_0x4387af=0x0:-_0x4c2282>_0x3901d3?_0x4387af=_0x29c3d3:(_0x4387af=-_0x4c2282,_0x29c3d3=_0x3901d3)):_0x161915>_0x4c07cb&&(_0x161915=_0x4c07cb,-_0x4c2282+_0x1fcba0<0x0?_0x4387af=0x0:-_0x4c2282+_0x1fcba0>_0x3901d3?_0x4387af=_0x29c3d3:(_0x4387af=-_0x4c2282+_0x1fcba0,_0x29c3d3=_0x3901d3)),_0x168c31=Math['abs'](_0x4387af)<_0x128e9b['smallnum']?0x0:_0x4387af/_0x29c3d3,_0x486e51=Math['abs'](_0x161915)<_0x128e9b['smallnum']?0x0:_0x161915/_0x4c07cb;var _0x2e7cf1=_0x33cbf4['c']['Vector3'][0x4];_0x1d49ff['scaleToRef'](_0x486e51,_0x2e7cf1);var _0x370f63=_0x33cbf4['c']['Vector3'][0x5];_0x12abf8['scaleToRef'](_0x168c31,_0x370f63),_0x370f63['addInPlace'](_0x240cd5);var _0x49223a=_0x33cbf4['c']['Vector3'][0x6];return _0x370f63['subtractToRef'](_0x2e7cf1,_0x49223a),_0x486e51>0x0&&_0x486e51<=this['length']&&_0x49223a['lengthSquared']()<_0x28da4e*_0x28da4e?_0x370f63['length']():-0x1;},_0x128e9b['prototype']['update']=function(_0x1861da,_0x2fbb23,_0x138e09,_0x568675,_0x5d19ca,_0x1a9d14,_0x3d70ec){return this['unprojectRayToRef'](_0x1861da,_0x2fbb23,_0x138e09,_0x568675,_0x5d19ca,_0x1a9d14,_0x3d70ec),this;},_0x128e9b['Zero']=function(){return new _0x128e9b(_0x33cbf4['e']['Zero'](),_0x33cbf4['e']['Zero']());},_0x128e9b['CreateNew']=function(_0x38091e,_0xbefb84,_0x2bb797,_0x23a546,_0x332ee3,_0x461dbb,_0xc5b983){return _0x128e9b['Zero']()['update'](_0x38091e,_0xbefb84,_0x2bb797,_0x23a546,_0x332ee3,_0x461dbb,_0xc5b983);},_0x128e9b['CreateNewFromTo']=function(_0x1cf638,_0x144ede,_0x4d3e9c){void 0x0===_0x4d3e9c&&(_0x4d3e9c=_0x33cbf4['a']['IdentityReadOnly']);var _0x207f18=_0x144ede['subtract'](_0x1cf638),_0x1cee16=Math['sqrt'](_0x207f18['x']*_0x207f18['x']+_0x207f18['y']*_0x207f18['y']+_0x207f18['z']*_0x207f18['z']);return _0x207f18['normalize'](),_0x128e9b['Transform'](new _0x128e9b(_0x1cf638,_0x207f18,_0x1cee16),_0x4d3e9c);},_0x128e9b['Transform']=function(_0x540539,_0x1583c8){var _0x5c1757=new _0x128e9b(new _0x33cbf4['e'](0x0,0x0,0x0),new _0x33cbf4['e'](0x0,0x0,0x0));return _0x128e9b['TransformToRef'](_0x540539,_0x1583c8,_0x5c1757),_0x5c1757;},_0x128e9b['TransformToRef']=function(_0x112ee8,_0x5d0ea0,_0x5387f9){_0x33cbf4['e']['TransformCoordinatesToRef'](_0x112ee8['origin'],_0x5d0ea0,_0x5387f9['origin']),_0x33cbf4['e']['TransformNormalToRef'](_0x112ee8['direction'],_0x5d0ea0,_0x5387f9['direction']),_0x5387f9['length']=_0x112ee8['length'];var _0x4ecdc9=_0x5387f9['direction'],_0x4f2d87=_0x4ecdc9['length']();if(0x0!==_0x4f2d87&&0x1!==_0x4f2d87){var _0x4f3ce9=0x1/_0x4f2d87;_0x4ecdc9['x']*=_0x4f3ce9,_0x4ecdc9['y']*=_0x4f3ce9,_0x4ecdc9['z']*=_0x4f3ce9,_0x5387f9['length']*=_0x4f2d87;}},_0x128e9b['prototype']['unprojectRayToRef']=function(_0x4382e0,_0x52e290,_0x523eec,_0x1189d3,_0x515129,_0x137491,_0x2cb2b2){var _0x48b1bb=_0x33cbf4['c']['Matrix'][0x0];_0x515129['multiplyToRef'](_0x137491,_0x48b1bb),_0x48b1bb['multiplyToRef'](_0x2cb2b2,_0x48b1bb),_0x48b1bb['invert']();var _0x381b4c=_0x33cbf4['c']['Vector3'][0x0];_0x381b4c['x']=_0x4382e0/_0x523eec*0x2-0x1,_0x381b4c['y']=-(_0x52e290/_0x1189d3*0x2-0x1),_0x381b4c['z']=-0x1;var _0x14c580=_0x33cbf4['c']['Vector3'][0x1]['copyFromFloats'](_0x381b4c['x'],_0x381b4c['y'],0x1),_0x586f34=_0x33cbf4['c']['Vector3'][0x2],_0x7ff721=_0x33cbf4['c']['Vector3'][0x3];_0x33cbf4['e']['_UnprojectFromInvertedMatrixToRef'](_0x381b4c,_0x48b1bb,_0x586f34),_0x33cbf4['e']['_UnprojectFromInvertedMatrixToRef'](_0x14c580,_0x48b1bb,_0x7ff721),this['origin']['copyFrom'](_0x586f34),_0x7ff721['subtractToRef'](_0x586f34,this['direction']),this['direction']['normalize']();},_0x128e9b['_TmpVector3']=_0x9dc3db['a']['BuildArray'](0x6,_0x33cbf4['e']['Zero']),_0x128e9b['smallnum']=1e-8,_0x128e9b['rayl']=0x3b9aca00,_0x128e9b;}());_0x2975d1['a']['prototype']['createPickingRay']=function(_0x18d5c0,_0x414597,_0x385bd3,_0x3acbac,_0xc6c54f){void 0x0===_0xc6c54f&&(_0xc6c54f=!0x1);var _0x40edf4=_0x5aee8d['Zero']();return this['createPickingRayToRef'](_0x18d5c0,_0x414597,_0x385bd3,_0x40edf4,_0x3acbac,_0xc6c54f),_0x40edf4;},_0x2975d1['a']['prototype']['createPickingRayToRef']=function(_0x79a0da,_0x3cae3b,_0x269eaf,_0x52cc47,_0x339951,_0x455515){void 0x0===_0x455515&&(_0x455515=!0x1);var _0x281f81=this['getEngine']();if(!_0x339951){if(!this['activeCamera'])return this;_0x339951=this['activeCamera'];}var _0x474e36=_0x339951['viewport']['toGlobal'](_0x281f81['getRenderWidth'](),_0x281f81['getRenderHeight']());return _0x79a0da=_0x79a0da/_0x281f81['getHardwareScalingLevel']()-_0x474e36['x'],_0x3cae3b=_0x3cae3b/_0x281f81['getHardwareScalingLevel']()-(_0x281f81['getRenderHeight']()-_0x474e36['y']-_0x474e36['height']),_0x52cc47['update'](_0x79a0da,_0x3cae3b,_0x474e36['width'],_0x474e36['height'],_0x269eaf||_0x33cbf4['a']['IdentityReadOnly'],_0x455515?_0x33cbf4['a']['IdentityReadOnly']:_0x339951['getViewMatrix'](),_0x339951['getProjectionMatrix']()),this;},_0x2975d1['a']['prototype']['createPickingRayInCameraSpace']=function(_0x458c73,_0x19dbfb,_0x53ca3c){var _0x224502=_0x5aee8d['Zero']();return this['createPickingRayInCameraSpaceToRef'](_0x458c73,_0x19dbfb,_0x224502,_0x53ca3c),_0x224502;},_0x2975d1['a']['prototype']['createPickingRayInCameraSpaceToRef']=function(_0x30e9eb,_0x141732,_0x3270e1,_0x14b4e7){if(!_0x13e578['a'])return this;var _0x10fac0=this['getEngine']();if(!_0x14b4e7){if(!this['activeCamera'])throw new Error('Active\x20camera\x20not\x20set');_0x14b4e7=this['activeCamera'];}var _0x42c7e0=_0x14b4e7['viewport']['toGlobal'](_0x10fac0['getRenderWidth'](),_0x10fac0['getRenderHeight']()),_0x2911ab=_0x33cbf4['a']['Identity']();return _0x30e9eb=_0x30e9eb/_0x10fac0['getHardwareScalingLevel']()-_0x42c7e0['x'],_0x141732=_0x141732/_0x10fac0['getHardwareScalingLevel']()-(_0x10fac0['getRenderHeight']()-_0x42c7e0['y']-_0x42c7e0['height']),_0x3270e1['update'](_0x30e9eb,_0x141732,_0x42c7e0['width'],_0x42c7e0['height'],_0x2911ab,_0x2911ab,_0x14b4e7['getProjectionMatrix']()),this;},_0x2975d1['a']['prototype']['_internalPickForMesh']=function(_0xec1eba,_0x2aac3b,_0x299736,_0x724b19,_0x1e2201,_0x5da45f,_0x3364a4,_0x14b5f5){var _0x52ccf2=_0x2aac3b(_0x724b19),_0x31325e=_0x299736['intersects'](_0x52ccf2,_0x1e2201,_0x3364a4,_0x5da45f,_0x724b19,_0x14b5f5);return _0x31325e&&_0x31325e['hit']?!_0x1e2201&&null!=_0xec1eba&&_0x31325e['distance']>=_0xec1eba['distance']?null:_0x31325e:null;},_0x2975d1['a']['prototype']['_internalPick']=function(_0x52e15d,_0x37ccbb,_0x246a8f,_0x24e60b,_0x508286){if(!_0x13e578['a'])return null;for(var _0x52741f=null,_0x2761cc=0x0;_0x2761cc0x0&&(_0x143706['push'](_0x47be33-0x1),_0x143706['push'](_0x47be33)),_0x47be33++;}var _0x509886=new _0x552b55['a']();return _0x509886['indices']=_0x143706,_0x509886['positions']=_0x2a851b,_0x34b76e&&(_0x509886['colors']=_0x58b37d),_0x509886;},_0x552b55['a']['CreateDashedLines']=function(_0x2c6bf7){var _0x584bd2,_0x312244,_0x30f9f1=_0x2c6bf7['dashSize']||0x3,_0x2d3bca=_0x2c6bf7['gapSize']||0x1,_0x1b1795=_0x2c6bf7['dashNb']||0xc8,_0x4356c9=_0x2c6bf7['points'],_0x5cd4fc=new Array(),_0x1ff181=new Array(),_0x10faba=_0x9a06e0['e']['Zero'](),_0x463449=0x0,_0x4a90a2=0x0,_0x4cb8f1=0x0,_0x4cc25c=0x0,_0x39eb08=0x0;for(_0x39eb08=0x0;_0x39eb08<_0x4356c9['length']-0x1;_0x39eb08++)_0x4356c9[_0x39eb08+0x1]['subtractToRef'](_0x4356c9[_0x39eb08],_0x10faba),_0x463449+=_0x10faba['length']();for(_0x312244=_0x30f9f1*(_0x584bd2=_0x463449/_0x1b1795)/(_0x30f9f1+_0x2d3bca),_0x39eb08=0x0;_0x39eb08<_0x4356c9['length']-0x1;_0x39eb08++){_0x4356c9[_0x39eb08+0x1]['subtractToRef'](_0x4356c9[_0x39eb08],_0x10faba),_0x4a90a2=Math['floor'](_0x10faba['length']()/_0x584bd2),_0x10faba['normalize']();for(var _0x433cee=0x0;_0x433cee<_0x4a90a2;_0x433cee++)_0x4cb8f1=_0x584bd2*_0x433cee,_0x5cd4fc['push'](_0x4356c9[_0x39eb08]['x']+_0x4cb8f1*_0x10faba['x'],_0x4356c9[_0x39eb08]['y']+_0x4cb8f1*_0x10faba['y'],_0x4356c9[_0x39eb08]['z']+_0x4cb8f1*_0x10faba['z']),_0x5cd4fc['push'](_0x4356c9[_0x39eb08]['x']+(_0x4cb8f1+_0x312244)*_0x10faba['x'],_0x4356c9[_0x39eb08]['y']+(_0x4cb8f1+_0x312244)*_0x10faba['y'],_0x4356c9[_0x39eb08]['z']+(_0x4cb8f1+_0x312244)*_0x10faba['z']),_0x1ff181['push'](_0x4cc25c,_0x4cc25c+0x1),_0x4cc25c+=0x2;}var _0x44e78c=new _0x552b55['a']();return _0x44e78c['positions']=_0x5cd4fc,_0x44e78c['indices']=_0x1ff181,_0x44e78c;},_0x2a380c['a']['CreateLines']=function(_0x474c5a,_0x55084c,_0x32a5e5,_0x4f8ce4,_0x48f1b3){void 0x0===_0x32a5e5&&(_0x32a5e5=null),void 0x0===_0x4f8ce4&&(_0x4f8ce4=!0x1),void 0x0===_0x48f1b3&&(_0x48f1b3=null);var _0x63019d={'points':_0x55084c,'updatable':_0x4f8ce4,'instance':_0x48f1b3};return _0x25ddd2['CreateLines'](_0x474c5a,_0x63019d,_0x32a5e5);},_0x2a380c['a']['CreateDashedLines']=function(_0x1dd160,_0x1adfe6,_0x23d55e,_0x119f2b,_0xbe2023,_0x747e82,_0x4c46eb,_0x2ff33c){void 0x0===_0x747e82&&(_0x747e82=null);var _0x5ceaa3={'points':_0x1adfe6,'dashSize':_0x23d55e,'gapSize':_0x119f2b,'dashNb':_0xbe2023,'updatable':_0x4c46eb,'instance':_0x2ff33c};return _0x25ddd2['CreateDashedLines'](_0x1dd160,_0x5ceaa3,_0x747e82);};var _0x25ddd2=(function(){function _0x35b8df(){}return _0x35b8df['CreateLineSystem']=function(_0x4c86a0,_0x2b5518,_0xadacf7){var _0x58b1af=_0x2b5518['instance'],_0x43db93=_0x2b5518['lines'],_0x28baf2=_0x2b5518['colors'];if(_0x58b1af){var _0x6c64bc,_0x3f9fe2,_0x427da7=_0x58b1af['getVerticesData'](_0x150161['b']['PositionKind']);_0x28baf2&&(_0x6c64bc=_0x58b1af['getVerticesData'](_0x150161['b']['ColorKind']));for(var _0x47d059=0x0,_0x27ebae=0x0,_0x17e13e=0x0;_0x17e13e<_0x43db93['length'];_0x17e13e++)for(var _0x5e3035=_0x43db93[_0x17e13e],_0x556d6e=0x0;_0x556d6e<_0x5e3035['length'];_0x556d6e++)_0x427da7[_0x47d059]=_0x5e3035[_0x556d6e]['x'],_0x427da7[_0x47d059+0x1]=_0x5e3035[_0x556d6e]['y'],_0x427da7[_0x47d059+0x2]=_0x5e3035[_0x556d6e]['z'],_0x28baf2&&_0x6c64bc&&(_0x3f9fe2=_0x28baf2[_0x17e13e],_0x6c64bc[_0x27ebae]=_0x3f9fe2[_0x556d6e]['r'],_0x6c64bc[_0x27ebae+0x1]=_0x3f9fe2[_0x556d6e]['g'],_0x6c64bc[_0x27ebae+0x2]=_0x3f9fe2[_0x556d6e]['b'],_0x6c64bc[_0x27ebae+0x3]=_0x3f9fe2[_0x556d6e]['a'],_0x27ebae+=0x4),_0x47d059+=0x3;return _0x58b1af['updateVerticesData'](_0x150161['b']['PositionKind'],_0x427da7,!0x1,!0x1),_0x28baf2&&_0x6c64bc&&_0x58b1af['updateVerticesData'](_0x150161['b']['ColorKind'],_0x6c64bc,!0x1,!0x1),_0x58b1af;}var _0x1afd52=!!_0x28baf2,_0x35fb89=new _0x4a239c['b'](_0x4c86a0,_0xadacf7,null,void 0x0,void 0x0,_0x1afd52,_0x2b5518['useVertexAlpha']);return _0x552b55['a']['CreateLineSystem'](_0x2b5518)['applyToMesh'](_0x35fb89,_0x2b5518['updatable']),_0x35fb89;},_0x35b8df['CreateLines']=function(_0x2172ba,_0x14b372,_0x185c4c){void 0x0===_0x185c4c&&(_0x185c4c=null);var _0x18eece=_0x14b372['colors']?[_0x14b372['colors']]:null;return _0x35b8df['CreateLineSystem'](_0x2172ba,{'lines':[_0x14b372['points']],'updatable':_0x14b372['updatable'],'instance':_0x14b372['instance'],'colors':_0x18eece,'useVertexAlpha':_0x14b372['useVertexAlpha']},_0x185c4c);},_0x35b8df['CreateDashedLines']=function(_0x127453,_0x152365,_0x264800){void 0x0===_0x264800&&(_0x264800=null);var _0x10d50e=_0x152365['points'],_0x3570f0=_0x152365['instance'],_0x2ba58f=_0x152365['gapSize']||0x1,_0x2657ee=_0x152365['dashSize']||0x3;if(_0x3570f0)return _0x3570f0['updateMeshPositions'](function(_0x191614){var _0x5526b9,_0xd8b776,_0x52b77d=_0x9a06e0['e']['Zero'](),_0x55c29d=_0x191614['length']/0x6,_0x19d78c=0x0,_0x524406=0x0,_0x15de2f=0x0,_0x30120f=0x0,_0x4af0d5=0x0,_0x1e0924=0x0;for(_0x4af0d5=0x0;_0x4af0d5<_0x10d50e['length']-0x1;_0x4af0d5++)_0x10d50e[_0x4af0d5+0x1]['subtractToRef'](_0x10d50e[_0x4af0d5],_0x52b77d),_0x19d78c+=_0x52b77d['length']();_0x5526b9=_0x19d78c/_0x55c29d;var _0x20004e=_0x3570f0['_creationDataStorage']['dashSize'];for(_0xd8b776=_0x20004e*_0x5526b9/(_0x20004e+_0x3570f0['_creationDataStorage']['gapSize']),_0x4af0d5=0x0;_0x4af0d5<_0x10d50e['length']-0x1;_0x4af0d5++)for(_0x10d50e[_0x4af0d5+0x1]['subtractToRef'](_0x10d50e[_0x4af0d5],_0x52b77d),_0x524406=Math['floor'](_0x52b77d['length']()/_0x5526b9),_0x52b77d['normalize'](),_0x1e0924=0x0;_0x1e0924<_0x524406&&_0x30120f<_0x191614['length'];)_0x15de2f=_0x5526b9*_0x1e0924,_0x191614[_0x30120f]=_0x10d50e[_0x4af0d5]['x']+_0x15de2f*_0x52b77d['x'],_0x191614[_0x30120f+0x1]=_0x10d50e[_0x4af0d5]['y']+_0x15de2f*_0x52b77d['y'],_0x191614[_0x30120f+0x2]=_0x10d50e[_0x4af0d5]['z']+_0x15de2f*_0x52b77d['z'],_0x191614[_0x30120f+0x3]=_0x10d50e[_0x4af0d5]['x']+(_0x15de2f+_0xd8b776)*_0x52b77d['x'],_0x191614[_0x30120f+0x4]=_0x10d50e[_0x4af0d5]['y']+(_0x15de2f+_0xd8b776)*_0x52b77d['y'],_0x191614[_0x30120f+0x5]=_0x10d50e[_0x4af0d5]['z']+(_0x15de2f+_0xd8b776)*_0x52b77d['z'],_0x30120f+=0x6,_0x1e0924++;for(;_0x30120f<_0x191614['length'];)_0x191614[_0x30120f]=_0x10d50e[_0x4af0d5]['x'],_0x191614[_0x30120f+0x1]=_0x10d50e[_0x4af0d5]['y'],_0x191614[_0x30120f+0x2]=_0x10d50e[_0x4af0d5]['z'],_0x30120f+=0x3;},!0x1),_0x3570f0;var _0xb2ce07=new _0x4a239c['b'](_0x127453,_0x264800,null,void 0x0,void 0x0,void 0x0,_0x152365['useVertexAlpha']);return _0x552b55['a']['CreateDashedLines'](_0x152365)['applyToMesh'](_0xb2ce07,_0x152365['updatable']),_0xb2ce07['_creationDataStorage']=new _0x2a380c['b'](),_0xb2ce07['_creationDataStorage']['dashSize']=_0x2657ee,_0xb2ce07['_creationDataStorage']['gapSize']=_0x2ba58f,_0xb2ce07;},_0x35b8df;}());},function(_0xe1023d,_0x23f069,_0x34c77e){'use strict';_0x34c77e['d'](_0x23f069,'a',function(){return _0x2aeb91;});var _0x36b9a3=_0x34c77e(0x22),_0x48b39f=_0x34c77e(0x8),_0x36610b=function(_0x425a65,_0x3a0a17){return _0x425a65?_0x425a65['getClassName']&&'Mesh'===_0x425a65['getClassName']()?null:_0x425a65['getClassName']&&'SubMesh'===_0x425a65['getClassName']()?_0x425a65['clone'](_0x3a0a17):_0x425a65['clone']?_0x425a65['clone']():null:null;},_0x2aeb91=(function(){function _0x569ab4(){}return _0x569ab4['DeepCopy']=function(_0xc87a25,_0x4e3a91,_0x48e25d,_0x25dc56){for(var _0x2a6fab=0x0,_0x17125d=function(_0x3ec824){var _0xfb4cc2=[];do{Object['getOwnPropertyNames'](_0x3ec824)['forEach'](function(_0x10d082){-0x1===_0xfb4cc2['indexOf'](_0x10d082)&&_0xfb4cc2['push'](_0x10d082);});}while(_0x3ec824=Object['getPrototypeOf'](_0x3ec824));return _0xfb4cc2;}(_0xc87a25);_0x2a6fab<_0x17125d['length'];_0x2a6fab++){var _0x1cda50=_0x17125d[_0x2a6fab];if(('_'!==_0x1cda50[0x0]||_0x25dc56&&-0x1!==_0x25dc56['indexOf'](_0x1cda50))&&!(_0x36b9a3['a']['EndsWith'](_0x1cda50,'Observable')||_0x48e25d&&-0x1!==_0x48e25d['indexOf'](_0x1cda50))){var _0xea0651=_0xc87a25[_0x1cda50],_0x1d54a8=typeof _0xea0651;if('function'!==_0x1d54a8)try{if('object'===_0x1d54a8){if(_0xea0651 instanceof Array){if(_0x4e3a91[_0x1cda50]=[],_0xea0651['length']>0x0){if('object'==typeof _0xea0651[0x0])for(var _0x14507f=0x0;_0x14507f<_0xea0651['length'];_0x14507f++){var _0x93c78f=_0x36610b(_0xea0651[_0x14507f],_0x4e3a91);-0x1===_0x4e3a91[_0x1cda50]['indexOf'](_0x93c78f)&&_0x4e3a91[_0x1cda50]['push'](_0x93c78f);}else _0x4e3a91[_0x1cda50]=_0xea0651['slice'](0x0);}}else _0x4e3a91[_0x1cda50]=_0x36610b(_0xea0651,_0x4e3a91);}else _0x4e3a91[_0x1cda50]=_0xea0651;}catch(_0x3479fa){_0x48b39f['a']['Warn'](_0x3479fa['message']);}}}},_0x569ab4;}());},function(_0x1b8532,_0x5e8787,_0x3a9108){'use strict';_0x3a9108['d'](_0x5e8787,'b',function(){return _0x5b0fa1;}),_0x3a9108['d'](_0x5e8787,'a',function(){return _0x5df820;});var _0x1bac69=_0x3a9108(0x1),_0x12df64=_0x3a9108(0x3),_0x462abb=_0x3a9108(0x6),_0x369934=_0x3a9108(0xc),_0x47ddb3=_0x3a9108(0x9),_0xabb331=_0x3a9108(0x4c),_0x36b088=_0x3a9108(0x79),_0x5b0fa1=function(_0x2ff71a){function _0x198bd2(){var _0x143391=_0x2ff71a['call'](this)||this;return _0x143391['IMAGEPROCESSING']=!0x1,_0x143391['VIGNETTE']=!0x1,_0x143391['VIGNETTEBLENDMODEMULTIPLY']=!0x1,_0x143391['VIGNETTEBLENDMODEOPAQUE']=!0x1,_0x143391['TONEMAPPING']=!0x1,_0x143391['TONEMAPPING_ACES']=!0x1,_0x143391['CONTRAST']=!0x1,_0x143391['COLORCURVES']=!0x1,_0x143391['COLORGRADING']=!0x1,_0x143391['COLORGRADING3D']=!0x1,_0x143391['SAMPLER3DGREENDEPTH']=!0x1,_0x143391['SAMPLER3DBGRMAP']=!0x1,_0x143391['IMAGEPROCESSINGPOSTPROCESS']=!0x1,_0x143391['EXPOSURE']=!0x1,_0x143391['rebuild'](),_0x143391;}return Object(_0x1bac69['d'])(_0x198bd2,_0x2ff71a),_0x198bd2;}(_0xabb331['a']),_0x5df820=(function(){function _0x174761(){this['colorCurves']=new _0x36b088['a'](),this['_colorCurvesEnabled']=!0x1,this['_colorGradingEnabled']=!0x1,this['_colorGradingWithGreenDepth']=!0x0,this['_colorGradingBGR']=!0x0,this['_exposure']=0x1,this['_toneMappingEnabled']=!0x1,this['_toneMappingType']=_0x174761['TONEMAPPING_STANDARD'],this['_contrast']=0x1,this['vignetteStretch']=0x0,this['vignetteCentreX']=0x0,this['vignetteCentreY']=0x0,this['vignetteWeight']=1.5,this['vignetteColor']=new _0x47ddb3['b'](0x0,0x0,0x0,0x0),this['vignetteCameraFov']=0.5,this['_vignetteBlendMode']=_0x174761['VIGNETTEMODE_MULTIPLY'],this['_vignetteEnabled']=!0x1,this['_applyByPostProcess']=!0x1,this['_isEnabled']=!0x0,this['onUpdateParameters']=new _0x462abb['c']();}return Object['defineProperty'](_0x174761['prototype'],'colorCurvesEnabled',{'get':function(){return this['_colorCurvesEnabled'];},'set':function(_0x29e96b){this['_colorCurvesEnabled']!==_0x29e96b&&(this['_colorCurvesEnabled']=_0x29e96b,this['_updateParameters']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x174761['prototype'],'colorGradingTexture',{'get':function(){return this['_colorGradingTexture'];},'set':function(_0x88f716){this['_colorGradingTexture']!==_0x88f716&&(this['_colorGradingTexture']=_0x88f716,this['_updateParameters']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x174761['prototype'],'colorGradingEnabled',{'get':function(){return this['_colorGradingEnabled'];},'set':function(_0x44af95){this['_colorGradingEnabled']!==_0x44af95&&(this['_colorGradingEnabled']=_0x44af95,this['_updateParameters']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x174761['prototype'],'colorGradingWithGreenDepth',{'get':function(){return this['_colorGradingWithGreenDepth'];},'set':function(_0x162f73){this['_colorGradingWithGreenDepth']!==_0x162f73&&(this['_colorGradingWithGreenDepth']=_0x162f73,this['_updateParameters']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x174761['prototype'],'colorGradingBGR',{'get':function(){return this['_colorGradingBGR'];},'set':function(_0x27f18a){this['_colorGradingBGR']!==_0x27f18a&&(this['_colorGradingBGR']=_0x27f18a,this['_updateParameters']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x174761['prototype'],'exposure',{'get':function(){return this['_exposure'];},'set':function(_0x4e06f5){this['_exposure']!==_0x4e06f5&&(this['_exposure']=_0x4e06f5,this['_updateParameters']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x174761['prototype'],'toneMappingEnabled',{'get':function(){return this['_toneMappingEnabled'];},'set':function(_0xb1b1b3){this['_toneMappingEnabled']!==_0xb1b1b3&&(this['_toneMappingEnabled']=_0xb1b1b3,this['_updateParameters']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x174761['prototype'],'toneMappingType',{'get':function(){return this['_toneMappingType'];},'set':function(_0x281689){this['_toneMappingType']!==_0x281689&&(this['_toneMappingType']=_0x281689,this['_updateParameters']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x174761['prototype'],'contrast',{'get':function(){return this['_contrast'];},'set':function(_0x5dca5e){this['_contrast']!==_0x5dca5e&&(this['_contrast']=_0x5dca5e,this['_updateParameters']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x174761['prototype'],'vignetteBlendMode',{'get':function(){return this['_vignetteBlendMode'];},'set':function(_0x392ce7){this['_vignetteBlendMode']!==_0x392ce7&&(this['_vignetteBlendMode']=_0x392ce7,this['_updateParameters']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x174761['prototype'],'vignetteEnabled',{'get':function(){return this['_vignetteEnabled'];},'set':function(_0x237a05){this['_vignetteEnabled']!==_0x237a05&&(this['_vignetteEnabled']=_0x237a05,this['_updateParameters']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x174761['prototype'],'applyByPostProcess',{'get':function(){return this['_applyByPostProcess'];},'set':function(_0x88fa1b){this['_applyByPostProcess']!==_0x88fa1b&&(this['_applyByPostProcess']=_0x88fa1b,this['_updateParameters']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x174761['prototype'],'isEnabled',{'get':function(){return this['_isEnabled'];},'set':function(_0x2a9191){this['_isEnabled']!==_0x2a9191&&(this['_isEnabled']=_0x2a9191,this['_updateParameters']());},'enumerable':!0x1,'configurable':!0x0}),_0x174761['prototype']['_updateParameters']=function(){this['onUpdateParameters']['notifyObservers'](this);},_0x174761['prototype']['getClassName']=function(){return'ImageProcessingConfiguration';},_0x174761['PrepareUniforms']=function(_0x405216,_0x4d87de){_0x4d87de['EXPOSURE']&&_0x405216['push']('exposureLinear'),_0x4d87de['CONTRAST']&&_0x405216['push']('contrast'),_0x4d87de['COLORGRADING']&&_0x405216['push']('colorTransformSettings'),_0x4d87de['VIGNETTE']&&(_0x405216['push']('vInverseScreenSize'),_0x405216['push']('vignetteSettings1'),_0x405216['push']('vignetteSettings2')),_0x4d87de['COLORCURVES']&&_0x36b088['a']['PrepareUniforms'](_0x405216);},_0x174761['PrepareSamplers']=function(_0x3706d4,_0xe8f150){_0xe8f150['COLORGRADING']&&_0x3706d4['push']('txColorTransform');},_0x174761['prototype']['prepareDefines']=function(_0x1ff736,_0x52360b){if(void 0x0===_0x52360b&&(_0x52360b=!0x1),_0x52360b!==this['applyByPostProcess']||!this['_isEnabled'])return _0x1ff736['VIGNETTE']=!0x1,_0x1ff736['TONEMAPPING']=!0x1,_0x1ff736['TONEMAPPING_ACES']=!0x1,_0x1ff736['CONTRAST']=!0x1,_0x1ff736['EXPOSURE']=!0x1,_0x1ff736['COLORCURVES']=!0x1,_0x1ff736['COLORGRADING']=!0x1,_0x1ff736['COLORGRADING3D']=!0x1,_0x1ff736['IMAGEPROCESSING']=!0x1,void(_0x1ff736['IMAGEPROCESSINGPOSTPROCESS']=this['applyByPostProcess']&&this['_isEnabled']);switch(_0x1ff736['VIGNETTE']=this['vignetteEnabled'],_0x1ff736['VIGNETTEBLENDMODEMULTIPLY']=this['vignetteBlendMode']===_0x174761['_VIGNETTEMODE_MULTIPLY'],_0x1ff736['VIGNETTEBLENDMODEOPAQUE']=!_0x1ff736['VIGNETTEBLENDMODEMULTIPLY'],_0x1ff736['TONEMAPPING']=this['toneMappingEnabled'],this['_toneMappingType']){case _0x174761['TONEMAPPING_ACES']:_0x1ff736['TONEMAPPING_ACES']=!0x0;break;default:_0x1ff736['TONEMAPPING_ACES']=!0x1;}_0x1ff736['CONTRAST']=0x1!==this['contrast'],_0x1ff736['EXPOSURE']=0x1!==this['exposure'],_0x1ff736['COLORCURVES']=this['colorCurvesEnabled']&&!!this['colorCurves'],_0x1ff736['COLORGRADING']=this['colorGradingEnabled']&&!!this['colorGradingTexture'],_0x1ff736['COLORGRADING']?_0x1ff736['COLORGRADING3D']=this['colorGradingTexture']['is3D']:_0x1ff736['COLORGRADING3D']=!0x1,_0x1ff736['SAMPLER3DGREENDEPTH']=this['colorGradingWithGreenDepth'],_0x1ff736['SAMPLER3DBGRMAP']=this['colorGradingBGR'],_0x1ff736['IMAGEPROCESSINGPOSTPROCESS']=this['applyByPostProcess'],_0x1ff736['IMAGEPROCESSING']=_0x1ff736['VIGNETTE']||_0x1ff736['TONEMAPPING']||_0x1ff736['CONTRAST']||_0x1ff736['EXPOSURE']||_0x1ff736['COLORCURVES']||_0x1ff736['COLORGRADING'];},_0x174761['prototype']['isReady']=function(){return!this['colorGradingEnabled']||!this['colorGradingTexture']||this['colorGradingTexture']['isReady']();},_0x174761['prototype']['bind']=function(_0x5b42c7,_0x3ba9a0){if(this['_colorCurvesEnabled']&&this['colorCurves']&&_0x36b088['a']['Bind'](this['colorCurves'],_0x5b42c7),this['_vignetteEnabled']){var _0x44280f=0x1/_0x5b42c7['getEngine']()['getRenderWidth'](),_0x1e4a26=0x1/_0x5b42c7['getEngine']()['getRenderHeight']();_0x5b42c7['setFloat2']('vInverseScreenSize',_0x44280f,_0x1e4a26);var _0x278317=null!=_0x3ba9a0?_0x3ba9a0:_0x1e4a26/_0x44280f,_0x26a164=Math['tan'](0.5*this['vignetteCameraFov']),_0x2acc68=_0x26a164*_0x278317,_0x318f6c=Math['sqrt'](_0x2acc68*_0x26a164);_0x2acc68=_0x369934['b']['Mix'](_0x2acc68,_0x318f6c,this['vignetteStretch']),_0x26a164=_0x369934['b']['Mix'](_0x26a164,_0x318f6c,this['vignetteStretch']),_0x5b42c7['setFloat4']('vignetteSettings1',_0x2acc68,_0x26a164,-_0x2acc68*this['vignetteCentreX'],-_0x26a164*this['vignetteCentreY']);var _0x2358cf=-0x2*this['vignetteWeight'];_0x5b42c7['setFloat4']('vignetteSettings2',this['vignetteColor']['r'],this['vignetteColor']['g'],this['vignetteColor']['b'],_0x2358cf);}if(_0x5b42c7['setFloat']('exposureLinear',this['exposure']),_0x5b42c7['setFloat']('contrast',this['contrast']),this['colorGradingTexture']){_0x5b42c7['setTexture']('txColorTransform',this['colorGradingTexture']);var _0x1edbac=this['colorGradingTexture']['getSize']()['height'];_0x5b42c7['setFloat4']('colorTransformSettings',(_0x1edbac-0x1)/_0x1edbac,0.5/_0x1edbac,_0x1edbac,this['colorGradingTexture']['level']);}},_0x174761['prototype']['clone']=function(){return _0x12df64['a']['Clone'](function(){return new _0x174761();},this);},_0x174761['prototype']['serialize']=function(){return _0x12df64['a']['Serialize'](this);},_0x174761['Parse']=function(_0x376855){return _0x12df64['a']['Parse'](function(){return new _0x174761();},_0x376855,null,null);},Object['defineProperty'](_0x174761,'VIGNETTEMODE_MULTIPLY',{'get':function(){return this['_VIGNETTEMODE_MULTIPLY'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x174761,'VIGNETTEMODE_OPAQUE',{'get':function(){return this['_VIGNETTEMODE_OPAQUE'];},'enumerable':!0x1,'configurable':!0x0}),_0x174761['TONEMAPPING_STANDARD']=0x0,_0x174761['TONEMAPPING_ACES']=0x1,_0x174761['_VIGNETTEMODE_MULTIPLY']=0x0,_0x174761['_VIGNETTEMODE_OPAQUE']=0x1,Object(_0x1bac69['c'])([Object(_0x12df64['g'])()],_0x174761['prototype'],'colorCurves',void 0x0),Object(_0x1bac69['c'])([Object(_0x12df64['c'])()],_0x174761['prototype'],'_colorCurvesEnabled',void 0x0),Object(_0x1bac69['c'])([Object(_0x12df64['m'])('colorGradingTexture')],_0x174761['prototype'],'_colorGradingTexture',void 0x0),Object(_0x1bac69['c'])([Object(_0x12df64['c'])()],_0x174761['prototype'],'_colorGradingEnabled',void 0x0),Object(_0x1bac69['c'])([Object(_0x12df64['c'])()],_0x174761['prototype'],'_colorGradingWithGreenDepth',void 0x0),Object(_0x1bac69['c'])([Object(_0x12df64['c'])()],_0x174761['prototype'],'_colorGradingBGR',void 0x0),Object(_0x1bac69['c'])([Object(_0x12df64['c'])()],_0x174761['prototype'],'_exposure',void 0x0),Object(_0x1bac69['c'])([Object(_0x12df64['c'])()],_0x174761['prototype'],'_toneMappingEnabled',void 0x0),Object(_0x1bac69['c'])([Object(_0x12df64['c'])()],_0x174761['prototype'],'_toneMappingType',void 0x0),Object(_0x1bac69['c'])([Object(_0x12df64['c'])()],_0x174761['prototype'],'_contrast',void 0x0),Object(_0x1bac69['c'])([Object(_0x12df64['c'])()],_0x174761['prototype'],'vignetteStretch',void 0x0),Object(_0x1bac69['c'])([Object(_0x12df64['c'])()],_0x174761['prototype'],'vignetteCentreX',void 0x0),Object(_0x1bac69['c'])([Object(_0x12df64['c'])()],_0x174761['prototype'],'vignetteCentreY',void 0x0),Object(_0x1bac69['c'])([Object(_0x12df64['c'])()],_0x174761['prototype'],'vignetteWeight',void 0x0),Object(_0x1bac69['c'])([Object(_0x12df64['f'])()],_0x174761['prototype'],'vignetteColor',void 0x0),Object(_0x1bac69['c'])([Object(_0x12df64['c'])()],_0x174761['prototype'],'vignetteCameraFov',void 0x0),Object(_0x1bac69['c'])([Object(_0x12df64['c'])()],_0x174761['prototype'],'_vignetteBlendMode',void 0x0),Object(_0x1bac69['c'])([Object(_0x12df64['c'])()],_0x174761['prototype'],'_vignetteEnabled',void 0x0),Object(_0x1bac69['c'])([Object(_0x12df64['c'])()],_0x174761['prototype'],'_applyByPostProcess',void 0x0),Object(_0x1bac69['c'])([Object(_0x12df64['c'])()],_0x174761['prototype'],'_isEnabled',void 0x0),_0x174761;}());_0x12df64['a']['_ImageProcessingConfigurationParser']=_0x5df820['Parse'];},function(_0x1a5f24,_0x450f49,_0x3c8796){'use strict';_0x3c8796['d'](_0x450f49,'a',function(){return _0x15a121;});var _0x50da90=_0x3c8796(0x2c),_0x199170=_0x3c8796(0x0),_0x33cd88=_0x3c8796(0x2),_0x263e21=_0x3c8796(0x67),_0x1afad8=_0x3c8796(0x71),_0x4cc184={'min':0x0,'max':0x0},_0xb26a5e={'min':0x0,'max':0x0},_0x3c3b89=function(_0x102251,_0x3e82a7,_0x345121){var _0x572412=_0x199170['e']['Dot'](_0x3e82a7['centerWorld'],_0x102251),_0x137941=Math['abs'](_0x199170['e']['Dot'](_0x3e82a7['directions'][0x0],_0x102251))*_0x3e82a7['extendSize']['x']+Math['abs'](_0x199170['e']['Dot'](_0x3e82a7['directions'][0x1],_0x102251))*_0x3e82a7['extendSize']['y']+Math['abs'](_0x199170['e']['Dot'](_0x3e82a7['directions'][0x2],_0x102251))*_0x3e82a7['extendSize']['z'];_0x345121['min']=_0x572412-_0x137941,_0x345121['max']=_0x572412+_0x137941;},_0x35866a=function(_0x3bafea,_0x5b9f5a,_0xa7bcb4){return _0x3c3b89(_0x3bafea,_0x5b9f5a,_0x4cc184),_0x3c3b89(_0x3bafea,_0xa7bcb4,_0xb26a5e),!(_0x4cc184['min']>_0xb26a5e['max']||_0xb26a5e['min']>_0x4cc184['max']);},_0x15a121=(function(){function _0x47e66d(_0x5d583f,_0x227eff,_0x49bf94){this['_isLocked']=!0x1,this['boundingBox']=new _0x263e21['a'](_0x5d583f,_0x227eff,_0x49bf94),this['boundingSphere']=new _0x1afad8['a'](_0x5d583f,_0x227eff,_0x49bf94);}return _0x47e66d['prototype']['reConstruct']=function(_0x3f5354,_0x325b50,_0xd88fef){this['boundingBox']['reConstruct'](_0x3f5354,_0x325b50,_0xd88fef),this['boundingSphere']['reConstruct'](_0x3f5354,_0x325b50,_0xd88fef);},Object['defineProperty'](_0x47e66d['prototype'],'minimum',{'get':function(){return this['boundingBox']['minimum'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x47e66d['prototype'],'maximum',{'get':function(){return this['boundingBox']['maximum'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x47e66d['prototype'],'isLocked',{'get':function(){return this['_isLocked'];},'set':function(_0x34f03d){this['_isLocked']=_0x34f03d;},'enumerable':!0x1,'configurable':!0x0}),_0x47e66d['prototype']['update']=function(_0x1c634a){this['_isLocked']||(this['boundingBox']['_update'](_0x1c634a),this['boundingSphere']['_update'](_0x1c634a));},_0x47e66d['prototype']['centerOn']=function(_0x18922f,_0x3636ec){var _0x18ea07=_0x47e66d['TmpVector3'][0x0]['copyFrom'](_0x18922f)['subtractInPlace'](_0x3636ec),_0x58548f=_0x47e66d['TmpVector3'][0x1]['copyFrom'](_0x18922f)['addInPlace'](_0x3636ec);return this['boundingBox']['reConstruct'](_0x18ea07,_0x58548f,this['boundingBox']['getWorldMatrix']()),this['boundingSphere']['reConstruct'](_0x18ea07,_0x58548f,this['boundingBox']['getWorldMatrix']()),this;},_0x47e66d['prototype']['scale']=function(_0x2d0815){return this['boundingBox']['scale'](_0x2d0815),this['boundingSphere']['scale'](_0x2d0815),this;},_0x47e66d['prototype']['isInFrustum']=function(_0x16a3a9,_0x1ec994){return void 0x0===_0x1ec994&&(_0x1ec994=_0x33cd88['a']['MESHES_CULLINGSTRATEGY_STANDARD']),!(_0x1ec994!==_0x33cd88['a']['MESHES_CULLINGSTRATEGY_OPTIMISTIC_INCLUSION']&&_0x1ec994!==_0x33cd88['a']['MESHES_CULLINGSTRATEGY_OPTIMISTIC_INCLUSION_THEN_BSPHERE_ONLY']||!this['boundingSphere']['isCenterInFrustum'](_0x16a3a9))||!!this['boundingSphere']['isInFrustum'](_0x16a3a9)&&(!(_0x1ec994!==_0x33cd88['a']['MESHES_CULLINGSTRATEGY_BOUNDINGSPHERE_ONLY']&&_0x1ec994!==_0x33cd88['a']['MESHES_CULLINGSTRATEGY_OPTIMISTIC_INCLUSION_THEN_BSPHERE_ONLY'])||this['boundingBox']['isInFrustum'](_0x16a3a9));},Object['defineProperty'](_0x47e66d['prototype'],'diagonalLength',{'get':function(){var _0x166ac1=this['boundingBox'];return _0x166ac1['maximumWorld']['subtractToRef'](_0x166ac1['minimumWorld'],_0x47e66d['TmpVector3'][0x0])['length']();},'enumerable':!0x1,'configurable':!0x0}),_0x47e66d['prototype']['isCompletelyInFrustum']=function(_0x2072cd){return this['boundingBox']['isCompletelyInFrustum'](_0x2072cd);},_0x47e66d['prototype']['_checkCollision']=function(_0x372438){return _0x372438['_canDoCollision'](this['boundingSphere']['centerWorld'],this['boundingSphere']['radiusWorld'],this['boundingBox']['minimumWorld'],this['boundingBox']['maximumWorld']);},_0x47e66d['prototype']['intersectsPoint']=function(_0x1ff97c){return!!this['boundingSphere']['centerWorld']&&(!!this['boundingSphere']['intersectsPoint'](_0x1ff97c)&&!!this['boundingBox']['intersectsPoint'](_0x1ff97c));},_0x47e66d['prototype']['intersects']=function(_0x13a4fc,_0xced75f){if(!_0x1afad8['a']['Intersects'](this['boundingSphere'],_0x13a4fc['boundingSphere']))return!0x1;if(!_0x263e21['a']['Intersects'](this['boundingBox'],_0x13a4fc['boundingBox']))return!0x1;if(!_0xced75f)return!0x0;var _0x494ce0=this['boundingBox'],_0x38f8f6=_0x13a4fc['boundingBox'];return!!_0x35866a(_0x494ce0['directions'][0x0],_0x494ce0,_0x38f8f6)&&(!!_0x35866a(_0x494ce0['directions'][0x1],_0x494ce0,_0x38f8f6)&&(!!_0x35866a(_0x494ce0['directions'][0x2],_0x494ce0,_0x38f8f6)&&(!!_0x35866a(_0x38f8f6['directions'][0x0],_0x494ce0,_0x38f8f6)&&(!!_0x35866a(_0x38f8f6['directions'][0x1],_0x494ce0,_0x38f8f6)&&(!!_0x35866a(_0x38f8f6['directions'][0x2],_0x494ce0,_0x38f8f6)&&(!!_0x35866a(_0x199170['e']['Cross'](_0x494ce0['directions'][0x0],_0x38f8f6['directions'][0x0]),_0x494ce0,_0x38f8f6)&&(!!_0x35866a(_0x199170['e']['Cross'](_0x494ce0['directions'][0x0],_0x38f8f6['directions'][0x1]),_0x494ce0,_0x38f8f6)&&(!!_0x35866a(_0x199170['e']['Cross'](_0x494ce0['directions'][0x0],_0x38f8f6['directions'][0x2]),_0x494ce0,_0x38f8f6)&&(!!_0x35866a(_0x199170['e']['Cross'](_0x494ce0['directions'][0x1],_0x38f8f6['directions'][0x0]),_0x494ce0,_0x38f8f6)&&(!!_0x35866a(_0x199170['e']['Cross'](_0x494ce0['directions'][0x1],_0x38f8f6['directions'][0x1]),_0x494ce0,_0x38f8f6)&&(!!_0x35866a(_0x199170['e']['Cross'](_0x494ce0['directions'][0x1],_0x38f8f6['directions'][0x2]),_0x494ce0,_0x38f8f6)&&(!!_0x35866a(_0x199170['e']['Cross'](_0x494ce0['directions'][0x2],_0x38f8f6['directions'][0x0]),_0x494ce0,_0x38f8f6)&&(!!_0x35866a(_0x199170['e']['Cross'](_0x494ce0['directions'][0x2],_0x38f8f6['directions'][0x1]),_0x494ce0,_0x38f8f6)&&!!_0x35866a(_0x199170['e']['Cross'](_0x494ce0['directions'][0x2],_0x38f8f6['directions'][0x2]),_0x494ce0,_0x38f8f6))))))))))))));},_0x47e66d['TmpVector3']=_0x50da90['a']['BuildArray'](0x2,_0x199170['e']['Zero']),_0x47e66d;}());},function(_0x5719cd,_0x55366e,_0x14d3cf){'use strict';_0x14d3cf['d'](_0x55366e,'a',function(){return _0x3f4ad3;});var _0x3f4ad3=(function(){function _0x6fa65e(){}return _0x6fa65e['BuildArray']=function(_0x478f30,_0x170324){for(var _0x48143b=[],_0x2d03c2=0x0;_0x2d03c2<_0x478f30;++_0x2d03c2)_0x48143b['push'](_0x170324());return _0x48143b;},_0x6fa65e;}());},function(_0x50fd9d,_0x42915,_0x297114){'use strict';_0x297114['d'](_0x42915,'a',function(){return _0x323cb0;});var _0x1d52c4=_0x297114(0x0),_0x374b95=_0x297114(0x7),_0x22e086=_0x297114(0x10);_0x22e086['a']['CreateSphere']=function(_0x5943bf){for(var _0x23fbd3=_0x5943bf['segments']||0x20,_0x1a7956=_0x5943bf['diameterX']||_0x5943bf['diameter']||0x1,_0xfa6992=_0x5943bf['diameterY']||_0x5943bf['diameter']||0x1,_0x2fe9cb=_0x5943bf['diameterZ']||_0x5943bf['diameter']||0x1,_0x18f8e6=_0x5943bf['arc']&&(_0x5943bf['arc']<=0x0||_0x5943bf['arc']>0x1)?0x1:_0x5943bf['arc']||0x1,_0x1ca550=_0x5943bf['slice']&&_0x5943bf['slice']<=0x0?0x1:_0x5943bf['slice']||0x1,_0x19acd8=0x0===_0x5943bf['sideOrientation']?0x0:_0x5943bf['sideOrientation']||_0x22e086['a']['DEFAULTSIDE'],_0x296a62=!!_0x5943bf['dedupTopBottomIndices'],_0xcdfe73=new _0x1d52c4['e'](_0x1a7956/0x2,_0xfa6992/0x2,_0x2fe9cb/0x2),_0x49a960=0x2+_0x23fbd3,_0x79ac7c=0x2*_0x49a960,_0x442d57=[],_0xd9bf21=[],_0x55969a=[],_0x247037=[],_0x421df4=0x0;_0x421df4<=_0x49a960;_0x421df4++){for(var _0x59cf64=_0x421df4/_0x49a960,_0x220cec=_0x59cf64*Math['PI']*_0x1ca550,_0x4fce37=0x0;_0x4fce37<=_0x79ac7c;_0x4fce37++){var _0x18de3e=_0x4fce37/_0x79ac7c,_0x42e03e=_0x18de3e*Math['PI']*0x2*_0x18f8e6,_0x20f612=_0x1d52c4['a']['RotationZ'](-_0x220cec),_0x3748b5=_0x1d52c4['a']['RotationY'](_0x42e03e),_0x169a33=_0x1d52c4['e']['TransformCoordinates'](_0x1d52c4['e']['Up'](),_0x20f612),_0x1f4b97=_0x1d52c4['e']['TransformCoordinates'](_0x169a33,_0x3748b5),_0x56efe8=_0x1f4b97['multiply'](_0xcdfe73),_0x56b522=_0x1f4b97['divide'](_0xcdfe73)['normalize']();_0xd9bf21['push'](_0x56efe8['x'],_0x56efe8['y'],_0x56efe8['z']),_0x55969a['push'](_0x56b522['x'],_0x56b522['y'],_0x56b522['z']),_0x247037['push'](_0x18de3e,_0x59cf64);}if(_0x421df4>0x0){for(var _0xe24c29=_0xd9bf21['length']/0x3,_0x250f11=_0xe24c29-0x2*(_0x79ac7c+0x1);_0x250f11+_0x79ac7c+0x2<_0xe24c29;_0x250f11++)_0x296a62?(_0x421df4>0x1&&(_0x442d57['push'](_0x250f11),_0x442d57['push'](_0x250f11+0x1),_0x442d57['push'](_0x250f11+_0x79ac7c+0x1)),(_0x421df4<_0x49a960||_0x1ca550<0x1)&&(_0x442d57['push'](_0x250f11+_0x79ac7c+0x1),_0x442d57['push'](_0x250f11+0x1),_0x442d57['push'](_0x250f11+_0x79ac7c+0x2))):(_0x442d57['push'](_0x250f11),_0x442d57['push'](_0x250f11+0x1),_0x442d57['push'](_0x250f11+_0x79ac7c+0x1),_0x442d57['push'](_0x250f11+_0x79ac7c+0x1),_0x442d57['push'](_0x250f11+0x1),_0x442d57['push'](_0x250f11+_0x79ac7c+0x2));}}_0x22e086['a']['_ComputeSides'](_0x19acd8,_0xd9bf21,_0x442d57,_0x55969a,_0x247037,_0x5943bf['frontUVs'],_0x5943bf['backUVs']);var _0x54542a=new _0x22e086['a']();return _0x54542a['indices']=_0x442d57,_0x54542a['positions']=_0xd9bf21,_0x54542a['normals']=_0x55969a,_0x54542a['uvs']=_0x247037,_0x54542a;},_0x374b95['a']['CreateSphere']=function(_0x56f0e6,_0x446d5a,_0x13ea06,_0x10d42f,_0x44067b,_0x33493d){var _0x437c4c={'segments':_0x446d5a,'diameterX':_0x13ea06,'diameterY':_0x13ea06,'diameterZ':_0x13ea06,'sideOrientation':_0x33493d,'updatable':_0x44067b};return _0x323cb0['CreateSphere'](_0x56f0e6,_0x437c4c,_0x10d42f);};var _0x323cb0=(function(){function _0x1aa73b(){}return _0x1aa73b['CreateSphere']=function(_0x5d3d6b,_0xc0f8cf,_0x54e2ef){void 0x0===_0x54e2ef&&(_0x54e2ef=null);var _0x2f12a8=new _0x374b95['a'](_0x5d3d6b,_0x54e2ef);return _0xc0f8cf['sideOrientation']=_0x374b95['a']['_GetDefaultSideOrientation'](_0xc0f8cf['sideOrientation']),_0x2f12a8['_originalBuilderSideOrientation']=_0xc0f8cf['sideOrientation'],_0x22e086['a']['CreateSphere'](_0xc0f8cf)['applyToMesh'](_0x2f12a8,_0xc0f8cf['updatable']),_0x2f12a8;},_0x1aa73b;}());},function(_0x59adcb,_0x34c379,_0x5199e5){'use strict';_0x5199e5['d'](_0x34c379,'a',function(){return _0x25feea;});var _0x3efcab=_0x5199e5(0x1),_0x4b239b=_0x5199e5(0x3),_0x176abf=_0x5199e5(0x6),_0x2fbe99=_0x5199e5(0x0),_0x1fa415=_0x5199e5(0x1d),_0x2fe20f=_0x5199e5(0x17),_0x25feea=function(_0x2d2994){function _0x8c7d4c(_0x1bf864,_0x51e5e9,_0x27c57c){void 0x0===_0x51e5e9&&(_0x51e5e9=null),void 0x0===_0x27c57c&&(_0x27c57c=!0x0);var _0x199d95=_0x2d2994['call'](this,_0x1bf864,_0x51e5e9)||this;return _0x199d95['_forward']=new _0x2fbe99['e'](0x0,0x0,0x1),_0x199d95['_forwardInverted']=new _0x2fbe99['e'](0x0,0x0,-0x1),_0x199d95['_up']=new _0x2fbe99['e'](0x0,0x1,0x0),_0x199d95['_right']=new _0x2fbe99['e'](0x1,0x0,0x0),_0x199d95['_rightInverted']=new _0x2fbe99['e'](-0x1,0x0,0x0),_0x199d95['_position']=_0x2fbe99['e']['Zero'](),_0x199d95['_rotation']=_0x2fbe99['e']['Zero'](),_0x199d95['_rotationQuaternion']=null,_0x199d95['_scaling']=_0x2fbe99['e']['One'](),_0x199d95['_isDirty']=!0x1,_0x199d95['_transformToBoneReferal']=null,_0x199d95['_isAbsoluteSynced']=!0x1,_0x199d95['_billboardMode']=_0x8c7d4c['BILLBOARDMODE_NONE'],_0x199d95['_preserveParentRotationForBillboard']=!0x1,_0x199d95['scalingDeterminant']=0x1,_0x199d95['_infiniteDistance']=!0x1,_0x199d95['ignoreNonUniformScaling']=!0x1,_0x199d95['reIntegrateRotationIntoRotationQuaternion']=!0x1,_0x199d95['_poseMatrix']=null,_0x199d95['_localMatrix']=_0x2fbe99['a']['Zero'](),_0x199d95['_usePivotMatrix']=!0x1,_0x199d95['_absolutePosition']=_0x2fbe99['e']['Zero'](),_0x199d95['_absoluteScaling']=_0x2fbe99['e']['Zero'](),_0x199d95['_absoluteRotationQuaternion']=_0x2fbe99['b']['Identity'](),_0x199d95['_pivotMatrix']=_0x2fbe99['a']['Identity'](),_0x199d95['_postMultiplyPivotMatrix']=!0x1,_0x199d95['_isWorldMatrixFrozen']=!0x1,_0x199d95['_indexInSceneTransformNodesArray']=-0x1,_0x199d95['onAfterWorldMatrixUpdateObservable']=new _0x176abf['c'](),_0x199d95['_nonUniformScaling']=!0x1,_0x27c57c&&_0x199d95['getScene']()['addTransformNode'](_0x199d95),_0x199d95;}return Object(_0x3efcab['d'])(_0x8c7d4c,_0x2d2994),Object['defineProperty'](_0x8c7d4c['prototype'],'billboardMode',{'get':function(){return this['_billboardMode'];},'set':function(_0x4de587){this['_billboardMode']!==_0x4de587&&(this['_billboardMode']=_0x4de587);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x8c7d4c['prototype'],'preserveParentRotationForBillboard',{'get':function(){return this['_preserveParentRotationForBillboard'];},'set':function(_0x550375){_0x550375!==this['_preserveParentRotationForBillboard']&&(this['_preserveParentRotationForBillboard']=_0x550375);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x8c7d4c['prototype'],'infiniteDistance',{'get':function(){return this['_infiniteDistance'];},'set':function(_0x38cf2a){this['_infiniteDistance']!==_0x38cf2a&&(this['_infiniteDistance']=_0x38cf2a);},'enumerable':!0x1,'configurable':!0x0}),_0x8c7d4c['prototype']['getClassName']=function(){return'TransformNode';},Object['defineProperty'](_0x8c7d4c['prototype'],'position',{'get':function(){return this['_position'];},'set':function(_0x173e35){this['_position']=_0x173e35,this['_isDirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x8c7d4c['prototype'],'rotation',{'get':function(){return this['_rotation'];},'set':function(_0x154c1c){this['_rotation']=_0x154c1c,this['_rotationQuaternion']=null,this['_isDirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x8c7d4c['prototype'],'scaling',{'get':function(){return this['_scaling'];},'set':function(_0x56ee55){this['_scaling']=_0x56ee55,this['_isDirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x8c7d4c['prototype'],'rotationQuaternion',{'get':function(){return this['_rotationQuaternion'];},'set':function(_0x183fe1){this['_rotationQuaternion']=_0x183fe1,_0x183fe1&&this['_rotation']['setAll'](0x0),this['_isDirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x8c7d4c['prototype'],'forward',{'get':function(){return _0x2fbe99['e']['Normalize'](_0x2fbe99['e']['TransformNormal'](this['getScene']()['useRightHandedSystem']?this['_forwardInverted']:this['_forward'],this['getWorldMatrix']()));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x8c7d4c['prototype'],'up',{'get':function(){return _0x2fbe99['e']['Normalize'](_0x2fbe99['e']['TransformNormal'](this['_up'],this['getWorldMatrix']()));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x8c7d4c['prototype'],'right',{'get':function(){return _0x2fbe99['e']['Normalize'](_0x2fbe99['e']['TransformNormal'](this['getScene']()['useRightHandedSystem']?this['_rightInverted']:this['_right'],this['getWorldMatrix']()));},'enumerable':!0x1,'configurable':!0x0}),_0x8c7d4c['prototype']['updatePoseMatrix']=function(_0x56526e){return this['_poseMatrix']?(this['_poseMatrix']['copyFrom'](_0x56526e),this):(this['_poseMatrix']=_0x56526e['clone'](),this);},_0x8c7d4c['prototype']['getPoseMatrix']=function(){return this['_poseMatrix']||(this['_poseMatrix']=_0x2fbe99['a']['Identity']()),this['_poseMatrix'];},_0x8c7d4c['prototype']['_isSynchronized']=function(){var _0x408862=this['_cache'];return this['billboardMode']===_0x408862['billboardMode']&&this['billboardMode']===_0x8c7d4c['BILLBOARDMODE_NONE']&&(!_0x408862['pivotMatrixUpdated']&&(!this['infiniteDistance']&&(!this['position']['_isDirty']&&(!this['scaling']['_isDirty']&&!(this['_rotationQuaternion']&&this['_rotationQuaternion']['_isDirty']||this['rotation']['_isDirty'])))));},_0x8c7d4c['prototype']['_initCache']=function(){_0x2d2994['prototype']['_initCache']['call'](this);var _0x404e6e=this['_cache'];_0x404e6e['localMatrixUpdated']=!0x1,_0x404e6e['billboardMode']=-0x1,_0x404e6e['infiniteDistance']=!0x1;},_0x8c7d4c['prototype']['markAsDirty']=function(_0x2e1e58){return this['_currentRenderId']=Number['MAX_VALUE'],this['_isDirty']=!0x0,this;},Object['defineProperty'](_0x8c7d4c['prototype'],'absolutePosition',{'get':function(){return this['_absolutePosition'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x8c7d4c['prototype'],'absoluteScaling',{'get':function(){return this['_syncAbsoluteScalingAndRotation'](),this['_absoluteScaling'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x8c7d4c['prototype'],'absoluteRotationQuaternion',{'get':function(){return this['_syncAbsoluteScalingAndRotation'](),this['_absoluteRotationQuaternion'];},'enumerable':!0x1,'configurable':!0x0}),_0x8c7d4c['prototype']['setPreTransformMatrix']=function(_0x36209d){return this['setPivotMatrix'](_0x36209d,!0x1);},_0x8c7d4c['prototype']['setPivotMatrix']=function(_0x4a9d60,_0x3c3ef6){return void 0x0===_0x3c3ef6&&(_0x3c3ef6=!0x0),this['_pivotMatrix']['copyFrom'](_0x4a9d60),this['_usePivotMatrix']=!this['_pivotMatrix']['isIdentity'](),this['_cache']['pivotMatrixUpdated']=!0x0,this['_postMultiplyPivotMatrix']=_0x3c3ef6,this['_postMultiplyPivotMatrix']&&(this['_pivotMatrixInverse']?this['_pivotMatrix']['invertToRef'](this['_pivotMatrixInverse']):this['_pivotMatrixInverse']=_0x2fbe99['a']['Invert'](this['_pivotMatrix'])),this;},_0x8c7d4c['prototype']['getPivotMatrix']=function(){return this['_pivotMatrix'];},_0x8c7d4c['prototype']['instantiateHierarchy']=function(_0xf03bdc,_0x53b1fe,_0x34b1b3){void 0x0===_0xf03bdc&&(_0xf03bdc=null);var _0x1278d8=this['clone']('Clone\x20of\x20'+(this['name']||this['id']),_0xf03bdc||this['parent'],!0x0);_0x1278d8&&_0x34b1b3&&_0x34b1b3(this,_0x1278d8);for(var _0x3e89a8=0x0,_0x4b318f=this['getChildTransformNodes'](!0x0);_0x3e89a8<_0x4b318f['length'];_0x3e89a8++){_0x4b318f[_0x3e89a8]['instantiateHierarchy'](_0x1278d8,_0x53b1fe,_0x34b1b3);}return _0x1278d8;},_0x8c7d4c['prototype']['freezeWorldMatrix']=function(_0x247544){return void 0x0===_0x247544&&(_0x247544=null),_0x247544?this['_worldMatrix']=_0x247544:(this['_isWorldMatrixFrozen']=!0x1,this['computeWorldMatrix'](!0x0)),this['_isDirty']=!0x1,this['_isWorldMatrixFrozen']=!0x0,this;},_0x8c7d4c['prototype']['unfreezeWorldMatrix']=function(){return this['_isWorldMatrixFrozen']=!0x1,this['computeWorldMatrix'](!0x0),this;},Object['defineProperty'](_0x8c7d4c['prototype'],'isWorldMatrixFrozen',{'get':function(){return this['_isWorldMatrixFrozen'];},'enumerable':!0x1,'configurable':!0x0}),_0x8c7d4c['prototype']['getAbsolutePosition']=function(){return this['computeWorldMatrix'](),this['_absolutePosition'];},_0x8c7d4c['prototype']['setAbsolutePosition']=function(_0x3a5191){if(!_0x3a5191)return this;var _0x2eae36,_0x928c26,_0xe72608;if(void 0x0===_0x3a5191['x']){if(arguments['length']<0x3)return this;_0x2eae36=arguments[0x0],_0x928c26=arguments[0x1],_0xe72608=arguments[0x2];}else _0x2eae36=_0x3a5191['x'],_0x928c26=_0x3a5191['y'],_0xe72608=_0x3a5191['z'];if(this['parent']){var _0x2fab2b=_0x2fbe99['c']['Matrix'][0x0];this['parent']['getWorldMatrix']()['invertToRef'](_0x2fab2b),_0x2fbe99['e']['TransformCoordinatesFromFloatsToRef'](_0x2eae36,_0x928c26,_0xe72608,_0x2fab2b,this['position']);}else this['position']['x']=_0x2eae36,this['position']['y']=_0x928c26,this['position']['z']=_0xe72608;return this['_absolutePosition']['copyFrom'](_0x3a5191),this;},_0x8c7d4c['prototype']['setPositionWithLocalVector']=function(_0x382d47){return this['computeWorldMatrix'](),this['position']=_0x2fbe99['e']['TransformNormal'](_0x382d47,this['_localMatrix']),this;},_0x8c7d4c['prototype']['getPositionExpressedInLocalSpace']=function(){this['computeWorldMatrix']();var _0xa19dcf=_0x2fbe99['c']['Matrix'][0x0];return this['_localMatrix']['invertToRef'](_0xa19dcf),_0x2fbe99['e']['TransformNormal'](this['position'],_0xa19dcf);},_0x8c7d4c['prototype']['locallyTranslate']=function(_0x3c5d4a){return this['computeWorldMatrix'](!0x0),this['position']=_0x2fbe99['e']['TransformCoordinates'](_0x3c5d4a,this['_localMatrix']),this;},_0x8c7d4c['prototype']['lookAt']=function(_0x2efc3e,_0x4a6c82,_0x3f237d,_0x52d9cd,_0x45308d){void 0x0===_0x4a6c82&&(_0x4a6c82=0x0),void 0x0===_0x3f237d&&(_0x3f237d=0x0),void 0x0===_0x52d9cd&&(_0x52d9cd=0x0),void 0x0===_0x45308d&&(_0x45308d=_0x2fe20f['c']['LOCAL']);var _0x171aff=_0x8c7d4c['_lookAtVectorCache'],_0x47e437=_0x45308d===_0x2fe20f['c']['LOCAL']?this['position']:this['getAbsolutePosition']();if(_0x2efc3e['subtractToRef'](_0x47e437,_0x171aff),this['setDirection'](_0x171aff,_0x4a6c82,_0x3f237d,_0x52d9cd),_0x45308d===_0x2fe20f['c']['WORLD']&&this['parent']){if(this['rotationQuaternion']){var _0x3db8c3=_0x2fbe99['c']['Matrix'][0x0];this['rotationQuaternion']['toRotationMatrix'](_0x3db8c3);var _0x3ab506=_0x2fbe99['c']['Matrix'][0x1];this['parent']['getWorldMatrix']()['getRotationMatrixToRef'](_0x3ab506),_0x3ab506['invert'](),_0x3db8c3['multiplyToRef'](_0x3ab506,_0x3db8c3),this['rotationQuaternion']['fromRotationMatrix'](_0x3db8c3);}else{var _0x2d779e=_0x2fbe99['c']['Quaternion'][0x0];_0x2fbe99['b']['FromEulerVectorToRef'](this['rotation'],_0x2d779e),_0x3db8c3=_0x2fbe99['c']['Matrix'][0x0],_0x2d779e['toRotationMatrix'](_0x3db8c3),_0x3ab506=_0x2fbe99['c']['Matrix'][0x1],(this['parent']['getWorldMatrix']()['getRotationMatrixToRef'](_0x3ab506),_0x3ab506['invert'](),_0x3db8c3['multiplyToRef'](_0x3ab506,_0x3db8c3),_0x2d779e['fromRotationMatrix'](_0x3db8c3),_0x2d779e['toEulerAnglesToRef'](this['rotation']));}}return this;},_0x8c7d4c['prototype']['getDirection']=function(_0x36f959){var _0x421104=_0x2fbe99['e']['Zero']();return this['getDirectionToRef'](_0x36f959,_0x421104),_0x421104;},_0x8c7d4c['prototype']['getDirectionToRef']=function(_0x57044d,_0x21f83f){return _0x2fbe99['e']['TransformNormalToRef'](_0x57044d,this['getWorldMatrix'](),_0x21f83f),this;},_0x8c7d4c['prototype']['setDirection']=function(_0x403f60,_0x7165a4,_0x196e53,_0x3c3e72){void 0x0===_0x7165a4&&(_0x7165a4=0x0),void 0x0===_0x196e53&&(_0x196e53=0x0),void 0x0===_0x3c3e72&&(_0x3c3e72=0x0);var _0x1ff78a=-Math['atan2'](_0x403f60['z'],_0x403f60['x'])+Math['PI']/0x2,_0x330dfe=Math['sqrt'](_0x403f60['x']*_0x403f60['x']+_0x403f60['z']*_0x403f60['z']),_0x4f364f=-Math['atan2'](_0x403f60['y'],_0x330dfe);return this['rotationQuaternion']?_0x2fbe99['b']['RotationYawPitchRollToRef'](_0x1ff78a+_0x7165a4,_0x4f364f+_0x196e53,_0x3c3e72,this['rotationQuaternion']):(this['rotation']['x']=_0x4f364f+_0x196e53,this['rotation']['y']=_0x1ff78a+_0x7165a4,this['rotation']['z']=_0x3c3e72),this;},_0x8c7d4c['prototype']['setPivotPoint']=function(_0x17addf,_0x4479e5){void 0x0===_0x4479e5&&(_0x4479e5=_0x2fe20f['c']['LOCAL']),0x0==this['getScene']()['getRenderId']()&&this['computeWorldMatrix'](!0x0);var _0x55ab26=this['getWorldMatrix']();if(_0x4479e5==_0x2fe20f['c']['WORLD']){var _0x17688a=_0x2fbe99['c']['Matrix'][0x0];_0x55ab26['invertToRef'](_0x17688a),_0x17addf=_0x2fbe99['e']['TransformCoordinates'](_0x17addf,_0x17688a);}return this['setPivotMatrix'](_0x2fbe99['a']['Translation'](-_0x17addf['x'],-_0x17addf['y'],-_0x17addf['z']),!0x0);},_0x8c7d4c['prototype']['getPivotPoint']=function(){var _0x4559d5=_0x2fbe99['e']['Zero']();return this['getPivotPointToRef'](_0x4559d5),_0x4559d5;},_0x8c7d4c['prototype']['getPivotPointToRef']=function(_0x44b092){return _0x44b092['x']=-this['_pivotMatrix']['m'][0xc],_0x44b092['y']=-this['_pivotMatrix']['m'][0xd],_0x44b092['z']=-this['_pivotMatrix']['m'][0xe],this;},_0x8c7d4c['prototype']['getAbsolutePivotPoint']=function(){var _0x21ec4e=_0x2fbe99['e']['Zero']();return this['getAbsolutePivotPointToRef'](_0x21ec4e),_0x21ec4e;},_0x8c7d4c['prototype']['getAbsolutePivotPointToRef']=function(_0x5e0b4e){return this['getPivotPointToRef'](_0x5e0b4e),_0x2fbe99['e']['TransformCoordinatesToRef'](_0x5e0b4e,this['getWorldMatrix'](),_0x5e0b4e),this;},_0x8c7d4c['prototype']['setParent']=function(_0x1c2803){if(!_0x1c2803&&!this['parent'])return this;var _0x3acc9c=_0x2fbe99['c']['Quaternion'][0x0],_0x26acad=_0x2fbe99['c']['Vector3'][0x0],_0x2e182e=_0x2fbe99['c']['Vector3'][0x1];if(_0x1c2803){var _0x2a6cc8=_0x2fbe99['c']['Matrix'][0x0],_0x46fbcf=_0x2fbe99['c']['Matrix'][0x1];this['computeWorldMatrix'](!0x0),_0x1c2803['computeWorldMatrix'](!0x0),_0x1c2803['getWorldMatrix']()['invertToRef'](_0x46fbcf),this['getWorldMatrix']()['multiplyToRef'](_0x46fbcf,_0x2a6cc8),_0x2a6cc8['decompose'](_0x2e182e,_0x3acc9c,_0x26acad);}else this['computeWorldMatrix'](!0x0),this['getWorldMatrix']()['decompose'](_0x2e182e,_0x3acc9c,_0x26acad);return this['rotationQuaternion']?this['rotationQuaternion']['copyFrom'](_0x3acc9c):_0x3acc9c['toEulerAnglesToRef'](this['rotation']),this['scaling']['copyFrom'](_0x2e182e),this['position']['copyFrom'](_0x26acad),this['parent']=_0x1c2803,this;},Object['defineProperty'](_0x8c7d4c['prototype'],'nonUniformScaling',{'get':function(){return this['_nonUniformScaling'];},'enumerable':!0x1,'configurable':!0x0}),_0x8c7d4c['prototype']['_updateNonUniformScalingState']=function(_0x297d74){return this['_nonUniformScaling']!==_0x297d74&&(this['_nonUniformScaling']=_0x297d74,!0x0);},_0x8c7d4c['prototype']['attachToBone']=function(_0x325dbc,_0x5122ce){return this['_transformToBoneReferal']=_0x5122ce,this['parent']=_0x325dbc,_0x325dbc['getSkeleton']()['prepare'](),_0x325dbc['getWorldMatrix']()['determinant']()<0x0&&(this['scalingDeterminant']*=-0x1),this;},_0x8c7d4c['prototype']['detachFromBone']=function(){return this['parent']?(this['parent']['getWorldMatrix']()['determinant']()<0x0&&(this['scalingDeterminant']*=-0x1),this['_transformToBoneReferal']=null,this['parent']=null,this):this;},_0x8c7d4c['prototype']['rotate']=function(_0x20d55a,_0x78b6ee,_0x3f08d1){var _0x40cc11;if(_0x20d55a['normalize'](),this['rotationQuaternion']||(this['rotationQuaternion']=this['rotation']['toQuaternion'](),this['rotation']['setAll'](0x0)),_0x3f08d1&&_0x3f08d1!==_0x2fe20f['c']['LOCAL']){if(this['parent']){var _0x1aac3c=_0x2fbe99['c']['Matrix'][0x0];this['parent']['getWorldMatrix']()['invertToRef'](_0x1aac3c),_0x20d55a=_0x2fbe99['e']['TransformNormal'](_0x20d55a,_0x1aac3c);}(_0x40cc11=_0x2fbe99['b']['RotationAxisToRef'](_0x20d55a,_0x78b6ee,_0x8c7d4c['_rotationAxisCache']))['multiplyToRef'](this['rotationQuaternion'],this['rotationQuaternion']);}else _0x40cc11=_0x2fbe99['b']['RotationAxisToRef'](_0x20d55a,_0x78b6ee,_0x8c7d4c['_rotationAxisCache']),this['rotationQuaternion']['multiplyToRef'](_0x40cc11,this['rotationQuaternion']);return this;},_0x8c7d4c['prototype']['rotateAround']=function(_0x3eb4f5,_0x232238,_0x53ec13){_0x232238['normalize'](),this['rotationQuaternion']||(this['rotationQuaternion']=_0x2fbe99['b']['RotationYawPitchRoll'](this['rotation']['y'],this['rotation']['x'],this['rotation']['z']),this['rotation']['setAll'](0x0));var _0x5af08a=_0x2fbe99['c']['Vector3'][0x0],_0x335109=_0x2fbe99['c']['Vector3'][0x1],_0x59472f=_0x2fbe99['c']['Vector3'][0x2],_0x4c0b7e=_0x2fbe99['c']['Quaternion'][0x0],_0x42d42c=_0x2fbe99['c']['Matrix'][0x0],_0xe36b23=_0x2fbe99['c']['Matrix'][0x1],_0x5ed0b1=_0x2fbe99['c']['Matrix'][0x2],_0x18d442=_0x2fbe99['c']['Matrix'][0x3];return _0x3eb4f5['subtractToRef'](this['position'],_0x5af08a),_0x2fbe99['a']['TranslationToRef'](_0x5af08a['x'],_0x5af08a['y'],_0x5af08a['z'],_0x42d42c),_0x2fbe99['a']['TranslationToRef'](-_0x5af08a['x'],-_0x5af08a['y'],-_0x5af08a['z'],_0xe36b23),_0x2fbe99['a']['RotationAxisToRef'](_0x232238,_0x53ec13,_0x5ed0b1),_0xe36b23['multiplyToRef'](_0x5ed0b1,_0x18d442),_0x18d442['multiplyToRef'](_0x42d42c,_0x18d442),_0x18d442['decompose'](_0x335109,_0x4c0b7e,_0x59472f),this['position']['addInPlace'](_0x59472f),_0x4c0b7e['multiplyToRef'](this['rotationQuaternion'],this['rotationQuaternion']),this;},_0x8c7d4c['prototype']['translate']=function(_0x740cc,_0x41d4c7,_0x556d61){var _0x2f0803=_0x740cc['scale'](_0x41d4c7);if(_0x556d61&&_0x556d61!==_0x2fe20f['c']['LOCAL'])this['setAbsolutePosition'](this['getAbsolutePosition']()['add'](_0x2f0803));else{var _0x34c48a=this['getPositionExpressedInLocalSpace']()['add'](_0x2f0803);this['setPositionWithLocalVector'](_0x34c48a);}return this;},_0x8c7d4c['prototype']['addRotation']=function(_0x409554,_0x2c882b,_0x34101){var _0x1d5586;this['rotationQuaternion']?_0x1d5586=this['rotationQuaternion']:(_0x1d5586=_0x2fbe99['c']['Quaternion'][0x1],_0x2fbe99['b']['RotationYawPitchRollToRef'](this['rotation']['y'],this['rotation']['x'],this['rotation']['z'],_0x1d5586));var _0x5eeccc=_0x2fbe99['c']['Quaternion'][0x0];return _0x2fbe99['b']['RotationYawPitchRollToRef'](_0x2c882b,_0x409554,_0x34101,_0x5eeccc),_0x1d5586['multiplyInPlace'](_0x5eeccc),this['rotationQuaternion']||_0x1d5586['toEulerAnglesToRef'](this['rotation']),this;},_0x8c7d4c['prototype']['_getEffectiveParent']=function(){return this['parent'];},_0x8c7d4c['prototype']['computeWorldMatrix']=function(_0x52dfa0){if(this['_isWorldMatrixFrozen']&&!this['_isDirty'])return this['_worldMatrix'];var _0x3d85be=this['getScene']()['getRenderId']();if(!this['_isDirty']&&!_0x52dfa0&&this['isSynchronized']())return this['_currentRenderId']=_0x3d85be,this['_worldMatrix'];var _0x424361=this['getScene']()['activeCamera'],_0x337f93=0x0!=(this['_billboardMode']&_0x8c7d4c['BILLBOARDMODE_USE_POSITION']),_0x567077=this['_billboardMode']!==_0x8c7d4c['BILLBOARDMODE_NONE']&&!this['preserveParentRotationForBillboard'];_0x567077&&_0x424361&&_0x337f93&&(this['lookAt'](_0x424361['position']),(this['billboardMode']&_0x8c7d4c['BILLBOARDMODE_X'])!==_0x8c7d4c['BILLBOARDMODE_X']&&(this['rotation']['x']=0x0),(this['billboardMode']&_0x8c7d4c['BILLBOARDMODE_Y'])!==_0x8c7d4c['BILLBOARDMODE_Y']&&(this['rotation']['y']=0x0),(this['billboardMode']&_0x8c7d4c['BILLBOARDMODE_Z'])!==_0x8c7d4c['BILLBOARDMODE_Z']&&(this['rotation']['z']=0x0)),this['_updateCache']();var _0x43f93a=this['_cache'];_0x43f93a['pivotMatrixUpdated']=!0x1,_0x43f93a['billboardMode']=this['billboardMode'],_0x43f93a['infiniteDistance']=this['infiniteDistance'],this['_currentRenderId']=_0x3d85be,this['_childUpdateId']++,this['_isDirty']=!0x1,this['_position']['_isDirty']=!0x1,this['_rotation']['_isDirty']=!0x1,this['_scaling']['_isDirty']=!0x1;var _0xaa4e0d,_0x1d5b33=this['_getEffectiveParent'](),_0x3c4f8d=_0x8c7d4c['_TmpScaling'],_0x54e643=this['_position'];if(this['_infiniteDistance']&&!this['parent']&&_0x424361){var _0x49a20b=_0x424361['getWorldMatrix'](),_0x59de7e=new _0x2fbe99['e'](_0x49a20b['m'][0xc],_0x49a20b['m'][0xd],_0x49a20b['m'][0xe]);(_0x54e643=_0x8c7d4c['_TmpTranslation'])['copyFromFloats'](this['_position']['x']+_0x59de7e['x'],this['_position']['y']+_0x59de7e['y'],this['_position']['z']+_0x59de7e['z']);}(_0x3c4f8d['copyFromFloats'](this['_scaling']['x']*this['scalingDeterminant'],this['_scaling']['y']*this['scalingDeterminant'],this['_scaling']['z']*this['scalingDeterminant']),this['_rotationQuaternion'])?(this['_rotationQuaternion']['_isDirty']=!0x1,_0xaa4e0d=this['_rotationQuaternion'],this['reIntegrateRotationIntoRotationQuaternion']&&this['rotation']['lengthSquared']()&&(this['_rotationQuaternion']['multiplyInPlace'](_0x2fbe99['b']['RotationYawPitchRoll'](this['_rotation']['y'],this['_rotation']['x'],this['_rotation']['z'])),this['_rotation']['copyFromFloats'](0x0,0x0,0x0))):(_0xaa4e0d=_0x8c7d4c['_TmpRotation'],_0x2fbe99['b']['RotationYawPitchRollToRef'](this['_rotation']['y'],this['_rotation']['x'],this['_rotation']['z'],_0xaa4e0d));if(this['_usePivotMatrix']){var _0x117235=_0x2fbe99['c']['Matrix'][0x1];_0x2fbe99['a']['ScalingToRef'](_0x3c4f8d['x'],_0x3c4f8d['y'],_0x3c4f8d['z'],_0x117235);var _0x27c4db=_0x2fbe99['c']['Matrix'][0x0];_0xaa4e0d['toRotationMatrix'](_0x27c4db),this['_pivotMatrix']['multiplyToRef'](_0x117235,_0x2fbe99['c']['Matrix'][0x4]),_0x2fbe99['c']['Matrix'][0x4]['multiplyToRef'](_0x27c4db,this['_localMatrix']),this['_postMultiplyPivotMatrix']&&this['_localMatrix']['multiplyToRef'](this['_pivotMatrixInverse'],this['_localMatrix']),this['_localMatrix']['addTranslationFromFloats'](_0x54e643['x'],_0x54e643['y'],_0x54e643['z']);}else _0x2fbe99['a']['ComposeToRef'](_0x3c4f8d,_0xaa4e0d,_0x54e643,this['_localMatrix']);if(_0x1d5b33&&_0x1d5b33['getWorldMatrix']){if(_0x52dfa0&&_0x1d5b33['computeWorldMatrix'](),_0x567077){this['_transformToBoneReferal']?_0x1d5b33['getWorldMatrix']()['multiplyToRef'](this['_transformToBoneReferal']['getWorldMatrix'](),_0x2fbe99['c']['Matrix'][0x7]):_0x2fbe99['c']['Matrix'][0x7]['copyFrom'](_0x1d5b33['getWorldMatrix']());var _0x7686c7=_0x2fbe99['c']['Vector3'][0x5],_0x2522f6=_0x2fbe99['c']['Vector3'][0x6];_0x2fbe99['c']['Matrix'][0x7]['decompose'](_0x2522f6,void 0x0,_0x7686c7),_0x2fbe99['a']['ScalingToRef'](_0x2522f6['x'],_0x2522f6['y'],_0x2522f6['z'],_0x2fbe99['c']['Matrix'][0x7]),_0x2fbe99['c']['Matrix'][0x7]['setTranslation'](_0x7686c7),this['_localMatrix']['multiplyToRef'](_0x2fbe99['c']['Matrix'][0x7],this['_worldMatrix']);}else this['_transformToBoneReferal']?(this['_localMatrix']['multiplyToRef'](_0x1d5b33['getWorldMatrix'](),_0x2fbe99['c']['Matrix'][0x6]),_0x2fbe99['c']['Matrix'][0x6]['multiplyToRef'](this['_transformToBoneReferal']['getWorldMatrix'](),this['_worldMatrix'])):this['_localMatrix']['multiplyToRef'](_0x1d5b33['getWorldMatrix'](),this['_worldMatrix']);this['_markSyncedWithParent']();}else this['_worldMatrix']['copyFrom'](this['_localMatrix']);if(_0x567077&&_0x424361&&this['billboardMode']&&!_0x337f93){var _0x488b9f=_0x2fbe99['c']['Vector3'][0x0];if(this['_worldMatrix']['getTranslationToRef'](_0x488b9f),_0x2fbe99['c']['Matrix'][0x1]['copyFrom'](_0x424361['getViewMatrix']()),_0x2fbe99['c']['Matrix'][0x1]['setTranslationFromFloats'](0x0,0x0,0x0),_0x2fbe99['c']['Matrix'][0x1]['invertToRef'](_0x2fbe99['c']['Matrix'][0x0]),(this['billboardMode']&_0x8c7d4c['BILLBOARDMODE_ALL'])!==_0x8c7d4c['BILLBOARDMODE_ALL']){_0x2fbe99['c']['Matrix'][0x0]['decompose'](void 0x0,_0x2fbe99['c']['Quaternion'][0x0],void 0x0);var _0x2ba080=_0x2fbe99['c']['Vector3'][0x1];_0x2fbe99['c']['Quaternion'][0x0]['toEulerAnglesToRef'](_0x2ba080),(this['billboardMode']&_0x8c7d4c['BILLBOARDMODE_X'])!==_0x8c7d4c['BILLBOARDMODE_X']&&(_0x2ba080['x']=0x0),(this['billboardMode']&_0x8c7d4c['BILLBOARDMODE_Y'])!==_0x8c7d4c['BILLBOARDMODE_Y']&&(_0x2ba080['y']=0x0),(this['billboardMode']&_0x8c7d4c['BILLBOARDMODE_Z'])!==_0x8c7d4c['BILLBOARDMODE_Z']&&(_0x2ba080['z']=0x0),_0x2fbe99['a']['RotationYawPitchRollToRef'](_0x2ba080['y'],_0x2ba080['x'],_0x2ba080['z'],_0x2fbe99['c']['Matrix'][0x0]);}this['_worldMatrix']['setTranslationFromFloats'](0x0,0x0,0x0),this['_worldMatrix']['multiplyToRef'](_0x2fbe99['c']['Matrix'][0x0],this['_worldMatrix']),this['_worldMatrix']['setTranslation'](_0x2fbe99['c']['Vector3'][0x0]);}return this['ignoreNonUniformScaling']?this['_updateNonUniformScalingState'](!0x1):this['_scaling']['isNonUniformWithinEpsilon'](0.000001)?this['_updateNonUniformScalingState'](!0x0):_0x1d5b33&&_0x1d5b33['_nonUniformScaling']?this['_updateNonUniformScalingState'](_0x1d5b33['_nonUniformScaling']):this['_updateNonUniformScalingState'](!0x1),this['_afterComputeWorldMatrix'](),this['_absolutePosition']['copyFromFloats'](this['_worldMatrix']['m'][0xc],this['_worldMatrix']['m'][0xd],this['_worldMatrix']['m'][0xe]),this['_isAbsoluteSynced']=!0x1,this['onAfterWorldMatrixUpdateObservable']['notifyObservers'](this),this['_poseMatrix']||(this['_poseMatrix']=_0x2fbe99['a']['Invert'](this['_worldMatrix'])),this['_worldMatrixDeterminantIsDirty']=!0x0,this['_worldMatrix'];},_0x8c7d4c['prototype']['resetLocalMatrix']=function(_0xddf1db){if(void 0x0===_0xddf1db&&(_0xddf1db=!0x0),this['computeWorldMatrix'](),_0xddf1db)for(var _0x3030cc=this['getChildren'](),_0x1b6d20=0x0;_0x1b6d20<_0x3030cc['length'];++_0x1b6d20){var _0x1bb5d1=_0x3030cc[_0x1b6d20];if(_0x1bb5d1){_0x1bb5d1['computeWorldMatrix']();var _0x16ff46=_0x2fbe99['c']['Matrix'][0x0];_0x1bb5d1['_localMatrix']['multiplyToRef'](this['_localMatrix'],_0x16ff46);var _0x4f0d56=_0x2fbe99['c']['Quaternion'][0x0];_0x16ff46['decompose'](_0x1bb5d1['scaling'],_0x4f0d56,_0x1bb5d1['position']),_0x1bb5d1['rotationQuaternion']?_0x1bb5d1['rotationQuaternion']=_0x4f0d56:_0x4f0d56['toEulerAnglesToRef'](_0x1bb5d1['rotation']);}}this['scaling']['copyFromFloats'](0x1,0x1,0x1),this['position']['copyFromFloats'](0x0,0x0,0x0),this['rotation']['copyFromFloats'](0x0,0x0,0x0),this['rotationQuaternion']&&(this['rotationQuaternion']=_0x2fbe99['b']['Identity']()),this['_worldMatrix']=_0x2fbe99['a']['Identity']();},_0x8c7d4c['prototype']['_afterComputeWorldMatrix']=function(){},_0x8c7d4c['prototype']['registerAfterWorldMatrixUpdate']=function(_0x3eb93a){return this['onAfterWorldMatrixUpdateObservable']['add'](_0x3eb93a),this;},_0x8c7d4c['prototype']['unregisterAfterWorldMatrixUpdate']=function(_0x115583){return this['onAfterWorldMatrixUpdateObservable']['removeCallback'](_0x115583),this;},_0x8c7d4c['prototype']['getPositionInCameraSpace']=function(_0x517dad){return void 0x0===_0x517dad&&(_0x517dad=null),_0x517dad||(_0x517dad=this['getScene']()['activeCamera']),_0x2fbe99['e']['TransformCoordinates'](this['getAbsolutePosition'](),_0x517dad['getViewMatrix']());},_0x8c7d4c['prototype']['getDistanceToCamera']=function(_0x9a5024){return void 0x0===_0x9a5024&&(_0x9a5024=null),_0x9a5024||(_0x9a5024=this['getScene']()['activeCamera']),this['getAbsolutePosition']()['subtract'](_0x9a5024['globalPosition'])['length']();},_0x8c7d4c['prototype']['clone']=function(_0x464ee9,_0x2379e3,_0x1cebd){var _0x20aadf=this,_0x1e52fa=_0x4b239b['a']['Clone'](function(){return new _0x8c7d4c(_0x464ee9,_0x20aadf['getScene']());},this);if(_0x1e52fa['name']=_0x464ee9,_0x1e52fa['id']=_0x464ee9,_0x2379e3&&(_0x1e52fa['parent']=_0x2379e3),!_0x1cebd)for(var _0x232f17=this['getDescendants'](!0x0),_0x4d6037=0x0;_0x4d6037<_0x232f17['length'];_0x4d6037++){var _0x5dc894=_0x232f17[_0x4d6037];_0x5dc894['clone']&&_0x5dc894['clone'](_0x464ee9+'.'+_0x5dc894['name'],_0x1e52fa);}return _0x1e52fa;},_0x8c7d4c['prototype']['serialize']=function(_0xe3916d){var _0x47f750=_0x4b239b['a']['Serialize'](this,_0xe3916d);return _0x47f750['type']=this['getClassName'](),this['parent']&&(_0x47f750['parentId']=this['parent']['id']),_0x47f750['localMatrix']=this['getPivotMatrix']()['asArray'](),_0x47f750['isEnabled']=this['isEnabled'](),this['parent']&&(_0x47f750['parentId']=this['parent']['id']),_0x47f750;},_0x8c7d4c['Parse']=function(_0x7ee881,_0x13b21c,_0x4e7ac9){var _0x2a49dc=_0x4b239b['a']['Parse'](function(){return new _0x8c7d4c(_0x7ee881['name'],_0x13b21c);},_0x7ee881,_0x13b21c,_0x4e7ac9);return _0x7ee881['localMatrix']?_0x2a49dc['setPreTransformMatrix'](_0x2fbe99['a']['FromArray'](_0x7ee881['localMatrix'])):_0x7ee881['pivotMatrix']&&_0x2a49dc['setPivotMatrix'](_0x2fbe99['a']['FromArray'](_0x7ee881['pivotMatrix'])),_0x2a49dc['setEnabled'](_0x7ee881['isEnabled']),_0x7ee881['parentId']&&(_0x2a49dc['_waitingParentId']=_0x7ee881['parentId']),_0x2a49dc;},_0x8c7d4c['prototype']['getChildTransformNodes']=function(_0xebcd7a,_0x4c6adb){var _0x55c928=[];return this['_getDescendants'](_0x55c928,_0xebcd7a,function(_0x21483a){return(!_0x4c6adb||_0x4c6adb(_0x21483a))&&_0x21483a instanceof _0x8c7d4c;}),_0x55c928;},_0x8c7d4c['prototype']['dispose']=function(_0xb50455,_0x603dd6){if(void 0x0===_0x603dd6&&(_0x603dd6=!0x1),this['getScene']()['stopAnimation'](this),this['getScene']()['removeTransformNode'](this),this['onAfterWorldMatrixUpdateObservable']['clear'](),_0xb50455)for(var _0x1bf5bd=0x0,_0x30e93e=this['getChildTransformNodes'](!0x0);_0x1bf5bd<_0x30e93e['length'];_0x1bf5bd++){var _0x99a9d4=_0x30e93e[_0x1bf5bd];_0x99a9d4['parent']=null,_0x99a9d4['computeWorldMatrix'](!0x0);}_0x2d2994['prototype']['dispose']['call'](this,_0xb50455,_0x603dd6);},_0x8c7d4c['prototype']['normalizeToUnitCube']=function(_0x1b26ec,_0x13e8bf,_0x76e359){void 0x0===_0x1b26ec&&(_0x1b26ec=!0x0),void 0x0===_0x13e8bf&&(_0x13e8bf=!0x1);var _0x3a5480=null,_0x35ba31=null;_0x13e8bf&&(this['rotationQuaternion']?(_0x35ba31=this['rotationQuaternion']['clone'](),this['rotationQuaternion']['copyFromFloats'](0x0,0x0,0x0,0x1)):this['rotation']&&(_0x3a5480=this['rotation']['clone'](),this['rotation']['copyFromFloats'](0x0,0x0,0x0)));var _0x44f76f=this['getHierarchyBoundingVectors'](_0x1b26ec,_0x76e359),_0x2c7fad=_0x44f76f['max']['subtract'](_0x44f76f['min']),_0x4472a7=Math['max'](_0x2c7fad['x'],_0x2c7fad['y'],_0x2c7fad['z']);if(0x0===_0x4472a7)return this;var _0x15da1d=0x1/_0x4472a7;return this['scaling']['scaleInPlace'](_0x15da1d),_0x13e8bf&&(this['rotationQuaternion']&&_0x35ba31?this['rotationQuaternion']['copyFrom'](_0x35ba31):this['rotation']&&_0x3a5480&&this['rotation']['copyFrom'](_0x3a5480)),this;},_0x8c7d4c['prototype']['_syncAbsoluteScalingAndRotation']=function(){this['_isAbsoluteSynced']||(this['_worldMatrix']['decompose'](this['_absoluteScaling'],this['_absoluteRotationQuaternion']),this['_isAbsoluteSynced']=!0x0);},_0x8c7d4c['BILLBOARDMODE_NONE']=0x0,_0x8c7d4c['BILLBOARDMODE_X']=0x1,_0x8c7d4c['BILLBOARDMODE_Y']=0x2,_0x8c7d4c['BILLBOARDMODE_Z']=0x4,_0x8c7d4c['BILLBOARDMODE_ALL']=0x7,_0x8c7d4c['BILLBOARDMODE_USE_POSITION']=0x80,_0x8c7d4c['_TmpRotation']=_0x2fbe99['b']['Zero'](),_0x8c7d4c['_TmpScaling']=_0x2fbe99['e']['Zero'](),_0x8c7d4c['_TmpTranslation']=_0x2fbe99['e']['Zero'](),_0x8c7d4c['_lookAtVectorCache']=new _0x2fbe99['e'](0x0,0x0,0x0),_0x8c7d4c['_rotationAxisCache']=new _0x2fbe99['b'](),Object(_0x3efcab['c'])([Object(_0x4b239b['o'])('position')],_0x8c7d4c['prototype'],'_position',void 0x0),Object(_0x3efcab['c'])([Object(_0x4b239b['o'])('rotation')],_0x8c7d4c['prototype'],'_rotation',void 0x0),Object(_0x3efcab['c'])([Object(_0x4b239b['l'])('rotationQuaternion')],_0x8c7d4c['prototype'],'_rotationQuaternion',void 0x0),Object(_0x3efcab['c'])([Object(_0x4b239b['o'])('scaling')],_0x8c7d4c['prototype'],'_scaling',void 0x0),Object(_0x3efcab['c'])([Object(_0x4b239b['c'])('billboardMode')],_0x8c7d4c['prototype'],'_billboardMode',void 0x0),Object(_0x3efcab['c'])([Object(_0x4b239b['c'])()],_0x8c7d4c['prototype'],'scalingDeterminant',void 0x0),Object(_0x3efcab['c'])([Object(_0x4b239b['c'])('infiniteDistance')],_0x8c7d4c['prototype'],'_infiniteDistance',void 0x0),Object(_0x3efcab['c'])([Object(_0x4b239b['c'])()],_0x8c7d4c['prototype'],'ignoreNonUniformScaling',void 0x0),Object(_0x3efcab['c'])([Object(_0x4b239b['c'])()],_0x8c7d4c['prototype'],'reIntegrateRotationIntoRotationQuaternion',void 0x0),_0x8c7d4c;}(_0x1fa415['a']);},function(_0x32eda8,_0xcbd56f,_0x455e46){'use strict';_0x455e46['d'](_0xcbd56f,'a',function(){return _0x5420c6;});var _0x5420c6=(function(){function _0x2b3b6f(_0xa24fec,_0x20c9bf,_0x1004be,_0x876bd5,_0x380e80,_0x6fb562){this['source']=_0xa24fec,this['pointerX']=_0x20c9bf,this['pointerY']=_0x1004be,this['meshUnderPointer']=_0x876bd5,this['sourceEvent']=_0x380e80,this['additionalData']=_0x6fb562;}return _0x2b3b6f['CreateNew']=function(_0x5e7f59,_0x3b4ed3,_0x80fc9){var _0x43036e=_0x5e7f59['getScene']();return new _0x2b3b6f(_0x5e7f59,_0x43036e['pointerX'],_0x43036e['pointerY'],_0x43036e['meshUnderPointer']||_0x5e7f59,_0x3b4ed3,_0x80fc9);},_0x2b3b6f['CreateNewFromSprite']=function(_0x56ea7e,_0x21f7c5,_0x33639d,_0x2771b2){return new _0x2b3b6f(_0x56ea7e,_0x21f7c5['pointerX'],_0x21f7c5['pointerY'],_0x21f7c5['meshUnderPointer'],_0x33639d,_0x2771b2);},_0x2b3b6f['CreateNewFromScene']=function(_0x22ac75,_0x3463d9){return new _0x2b3b6f(null,_0x22ac75['pointerX'],_0x22ac75['pointerY'],_0x22ac75['meshUnderPointer'],_0x3463d9);},_0x2b3b6f['CreateNewFromPrimitive']=function(_0x2e6b89,_0x42f673,_0x1197f5,_0x3f8178){return new _0x2b3b6f(_0x2e6b89,_0x42f673['x'],_0x42f673['y'],null,_0x1197f5,_0x3f8178);},_0x2b3b6f;}());},function(_0x14a59f,_0x483d89,_0x42e4c6){'use strict';_0x42e4c6['d'](_0x483d89,'a',function(){return _0x2584c6;});var _0x3651f9=_0x42e4c6(0x1),_0x2dc92b=_0x42e4c6(0x3),_0x2142cc=_0x42e4c6(0x0),_0xc6e127=_0x42e4c6(0x9),_0x343e5d=_0x42e4c6(0x1d),_0x50d6a8=_0x42e4c6(0x55),_0x455bd7=_0x42e4c6(0xb),_0x2584c6=function(_0xdfb116){function _0x5767f8(_0x3d3446,_0x4c4778){var _0x310140=_0xdfb116['call'](this,_0x3d3446,_0x4c4778)||this;return _0x310140['diffuse']=new _0xc6e127['a'](0x1,0x1,0x1),_0x310140['specular']=new _0xc6e127['a'](0x1,0x1,0x1),_0x310140['falloffType']=_0x5767f8['FALLOFF_DEFAULT'],_0x310140['intensity']=0x1,_0x310140['_range']=Number['MAX_VALUE'],_0x310140['_inverseSquaredRange']=0x0,_0x310140['_photometricScale']=0x1,_0x310140['_intensityMode']=_0x5767f8['INTENSITYMODE_AUTOMATIC'],_0x310140['_radius']=0.00001,_0x310140['renderPriority']=0x0,_0x310140['_shadowEnabled']=!0x0,_0x310140['_excludeWithLayerMask']=0x0,_0x310140['_includeOnlyWithLayerMask']=0x0,_0x310140['_lightmapMode']=0x0,_0x310140['_excludedMeshesIds']=new Array(),_0x310140['_includedOnlyMeshesIds']=new Array(),_0x310140['_isLight']=!0x0,_0x310140['getScene']()['addLight'](_0x310140),_0x310140['_uniformBuffer']=new _0x50d6a8['a'](_0x310140['getScene']()['getEngine']()),_0x310140['_buildUniformLayout'](),_0x310140['includedOnlyMeshes']=new Array(),_0x310140['excludedMeshes']=new Array(),_0x310140['_resyncMeshes'](),_0x310140;}return Object(_0x3651f9['d'])(_0x5767f8,_0xdfb116),Object['defineProperty'](_0x5767f8['prototype'],'range',{'get':function(){return this['_range'];},'set':function(_0x4fc2bd){this['_range']=_0x4fc2bd,this['_inverseSquaredRange']=0x1/(this['range']*this['range']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5767f8['prototype'],'intensityMode',{'get':function(){return this['_intensityMode'];},'set':function(_0x2b3436){this['_intensityMode']=_0x2b3436,this['_computePhotometricScale']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5767f8['prototype'],'radius',{'get':function(){return this['_radius'];},'set':function(_0x5c8584){this['_radius']=_0x5c8584,this['_computePhotometricScale']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5767f8['prototype'],'shadowEnabled',{'get':function(){return this['_shadowEnabled'];},'set':function(_0x3fa4b8){this['_shadowEnabled']!==_0x3fa4b8&&(this['_shadowEnabled']=_0x3fa4b8,this['_markMeshesAsLightDirty']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5767f8['prototype'],'includedOnlyMeshes',{'get':function(){return this['_includedOnlyMeshes'];},'set':function(_0x41b16b){this['_includedOnlyMeshes']=_0x41b16b,this['_hookArrayForIncludedOnly'](_0x41b16b);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5767f8['prototype'],'excludedMeshes',{'get':function(){return this['_excludedMeshes'];},'set':function(_0x722579){this['_excludedMeshes']=_0x722579,this['_hookArrayForExcluded'](_0x722579);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5767f8['prototype'],'excludeWithLayerMask',{'get':function(){return this['_excludeWithLayerMask'];},'set':function(_0x242190){this['_excludeWithLayerMask']=_0x242190,this['_resyncMeshes']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5767f8['prototype'],'includeOnlyWithLayerMask',{'get':function(){return this['_includeOnlyWithLayerMask'];},'set':function(_0x557b4a){this['_includeOnlyWithLayerMask']=_0x557b4a,this['_resyncMeshes']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5767f8['prototype'],'lightmapMode',{'get':function(){return this['_lightmapMode'];},'set':function(_0x47c7e1){this['_lightmapMode']!==_0x47c7e1&&(this['_lightmapMode']=_0x47c7e1,this['_markMeshesAsLightDirty']());},'enumerable':!0x1,'configurable':!0x0}),_0x5767f8['prototype']['transferTexturesToEffect']=function(_0x28a526,_0x1777d7){return this;},_0x5767f8['prototype']['_bindLight']=function(_0x7b8cb0,_0x3a1351,_0x2d6bfe,_0x1ba536,_0x1b3348){void 0x0===_0x1b3348&&(_0x1b3348=!0x1);var _0x3054d8=_0x7b8cb0['toString'](),_0x2b30b3=!0x1;if(!_0x1b3348||!this['_uniformBuffer']['_alreadyBound']){if(this['_uniformBuffer']['bindToEffect'](_0x2d6bfe,'Light'+_0x3054d8),this['_renderId']!==_0x3a1351['getRenderId']()||!this['_uniformBuffer']['useUbo']){this['_renderId']=_0x3a1351['getRenderId']();var _0x15422c=this['getScaledIntensity']();this['transferToEffect'](_0x2d6bfe,_0x3054d8),this['diffuse']['scaleToRef'](_0x15422c,_0xc6e127['c']['Color3'][0x0]),this['_uniformBuffer']['updateColor4']('vLightDiffuse',_0xc6e127['c']['Color3'][0x0],this['range'],_0x3054d8),_0x1ba536&&(this['specular']['scaleToRef'](_0x15422c,_0xc6e127['c']['Color3'][0x1]),this['_uniformBuffer']['updateColor4']('vLightSpecular',_0xc6e127['c']['Color3'][0x1],this['radius'],_0x3054d8)),_0x2b30b3=!0x0;}if(this['transferTexturesToEffect'](_0x2d6bfe,_0x3054d8),_0x3a1351['shadowsEnabled']&&this['shadowEnabled']){var _0x52e777=this['getShadowGenerator']();_0x52e777&&(_0x52e777['bindShadowLight'](_0x3054d8,_0x2d6bfe),_0x2b30b3=!0x0);}_0x2b30b3&&this['_uniformBuffer']['update']();}},_0x5767f8['prototype']['getClassName']=function(){return'Light';},_0x5767f8['prototype']['toString']=function(_0x1f6791){var _0x29c301='Name:\x20'+this['name'];if(_0x29c301+=',\x20type:\x20'+['Point','Directional','Spot','Hemispheric'][this['getTypeID']()],this['animations']){for(var _0x58408a=0x0;_0x58408a0x0&&-0x1===this['includedOnlyMeshes']['indexOf'](_0x3b3ba2))&&(!(this['excludedMeshes']&&this['excludedMeshes']['length']>0x0&&-0x1!==this['excludedMeshes']['indexOf'](_0x3b3ba2))&&((0x0===this['includeOnlyWithLayerMask']||0x0!=(this['includeOnlyWithLayerMask']&_0x3b3ba2['layerMask']))&&!(0x0!==this['excludeWithLayerMask']&&this['excludeWithLayerMask']&_0x3b3ba2['layerMask'])));},_0x5767f8['CompareLightsPriority']=function(_0x56f9b9,_0x4bb644){return _0x56f9b9['shadowEnabled']!==_0x4bb644['shadowEnabled']?(_0x4bb644['shadowEnabled']?0x1:0x0)-(_0x56f9b9['shadowEnabled']?0x1:0x0):_0x4bb644['renderPriority']-_0x56f9b9['renderPriority'];},_0x5767f8['prototype']['dispose']=function(_0x54d8db,_0x178d25){void 0x0===_0x178d25&&(_0x178d25=!0x1),this['_shadowGenerator']&&(this['_shadowGenerator']['dispose'](),this['_shadowGenerator']=null),this['getScene']()['stopAnimation'](this);for(var _0x3a2772=0x0,_0x22f292=this['getScene']()['meshes'];_0x3a2772<_0x22f292['length'];_0x3a2772++){_0x22f292[_0x3a2772]['_removeLightSource'](this,!0x0);}this['_uniformBuffer']['dispose'](),this['getScene']()['removeLight'](this),_0xdfb116['prototype']['dispose']['call'](this,_0x54d8db,_0x178d25);},_0x5767f8['prototype']['getTypeID']=function(){return 0x0;},_0x5767f8['prototype']['getScaledIntensity']=function(){return this['_photometricScale']*this['intensity'];},_0x5767f8['prototype']['clone']=function(_0x42ccf3,_0x45f970){void 0x0===_0x45f970&&(_0x45f970=null);var _0x1ae0d2=_0x5767f8['GetConstructorFromName'](this['getTypeID'](),_0x42ccf3,this['getScene']());if(!_0x1ae0d2)return null;var _0x383e3e=_0x2dc92b['a']['Clone'](_0x1ae0d2,this);return _0x45f970&&(_0x383e3e['parent']=_0x45f970),_0x383e3e['setEnabled'](this['isEnabled']()),_0x383e3e;},_0x5767f8['prototype']['serialize']=function(){var _0x21c2b0=_0x2dc92b['a']['Serialize'](this);return _0x21c2b0['type']=this['getTypeID'](),this['parent']&&(_0x21c2b0['parentId']=this['parent']['id']),this['excludedMeshes']['length']>0x0&&(_0x21c2b0['excludedMeshesIds']=[],this['excludedMeshes']['forEach'](function(_0x413b76){_0x21c2b0['excludedMeshesIds']['push'](_0x413b76['id']);})),this['includedOnlyMeshes']['length']>0x0&&(_0x21c2b0['includedOnlyMeshesIds']=[],this['includedOnlyMeshes']['forEach'](function(_0x4eac70){_0x21c2b0['includedOnlyMeshesIds']['push'](_0x4eac70['id']);})),_0x2dc92b['a']['AppendSerializedAnimations'](this,_0x21c2b0),_0x21c2b0['ranges']=this['serializeAnimationRanges'](),_0x21c2b0;},_0x5767f8['GetConstructorFromName']=function(_0x127239,_0x266a12,_0x1aa30d){var _0x33cba2=_0x343e5d['a']['Construct']('Light_Type_'+_0x127239,_0x266a12,_0x1aa30d);return _0x33cba2||null;},_0x5767f8['Parse']=function(_0x313128,_0x29ccbd){var _0x4a522d=_0x5767f8['GetConstructorFromName'](_0x313128['type'],_0x313128['name'],_0x29ccbd);if(!_0x4a522d)return null;var _0x3d4263=_0x2dc92b['a']['Parse'](_0x4a522d,_0x313128,_0x29ccbd);if(_0x313128['excludedMeshesIds']&&(_0x3d4263['_excludedMeshesIds']=_0x313128['excludedMeshesIds']),_0x313128['includedOnlyMeshesIds']&&(_0x3d4263['_includedOnlyMeshesIds']=_0x313128['includedOnlyMeshesIds']),_0x313128['parentId']&&(_0x3d4263['_waitingParentId']=_0x313128['parentId']),void 0x0!==_0x313128['falloffType']&&(_0x3d4263['falloffType']=_0x313128['falloffType']),void 0x0!==_0x313128['lightmapMode']&&(_0x3d4263['lightmapMode']=_0x313128['lightmapMode']),_0x313128['animations']){for(var _0x26a3ee=0x0;_0x26a3ee<_0x313128['animations']['length'];_0x26a3ee++){var _0x25cfc4=_0x313128['animations'][_0x26a3ee],_0x21bd12=_0x455bd7['a']['GetClass']('BABYLON.Animation');_0x21bd12&&_0x3d4263['animations']['push'](_0x21bd12['Parse'](_0x25cfc4));}_0x343e5d['a']['ParseAnimationRanges'](_0x3d4263,_0x313128,_0x29ccbd);}return _0x313128['autoAnimate']&&_0x29ccbd['beginAnimation'](_0x3d4263,_0x313128['autoAnimateFrom'],_0x313128['autoAnimateTo'],_0x313128['autoAnimateLoop'],_0x313128['autoAnimateSpeed']||0x1),_0x3d4263;},_0x5767f8['prototype']['_hookArrayForExcluded']=function(_0x3997ea){var _0x36510d=this,_0x2b3ea8=_0x3997ea['push'];_0x3997ea['push']=function(){for(var _0x2b973f=[],_0x2b17f4=0x0;_0x2b17f4=0x0&&this['_scene']['textures']['splice'](_0x3c7f01,0x1),this['_scene']['onTextureRemovedObservable']['notifyObservers'](this),this['_scene']=null;}this['onDisposeObservable']['notifyObservers'](this),this['onDisposeObservable']['clear'](),_0x29eef5['prototype']['dispose']['call'](this);},_0x562eb8['prototype']['serialize']=function(){if(!this['name'])return null;var _0x90bf61=_0x24537e['a']['Serialize'](this);return _0x24537e['a']['AppendSerializedAnimations'](this,_0x90bf61),_0x90bf61;},_0x562eb8['WhenAllReady']=function(_0x6ec4c8,_0x3d6239){var _0x3d88a1=_0x6ec4c8['length'];if(0x0!==_0x3d88a1)for(var _0x1c1f9e=0x0;_0x1c1f9e<_0x6ec4c8['length'];_0x1c1f9e++){var _0x24d9a7=_0x6ec4c8[_0x1c1f9e];if(_0x24d9a7['isReady']())0x0==--_0x3d88a1&&_0x3d6239();else{var _0xfb2365=_0x24d9a7['onLoadObservable'];_0xfb2365&&_0xfb2365['addOnce'](function(){0x0==--_0x3d88a1&&_0x3d6239();});}}else _0x3d6239();},_0x562eb8['_isScene']=function(_0x6c7e15){return'Scene'===_0x6c7e15['getClassName']();},_0x562eb8['DEFAULT_ANISOTROPIC_FILTERING_LEVEL']=0x4,Object(_0x226662['c'])([Object(_0x24537e['c'])()],_0x562eb8['prototype'],'uniqueId',void 0x0),Object(_0x226662['c'])([Object(_0x24537e['c'])()],_0x562eb8['prototype'],'name',void 0x0),Object(_0x226662['c'])([Object(_0x24537e['c'])()],_0x562eb8['prototype'],'metadata',void 0x0),Object(_0x226662['c'])([Object(_0x24537e['c'])('hasAlpha')],_0x562eb8['prototype'],'_hasAlpha',void 0x0),Object(_0x226662['c'])([Object(_0x24537e['c'])()],_0x562eb8['prototype'],'getAlphaFromRGB',void 0x0),Object(_0x226662['c'])([Object(_0x24537e['c'])()],_0x562eb8['prototype'],'level',void 0x0),Object(_0x226662['c'])([Object(_0x24537e['c'])()],_0x562eb8['prototype'],'coordinatesIndex',void 0x0),Object(_0x226662['c'])([Object(_0x24537e['c'])('coordinatesMode')],_0x562eb8['prototype'],'_coordinatesMode',void 0x0),Object(_0x226662['c'])([Object(_0x24537e['c'])()],_0x562eb8['prototype'],'wrapU',null),Object(_0x226662['c'])([Object(_0x24537e['c'])()],_0x562eb8['prototype'],'wrapV',null),Object(_0x226662['c'])([Object(_0x24537e['c'])()],_0x562eb8['prototype'],'wrapR',void 0x0),Object(_0x226662['c'])([Object(_0x24537e['c'])()],_0x562eb8['prototype'],'anisotropicFilteringLevel',void 0x0),Object(_0x226662['c'])([Object(_0x24537e['c'])()],_0x562eb8['prototype'],'isCube',null),Object(_0x226662['c'])([Object(_0x24537e['c'])()],_0x562eb8['prototype'],'is3D',null),Object(_0x226662['c'])([Object(_0x24537e['c'])()],_0x562eb8['prototype'],'is2DArray',null),Object(_0x226662['c'])([Object(_0x24537e['c'])()],_0x562eb8['prototype'],'gammaSpace',null),Object(_0x226662['c'])([Object(_0x24537e['c'])()],_0x562eb8['prototype'],'invertZ',void 0x0),Object(_0x226662['c'])([Object(_0x24537e['c'])()],_0x562eb8['prototype'],'lodLevelInAlpha',void 0x0),Object(_0x226662['c'])([Object(_0x24537e['c'])()],_0x562eb8['prototype'],'lodGenerationOffset',null),Object(_0x226662['c'])([Object(_0x24537e['c'])()],_0x562eb8['prototype'],'lodGenerationScale',null),Object(_0x226662['c'])([Object(_0x24537e['c'])()],_0x562eb8['prototype'],'linearSpecularLOD',null),Object(_0x226662['c'])([Object(_0x24537e['m'])()],_0x562eb8['prototype'],'irradianceTexture',null),Object(_0x226662['c'])([Object(_0x24537e['c'])()],_0x562eb8['prototype'],'isRenderTarget',void 0x0),_0x562eb8;}((function(){function _0x2729ea(_0x5c098e){this['_wrapU']=_0x47c1d5['a']['TEXTURE_WRAP_ADDRESSMODE'],this['_wrapV']=_0x47c1d5['a']['TEXTURE_WRAP_ADDRESSMODE'],this['wrapR']=_0x47c1d5['a']['TEXTURE_WRAP_ADDRESSMODE'],this['anisotropicFilteringLevel']=0x4,this['delayLoadState']=_0x47c1d5['a']['DELAYLOADSTATE_NONE'],this['_texture']=null,this['_engine']=null,this['_cachedSize']=_0x39273a['a']['Zero'](),this['_cachedBaseSize']=_0x39273a['a']['Zero'](),this['_texture']=_0x5c098e,this['_texture']&&(this['_engine']=this['_texture']['getEngine']());}return Object['defineProperty'](_0x2729ea['prototype'],'wrapU',{'get':function(){return this['_wrapU'];},'set':function(_0x9edfa6){this['_wrapU']=_0x9edfa6;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2729ea['prototype'],'wrapV',{'get':function(){return this['_wrapV'];},'set':function(_0x2e9bdd){this['_wrapV']=_0x2e9bdd;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2729ea['prototype'],'coordinatesMode',{'get':function(){return 0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2729ea['prototype'],'isCube',{'get':function(){return!!this['_texture']&&this['_texture']['isCube'];},'set':function(_0x545495){this['_texture']&&(this['_texture']['isCube']=_0x545495);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2729ea['prototype'],'is3D',{'get':function(){return!!this['_texture']&&this['_texture']['is3D'];},'set':function(_0x241a10){this['_texture']&&(this['_texture']['is3D']=_0x241a10);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2729ea['prototype'],'is2DArray',{'get':function(){return!!this['_texture']&&this['_texture']['is2DArray'];},'set':function(_0x4aa915){this['_texture']&&(this['_texture']['is2DArray']=_0x4aa915);},'enumerable':!0x1,'configurable':!0x0}),_0x2729ea['prototype']['getClassName']=function(){return'ThinTexture';},_0x2729ea['prototype']['isReady']=function(){return this['delayLoadState']===_0x47c1d5['a']['DELAYLOADSTATE_NOTLOADED']?(this['delayLoad'](),!0x1):!!this['_texture']&&this['_texture']['isReady'];},_0x2729ea['prototype']['delayLoad']=function(){},_0x2729ea['prototype']['getInternalTexture']=function(){return this['_texture'];},_0x2729ea['prototype']['getSize']=function(){if(this['_texture']){if(this['_texture']['width'])return this['_cachedSize']['width']=this['_texture']['width'],this['_cachedSize']['height']=this['_texture']['height'],this['_cachedSize'];if(this['_texture']['_size'])return this['_cachedSize']['width']=this['_texture']['_size'],this['_cachedSize']['height']=this['_texture']['_size'],this['_cachedSize'];}return this['_cachedSize'];},_0x2729ea['prototype']['getBaseSize']=function(){return this['isReady']()&&this['_texture']?this['_texture']['_size']?(this['_cachedBaseSize']['width']=this['_texture']['_size'],this['_cachedBaseSize']['height']=this['_texture']['_size'],this['_cachedBaseSize']):(this['_cachedBaseSize']['width']=this['_texture']['baseWidth'],this['_cachedBaseSize']['height']=this['_texture']['baseHeight'],this['_cachedBaseSize']):(this['_cachedBaseSize']['width']=0x0,this['_cachedBaseSize']['height']=0x0,this['_cachedBaseSize']);},_0x2729ea['prototype']['updateSamplingMode']=function(_0x5a38d6){this['_texture']&&this['_engine']&&this['_engine']['updateTextureSamplingMode'](_0x5a38d6,this['_texture']);},_0x2729ea['prototype']['releaseInternalTexture']=function(){this['_texture']&&(this['_texture']['dispose'](),this['_texture']=null);},_0x2729ea['prototype']['dispose']=function(){this['_texture']&&(this['releaseInternalTexture'](),this['_engine']=null);},_0x2729ea;}()));},function(_0xdfad47,_0x1755d7,_0x41b2ce){'use strict';_0x41b2ce['d'](_0x1755d7,'a',function(){return _0x8a3e5a;});var _0x13cc54=_0x41b2ce(0x0),_0x18efd7=_0x41b2ce(0x9),_0x59e013=_0x41b2ce(0x7),_0x5eadce=_0x41b2ce(0x10),_0xa0c5db=_0x41b2ce(0x14),_0x472179=_0x41b2ce(0x17);_0x5eadce['a']['CreateCylinder']=function(_0x5b55b4){var _0x4a9423=_0x5b55b4['height']||0x2,_0x5d9007=0x0===_0x5b55b4['diameterTop']?0x0:_0x5b55b4['diameterTop']||_0x5b55b4['diameter']||0x1,_0x9308d=0x0===_0x5b55b4['diameterBottom']?0x0:_0x5b55b4['diameterBottom']||_0x5b55b4['diameter']||0x1;_0x5d9007=_0x5d9007||0.00001,_0x9308d=_0x9308d||0.00001;var _0x19c471,_0x500747=_0x5b55b4['tessellation']||0x18,_0x2cff2a=_0x5b55b4['subdivisions']||0x1,_0x5b37ab=!!_0x5b55b4['hasRings'],_0x4b7cd1=!!_0x5b55b4['enclose'],_0x4e0ed3=0x0===_0x5b55b4['cap']?0x0:_0x5b55b4['cap']||_0x59e013['a']['CAP_ALL'],_0x320b6=_0x5b55b4['arc']&&(_0x5b55b4['arc']<=0x0||_0x5b55b4['arc']>0x1)?0x1:_0x5b55b4['arc']||0x1,_0x204e06=0x0===_0x5b55b4['sideOrientation']?0x0:_0x5b55b4['sideOrientation']||_0x5eadce['a']['DEFAULTSIDE'],_0x1ab485=_0x5b55b4['faceUV']||new Array(0x3),_0xe45eb9=_0x5b55b4['faceColors'],_0x4df44c=0x2+(0x1+(0x1!==_0x320b6&&_0x4b7cd1?0x2:0x0))*(_0x5b37ab?_0x2cff2a:0x1);for(_0x19c471=0x0;_0x19c471<_0x4df44c;_0x19c471++)_0xe45eb9&&void 0x0===_0xe45eb9[_0x19c471]&&(_0xe45eb9[_0x19c471]=new _0x18efd7['b'](0x1,0x1,0x1,0x1));for(_0x19c471=0x0;_0x19c471<_0x4df44c;_0x19c471++)_0x1ab485&&void 0x0===_0x1ab485[_0x19c471]&&(_0x1ab485[_0x19c471]=new _0x13cc54['f'](0x0,0x0,0x1,0x1));var _0x248343,_0x4fa017,_0x9105a2,_0x2669b5,_0x369a69,_0x215baa,_0x3c699c=new Array(),_0x17fa97=new Array(),_0x3455e0=new Array(),_0x2ad3d8=new Array(),_0x218036=new Array(),_0x2f1e6a=0x2*Math['PI']*_0x320b6/_0x500747,_0x1bb0c1=(_0x9308d-_0x5d9007)/0x2/_0x4a9423,_0xbfc771=_0x13cc54['e']['Zero'](),_0x173124=_0x13cc54['e']['Zero'](),_0x5450f9=_0x13cc54['e']['Zero'](),_0x3e9c7f=_0x13cc54['e']['Zero'](),_0x4f1de3=_0x13cc54['e']['Zero'](),_0x5d3ee1=_0x472179['a']['Y'],_0x350458=0x1,_0x3f1b7c=0x1,_0x2fbc2a=0x0,_0xafa38c=0x0;for(_0x2669b5=0x0;_0x2669b5<=_0x2cff2a;_0x2669b5++)for(_0x9105a2=((_0x4fa017=_0x2669b5/_0x2cff2a)*(_0x5d9007-_0x9308d)+_0x9308d)/0x2,_0x350458=_0x5b37ab&&0x0!==_0x2669b5&&_0x2669b5!==_0x2cff2a?0x2:0x1,_0x215baa=0x0;_0x215baa<_0x350458;_0x215baa++){for(_0x5b37ab&&(_0x3f1b7c+=_0x215baa),_0x4b7cd1&&(_0x3f1b7c+=0x2*_0x215baa),_0x369a69=0x0;_0x369a69<=_0x500747;_0x369a69++)_0x248343=_0x369a69*_0x2f1e6a,_0xbfc771['x']=Math['cos'](-_0x248343)*_0x9105a2,_0xbfc771['y']=-_0x4a9423/0x2+_0x4fa017*_0x4a9423,_0xbfc771['z']=Math['sin'](-_0x248343)*_0x9105a2,0x0===_0x5d9007&&_0x2669b5===_0x2cff2a?(_0x173124['x']=_0x3455e0[_0x3455e0['length']-0x3*(_0x500747+0x1)],_0x173124['y']=_0x3455e0[_0x3455e0['length']-0x3*(_0x500747+0x1)+0x1],_0x173124['z']=_0x3455e0[_0x3455e0['length']-0x3*(_0x500747+0x1)+0x2]):(_0x173124['x']=_0xbfc771['x'],_0x173124['z']=_0xbfc771['z'],_0x173124['y']=Math['sqrt'](_0x173124['x']*_0x173124['x']+_0x173124['z']*_0x173124['z'])*_0x1bb0c1,_0x173124['normalize']()),0x0===_0x369a69&&(_0x5450f9['copyFrom'](_0xbfc771),_0x3e9c7f['copyFrom'](_0x173124)),_0x17fa97['push'](_0xbfc771['x'],_0xbfc771['y'],_0xbfc771['z']),_0x3455e0['push'](_0x173124['x'],_0x173124['y'],_0x173124['z']),_0xafa38c=_0x5b37ab?_0x2fbc2a!==_0x3f1b7c?_0x1ab485[_0x3f1b7c]['y']:_0x1ab485[_0x3f1b7c]['w']:_0x1ab485[_0x3f1b7c]['y']+(_0x1ab485[_0x3f1b7c]['w']-_0x1ab485[_0x3f1b7c]['y'])*_0x4fa017,_0x2ad3d8['push'](_0x1ab485[_0x3f1b7c]['x']+(_0x1ab485[_0x3f1b7c]['z']-_0x1ab485[_0x3f1b7c]['x'])*_0x369a69/_0x500747,_0xafa38c),_0xe45eb9&&_0x218036['push'](_0xe45eb9[_0x3f1b7c]['r'],_0xe45eb9[_0x3f1b7c]['g'],_0xe45eb9[_0x3f1b7c]['b'],_0xe45eb9[_0x3f1b7c]['a']);0x1!==_0x320b6&&_0x4b7cd1&&(_0x17fa97['push'](_0xbfc771['x'],_0xbfc771['y'],_0xbfc771['z']),_0x17fa97['push'](0x0,_0xbfc771['y'],0x0),_0x17fa97['push'](0x0,_0xbfc771['y'],0x0),_0x17fa97['push'](_0x5450f9['x'],_0x5450f9['y'],_0x5450f9['z']),_0x13cc54['e']['CrossToRef'](_0x5d3ee1,_0x173124,_0x4f1de3),_0x4f1de3['normalize'](),_0x3455e0['push'](_0x4f1de3['x'],_0x4f1de3['y'],_0x4f1de3['z'],_0x4f1de3['x'],_0x4f1de3['y'],_0x4f1de3['z']),_0x13cc54['e']['CrossToRef'](_0x3e9c7f,_0x5d3ee1,_0x4f1de3),_0x4f1de3['normalize'](),_0x3455e0['push'](_0x4f1de3['x'],_0x4f1de3['y'],_0x4f1de3['z'],_0x4f1de3['x'],_0x4f1de3['y'],_0x4f1de3['z']),_0xafa38c=_0x5b37ab?_0x2fbc2a!==_0x3f1b7c?_0x1ab485[_0x3f1b7c+0x1]['y']:_0x1ab485[_0x3f1b7c+0x1]['w']:_0x1ab485[_0x3f1b7c+0x1]['y']+(_0x1ab485[_0x3f1b7c+0x1]['w']-_0x1ab485[_0x3f1b7c+0x1]['y'])*_0x4fa017,_0x2ad3d8['push'](_0x1ab485[_0x3f1b7c+0x1]['x'],_0xafa38c),_0x2ad3d8['push'](_0x1ab485[_0x3f1b7c+0x1]['z'],_0xafa38c),_0xafa38c=_0x5b37ab?_0x2fbc2a!==_0x3f1b7c?_0x1ab485[_0x3f1b7c+0x2]['y']:_0x1ab485[_0x3f1b7c+0x2]['w']:_0x1ab485[_0x3f1b7c+0x2]['y']+(_0x1ab485[_0x3f1b7c+0x2]['w']-_0x1ab485[_0x3f1b7c+0x2]['y'])*_0x4fa017,_0x2ad3d8['push'](_0x1ab485[_0x3f1b7c+0x2]['x'],_0xafa38c),_0x2ad3d8['push'](_0x1ab485[_0x3f1b7c+0x2]['z'],_0xafa38c),_0xe45eb9&&(_0x218036['push'](_0xe45eb9[_0x3f1b7c+0x1]['r'],_0xe45eb9[_0x3f1b7c+0x1]['g'],_0xe45eb9[_0x3f1b7c+0x1]['b'],_0xe45eb9[_0x3f1b7c+0x1]['a']),_0x218036['push'](_0xe45eb9[_0x3f1b7c+0x1]['r'],_0xe45eb9[_0x3f1b7c+0x1]['g'],_0xe45eb9[_0x3f1b7c+0x1]['b'],_0xe45eb9[_0x3f1b7c+0x1]['a']),_0x218036['push'](_0xe45eb9[_0x3f1b7c+0x2]['r'],_0xe45eb9[_0x3f1b7c+0x2]['g'],_0xe45eb9[_0x3f1b7c+0x2]['b'],_0xe45eb9[_0x3f1b7c+0x2]['a']),_0x218036['push'](_0xe45eb9[_0x3f1b7c+0x2]['r'],_0xe45eb9[_0x3f1b7c+0x2]['g'],_0xe45eb9[_0x3f1b7c+0x2]['b'],_0xe45eb9[_0x3f1b7c+0x2]['a']))),_0x2fbc2a!==_0x3f1b7c&&(_0x2fbc2a=_0x3f1b7c);}var _0x4a7c65=0x1!==_0x320b6&&_0x4b7cd1?_0x500747+0x4:_0x500747;for(_0x2669b5=0x0,_0x3f1b7c=0x0;_0x3f1b7c<_0x2cff2a;_0x3f1b7c++){var _0x447276=0x0,_0x421d3b=0x0,_0x4f2942=0x0,_0x583dfe=0x0;for(_0x369a69=0x0;_0x369a69<_0x500747;_0x369a69++)_0x447276=_0x2669b5*(_0x4a7c65+0x1)+_0x369a69,_0x421d3b=(_0x2669b5+0x1)*(_0x4a7c65+0x1)+_0x369a69,_0x4f2942=_0x2669b5*(_0x4a7c65+0x1)+(_0x369a69+0x1),_0x583dfe=(_0x2669b5+0x1)*(_0x4a7c65+0x1)+(_0x369a69+0x1),_0x3c699c['push'](_0x447276,_0x421d3b,_0x4f2942),_0x3c699c['push'](_0x583dfe,_0x4f2942,_0x421d3b);0x1!==_0x320b6&&_0x4b7cd1&&(_0x3c699c['push'](_0x447276+0x2,_0x421d3b+0x2,_0x4f2942+0x2),_0x3c699c['push'](_0x583dfe+0x2,_0x4f2942+0x2,_0x421d3b+0x2),_0x3c699c['push'](_0x447276+0x4,_0x421d3b+0x4,_0x4f2942+0x4),_0x3c699c['push'](_0x583dfe+0x4,_0x4f2942+0x4,_0x421d3b+0x4)),_0x2669b5=_0x5b37ab?_0x2669b5+0x2:_0x2669b5+0x1;}var _0x2ce95c=function(_0x1cb8ab){var _0x183616=_0x1cb8ab?_0x5d9007/0x2:_0x9308d/0x2;if(0x0!==_0x183616){var _0x11b2f1,_0xd09087,_0x4abda2,_0x576220=_0x1cb8ab?_0x1ab485[_0x4df44c-0x1]:_0x1ab485[0x0],_0x25dc3f=null;_0xe45eb9&&(_0x25dc3f=_0x1cb8ab?_0xe45eb9[_0x4df44c-0x1]:_0xe45eb9[0x0]);var _0x12ad42=_0x17fa97['length']/0x3,_0x2cbbd0=_0x1cb8ab?_0x4a9423/0x2:-_0x4a9423/0x2,_0x2d7454=new _0x13cc54['e'](0x0,_0x2cbbd0,0x0);_0x17fa97['push'](_0x2d7454['x'],_0x2d7454['y'],_0x2d7454['z']),_0x3455e0['push'](0x0,_0x1cb8ab?0x1:-0x1,0x0),_0x2ad3d8['push'](_0x576220['x']+0.5*(_0x576220['z']-_0x576220['x']),_0x576220['y']+0.5*(_0x576220['w']-_0x576220['y'])),_0x25dc3f&&_0x218036['push'](_0x25dc3f['r'],_0x25dc3f['g'],_0x25dc3f['b'],_0x25dc3f['a']);var _0x228d5c=new _0x13cc54['d'](0.5,0.5);for(_0x4abda2=0x0;_0x4abda2<=_0x500747;_0x4abda2++){_0x11b2f1=0x2*Math['PI']*_0x4abda2*_0x320b6/_0x500747;var _0x2cf2be=Math['cos'](-_0x11b2f1),_0x10074c=Math['sin'](-_0x11b2f1);_0xd09087=new _0x13cc54['e'](_0x2cf2be*_0x183616,_0x2cbbd0,_0x10074c*_0x183616);var _0x106ac2=new _0x13cc54['d'](_0x2cf2be*_0x228d5c['x']+0.5,_0x10074c*_0x228d5c['y']+0.5);_0x17fa97['push'](_0xd09087['x'],_0xd09087['y'],_0xd09087['z']),_0x3455e0['push'](0x0,_0x1cb8ab?0x1:-0x1,0x0),_0x2ad3d8['push'](_0x576220['x']+(_0x576220['z']-_0x576220['x'])*_0x106ac2['x'],_0x576220['y']+(_0x576220['w']-_0x576220['y'])*_0x106ac2['y']),_0x25dc3f&&_0x218036['push'](_0x25dc3f['r'],_0x25dc3f['g'],_0x25dc3f['b'],_0x25dc3f['a']);}for(_0x4abda2=0x0;_0x4abda2<_0x500747;_0x4abda2++)_0x1cb8ab?(_0x3c699c['push'](_0x12ad42),_0x3c699c['push'](_0x12ad42+(_0x4abda2+0x2)),_0x3c699c['push'](_0x12ad42+(_0x4abda2+0x1))):(_0x3c699c['push'](_0x12ad42),_0x3c699c['push'](_0x12ad42+(_0x4abda2+0x1)),_0x3c699c['push'](_0x12ad42+(_0x4abda2+0x2)));}};_0x4e0ed3!==_0x59e013['a']['CAP_START']&&_0x4e0ed3!==_0x59e013['a']['CAP_ALL']||_0x2ce95c(!0x1),_0x4e0ed3!==_0x59e013['a']['CAP_END']&&_0x4e0ed3!==_0x59e013['a']['CAP_ALL']||_0x2ce95c(!0x0),_0x5eadce['a']['_ComputeSides'](_0x204e06,_0x17fa97,_0x3c699c,_0x3455e0,_0x2ad3d8,_0x5b55b4['frontUVs'],_0x5b55b4['backUVs']);var _0x16d4a0=new _0x5eadce['a']();return _0x16d4a0['indices']=_0x3c699c,_0x16d4a0['positions']=_0x17fa97,_0x16d4a0['normals']=_0x3455e0,_0x16d4a0['uvs']=_0x2ad3d8,_0xe45eb9&&(_0x16d4a0['colors']=_0x218036),_0x16d4a0;},_0x59e013['a']['CreateCylinder']=function(_0x231138,_0x1362b8,_0x16fc56,_0x5a7fdf,_0x345d12,_0x50674b,_0x41a329,_0x350295,_0x51162){void 0x0!==_0x41a329&&_0x41a329 instanceof _0xa0c5db['a']||(void 0x0!==_0x41a329&&(_0x51162=_0x350295||_0x59e013['a']['DEFAULTSIDE'],_0x350295=_0x41a329),_0x41a329=_0x50674b,_0x50674b=0x1);var _0x5a42ac={'height':_0x1362b8,'diameterTop':_0x16fc56,'diameterBottom':_0x5a7fdf,'tessellation':_0x345d12,'subdivisions':_0x50674b,'sideOrientation':_0x51162,'updatable':_0x350295};return _0x8a3e5a['CreateCylinder'](_0x231138,_0x5a42ac,_0x41a329);};var _0x8a3e5a=(function(){function _0x560c7a(){}return _0x560c7a['CreateCylinder']=function(_0x2c0e82,_0x38b9f1,_0x5e05cb){var _0x55818b=new _0x59e013['a'](_0x2c0e82,_0x5e05cb);return _0x38b9f1['sideOrientation']=_0x59e013['a']['_GetDefaultSideOrientation'](_0x38b9f1['sideOrientation']),_0x55818b['_originalBuilderSideOrientation']=_0x38b9f1['sideOrientation'],_0x5eadce['a']['CreateCylinder'](_0x38b9f1)['applyToMesh'](_0x55818b,_0x38b9f1['updatable']),_0x55818b;},_0x560c7a;}());},function(_0x382a2d,_0x566c74,_0xffdc35){'use strict';_0xffdc35['d'](_0x566c74,'a',function(){return _0x2b082d;});var _0x18f9b7=_0xffdc35(0x0),_0x3b38df=_0xffdc35(0x4),_0x2b082d=(function(){function _0x5765ab(){this['_pickingUnavailable']=!0x1,this['hit']=!0x1,this['distance']=0x0,this['pickedPoint']=null,this['pickedMesh']=null,this['bu']=0x0,this['bv']=0x0,this['faceId']=-0x1,this['subMeshFaceId']=-0x1,this['subMeshId']=0x0,this['pickedSprite']=null,this['thinInstanceIndex']=-0x1,this['originMesh']=null,this['ray']=null;}return _0x5765ab['prototype']['getNormal']=function(_0x55d39e,_0x36cee1){if(void 0x0===_0x55d39e&&(_0x55d39e=!0x1),void 0x0===_0x36cee1&&(_0x36cee1=!0x0),!this['pickedMesh']||!this['pickedMesh']['isVerticesDataPresent'](_0x3b38df['b']['NormalKind']))return null;var _0x375106,_0x3e5bb6=this['pickedMesh']['getIndices']();if(!_0x3e5bb6)return null;if(_0x36cee1){var _0x9f2de1=this['pickedMesh']['getVerticesData'](_0x3b38df['b']['NormalKind']),_0x16fc31=_0x18f9b7['e']['FromArray'](_0x9f2de1,0x3*_0x3e5bb6[0x3*this['faceId']]),_0xcd85fe=_0x18f9b7['e']['FromArray'](_0x9f2de1,0x3*_0x3e5bb6[0x3*this['faceId']+0x1]),_0x595ea2=_0x18f9b7['e']['FromArray'](_0x9f2de1,0x3*_0x3e5bb6[0x3*this['faceId']+0x2]);_0x16fc31=_0x16fc31['scale'](this['bu']),_0xcd85fe=_0xcd85fe['scale'](this['bv']),_0x595ea2=_0x595ea2['scale'](0x1-this['bu']-this['bv']),_0x375106=new _0x18f9b7['e'](_0x16fc31['x']+_0xcd85fe['x']+_0x595ea2['x'],_0x16fc31['y']+_0xcd85fe['y']+_0x595ea2['y'],_0x16fc31['z']+_0xcd85fe['z']+_0x595ea2['z']);}else{var _0x4776d6=this['pickedMesh']['getVerticesData'](_0x3b38df['b']['PositionKind']),_0x5509d7=_0x18f9b7['e']['FromArray'](_0x4776d6,0x3*_0x3e5bb6[0x3*this['faceId']]),_0x227b60=_0x18f9b7['e']['FromArray'](_0x4776d6,0x3*_0x3e5bb6[0x3*this['faceId']+0x1]),_0x3a6971=_0x18f9b7['e']['FromArray'](_0x4776d6,0x3*_0x3e5bb6[0x3*this['faceId']+0x2]),_0x450cdd=_0x5509d7['subtract'](_0x227b60),_0x23b3a4=_0x3a6971['subtract'](_0x227b60);_0x375106=_0x18f9b7['e']['Cross'](_0x450cdd,_0x23b3a4);}if(_0x55d39e){var _0x18f934=this['pickedMesh']['getWorldMatrix']();this['pickedMesh']['nonUniformScaling']&&(_0x18f9b7['c']['Matrix'][0x0]['copyFrom'](_0x18f934),(_0x18f934=_0x18f9b7['c']['Matrix'][0x0])['setTranslationFromFloats'](0x0,0x0,0x0),_0x18f934['invert'](),_0x18f934['transposeToRef'](_0x18f9b7['c']['Matrix'][0x1]),_0x18f934=_0x18f9b7['c']['Matrix'][0x1]),_0x375106=_0x18f9b7['e']['TransformNormal'](_0x375106,_0x18f934);}return _0x375106['normalize'](),_0x375106;},_0x5765ab['prototype']['getTextureCoordinates']=function(){if(!this['pickedMesh']||!this['pickedMesh']['isVerticesDataPresent'](_0x3b38df['b']['UVKind']))return null;var _0x40a1ba=this['pickedMesh']['getIndices']();if(!_0x40a1ba)return null;var _0x3b0d52=this['pickedMesh']['getVerticesData'](_0x3b38df['b']['UVKind']);if(!_0x3b0d52)return null;var _0x221e3f=_0x18f9b7['d']['FromArray'](_0x3b0d52,0x2*_0x40a1ba[0x3*this['faceId']]),_0x3f50be=_0x18f9b7['d']['FromArray'](_0x3b0d52,0x2*_0x40a1ba[0x3*this['faceId']+0x1]),_0x48074b=_0x18f9b7['d']['FromArray'](_0x3b0d52,0x2*_0x40a1ba[0x3*this['faceId']+0x2]);return _0x221e3f=_0x221e3f['scale'](this['bu']),_0x3f50be=_0x3f50be['scale'](this['bv']),_0x48074b=_0x48074b['scale'](0x1-this['bu']-this['bv']),new _0x18f9b7['d'](_0x221e3f['x']+_0x3f50be['x']+_0x48074b['x'],_0x221e3f['y']+_0x3f50be['y']+_0x48074b['y']);},_0x5765ab;}());},function(_0x199b54,_0x415952,_0x1261ac){'use strict';_0x1261ac['d'](_0x415952,'a',function(){return _0x388228;});var _0x528cfd=_0x1261ac(0x39),_0x388228=(function(){function _0x3841f6(){this['_startMonitoringTime']=0x0,this['_min']=0x0,this['_max']=0x0,this['_average']=0x0,this['_lastSecAverage']=0x0,this['_current']=0x0,this['_totalValueCount']=0x0,this['_totalAccumulated']=0x0,this['_lastSecAccumulated']=0x0,this['_lastSecTime']=0x0,this['_lastSecValueCount']=0x0;}return Object['defineProperty'](_0x3841f6['prototype'],'min',{'get':function(){return this['_min'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3841f6['prototype'],'max',{'get':function(){return this['_max'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3841f6['prototype'],'average',{'get':function(){return this['_average'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3841f6['prototype'],'lastSecAverage',{'get':function(){return this['_lastSecAverage'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3841f6['prototype'],'current',{'get':function(){return this['_current'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3841f6['prototype'],'total',{'get':function(){return this['_totalAccumulated'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3841f6['prototype'],'count',{'get':function(){return this['_totalValueCount'];},'enumerable':!0x1,'configurable':!0x0}),_0x3841f6['prototype']['fetchNewFrame']=function(){this['_totalValueCount']++,this['_current']=0x0,this['_lastSecValueCount']++;},_0x3841f6['prototype']['addCount']=function(_0x5c5bb5,_0x369514){_0x3841f6['Enabled']&&(this['_current']+=_0x5c5bb5,_0x369514&&this['_fetchResult']());},_0x3841f6['prototype']['beginMonitoring']=function(){_0x3841f6['Enabled']&&(this['_startMonitoringTime']=_0x528cfd['a']['Now']);},_0x3841f6['prototype']['endMonitoring']=function(_0x55231e){if(void 0x0===_0x55231e&&(_0x55231e=!0x0),_0x3841f6['Enabled']){_0x55231e&&this['fetchNewFrame']();var _0xc94e53=_0x528cfd['a']['Now'];this['_current']=_0xc94e53-this['_startMonitoringTime'],_0x55231e&&this['_fetchResult']();}},_0x3841f6['prototype']['_fetchResult']=function(){this['_totalAccumulated']+=this['_current'],this['_lastSecAccumulated']+=this['_current'],this['_min']=Math['min'](this['_min'],this['_current']),this['_max']=Math['max'](this['_max'],this['_current']),this['_average']=this['_totalAccumulated']/this['_totalValueCount'];var _0x4ccf38=_0x528cfd['a']['Now'];_0x4ccf38-this['_lastSecTime']>0x3e8&&(this['_lastSecAverage']=this['_lastSecAccumulated']/this['_lastSecValueCount'],this['_lastSecTime']=_0x4ccf38,this['_lastSecAccumulated']=0x0,this['_lastSecValueCount']=0x0);},_0x3841f6['Enabled']=!0x0,_0x3841f6;}());},function(_0x390da3,_0x3a33cc,_0x5559d0){'use strict';_0x5559d0['d'](_0x3a33cc,'b',function(){return _0x5f1ca5;}),_0x5559d0['d'](_0x3a33cc,'d',function(){return _0x5852b7;}),_0x5559d0['d'](_0x3a33cc,'c',function(){return _0xff151b;}),_0x5559d0['d'](_0x3a33cc,'a',function(){return _0x5b8662;});var _0xe8b265=_0x5559d0(0x1),_0x181c2e=_0x5559d0(0x31),_0x2dbda8=_0x5559d0(0x26),_0x27430d=_0x5559d0(0x6),_0x440a05=_0x5559d0(0x53),_0x190a6e=_0x5559d0(0x8c),_0xd1d05e=function(_0x182d5f){function _0x7e84ce(){return null!==_0x182d5f&&_0x182d5f['apply'](this,arguments)||this;}return Object(_0xe8b265['d'])(_0x7e84ce,_0x182d5f),_0x7e84ce['_setPrototypeOf']=Object['setPrototypeOf']||function(_0x2fe23b,_0x3b8a58){return _0x2fe23b['__proto__']=_0x3b8a58,_0x2fe23b;},_0x7e84ce;}(Error),_0x246e80=_0x5559d0(0x22),_0x8955a7=_0x5559d0(0x1a),_0x36acf0=_0x5559d0(0x80),_0x5f1ca5=function(_0x493d7e){function _0x380acb(_0x51cc1f,_0x599c26){var _0x4bf69a=_0x493d7e['call'](this,_0x51cc1f)||this;return _0x4bf69a['name']='LoadFileError',_0xd1d05e['_setPrototypeOf'](_0x4bf69a,_0x380acb['prototype']),_0x599c26 instanceof _0x181c2e['a']?_0x4bf69a['request']=_0x599c26:_0x4bf69a['file']=_0x599c26,_0x4bf69a;}return Object(_0xe8b265['d'])(_0x380acb,_0x493d7e),_0x380acb;}(_0xd1d05e),_0x5852b7=function(_0x57dcd7){function _0x33534d(_0x24f7d2,_0x599e9f){var _0x4335e7=_0x57dcd7['call'](this,_0x24f7d2)||this;return _0x4335e7['request']=_0x599e9f,_0x4335e7['name']='RequestFileError',_0xd1d05e['_setPrototypeOf'](_0x4335e7,_0x33534d['prototype']),_0x4335e7;}return Object(_0xe8b265['d'])(_0x33534d,_0x57dcd7),_0x33534d;}(_0xd1d05e),_0xff151b=function(_0x2e094d){function _0x346dd7(_0x4811e1,_0xed5e97){var _0x10a03b=_0x2e094d['call'](this,_0x4811e1)||this;return _0x10a03b['file']=_0xed5e97,_0x10a03b['name']='ReadFileError',_0xd1d05e['_setPrototypeOf'](_0x10a03b,_0x346dd7['prototype']),_0x10a03b;}return Object(_0xe8b265['d'])(_0x346dd7,_0x2e094d),_0x346dd7;}(_0xd1d05e),_0x5b8662=(function(){function _0xd3c2bc(){}return _0xd3c2bc['_CleanUrl']=function(_0x1034ef){return _0x1034ef=_0x1034ef['replace'](/#/gm,'%23');},_0xd3c2bc['SetCorsBehavior']=function(_0x328df6,_0x1cd88c){if((!_0x328df6||0x0!==_0x328df6['indexOf']('data:'))&&_0xd3c2bc['CorsBehavior']){if('string'==typeof _0xd3c2bc['CorsBehavior']||this['CorsBehavior']instanceof String)_0x1cd88c['crossOrigin']=_0xd3c2bc['CorsBehavior'];else{var _0x587fe9=_0xd3c2bc['CorsBehavior'](_0x328df6);_0x587fe9&&(_0x1cd88c['crossOrigin']=_0x587fe9);}}},_0xd3c2bc['LoadImage']=function(_0x4e9475,_0x39d944,_0x1beeef,_0xc31c46,_0x2cea6b){var _0x34deea;void 0x0===_0x2cea6b&&(_0x2cea6b='');var _0x183fb5=!0x1;if(_0x4e9475 instanceof ArrayBuffer||ArrayBuffer['isView'](_0x4e9475)?'undefined'!=typeof Blob?(_0x34deea=URL['createObjectURL'](new Blob([_0x4e9475],{'type':_0x2cea6b})),_0x183fb5=!0x0):_0x34deea='data:'+_0x2cea6b+';base64,'+_0x246e80['a']['EncodeArrayBufferToBase64'](_0x4e9475):_0x4e9475 instanceof Blob?(_0x34deea=URL['createObjectURL'](_0x4e9475),_0x183fb5=!0x0):(_0x34deea=_0xd3c2bc['_CleanUrl'](_0x4e9475),_0x34deea=_0xd3c2bc['PreprocessUrl'](_0x4e9475)),'undefined'==typeof Image)return _0xd3c2bc['LoadFile'](_0x34deea,function(_0x2a2cb5){createImageBitmap(new Blob([_0x2a2cb5],{'type':_0x2cea6b}))['then'](function(_0x240c89){_0x39d944(_0x240c89),_0x183fb5&&URL['revokeObjectURL'](_0x34deea);})['catch'](function(_0x92e72a){_0x1beeef&&_0x1beeef('Error\x20while\x20trying\x20to\x20load\x20image:\x20'+_0x4e9475,_0x92e72a);});},void 0x0,_0xc31c46||void 0x0,!0x0,function(_0x4a17fe,_0x201b6d){_0x1beeef&&_0x1beeef('Error\x20while\x20trying\x20to\x20load\x20image:\x20'+_0x4e9475,_0x201b6d);}),null;var _0x378b10=new Image();_0xd3c2bc['SetCorsBehavior'](_0x34deea,_0x378b10);var _0x38f166=function(){_0x378b10['removeEventListener']('load',_0x38f166),_0x378b10['removeEventListener']('error',_0x11c53c),_0x39d944(_0x378b10),_0x183fb5&&_0x378b10['src']&&URL['revokeObjectURL'](_0x378b10['src']);},_0x11c53c=function(_0x12d0fd){if(_0x378b10['removeEventListener']('load',_0x38f166),_0x378b10['removeEventListener']('error',_0x11c53c),_0x1beeef){var _0x1e3636=_0x4e9475['toString']();_0x1beeef('Error\x20while\x20trying\x20to\x20load\x20image:\x20'+(_0x1e3636['length']<0x20?_0x1e3636:_0x1e3636['slice'](0x0,0x20)+'...'),_0x12d0fd);}_0x183fb5&&_0x378b10['src']&&URL['revokeObjectURL'](_0x378b10['src']);};_0x378b10['addEventListener']('load',_0x38f166),_0x378b10['addEventListener']('error',_0x11c53c);var _0x3cb87e=function(){_0x378b10['src']=_0x34deea;};if('data:'!==_0x34deea['substr'](0x0,0x5)&&_0xc31c46&&_0xc31c46['enableTexturesOffline'])_0xc31c46['open'](function(){_0xc31c46&&_0xc31c46['loadImage'](_0x34deea,_0x378b10);},_0x3cb87e);else{if(-0x1!==_0x34deea['indexOf']('file:')){var _0x49b2c2=decodeURIComponent(_0x34deea['substring'](0x5)['toLowerCase']());if(_0x440a05['a']['FilesToLoad'][_0x49b2c2]){try{var _0x1e9e62;try{_0x1e9e62=URL['createObjectURL'](_0x440a05['a']['FilesToLoad'][_0x49b2c2]);}catch(_0x254adb){_0x1e9e62=URL['createObjectURL'](_0x440a05['a']['FilesToLoad'][_0x49b2c2]);}_0x378b10['src']=_0x1e9e62,_0x183fb5=!0x0;}catch(_0x11527c){_0x378b10['src']='';}return _0x378b10;}}_0x3cb87e();}return _0x378b10;},_0xd3c2bc['ReadFile']=function(_0x4935f1,_0x2b09ed,_0x32db03,_0x182426,_0x529d8a){var _0x1c5c68=new FileReader(),_0x5a5e0c={'onCompleteObservable':new _0x27430d['c'](),'abort':function(){return _0x1c5c68['abort']();}};return _0x1c5c68['onloadend']=function(_0x1e60a5){return _0x5a5e0c['onCompleteObservable']['notifyObservers'](_0x5a5e0c);},_0x529d8a&&(_0x1c5c68['onerror']=function(_0x4ac60c){_0x529d8a(new _0xff151b('Unable\x20to\x20read\x20'+_0x4935f1['name'],_0x4935f1));}),_0x1c5c68['onload']=function(_0x5a181e){_0x2b09ed(_0x5a181e['target']['result']);},_0x32db03&&(_0x1c5c68['onprogress']=_0x32db03),_0x182426?_0x1c5c68['readAsArrayBuffer'](_0x4935f1):_0x1c5c68['readAsText'](_0x4935f1),_0x5a5e0c;},_0xd3c2bc['LoadFile']=function(_0xb531a2,_0x1cd734,_0x3dc065,_0x57dfc1,_0x493ab5,_0xf6b712){if(-0x1!==_0xb531a2['indexOf']('file:')){var _0x4e34c1=decodeURIComponent(_0xb531a2['substring'](0x5)['toLowerCase']());0x0===_0x4e34c1['indexOf']('./')&&(_0x4e34c1=_0x4e34c1['substring'](0x2));var _0x5902f4=_0x440a05['a']['FilesToLoad'][_0x4e34c1];if(_0x5902f4)return _0xd3c2bc['ReadFile'](_0x5902f4,_0x1cd734,_0x3dc065,_0x493ab5,_0xf6b712?function(_0x1b2cf2){return _0xf6b712(void 0x0,new _0x5f1ca5(_0x1b2cf2['message'],_0x1b2cf2['file']));}:void 0x0);}return _0xd3c2bc['RequestFile'](_0xb531a2,function(_0x315a3f,_0xb58c70){_0x1cd734(_0x315a3f,_0xb58c70?_0xb58c70['responseURL']:void 0x0);},_0x3dc065,_0x57dfc1,_0x493ab5,_0xf6b712?function(_0x53f20c){_0xf6b712(_0x53f20c['request'],new _0x5f1ca5(_0x53f20c['message'],_0x53f20c['request']));}:void 0x0);},_0xd3c2bc['RequestFile']=function(_0x4799da,_0x409877,_0x72ef55,_0x49143c,_0x43c528,_0x46b253,_0xef21bd){_0x4799da=_0xd3c2bc['_CleanUrl'](_0x4799da),_0x4799da=_0xd3c2bc['PreprocessUrl'](_0x4799da);var _0x2be6d3=_0xd3c2bc['BaseUrl']+_0x4799da,_0x2fc838=!0x1,_0x349687={'onCompleteObservable':new _0x27430d['c'](),'abort':function(){return _0x2fc838=!0x0;}},_0x5493ed=function(){var _0x59751d=new _0x181c2e['a'](),_0x1069ca=null;_0x349687['abort']=function(){_0x2fc838=!0x0,_0x59751d['readyState']!==(XMLHttpRequest['DONE']||0x4)&&_0x59751d['abort'](),null!==_0x1069ca&&(clearTimeout(_0x1069ca),_0x1069ca=null);};var _0x4ddae2=function(_0x911818){_0x59751d['open']('GET',_0x2be6d3),_0xef21bd&&_0xef21bd(_0x59751d),_0x43c528&&(_0x59751d['responseType']='arraybuffer'),_0x72ef55&&_0x59751d['addEventListener']('progress',_0x72ef55);var _0x6ed81e=function(){_0x59751d['removeEventListener']('loadend',_0x6ed81e),_0x349687['onCompleteObservable']['notifyObservers'](_0x349687),_0x349687['onCompleteObservable']['clear']();};_0x59751d['addEventListener']('loadend',_0x6ed81e);var _0x39a835=function(){if(!_0x2fc838&&_0x59751d['readyState']===(XMLHttpRequest['DONE']||0x4)){if(_0x59751d['removeEventListener']('readystatechange',_0x39a835),_0x59751d['status']>=0xc8&&_0x59751d['status']<0x12c||0x0===_0x59751d['status']&&(!_0x2dbda8['a']['IsWindowObjectExist']()||_0xd3c2bc['IsFileURL']()))return void _0x409877(_0x43c528?_0x59751d['response']:_0x59751d['responseText'],_0x59751d);var _0x57500d=_0xd3c2bc['DefaultRetryStrategy'];if(_0x57500d){var _0x4ca539=_0x57500d(_0x2be6d3,_0x59751d,_0x911818);if(-0x1!==_0x4ca539)return _0x59751d['removeEventListener']('loadend',_0x6ed81e),_0x59751d=new _0x181c2e['a'](),void(_0x1069ca=setTimeout(function(){return _0x4ddae2(_0x911818+0x1);},_0x4ca539));}var _0x24e50d=new _0x5852b7('Error\x20status:\x20'+_0x59751d['status']+'\x20'+_0x59751d['statusText']+'\x20-\x20Unable\x20to\x20load\x20'+_0x2be6d3,_0x59751d);_0x46b253&&_0x46b253(_0x24e50d);}};_0x59751d['addEventListener']('readystatechange',_0x39a835),_0x59751d['send']();};_0x4ddae2(0x0);};if(_0x49143c&&_0x49143c['enableSceneOffline']){var _0x4b1169=function(_0x3c02cb){_0x3c02cb&&_0x3c02cb['status']>0x190?_0x46b253&&_0x46b253(_0x3c02cb):_0x5493ed();};_0x49143c['open'](function(){_0x49143c&&_0x49143c['loadFile'](_0xd3c2bc['BaseUrl']+_0x4799da,function(_0x2f9322){_0x2fc838||_0x409877(_0x2f9322),_0x349687['onCompleteObservable']['notifyObservers'](_0x349687);},_0x72ef55?function(_0x282d3b){_0x2fc838||_0x72ef55(_0x282d3b);}:void 0x0,_0x4b1169,_0x43c528);},_0x4b1169);}else _0x5493ed();return _0x349687;},_0xd3c2bc['IsFileURL']=function(){return'undefined'!=typeof location&&'file:'===location['protocol'];},_0xd3c2bc['DefaultRetryStrategy']=_0x190a6e['a']['ExponentialBackoff'](),_0xd3c2bc['BaseUrl']='',_0xd3c2bc['CorsBehavior']='anonymous',_0xd3c2bc['PreprocessUrl']=function(_0x932aeb){return _0x932aeb;},_0xd3c2bc;}());_0x8955a7['a']['_FileToolsLoadImage']=_0x5b8662['LoadImage']['bind'](_0x5b8662),_0x8955a7['a']['_FileToolsLoadFile']=_0x5b8662['LoadFile']['bind'](_0x5b8662),_0x36acf0['a']['_FileToolsLoadFile']=_0x5b8662['LoadFile']['bind'](_0x5b8662);},function(_0x297d3c,_0x5c8983,_0x2a557c){'use strict';_0x2a557c['d'](_0x5c8983,'a',function(){return _0x5aedb5;});var _0x21748f=_0x2a557c(0x26),_0x5aedb5=(function(){function _0x4f3bb1(){}return Object['defineProperty'](_0x4f3bb1,'Now',{'get':function(){return _0x21748f['a']['IsWindowObjectExist']()&&window['performance']&&window['performance']['now']?window['performance']['now']():Date['now']();},'enumerable':!0x1,'configurable':!0x0}),_0x4f3bb1;}());},function(_0x1b653b,_0x1d20df,_0x13d672){'use strict';_0x13d672['d'](_0x1d20df,'a',function(){return _0x3aa357;});var _0x3aa357=(function(){function _0x1f4b54(_0x1e58c5,_0x336197,_0x2bd2f9,_0x3cf76d){this['x']=_0x1e58c5,this['y']=_0x336197,this['width']=_0x2bd2f9,this['height']=_0x3cf76d;}return _0x1f4b54['prototype']['toGlobal']=function(_0x3f248f,_0x31e36b){return new _0x1f4b54(this['x']*_0x3f248f,this['y']*_0x31e36b,this['width']*_0x3f248f,this['height']*_0x31e36b);},_0x1f4b54['prototype']['toGlobalToRef']=function(_0x188d76,_0xc734bd,_0xf30e9b){return _0xf30e9b['x']=this['x']*_0x188d76,_0xf30e9b['y']=this['y']*_0xc734bd,_0xf30e9b['width']=this['width']*_0x188d76,_0xf30e9b['height']=this['height']*_0xc734bd,this;},_0x1f4b54['prototype']['clone']=function(){return new _0x1f4b54(this['x'],this['y'],this['width'],this['height']);},_0x1f4b54;}());},function(_0x33ef19,_0x45a6f1,_0x1ca82b){'use strict';var _0x3c1509='helperFunctions',_0x50bbb3='const\x20float\x20PI=3.1415926535897932384626433832795;\x0aconst\x20float\x20HALF_MIN=5.96046448e-08;\x0aconst\x20float\x20LinearEncodePowerApprox=2.2;\x0aconst\x20float\x20GammaEncodePowerApprox=1.0/LinearEncodePowerApprox;\x0aconst\x20vec3\x20LuminanceEncodeApprox=vec3(0.2126,0.7152,0.0722);\x0aconst\x20float\x20Epsilon=0.0000001;\x0a#define\x20saturate(x)\x20clamp(x,0.0,1.0)\x0a#define\x20absEps(x)\x20abs(x)+Epsilon\x0a#define\x20maxEps(x)\x20max(x,Epsilon)\x0a#define\x20saturateEps(x)\x20clamp(x,Epsilon,1.0)\x0amat3\x20transposeMat3(mat3\x20inMatrix)\x20{\x0avec3\x20i0=inMatrix[0];\x0avec3\x20i1=inMatrix[1];\x0avec3\x20i2=inMatrix[2];\x0amat3\x20outMatrix=mat3(\x0avec3(i0.x,i1.x,i2.x),\x0avec3(i0.y,i1.y,i2.y),\x0avec3(i0.z,i1.z,i2.z)\x0a);\x0areturn\x20outMatrix;\x0a}\x0a\x0amat3\x20inverseMat3(mat3\x20inMatrix)\x20{\x0afloat\x20a00=inMatrix[0][0],a01=inMatrix[0][1],a02=inMatrix[0][2];\x0afloat\x20a10=inMatrix[1][0],a11=inMatrix[1][1],a12=inMatrix[1][2];\x0afloat\x20a20=inMatrix[2][0],a21=inMatrix[2][1],a22=inMatrix[2][2];\x0afloat\x20b01=a22*a11-a12*a21;\x0afloat\x20b11=-a22*a10+a12*a20;\x0afloat\x20b21=a21*a10-a11*a20;\x0afloat\x20det=a00*b01+a01*b11+a02*b21;\x0areturn\x20mat3(b01,(-a22*a01+a02*a21),(a12*a01-a02*a11),\x0ab11,(a22*a00-a02*a20),(-a12*a00+a02*a10),\x0ab21,(-a21*a00+a01*a20),(a11*a00-a01*a10))/det;\x0a}\x0afloat\x20toLinearSpace(float\x20color)\x0a{\x0areturn\x20pow(color,LinearEncodePowerApprox);\x0a}\x0avec3\x20toLinearSpace(vec3\x20color)\x0a{\x0areturn\x20pow(color,vec3(LinearEncodePowerApprox));\x0a}\x0avec4\x20toLinearSpace(vec4\x20color)\x0a{\x0areturn\x20vec4(pow(color.rgb,vec3(LinearEncodePowerApprox)),color.a);\x0a}\x0avec3\x20toGammaSpace(vec3\x20color)\x0a{\x0areturn\x20pow(color,vec3(GammaEncodePowerApprox));\x0a}\x0avec4\x20toGammaSpace(vec4\x20color)\x0a{\x0areturn\x20vec4(pow(color.rgb,vec3(GammaEncodePowerApprox)),color.a);\x0a}\x0afloat\x20toGammaSpace(float\x20color)\x0a{\x0areturn\x20pow(color,GammaEncodePowerApprox);\x0a}\x0afloat\x20square(float\x20value)\x0a{\x0areturn\x20value*value;\x0a}\x0afloat\x20pow5(float\x20value)\x20{\x0afloat\x20sq=value*value;\x0areturn\x20sq*sq*value;\x0a}\x0afloat\x20getLuminance(vec3\x20color)\x0a{\x0areturn\x20clamp(dot(color,LuminanceEncodeApprox),0.,1.);\x0a}\x0a\x0afloat\x20getRand(vec2\x20seed)\x20{\x0areturn\x20fract(sin(dot(seed.xy\x20,vec2(12.9898,78.233)))*43758.5453);\x0a}\x0afloat\x20dither(vec2\x20seed,float\x20varianceAmount)\x20{\x0afloat\x20rand=getRand(seed);\x0afloat\x20dither=mix(-varianceAmount/255.0,varianceAmount/255.0,rand);\x0areturn\x20dither;\x0a}\x0a\x0aconst\x20float\x20rgbdMaxRange=255.0;\x0avec4\x20toRGBD(vec3\x20color)\x20{\x0afloat\x20maxRGB=maxEps(max(color.r,max(color.g,color.b)));\x0afloat\x20D=max(rgbdMaxRange/maxRGB,1.);\x0aD=clamp(floor(D)/255.0,0.,1.);\x0a\x0avec3\x20rgb=color.rgb*D;\x0a\x0argb=toGammaSpace(rgb);\x0areturn\x20vec4(rgb,D);\x0a}\x0avec3\x20fromRGBD(vec4\x20rgbd)\x20{\x0a\x0argbd.rgb=toLinearSpace(rgbd.rgb);\x0a\x0areturn\x20rgbd.rgb/rgbd.a;\x0a}\x0a';_0x1ca82b(0x5)['a']['IncludesShadersStore'][_0x3c1509]=_0x50bbb3;},function(_0x118bae,_0xb2c6f7,_0x3054d4){'use strict';_0x3054d4['d'](_0xb2c6f7,'a',function(){return _0xd80220;});var _0x508623=_0x3054d4(0x0),_0xd80220=(function(){function _0x48bd4e(){}return _0x48bd4e['_RemoveAndStorePivotPoint']=function(_0x355933){_0x355933&&0x0===_0x48bd4e['_PivotCached']&&(_0x355933['getPivotPointToRef'](_0x48bd4e['_OldPivotPoint']),_0x48bd4e['_PivotPostMultiplyPivotMatrix']=_0x355933['_postMultiplyPivotMatrix'],_0x48bd4e['_OldPivotPoint']['equalsToFloats'](0x0,0x0,0x0)||(_0x355933['setPivotMatrix'](_0x508623['a']['IdentityReadOnly']),_0x48bd4e['_OldPivotPoint']['subtractToRef'](_0x355933['getPivotPoint'](),_0x48bd4e['_PivotTranslation']),_0x48bd4e['_PivotTmpVector']['copyFromFloats'](0x1,0x1,0x1),_0x48bd4e['_PivotTmpVector']['subtractInPlace'](_0x355933['scaling']),_0x48bd4e['_PivotTmpVector']['multiplyInPlace'](_0x48bd4e['_PivotTranslation']),_0x355933['position']['addInPlace'](_0x48bd4e['_PivotTmpVector']))),_0x48bd4e['_PivotCached']++;},_0x48bd4e['_RestorePivotPoint']=function(_0x2428db){_0x2428db&&!_0x48bd4e['_OldPivotPoint']['equalsToFloats'](0x0,0x0,0x0)&&0x1===_0x48bd4e['_PivotCached']&&(_0x2428db['setPivotPoint'](_0x48bd4e['_OldPivotPoint']),_0x2428db['_postMultiplyPivotMatrix']=_0x48bd4e['_PivotPostMultiplyPivotMatrix'],_0x48bd4e['_PivotTmpVector']['copyFromFloats'](0x1,0x1,0x1),_0x48bd4e['_PivotTmpVector']['subtractInPlace'](_0x2428db['scaling']),_0x48bd4e['_PivotTmpVector']['multiplyInPlace'](_0x48bd4e['_PivotTranslation']),_0x2428db['position']['subtractInPlace'](_0x48bd4e['_PivotTmpVector'])),this['_PivotCached']--;},_0x48bd4e['_PivotCached']=0x0,_0x48bd4e['_OldPivotPoint']=new _0x508623['e'](),_0x48bd4e['_PivotTranslation']=new _0x508623['e'](),_0x48bd4e['_PivotTmpVector']=new _0x508623['e'](),_0x48bd4e['_PivotPostMultiplyPivotMatrix']=!0x1,_0x48bd4e;}());},function(_0x5756fa,_0x36eb00,_0x56bbb2){'use strict';_0x56bbb2['d'](_0x36eb00,'a',function(){return _0x541d1c;});var _0x36be3e=_0x56bbb2(0x4),_0x368fa3=_0x56bbb2(0x72),_0x2c4c1c=_0x56bbb2(0x2b),_0x53bfbb=_0x56bbb2(0x2),_0x2770ac=_0x56bbb2(0x65),_0x541d1c=(function(){function _0xb2343d(_0x18526b,_0x1cfe08,_0x5bd43e,_0x222e38,_0x456c33,_0x2d780f,_0x3d7b58,_0x180f69,_0x25d0ca){void 0x0===_0x180f69&&(_0x180f69=!0x0),void 0x0===_0x25d0ca&&(_0x25d0ca=!0x0),this['materialIndex']=_0x18526b,this['verticesStart']=_0x1cfe08,this['verticesCount']=_0x5bd43e,this['indexStart']=_0x222e38,this['indexCount']=_0x456c33,this['_materialDefines']=null,this['_materialEffect']=null,this['_effectOverride']=null,this['_linesIndexCount']=0x0,this['_linesIndexBuffer']=null,this['_lastColliderWorldVertices']=null,this['_lastColliderTransformMatrix']=null,this['_renderId']=0x0,this['_alphaIndex']=0x0,this['_distanceToCamera']=0x0,this['_currentMaterial']=null,this['_mesh']=_0x2d780f,this['_renderingMesh']=_0x3d7b58||_0x2d780f,_0x25d0ca&&_0x2d780f['subMeshes']['push'](this),this['_trianglePlanes']=[],this['_id']=_0x2d780f['subMeshes']['length']-0x1,_0x180f69&&(this['refreshBoundingInfo'](),_0x2d780f['computeWorldMatrix'](!0x0));}return Object['defineProperty'](_0xb2343d['prototype'],'materialDefines',{'get':function(){return this['_materialDefines'];},'set':function(_0x3eb487){this['_materialDefines']=_0x3eb487;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xb2343d['prototype'],'effect',{'get':function(){var _0x138fe5;return null!==(_0x138fe5=this['_effectOverride'])&&void 0x0!==_0x138fe5?_0x138fe5:this['_materialEffect'];},'enumerable':!0x1,'configurable':!0x0}),_0xb2343d['prototype']['setEffect']=function(_0x5cfaa3,_0x2755a0){void 0x0===_0x2755a0&&(_0x2755a0=null),this['_materialEffect']!==_0x5cfaa3?(this['_materialDefines']=_0x2755a0,this['_materialEffect']=_0x5cfaa3):_0x5cfaa3||(this['_materialDefines']=null);},_0xb2343d['AddToMesh']=function(_0x57d3dc,_0x3f4a34,_0x497720,_0x3f99a9,_0x339fe4,_0x475770,_0x55c79b,_0x4b0bb2){return void 0x0===_0x4b0bb2&&(_0x4b0bb2=!0x0),new _0xb2343d(_0x57d3dc,_0x3f4a34,_0x497720,_0x3f99a9,_0x339fe4,_0x475770,_0x55c79b,_0x4b0bb2);},Object['defineProperty'](_0xb2343d['prototype'],'IsGlobal',{'get':function(){return 0x0===this['verticesStart']&&this['verticesCount']===this['_mesh']['getTotalVertices']();},'enumerable':!0x1,'configurable':!0x0}),_0xb2343d['prototype']['getBoundingInfo']=function(){return this['IsGlobal']?this['_mesh']['getBoundingInfo']():this['_boundingInfo'];},_0xb2343d['prototype']['setBoundingInfo']=function(_0x166686){return this['_boundingInfo']=_0x166686,this;},_0xb2343d['prototype']['getMesh']=function(){return this['_mesh'];},_0xb2343d['prototype']['getRenderingMesh']=function(){return this['_renderingMesh'];},_0xb2343d['prototype']['getReplacementMesh']=function(){return this['_mesh']['_internalAbstractMeshDataInfo']['_actAsRegularMesh']?this['_mesh']:null;},_0xb2343d['prototype']['getEffectiveMesh']=function(){var _0x4ede93=this['_mesh']['_internalAbstractMeshDataInfo']['_actAsRegularMesh']?this['_mesh']:null;return _0x4ede93||this['_renderingMesh'];},_0xb2343d['prototype']['getMaterial']=function(){var _0x49e842=this['_renderingMesh']['material'];if(null==_0x49e842)return this['_mesh']['getScene']()['defaultMaterial'];if(this['_IsMultiMaterial'](_0x49e842)){var _0x156e4a=_0x49e842['getSubMaterial'](this['materialIndex']);return this['_currentMaterial']!==_0x156e4a&&(this['_currentMaterial']=_0x156e4a,this['_materialDefines']=null),_0x156e4a;}return _0x49e842;},_0xb2343d['prototype']['_IsMultiMaterial']=function(_0x1461d0){return void 0x0!==_0x1461d0['getSubMaterial'];},_0xb2343d['prototype']['refreshBoundingInfo']=function(_0x148ee6){if(void 0x0===_0x148ee6&&(_0x148ee6=null),this['_lastColliderWorldVertices']=null,this['IsGlobal']||!this['_renderingMesh']||!this['_renderingMesh']['geometry'])return this;if(_0x148ee6||(_0x148ee6=this['_renderingMesh']['getVerticesData'](_0x36be3e['b']['PositionKind'])),!_0x148ee6)return this['_boundingInfo']=this['_mesh']['getBoundingInfo'](),this;var _0x231017,_0x3e1bdd=this['_renderingMesh']['getIndices']();if(0x0===this['indexStart']&&this['indexCount']===_0x3e1bdd['length']){var _0xbe2879=this['_renderingMesh']['getBoundingInfo']();_0x231017={'minimum':_0xbe2879['minimum']['clone'](),'maximum':_0xbe2879['maximum']['clone']()};}else _0x231017=Object(_0x2770ac['b'])(_0x148ee6,_0x3e1bdd,this['indexStart'],this['indexCount'],this['_renderingMesh']['geometry']['boundingBias']);return this['_boundingInfo']?this['_boundingInfo']['reConstruct'](_0x231017['minimum'],_0x231017['maximum']):this['_boundingInfo']=new _0x2c4c1c['a'](_0x231017['minimum'],_0x231017['maximum']),this;},_0xb2343d['prototype']['_checkCollision']=function(_0x2ae65c){return this['getBoundingInfo']()['_checkCollision'](_0x2ae65c);},_0xb2343d['prototype']['updateBoundingInfo']=function(_0x393ea4){var _0x418edb=this['getBoundingInfo']();return _0x418edb||(this['refreshBoundingInfo'](),_0x418edb=this['getBoundingInfo']()),_0x418edb&&_0x418edb['update'](_0x393ea4),this;},_0xb2343d['prototype']['isInFrustum']=function(_0x37202f){var _0x4a35de=this['getBoundingInfo']();return!!_0x4a35de&&_0x4a35de['isInFrustum'](_0x37202f,this['_mesh']['cullingStrategy']);},_0xb2343d['prototype']['isCompletelyInFrustum']=function(_0x2c3510){var _0x42cc60=this['getBoundingInfo']();return!!_0x42cc60&&_0x42cc60['isCompletelyInFrustum'](_0x2c3510);},_0xb2343d['prototype']['render']=function(_0x3a5108){return this['_renderingMesh']['render'](this,_0x3a5108,this['_mesh']['_internalAbstractMeshDataInfo']['_actAsRegularMesh']?this['_mesh']:void 0x0),this;},_0xb2343d['prototype']['_getLinesIndexBuffer']=function(_0x159210,_0x35ac53){if(!this['_linesIndexBuffer']){for(var _0x175f83=[],_0x307502=this['indexStart'];_0x307502_0x2cda0e&&(_0x2cda0e=_0x369749);}return new _0xb2343d(_0x502224,_0x12342f,_0x2cda0e-_0x12342f+0x1,_0x39f39a,_0x2609fb,_0x2083ca,_0x1b5c05);},_0xb2343d;}());},function(_0x1b9c06,_0x3dadec,_0x3040c6){'use strict';_0x3040c6['d'](_0x3dadec,'a',function(){return _0x37c879;});var _0x204e4d=_0x3040c6(0x1),_0x353527=_0x3040c6(0x8),_0x1d0216=_0x3040c6(0xa),_0x19224d=_0x3040c6(0x2),_0x1cc30e=(_0x3040c6(0x7e),_0x3040c6(0x46)),_0x37c879=function(_0x29d7e6){function _0x3eec81(_0x8522d9,_0x1abd3b,_0x5efea6,_0x4cd12f,_0x629dfc,_0x4a489a,_0x4c9efb){void 0x0===_0x5efea6&&(_0x5efea6=null),void 0x0===_0x629dfc&&(_0x629dfc=_0x19224d['a']['TEXTURE_TRILINEAR_SAMPLINGMODE']),void 0x0===_0x4a489a&&(_0x4a489a=_0x19224d['a']['TEXTUREFORMAT_RGBA']);var _0x3b49aa=_0x29d7e6['call'](this,null,_0x5efea6,!_0x4cd12f,_0x4c9efb,_0x629dfc,void 0x0,void 0x0,void 0x0,void 0x0,_0x4a489a)||this;_0x3b49aa['name']=_0x8522d9,_0x3b49aa['wrapU']=_0x1d0216['a']['CLAMP_ADDRESSMODE'],_0x3b49aa['wrapV']=_0x1d0216['a']['CLAMP_ADDRESSMODE'],_0x3b49aa['_generateMipMaps']=_0x4cd12f;var _0xf5c70=_0x3b49aa['_getEngine']();if(!_0xf5c70)return _0x3b49aa;_0x1abd3b['getContext']?(_0x3b49aa['_canvas']=_0x1abd3b,_0x3b49aa['_texture']=_0xf5c70['createDynamicTexture'](_0x1abd3b['width'],_0x1abd3b['height'],_0x4cd12f,_0x629dfc)):(_0x3b49aa['_canvas']=_0x1cc30e['a']['CreateCanvas'](0x1,0x1),_0x1abd3b['width']||0x0===_0x1abd3b['width']?_0x3b49aa['_texture']=_0xf5c70['createDynamicTexture'](_0x1abd3b['width'],_0x1abd3b['height'],_0x4cd12f,_0x629dfc):_0x3b49aa['_texture']=_0xf5c70['createDynamicTexture'](_0x1abd3b,_0x1abd3b,_0x4cd12f,_0x629dfc));var _0x5e561b=_0x3b49aa['getSize']();return _0x3b49aa['_canvas']['width']=_0x5e561b['width'],_0x3b49aa['_canvas']['height']=_0x5e561b['height'],_0x3b49aa['_context']=_0x3b49aa['_canvas']['getContext']('2d'),_0x3b49aa;}return Object(_0x204e4d['d'])(_0x3eec81,_0x29d7e6),_0x3eec81['prototype']['getClassName']=function(){return'DynamicTexture';},Object['defineProperty'](_0x3eec81['prototype'],'canRescale',{'get':function(){return!0x0;},'enumerable':!0x1,'configurable':!0x0}),_0x3eec81['prototype']['_recreate']=function(_0x3206b6){this['_canvas']['width']=_0x3206b6['width'],this['_canvas']['height']=_0x3206b6['height'],this['releaseInternalTexture'](),this['_texture']=this['_getEngine']()['createDynamicTexture'](_0x3206b6['width'],_0x3206b6['height'],this['_generateMipMaps'],this['samplingMode']);},_0x3eec81['prototype']['scale']=function(_0x55272b){var _0x406413=this['getSize']();_0x406413['width']*=_0x55272b,_0x406413['height']*=_0x55272b,this['_recreate'](_0x406413);},_0x3eec81['prototype']['scaleTo']=function(_0x196f1a,_0x4af073){var _0x25a454=this['getSize']();_0x25a454['width']=_0x196f1a,_0x25a454['height']=_0x4af073,this['_recreate'](_0x25a454);},_0x3eec81['prototype']['getContext']=function(){return this['_context'];},_0x3eec81['prototype']['clear']=function(){var _0x64a7b4=this['getSize']();this['_context']['fillRect'](0x0,0x0,_0x64a7b4['width'],_0x64a7b4['height']);},_0x3eec81['prototype']['update']=function(_0xdd0f82,_0x532250){void 0x0===_0x532250&&(_0x532250=!0x1),this['_getEngine']()['updateDynamicTexture'](this['_texture'],this['_canvas'],void 0x0===_0xdd0f82||_0xdd0f82,_0x532250,this['_format']||void 0x0);},_0x3eec81['prototype']['drawText']=function(_0x5b54be,_0x2e037b,_0x34b835,_0x4f6696,_0x27c3d6,_0x209cae,_0x2093cc,_0x52dee6){void 0x0===_0x52dee6&&(_0x52dee6=!0x0);var _0x25846a=this['getSize']();if(_0x209cae&&(this['_context']['fillStyle']=_0x209cae,this['_context']['fillRect'](0x0,0x0,_0x25846a['width'],_0x25846a['height'])),this['_context']['font']=_0x4f6696,null==_0x2e037b){var _0x280839=this['_context']['measureText'](_0x5b54be);_0x2e037b=(_0x25846a['width']-_0x280839['width'])/0x2;}if(null==_0x34b835){var _0x16a7ed=parseInt(_0x4f6696['replace'](/\D/g,''));_0x34b835=_0x25846a['height']/0x2+_0x16a7ed/3.65;}this['_context']['fillStyle']=_0x27c3d6||'',this['_context']['fillText'](_0x5b54be,_0x2e037b,_0x34b835),_0x52dee6&&this['update'](_0x2093cc);},_0x3eec81['prototype']['clone']=function(){var _0x9faf71=this['getScene']();if(!_0x9faf71)return this;var _0x3869ee=this['getSize'](),_0x174e0c=new _0x3eec81(this['name'],_0x3869ee,_0x9faf71,this['_generateMipMaps']);return _0x174e0c['hasAlpha']=this['hasAlpha'],_0x174e0c['level']=this['level'],_0x174e0c['wrapU']=this['wrapU'],_0x174e0c['wrapV']=this['wrapV'],_0x174e0c;},_0x3eec81['prototype']['serialize']=function(){var _0x4442ea=this['getScene']();_0x4442ea&&!_0x4442ea['isReady']()&&_0x353527['a']['Warn']('The\x20scene\x20must\x20be\x20ready\x20before\x20serializing\x20the\x20dynamic\x20texture');var _0x37ae8a=_0x29d7e6['prototype']['serialize']['call'](this);return this['_IsCanvasElement'](this['_canvas'])&&(_0x37ae8a['base64String']=this['_canvas']['toDataURL']()),_0x37ae8a['invertY']=this['_invertY'],_0x37ae8a['samplingMode']=this['samplingMode'],_0x37ae8a;},_0x3eec81['prototype']['_IsCanvasElement']=function(_0x5c1d9e){return void 0x0!==_0x5c1d9e['toDataURL'];},_0x3eec81['prototype']['_rebuild']=function(){this['update']();},_0x3eec81;}(_0x1d0216['a']);},function(_0x385f5c,_0x13dd7b,_0x513775){'use strict';_0x513775['d'](_0x13dd7b,'a',function(){return _0x48a193;});var _0x554494=_0x513775(0x0),_0x3e8814=_0x513775(0x9),_0xbdd7f7=_0x513775(0x7),_0xde4b70=_0x513775(0x10);_0xde4b70['a']['CreateBox']=function(_0x3aa85b){var _0xcc5baa,_0x437954=[0x0,0x1,0x2,0x0,0x2,0x3,0x4,0x5,0x6,0x4,0x6,0x7,0x8,0x9,0xa,0x8,0xa,0xb,0xc,0xd,0xe,0xc,0xe,0xf,0x10,0x11,0x12,0x10,0x12,0x13,0x14,0x15,0x16,0x14,0x16,0x17],_0x144c64=[0x0,0x0,0x1,0x0,0x0,0x1,0x0,0x0,0x1,0x0,0x0,0x1,0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1,0x1,0x0,0x0,0x1,0x0,0x0,0x1,0x0,0x0,0x1,0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,0x0,0x1,0x0,0x0,0x1,0x0,0x0,0x1,0x0,0x0,0x1,0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1,0x0],_0x4fc874=[],_0xa17c2a=_0x3aa85b['width']||_0x3aa85b['size']||0x1,_0x41a6b3=_0x3aa85b['height']||_0x3aa85b['size']||0x1,_0x2ebf6f=_0x3aa85b['depth']||_0x3aa85b['size']||0x1,_0x35e3e6=_0x3aa85b['wrap']||!0x1,_0x295abf=void 0x0===_0x3aa85b['topBaseAt']?0x1:_0x3aa85b['topBaseAt'],_0x1d9190=void 0x0===_0x3aa85b['bottomBaseAt']?0x0:_0x3aa85b['bottomBaseAt'],_0x533a70=[0x2,0x0,0x3,0x1][_0x295abf=(_0x295abf+0x4)%0x4],_0x1fbe49=[0x2,0x0,0x1,0x3][_0x1d9190=(_0x1d9190+0x4)%0x4],_0x5741c0=[0x1,-0x1,0x1,-0x1,-0x1,0x1,-0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,-0x1,-0x1,0x1,-0x1,-0x1,-0x1,-0x1,0x1,-0x1,-0x1,0x1,0x1,-0x1,0x1,-0x1,-0x1,0x1,-0x1,0x1,0x1,0x1,0x1,-0x1,0x1,0x1,-0x1,-0x1,0x1,-0x1,-0x1,-0x1,-0x1,0x1,-0x1,-0x1,0x1,0x1,-0x1,0x1,-0x1,0x1,0x1,-0x1,0x1,0x1,0x1,0x1,-0x1,0x1,0x1,-0x1,-0x1,-0x1,-0x1,-0x1,-0x1,-0x1,0x1];if(_0x35e3e6){_0x437954=[0x2,0x3,0x0,0x2,0x0,0x1,0x4,0x5,0x6,0x4,0x6,0x7,0x9,0xa,0xb,0x9,0xb,0x8,0xc,0xe,0xf,0xc,0xd,0xe],_0x5741c0=[-0x1,0x1,0x1,0x1,0x1,0x1,0x1,-0x1,0x1,-0x1,-0x1,0x1,0x1,0x1,-0x1,-0x1,0x1,-0x1,-0x1,-0x1,-0x1,0x1,-0x1,-0x1,0x1,0x1,0x1,0x1,0x1,-0x1,0x1,-0x1,-0x1,0x1,-0x1,0x1,-0x1,0x1,-0x1,-0x1,0x1,0x1,-0x1,-0x1,0x1,-0x1,-0x1,-0x1];for(var _0x4b6bbf=[[0x1,0x1,0x1],[-0x1,0x1,0x1],[-0x1,0x1,-0x1],[0x1,0x1,-0x1]],_0x3b890c=[[-0x1,-0x1,0x1],[0x1,-0x1,0x1],[0x1,-0x1,-0x1],[-0x1,-0x1,-0x1]],_0xb7d45=[0x11,0x12,0x13,0x10],_0x4e0811=[0x16,0x17,0x14,0x15];_0x533a70>0x0;)_0x4b6bbf['unshift'](_0x4b6bbf['pop']()),_0xb7d45['unshift'](_0xb7d45['pop']()),_0x533a70--;for(;_0x1fbe49>0x0;)_0x3b890c['unshift'](_0x3b890c['pop']()),_0x4e0811['unshift'](_0x4e0811['pop']()),_0x1fbe49--;_0x4b6bbf=_0x4b6bbf['flat'](),_0x3b890c=_0x3b890c['flat'](),_0x5741c0=_0x5741c0['concat'](_0x4b6bbf)['concat'](_0x3b890c),_0x437954['push'](_0xb7d45[0x0],_0xb7d45[0x2],_0xb7d45[0x3],_0xb7d45[0x0],_0xb7d45[0x1],_0xb7d45[0x2]),_0x437954['push'](_0x4e0811[0x0],_0x4e0811[0x2],_0x4e0811[0x3],_0x4e0811[0x0],_0x4e0811[0x1],_0x4e0811[0x2]);}var _0x595f24=[_0xa17c2a/0x2,_0x41a6b3/0x2,_0x2ebf6f/0x2];_0xcc5baa=_0x5741c0['reduce'](function(_0x310e8e,_0x463c4a,_0x4a9646){return _0x310e8e['concat'](_0x463c4a*_0x595f24[_0x4a9646%0x3]);},[]);for(var _0x4c2831=0x0===_0x3aa85b['sideOrientation']?0x0:_0x3aa85b['sideOrientation']||_0xde4b70['a']['DEFAULTSIDE'],_0x4b67da=_0x3aa85b['faceUV']||new Array(0x6),_0x5aede2=_0x3aa85b['faceColors'],_0x3ce9b9=[],_0x35c8d8=0x0;_0x35c8d8<0x6;_0x35c8d8++)void 0x0===_0x4b67da[_0x35c8d8]&&(_0x4b67da[_0x35c8d8]=new _0x554494['f'](0x0,0x0,0x1,0x1)),_0x5aede2&&void 0x0===_0x5aede2[_0x35c8d8]&&(_0x5aede2[_0x35c8d8]=new _0x3e8814['b'](0x1,0x1,0x1,0x1));for(var _0x322798=0x0;_0x322798<0x6;_0x322798++)if(_0x4fc874['push'](_0x4b67da[_0x322798]['z'],_0x4b67da[_0x322798]['w']),_0x4fc874['push'](_0x4b67da[_0x322798]['x'],_0x4b67da[_0x322798]['w']),_0x4fc874['push'](_0x4b67da[_0x322798]['x'],_0x4b67da[_0x322798]['y']),_0x4fc874['push'](_0x4b67da[_0x322798]['z'],_0x4b67da[_0x322798]['y']),_0x5aede2){for(var _0x331e18=0x0;_0x331e18<0x4;_0x331e18++)_0x3ce9b9['push'](_0x5aede2[_0x322798]['r'],_0x5aede2[_0x322798]['g'],_0x5aede2[_0x322798]['b'],_0x5aede2[_0x322798]['a']);}_0xde4b70['a']['_ComputeSides'](_0x4c2831,_0xcc5baa,_0x437954,_0x144c64,_0x4fc874,_0x3aa85b['frontUVs'],_0x3aa85b['backUVs']);var _0x59775a=new _0xde4b70['a']();if(_0x59775a['indices']=_0x437954,_0x59775a['positions']=_0xcc5baa,_0x59775a['normals']=_0x144c64,_0x59775a['uvs']=_0x4fc874,_0x5aede2){var _0x2a4534=_0x4c2831===_0xde4b70['a']['DOUBLESIDE']?_0x3ce9b9['concat'](_0x3ce9b9):_0x3ce9b9;_0x59775a['colors']=_0x2a4534;}return _0x59775a;},_0xbdd7f7['a']['CreateBox']=function(_0x21a623,_0x48a9de,_0x320727,_0x4d3333,_0x52b83d){void 0x0===_0x320727&&(_0x320727=null);var _0x31e7f6={'size':_0x48a9de,'sideOrientation':_0x52b83d,'updatable':_0x4d3333};return _0x48a193['CreateBox'](_0x21a623,_0x31e7f6,_0x320727);};var _0x48a193=(function(){function _0x48c041(){}return _0x48c041['CreateBox']=function(_0x5057e2,_0x5f850a,_0x51775e){void 0x0===_0x51775e&&(_0x51775e=null);var _0x3f9776=new _0xbdd7f7['a'](_0x5057e2,_0x51775e);return _0x5f850a['sideOrientation']=_0xbdd7f7['a']['_GetDefaultSideOrientation'](_0x5f850a['sideOrientation']),_0x3f9776['_originalBuilderSideOrientation']=_0x5f850a['sideOrientation'],_0xde4b70['a']['CreateBox'](_0x5f850a)['applyToMesh'](_0x3f9776,_0x5f850a['updatable']),_0x3f9776;},_0x48c041;}());},function(_0x33f8c6,_0x3269f8,_0x58ae2d){'use strict';_0x58ae2d['d'](_0x3269f8,'a',function(){return _0x29e796;});var _0x8a594e=_0x58ae2d(0x0),_0x29e796=(function(){function _0x3bb1bd(_0x1d4e22,_0x414d48,_0x5d2898,_0x3f3128){this['normal']=new _0x8a594e['e'](_0x1d4e22,_0x414d48,_0x5d2898),this['d']=_0x3f3128;}return _0x3bb1bd['prototype']['asArray']=function(){return[this['normal']['x'],this['normal']['y'],this['normal']['z'],this['d']];},_0x3bb1bd['prototype']['clone']=function(){return new _0x3bb1bd(this['normal']['x'],this['normal']['y'],this['normal']['z'],this['d']);},_0x3bb1bd['prototype']['getClassName']=function(){return'Plane';},_0x3bb1bd['prototype']['getHashCode']=function(){var _0x3408f1=this['normal']['getHashCode']();return _0x3408f1=0x18d*_0x3408f1^(0x0|this['d']);},_0x3bb1bd['prototype']['normalize']=function(){var _0x2d1258=Math['sqrt'](this['normal']['x']*this['normal']['x']+this['normal']['y']*this['normal']['y']+this['normal']['z']*this['normal']['z']),_0x167cfc=0x0;return 0x0!==_0x2d1258&&(_0x167cfc=0x1/_0x2d1258),this['normal']['x']*=_0x167cfc,this['normal']['y']*=_0x167cfc,this['normal']['z']*=_0x167cfc,this['d']*=_0x167cfc,this;},_0x3bb1bd['prototype']['transform']=function(_0x179b6e){var _0x4b4bf1=_0x3bb1bd['_TmpMatrix'];_0x179b6e['invertToRef'](_0x4b4bf1);var _0x6a4b19=_0x4b4bf1['m'],_0x38e6ac=this['normal']['x'],_0x5471b2=this['normal']['y'],_0x37d83d=this['normal']['z'],_0x261393=this['d'];return new _0x3bb1bd(_0x38e6ac*_0x6a4b19[0x0]+_0x5471b2*_0x6a4b19[0x1]+_0x37d83d*_0x6a4b19[0x2]+_0x261393*_0x6a4b19[0x3],_0x38e6ac*_0x6a4b19[0x4]+_0x5471b2*_0x6a4b19[0x5]+_0x37d83d*_0x6a4b19[0x6]+_0x261393*_0x6a4b19[0x7],_0x38e6ac*_0x6a4b19[0x8]+_0x5471b2*_0x6a4b19[0x9]+_0x37d83d*_0x6a4b19[0xa]+_0x261393*_0x6a4b19[0xb],_0x38e6ac*_0x6a4b19[0xc]+_0x5471b2*_0x6a4b19[0xd]+_0x37d83d*_0x6a4b19[0xe]+_0x261393*_0x6a4b19[0xf]);},_0x3bb1bd['prototype']['dotCoordinate']=function(_0x50c405){return this['normal']['x']*_0x50c405['x']+this['normal']['y']*_0x50c405['y']+this['normal']['z']*_0x50c405['z']+this['d'];},_0x3bb1bd['prototype']['copyFromPoints']=function(_0x25b4e3,_0xca9bd8,_0x2b9e3f){var _0x48e161,_0xe7a819=_0xca9bd8['x']-_0x25b4e3['x'],_0x1c8ecb=_0xca9bd8['y']-_0x25b4e3['y'],_0x1e38f6=_0xca9bd8['z']-_0x25b4e3['z'],_0x442d69=_0x2b9e3f['x']-_0x25b4e3['x'],_0x5cafd1=_0x2b9e3f['y']-_0x25b4e3['y'],_0x41bef5=_0x2b9e3f['z']-_0x25b4e3['z'],_0x269385=_0x1c8ecb*_0x41bef5-_0x1e38f6*_0x5cafd1,_0x318d65=_0x1e38f6*_0x442d69-_0xe7a819*_0x41bef5,_0x3648b0=_0xe7a819*_0x5cafd1-_0x1c8ecb*_0x442d69,_0x387180=Math['sqrt'](_0x269385*_0x269385+_0x318d65*_0x318d65+_0x3648b0*_0x3648b0);return _0x48e161=0x0!==_0x387180?0x1/_0x387180:0x0,this['normal']['x']=_0x269385*_0x48e161,this['normal']['y']=_0x318d65*_0x48e161,this['normal']['z']=_0x3648b0*_0x48e161,this['d']=-(this['normal']['x']*_0x25b4e3['x']+this['normal']['y']*_0x25b4e3['y']+this['normal']['z']*_0x25b4e3['z']),this;},_0x3bb1bd['prototype']['isFrontFacingTo']=function(_0xefa81f,_0x58234b){return _0x8a594e['e']['Dot'](this['normal'],_0xefa81f)<=_0x58234b;},_0x3bb1bd['prototype']['signedDistanceTo']=function(_0x47afd3){return _0x8a594e['e']['Dot'](_0x47afd3,this['normal'])+this['d'];},_0x3bb1bd['FromArray']=function(_0x562578){return new _0x3bb1bd(_0x562578[0x0],_0x562578[0x1],_0x562578[0x2],_0x562578[0x3]);},_0x3bb1bd['FromPoints']=function(_0x97af9c,_0xcbefa0,_0x42a632){var _0x1c484a=new _0x3bb1bd(0x0,0x0,0x0,0x0);return _0x1c484a['copyFromPoints'](_0x97af9c,_0xcbefa0,_0x42a632),_0x1c484a;},_0x3bb1bd['FromPositionAndNormal']=function(_0x1f594c,_0x4f1e00){var _0x144ff7=new _0x3bb1bd(0x0,0x0,0x0,0x0);return _0x4f1e00['normalize'](),_0x144ff7['normal']=_0x4f1e00,_0x144ff7['d']=-(_0x4f1e00['x']*_0x1f594c['x']+_0x4f1e00['y']*_0x1f594c['y']+_0x4f1e00['z']*_0x1f594c['z']),_0x144ff7;},_0x3bb1bd['SignedDistanceToPlaneFromPositionAndNormal']=function(_0x4d4874,_0x476fa3,_0x1ee8e4){var _0x541aca=-(_0x476fa3['x']*_0x4d4874['x']+_0x476fa3['y']*_0x4d4874['y']+_0x476fa3['z']*_0x4d4874['z']);return _0x8a594e['e']['Dot'](_0x1ee8e4,_0x476fa3)+_0x541aca;},_0x3bb1bd['_TmpMatrix']=_0x8a594e['a']['Identity'](),_0x3bb1bd;}());},function(_0x3694e6,_0x4b6a49,_0x409022){'use strict';_0x409022['d'](_0x4b6a49,'a',function(){return _0x59fd15;});var _0x5c39b0=_0x409022(0x7),_0xf54fed=_0x409022(0x14),_0x4459ea=_0x409022(0x6),_0x52b07e=_0x409022(0x0),_0x3ad0b4=_0x409022(0x12),_0x572e63=_0x409022(0x27),_0x4d8a9c=_0x409022(0x3c),_0x59fd15=(_0x409022(0x54),(function(){function _0x14dc17(_0x42cb3a){this['_useAlternatePickedPointAboveMaxDragAngleDragSpeed']=-1.1,this['maxDragAngle']=0x0,this['_useAlternatePickedPointAboveMaxDragAngle']=!0x1,this['currentDraggingPointerID']=-0x1,this['dragging']=!0x1,this['dragDeltaRatio']=0.2,this['updateDragPlane']=!0x0,this['_debugMode']=!0x1,this['_moving']=!0x1,this['onDragObservable']=new _0x4459ea['c'](),this['onDragStartObservable']=new _0x4459ea['c'](),this['onDragEndObservable']=new _0x4459ea['c'](),this['moveAttached']=!0x0,this['enabled']=!0x0,this['startAndReleaseDragOnPointerEvents']=!0x0,this['detachCameraControls']=!0x0,this['useObjectOrientationForDragging']=!0x0,this['validateDrag']=function(_0x1a2eb8){return!0x0;},this['_tmpVector']=new _0x52b07e['e'](0x0,0x0,0x0),this['_alternatePickedPoint']=new _0x52b07e['e'](0x0,0x0,0x0),this['_worldDragAxis']=new _0x52b07e['e'](0x0,0x0,0x0),this['_targetPosition']=new _0x52b07e['e'](0x0,0x0,0x0),this['_attachedToElement']=!0x1,this['_startDragRay']=new _0x572e63['a'](new _0x52b07e['e'](),new _0x52b07e['e']()),this['_lastPointerRay']={},this['_dragDelta']=new _0x52b07e['e'](),this['_pointA']=new _0x52b07e['e'](0x0,0x0,0x0),this['_pointC']=new _0x52b07e['e'](0x0,0x0,0x0),this['_localAxis']=new _0x52b07e['e'](0x0,0x0,0x0),this['_lookAt']=new _0x52b07e['e'](0x0,0x0,0x0),this['_options']=_0x42cb3a||{};var _0x580822=0x0;if(this['_options']['dragAxis']&&_0x580822++,this['_options']['dragPlaneNormal']&&_0x580822++,_0x580822>0x1)throw'Multiple\x20drag\x20modes\x20specified\x20in\x20dragBehavior\x20options.\x20Only\x20one\x20expected';}return Object['defineProperty'](_0x14dc17['prototype'],'options',{'get':function(){return this['_options'];},'set':function(_0x4a3a13){this['_options']=_0x4a3a13;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x14dc17['prototype'],'name',{'get':function(){return'PointerDrag';},'enumerable':!0x1,'configurable':!0x0}),_0x14dc17['prototype']['init']=function(){},_0x14dc17['prototype']['attach']=function(_0x39340a,_0xd41c23){var _0x2f4b92=this;this['_scene']=_0x39340a['getScene'](),this['attachedNode']=_0x39340a,_0x14dc17['_planeScene']||(this['_debugMode']?_0x14dc17['_planeScene']=this['_scene']:(_0x14dc17['_planeScene']=new _0xf54fed['a'](this['_scene']['getEngine'](),{'virtual':!0x0}),_0x14dc17['_planeScene']['detachControl'](),this['_scene']['onDisposeObservable']['addOnce'](function(){_0x14dc17['_planeScene']['dispose'](),_0x14dc17['_planeScene']=null;}))),this['_dragPlane']=_0x5c39b0['a']['CreatePlane']('pointerDragPlane',this['_debugMode']?0x1:0x2710,_0x14dc17['_planeScene'],!0x1,_0x5c39b0['a']['DOUBLESIDE']),this['lastDragPosition']=new _0x52b07e['e'](0x0,0x0,0x0);var _0x3d6a3d=_0xd41c23||function(_0x30e30b){return _0x2f4b92['attachedNode']==_0x30e30b||_0x30e30b['isDescendantOf'](_0x2f4b92['attachedNode']);};this['_pointerObserver']=this['_scene']['onPointerObservable']['add'](function(_0x1c9e39,_0x34613a){if(_0x2f4b92['enabled']){if(_0x1c9e39['type']==_0x3ad0b4['a']['POINTERDOWN'])_0x2f4b92['startAndReleaseDragOnPointerEvents']&&!_0x2f4b92['dragging']&&_0x1c9e39['pickInfo']&&_0x1c9e39['pickInfo']['hit']&&_0x1c9e39['pickInfo']['pickedMesh']&&_0x1c9e39['pickInfo']['pickedPoint']&&_0x1c9e39['pickInfo']['ray']&&_0x3d6a3d(_0x1c9e39['pickInfo']['pickedMesh'])&&_0x2f4b92['_startDrag'](_0x1c9e39['event']['pointerId'],_0x1c9e39['pickInfo']['ray'],_0x1c9e39['pickInfo']['pickedPoint']);else{if(_0x1c9e39['type']==_0x3ad0b4['a']['POINTERUP'])_0x2f4b92['startAndReleaseDragOnPointerEvents']&&_0x2f4b92['currentDraggingPointerID']==_0x1c9e39['event']['pointerId']&&_0x2f4b92['releaseDrag']();else{if(_0x1c9e39['type']==_0x3ad0b4['a']['POINTERMOVE']){var _0x31e371=_0x1c9e39['event']['pointerId'];if(_0x2f4b92['currentDraggingPointerID']===_0x14dc17['_AnyMouseID']&&_0x31e371!==_0x14dc17['_AnyMouseID']){var _0x2c5e36=_0x1c9e39['event'];('mouse'===_0x2c5e36['pointerType']||!_0x2f4b92['_scene']['getEngine']()['hostInformation']['isMobile']&&_0x2c5e36 instanceof MouseEvent)&&(_0x2f4b92['_lastPointerRay'][_0x2f4b92['currentDraggingPointerID']]&&(_0x2f4b92['_lastPointerRay'][_0x31e371]=_0x2f4b92['_lastPointerRay'][_0x2f4b92['currentDraggingPointerID']],delete _0x2f4b92['_lastPointerRay'][_0x2f4b92['currentDraggingPointerID']]),_0x2f4b92['currentDraggingPointerID']=_0x31e371);}_0x2f4b92['_lastPointerRay'][_0x31e371]||(_0x2f4b92['_lastPointerRay'][_0x31e371]=new _0x572e63['a'](new _0x52b07e['e'](),new _0x52b07e['e']())),_0x1c9e39['pickInfo']&&_0x1c9e39['pickInfo']['ray']&&(_0x2f4b92['_lastPointerRay'][_0x31e371]['origin']['copyFrom'](_0x1c9e39['pickInfo']['ray']['origin']),_0x2f4b92['_lastPointerRay'][_0x31e371]['direction']['copyFrom'](_0x1c9e39['pickInfo']['ray']['direction']),_0x2f4b92['currentDraggingPointerID']==_0x31e371&&_0x2f4b92['dragging']&&_0x2f4b92['_moveDrag'](_0x1c9e39['pickInfo']['ray']));}}}}}),this['_beforeRenderObserver']=this['_scene']['onBeforeRenderObservable']['add'](function(){_0x2f4b92['_moving']&&_0x2f4b92['moveAttached']&&(_0x4d8a9c['a']['_RemoveAndStorePivotPoint'](_0x2f4b92['attachedNode']),_0x2f4b92['_targetPosition']['subtractToRef'](_0x2f4b92['attachedNode']['absolutePosition'],_0x2f4b92['_tmpVector']),_0x2f4b92['_tmpVector']['scaleInPlace'](_0x2f4b92['dragDeltaRatio']),_0x2f4b92['attachedNode']['getAbsolutePosition']()['addToRef'](_0x2f4b92['_tmpVector'],_0x2f4b92['_tmpVector']),_0x2f4b92['validateDrag'](_0x2f4b92['_tmpVector'])&&_0x2f4b92['attachedNode']['setAbsolutePosition'](_0x2f4b92['_tmpVector']),_0x4d8a9c['a']['_RestorePivotPoint'](_0x2f4b92['attachedNode']));});},_0x14dc17['prototype']['releaseDrag']=function(){if(this['dragging']&&(this['dragging']=!0x1,this['onDragEndObservable']['notifyObservers']({'dragPlanePoint':this['lastDragPosition'],'pointerId':this['currentDraggingPointerID']})),this['currentDraggingPointerID']=-0x1,this['_moving']=!0x1,this['detachCameraControls']&&this['_attachedToElement']&&this['_scene']['activeCamera']&&!this['_scene']['activeCamera']['leftCamera']){if('ArcRotateCamera'===this['_scene']['activeCamera']['getClassName']()){var _0x489d7c=this['_scene']['activeCamera'];_0x489d7c['attachControl'](!_0x489d7c['inputs']||_0x489d7c['inputs']['noPreventDefault'],_0x489d7c['_useCtrlForPanning'],_0x489d7c['_panningMouseButton']);}else this['_scene']['activeCamera']['attachControl'](!this['_scene']['activeCamera']['inputs']||this['_scene']['activeCamera']['inputs']['noPreventDefault']);this['_attachedToElement']=!0x1;}},_0x14dc17['prototype']['startDrag']=function(_0x303efb,_0xe08fe,_0x25c588){void 0x0===_0x303efb&&(_0x303efb=_0x14dc17['_AnyMouseID']),this['_startDrag'](_0x303efb,_0xe08fe,_0x25c588);var _0x561977=this['_lastPointerRay'][_0x303efb];_0x303efb===_0x14dc17['_AnyMouseID']&&(_0x561977=this['_lastPointerRay'][Object['keys'](this['_lastPointerRay'])[0x0]]),_0x561977&&this['_moveDrag'](_0x561977);},_0x14dc17['prototype']['_startDrag']=function(_0x486d9f,_0x1eb9b8,_0x18f5e3){if(this['_scene']['activeCamera']&&!this['dragging']&&this['attachedNode']){_0x4d8a9c['a']['_RemoveAndStorePivotPoint'](this['attachedNode']),_0x1eb9b8?(this['_startDragRay']['direction']['copyFrom'](_0x1eb9b8['direction']),this['_startDragRay']['origin']['copyFrom'](_0x1eb9b8['origin'])):(this['_startDragRay']['origin']['copyFrom'](this['_scene']['activeCamera']['position']),this['attachedNode']['getWorldMatrix']()['getTranslationToRef'](this['_tmpVector']),this['_tmpVector']['subtractToRef'](this['_scene']['activeCamera']['position'],this['_startDragRay']['direction'])),this['_updateDragPlanePosition'](this['_startDragRay'],_0x18f5e3||this['_tmpVector']);var _0x5eb124=this['_pickWithRayOnDragPlane'](this['_startDragRay']);_0x5eb124&&(this['dragging']=!0x0,this['currentDraggingPointerID']=_0x486d9f,this['lastDragPosition']['copyFrom'](_0x5eb124),this['onDragStartObservable']['notifyObservers']({'dragPlanePoint':_0x5eb124,'pointerId':this['currentDraggingPointerID']}),this['_targetPosition']['copyFrom'](this['attachedNode']['absolutePosition']),this['detachCameraControls']&&this['_scene']['activeCamera']&&this['_scene']['activeCamera']['inputs']&&!this['_scene']['activeCamera']['leftCamera']&&(this['_scene']['activeCamera']['inputs']['attachedToElement']?(this['_scene']['activeCamera']['detachControl'](),this['_attachedToElement']=!0x0):this['_attachedToElement']=!0x1)),_0x4d8a9c['a']['_RestorePivotPoint'](this['attachedNode']);}},_0x14dc17['prototype']['_moveDrag']=function(_0x1bbadb){this['_moving']=!0x0;var _0x46c779=this['_pickWithRayOnDragPlane'](_0x1bbadb);if(_0x46c779){this['updateDragPlane']&&this['_updateDragPlanePosition'](_0x1bbadb,_0x46c779);var _0x63146e=0x0;this['_options']['dragAxis']?(this['useObjectOrientationForDragging']?_0x52b07e['e']['TransformCoordinatesToRef'](this['_options']['dragAxis'],this['attachedNode']['getWorldMatrix']()['getRotationMatrix'](),this['_worldDragAxis']):this['_worldDragAxis']['copyFrom'](this['_options']['dragAxis']),_0x46c779['subtractToRef'](this['lastDragPosition'],this['_tmpVector']),_0x63146e=_0x52b07e['e']['Dot'](this['_tmpVector'],this['_worldDragAxis']),this['_worldDragAxis']['scaleToRef'](_0x63146e,this['_dragDelta'])):(_0x63146e=this['_dragDelta']['length'](),_0x46c779['subtractToRef'](this['lastDragPosition'],this['_dragDelta'])),this['_targetPosition']['addInPlace'](this['_dragDelta']),this['onDragObservable']['notifyObservers']({'dragDistance':_0x63146e,'delta':this['_dragDelta'],'dragPlanePoint':_0x46c779,'dragPlaneNormal':this['_dragPlane']['forward'],'pointerId':this['currentDraggingPointerID']}),this['lastDragPosition']['copyFrom'](_0x46c779);}},_0x14dc17['prototype']['_pickWithRayOnDragPlane']=function(_0x115081){var _0x5edc23=this;if(!_0x115081)return null;var _0x42494e=Math['acos'](_0x52b07e['e']['Dot'](this['_dragPlane']['forward'],_0x115081['direction']));if(_0x42494e>Math['PI']/0x2&&(_0x42494e=Math['PI']-_0x42494e),this['maxDragAngle']>0x0&&_0x42494e>this['maxDragAngle']){if(this['_useAlternatePickedPointAboveMaxDragAngle']){this['_tmpVector']['copyFrom'](_0x115081['direction']),this['attachedNode']['absolutePosition']['subtractToRef'](_0x115081['origin'],this['_alternatePickedPoint']),this['_alternatePickedPoint']['normalize'](),this['_alternatePickedPoint']['scaleInPlace'](this['_useAlternatePickedPointAboveMaxDragAngleDragSpeed']*_0x52b07e['e']['Dot'](this['_alternatePickedPoint'],this['_tmpVector'])),this['_tmpVector']['addInPlace'](this['_alternatePickedPoint']);var _0x13d215=_0x52b07e['e']['Dot'](this['_dragPlane']['forward'],this['_tmpVector']);return this['_dragPlane']['forward']['scaleToRef'](-_0x13d215,this['_alternatePickedPoint']),this['_alternatePickedPoint']['addInPlace'](this['_tmpVector']),this['_alternatePickedPoint']['addInPlace'](this['attachedNode']['absolutePosition']),this['_alternatePickedPoint'];}return null;}var _0x55322=_0x14dc17['_planeScene']['pickWithRay'](_0x115081,function(_0x55f2ba){return _0x55f2ba==_0x5edc23['_dragPlane'];});return _0x55322&&_0x55322['hit']&&_0x55322['pickedMesh']&&_0x55322['pickedPoint']?_0x55322['pickedPoint']:null;},_0x14dc17['prototype']['_updateDragPlanePosition']=function(_0x5c27d4,_0x330c03){this['_pointA']['copyFrom'](_0x330c03),this['_options']['dragAxis']?(this['useObjectOrientationForDragging']?_0x52b07e['e']['TransformCoordinatesToRef'](this['_options']['dragAxis'],this['attachedNode']['getWorldMatrix']()['getRotationMatrix'](),this['_localAxis']):this['_localAxis']['copyFrom'](this['_options']['dragAxis']),_0x5c27d4['origin']['subtractToRef'](this['_pointA'],this['_pointC']),this['_pointC']['normalize'](),Math['abs'](_0x52b07e['e']['Dot'](this['_localAxis'],this['_pointC']))>0.999?Math['abs'](_0x52b07e['e']['Dot'](_0x52b07e['e']['UpReadOnly'],this['_pointC']))>0.999?this['_lookAt']['copyFrom'](_0x52b07e['e']['Right']()):this['_lookAt']['copyFrom'](_0x52b07e['e']['UpReadOnly']):(_0x52b07e['e']['CrossToRef'](this['_localAxis'],this['_pointC'],this['_lookAt']),_0x52b07e['e']['CrossToRef'](this['_localAxis'],this['_lookAt'],this['_lookAt']),this['_lookAt']['normalize']()),this['_dragPlane']['position']['copyFrom'](this['_pointA']),this['_pointA']['addToRef'](this['_lookAt'],this['_lookAt']),this['_dragPlane']['lookAt'](this['_lookAt'])):this['_options']['dragPlaneNormal']?(this['useObjectOrientationForDragging']?_0x52b07e['e']['TransformCoordinatesToRef'](this['_options']['dragPlaneNormal'],this['attachedNode']['getWorldMatrix']()['getRotationMatrix'](),this['_localAxis']):this['_localAxis']['copyFrom'](this['_options']['dragPlaneNormal']),this['_dragPlane']['position']['copyFrom'](this['_pointA']),this['_pointA']['addToRef'](this['_localAxis'],this['_lookAt']),this['_dragPlane']['lookAt'](this['_lookAt'])):(this['_dragPlane']['position']['copyFrom'](this['_pointA']),this['_dragPlane']['lookAt'](_0x5c27d4['origin'])),this['_dragPlane']['position']['copyFrom'](this['attachedNode']['absolutePosition']),this['_dragPlane']['computeWorldMatrix'](!0x0);},_0x14dc17['prototype']['detach']=function(){this['_pointerObserver']&&this['_scene']['onPointerObservable']['remove'](this['_pointerObserver']),this['_beforeRenderObserver']&&this['_scene']['onBeforeRenderObservable']['remove'](this['_beforeRenderObserver']),this['releaseDrag']();},_0x14dc17['_AnyMouseID']=-0x2,_0x14dc17;}()));},function(_0x71a25,_0x1e9aa6,_0x2c9525){'use strict';_0x2c9525['d'](_0x1e9aa6,'a',function(){return _0x2e5eec;}),_0x2c9525['d'](_0x1e9aa6,'b',function(){return _0xd9491f;}),_0x2c9525['d'](_0x1e9aa6,'c',function(){return _0x487dfc;});var _0x4babe5=_0x2c9525(0x1),_0x2e5eec=(function(){function _0x8b6cfc(){}return _0x8b6cfc['KEYDOWN']=0x1,_0x8b6cfc['KEYUP']=0x2,_0x8b6cfc;}()),_0xd9491f=function(_0x49763f,_0x5c4299){this['type']=_0x49763f,this['event']=_0x5c4299;},_0x487dfc=function(_0x1b3e58){function _0x37563f(_0x4d739b,_0xef9627){var _0x5ce194=_0x1b3e58['call'](this,_0x4d739b,_0xef9627)||this;return _0x5ce194['type']=_0x4d739b,_0x5ce194['event']=_0xef9627,_0x5ce194['skipOnPointerObservable']=!0x1,_0x5ce194;}return Object(_0x4babe5['d'])(_0x37563f,_0x1b3e58),_0x37563f;}(_0xd9491f);},function(_0x1d4dc2,_0x4107e0,_0x18fb66){'use strict';_0x18fb66['d'](_0x4107e0,'a',function(){return _0x1c6238;});var _0x1c6238=(function(){function _0x16a83a(){this['_defines']={},this['_currentRank']=0x20,this['_maxRank']=-0x1,this['_mesh']=null;}return _0x16a83a['prototype']['unBindMesh']=function(){this['_mesh']=null;},_0x16a83a['prototype']['addFallback']=function(_0x1e9133,_0x2729c2){this['_defines'][_0x1e9133]||(_0x1e9133this['_maxRank']&&(this['_maxRank']=_0x1e9133),this['_defines'][_0x1e9133]=new Array()),this['_defines'][_0x1e9133]['push'](_0x2729c2);},_0x16a83a['prototype']['addCPUSkinningFallback']=function(_0x104fb8,_0x3833c5){this['_mesh']=_0x3833c5,_0x104fb8this['_maxRank']&&(this['_maxRank']=_0x104fb8);},Object['defineProperty'](_0x16a83a['prototype'],'hasMoreFallbacks',{'get':function(){return this['_currentRank']<=this['_maxRank'];},'enumerable':!0x1,'configurable':!0x0}),_0x16a83a['prototype']['reduce']=function(_0x240249,_0x5de1ec){if(this['_mesh']&&this['_mesh']['computeBonesUsingShaders']&&this['_mesh']['numBoneInfluencers']>0x0){this['_mesh']['computeBonesUsingShaders']=!0x1,_0x240249=_0x240249['replace']('#define\x20NUM_BONE_INFLUENCERS\x20'+this['_mesh']['numBoneInfluencers'],'#define\x20NUM_BONE_INFLUENCERS\x200'),_0x5de1ec['_bonesComputationForcedToCPU']=!0x0;for(var _0x157cd1=this['_mesh']['getScene'](),_0x5d521b=0x0;_0x5d521b<_0x157cd1['meshes']['length'];_0x5d521b++){var _0x573b61=_0x157cd1['meshes'][_0x5d521b];if(_0x573b61['material']){if(_0x573b61['computeBonesUsingShaders']&&0x0!==_0x573b61['numBoneInfluencers']){if(_0x573b61['material']['getEffect']()===_0x5de1ec)_0x573b61['computeBonesUsingShaders']=!0x1;else{if(_0x573b61['subMeshes'])for(var _0x1c3f2e=0x0,_0x1c6499=_0x573b61['subMeshes'];_0x1c3f2e<_0x1c6499['length'];_0x1c3f2e++){if(_0x1c6499[_0x1c3f2e]['effect']===_0x5de1ec){_0x573b61['computeBonesUsingShaders']=!0x1;break;}}}}}else!this['_mesh']['material']&&_0x573b61['computeBonesUsingShaders']&&_0x573b61['numBoneInfluencers']>0x0&&(_0x573b61['computeBonesUsingShaders']=!0x1);}}else{var _0x5ba136=this['_defines'][this['_currentRank']];if(_0x5ba136){for(_0x5d521b=0x0;_0x5d521b<_0x5ba136['length'];_0x5d521b++)_0x240249=_0x240249['replace']('#define\x20'+_0x5ba136[_0x5d521b],'');}this['_currentRank']++;}return _0x240249;},_0x16a83a;}());},function(_0x176def,_0x540578,_0x50bbed){'use strict';_0x50bbed['d'](_0x540578,'a',function(){return _0x1b8a64;});var _0x500e2b=_0x50bbed(0x1),_0x46f8d1=_0x50bbed(0x19),_0x42ce1f=_0x50bbed(0x25),_0xd1fffa=_0x50bbed(0xb),_0x1b8a64=function(_0x302fac){function _0x290f6f(_0x32f4e5,_0x3303ae){var _0x3e4d1c=_0x302fac['call'](this,_0x32f4e5,_0x3303ae,!0x0)||this;return _0x3303ae['multiMaterials']['push'](_0x3e4d1c),_0x3e4d1c['subMaterials']=new Array(),_0x3e4d1c['_storeEffectOnSubMeshes']=!0x0,_0x3e4d1c;}return Object(_0x500e2b['d'])(_0x290f6f,_0x302fac),Object['defineProperty'](_0x290f6f['prototype'],'subMaterials',{'get':function(){return this['_subMaterials'];},'set':function(_0x519bd0){this['_subMaterials']=_0x519bd0,this['_hookArray'](_0x519bd0);},'enumerable':!0x1,'configurable':!0x0}),_0x290f6f['prototype']['getChildren']=function(){return this['subMaterials'];},_0x290f6f['prototype']['_hookArray']=function(_0x28c2c5){var _0x40e815=this,_0x185f26=_0x28c2c5['push'];_0x28c2c5['push']=function(){for(var _0x2decce=[],_0x13af47=0x0;_0x13af47=this['subMaterials']['length']?this['getScene']()['defaultMaterial']:this['subMaterials'][_0x4deb71];},_0x290f6f['prototype']['getActiveTextures']=function(){var _0x4f98c1;return(_0x4f98c1=_0x302fac['prototype']['getActiveTextures']['call'](this))['concat']['apply'](_0x4f98c1,this['subMaterials']['map'](function(_0xb1b6c4){return _0xb1b6c4?_0xb1b6c4['getActiveTextures']():[];}));},_0x290f6f['prototype']['hasTexture']=function(_0x322327){var _0x42f8d5;if(_0x302fac['prototype']['hasTexture']['call'](this,_0x322327))return!0x0;for(var _0x5f2ab2=0x0;_0x5f2ab2=0x0&&_0x138fa6['multiMaterials']['splice'](_0x3da16f,0x1),_0x302fac['prototype']['dispose']['call'](this,_0x544fe4,_0x5abccb);}},_0x290f6f['ParseMultiMaterial']=function(_0x3ee9bf,_0x4717d4){var _0x1d6b7d=new _0x290f6f(_0x3ee9bf['name'],_0x4717d4);_0x1d6b7d['id']=_0x3ee9bf['id'],_0x42ce1f['a']&&_0x42ce1f['a']['AddTagsTo'](_0x1d6b7d,_0x3ee9bf['tags']);for(var _0x4d72fb=0x0;_0x4d72fb<_0x3ee9bf['materials']['length'];_0x4d72fb++){var _0x4aeaea=_0x3ee9bf['materials'][_0x4d72fb];_0x4aeaea?_0x1d6b7d['subMaterials']['push'](_0x4717d4['getLastMaterialByID'](_0x4aeaea)):_0x1d6b7d['subMaterials']['push'](null);}return _0x1d6b7d;},_0x290f6f;}(_0x46f8d1['a']);_0xd1fffa['a']['RegisteredTypes']['BABYLON.MultiMaterial']=_0x1b8a64;},function(_0xe3bb66,_0x447be5,_0x5788fc){'use strict';_0x5788fc['d'](_0x447be5,'a',function(){return _0x135589;});var _0x6ecc12=_0x5788fc(0x2),_0x135589=(function(){function _0x13e0ab(){}return Object['defineProperty'](_0x13e0ab,'ForceFullSceneLoadingForIncremental',{'get':function(){return _0x13e0ab['_ForceFullSceneLoadingForIncremental'];},'set':function(_0x5ea072){_0x13e0ab['_ForceFullSceneLoadingForIncremental']=_0x5ea072;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x13e0ab,'ShowLoadingScreen',{'get':function(){return _0x13e0ab['_ShowLoadingScreen'];},'set':function(_0x4224fd){_0x13e0ab['_ShowLoadingScreen']=_0x4224fd;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x13e0ab,'loggingLevel',{'get':function(){return _0x13e0ab['_loggingLevel'];},'set':function(_0x4a9182){_0x13e0ab['_loggingLevel']=_0x4a9182;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x13e0ab,'CleanBoneMatrixWeights',{'get':function(){return _0x13e0ab['_CleanBoneMatrixWeights'];},'set':function(_0x40d050){_0x13e0ab['_CleanBoneMatrixWeights']=_0x40d050;},'enumerable':!0x1,'configurable':!0x0}),_0x13e0ab['_ForceFullSceneLoadingForIncremental']=!0x1,_0x13e0ab['_ShowLoadingScreen']=!0x0,_0x13e0ab['_CleanBoneMatrixWeights']=!0x1,_0x13e0ab['_loggingLevel']=_0x6ecc12['a']['SCENELOADER_NO_LOGGING'],_0x13e0ab;}());},function(_0xb4f461,_0x269ea9,_0x283bcc){'use strict';_0x283bcc['d'](_0x269ea9,'a',function(){return _0x1423b2;});var _0x1423b2=(function(){function _0xad5e1d(){}return _0xad5e1d['CreateCanvas']=function(_0x53d1a6,_0x32d8b3){if('undefined'==typeof document)return new OffscreenCanvas(_0x53d1a6,_0x32d8b3);var _0x107a57=document['createElement']('canvas');return _0x107a57['width']=_0x53d1a6,_0x107a57['height']=_0x32d8b3,_0x107a57;},_0xad5e1d;}());},function(_0x270c96,_0x4be19e,_0x180499){'use strict';_0x180499['d'](_0x4be19e,'a',function(){return _0xf56612;});var _0x304ef6=_0x180499(0x0),_0x546704=_0x180499(0x9),_0x58998a=_0x180499(0x10),_0x3c67a7=_0x180499(0x4),_0x67ee45=_0x180499(0x3d),_0xc79627=_0x180499(0x45),_0x159afa=_0x180499(0x2b),_0x3aae97=_0x180499(0x2),_0x5ca53d=_0x180499(0xc),_0x381fd0=_0x180499(0x25),_0x497a76=_0x180499(0x65),_0xf56612=(function(){function _0x4cae7b(_0x426cfd,_0x3869e5,_0x2a4f2a,_0x413734,_0x1d8ac5){void 0x0===_0x413734&&(_0x413734=!0x1),void 0x0===_0x1d8ac5&&(_0x1d8ac5=null),this['delayLoadState']=_0x3aae97['a']['DELAYLOADSTATE_NONE'],this['_totalVertices']=0x0,this['_isDisposed']=!0x1,this['_indexBufferIsUpdatable']=!0x1,this['_positionsCache']=[],this['useBoundingInfoFromGeometry']=!0x1,this['id']=_0x426cfd,this['uniqueId']=_0x3869e5['getUniqueId'](),this['_engine']=_0x3869e5['getEngine'](),this['_meshes']=[],this['_scene']=_0x3869e5,this['_vertexBuffers']={},this['_indices']=[],this['_updatable']=_0x413734,_0x2a4f2a?this['setAllVerticesData'](_0x2a4f2a,_0x413734):(this['_totalVertices']=0x0,this['_indices']=[]),this['_engine']['getCaps']()['vertexArrayObject']&&(this['_vertexArrayObjects']={}),_0x1d8ac5&&(this['applyToMesh'](_0x1d8ac5),_0x1d8ac5['computeWorldMatrix'](!0x0));}return Object['defineProperty'](_0x4cae7b['prototype'],'boundingBias',{'get':function(){return this['_boundingBias'];},'set':function(_0x51573a){this['_boundingBias']?this['_boundingBias']['copyFrom'](_0x51573a):this['_boundingBias']=_0x51573a['clone'](),this['_updateBoundingInfo'](!0x0,null);},'enumerable':!0x1,'configurable':!0x0}),_0x4cae7b['CreateGeometryForMesh']=function(_0x244811){var _0x26d8cb=new _0x4cae7b(_0x4cae7b['RandomId'](),_0x244811['getScene']());return _0x26d8cb['applyToMesh'](_0x244811),_0x26d8cb;},Object['defineProperty'](_0x4cae7b['prototype'],'meshes',{'get':function(){return this['_meshes'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4cae7b['prototype'],'extend',{'get':function(){return this['_extend'];},'enumerable':!0x1,'configurable':!0x0}),_0x4cae7b['prototype']['getScene']=function(){return this['_scene'];},_0x4cae7b['prototype']['getEngine']=function(){return this['_engine'];},_0x4cae7b['prototype']['isReady']=function(){return this['delayLoadState']===_0x3aae97['a']['DELAYLOADSTATE_LOADED']||this['delayLoadState']===_0x3aae97['a']['DELAYLOADSTATE_NONE'];},Object['defineProperty'](_0x4cae7b['prototype'],'doNotSerialize',{'get':function(){for(var _0x19075d=0x0;_0x19075d0x0&&(this['_indexBuffer']=this['_engine']['createIndexBuffer'](this['_indices'])),this['_indexBuffer']&&(this['_indexBuffer']['references']=_0x368131),_0x1bcc2f['_syncGeometryWithMorphTargetManager'](),_0x1bcc2f['synchronizeInstances']();},_0x4cae7b['prototype']['notifyUpdate']=function(_0x115992){this['onGeometryUpdated']&&this['onGeometryUpdated'](this,_0x115992);for(var _0x27abfb=0x0,_0x3e018f=this['_meshes'];_0x27abfb<_0x3e018f['length'];_0x27abfb++){_0x3e018f[_0x27abfb]['_markSubMeshesAsAttributesDirty']();}},_0x4cae7b['prototype']['load']=function(_0x46f521,_0x45200c){this['delayLoadState']!==_0x3aae97['a']['DELAYLOADSTATE_LOADING']&&(this['isReady']()?_0x45200c&&_0x45200c():(this['delayLoadState']=_0x3aae97['a']['DELAYLOADSTATE_LOADING'],this['_queueLoad'](_0x46f521,_0x45200c)));},_0x4cae7b['prototype']['_queueLoad']=function(_0xd21c68,_0x30c7be){var _0x3afebd=this;this['delayLoadingFile']&&(_0xd21c68['_addPendingData'](this),_0xd21c68['_loadFile'](this['delayLoadingFile'],function(_0x57dea8){if(_0x3afebd['_delayLoadingFunction']){_0x3afebd['_delayLoadingFunction'](JSON['parse'](_0x57dea8),_0x3afebd),_0x3afebd['delayLoadState']=_0x3aae97['a']['DELAYLOADSTATE_LOADED'],_0x3afebd['_delayInfo']=[],_0xd21c68['_removePendingData'](_0x3afebd);for(var _0x57d656=_0x3afebd['_meshes'],_0x296e37=_0x57d656['length'],_0x164369=0x0;_0x164369<_0x296e37;_0x164369++)_0x3afebd['_applyToMesh'](_0x57d656[_0x164369]);_0x30c7be&&_0x30c7be();}},void 0x0,!0x0));},_0x4cae7b['prototype']['toLeftHanded']=function(){var _0x1c4ab7=this['getIndices'](!0x1);if(null!=_0x1c4ab7&&_0x1c4ab7['length']>0x0){for(var _0xd70db1=0x0;_0xd70db1<_0x1c4ab7['length'];_0xd70db1+=0x3){var _0x382630=_0x1c4ab7[_0xd70db1+0x0];_0x1c4ab7[_0xd70db1+0x0]=_0x1c4ab7[_0xd70db1+0x2],_0x1c4ab7[_0xd70db1+0x2]=_0x382630;}this['setIndices'](_0x1c4ab7);}var _0x4cb30b=this['getVerticesData'](_0x3c67a7['b']['PositionKind'],!0x1);if(null!=_0x4cb30b&&_0x4cb30b['length']>0x0){for(_0xd70db1=0x0;_0xd70db1<_0x4cb30b['length'];_0xd70db1+=0x3)_0x4cb30b[_0xd70db1+0x2]=-_0x4cb30b[_0xd70db1+0x2];this['setVerticesData'](_0x3c67a7['b']['PositionKind'],_0x4cb30b,!0x1);}var _0x180140=this['getVerticesData'](_0x3c67a7['b']['NormalKind'],!0x1);if(null!=_0x180140&&_0x180140['length']>0x0){for(_0xd70db1=0x0;_0xd70db1<_0x180140['length'];_0xd70db1+=0x3)_0x180140[_0xd70db1+0x2]=-_0x180140[_0xd70db1+0x2];this['setVerticesData'](_0x3c67a7['b']['NormalKind'],_0x180140,!0x1);}},_0x4cae7b['prototype']['_resetPointsArrayCache']=function(){this['_positions']=null;},_0x4cae7b['prototype']['_generatePointsArray']=function(){if(this['_positions'])return!0x0;var _0x45ad30=this['getVerticesData'](_0x3c67a7['b']['PositionKind']);if(!_0x45ad30||0x0===_0x45ad30['length'])return!0x1;for(var _0x235f2f=0x3*this['_positionsCache']['length'],_0x3b0230=this['_positionsCache']['length'];_0x235f2f<_0x45ad30['length'];_0x235f2f+=0x3,++_0x3b0230)this['_positionsCache'][_0x3b0230]=_0x304ef6['e']['FromArray'](_0x45ad30,_0x235f2f);for(_0x235f2f=0x0,_0x3b0230=0x0;_0x235f2f<_0x45ad30['length'];_0x235f2f+=0x3,++_0x3b0230)this['_positionsCache'][_0x3b0230]['set'](_0x45ad30[0x0+_0x235f2f],_0x45ad30[0x1+_0x235f2f],_0x45ad30[0x2+_0x235f2f]);return this['_positionsCache']['length']=_0x45ad30['length']/0x3,this['_positions']=this['_positionsCache'],!0x0;},_0x4cae7b['prototype']['isDisposed']=function(){return this['_isDisposed'];},_0x4cae7b['prototype']['_disposeVertexArrayObjects']=function(){if(this['_vertexArrayObjects']){for(var _0x61d6be in this['_vertexArrayObjects'])this['_engine']['releaseVertexArrayObject'](this['_vertexArrayObjects'][_0x61d6be]);this['_vertexArrayObjects']={};}},_0x4cae7b['prototype']['dispose']=function(){var _0x53c9e8,_0x17c601=this['_meshes'],_0xf82270=_0x17c601['length'];for(_0x53c9e8=0x0;_0x53c9e8<_0xf82270;_0x53c9e8++)this['releaseForMesh'](_0x17c601[_0x53c9e8]);for(var _0x39c1aa in(this['_meshes']=[],this['_disposeVertexArrayObjects'](),this['_vertexBuffers']))this['_vertexBuffers'][_0x39c1aa]['dispose']();this['_vertexBuffers']={},this['_totalVertices']=0x0,this['_indexBuffer']&&this['_engine']['_releaseBuffer'](this['_indexBuffer']),this['_indexBuffer']=null,this['_indices']=[],this['delayLoadState']=_0x3aae97['a']['DELAYLOADSTATE_NONE'],this['delayLoadingFile']=null,this['_delayLoadingFunction']=null,this['_delayInfo']=[],this['_boundingInfo']=null,this['_scene']['removeGeometry'](this),this['_isDisposed']=!0x0;},_0x4cae7b['prototype']['copy']=function(_0x57f13b){var _0x270c80=new _0x58998a['a']();_0x270c80['indices']=[];var _0x5da6eb=this['getIndices']();if(_0x5da6eb){for(var _0x1496e4=0x0;_0x1496e4<_0x5da6eb['length'];_0x1496e4++)_0x270c80['indices']['push'](_0x5da6eb[_0x1496e4]);}var _0x5724d2,_0x55dc64=!0x1,_0x325d6e=!0x1;for(_0x5724d2 in this['_vertexBuffers']){var _0x30f037=this['getVerticesData'](_0x5724d2);if(_0x30f037&&(_0x30f037 instanceof Float32Array?_0x270c80['set'](new Float32Array(_0x30f037),_0x5724d2):_0x270c80['set'](_0x30f037['slice'](0x0),_0x5724d2),!_0x325d6e)){var _0x2a4edf=this['getVertexBuffer'](_0x5724d2);_0x2a4edf&&(_0x325d6e=!(_0x55dc64=_0x2a4edf['isUpdatable']()));}}var _0x3b8ea8=new _0x4cae7b(_0x57f13b,this['_scene'],_0x270c80,_0x55dc64);for(_0x5724d2 in(_0x3b8ea8['delayLoadState']=this['delayLoadState'],_0x3b8ea8['delayLoadingFile']=this['delayLoadingFile'],_0x3b8ea8['_delayLoadingFunction']=this['_delayLoadingFunction'],this['_delayInfo']))_0x3b8ea8['_delayInfo']=_0x3b8ea8['_delayInfo']||[],_0x3b8ea8['_delayInfo']['push'](_0x5724d2);return _0x3b8ea8['_boundingInfo']=new _0x159afa['a'](this['_extend']['minimum'],this['_extend']['maximum']),_0x3b8ea8;},_0x4cae7b['prototype']['serialize']=function(){var _0x59815e={};return _0x59815e['id']=this['id'],_0x59815e['updatable']=this['_updatable'],_0x381fd0['a']&&_0x381fd0['a']['HasTags'](this)&&(_0x59815e['tags']=_0x381fd0['a']['GetTags'](this)),_0x59815e;},_0x4cae7b['prototype']['toNumberArray']=function(_0x11cf27){return Array['isArray'](_0x11cf27)?_0x11cf27:Array['prototype']['slice']['call'](_0x11cf27);},_0x4cae7b['prototype']['serializeVerticeData']=function(){var _0x5c4daf=this['serialize']();return this['isVerticesDataPresent'](_0x3c67a7['b']['PositionKind'])&&(_0x5c4daf['positions']=this['toNumberArray'](this['getVerticesData'](_0x3c67a7['b']['PositionKind'])),this['isVertexBufferUpdatable'](_0x3c67a7['b']['PositionKind'])&&(_0x5c4daf['positions']['_updatable']=!0x0)),this['isVerticesDataPresent'](_0x3c67a7['b']['NormalKind'])&&(_0x5c4daf['normals']=this['toNumberArray'](this['getVerticesData'](_0x3c67a7['b']['NormalKind'])),this['isVertexBufferUpdatable'](_0x3c67a7['b']['NormalKind'])&&(_0x5c4daf['normals']['_updatable']=!0x0)),this['isVerticesDataPresent'](_0x3c67a7['b']['TangentKind'])&&(_0x5c4daf['tangets']=this['toNumberArray'](this['getVerticesData'](_0x3c67a7['b']['TangentKind'])),this['isVertexBufferUpdatable'](_0x3c67a7['b']['TangentKind'])&&(_0x5c4daf['tangets']['_updatable']=!0x0)),this['isVerticesDataPresent'](_0x3c67a7['b']['UVKind'])&&(_0x5c4daf['uvs']=this['toNumberArray'](this['getVerticesData'](_0x3c67a7['b']['UVKind'])),this['isVertexBufferUpdatable'](_0x3c67a7['b']['UVKind'])&&(_0x5c4daf['uvs']['_updatable']=!0x0)),this['isVerticesDataPresent'](_0x3c67a7['b']['UV2Kind'])&&(_0x5c4daf['uv2s']=this['toNumberArray'](this['getVerticesData'](_0x3c67a7['b']['UV2Kind'])),this['isVertexBufferUpdatable'](_0x3c67a7['b']['UV2Kind'])&&(_0x5c4daf['uv2s']['_updatable']=!0x0)),this['isVerticesDataPresent'](_0x3c67a7['b']['UV3Kind'])&&(_0x5c4daf['uv3s']=this['toNumberArray'](this['getVerticesData'](_0x3c67a7['b']['UV3Kind'])),this['isVertexBufferUpdatable'](_0x3c67a7['b']['UV3Kind'])&&(_0x5c4daf['uv3s']['_updatable']=!0x0)),this['isVerticesDataPresent'](_0x3c67a7['b']['UV4Kind'])&&(_0x5c4daf['uv4s']=this['toNumberArray'](this['getVerticesData'](_0x3c67a7['b']['UV4Kind'])),this['isVertexBufferUpdatable'](_0x3c67a7['b']['UV4Kind'])&&(_0x5c4daf['uv4s']['_updatable']=!0x0)),this['isVerticesDataPresent'](_0x3c67a7['b']['UV5Kind'])&&(_0x5c4daf['uv5s']=this['toNumberArray'](this['getVerticesData'](_0x3c67a7['b']['UV5Kind'])),this['isVertexBufferUpdatable'](_0x3c67a7['b']['UV5Kind'])&&(_0x5c4daf['uv5s']['_updatable']=!0x0)),this['isVerticesDataPresent'](_0x3c67a7['b']['UV6Kind'])&&(_0x5c4daf['uv6s']=this['toNumberArray'](this['getVerticesData'](_0x3c67a7['b']['UV6Kind'])),this['isVertexBufferUpdatable'](_0x3c67a7['b']['UV6Kind'])&&(_0x5c4daf['uv6s']['_updatable']=!0x0)),this['isVerticesDataPresent'](_0x3c67a7['b']['ColorKind'])&&(_0x5c4daf['colors']=this['toNumberArray'](this['getVerticesData'](_0x3c67a7['b']['ColorKind'])),this['isVertexBufferUpdatable'](_0x3c67a7['b']['ColorKind'])&&(_0x5c4daf['colors']['_updatable']=!0x0)),this['isVerticesDataPresent'](_0x3c67a7['b']['MatricesIndicesKind'])&&(_0x5c4daf['matricesIndices']=this['toNumberArray'](this['getVerticesData'](_0x3c67a7['b']['MatricesIndicesKind'])),_0x5c4daf['matricesIndices']['_isExpanded']=!0x0,this['isVertexBufferUpdatable'](_0x3c67a7['b']['MatricesIndicesKind'])&&(_0x5c4daf['matricesIndices']['_updatable']=!0x0)),this['isVerticesDataPresent'](_0x3c67a7['b']['MatricesWeightsKind'])&&(_0x5c4daf['matricesWeights']=this['toNumberArray'](this['getVerticesData'](_0x3c67a7['b']['MatricesWeightsKind'])),this['isVertexBufferUpdatable'](_0x3c67a7['b']['MatricesWeightsKind'])&&(_0x5c4daf['matricesWeights']['_updatable']=!0x0)),_0x5c4daf['indices']=this['toNumberArray'](this['getIndices']()),_0x5c4daf;},_0x4cae7b['ExtractFromMesh']=function(_0x33ce8a,_0x9f8b16){var _0x3a0c6b=_0x33ce8a['_geometry'];return _0x3a0c6b?_0x3a0c6b['copy'](_0x9f8b16):null;},_0x4cae7b['RandomId']=function(){return _0x5ca53d['b']['RandomId']();},_0x4cae7b['_ImportGeometry']=function(_0x346656,_0x269f19){var _0x6dbe8b=_0x269f19['getScene'](),_0x13baf8=_0x346656['geometryId'];if(_0x13baf8){var _0x239b76=_0x6dbe8b['getGeometryByID'](_0x13baf8);_0x239b76&&_0x239b76['applyToMesh'](_0x269f19);}else{if(_0x346656 instanceof ArrayBuffer){var _0x379673=_0x269f19['_binaryInfo'];if(_0x379673['positionsAttrDesc']&&_0x379673['positionsAttrDesc']['count']>0x0){var _0x8d3e61=new Float32Array(_0x346656,_0x379673['positionsAttrDesc']['offset'],_0x379673['positionsAttrDesc']['count']);_0x269f19['setVerticesData'](_0x3c67a7['b']['PositionKind'],_0x8d3e61,!0x1);}if(_0x379673['normalsAttrDesc']&&_0x379673['normalsAttrDesc']['count']>0x0){var _0x5c4da4=new Float32Array(_0x346656,_0x379673['normalsAttrDesc']['offset'],_0x379673['normalsAttrDesc']['count']);_0x269f19['setVerticesData'](_0x3c67a7['b']['NormalKind'],_0x5c4da4,!0x1);}if(_0x379673['tangetsAttrDesc']&&_0x379673['tangetsAttrDesc']['count']>0x0){var _0xa9e736=new Float32Array(_0x346656,_0x379673['tangetsAttrDesc']['offset'],_0x379673['tangetsAttrDesc']['count']);_0x269f19['setVerticesData'](_0x3c67a7['b']['TangentKind'],_0xa9e736,!0x1);}if(_0x379673['uvsAttrDesc']&&_0x379673['uvsAttrDesc']['count']>0x0){var _0x37ec17=new Float32Array(_0x346656,_0x379673['uvsAttrDesc']['offset'],_0x379673['uvsAttrDesc']['count']);_0x269f19['setVerticesData'](_0x3c67a7['b']['UVKind'],_0x37ec17,!0x1);}if(_0x379673['uvs2AttrDesc']&&_0x379673['uvs2AttrDesc']['count']>0x0){var _0x21c57d=new Float32Array(_0x346656,_0x379673['uvs2AttrDesc']['offset'],_0x379673['uvs2AttrDesc']['count']);_0x269f19['setVerticesData'](_0x3c67a7['b']['UV2Kind'],_0x21c57d,!0x1);}if(_0x379673['uvs3AttrDesc']&&_0x379673['uvs3AttrDesc']['count']>0x0){var _0x52053b=new Float32Array(_0x346656,_0x379673['uvs3AttrDesc']['offset'],_0x379673['uvs3AttrDesc']['count']);_0x269f19['setVerticesData'](_0x3c67a7['b']['UV3Kind'],_0x52053b,!0x1);}if(_0x379673['uvs4AttrDesc']&&_0x379673['uvs4AttrDesc']['count']>0x0){var _0x2c3b8e=new Float32Array(_0x346656,_0x379673['uvs4AttrDesc']['offset'],_0x379673['uvs4AttrDesc']['count']);_0x269f19['setVerticesData'](_0x3c67a7['b']['UV4Kind'],_0x2c3b8e,!0x1);}if(_0x379673['uvs5AttrDesc']&&_0x379673['uvs5AttrDesc']['count']>0x0){var _0x187099=new Float32Array(_0x346656,_0x379673['uvs5AttrDesc']['offset'],_0x379673['uvs5AttrDesc']['count']);_0x269f19['setVerticesData'](_0x3c67a7['b']['UV5Kind'],_0x187099,!0x1);}if(_0x379673['uvs6AttrDesc']&&_0x379673['uvs6AttrDesc']['count']>0x0){var _0x4d2a39=new Float32Array(_0x346656,_0x379673['uvs6AttrDesc']['offset'],_0x379673['uvs6AttrDesc']['count']);_0x269f19['setVerticesData'](_0x3c67a7['b']['UV6Kind'],_0x4d2a39,!0x1);}if(_0x379673['colorsAttrDesc']&&_0x379673['colorsAttrDesc']['count']>0x0){var _0x48a534=new Float32Array(_0x346656,_0x379673['colorsAttrDesc']['offset'],_0x379673['colorsAttrDesc']['count']);_0x269f19['setVerticesData'](_0x3c67a7['b']['ColorKind'],_0x48a534,!0x1,_0x379673['colorsAttrDesc']['stride']);}if(_0x379673['matricesIndicesAttrDesc']&&_0x379673['matricesIndicesAttrDesc']['count']>0x0){for(var _0x240cbe=new Int32Array(_0x346656,_0x379673['matricesIndicesAttrDesc']['offset'],_0x379673['matricesIndicesAttrDesc']['count']),_0x44371a=[],_0x1a4c23=0x0;_0x1a4c23<_0x240cbe['length'];_0x1a4c23++){var _0x39a641=_0x240cbe[_0x1a4c23];_0x44371a['push'](0xff&_0x39a641),_0x44371a['push']((0xff00&_0x39a641)>>0x8),_0x44371a['push']((0xff0000&_0x39a641)>>0x10),_0x44371a['push'](_0x39a641>>0x18&0xff);}_0x269f19['setVerticesData'](_0x3c67a7['b']['MatricesIndicesKind'],_0x44371a,!0x1);}if(_0x379673['matricesIndicesExtraAttrDesc']&&_0x379673['matricesIndicesExtraAttrDesc']['count']>0x0){for(_0x240cbe=new Int32Array(_0x346656,_0x379673['matricesIndicesExtraAttrDesc']['offset'],_0x379673['matricesIndicesExtraAttrDesc']['count']),_0x44371a=[],_0x1a4c23=0x0;_0x1a4c23<_0x240cbe['length'];_0x1a4c23++){_0x39a641=_0x240cbe[_0x1a4c23],(_0x44371a['push'](0xff&_0x39a641),_0x44371a['push']((0xff00&_0x39a641)>>0x8),_0x44371a['push']((0xff0000&_0x39a641)>>0x10),_0x44371a['push'](_0x39a641>>0x18&0xff));}_0x269f19['setVerticesData'](_0x3c67a7['b']['MatricesIndicesExtraKind'],_0x44371a,!0x1);}if(_0x379673['matricesWeightsAttrDesc']&&_0x379673['matricesWeightsAttrDesc']['count']>0x0){var _0x3951fe=new Float32Array(_0x346656,_0x379673['matricesWeightsAttrDesc']['offset'],_0x379673['matricesWeightsAttrDesc']['count']);_0x269f19['setVerticesData'](_0x3c67a7['b']['MatricesWeightsKind'],_0x3951fe,!0x1);}if(_0x379673['indicesAttrDesc']&&_0x379673['indicesAttrDesc']['count']>0x0){var _0x3c4b0b=new Int32Array(_0x346656,_0x379673['indicesAttrDesc']['offset'],_0x379673['indicesAttrDesc']['count']);_0x269f19['setIndices'](_0x3c4b0b,null);}if(_0x379673['subMeshesAttrDesc']&&_0x379673['subMeshesAttrDesc']['count']>0x0){var _0xa20a32=new Int32Array(_0x346656,_0x379673['subMeshesAttrDesc']['offset'],0x5*_0x379673['subMeshesAttrDesc']['count']);_0x269f19['subMeshes']=[];for(_0x1a4c23=0x0;_0x1a4c23<_0x379673['subMeshesAttrDesc']['count'];_0x1a4c23++){var _0x2a768e=_0xa20a32[0x5*_0x1a4c23+0x0],_0x50ad2c=_0xa20a32[0x5*_0x1a4c23+0x1],_0x3b312f=_0xa20a32[0x5*_0x1a4c23+0x2],_0x3656df=_0xa20a32[0x5*_0x1a4c23+0x3],_0x1c501f=_0xa20a32[0x5*_0x1a4c23+0x4];_0x67ee45['a']['AddToMesh'](_0x2a768e,_0x50ad2c,_0x3b312f,_0x3656df,_0x1c501f,_0x269f19);}}}else{if(_0x346656['positions']&&_0x346656['normals']&&_0x346656['indices']){if(_0x269f19['setVerticesData'](_0x3c67a7['b']['PositionKind'],_0x346656['positions'],_0x346656['positions']['_updatable']),_0x269f19['setVerticesData'](_0x3c67a7['b']['NormalKind'],_0x346656['normals'],_0x346656['normals']['_updatable']),_0x346656['tangents']&&_0x269f19['setVerticesData'](_0x3c67a7['b']['TangentKind'],_0x346656['tangents'],_0x346656['tangents']['_updatable']),_0x346656['uvs']&&_0x269f19['setVerticesData'](_0x3c67a7['b']['UVKind'],_0x346656['uvs'],_0x346656['uvs']['_updatable']),_0x346656['uvs2']&&_0x269f19['setVerticesData'](_0x3c67a7['b']['UV2Kind'],_0x346656['uvs2'],_0x346656['uvs2']['_updatable']),_0x346656['uvs3']&&_0x269f19['setVerticesData'](_0x3c67a7['b']['UV3Kind'],_0x346656['uvs3'],_0x346656['uvs3']['_updatable']),_0x346656['uvs4']&&_0x269f19['setVerticesData'](_0x3c67a7['b']['UV4Kind'],_0x346656['uvs4'],_0x346656['uvs4']['_updatable']),_0x346656['uvs5']&&_0x269f19['setVerticesData'](_0x3c67a7['b']['UV5Kind'],_0x346656['uvs5'],_0x346656['uvs5']['_updatable']),_0x346656['uvs6']&&_0x269f19['setVerticesData'](_0x3c67a7['b']['UV6Kind'],_0x346656['uvs6'],_0x346656['uvs6']['_updatable']),_0x346656['colors']&&_0x269f19['setVerticesData'](_0x3c67a7['b']['ColorKind'],_0x546704['b']['CheckColors4'](_0x346656['colors'],_0x346656['positions']['length']/0x3),_0x346656['colors']['_updatable']),_0x346656['matricesIndices']){if(_0x346656['matricesIndices']['_isExpanded'])delete _0x346656['matricesIndices']['_isExpanded'],_0x269f19['setVerticesData'](_0x3c67a7['b']['MatricesIndicesKind'],_0x346656['matricesIndices'],_0x346656['matricesIndices']['_updatable']);else{for(_0x44371a=[],_0x1a4c23=0x0;_0x1a4c23<_0x346656['matricesIndices']['length'];_0x1a4c23++){var _0x5ad82b=_0x346656['matricesIndices'][_0x1a4c23];_0x44371a['push'](0xff&_0x5ad82b),_0x44371a['push']((0xff00&_0x5ad82b)>>0x8),_0x44371a['push']((0xff0000&_0x5ad82b)>>0x10),_0x44371a['push'](_0x5ad82b>>0x18&0xff);}_0x269f19['setVerticesData'](_0x3c67a7['b']['MatricesIndicesKind'],_0x44371a,_0x346656['matricesIndices']['_updatable']);}}if(_0x346656['matricesIndicesExtra']){if(_0x346656['matricesIndicesExtra']['_isExpanded'])delete _0x346656['matricesIndices']['_isExpanded'],_0x269f19['setVerticesData'](_0x3c67a7['b']['MatricesIndicesExtraKind'],_0x346656['matricesIndicesExtra'],_0x346656['matricesIndicesExtra']['_updatable']);else{for(_0x44371a=[],_0x1a4c23=0x0;_0x1a4c23<_0x346656['matricesIndicesExtra']['length'];_0x1a4c23++){_0x5ad82b=_0x346656['matricesIndicesExtra'][_0x1a4c23],(_0x44371a['push'](0xff&_0x5ad82b),_0x44371a['push']((0xff00&_0x5ad82b)>>0x8),_0x44371a['push']((0xff0000&_0x5ad82b)>>0x10),_0x44371a['push'](_0x5ad82b>>0x18&0xff));}_0x269f19['setVerticesData'](_0x3c67a7['b']['MatricesIndicesExtraKind'],_0x44371a,_0x346656['matricesIndicesExtra']['_updatable']);}}_0x346656['matricesWeights']&&(_0x4cae7b['_CleanMatricesWeights'](_0x346656,_0x269f19),_0x269f19['setVerticesData'](_0x3c67a7['b']['MatricesWeightsKind'],_0x346656['matricesWeights'],_0x346656['matricesWeights']['_updatable'])),_0x346656['matricesWeightsExtra']&&_0x269f19['setVerticesData'](_0x3c67a7['b']['MatricesWeightsExtraKind'],_0x346656['matricesWeightsExtra'],_0x346656['matricesWeights']['_updatable']),_0x269f19['setIndices'](_0x346656['indices'],null);}}}if(_0x346656['subMeshes']){_0x269f19['subMeshes']=[];for(var _0x2b8768=0x0;_0x2b8768<_0x346656['subMeshes']['length'];_0x2b8768++){var _0x9a4897=_0x346656['subMeshes'][_0x2b8768];_0x67ee45['a']['AddToMesh'](_0x9a4897['materialIndex'],_0x9a4897['verticesStart'],_0x9a4897['verticesCount'],_0x9a4897['indexStart'],_0x9a4897['indexCount'],_0x269f19);}}_0x269f19['_shouldGenerateFlatShading']&&(_0x269f19['convertToFlatShadedMesh'](),_0x269f19['_shouldGenerateFlatShading']=!0x1),_0x269f19['computeWorldMatrix'](!0x0),_0x6dbe8b['onMeshImportedObservable']['notifyObservers'](_0x269f19);},_0x4cae7b['_CleanMatricesWeights']=function(_0x36fdaf,_0x844f9f){if(_0xc79627['a']['CleanBoneMatrixWeights']){var _0x20a043=0x0;if(_0x36fdaf['skeletonId']>-0x1){var _0x333ef3=_0x844f9f['getScene']()['getLastSkeletonByID'](_0x36fdaf['skeletonId']);if(_0x333ef3){_0x20a043=_0x333ef3['bones']['length'];for(var _0x3fe938=_0x844f9f['getVerticesData'](_0x3c67a7['b']['MatricesIndicesKind']),_0x3e2843=_0x844f9f['getVerticesData'](_0x3c67a7['b']['MatricesIndicesExtraKind']),_0x19853d=_0x36fdaf['matricesWeights'],_0x237a81=_0x36fdaf['matricesWeightsExtra'],_0x3e4a19=_0x36fdaf['numBoneInfluencer'],_0x14b3de=_0x19853d['length'],_0x31f8b2=0x0;_0x31f8b2<_0x14b3de;_0x31f8b2+=0x4){for(var _0x29c619=0x0,_0x145815=-0x1,_0x4025b0=0x0;_0x4025b0<0x4;_0x4025b0++){_0x29c619+=_0x19cb20=_0x19853d[_0x31f8b2+_0x4025b0],_0x19cb20<0.001&&_0x145815<0x0&&(_0x145815=_0x4025b0);}if(_0x237a81)for(_0x4025b0=0x0;_0x4025b0<0x4;_0x4025b0++){var _0x19cb20;_0x29c619+=_0x19cb20=_0x237a81[_0x31f8b2+_0x4025b0],_0x19cb20<0.001&&_0x145815<0x0&&(_0x145815=_0x4025b0+0x4);}if((_0x145815<0x0||_0x145815>_0x3e4a19-0x1)&&(_0x145815=_0x3e4a19-0x1),_0x29c619>0.001){var _0x1b6486=0x1/_0x29c619;for(_0x4025b0=0x0;_0x4025b0<0x4;_0x4025b0++)_0x19853d[_0x31f8b2+_0x4025b0]*=_0x1b6486;if(_0x237a81){for(_0x4025b0=0x0;_0x4025b0<0x4;_0x4025b0++)_0x237a81[_0x31f8b2+_0x4025b0]*=_0x1b6486;}}else _0x145815>=0x4?(_0x237a81[_0x31f8b2+_0x145815-0x4]=0x1-_0x29c619,_0x3e2843[_0x31f8b2+_0x145815-0x4]=_0x20a043):(_0x19853d[_0x31f8b2+_0x145815]=0x1-_0x29c619,_0x3fe938[_0x31f8b2+_0x145815]=_0x20a043);}_0x844f9f['setVerticesData'](_0x3c67a7['b']['MatricesIndicesKind'],_0x3fe938),_0x36fdaf['matricesWeightsExtra']&&_0x844f9f['setVerticesData'](_0x3c67a7['b']['MatricesIndicesExtraKind'],_0x3e2843);}}}},_0x4cae7b['Parse']=function(_0x3345f1,_0x3ac39e,_0x369937){if(_0x3ac39e['getGeometryByID'](_0x3345f1['id']))return null;var _0x246a41=new _0x4cae7b(_0x3345f1['id'],_0x3ac39e,void 0x0,_0x3345f1['updatable']);return _0x381fd0['a']&&_0x381fd0['a']['AddTagsTo'](_0x246a41,_0x3345f1['tags']),_0x3345f1['delayLoadingFile']?(_0x246a41['delayLoadState']=_0x3aae97['a']['DELAYLOADSTATE_NOTLOADED'],_0x246a41['delayLoadingFile']=_0x369937+_0x3345f1['delayLoadingFile'],_0x246a41['_boundingInfo']=new _0x159afa['a'](_0x304ef6['e']['FromArray'](_0x3345f1['boundingBoxMinimum']),_0x304ef6['e']['FromArray'](_0x3345f1['boundingBoxMaximum'])),_0x246a41['_delayInfo']=[],_0x3345f1['hasUVs']&&_0x246a41['_delayInfo']['push'](_0x3c67a7['b']['UVKind']),_0x3345f1['hasUVs2']&&_0x246a41['_delayInfo']['push'](_0x3c67a7['b']['UV2Kind']),_0x3345f1['hasUVs3']&&_0x246a41['_delayInfo']['push'](_0x3c67a7['b']['UV3Kind']),_0x3345f1['hasUVs4']&&_0x246a41['_delayInfo']['push'](_0x3c67a7['b']['UV4Kind']),_0x3345f1['hasUVs5']&&_0x246a41['_delayInfo']['push'](_0x3c67a7['b']['UV5Kind']),_0x3345f1['hasUVs6']&&_0x246a41['_delayInfo']['push'](_0x3c67a7['b']['UV6Kind']),_0x3345f1['hasColors']&&_0x246a41['_delayInfo']['push'](_0x3c67a7['b']['ColorKind']),_0x3345f1['hasMatricesIndices']&&_0x246a41['_delayInfo']['push'](_0x3c67a7['b']['MatricesIndicesKind']),_0x3345f1['hasMatricesWeights']&&_0x246a41['_delayInfo']['push'](_0x3c67a7['b']['MatricesWeightsKind']),_0x246a41['_delayLoadingFunction']=_0x58998a['a']['ImportVertexData']):_0x58998a['a']['ImportVertexData'](_0x3345f1,_0x246a41),_0x3ac39e['pushGeometry'](_0x246a41,!0x0),_0x246a41;},_0x4cae7b;}());},function(_0xcc9635,_0x254130,_0x443812){'use strict';_0x443812['d'](_0x254130,'e',function(){return _0x37d0ec;}),_0x443812['d'](_0x254130,'c',function(){return _0x550e4f;}),_0x443812['d'](_0x254130,'a',function(){return _0x1ebc8b;}),_0x443812['d'](_0x254130,'b',function(){return _0x13a4f9;}),_0x443812['d'](_0x254130,'f',function(){return _0x87c77d;}),_0x443812['d'](_0x254130,'g',function(){return _0x59f51e;}),_0x443812['d'](_0x254130,'d',function(){return _0x36d807;});var _0x37d0ec,_0x57e2bd=_0x443812(0xe),_0x30ed6e=_0x443812(0x0),_0x5a30c1=_0x443812(0x1c);!function(_0x4e8e2d){_0x4e8e2d[_0x4e8e2d['CW']=0x0]='CW',_0x4e8e2d[_0x4e8e2d['CCW']=0x1]='CCW';}(_0x37d0ec||(_0x37d0ec={}));var _0x550e4f=(function(){function _0x43c47a(){}return _0x43c47a['Interpolate']=function(_0x33ff48,_0x35f4fd,_0x12be71,_0x43bedc,_0x5646d4){for(var _0x481be2=0x1-0x3*_0x43bedc+0x3*_0x35f4fd,_0x2b347a=0x3*_0x43bedc-0x6*_0x35f4fd,_0x44ea4e=0x3*_0x35f4fd,_0x51b837=_0x33ff48,_0x3a6b0b=0x0;_0x3a6b0b<0x5;_0x3a6b0b++){var _0x5a5716=_0x51b837*_0x51b837;_0x51b837-=(_0x481be2*(_0x5a5716*_0x51b837)+_0x2b347a*_0x5a5716+_0x44ea4e*_0x51b837-_0x33ff48)*(0x1/(0x3*_0x481be2*_0x5a5716+0x2*_0x2b347a*_0x51b837+_0x44ea4e)),_0x51b837=Math['min'](0x1,Math['max'](0x0,_0x51b837));}return 0x3*Math['pow'](0x1-_0x51b837,0x2)*_0x51b837*_0x12be71+0x3*(0x1-_0x51b837)*Math['pow'](_0x51b837,0x2)*_0x5646d4+Math['pow'](_0x51b837,0x3);},_0x43c47a;}()),_0x1ebc8b=(function(){function _0x362dda(_0x2469d1){this['_radians']=_0x2469d1,this['_radians']<0x0&&(this['_radians']+=0x2*Math['PI']);}return _0x362dda['prototype']['degrees']=function(){return 0xb4*this['_radians']/Math['PI'];},_0x362dda['prototype']['radians']=function(){return this['_radians'];},_0x362dda['BetweenTwoPoints']=function(_0x1135d0,_0x21803f){var _0x50f36b=_0x21803f['subtract'](_0x1135d0);return new _0x362dda(Math['atan2'](_0x50f36b['y'],_0x50f36b['x']));},_0x362dda['FromRadians']=function(_0x4ead4e){return new _0x362dda(_0x4ead4e);},_0x362dda['FromDegrees']=function(_0x1340a7){return new _0x362dda(_0x1340a7*Math['PI']/0xb4);},_0x362dda;}()),_0x13a4f9=function(_0x2dfc29,_0xdde70f,_0x322c36){this['startPoint']=_0x2dfc29,this['midPoint']=_0xdde70f,this['endPoint']=_0x322c36;var _0x426fd3=Math['pow'](_0xdde70f['x'],0x2)+Math['pow'](_0xdde70f['y'],0x2),_0x45de26=(Math['pow'](_0x2dfc29['x'],0x2)+Math['pow'](_0x2dfc29['y'],0x2)-_0x426fd3)/0x2,_0x4cdc67=(_0x426fd3-Math['pow'](_0x322c36['x'],0x2)-Math['pow'](_0x322c36['y'],0x2))/0x2,_0x1a4be8=(_0x2dfc29['x']-_0xdde70f['x'])*(_0xdde70f['y']-_0x322c36['y'])-(_0xdde70f['x']-_0x322c36['x'])*(_0x2dfc29['y']-_0xdde70f['y']);this['centerPoint']=new _0x30ed6e['d']((_0x45de26*(_0xdde70f['y']-_0x322c36['y'])-_0x4cdc67*(_0x2dfc29['y']-_0xdde70f['y']))/_0x1a4be8,((_0x2dfc29['x']-_0xdde70f['x'])*_0x4cdc67-(_0xdde70f['x']-_0x322c36['x'])*_0x45de26)/_0x1a4be8),this['radius']=this['centerPoint']['subtract'](this['startPoint'])['length'](),this['startAngle']=_0x1ebc8b['BetweenTwoPoints'](this['centerPoint'],this['startPoint']);var _0x1528b8=this['startAngle']['degrees'](),_0x204be6=_0x1ebc8b['BetweenTwoPoints'](this['centerPoint'],this['midPoint'])['degrees'](),_0x1d1ff4=_0x1ebc8b['BetweenTwoPoints'](this['centerPoint'],this['endPoint'])['degrees']();_0x204be6-_0x1528b8>0xb4&&(_0x204be6-=0x168),_0x204be6-_0x1528b8<-0xb4&&(_0x204be6+=0x168),_0x1d1ff4-_0x204be6>0xb4&&(_0x1d1ff4-=0x168),_0x1d1ff4-_0x204be6<-0xb4&&(_0x1d1ff4+=0x168),this['orientation']=_0x204be6-_0x1528b8<0x0?_0x37d0ec['CW']:_0x37d0ec['CCW'],this['angle']=_0x1ebc8b['FromDegrees'](this['orientation']===_0x37d0ec['CW']?_0x1528b8-_0x1d1ff4:_0x1d1ff4-_0x1528b8);},_0x87c77d=(function(){function _0x3964ea(_0x3a7df1,_0x249201){this['_points']=new Array(),this['_length']=0x0,this['closed']=!0x1,this['_points']['push'](new _0x30ed6e['d'](_0x3a7df1,_0x249201));}return _0x3964ea['prototype']['addLineTo']=function(_0x3d6e80,_0x596071){if(this['closed'])return this;var _0x3162a4=new _0x30ed6e['d'](_0x3d6e80,_0x596071),_0x1efd6e=this['_points'][this['_points']['length']-0x1];return this['_points']['push'](_0x3162a4),this['_length']+=_0x3162a4['subtract'](_0x1efd6e)['length'](),this;},_0x3964ea['prototype']['addArcTo']=function(_0x589091,_0x4b7984,_0x9c43ee,_0x229b96,_0x115e8d){if(void 0x0===_0x115e8d&&(_0x115e8d=0x24),this['closed'])return this;var _0x2e1d06=this['_points'][this['_points']['length']-0x1],_0x27d292=new _0x30ed6e['d'](_0x589091,_0x4b7984),_0x51cfa3=new _0x30ed6e['d'](_0x9c43ee,_0x229b96),_0x2b09bb=new _0x13a4f9(_0x2e1d06,_0x27d292,_0x51cfa3),_0x2c3abd=_0x2b09bb['angle']['radians']()/_0x115e8d;_0x2b09bb['orientation']===_0x37d0ec['CW']&&(_0x2c3abd*=-0x1);for(var _0x376401=_0x2b09bb['startAngle']['radians']()+_0x2c3abd,_0x19c0cb=0x0;_0x19c0cb<_0x115e8d;_0x19c0cb++){var _0x526da3=Math['cos'](_0x376401)*_0x2b09bb['radius']+_0x2b09bb['centerPoint']['x'],_0x389972=Math['sin'](_0x376401)*_0x2b09bb['radius']+_0x2b09bb['centerPoint']['y'];this['addLineTo'](_0x526da3,_0x389972),_0x376401+=_0x2c3abd;}return this;},_0x3964ea['prototype']['close']=function(){return this['closed']=!0x0,this;},_0x3964ea['prototype']['length']=function(){var _0x246a3b=this['_length'];if(this['closed']){var _0x103b5a=this['_points'][this['_points']['length']-0x1];_0x246a3b+=this['_points'][0x0]['subtract'](_0x103b5a)['length']();}return _0x246a3b;},_0x3964ea['prototype']['getPoints']=function(){return this['_points'];},_0x3964ea['prototype']['getPointAtLengthPosition']=function(_0x21ac8b){if(_0x21ac8b<0x0||_0x21ac8b>0x1)return _0x30ed6e['d']['Zero']();for(var _0x3d52d5=_0x21ac8b*this['length'](),_0x1f4646=0x0,_0x5f5b09=0x0;_0x5f5b09=_0x1f4646&&_0x3d52d5<=_0x47e5ea){var _0x1545f3=_0x1ca247['normalize'](),_0x28e46b=_0x3d52d5-_0x1f4646;return new _0x30ed6e['d'](_0x33e5e9['x']+_0x1545f3['x']*_0x28e46b,_0x33e5e9['y']+_0x1545f3['y']*_0x28e46b);}_0x1f4646=_0x47e5ea;}return _0x30ed6e['d']['Zero']();},_0x3964ea['StartingAt']=function(_0x106559,_0x4e8d63){return new _0x3964ea(_0x106559,_0x4e8d63);},_0x3964ea;}()),_0x59f51e=(function(){function _0x37c447(_0x3d28b0,_0x2da824,_0x31900b,_0xbab9dd){void 0x0===_0x2da824&&(_0x2da824=null),void 0x0===_0xbab9dd&&(_0xbab9dd=!0x1),this['path']=_0x3d28b0,this['_curve']=new Array(),this['_distances']=new Array(),this['_tangents']=new Array(),this['_normals']=new Array(),this['_binormals']=new Array(),this['_pointAtData']={'id':0x0,'point':_0x30ed6e['e']['Zero'](),'previousPointArrayIndex':0x0,'position':0x0,'subPosition':0x0,'interpolateReady':!0x1,'interpolationMatrix':_0x30ed6e['a']['Identity']()};for(var _0xda98ac=0x0;_0xda98ac<_0x3d28b0['length'];_0xda98ac++)this['_curve'][_0xda98ac]=_0x3d28b0[_0xda98ac]['clone']();this['_raw']=_0x31900b||!0x1,this['_alignTangentsWithPath']=_0xbab9dd,this['_compute'](_0x2da824,_0xbab9dd);}return _0x37c447['prototype']['getCurve']=function(){return this['_curve'];},_0x37c447['prototype']['getPoints']=function(){return this['_curve'];},_0x37c447['prototype']['length']=function(){return this['_distances'][this['_distances']['length']-0x1];},_0x37c447['prototype']['getTangents']=function(){return this['_tangents'];},_0x37c447['prototype']['getNormals']=function(){return this['_normals'];},_0x37c447['prototype']['getBinormals']=function(){return this['_binormals'];},_0x37c447['prototype']['getDistances']=function(){return this['_distances'];},_0x37c447['prototype']['getPointAt']=function(_0x4b7a75){return this['_updatePointAtData'](_0x4b7a75)['point'];},_0x37c447['prototype']['getTangentAt']=function(_0x270290,_0x364b6a){return void 0x0===_0x364b6a&&(_0x364b6a=!0x1),this['_updatePointAtData'](_0x270290,_0x364b6a),_0x364b6a?_0x30ed6e['e']['TransformCoordinates'](_0x30ed6e['e']['Forward'](),this['_pointAtData']['interpolationMatrix']):this['_tangents'][this['_pointAtData']['previousPointArrayIndex']];},_0x37c447['prototype']['getNormalAt']=function(_0x29c788,_0x43169e){return void 0x0===_0x43169e&&(_0x43169e=!0x1),this['_updatePointAtData'](_0x29c788,_0x43169e),_0x43169e?_0x30ed6e['e']['TransformCoordinates'](_0x30ed6e['e']['Right'](),this['_pointAtData']['interpolationMatrix']):this['_normals'][this['_pointAtData']['previousPointArrayIndex']];},_0x37c447['prototype']['getBinormalAt']=function(_0x443a56,_0x4b6cf3){return void 0x0===_0x4b6cf3&&(_0x4b6cf3=!0x1),this['_updatePointAtData'](_0x443a56,_0x4b6cf3),_0x4b6cf3?_0x30ed6e['e']['TransformCoordinates'](_0x30ed6e['e']['UpReadOnly'],this['_pointAtData']['interpolationMatrix']):this['_binormals'][this['_pointAtData']['previousPointArrayIndex']];},_0x37c447['prototype']['getDistanceAt']=function(_0x134e28){return this['length']()*_0x134e28;},_0x37c447['prototype']['getPreviousPointIndexAt']=function(_0x619024){return this['_updatePointAtData'](_0x619024),this['_pointAtData']['previousPointArrayIndex'];},_0x37c447['prototype']['getSubPositionAt']=function(_0x110f7b){return this['_updatePointAtData'](_0x110f7b),this['_pointAtData']['subPosition'];},_0x37c447['prototype']['getClosestPositionTo']=function(_0x12156f){for(var _0x1f89cc=Number['MAX_VALUE'],_0x3473c7=0x0,_0x512af2=0x0;_0x512af2_0x3cd154){var _0x1e5e6a=_0x2523a1;_0x2523a1=_0x3cd154,_0x3cd154=_0x1e5e6a;}var _0x25b14a=this['getCurve'](),_0x53535b=this['getPointAt'](_0x2523a1),_0xfa1de4=this['getPreviousPointIndexAt'](_0x2523a1),_0x223348=this['getPointAt'](_0x3cd154),_0x278a5c=this['getPreviousPointIndexAt'](_0x3cd154)+0x1,_0x31c571=[];return 0x0!==_0x2523a1&&(_0xfa1de4++,_0x31c571['push'](_0x53535b)),_0x31c571['push']['apply'](_0x31c571,_0x25b14a['slice'](_0xfa1de4,_0x278a5c)),0x1===_0x3cd154&&0x1!==_0x2523a1||_0x31c571['push'](_0x223348),new _0x37c447(_0x31c571,this['getNormalAt'](_0x2523a1),this['_raw'],this['_alignTangentsWithPath']);},_0x37c447['prototype']['update']=function(_0x44f9dc,_0x2231e4,_0x3b5062){void 0x0===_0x2231e4&&(_0x2231e4=null),void 0x0===_0x3b5062&&(_0x3b5062=!0x1);for(var _0x5102a6=0x0;_0x5102a6<_0x44f9dc['length'];_0x5102a6++)this['_curve'][_0x5102a6]['x']=_0x44f9dc[_0x5102a6]['x'],this['_curve'][_0x5102a6]['y']=_0x44f9dc[_0x5102a6]['y'],this['_curve'][_0x5102a6]['z']=_0x44f9dc[_0x5102a6]['z'];return this['_compute'](_0x2231e4,_0x3b5062),this;},_0x37c447['prototype']['_compute']=function(_0x22412f,_0x5e7184){void 0x0===_0x5e7184&&(_0x5e7184=!0x1);var _0x1b5c33=this['_curve']['length'];if(!(_0x1b5c33<0x2)){this['_tangents'][0x0]=this['_getFirstNonNullVector'](0x0),this['_raw']||this['_tangents'][0x0]['normalize'](),this['_tangents'][_0x1b5c33-0x1]=this['_curve'][_0x1b5c33-0x1]['subtract'](this['_curve'][_0x1b5c33-0x2]),this['_raw']||this['_tangents'][_0x1b5c33-0x1]['normalize']();var _0x560926,_0x3247c6,_0x150f42,_0x29d487,_0x35ca7b,_0x47827d=this['_tangents'][0x0],_0x1a4b19=this['_normalVector'](_0x47827d,_0x22412f);this['_normals'][0x0]=_0x1a4b19,this['_raw']||this['_normals'][0x0]['normalize'](),this['_binormals'][0x0]=_0x30ed6e['e']['Cross'](_0x47827d,this['_normals'][0x0]),this['_raw']||this['_binormals'][0x0]['normalize'](),this['_distances'][0x0]=0x0;for(var _0x1f6c86=0x1;_0x1f6c86<_0x1b5c33;_0x1f6c86++)_0x560926=this['_getLastNonNullVector'](_0x1f6c86),_0x1f6c86<_0x1b5c33-0x1&&(_0x3247c6=this['_getFirstNonNullVector'](_0x1f6c86),this['_tangents'][_0x1f6c86]=_0x5e7184?_0x3247c6:_0x560926['add'](_0x3247c6),this['_tangents'][_0x1f6c86]['normalize']()),this['_distances'][_0x1f6c86]=this['_distances'][_0x1f6c86-0x1]+this['_curve'][_0x1f6c86]['subtract'](this['_curve'][_0x1f6c86-0x1])['length'](),_0x150f42=this['_tangents'][_0x1f6c86],_0x35ca7b=this['_binormals'][_0x1f6c86-0x1],this['_normals'][_0x1f6c86]=_0x30ed6e['e']['Cross'](_0x35ca7b,_0x150f42),this['_raw']||(0x0===this['_normals'][_0x1f6c86]['length']()?(_0x29d487=this['_normals'][_0x1f6c86-0x1],this['_normals'][_0x1f6c86]=_0x29d487['clone']()):this['_normals'][_0x1f6c86]['normalize']()),this['_binormals'][_0x1f6c86]=_0x30ed6e['e']['Cross'](_0x150f42,this['_normals'][_0x1f6c86]),this['_raw']||this['_binormals'][_0x1f6c86]['normalize']();this['_pointAtData']['id']=NaN;}},_0x37c447['prototype']['_getFirstNonNullVector']=function(_0x88eb52){for(var _0x56d8f5=0x1,_0x5a5aac=this['_curve'][_0x88eb52+_0x56d8f5]['subtract'](this['_curve'][_0x88eb52]);0x0===_0x5a5aac['length']()&&_0x88eb52+_0x56d8f5+0x1_0x2af4c9+0x1;)_0x2af4c9++,_0x2e3950=this['_curve'][_0xc2950e]['subtract'](this['_curve'][_0xc2950e-_0x2af4c9]);return _0x2e3950;},_0x37c447['prototype']['_normalVector']=function(_0x33fb7c,_0x562e4e){var _0x196643,_0x4478bf,_0x721aa8=_0x33fb7c['length']();return(0x0===_0x721aa8&&(_0x721aa8=0x1),null==_0x562e4e)?(_0x4478bf=_0x57e2bd['a']['WithinEpsilon'](Math['abs'](_0x33fb7c['y'])/_0x721aa8,0x1,_0x5a30c1['a'])?_0x57e2bd['a']['WithinEpsilon'](Math['abs'](_0x33fb7c['x'])/_0x721aa8,0x1,_0x5a30c1['a'])?_0x57e2bd['a']['WithinEpsilon'](Math['abs'](_0x33fb7c['z'])/_0x721aa8,0x1,_0x5a30c1['a'])?_0x30ed6e['e']['Zero']():new _0x30ed6e['e'](0x0,0x0,0x1):new _0x30ed6e['e'](0x1,0x0,0x0):new _0x30ed6e['e'](0x0,-0x1,0x0),_0x196643=_0x30ed6e['e']['Cross'](_0x33fb7c,_0x4478bf)):(_0x196643=_0x30ed6e['e']['Cross'](_0x33fb7c,_0x562e4e),_0x30ed6e['e']['CrossToRef'](_0x196643,_0x33fb7c,_0x196643)),(_0x196643['normalize'](),_0x196643);},_0x37c447['prototype']['_updatePointAtData']=function(_0x53719b,_0x1d8d64){if(void 0x0===_0x1d8d64&&(_0x1d8d64=!0x1),this['_pointAtData']['id']===_0x53719b)return this['_pointAtData']['interpolateReady']||this['_updateInterpolationMatrix'](),this['_pointAtData'];this['_pointAtData']['id']=_0x53719b;var _0x5c8ea5=this['getPoints']();if(_0x53719b<=0x0)return this['_setPointAtData'](0x0,0x0,_0x5c8ea5[0x0],0x0,_0x1d8d64);if(_0x53719b>=0x1)return this['_setPointAtData'](0x1,0x1,_0x5c8ea5[_0x5c8ea5['length']-0x1],_0x5c8ea5['length']-0x1,_0x1d8d64);for(var _0x475d5a,_0x503b8e=_0x5c8ea5[0x0],_0x4ee743=0x0,_0x10901b=_0x53719b*this['length'](),_0x58ce6a=0x1;_0x58ce6a<_0x5c8ea5['length'];_0x58ce6a++){_0x475d5a=_0x5c8ea5[_0x58ce6a];var _0x5d6ab3=_0x30ed6e['e']['Distance'](_0x503b8e,_0x475d5a);if((_0x4ee743+=_0x5d6ab3)===_0x10901b)return this['_setPointAtData'](_0x53719b,0x1,_0x475d5a,_0x58ce6a,_0x1d8d64);if(_0x4ee743>_0x10901b){var _0x4e649b=(_0x4ee743-_0x10901b)/_0x5d6ab3,_0x2119a5=_0x503b8e['subtract'](_0x475d5a),_0x427244=_0x475d5a['add'](_0x2119a5['scaleInPlace'](_0x4e649b));return this['_setPointAtData'](_0x53719b,0x1-_0x4e649b,_0x427244,_0x58ce6a-0x1,_0x1d8d64);}_0x503b8e=_0x475d5a;}return this['_pointAtData'];},_0x37c447['prototype']['_setPointAtData']=function(_0x5b34f7,_0xfbba14,_0x4de6b6,_0x41ec2f,_0x4fc895){return this['_pointAtData']['point']=_0x4de6b6,this['_pointAtData']['position']=_0x5b34f7,this['_pointAtData']['subPosition']=_0xfbba14,this['_pointAtData']['previousPointArrayIndex']=_0x41ec2f,this['_pointAtData']['interpolateReady']=_0x4fc895,_0x4fc895&&this['_updateInterpolationMatrix'](),this['_pointAtData'];},_0x37c447['prototype']['_updateInterpolationMatrix']=function(){this['_pointAtData']['interpolationMatrix']=_0x30ed6e['a']['Identity']();var _0x3b177c=this['_pointAtData']['previousPointArrayIndex'];if(_0x3b177c!==this['_tangents']['length']-0x1){var _0x4be5d8=_0x3b177c+0x1,_0x3eded9=this['_tangents'][_0x3b177c]['clone'](),_0x15ef29=this['_normals'][_0x3b177c]['clone'](),_0x1aec28=this['_binormals'][_0x3b177c]['clone'](),_0x13c40a=this['_tangents'][_0x4be5d8]['clone'](),_0x4e42a5=this['_normals'][_0x4be5d8]['clone'](),_0x549856=this['_binormals'][_0x4be5d8]['clone'](),_0x159517=_0x30ed6e['b']['RotationQuaternionFromAxis'](_0x15ef29,_0x1aec28,_0x3eded9),_0x25d639=_0x30ed6e['b']['RotationQuaternionFromAxis'](_0x4e42a5,_0x549856,_0x13c40a);_0x30ed6e['b']['Slerp'](_0x159517,_0x25d639,this['_pointAtData']['subPosition'])['toRotationMatrix'](this['_pointAtData']['interpolationMatrix']);}},_0x37c447;}()),_0x36d807=(function(){function _0x99b18d(_0x55e18c){this['_length']=0x0,this['_points']=_0x55e18c,this['_length']=this['_computeLength'](_0x55e18c);}return _0x99b18d['CreateQuadraticBezier']=function(_0xb09e10,_0x1b44b5,_0x5b7013,_0x5d029f){_0x5d029f=_0x5d029f>0x2?_0x5d029f:0x3;for(var _0x1fae4a=new Array(),_0xf9a217=function(_0x575952,_0x23adc5,_0x1da10c,_0x3dbd01){return(0x1-_0x575952)*(0x1-_0x575952)*_0x23adc5+0x2*_0x575952*(0x1-_0x575952)*_0x1da10c+_0x575952*_0x575952*_0x3dbd01;},_0x1d76c7=0x0;_0x1d76c7<=_0x5d029f;_0x1d76c7++)_0x1fae4a['push'](new _0x30ed6e['e'](_0xf9a217(_0x1d76c7/_0x5d029f,_0xb09e10['x'],_0x1b44b5['x'],_0x5b7013['x']),_0xf9a217(_0x1d76c7/_0x5d029f,_0xb09e10['y'],_0x1b44b5['y'],_0x5b7013['y']),_0xf9a217(_0x1d76c7/_0x5d029f,_0xb09e10['z'],_0x1b44b5['z'],_0x5b7013['z'])));return new _0x99b18d(_0x1fae4a);},_0x99b18d['CreateCubicBezier']=function(_0xad54b3,_0x6cb59a,_0x23a82c,_0x5c9159,_0x4e5d52){_0x4e5d52=_0x4e5d52>0x3?_0x4e5d52:0x4;for(var _0x1f4199=new Array(),_0xbe9aaf=function(_0xee34f5,_0x1ef0c2,_0x4bee5a,_0x52f645,_0x17059c){return(0x1-_0xee34f5)*(0x1-_0xee34f5)*(0x1-_0xee34f5)*_0x1ef0c2+0x3*_0xee34f5*(0x1-_0xee34f5)*(0x1-_0xee34f5)*_0x4bee5a+0x3*_0xee34f5*_0xee34f5*(0x1-_0xee34f5)*_0x52f645+_0xee34f5*_0xee34f5*_0xee34f5*_0x17059c;},_0x1b2af1=0x0;_0x1b2af1<=_0x4e5d52;_0x1b2af1++)_0x1f4199['push'](new _0x30ed6e['e'](_0xbe9aaf(_0x1b2af1/_0x4e5d52,_0xad54b3['x'],_0x6cb59a['x'],_0x23a82c['x'],_0x5c9159['x']),_0xbe9aaf(_0x1b2af1/_0x4e5d52,_0xad54b3['y'],_0x6cb59a['y'],_0x23a82c['y'],_0x5c9159['y']),_0xbe9aaf(_0x1b2af1/_0x4e5d52,_0xad54b3['z'],_0x6cb59a['z'],_0x23a82c['z'],_0x5c9159['z'])));return new _0x99b18d(_0x1f4199);},_0x99b18d['CreateHermiteSpline']=function(_0x3f5dfc,_0x3d39ff,_0x45a43f,_0x1e186b,_0x14bf2f){for(var _0x37a2ce=new Array(),_0x4b7903=0x1/_0x14bf2f,_0x4a5d20=0x0;_0x4a5d20<=_0x14bf2f;_0x4a5d20++)_0x37a2ce['push'](_0x30ed6e['e']['Hermite'](_0x3f5dfc,_0x3d39ff,_0x45a43f,_0x1e186b,_0x4a5d20*_0x4b7903));return new _0x99b18d(_0x37a2ce);},_0x99b18d['CreateCatmullRomSpline']=function(_0x426ef5,_0x1bcc45,_0x1a9093){var _0x2b3457=new Array(),_0x571c55=0x1/_0x1bcc45,_0x20ba3d=0x0;if(_0x1a9093){for(var _0x2f6185=_0x426ef5['length'],_0x477d23=0x0;_0x477d23<_0x2f6185;_0x477d23++){_0x20ba3d=0x0;for(var _0x25e9af=0x0;_0x25e9af<_0x1bcc45;_0x25e9af++)_0x2b3457['push'](_0x30ed6e['e']['CatmullRom'](_0x426ef5[_0x477d23%_0x2f6185],_0x426ef5[(_0x477d23+0x1)%_0x2f6185],_0x426ef5[(_0x477d23+0x2)%_0x2f6185],_0x426ef5[(_0x477d23+0x3)%_0x2f6185],_0x20ba3d)),_0x20ba3d+=_0x571c55;}_0x2b3457['push'](_0x2b3457[0x0]);}else{var _0x7f84b=new Array();_0x7f84b['push'](_0x426ef5[0x0]['clone']()),Array['prototype']['push']['apply'](_0x7f84b,_0x426ef5),_0x7f84b['push'](_0x426ef5[_0x426ef5['length']-0x1]['clone']());for(_0x477d23=0x0;_0x477d23<_0x7f84b['length']-0x3;_0x477d23++){_0x20ba3d=0x0;for(_0x25e9af=0x0;_0x25e9af<_0x1bcc45;_0x25e9af++)_0x2b3457['push'](_0x30ed6e['e']['CatmullRom'](_0x7f84b[_0x477d23],_0x7f84b[_0x477d23+0x1],_0x7f84b[_0x477d23+0x2],_0x7f84b[_0x477d23+0x3],_0x20ba3d)),_0x20ba3d+=_0x571c55;}_0x477d23--,_0x2b3457['push'](_0x30ed6e['e']['CatmullRom'](_0x7f84b[_0x477d23],_0x7f84b[_0x477d23+0x1],_0x7f84b[_0x477d23+0x2],_0x7f84b[_0x477d23+0x3],_0x20ba3d));}return new _0x99b18d(_0x2b3457);},_0x99b18d['prototype']['getPoints']=function(){return this['_points'];},_0x99b18d['prototype']['length']=function(){return this['_length'];},_0x99b18d['prototype']['continue']=function(_0x454f92){for(var _0x16a669=this['_points'][this['_points']['length']-0x1],_0x18d78a=this['_points']['slice'](),_0x35b85d=_0x454f92['getPoints'](),_0x24f5b9=0x1;_0x24f5b9<_0x35b85d['length'];_0x24f5b9++)_0x18d78a['push'](_0x35b85d[_0x24f5b9]['subtract'](_0x35b85d[0x0])['add'](_0x16a669));return new _0x99b18d(_0x18d78a);},_0x99b18d['prototype']['_computeLength']=function(_0x2cdb53){for(var _0x4ee688=0x0,_0x5e6fb1=0x1;_0x5e6fb1<_0x2cdb53['length'];_0x5e6fb1++)_0x4ee688+=_0x2cdb53[_0x5e6fb1]['subtract'](_0x2cdb53[_0x5e6fb1-0x1])['length']();return _0x4ee688;},_0x99b18d;}());},function(_0x31ee0f,_0x4c6428,_0x243b63){'use strict';_0x243b63['d'](_0x4c6428,'a',function(){return _0x45baef;});var _0x35e7a5=_0x243b63(0x1),_0x54629c=_0x243b63(0x3),_0x38d2ee=_0x243b63(0x0),_0x26478b=_0x243b63(0x4),_0x410eba=_0x243b63(0xa),_0x6037bd=_0x243b63(0xf),_0x40b31b=_0x243b63(0x19),_0xc34d13=_0x243b63(0xb),_0x14eaa1=_0x243b63(0x9),_0x57ef81=_0x243b63(0x43),_0x1c3ef9=_0x243b63(0x31),_0x38ea91=_0x243b63(0xd),_0x482ba1={'effect':null,'subMesh':null},_0x45baef=function(_0x43b836){function _0x2614c2(_0x36eff6,_0x2a041b,_0x200848,_0x13cb55){void 0x0===_0x13cb55&&(_0x13cb55={});var _0x1a983b=_0x43b836['call'](this,_0x36eff6,_0x2a041b)||this;return _0x1a983b['_textures']={},_0x1a983b['_textureArrays']={},_0x1a983b['_floats']={},_0x1a983b['_ints']={},_0x1a983b['_floatsArrays']={},_0x1a983b['_colors3']={},_0x1a983b['_colors3Arrays']={},_0x1a983b['_colors4']={},_0x1a983b['_colors4Arrays']={},_0x1a983b['_vectors2']={},_0x1a983b['_vectors3']={},_0x1a983b['_vectors4']={},_0x1a983b['_matrices']={},_0x1a983b['_matrixArrays']={},_0x1a983b['_matrices3x3']={},_0x1a983b['_matrices2x2']={},_0x1a983b['_vectors2Arrays']={},_0x1a983b['_vectors3Arrays']={},_0x1a983b['_vectors4Arrays']={},_0x1a983b['_cachedWorldViewMatrix']=new _0x38d2ee['a'](),_0x1a983b['_cachedWorldViewProjectionMatrix']=new _0x38d2ee['a'](),_0x1a983b['_multiview']=!0x1,_0x1a983b['_shaderPath']=_0x200848,_0x1a983b['_options']=Object(_0x35e7a5['a'])({'needAlphaBlending':!0x1,'needAlphaTesting':!0x1,'attributes':['position','normal','uv'],'uniforms':['worldViewProjection'],'uniformBuffers':[],'samplers':[],'defines':[]},_0x13cb55),_0x1a983b;}return Object(_0x35e7a5['d'])(_0x2614c2,_0x43b836),Object['defineProperty'](_0x2614c2['prototype'],'shaderPath',{'get':function(){return this['_shaderPath'];},'set':function(_0x33f13b){this['_shaderPath']=_0x33f13b;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2614c2['prototype'],'options',{'get':function(){return this['_options'];},'enumerable':!0x1,'configurable':!0x0}),_0x2614c2['prototype']['getClassName']=function(){return'ShaderMaterial';},_0x2614c2['prototype']['needAlphaBlending']=function(){return this['alpha']<0x1||this['_options']['needAlphaBlending'];},_0x2614c2['prototype']['needAlphaTesting']=function(){return this['_options']['needAlphaTesting'];},_0x2614c2['prototype']['_checkUniform']=function(_0x10ab73){-0x1===this['_options']['uniforms']['indexOf'](_0x10ab73)&&this['_options']['uniforms']['push'](_0x10ab73);},_0x2614c2['prototype']['setTexture']=function(_0x347a27,_0x502088){return-0x1===this['_options']['samplers']['indexOf'](_0x347a27)&&this['_options']['samplers']['push'](_0x347a27),this['_textures'][_0x347a27]=_0x502088,this;},_0x2614c2['prototype']['setTextureArray']=function(_0x21d4d0,_0xbde2d){return-0x1===this['_options']['samplers']['indexOf'](_0x21d4d0)&&this['_options']['samplers']['push'](_0x21d4d0),this['_checkUniform'](_0x21d4d0),this['_textureArrays'][_0x21d4d0]=_0xbde2d,this;},_0x2614c2['prototype']['setFloat']=function(_0x36bbf1,_0x2adbe1){return this['_checkUniform'](_0x36bbf1),this['_floats'][_0x36bbf1]=_0x2adbe1,this;},_0x2614c2['prototype']['setInt']=function(_0x53965d,_0x29d898){return this['_checkUniform'](_0x53965d),this['_ints'][_0x53965d]=_0x29d898,this;},_0x2614c2['prototype']['setFloats']=function(_0x5ad017,_0x2e17d2){return this['_checkUniform'](_0x5ad017),this['_floatsArrays'][_0x5ad017]=_0x2e17d2,this;},_0x2614c2['prototype']['setColor3']=function(_0x437568,_0x2321e5){return this['_checkUniform'](_0x437568),this['_colors3'][_0x437568]=_0x2321e5,this;},_0x2614c2['prototype']['setColor3Array']=function(_0x37cb1f,_0x38176c){return this['_checkUniform'](_0x37cb1f),this['_colors3Arrays'][_0x37cb1f]=_0x38176c['reduce'](function(_0x38121b,_0x3d4fe2){return _0x3d4fe2['toArray'](_0x38121b,_0x38121b['length']),_0x38121b;},[]),this;},_0x2614c2['prototype']['setColor4']=function(_0x12dd5e,_0x34190e){return this['_checkUniform'](_0x12dd5e),this['_colors4'][_0x12dd5e]=_0x34190e,this;},_0x2614c2['prototype']['setColor4Array']=function(_0x3f0b01,_0x566a95){return this['_checkUniform'](_0x3f0b01),this['_colors4Arrays'][_0x3f0b01]=_0x566a95['reduce'](function(_0x58279a,_0x51e5ca){return _0x51e5ca['toArray'](_0x58279a,_0x58279a['length']),_0x58279a;},[]),this;},_0x2614c2['prototype']['setVector2']=function(_0x35b4a6,_0x34fd31){return this['_checkUniform'](_0x35b4a6),this['_vectors2'][_0x35b4a6]=_0x34fd31,this;},_0x2614c2['prototype']['setVector3']=function(_0x32199c,_0x450413){return this['_checkUniform'](_0x32199c),this['_vectors3'][_0x32199c]=_0x450413,this;},_0x2614c2['prototype']['setVector4']=function(_0xdcd25f,_0x3e10ec){return this['_checkUniform'](_0xdcd25f),this['_vectors4'][_0xdcd25f]=_0x3e10ec,this;},_0x2614c2['prototype']['setMatrix']=function(_0x2f60fb,_0x1d03c5){return this['_checkUniform'](_0x2f60fb),this['_matrices'][_0x2f60fb]=_0x1d03c5,this;},_0x2614c2['prototype']['setMatrices']=function(_0x5f416f,_0x5c679d){this['_checkUniform'](_0x5f416f);for(var _0xb27e91=new Float32Array(0x10*_0x5c679d['length']),_0x3aa538=0x0;_0x3aa538<_0x5c679d['length'];_0x3aa538++){_0x5c679d[_0x3aa538]['copyToArray'](_0xb27e91,0x10*_0x3aa538);}return this['_matrixArrays'][_0x5f416f]=_0xb27e91,this;},_0x2614c2['prototype']['setMatrix3x3']=function(_0x3cd9de,_0x5701e9){return this['_checkUniform'](_0x3cd9de),this['_matrices3x3'][_0x3cd9de]=_0x5701e9,this;},_0x2614c2['prototype']['setMatrix2x2']=function(_0x37413d,_0x557de9){return this['_checkUniform'](_0x37413d),this['_matrices2x2'][_0x37413d]=_0x557de9,this;},_0x2614c2['prototype']['setArray2']=function(_0x2afcfa,_0x20bda5){return this['_checkUniform'](_0x2afcfa),this['_vectors2Arrays'][_0x2afcfa]=_0x20bda5,this;},_0x2614c2['prototype']['setArray3']=function(_0x2c6709,_0x1d2ed1){return this['_checkUniform'](_0x2c6709),this['_vectors3Arrays'][_0x2c6709]=_0x1d2ed1,this;},_0x2614c2['prototype']['setArray4']=function(_0x300593,_0x25d3c6){return this['_checkUniform'](_0x300593),this['_vectors4Arrays'][_0x300593]=_0x25d3c6,this;},_0x2614c2['prototype']['_checkCache']=function(_0xefc22e,_0x244da0){return!_0xefc22e||(!this['_effect']||-0x1!==this['_effect']['defines']['indexOf']('#define\x20INSTANCES')===_0x244da0);},_0x2614c2['prototype']['isReadyForSubMesh']=function(_0xa556d6,_0x2ddc08,_0x35c4f4){return this['isReady'](_0xa556d6,_0x35c4f4);},_0x2614c2['prototype']['isReady']=function(_0x482afa,_0x10e71e){var _0x5a9f93,_0x3275c3;if(this['_effect']&&this['isFrozen']&&this['_effect']['_wasPreviouslyReady'])return!0x0;var _0x1bf923=this['getScene'](),_0x19214b=_0x1bf923['getEngine']();if(!this['checkReadyOnEveryCall']&&this['_renderId']===_0x1bf923['getRenderId']()&&this['_checkCache'](_0x482afa,_0x10e71e))return!0x0;var _0x1f4c09=[],_0x12b04d=[],_0x4e0747=new _0x57ef81['a']();_0x19214b['getCaps']()['multiview']&&_0x1bf923['activeCamera']&&_0x1bf923['activeCamera']['outputRenderTarget']&&_0x1bf923['activeCamera']['outputRenderTarget']['getViewCount']()>0x1&&(this['_multiview']=!0x0,_0x1f4c09['push']('#define\x20MULTIVIEW'),-0x1!==this['_options']['uniforms']['indexOf']('viewProjection')&&-0x1===this['_options']['uniforms']['push']('viewProjectionR')&&this['_options']['uniforms']['push']('viewProjectionR'));for(var _0xb9a161=0x0;_0xb9a1610x4&&(_0x12b04d['push'](_0x26478b['b']['MatricesIndicesExtraKind']),_0x12b04d['push'](_0x26478b['b']['MatricesWeightsExtraKind']));var _0x2141a5=_0x482afa['skeleton'];_0x3706a2=_0x482afa['numBoneInfluencers'],_0x1f4c09['push']('#define\x20NUM_BONE_INFLUENCERS\x20'+_0x3706a2),_0x4e0747['addCPUSkinningFallback'](0x0,_0x482afa),_0x2141a5['isUsingTextureForMatrices']?(_0x1f4c09['push']('#define\x20BONETEXTURE'),-0x1===this['_options']['uniforms']['indexOf']('boneTextureWidth')&&this['_options']['uniforms']['push']('boneTextureWidth'),-0x1===this['_options']['samplers']['indexOf']('boneSampler')&&this['_options']['samplers']['push']('boneSampler')):(_0x1f4c09['push']('#define\x20BonesPerMesh\x20'+(_0x2141a5['bones']['length']+0x1)),-0x1===this['_options']['uniforms']['indexOf']('mBones')&&this['_options']['uniforms']['push']('mBones'));}else _0x1f4c09['push']('#define\x20NUM_BONE_INFLUENCERS\x200');for(var _0x45f6b3 in this['_textures'])if(!this['_textures'][_0x45f6b3]['isReady']())return!0x1;_0x482afa&&this['_shouldTurnAlphaTestOn'](_0x482afa)&&_0x1f4c09['push']('#define\x20ALPHATEST');var _0x334b2b=this['_shaderPath'],_0x249def=this['_options']['uniforms'],_0x1a6850=this['_options']['uniformBuffers'],_0x1b43ce=this['_options']['samplers'];this['customShaderNameResolve']&&(_0x249def=_0x249def['slice'](),_0x1a6850=_0x1a6850['slice'](),_0x1b43ce=_0x1b43ce['slice'](),_0x334b2b=this['customShaderNameResolve'](_0x334b2b,_0x249def,_0x1a6850,_0x1b43ce,_0x1f4c09,_0x12b04d));var _0x196801=this['_effect'],_0x2362ec=_0x1f4c09['join']('\x0a');return this['_cachedDefines']!==_0x2362ec&&(this['_cachedDefines']=_0x2362ec,this['_effect']=_0x19214b['createEffect'](_0x334b2b,{'attributes':_0x12b04d,'uniformsNames':_0x249def,'uniformBuffersNames':_0x1a6850,'samplers':_0x1b43ce,'defines':_0x2362ec,'fallbacks':_0x4e0747,'onCompiled':this['onCompiled'],'onError':this['onError'],'indexParameters':{'maxSimultaneousMorphTargets':_0x3706a2}},_0x19214b),this['_onEffectCreatedObservable']&&(_0x482ba1['effect']=this['_effect'],this['_onEffectCreatedObservable']['notifyObservers'](_0x482ba1))),null!==(_0x3275c3=!(null===(_0x5a9f93=this['_effect'])||void 0x0===_0x5a9f93?void 0x0:_0x5a9f93['isReady']()))&&void 0x0!==_0x3275c3&&!_0x3275c3&&(_0x196801!==this['_effect']&&_0x1bf923['resetCachedMaterial'](),this['_renderId']=_0x1bf923['getRenderId'](),this['_effect']['_wasPreviouslyReady']=!0x0,!0x0);},_0x2614c2['prototype']['bindOnlyWorldMatrix']=function(_0x48ccaa,_0x1be56b){var _0x363883=this['getScene'](),_0x44ed46=null!=_0x1be56b?_0x1be56b:this['_effect'];_0x44ed46&&(-0x1!==this['_options']['uniforms']['indexOf']('world')&&_0x44ed46['setMatrix']('world',_0x48ccaa),-0x1!==this['_options']['uniforms']['indexOf']('worldView')&&(_0x48ccaa['multiplyToRef'](_0x363883['getViewMatrix'](),this['_cachedWorldViewMatrix']),_0x44ed46['setMatrix']('worldView',this['_cachedWorldViewMatrix'])),-0x1!==this['_options']['uniforms']['indexOf']('worldViewProjection')&&(_0x48ccaa['multiplyToRef'](_0x363883['getTransformMatrix'](),this['_cachedWorldViewProjectionMatrix']),_0x44ed46['setMatrix']('worldViewProjection',this['_cachedWorldViewProjectionMatrix'])));},_0x2614c2['prototype']['bindForSubMesh']=function(_0x482bfd,_0xc1d0ec,_0x2af21b){this['bind'](_0x482bfd,_0xc1d0ec,_0x2af21b['_effectOverride']);},_0x2614c2['prototype']['bind']=function(_0x3dec3c,_0xe2a56a,_0x5b6a0f){this['bindOnlyWorldMatrix'](_0x3dec3c,_0x5b6a0f);var _0x54414e=null!=_0x5b6a0f?_0x5b6a0f:this['_effect'];if(_0x54414e&&this['getScene']()['getCachedMaterial']()!==this){var _0x14e3fc;for(_0x14e3fc in(-0x1!==this['_options']['uniforms']['indexOf']('view')&&_0x54414e['setMatrix']('view',this['getScene']()['getViewMatrix']()),-0x1!==this['_options']['uniforms']['indexOf']('projection')&&_0x54414e['setMatrix']('projection',this['getScene']()['getProjectionMatrix']()),-0x1!==this['_options']['uniforms']['indexOf']('viewProjection')&&(_0x54414e['setMatrix']('viewProjection',this['getScene']()['getTransformMatrix']()),this['_multiview']&&_0x54414e['setMatrix']('viewProjectionR',this['getScene']()['_transformMatrixR'])),this['getScene']()['activeCamera']&&-0x1!==this['_options']['uniforms']['indexOf']('cameraPosition')&&_0x54414e['setVector3']('cameraPosition',this['getScene']()['activeCamera']['globalPosition']),_0x6037bd['a']['BindBonesParameters'](_0xe2a56a,_0x54414e),this['_textures']))_0x54414e['setTexture'](_0x14e3fc,this['_textures'][_0x14e3fc]);for(_0x14e3fc in this['_textureArrays'])_0x54414e['setTextureArray'](_0x14e3fc,this['_textureArrays'][_0x14e3fc]);for(_0x14e3fc in this['_ints'])_0x54414e['setInt'](_0x14e3fc,this['_ints'][_0x14e3fc]);for(_0x14e3fc in this['_floats'])_0x54414e['setFloat'](_0x14e3fc,this['_floats'][_0x14e3fc]);for(_0x14e3fc in this['_floatsArrays'])_0x54414e['setArray'](_0x14e3fc,this['_floatsArrays'][_0x14e3fc]);for(_0x14e3fc in this['_colors3'])_0x54414e['setColor3'](_0x14e3fc,this['_colors3'][_0x14e3fc]);for(_0x14e3fc in this['_colors3Arrays'])_0x54414e['setArray3'](_0x14e3fc,this['_colors3Arrays'][_0x14e3fc]);for(_0x14e3fc in this['_colors4']){var _0x4ad989=this['_colors4'][_0x14e3fc];_0x54414e['setFloat4'](_0x14e3fc,_0x4ad989['r'],_0x4ad989['g'],_0x4ad989['b'],_0x4ad989['a']);}for(_0x14e3fc in this['_colors4Arrays'])_0x54414e['setArray4'](_0x14e3fc,this['_colors4Arrays'][_0x14e3fc]);for(_0x14e3fc in this['_vectors2'])_0x54414e['setVector2'](_0x14e3fc,this['_vectors2'][_0x14e3fc]);for(_0x14e3fc in this['_vectors3'])_0x54414e['setVector3'](_0x14e3fc,this['_vectors3'][_0x14e3fc]);for(_0x14e3fc in this['_vectors4'])_0x54414e['setVector4'](_0x14e3fc,this['_vectors4'][_0x14e3fc]);for(_0x14e3fc in this['_matrices'])_0x54414e['setMatrix'](_0x14e3fc,this['_matrices'][_0x14e3fc]);for(_0x14e3fc in this['_matrixArrays'])_0x54414e['setMatrices'](_0x14e3fc,this['_matrixArrays'][_0x14e3fc]);for(_0x14e3fc in this['_matrices3x3'])_0x54414e['setMatrix3x3'](_0x14e3fc,this['_matrices3x3'][_0x14e3fc]);for(_0x14e3fc in this['_matrices2x2'])_0x54414e['setMatrix2x2'](_0x14e3fc,this['_matrices2x2'][_0x14e3fc]);for(_0x14e3fc in this['_vectors2Arrays'])_0x54414e['setArray2'](_0x14e3fc,this['_vectors2Arrays'][_0x14e3fc]);for(_0x14e3fc in this['_vectors3Arrays'])_0x54414e['setArray3'](_0x14e3fc,this['_vectors3Arrays'][_0x14e3fc]);for(_0x14e3fc in this['_vectors4Arrays'])_0x54414e['setArray4'](_0x14e3fc,this['_vectors4Arrays'][_0x14e3fc]);}var _0x2e6abb=this['_effect'];this['_effect']=_0x54414e,this['_afterBind'](_0xe2a56a),this['_effect']=_0x2e6abb;},_0x2614c2['prototype']['_afterBind']=function(_0x5d44d2){_0x43b836['prototype']['_afterBind']['call'](this,_0x5d44d2),this['getScene']()['_cachedEffect']=this['_effect'];},_0x2614c2['prototype']['getActiveTextures']=function(){var _0x21f81b=_0x43b836['prototype']['getActiveTextures']['call'](this);for(var _0x3f5699 in this['_textures'])_0x21f81b['push'](this['_textures'][_0x3f5699]);for(var _0x3f5699 in this['_textureArrays'])for(var _0x87acc6=this['_textureArrays'][_0x3f5699],_0x411397=0x0;_0x411397<_0x87acc6['length'];_0x411397++)_0x21f81b['push'](_0x87acc6[_0x411397]);return _0x21f81b;},_0x2614c2['prototype']['hasTexture']=function(_0x13b894){if(_0x43b836['prototype']['hasTexture']['call'](this,_0x13b894))return!0x0;for(var _0x40c073 in this['_textures'])if(this['_textures'][_0x40c073]===_0x13b894)return!0x0;for(var _0x40c073 in this['_textureArrays'])for(var _0x3eda72=this['_textureArrays'][_0x40c073],_0x297903=0x0;_0x297903<_0x3eda72['length'];_0x297903++)if(_0x3eda72[_0x297903]===_0x13b894)return!0x0;return!0x1;},_0x2614c2['prototype']['clone']=function(_0x168948){var _0x5ba9b7=this,_0x592af0=_0x54629c['a']['Clone'](function(){return new _0x2614c2(_0x168948,_0x5ba9b7['getScene'](),_0x5ba9b7['_shaderPath'],_0x5ba9b7['_options']);},this);for(var _0x76ead9 in(_0x592af0['name']=_0x168948,_0x592af0['id']=_0x168948,'object'==typeof _0x592af0['_shaderPath']&&(_0x592af0['_shaderPath']=Object(_0x35e7a5['a'])({},_0x592af0['_shaderPath'])),this['_options']=Object(_0x35e7a5['a'])({},this['_options']),Object['keys'](this['_options'])['forEach'](function(_0x4d2cdd){var _0x301213=_0x5ba9b7['_options'][_0x4d2cdd];Array['isArray'](_0x301213)&&(_0x5ba9b7['_options'][_0x4d2cdd]=_0x301213['slice'](0x0));}),this['_textures']))_0x592af0['setTexture'](_0x76ead9,this['_textures'][_0x76ead9]);for(var _0x76ead9 in this['_floats'])_0x592af0['setFloat'](_0x76ead9,this['_floats'][_0x76ead9]);for(var _0x76ead9 in this['_floatsArrays'])_0x592af0['setFloats'](_0x76ead9,this['_floatsArrays'][_0x76ead9]);for(var _0x76ead9 in this['_colors3'])_0x592af0['setColor3'](_0x76ead9,this['_colors3'][_0x76ead9]);for(var _0x76ead9 in this['_colors4'])_0x592af0['setColor4'](_0x76ead9,this['_colors4'][_0x76ead9]);for(var _0x76ead9 in this['_vectors2'])_0x592af0['setVector2'](_0x76ead9,this['_vectors2'][_0x76ead9]);for(var _0x76ead9 in this['_vectors3'])_0x592af0['setVector3'](_0x76ead9,this['_vectors3'][_0x76ead9]);for(var _0x76ead9 in this['_vectors4'])_0x592af0['setVector4'](_0x76ead9,this['_vectors4'][_0x76ead9]);for(var _0x76ead9 in this['_matrices'])_0x592af0['setMatrix'](_0x76ead9,this['_matrices'][_0x76ead9]);for(var _0x76ead9 in this['_matrices3x3'])_0x592af0['setMatrix3x3'](_0x76ead9,this['_matrices3x3'][_0x76ead9]);for(var _0x76ead9 in this['_matrices2x2'])_0x592af0['setMatrix2x2'](_0x76ead9,this['_matrices2x2'][_0x76ead9]);return _0x592af0;},_0x2614c2['prototype']['dispose']=function(_0x2f9210,_0x2ed91a,_0x138c7e){if(_0x2ed91a){var _0x1e1312;for(_0x1e1312 in this['_textures'])this['_textures'][_0x1e1312]['dispose']();for(_0x1e1312 in this['_textureArrays'])for(var _0x1c01f5=this['_textureArrays'][_0x1e1312],_0x20560b=0x0;_0x20560b<_0x1c01f5['length'];_0x20560b++)_0x1c01f5[_0x20560b]['dispose']();}this['_textures']={},_0x43b836['prototype']['dispose']['call'](this,_0x2f9210,_0x2ed91a,_0x138c7e);},_0x2614c2['prototype']['serialize']=function(){var _0x37c7d8,_0x351f61=_0x54629c['a']['Serialize'](this);for(_0x37c7d8 in(_0x351f61['customType']='BABYLON.ShaderMaterial',_0x351f61['options']=this['_options'],_0x351f61['shaderPath']=this['_shaderPath'],_0x351f61['textures']={},this['_textures']))_0x351f61['textures'][_0x37c7d8]=this['_textures'][_0x37c7d8]['serialize']();for(_0x37c7d8 in(_0x351f61['textureArrays']={},this['_textureArrays'])){_0x351f61['textureArrays'][_0x37c7d8]=[];for(var _0x3579ff=this['_textureArrays'][_0x37c7d8],_0x19da50=0x0;_0x19da50<_0x3579ff['length'];_0x19da50++)_0x351f61['textureArrays'][_0x37c7d8]['push'](_0x3579ff[_0x19da50]['serialize']());}for(_0x37c7d8 in(_0x351f61['floats']={},this['_floats']))_0x351f61['floats'][_0x37c7d8]=this['_floats'][_0x37c7d8];for(_0x37c7d8 in(_0x351f61['FloatArrays']={},this['_floatsArrays']))_0x351f61['FloatArrays'][_0x37c7d8]=this['_floatsArrays'][_0x37c7d8];for(_0x37c7d8 in(_0x351f61['colors3']={},this['_colors3']))_0x351f61['colors3'][_0x37c7d8]=this['_colors3'][_0x37c7d8]['asArray']();for(_0x37c7d8 in(_0x351f61['colors3Arrays']={},this['_colors3Arrays']))_0x351f61['colors3Arrays'][_0x37c7d8]=this['_colors3Arrays'][_0x37c7d8];for(_0x37c7d8 in(_0x351f61['colors4']={},this['_colors4']))_0x351f61['colors4'][_0x37c7d8]=this['_colors4'][_0x37c7d8]['asArray']();for(_0x37c7d8 in(_0x351f61['colors4Arrays']={},this['_colors4Arrays']))_0x351f61['colors4Arrays'][_0x37c7d8]=this['_colors4Arrays'][_0x37c7d8];for(_0x37c7d8 in(_0x351f61['vectors2']={},this['_vectors2']))_0x351f61['vectors2'][_0x37c7d8]=this['_vectors2'][_0x37c7d8]['asArray']();for(_0x37c7d8 in(_0x351f61['vectors3']={},this['_vectors3']))_0x351f61['vectors3'][_0x37c7d8]=this['_vectors3'][_0x37c7d8]['asArray']();for(_0x37c7d8 in(_0x351f61['vectors4']={},this['_vectors4']))_0x351f61['vectors4'][_0x37c7d8]=this['_vectors4'][_0x37c7d8]['asArray']();for(_0x37c7d8 in(_0x351f61['matrices']={},this['_matrices']))_0x351f61['matrices'][_0x37c7d8]=this['_matrices'][_0x37c7d8]['asArray']();for(_0x37c7d8 in(_0x351f61['matrixArray']={},this['_matrixArrays']))_0x351f61['matrixArray'][_0x37c7d8]=this['_matrixArrays'][_0x37c7d8];for(_0x37c7d8 in(_0x351f61['matrices3x3']={},this['_matrices3x3']))_0x351f61['matrices3x3'][_0x37c7d8]=this['_matrices3x3'][_0x37c7d8];for(_0x37c7d8 in(_0x351f61['matrices2x2']={},this['_matrices2x2']))_0x351f61['matrices2x2'][_0x37c7d8]=this['_matrices2x2'][_0x37c7d8];for(_0x37c7d8 in(_0x351f61['vectors2Arrays']={},this['_vectors2Arrays']))_0x351f61['vectors2Arrays'][_0x37c7d8]=this['_vectors2Arrays'][_0x37c7d8];for(_0x37c7d8 in(_0x351f61['vectors3Arrays']={},this['_vectors3Arrays']))_0x351f61['vectors3Arrays'][_0x37c7d8]=this['_vectors3Arrays'][_0x37c7d8];for(_0x37c7d8 in(_0x351f61['vectors4Arrays']={},this['_vectors4Arrays']))_0x351f61['vectors4Arrays'][_0x37c7d8]=this['_vectors4Arrays'][_0x37c7d8];return _0x351f61;},_0x2614c2['Parse']=function(_0x3b34f0,_0x591005,_0x36fc5a){var _0x26deda,_0xaed0db=_0x54629c['a']['Parse'](function(){return new _0x2614c2(_0x3b34f0['name'],_0x591005,_0x3b34f0['shaderPath'],_0x3b34f0['options']);},_0x3b34f0,_0x591005,_0x36fc5a);for(_0x26deda in _0x3b34f0['textures'])_0xaed0db['setTexture'](_0x26deda,_0x410eba['a']['Parse'](_0x3b34f0['textures'][_0x26deda],_0x591005,_0x36fc5a));for(_0x26deda in _0x3b34f0['textureArrays']){for(var _0x4a780b=_0x3b34f0['textureArrays'][_0x26deda],_0x5e0c96=new Array(),_0x2fe74f=0x0;_0x2fe74f<_0x4a780b['length'];_0x2fe74f++)_0x5e0c96['push'](_0x410eba['a']['Parse'](_0x4a780b[_0x2fe74f],_0x591005,_0x36fc5a));_0xaed0db['setTextureArray'](_0x26deda,_0x5e0c96);}for(_0x26deda in _0x3b34f0['floats'])_0xaed0db['setFloat'](_0x26deda,_0x3b34f0['floats'][_0x26deda]);for(_0x26deda in _0x3b34f0['floatsArrays'])_0xaed0db['setFloats'](_0x26deda,_0x3b34f0['floatsArrays'][_0x26deda]);for(_0x26deda in _0x3b34f0['colors3'])_0xaed0db['setColor3'](_0x26deda,_0x14eaa1['a']['FromArray'](_0x3b34f0['colors3'][_0x26deda]));for(_0x26deda in _0x3b34f0['colors3Arrays']){var _0xdad7a3=_0x3b34f0['colors3Arrays'][_0x26deda]['reduce'](function(_0x45e781,_0x3caf11,_0x216567){return _0x216567%0x3==0x0?_0x45e781['push']([_0x3caf11]):_0x45e781[_0x45e781['length']-0x1]['push'](_0x3caf11),_0x45e781;},[])['map'](function(_0x573517){return _0x14eaa1['a']['FromArray'](_0x573517);});_0xaed0db['setColor3Array'](_0x26deda,_0xdad7a3);}for(_0x26deda in _0x3b34f0['colors4'])_0xaed0db['setColor4'](_0x26deda,_0x14eaa1['b']['FromArray'](_0x3b34f0['colors4'][_0x26deda]));for(_0x26deda in _0x3b34f0['colors4Arrays']){_0xdad7a3=_0x3b34f0['colors4Arrays'][_0x26deda]['reduce'](function(_0x43ae4c,_0x38048c,_0x344c40){return _0x344c40%0x4==0x0?_0x43ae4c['push']([_0x38048c]):_0x43ae4c[_0x43ae4c['length']-0x1]['push'](_0x38048c),_0x43ae4c;},[])['map'](function(_0x4e1238){return _0x14eaa1['b']['FromArray'](_0x4e1238);}),_0xaed0db['setColor4Array'](_0x26deda,_0xdad7a3);}for(_0x26deda in _0x3b34f0['vectors2'])_0xaed0db['setVector2'](_0x26deda,_0x38d2ee['d']['FromArray'](_0x3b34f0['vectors2'][_0x26deda]));for(_0x26deda in _0x3b34f0['vectors3'])_0xaed0db['setVector3'](_0x26deda,_0x38d2ee['e']['FromArray'](_0x3b34f0['vectors3'][_0x26deda]));for(_0x26deda in _0x3b34f0['vectors4'])_0xaed0db['setVector4'](_0x26deda,_0x38d2ee['f']['FromArray'](_0x3b34f0['vectors4'][_0x26deda]));for(_0x26deda in _0x3b34f0['matrices'])_0xaed0db['setMatrix'](_0x26deda,_0x38d2ee['a']['FromArray'](_0x3b34f0['matrices'][_0x26deda]));for(_0x26deda in _0x3b34f0['matrixArray'])_0xaed0db['_matrixArrays'][_0x26deda]=new Float32Array(_0x3b34f0['matrixArray'][_0x26deda]);for(_0x26deda in _0x3b34f0['matrices3x3'])_0xaed0db['setMatrix3x3'](_0x26deda,_0x3b34f0['matrices3x3'][_0x26deda]);for(_0x26deda in _0x3b34f0['matrices2x2'])_0xaed0db['setMatrix2x2'](_0x26deda,_0x3b34f0['matrices2x2'][_0x26deda]);for(_0x26deda in _0x3b34f0['vectors2Arrays'])_0xaed0db['setArray2'](_0x26deda,_0x3b34f0['vectors2Arrays'][_0x26deda]);for(_0x26deda in _0x3b34f0['vectors3Arrays'])_0xaed0db['setArray3'](_0x26deda,_0x3b34f0['vectors3Arrays'][_0x26deda]);for(_0x26deda in _0x3b34f0['vectors4Arrays'])_0xaed0db['setArray4'](_0x26deda,_0x3b34f0['vectors4Arrays'][_0x26deda]);return _0xaed0db;},_0x2614c2['ParseFromFileAsync']=function(_0x2aa47f,_0x36aafc,_0x4fc6c3,_0x18e4b8){var _0x33d629=this;return void 0x0===_0x18e4b8&&(_0x18e4b8=''),new Promise(function(_0x51d6d2,_0x41bce9){var _0x535f99=new _0x1c3ef9['a']();_0x535f99['addEventListener']('readystatechange',function(){if(0x4==_0x535f99['readyState']){if(0xc8==_0x535f99['status']){var _0x591bec=JSON['parse'](_0x535f99['responseText']),_0x59aa33=_0x33d629['Parse'](_0x591bec,_0x4fc6c3||_0x38ea91['a']['LastCreatedScene'],_0x18e4b8);_0x2aa47f&&(_0x59aa33['name']=_0x2aa47f),_0x51d6d2(_0x59aa33);}else _0x41bce9('Unable\x20to\x20load\x20the\x20ShaderMaterial');}}),_0x535f99['open']('GET',_0x36aafc),_0x535f99['send']();});},_0x2614c2['CreateFromSnippetAsync']=function(_0x30a89a,_0x56911c,_0x43f51e){var _0x1a5b3f=this;return void 0x0===_0x43f51e&&(_0x43f51e=''),new Promise(function(_0x5bc9ae,_0x5398a9){var _0x436822=new _0x1c3ef9['a']();_0x436822['addEventListener']('readystatechange',function(){if(0x4==_0x436822['readyState']){if(0xc8==_0x436822['status']){var _0x3e4d8b=JSON['parse'](JSON['parse'](_0x436822['responseText'])['jsonPayload']),_0x40bbc0=JSON['parse'](_0x3e4d8b['shaderMaterial']),_0x2f9963=_0x1a5b3f['Parse'](_0x40bbc0,_0x56911c||_0x38ea91['a']['LastCreatedScene'],_0x43f51e);_0x2f9963['snippetId']=_0x30a89a,_0x5bc9ae(_0x2f9963);}else _0x5398a9('Unable\x20to\x20load\x20the\x20snippet\x20'+_0x30a89a);}}),_0x436822['open']('GET',_0x1a5b3f['SnippetUrl']+'/'+_0x30a89a['replace'](/#/g,'/')),_0x436822['send']();});},_0x2614c2['SnippetUrl']='https://snippet.babylonjs.com',_0x2614c2;}(_0x40b31b['a']);_0xc34d13['a']['RegisteredTypes']['BABYLON.ShaderMaterial']=_0x45baef;},function(_0x13dc7f,_0x271364,_0x24b22f){'use strict';_0x24b22f['d'](_0x271364,'a',function(){return _0x53a83a;});var _0x53a83a=(function(){function _0x30463b(){}return _0x30463b['SetMatrixPrecision']=function(_0x596292){if(_0x30463b['MatrixTrackPrecisionChange']=!0x1,_0x596292&&!_0x30463b['MatrixUse64Bits']&&_0x30463b['MatrixTrackedMatrices'])for(var _0x1bd739=0x0;_0x1bd739<_0x30463b['MatrixTrackedMatrices']['length'];++_0x1bd739){var _0x118fd3=_0x30463b['MatrixTrackedMatrices'][_0x1bd739],_0x463d49=_0x118fd3['_m'];_0x118fd3['_m']=new Array(0x10);for(var _0x46b425=0x0;_0x46b425<0x10;++_0x46b425)_0x118fd3['_m'][_0x46b425]=_0x463d49[_0x46b425];}_0x30463b['MatrixUse64Bits']=_0x596292,_0x30463b['MatrixCurrentType']=_0x30463b['MatrixUse64Bits']?Array:Float32Array,_0x30463b['MatrixTrackedMatrices']=null;},_0x30463b['MatrixUse64Bits']=!0x1,_0x30463b['MatrixTrackPrecisionChange']=!0x0,_0x30463b['MatrixCurrentType']=Float32Array,_0x30463b['MatrixTrackedMatrices']=[],_0x30463b;}());},function(_0x13bbcf,_0x11c351,_0x3759b4){'use strict';_0x3759b4['d'](_0x11c351,'a',function(){return _0x308b5e;});var _0x3adf82=_0x3759b4(0x1),_0x71ed0f=_0x3759b4(0x6),_0x338cbc=_0x3759b4(0x0),_0x3ebfdd=_0x3759b4(0x2e),_0x491e21=_0x3759b4(0x7),_0x533845=_0x3759b4(0x35),_0x2726f2=_0x3759b4(0x41),_0x693e7b=_0x3759b4(0x33),_0x3263e9=_0x3759b4(0x24),_0x4eb995=_0x3759b4(0x1e),_0x49937f=_0x3759b4(0x9),_0x308b5e=function(_0x4c927a){function _0x5f42da(_0x5add6b,_0x3ae9ac,_0x340cec,_0x365907,_0x2c1c54){var _0x20da52;void 0x0===_0x3ae9ac&&(_0x3ae9ac=_0x49937f['a']['Gray']()),void 0x0===_0x340cec&&(_0x340cec=_0x3263e9['a']['DefaultUtilityLayer']),void 0x0===_0x365907&&(_0x365907=null),void 0x0===_0x2c1c54&&(_0x2c1c54=0x1);var _0x353a7f=_0x4c927a['call'](this,_0x340cec)||this;_0x353a7f['_pointerObserver']=null,_0x353a7f['snapDistance']=0x0,_0x353a7f['onSnapObservable']=new _0x71ed0f['c'](),_0x353a7f['_isEnabled']=!0x0,_0x353a7f['_parent']=null,_0x353a7f['_dragging']=!0x1,_0x353a7f['_parent']=_0x365907,_0x353a7f['_coloredMaterial']=new _0x4eb995['a']('',_0x340cec['utilityLayerScene']),_0x353a7f['_coloredMaterial']['diffuseColor']=_0x3ae9ac,_0x353a7f['_coloredMaterial']['specularColor']=_0x3ae9ac['subtract'](new _0x49937f['a'](0.1,0.1,0.1)),_0x353a7f['_hoverMaterial']=new _0x4eb995['a']('',_0x340cec['utilityLayerScene']),_0x353a7f['_hoverMaterial']['diffuseColor']=_0x49937f['a']['Yellow'](),_0x353a7f['_disableMaterial']=new _0x4eb995['a']('',_0x340cec['utilityLayerScene']),_0x353a7f['_disableMaterial']['diffuseColor']=_0x49937f['a']['Gray'](),_0x353a7f['_disableMaterial']['alpha']=0.4;var _0x1171a9=_0x5f42da['_CreateArrow'](_0x340cec['utilityLayerScene'],_0x353a7f['_coloredMaterial'],_0x2c1c54),_0x24b082=_0x5f42da['_CreateArrow'](_0x340cec['utilityLayerScene'],_0x353a7f['_coloredMaterial'],_0x2c1c54+0x4,!0x0);_0x353a7f['_gizmoMesh']=new _0x491e21['a']('',_0x340cec['utilityLayerScene']),_0x353a7f['_gizmoMesh']['addChild'](_0x1171a9),_0x353a7f['_gizmoMesh']['addChild'](_0x24b082),_0x353a7f['_gizmoMesh']['lookAt'](_0x353a7f['_rootMesh']['position']['add'](_0x5add6b)),_0x353a7f['_gizmoMesh']['scaling']['scaleInPlace'](0x1/0x3),_0x353a7f['_gizmoMesh']['parent']=_0x353a7f['_rootMesh'];var _0x27a767=0x0,_0x23d45f=new _0x338cbc['e'](),_0x574907={'snapDistance':0x0};_0x353a7f['dragBehavior']=new _0x2726f2['a']({'dragAxis':_0x5add6b}),_0x353a7f['dragBehavior']['moveAttached']=!0x1,_0x353a7f['_rootMesh']['addBehavior'](_0x353a7f['dragBehavior']),_0x353a7f['dragBehavior']['onDragObservable']['add'](function(_0x5dba8b){if(_0x353a7f['attachedNode']){if(0x0==_0x353a7f['snapDistance'])_0x353a7f['attachedNode']['position']&&_0x353a7f['attachedNode']['position']['addInPlaceFromFloats'](_0x5dba8b['delta']['x'],_0x5dba8b['delta']['y'],_0x5dba8b['delta']['z']),_0x353a7f['attachedNode']['getWorldMatrix']()['addTranslationFromFloats'](_0x5dba8b['delta']['x'],_0x5dba8b['delta']['y'],_0x5dba8b['delta']['z']),_0x353a7f['attachedNode']['updateCache']();else{if(_0x27a767+=_0x5dba8b['dragDistance'],Math['abs'](_0x27a767)>_0x353a7f['snapDistance']){var _0x5f3dd3=Math['floor'](Math['abs'](_0x27a767)/_0x353a7f['snapDistance']);_0x27a767%=_0x353a7f['snapDistance'],_0x5dba8b['delta']['normalizeToRef'](_0x23d45f),_0x23d45f['scaleInPlace'](_0x353a7f['snapDistance']*_0x5f3dd3),_0x353a7f['attachedNode']['getWorldMatrix']()['addTranslationFromFloats'](_0x23d45f['x'],_0x23d45f['y'],_0x23d45f['z']),_0x353a7f['attachedNode']['updateCache'](),_0x574907['snapDistance']=_0x353a7f['snapDistance']*_0x5f3dd3,_0x353a7f['onSnapObservable']['notifyObservers'](_0x574907);}}_0x353a7f['_matrixChanged']();}}),_0x353a7f['dragBehavior']['onDragStartObservable']['add'](function(){_0x353a7f['_dragging']=!0x0;}),_0x353a7f['dragBehavior']['onDragEndObservable']['add'](function(){_0x353a7f['_dragging']=!0x1;});var _0x2b98d3=_0x340cec['_getSharedGizmoLight']();_0x2b98d3['includedOnlyMeshes']=_0x2b98d3['includedOnlyMeshes']['concat'](_0x353a7f['_rootMesh']['getChildMeshes'](!0x1));var _0x4b3f77={'gizmoMeshes':_0x1171a9['getChildMeshes'](),'colliderMeshes':_0x24b082['getChildMeshes'](),'material':_0x353a7f['_coloredMaterial'],'hoverMaterial':_0x353a7f['_hoverMaterial'],'disableMaterial':_0x353a7f['_disableMaterial'],'active':!0x1};return null===(_0x20da52=_0x353a7f['_parent'])||void 0x0===_0x20da52||_0x20da52['addToAxisCache'](_0x24b082,_0x4b3f77),_0x353a7f['_pointerObserver']=_0x340cec['utilityLayerScene']['onPointerObservable']['add'](function(_0x2d2c89){var _0x2bd475;if(!_0x353a7f['_customMeshSet']&&(_0x353a7f['_isHovered']=!(-0x1==_0x4b3f77['colliderMeshes']['indexOf'](null===(_0x2bd475=null==_0x2d2c89?void 0x0:_0x2d2c89['pickInfo'])||void 0x0===_0x2bd475?void 0x0:_0x2bd475['pickedMesh'])),!_0x353a7f['_parent'])){var _0x5dee37=_0x353a7f['_isHovered']||_0x353a7f['_dragging']?_0x353a7f['_hoverMaterial']:_0x353a7f['_coloredMaterial'];_0x4b3f77['gizmoMeshes']['forEach'](function(_0x49a145){_0x49a145['material']=_0x5dee37,_0x49a145['color']&&(_0x49a145['color']=_0x5dee37['diffuseColor']);});}}),_0x353a7f;}return Object(_0x3adf82['d'])(_0x5f42da,_0x4c927a),_0x5f42da['_CreateArrow']=function(_0x4dbcff,_0x3a69af,_0xa1c19,_0x5a0133){void 0x0===_0xa1c19&&(_0xa1c19=0x1),void 0x0===_0x5a0133&&(_0x5a0133=!0x1);var _0x39cd40=new _0x3ebfdd['a']('arrow',_0x4dbcff),_0x4531dc=_0x533845['a']['CreateCylinder']('cylinder',{'diameterTop':0x0,'height':0.075,'diameterBottom':0.0375*(0x1+(_0xa1c19-0x1)/0x4),'tessellation':0x60},_0x4dbcff),_0x6bd17b=_0x533845['a']['CreateCylinder']('cylinder',{'diameterTop':0.005*_0xa1c19,'height':0.275,'diameterBottom':0.005*_0xa1c19,'tessellation':0x60},_0x4dbcff);return _0x4531dc['parent']=_0x39cd40,_0x4531dc['material']=_0x3a69af,_0x4531dc['rotation']['x']=Math['PI']/0x2,_0x4531dc['position']['z']+=0.3,_0x6bd17b['parent']=_0x39cd40,_0x6bd17b['material']=_0x3a69af,_0x6bd17b['position']['z']+=0.1375,_0x6bd17b['rotation']['x']=Math['PI']/0x2,_0x5a0133&&(_0x6bd17b['visibility']=0x0,_0x4531dc['visibility']=0x0),_0x39cd40;},_0x5f42da['_CreateArrowInstance']=function(_0x2c2ed8,_0x38994e){for(var _0x555c94=new _0x3ebfdd['a']('arrow',_0x2c2ed8),_0x5f9f7a=0x0,_0x1c121e=_0x38994e['getChildMeshes']();_0x5f9f7a<_0x1c121e['length'];_0x5f9f7a++){var _0x4635c7=_0x1c121e[_0x5f9f7a];_0x4635c7['createInstance'](_0x4635c7['name'])['parent']=_0x555c94;}return _0x555c94;},_0x5f42da['prototype']['_attachedNodeChanged']=function(_0x4d4aa2){this['dragBehavior']&&(this['dragBehavior']['enabled']=!!_0x4d4aa2);},Object['defineProperty'](_0x5f42da['prototype'],'isEnabled',{'get':function(){return this['_isEnabled'];},'set':function(_0x48e781){this['_isEnabled']=_0x48e781,_0x48e781?this['_parent']&&(this['attachedMesh']=this['_parent']['attachedMesh'],this['attachedNode']=this['_parent']['attachedNode']):(this['attachedMesh']=null,this['attachedNode']=null);},'enumerable':!0x1,'configurable':!0x0}),_0x5f42da['prototype']['dispose']=function(){this['onSnapObservable']['clear'](),this['gizmoLayer']['utilityLayerScene']['onPointerObservable']['remove'](this['_pointerObserver']),this['dragBehavior']['detach'](),this['_gizmoMesh']&&this['_gizmoMesh']['dispose'](),[this['_coloredMaterial'],this['_hoverMaterial'],this['_disableMaterial']]['forEach'](function(_0xc9818){_0xc9818&&_0xc9818['dispose']();}),_0x4c927a['prototype']['dispose']['call'](this);},_0x5f42da;}(_0x693e7b['a']);},function(_0x262cb1,_0x523978,_0x408c36){'use strict';_0x408c36['d'](_0x523978,'a',function(){return _0x4c767b;});var _0x4c767b=(function(){function _0x5edc45(){this['_isDirty']=!0x0,this['_areLightsDirty']=!0x0,this['_areLightsDisposed']=!0x1,this['_areAttributesDirty']=!0x0,this['_areTexturesDirty']=!0x0,this['_areFresnelDirty']=!0x0,this['_areMiscDirty']=!0x0,this['_arePrePassDirty']=!0x0,this['_areImageProcessingDirty']=!0x0,this['_normals']=!0x1,this['_uvs']=!0x1,this['_needNormals']=!0x1,this['_needUVs']=!0x1;}return Object['defineProperty'](_0x5edc45['prototype'],'isDirty',{'get':function(){return this['_isDirty'];},'enumerable':!0x1,'configurable':!0x0}),_0x5edc45['prototype']['markAsProcessed']=function(){this['_isDirty']=!0x1,this['_areAttributesDirty']=!0x1,this['_areTexturesDirty']=!0x1,this['_areFresnelDirty']=!0x1,this['_areLightsDirty']=!0x1,this['_areLightsDisposed']=!0x1,this['_areMiscDirty']=!0x1,this['_arePrePassDirty']=!0x1,this['_areImageProcessingDirty']=!0x1;},_0x5edc45['prototype']['markAsUnprocessed']=function(){this['_isDirty']=!0x0;},_0x5edc45['prototype']['markAllAsDirty']=function(){this['_areTexturesDirty']=!0x0,this['_areAttributesDirty']=!0x0,this['_areLightsDirty']=!0x0,this['_areFresnelDirty']=!0x0,this['_areMiscDirty']=!0x0,this['_areImageProcessingDirty']=!0x0,this['_isDirty']=!0x0;},_0x5edc45['prototype']['markAsImageProcessingDirty']=function(){this['_areImageProcessingDirty']=!0x0,this['_isDirty']=!0x0;},_0x5edc45['prototype']['markAsLightDirty']=function(_0x2f8b72){void 0x0===_0x2f8b72&&(_0x2f8b72=!0x1),this['_areLightsDirty']=!0x0,this['_areLightsDisposed']=this['_areLightsDisposed']||_0x2f8b72,this['_isDirty']=!0x0;},_0x5edc45['prototype']['markAsAttributesDirty']=function(){this['_areAttributesDirty']=!0x0,this['_isDirty']=!0x0;},_0x5edc45['prototype']['markAsTexturesDirty']=function(){this['_areTexturesDirty']=!0x0,this['_isDirty']=!0x0;},_0x5edc45['prototype']['markAsFresnelDirty']=function(){this['_areFresnelDirty']=!0x0,this['_isDirty']=!0x0;},_0x5edc45['prototype']['markAsMiscDirty']=function(){this['_areMiscDirty']=!0x0,this['_isDirty']=!0x0;},_0x5edc45['prototype']['markAsPrePassDirty']=function(){this['_arePrePassDirty']=!0x0,this['_isDirty']=!0x0;},_0x5edc45['prototype']['rebuild']=function(){this['_keys']=[];for(var _0xa120b2=0x0,_0x3fdea3=Object['keys'](this);_0xa120b2<_0x3fdea3['length'];_0xa120b2++){var _0x2a1989=_0x3fdea3[_0xa120b2];'_'!==_0x2a1989[0x0]&&this['_keys']['push'](_0x2a1989);}},_0x5edc45['prototype']['isEqual']=function(_0x37279d){if(this['_keys']['length']!==_0x37279d['_keys']['length'])return!0x1;for(var _0x4db870=0x0;_0x4db870_0x51f777?_0x51f777:Math['floor'](_0x4a9675);var _0x14f84c,_0x4b96bc,_0x4f0484,_0x4f179b,_0x28f2fe=0x0===_0x396daa['sideOrientation']?0x0:_0x396daa['sideOrientation']||_0x459030['a']['DEFAULTSIDE'],_0x44729c=_0x396daa['uvs'],_0x1378bf=_0x396daa['colors'],_0x3377de=[],_0x8dd3ab=[],_0x48db0e=[],_0x2fa97f=[],_0x1aa8de=[],_0x48c8ac=[],_0x3974c7=[],_0x54e902=[],_0x115346=[],_0x37fb4b=[];if(_0x57991c['length']<0x2){var _0x173bae=[],_0x589bbe=[];for(_0x4f0484=0x0;_0x4f0484<_0x57991c[0x0]['length']-_0x4a9675;_0x4f0484++)_0x173bae['push'](_0x57991c[0x0][_0x4f0484]),_0x589bbe['push'](_0x57991c[0x0][_0x4f0484+_0x4a9675]);_0x57991c=[_0x173bae,_0x589bbe];}var _0x3408b1,_0x4d81c9,_0x29367f,_0x318610,_0xeaecc2,_0x49a89d=0x0,_0x30ac55=_0x3cd0d7?0x1:0x0;for(_0x14f84c=_0x57991c[0x0]['length'],_0x4b96bc=0x0;_0x4b96bc<_0x57991c['length'];_0x4b96bc++){for(_0x3974c7[_0x4b96bc]=0x0,_0x1aa8de[_0x4b96bc]=[0x0],_0x14f84c=_0x14f84c<(_0x4d81c9=(_0x3408b1=_0x57991c[_0x4b96bc])['length'])?_0x14f84c:_0x4d81c9,_0x4f179b=0x0;_0x4f179b<_0x4d81c9;)_0x3377de['push'](_0x3408b1[_0x4f179b]['x'],_0x3408b1[_0x4f179b]['y'],_0x3408b1[_0x4f179b]['z']),_0x4f179b>0x0&&(_0x29367f=_0x3408b1[_0x4f179b]['subtract'](_0x3408b1[_0x4f179b-0x1])['length']()+_0x3974c7[_0x4b96bc],_0x1aa8de[_0x4b96bc]['push'](_0x29367f),_0x3974c7[_0x4b96bc]=_0x29367f),_0x4f179b++;_0x3cd0d7&&(_0x4f179b--,_0x3377de['push'](_0x3408b1[0x0]['x'],_0x3408b1[0x0]['y'],_0x3408b1[0x0]['z']),_0x29367f=_0x3408b1[_0x4f179b]['subtract'](_0x3408b1[0x0])['length']()+_0x3974c7[_0x4b96bc],_0x1aa8de[_0x4b96bc]['push'](_0x29367f),_0x3974c7[_0x4b96bc]=_0x29367f),_0x115346[_0x4b96bc]=_0x4d81c9+_0x30ac55,_0x37fb4b[_0x4b96bc]=_0x49a89d,_0x49a89d+=_0x4d81c9+_0x30ac55;}var _0x312286,_0x46ade7,_0x2edf93=null,_0x5c81a3=null;for(_0x4f0484=0x0;_0x4f0484<_0x14f84c+_0x30ac55;_0x4f0484++){for(_0x54e902[_0x4f0484]=0x0,_0x48c8ac[_0x4f0484]=[0x0],_0x4b96bc=0x0;_0x4b96bc<_0x57991c['length']-0x1;_0x4b96bc++)_0x318610=_0x57991c[_0x4b96bc],_0xeaecc2=_0x57991c[_0x4b96bc+0x1],_0x4f0484===_0x14f84c?(_0x2edf93=_0x318610[0x0],_0x5c81a3=_0xeaecc2[0x0]):(_0x2edf93=_0x318610[_0x4f0484],_0x5c81a3=_0xeaecc2[_0x4f0484]),_0x29367f=_0x5c81a3['subtract'](_0x2edf93)['length']()+_0x54e902[_0x4f0484],_0x48c8ac[_0x4f0484]['push'](_0x29367f),_0x54e902[_0x4f0484]=_0x29367f;_0x2f1951&&_0x5c81a3&&_0x2edf93&&(_0x318610=_0x57991c[_0x4b96bc],_0xeaecc2=_0x57991c[0x0],_0x4f0484===_0x14f84c&&(_0x5c81a3=_0xeaecc2[0x0]),_0x29367f=_0x5c81a3['subtract'](_0x2edf93)['length']()+_0x54e902[_0x4f0484],_0x54e902[_0x4f0484]=_0x29367f);}if(_0x44729c){for(_0x4b96bc=0x0;_0x4b96bc<_0x44729c['length'];_0x4b96bc++)_0x2fa97f['push'](_0x44729c[_0x4b96bc]['x'],_0x44729c[_0x4b96bc]['y']);}else{for(_0x4b96bc=0x0;_0x4b96bc<_0x57991c['length'];_0x4b96bc++)for(_0x4f0484=0x0;_0x4f0484<_0x14f84c+_0x30ac55;_0x4f0484++)_0x312286=0x0!=_0x3974c7[_0x4b96bc]?_0x1aa8de[_0x4b96bc][_0x4f0484]/_0x3974c7[_0x4b96bc]:0x0,_0x46ade7=0x0!=_0x54e902[_0x4f0484]?_0x48c8ac[_0x4f0484][_0x4b96bc]/_0x54e902[_0x4f0484]:0x0,_0x569f0d?_0x2fa97f['push'](_0x46ade7,_0x312286):_0x2fa97f['push'](_0x312286,_0x46ade7);}for(var _0x1c3338=0x0,_0x365c55=_0x115346[_0x4b96bc=0x0]-0x1,_0x2a0773=_0x115346[_0x4b96bc+0x1]-0x1,_0x44fe3d=_0x365c55<_0x2a0773?_0x365c55:_0x2a0773,_0x15dbb1=_0x37fb4b[0x1]-_0x37fb4b[0x0],_0x11db7c=_0x2f1951?_0x115346['length']:_0x115346['length']-0x1;_0x1c3338<=_0x44fe3d&&_0x4b96bc<_0x11db7c;)_0x8dd3ab['push'](_0x1c3338,_0x1c3338+_0x15dbb1,_0x1c3338+0x1),_0x8dd3ab['push'](_0x1c3338+_0x15dbb1+0x1,_0x1c3338+0x1,_0x1c3338+_0x15dbb1),(_0x1c3338+=0x1)===_0x44fe3d&&(++_0x4b96bc===_0x115346['length']-0x1?(_0x15dbb1=_0x37fb4b[0x0]-_0x37fb4b[_0x4b96bc],_0x365c55=_0x115346[_0x4b96bc]-0x1,_0x2a0773=_0x115346[0x0]-0x1):(_0x15dbb1=_0x37fb4b[_0x4b96bc+0x1]-_0x37fb4b[_0x4b96bc],_0x365c55=_0x115346[_0x4b96bc]-0x1,_0x2a0773=_0x115346[_0x4b96bc+0x1]-0x1),_0x1c3338=_0x37fb4b[_0x4b96bc],_0x44fe3d=_0x365c55<_0x2a0773?_0x365c55+_0x1c3338:_0x2a0773+_0x1c3338);if(_0x459030['a']['ComputeNormals'](_0x3377de,_0x8dd3ab,_0x48db0e),_0x3cd0d7){var _0x28dc0e=0x0,_0x56dab3=0x0;for(_0x4b96bc=0x0;_0x4b96bc<_0x57991c['length'];_0x4b96bc++)_0x28dc0e=0x3*_0x37fb4b[_0x4b96bc],_0x56dab3=_0x4b96bc+0x1<_0x57991c['length']?0x3*(_0x37fb4b[_0x4b96bc+0x1]-0x1):_0x48db0e['length']-0x3,_0x48db0e[_0x28dc0e]=0.5*(_0x48db0e[_0x28dc0e]+_0x48db0e[_0x56dab3]),_0x48db0e[_0x28dc0e+0x1]=0.5*(_0x48db0e[_0x28dc0e+0x1]+_0x48db0e[_0x56dab3+0x1]),_0x48db0e[_0x28dc0e+0x2]=0.5*(_0x48db0e[_0x28dc0e+0x2]+_0x48db0e[_0x56dab3+0x2]),_0x48db0e[_0x56dab3]=_0x48db0e[_0x28dc0e],_0x48db0e[_0x56dab3+0x1]=_0x48db0e[_0x28dc0e+0x1],_0x48db0e[_0x56dab3+0x2]=_0x48db0e[_0x28dc0e+0x2];}_0x459030['a']['_ComputeSides'](_0x28f2fe,_0x3377de,_0x8dd3ab,_0x48db0e,_0x2fa97f,_0x396daa['frontUVs'],_0x396daa['backUVs']);var _0x1376de=null;if(_0x1378bf){_0x1376de=new Float32Array(0x4*_0x1378bf['length']);for(var _0xbbfe07=0x0;_0xbbfe07<_0x1378bf['length'];_0xbbfe07++)_0x1376de[0x4*_0xbbfe07]=_0x1378bf[_0xbbfe07]['r'],_0x1376de[0x4*_0xbbfe07+0x1]=_0x1378bf[_0xbbfe07]['g'],_0x1376de[0x4*_0xbbfe07+0x2]=_0x1378bf[_0xbbfe07]['b'],_0x1376de[0x4*_0xbbfe07+0x3]=_0x1378bf[_0xbbfe07]['a'];}var _0x2efcd7=new _0x459030['a'](),_0x3ab072=new Float32Array(_0x3377de),_0x1a8883=new Float32Array(_0x48db0e),_0x4c88b8=new Float32Array(_0x2fa97f);return _0x2efcd7['indices']=_0x8dd3ab,_0x2efcd7['positions']=_0x3ab072,_0x2efcd7['normals']=_0x1a8883,_0x2efcd7['uvs']=_0x4c88b8,_0x1376de&&_0x2efcd7['set'](_0x1376de,_0x2b03b3['b']['ColorKind']),_0x3cd0d7&&(_0x2efcd7['_idx']=_0x37fb4b),_0x2efcd7;},_0x7a7ef5['a']['CreateRibbon']=function(_0x7eb7fd,_0x3a6b72,_0x450028,_0xad2188,_0x20ab91,_0x10a689,_0x1b77af,_0x3952bb,_0x171867){return void 0x0===_0x450028&&(_0x450028=!0x1),void 0x0===_0x1b77af&&(_0x1b77af=!0x1),_0x1e4fba['CreateRibbon'](_0x7eb7fd,{'pathArray':_0x3a6b72,'closeArray':_0x450028,'closePath':_0xad2188,'offset':_0x20ab91,'updatable':_0x1b77af,'sideOrientation':_0x3952bb,'instance':_0x171867},_0x10a689);};var _0x1e4fba=(function(){function _0x4b81a9(){}return _0x4b81a9['CreateRibbon']=function(_0x51a848,_0x1ccc2c,_0x9925f){void 0x0===_0x9925f&&(_0x9925f=null);var _0x40912b=_0x1ccc2c['pathArray'],_0x38adf2=_0x1ccc2c['closeArray'],_0x25b7e7=_0x1ccc2c['closePath'],_0x417e7c=_0x7a7ef5['a']['_GetDefaultSideOrientation'](_0x1ccc2c['sideOrientation']),_0x1fcfa6=_0x1ccc2c['instance'],_0x4bbd2c=_0x1ccc2c['updatable'];if(_0x1fcfa6){var _0x506ecd=_0x2fa7a2['c']['Vector3'][0x0]['setAll'](Number['MAX_VALUE']),_0x4b8c61=_0x2fa7a2['c']['Vector3'][0x1]['setAll'](-Number['MAX_VALUE']),_0x50b3ef=_0x1fcfa6['getVerticesData'](_0x2b03b3['b']['PositionKind']);if(function(_0x26ddff){for(var _0x367688=_0x40912b[0x0]['length'],_0x4f8747=_0x1fcfa6,_0x197fba=0x0,_0x4b93fc=_0x4f8747['_originalBuilderSideOrientation']===_0x7a7ef5['a']['DOUBLESIDE']?0x2:0x1,_0x54894f=0x1;_0x54894f<=_0x4b93fc;++_0x54894f)for(var _0x568ed9=0x0;_0x568ed9<_0x40912b['length'];++_0x568ed9){var _0x5dd101=_0x40912b[_0x568ed9],_0xd2cedc=_0x5dd101['length'];_0x367688=_0x367688<_0xd2cedc?_0x367688:_0xd2cedc;for(var _0x3cc4c0=0x0;_0x3cc4c0<_0x367688;++_0x3cc4c0){var _0x38b284=_0x5dd101[_0x3cc4c0];_0x26ddff[_0x197fba]=_0x38b284['x'],_0x26ddff[_0x197fba+0x1]=_0x38b284['y'],_0x26ddff[_0x197fba+0x2]=_0x38b284['z'],_0x506ecd['minimizeInPlaceFromFloats'](_0x38b284['x'],_0x38b284['y'],_0x38b284['z']),_0x4b8c61['maximizeInPlaceFromFloats'](_0x38b284['x'],_0x38b284['y'],_0x38b284['z']),_0x197fba+=0x3;}_0x4f8747['_creationDataStorage']&&_0x4f8747['_creationDataStorage']['closePath']&&(_0x38b284=_0x5dd101[0x0],(_0x26ddff[_0x197fba]=_0x38b284['x'],_0x26ddff[_0x197fba+0x1]=_0x38b284['y'],_0x26ddff[_0x197fba+0x2]=_0x38b284['z'],_0x197fba+=0x3));}}(_0x50b3ef),_0x1fcfa6['_boundingInfo']?_0x1fcfa6['_boundingInfo']['reConstruct'](_0x506ecd,_0x4b8c61,_0x1fcfa6['_worldMatrix']):_0x1fcfa6['_boundingInfo']=new _0x2a8904['a'](_0x506ecd,_0x4b8c61,_0x1fcfa6['_worldMatrix']),_0x1fcfa6['updateVerticesData'](_0x2b03b3['b']['PositionKind'],_0x50b3ef,!0x1,!0x1),_0x1ccc2c['colors']){for(var _0x392580=_0x1fcfa6['getVerticesData'](_0x2b03b3['b']['ColorKind']),_0x4276aa=0x0,_0x575e96=0x0;_0x4276aa<_0x1ccc2c['colors']['length'];_0x4276aa++,_0x575e96+=0x4){var _0x4fca6a=_0x1ccc2c['colors'][_0x4276aa];_0x392580[_0x575e96]=_0x4fca6a['r'],_0x392580[_0x575e96+0x1]=_0x4fca6a['g'],_0x392580[_0x575e96+0x2]=_0x4fca6a['b'],_0x392580[_0x575e96+0x3]=_0x4fca6a['a'];}_0x1fcfa6['updateVerticesData'](_0x2b03b3['b']['ColorKind'],_0x392580,!0x1,!0x1);}if(_0x1ccc2c['uvs']){for(var _0x534bfa=_0x1fcfa6['getVerticesData'](_0x2b03b3['b']['UVKind']),_0x3c6a62=0x0;_0x3c6a62<_0x1ccc2c['uvs']['length'];_0x3c6a62++)_0x534bfa[0x2*_0x3c6a62]=_0x1ccc2c['uvs'][_0x3c6a62]['x'],_0x534bfa[0x2*_0x3c6a62+0x1]=_0x1ccc2c['uvs'][_0x3c6a62]['y'];_0x1fcfa6['updateVerticesData'](_0x2b03b3['b']['UVKind'],_0x534bfa,!0x1,!0x1);}if(!_0x1fcfa6['areNormalsFrozen']||_0x1fcfa6['isFacetDataEnabled']){var _0xb27c3d=_0x1fcfa6['getIndices'](),_0x32919c=_0x1fcfa6['getVerticesData'](_0x2b03b3['b']['NormalKind']),_0x291872=_0x1fcfa6['isFacetDataEnabled']?_0x1fcfa6['getFacetDataParameters']():null;if(_0x459030['a']['ComputeNormals'](_0x50b3ef,_0xb27c3d,_0x32919c,_0x291872),_0x1fcfa6['_creationDataStorage']&&_0x1fcfa6['_creationDataStorage']['closePath']){for(var _0x5c0bbd=0x0,_0x5f97=0x0,_0x502a6f=0x0;_0x502a6f<_0x40912b['length'];_0x502a6f++)_0x5c0bbd=0x3*_0x1fcfa6['_creationDataStorage']['idx'][_0x502a6f],_0x5f97=_0x502a6f+0x1<_0x40912b['length']?0x3*(_0x1fcfa6['_creationDataStorage']['idx'][_0x502a6f+0x1]-0x1):_0x32919c['length']-0x3,_0x32919c[_0x5c0bbd]=0.5*(_0x32919c[_0x5c0bbd]+_0x32919c[_0x5f97]),_0x32919c[_0x5c0bbd+0x1]=0.5*(_0x32919c[_0x5c0bbd+0x1]+_0x32919c[_0x5f97+0x1]),_0x32919c[_0x5c0bbd+0x2]=0.5*(_0x32919c[_0x5c0bbd+0x2]+_0x32919c[_0x5f97+0x2]),_0x32919c[_0x5f97]=_0x32919c[_0x5c0bbd],_0x32919c[_0x5f97+0x1]=_0x32919c[_0x5c0bbd+0x1],_0x32919c[_0x5f97+0x2]=_0x32919c[_0x5c0bbd+0x2];}_0x1fcfa6['areNormalsFrozen']||_0x1fcfa6['updateVerticesData'](_0x2b03b3['b']['NormalKind'],_0x32919c,!0x1,!0x1);}return _0x1fcfa6;}var _0x21fef9=new _0x7a7ef5['a'](_0x51a848,_0x9925f);_0x21fef9['_originalBuilderSideOrientation']=_0x417e7c,_0x21fef9['_creationDataStorage']=new _0x7a7ef5['b']();var _0x1c29d5=_0x459030['a']['CreateRibbon'](_0x1ccc2c);return _0x25b7e7&&(_0x21fef9['_creationDataStorage']['idx']=_0x1c29d5['_idx']),_0x21fef9['_creationDataStorage']['closePath']=_0x25b7e7,_0x21fef9['_creationDataStorage']['closeArray']=_0x38adf2,_0x1c29d5['applyToMesh'](_0x21fef9,_0x4bbd2c),_0x21fef9;},_0x4b81a9;}());},function(_0x3a93eb,_0x417e3d,_0x47f108){'use strict';_0x47f108['d'](_0x417e3d,'a',function(){return _0x24e040;});var _0x24e040=(function(){function _0x8a8abb(){}return _0x8a8abb['FilesToLoad']={},_0x8a8abb;}());},function(_0x5e8f0c,_0x333080,_0x722765){'use strict';_0x722765['d'](_0x333080,'a',function(){return _0x52feeb;});var _0xf6556b=_0x722765(0x7),_0x3e3efc=_0x722765(0x10);_0x3e3efc['a']['CreatePlane']=function(_0x58097d){var _0x1663c5=[],_0x90ba2d=[],_0x32eff5=[],_0x54773c=[],_0x40203a=_0x58097d['width']||_0x58097d['size']||0x1,_0xa322d5=_0x58097d['height']||_0x58097d['size']||0x1,_0xbee9f3=0x0===_0x58097d['sideOrientation']?0x0:_0x58097d['sideOrientation']||_0x3e3efc['a']['DEFAULTSIDE'],_0x507d1a=_0x40203a/0x2,_0x7388df=_0xa322d5/0x2;_0x90ba2d['push'](-_0x507d1a,-_0x7388df,0x0),_0x32eff5['push'](0x0,0x0,-0x1),_0x54773c['push'](0x0,0x0),_0x90ba2d['push'](_0x507d1a,-_0x7388df,0x0),_0x32eff5['push'](0x0,0x0,-0x1),_0x54773c['push'](0x1,0x0),_0x90ba2d['push'](_0x507d1a,_0x7388df,0x0),_0x32eff5['push'](0x0,0x0,-0x1),_0x54773c['push'](0x1,0x1),_0x90ba2d['push'](-_0x507d1a,_0x7388df,0x0),_0x32eff5['push'](0x0,0x0,-0x1),_0x54773c['push'](0x0,0x1),_0x1663c5['push'](0x0),_0x1663c5['push'](0x1),_0x1663c5['push'](0x2),_0x1663c5['push'](0x0),_0x1663c5['push'](0x2),_0x1663c5['push'](0x3),_0x3e3efc['a']['_ComputeSides'](_0xbee9f3,_0x90ba2d,_0x1663c5,_0x32eff5,_0x54773c,_0x58097d['frontUVs'],_0x58097d['backUVs']);var _0x3aba3d=new _0x3e3efc['a']();return _0x3aba3d['indices']=_0x1663c5,_0x3aba3d['positions']=_0x90ba2d,_0x3aba3d['normals']=_0x32eff5,_0x3aba3d['uvs']=_0x54773c,_0x3aba3d;},_0xf6556b['a']['CreatePlane']=function(_0x47e071,_0x1c6e4e,_0x339386,_0x47299c,_0x116aa5){var _0x27834f={'size':_0x1c6e4e,'width':_0x1c6e4e,'height':_0x1c6e4e,'sideOrientation':_0x116aa5,'updatable':_0x47299c};return _0x52feeb['CreatePlane'](_0x47e071,_0x27834f,_0x339386);};var _0x52feeb=(function(){function _0x42bcb2(){}return _0x42bcb2['CreatePlane']=function(_0x363cc4,_0x23ad70,_0x42d520){void 0x0===_0x42d520&&(_0x42d520=null);var _0x3d31ae=new _0xf6556b['a'](_0x363cc4,_0x42d520);return _0x23ad70['sideOrientation']=_0xf6556b['a']['_GetDefaultSideOrientation'](_0x23ad70['sideOrientation']),_0x3d31ae['_originalBuilderSideOrientation']=_0x23ad70['sideOrientation'],_0x3e3efc['a']['CreatePlane'](_0x23ad70)['applyToMesh'](_0x3d31ae,_0x23ad70['updatable']),_0x23ad70['sourcePlane']&&(_0x3d31ae['translate'](_0x23ad70['sourcePlane']['normal'],-_0x23ad70['sourcePlane']['d']),_0x3d31ae['setDirection'](_0x23ad70['sourcePlane']['normal']['scale'](-0x1))),_0x3d31ae;},_0x42bcb2;}());},function(_0x41b3e2,_0x42c3a8,_0x52e2b4){'use strict';_0x52e2b4['d'](_0x42c3a8,'a',function(){return _0x584913;});var _0x25d502=_0x52e2b4(0x8),_0x584913=(_0x52e2b4(0x99),(function(){function _0x5ad09e(_0x510b57,_0x148133,_0x3d5ef5){this['_alreadyBound']=!0x1,this['_valueCache']={},this['_engine']=_0x510b57,this['_noUBO']=!_0x510b57['supportsUniformBuffers'],this['_dynamic']=_0x3d5ef5,this['_data']=_0x148133||[],this['_uniformLocations']={},this['_uniformSizes']={},this['_uniformLocationPointer']=0x0,this['_needSync']=!0x1,this['_noUBO']?(this['updateMatrix3x3']=this['_updateMatrix3x3ForEffect'],this['updateMatrix2x2']=this['_updateMatrix2x2ForEffect'],this['updateFloat']=this['_updateFloatForEffect'],this['updateFloat2']=this['_updateFloat2ForEffect'],this['updateFloat3']=this['_updateFloat3ForEffect'],this['updateFloat4']=this['_updateFloat4ForEffect'],this['updateMatrix']=this['_updateMatrixForEffect'],this['updateVector3']=this['_updateVector3ForEffect'],this['updateVector4']=this['_updateVector4ForEffect'],this['updateColor3']=this['_updateColor3ForEffect'],this['updateColor4']=this['_updateColor4ForEffect']):(this['_engine']['_uniformBuffers']['push'](this),this['updateMatrix3x3']=this['_updateMatrix3x3ForUniform'],this['updateMatrix2x2']=this['_updateMatrix2x2ForUniform'],this['updateFloat']=this['_updateFloatForUniform'],this['updateFloat2']=this['_updateFloat2ForUniform'],this['updateFloat3']=this['_updateFloat3ForUniform'],this['updateFloat4']=this['_updateFloat4ForUniform'],this['updateMatrix']=this['_updateMatrixForUniform'],this['updateVector3']=this['_updateVector3ForUniform'],this['updateVector4']=this['_updateVector4ForUniform'],this['updateColor3']=this['_updateColor3ForUniform'],this['updateColor4']=this['_updateColor4ForUniform']);}return Object['defineProperty'](_0x5ad09e['prototype'],'useUbo',{'get':function(){return!this['_noUBO'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5ad09e['prototype'],'isSync',{'get':function(){return!this['_needSync'];},'enumerable':!0x1,'configurable':!0x0}),_0x5ad09e['prototype']['isDynamic']=function(){return void 0x0!==this['_dynamic'];},_0x5ad09e['prototype']['getData']=function(){return this['_bufferData'];},_0x5ad09e['prototype']['getBuffer']=function(){return this['_buffer'];},_0x5ad09e['prototype']['_fillAlignment']=function(_0x593665){var _0x458201;if(_0x458201=_0x593665<=0x2?_0x593665:0x4,this['_uniformLocationPointer']%_0x458201!=0x0){var _0x32dcde=this['_uniformLocationPointer'];this['_uniformLocationPointer']+=_0x458201-this['_uniformLocationPointer']%_0x458201;for(var _0x5d766e=this['_uniformLocationPointer']-_0x32dcde,_0x49d35c=0x0;_0x49d35c<_0x5d766e;_0x49d35c++)this['_data']['push'](0x0);}},_0x5ad09e['prototype']['addUniform']=function(_0x124fe3,_0x5ea353){if(!this['_noUBO']&&void 0x0===this['_uniformLocations'][_0x124fe3]){var _0x55a7ed;if(_0x5ea353 instanceof Array)_0x5ea353=(_0x55a7ed=_0x5ea353)['length'];else{_0x5ea353=_0x5ea353,_0x55a7ed=[];for(var _0x48e432=0x0;_0x48e432<_0x5ea353;_0x48e432++)_0x55a7ed['push'](0x0);}this['_fillAlignment'](_0x5ea353),this['_uniformSizes'][_0x124fe3]=_0x5ea353,this['_uniformLocations'][_0x124fe3]=this['_uniformLocationPointer'],this['_uniformLocationPointer']+=_0x5ea353;for(_0x48e432=0x0;_0x48e432<_0x5ea353;_0x48e432++)this['_data']['push'](_0x55a7ed[_0x48e432]);this['_needSync']=!0x0;}},_0x5ad09e['prototype']['addMatrix']=function(_0x4478fc,_0x2778ca){this['addUniform'](_0x4478fc,Array['prototype']['slice']['call'](_0x2778ca['toArray']()));},_0x5ad09e['prototype']['addFloat2']=function(_0x2ccb66,_0x14d7cc,_0x3e3b1f){var _0x445247=[_0x14d7cc,_0x3e3b1f];this['addUniform'](_0x2ccb66,_0x445247);},_0x5ad09e['prototype']['addFloat3']=function(_0x55a11b,_0x32386b,_0x194a0e,_0x5a5d9c){var _0x1d4e6e=[_0x32386b,_0x194a0e,_0x5a5d9c];this['addUniform'](_0x55a11b,_0x1d4e6e);},_0x5ad09e['prototype']['addColor3']=function(_0x40467b,_0x22d9e7){var _0x541e98=new Array();_0x22d9e7['toArray'](_0x541e98),this['addUniform'](_0x40467b,_0x541e98);},_0x5ad09e['prototype']['addColor4']=function(_0x4e2b4e,_0x147fdf,_0x39ae64){var _0x546cf9=new Array();_0x147fdf['toArray'](_0x546cf9),_0x546cf9['push'](_0x39ae64),this['addUniform'](_0x4e2b4e,_0x546cf9);},_0x5ad09e['prototype']['addVector3']=function(_0x2c7bf1,_0x586789){var _0x3b0efb=new Array();_0x586789['toArray'](_0x3b0efb),this['addUniform'](_0x2c7bf1,_0x3b0efb);},_0x5ad09e['prototype']['addMatrix3x3']=function(_0x3448c2){this['addUniform'](_0x3448c2,0xc);},_0x5ad09e['prototype']['addMatrix2x2']=function(_0x3f43c0){this['addUniform'](_0x3f43c0,0x8);},_0x5ad09e['prototype']['create']=function(){this['_noUBO']||this['_buffer']||(this['_fillAlignment'](0x4),this['_bufferData']=new Float32Array(this['_data']),this['_rebuild'](),this['_needSync']=!0x0);},_0x5ad09e['prototype']['_rebuild']=function(){!this['_noUBO']&&this['_bufferData']&&(this['_dynamic']?this['_buffer']=this['_engine']['createDynamicUniformBuffer'](this['_bufferData']):this['_buffer']=this['_engine']['createUniformBuffer'](this['_bufferData']));},_0x5ad09e['prototype']['update']=function(){this['_buffer']?(this['_dynamic']||this['_needSync'])&&(this['_engine']['updateUniformBuffer'](this['_buffer'],this['_bufferData']),this['_needSync']=!0x1):this['create']();},_0x5ad09e['prototype']['updateUniform']=function(_0x8673b0,_0x29d992,_0x49b796){var _0x423172=this['_uniformLocations'][_0x8673b0];if(void 0x0===_0x423172){if(this['_buffer'])return void _0x25d502['a']['Error']('Cannot\x20add\x20an\x20uniform\x20after\x20UBO\x20has\x20been\x20created.');this['addUniform'](_0x8673b0,_0x49b796),_0x423172=this['_uniformLocations'][_0x8673b0];}if(this['_buffer']||this['create'](),this['_dynamic']){for(_0x2ec9f6=0x0;_0x2ec9f6<_0x49b796;_0x2ec9f6++)this['_bufferData'][_0x423172+_0x2ec9f6]=_0x29d992[_0x2ec9f6];}else{for(var _0x1b8b37=!0x1,_0x2ec9f6=0x0;_0x2ec9f6<_0x49b796;_0x2ec9f6++)0x10!==_0x49b796&&this['_bufferData'][_0x423172+_0x2ec9f6]===_0x29d992[_0x2ec9f6]||(_0x1b8b37=!0x0,this['_bufferData'][_0x423172+_0x2ec9f6]=_0x29d992[_0x2ec9f6]);this['_needSync']=this['_needSync']||_0x1b8b37;}},_0x5ad09e['prototype']['_cacheMatrix']=function(_0x52a155,_0x5edb2a){var _0x3c73d5=this['_valueCache'][_0x52a155],_0x86452a=_0x5edb2a['updateFlag'];return(void 0x0===_0x3c73d5||_0x3c73d5!==_0x86452a)&&(this['_valueCache'][_0x52a155]=_0x86452a,!0x0);},_0x5ad09e['prototype']['_updateMatrix3x3ForUniform']=function(_0x541efc,_0x5e6efd){for(var _0x15a068=0x0;_0x15a068<0x3;_0x15a068++)_0x5ad09e['_tempBuffer'][0x4*_0x15a068]=_0x5e6efd[0x3*_0x15a068],_0x5ad09e['_tempBuffer'][0x4*_0x15a068+0x1]=_0x5e6efd[0x3*_0x15a068+0x1],_0x5ad09e['_tempBuffer'][0x4*_0x15a068+0x2]=_0x5e6efd[0x3*_0x15a068+0x2],_0x5ad09e['_tempBuffer'][0x4*_0x15a068+0x3]=0x0;this['updateUniform'](_0x541efc,_0x5ad09e['_tempBuffer'],0xc);},_0x5ad09e['prototype']['_updateMatrix3x3ForEffect']=function(_0x34499d,_0x33b0a3){this['_currentEffect']['setMatrix3x3'](_0x34499d,_0x33b0a3);},_0x5ad09e['prototype']['_updateMatrix2x2ForEffect']=function(_0x4a8e72,_0x3b0586){this['_currentEffect']['setMatrix2x2'](_0x4a8e72,_0x3b0586);},_0x5ad09e['prototype']['_updateMatrix2x2ForUniform']=function(_0x5a7c87,_0x38e1cb){for(var _0x2d4d71=0x0;_0x2d4d71<0x2;_0x2d4d71++)_0x5ad09e['_tempBuffer'][0x4*_0x2d4d71]=_0x38e1cb[0x2*_0x2d4d71],_0x5ad09e['_tempBuffer'][0x4*_0x2d4d71+0x1]=_0x38e1cb[0x2*_0x2d4d71+0x1],_0x5ad09e['_tempBuffer'][0x4*_0x2d4d71+0x2]=0x0,_0x5ad09e['_tempBuffer'][0x4*_0x2d4d71+0x3]=0x0;this['updateUniform'](_0x5a7c87,_0x5ad09e['_tempBuffer'],0x8);},_0x5ad09e['prototype']['_updateFloatForEffect']=function(_0x49e913,_0x85653b){this['_currentEffect']['setFloat'](_0x49e913,_0x85653b);},_0x5ad09e['prototype']['_updateFloatForUniform']=function(_0x35dac5,_0xeeb242){_0x5ad09e['_tempBuffer'][0x0]=_0xeeb242,this['updateUniform'](_0x35dac5,_0x5ad09e['_tempBuffer'],0x1);},_0x5ad09e['prototype']['_updateFloat2ForEffect']=function(_0xdc249f,_0x3f88d2,_0x4a88dc,_0x2110e7){void 0x0===_0x2110e7&&(_0x2110e7=''),this['_currentEffect']['setFloat2'](_0xdc249f+_0x2110e7,_0x3f88d2,_0x4a88dc);},_0x5ad09e['prototype']['_updateFloat2ForUniform']=function(_0xc5e9aa,_0x138653,_0x121bcb){_0x5ad09e['_tempBuffer'][0x0]=_0x138653,_0x5ad09e['_tempBuffer'][0x1]=_0x121bcb,this['updateUniform'](_0xc5e9aa,_0x5ad09e['_tempBuffer'],0x2);},_0x5ad09e['prototype']['_updateFloat3ForEffect']=function(_0x2b5ac8,_0x4636bc,_0x1a534a,_0x381fc4,_0x536514){void 0x0===_0x536514&&(_0x536514=''),this['_currentEffect']['setFloat3'](_0x2b5ac8+_0x536514,_0x4636bc,_0x1a534a,_0x381fc4);},_0x5ad09e['prototype']['_updateFloat3ForUniform']=function(_0x1e5f3a,_0x5a9ab0,_0x2a40e0,_0x19308e){_0x5ad09e['_tempBuffer'][0x0]=_0x5a9ab0,_0x5ad09e['_tempBuffer'][0x1]=_0x2a40e0,_0x5ad09e['_tempBuffer'][0x2]=_0x19308e,this['updateUniform'](_0x1e5f3a,_0x5ad09e['_tempBuffer'],0x3);},_0x5ad09e['prototype']['_updateFloat4ForEffect']=function(_0x42150f,_0x2c0e31,_0x4edc7d,_0x47df3d,_0x927c5b,_0xb1e0a9){void 0x0===_0xb1e0a9&&(_0xb1e0a9=''),this['_currentEffect']['setFloat4'](_0x42150f+_0xb1e0a9,_0x2c0e31,_0x4edc7d,_0x47df3d,_0x927c5b);},_0x5ad09e['prototype']['_updateFloat4ForUniform']=function(_0xd17c59,_0x17febe,_0x1ac211,_0x30ea03,_0x487cc2){_0x5ad09e['_tempBuffer'][0x0]=_0x17febe,_0x5ad09e['_tempBuffer'][0x1]=_0x1ac211,_0x5ad09e['_tempBuffer'][0x2]=_0x30ea03,_0x5ad09e['_tempBuffer'][0x3]=_0x487cc2,this['updateUniform'](_0xd17c59,_0x5ad09e['_tempBuffer'],0x4);},_0x5ad09e['prototype']['_updateMatrixForEffect']=function(_0x31dad1,_0x7d0f3b){this['_currentEffect']['setMatrix'](_0x31dad1,_0x7d0f3b);},_0x5ad09e['prototype']['_updateMatrixForUniform']=function(_0x393cee,_0x30fc05){this['_cacheMatrix'](_0x393cee,_0x30fc05)&&this['updateUniform'](_0x393cee,_0x30fc05['toArray'](),0x10);},_0x5ad09e['prototype']['_updateVector3ForEffect']=function(_0x2785e9,_0x166a41){this['_currentEffect']['setVector3'](_0x2785e9,_0x166a41);},_0x5ad09e['prototype']['_updateVector3ForUniform']=function(_0x488c22,_0x4f5e9c){_0x4f5e9c['toArray'](_0x5ad09e['_tempBuffer']),this['updateUniform'](_0x488c22,_0x5ad09e['_tempBuffer'],0x3);},_0x5ad09e['prototype']['_updateVector4ForEffect']=function(_0x5c2d93,_0x5619fe){this['_currentEffect']['setVector4'](_0x5c2d93,_0x5619fe);},_0x5ad09e['prototype']['_updateVector4ForUniform']=function(_0x431b7a,_0x5506b6){_0x5506b6['toArray'](_0x5ad09e['_tempBuffer']),this['updateUniform'](_0x431b7a,_0x5ad09e['_tempBuffer'],0x4);},_0x5ad09e['prototype']['_updateColor3ForEffect']=function(_0x27a367,_0xf12ad2,_0x3fca34){void 0x0===_0x3fca34&&(_0x3fca34=''),this['_currentEffect']['setColor3'](_0x27a367+_0x3fca34,_0xf12ad2);},_0x5ad09e['prototype']['_updateColor3ForUniform']=function(_0x2bf103,_0x3141e3){_0x3141e3['toArray'](_0x5ad09e['_tempBuffer']),this['updateUniform'](_0x2bf103,_0x5ad09e['_tempBuffer'],0x3);},_0x5ad09e['prototype']['_updateColor4ForEffect']=function(_0x292bf8,_0x1b5d37,_0x32664d,_0x5a7dc9){void 0x0===_0x5a7dc9&&(_0x5a7dc9=''),this['_currentEffect']['setColor4'](_0x292bf8+_0x5a7dc9,_0x1b5d37,_0x32664d);},_0x5ad09e['prototype']['_updateColor4ForUniform']=function(_0x550c31,_0xb09dd6,_0x5b84f6){_0xb09dd6['toArray'](_0x5ad09e['_tempBuffer']),_0x5ad09e['_tempBuffer'][0x3]=_0x5b84f6,this['updateUniform'](_0x550c31,_0x5ad09e['_tempBuffer'],0x4);},_0x5ad09e['prototype']['setTexture']=function(_0x191a55,_0x13b2d3){this['_currentEffect']['setTexture'](_0x191a55,_0x13b2d3);},_0x5ad09e['prototype']['updateUniformDirectly']=function(_0x1f116e,_0x17b3a0){this['updateUniform'](_0x1f116e,_0x17b3a0,_0x17b3a0['length']),this['update']();},_0x5ad09e['prototype']['bindToEffect']=function(_0x2adb99,_0x38af25){this['_currentEffect']=_0x2adb99,!this['_noUBO']&&this['_buffer']&&(this['_alreadyBound']=!0x0,_0x2adb99['bindUniformBuffer'](this['_buffer'],_0x38af25));},_0x5ad09e['prototype']['dispose']=function(){if(!this['_noUBO']){var _0x144ad4=this['_engine']['_uniformBuffers'],_0x355912=_0x144ad4['indexOf'](this);-0x1!==_0x355912&&(_0x144ad4[_0x355912]=_0x144ad4[_0x144ad4['length']-0x1],_0x144ad4['pop']()),this['_buffer']&&this['_engine']['_releaseBuffer'](this['_buffer'])&&(this['_buffer']=null);}},_0x5ad09e['_MAX_UNIFORM_SIZE']=0x100,_0x5ad09e['_tempBuffer']=new Float32Array(_0x5ad09e['_MAX_UNIFORM_SIZE']),_0x5ad09e;}()));},function(_0x296001,_0x3dcafd,_0x204a9a){'use strict';_0x204a9a['d'](_0x3dcafd,'a',function(){return _0x3be48c;});var _0x401938=_0x204a9a(0x1),_0x42491d=_0x204a9a(0x3),_0x143890=_0x204a9a(0x0),_0x49de26=_0x204a9a(0x9),_0x538550=_0x204a9a(0x1d),_0x5baac1=_0x204a9a(0x30);_0x538550['a']['AddNodeConstructor']('Light_Type_3',function(_0x45bab5,_0x5ac7d1){return function(){return new _0x3be48c(_0x45bab5,_0x143890['e']['Zero'](),_0x5ac7d1);};});var _0x3be48c=function(_0x37da0d){function _0x21cf7e(_0x110cc9,_0x594981,_0x1285ba){var _0x570c14=_0x37da0d['call'](this,_0x110cc9,_0x1285ba)||this;return _0x570c14['groundColor']=new _0x49de26['a'](0x0,0x0,0x0),_0x570c14['direction']=_0x594981||_0x143890['e']['Up'](),_0x570c14;}return Object(_0x401938['d'])(_0x21cf7e,_0x37da0d),_0x21cf7e['prototype']['_buildUniformLayout']=function(){this['_uniformBuffer']['addUniform']('vLightData',0x4),this['_uniformBuffer']['addUniform']('vLightDiffuse',0x4),this['_uniformBuffer']['addUniform']('vLightSpecular',0x4),this['_uniformBuffer']['addUniform']('vLightGround',0x3),this['_uniformBuffer']['addUniform']('shadowsInfo',0x3),this['_uniformBuffer']['addUniform']('depthValues',0x2),this['_uniformBuffer']['create']();},_0x21cf7e['prototype']['getClassName']=function(){return'HemisphericLight';},_0x21cf7e['prototype']['setDirectionToTarget']=function(_0x514f8e){return this['direction']=_0x143890['e']['Normalize'](_0x514f8e['subtract'](_0x143890['e']['Zero']())),this['direction'];},_0x21cf7e['prototype']['getShadowGenerator']=function(){return null;},_0x21cf7e['prototype']['transferToEffect']=function(_0x3194ea,_0x7ff9b8){var _0xa29483=_0x143890['e']['Normalize'](this['direction']);return this['_uniformBuffer']['updateFloat4']('vLightData',_0xa29483['x'],_0xa29483['y'],_0xa29483['z'],0x0,_0x7ff9b8),this['_uniformBuffer']['updateColor3']('vLightGround',this['groundColor']['scale'](this['intensity']),_0x7ff9b8),this;},_0x21cf7e['prototype']['transferToNodeMaterialEffect']=function(_0x4599d2,_0x162c10){var _0xdb3275=_0x143890['e']['Normalize'](this['direction']);return _0x4599d2['setFloat3'](_0x162c10,_0xdb3275['x'],_0xdb3275['y'],_0xdb3275['z']),this;},_0x21cf7e['prototype']['computeWorldMatrix']=function(){return this['_worldMatrix']||(this['_worldMatrix']=_0x143890['a']['Identity']()),this['_worldMatrix'];},_0x21cf7e['prototype']['getTypeID']=function(){return _0x5baac1['a']['LIGHTTYPEID_HEMISPHERICLIGHT'];},_0x21cf7e['prototype']['prepareLightSpecificDefines']=function(_0x5d4153,_0x7a267){_0x5d4153['HEMILIGHT'+_0x7a267]=!0x0;},Object(_0x401938['c'])([Object(_0x42491d['e'])()],_0x21cf7e['prototype'],'groundColor',void 0x0),Object(_0x401938['c'])([Object(_0x42491d['o'])()],_0x21cf7e['prototype'],'direction',void 0x0),_0x21cf7e;}(_0x5baac1['a']);},function(_0x570e57,_0x825dd9,_0xfa3f73){'use strict';_0xfa3f73['d'](_0x825dd9,'a',function(){return _0x37a6fb;});var _0xfcad27=_0xfa3f73(0x1),_0x116386=_0xfa3f73(0x0),_0x37a6fb=function(_0x412e12){function _0x1037a6(_0x1be1c2,_0x1b177b){var _0x5b6682=_0x412e12['call'](this,_0x1be1c2,_0x1b177b)||this;return _0x5b6682['_normalMatrix']=new _0x116386['a'](),_0x5b6682['_storeEffectOnSubMeshes']=!0x0,_0x5b6682;}return Object(_0xfcad27['d'])(_0x1037a6,_0x412e12),_0x1037a6['prototype']['getEffect']=function(){return this['_activeEffect'];},_0x1037a6['prototype']['isReady']=function(_0x55294c,_0x4524b0){return!!_0x55294c&&(!_0x55294c['subMeshes']||0x0===_0x55294c['subMeshes']['length']||this['isReadyForSubMesh'](_0x55294c,_0x55294c['subMeshes'][0x0],_0x4524b0));},_0x1037a6['prototype']['_isReadyForSubMesh']=function(_0x49ec5f){var _0x5cca0f=_0x49ec5f['_materialDefines'];return!(this['checkReadyOnEveryCall']||!_0x49ec5f['effect']||!_0x5cca0f||_0x5cca0f['_renderId']!==this['getScene']()['getRenderId']());},_0x1037a6['prototype']['bindOnlyWorldMatrix']=function(_0x3f820b){this['_activeEffect']['setMatrix']('world',_0x3f820b);},_0x1037a6['prototype']['bindOnlyNormalMatrix']=function(_0x590dd5){this['_activeEffect']['setMatrix']('normalMatrix',_0x590dd5);},_0x1037a6['prototype']['bind']=function(_0x1b02d4,_0x23fa43){_0x23fa43&&this['bindForSubMesh'](_0x1b02d4,_0x23fa43,_0x23fa43['subMeshes'][0x0]);},_0x1037a6['prototype']['_afterBind']=function(_0x2c9c3c,_0x275ef1){void 0x0===_0x275ef1&&(_0x275ef1=null),_0x412e12['prototype']['_afterBind']['call'](this,_0x2c9c3c),this['getScene']()['_cachedEffect']=_0x275ef1;},_0x1037a6['prototype']['_mustRebind']=function(_0x3be21a,_0x278f78,_0x2c9a38){return void 0x0===_0x2c9a38&&(_0x2c9a38=0x1),_0x3be21a['isCachedMaterialInvalid'](this,_0x278f78,_0x2c9a38);},_0x1037a6;}(_0xfa3f73(0x19)['a']);},function(_0x508938,_0x28ce59,_0x37629d){'use strict';_0x37629d['d'](_0x28ce59,'a',function(){return _0x3e2777;});var _0x134442=_0x37629d(0x1),_0x3e2777=function(_0x2bae05){function _0x5f5194(_0x59402e){var _0x1cc927=_0x2bae05['call'](this)||this;return _0x1cc927['_buffer']=_0x59402e,_0x1cc927;}return Object(_0x134442['d'])(_0x5f5194,_0x2bae05),Object['defineProperty'](_0x5f5194['prototype'],'underlyingResource',{'get':function(){return this['_buffer'];},'enumerable':!0x1,'configurable':!0x0}),_0x5f5194;}(_0x37629d(0x59)['a']);},function(_0x569c1d,_0x4dec0b,_0x1bfc1f){'use strict';_0x1bfc1f['d'](_0x4dec0b,'a',function(){return _0x42ad55;});var _0x42ad55=(function(){function _0x44b73e(){this['references']=0x0,this['capacity']=0x0,this['is32Bits']=!0x1;}return Object['defineProperty'](_0x44b73e['prototype'],'underlyingResource',{'get':function(){return null;},'enumerable':!0x1,'configurable':!0x0}),_0x44b73e;}());},function(_0x14f8c2,_0x4ef2f5,_0x385742){'use strict';_0x385742['d'](_0x4ef2f5,'a',function(){return _0x1d637d;});var _0x310010=_0x385742(0x40),_0x1d637d=(function(){function _0x72d15f(){}return _0x72d15f['GetPlanes']=function(_0x3956d7){for(var _0x36df7c=[],_0x56ac2e=0x0;_0x56ac2e<0x6;_0x56ac2e++)_0x36df7c['push'](new _0x310010['a'](0x0,0x0,0x0,0x0));return _0x72d15f['GetPlanesToRef'](_0x3956d7,_0x36df7c),_0x36df7c;},_0x72d15f['GetNearPlaneToRef']=function(_0x5e3d16,_0x3f649f){var _0x4749b6=_0x5e3d16['m'];_0x3f649f['normal']['x']=_0x4749b6[0x3]+_0x4749b6[0x2],_0x3f649f['normal']['y']=_0x4749b6[0x7]+_0x4749b6[0x6],_0x3f649f['normal']['z']=_0x4749b6[0xb]+_0x4749b6[0xa],_0x3f649f['d']=_0x4749b6[0xf]+_0x4749b6[0xe],_0x3f649f['normalize']();},_0x72d15f['GetFarPlaneToRef']=function(_0x5daf61,_0xebb480){var _0x293a43=_0x5daf61['m'];_0xebb480['normal']['x']=_0x293a43[0x3]-_0x293a43[0x2],_0xebb480['normal']['y']=_0x293a43[0x7]-_0x293a43[0x6],_0xebb480['normal']['z']=_0x293a43[0xb]-_0x293a43[0xa],_0xebb480['d']=_0x293a43[0xf]-_0x293a43[0xe],_0xebb480['normalize']();},_0x72d15f['GetLeftPlaneToRef']=function(_0x29cc4c,_0x5aa6aa){var _0x2eb493=_0x29cc4c['m'];_0x5aa6aa['normal']['x']=_0x2eb493[0x3]+_0x2eb493[0x0],_0x5aa6aa['normal']['y']=_0x2eb493[0x7]+_0x2eb493[0x4],_0x5aa6aa['normal']['z']=_0x2eb493[0xb]+_0x2eb493[0x8],_0x5aa6aa['d']=_0x2eb493[0xf]+_0x2eb493[0xc],_0x5aa6aa['normalize']();},_0x72d15f['GetRightPlaneToRef']=function(_0x3b8c87,_0x27fb64){var _0x8b8d4d=_0x3b8c87['m'];_0x27fb64['normal']['x']=_0x8b8d4d[0x3]-_0x8b8d4d[0x0],_0x27fb64['normal']['y']=_0x8b8d4d[0x7]-_0x8b8d4d[0x4],_0x27fb64['normal']['z']=_0x8b8d4d[0xb]-_0x8b8d4d[0x8],_0x27fb64['d']=_0x8b8d4d[0xf]-_0x8b8d4d[0xc],_0x27fb64['normalize']();},_0x72d15f['GetTopPlaneToRef']=function(_0x35f604,_0x231969){var _0x225975=_0x35f604['m'];_0x231969['normal']['x']=_0x225975[0x3]-_0x225975[0x1],_0x231969['normal']['y']=_0x225975[0x7]-_0x225975[0x5],_0x231969['normal']['z']=_0x225975[0xb]-_0x225975[0x9],_0x231969['d']=_0x225975[0xf]-_0x225975[0xd],_0x231969['normalize']();},_0x72d15f['GetBottomPlaneToRef']=function(_0x59257b,_0x4c9f61){var _0x31f998=_0x59257b['m'];_0x4c9f61['normal']['x']=_0x31f998[0x3]+_0x31f998[0x1],_0x4c9f61['normal']['y']=_0x31f998[0x7]+_0x31f998[0x5],_0x4c9f61['normal']['z']=_0x31f998[0xb]+_0x31f998[0x9],_0x4c9f61['d']=_0x31f998[0xf]+_0x31f998[0xd],_0x4c9f61['normalize']();},_0x72d15f['GetPlanesToRef']=function(_0x3752ec,_0x543e4e){_0x72d15f['GetNearPlaneToRef'](_0x3752ec,_0x543e4e[0x0]),_0x72d15f['GetFarPlaneToRef'](_0x3752ec,_0x543e4e[0x1]),_0x72d15f['GetLeftPlaneToRef'](_0x3752ec,_0x543e4e[0x2]),_0x72d15f['GetRightPlaneToRef'](_0x3752ec,_0x543e4e[0x3]),_0x72d15f['GetTopPlaneToRef'](_0x3752ec,_0x543e4e[0x4]),_0x72d15f['GetBottomPlaneToRef'](_0x3752ec,_0x543e4e[0x5]);},_0x72d15f;}());},function(_0x56365a,_0x479208,_0x51026e){'use strict';_0x51026e['d'](_0x479208,'a',function(){return _0x4d0478;});var _0x56e69a=_0x51026e(0x2),_0x4d0478=(function(){function _0x4828ce(){this['hoverCursor']='',this['actions']=new Array(),this['isRecursive']=!0x1;}return Object['defineProperty'](_0x4828ce,'HasTriggers',{'get':function(){for(var _0x1e5308 in _0x4828ce['Triggers'])if(_0x4828ce['Triggers']['hasOwnProperty'](_0x1e5308))return!0x0;return!0x1;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4828ce,'HasPickTriggers',{'get':function(){for(var _0x2059fa in _0x4828ce['Triggers'])if(_0x4828ce['Triggers']['hasOwnProperty'](_0x2059fa)){var _0x372097=parseInt(_0x2059fa);if(_0x372097>=_0x56e69a['a']['ACTION_OnPickTrigger']&&_0x372097<=_0x56e69a['a']['ACTION_OnPickUpTrigger'])return!0x0;}return!0x1;},'enumerable':!0x1,'configurable':!0x0}),_0x4828ce['HasSpecificTrigger']=function(_0x11690f){for(var _0xa0b7e8 in _0x4828ce['Triggers']){if(_0x4828ce['Triggers']['hasOwnProperty'](_0xa0b7e8)){if(parseInt(_0xa0b7e8)===_0x11690f)return!0x0;}}return!0x1;},_0x4828ce['Triggers']={},_0x4828ce;}());},function(_0x502fd1,_0x47484c,_0x2b2a91){'use strict';_0x2b2a91['d'](_0x47484c,'a',function(){return _0x91ecad;});var _0x3e12b7=_0x2b2a91(0x1),_0x4c47b3=_0x2b2a91(0x19),_0x526b48=_0x2b2a91(0x3),_0x2f838d=_0x2b2a91(0x13),_0x45d5e7=_0x2b2a91(0xf),_0x91ecad=(function(){function _0x49090d(_0x5ace10){this['_texture']=null,this['diffuseBlendLevel']=0x1,this['roughnessBlendLevel']=0x1,this['bumpLevel']=0x1,this['_normalBlendMethod']=_0x4c47b3['a']['MATERIAL_NORMALBLENDMETHOD_WHITEOUT'],this['_isEnabled']=!0x1,this['isEnabled']=!0x1,this['_internalMarkAllSubMeshesAsTexturesDirty']=_0x5ace10;}return _0x49090d['prototype']['_markAllSubMeshesAsTexturesDirty']=function(){this['_internalMarkAllSubMeshesAsTexturesDirty']();},_0x49090d['prototype']['isReadyForSubMesh']=function(_0x1e76a5,_0x4c1a7a){var _0x36d906=_0x4c1a7a['getEngine']();return!(_0x1e76a5['_areTexturesDirty']&&_0x4c1a7a['texturesEnabled']&&_0x36d906['getCaps']()['standardDerivatives']&&this['_texture']&&_0x2f838d['a']['DetailTextureEnabled']&&!this['_texture']['isReady']());},_0x49090d['prototype']['prepareDefines']=function(_0x530877,_0x59dcbd){if(this['_isEnabled']){_0x530877['DETAIL_NORMALBLENDMETHOD']=this['_normalBlendMethod'];var _0x3ecc20=_0x59dcbd['getEngine']();_0x530877['_areTexturesDirty']&&(_0x3ecc20['getCaps']()['standardDerivatives']&&this['_texture']&&_0x2f838d['a']['DetailTextureEnabled']&&this['_isEnabled']?(_0x45d5e7['a']['PrepareDefinesForMergedUV'](this['_texture'],_0x530877,'DETAIL'),_0x530877['DETAIL_NORMALBLENDMETHOD']=this['_normalBlendMethod']):_0x530877['DETAIL']=!0x1);}else _0x530877['DETAIL']=!0x1;},_0x49090d['prototype']['bindForSubMesh']=function(_0x27bfe8,_0x2ca741,_0x2761d1){this['_isEnabled']&&(_0x27bfe8['useUbo']&&_0x2761d1&&_0x27bfe8['isSync']||this['_texture']&&_0x2f838d['a']['DetailTextureEnabled']&&(_0x27bfe8['updateFloat4']('vDetailInfos',this['_texture']['coordinatesIndex'],this['diffuseBlendLevel'],this['bumpLevel'],this['roughnessBlendLevel']),_0x45d5e7['a']['BindTextureMatrix'](this['_texture'],_0x27bfe8,'detail')),_0x2ca741['texturesEnabled']&&this['_texture']&&_0x2f838d['a']['DetailTextureEnabled']&&_0x27bfe8['setTexture']('detailSampler',this['_texture']));},_0x49090d['prototype']['hasTexture']=function(_0x3f5cbe){return this['_texture']===_0x3f5cbe;},_0x49090d['prototype']['getActiveTextures']=function(_0x4a487d){this['_texture']&&_0x4a487d['push'](this['_texture']);},_0x49090d['prototype']['getAnimatables']=function(_0x499d30){this['_texture']&&this['_texture']['animations']&&this['_texture']['animations']['length']>0x0&&_0x499d30['push'](this['_texture']);},_0x49090d['prototype']['dispose']=function(_0x161355){var _0x54259b;_0x161355&&(null===(_0x54259b=this['_texture'])||void 0x0===_0x54259b||_0x54259b['dispose']());},_0x49090d['prototype']['getClassName']=function(){return'DetailMap';},_0x49090d['AddUniforms']=function(_0x13dc79){_0x13dc79['push']('vDetailInfos');},_0x49090d['AddSamplers']=function(_0x402d9f){_0x402d9f['push']('detailSampler');},_0x49090d['PrepareUniformBuffer']=function(_0x506b9e){_0x506b9e['addUniform']('vDetailInfos',0x4),_0x506b9e['addUniform']('detailMatrix',0x10);},_0x49090d['prototype']['copyTo']=function(_0x14d384){_0x526b48['a']['Clone'](function(){return _0x14d384;},this);},_0x49090d['prototype']['serialize']=function(){return _0x526b48['a']['Serialize'](this);},_0x49090d['prototype']['parse']=function(_0x3956b0,_0x1eaa5f,_0x1981a5){var _0x466e3e=this;_0x526b48['a']['Parse'](function(){return _0x466e3e;},_0x3956b0,_0x1eaa5f,_0x1981a5);},Object(_0x3e12b7['c'])([Object(_0x526b48['m'])('detailTexture'),Object(_0x526b48['b'])('_markAllSubMeshesAsTexturesDirty')],_0x49090d['prototype'],'texture',void 0x0),Object(_0x3e12b7['c'])([Object(_0x526b48['c'])()],_0x49090d['prototype'],'diffuseBlendLevel',void 0x0),Object(_0x3e12b7['c'])([Object(_0x526b48['c'])()],_0x49090d['prototype'],'roughnessBlendLevel',void 0x0),Object(_0x3e12b7['c'])([Object(_0x526b48['c'])()],_0x49090d['prototype'],'bumpLevel',void 0x0),Object(_0x3e12b7['c'])([Object(_0x526b48['c'])(),Object(_0x526b48['b'])('_markAllSubMeshesAsTexturesDirty')],_0x49090d['prototype'],'normalBlendMethod',void 0x0),Object(_0x3e12b7['c'])([Object(_0x526b48['c'])(),Object(_0x526b48['b'])('_markAllSubMeshesAsTexturesDirty')],_0x49090d['prototype'],'isEnabled',void 0x0),_0x49090d;}());},function(_0x4e0730,_0x3115e6,_0x2c0c19){'use strict';var _0x2f999d='morphTargetsVertexGlobalDeclaration',_0x3d6bba='#ifdef\x20MORPHTARGETS\x0auniform\x20float\x20morphTargetInfluences[NUM_MORPH_INFLUENCERS];\x0a#endif';_0x2c0c19(0x5)['a']['IncludesShadersStore'][_0x2f999d]=_0x3d6bba;},function(_0x1e7323,_0x23f3df,_0xeaf444){'use strict';var _0x44d2f1='morphTargetsVertexDeclaration',_0x5bbb1f='#ifdef\x20MORPHTARGETS\x0aattribute\x20vec3\x20position{X};\x0a#ifdef\x20MORPHTARGETS_NORMAL\x0aattribute\x20vec3\x20normal{X};\x0a#endif\x0a#ifdef\x20MORPHTARGETS_TANGENT\x0aattribute\x20vec3\x20tangent{X};\x0a#endif\x0a#ifdef\x20MORPHTARGETS_UV\x0aattribute\x20vec2\x20uv_{X};\x0a#endif\x0a#endif';_0xeaf444(0x5)['a']['IncludesShadersStore'][_0x44d2f1]=_0x5bbb1f;},function(_0x1fdccc,_0x236879,_0xd6ea5b){'use strict';_0xd6ea5b['d'](_0x236879,'a',function(){return _0x9fc8eb;});var _0x40b5a4=_0xd6ea5b(0x19),_0x2d77cf=_0xd6ea5b(0x4),_0x8ccaff=_0xd6ea5b(0x2),_0x9fc8eb=(function(){function _0x57f0fc(_0x46fba9){this['_vertexBuffers']={},this['_scene']=_0x46fba9;}return _0x57f0fc['prototype']['_prepareBuffers']=function(){if(!this['_vertexBuffers'][_0x2d77cf['b']['PositionKind']]){var _0x20b61a=[];_0x20b61a['push'](0x1,0x1),_0x20b61a['push'](-0x1,0x1),_0x20b61a['push'](-0x1,-0x1),_0x20b61a['push'](0x1,-0x1),this['_vertexBuffers'][_0x2d77cf['b']['PositionKind']]=new _0x2d77cf['b'](this['_scene']['getEngine'](),_0x20b61a,_0x2d77cf['b']['PositionKind'],!0x1,!0x1,0x2),this['_buildIndexBuffer']();}},_0x57f0fc['prototype']['_buildIndexBuffer']=function(){var _0x8ae2b3=[];_0x8ae2b3['push'](0x0),_0x8ae2b3['push'](0x1),_0x8ae2b3['push'](0x2),_0x8ae2b3['push'](0x0),_0x8ae2b3['push'](0x2),_0x8ae2b3['push'](0x3),this['_indexBuffer']=this['_scene']['getEngine']()['createIndexBuffer'](_0x8ae2b3);},_0x57f0fc['prototype']['_rebuild']=function(){var _0x4d001c=this['_vertexBuffers'][_0x2d77cf['b']['PositionKind']];_0x4d001c&&(_0x4d001c['_rebuild'](),this['_buildIndexBuffer']());},_0x57f0fc['prototype']['_prepareFrame']=function(_0x26bf82,_0x4fd54b){void 0x0===_0x26bf82&&(_0x26bf82=null),void 0x0===_0x4fd54b&&(_0x4fd54b=null);var _0x47fe98=this['_scene']['activeCamera'];return!!_0x47fe98&&(!(!(_0x4fd54b=_0x4fd54b||_0x47fe98['_postProcesses']['filter'](function(_0x27a223){return null!=_0x27a223;}))||0x0===_0x4fd54b['length']||!this['_scene']['postProcessesEnabled'])&&(_0x4fd54b[0x0]['activate'](_0x47fe98,_0x26bf82,null!=_0x4fd54b),!0x0));},_0x57f0fc['prototype']['directRender']=function(_0x423260,_0x213495,_0x5e9588,_0xcef168,_0x4bc11c,_0x2d2391){void 0x0===_0x213495&&(_0x213495=null),void 0x0===_0x5e9588&&(_0x5e9588=!0x1),void 0x0===_0xcef168&&(_0xcef168=0x0),void 0x0===_0x4bc11c&&(_0x4bc11c=0x0),void 0x0===_0x2d2391&&(_0x2d2391=!0x1);for(var _0x4e316e=this['_scene']['getEngine'](),_0x1e7725=0x0;_0x1e7725<_0x423260['length'];_0x1e7725++){_0x1e7725<_0x423260['length']-0x1?_0x423260[_0x1e7725+0x1]['activate'](this['_scene']['activeCamera'],_0x213495):_0x213495?_0x4e316e['bindFramebuffer'](_0x213495,_0xcef168,void 0x0,void 0x0,_0x5e9588,_0x4bc11c):_0x2d2391||_0x4e316e['restoreDefaultFramebuffer']();var _0x45829a=_0x423260[_0x1e7725],_0x132da7=_0x45829a['apply']();_0x132da7&&(_0x45829a['onBeforeRenderObservable']['notifyObservers'](_0x132da7),this['_prepareBuffers'](),_0x4e316e['bindBuffers'](this['_vertexBuffers'],this['_indexBuffer'],_0x132da7),_0x4e316e['drawElementsType'](_0x40b5a4['a']['TriangleFillMode'],0x0,0x6),_0x45829a['onAfterRenderObservable']['notifyObservers'](_0x132da7));}_0x4e316e['setDepthBuffer'](!0x0),_0x4e316e['setDepthWrite'](!0x0);},_0x57f0fc['prototype']['_finalizeFrame']=function(_0x39d3d7,_0x52ee2f,_0x5ab196,_0x2ae4f1,_0x98ae16){void 0x0===_0x98ae16&&(_0x98ae16=!0x1);var _0x4536f0=this['_scene']['activeCamera'];if(_0x4536f0&&0x0!==(_0x2ae4f1=_0x2ae4f1||_0x4536f0['_postProcesses']['filter'](function(_0x257b07){return null!=_0x257b07;}))['length']&&this['_scene']['postProcessesEnabled']){for(var _0x996c54=this['_scene']['getEngine'](),_0x38a2e2=0x0,_0x4169f2=_0x2ae4f1['length'];_0x38a2e2<_0x4169f2;_0x38a2e2++){var _0x4d3c6b=_0x2ae4f1[_0x38a2e2];if(_0x38a2e2<_0x4169f2-0x1?_0x4d3c6b['_outputTexture']=_0x2ae4f1[_0x38a2e2+0x1]['activate'](_0x4536f0,_0x52ee2f):_0x52ee2f?(_0x996c54['bindFramebuffer'](_0x52ee2f,_0x5ab196,void 0x0,void 0x0,_0x98ae16),_0x4d3c6b['_outputTexture']=_0x52ee2f):(_0x996c54['restoreDefaultFramebuffer'](),_0x4d3c6b['_outputTexture']=null),_0x39d3d7)break;var _0x4652b3=_0x4d3c6b['apply']();_0x4652b3&&(_0x4d3c6b['onBeforeRenderObservable']['notifyObservers'](_0x4652b3),this['_prepareBuffers'](),_0x996c54['bindBuffers'](this['_vertexBuffers'],this['_indexBuffer'],_0x4652b3),_0x996c54['drawElementsType'](_0x40b5a4['a']['TriangleFillMode'],0x0,0x6),_0x4d3c6b['onAfterRenderObservable']['notifyObservers'](_0x4652b3));}_0x996c54['setDepthBuffer'](!0x0),_0x996c54['setDepthWrite'](!0x0),_0x996c54['setAlphaMode'](_0x8ccaff['a']['ALPHA_DISABLE']);}},_0x57f0fc['prototype']['dispose']=function(){var _0x2530a3=this['_vertexBuffers'][_0x2d77cf['b']['PositionKind']];_0x2530a3&&(_0x2530a3['dispose'](),this['_vertexBuffers'][_0x2d77cf['b']['PositionKind']]=null),this['_indexBuffer']&&(this['_scene']['getEngine']()['_releaseBuffer'](this['_indexBuffer']),this['_indexBuffer']=null);},_0x57f0fc;}());},function(_0x314656,_0x2b4c02,_0x5516a2){'use strict';_0x5516a2['d'](_0x2b4c02,'a',function(){return _0x4009d8;}),_0x5516a2['d'](_0x2b4c02,'b',function(){return _0x2af08b;});var _0x7dd0ba=_0x5516a2(0x94),_0x4009d8=function(){},_0x2af08b=(function(){function _0x3afbc2(_0x1a2232){this['_useSceneAutoClearSetup']=!0x1,this['_renderingGroups']=new Array(),this['_autoClearDepthStencil']={},this['_customOpaqueSortCompareFn']={},this['_customAlphaTestSortCompareFn']={},this['_customTransparentSortCompareFn']={},this['_renderingGroupInfo']=new _0x4009d8(),this['_scene']=_0x1a2232;for(var _0x25432e=_0x3afbc2['MIN_RENDERINGGROUPS'];_0x25432e<_0x3afbc2['MAX_RENDERINGGROUPS'];_0x25432e++)this['_autoClearDepthStencil'][_0x25432e]={'autoClear':!0x0,'depth':!0x0,'stencil':!0x0};}return _0x3afbc2['prototype']['_clearDepthStencilBuffer']=function(_0x9f1e23,_0x52592d){void 0x0===_0x9f1e23&&(_0x9f1e23=!0x0),void 0x0===_0x52592d&&(_0x52592d=!0x0),this['_depthStencilBufferAlreadyCleaned']||(this['_scene']['getEngine']()['clear'](null,!0x1,_0x9f1e23,_0x52592d),this['_depthStencilBufferAlreadyCleaned']=!0x0);},_0x3afbc2['prototype']['render']=function(_0x142de8,_0x540617,_0x941fbb,_0x5aeed0){var _0x46b19f=this['_renderingGroupInfo'];if(_0x46b19f['scene']=this['_scene'],_0x46b19f['camera']=this['_scene']['activeCamera'],this['_scene']['spriteManagers']&&_0x5aeed0)for(var _0xef5424=0x0;_0xef54240x3?0x0:_0x1fd1ce,_0x3bbac1);var _0x4d3104=_0x1d4471['a']['CreateRibbon'](_0x3e96e0,{'pathArray':_0x10865c,'closeArray':_0x12dfaa,'closePath':_0x314515,'updatable':_0x65e27,'sideOrientation':_0x46fa76,'invertUV':_0x41eb98,'frontUVs':_0x397dd6||void 0x0,'backUVs':_0x22f290||void 0x0},_0x51df56);return _0x4d3104['_creationDataStorage']['pathArray']=_0x10865c,_0x4d3104['_creationDataStorage']['path3D']=_0x38a743,_0x4d3104['_creationDataStorage']['cap']=_0x1fd1ce,_0x4d3104;},_0x2948ff;}());},function(_0x1558d2,_0x3b3db4,_0x18a95d){'use strict';_0x18a95d['d'](_0x3b3db4,'b',function(){return _0x5dbd66;}),_0x18a95d['d'](_0x3b3db4,'a',function(){return _0x6f6a92;});var _0x24adf0=_0x18a95d(0x1),_0x4a54ea=_0x18a95d(0x9),_0x5734d3=_0x18a95d(0x4),_0x3da502=_0x18a95d(0x7),_0xab1d01=_0x18a95d(0x97),_0x2e7cdd=_0x18a95d(0x19),_0x1fb329=_0x18a95d(0x49),_0xd71c18=_0x18a95d(0xf),_0x5dbd66=(_0x18a95d(0xa6),_0x18a95d(0xa7),function(_0x496551){function _0x329aff(_0x2cc015,_0x2c415f,_0x35d021,_0x3e1298,_0x4369b3,_0x4d76b0,_0x1dbf49){void 0x0===_0x2c415f&&(_0x2c415f=null),void 0x0===_0x35d021&&(_0x35d021=null),void 0x0===_0x3e1298&&(_0x3e1298=null);var _0xa83df1=_0x496551['call'](this,_0x2cc015,_0x2c415f,_0x35d021,_0x3e1298,_0x4369b3)||this;_0xa83df1['useVertexColor']=_0x4d76b0,_0xa83df1['useVertexAlpha']=_0x1dbf49,_0xa83df1['color']=new _0x4a54ea['a'](0x1,0x1,0x1),_0xa83df1['alpha']=0x1,_0x3e1298&&(_0xa83df1['color']=_0x3e1298['color']['clone'](),_0xa83df1['alpha']=_0x3e1298['alpha'],_0xa83df1['useVertexColor']=_0x3e1298['useVertexColor'],_0xa83df1['useVertexAlpha']=_0x3e1298['useVertexAlpha']),_0xa83df1['intersectionThreshold']=0.1;var _0x3d7775={'attributes':[_0x5734d3['b']['PositionKind'],'world0','world1','world2','world3'],'uniforms':['vClipPlane','vClipPlane2','vClipPlane3','vClipPlane4','vClipPlane5','vClipPlane6','world','viewProjection'],'needAlphaBlending':!0x0,'defines':[]};return!0x1===_0x1dbf49&&(_0x3d7775['needAlphaBlending']=!0x1),_0x4d76b0?(_0x3d7775['defines']['push']('#define\x20VERTEXCOLOR'),_0x3d7775['attributes']['push'](_0x5734d3['b']['ColorKind'])):(_0x3d7775['uniforms']['push']('color'),_0xa83df1['color4']=new _0x4a54ea['b']()),_0xa83df1['_colorShader']=new _0x1fb329['a']('colorShader',_0xa83df1['getScene'](),'color',_0x3d7775),_0xa83df1;}return Object(_0x24adf0['d'])(_0x329aff,_0x496551),_0x329aff['prototype']['_addClipPlaneDefine']=function(_0x4ed2c3){var _0x268a4b='#define\x20'+_0x4ed2c3;-0x1===this['_colorShader']['options']['defines']['indexOf'](_0x268a4b)&&this['_colorShader']['options']['defines']['push'](_0x268a4b);},_0x329aff['prototype']['_removeClipPlaneDefine']=function(_0x547bbc){var _0x1b3ad8='#define\x20'+_0x547bbc,_0x191f68=this['_colorShader']['options']['defines']['indexOf'](_0x1b3ad8);-0x1!==_0x191f68&&this['_colorShader']['options']['defines']['splice'](_0x191f68,0x1);},_0x329aff['prototype']['isReady']=function(){var _0x57d58a=this['getScene']();return _0x57d58a['clipPlane']?this['_addClipPlaneDefine']('CLIPPLANE'):this['_removeClipPlaneDefine']('CLIPPLANE'),_0x57d58a['clipPlane2']?this['_addClipPlaneDefine']('CLIPPLANE2'):this['_removeClipPlaneDefine']('CLIPPLANE2'),_0x57d58a['clipPlane3']?this['_addClipPlaneDefine']('CLIPPLANE3'):this['_removeClipPlaneDefine']('CLIPPLANE3'),_0x57d58a['clipPlane4']?this['_addClipPlaneDefine']('CLIPPLANE4'):this['_removeClipPlaneDefine']('CLIPPLANE4'),_0x57d58a['clipPlane5']?this['_addClipPlaneDefine']('CLIPPLANE5'):this['_removeClipPlaneDefine']('CLIPPLANE5'),_0x57d58a['clipPlane6']?this['_addClipPlaneDefine']('CLIPPLANE6'):this['_removeClipPlaneDefine']('CLIPPLANE6'),!!this['_colorShader']['isReady'](this)&&_0x496551['prototype']['isReady']['call'](this);},_0x329aff['prototype']['getClassName']=function(){return'LinesMesh';},Object['defineProperty'](_0x329aff['prototype'],'material',{'get':function(){return this['_colorShader'];},'set':function(_0x455086){},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x329aff['prototype'],'checkCollisions',{'get':function(){return!0x1;},'enumerable':!0x1,'configurable':!0x0}),_0x329aff['prototype']['_bind']=function(_0x131721,_0x257b7f,_0x59f4c8){if(!this['_geometry'])return this;var _0x4851ac=this['_colorShader']['getEffect'](),_0x2d8b9e=this['isUnIndexed']?null:this['_geometry']['getIndexBuffer']();if(this['_geometry']['_bind'](_0x4851ac,_0x2d8b9e),!this['useVertexColor']){var _0xaafe2c=this['color'],_0x5707af=_0xaafe2c['r'],_0xf87800=_0xaafe2c['g'],_0x3f3d10=_0xaafe2c['b'];this['color4']['set'](_0x5707af,_0xf87800,_0x3f3d10,this['alpha']),this['_colorShader']['setColor4']('color',this['color4']);}return _0xd71c18['a']['BindClipPlane'](_0x4851ac,this['getScene']()),this;},_0x329aff['prototype']['_draw']=function(_0x3dcb97,_0x2e5f5a,_0x1f3534){if(!this['_geometry']||!this['_geometry']['getVertexBuffers']()||!this['_unIndexed']&&!this['_geometry']['getIndexBuffer']())return this;var _0x1e9d67=this['getScene']()['getEngine']();return this['_unIndexed']?_0x1e9d67['drawArraysType'](_0x2e7cdd['a']['LineListDrawMode'],_0x3dcb97['verticesStart'],_0x3dcb97['verticesCount'],_0x1f3534):_0x1e9d67['drawElementsType'](_0x2e7cdd['a']['LineListDrawMode'],_0x3dcb97['indexStart'],_0x3dcb97['indexCount'],_0x1f3534),this;},_0x329aff['prototype']['dispose']=function(_0x4cb825){this['_colorShader']['dispose'](!0x1,!0x1,!0x0),_0x496551['prototype']['dispose']['call'](this,_0x4cb825);},_0x329aff['prototype']['clone']=function(_0x1ca40b,_0x5dbc13,_0x4a0ce6){return void 0x0===_0x5dbc13&&(_0x5dbc13=null),new _0x329aff(_0x1ca40b,this['getScene'](),_0x5dbc13,this,_0x4a0ce6);},_0x329aff['prototype']['createInstance']=function(_0x4e782a){return new _0x6f6a92(_0x4e782a,this);},_0x329aff;}(_0x3da502['a'])),_0x6f6a92=function(_0xa79588){function _0x151e38(_0x526235,_0x4ee584){var _0x44ce58=_0xa79588['call'](this,_0x526235,_0x4ee584)||this;return _0x44ce58['intersectionThreshold']=_0x4ee584['intersectionThreshold'],_0x44ce58;}return Object(_0x24adf0['d'])(_0x151e38,_0xa79588),_0x151e38['prototype']['getClassName']=function(){return'InstancedLinesMesh';},_0x151e38;}(_0xab1d01['a']);},function(_0x1e1dfd,_0x381c91,_0x1441f7){'use strict';_0x1441f7['r'](_0x381c91),_0x1441f7['d'](_0x381c91,'AxesViewer',function(){return _0x3829d3;}),_0x1441f7['d'](_0x381c91,'BoneAxesViewer',function(){return _0x1f989d;}),_0x1441f7['d'](_0x381c91,'DebugLayerTab',function(){return _0x4ea35d;}),_0x1441f7['d'](_0x381c91,'DebugLayer',function(){return _0x1ef09a;}),_0x1441f7['d'](_0x381c91,'PhysicsViewer',function(){return _0x557bf6;}),_0x1441f7['d'](_0x381c91,'RayHelper',function(){return _0x369a5c;}),_0x1441f7['d'](_0x381c91,'SkeletonViewer',function(){return _0x82d8d6;});var _0x4ea35d,_0x4d0504=_0x1441f7(0x0),_0x2e4e6a=_0x1441f7(0x1e),_0x1d9e57=_0x1441f7(0x4b),_0x1447d6=_0x1441f7(0x9),_0x3829d3=(function(){function _0x438e01(_0x10ae83,_0x3aba2e,_0x206d55,_0x2eb477,_0x4d74da,_0x4003c){if(void 0x0===_0x3aba2e&&(_0x3aba2e=0x1),void 0x0===_0x206d55&&(_0x206d55=0x2),this['_scaleLinesFactor']=0x4,this['_instanced']=!0x1,this['scene']=null,this['scaleLines']=0x1,this['scaleLines']=_0x3aba2e,!_0x2eb477){var _0x40c671=new _0x2e4e6a['a']('',_0x10ae83);_0x40c671['disableLighting']=!0x0,_0x40c671['emissiveColor']=_0x1447d6['a']['Red']()['scale'](0.5),_0x2eb477=_0x1d9e57['a']['_CreateArrow'](_0x10ae83,_0x40c671);}if(!_0x4d74da){var _0x49cbf5=new _0x2e4e6a['a']('',_0x10ae83);_0x49cbf5['disableLighting']=!0x0,_0x49cbf5['emissiveColor']=_0x1447d6['a']['Green']()['scale'](0.5),_0x4d74da=_0x1d9e57['a']['_CreateArrow'](_0x10ae83,_0x49cbf5);}if(!_0x4003c){var _0x4a66f2=new _0x2e4e6a['a']('',_0x10ae83);_0x4a66f2['disableLighting']=!0x0,_0x4a66f2['emissiveColor']=_0x1447d6['a']['Blue']()['scale'](0.5),_0x4003c=_0x1d9e57['a']['_CreateArrow'](_0x10ae83,_0x4a66f2);}this['_xAxis']=_0x2eb477,this['_xAxis']['scaling']['setAll'](this['scaleLines']*this['_scaleLinesFactor']),this['_yAxis']=_0x4d74da,this['_yAxis']['scaling']['setAll'](this['scaleLines']*this['_scaleLinesFactor']),this['_zAxis']=_0x4003c,this['_zAxis']['scaling']['setAll'](this['scaleLines']*this['_scaleLinesFactor']),null!=_0x206d55&&(_0x438e01['_SetRenderingGroupId'](this['_xAxis'],_0x206d55),_0x438e01['_SetRenderingGroupId'](this['_yAxis'],_0x206d55),_0x438e01['_SetRenderingGroupId'](this['_zAxis'],_0x206d55)),this['scene']=_0x10ae83,this['update'](new _0x4d0504['e'](),_0x4d0504['e']['Right'](),_0x4d0504['e']['Up'](),_0x4d0504['e']['Forward']());}return Object['defineProperty'](_0x438e01['prototype'],'xAxis',{'get':function(){return this['_xAxis'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x438e01['prototype'],'yAxis',{'get':function(){return this['_yAxis'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x438e01['prototype'],'zAxis',{'get':function(){return this['_zAxis'];},'enumerable':!0x1,'configurable':!0x0}),_0x438e01['prototype']['update']=function(_0x4ef4da,_0x457d4c,_0x3a904b,_0x19fb39){this['_xAxis']['position']['copyFrom'](_0x4ef4da),this['_xAxis']['setDirection'](_0x457d4c),this['_xAxis']['scaling']['setAll'](this['scaleLines']*this['_scaleLinesFactor']),this['_yAxis']['position']['copyFrom'](_0x4ef4da),this['_yAxis']['setDirection'](_0x3a904b),this['_yAxis']['scaling']['setAll'](this['scaleLines']*this['_scaleLinesFactor']),this['_zAxis']['position']['copyFrom'](_0x4ef4da),this['_zAxis']['setDirection'](_0x19fb39),this['_zAxis']['scaling']['setAll'](this['scaleLines']*this['_scaleLinesFactor']);},_0x438e01['prototype']['createInstance']=function(){var _0x4cf761=_0x1d9e57['a']['_CreateArrowInstance'](this['scene'],this['_xAxis']),_0x26df3d=_0x1d9e57['a']['_CreateArrowInstance'](this['scene'],this['_yAxis']),_0x251c76=_0x1d9e57['a']['_CreateArrowInstance'](this['scene'],this['_zAxis']),_0x4d65a5=new _0x438e01(this['scene'],this['scaleLines'],null,_0x4cf761,_0x26df3d,_0x251c76);return _0x4d65a5['_instanced']=!0x0,_0x4d65a5;},_0x438e01['prototype']['dispose']=function(){this['_xAxis']&&this['_xAxis']['dispose'](!0x1,!this['_instanced']),this['_yAxis']&&this['_yAxis']['dispose'](!0x1,!this['_instanced']),this['_zAxis']&&this['_zAxis']['dispose'](!0x1,!this['_instanced']),this['scene']=null;},_0x438e01['_SetRenderingGroupId']=function(_0x59a102,_0x4a5bd2){_0x59a102['getChildMeshes']()['forEach'](function(_0x48e176){_0x48e176['renderingGroupId']=_0x4a5bd2;});},_0x438e01;}()),_0x1849d1=_0x1441f7(0x1),_0x32cfad=_0x1441f7(0x17),_0x1f989d=function(_0x39422c){function _0x352547(_0x4dfcfd,_0x349e73,_0x42ce9d,_0xf7e640){void 0x0===_0xf7e640&&(_0xf7e640=0x1);var _0x28e126=_0x39422c['call'](this,_0x4dfcfd,_0xf7e640)||this;return _0x28e126['pos']=_0x4d0504['e']['Zero'](),_0x28e126['xaxis']=_0x4d0504['e']['Zero'](),_0x28e126['yaxis']=_0x4d0504['e']['Zero'](),_0x28e126['zaxis']=_0x4d0504['e']['Zero'](),_0x28e126['mesh']=_0x42ce9d,_0x28e126['bone']=_0x349e73,_0x28e126;}return Object(_0x1849d1['d'])(_0x352547,_0x39422c),_0x352547['prototype']['update']=function(){if(this['mesh']&&this['bone']){var _0xde70ed=this['bone'];_0xde70ed['_markAsDirtyAndCompose'](),_0xde70ed['getAbsolutePositionToRef'](this['mesh'],this['pos']),_0xde70ed['getDirectionToRef'](_0x32cfad['a']['X'],this['mesh'],this['xaxis']),_0xde70ed['getDirectionToRef'](_0x32cfad['a']['Y'],this['mesh'],this['yaxis']),_0xde70ed['getDirectionToRef'](_0x32cfad['a']['Z'],this['mesh'],this['zaxis']),_0x39422c['prototype']['update']['call'](this,this['pos'],this['xaxis'],this['yaxis'],this['zaxis']);}},_0x352547['prototype']['dispose']=function(){this['mesh']&&(this['mesh']=null,this['bone']=null,_0x39422c['prototype']['dispose']['call'](this));},_0x352547;}(_0x3829d3),_0x154add=_0x1441f7(0xc),_0x1bba75=_0x1441f7(0x6),_0x29d6ea=_0x1441f7(0x14),_0x1a24e6=_0x1441f7(0xd);Object['defineProperty'](_0x29d6ea['a']['prototype'],'debugLayer',{'get':function(){return this['_debugLayer']||(this['_debugLayer']=new _0x1ef09a(this)),this['_debugLayer'];},'enumerable':!0x0,'configurable':!0x0}),function(_0x17fdb6){_0x17fdb6[_0x17fdb6['Properties']=0x0]='Properties',_0x17fdb6[_0x17fdb6['Debug']=0x1]='Debug',_0x17fdb6[_0x17fdb6['Statistics']=0x2]='Statistics',_0x17fdb6[_0x17fdb6['Tools']=0x3]='Tools',_0x17fdb6[_0x17fdb6['Settings']=0x4]='Settings';}(_0x4ea35d||(_0x4ea35d={}));var _0x1ef09a=(function(){function _0x216c3b(_0x535c95){var _0x1086d9=this;this['BJSINSPECTOR']=this['_getGlobalInspector'](),this['_scene']=_0x535c95,this['_scene']['onDisposeObservable']['add'](function(){_0x1086d9['_scene']['_debugLayer']&&_0x1086d9['_scene']['_debugLayer']['hide']();});}return Object['defineProperty'](_0x216c3b['prototype'],'onPropertyChangedObservable',{'get':function(){return this['BJSINSPECTOR']&&this['BJSINSPECTOR']['Inspector']?this['BJSINSPECTOR']['Inspector']['OnPropertyChangedObservable']:(this['_onPropertyChangedObservable']||(this['_onPropertyChangedObservable']=new _0x1bba75['c']()),this['_onPropertyChangedObservable']);},'enumerable':!0x1,'configurable':!0x0}),_0x216c3b['prototype']['_createInspector']=function(_0x2f74a0){if(!this['isVisible']()){if(this['_onPropertyChangedObservable']){for(var _0x4b6185=0x0,_0x18f9fc=this['_onPropertyChangedObservable']['observers'];_0x4b6185<_0x18f9fc['length'];_0x4b6185++){var _0x38300b=_0x18f9fc[_0x4b6185];this['BJSINSPECTOR']['Inspector']['OnPropertyChangedObservable']['add'](_0x38300b);}this['_onPropertyChangedObservable']['clear'](),this['_onPropertyChangedObservable']=void 0x0;}var _0x1ddb58=Object(_0x1849d1['a'])({'overlay':!0x1,'showExplorer':!0x0,'showInspector':!0x0,'embedMode':!0x1,'handleResize':!0x0,'enablePopup':!0x0},_0x2f74a0);this['BJSINSPECTOR']=this['BJSINSPECTOR']||this['_getGlobalInspector'](),this['BJSINSPECTOR']['Inspector']['Show'](this['_scene'],_0x1ddb58);}},_0x216c3b['prototype']['select']=function(_0x43aae4,_0x37c65b){this['BJSINSPECTOR']&&(_0x37c65b&&('[object\x20String]'==Object['prototype']['toString']['call'](_0x37c65b)?this['BJSINSPECTOR']['Inspector']['MarkLineContainerTitleForHighlighting'](_0x37c65b):this['BJSINSPECTOR']['Inspector']['MarkMultipleLineContainerTitlesForHighlighting'](_0x37c65b)),this['BJSINSPECTOR']['Inspector']['OnSelectionChangeObservable']['notifyObservers'](_0x43aae4));},_0x216c3b['prototype']['_getGlobalInspector']=function(){return'undefined'!=typeof INSPECTOR?INSPECTOR:'undefined'!=typeof BABYLON&&void 0x0!==BABYLON['Inspector']?BABYLON:void 0x0;},_0x216c3b['prototype']['isVisible']=function(){return this['BJSINSPECTOR']&&this['BJSINSPECTOR']['Inspector']['IsVisible'];},_0x216c3b['prototype']['hide']=function(){this['BJSINSPECTOR']&&this['BJSINSPECTOR']['Inspector']['Hide']();},_0x216c3b['prototype']['setAsActiveScene']=function(){this['BJSINSPECTOR']&&this['BJSINSPECTOR']['Inspector']['_SetNewScene'](this['_scene']);},_0x216c3b['prototype']['show']=function(_0x215c9b){var _0x41f32e=this;return new Promise(function(_0x386e3f,_0x20fe51){if(void 0x0===_0x41f32e['BJSINSPECTOR']){var _0x428bcf=_0x215c9b&&_0x215c9b['inspectorURL']?_0x215c9b['inspectorURL']:_0x216c3b['InspectorURL'];_0x154add['b']['LoadScript'](_0x428bcf,function(){_0x41f32e['_createInspector'](_0x215c9b),_0x386e3f(_0x41f32e);});}else _0x41f32e['_createInspector'](_0x215c9b),_0x386e3f(_0x41f32e);});},_0x216c3b['InspectorURL']='https://unpkg.com/babylonjs-inspector@'+_0x1a24e6['a']['Version']+'/babylon.inspector.bundle.js',_0x216c3b;}()),_0xb21d98=_0x1441f7(0x7),_0x5dd832=_0x1441f7(0x3f),_0x1a2742=_0x1441f7(0x2d),_0x311229=_0x1441f7(0x16),_0x204eb4=_0x1441f7(0x20),_0x21852a=_0x1441f7(0x24),_0x166656=_0x1441f7(0x35),_0x557bf6=(function(){function _0xb6ab46(_0x124313){this['_impostors']=[],this['_meshes']=[],this['_numMeshes']=0x0,this['_debugMeshMeshes']=new Array(),this['_scene']=_0x124313||_0x311229['a']['LastCreatedScene'];var _0x266dab=this['_scene']['getPhysicsEngine']();_0x266dab&&(this['_physicsEnginePlugin']=_0x266dab['getPhysicsPlugin']()),this['_utilityLayer']=new _0x21852a['a'](this['_scene'],!0x1),this['_utilityLayer']['pickUtilitySceneFirst']=!0x1,this['_utilityLayer']['utilityLayerScene']['autoClearDepthAndStencil']=!0x0;}return _0xb6ab46['prototype']['_updateDebugMeshes']=function(){for(var _0x43ab73=this['_physicsEnginePlugin'],_0x2a06f7=0x0;_0x2a06f7-0x1&&this['_debugMeshMeshes']['splice'](_0x5ce7aa,0x1),this['_numMeshes']--,this['_numMeshes']>0x0?(this['_meshes'][_0x212a28]=this['_meshes'][this['_numMeshes']],this['_impostors'][_0x212a28]=this['_impostors'][this['_numMeshes']],this['_meshes'][this['_numMeshes']]=null,this['_impostors'][this['_numMeshes']]=null):(this['_meshes'][0x0]=null,this['_impostors'][0x0]=null),_0x30673b=!0x0;break;}_0x30673b&&0x0===this['_numMeshes']&&this['_scene']['unregisterBeforeRender'](this['_renderFunction']);}},_0xb6ab46['prototype']['_getDebugMaterial']=function(_0x3a4e3b){return this['_debugMaterial']||(this['_debugMaterial']=new _0x2e4e6a['a']('',_0x3a4e3b),this['_debugMaterial']['wireframe']=!0x0,this['_debugMaterial']['emissiveColor']=_0x1447d6['a']['White'](),this['_debugMaterial']['disableLighting']=!0x0),this['_debugMaterial'];},_0xb6ab46['prototype']['_getDebugBoxMesh']=function(_0x2614cb){return this['_debugBoxMesh']||(this['_debugBoxMesh']=_0x5dd832['a']['CreateBox']('physicsBodyBoxViewMesh',{'size':0x1},_0x2614cb),this['_debugBoxMesh']['rotationQuaternion']=_0x4d0504['b']['Identity'](),this['_debugBoxMesh']['material']=this['_getDebugMaterial'](_0x2614cb),this['_debugBoxMesh']['setEnabled'](!0x1)),this['_debugBoxMesh']['createInstance']('physicsBodyBoxViewInstance');},_0xb6ab46['prototype']['_getDebugSphereMesh']=function(_0x5aa9ff){return this['_debugSphereMesh']||(this['_debugSphereMesh']=_0x1a2742['a']['CreateSphere']('physicsBodySphereViewMesh',{'diameter':0x1},_0x5aa9ff),this['_debugSphereMesh']['rotationQuaternion']=_0x4d0504['b']['Identity'](),this['_debugSphereMesh']['material']=this['_getDebugMaterial'](_0x5aa9ff),this['_debugSphereMesh']['setEnabled'](!0x1)),this['_debugSphereMesh']['createInstance']('physicsBodyBoxViewInstance');},_0xb6ab46['prototype']['_getDebugCylinderMesh']=function(_0x1370b0){return this['_debugCylinderMesh']||(this['_debugCylinderMesh']=_0x166656['a']['CreateCylinder']('physicsBodyCylinderViewMesh',{'diameterTop':0x1,'diameterBottom':0x1,'height':0x1},_0x1370b0),this['_debugCylinderMesh']['rotationQuaternion']=_0x4d0504['b']['Identity'](),this['_debugCylinderMesh']['material']=this['_getDebugMaterial'](_0x1370b0),this['_debugCylinderMesh']['setEnabled'](!0x1)),this['_debugCylinderMesh']['createInstance']('physicsBodyBoxViewInstance');},_0xb6ab46['prototype']['_getDebugMeshMesh']=function(_0x22432d,_0x4d6221){var _0x3655d3=new _0xb21d98['a'](_0x22432d['name'],_0x4d6221,null,_0x22432d);return _0x3655d3['position']=_0x4d0504['e']['Zero'](),_0x3655d3['setParent'](_0x22432d),_0x3655d3['material']=this['_getDebugMaterial'](_0x4d6221),this['_debugMeshMeshes']['push'](_0x3655d3),_0x3655d3;},_0xb6ab46['prototype']['_getDebugMesh']=function(_0x3b1832,_0x5145b2){var _0xe93e96=this;if(!this['_utilityLayer'])return null;if(_0x5145b2&&_0x5145b2['parent']&&_0x5145b2['parent']['physicsImpostor'])return null;var _0x3c2be5=null,_0x39fbcf=this['_utilityLayer']['utilityLayerScene'];switch(_0x3b1832['type']){case _0x204eb4['a']['BoxImpostor']:_0x3c2be5=this['_getDebugBoxMesh'](_0x39fbcf),_0x3b1832['getBoxSizeToRef'](_0x3c2be5['scaling']);break;case _0x204eb4['a']['SphereImpostor']:_0x3c2be5=this['_getDebugSphereMesh'](_0x39fbcf);var _0x1c10cd=_0x3b1832['getRadius']();_0x3c2be5['scaling']['x']=0x2*_0x1c10cd,_0x3c2be5['scaling']['y']=0x2*_0x1c10cd,_0x3c2be5['scaling']['z']=0x2*_0x1c10cd;break;case _0x204eb4['a']['MeshImpostor']:_0x5145b2&&(_0x3c2be5=this['_getDebugMeshMesh'](_0x5145b2,_0x39fbcf));break;case _0x204eb4['a']['NoImpostor']:if(_0x5145b2)_0x5145b2['getChildMeshes']()['filter'](function(_0x20d5a6){return _0x20d5a6['physicsImpostor']?0x1:0x0;})['forEach'](function(_0x3efc03){_0xe93e96['_getDebugBoxMesh'](_0x39fbcf)['parent']=_0x3efc03;});break;case _0x204eb4['a']['CylinderImpostor']:_0x3c2be5=this['_getDebugCylinderMesh'](_0x39fbcf);var _0x50cd73=_0x3b1832['object']['getBoundingInfo']();_0x3c2be5['scaling']['x']=_0x50cd73['boundingBox']['maximum']['x']-_0x50cd73['boundingBox']['minimum']['x'],_0x3c2be5['scaling']['y']=_0x50cd73['boundingBox']['maximum']['y']-_0x50cd73['boundingBox']['minimum']['y'],_0x3c2be5['scaling']['z']=_0x50cd73['boundingBox']['maximum']['z']-_0x50cd73['boundingBox']['minimum']['z'];}return _0x3c2be5;},_0xb6ab46['prototype']['dispose']=function(){for(var _0x1b1bc4=this['_numMeshes'],_0x56a8da=0x0;_0x56a8da<_0x1b1bc4;_0x56a8da++)this['hideImpostor'](this['_impostors'][0x0]);this['_debugBoxMesh']&&this['_debugBoxMesh']['dispose'](),this['_debugSphereMesh']&&this['_debugSphereMesh']['dispose'](),this['_debugCylinderMesh']&&this['_debugCylinderMesh']['dispose'](),this['_debugMaterial']&&this['_debugMaterial']['dispose'](),this['_impostors']['length']=0x0,this['_scene']=null,this['_physicsEnginePlugin']=null,this['_utilityLayer']&&(this['_utilityLayer']['dispose'](),this['_utilityLayer']=null);},_0xb6ab46;}()),_0x146c59=_0x1441f7(0x28),_0x369a5c=(function(){function _0x35d515(_0x5d86c0){this['ray']=_0x5d86c0;}return _0x35d515['CreateAndShow']=function(_0x38db0e,_0x10b87e,_0x51053d){var _0x64117f=new _0x35d515(_0x38db0e);return _0x64117f['show'](_0x10b87e,_0x51053d),_0x64117f;},_0x35d515['prototype']['show']=function(_0x2d803f,_0x2ca4a8){if(!this['_renderFunction']&&this['ray']){var _0x47a921=this['ray'];this['_renderFunction']=this['_render']['bind'](this),this['_scene']=_0x2d803f,this['_renderPoints']=[_0x47a921['origin'],_0x47a921['origin']['add'](_0x47a921['direction']['scale'](_0x47a921['length']))],this['_renderLine']=_0xb21d98['a']['CreateLines']('ray',this['_renderPoints'],_0x2d803f,!0x0),this['_renderLine']['isPickable']=!0x1,this['_renderFunction']&&this['_scene']['registerBeforeRender'](this['_renderFunction']);}_0x2ca4a8&&this['_renderLine']&&this['_renderLine']['color']['copyFrom'](_0x2ca4a8);},_0x35d515['prototype']['hide']=function(){this['_renderFunction']&&this['_scene']&&(this['_scene']['unregisterBeforeRender'](this['_renderFunction']),this['_scene']=null,this['_renderFunction']=null,this['_renderLine']&&(this['_renderLine']['dispose'](),this['_renderLine']=null),this['_renderPoints']=[]);},_0x35d515['prototype']['_render']=function(){var _0x2a4d2b=this['ray'];if(_0x2a4d2b){var _0x184977=this['_renderPoints'][0x1],_0x356f52=Math['min'](_0x2a4d2b['length'],0xf4240);_0x184977['copyFrom'](_0x2a4d2b['direction']),_0x184977['scaleInPlace'](_0x356f52),_0x184977['addInPlace'](_0x2a4d2b['origin']),this['_renderPoints'][0x0]['copyFrom'](_0x2a4d2b['origin']),_0xb21d98['a']['CreateLines']('ray',this['_renderPoints'],this['_scene'],!0x0,this['_renderLine']);}},_0x35d515['prototype']['attachToMesh']=function(_0x493b79,_0x139fe8,_0x224366,_0x4b5d24){var _0x2491a1=this;this['_attachedToMesh']=_0x493b79;var _0x1de030=this['ray'];_0x1de030&&(_0x1de030['direction']||(_0x1de030['direction']=_0x4d0504['e']['Zero']()),_0x1de030['origin']||(_0x1de030['origin']=_0x4d0504['e']['Zero']()),_0x4b5d24&&(_0x1de030['length']=_0x4b5d24),_0x224366||(_0x224366=_0x4d0504['e']['Zero']()),_0x139fe8||(_0x139fe8=new _0x4d0504['e'](0x0,0x0,-0x1)),this['_scene']||(this['_scene']=_0x493b79['getScene']()),this['_meshSpaceDirection']?(this['_meshSpaceDirection']['copyFrom'](_0x139fe8),this['_meshSpaceOrigin']['copyFrom'](_0x224366)):(this['_meshSpaceDirection']=_0x139fe8['clone'](),this['_meshSpaceOrigin']=_0x224366['clone']()),this['_onAfterRenderObserver']||(this['_onAfterRenderObserver']=this['_scene']['onBeforeRenderObservable']['add'](function(){return _0x2491a1['_updateToMesh']();}),this['_onAfterStepObserver']=this['_scene']['onAfterStepObservable']['add'](function(){return _0x2491a1['_updateToMesh']();})),this['_attachedToMesh']['computeWorldMatrix'](!0x0),this['_updateToMesh']());},_0x35d515['prototype']['detachFromMesh']=function(){this['_attachedToMesh']&&this['_scene']&&(this['_onAfterRenderObserver']&&(this['_scene']['onBeforeRenderObservable']['remove'](this['_onAfterRenderObserver']),this['_scene']['onAfterStepObservable']['remove'](this['_onAfterStepObserver'])),this['_attachedToMesh']=null,this['_onAfterRenderObserver']=null,this['_onAfterStepObserver']=null,this['_scene']=null);},_0x35d515['prototype']['_updateToMesh']=function(){var _0x59ba72=this['ray'];this['_attachedToMesh']&&_0x59ba72&&(this['_attachedToMesh']['_isDisposed']?this['detachFromMesh']():(this['_attachedToMesh']['getDirectionToRef'](this['_meshSpaceDirection'],_0x59ba72['direction']),_0x4d0504['e']['TransformCoordinatesToRef'](this['_meshSpaceOrigin'],this['_attachedToMesh']['getWorldMatrix'](),_0x59ba72['origin'])));},_0x35d515['prototype']['dispose']=function(){this['hide'](),this['detachFromMesh'](),this['ray']=null;},_0x35d515;}()),_0x22b2d7=_0x1441f7(0x19),_0x5bc610=_0x1441f7(0x49),_0x36b2de=_0x1441f7(0x3e),_0x13615a=_0x1441f7(0x4),_0x2f1175=_0x1441f7(0x5),_0x30edb4=_0x1441f7(0x61),_0x82d8d6=(function(){function _0x32d96a(_0x8291c2,_0x1aff43,_0xe00246,_0x9227a9,_0x7bd1ef,_0x247ff4){var _0x223ce0,_0xc9df22,_0x22b14c,_0x3b3f7a,_0x3d2a3b,_0x7b44a1,_0x4c4a04,_0x435692,_0x56bbd9,_0x59a6ca,_0x403954,_0x5a565e,_0x55393e,_0x32fcfb;void 0x0===_0x9227a9&&(_0x9227a9=!0x0),void 0x0===_0x7bd1ef&&(_0x7bd1ef=0x3),void 0x0===_0x247ff4&&(_0x247ff4={}),this['skeleton']=_0x8291c2,this['mesh']=_0x1aff43,this['autoUpdateBonesMatrices']=_0x9227a9,this['renderingGroupId']=_0x7bd1ef,this['options']=_0x247ff4,this['color']=_0x1447d6['a']['White'](),this['_debugLines']=new Array(),this['_localAxes']=null,this['_isEnabled']=!0x1,this['_obs']=null,this['_scene']=_0xe00246,this['_ready']=!0x1,_0x247ff4['pauseAnimations']=null===(_0x223ce0=_0x247ff4['pauseAnimations'])||void 0x0===_0x223ce0||_0x223ce0,_0x247ff4['returnToRest']=null!==(_0xc9df22=_0x247ff4['returnToRest'])&&void 0x0!==_0xc9df22&&_0xc9df22,_0x247ff4['displayMode']=null!==(_0x22b14c=_0x247ff4['displayMode'])&&void 0x0!==_0x22b14c?_0x22b14c:_0x32d96a['DISPLAY_LINES'],_0x247ff4['displayOptions']=null!==(_0x3b3f7a=_0x247ff4['displayOptions'])&&void 0x0!==_0x3b3f7a?_0x3b3f7a:{},_0x247ff4['displayOptions']['midStep']=null!==(_0x3d2a3b=_0x247ff4['displayOptions']['midStep'])&&void 0x0!==_0x3d2a3b?_0x3d2a3b:0.235,_0x247ff4['displayOptions']['midStepFactor']=null!==(_0x7b44a1=_0x247ff4['displayOptions']['midStepFactor'])&&void 0x0!==_0x7b44a1?_0x7b44a1:0.155,_0x247ff4['displayOptions']['sphereBaseSize']=null!==(_0x4c4a04=_0x247ff4['displayOptions']['sphereBaseSize'])&&void 0x0!==_0x4c4a04?_0x4c4a04:0.15,_0x247ff4['displayOptions']['sphereScaleUnit']=null!==(_0x435692=_0x247ff4['displayOptions']['sphereScaleUnit'])&&void 0x0!==_0x435692?_0x435692:0x2,_0x247ff4['displayOptions']['sphereFactor']=null!==(_0x56bbd9=_0x247ff4['displayOptions']['sphereFactor'])&&void 0x0!==_0x56bbd9?_0x56bbd9:0.865,_0x247ff4['displayOptions']['spurFollowsChild']=null!==(_0x59a6ca=_0x247ff4['displayOptions']['spurFollowsChild'])&&void 0x0!==_0x59a6ca&&_0x59a6ca,_0x247ff4['displayOptions']['showLocalAxes']=null!==(_0x403954=_0x247ff4['displayOptions']['showLocalAxes'])&&void 0x0!==_0x403954&&_0x403954,_0x247ff4['displayOptions']['localAxesSize']=null!==(_0x5a565e=_0x247ff4['displayOptions']['localAxesSize'])&&void 0x0!==_0x5a565e?_0x5a565e:0.075,_0x247ff4['computeBonesUsingShaders']=null===(_0x55393e=_0x247ff4['computeBonesUsingShaders'])||void 0x0===_0x55393e||_0x55393e,_0x247ff4['useAllBones']=null===(_0x32fcfb=_0x247ff4['useAllBones'])||void 0x0===_0x32fcfb||_0x32fcfb;var _0x4b1e11=_0x1aff43['getVerticesData'](_0x13615a['b']['MatricesIndicesKind']),_0xcbdce6=_0x1aff43['getVerticesData'](_0x13615a['b']['MatricesWeightsKind']);if(this['_boneIndices']=new Set(),!_0x247ff4['useAllBones']&&_0x4b1e11&&_0xcbdce6)for(var _0xee4df3=0x0;_0xee4df3<_0x4b1e11['length'];++_0xee4df3){var _0x49788c=_0x4b1e11[_0xee4df3];0x0!==_0xcbdce6[_0xee4df3]&&this['_boneIndices']['add'](_0x49788c);}this['_utilityLayer']=new _0x21852a['a'](this['_scene'],!0x1),this['_utilityLayer']['pickUtilitySceneFirst']=!0x1,this['_utilityLayer']['utilityLayerScene']['autoClearDepthAndStencil']=!0x0;var _0x298670=this['options']['displayMode']||0x0;_0x298670>_0x32d96a['DISPLAY_SPHERE_AND_SPURS']&&(_0x298670=_0x32d96a['DISPLAY_LINES']),this['displayMode']=_0x298670,this['update'](),this['_bindObs']();}return _0x32d96a['CreateBoneWeightShader']=function(_0xe307a5,_0x280c78){var _0x37ac7b,_0x41d211,_0x272800,_0x3132c5,_0x55cb0a,_0x13fac5,_0x34e260=_0xe307a5['skeleton'],_0x4a2f88=null!==(_0x37ac7b=_0xe307a5['colorBase'])&&void 0x0!==_0x37ac7b?_0x37ac7b:_0x1447d6['a']['Black'](),_0x345a4b=null!==(_0x41d211=_0xe307a5['colorZero'])&&void 0x0!==_0x41d211?_0x41d211:_0x1447d6['a']['Blue'](),_0x2ad665=null!==(_0x272800=_0xe307a5['colorQuarter'])&&void 0x0!==_0x272800?_0x272800:_0x1447d6['a']['Green'](),_0x446190=null!==(_0x3132c5=_0xe307a5['colorHalf'])&&void 0x0!==_0x3132c5?_0x3132c5:_0x1447d6['a']['Yellow'](),_0x35c868=null!==(_0x55cb0a=_0xe307a5['colorFull'])&&void 0x0!==_0x55cb0a?_0x55cb0a:_0x1447d6['a']['Red'](),_0xad8ed2=null!==(_0x13fac5=_0xe307a5['targetBoneIndex'])&&void 0x0!==_0x13fac5?_0x13fac5:0x0;_0x2f1175['a']['ShadersStore']['boneWeights:'+_0x34e260['name']+'VertexShader']='precision\x20highp\x20float;\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20attribute\x20vec3\x20position;\x0a\x20\x20\x20\x20\x20\x20\x20\x20attribute\x20vec2\x20uv;\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20uniform\x20mat4\x20view;\x0a\x20\x20\x20\x20\x20\x20\x20\x20uniform\x20mat4\x20projection;\x0a\x20\x20\x20\x20\x20\x20\x20\x20uniform\x20mat4\x20worldViewProjection;\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20#include\x0a\x20\x20\x20\x20\x20\x20\x20\x20#if\x20NUM_BONE_INFLUENCERS\x20==\x200\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20attribute\x20vec4\x20matricesIndices;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20attribute\x20vec4\x20matricesWeights;\x0a\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20#include\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20varying\x20vec3\x20vColor;\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20uniform\x20vec3\x20colorBase;\x0a\x20\x20\x20\x20\x20\x20\x20\x20uniform\x20vec3\x20colorZero;\x0a\x20\x20\x20\x20\x20\x20\x20\x20uniform\x20vec3\x20colorQuarter;\x0a\x20\x20\x20\x20\x20\x20\x20\x20uniform\x20vec3\x20colorHalf;\x0a\x20\x20\x20\x20\x20\x20\x20\x20uniform\x20vec3\x20colorFull;\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20uniform\x20float\x20targetBoneIndex;\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20void\x20main()\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec3\x20positionUpdated\x20=\x20position;\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#include\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#include\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec4\x20worldPos\x20=\x20finalWorld\x20*\x20vec4(positionUpdated,\x201.0);\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec3\x20color\x20=\x20colorBase;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20float\x20totalWeight\x20=\x200.;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20if(matricesIndices[0]\x20==\x20targetBoneIndex\x20&&\x20matricesWeights[0]\x20>\x200.){\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20totalWeight\x20+=\x20matricesWeights[0];\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20if(matricesIndices[1]\x20==\x20targetBoneIndex\x20&&\x20matricesWeights[1]\x20>\x200.){\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20totalWeight\x20+=\x20matricesWeights[1];\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20if(matricesIndices[2]\x20==\x20targetBoneIndex\x20&&\x20matricesWeights[2]\x20>\x200.){\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20totalWeight\x20+=\x20matricesWeights[2];\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20if(matricesIndices[3]\x20==\x20targetBoneIndex\x20&&\x20matricesWeights[3]\x20>\x200.){\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20totalWeight\x20+=\x20matricesWeights[3];\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20}\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20color\x20=\x20mix(color,\x20colorZero,\x20smoothstep(0.,\x200.25,\x20totalWeight));\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20color\x20=\x20mix(color,\x20colorQuarter,\x20smoothstep(0.25,\x200.5,\x20totalWeight));\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20color\x20=\x20mix(color,\x20colorHalf,\x20smoothstep(0.5,\x200.75,\x20totalWeight));\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20color\x20=\x20mix(color,\x20colorFull,\x20smoothstep(0.75,\x201.0,\x20totalWeight));\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vColor\x20=\x20color;\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20gl_Position\x20=\x20projection\x20*\x20view\x20*\x20worldPos;\x0a\x20\x20\x20\x20\x20\x20\x20\x20}',_0x2f1175['a']['ShadersStore']['boneWeights:'+_0x34e260['name']+'FragmentShader']='\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20precision\x20highp\x20float;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20varying\x20vec3\x20vPosition;\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20varying\x20vec3\x20vColor;\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20void\x20main()\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec4\x20color\x20=\x20vec4(vColor,\x201.0);\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20gl_FragColor\x20=\x20color;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20\x20\x20\x20\x20';var _0x174180=new _0x5bc610['a']('boneWeight:'+_0x34e260['name'],_0x280c78,{'vertex':'boneWeights:'+_0x34e260['name'],'fragment':'boneWeights:'+_0x34e260['name']},{'attributes':['position','normal','matricesIndices','matricesWeights'],'uniforms':['world','worldView','worldViewProjection','view','projection','viewProjection','colorBase','colorZero','colorQuarter','colorHalf','colorFull','targetBoneIndex']});return _0x174180['setColor3']('colorBase',_0x4a2f88),_0x174180['setColor3']('colorZero',_0x345a4b),_0x174180['setColor3']('colorQuarter',_0x2ad665),_0x174180['setColor3']('colorHalf',_0x446190),_0x174180['setColor3']('colorFull',_0x35c868),_0x174180['setFloat']('targetBoneIndex',_0xad8ed2),_0x174180['getClassName']=function(){return'BoneWeightShader';},_0x174180['transparencyMode']=_0x22b2d7['a']['MATERIAL_OPAQUE'],_0x174180;},_0x32d96a['CreateSkeletonMapShader']=function(_0x384950,_0x3cf57a){var _0x4e6613,_0x456fc8=_0x384950['skeleton'],_0x58ed25=null!==(_0x4e6613=_0x384950['colorMap'])&&void 0x0!==_0x4e6613?_0x4e6613:[{'color':new _0x1447d6['a'](0x1,0.38,0.18),'location':0x0},{'color':new _0x1447d6['a'](0.59,0.18,0x1),'location':0.2},{'color':new _0x1447d6['a'](0.59,0x1,0.18),'location':0.4},{'color':new _0x1447d6['a'](0x1,0.87,0.17),'location':0.6},{'color':new _0x1447d6['a'](0x1,0.17,0.42),'location':0.8},{'color':new _0x1447d6['a'](0.17,0.68,0x1),'location':0x1}],_0x2c288c=_0x456fc8['bones']['length']+0x1,_0x238665=_0x32d96a['_CreateBoneMapColorBuffer'](_0x2c288c,_0x58ed25,_0x3cf57a),_0x2dc7bc=new _0x5bc610['a']('boneWeights:'+_0x456fc8['name'],_0x3cf57a,{'vertexSource':'precision\x20highp\x20float;\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20attribute\x20vec3\x20position;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20attribute\x20vec2\x20uv;\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20uniform\x20mat4\x20view;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20uniform\x20mat4\x20projection;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20uniform\x20mat4\x20worldViewProjection;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20uniform\x20float\x20colorMap['+0x4*_0x456fc8['bones']['length']+'];\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#include\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#if\x20NUM_BONE_INFLUENCERS\x20==\x200\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20attribute\x20vec4\x20matricesIndices;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20attribute\x20vec4\x20matricesWeights;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#include\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20varying\x20vec3\x20vColor;\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20void\x20main()\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec3\x20positionUpdated\x20=\x20position;\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#include\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#include\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec3\x20color\x20=\x20vec3(0.);\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20bool\x20first\x20=\x20true;\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20for\x20(int\x20i\x20=\x200;\x20i\x20<\x204;\x20i++)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20int\x20boneIdx\x20=\x20int(matricesIndices[i]);\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20float\x20boneWgt\x20=\x20matricesWeights[i];\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec3\x20c\x20=\x20vec3(colorMap[boneIdx\x20*\x204\x20+\x200],\x20colorMap[boneIdx\x20*\x204\x20+\x201],\x20colorMap[boneIdx\x20*\x204\x20+\x202]);\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20if\x20(boneWgt\x20>\x200.)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20if\x20(first)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20first\x20=\x20false;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20color\x20=\x20c;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20}\x20else\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20color\x20=\x20mix(color,\x20c,\x20boneWgt);\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20}\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vColor\x20=\x20color;\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec4\x20worldPos\x20=\x20finalWorld\x20*\x20vec4(positionUpdated,\x201.0);\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20gl_Position\x20=\x20projection\x20*\x20view\x20*\x20worldPos;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20}','fragmentSource':'\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20precision\x20highp\x20float;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20varying\x20vec3\x20vColor;\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20void\x20main()\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec4\x20color\x20=\x20vec4(\x20vColor,\x201.0\x20);\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20gl_FragColor\x20=\x20color;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'},{'attributes':['position','normal','matricesIndices','matricesWeights'],'uniforms':['world','worldView','worldViewProjection','view','projection','viewProjection','colorMap']});return _0x2dc7bc['setFloats']('colorMap',_0x238665),_0x2dc7bc['getClassName']=function(){return'SkeletonMapShader';},_0x2dc7bc['transparencyMode']=_0x22b2d7['a']['MATERIAL_OPAQUE'],_0x2dc7bc;},_0x32d96a['_CreateBoneMapColorBuffer']=function(_0x956403,_0x41c921,_0x4c76ed){var _0x1cdafb=new _0x36b2de['a']('temp',{'width':_0x956403,'height':0x1},_0x4c76ed,!0x1),_0x4ea84a=_0x1cdafb['getContext'](),_0xd32c42=_0x4ea84a['createLinearGradient'](0x0,0x0,_0x956403,0x0);_0x41c921['forEach'](function(_0x375d2a){_0xd32c42['addColorStop'](_0x375d2a['location'],_0x375d2a['color']['toHexString']());}),_0x4ea84a['fillStyle']=_0xd32c42,_0x4ea84a['fillRect'](0x0,0x0,_0x956403,0x1),_0x1cdafb['update']();for(var _0x5aabea=[],_0xb90e7f=_0x4ea84a['getImageData'](0x0,0x0,_0x956403,0x1)['data'],_0x1a732d=0x0;_0x1a732d<_0xb90e7f['length'];_0x1a732d++)_0x5aabea['push'](_0xb90e7f[_0x1a732d]*(0x1/0xff));return _0x1cdafb['dispose'](),_0x5aabea;},Object['defineProperty'](_0x32d96a['prototype'],'scene',{'get':function(){return this['_scene'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x32d96a['prototype'],'utilityLayer',{'get':function(){return this['_utilityLayer'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x32d96a['prototype'],'isReady',{'get':function(){return this['_ready'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x32d96a['prototype'],'ready',{'set':function(_0x23bec0){this['_ready']=_0x23bec0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x32d96a['prototype'],'debugMesh',{'get':function(){return this['_debugMesh'];},'set':function(_0x16d6ec){this['_debugMesh']=_0x16d6ec;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x32d96a['prototype'],'displayMode',{'get':function(){return this['options']['displayMode']||_0x32d96a['DISPLAY_LINES'];},'set':function(_0x5737ff){_0x5737ff>_0x32d96a['DISPLAY_SPHERE_AND_SPURS']&&(_0x5737ff=_0x32d96a['DISPLAY_LINES']),this['options']['displayMode']=_0x5737ff;},'enumerable':!0x1,'configurable':!0x0}),_0x32d96a['prototype']['_bindObs']=function(){var _0x531d0f=this;switch(this['displayMode']){case _0x32d96a['DISPLAY_LINES']:this['_obs']=this['scene']['onBeforeRenderObservable']['add'](function(){_0x531d0f['_displayLinesUpdate']();});}},_0x32d96a['prototype']['update']=function(){switch(this['displayMode']){case _0x32d96a['DISPLAY_LINES']:this['_displayLinesUpdate']();break;case _0x32d96a['DISPLAY_SPHERES']:this['_buildSpheresAndSpurs'](!0x0);break;case _0x32d96a['DISPLAY_SPHERE_AND_SPURS']:this['_buildSpheresAndSpurs'](!0x1);}this['_buildLocalAxes']();},Object['defineProperty'](_0x32d96a['prototype'],'isEnabled',{'get':function(){return this['_isEnabled'];},'set':function(_0xc85fd7){this['isEnabled']!==_0xc85fd7&&(this['_isEnabled']=_0xc85fd7,this['debugMesh']&&this['debugMesh']['setEnabled'](_0xc85fd7),_0xc85fd7&&!this['_obs']?this['_bindObs']():!_0xc85fd7&&this['_obs']&&(this['scene']['onBeforeRenderObservable']['remove'](this['_obs']),this['_obs']=null));},'enumerable':!0x1,'configurable':!0x0}),_0x32d96a['prototype']['_getBonePosition']=function(_0x3dbb8b,_0x5ee671,_0x45beb1,_0x2ddeca,_0x3a2550,_0x1c51b9){void 0x0===_0x2ddeca&&(_0x2ddeca=0x0),void 0x0===_0x3a2550&&(_0x3a2550=0x0),void 0x0===_0x1c51b9&&(_0x1c51b9=0x0);var _0xabacf5=_0x4d0504['c']['Matrix'][0x0],_0x2b3500=_0x5ee671['getParent']();if(_0xabacf5['copyFrom'](_0x5ee671['getLocalMatrix']()),0x0!==_0x2ddeca||0x0!==_0x3a2550||0x0!==_0x1c51b9){var _0x55cefd=_0x4d0504['c']['Matrix'][0x1];_0x4d0504['a']['IdentityToRef'](_0x55cefd),_0x55cefd['setTranslationFromFloats'](_0x2ddeca,_0x3a2550,_0x1c51b9),_0x55cefd['multiplyToRef'](_0xabacf5,_0xabacf5);}_0x2b3500&&_0xabacf5['multiplyToRef'](_0x2b3500['getAbsoluteTransform'](),_0xabacf5),_0xabacf5['multiplyToRef'](_0x45beb1,_0xabacf5),_0x3dbb8b['x']=_0xabacf5['m'][0xc],_0x3dbb8b['y']=_0xabacf5['m'][0xd],_0x3dbb8b['z']=_0xabacf5['m'][0xe];},_0x32d96a['prototype']['_getLinesForBonesWithLength']=function(_0x2d76a0,_0x51b7e1){for(var _0x579d96=_0x2d76a0['length'],_0x216c33=this['mesh']['_effectiveMesh']['position'],_0x1b2ca0=0x0,_0x4b3169=0x0;_0x4b3169<_0x579d96;_0x4b3169++){var _0x36caa1=_0x2d76a0[_0x4b3169],_0xfaed59=this['_debugLines'][_0x1b2ca0];-0x1!==_0x36caa1['_index']&&(this['_boneIndices']['has'](_0x36caa1['getIndex']())||this['options']['useAllBones'])&&(_0xfaed59||(_0xfaed59=[_0x4d0504['e']['Zero'](),_0x4d0504['e']['Zero']()],this['_debugLines'][_0x1b2ca0]=_0xfaed59),this['_getBonePosition'](_0xfaed59[0x0],_0x36caa1,_0x51b7e1),this['_getBonePosition'](_0xfaed59[0x1],_0x36caa1,_0x51b7e1,0x0,_0x36caa1['length'],0x0),_0xfaed59[0x0]['subtractInPlace'](_0x216c33),_0xfaed59[0x1]['subtractInPlace'](_0x216c33),_0x1b2ca0++);}},_0x32d96a['prototype']['_getLinesForBonesNoLength']=function(_0x24dc74){for(var _0x25de86=_0x24dc74['length'],_0xa09e95=0x0,_0x3298b4=this['mesh']['_effectiveMesh'],_0x221c3e=_0x3298b4['position'],_0x39e553=_0x25de86-0x1;_0x39e553>=0x0;_0x39e553--){var _0x2da4fc=_0x24dc74[_0x39e553],_0x1ea8bb=_0x2da4fc['getParent']();if(_0x1ea8bb&&(this['_boneIndices']['has'](_0x2da4fc['getIndex']())||this['options']['useAllBones'])){var _0x1de91c=this['_debugLines'][_0xa09e95];_0x1de91c||(_0x1de91c=[_0x4d0504['e']['Zero'](),_0x4d0504['e']['Zero']()],this['_debugLines'][_0xa09e95]=_0x1de91c),_0x2da4fc['getAbsolutePositionToRef'](_0x3298b4,_0x1de91c[0x0]),_0x1ea8bb['getAbsolutePositionToRef'](_0x3298b4,_0x1de91c[0x1]),_0x1de91c[0x0]['subtractInPlace'](_0x221c3e),_0x1de91c[0x1]['subtractInPlace'](_0x221c3e),_0xa09e95++;}}},_0x32d96a['prototype']['_revert']=function(_0x4eadc6){this['options']['pauseAnimations']&&(this['scene']['animationsEnabled']=_0x4eadc6,this['utilityLayer']['utilityLayerScene']['animationsEnabled']=_0x4eadc6);},_0x32d96a['prototype']['_getAbsoluteBindPoseToRef']=function(_0x2ce190,_0x21a7ac){null!==_0x2ce190&&-0x1!==_0x2ce190['_index']?(this['_getAbsoluteBindPoseToRef'](_0x2ce190['getParent'](),_0x21a7ac),_0x2ce190['getBindPose']()['multiplyToRef'](_0x21a7ac,_0x21a7ac)):_0x21a7ac['copyFrom'](_0x4d0504['a']['Identity']());},_0x32d96a['prototype']['_buildSpheresAndSpurs']=function(_0x153d2){var _0x545a0f,_0x1a0fd6;void 0x0===_0x153d2&&(_0x153d2=!0x0),this['_debugMesh']&&(this['_debugMesh']['dispose'](),this['_debugMesh']=null,this['ready']=!0x1),this['_ready']=!0x1;var _0x573cb6=null===(_0x545a0f=this['utilityLayer'])||void 0x0===_0x545a0f?void 0x0:_0x545a0f['utilityLayerScene'],_0x2a368e=this['skeleton']['bones'],_0x3d78d3=[],_0x3f93fc=[],_0x169207=this['scene']['animationsEnabled'];try{this['options']['pauseAnimations']&&(this['scene']['animationsEnabled']=!0x1,_0x573cb6['animationsEnabled']=!0x1),this['options']['returnToRest']&&this['skeleton']['returnToRest'](),this['autoUpdateBonesMatrices']&&this['skeleton']['computeAbsoluteTransforms']();for(var _0x438979=Number['NEGATIVE_INFINITY'],_0x4a6db3=this['options']['displayOptions']||{},_0x3eac9e=function(_0x405be9){var _0x53cab4=_0x2a368e[_0x405be9];if(-0x1===_0x53cab4['_index']||!_0x1bddf3['_boneIndices']['has'](_0x53cab4['getIndex']())&&!_0x1bddf3['options']['useAllBones'])return'continue';var _0x3f38a2=new _0x4d0504['a']();_0x1bddf3['_getAbsoluteBindPoseToRef'](_0x53cab4,_0x3f38a2);var _0x368e68=new _0x4d0504['e']();_0x3f38a2['decompose'](void 0x0,void 0x0,_0x368e68),_0x53cab4['children']['forEach'](function(_0x45e605,_0x493f86){var _0x55b4db=new _0x4d0504['a']();_0x45e605['getBindPose']()['multiplyToRef'](_0x3f38a2,_0x55b4db);var _0x2b9803=new _0x4d0504['e']();_0x55b4db['decompose'](void 0x0,void 0x0,_0x2b9803);var _0x509e27=_0x4d0504['e']['Distance'](_0x368e68,_0x2b9803);if(_0x509e27>_0x438979&&(_0x438979=_0x509e27),!_0x153d2){for(var _0x1bd0be=_0x2b9803['clone']()['subtract'](_0x368e68['clone']()),_0x2cc910=_0x1bd0be['length'](),_0x4d257a=_0x1bd0be['normalize']()['scale'](_0x2cc910),_0xd7904c=_0x4a6db3['midStep']||0.165,_0x25f95c=_0x4a6db3['midStepFactor']||0.215,_0x243a04=_0x4d257a['scale'](_0xd7904c),_0xf0f2c8=_0x30edb4['a']['ExtrudeShapeCustom']('skeletonViewer',{'shape':[new _0x4d0504['e'](0x1,-0x1,0x0),new _0x4d0504['e'](0x1,0x1,0x0),new _0x4d0504['e'](-0x1,0x1,0x0),new _0x4d0504['e'](-0x1,-0x1,0x0),new _0x4d0504['e'](0x1,-0x1,0x0)],'path':[_0x4d0504['e']['Zero'](),_0x243a04,_0x4d257a],'scaleFunction':function(_0x54a9f6){switch(_0x54a9f6){case 0x0:case 0x2:return 0x0;case 0x1:return _0x2cc910*_0x25f95c;}return 0x0;},'sideOrientation':_0xb21d98['a']['DEFAULTSIDE'],'updatable':!0x1},_0x573cb6),_0x5d12d6=_0xf0f2c8['getTotalVertices'](),_0x1ff04e=[],_0x188f14=[],_0x437d9a=0x0;_0x437d9a<_0x5d12d6;_0x437d9a++)_0x1ff04e['push'](0x1,0x0,0x0,0x0),_0x4a6db3['spurFollowsChild']&&_0x437d9a>0x9?_0x188f14['push'](_0x45e605['getIndex'](),0x0,0x0,0x0):_0x188f14['push'](_0x53cab4['getIndex'](),0x0,0x0,0x0);_0xf0f2c8['position']=_0x368e68['clone'](),_0xf0f2c8['setVerticesData'](_0x13615a['b']['MatricesWeightsKind'],_0x1ff04e,!0x1),_0xf0f2c8['setVerticesData'](_0x13615a['b']['MatricesIndicesKind'],_0x188f14,!0x1),_0xf0f2c8['convertToFlatShadedMesh'](),_0x3f93fc['push'](_0xf0f2c8);}});for(var _0x2f97a5=_0x4a6db3['sphereBaseSize']||0.2,_0x5b931c=_0x1a2742['a']['CreateSphere']('skeletonViewer',{'segments':0x6,'diameter':_0x2f97a5,'updatable':!0x0},_0x573cb6),_0x4e2e84=_0x5b931c['getTotalVertices'](),_0x5f16fa=[],_0x1597ec=[],_0x90b3ca=0x0;_0x90b3ca<_0x4e2e84;_0x90b3ca++)_0x5f16fa['push'](0x1,0x0,0x0,0x0),_0x1597ec['push'](_0x53cab4['getIndex'](),0x0,0x0,0x0);_0x5b931c['setVerticesData'](_0x13615a['b']['MatricesWeightsKind'],_0x5f16fa,!0x1),_0x5b931c['setVerticesData'](_0x13615a['b']['MatricesIndicesKind'],_0x1597ec,!0x1),_0x5b931c['position']=_0x368e68['clone'](),_0x3d78d3['push']([_0x5b931c,_0x53cab4]);},_0x1bddf3=this,_0x5915a0=0x0;_0x5915a0<_0x2a368e['length'];_0x5915a0++)_0x3eac9e(_0x5915a0);var _0x23e515=_0x4a6db3['sphereScaleUnit']||0x2,_0x51c9d4=_0x4a6db3['sphereFactor']||0.85,_0x1c636b=[];for(_0x5915a0=0x0;_0x5915a0<_0x3d78d3['length'];_0x5915a0++){for(var _0x166c0e=_0x3d78d3[_0x5915a0],_0x5473ee=_0x166c0e[0x0],_0x23878d=_0x166c0e[0x1],_0x5eabca=0x1/(_0x23e515/_0x438979),_0x835a24=0x0,_0x1e30f3=_0x23878d;_0x1e30f3['getParent']()&&-0x1!==_0x1e30f3['getParent']()['getIndex']();)_0x835a24++,_0x1e30f3=_0x1e30f3['getParent']();_0x5473ee['scaling']['scaleInPlace'](_0x5eabca*Math['pow'](_0x51c9d4,_0x835a24)),_0x1c636b['push'](_0x5473ee);}this['debugMesh']=_0xb21d98['a']['MergeMeshes'](_0x1c636b['concat'](_0x3f93fc),!0x0,!0x0),this['debugMesh']&&(this['debugMesh']['renderingGroupId']=this['renderingGroupId'],this['debugMesh']['skeleton']=this['skeleton'],this['debugMesh']['parent']=this['mesh'],this['debugMesh']['computeBonesUsingShaders']=null===(_0x1a0fd6=this['options']['computeBonesUsingShaders'])||void 0x0===_0x1a0fd6||_0x1a0fd6,this['debugMesh']['alwaysSelectAsActiveMesh']=!0x0),this['utilityLayer']['_getSharedGizmoLight']()['intensity']=0.7,this['_revert'](_0x169207),this['ready']=!0x0;}catch(_0x118fff){console['error'](_0x118fff),this['_revert'](_0x169207),this['dispose']();}},_0x32d96a['prototype']['_buildLocalAxes']=function(){var _0x2810de;this['_localAxes']&&this['_localAxes']['dispose'](),this['_localAxes']=null;var _0x19c006=this['options']['displayOptions']||{};if(_0x19c006['showLocalAxes']){var _0x1fec1e=this['_utilityLayer']['utilityLayerScene'],_0x53b3f3=_0x19c006['localAxesSize']||0.075,_0x96ac85=[],_0x51da36=[],_0x5a0ac2=new _0x1447d6['b'](0x1,0x0,0x0,0x1),_0x6ea2a6=new _0x1447d6['b'](0x0,0x1,0x0,0x1),_0x4724b0=new _0x1447d6['b'](0x0,0x0,0x1,0x1),_0x55f1cf=[],_0x125c6a=[];for(var _0x11505e in this['skeleton']['bones']){var _0xedfa80=this['skeleton']['bones'][_0x11505e];if(-0x1!==_0xedfa80['_index']&&(this['_boneIndices']['has'](_0xedfa80['getIndex']())||this['options']['useAllBones'])){var _0x1aa331=new _0x4d0504['a'](),_0x32de74=new _0x4d0504['e']();this['_getAbsoluteBindPoseToRef'](_0xedfa80,_0x1aa331),_0x1aa331['decompose'](void 0x0,void 0x0,_0x32de74);var _0x5e7481=_0xedfa80['getBindPose']()['getRotationMatrix'](),_0xf6e189=_0x4d0504['e']['TransformCoordinates'](new _0x4d0504['e'](0x0+_0x53b3f3,0x0,0x0),_0x5e7481),_0x219a34=_0x4d0504['e']['TransformCoordinates'](new _0x4d0504['e'](0x0,0x0+_0x53b3f3,0x0),_0x5e7481),_0x3b3309=_0x4d0504['e']['TransformCoordinates'](new _0x4d0504['e'](0x0,0x0,0x0+_0x53b3f3),_0x5e7481),_0x52f7a5=[[_0x32de74,_0x32de74['add'](_0xf6e189)],[_0x32de74,_0x32de74['add'](_0x219a34)],[_0x32de74,_0x32de74['add'](_0x3b3309)]],_0x538fe5=[[_0x5a0ac2,_0x5a0ac2],[_0x6ea2a6,_0x6ea2a6],[_0x4724b0,_0x4724b0]];_0x96ac85['push']['apply'](_0x96ac85,_0x52f7a5),_0x51da36['push']['apply'](_0x51da36,_0x538fe5);for(var _0x19264d=0x0;_0x19264d<0x6;_0x19264d++)_0x55f1cf['push'](0x1,0x0,0x0,0x0),_0x125c6a['push'](_0xedfa80['getIndex'](),0x0,0x0,0x0);}}this['_localAxes']=_0x146c59['a']['CreateLineSystem']('localAxes',{'lines':_0x96ac85,'colors':_0x51da36,'updatable':!0x0},_0x1fec1e),this['_localAxes']['setVerticesData'](_0x13615a['b']['MatricesWeightsKind'],_0x55f1cf,!0x1),this['_localAxes']['setVerticesData'](_0x13615a['b']['MatricesIndicesKind'],_0x125c6a,!0x1),this['_localAxes']['skeleton']=this['skeleton'],this['_localAxes']['renderingGroupId']=this['renderingGroupId'],this['_localAxes']['parent']=this['mesh'],this['_localAxes']['computeBonesUsingShaders']=null===(_0x2810de=this['options']['computeBonesUsingShaders'])||void 0x0===_0x2810de||_0x2810de;}},_0x32d96a['prototype']['_displayLinesUpdate']=function(){if(this['_utilityLayer']){this['autoUpdateBonesMatrices']&&this['skeleton']['computeAbsoluteTransforms']();var _0xe23487=this['mesh']['_effectiveMesh'];void 0x0===this['skeleton']['bones'][0x0]['length']?this['_getLinesForBonesNoLength'](this['skeleton']['bones']):this['_getLinesForBonesWithLength'](this['skeleton']['bones'],_0xe23487['getWorldMatrix']());var _0x1358eb=this['_utilityLayer']['utilityLayerScene'];_0x1358eb&&(this['_debugMesh']?_0x146c59['a']['CreateLineSystem']('',{'lines':this['_debugLines'],'updatable':!0x0,'instance':this['_debugMesh']},_0x1358eb):(this['_debugMesh']=_0x146c59['a']['CreateLineSystem']('',{'lines':this['_debugLines'],'updatable':!0x0,'instance':null},_0x1358eb),this['_debugMesh']['renderingGroupId']=this['renderingGroupId']),this['_debugMesh']['position']['copyFrom'](this['mesh']['position']),this['_debugMesh']['color']=this['color']);}},_0x32d96a['prototype']['changeDisplayMode']=function(_0x235c94){var _0x5ed6db=!!this['isEnabled'];this['displayMode']!==_0x235c94&&(this['isEnabled']=!0x1,this['_debugMesh']&&(this['_debugMesh']['dispose'](),this['_debugMesh']=null,this['ready']=!0x1),this['displayMode']=_0x235c94,this['update'](),this['_bindObs'](),this['isEnabled']=_0x5ed6db);},_0x32d96a['prototype']['changeDisplayOptions']=function(_0xd480b1,_0xd8d17d){var _0x4d3fd5=!!this['isEnabled'];this['options']['displayOptions'][_0xd480b1]=_0xd8d17d,this['isEnabled']=!0x1,this['_debugMesh']&&(this['_debugMesh']['dispose'](),this['_debugMesh']=null,this['ready']=!0x1),this['update'](),this['_bindObs'](),this['isEnabled']=_0x4d3fd5;},_0x32d96a['prototype']['dispose']=function(){this['isEnabled']=!0x1,this['_debugMesh']&&(this['_debugMesh']['dispose'](),this['_debugMesh']=null),this['_utilityLayer']&&(this['_utilityLayer']['dispose'](),this['_utilityLayer']=null),this['ready']=!0x1;},_0x32d96a['DISPLAY_LINES']=0x0,_0x32d96a['DISPLAY_SPHERES']=0x1,_0x32d96a['DISPLAY_SPHERE_AND_SPURS']=0x2,_0x32d96a;}());},function(_0x4b57ed,_0x48a1b1,_0x1ad79a){'use strict';var _0xfd6416='morphTargetsVertex',_0x1f04f8='#ifdef\x20MORPHTARGETS\x0apositionUpdated+=(position{X}-position)*morphTargetInfluences[{X}];\x0a#ifdef\x20MORPHTARGETS_NORMAL\x0anormalUpdated+=(normal{X}-normal)*morphTargetInfluences[{X}];\x0a#endif\x0a#ifdef\x20MORPHTARGETS_TANGENT\x0atangentUpdated.xyz+=(tangent{X}-tangent.xyz)*morphTargetInfluences[{X}];\x0a#endif\x0a#ifdef\x20MORPHTARGETS_UV\x0auvUpdated+=(uv_{X}-uv)*morphTargetInfluences[{X}];\x0a#endif\x0a#endif';_0x1ad79a(0x5)['a']['IncludesShadersStore'][_0xfd6416]=_0x1f04f8;},function(_0x4d7459,_0x47dfe0,_0x5088f0){'use strict';_0x5088f0['d'](_0x47dfe0,'b',function(){return _0x29d380;}),_0x5088f0['d'](_0x47dfe0,'a',function(){return _0x59f396;});var _0x591ee5=_0x5088f0(0x0);function _0x29d380(_0x126651,_0x42cf86,_0x20341d,_0x28af8a,_0x4940c){void 0x0===_0x4940c&&(_0x4940c=null);for(var _0x4a9aa8=new _0x591ee5['e'](Number['MAX_VALUE'],Number['MAX_VALUE'],Number['MAX_VALUE']),_0x149237=new _0x591ee5['e'](-Number['MAX_VALUE'],-Number['MAX_VALUE'],-Number['MAX_VALUE']),_0x4efc8d=_0x20341d;_0x4efc8d<_0x20341d+_0x28af8a;_0x4efc8d++){var _0x1908af=0x3*_0x42cf86[_0x4efc8d],_0x4633dc=_0x126651[_0x1908af],_0x192f19=_0x126651[_0x1908af+0x1],_0xcae61=_0x126651[_0x1908af+0x2];_0x4a9aa8['minimizeInPlaceFromFloats'](_0x4633dc,_0x192f19,_0xcae61),_0x149237['maximizeInPlaceFromFloats'](_0x4633dc,_0x192f19,_0xcae61);}return _0x4940c&&(_0x4a9aa8['x']-=_0x4a9aa8['x']*_0x4940c['x']+_0x4940c['y'],_0x4a9aa8['y']-=_0x4a9aa8['y']*_0x4940c['x']+_0x4940c['y'],_0x4a9aa8['z']-=_0x4a9aa8['z']*_0x4940c['x']+_0x4940c['y'],_0x149237['x']+=_0x149237['x']*_0x4940c['x']+_0x4940c['y'],_0x149237['y']+=_0x149237['y']*_0x4940c['x']+_0x4940c['y'],_0x149237['z']+=_0x149237['z']*_0x4940c['x']+_0x4940c['y']),{'minimum':_0x4a9aa8,'maximum':_0x149237};}function _0x59f396(_0xa9c601,_0x4c27ad,_0x327764,_0x3ecff8,_0x1ddd2f){void 0x0===_0x3ecff8&&(_0x3ecff8=null);var _0x318f5b=new _0x591ee5['e'](Number['MAX_VALUE'],Number['MAX_VALUE'],Number['MAX_VALUE']),_0xad8513=new _0x591ee5['e'](-Number['MAX_VALUE'],-Number['MAX_VALUE'],-Number['MAX_VALUE']);_0x1ddd2f||(_0x1ddd2f=0x3);for(var _0x3987a9=_0x4c27ad,_0x6bc63d=_0x4c27ad*_0x1ddd2f;_0x3987a9<_0x4c27ad+_0x327764;_0x3987a9++,_0x6bc63d+=_0x1ddd2f){var _0x4b8c4a=_0xa9c601[_0x6bc63d],_0x2c06df=_0xa9c601[_0x6bc63d+0x1],_0x1b444b=_0xa9c601[_0x6bc63d+0x2];_0x318f5b['minimizeInPlaceFromFloats'](_0x4b8c4a,_0x2c06df,_0x1b444b),_0xad8513['maximizeInPlaceFromFloats'](_0x4b8c4a,_0x2c06df,_0x1b444b);}return _0x3ecff8&&(_0x318f5b['x']-=_0x318f5b['x']*_0x3ecff8['x']+_0x3ecff8['y'],_0x318f5b['y']-=_0x318f5b['y']*_0x3ecff8['x']+_0x3ecff8['y'],_0x318f5b['z']-=_0x318f5b['z']*_0x3ecff8['x']+_0x3ecff8['y'],_0xad8513['x']+=_0xad8513['x']*_0x3ecff8['x']+_0x3ecff8['y'],_0xad8513['y']+=_0xad8513['y']*_0x3ecff8['x']+_0x3ecff8['y'],_0xad8513['z']+=_0xad8513['z']*_0x3ecff8['x']+_0x3ecff8['y']),{'minimum':_0x318f5b,'maximum':_0xad8513};}},function(_0x233f6f,_0x3a1a03,_0x1341dd){'use strict';_0x1341dd['d'](_0x3a1a03,'a',function(){return _0x5151fe;});var _0x5151fe=function(){};},function(_0x220984,_0xcf043c,_0xcb7a22){'use strict';_0xcb7a22['d'](_0xcf043c,'a',function(){return _0x1d1316;});var _0x6ee224=_0xcb7a22(0x2c),_0x4c14eb=_0xcb7a22(0x0),_0x476141=_0xcb7a22(0x1c),_0x1d1316=(function(){function _0x95ba33(_0x1dad20,_0x3a0dbb,_0x121bb2){this['vectors']=_0x6ee224['a']['BuildArray'](0x8,_0x4c14eb['e']['Zero']),this['center']=_0x4c14eb['e']['Zero'](),this['centerWorld']=_0x4c14eb['e']['Zero'](),this['extendSize']=_0x4c14eb['e']['Zero'](),this['extendSizeWorld']=_0x4c14eb['e']['Zero'](),this['directions']=_0x6ee224['a']['BuildArray'](0x3,_0x4c14eb['e']['Zero']),this['vectorsWorld']=_0x6ee224['a']['BuildArray'](0x8,_0x4c14eb['e']['Zero']),this['minimumWorld']=_0x4c14eb['e']['Zero'](),this['maximumWorld']=_0x4c14eb['e']['Zero'](),this['minimum']=_0x4c14eb['e']['Zero'](),this['maximum']=_0x4c14eb['e']['Zero'](),this['reConstruct'](_0x1dad20,_0x3a0dbb,_0x121bb2);}return _0x95ba33['prototype']['reConstruct']=function(_0x2dece1,_0x5aaff5,_0x51a84c){var _0x1ef519=_0x2dece1['x'],_0x28348d=_0x2dece1['y'],_0xed1b22=_0x2dece1['z'],_0x1ff70c=_0x5aaff5['x'],_0x12c18b=_0x5aaff5['y'],_0x44c754=_0x5aaff5['z'],_0x5ca7f2=this['vectors'];this['minimum']['copyFromFloats'](_0x1ef519,_0x28348d,_0xed1b22),this['maximum']['copyFromFloats'](_0x1ff70c,_0x12c18b,_0x44c754),_0x5ca7f2[0x0]['copyFromFloats'](_0x1ef519,_0x28348d,_0xed1b22),_0x5ca7f2[0x1]['copyFromFloats'](_0x1ff70c,_0x12c18b,_0x44c754),_0x5ca7f2[0x2]['copyFromFloats'](_0x1ff70c,_0x28348d,_0xed1b22),_0x5ca7f2[0x3]['copyFromFloats'](_0x1ef519,_0x12c18b,_0xed1b22),_0x5ca7f2[0x4]['copyFromFloats'](_0x1ef519,_0x28348d,_0x44c754),_0x5ca7f2[0x5]['copyFromFloats'](_0x1ff70c,_0x12c18b,_0xed1b22),_0x5ca7f2[0x6]['copyFromFloats'](_0x1ef519,_0x12c18b,_0x44c754),_0x5ca7f2[0x7]['copyFromFloats'](_0x1ff70c,_0x28348d,_0x44c754),_0x5aaff5['addToRef'](_0x2dece1,this['center'])['scaleInPlace'](0.5),_0x5aaff5['subtractToRef'](_0x2dece1,this['extendSize'])['scaleInPlace'](0.5),this['_worldMatrix']=_0x51a84c||_0x4c14eb['a']['IdentityReadOnly'],this['_update'](this['_worldMatrix']);},_0x95ba33['prototype']['scale']=function(_0x2bdd0a){var _0x16b9eb=_0x95ba33['TmpVector3'],_0x746a9b=this['maximum']['subtractToRef'](this['minimum'],_0x16b9eb[0x0]),_0x4e4ac0=_0x746a9b['length']();_0x746a9b['normalizeFromLength'](_0x4e4ac0);var _0x440065=_0x4e4ac0*_0x2bdd0a,_0x40d0ef=_0x746a9b['scaleInPlace'](0.5*_0x440065),_0x4b6d4c=this['center']['subtractToRef'](_0x40d0ef,_0x16b9eb[0x1]),_0x53053b=this['center']['addToRef'](_0x40d0ef,_0x16b9eb[0x2]);return this['reConstruct'](_0x4b6d4c,_0x53053b,this['_worldMatrix']),this;},_0x95ba33['prototype']['getWorldMatrix']=function(){return this['_worldMatrix'];},_0x95ba33['prototype']['_update']=function(_0x3cea7){var _0x282d7c=this['minimumWorld'],_0x50c44d=this['maximumWorld'],_0x11ec8b=this['directions'],_0x30948e=this['vectorsWorld'],_0x1806c8=this['vectors'];if(_0x3cea7['isIdentity']()){_0x282d7c['copyFrom'](this['minimum']),_0x50c44d['copyFrom'](this['maximum']);for(_0x33dc04=0x0;_0x33dc04<0x8;++_0x33dc04)_0x30948e[_0x33dc04]['copyFrom'](_0x1806c8[_0x33dc04]);this['extendSizeWorld']['copyFrom'](this['extendSize']),this['centerWorld']['copyFrom'](this['center']);}else{_0x282d7c['setAll'](Number['MAX_VALUE']),_0x50c44d['setAll'](-Number['MAX_VALUE']);for(var _0x33dc04=0x0;_0x33dc04<0x8;++_0x33dc04){var _0xd1704a=_0x30948e[_0x33dc04];_0x4c14eb['e']['TransformCoordinatesToRef'](_0x1806c8[_0x33dc04],_0x3cea7,_0xd1704a),_0x282d7c['minimizeInPlace'](_0xd1704a),_0x50c44d['maximizeInPlace'](_0xd1704a);}_0x50c44d['subtractToRef'](_0x282d7c,this['extendSizeWorld'])['scaleInPlace'](0.5),_0x50c44d['addToRef'](_0x282d7c,this['centerWorld'])['scaleInPlace'](0.5);}_0x4c14eb['e']['FromArrayToRef'](_0x3cea7['m'],0x0,_0x11ec8b[0x0]),_0x4c14eb['e']['FromArrayToRef'](_0x3cea7['m'],0x4,_0x11ec8b[0x1]),_0x4c14eb['e']['FromArrayToRef'](_0x3cea7['m'],0x8,_0x11ec8b[0x2]),this['_worldMatrix']=_0x3cea7;},_0x95ba33['prototype']['isInFrustum']=function(_0x53378e){return _0x95ba33['IsInFrustum'](this['vectorsWorld'],_0x53378e);},_0x95ba33['prototype']['isCompletelyInFrustum']=function(_0x3fce87){return _0x95ba33['IsCompletelyInFrustum'](this['vectorsWorld'],_0x3fce87);},_0x95ba33['prototype']['intersectsPoint']=function(_0x36c33e){var _0x1b95ac=this['minimumWorld'],_0x25edc5=this['maximumWorld'],_0x2f78d8=_0x1b95ac['x'],_0x332e9f=_0x1b95ac['y'],_0x30fd3a=_0x1b95ac['z'],_0x2eb157=_0x25edc5['x'],_0x310f5a=_0x25edc5['y'],_0x6cb285=_0x25edc5['z'],_0x2465c3=_0x36c33e['x'],_0x775bdd=_0x36c33e['y'],_0x4e853e=_0x36c33e['z'],_0x4ecf6c=-_0x476141['a'];return!(_0x2eb157-_0x2465c3<_0x4ecf6c||_0x4ecf6c>_0x2465c3-_0x2f78d8)&&(!(_0x310f5a-_0x775bdd<_0x4ecf6c||_0x4ecf6c>_0x775bdd-_0x332e9f)&&!(_0x6cb285-_0x4e853e<_0x4ecf6c||_0x4ecf6c>_0x4e853e-_0x30fd3a));},_0x95ba33['prototype']['intersectsSphere']=function(_0x5cec76){return _0x95ba33['IntersectsSphere'](this['minimumWorld'],this['maximumWorld'],_0x5cec76['centerWorld'],_0x5cec76['radiusWorld']);},_0x95ba33['prototype']['intersectsMinMax']=function(_0x480659,_0x2c868e){var _0x26a15e=this['minimumWorld'],_0x1be50c=this['maximumWorld'],_0x55fda9=_0x26a15e['x'],_0x1cdd32=_0x26a15e['y'],_0x3ab3e4=_0x26a15e['z'],_0x23371f=_0x1be50c['x'],_0x9e487c=_0x1be50c['y'],_0x1d7883=_0x1be50c['z'],_0x13ad16=_0x480659['x'],_0x5407dc=_0x480659['y'],_0x27d68a=_0x480659['z'],_0x2ac87f=_0x2c868e['x'],_0x206b0c=_0x2c868e['y'],_0x5f1342=_0x2c868e['z'];return!(_0x23371f<_0x13ad16||_0x55fda9>_0x2ac87f)&&(!(_0x9e487c<_0x5407dc||_0x1cdd32>_0x206b0c)&&!(_0x1d7883<_0x27d68a||_0x3ab3e4>_0x5f1342));},_0x95ba33['Intersects']=function(_0x556d02,_0x2239ca){return _0x556d02['intersectsMinMax'](_0x2239ca['minimumWorld'],_0x2239ca['maximumWorld']);},_0x95ba33['IntersectsSphere']=function(_0x20011b,_0x28e78a,_0x57ac26,_0x2121d3){var _0x2a5356=_0x95ba33['TmpVector3'][0x0];return _0x4c14eb['e']['ClampToRef'](_0x57ac26,_0x20011b,_0x28e78a,_0x2a5356),_0x4c14eb['e']['DistanceSquared'](_0x57ac26,_0x2a5356)<=_0x2121d3*_0x2121d3;},_0x95ba33['IsCompletelyInFrustum']=function(_0x260406,_0x2a61e7){for(var _0x5ba9e0=0x0;_0x5ba9e0<0x6;++_0x5ba9e0)for(var _0x4c9056=_0x2a61e7[_0x5ba9e0],_0x3c503e=0x0;_0x3c503e<0x8;++_0x3c503e)if(_0x4c9056['dotCoordinate'](_0x260406[_0x3c503e])<0x0)return!0x1;return!0x0;},_0x95ba33['IsInFrustum']=function(_0x529351,_0x1d8b99){for(var _0x5f4c3c=0x0;_0x5f4c3c<0x6;++_0x5f4c3c){for(var _0x1216fd=!0x0,_0x2140a2=_0x1d8b99[_0x5f4c3c],_0x3090dd=0x0;_0x3090dd<0x8;++_0x3090dd)if(_0x2140a2['dotCoordinate'](_0x529351[_0x3090dd])>=0x0){_0x1216fd=!0x1;break;}if(_0x1216fd)return!0x1;}return!0x0;},_0x95ba33['TmpVector3']=_0x6ee224['a']['BuildArray'](0x3,_0x4c14eb['e']['Zero']),_0x95ba33;}());},function(_0x341157,_0x2bda4b,_0x2e53b5){'use strict';_0x2e53b5['d'](_0x2bda4b,'a',function(){return _0x507cfd;});var _0x57873c=_0x2e53b5(0x26),_0x507cfd=(function(){function _0x49acea(){}return _0x49acea['SetImmediate']=function(_0x5dce8f){_0x57873c['a']['IsWindowObjectExist']()&&window['setImmediate']?window['setImmediate'](_0x5dce8f):setTimeout(_0x5dce8f,0x1);},_0x49acea;}());},function(_0x5082be,_0x11bdeb,_0x3b7549){'use strict';_0x3b7549['d'](_0x11bdeb,'a',function(){return _0x38f92f;});var _0x4097aa=_0x3b7549(0x0),_0x4596e4=_0x3b7549(0x2),_0x38f92f=(function(){function _0x5bcee9(){this['previousWorldMatrices']={},this['previousBones']={};}return _0x5bcee9['AddUniforms']=function(_0x52e5a7){_0x52e5a7['push']('previousWorld','previousViewProjection');},_0x5bcee9['AddSamplers']=function(_0xcc7e1d){},_0x5bcee9['prototype']['bindForSubMesh']=function(_0x382231,_0x23cb69,_0x39dd30,_0x115e14,_0x7c28c4){_0x23cb69['prePassRenderer']&&_0x23cb69['prePassRenderer']['enabled']&&-0x1!==_0x23cb69['prePassRenderer']['getIndex'](_0x4596e4['a']['PREPASS_VELOCITY_TEXTURE_TYPE'])&&(this['previousWorldMatrices'][_0x39dd30['uniqueId']]||(this['previousWorldMatrices'][_0x39dd30['uniqueId']]=_0x4097aa['a']['Identity']()),this['previousViewProjection']||(this['previousViewProjection']=_0x23cb69['getTransformMatrix']()),_0x382231['setMatrix']('previousWorld',this['previousWorldMatrices'][_0x39dd30['uniqueId']]),_0x382231['setMatrix']('previousViewProjection',this['previousViewProjection']),this['previousWorldMatrices'][_0x39dd30['uniqueId']]=_0x115e14['clone'](),this['previousViewProjection']=_0x23cb69['getTransformMatrix']()['clone']());},_0x5bcee9;}());},function(_0x16d77e,_0x1131bc,_0x3a270d){'use strict';var _0xfe9fbd='lightFragmentDeclaration',_0x38816f='#ifdef\x20LIGHT{X}\x0auniform\x20vec4\x20vLightData{X};\x0auniform\x20vec4\x20vLightDiffuse{X};\x0a#ifdef\x20SPECULARTERM\x0auniform\x20vec4\x20vLightSpecular{X};\x0a#else\x0avec4\x20vLightSpecular{X}=vec4(0.);\x0a#endif\x0a#ifdef\x20SHADOW{X}\x0a#ifdef\x20SHADOWCSM{X}\x0auniform\x20mat4\x20lightMatrix{X}[SHADOWCSMNUM_CASCADES{X}];\x0auniform\x20float\x20viewFrustumZ{X}[SHADOWCSMNUM_CASCADES{X}];\x0auniform\x20float\x20frustumLengths{X}[SHADOWCSMNUM_CASCADES{X}];\x0auniform\x20float\x20cascadeBlendFactor{X};\x0avarying\x20vec4\x20vPositionFromLight{X}[SHADOWCSMNUM_CASCADES{X}];\x0avarying\x20float\x20vDepthMetric{X}[SHADOWCSMNUM_CASCADES{X}];\x0avarying\x20vec4\x20vPositionFromCamera{X};\x0a#if\x20defined(SHADOWPCSS{X})\x0auniform\x20highp\x20sampler2DArrayShadow\x20shadowSampler{X};\x0auniform\x20highp\x20sampler2DArray\x20depthSampler{X};\x0auniform\x20vec2\x20lightSizeUVCorrection{X}[SHADOWCSMNUM_CASCADES{X}];\x0auniform\x20float\x20depthCorrection{X}[SHADOWCSMNUM_CASCADES{X}];\x0auniform\x20float\x20penumbraDarkness{X};\x0a#elif\x20defined(SHADOWPCF{X})\x0auniform\x20highp\x20sampler2DArrayShadow\x20shadowSampler{X};\x0a#else\x0auniform\x20highp\x20sampler2DArray\x20shadowSampler{X};\x0a#endif\x0a#ifdef\x20SHADOWCSMDEBUG{X}\x0aconst\x20vec3\x20vCascadeColorsMultiplier{X}[8]=vec3[8]\x0a(\x0avec3\x20(\x201.5,0.0,0.0\x20),\x0avec3\x20(\x200.0,1.5,0.0\x20),\x0avec3\x20(\x200.0,0.0,5.5\x20),\x0avec3\x20(\x201.5,0.0,5.5\x20),\x0avec3\x20(\x201.5,1.5,0.0\x20),\x0avec3\x20(\x201.0,1.0,1.0\x20),\x0avec3\x20(\x200.0,1.0,5.5\x20),\x0avec3\x20(\x200.5,3.5,0.75\x20)\x0a);\x0avec3\x20shadowDebug{X};\x0a#endif\x0a#ifdef\x20SHADOWCSMUSESHADOWMAXZ{X}\x0aint\x20index{X}=-1;\x0a#else\x0aint\x20index{X}=SHADOWCSMNUM_CASCADES{X}-1;\x0a#endif\x0afloat\x20diff{X}=0.;\x0a#elif\x20defined(SHADOWCUBE{X})\x0auniform\x20samplerCube\x20shadowSampler{X};\x0a#else\x0avarying\x20vec4\x20vPositionFromLight{X};\x0avarying\x20float\x20vDepthMetric{X};\x0a#if\x20defined(SHADOWPCSS{X})\x0auniform\x20highp\x20sampler2DShadow\x20shadowSampler{X};\x0auniform\x20highp\x20sampler2D\x20depthSampler{X};\x0a#elif\x20defined(SHADOWPCF{X})\x0auniform\x20highp\x20sampler2DShadow\x20shadowSampler{X};\x0a#else\x0auniform\x20sampler2D\x20shadowSampler{X};\x0a#endif\x0auniform\x20mat4\x20lightMatrix{X};\x0a#endif\x0auniform\x20vec4\x20shadowsInfo{X};\x0auniform\x20vec2\x20depthValues{X};\x0a#endif\x0a#ifdef\x20SPOTLIGHT{X}\x0auniform\x20vec4\x20vLightDirection{X};\x0auniform\x20vec4\x20vLightFalloff{X};\x0a#elif\x20defined(POINTLIGHT{X})\x0auniform\x20vec4\x20vLightFalloff{X};\x0a#elif\x20defined(HEMILIGHT{X})\x0auniform\x20vec3\x20vLightGround{X};\x0a#endif\x0a#ifdef\x20PROJECTEDLIGHTTEXTURE{X}\x0auniform\x20mat4\x20textureProjectionMatrix{X};\x0auniform\x20sampler2D\x20projectionLightSampler{X};\x0a#endif\x0a#endif';_0x3a270d(0x5)['a']['IncludesShadersStore'][_0xfe9fbd]=_0x38816f;},function(_0x12c9c6,_0x1070c9,_0x4a3531){'use strict';var _0x46a710='lightUboDeclaration',_0x302f6f='#ifdef\x20LIGHT{X}\x0auniform\x20Light{X}\x0a{\x0avec4\x20vLightData;\x0avec4\x20vLightDiffuse;\x0avec4\x20vLightSpecular;\x0a#ifdef\x20SPOTLIGHT{X}\x0avec4\x20vLightDirection;\x0avec4\x20vLightFalloff;\x0a#elif\x20defined(POINTLIGHT{X})\x0avec4\x20vLightFalloff;\x0a#elif\x20defined(HEMILIGHT{X})\x0avec3\x20vLightGround;\x0a#endif\x0avec4\x20shadowsInfo;\x0avec2\x20depthValues;\x0a}\x20light{X};\x0a#ifdef\x20PROJECTEDLIGHTTEXTURE{X}\x0auniform\x20mat4\x20textureProjectionMatrix{X};\x0auniform\x20sampler2D\x20projectionLightSampler{X};\x0a#endif\x0a#ifdef\x20SHADOW{X}\x0a#ifdef\x20SHADOWCSM{X}\x0auniform\x20mat4\x20lightMatrix{X}[SHADOWCSMNUM_CASCADES{X}];\x0auniform\x20float\x20viewFrustumZ{X}[SHADOWCSMNUM_CASCADES{X}];\x0auniform\x20float\x20frustumLengths{X}[SHADOWCSMNUM_CASCADES{X}];\x0auniform\x20float\x20cascadeBlendFactor{X};\x0avarying\x20vec4\x20vPositionFromLight{X}[SHADOWCSMNUM_CASCADES{X}];\x0avarying\x20float\x20vDepthMetric{X}[SHADOWCSMNUM_CASCADES{X}];\x0avarying\x20vec4\x20vPositionFromCamera{X};\x0a#if\x20defined(SHADOWPCSS{X})\x0auniform\x20highp\x20sampler2DArrayShadow\x20shadowSampler{X};\x0auniform\x20highp\x20sampler2DArray\x20depthSampler{X};\x0auniform\x20vec2\x20lightSizeUVCorrection{X}[SHADOWCSMNUM_CASCADES{X}];\x0auniform\x20float\x20depthCorrection{X}[SHADOWCSMNUM_CASCADES{X}];\x0auniform\x20float\x20penumbraDarkness{X};\x0a#elif\x20defined(SHADOWPCF{X})\x0auniform\x20highp\x20sampler2DArrayShadow\x20shadowSampler{X};\x0a#else\x0auniform\x20highp\x20sampler2DArray\x20shadowSampler{X};\x0a#endif\x0a#ifdef\x20SHADOWCSMDEBUG{X}\x0aconst\x20vec3\x20vCascadeColorsMultiplier{X}[8]=vec3[8]\x0a(\x0avec3\x20(\x201.5,0.0,0.0\x20),\x0avec3\x20(\x200.0,1.5,0.0\x20),\x0avec3\x20(\x200.0,0.0,5.5\x20),\x0avec3\x20(\x201.5,0.0,5.5\x20),\x0avec3\x20(\x201.5,1.5,0.0\x20),\x0avec3\x20(\x201.0,1.0,1.0\x20),\x0avec3\x20(\x200.0,1.0,5.5\x20),\x0avec3\x20(\x200.5,3.5,0.75\x20)\x0a);\x0avec3\x20shadowDebug{X};\x0a#endif\x0a#ifdef\x20SHADOWCSMUSESHADOWMAXZ{X}\x0aint\x20index{X}=-1;\x0a#else\x0aint\x20index{X}=SHADOWCSMNUM_CASCADES{X}-1;\x0a#endif\x0afloat\x20diff{X}=0.;\x0a#elif\x20defined(SHADOWCUBE{X})\x0auniform\x20samplerCube\x20shadowSampler{X};\x0a#else\x0avarying\x20vec4\x20vPositionFromLight{X};\x0avarying\x20float\x20vDepthMetric{X};\x0a#if\x20defined(SHADOWPCSS{X})\x0auniform\x20highp\x20sampler2DShadow\x20shadowSampler{X};\x0auniform\x20highp\x20sampler2D\x20depthSampler{X};\x0a#elif\x20defined(SHADOWPCF{X})\x0auniform\x20highp\x20sampler2DShadow\x20shadowSampler{X};\x0a#else\x0auniform\x20sampler2D\x20shadowSampler{X};\x0a#endif\x0auniform\x20mat4\x20lightMatrix{X};\x0a#endif\x0a#endif\x0a#endif';_0x4a3531(0x5)['a']['IncludesShadersStore'][_0x46a710]=_0x302f6f;},function(_0x40f6b5,_0x222ce5,_0x5205ea){'use strict';var _0x986317='imageProcessingDeclaration',_0x55e954='#ifdef\x20EXPOSURE\x0auniform\x20float\x20exposureLinear;\x0a#endif\x0a#ifdef\x20CONTRAST\x0auniform\x20float\x20contrast;\x0a#endif\x0a#ifdef\x20VIGNETTE\x0auniform\x20vec2\x20vInverseScreenSize;\x0auniform\x20vec4\x20vignetteSettings1;\x0auniform\x20vec4\x20vignetteSettings2;\x0a#endif\x0a#ifdef\x20COLORCURVES\x0auniform\x20vec4\x20vCameraColorCurveNegative;\x0auniform\x20vec4\x20vCameraColorCurveNeutral;\x0auniform\x20vec4\x20vCameraColorCurvePositive;\x0a#endif\x0a#ifdef\x20COLORGRADING\x0a#ifdef\x20COLORGRADING3D\x0auniform\x20highp\x20sampler3D\x20txColorTransform;\x0a#else\x0auniform\x20sampler2D\x20txColorTransform;\x0a#endif\x0auniform\x20vec4\x20colorTransformSettings;\x0a#endif';_0x5205ea(0x5)['a']['IncludesShadersStore'][_0x986317]=_0x55e954;},function(_0x27fca2,_0x5f39ad,_0x43399b){'use strict';var _0x511c47='imageProcessingFunctions',_0x63d9e4='#if\x20defined(COLORGRADING)\x20&&\x20!defined(COLORGRADING3D)\x0a\x0a#define\x20inline\x0avec3\x20sampleTexture3D(sampler2D\x20colorTransform,vec3\x20color,vec2\x20sampler3dSetting)\x0a{\x0afloat\x20sliceSize=2.0*sampler3dSetting.x;\x0a#ifdef\x20SAMPLER3DGREENDEPTH\x0afloat\x20sliceContinuous=(color.g-sampler3dSetting.x)*sampler3dSetting.y;\x0a#else\x0afloat\x20sliceContinuous=(color.b-sampler3dSetting.x)*sampler3dSetting.y;\x0a#endif\x0afloat\x20sliceInteger=floor(sliceContinuous);\x0a\x0a\x0afloat\x20sliceFraction=sliceContinuous-sliceInteger;\x0a#ifdef\x20SAMPLER3DGREENDEPTH\x0avec2\x20sliceUV=color.rb;\x0a#else\x0avec2\x20sliceUV=color.rg;\x0a#endif\x0asliceUV.x*=sliceSize;\x0asliceUV.x+=sliceInteger*sliceSize;\x0asliceUV=saturate(sliceUV);\x0avec4\x20slice0Color=texture2D(colorTransform,sliceUV);\x0asliceUV.x+=sliceSize;\x0asliceUV=saturate(sliceUV);\x0avec4\x20slice1Color=texture2D(colorTransform,sliceUV);\x0avec3\x20result=mix(slice0Color.rgb,slice1Color.rgb,sliceFraction);\x0a#ifdef\x20SAMPLER3DBGRMAP\x0acolor.rgb=result.rgb;\x0a#else\x0acolor.rgb=result.bgr;\x0a#endif\x0areturn\x20color;\x0a}\x0a#endif\x0a#ifdef\x20TONEMAPPING_ACES\x0a\x0a\x0a\x0a\x0a\x0aconst\x20mat3\x20ACESInputMat=mat3(\x0avec3(0.59719,0.07600,0.02840),\x0avec3(0.35458,0.90834,0.13383),\x0avec3(0.04823,0.01566,0.83777)\x0a);\x0a\x0aconst\x20mat3\x20ACESOutputMat=mat3(\x0avec3(\x201.60475,-0.10208,-0.00327),\x0avec3(-0.53108,1.10813,-0.07276),\x0avec3(-0.07367,-0.00605,1.07602)\x0a);\x0avec3\x20RRTAndODTFit(vec3\x20v)\x0a{\x0avec3\x20a=v*(v+0.0245786)-0.000090537;\x0avec3\x20b=v*(0.983729*v+0.4329510)+0.238081;\x0areturn\x20a/b;\x0a}\x0avec3\x20ACESFitted(vec3\x20color)\x0a{\x0acolor=ACESInputMat*color;\x0a\x0acolor=RRTAndODTFit(color);\x0acolor=ACESOutputMat*color;\x0a\x0acolor=saturate(color);\x0areturn\x20color;\x0a}\x0a#endif\x0avec4\x20applyImageProcessing(vec4\x20result)\x20{\x0a#ifdef\x20EXPOSURE\x0aresult.rgb*=exposureLinear;\x0a#endif\x0a#ifdef\x20VIGNETTE\x0a\x0avec2\x20viewportXY=gl_FragCoord.xy*vInverseScreenSize;\x0aviewportXY=viewportXY*2.0-1.0;\x0avec3\x20vignetteXY1=vec3(viewportXY*vignetteSettings1.xy+vignetteSettings1.zw,1.0);\x0afloat\x20vignetteTerm=dot(vignetteXY1,vignetteXY1);\x0afloat\x20vignette=pow(vignetteTerm,vignetteSettings2.w);\x0a\x0avec3\x20vignetteColor=vignetteSettings2.rgb;\x0a#ifdef\x20VIGNETTEBLENDMODEMULTIPLY\x0avec3\x20vignetteColorMultiplier=mix(vignetteColor,vec3(1,1,1),vignette);\x0aresult.rgb*=vignetteColorMultiplier;\x0a#endif\x0a#ifdef\x20VIGNETTEBLENDMODEOPAQUE\x0aresult.rgb=mix(vignetteColor,result.rgb,vignette);\x0a#endif\x0a#endif\x0a#ifdef\x20TONEMAPPING\x0a#ifdef\x20TONEMAPPING_ACES\x0aresult.rgb=ACESFitted(result.rgb);\x0a#else\x0aconst\x20float\x20tonemappingCalibration=1.590579;\x0aresult.rgb=1.0-exp2(-tonemappingCalibration*result.rgb);\x0a#endif\x0a#endif\x0a\x0aresult.rgb=toGammaSpace(result.rgb);\x0aresult.rgb=saturate(result.rgb);\x0a#ifdef\x20CONTRAST\x0a\x0avec3\x20resultHighContrast=result.rgb*result.rgb*(3.0-2.0*result.rgb);\x0aif\x20(contrast<1.0)\x20{\x0a\x0aresult.rgb=mix(vec3(0.5,0.5,0.5),result.rgb,contrast);\x0a}\x20else\x20{\x0a\x0aresult.rgb=mix(result.rgb,resultHighContrast,contrast-1.0);\x0a}\x0a#endif\x0a\x0a#ifdef\x20COLORGRADING\x0avec3\x20colorTransformInput=result.rgb*colorTransformSettings.xxx+colorTransformSettings.yyy;\x0a#ifdef\x20COLORGRADING3D\x0avec3\x20colorTransformOutput=texture(txColorTransform,colorTransformInput).rgb;\x0a#else\x0avec3\x20colorTransformOutput=sampleTexture3D(txColorTransform,colorTransformInput,colorTransformSettings.yz).rgb;\x0a#endif\x0aresult.rgb=mix(result.rgb,colorTransformOutput,colorTransformSettings.www);\x0a#endif\x0a#ifdef\x20COLORCURVES\x0a\x0afloat\x20luma=getLuminance(result.rgb);\x0avec2\x20curveMix=clamp(vec2(luma*3.0-1.5,luma*-3.0+1.5),vec2(0.0),vec2(1.0));\x0avec4\x20colorCurve=vCameraColorCurveNeutral+curveMix.x*vCameraColorCurvePositive-curveMix.y*vCameraColorCurveNegative;\x0aresult.rgb*=colorCurve.rgb;\x0aresult.rgb=mix(vec3(luma),result.rgb,colorCurve.a);\x0a#endif\x0areturn\x20result;\x0a}';_0x43399b(0x5)['a']['IncludesShadersStore'][_0x511c47]=_0x63d9e4;},function(_0xda9fc3,_0x2481ff,_0x5c8a47){'use strict';var _0xf4e3b6='clipPlaneFragment',_0x3b9855='#ifdef\x20CLIPPLANE\x0aif\x20(fClipDistance>0.0)\x0a{\x0adiscard;\x0a}\x0a#endif\x0a#ifdef\x20CLIPPLANE2\x0aif\x20(fClipDistance2>0.0)\x0a{\x0adiscard;\x0a}\x0a#endif\x0a#ifdef\x20CLIPPLANE3\x0aif\x20(fClipDistance3>0.0)\x0a{\x0adiscard;\x0a}\x0a#endif\x0a#ifdef\x20CLIPPLANE4\x0aif\x20(fClipDistance4>0.0)\x0a{\x0adiscard;\x0a}\x0a#endif\x0a#ifdef\x20CLIPPLANE5\x0aif\x20(fClipDistance5>0.0)\x0a{\x0adiscard;\x0a}\x0a#endif\x0a#ifdef\x20CLIPPLANE6\x0aif\x20(fClipDistance6>0.0)\x0a{\x0adiscard;\x0a}\x0a#endif';_0x5c8a47(0x5)['a']['IncludesShadersStore'][_0xf4e3b6]=_0x3b9855;},function(_0x4f85e3,_0xe379e4,_0x4e6043){'use strict';var _0x2d278e='clipPlaneVertex',_0x97a9e9='#ifdef\x20CLIPPLANE\x0afClipDistance=dot(worldPos,vClipPlane);\x0a#endif\x0a#ifdef\x20CLIPPLANE2\x0afClipDistance2=dot(worldPos,vClipPlane2);\x0a#endif\x0a#ifdef\x20CLIPPLANE3\x0afClipDistance3=dot(worldPos,vClipPlane3);\x0a#endif\x0a#ifdef\x20CLIPPLANE4\x0afClipDistance4=dot(worldPos,vClipPlane4);\x0a#endif\x0a#ifdef\x20CLIPPLANE5\x0afClipDistance5=dot(worldPos,vClipPlane5);\x0a#endif\x0a#ifdef\x20CLIPPLANE6\x0afClipDistance6=dot(worldPos,vClipPlane6);\x0a#endif';_0x4e6043(0x5)['a']['IncludesShadersStore'][_0x2d278e]=_0x97a9e9;},function(_0x3ca859,_0x24889f,_0x39ffd9){'use strict';_0x39ffd9['d'](_0x24889f,'a',function(){return _0x21f5f1;});var _0x21f5f1=(function(){function _0x4c6949(){this['_count']=0x0,this['_data']={};}return _0x4c6949['prototype']['copyFrom']=function(_0x102557){var _0x4532f7=this;this['clear'](),_0x102557['forEach'](function(_0x38b43e,_0x356e19){return _0x4532f7['add'](_0x38b43e,_0x356e19);});},_0x4c6949['prototype']['get']=function(_0x21c4eb){var _0x866c2=this['_data'][_0x21c4eb];if(void 0x0!==_0x866c2)return _0x866c2;},_0x4c6949['prototype']['getOrAddWithFactory']=function(_0x376e00,_0x39d9e7){var _0x225025=this['get'](_0x376e00);return void 0x0!==_0x225025||(_0x225025=_0x39d9e7(_0x376e00))&&this['add'](_0x376e00,_0x225025),_0x225025;},_0x4c6949['prototype']['getOrAdd']=function(_0x538bce,_0xb72058){var _0x3b73ae=this['get'](_0x538bce);return void 0x0!==_0x3b73ae?_0x3b73ae:(this['add'](_0x538bce,_0xb72058),_0xb72058);},_0x4c6949['prototype']['contains']=function(_0x4b9e23){return void 0x0!==this['_data'][_0x4b9e23];},_0x4c6949['prototype']['add']=function(_0x3c27b5,_0x2cb2ee){return void 0x0===this['_data'][_0x3c27b5]&&(this['_data'][_0x3c27b5]=_0x2cb2ee,++this['_count'],!0x0);},_0x4c6949['prototype']['set']=function(_0x5c8f45,_0x14001b){return void 0x0!==this['_data'][_0x5c8f45]&&(this['_data'][_0x5c8f45]=_0x14001b,!0x0);},_0x4c6949['prototype']['getAndRemove']=function(_0x3d09b8){var _0x4b1c32=this['get'](_0x3d09b8);return void 0x0!==_0x4b1c32?(delete this['_data'][_0x3d09b8],--this['_count'],_0x4b1c32):null;},_0x4c6949['prototype']['remove']=function(_0x88e2cf){return!!this['contains'](_0x88e2cf)&&(delete this['_data'][_0x88e2cf],--this['_count'],!0x0);},_0x4c6949['prototype']['clear']=function(){this['_data']={},this['_count']=0x0;},Object['defineProperty'](_0x4c6949['prototype'],'count',{'get':function(){return this['_count'];},'enumerable':!0x1,'configurable':!0x0}),_0x4c6949['prototype']['forEach']=function(_0x457cac){for(var _0x5272dd in this['_data']){_0x457cac(_0x5272dd,this['_data'][_0x5272dd]);}},_0x4c6949['prototype']['first']=function(_0x1be25c){for(var _0x4436ed in this['_data']){var _0x915a93=_0x1be25c(_0x4436ed,this['_data'][_0x4436ed]);if(_0x915a93)return _0x915a93;}return null;},_0x4c6949;}());},function(_0x80a37a,_0x4a553e,_0x346ea7){'use strict';_0x346ea7['d'](_0x4a553e,'a',function(){return _0x349a70;});var _0x4ecf69=_0x346ea7(0x2c),_0x3f6fb1=_0x346ea7(0x0),_0x349a70=(function(){function _0x3721cc(_0x1c40ce,_0x3fce6f,_0x3c195d){this['center']=_0x3f6fb1['e']['Zero'](),this['centerWorld']=_0x3f6fb1['e']['Zero'](),this['minimum']=_0x3f6fb1['e']['Zero'](),this['maximum']=_0x3f6fb1['e']['Zero'](),this['reConstruct'](_0x1c40ce,_0x3fce6f,_0x3c195d);}return _0x3721cc['prototype']['reConstruct']=function(_0x1b1a3e,_0x17ea73,_0x1a1f88){this['minimum']['copyFrom'](_0x1b1a3e),this['maximum']['copyFrom'](_0x17ea73);var _0x40b7cc=_0x3f6fb1['e']['Distance'](_0x1b1a3e,_0x17ea73);_0x17ea73['addToRef'](_0x1b1a3e,this['center'])['scaleInPlace'](0.5),this['radius']=0.5*_0x40b7cc,this['_update'](_0x1a1f88||_0x3f6fb1['a']['IdentityReadOnly']);},_0x3721cc['prototype']['scale']=function(_0x25b431){var _0x4b04d4=this['radius']*_0x25b431,_0x1df83b=_0x3721cc['TmpVector3'],_0x1d2ba2=_0x1df83b[0x0]['setAll'](_0x4b04d4),_0x52cdc6=this['center']['subtractToRef'](_0x1d2ba2,_0x1df83b[0x1]),_0x147ac5=this['center']['addToRef'](_0x1d2ba2,_0x1df83b[0x2]);return this['reConstruct'](_0x52cdc6,_0x147ac5,this['_worldMatrix']),this;},_0x3721cc['prototype']['getWorldMatrix']=function(){return this['_worldMatrix'];},_0x3721cc['prototype']['_update']=function(_0x5fd53c){if(_0x5fd53c['isIdentity']())this['centerWorld']['copyFrom'](this['center']),this['radiusWorld']=this['radius'];else{_0x3f6fb1['e']['TransformCoordinatesToRef'](this['center'],_0x5fd53c,this['centerWorld']);var _0x349bd5=_0x3721cc['TmpVector3'][0x0];_0x3f6fb1['e']['TransformNormalFromFloatsToRef'](0x1,0x1,0x1,_0x5fd53c,_0x349bd5),this['radiusWorld']=Math['max'](Math['abs'](_0x349bd5['x']),Math['abs'](_0x349bd5['y']),Math['abs'](_0x349bd5['z']))*this['radius'];}},_0x3721cc['prototype']['isInFrustum']=function(_0x1750fd){for(var _0x1b34e8=this['centerWorld'],_0x1e58fb=this['radiusWorld'],_0x3cc642=0x0;_0x3cc642<0x6;_0x3cc642++)if(_0x1750fd[_0x3cc642]['dotCoordinate'](_0x1b34e8)<=-_0x1e58fb)return!0x1;return!0x0;},_0x3721cc['prototype']['isCenterInFrustum']=function(_0x23b925){for(var _0x5c6211=this['centerWorld'],_0x49c309=0x0;_0x49c309<0x6;_0x49c309++)if(_0x23b925[_0x49c309]['dotCoordinate'](_0x5c6211)<0x0)return!0x1;return!0x0;},_0x3721cc['prototype']['intersectsPoint']=function(_0x481267){var _0x10eb61=_0x3f6fb1['e']['DistanceSquared'](this['centerWorld'],_0x481267);return!(this['radiusWorld']*this['radiusWorld']<_0x10eb61);},_0x3721cc['Intersects']=function(_0x125b0f,_0x55fd3e){var _0x3133c8=_0x3f6fb1['e']['DistanceSquared'](_0x125b0f['centerWorld'],_0x55fd3e['centerWorld']),_0x7cd0dc=_0x125b0f['radiusWorld']+_0x55fd3e['radiusWorld'];return!(_0x7cd0dc*_0x7cd0dc<_0x3133c8);},_0x3721cc['TmpVector3']=_0x4ecf69['a']['BuildArray'](0x3,_0x3f6fb1['e']['Zero']),_0x3721cc;}());},function(_0x83c058,_0x2aab3e,_0x137aa6){'use strict';_0x137aa6['d'](_0x2aab3e,'a',function(){return _0x4bd82f;});var _0x4bd82f=function(_0x63eae4,_0x3c2df7,_0x7e7369){this['bu']=_0x63eae4,this['bv']=_0x3c2df7,this['distance']=_0x7e7369,this['faceId']=0x0,this['subMeshId']=0x0;};},function(_0x2dfc41,_0x4c11c7,_0x509c50){'use strict';var _0x52bd46='clipPlaneFragmentDeclaration',_0x5f07cb='#ifdef\x20CLIPPLANE\x0avarying\x20float\x20fClipDistance;\x0a#endif\x0a#ifdef\x20CLIPPLANE2\x0avarying\x20float\x20fClipDistance2;\x0a#endif\x0a#ifdef\x20CLIPPLANE3\x0avarying\x20float\x20fClipDistance3;\x0a#endif\x0a#ifdef\x20CLIPPLANE4\x0avarying\x20float\x20fClipDistance4;\x0a#endif\x0a#ifdef\x20CLIPPLANE5\x0avarying\x20float\x20fClipDistance5;\x0a#endif\x0a#ifdef\x20CLIPPLANE6\x0avarying\x20float\x20fClipDistance6;\x0a#endif';_0x509c50(0x5)['a']['IncludesShadersStore'][_0x52bd46]=_0x5f07cb;},function(_0x4884e4,_0xa3513f,_0x29da66){'use strict';var _0x3a94b1='logDepthDeclaration',_0x33d81b='#ifdef\x20LOGARITHMICDEPTH\x0auniform\x20float\x20logarithmicDepthConstant;\x0avarying\x20float\x20vFragmentDepth;\x0a#endif';_0x29da66(0x5)['a']['IncludesShadersStore'][_0x3a94b1]=_0x33d81b;},function(_0x393c74,_0x136abe,_0x285f36){'use strict';var _0x659136='clipPlaneVertexDeclaration',_0x420773='#ifdef\x20CLIPPLANE\x0auniform\x20vec4\x20vClipPlane;\x0avarying\x20float\x20fClipDistance;\x0a#endif\x0a#ifdef\x20CLIPPLANE2\x0auniform\x20vec4\x20vClipPlane2;\x0avarying\x20float\x20fClipDistance2;\x0a#endif\x0a#ifdef\x20CLIPPLANE3\x0auniform\x20vec4\x20vClipPlane3;\x0avarying\x20float\x20fClipDistance3;\x0a#endif\x0a#ifdef\x20CLIPPLANE4\x0auniform\x20vec4\x20vClipPlane4;\x0avarying\x20float\x20fClipDistance4;\x0a#endif\x0a#ifdef\x20CLIPPLANE5\x0auniform\x20vec4\x20vClipPlane5;\x0avarying\x20float\x20fClipDistance5;\x0a#endif\x0a#ifdef\x20CLIPPLANE6\x0auniform\x20vec4\x20vClipPlane6;\x0avarying\x20float\x20fClipDistance6;\x0a#endif';_0x285f36(0x5)['a']['IncludesShadersStore'][_0x659136]=_0x420773;},function(_0x42d58b,_0x3d4eb0,_0x4e146c){'use strict';_0x4e146c['d'](_0x3d4eb0,'a',function(){return _0x36f37f;});var _0x36f37f=(function(){function _0x49bc3f(){}return _0x49bc3f['prototype']['attributeProcessor']=function(_0x3cae9a){return _0x3cae9a['replace']('attribute','in');},_0x49bc3f['prototype']['varyingProcessor']=function(_0x3aa024,_0xe30078){return _0x3aa024['replace']('varying',_0xe30078?'in':'out');},_0x49bc3f['prototype']['postProcessor']=function(_0x5c65b0,_0x1e4e97,_0x42c7d4){var _0x4ac7bc=-0x1!==_0x5c65b0['search'](/#extension.+GL_EXT_draw_buffers.+require/);if(_0x5c65b0=(_0x5c65b0=_0x5c65b0['replace'](/#extension.+(GL_OVR_multiview2|GL_OES_standard_derivatives|GL_EXT_shader_texture_lod|GL_EXT_frag_depth|GL_EXT_draw_buffers).+(enable|require)/g,''))['replace'](/texture2D\s*\(/g,'texture('),_0x42c7d4)_0x5c65b0=(_0x5c65b0=(_0x5c65b0=(_0x5c65b0=(_0x5c65b0=(_0x5c65b0=(_0x5c65b0=_0x5c65b0['replace'](/texture2DLodEXT\s*\(/g,'textureLod('))['replace'](/textureCubeLodEXT\s*\(/g,'textureLod('))['replace'](/textureCube\s*\(/g,'texture('))['replace'](/gl_FragDepthEXT/g,'gl_FragDepth'))['replace'](/gl_FragColor/g,'glFragColor'))['replace'](/gl_FragData/g,'glFragData'))['replace'](/void\s+?main\s*\(/g,(_0x4ac7bc?'':'out\x20vec4\x20glFragColor;\x0a')+'void\x20main(');else{if(-0x1!==_0x1e4e97['indexOf']('#define\x20MULTIVIEW'))return'#extension\x20GL_OVR_multiview2\x20:\x20require\x0alayout\x20(num_views\x20=\x202)\x20in;\x0a'+_0x5c65b0;}return _0x5c65b0;},_0x49bc3f;}());},function(_0x2612af,_0x122df7,_0x539643){'use strict';_0x539643['d'](_0x122df7,'a',function(){return _0x4653fb;});var _0x4653fb=(function(){function _0x466eec(){}return _0x466eec['BindClipPlane']=function(_0x2140c8,_0x481f8d){if(_0x481f8d['clipPlane']){var _0x37f7bf=_0x481f8d['clipPlane'];_0x2140c8['setFloat4']('vClipPlane',_0x37f7bf['normal']['x'],_0x37f7bf['normal']['y'],_0x37f7bf['normal']['z'],_0x37f7bf['d']);}_0x481f8d['clipPlane2']&&(_0x37f7bf=_0x481f8d['clipPlane2'],_0x2140c8['setFloat4']('vClipPlane2',_0x37f7bf['normal']['x'],_0x37f7bf['normal']['y'],_0x37f7bf['normal']['z'],_0x37f7bf['d'])),_0x481f8d['clipPlane3']&&(_0x37f7bf=_0x481f8d['clipPlane3'],_0x2140c8['setFloat4']('vClipPlane3',_0x37f7bf['normal']['x'],_0x37f7bf['normal']['y'],_0x37f7bf['normal']['z'],_0x37f7bf['d'])),_0x481f8d['clipPlane4']&&(_0x37f7bf=_0x481f8d['clipPlane4'],_0x2140c8['setFloat4']('vClipPlane4',_0x37f7bf['normal']['x'],_0x37f7bf['normal']['y'],_0x37f7bf['normal']['z'],_0x37f7bf['d'])),_0x481f8d['clipPlane5']&&(_0x37f7bf=_0x481f8d['clipPlane5'],_0x2140c8['setFloat4']('vClipPlane5',_0x37f7bf['normal']['x'],_0x37f7bf['normal']['y'],_0x37f7bf['normal']['z'],_0x37f7bf['d'])),_0x481f8d['clipPlane6']&&(_0x37f7bf=_0x481f8d['clipPlane6'],_0x2140c8['setFloat4']('vClipPlane6',_0x37f7bf['normal']['x'],_0x37f7bf['normal']['y'],_0x37f7bf['normal']['z'],_0x37f7bf['d']));},_0x466eec;}());},function(_0x5a49a3,_0x5ad69a,_0x8a39b9){'use strict';_0x8a39b9['d'](_0x5ad69a,'a',function(){return _0xa387ee;});var _0xa387ee=(function(){function _0x516d17(){}return _0x516d17['RandomId']=function(){return'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'['replace'](/[xy]/g,function(_0x325541){var _0x5d8c95=0x10*Math['random']()|0x0;return('x'===_0x325541?_0x5d8c95:0x3&_0x5d8c95|0x8)['toString'](0x10);});},_0x516d17;}());},function(_0x298d53,_0x484135,_0x3f0422){'use strict';_0x3f0422['d'](_0x484135,'a',function(){return _0x2408f4;});var _0x5cc1a3=_0x3f0422(0x1),_0x5156dc=_0x3f0422(0x3),_0x23bf3c=_0x3f0422(0x9),_0x2408f4=(function(){function _0x44f1d5(){this['_dirty']=!0x0,this['_tempColor']=new _0x23bf3c['b'](0x0,0x0,0x0,0x0),this['_globalCurve']=new _0x23bf3c['b'](0x0,0x0,0x0,0x0),this['_highlightsCurve']=new _0x23bf3c['b'](0x0,0x0,0x0,0x0),this['_midtonesCurve']=new _0x23bf3c['b'](0x0,0x0,0x0,0x0),this['_shadowsCurve']=new _0x23bf3c['b'](0x0,0x0,0x0,0x0),this['_positiveCurve']=new _0x23bf3c['b'](0x0,0x0,0x0,0x0),this['_negativeCurve']=new _0x23bf3c['b'](0x0,0x0,0x0,0x0),this['_globalHue']=0x1e,this['_globalDensity']=0x0,this['_globalSaturation']=0x0,this['_globalExposure']=0x0,this['_highlightsHue']=0x1e,this['_highlightsDensity']=0x0,this['_highlightsSaturation']=0x0,this['_highlightsExposure']=0x0,this['_midtonesHue']=0x1e,this['_midtonesDensity']=0x0,this['_midtonesSaturation']=0x0,this['_midtonesExposure']=0x0,this['_shadowsHue']=0x1e,this['_shadowsDensity']=0x0,this['_shadowsSaturation']=0x0,this['_shadowsExposure']=0x0;}return Object['defineProperty'](_0x44f1d5['prototype'],'globalHue',{'get':function(){return this['_globalHue'];},'set':function(_0x105076){this['_globalHue']=_0x105076,this['_dirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x44f1d5['prototype'],'globalDensity',{'get':function(){return this['_globalDensity'];},'set':function(_0x329ff1){this['_globalDensity']=_0x329ff1,this['_dirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x44f1d5['prototype'],'globalSaturation',{'get':function(){return this['_globalSaturation'];},'set':function(_0xc8dd1a){this['_globalSaturation']=_0xc8dd1a,this['_dirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x44f1d5['prototype'],'globalExposure',{'get':function(){return this['_globalExposure'];},'set':function(_0x2192ea){this['_globalExposure']=_0x2192ea,this['_dirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x44f1d5['prototype'],'highlightsHue',{'get':function(){return this['_highlightsHue'];},'set':function(_0x281317){this['_highlightsHue']=_0x281317,this['_dirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x44f1d5['prototype'],'highlightsDensity',{'get':function(){return this['_highlightsDensity'];},'set':function(_0x585b36){this['_highlightsDensity']=_0x585b36,this['_dirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x44f1d5['prototype'],'highlightsSaturation',{'get':function(){return this['_highlightsSaturation'];},'set':function(_0x4cf827){this['_highlightsSaturation']=_0x4cf827,this['_dirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x44f1d5['prototype'],'highlightsExposure',{'get':function(){return this['_highlightsExposure'];},'set':function(_0x595538){this['_highlightsExposure']=_0x595538,this['_dirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x44f1d5['prototype'],'midtonesHue',{'get':function(){return this['_midtonesHue'];},'set':function(_0x5c4635){this['_midtonesHue']=_0x5c4635,this['_dirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x44f1d5['prototype'],'midtonesDensity',{'get':function(){return this['_midtonesDensity'];},'set':function(_0x42992a){this['_midtonesDensity']=_0x42992a,this['_dirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x44f1d5['prototype'],'midtonesSaturation',{'get':function(){return this['_midtonesSaturation'];},'set':function(_0xce6354){this['_midtonesSaturation']=_0xce6354,this['_dirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x44f1d5['prototype'],'midtonesExposure',{'get':function(){return this['_midtonesExposure'];},'set':function(_0x4f7eaa){this['_midtonesExposure']=_0x4f7eaa,this['_dirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x44f1d5['prototype'],'shadowsHue',{'get':function(){return this['_shadowsHue'];},'set':function(_0x5a0df5){this['_shadowsHue']=_0x5a0df5,this['_dirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x44f1d5['prototype'],'shadowsDensity',{'get':function(){return this['_shadowsDensity'];},'set':function(_0x3d4aee){this['_shadowsDensity']=_0x3d4aee,this['_dirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x44f1d5['prototype'],'shadowsSaturation',{'get':function(){return this['_shadowsSaturation'];},'set':function(_0x2c3f8f){this['_shadowsSaturation']=_0x2c3f8f,this['_dirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x44f1d5['prototype'],'shadowsExposure',{'get':function(){return this['_shadowsExposure'];},'set':function(_0x56cdf7){this['_shadowsExposure']=_0x56cdf7,this['_dirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),_0x44f1d5['prototype']['getClassName']=function(){return'ColorCurves';},_0x44f1d5['Bind']=function(_0x3523ff,_0x3c3d8b,_0x16dd2b,_0x38c5f5,_0x4e643f){void 0x0===_0x16dd2b&&(_0x16dd2b='vCameraColorCurvePositive'),void 0x0===_0x38c5f5&&(_0x38c5f5='vCameraColorCurveNeutral'),void 0x0===_0x4e643f&&(_0x4e643f='vCameraColorCurveNegative'),_0x3523ff['_dirty']&&(_0x3523ff['_dirty']=!0x1,_0x3523ff['getColorGradingDataToRef'](_0x3523ff['_globalHue'],_0x3523ff['_globalDensity'],_0x3523ff['_globalSaturation'],_0x3523ff['_globalExposure'],_0x3523ff['_globalCurve']),_0x3523ff['getColorGradingDataToRef'](_0x3523ff['_highlightsHue'],_0x3523ff['_highlightsDensity'],_0x3523ff['_highlightsSaturation'],_0x3523ff['_highlightsExposure'],_0x3523ff['_tempColor']),_0x3523ff['_tempColor']['multiplyToRef'](_0x3523ff['_globalCurve'],_0x3523ff['_highlightsCurve']),_0x3523ff['getColorGradingDataToRef'](_0x3523ff['_midtonesHue'],_0x3523ff['_midtonesDensity'],_0x3523ff['_midtonesSaturation'],_0x3523ff['_midtonesExposure'],_0x3523ff['_tempColor']),_0x3523ff['_tempColor']['multiplyToRef'](_0x3523ff['_globalCurve'],_0x3523ff['_midtonesCurve']),_0x3523ff['getColorGradingDataToRef'](_0x3523ff['_shadowsHue'],_0x3523ff['_shadowsDensity'],_0x3523ff['_shadowsSaturation'],_0x3523ff['_shadowsExposure'],_0x3523ff['_tempColor']),_0x3523ff['_tempColor']['multiplyToRef'](_0x3523ff['_globalCurve'],_0x3523ff['_shadowsCurve']),_0x3523ff['_highlightsCurve']['subtractToRef'](_0x3523ff['_midtonesCurve'],_0x3523ff['_positiveCurve']),_0x3523ff['_midtonesCurve']['subtractToRef'](_0x3523ff['_shadowsCurve'],_0x3523ff['_negativeCurve'])),_0x3c3d8b&&(_0x3c3d8b['setFloat4'](_0x16dd2b,_0x3523ff['_positiveCurve']['r'],_0x3523ff['_positiveCurve']['g'],_0x3523ff['_positiveCurve']['b'],_0x3523ff['_positiveCurve']['a']),_0x3c3d8b['setFloat4'](_0x38c5f5,_0x3523ff['_midtonesCurve']['r'],_0x3523ff['_midtonesCurve']['g'],_0x3523ff['_midtonesCurve']['b'],_0x3523ff['_midtonesCurve']['a']),_0x3c3d8b['setFloat4'](_0x4e643f,_0x3523ff['_negativeCurve']['r'],_0x3523ff['_negativeCurve']['g'],_0x3523ff['_negativeCurve']['b'],_0x3523ff['_negativeCurve']['a']));},_0x44f1d5['PrepareUniforms']=function(_0x12458b){_0x12458b['push']('vCameraColorCurveNeutral','vCameraColorCurvePositive','vCameraColorCurveNegative');},_0x44f1d5['prototype']['getColorGradingDataToRef']=function(_0x3bea19,_0x51a160,_0xec86aa,_0xa7d69e,_0x4d099c){null!=_0x3bea19&&(_0x3bea19=_0x44f1d5['clamp'](_0x3bea19,0x0,0x168),_0x51a160=_0x44f1d5['clamp'](_0x51a160,-0x64,0x64),_0xec86aa=_0x44f1d5['clamp'](_0xec86aa,-0x64,0x64),_0xa7d69e=_0x44f1d5['clamp'](_0xa7d69e,-0x64,0x64),_0x51a160=_0x44f1d5['applyColorGradingSliderNonlinear'](_0x51a160),_0x51a160*=0.5,_0xa7d69e=_0x44f1d5['applyColorGradingSliderNonlinear'](_0xa7d69e),_0x51a160<0x0&&(_0x51a160*=-0x1,_0x3bea19=(_0x3bea19+0xb4)%0x168),_0x44f1d5['fromHSBToRef'](_0x3bea19,_0x51a160,0x32+0.25*_0xa7d69e,_0x4d099c),_0x4d099c['scaleToRef'](0x2,_0x4d099c),_0x4d099c['a']=0x1+0.01*_0xec86aa);},_0x44f1d5['applyColorGradingSliderNonlinear']=function(_0x4df4a5){_0x4df4a5/=0x64;var _0x4605d8=Math['abs'](_0x4df4a5);return _0x4605d8=Math['pow'](_0x4605d8,0x2),_0x4df4a5<0x0&&(_0x4605d8*=-0x1),_0x4605d8*=0x64;},_0x44f1d5['fromHSBToRef']=function(_0x3daf45,_0x5d87e7,_0x492fce,_0x44cd04){var _0x40bbaf=_0x44f1d5['clamp'](_0x3daf45,0x0,0x168),_0x26182a=_0x44f1d5['clamp'](_0x5d87e7/0x64,0x0,0x1),_0x15dbd8=_0x44f1d5['clamp'](_0x492fce/0x64,0x0,0x1);if(0x0===_0x26182a)_0x44cd04['r']=_0x15dbd8,_0x44cd04['g']=_0x15dbd8,_0x44cd04['b']=_0x15dbd8;else{_0x40bbaf/=0x3c;var _0x2cc048=Math['floor'](_0x40bbaf),_0xc2d8df=_0x40bbaf-_0x2cc048,_0x229f9f=_0x15dbd8*(0x1-_0x26182a),_0x28ce24=_0x15dbd8*(0x1-_0x26182a*_0xc2d8df),_0x9929da=_0x15dbd8*(0x1-_0x26182a*(0x1-_0xc2d8df));switch(_0x2cc048){case 0x0:_0x44cd04['r']=_0x15dbd8,_0x44cd04['g']=_0x9929da,_0x44cd04['b']=_0x229f9f;break;case 0x1:_0x44cd04['r']=_0x28ce24,_0x44cd04['g']=_0x15dbd8,_0x44cd04['b']=_0x229f9f;break;case 0x2:_0x44cd04['r']=_0x229f9f,_0x44cd04['g']=_0x15dbd8,_0x44cd04['b']=_0x9929da;break;case 0x3:_0x44cd04['r']=_0x229f9f,_0x44cd04['g']=_0x28ce24,_0x44cd04['b']=_0x15dbd8;break;case 0x4:_0x44cd04['r']=_0x9929da,_0x44cd04['g']=_0x229f9f,_0x44cd04['b']=_0x15dbd8;break;default:_0x44cd04['r']=_0x15dbd8,_0x44cd04['g']=_0x229f9f,_0x44cd04['b']=_0x28ce24;}}_0x44cd04['a']=0x1;},_0x44f1d5['clamp']=function(_0x2fac1b,_0x474d80,_0x1c3062){return Math['min'](Math['max'](_0x2fac1b,_0x474d80),_0x1c3062);},_0x44f1d5['prototype']['clone']=function(){return _0x5156dc['a']['Clone'](function(){return new _0x44f1d5();},this);},_0x44f1d5['prototype']['serialize']=function(){return _0x5156dc['a']['Serialize'](this);},_0x44f1d5['Parse']=function(_0x2fc96c){return _0x5156dc['a']['Parse'](function(){return new _0x44f1d5();},_0x2fc96c,null,null);},Object(_0x5cc1a3['c'])([Object(_0x5156dc['c'])()],_0x44f1d5['prototype'],'_globalHue',void 0x0),Object(_0x5cc1a3['c'])([Object(_0x5156dc['c'])()],_0x44f1d5['prototype'],'_globalDensity',void 0x0),Object(_0x5cc1a3['c'])([Object(_0x5156dc['c'])()],_0x44f1d5['prototype'],'_globalSaturation',void 0x0),Object(_0x5cc1a3['c'])([Object(_0x5156dc['c'])()],_0x44f1d5['prototype'],'_globalExposure',void 0x0),Object(_0x5cc1a3['c'])([Object(_0x5156dc['c'])()],_0x44f1d5['prototype'],'_highlightsHue',void 0x0),Object(_0x5cc1a3['c'])([Object(_0x5156dc['c'])()],_0x44f1d5['prototype'],'_highlightsDensity',void 0x0),Object(_0x5cc1a3['c'])([Object(_0x5156dc['c'])()],_0x44f1d5['prototype'],'_highlightsSaturation',void 0x0),Object(_0x5cc1a3['c'])([Object(_0x5156dc['c'])()],_0x44f1d5['prototype'],'_highlightsExposure',void 0x0),Object(_0x5cc1a3['c'])([Object(_0x5156dc['c'])()],_0x44f1d5['prototype'],'_midtonesHue',void 0x0),Object(_0x5cc1a3['c'])([Object(_0x5156dc['c'])()],_0x44f1d5['prototype'],'_midtonesDensity',void 0x0),Object(_0x5cc1a3['c'])([Object(_0x5156dc['c'])()],_0x44f1d5['prototype'],'_midtonesSaturation',void 0x0),Object(_0x5cc1a3['c'])([Object(_0x5156dc['c'])()],_0x44f1d5['prototype'],'_midtonesExposure',void 0x0),_0x44f1d5;}());_0x5156dc['a']['_ColorCurvesParser']=_0x2408f4['Parse'];},function(_0x4cb194,_0x3f8ed1,_0x48410d){'use strict';_0x48410d['d'](_0x3f8ed1,'a',function(){return _0x3ad1ce;});var _0x4e2b8c=_0x48410d(0x8),_0x3511c3=_0x48410d(0xb),_0x3ad1ce=(function(){function _0x67279f(){}return _0x67279f['Instantiate']=function(_0x1b20f7){if(this['RegisteredExternalClasses']&&this['RegisteredExternalClasses'][_0x1b20f7])return this['RegisteredExternalClasses'][_0x1b20f7];var _0x31a14e=_0x3511c3['a']['GetClass'](_0x1b20f7);if(_0x31a14e)return _0x31a14e;_0x4e2b8c['a']['Warn'](_0x1b20f7+'\x20not\x20found,\x20you\x20may\x20have\x20missed\x20an\x20import.');for(var _0x11d8ad=_0x1b20f7['split']('.'),_0x22908f=window||this,_0x4386b0=0x0,_0x229de4=_0x11d8ad['length'];_0x4386b0<_0x229de4;_0x4386b0++)_0x22908f=_0x22908f[_0x11d8ad[_0x4386b0]];return'function'!=typeof _0x22908f?null:_0x22908f;},_0x67279f['RegisteredExternalClasses']={},_0x67279f;}());},function(_0x585327,_0x4d2495,_0x45c97b){'use strict';var _0x56cb87=_0x45c97b(0x1a),_0x44ec27=_0x45c97b(0x2);_0x56cb87['a']['prototype']['setAlphaConstants']=function(_0x15e794,_0x27cb0b,_0x473bb9,_0x2d7c1e){this['_alphaState']['setAlphaBlendConstants'](_0x15e794,_0x27cb0b,_0x473bb9,_0x2d7c1e);},_0x56cb87['a']['prototype']['setAlphaMode']=function(_0x3e5e42,_0x3f4e1f){if(void 0x0===_0x3f4e1f&&(_0x3f4e1f=!0x1),this['_alphaMode']!==_0x3e5e42){switch(_0x3e5e42){case _0x44ec27['a']['ALPHA_DISABLE']:this['_alphaState']['alphaBlend']=!0x1;break;case _0x44ec27['a']['ALPHA_PREMULTIPLIED']:this['_alphaState']['setAlphaBlendFunctionParameters'](this['_gl']['ONE'],this['_gl']['ONE_MINUS_SRC_ALPHA'],this['_gl']['ONE'],this['_gl']['ONE']),this['_alphaState']['alphaBlend']=!0x0;break;case _0x44ec27['a']['ALPHA_PREMULTIPLIED_PORTERDUFF']:this['_alphaState']['setAlphaBlendFunctionParameters'](this['_gl']['ONE'],this['_gl']['ONE_MINUS_SRC_ALPHA'],this['_gl']['ONE'],this['_gl']['ONE_MINUS_SRC_ALPHA']),this['_alphaState']['alphaBlend']=!0x0;break;case _0x44ec27['a']['ALPHA_COMBINE']:this['_alphaState']['setAlphaBlendFunctionParameters'](this['_gl']['SRC_ALPHA'],this['_gl']['ONE_MINUS_SRC_ALPHA'],this['_gl']['ONE'],this['_gl']['ONE']),this['_alphaState']['alphaBlend']=!0x0;break;case _0x44ec27['a']['ALPHA_ONEONE']:this['_alphaState']['setAlphaBlendFunctionParameters'](this['_gl']['ONE'],this['_gl']['ONE'],this['_gl']['ZERO'],this['_gl']['ONE']),this['_alphaState']['alphaBlend']=!0x0;break;case _0x44ec27['a']['ALPHA_ADD']:this['_alphaState']['setAlphaBlendFunctionParameters'](this['_gl']['SRC_ALPHA'],this['_gl']['ONE'],this['_gl']['ZERO'],this['_gl']['ONE']),this['_alphaState']['alphaBlend']=!0x0;break;case _0x44ec27['a']['ALPHA_SUBTRACT']:this['_alphaState']['setAlphaBlendFunctionParameters'](this['_gl']['ZERO'],this['_gl']['ONE_MINUS_SRC_COLOR'],this['_gl']['ONE'],this['_gl']['ONE']),this['_alphaState']['alphaBlend']=!0x0;break;case _0x44ec27['a']['ALPHA_MULTIPLY']:this['_alphaState']['setAlphaBlendFunctionParameters'](this['_gl']['DST_COLOR'],this['_gl']['ZERO'],this['_gl']['ONE'],this['_gl']['ONE']),this['_alphaState']['alphaBlend']=!0x0;break;case _0x44ec27['a']['ALPHA_MAXIMIZED']:this['_alphaState']['setAlphaBlendFunctionParameters'](this['_gl']['SRC_ALPHA'],this['_gl']['ONE_MINUS_SRC_COLOR'],this['_gl']['ONE'],this['_gl']['ONE']),this['_alphaState']['alphaBlend']=!0x0;break;case _0x44ec27['a']['ALPHA_INTERPOLATE']:this['_alphaState']['setAlphaBlendFunctionParameters'](this['_gl']['CONSTANT_COLOR'],this['_gl']['ONE_MINUS_CONSTANT_COLOR'],this['_gl']['CONSTANT_ALPHA'],this['_gl']['ONE_MINUS_CONSTANT_ALPHA']),this['_alphaState']['alphaBlend']=!0x0;break;case _0x44ec27['a']['ALPHA_SCREENMODE']:this['_alphaState']['setAlphaBlendFunctionParameters'](this['_gl']['ONE'],this['_gl']['ONE_MINUS_SRC_COLOR'],this['_gl']['ONE'],this['_gl']['ONE_MINUS_SRC_ALPHA']),this['_alphaState']['alphaBlend']=!0x0;break;case _0x44ec27['a']['ALPHA_ONEONE_ONEONE']:this['_alphaState']['setAlphaBlendFunctionParameters'](this['_gl']['ONE'],this['_gl']['ONE'],this['_gl']['ONE'],this['_gl']['ONE']),this['_alphaState']['alphaBlend']=!0x0;break;case _0x44ec27['a']['ALPHA_ALPHATOCOLOR']:this['_alphaState']['setAlphaBlendFunctionParameters'](this['_gl']['DST_ALPHA'],this['_gl']['ONE'],this['_gl']['ZERO'],this['_gl']['ZERO']),this['_alphaState']['alphaBlend']=!0x0;break;case _0x44ec27['a']['ALPHA_REVERSEONEMINUS']:this['_alphaState']['setAlphaBlendFunctionParameters'](this['_gl']['ONE_MINUS_DST_COLOR'],this['_gl']['ONE_MINUS_SRC_COLOR'],this['_gl']['ONE_MINUS_DST_ALPHA'],this['_gl']['ONE_MINUS_SRC_ALPHA']),this['_alphaState']['alphaBlend']=!0x0;break;case _0x44ec27['a']['ALPHA_SRC_DSTONEMINUSSRCALPHA']:this['_alphaState']['setAlphaBlendFunctionParameters'](this['_gl']['ONE'],this['_gl']['ONE_MINUS_SRC_ALPHA'],this['_gl']['ONE'],this['_gl']['ONE_MINUS_SRC_ALPHA']),this['_alphaState']['alphaBlend']=!0x0;break;case _0x44ec27['a']['ALPHA_ONEONE_ONEZERO']:this['_alphaState']['setAlphaBlendFunctionParameters'](this['_gl']['ONE'],this['_gl']['ONE'],this['_gl']['ONE'],this['_gl']['ZERO']),this['_alphaState']['alphaBlend']=!0x0;break;case _0x44ec27['a']['ALPHA_EXCLUSION']:this['_alphaState']['setAlphaBlendFunctionParameters'](this['_gl']['ONE_MINUS_DST_COLOR'],this['_gl']['ONE_MINUS_SRC_COLOR'],this['_gl']['ZERO'],this['_gl']['ONE']),this['_alphaState']['alphaBlend']=!0x0;}_0x3f4e1f||(this['depthCullingState']['depthMask']=_0x3e5e42===_0x44ec27['a']['ALPHA_DISABLE']),this['_alphaMode']=_0x3e5e42;}},_0x56cb87['a']['prototype']['getAlphaMode']=function(){return this['_alphaMode'];},_0x56cb87['a']['prototype']['setAlphaEquation']=function(_0x1d9415){if(this['_alphaEquation']!==_0x1d9415){switch(_0x1d9415){case _0x44ec27['a']['ALPHA_EQUATION_ADD']:this['_alphaState']['setAlphaEquationParameters'](this['_gl']['FUNC_ADD'],this['_gl']['FUNC_ADD']);break;case _0x44ec27['a']['ALPHA_EQUATION_SUBSTRACT']:this['_alphaState']['setAlphaEquationParameters'](this['_gl']['FUNC_SUBTRACT'],this['_gl']['FUNC_SUBTRACT']);break;case _0x44ec27['a']['ALPHA_EQUATION_REVERSE_SUBTRACT']:this['_alphaState']['setAlphaEquationParameters'](this['_gl']['FUNC_REVERSE_SUBTRACT'],this['_gl']['FUNC_REVERSE_SUBTRACT']);break;case _0x44ec27['a']['ALPHA_EQUATION_MAX']:this['_alphaState']['setAlphaEquationParameters'](this['_gl']['MAX'],this['_gl']['MAX']);break;case _0x44ec27['a']['ALPHA_EQUATION_MIN']:this['_alphaState']['setAlphaEquationParameters'](this['_gl']['MIN'],this['_gl']['MIN']);break;case _0x44ec27['a']['ALPHA_EQUATION_DARKEN']:this['_alphaState']['setAlphaEquationParameters'](this['_gl']['MIN'],this['_gl']['FUNC_ADD']);}this['_alphaEquation']=_0x1d9415;}},_0x56cb87['a']['prototype']['getAlphaEquation']=function(){return this['_alphaEquation'];};},function(_0x4e2eb8,_0x2a41f1,_0x779d52){'use strict';var _0x4db6fe=_0x779d52(0x1a);_0x4db6fe['a']['prototype']['updateDynamicIndexBuffer']=function(_0x480a27,_0x431903,_0x262676){var _0x4978ea;void 0x0===_0x262676&&(_0x262676=0x0),this['_currentBoundBuffer'][this['_gl']['ELEMENT_ARRAY_BUFFER']]=null,this['bindIndexBuffer'](_0x480a27),_0x4978ea=_0x431903 instanceof Uint16Array||_0x431903 instanceof Uint32Array?_0x431903:_0x480a27['is32Bits']?new Uint32Array(_0x431903):new Uint16Array(_0x431903),this['_gl']['bufferData'](this['_gl']['ELEMENT_ARRAY_BUFFER'],_0x4978ea,this['_gl']['DYNAMIC_DRAW']),this['_resetIndexBufferBinding']();},_0x4db6fe['a']['prototype']['updateDynamicVertexBuffer']=function(_0x2a6eba,_0x334931,_0x4ac4f1,_0x23a16d){this['bindArrayBuffer'](_0x2a6eba),void 0x0===_0x4ac4f1&&(_0x4ac4f1=0x0);var _0x413576=_0x334931['length']||_0x334931['byteLength'];void 0x0===_0x23a16d||_0x23a16d>=_0x413576&&0x0===_0x4ac4f1?_0x334931 instanceof Array?this['_gl']['bufferSubData'](this['_gl']['ARRAY_BUFFER'],_0x4ac4f1,new Float32Array(_0x334931)):this['_gl']['bufferSubData'](this['_gl']['ARRAY_BUFFER'],_0x4ac4f1,_0x334931):_0x334931 instanceof Array?this['_gl']['bufferSubData'](this['_gl']['ARRAY_BUFFER'],0x0,new Float32Array(_0x334931)['subarray'](_0x4ac4f1,_0x4ac4f1+_0x23a16d)):(_0x334931=_0x334931 instanceof ArrayBuffer?new Uint8Array(_0x334931,_0x4ac4f1,_0x23a16d):new Uint8Array(_0x334931['buffer'],_0x334931['byteOffset']+_0x4ac4f1,_0x23a16d),this['_gl']['bufferSubData'](this['_gl']['ARRAY_BUFFER'],0x0,_0x334931)),this['_resetVertexBufferBinding']();};},function(_0x23e504,_0xd19e19,_0x5731d2){'use strict';var _0x377a70='fogFragmentDeclaration',_0x18333e='#ifdef\x20FOG\x0a#define\x20FOGMODE_NONE\x200.\x0a#define\x20FOGMODE_EXP\x201.\x0a#define\x20FOGMODE_EXP2\x202.\x0a#define\x20FOGMODE_LINEAR\x203.\x0a#define\x20E\x202.71828\x0auniform\x20vec4\x20vFogInfos;\x0auniform\x20vec3\x20vFogColor;\x0avarying\x20vec3\x20vFogDistance;\x0afloat\x20CalcFogFactor()\x0a{\x0afloat\x20fogCoeff=1.0;\x0afloat\x20fogStart=vFogInfos.y;\x0afloat\x20fogEnd=vFogInfos.z;\x0afloat\x20fogDensity=vFogInfos.w;\x0afloat\x20fogDistance=length(vFogDistance);\x0aif\x20(FOGMODE_LINEAR\x20==\x20vFogInfos.x)\x0a{\x0afogCoeff=(fogEnd-fogDistance)/(fogEnd-fogStart);\x0a}\x0aelse\x20if\x20(FOGMODE_EXP\x20==\x20vFogInfos.x)\x0a{\x0afogCoeff=1.0/pow(E,fogDistance*fogDensity);\x0a}\x0aelse\x20if\x20(FOGMODE_EXP2\x20==\x20vFogInfos.x)\x0a{\x0afogCoeff=1.0/pow(E,fogDistance*fogDistance*fogDensity*fogDensity);\x0a}\x0areturn\x20clamp(fogCoeff,0.0,1.0);\x0a}\x0a#endif';_0x5731d2(0x5)['a']['IncludesShadersStore'][_0x377a70]=_0x18333e;},function(_0x74a9d0,_0x4041b1,_0x38a127){'use strict';var _0x4178fc=_0x38a127(0x1a),_0x23f84d=_0x38a127(0x1b);_0x4178fc['a']['prototype']['createDynamicTexture']=function(_0xf7c41e,_0x42e1a8,_0x507e7f,_0x359277){var _0xe99528=new _0x23f84d['a'](this,_0x23f84d['b']['Dynamic']);return _0xe99528['baseWidth']=_0xf7c41e,_0xe99528['baseHeight']=_0x42e1a8,_0x507e7f&&(_0xf7c41e=this['needPOTTextures']?_0x4178fc['a']['GetExponentOfTwo'](_0xf7c41e,this['_caps']['maxTextureSize']):_0xf7c41e,_0x42e1a8=this['needPOTTextures']?_0x4178fc['a']['GetExponentOfTwo'](_0x42e1a8,this['_caps']['maxTextureSize']):_0x42e1a8),_0xe99528['width']=_0xf7c41e,_0xe99528['height']=_0x42e1a8,_0xe99528['isReady']=!0x1,_0xe99528['generateMipMaps']=_0x507e7f,_0xe99528['samplingMode']=_0x359277,this['updateTextureSamplingMode'](_0x359277,_0xe99528),this['_internalTexturesCache']['push'](_0xe99528),_0xe99528;},_0x4178fc['a']['prototype']['updateDynamicTexture']=function(_0x1d9b7b,_0x47c7c5,_0x35a65f,_0x4176a6,_0x5269ed,_0x1d994e){if(void 0x0===_0x4176a6&&(_0x4176a6=!0x1),void 0x0===_0x1d994e&&(_0x1d994e=!0x1),_0x1d9b7b){var _0x26e80e=this['_gl'],_0x363a42=_0x26e80e['TEXTURE_2D'],_0x8ed14c=this['_bindTextureDirectly'](_0x363a42,_0x1d9b7b,!0x0,_0x1d994e);this['_unpackFlipY'](void 0x0===_0x35a65f?_0x1d9b7b['invertY']:_0x35a65f),_0x4176a6&&_0x26e80e['pixelStorei'](_0x26e80e['UNPACK_PREMULTIPLY_ALPHA_WEBGL'],0x1);var _0x32a086=this['_getWebGLTextureType'](_0x1d9b7b['type']),_0x301f54=this['_getInternalFormat'](_0x5269ed||_0x1d9b7b['format']),_0x46f43e=this['_getRGBABufferInternalSizedFormat'](_0x1d9b7b['type'],_0x301f54);_0x26e80e['texImage2D'](_0x363a42,0x0,_0x46f43e,_0x301f54,_0x32a086,_0x47c7c5),_0x1d9b7b['generateMipMaps']&&_0x26e80e['generateMipmap'](_0x363a42),_0x8ed14c||this['_bindTextureDirectly'](_0x363a42,null),_0x4176a6&&_0x26e80e['pixelStorei'](_0x26e80e['UNPACK_PREMULTIPLY_ALPHA_WEBGL'],0x0),_0x1d9b7b['isReady']=!0x0;}};},function(_0x3560ee,_0x235062,_0x162675){'use strict';_0x162675['r'](_0x235062),_0x162675['d'](_0x235062,'AbstractScene',function(){return _0x3598db['a'];}),_0x162675['d'](_0x235062,'AbstractActionManager',function(){return _0xd232ee['a'];}),_0x162675['d'](_0x235062,'Action',function(){return _0x26efb5;}),_0x162675['d'](_0x235062,'ActionEvent',function(){return _0x3b70ca['a'];}),_0x162675['d'](_0x235062,'ActionManager',function(){return _0x443d42;}),_0x162675['d'](_0x235062,'Condition',function(){return _0x572956;}),_0x162675['d'](_0x235062,'ValueCondition',function(){return _0xc057a3;}),_0x162675['d'](_0x235062,'PredicateCondition',function(){return _0x4d409d;}),_0x162675['d'](_0x235062,'StateCondition',function(){return _0x2e9761;}),_0x162675['d'](_0x235062,'SwitchBooleanAction',function(){return _0x39dbfd;}),_0x162675['d'](_0x235062,'SetStateAction',function(){return _0x5e7530;}),_0x162675['d'](_0x235062,'SetValueAction',function(){return _0x20fbfe;}),_0x162675['d'](_0x235062,'IncrementValueAction',function(){return _0x56aa79;}),_0x162675['d'](_0x235062,'PlayAnimationAction',function(){return _0x24f2e5;}),_0x162675['d'](_0x235062,'StopAnimationAction',function(){return _0x595277;}),_0x162675['d'](_0x235062,'DoNothingAction',function(){return _0xc309ab;}),_0x162675['d'](_0x235062,'CombineAction',function(){return _0x23107d;}),_0x162675['d'](_0x235062,'ExecuteCodeAction',function(){return _0x1051bf;}),_0x162675['d'](_0x235062,'SetParentAction',function(){return _0x1e29bf;}),_0x162675['d'](_0x235062,'PlaySoundAction',function(){return _0x1272a3;}),_0x162675['d'](_0x235062,'StopSoundAction',function(){return _0x479f71;}),_0x162675['d'](_0x235062,'InterpolateValueAction',function(){return _0x323857;}),_0x162675['d'](_0x235062,'Animatable',function(){return _0x13e125;}),_0x162675['d'](_0x235062,'_IAnimationState',function(){return _0x106da3;}),_0x162675['d'](_0x235062,'Animation',function(){return _0x1b0498;}),_0x162675['d'](_0x235062,'TargetedAnimation',function(){return _0x37db12;}),_0x162675['d'](_0x235062,'AnimationGroup',function(){return _0x433562;}),_0x162675['d'](_0x235062,'AnimationPropertiesOverride',function(){return _0x2d9106;}),_0x162675['d'](_0x235062,'EasingFunction',function(){return _0x4ba918;}),_0x162675['d'](_0x235062,'CircleEase',function(){return _0x66297f;}),_0x162675['d'](_0x235062,'BackEase',function(){return _0x161f26;}),_0x162675['d'](_0x235062,'BounceEase',function(){return _0x63d35e;}),_0x162675['d'](_0x235062,'CubicEase',function(){return _0x4c6fcb;}),_0x162675['d'](_0x235062,'ElasticEase',function(){return _0x1e3d8f;}),_0x162675['d'](_0x235062,'ExponentialEase',function(){return _0x5d36b0;}),_0x162675['d'](_0x235062,'PowerEase',function(){return _0x254ce2;}),_0x162675['d'](_0x235062,'QuadraticEase',function(){return _0xb5f1d;}),_0x162675['d'](_0x235062,'QuarticEase',function(){return _0x4f49f4;}),_0x162675['d'](_0x235062,'QuinticEase',function(){return _0x4d366f;}),_0x162675['d'](_0x235062,'SineEase',function(){return _0x4c852a;}),_0x162675['d'](_0x235062,'BezierCurveEase',function(){return _0x3a605e;}),_0x162675['d'](_0x235062,'RuntimeAnimation',function(){return _0xfb2c56;}),_0x162675['d'](_0x235062,'AnimationEvent',function(){return _0x36110e;}),_0x162675['d'](_0x235062,'AnimationKeyInterpolation',function(){return _0x3c3574;}),_0x162675['d'](_0x235062,'AnimationRange',function(){return _0x44ee32;}),_0x162675['d'](_0x235062,'KeepAssets',function(){return _0x406ff9;}),_0x162675['d'](_0x235062,'InstantiatedEntries',function(){return _0x25bb37;}),_0x162675['d'](_0x235062,'AssetContainer',function(){return _0x3a6778;}),_0x162675['d'](_0x235062,'Analyser',function(){return _0x35fcc7;}),_0x162675['d'](_0x235062,'AudioEngine',function(){return _0x288a7d;}),_0x162675['d'](_0x235062,'AudioSceneComponent',function(){return _0x1db746;}),_0x162675['d'](_0x235062,'Sound',function(){return _0x13741a;}),_0x162675['d'](_0x235062,'SoundTrack',function(){return _0x11da99;}),_0x162675['d'](_0x235062,'WeightedSound',function(){return _0x44c93c;}),_0x162675['d'](_0x235062,'AutoRotationBehavior',function(){return _0x47605d;}),_0x162675['d'](_0x235062,'BouncingBehavior',function(){return _0x3e9056;}),_0x162675['d'](_0x235062,'FramingBehavior',function(){return _0x593fc5;}),_0x162675['d'](_0x235062,'AttachToBoxBehavior',function(){return _0x202ace;}),_0x162675['d'](_0x235062,'FadeInOutBehavior',function(){return _0x264a18;}),_0x162675['d'](_0x235062,'MultiPointerScaleBehavior',function(){return _0x3c3fa9;}),_0x162675['d'](_0x235062,'PointerDragBehavior',function(){return _0x356c6d['a'];}),_0x162675['d'](_0x235062,'SixDofDragBehavior',function(){return _0x2f1fdc;}),_0x162675['d'](_0x235062,'Bone',function(){return _0x4df88a;}),_0x162675['d'](_0x235062,'BoneIKController',function(){return _0x2d9be4;}),_0x162675['d'](_0x235062,'BoneLookController',function(){return _0xdce04c;}),_0x162675['d'](_0x235062,'Skeleton',function(){return _0x4198a1;}),_0x162675['d'](_0x235062,'ArcRotateCameraGamepadInput',function(){return _0x588ef7;}),_0x162675['d'](_0x235062,'ArcRotateCameraKeyboardMoveInput',function(){return _0x139502;}),_0x162675['d'](_0x235062,'ArcRotateCameraMouseWheelInput',function(){return _0x25cb17;}),_0x162675['d'](_0x235062,'ArcRotateCameraPointersInput',function(){return _0x14bb32;}),_0x162675['d'](_0x235062,'ArcRotateCameraVRDeviceOrientationInput',function(){return _0x3c682d;}),_0x162675['d'](_0x235062,'FlyCameraKeyboardInput',function(){return _0x3ec62e;}),_0x162675['d'](_0x235062,'FlyCameraMouseInput',function(){return _0x2c3b9f;}),_0x162675['d'](_0x235062,'FollowCameraKeyboardMoveInput',function(){return _0xceeb14;}),_0x162675['d'](_0x235062,'FollowCameraMouseWheelInput',function(){return _0x41b4ed;}),_0x162675['d'](_0x235062,'FollowCameraPointersInput',function(){return _0xbf36c3;}),_0x162675['d'](_0x235062,'FreeCameraDeviceOrientationInput',function(){return _0x49f234;}),_0x162675['d'](_0x235062,'FreeCameraGamepadInput',function(){return _0x47ef9b;}),_0x162675['d'](_0x235062,'FreeCameraKeyboardMoveInput',function(){return _0x45d6ae;}),_0x162675['d'](_0x235062,'FreeCameraMouseInput',function(){return _0x51dcc9;}),_0x162675['d'](_0x235062,'FreeCameraMouseWheelInput',function(){return _0x192268;}),_0x162675['d'](_0x235062,'FreeCameraTouchInput',function(){return _0x4a54c9;}),_0x162675['d'](_0x235062,'FreeCameraVirtualJoystickInput',function(){return _0x359913;}),_0x162675['d'](_0x235062,'CameraInputTypes',function(){return _0x2f54c9;}),_0x162675['d'](_0x235062,'CameraInputsManager',function(){return _0x4ad380;}),_0x162675['d'](_0x235062,'Camera',function(){return _0x568729['a'];}),_0x162675['d'](_0x235062,'TargetCamera',function(){return _0x5f32ae;}),_0x162675['d'](_0x235062,'FreeCamera',function(){return _0x5625b9;}),_0x162675['d'](_0x235062,'FreeCameraInputsManager',function(){return _0x3d384c;}),_0x162675['d'](_0x235062,'TouchCamera',function(){return _0x593a2c;}),_0x162675['d'](_0x235062,'ArcRotateCamera',function(){return _0xe57e08;}),_0x162675['d'](_0x235062,'ArcRotateCameraInputsManager',function(){return _0x1f548e;}),_0x162675['d'](_0x235062,'DeviceOrientationCamera',function(){return _0x2de943;}),_0x162675['d'](_0x235062,'FlyCamera',function(){return _0x194bfa;}),_0x162675['d'](_0x235062,'FlyCameraInputsManager',function(){return _0x131ccb;}),_0x162675['d'](_0x235062,'FollowCamera',function(){return _0x356cee;}),_0x162675['d'](_0x235062,'ArcFollowCamera',function(){return _0x56be32;}),_0x162675['d'](_0x235062,'FollowCameraInputsManager',function(){return _0x5f353d;}),_0x162675['d'](_0x235062,'GamepadCamera',function(){return _0x3b87d8;}),_0x162675['d'](_0x235062,'AnaglyphArcRotateCamera',function(){return _0x504aa7;}),_0x162675['d'](_0x235062,'AnaglyphFreeCamera',function(){return _0x421e11;}),_0x162675['d'](_0x235062,'AnaglyphGamepadCamera',function(){return _0x3644d1;}),_0x162675['d'](_0x235062,'AnaglyphUniversalCamera',function(){return _0x2a1642;}),_0x162675['d'](_0x235062,'StereoscopicArcRotateCamera',function(){return _0x3e1a78;}),_0x162675['d'](_0x235062,'StereoscopicFreeCamera',function(){return _0x339591;}),_0x162675['d'](_0x235062,'StereoscopicGamepadCamera',function(){return _0x148052;}),_0x162675['d'](_0x235062,'StereoscopicUniversalCamera',function(){return _0x1716b9;}),_0x162675['d'](_0x235062,'UniversalCamera',function(){return _0x2d65de;}),_0x162675['d'](_0x235062,'VirtualJoysticksCamera',function(){return _0x562b40;}),_0x162675['d'](_0x235062,'VRCameraMetrics',function(){return _0x521280;}),_0x162675['d'](_0x235062,'VRDeviceOrientationArcRotateCamera',function(){return _0x3dfa73;}),_0x162675['d'](_0x235062,'VRDeviceOrientationFreeCamera',function(){return _0x4fea40;}),_0x162675['d'](_0x235062,'VRDeviceOrientationGamepadCamera',function(){return _0x7f0a4e;}),_0x162675['d'](_0x235062,'OnAfterEnteringVRObservableEvent',function(){return _0x23547a;}),_0x162675['d'](_0x235062,'VRExperienceHelper',function(){return _0x17f3dd;}),_0x162675['d'](_0x235062,'WebVRFreeCamera',function(){return _0x3c14c8;}),_0x162675['d'](_0x235062,'Collider',function(){return _0x24c000;}),_0x162675['d'](_0x235062,'DefaultCollisionCoordinator',function(){return _0x235a56;}),_0x162675['d'](_0x235062,'PickingInfo',function(){return _0x1fa05e['a'];}),_0x162675['d'](_0x235062,'IntersectionInfo',function(){return _0xa2bfd7['a'];}),_0x162675['d'](_0x235062,'_MeshCollisionData',function(){return _0x136422['a'];}),_0x162675['d'](_0x235062,'BoundingBox',function(){return _0x52db25['a'];}),_0x162675['d'](_0x235062,'BoundingInfo',function(){return _0x386a4b['a'];}),_0x162675['d'](_0x235062,'BoundingSphere',function(){return _0x16d1ed['a'];}),_0x162675['d'](_0x235062,'Octree',function(){return _0x1eea99;}),_0x162675['d'](_0x235062,'OctreeBlock',function(){return _0xa1ff28;}),_0x162675['d'](_0x235062,'OctreeSceneComponent',function(){return _0x3ba06b;}),_0x162675['d'](_0x235062,'Ray',function(){return _0x36fb4d['a'];}),_0x162675['d'](_0x235062,'AxesViewer',function(){return _0x41585b['AxesViewer'];}),_0x162675['d'](_0x235062,'BoneAxesViewer',function(){return _0x41585b['BoneAxesViewer'];}),_0x162675['d'](_0x235062,'DebugLayerTab',function(){return _0x41585b['DebugLayerTab'];}),_0x162675['d'](_0x235062,'DebugLayer',function(){return _0x41585b['DebugLayer'];}),_0x162675['d'](_0x235062,'PhysicsViewer',function(){return _0x41585b['PhysicsViewer'];}),_0x162675['d'](_0x235062,'RayHelper',function(){return _0x41585b['RayHelper'];}),_0x162675['d'](_0x235062,'SkeletonViewer',function(){return _0x41585b['SkeletonViewer'];}),_0x162675['d'](_0x235062,'DeviceInputSystem',function(){return _0x1e32b7;}),_0x162675['d'](_0x235062,'DeviceType',function(){return _0x120523;}),_0x162675['d'](_0x235062,'PointerInput',function(){return _0x12f0a8;}),_0x162675['d'](_0x235062,'DualShockInput',function(){return _0x5c5e14;}),_0x162675['d'](_0x235062,'XboxInput',function(){return _0x57f5a3;}),_0x162675['d'](_0x235062,'SwitchInput',function(){return _0x33d188;}),_0x162675['d'](_0x235062,'DeviceSource',function(){return _0x2285a0;}),_0x162675['d'](_0x235062,'DeviceSourceManager',function(){return _0x195d3a;}),_0x162675['d'](_0x235062,'Constants',function(){return _0x2103ba['a'];}),_0x162675['d'](_0x235062,'ThinEngine',function(){return _0x26966b['a'];}),_0x162675['d'](_0x235062,'Engine',function(){return _0x300b38['a'];}),_0x162675['d'](_0x235062,'EngineStore',function(){return _0x44b9ce['a'];}),_0x162675['d'](_0x235062,'NullEngineOptions',function(){return _0x813e33['b'];}),_0x162675['d'](_0x235062,'NullEngine',function(){return _0x813e33['a'];}),_0x162675['d'](_0x235062,'_OcclusionDataStorage',function(){return _0x286eca;}),_0x162675['d'](_0x235062,'_forceTransformFeedbackToBundle',function(){return _0x215eb9;}),_0x162675['d'](_0x235062,'EngineView',function(){return _0x15af5c;}),_0x162675['d'](_0x235062,'WebGLPipelineContext',function(){return _0x2bf27f['a'];}),_0x162675['d'](_0x235062,'WebGL2ShaderProcessor',function(){return _0x304729['a'];}),_0x162675['d'](_0x235062,'NativeEngine',function(){return _0xa5ed76;}),_0x162675['d'](_0x235062,'ShaderCodeInliner',function(){return _0x1e1646;}),_0x162675['d'](_0x235062,'PerformanceConfigurator',function(){return _0x134549['a'];}),_0x162675['d'](_0x235062,'KeyboardEventTypes',function(){return _0x2ae55c['a'];}),_0x162675['d'](_0x235062,'KeyboardInfo',function(){return _0x2ae55c['b'];}),_0x162675['d'](_0x235062,'KeyboardInfoPre',function(){return _0x2ae55c['c'];}),_0x162675['d'](_0x235062,'PointerEventTypes',function(){return _0x1cb628['a'];}),_0x162675['d'](_0x235062,'PointerInfoBase',function(){return _0x1cb628['c'];}),_0x162675['d'](_0x235062,'PointerInfoPre',function(){return _0x1cb628['d'];}),_0x162675['d'](_0x235062,'PointerInfo',function(){return _0x1cb628['b'];}),_0x162675['d'](_0x235062,'ClipboardEventTypes',function(){return _0x109356;}),_0x162675['d'](_0x235062,'ClipboardInfo',function(){return _0x1860e1;}),_0x162675['d'](_0x235062,'DaydreamController',function(){return _0x45be87;}),_0x162675['d'](_0x235062,'GearVRController',function(){return _0x40f55a;}),_0x162675['d'](_0x235062,'GenericController',function(){return _0x2157a4;}),_0x162675['d'](_0x235062,'OculusTouchController',function(){return _0xc25c2e;}),_0x162675['d'](_0x235062,'PoseEnabledControllerType',function(){return _0x1a2757;}),_0x162675['d'](_0x235062,'PoseEnabledControllerHelper',function(){return _0x14684f;}),_0x162675['d'](_0x235062,'PoseEnabledController',function(){return _0x3c2ea8;}),_0x162675['d'](_0x235062,'ViveController',function(){return _0x5dadcc;}),_0x162675['d'](_0x235062,'WebVRController',function(){return _0x5dfec2;}),_0x162675['d'](_0x235062,'WindowsMotionController',function(){return _0x34565c;}),_0x162675['d'](_0x235062,'XRWindowsMotionController',function(){return _0x45654e;}),_0x162675['d'](_0x235062,'StickValues',function(){return _0x5ddebf;}),_0x162675['d'](_0x235062,'Gamepad',function(){return _0x56ffd0;}),_0x162675['d'](_0x235062,'GenericPad',function(){return _0x1275ec;}),_0x162675['d'](_0x235062,'GamepadManager',function(){return _0x258956;}),_0x162675['d'](_0x235062,'GamepadSystemSceneComponent',function(){return _0x986b92;}),_0x162675['d'](_0x235062,'Xbox360Button',function(){return _0x40fdb4;}),_0x162675['d'](_0x235062,'Xbox360Dpad',function(){return _0x57b714;}),_0x162675['d'](_0x235062,'Xbox360Pad',function(){return _0x4fe65c;}),_0x162675['d'](_0x235062,'DualShockButton',function(){return _0x1d97e6;}),_0x162675['d'](_0x235062,'DualShockDpad',function(){return _0x4edecf;}),_0x162675['d'](_0x235062,'DualShockPad',function(){return _0x5e3294;}),_0x162675['d'](_0x235062,'AxisDragGizmo',function(){return _0x1b97f2['a'];}),_0x162675['d'](_0x235062,'AxisScaleGizmo',function(){return _0x1f64e7;}),_0x162675['d'](_0x235062,'BoundingBoxGizmo',function(){return _0x322a76;}),_0x162675['d'](_0x235062,'Gizmo',function(){return _0x417dc8['a'];}),_0x162675['d'](_0x235062,'GizmoManager',function(){return _0x97daf7;}),_0x162675['d'](_0x235062,'PlaneRotationGizmo',function(){return _0x4e6561;}),_0x162675['d'](_0x235062,'PositionGizmo',function(){return _0xccbb24;}),_0x162675['d'](_0x235062,'RotationGizmo',function(){return _0xbdd3b4;}),_0x162675['d'](_0x235062,'ScaleGizmo',function(){return _0x5e0e1f;}),_0x162675['d'](_0x235062,'LightGizmo',function(){return _0x499c61;}),_0x162675['d'](_0x235062,'CameraGizmo',function(){return _0x4a61d0;}),_0x162675['d'](_0x235062,'PlaneDragGizmo',function(){return _0x371e63;}),_0x162675['d'](_0x235062,'EnvironmentHelper',function(){return _0xec7a4b;}),_0x162675['d'](_0x235062,'PhotoDome',function(){return _0x567fac;}),_0x162675['d'](_0x235062,'_forceSceneHelpersToBundle',function(){return _0x130649;}),_0x162675['d'](_0x235062,'VideoDome',function(){return _0xcbcd01;}),_0x162675['d'](_0x235062,'EngineInstrumentation',function(){return _0x235e55;}),_0x162675['d'](_0x235062,'SceneInstrumentation',function(){return _0xe36a6b;}),_0x162675['d'](_0x235062,'_TimeToken',function(){return _0x17597a;}),_0x162675['d'](_0x235062,'EffectLayer',function(){return _0x1fb328;}),_0x162675['d'](_0x235062,'EffectLayerSceneComponent',function(){return _0x3c6a4a;}),_0x162675['d'](_0x235062,'GlowLayer',function(){return _0x5ca1a8;}),_0x162675['d'](_0x235062,'HighlightLayer',function(){return _0x2429ed;}),_0x162675['d'](_0x235062,'Layer',function(){return _0x688512;}),_0x162675['d'](_0x235062,'LayerSceneComponent',function(){return _0xf67129;}),_0x162675['d'](_0x235062,'LensFlare',function(){return _0x5390a4;}),_0x162675['d'](_0x235062,'LensFlareSystem',function(){return _0x23fcdc;}),_0x162675['d'](_0x235062,'LensFlareSystemSceneComponent',function(){return _0x28c767;}),_0x162675['d'](_0x235062,'Light',function(){return _0x4e3e4a['a'];}),_0x162675['d'](_0x235062,'ShadowLight',function(){return _0x9de826;}),_0x162675['d'](_0x235062,'ShadowGenerator',function(){return _0x4f0fba;}),_0x162675['d'](_0x235062,'CascadedShadowGenerator',function(){return _0x252b01;}),_0x162675['d'](_0x235062,'ShadowGeneratorSceneComponent',function(){return _0x215a77;}),_0x162675['d'](_0x235062,'DirectionalLight',function(){return _0x4367f2;}),_0x162675['d'](_0x235062,'HemisphericLight',function(){return _0xb2c680['a'];}),_0x162675['d'](_0x235062,'PointLight',function(){return _0x4c489f;}),_0x162675['d'](_0x235062,'SpotLight',function(){return _0x27087d;}),_0x162675['d'](_0x235062,'DefaultLoadingScreen',function(){return _0x379bf0;}),_0x162675['d'](_0x235062,'_BabylonLoaderRegistered',function(){return _0x3fddea;}),_0x162675['d'](_0x235062,'BabylonFileLoaderConfiguration',function(){return _0x4f9256;}),_0x162675['d'](_0x235062,'SceneLoaderAnimationGroupLoadingMode',function(){return _0x18784f;}),_0x162675['d'](_0x235062,'SceneLoader',function(){return _0x5de01e;}),_0x162675['d'](_0x235062,'SceneLoaderFlags',function(){return _0x396102['a'];}),_0x162675['d'](_0x235062,'BackgroundMaterial',function(){return _0x4fe332;}),_0x162675['d'](_0x235062,'ColorCurves',function(){return _0x133a53['a'];}),_0x162675['d'](_0x235062,'EffectFallbacks',function(){return _0x1603d9['a'];}),_0x162675['d'](_0x235062,'Effect',function(){return _0x494b01['a'];}),_0x162675['d'](_0x235062,'FresnelParameters',function(){return _0x541f6d;}),_0x162675['d'](_0x235062,'ImageProcessingConfigurationDefines',function(){return _0x3f08d6['b'];}),_0x162675['d'](_0x235062,'ImageProcessingConfiguration',function(){return _0x3f08d6['a'];}),_0x162675['d'](_0x235062,'Material',function(){return _0x33c2e5['a'];}),_0x162675['d'](_0x235062,'MaterialDefines',function(){return _0x35e5d5['a'];}),_0x162675['d'](_0x235062,'ThinMaterialHelper',function(){return _0x51ff42['a'];}),_0x162675['d'](_0x235062,'MaterialHelper',function(){return _0x464f31['a'];}),_0x162675['d'](_0x235062,'MultiMaterial',function(){return _0x5a4b2b['a'];}),_0x162675['d'](_0x235062,'PBRMaterialDefines',function(){return _0x4fc3ba;}),_0x162675['d'](_0x235062,'PBRBaseMaterial',function(){return _0x136113;}),_0x162675['d'](_0x235062,'PBRBaseSimpleMaterial',function(){return _0x532fe4;}),_0x162675['d'](_0x235062,'PBRMaterial',function(){return _0x4cd87a;}),_0x162675['d'](_0x235062,'PBRMetallicRoughnessMaterial',function(){return _0x495b0c;}),_0x162675['d'](_0x235062,'PBRSpecularGlossinessMaterial',function(){return _0x51895b;}),_0x162675['d'](_0x235062,'PushMaterial',function(){return _0x1bb048['a'];}),_0x162675['d'](_0x235062,'ShaderMaterial',function(){return _0x14ee07['a'];}),_0x162675['d'](_0x235062,'StandardMaterialDefines',function(){return _0x5905ab['b'];}),_0x162675['d'](_0x235062,'StandardMaterial',function(){return _0x5905ab['a'];}),_0x162675['d'](_0x235062,'BaseTexture',function(){return _0x2268ea['a'];}),_0x162675['d'](_0x235062,'ColorGradingTexture',function(){return _0x4b03c9;}),_0x162675['d'](_0x235062,'CubeTexture',function(){return _0x33892f;}),_0x162675['d'](_0x235062,'DynamicTexture',function(){return _0x41f891['a'];}),_0x162675['d'](_0x235062,'EquiRectangularCubeTexture',function(){return _0x5beaea;}),_0x162675['d'](_0x235062,'HDRFiltering',function(){return _0x43f45b;}),_0x162675['d'](_0x235062,'HDRCubeTexture',function(){return _0x26e1bc;}),_0x162675['d'](_0x235062,'HtmlElementTexture',function(){return _0x2104d5;}),_0x162675['d'](_0x235062,'InternalTextureSource',function(){return _0x21ea74['b'];}),_0x162675['d'](_0x235062,'InternalTexture',function(){return _0x21ea74['a'];}),_0x162675['d'](_0x235062,'_DDSTextureLoader',function(){return _0x5ca044;}),_0x162675['d'](_0x235062,'_ENVTextureLoader',function(){return _0x1efa48;}),_0x162675['d'](_0x235062,'_KTXTextureLoader',function(){return _0x351007;}),_0x162675['d'](_0x235062,'_TGATextureLoader',function(){return _0x1c1333;}),_0x162675['d'](_0x235062,'_BasisTextureLoader',function(){return _0x5da230;}),_0x162675['d'](_0x235062,'MirrorTexture',function(){return _0xb1e723;}),_0x162675['d'](_0x235062,'MultiRenderTarget',function(){return _0x152eb4;}),_0x162675['d'](_0x235062,'TexturePacker',function(){return _0x3c3d20;}),_0x162675['d'](_0x235062,'TexturePackerFrame',function(){return _0x5e85bf;}),_0x162675['d'](_0x235062,'CustomProceduralTexture',function(){return _0x4a929e;}),_0x162675['d'](_0x235062,'NoiseProceduralTexture',function(){return _0x355742;}),_0x162675['d'](_0x235062,'ProceduralTexture',function(){return _0x27f07d;}),_0x162675['d'](_0x235062,'ProceduralTextureSceneComponent',function(){return _0x1d57c9;}),_0x162675['d'](_0x235062,'RawCubeTexture',function(){return _0x51721d;}),_0x162675['d'](_0x235062,'RawTexture',function(){return _0x1a05d8;}),_0x162675['d'](_0x235062,'RawTexture2DArray',function(){return _0x208bae;}),_0x162675['d'](_0x235062,'RawTexture3D',function(){return _0x1f7293;}),_0x162675['d'](_0x235062,'RefractionTexture',function(){return _0x9cf052;}),_0x162675['d'](_0x235062,'RenderTargetTexture',function(){return _0x310f87;}),_0x162675['d'](_0x235062,'Texture',function(){return _0xaf3c80['a'];}),_0x162675['d'](_0x235062,'VideoTexture',function(){return _0x411196;}),_0x162675['d'](_0x235062,'UniformBuffer',function(){return _0x640faf['a'];}),_0x162675['d'](_0x235062,'MaterialFlags',function(){return _0x4e6421['a'];}),_0x162675['d'](_0x235062,'NodeMaterialBlockTargets',function(){return _0x4e54a1;}),_0x162675['d'](_0x235062,'NodeMaterialBlockConnectionPointTypes',function(){return _0x3bb339;}),_0x162675['d'](_0x235062,'NodeMaterialBlockConnectionPointMode',function(){return _0x370a71;}),_0x162675['d'](_0x235062,'NodeMaterialSystemValues',function(){return _0x509c82;}),_0x162675['d'](_0x235062,'NodeMaterialModes',function(){return _0x608fec;}),_0x162675['d'](_0x235062,'NodeMaterialConnectionPointCompatibilityStates',function(){return _0x530b1e;}),_0x162675['d'](_0x235062,'NodeMaterialConnectionPointDirection',function(){return _0x13ce46;}),_0x162675['d'](_0x235062,'NodeMaterialConnectionPoint',function(){return _0x33b7d2;}),_0x162675['d'](_0x235062,'NodeMaterialBlock',function(){return _0x52300e;}),_0x162675['d'](_0x235062,'NodeMaterialDefines',function(){return _0x412d6e;}),_0x162675['d'](_0x235062,'NodeMaterial',function(){return _0x457d3e;}),_0x162675['d'](_0x235062,'VertexOutputBlock',function(){return _0x5b4f0e;}),_0x162675['d'](_0x235062,'BonesBlock',function(){return _0x13d2bc;}),_0x162675['d'](_0x235062,'InstancesBlock',function(){return _0xc2c26b;}),_0x162675['d'](_0x235062,'MorphTargetsBlock',function(){return _0x1d5af4;}),_0x162675['d'](_0x235062,'LightInformationBlock',function(){return _0x52442e;}),_0x162675['d'](_0x235062,'FragmentOutputBlock',function(){return _0x1f2748;}),_0x162675['d'](_0x235062,'ImageProcessingBlock',function(){return _0x2a97bd;}),_0x162675['d'](_0x235062,'PerturbNormalBlock',function(){return _0x2f04d9;}),_0x162675['d'](_0x235062,'DiscardBlock',function(){return _0xb71fa6;}),_0x162675['d'](_0x235062,'FrontFacingBlock',function(){return _0x3cabc9;}),_0x162675['d'](_0x235062,'DerivativeBlock',function(){return _0x514d99;}),_0x162675['d'](_0x235062,'FragCoordBlock',function(){return _0x1e93a8;}),_0x162675['d'](_0x235062,'ScreenSizeBlock',function(){return _0x466e76;}),_0x162675['d'](_0x235062,'FogBlock',function(){return _0x13668a;}),_0x162675['d'](_0x235062,'LightBlock',function(){return _0x531a4e;}),_0x162675['d'](_0x235062,'TextureBlock',function(){return _0x3c5db7;}),_0x162675['d'](_0x235062,'ReflectionTextureBlock',function(){return _0x8e8494;}),_0x162675['d'](_0x235062,'CurrentScreenBlock',function(){return _0x6d15a7;}),_0x162675['d'](_0x235062,'InputBlock',function(){return _0x581182;}),_0x162675['d'](_0x235062,'AnimatedInputBlockTypes',function(){return _0x5b0248;}),_0x162675['d'](_0x235062,'MultiplyBlock',function(){return _0x4b8ff3;}),_0x162675['d'](_0x235062,'AddBlock',function(){return _0x1c572e;}),_0x162675['d'](_0x235062,'ScaleBlock',function(){return _0xcf3d9e;}),_0x162675['d'](_0x235062,'ClampBlock',function(){return _0x10c1c3;}),_0x162675['d'](_0x235062,'CrossBlock',function(){return _0xe40533;}),_0x162675['d'](_0x235062,'DotBlock',function(){return _0x4ce394;}),_0x162675['d'](_0x235062,'TransformBlock',function(){return _0x3fcbd4;}),_0x162675['d'](_0x235062,'RemapBlock',function(){return _0x662ea4;}),_0x162675['d'](_0x235062,'NormalizeBlock',function(){return _0x3b6eff;}),_0x162675['d'](_0x235062,'TrigonometryBlockOperations',function(){return _0x4872c7;}),_0x162675['d'](_0x235062,'TrigonometryBlock',function(){return _0xfe96fa;}),_0x162675['d'](_0x235062,'ColorMergerBlock',function(){return _0x8f09b8;}),_0x162675['d'](_0x235062,'VectorMergerBlock',function(){return _0x2ef6e9;}),_0x162675['d'](_0x235062,'ColorSplitterBlock',function(){return _0x48f9fa;}),_0x162675['d'](_0x235062,'VectorSplitterBlock',function(){return _0x41cae2;}),_0x162675['d'](_0x235062,'LerpBlock',function(){return _0x5b8f17;}),_0x162675['d'](_0x235062,'DivideBlock',function(){return _0x3b4794;}),_0x162675['d'](_0x235062,'SubtractBlock',function(){return _0x3c393b;}),_0x162675['d'](_0x235062,'StepBlock',function(){return _0x56ce29;}),_0x162675['d'](_0x235062,'OneMinusBlock',function(){return _0x3fe18e;}),_0x162675['d'](_0x235062,'ViewDirectionBlock',function(){return _0x565aad;}),_0x162675['d'](_0x235062,'FresnelBlock',function(){return _0x5adb42;}),_0x162675['d'](_0x235062,'MaxBlock',function(){return _0x1f615c;}),_0x162675['d'](_0x235062,'MinBlock',function(){return _0x258c26;}),_0x162675['d'](_0x235062,'DistanceBlock',function(){return _0x5a3952;}),_0x162675['d'](_0x235062,'LengthBlock',function(){return _0x46caad;}),_0x162675['d'](_0x235062,'NegateBlock',function(){return _0x567545;}),_0x162675['d'](_0x235062,'PowBlock',function(){return _0x49ea90;}),_0x162675['d'](_0x235062,'RandomNumberBlock',function(){return _0x1cb448;}),_0x162675['d'](_0x235062,'ArcTan2Block',function(){return _0x4dcf7e;}),_0x162675['d'](_0x235062,'SmoothStepBlock',function(){return _0x37b2a8;}),_0x162675['d'](_0x235062,'ReciprocalBlock',function(){return _0x4a9bbf;}),_0x162675['d'](_0x235062,'ReplaceColorBlock',function(){return _0x30500a;}),_0x162675['d'](_0x235062,'PosterizeBlock',function(){return _0x3ab45d;}),_0x162675['d'](_0x235062,'WaveBlockKind',function(){return _0x377874;}),_0x162675['d'](_0x235062,'WaveBlock',function(){return _0xe1c3a7;}),_0x162675['d'](_0x235062,'GradientBlockColorStep',function(){return _0x56d334;}),_0x162675['d'](_0x235062,'GradientBlock',function(){return _0x3acb6e;}),_0x162675['d'](_0x235062,'NLerpBlock',function(){return _0x54a4fd;}),_0x162675['d'](_0x235062,'WorleyNoise3DBlock',function(){return _0x443124;}),_0x162675['d'](_0x235062,'SimplexPerlin3DBlock',function(){return _0x5903ed;}),_0x162675['d'](_0x235062,'NormalBlendBlock',function(){return _0x3094c6;}),_0x162675['d'](_0x235062,'Rotate2dBlock',function(){return _0x4f2bda;}),_0x162675['d'](_0x235062,'ReflectBlock',function(){return _0x166480;}),_0x162675['d'](_0x235062,'RefractBlock',function(){return _0x4519fd;}),_0x162675['d'](_0x235062,'DesaturateBlock',function(){return _0x4f0b7;}),_0x162675['d'](_0x235062,'PBRMetallicRoughnessBlock',function(){return _0x36709a;}),_0x162675['d'](_0x235062,'SheenBlock',function(){return _0x44b0e3;}),_0x162675['d'](_0x235062,'AnisotropyBlock',function(){return _0xf3db90;}),_0x162675['d'](_0x235062,'ReflectionBlock',function(){return _0x3d3908;}),_0x162675['d'](_0x235062,'ClearCoatBlock',function(){return _0x487217;}),_0x162675['d'](_0x235062,'RefractionBlock',function(){return _0x43bd0d;}),_0x162675['d'](_0x235062,'SubSurfaceBlock',function(){return _0xc68b25;}),_0x162675['d'](_0x235062,'ParticleTextureBlock',function(){return _0x56dc96;}),_0x162675['d'](_0x235062,'ParticleRampGradientBlock',function(){return _0x154efb;}),_0x162675['d'](_0x235062,'ParticleBlendMultiplyBlock',function(){return _0x4bafb1;}),_0x162675['d'](_0x235062,'ModBlock',function(){return _0x51bca1;}),_0x162675['d'](_0x235062,'NodeMaterialOptimizer',function(){return _0x6d9930;}),_0x162675['d'](_0x235062,'PropertyTypeForEdition',function(){return _0x4bd31d;}),_0x162675['d'](_0x235062,'editableInPropertyPage',function(){return _0x148e9b;}),_0x162675['d'](_0x235062,'EffectRenderer',function(){return _0x30619e;}),_0x162675['d'](_0x235062,'EffectWrapper',function(){return _0x15c8ff;}),_0x162675['d'](_0x235062,'ShadowDepthWrapper',function(){return _0x5e1309;}),_0x162675['d'](_0x235062,'Scalar',function(){return _0x4a0cf0['a'];}),_0x162675['d'](_0x235062,'extractMinAndMaxIndexed',function(){return _0x595214['b'];}),_0x162675['d'](_0x235062,'extractMinAndMax',function(){return _0x595214['a'];}),_0x162675['d'](_0x235062,'Space',function(){return _0x4a79a2['c'];}),_0x162675['d'](_0x235062,'Axis',function(){return _0x4a79a2['a'];}),_0x162675['d'](_0x235062,'Coordinate',function(){return _0x4a79a2['b'];}),_0x162675['d'](_0x235062,'Color3',function(){return _0x39310d['a'];}),_0x162675['d'](_0x235062,'Color4',function(){return _0x39310d['b'];}),_0x162675['d'](_0x235062,'TmpColors',function(){return _0x39310d['c'];}),_0x162675['d'](_0x235062,'ToGammaSpace',function(){return _0x27da6e['b'];}),_0x162675['d'](_0x235062,'ToLinearSpace',function(){return _0x27da6e['c'];}),_0x162675['d'](_0x235062,'Epsilon',function(){return _0x27da6e['a'];}),_0x162675['d'](_0x235062,'Frustum',function(){return _0xd246c2['a'];}),_0x162675['d'](_0x235062,'Orientation',function(){return _0x5e9f26['e'];}),_0x162675['d'](_0x235062,'BezierCurve',function(){return _0x5e9f26['c'];}),_0x162675['d'](_0x235062,'Angle',function(){return _0x5e9f26['a'];}),_0x162675['d'](_0x235062,'Arc2',function(){return _0x5e9f26['b'];}),_0x162675['d'](_0x235062,'Path2',function(){return _0x5e9f26['f'];}),_0x162675['d'](_0x235062,'Path3D',function(){return _0x5e9f26['g'];}),_0x162675['d'](_0x235062,'Curve3',function(){return _0x5e9f26['d'];}),_0x162675['d'](_0x235062,'Plane',function(){return _0x5c8dd6['a'];}),_0x162675['d'](_0x235062,'Size',function(){return _0x417f41['a'];}),_0x162675['d'](_0x235062,'Vector2',function(){return _0x74d525['d'];}),_0x162675['d'](_0x235062,'Vector3',function(){return _0x74d525['e'];}),_0x162675['d'](_0x235062,'Vector4',function(){return _0x74d525['f'];}),_0x162675['d'](_0x235062,'Quaternion',function(){return _0x74d525['b'];}),_0x162675['d'](_0x235062,'Matrix',function(){return _0x74d525['a'];}),_0x162675['d'](_0x235062,'TmpVectors',function(){return _0x74d525['c'];}),_0x162675['d'](_0x235062,'PositionNormalVertex',function(){return _0x5a7f8f;}),_0x162675['d'](_0x235062,'PositionNormalTextureVertex',function(){return _0x440fac;}),_0x162675['d'](_0x235062,'Viewport',function(){return _0x4548b0['a'];}),_0x162675['d'](_0x235062,'SphericalHarmonics',function(){return _0x44d982;}),_0x162675['d'](_0x235062,'SphericalPolynomial',function(){return _0x23d472;}),_0x162675['d'](_0x235062,'AbstractMesh',function(){return _0x40d22e['a'];}),_0x162675['d'](_0x235062,'Buffer',function(){return _0x212fbd['a'];}),_0x162675['d'](_0x235062,'VertexBuffer',function(){return _0x212fbd['b'];}),_0x162675['d'](_0x235062,'DracoCompression',function(){return _0x238160;}),_0x162675['d'](_0x235062,'CSG',function(){return _0x37caee;}),_0x162675['d'](_0x235062,'Geometry',function(){return _0xe6018['a'];}),_0x162675['d'](_0x235062,'GroundMesh',function(){return _0x5e0e3b;}),_0x162675['d'](_0x235062,'TrailMesh',function(){return _0x4b9b77;}),_0x162675['d'](_0x235062,'InstancedMesh',function(){return _0x5dfa8c['a'];}),_0x162675['d'](_0x235062,'LinesMesh',function(){return _0x2cc72f['b'];}),_0x162675['d'](_0x235062,'InstancedLinesMesh',function(){return _0x2cc72f['a'];}),_0x162675['d'](_0x235062,'_CreationDataStorage',function(){return _0x3cf5e5['b'];}),_0x162675['d'](_0x235062,'_InstancesBatch',function(){return _0x3cf5e5['c'];}),_0x162675['d'](_0x235062,'Mesh',function(){return _0x3cf5e5['a'];}),_0x162675['d'](_0x235062,'VertexData',function(){return _0xa18063['a'];}),_0x162675['d'](_0x235062,'MeshBuilder',function(){return _0x531160;}),_0x162675['d'](_0x235062,'SimplificationSettings',function(){return _0x214f41;}),_0x162675['d'](_0x235062,'SimplificationQueue',function(){return _0x3d1879;}),_0x162675['d'](_0x235062,'SimplificationType',function(){return _0x21793b;}),_0x162675['d'](_0x235062,'QuadraticErrorSimplification',function(){return _0x5ab9b4;}),_0x162675['d'](_0x235062,'SimplicationQueueSceneComponent',function(){return _0x5c7435;}),_0x162675['d'](_0x235062,'Polygon',function(){return _0x1ff6c6;}),_0x162675['d'](_0x235062,'PolygonMeshBuilder',function(){return _0x20eb6b;}),_0x162675['d'](_0x235062,'SubMesh',function(){return _0x2a2d6d['a'];}),_0x162675['d'](_0x235062,'MeshLODLevel',function(){return _0x325fe2['a'];}),_0x162675['d'](_0x235062,'TransformNode',function(){return _0x200669['a'];}),_0x162675['d'](_0x235062,'BoxBuilder',function(){return _0x144742['a'];}),_0x162675['d'](_0x235062,'TiledBoxBuilder',function(){return _0x3986af;}),_0x162675['d'](_0x235062,'DiscBuilder',function(){return _0x4ec9b3;}),_0x162675['d'](_0x235062,'RibbonBuilder',function(){return _0x9de293['a'];}),_0x162675['d'](_0x235062,'SphereBuilder',function(){return _0x5c4f8d['a'];}),_0x162675['d'](_0x235062,'HemisphereBuilder',function(){return _0x380273;}),_0x162675['d'](_0x235062,'CylinderBuilder',function(){return _0x179064['a'];}),_0x162675['d'](_0x235062,'TorusBuilder',function(){return _0x4a716b;}),_0x162675['d'](_0x235062,'TorusKnotBuilder',function(){return _0x2baa94;}),_0x162675['d'](_0x235062,'LinesBuilder',function(){return _0x333a74['a'];}),_0x162675['d'](_0x235062,'PolygonBuilder',function(){return _0x25aa99;}),_0x162675['d'](_0x235062,'ShapeBuilder',function(){return _0x13b0e7['a'];}),_0x162675['d'](_0x235062,'LatheBuilder',function(){return _0x2a4bc7;}),_0x162675['d'](_0x235062,'PlaneBuilder',function(){return _0xd22a68['a'];}),_0x162675['d'](_0x235062,'TiledPlaneBuilder',function(){return _0x8a5c03;}),_0x162675['d'](_0x235062,'GroundBuilder',function(){return _0x369c28;}),_0x162675['d'](_0x235062,'TubeBuilder',function(){return _0x124f37;}),_0x162675['d'](_0x235062,'PolyhedronBuilder',function(){return _0x39b46b;}),_0x162675['d'](_0x235062,'IcoSphereBuilder',function(){return _0x3acb17;}),_0x162675['d'](_0x235062,'DecalBuilder',function(){return _0x458e78;}),_0x162675['d'](_0x235062,'CapsuleBuilder',function(){return _0x5733e6;}),_0x162675['d'](_0x235062,'DataBuffer',function(){return _0x2b8850['a'];}),_0x162675['d'](_0x235062,'WebGLDataBuffer',function(){return _0x2da03e['a'];}),_0x162675['d'](_0x235062,'MorphTarget',function(){return _0x233e18;}),_0x162675['d'](_0x235062,'MorphTargetManager',function(){return _0x43ac20;}),_0x162675['d'](_0x235062,'RecastJSPlugin',function(){return _0x51a5cd;}),_0x162675['d'](_0x235062,'RecastJSCrowd',function(){return _0x121a1e;}),_0x162675['d'](_0x235062,'Node',function(){return _0x43169a['a'];}),_0x162675['d'](_0x235062,'Database',function(){return _0x2173c0;}),_0x162675['d'](_0x235062,'BaseParticleSystem',function(){return _0x2e1395;}),_0x162675['d'](_0x235062,'BoxParticleEmitter',function(){return _0x3faf18;}),_0x162675['d'](_0x235062,'ConeParticleEmitter',function(){return _0x2cb2ef;}),_0x162675['d'](_0x235062,'CylinderParticleEmitter',function(){return _0x4c9a66;}),_0x162675['d'](_0x235062,'CylinderDirectedParticleEmitter',function(){return _0x1b1b95;}),_0x162675['d'](_0x235062,'HemisphericParticleEmitter',function(){return _0x18cf99;}),_0x162675['d'](_0x235062,'PointParticleEmitter',function(){return _0x48f6b1;}),_0x162675['d'](_0x235062,'SphereParticleEmitter',function(){return _0x338038;}),_0x162675['d'](_0x235062,'SphereDirectedParticleEmitter',function(){return _0x111265;}),_0x162675['d'](_0x235062,'CustomParticleEmitter',function(){return _0x10a54c;}),_0x162675['d'](_0x235062,'MeshParticleEmitter',function(){return _0x219b07;}),_0x162675['d'](_0x235062,'GPUParticleSystem',function(){return _0x478f32;}),_0x162675['d'](_0x235062,'Particle',function(){return _0x387dbf;}),_0x162675['d'](_0x235062,'ParticleHelper',function(){return _0x1d5a32;}),_0x162675['d'](_0x235062,'ParticleSystem',function(){return _0x4baa8b;}),_0x162675['d'](_0x235062,'ParticleSystemSet',function(){return _0x3dbb28;}),_0x162675['d'](_0x235062,'SolidParticle',function(){return _0x51d7cc;}),_0x162675['d'](_0x235062,'ModelShape',function(){return _0x117754;}),_0x162675['d'](_0x235062,'DepthSortedParticle',function(){return _0x1c1fcf;}),_0x162675['d'](_0x235062,'SolidParticleVertex',function(){return _0x4e762f;}),_0x162675['d'](_0x235062,'SolidParticleSystem',function(){return _0x2322a7;}),_0x162675['d'](_0x235062,'CloudPoint',function(){return _0x264666;}),_0x162675['d'](_0x235062,'PointsGroup',function(){return _0x176d8e;}),_0x162675['d'](_0x235062,'PointColor',function(){return _0x4a7a2d;}),_0x162675['d'](_0x235062,'PointsCloudSystem',function(){return _0x2c9b20;}),_0x162675['d'](_0x235062,'SubEmitterType',function(){return _0x288d3e;}),_0x162675['d'](_0x235062,'SubEmitter',function(){return _0x5abfe8;}),_0x162675['d'](_0x235062,'PhysicsEngine',function(){return _0x598ff1;}),_0x162675['d'](_0x235062,'PhysicsEngineSceneComponent',function(){return _0x4e10cf;}),_0x162675['d'](_0x235062,'PhysicsHelper',function(){return _0x407b6b;}),_0x162675['d'](_0x235062,'PhysicsRadialExplosionEventOptions',function(){return _0x2cb9ab;}),_0x162675['d'](_0x235062,'PhysicsUpdraftEventOptions',function(){return _0x18f929;}),_0x162675['d'](_0x235062,'PhysicsVortexEventOptions',function(){return _0x478fbc;}),_0x162675['d'](_0x235062,'PhysicsRadialImpulseFalloff',function(){return _0x27983e;}),_0x162675['d'](_0x235062,'PhysicsUpdraftMode',function(){return _0x43cb3d;}),_0x162675['d'](_0x235062,'PhysicsImpostor',function(){return _0x3c10c7['a'];}),_0x162675['d'](_0x235062,'PhysicsJoint',function(){return _0x288b05['e'];}),_0x162675['d'](_0x235062,'DistanceJoint',function(){return _0x288b05['a'];}),_0x162675['d'](_0x235062,'MotorEnabledJoint',function(){return _0x288b05['d'];}),_0x162675['d'](_0x235062,'HingeJoint',function(){return _0x288b05['c'];}),_0x162675['d'](_0x235062,'Hinge2Joint',function(){return _0x288b05['b'];}),_0x162675['d'](_0x235062,'CannonJSPlugin',function(){return _0x52f9b1;}),_0x162675['d'](_0x235062,'AmmoJSPlugin',function(){return _0x1e7dd4;}),_0x162675['d'](_0x235062,'OimoJSPlugin',function(){return _0x128d84;}),_0x162675['d'](_0x235062,'AnaglyphPostProcess',function(){return _0x48ece4;}),_0x162675['d'](_0x235062,'BlackAndWhitePostProcess',function(){return _0x574bf7;}),_0x162675['d'](_0x235062,'BloomEffect',function(){return _0x199b31;}),_0x162675['d'](_0x235062,'BloomMergePostProcess',function(){return _0x2f39c9;}),_0x162675['d'](_0x235062,'BlurPostProcess',function(){return _0x487d78;}),_0x162675['d'](_0x235062,'ChromaticAberrationPostProcess',function(){return _0x151615;}),_0x162675['d'](_0x235062,'CircleOfConfusionPostProcess',function(){return _0x3f2eeb;}),_0x162675['d'](_0x235062,'ColorCorrectionPostProcess',function(){return _0x1865c6;}),_0x162675['d'](_0x235062,'ConvolutionPostProcess',function(){return _0x38ac9f;}),_0x162675['d'](_0x235062,'DepthOfFieldBlurPostProcess',function(){return _0x105a57;}),_0x162675['d'](_0x235062,'DepthOfFieldEffectBlurLevel',function(){return _0x30d121;}),_0x162675['d'](_0x235062,'DepthOfFieldEffect',function(){return _0x1f85e2;}),_0x162675['d'](_0x235062,'DepthOfFieldMergePostProcessOptions',function(){return _0x5092b7;}),_0x162675['d'](_0x235062,'DepthOfFieldMergePostProcess',function(){return _0x14dd7c;}),_0x162675['d'](_0x235062,'DisplayPassPostProcess',function(){return _0x3d3876;}),_0x162675['d'](_0x235062,'ExtractHighlightsPostProcess',function(){return _0x3d2626;}),_0x162675['d'](_0x235062,'FilterPostProcess',function(){return _0x2ea5fd;}),_0x162675['d'](_0x235062,'FxaaPostProcess',function(){return _0x30558e;}),_0x162675['d'](_0x235062,'GrainPostProcess',function(){return _0x338247;}),_0x162675['d'](_0x235062,'HighlightsPostProcess',function(){return _0x47ea8e;}),_0x162675['d'](_0x235062,'ImageProcessingPostProcess',function(){return _0x53baeb;}),_0x162675['d'](_0x235062,'MotionBlurPostProcess',function(){return _0x8933c4;}),_0x162675['d'](_0x235062,'PassPostProcess',function(){return _0x3f9daa;}),_0x162675['d'](_0x235062,'PassCubePostProcess',function(){return _0xc9943e;}),_0x162675['d'](_0x235062,'PostProcess',function(){return _0x5cae84;}),_0x162675['d'](_0x235062,'PostProcessManager',function(){return _0x1a1fc2['a'];}),_0x162675['d'](_0x235062,'RefractionPostProcess',function(){return _0x3a9838;}),_0x162675['d'](_0x235062,'DefaultRenderingPipeline',function(){return _0x1e339d;}),_0x162675['d'](_0x235062,'LensRenderingPipeline',function(){return _0x183e02;}),_0x162675['d'](_0x235062,'SSAO2RenderingPipeline',function(){return _0x1716c3;}),_0x162675['d'](_0x235062,'SSAORenderingPipeline',function(){return _0xc4fd5b;}),_0x162675['d'](_0x235062,'StandardRenderingPipeline',function(){return _0x6a7ba7;}),_0x162675['d'](_0x235062,'PostProcessRenderEffect',function(){return _0x1f6f7e;}),_0x162675['d'](_0x235062,'PostProcessRenderPipeline',function(){return _0x15e31a;}),_0x162675['d'](_0x235062,'PostProcessRenderPipelineManager',function(){return _0x13a007;}),_0x162675['d'](_0x235062,'PostProcessRenderPipelineManagerSceneComponent',function(){return _0x5a88cb;}),_0x162675['d'](_0x235062,'SharpenPostProcess',function(){return _0x59740a;}),_0x162675['d'](_0x235062,'StereoscopicInterlacePostProcessI',function(){return _0xf637cf;}),_0x162675['d'](_0x235062,'StereoscopicInterlacePostProcess',function(){return _0x4d0875;}),_0x162675['d'](_0x235062,'TonemappingOperator',function(){return _0x32e67b;}),_0x162675['d'](_0x235062,'TonemapPostProcess',function(){return _0x1897fb;}),_0x162675['d'](_0x235062,'VolumetricLightScatteringPostProcess',function(){return _0x318209;}),_0x162675['d'](_0x235062,'VRDistortionCorrectionPostProcess',function(){return _0x491a9b;}),_0x162675['d'](_0x235062,'VRMultiviewToSingleviewPostProcess',function(){return _0x2c34b9;}),_0x162675['d'](_0x235062,'ScreenSpaceReflectionPostProcess',function(){return _0x5d05bb;}),_0x162675['d'](_0x235062,'ScreenSpaceCurvaturePostProcess',function(){return _0x25052b;}),_0x162675['d'](_0x235062,'ReflectionProbe',function(){return _0x39356b;}),_0x162675['d'](_0x235062,'BoundingBoxRenderer',function(){return _0x2c8e40;}),_0x162675['d'](_0x235062,'DepthRenderer',function(){return _0x4ba7ed;}),_0x162675['d'](_0x235062,'DepthRendererSceneComponent',function(){return _0x2ede05;}),_0x162675['d'](_0x235062,'EdgesRenderer',function(){return _0x5cf15b;}),_0x162675['d'](_0x235062,'LineEdgesRenderer',function(){return _0x29ddd5;}),_0x162675['d'](_0x235062,'GeometryBufferRenderer',function(){return _0x5e0ba2;}),_0x162675['d'](_0x235062,'GeometryBufferRendererSceneComponent',function(){return _0x1e2f6b;}),_0x162675['d'](_0x235062,'PrePassRenderer',function(){return _0xb94897;}),_0x162675['d'](_0x235062,'PrePassRendererSceneComponent',function(){return _0x1a18b3;}),_0x162675['d'](_0x235062,'SubSurfaceSceneComponent',function(){return _0x376f07;}),_0x162675['d'](_0x235062,'OutlineRenderer',function(){return _0x475d6d;}),_0x162675['d'](_0x235062,'RenderingGroup',function(){return _0x883304['a'];}),_0x162675['d'](_0x235062,'RenderingGroupInfo',function(){return _0x46a497['a'];}),_0x162675['d'](_0x235062,'RenderingManager',function(){return _0x46a497['b'];}),_0x162675['d'](_0x235062,'UtilityLayerRenderer',function(){return _0x539118['a'];}),_0x162675['d'](_0x235062,'Scene',function(){return _0x59370b['a'];}),_0x162675['d'](_0x235062,'SceneComponentConstants',function(){return _0x384de3['a'];}),_0x162675['d'](_0x235062,'Stage',function(){return _0x384de3['b'];}),_0x162675['d'](_0x235062,'Sprite',function(){return _0x181037;}),_0x162675['d'](_0x235062,'SpriteManager',function(){return _0x15f119;}),_0x162675['d'](_0x235062,'SpriteMap',function(){return _0xab3fb1;}),_0x162675['d'](_0x235062,'SpritePackedManager',function(){return _0x23ee96;}),_0x162675['d'](_0x235062,'SpriteSceneComponent',function(){return _0x187130;}),_0x162675['d'](_0x235062,'AlphaState',function(){return _0x3b3d42['a'];}),_0x162675['d'](_0x235062,'DepthCullingState',function(){return _0x30319a['a'];}),_0x162675['d'](_0x235062,'StencilState',function(){return _0x47270c['a'];}),_0x162675['d'](_0x235062,'AndOrNotEvaluator',function(){return _0x18e05a['a'];}),_0x162675['d'](_0x235062,'AssetTaskState',function(){return _0x2fdd8f;}),_0x162675['d'](_0x235062,'AbstractAssetTask',function(){return _0x822dce;}),_0x162675['d'](_0x235062,'AssetsProgressEvent',function(){return _0x4c658d;}),_0x162675['d'](_0x235062,'ContainerAssetTask',function(){return _0x2c9bee;}),_0x162675['d'](_0x235062,'MeshAssetTask',function(){return _0x182209;}),_0x162675['d'](_0x235062,'TextFileAssetTask',function(){return _0x8db0a1;}),_0x162675['d'](_0x235062,'BinaryFileAssetTask',function(){return _0x395535;}),_0x162675['d'](_0x235062,'ImageAssetTask',function(){return _0xf62d4b;}),_0x162675['d'](_0x235062,'TextureAssetTask',function(){return _0x1f67ec;}),_0x162675['d'](_0x235062,'CubeTextureAssetTask',function(){return _0x4dda1a;}),_0x162675['d'](_0x235062,'HDRCubeTextureAssetTask',function(){return _0x479df4;}),_0x162675['d'](_0x235062,'EquiRectangularCubeTextureAssetTask',function(){return _0x7ac95a;}),_0x162675['d'](_0x235062,'AssetsManager',function(){return _0xe5d1bb;}),_0x162675['d'](_0x235062,'BasisTranscodeConfiguration',function(){return _0x3d12cf;}),_0x162675['d'](_0x235062,'BasisTools',function(){return _0x9fc683;}),_0x162675['d'](_0x235062,'DDSTools',function(){return _0x568c36;}),_0x162675['d'](_0x235062,'expandToProperty',function(){return _0x495d06['b'];}),_0x162675['d'](_0x235062,'serialize',function(){return _0x495d06['c'];}),_0x162675['d'](_0x235062,'serializeAsTexture',function(){return _0x495d06['m'];}),_0x162675['d'](_0x235062,'serializeAsColor3',function(){return _0x495d06['e'];}),_0x162675['d'](_0x235062,'serializeAsFresnelParameters',function(){return _0x495d06['h'];}),_0x162675['d'](_0x235062,'serializeAsVector2',function(){return _0x495d06['n'];}),_0x162675['d'](_0x235062,'serializeAsVector3',function(){return _0x495d06['o'];}),_0x162675['d'](_0x235062,'serializeAsMeshReference',function(){return _0x495d06['k'];}),_0x162675['d'](_0x235062,'serializeAsColorCurves',function(){return _0x495d06['g'];}),_0x162675['d'](_0x235062,'serializeAsColor4',function(){return _0x495d06['f'];}),_0x162675['d'](_0x235062,'serializeAsImageProcessingConfiguration',function(){return _0x495d06['i'];}),_0x162675['d'](_0x235062,'serializeAsQuaternion',function(){return _0x495d06['l'];}),_0x162675['d'](_0x235062,'serializeAsMatrix',function(){return _0x495d06['j'];}),_0x162675['d'](_0x235062,'serializeAsCameraReference',function(){return _0x495d06['d'];}),_0x162675['d'](_0x235062,'SerializationHelper',function(){return _0x495d06['a'];}),_0x162675['d'](_0x235062,'Deferred',function(){return _0x126714;}),_0x162675['d'](_0x235062,'EnvironmentTextureTools',function(){return _0x480d46;}),_0x162675['d'](_0x235062,'MeshExploder',function(){return _0x252c0f;}),_0x162675['d'](_0x235062,'FilesInput',function(){return _0x52a3bf;}),_0x162675['d'](_0x235062,'CubeMapToSphericalPolynomialTools',function(){return _0x3fdf9a;}),_0x162675['d'](_0x235062,'HDRTools',function(){return _0x1fec63;}),_0x162675['d'](_0x235062,'PanoramaToCubeMapTools',function(){return _0x11ae99;}),_0x162675['d'](_0x235062,'KhronosTextureContainer',function(){return _0x8ca7f1;}),_0x162675['d'](_0x235062,'EventState',function(){return _0x6ac1f7['a'];}),_0x162675['d'](_0x235062,'Observer',function(){return _0x6ac1f7['d'];}),_0x162675['d'](_0x235062,'MultiObserver',function(){return _0x6ac1f7['b'];}),_0x162675['d'](_0x235062,'Observable',function(){return _0x6ac1f7['c'];}),_0x162675['d'](_0x235062,'PerformanceMonitor',function(){return _0x45e325['a'];}),_0x162675['d'](_0x235062,'RollingAverage',function(){return _0x45e325['b'];}),_0x162675['d'](_0x235062,'PromisePolyfill',function(){return _0x534107['a'];}),_0x162675['d'](_0x235062,'SceneOptimization',function(){return _0x570cc0;}),_0x162675['d'](_0x235062,'TextureOptimization',function(){return _0x3812e5;}),_0x162675['d'](_0x235062,'HardwareScalingOptimization',function(){return _0x25b571;}),_0x162675['d'](_0x235062,'ShadowsOptimization',function(){return _0x175af1;}),_0x162675['d'](_0x235062,'PostProcessesOptimization',function(){return _0x253aec;}),_0x162675['d'](_0x235062,'LensFlaresOptimization',function(){return _0x3300ac;}),_0x162675['d'](_0x235062,'CustomOptimization',function(){return _0x4a5233;}),_0x162675['d'](_0x235062,'ParticlesOptimization',function(){return _0x53fa4c;}),_0x162675['d'](_0x235062,'RenderTargetsOptimization',function(){return _0x422335;}),_0x162675['d'](_0x235062,'MergeMeshesOptimization',function(){return _0x5a962a;}),_0x162675['d'](_0x235062,'SceneOptimizerOptions',function(){return _0x2e7d19;}),_0x162675['d'](_0x235062,'SceneOptimizer',function(){return _0x353c55;}),_0x162675['d'](_0x235062,'SceneSerializer',function(){return _0x568e68;}),_0x162675['d'](_0x235062,'SmartArray',function(){return _0x2266f9['a'];}),_0x162675['d'](_0x235062,'SmartArrayNoDuplicate',function(){return _0x2266f9['b'];}),_0x162675['d'](_0x235062,'StringDictionary',function(){return _0x33b3b3['a'];}),_0x162675['d'](_0x235062,'Tags',function(){return _0x49603f['a'];}),_0x162675['d'](_0x235062,'TextureTools',function(){return _0x34ddb1;}),_0x162675['d'](_0x235062,'TGATools',function(){return _0x4a363d;}),_0x162675['d'](_0x235062,'Tools',function(){return _0x5d754c['b'];}),_0x162675['d'](_0x235062,'className',function(){return _0x5d754c['c'];}),_0x162675['d'](_0x235062,'AsyncLoop',function(){return _0x5d754c['a'];}),_0x162675['d'](_0x235062,'VideoRecorder',function(){return _0x1816cc;}),_0x162675['d'](_0x235062,'JoystickAxis',function(){return _0x15bf12;}),_0x162675['d'](_0x235062,'VirtualJoystick',function(){return _0x2fab61;}),_0x162675['d'](_0x235062,'WorkerPool',function(){return _0xe2001d;}),_0x162675['d'](_0x235062,'Logger',function(){return _0x75193d['a'];}),_0x162675['d'](_0x235062,'_TypeStore',function(){return _0x3cd573['a'];}),_0x162675['d'](_0x235062,'FilesInputStore',function(){return _0xa24f9c['a'];}),_0x162675['d'](_0x235062,'DeepCopier',function(){return _0x5d9c83['a'];}),_0x162675['d'](_0x235062,'PivotTools',function(){return _0x45da14['a'];}),_0x162675['d'](_0x235062,'PrecisionDate',function(){return _0x49f003['a'];}),_0x162675['d'](_0x235062,'ScreenshotTools',function(){return _0x329c92;}),_0x162675['d'](_0x235062,'WebRequest',function(){return _0x25cf22['a'];}),_0x162675['d'](_0x235062,'InspectableType',function(){return _0x387f88;}),_0x162675['d'](_0x235062,'BRDFTextureTools',function(){return _0x4d5377;}),_0x162675['d'](_0x235062,'RGBDTextureTools',function(){return _0x12db54;}),_0x162675['d'](_0x235062,'ColorGradient',function(){return _0x3b38b8;}),_0x162675['d'](_0x235062,'Color3Gradient',function(){return _0x4394fb;}),_0x162675['d'](_0x235062,'FactorGradient',function(){return _0x3f4c49;}),_0x162675['d'](_0x235062,'GradientHelper',function(){return _0x2688df;}),_0x162675['d'](_0x235062,'PerfCounter',function(){return _0x177abf['a'];}),_0x162675['d'](_0x235062,'RetryStrategy',function(){return _0x2236e7['a'];}),_0x162675['d'](_0x235062,'CanvasGenerator',function(){return _0x27137b['a'];}),_0x162675['d'](_0x235062,'LoadFileError',function(){return _0x14fdee['b'];}),_0x162675['d'](_0x235062,'RequestFileError',function(){return _0x14fdee['d'];}),_0x162675['d'](_0x235062,'ReadFileError',function(){return _0x14fdee['c'];}),_0x162675['d'](_0x235062,'FileTools',function(){return _0x14fdee['a'];}),_0x162675['d'](_0x235062,'StringTools',function(){return _0x5950ed['a'];}),_0x162675['d'](_0x235062,'DataReader',function(){return _0x85935a;}),_0x162675['d'](_0x235062,'MinMaxReducer',function(){return _0x5be8fc;}),_0x162675['d'](_0x235062,'DepthReducer',function(){return _0x457be1;}),_0x162675['d'](_0x235062,'DataStorage',function(){return _0x2ac121;}),_0x162675['d'](_0x235062,'SceneRecorder',function(){return _0x58653c;}),_0x162675['d'](_0x235062,'KhronosTextureContainer2',function(){return _0x20352;}),_0x162675['d'](_0x235062,'Trajectory',function(){return _0x261275;}),_0x162675['d'](_0x235062,'TrajectoryClassifier',function(){return _0x2038bd;}),_0x162675['d'](_0x235062,'TimerState',function(){return _0x496a16;}),_0x162675['d'](_0x235062,'setAndStartTimer',function(){return _0xad9c7a;}),_0x162675['d'](_0x235062,'AdvancedTimer',function(){return _0x8fbeb1;}),_0x162675['d'](_0x235062,'CopyTools',function(){return _0x41adc1['a'];}),_0x162675['d'](_0x235062,'WebXRCamera',function(){return _0x4aea41;}),_0x162675['d'](_0x235062,'WebXREnterExitUIButton',function(){return _0x1875af;}),_0x162675['d'](_0x235062,'WebXREnterExitUIOptions',function(){return _0x318d40;}),_0x162675['d'](_0x235062,'WebXREnterExitUI',function(){return _0x57fcd2;}),_0x162675['d'](_0x235062,'WebXRExperienceHelper',function(){return _0xaf8b47;}),_0x162675['d'](_0x235062,'WebXRInput',function(){return _0x51d413;}),_0x162675['d'](_0x235062,'WebXRInputSource',function(){return _0x567d87;}),_0x162675['d'](_0x235062,'WebXRManagedOutputCanvasOptions',function(){return _0x3b39f6;}),_0x162675['d'](_0x235062,'WebXRManagedOutputCanvas',function(){return _0x290869;}),_0x162675['d'](_0x235062,'WebXRState',function(){return _0xada4aa;}),_0x162675['d'](_0x235062,'WebXRTrackingState',function(){return _0x49ab50;}),_0x162675['d'](_0x235062,'WebXRSessionManager',function(){return _0x31ca49;}),_0x162675['d'](_0x235062,'WebXRDefaultExperienceOptions',function(){return _0x4272d5;}),_0x162675['d'](_0x235062,'WebXRDefaultExperience',function(){return _0x2d69fd;}),_0x162675['d'](_0x235062,'WebXRFeatureName',function(){return _0x216b10;}),_0x162675['d'](_0x235062,'WebXRFeaturesManager',function(){return _0x5ef0ab;}),_0x162675['d'](_0x235062,'WebXRAbstractFeature',function(){return _0x2fd67e;}),_0x162675['d'](_0x235062,'WebXRHitTestLegacy',function(){return _0x5d7f67;}),_0x162675['d'](_0x235062,'WebXRAnchorSystem',function(){return _0x366775;}),_0x162675['d'](_0x235062,'WebXRPlaneDetector',function(){return _0x48d6be;}),_0x162675['d'](_0x235062,'WebXRBackgroundRemover',function(){return _0x30bf81;}),_0x162675['d'](_0x235062,'WebXRMotionControllerTeleportation',function(){return _0x55b553;}),_0x162675['d'](_0x235062,'WebXRControllerPointerSelection',function(){return _0x4a05bd;}),_0x162675['d'](_0x235062,'IWebXRControllerPhysicsOptions',function(){return _0x33cfb0;}),_0x162675['d'](_0x235062,'WebXRControllerPhysics',function(){return _0x14c10a;}),_0x162675['d'](_0x235062,'WebXRHitTest',function(){return _0x3e0b3b;}),_0x162675['d'](_0x235062,'WebXRFeaturePointSystem',function(){return _0x5afa2d;}),_0x162675['d'](_0x235062,'WebXRHand',function(){return _0x1ad3fc;}),_0x162675['d'](_0x235062,'WebXRHandTracking',function(){return _0x41e0b1;}),_0x162675['d'](_0x235062,'WebXRAbstractMotionController',function(){return _0x48fb5b;}),_0x162675['d'](_0x235062,'WebXRControllerComponent',function(){return _0x38e6cf;}),_0x162675['d'](_0x235062,'WebXRGenericTriggerMotionController',function(){return _0x11269c;}),_0x162675['d'](_0x235062,'WebXRMicrosoftMixedRealityController',function(){return _0x5545b9;}),_0x162675['d'](_0x235062,'WebXRMotionControllerManager',function(){return _0x13267d;}),_0x162675['d'](_0x235062,'WebXROculusTouchMotionController',function(){return _0x44d608;}),_0x162675['d'](_0x235062,'WebXRHTCViveMotionController',function(){return _0x159301;}),_0x162675['d'](_0x235062,'WebXRProfiledMotionController',function(){return _0x546c04;});var _0x3598db=_0x162675(0x23),_0xd232ee=_0x162675(0x5b),_0x6ac1f7=_0x162675(0x6),_0x74d525=_0x162675(0x0),_0x39310d=_0x162675(0x9),_0x3cd573=_0x162675(0xb),_0x26efb5=(function(){function _0x5ee372(_0x512ebe,_0x40a9f5){this['triggerOptions']=_0x512ebe,this['onBeforeExecuteObservable']=new _0x6ac1f7['c'](),_0x512ebe['parameter']?(this['trigger']=_0x512ebe['trigger'],this['_triggerParameter']=_0x512ebe['parameter']):_0x512ebe['trigger']?this['trigger']=_0x512ebe['trigger']:this['trigger']=_0x512ebe,this['_nextActiveAction']=this,this['_condition']=_0x40a9f5;}return _0x5ee372['prototype']['_prepare']=function(){},_0x5ee372['prototype']['getTriggerParameter']=function(){return this['_triggerParameter'];},_0x5ee372['prototype']['_executeCurrent']=function(_0x5baa22){if(this['_nextActiveAction']['_condition']){var _0x27e763=this['_nextActiveAction']['_condition'],_0x4b6d4b=this['_actionManager']['getScene']()['getRenderId']();if(_0x27e763['_evaluationId']===_0x4b6d4b){if(!_0x27e763['_currentResult'])return;}else{if(_0x27e763['_evaluationId']=_0x4b6d4b,!_0x27e763['isValid']())return void(_0x27e763['_currentResult']=!0x1);_0x27e763['_currentResult']=!0x0;}}this['onBeforeExecuteObservable']['notifyObservers'](this),this['_nextActiveAction']['execute'](_0x5baa22),this['skipToNextActiveAction']();},_0x5ee372['prototype']['execute']=function(_0x51f9f2){},_0x5ee372['prototype']['skipToNextActiveAction']=function(){this['_nextActiveAction']['_child']?(this['_nextActiveAction']['_child']['_actionManager']||(this['_nextActiveAction']['_child']['_actionManager']=this['_actionManager']),this['_nextActiveAction']=this['_nextActiveAction']['_child']):this['_nextActiveAction']=this;},_0x5ee372['prototype']['then']=function(_0x3ad32b){return this['_child']=_0x3ad32b,_0x3ad32b['_actionManager']=this['_actionManager'],_0x3ad32b['_prepare'](),_0x3ad32b;},_0x5ee372['prototype']['_getProperty']=function(_0x25e72c){return this['_actionManager']['_getProperty'](_0x25e72c);},_0x5ee372['prototype']['_getEffectiveTarget']=function(_0x169bdd,_0x3603f7){return this['_actionManager']['_getEffectiveTarget'](_0x169bdd,_0x3603f7);},_0x5ee372['prototype']['serialize']=function(_0x1dc888){},_0x5ee372['prototype']['_serialize']=function(_0x44aa01,_0x3f1d5c){var _0x1f95e3={'type':0x1,'children':[],'name':_0x44aa01['name'],'properties':_0x44aa01['properties']||[]};if(this['_child']&&this['_child']['serialize'](_0x1f95e3),this['_condition']){var _0x3aac66=this['_condition']['serialize']();return _0x3aac66['children']['push'](_0x1f95e3),_0x3f1d5c&&_0x3f1d5c['children']['push'](_0x3aac66),_0x3aac66;}return _0x3f1d5c&&_0x3f1d5c['children']['push'](_0x1f95e3),_0x1f95e3;},_0x5ee372['_SerializeValueAsString']=function(_0x17c695){return'number'==typeof _0x17c695?_0x17c695['toString']():'boolean'==typeof _0x17c695?_0x17c695?'true':'false':_0x17c695 instanceof _0x74d525['d']?_0x17c695['x']+',\x20'+_0x17c695['y']:_0x17c695 instanceof _0x74d525['e']?_0x17c695['x']+',\x20'+_0x17c695['y']+',\x20'+_0x17c695['z']:_0x17c695 instanceof _0x39310d['a']?_0x17c695['r']+',\x20'+_0x17c695['g']+',\x20'+_0x17c695['b']:_0x17c695 instanceof _0x39310d['b']?_0x17c695['r']+',\x20'+_0x17c695['g']+',\x20'+_0x17c695['b']+',\x20'+_0x17c695['a']:_0x17c695;},_0x5ee372['_GetTargetProperty']=function(_0x3ce45e){return{'name':'target','targetType':_0x3ce45e['_isMesh']?'MeshProperties':_0x3ce45e['_isLight']?'LightProperties':_0x3ce45e['_isCamera']?'CameraProperties':'SceneProperties','value':_0x3ce45e['_isScene']?'Scene':_0x3ce45e['name']};},_0x5ee372;}());_0x3cd573['a']['RegisteredTypes']['BABYLON.Action']=_0x26efb5;var _0x3b70ca=_0x162675(0x2f),_0x18e13d=_0x162675(0x1),_0x572956=(function(){function _0x528dc0(_0x1b31a4){this['_actionManager']=_0x1b31a4;}return _0x528dc0['prototype']['isValid']=function(){return!0x0;},_0x528dc0['prototype']['_getProperty']=function(_0x5b9552){return this['_actionManager']['_getProperty'](_0x5b9552);},_0x528dc0['prototype']['_getEffectiveTarget']=function(_0x4fa085,_0x12f727){return this['_actionManager']['_getEffectiveTarget'](_0x4fa085,_0x12f727);},_0x528dc0['prototype']['serialize']=function(){},_0x528dc0['prototype']['_serialize']=function(_0x8806bf){return{'type':0x2,'children':[],'name':_0x8806bf['name'],'properties':_0x8806bf['properties']};},_0x528dc0;}()),_0xc057a3=function(_0x5b9739){function _0x15ec18(_0x53ded2,_0x637f15,_0x7635fc,_0xe0a4ec,_0x1109df){void 0x0===_0x1109df&&(_0x1109df=_0x15ec18['IsEqual']);var _0xeaf9f5=_0x5b9739['call'](this,_0x53ded2)||this;return _0xeaf9f5['propertyPath']=_0x7635fc,_0xeaf9f5['value']=_0xe0a4ec,_0xeaf9f5['operator']=_0x1109df,_0xeaf9f5['_target']=_0x637f15,_0xeaf9f5['_effectiveTarget']=_0xeaf9f5['_getEffectiveTarget'](_0x637f15,_0xeaf9f5['propertyPath']),_0xeaf9f5['_property']=_0xeaf9f5['_getProperty'](_0xeaf9f5['propertyPath']),_0xeaf9f5;}return Object(_0x18e13d['d'])(_0x15ec18,_0x5b9739),Object['defineProperty'](_0x15ec18,'IsEqual',{'get':function(){return _0x15ec18['_IsEqual'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x15ec18,'IsDifferent',{'get':function(){return _0x15ec18['_IsDifferent'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x15ec18,'IsGreater',{'get':function(){return _0x15ec18['_IsGreater'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x15ec18,'IsLesser',{'get':function(){return _0x15ec18['_IsLesser'];},'enumerable':!0x1,'configurable':!0x0}),_0x15ec18['prototype']['isValid']=function(){switch(this['operator']){case _0x15ec18['IsGreater']:return this['_effectiveTarget'][this['_property']]>this['value'];case _0x15ec18['IsLesser']:return this['_effectiveTarget'][this['_property']]-0x1&&this['_scene']['actionManagers']['splice'](_0x295ef9,0x1);},_0xe6d836['prototype']['getScene']=function(){return this['_scene'];},_0xe6d836['prototype']['hasSpecificTriggers']=function(_0xd0f42c){for(var _0x5cded9=0x0;_0x5cded9-0x1)return!0x0;}return!0x1;},_0xe6d836['prototype']['hasSpecificTriggers2']=function(_0x116981,_0x30bb56){for(var _0x4fb104=0x0;_0x4fb104=_0xe6d836['OnPickTrigger']&&_0x2c3667['trigger']<=_0xe6d836['OnPointerOutTrigger'])return!0x0;}return!0x1;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xe6d836['prototype'],'hasPickTriggers',{'get':function(){for(var _0x3acbf5=0x0;_0x3acbf5=_0xe6d836['OnPickTrigger']&&_0x5a8173['trigger']<=_0xe6d836['OnPickUpTrigger'])return!0x0;}return!0x1;},'enumerable':!0x1,'configurable':!0x0}),_0xe6d836['prototype']['registerAction']=function(_0x50283c){return _0x50283c['trigger']===_0xe6d836['OnEveryFrameTrigger']&&this['getScene']()['actionManager']!==this?(_0x75193d['a']['Warn']('OnEveryFrameTrigger\x20can\x20only\x20be\x20used\x20with\x20scene.actionManager'),null):(this['actions']['push'](_0x50283c),_0xe6d836['Triggers'][_0x50283c['trigger']]?_0xe6d836['Triggers'][_0x50283c['trigger']]++:_0xe6d836['Triggers'][_0x50283c['trigger']]=0x1,_0x50283c['_actionManager']=this,_0x50283c['_prepare'](),_0x50283c);},_0xe6d836['prototype']['unregisterAction']=function(_0x2fbdbf){var _0x4f959f=this['actions']['indexOf'](_0x2fbdbf);return-0x1!==_0x4f959f&&(this['actions']['splice'](_0x4f959f,0x1),_0xe6d836['Triggers'][_0x2fbdbf['trigger']]-=0x1,0x0===_0xe6d836['Triggers'][_0x2fbdbf['trigger']]&&delete _0xe6d836['Triggers'][_0x2fbdbf['trigger']],_0x2fbdbf['_actionManager']=null,!0x0);},_0xe6d836['prototype']['processTrigger']=function(_0x40cb79,_0x552ba0){for(var _0x3eb42d=0x0;_0x3eb42d0x0;if(0x2===_0x37dca2['type']?_0x2b55cb['push'](_0x1cd24c):_0x2b55cb['push'](_0x264a1b),_0x7a9ded){for(var _0x134967=new Array(),_0x90888d=0x0;_0x90888d<_0x37dca2['combine']['length'];_0x90888d++)_0x454b7c(_0x37dca2['combine'][_0x90888d],_0xe6d836['NothingTrigger'],_0x4fd606,_0x45c3a6,_0x134967);_0x2b55cb['push'](_0x134967);}else for(var _0x2c4f09=0x0;_0x2c4f09<_0x37dca2['properties']['length'];_0x2c4f09++){var _0x4fe6d0=_0x37dca2['properties'][_0x2c4f09]['value'],_0x34ed6e=_0x37dca2['properties'][_0x2c4f09]['name'],_0x12a39e=_0x37dca2['properties'][_0x2c4f09]['targetType'];'target'===_0x34ed6e?_0x4fe6d0=_0x1bc451=null!==_0x12a39e&&'SceneProperties'===_0x12a39e?_0x4a4831:_0x4a4831['getNodeByName'](_0x4fe6d0):'parent'===_0x34ed6e?_0x4fe6d0=_0x4a4831['getNodeByName'](_0x4fe6d0):'sound'===_0x34ed6e?_0x4a4831['getSoundByName']&&(_0x4fe6d0=_0x4a4831['getSoundByName'](_0x4fe6d0)):'propertyPath'!==_0x34ed6e?_0x4fe6d0=0x2===_0x37dca2['type']&&'operator'===_0x34ed6e?_0xc057a3[_0x4fe6d0]:_0x37e6d3(0x0,_0x4fe6d0,_0x1bc451,'value'===_0x34ed6e?_0x537eee:null):_0x537eee=_0x4fe6d0,_0x2b55cb['push'](_0x4fe6d0);}if(null===_0x1ce189?_0x2b55cb['push'](_0x4fd606):_0x2b55cb['push'](null),'InterpolateValueAction'===_0x37dca2['name']){var _0x3cec97=_0x2b55cb[_0x2b55cb['length']-0x2];_0x2b55cb[_0x2b55cb['length']-0x1]=_0x3cec97,_0x2b55cb[_0x2b55cb['length']-0x2]=_0x4fd606;}var _0x393c9f=function(_0x2043eb,_0x5d503a){var _0x5d4ae8=_0x3cd573['a']['GetClass']('BABYLON.'+_0x2043eb);if(_0x5d4ae8){var _0x557506=Object['create'](_0x5d4ae8['prototype']);return _0x557506['constructor']['apply'](_0x557506,_0x5d503a),_0x557506;}}(_0x37dca2['name'],_0x2b55cb);if(_0x393c9f instanceof _0x572956&&null!==_0x4fd606){var _0x32e92f=new _0xc309ab(_0x264a1b,_0x4fd606);_0x45c3a6?_0x45c3a6['then'](_0x32e92f):_0x1cd24c['registerAction'](_0x32e92f),_0x45c3a6=_0x32e92f;}null===_0x1ce189?_0x393c9f instanceof _0x572956?(_0x4fd606=_0x393c9f,_0x393c9f=_0x45c3a6):(_0x4fd606=null,_0x45c3a6?_0x45c3a6['then'](_0x393c9f):_0x1cd24c['registerAction'](_0x393c9f)):_0x1ce189['push'](_0x393c9f);for(_0x2c4f09=0x0;_0x2c4f09<_0x37dca2['children']['length'];_0x2c4f09++)_0x454b7c(_0x37dca2['children'][_0x2c4f09],_0x264a1b,_0x4fd606,_0x393c9f,null);}},_0x35b542=0x0;_0x35b542<_0x50d6d3['children']['length'];_0x35b542++){var _0x4af474,_0x3b3a0c=_0x50d6d3['children'][_0x35b542];if(_0x3b3a0c['properties']['length']>0x0){var _0x23858a=_0x3b3a0c['properties'][0x0]['value'],_0x4724b1=null===_0x3b3a0c['properties'][0x0]['targetType']?_0x23858a:_0x4a4831['getMeshByName'](_0x23858a);_0x4724b1['_meshId']&&(_0x4724b1['mesh']=_0x4a4831['getMeshByID'](_0x4724b1['_meshId'])),_0x4af474={'trigger':_0xe6d836[_0x3b3a0c['name']],'parameter':_0x4724b1};}else _0x4af474=_0xe6d836[_0x3b3a0c['name']];for(var _0x34afa0=0x0;_0x34afa0<_0x3b3a0c['children']['length'];_0x34afa0++)_0x3b3a0c['detached']||_0x454b7c(_0x3b3a0c['children'][_0x34afa0],_0x4af474,null,null);}},_0xe6d836['GetTriggerName']=function(_0x1313db){switch(_0x1313db){case 0x0:return'NothingTrigger';case 0x1:return'OnPickTrigger';case 0x2:return'OnLeftPickTrigger';case 0x3:return'OnRightPickTrigger';case 0x4:return'OnCenterPickTrigger';case 0x5:return'OnPickDownTrigger';case 0x6:return'OnPickUpTrigger';case 0x7:return'OnLongPressTrigger';case 0x8:return'OnPointerOverTrigger';case 0x9:return'OnPointerOutTrigger';case 0xa:return'OnEveryFrameTrigger';case 0xb:return'OnIntersectionEnterTrigger';case 0xc:return'OnIntersectionExitTrigger';case 0xd:return'OnKeyDownTrigger';case 0xe:return'OnKeyUpTrigger';case 0xf:return'OnPickOutTrigger';default:return'';}},_0xe6d836['NothingTrigger']=_0x2103ba['a']['ACTION_NothingTrigger'],_0xe6d836['OnPickTrigger']=_0x2103ba['a']['ACTION_OnPickTrigger'],_0xe6d836['OnLeftPickTrigger']=_0x2103ba['a']['ACTION_OnLeftPickTrigger'],_0xe6d836['OnRightPickTrigger']=_0x2103ba['a']['ACTION_OnRightPickTrigger'],_0xe6d836['OnCenterPickTrigger']=_0x2103ba['a']['ACTION_OnCenterPickTrigger'],_0xe6d836['OnPickDownTrigger']=_0x2103ba['a']['ACTION_OnPickDownTrigger'],_0xe6d836['OnDoublePickTrigger']=_0x2103ba['a']['ACTION_OnDoublePickTrigger'],_0xe6d836['OnPickUpTrigger']=_0x2103ba['a']['ACTION_OnPickUpTrigger'],_0xe6d836['OnPickOutTrigger']=_0x2103ba['a']['ACTION_OnPickOutTrigger'],_0xe6d836['OnLongPressTrigger']=_0x2103ba['a']['ACTION_OnLongPressTrigger'],_0xe6d836['OnPointerOverTrigger']=_0x2103ba['a']['ACTION_OnPointerOverTrigger'],_0xe6d836['OnPointerOutTrigger']=_0x2103ba['a']['ACTION_OnPointerOutTrigger'],_0xe6d836['OnEveryFrameTrigger']=_0x2103ba['a']['ACTION_OnEveryFrameTrigger'],_0xe6d836['OnIntersectionEnterTrigger']=_0x2103ba['a']['ACTION_OnIntersectionEnterTrigger'],_0xe6d836['OnIntersectionExitTrigger']=_0x2103ba['a']['ACTION_OnIntersectionExitTrigger'],_0xe6d836['OnKeyDownTrigger']=_0x2103ba['a']['ACTION_OnKeyDownTrigger'],_0xe6d836['OnKeyUpTrigger']=0xf,_0xe6d836;}(_0xd232ee['a']),_0x1272a3=function(_0x48d418){function _0x13c35b(_0x306a2d,_0x57da14,_0x81aece){var _0x22cde0=_0x48d418['call'](this,_0x306a2d,_0x81aece)||this;return _0x22cde0['_sound']=_0x57da14,_0x22cde0;}return Object(_0x18e13d['d'])(_0x13c35b,_0x48d418),_0x13c35b['prototype']['_prepare']=function(){},_0x13c35b['prototype']['execute']=function(){void 0x0!==this['_sound']&&this['_sound']['play']();},_0x13c35b['prototype']['serialize']=function(_0x218b1b){return _0x48d418['prototype']['_serialize']['call'](this,{'name':'PlaySoundAction','properties':[{'name':'sound','value':this['_sound']['name']}]},_0x218b1b);},_0x13c35b;}(_0x26efb5),_0x479f71=function(_0x1e9401){function _0x1f055b(_0x10af88,_0x500fec,_0x214efd){var _0x8e01fc=_0x1e9401['call'](this,_0x10af88,_0x214efd)||this;return _0x8e01fc['_sound']=_0x500fec,_0x8e01fc;}return Object(_0x18e13d['d'])(_0x1f055b,_0x1e9401),_0x1f055b['prototype']['_prepare']=function(){},_0x1f055b['prototype']['execute']=function(){void 0x0!==this['_sound']&&this['_sound']['stop']();},_0x1f055b['prototype']['serialize']=function(_0x249417){return _0x1e9401['prototype']['_serialize']['call'](this,{'name':'StopSoundAction','properties':[{'name':'sound','value':this['_sound']['name']}]},_0x249417);},_0x1f055b;}(_0x26efb5);_0x3cd573['a']['RegisteredTypes']['BABYLON.PlaySoundAction']=_0x479f71,_0x3cd573['a']['RegisteredTypes']['BABYLON.StopSoundAction']=_0x479f71;var _0x3c3574,_0x4a0cf0=_0x162675(0xe),_0x495d06=_0x162675(0x3);!function(_0x322d8f){_0x322d8f[_0x322d8f['STEP']=0x1]='STEP';}(_0x3c3574||(_0x3c3574={}));var _0x44ee32=(function(){function _0x2fd60d(_0x5bd264,_0x534001,_0x5db65a){this['name']=_0x5bd264,this['from']=_0x534001,this['to']=_0x5db65a;}return _0x2fd60d['prototype']['clone']=function(){return new _0x2fd60d(this['name'],this['from'],this['to']);},_0x2fd60d;}()),_0x43169a=_0x162675(0x1d),_0x417f41=_0x162675(0x4d),_0x25cf22=_0x162675(0x31),_0x106da3=function(){},_0x1b0498=(function(){function _0x1ebefc(_0x30d550,_0x5b9348,_0x251f51,_0x272435,_0x15188d,_0x3492ad){this['name']=_0x30d550,this['targetProperty']=_0x5b9348,this['framePerSecond']=_0x251f51,this['dataType']=_0x272435,this['loopMode']=_0x15188d,this['enableBlending']=_0x3492ad,this['_runtimeAnimations']=new Array(),this['_events']=new Array(),this['blendingSpeed']=0.01,this['_ranges']={},this['targetPropertyPath']=_0x5b9348['split']('.'),this['dataType']=_0x272435,this['loopMode']=void 0x0===_0x15188d?_0x1ebefc['ANIMATIONLOOPMODE_CYCLE']:_0x15188d;}return _0x1ebefc['_PrepareAnimation']=function(_0x577445,_0x357e66,_0x54d5a7,_0x4ff545,_0x57aeeb,_0x901a7f,_0x3dc066,_0x352688){var _0x30a368=void 0x0;if(!isNaN(parseFloat(_0x57aeeb))&&isFinite(_0x57aeeb)?_0x30a368=_0x1ebefc['ANIMATIONTYPE_FLOAT']:_0x57aeeb instanceof _0x74d525['b']?_0x30a368=_0x1ebefc['ANIMATIONTYPE_QUATERNION']:_0x57aeeb instanceof _0x74d525['e']?_0x30a368=_0x1ebefc['ANIMATIONTYPE_VECTOR3']:_0x57aeeb instanceof _0x74d525['d']?_0x30a368=_0x1ebefc['ANIMATIONTYPE_VECTOR2']:_0x57aeeb instanceof _0x39310d['a']?_0x30a368=_0x1ebefc['ANIMATIONTYPE_COLOR3']:_0x57aeeb instanceof _0x39310d['b']?_0x30a368=_0x1ebefc['ANIMATIONTYPE_COLOR4']:_0x57aeeb instanceof _0x417f41['a']&&(_0x30a368=_0x1ebefc['ANIMATIONTYPE_SIZE']),null==_0x30a368)return null;var _0x53d6fb=new _0x1ebefc(_0x577445,_0x357e66,_0x54d5a7,_0x30a368,_0x3dc066),_0x235800=[{'frame':0x0,'value':_0x57aeeb},{'frame':_0x4ff545,'value':_0x901a7f}];return _0x53d6fb['setKeys'](_0x235800),void 0x0!==_0x352688&&_0x53d6fb['setEasingFunction'](_0x352688),_0x53d6fb;},_0x1ebefc['CreateAnimation']=function(_0x528e79,_0x3280ff,_0x1a153c,_0x530ea1){var _0x57db1d=new _0x1ebefc(_0x528e79+'Animation',_0x528e79,_0x1a153c,_0x3280ff,_0x1ebefc['ANIMATIONLOOPMODE_CONSTANT']);return _0x57db1d['setEasingFunction'](_0x530ea1),_0x57db1d;},_0x1ebefc['CreateAndStartAnimation']=function(_0x1840ce,_0x352767,_0x458f3d,_0x4b4598,_0x3a71e9,_0x35775a,_0x7a4a99,_0x181328,_0x4a05eb,_0x4c9289){var _0x1c0cd3=_0x1ebefc['_PrepareAnimation'](_0x1840ce,_0x458f3d,_0x4b4598,_0x3a71e9,_0x35775a,_0x7a4a99,_0x181328,_0x4a05eb);return _0x1c0cd3?_0x352767['getScene']()['beginDirectAnimation'](_0x352767,[_0x1c0cd3],0x0,_0x3a71e9,0x1===_0x1c0cd3['loopMode'],0x1,_0x4c9289):null;},_0x1ebefc['CreateAndStartHierarchyAnimation']=function(_0x26f4e4,_0x1bfcbd,_0x1781b8,_0x12fb20,_0x243119,_0x4e0bbf,_0x504666,_0x1665cc,_0x2281d8,_0x3cdf46,_0x4cb677){var _0x4b162d=_0x1ebefc['_PrepareAnimation'](_0x26f4e4,_0x12fb20,_0x243119,_0x4e0bbf,_0x504666,_0x1665cc,_0x2281d8,_0x3cdf46);return _0x4b162d?_0x1bfcbd['getScene']()['beginDirectHierarchyAnimation'](_0x1bfcbd,_0x1781b8,[_0x4b162d],0x0,_0x4e0bbf,0x1===_0x4b162d['loopMode'],0x1,_0x4cb677):null;},_0x1ebefc['CreateMergeAndStartAnimation']=function(_0x4f5e19,_0x3afcb6,_0x36b58a,_0xa2dd64,_0x5f4cb0,_0x6c212,_0x364492,_0x2f06f7,_0x8d4679,_0x535a99){var _0x2aa32b=_0x1ebefc['_PrepareAnimation'](_0x4f5e19,_0x36b58a,_0xa2dd64,_0x5f4cb0,_0x6c212,_0x364492,_0x2f06f7,_0x8d4679);return _0x2aa32b?(_0x3afcb6['animations']['push'](_0x2aa32b),_0x3afcb6['getScene']()['beginAnimation'](_0x3afcb6,0x0,_0x5f4cb0,0x1===_0x2aa32b['loopMode'],0x1,_0x535a99)):null;},_0x1ebefc['MakeAnimationAdditive']=function(_0x5d565e,_0xd317a8,_0x2fc960,_0x2e848a,_0x289ace){void 0x0===_0xd317a8&&(_0xd317a8=0x0),void 0x0===_0x2e848a&&(_0x2e848a=!0x1);var _0x2244ef=_0x5d565e;if(_0x2e848a&&((_0x2244ef=_0x5d565e['clone']())['name']=_0x289ace||_0x2244ef['name']),!_0x2244ef['_keys']['length'])return _0x2244ef;_0xd317a8=_0xd317a8>=0x0?_0xd317a8:0x0;var _0x5a9ea0=0x0,_0x45a137=_0x2244ef['_keys'][0x0],_0x1e7f9c=_0x2244ef['_keys']['length']-0x1,_0x588957=_0x2244ef['_keys'][_0x1e7f9c],_0xf00972={'referenceValue':_0x45a137['value'],'referencePosition':_0x74d525['c']['Vector3'][0x0],'referenceQuaternion':_0x74d525['c']['Quaternion'][0x0],'referenceScaling':_0x74d525['c']['Vector3'][0x1],'keyPosition':_0x74d525['c']['Vector3'][0x2],'keyQuaternion':_0x74d525['c']['Quaternion'][0x1],'keyScaling':_0x74d525['c']['Vector3'][0x3]},_0x4bdc4c=!0x1,_0x48bb97=_0x45a137['frame'],_0x1cac73=_0x588957['frame'];if(_0x2fc960){var _0x5f2b08=_0x2244ef['getRange'](_0x2fc960);_0x5f2b08&&(_0x48bb97=_0x5f2b08['from'],_0x1cac73=_0x5f2b08['to']);}var _0x2ba944=_0x45a137['frame']===_0x48bb97,_0x33433f=_0x588957['frame']===_0x1cac73;if(0x1===_0x2244ef['_keys']['length']){var _0x2432f2=_0x2244ef['_getKeyValue'](_0x2244ef['_keys'][0x0]);_0xf00972['referenceValue']=_0x2432f2['clone']?_0x2432f2['clone']():_0x2432f2,_0x4bdc4c=!0x0;}else{if(_0xd317a8<=_0x45a137['frame'])_0x2432f2=_0x2244ef['_getKeyValue'](_0x45a137['value']),(_0xf00972['referenceValue']=_0x2432f2['clone']?_0x2432f2['clone']():_0x2432f2,_0x4bdc4c=!0x0);else _0xd317a8>=_0x588957['frame']&&(_0x2432f2=_0x2244ef['_getKeyValue'](_0x588957['value']),(_0xf00972['referenceValue']=_0x2432f2['clone']?_0x2432f2['clone']():_0x2432f2,_0x4bdc4c=!0x0));}for(var _0x5ad167=0x0;!_0x4bdc4c||!_0x2ba944||!_0x33433f&&_0x5ad167<_0x2244ef['_keys']['length']-0x1;){var _0x576862=_0x2244ef['_keys'][_0x5ad167],_0x4a871f=_0x2244ef['_keys'][_0x5ad167+0x1];if(!_0x4bdc4c&&_0xd317a8>=_0x576862['frame']&&_0xd317a8<=_0x4a871f['frame']){_0x2432f2=void 0x0;if(_0xd317a8===_0x576862['frame'])_0x2432f2=_0x2244ef['_getKeyValue'](_0x576862['value']);else{if(_0xd317a8===_0x4a871f['frame'])_0x2432f2=_0x2244ef['_getKeyValue'](_0x4a871f['value']);else{var _0x3e7c5d={'key':_0x5ad167,'repeatCount':0x0,'loopMode':this['ANIMATIONLOOPMODE_CONSTANT']};_0x2432f2=_0x2244ef['_interpolate'](_0xd317a8,_0x3e7c5d);}}_0xf00972['referenceValue']=_0x2432f2['clone']?_0x2432f2['clone']():_0x2432f2,_0x4bdc4c=!0x0;}if(!_0x2ba944&&_0x48bb97>=_0x576862['frame']&&_0x48bb97<=_0x4a871f['frame']){if(_0x48bb97===_0x576862['frame'])_0x5a9ea0=_0x5ad167;else{if(_0x48bb97===_0x4a871f['frame'])_0x5a9ea0=_0x5ad167+0x1;else{_0x3e7c5d={'key':_0x5ad167,'repeatCount':0x0,'loopMode':this['ANIMATIONLOOPMODE_CONSTANT']};var _0x54774d={'frame':_0x48bb97,'value':(_0x2432f2=_0x2244ef['_interpolate'](_0x48bb97,_0x3e7c5d))['clone']?_0x2432f2['clone']():_0x2432f2};_0x2244ef['_keys']['splice'](_0x5ad167+0x1,0x0,_0x54774d),_0x5a9ea0=_0x5ad167+0x1;}}_0x2ba944=!0x0;}if(!_0x33433f&&_0x1cac73>=_0x576862['frame']&&_0x1cac73<=_0x4a871f['frame']){if(_0x1cac73===_0x576862['frame'])_0x1e7f9c=_0x5ad167;else{if(_0x1cac73===_0x4a871f['frame'])_0x1e7f9c=_0x5ad167+0x1;else _0x3e7c5d={'key':_0x5ad167,'repeatCount':0x0,'loopMode':this['ANIMATIONLOOPMODE_CONSTANT']},_0x54774d={'frame':_0x1cac73,'value':(_0x2432f2=_0x2244ef['_interpolate'](_0x1cac73,_0x3e7c5d))['clone']?_0x2432f2['clone']():_0x2432f2},(_0x2244ef['_keys']['splice'](_0x5ad167+0x1,0x0,_0x54774d),_0x1e7f9c=_0x5ad167+0x1);}_0x33433f=!0x0;}_0x5ad167++;}_0x2244ef['dataType']===_0x1ebefc['ANIMATIONTYPE_QUATERNION']?_0xf00972['referenceValue']['normalize']()['conjugateInPlace']():_0x2244ef['dataType']===_0x1ebefc['ANIMATIONTYPE_MATRIX']&&(_0xf00972['referenceValue']['decompose'](_0xf00972['referenceScaling'],_0xf00972['referenceQuaternion'],_0xf00972['referencePosition']),_0xf00972['referenceQuaternion']['normalize']()['conjugateInPlace']());for(_0x5ad167=_0x5a9ea0;_0x5ad167<=_0x1e7f9c;_0x5ad167++){_0x54774d=_0x2244ef['_keys'][_0x5ad167];if(!_0x5ad167||_0x2244ef['dataType']===_0x1ebefc['ANIMATIONTYPE_FLOAT']||_0x54774d['value']!==_0x45a137['value'])switch(_0x2244ef['dataType']){case _0x1ebefc['ANIMATIONTYPE_MATRIX']:_0x54774d['value']['decompose'](_0xf00972['keyScaling'],_0xf00972['keyQuaternion'],_0xf00972['keyPosition']),_0xf00972['keyPosition']['subtractInPlace'](_0xf00972['referencePosition']),_0xf00972['keyScaling']['divideInPlace'](_0xf00972['referenceScaling']),_0xf00972['referenceQuaternion']['multiplyToRef'](_0xf00972['keyQuaternion'],_0xf00972['keyQuaternion']),_0x74d525['a']['ComposeToRef'](_0xf00972['keyScaling'],_0xf00972['keyQuaternion'],_0xf00972['keyPosition'],_0x54774d['value']);break;case _0x1ebefc['ANIMATIONTYPE_QUATERNION']:_0xf00972['referenceValue']['multiplyToRef'](_0x54774d['value'],_0x54774d['value']);break;case _0x1ebefc['ANIMATIONTYPE_VECTOR2']:case _0x1ebefc['ANIMATIONTYPE_VECTOR3']:case _0x1ebefc['ANIMATIONTYPE_COLOR3']:case _0x1ebefc['ANIMATIONTYPE_COLOR4']:_0x54774d['value']['subtractToRef'](_0xf00972['referenceValue'],_0x54774d['value']);break;case _0x1ebefc['ANIMATIONTYPE_SIZE']:_0x54774d['value']['width']-=_0xf00972['referenceValue']['width'],_0x54774d['value']['height']-=_0xf00972['referenceValue']['height'];break;default:_0x54774d['value']-=_0xf00972['referenceValue'];}}return _0x2244ef;},_0x1ebefc['TransitionTo']=function(_0x5a7f50,_0x4ab84d,_0x47c630,_0x360066,_0x39abb9,_0x512f1a,_0x13da75,_0x507bbb){if(void 0x0===_0x507bbb&&(_0x507bbb=null),_0x13da75<=0x0)return _0x47c630[_0x5a7f50]=_0x4ab84d,_0x507bbb&&_0x507bbb(),null;var _0x356568=_0x39abb9*(_0x13da75/0x3e8);_0x512f1a['setKeys']([{'frame':0x0,'value':_0x47c630[_0x5a7f50]['clone']?_0x47c630[_0x5a7f50]['clone']():_0x47c630[_0x5a7f50]},{'frame':_0x356568,'value':_0x4ab84d}]),_0x47c630['animations']||(_0x47c630['animations']=[]),_0x47c630['animations']['push'](_0x512f1a);var _0xd489b=_0x360066['beginAnimation'](_0x47c630,0x0,_0x356568,!0x1);return _0xd489b['onAnimationEnd']=_0x507bbb,_0xd489b;},Object['defineProperty'](_0x1ebefc['prototype'],'runtimeAnimations',{'get':function(){return this['_runtimeAnimations'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1ebefc['prototype'],'hasRunningRuntimeAnimations',{'get':function(){for(var _0x585d66=0x0,_0xdcde5f=this['_runtimeAnimations'];_0x585d66<_0xdcde5f['length'];_0x585d66++){if(!_0xdcde5f[_0x585d66]['isStopped'])return!0x0;}return!0x1;},'enumerable':!0x1,'configurable':!0x0}),_0x1ebefc['prototype']['toString']=function(_0x1449a0){var _0x3ae141='Name:\x20'+this['name']+',\x20property:\x20'+this['targetProperty'];if(_0x3ae141+=',\x20datatype:\x20'+['Float','Vector3','Quaternion','Matrix','Color3','Vector2'][this['dataType']],_0x3ae141+=',\x20nKeys:\x20'+(this['_keys']?this['_keys']['length']:'none'),_0x3ae141+=',\x20nRanges:\x20'+(this['_ranges']?Object['keys'](this['_ranges'])['length']:'none'),_0x1449a0){_0x3ae141+=',\x20Ranges:\x20{';var _0x4461f7=!0x0;for(var _0x293e48 in this['_ranges'])_0x4461f7&&(_0x3ae141+=',\x20',_0x4461f7=!0x1),_0x3ae141+=_0x293e48;_0x3ae141+='}';}return _0x3ae141;},_0x1ebefc['prototype']['addEvent']=function(_0x1d73df){this['_events']['push'](_0x1d73df),this['_events']['sort'](function(_0x355b4e,_0x34e6fe){return _0x355b4e['frame']-_0x34e6fe['frame'];});},_0x1ebefc['prototype']['removeEvents']=function(_0x5f2e83){for(var _0x4d24e4=0x0;_0x4d24e4=0x0;_0x3f240b--)this['_keys'][_0x3f240b]['frame']>=_0x1e6faa&&this['_keys'][_0x3f240b]['frame']<=_0xbc6d31&&this['_keys']['splice'](_0x3f240b,0x1);}this['_ranges'][_0x549ccf]=null;}},_0x1ebefc['prototype']['getRange']=function(_0x3b4a6a){return this['_ranges'][_0x3b4a6a];},_0x1ebefc['prototype']['getKeys']=function(){return this['_keys'];},_0x1ebefc['prototype']['getHighestFrame']=function(){for(var _0x57761b=0x0,_0x1ebe28=0x0,_0x10e1ed=this['_keys']['length'];_0x1ebe28<_0x10e1ed;_0x1ebe28++)_0x57761b0x0)return _0x147957['highLimitValue']['clone']?_0x147957['highLimitValue']['clone']():_0x147957['highLimitValue'];var _0x43df12=this['_keys'];if(0x1===_0x43df12['length'])return this['_getKeyValue'](_0x43df12[0x0]['value']);var _0xc9eb01=_0x147957['key'];if(_0x43df12[_0xc9eb01]['frame']>=_0x5ac9d4){for(;_0xc9eb01-0x1>=0x0&&_0x43df12[_0xc9eb01]['frame']>=_0x5ac9d4;)_0xc9eb01--;}for(var _0x2eb703=_0xc9eb01;_0x2eb703<_0x43df12['length'];_0x2eb703++){var _0x91d1a8=_0x43df12[_0x2eb703+0x1];if(_0x91d1a8['frame']>=_0x5ac9d4){_0x147957['key']=_0x2eb703;var _0xdabde9=_0x43df12[_0x2eb703],_0x2132a6=this['_getKeyValue'](_0xdabde9['value']);if(_0xdabde9['interpolation']===_0x3c3574['STEP'])return _0x2132a6;var _0x57e5d7=this['_getKeyValue'](_0x91d1a8['value']),_0x57de19=void 0x0!==_0xdabde9['outTangent']&&void 0x0!==_0x91d1a8['inTangent'],_0x4eec9b=_0x91d1a8['frame']-_0xdabde9['frame'],_0x3b1ea1=(_0x5ac9d4-_0xdabde9['frame'])/_0x4eec9b,_0x7a31b7=this['getEasingFunction']();switch(null!=_0x7a31b7&&(_0x3b1ea1=_0x7a31b7['ease'](_0x3b1ea1)),this['dataType']){case _0x1ebefc['ANIMATIONTYPE_FLOAT']:var _0x46ed29=_0x57de19?this['floatInterpolateFunctionWithTangents'](_0x2132a6,_0xdabde9['outTangent']*_0x4eec9b,_0x57e5d7,_0x91d1a8['inTangent']*_0x4eec9b,_0x3b1ea1):this['floatInterpolateFunction'](_0x2132a6,_0x57e5d7,_0x3b1ea1);switch(_0x147957['loopMode']){case _0x1ebefc['ANIMATIONLOOPMODE_CYCLE']:case _0x1ebefc['ANIMATIONLOOPMODE_CONSTANT']:return _0x46ed29;case _0x1ebefc['ANIMATIONLOOPMODE_RELATIVE']:return _0x147957['offsetValue']*_0x147957['repeatCount']+_0x46ed29;}break;case _0x1ebefc['ANIMATIONTYPE_QUATERNION']:var _0x459fc5=_0x57de19?this['quaternionInterpolateFunctionWithTangents'](_0x2132a6,_0xdabde9['outTangent']['scale'](_0x4eec9b),_0x57e5d7,_0x91d1a8['inTangent']['scale'](_0x4eec9b),_0x3b1ea1):this['quaternionInterpolateFunction'](_0x2132a6,_0x57e5d7,_0x3b1ea1);switch(_0x147957['loopMode']){case _0x1ebefc['ANIMATIONLOOPMODE_CYCLE']:case _0x1ebefc['ANIMATIONLOOPMODE_CONSTANT']:return _0x459fc5;case _0x1ebefc['ANIMATIONLOOPMODE_RELATIVE']:return _0x459fc5['addInPlace'](_0x147957['offsetValue']['scale'](_0x147957['repeatCount']));}return _0x459fc5;case _0x1ebefc['ANIMATIONTYPE_VECTOR3']:var _0x598fbb=_0x57de19?this['vector3InterpolateFunctionWithTangents'](_0x2132a6,_0xdabde9['outTangent']['scale'](_0x4eec9b),_0x57e5d7,_0x91d1a8['inTangent']['scale'](_0x4eec9b),_0x3b1ea1):this['vector3InterpolateFunction'](_0x2132a6,_0x57e5d7,_0x3b1ea1);switch(_0x147957['loopMode']){case _0x1ebefc['ANIMATIONLOOPMODE_CYCLE']:case _0x1ebefc['ANIMATIONLOOPMODE_CONSTANT']:return _0x598fbb;case _0x1ebefc['ANIMATIONLOOPMODE_RELATIVE']:return _0x598fbb['add'](_0x147957['offsetValue']['scale'](_0x147957['repeatCount']));}case _0x1ebefc['ANIMATIONTYPE_VECTOR2']:var _0xe9a552=_0x57de19?this['vector2InterpolateFunctionWithTangents'](_0x2132a6,_0xdabde9['outTangent']['scale'](_0x4eec9b),_0x57e5d7,_0x91d1a8['inTangent']['scale'](_0x4eec9b),_0x3b1ea1):this['vector2InterpolateFunction'](_0x2132a6,_0x57e5d7,_0x3b1ea1);switch(_0x147957['loopMode']){case _0x1ebefc['ANIMATIONLOOPMODE_CYCLE']:case _0x1ebefc['ANIMATIONLOOPMODE_CONSTANT']:return _0xe9a552;case _0x1ebefc['ANIMATIONLOOPMODE_RELATIVE']:return _0xe9a552['add'](_0x147957['offsetValue']['scale'](_0x147957['repeatCount']));}case _0x1ebefc['ANIMATIONTYPE_SIZE']:switch(_0x147957['loopMode']){case _0x1ebefc['ANIMATIONLOOPMODE_CYCLE']:case _0x1ebefc['ANIMATIONLOOPMODE_CONSTANT']:return this['sizeInterpolateFunction'](_0x2132a6,_0x57e5d7,_0x3b1ea1);case _0x1ebefc['ANIMATIONLOOPMODE_RELATIVE']:return this['sizeInterpolateFunction'](_0x2132a6,_0x57e5d7,_0x3b1ea1)['add'](_0x147957['offsetValue']['scale'](_0x147957['repeatCount']));}case _0x1ebefc['ANIMATIONTYPE_COLOR3']:switch(_0x147957['loopMode']){case _0x1ebefc['ANIMATIONLOOPMODE_CYCLE']:case _0x1ebefc['ANIMATIONLOOPMODE_CONSTANT']:return this['color3InterpolateFunction'](_0x2132a6,_0x57e5d7,_0x3b1ea1);case _0x1ebefc['ANIMATIONLOOPMODE_RELATIVE']:return this['color3InterpolateFunction'](_0x2132a6,_0x57e5d7,_0x3b1ea1)['add'](_0x147957['offsetValue']['scale'](_0x147957['repeatCount']));}case _0x1ebefc['ANIMATIONTYPE_COLOR4']:switch(_0x147957['loopMode']){case _0x1ebefc['ANIMATIONLOOPMODE_CYCLE']:case _0x1ebefc['ANIMATIONLOOPMODE_CONSTANT']:return this['color4InterpolateFunction'](_0x2132a6,_0x57e5d7,_0x3b1ea1);case _0x1ebefc['ANIMATIONLOOPMODE_RELATIVE']:return this['color4InterpolateFunction'](_0x2132a6,_0x57e5d7,_0x3b1ea1)['add'](_0x147957['offsetValue']['scale'](_0x147957['repeatCount']));}case _0x1ebefc['ANIMATIONTYPE_MATRIX']:switch(_0x147957['loopMode']){case _0x1ebefc['ANIMATIONLOOPMODE_CYCLE']:case _0x1ebefc['ANIMATIONLOOPMODE_CONSTANT']:if(_0x1ebefc['AllowMatricesInterpolation'])return this['matrixInterpolateFunction'](_0x2132a6,_0x57e5d7,_0x3b1ea1,_0x147957['workValue']);case _0x1ebefc['ANIMATIONLOOPMODE_RELATIVE']:return _0x2132a6;}}break;}}return this['_getKeyValue'](_0x43df12[_0x43df12['length']-0x1]['value']);},_0x1ebefc['prototype']['matrixInterpolateFunction']=function(_0x2b504e,_0x57c73d,_0xe84876,_0x5399e4){return _0x1ebefc['AllowMatrixDecomposeForInterpolation']?_0x5399e4?(_0x74d525['a']['DecomposeLerpToRef'](_0x2b504e,_0x57c73d,_0xe84876,_0x5399e4),_0x5399e4):_0x74d525['a']['DecomposeLerp'](_0x2b504e,_0x57c73d,_0xe84876):_0x5399e4?(_0x74d525['a']['LerpToRef'](_0x2b504e,_0x57c73d,_0xe84876,_0x5399e4),_0x5399e4):_0x74d525['a']['Lerp'](_0x2b504e,_0x57c73d,_0xe84876);},_0x1ebefc['prototype']['clone']=function(){var _0x475482=new _0x1ebefc(this['name'],this['targetPropertyPath']['join']('.'),this['framePerSecond'],this['dataType'],this['loopMode']);if(_0x475482['enableBlending']=this['enableBlending'],_0x475482['blendingSpeed']=this['blendingSpeed'],this['_keys']&&_0x475482['setKeys'](this['_keys']),this['_ranges'])for(var _0xc4a7be in(_0x475482['_ranges']={},this['_ranges'])){var _0x2e7961=this['_ranges'][_0xc4a7be];_0x2e7961&&(_0x475482['_ranges'][_0xc4a7be]=_0x2e7961['clone']());}return _0x475482;},_0x1ebefc['prototype']['setKeys']=function(_0x218eef){this['_keys']=_0x218eef['slice'](0x0);},_0x1ebefc['prototype']['serialize']=function(){var _0x52cfe1={};_0x52cfe1['name']=this['name'],_0x52cfe1['property']=this['targetProperty'],_0x52cfe1['framePerSecond']=this['framePerSecond'],_0x52cfe1['dataType']=this['dataType'],_0x52cfe1['loopBehavior']=this['loopMode'],_0x52cfe1['enableBlending']=this['enableBlending'],_0x52cfe1['blendingSpeed']=this['blendingSpeed'];var _0x1e2d3a=this['dataType'];_0x52cfe1['keys']=[];for(var _0x3734ab=this['getKeys'](),_0x1ad27e=0x0;_0x1ad27e<_0x3734ab['length'];_0x1ad27e++){var _0x240f3b=_0x3734ab[_0x1ad27e],_0xa0eb67={};switch(_0xa0eb67['frame']=_0x240f3b['frame'],_0x1e2d3a){case _0x1ebefc['ANIMATIONTYPE_FLOAT']:_0xa0eb67['values']=[_0x240f3b['value']],void 0x0!==_0x240f3b['inTangent']&&_0xa0eb67['values']['push'](_0x240f3b['inTangent']),void 0x0!==_0x240f3b['outTangent']&&(void 0x0===_0x240f3b['inTangent']&&_0xa0eb67['values']['push'](void 0x0),_0xa0eb67['values']['push'](_0x240f3b['outTangent']));break;case _0x1ebefc['ANIMATIONTYPE_QUATERNION']:case _0x1ebefc['ANIMATIONTYPE_MATRIX']:case _0x1ebefc['ANIMATIONTYPE_VECTOR3']:case _0x1ebefc['ANIMATIONTYPE_COLOR3']:case _0x1ebefc['ANIMATIONTYPE_COLOR4']:_0xa0eb67['values']=_0x240f3b['value']['asArray'](),null!=_0x240f3b['inTangent']&&_0xa0eb67['values']['push'](_0x240f3b['inTangent']['asArray']()),null!=_0x240f3b['outTangent']&&(void 0x0===_0x240f3b['inTangent']&&_0xa0eb67['values']['push'](void 0x0),_0xa0eb67['values']['push'](_0x240f3b['outTangent']['asArray']()));}_0x52cfe1['keys']['push'](_0xa0eb67);}for(var _0x2cfd36 in(_0x52cfe1['ranges']=[],this['_ranges'])){var _0x308ddb=this['_ranges'][_0x2cfd36];if(_0x308ddb){var _0x2e673c={};_0x2e673c['name']=_0x2cfd36,_0x2e673c['from']=_0x308ddb['from'],_0x2e673c['to']=_0x308ddb['to'],_0x52cfe1['ranges']['push'](_0x2e673c);}}return _0x52cfe1;},_0x1ebefc['_UniversalLerp']=function(_0x54ccc6,_0x294241,_0x3c29c9){var _0x439c25=_0x54ccc6['constructor'];return _0x439c25['Lerp']?_0x439c25['Lerp'](_0x54ccc6,_0x294241,_0x3c29c9):_0x439c25['Slerp']?_0x439c25['Slerp'](_0x54ccc6,_0x294241,_0x3c29c9):_0x54ccc6['toFixed']?_0x54ccc6*(0x1-_0x3c29c9)+_0x3c29c9*_0x294241:_0x294241;},_0x1ebefc['Parse']=function(_0x54e3e2){var _0x2bf045,_0x40e2b9,_0x37d3ba=new _0x1ebefc(_0x54e3e2['name'],_0x54e3e2['property'],_0x54e3e2['framePerSecond'],_0x54e3e2['dataType'],_0x54e3e2['loopBehavior']),_0x1c5b7f=_0x54e3e2['dataType'],_0x310d72=[];for(_0x54e3e2['enableBlending']&&(_0x37d3ba['enableBlending']=_0x54e3e2['enableBlending']),_0x54e3e2['blendingSpeed']&&(_0x37d3ba['blendingSpeed']=_0x54e3e2['blendingSpeed']),_0x40e2b9=0x0;_0x40e2b9<_0x54e3e2['keys']['length'];_0x40e2b9++){var _0x242eca,_0x1bc052,_0x1051ed=_0x54e3e2['keys'][_0x40e2b9];switch(_0x1c5b7f){case _0x1ebefc['ANIMATIONTYPE_FLOAT']:_0x2bf045=_0x1051ed['values'][0x0],_0x1051ed['values']['length']>=0x1&&(_0x242eca=_0x1051ed['values'][0x1]),_0x1051ed['values']['length']>=0x2&&(_0x1bc052=_0x1051ed['values'][0x2]);break;case _0x1ebefc['ANIMATIONTYPE_QUATERNION']:if(_0x2bf045=_0x74d525['b']['FromArray'](_0x1051ed['values']),_0x1051ed['values']['length']>=0x8){var _0x1b8674=_0x74d525['b']['FromArray'](_0x1051ed['values']['slice'](0x4,0x8));_0x1b8674['equals'](_0x74d525['b']['Zero']())||(_0x242eca=_0x1b8674);}if(_0x1051ed['values']['length']>=0xc){var _0x20f906=_0x74d525['b']['FromArray'](_0x1051ed['values']['slice'](0x8,0xc));_0x20f906['equals'](_0x74d525['b']['Zero']())||(_0x1bc052=_0x20f906);}break;case _0x1ebefc['ANIMATIONTYPE_MATRIX']:_0x2bf045=_0x74d525['a']['FromArray'](_0x1051ed['values']);break;case _0x1ebefc['ANIMATIONTYPE_COLOR3']:_0x2bf045=_0x39310d['a']['FromArray'](_0x1051ed['values']);break;case _0x1ebefc['ANIMATIONTYPE_COLOR4']:_0x2bf045=_0x39310d['b']['FromArray'](_0x1051ed['values']);break;case _0x1ebefc['ANIMATIONTYPE_VECTOR3']:default:_0x2bf045=_0x74d525['e']['FromArray'](_0x1051ed['values']);}var _0x59c84e={};_0x59c84e['frame']=_0x1051ed['frame'],_0x59c84e['value']=_0x2bf045,null!=_0x242eca&&(_0x59c84e['inTangent']=_0x242eca),null!=_0x1bc052&&(_0x59c84e['outTangent']=_0x1bc052),_0x310d72['push'](_0x59c84e);}if(_0x37d3ba['setKeys'](_0x310d72),_0x54e3e2['ranges']){for(_0x40e2b9=0x0;_0x40e2b9<_0x54e3e2['ranges']['length'];_0x40e2b9++)_0x2bf045=_0x54e3e2['ranges'][_0x40e2b9],_0x37d3ba['createRange'](_0x2bf045['name'],_0x2bf045['from'],_0x2bf045['to']);}return _0x37d3ba;},_0x1ebefc['AppendSerializedAnimations']=function(_0x171375,_0x2f23d7){_0x495d06['a']['AppendSerializedAnimations'](_0x171375,_0x2f23d7);},_0x1ebefc['ParseFromFileAsync']=function(_0x4eb730,_0xe8c2d1){var _0x2c49b4=this;return new Promise(function(_0x765ca,_0x23c400){var _0x4c7d21=new _0x25cf22['a']();_0x4c7d21['addEventListener']('readystatechange',function(){if(0x4==_0x4c7d21['readyState']){if(0xc8==_0x4c7d21['status']){var _0x474cf2=JSON['parse'](_0x4c7d21['responseText']);if(_0x474cf2['length']){for(var _0x7da1b4=new Array(),_0x52a0e1=0x0,_0x1d5f60=_0x474cf2;_0x52a0e1<_0x1d5f60['length'];_0x52a0e1++){var _0x223530=_0x1d5f60[_0x52a0e1];_0x7da1b4['push'](_0x2c49b4['Parse'](_0x223530));}_0x765ca(_0x7da1b4);}else _0x7da1b4=_0x2c49b4['Parse'](_0x474cf2),(_0x4eb730&&(_0x7da1b4['name']=_0x4eb730),_0x765ca(_0x7da1b4));}else _0x23c400('Unable\x20to\x20load\x20the\x20animation');}}),_0x4c7d21['open']('GET',_0xe8c2d1),_0x4c7d21['send']();});},_0x1ebefc['CreateFromSnippetAsync']=function(_0x3fb95c){var _0x595d40=this;return new Promise(function(_0x2b19bd,_0x10f169){var _0x3f3656=new _0x25cf22['a']();_0x3f3656['addEventListener']('readystatechange',function(){if(0x4==_0x3f3656['readyState']){if(0xc8==_0x3f3656['status']){var _0x4e79ef=JSON['parse'](JSON['parse'](_0x3f3656['responseText'])['jsonPayload']);if(_0x4e79ef['animations']){for(var _0x5b1041=JSON['parse'](_0x4e79ef['animations']),_0x5cf4a5=new Array(),_0x43fee4=0x0,_0x12406a=_0x5b1041;_0x43fee4<_0x12406a['length'];_0x43fee4++){var _0x8f5cdc=_0x12406a[_0x43fee4];_0x5cf4a5['push'](_0x595d40['Parse'](_0x8f5cdc));}_0x2b19bd(_0x5cf4a5);}else _0x5b1041=JSON['parse'](_0x4e79ef['animation']),((_0x5cf4a5=_0x595d40['Parse'](_0x5b1041))['snippetId']=_0x3fb95c,_0x2b19bd(_0x5cf4a5));}else _0x10f169('Unable\x20to\x20load\x20the\x20snippet\x20'+_0x3fb95c);}}),_0x3f3656['open']('GET',_0x595d40['SnippetUrl']+'/'+_0x3fb95c['replace'](/#/g,'/')),_0x3f3656['send']();});},_0x1ebefc['AllowMatricesInterpolation']=!0x1,_0x1ebefc['AllowMatrixDecomposeForInterpolation']=!0x0,_0x1ebefc['SnippetUrl']='https://snippet.babylonjs.com',_0x1ebefc['ANIMATIONTYPE_FLOAT']=0x0,_0x1ebefc['ANIMATIONTYPE_VECTOR3']=0x1,_0x1ebefc['ANIMATIONTYPE_QUATERNION']=0x2,_0x1ebefc['ANIMATIONTYPE_MATRIX']=0x3,_0x1ebefc['ANIMATIONTYPE_COLOR3']=0x4,_0x1ebefc['ANIMATIONTYPE_COLOR4']=0x7,_0x1ebefc['ANIMATIONTYPE_VECTOR2']=0x5,_0x1ebefc['ANIMATIONTYPE_SIZE']=0x6,_0x1ebefc['ANIMATIONLOOPMODE_RELATIVE']=0x0,_0x1ebefc['ANIMATIONLOOPMODE_CYCLE']=0x1,_0x1ebefc['ANIMATIONLOOPMODE_CONSTANT']=0x2,_0x1ebefc;}());_0x3cd573['a']['RegisteredTypes']['BABYLON.Animation']=_0x1b0498,_0x43169a['a']['_AnimationRangeFactory']=function(_0x5dfb17,_0x351d06,_0x21607f){return new _0x44ee32(_0x5dfb17,_0x351d06,_0x21607f);};var _0x323857=function(_0x50d198){function _0x3ab093(_0x48b4fb,_0x373a32,_0x2d04f5,_0x54a4b9,_0x2e0e78,_0x4149c2,_0x4c9851,_0x5b9e6e){void 0x0===_0x2e0e78&&(_0x2e0e78=0x3e8);var _0x3a32d4=_0x50d198['call'](this,_0x48b4fb,_0x4149c2)||this;return _0x3a32d4['duration']=0x3e8,_0x3a32d4['onInterpolationDoneObservable']=new _0x6ac1f7['c'](),_0x3a32d4['propertyPath']=_0x2d04f5,_0x3a32d4['value']=_0x54a4b9,_0x3a32d4['duration']=_0x2e0e78,_0x3a32d4['stopOtherAnimations']=_0x4c9851,_0x3a32d4['onInterpolationDone']=_0x5b9e6e,_0x3a32d4['_target']=_0x3a32d4['_effectiveTarget']=_0x373a32,_0x3a32d4;}return Object(_0x18e13d['d'])(_0x3ab093,_0x50d198),_0x3ab093['prototype']['_prepare']=function(){this['_effectiveTarget']=this['_getEffectiveTarget'](this['_effectiveTarget'],this['propertyPath']),this['_property']=this['_getProperty'](this['propertyPath']);},_0x3ab093['prototype']['execute']=function(){var _0x5c7876,_0xd0bd57=this,_0x53937a=this['_actionManager']['getScene'](),_0x402871=[{'frame':0x0,'value':this['_effectiveTarget'][this['_property']]},{'frame':0x64,'value':this['value']}];if('number'==typeof this['value'])_0x5c7876=_0x1b0498['ANIMATIONTYPE_FLOAT'];else{if(this['value']instanceof _0x39310d['a'])_0x5c7876=_0x1b0498['ANIMATIONTYPE_COLOR3'];else{if(this['value']instanceof _0x74d525['e'])_0x5c7876=_0x1b0498['ANIMATIONTYPE_VECTOR3'];else{if(this['value']instanceof _0x74d525['a'])_0x5c7876=_0x1b0498['ANIMATIONTYPE_MATRIX'];else{if(!(this['value']instanceof _0x74d525['b']))return void _0x75193d['a']['Warn']('InterpolateValueAction:\x20Unsupported\x20type\x20('+typeof this['value']+')');_0x5c7876=_0x1b0498['ANIMATIONTYPE_QUATERNION'];}}}}var _0x3d4791=new _0x1b0498('InterpolateValueAction',this['_property'],0x3e8/this['duration']*0x64,_0x5c7876,_0x1b0498['ANIMATIONLOOPMODE_CONSTANT']);_0x3d4791['setKeys'](_0x402871),this['stopOtherAnimations']&&_0x53937a['stopAnimation'](this['_effectiveTarget']),_0x53937a['beginDirectAnimation'](this['_effectiveTarget'],[_0x3d4791],0x0,0x64,!0x1,0x1,function(){_0xd0bd57['onInterpolationDoneObservable']['notifyObservers'](_0xd0bd57),_0xd0bd57['onInterpolationDone']&&_0xd0bd57['onInterpolationDone']();});},_0x3ab093['prototype']['serialize']=function(_0x392152){return _0x50d198['prototype']['_serialize']['call'](this,{'name':'InterpolateValueAction','properties':[_0x26efb5['_GetTargetProperty'](this['_target']),{'name':'propertyPath','value':this['propertyPath']},{'name':'value','value':_0x26efb5['_SerializeValueAsString'](this['value'])},{'name':'duration','value':_0x26efb5['_SerializeValueAsString'](this['duration'])},{'name':'stopOtherAnimations','value':_0x26efb5['_SerializeValueAsString'](this['stopOtherAnimations'])||!0x1}]},_0x392152);},_0x3ab093;}(_0x26efb5);_0x3cd573['a']['RegisteredTypes']['BABYLON.InterpolateValueAction']=_0x323857;var _0x3de49a=Object['freeze'](new _0x74d525['b'](0x0,0x0,0x0,0x0)),_0x12bb4e=Object['freeze'](_0x74d525['e']['Zero']()),_0x135b84=Object['freeze'](_0x74d525['d']['Zero']()),_0x454b5d=Object['freeze'](_0x417f41['a']['Zero']()),_0x2963cf=Object['freeze'](_0x39310d['a']['Black']()),_0xfb2c56=(function(){function _0x39a9e8(_0x4bcf68,_0x350433,_0x15a15d,_0x54595a){var _0x259a85=this;if(this['_events']=new Array(),this['_currentFrame']=0x0,this['_originalValue']=new Array(),this['_originalBlendValue']=null,this['_offsetsCache']={},this['_highLimitsCache']={},this['_stopped']=!0x1,this['_blendingFactor']=0x0,this['_currentValue']=null,this['_currentActiveTarget']=null,this['_directTarget']=null,this['_targetPath']='',this['_weight']=0x1,this['_ratioOffset']=0x0,this['_previousDelay']=0x0,this['_previousRatio']=0x0,this['_targetIsArray']=!0x1,this['_animation']=_0x350433,this['_target']=_0x4bcf68,this['_scene']=_0x15a15d,this['_host']=_0x54595a,this['_activeTargets']=[],_0x350433['_runtimeAnimations']['push'](this),this['_animationState']={'key':0x0,'repeatCount':0x0,'loopMode':this['_getCorrectLoopMode']()},this['_animation']['dataType']===_0x1b0498['ANIMATIONTYPE_MATRIX']&&(this['_animationState']['workValue']=_0x74d525['a']['Zero']()),this['_keys']=this['_animation']['getKeys'](),this['_minFrame']=this['_keys'][0x0]['frame'],this['_maxFrame']=this['_keys'][this['_keys']['length']-0x1]['frame'],this['_minValue']=this['_keys'][0x0]['value'],this['_maxValue']=this['_keys'][this['_keys']['length']-0x1]['value'],0x0!==this['_minFrame']){var _0x405024={'frame':0x0,'value':this['_minValue']};this['_keys']['splice'](0x0,0x0,_0x405024);}if(this['_target']instanceof Array){for(var _0x65bff8=0x0,_0x5c1f09=0x0,_0x1d45d1=this['_target'];_0x5c1f09<_0x1d45d1['length'];_0x5c1f09++){var _0x1fb1dd=_0x1d45d1[_0x5c1f09];this['_preparePath'](_0x1fb1dd,_0x65bff8),this['_getOriginalValues'](_0x65bff8),_0x65bff8++;}this['_targetIsArray']=!0x0;}else this['_preparePath'](this['_target']),this['_getOriginalValues'](),this['_targetIsArray']=!0x1,this['_directTarget']=this['_activeTargets'][0x0];var _0x125e37=_0x350433['getEvents']();_0x125e37&&_0x125e37['length']>0x0&&_0x125e37['forEach'](function(_0x2f9ff2){_0x259a85['_events']['push'](_0x2f9ff2['_clone']());}),this['_enableBlending']=_0x4bcf68&&_0x4bcf68['animationPropertiesOverride']?_0x4bcf68['animationPropertiesOverride']['enableBlending']:this['_animation']['enableBlending'];}return Object['defineProperty'](_0x39a9e8['prototype'],'currentFrame',{'get':function(){return this['_currentFrame'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x39a9e8['prototype'],'weight',{'get':function(){return this['_weight'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x39a9e8['prototype'],'currentValue',{'get':function(){return this['_currentValue'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x39a9e8['prototype'],'targetPath',{'get':function(){return this['_targetPath'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x39a9e8['prototype'],'target',{'get':function(){return this['_currentActiveTarget'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x39a9e8['prototype'],'isAdditive',{'get':function(){return this['_host']&&this['_host']['isAdditive'];},'enumerable':!0x1,'configurable':!0x0}),_0x39a9e8['prototype']['_preparePath']=function(_0x52478d,_0x5d598d){void 0x0===_0x5d598d&&(_0x5d598d=0x0);var _0x603aeb=this['_animation']['targetPropertyPath'];if(_0x603aeb['length']>0x1){for(var _0x7603bf=_0x52478d[_0x603aeb[0x0]],_0x5dbf7a=0x1;_0x5dbf7a<_0x603aeb['length']-0x1;_0x5dbf7a++)_0x7603bf=_0x7603bf[_0x603aeb[_0x5dbf7a]];this['_targetPath']=_0x603aeb[_0x603aeb['length']-0x1],this['_activeTargets'][_0x5d598d]=_0x7603bf;}else this['_targetPath']=_0x603aeb[0x0],this['_activeTargets'][_0x5d598d]=_0x52478d;},Object['defineProperty'](_0x39a9e8['prototype'],'animation',{'get':function(){return this['_animation'];},'enumerable':!0x1,'configurable':!0x0}),_0x39a9e8['prototype']['reset']=function(_0xf9dfa9){if(void 0x0===_0xf9dfa9&&(_0xf9dfa9=!0x1),_0xf9dfa9){if(this['_target']instanceof Array)for(var _0x34dc36=0x0,_0x3fbb3d=0x0,_0x3389ff=this['_target'];_0x3fbb3d<_0x3389ff['length'];_0x3fbb3d++){var _0x27db48=_0x3389ff[_0x3fbb3d];void 0x0!==this['_originalValue'][_0x34dc36]&&this['_setValue'](_0x27db48,this['_activeTargets'][_0x34dc36],this['_originalValue'][_0x34dc36],-0x1,_0x34dc36),_0x34dc36++;}else void 0x0!==this['_originalValue'][0x0]&&this['_setValue'](this['_target'],this['_directTarget'],this['_originalValue'][0x0],-0x1,0x0);}this['_offsetsCache']={},this['_highLimitsCache']={},this['_currentFrame']=0x0,this['_blendingFactor']=0x0;for(_0x34dc36=0x0;_0x34dc36-0x1&&this['_animation']['runtimeAnimations']['splice'](_0x5e05f7,0x1);},_0x39a9e8['prototype']['setValue']=function(_0x51c913,_0x5b5aed){if(this['_targetIsArray'])for(var _0x4e15fa=0x0;_0x4e15fa_0x54ed8e[_0x54ed8e['length']-0x1]['frame']&&(_0x374d76=_0x54ed8e[_0x54ed8e['length']-0x1]['frame']);var _0x2a7fef=this['_events'];if(_0x2a7fef['length']){for(var _0x236c84=0x0;_0x236c84<_0x2a7fef['length'];_0x236c84++)_0x2a7fef[_0x236c84]['onlyOnce']||(_0x2a7fef[_0x236c84]['isDone']=_0x2a7fef[_0x236c84]['frame']<_0x374d76);}this['_currentFrame']=_0x374d76;var _0x2b81e1=this['_animation']['_interpolate'](_0x374d76,this['_animationState']);this['setValue'](_0x2b81e1,-0x1);},_0x39a9e8['prototype']['_prepareForSpeedRatioChange']=function(_0x17ae6e){var _0x3e11a5=this['_previousDelay']*(this['_animation']['framePerSecond']*_0x17ae6e)/0x3e8;this['_ratioOffset']=this['_previousRatio']-_0x3e11a5;},_0x39a9e8['prototype']['animate']=function(_0x27a168,_0x39902f,_0x3eb56e,_0xcc4b13,_0x46e84d,_0x573d33){void 0x0===_0x573d33&&(_0x573d33=-0x1);var _0x276d5b=this['_animation'],_0x5a725f=_0x276d5b['targetPropertyPath'];if(!_0x5a725f||_0x5a725f['length']<0x1)return this['_stopped']=!0x0,!0x1;var _0x2456d=!0x0;(_0x39902fthis['_maxFrame'])&&(_0x39902f=this['_minFrame']),(_0x3eb56ethis['_maxFrame'])&&(_0x3eb56e=this['_maxFrame']);var _0x12cbc9,_0x5626c1,_0x223794=_0x3eb56e-_0x39902f,_0x1b6d3e=_0x27a168*(_0x276d5b['framePerSecond']*_0x46e84d)/0x3e8+this['_ratioOffset'],_0x4acbcb=0x0;if(this['_previousDelay']=_0x27a168,this['_previousRatio']=_0x1b6d3e,!_0xcc4b13&&_0x3eb56e>=_0x39902f&&_0x1b6d3e>=_0x223794)_0x2456d=!0x1,_0x4acbcb=_0x276d5b['_getKeyValue'](this['_maxValue']);else{if(!_0xcc4b13&&_0x39902f>=_0x3eb56e&&_0x1b6d3e<=_0x223794)_0x2456d=!0x1,_0x4acbcb=_0x276d5b['_getKeyValue'](this['_minValue']);else{if(this['_animationState']['loopMode']!==_0x1b0498['ANIMATIONLOOPMODE_CYCLE']){var _0x718618=_0x3eb56e['toString']()+_0x39902f['toString']();if(!this['_offsetsCache'][_0x718618]){this['_animationState']['repeatCount']=0x0,this['_animationState']['loopMode']=_0x1b0498['ANIMATIONLOOPMODE_CYCLE'];var _0x40190e=_0x276d5b['_interpolate'](_0x39902f,this['_animationState']),_0x546164=_0x276d5b['_interpolate'](_0x3eb56e,this['_animationState']);switch(this['_animationState']['loopMode']=this['_getCorrectLoopMode'](),_0x276d5b['dataType']){case _0x1b0498['ANIMATIONTYPE_FLOAT']:this['_offsetsCache'][_0x718618]=_0x546164-_0x40190e;break;case _0x1b0498['ANIMATIONTYPE_QUATERNION']:this['_offsetsCache'][_0x718618]=_0x546164['subtract'](_0x40190e);break;case _0x1b0498['ANIMATIONTYPE_VECTOR3']:this['_offsetsCache'][_0x718618]=_0x546164['subtract'](_0x40190e);case _0x1b0498['ANIMATIONTYPE_VECTOR2']:this['_offsetsCache'][_0x718618]=_0x546164['subtract'](_0x40190e);case _0x1b0498['ANIMATIONTYPE_SIZE']:this['_offsetsCache'][_0x718618]=_0x546164['subtract'](_0x40190e);case _0x1b0498['ANIMATIONTYPE_COLOR3']:this['_offsetsCache'][_0x718618]=_0x546164['subtract'](_0x40190e);}this['_highLimitsCache'][_0x718618]=_0x546164;}_0x4acbcb=this['_highLimitsCache'][_0x718618],_0x12cbc9=this['_offsetsCache'][_0x718618];}}}if(void 0x0===_0x12cbc9)switch(_0x276d5b['dataType']){case _0x1b0498['ANIMATIONTYPE_FLOAT']:_0x12cbc9=0x0;break;case _0x1b0498['ANIMATIONTYPE_QUATERNION']:_0x12cbc9=_0x3de49a;break;case _0x1b0498['ANIMATIONTYPE_VECTOR3']:_0x12cbc9=_0x12bb4e;break;case _0x1b0498['ANIMATIONTYPE_VECTOR2']:_0x12cbc9=_0x135b84;break;case _0x1b0498['ANIMATIONTYPE_SIZE']:_0x12cbc9=_0x454b5d;break;case _0x1b0498['ANIMATIONTYPE_COLOR3']:_0x12cbc9=_0x2963cf;}if(this['_host']&&this['_host']['syncRoot']){var _0x5c8be9=this['_host']['syncRoot'];_0x5626c1=_0x39902f+(_0x3eb56e-_0x39902f)*((_0x5c8be9['masterFrame']-_0x5c8be9['fromFrame'])/(_0x5c8be9['toFrame']-_0x5c8be9['fromFrame']));}else _0x5626c1=_0x2456d&&0x0!==_0x223794?_0x39902f+_0x1b6d3e%_0x223794:_0x3eb56e;var _0x5b4292=this['_events'];if((_0x223794>0x0&&this['currentFrame']>_0x5626c1||_0x223794<0x0&&this['currentFrame']<_0x5626c1)&&(this['_onLoop'](),_0x5b4292['length'])){for(var _0xabac6b=0x0;_0xabac6b<_0x5b4292['length'];_0xabac6b++)_0x5b4292[_0xabac6b]['onlyOnce']||(_0x5b4292[_0xabac6b]['isDone']=!0x1);}this['_currentFrame']=_0x5626c1,this['_animationState']['repeatCount']=0x0===_0x223794?0x0:_0x1b6d3e/_0x223794>>0x0,this['_animationState']['highLimitValue']=_0x4acbcb,this['_animationState']['offsetValue']=_0x12cbc9;var _0x38777f=_0x276d5b['_interpolate'](_0x5626c1,this['_animationState']);if(this['setValue'](_0x38777f,_0x573d33),_0x5b4292['length']){for(_0xabac6b=0x0;_0xabac6b<_0x5b4292['length'];_0xabac6b++)if(_0x223794>0x0&&_0x5626c1>=_0x5b4292[_0xabac6b]['frame']&&_0x5b4292[_0xabac6b]['frame']>=_0x39902f||_0x223794<0x0&&_0x5626c1<=_0x5b4292[_0xabac6b]['frame']&&_0x5b4292[_0xabac6b]['frame']<=_0x39902f){var _0x204e77=_0x5b4292[_0xabac6b];_0x204e77['isDone']||(_0x204e77['onlyOnce']&&(_0x5b4292['splice'](_0xabac6b,0x1),_0xabac6b--),_0x204e77['isDone']=!0x0,_0x204e77['action'](_0x5626c1));}}return _0x2456d||(this['_stopped']=!0x0),_0x2456d;},_0x39a9e8;}()),_0x59370b=_0x162675(0x14),_0x49f003=_0x162675(0x39),_0x429cc2=_0x162675(0x2c),_0x4a79a2=_0x162675(0x17),_0x4df88a=function(_0x391c12){function _0x473e4c(_0x4315e5,_0x473804,_0x133ad1,_0x17ac49,_0x4b721b,_0x190c5a,_0x4d8c3d){void 0x0===_0x133ad1&&(_0x133ad1=null),void 0x0===_0x17ac49&&(_0x17ac49=null),void 0x0===_0x4b721b&&(_0x4b721b=null),void 0x0===_0x190c5a&&(_0x190c5a=null),void 0x0===_0x4d8c3d&&(_0x4d8c3d=null);var _0x3d6510=_0x391c12['call'](this,_0x4315e5,_0x473804['getScene']())||this;return _0x3d6510['name']=_0x4315e5,_0x3d6510['children']=new Array(),_0x3d6510['animations']=new Array(),_0x3d6510['_index']=null,_0x3d6510['_absoluteTransform']=new _0x74d525['a'](),_0x3d6510['_invertedAbsoluteTransform']=new _0x74d525['a'](),_0x3d6510['_scalingDeterminant']=0x1,_0x3d6510['_worldTransform']=new _0x74d525['a'](),_0x3d6510['_needToDecompose']=!0x0,_0x3d6510['_needToCompose']=!0x1,_0x3d6510['_linkedTransformNode']=null,_0x3d6510['_waitingTransformNodeId']=null,_0x3d6510['_skeleton']=_0x473804,_0x3d6510['_localMatrix']=_0x17ac49?_0x17ac49['clone']():_0x74d525['a']['Identity'](),_0x3d6510['_restPose']=_0x4b721b||_0x3d6510['_localMatrix']['clone'](),_0x3d6510['_bindPose']=_0x3d6510['_localMatrix']['clone'](),_0x3d6510['_baseMatrix']=_0x190c5a||_0x3d6510['_localMatrix']['clone'](),_0x3d6510['_index']=_0x4d8c3d,_0x473804['bones']['push'](_0x3d6510),_0x3d6510['setParent'](_0x133ad1,!0x1),(_0x190c5a||_0x17ac49)&&_0x3d6510['_updateDifferenceMatrix'](),_0x3d6510;}return Object(_0x18e13d['d'])(_0x473e4c,_0x391c12),Object['defineProperty'](_0x473e4c['prototype'],'_matrix',{'get':function(){return this['_compose'](),this['_localMatrix'];},'set':function(_0x29344b){this['_localMatrix']['copyFrom'](_0x29344b),this['_needToDecompose']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),_0x473e4c['prototype']['getClassName']=function(){return'Bone';},_0x473e4c['prototype']['getSkeleton']=function(){return this['_skeleton'];},_0x473e4c['prototype']['getParent']=function(){return this['_parent'];},_0x473e4c['prototype']['getChildren']=function(){return this['children'];},_0x473e4c['prototype']['getIndex']=function(){return null===this['_index']?this['getSkeleton']()['bones']['indexOf'](this):this['_index'];},_0x473e4c['prototype']['setParent']=function(_0x22159e,_0x5482b1){if(void 0x0===_0x5482b1&&(_0x5482b1=!0x0),this['_parent']!==_0x22159e){if(this['_parent']){var _0x3d5958=this['_parent']['children']['indexOf'](this);-0x1!==_0x3d5958&&this['_parent']['children']['splice'](_0x3d5958,0x1);}this['_parent']=_0x22159e,this['_parent']&&this['_parent']['children']['push'](this),_0x5482b1&&this['_updateDifferenceMatrix'](),this['markAsDirty']();}},_0x473e4c['prototype']['getLocalMatrix']=function(){return this['_compose'](),this['_localMatrix'];},_0x473e4c['prototype']['getBaseMatrix']=function(){return this['_baseMatrix'];},_0x473e4c['prototype']['getRestPose']=function(){return this['_restPose'];},_0x473e4c['prototype']['setRestPose']=function(_0x106829){this['_restPose']['copyFrom'](_0x106829);},_0x473e4c['prototype']['getBindPose']=function(){return this['_bindPose'];},_0x473e4c['prototype']['setBindPose']=function(_0x435941){this['_bindPose']['copyFrom'](_0x435941);},_0x473e4c['prototype']['getWorldMatrix']=function(){return this['_worldTransform'];},_0x473e4c['prototype']['returnToRest']=function(){this['_skeleton']['_numBonesWithLinkedTransformNode']>0x0?this['updateMatrix'](this['_restPose'],!0x1,!0x1):this['updateMatrix'](this['_restPose'],!0x1,!0x0);},_0x473e4c['prototype']['getInvertedAbsoluteTransform']=function(){return this['_invertedAbsoluteTransform'];},_0x473e4c['prototype']['getAbsoluteTransform']=function(){return this['_absoluteTransform'];},_0x473e4c['prototype']['linkTransformNode']=function(_0x2f81fe){this['_linkedTransformNode']&&this['_skeleton']['_numBonesWithLinkedTransformNode']--,this['_linkedTransformNode']=_0x2f81fe,this['_linkedTransformNode']&&this['_skeleton']['_numBonesWithLinkedTransformNode']++;},_0x473e4c['prototype']['getTransformNode']=function(){return this['_linkedTransformNode'];},Object['defineProperty'](_0x473e4c['prototype'],'position',{'get':function(){return this['_decompose'](),this['_localPosition'];},'set':function(_0x3eae8a){this['_decompose'](),this['_localPosition']['copyFrom'](_0x3eae8a),this['_markAsDirtyAndCompose']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x473e4c['prototype'],'rotation',{'get':function(){return this['getRotation']();},'set':function(_0x34e593){this['setRotation'](_0x34e593);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x473e4c['prototype'],'rotationQuaternion',{'get':function(){return this['_decompose'](),this['_localRotation'];},'set':function(_0x2c9d75){this['setRotationQuaternion'](_0x2c9d75);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x473e4c['prototype'],'scaling',{'get':function(){return this['getScale']();},'set':function(_0x108c7b){this['setScale'](_0x108c7b);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x473e4c['prototype'],'animationPropertiesOverride',{'get':function(){return this['_skeleton']['animationPropertiesOverride'];},'enumerable':!0x1,'configurable':!0x0}),_0x473e4c['prototype']['_decompose']=function(){this['_needToDecompose']&&(this['_needToDecompose']=!0x1,this['_localScaling']||(this['_localScaling']=_0x74d525['e']['Zero'](),this['_localRotation']=_0x74d525['b']['Zero'](),this['_localPosition']=_0x74d525['e']['Zero']()),this['_localMatrix']['decompose'](this['_localScaling'],this['_localRotation'],this['_localPosition']));},_0x473e4c['prototype']['_compose']=function(){this['_needToCompose']&&(this['_localScaling']?(this['_needToCompose']=!0x1,_0x74d525['a']['ComposeToRef'](this['_localScaling'],this['_localRotation'],this['_localPosition'],this['_localMatrix'])):this['_needToCompose']=!0x1);},_0x473e4c['prototype']['updateMatrix']=function(_0x4fd267,_0x57dc77,_0x5e391a){void 0x0===_0x57dc77&&(_0x57dc77=!0x0),void 0x0===_0x5e391a&&(_0x5e391a=!0x0),this['_baseMatrix']['copyFrom'](_0x4fd267),_0x57dc77&&this['_updateDifferenceMatrix'](),_0x5e391a?(this['_needToCompose']=!0x1,this['_localMatrix']['copyFrom'](_0x4fd267),this['_markAsDirtyAndDecompose']()):this['markAsDirty']();},_0x473e4c['prototype']['_updateDifferenceMatrix']=function(_0x4136a6,_0x3ec402){if(void 0x0===_0x3ec402&&(_0x3ec402=!0x0),_0x4136a6||(_0x4136a6=this['_baseMatrix']),this['_parent']?_0x4136a6['multiplyToRef'](this['_parent']['_absoluteTransform'],this['_absoluteTransform']):this['_absoluteTransform']['copyFrom'](_0x4136a6),this['_absoluteTransform']['invertToRef'](this['_invertedAbsoluteTransform']),_0x3ec402){for(var _0x48f8de=0x0;_0x48f8de-0x1&&(this['_scene']['_activeAnimatables']['splice'](_0x31202a,0x1),this['_scene']['_activeAnimatables']['push'](this));}return this;},_0x68d68d['prototype']['getAnimations']=function(){return this['_runtimeAnimations'];},_0x68d68d['prototype']['appendAnimations']=function(_0xf73eea,_0x4e1d3b){for(var _0x489770=this,_0x3f84a2=0x0;_0x3f84a2<_0x4e1d3b['length'];_0x3f84a2++){var _0xd940fa=_0x4e1d3b[_0x3f84a2],_0x2a3344=new _0xfb2c56(_0xf73eea,_0xd940fa,this['_scene'],this);_0x2a3344['_onLoop']=function(){_0x489770['onAnimationLoopObservable']['notifyObservers'](_0x489770),_0x489770['onAnimationLoop']&&_0x489770['onAnimationLoop']();},this['_runtimeAnimations']['push'](_0x2a3344);}},_0x68d68d['prototype']['getAnimationByTargetProperty']=function(_0x50dac9){for(var _0x2c256c=this['_runtimeAnimations'],_0x779917=0x0;_0x779917<_0x2c256c['length'];_0x779917++)if(_0x2c256c[_0x779917]['animation']['targetProperty']===_0x50dac9)return _0x2c256c[_0x779917]['animation'];return null;},_0x68d68d['prototype']['getRuntimeAnimationByTargetProperty']=function(_0x45b977){for(var _0x395e28=this['_runtimeAnimations'],_0x537290=0x0;_0x537290<_0x395e28['length'];_0x537290++)if(_0x395e28[_0x537290]['animation']['targetProperty']===_0x45b977)return _0x395e28[_0x537290];return null;},_0x68d68d['prototype']['reset']=function(){for(var _0x95c456=this['_runtimeAnimations'],_0x53a567=0x0;_0x53a567<_0x95c456['length'];_0x53a567++)_0x95c456[_0x53a567]['reset'](!0x0);this['_localDelayOffset']=null,this['_pausedDelay']=null;},_0x68d68d['prototype']['enableBlending']=function(_0x21e314){for(var _0x235a39=this['_runtimeAnimations'],_0x34f3a0=0x0;_0x34f3a0<_0x235a39['length'];_0x34f3a0++)_0x235a39[_0x34f3a0]['animation']['enableBlending']=!0x0,_0x235a39[_0x34f3a0]['animation']['blendingSpeed']=_0x21e314;},_0x68d68d['prototype']['disableBlending']=function(){for(var _0x498784=this['_runtimeAnimations'],_0x16d30c=0x0;_0x16d30c<_0x498784['length'];_0x16d30c++)_0x498784[_0x16d30c]['animation']['enableBlending']=!0x1;},_0x68d68d['prototype']['goToFrame']=function(_0x4f52b0){var _0x3f47d3=this['_runtimeAnimations'];if(_0x3f47d3[0x0]){var _0x527008=_0x3f47d3[0x0]['animation']['framePerSecond'],_0x97a048=_0x3f47d3[0x0]['currentFrame'],_0x64d1aa=0x0===this['speedRatio']?0x0:(_0x4f52b0-_0x97a048)/_0x527008*0x3e8/this['speedRatio'];null===this['_localDelayOffset']&&(this['_localDelayOffset']=0x0),this['_localDelayOffset']-=_0x64d1aa;}for(var _0x7e92d4=0x0;_0x7e92d4<_0x3f47d3['length'];_0x7e92d4++)_0x3f47d3[_0x7e92d4]['goToFrame'](_0x4f52b0);},_0x68d68d['prototype']['pause']=function(){this['_paused']||(this['_paused']=!0x0);},_0x68d68d['prototype']['restart']=function(){this['_paused']=!0x1;},_0x68d68d['prototype']['_raiseOnAnimationEnd']=function(){this['onAnimationEnd']&&this['onAnimationEnd'](),this['onAnimationEndObservable']['notifyObservers'](this);},_0x68d68d['prototype']['stop']=function(_0x54d735,_0x694296){if(_0x54d735||_0x694296){var _0x34ef6f=this['_scene']['_activeAnimatables']['indexOf'](this);if(_0x34ef6f>-0x1){for(var _0x453e9b=(_0x2a5e30=this['_runtimeAnimations'])['length']-0x1;_0x453e9b>=0x0;_0x453e9b--){var _0x59f5c9=_0x2a5e30[_0x453e9b];_0x54d735&&_0x59f5c9['animation']['name']!=_0x54d735||(_0x694296&&!_0x694296(_0x59f5c9['target'])||(_0x59f5c9['dispose'](),_0x2a5e30['splice'](_0x453e9b,0x1)));}0x0==_0x2a5e30['length']&&(this['_scene']['_activeAnimatables']['splice'](_0x34ef6f,0x1),this['_raiseOnAnimationEnd']());}}else{if((_0x453e9b=this['_scene']['_activeAnimatables']['indexOf'](this))>-0x1){this['_scene']['_activeAnimatables']['splice'](_0x453e9b,0x1);var _0x2a5e30=this['_runtimeAnimations'];for(_0x453e9b=0x0;_0x453e9b<_0x2a5e30['length'];_0x453e9b++)_0x2a5e30[_0x453e9b]['dispose']();this['_raiseOnAnimationEnd']();}}},_0x68d68d['prototype']['waitAsync']=function(){var _0x34f4ac=this;return new Promise(function(_0x324d65,_0x558b3a){_0x34f4ac['onAnimationEndObservable']['add'](function(){_0x324d65(_0x34f4ac);},void 0x0,void 0x0,_0x34f4ac,!0x0);});},_0x68d68d['prototype']['_animate']=function(_0x722f3e){if(this['_paused'])return this['animationStarted']=!0x1,null===this['_pausedDelay']&&(this['_pausedDelay']=_0x722f3e),!0x0;if(null===this['_localDelayOffset']?(this['_localDelayOffset']=_0x722f3e,this['_pausedDelay']=null):null!==this['_pausedDelay']&&(this['_localDelayOffset']+=_0x722f3e-this['_pausedDelay'],this['_pausedDelay']=null),0x0===this['_weight'])return!0x0;var _0x79aaa3,_0x6e7773=!0x1,_0x39a824=this['_runtimeAnimations'];for(_0x79aaa3=0x0;_0x79aaa3<_0x39a824['length'];_0x79aaa3++){var _0x1987b1=_0x39a824[_0x79aaa3]['animate'](_0x722f3e-this['_localDelayOffset'],this['fromFrame'],this['toFrame'],this['loopAnimation'],this['_speedRatio'],this['_weight']);_0x6e7773=_0x6e7773||_0x1987b1;}if(this['animationStarted']=_0x6e7773,!_0x6e7773){if(this['disposeOnEnd']){for(_0x79aaa3=this['_scene']['_activeAnimatables']['indexOf'](this),this['_scene']['_activeAnimatables']['splice'](_0x79aaa3,0x1),_0x79aaa3=0x0;_0x79aaa3<_0x39a824['length'];_0x79aaa3++)_0x39a824[_0x79aaa3]['dispose']();}this['_raiseOnAnimationEnd'](),this['disposeOnEnd']&&(this['onAnimationEnd']=null,this['onAnimationLoop']=null,this['onAnimationLoopObservable']['clear'](),this['onAnimationEndObservable']['clear']());}return _0x6e7773;},_0x68d68d;}());_0x59370b['a']['prototype']['_animate']=function(){if(this['animationsEnabled']){var _0x2c85c1=_0x49f003['a']['Now'];if(!this['_animationTimeLast']){if(this['_pendingData']['length']>0x0)return;this['_animationTimeLast']=_0x2c85c1;}this['deltaTime']=this['useConstantAnimationDeltaTime']?0x10:(_0x2c85c1-this['_animationTimeLast'])*this['animationTimeScale'],this['_animationTimeLast']=_0x2c85c1;var _0xe74259=this['_activeAnimatables'];if(0x0!==_0xe74259['length']){this['_animationTime']+=this['deltaTime'];for(var _0x46d22a=this['_animationTime'],_0x20392a=0x0;_0x20392a<_0xe74259['length'];_0x20392a++){var _0x4f82d5=_0xe74259[_0x20392a];!_0x4f82d5['_animate'](_0x46d22a)&&_0x4f82d5['disposeOnEnd']&&_0x20392a--;}this['_processLateAnimationBindings']();}}},_0x59370b['a']['prototype']['beginWeightedAnimation']=function(_0x1dcfc0,_0x41043a,_0x366368,_0x1e5fa4,_0xf161aa,_0x40d3ad,_0x17bccb,_0xd14e05,_0x481889,_0xcd77af,_0x413489){void 0x0===_0x1e5fa4&&(_0x1e5fa4=0x1),void 0x0===_0x40d3ad&&(_0x40d3ad=0x1),void 0x0===_0x413489&&(_0x413489=!0x1);var _0x310613=this['beginAnimation'](_0x1dcfc0,_0x41043a,_0x366368,_0xf161aa,_0x40d3ad,_0x17bccb,_0xd14e05,!0x1,_0x481889,_0xcd77af,_0x413489);return _0x310613['weight']=_0x1e5fa4,_0x310613;},_0x59370b['a']['prototype']['beginAnimation']=function(_0x43373b,_0x684609,_0x3e95fa,_0x5f0861,_0x324d05,_0x40017d,_0x1a4b29,_0x4628ce,_0x43793b,_0x1ba300,_0x4d2bd9){void 0x0===_0x324d05&&(_0x324d05=0x1),void 0x0===_0x4628ce&&(_0x4628ce=!0x0),void 0x0===_0x4d2bd9&&(_0x4d2bd9=!0x1),_0x684609>_0x3e95fa&&_0x324d05>0x0&&(_0x324d05*=-0x1),_0x4628ce&&this['stopAnimation'](_0x43373b,void 0x0,_0x43793b),_0x1a4b29||(_0x1a4b29=new _0x13e125(this,_0x43373b,_0x684609,_0x3e95fa,_0x5f0861,_0x324d05,_0x40017d,void 0x0,_0x1ba300,_0x4d2bd9));var _0x129ab4=!_0x43793b||_0x43793b(_0x43373b);if(_0x43373b['animations']&&_0x129ab4&&_0x1a4b29['appendAnimations'](_0x43373b,_0x43373b['animations']),_0x43373b['getAnimatables']){for(var _0x2d6774=_0x43373b['getAnimatables'](),_0x2198f8=0x0;_0x2198f8<_0x2d6774['length'];_0x2198f8++)this['beginAnimation'](_0x2d6774[_0x2198f8],_0x684609,_0x3e95fa,_0x5f0861,_0x324d05,_0x40017d,_0x1a4b29,_0x4628ce,_0x43793b,_0x1ba300);}return _0x1a4b29['reset'](),_0x1a4b29;},_0x59370b['a']['prototype']['beginHierarchyAnimation']=function(_0x35f563,_0x29a242,_0x15c5bf,_0x27cce6,_0x387f5e,_0x156f90,_0xd46960,_0x1b7704,_0x4a054c,_0x2d1f19,_0x3cd71a,_0x156223){void 0x0===_0x156f90&&(_0x156f90=0x1),void 0x0===_0x4a054c&&(_0x4a054c=!0x0),void 0x0===_0x156223&&(_0x156223=!0x1);var _0x143245=_0x35f563['getDescendants'](_0x29a242),_0x151943=[];_0x151943['push'](this['beginAnimation'](_0x35f563,_0x15c5bf,_0x27cce6,_0x387f5e,_0x156f90,_0xd46960,_0x1b7704,_0x4a054c,_0x2d1f19,void 0x0,_0x156223));for(var _0x51b816=0x0,_0x427170=_0x143245;_0x51b816<_0x427170['length'];_0x51b816++){var _0x5d6457=_0x427170[_0x51b816];_0x151943['push'](this['beginAnimation'](_0x5d6457,_0x15c5bf,_0x27cce6,_0x387f5e,_0x156f90,_0xd46960,_0x1b7704,_0x4a054c,_0x2d1f19,void 0x0,_0x156223));}return _0x151943;},_0x59370b['a']['prototype']['beginDirectAnimation']=function(_0x5823e8,_0x437f7d,_0x485520,_0x1af2db,_0x3e7cd9,_0x40986a,_0x49d158,_0xfd1ac6,_0x24b3bb){return void 0x0===_0x24b3bb&&(_0x24b3bb=!0x1),void 0x0===_0x40986a&&(_0x40986a=0x1),_0x485520>_0x1af2db&&_0x40986a>0x0&&(_0x40986a*=-0x1),new _0x13e125(this,_0x5823e8,_0x485520,_0x1af2db,_0x3e7cd9,_0x40986a,_0x49d158,_0x437f7d,_0xfd1ac6,_0x24b3bb);},_0x59370b['a']['prototype']['beginDirectHierarchyAnimation']=function(_0x3ff001,_0x2e4980,_0x4110d0,_0x4a41e6,_0x43ea76,_0x104333,_0x333f38,_0x16881f,_0x4db7bc,_0x4d585c){void 0x0===_0x4d585c&&(_0x4d585c=!0x1);var _0x1c9fe3=_0x3ff001['getDescendants'](_0x2e4980),_0x35fc17=[];_0x35fc17['push'](this['beginDirectAnimation'](_0x3ff001,_0x4110d0,_0x4a41e6,_0x43ea76,_0x104333,_0x333f38,_0x16881f,_0x4db7bc,_0x4d585c));for(var _0x155b7e=0x0,_0xec3604=_0x1c9fe3;_0x155b7e<_0xec3604['length'];_0x155b7e++){var _0x306b1f=_0xec3604[_0x155b7e];_0x35fc17['push'](this['beginDirectAnimation'](_0x306b1f,_0x4110d0,_0x4a41e6,_0x43ea76,_0x104333,_0x333f38,_0x16881f,_0x4db7bc,_0x4d585c));}return _0x35fc17;},_0x59370b['a']['prototype']['getAnimatableByTarget']=function(_0x4e7ced){for(var _0x64fd3b=0x0;_0x64fd3b0x0)_0x3384c3['copyFrom'](_0x243d0f);else{if(0x1===_0x274a55['animations']['length']){if(_0x74d525['b']['SlerpToRef'](_0x243d0f,_0x4ca3be['currentValue'],Math['min'](0x1,_0x274a55['totalWeight']),_0x3384c3),0x0===_0x274a55['totalAdditiveWeight'])return _0x3384c3;}else{if(_0x274a55['animations']['length']>0x1){var _0x5b0629=0x1,_0x455f77=void 0x0,_0x5c1737=void 0x0;if(_0x274a55['totalWeight']<0x1){var _0x5731ae=0x1-_0x274a55['totalWeight'];_0x5c1737=[],(_0x455f77=[])['push'](_0x243d0f),_0x5c1737['push'](_0x5731ae);}else{if(0x2===_0x274a55['animations']['length']&&(_0x74d525['b']['SlerpToRef'](_0x274a55['animations'][0x0]['currentValue'],_0x274a55['animations'][0x1]['currentValue'],_0x274a55['animations'][0x1]['weight']/_0x274a55['totalWeight'],_0x10d0fb),0x0===_0x274a55['totalAdditiveWeight']))return _0x10d0fb;_0x455f77=[],_0x5c1737=[],_0x5b0629=_0x274a55['totalWeight'];}for(var _0x2e5d8d=0x0;_0x2e5d8d<_0x274a55['animations']['length'];_0x2e5d8d++){var _0x4b2807=_0x274a55['animations'][_0x2e5d8d];_0x455f77['push'](_0x4b2807['currentValue']),_0x5c1737['push'](_0x4b2807['weight']/_0x5b0629);}for(var _0x24b3aa=0x0,_0x1a599b=0x0;_0x1a599b<_0x455f77['length'];)_0x1a599b?(_0x24b3aa+=_0x5c1737[_0x1a599b],_0x74d525['b']['SlerpToRef'](_0x3384c3,_0x455f77[_0x1a599b],_0x5c1737[_0x1a599b]/_0x24b3aa,_0x3384c3),_0x1a599b++):(_0x74d525['b']['SlerpToRef'](_0x455f77[_0x1a599b],_0x455f77[_0x1a599b+0x1],_0x5c1737[_0x1a599b+0x1]/(_0x5c1737[_0x1a599b]+_0x5c1737[_0x1a599b+0x1]),_0x10d0fb),_0x3384c3=_0x10d0fb,_0x24b3aa=_0x5c1737[_0x1a599b]+_0x5c1737[_0x1a599b+0x1],_0x1a599b+=0x2);}}}for(var _0x2463ce=0x0;_0x2463ce<_0x274a55['additiveAnimations']['length'];_0x2463ce++){0x0!==(_0x4b2807=_0x274a55['additiveAnimations'][_0x2463ce])['weight']&&(_0x3384c3['multiplyToRef'](_0x4b2807['currentValue'],_0x74d525['c']['Quaternion'][0x0]),_0x74d525['b']['SlerpToRef'](_0x3384c3,_0x74d525['c']['Quaternion'][0x0],_0x4b2807['weight'],_0x3384c3));}return _0x3384c3;},_0x59370b['a']['prototype']['_processLateAnimationBindings']=function(){if(this['_registeredForLateAnimationBindings']['length']){for(var _0x3ed0fb=0x0;_0x3ed0fb=_0x3419c3&&_0x572867['frame']<=_0x516c07&&(_0x476135?(_0x5a4115=_0x572867['value']['clone'](),_0x674b84?(_0x5d82b5=_0x5a4115['getTranslation'](),_0x5a4115['setTranslation'](_0x5d82b5['scaleInPlace'](_0x5aa16f))):_0x45fa90&&_0x3a8f15?(_0x5d82b5=_0x5a4115['getTranslation'](),_0x5a4115['setTranslation'](_0x5d82b5['multiplyInPlace'](_0x3a8f15))):_0x5a4115=_0x572867['value']):_0x5a4115=_0x572867['value'],_0x1107e9['push']({'frame':_0x572867['frame']+_0x4eabd3,'value':_0x5a4115}));return this['animations'][0x0]['createRange'](_0x4fb206,_0x3419c3+_0x4eabd3,_0x516c07+_0x4eabd3),!0x0;};var _0x37db12=(function(){function _0x30623d(){}return _0x30623d['prototype']['getClassName']=function(){return'TargetedAnimation';},_0x30623d['prototype']['serialize']=function(){var _0x2fec7c={};return _0x2fec7c['animation']=this['animation']['serialize'](),_0x2fec7c['targetId']=this['target']['id'],_0x2fec7c;},_0x30623d;}()),_0x433562=(function(){function _0x304d59(_0x42a851,_0x206031){void 0x0===_0x206031&&(_0x206031=null),this['name']=_0x42a851,this['_targetedAnimations']=new Array(),this['_animatables']=new Array(),this['_from']=Number['MAX_VALUE'],this['_to']=-Number['MAX_VALUE'],this['_speedRatio']=0x1,this['_loopAnimation']=!0x1,this['_isAdditive']=!0x1,this['onAnimationEndObservable']=new _0x6ac1f7['c'](),this['onAnimationLoopObservable']=new _0x6ac1f7['c'](),this['onAnimationGroupLoopObservable']=new _0x6ac1f7['c'](),this['onAnimationGroupEndObservable']=new _0x6ac1f7['c'](),this['onAnimationGroupPauseObservable']=new _0x6ac1f7['c'](),this['onAnimationGroupPlayObservable']=new _0x6ac1f7['c'](),this['_scene']=_0x206031||_0x44b9ce['a']['LastCreatedScene'],this['uniqueId']=this['_scene']['getUniqueId'](),this['_scene']['addAnimationGroup'](this);}return Object['defineProperty'](_0x304d59['prototype'],'from',{'get':function(){return this['_from'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x304d59['prototype'],'to',{'get':function(){return this['_to'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x304d59['prototype'],'isStarted',{'get':function(){return this['_isStarted'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x304d59['prototype'],'isPlaying',{'get':function(){return this['_isStarted']&&!this['_isPaused'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x304d59['prototype'],'speedRatio',{'get':function(){return this['_speedRatio'];},'set':function(_0x4cdf76){if(this['_speedRatio']!==_0x4cdf76){this['_speedRatio']=_0x4cdf76;for(var _0x213a9d=0x0;_0x213a9d_0x3173fd[0x0]['frame']&&(this['_from']=_0x3173fd[0x0]['frame']),this['_to']<_0x3173fd[_0x3173fd['length']-0x1]['frame']&&(this['_to']=_0x3173fd[_0x3173fd['length']-0x1]['frame']),this['_targetedAnimations']['push'](_0x15887d),_0x15887d;},_0x304d59['prototype']['normalize']=function(_0x40e856,_0x4c6ea4){void 0x0===_0x40e856&&(_0x40e856=null),void 0x0===_0x4c6ea4&&(_0x4c6ea4=null),null==_0x40e856&&(_0x40e856=this['_from']),null==_0x4c6ea4&&(_0x4c6ea4=this['_to']);for(var _0x1cc0ef=0x0;_0x1cc0ef_0x40e856){var _0x86d74f={'frame':_0x40e856,'value':_0x554c6b['value'],'inTangent':_0x554c6b['inTangent'],'outTangent':_0x554c6b['outTangent'],'interpolation':_0x554c6b['interpolation']};_0x21a257['splice'](0x0,0x0,_0x86d74f);}_0x3a7ff1['frame']<_0x4c6ea4&&(_0x86d74f={'frame':_0x4c6ea4,'value':_0x3a7ff1['value'],'inTangent':_0x3a7ff1['inTangent'],'outTangent':_0x3a7ff1['outTangent'],'interpolation':_0x3a7ff1['interpolation']},_0x21a257['push'](_0x86d74f));}return this['_from']=_0x40e856,this['_to']=_0x4c6ea4,this;},_0x304d59['prototype']['_processLoop']=function(_0x2f1603,_0x3a6497,_0x3a23d8){var _0x13ff7a=this;_0x2f1603['onAnimationLoop']=function(){_0x13ff7a['onAnimationLoopObservable']['notifyObservers'](_0x3a6497),_0x13ff7a['_animationLoopFlags'][_0x3a23d8]||(_0x13ff7a['_animationLoopFlags'][_0x3a23d8]=!0x0,_0x13ff7a['_animationLoopCount']++,_0x13ff7a['_animationLoopCount']===_0x13ff7a['_targetedAnimations']['length']&&(_0x13ff7a['onAnimationGroupLoopObservable']['notifyObservers'](_0x13ff7a),_0x13ff7a['_animationLoopCount']=0x0,_0x13ff7a['_animationLoopFlags']=[]));};},_0x304d59['prototype']['start']=function(_0x577402,_0x1eed13,_0x306adb,_0x5c0531,_0x4e4cc8){var _0x5e232c=this;if(void 0x0===_0x577402&&(_0x577402=!0x1),void 0x0===_0x1eed13&&(_0x1eed13=0x1),this['_isStarted']||0x0===this['_targetedAnimations']['length'])return this;this['_loopAnimation']=_0x577402,this['_animationLoopCount']=0x0,this['_animationLoopFlags']=[];for(var _0x5b626e=function(){var _0x3d1505=_0x39b51d['_targetedAnimations'][_0x46874d],_0x187a6c=_0x39b51d['_scene']['beginDirectAnimation'](_0x3d1505['target'],[_0x3d1505['animation']],void 0x0!==_0x306adb?_0x306adb:_0x39b51d['_from'],void 0x0!==_0x5c0531?_0x5c0531:_0x39b51d['_to'],_0x577402,_0x1eed13,void 0x0,void 0x0,void 0x0!==_0x4e4cc8?_0x4e4cc8:_0x39b51d['_isAdditive']);_0x187a6c['onAnimationEnd']=function(){_0x5e232c['onAnimationEndObservable']['notifyObservers'](_0x3d1505),_0x5e232c['_checkAnimationGroupEnded'](_0x187a6c);},_0x39b51d['_processLoop'](_0x187a6c,_0x3d1505,_0x46874d),_0x39b51d['_animatables']['push'](_0x187a6c);},_0x39b51d=this,_0x46874d=0x0;_0x46874d_0x5c0531&&this['_speedRatio']>0x0&&(this['_speedRatio']=-_0x1eed13);}return this['_isStarted']=!0x0,this['_isPaused']=!0x1,this['onAnimationGroupPlayObservable']['notifyObservers'](this),this;},_0x304d59['prototype']['pause']=function(){if(!this['_isStarted'])return this;this['_isPaused']=!0x0;for(var _0x154055=0x0;_0x154055-0x1&&this['_scene']['animationGroups']['splice'](_0x1e0bf3,0x1),this['onAnimationEndObservable']['clear'](),this['onAnimationGroupEndObservable']['clear'](),this['onAnimationGroupPauseObservable']['clear'](),this['onAnimationGroupPlayObservable']['clear'](),this['onAnimationLoopObservable']['clear'](),this['onAnimationGroupLoopObservable']['clear']();},_0x304d59['prototype']['_checkAnimationGroupEnded']=function(_0x216b93){var _0x175640=this['_animatables']['indexOf'](_0x216b93);_0x175640>-0x1&&this['_animatables']['splice'](_0x175640,0x1),0x0===this['_animatables']['length']&&(this['_isStarted']=!0x1,this['onAnimationGroupEndObservable']['notifyObservers'](this));},_0x304d59['prototype']['clone']=function(_0x1ab338,_0x1c8259){for(var _0x194305=new _0x304d59(_0x1ab338||this['name'],this['_scene']),_0xcbedb0=0x0,_0x16138c=this['_targetedAnimations'];_0xcbedb0<_0x16138c['length'];_0xcbedb0++){var _0x52cb5e=_0x16138c[_0xcbedb0];_0x194305['addTargetedAnimation'](_0x52cb5e['animation']['clone'](),_0x1c8259?_0x1c8259(_0x52cb5e['target']):_0x52cb5e['target']);}return _0x194305;},_0x304d59['prototype']['serialize']=function(){var _0x1ab729={};_0x1ab729['name']=this['name'],_0x1ab729['from']=this['from'],_0x1ab729['to']=this['to'],_0x1ab729['targetedAnimations']=[];for(var _0x451995=0x0;_0x451995=0.5?0.5*(0x1-this['easeInCore'](0x2*(0x1-_0x23eff0)))+0.5:0.5*this['easeInCore'](0x2*_0x23eff0);},_0x5705c9['EASINGMODE_EASEIN']=0x0,_0x5705c9['EASINGMODE_EASEOUT']=0x1,_0x5705c9['EASINGMODE_EASEINOUT']=0x2,_0x5705c9;}()),_0x66297f=function(_0x38cd72){function _0x1f26c3(){return null!==_0x38cd72&&_0x38cd72['apply'](this,arguments)||this;}return Object(_0x18e13d['d'])(_0x1f26c3,_0x38cd72),_0x1f26c3['prototype']['easeInCore']=function(_0x4ec9a7){return _0x4ec9a7=Math['max'](0x0,Math['min'](0x1,_0x4ec9a7)),0x1-Math['sqrt'](0x1-_0x4ec9a7*_0x4ec9a7);},_0x1f26c3;}(_0x4ba918),_0x161f26=function(_0xc0ad01){function _0x1ee6eb(_0xc381ac){void 0x0===_0xc381ac&&(_0xc381ac=0x1);var _0x29fa6f=_0xc0ad01['call'](this)||this;return _0x29fa6f['amplitude']=_0xc381ac,_0x29fa6f;}return Object(_0x18e13d['d'])(_0x1ee6eb,_0xc0ad01),_0x1ee6eb['prototype']['easeInCore']=function(_0x444db8){var _0x34b939=Math['max'](0x0,this['amplitude']);return Math['pow'](_0x444db8,0x3)-_0x444db8*_0x34b939*Math['sin'](3.141592653589793*_0x444db8);},_0x1ee6eb;}(_0x4ba918),_0x63d35e=function(_0x359a7e){function _0x46fc81(_0xbf0f57,_0x31f00d){void 0x0===_0xbf0f57&&(_0xbf0f57=0x3),void 0x0===_0x31f00d&&(_0x31f00d=0x2);var _0x32ee7b=_0x359a7e['call'](this)||this;return _0x32ee7b['bounces']=_0xbf0f57,_0x32ee7b['bounciness']=_0x31f00d,_0x32ee7b;}return Object(_0x18e13d['d'])(_0x46fc81,_0x359a7e),_0x46fc81['prototype']['easeInCore']=function(_0x2da0f9){var _0x39c8fa=Math['max'](0x0,this['bounces']),_0xabd8e1=this['bounciness'];_0xabd8e1<=0x1&&(_0xabd8e1=1.001);var _0xbe1009=Math['pow'](_0xabd8e1,_0x39c8fa),_0x5aacec=0x1-_0xabd8e1,_0xac437a=(0x1-_0xbe1009)/_0x5aacec+0.5*_0xbe1009,_0x51ec8a=_0x2da0f9*_0xac437a,_0x2d4851=Math['log'](-_0x51ec8a*(0x1-_0xabd8e1)+0x1)/Math['log'](_0xabd8e1),_0x336ba3=Math['floor'](_0x2d4851),_0x4abfe9=_0x336ba3+0x1,_0x1832fa=(0x1-Math['pow'](_0xabd8e1,_0x336ba3))/(_0x5aacec*_0xac437a),_0x5c539d=0.5*(_0x1832fa+(0x1-Math['pow'](_0xabd8e1,_0x4abfe9))/(_0x5aacec*_0xac437a)),_0x3e92e2=_0x2da0f9-_0x5c539d,_0x407682=_0x5c539d-_0x1832fa;return-Math['pow'](0x1/_0xabd8e1,_0x39c8fa-_0x336ba3)/(_0x407682*_0x407682)*(_0x3e92e2-_0x407682)*(_0x3e92e2+_0x407682);},_0x46fc81;}(_0x4ba918),_0x4c6fcb=function(_0x482e85){function _0x5bfc70(){return null!==_0x482e85&&_0x482e85['apply'](this,arguments)||this;}return Object(_0x18e13d['d'])(_0x5bfc70,_0x482e85),_0x5bfc70['prototype']['easeInCore']=function(_0x5fabac){return _0x5fabac*_0x5fabac*_0x5fabac;},_0x5bfc70;}(_0x4ba918),_0x1e3d8f=function(_0x3b2718){function _0x3d98ec(_0x5e53f7,_0x343272){void 0x0===_0x5e53f7&&(_0x5e53f7=0x3),void 0x0===_0x343272&&(_0x343272=0x3);var _0x58bae6=_0x3b2718['call'](this)||this;return _0x58bae6['oscillations']=_0x5e53f7,_0x58bae6['springiness']=_0x343272,_0x58bae6;}return Object(_0x18e13d['d'])(_0x3d98ec,_0x3b2718),_0x3d98ec['prototype']['easeInCore']=function(_0x4c3870){var _0x457787=Math['max'](0x0,this['oscillations']),_0x2d7e4b=Math['max'](0x0,this['springiness']);return(0x0==_0x2d7e4b?_0x4c3870:(Math['exp'](_0x2d7e4b*_0x4c3870)-0x1)/(Math['exp'](_0x2d7e4b)-0x1))*Math['sin']((6.283185307179586*_0x457787+1.5707963267948966)*_0x4c3870);},_0x3d98ec;}(_0x4ba918),_0x5d36b0=function(_0x2fac64){function _0x565be4(_0x2f196b){void 0x0===_0x2f196b&&(_0x2f196b=0x2);var _0x21f040=_0x2fac64['call'](this)||this;return _0x21f040['exponent']=_0x2f196b,_0x21f040;}return Object(_0x18e13d['d'])(_0x565be4,_0x2fac64),_0x565be4['prototype']['easeInCore']=function(_0x2b780c){return this['exponent']<=0x0?_0x2b780c:(Math['exp'](this['exponent']*_0x2b780c)-0x1)/(Math['exp'](this['exponent'])-0x1);},_0x565be4;}(_0x4ba918),_0x254ce2=function(_0x4fb53f){function _0x1f3d6d(_0x5d5860){void 0x0===_0x5d5860&&(_0x5d5860=0x2);var _0x5b4a14=_0x4fb53f['call'](this)||this;return _0x5b4a14['power']=_0x5d5860,_0x5b4a14;}return Object(_0x18e13d['d'])(_0x1f3d6d,_0x4fb53f),_0x1f3d6d['prototype']['easeInCore']=function(_0x4cfdba){var _0xcc5f13=Math['max'](0x0,this['power']);return Math['pow'](_0x4cfdba,_0xcc5f13);},_0x1f3d6d;}(_0x4ba918),_0xb5f1d=function(_0x1eba1a){function _0x3a782d(){return null!==_0x1eba1a&&_0x1eba1a['apply'](this,arguments)||this;}return Object(_0x18e13d['d'])(_0x3a782d,_0x1eba1a),_0x3a782d['prototype']['easeInCore']=function(_0x2ab6a3){return _0x2ab6a3*_0x2ab6a3;},_0x3a782d;}(_0x4ba918),_0x4f49f4=function(_0xd879ef){function _0x31bf65(){return null!==_0xd879ef&&_0xd879ef['apply'](this,arguments)||this;}return Object(_0x18e13d['d'])(_0x31bf65,_0xd879ef),_0x31bf65['prototype']['easeInCore']=function(_0x5ebe32){return _0x5ebe32*_0x5ebe32*_0x5ebe32*_0x5ebe32;},_0x31bf65;}(_0x4ba918),_0x4d366f=function(_0x3ebe0f){function _0x590a84(){return null!==_0x3ebe0f&&_0x3ebe0f['apply'](this,arguments)||this;}return Object(_0x18e13d['d'])(_0x590a84,_0x3ebe0f),_0x590a84['prototype']['easeInCore']=function(_0x32d92e){return _0x32d92e*_0x32d92e*_0x32d92e*_0x32d92e*_0x32d92e;},_0x590a84;}(_0x4ba918),_0x4c852a=function(_0x3ce10b){function _0x200acf(){return null!==_0x3ce10b&&_0x3ce10b['apply'](this,arguments)||this;}return Object(_0x18e13d['d'])(_0x200acf,_0x3ce10b),_0x200acf['prototype']['easeInCore']=function(_0x5226f8){return 0x1-Math['sin'](1.5707963267948966*(0x1-_0x5226f8));},_0x200acf;}(_0x4ba918),_0x3a605e=function(_0x169e04){function _0x1e94cf(_0x54d3ba,_0x5c6f31,_0x2206a0,_0x3dc4d2){void 0x0===_0x54d3ba&&(_0x54d3ba=0x0),void 0x0===_0x5c6f31&&(_0x5c6f31=0x0),void 0x0===_0x2206a0&&(_0x2206a0=0x1),void 0x0===_0x3dc4d2&&(_0x3dc4d2=0x1);var _0x498ae8=_0x169e04['call'](this)||this;return _0x498ae8['x1']=_0x54d3ba,_0x498ae8['y1']=_0x5c6f31,_0x498ae8['x2']=_0x2206a0,_0x498ae8['y2']=_0x3dc4d2,_0x498ae8;}return Object(_0x18e13d['d'])(_0x1e94cf,_0x169e04),_0x1e94cf['prototype']['easeInCore']=function(_0x2ff020){return _0x5e9f26['c']['Interpolate'](_0x2ff020,this['x1'],this['y1'],this['x2'],this['y2']);},_0x1e94cf;}(_0x4ba918),_0x36110e=(function(){function _0x59f565(_0x30983d,_0x1b0981,_0x55a7d3){this['frame']=_0x30983d,this['action']=_0x1b0981,this['onlyOnce']=_0x55a7d3,this['isDone']=!0x1;}return _0x59f565['prototype']['_clone']=function(){return new _0x59f565(this['frame'],this['action'],this['onlyOnce']);},_0x59f565;}()),_0x3cf5e5=_0x162675(0x7),_0x406ff9=function(_0xea5416){function _0x30a4e8(){return null!==_0xea5416&&_0xea5416['apply'](this,arguments)||this;}return Object(_0x18e13d['d'])(_0x30a4e8,_0xea5416),_0x30a4e8;}(_0x3598db['a']),_0x25bb37=function(){this['rootNodes']=[],this['skeletons']=[],this['animationGroups']=[];},_0x3a6778=function(_0x18743c){function _0x37e397(_0x202a4b){var _0x49610e=_0x18743c['call'](this)||this;return _0x49610e['_wasAddedToScene']=!0x1,_0x49610e['scene']=_0x202a4b,_0x49610e['sounds']=[],_0x49610e['effectLayers']=[],_0x49610e['layers']=[],_0x49610e['lensFlareSystems']=[],_0x49610e['proceduralTextures']=[],_0x49610e['reflectionProbes']=[],_0x202a4b['onDisposeObservable']['add'](function(){_0x49610e['_wasAddedToScene']||_0x49610e['dispose']();}),_0x49610e;}return Object(_0x18e13d['d'])(_0x37e397,_0x18743c),_0x37e397['prototype']['instantiateModelsToScene']=function(_0x154d77,_0x3e8bb1){var _0x54ed5d=this;void 0x0===_0x3e8bb1&&(_0x3e8bb1=!0x1);var _0x20858d={},_0x5a98fe={},_0x208f8a=new _0x25bb37(),_0x5178e3=[],_0x230858=[],_0x2b8b75={'doNotInstantiate':!0x0},_0x46ec02=function(_0x2d81bb,_0x58900c){if(_0x20858d[_0x2d81bb['uniqueId']]=_0x58900c['uniqueId'],_0x5a98fe[_0x58900c['uniqueId']]=_0x58900c,_0x154d77&&(_0x58900c['name']=_0x154d77(_0x2d81bb['name'])),_0x58900c instanceof _0x3cf5e5['a']){var _0xa827c2=_0x58900c;if(_0xa827c2['morphTargetManager']){var _0x331f78=_0x2d81bb['morphTargetManager'];_0xa827c2['morphTargetManager']=_0x331f78['clone']();for(var _0x133497=0x0;_0x133497<_0x331f78['numTargets'];_0x133497++){var _0x1eb8f1=_0x331f78['getTarget'](_0x133497),_0x5e5c00=_0xa827c2['morphTargetManager']['getTarget'](_0x133497);_0x20858d[_0x1eb8f1['uniqueId']]=_0x5e5c00['uniqueId'],_0x5a98fe[_0x5e5c00['uniqueId']]=_0x5e5c00;}}}};return this['transformNodes']['forEach'](function(_0x203486){if(!_0x203486['parent']){var _0x4cbc09=_0x203486['instantiateHierarchy'](null,_0x2b8b75,function(_0x45e835,_0x4f7137){_0x46ec02(_0x45e835,_0x4f7137);});_0x4cbc09&&_0x208f8a['rootNodes']['push'](_0x4cbc09);}}),this['meshes']['forEach'](function(_0x56e3d2){if(!_0x56e3d2['parent']){var _0x19f208=_0x56e3d2['instantiateHierarchy'](null,_0x2b8b75,function(_0x59f4f4,_0x379aee){if(_0x46ec02(_0x59f4f4,_0x379aee),_0x379aee['material']){var _0x1d8b56=_0x379aee;if(_0x1d8b56['material']){if(_0x3e8bb1){var _0x11d2b0=_0x59f4f4['material'];if(-0x1===_0x230858['indexOf'](_0x11d2b0)){var _0x55d315=_0x11d2b0['clone'](_0x154d77?_0x154d77(_0x11d2b0['name']):'Clone\x20of\x20'+_0x11d2b0['name']);if(_0x230858['push'](_0x11d2b0),_0x20858d[_0x11d2b0['uniqueId']]=_0x55d315['uniqueId'],_0x5a98fe[_0x55d315['uniqueId']]=_0x55d315,'MultiMaterial'===_0x11d2b0['getClassName']()){for(var _0x38d38c=_0x11d2b0,_0x37f005=0x0,_0x9ea973=_0x38d38c['subMaterials'];_0x37f005<_0x9ea973['length'];_0x37f005++){var _0x10b2e6=_0x9ea973[_0x37f005];_0x10b2e6&&(_0x55d315=_0x10b2e6['clone'](_0x154d77?_0x154d77(_0x10b2e6['name']):'Clone\x20of\x20'+_0x10b2e6['name']),_0x230858['push'](_0x10b2e6),_0x20858d[_0x10b2e6['uniqueId']]=_0x55d315['uniqueId'],_0x5a98fe[_0x55d315['uniqueId']]=_0x55d315);}_0x38d38c['subMaterials']=_0x38d38c['subMaterials']['map'](function(_0x8f8ce8){return _0x8f8ce8&&_0x5a98fe[_0x20858d[_0x8f8ce8['uniqueId']]];});}}_0x1d8b56['material']=_0x5a98fe[_0x20858d[_0x11d2b0['uniqueId']]];}else'MultiMaterial'===_0x1d8b56['material']['getClassName']()?-0x1===_0x54ed5d['scene']['multiMaterials']['indexOf'](_0x1d8b56['material'])&&_0x54ed5d['scene']['addMultiMaterial'](_0x1d8b56['material']):-0x1===_0x54ed5d['scene']['materials']['indexOf'](_0x1d8b56['material'])&&_0x54ed5d['scene']['addMaterial'](_0x1d8b56['material']);}}});_0x19f208&&_0x208f8a['rootNodes']['push'](_0x19f208);}}),this['skeletons']['forEach'](function(_0x1e8da7){var _0x44d27a=_0x1e8da7['clone'](_0x154d77?_0x154d77(_0x1e8da7['name']):'Clone\x20of\x20'+_0x1e8da7['name']);_0x1e8da7['overrideMesh']&&(_0x44d27a['overrideMesh']=_0x5a98fe[_0x20858d[_0x1e8da7['overrideMesh']['uniqueId']]]);for(var _0x98f122=0x0,_0x2cc1ab=_0x54ed5d['meshes'];_0x98f122<_0x2cc1ab['length'];_0x98f122++){var _0x6a7a3e=_0x2cc1ab[_0x98f122];if(_0x6a7a3e['skeleton']===_0x1e8da7&&!_0x6a7a3e['isAnInstance']){if(_0x5a98fe[_0x20858d[_0x6a7a3e['uniqueId']]]['skeleton']=_0x44d27a,-0x1!==_0x5178e3['indexOf'](_0x44d27a))continue;_0x5178e3['push'](_0x44d27a);for(var _0x451e5c=0x0,_0x11168b=_0x44d27a['bones'];_0x451e5c<_0x11168b['length'];_0x451e5c++){var _0x56aa0b=_0x11168b[_0x451e5c];_0x56aa0b['_linkedTransformNode']&&(_0x56aa0b['_linkedTransformNode']=_0x5a98fe[_0x20858d[_0x56aa0b['_linkedTransformNode']['uniqueId']]]);}}}_0x208f8a['skeletons']['push'](_0x44d27a);}),this['animationGroups']['forEach'](function(_0x1b311d){var _0x237de2=_0x1b311d['clone'](_0x1b311d['name'],function(_0x4f1e24){return _0x5a98fe[_0x20858d[_0x4f1e24['uniqueId']]]||_0x4f1e24;});_0x208f8a['animationGroups']['push'](_0x237de2);}),_0x208f8a;},_0x37e397['prototype']['addAllToScene']=function(){var _0x1770d5=this;this['_wasAddedToScene']=!0x0,this['cameras']['forEach'](function(_0x1febfc){_0x1770d5['scene']['addCamera'](_0x1febfc);}),this['lights']['forEach'](function(_0x3b9753){_0x1770d5['scene']['addLight'](_0x3b9753);}),this['meshes']['forEach'](function(_0x5cfc9b){_0x1770d5['scene']['addMesh'](_0x5cfc9b);}),this['skeletons']['forEach'](function(_0x211045){_0x1770d5['scene']['addSkeleton'](_0x211045);}),this['animations']['forEach'](function(_0x1112b9){_0x1770d5['scene']['addAnimation'](_0x1112b9);}),this['animationGroups']['forEach'](function(_0x3dca20){_0x1770d5['scene']['addAnimationGroup'](_0x3dca20);}),this['multiMaterials']['forEach'](function(_0x35b652){_0x1770d5['scene']['addMultiMaterial'](_0x35b652);}),this['materials']['forEach'](function(_0x53e83e){_0x1770d5['scene']['addMaterial'](_0x53e83e);}),this['morphTargetManagers']['forEach'](function(_0x2c776c){_0x1770d5['scene']['addMorphTargetManager'](_0x2c776c);}),this['geometries']['forEach'](function(_0x54f01a){_0x1770d5['scene']['addGeometry'](_0x54f01a);}),this['transformNodes']['forEach'](function(_0xf61efc){_0x1770d5['scene']['addTransformNode'](_0xf61efc);}),this['actionManagers']['forEach'](function(_0x5d6172){_0x1770d5['scene']['addActionManager'](_0x5d6172);}),this['textures']['forEach'](function(_0x461359){_0x1770d5['scene']['addTexture'](_0x461359);}),this['reflectionProbes']['forEach'](function(_0xed1c2a){_0x1770d5['scene']['addReflectionProbe'](_0xed1c2a);}),this['environmentTexture']&&(this['scene']['environmentTexture']=this['environmentTexture']);for(var _0x569531=0x0,_0x229133=this['scene']['_serializableComponents'];_0x569531<_0x229133['length'];_0x569531++){_0x229133[_0x569531]['addFromContainer'](this);}},_0x37e397['prototype']['removeAllFromScene']=function(){var _0x5f3a1b=this;this['_wasAddedToScene']=!0x1,this['cameras']['forEach'](function(_0x9c54ff){_0x5f3a1b['scene']['removeCamera'](_0x9c54ff);}),this['lights']['forEach'](function(_0x312e00){_0x5f3a1b['scene']['removeLight'](_0x312e00);}),this['meshes']['forEach'](function(_0x21a210){_0x5f3a1b['scene']['removeMesh'](_0x21a210);}),this['skeletons']['forEach'](function(_0x2100fb){_0x5f3a1b['scene']['removeSkeleton'](_0x2100fb);}),this['animations']['forEach'](function(_0x5c2ff0){_0x5f3a1b['scene']['removeAnimation'](_0x5c2ff0);}),this['animationGroups']['forEach'](function(_0x37b84e){_0x5f3a1b['scene']['removeAnimationGroup'](_0x37b84e);}),this['multiMaterials']['forEach'](function(_0x2764b2){_0x5f3a1b['scene']['removeMultiMaterial'](_0x2764b2);}),this['materials']['forEach'](function(_0x4dc5d6){_0x5f3a1b['scene']['removeMaterial'](_0x4dc5d6);}),this['morphTargetManagers']['forEach'](function(_0x2717d0){_0x5f3a1b['scene']['removeMorphTargetManager'](_0x2717d0);}),this['geometries']['forEach'](function(_0x2de9d2){_0x5f3a1b['scene']['removeGeometry'](_0x2de9d2);}),this['transformNodes']['forEach'](function(_0x5be3f7){_0x5f3a1b['scene']['removeTransformNode'](_0x5be3f7);}),this['actionManagers']['forEach'](function(_0x441721){_0x5f3a1b['scene']['removeActionManager'](_0x441721);}),this['textures']['forEach'](function(_0x5b2e21){_0x5f3a1b['scene']['removeTexture'](_0x5b2e21);}),this['reflectionProbes']['forEach'](function(_0x2cc95c){_0x5f3a1b['scene']['removeReflectionProbe'](_0x2cc95c);}),this['environmentTexture']===this['scene']['environmentTexture']&&(this['scene']['environmentTexture']=null);for(var _0x2ec570=0x0,_0x15f24d=this['scene']['_serializableComponents'];_0x2ec570<_0x15f24d['length'];_0x2ec570++){_0x15f24d[_0x2ec570]['removeFromContainer'](this);}},_0x37e397['prototype']['dispose']=function(){this['cameras']['forEach'](function(_0x5d3b17){_0x5d3b17['dispose']();}),this['cameras']=[],this['lights']['forEach'](function(_0x5201ea){_0x5201ea['dispose']();}),this['lights']=[],this['meshes']['forEach'](function(_0x4a5d3f){_0x4a5d3f['dispose']();}),this['meshes']=[],this['skeletons']['forEach'](function(_0x4899db){_0x4899db['dispose']();}),this['skeletons']=[],this['animationGroups']['forEach'](function(_0x591459){_0x591459['dispose']();}),this['animationGroups']=[],this['multiMaterials']['forEach'](function(_0x4576a4){_0x4576a4['dispose']();}),this['multiMaterials']=[],this['materials']['forEach'](function(_0x58339d){_0x58339d['dispose']();}),this['materials']=[],this['geometries']['forEach'](function(_0x298393){_0x298393['dispose']();}),this['geometries']=[],this['transformNodes']['forEach'](function(_0x452b37){_0x452b37['dispose']();}),this['transformNodes']=[],this['actionManagers']['forEach'](function(_0x293d82){_0x293d82['dispose']();}),this['actionManagers']=[],this['textures']['forEach'](function(_0x470a60){_0x470a60['dispose']();}),this['textures']=[],this['reflectionProbes']['forEach'](function(_0x23a658){_0x23a658['dispose']();}),this['reflectionProbes']=[],this['environmentTexture']&&(this['environmentTexture']['dispose'](),this['environmentTexture']=null);for(var _0x3a14a8=0x0,_0x57c3f9=this['scene']['_serializableComponents'];_0x3a14a8<_0x57c3f9['length'];_0x3a14a8++){_0x57c3f9[_0x3a14a8]['removeFromContainer'](this,!0x0);}},_0x37e397['prototype']['_moveAssets']=function(_0x21a6a0,_0x24eb7e,_0x45398c){if(_0x21a6a0)for(var _0x48fb5a=0x0,_0x4673d7=_0x21a6a0;_0x48fb5a<_0x4673d7['length'];_0x48fb5a++){var _0x5e3ad2=_0x4673d7[_0x48fb5a],_0x519e13=!0x0;if(_0x45398c)for(var _0x2acd56=0x0,_0x2a1dc3=_0x45398c;_0x2acd56<_0x2a1dc3['length'];_0x2acd56++){if(_0x5e3ad2===_0x2a1dc3[_0x2acd56]){_0x519e13=!0x1;break;}}_0x519e13&&_0x24eb7e['push'](_0x5e3ad2);}},_0x37e397['prototype']['moveAllFromScene']=function(_0x4fd992){for(var _0x1dab52 in(this['_wasAddedToScene']=!0x1,void 0x0===_0x4fd992&&(_0x4fd992=new _0x406ff9()),this))this['hasOwnProperty'](_0x1dab52)&&(this[_0x1dab52]=this[_0x1dab52]||('environmentTexture'===_0x1dab52?null:[]),this['_moveAssets'](this['scene'][_0x1dab52],this[_0x1dab52],_0x4fd992[_0x1dab52]));this['environmentTexture']=this['scene']['environmentTexture'],this['removeAllFromScene']();},_0x37e397['prototype']['createRootMesh']=function(){var _0x20240c=new _0x3cf5e5['a']('assetContainerRootMesh',this['scene']);return this['meshes']['forEach'](function(_0x5174e8){_0x5174e8['parent']||_0x20240c['addChild'](_0x5174e8);}),this['meshes']['unshift'](_0x20240c),_0x20240c;},_0x37e397['prototype']['mergeAnimationsTo']=function(_0x4c480f,_0x5c6948,_0x745564){if(void 0x0===_0x4c480f&&(_0x4c480f=_0x44b9ce['a']['LastCreatedScene']),void 0x0===_0x745564&&(_0x745564=null),!_0x4c480f)return _0x75193d['a']['Error']('No\x20scene\x20available\x20to\x20merge\x20animations\x20to'),[];var _0x4ac6f3=_0x745564||function(_0xc46e95){var _0x3c7ceb=null,_0x2a62f6=_0xc46e95['animations']['length']?_0xc46e95['animations'][0x0]['targetProperty']:'',_0x14c508=_0xc46e95['name']['split']('.')['join']('')['split']('_primitive')[0x0];switch(_0x2a62f6){case'position':case'rotationQuaternion':_0x3c7ceb=_0x4c480f['getTransformNodeByName'](_0xc46e95['name'])||_0x4c480f['getTransformNodeByName'](_0x14c508);break;case'influence':_0x3c7ceb=_0x4c480f['getMorphTargetByName'](_0xc46e95['name'])||_0x4c480f['getMorphTargetByName'](_0x14c508);break;default:_0x3c7ceb=_0x4c480f['getNodeByName'](_0xc46e95['name'])||_0x4c480f['getNodeByName'](_0x14c508);}return _0x3c7ceb;};this['getNodes']()['forEach'](function(_0x23475f){var _0x46f790=_0x4ac6f3(_0x23475f);if(null!==_0x46f790){for(var _0x2c549f=function(_0x647d74){for(var _0x7f7d3c=0x0,_0x1d54b7=_0x46f790['animations']['filter'](function(_0x1a67fb){return _0x1a67fb['targetProperty']===_0x647d74['targetProperty'];});_0x7f7d3c<_0x1d54b7['length'];_0x7f7d3c++){var _0x5c16f3=_0x1d54b7[_0x7f7d3c],_0x4e7b3e=_0x46f790['animations']['indexOf'](_0x5c16f3,0x0);_0x4e7b3e>-0x1&&_0x46f790['animations']['splice'](_0x4e7b3e,0x1);}},_0x4c1787=0x0,_0x233137=_0x23475f['animations'];_0x4c1787<_0x233137['length'];_0x4c1787++){_0x2c549f(_0x233137[_0x4c1787]);}_0x46f790['animations']=_0x46f790['animations']['concat'](_0x23475f['animations']);}});var _0x4f5423=new Array();return this['animationGroups']['slice']()['forEach'](function(_0x2dfe17){_0x4f5423['push'](_0x2dfe17['clone'](_0x2dfe17['name'],_0x4ac6f3)),_0x2dfe17['animatables']['forEach'](function(_0xd42b1){_0xd42b1['stop']();});}),_0x5c6948['forEach'](function(_0x3d1390){var _0x48c577=_0x4ac6f3(_0x3d1390['target']);_0x48c577&&(_0x4c480f['beginAnimation'](_0x48c577,_0x3d1390['fromFrame'],_0x3d1390['toFrame'],_0x3d1390['loopAnimation'],_0x3d1390['speedRatio'],_0x3d1390['onAnimationEnd']?_0x3d1390['onAnimationEnd']:void 0x0,void 0x0,!0x0,void 0x0,_0x3d1390['onAnimationLoop']?_0x3d1390['onAnimationLoop']:void 0x0),_0x4c480f['stopAnimation'](_0x3d1390['target']));}),_0x4f5423;},_0x37e397;}(_0x3598db['a']),_0x300b38=_0x162675(0xd),_0x35fcc7=(function(){function _0x2540b6(_0x293d9d){this['SMOOTHING']=0.75,this['FFT_SIZE']=0x200,this['BARGRAPHAMPLITUDE']=0x100,this['DEBUGCANVASPOS']={'x':0x14,'y':0x14},this['DEBUGCANVASSIZE']={'width':0x140,'height':0xc8},this['_scene']=_0x293d9d,this['_audioEngine']=_0x300b38['a']['audioEngine'],this['_audioEngine']['canUseWebAudio']&&this['_audioEngine']['audioContext']&&(this['_webAudioAnalyser']=this['_audioEngine']['audioContext']['createAnalyser'](),this['_webAudioAnalyser']['minDecibels']=-0x8c,this['_webAudioAnalyser']['maxDecibels']=0x0,this['_byteFreqs']=new Uint8Array(this['_webAudioAnalyser']['frequencyBinCount']),this['_byteTime']=new Uint8Array(this['_webAudioAnalyser']['frequencyBinCount']),this['_floatFreqs']=new Float32Array(this['_webAudioAnalyser']['frequencyBinCount']));}return _0x2540b6['prototype']['getFrequencyBinCount']=function(){return this['_audioEngine']['canUseWebAudio']?this['_webAudioAnalyser']['frequencyBinCount']:0x0;},_0x2540b6['prototype']['getByteFrequencyData']=function(){return this['_audioEngine']['canUseWebAudio']&&(this['_webAudioAnalyser']['smoothingTimeConstant']=this['SMOOTHING'],this['_webAudioAnalyser']['fftSize']=this['FFT_SIZE'],this['_webAudioAnalyser']['getByteFrequencyData'](this['_byteFreqs'])),this['_byteFreqs'];},_0x2540b6['prototype']['getByteTimeDomainData']=function(){return this['_audioEngine']['canUseWebAudio']&&(this['_webAudioAnalyser']['smoothingTimeConstant']=this['SMOOTHING'],this['_webAudioAnalyser']['fftSize']=this['FFT_SIZE'],this['_webAudioAnalyser']['getByteTimeDomainData'](this['_byteTime'])),this['_byteTime'];},_0x2540b6['prototype']['getFloatFrequencyData']=function(){return this['_audioEngine']['canUseWebAudio']&&(this['_webAudioAnalyser']['smoothingTimeConstant']=this['SMOOTHING'],this['_webAudioAnalyser']['fftSize']=this['FFT_SIZE'],this['_webAudioAnalyser']['getFloatFrequencyData'](this['_floatFreqs'])),this['_floatFreqs'];},_0x2540b6['prototype']['drawDebugCanvas']=function(){var _0x438498=this;if(this['_audioEngine']['canUseWebAudio']&&(this['_debugCanvas']||(this['_debugCanvas']=document['createElement']('canvas'),this['_debugCanvas']['width']=this['DEBUGCANVASSIZE']['width'],this['_debugCanvas']['height']=this['DEBUGCANVASSIZE']['height'],this['_debugCanvas']['style']['position']='absolute',this['_debugCanvas']['style']['top']=this['DEBUGCANVASPOS']['y']+'px',this['_debugCanvas']['style']['left']=this['DEBUGCANVASPOS']['x']+'px',this['_debugCanvasContext']=this['_debugCanvas']['getContext']('2d'),document['body']['appendChild'](this['_debugCanvas']),this['_registerFunc']=function(){_0x438498['drawDebugCanvas']();},this['_scene']['registerBeforeRender'](this['_registerFunc'])),this['_registerFunc']&&this['_debugCanvasContext'])){var _0x227ef1=this['getByteFrequencyData']();this['_debugCanvasContext']['fillStyle']='rgb(0,\x200,\x200)',this['_debugCanvasContext']['fillRect'](0x0,0x0,this['DEBUGCANVASSIZE']['width'],this['DEBUGCANVASSIZE']['height']);for(var _0x5b52f0=0x0;_0x5b52f00x0&&(_0x4e47e7=!0x0,this['_soundLoaded'](_0x211ad3));break;case'String':_0x17b86b['push'](_0x211ad3);case'Array':0x0===_0x17b86b['length']&&(_0x17b86b=_0x211ad3);for(var _0x27252f=0x0;_0x27252f<_0x17b86b['length'];_0x27252f++){var _0x4cbaf5=_0x17b86b[_0x27252f];if(_0x4e47e7=_0x3ca66a&&_0x3ca66a['skipCodecCheck']||-0x1!==_0x4cbaf5['indexOf']('.mp3',_0x4cbaf5['length']-0x4)&&_0x300b38['a']['audioEngine']['isMP3supported']||-0x1!==_0x4cbaf5['indexOf']('.ogg',_0x4cbaf5['length']-0x4)&&_0x300b38['a']['audioEngine']['isOGGsupported']||-0x1!==_0x4cbaf5['indexOf']('.wav',_0x4cbaf5['length']-0x4)||-0x1!==_0x4cbaf5['indexOf']('.m4a',_0x4cbaf5['length']-0x4)||-0x1!==_0x4cbaf5['indexOf']('blob:')){this['_streaming']?(this['_htmlAudioElement']=new Audio(_0x4cbaf5),this['_htmlAudioElement']['controls']=!0x1,this['_htmlAudioElement']['loop']=this['loop'],_0x5d754c['b']['SetCorsBehavior'](_0x4cbaf5,this['_htmlAudioElement']),this['_htmlAudioElement']['preload']='auto',this['_htmlAudioElement']['addEventListener']('canplaythrough',function(){_0x334502['_isReadyToPlay']=!0x0,_0x334502['autoplay']&&_0x334502['play'](0x0,_0x334502['_offset'],_0x334502['_length']),_0x334502['_readyToPlayCallback']&&_0x334502['_readyToPlayCallback']();}),document['body']['appendChild'](this['_htmlAudioElement']),this['_htmlAudioElement']['load']()):this['_scene']['_loadFile'](_0x4cbaf5,function(_0x91542f){_0x334502['_soundLoaded'](_0x91542f);},void 0x0,!0x0,!0x0,function(_0x27bf5a){_0x27bf5a&&_0x75193d['a']['Error']('XHR\x20'+_0x27bf5a['status']+'\x20error\x20on:\x20'+_0x4cbaf5+'.'),_0x75193d['a']['Error']('Sound\x20creation\x20aborted.'),_0x334502['_scene']['mainSoundTrack']['removeSound'](_0x334502);});break;}}break;default:_0x580ed2=!0x1;}_0x580ed2?_0x4e47e7||(this['_isReadyToPlay']=!0x0,this['_readyToPlayCallback']&&window['setTimeout'](function(){_0x334502['_readyToPlayCallback']&&_0x334502['_readyToPlayCallback']();},0x3e8)):_0x75193d['a']['Error']('Parameter\x20must\x20be\x20a\x20URL\x20to\x20the\x20sound,\x20an\x20Array\x20of\x20URLs\x20(.mp3\x20&\x20.ogg)\x20or\x20an\x20ArrayBuffer\x20of\x20the\x20sound.');}catch(_0x236be8){_0x75193d['a']['Error']('Unexpected\x20error.\x20Sound\x20creation\x20aborted.'),this['_scene']['mainSoundTrack']['removeSound'](this);}}else this['_scene']['mainSoundTrack']['addSound'](this),_0x300b38['a']['audioEngine']['WarnedWebAudioUnsupported']||(_0x75193d['a']['Error']('Web\x20Audio\x20is\x20not\x20supported\x20by\x20your\x20browser.'),_0x300b38['a']['audioEngine']['WarnedWebAudioUnsupported']=!0x0),this['_readyToPlayCallback']&&window['setTimeout'](function(){_0x334502['_readyToPlayCallback']&&_0x334502['_readyToPlayCallback']();},0x3e8);}return Object['defineProperty'](_0x5b6428['prototype'],'currentTime',{'get':function(){if(this['_htmlAudioElement'])return this['_htmlAudioElement']['currentTime'];var _0x45b558=this['_startOffset'];return this['isPlaying']&&_0x300b38['a']['audioEngine']['audioContext']&&(_0x45b558+=_0x300b38['a']['audioEngine']['audioContext']['currentTime']-this['_startTime']),_0x45b558;},'enumerable':!0x1,'configurable':!0x0}),_0x5b6428['prototype']['dispose']=function(){_0x300b38['a']['audioEngine']['canUseWebAudio']&&(this['isPlaying']&&this['stop'](),this['_isReadyToPlay']=!0x1,-0x1===this['soundTrackId']?this['_scene']['mainSoundTrack']['removeSound'](this):this['_scene']['soundTracks']&&this['_scene']['soundTracks'][this['soundTrackId']]['removeSound'](this),this['_soundGain']&&(this['_soundGain']['disconnect'](),this['_soundGain']=null),this['_soundPanner']&&(this['_soundPanner']['disconnect'](),this['_soundPanner']=null),this['_soundSource']&&(this['_soundSource']['disconnect'](),this['_soundSource']=null),this['_audioBuffer']=null,this['_htmlAudioElement']&&(this['_htmlAudioElement']['pause'](),this['_htmlAudioElement']['src']='',document['body']['removeChild'](this['_htmlAudioElement'])),this['_streamingSource']&&this['_streamingSource']['disconnect'](),this['_connectedTransformNode']&&this['_registerFunc']&&(this['_connectedTransformNode']['unregisterAfterWorldMatrixUpdate'](this['_registerFunc']),this['_connectedTransformNode']=null));},_0x5b6428['prototype']['isReady']=function(){return this['_isReadyToPlay'];},_0x5b6428['prototype']['_soundLoaded']=function(_0x395134){var _0x2a4d75=this;_0x300b38['a']['audioEngine']['audioContext']&&_0x300b38['a']['audioEngine']['audioContext']['decodeAudioData'](_0x395134,function(_0x9bf07b){_0x2a4d75['_audioBuffer']=_0x9bf07b,_0x2a4d75['_isReadyToPlay']=!0x0,_0x2a4d75['autoplay']&&_0x2a4d75['play'](0x0,_0x2a4d75['_offset'],_0x2a4d75['_length']),_0x2a4d75['_readyToPlayCallback']&&_0x2a4d75['_readyToPlayCallback']();},function(_0x502583){_0x75193d['a']['Error']('Error\x20while\x20decoding\x20audio\x20data\x20for:\x20'+_0x2a4d75['name']+'\x20/\x20Error:\x20'+_0x502583);});},_0x5b6428['prototype']['setAudioBuffer']=function(_0x345f62){_0x300b38['a']['audioEngine']['canUseWebAudio']&&(this['_audioBuffer']=_0x345f62,this['_isReadyToPlay']=!0x0);},_0x5b6428['prototype']['updateOptions']=function(_0x1154cd){var _0x419d77,_0x48f59d,_0x389e61,_0x12ca6e,_0x201628,_0x19ddda,_0x4f4b71,_0x1e0fba,_0x4df529;_0x1154cd&&(this['loop']=null!==(_0x419d77=_0x1154cd['loop'])&&void 0x0!==_0x419d77?_0x419d77:this['loop'],this['maxDistance']=null!==(_0x48f59d=_0x1154cd['maxDistance'])&&void 0x0!==_0x48f59d?_0x48f59d:this['maxDistance'],this['useCustomAttenuation']=null!==(_0x389e61=_0x1154cd['useCustomAttenuation'])&&void 0x0!==_0x389e61?_0x389e61:this['useCustomAttenuation'],this['rolloffFactor']=null!==(_0x12ca6e=_0x1154cd['rolloffFactor'])&&void 0x0!==_0x12ca6e?_0x12ca6e:this['rolloffFactor'],this['refDistance']=null!==(_0x201628=_0x1154cd['refDistance'])&&void 0x0!==_0x201628?_0x201628:this['refDistance'],this['distanceModel']=null!==(_0x19ddda=_0x1154cd['distanceModel'])&&void 0x0!==_0x19ddda?_0x19ddda:this['distanceModel'],this['_playbackRate']=null!==(_0x4f4b71=_0x1154cd['playbackRate'])&&void 0x0!==_0x4f4b71?_0x4f4b71:this['_playbackRate'],this['_length']=null!==(_0x1e0fba=_0x1154cd['length'])&&void 0x0!==_0x1e0fba?_0x1e0fba:void 0x0,this['_offset']=null!==(_0x4df529=_0x1154cd['offset'])&&void 0x0!==_0x4df529?_0x4df529:void 0x0,this['_updateSpatialParameters'](),this['isPlaying']&&(this['_streaming']&&this['_htmlAudioElement']?(this['_htmlAudioElement']['playbackRate']=this['_playbackRate'],this['_htmlAudioElement']['loop']!==this['loop']&&(this['_htmlAudioElement']['loop']=this['loop'])):this['_soundSource']&&(this['_soundSource']['playbackRate']['value']=this['_playbackRate'],this['_soundSource']['loop']!==this['loop']&&(this['_soundSource']['loop']=this['loop']),void 0x0!==this['_offset']&&this['_soundSource']['loopStart']!==this['_offset']&&(this['_soundSource']['loopStart']=this['_offset']),void 0x0!==this['_length']&&this['_length']!==this['_soundSource']['loopEnd']&&(this['_soundSource']['loopEnd']=(0x0|this['_offset'])+this['_length']))));},_0x5b6428['prototype']['_createSpatialParameters']=function(){_0x300b38['a']['audioEngine']['canUseWebAudio']&&_0x300b38['a']['audioEngine']['audioContext']&&(this['_scene']['headphone']&&(this['_panningModel']='HRTF'),this['_soundPanner']=_0x300b38['a']['audioEngine']['audioContext']['createPanner'](),this['_soundPanner']&&this['_outputAudioNode']&&(this['_updateSpatialParameters'](),this['_soundPanner']['connect'](this['_outputAudioNode']),this['_inputAudioNode']=this['_soundPanner']));},_0x5b6428['prototype']['_updateSpatialParameters']=function(){this['spatialSound']&&this['_soundPanner']&&(this['useCustomAttenuation']?(this['_soundPanner']['distanceModel']='linear',this['_soundPanner']['maxDistance']=Number['MAX_VALUE'],this['_soundPanner']['refDistance']=0x1,this['_soundPanner']['rolloffFactor']=0x1,this['_soundPanner']['panningModel']=this['_panningModel']):(this['_soundPanner']['distanceModel']=this['distanceModel'],this['_soundPanner']['maxDistance']=this['maxDistance'],this['_soundPanner']['refDistance']=this['refDistance'],this['_soundPanner']['rolloffFactor']=this['rolloffFactor'],this['_soundPanner']['panningModel']=this['_panningModel']));},_0x5b6428['prototype']['switchPanningModelToHRTF']=function(){this['_panningModel']='HRTF',this['_switchPanningModel']();},_0x5b6428['prototype']['switchPanningModelToEqualPower']=function(){this['_panningModel']='equalpower',this['_switchPanningModel']();},_0x5b6428['prototype']['_switchPanningModel']=function(){_0x300b38['a']['audioEngine']['canUseWebAudio']&&this['spatialSound']&&this['_soundPanner']&&(this['_soundPanner']['panningModel']=this['_panningModel']);},_0x5b6428['prototype']['connectToSoundTrackAudioNode']=function(_0x35ee2f){_0x300b38['a']['audioEngine']['canUseWebAudio']&&this['_outputAudioNode']&&(this['_isOutputConnected']&&this['_outputAudioNode']['disconnect'](),this['_outputAudioNode']['connect'](_0x35ee2f),this['_isOutputConnected']=!0x0);},_0x5b6428['prototype']['setDirectionalCone']=function(_0x467d44,_0x2a26ef,_0x2b4ef5){_0x2a26ef<_0x467d44?_0x75193d['a']['Error']('setDirectionalCone():\x20outer\x20angle\x20of\x20the\x20cone\x20must\x20be\x20superior\x20or\x20equal\x20to\x20the\x20inner\x20angle.'):(this['_coneInnerAngle']=_0x467d44,this['_coneOuterAngle']=_0x2a26ef,this['_coneOuterGain']=_0x2b4ef5,this['_isDirectional']=!0x0,this['isPlaying']&&this['loop']&&(this['stop'](),this['play'](0x0,this['_offset'],this['_length'])));},Object['defineProperty'](_0x5b6428['prototype'],'directionalConeInnerAngle',{'get':function(){return this['_coneInnerAngle'];},'set':function(_0x460fd8){if(_0x460fd8!=this['_coneInnerAngle']){if(this['_coneOuterAngle']<_0x460fd8)return void _0x75193d['a']['Error']('directionalConeInnerAngle:\x20outer\x20angle\x20of\x20the\x20cone\x20must\x20be\x20superior\x20or\x20equal\x20to\x20the\x20inner\x20angle.');this['_coneInnerAngle']=_0x460fd8,_0x300b38['a']['audioEngine']['canUseWebAudio']&&this['spatialSound']&&this['_soundPanner']&&(this['_soundPanner']['coneInnerAngle']=this['_coneInnerAngle']);}},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5b6428['prototype'],'directionalConeOuterAngle',{'get':function(){return this['_coneOuterAngle'];},'set':function(_0x5ba949){if(_0x5ba949!=this['_coneOuterAngle']){if(_0x5ba9490x0&&(this['_htmlAudioElement']['currentTime']=0x0)):this['_streamingSource']['disconnect'](),this['isPlaying']=!0x1;else{if(_0x300b38['a']['audioEngine']['audioContext']&&this['_soundSource']){var _0x2f4433=_0x54acbd?_0x300b38['a']['audioEngine']['audioContext']['currentTime']+_0x54acbd:_0x300b38['a']['audioEngine']['audioContext']['currentTime'];this['_soundSource']['stop'](_0x2f4433),this['_soundSource']['onended']=function(){_0x394d56['isPlaying']=!0x1;},this['isPaused']||(this['_startOffset']=0x0);}}}},_0x5b6428['prototype']['pause']=function(){this['isPlaying']&&(this['isPaused']=!0x0,this['_streaming']?this['_htmlAudioElement']?this['_htmlAudioElement']['pause']():this['_streamingSource']['disconnect']():_0x300b38['a']['audioEngine']['audioContext']&&(this['stop'](0x0),this['_startOffset']+=_0x300b38['a']['audioEngine']['audioContext']['currentTime']-this['_startTime']));},_0x5b6428['prototype']['setVolume']=function(_0x148e54,_0x352154){_0x300b38['a']['audioEngine']['canUseWebAudio']&&this['_soundGain']&&(_0x352154&&_0x300b38['a']['audioEngine']['audioContext']?(this['_soundGain']['gain']['cancelScheduledValues'](_0x300b38['a']['audioEngine']['audioContext']['currentTime']),this['_soundGain']['gain']['setValueAtTime'](this['_soundGain']['gain']['value'],_0x300b38['a']['audioEngine']['audioContext']['currentTime']),this['_soundGain']['gain']['linearRampToValueAtTime'](_0x148e54,_0x300b38['a']['audioEngine']['audioContext']['currentTime']+_0x352154)):this['_soundGain']['gain']['value']=_0x148e54),this['_volume']=_0x148e54;},_0x5b6428['prototype']['setPlaybackRate']=function(_0x1c56ff){this['_playbackRate']=_0x1c56ff,this['isPlaying']&&(this['_streaming']&&this['_htmlAudioElement']?this['_htmlAudioElement']['playbackRate']=this['_playbackRate']:this['_soundSource']&&(this['_soundSource']['playbackRate']['value']=this['_playbackRate']));},_0x5b6428['prototype']['getVolume']=function(){return this['_volume'];},_0x5b6428['prototype']['attachToMesh']=function(_0x21d056){var _0x20e188=this;this['_connectedTransformNode']&&this['_registerFunc']&&(this['_connectedTransformNode']['unregisterAfterWorldMatrixUpdate'](this['_registerFunc']),this['_registerFunc']=null),this['_connectedTransformNode']=_0x21d056,this['spatialSound']||(this['spatialSound']=!0x0,this['_createSpatialParameters'](),this['isPlaying']&&this['loop']&&(this['stop'](),this['play'](0x0,this['_offset'],this['_length']))),this['_onRegisterAfterWorldMatrixUpdate'](this['_connectedTransformNode']),this['_registerFunc']=function(_0x46c5c8){return _0x20e188['_onRegisterAfterWorldMatrixUpdate'](_0x46c5c8);},this['_connectedTransformNode']['registerAfterWorldMatrixUpdate'](this['_registerFunc']);},_0x5b6428['prototype']['detachFromMesh']=function(){this['_connectedTransformNode']&&this['_registerFunc']&&(this['_connectedTransformNode']['unregisterAfterWorldMatrixUpdate'](this['_registerFunc']),this['_registerFunc']=null,this['_connectedTransformNode']=null);},_0x5b6428['prototype']['_onRegisterAfterWorldMatrixUpdate']=function(_0x370f3e){if(this['_positionInEmitterSpace'])_0x370f3e['worldMatrixFromCache']['invertToRef'](_0x74d525['c']['Matrix'][0x0]),this['setPosition'](_0x74d525['c']['Matrix'][0x0]['getTranslation']());else{if(_0x370f3e['getBoundingInfo']){var _0x1cbec7=_0x370f3e['getBoundingInfo']();this['setPosition'](_0x1cbec7['boundingSphere']['centerWorld']);}else this['setPosition'](_0x370f3e['absolutePosition']);}_0x300b38['a']['audioEngine']['canUseWebAudio']&&this['_isDirectional']&&this['isPlaying']&&this['_updateDirection']();},_0x5b6428['prototype']['clone']=function(){var _0x2395ef=this;if(this['_streaming'])return null;var _0x475243=function(){_0x2395ef['_isReadyToPlay']?(_0x50fcc7['_audioBuffer']=_0x2395ef['getAudioBuffer'](),_0x50fcc7['_isReadyToPlay']=!0x0,_0x50fcc7['autoplay']&&_0x50fcc7['play'](0x0,_0x2395ef['_offset'],_0x2395ef['_length'])):window['setTimeout'](_0x475243,0x12c);},_0x194d36={'autoplay':this['autoplay'],'loop':this['loop'],'volume':this['_volume'],'spatialSound':this['spatialSound'],'maxDistance':this['maxDistance'],'useCustomAttenuation':this['useCustomAttenuation'],'rolloffFactor':this['rolloffFactor'],'refDistance':this['refDistance'],'distanceModel':this['distanceModel']},_0x50fcc7=new _0x5b6428(this['name']+'_cloned',new ArrayBuffer(0x0),this['_scene'],null,_0x194d36);return this['useCustomAttenuation']&&_0x50fcc7['setAttenuationFunction'](this['_customAttenuationFunction']),_0x50fcc7['setPosition'](this['_position']),_0x50fcc7['setPlaybackRate'](this['_playbackRate']),_0x475243(),_0x50fcc7;},_0x5b6428['prototype']['getAudioBuffer']=function(){return this['_audioBuffer'];},_0x5b6428['prototype']['getSoundSource']=function(){return this['_soundSource'];},_0x5b6428['prototype']['getSoundGain']=function(){return this['_soundGain'];},_0x5b6428['prototype']['serialize']=function(){var _0x381652={'name':this['name'],'url':this['name'],'autoplay':this['autoplay'],'loop':this['loop'],'volume':this['_volume'],'spatialSound':this['spatialSound'],'maxDistance':this['maxDistance'],'rolloffFactor':this['rolloffFactor'],'refDistance':this['refDistance'],'distanceModel':this['distanceModel'],'playbackRate':this['_playbackRate'],'panningModel':this['_panningModel'],'soundTrackId':this['soundTrackId'],'metadata':this['metadata']};return this['spatialSound']&&(this['_connectedTransformNode']&&(_0x381652['connectedMeshId']=this['_connectedTransformNode']['id']),_0x381652['position']=this['_position']['asArray'](),_0x381652['refDistance']=this['refDistance'],_0x381652['distanceModel']=this['distanceModel'],_0x381652['isDirectional']=this['_isDirectional'],_0x381652['localDirectionToMesh']=this['_localDirection']['asArray'](),_0x381652['coneInnerAngle']=this['_coneInnerAngle'],_0x381652['coneOuterAngle']=this['_coneOuterAngle'],_0x381652['coneOuterGain']=this['_coneOuterGain']),_0x381652;},_0x5b6428['Parse']=function(_0x3bb318,_0x42fbc0,_0x2a4fe2,_0x42fdbd){var _0xd4f946,_0x4edff9=_0x3bb318['name'];_0xd4f946=_0x3bb318['url']?_0x2a4fe2+_0x3bb318['url']:_0x2a4fe2+_0x4edff9;var _0x39bdb0,_0x223f10={'autoplay':_0x3bb318['autoplay'],'loop':_0x3bb318['loop'],'volume':_0x3bb318['volume'],'spatialSound':_0x3bb318['spatialSound'],'maxDistance':_0x3bb318['maxDistance'],'rolloffFactor':_0x3bb318['rolloffFactor'],'refDistance':_0x3bb318['refDistance'],'distanceModel':_0x3bb318['distanceModel'],'playbackRate':_0x3bb318['playbackRate']};if(_0x42fdbd){var _0xd4f0f7=function(){_0x42fdbd['_isReadyToPlay']?(_0x39bdb0['_audioBuffer']=_0x42fdbd['getAudioBuffer'](),_0x39bdb0['_isReadyToPlay']=!0x0,_0x39bdb0['autoplay']&&_0x39bdb0['play'](0x0,_0x39bdb0['_offset'],_0x39bdb0['_length'])):window['setTimeout'](_0xd4f0f7,0x12c);};_0x39bdb0=new _0x5b6428(_0x4edff9,new ArrayBuffer(0x0),_0x42fbc0,null,_0x223f10),_0xd4f0f7();}else _0x39bdb0=new _0x5b6428(_0x4edff9,_0xd4f946,_0x42fbc0,function(){_0x42fbc0['_removePendingData'](_0x39bdb0);},_0x223f10),_0x42fbc0['_addPendingData'](_0x39bdb0);if(_0x3bb318['position']){var _0x576802=_0x74d525['e']['FromArray'](_0x3bb318['position']);_0x39bdb0['setPosition'](_0x576802);}if(_0x3bb318['isDirectional']&&(_0x39bdb0['setDirectionalCone'](_0x3bb318['coneInnerAngle']||0x168,_0x3bb318['coneOuterAngle']||0x168,_0x3bb318['coneOuterGain']||0x0),_0x3bb318['localDirectionToMesh'])){var _0x555a45=_0x74d525['e']['FromArray'](_0x3bb318['localDirectionToMesh']);_0x39bdb0['setLocalDirectionToMesh'](_0x555a45);}if(_0x3bb318['connectedMeshId']){var _0x44e265=_0x42fbc0['getMeshByID'](_0x3bb318['connectedMeshId']);_0x44e265&&_0x39bdb0['attachToMesh'](_0x44e265);}return _0x3bb318['metadata']&&(_0x39bdb0['metadata']=_0x3bb318['metadata']),_0x39bdb0;},_0x5b6428['_SceneComponentInitialization']=function(_0x134e73){throw _0x2de344['a']['WarnImport']('AudioSceneComponent');},_0x5b6428;}()),_0x11da99=(function(){function _0x14b6fc(_0x47ac28,_0x471203){void 0x0===_0x471203&&(_0x471203={}),this['id']=-0x1,this['_isInitialized']=!0x1,this['_scene']=_0x47ac28,this['soundCollection']=new Array(),this['_options']=_0x471203,!this['_options']['mainTrack']&&this['_scene']['soundTracks']&&(this['_scene']['soundTracks']['push'](this),this['id']=this['_scene']['soundTracks']['length']-0x1);}return _0x14b6fc['prototype']['_initializeSoundTrackAudioGraph']=function(){_0x300b38['a']['audioEngine']['canUseWebAudio']&&_0x300b38['a']['audioEngine']['audioContext']&&(this['_outputAudioNode']=_0x300b38['a']['audioEngine']['audioContext']['createGain'](),this['_outputAudioNode']['connect'](_0x300b38['a']['audioEngine']['masterGain']),this['_options']&&this['_options']['volume']&&(this['_outputAudioNode']['gain']['value']=this['_options']['volume']),this['_isInitialized']=!0x0);},_0x14b6fc['prototype']['dispose']=function(){if(_0x300b38['a']['audioEngine']&&_0x300b38['a']['audioEngine']['canUseWebAudio']){for(this['_connectedAnalyser']&&this['_connectedAnalyser']['stopDebugCanvas']();this['soundCollection']['length'];)this['soundCollection'][0x0]['dispose']();this['_outputAudioNode']&&this['_outputAudioNode']['disconnect'](),this['_outputAudioNode']=null;}},_0x14b6fc['prototype']['addSound']=function(_0x3eff53){this['_isInitialized']||this['_initializeSoundTrackAudioGraph'](),_0x300b38['a']['audioEngine']['canUseWebAudio']&&this['_outputAudioNode']&&_0x3eff53['connectToSoundTrackAudioNode'](this['_outputAudioNode']),_0x3eff53['soundTrackId']&&(-0x1===_0x3eff53['soundTrackId']?this['_scene']['mainSoundTrack']['removeSound'](_0x3eff53):this['_scene']['soundTracks']&&this['_scene']['soundTracks'][_0x3eff53['soundTrackId']]['removeSound'](_0x3eff53)),this['soundCollection']['push'](_0x3eff53),_0x3eff53['soundTrackId']=this['id'];},_0x14b6fc['prototype']['removeSound']=function(_0x407538){var _0x90533d=this['soundCollection']['indexOf'](_0x407538);-0x1!==_0x90533d&&this['soundCollection']['splice'](_0x90533d,0x1);},_0x14b6fc['prototype']['setVolume']=function(_0x354823){_0x300b38['a']['audioEngine']['canUseWebAudio']&&this['_outputAudioNode']&&(this['_outputAudioNode']['gain']['value']=_0x354823);},_0x14b6fc['prototype']['switchPanningModelToHRTF']=function(){if(_0x300b38['a']['audioEngine']['canUseWebAudio']){for(var _0x5f32b4=0x0;_0x5f32b40x0?_0x1001a4['activeCameras'][0x0]:_0x1001a4['activeCamera']){this['_cachedCameraPosition']['equals'](_0x4607b1['globalPosition'])||(this['_cachedCameraPosition']['copyFrom'](_0x4607b1['globalPosition']),_0x802d00['audioContext']['listener']['setPosition'](_0x4607b1['globalPosition']['x'],_0x4607b1['globalPosition']['y'],_0x4607b1['globalPosition']['z'])),_0x4607b1['rigCameras']&&_0x4607b1['rigCameras']['length']>0x0&&(_0x4607b1=_0x4607b1['rigCameras'][0x0]);var _0x262073=_0x74d525['a']['Invert'](_0x4607b1['getViewMatrix']()),_0x47095d=_0x74d525['e']['TransformNormal'](_0x1001a4['useRightHandedSystem']?_0x389547['_CameraDirectionRH']:_0x389547['_CameraDirectionLH'],_0x262073);_0x47095d['normalize'](),isNaN(_0x47095d['x'])||isNaN(_0x47095d['y'])||isNaN(_0x47095d['z'])||this['_cachedCameraDirection']['equals'](_0x47095d)||(this['_cachedCameraDirection']['copyFrom'](_0x47095d),_0x802d00['audioContext']['listener']['setOrientation'](_0x47095d['x'],_0x47095d['y'],_0x47095d['z'],0x0,0x1,0x0));}else _0x802d00['audioContext']['listener']['setPosition'](0x0,0x0,0x0);}var _0xfbd629;for(_0xfbd629=0x0;_0xfbd629<_0x1001a4['mainSoundTrack']['soundCollection']['length'];_0xfbd629++){var _0x34be76=_0x1001a4['mainSoundTrack']['soundCollection'][_0xfbd629];_0x34be76['useCustomAttenuation']&&_0x34be76['updateDistanceFromListener']();}if(_0x1001a4['soundTracks']){for(_0xfbd629=0x0;_0xfbd629<_0x1001a4['soundTracks']['length'];_0xfbd629++)for(var _0xe8979d=0x0;_0xe8979d<_0x1001a4['soundTracks'][_0xfbd629]['soundCollection']['length'];_0xe8979d++)(_0x34be76=_0x1001a4['soundTracks'][_0xfbd629]['soundCollection'][_0xe8979d])['useCustomAttenuation']&&_0x34be76['updateDistanceFromListener']();}}}}},_0x389547['_CameraDirectionLH']=new _0x74d525['e'](0x0,0x0,-0x1),_0x389547['_CameraDirectionRH']=new _0x74d525['e'](0x0,0x0,0x1),_0x389547;}());_0x13741a['_SceneComponentInitialization']=function(_0xc2ecb2){var _0x11189b=_0xc2ecb2['_getComponent'](_0x384de3['a']['NAME_AUDIO']);_0x11189b||(_0x11189b=new _0x1db746(_0xc2ecb2),_0xc2ecb2['_addComponent'](_0x11189b));};var _0x44c93c=(function(){function _0xe64b35(_0x12f61c,_0x359f16,_0x431e8d){var _0x4c9dbf=this;if(this['loop']=!0x1,this['_coneInnerAngle']=0x168,this['_coneOuterAngle']=0x168,this['_volume']=0x1,this['isPlaying']=!0x1,this['isPaused']=!0x1,this['_sounds']=[],this['_weights']=[],_0x359f16['length']!==_0x431e8d['length'])throw new Error('Sounds\x20length\x20does\x20not\x20equal\x20weights\x20length');this['loop']=_0x12f61c,this['_weights']=_0x431e8d;for(var _0x574e9d=0x0,_0x331386=0x0,_0x3e1a2c=_0x431e8d;_0x331386<_0x3e1a2c['length'];_0x331386++){_0x574e9d+=_0x3e1a2c[_0x331386];}for(var _0x399155=_0x574e9d>0x0?0x1/_0x574e9d:0x0,_0x258c60=0x0;_0x258c600x0;},'enumerable':!0x1,'configurable':!0x0}),_0x32becc['prototype']['init']=function(){},_0x32becc['prototype']['attach']=function(_0x2056c1){var _0x2368e7=this;this['_attachedCamera']=_0x2056c1;var _0x24c3dd=this['_attachedCamera']['getScene']();this['_onPrePointerObservableObserver']=_0x24c3dd['onPrePointerObservable']['add'](function(_0x7c7b85){_0x7c7b85['type']!==_0x1cb628['a']['POINTERDOWN']?_0x7c7b85['type']===_0x1cb628['a']['POINTERUP']&&(_0x2368e7['_isPointerDown']=!0x1):_0x2368e7['_isPointerDown']=!0x0;}),this['_onAfterCheckInputsObserver']=_0x2056c1['onAfterCheckInputsObservable']['add'](function(){var _0x45b6e2=_0x49f003['a']['Now'],_0xcf9e99=0x0;null!=_0x2368e7['_lastFrameTime']&&(_0xcf9e99=_0x45b6e2-_0x2368e7['_lastFrameTime']),_0x2368e7['_lastFrameTime']=_0x45b6e2,_0x2368e7['_applyUserInteraction']();var _0x35737a=_0x45b6e2-_0x2368e7['_lastInteractionTime']-_0x2368e7['_idleRotationWaitTime'],_0x3cc591=Math['max'](Math['min'](_0x35737a/_0x2368e7['_idleRotationSpinupTime'],0x1),0x0);_0x2368e7['_cameraRotationSpeed']=_0x2368e7['_idleRotationSpeed']*_0x3cc591,_0x2368e7['_attachedCamera']&&(_0x2368e7['_attachedCamera']['alpha']-=_0x2368e7['_cameraRotationSpeed']*(_0xcf9e99/0x3e8));});},_0x32becc['prototype']['detach']=function(){if(this['_attachedCamera']){var _0x1129fd=this['_attachedCamera']['getScene']();this['_onPrePointerObservableObserver']&&_0x1129fd['onPrePointerObservable']['remove'](this['_onPrePointerObservableObserver']),this['_attachedCamera']['onAfterCheckInputsObservable']['remove'](this['_onAfterCheckInputsObserver']),this['_attachedCamera']=null;}},_0x32becc['prototype']['_userIsZooming']=function(){return!!this['_attachedCamera']&&0x0!==this['_attachedCamera']['inertialRadiusOffset'];},_0x32becc['prototype']['_shouldAnimationStopForInteraction']=function(){if(!this['_attachedCamera'])return!0x1;var _0x24a4d3=!0x1;return this['_lastFrameRadius']===this['_attachedCamera']['radius']&&0x0!==this['_attachedCamera']['inertialRadiusOffset']&&(_0x24a4d3=!0x0),this['_lastFrameRadius']=this['_attachedCamera']['radius'],this['_zoomStopsAnimation']?_0x24a4d3:this['_userIsZooming']();},_0x32becc['prototype']['_applyUserInteraction']=function(){this['_userIsMoving']()&&!this['_shouldAnimationStopForInteraction']()&&(this['_lastInteractionTime']=_0x49f003['a']['Now']);},_0x32becc['prototype']['_userIsMoving']=function(){return!!this['_attachedCamera']&&(0x0!==this['_attachedCamera']['inertialAlphaOffset']||0x0!==this['_attachedCamera']['inertialBetaOffset']||0x0!==this['_attachedCamera']['inertialRadiusOffset']||0x0!==this['_attachedCamera']['inertialPanningX']||0x0!==this['_attachedCamera']['inertialPanningY']||this['_isPointerDown']);},_0x32becc;}()),_0x3e9056=(function(){function _0x3c37a8(){this['transitionDuration']=0x1c2,this['lowerRadiusTransitionRange']=0x2,this['upperRadiusTransitionRange']=-0x2,this['_autoTransitionRange']=!0x1,this['_radiusIsAnimating']=!0x1,this['_radiusBounceTransition']=null,this['_animatables']=new Array();}return Object['defineProperty'](_0x3c37a8['prototype'],'name',{'get':function(){return'Bouncing';},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3c37a8['prototype'],'autoTransitionRange',{'get':function(){return this['_autoTransitionRange'];},'set':function(_0x2a7776){var _0x53b08e=this;if(this['_autoTransitionRange']!==_0x2a7776){this['_autoTransitionRange']=_0x2a7776;var _0x1fcf7=this['_attachedCamera'];_0x1fcf7&&(_0x2a7776?this['_onMeshTargetChangedObserver']=_0x1fcf7['onMeshTargetChangedObservable']['add'](function(_0x5bffaf){if(_0x5bffaf){_0x5bffaf['computeWorldMatrix'](!0x0);var _0x1e4a5d=_0x5bffaf['getBoundingInfo']()['diagonalLength'];_0x53b08e['lowerRadiusTransitionRange']=0.05*_0x1e4a5d,_0x53b08e['upperRadiusTransitionRange']=0.05*_0x1e4a5d;}}):this['_onMeshTargetChangedObserver']&&_0x1fcf7['onMeshTargetChangedObservable']['remove'](this['_onMeshTargetChangedObserver']));}},'enumerable':!0x1,'configurable':!0x0}),_0x3c37a8['prototype']['init']=function(){},_0x3c37a8['prototype']['attach']=function(_0x50aae1){var _0x2b495a=this;this['_attachedCamera']=_0x50aae1,this['_onAfterCheckInputsObserver']=_0x50aae1['onAfterCheckInputsObservable']['add'](function(){_0x2b495a['_attachedCamera']&&(_0x2b495a['_isRadiusAtLimit'](_0x2b495a['_attachedCamera']['lowerRadiusLimit'])&&_0x2b495a['_applyBoundRadiusAnimation'](_0x2b495a['lowerRadiusTransitionRange']),_0x2b495a['_isRadiusAtLimit'](_0x2b495a['_attachedCamera']['upperRadiusLimit'])&&_0x2b495a['_applyBoundRadiusAnimation'](_0x2b495a['upperRadiusTransitionRange']));});},_0x3c37a8['prototype']['detach']=function(){this['_attachedCamera']&&(this['_onAfterCheckInputsObserver']&&this['_attachedCamera']['onAfterCheckInputsObservable']['remove'](this['_onAfterCheckInputsObserver']),this['_onMeshTargetChangedObserver']&&this['_attachedCamera']['onMeshTargetChangedObservable']['remove'](this['_onMeshTargetChangedObserver']),this['_attachedCamera']=null);},_0x3c37a8['prototype']['_isRadiusAtLimit']=function(_0x1dd831){return!!this['_attachedCamera']&&(this['_attachedCamera']['radius']===_0x1dd831&&!this['_radiusIsAnimating']);},_0x3c37a8['prototype']['_applyBoundRadiusAnimation']=function(_0x2baa0e){var _0xf8b8e1=this;if(this['_attachedCamera']){this['_radiusBounceTransition']||(_0x3c37a8['EasingFunction']['setEasingMode'](_0x3c37a8['EasingMode']),this['_radiusBounceTransition']=_0x1b0498['CreateAnimation']('radius',_0x1b0498['ANIMATIONTYPE_FLOAT'],0x3c,_0x3c37a8['EasingFunction'])),this['_cachedWheelPrecision']=this['_attachedCamera']['wheelPrecision'],this['_attachedCamera']['wheelPrecision']=0x1/0x0,this['_attachedCamera']['inertialRadiusOffset']=0x0,this['stopAllAnimations'](),this['_radiusIsAnimating']=!0x0;var _0x4eca14=_0x1b0498['TransitionTo']('radius',this['_attachedCamera']['radius']+_0x2baa0e,this['_attachedCamera'],this['_attachedCamera']['getScene'](),0x3c,this['_radiusBounceTransition'],this['transitionDuration'],function(){return _0xf8b8e1['_clearAnimationLocks']();});_0x4eca14&&this['_animatables']['push'](_0x4eca14);}},_0x3c37a8['prototype']['_clearAnimationLocks']=function(){this['_radiusIsAnimating']=!0x1,this['_attachedCamera']&&(this['_attachedCamera']['wheelPrecision']=this['_cachedWheelPrecision']);},_0x3c37a8['prototype']['stopAllAnimations']=function(){for(this['_attachedCamera']&&(this['_attachedCamera']['animations']=[]);this['_animatables']['length'];)this['_animatables'][0x0]['onAnimationEnd']=null,this['_animatables'][0x0]['stop'](),this['_animatables']['shift']();},_0x3c37a8['EasingFunction']=new _0x161f26(0.3),_0x3c37a8['EasingMode']=_0x4ba918['EASINGMODE_EASEOUT'],_0x3c37a8;}()),_0x593fc5=(function(){function _0x108684(){this['_mode']=_0x108684['FitFrustumSidesMode'],this['_radiusScale']=0x1,this['_positionScale']=0.5,this['_defaultElevation']=0.3,this['_elevationReturnTime']=0x5dc,this['_elevationReturnWaitTime']=0x3e8,this['_zoomStopsAnimation']=!0x1,this['_framingTime']=0x5dc,this['autoCorrectCameraLimitsAndSensibility']=!0x0,this['_isPointerDown']=!0x1,this['_lastInteractionTime']=-0x1/0x0,this['_animatables']=new Array(),this['_betaIsAnimating']=!0x1;}return Object['defineProperty'](_0x108684['prototype'],'name',{'get':function(){return'Framing';},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x108684['prototype'],'mode',{'get':function(){return this['_mode'];},'set':function(_0x18faa0){this['_mode']=_0x18faa0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x108684['prototype'],'radiusScale',{'get':function(){return this['_radiusScale'];},'set':function(_0x3a6dde){this['_radiusScale']=_0x3a6dde;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x108684['prototype'],'positionScale',{'get':function(){return this['_positionScale'];},'set':function(_0x29041c){this['_positionScale']=_0x29041c;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x108684['prototype'],'defaultElevation',{'get':function(){return this['_defaultElevation'];},'set':function(_0x3cadec){this['_defaultElevation']=_0x3cadec;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x108684['prototype'],'elevationReturnTime',{'get':function(){return this['_elevationReturnTime'];},'set':function(_0x4d3dfd){this['_elevationReturnTime']=_0x4d3dfd;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x108684['prototype'],'elevationReturnWaitTime',{'get':function(){return this['_elevationReturnWaitTime'];},'set':function(_0x4f97b5){this['_elevationReturnWaitTime']=_0x4f97b5;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x108684['prototype'],'zoomStopsAnimation',{'get':function(){return this['_zoomStopsAnimation'];},'set':function(_0x34b0b6){this['_zoomStopsAnimation']=_0x34b0b6;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x108684['prototype'],'framingTime',{'get':function(){return this['_framingTime'];},'set':function(_0x594117){this['_framingTime']=_0x594117;},'enumerable':!0x1,'configurable':!0x0}),_0x108684['prototype']['init']=function(){},_0x108684['prototype']['attach']=function(_0x135441){var _0x2291b0=this;this['_attachedCamera']=_0x135441;var _0x3b2774=this['_attachedCamera']['getScene']();_0x108684['EasingFunction']['setEasingMode'](_0x108684['EasingMode']),this['_onPrePointerObservableObserver']=_0x3b2774['onPrePointerObservable']['add'](function(_0x11c88c){_0x11c88c['type']!==_0x1cb628['a']['POINTERDOWN']?_0x11c88c['type']===_0x1cb628['a']['POINTERUP']&&(_0x2291b0['_isPointerDown']=!0x1):_0x2291b0['_isPointerDown']=!0x0;}),this['_onMeshTargetChangedObserver']=_0x135441['onMeshTargetChangedObservable']['add'](function(_0x4932a5){_0x4932a5&&_0x2291b0['zoomOnMesh'](_0x4932a5);}),this['_onAfterCheckInputsObserver']=_0x135441['onAfterCheckInputsObservable']['add'](function(){_0x2291b0['_applyUserInteraction'](),_0x2291b0['_maintainCameraAboveGround']();});},_0x108684['prototype']['detach']=function(){if(this['_attachedCamera']){var _0x2b3483=this['_attachedCamera']['getScene']();this['_onPrePointerObservableObserver']&&_0x2b3483['onPrePointerObservable']['remove'](this['_onPrePointerObservableObserver']),this['_onAfterCheckInputsObserver']&&this['_attachedCamera']['onAfterCheckInputsObservable']['remove'](this['_onAfterCheckInputsObserver']),this['_onMeshTargetChangedObserver']&&this['_attachedCamera']['onMeshTargetChangedObservable']['remove'](this['_onMeshTargetChangedObserver']),this['_attachedCamera']=null;}},_0x108684['prototype']['zoomOnMesh']=function(_0x4604a2,_0x35f16e,_0x542718){void 0x0===_0x35f16e&&(_0x35f16e=!0x1),void 0x0===_0x542718&&(_0x542718=null),_0x4604a2['computeWorldMatrix'](!0x0);var _0x43e2bc=_0x4604a2['getBoundingInfo']()['boundingBox'];this['zoomOnBoundingInfo'](_0x43e2bc['minimumWorld'],_0x43e2bc['maximumWorld'],_0x35f16e,_0x542718);},_0x108684['prototype']['zoomOnMeshHierarchy']=function(_0xd56ccd,_0x44b0f4,_0x223d7c){void 0x0===_0x44b0f4&&(_0x44b0f4=!0x1),void 0x0===_0x223d7c&&(_0x223d7c=null),_0xd56ccd['computeWorldMatrix'](!0x0);var _0x197395=_0xd56ccd['getHierarchyBoundingVectors'](!0x0);this['zoomOnBoundingInfo'](_0x197395['min'],_0x197395['max'],_0x44b0f4,_0x223d7c);},_0x108684['prototype']['zoomOnMeshesHierarchy']=function(_0x169ce1,_0x3ce6d1,_0x326b63){void 0x0===_0x3ce6d1&&(_0x3ce6d1=!0x1),void 0x0===_0x326b63&&(_0x326b63=null);for(var _0x536387=new _0x74d525['e'](Number['MAX_VALUE'],Number['MAX_VALUE'],Number['MAX_VALUE']),_0x3fd645=new _0x74d525['e'](-Number['MAX_VALUE'],-Number['MAX_VALUE'],-Number['MAX_VALUE']),_0x2145ca=0x0;_0x2145ca<_0x169ce1['length'];_0x2145ca++){var _0x5a01b8=_0x169ce1[_0x2145ca]['getHierarchyBoundingVectors'](!0x0);_0x74d525['e']['CheckExtends'](_0x5a01b8['min'],_0x536387,_0x3fd645),_0x74d525['e']['CheckExtends'](_0x5a01b8['max'],_0x536387,_0x3fd645);}this['zoomOnBoundingInfo'](_0x536387,_0x3fd645,_0x3ce6d1,_0x326b63);},_0x108684['prototype']['zoomOnBoundingInfo']=function(_0x2270c0,_0x8cea72,_0x51f9,_0x58decd){var _0x49f5b8,_0x1b2dde=this;if(void 0x0===_0x51f9&&(_0x51f9=!0x1),void 0x0===_0x58decd&&(_0x58decd=null),this['_attachedCamera']){var _0x4a00be=_0x2270c0['y'],_0x187593=_0x4a00be+(_0x8cea72['y']-_0x4a00be)*this['_positionScale'],_0x4b1f2c=_0x8cea72['subtract'](_0x2270c0)['scale'](0.5);if(_0x51f9)_0x49f5b8=new _0x74d525['e'](0x0,_0x187593,0x0);else{var _0x3815b2=_0x2270c0['add'](_0x4b1f2c);_0x49f5b8=new _0x74d525['e'](_0x3815b2['x'],_0x187593,_0x3815b2['z']);}this['_vectorTransition']||(this['_vectorTransition']=_0x1b0498['CreateAnimation']('target',_0x1b0498['ANIMATIONTYPE_VECTOR3'],0x3c,_0x108684['EasingFunction'])),this['_betaIsAnimating']=!0x0;var _0x299a71=_0x1b0498['TransitionTo']('target',_0x49f5b8,this['_attachedCamera'],this['_attachedCamera']['getScene'](),0x3c,this['_vectorTransition'],this['_framingTime']);_0x299a71&&this['_animatables']['push'](_0x299a71);var _0x56e02f=0x0;if(this['_mode']===_0x108684['FitFrustumSidesMode']){var _0x2fca1b=this['_calculateLowerRadiusFromModelBoundingSphere'](_0x2270c0,_0x8cea72);this['autoCorrectCameraLimitsAndSensibility']&&(this['_attachedCamera']['lowerRadiusLimit']=_0x4b1f2c['length']()+this['_attachedCamera']['minZ']),_0x56e02f=_0x2fca1b;}else this['_mode']===_0x108684['IgnoreBoundsSizeMode']&&(_0x56e02f=this['_calculateLowerRadiusFromModelBoundingSphere'](_0x2270c0,_0x8cea72),this['autoCorrectCameraLimitsAndSensibility']&&null===this['_attachedCamera']['lowerRadiusLimit']&&(this['_attachedCamera']['lowerRadiusLimit']=this['_attachedCamera']['minZ']));if(this['autoCorrectCameraLimitsAndSensibility']){var _0x1edae2=_0x8cea72['subtract'](_0x2270c0)['length']();this['_attachedCamera']['panningSensibility']=0x1388/_0x1edae2,this['_attachedCamera']['wheelPrecision']=0x64/_0x56e02f;}this['_radiusTransition']||(this['_radiusTransition']=_0x1b0498['CreateAnimation']('radius',_0x1b0498['ANIMATIONTYPE_FLOAT'],0x3c,_0x108684['EasingFunction'])),(_0x299a71=_0x1b0498['TransitionTo']('radius',_0x56e02f,this['_attachedCamera'],this['_attachedCamera']['getScene'](),0x3c,this['_radiusTransition'],this['_framingTime'],function(){_0x1b2dde['stopAllAnimations'](),_0x58decd&&_0x58decd(),_0x1b2dde['_attachedCamera']&&_0x1b2dde['_attachedCamera']['useInputToRestoreState']&&_0x1b2dde['_attachedCamera']['storeState']();}))&&this['_animatables']['push'](_0x299a71);}},_0x108684['prototype']['_calculateLowerRadiusFromModelBoundingSphere']=function(_0x49be51,_0x2818c8){var _0x319eed=_0x2818c8['subtract'](_0x49be51)['length'](),_0x19f16e=this['_getFrustumSlope'](),_0x3ff2e6=0.5*_0x319eed*this['_radiusScale'],_0x49e2af=_0x3ff2e6*Math['sqrt'](0x1+0x1/(_0x19f16e['x']*_0x19f16e['x'])),_0x3ac3bd=_0x3ff2e6*Math['sqrt'](0x1+0x1/(_0x19f16e['y']*_0x19f16e['y'])),_0x443e0a=Math['max'](_0x49e2af,_0x3ac3bd),_0x5dc64d=this['_attachedCamera'];return _0x5dc64d?(_0x5dc64d['lowerRadiusLimit']&&this['_mode']===_0x108684['IgnoreBoundsSizeMode']&&(_0x443e0a=_0x443e0a<_0x5dc64d['lowerRadiusLimit']?_0x5dc64d['lowerRadiusLimit']:_0x443e0a),_0x5dc64d['upperRadiusLimit']&&(_0x443e0a=_0x443e0a>_0x5dc64d['upperRadiusLimit']?_0x5dc64d['upperRadiusLimit']:_0x443e0a),_0x443e0a):0x0;},_0x108684['prototype']['_maintainCameraAboveGround']=function(){var _0x3ca5bf=this;if(!(this['_elevationReturnTime']<0x0)){var _0x421066=_0x49f003['a']['Now']-this['_lastInteractionTime'],_0x256d8c=0.5*Math['PI']-this['_defaultElevation'],_0xc94b68=0.5*Math['PI'];if(this['_attachedCamera']&&!this['_betaIsAnimating']&&this['_attachedCamera']['beta']>_0xc94b68&&_0x421066>=this['_elevationReturnWaitTime']){this['_betaIsAnimating']=!0x0,this['stopAllAnimations'](),this['_betaTransition']||(this['_betaTransition']=_0x1b0498['CreateAnimation']('beta',_0x1b0498['ANIMATIONTYPE_FLOAT'],0x3c,_0x108684['EasingFunction']));var _0x514bf8=_0x1b0498['TransitionTo']('beta',_0x256d8c,this['_attachedCamera'],this['_attachedCamera']['getScene'](),0x3c,this['_betaTransition'],this['_elevationReturnTime'],function(){_0x3ca5bf['_clearAnimationLocks'](),_0x3ca5bf['stopAllAnimations']();});_0x514bf8&&this['_animatables']['push'](_0x514bf8);}}},_0x108684['prototype']['_getFrustumSlope']=function(){var _0x59e9a8=this['_attachedCamera'];if(!_0x59e9a8)return _0x74d525['d']['Zero']();var _0x14e270=_0x59e9a8['getScene']()['getEngine']()['getAspectRatio'](_0x59e9a8),_0x2cbf5e=Math['tan'](_0x59e9a8['fov']/0x2),_0x5c7c43=_0x2cbf5e*_0x14e270;return new _0x74d525['d'](_0x5c7c43,_0x2cbf5e);},_0x108684['prototype']['_clearAnimationLocks']=function(){this['_betaIsAnimating']=!0x1;},_0x108684['prototype']['_applyUserInteraction']=function(){this['isUserIsMoving']&&(this['_lastInteractionTime']=_0x49f003['a']['Now'],this['stopAllAnimations'](),this['_clearAnimationLocks']());},_0x108684['prototype']['stopAllAnimations']=function(){for(this['_attachedCamera']&&(this['_attachedCamera']['animations']=[]);this['_animatables']['length'];)this['_animatables'][0x0]&&(this['_animatables'][0x0]['onAnimationEnd']=null,this['_animatables'][0x0]['stop']()),this['_animatables']['shift']();},Object['defineProperty'](_0x108684['prototype'],'isUserIsMoving',{'get':function(){return!!this['_attachedCamera']&&(0x0!==this['_attachedCamera']['inertialAlphaOffset']||0x0!==this['_attachedCamera']['inertialBetaOffset']||0x0!==this['_attachedCamera']['inertialRadiusOffset']||0x0!==this['_attachedCamera']['inertialPanningX']||0x0!==this['_attachedCamera']['inertialPanningY']||this['_isPointerDown']);},'enumerable':!0x1,'configurable':!0x0}),_0x108684['EasingFunction']=new _0x5d36b0(),_0x108684['EasingMode']=_0x4ba918['EASINGMODE_EASEINOUT'],_0x108684['IgnoreBoundsSizeMode']=0x0,_0x108684['FitFrustumSidesMode']=0x1,_0x108684;}()),_0x332bc8=function(_0x48c21a,_0x3cfee1,_0x49b680,_0x1fbca9){void 0x0===_0x3cfee1&&(_0x3cfee1=new _0x74d525['e']()),void 0x0===_0x49b680&&(_0x49b680=0x0),void 0x0===_0x1fbca9&&(_0x1fbca9=!0x1),this['direction']=_0x48c21a,this['rotatedDirection']=_0x3cfee1,this['diff']=_0x49b680,this['ignore']=_0x1fbca9;},_0x202ace=(function(){function _0x59fe17(_0x23e589){this['ui']=_0x23e589,this['name']='AttachToBoxBehavior',this['distanceAwayFromFace']=0.15,this['distanceAwayFromBottomOfFace']=0.15,this['_faceVectors']=[new _0x332bc8(_0x74d525['e']['Up']()),new _0x332bc8(_0x74d525['e']['Down']()),new _0x332bc8(_0x74d525['e']['Left']()),new _0x332bc8(_0x74d525['e']['Right']()),new _0x332bc8(_0x74d525['e']['Forward']()),new _0x332bc8(_0x74d525['e']['Forward']()['scaleInPlace'](-0x1))],this['_tmpMatrix']=new _0x74d525['a'](),this['_tmpVector']=new _0x74d525['e'](),this['_zeroVector']=_0x74d525['e']['Zero'](),this['_lookAtTmpMatrix']=new _0x74d525['a']();}return _0x59fe17['prototype']['init']=function(){},_0x59fe17['prototype']['_closestFace']=function(_0x300b93){var _0x147b33=this;return this['_faceVectors']['forEach'](function(_0x5df5db){_0x147b33['_target']['rotationQuaternion']||(_0x147b33['_target']['rotationQuaternion']=_0x74d525['b']['RotationYawPitchRoll'](_0x147b33['_target']['rotation']['y'],_0x147b33['_target']['rotation']['x'],_0x147b33['_target']['rotation']['z'])),_0x147b33['_target']['rotationQuaternion']['toRotationMatrix'](_0x147b33['_tmpMatrix']),_0x74d525['e']['TransformCoordinatesToRef'](_0x5df5db['direction'],_0x147b33['_tmpMatrix'],_0x5df5db['rotatedDirection']),_0x5df5db['diff']=_0x74d525['e']['GetAngleBetweenVectors'](_0x5df5db['rotatedDirection'],_0x300b93,_0x74d525['e']['Cross'](_0x5df5db['rotatedDirection'],_0x300b93));}),this['_faceVectors']['reduce'](function(_0x1bfb3e,_0x33bb3d){return _0x1bfb3e['ignore']?_0x33bb3d:_0x33bb3d['ignore']||_0x1bfb3e['diff']<_0x33bb3d['diff']?_0x1bfb3e:_0x33bb3d;},this['_faceVectors'][0x0]);},_0x59fe17['prototype']['_lookAtToRef']=function(_0x3cde6c,_0x1288a1,_0x5684b7){void 0x0===_0x1288a1&&(_0x1288a1=new _0x74d525['e'](0x0,0x1,0x0)),_0x74d525['a']['LookAtLHToRef'](this['_zeroVector'],_0x3cde6c,_0x1288a1,this['_lookAtTmpMatrix']),this['_lookAtTmpMatrix']['invert'](),_0x74d525['b']['FromRotationMatrixToRef'](this['_lookAtTmpMatrix'],_0x5684b7);},_0x59fe17['prototype']['attach']=function(_0x712405){var _0x347840=this;this['_target']=_0x712405,this['_scene']=this['_target']['getScene'](),this['_onRenderObserver']=this['_scene']['onBeforeRenderObservable']['add'](function(){if(_0x347840['_scene']['activeCamera']){var _0x2fa44c=_0x347840['_scene']['activeCamera']['position'];_0x347840['_scene']['activeCamera']['devicePosition']&&(_0x2fa44c=_0x347840['_scene']['activeCamera']['devicePosition']);var _0x3e6833=_0x347840['_closestFace'](_0x2fa44c['subtract'](_0x712405['position']));_0x347840['_scene']['activeCamera']['leftCamera']?_0x347840['_scene']['activeCamera']['leftCamera']['computeWorldMatrix']()['getRotationMatrixToRef'](_0x347840['_tmpMatrix']):_0x347840['_scene']['activeCamera']['computeWorldMatrix']()['getRotationMatrixToRef'](_0x347840['_tmpMatrix']),_0x74d525['e']['TransformCoordinatesToRef'](_0x74d525['e']['Up'](),_0x347840['_tmpMatrix'],_0x347840['_tmpVector']),_0x347840['_faceVectors']['forEach'](function(_0x182a3a){_0x3e6833['direction']['x']&&_0x182a3a['direction']['x']&&(_0x182a3a['ignore']=!0x0),_0x3e6833['direction']['y']&&_0x182a3a['direction']['y']&&(_0x182a3a['ignore']=!0x0),_0x3e6833['direction']['z']&&_0x182a3a['direction']['z']&&(_0x182a3a['ignore']=!0x0);});var _0x4d76d4=_0x347840['_closestFace'](_0x347840['_tmpVector']);_0x347840['_faceVectors']['forEach'](function(_0x486d90){_0x486d90['ignore']=!0x1;}),_0x347840['ui']['position']['copyFrom'](_0x712405['position']),_0x3e6833['direction']['x']&&(_0x3e6833['rotatedDirection']['scaleToRef'](_0x712405['scaling']['x']/0x2+_0x347840['distanceAwayFromFace'],_0x347840['_tmpVector']),_0x347840['ui']['position']['addInPlace'](_0x347840['_tmpVector'])),_0x3e6833['direction']['y']&&(_0x3e6833['rotatedDirection']['scaleToRef'](_0x712405['scaling']['y']/0x2+_0x347840['distanceAwayFromFace'],_0x347840['_tmpVector']),_0x347840['ui']['position']['addInPlace'](_0x347840['_tmpVector'])),_0x3e6833['direction']['z']&&(_0x3e6833['rotatedDirection']['scaleToRef'](_0x712405['scaling']['z']/0x2+_0x347840['distanceAwayFromFace'],_0x347840['_tmpVector']),_0x347840['ui']['position']['addInPlace'](_0x347840['_tmpVector'])),_0x347840['ui']['rotationQuaternion']||(_0x347840['ui']['rotationQuaternion']=_0x74d525['b']['RotationYawPitchRoll'](_0x347840['ui']['rotation']['y'],_0x347840['ui']['rotation']['x'],_0x347840['ui']['rotation']['z'])),_0x3e6833['rotatedDirection']['scaleToRef'](-0x1,_0x347840['_tmpVector']),_0x347840['_lookAtToRef'](_0x347840['_tmpVector'],_0x4d76d4['rotatedDirection'],_0x347840['ui']['rotationQuaternion']),_0x4d76d4['direction']['x']&&_0x347840['ui']['up']['scaleToRef'](_0x347840['distanceAwayFromBottomOfFace']-_0x712405['scaling']['x']/0x2,_0x347840['_tmpVector']),_0x4d76d4['direction']['y']&&_0x347840['ui']['up']['scaleToRef'](_0x347840['distanceAwayFromBottomOfFace']-_0x712405['scaling']['y']/0x2,_0x347840['_tmpVector']),_0x4d76d4['direction']['z']&&_0x347840['ui']['up']['scaleToRef'](_0x347840['distanceAwayFromBottomOfFace']-_0x712405['scaling']['z']/0x2,_0x347840['_tmpVector']),_0x347840['ui']['position']['addInPlace'](_0x347840['_tmpVector']);}});},_0x59fe17['prototype']['detach']=function(){this['_scene']['onBeforeRenderObservable']['remove'](this['_onRenderObserver']);},_0x59fe17;}()),_0x264a18=(function(){function _0x5f2d22(){var _0x1a5ba0=this;this['delay']=0x0,this['fadeInTime']=0x12c,this['_millisecondsPerFrame']=0x3e8/0x3c,this['_hovered']=!0x1,this['_hoverValue']=0x0,this['_ownerNode']=null,this['_update']=function(){if(_0x1a5ba0['_ownerNode']){if(_0x1a5ba0['_hoverValue']+=_0x1a5ba0['_hovered']?_0x1a5ba0['_millisecondsPerFrame']:-_0x1a5ba0['_millisecondsPerFrame'],_0x1a5ba0['_setAllVisibility'](_0x1a5ba0['_ownerNode'],(_0x1a5ba0['_hoverValue']-_0x1a5ba0['delay'])/_0x1a5ba0['fadeInTime']),_0x1a5ba0['_ownerNode']['visibility']>0x1)return _0x1a5ba0['_setAllVisibility'](_0x1a5ba0['_ownerNode'],0x1),void(_0x1a5ba0['_hoverValue']=_0x1a5ba0['fadeInTime']+_0x1a5ba0['delay']);if(_0x1a5ba0['_ownerNode']['visibility']<0x0&&(_0x1a5ba0['_setAllVisibility'](_0x1a5ba0['_ownerNode'],0x0),_0x1a5ba0['_hoverValue']<0x0))return void(_0x1a5ba0['_hoverValue']=0x0);setTimeout(_0x1a5ba0['_update'],_0x1a5ba0['_millisecondsPerFrame']);}};}return Object['defineProperty'](_0x5f2d22['prototype'],'name',{'get':function(){return'FadeInOut';},'enumerable':!0x1,'configurable':!0x0}),_0x5f2d22['prototype']['init']=function(){},_0x5f2d22['prototype']['attach']=function(_0x29ef80){this['_ownerNode']=_0x29ef80,this['_setAllVisibility'](this['_ownerNode'],0x0);},_0x5f2d22['prototype']['detach']=function(){this['_ownerNode']=null;},_0x5f2d22['prototype']['fadeIn']=function(_0x6bcf6a){this['_hovered']=_0x6bcf6a,this['_update']();},_0x5f2d22['prototype']['_setAllVisibility']=function(_0x47e07e,_0x4e9221){var _0x32bd57=this;_0x47e07e['visibility']=_0x4e9221,_0x47e07e['getChildMeshes']()['forEach'](function(_0x31a60a){_0x32bd57['_setAllVisibility'](_0x31a60a,_0x4e9221);});},_0x5f2d22;}()),_0x356c6d=_0x162675(0x41),_0x3c3fa9=(function(){function _0x36a61a(){this['_startDistance']=0x0,this['_initialScale']=new _0x74d525['e'](0x0,0x0,0x0),this['_targetScale']=new _0x74d525['e'](0x0,0x0,0x0),this['_sceneRenderObserver']=null,this['_dragBehaviorA']=new _0x356c6d['a']({}),this['_dragBehaviorA']['moveAttached']=!0x1,this['_dragBehaviorB']=new _0x356c6d['a']({}),this['_dragBehaviorB']['moveAttached']=!0x1;}return Object['defineProperty'](_0x36a61a['prototype'],'name',{'get':function(){return'MultiPointerScale';},'enumerable':!0x1,'configurable':!0x0}),_0x36a61a['prototype']['init']=function(){},_0x36a61a['prototype']['_getCurrentDistance']=function(){return this['_dragBehaviorA']['lastDragPosition']['subtract'](this['_dragBehaviorB']['lastDragPosition'])['length']();},_0x36a61a['prototype']['attach']=function(_0x5a12b0){var _0x35414f=this;this['_ownerNode']=_0x5a12b0,this['_dragBehaviorA']['onDragStartObservable']['add'](function(_0x2413a7){_0x35414f['_dragBehaviorA']['dragging']&&_0x35414f['_dragBehaviorB']['dragging']&&(_0x35414f['_dragBehaviorA']['currentDraggingPointerID']==_0x35414f['_dragBehaviorB']['currentDraggingPointerID']?_0x35414f['_dragBehaviorA']['releaseDrag']():(_0x35414f['_initialScale']['copyFrom'](_0x5a12b0['scaling']),_0x35414f['_startDistance']=_0x35414f['_getCurrentDistance']()));}),this['_dragBehaviorB']['onDragStartObservable']['add'](function(_0x519d7d){_0x35414f['_dragBehaviorA']['dragging']&&_0x35414f['_dragBehaviorB']['dragging']&&(_0x35414f['_dragBehaviorA']['currentDraggingPointerID']==_0x35414f['_dragBehaviorB']['currentDraggingPointerID']?_0x35414f['_dragBehaviorB']['releaseDrag']():(_0x35414f['_initialScale']['copyFrom'](_0x5a12b0['scaling']),_0x35414f['_startDistance']=_0x35414f['_getCurrentDistance']()));}),[this['_dragBehaviorA'],this['_dragBehaviorB']]['forEach'](function(_0x4fef1c){_0x4fef1c['onDragObservable']['add'](function(){if(_0x35414f['_dragBehaviorA']['dragging']&&_0x35414f['_dragBehaviorB']['dragging']){var _0x4b358c=_0x35414f['_getCurrentDistance']()/_0x35414f['_startDistance'];_0x35414f['_initialScale']['scaleToRef'](_0x4b358c,_0x35414f['_targetScale']);}});}),_0x5a12b0['addBehavior'](this['_dragBehaviorA']),_0x5a12b0['addBehavior'](this['_dragBehaviorB']),this['_sceneRenderObserver']=_0x5a12b0['getScene']()['onBeforeRenderObservable']['add'](function(){if(_0x35414f['_dragBehaviorA']['dragging']&&_0x35414f['_dragBehaviorB']['dragging']){var _0x2963be=_0x35414f['_targetScale']['subtract'](_0x5a12b0['scaling'])['scaleInPlace'](0.1);_0x2963be['length']()>0.01&&_0x5a12b0['scaling']['addInPlace'](_0x2963be);}});},_0x36a61a['prototype']['detach']=function(){var _0x4b0e6e=this;this['_ownerNode']['getScene']()['onBeforeRenderObservable']['remove'](this['_sceneRenderObserver']),[this['_dragBehaviorA'],this['_dragBehaviorB']]['forEach'](function(_0xb0116d){_0xb0116d['onDragStartObservable']['clear'](),_0xb0116d['onDragObservable']['clear'](),_0x4b0e6e['_ownerNode']['removeBehavior'](_0xb0116d);});},_0x36a61a;}()),_0x40d22e=_0x162675(0x1f),_0x568729=_0x162675(0x18),_0x45da14=_0x162675(0x3c),_0x2f1fdc=(function(){function _0x485322(){this['_sceneRenderObserver']=null,this['_targetPosition']=new _0x74d525['e'](0x0,0x0,0x0),this['_moving']=!0x1,this['_startingOrientation']=new _0x74d525['b'](),this['_attachedToElement']=!0x1,this['zDragFactor']=0x3,this['rotateDraggedObject']=!0x0,this['dragging']=!0x1,this['dragDeltaRatio']=0.2,this['currentDraggingPointerID']=-0x1,this['detachCameraControls']=!0x0,this['onDragStartObservable']=new _0x6ac1f7['c'](),this['onDragObservable']=new _0x6ac1f7['c'](),this['onDragEndObservable']=new _0x6ac1f7['c']();}return Object['defineProperty'](_0x485322['prototype'],'name',{'get':function(){return'SixDofDrag';},'enumerable':!0x1,'configurable':!0x0}),_0x485322['prototype']['init']=function(){},Object['defineProperty'](_0x485322['prototype'],'_pointerCamera',{'get':function(){return this['_scene']['cameraToUseForPointers']?this['_scene']['cameraToUseForPointers']:this['_scene']['activeCamera'];},'enumerable':!0x1,'configurable':!0x0}),_0x485322['prototype']['attach']=function(_0x4aa557){var _0x1ca6b2=this;this['_ownerNode']=_0x4aa557,this['_scene']=this['_ownerNode']['getScene'](),_0x485322['_virtualScene']||(_0x485322['_virtualScene']=new _0x59370b['a'](this['_scene']['getEngine'](),{'virtual':!0x0}),_0x485322['_virtualScene']['detachControl'](),this['_scene']['getEngine']()['scenes']['pop']());var _0x37405a=null,_0x14de5a=new _0x74d525['e'](0x0,0x0,0x0);this['_virtualOriginMesh']=new _0x40d22e['a']('',_0x485322['_virtualScene']),this['_virtualOriginMesh']['rotationQuaternion']=new _0x74d525['b'](),this['_virtualDragMesh']=new _0x40d22e['a']('',_0x485322['_virtualScene']),this['_virtualDragMesh']['rotationQuaternion']=new _0x74d525['b'](),this['_pointerObserver']=this['_scene']['onPointerObservable']['add'](function(_0x531469,_0x1c8f60){if(_0x531469['type']==_0x1cb628['a']['POINTERDOWN']){if(!_0x1ca6b2['dragging']&&_0x531469['pickInfo']&&_0x531469['pickInfo']['hit']&&_0x531469['pickInfo']['pickedMesh']&&_0x531469['pickInfo']['ray']&&(_0x501825=_0x531469['pickInfo']['pickedMesh'],_0x1ca6b2['_ownerNode']==_0x501825||_0x501825['isDescendantOf'](_0x1ca6b2['_ownerNode']))){_0x1ca6b2['_pointerCamera']&&_0x1ca6b2['_pointerCamera']['cameraRigMode']==_0x568729['a']['RIG_MODE_NONE']&&_0x531469['pickInfo']['ray']['origin']['copyFrom'](_0x1ca6b2['_pointerCamera']['globalPosition']),_0x37405a=_0x1ca6b2['_ownerNode'],_0x45da14['a']['_RemoveAndStorePivotPoint'](_0x37405a),_0x14de5a['copyFrom'](_0x531469['pickInfo']['ray']['origin']),_0x1ca6b2['_virtualOriginMesh']['position']['copyFrom'](_0x531469['pickInfo']['ray']['origin']),_0x1ca6b2['_virtualOriginMesh']['lookAt'](_0x531469['pickInfo']['ray']['origin']['add'](_0x531469['pickInfo']['ray']['direction'])),_0x1ca6b2['_virtualOriginMesh']['removeChild'](_0x1ca6b2['_virtualDragMesh']),_0x37405a['computeWorldMatrix'](),_0x1ca6b2['_virtualDragMesh']['position']['copyFrom'](_0x37405a['absolutePosition']),_0x37405a['rotationQuaternion']||(_0x37405a['rotationQuaternion']=_0x74d525['b']['RotationYawPitchRoll'](_0x37405a['rotation']['y'],_0x37405a['rotation']['x'],_0x37405a['rotation']['z']));var _0x2b6f5d=_0x37405a['parent'];_0x37405a['setParent'](null),_0x1ca6b2['_virtualDragMesh']['rotationQuaternion']['copyFrom'](_0x37405a['rotationQuaternion']),_0x37405a['setParent'](_0x2b6f5d),_0x1ca6b2['_virtualOriginMesh']['addChild'](_0x1ca6b2['_virtualDragMesh']),_0x1ca6b2['_targetPosition']['copyFrom'](_0x1ca6b2['_virtualDragMesh']['absolutePosition']),_0x1ca6b2['dragging']=!0x0,_0x1ca6b2['currentDraggingPointerID']=_0x531469['event']['pointerId'],_0x1ca6b2['detachCameraControls']&&_0x1ca6b2['_pointerCamera']&&!_0x1ca6b2['_pointerCamera']['leftCamera']&&(_0x1ca6b2['_pointerCamera']['inputs']['attachedToElement']?(_0x1ca6b2['_pointerCamera']['detachControl'](),_0x1ca6b2['_attachedToElement']=!0x0):_0x1ca6b2['_attachedToElement']=!0x1),_0x45da14['a']['_RestorePivotPoint'](_0x37405a),_0x1ca6b2['onDragStartObservable']['notifyObservers']({});}}else{if(_0x531469['type']==_0x1cb628['a']['POINTERUP']||_0x531469['type']==_0x1cb628['a']['POINTERDOUBLETAP'])_0x1ca6b2['currentDraggingPointerID']==_0x531469['event']['pointerId']&&(_0x1ca6b2['dragging']=!0x1,_0x1ca6b2['_moving']=!0x1,_0x1ca6b2['currentDraggingPointerID']=-0x1,_0x37405a=null,_0x1ca6b2['_virtualOriginMesh']['removeChild'](_0x1ca6b2['_virtualDragMesh']),_0x1ca6b2['detachCameraControls']&&_0x1ca6b2['_attachedToElement']&&_0x1ca6b2['_pointerCamera']&&!_0x1ca6b2['_pointerCamera']['leftCamera']&&(_0x1ca6b2['_pointerCamera']['attachControl'](!0x0),_0x1ca6b2['_attachedToElement']=!0x1),_0x1ca6b2['onDragEndObservable']['notifyObservers']({}));else{if(_0x531469['type']==_0x1cb628['a']['POINTERMOVE']&&_0x1ca6b2['currentDraggingPointerID']==_0x531469['event']['pointerId']&&_0x1ca6b2['dragging']&&_0x531469['pickInfo']&&_0x531469['pickInfo']['ray']&&_0x37405a){var _0x4adf15=_0x1ca6b2['zDragFactor'];_0x1ca6b2['_pointerCamera']&&_0x1ca6b2['_pointerCamera']['cameraRigMode']==_0x568729['a']['RIG_MODE_NONE']&&(_0x531469['pickInfo']['ray']['origin']['copyFrom'](_0x1ca6b2['_pointerCamera']['globalPosition']),_0x4adf15=0x0);var _0x2409e8=_0x531469['pickInfo']['ray']['origin']['subtract'](_0x14de5a);_0x14de5a['copyFrom'](_0x531469['pickInfo']['ray']['origin']);var _0x8cf2f0=-_0x74d525['e']['Dot'](_0x2409e8,_0x531469['pickInfo']['ray']['direction']);_0x1ca6b2['_virtualOriginMesh']['addChild'](_0x1ca6b2['_virtualDragMesh']),_0x1ca6b2['_virtualDragMesh']['position']['z']-=_0x1ca6b2['_virtualDragMesh']['position']['z']<0x1?_0x8cf2f0*_0x1ca6b2['zDragFactor']:_0x8cf2f0*_0x4adf15*_0x1ca6b2['_virtualDragMesh']['position']['z'],_0x1ca6b2['_virtualDragMesh']['position']['z']<0x0&&(_0x1ca6b2['_virtualDragMesh']['position']['z']=0x0),_0x1ca6b2['_virtualOriginMesh']['position']['copyFrom'](_0x531469['pickInfo']['ray']['origin']),_0x1ca6b2['_virtualOriginMesh']['lookAt'](_0x531469['pickInfo']['ray']['origin']['add'](_0x531469['pickInfo']['ray']['direction'])),_0x1ca6b2['_virtualOriginMesh']['removeChild'](_0x1ca6b2['_virtualDragMesh']),_0x1ca6b2['_targetPosition']['copyFrom'](_0x1ca6b2['_virtualDragMesh']['absolutePosition']),_0x37405a['parent']&&_0x74d525['e']['TransformCoordinatesToRef'](_0x1ca6b2['_targetPosition'],_0x74d525['a']['Invert'](_0x37405a['parent']['getWorldMatrix']()),_0x1ca6b2['_targetPosition']),_0x1ca6b2['_moving']||_0x1ca6b2['_startingOrientation']['copyFrom'](_0x1ca6b2['_virtualDragMesh']['rotationQuaternion']),_0x1ca6b2['_moving']=!0x0;}}}var _0x501825;});var _0x505b28=new _0x74d525['b']();this['_sceneRenderObserver']=_0x4aa557['getScene']()['onBeforeRenderObservable']['add'](function(){if(_0x1ca6b2['dragging']&&_0x1ca6b2['_moving']&&_0x37405a){if(_0x45da14['a']['_RemoveAndStorePivotPoint'](_0x37405a),_0x37405a['position']['addInPlace'](_0x1ca6b2['_targetPosition']['subtract'](_0x37405a['position'])['scale'](_0x1ca6b2['dragDeltaRatio'])),_0x1ca6b2['rotateDraggedObject']){_0x505b28['copyFrom'](_0x1ca6b2['_startingOrientation']),_0x505b28['x']=-_0x505b28['x'],_0x505b28['y']=-_0x505b28['y'],_0x505b28['z']=-_0x505b28['z'],_0x1ca6b2['_virtualDragMesh']['rotationQuaternion']['multiplyToRef'](_0x505b28,_0x505b28),_0x74d525['b']['RotationYawPitchRollToRef'](_0x505b28['toEulerAngles']('xyz')['y'],0x0,0x0,_0x505b28),_0x505b28['multiplyToRef'](_0x1ca6b2['_startingOrientation'],_0x505b28);var _0x23fe36=_0x37405a['parent'];(!_0x23fe36||_0x23fe36['scaling']&&!_0x23fe36['scaling']['isNonUniformWithinEpsilon'](0.001))&&(_0x37405a['setParent'](null),_0x74d525['b']['SlerpToRef'](_0x37405a['rotationQuaternion'],_0x505b28,_0x1ca6b2['dragDeltaRatio'],_0x37405a['rotationQuaternion']),_0x37405a['setParent'](_0x23fe36));}_0x45da14['a']['_RestorePivotPoint'](_0x37405a),_0x1ca6b2['onDragObservable']['notifyObservers']();}});},_0x485322['prototype']['detach']=function(){this['_scene']&&(this['detachCameraControls']&&this['_attachedToElement']&&this['_pointerCamera']&&!this['_pointerCamera']['leftCamera']&&(this['_pointerCamera']['attachControl'](!0x0),this['_attachedToElement']=!0x1),this['_scene']['onPointerObservable']['remove'](this['_pointerObserver'])),this['_ownerNode']&&this['_ownerNode']['getScene']()['onBeforeRenderObservable']['remove'](this['_sceneRenderObserver']),this['_virtualOriginMesh']&&this['_virtualOriginMesh']['dispose'](),this['_virtualDragMesh']&&this['_virtualDragMesh']['dispose'](),this['onDragEndObservable']['clear'](),this['onDragObservable']['clear'](),this['onDragStartObservable']['clear']();},_0x485322;}()),_0x2d9be4=(function(){function _0xf96fc6(_0x20dac6,_0x1a2b16,_0x54f75e){if(this['targetPosition']=_0x74d525['e']['Zero'](),this['poleTargetPosition']=_0x74d525['e']['Zero'](),this['poleTargetLocalOffset']=_0x74d525['e']['Zero'](),this['poleAngle']=0x0,this['slerpAmount']=0x1,this['_bone1Quat']=_0x74d525['b']['Identity'](),this['_bone1Mat']=_0x74d525['a']['Identity'](),this['_bone2Ang']=Math['PI'],this['_maxAngle']=Math['PI'],this['_rightHandedSystem']=!0x1,this['_bendAxis']=_0x74d525['e']['Right'](),this['_slerping']=!0x1,this['_adjustRoll']=0x0,this['_bone2']=_0x1a2b16,this['_bone1']=_0x1a2b16['getParent'](),this['_bone1']){this['mesh']=_0x20dac6;var _0x932516=_0x1a2b16['getPosition']();if(_0x1a2b16['getAbsoluteTransform']()['determinant']()>0x0&&(this['_rightHandedSystem']=!0x0,this['_bendAxis']['x']=0x0,this['_bendAxis']['y']=0x0,this['_bendAxis']['z']=-0x1,_0x932516['x']>_0x932516['y']&&_0x932516['x']>_0x932516['z']&&(this['_adjustRoll']=0.5*Math['PI'],this['_bendAxis']['z']=0x1)),this['_bone1']['length']){var _0x1f64eb=this['_bone1']['getScale'](),_0x59599f=this['_bone2']['getScale']();this['_bone1Length']=this['_bone1']['length']*_0x1f64eb['y']*this['mesh']['scaling']['y'],this['_bone2Length']=this['_bone2']['length']*_0x59599f['y']*this['mesh']['scaling']['y'];}else{if(this['_bone1']['children'][0x0]){_0x20dac6['computeWorldMatrix'](!0x0);var _0x3e1960=this['_bone2']['children'][0x0]['getAbsolutePosition'](_0x20dac6),_0x51f5e8=this['_bone2']['getAbsolutePosition'](_0x20dac6),_0x3449b7=this['_bone1']['getAbsolutePosition'](_0x20dac6);this['_bone1Length']=_0x74d525['e']['Distance'](_0x3e1960,_0x51f5e8),this['_bone2Length']=_0x74d525['e']['Distance'](_0x51f5e8,_0x3449b7);}}this['_bone1']['getRotationMatrixToRef'](_0x4a79a2['c']['WORLD'],_0x20dac6,this['_bone1Mat']),this['maxAngle']=Math['PI'],_0x54f75e&&(_0x54f75e['targetMesh']&&(this['targetMesh']=_0x54f75e['targetMesh'],this['targetMesh']['computeWorldMatrix'](!0x0)),_0x54f75e['poleTargetMesh']?(this['poleTargetMesh']=_0x54f75e['poleTargetMesh'],this['poleTargetMesh']['computeWorldMatrix'](!0x0)):_0x54f75e['poleTargetBone']?this['poleTargetBone']=_0x54f75e['poleTargetBone']:this['_bone1']['getParent']()&&(this['poleTargetBone']=this['_bone1']['getParent']()),_0x54f75e['poleTargetLocalOffset']&&this['poleTargetLocalOffset']['copyFrom'](_0x54f75e['poleTargetLocalOffset']),_0x54f75e['poleAngle']&&(this['poleAngle']=_0x54f75e['poleAngle']),_0x54f75e['bendAxis']&&this['_bendAxis']['copyFrom'](_0x54f75e['bendAxis']),_0x54f75e['maxAngle']&&(this['maxAngle']=_0x54f75e['maxAngle']),_0x54f75e['slerpAmount']&&(this['slerpAmount']=_0x54f75e['slerpAmount']));}}return Object['defineProperty'](_0xf96fc6['prototype'],'maxAngle',{'get':function(){return this['_maxAngle'];},'set':function(_0x919005){this['_setMaxAngle'](_0x919005);},'enumerable':!0x1,'configurable':!0x0}),_0xf96fc6['prototype']['_setMaxAngle']=function(_0x26e871){_0x26e871<0x0&&(_0x26e871=0x0),(_0x26e871>Math['PI']||null==_0x26e871)&&(_0x26e871=Math['PI']),this['_maxAngle']=_0x26e871;var _0x2ea259=this['_bone1Length'],_0x1723d6=this['_bone2Length'];this['_maxReach']=Math['sqrt'](_0x2ea259*_0x2ea259+_0x1723d6*_0x1723d6-0x2*_0x2ea259*_0x1723d6*Math['cos'](_0x26e871));},_0xf96fc6['prototype']['update']=function(){var _0x5c0f6e=this['_bone1'];if(_0x5c0f6e){var _0x39386a=this['targetPosition'],_0x4f247d=this['poleTargetPosition'],_0x210e0c=_0xf96fc6['_tmpMats'][0x0],_0x2df711=_0xf96fc6['_tmpMats'][0x1];this['targetMesh']&&_0x39386a['copyFrom'](this['targetMesh']['getAbsolutePosition']()),this['poleTargetBone']?this['poleTargetBone']['getAbsolutePositionFromLocalToRef'](this['poleTargetLocalOffset'],this['mesh'],_0x4f247d):this['poleTargetMesh']&&_0x74d525['e']['TransformCoordinatesToRef'](this['poleTargetLocalOffset'],this['poleTargetMesh']['getWorldMatrix'](),_0x4f247d);var _0x526b8f=_0xf96fc6['_tmpVecs'][0x0],_0x20e7c3=_0xf96fc6['_tmpVecs'][0x1],_0x15e984=_0xf96fc6['_tmpVecs'][0x2],_0x5b4fd0=_0xf96fc6['_tmpVecs'][0x3],_0x1d9955=_0xf96fc6['_tmpVecs'][0x4],_0x18a0e7=_0xf96fc6['_tmpQuat'];_0x5c0f6e['getAbsolutePositionToRef'](this['mesh'],_0x526b8f),_0x4f247d['subtractToRef'](_0x526b8f,_0x1d9955),0x0==_0x1d9955['x']&&0x0==_0x1d9955['y']&&0x0==_0x1d9955['z']?_0x1d9955['y']=0x1:_0x1d9955['normalize'](),_0x39386a['subtractToRef'](_0x526b8f,_0x5b4fd0),_0x5b4fd0['normalize'](),_0x74d525['e']['CrossToRef'](_0x5b4fd0,_0x1d9955,_0x20e7c3),_0x20e7c3['normalize'](),_0x74d525['e']['CrossToRef'](_0x5b4fd0,_0x20e7c3,_0x15e984),_0x15e984['normalize'](),_0x74d525['a']['FromXYZAxesToRef'](_0x15e984,_0x5b4fd0,_0x20e7c3,_0x210e0c);var _0x3b6a7e=this['_bone1Length'],_0x54534f=this['_bone2Length'],_0x5129db=_0x74d525['e']['Distance'](_0x526b8f,_0x39386a);this['_maxReach']>0x0&&(_0x5129db=Math['min'](this['_maxReach'],_0x5129db));var _0x5aa26e=(_0x54534f*_0x54534f+_0x5129db*_0x5129db-_0x3b6a7e*_0x3b6a7e)/(0x2*_0x54534f*_0x5129db),_0x5620ce=(_0x5129db*_0x5129db+_0x3b6a7e*_0x3b6a7e-_0x54534f*_0x54534f)/(0x2*_0x5129db*_0x3b6a7e);_0x5aa26e>0x1&&(_0x5aa26e=0x1),_0x5620ce>0x1&&(_0x5620ce=0x1),_0x5aa26e<-0x1&&(_0x5aa26e=-0x1),_0x5620ce<-0x1&&(_0x5620ce=-0x1);var _0xa9d666=Math['acos'](_0x5aa26e),_0x5da252=Math['acos'](_0x5620ce),_0x2b2458=-_0xa9d666-_0x5da252;if(this['_rightHandedSystem'])_0x74d525['a']['RotationYawPitchRollToRef'](0x0,0x0,this['_adjustRoll'],_0x2df711),_0x2df711['multiplyToRef'](_0x210e0c,_0x210e0c),_0x74d525['a']['RotationAxisToRef'](this['_bendAxis'],_0x5da252,_0x2df711),_0x2df711['multiplyToRef'](_0x210e0c,_0x210e0c);else{var _0x2e1715=_0xf96fc6['_tmpVecs'][0x5];_0x2e1715['copyFrom'](this['_bendAxis']),_0x2e1715['x']*=-0x1,_0x74d525['a']['RotationAxisToRef'](_0x2e1715,-_0x5da252,_0x2df711),_0x2df711['multiplyToRef'](_0x210e0c,_0x210e0c);}this['poleAngle']&&(_0x74d525['a']['RotationAxisToRef'](_0x5b4fd0,this['poleAngle'],_0x2df711),_0x210e0c['multiplyToRef'](_0x2df711,_0x210e0c)),this['_bone1']&&(this['slerpAmount']<0x1?(this['_slerping']||_0x74d525['b']['FromRotationMatrixToRef'](this['_bone1Mat'],this['_bone1Quat']),_0x74d525['b']['FromRotationMatrixToRef'](_0x210e0c,_0x18a0e7),_0x74d525['b']['SlerpToRef'](this['_bone1Quat'],_0x18a0e7,this['slerpAmount'],this['_bone1Quat']),_0x2b2458=this['_bone2Ang']*(0x1-this['slerpAmount'])+_0x2b2458*this['slerpAmount'],this['_bone1']['setRotationQuaternion'](this['_bone1Quat'],_0x4a79a2['c']['WORLD'],this['mesh']),this['_slerping']=!0x0):(this['_bone1']['setRotationMatrix'](_0x210e0c,_0x4a79a2['c']['WORLD'],this['mesh']),this['_bone1Mat']['copyFrom'](_0x210e0c),this['_slerping']=!0x1)),this['_bone2']['setAxisAngle'](this['_bendAxis'],_0x2b2458,_0x4a79a2['c']['LOCAL']),this['_bone2Ang']=_0x2b2458;}},_0xf96fc6['_tmpVecs']=[_0x74d525['e']['Zero'](),_0x74d525['e']['Zero'](),_0x74d525['e']['Zero'](),_0x74d525['e']['Zero'](),_0x74d525['e']['Zero'](),_0x74d525['e']['Zero']()],_0xf96fc6['_tmpQuat']=_0x74d525['b']['Identity'](),_0xf96fc6['_tmpMats']=[_0x74d525['a']['Identity'](),_0x74d525['a']['Identity']()],_0xf96fc6;}()),_0xdce04c=(function(){function _0x9f1d28(_0x1bdfc5,_0x1839e4,_0x83fabf,_0x27acf6){if(this['upAxis']=_0x74d525['e']['Up'](),this['upAxisSpace']=_0x4a79a2['c']['LOCAL'],this['adjustYaw']=0x0,this['adjustPitch']=0x0,this['adjustRoll']=0x0,this['slerpAmount']=0x1,this['_boneQuat']=_0x74d525['b']['Identity'](),this['_slerping']=!0x1,this['_firstFrameSkipped']=!0x1,this['_fowardAxis']=_0x74d525['e']['Forward'](),this['mesh']=_0x1bdfc5,this['bone']=_0x1839e4,this['target']=_0x83fabf,_0x27acf6&&(_0x27acf6['adjustYaw']&&(this['adjustYaw']=_0x27acf6['adjustYaw']),_0x27acf6['adjustPitch']&&(this['adjustPitch']=_0x27acf6['adjustPitch']),_0x27acf6['adjustRoll']&&(this['adjustRoll']=_0x27acf6['adjustRoll']),null!=_0x27acf6['maxYaw']?this['maxYaw']=_0x27acf6['maxYaw']:this['maxYaw']=Math['PI'],null!=_0x27acf6['minYaw']?this['minYaw']=_0x27acf6['minYaw']:this['minYaw']=-Math['PI'],null!=_0x27acf6['maxPitch']?this['maxPitch']=_0x27acf6['maxPitch']:this['maxPitch']=Math['PI'],null!=_0x27acf6['minPitch']?this['minPitch']=_0x27acf6['minPitch']:this['minPitch']=-Math['PI'],null!=_0x27acf6['slerpAmount']&&(this['slerpAmount']=_0x27acf6['slerpAmount']),null!=_0x27acf6['upAxis']&&(this['upAxis']=_0x27acf6['upAxis']),null!=_0x27acf6['upAxisSpace']&&(this['upAxisSpace']=_0x27acf6['upAxisSpace']),null!=_0x27acf6['yawAxis']||null!=_0x27acf6['pitchAxis'])){var _0x17c437=_0x4a79a2['a']['Y'],_0x517426=_0x4a79a2['a']['X'];null!=_0x27acf6['yawAxis']&&(_0x17c437=_0x27acf6['yawAxis']['clone']())['normalize'](),null!=_0x27acf6['pitchAxis']&&(_0x517426=_0x27acf6['pitchAxis']['clone']())['normalize']();var _0x57ee2a=_0x74d525['e']['Cross'](_0x517426,_0x17c437);this['_transformYawPitch']=_0x74d525['a']['Identity'](),_0x74d525['a']['FromXYZAxesToRef'](_0x517426,_0x17c437,_0x57ee2a,this['_transformYawPitch']),this['_transformYawPitchInv']=this['_transformYawPitch']['clone'](),this['_transformYawPitch']['invert']();}_0x1839e4['getParent']()||this['upAxisSpace']!=_0x4a79a2['c']['BONE']||(this['upAxisSpace']=_0x4a79a2['c']['LOCAL']);}return Object['defineProperty'](_0x9f1d28['prototype'],'minYaw',{'get':function(){return this['_minYaw'];},'set':function(_0x489bc2){this['_minYaw']=_0x489bc2,this['_minYawSin']=Math['sin'](_0x489bc2),this['_minYawCos']=Math['cos'](_0x489bc2),null!=this['_maxYaw']&&(this['_midYawConstraint']=0.5*this['_getAngleDiff'](this['_minYaw'],this['_maxYaw'])+this['_minYaw'],this['_yawRange']=this['_maxYaw']-this['_minYaw']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x9f1d28['prototype'],'maxYaw',{'get':function(){return this['_maxYaw'];},'set':function(_0x501279){this['_maxYaw']=_0x501279,this['_maxYawSin']=Math['sin'](_0x501279),this['_maxYawCos']=Math['cos'](_0x501279),null!=this['_minYaw']&&(this['_midYawConstraint']=0.5*this['_getAngleDiff'](this['_minYaw'],this['_maxYaw'])+this['_minYaw'],this['_yawRange']=this['_maxYaw']-this['_minYaw']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x9f1d28['prototype'],'minPitch',{'get':function(){return this['_minPitch'];},'set':function(_0x228042){this['_minPitch']=_0x228042,this['_minPitchTan']=Math['tan'](_0x228042);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x9f1d28['prototype'],'maxPitch',{'get':function(){return this['_maxPitch'];},'set':function(_0x48d82c){this['_maxPitch']=_0x48d82c,this['_maxPitchTan']=Math['tan'](_0x48d82c);},'enumerable':!0x1,'configurable':!0x0}),_0x9f1d28['prototype']['update']=function(){if(this['slerpAmount']<0x1&&!this['_firstFrameSkipped'])this['_firstFrameSkipped']=!0x0;else{var _0x2b8fa8=this['bone'],_0x46a6ab=_0x9f1d28['_tmpVecs'][0x0];_0x2b8fa8['getAbsolutePositionToRef'](this['mesh'],_0x46a6ab);var _0x23ecd1=this['target'],_0xb72c6a=_0x9f1d28['_tmpMats'][0x0],_0x42ff78=_0x9f1d28['_tmpMats'][0x1],_0x5d098e=this['mesh'],_0x11c46d=_0x2b8fa8['getParent'](),_0x6f100e=_0x9f1d28['_tmpVecs'][0x1];_0x6f100e['copyFrom'](this['upAxis']),this['upAxisSpace']==_0x4a79a2['c']['BONE']&&_0x11c46d?(this['_transformYawPitch']&&_0x74d525['e']['TransformCoordinatesToRef'](_0x6f100e,this['_transformYawPitchInv'],_0x6f100e),_0x11c46d['getDirectionToRef'](_0x6f100e,this['mesh'],_0x6f100e)):this['upAxisSpace']==_0x4a79a2['c']['LOCAL']&&(_0x5d098e['getDirectionToRef'](_0x6f100e,_0x6f100e),0x1==_0x5d098e['scaling']['x']&&0x1==_0x5d098e['scaling']['y']&&0x1==_0x5d098e['scaling']['z']||_0x6f100e['normalize']());var _0x8b3a39=!0x1,_0x5565dd=!0x1;if(this['_maxYaw']==Math['PI']&&this['_minYaw']==-Math['PI']||(_0x8b3a39=!0x0),this['_maxPitch']==Math['PI']&&this['_minPitch']==-Math['PI']||(_0x5565dd=!0x0),_0x8b3a39||_0x5565dd){var _0xe6e8da=_0x9f1d28['_tmpMats'][0x2],_0x1f830b=_0x9f1d28['_tmpMats'][0x3];if(this['upAxisSpace']==_0x4a79a2['c']['BONE']&&0x1==_0x6f100e['y']&&_0x11c46d)_0x11c46d['getRotationMatrixToRef'](_0x4a79a2['c']['WORLD'],this['mesh'],_0xe6e8da);else{if(this['upAxisSpace']!=_0x4a79a2['c']['LOCAL']||0x1!=_0x6f100e['y']||_0x11c46d){(_0x46071c=_0x9f1d28['_tmpVecs'][0x2])['copyFrom'](this['_fowardAxis']),this['_transformYawPitch']&&_0x74d525['e']['TransformCoordinatesToRef'](_0x46071c,this['_transformYawPitchInv'],_0x46071c),_0x11c46d?_0x11c46d['getDirectionToRef'](_0x46071c,this['mesh'],_0x46071c):_0x5d098e['getDirectionToRef'](_0x46071c,_0x46071c);var _0x53b9ad=_0x74d525['e']['Cross'](_0x6f100e,_0x46071c);_0x53b9ad['normalize']();var _0x46071c=_0x74d525['e']['Cross'](_0x53b9ad,_0x6f100e);_0x74d525['a']['FromXYZAxesToRef'](_0x53b9ad,_0x6f100e,_0x46071c,_0xe6e8da);}else _0xe6e8da['copyFrom'](_0x5d098e['getWorldMatrix']());}_0xe6e8da['invertToRef'](_0x1f830b);var _0xc4b299=null;if(_0x5565dd){var _0xbd3454=_0x9f1d28['_tmpVecs'][0x3];_0x23ecd1['subtractToRef'](_0x46a6ab,_0xbd3454),_0x74d525['e']['TransformCoordinatesToRef'](_0xbd3454,_0x1f830b,_0xbd3454),_0xc4b299=Math['sqrt'](_0xbd3454['x']*_0xbd3454['x']+_0xbd3454['z']*_0xbd3454['z']);var _0x1743c4=Math['atan2'](_0xbd3454['y'],_0xc4b299),_0x3a142c=_0x1743c4;_0x1743c4>this['_maxPitch']?(_0xbd3454['y']=this['_maxPitchTan']*_0xc4b299,_0x3a142c=this['_maxPitch']):_0x1743c4this['_maxYaw']||_0x573325Math['PI']?this['_isAngleBetween'](_0x573325,this['_maxYaw'],this['_midYawConstraint'])?(_0xbd3454['z']=this['_maxYawCos']*_0xc4b299,_0xbd3454['x']=this['_maxYawSin']*_0xc4b299,_0xcec9f3=this['_maxYaw']):this['_isAngleBetween'](_0x573325,this['_midYawConstraint'],this['_minYaw'])&&(_0xbd3454['z']=this['_minYawCos']*_0xc4b299,_0xbd3454['x']=this['_minYawSin']*_0xc4b299,_0xcec9f3=this['_minYaw']):_0x573325>this['_maxYaw']?(_0xbd3454['z']=this['_maxYawCos']*_0xc4b299,_0xbd3454['x']=this['_maxYawSin']*_0xc4b299,_0xcec9f3=this['_maxYaw']):_0x573325Math['PI']){var _0x261df1=_0x9f1d28['_tmpVecs'][0x8];_0x261df1['copyFrom'](_0x4a79a2['a']['Z']),this['_transformYawPitch']&&_0x74d525['e']['TransformCoordinatesToRef'](_0x261df1,this['_transformYawPitchInv'],_0x261df1);var _0x1a6ad1=_0x9f1d28['_tmpMats'][0x4];this['_boneQuat']['toRotationMatrix'](_0x1a6ad1),this['mesh']['getWorldMatrix']()['multiplyToRef'](_0x1a6ad1,_0x1a6ad1),_0x74d525['e']['TransformCoordinatesToRef'](_0x261df1,_0x1a6ad1,_0x261df1),_0x74d525['e']['TransformCoordinatesToRef'](_0x261df1,_0x1f830b,_0x261df1);var _0xc8bc9c=Math['atan2'](_0x261df1['x'],_0x261df1['z']);if(this['_getAngleBetween'](_0xc8bc9c,_0x573325)>this['_getAngleBetween'](_0xc8bc9c,this['_midYawConstraint'])){null==_0xc4b299&&(_0xc4b299=Math['sqrt'](_0xbd3454['x']*_0xbd3454['x']+_0xbd3454['z']*_0xbd3454['z']));var _0x132e2a=this['_getAngleBetween'](_0xc8bc9c,this['_maxYaw']);this['_getAngleBetween'](_0xc8bc9c,this['_minYaw'])<_0x132e2a?(_0xcec9f3=_0xc8bc9c+0.75*Math['PI'],_0xbd3454['z']=Math['cos'](_0xcec9f3)*_0xc4b299,_0xbd3454['x']=Math['sin'](_0xcec9f3)*_0xc4b299):(_0xcec9f3=_0xc8bc9c-0.75*Math['PI'],_0xbd3454['z']=Math['cos'](_0xcec9f3)*_0xc4b299,_0xbd3454['x']=Math['sin'](_0xcec9f3)*_0xc4b299);}}_0x573325!=_0xcec9f3&&(_0x74d525['e']['TransformCoordinatesToRef'](_0xbd3454,_0xe6e8da,_0xbd3454),_0xbd3454['addInPlace'](_0x46a6ab),_0x23ecd1=_0xbd3454);}}var _0x31dec4=_0x9f1d28['_tmpVecs'][0x5],_0x5848f1=_0x9f1d28['_tmpVecs'][0x6],_0x13d1ff=_0x9f1d28['_tmpVecs'][0x7],_0x35cfe1=_0x9f1d28['_tmpQuat'];_0x23ecd1['subtractToRef'](_0x46a6ab,_0x31dec4),_0x31dec4['normalize'](),_0x74d525['e']['CrossToRef'](_0x6f100e,_0x31dec4,_0x5848f1),_0x5848f1['normalize'](),_0x74d525['e']['CrossToRef'](_0x31dec4,_0x5848f1,_0x13d1ff),_0x13d1ff['normalize'](),_0x74d525['a']['FromXYZAxesToRef'](_0x5848f1,_0x13d1ff,_0x31dec4,_0xb72c6a),0x0===_0x5848f1['x']&&0x0===_0x5848f1['y']&&0x0===_0x5848f1['z']||0x0===_0x13d1ff['x']&&0x0===_0x13d1ff['y']&&0x0===_0x13d1ff['z']||0x0===_0x31dec4['x']&&0x0===_0x31dec4['y']&&0x0===_0x31dec4['z']||((this['adjustYaw']||this['adjustPitch']||this['adjustRoll'])&&(_0x74d525['a']['RotationYawPitchRollToRef'](this['adjustYaw'],this['adjustPitch'],this['adjustRoll'],_0x42ff78),_0x42ff78['multiplyToRef'](_0xb72c6a,_0xb72c6a)),this['slerpAmount']<0x1?(this['_slerping']||this['bone']['getRotationQuaternionToRef'](_0x4a79a2['c']['WORLD'],this['mesh'],this['_boneQuat']),this['_transformYawPitch']&&this['_transformYawPitch']['multiplyToRef'](_0xb72c6a,_0xb72c6a),_0x74d525['b']['FromRotationMatrixToRef'](_0xb72c6a,_0x35cfe1),_0x74d525['b']['SlerpToRef'](this['_boneQuat'],_0x35cfe1,this['slerpAmount'],this['_boneQuat']),this['bone']['setRotationQuaternion'](this['_boneQuat'],_0x4a79a2['c']['WORLD'],this['mesh']),this['_slerping']=!0x0):(this['_transformYawPitch']&&this['_transformYawPitch']['multiplyToRef'](_0xb72c6a,_0xb72c6a),this['bone']['setRotationMatrix'](_0xb72c6a,_0x4a79a2['c']['WORLD'],this['mesh']),this['_slerping']=!0x1));}},_0x9f1d28['prototype']['_getAngleDiff']=function(_0xf243b4,_0x1339cb){var _0x2f5c40=_0x1339cb-_0xf243b4;return(_0x2f5c40%=0x2*Math['PI'])>Math['PI']?_0x2f5c40-=0x2*Math['PI']:_0x2f5c40<-Math['PI']&&(_0x2f5c40+=0x2*Math['PI']),_0x2f5c40;},_0x9f1d28['prototype']['_getAngleBetween']=function(_0x279025,_0xef38de){var _0x2dd9d1=0x0;return(_0x2dd9d1=(_0x279025=(_0x279025%=0x2*Math['PI'])<0x0?_0x279025+0x2*Math['PI']:_0x279025)<(_0xef38de=(_0xef38de%=0x2*Math['PI'])<0x0?_0xef38de+0x2*Math['PI']:_0xef38de)?_0xef38de-_0x279025:_0x279025-_0xef38de)>Math['PI']&&(_0x2dd9d1=0x2*Math['PI']-_0x2dd9d1),_0x2dd9d1;},_0x9f1d28['prototype']['_isAngleBetween']=function(_0x167a75,_0x573181,_0xea0772){if(_0x167a75=(_0x167a75%=0x2*Math['PI'])<0x0?_0x167a75+0x2*Math['PI']:_0x167a75,(_0x573181=(_0x573181%=0x2*Math['PI'])<0x0?_0x573181+0x2*Math['PI']:_0x573181)<(_0xea0772=(_0xea0772%=0x2*Math['PI'])<0x0?_0xea0772+0x2*Math['PI']:_0xea0772)){if(_0x167a75>_0x573181&&_0x167a75<_0xea0772)return!0x0;}else{if(_0x167a75>_0xea0772&&_0x167a75<_0x573181)return!0x0;}return!0x1;},_0x9f1d28['_tmpVecs']=_0x429cc2['a']['BuildArray'](0xa,_0x74d525['e']['Zero']),_0x9f1d28['_tmpQuat']=_0x74d525['b']['Identity'](),_0x9f1d28['_tmpMats']=_0x429cc2['a']['BuildArray'](0x5,_0x74d525['a']['Identity']),_0x9f1d28;}()),_0xaf3c80=_0x162675(0xa),_0x21ea74=_0x162675(0x1b),_0x26966b=_0x162675(0x1a);function _0x1e87bf(_0xd57ead,_0x458269,_0x5bf3e4,_0x457a87){var _0x30cb5a;_0x30cb5a=_0x457a87===_0x2103ba['a']['TEXTURETYPE_FLOAT']?new Float32Array(_0x458269*_0x5bf3e4*0x4):new Uint32Array(_0x458269*_0x5bf3e4*0x4);for(var _0x4b0fa0=0x0;_0x4b0fa0<_0x458269;_0x4b0fa0++)for(var _0x4264c7=0x0;_0x4264c7<_0x5bf3e4;_0x4264c7++){var _0x2036ba=0x3*(_0x4264c7*_0x458269+_0x4b0fa0),_0x4eca00=0x4*(_0x4264c7*_0x458269+_0x4b0fa0);_0x30cb5a[_0x4eca00+0x0]=_0xd57ead[_0x2036ba+0x0],_0x30cb5a[_0x4eca00+0x1]=_0xd57ead[_0x2036ba+0x1],_0x30cb5a[_0x4eca00+0x2]=_0xd57ead[_0x2036ba+0x2],_0x30cb5a[_0x4eca00+0x3]=0x1;}return _0x30cb5a;}function _0x556fc1(_0x9fd0c8){return function(_0x1a6c1c,_0x2b21b6,_0x4e5fcb,_0x3db693,_0x1fb0d9,_0x559569,_0x5a41e7,_0x37d233,_0xe24e39,_0x238162){void 0x0===_0xe24e39&&(_0xe24e39=null),void 0x0===_0x238162&&(_0x238162=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']);var _0x3c66b9=_0x9fd0c8?this['_gl']['TEXTURE_3D']:this['_gl']['TEXTURE_2D_ARRAY'],_0x4c401c=_0x9fd0c8?_0x21ea74['b']['Raw3D']:_0x21ea74['b']['Raw2DArray'],_0xa1ce98=new _0x21ea74['a'](this,_0x4c401c);_0xa1ce98['baseWidth']=_0x2b21b6,_0xa1ce98['baseHeight']=_0x4e5fcb,_0xa1ce98['baseDepth']=_0x3db693,_0xa1ce98['width']=_0x2b21b6,_0xa1ce98['height']=_0x4e5fcb,_0xa1ce98['depth']=_0x3db693,_0xa1ce98['format']=_0x1fb0d9,_0xa1ce98['type']=_0x238162,_0xa1ce98['generateMipMaps']=_0x559569,_0xa1ce98['samplingMode']=_0x37d233,_0x9fd0c8?_0xa1ce98['is3D']=!0x0:_0xa1ce98['is2DArray']=!0x0,this['_doNotHandleContextLost']||(_0xa1ce98['_bufferView']=_0x1a6c1c),_0x9fd0c8?this['updateRawTexture3D'](_0xa1ce98,_0x1a6c1c,_0x1fb0d9,_0x5a41e7,_0xe24e39,_0x238162):this['updateRawTexture2DArray'](_0xa1ce98,_0x1a6c1c,_0x1fb0d9,_0x5a41e7,_0xe24e39,_0x238162),this['_bindTextureDirectly'](_0x3c66b9,_0xa1ce98,!0x0);var _0x11cadf=this['_getSamplingParameters'](_0x37d233,_0x559569);return this['_gl']['texParameteri'](_0x3c66b9,this['_gl']['TEXTURE_MAG_FILTER'],_0x11cadf['mag']),this['_gl']['texParameteri'](_0x3c66b9,this['_gl']['TEXTURE_MIN_FILTER'],_0x11cadf['min']),_0x559569&&this['_gl']['generateMipmap'](_0x3c66b9),this['_bindTextureDirectly'](_0x3c66b9,null),this['_internalTexturesCache']['push'](_0xa1ce98),_0xa1ce98;};}function _0x412e60(_0x398729){return function(_0x5bc10d,_0x1c711,_0x168d9b,_0x2beba7,_0x11efd6,_0x5be781){void 0x0===_0x11efd6&&(_0x11efd6=null),void 0x0===_0x5be781&&(_0x5be781=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']);var _0x12d753=_0x398729?this['_gl']['TEXTURE_3D']:this['_gl']['TEXTURE_2D_ARRAY'],_0x2459e7=this['_getWebGLTextureType'](_0x5be781),_0x2ef5a5=this['_getInternalFormat'](_0x168d9b),_0x35466e=this['_getRGBABufferInternalSizedFormat'](_0x5be781,_0x168d9b);this['_bindTextureDirectly'](_0x12d753,_0x5bc10d,!0x0),this['_unpackFlipY'](void 0x0===_0x2beba7||!!_0x2beba7),this['_doNotHandleContextLost']||(_0x5bc10d['_bufferView']=_0x1c711,_0x5bc10d['format']=_0x168d9b,_0x5bc10d['invertY']=_0x2beba7,_0x5bc10d['_compression']=_0x11efd6),_0x5bc10d['width']%0x4!=0x0&&this['_gl']['pixelStorei'](this['_gl']['UNPACK_ALIGNMENT'],0x1),_0x11efd6&&_0x1c711?this['_gl']['compressedTexImage3D'](_0x12d753,0x0,this['getCaps']()['s3tc'][_0x11efd6],_0x5bc10d['width'],_0x5bc10d['height'],_0x5bc10d['depth'],0x0,_0x1c711):this['_gl']['texImage3D'](_0x12d753,0x0,_0x35466e,_0x5bc10d['width'],_0x5bc10d['height'],_0x5bc10d['depth'],0x0,_0x2ef5a5,_0x2459e7,_0x1c711),_0x5bc10d['generateMipMaps']&&this['_gl']['generateMipmap'](_0x12d753),this['_bindTextureDirectly'](_0x12d753,null),_0x5bc10d['isReady']=!0x0;};}_0x26966b['a']['prototype']['updateRawTexture']=function(_0xed95f2,_0x5d3a35,_0x2c3378,_0x3f3348,_0x526a8d,_0x405c08){if(void 0x0===_0x526a8d&&(_0x526a8d=null),void 0x0===_0x405c08&&(_0x405c08=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),_0xed95f2){var _0x38e6a1=this['_getRGBABufferInternalSizedFormat'](_0x405c08,_0x2c3378),_0x326627=this['_getInternalFormat'](_0x2c3378),_0x112fc5=this['_getWebGLTextureType'](_0x405c08);this['_bindTextureDirectly'](this['_gl']['TEXTURE_2D'],_0xed95f2,!0x0),this['_unpackFlipY'](void 0x0===_0x3f3348||!!_0x3f3348),this['_doNotHandleContextLost']||(_0xed95f2['_bufferView']=_0x5d3a35,_0xed95f2['format']=_0x2c3378,_0xed95f2['type']=_0x405c08,_0xed95f2['invertY']=_0x3f3348,_0xed95f2['_compression']=_0x526a8d),_0xed95f2['width']%0x4!=0x0&&this['_gl']['pixelStorei'](this['_gl']['UNPACK_ALIGNMENT'],0x1),_0x526a8d&&_0x5d3a35?this['_gl']['compressedTexImage2D'](this['_gl']['TEXTURE_2D'],0x0,this['getCaps']()['s3tc'][_0x526a8d],_0xed95f2['width'],_0xed95f2['height'],0x0,_0x5d3a35):this['_gl']['texImage2D'](this['_gl']['TEXTURE_2D'],0x0,_0x38e6a1,_0xed95f2['width'],_0xed95f2['height'],0x0,_0x326627,_0x112fc5,_0x5d3a35),_0xed95f2['generateMipMaps']&&this['_gl']['generateMipmap'](this['_gl']['TEXTURE_2D']),this['_bindTextureDirectly'](this['_gl']['TEXTURE_2D'],null),_0xed95f2['isReady']=!0x0;}},_0x26966b['a']['prototype']['createRawTexture']=function(_0x46e73f,_0x49cbb1,_0x8d6b00,_0x3ef681,_0x2413a9,_0x33ac20,_0x5e3135,_0x257ea5,_0x123f7c){void 0x0===_0x257ea5&&(_0x257ea5=null),void 0x0===_0x123f7c&&(_0x123f7c=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']);var _0xcdea44=new _0x21ea74['a'](this,_0x21ea74['b']['Raw']);_0xcdea44['baseWidth']=_0x49cbb1,_0xcdea44['baseHeight']=_0x8d6b00,_0xcdea44['width']=_0x49cbb1,_0xcdea44['height']=_0x8d6b00,_0xcdea44['format']=_0x3ef681,_0xcdea44['generateMipMaps']=_0x2413a9,_0xcdea44['samplingMode']=_0x5e3135,_0xcdea44['invertY']=_0x33ac20,_0xcdea44['_compression']=_0x257ea5,_0xcdea44['type']=_0x123f7c,this['_doNotHandleContextLost']||(_0xcdea44['_bufferView']=_0x46e73f),this['updateRawTexture'](_0xcdea44,_0x46e73f,_0x3ef681,_0x33ac20,_0x257ea5,_0x123f7c),this['_bindTextureDirectly'](this['_gl']['TEXTURE_2D'],_0xcdea44,!0x0);var _0x1f979d=this['_getSamplingParameters'](_0x5e3135,_0x2413a9);return this['_gl']['texParameteri'](this['_gl']['TEXTURE_2D'],this['_gl']['TEXTURE_MAG_FILTER'],_0x1f979d['mag']),this['_gl']['texParameteri'](this['_gl']['TEXTURE_2D'],this['_gl']['TEXTURE_MIN_FILTER'],_0x1f979d['min']),_0x2413a9&&this['_gl']['generateMipmap'](this['_gl']['TEXTURE_2D']),this['_bindTextureDirectly'](this['_gl']['TEXTURE_2D'],null),this['_internalTexturesCache']['push'](_0xcdea44),_0xcdea44;},_0x26966b['a']['prototype']['createRawCubeTexture']=function(_0x2a5171,_0x11b0cc,_0xe0a0b9,_0x773f08,_0x43a313,_0x132b8d,_0x5aeb86,_0x42f257){void 0x0===_0x42f257&&(_0x42f257=null);var _0xe2571=this['_gl'],_0x129cb8=new _0x21ea74['a'](this,_0x21ea74['b']['CubeRaw']);_0x129cb8['isCube']=!0x0,_0x129cb8['format']=_0xe0a0b9,_0x129cb8['type']=_0x773f08,this['_doNotHandleContextLost']||(_0x129cb8['_bufferViewArray']=_0x2a5171);var _0x1e46e3=this['_getWebGLTextureType'](_0x773f08),_0xce6891=this['_getInternalFormat'](_0xe0a0b9);_0xce6891===_0xe2571['RGB']&&(_0xce6891=_0xe2571['RGBA']),_0x1e46e3!==_0xe2571['FLOAT']||this['_caps']['textureFloatLinearFiltering']?_0x1e46e3!==this['_gl']['HALF_FLOAT_OES']||this['_caps']['textureHalfFloatLinearFiltering']?_0x1e46e3!==_0xe2571['FLOAT']||this['_caps']['textureFloatRender']?_0x1e46e3!==_0xe2571['HALF_FLOAT']||this['_caps']['colorBufferFloat']||(_0x43a313=!0x1,_0x75193d['a']['Warn']('Render\x20to\x20half\x20float\x20textures\x20is\x20not\x20supported.\x20Mipmap\x20generation\x20forced\x20to\x20false.')):(_0x43a313=!0x1,_0x75193d['a']['Warn']('Render\x20to\x20float\x20textures\x20is\x20not\x20supported.\x20Mipmap\x20generation\x20forced\x20to\x20false.')):(_0x43a313=!0x1,_0x5aeb86=_0x2103ba['a']['TEXTURE_NEAREST_SAMPLINGMODE'],_0x75193d['a']['Warn']('Half\x20float\x20texture\x20filtering\x20is\x20not\x20supported.\x20Mipmap\x20generation\x20and\x20sampling\x20mode\x20are\x20forced\x20to\x20false\x20and\x20TEXTURE_NEAREST_SAMPLINGMODE,\x20respectively.')):(_0x43a313=!0x1,_0x5aeb86=_0x2103ba['a']['TEXTURE_NEAREST_SAMPLINGMODE'],_0x75193d['a']['Warn']('Float\x20texture\x20filtering\x20is\x20not\x20supported.\x20Mipmap\x20generation\x20and\x20sampling\x20mode\x20are\x20forced\x20to\x20false\x20and\x20TEXTURE_NEAREST_SAMPLINGMODE,\x20respectively.'));var _0x420aa2=_0x11b0cc,_0x1f43da=_0x420aa2;_0x129cb8['width']=_0x420aa2,_0x129cb8['height']=_0x1f43da,!this['needPOTTextures']||_0x5d754c['b']['IsExponentOfTwo'](_0x129cb8['width'])&&_0x5d754c['b']['IsExponentOfTwo'](_0x129cb8['height'])||(_0x43a313=!0x1),_0x2a5171&&this['updateRawCubeTexture'](_0x129cb8,_0x2a5171,_0xe0a0b9,_0x773f08,_0x132b8d,_0x42f257),this['_bindTextureDirectly'](this['_gl']['TEXTURE_CUBE_MAP'],_0x129cb8,!0x0),_0x2a5171&&_0x43a313&&this['_gl']['generateMipmap'](this['_gl']['TEXTURE_CUBE_MAP']);var _0x39967f=this['_getSamplingParameters'](_0x5aeb86,_0x43a313);return _0xe2571['texParameteri'](_0xe2571['TEXTURE_CUBE_MAP'],_0xe2571['TEXTURE_MAG_FILTER'],_0x39967f['mag']),_0xe2571['texParameteri'](_0xe2571['TEXTURE_CUBE_MAP'],_0xe2571['TEXTURE_MIN_FILTER'],_0x39967f['min']),_0xe2571['texParameteri'](_0xe2571['TEXTURE_CUBE_MAP'],_0xe2571['TEXTURE_WRAP_S'],_0xe2571['CLAMP_TO_EDGE']),_0xe2571['texParameteri'](_0xe2571['TEXTURE_CUBE_MAP'],_0xe2571['TEXTURE_WRAP_T'],_0xe2571['CLAMP_TO_EDGE']),this['_bindTextureDirectly'](_0xe2571['TEXTURE_CUBE_MAP'],null),_0x129cb8['generateMipMaps']=_0x43a313,_0x129cb8;},_0x26966b['a']['prototype']['updateRawCubeTexture']=function(_0xaa1a1e,_0x29936b,_0x2a44f7,_0x3a80f2,_0xc9ce20,_0x5d2375,_0xd3ddbf){void 0x0===_0x5d2375&&(_0x5d2375=null),void 0x0===_0xd3ddbf&&(_0xd3ddbf=0x0),_0xaa1a1e['_bufferViewArray']=_0x29936b,_0xaa1a1e['format']=_0x2a44f7,_0xaa1a1e['type']=_0x3a80f2,_0xaa1a1e['invertY']=_0xc9ce20,_0xaa1a1e['_compression']=_0x5d2375;var _0x4cc2ee=this['_gl'],_0x20e37e=this['_getWebGLTextureType'](_0x3a80f2),_0x556bf5=this['_getInternalFormat'](_0x2a44f7),_0x3d4636=this['_getRGBABufferInternalSizedFormat'](_0x3a80f2),_0x30f916=!0x1;_0x556bf5===_0x4cc2ee['RGB']&&(_0x556bf5=_0x4cc2ee['RGBA'],_0x30f916=!0x0),this['_bindTextureDirectly'](_0x4cc2ee['TEXTURE_CUBE_MAP'],_0xaa1a1e,!0x0),this['_unpackFlipY'](void 0x0===_0xc9ce20||!!_0xc9ce20),_0xaa1a1e['width']%0x4!=0x0&&_0x4cc2ee['pixelStorei'](_0x4cc2ee['UNPACK_ALIGNMENT'],0x1);for(var _0x3f4b72=0x0;_0x3f4b72<0x6;_0x3f4b72++){var _0x30fde3=_0x29936b[_0x3f4b72];_0x5d2375?_0x4cc2ee['compressedTexImage2D'](_0x4cc2ee['TEXTURE_CUBE_MAP_POSITIVE_X']+_0x3f4b72,_0xd3ddbf,this['getCaps']()['s3tc'][_0x5d2375],_0xaa1a1e['width'],_0xaa1a1e['height'],0x0,_0x30fde3):(_0x30f916&&(_0x30fde3=_0x1e87bf(_0x30fde3,_0xaa1a1e['width'],_0xaa1a1e['height'],_0x3a80f2)),_0x4cc2ee['texImage2D'](_0x4cc2ee['TEXTURE_CUBE_MAP_POSITIVE_X']+_0x3f4b72,_0xd3ddbf,_0x3d4636,_0xaa1a1e['width'],_0xaa1a1e['height'],0x0,_0x556bf5,_0x20e37e,_0x30fde3));}(!this['needPOTTextures']||_0x5d754c['b']['IsExponentOfTwo'](_0xaa1a1e['width'])&&_0x5d754c['b']['IsExponentOfTwo'](_0xaa1a1e['height']))&&_0xaa1a1e['generateMipMaps']&&0x0===_0xd3ddbf&&this['_gl']['generateMipmap'](this['_gl']['TEXTURE_CUBE_MAP']),this['_bindTextureDirectly'](this['_gl']['TEXTURE_CUBE_MAP'],null),_0xaa1a1e['isReady']=!0x0;},_0x26966b['a']['prototype']['createRawCubeTextureFromUrl']=function(_0x593202,_0x3d5329,_0x220183,_0x1d3882,_0x318a8a,_0x81dc92,_0x4da15e,_0x1a0ac8,_0x49ca02,_0x1eb54f,_0x2e163d,_0x1929fa){var _0x4386dc=this;void 0x0===_0x49ca02&&(_0x49ca02=null),void 0x0===_0x1eb54f&&(_0x1eb54f=null),void 0x0===_0x2e163d&&(_0x2e163d=_0x2103ba['a']['TEXTURE_TRILINEAR_SAMPLINGMODE']),void 0x0===_0x1929fa&&(_0x1929fa=!0x1);var _0x24320b=this['_gl'],_0x2da710=this['createRawCubeTexture'](null,_0x220183,_0x1d3882,_0x318a8a,!_0x81dc92,_0x1929fa,_0x2e163d,null);return null==_0x3d5329||_0x3d5329['_addPendingData'](_0x2da710),_0x2da710['url']=_0x593202,this['_internalTexturesCache']['push'](_0x2da710),(this['_loadFile'](_0x593202,function(_0x277a01){!function(_0x3f4624){var _0x2b3a87=_0x2da710['width'],_0x5c4fa5=_0x4da15e(_0x3f4624);if(_0x5c4fa5){if(_0x1a0ac8){var _0x6aaa2c=_0x4386dc['_getWebGLTextureType'](_0x318a8a),_0x566839=_0x4386dc['_getInternalFormat'](_0x1d3882),_0x11c6c8=_0x4386dc['_getRGBABufferInternalSizedFormat'](_0x318a8a),_0x4189dd=!0x1;_0x566839===_0x24320b['RGB']&&(_0x566839=_0x24320b['RGBA'],_0x4189dd=!0x0),_0x4386dc['_bindTextureDirectly'](_0x24320b['TEXTURE_CUBE_MAP'],_0x2da710,!0x0),_0x4386dc['_unpackFlipY'](!0x1);for(var _0x2453f3=_0x1a0ac8(_0x5c4fa5),_0x1179f9=0x0;_0x1179f9<_0x2453f3['length'];_0x1179f9++)for(var _0x154a2a=_0x2b3a87>>_0x1179f9,_0x9a7433=0x0;_0x9a7433<0x6;_0x9a7433++){var _0x12ec9a=_0x2453f3[_0x1179f9][_0x9a7433];_0x4189dd&&(_0x12ec9a=_0x1e87bf(_0x12ec9a,_0x154a2a,_0x154a2a,_0x318a8a)),_0x24320b['texImage2D'](_0x9a7433,_0x1179f9,_0x11c6c8,_0x154a2a,_0x154a2a,0x0,_0x566839,_0x6aaa2c,_0x12ec9a);}_0x4386dc['_bindTextureDirectly'](_0x24320b['TEXTURE_CUBE_MAP'],null);}else _0x4386dc['updateRawCubeTexture'](_0x2da710,_0x5c4fa5,_0x1d3882,_0x318a8a,_0x1929fa);_0x2da710['isReady']=!0x0,null==_0x3d5329||_0x3d5329['_removePendingData'](_0x2da710),_0x49ca02&&_0x49ca02();}}(_0x277a01);},void 0x0,null==_0x3d5329?void 0x0:_0x3d5329['offlineProvider'],!0x0,function(_0x342f2b,_0x323930){null==_0x3d5329||_0x3d5329['_removePendingData'](_0x2da710),_0x1eb54f&&_0x342f2b&&_0x1eb54f(_0x342f2b['status']+'\x20'+_0x342f2b['statusText'],_0x323930);}),_0x2da710);},_0x26966b['a']['prototype']['createRawTexture2DArray']=_0x556fc1(!0x1),_0x26966b['a']['prototype']['createRawTexture3D']=_0x556fc1(!0x0),_0x26966b['a']['prototype']['updateRawTexture2DArray']=_0x412e60(!0x1),_0x26966b['a']['prototype']['updateRawTexture3D']=_0x412e60(!0x0);var _0x1a05d8=function(_0x354c77){function _0x507f9e(_0x431360,_0x11b974,_0xdc4432,_0x2ad77c,_0x4f9c8b,_0x7617d0,_0x48245c,_0x29dd1a,_0x362604){void 0x0===_0x7617d0&&(_0x7617d0=!0x0),void 0x0===_0x48245c&&(_0x48245c=!0x1),void 0x0===_0x29dd1a&&(_0x29dd1a=_0x2103ba['a']['TEXTURE_TRILINEAR_SAMPLINGMODE']),void 0x0===_0x362604&&(_0x362604=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']);var _0x42a150=_0x354c77['call'](this,null,_0x4f9c8b,!_0x7617d0,_0x48245c)||this;return _0x42a150['format']=_0x2ad77c,_0x42a150['_engine']?(_0x42a150['_texture']=_0x42a150['_engine']['createRawTexture'](_0x431360,_0x11b974,_0xdc4432,_0x2ad77c,_0x7617d0,_0x48245c,_0x29dd1a,null,_0x362604),_0x42a150['wrapU']=_0xaf3c80['a']['CLAMP_ADDRESSMODE'],_0x42a150['wrapV']=_0xaf3c80['a']['CLAMP_ADDRESSMODE'],_0x42a150):_0x42a150;}return Object(_0x18e13d['d'])(_0x507f9e,_0x354c77),_0x507f9e['prototype']['update']=function(_0x13b245){this['_getEngine']()['updateRawTexture'](this['_texture'],_0x13b245,this['_texture']['format'],this['_texture']['invertY'],null,this['_texture']['type']);},_0x507f9e['CreateLuminanceTexture']=function(_0x262228,_0x4409e7,_0x2f8e67,_0x964c15,_0x39f1f7,_0x129c5f,_0x1b4a2f){return void 0x0===_0x39f1f7&&(_0x39f1f7=!0x0),void 0x0===_0x129c5f&&(_0x129c5f=!0x1),void 0x0===_0x1b4a2f&&(_0x1b4a2f=_0x2103ba['a']['TEXTURE_TRILINEAR_SAMPLINGMODE']),new _0x507f9e(_0x262228,_0x4409e7,_0x2f8e67,_0x2103ba['a']['TEXTUREFORMAT_LUMINANCE'],_0x964c15,_0x39f1f7,_0x129c5f,_0x1b4a2f);},_0x507f9e['CreateLuminanceAlphaTexture']=function(_0x105e6c,_0x5e9ec4,_0x2e0001,_0x2143a5,_0x2135c3,_0x9d1c41,_0x108957){return void 0x0===_0x2135c3&&(_0x2135c3=!0x0),void 0x0===_0x9d1c41&&(_0x9d1c41=!0x1),void 0x0===_0x108957&&(_0x108957=_0x2103ba['a']['TEXTURE_TRILINEAR_SAMPLINGMODE']),new _0x507f9e(_0x105e6c,_0x5e9ec4,_0x2e0001,_0x2103ba['a']['TEXTUREFORMAT_LUMINANCE_ALPHA'],_0x2143a5,_0x2135c3,_0x9d1c41,_0x108957);},_0x507f9e['CreateAlphaTexture']=function(_0x2fa809,_0x12210f,_0x6b7ead,_0x15202b,_0xede63a,_0x86849b,_0x44d5d6){return void 0x0===_0xede63a&&(_0xede63a=!0x0),void 0x0===_0x86849b&&(_0x86849b=!0x1),void 0x0===_0x44d5d6&&(_0x44d5d6=_0x2103ba['a']['TEXTURE_TRILINEAR_SAMPLINGMODE']),new _0x507f9e(_0x2fa809,_0x12210f,_0x6b7ead,_0x2103ba['a']['TEXTUREFORMAT_ALPHA'],_0x15202b,_0xede63a,_0x86849b,_0x44d5d6);},_0x507f9e['CreateRGBTexture']=function(_0x584ad8,_0x14d948,_0x30ff57,_0x34fd98,_0x54f8bc,_0x4def5d,_0x36a939,_0x34d323){return void 0x0===_0x54f8bc&&(_0x54f8bc=!0x0),void 0x0===_0x4def5d&&(_0x4def5d=!0x1),void 0x0===_0x36a939&&(_0x36a939=_0x2103ba['a']['TEXTURE_TRILINEAR_SAMPLINGMODE']),void 0x0===_0x34d323&&(_0x34d323=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),new _0x507f9e(_0x584ad8,_0x14d948,_0x30ff57,_0x2103ba['a']['TEXTUREFORMAT_RGB'],_0x34fd98,_0x54f8bc,_0x4def5d,_0x36a939,_0x34d323);},_0x507f9e['CreateRGBATexture']=function(_0x45c5dd,_0x5d59d3,_0x45e8fd,_0x170d05,_0x2de29e,_0x43c554,_0x65d1e8,_0x3f91f7){return void 0x0===_0x2de29e&&(_0x2de29e=!0x0),void 0x0===_0x43c554&&(_0x43c554=!0x1),void 0x0===_0x65d1e8&&(_0x65d1e8=_0x2103ba['a']['TEXTURE_TRILINEAR_SAMPLINGMODE']),void 0x0===_0x3f91f7&&(_0x3f91f7=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),new _0x507f9e(_0x45c5dd,_0x5d59d3,_0x45e8fd,_0x2103ba['a']['TEXTUREFORMAT_RGBA'],_0x170d05,_0x2de29e,_0x43c554,_0x65d1e8,_0x3f91f7);},_0x507f9e['CreateRTexture']=function(_0x2ee604,_0x660cd6,_0x41e095,_0x3b098d,_0x21667d,_0x2e0248,_0x34834b,_0x41b5e5){return void 0x0===_0x21667d&&(_0x21667d=!0x0),void 0x0===_0x2e0248&&(_0x2e0248=!0x1),void 0x0===_0x34834b&&(_0x34834b=_0xaf3c80['a']['TRILINEAR_SAMPLINGMODE']),void 0x0===_0x41b5e5&&(_0x41b5e5=_0x2103ba['a']['TEXTURETYPE_FLOAT']),new _0x507f9e(_0x2ee604,_0x660cd6,_0x41e095,_0x2103ba['a']['TEXTUREFORMAT_R'],_0x3b098d,_0x21667d,_0x2e0248,_0x34834b,_0x41b5e5);},_0x507f9e;}(_0xaf3c80['a']),_0x4198a1=(function(){function _0x1986d6(_0x50a161,_0x438ccb,_0x33b8e3){this['name']=_0x50a161,this['id']=_0x438ccb,this['bones']=new Array(),this['needInitialSkinMatrix']=!0x1,this['overrideMesh']=null,this['_isDirty']=!0x0,this['_meshesWithPoseMatrix']=new Array(),this['_identity']=_0x74d525['a']['Identity'](),this['_ranges']={},this['_lastAbsoluteTransformsUpdateId']=-0x1,this['_canUseTextureForBones']=!0x1,this['_uniqueId']=0x0,this['_numBonesWithLinkedTransformNode']=0x0,this['_hasWaitingData']=null,this['_waitingOverrideMeshId']=null,this['doNotSerialize']=!0x1,this['_useTextureToStoreBoneMatrices']=!0x0,this['_animationPropertiesOverride']=null,this['onBeforeComputeObservable']=new _0x6ac1f7['c'](),this['bones']=[],this['_scene']=_0x33b8e3||_0x44b9ce['a']['LastCreatedScene'],this['_uniqueId']=this['_scene']['getUniqueId'](),this['_scene']['addSkeleton'](this),this['_isDirty']=!0x0;var _0x4dde50=this['_scene']['getEngine']()['getCaps']();this['_canUseTextureForBones']=_0x4dde50['textureFloat']&&_0x4dde50['maxVertexTextureImageUnits']>0x0;}return Object['defineProperty'](_0x1986d6['prototype'],'useTextureToStoreBoneMatrices',{'get':function(){return this['_useTextureToStoreBoneMatrices'];},'set':function(_0x1348ab){this['_useTextureToStoreBoneMatrices']=_0x1348ab,this['_markAsDirty']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1986d6['prototype'],'animationPropertiesOverride',{'get':function(){return this['_animationPropertiesOverride']?this['_animationPropertiesOverride']:this['_scene']['animationPropertiesOverride'];},'set':function(_0x15e023){this['_animationPropertiesOverride']=_0x15e023;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1986d6['prototype'],'isUsingTextureForMatrices',{'get':function(){return this['useTextureToStoreBoneMatrices']&&this['_canUseTextureForBones'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1986d6['prototype'],'uniqueId',{'get':function(){return this['_uniqueId'];},'enumerable':!0x1,'configurable':!0x0}),_0x1986d6['prototype']['getClassName']=function(){return'Skeleton';},_0x1986d6['prototype']['getChildren']=function(){return this['bones']['filter'](function(_0x3c1a5e){return!_0x3c1a5e['getParent']();});},_0x1986d6['prototype']['getTransformMatrices']=function(_0x5b1533){return this['needInitialSkinMatrix']&&_0x5b1533['_bonesTransformMatrices']?_0x5b1533['_bonesTransformMatrices']:(this['_transformMatrices']||this['prepare'](),this['_transformMatrices']);},_0x1986d6['prototype']['getTransformMatrixTexture']=function(_0x914887){return this['needInitialSkinMatrix']&&_0x914887['_transformMatrixTexture']?_0x914887['_transformMatrixTexture']:this['_transformMatrixTexture'];},_0x1986d6['prototype']['getScene']=function(){return this['_scene'];},_0x1986d6['prototype']['toString']=function(_0x371f51){var _0x370d34='Name:\x20'+this['name']+',\x20nBones:\x20'+this['bones']['length'];if(_0x370d34+=',\x20nAnimationRanges:\x20'+(this['_ranges']?Object['keys'](this['_ranges'])['length']:'none'),_0x371f51){_0x370d34+=',\x20Ranges:\x20{';var _0x336827=!0x0;for(var _0x160e83 in this['_ranges'])_0x336827&&(_0x370d34+=',\x20',_0x336827=!0x1),_0x370d34+=_0x160e83;_0x370d34+='}';}return _0x370d34;},_0x1986d6['prototype']['getBoneIndexByName']=function(_0x57893f){for(var _0x2885a6=0x0,_0x4c9fec=this['bones']['length'];_0x2885a6<_0x4c9fec;_0x2885a6++)if(this['bones'][_0x2885a6]['name']===_0x57893f)return _0x2885a6;return-0x1;},_0x1986d6['prototype']['createAnimationRange']=function(_0x434dfb,_0x42b2f7,_0x5a2484){if(!this['_ranges'][_0x434dfb]){this['_ranges'][_0x434dfb]=new _0x44ee32(_0x434dfb,_0x42b2f7,_0x5a2484);for(var _0x18737d=0x0,_0x4b93c8=this['bones']['length'];_0x18737d<_0x4b93c8;_0x18737d++)this['bones'][_0x18737d]['animations'][0x0]&&this['bones'][_0x18737d]['animations'][0x0]['createRange'](_0x434dfb,_0x42b2f7,_0x5a2484);}},_0x1986d6['prototype']['deleteAnimationRange']=function(_0x5d58af,_0x3baea3){void 0x0===_0x3baea3&&(_0x3baea3=!0x0);for(var _0x171acf=0x0,_0x59311f=this['bones']['length'];_0x171acf<_0x59311f;_0x171acf++)this['bones'][_0x171acf]['animations'][0x0]&&this['bones'][_0x171acf]['animations'][0x0]['deleteRange'](_0x5d58af,_0x3baea3);this['_ranges'][_0x5d58af]=null;},_0x1986d6['prototype']['getAnimationRange']=function(_0x485767){return this['_ranges'][_0x485767]||null;},_0x1986d6['prototype']['getAnimationRanges']=function(){var _0x4ff056,_0x2f2bb3=[];for(_0x4ff056 in this['_ranges'])_0x2f2bb3['push'](this['_ranges'][_0x4ff056]);return _0x2f2bb3;},_0x1986d6['prototype']['copyAnimationRange']=function(_0x246b16,_0x3d2af9,_0x5e0764){if(void 0x0===_0x5e0764&&(_0x5e0764=!0x1),this['_ranges'][_0x3d2af9]||!_0x246b16['getAnimationRange'](_0x3d2af9))return!0x1;var _0x1c13e6,_0x424e20,_0x387c71=!0x0,_0x1e039b=this['_getHighestAnimationFrame']()+0x1,_0x4f6bfc={},_0x16913f=_0x246b16['bones'];for(_0x424e20=0x0,_0x1c13e6=_0x16913f['length'];_0x424e20<_0x1c13e6;_0x424e20++)_0x4f6bfc[_0x16913f[_0x424e20]['name']]=_0x16913f[_0x424e20];this['bones']['length']!==_0x16913f['length']&&(_0x75193d['a']['Warn']('copyAnimationRange:\x20this\x20rig\x20has\x20'+this['bones']['length']+'\x20bones,\x20while\x20source\x20as\x20'+_0x16913f['length']),_0x387c71=!0x1);var _0x2d6b1e=_0x5e0764&&this['dimensionsAtRest']&&_0x246b16['dimensionsAtRest']?this['dimensionsAtRest']['divide'](_0x246b16['dimensionsAtRest']):null;for(_0x424e20=0x0,_0x1c13e6=this['bones']['length'];_0x424e20<_0x1c13e6;_0x424e20++){var _0x5d60a2=this['bones'][_0x424e20]['name'],_0x2f03de=_0x4f6bfc[_0x5d60a2];_0x2f03de?_0x387c71=_0x387c71&&this['bones'][_0x424e20]['copyAnimationRange'](_0x2f03de,_0x3d2af9,_0x1e039b,_0x5e0764,_0x2d6b1e):(_0x75193d['a']['Warn']('copyAnimationRange:\x20not\x20same\x20rig,\x20missing\x20source\x20bone\x20'+_0x5d60a2),_0x387c71=!0x1);}var _0x475830=_0x246b16['getAnimationRange'](_0x3d2af9);return _0x475830&&(this['_ranges'][_0x3d2af9]=new _0x44ee32(_0x3d2af9,_0x475830['from']+_0x1e039b,_0x475830['to']+_0x1e039b)),_0x387c71;},_0x1986d6['prototype']['returnToRest']=function(){for(var _0x181002=_0x74d525['c']['Vector3'][0x0],_0x19b162=_0x74d525['c']['Quaternion'][0x0],_0x15eeac=_0x74d525['c']['Vector3'][0x1],_0x39db8e=0x0;_0x39db8e-0x1&&this['_meshesWithPoseMatrix']['splice'](_0x586893,0x1);},_0x1986d6['prototype']['_computeTransformMatrices']=function(_0x1b0027,_0x1290a6){this['onBeforeComputeObservable']['notifyObservers'](this);for(var _0xaa2ac3=0x0;_0xaa2ac30x0)for(var _0x450cfb=0x0,_0x5b1612=this['bones'];_0x450cfb<_0x5b1612['length'];_0x450cfb++){var _0x3e3be9=_0x5b1612[_0x450cfb];_0x3e3be9['_linkedTransformNode']&&(_0x3e3be9['_linkedTransformNode']['computeWorldMatrix'](),_0x3e3be9['_matrix']=_0x3e3be9['_linkedTransformNode']['_localMatrix'],_0x3e3be9['markAsDirty']());}if(this['_isDirty']){if(this['needInitialSkinMatrix'])for(var _0xd291f1=0x0;_0xd291f10x0&&(_0x59053e['animation']=_0x410c0b['animations'][0x0]['serialize']()),_0x3adb8c['ranges']=[],this['_ranges'])){var _0x2e8283=this['_ranges'][_0x47c3b0];if(_0x2e8283){var _0x1ddc3f={};_0x1ddc3f['name']=_0x47c3b0,_0x1ddc3f['from']=_0x2e8283['from'],_0x1ddc3f['to']=_0x2e8283['to'],_0x3adb8c['ranges']['push'](_0x1ddc3f);}}}return _0x3adb8c;},_0x1986d6['Parse']=function(_0x749a5f,_0x47122b){var _0x5adb23,_0x34c241=new _0x1986d6(_0x749a5f['name'],_0x749a5f['id'],_0x47122b);for(_0x749a5f['dimensionsAtRest']&&(_0x34c241['dimensionsAtRest']=_0x74d525['e']['FromArray'](_0x749a5f['dimensionsAtRest'])),_0x34c241['needInitialSkinMatrix']=_0x749a5f['needInitialSkinMatrix'],_0x749a5f['overrideMeshId']&&(_0x34c241['_hasWaitingData']=!0x0,_0x34c241['_waitingOverrideMeshId']=_0x749a5f['overrideMeshId']),_0x5adb23=0x0;_0x5adb23<_0x749a5f['bones']['length'];_0x5adb23++){var _0x1e04e8=_0x749a5f['bones'][_0x5adb23],_0x18864f=_0x749a5f['bones'][_0x5adb23]['index'],_0x35eb4a=null;_0x1e04e8['parentBoneIndex']>-0x1&&(_0x35eb4a=_0x34c241['bones'][_0x1e04e8['parentBoneIndex']]);var _0x3865e1=_0x1e04e8['rest']?_0x74d525['a']['FromArray'](_0x1e04e8['rest']):null,_0x4e5da4=new _0x4df88a(_0x1e04e8['name'],_0x34c241,_0x35eb4a,_0x74d525['a']['FromArray'](_0x1e04e8['matrix']),_0x3865e1,null,_0x18864f);void 0x0!==_0x1e04e8['id']&&null!==_0x1e04e8['id']&&(_0x4e5da4['id']=_0x1e04e8['id']),_0x1e04e8['length']&&(_0x4e5da4['length']=_0x1e04e8['length']),_0x1e04e8['metadata']&&(_0x4e5da4['metadata']=_0x1e04e8['metadata']),_0x1e04e8['animation']&&_0x4e5da4['animations']['push'](_0x1b0498['Parse'](_0x1e04e8['animation'])),void 0x0!==_0x1e04e8['linkedTransformNodeId']&&null!==_0x1e04e8['linkedTransformNodeId']&&(_0x34c241['_hasWaitingData']=!0x0,_0x4e5da4['_waitingTransformNodeId']=_0x1e04e8['linkedTransformNodeId']);}if(_0x749a5f['ranges'])for(_0x5adb23=0x0;_0x5adb23<_0x749a5f['ranges']['length'];_0x5adb23++){var _0x364624=_0x749a5f['ranges'][_0x5adb23];_0x34c241['createAnimationRange'](_0x364624['name'],_0x364624['from'],_0x364624['to']);}return _0x34c241;},_0x1986d6['prototype']['computeAbsoluteTransforms']=function(_0x2c85cc){void 0x0===_0x2c85cc&&(_0x2c85cc=!0x1);var _0x4ab175=this['_scene']['getRenderId']();(this['_lastAbsoluteTransformsUpdateId']!=_0x4ab175||_0x2c85cc)&&(this['bones'][0x0]['computeAbsoluteTransforms'](),this['_lastAbsoluteTransformsUpdateId']=_0x4ab175);},_0x1986d6['prototype']['getPoseMatrix']=function(){var _0x2ad7fc=null;return this['_meshesWithPoseMatrix']['length']>0x0&&(_0x2ad7fc=this['_meshesWithPoseMatrix'][0x0]['getPoseMatrix']()),_0x2ad7fc;},_0x1986d6['prototype']['sortBones']=function(){for(var _0x5ce2a0=new Array(),_0x5184b0=new Array(this['bones']['length']),_0x3d0eda=0x0;_0x3d0eda=0x2&&(this['_leftStick']={'x':this['browserGamepad']['axes'][this['_leftStickAxisX']],'y':this['browserGamepad']['axes'][this['_leftStickAxisY']]}),this['browserGamepad']['axes']['length']>=0x4&&(this['_rightStick']={'x':this['browserGamepad']['axes'][this['_rightStickAxisX']],'y':this['browserGamepad']['axes'][this['_rightStickAxisY']]});}return Object['defineProperty'](_0x1a7dfc['prototype'],'isConnected',{'get':function(){return this['_isConnected'];},'enumerable':!0x1,'configurable':!0x0}),_0x1a7dfc['prototype']['onleftstickchanged']=function(_0x1bce51){this['_onleftstickchanged']=_0x1bce51;},_0x1a7dfc['prototype']['onrightstickchanged']=function(_0xa9ede1){this['_onrightstickchanged']=_0xa9ede1;},Object['defineProperty'](_0x1a7dfc['prototype'],'leftStick',{'get':function(){return this['_leftStick'];},'set':function(_0x13926b){!this['_onleftstickchanged']||this['_leftStick']['x']===_0x13926b['x']&&this['_leftStick']['y']===_0x13926b['y']||this['_onleftstickchanged'](_0x13926b),this['_leftStick']=_0x13926b;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1a7dfc['prototype'],'rightStick',{'get':function(){return this['_rightStick'];},'set':function(_0x44f266){!this['_onrightstickchanged']||this['_rightStick']['x']===_0x44f266['x']&&this['_rightStick']['y']===_0x44f266['y']||this['_onrightstickchanged'](_0x44f266),this['_rightStick']=_0x44f266;},'enumerable':!0x1,'configurable':!0x0}),_0x1a7dfc['prototype']['update']=function(){this['_leftStick']&&(this['leftStick']={'x':this['browserGamepad']['axes'][this['_leftStickAxisX']],'y':this['browserGamepad']['axes'][this['_leftStickAxisY']]},this['_invertLeftStickY']&&(this['leftStick']['y']*=-0x1)),this['_rightStick']&&(this['rightStick']={'x':this['browserGamepad']['axes'][this['_rightStickAxisX']],'y':this['browserGamepad']['axes'][this['_rightStickAxisY']]});},_0x1a7dfc['prototype']['dispose']=function(){},_0x1a7dfc['GAMEPAD']=0x0,_0x1a7dfc['GENERIC']=0x1,_0x1a7dfc['XBOX']=0x2,_0x1a7dfc['POSE_ENABLED']=0x3,_0x1a7dfc['DUALSHOCK']=0x4,_0x1a7dfc;}()),_0x1275ec=function(_0x2dd1b4){function _0xca0358(_0x123fdb,_0x2e1e17,_0x509ab2){var _0x3f40dc=_0x2dd1b4['call'](this,_0x123fdb,_0x2e1e17,_0x509ab2)||this;return _0x3f40dc['onButtonDownObservable']=new _0x6ac1f7['c'](),_0x3f40dc['onButtonUpObservable']=new _0x6ac1f7['c'](),_0x3f40dc['type']=_0x56ffd0['GENERIC'],_0x3f40dc['_buttons']=new Array(_0x509ab2['buttons']['length']),_0x3f40dc;}return Object(_0x18e13d['d'])(_0xca0358,_0x2dd1b4),_0xca0358['prototype']['onbuttondown']=function(_0x24634a){this['_onbuttondown']=_0x24634a;},_0xca0358['prototype']['onbuttonup']=function(_0x401181){this['_onbuttonup']=_0x401181;},_0xca0358['prototype']['_setButtonValue']=function(_0x3f50ed,_0x1a868d,_0x376f09){return _0x3f50ed!==_0x1a868d&&(0x1===_0x3f50ed&&(this['_onbuttondown']&&this['_onbuttondown'](_0x376f09),this['onButtonDownObservable']['notifyObservers'](_0x376f09)),0x0===_0x3f50ed&&(this['_onbuttonup']&&this['_onbuttonup'](_0x376f09),this['onButtonUpObservable']['notifyObservers'](_0x376f09))),_0x3f50ed;},_0xca0358['prototype']['update']=function(){_0x2dd1b4['prototype']['update']['call'](this);for(var _0x32b639=0x0;_0x32b6390.005&&(_0x2a0b44['inertialAlphaOffset']+=_0x40ae1b);}if(0x0!=_0x4f9a99['y']){var _0x4b622b=_0x4f9a99['y']/this['gamepadRotationSensibility']*this['_yAxisScale'];0x0!=_0x4b622b&&Math['abs'](_0x4b622b)>0.005&&(_0x2a0b44['inertialBetaOffset']+=_0x4b622b);}}var _0x2729e3=this['gamepad']['leftStick'];if(_0x2729e3&&0x0!=_0x2729e3['y']){var _0x5c0b4a=_0x2729e3['y']/this['gamepadMoveSensibility'];0x0!=_0x5c0b4a&&Math['abs'](_0x5c0b4a)>0.005&&(this['camera']['inertialRadiusOffset']-=_0x5c0b4a);}}},_0x56ab9c['prototype']['getClassName']=function(){return'ArcRotateCameraGamepadInput';},_0x56ab9c['prototype']['getSimpleName']=function(){return'gamepad';},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x56ab9c['prototype'],'gamepadRotationSensibility',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x56ab9c['prototype'],'gamepadMoveSensibility',void 0x0),_0x56ab9c;}());_0x2f54c9['ArcRotateCameraGamepadInput']=_0x588ef7;var _0x2ae55c=_0x162675(0x42),_0x139502=(function(){function _0xca291b(){this['keysUp']=[0x26],this['keysDown']=[0x28],this['keysLeft']=[0x25],this['keysRight']=[0x27],this['keysReset']=[0xdc],this['panningSensibility']=0x32,this['zoomingSensibility']=0x19,this['useAltToZoom']=!0x0,this['angularSpeed']=0.01,this['_keys']=new Array();}return _0xca291b['prototype']['attachControl']=function(_0x37572d){var _0x4bfe4c=this;_0x37572d=_0x5d754c['b']['BackCompatCameraNoPreventDefault'](arguments),this['_onCanvasBlurObserver']||(this['_scene']=this['camera']['getScene'](),this['_engine']=this['_scene']['getEngine'](),this['_onCanvasBlurObserver']=this['_engine']['onCanvasBlurObservable']['add'](function(){_0x4bfe4c['_keys']=[];}),this['_onKeyboardObserver']=this['_scene']['onKeyboardObservable']['add'](function(_0x488f2e){var _0x25cc80,_0x1f44d0=_0x488f2e['event'];_0x1f44d0['metaKey']||(_0x488f2e['type']===_0x2ae55c['a']['KEYDOWN']?(_0x4bfe4c['_ctrlPressed']=_0x1f44d0['ctrlKey'],_0x4bfe4c['_altPressed']=_0x1f44d0['altKey'],(-0x1!==_0x4bfe4c['keysUp']['indexOf'](_0x1f44d0['keyCode'])||-0x1!==_0x4bfe4c['keysDown']['indexOf'](_0x1f44d0['keyCode'])||-0x1!==_0x4bfe4c['keysLeft']['indexOf'](_0x1f44d0['keyCode'])||-0x1!==_0x4bfe4c['keysRight']['indexOf'](_0x1f44d0['keyCode'])||-0x1!==_0x4bfe4c['keysReset']['indexOf'](_0x1f44d0['keyCode']))&&(-0x1===(_0x25cc80=_0x4bfe4c['_keys']['indexOf'](_0x1f44d0['keyCode']))&&_0x4bfe4c['_keys']['push'](_0x1f44d0['keyCode']),_0x1f44d0['preventDefault']&&(_0x37572d||_0x1f44d0['preventDefault']()))):-0x1===_0x4bfe4c['keysUp']['indexOf'](_0x1f44d0['keyCode'])&&-0x1===_0x4bfe4c['keysDown']['indexOf'](_0x1f44d0['keyCode'])&&-0x1===_0x4bfe4c['keysLeft']['indexOf'](_0x1f44d0['keyCode'])&&-0x1===_0x4bfe4c['keysRight']['indexOf'](_0x1f44d0['keyCode'])&&-0x1===_0x4bfe4c['keysReset']['indexOf'](_0x1f44d0['keyCode'])||((_0x25cc80=_0x4bfe4c['_keys']['indexOf'](_0x1f44d0['keyCode']))>=0x0&&_0x4bfe4c['_keys']['splice'](_0x25cc80,0x1),_0x1f44d0['preventDefault']&&(_0x37572d||_0x1f44d0['preventDefault']())));}));},_0xca291b['prototype']['detachControl']=function(_0x3622bf){this['_scene']&&(this['_onKeyboardObserver']&&this['_scene']['onKeyboardObservable']['remove'](this['_onKeyboardObserver']),this['_onCanvasBlurObserver']&&this['_engine']['onCanvasBlurObservable']['remove'](this['_onCanvasBlurObserver']),this['_onKeyboardObserver']=null,this['_onCanvasBlurObserver']=null),this['_keys']=[];},_0xca291b['prototype']['checkInputs']=function(){if(this['_onKeyboardObserver'])for(var _0xa1486c=this['camera'],_0x2fa0b4=0x0;_0x2fa0b40x0?_0x3204d8/(0x1+this['wheelDeltaPercentage']):_0x3204d8*(0x1+this['wheelDeltaPercentage']);},_0xd36296['prototype']['attachControl']=function(_0x1fdca9){var _0xaa012a=this;_0x1fdca9=_0x5d754c['b']['BackCompatCameraNoPreventDefault'](arguments),this['_wheel']=function(_0x56584d,_0x372d22){if(_0x56584d['type']===_0x1cb628['a']['POINTERWHEEL']){var _0x2e77fb=_0x56584d['event'],_0x513306=0x0,_0x4f3989=_0x2e77fb,_0xb312e0=0x0;if(_0xb312e0=_0x4f3989['wheelDelta']?_0x4f3989['wheelDelta']:0x3c*-(_0x2e77fb['deltaY']||_0x2e77fb['detail']),_0xaa012a['wheelDeltaPercentage']){if((_0x513306=_0xaa012a['computeDeltaFromMouseWheelLegacyEvent'](_0xb312e0,_0xaa012a['camera']['radius']))>0x0){for(var _0x699a4d=_0xaa012a['camera']['radius'],_0x4a0474=_0xaa012a['camera']['inertialRadiusOffset']+_0x513306,_0x4be053=0x0;_0x4be053<0x14&&Math['abs'](_0x4a0474)>0.001;_0x4be053++)_0x699a4d-=_0x4a0474,_0x4a0474*=_0xaa012a['camera']['inertia'];_0x699a4d=_0x4a0cf0['a']['Clamp'](_0x699a4d,0x0,Number['MAX_VALUE']),_0x513306=_0xaa012a['computeDeltaFromMouseWheelLegacyEvent'](_0xb312e0,_0x699a4d);}}else _0x513306=_0xb312e0/(0x28*_0xaa012a['wheelPrecision']);_0x513306&&(_0xaa012a['camera']['inertialRadiusOffset']+=_0x513306),_0x2e77fb['preventDefault']&&(_0x1fdca9||_0x2e77fb['preventDefault']());}},this['_observer']=this['camera']['getScene']()['onPointerObservable']['add'](this['_wheel'],_0x1cb628['a']['POINTERWHEEL']);},_0xd36296['prototype']['detachControl']=function(_0x3ded9e){this['_observer']&&(this['camera']['getScene']()['onPointerObservable']['remove'](this['_observer']),this['_observer']=null,this['_wheel']=null);},_0xd36296['prototype']['getClassName']=function(){return'ArcRotateCameraMouseWheelInput';},_0xd36296['prototype']['getSimpleName']=function(){return'mousewheel';},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xd36296['prototype'],'wheelPrecision',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xd36296['prototype'],'wheelDeltaPercentage',void 0x0),_0xd36296;}());_0x2f54c9['ArcRotateCameraMouseWheelInput']=_0x25cb17;var _0x5b47c7=(function(){function _0xa76c9(){this['buttons']=[0x0,0x1,0x2];}return _0xa76c9['prototype']['attachControl']=function(_0x2cdf5d){var _0x1fccbb=this;_0x2cdf5d=_0x5d754c['b']['BackCompatCameraNoPreventDefault'](arguments);var _0x527c5a=this['camera']['getEngine'](),_0x27b9f6=_0x527c5a['getInputElement'](),_0x52f8e4=0x0,_0x57c2f2=null;this['pointA']=null,this['pointB']=null,this['_altKey']=!0x1,this['_ctrlKey']=!0x1,this['_metaKey']=!0x1,this['_shiftKey']=!0x1,this['_buttonsPressed']=0x0,this['_pointerInput']=function(_0x398d46,_0x493dcf){var _0x2042fa=_0x398d46['event'],_0x370e5a='touch'===_0x2042fa['pointerType'];if(!_0x527c5a['isInVRExclusivePointerMode']&&(_0x398d46['type']===_0x1cb628['a']['POINTERMOVE']||-0x1!==_0x1fccbb['buttons']['indexOf'](_0x2042fa['button']))){var _0x9deb7d=_0x2042fa['srcElement']||_0x2042fa['target'];if(_0x1fccbb['_altKey']=_0x2042fa['altKey'],_0x1fccbb['_ctrlKey']=_0x2042fa['ctrlKey'],_0x1fccbb['_metaKey']=_0x2042fa['metaKey'],_0x1fccbb['_shiftKey']=_0x2042fa['shiftKey'],_0x1fccbb['_buttonsPressed']=_0x2042fa['buttons'],_0x527c5a['isPointerLock']){var _0x12af68=_0x2042fa['movementX']||_0x2042fa['mozMovementX']||_0x2042fa['webkitMovementX']||_0x2042fa['msMovementX']||0x0,_0x1acc8b=_0x2042fa['movementY']||_0x2042fa['mozMovementY']||_0x2042fa['webkitMovementY']||_0x2042fa['msMovementY']||0x0;_0x1fccbb['onTouch'](null,_0x12af68,_0x1acc8b),_0x1fccbb['pointA']=null,_0x1fccbb['pointB']=null;}else{if(_0x398d46['type']===_0x1cb628['a']['POINTERDOWN']&&_0x9deb7d){try{_0x9deb7d['setPointerCapture'](_0x2042fa['pointerId']);}catch(_0x2809e6){}null===_0x1fccbb['pointA']?_0x1fccbb['pointA']={'x':_0x2042fa['clientX'],'y':_0x2042fa['clientY'],'pointerId':_0x2042fa['pointerId'],'type':_0x2042fa['pointerType']}:null===_0x1fccbb['pointB']&&(_0x1fccbb['pointB']={'x':_0x2042fa['clientX'],'y':_0x2042fa['clientY'],'pointerId':_0x2042fa['pointerId'],'type':_0x2042fa['pointerType']}),_0x1fccbb['onButtonDown'](_0x2042fa),_0x2cdf5d||(_0x2042fa['preventDefault'](),_0x27b9f6&&_0x27b9f6['focus']());}else{if(_0x398d46['type']===_0x1cb628['a']['POINTERDOUBLETAP'])_0x1fccbb['onDoubleTap'](_0x2042fa['pointerType']);else{if(_0x398d46['type']===_0x1cb628['a']['POINTERUP']&&_0x9deb7d){try{_0x9deb7d['releasePointerCapture'](_0x2042fa['pointerId']);}catch(_0x269915){}_0x370e5a||(_0x1fccbb['pointB']=null),_0x527c5a['_badOS']?_0x1fccbb['pointA']=_0x1fccbb['pointB']=null:_0x1fccbb['pointB']&&_0x1fccbb['pointA']&&_0x1fccbb['pointA']['pointerId']==_0x2042fa['pointerId']?(_0x1fccbb['pointA']=_0x1fccbb['pointB'],_0x1fccbb['pointB']=null):_0x1fccbb['pointA']&&_0x1fccbb['pointB']&&_0x1fccbb['pointB']['pointerId']==_0x2042fa['pointerId']?_0x1fccbb['pointB']=null:_0x1fccbb['pointA']=_0x1fccbb['pointB']=null,(0x0!==_0x52f8e4||_0x57c2f2)&&(_0x1fccbb['onMultiTouch'](_0x1fccbb['pointA'],_0x1fccbb['pointB'],_0x52f8e4,0x0,_0x57c2f2,null),_0x52f8e4=0x0,_0x57c2f2=null),_0x1fccbb['onButtonUp'](_0x2042fa),_0x2cdf5d||_0x2042fa['preventDefault']();}else{if(_0x398d46['type']===_0x1cb628['a']['POINTERMOVE']){if(_0x2cdf5d||_0x2042fa['preventDefault'](),_0x1fccbb['pointA']&&null===_0x1fccbb['pointB'])_0x12af68=_0x2042fa['clientX']-_0x1fccbb['pointA']['x'],_0x1acc8b=_0x2042fa['clientY']-_0x1fccbb['pointA']['y'],(_0x1fccbb['onTouch'](_0x1fccbb['pointA'],_0x12af68,_0x1acc8b),_0x1fccbb['pointA']['x']=_0x2042fa['clientX'],_0x1fccbb['pointA']['y']=_0x2042fa['clientY']);else{if(_0x1fccbb['pointA']&&_0x1fccbb['pointB']){var _0x54a1d0=_0x1fccbb['pointA']['pointerId']===_0x2042fa['pointerId']?_0x1fccbb['pointA']:_0x1fccbb['pointB'];_0x54a1d0['x']=_0x2042fa['clientX'],_0x54a1d0['y']=_0x2042fa['clientY'];var _0x33fe7a=_0x1fccbb['pointA']['x']-_0x1fccbb['pointB']['x'],_0x4dace2=_0x1fccbb['pointA']['y']-_0x1fccbb['pointB']['y'],_0x333fd5=_0x33fe7a*_0x33fe7a+_0x4dace2*_0x4dace2,_0x5262f3={'x':(_0x1fccbb['pointA']['x']+_0x1fccbb['pointB']['x'])/0x2,'y':(_0x1fccbb['pointA']['y']+_0x1fccbb['pointB']['y'])/0x2,'pointerId':_0x2042fa['pointerId'],'type':_0x398d46['type']};_0x1fccbb['onMultiTouch'](_0x1fccbb['pointA'],_0x1fccbb['pointB'],_0x52f8e4,_0x333fd5,_0x57c2f2,_0x5262f3),_0x57c2f2=_0x5262f3,_0x52f8e4=_0x333fd5;}}}}}}}}},this['_observer']=this['camera']['getScene']()['onPointerObservable']['add'](this['_pointerInput'],_0x1cb628['a']['POINTERDOWN']|_0x1cb628['a']['POINTERUP']|_0x1cb628['a']['POINTERMOVE']),this['_onLostFocus']=function(){_0x1fccbb['pointA']=_0x1fccbb['pointB']=null,_0x52f8e4=0x0,_0x57c2f2=null,_0x1fccbb['onLostFocus']();},_0x27b9f6&&_0x27b9f6['addEventListener']('contextmenu',this['onContextMenu']['bind'](this),!0x1);var _0x10985a=this['camera']['getScene']()['getEngine']()['getHostWindow']();_0x10985a&&_0x5d754c['b']['RegisterTopRootEvents'](_0x10985a,[{'name':'blur','handler':this['_onLostFocus']}]);},_0xa76c9['prototype']['detachControl']=function(_0x486bce){if(this['_onLostFocus']){var _0xd36b2=this['camera']['getScene']()['getEngine']()['getHostWindow']();_0xd36b2&&_0x5d754c['b']['UnregisterTopRootEvents'](_0xd36b2,[{'name':'blur','handler':this['_onLostFocus']}]);}if(this['_observer']){if(this['camera']['getScene']()['onPointerObservable']['remove'](this['_observer']),this['_observer']=null,this['onContextMenu']){var _0x5a57f3=this['camera']['getScene']()['getEngine']()['getInputElement']();_0x5a57f3&&_0x5a57f3['removeEventListener']('contextmenu',this['onContextMenu']);}this['_onLostFocus']=null;}this['_altKey']=!0x1,this['_ctrlKey']=!0x1,this['_metaKey']=!0x1,this['_shiftKey']=!0x1,this['_buttonsPressed']=0x0;},_0xa76c9['prototype']['getClassName']=function(){return'BaseCameraPointersInput';},_0xa76c9['prototype']['getSimpleName']=function(){return'pointers';},_0xa76c9['prototype']['onDoubleTap']=function(_0xa12285){},_0xa76c9['prototype']['onTouch']=function(_0x2e9f45,_0x13439b,_0x56f521){},_0xa76c9['prototype']['onMultiTouch']=function(_0x2c648d,_0x172df3,_0x92b5e,_0x2c56ec,_0xababa1,_0x5584b4){},_0xa76c9['prototype']['onContextMenu']=function(_0x17c717){_0x17c717['preventDefault']();},_0xa76c9['prototype']['onButtonDown']=function(_0x38a94e){},_0xa76c9['prototype']['onButtonUp']=function(_0x43562c){},_0xa76c9['prototype']['onLostFocus']=function(){},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xa76c9['prototype'],'buttons',void 0x0),_0xa76c9;}()),_0x14bb32=function(_0x1abd23){function _0x1360e9(){var _0x28007b=null!==_0x1abd23&&_0x1abd23['apply'](this,arguments)||this;return _0x28007b['buttons']=[0x0,0x1,0x2],_0x28007b['angularSensibilityX']=0x3e8,_0x28007b['angularSensibilityY']=0x3e8,_0x28007b['pinchPrecision']=0xc,_0x28007b['pinchDeltaPercentage']=0x0,_0x28007b['useNaturalPinchZoom']=!0x1,_0x28007b['panningSensibility']=0x3e8,_0x28007b['multiTouchPanning']=!0x0,_0x28007b['multiTouchPanAndZoom']=!0x0,_0x28007b['pinchInwards']=!0x0,_0x28007b['_isPanClick']=!0x1,_0x28007b['_twoFingerActivityCount']=0x0,_0x28007b['_isPinching']=!0x1,_0x28007b;}return Object(_0x18e13d['d'])(_0x1360e9,_0x1abd23),_0x1360e9['prototype']['getClassName']=function(){return'ArcRotateCameraPointersInput';},_0x1360e9['prototype']['onTouch']=function(_0x3622bd,_0x4163fd,_0x5c01f1){0x0!==this['panningSensibility']&&(this['_ctrlKey']&&this['camera']['_useCtrlForPanning']||this['_isPanClick'])?(this['camera']['inertialPanningX']+=-_0x4163fd/this['panningSensibility'],this['camera']['inertialPanningY']+=_0x5c01f1/this['panningSensibility']):(this['camera']['inertialAlphaOffset']-=_0x4163fd/this['angularSensibilityX'],this['camera']['inertialBetaOffset']-=_0x5c01f1/this['angularSensibilityY']);},_0x1360e9['prototype']['onDoubleTap']=function(_0x793cb6){this['camera']['useInputToRestoreState']&&this['camera']['restoreState']();},_0x1360e9['prototype']['onMultiTouch']=function(_0x37bcf0,_0x27294a,_0x330c5d,_0x21c882,_0x262fd3,_0x348ce0){if(!(0x0===_0x330c5d&&null===_0x262fd3||0x0===_0x21c882&&null===_0x348ce0)){var _0x24df4e=this['pinchInwards']?0x1:-0x1;if(this['multiTouchPanAndZoom']){if(this['useNaturalPinchZoom']?this['camera']['radius']=this['camera']['radius']*Math['sqrt'](_0x330c5d)/Math['sqrt'](_0x21c882):this['pinchDeltaPercentage']?this['camera']['inertialRadiusOffset']+=0.001*(_0x21c882-_0x330c5d)*this['camera']['radius']*this['pinchDeltaPercentage']:this['camera']['inertialRadiusOffset']+=(_0x21c882-_0x330c5d)/(this['pinchPrecision']*_0x24df4e*(this['angularSensibilityX']+this['angularSensibilityY'])/0x2),0x0!==this['panningSensibility']&&_0x262fd3&&_0x348ce0){var _0x2412ac=_0x348ce0['x']-_0x262fd3['x'],_0x429553=_0x348ce0['y']-_0x262fd3['y'];this['camera']['inertialPanningX']+=-_0x2412ac/this['panningSensibility'],this['camera']['inertialPanningY']+=_0x429553/this['panningSensibility'];}}else{this['_twoFingerActivityCount']++;var _0x10ab13=Math['sqrt'](_0x330c5d),_0x400d2d=Math['sqrt'](_0x21c882);if(this['_isPinching']||this['_twoFingerActivityCount']<0x14&&Math['abs'](_0x400d2d-_0x10ab13)>this['camera']['pinchToPanMaxDistance'])this['pinchDeltaPercentage']?this['camera']['inertialRadiusOffset']+=0.001*(_0x21c882-_0x330c5d)*this['camera']['radius']*this['pinchDeltaPercentage']:this['camera']['inertialRadiusOffset']+=(_0x21c882-_0x330c5d)/(this['pinchPrecision']*_0x24df4e*(this['angularSensibilityX']+this['angularSensibilityY'])/0x2),this['_isPinching']=!0x0;else 0x0!==this['panningSensibility']&&this['multiTouchPanning']&&_0x348ce0&&_0x262fd3&&(_0x2412ac=_0x348ce0['x']-_0x262fd3['x'],_0x429553=_0x348ce0['y']-_0x262fd3['y'],(this['camera']['inertialPanningX']+=-_0x2412ac/this['panningSensibility'],this['camera']['inertialPanningY']+=_0x429553/this['panningSensibility']));}}},_0x1360e9['prototype']['onButtonDown']=function(_0x1731e3){this['_isPanClick']=_0x1731e3['button']===this['camera']['_panningMouseButton'];},_0x1360e9['prototype']['onButtonUp']=function(_0x178165){this['_twoFingerActivityCount']=0x0,this['_isPinching']=!0x1;},_0x1360e9['prototype']['onLostFocus']=function(){this['_isPanClick']=!0x1,this['_twoFingerActivityCount']=0x0,this['_isPinching']=!0x1;},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x1360e9['prototype'],'buttons',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x1360e9['prototype'],'angularSensibilityX',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x1360e9['prototype'],'angularSensibilityY',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x1360e9['prototype'],'pinchPrecision',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x1360e9['prototype'],'pinchDeltaPercentage',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x1360e9['prototype'],'useNaturalPinchZoom',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x1360e9['prototype'],'panningSensibility',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x1360e9['prototype'],'multiTouchPanning',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x1360e9['prototype'],'multiTouchPanAndZoom',void 0x0),_0x1360e9;}(_0x5b47c7);_0x2f54c9['ArcRotateCameraPointersInput']=_0x14bb32;var _0x1f548e=function(_0x2a6e1c){function _0x4efa76(_0x10d95b){return _0x2a6e1c['call'](this,_0x10d95b)||this;}return Object(_0x18e13d['d'])(_0x4efa76,_0x2a6e1c),_0x4efa76['prototype']['addMouseWheel']=function(){return this['add'](new _0x25cb17()),this;},_0x4efa76['prototype']['addPointers']=function(){return this['add'](new _0x14bb32()),this;},_0x4efa76['prototype']['addKeyboard']=function(){return this['add'](new _0x139502()),this;},_0x4efa76;}(_0x4ad380);_0x1f548e['prototype']['addVRDeviceOrientation']=function(){return this['add'](new _0x3c682d()),this;};var _0x3c682d=(function(){function _0x391489(){this['alphaCorrection']=0x1,this['gammaCorrection']=0x1,this['_alpha']=0x0,this['_gamma']=0x0,this['_dirty']=!0x1,this['_deviceOrientationHandler']=this['_onOrientationEvent']['bind'](this);}return _0x391489['prototype']['attachControl']=function(_0x3e0938){var _0x342008=this;_0x3e0938=_0x5d754c['b']['BackCompatCameraNoPreventDefault'](arguments),this['camera']['attachControl'](_0x3e0938);var _0x28f46a=this['camera']['getScene']()['getEngine']()['getHostWindow']();_0x28f46a&&('undefined'!=typeof DeviceOrientationEvent&&'function'==typeof DeviceOrientationEvent['requestPermission']?DeviceOrientationEvent['requestPermission']()['then'](function(_0x2f1cb3){'granted'===_0x2f1cb3?_0x28f46a['addEventListener']('deviceorientation',_0x342008['_deviceOrientationHandler']):_0x5d754c['b']['Warn']('Permission\x20not\x20granted.');})['catch'](function(_0x46bcde){_0x5d754c['b']['Error'](_0x46bcde);}):_0x28f46a['addEventListener']('deviceorientation',this['_deviceOrientationHandler']));},_0x391489['prototype']['_onOrientationEvent']=function(_0x1905e8){null!==_0x1905e8['alpha']&&(this['_alpha']=(0x0|+_0x1905e8['alpha'])*this['alphaCorrection']),null!==_0x1905e8['gamma']&&(this['_gamma']=(0x0|+_0x1905e8['gamma'])*this['gammaCorrection']),this['_dirty']=!0x0;},_0x391489['prototype']['checkInputs']=function(){this['_dirty']&&(this['_dirty']=!0x1,this['_gamma']<0x0&&(this['_gamma']=0xb4+this['_gamma']),this['camera']['alpha']=-this['_alpha']/0xb4*Math['PI']%Math['PI']*0x2,this['camera']['beta']=this['_gamma']/0xb4*Math['PI']);},_0x391489['prototype']['detachControl']=function(_0x51a3c0){window['removeEventListener']('deviceorientation',this['_deviceOrientationHandler']);},_0x391489['prototype']['getClassName']=function(){return'ArcRotateCameraVRDeviceOrientationInput';},_0x391489['prototype']['getSimpleName']=function(){return'VRDeviceOrientation';},_0x391489;}());_0x2f54c9['ArcRotateCameraVRDeviceOrientationInput']=_0x3c682d;var _0x3ec62e=(function(){function _0x1a9241(){this['keysForward']=[0x57],this['keysBackward']=[0x53],this['keysUp']=[0x45],this['keysDown']=[0x51],this['keysRight']=[0x44],this['keysLeft']=[0x41],this['_keys']=new Array();}return _0x1a9241['prototype']['attachControl']=function(_0x495d2e){var _0x44e5b2=this;_0x495d2e=_0x5d754c['b']['BackCompatCameraNoPreventDefault'](arguments),this['_onCanvasBlurObserver']||(this['_scene']=this['camera']['getScene'](),this['_engine']=this['_scene']['getEngine'](),this['_onCanvasBlurObserver']=this['_engine']['onCanvasBlurObservable']['add'](function(){_0x44e5b2['_keys']=[];}),this['_onKeyboardObserver']=this['_scene']['onKeyboardObservable']['add'](function(_0x3ad241){var _0x1bf825,_0x182756=_0x3ad241['event'];_0x3ad241['type']===_0x2ae55c['a']['KEYDOWN']?-0x1===_0x44e5b2['keysForward']['indexOf'](_0x182756['keyCode'])&&-0x1===_0x44e5b2['keysBackward']['indexOf'](_0x182756['keyCode'])&&-0x1===_0x44e5b2['keysUp']['indexOf'](_0x182756['keyCode'])&&-0x1===_0x44e5b2['keysDown']['indexOf'](_0x182756['keyCode'])&&-0x1===_0x44e5b2['keysLeft']['indexOf'](_0x182756['keyCode'])&&-0x1===_0x44e5b2['keysRight']['indexOf'](_0x182756['keyCode'])||(-0x1===(_0x1bf825=_0x44e5b2['_keys']['indexOf'](_0x182756['keyCode']))&&_0x44e5b2['_keys']['push'](_0x182756['keyCode']),_0x495d2e||_0x182756['preventDefault']()):-0x1===_0x44e5b2['keysForward']['indexOf'](_0x182756['keyCode'])&&-0x1===_0x44e5b2['keysBackward']['indexOf'](_0x182756['keyCode'])&&-0x1===_0x44e5b2['keysUp']['indexOf'](_0x182756['keyCode'])&&-0x1===_0x44e5b2['keysDown']['indexOf'](_0x182756['keyCode'])&&-0x1===_0x44e5b2['keysLeft']['indexOf'](_0x182756['keyCode'])&&-0x1===_0x44e5b2['keysRight']['indexOf'](_0x182756['keyCode'])||((_0x1bf825=_0x44e5b2['_keys']['indexOf'](_0x182756['keyCode']))>=0x0&&_0x44e5b2['_keys']['splice'](_0x1bf825,0x1),_0x495d2e||_0x182756['preventDefault']());}));},_0x1a9241['prototype']['detachControl']=function(_0x38ad54){this['_scene']&&(this['_onKeyboardObserver']&&this['_scene']['onKeyboardObservable']['remove'](this['_onKeyboardObserver']),this['_onCanvasBlurObserver']&&this['_engine']['onCanvasBlurObservable']['remove'](this['_onCanvasBlurObserver']),this['_onKeyboardObserver']=null,this['_onCanvasBlurObserver']=null),this['_keys']=[];},_0x1a9241['prototype']['getClassName']=function(){return'FlyCameraKeyboardInput';},_0x1a9241['prototype']['_onLostFocus']=function(_0x12d6c5){this['_keys']=[];},_0x1a9241['prototype']['getSimpleName']=function(){return'keyboard';},_0x1a9241['prototype']['checkInputs']=function(){if(this['_onKeyboardObserver'])for(var _0x4ad1c1=this['camera'],_0xa280e8=0x0;_0xa280e8=0x0&&_0x31e3f1['_keys']['splice'](_0x5d4216,0x1),_0x487618['preventDefault']&&(_0x1f49c3||_0x487618['preventDefault']())));}));},_0xdb58f5['prototype']['detachControl']=function(_0x155cfb){this['_scene']&&(this['_onKeyboardObserver']&&this['_scene']['onKeyboardObservable']['remove'](this['_onKeyboardObserver']),this['_onCanvasBlurObserver']&&this['_engine']['onCanvasBlurObservable']['remove'](this['_onCanvasBlurObserver']),this['_onKeyboardObserver']=null,this['_onCanvasBlurObserver']=null),this['_keys']=[];},_0xdb58f5['prototype']['checkInputs']=function(){var _0x410cd8=this;this['_onKeyboardObserver']&&this['_keys']['forEach'](function(_0xd63666){-0x1!==_0x410cd8['keysHeightOffsetIncr']['indexOf'](_0xd63666)&&_0x410cd8['_modifierHeightOffset']()?_0x410cd8['camera']['heightOffset']+=_0x410cd8['heightSensibility']:-0x1!==_0x410cd8['keysHeightOffsetDecr']['indexOf'](_0xd63666)&&_0x410cd8['_modifierHeightOffset']()?_0x410cd8['camera']['heightOffset']-=_0x410cd8['heightSensibility']:-0x1!==_0x410cd8['keysRotationOffsetIncr']['indexOf'](_0xd63666)&&_0x410cd8['_modifierRotationOffset']()?(_0x410cd8['camera']['rotationOffset']+=_0x410cd8['rotationSensibility'],_0x410cd8['camera']['rotationOffset']%=0x168):-0x1!==_0x410cd8['keysRotationOffsetDecr']['indexOf'](_0xd63666)&&_0x410cd8['_modifierRotationOffset']()?(_0x410cd8['camera']['rotationOffset']-=_0x410cd8['rotationSensibility'],_0x410cd8['camera']['rotationOffset']%=0x168):-0x1!==_0x410cd8['keysRadiusIncr']['indexOf'](_0xd63666)&&_0x410cd8['_modifierRadius']()?_0x410cd8['camera']['radius']+=_0x410cd8['radiusSensibility']:-0x1!==_0x410cd8['keysRadiusDecr']['indexOf'](_0xd63666)&&_0x410cd8['_modifierRadius']()&&(_0x410cd8['camera']['radius']-=_0x410cd8['radiusSensibility']);});},_0xdb58f5['prototype']['getClassName']=function(){return'FollowCameraKeyboardMoveInput';},_0xdb58f5['prototype']['getSimpleName']=function(){return'keyboard';},_0xdb58f5['prototype']['_modifierHeightOffset']=function(){return this['keysHeightOffsetModifierAlt']===this['_altPressed']&&this['keysHeightOffsetModifierCtrl']===this['_ctrlPressed']&&this['keysHeightOffsetModifierShift']===this['_shiftPressed'];},_0xdb58f5['prototype']['_modifierRotationOffset']=function(){return this['keysRotationOffsetModifierAlt']===this['_altPressed']&&this['keysRotationOffsetModifierCtrl']===this['_ctrlPressed']&&this['keysRotationOffsetModifierShift']===this['_shiftPressed'];},_0xdb58f5['prototype']['_modifierRadius']=function(){return this['keysRadiusModifierAlt']===this['_altPressed']&&this['keysRadiusModifierCtrl']===this['_ctrlPressed']&&this['keysRadiusModifierShift']===this['_shiftPressed'];},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xdb58f5['prototype'],'keysHeightOffsetIncr',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xdb58f5['prototype'],'keysHeightOffsetDecr',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xdb58f5['prototype'],'keysHeightOffsetModifierAlt',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xdb58f5['prototype'],'keysHeightOffsetModifierCtrl',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xdb58f5['prototype'],'keysHeightOffsetModifierShift',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xdb58f5['prototype'],'keysRotationOffsetIncr',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xdb58f5['prototype'],'keysRotationOffsetDecr',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xdb58f5['prototype'],'keysRotationOffsetModifierAlt',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xdb58f5['prototype'],'keysRotationOffsetModifierCtrl',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xdb58f5['prototype'],'keysRotationOffsetModifierShift',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xdb58f5['prototype'],'keysRadiusIncr',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xdb58f5['prototype'],'keysRadiusDecr',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xdb58f5['prototype'],'keysRadiusModifierAlt',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xdb58f5['prototype'],'keysRadiusModifierCtrl',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xdb58f5['prototype'],'keysRadiusModifierShift',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xdb58f5['prototype'],'heightSensibility',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xdb58f5['prototype'],'rotationSensibility',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xdb58f5['prototype'],'radiusSensibility',void 0x0),_0xdb58f5;}());_0x2f54c9['FollowCameraKeyboardMoveInput']=_0xceeb14;var _0x41b4ed=(function(){function _0x2fbc44(){this['axisControlRadius']=!0x0,this['axisControlHeight']=!0x1,this['axisControlRotation']=!0x1,this['wheelPrecision']=0x3,this['wheelDeltaPercentage']=0x0;}return _0x2fbc44['prototype']['attachControl']=function(_0x1d622d){var _0x5c8f94=this;_0x1d622d=_0x5d754c['b']['BackCompatCameraNoPreventDefault'](arguments),this['_wheel']=function(_0x7c5bcd,_0x2ee47b){if(_0x7c5bcd['type']===_0x1cb628['a']['POINTERWHEEL']){var _0x3362b1=_0x7c5bcd['event'],_0x5591d1=0x0,_0x522892=Math['max'](-0x1,Math['min'](0x1,_0x3362b1['deltaY']||_0x3362b1['wheelDelta']||-_0x3362b1['detail']));_0x5c8f94['wheelDeltaPercentage']?(console['assert'](_0x5c8f94['axisControlRadius']+_0x5c8f94['axisControlHeight']+_0x5c8f94['axisControlRotation']<=0x1,'wheelDeltaPercentage\x20only\x20usable\x20when\x20mouse\x20wheel\x20controlls\x20ONE\x20axis.\x20Currently\x20enabled:\x20axisControlRadius:\x20'+_0x5c8f94['axisControlRadius']+',\x20axisControlHeightOffset:\x20'+_0x5c8f94['axisControlHeight']+',\x20axisControlRotationOffset:\x20'+_0x5c8f94['axisControlRotation']),_0x5c8f94['axisControlRadius']?_0x5591d1=0.01*_0x522892*_0x5c8f94['wheelDeltaPercentage']*_0x5c8f94['camera']['radius']:_0x5c8f94['axisControlHeight']?_0x5591d1=0.01*_0x522892*_0x5c8f94['wheelDeltaPercentage']*_0x5c8f94['camera']['heightOffset']:_0x5c8f94['axisControlRotation']&&(_0x5591d1=0.01*_0x522892*_0x5c8f94['wheelDeltaPercentage']*_0x5c8f94['camera']['rotationOffset'])):_0x5591d1=_0x522892*_0x5c8f94['wheelPrecision'],_0x5591d1&&(_0x5c8f94['axisControlRadius']?_0x5c8f94['camera']['radius']+=_0x5591d1:_0x5c8f94['axisControlHeight']?_0x5c8f94['camera']['heightOffset']-=_0x5591d1:_0x5c8f94['axisControlRotation']&&(_0x5c8f94['camera']['rotationOffset']-=_0x5591d1)),_0x3362b1['preventDefault']&&(_0x1d622d||_0x3362b1['preventDefault']());}},this['_observer']=this['camera']['getScene']()['onPointerObservable']['add'](this['_wheel'],_0x1cb628['a']['POINTERWHEEL']);},_0x2fbc44['prototype']['detachControl']=function(_0x38c468){this['_observer']&&(this['camera']['getScene']()['onPointerObservable']['remove'](this['_observer']),this['_observer']=null,this['_wheel']=null);},_0x2fbc44['prototype']['getClassName']=function(){return'ArcRotateCameraMouseWheelInput';},_0x2fbc44['prototype']['getSimpleName']=function(){return'mousewheel';},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x2fbc44['prototype'],'axisControlRadius',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x2fbc44['prototype'],'axisControlHeight',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x2fbc44['prototype'],'axisControlRotation',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x2fbc44['prototype'],'wheelPrecision',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x2fbc44['prototype'],'wheelDeltaPercentage',void 0x0),_0x2fbc44;}());_0x2f54c9['FollowCameraMouseWheelInput']=_0x41b4ed;var _0xbf36c3=function(_0x48890b){function _0x27a172(){var _0x57b66e=null!==_0x48890b&&_0x48890b['apply'](this,arguments)||this;return _0x57b66e['angularSensibilityX']=0x1,_0x57b66e['angularSensibilityY']=0x1,_0x57b66e['pinchPrecision']=0x2710,_0x57b66e['pinchDeltaPercentage']=0x0,_0x57b66e['axisXControlRadius']=!0x1,_0x57b66e['axisXControlHeight']=!0x1,_0x57b66e['axisXControlRotation']=!0x0,_0x57b66e['axisYControlRadius']=!0x1,_0x57b66e['axisYControlHeight']=!0x0,_0x57b66e['axisYControlRotation']=!0x1,_0x57b66e['axisPinchControlRadius']=!0x0,_0x57b66e['axisPinchControlHeight']=!0x1,_0x57b66e['axisPinchControlRotation']=!0x1,_0x57b66e['warningEnable']=!0x0,_0x57b66e['_warningCounter']=0x0,_0x57b66e;}return Object(_0x18e13d['d'])(_0x27a172,_0x48890b),_0x27a172['prototype']['getClassName']=function(){return'FollowCameraPointersInput';},_0x27a172['prototype']['onTouch']=function(_0x89167b,_0x5d6c12,_0x491cba){this['_warning'](),this['axisXControlRotation']?this['camera']['rotationOffset']+=_0x5d6c12/this['angularSensibilityX']:this['axisYControlRotation']&&(this['camera']['rotationOffset']+=_0x491cba/this['angularSensibilityX']),this['axisXControlHeight']?this['camera']['heightOffset']+=_0x5d6c12/this['angularSensibilityY']:this['axisYControlHeight']&&(this['camera']['heightOffset']+=_0x491cba/this['angularSensibilityY']),this['axisXControlRadius']?this['camera']['radius']-=_0x5d6c12/this['angularSensibilityY']:this['axisYControlRadius']&&(this['camera']['radius']-=_0x491cba/this['angularSensibilityY']);},_0x27a172['prototype']['onMultiTouch']=function(_0x121b7b,_0x122ff0,_0x256a76,_0x4b106a,_0x1b2c48,_0x59ff4c){if(!(0x0===_0x256a76&&null===_0x1b2c48||0x0===_0x4b106a&&null===_0x59ff4c)){var _0x2a0427=(_0x4b106a-_0x256a76)/(this['pinchPrecision']*(this['angularSensibilityX']+this['angularSensibilityY'])/0x2);this['pinchDeltaPercentage']?(_0x2a0427*=0.01*this['pinchDeltaPercentage'],this['axisPinchControlRotation']&&(this['camera']['rotationOffset']+=_0x2a0427*this['camera']['rotationOffset']),this['axisPinchControlHeight']&&(this['camera']['heightOffset']+=_0x2a0427*this['camera']['heightOffset']),this['axisPinchControlRadius']&&(this['camera']['radius']-=_0x2a0427*this['camera']['radius'])):(this['axisPinchControlRotation']&&(this['camera']['rotationOffset']+=_0x2a0427),this['axisPinchControlHeight']&&(this['camera']['heightOffset']+=_0x2a0427),this['axisPinchControlRadius']&&(this['camera']['radius']-=_0x2a0427));}},_0x27a172['prototype']['_warning']=function(){if(this['warningEnable']&&this['_warningCounter']++%0x64==0x0){var _0x40f249='It\x20probably\x20only\x20makes\x20sense\x20to\x20control\x20ONE\x20camera\x20property\x20with\x20each\x20pointer\x20axis.\x20Set\x20\x27warningEnable\x20=\x20false\x27\x20if\x20you\x20are\x20sure.\x20Currently\x20enabled:\x20';console['assert'](this['axisXControlRotation']+this['axisXControlHeight']+this['axisXControlRadius']<=0x1,_0x40f249+'axisXControlRotation:\x20'+this['axisXControlRotation']+',\x20axisXControlHeight:\x20'+this['axisXControlHeight']+',\x20axisXControlRadius:\x20'+this['axisXControlRadius']),console['assert'](this['axisYControlRotation']+this['axisYControlHeight']+this['axisYControlRadius']<=0x1,_0x40f249+'axisYControlRotation:\x20'+this['axisYControlRotation']+',\x20axisYControlHeight:\x20'+this['axisYControlHeight']+',\x20axisYControlRadius:\x20'+this['axisYControlRadius']),console['assert'](this['axisPinchControlRotation']+this['axisPinchControlHeight']+this['axisPinchControlRadius']<=0x1,_0x40f249+'axisPinchControlRotation:\x20'+this['axisPinchControlRotation']+',\x20axisPinchControlHeight:\x20'+this['axisPinchControlHeight']+',\x20axisPinchControlRadius:\x20'+this['axisPinchControlRadius']);}},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x27a172['prototype'],'angularSensibilityX',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x27a172['prototype'],'angularSensibilityY',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x27a172['prototype'],'pinchPrecision',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x27a172['prototype'],'pinchDeltaPercentage',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x27a172['prototype'],'axisXControlRadius',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x27a172['prototype'],'axisXControlHeight',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x27a172['prototype'],'axisXControlRotation',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x27a172['prototype'],'axisYControlRadius',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x27a172['prototype'],'axisYControlHeight',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x27a172['prototype'],'axisYControlRotation',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x27a172['prototype'],'axisPinchControlRadius',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x27a172['prototype'],'axisPinchControlHeight',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x27a172['prototype'],'axisPinchControlRotation',void 0x0),_0x27a172;}(_0x5b47c7);_0x2f54c9['FollowCameraPointersInput']=_0xbf36c3;var _0x45d6ae=(function(){function _0xb8f595(){this['keysUp']=[0x26],this['keysUpward']=[0x21],this['keysDown']=[0x28],this['keysDownward']=[0x22],this['keysLeft']=[0x25],this['keysRight']=[0x27],this['_keys']=new Array();}return _0xb8f595['prototype']['attachControl']=function(_0x1cd5c4){var _0x4b8e84=this;_0x1cd5c4=_0x5d754c['b']['BackCompatCameraNoPreventDefault'](arguments),this['_onCanvasBlurObserver']||(this['_scene']=this['camera']['getScene'](),this['_engine']=this['_scene']['getEngine'](),this['_onCanvasBlurObserver']=this['_engine']['onCanvasBlurObservable']['add'](function(){_0x4b8e84['_keys']=[];}),this['_onKeyboardObserver']=this['_scene']['onKeyboardObservable']['add'](function(_0x1c3813){var _0xea9e4b,_0x4f9029=_0x1c3813['event'];_0x4f9029['metaKey']||(_0x1c3813['type']===_0x2ae55c['a']['KEYDOWN']?-0x1===_0x4b8e84['keysUp']['indexOf'](_0x4f9029['keyCode'])&&-0x1===_0x4b8e84['keysDown']['indexOf'](_0x4f9029['keyCode'])&&-0x1===_0x4b8e84['keysLeft']['indexOf'](_0x4f9029['keyCode'])&&-0x1===_0x4b8e84['keysRight']['indexOf'](_0x4f9029['keyCode'])&&-0x1===_0x4b8e84['keysUpward']['indexOf'](_0x4f9029['keyCode'])&&-0x1===_0x4b8e84['keysDownward']['indexOf'](_0x4f9029['keyCode'])||(-0x1===(_0xea9e4b=_0x4b8e84['_keys']['indexOf'](_0x4f9029['keyCode']))&&_0x4b8e84['_keys']['push'](_0x4f9029['keyCode']),_0x1cd5c4||_0x4f9029['preventDefault']()):-0x1===_0x4b8e84['keysUp']['indexOf'](_0x4f9029['keyCode'])&&-0x1===_0x4b8e84['keysDown']['indexOf'](_0x4f9029['keyCode'])&&-0x1===_0x4b8e84['keysLeft']['indexOf'](_0x4f9029['keyCode'])&&-0x1===_0x4b8e84['keysRight']['indexOf'](_0x4f9029['keyCode'])&&-0x1===_0x4b8e84['keysUpward']['indexOf'](_0x4f9029['keyCode'])&&-0x1===_0x4b8e84['keysDownward']['indexOf'](_0x4f9029['keyCode'])||((_0xea9e4b=_0x4b8e84['_keys']['indexOf'](_0x4f9029['keyCode']))>=0x0&&_0x4b8e84['_keys']['splice'](_0xea9e4b,0x1),_0x1cd5c4||_0x4f9029['preventDefault']()));}));},_0xb8f595['prototype']['detachControl']=function(_0x50d45b){this['_scene']&&(this['_onKeyboardObserver']&&this['_scene']['onKeyboardObservable']['remove'](this['_onKeyboardObserver']),this['_onCanvasBlurObserver']&&this['_engine']['onCanvasBlurObservable']['remove'](this['_onCanvasBlurObserver']),this['_onKeyboardObserver']=null,this['_onCanvasBlurObserver']=null),this['_keys']=[];},_0xb8f595['prototype']['checkInputs']=function(){if(this['_onKeyboardObserver'])for(var _0x5c1559=this['camera'],_0x276901=0x0;_0x2769010x1)_0x563b48['cameraRotation']['x']=-this['_offsetY']/this['touchAngularSensibility'];else{var _0x36bf64=_0x563b48['_computeLocalCameraSpeed'](),_0x10ca3d=new _0x74d525['e'](0x0,0x0,_0x36bf64*this['_offsetY']/this['touchMoveSensibility']);_0x74d525['a']['RotationYawPitchRollToRef'](_0x563b48['rotation']['y'],_0x563b48['rotation']['x'],0x0,_0x563b48['_cameraRotationMatrix']),_0x563b48['cameraDirection']['addInPlace'](_0x74d525['e']['TransformCoordinates'](_0x10ca3d,_0x563b48['_cameraRotationMatrix']));}}},_0x573c5c['prototype']['getClassName']=function(){return'FreeCameraTouchInput';},_0x573c5c['prototype']['getSimpleName']=function(){return'touch';},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x573c5c['prototype'],'touchAngularSensibility',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x573c5c['prototype'],'touchMoveSensibility',void 0x0),_0x573c5c;}());_0x2f54c9['FreeCameraTouchInput']=_0x4a54c9;var _0x3d384c=function(_0x2ee88d){function _0x23f42f(_0x447647){var _0x26aeda=_0x2ee88d['call'](this,_0x447647)||this;return _0x26aeda['_mouseInput']=null,_0x26aeda['_mouseWheelInput']=null,_0x26aeda;}return Object(_0x18e13d['d'])(_0x23f42f,_0x2ee88d),_0x23f42f['prototype']['addKeyboard']=function(){return this['add'](new _0x45d6ae()),this;},_0x23f42f['prototype']['addMouse']=function(_0x59744d){return void 0x0===_0x59744d&&(_0x59744d=!0x0),this['_mouseInput']||(this['_mouseInput']=new _0x51dcc9(_0x59744d),this['add'](this['_mouseInput'])),this;},_0x23f42f['prototype']['removeMouse']=function(){return this['_mouseInput']&&this['remove'](this['_mouseInput']),this;},_0x23f42f['prototype']['addMouseWheel']=function(){return this['_mouseWheelInput']||(this['_mouseWheelInput']=new _0x192268(),this['add'](this['_mouseWheelInput'])),this;},_0x23f42f['prototype']['removeMouseWheel']=function(){return this['_mouseWheelInput']&&this['remove'](this['_mouseWheelInput']),this;},_0x23f42f['prototype']['addTouch']=function(){return this['add'](new _0x4a54c9()),this;},_0x23f42f['prototype']['clear']=function(){_0x2ee88d['prototype']['clear']['call'](this),this['_mouseInput']=null;},_0x23f42f;}(_0x4ad380);_0x3d384c['prototype']['addDeviceOrientation']=function(){return this['_deviceOrientationInput']||(this['_deviceOrientationInput']=new _0x49f234(),this['add'](this['_deviceOrientationInput'])),this;};var _0x49f234=(function(){function _0x2157a1(){var _0x108ca8=this;this['_screenOrientationAngle']=0x0,this['_screenQuaternion']=new _0x74d525['b'](),this['_alpha']=0x0,this['_beta']=0x0,this['_gamma']=0x0,this['_onDeviceOrientationChangedObservable']=new _0x6ac1f7['c'](),this['_orientationChanged']=function(){_0x108ca8['_screenOrientationAngle']=void 0x0!==window['orientation']?+window['orientation']:window['screen']['orientation']&&window['screen']['orientation']['angle']?window['screen']['orientation']['angle']:0x0,_0x108ca8['_screenOrientationAngle']=-_0x5d754c['b']['ToRadians'](_0x108ca8['_screenOrientationAngle']/0x2),_0x108ca8['_screenQuaternion']['copyFromFloats'](0x0,Math['sin'](_0x108ca8['_screenOrientationAngle']),0x0,Math['cos'](_0x108ca8['_screenOrientationAngle']));},this['_deviceOrientation']=function(_0x52a11d){_0x108ca8['_alpha']=null!==_0x52a11d['alpha']?_0x52a11d['alpha']:0x0,_0x108ca8['_beta']=null!==_0x52a11d['beta']?_0x52a11d['beta']:0x0,_0x108ca8['_gamma']=null!==_0x52a11d['gamma']?_0x52a11d['gamma']:0x0,null!==_0x52a11d['alpha']&&_0x108ca8['_onDeviceOrientationChangedObservable']['notifyObservers']();},this['_constantTranform']=new _0x74d525['b'](-Math['sqrt'](0.5),0x0,0x0,Math['sqrt'](0.5)),this['_orientationChanged']();}return _0x2157a1['WaitForOrientationChangeAsync']=function(_0x1c52c0){return new Promise(function(_0x5a1e9e,_0x14d169){var _0x3ff316=!0x1,_0x388ef7=function(){window['removeEventListener']('deviceorientation',_0x388ef7),_0x3ff316=!0x0,_0x5a1e9e();};_0x1c52c0&&setTimeout(function(){_0x3ff316||(window['removeEventListener']('deviceorientation',_0x388ef7),_0x14d169('WaitForOrientationChangeAsync\x20timed\x20out'));},_0x1c52c0),'undefined'!=typeof DeviceOrientationEvent&&'function'==typeof DeviceOrientationEvent['requestPermission']?DeviceOrientationEvent['requestPermission']()['then'](function(_0x2777f0){'granted'==_0x2777f0?window['addEventListener']('deviceorientation',_0x388ef7):_0x5d754c['b']['Warn']('Permission\x20not\x20granted.');})['catch'](function(_0x585817){_0x5d754c['b']['Error'](_0x585817);}):window['addEventListener']('deviceorientation',_0x388ef7);});},Object['defineProperty'](_0x2157a1['prototype'],'camera',{'get':function(){return this['_camera'];},'set':function(_0x1f1d27){var _0x4874e8=this;this['_camera']=_0x1f1d27,null==this['_camera']||this['_camera']['rotationQuaternion']||(this['_camera']['rotationQuaternion']=new _0x74d525['b']()),this['_camera']&&this['_camera']['onDisposeObservable']['add'](function(){_0x4874e8['_onDeviceOrientationChangedObservable']['clear']();});},'enumerable':!0x1,'configurable':!0x0}),_0x2157a1['prototype']['attachControl']=function(){var _0x190ac3=this,_0x749302=this['camera']['getScene']()['getEngine']()['getHostWindow']();if(_0x749302){var _0x180eb5=function(){_0x749302['addEventListener']('orientationchange',_0x190ac3['_orientationChanged']),_0x749302['addEventListener']('deviceorientation',_0x190ac3['_deviceOrientation']),_0x190ac3['_orientationChanged']();};'undefined'!=typeof DeviceOrientationEvent&&'function'==typeof DeviceOrientationEvent['requestPermission']?DeviceOrientationEvent['requestPermission']()['then'](function(_0x59c498){'granted'===_0x59c498?_0x180eb5():_0x5d754c['b']['Warn']('Permission\x20not\x20granted.');})['catch'](function(_0x30b767){_0x5d754c['b']['Error'](_0x30b767);}):_0x180eb5();}},_0x2157a1['prototype']['detachControl']=function(_0x5f1d1c){window['removeEventListener']('orientationchange',this['_orientationChanged']),window['removeEventListener']('deviceorientation',this['_deviceOrientation']),this['_alpha']=0x0;},_0x2157a1['prototype']['checkInputs']=function(){this['_alpha']&&(_0x74d525['b']['RotationYawPitchRollToRef'](_0x5d754c['b']['ToRadians'](this['_alpha']),_0x5d754c['b']['ToRadians'](this['_beta']),-_0x5d754c['b']['ToRadians'](this['_gamma']),this['camera']['rotationQuaternion']),this['_camera']['rotationQuaternion']['multiplyInPlace'](this['_screenQuaternion']),this['_camera']['rotationQuaternion']['multiplyInPlace'](this['_constantTranform']),this['_camera']['rotationQuaternion']['z']*=-0x1,this['_camera']['rotationQuaternion']['w']*=-0x1);},_0x2157a1['prototype']['getClassName']=function(){return'FreeCameraDeviceOrientationInput';},_0x2157a1['prototype']['getSimpleName']=function(){return'deviceOrientation';},_0x2157a1;}());_0x2f54c9['FreeCameraDeviceOrientationInput']=_0x49f234;var _0x47ef9b=(function(){function _0x13940b(){this['gamepadAngularSensibility']=0xc8,this['gamepadMoveSensibility']=0x28,this['_yAxisScale']=0x1,this['_cameraTransform']=_0x74d525['a']['Identity'](),this['_deltaTransform']=_0x74d525['e']['Zero'](),this['_vector3']=_0x74d525['e']['Zero'](),this['_vector2']=_0x74d525['d']['Zero']();}return Object['defineProperty'](_0x13940b['prototype'],'invertYAxis',{'get':function(){return 0x1!==this['_yAxisScale'];},'set':function(_0x10e982){this['_yAxisScale']=_0x10e982?-0x1:0x1;},'enumerable':!0x1,'configurable':!0x0}),_0x13940b['prototype']['attachControl']=function(){var _0x379353=this,_0x1f911d=this['camera']['getScene']()['gamepadManager'];this['_onGamepadConnectedObserver']=_0x1f911d['onGamepadConnectedObservable']['add'](function(_0x50bd38){_0x50bd38['type']!==_0x56ffd0['POSE_ENABLED']&&(_0x379353['gamepad']&&_0x50bd38['type']!==_0x56ffd0['XBOX']||(_0x379353['gamepad']=_0x50bd38));}),this['_onGamepadDisconnectedObserver']=_0x1f911d['onGamepadDisconnectedObservable']['add'](function(_0x2223a5){_0x379353['gamepad']===_0x2223a5&&(_0x379353['gamepad']=null);}),this['gamepad']=_0x1f911d['getGamepadByType'](_0x56ffd0['XBOX']),!this['gamepad']&&_0x1f911d['gamepads']['length']&&(this['gamepad']=_0x1f911d['gamepads'][0x0]);},_0x13940b['prototype']['detachControl']=function(_0x28e228){this['camera']['getScene']()['gamepadManager']['onGamepadConnectedObservable']['remove'](this['_onGamepadConnectedObserver']),this['camera']['getScene']()['gamepadManager']['onGamepadDisconnectedObservable']['remove'](this['_onGamepadDisconnectedObserver']),this['gamepad']=null;},_0x13940b['prototype']['checkInputs']=function(){if(this['gamepad']&&this['gamepad']['leftStick']){var _0x483a63=this['camera'],_0x5922b9=this['gamepad']['leftStick'],_0x1f1b98=_0x5922b9['x']/this['gamepadMoveSensibility'],_0xcb7d=_0x5922b9['y']/this['gamepadMoveSensibility'];_0x5922b9['x']=Math['abs'](_0x1f1b98)>0.005?0x0+_0x1f1b98:0x0,_0x5922b9['y']=Math['abs'](_0xcb7d)>0.005?0x0+_0xcb7d:0x0;var _0x52e4d0=this['gamepad']['rightStick'];if(_0x52e4d0){var _0x49cc83=_0x52e4d0['x']/this['gamepadAngularSensibility'],_0x5b3d7c=_0x52e4d0['y']/this['gamepadAngularSensibility']*this['_yAxisScale'];_0x52e4d0['x']=Math['abs'](_0x49cc83)>0.001?0x0+_0x49cc83:0x0,_0x52e4d0['y']=Math['abs'](_0x5b3d7c)>0.001?0x0+_0x5b3d7c:0x0;}else _0x52e4d0={'x':0x0,'y':0x0};_0x483a63['rotationQuaternion']?_0x483a63['rotationQuaternion']['toRotationMatrix'](this['_cameraTransform']):_0x74d525['a']['RotationYawPitchRollToRef'](_0x483a63['rotation']['y'],_0x483a63['rotation']['x'],0x0,this['_cameraTransform']);var _0x908f29=0x32*_0x483a63['_computeLocalCameraSpeed']();this['_vector3']['copyFromFloats'](_0x5922b9['x']*_0x908f29,0x0,-_0x5922b9['y']*_0x908f29),_0x74d525['e']['TransformCoordinatesToRef'](this['_vector3'],this['_cameraTransform'],this['_deltaTransform']),_0x483a63['cameraDirection']['addInPlace'](this['_deltaTransform']),this['_vector2']['copyFromFloats'](_0x52e4d0['y'],_0x52e4d0['x']),_0x483a63['cameraRotation']['addInPlace'](this['_vector2']);}},_0x13940b['prototype']['getClassName']=function(){return'FreeCameraGamepadInput';},_0x13940b['prototype']['getSimpleName']=function(){return'gamepad';},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x13940b['prototype'],'gamepadAngularSensibility',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x13940b['prototype'],'gamepadMoveSensibility',void 0x0),_0x13940b;}());_0x2f54c9['FreeCameraGamepadInput']=_0x47ef9b;var _0x15bf12,_0x33b3b3=_0x162675(0x70);!function(_0x4ac1cd){_0x4ac1cd[_0x4ac1cd['X']=0x0]='X',_0x4ac1cd[_0x4ac1cd['Y']=0x1]='Y',_0x4ac1cd[_0x4ac1cd['Z']=0x2]='Z';}(_0x15bf12||(_0x15bf12={}));var _0x2fab61=(function(){function _0x2ee3a9(_0x4800df,_0x458ab2){var _0x41598a=this,_0x43c8c0=Object(_0x18e13d['a'])(Object(_0x18e13d['a'])({},_0x2ee3a9['_GetDefaultOptions']()),_0x458ab2);if(this['_leftJoystick']=!!_0x4800df,_0x2ee3a9['_globalJoystickIndex']++,this['_axisTargetedByLeftAndRight']=_0x15bf12['X'],this['_axisTargetedByUpAndDown']=_0x15bf12['Y'],this['reverseLeftRight']=!0x1,this['reverseUpDown']=!0x1,this['_touches']=new _0x33b3b3['a'](),this['deltaPosition']=_0x74d525['e']['Zero'](),this['_joystickSensibility']=0x19,this['_inversedSensibility']=0x1/(this['_joystickSensibility']/0x3e8),this['_onResize']=function(_0x4c6e05){_0x2ee3a9['vjCanvasWidth']=window['innerWidth'],_0x2ee3a9['vjCanvasHeight']=window['innerHeight'],_0x2ee3a9['Canvas']&&(_0x2ee3a9['Canvas']['width']=_0x2ee3a9['vjCanvasWidth'],_0x2ee3a9['Canvas']['height']=_0x2ee3a9['vjCanvasHeight']),_0x2ee3a9['halfWidth']=_0x2ee3a9['vjCanvasWidth']/0x2;},!_0x2ee3a9['Canvas']){window['addEventListener']('resize',this['_onResize'],!0x1),_0x2ee3a9['Canvas']=document['createElement']('canvas'),_0x2ee3a9['vjCanvasWidth']=window['innerWidth'],_0x2ee3a9['vjCanvasHeight']=window['innerHeight'],_0x2ee3a9['Canvas']['width']=window['innerWidth'],_0x2ee3a9['Canvas']['height']=window['innerHeight'],_0x2ee3a9['Canvas']['style']['width']='100%',_0x2ee3a9['Canvas']['style']['height']='100%',_0x2ee3a9['Canvas']['style']['position']='absolute',_0x2ee3a9['Canvas']['style']['backgroundColor']='transparent',_0x2ee3a9['Canvas']['style']['top']='0px',_0x2ee3a9['Canvas']['style']['left']='0px',_0x2ee3a9['Canvas']['style']['zIndex']='5',_0x2ee3a9['Canvas']['style']['msTouchAction']='none',_0x2ee3a9['Canvas']['style']['touchAction']='none',_0x2ee3a9['Canvas']['setAttribute']('touch-action','none');var _0x8473b6=_0x2ee3a9['Canvas']['getContext']('2d');if(!_0x8473b6)throw new Error('Unable\x20to\x20create\x20canvas\x20for\x20virtual\x20joystick');_0x2ee3a9['vjCanvasContext']=_0x8473b6,_0x2ee3a9['vjCanvasContext']['strokeStyle']='#ffffff',_0x2ee3a9['vjCanvasContext']['lineWidth']=0x2,document['body']['appendChild'](_0x2ee3a9['Canvas']);}_0x2ee3a9['halfWidth']=_0x2ee3a9['Canvas']['width']/0x2,this['pressed']=!0x1,this['limitToContainer']=_0x43c8c0['limitToContainer'],this['_joystickColor']=_0x43c8c0['color'],this['containerSize']=_0x43c8c0['containerSize'],this['puckSize']=_0x43c8c0['puckSize'],_0x43c8c0['position']&&this['setPosition'](_0x43c8c0['position']['x'],_0x43c8c0['position']['y']),_0x43c8c0['puckImage']&&this['setPuckImage'](_0x43c8c0['puckImage']),_0x43c8c0['containerImage']&&this['setContainerImage'](_0x43c8c0['containerImage']),_0x43c8c0['alwaysVisible']&&_0x2ee3a9['_alwaysVisibleSticks']++,this['alwaysVisible']=_0x43c8c0['alwaysVisible'],this['_joystickPointerID']=-0x1,this['_joystickPointerPos']=new _0x74d525['d'](0x0,0x0),this['_joystickPreviousPointerPos']=new _0x74d525['d'](0x0,0x0),this['_joystickPointerStartPos']=new _0x74d525['d'](0x0,0x0),this['_deltaJoystickVector']=new _0x74d525['d'](0x0,0x0),this['_onPointerDownHandlerRef']=function(_0xb87bd5){_0x41598a['_onPointerDown'](_0xb87bd5);},this['_onPointerMoveHandlerRef']=function(_0x420b2e){_0x41598a['_onPointerMove'](_0x420b2e);},this['_onPointerUpHandlerRef']=function(_0xbc8f96){_0x41598a['_onPointerUp'](_0xbc8f96);},_0x2ee3a9['Canvas']['addEventListener']('pointerdown',this['_onPointerDownHandlerRef'],!0x1),_0x2ee3a9['Canvas']['addEventListener']('pointermove',this['_onPointerMoveHandlerRef'],!0x1),_0x2ee3a9['Canvas']['addEventListener']('pointerup',this['_onPointerUpHandlerRef'],!0x1),_0x2ee3a9['Canvas']['addEventListener']('pointerout',this['_onPointerUpHandlerRef'],!0x1),_0x2ee3a9['Canvas']['addEventListener']('contextmenu',function(_0x1f2830){_0x1f2830['preventDefault']();},!0x1),requestAnimationFrame(function(){_0x41598a['_drawVirtualJoystick']();});}return _0x2ee3a9['_GetDefaultOptions']=function(){return{'puckSize':0x28,'containerSize':0x3c,'color':'cyan','puckImage':void 0x0,'containerImage':void 0x0,'position':void 0x0,'alwaysVisible':!0x1,'limitToContainer':!0x1};},_0x2ee3a9['prototype']['setJoystickSensibility']=function(_0x387241){this['_joystickSensibility']=_0x387241,this['_inversedSensibility']=0x1/(this['_joystickSensibility']/0x3e8);},_0x2ee3a9['prototype']['_onPointerDown']=function(_0x547130){_0x547130['preventDefault'](),(!0x0===this['_leftJoystick']?_0x547130['clientX']<_0x2ee3a9['halfWidth']:_0x547130['clientX']>_0x2ee3a9['halfWidth'])&&this['_joystickPointerID']<0x0?(this['_joystickPointerID']=_0x547130['pointerId'],this['_joystickPosition']?(this['_joystickPointerStartPos']=this['_joystickPosition']['clone'](),this['_joystickPointerPos']=this['_joystickPosition']['clone'](),this['_joystickPreviousPointerPos']=this['_joystickPosition']['clone'](),this['_onPointerMove'](_0x547130)):(this['_joystickPointerStartPos']['x']=_0x547130['clientX'],this['_joystickPointerStartPos']['y']=_0x547130['clientY'],this['_joystickPointerPos']=this['_joystickPointerStartPos']['clone'](),this['_joystickPreviousPointerPos']=this['_joystickPointerStartPos']['clone']()),this['_deltaJoystickVector']['x']=0x0,this['_deltaJoystickVector']['y']=0x0,this['pressed']=!0x0,this['_touches']['add'](_0x547130['pointerId']['toString'](),_0x547130)):_0x2ee3a9['_globalJoystickIndex']<0x2&&this['_action']&&(this['_action'](),this['_touches']['add'](_0x547130['pointerId']['toString'](),{'x':_0x547130['clientX'],'y':_0x547130['clientY'],'prevX':_0x547130['clientX'],'prevY':_0x547130['clientY']}));},_0x2ee3a9['prototype']['_onPointerMove']=function(_0x1bebac){if(this['_joystickPointerID']==_0x1bebac['pointerId']){if(this['limitToContainer']){var _0x281f9b=new _0x74d525['d'](_0x1bebac['clientX']-this['_joystickPointerStartPos']['x'],_0x1bebac['clientY']-this['_joystickPointerStartPos']['y']),_0x205a67=_0x281f9b['length']();_0x205a67>this['containerSize']&&_0x281f9b['scaleInPlace'](this['containerSize']/_0x205a67),this['_joystickPointerPos']['x']=this['_joystickPointerStartPos']['x']+_0x281f9b['x'],this['_joystickPointerPos']['y']=this['_joystickPointerStartPos']['y']+_0x281f9b['y'];}else this['_joystickPointerPos']['x']=_0x1bebac['clientX'],this['_joystickPointerPos']['y']=_0x1bebac['clientY'];this['_deltaJoystickVector']=this['_joystickPointerPos']['clone'](),this['_deltaJoystickVector']=this['_deltaJoystickVector']['subtract'](this['_joystickPointerStartPos']),0x0<_0x2ee3a9['_alwaysVisibleSticks']&&(this['_leftJoystick']?this['_joystickPointerPos']['x']=Math['min'](_0x2ee3a9['halfWidth'],this['_joystickPointerPos']['x']):this['_joystickPointerPos']['x']=Math['max'](_0x2ee3a9['halfWidth'],this['_joystickPointerPos']['x']));var _0x5c74cc=(this['reverseLeftRight']?-0x1:0x1)*this['_deltaJoystickVector']['x']/this['_inversedSensibility'];switch(this['_axisTargetedByLeftAndRight']){case _0x15bf12['X']:this['deltaPosition']['x']=Math['min'](0x1,Math['max'](-0x1,_0x5c74cc));break;case _0x15bf12['Y']:this['deltaPosition']['y']=Math['min'](0x1,Math['max'](-0x1,_0x5c74cc));break;case _0x15bf12['Z']:this['deltaPosition']['z']=Math['min'](0x1,Math['max'](-0x1,_0x5c74cc));}var _0x3d79dc=(this['reverseUpDown']?0x1:-0x1)*this['_deltaJoystickVector']['y']/this['_inversedSensibility'];switch(this['_axisTargetedByUpAndDown']){case _0x15bf12['X']:this['deltaPosition']['x']=Math['min'](0x1,Math['max'](-0x1,_0x3d79dc));break;case _0x15bf12['Y']:this['deltaPosition']['y']=Math['min'](0x1,Math['max'](-0x1,_0x3d79dc));break;case _0x15bf12['Z']:this['deltaPosition']['z']=Math['min'](0x1,Math['max'](-0x1,_0x3d79dc));}}else{var _0x3576f2=this['_touches']['get'](_0x1bebac['pointerId']['toString']());_0x3576f2&&(_0x3576f2['x']=_0x1bebac['clientX'],_0x3576f2['y']=_0x1bebac['clientY']);}},_0x2ee3a9['prototype']['_onPointerUp']=function(_0x1bd1d2){if(this['_joystickPointerID']==_0x1bd1d2['pointerId'])this['_clearPreviousDraw'](),this['_joystickPointerID']=-0x1,this['pressed']=!0x1;else{var _0x227a52=this['_touches']['get'](_0x1bd1d2['pointerId']['toString']());_0x227a52&&_0x2ee3a9['vjCanvasContext']['clearRect'](_0x227a52['prevX']-0x2c,_0x227a52['prevY']-0x2c,0x58,0x58);}this['_deltaJoystickVector']['x']=0x0,this['_deltaJoystickVector']['y']=0x0,this['_touches']['remove'](_0x1bd1d2['pointerId']['toString']());},_0x2ee3a9['prototype']['setJoystickColor']=function(_0x58443b){this['_joystickColor']=_0x58443b;},Object['defineProperty'](_0x2ee3a9['prototype'],'containerSize',{'get':function(){return this['_joystickContainerSize'];},'set':function(_0x40f84c){this['_joystickContainerSize']=_0x40f84c,this['_clearContainerSize']=~~(2.1*this['_joystickContainerSize']),this['_clearContainerSizeOffset']=~~(this['_clearContainerSize']/0x2);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2ee3a9['prototype'],'puckSize',{'get':function(){return this['_joystickPuckSize'];},'set':function(_0x1f0136){this['_joystickPuckSize']=_0x1f0136,this['_clearPuckSize']=~~(2.1*this['_joystickPuckSize']),this['_clearPuckSizeOffset']=~~(this['_clearPuckSize']/0x2);},'enumerable':!0x1,'configurable':!0x0}),_0x2ee3a9['prototype']['clearPosition']=function(){this['alwaysVisible']=!0x1,this['_joystickPosition']=null;},Object['defineProperty'](_0x2ee3a9['prototype'],'alwaysVisible',{'get':function(){return this['_alwaysVisible'];},'set':function(_0x23bd58){this['_alwaysVisible']!==_0x23bd58&&(_0x23bd58&&this['_joystickPosition']?(_0x2ee3a9['_alwaysVisibleSticks']++,this['_alwaysVisible']=!0x0):(_0x2ee3a9['_alwaysVisibleSticks']--,this['_alwaysVisible']=!0x1));},'enumerable':!0x1,'configurable':!0x0}),_0x2ee3a9['prototype']['setPosition']=function(_0x2fe6cf,_0x294085){this['_joystickPointerStartPos']&&this['_clearPreviousDraw'](),this['_joystickPosition']=new _0x74d525['d'](_0x2fe6cf,_0x294085);},_0x2ee3a9['prototype']['setActionOnTouch']=function(_0x5391b6){this['_action']=_0x5391b6;},_0x2ee3a9['prototype']['setAxisForLeftRight']=function(_0x1e7421){switch(_0x1e7421){case _0x15bf12['X']:case _0x15bf12['Y']:case _0x15bf12['Z']:this['_axisTargetedByLeftAndRight']=_0x1e7421;break;default:this['_axisTargetedByLeftAndRight']=_0x15bf12['X'];}},_0x2ee3a9['prototype']['setAxisForUpDown']=function(_0x20c6de){switch(_0x20c6de){case _0x15bf12['X']:case _0x15bf12['Y']:case _0x15bf12['Z']:this['_axisTargetedByUpAndDown']=_0x20c6de;break;default:this['_axisTargetedByUpAndDown']=_0x15bf12['Y'];}},_0x2ee3a9['prototype']['_clearPreviousDraw']=function(){var _0x348251=this['_joystickPosition']||this['_joystickPointerStartPos'];_0x2ee3a9['vjCanvasContext']['clearRect'](_0x348251['x']-this['_clearContainerSizeOffset'],_0x348251['y']-this['_clearContainerSizeOffset'],this['_clearContainerSize'],this['_clearContainerSize']),_0x2ee3a9['vjCanvasContext']['clearRect'](this['_joystickPreviousPointerPos']['x']-this['_clearPuckSizeOffset'],this['_joystickPreviousPointerPos']['y']-this['_clearPuckSizeOffset'],this['_clearPuckSize'],this['_clearPuckSize']);},_0x2ee3a9['prototype']['setContainerImage']=function(_0x47284e){var _0x68ee9d=this,_0x474eba=new Image();_0x474eba['src']=_0x47284e,_0x474eba['onload']=function(){return _0x68ee9d['_containerImage']=_0x474eba;};},_0x2ee3a9['prototype']['setPuckImage']=function(_0x3ac38b){var _0x2c8040=this,_0xd843ec=new Image();_0xd843ec['src']=_0x3ac38b,_0xd843ec['onload']=function(){return _0x2c8040['_puckImage']=_0xd843ec;};},_0x2ee3a9['prototype']['_drawContainer']=function(){var _0x5aca35=this['_joystickPosition']||this['_joystickPointerStartPos'];this['_clearPreviousDraw'](),this['_containerImage']?_0x2ee3a9['vjCanvasContext']['drawImage'](this['_containerImage'],_0x5aca35['x']-this['containerSize'],_0x5aca35['y']-this['containerSize'],0x2*this['containerSize'],0x2*this['containerSize']):(_0x2ee3a9['vjCanvasContext']['beginPath'](),_0x2ee3a9['vjCanvasContext']['strokeStyle']=this['_joystickColor'],_0x2ee3a9['vjCanvasContext']['lineWidth']=0x2,_0x2ee3a9['vjCanvasContext']['arc'](_0x5aca35['x'],_0x5aca35['y'],this['containerSize'],0x0,0x2*Math['PI'],!0x0),_0x2ee3a9['vjCanvasContext']['stroke'](),_0x2ee3a9['vjCanvasContext']['closePath'](),_0x2ee3a9['vjCanvasContext']['beginPath'](),_0x2ee3a9['vjCanvasContext']['lineWidth']=0x6,_0x2ee3a9['vjCanvasContext']['strokeStyle']=this['_joystickColor'],_0x2ee3a9['vjCanvasContext']['arc'](_0x5aca35['x'],_0x5aca35['y'],this['puckSize'],0x0,0x2*Math['PI'],!0x0),_0x2ee3a9['vjCanvasContext']['stroke'](),_0x2ee3a9['vjCanvasContext']['closePath']());},_0x2ee3a9['prototype']['_drawPuck']=function(){this['_puckImage']?_0x2ee3a9['vjCanvasContext']['drawImage'](this['_puckImage'],this['_joystickPointerPos']['x']-this['puckSize'],this['_joystickPointerPos']['y']-this['puckSize'],0x2*this['puckSize'],0x2*this['puckSize']):(_0x2ee3a9['vjCanvasContext']['beginPath'](),_0x2ee3a9['vjCanvasContext']['strokeStyle']=this['_joystickColor'],_0x2ee3a9['vjCanvasContext']['lineWidth']=0x2,_0x2ee3a9['vjCanvasContext']['arc'](this['_joystickPointerPos']['x'],this['_joystickPointerPos']['y'],this['puckSize'],0x0,0x2*Math['PI'],!0x0),_0x2ee3a9['vjCanvasContext']['stroke'](),_0x2ee3a9['vjCanvasContext']['closePath']());},_0x2ee3a9['prototype']['_drawVirtualJoystick']=function(){var _0x85c13a=this;this['alwaysVisible']&&this['_drawContainer'](),this['pressed']&&this['_touches']['forEach'](function(_0x473f2b,_0x3a40ed){_0x3a40ed['pointerId']===_0x85c13a['_joystickPointerID']?(_0x85c13a['alwaysVisible']||_0x85c13a['_drawContainer'](),_0x85c13a['_drawPuck'](),_0x85c13a['_joystickPreviousPointerPos']=_0x85c13a['_joystickPointerPos']['clone']()):(_0x2ee3a9['vjCanvasContext']['clearRect'](_0x3a40ed['prevX']-0x2c,_0x3a40ed['prevY']-0x2c,0x58,0x58),_0x2ee3a9['vjCanvasContext']['beginPath'](),_0x2ee3a9['vjCanvasContext']['fillStyle']='white',_0x2ee3a9['vjCanvasContext']['beginPath'](),_0x2ee3a9['vjCanvasContext']['strokeStyle']='red',_0x2ee3a9['vjCanvasContext']['lineWidth']=0x6,_0x2ee3a9['vjCanvasContext']['arc'](_0x3a40ed['x'],_0x3a40ed['y'],0x28,0x0,0x2*Math['PI'],!0x0),_0x2ee3a9['vjCanvasContext']['stroke'](),_0x2ee3a9['vjCanvasContext']['closePath'](),_0x3a40ed['prevX']=_0x3a40ed['x'],_0x3a40ed['prevY']=_0x3a40ed['y']);}),requestAnimationFrame(function(){_0x85c13a['_drawVirtualJoystick']();});},_0x2ee3a9['prototype']['releaseCanvas']=function(){_0x2ee3a9['Canvas']&&(_0x2ee3a9['Canvas']['removeEventListener']('pointerdown',this['_onPointerDownHandlerRef']),_0x2ee3a9['Canvas']['removeEventListener']('pointermove',this['_onPointerMoveHandlerRef']),_0x2ee3a9['Canvas']['removeEventListener']('pointerup',this['_onPointerUpHandlerRef']),_0x2ee3a9['Canvas']['removeEventListener']('pointerout',this['_onPointerUpHandlerRef']),window['removeEventListener']('resize',this['_onResize']),document['body']['removeChild'](_0x2ee3a9['Canvas']),_0x2ee3a9['Canvas']=null);},_0x2ee3a9['_globalJoystickIndex']=0x0,_0x2ee3a9['_alwaysVisibleSticks']=0x0,_0x2ee3a9;}());_0x3d384c['prototype']['addVirtualJoystick']=function(){return this['add'](new _0x359913()),this;};var _0x359913=(function(){function _0x89cdbd(){}return _0x89cdbd['prototype']['getLeftJoystick']=function(){return this['_leftjoystick'];},_0x89cdbd['prototype']['getRightJoystick']=function(){return this['_rightjoystick'];},_0x89cdbd['prototype']['checkInputs']=function(){if(this['_leftjoystick']){var _0x271024=this['camera'],_0x4781fb=0x32*_0x271024['_computeLocalCameraSpeed'](),_0x40bdc5=_0x74d525['a']['RotationYawPitchRoll'](_0x271024['rotation']['y'],_0x271024['rotation']['x'],0x0),_0xe594b0=_0x74d525['e']['TransformCoordinates'](new _0x74d525['e'](this['_leftjoystick']['deltaPosition']['x']*_0x4781fb,this['_leftjoystick']['deltaPosition']['y']*_0x4781fb,this['_leftjoystick']['deltaPosition']['z']*_0x4781fb),_0x40bdc5);_0x271024['cameraDirection']=_0x271024['cameraDirection']['add'](_0xe594b0),_0x271024['cameraRotation']=_0x271024['cameraRotation']['addVector3'](this['_rightjoystick']['deltaPosition']),this['_leftjoystick']['pressed']||(this['_leftjoystick']['deltaPosition']=this['_leftjoystick']['deltaPosition']['scale'](0.9)),this['_rightjoystick']['pressed']||(this['_rightjoystick']['deltaPosition']=this['_rightjoystick']['deltaPosition']['scale'](0.9));}},_0x89cdbd['prototype']['attachControl']=function(){this['_leftjoystick']=new _0x2fab61(!0x0),this['_leftjoystick']['setAxisForUpDown'](_0x15bf12['Z']),this['_leftjoystick']['setAxisForLeftRight'](_0x15bf12['X']),this['_leftjoystick']['setJoystickSensibility'](0.15),this['_rightjoystick']=new _0x2fab61(!0x1),this['_rightjoystick']['setAxisForUpDown'](_0x15bf12['X']),this['_rightjoystick']['setAxisForLeftRight'](_0x15bf12['Y']),this['_rightjoystick']['reverseUpDown']=!0x0,this['_rightjoystick']['setJoystickSensibility'](0.05),this['_rightjoystick']['setJoystickColor']('yellow');},_0x89cdbd['prototype']['detachControl']=function(_0x1178fd){this['_leftjoystick']['releaseCanvas'](),this['_rightjoystick']['releaseCanvas']();},_0x89cdbd['prototype']['getClassName']=function(){return'FreeCameraVirtualJoystickInput';},_0x89cdbd['prototype']['getSimpleName']=function(){return'virtualJoystick';},_0x89cdbd;}());_0x2f54c9['FreeCameraVirtualJoystickInput']=_0x359913;var _0x27da6e=_0x162675(0x1c),_0x5f32ae=function(_0x1e6e5e){function _0x520d39(_0x2c8503,_0xd3e69f,_0x2dfcf3,_0x230135){void 0x0===_0x230135&&(_0x230135=!0x0);var _0x25698f=_0x1e6e5e['call'](this,_0x2c8503,_0xd3e69f,_0x2dfcf3,_0x230135)||this;return _0x25698f['_tmpUpVector']=_0x74d525['e']['Zero'](),_0x25698f['_tmpTargetVector']=_0x74d525['e']['Zero'](),_0x25698f['cameraDirection']=new _0x74d525['e'](0x0,0x0,0x0),_0x25698f['cameraRotation']=new _0x74d525['d'](0x0,0x0),_0x25698f['ignoreParentScaling']=!0x1,_0x25698f['updateUpVectorFromRotation']=!0x1,_0x25698f['_tmpQuaternion']=new _0x74d525['b'](),_0x25698f['rotation']=new _0x74d525['e'](0x0,0x0,0x0),_0x25698f['speed']=0x2,_0x25698f['noRotationConstraint']=!0x1,_0x25698f['invertRotation']=!0x1,_0x25698f['inverseRotationSpeed']=0.2,_0x25698f['lockedTarget']=null,_0x25698f['_currentTarget']=_0x74d525['e']['Zero'](),_0x25698f['_initialFocalDistance']=0x1,_0x25698f['_viewMatrix']=_0x74d525['a']['Zero'](),_0x25698f['_camMatrix']=_0x74d525['a']['Zero'](),_0x25698f['_cameraTransformMatrix']=_0x74d525['a']['Zero'](),_0x25698f['_cameraRotationMatrix']=_0x74d525['a']['Zero'](),_0x25698f['_referencePoint']=new _0x74d525['e'](0x0,0x0,0x1),_0x25698f['_transformedReferencePoint']=_0x74d525['e']['Zero'](),_0x25698f['_defaultUp']=_0x74d525['e']['Up'](),_0x25698f['_cachedRotationZ']=0x0,_0x25698f['_cachedQuaternionRotationZ']=0x0,_0x25698f;}return Object(_0x18e13d['d'])(_0x520d39,_0x1e6e5e),_0x520d39['prototype']['getFrontPosition']=function(_0x5c28e0){this['getWorldMatrix']();var _0x5aca27=this['getTarget']()['subtract'](this['position']);return _0x5aca27['normalize'](),_0x5aca27['scaleInPlace'](_0x5c28e0),this['globalPosition']['add'](_0x5aca27);},_0x520d39['prototype']['_getLockedTargetPosition']=function(){return this['lockedTarget']?(this['lockedTarget']['absolutePosition']&&this['lockedTarget']['computeWorldMatrix'](),this['lockedTarget']['absolutePosition']||this['lockedTarget']):null;},_0x520d39['prototype']['storeState']=function(){return this['_storedPosition']=this['position']['clone'](),this['_storedRotation']=this['rotation']['clone'](),this['rotationQuaternion']&&(this['_storedRotationQuaternion']=this['rotationQuaternion']['clone']()),_0x1e6e5e['prototype']['storeState']['call'](this);},_0x520d39['prototype']['_restoreStateValues']=function(){return!!_0x1e6e5e['prototype']['_restoreStateValues']['call'](this)&&(this['position']=this['_storedPosition']['clone'](),this['rotation']=this['_storedRotation']['clone'](),this['rotationQuaternion']&&(this['rotationQuaternion']=this['_storedRotationQuaternion']['clone']()),this['cameraDirection']['copyFromFloats'](0x0,0x0,0x0),this['cameraRotation']['copyFromFloats'](0x0,0x0),!0x0);},_0x520d39['prototype']['_initCache']=function(){_0x1e6e5e['prototype']['_initCache']['call'](this),this['_cache']['lockedTarget']=new _0x74d525['e'](Number['MAX_VALUE'],Number['MAX_VALUE'],Number['MAX_VALUE']),this['_cache']['rotation']=new _0x74d525['e'](Number['MAX_VALUE'],Number['MAX_VALUE'],Number['MAX_VALUE']),this['_cache']['rotationQuaternion']=new _0x74d525['b'](Number['MAX_VALUE'],Number['MAX_VALUE'],Number['MAX_VALUE'],Number['MAX_VALUE']);},_0x520d39['prototype']['_updateCache']=function(_0x11c2c4){_0x11c2c4||_0x1e6e5e['prototype']['_updateCache']['call'](this);var _0x3db451=this['_getLockedTargetPosition']();_0x3db451?this['_cache']['lockedTarget']?this['_cache']['lockedTarget']['copyFrom'](_0x3db451):this['_cache']['lockedTarget']=_0x3db451['clone']():this['_cache']['lockedTarget']=null,this['_cache']['rotation']['copyFrom'](this['rotation']),this['rotationQuaternion']&&this['_cache']['rotationQuaternion']['copyFrom'](this['rotationQuaternion']);},_0x520d39['prototype']['_isSynchronizedViewMatrix']=function(){if(!_0x1e6e5e['prototype']['_isSynchronizedViewMatrix']['call'](this))return!0x1;var _0x3da0c7=this['_getLockedTargetPosition']();return(this['_cache']['lockedTarget']?this['_cache']['lockedTarget']['equals'](_0x3da0c7):!_0x3da0c7)&&(this['rotationQuaternion']?this['rotationQuaternion']['equals'](this['_cache']['rotationQuaternion']):this['_cache']['rotation']['equals'](this['rotation']));},_0x520d39['prototype']['_computeLocalCameraSpeed']=function(){var _0x34b556=this['getEngine']();return this['speed']*Math['sqrt'](_0x34b556['getDeltaTime']()/(0x64*_0x34b556['getFps']()));},_0x520d39['prototype']['setTarget']=function(_0x53f5f8){this['upVector']['normalize'](),this['_initialFocalDistance']=_0x53f5f8['subtract'](this['position'])['length'](),this['position']['z']===_0x53f5f8['z']&&(this['position']['z']+=_0x27da6e['a']),this['_referencePoint']['normalize']()['scaleInPlace'](this['_initialFocalDistance']),_0x74d525['a']['LookAtLHToRef'](this['position'],_0x53f5f8,this['_defaultUp'],this['_camMatrix']),this['_camMatrix']['invert'](),this['rotation']['x']=Math['atan'](this['_camMatrix']['m'][0x6]/this['_camMatrix']['m'][0xa]);var _0x413d97=_0x53f5f8['subtract'](this['position']);_0x413d97['x']>=0x0?this['rotation']['y']=-Math['atan'](_0x413d97['z']/_0x413d97['x'])+Math['PI']/0x2:this['rotation']['y']=-Math['atan'](_0x413d97['z']/_0x413d97['x'])-Math['PI']/0x2,this['rotation']['z']=0x0,isNaN(this['rotation']['x'])&&(this['rotation']['x']=0x0),isNaN(this['rotation']['y'])&&(this['rotation']['y']=0x0),isNaN(this['rotation']['z'])&&(this['rotation']['z']=0x0),this['rotationQuaternion']&&_0x74d525['b']['RotationYawPitchRollToRef'](this['rotation']['y'],this['rotation']['x'],this['rotation']['z'],this['rotationQuaternion']);},Object['defineProperty'](_0x520d39['prototype'],'target',{'get':function(){return this['getTarget']();},'set':function(_0xecbf31){this['setTarget'](_0xecbf31);},'enumerable':!0x1,'configurable':!0x0}),_0x520d39['prototype']['getTarget']=function(){return this['_currentTarget'];},_0x520d39['prototype']['_decideIfNeedsToMove']=function(){return Math['abs'](this['cameraDirection']['x'])>0x0||Math['abs'](this['cameraDirection']['y'])>0x0||Math['abs'](this['cameraDirection']['z'])>0x0;},_0x520d39['prototype']['_updatePosition']=function(){if(this['parent'])return this['parent']['getWorldMatrix']()['invertToRef'](_0x74d525['c']['Matrix'][0x0]),_0x74d525['e']['TransformNormalToRef'](this['cameraDirection'],_0x74d525['c']['Matrix'][0x0],_0x74d525['c']['Vector3'][0x0]),void this['position']['addInPlace'](_0x74d525['c']['Vector3'][0x0]);this['position']['addInPlace'](this['cameraDirection']);},_0x520d39['prototype']['_checkInputs']=function(){var _0x506e92=this['invertRotation']?-this['inverseRotationSpeed']:0x1,_0x38354c=this['_decideIfNeedsToMove'](),_0x3e8ea2=Math['abs'](this['cameraRotation']['x'])>0x0||Math['abs'](this['cameraRotation']['y'])>0x0;if(_0x38354c&&this['_updatePosition'](),_0x3e8ea2){(this['rotationQuaternion']&&this['rotationQuaternion']['toEulerAnglesToRef'](this['rotation']),this['rotation']['x']+=this['cameraRotation']['x']*_0x506e92,this['rotation']['y']+=this['cameraRotation']['y']*_0x506e92,!this['noRotationConstraint'])&&(this['rotation']['x']>1.570796&&(this['rotation']['x']=1.570796),this['rotation']['x']<-1.570796&&(this['rotation']['x']=-1.570796));if(this['rotationQuaternion'])this['rotation']['lengthSquared']()&&_0x74d525['b']['RotationYawPitchRollToRef'](this['rotation']['y'],this['rotation']['x'],this['rotation']['z'],this['rotationQuaternion']);}_0x38354c&&(Math['abs'](this['cameraDirection']['x'])_0x300b38['a']['CollisionsEpsilon']&&(_0x42e521['position']['addInPlace'](_0x42e521['_diffPosition']),_0x42e521['onCollide']&&_0x51bc8a&&_0x42e521['onCollide'](_0x51bc8a));},_0x42e521['inputs']=new _0x3d384c(_0x42e521),_0x42e521['inputs']['addKeyboard']()['addMouse'](),_0x42e521;}return Object(_0x18e13d['d'])(_0x40c5b5,_0x19ad60),Object['defineProperty'](_0x40c5b5['prototype'],'angularSensibility',{'get':function(){var _0x4f7f1c=this['inputs']['attached']['mouse'];return _0x4f7f1c?_0x4f7f1c['angularSensibility']:0x0;},'set':function(_0x4f1776){var _0x155dce=this['inputs']['attached']['mouse'];_0x155dce&&(_0x155dce['angularSensibility']=_0x4f1776);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x40c5b5['prototype'],'keysUp',{'get':function(){var _0x352c01=this['inputs']['attached']['keyboard'];return _0x352c01?_0x352c01['keysUp']:[];},'set':function(_0x3526f1){var _0x2f121b=this['inputs']['attached']['keyboard'];_0x2f121b&&(_0x2f121b['keysUp']=_0x3526f1);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x40c5b5['prototype'],'keysUpward',{'get':function(){var _0x3013e0=this['inputs']['attached']['keyboard'];return _0x3013e0?_0x3013e0['keysUpward']:[];},'set':function(_0x3cb6df){var _0x34f3f1=this['inputs']['attached']['keyboard'];_0x34f3f1&&(_0x34f3f1['keysUpward']=_0x3cb6df);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x40c5b5['prototype'],'keysDown',{'get':function(){var _0x5c0212=this['inputs']['attached']['keyboard'];return _0x5c0212?_0x5c0212['keysDown']:[];},'set':function(_0x2d19aa){var _0x32ec1b=this['inputs']['attached']['keyboard'];_0x32ec1b&&(_0x32ec1b['keysDown']=_0x2d19aa);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x40c5b5['prototype'],'keysDownward',{'get':function(){var _0x210956=this['inputs']['attached']['keyboard'];return _0x210956?_0x210956['keysDownward']:[];},'set':function(_0x4086f7){var _0x1823c9=this['inputs']['attached']['keyboard'];_0x1823c9&&(_0x1823c9['keysDownward']=_0x4086f7);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x40c5b5['prototype'],'keysLeft',{'get':function(){var _0x4f1e04=this['inputs']['attached']['keyboard'];return _0x4f1e04?_0x4f1e04['keysLeft']:[];},'set':function(_0x60632a){var _0x5dcd9a=this['inputs']['attached']['keyboard'];_0x5dcd9a&&(_0x5dcd9a['keysLeft']=_0x60632a);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x40c5b5['prototype'],'keysRight',{'get':function(){var _0x37e41a=this['inputs']['attached']['keyboard'];return _0x37e41a?_0x37e41a['keysRight']:[];},'set':function(_0x4c70ef){var _0x16a373=this['inputs']['attached']['keyboard'];_0x16a373&&(_0x16a373['keysRight']=_0x4c70ef);},'enumerable':!0x1,'configurable':!0x0}),_0x40c5b5['prototype']['attachControl']=function(_0x84097b,_0x523b23){_0x523b23=_0x5d754c['b']['BackCompatCameraNoPreventDefault'](arguments),this['inputs']['attachElement'](_0x523b23);},_0x40c5b5['prototype']['detachControl']=function(_0x4ef6b3){this['inputs']['detachElement'](),this['cameraDirection']=new _0x74d525['e'](0x0,0x0,0x0),this['cameraRotation']=new _0x74d525['d'](0x0,0x0);},Object['defineProperty'](_0x40c5b5['prototype'],'collisionMask',{'get':function(){return this['_collisionMask'];},'set':function(_0xac9c33){this['_collisionMask']=isNaN(_0xac9c33)?-0x1:_0xac9c33;},'enumerable':!0x1,'configurable':!0x0}),_0x40c5b5['prototype']['_collideWithWorld']=function(_0x2201ee){(this['parent']?_0x74d525['e']['TransformCoordinates'](this['position'],this['parent']['getWorldMatrix']()):this['position'])['subtractFromFloatsToRef'](0x0,this['ellipsoid']['y'],0x0,this['_oldPosition']),this['_oldPosition']['addInPlace'](this['ellipsoidOffset']);var _0x393da2=this['getScene']()['collisionCoordinator'];this['_collider']||(this['_collider']=_0x393da2['createCollider']()),this['_collider']['_radius']=this['ellipsoid'],this['_collider']['collisionMask']=this['_collisionMask'];var _0x3757ef=_0x2201ee;this['applyGravity']&&(_0x3757ef=_0x2201ee['add'](this['getScene']()['gravity'])),_0x393da2['getNewPosition'](this['_oldPosition'],_0x3757ef,this['_collider'],0x3,null,this['_onCollisionPositionChange'],this['uniqueId']);},_0x40c5b5['prototype']['_checkInputs']=function(){this['_localDirection']||(this['_localDirection']=_0x74d525['e']['Zero'](),this['_transformedDirection']=_0x74d525['e']['Zero']()),this['inputs']['checkInputs'](),_0x19ad60['prototype']['_checkInputs']['call'](this);},_0x40c5b5['prototype']['_decideIfNeedsToMove']=function(){return this['_needMoveForGravity']||Math['abs'](this['cameraDirection']['x'])>0x0||Math['abs'](this['cameraDirection']['y'])>0x0||Math['abs'](this['cameraDirection']['z'])>0x0;},_0x40c5b5['prototype']['_updatePosition']=function(){this['checkCollisions']&&this['getScene']()['collisionsEnabled']?this['_collideWithWorld'](this['cameraDirection']):_0x19ad60['prototype']['_updatePosition']['call'](this);},_0x40c5b5['prototype']['dispose']=function(){this['inputs']['clear'](),_0x19ad60['prototype']['dispose']['call'](this);},_0x40c5b5['prototype']['getClassName']=function(){return'FreeCamera';},Object(_0x18e13d['c'])([Object(_0x495d06['o'])()],_0x40c5b5['prototype'],'ellipsoid',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['o'])()],_0x40c5b5['prototype'],'ellipsoidOffset',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x40c5b5['prototype'],'checkCollisions',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x40c5b5['prototype'],'applyGravity',void 0x0),_0x40c5b5;}(_0x5f32ae);_0x43169a['a']['AddNodeConstructor']('TouchCamera',function(_0x44afe4,_0x74f8e0){return function(){return new _0x593a2c(_0x44afe4,_0x74d525['e']['Zero'](),_0x74f8e0);};});var _0x593a2c=function(_0x3eff93){function _0x3a1dfd(_0x1250cf,_0x4c0caf,_0x22a3ac){var _0xdc8138=_0x3eff93['call'](this,_0x1250cf,_0x4c0caf,_0x22a3ac)||this;return _0xdc8138['inputs']['addTouch'](),_0xdc8138['_setupInputs'](),_0xdc8138;}return Object(_0x18e13d['d'])(_0x3a1dfd,_0x3eff93),Object['defineProperty'](_0x3a1dfd['prototype'],'touchAngularSensibility',{'get':function(){var _0x186291=this['inputs']['attached']['touch'];return _0x186291?_0x186291['touchAngularSensibility']:0x0;},'set':function(_0x38df5c){var _0x4ed0e8=this['inputs']['attached']['touch'];_0x4ed0e8&&(_0x4ed0e8['touchAngularSensibility']=_0x38df5c);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3a1dfd['prototype'],'touchMoveSensibility',{'get':function(){var _0x25b0ab=this['inputs']['attached']['touch'];return _0x25b0ab?_0x25b0ab['touchMoveSensibility']:0x0;},'set':function(_0x46881b){var _0x17798a=this['inputs']['attached']['touch'];_0x17798a&&(_0x17798a['touchMoveSensibility']=_0x46881b);},'enumerable':!0x1,'configurable':!0x0}),_0x3a1dfd['prototype']['getClassName']=function(){return'TouchCamera';},_0x3a1dfd['prototype']['_setupInputs']=function(){var _0x344aa7=this['inputs']['attached']['touch'],_0x391d71=this['inputs']['attached']['mouse'];_0x391d71?_0x391d71['touchEnabled']=!0x1:_0x344aa7['allowMouse']=!0x0;},_0x3a1dfd;}(_0x5625b9);_0x43169a['a']['AddNodeConstructor']('ArcRotateCamera',function(_0x2eb399,_0xb18109){return function(){return new _0xe57e08(_0x2eb399,0x0,0x0,0x1,_0x74d525['e']['Zero'](),_0xb18109);};});var _0xe57e08=function(_0x283b6e){function _0x218ba2(_0x526b71,_0xd1f372,_0xee0f4f,_0x57baaa,_0x59b7f3,_0x44450a,_0x143bab){void 0x0===_0x143bab&&(_0x143bab=!0x0);var _0x16b1ed=_0x283b6e['call'](this,_0x526b71,_0x74d525['e']['Zero'](),_0x44450a,_0x143bab)||this;return _0x16b1ed['inertialAlphaOffset']=0x0,_0x16b1ed['inertialBetaOffset']=0x0,_0x16b1ed['inertialRadiusOffset']=0x0,_0x16b1ed['lowerAlphaLimit']=null,_0x16b1ed['upperAlphaLimit']=null,_0x16b1ed['lowerBetaLimit']=0.01,_0x16b1ed['upperBetaLimit']=Math['PI']-0.01,_0x16b1ed['lowerRadiusLimit']=null,_0x16b1ed['upperRadiusLimit']=null,_0x16b1ed['inertialPanningX']=0x0,_0x16b1ed['inertialPanningY']=0x0,_0x16b1ed['pinchToPanMaxDistance']=0x14,_0x16b1ed['panningDistanceLimit']=null,_0x16b1ed['panningOriginTarget']=_0x74d525['e']['Zero'](),_0x16b1ed['panningInertia']=0.9,_0x16b1ed['zoomOnFactor']=0x1,_0x16b1ed['targetScreenOffset']=_0x74d525['d']['Zero'](),_0x16b1ed['allowUpsideDown']=!0x0,_0x16b1ed['useInputToRestoreState']=!0x0,_0x16b1ed['_viewMatrix']=new _0x74d525['a'](),_0x16b1ed['panningAxis']=new _0x74d525['e'](0x1,0x1,0x0),_0x16b1ed['onMeshTargetChangedObservable']=new _0x6ac1f7['c'](),_0x16b1ed['checkCollisions']=!0x1,_0x16b1ed['collisionRadius']=new _0x74d525['e'](0.5,0.5,0.5),_0x16b1ed['_previousPosition']=_0x74d525['e']['Zero'](),_0x16b1ed['_collisionVelocity']=_0x74d525['e']['Zero'](),_0x16b1ed['_newPosition']=_0x74d525['e']['Zero'](),_0x16b1ed['_computationVector']=_0x74d525['e']['Zero'](),_0x16b1ed['_onCollisionPositionChange']=function(_0x2a3802,_0x242410,_0xaa149e){void 0x0===_0xaa149e&&(_0xaa149e=null),_0xaa149e?(_0x16b1ed['setPosition'](_0x242410),_0x16b1ed['onCollide']&&_0x16b1ed['onCollide'](_0xaa149e)):_0x16b1ed['_previousPosition']['copyFrom'](_0x16b1ed['_position']);var _0x5c1c64=Math['cos'](_0x16b1ed['alpha']),_0x5a5861=Math['sin'](_0x16b1ed['alpha']),_0x18a950=Math['cos'](_0x16b1ed['beta']),_0x1a346b=Math['sin'](_0x16b1ed['beta']);0x0===_0x1a346b&&(_0x1a346b=0.0001);var _0x43d652=_0x16b1ed['_getTargetPosition']();_0x16b1ed['_computationVector']['copyFromFloats'](_0x16b1ed['radius']*_0x5c1c64*_0x1a346b,_0x16b1ed['radius']*_0x18a950,_0x16b1ed['radius']*_0x5a5861*_0x1a346b),_0x43d652['addToRef'](_0x16b1ed['_computationVector'],_0x16b1ed['_newPosition']),_0x16b1ed['_position']['copyFrom'](_0x16b1ed['_newPosition']);var _0x2ea2de=_0x16b1ed['upVector'];_0x16b1ed['allowUpsideDown']&&_0x16b1ed['beta']<0x0&&(_0x2ea2de=(_0x2ea2de=_0x2ea2de['clone']())['negate']()),_0x16b1ed['_computeViewMatrix'](_0x16b1ed['_position'],_0x43d652,_0x2ea2de),_0x16b1ed['_viewMatrix']['addAtIndex'](0xc,_0x16b1ed['targetScreenOffset']['x']),_0x16b1ed['_viewMatrix']['addAtIndex'](0xd,_0x16b1ed['targetScreenOffset']['y']),_0x16b1ed['_collisionTriggered']=!0x1;},_0x16b1ed['_target']=_0x74d525['e']['Zero'](),_0x59b7f3&&_0x16b1ed['setTarget'](_0x59b7f3),_0x16b1ed['alpha']=_0xd1f372,_0x16b1ed['beta']=_0xee0f4f,_0x16b1ed['radius']=_0x57baaa,_0x16b1ed['getViewMatrix'](),_0x16b1ed['inputs']=new _0x1f548e(_0x16b1ed),_0x16b1ed['inputs']['addKeyboard']()['addMouseWheel']()['addPointers'](),_0x16b1ed;}return Object(_0x18e13d['d'])(_0x218ba2,_0x283b6e),Object['defineProperty'](_0x218ba2['prototype'],'target',{'get':function(){return this['_target'];},'set':function(_0x4542b4){this['setTarget'](_0x4542b4);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x218ba2['prototype'],'position',{'get':function(){return this['_position'];},'set':function(_0x2d1737){this['setPosition'](_0x2d1737);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x218ba2['prototype'],'upVector',{'get':function(){return this['_upVector'];},'set':function(_0x334575){this['_upToYMatrix']||(this['_YToUpMatrix']=new _0x74d525['a'](),this['_upToYMatrix']=new _0x74d525['a'](),this['_upVector']=_0x74d525['e']['Zero']()),_0x334575['normalize'](),this['_upVector']['copyFrom'](_0x334575),this['setMatUp']();},'enumerable':!0x1,'configurable':!0x0}),_0x218ba2['prototype']['setMatUp']=function(){_0x74d525['a']['RotationAlignToRef'](_0x74d525['e']['UpReadOnly'],this['_upVector'],this['_YToUpMatrix']),_0x74d525['a']['RotationAlignToRef'](this['_upVector'],_0x74d525['e']['UpReadOnly'],this['_upToYMatrix']);},Object['defineProperty'](_0x218ba2['prototype'],'angularSensibilityX',{'get':function(){var _0x118cb4=this['inputs']['attached']['pointers'];return _0x118cb4?_0x118cb4['angularSensibilityX']:0x0;},'set':function(_0x4ed042){var _0x51ed06=this['inputs']['attached']['pointers'];_0x51ed06&&(_0x51ed06['angularSensibilityX']=_0x4ed042);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x218ba2['prototype'],'angularSensibilityY',{'get':function(){var _0x3a05d6=this['inputs']['attached']['pointers'];return _0x3a05d6?_0x3a05d6['angularSensibilityY']:0x0;},'set':function(_0x5bce04){var _0x21eaf2=this['inputs']['attached']['pointers'];_0x21eaf2&&(_0x21eaf2['angularSensibilityY']=_0x5bce04);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x218ba2['prototype'],'pinchPrecision',{'get':function(){var _0x552b42=this['inputs']['attached']['pointers'];return _0x552b42?_0x552b42['pinchPrecision']:0x0;},'set':function(_0x42f916){var _0x14ad86=this['inputs']['attached']['pointers'];_0x14ad86&&(_0x14ad86['pinchPrecision']=_0x42f916);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x218ba2['prototype'],'pinchDeltaPercentage',{'get':function(){var _0xc9624c=this['inputs']['attached']['pointers'];return _0xc9624c?_0xc9624c['pinchDeltaPercentage']:0x0;},'set':function(_0x2b97ad){var _0x5b6373=this['inputs']['attached']['pointers'];_0x5b6373&&(_0x5b6373['pinchDeltaPercentage']=_0x2b97ad);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x218ba2['prototype'],'useNaturalPinchZoom',{'get':function(){var _0x5a39a5=this['inputs']['attached']['pointers'];return!!_0x5a39a5&&_0x5a39a5['useNaturalPinchZoom'];},'set':function(_0x1596fb){var _0x355410=this['inputs']['attached']['pointers'];_0x355410&&(_0x355410['useNaturalPinchZoom']=_0x1596fb);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x218ba2['prototype'],'panningSensibility',{'get':function(){var _0x56106f=this['inputs']['attached']['pointers'];return _0x56106f?_0x56106f['panningSensibility']:0x0;},'set':function(_0x3afcc6){var _0x28f159=this['inputs']['attached']['pointers'];_0x28f159&&(_0x28f159['panningSensibility']=_0x3afcc6);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x218ba2['prototype'],'keysUp',{'get':function(){var _0x5b9648=this['inputs']['attached']['keyboard'];return _0x5b9648?_0x5b9648['keysUp']:[];},'set':function(_0x472067){var _0x389bad=this['inputs']['attached']['keyboard'];_0x389bad&&(_0x389bad['keysUp']=_0x472067);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x218ba2['prototype'],'keysDown',{'get':function(){var _0x559527=this['inputs']['attached']['keyboard'];return _0x559527?_0x559527['keysDown']:[];},'set':function(_0x1a26f4){var _0x4cfbc4=this['inputs']['attached']['keyboard'];_0x4cfbc4&&(_0x4cfbc4['keysDown']=_0x1a26f4);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x218ba2['prototype'],'keysLeft',{'get':function(){var _0x23a594=this['inputs']['attached']['keyboard'];return _0x23a594?_0x23a594['keysLeft']:[];},'set':function(_0x43354b){var _0x415d82=this['inputs']['attached']['keyboard'];_0x415d82&&(_0x415d82['keysLeft']=_0x43354b);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x218ba2['prototype'],'keysRight',{'get':function(){var _0x38622f=this['inputs']['attached']['keyboard'];return _0x38622f?_0x38622f['keysRight']:[];},'set':function(_0x16ee94){var _0x1fe424=this['inputs']['attached']['keyboard'];_0x1fe424&&(_0x1fe424['keysRight']=_0x16ee94);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x218ba2['prototype'],'wheelPrecision',{'get':function(){var _0x18ebaa=this['inputs']['attached']['mousewheel'];return _0x18ebaa?_0x18ebaa['wheelPrecision']:0x0;},'set':function(_0x49979c){var _0x55aec1=this['inputs']['attached']['mousewheel'];_0x55aec1&&(_0x55aec1['wheelPrecision']=_0x49979c);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x218ba2['prototype'],'wheelDeltaPercentage',{'get':function(){var _0x436c72=this['inputs']['attached']['mousewheel'];return _0x436c72?_0x436c72['wheelDeltaPercentage']:0x0;},'set':function(_0x2bc73c){var _0x225d66=this['inputs']['attached']['mousewheel'];_0x225d66&&(_0x225d66['wheelDeltaPercentage']=_0x2bc73c);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x218ba2['prototype'],'bouncingBehavior',{'get':function(){return this['_bouncingBehavior'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x218ba2['prototype'],'useBouncingBehavior',{'get':function(){return null!=this['_bouncingBehavior'];},'set':function(_0x26fbe5){_0x26fbe5!==this['useBouncingBehavior']&&(_0x26fbe5?(this['_bouncingBehavior']=new _0x3e9056(),this['addBehavior'](this['_bouncingBehavior'])):this['_bouncingBehavior']&&(this['removeBehavior'](this['_bouncingBehavior']),this['_bouncingBehavior']=null));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x218ba2['prototype'],'framingBehavior',{'get':function(){return this['_framingBehavior'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x218ba2['prototype'],'useFramingBehavior',{'get':function(){return null!=this['_framingBehavior'];},'set':function(_0x2c10ff){_0x2c10ff!==this['useFramingBehavior']&&(_0x2c10ff?(this['_framingBehavior']=new _0x593fc5(),this['addBehavior'](this['_framingBehavior'])):this['_framingBehavior']&&(this['removeBehavior'](this['_framingBehavior']),this['_framingBehavior']=null));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x218ba2['prototype'],'autoRotationBehavior',{'get':function(){return this['_autoRotationBehavior'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x218ba2['prototype'],'useAutoRotationBehavior',{'get':function(){return null!=this['_autoRotationBehavior'];},'set':function(_0x4f5aae){_0x4f5aae!==this['useAutoRotationBehavior']&&(_0x4f5aae?(this['_autoRotationBehavior']=new _0x47605d(),this['addBehavior'](this['_autoRotationBehavior'])):this['_autoRotationBehavior']&&(this['removeBehavior'](this['_autoRotationBehavior']),this['_autoRotationBehavior']=null));},'enumerable':!0x1,'configurable':!0x0}),_0x218ba2['prototype']['_initCache']=function(){_0x283b6e['prototype']['_initCache']['call'](this),this['_cache']['_target']=new _0x74d525['e'](Number['MAX_VALUE'],Number['MAX_VALUE'],Number['MAX_VALUE']),this['_cache']['alpha']=void 0x0,this['_cache']['beta']=void 0x0,this['_cache']['radius']=void 0x0,this['_cache']['targetScreenOffset']=_0x74d525['d']['Zero']();},_0x218ba2['prototype']['_updateCache']=function(_0x4f86c4){_0x4f86c4||_0x283b6e['prototype']['_updateCache']['call'](this),this['_cache']['_target']['copyFrom'](this['_getTargetPosition']()),this['_cache']['alpha']=this['alpha'],this['_cache']['beta']=this['beta'],this['_cache']['radius']=this['radius'],this['_cache']['targetScreenOffset']['copyFrom'](this['targetScreenOffset']);},_0x218ba2['prototype']['_getTargetPosition']=function(){if(this['_targetHost']&&this['_targetHost']['getAbsolutePosition']){var _0x530eb1=this['_targetHost']['absolutePosition'];this['_targetBoundingCenter']?_0x530eb1['addToRef'](this['_targetBoundingCenter'],this['_target']):this['_target']['copyFrom'](_0x530eb1);}var _0x1ddd33=this['_getLockedTargetPosition']();return _0x1ddd33||this['_target'];},_0x218ba2['prototype']['storeState']=function(){return this['_storedAlpha']=this['alpha'],this['_storedBeta']=this['beta'],this['_storedRadius']=this['radius'],this['_storedTarget']=this['_getTargetPosition']()['clone'](),this['_storedTargetScreenOffset']=this['targetScreenOffset']['clone'](),_0x283b6e['prototype']['storeState']['call'](this);},_0x218ba2['prototype']['_restoreStateValues']=function(){return!!_0x283b6e['prototype']['_restoreStateValues']['call'](this)&&(this['setTarget'](this['_storedTarget']['clone']()),this['alpha']=this['_storedAlpha'],this['beta']=this['_storedBeta'],this['radius']=this['_storedRadius'],this['targetScreenOffset']=this['_storedTargetScreenOffset']['clone'](),this['inertialAlphaOffset']=0x0,this['inertialBetaOffset']=0x0,this['inertialRadiusOffset']=0x0,this['inertialPanningX']=0x0,this['inertialPanningY']=0x0,!0x0);},_0x218ba2['prototype']['_isSynchronizedViewMatrix']=function(){return!!_0x283b6e['prototype']['_isSynchronizedViewMatrix']['call'](this)&&(this['_cache']['_target']['equals'](this['_getTargetPosition']())&&this['_cache']['alpha']===this['alpha']&&this['_cache']['beta']===this['beta']&&this['_cache']['radius']===this['radius']&&this['_cache']['targetScreenOffset']['equals'](this['targetScreenOffset']));},_0x218ba2['prototype']['attachControl']=function(_0x321b30,_0x8fcb93,_0x115468,_0x30763f){var _0x24d0c7=this;void 0x0===_0x115468&&(_0x115468=!0x0),void 0x0===_0x30763f&&(_0x30763f=0x2),_0x8fcb93=_0x5d754c['b']['BackCompatCameraNoPreventDefault'](arguments),this['_useCtrlForPanning']=_0x115468,this['_panningMouseButton']=_0x30763f,'boolean'==typeof arguments[0x0]&&(arguments['length']>0x1&&(this['_useCtrlForPanning']=arguments[0x1]),arguments['length']>0x2&&(this['_panningMouseButton']=arguments[0x2])),this['inputs']['attachElement'](_0x8fcb93),this['_reset']=function(){_0x24d0c7['inertialAlphaOffset']=0x0,_0x24d0c7['inertialBetaOffset']=0x0,_0x24d0c7['inertialRadiusOffset']=0x0,_0x24d0c7['inertialPanningX']=0x0,_0x24d0c7['inertialPanningY']=0x0;};},_0x218ba2['prototype']['detachControl']=function(_0x22e90a){this['inputs']['detachElement'](),this['_reset']&&this['_reset']();},_0x218ba2['prototype']['_checkInputs']=function(){if(!this['_collisionTriggered']){if(this['inputs']['checkInputs'](),0x0!==this['inertialAlphaOffset']||0x0!==this['inertialBetaOffset']||0x0!==this['inertialRadiusOffset']){var _0x5876b1=this['inertialAlphaOffset'];this['beta']<=0x0&&(_0x5876b1*=-0x1),this['getScene']()['useRightHandedSystem']&&(_0x5876b1*=-0x1),this['parent']&&this['parent']['_getWorldMatrixDeterminant']()<0x0&&(_0x5876b1*=-0x1),this['alpha']+=_0x5876b1,this['beta']+=this['inertialBetaOffset'],this['radius']-=this['inertialRadiusOffset'],this['inertialAlphaOffset']*=this['inertia'],this['inertialBetaOffset']*=this['inertia'],this['inertialRadiusOffset']*=this['inertia'],Math['abs'](this['inertialAlphaOffset'])<_0x27da6e['a']&&(this['inertialAlphaOffset']=0x0),Math['abs'](this['inertialBetaOffset'])<_0x27da6e['a']&&(this['inertialBetaOffset']=0x0),Math['abs'](this['inertialRadiusOffset'])Math['PI']&&(this['beta']=this['beta']-0x2*Math['PI']):this['beta']this['upperBetaLimit']&&(this['beta']=this['upperBetaLimit']),null!==this['lowerAlphaLimit']&&this['alpha']this['upperAlphaLimit']&&(this['alpha']=this['upperAlphaLimit']),null!==this['lowerRadiusLimit']&&this['radius']this['upperRadiusLimit']&&(this['radius']=this['upperRadiusLimit'],this['inertialRadiusOffset']=0x0);},_0x218ba2['prototype']['rebuildAnglesAndRadius']=function(){this['_position']['subtractToRef'](this['_getTargetPosition'](),this['_computationVector']),0x0===this['_upVector']['x']&&0x1===this['_upVector']['y']&&0x0===this['_upVector']['z']||_0x74d525['e']['TransformCoordinatesToRef'](this['_computationVector'],this['_upToYMatrix'],this['_computationVector']),this['radius']=this['_computationVector']['length'](),0x0===this['radius']&&(this['radius']=0.0001);var _0x370319=this['alpha'];0x0===this['_computationVector']['x']&&0x0===this['_computationVector']['z']?this['alpha']=Math['PI']/0x2:this['alpha']=Math['acos'](this['_computationVector']['x']/Math['sqrt'](Math['pow'](this['_computationVector']['x'],0x2)+Math['pow'](this['_computationVector']['z'],0x2))),this['_computationVector']['z']<0x0&&(this['alpha']=0x2*Math['PI']-this['alpha']);var _0x1f7a48=Math['round']((_0x370319-this['alpha'])/(0x2*Math['PI']));this['alpha']+=0x2*_0x1f7a48*Math['PI'],this['beta']=Math['acos'](this['_computationVector']['y']/this['radius']),this['_checkLimits']();},_0x218ba2['prototype']['setPosition']=function(_0x53cafd){this['_position']['equals'](_0x53cafd)||(this['_position']['copyFrom'](_0x53cafd),this['rebuildAnglesAndRadius']());},_0x218ba2['prototype']['setTarget']=function(_0x4ebf17,_0x2036f6,_0x40ba20){if(void 0x0===_0x2036f6&&(_0x2036f6=!0x1),void 0x0===_0x40ba20&&(_0x40ba20=!0x1),_0x4ebf17['getBoundingInfo'])this['_targetBoundingCenter']=_0x2036f6?_0x4ebf17['getBoundingInfo']()['boundingBox']['centerWorld']['clone']():null,_0x4ebf17['computeWorldMatrix'](),this['_targetHost']=_0x4ebf17,this['_target']=this['_getTargetPosition'](),this['onMeshTargetChangedObservable']['notifyObservers'](this['_targetHost']);else{var _0x2312b2=_0x4ebf17,_0x1db5a8=this['_getTargetPosition']();if(_0x1db5a8&&!_0x40ba20&&_0x1db5a8['equals'](_0x2312b2))return;this['_targetHost']=null,this['_target']=_0x2312b2,this['_targetBoundingCenter']=null,this['onMeshTargetChangedObservable']['notifyObservers'](null);}this['rebuildAnglesAndRadius']();},_0x218ba2['prototype']['_getViewMatrix']=function(){var _0x479fd6=Math['cos'](this['alpha']),_0x8485c2=Math['sin'](this['alpha']),_0x36148c=Math['cos'](this['beta']),_0x42082a=Math['sin'](this['beta']);0x0===_0x42082a&&(_0x42082a=0.0001),0x0===this['radius']&&(this['radius']=0.0001);var _0x20f56e=this['_getTargetPosition']();if(this['_computationVector']['copyFromFloats'](this['radius']*_0x479fd6*_0x42082a,this['radius']*_0x36148c,this['radius']*_0x8485c2*_0x42082a),0x0===this['_upVector']['x']&&0x1===this['_upVector']['y']&&0x0===this['_upVector']['z']||_0x74d525['e']['TransformCoordinatesToRef'](this['_computationVector'],this['_YToUpMatrix'],this['_computationVector']),_0x20f56e['addToRef'](this['_computationVector'],this['_newPosition']),this['getScene']()['collisionsEnabled']&&this['checkCollisions']){var _0x20834d=this['getScene']()['collisionCoordinator'];this['_collider']||(this['_collider']=_0x20834d['createCollider']()),this['_collider']['_radius']=this['collisionRadius'],this['_newPosition']['subtractToRef'](this['_position'],this['_collisionVelocity']),this['_collisionTriggered']=!0x0,_0x20834d['getNewPosition'](this['_position'],this['_collisionVelocity'],this['_collider'],0x3,null,this['_onCollisionPositionChange'],this['uniqueId']);}else{this['_position']['copyFrom'](this['_newPosition']);var _0x1c7b66=this['upVector'];this['allowUpsideDown']&&_0x42082a<0x0&&(_0x1c7b66=_0x1c7b66['negate']()),this['_computeViewMatrix'](this['_position'],_0x20f56e,_0x1c7b66),this['_viewMatrix']['addAtIndex'](0xc,this['targetScreenOffset']['x']),this['_viewMatrix']['addAtIndex'](0xd,this['targetScreenOffset']['y']);}return this['_currentTarget']=_0x20f56e,this['_viewMatrix'];},_0x218ba2['prototype']['zoomOn']=function(_0x5c23a6,_0x1bc590){void 0x0===_0x1bc590&&(_0x1bc590=!0x1),_0x5c23a6=_0x5c23a6||this['getScene']()['meshes'];var _0x3fda22=_0x3cf5e5['a']['MinMax'](_0x5c23a6),_0x384d79=_0x74d525['e']['Distance'](_0x3fda22['min'],_0x3fda22['max']);this['radius']=_0x384d79*this['zoomOnFactor'],this['focusOn']({'min':_0x3fda22['min'],'max':_0x3fda22['max'],'distance':_0x384d79},_0x1bc590);},_0x218ba2['prototype']['focusOn']=function(_0x1560aa,_0x4b67f9){var _0x5a1cfa,_0x3299ff;if(void 0x0===_0x4b67f9&&(_0x4b67f9=!0x1),void 0x0===_0x1560aa['min']){var _0x279086=_0x1560aa||this['getScene']()['meshes'];_0x5a1cfa=_0x3cf5e5['a']['MinMax'](_0x279086),_0x3299ff=_0x74d525['e']['Distance'](_0x5a1cfa['min'],_0x5a1cfa['max']);}else _0x5a1cfa=_0x1560aa,_0x3299ff=_0x1560aa['distance'];this['_target']=_0x3cf5e5['a']['Center'](_0x5a1cfa),_0x4b67f9||(this['maxZ']=0x2*_0x3299ff);},_0x218ba2['prototype']['createRigCamera']=function(_0x5f12a9,_0x251aa7){var _0x21c5c7=0x0;switch(this['cameraRigMode']){case _0x568729['a']['RIG_MODE_STEREOSCOPIC_ANAGLYPH']:case _0x568729['a']['RIG_MODE_STEREOSCOPIC_SIDEBYSIDE_PARALLEL']:case _0x568729['a']['RIG_MODE_STEREOSCOPIC_OVERUNDER']:case _0x568729['a']['RIG_MODE_STEREOSCOPIC_INTERLACED']:case _0x568729['a']['RIG_MODE_VR']:_0x21c5c7=this['_cameraRigParams']['stereoHalfAngle']*(0x0===_0x251aa7?0x1:-0x1);break;case _0x568729['a']['RIG_MODE_STEREOSCOPIC_SIDEBYSIDE_CROSSEYED']:_0x21c5c7=this['_cameraRigParams']['stereoHalfAngle']*(0x0===_0x251aa7?-0x1:0x1);}var _0xec3eea=new _0x218ba2(_0x5f12a9,this['alpha']+_0x21c5c7,this['beta'],this['radius'],this['_target'],this['getScene']());return _0xec3eea['_cameraRigParams']={},_0xec3eea['isRigCamera']=!0x0,_0xec3eea['rigParent']=this,_0xec3eea['upVector']=this['upVector'],_0xec3eea;},_0x218ba2['prototype']['_updateRigCameras']=function(){var _0x312842=this['_rigCameras'][0x0],_0x2223fe=this['_rigCameras'][0x1];switch(_0x312842['beta']=_0x2223fe['beta']=this['beta'],this['cameraRigMode']){case _0x568729['a']['RIG_MODE_STEREOSCOPIC_ANAGLYPH']:case _0x568729['a']['RIG_MODE_STEREOSCOPIC_SIDEBYSIDE_PARALLEL']:case _0x568729['a']['RIG_MODE_STEREOSCOPIC_OVERUNDER']:case _0x568729['a']['RIG_MODE_STEREOSCOPIC_INTERLACED']:case _0x568729['a']['RIG_MODE_VR']:_0x312842['alpha']=this['alpha']-this['_cameraRigParams']['stereoHalfAngle'],_0x2223fe['alpha']=this['alpha']+this['_cameraRigParams']['stereoHalfAngle'];break;case _0x568729['a']['RIG_MODE_STEREOSCOPIC_SIDEBYSIDE_CROSSEYED']:_0x312842['alpha']=this['alpha']+this['_cameraRigParams']['stereoHalfAngle'],_0x2223fe['alpha']=this['alpha']-this['_cameraRigParams']['stereoHalfAngle'];}_0x283b6e['prototype']['_updateRigCameras']['call'](this);},_0x218ba2['prototype']['dispose']=function(){this['inputs']['clear'](),_0x283b6e['prototype']['dispose']['call'](this);},_0x218ba2['prototype']['getClassName']=function(){return'ArcRotateCamera';},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x218ba2['prototype'],'alpha',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x218ba2['prototype'],'beta',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x218ba2['prototype'],'radius',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['o'])('target')],_0x218ba2['prototype'],'_target',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x218ba2['prototype'],'inertialAlphaOffset',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x218ba2['prototype'],'inertialBetaOffset',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x218ba2['prototype'],'inertialRadiusOffset',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x218ba2['prototype'],'lowerAlphaLimit',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x218ba2['prototype'],'upperAlphaLimit',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x218ba2['prototype'],'lowerBetaLimit',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x218ba2['prototype'],'upperBetaLimit',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x218ba2['prototype'],'lowerRadiusLimit',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x218ba2['prototype'],'upperRadiusLimit',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x218ba2['prototype'],'inertialPanningX',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x218ba2['prototype'],'inertialPanningY',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x218ba2['prototype'],'pinchToPanMaxDistance',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x218ba2['prototype'],'panningDistanceLimit',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['o'])()],_0x218ba2['prototype'],'panningOriginTarget',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x218ba2['prototype'],'panningInertia',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x218ba2['prototype'],'zoomOnFactor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x218ba2['prototype'],'targetScreenOffset',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x218ba2['prototype'],'allowUpsideDown',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x218ba2['prototype'],'useInputToRestoreState',void 0x0),_0x218ba2;}(_0x5f32ae);_0x43169a['a']['AddNodeConstructor']('DeviceOrientationCamera',function(_0x25dfa5,_0x3a61ad){return function(){return new _0x2de943(_0x25dfa5,_0x74d525['e']['Zero'](),_0x3a61ad);};});var _0x2de943=function(_0x1aedc2){function _0x589661(_0x16741b,_0x2a9df0,_0x2b920c){var _0x2f0117=_0x1aedc2['call'](this,_0x16741b,_0x2a9df0,_0x2b920c)||this;return _0x2f0117['_tmpDragQuaternion']=new _0x74d525['b'](),_0x2f0117['_disablePointerInputWhenUsingDeviceOrientation']=!0x0,_0x2f0117['_dragFactor']=0x0,_0x2f0117['_quaternionCache']=new _0x74d525['b'](),_0x2f0117['inputs']['addDeviceOrientation'](),_0x2f0117['inputs']['_deviceOrientationInput']&&_0x2f0117['inputs']['_deviceOrientationInput']['_onDeviceOrientationChangedObservable']['addOnce'](function(){_0x2f0117['_disablePointerInputWhenUsingDeviceOrientation']&&_0x2f0117['inputs']['_mouseInput']&&(_0x2f0117['inputs']['_mouseInput']['_allowCameraRotation']=!0x1,_0x2f0117['inputs']['_mouseInput']['onPointerMovedObservable']['add'](function(_0x7eeb4a){0x0!=_0x2f0117['_dragFactor']&&(_0x2f0117['_initialQuaternion']||(_0x2f0117['_initialQuaternion']=new _0x74d525['b']()),_0x74d525['b']['FromEulerAnglesToRef'](0x0,_0x7eeb4a['offsetX']*_0x2f0117['_dragFactor'],0x0,_0x2f0117['_tmpDragQuaternion']),_0x2f0117['_initialQuaternion']['multiplyToRef'](_0x2f0117['_tmpDragQuaternion'],_0x2f0117['_initialQuaternion']));}));}),_0x2f0117;}return Object(_0x18e13d['d'])(_0x589661,_0x1aedc2),Object['defineProperty'](_0x589661['prototype'],'disablePointerInputWhenUsingDeviceOrientation',{'get':function(){return this['_disablePointerInputWhenUsingDeviceOrientation'];},'set':function(_0x4c66bf){this['_disablePointerInputWhenUsingDeviceOrientation']=_0x4c66bf;},'enumerable':!0x1,'configurable':!0x0}),_0x589661['prototype']['enableHorizontalDragging']=function(_0xd3a8eb){void 0x0===_0xd3a8eb&&(_0xd3a8eb=0x1/0x12c),this['_dragFactor']=_0xd3a8eb;},_0x589661['prototype']['getClassName']=function(){return'DeviceOrientationCamera';},_0x589661['prototype']['_checkInputs']=function(){_0x1aedc2['prototype']['_checkInputs']['call'](this),this['_quaternionCache']['copyFrom'](this['rotationQuaternion']),this['_initialQuaternion']&&this['_initialQuaternion']['multiplyToRef'](this['rotationQuaternion'],this['rotationQuaternion']);},_0x589661['prototype']['resetToCurrentRotation']=function(_0x15d901){var _0x1bfef3=this;void 0x0===_0x15d901&&(_0x15d901=_0x4a79a2['a']['Y']),this['rotationQuaternion']&&(this['_initialQuaternion']||(this['_initialQuaternion']=new _0x74d525['b']()),this['_initialQuaternion']['copyFrom'](this['_quaternionCache']||this['rotationQuaternion']),['x','y','z']['forEach'](function(_0x10eb27){_0x15d901[_0x10eb27]?_0x1bfef3['_initialQuaternion'][_0x10eb27]*=-0x1:_0x1bfef3['_initialQuaternion'][_0x10eb27]=0x0;}),this['_initialQuaternion']['normalize'](),this['_initialQuaternion']['multiplyToRef'](this['rotationQuaternion'],this['rotationQuaternion']));},_0x589661;}(_0x5625b9),_0x131ccb=function(_0x39d173){function _0x295688(_0x55762d){return _0x39d173['call'](this,_0x55762d)||this;}return Object(_0x18e13d['d'])(_0x295688,_0x39d173),_0x295688['prototype']['addKeyboard']=function(){return this['add'](new _0x3ec62e()),this;},_0x295688['prototype']['addMouse']=function(_0x3263c5){return void 0x0===_0x3263c5&&(_0x3263c5=!0x0),this['add'](new _0x2c3b9f(_0x3263c5)),this;},_0x295688;}(_0x4ad380),_0x194bfa=function(_0x18b0b0){function _0x4721b0(_0x364d49,_0x3fa1d5,_0x4b6da3,_0x101b1d){void 0x0===_0x101b1d&&(_0x101b1d=!0x0);var _0x2d1544=_0x18b0b0['call'](this,_0x364d49,_0x3fa1d5,_0x4b6da3,_0x101b1d)||this;return _0x2d1544['ellipsoid']=new _0x74d525['e'](0x1,0x1,0x1),_0x2d1544['ellipsoidOffset']=new _0x74d525['e'](0x0,0x0,0x0),_0x2d1544['checkCollisions']=!0x1,_0x2d1544['applyGravity']=!0x1,_0x2d1544['cameraDirection']=_0x74d525['e']['Zero'](),_0x2d1544['_trackRoll']=0x0,_0x2d1544['rollCorrect']=0x64,_0x2d1544['bankedTurn']=!0x1,_0x2d1544['bankedTurnLimit']=Math['PI']/0x2,_0x2d1544['bankedTurnMultiplier']=0x1,_0x2d1544['_needMoveForGravity']=!0x1,_0x2d1544['_oldPosition']=_0x74d525['e']['Zero'](),_0x2d1544['_diffPosition']=_0x74d525['e']['Zero'](),_0x2d1544['_newPosition']=_0x74d525['e']['Zero'](),_0x2d1544['_collisionMask']=-0x1,_0x2d1544['_onCollisionPositionChange']=function(_0x3dd74d,_0x97a465,_0x3ef6b8){void 0x0===_0x3ef6b8&&(_0x3ef6b8=null);var _0x502c84;_0x502c84=_0x97a465,_0x2d1544['_newPosition']['copyFrom'](_0x502c84),_0x2d1544['_newPosition']['subtractToRef'](_0x2d1544['_oldPosition'],_0x2d1544['_diffPosition']),_0x2d1544['_diffPosition']['length']()>_0x300b38['a']['CollisionsEpsilon']&&(_0x2d1544['position']['addInPlace'](_0x2d1544['_diffPosition']),_0x2d1544['onCollide']&&_0x3ef6b8&&_0x2d1544['onCollide'](_0x3ef6b8));},_0x2d1544['inputs']=new _0x131ccb(_0x2d1544),_0x2d1544['inputs']['addKeyboard']()['addMouse'](),_0x2d1544;}return Object(_0x18e13d['d'])(_0x4721b0,_0x18b0b0),Object['defineProperty'](_0x4721b0['prototype'],'angularSensibility',{'get':function(){var _0x1c29e5=this['inputs']['attached']['mouse'];return _0x1c29e5?_0x1c29e5['angularSensibility']:0x0;},'set':function(_0x3fc235){var _0x120554=this['inputs']['attached']['mouse'];_0x120554&&(_0x120554['angularSensibility']=_0x3fc235);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4721b0['prototype'],'keysForward',{'get':function(){var _0x4aecde=this['inputs']['attached']['keyboard'];return _0x4aecde?_0x4aecde['keysForward']:[];},'set':function(_0x5254f3){var _0x3eaef8=this['inputs']['attached']['keyboard'];_0x3eaef8&&(_0x3eaef8['keysForward']=_0x5254f3);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4721b0['prototype'],'keysBackward',{'get':function(){var _0x49a453=this['inputs']['attached']['keyboard'];return _0x49a453?_0x49a453['keysBackward']:[];},'set':function(_0x24e41b){var _0x2e494c=this['inputs']['attached']['keyboard'];_0x2e494c&&(_0x2e494c['keysBackward']=_0x24e41b);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4721b0['prototype'],'keysUp',{'get':function(){var _0x2e86cd=this['inputs']['attached']['keyboard'];return _0x2e86cd?_0x2e86cd['keysUp']:[];},'set':function(_0x453761){var _0x17acd5=this['inputs']['attached']['keyboard'];_0x17acd5&&(_0x17acd5['keysUp']=_0x453761);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4721b0['prototype'],'keysDown',{'get':function(){var _0x17da47=this['inputs']['attached']['keyboard'];return _0x17da47?_0x17da47['keysDown']:[];},'set':function(_0x1db216){var _0x34bf40=this['inputs']['attached']['keyboard'];_0x34bf40&&(_0x34bf40['keysDown']=_0x1db216);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4721b0['prototype'],'keysLeft',{'get':function(){var _0x50ce8b=this['inputs']['attached']['keyboard'];return _0x50ce8b?_0x50ce8b['keysLeft']:[];},'set':function(_0x475e81){var _0xae9b07=this['inputs']['attached']['keyboard'];_0xae9b07&&(_0xae9b07['keysLeft']=_0x475e81);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4721b0['prototype'],'keysRight',{'get':function(){var _0xecd3fb=this['inputs']['attached']['keyboard'];return _0xecd3fb?_0xecd3fb['keysRight']:[];},'set':function(_0x2f4533){var _0x190a8b=this['inputs']['attached']['keyboard'];_0x190a8b&&(_0x190a8b['keysRight']=_0x2f4533);},'enumerable':!0x1,'configurable':!0x0}),_0x4721b0['prototype']['attachControl']=function(_0x57bdd3,_0x423fce){_0x423fce=_0x5d754c['b']['BackCompatCameraNoPreventDefault'](arguments),this['inputs']['attachElement'](_0x423fce);},_0x4721b0['prototype']['detachControl']=function(){this['inputs']['detachElement'](),this['cameraDirection']=new _0x74d525['e'](0x0,0x0,0x0);},Object['defineProperty'](_0x4721b0['prototype'],'collisionMask',{'get':function(){return this['_collisionMask'];},'set':function(_0x30ffe9){this['_collisionMask']=isNaN(_0x30ffe9)?-0x1:_0x30ffe9;},'enumerable':!0x1,'configurable':!0x0}),_0x4721b0['prototype']['_collideWithWorld']=function(_0x4c09b1){(this['parent']?_0x74d525['e']['TransformCoordinates'](this['position'],this['parent']['getWorldMatrix']()):this['position'])['subtractFromFloatsToRef'](0x0,this['ellipsoid']['y'],0x0,this['_oldPosition']),this['_oldPosition']['addInPlace'](this['ellipsoidOffset']);var _0x7d9fa0=this['getScene']()['collisionCoordinator'];this['_collider']||(this['_collider']=_0x7d9fa0['createCollider']()),this['_collider']['_radius']=this['ellipsoid'],this['_collider']['collisionMask']=this['_collisionMask'];var _0x2dd9a1=_0x4c09b1;this['applyGravity']&&(_0x2dd9a1=_0x4c09b1['add'](this['getScene']()['gravity'])),_0x7d9fa0['getNewPosition'](this['_oldPosition'],_0x2dd9a1,this['_collider'],0x3,null,this['_onCollisionPositionChange'],this['uniqueId']);},_0x4721b0['prototype']['_checkInputs']=function(){this['_localDirection']||(this['_localDirection']=_0x74d525['e']['Zero'](),this['_transformedDirection']=_0x74d525['e']['Zero']()),this['inputs']['checkInputs'](),_0x18b0b0['prototype']['_checkInputs']['call'](this);},_0x4721b0['prototype']['_decideIfNeedsToMove']=function(){return this['_needMoveForGravity']||Math['abs'](this['cameraDirection']['x'])>0x0||Math['abs'](this['cameraDirection']['y'])>0x0||Math['abs'](this['cameraDirection']['z'])>0x0;},_0x4721b0['prototype']['_updatePosition']=function(){this['checkCollisions']&&this['getScene']()['collisionsEnabled']?this['_collideWithWorld'](this['cameraDirection']):_0x18b0b0['prototype']['_updatePosition']['call'](this);},_0x4721b0['prototype']['restoreRoll']=function(_0x5c6e69){var _0x567bab=this['_trackRoll'],_0x5bfc39=_0x567bab-this['rotation']['z'];Math['abs'](_0x5bfc39)>=0.001&&(this['rotation']['z']+=_0x5bfc39/_0x5c6e69,Math['abs'](_0x567bab-this['rotation']['z'])<=0.001&&(this['rotation']['z']=_0x567bab));},_0x4721b0['prototype']['dispose']=function(){this['inputs']['clear'](),_0x18b0b0['prototype']['dispose']['call'](this);},_0x4721b0['prototype']['getClassName']=function(){return'FlyCamera';},Object(_0x18e13d['c'])([Object(_0x495d06['o'])()],_0x4721b0['prototype'],'ellipsoid',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['o'])()],_0x4721b0['prototype'],'ellipsoidOffset',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x4721b0['prototype'],'checkCollisions',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x4721b0['prototype'],'applyGravity',void 0x0),_0x4721b0;}(_0x5f32ae),_0x5f353d=function(_0x5e6874){function _0x4c6cac(_0x218586){return _0x5e6874['call'](this,_0x218586)||this;}return Object(_0x18e13d['d'])(_0x4c6cac,_0x5e6874),_0x4c6cac['prototype']['addKeyboard']=function(){return this['add'](new _0xceeb14()),this;},_0x4c6cac['prototype']['addMouseWheel']=function(){return this['add'](new _0x41b4ed()),this;},_0x4c6cac['prototype']['addPointers']=function(){return this['add'](new _0xbf36c3()),this;},_0x4c6cac['prototype']['addVRDeviceOrientation']=function(){return console['warn']('DeviceOrientation\x20support\x20not\x20yet\x20implemented\x20for\x20FollowCamera.'),this;},_0x4c6cac;}(_0x4ad380);_0x43169a['a']['AddNodeConstructor']('FollowCamera',function(_0x5465ef,_0x227ce2){return function(){return new _0x356cee(_0x5465ef,_0x74d525['e']['Zero'](),_0x227ce2);};}),_0x43169a['a']['AddNodeConstructor']('ArcFollowCamera',function(_0x1e1b31,_0x174fcc){return function(){return new _0x56be32(_0x1e1b31,0x0,0x0,0x1,null,_0x174fcc);};});var _0x1a2757,_0x356cee=function(_0x16ccc9){function _0x9f75a6(_0x3d194d,_0x2cffae,_0x3aaa4c,_0xa6a1f3){void 0x0===_0xa6a1f3&&(_0xa6a1f3=null);var _0x31dc9d=_0x16ccc9['call'](this,_0x3d194d,_0x2cffae,_0x3aaa4c)||this;return _0x31dc9d['radius']=0xc,_0x31dc9d['lowerRadiusLimit']=null,_0x31dc9d['upperRadiusLimit']=null,_0x31dc9d['rotationOffset']=0x0,_0x31dc9d['lowerRotationOffsetLimit']=null,_0x31dc9d['upperRotationOffsetLimit']=null,_0x31dc9d['heightOffset']=0x4,_0x31dc9d['lowerHeightOffsetLimit']=null,_0x31dc9d['upperHeightOffsetLimit']=null,_0x31dc9d['cameraAcceleration']=0.05,_0x31dc9d['maxCameraSpeed']=0x14,_0x31dc9d['lockedTarget']=_0xa6a1f3,_0x31dc9d['inputs']=new _0x5f353d(_0x31dc9d),_0x31dc9d['inputs']['addKeyboard']()['addMouseWheel']()['addPointers'](),_0x31dc9d;}return Object(_0x18e13d['d'])(_0x9f75a6,_0x16ccc9),_0x9f75a6['prototype']['_follow']=function(_0x46633d){if(_0x46633d){var _0x49301c;if(_0x46633d['rotationQuaternion']){var _0x484733=new _0x74d525['a']();_0x46633d['rotationQuaternion']['toRotationMatrix'](_0x484733),_0x49301c=Math['atan2'](_0x484733['m'][0x8],_0x484733['m'][0xa]);}else _0x49301c=_0x46633d['rotation']['y'];var _0x48e62c=_0x5d754c['b']['ToRadians'](this['rotationOffset'])+_0x49301c,_0x4c39a9=_0x46633d['getAbsolutePosition'](),_0x5a0bea=_0x4c39a9['x']+Math['sin'](_0x48e62c)*this['radius'],_0x4142bf=_0x4c39a9['z']+Math['cos'](_0x48e62c)*this['radius'],_0x355db7=_0x5a0bea-this['position']['x'],_0x401d14=_0x4c39a9['y']+this['heightOffset']-this['position']['y'],_0x27457a=_0x4142bf-this['position']['z'],_0x4c9cbb=_0x355db7*this['cameraAcceleration']*0x2,_0x3b8b85=_0x401d14*this['cameraAcceleration'],_0x595964=_0x27457a*this['cameraAcceleration']*0x2;(_0x4c9cbb>this['maxCameraSpeed']||_0x4c9cbb<-this['maxCameraSpeed'])&&(_0x4c9cbb=_0x4c9cbb<0x1?-this['maxCameraSpeed']:this['maxCameraSpeed']),(_0x3b8b85>this['maxCameraSpeed']||_0x3b8b85<-this['maxCameraSpeed'])&&(_0x3b8b85=_0x3b8b85<0x1?-this['maxCameraSpeed']:this['maxCameraSpeed']),(_0x595964>this['maxCameraSpeed']||_0x595964<-this['maxCameraSpeed'])&&(_0x595964=_0x595964<0x1?-this['maxCameraSpeed']:this['maxCameraSpeed']),this['position']=new _0x74d525['e'](this['position']['x']+_0x4c9cbb,this['position']['y']+_0x3b8b85,this['position']['z']+_0x595964),this['setTarget'](_0x4c39a9);}},_0x9f75a6['prototype']['attachControl']=function(_0x35b1d7,_0x193914){_0x193914=_0x5d754c['b']['BackCompatCameraNoPreventDefault'](arguments),this['inputs']['attachElement'](_0x193914),this['_reset']=function(){};},_0x9f75a6['prototype']['detachControl']=function(_0x5a170a){this['inputs']['detachElement'](),this['_reset']&&this['_reset']();},_0x9f75a6['prototype']['_checkInputs']=function(){this['inputs']['checkInputs'](),this['_checkLimits'](),_0x16ccc9['prototype']['_checkInputs']['call'](this),this['lockedTarget']&&this['_follow'](this['lockedTarget']);},_0x9f75a6['prototype']['_checkLimits']=function(){null!==this['lowerRadiusLimit']&&this['radius']this['upperRadiusLimit']&&(this['radius']=this['upperRadiusLimit']),null!==this['lowerHeightOffsetLimit']&&this['heightOffset']this['upperHeightOffsetLimit']&&(this['heightOffset']=this['upperHeightOffsetLimit']),null!==this['lowerRotationOffsetLimit']&&this['rotationOffset']this['upperRotationOffsetLimit']&&(this['rotationOffset']=this['upperRotationOffsetLimit']);},_0x9f75a6['prototype']['getClassName']=function(){return'FollowCamera';},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x9f75a6['prototype'],'radius',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x9f75a6['prototype'],'lowerRadiusLimit',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x9f75a6['prototype'],'upperRadiusLimit',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x9f75a6['prototype'],'rotationOffset',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x9f75a6['prototype'],'lowerRotationOffsetLimit',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x9f75a6['prototype'],'upperRotationOffsetLimit',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x9f75a6['prototype'],'heightOffset',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x9f75a6['prototype'],'lowerHeightOffsetLimit',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x9f75a6['prototype'],'upperHeightOffsetLimit',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x9f75a6['prototype'],'cameraAcceleration',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x9f75a6['prototype'],'maxCameraSpeed',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['k'])('lockedTargetId')],_0x9f75a6['prototype'],'lockedTarget',void 0x0),_0x9f75a6;}(_0x5f32ae),_0x56be32=function(_0x337e39){function _0x5d7ecf(_0x3ad900,_0x4eb524,_0x55b7ff,_0x32d40a,_0x816f02,_0x1cf7b5){var _0x2edbd8=_0x337e39['call'](this,_0x3ad900,_0x74d525['e']['Zero'](),_0x1cf7b5)||this;return _0x2edbd8['alpha']=_0x4eb524,_0x2edbd8['beta']=_0x55b7ff,_0x2edbd8['radius']=_0x32d40a,_0x2edbd8['_cartesianCoordinates']=_0x74d525['e']['Zero'](),_0x2edbd8['_meshTarget']=_0x816f02,_0x2edbd8['_follow'](),_0x2edbd8;}return Object(_0x18e13d['d'])(_0x5d7ecf,_0x337e39),_0x5d7ecf['prototype']['_follow']=function(){if(this['_meshTarget']){this['_cartesianCoordinates']['x']=this['radius']*Math['cos'](this['alpha'])*Math['cos'](this['beta']),this['_cartesianCoordinates']['y']=this['radius']*Math['sin'](this['beta']),this['_cartesianCoordinates']['z']=this['radius']*Math['sin'](this['alpha'])*Math['cos'](this['beta']);var _0x4abfdc=this['_meshTarget']['getAbsolutePosition']();this['position']=_0x4abfdc['add'](this['_cartesianCoordinates']),this['setTarget'](_0x4abfdc);}},_0x5d7ecf['prototype']['_checkInputs']=function(){_0x337e39['prototype']['_checkInputs']['call'](this),this['_follow']();},_0x5d7ecf['prototype']['getClassName']=function(){return'ArcFollowCamera';},_0x5d7ecf;}(_0x5f32ae),_0x3cbe81=_0x162675(0x26),_0x36fb4d=_0x162675(0x27);!function(_0x21f1df){_0x21f1df[_0x21f1df['VIVE']=0x0]='VIVE',_0x21f1df[_0x21f1df['OCULUS']=0x1]='OCULUS',_0x21f1df[_0x21f1df['WINDOWS']=0x2]='WINDOWS',_0x21f1df[_0x21f1df['GEAR_VR']=0x3]='GEAR_VR',_0x21f1df[_0x21f1df['DAYDREAM']=0x4]='DAYDREAM',_0x21f1df[_0x21f1df['GENERIC']=0x5]='GENERIC';}(_0x1a2757||(_0x1a2757={}));var _0x40fdb4,_0x57b714,_0x14684f=(function(){function _0x58a887(){}return _0x58a887['InitiateController']=function(_0x83cf67){for(var _0x36317f=0x0,_0x224650=this['_ControllerFactories'];_0x36317f<_0x224650['length'];_0x36317f++){var _0x4b3c1c=_0x224650[_0x36317f];if(_0x4b3c1c['canCreate'](_0x83cf67))return _0x4b3c1c['create'](_0x83cf67);}if(this['_DefaultControllerFactory'])return this['_DefaultControllerFactory'](_0x83cf67);throw'The\x20type\x20of\x20gamepad\x20you\x20are\x20trying\x20to\x20load\x20needs\x20to\x20be\x20imported\x20first\x20or\x20is\x20not\x20supported.';},_0x58a887['_ControllerFactories']=[],_0x58a887['_DefaultControllerFactory']=null,_0x58a887;}()),_0x3c2ea8=function(_0x5c01b3){function _0x3a98f0(_0x4163bc){var _0x584ca2=_0x5c01b3['call'](this,_0x4163bc['id'],_0x4163bc['index'],_0x4163bc)||this;return _0x584ca2['isXR']=!0x1,_0x584ca2['_deviceRoomPosition']=_0x74d525['e']['Zero'](),_0x584ca2['_deviceRoomRotationQuaternion']=new _0x74d525['b'](),_0x584ca2['devicePosition']=_0x74d525['e']['Zero'](),_0x584ca2['deviceRotationQuaternion']=new _0x74d525['b'](),_0x584ca2['deviceScaleFactor']=0x1,_0x584ca2['_trackPosition']=!0x0,_0x584ca2['_maxRotationDistFromHeadset']=Math['PI']/0x5,_0x584ca2['_draggedRoomRotation']=0x0,_0x584ca2['_leftHandSystemQuaternion']=new _0x74d525['b'](),_0x584ca2['_deviceToWorld']=_0x74d525['a']['Identity'](),_0x584ca2['_pointingPoseNode']=null,_0x584ca2['_workingMatrix']=_0x74d525['a']['Identity'](),_0x584ca2['_meshAttachedObservable']=new _0x6ac1f7['c'](),_0x584ca2['type']=_0x56ffd0['POSE_ENABLED'],_0x584ca2['controllerType']=_0x1a2757['GENERIC'],_0x584ca2['position']=_0x74d525['e']['Zero'](),_0x584ca2['rotationQuaternion']=new _0x74d525['b'](),_0x584ca2['_calculatedPosition']=_0x74d525['e']['Zero'](),_0x584ca2['_calculatedRotation']=new _0x74d525['b'](),_0x74d525['b']['RotationYawPitchRollToRef'](Math['PI'],0x0,0x0,_0x584ca2['_leftHandSystemQuaternion']),_0x584ca2;}return Object(_0x18e13d['d'])(_0x3a98f0,_0x5c01b3),_0x3a98f0['prototype']['_disableTrackPosition']=function(_0x3d3bf6){this['_trackPosition']&&(this['_calculatedPosition']['copyFrom'](_0x3d3bf6),this['_trackPosition']=!0x1);},_0x3a98f0['prototype']['update']=function(){_0x5c01b3['prototype']['update']['call'](this),this['_updatePoseAndMesh']();},_0x3a98f0['prototype']['_updatePoseAndMesh']=function(){if(!this['isXR']){var _0x1ef0a7=this['browserGamepad']['pose'];if(this['updateFromDevice'](_0x1ef0a7),!this['_trackPosition']&&_0x44b9ce['a']['LastCreatedScene']&&_0x44b9ce['a']['LastCreatedScene']['activeCamera']&&_0x44b9ce['a']['LastCreatedScene']['activeCamera']['devicePosition']){if((_0xd6926=_0x44b9ce['a']['LastCreatedScene']['activeCamera'])['_computeDevicePosition'](),this['_deviceToWorld']['setTranslation'](_0xd6926['devicePosition']),_0xd6926['deviceRotationQuaternion']){var _0xd6926;(_0xd6926=_0xd6926)['_deviceRoomRotationQuaternion']['toEulerAnglesToRef'](_0x74d525['c']['Vector3'][0x0]);var _0x1500dd=Math['atan2'](Math['sin'](_0x74d525['c']['Vector3'][0x0]['y']-this['_draggedRoomRotation']),Math['cos'](_0x74d525['c']['Vector3'][0x0]['y']-this['_draggedRoomRotation']));if(Math['abs'](_0x1500dd)>this['_maxRotationDistFromHeadset']){var _0x38b8d8=_0x1500dd-(_0x1500dd<0x0?-this['_maxRotationDistFromHeadset']:this['_maxRotationDistFromHeadset']);this['_draggedRoomRotation']+=_0x38b8d8;var _0x387a6e=Math['sin'](-_0x38b8d8),_0x2a2b71=Math['cos'](-_0x38b8d8);this['_calculatedPosition']['x']=this['_calculatedPosition']['x']*_0x2a2b71-this['_calculatedPosition']['z']*_0x387a6e,this['_calculatedPosition']['z']=this['_calculatedPosition']['x']*_0x387a6e+this['_calculatedPosition']['z']*_0x2a2b71;}}}_0x74d525['e']['TransformCoordinatesToRef'](this['_calculatedPosition'],this['_deviceToWorld'],this['devicePosition']),this['_deviceToWorld']['getRotationMatrixToRef'](this['_workingMatrix']),_0x74d525['b']['FromRotationMatrixToRef'](this['_workingMatrix'],this['deviceRotationQuaternion']),this['deviceRotationQuaternion']['multiplyInPlace'](this['_calculatedRotation']),this['_mesh']&&(this['_mesh']['position']['copyFrom'](this['devicePosition']),this['_mesh']['rotationQuaternion']&&this['_mesh']['rotationQuaternion']['copyFrom'](this['deviceRotationQuaternion']));}},_0x3a98f0['prototype']['updateFromDevice']=function(_0x2137d0){if(!this['isXR']&&_0x2137d0){this['rawPose']=_0x2137d0,_0x2137d0['position']&&(this['_deviceRoomPosition']['copyFromFloats'](_0x2137d0['position'][0x0],_0x2137d0['position'][0x1],-_0x2137d0['position'][0x2]),this['_mesh']&&this['_mesh']['getScene']()['useRightHandedSystem']&&(this['_deviceRoomPosition']['z']*=-0x1),this['_trackPosition']&&this['_deviceRoomPosition']['scaleToRef'](this['deviceScaleFactor'],this['_calculatedPosition']),this['_calculatedPosition']['addInPlace'](this['position']));var _0x346745=this['rawPose'];_0x2137d0['orientation']&&_0x346745['orientation']&&0x4===_0x346745['orientation']['length']&&(this['_deviceRoomRotationQuaternion']['copyFromFloats'](_0x346745['orientation'][0x0],_0x346745['orientation'][0x1],-_0x346745['orientation'][0x2],-_0x346745['orientation'][0x3]),this['_mesh']&&(this['_mesh']['getScene']()['useRightHandedSystem']?(this['_deviceRoomRotationQuaternion']['z']*=-0x1,this['_deviceRoomRotationQuaternion']['w']*=-0x1):this['_deviceRoomRotationQuaternion']['multiplyToRef'](this['_leftHandSystemQuaternion'],this['_deviceRoomRotationQuaternion'])),this['_deviceRoomRotationQuaternion']['multiplyToRef'](this['rotationQuaternion'],this['_calculatedRotation']));}},_0x3a98f0['prototype']['attachToMesh']=function(_0x5b68c1){if(this['_mesh']&&(this['_mesh']['parent']=null),this['_mesh']=_0x5b68c1,this['_poseControlledCamera']&&(this['_mesh']['parent']=this['_poseControlledCamera']),this['_mesh']['rotationQuaternion']||(this['_mesh']['rotationQuaternion']=new _0x74d525['b']()),!this['isXR']&&(this['_updatePoseAndMesh'](),this['_pointingPoseNode'])){for(var _0x285f21=[],_0x36eefa=this['_pointingPoseNode'];_0x36eefa['parent'];)_0x285f21['push'](_0x36eefa['parent']),_0x36eefa=_0x36eefa['parent'];_0x285f21['reverse']()['forEach'](function(_0x5f1c66){_0x5f1c66['computeWorldMatrix'](!0x0);});}this['_meshAttachedObservable']['notifyObservers'](_0x5b68c1);},_0x3a98f0['prototype']['attachToPoseControlledCamera']=function(_0x37fac4){this['_poseControlledCamera']=_0x37fac4,this['_mesh']&&(this['_mesh']['parent']=this['_poseControlledCamera']);},_0x3a98f0['prototype']['dispose']=function(){this['_mesh']&&this['_mesh']['dispose'](),this['_mesh']=null,_0x5c01b3['prototype']['dispose']['call'](this);},Object['defineProperty'](_0x3a98f0['prototype'],'mesh',{'get':function(){return this['_mesh'];},'enumerable':!0x1,'configurable':!0x0}),_0x3a98f0['prototype']['getForwardRay']=function(_0x53315d){if(void 0x0===_0x53315d&&(_0x53315d=0x64),!this['mesh'])return new _0x36fb4d['a'](_0x74d525['e']['Zero'](),new _0x74d525['e'](0x0,0x0,0x1),_0x53315d);var _0x575a3f=this['_pointingPoseNode']?this['_pointingPoseNode']['getWorldMatrix']():this['mesh']['getWorldMatrix'](),_0x1c225e=_0x575a3f['getTranslation'](),_0x28d965=new _0x74d525['e'](0x0,0x0,-0x1),_0x16bf29=_0x74d525['e']['TransformNormal'](_0x28d965,_0x575a3f),_0x25aa84=_0x74d525['e']['Normalize'](_0x16bf29);return new _0x36fb4d['a'](_0x1c225e,_0x25aa84,_0x53315d);},_0x3a98f0['POINTING_POSE']='POINTING_POSE',_0x3a98f0;}(_0x56ffd0);!function(_0x444416){_0x444416[_0x444416['A']=0x0]='A',_0x444416[_0x444416['B']=0x1]='B',_0x444416[_0x444416['X']=0x2]='X',_0x444416[_0x444416['Y']=0x3]='Y',_0x444416[_0x444416['LB']=0x4]='LB',_0x444416[_0x444416['RB']=0x5]='RB',_0x444416[_0x444416['Back']=0x8]='Back',_0x444416[_0x444416['Start']=0x9]='Start',_0x444416[_0x444416['LeftStick']=0xa]='LeftStick',_0x444416[_0x444416['RightStick']=0xb]='RightStick';}(_0x40fdb4||(_0x40fdb4={})),function(_0x15130e){_0x15130e[_0x15130e['Up']=0xc]='Up',_0x15130e[_0x15130e['Down']=0xd]='Down',_0x15130e[_0x15130e['Left']=0xe]='Left',_0x15130e[_0x15130e['Right']=0xf]='Right';}(_0x57b714||(_0x57b714={}));var _0x1d97e6,_0x4edecf,_0x4fe65c=function(_0x52514e){function _0x51b276(_0x14a886,_0x1e65cf,_0x53daa0,_0x525dae){void 0x0===_0x525dae&&(_0x525dae=!0x1);var _0x2b9650=_0x52514e['call'](this,_0x14a886,_0x1e65cf,_0x53daa0,0x0,0x1,0x2,0x3)||this;return _0x2b9650['_leftTrigger']=0x0,_0x2b9650['_rightTrigger']=0x0,_0x2b9650['onButtonDownObservable']=new _0x6ac1f7['c'](),_0x2b9650['onButtonUpObservable']=new _0x6ac1f7['c'](),_0x2b9650['onPadDownObservable']=new _0x6ac1f7['c'](),_0x2b9650['onPadUpObservable']=new _0x6ac1f7['c'](),_0x2b9650['_buttonA']=0x0,_0x2b9650['_buttonB']=0x0,_0x2b9650['_buttonX']=0x0,_0x2b9650['_buttonY']=0x0,_0x2b9650['_buttonBack']=0x0,_0x2b9650['_buttonStart']=0x0,_0x2b9650['_buttonLB']=0x0,_0x2b9650['_buttonRB']=0x0,_0x2b9650['_buttonLeftStick']=0x0,_0x2b9650['_buttonRightStick']=0x0,_0x2b9650['_dPadUp']=0x0,_0x2b9650['_dPadDown']=0x0,_0x2b9650['_dPadLeft']=0x0,_0x2b9650['_dPadRight']=0x0,_0x2b9650['_isXboxOnePad']=!0x1,_0x2b9650['type']=_0x56ffd0['XBOX'],_0x2b9650['_isXboxOnePad']=_0x525dae,_0x2b9650;}return Object(_0x18e13d['d'])(_0x51b276,_0x52514e),_0x51b276['prototype']['onlefttriggerchanged']=function(_0x13f2cb){this['_onlefttriggerchanged']=_0x13f2cb;},_0x51b276['prototype']['onrighttriggerchanged']=function(_0x25273c){this['_onrighttriggerchanged']=_0x25273c;},Object['defineProperty'](_0x51b276['prototype'],'leftTrigger',{'get':function(){return this['_leftTrigger'];},'set':function(_0x99c8db){this['_onlefttriggerchanged']&&this['_leftTrigger']!==_0x99c8db&&this['_onlefttriggerchanged'](_0x99c8db),this['_leftTrigger']=_0x99c8db;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x51b276['prototype'],'rightTrigger',{'get':function(){return this['_rightTrigger'];},'set':function(_0x1e58fa){this['_onrighttriggerchanged']&&this['_rightTrigger']!==_0x1e58fa&&this['_onrighttriggerchanged'](_0x1e58fa),this['_rightTrigger']=_0x1e58fa;},'enumerable':!0x1,'configurable':!0x0}),_0x51b276['prototype']['onbuttondown']=function(_0x3dc5e1){this['_onbuttondown']=_0x3dc5e1;},_0x51b276['prototype']['onbuttonup']=function(_0x504e15){this['_onbuttonup']=_0x504e15;},_0x51b276['prototype']['ondpaddown']=function(_0x5585a2){this['_ondpaddown']=_0x5585a2;},_0x51b276['prototype']['ondpadup']=function(_0x5c6cb2){this['_ondpadup']=_0x5c6cb2;},_0x51b276['prototype']['_setButtonValue']=function(_0x511c59,_0x4cdc90,_0x576b3d){return _0x511c59!==_0x4cdc90&&(0x1===_0x511c59&&(this['_onbuttondown']&&this['_onbuttondown'](_0x576b3d),this['onButtonDownObservable']['notifyObservers'](_0x576b3d)),0x0===_0x511c59&&(this['_onbuttonup']&&this['_onbuttonup'](_0x576b3d),this['onButtonUpObservable']['notifyObservers'](_0x576b3d))),_0x511c59;},_0x51b276['prototype']['_setDPadValue']=function(_0x1482e8,_0x3b9739,_0x1dd031){return _0x1482e8!==_0x3b9739&&(0x1===_0x1482e8&&(this['_ondpaddown']&&this['_ondpaddown'](_0x1dd031),this['onPadDownObservable']['notifyObservers'](_0x1dd031)),0x0===_0x1482e8&&(this['_ondpadup']&&this['_ondpadup'](_0x1dd031),this['onPadUpObservable']['notifyObservers'](_0x1dd031))),_0x1482e8;},Object['defineProperty'](_0x51b276['prototype'],'buttonA',{'get':function(){return this['_buttonA'];},'set':function(_0x26890c){this['_buttonA']=this['_setButtonValue'](_0x26890c,this['_buttonA'],_0x40fdb4['A']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x51b276['prototype'],'buttonB',{'get':function(){return this['_buttonB'];},'set':function(_0x41597a){this['_buttonB']=this['_setButtonValue'](_0x41597a,this['_buttonB'],_0x40fdb4['B']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x51b276['prototype'],'buttonX',{'get':function(){return this['_buttonX'];},'set':function(_0x5bfc35){this['_buttonX']=this['_setButtonValue'](_0x5bfc35,this['_buttonX'],_0x40fdb4['X']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x51b276['prototype'],'buttonY',{'get':function(){return this['_buttonY'];},'set':function(_0xf28c90){this['_buttonY']=this['_setButtonValue'](_0xf28c90,this['_buttonY'],_0x40fdb4['Y']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x51b276['prototype'],'buttonStart',{'get':function(){return this['_buttonStart'];},'set':function(_0x5db5d1){this['_buttonStart']=this['_setButtonValue'](_0x5db5d1,this['_buttonStart'],_0x40fdb4['Start']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x51b276['prototype'],'buttonBack',{'get':function(){return this['_buttonBack'];},'set':function(_0x227a76){this['_buttonBack']=this['_setButtonValue'](_0x227a76,this['_buttonBack'],_0x40fdb4['Back']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x51b276['prototype'],'buttonLB',{'get':function(){return this['_buttonLB'];},'set':function(_0x1eb77a){this['_buttonLB']=this['_setButtonValue'](_0x1eb77a,this['_buttonLB'],_0x40fdb4['LB']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x51b276['prototype'],'buttonRB',{'get':function(){return this['_buttonRB'];},'set':function(_0x3783d9){this['_buttonRB']=this['_setButtonValue'](_0x3783d9,this['_buttonRB'],_0x40fdb4['RB']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x51b276['prototype'],'buttonLeftStick',{'get':function(){return this['_buttonLeftStick'];},'set':function(_0x2b2e08){this['_buttonLeftStick']=this['_setButtonValue'](_0x2b2e08,this['_buttonLeftStick'],_0x40fdb4['LeftStick']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x51b276['prototype'],'buttonRightStick',{'get':function(){return this['_buttonRightStick'];},'set':function(_0x4c75ab){this['_buttonRightStick']=this['_setButtonValue'](_0x4c75ab,this['_buttonRightStick'],_0x40fdb4['RightStick']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x51b276['prototype'],'dPadUp',{'get':function(){return this['_dPadUp'];},'set':function(_0x1115a5){this['_dPadUp']=this['_setDPadValue'](_0x1115a5,this['_dPadUp'],_0x57b714['Up']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x51b276['prototype'],'dPadDown',{'get':function(){return this['_dPadDown'];},'set':function(_0x4e60f0){this['_dPadDown']=this['_setDPadValue'](_0x4e60f0,this['_dPadDown'],_0x57b714['Down']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x51b276['prototype'],'dPadLeft',{'get':function(){return this['_dPadLeft'];},'set':function(_0x11bc10){this['_dPadLeft']=this['_setDPadValue'](_0x11bc10,this['_dPadLeft'],_0x57b714['Left']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x51b276['prototype'],'dPadRight',{'get':function(){return this['_dPadRight'];},'set':function(_0x2cfc42){this['_dPadRight']=this['_setDPadValue'](_0x2cfc42,this['_dPadRight'],_0x57b714['Right']);},'enumerable':!0x1,'configurable':!0x0}),_0x51b276['prototype']['update']=function(){_0x52514e['prototype']['update']['call'](this),this['_isXboxOnePad'],this['buttonA']=this['browserGamepad']['buttons'][0x0]['value'],this['buttonB']=this['browserGamepad']['buttons'][0x1]['value'],this['buttonX']=this['browserGamepad']['buttons'][0x2]['value'],this['buttonY']=this['browserGamepad']['buttons'][0x3]['value'],this['buttonLB']=this['browserGamepad']['buttons'][0x4]['value'],this['buttonRB']=this['browserGamepad']['buttons'][0x5]['value'],this['leftTrigger']=this['browserGamepad']['buttons'][0x6]['value'],this['rightTrigger']=this['browserGamepad']['buttons'][0x7]['value'],this['buttonBack']=this['browserGamepad']['buttons'][0x8]['value'],this['buttonStart']=this['browserGamepad']['buttons'][0x9]['value'],this['buttonLeftStick']=this['browserGamepad']['buttons'][0xa]['value'],this['buttonRightStick']=this['browserGamepad']['buttons'][0xb]['value'],this['dPadUp']=this['browserGamepad']['buttons'][0xc]['value'],this['dPadDown']=this['browserGamepad']['buttons'][0xd]['value'],this['dPadLeft']=this['browserGamepad']['buttons'][0xe]['value'],this['dPadRight']=this['browserGamepad']['buttons'][0xf]['value'];},_0x51b276['prototype']['dispose']=function(){_0x52514e['prototype']['dispose']['call'](this),this['onButtonDownObservable']['clear'](),this['onButtonUpObservable']['clear'](),this['onPadDownObservable']['clear'](),this['onPadUpObservable']['clear']();},_0x51b276;}(_0x56ffd0);!function(_0x37b9f6){_0x37b9f6[_0x37b9f6['Cross']=0x0]='Cross',_0x37b9f6[_0x37b9f6['Circle']=0x1]='Circle',_0x37b9f6[_0x37b9f6['Square']=0x2]='Square',_0x37b9f6[_0x37b9f6['Triangle']=0x3]='Triangle',_0x37b9f6[_0x37b9f6['L1']=0x4]='L1',_0x37b9f6[_0x37b9f6['R1']=0x5]='R1',_0x37b9f6[_0x37b9f6['Share']=0x8]='Share',_0x37b9f6[_0x37b9f6['Options']=0x9]='Options',_0x37b9f6[_0x37b9f6['LeftStick']=0xa]='LeftStick',_0x37b9f6[_0x37b9f6['RightStick']=0xb]='RightStick';}(_0x1d97e6||(_0x1d97e6={})),function(_0x46733a){_0x46733a[_0x46733a['Up']=0xc]='Up',_0x46733a[_0x46733a['Down']=0xd]='Down',_0x46733a[_0x46733a['Left']=0xe]='Left',_0x46733a[_0x46733a['Right']=0xf]='Right';}(_0x4edecf||(_0x4edecf={}));var _0x5e3294=function(_0x3006ed){function _0x41b7ee(_0x6695c0,_0x2a0b7a,_0x189e6e){var _0x4cfb3b=_0x3006ed['call'](this,_0x6695c0['replace']('STANDARD\x20GAMEPAD','SONY\x20PLAYSTATION\x20DUALSHOCK'),_0x2a0b7a,_0x189e6e,0x0,0x1,0x2,0x3)||this;return _0x4cfb3b['_leftTrigger']=0x0,_0x4cfb3b['_rightTrigger']=0x0,_0x4cfb3b['onButtonDownObservable']=new _0x6ac1f7['c'](),_0x4cfb3b['onButtonUpObservable']=new _0x6ac1f7['c'](),_0x4cfb3b['onPadDownObservable']=new _0x6ac1f7['c'](),_0x4cfb3b['onPadUpObservable']=new _0x6ac1f7['c'](),_0x4cfb3b['_buttonCross']=0x0,_0x4cfb3b['_buttonCircle']=0x0,_0x4cfb3b['_buttonSquare']=0x0,_0x4cfb3b['_buttonTriangle']=0x0,_0x4cfb3b['_buttonShare']=0x0,_0x4cfb3b['_buttonOptions']=0x0,_0x4cfb3b['_buttonL1']=0x0,_0x4cfb3b['_buttonR1']=0x0,_0x4cfb3b['_buttonLeftStick']=0x0,_0x4cfb3b['_buttonRightStick']=0x0,_0x4cfb3b['_dPadUp']=0x0,_0x4cfb3b['_dPadDown']=0x0,_0x4cfb3b['_dPadLeft']=0x0,_0x4cfb3b['_dPadRight']=0x0,_0x4cfb3b['type']=_0x56ffd0['DUALSHOCK'],_0x4cfb3b;}return Object(_0x18e13d['d'])(_0x41b7ee,_0x3006ed),_0x41b7ee['prototype']['onlefttriggerchanged']=function(_0x2e1dee){this['_onlefttriggerchanged']=_0x2e1dee;},_0x41b7ee['prototype']['onrighttriggerchanged']=function(_0x31ef9e){this['_onrighttriggerchanged']=_0x31ef9e;},Object['defineProperty'](_0x41b7ee['prototype'],'leftTrigger',{'get':function(){return this['_leftTrigger'];},'set':function(_0x1211c0){this['_onlefttriggerchanged']&&this['_leftTrigger']!==_0x1211c0&&this['_onlefttriggerchanged'](_0x1211c0),this['_leftTrigger']=_0x1211c0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x41b7ee['prototype'],'rightTrigger',{'get':function(){return this['_rightTrigger'];},'set':function(_0x384134){this['_onrighttriggerchanged']&&this['_rightTrigger']!==_0x384134&&this['_onrighttriggerchanged'](_0x384134),this['_rightTrigger']=_0x384134;},'enumerable':!0x1,'configurable':!0x0}),_0x41b7ee['prototype']['onbuttondown']=function(_0x5efe1a){this['_onbuttondown']=_0x5efe1a;},_0x41b7ee['prototype']['onbuttonup']=function(_0x3b3e40){this['_onbuttonup']=_0x3b3e40;},_0x41b7ee['prototype']['ondpaddown']=function(_0x39c7c5){this['_ondpaddown']=_0x39c7c5;},_0x41b7ee['prototype']['ondpadup']=function(_0x498260){this['_ondpadup']=_0x498260;},_0x41b7ee['prototype']['_setButtonValue']=function(_0x43b4f3,_0x2210ff,_0x518d7e){return _0x43b4f3!==_0x2210ff&&(0x1===_0x43b4f3&&(this['_onbuttondown']&&this['_onbuttondown'](_0x518d7e),this['onButtonDownObservable']['notifyObservers'](_0x518d7e)),0x0===_0x43b4f3&&(this['_onbuttonup']&&this['_onbuttonup'](_0x518d7e),this['onButtonUpObservable']['notifyObservers'](_0x518d7e))),_0x43b4f3;},_0x41b7ee['prototype']['_setDPadValue']=function(_0x613a2f,_0x33e14e,_0x2ebbbd){return _0x613a2f!==_0x33e14e&&(0x1===_0x613a2f&&(this['_ondpaddown']&&this['_ondpaddown'](_0x2ebbbd),this['onPadDownObservable']['notifyObservers'](_0x2ebbbd)),0x0===_0x613a2f&&(this['_ondpadup']&&this['_ondpadup'](_0x2ebbbd),this['onPadUpObservable']['notifyObservers'](_0x2ebbbd))),_0x613a2f;},Object['defineProperty'](_0x41b7ee['prototype'],'buttonCross',{'get':function(){return this['_buttonCross'];},'set':function(_0x166658){this['_buttonCross']=this['_setButtonValue'](_0x166658,this['_buttonCross'],_0x1d97e6['Cross']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x41b7ee['prototype'],'buttonCircle',{'get':function(){return this['_buttonCircle'];},'set':function(_0x52820a){this['_buttonCircle']=this['_setButtonValue'](_0x52820a,this['_buttonCircle'],_0x1d97e6['Circle']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x41b7ee['prototype'],'buttonSquare',{'get':function(){return this['_buttonSquare'];},'set':function(_0x71f084){this['_buttonSquare']=this['_setButtonValue'](_0x71f084,this['_buttonSquare'],_0x1d97e6['Square']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x41b7ee['prototype'],'buttonTriangle',{'get':function(){return this['_buttonTriangle'];},'set':function(_0x10f365){this['_buttonTriangle']=this['_setButtonValue'](_0x10f365,this['_buttonTriangle'],_0x1d97e6['Triangle']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x41b7ee['prototype'],'buttonOptions',{'get':function(){return this['_buttonOptions'];},'set':function(_0x5dd647){this['_buttonOptions']=this['_setButtonValue'](_0x5dd647,this['_buttonOptions'],_0x1d97e6['Options']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x41b7ee['prototype'],'buttonShare',{'get':function(){return this['_buttonShare'];},'set':function(_0x25a1e6){this['_buttonShare']=this['_setButtonValue'](_0x25a1e6,this['_buttonShare'],_0x1d97e6['Share']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x41b7ee['prototype'],'buttonL1',{'get':function(){return this['_buttonL1'];},'set':function(_0xafadff){this['_buttonL1']=this['_setButtonValue'](_0xafadff,this['_buttonL1'],_0x1d97e6['L1']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x41b7ee['prototype'],'buttonR1',{'get':function(){return this['_buttonR1'];},'set':function(_0x467b25){this['_buttonR1']=this['_setButtonValue'](_0x467b25,this['_buttonR1'],_0x1d97e6['R1']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x41b7ee['prototype'],'buttonLeftStick',{'get':function(){return this['_buttonLeftStick'];},'set':function(_0x324d1f){this['_buttonLeftStick']=this['_setButtonValue'](_0x324d1f,this['_buttonLeftStick'],_0x1d97e6['LeftStick']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x41b7ee['prototype'],'buttonRightStick',{'get':function(){return this['_buttonRightStick'];},'set':function(_0x255dec){this['_buttonRightStick']=this['_setButtonValue'](_0x255dec,this['_buttonRightStick'],_0x1d97e6['RightStick']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x41b7ee['prototype'],'dPadUp',{'get':function(){return this['_dPadUp'];},'set':function(_0x50dd1d){this['_dPadUp']=this['_setDPadValue'](_0x50dd1d,this['_dPadUp'],_0x4edecf['Up']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x41b7ee['prototype'],'dPadDown',{'get':function(){return this['_dPadDown'];},'set':function(_0x27ef73){this['_dPadDown']=this['_setDPadValue'](_0x27ef73,this['_dPadDown'],_0x4edecf['Down']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x41b7ee['prototype'],'dPadLeft',{'get':function(){return this['_dPadLeft'];},'set':function(_0x479429){this['_dPadLeft']=this['_setDPadValue'](_0x479429,this['_dPadLeft'],_0x4edecf['Left']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x41b7ee['prototype'],'dPadRight',{'get':function(){return this['_dPadRight'];},'set':function(_0x19b363){this['_dPadRight']=this['_setDPadValue'](_0x19b363,this['_dPadRight'],_0x4edecf['Right']);},'enumerable':!0x1,'configurable':!0x0}),_0x41b7ee['prototype']['update']=function(){_0x3006ed['prototype']['update']['call'](this),this['buttonCross']=this['browserGamepad']['buttons'][0x0]['value'],this['buttonCircle']=this['browserGamepad']['buttons'][0x1]['value'],this['buttonSquare']=this['browserGamepad']['buttons'][0x2]['value'],this['buttonTriangle']=this['browserGamepad']['buttons'][0x3]['value'],this['buttonL1']=this['browserGamepad']['buttons'][0x4]['value'],this['buttonR1']=this['browserGamepad']['buttons'][0x5]['value'],this['leftTrigger']=this['browserGamepad']['buttons'][0x6]['value'],this['rightTrigger']=this['browserGamepad']['buttons'][0x7]['value'],this['buttonShare']=this['browserGamepad']['buttons'][0x8]['value'],this['buttonOptions']=this['browserGamepad']['buttons'][0x9]['value'],this['buttonLeftStick']=this['browserGamepad']['buttons'][0xa]['value'],this['buttonRightStick']=this['browserGamepad']['buttons'][0xb]['value'],this['dPadUp']=this['browserGamepad']['buttons'][0xc]['value'],this['dPadDown']=this['browserGamepad']['buttons'][0xd]['value'],this['dPadLeft']=this['browserGamepad']['buttons'][0xe]['value'],this['dPadRight']=this['browserGamepad']['buttons'][0xf]['value'];},_0x41b7ee['prototype']['dispose']=function(){_0x3006ed['prototype']['dispose']['call'](this),this['onButtonDownObservable']['clear'](),this['onButtonUpObservable']['clear'](),this['onPadDownObservable']['clear'](),this['onPadUpObservable']['clear']();},_0x41b7ee;}(_0x56ffd0),_0x258956=(function(){function _0x1933af(_0x4b85b6){var _0x462920=this;if(this['_scene']=_0x4b85b6,this['_babylonGamepads']=[],this['_oneGamepadConnected']=!0x1,this['_isMonitoring']=!0x1,this['onGamepadDisconnectedObservable']=new _0x6ac1f7['c'](),_0x3cbe81['a']['IsWindowObjectExist']()?(this['_gamepadEventSupported']='GamepadEvent'in window,this['_gamepadSupport']=navigator['getGamepads']||navigator['webkitGetGamepads']||navigator['msGetGamepads']||navigator['webkitGamepads']):this['_gamepadEventSupported']=!0x1,this['onGamepadConnectedObservable']=new _0x6ac1f7['c'](function(_0x54b291){for(var _0x1c5b3f in _0x462920['_babylonGamepads']){var _0x15ecd4=_0x462920['_babylonGamepads'][_0x1c5b3f];_0x15ecd4&&_0x15ecd4['_isConnected']&&_0x462920['onGamepadConnectedObservable']['notifyObserver'](_0x54b291,_0x15ecd4);}}),this['_onGamepadConnectedEvent']=function(_0x4a5e7e){var _0x3af7f9,_0x5488fa=_0x4a5e7e['gamepad'];_0x5488fa['index']in _0x462920['_babylonGamepads']&&_0x462920['_babylonGamepads'][_0x5488fa['index']]['isConnected']||(_0x462920['_babylonGamepads'][_0x5488fa['index']]?((_0x3af7f9=_0x462920['_babylonGamepads'][_0x5488fa['index']])['browserGamepad']=_0x5488fa,_0x3af7f9['_isConnected']=!0x0):_0x3af7f9=_0x462920['_addNewGamepad'](_0x5488fa),_0x462920['onGamepadConnectedObservable']['notifyObservers'](_0x3af7f9),_0x462920['_startMonitoringGamepads']());},this['_onGamepadDisconnectedEvent']=function(_0x98d7ee){var _0x5f08a8=_0x98d7ee['gamepad'];for(var _0x1f464b in _0x462920['_babylonGamepads'])if(_0x462920['_babylonGamepads'][_0x1f464b]['index']===_0x5f08a8['index']){var _0x27d75b=_0x462920['_babylonGamepads'][_0x1f464b];_0x27d75b['_isConnected']=!0x1,_0x462920['onGamepadDisconnectedObservable']['notifyObservers'](_0x27d75b),_0x27d75b['dispose']&&_0x27d75b['dispose']();break;}},this['_gamepadSupport']){if(this['_updateGamepadObjects'](),this['_babylonGamepads']['length']&&this['_startMonitoringGamepads'](),this['_gamepadEventSupported']){var _0x9c64cf=this['_scene']?this['_scene']['getEngine']()['getHostWindow']():window;_0x9c64cf&&(_0x9c64cf['addEventListener']('gamepadconnected',this['_onGamepadConnectedEvent'],!0x1),_0x9c64cf['addEventListener']('gamepaddisconnected',this['_onGamepadDisconnectedEvent'],!0x1));}else this['_startMonitoringGamepads']();}}return Object['defineProperty'](_0x1933af['prototype'],'gamepads',{'get':function(){return this['_babylonGamepads'];},'enumerable':!0x1,'configurable':!0x0}),_0x1933af['prototype']['getGamepadByType']=function(_0x1b2e0c){void 0x0===_0x1b2e0c&&(_0x1b2e0c=_0x56ffd0['XBOX']);for(var _0x49ddeb=0x0,_0x57132e=this['_babylonGamepads'];_0x49ddeb<_0x57132e['length'];_0x49ddeb++){var _0x1a4260=_0x57132e[_0x49ddeb];if(_0x1a4260&&_0x1a4260['type']===_0x1b2e0c)return _0x1a4260;}return null;},_0x1933af['prototype']['dispose']=function(){this['_gamepadEventSupported']&&(this['_onGamepadConnectedEvent']&&window['removeEventListener']('gamepadconnected',this['_onGamepadConnectedEvent']),this['_onGamepadDisconnectedEvent']&&window['removeEventListener']('gamepaddisconnected',this['_onGamepadDisconnectedEvent']),this['_onGamepadConnectedEvent']=null,this['_onGamepadDisconnectedEvent']=null),this['_babylonGamepads']['forEach'](function(_0x501363){_0x501363['dispose']();}),this['onGamepadConnectedObservable']['clear'](),this['onGamepadDisconnectedObservable']['clear'](),this['_oneGamepadConnected']=!0x1,this['_stopMonitoringGamepads'](),this['_babylonGamepads']=[];},_0x1933af['prototype']['_addNewGamepad']=function(_0x2a1d04){var _0x398bb5;this['_oneGamepadConnected']||(this['_oneGamepadConnected']=!0x0);var _0x397193=-0x1!==_0x2a1d04['id']['search']('054c'),_0x2b471a=-0x1!==_0x2a1d04['id']['search']('Xbox\x20One');return _0x398bb5=_0x2b471a||-0x1!==_0x2a1d04['id']['search']('Xbox\x20360')||-0x1!==_0x2a1d04['id']['search']('xinput')?new _0x4fe65c(_0x2a1d04['id'],_0x2a1d04['index'],_0x2a1d04,_0x2b471a):_0x397193?new _0x5e3294(_0x2a1d04['id'],_0x2a1d04['index'],_0x2a1d04):_0x2a1d04['pose']?_0x14684f['InitiateController'](_0x2a1d04):new _0x1275ec(_0x2a1d04['id'],_0x2a1d04['index'],_0x2a1d04),this['_babylonGamepads'][_0x398bb5['index']]=_0x398bb5,_0x398bb5;},_0x1933af['prototype']['_startMonitoringGamepads']=function(){this['_isMonitoring']||(this['_isMonitoring']=!0x0,this['_scene']||this['_checkGamepadsStatus']());},_0x1933af['prototype']['_stopMonitoringGamepads']=function(){this['_isMonitoring']=!0x1;},_0x1933af['prototype']['_checkGamepadsStatus']=function(){var _0x132f96=this;for(var _0x45e9d2 in(this['_updateGamepadObjects'](),this['_babylonGamepads'])){var _0x2a2ee5=this['_babylonGamepads'][_0x45e9d2];_0x2a2ee5&&_0x2a2ee5['isConnected']&&_0x2a2ee5['update']();}this['_isMonitoring']&&!this['_scene']&&_0x300b38['a']['QueueNewFrame'](function(){_0x132f96['_checkGamepadsStatus']();});},_0x1933af['prototype']['_updateGamepadObjects']=function(){for(var _0x220d0d=navigator['getGamepads']?navigator['getGamepads']():navigator['webkitGetGamepads']?navigator['webkitGetGamepads']():[],_0x287fb7=0x0;_0x287fb7<_0x220d0d['length'];_0x287fb7++){var _0x4b9761=_0x220d0d[_0x287fb7];if(_0x4b9761){if(this['_babylonGamepads'][_0x4b9761['index']])this['_babylonGamepads'][_0x287fb7]['browserGamepad']=_0x4b9761,this['_babylonGamepads'][_0x287fb7]['isConnected']||(this['_babylonGamepads'][_0x287fb7]['_isConnected']=!0x0,this['onGamepadConnectedObservable']['notifyObservers'](this['_babylonGamepads'][_0x287fb7]));else{var _0x46bd7b=this['_addNewGamepad'](_0x4b9761);this['onGamepadConnectedObservable']['notifyObservers'](_0x46bd7b);}}}},_0x1933af;}());Object['defineProperty'](_0x59370b['a']['prototype'],'gamepadManager',{'get':function(){if(!this['_gamepadManager']){this['_gamepadManager']=new _0x258956(this);var _0x7e06c=this['_getComponent'](_0x384de3['a']['NAME_GAMEPAD']);_0x7e06c||(_0x7e06c=new _0x986b92(this),this['_addComponent'](_0x7e06c));}return this['_gamepadManager'];},'enumerable':!0x0,'configurable':!0x0}),_0x3d384c['prototype']['addGamepad']=function(){return this['add'](new _0x47ef9b()),this;},_0x1f548e['prototype']['addGamepad']=function(){return this['add'](new _0x588ef7()),this;};var _0x986b92=(function(){function _0x5efa65(_0x8afc){this['name']=_0x384de3['a']['NAME_GAMEPAD'],this['scene']=_0x8afc;}return _0x5efa65['prototype']['register']=function(){this['scene']['_beforeCameraUpdateStage']['registerStep'](_0x384de3['a']['STEP_BEFORECAMERAUPDATE_GAMEPAD'],this,this['_beforeCameraUpdate']);},_0x5efa65['prototype']['rebuild']=function(){},_0x5efa65['prototype']['dispose']=function(){var _0x4e4930=this['scene']['_gamepadManager'];_0x4e4930&&(_0x4e4930['dispose'](),this['scene']['_gamepadManager']=null);},_0x5efa65['prototype']['_beforeCameraUpdate']=function(){var _0x326c43=this['scene']['_gamepadManager'];_0x326c43&&_0x326c43['_isMonitoring']&&_0x326c43['_checkGamepadsStatus']();},_0x5efa65;}());_0x43169a['a']['AddNodeConstructor']('FreeCamera',function(_0xd12618,_0xf32ec5){return function(){return new _0x2d65de(_0xd12618,_0x74d525['e']['Zero'](),_0xf32ec5);};});var _0x2d65de=function(_0x3ebb9f){function _0x2431de(_0x2ef973,_0x4c2376,_0x27e2f1){var _0x3c8905=_0x3ebb9f['call'](this,_0x2ef973,_0x4c2376,_0x27e2f1)||this;return _0x3c8905['inputs']['addGamepad'](),_0x3c8905;}return Object(_0x18e13d['d'])(_0x2431de,_0x3ebb9f),Object['defineProperty'](_0x2431de['prototype'],'gamepadAngularSensibility',{'get':function(){var _0x336f2b=this['inputs']['attached']['gamepad'];return _0x336f2b?_0x336f2b['gamepadAngularSensibility']:0x0;},'set':function(_0x4676e5){var _0x1fe3c6=this['inputs']['attached']['gamepad'];_0x1fe3c6&&(_0x1fe3c6['gamepadAngularSensibility']=_0x4676e5);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2431de['prototype'],'gamepadMoveSensibility',{'get':function(){var _0xd982a6=this['inputs']['attached']['gamepad'];return _0xd982a6?_0xd982a6['gamepadMoveSensibility']:0x0;},'set':function(_0x152a33){var _0x5a9ee9=this['inputs']['attached']['gamepad'];_0x5a9ee9&&(_0x5a9ee9['gamepadMoveSensibility']=_0x152a33);},'enumerable':!0x1,'configurable':!0x0}),_0x2431de['prototype']['getClassName']=function(){return'UniversalCamera';},_0x2431de;}(_0x593a2c);_0x568729['a']['_createDefaultParsedCamera']=function(_0x4ed581,_0x22230f){return new _0x2d65de(_0x4ed581,_0x74d525['e']['Zero'](),_0x22230f);},_0x43169a['a']['AddNodeConstructor']('GamepadCamera',function(_0x5ec18f,_0x2fa259){return function(){return new _0x3b87d8(_0x5ec18f,_0x74d525['e']['Zero'](),_0x2fa259);};});var _0x3b87d8=function(_0x5d4441){function _0x2cfb61(_0x22b9a9,_0x113b68,_0x380df1){return _0x5d4441['call'](this,_0x22b9a9,_0x113b68,_0x380df1)||this;}return Object(_0x18e13d['d'])(_0x2cfb61,_0x5d4441),_0x2cfb61['prototype']['getClassName']=function(){return'GamepadCamera';},_0x2cfb61;}(_0x2d65de),_0x2266f9=_0x162675(0x21),_0x494b01=_0x162675(0x5),_0x102eec='\x0aattribute\x20vec2\x20position;\x0auniform\x20vec2\x20scale;\x0a\x0avarying\x20vec2\x20vUV;\x0aconst\x20vec2\x20madd=vec2(0.5,0.5);\x0avoid\x20main(void)\x20{\x0avUV=(position*madd+madd)*scale;\x0agl_Position=vec4(position,0.0,1.0);\x0a}';_0x494b01['a']['ShadersStore']['postprocessVertexShader']=_0x102eec;var _0x36b220=_0x162675(0x66);_0x26966b['a']['prototype']['createRenderTargetTexture']=function(_0x5838b4,_0x5240f6){var _0x456e7d=new _0x36b220['a']();void 0x0!==_0x5240f6&&'object'==typeof _0x5240f6?(_0x456e7d['generateMipMaps']=_0x5240f6['generateMipMaps'],_0x456e7d['generateDepthBuffer']=!!_0x5240f6['generateDepthBuffer'],_0x456e7d['generateStencilBuffer']=!!_0x5240f6['generateStencilBuffer'],_0x456e7d['type']=void 0x0===_0x5240f6['type']?_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']:_0x5240f6['type'],_0x456e7d['samplingMode']=void 0x0===_0x5240f6['samplingMode']?_0x2103ba['a']['TEXTURE_TRILINEAR_SAMPLINGMODE']:_0x5240f6['samplingMode'],_0x456e7d['format']=void 0x0===_0x5240f6['format']?_0x2103ba['a']['TEXTUREFORMAT_RGBA']:_0x5240f6['format']):(_0x456e7d['generateMipMaps']=_0x5240f6,_0x456e7d['generateDepthBuffer']=!0x0,_0x456e7d['generateStencilBuffer']=!0x1,_0x456e7d['type']=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'],_0x456e7d['samplingMode']=_0x2103ba['a']['TEXTURE_TRILINEAR_SAMPLINGMODE'],_0x456e7d['format']=_0x2103ba['a']['TEXTUREFORMAT_RGBA']),(_0x456e7d['type']!==_0x2103ba['a']['TEXTURETYPE_FLOAT']||this['_caps']['textureFloatLinearFiltering'])&&(_0x456e7d['type']!==_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT']||this['_caps']['textureHalfFloatLinearFiltering'])||(_0x456e7d['samplingMode']=_0x2103ba['a']['TEXTURE_NEAREST_SAMPLINGMODE']),_0x456e7d['type']!==_0x2103ba['a']['TEXTURETYPE_FLOAT']||this['_caps']['textureFloat']||(_0x456e7d['type']=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'],_0x75193d['a']['Warn']('Float\x20textures\x20are\x20not\x20supported.\x20Render\x20target\x20forced\x20to\x20TEXTURETYPE_UNSIGNED_BYTE\x20type'));var _0x31a448=this['_gl'],_0x3f9e7b=new _0x21ea74['a'](this,_0x21ea74['b']['RenderTarget']),_0x490ddf=_0x5838b4['width']||_0x5838b4,_0x5e807b=_0x5838b4['height']||_0x5838b4,_0x1f620a=_0x5838b4['layers']||0x0,_0xf20466=this['_getSamplingParameters'](_0x456e7d['samplingMode'],!!_0x456e7d['generateMipMaps']),_0xa7f43b=0x0!==_0x1f620a?_0x31a448['TEXTURE_2D_ARRAY']:_0x31a448['TEXTURE_2D'],_0x313645=this['_getRGBABufferInternalSizedFormat'](_0x456e7d['type'],_0x456e7d['format']),_0x3f05ee=this['_getInternalFormat'](_0x456e7d['format']),_0x4ff49c=this['_getWebGLTextureType'](_0x456e7d['type']);this['_bindTextureDirectly'](_0xa7f43b,_0x3f9e7b),0x0!==_0x1f620a?(_0x3f9e7b['is2DArray']=!0x0,_0x31a448['texImage3D'](_0xa7f43b,0x0,_0x313645,_0x490ddf,_0x5e807b,_0x1f620a,0x0,_0x3f05ee,_0x4ff49c,null)):_0x31a448['texImage2D'](_0xa7f43b,0x0,_0x313645,_0x490ddf,_0x5e807b,0x0,_0x3f05ee,_0x4ff49c,null),_0x31a448['texParameteri'](_0xa7f43b,_0x31a448['TEXTURE_MAG_FILTER'],_0xf20466['mag']),_0x31a448['texParameteri'](_0xa7f43b,_0x31a448['TEXTURE_MIN_FILTER'],_0xf20466['min']),_0x31a448['texParameteri'](_0xa7f43b,_0x31a448['TEXTURE_WRAP_S'],_0x31a448['CLAMP_TO_EDGE']),_0x31a448['texParameteri'](_0xa7f43b,_0x31a448['TEXTURE_WRAP_T'],_0x31a448['CLAMP_TO_EDGE']),_0x456e7d['generateMipMaps']&&this['_gl']['generateMipmap'](_0xa7f43b),this['_bindTextureDirectly'](_0xa7f43b,null);var _0xf6bb7a=this['_currentFramebuffer'],_0x25ce31=_0x31a448['createFramebuffer']();return this['_bindUnboundFramebuffer'](_0x25ce31),_0x3f9e7b['_depthStencilBuffer']=this['_setupFramebufferDepthAttachments'](!!_0x456e7d['generateStencilBuffer'],_0x456e7d['generateDepthBuffer'],_0x490ddf,_0x5e807b),_0x3f9e7b['is2DArray']||_0x31a448['framebufferTexture2D'](_0x31a448['FRAMEBUFFER'],_0x31a448['COLOR_ATTACHMENT0'],_0x31a448['TEXTURE_2D'],_0x3f9e7b['_webGLTexture'],0x0),this['_bindUnboundFramebuffer'](_0xf6bb7a),_0x3f9e7b['_framebuffer']=_0x25ce31,_0x3f9e7b['baseWidth']=_0x490ddf,_0x3f9e7b['baseHeight']=_0x5e807b,_0x3f9e7b['width']=_0x490ddf,_0x3f9e7b['height']=_0x5e807b,_0x3f9e7b['depth']=_0x1f620a,_0x3f9e7b['isReady']=!0x0,_0x3f9e7b['samples']=0x1,_0x3f9e7b['generateMipMaps']=!!_0x456e7d['generateMipMaps'],_0x3f9e7b['samplingMode']=_0x456e7d['samplingMode'],_0x3f9e7b['type']=_0x456e7d['type'],_0x3f9e7b['format']=_0x456e7d['format'],_0x3f9e7b['_generateDepthBuffer']=_0x456e7d['generateDepthBuffer'],_0x3f9e7b['_generateStencilBuffer']=!!_0x456e7d['generateStencilBuffer'],this['_internalTexturesCache']['push'](_0x3f9e7b),_0x3f9e7b;},_0x26966b['a']['prototype']['createDepthStencilTexture']=function(_0x162474,_0x3c646a){if(_0x3c646a['isCube']){var _0x1b7dec=_0x162474['width']||_0x162474;return this['_createDepthStencilCubeTexture'](_0x1b7dec,_0x3c646a);}return this['_createDepthStencilTexture'](_0x162474,_0x3c646a);},_0x26966b['a']['prototype']['_createDepthStencilTexture']=function(_0x4c77ec,_0x425c8b){var _0x482b91=this['_gl'],_0x1792a2=_0x4c77ec['layers']||0x0,_0x129fb5=0x0!==_0x1792a2?_0x482b91['TEXTURE_2D_ARRAY']:_0x482b91['TEXTURE_2D'],_0x2f74cc=new _0x21ea74['a'](this,_0x21ea74['b']['Depth']);if(!this['_caps']['depthTextureExtension'])return _0x75193d['a']['Error']('Depth\x20texture\x20is\x20not\x20supported\x20by\x20your\x20browser\x20or\x20hardware.'),_0x2f74cc;var _0xcd436e=Object(_0x18e13d['a'])({'bilinearFiltering':!0x1,'comparisonFunction':0x0,'generateStencil':!0x1},_0x425c8b);this['_bindTextureDirectly'](_0x129fb5,_0x2f74cc,!0x0),this['_setupDepthStencilTexture'](_0x2f74cc,_0x4c77ec,_0xcd436e['generateStencil'],_0xcd436e['bilinearFiltering'],_0xcd436e['comparisonFunction']);var _0x340e78=_0xcd436e['generateStencil']?_0x482b91['UNSIGNED_INT_24_8']:_0x482b91['UNSIGNED_INT'],_0x2d01a7=_0xcd436e['generateStencil']?_0x482b91['DEPTH_STENCIL']:_0x482b91['DEPTH_COMPONENT'],_0x321972=_0x2d01a7;return this['webGLVersion']>0x1&&(_0x321972=_0xcd436e['generateStencil']?_0x482b91['DEPTH24_STENCIL8']:_0x482b91['DEPTH_COMPONENT24']),_0x2f74cc['is2DArray']?_0x482b91['texImage3D'](_0x129fb5,0x0,_0x321972,_0x2f74cc['width'],_0x2f74cc['height'],_0x1792a2,0x0,_0x2d01a7,_0x340e78,null):_0x482b91['texImage2D'](_0x129fb5,0x0,_0x321972,_0x2f74cc['width'],_0x2f74cc['height'],0x0,_0x2d01a7,_0x340e78,null),this['_bindTextureDirectly'](_0x129fb5,null),_0x2f74cc;};var _0x5cae84=(function(){function _0x3b85aa(_0x54c099,_0x210e85,_0x4033ce,_0x4ae1a5,_0x137e20,_0x475eca,_0x354211,_0x557d8f,_0x478ae2,_0x25bf4a,_0x5b4f87,_0x38cf4b,_0x6bce48,_0x130b38,_0x1a9508){void 0x0===_0x354211&&(_0x354211=_0x2103ba['a']['TEXTURE_NEAREST_SAMPLINGMODE']),void 0x0===_0x25bf4a&&(_0x25bf4a=null),void 0x0===_0x5b4f87&&(_0x5b4f87=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),void 0x0===_0x38cf4b&&(_0x38cf4b='postprocess'),void 0x0===_0x130b38&&(_0x130b38=!0x1),void 0x0===_0x1a9508&&(_0x1a9508=_0x2103ba['a']['TEXTUREFORMAT_RGBA']),this['width']=-0x1,this['height']=-0x1,this['nodeMaterialSource']=null,this['_outputTexture']=null,this['autoClear']=!0x0,this['alphaMode']=_0x2103ba['a']['ALPHA_DISABLE'],this['animations']=new Array(),this['enablePixelPerfectMode']=!0x1,this['forceFullscreenViewport']=!0x0,this['scaleMode']=_0x2103ba['a']['SCALEMODE_FLOOR'],this['alwaysForcePOT']=!0x1,this['_samples']=0x1,this['adaptScaleToCurrentViewport']=!0x1,this['_reusable']=!0x1,this['_textures']=new _0x2266f9['a'](0x2),this['_currentRenderTextureInd']=0x0,this['_scaleRatio']=new _0x74d525['d'](0x1,0x1),this['_texelSize']=_0x74d525['d']['Zero'](),this['onActivateObservable']=new _0x6ac1f7['c'](),this['onSizeChangedObservable']=new _0x6ac1f7['c'](),this['onApplyObservable']=new _0x6ac1f7['c'](),this['onBeforeRenderObservable']=new _0x6ac1f7['c'](),this['onAfterRenderObservable']=new _0x6ac1f7['c'](),this['name']=_0x54c099,null!=_0x475eca?(this['_camera']=_0x475eca,this['_scene']=_0x475eca['getScene'](),_0x475eca['attachPostProcess'](this),this['_engine']=this['_scene']['getEngine'](),this['_scene']['postProcesses']['push'](this),this['uniqueId']=this['_scene']['getUniqueId']()):_0x557d8f&&(this['_engine']=_0x557d8f,this['_engine']['postProcesses']['push'](this)),this['_options']=_0x137e20,this['renderTargetSamplingMode']=_0x354211||_0x2103ba['a']['TEXTURE_NEAREST_SAMPLINGMODE'],this['_reusable']=_0x478ae2||!0x1,this['_textureType']=_0x5b4f87,this['_textureFormat']=_0x1a9508,this['_samplers']=_0x4ae1a5||[],this['_samplers']['push']('textureSampler'),this['_fragmentUrl']=_0x210e85,this['_vertexUrl']=_0x38cf4b,this['_parameters']=_0x4033ce||[],this['_parameters']['push']('scale'),this['_indexParameters']=_0x6bce48,_0x130b38||this['updateEffect'](_0x25bf4a);}return Object['defineProperty'](_0x3b85aa['prototype'],'samples',{'get':function(){return this['_samples'];},'set':function(_0x29734e){var _0x40815a=this;this['_samples']=Math['min'](_0x29734e,this['_engine']['getCaps']()['maxMSAASamples']),this['_textures']['forEach'](function(_0x569547){_0x569547['samples']!==_0x40815a['_samples']&&_0x40815a['_engine']['updateRenderTargetTextureSampleCount'](_0x569547,_0x40815a['_samples']);});},'enumerable':!0x1,'configurable':!0x0}),_0x3b85aa['prototype']['getEffectName']=function(){return this['_fragmentUrl'];},Object['defineProperty'](_0x3b85aa['prototype'],'onActivate',{'set':function(_0x24b37d){this['_onActivateObserver']&&this['onActivateObservable']['remove'](this['_onActivateObserver']),_0x24b37d&&(this['_onActivateObserver']=this['onActivateObservable']['add'](_0x24b37d));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3b85aa['prototype'],'onSizeChanged',{'set':function(_0x5a8711){this['_onSizeChangedObserver']&&this['onSizeChangedObservable']['remove'](this['_onSizeChangedObserver']),this['_onSizeChangedObserver']=this['onSizeChangedObservable']['add'](_0x5a8711);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3b85aa['prototype'],'onApply',{'set':function(_0x49843c){this['_onApplyObserver']&&this['onApplyObservable']['remove'](this['_onApplyObserver']),this['_onApplyObserver']=this['onApplyObservable']['add'](_0x49843c);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3b85aa['prototype'],'onBeforeRender',{'set':function(_0x1b8c7d){this['_onBeforeRenderObserver']&&this['onBeforeRenderObservable']['remove'](this['_onBeforeRenderObserver']),this['_onBeforeRenderObserver']=this['onBeforeRenderObservable']['add'](_0x1b8c7d);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3b85aa['prototype'],'onAfterRender',{'set':function(_0x2c5b17){this['_onAfterRenderObserver']&&this['onAfterRenderObservable']['remove'](this['_onAfterRenderObserver']),this['_onAfterRenderObserver']=this['onAfterRenderObservable']['add'](_0x2c5b17);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3b85aa['prototype'],'inputTexture',{'get':function(){return this['_textures']['data'][this['_currentRenderTextureInd']];},'set':function(_0x123b82){this['_forcedOutputTexture']=_0x123b82;},'enumerable':!0x1,'configurable':!0x0}),_0x3b85aa['prototype']['restoreDefaultInputTexture']=function(){this['_forcedOutputTexture']=null;},_0x3b85aa['prototype']['getCamera']=function(){return this['_camera'];},Object['defineProperty'](_0x3b85aa['prototype'],'texelSize',{'get':function(){return this['_shareOutputWithPostProcess']?this['_shareOutputWithPostProcess']['texelSize']:(this['_forcedOutputTexture']&&this['_texelSize']['copyFromFloats'](0x1/this['_forcedOutputTexture']['width'],0x1/this['_forcedOutputTexture']['height']),this['_texelSize']);},'enumerable':!0x1,'configurable':!0x0}),_0x3b85aa['prototype']['getClassName']=function(){return'PostProcess';},_0x3b85aa['prototype']['getEngine']=function(){return this['_engine'];},_0x3b85aa['prototype']['getEffect']=function(){return this['_effect'];},_0x3b85aa['prototype']['shareOutputWith']=function(_0x5e1069){return this['_disposeTextures'](),this['_shareOutputWithPostProcess']=_0x5e1069,this;},_0x3b85aa['prototype']['useOwnOutput']=function(){0x0==this['_textures']['length']&&(this['_textures']=new _0x2266f9['a'](0x2)),this['_shareOutputWithPostProcess']=null;},_0x3b85aa['prototype']['updateEffect']=function(_0x328c82,_0x374cda,_0x57804e,_0x2a5e8a,_0x1e1845,_0x364b36,_0x490d0d,_0x4b1679){void 0x0===_0x328c82&&(_0x328c82=null),void 0x0===_0x374cda&&(_0x374cda=null),void 0x0===_0x57804e&&(_0x57804e=null),this['_effect']=this['_engine']['createEffect']({'vertex':null!=_0x490d0d?_0x490d0d:this['_vertexUrl'],'fragment':null!=_0x4b1679?_0x4b1679:this['_fragmentUrl']},['position'],_0x374cda||this['_parameters'],_0x57804e||this['_samplers'],null!==_0x328c82?_0x328c82:'',void 0x0,_0x1e1845,_0x364b36,_0x2a5e8a||this['_indexParameters']);},_0x3b85aa['prototype']['isReusable']=function(){return this['_reusable'];},_0x3b85aa['prototype']['markTextureDirty']=function(){this['width']=-0x1;},_0x3b85aa['prototype']['activate']=function(_0x288ded,_0x394cd8,_0x1e1d48){var _0xd2f6cc=this;void 0x0===_0x394cd8&&(_0x394cd8=null);var _0x2e9b5f=(_0x288ded=_0x288ded||this['_camera'])['getScene'](),_0x1fba43=_0x2e9b5f['getEngine'](),_0xb0d054=_0x1fba43['getCaps']()['maxTextureSize'],_0x1b0c32=(_0x394cd8?_0x394cd8['width']:this['_engine']['getRenderWidth'](!0x0))*this['_options']|0x0,_0x160264=(_0x394cd8?_0x394cd8['height']:this['_engine']['getRenderHeight'](!0x0))*this['_options']|0x0,_0x22bbe5=_0x288ded['parent'];!_0x22bbe5||_0x22bbe5['leftCamera']!=_0x288ded&&_0x22bbe5['rightCamera']!=_0x288ded||(_0x1b0c32/=0x2);var _0x3ddd27,_0x394d01=this['_options']['width']||_0x1b0c32,_0x5cf71b=this['_options']['height']||_0x160264,_0x1f0eed=this['renderTargetSamplingMode']!==_0x2103ba['a']['TEXTURE_NEAREST_LINEAR']&&this['renderTargetSamplingMode']!==_0x2103ba['a']['TEXTURE_NEAREST_NEAREST']&&this['renderTargetSamplingMode']!==_0x2103ba['a']['TEXTURE_LINEAR_LINEAR'];if(!this['_shareOutputWithPostProcess']&&!this['_forcedOutputTexture']){if(this['adaptScaleToCurrentViewport']){var _0x408ff6=_0x1fba43['currentViewport'];_0x408ff6&&(_0x394d01*=_0x408ff6['width'],_0x5cf71b*=_0x408ff6['height']);}if((_0x1f0eed||this['alwaysForcePOT'])&&(this['_options']['width']||(_0x394d01=_0x1fba43['needPOTTextures']?_0x300b38['a']['GetExponentOfTwo'](_0x394d01,_0xb0d054,this['scaleMode']):_0x394d01),this['_options']['height']||(_0x5cf71b=_0x1fba43['needPOTTextures']?_0x300b38['a']['GetExponentOfTwo'](_0x5cf71b,_0xb0d054,this['scaleMode']):_0x5cf71b)),this['width']!==_0x394d01||this['height']!==_0x5cf71b){if(this['_textures']['length']>0x0){for(var _0x58952e=0x0;_0x58952e0x0){for(var _0x6f4333=0x0;_0x6f43330x0){var _0x496eb6=this['_camera']['_getFirstPostProcess']();_0x496eb6&&_0x496eb6['markTextureDirty']();}this['onActivateObservable']['clear'](),this['onAfterRenderObservable']['clear'](),this['onApplyObservable']['clear'](),this['onBeforeRenderObservable']['clear'](),this['onSizeChangedObservable']['clear']();}},_0x3b85aa['prototype']['serialize']=function(){var _0x2b22cd=_0x495d06['a']['Serialize'](this);return _0x2b22cd['customType']='BABYLON.'+this['getClassName'](),_0x2b22cd['cameraId']=this['getCamera']()['id'],_0x2b22cd['reusable']=this['_reusable'],_0x2b22cd['options']=this['_options'],_0x2b22cd['textureType']=this['_textureType'],_0x2b22cd;},_0x3b85aa['Parse']=function(_0x560bf2,_0x4ec592,_0x5dd8bb){var _0x100d62=_0x3cd573['a']['GetClass'](_0x560bf2['customType']);if(!_0x100d62||!_0x100d62['_Parse'])return null;var _0x490f96=_0x4ec592['getCameraByID'](_0x560bf2['cameraId']);return _0x490f96?_0x100d62['_Parse'](_0x560bf2,_0x490f96,_0x4ec592,_0x5dd8bb):null;},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3b85aa['prototype'],'uniqueId',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3b85aa['prototype'],'name',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3b85aa['prototype'],'width',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3b85aa['prototype'],'height',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3b85aa['prototype'],'renderTargetSamplingMode',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['f'])()],_0x3b85aa['prototype'],'clearColor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3b85aa['prototype'],'autoClear',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3b85aa['prototype'],'alphaMode',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3b85aa['prototype'],'alphaConstants',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3b85aa['prototype'],'enablePixelPerfectMode',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3b85aa['prototype'],'forceFullscreenViewport',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3b85aa['prototype'],'scaleMode',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3b85aa['prototype'],'alwaysForcePOT',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])('samples')],_0x3b85aa['prototype'],'_samples',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3b85aa['prototype'],'adaptScaleToCurrentViewport',void 0x0),_0x3b85aa;}());_0x3cd573['a']['RegisteredTypes']['BABYLON.PostProcess']=_0x5cae84;var _0x3c5ad3='\x0avarying\x20vec2\x20vUV;\x0auniform\x20sampler2D\x20textureSampler;\x0avoid\x20main(void)\x0a{\x0agl_FragColor=texture2D(textureSampler,vUV);\x0a}';_0x494b01['a']['ShadersStore']['passPixelShader']=_0x3c5ad3;var _0x2fb808='\x0avarying\x20vec2\x20vUV;\x0auniform\x20samplerCube\x20textureSampler;\x0avoid\x20main(void)\x0a{\x0avec2\x20uv=vUV*2.0-1.0;\x0a#ifdef\x20POSITIVEX\x0agl_FragColor=textureCube(textureSampler,vec3(1.001,uv.y,uv.x));\x0a#endif\x0a#ifdef\x20NEGATIVEX\x0agl_FragColor=textureCube(textureSampler,vec3(-1.001,uv.y,uv.x));\x0a#endif\x0a#ifdef\x20POSITIVEY\x0agl_FragColor=textureCube(textureSampler,vec3(uv.y,1.001,uv.x));\x0a#endif\x0a#ifdef\x20NEGATIVEY\x0agl_FragColor=textureCube(textureSampler,vec3(uv.y,-1.001,uv.x));\x0a#endif\x0a#ifdef\x20POSITIVEZ\x0agl_FragColor=textureCube(textureSampler,vec3(uv,1.001));\x0a#endif\x0a#ifdef\x20NEGATIVEZ\x0agl_FragColor=textureCube(textureSampler,vec3(uv,-1.001));\x0a#endif\x0a}';_0x494b01['a']['ShadersStore']['passCubePixelShader']=_0x2fb808;var _0x3f9daa=function(_0x109958){function _0x49fb41(_0x16e79a,_0x3e90c2,_0x54fa6f,_0x33bad7,_0x487716,_0x539e06,_0x353d16,_0x68b14e){return void 0x0===_0x54fa6f&&(_0x54fa6f=null),void 0x0===_0x353d16&&(_0x353d16=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),void 0x0===_0x68b14e&&(_0x68b14e=!0x1),_0x109958['call'](this,_0x16e79a,'pass',null,null,_0x3e90c2,_0x54fa6f,_0x33bad7,_0x487716,_0x539e06,void 0x0,_0x353d16,void 0x0,null,_0x68b14e)||this;}return Object(_0x18e13d['d'])(_0x49fb41,_0x109958),_0x49fb41['prototype']['getClassName']=function(){return'PassPostProcess';},_0x49fb41['_Parse']=function(_0x398487,_0x5ba570,_0x3f9db2,_0x445925){return _0x495d06['a']['Parse'](function(){return new _0x49fb41(_0x398487['name'],_0x398487['options'],_0x5ba570,_0x398487['renderTargetSamplingMode'],_0x3f9db2['getEngine'](),_0x398487['reusable']);},_0x398487,_0x3f9db2,_0x445925);},_0x49fb41;}(_0x5cae84);_0x3cd573['a']['RegisteredTypes']['BABYLON.PassPostProcess']=_0x3f9daa;var _0xc9943e=function(_0x18e3bc){function _0x1d24b4(_0x4a633c,_0x12333f,_0x4e1c81,_0x11582f,_0x3eba3c,_0xcfd566,_0x2533bb,_0x20af4e){void 0x0===_0x4e1c81&&(_0x4e1c81=null),void 0x0===_0x2533bb&&(_0x2533bb=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),void 0x0===_0x20af4e&&(_0x20af4e=!0x1);var _0x28c7ed=_0x18e3bc['call'](this,_0x4a633c,'passCube',null,null,_0x12333f,_0x4e1c81,_0x11582f,_0x3eba3c,_0xcfd566,'#define\x20POSITIVEX',_0x2533bb,void 0x0,null,_0x20af4e)||this;return _0x28c7ed['_face']=0x0,_0x28c7ed;}return Object(_0x18e13d['d'])(_0x1d24b4,_0x18e3bc),Object['defineProperty'](_0x1d24b4['prototype'],'face',{'get':function(){return this['_face'];},'set':function(_0x1b096d){if(!(_0x1b096d<0x0||_0x1b096d>0x5))switch(this['_face']=_0x1b096d,this['_face']){case 0x0:this['updateEffect']('#define\x20POSITIVEX');break;case 0x1:this['updateEffect']('#define\x20NEGATIVEX');break;case 0x2:this['updateEffect']('#define\x20POSITIVEY');break;case 0x3:this['updateEffect']('#define\x20NEGATIVEY');break;case 0x4:this['updateEffect']('#define\x20POSITIVEZ');break;case 0x5:this['updateEffect']('#define\x20NEGATIVEZ');}},'enumerable':!0x1,'configurable':!0x0}),_0x1d24b4['prototype']['getClassName']=function(){return'PassCubePostProcess';},_0x1d24b4['_Parse']=function(_0x499a51,_0x17d596,_0x425222,_0x51e95b){return _0x495d06['a']['Parse'](function(){return new _0x1d24b4(_0x499a51['name'],_0x499a51['options'],_0x17d596,_0x499a51['renderTargetSamplingMode'],_0x425222['getEngine'](),_0x499a51['reusable']);},_0x499a51,_0x425222,_0x51e95b);},_0x1d24b4;}(_0x5cae84);_0x300b38['a']['_RescalePostProcessFactory']=function(_0x8ac749){return new _0x3f9daa('rescale',0x1,null,_0x2103ba['a']['TEXTURE_BILINEAR_SAMPLINGMODE'],_0x8ac749,!0x1,_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']);};var _0x477041='\x0avarying\x20vec2\x20vUV;\x0auniform\x20sampler2D\x20textureSampler;\x0auniform\x20sampler2D\x20leftSampler;\x0avoid\x20main(void)\x0a{\x0avec4\x20leftFrag=texture2D(leftSampler,vUV);\x0aleftFrag=vec4(1.0,leftFrag.g,leftFrag.b,1.0);\x0avec4\x20rightFrag=texture2D(textureSampler,vUV);\x0arightFrag=vec4(rightFrag.r,1.0,1.0,1.0);\x0agl_FragColor=vec4(rightFrag.rgb*leftFrag.rgb,1.0);\x0a}';_0x494b01['a']['ShadersStore']['anaglyphPixelShader']=_0x477041;var _0x48ece4=function(_0x147a08){function _0x1268df(_0x3ce0b0,_0x50b3e0,_0x14ee78,_0x24d86c,_0x3f40ec,_0x446ad3){var _0xc9305e=_0x147a08['call'](this,_0x3ce0b0,'anaglyph',null,['leftSampler'],_0x50b3e0,_0x14ee78[0x1],_0x24d86c,_0x3f40ec,_0x446ad3)||this;return _0xc9305e['_passedProcess']=_0x14ee78[0x0]['_rigPostProcess'],_0xc9305e['onApplyObservable']['add'](function(_0x596917){_0x596917['setTextureFromPostProcess']('leftSampler',_0xc9305e['_passedProcess']);}),_0xc9305e;}return Object(_0x18e13d['d'])(_0x1268df,_0x147a08),_0x1268df['prototype']['getClassName']=function(){return'AnaglyphPostProcess';},_0x1268df;}(_0x5cae84);_0x3cd573['a']['RegisteredTypes']['BABYLON.AnaglyphPostProcess']=_0x48ece4,_0x568729['a']['_setStereoscopicAnaglyphRigMode']=function(_0x46a00b){_0x46a00b['_rigCameras'][0x0]['_rigPostProcess']=new _0x3f9daa(_0x46a00b['name']+'_passthru',0x1,_0x46a00b['_rigCameras'][0x0]),_0x46a00b['_rigCameras'][0x1]['_rigPostProcess']=new _0x48ece4(_0x46a00b['name']+'_anaglyph',0x1,_0x46a00b['_rigCameras']);},_0x43169a['a']['AddNodeConstructor']('AnaglyphArcRotateCamera',function(_0x46ef97,_0x45f097,_0x5c31d5){return function(){return new _0x504aa7(_0x46ef97,0x0,0x0,0x1,_0x74d525['e']['Zero'](),_0x5c31d5['interaxial_distance'],_0x45f097);};});var _0x504aa7=function(_0x5a5033){function _0x3d9d1e(_0x4efba8,_0x523ded,_0xf2b842,_0x5b7606,_0x18f5b9,_0x4ffaad,_0x32ad29){var _0x3d32b4=_0x5a5033['call'](this,_0x4efba8,_0x523ded,_0xf2b842,_0x5b7606,_0x18f5b9,_0x32ad29)||this;return _0x3d32b4['interaxialDistance']=_0x4ffaad,_0x3d32b4['setCameraRigMode'](_0x568729['a']['RIG_MODE_STEREOSCOPIC_ANAGLYPH'],{'interaxialDistance':_0x4ffaad}),_0x3d32b4;}return Object(_0x18e13d['d'])(_0x3d9d1e,_0x5a5033),_0x3d9d1e['prototype']['getClassName']=function(){return'AnaglyphArcRotateCamera';},_0x3d9d1e;}(_0xe57e08);_0x43169a['a']['AddNodeConstructor']('AnaglyphFreeCamera',function(_0x3b2db1,_0x49d0ee,_0xaafd31){return function(){return new _0x421e11(_0x3b2db1,_0x74d525['e']['Zero'](),_0xaafd31['interaxial_distance'],_0x49d0ee);};});var _0x421e11=function(_0x18873c){function _0x1b93fa(_0x1b892f,_0xccd66d,_0x173ba9,_0x541ae7){var _0xad82e1=_0x18873c['call'](this,_0x1b892f,_0xccd66d,_0x541ae7)||this;return _0xad82e1['interaxialDistance']=_0x173ba9,_0xad82e1['setCameraRigMode'](_0x568729['a']['RIG_MODE_STEREOSCOPIC_ANAGLYPH'],{'interaxialDistance':_0x173ba9}),_0xad82e1;}return Object(_0x18e13d['d'])(_0x1b93fa,_0x18873c),_0x1b93fa['prototype']['getClassName']=function(){return'AnaglyphFreeCamera';},_0x1b93fa;}(_0x5625b9);_0x43169a['a']['AddNodeConstructor']('AnaglyphGamepadCamera',function(_0x473937,_0x5cf07c,_0x49920c){return function(){return new _0x3644d1(_0x473937,_0x74d525['e']['Zero'](),_0x49920c['interaxial_distance'],_0x5cf07c);};});var _0x3644d1=function(_0xfffa48){function _0x432fad(_0x2f2ac1,_0x398c6a,_0x44f24f,_0x5ba1ca){var _0x928ae7=_0xfffa48['call'](this,_0x2f2ac1,_0x398c6a,_0x5ba1ca)||this;return _0x928ae7['interaxialDistance']=_0x44f24f,_0x928ae7['setCameraRigMode'](_0x568729['a']['RIG_MODE_STEREOSCOPIC_ANAGLYPH'],{'interaxialDistance':_0x44f24f}),_0x928ae7;}return Object(_0x18e13d['d'])(_0x432fad,_0xfffa48),_0x432fad['prototype']['getClassName']=function(){return'AnaglyphGamepadCamera';},_0x432fad;}(_0x3b87d8);_0x43169a['a']['AddNodeConstructor']('AnaglyphUniversalCamera',function(_0x2f740c,_0x4a5fda,_0x524647){return function(){return new _0x2a1642(_0x2f740c,_0x74d525['e']['Zero'](),_0x524647['interaxial_distance'],_0x4a5fda);};});var _0x2a1642=function(_0x41ee96){function _0x17eb1e(_0x3beb88,_0x434fcb,_0x402f27,_0x703662){var _0x3c1ffa=_0x41ee96['call'](this,_0x3beb88,_0x434fcb,_0x703662)||this;return _0x3c1ffa['interaxialDistance']=_0x402f27,_0x3c1ffa['setCameraRigMode'](_0x568729['a']['RIG_MODE_STEREOSCOPIC_ANAGLYPH'],{'interaxialDistance':_0x402f27}),_0x3c1ffa;}return Object(_0x18e13d['d'])(_0x17eb1e,_0x41ee96),_0x17eb1e['prototype']['getClassName']=function(){return'AnaglyphUniversalCamera';},_0x17eb1e;}(_0x2d65de),_0x4548b0=_0x162675(0x3a);_0x568729['a']['_setStereoscopicRigMode']=function(_0x368398){var _0x295d37=_0x368398['cameraRigMode']===_0x568729['a']['RIG_MODE_STEREOSCOPIC_SIDEBYSIDE_PARALLEL']||_0x368398['cameraRigMode']===_0x568729['a']['RIG_MODE_STEREOSCOPIC_SIDEBYSIDE_CROSSEYED'],_0x476cbf=_0x368398['cameraRigMode']===_0x568729['a']['RIG_MODE_STEREOSCOPIC_SIDEBYSIDE_CROSSEYED'];_0x368398['_rigCameras'][_0x476cbf?0x1:0x0]['viewport']=new _0x4548b0['a'](0x0,0x0,_0x295d37?0.5:0x1,_0x295d37?0x1:0.5),_0x368398['_rigCameras'][_0x476cbf?0x0:0x1]['viewport']=new _0x4548b0['a'](_0x295d37?0.5:0x0,_0x295d37?0x0:0.5,_0x295d37?0.5:0x1,_0x295d37?0x1:0.5);},_0x43169a['a']['AddNodeConstructor']('StereoscopicArcRotateCamera',function(_0x41101d,_0xbcd6bd,_0xbb3dd8){return function(){return new _0x3e1a78(_0x41101d,0x0,0x0,0x1,_0x74d525['e']['Zero'](),_0xbb3dd8['interaxial_distance'],_0xbb3dd8['isStereoscopicSideBySide'],_0xbcd6bd);};});var _0x3e1a78=function(_0x76f751){function _0xb6f447(_0xffb466,_0x165d6e,_0x47fe3b,_0x578d56,_0xa2827,_0x575eab,_0x5c154b,_0x2bd5a2){var _0x2b8b50=_0x76f751['call'](this,_0xffb466,_0x165d6e,_0x47fe3b,_0x578d56,_0xa2827,_0x2bd5a2)||this;return _0x2b8b50['interaxialDistance']=_0x575eab,_0x2b8b50['isStereoscopicSideBySide']=_0x5c154b,_0x2b8b50['setCameraRigMode'](_0x5c154b?_0x568729['a']['RIG_MODE_STEREOSCOPIC_SIDEBYSIDE_PARALLEL']:_0x568729['a']['RIG_MODE_STEREOSCOPIC_OVERUNDER'],{'interaxialDistance':_0x575eab}),_0x2b8b50;}return Object(_0x18e13d['d'])(_0xb6f447,_0x76f751),_0xb6f447['prototype']['getClassName']=function(){return'StereoscopicArcRotateCamera';},_0xb6f447;}(_0xe57e08);_0x43169a['a']['AddNodeConstructor']('StereoscopicFreeCamera',function(_0xc18623,_0x4f0245,_0x3fd5b4){return function(){return new _0x339591(_0xc18623,_0x74d525['e']['Zero'](),_0x3fd5b4['interaxial_distance'],_0x3fd5b4['isStereoscopicSideBySide'],_0x4f0245);};});var _0x339591=function(_0x212bec){function _0x45b2a0(_0x4f057f,_0x37be26,_0xb23b51,_0x22ff97,_0x4575db){var _0x319101=_0x212bec['call'](this,_0x4f057f,_0x37be26,_0x4575db)||this;return _0x319101['interaxialDistance']=_0xb23b51,_0x319101['isStereoscopicSideBySide']=_0x22ff97,_0x319101['setCameraRigMode'](_0x22ff97?_0x568729['a']['RIG_MODE_STEREOSCOPIC_SIDEBYSIDE_PARALLEL']:_0x568729['a']['RIG_MODE_STEREOSCOPIC_OVERUNDER'],{'interaxialDistance':_0xb23b51}),_0x319101;}return Object(_0x18e13d['d'])(_0x45b2a0,_0x212bec),_0x45b2a0['prototype']['getClassName']=function(){return'StereoscopicFreeCamera';},_0x45b2a0;}(_0x5625b9);_0x43169a['a']['AddNodeConstructor']('StereoscopicGamepadCamera',function(_0x46bd9f,_0x3437c4,_0x534d7d){return function(){return new _0x148052(_0x46bd9f,_0x74d525['e']['Zero'](),_0x534d7d['interaxial_distance'],_0x534d7d['isStereoscopicSideBySide'],_0x3437c4);};});var _0x148052=function(_0x211dfd){function _0x34b71e(_0x3136d1,_0x5474e2,_0x5f2ca1,_0x1b4c39,_0x1c1f96){var _0x3204a0=_0x211dfd['call'](this,_0x3136d1,_0x5474e2,_0x1c1f96)||this;return _0x3204a0['interaxialDistance']=_0x5f2ca1,_0x3204a0['isStereoscopicSideBySide']=_0x1b4c39,_0x3204a0['setCameraRigMode'](_0x1b4c39?_0x568729['a']['RIG_MODE_STEREOSCOPIC_SIDEBYSIDE_PARALLEL']:_0x568729['a']['RIG_MODE_STEREOSCOPIC_OVERUNDER'],{'interaxialDistance':_0x5f2ca1}),_0x3204a0;}return Object(_0x18e13d['d'])(_0x34b71e,_0x211dfd),_0x34b71e['prototype']['getClassName']=function(){return'StereoscopicGamepadCamera';},_0x34b71e;}(_0x3b87d8);_0x43169a['a']['AddNodeConstructor']('StereoscopicFreeCamera',function(_0x5bec9b,_0x41a62b,_0x308518){return function(){return new _0x1716b9(_0x5bec9b,_0x74d525['e']['Zero'](),_0x308518['interaxial_distance'],_0x308518['isStereoscopicSideBySide'],_0x41a62b);};});var _0x1716b9=function(_0x1bd7f1){function _0x2083dd(_0x25830e,_0x1a1b50,_0x384bb5,_0xdf1a9,_0x3b6f1f){var _0x5bfd4c=_0x1bd7f1['call'](this,_0x25830e,_0x1a1b50,_0x3b6f1f)||this;return _0x5bfd4c['interaxialDistance']=_0x384bb5,_0x5bfd4c['isStereoscopicSideBySide']=_0xdf1a9,_0x5bfd4c['setCameraRigMode'](_0xdf1a9?_0x568729['a']['RIG_MODE_STEREOSCOPIC_SIDEBYSIDE_PARALLEL']:_0x568729['a']['RIG_MODE_STEREOSCOPIC_OVERUNDER'],{'interaxialDistance':_0x384bb5}),_0x5bfd4c;}return Object(_0x18e13d['d'])(_0x2083dd,_0x1bd7f1),_0x2083dd['prototype']['getClassName']=function(){return'StereoscopicUniversalCamera';},_0x2083dd;}(_0x2d65de);_0x43169a['a']['AddNodeConstructor']('VirtualJoysticksCamera',function(_0x49bdd3,_0x2821f1){return function(){return new _0x562b40(_0x49bdd3,_0x74d525['e']['Zero'](),_0x2821f1);};});var _0x562b40=function(_0x1b5058){function _0x12b0b3(_0x2b7d8e,_0x5642d7,_0x2628de){var _0x468976=_0x1b5058['call'](this,_0x2b7d8e,_0x5642d7,_0x2628de)||this;return _0x468976['inputs']['addVirtualJoystick'](),_0x468976;}return Object(_0x18e13d['d'])(_0x12b0b3,_0x1b5058),_0x12b0b3['prototype']['getClassName']=function(){return'VirtualJoysticksCamera';},_0x12b0b3;}(_0x5625b9),_0x521280=(function(){function _0x3b509d(){this['compensateDistortion']=!0x0,this['multiviewEnabled']=!0x1;}return Object['defineProperty'](_0x3b509d['prototype'],'aspectRatio',{'get':function(){return this['hResolution']/(0x2*this['vResolution']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3b509d['prototype'],'aspectRatioFov',{'get':function(){return 0x2*Math['atan'](this['postProcessScaleFactor']*this['vScreenSize']/(0x2*this['eyeToScreenDistance']));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3b509d['prototype'],'leftHMatrix',{'get':function(){var _0x9e6b57=0x4*(this['hScreenSize']/0x4-this['lensSeparationDistance']/0x2)/this['hScreenSize'];return _0x74d525['a']['Translation'](_0x9e6b57,0x0,0x0);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3b509d['prototype'],'rightHMatrix',{'get':function(){var _0x4fca5f=0x4*(this['hScreenSize']/0x4-this['lensSeparationDistance']/0x2)/this['hScreenSize'];return _0x74d525['a']['Translation'](-_0x4fca5f,0x0,0x0);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3b509d['prototype'],'leftPreViewMatrix',{'get':function(){return _0x74d525['a']['Translation'](0.5*this['interpupillaryDistance'],0x0,0x0);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3b509d['prototype'],'rightPreViewMatrix',{'get':function(){return _0x74d525['a']['Translation'](-0.5*this['interpupillaryDistance'],0x0,0x0);},'enumerable':!0x1,'configurable':!0x0}),_0x3b509d['GetDefault']=function(){var _0x1dc44b=new _0x3b509d();return _0x1dc44b['hResolution']=0x500,_0x1dc44b['vResolution']=0x320,_0x1dc44b['hScreenSize']=0.149759993,_0x1dc44b['vScreenSize']=0.0935999975,_0x1dc44b['vScreenCenter']=0.0467999987,_0x1dc44b['eyeToScreenDistance']=0.0410000011,_0x1dc44b['lensSeparationDistance']=0.063500002,_0x1dc44b['interpupillaryDistance']=0.064000003,_0x1dc44b['distortionK']=[0x1,0.219999999,0.239999995,0x0],_0x1dc44b['chromaAbCorrection']=[0.995999992,-0.00400000019,1.01400006,0x0],_0x1dc44b['postProcessScaleFactor']=1.714605507808412,_0x1dc44b['lensCenterOffset']=0.151976421,_0x1dc44b;},_0x3b509d;}()),_0x5ca674='\x0avarying\x20vec2\x20vUV;\x0auniform\x20sampler2D\x20textureSampler;\x0auniform\x20vec2\x20LensCenter;\x0auniform\x20vec2\x20Scale;\x0auniform\x20vec2\x20ScaleIn;\x0auniform\x20vec4\x20HmdWarpParam;\x0avec2\x20HmdWarp(vec2\x20in01)\x20{\x0avec2\x20theta=(in01-LensCenter)*ScaleIn;\x0afloat\x20rSq=theta.x*theta.x+theta.y*theta.y;\x0avec2\x20rvector=theta*(HmdWarpParam.x+HmdWarpParam.y*rSq+HmdWarpParam.z*rSq*rSq+HmdWarpParam.w*rSq*rSq*rSq);\x0areturn\x20LensCenter+Scale*rvector;\x0a}\x0avoid\x20main(void)\x0a{\x0avec2\x20tc=HmdWarp(vUV);\x0aif\x20(tc.x\x20<0.0\x20||\x20tc.x>1.0\x20||\x20tc.y<0.0\x20||\x20tc.y>1.0)\x0agl_FragColor=vec4(0.0,0.0,0.0,0.0);\x0aelse{\x0agl_FragColor=texture2D(textureSampler,tc);\x0a}\x0a}';_0x494b01['a']['ShadersStore']['vrDistortionCorrectionPixelShader']=_0x5ca674;var _0x491a9b=function(_0x284b88){function _0x2e3b02(_0x2d4e65,_0xa225b1,_0x240e7a,_0x150720){var _0x51ba70=_0x284b88['call'](this,_0x2d4e65,'vrDistortionCorrection',['LensCenter','Scale','ScaleIn','HmdWarpParam'],null,_0x150720['postProcessScaleFactor'],_0xa225b1,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'])||this;return _0x51ba70['_isRightEye']=_0x240e7a,_0x51ba70['_distortionFactors']=_0x150720['distortionK'],_0x51ba70['_postProcessScaleFactor']=_0x150720['postProcessScaleFactor'],_0x51ba70['_lensCenterOffset']=_0x150720['lensCenterOffset'],_0x51ba70['adaptScaleToCurrentViewport']=!0x0,_0x51ba70['onSizeChangedObservable']['add'](function(){_0x51ba70['_scaleIn']=new _0x74d525['d'](0x2,0x2/_0x51ba70['aspectRatio']),_0x51ba70['_scaleFactor']=new _0x74d525['d'](0x1/_0x51ba70['_postProcessScaleFactor']*0.5,0x1/_0x51ba70['_postProcessScaleFactor']*0.5*_0x51ba70['aspectRatio']),_0x51ba70['_lensCenter']=new _0x74d525['d'](_0x51ba70['_isRightEye']?0.5-0.5*_0x51ba70['_lensCenterOffset']:0.5+0.5*_0x51ba70['_lensCenterOffset'],0.5);}),_0x51ba70['onApplyObservable']['add'](function(_0x420d1c){_0x420d1c['setFloat2']('LensCenter',_0x51ba70['_lensCenter']['x'],_0x51ba70['_lensCenter']['y']),_0x420d1c['setFloat2']('Scale',_0x51ba70['_scaleFactor']['x'],_0x51ba70['_scaleFactor']['y']),_0x420d1c['setFloat2']('ScaleIn',_0x51ba70['_scaleIn']['x'],_0x51ba70['_scaleIn']['y']),_0x420d1c['setFloat4']('HmdWarpParam',_0x51ba70['_distortionFactors'][0x0],_0x51ba70['_distortionFactors'][0x1],_0x51ba70['_distortionFactors'][0x2],_0x51ba70['_distortionFactors'][0x3]);}),_0x51ba70;}return Object(_0x18e13d['d'])(_0x2e3b02,_0x284b88),_0x2e3b02['prototype']['getClassName']=function(){return'VRDistortionCorrectionPostProcess';},_0x2e3b02;}(_0x5cae84),_0x50c294='precision\x20mediump\x20sampler2DArray;\x0avarying\x20vec2\x20vUV;\x0auniform\x20sampler2DArray\x20multiviewSampler;\x0auniform\x20int\x20imageIndex;\x0avoid\x20main(void)\x0a{\x0agl_FragColor=texture(multiviewSampler,vec3(vUV,imageIndex));\x0a}';_0x494b01['a']['ShadersStore']['vrMultiviewToSingleviewPixelShader']=_0x50c294;var _0x640faf=_0x162675(0x55),_0x1a1fc2=_0x162675(0x5f),_0x46a497=_0x162675(0x60);_0x26966b['a']['prototype']['createRenderTargetCubeTexture']=function(_0x16989a,_0x1ddf22){var _0xc8d64=Object(_0x18e13d['a'])({'generateMipMaps':!0x0,'generateDepthBuffer':!0x0,'generateStencilBuffer':!0x1,'type':_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'],'samplingMode':_0x2103ba['a']['TEXTURE_TRILINEAR_SAMPLINGMODE'],'format':_0x2103ba['a']['TEXTUREFORMAT_RGBA']},_0x1ddf22);_0xc8d64['generateStencilBuffer']=_0xc8d64['generateDepthBuffer']&&_0xc8d64['generateStencilBuffer'],(_0xc8d64['type']!==_0x2103ba['a']['TEXTURETYPE_FLOAT']||this['_caps']['textureFloatLinearFiltering'])&&(_0xc8d64['type']!==_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT']||this['_caps']['textureHalfFloatLinearFiltering'])||(_0xc8d64['samplingMode']=_0x2103ba['a']['TEXTURE_NEAREST_SAMPLINGMODE']);var _0x217409=this['_gl'],_0x4660d2=new _0x21ea74['a'](this,_0x21ea74['b']['RenderTarget']);this['_bindTextureDirectly'](_0x217409['TEXTURE_CUBE_MAP'],_0x4660d2,!0x0);var _0x4a834b=this['_getSamplingParameters'](_0xc8d64['samplingMode'],_0xc8d64['generateMipMaps']);_0xc8d64['type']!==_0x2103ba['a']['TEXTURETYPE_FLOAT']||this['_caps']['textureFloat']||(_0xc8d64['type']=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'],_0x75193d['a']['Warn']('Float\x20textures\x20are\x20not\x20supported.\x20Cube\x20render\x20target\x20forced\x20to\x20TEXTURETYPE_UNESIGNED_BYTE\x20type')),_0x217409['texParameteri'](_0x217409['TEXTURE_CUBE_MAP'],_0x217409['TEXTURE_MAG_FILTER'],_0x4a834b['mag']),_0x217409['texParameteri'](_0x217409['TEXTURE_CUBE_MAP'],_0x217409['TEXTURE_MIN_FILTER'],_0x4a834b['min']),_0x217409['texParameteri'](_0x217409['TEXTURE_CUBE_MAP'],_0x217409['TEXTURE_WRAP_S'],_0x217409['CLAMP_TO_EDGE']),_0x217409['texParameteri'](_0x217409['TEXTURE_CUBE_MAP'],_0x217409['TEXTURE_WRAP_T'],_0x217409['CLAMP_TO_EDGE']);for(var _0x2f48f4=0x0;_0x2f48f4<0x6;_0x2f48f4++)_0x217409['texImage2D'](_0x217409['TEXTURE_CUBE_MAP_POSITIVE_X']+_0x2f48f4,0x0,this['_getRGBABufferInternalSizedFormat'](_0xc8d64['type'],_0xc8d64['format']),_0x16989a,_0x16989a,0x0,this['_getInternalFormat'](_0xc8d64['format']),this['_getWebGLTextureType'](_0xc8d64['type']),null);var _0x3d8561=_0x217409['createFramebuffer']();return this['_bindUnboundFramebuffer'](_0x3d8561),_0x4660d2['_depthStencilBuffer']=this['_setupFramebufferDepthAttachments'](_0xc8d64['generateStencilBuffer'],_0xc8d64['generateDepthBuffer'],_0x16989a,_0x16989a),_0xc8d64['generateMipMaps']&&_0x217409['generateMipmap'](_0x217409['TEXTURE_CUBE_MAP']),this['_bindTextureDirectly'](_0x217409['TEXTURE_CUBE_MAP'],null),this['_bindUnboundFramebuffer'](null),_0x4660d2['_framebuffer']=_0x3d8561,_0x4660d2['width']=_0x16989a,_0x4660d2['height']=_0x16989a,_0x4660d2['isReady']=!0x0,_0x4660d2['isCube']=!0x0,_0x4660d2['samples']=0x1,_0x4660d2['generateMipMaps']=_0xc8d64['generateMipMaps'],_0x4660d2['samplingMode']=_0xc8d64['samplingMode'],_0x4660d2['type']=_0xc8d64['type'],_0x4660d2['format']=_0xc8d64['format'],_0x4660d2['_generateDepthBuffer']=_0xc8d64['generateDepthBuffer'],_0x4660d2['_generateStencilBuffer']=_0xc8d64['generateStencilBuffer'],this['_internalTexturesCache']['push'](_0x4660d2),_0x4660d2;};var _0x310f87=function(_0x2c4bc9){function _0x480417(_0x3c4bf2,_0x201be9,_0x167f20,_0x28452c,_0x1c1e85,_0x172e66,_0x580e07,_0x58b3d0,_0x1eb479,_0x4c2f8c,_0x7e5fcf,_0x30c6f1,_0x25c14c){void 0x0===_0x1c1e85&&(_0x1c1e85=!0x0),void 0x0===_0x172e66&&(_0x172e66=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),void 0x0===_0x580e07&&(_0x580e07=!0x1),void 0x0===_0x58b3d0&&(_0x58b3d0=_0xaf3c80['a']['TRILINEAR_SAMPLINGMODE']),void 0x0===_0x1eb479&&(_0x1eb479=!0x0),void 0x0===_0x4c2f8c&&(_0x4c2f8c=!0x1),void 0x0===_0x7e5fcf&&(_0x7e5fcf=!0x1),void 0x0===_0x30c6f1&&(_0x30c6f1=_0x2103ba['a']['TEXTUREFORMAT_RGBA']),void 0x0===_0x25c14c&&(_0x25c14c=!0x1);var _0x51fe3e=_0x2c4bc9['call'](this,null,_0x167f20,!_0x28452c)||this;return _0x51fe3e['renderParticles']=!0x0,_0x51fe3e['renderSprites']=!0x1,_0x51fe3e['ignoreCameraViewport']=!0x1,_0x51fe3e['onBeforeBindObservable']=new _0x6ac1f7['c'](),_0x51fe3e['onAfterUnbindObservable']=new _0x6ac1f7['c'](),_0x51fe3e['onBeforeRenderObservable']=new _0x6ac1f7['c'](),_0x51fe3e['onAfterRenderObservable']=new _0x6ac1f7['c'](),_0x51fe3e['onClearObservable']=new _0x6ac1f7['c'](),_0x51fe3e['onResizeObservable']=new _0x6ac1f7['c'](),_0x51fe3e['_currentRefreshId']=-0x1,_0x51fe3e['_refreshRate']=0x1,_0x51fe3e['_samples']=0x1,_0x51fe3e['boundingBoxPosition']=_0x74d525['e']['Zero'](),(_0x167f20=_0x51fe3e['getScene']())?(_0x51fe3e['_coordinatesMode']=_0xaf3c80['a']['PROJECTION_MODE'],_0x51fe3e['renderList']=new Array(),_0x51fe3e['name']=_0x3c4bf2,_0x51fe3e['isRenderTarget']=!0x0,_0x51fe3e['_initialSizeParameter']=_0x201be9,_0x51fe3e['_processSizeParameter'](_0x201be9),_0x51fe3e['_resizeObserver']=_0x51fe3e['getScene']()['getEngine']()['onResizeObservable']['add'](function(){}),_0x51fe3e['_generateMipMaps']=!!_0x28452c,_0x51fe3e['_doNotChangeAspectRatio']=_0x1c1e85,_0x51fe3e['_renderingManager']=new _0x46a497['b'](_0x167f20),_0x51fe3e['_renderingManager']['_useSceneAutoClearSetup']=!0x0,_0x7e5fcf||(_0x51fe3e['_renderTargetOptions']={'generateMipMaps':_0x28452c,'type':_0x172e66,'format':_0x30c6f1,'samplingMode':_0x58b3d0,'generateDepthBuffer':_0x1eb479,'generateStencilBuffer':_0x4c2f8c},_0x58b3d0===_0xaf3c80['a']['NEAREST_SAMPLINGMODE']&&(_0x51fe3e['wrapU']=_0xaf3c80['a']['CLAMP_ADDRESSMODE'],_0x51fe3e['wrapV']=_0xaf3c80['a']['CLAMP_ADDRESSMODE']),_0x25c14c||(_0x580e07?(_0x51fe3e['_texture']=_0x167f20['getEngine']()['createRenderTargetCubeTexture'](_0x51fe3e['getRenderSize'](),_0x51fe3e['_renderTargetOptions']),_0x51fe3e['coordinatesMode']=_0xaf3c80['a']['INVCUBIC_MODE'],_0x51fe3e['_textureMatrix']=_0x74d525['a']['Identity']()):_0x51fe3e['_texture']=_0x167f20['getEngine']()['createRenderTargetTexture'](_0x51fe3e['_size'],_0x51fe3e['_renderTargetOptions']))),_0x51fe3e):_0x51fe3e;}return Object(_0x18e13d['d'])(_0x480417,_0x2c4bc9),Object['defineProperty'](_0x480417['prototype'],'renderList',{'get':function(){return this['_renderList'];},'set':function(_0x54d148){this['_renderList']=_0x54d148,this['_renderList']&&this['_hookArray'](this['_renderList']);},'enumerable':!0x1,'configurable':!0x0}),_0x480417['prototype']['_hookArray']=function(_0x18fa70){var _0x58b6fe=this,_0x515ae6=_0x18fa70['push'];_0x18fa70['push']=function(){for(var _0x401c8c=[],_0x235669=0x0;_0x2356690x0&&(this['_postProcesses'][0x0]['autoClear']=!0x1));}},_0x480417['prototype']['_shouldRender']=function(){return-0x1===this['_currentRefreshId']||this['refreshRate']===this['_currentRefreshId']?(this['_currentRefreshId']=0x1,!0x0):(this['_currentRefreshId']++,!0x1);},_0x480417['prototype']['getRenderSize']=function(){return this['getRenderWidth']();},_0x480417['prototype']['getRenderWidth']=function(){return this['_size']['width']?this['_size']['width']:this['_size'];},_0x480417['prototype']['getRenderHeight']=function(){return this['_size']['width']?this['_size']['height']:this['_size'];},_0x480417['prototype']['getRenderLayers']=function(){var _0x3f38b4=this['_size']['layers'];return _0x3f38b4||0x0;},Object['defineProperty'](_0x480417['prototype'],'canRescale',{'get':function(){return!0x0;},'enumerable':!0x1,'configurable':!0x0}),_0x480417['prototype']['scale']=function(_0x50363f){var _0x24ee8f=Math['max'](0x1,this['getRenderSize']()*_0x50363f);this['resize'](_0x24ee8f);},_0x480417['prototype']['getReflectionTextureMatrix']=function(){return this['isCube']?this['_textureMatrix']:_0x2c4bc9['prototype']['getReflectionTextureMatrix']['call'](this);},_0x480417['prototype']['resize']=function(_0x3623c1){var _0x299893=this['isCube'];this['releaseInternalTexture']();var _0x399ddd=this['getScene']();_0x399ddd&&(this['_processSizeParameter'](_0x3623c1),this['_texture']=_0x299893?_0x399ddd['getEngine']()['createRenderTargetCubeTexture'](this['getRenderSize'](),this['_renderTargetOptions']):_0x399ddd['getEngine']()['createRenderTargetTexture'](this['_size'],this['_renderTargetOptions']),this['onResizeObservable']['hasObservers']()&&this['onResizeObservable']['notifyObservers'](this));},_0x480417['prototype']['render']=function(_0x2089ee,_0x35542b){if(void 0x0===_0x2089ee&&(_0x2089ee=!0x1),void 0x0===_0x35542b&&(_0x35542b=!0x1),_0x506e83=this['getScene']()){var _0x91bec5,_0x5583cc=_0x506e83['getEngine']();if(void 0x0!==this['useCameraPostProcesses']&&(_0x2089ee=this['useCameraPostProcesses']),this['_waitingRenderList']){this['renderList']=[];for(var _0x578d29=0x0;_0x578d290x1||this['activeCamera']&&this['activeCamera']!==_0x506e83['activeCamera'])&&_0x506e83['setTransformMatrix'](_0x506e83['activeCamera']['getViewMatrix'](),_0x506e83['activeCamera']['getProjectionMatrix'](!0x0)),_0x5583cc['setViewport'](_0x506e83['activeCamera']['viewport'])),_0x506e83['resetCachedMaterial']();}},_0x480417['prototype']['_bestReflectionRenderTargetDimension']=function(_0xc71fdc,_0x5c1c95){var _0x758323=_0xc71fdc*_0x5c1c95,_0x5e1665=_0x300b38['a']['NearestPOT'](_0x758323+0x4000/(0x80+_0x758323));return Math['min'](_0x300b38['a']['FloorPOT'](_0xc71fdc),_0x5e1665);},_0x480417['prototype']['_prepareRenderingManager']=function(_0x354187,_0x944144,_0x40a25d,_0x11acc6){var _0x2d7e05=this['getScene']();if(_0x2d7e05){this['_renderingManager']['reset']();for(var _0x835331=_0x2d7e05['getRenderId'](),_0x294b95=0x0;_0x294b95<_0x944144;_0x294b95++){var _0x57d241=_0x354187[_0x294b95];if(_0x57d241&&!_0x57d241['isBlocked']){if(this['customIsReadyFunction']){if(!this['customIsReadyFunction'](_0x57d241,this['refreshRate'])){this['resetRefreshCounter']();continue;}}else{if(!_0x57d241['isReady'](0x0===this['refreshRate'])){this['resetRefreshCounter']();continue;}}if(!_0x57d241['_internalAbstractMeshDataInfo']['_currentLODIsUpToDate']&&_0x2d7e05['activeCamera']&&(_0x57d241['_internalAbstractMeshDataInfo']['_currentLOD']=_0x2d7e05['customLODSelector']?_0x2d7e05['customLODSelector'](_0x57d241,_0x2d7e05['activeCamera']):_0x57d241['getLOD'](_0x2d7e05['activeCamera']),_0x57d241['_internalAbstractMeshDataInfo']['_currentLODIsUpToDate']=!0x0),!_0x57d241['_internalAbstractMeshDataInfo']['_currentLOD'])continue;var _0xa8ffd1=_0x57d241['_internalAbstractMeshDataInfo']['_currentLOD'];_0xa8ffd1['_preActivateForIntermediateRendering'](_0x835331);var _0x5c2640=void 0x0;if(_0x5c2640=!(!_0x11acc6||!_0x40a25d)&&0x0==(_0x57d241['layerMask']&_0x40a25d['layerMask']),_0x57d241['isEnabled']()&&_0x57d241['isVisible']&&_0x57d241['subMeshes']&&!_0x5c2640&&(_0xa8ffd1!==_0x57d241&&_0xa8ffd1['_activate'](_0x835331,!0x0),_0x57d241['_activate'](_0x835331,!0x0)&&_0x57d241['subMeshes']['length'])){_0x57d241['isAnInstance']?_0x57d241['_internalAbstractMeshDataInfo']['_actAsRegularMesh']&&(_0xa8ffd1=_0x57d241):_0xa8ffd1['_internalAbstractMeshDataInfo']['_onlyForInstancesIntermediate']=!0x1,_0xa8ffd1['_internalAbstractMeshDataInfo']['_isActiveIntermediate']=!0x0;for(var _0x6e0f04=0x0;_0x6e0f04<_0xa8ffd1['subMeshes']['length'];_0x6e0f04++){var _0x4e7090=_0xa8ffd1['subMeshes'][_0x6e0f04];this['_renderingManager']['dispatch'](_0x4e7090,_0xa8ffd1);}}}}for(var _0x5014a4=0x0;_0x5014a4<_0x2d7e05['particleSystems']['length'];_0x5014a4++){var _0x1c4ee1=_0x2d7e05['particleSystems'][_0x5014a4],_0x23172b=_0x1c4ee1['emitter'];_0x1c4ee1['isStarted']()&&_0x23172b&&_0x23172b['position']&&_0x23172b['isEnabled']()&&(_0x354187['indexOf'](_0x23172b)>=0x0&&this['_renderingManager']['dispatchParticles'](_0x1c4ee1));}}},_0x480417['prototype']['_bindFrameBuffer']=function(_0x4e3eaf,_0x367807){void 0x0===_0x4e3eaf&&(_0x4e3eaf=0x0),void 0x0===_0x367807&&(_0x367807=0x0);var _0x4f316e=this['getScene']();if(_0x4f316e){var _0x255dea=_0x4f316e['getEngine']();this['_texture']&&_0x255dea['bindFramebuffer'](this['_texture'],this['isCube']?_0x4e3eaf:void 0x0,void 0x0,void 0x0,this['ignoreCameraViewport'],0x0,_0x367807);}},_0x480417['prototype']['unbindFrameBuffer']=function(_0x4e9afb,_0x5bdc5f){var _0x54d992=this;this['_texture']&&_0x4e9afb['unBindFramebuffer'](this['_texture'],this['isCube'],function(){_0x54d992['onAfterRenderObservable']['notifyObservers'](_0x5bdc5f);});},_0x480417['prototype']['renderToTarget']=function(_0x4c9472,_0x1165aa,_0x3ed7dc,_0x3930c1,_0x163659){void 0x0===_0x3930c1&&(_0x3930c1=0x0),void 0x0===_0x163659&&(_0x163659=null);var _0x3daf85=this['getScene']();if(_0x3daf85){var _0x40b0af=_0x3daf85['getEngine']();if(this['_texture']){this['_postProcessManager']?this['_postProcessManager']['_prepareFrame'](this['_texture'],this['_postProcesses']):_0x1165aa&&_0x3daf85['postProcessManager']['_prepareFrame'](this['_texture'])||this['_bindFrameBuffer'](_0x4c9472,_0x3930c1),this['is2DArray']?this['onBeforeRenderObservable']['notifyObservers'](_0x3930c1):this['onBeforeRenderObservable']['notifyObservers'](_0x4c9472);var _0x44126e=null,_0x2a5b4f=this['renderList']?this['renderList']:_0x3daf85['getActiveMeshes']()['data'],_0x2b7185=this['renderList']?this['renderList']['length']:_0x3daf85['getActiveMeshes']()['length'];this['getCustomRenderList']&&(_0x44126e=this['getCustomRenderList'](this['is2DArray']?_0x3930c1:_0x4c9472,_0x2a5b4f,_0x2b7185)),_0x44126e?this['_prepareRenderingManager'](_0x44126e,_0x44126e['length'],_0x163659,!0x1):(this['_defaultRenderListPrepared']||(this['_prepareRenderingManager'](_0x2a5b4f,_0x2b7185,_0x163659,!this['renderList']),this['_defaultRenderListPrepared']=!0x0),_0x44126e=_0x2a5b4f),this['onClearObservable']['hasObservers']()?this['onClearObservable']['notifyObservers'](_0x40b0af):_0x40b0af['clear'](this['clearColor']||_0x3daf85['clearColor'],!0x0,!0x0,!0x0),this['_doNotChangeAspectRatio']||_0x3daf85['updateTransformMatrix'](!0x0);for(var _0x1650bc=0x0,_0x5ab799=_0x3daf85['_beforeRenderTargetDrawStage'];_0x1650bc<_0x5ab799['length'];_0x1650bc++){_0x5ab799[_0x1650bc]['action'](this);}this['_renderingManager']['render'](this['customRenderFunction'],_0x44126e,this['renderParticles'],this['renderSprites']);for(var _0x190282=0x0,_0x24b0a7=_0x3daf85['_afterRenderTargetDrawStage'];_0x190282<_0x24b0a7['length'];_0x190282++){_0x24b0a7[_0x190282]['action'](this);}this['_postProcessManager']?this['_postProcessManager']['_finalizeFrame'](!0x1,this['_texture'],_0x4c9472,this['_postProcesses'],this['ignoreCameraViewport']):_0x1165aa&&_0x3daf85['postProcessManager']['_finalizeFrame'](!0x1,this['_texture'],_0x4c9472),this['_doNotChangeAspectRatio']||_0x3daf85['updateTransformMatrix'](!0x0),_0x3ed7dc&&_0x5d754c['b']['DumpFramebuffer'](this['getRenderWidth'](),this['getRenderHeight'](),_0x40b0af),this['isCube']&&0x5!==_0x4c9472?this['onAfterRenderObservable']['notifyObservers'](_0x4c9472):(this['isCube']&&0x5===_0x4c9472&&_0x40b0af['generateMipMapsForCubemap'](this['_texture']),this['unbindFrameBuffer'](_0x40b0af,_0x4c9472));}}},_0x480417['prototype']['setRenderingOrder']=function(_0x202507,_0x4c2a5a,_0x45c451,_0x7d9665){void 0x0===_0x4c2a5a&&(_0x4c2a5a=null),void 0x0===_0x45c451&&(_0x45c451=null),void 0x0===_0x7d9665&&(_0x7d9665=null),this['_renderingManager']['setRenderingOrder'](_0x202507,_0x4c2a5a,_0x45c451,_0x7d9665);},_0x480417['prototype']['setRenderingAutoClearDepthStencil']=function(_0x4a2df5,_0xb1f98c){this['_renderingManager']['setRenderingAutoClearDepthStencil'](_0x4a2df5,_0xb1f98c),this['_renderingManager']['_useSceneAutoClearSetup']=!0x1;},_0x480417['prototype']['clone']=function(){var _0x150785=this['getSize'](),_0x2e7182=new _0x480417(this['name'],_0x150785,this['getScene'](),this['_renderTargetOptions']['generateMipMaps'],this['_doNotChangeAspectRatio'],this['_renderTargetOptions']['type'],this['isCube'],this['_renderTargetOptions']['samplingMode'],this['_renderTargetOptions']['generateDepthBuffer'],this['_renderTargetOptions']['generateStencilBuffer']);return _0x2e7182['hasAlpha']=this['hasAlpha'],_0x2e7182['level']=this['level'],_0x2e7182['coordinatesMode']=this['coordinatesMode'],this['renderList']&&(_0x2e7182['renderList']=this['renderList']['slice'](0x0)),_0x2e7182;},_0x480417['prototype']['serialize']=function(){if(!this['name'])return null;var _0x51bf1e=_0x2c4bc9['prototype']['serialize']['call'](this);if(_0x51bf1e['renderTargetSize']=this['getRenderSize'](),_0x51bf1e['renderList']=[],this['renderList']){for(var _0x1d0f28=0x0;_0x1d0f28=0x0&&_0x347a35['customRenderTargets']['splice'](_0x1b7760,0x1);for(var _0x5948a1=0x0,_0x3a3e84=_0x347a35['cameras'];_0x5948a1<_0x3a3e84['length'];_0x5948a1++){var _0x5a23da=_0x3a3e84[_0x5948a1];(_0x1b7760=_0x5a23da['customRenderTargets']['indexOf'](this))>=0x0&&_0x5a23da['customRenderTargets']['splice'](_0x1b7760,0x1);}this['depthStencilTexture']&&this['getScene']()['getEngine']()['_releaseTexture'](this['depthStencilTexture']),_0x2c4bc9['prototype']['dispose']['call'](this);}},_0x480417['prototype']['_rebuild']=function(){this['refreshRate']===_0x480417['REFRESHRATE_RENDER_ONCE']&&(this['refreshRate']=_0x480417['REFRESHRATE_RENDER_ONCE']),this['_postProcessManager']&&this['_postProcessManager']['_rebuild']();},_0x480417['prototype']['freeRenderingGroups']=function(){this['_renderingManager']&&this['_renderingManager']['freeRenderingGroups']();},_0x480417['prototype']['getViewCount']=function(){return 0x1;},_0x480417['REFRESHRATE_RENDER_ONCE']=0x0,_0x480417['REFRESHRATE_RENDER_ONEVERYFRAME']=0x1,_0x480417['REFRESHRATE_RENDER_ONEVERYTWOFRAMES']=0x2,_0x480417;}(_0xaf3c80['a']);_0xaf3c80['a']['_CreateRenderTargetTexture']=function(_0x3d1a5d,_0x58f84f,_0x117f07,_0x3d8d99){return new _0x310f87(_0x3d1a5d,_0x58f84f,_0x117f07,_0x3d8d99);};var _0x2e6b8e=function(_0x6353ff){function _0xe485f1(_0x2afa60,_0x5413fe){void 0x0===_0x5413fe&&(_0x5413fe=0x200);var _0x287654=_0x6353ff['call'](this,'multiview\x20rtt',_0x5413fe,_0x2afa60,!0x1,!0x0,_0x21ea74['b']['Unknown'],!0x1,void 0x0,!0x1,!0x1,!0x0,void 0x0,!0x0)||this,_0x430b16=_0x2afa60['getEngine']()['createMultiviewRenderTargetTexture'](_0x287654['getRenderWidth'](),_0x287654['getRenderHeight']());return _0x430b16['isMultiview']=!0x0,_0x430b16['format']=_0x2103ba['a']['TEXTUREFORMAT_RGBA'],_0x287654['_texture']=_0x430b16,_0x287654['samples']=_0x287654['_getEngine']()['getCaps']()['maxSamples']||_0x287654['samples'],_0x287654;}return Object(_0x18e13d['d'])(_0xe485f1,_0x6353ff),_0xe485f1['prototype']['_bindFrameBuffer']=function(_0x4bb5f1){void 0x0===_0x4bb5f1&&(_0x4bb5f1=0x0),this['_texture']&&this['getScene']()['getEngine']()['bindMultiviewFramebuffer'](this['_texture']);},_0xe485f1['prototype']['getViewCount']=function(){return 0x2;},_0xe485f1;}(_0x310f87),_0xd246c2=_0x162675(0x5a);_0x300b38['a']['prototype']['createMultiviewRenderTargetTexture']=function(_0x283966,_0x1c7409){var _0x472cac=this['_gl'];if(!this['getCaps']()['multiview'])throw'Multiview\x20is\x20not\x20supported';var _0xc9abc6=new _0x21ea74['a'](this,_0x21ea74['b']['Unknown'],!0x0);return _0xc9abc6['width']=_0x283966,_0xc9abc6['height']=_0x1c7409,_0xc9abc6['_framebuffer']=_0x472cac['createFramebuffer'](),_0xc9abc6['_colorTextureArray']=_0x472cac['createTexture'](),_0x472cac['bindTexture'](_0x472cac['TEXTURE_2D_ARRAY'],_0xc9abc6['_colorTextureArray']),_0x472cac['texStorage3D'](_0x472cac['TEXTURE_2D_ARRAY'],0x1,_0x472cac['RGBA8'],_0x283966,_0x1c7409,0x2),_0xc9abc6['_depthStencilTextureArray']=_0x472cac['createTexture'](),_0x472cac['bindTexture'](_0x472cac['TEXTURE_2D_ARRAY'],_0xc9abc6['_depthStencilTextureArray']),_0x472cac['texStorage3D'](_0x472cac['TEXTURE_2D_ARRAY'],0x1,_0x472cac['DEPTH32F_STENCIL8'],_0x283966,_0x1c7409,0x2),_0xc9abc6['isReady']=!0x0,_0xc9abc6;},_0x300b38['a']['prototype']['bindMultiviewFramebuffer']=function(_0x4179de){var _0xe425c7=this['_gl'],_0x557e7b=this['getCaps']()['oculusMultiview']||this['getCaps']()['multiview'];if(this['bindFramebuffer'](_0x4179de,void 0x0,void 0x0,void 0x0,!0x0),_0xe425c7['bindFramebuffer'](_0xe425c7['DRAW_FRAMEBUFFER'],_0x4179de['_framebuffer']),!_0x4179de['_colorTextureArray']||!_0x4179de['_depthStencilTextureArray'])throw'Invalid\x20multiview\x20frame\x20buffer';this['getCaps']()['oculusMultiview']?(_0x557e7b['framebufferTextureMultisampleMultiviewOVR'](_0xe425c7['DRAW_FRAMEBUFFER'],_0xe425c7['COLOR_ATTACHMENT0'],_0x4179de['_colorTextureArray'],0x0,_0x4179de['samples'],0x0,0x2),_0x557e7b['framebufferTextureMultisampleMultiviewOVR'](_0xe425c7['DRAW_FRAMEBUFFER'],_0xe425c7['DEPTH_STENCIL_ATTACHMENT'],_0x4179de['_depthStencilTextureArray'],0x0,_0x4179de['samples'],0x0,0x2)):(_0x557e7b['framebufferTextureMultiviewOVR'](_0xe425c7['DRAW_FRAMEBUFFER'],_0xe425c7['COLOR_ATTACHMENT0'],_0x4179de['_colorTextureArray'],0x0,0x0,0x2),_0x557e7b['framebufferTextureMultiviewOVR'](_0xe425c7['DRAW_FRAMEBUFFER'],_0xe425c7['DEPTH_STENCIL_ATTACHMENT'],_0x4179de['_depthStencilTextureArray'],0x0,0x0,0x2));},_0x568729['a']['prototype']['_useMultiviewToSingleView']=!0x1,_0x568729['a']['prototype']['_multiviewTexture']=null,_0x568729['a']['prototype']['_resizeOrCreateMultiviewTexture']=function(_0x58380b,_0x32695c){this['_multiviewTexture']?this['_multiviewTexture']['getRenderWidth']()==_0x58380b&&this['_multiviewTexture']['getRenderHeight']()==_0x32695c||(this['_multiviewTexture']['dispose'](),this['_multiviewTexture']=new _0x2e6b8e(this['getScene'](),{'width':_0x58380b,'height':_0x32695c})):this['_multiviewTexture']=new _0x2e6b8e(this['getScene'](),{'width':_0x58380b,'height':_0x32695c});},_0x59370b['a']['prototype']['_transformMatrixR']=_0x74d525['a']['Zero'](),_0x59370b['a']['prototype']['_multiviewSceneUbo']=null,_0x59370b['a']['prototype']['_createMultiviewUbo']=function(){this['_multiviewSceneUbo']=new _0x640faf['a'](this['getEngine'](),void 0x0,!0x0),this['_multiviewSceneUbo']['addUniform']('viewProjection',0x10),this['_multiviewSceneUbo']['addUniform']('viewProjectionR',0x10),this['_multiviewSceneUbo']['addUniform']('view',0x10);},_0x59370b['a']['prototype']['_updateMultiviewUbo']=function(_0x578293,_0x4d701e){_0x578293&&_0x4d701e&&_0x578293['multiplyToRef'](_0x4d701e,this['_transformMatrixR']),_0x578293&&_0x4d701e&&(_0x578293['multiplyToRef'](_0x4d701e,_0x74d525['c']['Matrix'][0x0]),_0xd246c2['a']['GetRightPlaneToRef'](_0x74d525['c']['Matrix'][0x0],this['_frustumPlanes'][0x3])),this['_multiviewSceneUbo']&&(this['_multiviewSceneUbo']['updateMatrix']('viewProjection',this['getTransformMatrix']()),this['_multiviewSceneUbo']['updateMatrix']('viewProjectionR',this['_transformMatrixR']),this['_multiviewSceneUbo']['updateMatrix']('view',this['_viewMatrix']),this['_multiviewSceneUbo']['update']());},_0x59370b['a']['prototype']['_renderMultiviewToSingleView']=function(_0x32605e){_0x32605e['_resizeOrCreateMultiviewTexture'](_0x32605e['_rigPostProcess']&&_0x32605e['_rigPostProcess']&&_0x32605e['_rigPostProcess']['width']>0x0?_0x32605e['_rigPostProcess']['width']:this['getEngine']()['getRenderWidth'](!0x0),_0x32605e['_rigPostProcess']&&_0x32605e['_rigPostProcess']&&_0x32605e['_rigPostProcess']['height']>0x0?_0x32605e['_rigPostProcess']['height']:this['getEngine']()['getRenderHeight'](!0x0)),this['_multiviewSceneUbo']||this['_createMultiviewUbo'](),_0x32605e['outputRenderTarget']=_0x32605e['_multiviewTexture'],this['_renderForCamera'](_0x32605e),_0x32605e['outputRenderTarget']=null;for(var _0x1013df=0x0;_0x1013df<_0x32605e['_rigCameras']['length'];_0x1013df++){var _0x8e9986=this['getEngine']();this['_activeCamera']=_0x32605e['_rigCameras'][_0x1013df],_0x8e9986['setViewport'](this['_activeCamera']['viewport']),this['postProcessManager']&&(this['postProcessManager']['_prepareFrame'](),this['postProcessManager']['_finalizeFrame'](this['_activeCamera']['isIntermediate']));}};var _0x2c34b9=function(_0x5a7ffc){function _0x5569e8(_0xb38924,_0x44b8ac,_0x4de34f){var _0x1ec578=_0x5a7ffc['call'](this,_0xb38924,'vrMultiviewToSingleview',['imageIndex'],['multiviewSampler'],_0x4de34f,_0x44b8ac,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'])||this;return _0x1ec578['onSizeChangedObservable']['add'](function(){}),_0x1ec578['onApplyObservable']['add'](function(_0x452149){_0x44b8ac['_scene']['activeCamera']&&_0x44b8ac['_scene']['activeCamera']['isLeftCamera']?_0x452149['setInt']('imageIndex',0x0):_0x452149['setInt']('imageIndex',0x1),_0x452149['setTexture']('multiviewSampler',_0x44b8ac['_multiviewTexture']);}),_0x1ec578;}return Object(_0x18e13d['d'])(_0x5569e8,_0x5a7ffc),_0x5569e8['prototype']['getClassName']=function(){return'VRMultiviewToSingleviewPostProcess';},_0x5569e8;}(_0x5cae84);_0x568729['a']['_setVRRigMode']=function(_0x271380,_0xe42a72){var _0x194deb=_0xe42a72['vrCameraMetrics']||_0x521280['GetDefault']();_0x271380['_rigCameras'][0x0]['_cameraRigParams']['vrMetrics']=_0x194deb,_0x271380['_rigCameras'][0x0]['viewport']=new _0x4548b0['a'](0x0,0x0,0.5,0x1),_0x271380['_rigCameras'][0x0]['_cameraRigParams']['vrWorkMatrix']=new _0x74d525['a'](),_0x271380['_rigCameras'][0x0]['_cameraRigParams']['vrHMatrix']=_0x194deb['leftHMatrix'],_0x271380['_rigCameras'][0x0]['_cameraRigParams']['vrPreViewMatrix']=_0x194deb['leftPreViewMatrix'],_0x271380['_rigCameras'][0x0]['getProjectionMatrix']=_0x271380['_rigCameras'][0x0]['_getVRProjectionMatrix'],_0x271380['_rigCameras'][0x1]['_cameraRigParams']['vrMetrics']=_0x194deb,_0x271380['_rigCameras'][0x1]['viewport']=new _0x4548b0['a'](0.5,0x0,0.5,0x1),_0x271380['_rigCameras'][0x1]['_cameraRigParams']['vrWorkMatrix']=new _0x74d525['a'](),_0x271380['_rigCameras'][0x1]['_cameraRigParams']['vrHMatrix']=_0x194deb['rightHMatrix'],_0x271380['_rigCameras'][0x1]['_cameraRigParams']['vrPreViewMatrix']=_0x194deb['rightPreViewMatrix'],_0x271380['_rigCameras'][0x1]['getProjectionMatrix']=_0x271380['_rigCameras'][0x1]['_getVRProjectionMatrix'],_0x194deb['multiviewEnabled']&&(_0x271380['getScene']()['getEngine']()['getCaps']()['multiview']?(_0x271380['_useMultiviewToSingleView']=!0x0,_0x271380['_rigPostProcess']=new _0x2c34b9('VRMultiviewToSingleview',_0x271380,_0x194deb['postProcessScaleFactor'])):(_0x75193d['a']['Warn']('Multiview\x20is\x20not\x20supported,\x20falling\x20back\x20to\x20standard\x20rendering'),_0x194deb['multiviewEnabled']=!0x1)),_0x194deb['compensateDistortion']&&(_0x271380['_rigCameras'][0x0]['_rigPostProcess']=new _0x491a9b('VR_Distort_Compensation_Left',_0x271380['_rigCameras'][0x0],!0x1,_0x194deb),_0x271380['_rigCameras'][0x1]['_rigPostProcess']=new _0x491a9b('VR_Distort_Compensation_Right',_0x271380['_rigCameras'][0x1],!0x0,_0x194deb));},_0x43169a['a']['AddNodeConstructor']('VRDeviceOrientationFreeCamera',function(_0x563d8d,_0x9fef81){return function(){return new _0x3dfa73(_0x563d8d,0x0,0x0,0x1,_0x74d525['e']['Zero'](),_0x9fef81);};});var _0x3dfa73=function(_0x308de2){function _0x292e06(_0x1bf771,_0x5fba11,_0x5d4af1,_0x216c3d,_0x43f6ac,_0x4e15bd,_0x566d55,_0xfdf692){void 0x0===_0x566d55&&(_0x566d55=!0x0),void 0x0===_0xfdf692&&(_0xfdf692=_0x521280['GetDefault']());var _0x4fbb3a=_0x308de2['call'](this,_0x1bf771,_0x5fba11,_0x5d4af1,_0x216c3d,_0x43f6ac,_0x4e15bd)||this;return _0xfdf692['compensateDistortion']=_0x566d55,_0x4fbb3a['setCameraRigMode'](_0x568729['a']['RIG_MODE_VR'],{'vrCameraMetrics':_0xfdf692}),_0x4fbb3a['inputs']['addVRDeviceOrientation'](),_0x4fbb3a;}return Object(_0x18e13d['d'])(_0x292e06,_0x308de2),_0x292e06['prototype']['getClassName']=function(){return'VRDeviceOrientationArcRotateCamera';},_0x292e06;}(_0xe57e08);_0x43169a['a']['AddNodeConstructor']('VRDeviceOrientationFreeCamera',function(_0x8f5173,_0x386bcc){return function(){return new _0x4fea40(_0x8f5173,_0x74d525['e']['Zero'](),_0x386bcc);};});var _0x4fea40=function(_0x4a2ef7){function _0x15fb80(_0x197885,_0x5d64a1,_0x4a0edd,_0x24a9bb,_0x55e027){void 0x0===_0x24a9bb&&(_0x24a9bb=!0x0),void 0x0===_0x55e027&&(_0x55e027=_0x521280['GetDefault']());var _0x2fb6fa=_0x4a2ef7['call'](this,_0x197885,_0x5d64a1,_0x4a0edd)||this;return _0x55e027['compensateDistortion']=_0x24a9bb,_0x2fb6fa['setCameraRigMode'](_0x568729['a']['RIG_MODE_VR'],{'vrCameraMetrics':_0x55e027}),_0x2fb6fa;}return Object(_0x18e13d['d'])(_0x15fb80,_0x4a2ef7),_0x15fb80['prototype']['getClassName']=function(){return'VRDeviceOrientationFreeCamera';},_0x15fb80;}(_0x2de943);_0x43169a['a']['AddNodeConstructor']('VRDeviceOrientationGamepadCamera',function(_0x18ec9c,_0xcbf056){return function(){return new _0x7f0a4e(_0x18ec9c,_0x74d525['e']['Zero'](),_0xcbf056);};});var _0x7f0a4e=function(_0x12ab0d){function _0x3431ed(_0x1b1aa5,_0xe7b9e,_0x41de5d,_0x4d6c5b,_0x4f9f09){void 0x0===_0x4d6c5b&&(_0x4d6c5b=!0x0),void 0x0===_0x4f9f09&&(_0x4f9f09=_0x521280['GetDefault']());var _0x1d51bc=_0x12ab0d['call'](this,_0x1b1aa5,_0xe7b9e,_0x41de5d,_0x4d6c5b,_0x4f9f09)||this;return _0x1d51bc['inputs']['addGamepad'](),_0x1d51bc;}return Object(_0x18e13d['d'])(_0x3431ed,_0x12ab0d),_0x3431ed['prototype']['getClassName']=function(){return'VRDeviceOrientationGamepadCamera';},_0x3431ed;}(_0x4fea40),_0xb2c680=_0x162675(0x56);_0x568729['a']['_setWebVRRigMode']=function(_0x103702,_0x953c77){if(_0x953c77['vrDisplay']){var _0x52595a=_0x953c77['vrDisplay']['getEyeParameters']('left'),_0x45579d=_0x953c77['vrDisplay']['getEyeParameters']('right');_0x103702['_rigCameras'][0x0]['viewport']=new _0x4548b0['a'](0x0,0x0,0.5,0x1),_0x103702['_rigCameras'][0x0]['setCameraRigParameter']('left',!0x0),_0x103702['_rigCameras'][0x0]['setCameraRigParameter']('specs',_0x953c77['specs']),_0x103702['_rigCameras'][0x0]['setCameraRigParameter']('eyeParameters',_0x52595a),_0x103702['_rigCameras'][0x0]['setCameraRigParameter']('frameData',_0x953c77['frameData']),_0x103702['_rigCameras'][0x0]['setCameraRigParameter']('parentCamera',_0x953c77['parentCamera']),_0x103702['_rigCameras'][0x0]['_cameraRigParams']['vrWorkMatrix']=new _0x74d525['a'](),_0x103702['_rigCameras'][0x0]['getProjectionMatrix']=_0x103702['_getWebVRProjectionMatrix'],_0x103702['_rigCameras'][0x0]['parent']=_0x103702,_0x103702['_rigCameras'][0x0]['_getViewMatrix']=_0x103702['_getWebVRViewMatrix'],_0x103702['_rigCameras'][0x1]['viewport']=new _0x4548b0['a'](0.5,0x0,0.5,0x1),_0x103702['_rigCameras'][0x1]['setCameraRigParameter']('eyeParameters',_0x45579d),_0x103702['_rigCameras'][0x1]['setCameraRigParameter']('specs',_0x953c77['specs']),_0x103702['_rigCameras'][0x1]['setCameraRigParameter']('frameData',_0x953c77['frameData']),_0x103702['_rigCameras'][0x1]['setCameraRigParameter']('parentCamera',_0x953c77['parentCamera']),_0x103702['_rigCameras'][0x1]['_cameraRigParams']['vrWorkMatrix']=new _0x74d525['a'](),_0x103702['_rigCameras'][0x1]['getProjectionMatrix']=_0x103702['_getWebVRProjectionMatrix'],_0x103702['_rigCameras'][0x1]['parent']=_0x103702,_0x103702['_rigCameras'][0x1]['_getViewMatrix']=_0x103702['_getWebVRViewMatrix'];}},Object['defineProperty'](_0x300b38['a']['prototype'],'isInVRExclusivePointerMode',{'get':function(){return this['_vrExclusivePointerMode'];},'enumerable':!0x0,'configurable':!0x0}),_0x300b38['a']['prototype']['_prepareVRComponent']=function(){this['_vrSupported']=!0x1,this['_vrExclusivePointerMode']=!0x1,this['onVRDisplayChangedObservable']=new _0x6ac1f7['c'](),this['onVRRequestPresentComplete']=new _0x6ac1f7['c'](),this['onVRRequestPresentStart']=new _0x6ac1f7['c']();},_0x300b38['a']['prototype']['isVRDevicePresent']=function(){return!!this['_vrDisplay'];},_0x300b38['a']['prototype']['getVRDevice']=function(){return this['_vrDisplay'];},_0x300b38['a']['prototype']['initWebVR']=function(){return this['initWebVRAsync'](),this['onVRDisplayChangedObservable'];},_0x300b38['a']['prototype']['initWebVRAsync']=function(){var _0x3728bf=this,_0x29ba12=function(){var _0x4f49a9={'vrDisplay':_0x3728bf['_vrDisplay'],'vrSupported':_0x3728bf['_vrSupported']};_0x3728bf['onVRDisplayChangedObservable']['notifyObservers'](_0x4f49a9),_0x3728bf['_webVRInitPromise']=new Promise(function(_0x3b7616){_0x3b7616(_0x4f49a9);});};if(!this['_onVrDisplayConnect']){this['_onVrDisplayConnect']=function(_0x2d6956){_0x3728bf['_vrDisplay']=_0x2d6956['display'],_0x29ba12();},this['_onVrDisplayDisconnect']=function(){_0x3728bf['_vrDisplay']['cancelAnimationFrame'](_0x3728bf['_frameHandler']),_0x3728bf['_vrDisplay']=void 0x0,_0x3728bf['_frameHandler']=_0x300b38['a']['QueueNewFrame'](_0x3728bf['_boundRenderFunction']),_0x29ba12();},this['_onVrDisplayPresentChange']=function(){_0x3728bf['_vrExclusivePointerMode']=_0x3728bf['_vrDisplay']&&_0x3728bf['_vrDisplay']['isPresenting'];};var _0x1c04a2=this['getHostWindow']();_0x1c04a2&&(_0x1c04a2['addEventListener']('vrdisplayconnect',this['_onVrDisplayConnect']),_0x1c04a2['addEventListener']('vrdisplaydisconnect',this['_onVrDisplayDisconnect']),_0x1c04a2['addEventListener']('vrdisplaypresentchange',this['_onVrDisplayPresentChange']));}return this['_webVRInitPromise']=this['_webVRInitPromise']||this['_getVRDisplaysAsync'](),this['_webVRInitPromise']['then'](_0x29ba12),this['_webVRInitPromise'];},_0x300b38['a']['prototype']['_getVRDisplaysAsync']=function(){var _0x1665b0=this;return new Promise(function(_0x130954){navigator['getVRDisplays']?navigator['getVRDisplays']()['then'](function(_0x378103){_0x1665b0['_vrSupported']=!0x0,_0x1665b0['_vrDisplay']=_0x378103[0x0],_0x130954({'vrDisplay':_0x1665b0['_vrDisplay'],'vrSupported':_0x1665b0['_vrSupported']});}):(_0x1665b0['_vrDisplay']=void 0x0,_0x1665b0['_vrSupported']=!0x1,_0x130954({'vrDisplay':_0x1665b0['_vrDisplay'],'vrSupported':_0x1665b0['_vrSupported']}));});},_0x300b38['a']['prototype']['enableVR']=function(_0x555ed0){var _0x5b617e=this;if(this['_vrDisplay']&&!this['_vrDisplay']['isPresenting']){this['onVRRequestPresentStart']['notifyObservers'](this);var _0x5ba080={'highRefreshRate':!!this['vrPresentationAttributes']&&this['vrPresentationAttributes']['highRefreshRate'],'foveationLevel':this['vrPresentationAttributes']?this['vrPresentationAttributes']['foveationLevel']:0x1,'multiview':(this['getCaps']()['multiview']||this['getCaps']()['oculusMultiview'])&&_0x555ed0['useMultiview']};this['_vrDisplay']['requestPresent']([Object(_0x18e13d['a'])({'source':this['getRenderingCanvas'](),'attributes':_0x5ba080},_0x5ba080)])['then'](function(){_0x5b617e['onVRRequestPresentComplete']['notifyObservers'](!0x0),_0x5b617e['_onVRFullScreenTriggered']();})['catch'](function(){_0x5b617e['onVRRequestPresentComplete']['notifyObservers'](!0x1);});}},_0x300b38['a']['prototype']['_onVRFullScreenTriggered']=function(){if(this['_vrDisplay']&&this['_vrDisplay']['isPresenting']){this['_oldSize']=new _0x417f41['a'](this['getRenderWidth'](),this['getRenderHeight']()),this['_oldHardwareScaleFactor']=this['getHardwareScalingLevel']();var _0x1ca2b6=this['_vrDisplay']['getEyeParameters']('left');this['setHardwareScalingLevel'](0x1),this['setSize'](0x2*_0x1ca2b6['renderWidth'],_0x1ca2b6['renderHeight']);}else this['setHardwareScalingLevel'](this['_oldHardwareScaleFactor']),this['setSize'](this['_oldSize']['width'],this['_oldSize']['height']);},_0x300b38['a']['prototype']['disableVR']=function(){var _0x94354b=this;this['_vrDisplay']&&this['_vrDisplay']['isPresenting']&&this['_vrDisplay']['exitPresent']()['then'](function(){return _0x94354b['_onVRFullScreenTriggered']();})['catch'](function(){return _0x94354b['_onVRFullScreenTriggered']();}),_0x3cbe81['a']['IsWindowObjectExist']()&&(window['removeEventListener']('vrdisplaypointerrestricted',this['_onVRDisplayPointerRestricted']),window['removeEventListener']('vrdisplaypointerunrestricted',this['_onVRDisplayPointerUnrestricted']),this['_onVrDisplayConnect']&&(window['removeEventListener']('vrdisplayconnect',this['_onVrDisplayConnect']),this['_onVrDisplayDisconnect']&&window['removeEventListener']('vrdisplaydisconnect',this['_onVrDisplayDisconnect']),this['_onVrDisplayPresentChange']&&window['removeEventListener']('vrdisplaypresentchange',this['_onVrDisplayPresentChange']),this['_onVrDisplayConnect']=null,this['_onVrDisplayDisconnect']=null));},_0x300b38['a']['prototype']['_connectVREvents']=function(_0x383a3d,_0xc8ec0f){var _0x1a0957=this;if(this['_onVRDisplayPointerRestricted']=function(){_0x383a3d&&_0x383a3d['requestPointerLock']();},this['_onVRDisplayPointerUnrestricted']=function(){if(_0xc8ec0f)_0xc8ec0f['exitPointerLock']&&_0xc8ec0f['exitPointerLock']();else{var _0x5b75df=_0x1a0957['getHostWindow']();_0x5b75df['document']&&_0x5b75df['document']['exitPointerLock']&&_0x5b75df['document']['exitPointerLock']();}},_0x3cbe81['a']['IsWindowObjectExist']()){var _0x3b79c8=this['getHostWindow']();_0x3b79c8['addEventListener']('vrdisplaypointerrestricted',this['_onVRDisplayPointerRestricted'],!0x1),_0x3b79c8['addEventListener']('vrdisplaypointerunrestricted',this['_onVRDisplayPointerUnrestricted'],!0x1);}},_0x300b38['a']['prototype']['_submitVRFrame']=function(){if(this['_vrDisplay']&&this['_vrDisplay']['isPresenting'])try{this['_vrDisplay']['submitFrame']();}catch(_0x3886e5){_0x5d754c['b']['Warn']('webVR\x20submitFrame\x20has\x20had\x20an\x20unexpected\x20failure:\x20'+_0x3886e5);}},_0x300b38['a']['prototype']['isVRPresenting']=function(){return this['_vrDisplay']&&this['_vrDisplay']['isPresenting'];},_0x300b38['a']['prototype']['_requestVRFrame']=function(){this['_frameHandler']=_0x300b38['a']['QueueNewFrame'](this['_boundRenderFunction'],this['_vrDisplay']);},_0x43169a['a']['AddNodeConstructor']('WebVRFreeCamera',function(_0x2c785f,_0x590650){return function(){return new _0x3c14c8(_0x2c785f,_0x74d525['e']['Zero'](),_0x590650);};}),_0x43169a['a']['AddNodeConstructor']('WebVRGamepadCamera',function(_0x1c2ff0,_0x3aed5a){return function(){return new _0x3c14c8(_0x1c2ff0,_0x74d525['e']['Zero'](),_0x3aed5a);};});var _0x3c14c8=function(_0x577ff5){function _0x2cbce5(_0x5e82ad,_0x2c01b2,_0x3d15a2,_0x4ebaed){void 0x0===_0x4ebaed&&(_0x4ebaed={});var _0x2ecbac=_0x577ff5['call'](this,_0x5e82ad,_0x2c01b2,_0x3d15a2)||this;_0x2ecbac['webVROptions']=_0x4ebaed,_0x2ecbac['_vrDevice']=null,_0x2ecbac['rawPose']=null,_0x2ecbac['_specsVersion']='1.1',_0x2ecbac['_attached']=!0x1,_0x2ecbac['_descendants']=[],_0x2ecbac['_deviceRoomPosition']=_0x74d525['e']['Zero'](),_0x2ecbac['_deviceRoomRotationQuaternion']=_0x74d525['b']['Identity'](),_0x2ecbac['_standingMatrix']=null,_0x2ecbac['devicePosition']=_0x74d525['e']['Zero'](),_0x2ecbac['deviceRotationQuaternion']=_0x74d525['b']['Identity'](),_0x2ecbac['deviceScaleFactor']=0x1,_0x2ecbac['_deviceToWorld']=_0x74d525['a']['Identity'](),_0x2ecbac['_worldToDevice']=_0x74d525['a']['Identity'](),_0x2ecbac['controllers']=[],_0x2ecbac['onControllersAttachedObservable']=new _0x6ac1f7['c'](),_0x2ecbac['onControllerMeshLoadedObservable']=new _0x6ac1f7['c'](),_0x2ecbac['onPoseUpdatedFromDeviceObservable']=new _0x6ac1f7['c'](),_0x2ecbac['_poseSet']=!0x1,_0x2ecbac['rigParenting']=!0x0,_0x2ecbac['_defaultHeight']=void 0x0,_0x2ecbac['_detachIfAttached']=function(){var _0x177831=_0x2ecbac['getEngine']()['getVRDevice']();_0x177831&&!_0x177831['isPresenting']&&_0x2ecbac['detachControl']();},_0x2ecbac['_workingVector']=_0x74d525['e']['Zero'](),_0x2ecbac['_oneVector']=_0x74d525['e']['One'](),_0x2ecbac['_workingMatrix']=_0x74d525['a']['Identity'](),_0x2ecbac['_tmpMatrix']=new _0x74d525['a'](),_0x2ecbac['_cache']['position']=_0x74d525['e']['Zero'](),_0x4ebaed['defaultHeight']&&(_0x2ecbac['_defaultHeight']=_0x4ebaed['defaultHeight'],_0x2ecbac['position']['y']=_0x2ecbac['_defaultHeight']),_0x2ecbac['minZ']=0.1,0x5===arguments['length']&&(_0x2ecbac['webVROptions']=arguments[0x4]),null==_0x2ecbac['webVROptions']['trackPosition']&&(_0x2ecbac['webVROptions']['trackPosition']=!0x0),null==_0x2ecbac['webVROptions']['controllerMeshes']&&(_0x2ecbac['webVROptions']['controllerMeshes']=!0x0),null==_0x2ecbac['webVROptions']['defaultLightingOnControllers']&&(_0x2ecbac['webVROptions']['defaultLightingOnControllers']=!0x0),_0x2ecbac['rotationQuaternion']=new _0x74d525['b'](),_0x2ecbac['webVROptions']&&_0x2ecbac['webVROptions']['positionScale']&&(_0x2ecbac['deviceScaleFactor']=_0x2ecbac['webVROptions']['positionScale']);var _0x4f2b73=_0x2ecbac['getEngine']();return _0x2ecbac['_onVREnabled']=function(_0x4fbe8d){_0x4fbe8d&&_0x2ecbac['initControllers']();},_0x4f2b73['onVRRequestPresentComplete']['add'](_0x2ecbac['_onVREnabled']),_0x4f2b73['initWebVR']()['add'](function(_0x43326a){_0x43326a['vrDisplay']&&_0x2ecbac['_vrDevice']!==_0x43326a['vrDisplay']&&(_0x2ecbac['_vrDevice']=_0x43326a['vrDisplay'],_0x2ecbac['setCameraRigMode'](_0x568729['a']['RIG_MODE_WEBVR'],{'parentCamera':_0x2ecbac,'vrDisplay':_0x2ecbac['_vrDevice'],'frameData':_0x2ecbac['_frameData'],'specs':_0x2ecbac['_specsVersion']}),_0x2ecbac['_attached']&&_0x2ecbac['getEngine']()['enableVR'](_0x2ecbac['webVROptions']));}),'undefined'!=typeof VRFrameData&&(_0x2ecbac['_frameData']=new VRFrameData()),_0x4ebaed['useMultiview']&&(_0x2ecbac['getScene']()['getEngine']()['getCaps']()['multiview']?(_0x2ecbac['_useMultiviewToSingleView']=!0x0,_0x2ecbac['_rigPostProcess']=new _0x2c34b9('VRMultiviewToSingleview',_0x2ecbac,0x1)):(_0x75193d['a']['Warn']('Multiview\x20is\x20not\x20supported,\x20falling\x20back\x20to\x20standard\x20rendering'),_0x2ecbac['_useMultiviewToSingleView']=!0x1)),_0x3d15a2['onBeforeCameraRenderObservable']['add'](function(_0x3be60f){_0x3be60f['parent']===_0x2ecbac&&_0x2ecbac['rigParenting']&&(_0x2ecbac['_descendants']=_0x2ecbac['getDescendants'](!0x0,function(_0x49c815){var _0x523e6c=_0x2ecbac['controllers']['some'](function(_0x1ea198){return _0x1ea198['_mesh']===_0x49c815;}),_0x6bd45f=-0x1!==_0x2ecbac['_rigCameras']['indexOf'](_0x49c815);return!_0x523e6c&&!_0x6bd45f;}),_0x2ecbac['_descendants']['forEach'](function(_0x77c90e){_0x77c90e['parent']=_0x3be60f;}));}),_0x3d15a2['onAfterCameraRenderObservable']['add'](function(_0x25afa5){_0x25afa5['parent']===_0x2ecbac&&_0x2ecbac['rigParenting']&&_0x2ecbac['_descendants']['forEach'](function(_0x9266e6){_0x9266e6['parent']=_0x2ecbac;});}),_0x2ecbac;}return Object(_0x18e13d['d'])(_0x2cbce5,_0x577ff5),_0x2cbce5['prototype']['deviceDistanceToRoomGround']=function(){return this['_standingMatrix']?(this['_standingMatrix']['getTranslationToRef'](this['_workingVector']),this['_deviceRoomPosition']['y']+this['_workingVector']['y']):this['_defaultHeight']||0x0;},_0x2cbce5['prototype']['useStandingMatrix']=function(_0x4d1f71){var _0x440b5f=this;void 0x0===_0x4d1f71&&(_0x4d1f71=function(_0xadc4b0){}),this['getEngine']()['initWebVRAsync']()['then'](function(_0x2c9b49){_0x2c9b49['vrDisplay']&&_0x2c9b49['vrDisplay']['stageParameters']&&_0x2c9b49['vrDisplay']['stageParameters']['sittingToStandingTransform']&&_0x440b5f['webVROptions']['trackPosition']?(_0x440b5f['_standingMatrix']=new _0x74d525['a'](),_0x74d525['a']['FromFloat32ArrayToRefScaled'](_0x2c9b49['vrDisplay']['stageParameters']['sittingToStandingTransform'],0x0,0x1,_0x440b5f['_standingMatrix']),_0x440b5f['getScene']()['useRightHandedSystem']||_0x440b5f['_standingMatrix']&&_0x440b5f['_standingMatrix']['toggleModelMatrixHandInPlace'](),_0x4d1f71(!0x0)):_0x4d1f71(!0x1);});},_0x2cbce5['prototype']['useStandingMatrixAsync']=function(){var _0x385a29=this;return new Promise(function(_0x5c6efa){_0x385a29['useStandingMatrix'](function(_0x3609d7){_0x5c6efa(_0x3609d7);});});},_0x2cbce5['prototype']['dispose']=function(){this['_detachIfAttached'](),this['getEngine']()['onVRRequestPresentComplete']['removeCallback'](this['_onVREnabled']),this['_updateCacheWhenTrackingDisabledObserver']&&this['_scene']['onBeforeRenderObservable']['remove'](this['_updateCacheWhenTrackingDisabledObserver']),_0x577ff5['prototype']['dispose']['call'](this);},_0x2cbce5['prototype']['getControllerByName']=function(_0x12e24b){for(var _0xa589dd=0x0,_0x2c89f5=this['controllers'];_0xa589dd<_0x2c89f5['length'];_0xa589dd++){var _0x567d3b=_0x2c89f5[_0xa589dd];if(_0x567d3b['hand']===_0x12e24b)return _0x567d3b;}return null;},Object['defineProperty'](_0x2cbce5['prototype'],'leftController',{'get':function(){return this['_leftController']||(this['_leftController']=this['getControllerByName']('left')),this['_leftController'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2cbce5['prototype'],'rightController',{'get':function(){return this['_rightController']||(this['_rightController']=this['getControllerByName']('right')),this['_rightController'];},'enumerable':!0x1,'configurable':!0x0}),_0x2cbce5['prototype']['getForwardRay']=function(_0x55fd6f){return void 0x0===_0x55fd6f&&(_0x55fd6f=0x64),this['leftCamera']?_0x577ff5['prototype']['getForwardRay']['call'](this,_0x55fd6f,this['leftCamera']['getWorldMatrix'](),this['leftCamera']['globalPosition']):_0x577ff5['prototype']['getForwardRay']['call'](this,_0x55fd6f);},_0x2cbce5['prototype']['_checkInputs']=function(){this['_vrDevice']&&this['_vrDevice']['isPresenting']&&(this['_vrDevice']['getFrameData'](this['_frameData']),this['updateFromDevice'](this['_frameData']['pose'])),_0x577ff5['prototype']['_checkInputs']['call'](this);},_0x2cbce5['prototype']['updateFromDevice']=function(_0x3b4a29){_0x3b4a29&&_0x3b4a29['orientation']&&0x4===_0x3b4a29['orientation']['length']&&(this['rawPose']=_0x3b4a29,this['_deviceRoomRotationQuaternion']['copyFromFloats'](_0x3b4a29['orientation'][0x0],_0x3b4a29['orientation'][0x1],-_0x3b4a29['orientation'][0x2],-_0x3b4a29['orientation'][0x3]),this['getScene']()['useRightHandedSystem']&&(this['_deviceRoomRotationQuaternion']['z']*=-0x1,this['_deviceRoomRotationQuaternion']['w']*=-0x1),this['webVROptions']['trackPosition']&&this['rawPose']['position']&&(this['_deviceRoomPosition']['copyFromFloats'](this['rawPose']['position'][0x0],this['rawPose']['position'][0x1],-this['rawPose']['position'][0x2]),this['getScene']()['useRightHandedSystem']&&(this['_deviceRoomPosition']['z']*=-0x1)),this['_poseSet']=!0x0);},_0x2cbce5['prototype']['attachControl']=function(_0x1f5692){_0x1f5692=_0x5d754c['b']['BackCompatCameraNoPreventDefault'](arguments),_0x577ff5['prototype']['attachControl']['call'](this,_0x1f5692),this['_attached']=!0x0,_0x1f5692=!_0x568729['a']['ForceAttachControlToAlwaysPreventDefault']&&_0x1f5692,this['_vrDevice']&&this['getEngine']()['enableVR'](this['webVROptions']);var _0x5cbcf7=this['_scene']['getEngine']()['getHostWindow']();_0x5cbcf7&&_0x5cbcf7['addEventListener']('vrdisplaypresentchange',this['_detachIfAttached']);},_0x2cbce5['prototype']['detachControl']=function(_0x4d9bcd){this['getScene']()['gamepadManager']['onGamepadConnectedObservable']['remove'](this['_onGamepadConnectedObserver']),this['getScene']()['gamepadManager']['onGamepadDisconnectedObservable']['remove'](this['_onGamepadDisconnectedObserver']),_0x577ff5['prototype']['detachControl']['call'](this),this['_attached']=!0x1,this['getEngine']()['disableVR'](),window['removeEventListener']('vrdisplaypresentchange',this['_detachIfAttached']);},_0x2cbce5['prototype']['getClassName']=function(){return'WebVRFreeCamera';},_0x2cbce5['prototype']['resetToCurrentRotation']=function(){this['_vrDevice']['resetPose']();},_0x2cbce5['prototype']['_updateRigCameras']=function(){var _0xa1fb80=this['_rigCameras'][0x0],_0x27940e=this['_rigCameras'][0x1];_0xa1fb80['rotationQuaternion']['copyFrom'](this['_deviceRoomRotationQuaternion']),_0x27940e['rotationQuaternion']['copyFrom'](this['_deviceRoomRotationQuaternion']),_0xa1fb80['position']['copyFrom'](this['_deviceRoomPosition']),_0x27940e['position']['copyFrom'](this['_deviceRoomPosition']);},_0x2cbce5['prototype']['_correctPositionIfNotTrackPosition']=function(_0x51fa56,_0x1e50ac){void 0x0===_0x1e50ac&&(_0x1e50ac=!0x1),this['rawPose']&&this['rawPose']['position']&&!this['webVROptions']['trackPosition']&&(_0x74d525['a']['TranslationToRef'](this['rawPose']['position'][0x0],this['rawPose']['position'][0x1],-this['rawPose']['position'][0x2],this['_tmpMatrix']),_0x1e50ac||this['_tmpMatrix']['invert'](),this['_tmpMatrix']['multiplyToRef'](_0x51fa56,_0x51fa56));},_0x2cbce5['prototype']['_updateCache']=function(_0x29fe3d){var _0x244294=this;this['rotationQuaternion']['equals'](this['_cache']['rotationQuaternion'])&&this['position']['equals'](this['_cache']['position'])||(this['updateCacheCalled']||(this['updateCacheCalled']=!0x0,this['update']()),this['rotationQuaternion']['toRotationMatrix'](this['_workingMatrix']),_0x74d525['e']['TransformCoordinatesToRef'](this['_deviceRoomPosition'],this['_workingMatrix'],this['_workingVector']),this['devicePosition']['subtractToRef'](this['_workingVector'],this['_workingVector']),_0x74d525['a']['ComposeToRef'](this['_oneVector'],this['rotationQuaternion'],this['_workingVector'],this['_deviceToWorld']),this['_deviceToWorld']['getTranslationToRef'](this['_workingVector']),this['_workingVector']['addInPlace'](this['position']),this['_workingVector']['subtractInPlace'](this['_cache']['position']),this['_deviceToWorld']['setTranslation'](this['_workingVector']),this['_deviceToWorld']['invertToRef'](this['_worldToDevice']),this['controllers']['forEach'](function(_0x4c90fa){_0x4c90fa['_deviceToWorld']['copyFrom'](_0x244294['_deviceToWorld']),_0x244294['_correctPositionIfNotTrackPosition'](_0x4c90fa['_deviceToWorld']),_0x4c90fa['update']();})),_0x29fe3d||_0x577ff5['prototype']['_updateCache']['call'](this),this['updateCacheCalled']=!0x1;},_0x2cbce5['prototype']['_computeDevicePosition']=function(){_0x74d525['e']['TransformCoordinatesToRef'](this['_deviceRoomPosition'],this['_deviceToWorld'],this['devicePosition']);},_0x2cbce5['prototype']['update']=function(){this['_computeDevicePosition'](),_0x74d525['a']['FromQuaternionToRef'](this['_deviceRoomRotationQuaternion'],this['_workingMatrix']),this['_workingMatrix']['multiplyToRef'](this['_deviceToWorld'],this['_workingMatrix']),_0x74d525['b']['FromRotationMatrixToRef'](this['_workingMatrix'],this['deviceRotationQuaternion']),this['_poseSet']&&this['onPoseUpdatedFromDeviceObservable']['notifyObservers'](null),_0x577ff5['prototype']['update']['call'](this);},_0x2cbce5['prototype']['_getViewMatrix']=function(){return _0x74d525['a']['Identity']();},_0x2cbce5['prototype']['_getWebVRViewMatrix']=function(){var _0x378d82=this['_cameraRigParams']['parentCamera'];_0x378d82['_updateCache']();var _0x26c04f=this['_cameraRigParams']['left']?this['_cameraRigParams']['frameData']['leftViewMatrix']:this['_cameraRigParams']['frameData']['rightViewMatrix'];return _0x74d525['a']['FromArrayToRef'](_0x26c04f,0x0,this['_webvrViewMatrix']),this['getScene']()['useRightHandedSystem']||this['_webvrViewMatrix']['toggleModelMatrixHandInPlace'](),this['_webvrViewMatrix']['getRotationMatrixToRef'](this['_cameraRotationMatrix']),_0x74d525['e']['TransformCoordinatesToRef'](this['_referencePoint'],this['_cameraRotationMatrix'],this['_transformedReferencePoint']),this['position']['addToRef'](this['_transformedReferencePoint'],this['_currentTarget']),0x1!==_0x378d82['deviceScaleFactor']&&(this['_webvrViewMatrix']['invert'](),_0x378d82['deviceScaleFactor']&&(this['_webvrViewMatrix']['multiplyAtIndex'](0xc,_0x378d82['deviceScaleFactor']),this['_webvrViewMatrix']['multiplyAtIndex'](0xd,_0x378d82['deviceScaleFactor']),this['_webvrViewMatrix']['multiplyAtIndex'](0xe,_0x378d82['deviceScaleFactor'])),this['_webvrViewMatrix']['invert']()),_0x378d82['_correctPositionIfNotTrackPosition'](this['_webvrViewMatrix'],!0x0),_0x378d82['_worldToDevice']['multiplyToRef'](this['_webvrViewMatrix'],this['_webvrViewMatrix']),this['_workingMatrix']=this['_workingMatrix']||_0x74d525['a']['Identity'](),this['_webvrViewMatrix']['invertToRef'](this['_workingMatrix']),this['_workingMatrix']['multiplyToRef'](_0x378d82['getWorldMatrix'](),this['_workingMatrix']),this['_workingMatrix']['getTranslationToRef'](this['_globalPosition']),this['_markSyncedWithParent'](),this['_webvrViewMatrix'];},_0x2cbce5['prototype']['_getWebVRProjectionMatrix']=function(){var _0x38e7ed=this['parent'];_0x38e7ed['_vrDevice']['depthNear']=_0x38e7ed['minZ'],_0x38e7ed['_vrDevice']['depthFar']=_0x38e7ed['maxZ'];var _0x23d778=this['_cameraRigParams']['left']?this['_cameraRigParams']['frameData']['leftProjectionMatrix']:this['_cameraRigParams']['frameData']['rightProjectionMatrix'];return _0x74d525['a']['FromArrayToRef'](_0x23d778,0x0,this['_projectionMatrix']),this['getScene']()['useRightHandedSystem']||this['_projectionMatrix']['toggleProjectionMatrixHandInPlace'](),this['_projectionMatrix'];},_0x2cbce5['prototype']['initControllers']=function(){var _0x2cdc76=this;this['controllers']=[];var _0x116c5c=this['getScene']()['gamepadManager'];this['_onGamepadDisconnectedObserver']=_0x116c5c['onGamepadDisconnectedObservable']['add'](function(_0x3854e4){if(_0x3854e4['type']===_0x56ffd0['POSE_ENABLED']){var _0x11c1e5=_0x3854e4;_0x11c1e5['defaultModel']&&_0x11c1e5['defaultModel']['setEnabled'](!0x1),'right'===_0x11c1e5['hand']&&(_0x2cdc76['_rightController']=null),'left'===_0x11c1e5['hand']&&(_0x2cdc76['_leftController']=null);var _0x5a1bec=_0x2cdc76['controllers']['indexOf'](_0x11c1e5);-0x1!==_0x5a1bec&&_0x2cdc76['controllers']['splice'](_0x5a1bec,0x1);}}),this['_onGamepadConnectedObserver']=_0x116c5c['onGamepadConnectedObservable']['add'](function(_0x20d86a){if(_0x20d86a['type']===_0x56ffd0['POSE_ENABLED']){var _0x21ffe7=_0x20d86a;if(_0x2cdc76['webVROptions']['trackPosition']||(_0x21ffe7['_disableTrackPosition'](new _0x74d525['e']('left'==_0x21ffe7['hand']?-0.15:0.15,-0.5,0.25)),_0x2cdc76['_updateCacheWhenTrackingDisabledObserver']||(_0x2cdc76['_updateCacheWhenTrackingDisabledObserver']=_0x2cdc76['_scene']['onBeforeRenderObservable']['add'](function(){_0x2cdc76['_updateCache']();}))),_0x21ffe7['deviceScaleFactor']=_0x2cdc76['deviceScaleFactor'],_0x21ffe7['_deviceToWorld']['copyFrom'](_0x2cdc76['_deviceToWorld']),_0x2cdc76['_correctPositionIfNotTrackPosition'](_0x21ffe7['_deviceToWorld']),_0x2cdc76['webVROptions']['controllerMeshes']&&(_0x21ffe7['defaultModel']?_0x21ffe7['defaultModel']['setEnabled'](!0x0):_0x21ffe7['initControllerMesh'](_0x2cdc76['getScene'](),function(_0x11289b){if(_0x11289b['scaling']['scaleInPlace'](_0x2cdc76['deviceScaleFactor']),_0x2cdc76['onControllerMeshLoadedObservable']['notifyObservers'](_0x21ffe7),_0x2cdc76['webVROptions']['defaultLightingOnControllers']){_0x2cdc76['_lightOnControllers']||(_0x2cdc76['_lightOnControllers']=new _0xb2c680['a']('vrControllersLight',new _0x74d525['e'](0x0,0x1,0x0),_0x2cdc76['getScene']()));var _0x3e70f9=function(_0xa8937d,_0x4eac1c){var _0x4df25c=_0xa8937d['getChildren']();_0x4df25c&&0x0!==_0x4df25c['length']&&_0x4df25c['forEach'](function(_0x222ddc){_0x4eac1c['includedOnlyMeshes']['push'](_0x222ddc),_0x3e70f9(_0x222ddc,_0x4eac1c);});};_0x2cdc76['_lightOnControllers']['includedOnlyMeshes']['push'](_0x11289b),_0x3e70f9(_0x11289b,_0x2cdc76['_lightOnControllers']);}})),_0x21ffe7['attachToPoseControlledCamera'](_0x2cdc76),-0x1===_0x2cdc76['controllers']['indexOf'](_0x21ffe7)){_0x2cdc76['controllers']['push'](_0x21ffe7);for(var _0x3a19e4=!0x1,_0x3b6a3d=0x0;_0x3b6a3d<_0x2cdc76['controllers']['length'];_0x3b6a3d++)_0x2cdc76['controllers'][_0x3b6a3d]['controllerType']===_0x1a2757['VIVE']&&(_0x3a19e4?_0x2cdc76['controllers'][_0x3b6a3d]['hand']='right':(_0x3a19e4=!0x0,_0x2cdc76['controllers'][_0x3b6a3d]['hand']='left'));_0x2cdc76['controllers']['length']>=0x2&&_0x2cdc76['onControllersAttachedObservable']['notifyObservers'](_0x2cdc76['controllers']);}}});},_0x2cbce5;}(_0x5625b9),_0x5dfec2=function(_0x40e9f1){function _0x340440(_0x2304ca){var _0x29f2f5=_0x40e9f1['call'](this,_0x2304ca)||this;return _0x29f2f5['onTriggerStateChangedObservable']=new _0x6ac1f7['c'](),_0x29f2f5['onMainButtonStateChangedObservable']=new _0x6ac1f7['c'](),_0x29f2f5['onSecondaryButtonStateChangedObservable']=new _0x6ac1f7['c'](),_0x29f2f5['onPadStateChangedObservable']=new _0x6ac1f7['c'](),_0x29f2f5['onPadValuesChangedObservable']=new _0x6ac1f7['c'](),_0x29f2f5['pad']={'x':0x0,'y':0x0},_0x29f2f5['_changes']={'pressChanged':!0x1,'touchChanged':!0x1,'valueChanged':!0x1,'changed':!0x1},_0x29f2f5['_buttons']=new Array(_0x2304ca['buttons']['length']),_0x29f2f5['hand']=_0x2304ca['hand'],_0x29f2f5;}return Object(_0x18e13d['d'])(_0x340440,_0x40e9f1),_0x340440['prototype']['onButtonStateChange']=function(_0x419eb5){this['_onButtonStateChange']=_0x419eb5;},Object['defineProperty'](_0x340440['prototype'],'defaultModel',{'get':function(){return this['_defaultModel'];},'enumerable':!0x1,'configurable':!0x0}),_0x340440['prototype']['update']=function(){_0x40e9f1['prototype']['update']['call'](this);for(var _0x12bd04=0x0;_0x12bd04\x0a#include\x0a#include\x0avoid\x20main(void)\x0a{\x0avec4\x20result=texture2D(textureSampler,vUV);\x0a#ifdef\x20IMAGEPROCESSING\x0a#ifndef\x20FROMLINEARSPACE\x0a\x0aresult.rgb=toLinearSpace(result.rgb);\x0a#endif\x0aresult=applyImageProcessing(result);\x0a#else\x0a\x0a#ifdef\x20FROMLINEARSPACE\x0aresult=applyImageProcessing(result);\x0a#endif\x0a#endif\x0agl_FragColor=result;\x0a}');_0x494b01['a']['ShadersStore']['imageProcessingPixelShader']=_0x322458;var _0x53baeb=function(_0x4da036){function _0x3000a0(_0x50359e,_0x5b6cd6,_0x1cd3b3,_0x5a3b78,_0x272c86,_0x4b6e2c,_0x21e8ae,_0x1567b5){void 0x0===_0x1cd3b3&&(_0x1cd3b3=null),void 0x0===_0x21e8ae&&(_0x21e8ae=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']);var _0x3300e6=_0x4da036['call'](this,_0x50359e,'imageProcessing',[],[],_0x5b6cd6,_0x1cd3b3,_0x5a3b78,_0x272c86,_0x4b6e2c,null,_0x21e8ae,'postprocess',null,!0x0)||this;return _0x3300e6['_fromLinearSpace']=!0x0,_0x3300e6['_defines']={'IMAGEPROCESSING':!0x1,'VIGNETTE':!0x1,'VIGNETTEBLENDMODEMULTIPLY':!0x1,'VIGNETTEBLENDMODEOPAQUE':!0x1,'TONEMAPPING':!0x1,'TONEMAPPING_ACES':!0x1,'CONTRAST':!0x1,'COLORCURVES':!0x1,'COLORGRADING':!0x1,'COLORGRADING3D':!0x1,'FROMLINEARSPACE':!0x1,'SAMPLER3DGREENDEPTH':!0x1,'SAMPLER3DBGRMAP':!0x1,'IMAGEPROCESSINGPOSTPROCESS':!0x1,'EXPOSURE':!0x1},_0x1567b5?(_0x1567b5['applyByPostProcess']=!0x0,_0x3300e6['_attachImageProcessingConfiguration'](_0x1567b5,!0x0),_0x3300e6['fromLinearSpace']=!0x1):(_0x3300e6['_attachImageProcessingConfiguration'](null,!0x0),_0x3300e6['imageProcessingConfiguration']['applyByPostProcess']=!0x0),_0x3300e6['onApply']=function(_0x5bdd56){_0x3300e6['imageProcessingConfiguration']['bind'](_0x5bdd56,_0x3300e6['aspectRatio']);},_0x3300e6;}return Object(_0x18e13d['d'])(_0x3000a0,_0x4da036),Object['defineProperty'](_0x3000a0['prototype'],'imageProcessingConfiguration',{'get':function(){return this['_imageProcessingConfiguration'];},'set':function(_0x7f9340){_0x7f9340['applyByPostProcess']=!0x0,this['_attachImageProcessingConfiguration'](_0x7f9340);},'enumerable':!0x1,'configurable':!0x0}),_0x3000a0['prototype']['_attachImageProcessingConfiguration']=function(_0x2fb6a2,_0x2c21de){var _0x5e91de=this;if(void 0x0===_0x2c21de&&(_0x2c21de=!0x1),_0x2fb6a2!==this['_imageProcessingConfiguration']){if(this['_imageProcessingConfiguration']&&this['_imageProcessingObserver']&&this['_imageProcessingConfiguration']['onUpdateParameters']['remove'](this['_imageProcessingObserver']),_0x2fb6a2)this['_imageProcessingConfiguration']=_0x2fb6a2;else{var _0x5809d5=null,_0x44aa86=this['getEngine'](),_0x337619=this['getCamera']();if(_0x337619)_0x5809d5=_0x337619['getScene']();else{if(_0x44aa86&&_0x44aa86['scenes']){var _0x29c5dd=_0x44aa86['scenes'];_0x5809d5=_0x29c5dd[_0x29c5dd['length']-0x1];}else _0x5809d5=_0x44b9ce['a']['LastCreatedScene'];}this['_imageProcessingConfiguration']=_0x5809d5?_0x5809d5['imageProcessingConfiguration']:new _0x3f08d6['a']();}this['_imageProcessingConfiguration']&&(this['_imageProcessingObserver']=this['_imageProcessingConfiguration']['onUpdateParameters']['add'](function(){_0x5e91de['_updateParameters']();})),_0x2c21de||this['_updateParameters']();}},Object['defineProperty'](_0x3000a0['prototype'],'isSupported',{'get':function(){var _0x45b15e=this['getEffect']();return!_0x45b15e||_0x45b15e['isSupported'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3000a0['prototype'],'colorCurves',{'get':function(){return this['imageProcessingConfiguration']['colorCurves'];},'set':function(_0x512a00){this['imageProcessingConfiguration']['colorCurves']=_0x512a00;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3000a0['prototype'],'colorCurvesEnabled',{'get':function(){return this['imageProcessingConfiguration']['colorCurvesEnabled'];},'set':function(_0x110ba0){this['imageProcessingConfiguration']['colorCurvesEnabled']=_0x110ba0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3000a0['prototype'],'colorGradingTexture',{'get':function(){return this['imageProcessingConfiguration']['colorGradingTexture'];},'set':function(_0xeae424){this['imageProcessingConfiguration']['colorGradingTexture']=_0xeae424;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3000a0['prototype'],'colorGradingEnabled',{'get':function(){return this['imageProcessingConfiguration']['colorGradingEnabled'];},'set':function(_0x412883){this['imageProcessingConfiguration']['colorGradingEnabled']=_0x412883;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3000a0['prototype'],'exposure',{'get':function(){return this['imageProcessingConfiguration']['exposure'];},'set':function(_0x34fa55){this['imageProcessingConfiguration']['exposure']=_0x34fa55;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3000a0['prototype'],'toneMappingEnabled',{'get':function(){return this['_imageProcessingConfiguration']['toneMappingEnabled'];},'set':function(_0x5164c9){this['_imageProcessingConfiguration']['toneMappingEnabled']=_0x5164c9;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3000a0['prototype'],'toneMappingType',{'get':function(){return this['_imageProcessingConfiguration']['toneMappingType'];},'set':function(_0x1849cc){this['_imageProcessingConfiguration']['toneMappingType']=_0x1849cc;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3000a0['prototype'],'contrast',{'get':function(){return this['imageProcessingConfiguration']['contrast'];},'set':function(_0x42e2dc){this['imageProcessingConfiguration']['contrast']=_0x42e2dc;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3000a0['prototype'],'vignetteStretch',{'get':function(){return this['imageProcessingConfiguration']['vignetteStretch'];},'set':function(_0x283d74){this['imageProcessingConfiguration']['vignetteStretch']=_0x283d74;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3000a0['prototype'],'vignetteCentreX',{'get':function(){return this['imageProcessingConfiguration']['vignetteCentreX'];},'set':function(_0x3ce748){this['imageProcessingConfiguration']['vignetteCentreX']=_0x3ce748;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3000a0['prototype'],'vignetteCentreY',{'get':function(){return this['imageProcessingConfiguration']['vignetteCentreY'];},'set':function(_0x5f2c48){this['imageProcessingConfiguration']['vignetteCentreY']=_0x5f2c48;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3000a0['prototype'],'vignetteWeight',{'get':function(){return this['imageProcessingConfiguration']['vignetteWeight'];},'set':function(_0x41f018){this['imageProcessingConfiguration']['vignetteWeight']=_0x41f018;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3000a0['prototype'],'vignetteColor',{'get':function(){return this['imageProcessingConfiguration']['vignetteColor'];},'set':function(_0x4caa66){this['imageProcessingConfiguration']['vignetteColor']=_0x4caa66;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3000a0['prototype'],'vignetteCameraFov',{'get':function(){return this['imageProcessingConfiguration']['vignetteCameraFov'];},'set':function(_0x4c8ab0){this['imageProcessingConfiguration']['vignetteCameraFov']=_0x4c8ab0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3000a0['prototype'],'vignetteBlendMode',{'get':function(){return this['imageProcessingConfiguration']['vignetteBlendMode'];},'set':function(_0x339451){this['imageProcessingConfiguration']['vignetteBlendMode']=_0x339451;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3000a0['prototype'],'vignetteEnabled',{'get':function(){return this['imageProcessingConfiguration']['vignetteEnabled'];},'set':function(_0x362d6f){this['imageProcessingConfiguration']['vignetteEnabled']=_0x362d6f;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3000a0['prototype'],'fromLinearSpace',{'get':function(){return this['_fromLinearSpace'];},'set':function(_0xa2dad1){this['_fromLinearSpace']!==_0xa2dad1&&(this['_fromLinearSpace']=_0xa2dad1,this['_updateParameters']());},'enumerable':!0x1,'configurable':!0x0}),_0x3000a0['prototype']['getClassName']=function(){return'ImageProcessingPostProcess';},_0x3000a0['prototype']['_updateParameters']=function(){this['_defines']['FROMLINEARSPACE']=this['_fromLinearSpace'],this['imageProcessingConfiguration']['prepareDefines'](this['_defines'],!0x0);var _0x41562e='';for(var _0x2bfe54 in this['_defines'])this['_defines'][_0x2bfe54]&&(_0x41562e+='#define\x20'+_0x2bfe54+';\x0d\x0a');var _0x156daf=['textureSampler'],_0x26d0d4=['scale'];_0x3f08d6['a']&&(_0x3f08d6['a']['PrepareSamplers'](_0x156daf,this['_defines']),_0x3f08d6['a']['PrepareUniforms'](_0x26d0d4,this['_defines'])),this['updateEffect'](_0x41562e,_0x26d0d4,_0x156daf);},_0x3000a0['prototype']['dispose']=function(_0x3f29b3){_0x4da036['prototype']['dispose']['call'](this,_0x3f29b3),this['_imageProcessingConfiguration']&&this['_imageProcessingObserver']&&this['_imageProcessingConfiguration']['onUpdateParameters']['remove'](this['_imageProcessingObserver']),this['_imageProcessingConfiguration']&&(this['imageProcessingConfiguration']['applyByPostProcess']=!0x1);},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3000a0['prototype'],'_fromLinearSpace',void 0x0),_0x3000a0;}(_0x5cae84),_0xa18063=_0x162675(0x10),_0x212fbd=_0x162675(0x4);_0x3cf5e5['a']['_GroundMeshParser']=function(_0xd9b920,_0x3c3ef3){return _0x5e0e3b['Parse'](_0xd9b920,_0x3c3ef3);};var _0x5e0e3b=function(_0x2a4ae9){function _0x12d711(_0x6ff3ca,_0x11519e){var _0x2a3480=_0x2a4ae9['call'](this,_0x6ff3ca,_0x11519e)||this;return _0x2a3480['generateOctree']=!0x1,_0x2a3480;}return Object(_0x18e13d['d'])(_0x12d711,_0x2a4ae9),_0x12d711['prototype']['getClassName']=function(){return'GroundMesh';},Object['defineProperty'](_0x12d711['prototype'],'subdivisions',{'get':function(){return Math['min'](this['_subdivisionsX'],this['_subdivisionsY']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x12d711['prototype'],'subdivisionsX',{'get':function(){return this['_subdivisionsX'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x12d711['prototype'],'subdivisionsY',{'get':function(){return this['_subdivisionsY'];},'enumerable':!0x1,'configurable':!0x0}),_0x12d711['prototype']['optimize']=function(_0x3e7323,_0x44f79d){void 0x0===_0x44f79d&&(_0x44f79d=0x20),this['_subdivisionsX']=_0x3e7323,this['_subdivisionsY']=_0x3e7323,this['subdivide'](_0x3e7323),this['createOrUpdateSubmeshesOctree']&&this['createOrUpdateSubmeshesOctree'](_0x44f79d);},_0x12d711['prototype']['getHeightAtCoordinates']=function(_0x43716e,_0x2ab50c){var _0x3de5bb=this['getWorldMatrix'](),_0x338890=_0x74d525['c']['Matrix'][0x5];_0x3de5bb['invertToRef'](_0x338890);var _0x508ea3=_0x74d525['c']['Vector3'][0x8];if(_0x74d525['e']['TransformCoordinatesFromFloatsToRef'](_0x43716e,0x0,_0x2ab50c,_0x338890,_0x508ea3),_0x43716e=_0x508ea3['x'],_0x2ab50c=_0x508ea3['z'],_0x43716ethis['_maxX']||_0x2ab50cthis['_maxZ'])return this['position']['y'];this['_heightQuads']&&0x0!=this['_heightQuads']['length']||(this['_initHeightQuads'](),this['_computeHeightQuads']());var _0x18e83a=this['_getFacetAt'](_0x43716e,_0x2ab50c),_0x3f70cb=-(_0x18e83a['x']*_0x43716e+_0x18e83a['z']*_0x2ab50c+_0x18e83a['w'])/_0x18e83a['y'];return _0x74d525['e']['TransformCoordinatesFromFloatsToRef'](0x0,_0x3f70cb,0x0,_0x3de5bb,_0x508ea3),_0x508ea3['y'];},_0x12d711['prototype']['getNormalAtCoordinates']=function(_0x300ce3,_0x48212a){var _0x1484e4=new _0x74d525['e'](0x0,0x1,0x0);return this['getNormalAtCoordinatesToRef'](_0x300ce3,_0x48212a,_0x1484e4),_0x1484e4;},_0x12d711['prototype']['getNormalAtCoordinatesToRef']=function(_0x25895f,_0x476c3b,_0x27cd33){var _0x16bc3c=this['getWorldMatrix'](),_0x3ea26d=_0x74d525['c']['Matrix'][0x5];_0x16bc3c['invertToRef'](_0x3ea26d);var _0x39c9d6=_0x74d525['c']['Vector3'][0x8];if(_0x74d525['e']['TransformCoordinatesFromFloatsToRef'](_0x25895f,0x0,_0x476c3b,_0x3ea26d,_0x39c9d6),_0x25895f=_0x39c9d6['x'],_0x476c3b=_0x39c9d6['z'],_0x25895fthis['_maxX']||_0x476c3bthis['_maxZ'])return this;this['_heightQuads']&&0x0!=this['_heightQuads']['length']||(this['_initHeightQuads'](),this['_computeHeightQuads']());var _0x193cd4=this['_getFacetAt'](_0x25895f,_0x476c3b);return _0x74d525['e']['TransformNormalFromFloatsToRef'](_0x193cd4['x'],_0x193cd4['y'],_0x193cd4['z'],_0x16bc3c,_0x27cd33),this;},_0x12d711['prototype']['updateCoordinateHeights']=function(){return this['_heightQuads']&&0x0!=this['_heightQuads']['length']||this['_initHeightQuads'](),this['_computeHeightQuads'](),this;},_0x12d711['prototype']['_getFacetAt']=function(_0x51d1d5,_0x549dcd){var _0x342167=Math['floor']((_0x51d1d5+this['_maxX'])*this['_subdivisionsX']/this['_width']),_0x48bc8d=Math['floor'](-(_0x549dcd+this['_maxZ'])*this['_subdivisionsY']/this['_height']+this['_subdivisionsY']),_0x1e4aed=this['_heightQuads'][_0x48bc8d*this['_subdivisionsX']+_0x342167];return _0x549dcd<_0x1e4aed['slope']['x']*_0x51d1d5+_0x1e4aed['slope']['y']?_0x1e4aed['facet1']:_0x1e4aed['facet2'];},_0x12d711['prototype']['_initHeightQuads']=function(){var _0x379119=this['_subdivisionsX'],_0x180f07=this['_subdivisionsY'];this['_heightQuads']=new Array();for(var _0x29606d=0x0;_0x29606d<_0x180f07;_0x29606d++)for(var _0x47e877=0x0;_0x47e877<_0x379119;_0x47e877++){var _0x1969dc={'slope':_0x74d525['d']['Zero'](),'facet1':new _0x74d525['f'](0x0,0x0,0x0,0x0),'facet2':new _0x74d525['f'](0x0,0x0,0x0,0x0)};this['_heightQuads'][_0x29606d*_0x379119+_0x47e877]=_0x1969dc;}return this;},_0x12d711['prototype']['_computeHeightQuads']=function(){var _0x56ed52=this['getVerticesData'](_0x212fbd['b']['PositionKind']);if(!_0x56ed52)return this;for(var _0x7589d7=_0x74d525['c']['Vector3'][0x3],_0x5516bc=_0x74d525['c']['Vector3'][0x2],_0x5e050e=_0x74d525['c']['Vector3'][0x1],_0x1f5bac=_0x74d525['c']['Vector3'][0x0],_0x4f2ee3=_0x74d525['c']['Vector3'][0x4],_0x22959a=_0x74d525['c']['Vector3'][0x5],_0x3e5889=_0x74d525['c']['Vector3'][0x6],_0x5f06ed=_0x74d525['c']['Vector3'][0x7],_0x427d30=_0x74d525['c']['Vector3'][0x8],_0x404b0e=0x0,_0x5da643=0x0,_0x5de214=0x0,_0x106fb2=0x0,_0x1141ff=0x0,_0x4aa0eb=0x0,_0x4bf3e1=0x0,_0x326574=this['_subdivisionsX'],_0x1ceaba=this['_subdivisionsY'],_0x12c4b8=0x0;_0x12c4b8<_0x1ceaba;_0x12c4b8++)for(var _0x596567=0x0;_0x596567<_0x326574;_0x596567++){_0x404b0e=0x3*_0x596567,_0x5da643=_0x12c4b8*(_0x326574+0x1)*0x3,_0x5de214=(_0x12c4b8+0x1)*(_0x326574+0x1)*0x3,_0x7589d7['x']=_0x56ed52[_0x5da643+_0x404b0e],_0x7589d7['y']=_0x56ed52[_0x5da643+_0x404b0e+0x1],_0x7589d7['z']=_0x56ed52[_0x5da643+_0x404b0e+0x2],_0x5516bc['x']=_0x56ed52[_0x5da643+_0x404b0e+0x3],_0x5516bc['y']=_0x56ed52[_0x5da643+_0x404b0e+0x4],_0x5516bc['z']=_0x56ed52[_0x5da643+_0x404b0e+0x5],_0x5e050e['x']=_0x56ed52[_0x5de214+_0x404b0e],_0x5e050e['y']=_0x56ed52[_0x5de214+_0x404b0e+0x1],_0x5e050e['z']=_0x56ed52[_0x5de214+_0x404b0e+0x2],_0x1f5bac['x']=_0x56ed52[_0x5de214+_0x404b0e+0x3],_0x1f5bac['y']=_0x56ed52[_0x5de214+_0x404b0e+0x4],_0x1f5bac['z']=_0x56ed52[_0x5de214+_0x404b0e+0x5],_0x106fb2=(_0x1f5bac['z']-_0x7589d7['z'])/(_0x1f5bac['x']-_0x7589d7['x']),_0x1141ff=_0x7589d7['z']-_0x106fb2*_0x7589d7['x'],_0x5516bc['subtractToRef'](_0x7589d7,_0x4f2ee3),_0x5e050e['subtractToRef'](_0x7589d7,_0x22959a),_0x1f5bac['subtractToRef'](_0x7589d7,_0x3e5889),_0x74d525['e']['CrossToRef'](_0x3e5889,_0x22959a,_0x5f06ed),_0x74d525['e']['CrossToRef'](_0x4f2ee3,_0x3e5889,_0x427d30),_0x5f06ed['normalize'](),_0x427d30['normalize'](),_0x4aa0eb=-(_0x5f06ed['x']*_0x7589d7['x']+_0x5f06ed['y']*_0x7589d7['y']+_0x5f06ed['z']*_0x7589d7['z']),_0x4bf3e1=-(_0x427d30['x']*_0x5516bc['x']+_0x427d30['y']*_0x5516bc['y']+_0x427d30['z']*_0x5516bc['z']);var _0xad0661=this['_heightQuads'][_0x12c4b8*_0x326574+_0x596567];_0xad0661['slope']['copyFromFloats'](_0x106fb2,_0x1141ff),_0xad0661['facet1']['copyFromFloats'](_0x5f06ed['x'],_0x5f06ed['y'],_0x5f06ed['z'],_0x4aa0eb),_0xad0661['facet2']['copyFromFloats'](_0x427d30['x'],_0x427d30['y'],_0x427d30['z'],_0x4bf3e1);}return this;},_0x12d711['prototype']['serialize']=function(_0xd165cd){_0x2a4ae9['prototype']['serialize']['call'](this,_0xd165cd),_0xd165cd['subdivisionsX']=this['_subdivisionsX'],_0xd165cd['subdivisionsY']=this['_subdivisionsY'],_0xd165cd['minX']=this['_minX'],_0xd165cd['maxX']=this['_maxX'],_0xd165cd['minZ']=this['_minZ'],_0xd165cd['maxZ']=this['_maxZ'],_0xd165cd['width']=this['_width'],_0xd165cd['height']=this['_height'];},_0x12d711['Parse']=function(_0xdf795,_0x129f49){var _0x5663f9=new _0x12d711(_0xdf795['name'],_0x129f49);return _0x5663f9['_subdivisionsX']=_0xdf795['subdivisionsX']||0x1,_0x5663f9['_subdivisionsY']=_0xdf795['subdivisionsY']||0x1,_0x5663f9['_minX']=_0xdf795['minX'],_0x5663f9['_maxX']=_0xdf795['maxX'],_0x5663f9['_minZ']=_0xdf795['minZ'],_0x5663f9['_maxZ']=_0xdf795['maxZ'],_0x5663f9['_width']=_0xdf795['width'],_0x5663f9['_height']=_0xdf795['height'],_0x5663f9;},_0x12d711;}(_0x3cf5e5['a']),_0x27137b=_0x162675(0x46);_0xa18063['a']['CreateGround']=function(_0x5e071d){var _0xc87ac7,_0x5df8fd,_0x584065=[],_0x27aae9=[],_0x587d56=[],_0x90a539=[],_0x294533=_0x5e071d['width']||0x1,_0x74836d=_0x5e071d['height']||0x1,_0x3201ee=_0x5e071d['subdivisionsX']||_0x5e071d['subdivisions']||0x1,_0x416271=_0x5e071d['subdivisionsY']||_0x5e071d['subdivisions']||0x1;for(_0xc87ac7=0x0;_0xc87ac7<=_0x416271;_0xc87ac7++)for(_0x5df8fd=0x0;_0x5df8fd<=_0x3201ee;_0x5df8fd++){var _0xd4be25=new _0x74d525['e'](_0x5df8fd*_0x294533/_0x3201ee-_0x294533/0x2,0x0,(_0x416271-_0xc87ac7)*_0x74836d/_0x416271-_0x74836d/0x2),_0x32400a=new _0x74d525['e'](0x0,0x1,0x0);_0x27aae9['push'](_0xd4be25['x'],_0xd4be25['y'],_0xd4be25['z']),_0x587d56['push'](_0x32400a['x'],_0x32400a['y'],_0x32400a['z']),_0x90a539['push'](_0x5df8fd/_0x3201ee,0x1-_0xc87ac7/_0x416271);}for(_0xc87ac7=0x0;_0xc87ac7<_0x416271;_0xc87ac7++)for(_0x5df8fd=0x0;_0x5df8fd<_0x3201ee;_0x5df8fd++)_0x584065['push'](_0x5df8fd+0x1+(_0xc87ac7+0x1)*(_0x3201ee+0x1)),_0x584065['push'](_0x5df8fd+0x1+_0xc87ac7*(_0x3201ee+0x1)),_0x584065['push'](_0x5df8fd+_0xc87ac7*(_0x3201ee+0x1)),_0x584065['push'](_0x5df8fd+(_0xc87ac7+0x1)*(_0x3201ee+0x1)),_0x584065['push'](_0x5df8fd+0x1+(_0xc87ac7+0x1)*(_0x3201ee+0x1)),_0x584065['push'](_0x5df8fd+_0xc87ac7*(_0x3201ee+0x1));var _0x362e51=new _0xa18063['a']();return _0x362e51['indices']=_0x584065,_0x362e51['positions']=_0x27aae9,_0x362e51['normals']=_0x587d56,_0x362e51['uvs']=_0x90a539,_0x362e51;},_0xa18063['a']['CreateTiledGround']=function(_0x4d683b){var _0x863979,_0xb28ffb,_0x41ac67,_0x206300,_0x4806ff=void 0x0!==_0x4d683b['xmin']&&null!==_0x4d683b['xmin']?_0x4d683b['xmin']:-0x1,_0x5bc464=void 0x0!==_0x4d683b['zmin']&&null!==_0x4d683b['zmin']?_0x4d683b['zmin']:-0x1,_0xe27f84=void 0x0!==_0x4d683b['xmax']&&null!==_0x4d683b['xmax']?_0x4d683b['xmax']:0x1,_0x53f71c=void 0x0!==_0x4d683b['zmax']&&null!==_0x4d683b['zmax']?_0x4d683b['zmax']:0x1,_0x45887e=_0x4d683b['subdivisions']||{'w':0x1,'h':0x1},_0xeb7df2=_0x4d683b['precision']||{'w':0x1,'h':0x1},_0x40b155=new Array(),_0xfbadc9=new Array(),_0x2932a7=new Array(),_0x28b28e=new Array();_0x45887e['h']=_0x45887e['h']<0x1?0x1:_0x45887e['h'],_0x45887e['w']=_0x45887e['w']<0x1?0x1:_0x45887e['w'],_0xeb7df2['w']=_0xeb7df2['w']<0x1?0x1:_0xeb7df2['w'],_0xeb7df2['h']=_0xeb7df2['h']<0x1?0x1:_0xeb7df2['h'];var _0x5aa86d=(_0xe27f84-_0x4806ff)/_0x45887e['w'],_0x4a2362=(_0x53f71c-_0x5bc464)/_0x45887e['h'];function _0x57b467(_0x178247,_0x5344cd,_0x5cb8f3,_0x32e011){var _0x587b4a=_0xfbadc9['length']/0x3,_0x395611=_0xeb7df2['w']+0x1;for(_0x863979=0x0;_0x863979<_0xeb7df2['h'];_0x863979++)for(_0xb28ffb=0x0;_0xb28ffb<_0xeb7df2['w'];_0xb28ffb++){var _0x22955a=[_0x587b4a+_0xb28ffb+_0x863979*_0x395611,_0x587b4a+(_0xb28ffb+0x1)+_0x863979*_0x395611,_0x587b4a+(_0xb28ffb+0x1)+(_0x863979+0x1)*_0x395611,_0x587b4a+_0xb28ffb+(_0x863979+0x1)*_0x395611];_0x40b155['push'](_0x22955a[0x1]),_0x40b155['push'](_0x22955a[0x2]),_0x40b155['push'](_0x22955a[0x3]),_0x40b155['push'](_0x22955a[0x0]),_0x40b155['push'](_0x22955a[0x1]),_0x40b155['push'](_0x22955a[0x3]);}var _0x3c551b=_0x74d525['e']['Zero'](),_0x137c13=new _0x74d525['e'](0x0,0x1,0x0);for(_0x863979=0x0;_0x863979<=_0xeb7df2['h'];_0x863979++)for(_0x3c551b['z']=_0x863979*(_0x32e011-_0x5344cd)/_0xeb7df2['h']+_0x5344cd,_0xb28ffb=0x0;_0xb28ffb<=_0xeb7df2['w'];_0xb28ffb++)_0x3c551b['x']=_0xb28ffb*(_0x5cb8f3-_0x178247)/_0xeb7df2['w']+_0x178247,_0x3c551b['y']=0x0,_0xfbadc9['push'](_0x3c551b['x'],_0x3c551b['y'],_0x3c551b['z']),_0x2932a7['push'](_0x137c13['x'],_0x137c13['y'],_0x137c13['z']),_0x28b28e['push'](_0xb28ffb/_0xeb7df2['w'],_0x863979/_0xeb7df2['h']);}for(_0x41ac67=0x0;_0x41ac67<_0x45887e['h'];_0x41ac67++)for(_0x206300=0x0;_0x206300<_0x45887e['w'];_0x206300++)_0x57b467(_0x4806ff+_0x206300*_0x5aa86d,_0x5bc464+_0x41ac67*_0x4a2362,_0x4806ff+(_0x206300+0x1)*_0x5aa86d,_0x5bc464+(_0x41ac67+0x1)*_0x4a2362);var _0x525e3c=new _0xa18063['a']();return _0x525e3c['indices']=_0x40b155,_0x525e3c['positions']=_0xfbadc9,_0x525e3c['normals']=_0x2932a7,_0x525e3c['uvs']=_0x28b28e,_0x525e3c;},_0xa18063['a']['CreateGroundFromHeightMap']=function(_0x7328e6){var _0x254052,_0x4ebb2f,_0x5df729=[],_0xe3e9d3=[],_0x517907=[],_0x2fbd65=[],_0x2abaef=_0x7328e6['colorFilter']||new _0x39310d['a'](0.3,0.59,0.11),_0x4a7e59=_0x7328e6['alphaFilter']||0x0,_0x206660=!0x1;if(_0x7328e6['minHeight']>_0x7328e6['maxHeight']){_0x206660=!0x0;var _0x5da8be=_0x7328e6['maxHeight'];_0x7328e6['maxHeight']=_0x7328e6['minHeight'],_0x7328e6['minHeight']=_0x5da8be;}for(_0x254052=0x0;_0x254052<=_0x7328e6['subdivisions'];_0x254052++)for(_0x4ebb2f=0x0;_0x4ebb2f<=_0x7328e6['subdivisions'];_0x4ebb2f++){var _0x14dee5=new _0x74d525['e'](_0x4ebb2f*_0x7328e6['width']/_0x7328e6['subdivisions']-_0x7328e6['width']/0x2,0x0,(_0x7328e6['subdivisions']-_0x254052)*_0x7328e6['height']/_0x7328e6['subdivisions']-_0x7328e6['height']/0x2),_0x496c6b=0x4*(((_0x14dee5['x']+_0x7328e6['width']/0x2)/_0x7328e6['width']*(_0x7328e6['bufferWidth']-0x1)|0x0)+((0x1-(_0x14dee5['z']+_0x7328e6['height']/0x2)/_0x7328e6['height'])*(_0x7328e6['bufferHeight']-0x1)|0x0)*_0x7328e6['bufferWidth']),_0x1bd222=_0x7328e6['buffer'][_0x496c6b]/0xff,_0x497ce0=_0x7328e6['buffer'][_0x496c6b+0x1]/0xff,_0x39992c=_0x7328e6['buffer'][_0x496c6b+0x2]/0xff,_0x314cbc=_0x7328e6['buffer'][_0x496c6b+0x3]/0xff;_0x206660&&(_0x1bd222=0x1-_0x1bd222,_0x497ce0=0x1-_0x497ce0,_0x39992c=0x1-_0x39992c);var _0x45df67=_0x1bd222*_0x2abaef['r']+_0x497ce0*_0x2abaef['g']+_0x39992c*_0x2abaef['b'];_0x14dee5['y']=_0x314cbc>=_0x4a7e59?_0x7328e6['minHeight']+(_0x7328e6['maxHeight']-_0x7328e6['minHeight'])*_0x45df67:_0x7328e6['minHeight']-_0x27da6e['a'],_0xe3e9d3['push'](_0x14dee5['x'],_0x14dee5['y'],_0x14dee5['z']),_0x517907['push'](0x0,0x0,0x0),_0x2fbd65['push'](_0x4ebb2f/_0x7328e6['subdivisions'],0x1-_0x254052/_0x7328e6['subdivisions']);}for(_0x254052=0x0;_0x254052<_0x7328e6['subdivisions'];_0x254052++)for(_0x4ebb2f=0x0;_0x4ebb2f<_0x7328e6['subdivisions'];_0x4ebb2f++){var _0x442cf8=_0x4ebb2f+0x1+(_0x254052+0x1)*(_0x7328e6['subdivisions']+0x1),_0x2bdc20=_0x4ebb2f+0x1+_0x254052*(_0x7328e6['subdivisions']+0x1),_0x9a394b=_0x4ebb2f+_0x254052*(_0x7328e6['subdivisions']+0x1),_0x28b227=_0x4ebb2f+(_0x254052+0x1)*(_0x7328e6['subdivisions']+0x1),_0x323968=_0xe3e9d3[0x3*_0x442cf8+0x1]>=_0x7328e6['minHeight'],_0x3bf77a=_0xe3e9d3[0x3*_0x2bdc20+0x1]>=_0x7328e6['minHeight'],_0x1cc450=_0xe3e9d3[0x3*_0x9a394b+0x1]>=_0x7328e6['minHeight'];_0x323968&&_0x3bf77a&&_0x1cc450&&(_0x5df729['push'](_0x442cf8),_0x5df729['push'](_0x2bdc20),_0x5df729['push'](_0x9a394b)),_0xe3e9d3[0x3*_0x28b227+0x1]>=_0x7328e6['minHeight']&&_0x323968&&_0x1cc450&&(_0x5df729['push'](_0x28b227),_0x5df729['push'](_0x442cf8),_0x5df729['push'](_0x9a394b));}_0xa18063['a']['ComputeNormals'](_0xe3e9d3,_0x5df729,_0x517907);var _0x2f7188=new _0xa18063['a']();return _0x2f7188['indices']=_0x5df729,_0x2f7188['positions']=_0xe3e9d3,_0x2f7188['normals']=_0x517907,_0x2f7188['uvs']=_0x2fbd65,_0x2f7188;},_0x3cf5e5['a']['CreateGround']=function(_0x13bd0c,_0x317ede,_0x52f732,_0x468552,_0x38a0a9,_0xca1044){var _0x1c89f1={'width':_0x317ede,'height':_0x52f732,'subdivisions':_0x468552,'updatable':_0xca1044};return _0x369c28['CreateGround'](_0x13bd0c,_0x1c89f1,_0x38a0a9);},_0x3cf5e5['a']['CreateTiledGround']=function(_0x41f3d7,_0x5a1cf0,_0x1b8dd7,_0x3d9d6f,_0x1c9b03,_0x198353,_0x217a87,_0x482674,_0x49dbf5){var _0x5d6e9c={'xmin':_0x5a1cf0,'zmin':_0x1b8dd7,'xmax':_0x3d9d6f,'zmax':_0x1c9b03,'subdivisions':_0x198353,'precision':_0x217a87,'updatable':_0x49dbf5};return _0x369c28['CreateTiledGround'](_0x41f3d7,_0x5d6e9c,_0x482674);},_0x3cf5e5['a']['CreateGroundFromHeightMap']=function(_0x24919e,_0x46f219,_0x25acd6,_0x5d5b28,_0x499f24,_0xd8a84b,_0x15a58f,_0x1bd3dc,_0x2e0ca9,_0x29d27c,_0x11c2d1){var _0x23c9e3={'width':_0x25acd6,'height':_0x5d5b28,'subdivisions':_0x499f24,'minHeight':_0xd8a84b,'maxHeight':_0x15a58f,'updatable':_0x2e0ca9,'onReady':_0x29d27c,'alphaFilter':_0x11c2d1};return _0x369c28['CreateGroundFromHeightMap'](_0x24919e,_0x46f219,_0x23c9e3,_0x1bd3dc);};var _0x369c28=(function(){function _0x3d7652(){}return _0x3d7652['CreateGround']=function(_0x230bbf,_0x53cb40,_0xccb532){var _0x2f1b23=new _0x5e0e3b(_0x230bbf,_0xccb532);return _0x2f1b23['_setReady'](!0x1),_0x2f1b23['_subdivisionsX']=_0x53cb40['subdivisionsX']||_0x53cb40['subdivisions']||0x1,_0x2f1b23['_subdivisionsY']=_0x53cb40['subdivisionsY']||_0x53cb40['subdivisions']||0x1,_0x2f1b23['_width']=_0x53cb40['width']||0x1,_0x2f1b23['_height']=_0x53cb40['height']||0x1,_0x2f1b23['_maxX']=_0x2f1b23['_width']/0x2,_0x2f1b23['_maxZ']=_0x2f1b23['_height']/0x2,_0x2f1b23['_minX']=-_0x2f1b23['_maxX'],_0x2f1b23['_minZ']=-_0x2f1b23['_maxZ'],_0xa18063['a']['CreateGround'](_0x53cb40)['applyToMesh'](_0x2f1b23,_0x53cb40['updatable']),_0x2f1b23['_setReady'](!0x0),_0x2f1b23;},_0x3d7652['CreateTiledGround']=function(_0x341773,_0x19ba3d,_0x144a19){void 0x0===_0x144a19&&(_0x144a19=null);var _0x3d4ac1=new _0x3cf5e5['a'](_0x341773,_0x144a19);return _0xa18063['a']['CreateTiledGround'](_0x19ba3d)['applyToMesh'](_0x3d4ac1,_0x19ba3d['updatable']),_0x3d4ac1;},_0x3d7652['CreateGroundFromHeightMap']=function(_0x2594b6,_0x36efce,_0x26e0f4,_0x906aa0){void 0x0===_0x906aa0&&(_0x906aa0=null);var _0x198fb7=_0x26e0f4['width']||0xa,_0x556c1b=_0x26e0f4['height']||0xa,_0x336245=_0x26e0f4['subdivisions']||0x1,_0x1ef619=_0x26e0f4['minHeight']||0x0,_0x5923aa=_0x26e0f4['maxHeight']||0x1,_0x1d8da8=_0x26e0f4['colorFilter']||new _0x39310d['a'](0.3,0.59,0.11),_0x239440=_0x26e0f4['alphaFilter']||0x0,_0x2cdd4b=_0x26e0f4['updatable'],_0x54e84a=_0x26e0f4['onReady'];_0x906aa0=_0x906aa0||_0x44b9ce['a']['LastCreatedScene'];var _0xee3a79=new _0x5e0e3b(_0x2594b6,_0x906aa0);return _0xee3a79['_subdivisionsX']=_0x336245,_0xee3a79['_subdivisionsY']=_0x336245,_0xee3a79['_width']=_0x198fb7,_0xee3a79['_height']=_0x556c1b,_0xee3a79['_maxX']=_0xee3a79['_width']/0x2,_0xee3a79['_maxZ']=_0xee3a79['_height']/0x2,_0xee3a79['_minX']=-_0xee3a79['_maxX'],_0xee3a79['_minZ']=-_0xee3a79['_maxZ'],_0xee3a79['_setReady'](!0x1),(_0x5d754c['b']['LoadImage'](_0x36efce,function(_0x19561d){var _0xd498e1=_0x19561d['width'],_0x21e164=_0x19561d['height'],_0x10ec72=_0x27137b['a']['CreateCanvas'](_0xd498e1,_0x21e164)['getContext']('2d');if(!_0x10ec72)throw new Error('Unable\x20to\x20get\x202d\x20context\x20for\x20CreateGroundFromHeightMap');if(!_0x906aa0['isDisposed']){_0x10ec72['drawImage'](_0x19561d,0x0,0x0);var _0x502e98=_0x10ec72['getImageData'](0x0,0x0,_0xd498e1,_0x21e164)['data'];_0xa18063['a']['CreateGroundFromHeightMap']({'width':_0x198fb7,'height':_0x556c1b,'subdivisions':_0x336245,'minHeight':_0x1ef619,'maxHeight':_0x5923aa,'colorFilter':_0x1d8da8,'buffer':_0x502e98,'bufferWidth':_0xd498e1,'bufferHeight':_0x21e164,'alphaFilter':_0x239440})['applyToMesh'](_0xee3a79,_0x2cdd4b),_0x54e84a&&_0x54e84a(_0xee3a79),_0xee3a79['_setReady'](!0x0);}},function(){},_0x906aa0['offlineProvider']),_0xee3a79);},_0x3d7652;}());_0xa18063['a']['CreateTorus']=function(_0x3036ce){for(var _0xee78ec=[],_0x5e13a7=[],_0x26fafb=[],_0x206317=[],_0x59917e=_0x3036ce['diameter']||0x1,_0x350376=_0x3036ce['thickness']||0.5,_0x28fad3=_0x3036ce['tessellation']||0x10,_0x5f17ed=0x0===_0x3036ce['sideOrientation']?0x0:_0x3036ce['sideOrientation']||_0xa18063['a']['DEFAULTSIDE'],_0x125ac1=_0x28fad3+0x1,_0x1e3b54=0x0;_0x1e3b54<=_0x28fad3;_0x1e3b54++)for(var _0x22fd3c=_0x1e3b54/_0x28fad3,_0x37d88f=_0x1e3b54*Math['PI']*0x2/_0x28fad3-Math['PI']/0x2,_0x51c5c2=_0x74d525['a']['Translation'](_0x59917e/0x2,0x0,0x0)['multiply'](_0x74d525['a']['RotationY'](_0x37d88f)),_0x412e97=0x0;_0x412e97<=_0x28fad3;_0x412e97++){var _0x4598fb=0x1-_0x412e97/_0x28fad3,_0x1aa524=_0x412e97*Math['PI']*0x2/_0x28fad3+Math['PI'],_0x2226d4=Math['cos'](_0x1aa524),_0x543368=Math['sin'](_0x1aa524),_0x2140bd=new _0x74d525['e'](_0x2226d4,_0x543368,0x0),_0x3e81ec=_0x2140bd['scale'](_0x350376/0x2),_0x2f07d3=new _0x74d525['d'](_0x22fd3c,_0x4598fb);_0x3e81ec=_0x74d525['e']['TransformCoordinates'](_0x3e81ec,_0x51c5c2),_0x2140bd=_0x74d525['e']['TransformNormal'](_0x2140bd,_0x51c5c2),_0x5e13a7['push'](_0x3e81ec['x'],_0x3e81ec['y'],_0x3e81ec['z']),_0x26fafb['push'](_0x2140bd['x'],_0x2140bd['y'],_0x2140bd['z']),_0x206317['push'](_0x2f07d3['x'],_0x2f07d3['y']);var _0x254c0d=(_0x1e3b54+0x1)%_0x125ac1,_0x50f2c2=(_0x412e97+0x1)%_0x125ac1;_0xee78ec['push'](_0x1e3b54*_0x125ac1+_0x412e97),_0xee78ec['push'](_0x1e3b54*_0x125ac1+_0x50f2c2),_0xee78ec['push'](_0x254c0d*_0x125ac1+_0x412e97),_0xee78ec['push'](_0x1e3b54*_0x125ac1+_0x50f2c2),_0xee78ec['push'](_0x254c0d*_0x125ac1+_0x50f2c2),_0xee78ec['push'](_0x254c0d*_0x125ac1+_0x412e97);}_0xa18063['a']['_ComputeSides'](_0x5f17ed,_0x5e13a7,_0xee78ec,_0x26fafb,_0x206317,_0x3036ce['frontUVs'],_0x3036ce['backUVs']);var _0x159959=new _0xa18063['a']();return _0x159959['indices']=_0xee78ec,_0x159959['positions']=_0x5e13a7,_0x159959['normals']=_0x26fafb,_0x159959['uvs']=_0x206317,_0x159959;},_0x3cf5e5['a']['CreateTorus']=function(_0x39be31,_0x402511,_0x5e4cf7,_0x1e1404,_0x4ae038,_0x5609a6,_0x34c0a6){var _0x13cdcc={'diameter':_0x402511,'thickness':_0x5e4cf7,'tessellation':_0x1e1404,'sideOrientation':_0x34c0a6,'updatable':_0x5609a6};return _0x4a716b['CreateTorus'](_0x39be31,_0x13cdcc,_0x4ae038);};var _0xada4aa,_0x49ab50,_0x4a716b=(function(){function _0x404f89(){}return _0x404f89['CreateTorus']=function(_0x437eb3,_0x2e2afa,_0x5d8d74){var _0x1ffe35=new _0x3cf5e5['a'](_0x437eb3,_0x5d8d74);return _0x2e2afa['sideOrientation']=_0x3cf5e5['a']['_GetDefaultSideOrientation'](_0x2e2afa['sideOrientation']),_0x1ffe35['_originalBuilderSideOrientation']=_0x2e2afa['sideOrientation'],_0xa18063['a']['CreateTorus'](_0x2e2afa)['applyToMesh'](_0x1ffe35,_0x2e2afa['updatable']),_0x1ffe35;},_0x404f89;}()),_0x179064=_0x162675(0x35),_0x3b39f6=(function(){function _0x2f18e1(){}return _0x2f18e1['GetDefaults']=function(_0xb61f18){var _0x58f73c=new _0x2f18e1();return _0x58f73c['canvasOptions']={'antialias':!0x0,'depth':!0x0,'stencil':!_0xb61f18||_0xb61f18['isStencilEnable'],'alpha':!0x0,'multiview':!0x1,'framebufferScaleFactor':0x1},_0x58f73c['newCanvasCssStyle']='position:absolute;\x20bottom:0px;right:0px;z-index:10;width:90%;height:100%;background-color:\x20#000000;',_0x58f73c;},_0x2f18e1;}()),_0x290869=(function(){function _0x1ce285(_0x3e1b81,_0x2ab781){var _0x23309c=this;if(void 0x0===_0x2ab781&&(_0x2ab781=_0x3b39f6['GetDefaults']()),this['_options']=_0x2ab781,this['_canvas']=null,this['xrLayer']=null,this['onXRLayerInitObservable']=new _0x6ac1f7['c'](),this['_engine']=_0x3e1b81['scene']['getEngine'](),_0x2ab781['canvasElement'])this['_setManagedOutputCanvas'](_0x2ab781['canvasElement']);else{var _0x430bc0=document['createElement']('canvas');_0x430bc0['style']['cssText']=this['_options']['newCanvasCssStyle']||'position:absolute;\x20bottom:0px;right:0px;',this['_setManagedOutputCanvas'](_0x430bc0);}_0x3e1b81['onXRSessionInit']['add'](function(){_0x23309c['_addCanvas']();}),_0x3e1b81['onXRSessionEnded']['add'](function(){_0x23309c['_removeCanvas']();});}return _0x1ce285['prototype']['dispose']=function(){this['_removeCanvas'](),this['_setManagedOutputCanvas'](null);},_0x1ce285['prototype']['initializeXRLayerAsync']=function(_0xb1d11f){var _0x8be819=this,_0x501575=function(){var _0x15aa61=new XRWebGLLayer(_0xb1d11f,_0x8be819['canvasContext'],_0x8be819['_options']['canvasOptions']);return _0x8be819['onXRLayerInitObservable']['notifyObservers'](_0x15aa61),_0x15aa61;};return this['canvasContext']['makeXRCompatible']?this['canvasContext']['makeXRCompatible']()['then'](function(){return _0x8be819['xrLayer']=_0x501575(),_0x8be819['xrLayer'];}):(this['xrLayer']=_0x501575(),Promise['resolve'](this['xrLayer']));},_0x1ce285['prototype']['_addCanvas']=function(){var _0x4e59b3=this;this['_canvas']&&this['_canvas']!==this['_engine']['getRenderingCanvas']()&&document['body']['appendChild'](this['_canvas']),this['xrLayer']?this['_setCanvasSize'](!0x0):this['onXRLayerInitObservable']['addOnce'](function(_0x1a6b19){_0x4e59b3['_setCanvasSize'](!0x0,_0x1a6b19);});},_0x1ce285['prototype']['_removeCanvas']=function(){this['_canvas']&&document['body']['contains'](this['_canvas'])&&this['_canvas']!==this['_engine']['getRenderingCanvas']()&&document['body']['removeChild'](this['_canvas']),this['_setCanvasSize'](!0x1);},_0x1ce285['prototype']['_setCanvasSize']=function(_0x46ecae,_0x479a6b){void 0x0===_0x46ecae&&(_0x46ecae=!0x0),void 0x0===_0x479a6b&&(_0x479a6b=this['xrLayer']),this['_canvas']&&(_0x46ecae?_0x479a6b&&(this['_canvas']!==this['_engine']['getRenderingCanvas']()?(this['_canvas']['style']['width']=_0x479a6b['framebufferWidth']+'px',this['_canvas']['style']['height']=_0x479a6b['framebufferHeight']+'px'):this['_engine']['setSize'](_0x479a6b['framebufferWidth'],_0x479a6b['framebufferHeight'])):this['_originalCanvasSize']&&(this['_canvas']!==this['_engine']['getRenderingCanvas']()?(this['_canvas']['style']['width']=this['_originalCanvasSize']['width']+'px',this['_canvas']['style']['height']=this['_originalCanvasSize']['height']+'px'):this['_engine']['setSize'](this['_originalCanvasSize']['width'],this['_originalCanvasSize']['height'])));},_0x1ce285['prototype']['_setManagedOutputCanvas']=function(_0x166a9d){this['_removeCanvas'](),_0x166a9d?(this['_originalCanvasSize']={'width':_0x166a9d['offsetWidth'],'height':_0x166a9d['offsetHeight']},this['_canvas']=_0x166a9d,this['canvasContext']=this['_canvas']['getContext']('webgl2'),this['canvasContext']||(this['canvasContext']=this['_canvas']['getContext']('webgl'))):(this['_canvas']=null,this['canvasContext']=null);},_0x1ce285;}()),_0x31ca49=(function(){function _0xc2b23f(_0xce9de2){this['scene']=_0xce9de2,this['_sessionEnded']=!0x1,this['baseLayer']=null,this['currentTimestamp']=-0x1,this['defaultHeightCompensation']=1.7,this['onXRFrameObservable']=new _0x6ac1f7['c'](),this['onXRReferenceSpaceChanged']=new _0x6ac1f7['c'](),this['onXRSessionEnded']=new _0x6ac1f7['c'](),this['onXRSessionInit']=new _0x6ac1f7['c']();}return Object['defineProperty'](_0xc2b23f['prototype'],'referenceSpace',{'get':function(){return this['_referenceSpace'];},'set':function(_0x21f1bb){this['_referenceSpace']=_0x21f1bb,this['onXRReferenceSpaceChanged']['notifyObservers'](this['_referenceSpace']);},'enumerable':!0x1,'configurable':!0x0}),_0xc2b23f['prototype']['dispose']=function(){this['_sessionEnded']||this['exitXRAsync'](),this['onXRFrameObservable']['clear'](),this['onXRSessionEnded']['clear'](),this['onXRReferenceSpaceChanged']['clear'](),this['onXRSessionInit']['clear']();},_0xc2b23f['prototype']['exitXRAsync']=function(){return this['session']&&!this['_sessionEnded']?(this['_sessionEnded']=!0x0,this['session']['end']()['catch'](function(_0x345b56){_0x75193d['a']['Warn']('Could\x20not\x20end\x20XR\x20session.');})):Promise['resolve']();},_0xc2b23f['prototype']['getRenderTargetTextureForEye']=function(_0x396308){return this['_rttProvider']['getRenderTargetForEye'](_0x396308);},_0xc2b23f['prototype']['getWebXRRenderTarget']=function(_0x3b78b5){var _0x48f6f0=this['scene']['getEngine']();return this['_xrNavigator']['xr']['native']?this['_xrNavigator']['xr']['getWebXRRenderTarget'](_0x48f6f0):((_0x3b78b5=_0x3b78b5||_0x3b39f6['GetDefaults'](_0x48f6f0))['canvasElement']=_0x48f6f0['getRenderingCanvas']()||void 0x0,new _0x290869(this,_0x3b78b5));},_0xc2b23f['prototype']['initializeAsync']=function(){return this['_xrNavigator']=navigator,this['_xrNavigator']['xr']?Promise['resolve']():Promise['reject']('WebXR\x20not\x20available');},_0xc2b23f['prototype']['initializeSessionAsync']=function(_0x5d7787,_0x25ac19){var _0x283b7e=this;return void 0x0===_0x5d7787&&(_0x5d7787='immersive-vr'),void 0x0===_0x25ac19&&(_0x25ac19={}),this['_xrNavigator']['xr']['requestSession'](_0x5d7787,_0x25ac19)['then'](function(_0x245466){return _0x283b7e['session']=_0x245466,_0x283b7e['onXRSessionInit']['notifyObservers'](_0x245466),_0x283b7e['_sessionEnded']=!0x1,_0x283b7e['session']['addEventListener']('end',function(){var _0x555cad=_0x283b7e['scene']['getEngine']();_0x283b7e['_sessionEnded']=!0x0,_0x283b7e['_rttProvider']=null,_0x555cad['framebufferDimensionsObject']=null,_0x555cad['restoreDefaultFramebuffer'](),_0x555cad['customAnimationFrameRequester']=null,_0x283b7e['onXRSessionEnded']['notifyObservers'](null),_0x555cad['_renderLoop']();},{'once':!0x0}),_0x283b7e['session'];});},_0xc2b23f['prototype']['isSessionSupportedAsync']=function(_0x692cc6){return _0xc2b23f['IsSessionSupportedAsync'](_0x692cc6);},_0xc2b23f['prototype']['resetReferenceSpace']=function(){this['referenceSpace']=this['baseReferenceSpace'];},_0xc2b23f['prototype']['runXRRenderLoop']=function(){var _0x4d75ab=this,_0x4d4561=this['scene']['getEngine']();if(_0x4d4561['customAnimationFrameRequester']={'requestAnimationFrame':this['session']['requestAnimationFrame']['bind'](this['session']),'renderFunction':function(_0x2e9659,_0x41ec03){_0x4d75ab['_sessionEnded']||(_0x4d75ab['currentFrame']=_0x41ec03,_0x4d75ab['currentTimestamp']=_0x2e9659,_0x41ec03&&(_0x4d4561['framebufferDimensionsObject']=_0x4d75ab['baseLayer'],_0x4d75ab['onXRFrameObservable']['notifyObservers'](_0x41ec03),_0x4d4561['_renderLoop'](),_0x4d4561['framebufferDimensionsObject']=null));}},this['_xrNavigator']['xr']['native'])this['_rttProvider']=this['_xrNavigator']['xr']['getNativeRenderTargetProvider'](this['session'],this['_createRenderTargetTexture']['bind'](this));else{var _0x2476e9=this['_createRenderTargetTexture'](this['baseLayer']['framebufferWidth'],this['baseLayer']['framebufferHeight'],this['baseLayer']['framebuffer']);this['_rttProvider']={'getRenderTargetForEye':function(){return _0x2476e9;}},_0x4d4561['framebufferDimensionsObject']=this['baseLayer'];}'undefined'!=typeof window&&window['cancelAnimationFrame']&&window['cancelAnimationFrame'](_0x4d4561['_frameHandler']),_0x4d4561['_renderLoop']();},_0xc2b23f['prototype']['setReferenceSpaceTypeAsync']=function(_0x3960a9){var _0x46ce14=this;return void 0x0===_0x3960a9&&(_0x3960a9='local-floor'),this['session']['requestReferenceSpace'](_0x3960a9)['then'](function(_0xa212f1){return _0xa212f1;},function(_0xc3814d){return _0x75193d['a']['Error']('XR.requestReferenceSpace\x20failed\x20for\x20the\x20following\x20reason:\x20'),_0x75193d['a']['Error'](_0xc3814d),_0x75193d['a']['Log']('Defaulting\x20to\x20universally-supported\x20\x22viewer\x22\x20reference\x20space\x20type.'),_0x46ce14['session']['requestReferenceSpace']('viewer')['then'](function(_0x1f932e){var _0x8f8c46=new XRRigidTransform({'x':0x0,'y':-_0x46ce14['defaultHeightCompensation'],'z':0x0});return _0x1f932e['getOffsetReferenceSpace'](_0x8f8c46);},function(_0x5cef09){throw _0x75193d['a']['Error'](_0x5cef09),'XR\x20initialization\x20failed:\x20required\x20\x22viewer\x22\x20reference\x20space\x20type\x20not\x20supported.';});})['then'](function(_0x5f0a6f){return _0x46ce14['session']['requestReferenceSpace']('viewer')['then'](function(_0x3c4852){return _0x46ce14['viewerReferenceSpace']=_0x3c4852,_0x5f0a6f;});})['then'](function(_0x3ce676){return _0x46ce14['referenceSpace']=_0x46ce14['baseReferenceSpace']=_0x3ce676,_0x46ce14['referenceSpace'];});},_0xc2b23f['prototype']['updateRenderStateAsync']=function(_0x37dc94){return _0x37dc94['baseLayer']&&(this['baseLayer']=_0x37dc94['baseLayer']),this['session']['updateRenderState'](_0x37dc94);},_0xc2b23f['IsSessionSupportedAsync']=function(_0x418c40){if(!navigator['xr'])return Promise['resolve'](!0x1);var _0x5a8daf=navigator['xr']['isSessionSupported']||navigator['xr']['supportsSession'];return _0x5a8daf?_0x5a8daf['call'](navigator['xr'],_0x418c40)['then'](function(_0x492b96){var _0x16a5ab=void 0x0===_0x492b96||_0x492b96;return Promise['resolve'](_0x16a5ab);})['catch'](function(_0x2c1b60){return _0x75193d['a']['Warn'](_0x2c1b60),Promise['resolve'](!0x1);}):Promise['resolve'](!0x1);},_0xc2b23f['prototype']['_createRenderTargetTexture']=function(_0x48da30,_0x4cfcee,_0x3847d1){void 0x0===_0x3847d1&&(_0x3847d1=null);var _0x4b5dd8=new _0x21ea74['a'](this['scene']['getEngine'](),_0x21ea74['b']['Unknown'],!0x0);_0x4b5dd8['width']=_0x48da30,_0x4b5dd8['height']=_0x4cfcee,_0x4b5dd8['_framebuffer']=_0x3847d1;var _0x4af30a=new _0x310f87('XR\x20renderTargetTexture',{'width':_0x48da30,'height':_0x4cfcee},this['scene'],void 0x0,void 0x0,void 0x0,void 0x0,void 0x0,void 0x0,void 0x0,void 0x0,void 0x0,!0x0);return _0x4af30a['_texture']=_0x4b5dd8,_0x4af30a;},_0xc2b23f;}());!function(_0x17370c){_0x17370c[_0x17370c['ENTERING_XR']=0x0]='ENTERING_XR',_0x17370c[_0x17370c['EXITING_XR']=0x1]='EXITING_XR',_0x17370c[_0x17370c['IN_XR']=0x2]='IN_XR',_0x17370c[_0x17370c['NOT_IN_XR']=0x3]='NOT_IN_XR';}(_0xada4aa||(_0xada4aa={})),function(_0x5cdf65){_0x5cdf65[_0x5cdf65['NOT_TRACKING']=0x0]='NOT_TRACKING',_0x5cdf65[_0x5cdf65['TRACKING_LOST']=0x1]='TRACKING_LOST',_0x5cdf65[_0x5cdf65['TRACKING']=0x2]='TRACKING';}(_0x49ab50||(_0x49ab50={}));var _0x2cb8bd,_0x2b3833=(function(){function _0xeaf0c(_0x2635f0,_0x233ceb){if(void 0x0===_0x233ceb&&(_0x233ceb=null),this['scene']=_0x2635f0,this['_pointerDownOnMeshAsked']=!0x1,this['_isActionableMesh']=!0x1,this['_teleportationRequestInitiated']=!0x1,this['_teleportationBackRequestInitiated']=!0x1,this['_rotationRightAsked']=!0x1,this['_rotationLeftAsked']=!0x1,this['_dpadPressed']=!0x0,this['_activePointer']=!0x1,this['_id']=_0xeaf0c['_idCounter']++,_0x233ceb)this['_gazeTracker']=_0x233ceb['clone']('gazeTracker');else{this['_gazeTracker']=_0x3cf5e5['a']['CreateTorus']('gazeTracker',0.0035,0.0025,0x14,_0x2635f0,!0x1),this['_gazeTracker']['bakeCurrentTransformIntoVertices'](),this['_gazeTracker']['isPickable']=!0x1,this['_gazeTracker']['isVisible']=!0x1;var _0xd23c21=new _0x5905ab['a']('targetMat',_0x2635f0);_0xd23c21['specularColor']=_0x39310d['a']['Black'](),_0xd23c21['emissiveColor']=new _0x39310d['a'](0.7,0.7,0.7),_0xd23c21['backFaceCulling']=!0x1,this['_gazeTracker']['material']=_0xd23c21;}}return _0xeaf0c['prototype']['_getForwardRay']=function(_0x422ec1){return new _0x36fb4d['a'](_0x74d525['e']['Zero'](),new _0x74d525['e'](0x0,0x0,_0x422ec1));},_0xeaf0c['prototype']['_selectionPointerDown']=function(){this['_pointerDownOnMeshAsked']=!0x0,this['_currentHit']&&this['scene']['simulatePointerDown'](this['_currentHit'],{'pointerId':this['_id']});},_0xeaf0c['prototype']['_selectionPointerUp']=function(){this['_currentHit']&&this['scene']['simulatePointerUp'](this['_currentHit'],{'pointerId':this['_id']}),this['_pointerDownOnMeshAsked']=!0x1;},_0xeaf0c['prototype']['_activatePointer']=function(){this['_activePointer']=!0x0;},_0xeaf0c['prototype']['_deactivatePointer']=function(){this['_activePointer']=!0x1;},_0xeaf0c['prototype']['_updatePointerDistance']=function(_0x945af2){void 0x0===_0x945af2&&(_0x945af2=0x64);},_0xeaf0c['prototype']['dispose']=function(){this['_interactionsEnabled']=!0x1,this['_teleportationEnabled']=!0x1,this['_gazeTracker']&&this['_gazeTracker']['dispose']();},_0xeaf0c['_idCounter']=0x0,_0xeaf0c;}()),_0xda7418=function(_0x555fc5){function _0x3ff987(_0x358bdb,_0x11588b,_0x2870c9){var _0x26f515=_0x555fc5['call'](this,_0x11588b,_0x2870c9)||this;_0x26f515['webVRController']=_0x358bdb,_0x26f515['_laserPointer']=_0x3cf5e5['a']['CreateCylinder']('laserPointer',0x1,0.004,0.0002,0x14,0x1,_0x11588b,!0x1);var _0x2cc6d3=new _0x5905ab['a']('laserPointerMat',_0x11588b);if(_0x2cc6d3['emissiveColor']=new _0x39310d['a'](0.7,0.7,0.7),_0x2cc6d3['alpha']=0.6,_0x26f515['_laserPointer']['material']=_0x2cc6d3,_0x26f515['_laserPointer']['rotation']['x']=Math['PI']/0x2,_0x26f515['_laserPointer']['position']['z']=-0.5,_0x26f515['_laserPointer']['isVisible']=!0x1,_0x26f515['_laserPointer']['isPickable']=!0x1,!_0x358bdb['mesh']){var _0x573871=new _0x3cf5e5['a']('preloadControllerMesh',_0x11588b),_0x30fd30=new _0x3cf5e5['a'](_0x3c2ea8['POINTING_POSE'],_0x11588b);_0x30fd30['rotation']['x']=-0.7,_0x573871['addChild'](_0x30fd30),_0x358bdb['attachToMesh'](_0x573871);}return _0x26f515['_setLaserPointerParent'](_0x358bdb['mesh']),_0x26f515['_meshAttachedObserver']=_0x358bdb['_meshAttachedObservable']['add'](function(_0x4960af){_0x26f515['_setLaserPointerParent'](_0x4960af);}),_0x26f515;}return Object(_0x18e13d['d'])(_0x3ff987,_0x555fc5),_0x3ff987['prototype']['_getForwardRay']=function(_0x2e1865){return this['webVRController']['getForwardRay'](_0x2e1865);},_0x3ff987['prototype']['_activatePointer']=function(){_0x555fc5['prototype']['_activatePointer']['call'](this),this['_laserPointer']['isVisible']=!0x0;},_0x3ff987['prototype']['_deactivatePointer']=function(){_0x555fc5['prototype']['_deactivatePointer']['call'](this),this['_laserPointer']['isVisible']=!0x1;},_0x3ff987['prototype']['_setLaserPointerColor']=function(_0x4d59da){this['_laserPointer']['material']['emissiveColor']=_0x4d59da;},_0x3ff987['prototype']['_setLaserPointerLightingDisabled']=function(_0x58a6c6){this['_laserPointer']['material']['disableLighting']=_0x58a6c6;},_0x3ff987['prototype']['_setLaserPointerParent']=function(_0x1a0062){var _0x3f818a=function(_0x15ab02){_0x15ab02['isPickable']=!0x1,_0x15ab02['getChildMeshes']()['forEach'](function(_0x2c02bb){_0x3f818a(_0x2c02bb);});};_0x3f818a(_0x1a0062);var _0xf31764=_0x1a0062['getChildren'](void 0x0,!0x1),_0x5b138d=_0x1a0062;this['webVRController']['_pointingPoseNode']=null;for(var _0x3d4476=0x0;_0x3d4476<_0xf31764['length'];_0x3d4476++)if(_0xf31764[_0x3d4476]['name']&&_0xf31764[_0x3d4476]['name']['indexOf'](_0x3c2ea8['POINTING_POSE'])>=0x0){_0x5b138d=_0xf31764[_0x3d4476],this['webVRController']['_pointingPoseNode']=_0x5b138d;break;}this['_laserPointer']['parent']=_0x5b138d;},_0x3ff987['prototype']['_updatePointerDistance']=function(_0x9d7811){void 0x0===_0x9d7811&&(_0x9d7811=0x64),this['_laserPointer']['scaling']['y']=_0x9d7811,this['_laserPointer']['position']['z']=-_0x9d7811/0x2;},_0x3ff987['prototype']['dispose']=function(){_0x555fc5['prototype']['dispose']['call'](this),this['_laserPointer']['dispose'](),this['_meshAttachedObserver']&&this['webVRController']['_meshAttachedObservable']['remove'](this['_meshAttachedObserver']);},_0x3ff987;}(_0x2b3833),_0x599e9e=function(_0x24c821){function _0x4a32f7(_0x119b57,_0x4b8ec5){var _0x2dea85=_0x24c821['call'](this,_0x4b8ec5)||this;return _0x2dea85['getCamera']=_0x119b57,_0x2dea85;}return Object(_0x18e13d['d'])(_0x4a32f7,_0x24c821),_0x4a32f7['prototype']['_getForwardRay']=function(_0x3ec092){var _0xb41756=this['getCamera']();return _0xb41756?_0xb41756['getForwardRay'](_0x3ec092):new _0x36fb4d['a'](_0x74d525['e']['Zero'](),_0x74d525['e']['Forward']());},_0x4a32f7;}(_0x2b3833),_0x23547a=function(){},_0x17f3dd=(function(){function _0x25297c(_0x2f7b6d,_0x5992d9){var _0x1dbfab=this;if(void 0x0===_0x5992d9&&(_0x5992d9={}),this['webVROptions']=_0x5992d9,this['_webVRsupported']=!0x1,this['_webVRready']=!0x1,this['_webVRrequesting']=!0x1,this['_webVRpresenting']=!0x1,this['_fullscreenVRpresenting']=!0x1,this['enableGazeEvenWhenNoPointerLock']=!0x1,this['exitVROnDoubleTap']=!0x0,this['onEnteringVRObservable']=new _0x6ac1f7['c'](),this['onAfterEnteringVRObservable']=new _0x6ac1f7['c'](),this['onExitingVRObservable']=new _0x6ac1f7['c'](),this['onControllerMeshLoadedObservable']=new _0x6ac1f7['c'](),this['_useCustomVRButton']=!0x1,this['_teleportationRequested']=!0x1,this['_teleportActive']=!0x1,this['_floorMeshesCollection']=[],this['_teleportationMode']=_0x25297c['TELEPORTATIONMODE_CONSTANTTIME'],this['_teleportationTime']=0x7a,this['_teleportationSpeed']=0x14,this['_rotationAllowed']=!0x0,this['_teleportBackwardsVector']=new _0x74d525['e'](0x0,-0x1,-0x1),this['_isDefaultTeleportationTarget']=!0x0,this['_teleportationFillColor']='#444444',this['_teleportationBorderColor']='#FFFFFF',this['_rotationAngle']=0x0,this['_haloCenter']=new _0x74d525['e'](0x0,0x0,0x0),this['_padSensibilityUp']=0.65,this['_padSensibilityDown']=0.35,this['_leftController']=null,this['_rightController']=null,this['_gazeColor']=new _0x39310d['a'](0.7,0.7,0.7),this['_laserColor']=new _0x39310d['a'](0.7,0.7,0.7),this['_pickedLaserColor']=new _0x39310d['a'](0.2,0.2,0x1),this['_pickedGazeColor']=new _0x39310d['a'](0x0,0x0,0x1),this['onNewMeshSelected']=new _0x6ac1f7['c'](),this['onMeshSelectedWithController']=new _0x6ac1f7['c'](),this['onNewMeshPicked']=new _0x6ac1f7['c'](),this['onBeforeCameraTeleport']=new _0x6ac1f7['c'](),this['onAfterCameraTeleport']=new _0x6ac1f7['c'](),this['onSelectedMeshUnselected']=new _0x6ac1f7['c'](),this['teleportationEnabled']=!0x0,this['_teleportationInitialized']=!0x1,this['_interactionsEnabled']=!0x1,this['_interactionsRequested']=!0x1,this['_displayGaze']=!0x0,this['_displayLaserPointer']=!0x0,this['updateGazeTrackerScale']=!0x0,this['updateGazeTrackerColor']=!0x0,this['updateControllerLaserColor']=!0x0,this['requestPointerLockOnFullScreen']=!0x0,this['xrTestDone']=!0x1,this['_onResize']=function(){_0x1dbfab['moveButtonToBottomRight'](),_0x1dbfab['_fullscreenVRpresenting']&&_0x1dbfab['_webVRready']&&_0x1dbfab['exitVR']();},this['_onFullscreenChange']=function(){var _0x1f3509=document;void 0x0!==_0x1f3509['fullscreen']?_0x1dbfab['_fullscreenVRpresenting']=document['fullscreen']:void 0x0!==_0x1f3509['mozFullScreen']?_0x1dbfab['_fullscreenVRpresenting']=_0x1f3509['mozFullScreen']:void 0x0!==_0x1f3509['webkitIsFullScreen']?_0x1dbfab['_fullscreenVRpresenting']=_0x1f3509['webkitIsFullScreen']:void 0x0!==_0x1f3509['msIsFullScreen']?_0x1dbfab['_fullscreenVRpresenting']=_0x1f3509['msIsFullScreen']:void 0x0!==document['msFullscreenElement']&&(_0x1dbfab['_fullscreenVRpresenting']=document['msFullscreenElement']),!_0x1dbfab['_fullscreenVRpresenting']&&_0x1dbfab['_inputElement']&&(_0x1dbfab['exitVR'](),!_0x1dbfab['_useCustomVRButton']&&_0x1dbfab['_btnVR']&&(_0x1dbfab['_btnVR']['style']['top']=_0x1dbfab['_inputElement']['offsetTop']+_0x1dbfab['_inputElement']['offsetHeight']-0x46+'px',_0x1dbfab['_btnVR']['style']['left']=_0x1dbfab['_inputElement']['offsetLeft']+_0x1dbfab['_inputElement']['offsetWidth']-0x64+'px',_0x1dbfab['updateButtonVisibility']()));},this['_cachedAngularSensibility']={'angularSensibilityX':null,'angularSensibilityY':null,'angularSensibility':null},this['beforeRender']=function(){_0x1dbfab['_leftController']&&_0x1dbfab['_leftController']['_activePointer']&&_0x1dbfab['_castRayAndSelectObject'](_0x1dbfab['_leftController']),_0x1dbfab['_rightController']&&_0x1dbfab['_rightController']['_activePointer']&&_0x1dbfab['_castRayAndSelectObject'](_0x1dbfab['_rightController']),_0x1dbfab['_noControllerIsActive']&&(_0x1dbfab['_scene']['getEngine']()['isPointerLock']||_0x1dbfab['enableGazeEvenWhenNoPointerLock'])?_0x1dbfab['_castRayAndSelectObject'](_0x1dbfab['_cameraGazer']):_0x1dbfab['_cameraGazer']['_gazeTracker']['isVisible']=!0x1;},this['_onNewGamepadConnected']=function(_0x24d5ee){if(_0x24d5ee['type']!==_0x56ffd0['POSE_ENABLED'])_0x24d5ee['leftStick']&&_0x24d5ee['onleftstickchanged'](function(_0x4db344){_0x1dbfab['_teleportationInitialized']&&_0x1dbfab['teleportationEnabled']&&(!_0x1dbfab['_leftController']&&!_0x1dbfab['_rightController']||_0x1dbfab['_leftController']&&!_0x1dbfab['_leftController']['_activePointer']&&_0x1dbfab['_rightController']&&!_0x1dbfab['_rightController']['_activePointer'])&&(_0x1dbfab['_checkTeleportWithRay'](_0x4db344,_0x1dbfab['_cameraGazer']),_0x1dbfab['_checkTeleportBackwards'](_0x4db344,_0x1dbfab['_cameraGazer']));}),_0x24d5ee['rightStick']&&_0x24d5ee['onrightstickchanged'](function(_0x69379b){_0x1dbfab['_teleportationInitialized']&&_0x1dbfab['_checkRotate'](_0x69379b,_0x1dbfab['_cameraGazer']);}),_0x24d5ee['type']===_0x56ffd0['XBOX']&&(_0x24d5ee['onbuttondown'](function(_0x14f1ae){_0x1dbfab['_interactionsEnabled']&&_0x14f1ae===_0x40fdb4['A']&&_0x1dbfab['_cameraGazer']['_selectionPointerDown']();}),_0x24d5ee['onbuttonup'](function(_0x12ea24){_0x1dbfab['_interactionsEnabled']&&_0x12ea24===_0x40fdb4['A']&&_0x1dbfab['_cameraGazer']['_selectionPointerUp']();}));else{var _0x270059=_0x24d5ee,_0x3711f8=new _0xda7418(_0x270059,_0x1dbfab['_scene'],_0x1dbfab['_cameraGazer']['_gazeTracker']);'right'===_0x270059['hand']||_0x1dbfab['_leftController']&&_0x1dbfab['_leftController']['webVRController']!=_0x270059?_0x1dbfab['_rightController']=_0x3711f8:_0x1dbfab['_leftController']=_0x3711f8,_0x1dbfab['_tryEnableInteractionOnController'](_0x3711f8);}},this['_tryEnableInteractionOnController']=function(_0x1f1ebc){_0x1dbfab['_interactionsRequested']&&!_0x1f1ebc['_interactionsEnabled']&&_0x1dbfab['_enableInteractionOnController'](_0x1f1ebc),_0x1dbfab['_teleportationRequested']&&!_0x1f1ebc['_teleportationEnabled']&&_0x1dbfab['_enableTeleportationOnController'](_0x1f1ebc);},this['_onNewGamepadDisconnected']=function(_0x21fdf9){_0x21fdf9 instanceof _0x5dfec2&&('left'===_0x21fdf9['hand']&&null!=_0x1dbfab['_leftController']&&(_0x1dbfab['_leftController']['dispose'](),_0x1dbfab['_leftController']=null),'right'===_0x21fdf9['hand']&&null!=_0x1dbfab['_rightController']&&(_0x1dbfab['_rightController']['dispose'](),_0x1dbfab['_rightController']=null));},this['_workingVector']=_0x74d525['e']['Zero'](),this['_workingQuaternion']=_0x74d525['b']['Identity'](),this['_workingMatrix']=_0x74d525['a']['Identity'](),this['_scene']=_0x2f7b6d,this['_inputElement']=_0x2f7b6d['getEngine']()['getInputElement'](),'getVRDisplays'in navigator||(_0x5992d9['useXR']=!0x0),void 0x0===_0x5992d9['createFallbackVRDeviceOrientationFreeCamera']&&(_0x5992d9['createFallbackVRDeviceOrientationFreeCamera']=!0x0),void 0x0===_0x5992d9['createDeviceOrientationCamera']&&(_0x5992d9['createDeviceOrientationCamera']=!0x0),void 0x0===_0x5992d9['laserToggle']&&(_0x5992d9['laserToggle']=!0x0),void 0x0===_0x5992d9['defaultHeight']&&(_0x5992d9['defaultHeight']=1.7),_0x5992d9['useCustomVRButton']&&(this['_useCustomVRButton']=!0x0,_0x5992d9['customVRButton']&&(this['_btnVR']=_0x5992d9['customVRButton'])),_0x5992d9['rayLength']&&(this['_rayLength']=_0x5992d9['rayLength']),this['_defaultHeight']=_0x5992d9['defaultHeight'],_0x5992d9['positionScale']&&(this['_rayLength']*=_0x5992d9['positionScale'],this['_defaultHeight']*=_0x5992d9['positionScale']),this['_hasEnteredVR']=!0x1,this['_scene']['activeCamera']?this['_position']=this['_scene']['activeCamera']['position']['clone']():this['_position']=new _0x74d525['e'](0x0,this['_defaultHeight'],0x0),_0x5992d9['createDeviceOrientationCamera']||!this['_scene']['activeCamera']){if(this['_deviceOrientationCamera']=new _0x2de943('deviceOrientationVRHelper',this['_position']['clone'](),_0x2f7b6d),this['_scene']['activeCamera']&&(this['_deviceOrientationCamera']['minZ']=this['_scene']['activeCamera']['minZ'],this['_deviceOrientationCamera']['maxZ']=this['_scene']['activeCamera']['maxZ'],this['_scene']['activeCamera']instanceof _0x5f32ae&&this['_scene']['activeCamera']['rotation'])){var _0x2524d0=this['_scene']['activeCamera'];_0x2524d0['rotationQuaternion']?this['_deviceOrientationCamera']['rotationQuaternion']['copyFrom'](_0x2524d0['rotationQuaternion']):this['_deviceOrientationCamera']['rotationQuaternion']['copyFrom'](_0x74d525['b']['RotationYawPitchRoll'](_0x2524d0['rotation']['y'],_0x2524d0['rotation']['x'],_0x2524d0['rotation']['z'])),this['_deviceOrientationCamera']['rotation']=_0x2524d0['rotation']['clone']();}this['_scene']['activeCamera']=this['_deviceOrientationCamera'],this['_inputElement']&&this['_scene']['activeCamera']['attachControl']();}else this['_existingCamera']=this['_scene']['activeCamera'];this['webVROptions']['useXR']&&navigator['xr']?_0x31ca49['IsSessionSupportedAsync']('immersive-vr')['then'](function(_0x590e55){_0x590e55?(_0x75193d['a']['Log']('Using\x20WebXR.\x20It\x20is\x20recommended\x20to\x20use\x20the\x20WebXRDefaultExperience\x20directly'),_0x2f7b6d['createDefaultXRExperienceAsync']({'floorMeshes':_0x5992d9['floorMeshes']||[]})['then'](function(_0x5aaa91){_0x1dbfab['xr']=_0x5aaa91,_0x1dbfab['xrTestDone']=!0x0,_0x1dbfab['_cameraGazer']=new _0x599e9e(function(){return _0x1dbfab['xr']['baseExperience']['camera'];},_0x2f7b6d),_0x1dbfab['xr']['baseExperience']['onStateChangedObservable']['add'](function(_0x3c7afa){switch(_0x3c7afa){case _0xada4aa['ENTERING_XR']:_0x1dbfab['onEnteringVRObservable']['notifyObservers'](_0x1dbfab),_0x1dbfab['_interactionsEnabled']||_0x1dbfab['xr']['pointerSelection']['detach'](),_0x1dbfab['xr']['pointerSelection']['displayLaserPointer']=_0x1dbfab['_displayLaserPointer'];break;case _0xada4aa['EXITING_XR']:_0x1dbfab['onExitingVRObservable']['notifyObservers'](_0x1dbfab),_0x1dbfab['_scene']['getEngine']()['resize']();break;case _0xada4aa['IN_XR']:_0x1dbfab['_hasEnteredVR']=!0x0;break;case _0xada4aa['NOT_IN_XR']:_0x1dbfab['_hasEnteredVR']=!0x1;}});})):_0x1dbfab['completeVRInit'](_0x2f7b6d,_0x5992d9);}):this['completeVRInit'](_0x2f7b6d,_0x5992d9);}return Object['defineProperty'](_0x25297c['prototype'],'onEnteringVR',{'get':function(){return this['onEnteringVRObservable'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x25297c['prototype'],'onExitingVR',{'get':function(){return this['onExitingVRObservable'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x25297c['prototype'],'onControllerMeshLoaded',{'get':function(){return this['onControllerMeshLoadedObservable'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x25297c['prototype'],'teleportationTarget',{'get':function(){return this['_teleportationTarget'];},'set':function(_0x151eaa){_0x151eaa&&(_0x151eaa['name']='teleportationTarget',this['_isDefaultTeleportationTarget']=!0x1,this['_teleportationTarget']=_0x151eaa);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x25297c['prototype'],'gazeTrackerMesh',{'get':function(){return this['_cameraGazer']['_gazeTracker'];},'set':function(_0x1ed9d5){_0x1ed9d5&&(this['_cameraGazer']['_gazeTracker']&&this['_cameraGazer']['_gazeTracker']['dispose'](),this['_leftController']&&this['_leftController']['_gazeTracker']&&this['_leftController']['_gazeTracker']['dispose'](),this['_rightController']&&this['_rightController']['_gazeTracker']&&this['_rightController']['_gazeTracker']['dispose'](),this['_cameraGazer']['_gazeTracker']=_0x1ed9d5,this['_cameraGazer']['_gazeTracker']['bakeCurrentTransformIntoVertices'](),this['_cameraGazer']['_gazeTracker']['isPickable']=!0x1,this['_cameraGazer']['_gazeTracker']['isVisible']=!0x1,this['_cameraGazer']['_gazeTracker']['name']='gazeTracker',this['_leftController']&&(this['_leftController']['_gazeTracker']=this['_cameraGazer']['_gazeTracker']['clone']('gazeTracker')),this['_rightController']&&(this['_rightController']['_gazeTracker']=this['_cameraGazer']['_gazeTracker']['clone']('gazeTracker')));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x25297c['prototype'],'leftControllerGazeTrackerMesh',{'get':function(){return this['_leftController']?this['_leftController']['_gazeTracker']:null;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x25297c['prototype'],'rightControllerGazeTrackerMesh',{'get':function(){return this['_rightController']?this['_rightController']['_gazeTracker']:null;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x25297c['prototype'],'displayGaze',{'get':function(){return this['_displayGaze'];},'set':function(_0x4fdfd1){this['_displayGaze']=_0x4fdfd1,_0x4fdfd1||(this['_cameraGazer']['_gazeTracker']['isVisible']=!0x1,this['_leftController']&&(this['_leftController']['_gazeTracker']['isVisible']=!0x1),this['_rightController']&&(this['_rightController']['_gazeTracker']['isVisible']=!0x1));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x25297c['prototype'],'displayLaserPointer',{'get':function(){return this['_displayLaserPointer'];},'set':function(_0x1cf7ed){this['_displayLaserPointer']=_0x1cf7ed,_0x1cf7ed?(this['_rightController']&&this['_rightController']['_activatePointer'](),this['_leftController']&&this['_leftController']['_activatePointer']()):(this['_rightController']&&(this['_rightController']['_deactivatePointer'](),this['_rightController']['_gazeTracker']['isVisible']=!0x1),this['_leftController']&&(this['_leftController']['_deactivatePointer'](),this['_leftController']['_gazeTracker']['isVisible']=!0x1));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x25297c['prototype'],'deviceOrientationCamera',{'get':function(){return this['_deviceOrientationCamera'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x25297c['prototype'],'currentVRCamera',{'get':function(){return this['_webVRready']?this['_webVRCamera']:this['_scene']['activeCamera'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x25297c['prototype'],'webVRCamera',{'get':function(){return this['_webVRCamera'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x25297c['prototype'],'vrDeviceOrientationCamera',{'get':function(){return this['_vrDeviceOrientationCamera'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x25297c['prototype'],'vrButton',{'get':function(){return this['_btnVR'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x25297c['prototype'],'_teleportationRequestInitiated',{'get':function(){return this['_cameraGazer']['_teleportationRequestInitiated']||null!==this['_leftController']&&this['_leftController']['_teleportationRequestInitiated']||null!==this['_rightController']&&this['_rightController']['_teleportationRequestInitiated'];},'enumerable':!0x1,'configurable':!0x0}),_0x25297c['prototype']['completeVRInit']=function(_0x591ee9,_0x246583){var _0x33559f=this;if(this['xrTestDone']=!0x0,_0x246583['createFallbackVRDeviceOrientationFreeCamera']&&(_0x246583['useMultiview']&&(_0x246583['vrDeviceOrientationCameraMetrics']||(_0x246583['vrDeviceOrientationCameraMetrics']=_0x521280['GetDefault']()),_0x246583['vrDeviceOrientationCameraMetrics']['multiviewEnabled']=!0x0),this['_vrDeviceOrientationCamera']=new _0x4fea40('VRDeviceOrientationVRHelper',this['_position'],this['_scene'],!0x0,_0x246583['vrDeviceOrientationCameraMetrics']),this['_vrDeviceOrientationCamera']['angularSensibility']=Number['MAX_VALUE']),this['_webVRCamera']=new _0x3c14c8('WebVRHelper',this['_position'],this['_scene'],_0x246583),this['_webVRCamera']['useStandingMatrix'](),this['_cameraGazer']=new _0x599e9e(function(){return _0x33559f['currentVRCamera'];},_0x591ee9),!this['_useCustomVRButton']){this['_btnVR']=document['createElement']('BUTTON'),this['_btnVR']['className']='babylonVRicon',this['_btnVR']['id']='babylonVRiconbtn',this['_btnVR']['title']='Click\x20to\x20switch\x20to\x20VR';var _0xa3b994='.babylonVRicon\x20{\x20position:\x20absolute;\x20right:\x2020px;\x20height:\x2050px;\x20width:\x2080px;\x20background-color:\x20rgba(51,51,51,0.7);\x20background-image:\x20url('+(window['SVGSVGElement']?'data:image/svg+xml;charset=UTF-8,%3Csvg%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%20width%3D%222048%22%20height%3D%221152%22%20viewBox%3D%220%200%202048%201152%22%20version%3D%221.1%22%3E%3Cpath%20transform%3D%22rotate%28180%201024%2C576.0000000000001%29%22%20d%3D%22m1109%2C896q17%2C0%2030%2C-12t13%2C-30t-12.5%2C-30.5t-30.5%2C-12.5l-170%2C0q-18%2C0%20-30.5%2C12.5t-12.5%2C30.5t13%2C30t30%2C12l170%2C0zm-85%2C256q59%2C0%20132.5%2C-1.5t154.5%2C-5.5t164.5%2C-11.5t163%2C-20t150%2C-30t124.5%2C-41.5q23%2C-11%2042%2C-24t38%2C-30q27%2C-25%2041%2C-61.5t14%2C-72.5l0%2C-257q0%2C-123%20-47%2C-232t-128%2C-190t-190%2C-128t-232%2C-47l-81%2C0q-37%2C0%20-68.5%2C14t-60.5%2C34.5t-55.5%2C45t-53%2C45t-53%2C34.5t-55.5%2C14t-55.5%2C-14t-53%2C-34.5t-53%2C-45t-55.5%2C-45t-60.5%2C-34.5t-68.5%2C-14l-81%2C0q-123%2C0%20-232%2C47t-190%2C128t-128%2C190t-47%2C232l0%2C257q0%2C68%2038%2C115t97%2C73q54%2C24%20124.5%2C41.5t150%2C30t163%2C20t164.5%2C11.5t154.5%2C5.5t132.5%2C1.5zm939%2C-298q0%2C39%20-24.5%2C67t-58.5%2C42q-54%2C23%20-122%2C39.5t-143.5%2C28t-155.5%2C19t-157%2C11t-148.5%2C5t-129.5%2C1.5q-59%2C0%20-130%2C-1.5t-148%2C-5t-157%2C-11t-155.5%2C-19t-143.5%2C-28t-122%2C-39.5q-34%2C-14%20-58.5%2C-42t-24.5%2C-67l0%2C-257q0%2C-106%2040.5%2C-199t110%2C-162.5t162.5%2C-109.5t199%2C-40l81%2C0q27%2C0%2052%2C14t50%2C34.5t51%2C44.5t55.5%2C44.5t63.5%2C34.5t74%2C14t74%2C-14t63.5%2C-34.5t55.5%2C-44.5t51%2C-44.5t50%2C-34.5t52%2C-14l14%2C0q37%2C0%2070%2C0.5t64.5%2C4.5t63.5%2C12t68%2C23q71%2C30%20128.5%2C78.5t98.5%2C110t63.5%2C133.5t22.5%2C149l0%2C257z%22%20fill%3D%22white%22%20/%3E%3C/svg%3E%0A':'https://cdn.babylonjs.com/Assets/vrButton.png')+');\x20background-size:\x2080%;\x20background-repeat:no-repeat;\x20background-position:\x20center;\x20border:\x20none;\x20outline:\x20none;\x20transition:\x20transform\x200.125s\x20ease-out\x20}\x20.babylonVRicon:hover\x20{\x20transform:\x20scale(1.05)\x20}\x20.babylonVRicon:active\x20{background-color:\x20rgba(51,51,51,1)\x20}\x20.babylonVRicon:focus\x20{background-color:\x20rgba(51,51,51,1)\x20}';_0xa3b994+='.babylonVRicon.vrdisplaypresenting\x20{\x20display:\x20none;\x20}';var _0x32b5fd=document['createElement']('style');_0x32b5fd['appendChild'](document['createTextNode'](_0xa3b994)),document['getElementsByTagName']('head')[0x0]['appendChild'](_0x32b5fd),this['moveButtonToBottomRight']();}this['_btnVR']&&this['_btnVR']['addEventListener']('click',function(){_0x33559f['isInVRMode']?_0x33559f['_scene']['getEngine']()['disableVR']():_0x33559f['enterVR']();});var _0x2d15f4=this['_scene']['getEngine']()['getHostWindow']();_0x2d15f4&&(_0x2d15f4['addEventListener']('resize',this['_onResize']),document['addEventListener']('fullscreenchange',this['_onFullscreenChange'],!0x1),document['addEventListener']('mozfullscreenchange',this['_onFullscreenChange'],!0x1),document['addEventListener']('webkitfullscreenchange',this['_onFullscreenChange'],!0x1),document['addEventListener']('msfullscreenchange',this['_onFullscreenChange'],!0x1),document['onmsfullscreenchange']=this['_onFullscreenChange'],_0x246583['createFallbackVRDeviceOrientationFreeCamera']?this['displayVRButton']():this['_scene']['getEngine']()['onVRDisplayChangedObservable']['add'](function(_0x4815c9){_0x4815c9['vrDisplay']&&_0x33559f['displayVRButton']();}),this['_onKeyDown']=function(_0x462aa6){0x1b===_0x462aa6['keyCode']&&_0x33559f['isInVRMode']&&_0x33559f['exitVR']();},document['addEventListener']('keydown',this['_onKeyDown']),this['_scene']['onPrePointerObservable']['add'](function(){_0x33559f['_hasEnteredVR']&&_0x33559f['exitVROnDoubleTap']&&(_0x33559f['exitVR'](),_0x33559f['_fullscreenVRpresenting']&&_0x33559f['_scene']['getEngine']()['exitFullscreen']());},_0x1cb628['a']['POINTERDOUBLETAP'],!0x1),this['_onVRDisplayChanged']=function(_0x5b44ee){return _0x33559f['onVRDisplayChanged'](_0x5b44ee);},this['_onVrDisplayPresentChange']=function(){return _0x33559f['onVrDisplayPresentChange']();},this['_onVRRequestPresentStart']=function(){_0x33559f['_webVRrequesting']=!0x0,_0x33559f['updateButtonVisibility']();},this['_onVRRequestPresentComplete']=function(){_0x33559f['_webVRrequesting']=!0x1,_0x33559f['updateButtonVisibility']();},_0x591ee9['getEngine']()['onVRDisplayChangedObservable']['add'](this['_onVRDisplayChanged']),_0x591ee9['getEngine']()['onVRRequestPresentStart']['add'](this['_onVRRequestPresentStart']),_0x591ee9['getEngine']()['onVRRequestPresentComplete']['add'](this['_onVRRequestPresentComplete']),_0x2d15f4['addEventListener']('vrdisplaypresentchange',this['_onVrDisplayPresentChange']),_0x591ee9['onDisposeObservable']['add'](function(){_0x33559f['dispose']();}),this['_webVRCamera']['onControllerMeshLoadedObservable']['add'](function(_0x35c22b){return _0x33559f['_onDefaultMeshLoaded'](_0x35c22b);}),this['_scene']['gamepadManager']['onGamepadConnectedObservable']['add'](this['_onNewGamepadConnected']),this['_scene']['gamepadManager']['onGamepadDisconnectedObservable']['add'](this['_onNewGamepadDisconnected']),this['updateButtonVisibility'](),this['_circleEase']=new _0x66297f(),this['_circleEase']['setEasingMode'](_0x4ba918['EASINGMODE_EASEINOUT']),this['_teleportationEasing']=this['_circleEase'],_0x591ee9['onPointerObservable']['add'](function(_0x1a834e){_0x33559f['_interactionsEnabled']&&_0x591ee9['activeCamera']===_0x33559f['vrDeviceOrientationCamera']&&'mouse'===_0x1a834e['event']['pointerType']&&(_0x1a834e['type']===_0x1cb628['a']['POINTERDOWN']?_0x33559f['_cameraGazer']['_selectionPointerDown']():_0x1a834e['type']===_0x1cb628['a']['POINTERUP']&&_0x33559f['_cameraGazer']['_selectionPointerUp']());}),this['webVROptions']['floorMeshes']&&this['enableTeleportation']({'floorMeshes':this['webVROptions']['floorMeshes']}));},_0x25297c['prototype']['_onDefaultMeshLoaded']=function(_0x10ec78){this['_leftController']&&this['_leftController']['webVRController']==_0x10ec78&&_0x10ec78['mesh']&&this['_leftController']['_setLaserPointerParent'](_0x10ec78['mesh']),this['_rightController']&&this['_rightController']['webVRController']==_0x10ec78&&_0x10ec78['mesh']&&this['_rightController']['_setLaserPointerParent'](_0x10ec78['mesh']);try{this['onControllerMeshLoadedObservable']['notifyObservers'](_0x10ec78);}catch(_0x5e37ce){_0x75193d['a']['Warn']('Error\x20in\x20your\x20custom\x20logic\x20onControllerMeshLoaded:\x20'+_0x5e37ce);}},Object['defineProperty'](_0x25297c['prototype'],'isInVRMode',{'get':function(){return this['xr']&&this['webVROptions']['useXR']&&this['xr']['baseExperience']['state']===_0xada4aa['IN_XR']||this['_webVRpresenting']||this['_fullscreenVRpresenting'];},'enumerable':!0x1,'configurable':!0x0}),_0x25297c['prototype']['onVrDisplayPresentChange']=function(){var _0x4ecfed=this['_scene']['getEngine']()['getVRDevice']();if(_0x4ecfed){var _0x56d0c2=this['_webVRpresenting'];this['_webVRpresenting']=_0x4ecfed['isPresenting'],_0x56d0c2&&!this['_webVRpresenting']&&this['exitVR']();}else _0x75193d['a']['Warn']('Detected\x20VRDisplayPresentChange\x20on\x20an\x20unknown\x20VRDisplay.\x20Did\x20you\x20can\x20enterVR\x20on\x20the\x20vrExperienceHelper?');this['updateButtonVisibility']();},_0x25297c['prototype']['onVRDisplayChanged']=function(_0x123d2d){this['_webVRsupported']=_0x123d2d['vrSupported'],this['_webVRready']=!!_0x123d2d['vrDisplay'],this['_webVRpresenting']=_0x123d2d['vrDisplay']&&_0x123d2d['vrDisplay']['isPresenting'],this['updateButtonVisibility']();},_0x25297c['prototype']['moveButtonToBottomRight']=function(){if(this['_inputElement']&&!this['_useCustomVRButton']&&this['_btnVR']){var _0x5323ed=this['_inputElement']['getBoundingClientRect']();this['_btnVR']['style']['top']=_0x5323ed['top']+_0x5323ed['height']-0x46+'px',this['_btnVR']['style']['left']=_0x5323ed['left']+_0x5323ed['width']-0x64+'px';}},_0x25297c['prototype']['displayVRButton']=function(){this['_useCustomVRButton']||this['_btnVRDisplayed']||!this['_btnVR']||(document['body']['appendChild'](this['_btnVR']),this['_btnVRDisplayed']=!0x0);},_0x25297c['prototype']['updateButtonVisibility']=function(){this['_btnVR']&&!this['_useCustomVRButton']&&(this['_btnVR']['className']='babylonVRicon',this['isInVRMode']?this['_btnVR']['className']+='\x20vrdisplaypresenting':(this['_webVRready']&&(this['_btnVR']['className']+='\x20vrdisplayready'),this['_webVRsupported']&&(this['_btnVR']['className']+='\x20vrdisplaysupported'),this['_webVRrequesting']&&(this['_btnVR']['className']+='\x20vrdisplayrequesting')));},_0x25297c['prototype']['enterVR']=function(){var _0x340455=this;if(this['xr'])this['xr']['baseExperience']['enterXRAsync']('immersive-vr','local-floor',this['xr']['renderTarget']);else{if(this['onEnteringVRObservable'])try{this['onEnteringVRObservable']['notifyObservers'](this);}catch(_0x395cb5){_0x75193d['a']['Warn']('Error\x20in\x20your\x20custom\x20logic\x20onEnteringVR:\x20'+_0x395cb5);}if(this['_scene']['activeCamera']){if(this['_position']=this['_scene']['activeCamera']['position']['clone'](),this['vrDeviceOrientationCamera']&&(this['vrDeviceOrientationCamera']['rotation']=_0x74d525['b']['FromRotationMatrix'](this['_scene']['activeCamera']['getWorldMatrix']()['getRotationMatrix']())['toEulerAngles'](),this['vrDeviceOrientationCamera']['angularSensibility']=0x7d0),this['webVRCamera']){var _0x37fdac=this['webVRCamera']['deviceRotationQuaternion']['toEulerAngles']()['y'],_0x1b37fb=_0x74d525['b']['FromRotationMatrix'](this['_scene']['activeCamera']['getWorldMatrix']()['getRotationMatrix']())['toEulerAngles']()['y']-_0x37fdac,_0xb4685d=this['webVRCamera']['rotationQuaternion']['toEulerAngles']()['y'];this['webVRCamera']['rotationQuaternion']=_0x74d525['b']['FromEulerAngles'](0x0,_0xb4685d+_0x1b37fb,0x0);}this['_existingCamera']=this['_scene']['activeCamera'],this['_existingCamera']['angularSensibilityX']&&(this['_cachedAngularSensibility']['angularSensibilityX']=this['_existingCamera']['angularSensibilityX'],this['_existingCamera']['angularSensibilityX']=Number['MAX_VALUE']),this['_existingCamera']['angularSensibilityY']&&(this['_cachedAngularSensibility']['angularSensibilityY']=this['_existingCamera']['angularSensibilityY'],this['_existingCamera']['angularSensibilityY']=Number['MAX_VALUE']),this['_existingCamera']['angularSensibility']&&(this['_cachedAngularSensibility']['angularSensibility']=this['_existingCamera']['angularSensibility'],this['_existingCamera']['angularSensibility']=Number['MAX_VALUE']);}this['_webVRrequesting']||(this['_webVRready']?this['_webVRpresenting']||(this['_scene']['getEngine']()['onVRRequestPresentComplete']['addOnce'](function(_0x5aff65){_0x340455['onAfterEnteringVRObservable']['notifyObservers']({'success':_0x5aff65});}),this['_webVRCamera']['position']=this['_position'],this['_scene']['activeCamera']=this['_webVRCamera']):this['_vrDeviceOrientationCamera']&&(this['_vrDeviceOrientationCamera']['position']=this['_position'],this['_scene']['activeCamera']&&(this['_vrDeviceOrientationCamera']['minZ']=this['_scene']['activeCamera']['minZ']),this['_scene']['activeCamera']=this['_vrDeviceOrientationCamera'],this['_scene']['getEngine']()['enterFullscreen'](this['requestPointerLockOnFullScreen']),this['updateButtonVisibility'](),this['_vrDeviceOrientationCamera']['onViewMatrixChangedObservable']['addOnce'](function(){_0x340455['onAfterEnteringVRObservable']['notifyObservers']({'success':!0x0});})),this['_scene']['activeCamera']&&this['_inputElement']&&this['_scene']['activeCamera']['attachControl'](),this['_interactionsEnabled']&&this['_scene']['registerBeforeRender'](this['beforeRender']),this['_displayLaserPointer']&&[this['_leftController'],this['_rightController']]['forEach'](function(_0xcff9f7){_0xcff9f7&&_0xcff9f7['_activatePointer']();}),this['_hasEnteredVR']=!0x0);}},_0x25297c['prototype']['exitVR']=function(){if(this['xr'])this['xr']['baseExperience']['exitXRAsync']();else{if(this['_hasEnteredVR']){if(this['onExitingVRObservable'])try{this['onExitingVRObservable']['notifyObservers'](this);}catch(_0x40033a){_0x75193d['a']['Warn']('Error\x20in\x20your\x20custom\x20logic\x20onExitingVR:\x20'+_0x40033a);}this['_webVRpresenting']&&this['_scene']['getEngine']()['disableVR'](),this['_scene']['activeCamera']&&(this['_position']=this['_scene']['activeCamera']['position']['clone']()),this['vrDeviceOrientationCamera']&&(this['vrDeviceOrientationCamera']['angularSensibility']=Number['MAX_VALUE']),this['_deviceOrientationCamera']?(this['_deviceOrientationCamera']['position']=this['_position'],this['_scene']['activeCamera']=this['_deviceOrientationCamera'],this['_cachedAngularSensibility']['angularSensibilityX']&&(this['_deviceOrientationCamera']['angularSensibilityX']=this['_cachedAngularSensibility']['angularSensibilityX'],this['_cachedAngularSensibility']['angularSensibilityX']=null),this['_cachedAngularSensibility']['angularSensibilityY']&&(this['_deviceOrientationCamera']['angularSensibilityY']=this['_cachedAngularSensibility']['angularSensibilityY'],this['_cachedAngularSensibility']['angularSensibilityY']=null),this['_cachedAngularSensibility']['angularSensibility']&&(this['_deviceOrientationCamera']['angularSensibility']=this['_cachedAngularSensibility']['angularSensibility'],this['_cachedAngularSensibility']['angularSensibility']=null)):this['_existingCamera']&&(this['_existingCamera']['position']=this['_position'],this['_scene']['activeCamera']=this['_existingCamera'],this['_inputElement']&&this['_scene']['activeCamera']['attachControl'](),this['_cachedAngularSensibility']['angularSensibilityX']&&(this['_existingCamera']['angularSensibilityX']=this['_cachedAngularSensibility']['angularSensibilityX'],this['_cachedAngularSensibility']['angularSensibilityX']=null),this['_cachedAngularSensibility']['angularSensibilityY']&&(this['_existingCamera']['angularSensibilityY']=this['_cachedAngularSensibility']['angularSensibilityY'],this['_cachedAngularSensibility']['angularSensibilityY']=null),this['_cachedAngularSensibility']['angularSensibility']&&(this['_existingCamera']['angularSensibility']=this['_cachedAngularSensibility']['angularSensibility'],this['_cachedAngularSensibility']['angularSensibility']=null)),this['updateButtonVisibility'](),this['_interactionsEnabled']&&(this['_scene']['unregisterBeforeRender'](this['beforeRender']),this['_cameraGazer']['_gazeTracker']['isVisible']=!0x1,this['_leftController']&&(this['_leftController']['_gazeTracker']['isVisible']=!0x1),this['_rightController']&&(this['_rightController']['_gazeTracker']['isVisible']=!0x1)),this['_scene']['getEngine']()['resize'](),[this['_leftController'],this['_rightController']]['forEach'](function(_0xe5a3c5){_0xe5a3c5&&_0xe5a3c5['_deactivatePointer']();}),this['_hasEnteredVR']=!0x1;var _0x5e9d9d=this['_scene']['getEngine']();_0x5e9d9d['_onVrDisplayPresentChange']&&_0x5e9d9d['_onVrDisplayPresentChange']();}}},Object['defineProperty'](_0x25297c['prototype'],'position',{'get':function(){return this['_position'];},'set':function(_0x25e1a4){this['_position']=_0x25e1a4,this['_scene']['activeCamera']&&(this['_scene']['activeCamera']['position']=_0x25e1a4);},'enumerable':!0x1,'configurable':!0x0}),_0x25297c['prototype']['enableInteractions']=function(){var _0x19ede9=this;if(!this['_interactionsEnabled']){if(this['_interactionsRequested']=!0x0,this['xr'])return void(this['xr']['baseExperience']['state']===_0xada4aa['IN_XR']&&this['xr']['pointerSelection']['attach']());this['_leftController']&&this['_enableInteractionOnController'](this['_leftController']),this['_rightController']&&this['_enableInteractionOnController'](this['_rightController']),this['raySelectionPredicate']=function(_0x5d72a5){return _0x5d72a5['isVisible']&&(_0x5d72a5['isPickable']||_0x5d72a5['name']===_0x19ede9['_floorMeshName']);},this['meshSelectionPredicate']=function(){return!0x0;},this['_raySelectionPredicate']=function(_0x15c4dd){return!!(_0x19ede9['_isTeleportationFloor'](_0x15c4dd)||-0x1===_0x15c4dd['name']['indexOf']('gazeTracker')&&-0x1===_0x15c4dd['name']['indexOf']('teleportationTarget')&&-0x1===_0x15c4dd['name']['indexOf']('torusTeleportation'))&&_0x19ede9['raySelectionPredicate'](_0x15c4dd);},this['_interactionsEnabled']=!0x0;}},Object['defineProperty'](_0x25297c['prototype'],'_noControllerIsActive',{'get':function(){return!(this['_leftController']&&this['_leftController']['_activePointer']||this['_rightController']&&this['_rightController']['_activePointer']);},'enumerable':!0x1,'configurable':!0x0}),_0x25297c['prototype']['_isTeleportationFloor']=function(_0x4238d8){for(var _0x53cf7c=0x0;_0x53cf7c-0x1||this['_floorMeshesCollection']['push'](_0x23ed17));},_0x25297c['prototype']['removeFloorMesh']=function(_0x23dd95){if(this['_floorMeshesCollection']){var _0x351e16=this['_floorMeshesCollection']['indexOf'](_0x23dd95);-0x1!==_0x351e16&&this['_floorMeshesCollection']['splice'](_0x351e16,0x1);}},_0x25297c['prototype']['enableTeleportation']=function(_0x2e33e4){var _0x264f62=this;if(void 0x0===_0x2e33e4&&(_0x2e33e4={}),!this['_teleportationInitialized']){if(this['_teleportationRequested']=!0x0,this['enableInteractions'](),this['webVROptions']['useXR']&&(_0x2e33e4['floorMeshes']||_0x2e33e4['floorMeshName'])){var _0x25f1d9=_0x2e33e4['floorMeshes']||[];if(!_0x25f1d9['length']){var _0x31e0ca=this['_scene']['getMeshByName'](_0x2e33e4['floorMeshName']);_0x31e0ca&&_0x25f1d9['push'](_0x31e0ca);}if(this['xr'])return _0x25f1d9['forEach'](function(_0x653b71){_0x264f62['xr']['teleportation']['addFloorMesh'](_0x653b71);}),void(this['xr']['teleportation']['attached']||this['xr']['teleportation']['attach']());if(!this['xrTestDone']){var _0x13bf63=function(){_0x264f62['xrTestDone']&&(_0x264f62['_scene']['unregisterBeforeRender'](_0x13bf63),_0x264f62['xr']?_0x264f62['xr']['teleportation']['attached']||_0x264f62['xr']['teleportation']['attach']():_0x264f62['enableTeleportation'](_0x2e33e4));};return void this['_scene']['registerBeforeRender'](_0x13bf63);}}_0x2e33e4['floorMeshName']&&(this['_floorMeshName']=_0x2e33e4['floorMeshName']),_0x2e33e4['floorMeshes']&&(this['_floorMeshesCollection']=_0x2e33e4['floorMeshes']),_0x2e33e4['teleportationMode']&&(this['_teleportationMode']=_0x2e33e4['teleportationMode']),_0x2e33e4['teleportationTime']&&_0x2e33e4['teleportationTime']>0x0&&(this['_teleportationTime']=_0x2e33e4['teleportationTime']),_0x2e33e4['teleportationSpeed']&&_0x2e33e4['teleportationSpeed']>0x0&&(this['_teleportationSpeed']=_0x2e33e4['teleportationSpeed']),void 0x0!==_0x2e33e4['easingFunction']&&(this['_teleportationEasing']=_0x2e33e4['easingFunction']),null!=this['_leftController']&&this['_enableTeleportationOnController'](this['_leftController']),null!=this['_rightController']&&this['_enableTeleportationOnController'](this['_rightController']);var _0xd1d989=new _0x3f08d6['a']();_0xd1d989['vignetteColor']=new _0x39310d['b'](0x0,0x0,0x0,0x0),_0xd1d989['vignetteEnabled']=!0x0,this['_postProcessMove']=new _0x53baeb('postProcessMove',0x1,this['_webVRCamera'],void 0x0,void 0x0,void 0x0,void 0x0,_0xd1d989),this['_webVRCamera']['detachPostProcess'](this['_postProcessMove']),this['_teleportationInitialized']=!0x0,this['_isDefaultTeleportationTarget']&&(this['_createTeleportationCircles'](),this['_teleportationTarget']['scaling']['scaleInPlace'](this['_webVRCamera']['deviceScaleFactor']));}},_0x25297c['prototype']['_enableInteractionOnController']=function(_0x4482f0){var _0x3c8a08=this;_0x4482f0['webVRController']['mesh']&&(_0x4482f0['_interactionsEnabled']=!0x0,this['isInVRMode']&&this['_displayLaserPointer']&&_0x4482f0['_activatePointer'](),this['webVROptions']['laserToggle']&&_0x4482f0['webVRController']['onMainButtonStateChangedObservable']['add'](function(_0x4113dd){_0x3c8a08['_displayLaserPointer']&&0x1===_0x4113dd['value']&&(_0x4482f0['_activePointer']?_0x4482f0['_deactivatePointer']():_0x4482f0['_activatePointer'](),_0x3c8a08['displayGaze']&&(_0x4482f0['_gazeTracker']['isVisible']=_0x4482f0['_activePointer']));}),_0x4482f0['webVRController']['onTriggerStateChangedObservable']['add'](function(_0x3084f3){var _0x3aada2=_0x4482f0;_0x3c8a08['_noControllerIsActive']&&(_0x3aada2=_0x3c8a08['_cameraGazer']),_0x3aada2['_pointerDownOnMeshAsked']?_0x3084f3['value']<_0x3c8a08['_padSensibilityDown']&&_0x3aada2['_selectionPointerUp']():_0x3084f3['value']>_0x3c8a08['_padSensibilityUp']&&_0x3aada2['_selectionPointerDown']();}));},_0x25297c['prototype']['_checkTeleportWithRay']=function(_0x4d167c,_0x2afb8c){this['_teleportationRequestInitiated']&&!_0x2afb8c['_teleportationRequestInitiated']||(_0x2afb8c['_teleportationRequestInitiated']?Math['sqrt'](_0x4d167c['y']*_0x4d167c['y']+_0x4d167c['x']*_0x4d167c['x'])-this['_padSensibilityDown']&&(_0x38299f['_rotationLeftAsked']=!0x1):_0x2b4d21['x']<-this['_padSensibilityUp']&&_0x38299f['_dpadPressed']&&(_0x38299f['_rotationLeftAsked']=!0x0,this['_rotationAllowed']&&this['_rotateCamera'](!0x1)),_0x38299f['_rotationRightAsked']?_0x2b4d21['x']this['_padSensibilityUp']&&_0x38299f['_dpadPressed']&&(_0x38299f['_rotationRightAsked']=!0x0,this['_rotationAllowed']&&this['_rotateCamera'](!0x0)));},_0x25297c['prototype']['_checkTeleportBackwards']=function(_0x2b35af,_0x224db3){if(!_0x224db3['_teleportationRequestInitiated']){if(_0x2b35af['y']>this['_padSensibilityUp']&&_0x224db3['_dpadPressed']){if(!_0x224db3['_teleportationBackRequestInitiated']){if(!this['currentVRCamera'])return;var _0x364e2b=_0x74d525['b']['FromRotationMatrix'](this['currentVRCamera']['getWorldMatrix']()['getRotationMatrix']()),_0x4a1747=this['currentVRCamera']['position'];this['currentVRCamera']['devicePosition']&&this['currentVRCamera']['deviceRotationQuaternion']&&(_0x364e2b=this['currentVRCamera']['deviceRotationQuaternion'],_0x4a1747=this['currentVRCamera']['devicePosition']),_0x364e2b['toEulerAnglesToRef'](this['_workingVector']),this['_workingVector']['z']=0x0,this['_workingVector']['x']=0x0,_0x74d525['b']['RotationYawPitchRollToRef'](this['_workingVector']['y'],this['_workingVector']['x'],this['_workingVector']['z'],this['_workingQuaternion']),this['_workingQuaternion']['toRotationMatrix'](this['_workingMatrix']),_0x74d525['e']['TransformCoordinatesToRef'](this['_teleportBackwardsVector'],this['_workingMatrix'],this['_workingVector']);var _0x1e845d=new _0x36fb4d['a'](_0x4a1747,this['_workingVector']),_0x18dd15=this['_scene']['pickWithRay'](_0x1e845d,this['_raySelectionPredicate']);_0x18dd15&&_0x18dd15['pickedPoint']&&_0x18dd15['pickedMesh']&&this['_isTeleportationFloor'](_0x18dd15['pickedMesh'])&&_0x18dd15['distance']<0x5&&this['teleportCamera'](_0x18dd15['pickedPoint']),_0x224db3['_teleportationBackRequestInitiated']=!0x0;}}else _0x224db3['_teleportationBackRequestInitiated']=!0x1;}},_0x25297c['prototype']['_enableTeleportationOnController']=function(_0x52b55b){var _0x36a998=this;_0x52b55b['webVRController']['mesh']&&(_0x52b55b['_interactionsEnabled']||this['_enableInteractionOnController'](_0x52b55b),_0x52b55b['_interactionsEnabled']=!0x0,_0x52b55b['_teleportationEnabled']=!0x0,_0x52b55b['webVRController']['controllerType']===_0x1a2757['VIVE']&&(_0x52b55b['_dpadPressed']=!0x1,_0x52b55b['webVRController']['onPadStateChangedObservable']['add'](function(_0x491fb1){_0x52b55b['_dpadPressed']=_0x491fb1['pressed'],_0x52b55b['_dpadPressed']||(_0x52b55b['_rotationLeftAsked']=!0x1,_0x52b55b['_rotationRightAsked']=!0x1,_0x52b55b['_teleportationBackRequestInitiated']=!0x1);})),_0x52b55b['webVRController']['onPadValuesChangedObservable']['add'](function(_0x1df4ca){_0x36a998['teleportationEnabled']&&(_0x36a998['_checkTeleportBackwards'](_0x1df4ca,_0x52b55b),_0x36a998['_checkTeleportWithRay'](_0x1df4ca,_0x52b55b)),_0x36a998['_checkRotate'](_0x1df4ca,_0x52b55b);}));},_0x25297c['prototype']['_createTeleportationCircles']=function(){this['_teleportationTarget']=_0x3cf5e5['a']['CreateGround']('teleportationTarget',0x2,0x2,0x2,this['_scene']),this['_teleportationTarget']['isPickable']=!0x1;var _0x4ef55e=new _0x41f891['a']('DynamicTexture',0x200,this['_scene'],!0x0);_0x4ef55e['hasAlpha']=!0x0;var _0x5bafb3=_0x4ef55e['getContext']();_0x5bafb3['beginPath'](),_0x5bafb3['arc'](0x100,0x100,0xc8,0x0,0x2*Math['PI'],!0x1),_0x5bafb3['fillStyle']=this['_teleportationFillColor'],_0x5bafb3['fill'](),_0x5bafb3['lineWidth']=0xa,_0x5bafb3['strokeStyle']=this['_teleportationBorderColor'],_0x5bafb3['stroke'](),_0x5bafb3['closePath'](),_0x4ef55e['update']();var _0x414754=new _0x5905ab['a']('TextPlaneMaterial',this['_scene']);_0x414754['diffuseTexture']=_0x4ef55e,this['_teleportationTarget']['material']=_0x414754;var _0x3a1fa7=_0x3cf5e5['a']['CreateTorus']('torusTeleportation',0.75,0.1,0x19,this['_scene'],!0x1);_0x3a1fa7['isPickable']=!0x1,_0x3a1fa7['parent']=this['_teleportationTarget'];var _0x5a4196=new _0x1b0498('animationInnerCircle','position.y',0x1e,_0x1b0498['ANIMATIONTYPE_FLOAT'],_0x1b0498['ANIMATIONLOOPMODE_CYCLE']),_0x34a1df=[];_0x34a1df['push']({'frame':0x0,'value':0x0}),_0x34a1df['push']({'frame':0x1e,'value':0.4}),_0x34a1df['push']({'frame':0x3c,'value':0x0}),_0x5a4196['setKeys'](_0x34a1df);var _0x292105=new _0x4c852a();_0x292105['setEasingMode'](_0x4ba918['EASINGMODE_EASEINOUT']),_0x5a4196['setEasingFunction'](_0x292105),_0x3a1fa7['animations']=[],_0x3a1fa7['animations']['push'](_0x5a4196),this['_scene']['beginAnimation'](_0x3a1fa7,0x0,0x3c,!0x0),this['_hideTeleportationTarget']();},_0x25297c['prototype']['_displayTeleportationTarget']=function(){this['_teleportActive']=!0x0,this['_teleportationInitialized']&&(this['_teleportationTarget']['isVisible']=!0x0,this['_isDefaultTeleportationTarget']&&(this['_teleportationTarget']['getChildren']()[0x0]['isVisible']=!0x0));},_0x25297c['prototype']['_hideTeleportationTarget']=function(){this['_teleportActive']=!0x1,this['_teleportationInitialized']&&(this['_teleportationTarget']['isVisible']=!0x1,this['_isDefaultTeleportationTarget']&&(this['_teleportationTarget']['getChildren']()[0x0]['isVisible']=!0x1));},_0x25297c['prototype']['_rotateCamera']=function(_0x11dc09){var _0x54d51d=this;if(this['currentVRCamera']instanceof _0x5625b9){_0x11dc09?this['_rotationAngle']++:this['_rotationAngle']--,this['currentVRCamera']['animations']=[];var _0x3b12a4=_0x74d525['b']['FromRotationMatrix'](_0x74d525['a']['RotationY'](Math['PI']/0x4*this['_rotationAngle'])),_0x3132d2=new _0x1b0498('animationRotation','rotationQuaternion',0x5a,_0x1b0498['ANIMATIONTYPE_QUATERNION'],_0x1b0498['ANIMATIONLOOPMODE_CONSTANT']),_0x12c1a2=[];_0x12c1a2['push']({'frame':0x0,'value':this['currentVRCamera']['rotationQuaternion']}),_0x12c1a2['push']({'frame':0x6,'value':_0x3b12a4}),_0x3132d2['setKeys'](_0x12c1a2),_0x3132d2['setEasingFunction'](this['_circleEase']),this['currentVRCamera']['animations']['push'](_0x3132d2),this['_postProcessMove']['animations']=[];var _0x461e67=new _0x1b0498('animationPP','vignetteWeight',0x5a,_0x1b0498['ANIMATIONTYPE_FLOAT'],_0x1b0498['ANIMATIONLOOPMODE_CONSTANT']),_0x53bbd0=[];_0x53bbd0['push']({'frame':0x0,'value':0x0}),_0x53bbd0['push']({'frame':0x3,'value':0x4}),_0x53bbd0['push']({'frame':0x6,'value':0x0}),_0x461e67['setKeys'](_0x53bbd0),_0x461e67['setEasingFunction'](this['_circleEase']),this['_postProcessMove']['animations']['push'](_0x461e67);var _0x4c3f97=new _0x1b0498('animationPP2','vignetteStretch',0x5a,_0x1b0498['ANIMATIONTYPE_FLOAT'],_0x1b0498['ANIMATIONLOOPMODE_CONSTANT']),_0x1f6785=[];_0x1f6785['push']({'frame':0x0,'value':0x0}),_0x1f6785['push']({'frame':0x3,'value':0xa}),_0x1f6785['push']({'frame':0x6,'value':0x0}),_0x4c3f97['setKeys'](_0x1f6785),_0x4c3f97['setEasingFunction'](this['_circleEase']),this['_postProcessMove']['animations']['push'](_0x4c3f97),this['_postProcessMove']['imageProcessingConfiguration']['vignetteWeight']=0x0,this['_postProcessMove']['imageProcessingConfiguration']['vignetteStretch']=0x0,this['_postProcessMove']['samples']=0x4,this['_webVRCamera']['attachPostProcess'](this['_postProcessMove']),this['_scene']['beginAnimation'](this['_postProcessMove'],0x0,0x6,!0x1,0x1,function(){_0x54d51d['_webVRCamera']['detachPostProcess'](_0x54d51d['_postProcessMove']);}),this['_scene']['beginAnimation'](this['currentVRCamera'],0x0,0x6,!0x1,0x1);}},_0x25297c['prototype']['_moveTeleportationSelectorTo']=function(_0x39f588,_0x2b7173,_0x5c55d8){if(_0x39f588['pickedPoint']){_0x2b7173['_teleportationRequestInitiated']&&(this['_displayTeleportationTarget'](),this['_haloCenter']['copyFrom'](_0x39f588['pickedPoint']),this['_teleportationTarget']['position']['copyFrom'](_0x39f588['pickedPoint']));var _0x1d5845=this['_convertNormalToDirectionOfRay'](_0x39f588['getNormal'](!0x0,!0x1),_0x5c55d8);if(_0x1d5845){var _0x316fa6=_0x74d525['e']['Cross'](_0x4a79a2['a']['Y'],_0x1d5845),_0x43cbbf=_0x74d525['e']['Cross'](_0x1d5845,_0x316fa6);_0x74d525['e']['RotationFromAxisToRef'](_0x43cbbf,_0x1d5845,_0x316fa6,this['_teleportationTarget']['rotation']);}this['_teleportationTarget']['position']['y']+=0.1;}},_0x25297c['prototype']['teleportCamera']=function(_0x38d73b){var _0x40f92d=this;if(this['currentVRCamera']instanceof _0x5625b9){this['webVRCamera']['leftCamera']?(this['_workingVector']['copyFrom'](this['webVRCamera']['leftCamera']['globalPosition']),this['_workingVector']['subtractInPlace'](this['webVRCamera']['position']),_0x38d73b['subtractToRef'](this['_workingVector'],this['_workingVector'])):this['_workingVector']['copyFrom'](_0x38d73b),this['isInVRMode']?this['_workingVector']['y']+=this['webVRCamera']['deviceDistanceToRoomGround']()*this['_webVRCamera']['deviceScaleFactor']:this['_workingVector']['y']+=this['_defaultHeight'],this['onBeforeCameraTeleport']['notifyObservers'](this['_workingVector']);var _0x60f5b,_0x170462;if(this['_teleportationMode']==_0x25297c['TELEPORTATIONMODE_CONSTANTSPEED']){_0x170462=0x5a;var _0x33ae30=_0x74d525['e']['Distance'](this['currentVRCamera']['position'],this['_workingVector']);_0x60f5b=this['_teleportationSpeed']/_0x33ae30;}else _0x170462=Math['round'](0x5a*this['_teleportationTime']/0x3e8),_0x60f5b=0x1;this['currentVRCamera']['animations']=[];var _0x2469d6=new _0x1b0498('animationCameraTeleportation','position',0x5a,_0x1b0498['ANIMATIONTYPE_VECTOR3'],_0x1b0498['ANIMATIONLOOPMODE_CONSTANT']),_0x40f4e4=[{'frame':0x0,'value':this['currentVRCamera']['position']},{'frame':_0x170462,'value':this['_workingVector']}];_0x2469d6['setKeys'](_0x40f4e4),_0x2469d6['setEasingFunction'](this['_teleportationEasing']),this['currentVRCamera']['animations']['push'](_0x2469d6),this['_postProcessMove']['animations']=[];var _0x228df4=Math['round'](_0x170462/0x2),_0xec68e0=new _0x1b0498('animationPP','vignetteWeight',0x5a,_0x1b0498['ANIMATIONTYPE_FLOAT'],_0x1b0498['ANIMATIONLOOPMODE_CONSTANT']),_0x49ed8c=[];_0x49ed8c['push']({'frame':0x0,'value':0x0}),_0x49ed8c['push']({'frame':_0x228df4,'value':0x8}),_0x49ed8c['push']({'frame':_0x170462,'value':0x0}),_0xec68e0['setKeys'](_0x49ed8c),this['_postProcessMove']['animations']['push'](_0xec68e0);var _0x392739=new _0x1b0498('animationPP2','vignetteStretch',0x5a,_0x1b0498['ANIMATIONTYPE_FLOAT'],_0x1b0498['ANIMATIONLOOPMODE_CONSTANT']),_0x5f1a83=[];_0x5f1a83['push']({'frame':0x0,'value':0x0}),_0x5f1a83['push']({'frame':_0x228df4,'value':0xa}),_0x5f1a83['push']({'frame':_0x170462,'value':0x0}),_0x392739['setKeys'](_0x5f1a83),this['_postProcessMove']['animations']['push'](_0x392739),this['_postProcessMove']['imageProcessingConfiguration']['vignetteWeight']=0x0,this['_postProcessMove']['imageProcessingConfiguration']['vignetteStretch']=0x0,this['_webVRCamera']['attachPostProcess'](this['_postProcessMove']),this['_scene']['beginAnimation'](this['_postProcessMove'],0x0,_0x170462,!0x1,_0x60f5b,function(){_0x40f92d['_webVRCamera']['detachPostProcess'](_0x40f92d['_postProcessMove']);}),this['_scene']['beginAnimation'](this['currentVRCamera'],0x0,_0x170462,!0x1,_0x60f5b,function(){_0x40f92d['onAfterCameraTeleport']['notifyObservers'](_0x40f92d['_workingVector']);}),this['_hideTeleportationTarget']();}},_0x25297c['prototype']['_convertNormalToDirectionOfRay']=function(_0x148a0c,_0x423aa3){return _0x148a0c&&(Math['acos'](_0x74d525['e']['Dot'](_0x148a0c,_0x423aa3['direction']))_0x9c6d86){var _0x2c4a43=_0x9c6d86;_0x9c6d86=_0x35081d,_0x35081d=_0x2c4a43;}return _0x35081d>0x0&&_0x35081d<_0x3365c8?(_0x2cb8bd['root']=_0x35081d,_0x2cb8bd['found']=!0x0,_0x2cb8bd):_0x9c6d86>0x0&&_0x9c6d86<_0x3365c8?(_0x2cb8bd['root']=_0x9c6d86,_0x2cb8bd['found']=!0x0,_0x2cb8bd):_0x2cb8bd;}),_0x24c000=(function(){function _0x32bfe9(){this['_collisionPoint']=_0x74d525['e']['Zero'](),this['_planeIntersectionPoint']=_0x74d525['e']['Zero'](),this['_tempVector']=_0x74d525['e']['Zero'](),this['_tempVector2']=_0x74d525['e']['Zero'](),this['_tempVector3']=_0x74d525['e']['Zero'](),this['_tempVector4']=_0x74d525['e']['Zero'](),this['_edge']=_0x74d525['e']['Zero'](),this['_baseToVertex']=_0x74d525['e']['Zero'](),this['_destinationPoint']=_0x74d525['e']['Zero'](),this['_slidePlaneNormal']=_0x74d525['e']['Zero'](),this['_displacementVector']=_0x74d525['e']['Zero'](),this['_radius']=_0x74d525['e']['One'](),this['_retry']=0x0,this['_basePointWorld']=_0x74d525['e']['Zero'](),this['_velocityWorld']=_0x74d525['e']['Zero'](),this['_normalizedVelocity']=_0x74d525['e']['Zero'](),this['_collisionMask']=-0x1;}return Object['defineProperty'](_0x32bfe9['prototype'],'collisionMask',{'get':function(){return this['_collisionMask'];},'set':function(_0x3a1620){this['_collisionMask']=isNaN(_0x3a1620)?-0x1:_0x3a1620;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x32bfe9['prototype'],'slidePlaneNormal',{'get':function(){return this['_slidePlaneNormal'];},'enumerable':!0x1,'configurable':!0x0}),_0x32bfe9['prototype']['_initialize']=function(_0x34b541,_0x41b21f,_0x4d822c){this['_velocity']=_0x41b21f,_0x74d525['e']['NormalizeToRef'](_0x41b21f,this['_normalizedVelocity']),this['_basePoint']=_0x34b541,_0x34b541['multiplyToRef'](this['_radius'],this['_basePointWorld']),_0x41b21f['multiplyToRef'](this['_radius'],this['_velocityWorld']),this['_velocityWorldLength']=this['_velocityWorld']['length'](),this['_epsilon']=_0x4d822c,this['collisionFound']=!0x1;},_0x32bfe9['prototype']['_checkPointInTriangle']=function(_0x63fead,_0x16e58c,_0x55a2ba,_0x5ff7d9,_0x160679){_0x16e58c['subtractToRef'](_0x63fead,this['_tempVector']),_0x55a2ba['subtractToRef'](_0x63fead,this['_tempVector2']),_0x74d525['e']['CrossToRef'](this['_tempVector'],this['_tempVector2'],this['_tempVector4']);var _0x2f6049=_0x74d525['e']['Dot'](this['_tempVector4'],_0x160679);return!(_0x2f6049<0x0)&&(_0x5ff7d9['subtractToRef'](_0x63fead,this['_tempVector3']),_0x74d525['e']['CrossToRef'](this['_tempVector2'],this['_tempVector3'],this['_tempVector4']),!((_0x2f6049=_0x74d525['e']['Dot'](this['_tempVector4'],_0x160679))<0x0)&&(_0x74d525['e']['CrossToRef'](this['_tempVector3'],this['_tempVector'],this['_tempVector4']),(_0x2f6049=_0x74d525['e']['Dot'](this['_tempVector4'],_0x160679))>=0x0));},_0x32bfe9['prototype']['_canDoCollision']=function(_0x6e6741,_0x118cef,_0x388a1a,_0x4ade62){var _0x2c0a7b=_0x74d525['e']['Distance'](this['_basePointWorld'],_0x6e6741),_0x5d1a68=Math['max'](this['_radius']['x'],this['_radius']['y'],this['_radius']['z']);return!(_0x2c0a7b>this['_velocityWorldLength']+_0x5d1a68+_0x118cef)&&!!function(_0x274894,_0x23f115,_0x2a8af3,_0x4d45ca){return!(_0x274894['x']>_0x2a8af3['x']+_0x4d45ca)&&(!(_0x2a8af3['x']-_0x4d45ca>_0x23f115['x'])&&(!(_0x274894['y']>_0x2a8af3['y']+_0x4d45ca)&&(!(_0x2a8af3['y']-_0x4d45ca>_0x23f115['y'])&&(!(_0x274894['z']>_0x2a8af3['z']+_0x4d45ca)&&!(_0x2a8af3['z']-_0x4d45ca>_0x23f115['z'])))));}(_0x388a1a,_0x4ade62,this['_basePointWorld'],this['_velocityWorldLength']+_0x5d1a68);},_0x32bfe9['prototype']['_testTriangle']=function(_0x1d7f63,_0x3352a8,_0x410e7d,_0x4cfc05,_0x4b24a5,_0x3e6f04,_0x56b3ce){var _0x182ecc,_0x15ec11=!0x1;_0x3352a8||(_0x3352a8=[]),_0x3352a8[_0x1d7f63]||(_0x3352a8[_0x1d7f63]=new _0x5c8dd6['a'](0x0,0x0,0x0,0x0),_0x3352a8[_0x1d7f63]['copyFromPoints'](_0x410e7d,_0x4cfc05,_0x4b24a5));var _0x1fc120=_0x3352a8[_0x1d7f63];if(_0x3e6f04||_0x1fc120['isFrontFacingTo'](this['_normalizedVelocity'],0x0)){var _0x593231=_0x1fc120['signedDistanceTo'](this['_basePoint']),_0x2ef904=_0x74d525['e']['Dot'](_0x1fc120['normal'],this['_velocity']);if(0x0==_0x2ef904){if(Math['abs'](_0x593231)>=0x1)return;_0x15ec11=!0x0,_0x182ecc=0x0;}else{var _0x456caa=(0x1-_0x593231)/_0x2ef904;if((_0x182ecc=(-0x1-_0x593231)/_0x2ef904)>_0x456caa){var _0x4c0046=_0x456caa;_0x456caa=_0x182ecc,_0x182ecc=_0x4c0046;}if(_0x182ecc>0x1||_0x456caa<0x0)return;_0x182ecc<0x0&&(_0x182ecc=0x0),_0x182ecc>0x1&&(_0x182ecc=0x1);}this['_collisionPoint']['copyFromFloats'](0x0,0x0,0x0);var _0x36dba8=!0x1,_0x6b6486=0x1;if(_0x15ec11||(this['_basePoint']['subtractToRef'](_0x1fc120['normal'],this['_planeIntersectionPoint']),this['_velocity']['scaleToRef'](_0x182ecc,this['_tempVector']),this['_planeIntersectionPoint']['addInPlace'](this['_tempVector']),this['_checkPointInTriangle'](this['_planeIntersectionPoint'],_0x410e7d,_0x4cfc05,_0x4b24a5,_0x1fc120['normal'])&&(_0x36dba8=!0x0,_0x6b6486=_0x182ecc,this['_collisionPoint']['copyFrom'](this['_planeIntersectionPoint']))),!_0x36dba8){var _0x36a77a=this['_velocity']['lengthSquared'](),_0x1c18bf=_0x36a77a;this['_basePoint']['subtractToRef'](_0x410e7d,this['_tempVector']);var _0x2a81ab=0x2*_0x74d525['e']['Dot'](this['_velocity'],this['_tempVector']),_0x13dcd5=this['_tempVector']['lengthSquared']()-0x1,_0x33ddca=_0x4a6f47(_0x1c18bf,_0x2a81ab,_0x13dcd5,_0x6b6486);_0x33ddca['found']&&(_0x6b6486=_0x33ddca['root'],_0x36dba8=!0x0,this['_collisionPoint']['copyFrom'](_0x410e7d)),this['_basePoint']['subtractToRef'](_0x4cfc05,this['_tempVector']),_0x2a81ab=0x2*_0x74d525['e']['Dot'](this['_velocity'],this['_tempVector']),_0x13dcd5=this['_tempVector']['lengthSquared']()-0x1,(_0x33ddca=_0x4a6f47(_0x1c18bf,_0x2a81ab,_0x13dcd5,_0x6b6486))['found']&&(_0x6b6486=_0x33ddca['root'],_0x36dba8=!0x0,this['_collisionPoint']['copyFrom'](_0x4cfc05)),this['_basePoint']['subtractToRef'](_0x4b24a5,this['_tempVector']),_0x2a81ab=0x2*_0x74d525['e']['Dot'](this['_velocity'],this['_tempVector']),_0x13dcd5=this['_tempVector']['lengthSquared']()-0x1,(_0x33ddca=_0x4a6f47(_0x1c18bf,_0x2a81ab,_0x13dcd5,_0x6b6486))['found']&&(_0x6b6486=_0x33ddca['root'],_0x36dba8=!0x0,this['_collisionPoint']['copyFrom'](_0x4b24a5)),_0x4cfc05['subtractToRef'](_0x410e7d,this['_edge']),_0x410e7d['subtractToRef'](this['_basePoint'],this['_baseToVertex']);var _0x477231=this['_edge']['lengthSquared'](),_0x5c91c5=_0x74d525['e']['Dot'](this['_edge'],this['_velocity']),_0x164fae=_0x74d525['e']['Dot'](this['_edge'],this['_baseToVertex']);if(_0x1c18bf=_0x477231*-_0x36a77a+_0x5c91c5*_0x5c91c5,_0x2a81ab=_0x477231*(0x2*_0x74d525['e']['Dot'](this['_velocity'],this['_baseToVertex']))-0x2*_0x5c91c5*_0x164fae,_0x13dcd5=_0x477231*(0x1-this['_baseToVertex']['lengthSquared']())+_0x164fae*_0x164fae,(_0x33ddca=_0x4a6f47(_0x1c18bf,_0x2a81ab,_0x13dcd5,_0x6b6486))['found']){var _0x577d32=(_0x5c91c5*_0x33ddca['root']-_0x164fae)/_0x477231;_0x577d32>=0x0&&_0x577d32<=0x1&&(_0x6b6486=_0x33ddca['root'],_0x36dba8=!0x0,this['_edge']['scaleInPlace'](_0x577d32),_0x410e7d['addToRef'](this['_edge'],this['_collisionPoint']));}_0x4b24a5['subtractToRef'](_0x4cfc05,this['_edge']),_0x4cfc05['subtractToRef'](this['_basePoint'],this['_baseToVertex']),_0x477231=this['_edge']['lengthSquared'](),_0x5c91c5=_0x74d525['e']['Dot'](this['_edge'],this['_velocity']),_0x164fae=_0x74d525['e']['Dot'](this['_edge'],this['_baseToVertex']),_0x1c18bf=_0x477231*-_0x36a77a+_0x5c91c5*_0x5c91c5,_0x2a81ab=_0x477231*(0x2*_0x74d525['e']['Dot'](this['_velocity'],this['_baseToVertex']))-0x2*_0x5c91c5*_0x164fae,_0x13dcd5=_0x477231*(0x1-this['_baseToVertex']['lengthSquared']())+_0x164fae*_0x164fae,(_0x33ddca=_0x4a6f47(_0x1c18bf,_0x2a81ab,_0x13dcd5,_0x6b6486))['found']&&(_0x577d32=(_0x5c91c5*_0x33ddca['root']-_0x164fae)/_0x477231)>=0x0&&_0x577d32<=0x1&&(_0x6b6486=_0x33ddca['root'],_0x36dba8=!0x0,this['_edge']['scaleInPlace'](_0x577d32),_0x4cfc05['addToRef'](this['_edge'],this['_collisionPoint'])),_0x410e7d['subtractToRef'](_0x4b24a5,this['_edge']),_0x4b24a5['subtractToRef'](this['_basePoint'],this['_baseToVertex']),_0x477231=this['_edge']['lengthSquared'](),_0x5c91c5=_0x74d525['e']['Dot'](this['_edge'],this['_velocity']),_0x164fae=_0x74d525['e']['Dot'](this['_edge'],this['_baseToVertex']),_0x1c18bf=_0x477231*-_0x36a77a+_0x5c91c5*_0x5c91c5,_0x2a81ab=_0x477231*(0x2*_0x74d525['e']['Dot'](this['_velocity'],this['_baseToVertex']))-0x2*_0x5c91c5*_0x164fae,_0x13dcd5=_0x477231*(0x1-this['_baseToVertex']['lengthSquared']())+_0x164fae*_0x164fae,(_0x33ddca=_0x4a6f47(_0x1c18bf,_0x2a81ab,_0x13dcd5,_0x6b6486))['found']&&(_0x577d32=(_0x5c91c5*_0x33ddca['root']-_0x164fae)/_0x477231)>=0x0&&_0x577d32<=0x1&&(_0x6b6486=_0x33ddca['root'],_0x36dba8=!0x0,this['_edge']['scaleInPlace'](_0x577d32),_0x4b24a5['addToRef'](this['_edge'],this['_collisionPoint']));}if(_0x36dba8){var _0x157cd9=_0x6b6486*this['_velocity']['length']();(!this['collisionFound']||_0x157cd9=_0x2a956c)_0x166d4b['copyFrom'](_0x29d019);else{var _0x254232=_0x42245d?_0x42245d['collisionMask']:_0x141135['collisionMask'];_0x141135['_initialize'](_0x29d019,_0x4f3610,_0x4214d7);for(var _0x218b7d=_0x42245d&&_0x42245d['surroundingMeshes']||this['_scene']['meshes'],_0x3bbd3a=0x0;_0x3bbd3a<_0x218b7d['length'];_0x3bbd3a++){var _0x1b8cc1=_0x218b7d[_0x3bbd3a];_0x1b8cc1['isEnabled']()&&_0x1b8cc1['checkCollisions']&&_0x1b8cc1['subMeshes']&&_0x1b8cc1!==_0x42245d&&0x0!=(_0x254232&_0x1b8cc1['collisionGroup'])&&_0x1b8cc1['_checkCollision'](_0x141135);}_0x141135['collisionFound']?(0x0===_0x4f3610['x']&&0x0===_0x4f3610['y']&&0x0===_0x4f3610['z']||_0x141135['_getResponse'](_0x29d019,_0x4f3610),_0x4f3610['length']()<=_0x4214d7?_0x166d4b['copyFrom'](_0x29d019):(_0x141135['_retry']++,this['_collideWithWorld'](_0x29d019,_0x4f3610,_0x141135,_0x2a956c,_0x166d4b,_0x42245d))):_0x29d019['addToRef'](_0x4f3610,_0x166d4b);}},_0x1f66c2;}());_0x59370b['a']['CollisionCoordinatorFactory']=function(){return new _0x235a56();};var _0x1fa05e=_0x162675(0x36),_0xa2bfd7=_0x162675(0x72),_0x136422=_0x162675(0x93),_0x52db25=_0x162675(0x67),_0x386a4b=_0x162675(0x2b),_0x16d1ed=_0x162675(0x71),_0xa1ff28=(function(){function _0x3968d0(_0x20767b,_0x39cf58,_0x8ae2e7,_0x3d7cb7,_0x1e0567,_0x4401d2){this['entries']=new Array(),this['_boundingVectors']=new Array(),this['_capacity']=_0x8ae2e7,this['_depth']=_0x3d7cb7,this['_maxDepth']=_0x1e0567,this['_creationFunc']=_0x4401d2,this['_minPoint']=_0x20767b,this['_maxPoint']=_0x39cf58,this['_boundingVectors']['push'](_0x20767b['clone']()),this['_boundingVectors']['push'](_0x39cf58['clone']()),this['_boundingVectors']['push'](_0x20767b['clone']()),this['_boundingVectors'][0x2]['x']=_0x39cf58['x'],this['_boundingVectors']['push'](_0x20767b['clone']()),this['_boundingVectors'][0x3]['y']=_0x39cf58['y'],this['_boundingVectors']['push'](_0x20767b['clone']()),this['_boundingVectors'][0x4]['z']=_0x39cf58['z'],this['_boundingVectors']['push'](_0x39cf58['clone']()),this['_boundingVectors'][0x5]['z']=_0x20767b['z'],this['_boundingVectors']['push'](_0x39cf58['clone']()),this['_boundingVectors'][0x6]['x']=_0x20767b['x'],this['_boundingVectors']['push'](_0x39cf58['clone']()),this['_boundingVectors'][0x7]['y']=_0x20767b['y'];}return Object['defineProperty'](_0x3968d0['prototype'],'capacity',{'get':function(){return this['_capacity'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3968d0['prototype'],'minPoint',{'get':function(){return this['_minPoint'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3968d0['prototype'],'maxPoint',{'get':function(){return this['_maxPoint'];},'enumerable':!0x1,'configurable':!0x0}),_0x3968d0['prototype']['addEntry']=function(_0x476f0c){if(this['blocks'])for(var _0x375f6e=0x0;_0x375f6ethis['capacity']&&this['_depth']-0x1&&this['entries']['splice'](_0x436ac2,0x1);}},_0x3968d0['prototype']['addEntries']=function(_0x1c1176){for(var _0x596875=0x0;_0x596875<_0x1c1176['length'];_0x596875++){var _0x3c3367=_0x1c1176[_0x596875];this['addEntry'](_0x3c3367);}},_0x3968d0['prototype']['select']=function(_0x140c1a,_0x580d58,_0x2d49ef){if(_0x52db25['a']['IsInFrustum'](this['_boundingVectors'],_0x140c1a)){if(this['blocks']){for(var _0x583505=0x0;_0x583505=_0xfac13e['buttons']['length']?_0x3a68ce[_0x1bd6b0]=_0xfac13e['axes'][_0x1bd6b0-_0xfac13e['buttons']['length']]['valueOf']():_0x3a68ce[_0x1bd6b0]=_0xfac13e['buttons'][_0x1bd6b0]['value'];}},_0x2d6899['prototype']['_getGamepadDeviceType']=function(_0x3bf350){return-0x1!==_0x3bf350['indexOf']('054c')?_0x120523['DualShock']:-0x1!==_0x3bf350['indexOf']('Xbox\x20One')||-0x1!==_0x3bf350['search']('Xbox\x20360')||-0x1!==_0x3bf350['search']('xinput')?_0x120523['Xbox']:-0x1!==_0x3bf350['indexOf']('057e')?_0x120523['Switch']:_0x120523['Generic'];},_0x2d6899['_MAX_KEYCODES']=0xff,_0x2d6899['_MAX_POINTER_INPUTS']=0x7,_0x2d6899;}()),_0x2285a0=(function(){function _0x5bdd22(_0x2e2134,_0x2bbdad,_0x1f3f8c){void 0x0===_0x1f3f8c&&(_0x1f3f8c=0x0),this['deviceType']=_0x2bbdad,this['deviceSlot']=_0x1f3f8c,this['onInputChangedObservable']=new _0x6ac1f7['c'](),this['_deviceInputSystem']=_0x2e2134;}return _0x5bdd22['prototype']['getInput']=function(_0x23be5f){return this['_deviceInputSystem']['pollInput'](this['deviceType'],this['deviceSlot'],_0x23be5f);},_0x5bdd22;}()),_0x195d3a=(function(){function _0xc75169(_0x4d84ab){var _0x2f5504=this;this['onDeviceConnectedObservable']=new _0x6ac1f7['c'](function(_0x2f12a9){_0x2f5504['getDevices']()['forEach'](function(_0x59e7a9){_0x2f5504['onDeviceConnectedObservable']['notifyObserver'](_0x2f12a9,_0x59e7a9);});}),this['onDeviceDisconnectedObservable']=new _0x6ac1f7['c']();var _0x107b9e=Object['keys'](_0x120523)['length']/0x2;this['_devices']=new Array(_0x107b9e),this['_firstDevice']=new Array(_0x107b9e),this['_deviceInputSystem']=_0x1e32b7['Create'](_0x4d84ab),this['_deviceInputSystem']['onDeviceConnected']=function(_0x41fca0,_0x1fd444){_0x2f5504['_addDevice'](_0x41fca0,_0x1fd444),_0x2f5504['onDeviceConnectedObservable']['notifyObservers'](_0x2f5504['getDeviceSource'](_0x41fca0,_0x1fd444));},this['_deviceInputSystem']['onDeviceDisconnected']=function(_0x1ba591,_0x2eeb0c){var _0x3e9330=_0x2f5504['getDeviceSource'](_0x1ba591,_0x2eeb0c);_0x2f5504['_removeDevice'](_0x1ba591,_0x2eeb0c),_0x2f5504['onDeviceDisconnectedObservable']['notifyObservers'](_0x3e9330);},this['_deviceInputSystem']['onInputChanged']||(this['_deviceInputSystem']['onInputChanged']=function(_0x4196e4,_0x19616c,_0x4b5bc4,_0x337e5e,_0xbf5c7a){var _0x14b671;null===(_0x14b671=_0x2f5504['getDeviceSource'](_0x4196e4,_0x19616c))||void 0x0===_0x14b671||_0x14b671['onInputChangedObservable']['notifyObservers']({'inputIndex':_0x4b5bc4,'previousState':_0x337e5e,'currentState':_0xbf5c7a});});}return _0xc75169['prototype']['getDeviceSource']=function(_0x2028a3,_0x1de271){if(void 0x0===_0x1de271){if(void 0x0===this['_firstDevice'][_0x2028a3])return null;_0x1de271=this['_firstDevice'][_0x2028a3];}return this['_devices'][_0x2028a3]&&void 0x0!==this['_devices'][_0x2028a3][_0x1de271]?this['_devices'][_0x2028a3][_0x1de271]:null;},_0xc75169['prototype']['getDeviceSources']=function(_0x283312){return this['_devices'][_0x283312]['filter'](function(_0x30dec0){return!!_0x30dec0;});},_0xc75169['prototype']['getDevices']=function(){var _0x494f2e=new Array();return this['_devices']['forEach'](function(_0xc3eda4){_0x494f2e['push']['apply'](_0x494f2e,_0xc3eda4);}),_0x494f2e;},_0xc75169['prototype']['dispose']=function(){this['onDeviceConnectedObservable']['clear'](),this['onDeviceDisconnectedObservable']['clear'](),this['_deviceInputSystem']['dispose']();},_0xc75169['prototype']['_addDevice']=function(_0xc20d0a,_0x217231){this['_devices'][_0xc20d0a]||(this['_devices'][_0xc20d0a]=new Array()),this['_devices'][_0xc20d0a][_0x217231]||(this['_devices'][_0xc20d0a][_0x217231]=new _0x2285a0(this['_deviceInputSystem'],_0xc20d0a,_0x217231),this['_updateFirstDevices'](_0xc20d0a));},_0xc75169['prototype']['_removeDevice']=function(_0x4b47de,_0x123cb2){delete this['_devices'][_0x4b47de][_0x123cb2],this['_updateFirstDevices'](_0x4b47de);},_0xc75169['prototype']['_updateFirstDevices']=function(_0x148805){switch(_0x148805){case _0x120523['Keyboard']:case _0x120523['Mouse']:this['_firstDevice'][_0x148805]=0x0;break;case _0x120523['Touch']:case _0x120523['DualShock']:case _0x120523['Xbox']:case _0x120523['Switch']:case _0x120523['Generic']:var _0x168c3b=this['_devices'][_0x148805];delete this['_firstDevice'][_0x148805];for(var _0x5145fb=0x0;_0x5145fb<_0x168c3b['length'];_0x5145fb++)if(_0x168c3b[_0x5145fb]){this['_firstDevice'][_0x148805]=_0x5145fb;break;}}},_0xc75169;}()),_0x813e33=_0x162675(0xa8),_0x17597a=(_0x162675(0x7b),function(){this['_timeElapsedQueryEnded']=!0x1;}),_0x286eca=function(){this['occlusionInternalRetryCounter']=0x0,this['isOcclusionQueryInProgress']=!0x1,this['isOccluded']=!0x1,this['occlusionRetryCount']=-0x1,this['occlusionType']=_0x40d22e['a']['OCCLUSION_TYPE_NONE'],this['occlusionQueryAlgorithmType']=_0x40d22e['a']['OCCLUSION_ALGORITHM_TYPE_CONSERVATIVE'];};_0x300b38['a']['prototype']['createQuery']=function(){return this['_gl']['createQuery']();},_0x300b38['a']['prototype']['deleteQuery']=function(_0x3467fe){return this['_gl']['deleteQuery'](_0x3467fe),this;},_0x300b38['a']['prototype']['isQueryResultAvailable']=function(_0x23b7d4){return this['_gl']['getQueryParameter'](_0x23b7d4,this['_gl']['QUERY_RESULT_AVAILABLE']);},_0x300b38['a']['prototype']['getQueryResult']=function(_0x2522b6){return this['_gl']['getQueryParameter'](_0x2522b6,this['_gl']['QUERY_RESULT']);},_0x300b38['a']['prototype']['beginOcclusionQuery']=function(_0x28a0ad,_0x5cc5fc){var _0x309e8d=this['_getGlAlgorithmType'](_0x28a0ad);return this['_gl']['beginQuery'](_0x309e8d,_0x5cc5fc),this;},_0x300b38['a']['prototype']['endOcclusionQuery']=function(_0x1b13ad){var _0x22bf67=this['_getGlAlgorithmType'](_0x1b13ad);return this['_gl']['endQuery'](_0x22bf67),this;},_0x300b38['a']['prototype']['_createTimeQuery']=function(){var _0x509856=this['getCaps']()['timerQuery'];return _0x509856['createQueryEXT']?_0x509856['createQueryEXT']():this['createQuery']();},_0x300b38['a']['prototype']['_deleteTimeQuery']=function(_0x5863ee){var _0x2716d9=this['getCaps']()['timerQuery'];_0x2716d9['deleteQueryEXT']?_0x2716d9['deleteQueryEXT'](_0x5863ee):this['deleteQuery'](_0x5863ee);},_0x300b38['a']['prototype']['_getTimeQueryResult']=function(_0x259f3a){var _0x5b9ce=this['getCaps']()['timerQuery'];return _0x5b9ce['getQueryObjectEXT']?_0x5b9ce['getQueryObjectEXT'](_0x259f3a,_0x5b9ce['QUERY_RESULT_EXT']):this['getQueryResult'](_0x259f3a);},_0x300b38['a']['prototype']['_getTimeQueryAvailability']=function(_0x169f7e){var _0x220711=this['getCaps']()['timerQuery'];return _0x220711['getQueryObjectEXT']?_0x220711['getQueryObjectEXT'](_0x169f7e,_0x220711['QUERY_RESULT_AVAILABLE_EXT']):this['isQueryResultAvailable'](_0x169f7e);},_0x300b38['a']['prototype']['startTimeQuery']=function(){var _0x4a55b7=this['getCaps'](),_0x4a7ccb=_0x4a55b7['timerQuery'];if(!_0x4a7ccb)return null;var _0x55d845=new _0x17597a();if(this['_gl']['getParameter'](_0x4a7ccb['GPU_DISJOINT_EXT']),_0x4a55b7['canUseTimestampForTimerQuery'])_0x55d845['_startTimeQuery']=this['_createTimeQuery'](),_0x4a7ccb['queryCounterEXT'](_0x55d845['_startTimeQuery'],_0x4a7ccb['TIMESTAMP_EXT']);else{if(this['_currentNonTimestampToken'])return this['_currentNonTimestampToken'];_0x55d845['_timeElapsedQuery']=this['_createTimeQuery'](),_0x4a7ccb['beginQueryEXT']?_0x4a7ccb['beginQueryEXT'](_0x4a7ccb['TIME_ELAPSED_EXT'],_0x55d845['_timeElapsedQuery']):this['_gl']['beginQuery'](_0x4a7ccb['TIME_ELAPSED_EXT'],_0x55d845['_timeElapsedQuery']),this['_currentNonTimestampToken']=_0x55d845;}return _0x55d845;},_0x300b38['a']['prototype']['endTimeQuery']=function(_0x1ffff0){var _0x51af94=this['getCaps'](),_0x57ada2=_0x51af94['timerQuery'];if(!_0x57ada2||!_0x1ffff0)return-0x1;if(_0x51af94['canUseTimestampForTimerQuery']){if(!_0x1ffff0['_startTimeQuery'])return-0x1;_0x1ffff0['_endTimeQuery']||(_0x1ffff0['_endTimeQuery']=this['_createTimeQuery'](),_0x57ada2['queryCounterEXT'](_0x1ffff0['_endTimeQuery'],_0x57ada2['TIMESTAMP_EXT']));}else{if(!_0x1ffff0['_timeElapsedQueryEnded']){if(!_0x1ffff0['_timeElapsedQuery'])return-0x1;_0x57ada2['endQueryEXT']?_0x57ada2['endQueryEXT'](_0x57ada2['TIME_ELAPSED_EXT']):this['_gl']['endQuery'](_0x57ada2['TIME_ELAPSED_EXT']),_0x1ffff0['_timeElapsedQueryEnded']=!0x0;}}var _0x11962d=this['_gl']['getParameter'](_0x57ada2['GPU_DISJOINT_EXT']),_0x2faf37=!0x1;if(_0x1ffff0['_endTimeQuery']?_0x2faf37=this['_getTimeQueryAvailability'](_0x1ffff0['_endTimeQuery']):_0x1ffff0['_timeElapsedQuery']&&(_0x2faf37=this['_getTimeQueryAvailability'](_0x1ffff0['_timeElapsedQuery'])),_0x2faf37&&!_0x11962d){var _0x3aaf74=0x0;if(_0x51af94['canUseTimestampForTimerQuery']){if(!_0x1ffff0['_startTimeQuery']||!_0x1ffff0['_endTimeQuery'])return-0x1;var _0x2973e7=this['_getTimeQueryResult'](_0x1ffff0['_startTimeQuery']);_0x3aaf74=this['_getTimeQueryResult'](_0x1ffff0['_endTimeQuery'])-_0x2973e7,this['_deleteTimeQuery'](_0x1ffff0['_startTimeQuery']),this['_deleteTimeQuery'](_0x1ffff0['_endTimeQuery']),_0x1ffff0['_startTimeQuery']=null,_0x1ffff0['_endTimeQuery']=null;}else{if(!_0x1ffff0['_timeElapsedQuery'])return-0x1;_0x3aaf74=this['_getTimeQueryResult'](_0x1ffff0['_timeElapsedQuery']),this['_deleteTimeQuery'](_0x1ffff0['_timeElapsedQuery']),_0x1ffff0['_timeElapsedQuery']=null,_0x1ffff0['_timeElapsedQueryEnded']=!0x1,this['_currentNonTimestampToken']=null;}return _0x3aaf74;}return-0x1;},_0x300b38['a']['prototype']['_getGlAlgorithmType']=function(_0x16b267){return _0x16b267===_0x40d22e['a']['OCCLUSION_ALGORITHM_TYPE_CONSERVATIVE']?this['_gl']['ANY_SAMPLES_PASSED_CONSERVATIVE']:this['_gl']['ANY_SAMPLES_PASSED'];},Object['defineProperty'](_0x40d22e['a']['prototype'],'isOcclusionQueryInProgress',{'get':function(){return this['_occlusionDataStorage']['isOcclusionQueryInProgress'];},'set':function(_0x3cfd4f){this['_occlusionDataStorage']['isOcclusionQueryInProgress']=_0x3cfd4f;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x40d22e['a']['prototype'],'_occlusionDataStorage',{'get':function(){return this['__occlusionDataStorage']||(this['__occlusionDataStorage']=new _0x286eca()),this['__occlusionDataStorage'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x40d22e['a']['prototype'],'isOccluded',{'get':function(){return this['_occlusionDataStorage']['isOccluded'];},'set':function(_0x2553da){this['_occlusionDataStorage']['isOccluded']=_0x2553da;},'enumerable':!0x0,'configurable':!0x0}),Object['defineProperty'](_0x40d22e['a']['prototype'],'occlusionQueryAlgorithmType',{'get':function(){return this['_occlusionDataStorage']['occlusionQueryAlgorithmType'];},'set':function(_0x385af7){this['_occlusionDataStorage']['occlusionQueryAlgorithmType']=_0x385af7;},'enumerable':!0x0,'configurable':!0x0}),Object['defineProperty'](_0x40d22e['a']['prototype'],'occlusionType',{'get':function(){return this['_occlusionDataStorage']['occlusionType'];},'set':function(_0x6d073a){this['_occlusionDataStorage']['occlusionType']=_0x6d073a;},'enumerable':!0x0,'configurable':!0x0}),Object['defineProperty'](_0x40d22e['a']['prototype'],'occlusionRetryCount',{'get':function(){return this['_occlusionDataStorage']['occlusionRetryCount'];},'set':function(_0x348965){this['_occlusionDataStorage']['occlusionRetryCount']=_0x348965;},'enumerable':!0x0,'configurable':!0x0}),_0x40d22e['a']['prototype']['_checkOcclusionQuery']=function(){var _0x5363cd=this['_occlusionDataStorage'];if(_0x5363cd['occlusionType']===_0x40d22e['a']['OCCLUSION_TYPE_NONE'])return _0x5363cd['isOccluded']=!0x1,!0x1;var _0x1715e5=this['getEngine']();if(_0x1715e5['webGLVersion']<0x2)return _0x5363cd['isOccluded']=!0x1,!0x1;if(!_0x1715e5['isQueryResultAvailable'])return _0x5363cd['isOccluded']=!0x1,!0x1;if(this['isOcclusionQueryInProgress']&&this['_occlusionQuery']){if(_0x1715e5['isQueryResultAvailable'](this['_occlusionQuery'])){var _0x366b2b=_0x1715e5['getQueryResult'](this['_occlusionQuery']);_0x5363cd['isOcclusionQueryInProgress']=!0x1,_0x5363cd['occlusionInternalRetryCounter']=0x0,_0x5363cd['isOccluded']=0x1!==_0x366b2b;}else{if(_0x5363cd['occlusionInternalRetryCounter']++,!(-0x1!==_0x5363cd['occlusionRetryCount']&&_0x5363cd['occlusionInternalRetryCounter']>_0x5363cd['occlusionRetryCount']))return!0x1;_0x5363cd['isOcclusionQueryInProgress']=!0x1,_0x5363cd['occlusionInternalRetryCounter']=0x0,_0x5363cd['isOccluded']=_0x5363cd['occlusionType']!==_0x40d22e['a']['OCCLUSION_TYPE_OPTIMISTIC']&&_0x5363cd['isOccluded'];}}var _0x4c71bc=this['getScene']();if(_0x4c71bc['getBoundingBoxRenderer']){var _0x14e9bd=_0x4c71bc['getBoundingBoxRenderer']();this['_occlusionQuery']||(this['_occlusionQuery']=_0x1715e5['createQuery']()),_0x1715e5['beginOcclusionQuery'](_0x5363cd['occlusionQueryAlgorithmType'],this['_occlusionQuery']),_0x14e9bd['renderOcclusionBoundingBox'](this),_0x1715e5['endOcclusionQuery'](_0x5363cd['occlusionQueryAlgorithmType']),this['_occlusionDataStorage']['isOcclusionQueryInProgress']=!0x0;}return _0x5363cd['isOccluded'];};var _0x215eb9=!0x0;_0x300b38['a']['prototype']['createTransformFeedback']=function(){return this['_gl']['createTransformFeedback']();},_0x300b38['a']['prototype']['deleteTransformFeedback']=function(_0x7a67aa){this['_gl']['deleteTransformFeedback'](_0x7a67aa);},_0x300b38['a']['prototype']['bindTransformFeedback']=function(_0x2780e0){this['_gl']['bindTransformFeedback'](this['_gl']['TRANSFORM_FEEDBACK'],_0x2780e0);},_0x300b38['a']['prototype']['beginTransformFeedback']=function(_0x27ac98){void 0x0===_0x27ac98&&(_0x27ac98=!0x0),this['_gl']['beginTransformFeedback'](_0x27ac98?this['_gl']['POINTS']:this['_gl']['TRIANGLES']);},_0x300b38['a']['prototype']['endTransformFeedback']=function(){this['_gl']['endTransformFeedback']();},_0x300b38['a']['prototype']['setTranformFeedbackVaryings']=function(_0x57f1b9,_0x54a897){this['_gl']['transformFeedbackVaryings'](_0x57f1b9,_0x54a897,this['_gl']['INTERLEAVED_ATTRIBS']);},_0x300b38['a']['prototype']['bindTransformFeedbackBuffer']=function(_0x431dcb){this['_gl']['bindBufferBase'](this['_gl']['TRANSFORM_FEEDBACK_BUFFER'],0x0,_0x431dcb?_0x431dcb['underlyingResource']:null);},_0x162675(0x7e),(_0x26966b['a']['prototype']['updateVideoTexture']=function(_0x59237c,_0x2313af,_0x5c8967){if(_0x59237c&&!_0x59237c['_isDisabled']){var _0x2025ba=this['_bindTextureDirectly'](this['_gl']['TEXTURE_2D'],_0x59237c,!0x0);this['_unpackFlipY'](!_0x5c8967);try{if(void 0x0===this['_videoTextureSupported']&&(this['_gl']['getError'](),this['_gl']['texImage2D'](this['_gl']['TEXTURE_2D'],0x0,this['_gl']['RGBA'],this['_gl']['RGBA'],this['_gl']['UNSIGNED_BYTE'],_0x2313af),0x0!==this['_gl']['getError']()?this['_videoTextureSupported']=!0x1:this['_videoTextureSupported']=!0x0),this['_videoTextureSupported'])this['_gl']['texImage2D'](this['_gl']['TEXTURE_2D'],0x0,this['_gl']['RGBA'],this['_gl']['RGBA'],this['_gl']['UNSIGNED_BYTE'],_0x2313af);else{if(!_0x59237c['_workingCanvas']){_0x59237c['_workingCanvas']=_0x27137b['a']['CreateCanvas'](_0x59237c['width'],_0x59237c['height']);var _0x48419c=_0x59237c['_workingCanvas']['getContext']('2d');if(!_0x48419c)throw new Error('Unable\x20to\x20get\x202d\x20context');_0x59237c['_workingContext']=_0x48419c,_0x59237c['_workingCanvas']['width']=_0x59237c['width'],_0x59237c['_workingCanvas']['height']=_0x59237c['height'];}_0x59237c['_workingContext']['clearRect'](0x0,0x0,_0x59237c['width'],_0x59237c['height']),_0x59237c['_workingContext']['drawImage'](_0x2313af,0x0,0x0,_0x2313af['videoWidth'],_0x2313af['videoHeight'],0x0,0x0,_0x59237c['width'],_0x59237c['height']),this['_gl']['texImage2D'](this['_gl']['TEXTURE_2D'],0x0,this['_gl']['RGBA'],this['_gl']['RGBA'],this['_gl']['UNSIGNED_BYTE'],_0x59237c['_workingCanvas']);}_0x59237c['generateMipMaps']&&this['_gl']['generateMipmap'](this['_gl']['TEXTURE_2D']),_0x2025ba||this['_bindTextureDirectly'](this['_gl']['TEXTURE_2D'],null),_0x59237c['isReady']=!0x0;}catch(_0x4182a6){_0x59237c['_isDisabled']=!0x0;}}},_0x26966b['a']['prototype']['restoreSingleAttachment']=function(){var _0x1eb190=this['_gl'];this['bindAttachments']([_0x1eb190['BACK']]);},_0x26966b['a']['prototype']['buildTextureLayout']=function(_0x77572f){for(var _0x2a5ace=this['_gl'],_0x291682=[],_0x3518b5=0x0;_0x3518b5<_0x77572f['length'];_0x3518b5++)_0x77572f[_0x3518b5]?_0x291682['push'](_0x2a5ace['COLOR_ATTACHMENT'+_0x3518b5]):_0x291682['push'](_0x2a5ace['NONE']);return _0x291682;},_0x26966b['a']['prototype']['bindAttachments']=function(_0x321f2f){this['_gl']['drawBuffers'](_0x321f2f);},_0x26966b['a']['prototype']['unBindMultiColorAttachmentFramebuffer']=function(_0x167cbb,_0xad097a,_0x1fcc1){void 0x0===_0xad097a&&(_0xad097a=!0x1),this['_currentRenderTarget']=null;var _0x5e4836=this['_gl'],_0x1d8db5=_0x167cbb[0x0]['_attachments'],_0x517e08=_0x1d8db5['length'];if(_0x167cbb[0x0]['_MSAAFramebuffer']){_0x5e4836['bindFramebuffer'](_0x5e4836['READ_FRAMEBUFFER'],_0x167cbb[0x0]['_MSAAFramebuffer']),_0x5e4836['bindFramebuffer'](_0x5e4836['DRAW_FRAMEBUFFER'],_0x167cbb[0x0]['_framebuffer']);for(var _0x199d2a=0x0;_0x199d2a<_0x517e08;_0x199d2a++){for(var _0x192c00=_0x167cbb[_0x199d2a],_0x2c4f75=0x0;_0x2c4f75<_0x517e08;_0x2c4f75++)_0x1d8db5[_0x2c4f75]=_0x5e4836['NONE'];_0x1d8db5[_0x199d2a]=_0x5e4836[this['webGLVersion']>0x1?'COLOR_ATTACHMENT'+_0x199d2a:'COLOR_ATTACHMENT'+_0x199d2a+'_WEBGL'],_0x5e4836['readBuffer'](_0x1d8db5[_0x199d2a]),_0x5e4836['drawBuffers'](_0x1d8db5),_0x5e4836['blitFramebuffer'](0x0,0x0,_0x192c00['width'],_0x192c00['height'],0x0,0x0,_0x192c00['width'],_0x192c00['height'],_0x5e4836['COLOR_BUFFER_BIT'],_0x5e4836['NEAREST']);}for(_0x199d2a=0x0;_0x199d2a<_0x517e08;_0x199d2a++)_0x1d8db5[_0x199d2a]=_0x5e4836[this['webGLVersion']>0x1?'COLOR_ATTACHMENT'+_0x199d2a:'COLOR_ATTACHMENT'+_0x199d2a+'_WEBGL'];_0x5e4836['drawBuffers'](_0x1d8db5);}for(_0x199d2a=0x0;_0x199d2a<_0x517e08;_0x199d2a++){!(_0x192c00=_0x167cbb[_0x199d2a])['generateMipMaps']||_0xad097a||_0x192c00['isCube']||(this['_bindTextureDirectly'](_0x5e4836['TEXTURE_2D'],_0x192c00,!0x0),_0x5e4836['generateMipmap'](_0x5e4836['TEXTURE_2D']),this['_bindTextureDirectly'](_0x5e4836['TEXTURE_2D'],null));}_0x1fcc1&&(_0x167cbb[0x0]['_MSAAFramebuffer']&&this['_bindUnboundFramebuffer'](_0x167cbb[0x0]['_framebuffer']),_0x1fcc1()),this['_bindUnboundFramebuffer'](null);},_0x26966b['a']['prototype']['createMultipleRenderTarget']=function(_0x472b18,_0x192239){var _0x146196=!0x1,_0x3236e2=!0x0,_0x4ff1e5=!0x1,_0x93d2ac=!0x1,_0x5e5382=0x1,_0x5df684=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'],_0x2439e1=_0x2103ba['a']['TEXTURE_TRILINEAR_SAMPLINGMODE'],_0x6159c4=new Array(),_0x3be3e6=new Array();void 0x0!==_0x192239&&(_0x146196=void 0x0!==_0x192239['generateMipMaps']&&_0x192239['generateMipMaps'],_0x3236e2=void 0x0===_0x192239['generateDepthBuffer']||_0x192239['generateDepthBuffer'],_0x4ff1e5=void 0x0!==_0x192239['generateStencilBuffer']&&_0x192239['generateStencilBuffer'],_0x93d2ac=void 0x0!==_0x192239['generateDepthTexture']&&_0x192239['generateDepthTexture'],_0x5e5382=_0x192239['textureCount']||0x1,_0x192239['types']&&(_0x6159c4=_0x192239['types']),_0x192239['samplingModes']&&(_0x3be3e6=_0x192239['samplingModes']));var _0x1be8a1=this['_gl'],_0x5a446a=_0x1be8a1['createFramebuffer']();this['_bindUnboundFramebuffer'](_0x5a446a);for(var _0xc7888a=_0x472b18['width']||_0x472b18,_0x2b88a5=_0x472b18['height']||_0x472b18,_0x10f07f=[],_0x394d42=[],_0x17a6a1=this['_setupFramebufferDepthAttachments'](_0x4ff1e5,_0x3236e2,_0xc7888a,_0x2b88a5),_0x57379f=0x0;_0x57379f<_0x5e5382;_0x57379f++){var _0x3b2c9e=_0x3be3e6[_0x57379f]||_0x2439e1,_0x30c5da=_0x6159c4[_0x57379f]||_0x5df684;(_0x30c5da!==_0x2103ba['a']['TEXTURETYPE_FLOAT']||this['_caps']['textureFloatLinearFiltering'])&&(_0x30c5da!==_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT']||this['_caps']['textureHalfFloatLinearFiltering'])||(_0x3b2c9e=_0x2103ba['a']['TEXTURE_NEAREST_SAMPLINGMODE']);var _0x120221=this['_getSamplingParameters'](_0x3b2c9e,_0x146196);_0x30c5da!==_0x2103ba['a']['TEXTURETYPE_FLOAT']||this['_caps']['textureFloat']||(_0x30c5da=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'],_0x75193d['a']['Warn']('Float\x20textures\x20are\x20not\x20supported.\x20Render\x20target\x20forced\x20to\x20TEXTURETYPE_UNSIGNED_BYTE\x20type'));var _0x5bffca=new _0x21ea74['a'](this,_0x21ea74['b']['MultiRenderTarget']),_0x46006e=_0x1be8a1[this['webGLVersion']>0x1?'COLOR_ATTACHMENT'+_0x57379f:'COLOR_ATTACHMENT'+_0x57379f+'_WEBGL'];_0x10f07f['push'](_0x5bffca),_0x394d42['push'](_0x46006e),_0x1be8a1['activeTexture'](_0x1be8a1['TEXTURE'+_0x57379f]),_0x1be8a1['bindTexture'](_0x1be8a1['TEXTURE_2D'],_0x5bffca['_webGLTexture']),_0x1be8a1['texParameteri'](_0x1be8a1['TEXTURE_2D'],_0x1be8a1['TEXTURE_MAG_FILTER'],_0x120221['mag']),_0x1be8a1['texParameteri'](_0x1be8a1['TEXTURE_2D'],_0x1be8a1['TEXTURE_MIN_FILTER'],_0x120221['min']),_0x1be8a1['texParameteri'](_0x1be8a1['TEXTURE_2D'],_0x1be8a1['TEXTURE_WRAP_S'],_0x1be8a1['CLAMP_TO_EDGE']),_0x1be8a1['texParameteri'](_0x1be8a1['TEXTURE_2D'],_0x1be8a1['TEXTURE_WRAP_T'],_0x1be8a1['CLAMP_TO_EDGE']),_0x1be8a1['texImage2D'](_0x1be8a1['TEXTURE_2D'],0x0,this['_getRGBABufferInternalSizedFormat'](_0x30c5da),_0xc7888a,_0x2b88a5,0x0,_0x1be8a1['RGBA'],this['_getWebGLTextureType'](_0x30c5da),null),_0x1be8a1['framebufferTexture2D'](_0x1be8a1['DRAW_FRAMEBUFFER'],_0x46006e,_0x1be8a1['TEXTURE_2D'],_0x5bffca['_webGLTexture'],0x0),_0x146196&&this['_gl']['generateMipmap'](this['_gl']['TEXTURE_2D']),this['_bindTextureDirectly'](_0x1be8a1['TEXTURE_2D'],null),_0x5bffca['_framebuffer']=_0x5a446a,_0x5bffca['_depthStencilBuffer']=_0x17a6a1,_0x5bffca['baseWidth']=_0xc7888a,_0x5bffca['baseHeight']=_0x2b88a5,_0x5bffca['width']=_0xc7888a,_0x5bffca['height']=_0x2b88a5,_0x5bffca['isReady']=!0x0,_0x5bffca['samples']=0x1,_0x5bffca['generateMipMaps']=_0x146196,_0x5bffca['samplingMode']=_0x3b2c9e,_0x5bffca['type']=_0x30c5da,_0x5bffca['_generateDepthBuffer']=_0x3236e2,_0x5bffca['_generateStencilBuffer']=_0x4ff1e5,_0x5bffca['_attachments']=_0x394d42,_0x5bffca['_textureArray']=_0x10f07f,this['_internalTexturesCache']['push'](_0x5bffca);}if(_0x93d2ac&&this['_caps']['depthTextureExtension']){var _0x29cdb8=new _0x21ea74['a'](this,_0x21ea74['b']['MultiRenderTarget']);_0x1be8a1['activeTexture'](_0x1be8a1['TEXTURE0']),_0x1be8a1['bindTexture'](_0x1be8a1['TEXTURE_2D'],_0x29cdb8['_webGLTexture']),_0x1be8a1['texParameteri'](_0x1be8a1['TEXTURE_2D'],_0x1be8a1['TEXTURE_MAG_FILTER'],_0x1be8a1['NEAREST']),_0x1be8a1['texParameteri'](_0x1be8a1['TEXTURE_2D'],_0x1be8a1['TEXTURE_MIN_FILTER'],_0x1be8a1['NEAREST']),_0x1be8a1['texParameteri'](_0x1be8a1['TEXTURE_2D'],_0x1be8a1['TEXTURE_WRAP_S'],_0x1be8a1['CLAMP_TO_EDGE']),_0x1be8a1['texParameteri'](_0x1be8a1['TEXTURE_2D'],_0x1be8a1['TEXTURE_WRAP_T'],_0x1be8a1['CLAMP_TO_EDGE']),_0x1be8a1['texImage2D'](_0x1be8a1['TEXTURE_2D'],0x0,this['webGLVersion']<0x2?_0x1be8a1['DEPTH_COMPONENT']:_0x1be8a1['DEPTH_COMPONENT16'],_0xc7888a,_0x2b88a5,0x0,_0x1be8a1['DEPTH_COMPONENT'],_0x1be8a1['UNSIGNED_SHORT'],null),_0x1be8a1['framebufferTexture2D'](_0x1be8a1['FRAMEBUFFER'],_0x1be8a1['DEPTH_ATTACHMENT'],_0x1be8a1['TEXTURE_2D'],_0x29cdb8['_webGLTexture'],0x0),_0x29cdb8['_framebuffer']=_0x5a446a,_0x29cdb8['baseWidth']=_0xc7888a,_0x29cdb8['baseHeight']=_0x2b88a5,_0x29cdb8['width']=_0xc7888a,_0x29cdb8['height']=_0x2b88a5,_0x29cdb8['isReady']=!0x0,_0x29cdb8['samples']=0x1,_0x29cdb8['generateMipMaps']=_0x146196,_0x29cdb8['samplingMode']=_0x1be8a1['NEAREST'],_0x29cdb8['_generateDepthBuffer']=_0x3236e2,_0x29cdb8['_generateStencilBuffer']=_0x4ff1e5,_0x10f07f['push'](_0x29cdb8),this['_internalTexturesCache']['push'](_0x29cdb8);}return _0x1be8a1['drawBuffers'](_0x394d42),this['_bindUnboundFramebuffer'](null),this['resetTextureCache'](),_0x10f07f;},_0x26966b['a']['prototype']['updateMultipleRenderTargetTextureSampleCount']=function(_0x1f9ad5,_0x1a1f2a){if(this['webGLVersion']<0x2||!_0x1f9ad5)return 0x1;if(_0x1f9ad5[0x0]['samples']===_0x1a1f2a)return _0x1a1f2a;var _0x57b2e7=_0x1f9ad5[0x0]['_attachments']['length'];if(0x0===_0x57b2e7)return 0x1;var _0x2424a2=this['_gl'];_0x1a1f2a=Math['min'](_0x1a1f2a,this['getCaps']()['maxMSAASamples']),_0x1f9ad5[0x0]['_depthStencilBuffer']&&(_0x2424a2['deleteRenderbuffer'](_0x1f9ad5[0x0]['_depthStencilBuffer']),_0x1f9ad5[0x0]['_depthStencilBuffer']=null),_0x1f9ad5[0x0]['_MSAAFramebuffer']&&(_0x2424a2['deleteFramebuffer'](_0x1f9ad5[0x0]['_MSAAFramebuffer']),_0x1f9ad5[0x0]['_MSAAFramebuffer']=null);for(var _0x586335=0x0;_0x586335<_0x57b2e7;_0x586335++)_0x1f9ad5[_0x586335]['_MSAARenderBuffer']&&(_0x2424a2['deleteRenderbuffer'](_0x1f9ad5[_0x586335]['_MSAARenderBuffer']),_0x1f9ad5[_0x586335]['_MSAARenderBuffer']=null);if(_0x1a1f2a>0x1&&_0x2424a2['renderbufferStorageMultisample']){var _0x13f3b4=_0x2424a2['createFramebuffer']();if(!_0x13f3b4)throw new Error('Unable\x20to\x20create\x20multi\x20sampled\x20framebuffer');this['_bindUnboundFramebuffer'](_0x13f3b4);var _0x7d3af=this['_setupFramebufferDepthAttachments'](_0x1f9ad5[0x0]['_generateStencilBuffer'],_0x1f9ad5[0x0]['_generateDepthBuffer'],_0x1f9ad5[0x0]['width'],_0x1f9ad5[0x0]['height'],_0x1a1f2a),_0x5d8676=[];for(_0x586335=0x0;_0x586335<_0x57b2e7;_0x586335++){var _0x5cd0a1=_0x1f9ad5[_0x586335],_0x2b11ed=_0x2424a2[this['webGLVersion']>0x1?'COLOR_ATTACHMENT'+_0x586335:'COLOR_ATTACHMENT'+_0x586335+'_WEBGL'],_0x1f6df4=_0x2424a2['createRenderbuffer']();if(!_0x1f6df4)throw new Error('Unable\x20to\x20create\x20multi\x20sampled\x20framebuffer');_0x2424a2['bindRenderbuffer'](_0x2424a2['RENDERBUFFER'],_0x1f6df4),_0x2424a2['renderbufferStorageMultisample'](_0x2424a2['RENDERBUFFER'],_0x1a1f2a,this['_getRGBAMultiSampleBufferFormat'](_0x5cd0a1['type']),_0x5cd0a1['width'],_0x5cd0a1['height']),_0x2424a2['framebufferRenderbuffer'](_0x2424a2['FRAMEBUFFER'],_0x2b11ed,_0x2424a2['RENDERBUFFER'],_0x1f6df4),_0x5cd0a1['_MSAAFramebuffer']=_0x13f3b4,_0x5cd0a1['_MSAARenderBuffer']=_0x1f6df4,_0x5cd0a1['samples']=_0x1a1f2a,_0x5cd0a1['_depthStencilBuffer']=_0x7d3af,_0x2424a2['bindRenderbuffer'](_0x2424a2['RENDERBUFFER'],null),_0x5d8676['push'](_0x2b11ed);}_0x2424a2['drawBuffers'](_0x5d8676);}else this['_bindUnboundFramebuffer'](_0x1f9ad5[0x0]['_framebuffer']);return this['_bindUnboundFramebuffer'](null),_0x1a1f2a;});var _0x14fdee=_0x162675(0x38);_0x26966b['a']['prototype']['_createDepthStencilCubeTexture']=function(_0x1fde63,_0x873ec2){var _0x249072=new _0x21ea74['a'](this,_0x21ea74['b']['Unknown']);if(_0x249072['isCube']=!0x0,0x1===this['webGLVersion'])return _0x75193d['a']['Error']('Depth\x20cube\x20texture\x20is\x20not\x20supported\x20by\x20WebGL\x201.'),_0x249072;var _0x406e4c=Object(_0x18e13d['a'])({'bilinearFiltering':!0x1,'comparisonFunction':0x0,'generateStencil':!0x1},_0x873ec2),_0x7556a2=this['_gl'];this['_bindTextureDirectly'](_0x7556a2['TEXTURE_CUBE_MAP'],_0x249072,!0x0),this['_setupDepthStencilTexture'](_0x249072,_0x1fde63,_0x406e4c['generateStencil'],_0x406e4c['bilinearFiltering'],_0x406e4c['comparisonFunction']);for(var _0x33e976=0x0;_0x33e976<0x6;_0x33e976++)_0x406e4c['generateStencil']?_0x7556a2['texImage2D'](_0x7556a2['TEXTURE_CUBE_MAP_POSITIVE_X']+_0x33e976,0x0,_0x7556a2['DEPTH24_STENCIL8'],_0x1fde63,_0x1fde63,0x0,_0x7556a2['DEPTH_STENCIL'],_0x7556a2['UNSIGNED_INT_24_8'],null):_0x7556a2['texImage2D'](_0x7556a2['TEXTURE_CUBE_MAP_POSITIVE_X']+_0x33e976,0x0,_0x7556a2['DEPTH_COMPONENT24'],_0x1fde63,_0x1fde63,0x0,_0x7556a2['DEPTH_COMPONENT'],_0x7556a2['UNSIGNED_INT'],null);return this['_bindTextureDirectly'](_0x7556a2['TEXTURE_CUBE_MAP'],null),_0x249072;},_0x26966b['a']['prototype']['_partialLoadFile']=function(_0x1006b2,_0x2b2ace,_0x5baaf6,_0x3273fc,_0x52d281){void 0x0===_0x52d281&&(_0x52d281=null),this['_loadFile'](_0x1006b2,function(_0x222f1e){_0x5baaf6[_0x2b2ace]=_0x222f1e,_0x5baaf6['_internalCount']++,0x6===_0x5baaf6['_internalCount']&&_0x3273fc(_0x5baaf6);},void 0x0,void 0x0,!0x0,function(_0x212dbc,_0x29137c){_0x52d281&&_0x212dbc&&_0x52d281(_0x212dbc['status']+'\x20'+_0x212dbc['statusText'],_0x29137c);});},_0x26966b['a']['prototype']['_cascadeLoadFiles']=function(_0x446370,_0x1f253b,_0x20321b,_0x58c543){void 0x0===_0x58c543&&(_0x58c543=null);var _0x53a22c=[];_0x53a22c['_internalCount']=0x0;for(var _0x53643e=0x0;_0x53643e<0x6;_0x53643e++)this['_partialLoadFile'](_0x20321b[_0x53643e],_0x53643e,_0x53a22c,_0x1f253b,_0x58c543);},_0x26966b['a']['prototype']['_cascadeLoadImgs']=function(_0x52aeaf,_0x2b9fb5,_0xddc2b,_0x48eaa2,_0xa4e62f){void 0x0===_0x48eaa2&&(_0x48eaa2=null);var _0x4d2006=[];_0x4d2006['_internalCount']=0x0;for(var _0x1dd552=0x0;_0x1dd552<0x6;_0x1dd552++)this['_partialLoadImg'](_0xddc2b[_0x1dd552],_0x1dd552,_0x4d2006,_0x52aeaf,_0x2b9fb5,_0x48eaa2,_0xa4e62f);},_0x26966b['a']['prototype']['_partialLoadImg']=function(_0x21d2c9,_0x37299c,_0x113735,_0x443c55,_0x2cd8b0,_0x3e147e,_0x224361){var _0x265c66;void 0x0===_0x3e147e&&(_0x3e147e=null),(_0x265c66=_0x14fdee['a']['LoadImage'](_0x21d2c9,function(){_0x265c66&&(_0x113735[_0x37299c]=_0x265c66,_0x113735['_internalCount']++,_0x443c55&&_0x443c55['_removePendingData'](_0x265c66)),0x6===_0x113735['_internalCount']&&_0x2cd8b0(_0x113735);},function(_0x2df042,_0x594cbe){_0x443c55&&_0x443c55['_removePendingData'](_0x265c66),_0x3e147e&&_0x3e147e(_0x2df042,_0x594cbe);},_0x443c55?_0x443c55['offlineProvider']:null,_0x224361),_0x443c55&&_0x265c66&&_0x443c55['_addPendingData'](_0x265c66));},_0x26966b['a']['prototype']['_setCubeMapTextureParams']=function(_0x30fcfe,_0x3d56b4){var _0x672b69=this['_gl'];_0x672b69['texParameteri'](_0x672b69['TEXTURE_CUBE_MAP'],_0x672b69['TEXTURE_MAG_FILTER'],_0x672b69['LINEAR']),_0x672b69['texParameteri'](_0x672b69['TEXTURE_CUBE_MAP'],_0x672b69['TEXTURE_MIN_FILTER'],_0x3d56b4?_0x672b69['LINEAR_MIPMAP_LINEAR']:_0x672b69['LINEAR']),_0x672b69['texParameteri'](_0x672b69['TEXTURE_CUBE_MAP'],_0x672b69['TEXTURE_WRAP_S'],_0x672b69['CLAMP_TO_EDGE']),_0x672b69['texParameteri'](_0x672b69['TEXTURE_CUBE_MAP'],_0x672b69['TEXTURE_WRAP_T'],_0x672b69['CLAMP_TO_EDGE']),_0x30fcfe['samplingMode']=_0x3d56b4?_0x2103ba['a']['TEXTURE_TRILINEAR_SAMPLINGMODE']:_0x2103ba['a']['TEXTURE_LINEAR_LINEAR'],this['_bindTextureDirectly'](_0x672b69['TEXTURE_CUBE_MAP'],null);},_0x26966b['a']['prototype']['createCubeTexture']=function(_0x44b45c,_0x40661c,_0x2a0483,_0x3d5e3c,_0x42c234,_0x2bdc41,_0x2d3f10,_0x1362ae,_0x59d9fb,_0x2c0ced,_0xd60ac8,_0x1a0c52,_0x183488){var _0x5a9057=this;void 0x0===_0x42c234&&(_0x42c234=null),void 0x0===_0x2bdc41&&(_0x2bdc41=null),void 0x0===_0x1362ae&&(_0x1362ae=null),void 0x0===_0x59d9fb&&(_0x59d9fb=!0x1),void 0x0===_0x2c0ced&&(_0x2c0ced=0x0),void 0x0===_0xd60ac8&&(_0xd60ac8=0x0),void 0x0===_0x1a0c52&&(_0x1a0c52=null);var _0x10381c=this['_gl'],_0x1be3de=_0x1a0c52||new _0x21ea74['a'](this,_0x21ea74['b']['Cube']);_0x1be3de['isCube']=!0x0,_0x1be3de['url']=_0x44b45c,_0x1be3de['generateMipMaps']=!_0x3d5e3c,_0x1be3de['_lodGenerationScale']=_0x2c0ced,_0x1be3de['_lodGenerationOffset']=_0xd60ac8,this['_doNotHandleContextLost']||(_0x1be3de['_extension']=_0x1362ae,_0x1be3de['_files']=_0x2a0483);var _0x1cf5ec=_0x44b45c;this['_transformTextureUrl']&&!_0x1a0c52&&(_0x44b45c=this['_transformTextureUrl'](_0x44b45c));for(var _0x57062f=_0x44b45c['lastIndexOf']('.'),_0x41b4ae=_0x1362ae||(_0x57062f>-0x1?_0x44b45c['substring'](_0x57062f)['toLowerCase']():''),_0x493b13=null,_0x40ef18=0x0,_0x3649f3=_0x26966b['a']['_TextureLoaders'];_0x40ef18<_0x3649f3['length'];_0x40ef18++){var _0x142ae7=_0x3649f3[_0x40ef18];if(_0x142ae7['canLoad'](_0x41b4ae)){_0x493b13=_0x142ae7;break;}}if(_0x493b13){var _0x567f27=function(_0x3fcaf2){_0x5a9057['_bindTextureDirectly'](_0x10381c['TEXTURE_CUBE_MAP'],_0x1be3de,!0x0),_0x493b13['loadCubeData'](_0x3fcaf2,_0x1be3de,_0x59d9fb,_0x42c234,_0x2bdc41);};_0x2a0483&&0x6===_0x2a0483['length']?_0x493b13['supportCascades']?this['_cascadeLoadFiles'](_0x40661c,function(_0x1bdf36){return _0x567f27(_0x1bdf36['map'](function(_0x4e700e){return new Uint8Array(_0x4e700e);}));},_0x2a0483,_0x2bdc41):_0x2bdc41?_0x2bdc41('Textures\x20type\x20does\x20not\x20support\x20cascades.'):_0x75193d['a']['Warn']('Texture\x20loader\x20does\x20not\x20support\x20cascades.'):this['_loadFile'](_0x44b45c,function(_0x3d9b00){return _0x567f27(new Uint8Array(_0x3d9b00));},void 0x0,void 0x0,!0x0,function(_0x29657c,_0x1b1989){_0x44b45c===_0x1cf5ec?_0x2bdc41&&_0x29657c&&_0x2bdc41(_0x29657c['status']+'\x20'+_0x29657c['statusText'],_0x1b1989):(_0x75193d['a']['Warn']('Failed\x20to\x20load\x20'+_0x44b45c+',\x20falling\x20back\x20to\x20the\x20'+_0x1cf5ec),_0x5a9057['createCubeTexture'](_0x1cf5ec,_0x40661c,_0x2a0483,_0x3d5e3c,_0x42c234,_0x2bdc41,_0x2d3f10,_0x1362ae,_0x59d9fb,_0x2c0ced,_0xd60ac8,_0x1be3de,_0x183488));});}else{if(!_0x2a0483)throw new Error('Cannot\x20load\x20cubemap\x20because\x20files\x20were\x20not\x20defined');this['_cascadeLoadImgs'](_0x40661c,function(_0x20febc){var _0xaeca4=_0x5a9057['needPOTTextures']?_0x26966b['a']['GetExponentOfTwo'](_0x20febc[0x0]['width'],_0x5a9057['_caps']['maxCubemapTextureSize']):_0x20febc[0x0]['width'],_0x194669=_0xaeca4,_0x5bf763=[_0x10381c['TEXTURE_CUBE_MAP_POSITIVE_X'],_0x10381c['TEXTURE_CUBE_MAP_POSITIVE_Y'],_0x10381c['TEXTURE_CUBE_MAP_POSITIVE_Z'],_0x10381c['TEXTURE_CUBE_MAP_NEGATIVE_X'],_0x10381c['TEXTURE_CUBE_MAP_NEGATIVE_Y'],_0x10381c['TEXTURE_CUBE_MAP_NEGATIVE_Z']];_0x5a9057['_bindTextureDirectly'](_0x10381c['TEXTURE_CUBE_MAP'],_0x1be3de,!0x0),_0x5a9057['_unpackFlipY'](!0x1);for(var _0x585851=_0x2d3f10?_0x5a9057['_getInternalFormat'](_0x2d3f10):_0x5a9057['_gl']['RGBA'],_0x41fc15=0x0;_0x41fc15<_0x5bf763['length'];_0x41fc15++)if(_0x20febc[_0x41fc15]['width']!==_0xaeca4||_0x20febc[_0x41fc15]['height']!==_0x194669){if(_0x5a9057['_prepareWorkingCanvas'](),!_0x5a9057['_workingCanvas']||!_0x5a9057['_workingContext'])return void _0x75193d['a']['Warn']('Cannot\x20create\x20canvas\x20to\x20resize\x20texture.');_0x5a9057['_workingCanvas']['width']=_0xaeca4,_0x5a9057['_workingCanvas']['height']=_0x194669,_0x5a9057['_workingContext']['drawImage'](_0x20febc[_0x41fc15],0x0,0x0,_0x20febc[_0x41fc15]['width'],_0x20febc[_0x41fc15]['height'],0x0,0x0,_0xaeca4,_0x194669),_0x10381c['texImage2D'](_0x5bf763[_0x41fc15],0x0,_0x585851,_0x585851,_0x10381c['UNSIGNED_BYTE'],_0x5a9057['_workingCanvas']);}else _0x10381c['texImage2D'](_0x5bf763[_0x41fc15],0x0,_0x585851,_0x585851,_0x10381c['UNSIGNED_BYTE'],_0x20febc[_0x41fc15]);_0x3d5e3c||_0x10381c['generateMipmap'](_0x10381c['TEXTURE_CUBE_MAP']),_0x5a9057['_setCubeMapTextureParams'](_0x1be3de,!_0x3d5e3c),_0x1be3de['width']=_0xaeca4,_0x1be3de['height']=_0x194669,_0x1be3de['isReady']=!0x0,_0x2d3f10&&(_0x1be3de['format']=_0x2d3f10),_0x1be3de['onLoadedObservable']['notifyObservers'](_0x1be3de),_0x1be3de['onLoadedObservable']['clear'](),_0x42c234&&_0x42c234();},_0x2a0483,_0x2bdc41);}return this['_internalTexturesCache']['push'](_0x1be3de),_0x1be3de;},(_0x162675(0x99),_0x162675(0x7c));var _0x15af5c=function(){};_0x300b38['a']['prototype']['getInputElement']=function(){return this['inputElement']||this['getRenderingCanvas']();},_0x300b38['a']['prototype']['registerView']=function(_0x981a6e,_0x21cc72){var _0x5035ad=this;this['views']||(this['views']=[]);for(var _0x28c8ad=0x0,_0x58b603=this['views'];_0x28c8ad<_0x58b603['length'];_0x28c8ad++){var _0x16f035=_0x58b603[_0x28c8ad];if(_0x16f035['target']===_0x981a6e)return _0x16f035;}var _0x5a016a=this['getRenderingCanvas']();_0x5a016a&&(_0x981a6e['width']=_0x5a016a['width'],_0x981a6e['height']=_0x5a016a['height']);var _0x55e5ec={'target':_0x981a6e,'camera':_0x21cc72};return this['views']['push'](_0x55e5ec),_0x21cc72&&_0x21cc72['onDisposeObservable']['add'](function(){_0x5035ad['unRegisterView'](_0x981a6e);}),_0x55e5ec;},_0x300b38['a']['prototype']['unRegisterView']=function(_0x213b26){if(!this['views'])return this;for(var _0x57d24=0x0,_0x4898c9=this['views'];_0x57d24<_0x4898c9['length'];_0x57d24++){var _0x2222b9=_0x4898c9[_0x57d24];if(_0x2222b9['target']===_0x213b26){var _0xac6fb7=this['views']['indexOf'](_0x2222b9);-0x1!==_0xac6fb7&&this['views']['splice'](_0xac6fb7,0x1);break;}}return this;},_0x300b38['a']['prototype']['_renderViews']=function(){if(!this['views'])return!0x1;var _0x26d782=this['getRenderingCanvas']();if(!_0x26d782)return!0x1;for(var _0x3ff7d5=0x0,_0x242a6f=this['views'];_0x3ff7d5<_0x242a6f['length'];_0x3ff7d5++){var _0x59809e=_0x242a6f[_0x3ff7d5],_0x918d94=_0x59809e['target'],_0x32fa42=_0x918d94['getContext']('2d');if(_0x32fa42){var _0x446b26=_0x59809e['camera'],_0x132432=null,_0x2e936=null;if(_0x446b26){if((_0x2e936=_0x446b26['getScene']())['activeCameras']&&_0x2e936['activeCameras']['length'])continue;this['activeView']=_0x59809e,_0x132432=_0x2e936['activeCamera'],_0x2e936['activeCamera']=_0x446b26;}var _0x4079be=_0x918d94['width']!==_0x918d94['clientWidth']||_0x918d94['height']!==_0x918d94['clientHeight'];if(_0x918d94['clientWidth']&&_0x918d94['clientHeight']&&_0x4079be&&(_0x918d94['width']=_0x918d94['clientWidth'],_0x918d94['height']=_0x918d94['clientHeight'],_0x26d782['width']=_0x918d94['clientWidth'],_0x26d782['height']=_0x918d94['clientHeight'],this['resize']()),!_0x26d782['width']||!_0x26d782['height'])return!0x1;this['_renderFrame'](),_0x32fa42['drawImage'](_0x26d782,0x0,0x0),_0x132432&&_0x2e936&&(_0x2e936['activeCamera']=_0x132432);}}return this['activeView']=null,!0x0;},_0x162675(0x81);function _0x2d0493(_0x7f4ebb){if(this['_excludedCompressedTextures']&&this['_excludedCompressedTextures']['some'](function(_0x5dacbd){var _0x441b9e='\x5cb'+_0x5dacbd+'\x5cb';return _0x7f4ebb&&(_0x7f4ebb===_0x5dacbd||_0x7f4ebb['match'](new RegExp(_0x441b9e,'g')));}))return _0x7f4ebb;var _0x2949f8=_0x7f4ebb['lastIndexOf']('.'),_0x4490d9=_0x7f4ebb['lastIndexOf']('?'),_0x54f70c=_0x4490d9>-0x1?_0x7f4ebb['substring'](_0x4490d9,_0x7f4ebb['length']):'';return(_0x2949f8>-0x1?_0x7f4ebb['substring'](0x0,_0x2949f8):_0x7f4ebb)+this['_textureFormatInUse']+_0x54f70c;}Object['defineProperty'](_0x300b38['a']['prototype'],'texturesSupported',{'get':function(){var _0x1117c5=new Array();return this['_caps']['astc']&&_0x1117c5['push']('-astc.ktx'),this['_caps']['s3tc']&&_0x1117c5['push']('-dxt.ktx'),this['_caps']['pvrtc']&&_0x1117c5['push']('-pvrtc.ktx'),this['_caps']['etc2']&&_0x1117c5['push']('-etc2.ktx'),this['_caps']['etc1']&&_0x1117c5['push']('-etc1.ktx'),_0x1117c5;},'enumerable':!0x0,'configurable':!0x0}),Object['defineProperty'](_0x300b38['a']['prototype'],'textureFormatInUse',{'get':function(){return this['_textureFormatInUse']||null;},'enumerable':!0x0,'configurable':!0x0}),_0x300b38['a']['prototype']['setCompressedTextureExclusions']=function(_0x1e5194){this['_excludedCompressedTextures']=_0x1e5194;},_0x300b38['a']['prototype']['setTextureFormatToUse']=function(_0x35868e){for(var _0x373187=this['texturesSupported'],_0x30231f=0x0,_0x303b07=_0x373187['length'];_0x30231f<_0x303b07;_0x30231f++)for(var _0x1f4edb=0x0,_0x170b6f=_0x35868e['length'];_0x1f4edb<_0x170b6f;_0x1f4edb++)if(_0x373187[_0x30231f]===_0x35868e[_0x1f4edb]['toLowerCase']())return this['_transformTextureUrl']=_0x2d0493['bind'](this),this['_textureFormatInUse']=_0x373187[_0x30231f];return this['_textureFormatInUse']='',this['_transformTextureUrl']=null,null;};var _0x2bf27f=_0x162675(0x90),_0x304729=_0x162675(0x76),_0x2b8850=_0x162675(0x59),_0x2ddff8=[Math['sqrt'](0x1/(0x4*Math['PI'])),-Math['sqrt'](0x3/(0x4*Math['PI'])),Math['sqrt'](0x3/(0x4*Math['PI'])),-Math['sqrt'](0x3/(0x4*Math['PI'])),Math['sqrt'](0xf/(0x4*Math['PI'])),-Math['sqrt'](0xf/(0x4*Math['PI'])),Math['sqrt'](0x5/(0x10*Math['PI'])),-Math['sqrt'](0xf/(0x4*Math['PI'])),Math['sqrt'](0xf/(0x10*Math['PI']))],_0x156956=[function(_0x6f2bd9){return 0x1;},function(_0x3c4521){return _0x3c4521['y'];},function(_0x4e3bf6){return _0x4e3bf6['z'];},function(_0x131902){return _0x131902['x'];},function(_0x4a071d){return _0x4a071d['x']*_0x4a071d['y'];},function(_0x2bb584){return _0x2bb584['y']*_0x2bb584['z'];},function(_0x20801b){return 0x3*_0x20801b['z']*_0x20801b['z']-0x1;},function(_0x1a2977){return _0x1a2977['x']*_0x1a2977['z'];},function(_0x16048b){return _0x16048b['x']*_0x16048b['x']-_0x16048b['y']*_0x16048b['y'];}],_0x403b3e=function(_0x781be1,_0x12a497){return _0x2ddff8[_0x781be1]*_0x156956[_0x781be1](_0x12a497);},_0x540dc3=[Math['PI'],0x2*Math['PI']/0x3,0x2*Math['PI']/0x3,0x2*Math['PI']/0x3,Math['PI']/0x4,Math['PI']/0x4,Math['PI']/0x4,Math['PI']/0x4,Math['PI']/0x4],_0x44d982=(function(){function _0x72da1e(){this['preScaled']=!0x1,this['l00']=_0x74d525['e']['Zero'](),this['l1_1']=_0x74d525['e']['Zero'](),this['l10']=_0x74d525['e']['Zero'](),this['l11']=_0x74d525['e']['Zero'](),this['l2_2']=_0x74d525['e']['Zero'](),this['l2_1']=_0x74d525['e']['Zero'](),this['l20']=_0x74d525['e']['Zero'](),this['l21']=_0x74d525['e']['Zero'](),this['l22']=_0x74d525['e']['Zero']();}return _0x72da1e['prototype']['addLight']=function(_0x3e80d4,_0x322e6d,_0x599d60){var _0xf0636d=new _0x74d525['e'](_0x322e6d['r'],_0x322e6d['g'],_0x322e6d['b'])['scale'](_0x599d60);this['l00']=this['l00']['add'](_0xf0636d['scale'](_0x403b3e(0x0,_0x3e80d4))),this['l1_1']=this['l1_1']['add'](_0xf0636d['scale'](_0x403b3e(0x1,_0x3e80d4))),this['l10']=this['l10']['add'](_0xf0636d['scale'](_0x403b3e(0x2,_0x3e80d4))),this['l11']=this['l11']['add'](_0xf0636d['scale'](_0x403b3e(0x3,_0x3e80d4))),this['l2_2']=this['l2_2']['add'](_0xf0636d['scale'](_0x403b3e(0x4,_0x3e80d4))),this['l2_1']=this['l2_1']['add'](_0xf0636d['scale'](_0x403b3e(0x5,_0x3e80d4))),this['l20']=this['l20']['add'](_0xf0636d['scale'](_0x403b3e(0x6,_0x3e80d4))),this['l21']=this['l21']['add'](_0xf0636d['scale'](_0x403b3e(0x7,_0x3e80d4))),this['l22']=this['l22']['add'](_0xf0636d['scale'](_0x403b3e(0x8,_0x3e80d4)));},_0x72da1e['prototype']['scaleInPlace']=function(_0x1487b9){this['l00']['scaleInPlace'](_0x1487b9),this['l1_1']['scaleInPlace'](_0x1487b9),this['l10']['scaleInPlace'](_0x1487b9),this['l11']['scaleInPlace'](_0x1487b9),this['l2_2']['scaleInPlace'](_0x1487b9),this['l2_1']['scaleInPlace'](_0x1487b9),this['l20']['scaleInPlace'](_0x1487b9),this['l21']['scaleInPlace'](_0x1487b9),this['l22']['scaleInPlace'](_0x1487b9);},_0x72da1e['prototype']['convertIncidentRadianceToIrradiance']=function(){this['l00']['scaleInPlace'](_0x540dc3[0x0]),this['l1_1']['scaleInPlace'](_0x540dc3[0x1]),this['l10']['scaleInPlace'](_0x540dc3[0x2]),this['l11']['scaleInPlace'](_0x540dc3[0x3]),this['l2_2']['scaleInPlace'](_0x540dc3[0x4]),this['l2_1']['scaleInPlace'](_0x540dc3[0x5]),this['l20']['scaleInPlace'](_0x540dc3[0x6]),this['l21']['scaleInPlace'](_0x540dc3[0x7]),this['l22']['scaleInPlace'](_0x540dc3[0x8]);},_0x72da1e['prototype']['convertIrradianceToLambertianRadiance']=function(){this['scaleInPlace'](0x1/Math['PI']);},_0x72da1e['prototype']['preScaleForRendering']=function(){this['preScaled']=!0x0,this['l00']['scaleInPlace'](_0x2ddff8[0x0]),this['l1_1']['scaleInPlace'](_0x2ddff8[0x1]),this['l10']['scaleInPlace'](_0x2ddff8[0x2]),this['l11']['scaleInPlace'](_0x2ddff8[0x3]),this['l2_2']['scaleInPlace'](_0x2ddff8[0x4]),this['l2_1']['scaleInPlace'](_0x2ddff8[0x5]),this['l20']['scaleInPlace'](_0x2ddff8[0x6]),this['l21']['scaleInPlace'](_0x2ddff8[0x7]),this['l22']['scaleInPlace'](_0x2ddff8[0x8]);},_0x72da1e['FromArray']=function(_0x2ba3f4){var _0x9e0637=new _0x72da1e();return _0x74d525['e']['FromArrayToRef'](_0x2ba3f4[0x0],0x0,_0x9e0637['l00']),_0x74d525['e']['FromArrayToRef'](_0x2ba3f4[0x1],0x0,_0x9e0637['l1_1']),_0x74d525['e']['FromArrayToRef'](_0x2ba3f4[0x2],0x0,_0x9e0637['l10']),_0x74d525['e']['FromArrayToRef'](_0x2ba3f4[0x3],0x0,_0x9e0637['l11']),_0x74d525['e']['FromArrayToRef'](_0x2ba3f4[0x4],0x0,_0x9e0637['l2_2']),_0x74d525['e']['FromArrayToRef'](_0x2ba3f4[0x5],0x0,_0x9e0637['l2_1']),_0x74d525['e']['FromArrayToRef'](_0x2ba3f4[0x6],0x0,_0x9e0637['l20']),_0x74d525['e']['FromArrayToRef'](_0x2ba3f4[0x7],0x0,_0x9e0637['l21']),_0x74d525['e']['FromArrayToRef'](_0x2ba3f4[0x8],0x0,_0x9e0637['l22']),_0x9e0637;},_0x72da1e['FromPolynomial']=function(_0x4c21e9){var _0x5385d1=new _0x72da1e();return _0x5385d1['l00']=_0x4c21e9['xx']['scale'](0.376127)['add'](_0x4c21e9['yy']['scale'](0.376127))['add'](_0x4c21e9['zz']['scale'](0.376126)),_0x5385d1['l1_1']=_0x4c21e9['y']['scale'](0.977204),_0x5385d1['l10']=_0x4c21e9['z']['scale'](0.977204),_0x5385d1['l11']=_0x4c21e9['x']['scale'](0.977204),_0x5385d1['l2_2']=_0x4c21e9['xy']['scale'](1.16538),_0x5385d1['l2_1']=_0x4c21e9['yz']['scale'](1.16538),_0x5385d1['l20']=_0x4c21e9['zz']['scale'](1.34567)['subtract'](_0x4c21e9['xx']['scale'](0.672834))['subtract'](_0x4c21e9['yy']['scale'](0.672834)),_0x5385d1['l21']=_0x4c21e9['zx']['scale'](1.16538),_0x5385d1['l22']=_0x4c21e9['xx']['scale'](1.16538)['subtract'](_0x4c21e9['yy']['scale'](1.16538)),_0x5385d1['l1_1']['scaleInPlace'](-0x1),_0x5385d1['l11']['scaleInPlace'](-0x1),_0x5385d1['l2_1']['scaleInPlace'](-0x1),_0x5385d1['l21']['scaleInPlace'](-0x1),_0x5385d1['scaleInPlace'](Math['PI']),_0x5385d1;},_0x72da1e;}()),_0x23d472=(function(){function _0x91d108(){this['x']=_0x74d525['e']['Zero'](),this['y']=_0x74d525['e']['Zero'](),this['z']=_0x74d525['e']['Zero'](),this['xx']=_0x74d525['e']['Zero'](),this['yy']=_0x74d525['e']['Zero'](),this['zz']=_0x74d525['e']['Zero'](),this['xy']=_0x74d525['e']['Zero'](),this['yz']=_0x74d525['e']['Zero'](),this['zx']=_0x74d525['e']['Zero']();}return Object['defineProperty'](_0x91d108['prototype'],'preScaledHarmonics',{'get':function(){return this['_harmonics']||(this['_harmonics']=_0x44d982['FromPolynomial'](this)),this['_harmonics']['preScaled']||this['_harmonics']['preScaleForRendering'](),this['_harmonics'];},'enumerable':!0x1,'configurable':!0x0}),_0x91d108['prototype']['addAmbient']=function(_0x291a3a){var _0x34b4e0=new _0x74d525['e'](_0x291a3a['r'],_0x291a3a['g'],_0x291a3a['b']);this['xx']=this['xx']['add'](_0x34b4e0),this['yy']=this['yy']['add'](_0x34b4e0),this['zz']=this['zz']['add'](_0x34b4e0);},_0x91d108['prototype']['scaleInPlace']=function(_0x642d8c){this['x']['scaleInPlace'](_0x642d8c),this['y']['scaleInPlace'](_0x642d8c),this['z']['scaleInPlace'](_0x642d8c),this['xx']['scaleInPlace'](_0x642d8c),this['yy']['scaleInPlace'](_0x642d8c),this['zz']['scaleInPlace'](_0x642d8c),this['yz']['scaleInPlace'](_0x642d8c),this['zx']['scaleInPlace'](_0x642d8c),this['xy']['scaleInPlace'](_0x642d8c);},_0x91d108['FromHarmonics']=function(_0x2e3eff){var _0x1bf7f8=new _0x91d108();return _0x1bf7f8['_harmonics']=_0x2e3eff,_0x1bf7f8['x']=_0x2e3eff['l11']['scale'](1.02333)['scale'](-0x1),_0x1bf7f8['y']=_0x2e3eff['l1_1']['scale'](1.02333)['scale'](-0x1),_0x1bf7f8['z']=_0x2e3eff['l10']['scale'](1.02333),_0x1bf7f8['xx']=_0x2e3eff['l00']['scale'](0.886277)['subtract'](_0x2e3eff['l20']['scale'](0.247708))['add'](_0x2e3eff['l22']['scale'](0.429043)),_0x1bf7f8['yy']=_0x2e3eff['l00']['scale'](0.886277)['subtract'](_0x2e3eff['l20']['scale'](0.247708))['subtract'](_0x2e3eff['l22']['scale'](0.429043)),_0x1bf7f8['zz']=_0x2e3eff['l00']['scale'](0.886277)['add'](_0x2e3eff['l20']['scale'](0.495417)),_0x1bf7f8['yz']=_0x2e3eff['l2_1']['scale'](0.858086)['scale'](-0x1),_0x1bf7f8['zx']=_0x2e3eff['l21']['scale'](0.858086)['scale'](-0x1),_0x1bf7f8['xy']=_0x2e3eff['l2_2']['scale'](0.858086),_0x1bf7f8['scaleInPlace'](0x1/Math['PI']),_0x1bf7f8;},_0x91d108['FromArray']=function(_0x3c2f11){var _0x327f53=new _0x91d108();return _0x74d525['e']['FromArrayToRef'](_0x3c2f11[0x0],0x0,_0x327f53['x']),_0x74d525['e']['FromArrayToRef'](_0x3c2f11[0x1],0x0,_0x327f53['y']),_0x74d525['e']['FromArrayToRef'](_0x3c2f11[0x2],0x0,_0x327f53['z']),_0x74d525['e']['FromArrayToRef'](_0x3c2f11[0x3],0x0,_0x327f53['xx']),_0x74d525['e']['FromArrayToRef'](_0x3c2f11[0x4],0x0,_0x327f53['yy']),_0x74d525['e']['FromArrayToRef'](_0x3c2f11[0x5],0x0,_0x327f53['zz']),_0x74d525['e']['FromArrayToRef'](_0x3c2f11[0x6],0x0,_0x327f53['yz']),_0x74d525['e']['FromArrayToRef'](_0x3c2f11[0x7],0x0,_0x327f53['zx']),_0x74d525['e']['FromArrayToRef'](_0x3c2f11[0x8],0x0,_0x327f53['xy']),_0x327f53;},_0x91d108;}()),_0x2268ea=_0x162675(0x34),_0x4d7a86=function(_0x1864e9,_0x2fd771,_0x2bd247,_0x2ed14b){this['name']=_0x1864e9,this['worldAxisForNormal']=_0x2fd771,this['worldAxisForFileX']=_0x2bd247,this['worldAxisForFileY']=_0x2ed14b;},_0x3fdf9a=(function(){function _0x443a83(){}return _0x443a83['ConvertCubeMapTextureToSphericalPolynomial']=function(_0xe5f4fe){if(!_0xe5f4fe['isCube'])return null;var _0x2077ab,_0x47ce26,_0x2bb51e=_0xe5f4fe['getSize']()['width'],_0x4c6d0c=_0xe5f4fe['readPixels'](0x0),_0x4f952d=_0xe5f4fe['readPixels'](0x1);_0xe5f4fe['isRenderTarget']?(_0x2077ab=_0xe5f4fe['readPixels'](0x3),_0x47ce26=_0xe5f4fe['readPixels'](0x2)):(_0x2077ab=_0xe5f4fe['readPixels'](0x2),_0x47ce26=_0xe5f4fe['readPixels'](0x3));var _0xb755ff=_0xe5f4fe['readPixels'](0x4),_0x163b10=_0xe5f4fe['readPixels'](0x5),_0x3fb25b=_0xe5f4fe['gammaSpace'],_0x151b4d=_0x2103ba['a']['TEXTUREFORMAT_RGBA'],_0x5ed0e7=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'];_0xe5f4fe['textureType']!=_0x2103ba['a']['TEXTURETYPE_FLOAT']&&_0xe5f4fe['textureType']!=_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT']||(_0x5ed0e7=_0x2103ba['a']['TEXTURETYPE_FLOAT']);var _0x327670={'size':_0x2bb51e,'right':_0x4c6d0c,'left':_0x4f952d,'up':_0x2077ab,'down':_0x47ce26,'front':_0xb755ff,'back':_0x163b10,'format':_0x151b4d,'type':_0x5ed0e7,'gammaSpace':_0x3fb25b};return this['ConvertCubeMapToSphericalPolynomial'](_0x327670);},_0x443a83['ConvertCubeMapToSphericalPolynomial']=function(_0x34702f){for(var _0x1177f4=new _0x44d982(),_0x4cdf7b=0x0,_0x109372=0x2/_0x34702f['size'],_0x148bb6=_0x109372,_0xb9285=0.5*_0x109372-0x1,_0x3d166c=0x0;_0x3d166c<0x6;_0x3d166c++)for(var _0x307dbd=this['FileFaces'][_0x3d166c],_0x1db28d=_0x34702f[_0x307dbd['name']],_0x406997=_0xb9285,_0x88114f=_0x34702f['format']===_0x2103ba['a']['TEXTUREFORMAT_RGBA']?0x4:0x3,_0x15fc09=0x0;_0x15fc09<_0x34702f['size'];_0x15fc09++){for(var _0x109ba0=_0xb9285,_0x473ae8=0x0;_0x473ae8<_0x34702f['size'];_0x473ae8++){var _0x487e06=_0x307dbd['worldAxisForFileX']['scale'](_0x109ba0)['add'](_0x307dbd['worldAxisForFileY']['scale'](_0x406997))['add'](_0x307dbd['worldAxisForNormal']);_0x487e06['normalize']();var _0x952cdd=Math['pow'](0x1+_0x109ba0*_0x109ba0+_0x406997*_0x406997,-1.5),_0x21c350=_0x1db28d[_0x15fc09*_0x34702f['size']*_0x88114f+_0x473ae8*_0x88114f+0x0],_0x5a3323=_0x1db28d[_0x15fc09*_0x34702f['size']*_0x88114f+_0x473ae8*_0x88114f+0x1],_0x47bf96=_0x1db28d[_0x15fc09*_0x34702f['size']*_0x88114f+_0x473ae8*_0x88114f+0x2];isNaN(_0x21c350)&&(_0x21c350=0x0),isNaN(_0x5a3323)&&(_0x5a3323=0x0),isNaN(_0x47bf96)&&(_0x47bf96=0x0),_0x34702f['type']===_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']&&(_0x21c350/=0xff,_0x5a3323/=0xff,_0x47bf96/=0xff),_0x34702f['gammaSpace']&&(_0x21c350=Math['pow'](_0x4a0cf0['a']['Clamp'](_0x21c350),_0x27da6e['c']),_0x5a3323=Math['pow'](_0x4a0cf0['a']['Clamp'](_0x5a3323),_0x27da6e['c']),_0x47bf96=Math['pow'](_0x4a0cf0['a']['Clamp'](_0x47bf96),_0x27da6e['c'])),(_0x21c350=_0x4a0cf0['a']['Clamp'](_0x21c350,0x0,0x1000),_0x5a3323=_0x4a0cf0['a']['Clamp'](_0x5a3323,0x0,0x1000),_0x47bf96=_0x4a0cf0['a']['Clamp'](_0x47bf96,0x0,0x1000));var _0x438a78=new _0x39310d['a'](_0x21c350,_0x5a3323,_0x47bf96);_0x1177f4['addLight'](_0x487e06,_0x438a78,_0x952cdd),_0x4cdf7b+=_0x952cdd,_0x109ba0+=_0x109372;}_0x406997+=_0x148bb6;}var _0x4bb08b=0x6*(0x4*Math['PI'])/0x6/_0x4cdf7b;return _0x1177f4['scaleInPlace'](_0x4bb08b),_0x1177f4['convertIncidentRadianceToIrradiance'](),_0x1177f4['convertIrradianceToLambertianRadiance'](),_0x23d472['FromHarmonics'](_0x1177f4);},_0x443a83['FileFaces']=[new _0x4d7a86('right',new _0x74d525['e'](0x1,0x0,0x0),new _0x74d525['e'](0x0,0x0,-0x1),new _0x74d525['e'](0x0,-0x1,0x0)),new _0x4d7a86('left',new _0x74d525['e'](-0x1,0x0,0x0),new _0x74d525['e'](0x0,0x0,0x1),new _0x74d525['e'](0x0,-0x1,0x0)),new _0x4d7a86('up',new _0x74d525['e'](0x0,0x1,0x0),new _0x74d525['e'](0x1,0x0,0x0),new _0x74d525['e'](0x0,0x0,0x1)),new _0x4d7a86('down',new _0x74d525['e'](0x0,-0x1,0x0),new _0x74d525['e'](0x1,0x0,0x0),new _0x74d525['e'](0x0,0x0,-0x1)),new _0x4d7a86('front',new _0x74d525['e'](0x0,0x0,0x1),new _0x74d525['e'](0x1,0x0,0x0),new _0x74d525['e'](0x0,-0x1,0x0)),new _0x4d7a86('back',new _0x74d525['e'](0x0,0x0,-0x1),new _0x74d525['e'](-0x1,0x0,0x0),new _0x74d525['e'](0x0,-0x1,0x0))],_0x443a83;}());Object['defineProperty'](_0x2268ea['a']['prototype'],'sphericalPolynomial',{'get':function(){if(this['_texture']){if(this['_texture']['_sphericalPolynomial'])return this['_texture']['_sphericalPolynomial'];if(this['_texture']['isReady'])return this['_texture']['_sphericalPolynomial']=_0x3fdf9a['ConvertCubeMapTextureToSphericalPolynomial'](this),this['_texture']['_sphericalPolynomial'];}return null;},'set':function(_0x5b5cb){this['_texture']&&(this['_texture']['_sphericalPolynomial']=_0x5b5cb);},'enumerable':!0x0,'configurable':!0x0});var _0xc2b2c9='\x0avarying\x20vec2\x20vUV;\x0auniform\x20sampler2D\x20textureSampler;\x0a#include\x0avoid\x20main(void)\x0a{\x0agl_FragColor=toRGBD(texture2D(textureSampler,vUV).rgb);\x0a}';_0x494b01['a']['ShadersStore']['rgbdEncodePixelShader']=_0xc2b2c9;var _0x22baf3='\x0avarying\x20vec2\x20vUV;\x0auniform\x20sampler2D\x20textureSampler;\x0a#include\x0avoid\x20main(void)\x0a{\x0agl_FragColor=vec4(fromRGBD(texture2D(textureSampler,vUV)),1.0);\x0a}';_0x494b01['a']['ShadersStore']['rgbdDecodePixelShader']=_0x22baf3;var _0x480d46=(function(){function _0x1b77a3(){}return _0x1b77a3['GetEnvInfo']=function(_0x31ac74){for(var _0x392f7=new DataView(_0x31ac74['buffer'],_0x31ac74['byteOffset'],_0x31ac74['byteLength']),_0x49b95d=0x0,_0xf03f00=0x0;_0xf03f00<_0x1b77a3['_MagicBytes']['length'];_0xf03f00++)if(_0x392f7['getUint8'](_0x49b95d++)!==_0x1b77a3['_MagicBytes'][_0xf03f00])return _0x75193d['a']['Error']('Not\x20a\x20babylon\x20environment\x20map'),null;for(var _0x425616='',_0x7e33fe=0x0;_0x7e33fe=_0x392f7['getUint8'](_0x49b95d++);)_0x425616+=String['fromCharCode'](_0x7e33fe);var _0x53f098=JSON['parse'](_0x425616);return _0x53f098['specular']&&(_0x53f098['specular']['specularDataPosition']=_0x49b95d,_0x53f098['specular']['lodGenerationScale']=_0x53f098['specular']['lodGenerationScale']||0.8),_0x53f098;},_0x1b77a3['CreateEnvTextureAsync']=function(_0x49556e){var _0x57b6fc=this,_0x1b0467=_0x49556e['getInternalTexture']();if(!_0x1b0467)return Promise['reject']('The\x20cube\x20texture\x20is\x20invalid.');var _0x5ca6b6=_0x1b0467['getEngine']();if(_0x5ca6b6&&_0x5ca6b6['premultipliedAlpha'])return Promise['reject']('Env\x20texture\x20can\x20only\x20be\x20created\x20when\x20the\x20engine\x20is\x20created\x20with\x20the\x20premultipliedAlpha\x20option\x20set\x20to\x20false.');if(_0x49556e['textureType']===_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'])return Promise['reject']('The\x20cube\x20texture\x20should\x20allow\x20HDR\x20(Full\x20Float\x20or\x20Half\x20Float).');var _0x4a0eed=_0x5ca6b6['getRenderingCanvas']();if(!_0x4a0eed)return Promise['reject']('Env\x20texture\x20can\x20only\x20be\x20created\x20when\x20the\x20engine\x20is\x20associated\x20to\x20a\x20canvas.');var _0x3c834a=_0x2103ba['a']['TEXTURETYPE_FLOAT'];if(!_0x5ca6b6['getCaps']()['textureFloatRender']&&(_0x3c834a=_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT'],!_0x5ca6b6['getCaps']()['textureHalfFloatRender']))return Promise['reject']('Env\x20texture\x20can\x20only\x20be\x20created\x20when\x20the\x20browser\x20supports\x20half\x20float\x20or\x20full\x20float\x20rendering.');var _0x41b9d0=_0x1b0467['width'],_0x79ce07=new _0x59370b['a'](_0x5ca6b6),_0x5387fe={},_0x26eb81=[],_0x546f37=_0x4a0cf0['a']['Log2'](_0x1b0467['width']);_0x546f37=Math['round'](_0x546f37);for(var _0x4f7aa1=function(_0x34137c){for(var _0x980bb3=Math['pow'](0x2,_0x546f37-_0x34137c),_0x2a73d1=function(_0x5f032a){var _0x18060b=_0x49556e['readPixels'](_0x5f032a,_0x34137c),_0x30c06f=_0x5ca6b6['createRawTexture'](_0x18060b,_0x980bb3,_0x980bb3,_0x2103ba['a']['TEXTUREFORMAT_RGBA'],!0x1,!0x1,_0x2103ba['a']['TEXTURE_NEAREST_SAMPLINGMODE'],null,_0x3c834a),_0x1b2716=new Promise(function(_0x55822c,_0x3cc406){var _0x5e319b=new _0x5cae84('rgbdEncode','rgbdEncode',null,null,0x1,null,_0x2103ba['a']['TEXTURE_NEAREST_SAMPLINGMODE'],_0x5ca6b6,!0x1,void 0x0,_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'],void 0x0,null,!0x1);_0x5e319b['getEffect']()['executeWhenCompiled'](function(){_0x5e319b['onApply']=function(_0x125ad4){_0x125ad4['_bindTexture']('textureSampler',_0x30c06f);};var _0x37f76f=_0x5ca6b6['getRenderWidth'](),_0x3685bb=_0x5ca6b6['getRenderHeight']();_0x5ca6b6['setSize'](_0x980bb3,_0x980bb3),_0x79ce07['postProcessManager']['directRender']([_0x5e319b],null),_0x5d754c['b']['ToBlob'](_0x4a0eed,function(_0x330c7d){var _0x24737b=new FileReader();_0x24737b['onload']=function(_0x2b27db){var _0x57919e=_0x2b27db['target']['result'];_0x5387fe[0x6*_0x34137c+_0x5f032a]=_0x57919e,_0x55822c();},_0x24737b['readAsArrayBuffer'](_0x330c7d);}),_0x5ca6b6['setSize'](_0x37f76f,_0x3685bb);});});_0x26eb81['push'](_0x1b2716);},_0x41c5af=0x0;_0x41c5af<0x6;_0x41c5af++)_0x2a73d1(_0x41c5af);},_0xc0e11b=0x0;_0xc0e11b<=_0x546f37;_0xc0e11b++)_0x4f7aa1(_0xc0e11b);return Promise['all'](_0x26eb81)['then'](function(){_0x79ce07['dispose']();for(var _0x1fac83={'version':0x1,'width':_0x41b9d0,'irradiance':_0x57b6fc['_CreateEnvTextureIrradiance'](_0x49556e),'specular':{'mipmaps':[],'lodGenerationScale':_0x49556e['lodGenerationScale']}},_0x49bf29=0x0,_0xf08091=0x0;_0xf08091<=_0x546f37;_0xf08091++)for(var _0x14e3c0=0x0;_0x14e3c0<0x6;_0x14e3c0++){var _0x57fb3f=_0x5387fe[0x6*_0xf08091+_0x14e3c0]['byteLength'];_0x1fac83['specular']['mipmaps']['push']({'length':_0x57fb3f,'position':_0x49bf29}),_0x49bf29+=_0x57fb3f;}for(var _0x2c3c9b=JSON['stringify'](_0x1fac83),_0x2f2880=new ArrayBuffer(_0x2c3c9b['length']+0x1),_0x4cea4a=new Uint8Array(_0x2f2880),_0x19d811=(_0xf08091=0x0,_0x2c3c9b['length']);_0xf08091<_0x19d811;_0xf08091++)_0x4cea4a[_0xf08091]=_0x2c3c9b['charCodeAt'](_0xf08091);_0x4cea4a[_0x2c3c9b['length']]=0x0;var _0x3d258a=_0x1b77a3['_MagicBytes']['length']+_0x49bf29+_0x2f2880['byteLength'],_0x381348=new ArrayBuffer(_0x3d258a),_0x37edcb=new Uint8Array(_0x381348),_0x49d0f6=new DataView(_0x381348),_0x28d9b2=0x0;for(_0xf08091=0x0;_0xf08091<_0x1b77a3['_MagicBytes']['length'];_0xf08091++)_0x49d0f6['setUint8'](_0x28d9b2++,_0x1b77a3['_MagicBytes'][_0xf08091]);_0x37edcb['set'](new Uint8Array(_0x2f2880),_0x28d9b2),_0x28d9b2+=_0x2f2880['byteLength'];for(_0xf08091=0x0;_0xf08091<=_0x546f37;_0xf08091++)for(_0x14e3c0=0x0;_0x14e3c0<0x6;_0x14e3c0++){var _0x2aa5b2=_0x5387fe[0x6*_0xf08091+_0x14e3c0];_0x37edcb['set'](new Uint8Array(_0x2aa5b2),_0x28d9b2),_0x28d9b2+=_0x2aa5b2['byteLength'];}return _0x381348;});},_0x1b77a3['_CreateEnvTextureIrradiance']=function(_0x447e90){var _0x145218=_0x447e90['sphericalPolynomial'];return null==_0x145218?null:{'x':[_0x145218['x']['x'],_0x145218['x']['y'],_0x145218['x']['z']],'y':[_0x145218['y']['x'],_0x145218['y']['y'],_0x145218['y']['z']],'z':[_0x145218['z']['x'],_0x145218['z']['y'],_0x145218['z']['z']],'xx':[_0x145218['xx']['x'],_0x145218['xx']['y'],_0x145218['xx']['z']],'yy':[_0x145218['yy']['x'],_0x145218['yy']['y'],_0x145218['yy']['z']],'zz':[_0x145218['zz']['x'],_0x145218['zz']['y'],_0x145218['zz']['z']],'yz':[_0x145218['yz']['x'],_0x145218['yz']['y'],_0x145218['yz']['z']],'zx':[_0x145218['zx']['x'],_0x145218['zx']['y'],_0x145218['zx']['z']],'xy':[_0x145218['xy']['x'],_0x145218['xy']['y'],_0x145218['xy']['z']]};},_0x1b77a3['CreateImageDataArrayBufferViews']=function(_0x4c79c4,_0x5b2544){if(0x1!==_0x5b2544['version'])throw new Error('Unsupported\x20babylon\x20environment\x20map\x20version\x20\x22'+_0x5b2544['version']+'\x22');var _0x2de87a=_0x5b2544['specular'],_0x1a2f7b=_0x4a0cf0['a']['Log2'](_0x5b2544['width']);if(_0x1a2f7b=Math['round'](_0x1a2f7b)+0x1,_0x2de87a['mipmaps']['length']!==0x6*_0x1a2f7b)throw new Error('Unsupported\x20specular\x20mipmaps\x20number\x20\x22'+_0x2de87a['mipmaps']['length']+'\x22');for(var _0x473578=new Array(_0x1a2f7b),_0xf57830=0x0;_0xf57830<_0x1a2f7b;_0xf57830++){_0x473578[_0xf57830]=new Array(0x6);for(var _0x3be61a=0x0;_0x3be61a<0x6;_0x3be61a++){var _0x11655c=_0x2de87a['mipmaps'][0x6*_0xf57830+_0x3be61a];_0x473578[_0xf57830][_0x3be61a]=new Uint8Array(_0x4c79c4['buffer'],_0x4c79c4['byteOffset']+_0x2de87a['specularDataPosition']+_0x11655c['position'],_0x11655c['length']);}}return _0x473578;},_0x1b77a3['UploadEnvLevelsAsync']=function(_0x309d58,_0x302cfd,_0x5e4c8d){if(0x1!==_0x5e4c8d['version'])throw new Error('Unsupported\x20babylon\x20environment\x20map\x20version\x20\x22'+_0x5e4c8d['version']+'\x22');var _0x55f6c4=_0x5e4c8d['specular'];if(!_0x55f6c4)return Promise['resolve']();_0x309d58['_lodGenerationScale']=_0x55f6c4['lodGenerationScale'];var _0x587b29=_0x1b77a3['CreateImageDataArrayBufferViews'](_0x302cfd,_0x5e4c8d);return _0x1b77a3['UploadLevelsAsync'](_0x309d58,_0x587b29);},_0x1b77a3['_OnImageReadyAsync']=function(_0x29663b,_0x3084bd,_0x66e2d2,_0x3a4ce0,_0x25527f,_0x49a116,_0x56fb9e,_0xae5382,_0x53dff1,_0x2dbb7a,_0x4749fd){return new Promise(function(_0x5b95a5,_0x38bab8){if(_0x66e2d2){var _0x47b70c=_0x3084bd['createTexture'](null,!0x0,!0x0,null,_0x2103ba['a']['TEXTURE_NEAREST_SAMPLINGMODE'],null,function(_0x44d29d){_0x38bab8(_0x44d29d);},_0x29663b);_0x3a4ce0['getEffect']()['executeWhenCompiled'](function(){_0x3a4ce0['onApply']=function(_0x149d03){_0x149d03['_bindTexture']('textureSampler',_0x47b70c),_0x149d03['setFloat2']('scale',0x1,0x1);},_0x3084bd['scenes'][0x0]['postProcessManager']['directRender']([_0x3a4ce0],_0x2dbb7a,!0x0,_0x49a116,_0x56fb9e),_0x3084bd['restoreDefaultFramebuffer'](),_0x47b70c['dispose'](),URL['revokeObjectURL'](_0x25527f),_0x5b95a5();});}else{if(_0x3084bd['_uploadImageToTexture'](_0x4749fd,_0x29663b,_0x49a116,_0x56fb9e),_0xae5382){var _0x543cf5=_0x53dff1[_0x56fb9e];_0x543cf5&&_0x3084bd['_uploadImageToTexture'](_0x543cf5['_texture'],_0x29663b,_0x49a116,0x0);}_0x5b95a5();}});},_0x1b77a3['UploadLevelsAsync']=function(_0x13354e,_0xf3fb40){var _0x163e9a=this;if(!_0x5d754c['b']['IsExponentOfTwo'](_0x13354e['width']))throw new Error('Texture\x20size\x20must\x20be\x20a\x20power\x20of\x20two');var _0x278779=Math['round'](_0x4a0cf0['a']['Log2'](_0x13354e['width']))+0x1,_0x1c81f5=_0x13354e['getEngine'](),_0x2b9fba=!0x1,_0x5d7e9d=!0x1,_0x11d600=null,_0x502848=null,_0x1aa688=null,_0x35bdeb=_0x1c81f5['getCaps']();if(_0x13354e['format']=_0x2103ba['a']['TEXTUREFORMAT_RGBA'],_0x13354e['type']=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'],_0x13354e['generateMipMaps']=!0x0,_0x13354e['_cachedAnisotropicFilteringLevel']=null,_0x1c81f5['updateTextureSamplingMode'](_0x2103ba['a']['TEXTURE_TRILINEAR_SAMPLINGMODE'],_0x13354e),_0x35bdeb['textureLOD']?_0x1c81f5['webGLVersion']<0x2?_0x2b9fba=!0x1:_0x35bdeb['textureHalfFloatRender']&&_0x35bdeb['textureHalfFloatLinearFiltering']?(_0x2b9fba=!0x0,_0x13354e['type']=_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT']):_0x35bdeb['textureFloatRender']&&_0x35bdeb['textureFloatLinearFiltering']&&(_0x2b9fba=!0x0,_0x13354e['type']=_0x2103ba['a']['TEXTURETYPE_FLOAT']):(_0x2b9fba=!0x1,_0x5d7e9d=!0x0,_0x1aa688={}),_0x2b9fba)_0x11d600=new _0x5cae84('rgbdDecode','rgbdDecode',null,null,0x1,null,_0x2103ba['a']['TEXTURE_TRILINEAR_SAMPLINGMODE'],_0x1c81f5,!0x1,void 0x0,_0x13354e['type'],void 0x0,null,!0x1),_0x13354e['_isRGBD']=!0x1,_0x13354e['invertY']=!0x1,_0x502848=_0x1c81f5['createRenderTargetCubeTexture'](_0x13354e['width'],{'generateDepthBuffer':!0x1,'generateMipMaps':!0x0,'generateStencilBuffer':!0x1,'samplingMode':_0x2103ba['a']['TEXTURE_TRILINEAR_SAMPLINGMODE'],'type':_0x13354e['type'],'format':_0x2103ba['a']['TEXTUREFORMAT_RGBA']});else{if(_0x13354e['_isRGBD']=!0x0,_0x13354e['invertY']=!0x0,_0x5d7e9d)for(var _0x2bfdb1=_0x13354e['_lodGenerationScale'],_0x81307d=_0x13354e['_lodGenerationOffset'],_0x31bfd2=0x0;_0x31bfd2<0x3;_0x31bfd2++){var _0x532636=(_0x278779-0x1)*_0x2bfdb1+_0x81307d,_0x1449e3=_0x81307d+(_0x532636-_0x81307d)*(0x1-_0x31bfd2/0x2),_0x3649cb=Math['round'](Math['min'](Math['max'](_0x1449e3,0x0),_0x532636)),_0x314674=new _0x21ea74['a'](_0x1c81f5,_0x21ea74['b']['Temp']);_0x314674['isCube']=!0x0,_0x314674['invertY']=!0x0,_0x314674['generateMipMaps']=!0x1,_0x1c81f5['updateTextureSamplingMode'](_0x2103ba['a']['TEXTURE_LINEAR_LINEAR'],_0x314674);var _0x85cdb2=new _0x2268ea['a'](null);switch(_0x85cdb2['isCube']=!0x0,_0x85cdb2['_texture']=_0x314674,_0x1aa688[_0x3649cb]=_0x85cdb2,_0x31bfd2){case 0x0:_0x13354e['_lodTextureLow']=_0x85cdb2;break;case 0x1:_0x13354e['_lodTextureMid']=_0x85cdb2;break;case 0x2:_0x13354e['_lodTextureHigh']=_0x85cdb2;}}}var _0x125cea=[],_0x3feedc=function(_0x435ce3){for(var _0xd298c=function(_0xb1dc9c){var _0x53e63a=_0xf3fb40[_0x435ce3][_0xb1dc9c],_0x24041b=new Blob([_0x53e63a],{'type':'image/png'}),_0x4acd1d=URL['createObjectURL'](_0x24041b),_0x31e3a4=void 0x0;if('undefined'==typeof Image)_0x31e3a4=createImageBitmap(_0x24041b)['then'](function(_0x5f0d54){return _0x163e9a['_OnImageReadyAsync'](_0x5f0d54,_0x1c81f5,_0x2b9fba,_0x11d600,_0x4acd1d,_0xb1dc9c,_0x435ce3,_0x5d7e9d,_0x1aa688,_0x502848,_0x13354e);});else{var _0x3efef2=new Image();_0x3efef2['src']=_0x4acd1d,_0x31e3a4=new Promise(function(_0x14bb01,_0x4399f0){_0x3efef2['onload']=function(){_0x163e9a['_OnImageReadyAsync'](_0x3efef2,_0x1c81f5,_0x2b9fba,_0x11d600,_0x4acd1d,_0xb1dc9c,_0x435ce3,_0x5d7e9d,_0x1aa688,_0x502848,_0x13354e)['then'](function(){return _0x14bb01();})['catch'](function(_0x3d9c1c){_0x4399f0(_0x3d9c1c);});},_0x3efef2['onerror']=function(_0x3adce0){_0x4399f0(_0x3adce0);};});}_0x125cea['push'](_0x31e3a4);},_0x1a5c88=0x0;_0x1a5c88<0x6;_0x1a5c88++)_0xd298c(_0x1a5c88);};for(_0x31bfd2=0x0;_0x31bfd2<_0xf3fb40['length'];_0x31bfd2++)_0x3feedc(_0x31bfd2);if(_0xf3fb40['length']<_0x278779){var _0x348ae9=void 0x0,_0x43bcc4=Math['pow'](0x2,_0x278779-0x1-_0xf3fb40['length']),_0x591366=_0x43bcc4*_0x43bcc4*0x4;switch(_0x13354e['type']){case _0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']:_0x348ae9=new Uint8Array(_0x591366);break;case _0x2103ba['a']['TEXTURETYPE_HALF_FLOAT']:_0x348ae9=new Uint16Array(_0x591366);break;case _0x2103ba['a']['TEXTURETYPE_FLOAT']:_0x348ae9=new Float32Array(_0x591366);}for(_0x31bfd2=_0xf3fb40['length'];_0x31bfd2<_0x278779;_0x31bfd2++)for(var _0x430f3f=0x0;_0x430f3f<0x6;_0x430f3f++)_0x1c81f5['_uploadArrayBufferViewToTexture'](_0x13354e,_0x348ae9,_0x430f3f,_0x31bfd2);}return Promise['all'](_0x125cea)['then'](function(){_0x502848&&(_0x1c81f5['_releaseFramebufferObjects'](_0x502848),_0x1c81f5['_releaseTexture'](_0x13354e),_0x502848['_swapAndDie'](_0x13354e)),_0x11d600&&_0x11d600['dispose'](),_0x5d7e9d&&(_0x13354e['_lodTextureHigh']&&_0x13354e['_lodTextureHigh']['_texture']&&(_0x13354e['_lodTextureHigh']['_texture']['isReady']=!0x0),_0x13354e['_lodTextureMid']&&_0x13354e['_lodTextureMid']['_texture']&&(_0x13354e['_lodTextureMid']['_texture']['isReady']=!0x0),_0x13354e['_lodTextureLow']&&_0x13354e['_lodTextureLow']['_texture']&&(_0x13354e['_lodTextureLow']['_texture']['isReady']=!0x0));});},_0x1b77a3['UploadEnvSpherical']=function(_0xe597ec,_0x803d39){0x1!==_0x803d39['version']&&_0x75193d['a']['Warn']('Unsupported\x20babylon\x20environment\x20map\x20version\x20\x22'+_0x803d39['version']+'\x22');var _0x20469f=_0x803d39['irradiance'];if(_0x20469f){var _0x4dd0c2=new _0x23d472();_0x74d525['e']['FromArrayToRef'](_0x20469f['x'],0x0,_0x4dd0c2['x']),_0x74d525['e']['FromArrayToRef'](_0x20469f['y'],0x0,_0x4dd0c2['y']),_0x74d525['e']['FromArrayToRef'](_0x20469f['z'],0x0,_0x4dd0c2['z']),_0x74d525['e']['FromArrayToRef'](_0x20469f['xx'],0x0,_0x4dd0c2['xx']),_0x74d525['e']['FromArrayToRef'](_0x20469f['yy'],0x0,_0x4dd0c2['yy']),_0x74d525['e']['FromArrayToRef'](_0x20469f['zz'],0x0,_0x4dd0c2['zz']),_0x74d525['e']['FromArrayToRef'](_0x20469f['yz'],0x0,_0x4dd0c2['yz']),_0x74d525['e']['FromArrayToRef'](_0x20469f['zx'],0x0,_0x4dd0c2['zx']),_0x74d525['e']['FromArrayToRef'](_0x20469f['xy'],0x0,_0x4dd0c2['xy']),_0xe597ec['_sphericalPolynomial']=_0x4dd0c2;}},_0x1b77a3['_UpdateRGBDAsync']=function(_0x260ed4,_0x3efc13,_0x1f5e3d,_0x4fe3fb,_0x3bdb17){return _0x260ed4['_source']=_0x21ea74['b']['CubeRawRGBD'],_0x260ed4['_bufferViewArrayArray']=_0x3efc13,_0x260ed4['_lodGenerationScale']=_0x4fe3fb,_0x260ed4['_lodGenerationOffset']=_0x3bdb17,_0x260ed4['_sphericalPolynomial']=_0x1f5e3d,_0x1b77a3['UploadLevelsAsync'](_0x260ed4,_0x3efc13)['then'](function(){_0x260ed4['isReady']=!0x0;});},_0x1b77a3['_MagicBytes']=[0x86,0x16,0x87,0x96,0xf6,0xd6,0x96,0x36],_0x1b77a3;}());_0x21ea74['a']['_UpdateRGBDAsync']=_0x480d46['_UpdateRGBDAsync'];var _0x18784f,_0x1e1646=(function(){function _0x3c6f07(_0x380bc3,_0x385809){void 0x0===_0x385809&&(_0x385809=0x14),this['debug']=!0x1,this['_sourceCode']=_0x380bc3,this['_numMaxIterations']=_0x385809,this['_functionDescr']=[],this['inlineToken']='#define\x20inline';}return Object['defineProperty'](_0x3c6f07['prototype'],'code',{'get':function(){return this['_sourceCode'];},'enumerable':!0x1,'configurable':!0x0}),_0x3c6f07['prototype']['processCode']=function(){this['debug']&&console['log']('Start\x20inlining\x20process\x20(code\x20size='+this['_sourceCode']['length']+')...'),this['_collectFunctions'](),this['_processInlining'](this['_numMaxIterations']),this['debug']&&console['log']('End\x20of\x20inlining\x20process.');},_0x3c6f07['prototype']['_collectFunctions']=function(){for(var _0x32c871=0x0;_0x32c871=0x0&&_0x4280a9['push'](_0x52c317['substring'](_0x67fa3b+0x1));}'void'!==_0x1fdada&&_0x4280a9['push']('return'),this['_functionDescr']['push']({'name':_0x1523fd,'type':_0x1fdada,'parameters':_0x4280a9,'body':_0x5b84b4,'callIndex':0x0}),_0x32c871=_0x29ee18+0x1;var _0x4bf5b3=_0x5e71fc>0x0?this['_sourceCode']['substring'](0x0,_0x5e71fc):'',_0xefd66=_0x29ee18+0x1=0x0&&this['_replaceFunctionCallsByCode'](););return this['debug']&&console['log']('numMaxIterations\x20is\x20'+_0x33a2ac+'\x20after\x20inlining\x20process'),_0x33a2ac>=0x0;},_0x3c6f07['prototype']['_extractBetweenMarkers']=function(_0x33a04a,_0x3ee8fb,_0x33d0ed,_0x152dd9){for(var _0x576ebc=_0x152dd9,_0x47e4b0=0x0,_0x1feeac='';_0x576ebc<_0x33d0ed['length'];){var _0x4776c8=_0x33d0ed['charAt'](_0x576ebc);if(_0x1feeac)_0x4776c8===_0x1feeac?'\x22'===_0x1feeac||'\x27'===_0x1feeac?'\x5c'!==_0x33d0ed['charAt'](_0x576ebc-0x1)&&(_0x1feeac=''):_0x1feeac='':'*/'===_0x1feeac&&'*'===_0x4776c8&&_0x576ebc+0x1<_0x33d0ed['length']&&('/'===_0x33d0ed['charAt'](_0x576ebc+0x1)&&(_0x1feeac=''),''===_0x1feeac&&_0x576ebc++);else switch(_0x4776c8){case _0x33a04a:_0x47e4b0++;break;case _0x3ee8fb:_0x47e4b0--;break;case'\x22':case'\x27':case'`':_0x1feeac=_0x4776c8;break;case'/':if(_0x576ebc+0x1<_0x33d0ed['length']){var _0xbf575b=_0x33d0ed['charAt'](_0x576ebc+0x1);'/'===_0xbf575b?_0x1feeac='\x0a':'*'===_0xbf575b&&(_0x1feeac='*/');}}if(_0x576ebc++,0x0===_0x47e4b0)break;}return 0x0===_0x47e4b0?_0x576ebc-0x1:-0x1;},_0x3c6f07['prototype']['_skipWhitespaces']=function(_0x5b3a68,_0x3cfa26){for(;_0x3cfa26<_0x5b3a68['length'];){var _0x578d8a=_0x5b3a68[_0x3cfa26];if('\x20'!==_0x578d8a&&'\x0a'!==_0x578d8a&&'\x0d'!==_0x578d8a&&'\x09'!==_0x578d8a&&'\x0a'!==_0x578d8a&&'\u00a0'!==_0x578d8a)break;_0x3cfa26++;}return _0x3cfa26;},_0x3c6f07['prototype']['_removeComments']=function(_0x328903){for(var _0x1cff69=0x0,_0xb5ad2f='',_0x3d600d=!0x1,_0x378ca7=[];_0x1cff69<_0x328903['length'];){var _0x183c06=_0x328903['charAt'](_0x1cff69);if(_0xb5ad2f)_0x183c06===_0xb5ad2f?'\x22'===_0xb5ad2f||'\x27'===_0xb5ad2f?('\x5c'!==_0x328903['charAt'](_0x1cff69-0x1)&&(_0xb5ad2f=''),_0x378ca7['push'](_0x183c06)):(_0xb5ad2f='',_0x3d600d=!0x1):'*/'===_0xb5ad2f&&'*'===_0x183c06&&_0x1cff69+0x1<_0x328903['length']?('/'===_0x328903['charAt'](_0x1cff69+0x1)&&(_0xb5ad2f=''),''===_0xb5ad2f&&(_0x3d600d=!0x1,_0x1cff69++)):_0x3d600d||_0x378ca7['push'](_0x183c06);else{switch(_0x183c06){case'\x22':case'\x27':case'`':_0xb5ad2f=_0x183c06;break;case'/':if(_0x1cff69+0x1<_0x328903['length']){var _0x46224d=_0x328903['charAt'](_0x1cff69+0x1);'/'===_0x46224d?(_0xb5ad2f='\x0a',_0x3d600d=!0x0):'*'===_0x46224d&&(_0xb5ad2f='*/',_0x3d600d=!0x0);}}_0x3d600d||_0x378ca7['push'](_0x183c06);}_0x1cff69++;}return _0x378ca7['join']('');},_0x3c6f07['prototype']['_replaceFunctionCallsByCode']=function(){for(var _0x5c94b1=!0x1,_0x18a728=0x0,_0x20f60e=this['_functionDescr'];_0x18a728<_0x20f60e['length'];_0x18a728++)for(var _0x526b41=_0x20f60e[_0x18a728],_0xfb7317=_0x526b41['name'],_0x5c4a53=_0x526b41['type'],_0xdb3eef=_0x526b41['parameters'],_0x3ac606=_0x526b41['body'],_0x1f91ce=0x0;_0x1f91ce0x0?this['_sourceCode']['substring'](0x0,_0x4899ec):'',_0x303324=_0x30bdd7+0x1=0x0&&_0x3049df['charAt'](_0x40ef90)!==_0x15db21;)_0x40ef90--;return _0x40ef90;},_0x3c6f07['prototype']['_escapeRegExp']=function(_0x42409c){return _0x42409c['replace'](/[.*+?^${}()|[\]\\]/g,'\x5c$&');},_0x3c6f07['prototype']['_replaceNames']=function(_0x337bf6,_0x2170cf,_0x580f18){for(var _0x2292d6=0x0;_0x2292d6<_0x2170cf['length'];++_0x2292d6){var _0x2b0646=new RegExp(this['_escapeRegExp'](_0x2170cf[_0x2292d6]),'g'),_0x4f09cc=_0x580f18[_0x2292d6];_0x337bf6=_0x337bf6['replace'](_0x2b0646,_0x4f09cc);}return _0x337bf6;},_0x3c6f07['_RegexpFindFunctionNameAndType']=/((\s+?)(\w+)\s+(\w+)\s*?)$/,_0x3c6f07;}()),_0x23d700=(function(){function _0x37a70b(){this['isAsync']=!0x1,this['isReady']=!0x1;}return _0x37a70b['prototype']['_getVertexShaderCode']=function(){return null;},_0x37a70b['prototype']['_getFragmentShaderCode']=function(){return null;},_0x37a70b['prototype']['_handlesSpectorRebuildCallback']=function(_0x3707eb){throw new Error('Not\x20implemented');},_0x37a70b;}()),_0x32a08b=function(_0x28df10){function _0x164729(){return null!==_0x28df10&&_0x28df10['apply'](this,arguments)||this;}return Object(_0x18e13d['d'])(_0x164729,_0x28df10),_0x164729;}(_0x2b8850['a']),_0x589078=function(_0x5b1f0f){function _0x2b131f(){return null!==_0x5b1f0f&&_0x5b1f0f['apply'](this,arguments)||this;}return Object(_0x18e13d['d'])(_0x2b131f,_0x5b1f0f),_0x2b131f['prototype']['getInternalTexture']=function(){return this;},_0x2b131f['prototype']['getViewCount']=function(){return 0x1;},_0x2b131f;}(_0x21ea74['a']),_0xa5ed76=function(_0x394589){function _0x45108e(){var _0x19d9ce=_0x394589['call'](this,null)||this;return _0x19d9ce['_native']=new _native['Engine'](),_0x19d9ce['INVALID_HANDLE']=0xffff,_0x19d9ce['_boundBuffersVertexArray']=null,_0x19d9ce['_currentDepthTest']=_0x19d9ce['_native']['DEPTH_TEST_LEQUAL'],_0x19d9ce['_webGLVersion']=0x2,_0x19d9ce['disableUniformBuffers']=!0x0,_0x19d9ce['_caps']={'maxTexturesImageUnits':0x10,'maxVertexTextureImageUnits':0x10,'maxCombinedTexturesImageUnits':0x20,'maxTextureSize':0x200,'maxCubemapTextureSize':0x200,'maxRenderTextureSize':0x200,'maxVertexAttribs':0x10,'maxVaryingVectors':0x10,'maxFragmentUniformVectors':0x10,'maxVertexUniformVectors':0x10,'standardDerivatives':!0x0,'astc':null,'pvrtc':null,'etc1':null,'etc2':null,'bptc':null,'maxAnisotropy':0x10,'uintIndices':!0x0,'fragmentDepthSupported':!0x1,'highPrecisionShaderSupported':!0x0,'colorBufferFloat':!0x1,'textureFloat':!0x1,'textureFloatLinearFiltering':!0x1,'textureFloatRender':!0x1,'textureHalfFloat':!0x1,'textureHalfFloatLinearFiltering':!0x1,'textureHalfFloatRender':!0x1,'textureLOD':!0x0,'drawBuffersExtension':!0x1,'depthTextureExtension':!0x1,'vertexArrayObject':!0x0,'instancedArrays':!0x1,'canUseTimestampForTimerQuery':!0x1,'blendMinMax':!0x1,'maxMSAASamples':0x1},_0x5d754c['b']['Log']('Babylon\x20Native\x20(v'+_0x300b38['a']['Version']+')\x20launched'),_0x5d754c['b']['LoadScript']=function(_0x5f2ed0,_0x5da11c,_0xe862b,_0x187454){_0x5d754c['b']['LoadFile'](_0x5f2ed0,function(_0xaf783){Function(_0xaf783)['apply'](null),_0x5da11c&&_0x5da11c();},void 0x0,void 0x0,!0x1,function(_0x1baccc,_0x796ff5){_0xe862b&&_0xe862b('LoadScript\x20Error',_0x796ff5);});},'undefined'==typeof URL&&(window['URL']={'createObjectURL':function(){},'revokeObjectURL':function(){}}),'undefined'==typeof Blob&&(window['Blob']=function(){}),_0x19d9ce['_shaderProcessor']=new _0x304729['a'](),_0x19d9ce;}return Object(_0x18e13d['d'])(_0x45108e,_0x394589),_0x45108e['prototype']['getHardwareScalingLevel']=function(){return 0x1;},_0x45108e['prototype']['dispose']=function(){_0x394589['prototype']['dispose']['call'](this),this['_boundBuffersVertexArray']&&this['_native']['deleteVertexArray'](this['_boundBuffersVertexArray']),this['_native']['dispose']();},_0x45108e['prototype']['_queueNewFrame']=function(_0x5d2c83,_0x70b2e4){return _0x70b2e4['requestAnimationFrame']&&_0x70b2e4!==window?_0x70b2e4['requestAnimationFrame'](_0x5d2c83):this['_native']['requestAnimationFrame'](_0x5d2c83),0x0;},_0x45108e['prototype']['_bindUnboundFramebuffer']=function(_0x58f2cf){this['_currentFramebuffer']!==_0x58f2cf&&(this['_currentFramebuffer']&&this['_native']['unbindFramebuffer'](this['_currentFramebuffer']),_0x58f2cf&&this['_native']['bindFramebuffer'](_0x58f2cf),this['_currentFramebuffer']=_0x58f2cf);},_0x45108e['prototype']['getHostDocument']=function(){return null;},_0x45108e['prototype']['clear']=function(_0x4924c1,_0x1dd8de,_0x52d832,_0xf0fae5){void 0x0===_0xf0fae5&&(_0xf0fae5=!0x1);var _0x4809cf=0x0;_0x1dd8de&&_0x4924c1&&(this['_native']['clearColor'](_0x4924c1['r'],_0x4924c1['g'],_0x4924c1['b'],void 0x0!==_0x4924c1['a']?_0x4924c1['a']:0x1),_0x4809cf|=this['_native']['CLEAR_FLAG_COLOR']),_0x52d832&&(this['_native']['clearDepth'](0x1),_0x4809cf|=this['_native']['CLEAR_FLAG_DEPTH']),_0xf0fae5&&(this['_native']['clearStencil'](0x0),_0x4809cf|=this['_native']['CLEAR_FLAG_STENCIL']),this['_native']['clear'](_0x4809cf);},_0x45108e['prototype']['createIndexBuffer']=function(_0x31f3af,_0x24e8c9){var _0x4874ca=this['_normalizeIndexData'](_0x31f3af),_0x290082=new _0x32a08b();if(_0x290082['references']=0x1,_0x290082['is32Bits']=0x4===_0x4874ca['BYTES_PER_ELEMENT'],_0x4874ca['length']){if(_0x290082['nativeIndexBuffer']=this['_native']['createIndexBuffer'](_0x4874ca,null!=_0x24e8c9&&_0x24e8c9),_0x290082['nativeVertexBuffer']===this['INVALID_HANDLE'])throw new Error('Could\x20not\x20create\x20a\x20native\x20index\x20buffer.');}else _0x290082['nativeVertexBuffer']=this['INVALID_HANDLE'];return _0x290082;},_0x45108e['prototype']['createVertexBuffer']=function(_0x146ed7,_0x5b40a7){var _0x5f0c97=new _0x32a08b();if(_0x5f0c97['references']=0x1,_0x5f0c97['nativeVertexBuffer']=this['_native']['createVertexBuffer'](ArrayBuffer['isView'](_0x146ed7)?_0x146ed7:new Float32Array(_0x146ed7),null!=_0x5b40a7&&_0x5b40a7),_0x5f0c97['nativeVertexBuffer']===this['INVALID_HANDLE'])throw new Error('Could\x20not\x20create\x20a\x20native\x20vertex\x20buffer.');return _0x5f0c97;},_0x45108e['prototype']['_recordVertexArrayObject']=function(_0x4354fe,_0x71cb9c,_0x486467,_0x142975){_0x486467&&this['_native']['recordIndexBuffer'](_0x4354fe,_0x486467['nativeIndexBuffer']);for(var _0x4ce6d6=_0x142975['getAttributesNames'](),_0x2a4ec1=0x0;_0x2a4ec1<_0x4ce6d6['length'];_0x2a4ec1++){var _0x17ee8b=_0x142975['getAttributeLocation'](_0x2a4ec1);if(_0x17ee8b>=0x0){var _0x4595ac=_0x71cb9c[_0x4ce6d6[_0x2a4ec1]];if(_0x4595ac){var _0x298567=_0x4595ac['getBuffer']();_0x298567&&this['_native']['recordVertexBuffer'](_0x4354fe,_0x298567['nativeVertexBuffer'],_0x17ee8b,_0x4595ac['byteOffset'],_0x4595ac['byteStride'],_0x4595ac['getSize'](),this['_getNativeAttribType'](_0x4595ac['type']),_0x4595ac['normalized']);}}}},_0x45108e['prototype']['bindBuffers']=function(_0x22d542,_0x3ea4a8,_0x3052c2){this['_boundBuffersVertexArray']&&this['_native']['deleteVertexArray'](this['_boundBuffersVertexArray']),this['_boundBuffersVertexArray']=this['_native']['createVertexArray'](),this['_recordVertexArrayObject'](this['_boundBuffersVertexArray'],_0x22d542,_0x3ea4a8,_0x3052c2),this['_native']['bindVertexArray'](this['_boundBuffersVertexArray']);},_0x45108e['prototype']['recordVertexArrayObject']=function(_0x382303,_0x43975c,_0x3f6907){var _0x4176d7=this['_native']['createVertexArray']();return this['_recordVertexArrayObject'](_0x4176d7,_0x382303,_0x43975c,_0x3f6907),_0x4176d7;},_0x45108e['prototype']['bindVertexArrayObject']=function(_0xc71fec){this['_native']['bindVertexArray'](_0xc71fec);},_0x45108e['prototype']['releaseVertexArrayObject']=function(_0x4653fa){this['_native']['deleteVertexArray'](_0x4653fa);},_0x45108e['prototype']['getAttributes']=function(_0x39a7c3,_0x1db725){var _0x49fea7=_0x39a7c3;return this['_native']['getAttributes'](_0x49fea7['nativeProgram'],_0x1db725);},_0x45108e['prototype']['drawElementsType']=function(_0x38d568,_0x2e99a2,_0x309b0e,_0x1bb399){this['_drawCalls']['addCount'](0x1,!0x1),this['_native']['drawIndexed'](_0x38d568,_0x2e99a2,_0x309b0e);},_0x45108e['prototype']['drawArraysType']=function(_0x48af4c,_0x562de9,_0x13330b,_0x5bb159){this['_drawCalls']['addCount'](0x1,!0x1),this['_native']['draw'](_0x48af4c,_0x562de9,_0x13330b);},_0x45108e['prototype']['createPipelineContext']=function(){return new _0x23d700();},_0x45108e['prototype']['_preparePipelineContext']=function(_0x52ed20,_0x2611ac,_0x48edc2,_0x828abd,_0x368566,_0x6630ea,_0x40b13e){var _0x1c4990=_0x52ed20;_0x1c4990['nativeProgram']=_0x828abd?this['createRawShaderProgram'](_0x52ed20,_0x2611ac,_0x48edc2,void 0x0,_0x40b13e):this['createShaderProgram'](_0x52ed20,_0x2611ac,_0x48edc2,_0x6630ea,void 0x0,_0x40b13e);},_0x45108e['prototype']['_isRenderingStateCompiled']=function(_0x3ff010){return!0x0;},_0x45108e['prototype']['_executeWhenRenderingStateIsCompiled']=function(_0x2e87a5,_0x22801d){_0x22801d();},_0x45108e['prototype']['createRawShaderProgram']=function(_0x593d04,_0x1497e4,_0x581248,_0x53a26b,_0x4dbe9f){throw void 0x0===_0x4dbe9f&&(_0x4dbe9f=null),new Error('Not\x20Supported');},_0x45108e['prototype']['createShaderProgram']=function(_0x157272,_0x185978,_0xc713a6,_0x169fe8,_0x3800d4,_0x4f37c0){void 0x0===_0x4f37c0&&(_0x4f37c0=null),this['onBeforeShaderCompilationObservable']['notifyObservers'](this);var _0x11fd5f=new _0x1e1646(_0x185978);_0x11fd5f['processCode'](),_0x185978=_0x11fd5f['code'];var _0x560951=new _0x1e1646(_0xc713a6);_0x560951['processCode'](),_0xc713a6=_0x560951['code'],_0x185978=_0x26966b['a']['_ConcatenateShader'](_0x185978,_0x169fe8),_0xc713a6=_0x26966b['a']['_ConcatenateShader'](_0xc713a6,_0x169fe8);var _0x38c7fa=this['_native']['createProgram'](_0x185978,_0xc713a6);return this['onAfterShaderCompilationObservable']['notifyObservers'](this),_0x38c7fa;},_0x45108e['prototype']['_setProgram']=function(_0x9d5c87){this['_currentProgram']!==_0x9d5c87&&(this['_native']['setProgram'](_0x9d5c87),this['_currentProgram']=_0x9d5c87);},_0x45108e['prototype']['_releaseEffect']=function(_0x312963){},_0x45108e['prototype']['_deletePipelineContext']=function(_0x287db7){},_0x45108e['prototype']['getUniforms']=function(_0x53079d,_0x16ead7){var _0x17f6c4=_0x53079d;return this['_native']['getUniforms'](_0x17f6c4['nativeProgram'],_0x16ead7);},_0x45108e['prototype']['bindUniformBlock']=function(_0x7dbb8e,_0x141e9a,_0x319ee2){throw new Error('Not\x20Implemented');},_0x45108e['prototype']['bindSamplers']=function(_0x5a94d0){var _0x23030d=_0x5a94d0['getPipelineContext']();this['_setProgram'](_0x23030d['nativeProgram']);for(var _0x5cb9d8=_0x5a94d0['getSamplers'](),_0x396a34=0x0;_0x396a34<_0x5cb9d8['length'];_0x396a34++){var _0x22b411=_0x5a94d0['getUniform'](_0x5cb9d8[_0x396a34]);_0x22b411&&(this['_boundUniforms'][_0x396a34]=_0x22b411);}this['_currentEffect']=null;},_0x45108e['prototype']['setMatrix']=function(_0x91dee9,_0xf28ec1){_0x91dee9&&this['_native']['setMatrix'](_0x91dee9,_0xf28ec1['toArray']());},_0x45108e['prototype']['getRenderWidth']=function(_0x13d847){return void 0x0===_0x13d847&&(_0x13d847=!0x1),!_0x13d847&&this['_currentRenderTarget']?this['_currentRenderTarget']['width']:this['_native']['getRenderWidth']();},_0x45108e['prototype']['getRenderHeight']=function(_0x510a6d){return void 0x0===_0x510a6d&&(_0x510a6d=!0x1),!_0x510a6d&&this['_currentRenderTarget']?this['_currentRenderTarget']['height']:this['_native']['getRenderHeight']();},_0x45108e['prototype']['setViewport']=function(_0x40c94b,_0xcde23d,_0x5def7d){this['_cachedViewport']=_0x40c94b,this['_native']['setViewPort'](_0x40c94b['x'],_0x40c94b['y'],_0x40c94b['width'],_0x40c94b['height']);},_0x45108e['prototype']['setState']=function(_0x2da523,_0x144544,_0x240d7d,_0x3b78ce){void 0x0===_0x144544&&(_0x144544=0x0),void 0x0===_0x3b78ce&&(_0x3b78ce=!0x1),this['_native']['setState'](_0x2da523,_0x144544,_0x3b78ce);},_0x45108e['prototype']['setZOffset']=function(_0x2859a6){this['_native']['setZOffset'](_0x2859a6);},_0x45108e['prototype']['getZOffset']=function(){return this['_native']['getZOffset']();},_0x45108e['prototype']['setDepthBuffer']=function(_0x21e3e7){this['_native']['setDepthTest'](_0x21e3e7?this['_currentDepthTest']:this['_native']['DEPTH_TEST_ALWAYS']);},_0x45108e['prototype']['getDepthWrite']=function(){return this['_native']['getDepthWrite']();},_0x45108e['prototype']['setDepthFunctionToGreater']=function(){this['_currentDepthTest']=this['_native']['DEPTH_TEST_GREATER'],this['_native']['setDepthTest'](this['_currentDepthTest']);},_0x45108e['prototype']['setDepthFunctionToGreaterOrEqual']=function(){this['_currentDepthTest']=this['_native']['DEPTH_TEST_GEQUAL'],this['_native']['setDepthTest'](this['_currentDepthTest']);},_0x45108e['prototype']['setDepthFunctionToLess']=function(){this['_currentDepthTest']=this['_native']['DEPTH_TEST_LESS'],this['_native']['setDepthTest'](this['_currentDepthTest']);},_0x45108e['prototype']['setDepthFunctionToLessOrEqual']=function(){this['_currentDepthTest']=this['_native']['DEPTH_TEST_LEQUAL'],this['_native']['setDepthTest'](this['_currentDepthTest']);},_0x45108e['prototype']['setDepthWrite']=function(_0x1e6a5d){this['_native']['setDepthWrite'](_0x1e6a5d);},_0x45108e['prototype']['setColorWrite']=function(_0x32ff84){this['_native']['setColorWrite'](_0x32ff84),this['_colorWrite']=_0x32ff84;},_0x45108e['prototype']['getColorWrite']=function(){return this['_colorWrite'];},_0x45108e['prototype']['setAlphaConstants']=function(_0x4a2964,_0x34932e,_0x59b02d,_0x539335){throw new Error('Setting\x20alpha\x20blend\x20constant\x20color\x20not\x20yet\x20implemented.');},_0x45108e['prototype']['setAlphaMode']=function(_0x2308a9,_0x26afb6){void 0x0===_0x26afb6&&(_0x26afb6=!0x1),this['_alphaMode']!==_0x2308a9&&(_0x2308a9=this['_getNativeAlphaMode'](_0x2308a9),this['_native']['setBlendMode'](_0x2308a9),_0x26afb6||this['setDepthWrite'](_0x2308a9===_0x2103ba['a']['ALPHA_DISABLE']),this['_alphaMode']=_0x2308a9);},_0x45108e['prototype']['getAlphaMode']=function(){return this['_alphaMode'];},_0x45108e['prototype']['setInt']=function(_0x3a4fd2,_0x115d6f){return!!_0x3a4fd2&&(this['_native']['setInt'](_0x3a4fd2,_0x115d6f),!0x0);},_0x45108e['prototype']['setIntArray']=function(_0x2e5552,_0x105232){return!!_0x2e5552&&(this['_native']['setIntArray'](_0x2e5552,_0x105232),!0x0);},_0x45108e['prototype']['setIntArray2']=function(_0x461c23,_0x5a044b){return!!_0x461c23&&(this['_native']['setIntArray2'](_0x461c23,_0x5a044b),!0x0);},_0x45108e['prototype']['setIntArray3']=function(_0x51ddcc,_0x1c4877){return!!_0x51ddcc&&(this['_native']['setIntArray3'](_0x51ddcc,_0x1c4877),!0x0);},_0x45108e['prototype']['setIntArray4']=function(_0x186269,_0x538518){return!!_0x186269&&(this['_native']['setIntArray4'](_0x186269,_0x538518),!0x0);},_0x45108e['prototype']['setFloatArray']=function(_0x11bb0c,_0x58810d){return!!_0x11bb0c&&(this['_native']['setFloatArray'](_0x11bb0c,_0x58810d),!0x0);},_0x45108e['prototype']['setFloatArray2']=function(_0x4b20ec,_0xa28157){return!!_0x4b20ec&&(this['_native']['setFloatArray2'](_0x4b20ec,_0xa28157),!0x0);},_0x45108e['prototype']['setFloatArray3']=function(_0x44fb4b,_0x13aa8d){return!!_0x44fb4b&&(this['_native']['setFloatArray3'](_0x44fb4b,_0x13aa8d),!0x0);},_0x45108e['prototype']['setFloatArray4']=function(_0x3c7d2e,_0x5592f0){return!!_0x3c7d2e&&(this['_native']['setFloatArray4'](_0x3c7d2e,_0x5592f0),!0x0);},_0x45108e['prototype']['setArray']=function(_0x3e8329,_0x19284b){return!!_0x3e8329&&(this['_native']['setFloatArray'](_0x3e8329,_0x19284b),!0x0);},_0x45108e['prototype']['setArray2']=function(_0x4f8fd8,_0x409fa0){return!!_0x4f8fd8&&(this['_native']['setFloatArray2'](_0x4f8fd8,_0x409fa0),!0x0);},_0x45108e['prototype']['setArray3']=function(_0x2d6865,_0x38c330){return!!_0x2d6865&&(this['_native']['setFloatArray3'](_0x2d6865,_0x38c330),!0x0);},_0x45108e['prototype']['setArray4']=function(_0xbeff0c,_0x4a2bbc){return!!_0xbeff0c&&(this['_native']['setFloatArray4'](_0xbeff0c,_0x4a2bbc),!0x0);},_0x45108e['prototype']['setMatrices']=function(_0x595697,_0xed1622){return!!_0x595697&&(this['_native']['setMatrices'](_0x595697,_0xed1622),!0x0);},_0x45108e['prototype']['setMatrix3x3']=function(_0x5acd89,_0x280d3d){return!!_0x5acd89&&(this['_native']['setMatrix3x3'](_0x5acd89,_0x280d3d),!0x0);},_0x45108e['prototype']['setMatrix2x2']=function(_0x5b0b88,_0x2fe1d9){return!!_0x5b0b88&&(this['_native']['setMatrix2x2'](_0x5b0b88,_0x2fe1d9),!0x0);},_0x45108e['prototype']['setFloat']=function(_0x1bc12b,_0x532eb3){return!!_0x1bc12b&&(this['_native']['setFloat'](_0x1bc12b,_0x532eb3),!0x0);},_0x45108e['prototype']['setFloat2']=function(_0x1e7dfd,_0x4c6529,_0x1e623b){return!!_0x1e7dfd&&(this['_native']['setFloat2'](_0x1e7dfd,_0x4c6529,_0x1e623b),!0x0);},_0x45108e['prototype']['setFloat3']=function(_0x16abbd,_0x571cc3,_0x49dde9,_0x2c19d7){return!!_0x16abbd&&(this['_native']['setFloat3'](_0x16abbd,_0x571cc3,_0x49dde9,_0x2c19d7),!0x0);},_0x45108e['prototype']['setFloat4']=function(_0x435ee9,_0x3b776f,_0x3ae76b,_0x5d544c,_0x3d339d){return!!_0x435ee9&&(this['_native']['setFloat4'](_0x435ee9,_0x3b776f,_0x3ae76b,_0x5d544c,_0x3d339d),!0x0);},_0x45108e['prototype']['setColor3']=function(_0x2207a7,_0x1d29a5){return!!_0x2207a7&&(this['_native']['setFloat3'](_0x2207a7,_0x1d29a5['r'],_0x1d29a5['g'],_0x1d29a5['b']),!0x0);},_0x45108e['prototype']['setColor4']=function(_0x3657d6,_0x285a8a,_0x18b2d0){return!!_0x3657d6&&(this['_native']['setFloat4'](_0x3657d6,_0x285a8a['r'],_0x285a8a['g'],_0x285a8a['b'],_0x18b2d0),!0x0);},_0x45108e['prototype']['wipeCaches']=function(_0x135c85){this['preventCacheWipeBetweenFrames']||(this['resetTextureCache'](),this['_currentEffect']=null,_0x135c85&&(this['_currentProgram']=null,this['_stencilState']['reset'](),this['_depthCullingState']['reset'](),this['_alphaState']['reset']()),this['_cachedVertexBuffers']=null,this['_cachedIndexBuffer']=null,this['_cachedEffectForVertexBuffers']=null);},_0x45108e['prototype']['_createTexture']=function(){return this['_native']['createTexture']();},_0x45108e['prototype']['_deleteTexture']=function(_0x1ed2f2){this['_native']['deleteTexture'](_0x1ed2f2);},_0x45108e['prototype']['updateDynamicTexture']=function(_0x5670c3,_0xc74905,_0x3d1648,_0x299b31,_0x41f398){void 0x0===_0x299b31&&(_0x299b31=!0x1),this['createTexture']('data:my_image_name',!0x0,_0x3d1648,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],void 0x0,void 0x0,'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAYAAADED76LAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAYSURBVChTY/z//z8DPsAEpXGC4aCAgQEAGGMDDWwwgqsAAAAASUVORK5CYII=',_0x5670c3,_0x45108e['TEXTUREFORMAT_RGBA'],null,void 0x0);},_0x45108e['prototype']['createTexture']=function(_0xfcb3d7,_0x5023a0,_0xc54f2,_0x28cd0f,_0xaf4296,_0x18263a,_0x1e4913,_0x200760,_0x32d6d8,_0x2e8a04,_0x40c7d3,_0x4154d9,_0x184885){var _0x68a5be=this;void 0x0===_0xaf4296&&(_0xaf4296=_0x2103ba['a']['TEXTURE_TRILINEAR_SAMPLINGMODE']),void 0x0===_0x18263a&&(_0x18263a=null),void 0x0===_0x1e4913&&(_0x1e4913=null),void 0x0===_0x200760&&(_0x200760=null),void 0x0===_0x32d6d8&&(_0x32d6d8=null),void 0x0===_0x2e8a04&&(_0x2e8a04=null),void 0x0===_0x40c7d3&&(_0x40c7d3=null);var _0x17a3b6='data:'===(_0xfcb3d7=_0xfcb3d7||'')['substr'](0x0,0x5),_0x525acd=_0x17a3b6&&-0x1!==_0xfcb3d7['indexOf'](';base64,'),_0x43ba1e=_0x32d6d8||new _0x21ea74['a'](this,_0x21ea74['b']['Url']),_0x516147=_0xfcb3d7;!this['_transformTextureUrl']||_0x525acd||_0x32d6d8||_0x200760||(_0xfcb3d7=this['_transformTextureUrl'](_0xfcb3d7));for(var _0x2ee8bf=_0xfcb3d7['lastIndexOf']('.'),_0x3dcc37=_0x40c7d3||(_0x2ee8bf>-0x1?_0xfcb3d7['substring'](_0x2ee8bf)['toLowerCase']():''),_0x224c53=null,_0x3f4919=0x0,_0x29b401=_0x300b38['a']['_TextureLoaders'];_0x3f4919<_0x29b401['length'];_0x3f4919++){var _0x5dff66=_0x29b401[_0x3f4919];if(_0x5dff66['canLoad'](_0x3dcc37)){_0x224c53=_0x5dff66;break;}}_0x28cd0f&&_0x28cd0f['_addPendingData'](_0x43ba1e),_0x43ba1e['url']=_0xfcb3d7,_0x43ba1e['generateMipMaps']=!_0x5023a0,_0x43ba1e['samplingMode']=_0xaf4296,_0x43ba1e['invertY']=_0xc54f2,this['doNotHandleContextLost']||(_0x43ba1e['_buffer']=_0x200760);var _0x5862c2=null;_0x18263a&&!_0x32d6d8&&(_0x5862c2=_0x43ba1e['onLoadedObservable']['add'](_0x18263a)),_0x32d6d8||this['_internalTexturesCache']['push'](_0x43ba1e);if(_0x224c53)throw new Error('Loading\x20textures\x20from\x20IInternalTextureLoader\x20not\x20yet\x20implemented.');var _0x6fc533=function(_0x322a8e){var _0x2309fb=_0x43ba1e['_webGLTexture'];_0x2309fb?_0x68a5be['_native']['loadTexture'](_0x2309fb,_0x322a8e,!_0x5023a0,_0xc54f2,function(){_0x43ba1e['baseWidth']=_0x68a5be['_native']['getTextureWidth'](_0x2309fb),_0x43ba1e['baseHeight']=_0x68a5be['_native']['getTextureHeight'](_0x2309fb),_0x43ba1e['width']=_0x43ba1e['baseWidth'],_0x43ba1e['height']=_0x43ba1e['baseHeight'],_0x43ba1e['isReady']=!0x0;var _0x16f54f=_0x68a5be['_getNativeSamplingMode'](_0xaf4296);_0x68a5be['_native']['setTextureSampling'](_0x2309fb,_0x16f54f),_0x28cd0f&&_0x28cd0f['_removePendingData'](_0x43ba1e),_0x43ba1e['onLoadedObservable']['notifyObservers'](_0x43ba1e),_0x43ba1e['onLoadedObservable']['clear']();},function(){throw new Error('Could\x20not\x20load\x20a\x20native\x20texture.');}):_0x28cd0f&&_0x28cd0f['_removePendingData'](_0x43ba1e);};if(_0x17a3b6){if(_0x200760 instanceof ArrayBuffer)_0x6fc533(new Uint8Array(_0x200760));else{if(ArrayBuffer['isView'](_0x200760))_0x6fc533(_0x200760);else{if('string'!=typeof _0x200760)throw new Error('Unsupported\x20buffer\x20type');_0x6fc533(new Uint8Array(_0x5d754c['b']['DecodeBase64'](_0x200760)));}}}else _0x525acd?_0x6fc533(new Uint8Array(_0x5d754c['b']['DecodeBase64'](_0xfcb3d7))):this['_loadFile'](_0xfcb3d7,function(_0x5a2d74){return _0x6fc533(new Uint8Array(_0x5a2d74));},void 0x0,void 0x0,!0x0,function(_0x273af0,_0x6ad866){!function(_0x52d5d3,_0x5b1267){_0x28cd0f&&_0x28cd0f['_removePendingData'](_0x43ba1e),_0xfcb3d7===_0x516147?(_0x5862c2&&_0x43ba1e['onLoadedObservable']['remove'](_0x5862c2),_0x44b9ce['a']['UseFallbackTexture']&&_0x68a5be['createTexture'](_0x44b9ce['a']['FallbackTexture'],_0x5023a0,_0x43ba1e['invertY'],_0x28cd0f,_0xaf4296,null,_0x1e4913,_0x200760,_0x43ba1e),_0x1e4913&&_0x1e4913((_0x52d5d3||'Unknown\x20error')+(_0x44b9ce['a']['UseFallbackTexture']?'\x20-\x20Fallback\x20texture\x20was\x20used':''),_0x5b1267)):(_0x75193d['a']['Warn']('Failed\x20to\x20load\x20'+_0xfcb3d7+',\x20falling\x20back\x20to\x20'+_0x516147),_0x68a5be['createTexture'](_0x516147,_0x5023a0,_0x43ba1e['invertY'],_0x28cd0f,_0xaf4296,_0x18263a,_0x1e4913,_0x200760,_0x43ba1e,_0x2e8a04,_0x40c7d3,_0x4154d9,_0x184885));}('Unable\x20to\x20load\x20'+(_0x273af0&&_0x273af0['responseURL'],_0x6ad866));});return _0x43ba1e;},_0x45108e['prototype']['_createDepthStencilTexture']=function(_0x4d1dfa,_0x336572){var _0x1ef5f3=new _0x589078(this,_0x21ea74['b']['Depth']),_0x556dd5=_0x4d1dfa['width']||_0x4d1dfa,_0x384c8f=_0x4d1dfa['height']||_0x4d1dfa,_0x48843e=this['_native']['createDepthTexture'](_0x1ef5f3['_webGLTexture'],_0x556dd5,_0x384c8f);return _0x1ef5f3['_framebuffer']=_0x48843e,_0x1ef5f3;},_0x45108e['prototype']['_releaseFramebufferObjects']=function(_0x4f9a94){},_0x45108e['prototype']['createCubeTexture']=function(_0x1977bb,_0x28b23b,_0x2a2c76,_0x4ddfde,_0x3d0ce9,_0x5cb87e,_0x2eceab,_0x422f27,_0x50df01,_0x1bbc41,_0x5300df,_0xab0c80){var _0x4a1cf9=this;void 0x0===_0x3d0ce9&&(_0x3d0ce9=null),void 0x0===_0x5cb87e&&(_0x5cb87e=null),void 0x0===_0x422f27&&(_0x422f27=null),void 0x0===_0x50df01&&(_0x50df01=!0x1),void 0x0===_0x1bbc41&&(_0x1bbc41=0x0),void 0x0===_0x5300df&&(_0x5300df=0x0),void 0x0===_0xab0c80&&(_0xab0c80=null);var _0x2d45cd=_0xab0c80||new _0x21ea74['a'](this,_0x21ea74['b']['Cube']);_0x2d45cd['isCube']=!0x0,_0x2d45cd['url']=_0x1977bb,_0x2d45cd['generateMipMaps']=!_0x4ddfde,_0x2d45cd['_lodGenerationScale']=_0x1bbc41,_0x2d45cd['_lodGenerationOffset']=_0x5300df,this['_doNotHandleContextLost']||(_0x2d45cd['_extension']=_0x422f27,_0x2d45cd['_files']=_0x2a2c76);var _0x21b7a5=_0x1977bb['lastIndexOf']('.');if('.env'===(_0x422f27||(_0x21b7a5>-0x1?_0x1977bb['substring'](_0x21b7a5)['toLowerCase']():''))){if(_0x2a2c76&&0x6===_0x2a2c76['length'])throw new Error('Multi-file\x20loading\x20not\x20allowed\x20on\x20env\x20files.');this['_loadFile'](_0x1977bb,function(_0xc7de44){return function(_0x3024a0){var _0x2d709d=_0x480d46['GetEnvInfo'](_0x3024a0);if(_0x2d45cd['width']=_0x2d709d['width'],_0x2d45cd['height']=_0x2d709d['width'],_0x480d46['UploadEnvSpherical'](_0x2d45cd,_0x2d709d),0x1!==_0x2d709d['version'])throw new Error('Unsupported\x20babylon\x20environment\x20map\x20version\x20\x22'+_0x2d709d['version']+'\x22');var _0x17fd38=_0x2d709d['specular'];if(!_0x17fd38)throw new Error('Nothing\x20else\x20parsed\x20so\x20far');_0x2d45cd['_lodGenerationScale']=_0x17fd38['lodGenerationScale'];var _0x1da08a=_0x480d46['CreateImageDataArrayBufferViews'](_0x3024a0,_0x2d709d);_0x2d45cd['format']=_0x2103ba['a']['TEXTUREFORMAT_RGBA'],_0x2d45cd['type']=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'],_0x2d45cd['generateMipMaps']=!0x0,_0x2d45cd['getEngine']()['updateTextureSamplingMode'](_0xaf3c80['a']['TRILINEAR_SAMPLINGMODE'],_0x2d45cd),_0x2d45cd['_isRGBD']=!0x0,_0x2d45cd['invertY']=!0x0,_0x4a1cf9['_native']['loadCubeTextureWithMips'](_0x2d45cd['_webGLTexture'],_0x1da08a,function(){_0x2d45cd['isReady']=!0x0,_0x3d0ce9&&_0x3d0ce9();},function(){throw new Error('Could\x20not\x20load\x20a\x20native\x20cube\x20texture.');});}(new Uint8Array(_0xc7de44));},void 0x0,void 0x0,!0x0,function(_0x1cb058,_0x105d62){_0x5cb87e&&_0x1cb058&&_0x5cb87e(_0x1cb058['status']+'\x20'+_0x1cb058['statusText'],_0x105d62);});}else{if(!_0x2a2c76||0x6!==_0x2a2c76['length'])throw new Error('Cannot\x20load\x20cubemap\x20because\x206\x20files\x20were\x20not\x20defined');var _0x3532f2=[_0x2a2c76[0x0],_0x2a2c76[0x3],_0x2a2c76[0x1],_0x2a2c76[0x4],_0x2a2c76[0x2],_0x2a2c76[0x5]];Promise['all'](_0x3532f2['map'](function(_0x43d8d2){return _0x5d754c['b']['LoadFileAsync'](_0x43d8d2)['then'](function(_0x35de61){return new Uint8Array(_0x35de61);});}))['then'](function(_0x2e2bd4){return new Promise(function(_0xcf8834,_0x38fd33){_0x4a1cf9['_native']['loadCubeTexture'](_0x2d45cd['_webGLTexture'],_0x2e2bd4,!_0x4ddfde,_0xcf8834,_0x38fd33);});})['then'](function(){_0x2d45cd['isReady']=!0x0,_0x3d0ce9&&_0x3d0ce9();},function(_0x5e8459){_0x5cb87e&&_0x5cb87e('Failed\x20to\x20load\x20cubemap:\x20'+_0x5e8459['message'],_0x5e8459);});}return this['_internalTexturesCache']['push'](_0x2d45cd),_0x2d45cd;},_0x45108e['prototype']['createRenderTargetTexture']=function(_0x430680,_0x4c5e6c){var _0x4aeb23=new _0x36b220['a']();void 0x0!==_0x4c5e6c&&'object'==typeof _0x4c5e6c?(_0x4aeb23['generateMipMaps']=_0x4c5e6c['generateMipMaps'],_0x4aeb23['generateDepthBuffer']=void 0x0===_0x4c5e6c['generateDepthBuffer']||_0x4c5e6c['generateDepthBuffer'],_0x4aeb23['generateStencilBuffer']=_0x4aeb23['generateDepthBuffer']&&_0x4c5e6c['generateStencilBuffer'],_0x4aeb23['type']=void 0x0===_0x4c5e6c['type']?_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']:_0x4c5e6c['type'],_0x4aeb23['samplingMode']=void 0x0===_0x4c5e6c['samplingMode']?_0x2103ba['a']['TEXTURE_TRILINEAR_SAMPLINGMODE']:_0x4c5e6c['samplingMode'],_0x4aeb23['format']=void 0x0===_0x4c5e6c['format']?_0x2103ba['a']['TEXTUREFORMAT_RGBA']:_0x4c5e6c['format']):(_0x4aeb23['generateMipMaps']=_0x4c5e6c,_0x4aeb23['generateDepthBuffer']=!0x0,_0x4aeb23['generateStencilBuffer']=!0x1,_0x4aeb23['type']=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'],_0x4aeb23['samplingMode']=_0x2103ba['a']['TEXTURE_TRILINEAR_SAMPLINGMODE'],_0x4aeb23['format']=_0x2103ba['a']['TEXTUREFORMAT_RGBA']),(_0x4aeb23['type']!==_0x2103ba['a']['TEXTURETYPE_FLOAT']||this['_caps']['textureFloatLinearFiltering'])&&(_0x4aeb23['type']!==_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT']||this['_caps']['textureHalfFloatLinearFiltering'])||(_0x4aeb23['samplingMode']=_0x2103ba['a']['TEXTURE_NEAREST_SAMPLINGMODE']);var _0x591ee7=new _0x589078(this,_0x21ea74['b']['RenderTarget']),_0x31f850=_0x430680['width']||_0x430680,_0x2ddcc5=_0x430680['height']||_0x430680;_0x4aeb23['type']!==_0x2103ba['a']['TEXTURETYPE_FLOAT']||this['_caps']['textureFloat']||(_0x4aeb23['type']=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'],_0x75193d['a']['Warn']('Float\x20textures\x20are\x20not\x20supported.\x20Render\x20target\x20forced\x20to\x20TEXTURETYPE_UNSIGNED_BYTE\x20type'));var _0x17f41a=this['_native']['createFramebuffer'](_0x591ee7['_webGLTexture'],_0x31f850,_0x2ddcc5,this['_getNativeTextureFormat'](_0x4aeb23['format'],_0x4aeb23['type']),_0x4aeb23['samplingMode'],!!_0x4aeb23['generateStencilBuffer'],_0x4aeb23['generateDepthBuffer'],!!_0x4aeb23['generateMipMaps']);return _0x591ee7['_framebuffer']=_0x17f41a,_0x591ee7['baseWidth']=_0x31f850,_0x591ee7['baseHeight']=_0x2ddcc5,_0x591ee7['width']=_0x31f850,_0x591ee7['height']=_0x2ddcc5,_0x591ee7['isReady']=!0x0,_0x591ee7['samples']=0x1,_0x591ee7['generateMipMaps']=!!_0x4aeb23['generateMipMaps'],_0x591ee7['samplingMode']=_0x4aeb23['samplingMode'],_0x591ee7['type']=_0x4aeb23['type'],_0x591ee7['format']=_0x4aeb23['format'],_0x591ee7['_generateDepthBuffer']=_0x4aeb23['generateDepthBuffer'],_0x591ee7['_generateStencilBuffer']=!!_0x4aeb23['generateStencilBuffer'],this['_internalTexturesCache']['push'](_0x591ee7),_0x591ee7;},_0x45108e['prototype']['updateTextureSamplingMode']=function(_0x5144f2,_0x25fe13){if(_0x25fe13['_webGLTexture']){var _0x4a8b54=this['_getNativeSamplingMode'](_0x5144f2);this['_native']['setTextureSampling'](_0x25fe13['_webGLTexture'],_0x4a8b54);}_0x25fe13['samplingMode']=_0x5144f2;},_0x45108e['prototype']['bindFramebuffer']=function(_0x1f79cc,_0x108a57,_0x222945,_0x444196,_0x3190f5){if(_0x108a57)throw new Error('Cuboid\x20frame\x20buffers\x20are\x20not\x20yet\x20supported\x20in\x20NativeEngine.');if(_0x222945||_0x444196)throw new Error('Required\x20width/height\x20for\x20frame\x20buffers\x20not\x20yet\x20supported\x20in\x20NativeEngine.');_0x1f79cc['_depthStencilTexture']?this['_bindUnboundFramebuffer'](_0x1f79cc['_depthStencilTexture']['_framebuffer']):this['_bindUnboundFramebuffer'](_0x1f79cc['_framebuffer']);},_0x45108e['prototype']['unBindFramebuffer']=function(_0x3d8b9c,_0x1bde19,_0x4c1a62){void 0x0===_0x1bde19&&(_0x1bde19=!0x1),_0x1bde19&&_0x75193d['a']['Warn']('Disabling\x20mipmap\x20generation\x20not\x20yet\x20supported\x20in\x20NativeEngine.\x20Ignoring.'),_0x4c1a62&&_0x4c1a62(),this['_bindUnboundFramebuffer'](null);},_0x45108e['prototype']['createDynamicVertexBuffer']=function(_0x219163){return this['createVertexBuffer'](_0x219163,!0x0);},_0x45108e['prototype']['updateDynamicIndexBuffer']=function(_0x1b9494,_0x3b2b00,_0x3d2017){void 0x0===_0x3d2017&&(_0x3d2017=0x0);var _0x2625c7=_0x1b9494,_0x32c622=this['_normalizeIndexData'](_0x3b2b00);_0x2625c7['is32Bits']=0x4===_0x32c622['BYTES_PER_ELEMENT'],this['_native']['updateDynamicIndexBuffer'](_0x2625c7['nativeIndexBuffer'],_0x32c622,_0x3d2017);},_0x45108e['prototype']['updateDynamicVertexBuffer']=function(_0x5df1b0,_0x11d333,_0x5a8555,_0x3c808d){var _0xc9a68c=_0x5df1b0,_0xe19ea8=ArrayBuffer['isView'](_0x11d333)?_0x11d333:new Float32Array(_0x11d333);this['_native']['updateDynamicVertexBuffer'](_0xc9a68c['nativeVertexBuffer'],_0xe19ea8,null!=_0x5a8555?_0x5a8555:0x0,null!=_0x3c808d?_0x3c808d:_0xe19ea8['byteLength']);},_0x45108e['prototype']['_setTexture']=function(_0x2d3339,_0x204976,_0x46113d,_0x1f61ef){void 0x0===_0x46113d&&(_0x46113d=!0x1),void 0x0===_0x1f61ef&&(_0x1f61ef=!0x1);var _0x290808,_0x1e09f9=this['_boundUniforms'][_0x2d3339];if(!_0x1e09f9)return!0x1;if(!_0x204976)return null!=this['_boundTexturesCache'][_0x2d3339]&&(this['_activeChannel']=_0x2d3339,this['_native']['setTexture'](_0x1e09f9,null)),!0x1;if(_0x204976['video'])this['_activeChannel']=_0x2d3339,_0x204976['update']();else{if(_0x204976['delayLoadState']===_0x2103ba['a']['DELAYLOADSTATE_NOTLOADED'])return _0x204976['delayLoad'](),!0x1;}return _0x290808=_0x1f61ef?_0x204976['depthStencilTexture']:_0x204976['isReady']()?_0x204976['getInternalTexture']():_0x204976['isCube']?this['emptyCubeTexture']:_0x204976['is3D']?this['emptyTexture3D']:_0x204976['is2DArray']?this['emptyTexture2DArray']:this['emptyTexture'],this['_activeChannel']=_0x2d3339,!(!_0x290808||!_0x290808['_webGLTexture'])&&(this['_native']['setTextureWrapMode'](_0x290808['_webGLTexture'],this['_getAddressMode'](_0x204976['wrapU']),this['_getAddressMode'](_0x204976['wrapV']),this['_getAddressMode'](_0x204976['wrapR'])),this['_updateAnisotropicLevel'](_0x204976),this['_native']['setTexture'](_0x1e09f9,_0x290808['_webGLTexture']),!0x0);},_0x45108e['prototype']['_updateAnisotropicLevel']=function(_0x5cdbb5){var _0x6e8742=_0x5cdbb5['getInternalTexture'](),_0x1beb51=_0x5cdbb5['anisotropicFilteringLevel'];_0x6e8742&&_0x6e8742['_webGLTexture']&&_0x6e8742['_cachedAnisotropicFilteringLevel']!==_0x1beb51&&(this['_native']['setTextureAnisotropicLevel'](_0x6e8742['_webGLTexture'],_0x1beb51),_0x6e8742['_cachedAnisotropicFilteringLevel']=_0x1beb51);},_0x45108e['prototype']['_getAddressMode']=function(_0x1136c4){switch(_0x1136c4){case _0x2103ba['a']['TEXTURE_WRAP_ADDRESSMODE']:return this['_native']['ADDRESS_MODE_WRAP'];case _0x2103ba['a']['TEXTURE_CLAMP_ADDRESSMODE']:return this['_native']['ADDRESS_MODE_CLAMP'];case _0x2103ba['a']['TEXTURE_MIRROR_ADDRESSMODE']:return this['_native']['ADDRESS_MODE_MIRROR'];default:throw new Error('Unexpected\x20wrap\x20mode:\x20'+_0x1136c4+'.');}},_0x45108e['prototype']['_bindTexture']=function(_0x3acec3,_0x1e43a4){var _0x3401a3=this['_boundUniforms'][_0x3acec3];_0x3401a3&&this['_native']['setTexture'](_0x3401a3,_0x1e43a4['_webGLTexture']);},_0x45108e['prototype']['_deleteBuffer']=function(_0x375032){_0x375032['nativeIndexBuffer']&&(this['_native']['deleteIndexBuffer'](_0x375032['nativeIndexBuffer']),delete _0x375032['nativeIndexBuffer']),_0x375032['nativeVertexBuffer']&&(this['_native']['deleteVertexBuffer'](_0x375032['nativeVertexBuffer']),delete _0x375032['nativeVertexBuffer']);},_0x45108e['prototype']['releaseEffects']=function(){},_0x45108e['prototype']['_uploadCompressedDataToTextureDirectly']=function(_0x373fc3,_0x271211,_0x5d8b05,_0x141224,_0x4da52b,_0x298276,_0x519dd0){throw void 0x0===_0x298276&&(_0x298276=0x0),void 0x0===_0x519dd0&&(_0x519dd0=0x0),new Error('_uploadCompressedDataToTextureDirectly\x20not\x20implemented.');},_0x45108e['prototype']['_uploadDataToTextureDirectly']=function(_0x41fb56,_0x43b7f5,_0x3a9fed,_0x40729b){throw void 0x0===_0x3a9fed&&(_0x3a9fed=0x0),void 0x0===_0x40729b&&(_0x40729b=0x0),new Error('_uploadDataToTextureDirectly\x20not\x20implemented.');},_0x45108e['prototype']['_uploadArrayBufferViewToTexture']=function(_0x4eecdc,_0x4b085e,_0x306b74,_0x352953){throw void 0x0===_0x306b74&&(_0x306b74=0x0),void 0x0===_0x352953&&(_0x352953=0x0),new Error('_uploadArrayBufferViewToTexture\x20not\x20implemented.');},_0x45108e['prototype']['_uploadImageToTexture']=function(_0xd4abee,_0x2512c4,_0x4ad1a2,_0x4c8770){throw void 0x0===_0x4ad1a2&&(_0x4ad1a2=0x0),void 0x0===_0x4c8770&&(_0x4c8770=0x0),new Error('_uploadArrayBufferViewToTexture\x20not\x20implemented.');},_0x45108e['prototype']['_getNativeSamplingMode']=function(_0xfd20bf){switch(_0xfd20bf){case _0x2103ba['a']['TEXTURE_NEAREST_NEAREST']:return this['_native']['TEXTURE_NEAREST_NEAREST'];case _0x2103ba['a']['TEXTURE_LINEAR_LINEAR']:return this['_native']['TEXTURE_LINEAR_LINEAR'];case _0x2103ba['a']['TEXTURE_LINEAR_LINEAR_MIPLINEAR']:return this['_native']['TEXTURE_LINEAR_LINEAR_MIPLINEAR'];case _0x2103ba['a']['TEXTURE_NEAREST_NEAREST_MIPNEAREST']:return this['_native']['TEXTURE_NEAREST_NEAREST_MIPNEAREST'];case _0x2103ba['a']['TEXTURE_NEAREST_LINEAR_MIPNEAREST']:return this['_native']['TEXTURE_NEAREST_LINEAR_MIPNEAREST'];case _0x2103ba['a']['TEXTURE_NEAREST_LINEAR_MIPLINEAR']:return this['_native']['TEXTURE_NEAREST_LINEAR_MIPLINEAR'];case _0x2103ba['a']['TEXTURE_NEAREST_LINEAR']:return this['_native']['TEXTURE_NEAREST_LINEAR'];case _0x2103ba['a']['TEXTURE_NEAREST_NEAREST_MIPLINEAR']:return this['_native']['TEXTURE_NEAREST_NEAREST_MIPLINEAR'];case _0x2103ba['a']['TEXTURE_LINEAR_NEAREST_MIPNEAREST']:return this['_native']['TEXTURE_LINEAR_NEAREST_MIPNEAREST'];case _0x2103ba['a']['TEXTURE_LINEAR_NEAREST_MIPLINEAR']:return this['_native']['TEXTURE_LINEAR_NEAREST_MIPLINEAR'];case _0x2103ba['a']['TEXTURE_LINEAR_LINEAR_MIPNEAREST']:return this['_native']['TEXTURE_LINEAR_LINEAR_MIPNEAREST'];case _0x2103ba['a']['TEXTURE_LINEAR_NEAREST']:return this['_native']['TEXTURE_LINEAR_NEAREST'];default:throw new Error('Unsupported\x20sampling\x20mode:\x20'+_0xfd20bf+'.');}},_0x45108e['prototype']['_getNativeTextureFormat']=function(_0x1c5296,_0x62da8c){if(_0x1c5296==_0x2103ba['a']['TEXTUREFORMAT_RGBA']&&_0x62da8c==_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'])return this['_native']['TEXTURE_FORMAT_RGBA8'];if(_0x1c5296==_0x2103ba['a']['TEXTUREFORMAT_RGBA']&&_0x62da8c==_0x2103ba['a']['TEXTURETYPE_FLOAT'])return this['_native']['TEXTURE_FORMAT_RGBA32F'];throw new Error('Unsupported\x20texture\x20format\x20or\x20type:\x20format\x20'+_0x1c5296+',\x20type\x20'+_0x62da8c+'.');},_0x45108e['prototype']['_getNativeAlphaMode']=function(_0x260f0b){switch(_0x260f0b){case _0x2103ba['a']['ALPHA_DISABLE']:return this['_native']['ALPHA_DISABLE'];case _0x2103ba['a']['ALPHA_ADD']:return this['_native']['ALPHA_ADD'];case _0x2103ba['a']['ALPHA_COMBINE']:return this['_native']['ALPHA_COMBINE'];case _0x2103ba['a']['ALPHA_SUBTRACT']:return this['_native']['ALPHA_SUBTRACT'];case _0x2103ba['a']['ALPHA_MULTIPLY']:return this['_native']['ALPHA_MULTIPLY'];case _0x2103ba['a']['ALPHA_MAXIMIZED']:return this['_native']['ALPHA_MAXIMIZED'];case _0x2103ba['a']['ALPHA_ONEONE']:return this['_native']['ALPHA_ONEONE'];case _0x2103ba['a']['ALPHA_PREMULTIPLIED']:return this['_native']['ALPHA_PREMULTIPLIED'];case _0x2103ba['a']['ALPHA_PREMULTIPLIED_PORTERDUFF']:return this['_native']['ALPHA_PREMULTIPLIED_PORTERDUFF'];case _0x2103ba['a']['ALPHA_INTERPOLATE']:return this['_native']['ALPHA_INTERPOLATE'];case _0x2103ba['a']['ALPHA_SCREENMODE']:return this['_native']['ALPHA_SCREENMODE'];default:throw new Error('Unsupported\x20alpha\x20mode:\x20'+_0x260f0b+'.');}},_0x45108e['prototype']['_getNativeAttribType']=function(_0x3e969f){switch(_0x3e969f){case _0x212fbd['b']['UNSIGNED_BYTE']:return this['_native']['ATTRIB_TYPE_UINT8'];case _0x212fbd['b']['SHORT']:return this['_native']['ATTRIB_TYPE_INT16'];case _0x212fbd['b']['FLOAT']:return this['_native']['ATTRIB_TYPE_FLOAT'];default:throw new Error('Unsupported\x20attribute\x20type:\x20'+_0x3e969f+'.');}},_0x45108e;}(_0x300b38['a']),_0x134549=_0x162675(0x4a),_0x109356=(function(){function _0xd46eb2(){}return _0xd46eb2['COPY']=0x1,_0xd46eb2['CUT']=0x2,_0xd46eb2['PASTE']=0x3,_0xd46eb2;}()),_0x1860e1=(function(){function _0x39b0bc(_0x3e858c,_0x5d9f01){this['type']=_0x3e858c,this['event']=_0x5d9f01;}return _0x39b0bc['GetTypeFromCharacter']=function(_0x1a9e2a){switch(_0x1a9e2a){case 0x43:return _0x109356['COPY'];case 0x56:return _0x109356['PASTE'];case 0x58:return _0x109356['CUT'];default:return-0x1;}},_0x39b0bc;}()),_0xa24f9c=_0x162675(0x53),_0x396102=_0x162675(0x45);!function(_0x52b280){_0x52b280[_0x52b280['Clean']=0x0]='Clean',_0x52b280[_0x52b280['Stop']=0x1]='Stop',_0x52b280[_0x52b280['Sync']=0x2]='Sync',_0x52b280[_0x52b280['NoSync']=0x3]='NoSync';}(_0x18784f||(_0x18784f={}));var _0x5de01e=(function(){function _0x3df864(){}return Object['defineProperty'](_0x3df864,'ForceFullSceneLoadingForIncremental',{'get':function(){return _0x396102['a']['ForceFullSceneLoadingForIncremental'];},'set':function(_0x254872){_0x396102['a']['ForceFullSceneLoadingForIncremental']=_0x254872;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3df864,'ShowLoadingScreen',{'get':function(){return _0x396102['a']['ShowLoadingScreen'];},'set':function(_0x1d3667){_0x396102['a']['ShowLoadingScreen']=_0x1d3667;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3df864,'loggingLevel',{'get':function(){return _0x396102['a']['loggingLevel'];},'set':function(_0x2c4b2b){_0x396102['a']['loggingLevel']=_0x2c4b2b;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3df864,'CleanBoneMatrixWeights',{'get':function(){return _0x396102['a']['CleanBoneMatrixWeights'];},'set':function(_0xa771e0){_0x396102['a']['CleanBoneMatrixWeights']=_0xa771e0;},'enumerable':!0x1,'configurable':!0x0}),_0x3df864['GetDefaultPlugin']=function(){return _0x3df864['_registeredPlugins']['.babylon'];},_0x3df864['_GetPluginForExtension']=function(_0x588068){var _0x4ee4e0=_0x3df864['_registeredPlugins'][_0x588068];return _0x4ee4e0||(_0x75193d['a']['Warn']('Unable\x20to\x20find\x20a\x20plugin\x20to\x20load\x20'+_0x588068+'\x20files.\x20Trying\x20to\x20use\x20.babylon\x20default\x20plugin.\x20To\x20load\x20from\x20a\x20specific\x20filetype\x20(eg.\x20gltf)\x20see:\x20https://doc.babylonjs.com/how_to/load_from_any_file_type'),_0x3df864['GetDefaultPlugin']());},_0x3df864['_GetPluginForDirectLoad']=function(_0x3e251f){for(var _0x5649ca in _0x3df864['_registeredPlugins']){var _0x1c21a1=_0x3df864['_registeredPlugins'][_0x5649ca]['plugin'];if(_0x1c21a1['canDirectLoad']&&_0x1c21a1['canDirectLoad'](_0x3e251f))return _0x3df864['_registeredPlugins'][_0x5649ca];}return _0x3df864['GetDefaultPlugin']();},_0x3df864['_GetPluginForFilename']=function(_0x1b5f16){var _0xb98f23=_0x1b5f16['indexOf']('?');-0x1!==_0xb98f23&&(_0x1b5f16=_0x1b5f16['substring'](0x0,_0xb98f23));var _0x18c1bf=_0x1b5f16['lastIndexOf']('.'),_0xb9b8b=_0x1b5f16['substring'](_0x18c1bf,_0x1b5f16['length'])['toLowerCase']();return _0x3df864['_GetPluginForExtension'](_0xb9b8b);},_0x3df864['_GetDirectLoad']=function(_0x352aa9){return'data:'===_0x352aa9['substr'](0x0,0x5)?_0x352aa9['substr'](0x5):null;},_0x3df864['_LoadData']=function(_0x19970e,_0x4f0bb4,_0x41e29b,_0x297099,_0x41365d,_0x10ccdb,_0x55a45c){var _0x2484cf,_0x2bbd5d=_0x3df864['_GetDirectLoad'](_0x19970e['name']),_0x31cd21=_0x55a45c?_0x3df864['_GetPluginForExtension'](_0x55a45c):_0x2bbd5d?_0x3df864['_GetPluginForDirectLoad'](_0x19970e['name']):_0x3df864['_GetPluginForFilename'](_0x19970e['name']);if(!(_0x2484cf=void 0x0!==_0x31cd21['plugin']['createPlugin']?_0x31cd21['plugin']['createPlugin']():_0x31cd21['plugin']))throw'The\x20loader\x20plugin\x20corresponding\x20to\x20the\x20file\x20type\x20you\x20are\x20trying\x20to\x20load\x20has\x20not\x20been\x20found.\x20If\x20using\x20es6,\x20please\x20import\x20the\x20plugin\x20you\x20wish\x20to\x20use\x20before.';if(_0x3df864['OnPluginActivatedObservable']['notifyObservers'](_0x2484cf),_0x2bbd5d){if(_0x2484cf['directLoad']){var _0x7d5466=_0x2484cf['directLoad'](_0x4f0bb4,_0x2bbd5d);_0x7d5466['then']?_0x7d5466['then'](function(_0x6dd7c4){_0x41e29b(_0x2484cf,_0x6dd7c4);})['catch'](function(_0x16ba26){_0x41365d('Error\x20in\x20directLoad\x20of\x20_loadData:\x20'+_0x16ba26,_0x16ba26);}):_0x41e29b(_0x2484cf,_0x7d5466);}else _0x41e29b(_0x2484cf,_0x2bbd5d);return _0x2484cf;}var _0x22517d=_0x31cd21['isBinary'],_0x5ef99c=function(_0x5737d8,_0x322ef9){_0x4f0bb4['isDisposed']?_0x41365d('Scene\x20has\x20been\x20disposed'):_0x41e29b(_0x2484cf,_0x5737d8,_0x322ef9);},_0x5921f3=null,_0x373741=!0x1,_0x401079=_0x2484cf['onDisposeObservable'];_0x401079&&_0x401079['add'](function(){_0x373741=!0x0,_0x5921f3&&(_0x5921f3['abort'](),_0x5921f3=null),_0x10ccdb();});var _0x311ae8=function(){if(!_0x373741){var _0x175576=function(_0x3ddfa1,_0x1e8698){_0x5ef99c(_0x3ddfa1,_0x1e8698?_0x1e8698['responseURL']:void 0x0);},_0x474d67=function(_0x255822){_0x41365d(_0x255822['message'],_0x255822);};_0x5921f3=_0x2484cf['requestFile']?_0x2484cf['requestFile'](_0x4f0bb4,_0x19970e['url'],_0x175576,_0x297099,_0x22517d,_0x474d67):_0x4f0bb4['_requestFile'](_0x19970e['url'],_0x175576,_0x297099,!0x0,_0x22517d,_0x474d67);}},_0x7efb09=_0x19970e['file']||_0xa24f9c['a']['FilesToLoad'][_0x19970e['name']['toLowerCase']()];if(-0x1===_0x19970e['rootUrl']['indexOf']('file:')||-0x1!==_0x19970e['rootUrl']['indexOf']('file:')&&!_0x7efb09){var _0x39c5d8=_0x4f0bb4['getEngine'](),_0x2a7917=_0x39c5d8['enableOfflineSupport'];if(_0x2a7917){for(var _0x4021b1=!0x1,_0x4155c2=0x0,_0x25ecf0=_0x4f0bb4['disableOfflineSupportExceptionRules'];_0x4155c2<_0x25ecf0['length'];_0x4155c2++){if(_0x25ecf0[_0x4155c2]['test'](_0x19970e['url'])){_0x4021b1=!0x0;break;}}_0x2a7917=!_0x4021b1;}_0x2a7917&&_0x300b38['a']['OfflineProviderFactory']?_0x4f0bb4['offlineProvider']=_0x300b38['a']['OfflineProviderFactory'](_0x19970e['url'],_0x311ae8,_0x39c5d8['disableManifestCheck']):_0x311ae8();}else{if(_0x7efb09){var _0x14285f=function(_0x2fde9a){_0x41365d(_0x2fde9a['message'],_0x2fde9a);};_0x5921f3=_0x2484cf['readFile']?_0x2484cf['readFile'](_0x4f0bb4,_0x7efb09,_0x5ef99c,_0x297099,_0x22517d,_0x14285f):_0x4f0bb4['_readFile'](_0x7efb09,_0x5ef99c,_0x297099,_0x22517d,_0x14285f);}else _0x41365d('Unable\x20to\x20find\x20file\x20named\x20'+_0x19970e['name']);}return _0x2484cf;},_0x3df864['_GetFileInfo']=function(_0x2c2836,_0x96636){var _0x51195c,_0x343686,_0xd02908=null;if(_0x96636){if(_0x96636['name']){var _0xf7721d=_0x96636;_0x51195c=_0x2c2836+_0xf7721d['name'],_0x343686=_0xf7721d['name'],_0xd02908=_0xf7721d;}else{var _0x55b6fa=_0x96636;if('/'===_0x55b6fa['substr'](0x0,0x1))return _0x5d754c['b']['Error']('Wrong\x20sceneFilename\x20parameter'),null;_0x51195c=_0x2c2836+_0x55b6fa,_0x343686=_0x55b6fa;}}else _0x51195c=_0x2c2836,_0x343686=_0x5d754c['b']['GetFilename'](_0x2c2836),_0x2c2836=_0x5d754c['b']['GetFolderPath'](_0x2c2836);return{'url':_0x51195c,'rootUrl':_0x2c2836,'name':_0x343686,'file':_0xd02908};},_0x3df864['GetPluginForExtension']=function(_0x338bb2){return _0x3df864['_GetPluginForExtension'](_0x338bb2)['plugin'];},_0x3df864['IsPluginForExtensionAvailable']=function(_0x2a9f86){return!!_0x3df864['_registeredPlugins'][_0x2a9f86];},_0x3df864['RegisterPlugin']=function(_0x2450c4){if('string'==typeof _0x2450c4['extensions']){var _0x8ba06c=_0x2450c4['extensions'];_0x3df864['_registeredPlugins'][_0x8ba06c['toLowerCase']()]={'plugin':_0x2450c4,'isBinary':!0x1};}else{var _0x504bd3=_0x2450c4['extensions'];Object['keys'](_0x504bd3)['forEach'](function(_0x30e9af){_0x3df864['_registeredPlugins'][_0x30e9af['toLowerCase']()]={'plugin':_0x2450c4,'isBinary':_0x504bd3[_0x30e9af]['isBinary']};});}},_0x3df864['ImportMesh']=function(_0x291ccc,_0x22dc16,_0x288a03,_0x4d186b,_0xbe335e,_0x290dad,_0x1c38cd,_0x456371){if(void 0x0===_0x288a03&&(_0x288a03=''),void 0x0===_0x4d186b&&(_0x4d186b=_0x44b9ce['a']['LastCreatedScene']),void 0x0===_0xbe335e&&(_0xbe335e=null),void 0x0===_0x290dad&&(_0x290dad=null),void 0x0===_0x1c38cd&&(_0x1c38cd=null),void 0x0===_0x456371&&(_0x456371=null),!_0x4d186b)return _0x75193d['a']['Error']('No\x20scene\x20available\x20to\x20import\x20mesh\x20to'),null;var _0x4370dd=_0x3df864['_GetFileInfo'](_0x22dc16,_0x288a03);if(!_0x4370dd)return null;var _0x22022c={};_0x4d186b['_addPendingData'](_0x22022c);var _0x574130=function(){_0x4d186b['_removePendingData'](_0x22022c);},_0x985b7e=function(_0xc55b4f,_0x4de2b8){var _0x5ae00c='Unable\x20to\x20import\x20meshes\x20from\x20'+_0x4370dd['url']+':\x20'+_0xc55b4f;_0x1c38cd?_0x1c38cd(_0x4d186b,_0x5ae00c,_0x4de2b8):_0x75193d['a']['Error'](_0x5ae00c),_0x574130();},_0x2040b9=_0x290dad?function(_0x35d4f6){try{_0x290dad(_0x35d4f6);}catch(_0x298e2a){_0x985b7e('Error\x20in\x20onProgress\x20callback:\x20'+_0x298e2a,_0x298e2a);}}:void 0x0,_0x3b4226=function(_0x1a8172,_0x20903c,_0x36464c,_0x16f822,_0x41680d,_0x410f47,_0xe32d65){if(_0x4d186b['importedMeshesFiles']['push'](_0x4370dd['url']),_0xbe335e)try{_0xbe335e(_0x1a8172,_0x20903c,_0x36464c,_0x16f822,_0x41680d,_0x410f47,_0xe32d65);}catch(_0x2753ac){_0x985b7e('Error\x20in\x20onSuccess\x20callback:\x20'+_0x2753ac,_0x2753ac);}_0x4d186b['_removePendingData'](_0x22022c);};return _0x3df864['_LoadData'](_0x4370dd,_0x4d186b,function(_0x34e269,_0x118214,_0x37a3d0){if(_0x34e269['rewriteRootURL']&&(_0x4370dd['rootUrl']=_0x34e269['rewriteRootURL'](_0x4370dd['rootUrl'],_0x37a3d0)),_0x34e269['importMesh']){var _0x24e66e=_0x34e269,_0x5aaad2=new Array(),_0x49aba3=new Array(),_0x1cd9ab=new Array();if(!_0x24e66e['importMesh'](_0x291ccc,_0x4d186b,_0x118214,_0x4370dd['rootUrl'],_0x5aaad2,_0x49aba3,_0x1cd9ab,_0x985b7e))return;_0x4d186b['loadingPluginName']=_0x34e269['name'],_0x3b4226(_0x5aaad2,_0x49aba3,_0x1cd9ab,[],[],[],[]);}else _0x34e269['importMeshAsync'](_0x291ccc,_0x4d186b,_0x118214,_0x4370dd['rootUrl'],_0x2040b9,_0x4370dd['name'])['then'](function(_0x3eebe7){_0x4d186b['loadingPluginName']=_0x34e269['name'],_0x3b4226(_0x3eebe7['meshes'],_0x3eebe7['particleSystems'],_0x3eebe7['skeletons'],_0x3eebe7['animationGroups'],_0x3eebe7['transformNodes'],_0x3eebe7['geometries'],_0x3eebe7['lights']);})['catch'](function(_0x172ca2){_0x985b7e(_0x172ca2['message'],_0x172ca2);});},_0x2040b9,_0x985b7e,_0x574130,_0x456371);},_0x3df864['ImportMeshAsync']=function(_0x483ae0,_0x1d03f9,_0x344667,_0x33bf58,_0x4a97ea,_0x5809d1){return void 0x0===_0x344667&&(_0x344667=''),void 0x0===_0x33bf58&&(_0x33bf58=_0x44b9ce['a']['LastCreatedScene']),void 0x0===_0x4a97ea&&(_0x4a97ea=null),void 0x0===_0x5809d1&&(_0x5809d1=null),new Promise(function(_0x50488d,_0x34ecc0){_0x3df864['ImportMesh'](_0x483ae0,_0x1d03f9,_0x344667,_0x33bf58,function(_0x3b57dc,_0x13c867,_0x14c632,_0x149435,_0x2b2f44,_0x4dbf11,_0x5a5721){_0x50488d({'meshes':_0x3b57dc,'particleSystems':_0x13c867,'skeletons':_0x14c632,'animationGroups':_0x149435,'transformNodes':_0x2b2f44,'geometries':_0x4dbf11,'lights':_0x5a5721});},_0x4a97ea,function(_0x22fc9c,_0x5b0193,_0x266774){_0x34ecc0(_0x266774||new Error(_0x5b0193));},_0x5809d1);});},_0x3df864['Load']=function(_0x297b49,_0x9d14b2,_0xc28d74,_0x404627,_0x38c6e9,_0x556b06,_0x307657){return void 0x0===_0x9d14b2&&(_0x9d14b2=''),void 0x0===_0xc28d74&&(_0xc28d74=_0x44b9ce['a']['LastCreatedEngine']),void 0x0===_0x404627&&(_0x404627=null),void 0x0===_0x38c6e9&&(_0x38c6e9=null),void 0x0===_0x556b06&&(_0x556b06=null),void 0x0===_0x307657&&(_0x307657=null),_0xc28d74?_0x3df864['Append'](_0x297b49,_0x9d14b2,new _0x59370b['a'](_0xc28d74),_0x404627,_0x38c6e9,_0x556b06,_0x307657):(_0x5d754c['b']['Error']('No\x20engine\x20available'),null);},_0x3df864['LoadAsync']=function(_0x3b368e,_0xc46f72,_0x55b46c,_0x6446cb,_0x2dd48c){return void 0x0===_0xc46f72&&(_0xc46f72=''),void 0x0===_0x55b46c&&(_0x55b46c=_0x44b9ce['a']['LastCreatedEngine']),void 0x0===_0x6446cb&&(_0x6446cb=null),void 0x0===_0x2dd48c&&(_0x2dd48c=null),new Promise(function(_0x351bc3,_0x4331cd){_0x3df864['Load'](_0x3b368e,_0xc46f72,_0x55b46c,function(_0x2e242c){_0x351bc3(_0x2e242c);},_0x6446cb,function(_0x2558ea,_0x4e8747,_0x9a99a5){_0x4331cd(_0x9a99a5||new Error(_0x4e8747));},_0x2dd48c);});},_0x3df864['Append']=function(_0x1ea286,_0x2f55dc,_0x2090f5,_0x55e20d,_0x560714,_0x3d0cb1,_0x41ac85){var _0xfab4af=this;if(void 0x0===_0x2f55dc&&(_0x2f55dc=''),void 0x0===_0x2090f5&&(_0x2090f5=_0x44b9ce['a']['LastCreatedScene']),void 0x0===_0x55e20d&&(_0x55e20d=null),void 0x0===_0x560714&&(_0x560714=null),void 0x0===_0x3d0cb1&&(_0x3d0cb1=null),void 0x0===_0x41ac85&&(_0x41ac85=null),!_0x2090f5)return _0x75193d['a']['Error']('No\x20scene\x20available\x20to\x20append\x20to'),null;var _0x53bf8b=_0x3df864['_GetFileInfo'](_0x1ea286,_0x2f55dc);if(!_0x53bf8b)return null;_0x3df864['ShowLoadingScreen']&&!this['_showingLoadingScreen']&&(this['_showingLoadingScreen']=!0x0,_0x2090f5['getEngine']()['displayLoadingUI'](),_0x2090f5['executeWhenReady'](function(){_0x2090f5['getEngine']()['hideLoadingUI'](),_0xfab4af['_showingLoadingScreen']=!0x1;}));var _0x1e78da={};_0x2090f5['_addPendingData'](_0x1e78da);var _0x287a09=function(){_0x2090f5['_removePendingData'](_0x1e78da);},_0x499966=function(_0xe1f31e,_0x5bc92f){var _0x23c06c='Unable\x20to\x20load\x20from\x20'+_0x53bf8b['url']+(_0xe1f31e?':\x20'+_0xe1f31e:'');_0x3d0cb1?_0x3d0cb1(_0x2090f5,_0x23c06c,_0x5bc92f):_0x75193d['a']['Error'](_0x23c06c),_0x287a09();},_0x44f5c5=_0x560714?function(_0x56ed9b){try{_0x560714(_0x56ed9b);}catch(_0x12dd01){_0x499966('Error\x20in\x20onProgress\x20callback',_0x12dd01);}}:void 0x0,_0x5189d2=function(){if(_0x55e20d)try{_0x55e20d(_0x2090f5);}catch(_0x3b5490){_0x499966('Error\x20in\x20onSuccess\x20callback',_0x3b5490);}_0x2090f5['_removePendingData'](_0x1e78da);};return _0x3df864['_LoadData'](_0x53bf8b,_0x2090f5,function(_0x147fe7,_0x4902d3){if(_0x147fe7['load']){if(!_0x147fe7['load'](_0x2090f5,_0x4902d3,_0x53bf8b['rootUrl'],_0x499966))return;_0x2090f5['loadingPluginName']=_0x147fe7['name'],_0x5189d2();}else _0x147fe7['loadAsync'](_0x2090f5,_0x4902d3,_0x53bf8b['rootUrl'],_0x44f5c5,_0x53bf8b['name'])['then'](function(){_0x2090f5['loadingPluginName']=_0x147fe7['name'],_0x5189d2();})['catch'](function(_0x1c72a5){_0x499966(_0x1c72a5['message'],_0x1c72a5);});},_0x44f5c5,_0x499966,_0x287a09,_0x41ac85);},_0x3df864['AppendAsync']=function(_0x239a03,_0x16ad70,_0x3b6edc,_0x3390c4,_0x3c7a89){return void 0x0===_0x16ad70&&(_0x16ad70=''),void 0x0===_0x3b6edc&&(_0x3b6edc=_0x44b9ce['a']['LastCreatedScene']),void 0x0===_0x3390c4&&(_0x3390c4=null),void 0x0===_0x3c7a89&&(_0x3c7a89=null),new Promise(function(_0x53a582,_0x200b04){_0x3df864['Append'](_0x239a03,_0x16ad70,_0x3b6edc,function(_0x3cdb9f){_0x53a582(_0x3cdb9f);},_0x3390c4,function(_0x1ee62a,_0x36c85b,_0x4bd9b5){_0x200b04(_0x4bd9b5||new Error(_0x36c85b));},_0x3c7a89);});},_0x3df864['LoadAssetContainer']=function(_0x310b62,_0x39dd3b,_0x3f50ff,_0x25051b,_0x4bc4c1,_0x53a1cf,_0x309551){if(void 0x0===_0x39dd3b&&(_0x39dd3b=''),void 0x0===_0x3f50ff&&(_0x3f50ff=_0x44b9ce['a']['LastCreatedScene']),void 0x0===_0x25051b&&(_0x25051b=null),void 0x0===_0x4bc4c1&&(_0x4bc4c1=null),void 0x0===_0x53a1cf&&(_0x53a1cf=null),void 0x0===_0x309551&&(_0x309551=null),!_0x3f50ff)return _0x75193d['a']['Error']('No\x20scene\x20available\x20to\x20load\x20asset\x20container\x20to'),null;var _0x583747=_0x3df864['_GetFileInfo'](_0x310b62,_0x39dd3b);if(!_0x583747)return null;var _0x5c54a1={};_0x3f50ff['_addPendingData'](_0x5c54a1);var _0x417b58=function(){_0x3f50ff['_removePendingData'](_0x5c54a1);},_0x1cc0bd=function(_0x452446,_0x1a5beb){var _0x2be89d='Unable\x20to\x20load\x20assets\x20from\x20'+_0x583747['url']+(_0x452446?':\x20'+_0x452446:'');_0x1a5beb&&_0x1a5beb['message']&&(_0x2be89d+='\x20('+_0x1a5beb['message']+')'),_0x53a1cf?_0x53a1cf(_0x3f50ff,_0x2be89d,_0x1a5beb):_0x75193d['a']['Error'](_0x2be89d),_0x417b58();},_0x5ce846=_0x4bc4c1?function(_0x35aa62){try{_0x4bc4c1(_0x35aa62);}catch(_0x3a5fec){_0x1cc0bd('Error\x20in\x20onProgress\x20callback',_0x3a5fec);}}:void 0x0,_0x4eb95c=function(_0x2e8646){if(_0x25051b)try{_0x25051b(_0x2e8646);}catch(_0x231fa2){_0x1cc0bd('Error\x20in\x20onSuccess\x20callback',_0x231fa2);}_0x3f50ff['_removePendingData'](_0x5c54a1);};return _0x3df864['_LoadData'](_0x583747,_0x3f50ff,function(_0x517c7c,_0x220afd){if(_0x517c7c['loadAssetContainer']){var _0x5e5f0=_0x517c7c['loadAssetContainer'](_0x3f50ff,_0x220afd,_0x583747['rootUrl'],_0x1cc0bd);if(!_0x5e5f0)return;_0x3f50ff['loadingPluginName']=_0x517c7c['name'],_0x4eb95c(_0x5e5f0);}else{if(_0x517c7c['loadAssetContainerAsync'])_0x517c7c['loadAssetContainerAsync'](_0x3f50ff,_0x220afd,_0x583747['rootUrl'],_0x5ce846,_0x583747['name'])['then'](function(_0x46c9e4){_0x3f50ff['loadingPluginName']=_0x517c7c['name'],_0x4eb95c(_0x46c9e4);})['catch'](function(_0x587ab5){_0x1cc0bd(_0x587ab5['message'],_0x587ab5);});else _0x1cc0bd('LoadAssetContainer\x20is\x20not\x20supported\x20by\x20this\x20plugin.\x20Plugin\x20did\x20not\x20provide\x20a\x20loadAssetContainer\x20or\x20loadAssetContainerAsync\x20method.');}},_0x5ce846,_0x1cc0bd,_0x417b58,_0x309551);},_0x3df864['LoadAssetContainerAsync']=function(_0x5f2f7c,_0x36b8a2,_0x5284e0,_0x406985,_0x17a1dd){return void 0x0===_0x36b8a2&&(_0x36b8a2=''),void 0x0===_0x5284e0&&(_0x5284e0=_0x44b9ce['a']['LastCreatedScene']),void 0x0===_0x406985&&(_0x406985=null),void 0x0===_0x17a1dd&&(_0x17a1dd=null),new Promise(function(_0x4bbe30,_0x55e99e){_0x3df864['LoadAssetContainer'](_0x5f2f7c,_0x36b8a2,_0x5284e0,function(_0x4de5c0){_0x4bbe30(_0x4de5c0);},_0x406985,function(_0x4eeb75,_0x4480cf,_0x1080d2){_0x55e99e(_0x1080d2||new Error(_0x4480cf));},_0x17a1dd);});},_0x3df864['ImportAnimations']=function(_0x156a16,_0x5a233c,_0xec70c2,_0x3b916e,_0x3ae7df,_0x3ef5a5,_0x174284,_0x2fba27,_0x4028ca,_0x39f0b0){if(void 0x0===_0x5a233c&&(_0x5a233c=''),void 0x0===_0xec70c2&&(_0xec70c2=_0x44b9ce['a']['LastCreatedScene']),void 0x0===_0x3b916e&&(_0x3b916e=!0x0),void 0x0===_0x3ae7df&&(_0x3ae7df=_0x18784f['Clean']),void 0x0===_0x3ef5a5&&(_0x3ef5a5=null),void 0x0===_0x174284&&(_0x174284=null),void 0x0===_0x2fba27&&(_0x2fba27=null),void 0x0===_0x4028ca&&(_0x4028ca=null),void 0x0===_0x39f0b0&&(_0x39f0b0=null),_0xec70c2){if(_0x3b916e){for(var _0x5448ac=0x0,_0x24c934=_0xec70c2['animatables'];_0x5448ac<_0x24c934['length'];_0x5448ac++){_0x24c934[_0x5448ac]['reset']();}_0xec70c2['stopAllAnimations'](),_0xec70c2['animationGroups']['slice']()['forEach'](function(_0x46ad7b){_0x46ad7b['dispose']();}),_0xec70c2['getNodes']()['forEach'](function(_0x442119){_0x442119['animations']&&(_0x442119['animations']=[]);});}else switch(_0x3ae7df){case _0x18784f['Clean']:_0xec70c2['animationGroups']['slice']()['forEach'](function(_0x32a9a5){_0x32a9a5['dispose']();});break;case _0x18784f['Stop']:_0xec70c2['animationGroups']['forEach'](function(_0x5ae929){_0x5ae929['stop']();});break;case _0x18784f['Sync']:_0xec70c2['animationGroups']['forEach'](function(_0x370316){_0x370316['reset'](),_0x370316['restart']();});break;case _0x18784f['NoSync']:break;default:return void _0x75193d['a']['Error']('Unknown\x20animation\x20group\x20loading\x20mode\x20value\x20\x27'+_0x3ae7df+'\x27');}var _0x4bd3e2=_0xec70c2['animatables']['length'];this['LoadAssetContainer'](_0x156a16,_0x5a233c,_0xec70c2,function(_0x384a50){_0x384a50['mergeAnimationsTo'](_0xec70c2,_0xec70c2['animatables']['slice'](_0x4bd3e2),_0x3ef5a5),_0x384a50['dispose'](),_0xec70c2['onAnimationFileImportedObservable']['notifyObservers'](_0xec70c2),_0x174284&&_0x174284(_0xec70c2);},_0x2fba27,_0x4028ca,_0x39f0b0);}else _0x75193d['a']['Error']('No\x20scene\x20available\x20to\x20load\x20animations\x20to');},_0x3df864['ImportAnimationsAsync']=function(_0x31f361,_0x35c750,_0x2ce92d,_0xdf76ee,_0x13eb63,_0x2ed30c,_0x3dcda7,_0x3564fd,_0x3d1d5b,_0x442c67){return void 0x0===_0x35c750&&(_0x35c750=''),void 0x0===_0x2ce92d&&(_0x2ce92d=_0x44b9ce['a']['LastCreatedScene']),void 0x0===_0xdf76ee&&(_0xdf76ee=!0x0),void 0x0===_0x13eb63&&(_0x13eb63=_0x18784f['Clean']),void 0x0===_0x2ed30c&&(_0x2ed30c=null),void 0x0===_0x3dcda7&&(_0x3dcda7=null),void 0x0===_0x3564fd&&(_0x3564fd=null),void 0x0===_0x3d1d5b&&(_0x3d1d5b=null),void 0x0===_0x442c67&&(_0x442c67=null),new Promise(function(_0x2d5be6,_0x431bc3){_0x3df864['ImportAnimations'](_0x31f361,_0x35c750,_0x2ce92d,_0xdf76ee,_0x13eb63,_0x2ed30c,function(_0x8a5f51){_0x2d5be6(_0x8a5f51);},_0x3564fd,function(_0x571a52,_0x1f1903,_0x5550e6){_0x431bc3(_0x5550e6||new Error(_0x1f1903));},_0x442c67);});},_0x3df864['NO_LOGGING']=_0x2103ba['a']['SCENELOADER_NO_LOGGING'],_0x3df864['MINIMAL_LOGGING']=_0x2103ba['a']['SCENELOADER_MINIMAL_LOGGING'],_0x3df864['SUMMARY_LOGGING']=_0x2103ba['a']['SCENELOADER_SUMMARY_LOGGING'],_0x3df864['DETAILED_LOGGING']=_0x2103ba['a']['SCENELOADER_DETAILED_LOGGING'],_0x3df864['OnPluginActivatedObservable']=new _0x6ac1f7['c'](),_0x3df864['_registeredPlugins']={},_0x3df864['_showingLoadingScreen']=!0x1,_0x3df864;}()),_0x45be87=function(_0x1327a0){function _0x268dcf(_0x4a9e94){var _0x4177de=_0x1327a0['call'](this,_0x4a9e94)||this;return _0x4177de['controllerType']=_0x1a2757['DAYDREAM'],_0x4177de;}return Object(_0x18e13d['d'])(_0x268dcf,_0x1327a0),_0x268dcf['prototype']['initControllerMesh']=function(_0xb7d1ac,_0x112e01){var _0x190db2=this;_0x5de01e['ImportMesh']('',_0x268dcf['MODEL_BASE_URL'],_0x268dcf['MODEL_FILENAME'],_0xb7d1ac,function(_0x4d4347){_0x190db2['_defaultModel']=_0x4d4347[0x1],_0x190db2['attachToMesh'](_0x190db2['_defaultModel']),_0x112e01&&_0x112e01(_0x190db2['_defaultModel']);});},_0x268dcf['prototype']['_handleButtonChange']=function(_0x59d154,_0x33d9db,_0x5d7d95){if(0x0===_0x59d154){var _0x20d597=this['onTriggerStateChangedObservable'];_0x20d597&&_0x20d597['notifyObservers'](_0x33d9db);}else _0x75193d['a']['Warn']('Unrecognized\x20Daydream\x20button\x20index:\x20'+_0x59d154);},_0x268dcf['MODEL_BASE_URL']='https://controllers.babylonjs.com/generic/',_0x268dcf['MODEL_FILENAME']='generic.babylon',_0x268dcf['GAMEPAD_ID_PREFIX']='Daydream',_0x268dcf;}(_0x5dfec2);_0x14684f['_ControllerFactories']['push']({'canCreate':function(_0x37a9aa){return 0x0===_0x37a9aa['id']['indexOf'](_0x45be87['GAMEPAD_ID_PREFIX']);},'create':function(_0x2f212b){return new _0x45be87(_0x2f212b);}});var _0x40f55a=function(_0x599858){function _0x3abf21(_0x594a40){var _0x865cb4=_0x599858['call'](this,_0x594a40)||this;return _0x865cb4['_buttonIndexToObservableNameMap']=['onPadStateChangedObservable','onTriggerStateChangedObservable'],_0x865cb4['controllerType']=_0x1a2757['GEAR_VR'],_0x865cb4['_calculatedPosition']=new _0x74d525['e']('left'==_0x865cb4['hand']?-0.15:0.15,-0.5,0.25),_0x865cb4['_disableTrackPosition'](_0x865cb4['_calculatedPosition']),_0x865cb4;}return Object(_0x18e13d['d'])(_0x3abf21,_0x599858),_0x3abf21['prototype']['initControllerMesh']=function(_0x229c3f,_0x4b6ad6){var _0x5b0dd8=this;_0x5de01e['ImportMesh']('',_0x3abf21['MODEL_BASE_URL'],_0x3abf21['MODEL_FILENAME'],_0x229c3f,function(_0x327bf2){var _0x1f8351=new _0x3cf5e5['a']('',_0x229c3f);_0x327bf2[0x1]['parent']=_0x1f8351,_0x327bf2[0x1]['position']['z']=-0.15,_0x5b0dd8['_defaultModel']=_0x1f8351,_0x5b0dd8['attachToMesh'](_0x5b0dd8['_defaultModel']),_0x4b6ad6&&_0x4b6ad6(_0x5b0dd8['_defaultModel']);});},_0x3abf21['prototype']['_handleButtonChange']=function(_0x5b8cff,_0x1ea1eb,_0x3eaee6){if(_0x5b8cff_0x4a5779['snapDistance']?(_0x49ef9b=Math['floor'](Math['abs'](_0x970875)/_0x4a5779['snapDistance']),_0x970875<0x0&&(_0x49ef9b*=-0x1),_0x970875%=_0x4a5779['snapDistance'],_0x10650d['scaleToRef'](_0x4a5779['snapDistance']*_0x49ef9b,_0x10650d),_0x538795=!0x0):_0x10650d['scaleInPlace'](0x0)),_0x74d525['a']['ScalingToRef'](0x1+_0x10650d['x'],0x1+_0x10650d['y'],0x1+_0x10650d['z'],_0x4a5779['_tmpMatrix2']),_0x4a5779['_tmpMatrix2']['multiplyToRef'](_0x4a5779['attachedNode']['getWorldMatrix'](),_0x4a5779['_tmpMatrix']),_0x4a5779['_tmpMatrix']['decompose'](_0x4a5779['_tmpVector']),(Math['abs'](_0x4a5779['_tmpVector']['x'])<0x186a0&&Math['abs'](_0x4a5779['_tmpVector']['y'])<0x186a0&&Math['abs'](_0x4a5779['_tmpVector']['z'])<0x186a0&&_0x4a5779['attachedNode']['getWorldMatrix']()['copyFrom'](_0x4a5779['_tmpMatrix']),_0x538795&&(_0x1f3cc5['snapDistance']=_0x4a5779['snapDistance']*_0x49ef9b,_0x4a5779['onSnapObservable']['notifyObservers'](_0x1f3cc5)),_0x4a5779['_matrixChanged']());}}),_0x4a5779['dragBehavior']['onDragStartObservable']['add'](function(){_0x4a5779['_dragging']=!0x0;}),_0x4a5779['dragBehavior']['onDragObservable']['add'](function(_0x54fd7f){return _0x1526cb(_0x54fd7f['dragDistance']);}),_0x4a5779['dragBehavior']['onDragEndObservable']['add'](_0x1661f2),null===(_0x343d96=null===(_0x3ec5f5=null===(_0x51b848=null==_0x26ef40?void 0x0:_0x26ef40['uniformScaleGizmo'])||void 0x0===_0x51b848?void 0x0:_0x51b848['dragBehavior'])||void 0x0===_0x3ec5f5?void 0x0:_0x3ec5f5['onDragObservable'])||void 0x0===_0x343d96||_0x343d96['add'](function(_0x43e3df){return _0x1526cb(_0x43e3df['delta']['y']);}),null===(_0x37e301=null===(_0x4597b8=null===(_0x2394af=null==_0x26ef40?void 0x0:_0x26ef40['uniformScaleGizmo'])||void 0x0===_0x2394af?void 0x0:_0x2394af['dragBehavior'])||void 0x0===_0x4597b8?void 0x0:_0x4597b8['onDragEndObservable'])||void 0x0===_0x37e301||_0x37e301['add'](_0x1661f2);var _0x1f429d={'gizmoMeshes':[_0x180f63,_0x22b67a],'colliderMeshes':[_0x24e7aa['arrowMesh'],_0x24e7aa['arrowTail']],'material':_0x4a5779['_coloredMaterial'],'hoverMaterial':_0x4a5779['_hoverMaterial'],'disableMaterial':_0x4a5779['_disableMaterial'],'active':!0x1};null===(_0x58c585=_0x4a5779['_parent'])||void 0x0===_0x58c585||_0x58c585['addToAxisCache'](_0x4a5779['_gizmoMesh'],_0x1f429d),_0x4a5779['_pointerObserver']=_0x16c32b['utilityLayerScene']['onPointerObservable']['add'](function(_0x2e7bff){var _0x6588e9;if(!_0x4a5779['_customMeshSet']&&(_0x4a5779['_isHovered']=!(-0x1==_0x1f429d['colliderMeshes']['indexOf'](null===(_0x6588e9=null==_0x2e7bff?void 0x0:_0x2e7bff['pickInfo'])||void 0x0===_0x6588e9?void 0x0:_0x6588e9['pickedMesh'])),!_0x4a5779['_parent'])){var _0x41cca5=_0x4a5779['_isHovered']||_0x4a5779['_dragging']?_0x4a5779['_hoverMaterial']:_0x4a5779['_coloredMaterial'];_0x1f429d['gizmoMeshes']['forEach'](function(_0x16bd4d){_0x16bd4d['material']=_0x41cca5,_0x16bd4d['color']&&(_0x16bd4d['color']=_0x41cca5['diffuseColor']);});}});var _0x4c40ed=_0x16c32b['_getSharedGizmoLight']();return _0x4c40ed['includedOnlyMeshes']=_0x4c40ed['includedOnlyMeshes']['concat'](_0x4a5779['_rootMesh']['getChildMeshes']()),_0x4a5779;}return Object(_0x18e13d['d'])(_0x367578,_0x4ddf80),_0x367578['prototype']['_createGizmoMesh']=function(_0x274c4b,_0x42d417,_0x42504e){void 0x0===_0x42504e&&(_0x42504e=!0x1);var _0x435514=_0x144742['a']['CreateBox']('yPosMesh',{'size':0.4*(0x1+(_0x42d417-0x1)/0x4)},this['gizmoLayer']['utilityLayerScene']),_0x407854=_0x179064['a']['CreateCylinder']('cylinder',{'diameterTop':0.005*_0x42d417,'height':0.275,'diameterBottom':0.005*_0x42d417,'tessellation':0x60},this['gizmoLayer']['utilityLayerScene']);return _0x435514['scaling']['scaleInPlace'](0.1),_0x435514['material']=this['_coloredMaterial'],_0x435514['rotation']['x']=Math['PI']/0x2,_0x435514['position']['z']+=0.3,_0x407854['material']=this['_coloredMaterial'],_0x407854['position']['z']+=0.1375,_0x407854['rotation']['x']=Math['PI']/0x2,_0x42504e&&(_0x435514['visibility']=0x0,_0x407854['visibility']=0x0),_0x274c4b['addChild'](_0x435514),_0x274c4b['addChild'](_0x407854),{'arrowMesh':_0x435514,'arrowTail':_0x407854};},_0x367578['prototype']['_attachedNodeChanged']=function(_0x41ebac){this['dragBehavior']&&(this['dragBehavior']['enabled']=!!_0x41ebac);},Object['defineProperty'](_0x367578['prototype'],'isEnabled',{'get':function(){return this['_isEnabled'];},'set':function(_0x3bf74f){this['_isEnabled']=_0x3bf74f,_0x3bf74f?this['_parent']&&(this['attachedMesh']=this['_parent']['attachedMesh'],this['attachedNode']=this['_parent']['attachedNode']):(this['attachedMesh']=null,this['attachedNode']=null);},'enumerable':!0x1,'configurable':!0x0}),_0x367578['prototype']['dispose']=function(){this['onSnapObservable']['clear'](),this['gizmoLayer']['utilityLayerScene']['onPointerObservable']['remove'](this['_pointerObserver']),this['dragBehavior']['detach'](),this['_gizmoMesh']&&this['_gizmoMesh']['dispose'](),[this['_coloredMaterial'],this['_hoverMaterial'],this['_disableMaterial']]['forEach'](function(_0x289dbd){_0x289dbd&&_0x289dbd['dispose']();}),_0x4ddf80['prototype']['dispose']['call'](this);},_0x367578['prototype']['setCustomMesh']=function(_0x50bf96,_0x5b7357){var _0xd86043=this;void 0x0===_0x5b7357&&(_0x5b7357=!0x1),_0x4ddf80['prototype']['setCustomMesh']['call'](this,_0x50bf96),_0x5b7357&&(this['_rootMesh']['getChildMeshes']()['forEach'](function(_0x1553a5){_0x1553a5['material']=_0xd86043['_coloredMaterial'],_0x1553a5['color']&&(_0x1553a5['color']=_0xd86043['_coloredMaterial']['diffuseColor']);}),this['_customMeshSet']=!0x1);},_0x367578;}(_0x417dc8['a']),_0x5c4f8d=_0x162675(0x2d),_0x333a74=_0x162675(0x28),_0x322a76=function(_0x397205){function _0xd0b7d5(_0x1e58d7,_0x2ad8a2){void 0x0===_0x1e58d7&&(_0x1e58d7=_0x39310d['a']['Gray']()),void 0x0===_0x2ad8a2&&(_0x2ad8a2=_0x539118['a']['DefaultKeepDepthUtilityLayer']);var _0x4e31d2=_0x397205['call'](this,_0x2ad8a2)||this;_0x4e31d2['_boundingDimensions']=new _0x74d525['e'](0x1,0x1,0x1),_0x4e31d2['_renderObserver']=null,_0x4e31d2['_pointerObserver']=null,_0x4e31d2['_scaleDragSpeed']=0.2,_0x4e31d2['_tmpQuaternion']=new _0x74d525['b'](),_0x4e31d2['_tmpVector']=new _0x74d525['e'](0x0,0x0,0x0),_0x4e31d2['_tmpRotationMatrix']=new _0x74d525['a'](),_0x4e31d2['ignoreChildren']=!0x1,_0x4e31d2['includeChildPredicate']=null,_0x4e31d2['rotationSphereSize']=0.1,_0x4e31d2['scaleBoxSize']=0.1,_0x4e31d2['fixedDragMeshScreenSize']=!0x1,_0x4e31d2['fixedDragMeshBoundsSize']=!0x1,_0x4e31d2['fixedDragMeshScreenSizeDistanceFactor']=0xa,_0x4e31d2['onDragStartObservable']=new _0x6ac1f7['c'](),_0x4e31d2['onScaleBoxDragObservable']=new _0x6ac1f7['c'](),_0x4e31d2['onScaleBoxDragEndObservable']=new _0x6ac1f7['c'](),_0x4e31d2['onRotationSphereDragObservable']=new _0x6ac1f7['c'](),_0x4e31d2['onRotationSphereDragEndObservable']=new _0x6ac1f7['c'](),_0x4e31d2['scalePivot']=null,_0x4e31d2['_existingMeshScale']=new _0x74d525['e'](),_0x4e31d2['_dragMesh']=null,_0x4e31d2['pointerDragBehavior']=new _0x356c6d['a'](),_0x4e31d2['updateScale']=!0x1,_0x4e31d2['_anchorMesh']=new _0x40d22e['a']('anchor',_0x2ad8a2['utilityLayerScene']),_0x4e31d2['coloredMaterial']=new _0x5905ab['a']('',_0x2ad8a2['utilityLayerScene']),_0x4e31d2['coloredMaterial']['disableLighting']=!0x0,_0x4e31d2['hoverColoredMaterial']=new _0x5905ab['a']('',_0x2ad8a2['utilityLayerScene']),_0x4e31d2['hoverColoredMaterial']['disableLighting']=!0x0,_0x4e31d2['_lineBoundingBox']=new _0x40d22e['a']('',_0x2ad8a2['utilityLayerScene']),_0x4e31d2['_lineBoundingBox']['rotationQuaternion']=new _0x74d525['b']();var _0x237f51=[];_0x237f51['push'](_0x333a74['a']['CreateLines']('lines',{'points':[new _0x74d525['e'](0x0,0x0,0x0),new _0x74d525['e'](_0x4e31d2['_boundingDimensions']['x'],0x0,0x0)]},_0x2ad8a2['utilityLayerScene'])),_0x237f51['push'](_0x333a74['a']['CreateLines']('lines',{'points':[new _0x74d525['e'](0x0,0x0,0x0),new _0x74d525['e'](0x0,_0x4e31d2['_boundingDimensions']['y'],0x0)]},_0x2ad8a2['utilityLayerScene'])),_0x237f51['push'](_0x333a74['a']['CreateLines']('lines',{'points':[new _0x74d525['e'](0x0,0x0,0x0),new _0x74d525['e'](0x0,0x0,_0x4e31d2['_boundingDimensions']['z'])]},_0x2ad8a2['utilityLayerScene'])),_0x237f51['push'](_0x333a74['a']['CreateLines']('lines',{'points':[new _0x74d525['e'](_0x4e31d2['_boundingDimensions']['x'],0x0,0x0),new _0x74d525['e'](_0x4e31d2['_boundingDimensions']['x'],_0x4e31d2['_boundingDimensions']['y'],0x0)]},_0x2ad8a2['utilityLayerScene'])),_0x237f51['push'](_0x333a74['a']['CreateLines']('lines',{'points':[new _0x74d525['e'](_0x4e31d2['_boundingDimensions']['x'],0x0,0x0),new _0x74d525['e'](_0x4e31d2['_boundingDimensions']['x'],0x0,_0x4e31d2['_boundingDimensions']['z'])]},_0x2ad8a2['utilityLayerScene'])),_0x237f51['push'](_0x333a74['a']['CreateLines']('lines',{'points':[new _0x74d525['e'](0x0,_0x4e31d2['_boundingDimensions']['y'],0x0),new _0x74d525['e'](_0x4e31d2['_boundingDimensions']['x'],_0x4e31d2['_boundingDimensions']['y'],0x0)]},_0x2ad8a2['utilityLayerScene'])),_0x237f51['push'](_0x333a74['a']['CreateLines']('lines',{'points':[new _0x74d525['e'](0x0,_0x4e31d2['_boundingDimensions']['y'],0x0),new _0x74d525['e'](0x0,_0x4e31d2['_boundingDimensions']['y'],_0x4e31d2['_boundingDimensions']['z'])]},_0x2ad8a2['utilityLayerScene'])),_0x237f51['push'](_0x333a74['a']['CreateLines']('lines',{'points':[new _0x74d525['e'](0x0,0x0,_0x4e31d2['_boundingDimensions']['z']),new _0x74d525['e'](_0x4e31d2['_boundingDimensions']['x'],0x0,_0x4e31d2['_boundingDimensions']['z'])]},_0x2ad8a2['utilityLayerScene'])),_0x237f51['push'](_0x333a74['a']['CreateLines']('lines',{'points':[new _0x74d525['e'](0x0,0x0,_0x4e31d2['_boundingDimensions']['z']),new _0x74d525['e'](0x0,_0x4e31d2['_boundingDimensions']['y'],_0x4e31d2['_boundingDimensions']['z'])]},_0x2ad8a2['utilityLayerScene'])),_0x237f51['push'](_0x333a74['a']['CreateLines']('lines',{'points':[new _0x74d525['e'](_0x4e31d2['_boundingDimensions']['x'],_0x4e31d2['_boundingDimensions']['y'],_0x4e31d2['_boundingDimensions']['z']),new _0x74d525['e'](0x0,_0x4e31d2['_boundingDimensions']['y'],_0x4e31d2['_boundingDimensions']['z'])]},_0x2ad8a2['utilityLayerScene'])),_0x237f51['push'](_0x333a74['a']['CreateLines']('lines',{'points':[new _0x74d525['e'](_0x4e31d2['_boundingDimensions']['x'],_0x4e31d2['_boundingDimensions']['y'],_0x4e31d2['_boundingDimensions']['z']),new _0x74d525['e'](_0x4e31d2['_boundingDimensions']['x'],0x0,_0x4e31d2['_boundingDimensions']['z'])]},_0x2ad8a2['utilityLayerScene'])),_0x237f51['push'](_0x333a74['a']['CreateLines']('lines',{'points':[new _0x74d525['e'](_0x4e31d2['_boundingDimensions']['x'],_0x4e31d2['_boundingDimensions']['y'],_0x4e31d2['_boundingDimensions']['z']),new _0x74d525['e'](_0x4e31d2['_boundingDimensions']['x'],_0x4e31d2['_boundingDimensions']['y'],0x0)]},_0x2ad8a2['utilityLayerScene'])),_0x237f51['forEach'](function(_0x659250){_0x659250['color']=_0x1e58d7,_0x659250['position']['addInPlace'](new _0x74d525['e'](-_0x4e31d2['_boundingDimensions']['x']/0x2,-_0x4e31d2['_boundingDimensions']['y']/0x2,-_0x4e31d2['_boundingDimensions']['z']/0x2)),_0x659250['isPickable']=!0x1,_0x4e31d2['_lineBoundingBox']['addChild'](_0x659250);}),_0x4e31d2['_rootMesh']['addChild'](_0x4e31d2['_lineBoundingBox']),_0x4e31d2['setColor'](_0x1e58d7),_0x4e31d2['_rotateSpheresParent']=new _0x40d22e['a']('',_0x2ad8a2['utilityLayerScene']),_0x4e31d2['_rotateSpheresParent']['rotationQuaternion']=new _0x74d525['b']();for(var _0x2044ca=function(_0x3a11ea){var _0x452bcf=_0x5c4f8d['a']['CreateSphere']('',{'diameter':0x1},_0x2ad8a2['utilityLayerScene']);_0x452bcf['rotationQuaternion']=new _0x74d525['b'](),_0x452bcf['material']=_0xb078ea['coloredMaterial'],(_0x1a8a2a=new _0x356c6d['a']({}))['moveAttached']=!0x1,_0x1a8a2a['updateDragPlane']=!0x1,_0x452bcf['addBehavior'](_0x1a8a2a);var _0x341262=new _0x74d525['e'](0x1,0x0,0x0),_0x424ca8=0x0;_0x1a8a2a['onDragStartObservable']['add'](function(){_0x341262['copyFrom'](_0x452bcf['forward']),_0x424ca8=0x0;}),_0x1a8a2a['onDragObservable']['add'](function(_0x98c719){if(_0x4e31d2['onRotationSphereDragObservable']['notifyObservers']({}),_0x4e31d2['attachedMesh']){var _0x9898ef=_0x4e31d2['attachedMesh']['parent'];if(_0x9898ef&&_0x9898ef['scaling']&&_0x9898ef['scaling']['isNonUniformWithinEpsilon'](0.001))return void _0x75193d['a']['Warn']('BoundingBoxGizmo\x20controls\x20are\x20not\x20supported\x20on\x20child\x20meshes\x20with\x20non-uniform\x20parent\x20scaling');_0x45da14['a']['_RemoveAndStorePivotPoint'](_0x4e31d2['attachedMesh']);var _0xf7b1e2=_0x341262,_0x80f58f=_0x98c719['dragPlaneNormal']['scale'](_0x74d525['e']['Dot'](_0x98c719['dragPlaneNormal'],_0xf7b1e2)),_0x5469f6=_0xf7b1e2['subtract'](_0x80f58f)['normalizeToNew'](),_0x29e432=_0x74d525['e']['Dot'](_0x5469f6,_0x98c719['delta'])<0x0?Math['abs'](_0x98c719['delta']['length']()):-Math['abs'](_0x98c719['delta']['length']());_0x29e432=_0x29e432/_0x4e31d2['_boundingDimensions']['length']()*_0x4e31d2['_anchorMesh']['scaling']['length'](),_0x4e31d2['attachedMesh']['rotationQuaternion']||(_0x4e31d2['attachedMesh']['rotationQuaternion']=_0x74d525['b']['RotationYawPitchRoll'](_0x4e31d2['attachedMesh']['rotation']['y'],_0x4e31d2['attachedMesh']['rotation']['x'],_0x4e31d2['attachedMesh']['rotation']['z'])),_0x4e31d2['_anchorMesh']['rotationQuaternion']||(_0x4e31d2['_anchorMesh']['rotationQuaternion']=_0x74d525['b']['RotationYawPitchRoll'](_0x4e31d2['_anchorMesh']['rotation']['y'],_0x4e31d2['_anchorMesh']['rotation']['x'],_0x4e31d2['_anchorMesh']['rotation']['z'])),_0x424ca8+=_0x29e432,Math['abs'](_0x424ca8)<=0x2*Math['PI']&&(_0x3a11ea>=0x8?_0x74d525['b']['RotationYawPitchRollToRef'](0x0,0x0,_0x29e432,_0x4e31d2['_tmpQuaternion']):_0x3a11ea>=0x4?_0x74d525['b']['RotationYawPitchRollToRef'](_0x29e432,0x0,0x0,_0x4e31d2['_tmpQuaternion']):_0x74d525['b']['RotationYawPitchRollToRef'](0x0,_0x29e432,0x0,_0x4e31d2['_tmpQuaternion']),_0x4e31d2['_anchorMesh']['addChild'](_0x4e31d2['attachedMesh']),_0x4e31d2['_anchorMesh']['rotationQuaternion']['multiplyToRef'](_0x4e31d2['_tmpQuaternion'],_0x4e31d2['_anchorMesh']['rotationQuaternion']),_0x4e31d2['_anchorMesh']['removeChild'](_0x4e31d2['attachedMesh']),_0x4e31d2['attachedMesh']['setParent'](_0x9898ef)),_0x4e31d2['updateBoundingBox'](),_0x45da14['a']['_RestorePivotPoint'](_0x4e31d2['attachedMesh']);}_0x4e31d2['_updateDummy']();}),_0x1a8a2a['onDragStartObservable']['add'](function(){_0x4e31d2['onDragStartObservable']['notifyObservers']({}),_0x4e31d2['_selectNode'](_0x452bcf);}),_0x1a8a2a['onDragEndObservable']['add'](function(){_0x4e31d2['onRotationSphereDragEndObservable']['notifyObservers']({}),_0x4e31d2['_selectNode'](null),_0x4e31d2['_updateDummy']();}),_0xb078ea['_rotateSpheresParent']['addChild'](_0x452bcf);},_0xb078ea=this,_0xa672fd=0x0;_0xa672fd<0xc;_0xa672fd++)_0x2044ca(_0xa672fd);_0x4e31d2['_rootMesh']['addChild'](_0x4e31d2['_rotateSpheresParent']),_0x4e31d2['_scaleBoxesParent']=new _0x40d22e['a']('',_0x2ad8a2['utilityLayerScene']),_0x4e31d2['_scaleBoxesParent']['rotationQuaternion']=new _0x74d525['b']();for(var _0x4542f6=0x0;_0x4542f6<0x3;_0x4542f6++)for(var _0x126749=0x0;_0x126749<0x3;_0x126749++)for(var _0x1a8a2a,_0x84ca60=function(){var _0x2e9779=(0x1===_0x4542f6?0x1:0x0)+(0x1===_0x126749?0x1:0x0)+(0x1===_0x4a1beb?0x1:0x0);if(0x1===_0x2e9779||0x3===_0x2e9779)return'continue';var _0x7497c7=_0x144742['a']['CreateBox']('',{'size':0x1},_0x2ad8a2['utilityLayerScene']);_0x7497c7['material']=_0x27910f['coloredMaterial'],_0x7497c7['metadata']=0x2===_0x2e9779;var _0x3482b9=new _0x74d525['e'](_0x4542f6-0x1,_0x126749-0x1,_0x4a1beb-0x1)['normalize']();(_0x1a8a2a=new _0x356c6d['a']({'dragAxis':_0x3482b9}))['updateDragPlane']=!0x1,_0x1a8a2a['moveAttached']=!0x1,_0x7497c7['addBehavior'](_0x1a8a2a),_0x1a8a2a['onDragObservable']['add'](function(_0x9daf3b){if(_0x4e31d2['onScaleBoxDragObservable']['notifyObservers']({}),_0x4e31d2['attachedMesh']){var _0x4c9a3b=_0x4e31d2['attachedMesh']['parent'];if(_0x4c9a3b&&_0x4c9a3b['scaling']&&_0x4c9a3b['scaling']['isNonUniformWithinEpsilon'](0.001))return void _0x75193d['a']['Warn']('BoundingBoxGizmo\x20controls\x20are\x20not\x20supported\x20on\x20child\x20meshes\x20with\x20non-uniform\x20parent\x20scaling');_0x45da14['a']['_RemoveAndStorePivotPoint'](_0x4e31d2['attachedMesh']);var _0x283e60=_0x9daf3b['dragDistance']/_0x4e31d2['_boundingDimensions']['length']()*_0x4e31d2['_anchorMesh']['scaling']['length'](),_0x18a697=new _0x74d525['e'](_0x283e60,_0x283e60,_0x283e60);0x2===_0x2e9779&&(_0x18a697['x']*=Math['abs'](_0x3482b9['x']),_0x18a697['y']*=Math['abs'](_0x3482b9['y']),_0x18a697['z']*=Math['abs'](_0x3482b9['z'])),_0x18a697['scaleInPlace'](_0x4e31d2['_scaleDragSpeed']),_0x4e31d2['updateBoundingBox'](),_0x4e31d2['scalePivot']?(_0x4e31d2['attachedMesh']['getWorldMatrix']()['getRotationMatrixToRef'](_0x4e31d2['_tmpRotationMatrix']),_0x4e31d2['_boundingDimensions']['scaleToRef'](0.5,_0x4e31d2['_tmpVector']),_0x74d525['e']['TransformCoordinatesToRef'](_0x4e31d2['_tmpVector'],_0x4e31d2['_tmpRotationMatrix'],_0x4e31d2['_tmpVector']),_0x4e31d2['_anchorMesh']['position']['subtractInPlace'](_0x4e31d2['_tmpVector']),_0x4e31d2['_boundingDimensions']['multiplyToRef'](_0x4e31d2['scalePivot'],_0x4e31d2['_tmpVector']),_0x74d525['e']['TransformCoordinatesToRef'](_0x4e31d2['_tmpVector'],_0x4e31d2['_tmpRotationMatrix'],_0x4e31d2['_tmpVector']),_0x4e31d2['_anchorMesh']['position']['addInPlace'](_0x4e31d2['_tmpVector'])):(_0x7497c7['absolutePosition']['subtractToRef'](_0x4e31d2['_anchorMesh']['position'],_0x4e31d2['_tmpVector']),_0x4e31d2['_anchorMesh']['position']['subtractInPlace'](_0x4e31d2['_tmpVector'])),_0x4e31d2['_anchorMesh']['addChild'](_0x4e31d2['attachedMesh']),_0x4e31d2['_anchorMesh']['scaling']['addInPlace'](_0x18a697),(_0x4e31d2['_anchorMesh']['scaling']['x']<0x0||_0x4e31d2['_anchorMesh']['scaling']['y']<0x0||_0x4e31d2['_anchorMesh']['scaling']['z']<0x0)&&_0x4e31d2['_anchorMesh']['scaling']['subtractInPlace'](_0x18a697),_0x4e31d2['_anchorMesh']['removeChild'](_0x4e31d2['attachedMesh']),_0x4e31d2['attachedMesh']['setParent'](_0x4c9a3b),_0x45da14['a']['_RestorePivotPoint'](_0x4e31d2['attachedMesh']);}_0x4e31d2['_updateDummy']();}),_0x1a8a2a['onDragStartObservable']['add'](function(){_0x4e31d2['onDragStartObservable']['notifyObservers']({}),_0x4e31d2['_selectNode'](_0x7497c7);}),_0x1a8a2a['onDragEndObservable']['add'](function(){_0x4e31d2['onScaleBoxDragEndObservable']['notifyObservers']({}),_0x4e31d2['_selectNode'](null),_0x4e31d2['_updateDummy']();}),_0x27910f['_scaleBoxesParent']['addChild'](_0x7497c7);},_0x27910f=this,_0x4a1beb=0x0;_0x4a1beb<0x3;_0x4a1beb++)_0x84ca60();_0x4e31d2['_rootMesh']['addChild'](_0x4e31d2['_scaleBoxesParent']);var _0x3c7ca3=new Array();return _0x4e31d2['_pointerObserver']=_0x2ad8a2['utilityLayerScene']['onPointerObservable']['add'](function(_0x41a37a){_0x3c7ca3[_0x41a37a['event']['pointerId']]?_0x41a37a['pickInfo']&&_0x41a37a['pickInfo']['pickedMesh']!=_0x3c7ca3[_0x41a37a['event']['pointerId']]&&(_0x3c7ca3[_0x41a37a['event']['pointerId']]['material']=_0x4e31d2['coloredMaterial'],delete _0x3c7ca3[_0x41a37a['event']['pointerId']]):_0x4e31d2['_rotateSpheresParent']['getChildMeshes']()['concat'](_0x4e31d2['_scaleBoxesParent']['getChildMeshes']())['forEach'](function(_0x12e508){_0x41a37a['pickInfo']&&_0x41a37a['pickInfo']['pickedMesh']==_0x12e508&&(_0x3c7ca3[_0x41a37a['event']['pointerId']]=_0x12e508,_0x12e508['material']=_0x4e31d2['hoverColoredMaterial']);});}),_0x4e31d2['_renderObserver']=_0x4e31d2['gizmoLayer']['originalScene']['onBeforeRenderObservable']['add'](function(){_0x4e31d2['attachedMesh']&&!_0x4e31d2['_existingMeshScale']['equals'](_0x4e31d2['attachedMesh']['scaling'])?_0x4e31d2['updateBoundingBox']():(_0x4e31d2['fixedDragMeshScreenSize']||_0x4e31d2['fixedDragMeshBoundsSize'])&&(_0x4e31d2['_updateRotationSpheres'](),_0x4e31d2['_updateScaleBoxes']()),_0x4e31d2['_dragMesh']&&_0x4e31d2['attachedMesh']&&_0x4e31d2['pointerDragBehavior']['dragging']&&(_0x4e31d2['_lineBoundingBox']['position']['rotateByQuaternionToRef'](_0x4e31d2['_rootMesh']['rotationQuaternion'],_0x4e31d2['_tmpVector']),_0x4e31d2['attachedMesh']['setAbsolutePosition'](_0x4e31d2['_dragMesh']['position']['add'](_0x4e31d2['_tmpVector']['scale'](-0x1))));}),_0x4e31d2['updateBoundingBox'](),_0x4e31d2;}return Object(_0x18e13d['d'])(_0xd0b7d5,_0x397205),_0xd0b7d5['prototype']['setColor']=function(_0x3f67fd){this['coloredMaterial']['emissiveColor']=_0x3f67fd,this['hoverColoredMaterial']['emissiveColor']=_0x3f67fd['clone']()['add'](new _0x39310d['a'](0.3,0.3,0.3)),this['_lineBoundingBox']['getChildren']()['forEach'](function(_0x158090){_0x158090['color']&&(_0x158090['color']=_0x3f67fd);});},_0xd0b7d5['prototype']['_attachedNodeChanged']=function(_0x40ea20){var _0x5c2937=this;if(_0x40ea20){_0x45da14['a']['_RemoveAndStorePivotPoint'](_0x40ea20);var _0x280e75=_0x40ea20['parent'];this['_anchorMesh']['addChild'](_0x40ea20),this['_anchorMesh']['removeChild'](_0x40ea20),_0x40ea20['setParent'](_0x280e75),_0x45da14['a']['_RestorePivotPoint'](_0x40ea20),this['updateBoundingBox'](),_0x40ea20['getChildMeshes'](!0x1)['forEach'](function(_0x46367d){_0x46367d['markAsDirty']('scaling');}),this['gizmoLayer']['utilityLayerScene']['onAfterRenderObservable']['addOnce'](function(){_0x5c2937['_updateDummy']();});}},_0xd0b7d5['prototype']['_selectNode']=function(_0x33f48a){this['_rotateSpheresParent']['getChildMeshes']()['concat'](this['_scaleBoxesParent']['getChildMeshes']())['forEach'](function(_0x5da840){_0x5da840['isVisible']=!_0x33f48a||_0x5da840==_0x33f48a;});},_0xd0b7d5['prototype']['updateBoundingBox']=function(){if(this['attachedMesh']){_0x45da14['a']['_RemoveAndStorePivotPoint'](this['attachedMesh']);var _0x214e37=this['attachedMesh']['parent'];this['attachedMesh']['setParent'](null);var _0x14c593=null;this['attachedMesh']['skeleton']&&(_0x14c593=this['attachedMesh']['skeleton']['overrideMesh'],this['attachedMesh']['skeleton']['overrideMesh']=null),this['_update'](),this['attachedMesh']['rotationQuaternion']||(this['attachedMesh']['rotationQuaternion']=_0x74d525['b']['RotationYawPitchRoll'](this['attachedMesh']['rotation']['y'],this['attachedMesh']['rotation']['x'],this['attachedMesh']['rotation']['z'])),this['_anchorMesh']['rotationQuaternion']||(this['_anchorMesh']['rotationQuaternion']=_0x74d525['b']['RotationYawPitchRoll'](this['_anchorMesh']['rotation']['y'],this['_anchorMesh']['rotation']['x'],this['_anchorMesh']['rotation']['z'])),this['_anchorMesh']['rotationQuaternion']['copyFrom'](this['attachedMesh']['rotationQuaternion']),this['_tmpQuaternion']['copyFrom'](this['attachedMesh']['rotationQuaternion']),this['_tmpVector']['copyFrom'](this['attachedMesh']['position']),this['attachedMesh']['rotationQuaternion']['set'](0x0,0x0,0x0,0x1),this['attachedMesh']['position']['set'](0x0,0x0,0x0);var _0x50ea96=this['attachedMesh']['getHierarchyBoundingVectors'](!this['ignoreChildren'],this['includeChildPredicate']);_0x50ea96['max']['subtractToRef'](_0x50ea96['min'],this['_boundingDimensions']),this['_lineBoundingBox']['scaling']['copyFrom'](this['_boundingDimensions']),this['_lineBoundingBox']['position']['set']((_0x50ea96['max']['x']+_0x50ea96['min']['x'])/0x2,(_0x50ea96['max']['y']+_0x50ea96['min']['y'])/0x2,(_0x50ea96['max']['z']+_0x50ea96['min']['z'])/0x2),this['_rotateSpheresParent']['position']['copyFrom'](this['_lineBoundingBox']['position']),this['_scaleBoxesParent']['position']['copyFrom'](this['_lineBoundingBox']['position']),this['_lineBoundingBox']['computeWorldMatrix'](),this['_anchorMesh']['position']['copyFrom'](this['_lineBoundingBox']['absolutePosition']),this['attachedMesh']['rotationQuaternion']['copyFrom'](this['_tmpQuaternion']),this['attachedMesh']['position']['copyFrom'](this['_tmpVector']),this['attachedMesh']['setParent'](_0x214e37),this['attachedMesh']['skeleton']&&(this['attachedMesh']['skeleton']['overrideMesh']=_0x14c593);}this['_updateRotationSpheres'](),this['_updateScaleBoxes'](),this['attachedMesh']&&(this['_existingMeshScale']['copyFrom'](this['attachedMesh']['scaling']),_0x45da14['a']['_RestorePivotPoint'](this['attachedMesh']));},_0xd0b7d5['prototype']['_updateRotationSpheres']=function(){for(var _0x4419d4=this['_rotateSpheresParent']['getChildMeshes'](),_0x2a4915=0x0;_0x2a4915<0x3;_0x2a4915++)for(var _0x10a63c=0x0;_0x10a63c<0x2;_0x10a63c++)for(var _0x3f3215=0x0;_0x3f3215<0x2;_0x3f3215++){var _0x4b6b19=0x4*_0x2a4915+0x2*_0x10a63c+_0x3f3215;if(0x0==_0x2a4915&&(_0x4419d4[_0x4b6b19]['position']['set'](this['_boundingDimensions']['x']/0x2,this['_boundingDimensions']['y']*_0x10a63c,this['_boundingDimensions']['z']*_0x3f3215),_0x4419d4[_0x4b6b19]['position']['addInPlace'](new _0x74d525['e'](-this['_boundingDimensions']['x']/0x2,-this['_boundingDimensions']['y']/0x2,-this['_boundingDimensions']['z']/0x2)),_0x4419d4[_0x4b6b19]['lookAt'](_0x74d525['e']['Cross'](_0x4419d4[_0x4b6b19]['position']['normalizeToNew'](),_0x74d525['e']['Right']())['normalizeToNew']()['add'](_0x4419d4[_0x4b6b19]['position']))),0x1==_0x2a4915&&(_0x4419d4[_0x4b6b19]['position']['set'](this['_boundingDimensions']['x']*_0x10a63c,this['_boundingDimensions']['y']/0x2,this['_boundingDimensions']['z']*_0x3f3215),_0x4419d4[_0x4b6b19]['position']['addInPlace'](new _0x74d525['e'](-this['_boundingDimensions']['x']/0x2,-this['_boundingDimensions']['y']/0x2,-this['_boundingDimensions']['z']/0x2)),_0x4419d4[_0x4b6b19]['lookAt'](_0x74d525['e']['Cross'](_0x4419d4[_0x4b6b19]['position']['normalizeToNew'](),_0x74d525['e']['Up']())['normalizeToNew']()['add'](_0x4419d4[_0x4b6b19]['position']))),0x2==_0x2a4915&&(_0x4419d4[_0x4b6b19]['position']['set'](this['_boundingDimensions']['x']*_0x10a63c,this['_boundingDimensions']['y']*_0x3f3215,this['_boundingDimensions']['z']/0x2),_0x4419d4[_0x4b6b19]['position']['addInPlace'](new _0x74d525['e'](-this['_boundingDimensions']['x']/0x2,-this['_boundingDimensions']['y']/0x2,-this['_boundingDimensions']['z']/0x2)),_0x4419d4[_0x4b6b19]['lookAt'](_0x74d525['e']['Cross'](_0x4419d4[_0x4b6b19]['position']['normalizeToNew'](),_0x74d525['e']['Forward']())['normalizeToNew']()['add'](_0x4419d4[_0x4b6b19]['position']))),this['fixedDragMeshScreenSize']&&this['gizmoLayer']['utilityLayerScene']['activeCamera']){_0x4419d4[_0x4b6b19]['absolutePosition']['subtractToRef'](this['gizmoLayer']['utilityLayerScene']['activeCamera']['position'],this['_tmpVector']);var _0x656bec=this['rotationSphereSize']*this['_tmpVector']['length']()/this['fixedDragMeshScreenSizeDistanceFactor'];_0x4419d4[_0x4b6b19]['scaling']['set'](_0x656bec,_0x656bec,_0x656bec);}else this['fixedDragMeshBoundsSize']?_0x4419d4[_0x4b6b19]['scaling']['set'](this['rotationSphereSize']*this['_boundingDimensions']['x'],this['rotationSphereSize']*this['_boundingDimensions']['y'],this['rotationSphereSize']*this['_boundingDimensions']['z']):_0x4419d4[_0x4b6b19]['scaling']['set'](this['rotationSphereSize'],this['rotationSphereSize'],this['rotationSphereSize']);}},_0xd0b7d5['prototype']['_updateScaleBoxes']=function(){for(var _0x25813d=this['_scaleBoxesParent']['getChildMeshes'](),_0x250665=0x0,_0x3ca3b5=0x0;_0x3ca3b5<0x3;_0x3ca3b5++)for(var _0x215165=0x0;_0x215165<0x3;_0x215165++)for(var _0x53752e=0x0;_0x53752e<0x3;_0x53752e++){var _0x1104ee=(0x1===_0x3ca3b5?0x1:0x0)+(0x1===_0x215165?0x1:0x0)+(0x1===_0x53752e?0x1:0x0);if(0x1!==_0x1104ee&&0x3!==_0x1104ee){if(_0x25813d[_0x250665]){if(_0x25813d[_0x250665]['position']['set'](this['_boundingDimensions']['x']*(_0x3ca3b5/0x2),this['_boundingDimensions']['y']*(_0x215165/0x2),this['_boundingDimensions']['z']*(_0x53752e/0x2)),_0x25813d[_0x250665]['position']['addInPlace'](new _0x74d525['e'](-this['_boundingDimensions']['x']/0x2,-this['_boundingDimensions']['y']/0x2,-this['_boundingDimensions']['z']/0x2)),this['fixedDragMeshScreenSize']&&this['gizmoLayer']['utilityLayerScene']['activeCamera']){_0x25813d[_0x250665]['absolutePosition']['subtractToRef'](this['gizmoLayer']['utilityLayerScene']['activeCamera']['position'],this['_tmpVector']);var _0x2108c8=this['scaleBoxSize']*this['_tmpVector']['length']()/this['fixedDragMeshScreenSizeDistanceFactor'];_0x25813d[_0x250665]['scaling']['set'](_0x2108c8,_0x2108c8,_0x2108c8);}else this['fixedDragMeshBoundsSize']?_0x25813d[_0x250665]['scaling']['set'](this['scaleBoxSize']*this['_boundingDimensions']['x'],this['scaleBoxSize']*this['_boundingDimensions']['y'],this['scaleBoxSize']*this['_boundingDimensions']['z']):_0x25813d[_0x250665]['scaling']['set'](this['scaleBoxSize'],this['scaleBoxSize'],this['scaleBoxSize']);}_0x250665++;}}},_0xd0b7d5['prototype']['setEnabledRotationAxis']=function(_0x5825fe){this['_rotateSpheresParent']['getChildMeshes']()['forEach'](function(_0x3f7da8,_0x8fb906){_0x8fb906<0x4?_0x3f7da8['setEnabled'](-0x1!=_0x5825fe['indexOf']('x')):_0x8fb906<0x8?_0x3f7da8['setEnabled'](-0x1!=_0x5825fe['indexOf']('y')):_0x3f7da8['setEnabled'](-0x1!=_0x5825fe['indexOf']('z'));});},_0xd0b7d5['prototype']['setEnabledScaling']=function(_0x636fd2,_0x1ce078){void 0x0===_0x1ce078&&(_0x1ce078=!0x1),this['_scaleBoxesParent']['getChildMeshes']()['forEach'](function(_0x5f2380,_0x2665bd){var _0x3d4e9a=_0x636fd2;_0x1ce078&&!0x0===_0x5f2380['metadata']&&(_0x3d4e9a=!0x1),_0x5f2380['setEnabled'](_0x3d4e9a);});},_0xd0b7d5['prototype']['_updateDummy']=function(){this['_dragMesh']&&(this['_dragMesh']['position']['copyFrom'](this['_lineBoundingBox']['getAbsolutePosition']()),this['_dragMesh']['scaling']['copyFrom'](this['_lineBoundingBox']['scaling']),this['_dragMesh']['rotationQuaternion']['copyFrom'](this['_rootMesh']['rotationQuaternion']));},_0xd0b7d5['prototype']['enableDragBehavior']=function(){this['_dragMesh']=_0x3cf5e5['a']['CreateBox']('dummy',0x1,this['gizmoLayer']['utilityLayerScene']),this['_dragMesh']['visibility']=0x0,this['_dragMesh']['rotationQuaternion']=new _0x74d525['b'](),this['pointerDragBehavior']['useObjectOrientationForDragging']=!0x1,this['_dragMesh']['addBehavior'](this['pointerDragBehavior']);},_0xd0b7d5['prototype']['dispose']=function(){this['gizmoLayer']['utilityLayerScene']['onPointerObservable']['remove'](this['_pointerObserver']),this['gizmoLayer']['originalScene']['onBeforeRenderObservable']['remove'](this['_renderObserver']),this['_lineBoundingBox']['dispose'](),this['_rotateSpheresParent']['dispose'](),this['_scaleBoxesParent']['dispose'](),this['_dragMesh']&&this['_dragMesh']['dispose'](),_0x397205['prototype']['dispose']['call'](this);},_0xd0b7d5['MakeNotPickableAndWrapInBoundingBox']=function(_0x1f75cc){var _0x3cd8a8=function(_0xfb66d6){_0xfb66d6['isPickable']=!0x1,_0xfb66d6['getChildMeshes']()['forEach'](function(_0x166cc7){_0x3cd8a8(_0x166cc7);});};_0x3cd8a8(_0x1f75cc),_0x1f75cc['rotationQuaternion']||(_0x1f75cc['rotationQuaternion']=_0x74d525['b']['RotationYawPitchRoll'](_0x1f75cc['rotation']['y'],_0x1f75cc['rotation']['x'],_0x1f75cc['rotation']['z']));var _0x2c9c0a=_0x1f75cc['position']['clone'](),_0x1664bc=_0x1f75cc['rotationQuaternion']['clone']();_0x1f75cc['rotationQuaternion']['set'](0x0,0x0,0x0,0x1),_0x1f75cc['position']['set'](0x0,0x0,0x0);var _0x540bb8=_0x144742['a']['CreateBox']('box',{'size':0x1},_0x1f75cc['getScene']()),_0xdbb12d=_0x1f75cc['getHierarchyBoundingVectors']();return _0xdbb12d['max']['subtractToRef'](_0xdbb12d['min'],_0x540bb8['scaling']),0x0===_0x540bb8['scaling']['y']&&(_0x540bb8['scaling']['y']=_0x27da6e['a']),0x0===_0x540bb8['scaling']['x']&&(_0x540bb8['scaling']['x']=_0x27da6e['a']),0x0===_0x540bb8['scaling']['z']&&(_0x540bb8['scaling']['z']=_0x27da6e['a']),_0x540bb8['position']['set']((_0xdbb12d['max']['x']+_0xdbb12d['min']['x'])/0x2,(_0xdbb12d['max']['y']+_0xdbb12d['min']['y'])/0x2,(_0xdbb12d['max']['z']+_0xdbb12d['min']['z'])/0x2),_0x1f75cc['addChild'](_0x540bb8),_0x1f75cc['rotationQuaternion']['copyFrom'](_0x1664bc),_0x1f75cc['position']['copyFrom'](_0x2c9c0a),_0x1f75cc['removeChild'](_0x540bb8),_0x540bb8['addChild'](_0x1f75cc),_0x540bb8['visibility']=0x0,_0x540bb8;},_0xd0b7d5['prototype']['setCustomMesh']=function(_0x5e3d6d){_0x75193d['a']['Error']('Custom\x20meshes\x20are\x20not\x20supported\x20on\x20this\x20gizmo');},_0xd0b7d5;}(_0x417dc8['a']),_0x4e6561=function(_0x3c9dfa){function _0x7b7774(_0x4ed12c,_0x1615aa,_0x3b55a3,_0x5946c3,_0x4d075c,_0x4c0383,_0xc36f5a){var _0x23da7b;void 0x0===_0x1615aa&&(_0x1615aa=_0x39310d['a']['Gray']()),void 0x0===_0x3b55a3&&(_0x3b55a3=_0x539118['a']['DefaultUtilityLayer']),void 0x0===_0x5946c3&&(_0x5946c3=0x20),void 0x0===_0x4d075c&&(_0x4d075c=null),void 0x0===_0x4c0383&&(_0x4c0383=!0x1),void 0x0===_0xc36f5a&&(_0xc36f5a=0x1);var _0x3cf662=_0x3c9dfa['call'](this,_0x3b55a3)||this;_0x3cf662['_pointerObserver']=null,_0x3cf662['snapDistance']=0x0,_0x3cf662['onSnapObservable']=new _0x6ac1f7['c'](),_0x3cf662['_isEnabled']=!0x0,_0x3cf662['_parent']=null,_0x3cf662['_dragging']=!0x1,_0x3cf662['_parent']=_0x4d075c,_0x3cf662['_coloredMaterial']=new _0x5905ab['a']('',_0x3b55a3['utilityLayerScene']),_0x3cf662['_coloredMaterial']['diffuseColor']=_0x1615aa,_0x3cf662['_coloredMaterial']['specularColor']=_0x1615aa['subtract'](new _0x39310d['a'](0.1,0.1,0.1)),_0x3cf662['_hoverMaterial']=new _0x5905ab['a']('',_0x3b55a3['utilityLayerScene']),_0x3cf662['_hoverMaterial']['diffuseColor']=_0x39310d['a']['Yellow'](),_0x3cf662['_disableMaterial']=new _0x5905ab['a']('',_0x3b55a3['utilityLayerScene']),_0x3cf662['_disableMaterial']['diffuseColor']=_0x39310d['a']['Gray'](),_0x3cf662['_disableMaterial']['alpha']=0.4,_0x3cf662['_gizmoMesh']=new _0x3cf5e5['a']('',_0x3b55a3['utilityLayerScene']);var _0x56abe1=_0x3cf662['_createGizmoMesh'](_0x3cf662['_gizmoMesh'],_0xc36f5a,_0x5946c3),_0x38c80c=_0x56abe1['rotationMesh'],_0x333aa5=_0x56abe1['collider'],_0x39042e=[];_0x3cf662['_rotationCircle']=_0x3cf662['setupRotationCircle'](_0x39042e,_0x3cf662['_gizmoMesh']),_0x3cf662['_gizmoMesh']['lookAt'](_0x3cf662['_rootMesh']['position']['add'](_0x4ed12c)),_0x3cf662['_rootMesh']['addChild'](_0x3cf662['_gizmoMesh']),_0x3cf662['_gizmoMesh']['scaling']['scaleInPlace'](0x1/0x3),_0x3cf662['dragBehavior']=new _0x356c6d['a']({'dragPlaneNormal':_0x4ed12c}),_0x3cf662['dragBehavior']['moveAttached']=!0x1,_0x3cf662['dragBehavior']['maxDragAngle']=0x9*Math['PI']/0x14,_0x3cf662['dragBehavior']['_useAlternatePickedPointAboveMaxDragAngle']=!0x0,_0x3cf662['_rootMesh']['addBehavior'](_0x3cf662['dragBehavior']);var _0x573965=0x0,_0x5876c1=new _0x74d525['e'](),_0x333a16=new _0x74d525['e'](),_0x3e87ce=new _0x74d525['a'](),_0xb4a2ee=new _0x74d525['e'](),_0x366700=new _0x74d525['e']();_0x3cf662['dragBehavior']['onDragStartObservable']['add'](function(_0x2b5ba4){if(_0x3cf662['attachedNode']){_0x5876c1['copyFrom'](_0x2b5ba4['dragPlanePoint']);var _0x2e917c=new _0x74d525['e'](0x0,0x0,0x1),_0x4bf45e=_0x3cf662['_rotationCircle']['getDirection'](_0x2e917c);_0x4bf45e['normalize'](),_0x3cf662['_gizmoMesh']['removeChild'](_0x3cf662['_rotationCircle']),_0x5876c1['copyFrom'](_0x2b5ba4['dragPlanePoint']),_0x333a16=_0x2b5ba4['dragPlanePoint'];var _0x3f4f09=_0x3cf662['_rotationCircle']['getAbsolutePosition']()['clone'](),_0x56df75=_0x3cf662['_rotationCircle']['getAbsolutePosition']()['clone']()['addInPlace'](_0x4bf45e),_0x12b8ef=_0x2b5ba4['dragPlanePoint'],_0x40f87e=_0x74d525['e']['GetAngleBetweenVectors'](_0x56df75['subtract'](_0x3f4f09),_0x12b8ef['subtract'](_0x3f4f09),_0x3cf662['_rotationCircle']['up']);_0x3cf662['_rotationCircle']['addRotation'](0x0,_0x40f87e,0x0),_0x3cf662['_dragging']=!0x0;}}),_0x3cf662['dragBehavior']['onDragEndObservable']['add'](function(){_0x573965=0x0,_0x3cf662['updateRotationCircle'](_0x3cf662['_rotationCircle'],_0x39042e,_0x573965,_0x333a16),_0x3cf662['_gizmoMesh']['addChild'](_0x3cf662['_rotationCircle']),_0x3cf662['_dragging']=!0x1;});var _0x51a9d3={'snapDistance':0x0},_0x50cbe6=0x0,_0x341c8a=new _0x74d525['a'](),_0x5b6597=new _0x74d525['b']();_0x3cf662['dragBehavior']['onDragObservable']['add'](function(_0x3e1f12){if(_0x3cf662['attachedNode']){var _0x36815e=new _0x74d525['e'](0x1,0x1,0x1),_0x422d92=new _0x74d525['b'](0x0,0x0,0x0,0x1),_0x167c31=new _0x74d525['e'](0x0,0x0,0x0);_0x3cf662['attachedNode']['getWorldMatrix']()['decompose'](_0x36815e,_0x422d92,_0x167c31);var _0x4bcc6a=_0x3e1f12['dragPlanePoint']['subtract'](_0x167c31)['normalize'](),_0x530efc=_0x5876c1['subtract'](_0x167c31)['normalize'](),_0x5d9790=_0x74d525['e']['Cross'](_0x4bcc6a,_0x530efc),_0x7711b8=_0x74d525['e']['Dot'](_0x4bcc6a,_0x530efc),_0x452624=Math['atan2'](_0x5d9790['length'](),_0x7711b8);_0xb4a2ee['copyFrom'](_0x4ed12c),_0x366700['copyFrom'](_0x4ed12c),_0x3cf662['updateGizmoRotationToMatchAttachedMesh']&&(_0x422d92['toRotationMatrix'](_0x3e87ce),_0x366700=_0x74d525['e']['TransformCoordinates'](_0xb4a2ee,_0x3e87ce));var _0x101817=!0x1;if(_0x3b55a3['utilityLayerScene']['activeCamera']){var _0x5715ff=_0x3b55a3['utilityLayerScene']['activeCamera']['position']['subtract'](_0x167c31);_0x74d525['e']['Dot'](_0x5715ff,_0x366700)>0x0&&(_0xb4a2ee['scaleInPlace'](-0x1),_0x366700['scaleInPlace'](-0x1),_0x101817=!0x0);}_0x74d525['e']['Dot'](_0x366700,_0x5d9790)>0x0&&(_0x452624=-_0x452624);var _0x4ccf2c=!0x1;if(0x0!=_0x3cf662['snapDistance']){if(_0x50cbe6+=_0x452624,Math['abs'](_0x50cbe6)>_0x3cf662['snapDistance']){var _0x29608b=Math['floor'](Math['abs'](_0x50cbe6)/_0x3cf662['snapDistance']);_0x50cbe6<0x0&&(_0x29608b*=-0x1),_0x50cbe6%=_0x3cf662['snapDistance'],_0x452624=_0x3cf662['snapDistance']*_0x29608b,_0x4ccf2c=!0x0;}else _0x452624=0x0;}_0x573965+=_0x101817?-_0x452624:_0x452624,_0x3cf662['updateRotationCircle'](_0x3cf662['_rotationCircle'],_0x39042e,_0x573965,_0x333a16);var _0x53dbbc=Math['sin'](_0x452624/0x2);if(_0x5b6597['set'](_0xb4a2ee['x']*_0x53dbbc,_0xb4a2ee['y']*_0x53dbbc,_0xb4a2ee['z']*_0x53dbbc,Math['cos'](_0x452624/0x2)),_0x341c8a['determinant']()>0x0){var _0x230710=new _0x74d525['e']();_0x5b6597['toEulerAnglesToRef'](_0x230710),_0x74d525['b']['RotationYawPitchRollToRef'](_0x230710['y'],-_0x230710['x'],-_0x230710['z'],_0x5b6597);}_0x3cf662['updateGizmoRotationToMatchAttachedMesh']?_0x422d92['multiplyToRef'](_0x5b6597,_0x422d92):_0x5b6597['multiplyToRef'](_0x422d92,_0x422d92),_0x3cf662['attachedNode']['getWorldMatrix']()['copyFrom'](_0x74d525['a']['Compose'](_0x36815e,_0x422d92,_0x167c31)),_0x5876c1['copyFrom'](_0x3e1f12['dragPlanePoint']),_0x4ccf2c&&(_0x51a9d3['snapDistance']=_0x452624,_0x3cf662['onSnapObservable']['notifyObservers'](_0x51a9d3)),_0x3cf662['_matrixChanged']();}});var _0x918abf=_0x3b55a3['_getSharedGizmoLight']();_0x918abf['includedOnlyMeshes']=_0x918abf['includedOnlyMeshes']['concat'](_0x3cf662['_rootMesh']['getChildMeshes'](!0x1));var _0x53f68e={'colliderMeshes':[_0x333aa5],'gizmoMeshes':[_0x38c80c],'material':_0x3cf662['_coloredMaterial'],'hoverMaterial':_0x3cf662['_hoverMaterial'],'disableMaterial':_0x3cf662['_disableMaterial'],'active':!0x1};return null===(_0x23da7b=_0x3cf662['_parent'])||void 0x0===_0x23da7b||_0x23da7b['addToAxisCache'](_0x3cf662['_gizmoMesh'],_0x53f68e),_0x3cf662['_pointerObserver']=_0x3b55a3['utilityLayerScene']['onPointerObservable']['add'](function(_0x1927e1){var _0x232fd0;if(!_0x3cf662['_customMeshSet']&&(_0x3cf662['_isHovered']=!(-0x1==_0x53f68e['colliderMeshes']['indexOf'](null===(_0x232fd0=null==_0x1927e1?void 0x0:_0x1927e1['pickInfo'])||void 0x0===_0x232fd0?void 0x0:_0x232fd0['pickedMesh'])),!_0x3cf662['_parent'])){var _0x430408=_0x3cf662['_isHovered']||_0x3cf662['_dragging']?_0x3cf662['_hoverMaterial']:_0x3cf662['_coloredMaterial'];_0x53f68e['gizmoMeshes']['forEach'](function(_0x5110cc){_0x5110cc['material']=_0x430408,_0x5110cc['color']&&(_0x5110cc['color']=_0x430408['diffuseColor']);});}}),_0x3cf662;}return Object(_0x18e13d['d'])(_0x7b7774,_0x3c9dfa),_0x7b7774['prototype']['_createGizmoMesh']=function(_0x46ff2d,_0x58e2c5,_0x4cef27){var _0x5e8883=_0x3cf5e5['a']['CreateTorus']('ignore',0.6,0.03*_0x58e2c5,_0x4cef27,this['gizmoLayer']['utilityLayerScene']);_0x5e8883['visibility']=0x0;var _0x1f90aa=_0x3cf5e5['a']['CreateTorus']('',0.6,0.005*_0x58e2c5,_0x4cef27,this['gizmoLayer']['utilityLayerScene']);return _0x1f90aa['material']=this['_coloredMaterial'],_0x1f90aa['rotation']['x']=Math['PI']/0x2,_0x5e8883['rotation']['x']=Math['PI']/0x2,_0x46ff2d['addChild'](_0x1f90aa),_0x46ff2d['addChild'](_0x5e8883),{'rotationMesh':_0x1f90aa,'collider':_0x5e8883};},_0x7b7774['prototype']['_attachedNodeChanged']=function(_0x1865d9){this['dragBehavior']&&(this['dragBehavior']['enabled']=!!_0x1865d9);},_0x7b7774['prototype']['setupRotationCircle']=function(_0x5a9fca,_0x2a8093){for(var _0x117ee7=_0x7b7774['_CircleConstants']['pi2']/_0x7b7774['_CircleConstants']['tessellation'],_0x1543b9=-Math['PI']/0x2;_0x1543b90x0?_0x165eb9:-0x1*_0x165eb9,_0x53dc69=_0x2726a1>0x0?_0x53a14a:-0x1*_0x53a14a;_0xf32ff6[_0x1b4daf]['set'](_0x7b7774['_CircleConstants']['radius']*Math['sin'](_0x567729)*Math['cos'](_0x53dc69),0x0,_0x7b7774['_CircleConstants']['radius']*Math['cos'](_0x567729)*Math['cos'](_0x53dc69));}else _0xf32ff6[_0x1b4daf]['set'](0x0,0x0,0x0);}_0x1b4daf++;}_0x19e515++;}},_0x7b7774['prototype']['updateRotationCircle']=function(_0x2ba687,_0x1eafd5,_0x7c7e1e,_0x3eaaf7){this['updateRotationPath'](_0x1eafd5,_0x7c7e1e),_0x3cf5e5['a']['CreateRibbon']('rotationCircle',_0x1eafd5,!0x1,!0x1,0x0,this['gizmoLayer']['utilityLayerScene'],void 0x0,void 0x0,_0x2ba687['geometry']?_0x2ba687:void 0x0);},Object['defineProperty'](_0x7b7774['prototype'],'isEnabled',{'get':function(){return this['_isEnabled'];},'set':function(_0x298a4a){this['_isEnabled']=_0x298a4a,_0x298a4a?this['_parent']&&(this['attachedMesh']=this['_parent']['attachedMesh']):this['attachedMesh']=null;},'enumerable':!0x1,'configurable':!0x0}),_0x7b7774['prototype']['dispose']=function(){this['onSnapObservable']['clear'](),this['gizmoLayer']['utilityLayerScene']['onPointerObservable']['remove'](this['_pointerObserver']),this['dragBehavior']['detach'](),this['_gizmoMesh']&&this['_gizmoMesh']['dispose'](),this['_rotationCircle']&&this['_rotationCircle']['dispose'](),[this['_coloredMaterial'],this['_hoverMaterial'],this['_disableMaterial']]['forEach'](function(_0x1417ce){_0x1417ce&&_0x1417ce['dispose']();}),_0x3c9dfa['prototype']['dispose']['call'](this);},_0x7b7774['_CircleConstants']={'radius':0.3,'pi2':0x2*Math['PI'],'tessellation':0x46,'rotationCircleRange':0x4},_0x7b7774;}(_0x417dc8['a']),_0xbdd3b4=function(_0x2d3173){function _0x3a3d9f(_0x3aecbb,_0x284a0b,_0xb4831e,_0x142699,_0x31ad24){void 0x0===_0x3aecbb&&(_0x3aecbb=_0x539118['a']['DefaultUtilityLayer']),void 0x0===_0x284a0b&&(_0x284a0b=0x20),void 0x0===_0xb4831e&&(_0xb4831e=!0x1),void 0x0===_0x142699&&(_0x142699=0x1);var _0x2b3668=_0x2d3173['call'](this,_0x3aecbb)||this;return _0x2b3668['onDragStartObservable']=new _0x6ac1f7['c'](),_0x2b3668['onDragEndObservable']=new _0x6ac1f7['c'](),_0x2b3668['_observables']=[],_0x2b3668['_gizmoAxisCache']=new Map(),_0x2b3668['xGizmo']=new _0x4e6561(new _0x74d525['e'](0x1,0x0,0x0),_0x39310d['a']['Red']()['scale'](0.5),_0x3aecbb,_0x284a0b,_0x2b3668,_0xb4831e,_0x142699),_0x2b3668['yGizmo']=new _0x4e6561(new _0x74d525['e'](0x0,0x1,0x0),_0x39310d['a']['Green']()['scale'](0.5),_0x3aecbb,_0x284a0b,_0x2b3668,_0xb4831e,_0x142699),_0x2b3668['zGizmo']=new _0x4e6561(new _0x74d525['e'](0x0,0x0,0x1),_0x39310d['a']['Blue']()['scale'](0.5),_0x3aecbb,_0x284a0b,_0x2b3668,_0xb4831e,_0x142699),[_0x2b3668['xGizmo'],_0x2b3668['yGizmo'],_0x2b3668['zGizmo']]['forEach'](function(_0x4f9e77){_0x4f9e77['dragBehavior']['onDragStartObservable']['add'](function(){_0x2b3668['onDragStartObservable']['notifyObservers']({});}),_0x4f9e77['dragBehavior']['onDragEndObservable']['add'](function(){_0x2b3668['onDragEndObservable']['notifyObservers']({});});}),_0x2b3668['attachedMesh']=null,_0x2b3668['attachedNode']=null,_0x31ad24?_0x31ad24['addToAxisCache'](_0x2b3668['_gizmoAxisCache']):_0x417dc8['a']['GizmoAxisPointerObserver'](_0x3aecbb,_0x2b3668['_gizmoAxisCache']),_0x2b3668;}return Object(_0x18e13d['d'])(_0x3a3d9f,_0x2d3173),Object['defineProperty'](_0x3a3d9f['prototype'],'attachedMesh',{'get':function(){return this['_meshAttached'];},'set':function(_0x4be60b){this['_meshAttached']=_0x4be60b,this['_nodeAttached']=_0x4be60b,this['_checkBillboardTransform'](),[this['xGizmo'],this['yGizmo'],this['zGizmo']]['forEach'](function(_0x4f96f2){_0x4f96f2['isEnabled']?_0x4f96f2['attachedMesh']=_0x4be60b:_0x4f96f2['attachedMesh']=null;});},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3a3d9f['prototype'],'attachedNode',{'get':function(){return this['_nodeAttached'];},'set':function(_0x52c17e){this['_meshAttached']=null,this['_nodeAttached']=_0x52c17e,this['_checkBillboardTransform'](),[this['xGizmo'],this['yGizmo'],this['zGizmo']]['forEach'](function(_0x479e77){_0x479e77['isEnabled']?_0x479e77['attachedNode']=_0x52c17e:_0x479e77['attachedNode']=null;});},'enumerable':!0x1,'configurable':!0x0}),_0x3a3d9f['prototype']['_checkBillboardTransform']=function(){this['_nodeAttached']&&this['_nodeAttached']['billboardMode']&&console['log']('Rotation\x20Gizmo\x20will\x20not\x20work\x20with\x20transforms\x20in\x20billboard\x20mode.');},Object['defineProperty'](_0x3a3d9f['prototype'],'isHovered',{'get':function(){var _0x69eb79=!0x1;return[this['xGizmo'],this['yGizmo'],this['zGizmo']]['forEach'](function(_0x688669){_0x69eb79=_0x69eb79||_0x688669['isHovered'];}),_0x69eb79;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3a3d9f['prototype'],'updateGizmoRotationToMatchAttachedMesh',{'get':function(){return this['xGizmo']['updateGizmoRotationToMatchAttachedMesh'];},'set':function(_0x4e639e){this['xGizmo']&&(this['xGizmo']['updateGizmoRotationToMatchAttachedMesh']=_0x4e639e,this['yGizmo']['updateGizmoRotationToMatchAttachedMesh']=_0x4e639e,this['zGizmo']['updateGizmoRotationToMatchAttachedMesh']=_0x4e639e);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3a3d9f['prototype'],'snapDistance',{'get':function(){return this['xGizmo']['snapDistance'];},'set':function(_0x55998e){this['xGizmo']&&(this['xGizmo']['snapDistance']=_0x55998e,this['yGizmo']['snapDistance']=_0x55998e,this['zGizmo']['snapDistance']=_0x55998e);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3a3d9f['prototype'],'scaleRatio',{'get':function(){return this['xGizmo']['scaleRatio'];},'set':function(_0x7836a2){this['xGizmo']&&(this['xGizmo']['scaleRatio']=_0x7836a2,this['yGizmo']['scaleRatio']=_0x7836a2,this['zGizmo']['scaleRatio']=_0x7836a2);},'enumerable':!0x1,'configurable':!0x0}),_0x3a3d9f['prototype']['addToAxisCache']=function(_0x35a56f,_0x29c73c){this['_gizmoAxisCache']['set'](_0x35a56f,_0x29c73c);},_0x3a3d9f['prototype']['dispose']=function(){var _0x2df82c=this;this['xGizmo']['dispose'](),this['yGizmo']['dispose'](),this['zGizmo']['dispose'](),this['onDragStartObservable']['clear'](),this['onDragEndObservable']['clear'](),this['_observables']['forEach'](function(_0xd735a9){_0x2df82c['gizmoLayer']['utilityLayerScene']['onPointerObservable']['remove'](_0xd735a9);});},_0x3a3d9f['prototype']['setCustomMesh']=function(_0x10f345){_0x75193d['a']['Error']('Custom\x20meshes\x20are\x20not\x20supported\x20on\x20this\x20gizmo,\x20please\x20set\x20the\x20custom\x20meshes\x20on\x20the\x20gizmos\x20contained\x20within\x20this\x20one\x20(gizmo.xGizmo,\x20gizmo.yGizmo,\x20gizmo.zGizmo)');},_0x3a3d9f;}(_0x417dc8['a']),_0x200669=_0x162675(0x2e),_0xd22a68=_0x162675(0x54),_0x371e63=function(_0x36cebf){function _0x3c0de7(_0x5cb64d,_0xd6ef07,_0x56e214,_0x1944f0){var _0x23e3e6;void 0x0===_0xd6ef07&&(_0xd6ef07=_0x39310d['a']['Gray']()),void 0x0===_0x56e214&&(_0x56e214=_0x539118['a']['DefaultUtilityLayer']),void 0x0===_0x1944f0&&(_0x1944f0=null);var _0x111e62=_0x36cebf['call'](this,_0x56e214)||this;_0x111e62['_pointerObserver']=null,_0x111e62['snapDistance']=0x0,_0x111e62['onSnapObservable']=new _0x6ac1f7['c'](),_0x111e62['_isEnabled']=!0x1,_0x111e62['_parent']=null,_0x111e62['_dragging']=!0x1,_0x111e62['_parent']=_0x1944f0,_0x111e62['_coloredMaterial']=new _0x5905ab['a']('',_0x56e214['utilityLayerScene']),_0x111e62['_coloredMaterial']['diffuseColor']=_0xd6ef07,_0x111e62['_coloredMaterial']['specularColor']=_0xd6ef07['subtract'](new _0x39310d['a'](0.1,0.1,0.1)),_0x111e62['_hoverMaterial']=new _0x5905ab['a']('',_0x56e214['utilityLayerScene']),_0x111e62['_hoverMaterial']['diffuseColor']=_0x39310d['a']['Yellow'](),_0x111e62['_disableMaterial']=new _0x5905ab['a']('',_0x56e214['utilityLayerScene']),_0x111e62['_disableMaterial']['diffuseColor']=_0x39310d['a']['Gray'](),_0x111e62['_disableMaterial']['alpha']=0.4,_0x111e62['_gizmoMesh']=_0x3c0de7['_CreatePlane'](_0x56e214['utilityLayerScene'],_0x111e62['_coloredMaterial']),_0x111e62['_gizmoMesh']['lookAt'](_0x111e62['_rootMesh']['position']['add'](_0x5cb64d)),_0x111e62['_gizmoMesh']['scaling']['scaleInPlace'](0x1/0x3),_0x111e62['_gizmoMesh']['parent']=_0x111e62['_rootMesh'];var _0x4de91a=0x0,_0x7b6b5c=new _0x74d525['e'](),_0x15499d={'snapDistance':0x0};_0x111e62['dragBehavior']=new _0x356c6d['a']({'dragPlaneNormal':_0x5cb64d}),_0x111e62['dragBehavior']['moveAttached']=!0x1,_0x111e62['_rootMesh']['addBehavior'](_0x111e62['dragBehavior']),_0x111e62['dragBehavior']['onDragObservable']['add'](function(_0x126ef6){if(_0x111e62['attachedNode']){if(0x0==_0x111e62['snapDistance'])_0x111e62['attachedNode']['getWorldMatrix']()['addTranslationFromFloats'](_0x126ef6['delta']['x'],_0x126ef6['delta']['y'],_0x126ef6['delta']['z']);else{if(_0x4de91a+=_0x126ef6['dragDistance'],Math['abs'](_0x4de91a)>_0x111e62['snapDistance']){var _0x378535=Math['floor'](Math['abs'](_0x4de91a)/_0x111e62['snapDistance']);_0x4de91a%=_0x111e62['snapDistance'],_0x126ef6['delta']['normalizeToRef'](_0x7b6b5c),_0x7b6b5c['scaleInPlace'](_0x111e62['snapDistance']*_0x378535),_0x111e62['attachedNode']['getWorldMatrix']()['addTranslationFromFloats'](_0x7b6b5c['x'],_0x7b6b5c['y'],_0x7b6b5c['z']),_0x15499d['snapDistance']=_0x111e62['snapDistance']*_0x378535,_0x111e62['onSnapObservable']['notifyObservers'](_0x15499d);}}_0x111e62['_matrixChanged']();}}),_0x111e62['dragBehavior']['onDragStartObservable']['add'](function(){_0x111e62['_dragging']=!0x0;}),_0x111e62['dragBehavior']['onDragEndObservable']['add'](function(){_0x111e62['_dragging']=!0x1;});var _0x163d64=_0x56e214['_getSharedGizmoLight']();_0x163d64['includedOnlyMeshes']=_0x163d64['includedOnlyMeshes']['concat'](_0x111e62['_rootMesh']['getChildMeshes'](!0x1));var _0x1285da={'gizmoMeshes':_0x111e62['_gizmoMesh']['getChildMeshes'](),'colliderMeshes':_0x111e62['_gizmoMesh']['getChildMeshes'](),'material':_0x111e62['_coloredMaterial'],'hoverMaterial':_0x111e62['_hoverMaterial'],'disableMaterial':_0x111e62['_disableMaterial'],'active':!0x1};return null===(_0x23e3e6=_0x111e62['_parent'])||void 0x0===_0x23e3e6||_0x23e3e6['addToAxisCache'](_0x111e62['_gizmoMesh'],_0x1285da),_0x111e62['_pointerObserver']=_0x56e214['utilityLayerScene']['onPointerObservable']['add'](function(_0xd2ef07){var _0x5618e7;if(!_0x111e62['_customMeshSet']&&(_0x111e62['_isHovered']=!(-0x1==_0x1285da['colliderMeshes']['indexOf'](null===(_0x5618e7=null==_0xd2ef07?void 0x0:_0xd2ef07['pickInfo'])||void 0x0===_0x5618e7?void 0x0:_0x5618e7['pickedMesh'])),!_0x111e62['_parent'])){var _0x9e557b=_0x111e62['_isHovered']||_0x111e62['_dragging']?_0x111e62['_hoverMaterial']:_0x111e62['_coloredMaterial'];_0x1285da['gizmoMeshes']['forEach'](function(_0x9f5a3d){_0x9f5a3d['material']=_0x9e557b;});}}),_0x111e62;}return Object(_0x18e13d['d'])(_0x3c0de7,_0x36cebf),_0x3c0de7['_CreatePlane']=function(_0x2dbeb8,_0x1971e9){var _0x287cdd=new _0x200669['a']('plane',_0x2dbeb8),_0x18bf7a=_0xd22a68['a']['CreatePlane']('dragPlane',{'width':0.1375,'height':0.1375,'sideOrientation':0x2},_0x2dbeb8);return _0x18bf7a['material']=_0x1971e9,_0x18bf7a['parent']=_0x287cdd,_0x287cdd;},_0x3c0de7['prototype']['_attachedNodeChanged']=function(_0x43deee){this['dragBehavior']&&(this['dragBehavior']['enabled']=!!_0x43deee);},Object['defineProperty'](_0x3c0de7['prototype'],'isEnabled',{'get':function(){return this['_isEnabled'];},'set':function(_0x2851bb){this['_isEnabled']=_0x2851bb,_0x2851bb?this['_parent']&&(this['attachedNode']=this['_parent']['attachedNode']):this['attachedNode']=null;},'enumerable':!0x1,'configurable':!0x0}),_0x3c0de7['prototype']['dispose']=function(){this['onSnapObservable']['clear'](),this['gizmoLayer']['utilityLayerScene']['onPointerObservable']['remove'](this['_pointerObserver']),this['dragBehavior']['detach'](),_0x36cebf['prototype']['dispose']['call'](this),this['_gizmoMesh']&&this['_gizmoMesh']['dispose'](),[this['_coloredMaterial'],this['_hoverMaterial'],this['_disableMaterial']]['forEach'](function(_0x3c0446){_0x3c0446&&_0x3c0446['dispose']();});},_0x3c0de7;}(_0x417dc8['a']),_0xccbb24=function(_0x256770){function _0x114a2a(_0x46ab75,_0x44202f,_0x345cf5){void 0x0===_0x46ab75&&(_0x46ab75=_0x539118['a']['DefaultUtilityLayer']),void 0x0===_0x44202f&&(_0x44202f=0x1);var _0x3936a3=_0x256770['call'](this,_0x46ab75)||this;return _0x3936a3['_meshAttached']=null,_0x3936a3['_nodeAttached']=null,_0x3936a3['_observables']=[],_0x3936a3['_gizmoAxisCache']=new Map(),_0x3936a3['onDragStartObservable']=new _0x6ac1f7['c'](),_0x3936a3['onDragEndObservable']=new _0x6ac1f7['c'](),_0x3936a3['_planarGizmoEnabled']=!0x1,_0x3936a3['xGizmo']=new _0x1b97f2['a'](new _0x74d525['e'](0x1,0x0,0x0),_0x39310d['a']['Red']()['scale'](0.5),_0x46ab75,_0x3936a3,_0x44202f),_0x3936a3['yGizmo']=new _0x1b97f2['a'](new _0x74d525['e'](0x0,0x1,0x0),_0x39310d['a']['Green']()['scale'](0.5),_0x46ab75,_0x3936a3,_0x44202f),_0x3936a3['zGizmo']=new _0x1b97f2['a'](new _0x74d525['e'](0x0,0x0,0x1),_0x39310d['a']['Blue']()['scale'](0.5),_0x46ab75,_0x3936a3,_0x44202f),_0x3936a3['xPlaneGizmo']=new _0x371e63(new _0x74d525['e'](0x1,0x0,0x0),_0x39310d['a']['Red']()['scale'](0.5),_0x3936a3['gizmoLayer'],_0x3936a3),_0x3936a3['yPlaneGizmo']=new _0x371e63(new _0x74d525['e'](0x0,0x1,0x0),_0x39310d['a']['Green']()['scale'](0.5),_0x3936a3['gizmoLayer'],_0x3936a3),_0x3936a3['zPlaneGizmo']=new _0x371e63(new _0x74d525['e'](0x0,0x0,0x1),_0x39310d['a']['Blue']()['scale'](0.5),_0x3936a3['gizmoLayer'],_0x3936a3),[_0x3936a3['xGizmo'],_0x3936a3['yGizmo'],_0x3936a3['zGizmo'],_0x3936a3['xPlaneGizmo'],_0x3936a3['yPlaneGizmo'],_0x3936a3['zPlaneGizmo']]['forEach'](function(_0x2604c5){_0x2604c5['dragBehavior']['onDragStartObservable']['add'](function(){_0x3936a3['onDragStartObservable']['notifyObservers']({});}),_0x2604c5['dragBehavior']['onDragEndObservable']['add'](function(){_0x3936a3['onDragEndObservable']['notifyObservers']({});});}),_0x3936a3['attachedMesh']=null,_0x345cf5?_0x345cf5['addToAxisCache'](_0x3936a3['_gizmoAxisCache']):_0x417dc8['a']['GizmoAxisPointerObserver'](_0x46ab75,_0x3936a3['_gizmoAxisCache']),_0x3936a3;}return Object(_0x18e13d['d'])(_0x114a2a,_0x256770),Object['defineProperty'](_0x114a2a['prototype'],'attachedMesh',{'get':function(){return this['_meshAttached'];},'set':function(_0x555cbc){this['_meshAttached']=_0x555cbc,this['_nodeAttached']=_0x555cbc,[this['xGizmo'],this['yGizmo'],this['zGizmo'],this['xPlaneGizmo'],this['yPlaneGizmo'],this['zPlaneGizmo']]['forEach'](function(_0x2e324d){_0x2e324d['isEnabled']?_0x2e324d['attachedMesh']=_0x555cbc:_0x2e324d['attachedMesh']=null;});},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x114a2a['prototype'],'attachedNode',{'get':function(){return this['_nodeAttached'];},'set':function(_0x1918fc){this['_meshAttached']=null,this['_nodeAttached']=null,[this['xGizmo'],this['yGizmo'],this['zGizmo'],this['xPlaneGizmo'],this['yPlaneGizmo'],this['zPlaneGizmo']]['forEach'](function(_0xdbabdb){_0xdbabdb['isEnabled']?_0xdbabdb['attachedNode']=_0x1918fc:_0xdbabdb['attachedNode']=null;});},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x114a2a['prototype'],'isHovered',{'get':function(){var _0x1c515f=!0x1;return[this['xGizmo'],this['yGizmo'],this['zGizmo'],this['xPlaneGizmo'],this['yPlaneGizmo'],this['zPlaneGizmo']]['forEach'](function(_0x385aaf){_0x1c515f=_0x1c515f||_0x385aaf['isHovered'];}),_0x1c515f;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x114a2a['prototype'],'planarGizmoEnabled',{'get':function(){return this['_planarGizmoEnabled'];},'set':function(_0x3b78b8){var _0x41f3d9=this;this['_planarGizmoEnabled']=_0x3b78b8,[this['xPlaneGizmo'],this['yPlaneGizmo'],this['zPlaneGizmo']]['forEach'](function(_0x2f29ea){_0x2f29ea&&(_0x2f29ea['isEnabled']=_0x3b78b8,_0x3b78b8&&(_0x2f29ea['attachedMesh']?_0x2f29ea['attachedMesh']=_0x41f3d9['attachedMesh']:_0x2f29ea['attachedNode']=_0x41f3d9['attachedNode']));},this);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x114a2a['prototype'],'updateGizmoRotationToMatchAttachedMesh',{'get':function(){return this['_updateGizmoRotationToMatchAttachedMesh'];},'set':function(_0x49ced7){this['_updateGizmoRotationToMatchAttachedMesh']=_0x49ced7,[this['xGizmo'],this['yGizmo'],this['zGizmo'],this['xPlaneGizmo'],this['yPlaneGizmo'],this['zPlaneGizmo']]['forEach'](function(_0x35a4e4){_0x35a4e4&&(_0x35a4e4['updateGizmoRotationToMatchAttachedMesh']=_0x49ced7);});},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x114a2a['prototype'],'snapDistance',{'get':function(){return this['_snapDistance'];},'set':function(_0x1d59c8){this['_snapDistance']=_0x1d59c8,[this['xGizmo'],this['yGizmo'],this['zGizmo'],this['xPlaneGizmo'],this['yPlaneGizmo'],this['zPlaneGizmo']]['forEach'](function(_0x15f107){_0x15f107&&(_0x15f107['snapDistance']=_0x1d59c8);});},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x114a2a['prototype'],'scaleRatio',{'get':function(){return this['_scaleRatio'];},'set':function(_0x5533be){this['_scaleRatio']=_0x5533be,[this['xGizmo'],this['yGizmo'],this['zGizmo'],this['xPlaneGizmo'],this['yPlaneGizmo'],this['zPlaneGizmo']]['forEach'](function(_0x22b87d){_0x22b87d&&(_0x22b87d['scaleRatio']=_0x5533be);});},'enumerable':!0x1,'configurable':!0x0}),_0x114a2a['prototype']['addToAxisCache']=function(_0x3bbe62,_0x6ee926){this['_gizmoAxisCache']['set'](_0x3bbe62,_0x6ee926);},_0x114a2a['prototype']['dispose']=function(){var _0x4e3509=this;[this['xGizmo'],this['yGizmo'],this['zGizmo'],this['xPlaneGizmo'],this['yPlaneGizmo'],this['zPlaneGizmo']]['forEach'](function(_0x252655){_0x252655&&_0x252655['dispose']();}),this['_observables']['forEach'](function(_0x505b69){_0x4e3509['gizmoLayer']['utilityLayerScene']['onPointerObservable']['remove'](_0x505b69);}),this['onDragStartObservable']['clear'](),this['onDragEndObservable']['clear']();},_0x114a2a['prototype']['setCustomMesh']=function(_0x1f91ea){_0x75193d['a']['Error']('Custom\x20meshes\x20are\x20not\x20supported\x20on\x20this\x20gizmo,\x20please\x20set\x20the\x20custom\x20meshes\x20on\x20the\x20gizmos\x20contained\x20within\x20this\x20one\x20(gizmo.xGizmo,\x20gizmo.yGizmo,\x20gizmo.zGizmo,gizmo.xPlaneGizmo,\x20gizmo.yPlaneGizmo,\x20gizmo.zPlaneGizmo)');},_0x114a2a;}(_0x417dc8['a']);_0xa18063['a']['CreatePolyhedron']=function(_0x16cc58){var _0x54e26a=[];_0x54e26a[0x0]={'vertex':[[0x0,0x0,1.732051],[1.632993,0x0,-0.5773503],[-0.8164966,1.414214,-0.5773503],[-0.8164966,-1.414214,-0.5773503]],'face':[[0x0,0x1,0x2],[0x0,0x2,0x3],[0x0,0x3,0x1],[0x1,0x3,0x2]]},_0x54e26a[0x1]={'vertex':[[0x0,0x0,1.414214],[1.414214,0x0,0x0],[0x0,1.414214,0x0],[-1.414214,0x0,0x0],[0x0,-1.414214,0x0],[0x0,0x0,-1.414214]],'face':[[0x0,0x1,0x2],[0x0,0x2,0x3],[0x0,0x3,0x4],[0x0,0x4,0x1],[0x1,0x4,0x5],[0x1,0x5,0x2],[0x2,0x5,0x3],[0x3,0x5,0x4]]},_0x54e26a[0x2]={'vertex':[[0x0,0x0,1.070466],[0.7136442,0x0,0.7978784],[-0.3568221,0.618034,0.7978784],[-0.3568221,-0.618034,0.7978784],[0.7978784,0.618034,0.3568221],[0.7978784,-0.618034,0.3568221],[-0.9341724,0.381966,0.3568221],[0.1362939,0x1,0.3568221],[0.1362939,-0x1,0.3568221],[-0.9341724,-0.381966,0.3568221],[0.9341724,0.381966,-0.3568221],[0.9341724,-0.381966,-0.3568221],[-0.7978784,0.618034,-0.3568221],[-0.1362939,0x1,-0.3568221],[-0.1362939,-0x1,-0.3568221],[-0.7978784,-0.618034,-0.3568221],[0.3568221,0.618034,-0.7978784],[0.3568221,-0.618034,-0.7978784],[-0.7136442,0x0,-0.7978784],[0x0,0x0,-1.070466]],'face':[[0x0,0x1,0x4,0x7,0x2],[0x0,0x2,0x6,0x9,0x3],[0x0,0x3,0x8,0x5,0x1],[0x1,0x5,0xb,0xa,0x4],[0x2,0x7,0xd,0xc,0x6],[0x3,0x9,0xf,0xe,0x8],[0x4,0xa,0x10,0xd,0x7],[0x5,0x8,0xe,0x11,0xb],[0x6,0xc,0x12,0xf,0x9],[0xa,0xb,0x11,0x13,0x10],[0xc,0xd,0x10,0x13,0x12],[0xe,0xf,0x12,0x13,0x11]]},_0x54e26a[0x3]={'vertex':[[0x0,0x0,1.175571],[1.051462,0x0,0.5257311],[0.3249197,0x1,0.5257311],[-0.8506508,0.618034,0.5257311],[-0.8506508,-0.618034,0.5257311],[0.3249197,-0x1,0.5257311],[0.8506508,0.618034,-0.5257311],[0.8506508,-0.618034,-0.5257311],[-0.3249197,0x1,-0.5257311],[-1.051462,0x0,-0.5257311],[-0.3249197,-0x1,-0.5257311],[0x0,0x0,-1.175571]],'face':[[0x0,0x1,0x2],[0x0,0x2,0x3],[0x0,0x3,0x4],[0x0,0x4,0x5],[0x0,0x5,0x1],[0x1,0x5,0x7],[0x1,0x7,0x6],[0x1,0x6,0x2],[0x2,0x6,0x8],[0x2,0x8,0x3],[0x3,0x8,0x9],[0x3,0x9,0x4],[0x4,0x9,0xa],[0x4,0xa,0x5],[0x5,0xa,0x7],[0x6,0x7,0xb],[0x6,0xb,0x8],[0x7,0xa,0xb],[0x8,0xb,0x9],[0x9,0xb,0xa]]},_0x54e26a[0x4]={'vertex':[[0x0,0x0,1.070722],[0.7148135,0x0,0.7971752],[-0.104682,0.7071068,0.7971752],[-0.6841528,0.2071068,0.7971752],[-0.104682,-0.7071068,0.7971752],[0.6101315,0.7071068,0.5236279],[1.04156,0.2071068,0.1367736],[0.6101315,-0.7071068,0.5236279],[-0.3574067,0x1,0.1367736],[-0.7888348,-0.5,0.5236279],[-0.9368776,0.5,0.1367736],[-0.3574067,-0x1,0.1367736],[0.3574067,0x1,-0.1367736],[0.9368776,-0.5,-0.1367736],[0.7888348,0.5,-0.5236279],[0.3574067,-0x1,-0.1367736],[-0.6101315,0.7071068,-0.5236279],[-1.04156,-0.2071068,-0.1367736],[-0.6101315,-0.7071068,-0.5236279],[0.104682,0.7071068,-0.7971752],[0.6841528,-0.2071068,-0.7971752],[0.104682,-0.7071068,-0.7971752],[-0.7148135,0x0,-0.7971752],[0x0,0x0,-1.070722]],'face':[[0x0,0x2,0x3],[0x1,0x6,0x5],[0x4,0x9,0xb],[0x7,0xf,0xd],[0x8,0x10,0xa],[0xc,0xe,0x13],[0x11,0x16,0x12],[0x14,0x15,0x17],[0x0,0x1,0x5,0x2],[0x0,0x3,0x9,0x4],[0x0,0x4,0x7,0x1],[0x1,0x7,0xd,0x6],[0x2,0x5,0xc,0x8],[0x2,0x8,0xa,0x3],[0x3,0xa,0x11,0x9],[0x4,0xb,0xf,0x7],[0x5,0x6,0xe,0xc],[0x6,0xd,0x14,0xe],[0x8,0xc,0x13,0x10],[0x9,0x11,0x12,0xb],[0xa,0x10,0x16,0x11],[0xb,0x12,0x15,0xf],[0xd,0xf,0x15,0x14],[0xe,0x14,0x17,0x13],[0x10,0x13,0x17,0x16],[0x12,0x16,0x17,0x15]]},_0x54e26a[0x5]={'vertex':[[0x0,0x0,1.322876],[1.309307,0x0,0.1889822],[-0.9819805,0.8660254,0.1889822],[0.1636634,-1.299038,0.1889822],[0.3273268,0.8660254,-0.9449112],[-0.8183171,-0.4330127,-0.9449112]],'face':[[0x0,0x3,0x1],[0x2,0x4,0x5],[0x0,0x1,0x4,0x2],[0x0,0x2,0x5,0x3],[0x1,0x3,0x5,0x4]]},_0x54e26a[0x6]={'vertex':[[0x0,0x0,1.159953],[1.013464,0x0,0.5642542],[-0.3501431,0.9510565,0.5642542],[-0.7715208,-0.6571639,0.5642542],[0.6633206,0.9510565,-0.03144481],[0.8682979,-0.6571639,-0.3996071],[-1.121664,0.2938926,-0.03144481],[-0.2348831,-1.063314,-0.3996071],[0.5181548,0.2938926,-0.9953061],[-0.5850262,-0.112257,-0.9953061]],'face':[[0x0,0x1,0x4,0x2],[0x0,0x2,0x6,0x3],[0x1,0x5,0x8,0x4],[0x3,0x6,0x9,0x7],[0x5,0x7,0x9,0x8],[0x0,0x3,0x7,0x5,0x1],[0x2,0x4,0x8,0x9,0x6]]},_0x54e26a[0x7]={'vertex':[[0x0,0x0,1.118034],[0.8944272,0x0,0.6708204],[-0.2236068,0.8660254,0.6708204],[-0.7826238,-0.4330127,0.6708204],[0.6708204,0.8660254,0.2236068],[1.006231,-0.4330127,-0.2236068],[-1.006231,0.4330127,0.2236068],[-0.6708204,-0.8660254,-0.2236068],[0.7826238,0.4330127,-0.6708204],[0.2236068,-0.8660254,-0.6708204],[-0.8944272,0x0,-0.6708204],[0x0,0x0,-1.118034]],'face':[[0x0,0x1,0x4,0x2],[0x0,0x2,0x6,0x3],[0x1,0x5,0x8,0x4],[0x3,0x6,0xa,0x7],[0x5,0x9,0xb,0x8],[0x7,0xa,0xb,0x9],[0x0,0x3,0x7,0x9,0x5,0x1],[0x2,0x4,0x8,0xb,0xa,0x6]]},_0x54e26a[0x8]={'vertex':[[-0.729665,0.670121,0.319155],[-0.655235,-0.29213,-0.754096],[-0.093922,-0.607123,0.537818],[0.702196,0.595691,0.485187],[0.776626,-0.36656,-0.588064]],'face':[[0x1,0x4,0x2],[0x0,0x1,0x2],[0x3,0x0,0x2],[0x4,0x3,0x2],[0x4,0x1,0x0,0x3]]},_0x54e26a[0x9]={'vertex':[[-0.868849,-0.100041,0.61257],[-0.329458,0.976099,0.28078],[-0.26629,-0.013796,-0.477654],[-0.13392,-1.034115,0.229829],[0.738834,0.707117,-0.307018],[0.859683,-0.535264,-0.338508]],'face':[[0x3,0x0,0x2],[0x5,0x3,0x2],[0x4,0x5,0x2],[0x1,0x4,0x2],[0x0,0x1,0x2],[0x0,0x3,0x5,0x4,0x1]]},_0x54e26a[0xa]={'vertex':[[-0.610389,0.243975,0.531213],[-0.187812,-0.48795,-0.664016],[-0.187812,0.9759,-0.664016],[0.187812,-0.9759,0.664016],[0.798201,0.243975,0.132803]],'face':[[0x1,0x3,0x0],[0x3,0x4,0x0],[0x3,0x1,0x4],[0x0,0x2,0x1],[0x0,0x4,0x2],[0x2,0x4,0x1]]},_0x54e26a[0xb]={'vertex':[[-1.028778,0.392027,-0.048786],[-0.640503,-0.646161,0.621837],[-0.125162,-0.395663,-0.540059],[0.004683,0.888447,-0.651988],[0.125161,0.395663,0.540059],[0.632925,-0.791376,0.433102],[1.031672,0.157063,-0.354165]],'face':[[0x3,0x2,0x0],[0x2,0x1,0x0],[0x2,0x5,0x1],[0x0,0x4,0x3],[0x0,0x1,0x4],[0x4,0x1,0x5],[0x2,0x3,0x6],[0x3,0x4,0x6],[0x5,0x2,0x6],[0x4,0x5,0x6]]},_0x54e26a[0xc]={'vertex':[[-0.669867,0.334933,-0.529576],[-0.669867,0.334933,0.529577],[-0.4043,1.212901,0x0],[-0.334933,-0.669867,-0.529576],[-0.334933,-0.669867,0.529577],[0.334933,0.669867,-0.529576],[0.334933,0.669867,0.529577],[0.4043,-1.212901,0x0],[0.669867,-0.334933,-0.529576],[0.669867,-0.334933,0.529577]],'face':[[0x8,0x9,0x7],[0x6,0x5,0x2],[0x3,0x8,0x7],[0x5,0x0,0x2],[0x4,0x3,0x7],[0x0,0x1,0x2],[0x9,0x4,0x7],[0x1,0x6,0x2],[0x9,0x8,0x5,0x6],[0x8,0x3,0x0,0x5],[0x3,0x4,0x1,0x0],[0x4,0x9,0x6,0x1]]},_0x54e26a[0xd]={'vertex':[[-0.931836,0.219976,-0.264632],[-0.636706,0.318353,0.692816],[-0.613483,-0.735083,-0.264632],[-0.326545,0.979634,0x0],[-0.318353,-0.636706,0.692816],[-0.159176,0.477529,-0.856368],[0.159176,-0.477529,-0.856368],[0.318353,0.636706,0.692816],[0.326545,-0.979634,0x0],[0.613482,0.735082,-0.264632],[0.636706,-0.318353,0.692816],[0.931835,-0.219977,-0.264632]],'face':[[0xb,0xa,0x8],[0x7,0x9,0x3],[0x6,0xb,0x8],[0x9,0x5,0x3],[0x2,0x6,0x8],[0x5,0x0,0x3],[0x4,0x2,0x8],[0x0,0x1,0x3],[0xa,0x4,0x8],[0x1,0x7,0x3],[0xa,0xb,0x9,0x7],[0xb,0x6,0x5,0x9],[0x6,0x2,0x0,0x5],[0x2,0x4,0x1,0x0],[0x4,0xa,0x7,0x1]]},_0x54e26a[0xe]={'vertex':[[-0.93465,0.300459,-0.271185],[-0.838689,-0.260219,-0.516017],[-0.711319,0.717591,0.128359],[-0.710334,-0.156922,0.080946],[-0.599799,0.556003,-0.725148],[-0.503838,-0.004675,-0.969981],[-0.487004,0.26021,0.48049],[-0.460089,-0.750282,-0.512622],[-0.376468,0.973135,-0.325605],[-0.331735,-0.646985,0.084342],[-0.254001,0.831847,0.530001],[-0.125239,-0.494738,-0.966586],[0.029622,0.027949,0.730817],[0.056536,-0.982543,-0.262295],[0.08085,1.087391,0.076037],[0.125583,-0.532729,0.485984],[0.262625,0.599586,0.780328],[0.391387,-0.726999,-0.716259],[0.513854,-0.868287,0.139347],[0.597475,0.85513,0.326364],[0.641224,0.109523,0.783723],[0.737185,-0.451155,0.538891],[0.848705,-0.612742,-0.314616],[0.976075,0.365067,0.32976],[1.072036,-0.19561,0.084927]],'face':[[0xf,0x12,0x15],[0xc,0x14,0x10],[0x6,0xa,0x2],[0x3,0x0,0x1],[0x9,0x7,0xd],[0x2,0x8,0x4,0x0],[0x0,0x4,0x5,0x1],[0x1,0x5,0xb,0x7],[0x7,0xb,0x11,0xd],[0xd,0x11,0x16,0x12],[0x12,0x16,0x18,0x15],[0x15,0x18,0x17,0x14],[0x14,0x17,0x13,0x10],[0x10,0x13,0xe,0xa],[0xa,0xe,0x8,0x2],[0xf,0x9,0xd,0x12],[0xc,0xf,0x15,0x14],[0x6,0xc,0x10,0xa],[0x3,0x6,0x2,0x0],[0x9,0x3,0x1,0x7],[0x9,0xf,0xc,0x6,0x3],[0x16,0x11,0xb,0x5,0x4,0x8,0xe,0x13,0x17,0x18]]};var _0x38f8fe,_0x28a52d,_0x47205b,_0x4ee1c1,_0x3bbd22,_0x52e10d,_0x23dd08=_0x16cc58['type']&&(_0x16cc58['type']<0x0||_0x16cc58['type']>=_0x54e26a['length'])?0x0:_0x16cc58['type']||0x0,_0x48a912=_0x16cc58['size'],_0x409131=_0x16cc58['sizeX']||_0x48a912||0x1,_0x354a78=_0x16cc58['sizeY']||_0x48a912||0x1,_0x599a6b=_0x16cc58['sizeZ']||_0x48a912||0x1,_0x7fafad=_0x16cc58['custom']||_0x54e26a[_0x23dd08],_0x4f7f58=_0x7fafad['face']['length'],_0x2a021b=_0x16cc58['faceUV']||new Array(_0x4f7f58),_0x2c2077=_0x16cc58['faceColors'],_0x2039b2=void 0x0===_0x16cc58['flat']||_0x16cc58['flat'],_0x3f559a=0x0===_0x16cc58['sideOrientation']?0x0:_0x16cc58['sideOrientation']||_0xa18063['a']['DEFAULTSIDE'],_0x3ac262=new Array(),_0x3ae3ae=new Array(),_0x14eb1a=new Array(),_0x36b7e2=new Array(),_0x1ccddc=new Array(),_0x7603c=0x0,_0xfb4db6=0x0,_0x1a885e=new Array(),_0x52a86b=0x0,_0x5cda6d=0x0;if(_0x2039b2){for(_0x5cda6d=0x0;_0x5cda6d<_0x4f7f58;_0x5cda6d++)_0x2c2077&&void 0x0===_0x2c2077[_0x5cda6d]&&(_0x2c2077[_0x5cda6d]=new _0x39310d['b'](0x1,0x1,0x1,0x1)),_0x2a021b&&void 0x0===_0x2a021b[_0x5cda6d]&&(_0x2a021b[_0x5cda6d]=new _0x74d525['f'](0x0,0x0,0x1,0x1));}if(_0x2039b2)for(_0x5cda6d=0x0;_0x5cda6d<_0x4f7f58;_0x5cda6d++){var _0x51c792=_0x7fafad['face'][_0x5cda6d]['length'];for(_0x47205b=0x2*Math['PI']/_0x51c792,_0x4ee1c1=0.5*Math['tan'](_0x47205b/0x2),_0x3bbd22=0.5,_0x52a86b=0x0;_0x52a86b<_0x51c792;_0x52a86b++)_0x3ac262['push'](_0x7fafad['vertex'][_0x7fafad['face'][_0x5cda6d][_0x52a86b]][0x0]*_0x409131,_0x7fafad['vertex'][_0x7fafad['face'][_0x5cda6d][_0x52a86b]][0x1]*_0x354a78,_0x7fafad['vertex'][_0x7fafad['face'][_0x5cda6d][_0x52a86b]][0x2]*_0x599a6b),_0x1a885e['push'](_0x7603c),_0x7603c++,_0x38f8fe=_0x2a021b[_0x5cda6d]['x']+(_0x2a021b[_0x5cda6d]['z']-_0x2a021b[_0x5cda6d]['x'])*(0.5+_0x4ee1c1),_0x28a52d=_0x2a021b[_0x5cda6d]['y']+(_0x2a021b[_0x5cda6d]['w']-_0x2a021b[_0x5cda6d]['y'])*(_0x3bbd22-0.5),_0x36b7e2['push'](_0x38f8fe,_0x28a52d),_0x52e10d=_0x4ee1c1*Math['cos'](_0x47205b)-_0x3bbd22*Math['sin'](_0x47205b),_0x3bbd22=_0x4ee1c1*Math['sin'](_0x47205b)+_0x3bbd22*Math['cos'](_0x47205b),_0x4ee1c1=_0x52e10d,_0x2c2077&&_0x1ccddc['push'](_0x2c2077[_0x5cda6d]['r'],_0x2c2077[_0x5cda6d]['g'],_0x2c2077[_0x5cda6d]['b'],_0x2c2077[_0x5cda6d]['a']);for(_0x52a86b=0x0;_0x52a86b<_0x51c792-0x2;_0x52a86b++)_0x3ae3ae['push'](_0x1a885e[0x0+_0xfb4db6],_0x1a885e[_0x52a86b+0x2+_0xfb4db6],_0x1a885e[_0x52a86b+0x1+_0xfb4db6]);_0xfb4db6+=_0x51c792;}else{for(_0x52a86b=0x0;_0x52a86b<_0x7fafad['vertex']['length'];_0x52a86b++)_0x3ac262['push'](_0x7fafad['vertex'][_0x52a86b][0x0]*_0x409131,_0x7fafad['vertex'][_0x52a86b][0x1]*_0x354a78,_0x7fafad['vertex'][_0x52a86b][0x2]*_0x599a6b),_0x36b7e2['push'](0x0,0x0);for(_0x5cda6d=0x0;_0x5cda6d<_0x4f7f58;_0x5cda6d++)for(_0x52a86b=0x0;_0x52a86b<_0x7fafad['face'][_0x5cda6d]['length']-0x2;_0x52a86b++)_0x3ae3ae['push'](_0x7fafad['face'][_0x5cda6d][0x0],_0x7fafad['face'][_0x5cda6d][_0x52a86b+0x2],_0x7fafad['face'][_0x5cda6d][_0x52a86b+0x1]);}_0xa18063['a']['ComputeNormals'](_0x3ac262,_0x3ae3ae,_0x14eb1a),_0xa18063['a']['_ComputeSides'](_0x3f559a,_0x3ac262,_0x3ae3ae,_0x14eb1a,_0x36b7e2,_0x16cc58['frontUVs'],_0x16cc58['backUVs']);var _0x1657da=new _0xa18063['a']();return _0x1657da['positions']=_0x3ac262,_0x1657da['indices']=_0x3ae3ae,_0x1657da['normals']=_0x14eb1a,_0x1657da['uvs']=_0x36b7e2,_0x2c2077&&_0x2039b2&&(_0x1657da['colors']=_0x1ccddc),_0x1657da;},_0x3cf5e5['a']['CreatePolyhedron']=function(_0x33be29,_0x4b2762,_0x4586c9){return _0x39b46b['CreatePolyhedron'](_0x33be29,_0x4b2762,_0x4586c9);};var _0x39b46b=(function(){function _0x348a27(){}return _0x348a27['CreatePolyhedron']=function(_0x24bdb3,_0xb2e5b8,_0xe94de8){void 0x0===_0xe94de8&&(_0xe94de8=null);var _0x2bf0e9=new _0x3cf5e5['a'](_0x24bdb3,_0xe94de8);return _0xb2e5b8['sideOrientation']=_0x3cf5e5['a']['_GetDefaultSideOrientation'](_0xb2e5b8['sideOrientation']),_0x2bf0e9['_originalBuilderSideOrientation']=_0xb2e5b8['sideOrientation'],_0xa18063['a']['CreatePolyhedron'](_0xb2e5b8)['applyToMesh'](_0x2bf0e9,_0xb2e5b8['updatable']),_0x2bf0e9;},_0x348a27;}()),_0x5e0e1f=function(_0x242a5c){function _0x3e7e40(_0x2724fd,_0x3e6fc2,_0x35cad1){void 0x0===_0x2724fd&&(_0x2724fd=_0x539118['a']['DefaultUtilityLayer']),void 0x0===_0x3e6fc2&&(_0x3e6fc2=0x1);var _0x3d260d=_0x242a5c['call'](this,_0x2724fd)||this;return _0x3d260d['_meshAttached']=null,_0x3d260d['_nodeAttached']=null,_0x3d260d['_sensitivity']=0x1,_0x3d260d['_observables']=[],_0x3d260d['_gizmoAxisCache']=new Map(),_0x3d260d['onDragStartObservable']=new _0x6ac1f7['c'](),_0x3d260d['onDragEndObservable']=new _0x6ac1f7['c'](),_0x3d260d['uniformScaleGizmo']=_0x3d260d['_createUniformScaleMesh'](),_0x3d260d['xGizmo']=new _0x1f64e7(new _0x74d525['e'](0x1,0x0,0x0),_0x39310d['a']['Red']()['scale'](0.5),_0x2724fd,_0x3d260d,_0x3e6fc2),_0x3d260d['yGizmo']=new _0x1f64e7(new _0x74d525['e'](0x0,0x1,0x0),_0x39310d['a']['Green']()['scale'](0.5),_0x2724fd,_0x3d260d,_0x3e6fc2),_0x3d260d['zGizmo']=new _0x1f64e7(new _0x74d525['e'](0x0,0x0,0x1),_0x39310d['a']['Blue']()['scale'](0.5),_0x2724fd,_0x3d260d,_0x3e6fc2),[_0x3d260d['xGizmo'],_0x3d260d['yGizmo'],_0x3d260d['zGizmo'],_0x3d260d['uniformScaleGizmo']]['forEach'](function(_0x9d0f4d){_0x9d0f4d['dragBehavior']['onDragStartObservable']['add'](function(){_0x3d260d['onDragStartObservable']['notifyObservers']({});}),_0x9d0f4d['dragBehavior']['onDragEndObservable']['add'](function(){_0x3d260d['onDragEndObservable']['notifyObservers']({});});}),_0x3d260d['attachedMesh']=null,_0x3d260d['attachedNode']=null,_0x35cad1?_0x35cad1['addToAxisCache'](_0x3d260d['_gizmoAxisCache']):_0x417dc8['a']['GizmoAxisPointerObserver'](_0x2724fd,_0x3d260d['_gizmoAxisCache']),_0x3d260d;}return Object(_0x18e13d['d'])(_0x3e7e40,_0x242a5c),Object['defineProperty'](_0x3e7e40['prototype'],'attachedMesh',{'get':function(){return this['_meshAttached'];},'set':function(_0x1e7a6c){this['_meshAttached']=_0x1e7a6c,this['_nodeAttached']=_0x1e7a6c,[this['xGizmo'],this['yGizmo'],this['zGizmo'],this['uniformScaleGizmo']]['forEach'](function(_0x2867e8){_0x2867e8['isEnabled']?_0x2867e8['attachedMesh']=_0x1e7a6c:_0x2867e8['attachedMesh']=null;});},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3e7e40['prototype'],'attachedNode',{'get':function(){return this['_nodeAttached'];},'set':function(_0x15a66f){this['_meshAttached']=null,this['_nodeAttached']=_0x15a66f,[this['xGizmo'],this['yGizmo'],this['zGizmo'],this['uniformScaleGizmo']]['forEach'](function(_0x56028a){_0x56028a['isEnabled']?_0x56028a['attachedNode']=_0x15a66f:_0x56028a['attachedNode']=null;});},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3e7e40['prototype'],'isHovered',{'get':function(){var _0x50243e=!0x1;return[this['xGizmo'],this['yGizmo'],this['zGizmo']]['forEach'](function(_0x1f4eb8){_0x50243e=_0x50243e||_0x1f4eb8['isHovered'];}),_0x50243e;},'enumerable':!0x1,'configurable':!0x0}),_0x3e7e40['prototype']['_createUniformScaleMesh']=function(){this['_coloredMaterial']=new _0x5905ab['a']('',this['gizmoLayer']['utilityLayerScene']),this['_coloredMaterial']['diffuseColor']=_0x39310d['a']['Gray'](),this['_hoverMaterial']=new _0x5905ab['a']('',this['gizmoLayer']['utilityLayerScene']),this['_hoverMaterial']['diffuseColor']=_0x39310d['a']['Yellow'](),this['_disableMaterial']=new _0x5905ab['a']('',this['gizmoLayer']['utilityLayerScene']),this['_disableMaterial']['diffuseColor']=_0x39310d['a']['Gray'](),this['_disableMaterial']['alpha']=0.4;var _0x129481=new _0x1f64e7(new _0x74d525['e'](0x0,0x1,0x0),_0x39310d['a']['Gray']()['scale'](0.5),this['gizmoLayer'],this);_0x129481['updateGizmoRotationToMatchAttachedMesh']=!0x1,_0x129481['uniformScaling']=!0x0,this['_uniformScalingMesh']=_0x39b46b['CreatePolyhedron']('uniform',{'type':0x1},_0x129481['gizmoLayer']['utilityLayerScene']),this['_uniformScalingMesh']['scaling']['scaleInPlace'](0.01),this['_uniformScalingMesh']['visibility']=0x0,this['_octahedron']=_0x39b46b['CreatePolyhedron']('',{'type':0x1},_0x129481['gizmoLayer']['utilityLayerScene']),this['_octahedron']['scaling']['scaleInPlace'](0.007),this['_uniformScalingMesh']['addChild'](this['_octahedron']),_0x129481['setCustomMesh'](this['_uniformScalingMesh'],!0x0);var _0x53ec02=this['gizmoLayer']['_getSharedGizmoLight']();_0x53ec02['includedOnlyMeshes']=_0x53ec02['includedOnlyMeshes']['concat'](this['_octahedron']);var _0xa25241={'gizmoMeshes':[this['_octahedron'],this['_uniformScalingMesh']],'colliderMeshes':[this['_uniformScalingMesh']],'material':this['_coloredMaterial'],'hoverMaterial':this['_hoverMaterial'],'disableMaterial':this['_disableMaterial'],'active':!0x1};return this['addToAxisCache'](_0x129481['_rootMesh'],_0xa25241),_0x129481;},Object['defineProperty'](_0x3e7e40['prototype'],'updateGizmoRotationToMatchAttachedMesh',{'get':function(){return this['_updateGizmoRotationToMatchAttachedMesh'];},'set':function(_0x5c4d93){_0x5c4d93?(this['_updateGizmoRotationToMatchAttachedMesh']=_0x5c4d93,[this['xGizmo'],this['yGizmo'],this['zGizmo'],this['uniformScaleGizmo']]['forEach'](function(_0x368e5f){_0x368e5f&&(_0x368e5f['updateGizmoRotationToMatchAttachedMesh']=_0x5c4d93);})):_0x75193d['a']['Warn']('Setting\x20updateGizmoRotationToMatchAttachedMesh\x20=\x20false\x20on\x20scaling\x20gizmo\x20is\x20not\x20supported.');},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3e7e40['prototype'],'snapDistance',{'get':function(){return this['_snapDistance'];},'set':function(_0x46913f){this['_snapDistance']=_0x46913f,[this['xGizmo'],this['yGizmo'],this['zGizmo'],this['uniformScaleGizmo']]['forEach'](function(_0x18591a){_0x18591a&&(_0x18591a['snapDistance']=_0x46913f);});},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3e7e40['prototype'],'scaleRatio',{'get':function(){return this['_scaleRatio'];},'set':function(_0x3e777d){this['_scaleRatio']=_0x3e777d,[this['xGizmo'],this['yGizmo'],this['zGizmo'],this['uniformScaleGizmo']]['forEach'](function(_0x468a9c){_0x468a9c&&(_0x468a9c['scaleRatio']=_0x3e777d);});},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3e7e40['prototype'],'sensitivity',{'get':function(){return this['_sensitivity'];},'set':function(_0x30beb2){this['_sensitivity']=_0x30beb2,[this['xGizmo'],this['yGizmo'],this['zGizmo'],this['uniformScaleGizmo']]['forEach'](function(_0x46e7a7){_0x46e7a7&&(_0x46e7a7['sensitivity']=_0x30beb2);});},'enumerable':!0x1,'configurable':!0x0}),_0x3e7e40['prototype']['addToAxisCache']=function(_0x4e2236,_0x3a5535){this['_gizmoAxisCache']['set'](_0x4e2236,_0x3a5535);},_0x3e7e40['prototype']['dispose']=function(){var _0x3f30dd=this;[this['xGizmo'],this['yGizmo'],this['zGizmo'],this['uniformScaleGizmo']]['forEach'](function(_0x48fe4c){_0x48fe4c&&_0x48fe4c['dispose']();}),this['_observables']['forEach'](function(_0x34bfd1){_0x3f30dd['gizmoLayer']['utilityLayerScene']['onPointerObservable']['remove'](_0x34bfd1);}),this['onDragStartObservable']['clear'](),this['onDragEndObservable']['clear'](),[this['_uniformScalingMesh'],this['_octahedron']]['forEach'](function(_0x1cdb45){_0x1cdb45&&_0x1cdb45['dispose']();}),[this['_coloredMaterial'],this['_hoverMaterial'],this['_disableMaterial']]['forEach'](function(_0x4754a1){_0x4754a1&&_0x4754a1['dispose']();});},_0x3e7e40;}(_0x417dc8['a']),_0x97daf7=(function(){function _0x532f93(_0x3d57e3,_0x32f9fb,_0x39f9d9,_0x2a0f4f){void 0x0===_0x32f9fb&&(_0x32f9fb=0x1),void 0x0===_0x39f9d9&&(_0x39f9d9=_0x539118['a']['DefaultUtilityLayer']),void 0x0===_0x2a0f4f&&(_0x2a0f4f=_0x539118['a']['DefaultKeepDepthUtilityLayer']),this['scene']=_0x3d57e3,this['clearGizmoOnEmptyPointerEvent']=!0x1,this['onAttachedToMeshObservable']=new _0x6ac1f7['c'](),this['onAttachedToNodeObservable']=new _0x6ac1f7['c'](),this['_gizmosEnabled']={'positionGizmo':!0x1,'rotationGizmo':!0x1,'scaleGizmo':!0x1,'boundingBoxGizmo':!0x1},this['_pointerObservers']=[],this['_attachedMesh']=null,this['_attachedNode']=null,this['_boundingBoxColor']=_0x39310d['a']['FromHexString']('#0984e3'),this['_thickness']=0x1,this['_gizmoAxisCache']=new Map(),this['boundingBoxDragBehavior']=new _0x2f1fdc(),this['attachableMeshes']=null,this['attachableNodes']=null,this['usePointerToAttachGizmos']=!0x0,this['_defaultUtilityLayer']=_0x39f9d9,this['_defaultKeepDepthUtilityLayer']=_0x2a0f4f,this['_defaultKeepDepthUtilityLayer']['utilityLayerScene']['autoClearDepthAndStencil']=!0x1,this['_thickness']=_0x32f9fb,this['gizmos']={'positionGizmo':null,'rotationGizmo':null,'scaleGizmo':null,'boundingBoxGizmo':null};var _0x125a6c=this['_attachToMeshPointerObserver'](_0x3d57e3),_0x23a770=_0x417dc8['a']['GizmoAxisPointerObserver'](this['_defaultUtilityLayer'],this['_gizmoAxisCache']);this['_pointerObservers']=[_0x125a6c,_0x23a770];}return Object['defineProperty'](_0x532f93['prototype'],'keepDepthUtilityLayer',{'get':function(){return this['_defaultKeepDepthUtilityLayer'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x532f93['prototype'],'utilityLayer',{'get':function(){return this['_defaultUtilityLayer'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x532f93['prototype'],'isHovered',{'get':function(){var _0x2c3605=!0x1;for(var _0x108515 in this['gizmos']){var _0x232d14=this['gizmos'][_0x108515];if(_0x232d14&&_0x232d14['isHovered']){_0x2c3605=!0x0;break;}}return _0x2c3605;},'enumerable':!0x1,'configurable':!0x0}),_0x532f93['prototype']['_attachToMeshPointerObserver']=function(_0x2421f0){var _0x245390=this;return _0x2421f0['onPointerObservable']['add'](function(_0x50ef81){if(_0x245390['usePointerToAttachGizmos']&&_0x50ef81['type']==_0x1cb628['a']['POINTERDOWN']){if(_0x50ef81['pickInfo']&&_0x50ef81['pickInfo']['pickedMesh']){var _0xc48d76=_0x50ef81['pickInfo']['pickedMesh'];if(null==_0x245390['attachableMeshes']){for(;_0xc48d76&&null!=_0xc48d76['parent'];)_0xc48d76=_0xc48d76['parent'];}else{var _0x3fbc87=!0x1;_0x245390['attachableMeshes']['forEach'](function(_0x51944f){_0xc48d76&&(_0xc48d76==_0x51944f||_0xc48d76['isDescendantOf'](_0x51944f))&&(_0xc48d76=_0x51944f,_0x3fbc87=!0x0);}),_0x3fbc87||(_0xc48d76=null);}_0xc48d76 instanceof _0x40d22e['a']?_0x245390['_attachedMesh']!=_0xc48d76&&_0x245390['attachToMesh'](_0xc48d76):_0x245390['clearGizmoOnEmptyPointerEvent']&&_0x245390['attachToMesh'](null);}else _0x245390['clearGizmoOnEmptyPointerEvent']&&_0x245390['attachToMesh'](null);}});},_0x532f93['prototype']['attachToMesh']=function(_0xa5600d){for(var _0x45fd1d in(this['_attachedMesh']&&this['_attachedMesh']['removeBehavior'](this['boundingBoxDragBehavior']),this['_attachedNode']&&this['_attachedNode']['removeBehavior'](this['boundingBoxDragBehavior']),this['_attachedMesh']=_0xa5600d,this['_attachedNode']=null,this['gizmos'])){var _0x281aba=this['gizmos'][_0x45fd1d];_0x281aba&&this['_gizmosEnabled'][_0x45fd1d]&&(_0x281aba['attachedMesh']=_0xa5600d);}this['boundingBoxGizmoEnabled']&&this['_attachedMesh']&&this['_attachedMesh']['addBehavior'](this['boundingBoxDragBehavior']),this['onAttachedToMeshObservable']['notifyObservers'](_0xa5600d);},_0x532f93['prototype']['attachToNode']=function(_0x1d1b98){for(var _0xa44bd7 in(this['_attachedMesh']&&this['_attachedMesh']['removeBehavior'](this['boundingBoxDragBehavior']),this['_attachedNode']&&this['_attachedNode']['removeBehavior'](this['boundingBoxDragBehavior']),this['_attachedMesh']=null,this['_attachedNode']=_0x1d1b98,this['gizmos'])){var _0x2e6fce=this['gizmos'][_0xa44bd7];_0x2e6fce&&this['_gizmosEnabled'][_0xa44bd7]&&(_0x2e6fce['attachedNode']=_0x1d1b98);}this['boundingBoxGizmoEnabled']&&this['_attachedNode']&&this['_attachedNode']['addBehavior'](this['boundingBoxDragBehavior']),this['onAttachedToNodeObservable']['notifyObservers'](_0x1d1b98);},Object['defineProperty'](_0x532f93['prototype'],'positionGizmoEnabled',{'get':function(){return this['_gizmosEnabled']['positionGizmo'];},'set':function(_0x18351c){_0x18351c?(this['gizmos']['positionGizmo']||(this['gizmos']['positionGizmo']=new _0xccbb24(this['_defaultUtilityLayer'],this['_thickness'],this)),this['_attachedNode']?this['gizmos']['positionGizmo']['attachedNode']=this['_attachedNode']:this['gizmos']['positionGizmo']['attachedMesh']=this['_attachedMesh']):this['gizmos']['positionGizmo']&&(this['gizmos']['positionGizmo']['attachedNode']=null),this['_gizmosEnabled']['positionGizmo']=_0x18351c;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x532f93['prototype'],'rotationGizmoEnabled',{'get':function(){return this['_gizmosEnabled']['rotationGizmo'];},'set':function(_0x4f74ed){_0x4f74ed?(this['gizmos']['rotationGizmo']||(this['gizmos']['rotationGizmo']=new _0xbdd3b4(this['_defaultUtilityLayer'],0x20,!0x1,this['_thickness'],this)),this['_attachedNode']?this['gizmos']['rotationGizmo']['attachedNode']=this['_attachedNode']:this['gizmos']['rotationGizmo']['attachedMesh']=this['_attachedMesh']):this['gizmos']['rotationGizmo']&&(this['gizmos']['rotationGizmo']['attachedNode']=null),this['_gizmosEnabled']['rotationGizmo']=_0x4f74ed;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x532f93['prototype'],'scaleGizmoEnabled',{'get':function(){return this['_gizmosEnabled']['scaleGizmo'];},'set':function(_0x324622){_0x324622?(this['gizmos']['scaleGizmo']=this['gizmos']['scaleGizmo']||new _0x5e0e1f(this['_defaultUtilityLayer'],this['_thickness'],this),this['_attachedNode']?this['gizmos']['scaleGizmo']['attachedNode']=this['_attachedNode']:this['gizmos']['scaleGizmo']['attachedMesh']=this['_attachedMesh']):this['gizmos']['scaleGizmo']&&(this['gizmos']['scaleGizmo']['attachedNode']=null),this['_gizmosEnabled']['scaleGizmo']=_0x324622;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x532f93['prototype'],'boundingBoxGizmoEnabled',{'get':function(){return this['_gizmosEnabled']['boundingBoxGizmo'];},'set':function(_0x540256){_0x540256?(this['gizmos']['boundingBoxGizmo']=this['gizmos']['boundingBoxGizmo']||new _0x322a76(this['_boundingBoxColor'],this['_defaultKeepDepthUtilityLayer']),this['_attachedMesh']?this['gizmos']['boundingBoxGizmo']['attachedMesh']=this['_attachedMesh']:this['gizmos']['boundingBoxGizmo']['attachedNode']=this['_attachedNode'],this['_attachedMesh']?(this['_attachedMesh']['removeBehavior'](this['boundingBoxDragBehavior']),this['_attachedMesh']['addBehavior'](this['boundingBoxDragBehavior'])):this['_attachedNode']&&(this['_attachedNode']['removeBehavior'](this['boundingBoxDragBehavior']),this['_attachedNode']['addBehavior'](this['boundingBoxDragBehavior']))):this['gizmos']['boundingBoxGizmo']&&(this['_attachedMesh']?this['_attachedMesh']['removeBehavior'](this['boundingBoxDragBehavior']):this['_attachedNode']&&this['_attachedNode']['removeBehavior'](this['boundingBoxDragBehavior']),this['gizmos']['boundingBoxGizmo']['attachedNode']=null),this['_gizmosEnabled']['boundingBoxGizmo']=_0x540256;},'enumerable':!0x1,'configurable':!0x0}),_0x532f93['prototype']['addToAxisCache']=function(_0xf238f6){var _0xda8391=this;_0xf238f6['size']>0x0&&_0xf238f6['forEach'](function(_0x99f821,_0x59c811){_0xda8391['_gizmoAxisCache']['set'](_0x59c811,_0x99f821);});},_0x532f93['prototype']['dispose']=function(){var _0x505e65=this;for(var _0x138f10 in(this['_pointerObservers']['forEach'](function(_0x56278b){_0x505e65['scene']['onPointerObservable']['remove'](_0x56278b);}),this['gizmos'])){var _0x1f7bde=this['gizmos'][_0x138f10];_0x1f7bde&&_0x1f7bde['dispose']();}this['_defaultKeepDepthUtilityLayer']['dispose'](),this['_defaultUtilityLayer']['dispose'](),this['boundingBoxDragBehavior']['detach'](),this['onAttachedToMeshObservable']['clear']();},_0x532f93;}()),_0x4e3e4a=_0x162675(0x30),_0x9de826=function(_0x4cbfb3){function _0x28c503(){var _0x8e3394=null!==_0x4cbfb3&&_0x4cbfb3['apply'](this,arguments)||this;return _0x8e3394['_needProjectionMatrixCompute']=!0x0,_0x8e3394;}return Object(_0x18e13d['d'])(_0x28c503,_0x4cbfb3),_0x28c503['prototype']['_setPosition']=function(_0xf78612){this['_position']=_0xf78612;},Object['defineProperty'](_0x28c503['prototype'],'position',{'get':function(){return this['_position'];},'set':function(_0x35b1d8){this['_setPosition'](_0x35b1d8);},'enumerable':!0x1,'configurable':!0x0}),_0x28c503['prototype']['_setDirection']=function(_0x2b5edd){this['_direction']=_0x2b5edd;},Object['defineProperty'](_0x28c503['prototype'],'direction',{'get':function(){return this['_direction'];},'set':function(_0x10ef53){this['_setDirection'](_0x10ef53);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x28c503['prototype'],'shadowMinZ',{'get':function(){return this['_shadowMinZ'];},'set':function(_0x2383ac){this['_shadowMinZ']=_0x2383ac,this['forceProjectionMatrixCompute']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x28c503['prototype'],'shadowMaxZ',{'get':function(){return this['_shadowMaxZ'];},'set':function(_0x123804){this['_shadowMaxZ']=_0x123804,this['forceProjectionMatrixCompute']();},'enumerable':!0x1,'configurable':!0x0}),_0x28c503['prototype']['computeTransformedInformation']=function(){return!(!this['parent']||!this['parent']['getWorldMatrix'])&&(this['transformedPosition']||(this['transformedPosition']=_0x74d525['e']['Zero']()),_0x74d525['e']['TransformCoordinatesToRef'](this['position'],this['parent']['getWorldMatrix'](),this['transformedPosition']),this['direction']&&(this['transformedDirection']||(this['transformedDirection']=_0x74d525['e']['Zero']()),_0x74d525['e']['TransformNormalToRef'](this['direction'],this['parent']['getWorldMatrix'](),this['transformedDirection'])),!0x0);},_0x28c503['prototype']['getDepthScale']=function(){return 0x32;},_0x28c503['prototype']['getShadowDirection']=function(_0x4fe69a){return this['transformedDirection']?this['transformedDirection']:this['direction'];},_0x28c503['prototype']['getAbsolutePosition']=function(){return this['transformedPosition']?this['transformedPosition']:this['position'];},_0x28c503['prototype']['setDirectionToTarget']=function(_0x3ddbdf){return this['direction']=_0x74d525['e']['Normalize'](_0x3ddbdf['subtract'](this['position'])),this['direction'];},_0x28c503['prototype']['getRotation']=function(){this['direction']['normalize']();var _0x46aefb=_0x74d525['e']['Cross'](this['direction'],_0x4a79a2['a']['Y']),_0x4b1607=_0x74d525['e']['Cross'](_0x46aefb,this['direction']);return _0x74d525['e']['RotationFromAxis'](_0x46aefb,_0x4b1607,this['direction']);},_0x28c503['prototype']['needCube']=function(){return!0x1;},_0x28c503['prototype']['needProjectionMatrixCompute']=function(){return this['_needProjectionMatrixCompute'];},_0x28c503['prototype']['forceProjectionMatrixCompute']=function(){this['_needProjectionMatrixCompute']=!0x0;},_0x28c503['prototype']['_initCache']=function(){_0x4cbfb3['prototype']['_initCache']['call'](this),this['_cache']['position']=_0x74d525['e']['Zero']();},_0x28c503['prototype']['_isSynchronized']=function(){return!!this['_cache']['position']['equals'](this['position']);},_0x28c503['prototype']['computeWorldMatrix']=function(_0x34164f){return!_0x34164f&&this['isSynchronized']()?(this['_currentRenderId']=this['getScene']()['getRenderId'](),this['_worldMatrix']):(this['_updateCache'](),this['_cache']['position']['copyFrom'](this['position']),this['_worldMatrix']||(this['_worldMatrix']=_0x74d525['a']['Identity']()),_0x74d525['a']['TranslationToRef'](this['position']['x'],this['position']['y'],this['position']['z'],this['_worldMatrix']),this['parent']&&this['parent']['getWorldMatrix']&&(this['_worldMatrix']['multiplyToRef'](this['parent']['getWorldMatrix'](),this['_worldMatrix']),this['_markSyncedWithParent']()),this['_worldMatrixDeterminantIsDirty']=!0x0,this['_worldMatrix']);},_0x28c503['prototype']['getDepthMinZ']=function(_0x1ac3d0){return void 0x0!==this['shadowMinZ']?this['shadowMinZ']:_0x1ac3d0['minZ'];},_0x28c503['prototype']['getDepthMaxZ']=function(_0x4d3155){return void 0x0!==this['shadowMaxZ']?this['shadowMaxZ']:_0x4d3155['maxZ'];},_0x28c503['prototype']['setShadowProjectionMatrix']=function(_0x39233c,_0x3dec43,_0x12352b){return this['customProjectionMatrixBuilder']?this['customProjectionMatrixBuilder'](_0x3dec43,_0x12352b,_0x39233c):this['_setDefaultShadowProjectionMatrix'](_0x39233c,_0x3dec43,_0x12352b),this;},Object(_0x18e13d['c'])([Object(_0x495d06['o'])()],_0x28c503['prototype'],'position',null),Object(_0x18e13d['c'])([Object(_0x495d06['o'])()],_0x28c503['prototype'],'direction',null),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x28c503['prototype'],'shadowMinZ',null),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x28c503['prototype'],'shadowMaxZ',null),_0x28c503;}(_0x4e3e4a['a']);_0x43169a['a']['AddNodeConstructor']('Light_Type_1',function(_0x362a25,_0x116b0e){return function(){return new _0x4367f2(_0x362a25,_0x74d525['e']['Zero'](),_0x116b0e);};});var _0x4367f2=function(_0x1c4700){function _0x348cf7(_0x42ef5b,_0x5f19da,_0x1bfc97){var _0x437675=_0x1c4700['call'](this,_0x42ef5b,_0x1bfc97)||this;return _0x437675['_shadowFrustumSize']=0x0,_0x437675['_shadowOrthoScale']=0.1,_0x437675['autoUpdateExtends']=!0x0,_0x437675['autoCalcShadowZBounds']=!0x1,_0x437675['_orthoLeft']=Number['MAX_VALUE'],_0x437675['_orthoRight']=Number['MIN_VALUE'],_0x437675['_orthoTop']=Number['MIN_VALUE'],_0x437675['_orthoBottom']=Number['MAX_VALUE'],_0x437675['position']=_0x5f19da['scale'](-0x1),_0x437675['direction']=_0x5f19da,_0x437675;}return Object(_0x18e13d['d'])(_0x348cf7,_0x1c4700),Object['defineProperty'](_0x348cf7['prototype'],'shadowFrustumSize',{'get':function(){return this['_shadowFrustumSize'];},'set':function(_0x4ba5e8){this['_shadowFrustumSize']=_0x4ba5e8,this['forceProjectionMatrixCompute']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x348cf7['prototype'],'shadowOrthoScale',{'get':function(){return this['_shadowOrthoScale'];},'set':function(_0x158b31){this['_shadowOrthoScale']=_0x158b31,this['forceProjectionMatrixCompute']();},'enumerable':!0x1,'configurable':!0x0}),_0x348cf7['prototype']['getClassName']=function(){return'DirectionalLight';},_0x348cf7['prototype']['getTypeID']=function(){return _0x4e3e4a['a']['LIGHTTYPEID_DIRECTIONALLIGHT'];},_0x348cf7['prototype']['_setDefaultShadowProjectionMatrix']=function(_0x1ae38d,_0x322412,_0x541fdc){this['shadowFrustumSize']>0x0?this['_setDefaultFixedFrustumShadowProjectionMatrix'](_0x1ae38d):this['_setDefaultAutoExtendShadowProjectionMatrix'](_0x1ae38d,_0x322412,_0x541fdc);},_0x348cf7['prototype']['_setDefaultFixedFrustumShadowProjectionMatrix']=function(_0x3f50f2){var _0x4e22d0=this['getScene']()['activeCamera'];_0x4e22d0&&_0x74d525['a']['OrthoLHToRef'](this['shadowFrustumSize'],this['shadowFrustumSize'],void 0x0!==this['shadowMinZ']?this['shadowMinZ']:_0x4e22d0['minZ'],void 0x0!==this['shadowMaxZ']?this['shadowMaxZ']:_0x4e22d0['maxZ'],_0x3f50f2);},_0x348cf7['prototype']['_setDefaultAutoExtendShadowProjectionMatrix']=function(_0xcfe8a1,_0x438d9d,_0x443565){var _0x192169=this['getScene']()['activeCamera'];if(_0x192169){if(this['autoUpdateExtends']||this['_orthoLeft']===Number['MAX_VALUE']){var _0x59cca5=_0x74d525['e']['Zero']();this['_orthoLeft']=Number['MAX_VALUE'],this['_orthoRight']=Number['MIN_VALUE'],this['_orthoTop']=Number['MIN_VALUE'],this['_orthoBottom']=Number['MAX_VALUE'];for(var _0x2b0ee0=Number['MAX_VALUE'],_0x1a4605=Number['MIN_VALUE'],_0x59e173=0x0;_0x59e173<_0x443565['length'];_0x59e173++){var _0x5d02e6=_0x443565[_0x59e173];if(_0x5d02e6){for(var _0x414a39=_0x5d02e6['getBoundingInfo']()['boundingBox'],_0x4094ad=0x0;_0x4094ad<_0x414a39['vectorsWorld']['length'];_0x4094ad++)_0x74d525['e']['TransformCoordinatesToRef'](_0x414a39['vectorsWorld'][_0x4094ad],_0x438d9d,_0x59cca5),_0x59cca5['x']this['_orthoRight']&&(this['_orthoRight']=_0x59cca5['x']),_0x59cca5['y']>this['_orthoTop']&&(this['_orthoTop']=_0x59cca5['y']),this['autoCalcShadowZBounds']&&(_0x59cca5['z']<_0x2b0ee0&&(_0x2b0ee0=_0x59cca5['z']),_0x59cca5['z']>_0x1a4605&&(_0x1a4605=_0x59cca5['z']));}}this['autoCalcShadowZBounds']&&(this['_shadowMinZ']=_0x2b0ee0,this['_shadowMaxZ']=_0x1a4605);}var _0xfb56aa=this['_orthoRight']-this['_orthoLeft'],_0x324424=this['_orthoTop']-this['_orthoBottom'];_0x74d525['a']['OrthoOffCenterLHToRef'](this['_orthoLeft']-_0xfb56aa*this['shadowOrthoScale'],this['_orthoRight']+_0xfb56aa*this['shadowOrthoScale'],this['_orthoBottom']-_0x324424*this['shadowOrthoScale'],this['_orthoTop']+_0x324424*this['shadowOrthoScale'],void 0x0!==this['shadowMinZ']?this['shadowMinZ']:_0x192169['minZ'],void 0x0!==this['shadowMaxZ']?this['shadowMaxZ']:_0x192169['maxZ'],_0xcfe8a1);}},_0x348cf7['prototype']['_buildUniformLayout']=function(){this['_uniformBuffer']['addUniform']('vLightData',0x4),this['_uniformBuffer']['addUniform']('vLightDiffuse',0x4),this['_uniformBuffer']['addUniform']('vLightSpecular',0x4),this['_uniformBuffer']['addUniform']('shadowsInfo',0x3),this['_uniformBuffer']['addUniform']('depthValues',0x2),this['_uniformBuffer']['create']();},_0x348cf7['prototype']['transferToEffect']=function(_0x31196a,_0x3e074a){return this['computeTransformedInformation']()?(this['_uniformBuffer']['updateFloat4']('vLightData',this['transformedDirection']['x'],this['transformedDirection']['y'],this['transformedDirection']['z'],0x1,_0x3e074a),this):(this['_uniformBuffer']['updateFloat4']('vLightData',this['direction']['x'],this['direction']['y'],this['direction']['z'],0x1,_0x3e074a),this);},_0x348cf7['prototype']['transferToNodeMaterialEffect']=function(_0x45be74,_0x14db8b){return this['computeTransformedInformation']()?(_0x45be74['setFloat3'](_0x14db8b,this['transformedDirection']['x'],this['transformedDirection']['y'],this['transformedDirection']['z']),this):(_0x45be74['setFloat3'](_0x14db8b,this['direction']['x'],this['direction']['y'],this['direction']['z']),this);},_0x348cf7['prototype']['getDepthMinZ']=function(_0x429dc5){return 0x1;},_0x348cf7['prototype']['getDepthMaxZ']=function(_0x5917d8){return 0x1;},_0x348cf7['prototype']['prepareLightSpecificDefines']=function(_0x2920ef,_0x2e5008){_0x2920ef['DIRLIGHT'+_0x2e5008]=!0x0;},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x348cf7['prototype'],'shadowFrustumSize',null),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x348cf7['prototype'],'shadowOrthoScale',null),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x348cf7['prototype'],'autoUpdateExtends',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x348cf7['prototype'],'autoCalcShadowZBounds',void 0x0),_0x348cf7;}(_0x9de826);_0x3cf5e5['a']['CreateHemisphere']=function(_0x507594,_0x2c1021,_0x1910d2,_0x447722){var _0x5f090d={'segments':_0x2c1021,'diameter':_0x1910d2};return _0x380273['CreateHemisphere'](_0x507594,_0x5f090d,_0x447722);};var _0x380273=(function(){function _0x33b4cc(){}return _0x33b4cc['CreateHemisphere']=function(_0x16306a,_0x2b2e24,_0x12a512){_0x2b2e24['diameter']||(_0x2b2e24['diameter']=0x1),_0x2b2e24['segments']||(_0x2b2e24['segments']=0x10);var _0x5a92d2=_0x5c4f8d['a']['CreateSphere']('',{'slice':0.5,'diameter':_0x2b2e24['diameter'],'segments':_0x2b2e24['segments']},_0x12a512),_0x20d677=_0x3cf5e5['a']['CreateDisc']('',_0x2b2e24['diameter']/0x2,0x3*_0x2b2e24['segments']+(0x4-_0x2b2e24['segments']),_0x12a512);_0x20d677['rotation']['x']=-Math['PI']/0x2,_0x20d677['parent']=_0x5a92d2;var _0x102977=_0x3cf5e5['a']['MergeMeshes']([_0x20d677,_0x5a92d2],!0x0);return _0x102977['name']=_0x16306a,_0x102977;},_0x33b4cc;}());_0x43169a['a']['AddNodeConstructor']('Light_Type_2',function(_0x408fa1,_0x5e64fb){return function(){return new _0x27087d(_0x408fa1,_0x74d525['e']['Zero'](),_0x74d525['e']['Zero'](),0x0,0x0,_0x5e64fb);};});var _0x27087d=function(_0x4a11a4){function _0xac660b(_0x20fb5a,_0x59be08,_0x15cff1,_0x22952b,_0x2809a5,_0x13b81e){var _0x5164a4=_0x4a11a4['call'](this,_0x20fb5a,_0x13b81e)||this;return _0x5164a4['_innerAngle']=0x0,_0x5164a4['_projectionTextureMatrix']=_0x74d525['a']['Zero'](),_0x5164a4['_projectionTextureLightNear']=0.000001,_0x5164a4['_projectionTextureLightFar']=0x3e8,_0x5164a4['_projectionTextureUpDirection']=_0x74d525['e']['Up'](),_0x5164a4['_projectionTextureViewLightDirty']=!0x0,_0x5164a4['_projectionTextureProjectionLightDirty']=!0x0,_0x5164a4['_projectionTextureDirty']=!0x0,_0x5164a4['_projectionTextureViewTargetVector']=_0x74d525['e']['Zero'](),_0x5164a4['_projectionTextureViewLightMatrix']=_0x74d525['a']['Zero'](),_0x5164a4['_projectionTextureProjectionLightMatrix']=_0x74d525['a']['Zero'](),_0x5164a4['_projectionTextureScalingMatrix']=_0x74d525['a']['FromValues'](0.5,0x0,0x0,0x0,0x0,0.5,0x0,0x0,0x0,0x0,0.5,0x0,0.5,0.5,0.5,0x1),_0x5164a4['position']=_0x59be08,_0x5164a4['direction']=_0x15cff1,_0x5164a4['angle']=_0x22952b,_0x5164a4['exponent']=_0x2809a5,_0x5164a4;}return Object(_0x18e13d['d'])(_0xac660b,_0x4a11a4),Object['defineProperty'](_0xac660b['prototype'],'angle',{'get':function(){return this['_angle'];},'set':function(_0x31b1d0){this['_angle']=_0x31b1d0,this['_cosHalfAngle']=Math['cos'](0.5*_0x31b1d0),this['_projectionTextureProjectionLightDirty']=!0x0,this['forceProjectionMatrixCompute'](),this['_computeAngleValues']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xac660b['prototype'],'innerAngle',{'get':function(){return this['_innerAngle'];},'set':function(_0x190ae5){this['_innerAngle']=_0x190ae5,this['_computeAngleValues']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xac660b['prototype'],'shadowAngleScale',{'get':function(){return this['_shadowAngleScale'];},'set':function(_0x4553cf){this['_shadowAngleScale']=_0x4553cf,this['forceProjectionMatrixCompute']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xac660b['prototype'],'projectionTextureMatrix',{'get':function(){return this['_projectionTextureMatrix'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xac660b['prototype'],'projectionTextureLightNear',{'get':function(){return this['_projectionTextureLightNear'];},'set':function(_0x32d7ff){this['_projectionTextureLightNear']=_0x32d7ff,this['_projectionTextureProjectionLightDirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xac660b['prototype'],'projectionTextureLightFar',{'get':function(){return this['_projectionTextureLightFar'];},'set':function(_0x1bf627){this['_projectionTextureLightFar']=_0x1bf627,this['_projectionTextureProjectionLightDirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xac660b['prototype'],'projectionTextureUpDirection',{'get':function(){return this['_projectionTextureUpDirection'];},'set':function(_0x56b324){this['_projectionTextureUpDirection']=_0x56b324,this['_projectionTextureProjectionLightDirty']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xac660b['prototype'],'projectionTexture',{'get':function(){return this['_projectionTexture'];},'set':function(_0x336b1d){var _0x18089a=this;this['_projectionTexture']!==_0x336b1d&&(this['_projectionTexture']=_0x336b1d,this['_projectionTextureDirty']=!0x0,this['_projectionTexture']&&!this['_projectionTexture']['isReady']()&&(_0xac660b['_IsProceduralTexture'](this['_projectionTexture'])?this['_projectionTexture']['getEffect']()['executeWhenCompiled'](function(){_0x18089a['_markMeshesAsLightDirty']();}):_0xac660b['_IsTexture'](this['_projectionTexture'])&&this['_projectionTexture']['onLoadObservable']['addOnce'](function(){_0x18089a['_markMeshesAsLightDirty']();})));},'enumerable':!0x1,'configurable':!0x0}),_0xac660b['_IsProceduralTexture']=function(_0x3230c1){return void 0x0!==_0x3230c1['onGeneratedObservable'];},_0xac660b['_IsTexture']=function(_0x47835a){return void 0x0!==_0x47835a['onLoadObservable'];},_0xac660b['prototype']['getClassName']=function(){return'SpotLight';},_0xac660b['prototype']['getTypeID']=function(){return _0x4e3e4a['a']['LIGHTTYPEID_SPOTLIGHT'];},_0xac660b['prototype']['_setDirection']=function(_0x48721d){_0x4a11a4['prototype']['_setDirection']['call'](this,_0x48721d),this['_projectionTextureViewLightDirty']=!0x0;},_0xac660b['prototype']['_setPosition']=function(_0x4865f8){_0x4a11a4['prototype']['_setPosition']['call'](this,_0x4865f8),this['_projectionTextureViewLightDirty']=!0x0;},_0xac660b['prototype']['_setDefaultShadowProjectionMatrix']=function(_0x1a123e,_0x31f99e,_0x54f6b0){var _0x238500=this['getScene']()['activeCamera'];if(_0x238500){this['_shadowAngleScale']=this['_shadowAngleScale']||0x1;var _0x1eb702=this['_shadowAngleScale']*this['_angle'];_0x74d525['a']['PerspectiveFovLHToRef'](_0x1eb702,0x1,this['getDepthMinZ'](_0x238500),this['getDepthMaxZ'](_0x238500),_0x1a123e);}},_0xac660b['prototype']['_computeProjectionTextureViewLightMatrix']=function(){this['_projectionTextureViewLightDirty']=!0x1,this['_projectionTextureDirty']=!0x0,this['position']['addToRef'](this['direction'],this['_projectionTextureViewTargetVector']),_0x74d525['a']['LookAtLHToRef'](this['position'],this['_projectionTextureViewTargetVector'],this['_projectionTextureUpDirection'],this['_projectionTextureViewLightMatrix']);},_0xac660b['prototype']['_computeProjectionTextureProjectionLightMatrix']=function(){this['_projectionTextureProjectionLightDirty']=!0x1,this['_projectionTextureDirty']=!0x0;var _0x45c5bf=this['projectionTextureLightFar'],_0x3af676=this['projectionTextureLightNear'],_0x3391d5=_0x45c5bf/(_0x45c5bf-_0x3af676),_0x1d8234=-_0x3391d5*_0x3af676,_0x4cba3d=0x1/Math['tan'](this['_angle']/0x2);_0x74d525['a']['FromValuesToRef'](_0x4cba3d/0x1,0x0,0x0,0x0,0x0,_0x4cba3d,0x0,0x0,0x0,0x0,_0x3391d5,0x1,0x0,0x0,_0x1d8234,0x0,this['_projectionTextureProjectionLightMatrix']);},_0xac660b['prototype']['_computeProjectionTextureMatrix']=function(){if(this['_projectionTextureDirty']=!0x1,this['_projectionTextureViewLightMatrix']['multiplyToRef'](this['_projectionTextureProjectionLightMatrix'],this['_projectionTextureMatrix']),this['_projectionTexture']instanceof _0xaf3c80['a']){var _0x5341dd=this['_projectionTexture']['uScale']/0x2,_0x3f49c6=this['_projectionTexture']['vScale']/0x2;_0x74d525['a']['FromValuesToRef'](_0x5341dd,0x0,0x0,0x0,0x0,_0x3f49c6,0x0,0x0,0x0,0x0,0.5,0x0,0.5,0.5,0.5,0x1,this['_projectionTextureScalingMatrix']);}this['_projectionTextureMatrix']['multiplyToRef'](this['_projectionTextureScalingMatrix'],this['_projectionTextureMatrix']);},_0xac660b['prototype']['_buildUniformLayout']=function(){this['_uniformBuffer']['addUniform']('vLightData',0x4),this['_uniformBuffer']['addUniform']('vLightDiffuse',0x4),this['_uniformBuffer']['addUniform']('vLightSpecular',0x4),this['_uniformBuffer']['addUniform']('vLightDirection',0x3),this['_uniformBuffer']['addUniform']('vLightFalloff',0x4),this['_uniformBuffer']['addUniform']('shadowsInfo',0x3),this['_uniformBuffer']['addUniform']('depthValues',0x2),this['_uniformBuffer']['create']();},_0xac660b['prototype']['_computeAngleValues']=function(){this['_lightAngleScale']=0x1/Math['max'](0.001,Math['cos'](0.5*this['_innerAngle'])-this['_cosHalfAngle']),this['_lightAngleOffset']=-this['_cosHalfAngle']*this['_lightAngleScale'];},_0xac660b['prototype']['transferTexturesToEffect']=function(_0xb3569a,_0x3bf91b){return this['projectionTexture']&&this['projectionTexture']['isReady']()&&(this['_projectionTextureViewLightDirty']&&this['_computeProjectionTextureViewLightMatrix'](),this['_projectionTextureProjectionLightDirty']&&this['_computeProjectionTextureProjectionLightMatrix'](),this['_projectionTextureDirty']&&this['_computeProjectionTextureMatrix'](),_0xb3569a['setMatrix']('textureProjectionMatrix'+_0x3bf91b,this['_projectionTextureMatrix']),_0xb3569a['setTexture']('projectionLightSampler'+_0x3bf91b,this['projectionTexture'])),this;},_0xac660b['prototype']['transferToEffect']=function(_0x4b6b59,_0x1e599d){var _0x4075d2;return this['computeTransformedInformation']()?(this['_uniformBuffer']['updateFloat4']('vLightData',this['transformedPosition']['x'],this['transformedPosition']['y'],this['transformedPosition']['z'],this['exponent'],_0x1e599d),_0x4075d2=_0x74d525['e']['Normalize'](this['transformedDirection'])):(this['_uniformBuffer']['updateFloat4']('vLightData',this['position']['x'],this['position']['y'],this['position']['z'],this['exponent'],_0x1e599d),_0x4075d2=_0x74d525['e']['Normalize'](this['direction'])),this['_uniformBuffer']['updateFloat4']('vLightDirection',_0x4075d2['x'],_0x4075d2['y'],_0x4075d2['z'],this['_cosHalfAngle'],_0x1e599d),this['_uniformBuffer']['updateFloat4']('vLightFalloff',this['range'],this['_inverseSquaredRange'],this['_lightAngleScale'],this['_lightAngleOffset'],_0x1e599d),this;},_0xac660b['prototype']['transferToNodeMaterialEffect']=function(_0x3e9544,_0x2b0fe3){var _0x33cda4;return _0x33cda4=this['computeTransformedInformation']()?_0x74d525['e']['Normalize'](this['transformedDirection']):_0x74d525['e']['Normalize'](this['direction']),this['getScene']()['useRightHandedSystem']?_0x3e9544['setFloat3'](_0x2b0fe3,-_0x33cda4['x'],-_0x33cda4['y'],-_0x33cda4['z']):_0x3e9544['setFloat3'](_0x2b0fe3,_0x33cda4['x'],_0x33cda4['y'],_0x33cda4['z']),this;},_0xac660b['prototype']['dispose']=function(){_0x4a11a4['prototype']['dispose']['call'](this),this['_projectionTexture']&&this['_projectionTexture']['dispose']();},_0xac660b['prototype']['prepareLightSpecificDefines']=function(_0x46cbfb,_0x516fcd){_0x46cbfb['SPOTLIGHT'+_0x516fcd]=!0x0,_0x46cbfb['PROJECTEDLIGHTTEXTURE'+_0x516fcd]=!(!this['projectionTexture']||!this['projectionTexture']['isReady']());},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xac660b['prototype'],'angle',null),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xac660b['prototype'],'innerAngle',null),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xac660b['prototype'],'shadowAngleScale',null),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xac660b['prototype'],'exponent',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xac660b['prototype'],'projectionTextureLightNear',null),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xac660b['prototype'],'projectionTextureLightFar',null),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xac660b['prototype'],'projectionTextureUpDirection',null),Object(_0x18e13d['c'])([Object(_0x495d06['m'])('projectedLightTexture')],_0xac660b['prototype'],'_projectionTexture',void 0x0),_0xac660b;}(_0x9de826),_0x499c61=function(_0x1f386d){function _0x276eaf(_0x42096d){void 0x0===_0x42096d&&(_0x42096d=_0x539118['a']['DefaultUtilityLayer']);var _0x7e7a15=_0x1f386d['call'](this,_0x42096d)||this;return _0x7e7a15['_cachedPosition']=new _0x74d525['e'](),_0x7e7a15['_cachedForward']=new _0x74d525['e'](0x0,0x0,0x1),_0x7e7a15['_pointerObserver']=null,_0x7e7a15['onClickedObservable']=new _0x6ac1f7['c'](),_0x7e7a15['_light']=null,_0x7e7a15['attachedMesh']=new _0x40d22e['a']('',_0x7e7a15['gizmoLayer']['utilityLayerScene']),_0x7e7a15['_attachedMeshParent']=new _0x200669['a']('parent',_0x7e7a15['gizmoLayer']['utilityLayerScene']),_0x7e7a15['attachedMesh']['parent']=_0x7e7a15['_attachedMeshParent'],_0x7e7a15['_material']=new _0x5905ab['a']('light',_0x7e7a15['gizmoLayer']['utilityLayerScene']),_0x7e7a15['_material']['diffuseColor']=new _0x39310d['a'](0.5,0.5,0.5),_0x7e7a15['_material']['specularColor']=new _0x39310d['a'](0.1,0.1,0.1),_0x7e7a15['_pointerObserver']=_0x42096d['utilityLayerScene']['onPointerObservable']['add'](function(_0x299561){_0x7e7a15['_light']&&(_0x7e7a15['_isHovered']=!(!_0x299561['pickInfo']||-0x1==_0x7e7a15['_rootMesh']['getChildMeshes']()['indexOf'](_0x299561['pickInfo']['pickedMesh'])),_0x7e7a15['_isHovered']&&0x0===_0x299561['event']['button']&&_0x7e7a15['onClickedObservable']['notifyObservers'](_0x7e7a15['_light']));},_0x1cb628['a']['POINTERDOWN']),_0x7e7a15;}return Object(_0x18e13d['d'])(_0x276eaf,_0x1f386d),Object['defineProperty'](_0x276eaf['prototype'],'light',{'get':function(){return this['_light'];},'set':function(_0xe428a5){var _0x2d44c4=this;if(this['_light']=_0xe428a5,_0xe428a5){this['_lightMesh']&&this['_lightMesh']['dispose'](),_0xe428a5 instanceof _0xb2c680['a']?this['_lightMesh']=_0x276eaf['_CreateHemisphericLightMesh'](this['gizmoLayer']['utilityLayerScene']):this['_lightMesh']=_0xe428a5 instanceof _0x4367f2?_0x276eaf['_CreateDirectionalLightMesh'](this['gizmoLayer']['utilityLayerScene']):_0xe428a5 instanceof _0x27087d?_0x276eaf['_CreateSpotLightMesh'](this['gizmoLayer']['utilityLayerScene']):_0x276eaf['_CreatePointLightMesh'](this['gizmoLayer']['utilityLayerScene']),this['_lightMesh']['getChildMeshes'](!0x1)['forEach'](function(_0x3fc42c){_0x3fc42c['material']=_0x2d44c4['_material'];}),this['_lightMesh']['parent']=this['_rootMesh'];var _0x27105d=this['gizmoLayer']['_getSharedGizmoLight']();_0x27105d['includedOnlyMeshes']=_0x27105d['includedOnlyMeshes']['concat'](this['_lightMesh']['getChildMeshes'](!0x1)),this['_lightMesh']['rotationQuaternion']=new _0x74d525['b'](),this['attachedMesh']['reservedDataStore']||(this['attachedMesh']['reservedDataStore']={}),this['attachedMesh']['reservedDataStore']['lightGizmo']=this,_0xe428a5['parent']&&this['_attachedMeshParent']['freezeWorldMatrix'](_0xe428a5['parent']['getWorldMatrix']()),_0xe428a5['position']&&(this['attachedMesh']['position']['copyFrom'](_0xe428a5['position']),this['attachedMesh']['computeWorldMatrix'](!0x0),this['_cachedPosition']['copyFrom'](this['attachedMesh']['position'])),_0xe428a5['direction']&&(this['attachedMesh']['setDirection'](_0xe428a5['direction']),this['attachedMesh']['computeWorldMatrix'](!0x0),this['_cachedForward']['copyFrom'](this['attachedMesh']['forward'])),this['_update']();}},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x276eaf['prototype'],'material',{'get':function(){return this['_material'];},'enumerable':!0x1,'configurable':!0x0}),_0x276eaf['prototype']['_update']=function(){_0x1f386d['prototype']['_update']['call'](this),this['_light']&&(this['_light']['parent']&&this['_attachedMeshParent']['freezeWorldMatrix'](this['_light']['parent']['getWorldMatrix']()),this['_light']['position']&&(this['attachedMesh']['position']['equals'](this['_cachedPosition'])?(this['attachedMesh']['position']['copyFrom'](this['_light']['position']),this['attachedMesh']['computeWorldMatrix'](!0x0),this['_cachedPosition']['copyFrom'](this['attachedMesh']['position'])):(this['_light']['position']['copyFrom'](this['attachedMesh']['position']),this['_cachedPosition']['copyFrom'](this['attachedMesh']['position']))),this['_light']['direction']&&(_0x74d525['e']['DistanceSquared'](this['attachedMesh']['forward'],this['_cachedForward'])>0.0001?(this['_light']['direction']['copyFrom'](this['attachedMesh']['forward']),this['_cachedForward']['copyFrom'](this['attachedMesh']['forward'])):_0x74d525['e']['DistanceSquared'](this['attachedMesh']['forward'],this['_light']['direction'])>0.0001&&(this['attachedMesh']['setDirection'](this['_light']['direction']),this['attachedMesh']['computeWorldMatrix'](!0x0),this['_cachedForward']['copyFrom'](this['attachedMesh']['forward']))));},_0x276eaf['prototype']['dispose']=function(){this['onClickedObservable']['clear'](),this['gizmoLayer']['utilityLayerScene']['onPointerObservable']['remove'](this['_pointerObserver']),this['_material']['dispose'](),_0x1f386d['prototype']['dispose']['call'](this),this['_attachedMeshParent']['dispose']();},_0x276eaf['_CreateHemisphericLightMesh']=function(_0x426769){var _0x54b558=new _0x3cf5e5['a']('hemisphereLight',_0x426769),_0x4087a0=_0x380273['CreateHemisphere'](_0x54b558['name'],{'segments':0xa,'diameter':0x1},_0x426769);_0x4087a0['position']['z']=-0.15,_0x4087a0['rotation']['x']=Math['PI']/0x2,_0x4087a0['parent']=_0x54b558;var _0x4896e3=this['_CreateLightLines'](0x3,_0x426769);return _0x4896e3['parent']=_0x54b558,_0x4896e3['position']['z'],_0x54b558['scaling']['scaleInPlace'](_0x276eaf['_Scale']),_0x54b558['rotation']['x']=Math['PI']/0x2,_0x54b558;},_0x276eaf['_CreatePointLightMesh']=function(_0x43aae1){var _0x1ef430=new _0x3cf5e5['a']('pointLight',_0x43aae1),_0x5cbff8=_0x5c4f8d['a']['CreateSphere'](_0x1ef430['name'],{'segments':0xa,'diameter':0x1},_0x43aae1);return _0x5cbff8['rotation']['x']=Math['PI']/0x2,_0x5cbff8['parent']=_0x1ef430,this['_CreateLightLines'](0x5,_0x43aae1)['parent']=_0x1ef430,_0x1ef430['scaling']['scaleInPlace'](_0x276eaf['_Scale']),_0x1ef430['rotation']['x']=Math['PI']/0x2,_0x1ef430;},_0x276eaf['_CreateSpotLightMesh']=function(_0x4e76f7){var _0x4b7fc4=new _0x3cf5e5['a']('spotLight',_0x4e76f7);_0x5c4f8d['a']['CreateSphere'](_0x4b7fc4['name'],{'segments':0xa,'diameter':0x1},_0x4e76f7)['parent']=_0x4b7fc4;var _0x4304c0=_0x380273['CreateHemisphere'](_0x4b7fc4['name'],{'segments':0xa,'diameter':0x2},_0x4e76f7);return _0x4304c0['parent']=_0x4b7fc4,_0x4304c0['rotation']['x']=-Math['PI']/0x2,this['_CreateLightLines'](0x2,_0x4e76f7)['parent']=_0x4b7fc4,_0x4b7fc4['scaling']['scaleInPlace'](_0x276eaf['_Scale']),_0x4b7fc4['rotation']['x']=Math['PI']/0x2,_0x4b7fc4;},_0x276eaf['_CreateDirectionalLightMesh']=function(_0x287641){var _0x913954=new _0x3cf5e5['a']('directionalLight',_0x287641),_0x4a1190=new _0x3cf5e5['a'](_0x913954['name'],_0x287641);_0x4a1190['parent']=_0x913954,_0x5c4f8d['a']['CreateSphere'](_0x913954['name'],{'diameter':1.2,'segments':0xa},_0x287641)['parent']=_0x4a1190;var _0x13afa7=_0x3cf5e5['a']['CreateCylinder'](_0x913954['name'],0x6,0.3,0.3,0x6,0x1,_0x287641);_0x13afa7['parent']=_0x4a1190,(_0x29aa83=_0x13afa7['clone'](_0x913954['name']))['scaling']['y']=0.5,_0x29aa83['position']['x']+=1.25,(_0x232b19=_0x13afa7['clone'](_0x913954['name']))['scaling']['y']=0.5,_0x232b19['position']['x']+=-1.25;var _0x29aa83,_0x232b19,_0x252022=_0x3cf5e5['a']['CreateCylinder'](_0x913954['name'],0x1,0x0,0.6,0x6,0x1,_0x287641);return _0x252022['position']['y']+=0x3,_0x252022['parent']=_0x4a1190,(_0x29aa83=_0x252022['clone'](_0x913954['name']))['position']['y']=1.5,_0x29aa83['position']['x']+=1.25,(_0x232b19=_0x252022['clone'](_0x913954['name']))['position']['y']=1.5,_0x232b19['position']['x']+=-1.25,_0x4a1190['scaling']['scaleInPlace'](_0x276eaf['_Scale']),_0x4a1190['rotation']['z']=Math['PI']/0x2,_0x4a1190['rotation']['y']=Math['PI']/0x2,_0x913954;},_0x276eaf['_Scale']=0.007,_0x276eaf['_CreateLightLines']=function(_0x99a623,_0x2ab97d){var _0x497678=new _0x3cf5e5['a']('root',_0x2ab97d);_0x497678['rotation']['x']=Math['PI']/0x2;var _0x31d0f6=new _0x3cf5e5['a']('linePivot',_0x2ab97d);_0x31d0f6['parent']=_0x497678;var _0x22c2cb=_0x3cf5e5['a']['CreateCylinder']('line',0x2,0.2,0.3,0x6,0x1,_0x2ab97d);if(_0x22c2cb['position']['y']=_0x22c2cb['scaling']['y']/0x2+1.2,_0x22c2cb['parent']=_0x31d0f6,_0x99a623<0x2)return _0x31d0f6;for(var _0x2072fb=0x0;_0x2072fb<0x4;_0x2072fb++){(_0x337dbb=_0x31d0f6['clone']('lineParentClone'))['rotation']['z']=Math['PI']/0x4,_0x337dbb['rotation']['y']=Math['PI']/0x2+Math['PI']/0x2*_0x2072fb,_0x337dbb['getChildMeshes']()[0x0]['scaling']['y']=0.5,_0x337dbb['getChildMeshes']()[0x0]['scaling']['x']=_0x337dbb['getChildMeshes']()[0x0]['scaling']['z']=0.8,_0x337dbb['getChildMeshes']()[0x0]['position']['y']=_0x337dbb['getChildMeshes']()[0x0]['scaling']['y']/0x2+1.2;}if(_0x99a623<0x3)return _0x497678;for(_0x2072fb=0x0;_0x2072fb<0x4;_0x2072fb++){(_0x337dbb=_0x31d0f6['clone']('linePivotClone'))['rotation']['z']=Math['PI']/0x2,_0x337dbb['rotation']['y']=Math['PI']/0x2*_0x2072fb;}if(_0x99a623<0x4)return _0x497678;for(_0x2072fb=0x0;_0x2072fb<0x4;_0x2072fb++){var _0x337dbb;(_0x337dbb=_0x31d0f6['clone']('linePivotClone'))['rotation']['z']=Math['PI']+Math['PI']/0x4,_0x337dbb['rotation']['y']=Math['PI']/0x2+Math['PI']/0x2*_0x2072fb,_0x337dbb['getChildMeshes']()[0x0]['scaling']['y']=0.5,_0x337dbb['getChildMeshes']()[0x0]['scaling']['x']=_0x337dbb['getChildMeshes']()[0x0]['scaling']['z']=0.8,_0x337dbb['getChildMeshes']()[0x0]['position']['y']=_0x337dbb['getChildMeshes']()[0x0]['scaling']['y']/0x2+1.2;}return _0x99a623<0x5||((_0x337dbb=_0x31d0f6['clone']('linePivotClone'))['rotation']['z']=Math['PI']),_0x497678;},_0x276eaf;}(_0x417dc8['a']),_0x5a7f8f=(function(){function _0x134e88(_0x262cd5,_0x345342){void 0x0===_0x262cd5&&(_0x262cd5=_0x74d525['e']['Zero']()),void 0x0===_0x345342&&(_0x345342=_0x74d525['e']['Up']()),this['position']=_0x262cd5,this['normal']=_0x345342;}return _0x134e88['prototype']['clone']=function(){return new _0x134e88(this['position']['clone'](),this['normal']['clone']());},_0x134e88;}()),_0x440fac=(function(){function _0x935fcd(_0x44057b,_0xd12bf1,_0x2416eb){void 0x0===_0x44057b&&(_0x44057b=_0x74d525['e']['Zero']()),void 0x0===_0xd12bf1&&(_0xd12bf1=_0x74d525['e']['Up']()),void 0x0===_0x2416eb&&(_0x2416eb=_0x74d525['d']['Zero']()),this['position']=_0x44057b,this['normal']=_0xd12bf1,this['uv']=_0x2416eb;}return _0x935fcd['prototype']['clone']=function(){return new _0x935fcd(this['position']['clone'](),this['normal']['clone'](),this['uv']['clone']());},_0x935fcd;}()),_0x4a61d0=function(_0x24d9a9){function _0x539e30(_0x42100e){void 0x0===_0x42100e&&(_0x42100e=_0x539118['a']['DefaultUtilityLayer']);var _0xbbae72=_0x24d9a9['call'](this,_0x42100e)||this;return _0xbbae72['_pointerObserver']=null,_0xbbae72['onClickedObservable']=new _0x6ac1f7['c'](),_0xbbae72['_camera']=null,_0xbbae72['_invProjection']=new _0x74d525['a'](),_0xbbae72['_material']=new _0x5905ab['a']('cameraGizmoMaterial',_0xbbae72['gizmoLayer']['utilityLayerScene']),_0xbbae72['_material']['diffuseColor']=new _0x39310d['a'](0.5,0.5,0.5),_0xbbae72['_material']['specularColor']=new _0x39310d['a'](0.1,0.1,0.1),_0xbbae72['_pointerObserver']=_0x42100e['utilityLayerScene']['onPointerObservable']['add'](function(_0x159304){_0xbbae72['_camera']&&(_0xbbae72['_isHovered']=!(!_0x159304['pickInfo']||-0x1==_0xbbae72['_rootMesh']['getChildMeshes']()['indexOf'](_0x159304['pickInfo']['pickedMesh'])),_0xbbae72['_isHovered']&&0x0===_0x159304['event']['button']&&_0xbbae72['onClickedObservable']['notifyObservers'](_0xbbae72['_camera']));},_0x1cb628['a']['POINTERDOWN']),_0xbbae72;}return Object(_0x18e13d['d'])(_0x539e30,_0x24d9a9),Object['defineProperty'](_0x539e30['prototype'],'displayFrustum',{'get':function(){return this['_cameraLinesMesh']['isEnabled']();},'set':function(_0x1df96c){this['_cameraLinesMesh']['setEnabled'](_0x1df96c);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x539e30['prototype'],'camera',{'get':function(){return this['_camera'];},'set':function(_0x3ea11c){var _0x54c9e4=this;if(this['_camera']=_0x3ea11c,this['attachedNode']=_0x3ea11c,_0x3ea11c){this['_cameraMesh']&&this['_cameraMesh']['dispose'](),this['_cameraLinesMesh']&&this['_cameraLinesMesh']['dispose'](),this['_cameraMesh']=_0x539e30['_CreateCameraMesh'](this['gizmoLayer']['utilityLayerScene']),this['_cameraLinesMesh']=_0x539e30['_CreateCameraFrustum'](this['gizmoLayer']['utilityLayerScene']),this['_cameraMesh']['getChildMeshes'](!0x1)['forEach'](function(_0x14bbee){_0x14bbee['material']=_0x54c9e4['_material'];}),this['_cameraMesh']['parent']=this['_rootMesh'],this['_cameraLinesMesh']['parent']=this['_rootMesh'],this['gizmoLayer']['utilityLayerScene']['activeCamera']&&this['gizmoLayer']['utilityLayerScene']['activeCamera']['maxZ']<1.5*_0x3ea11c['maxZ']&&(this['gizmoLayer']['utilityLayerScene']['activeCamera']['maxZ']=1.5*_0x3ea11c['maxZ']),this['attachedNode']['reservedDataStore']||(this['attachedNode']['reservedDataStore']={}),this['attachedNode']['reservedDataStore']['cameraGizmo']=this;var _0x1695a5=this['gizmoLayer']['_getSharedGizmoLight']();_0x1695a5['includedOnlyMeshes']=_0x1695a5['includedOnlyMeshes']['concat'](this['_cameraMesh']['getChildMeshes'](!0x1)),this['_update']();}},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x539e30['prototype'],'material',{'get':function(){return this['_material'];},'enumerable':!0x1,'configurable':!0x0}),_0x539e30['prototype']['_update']=function(){_0x24d9a9['prototype']['_update']['call'](this),this['_camera']&&(this['_camera']['getProjectionMatrix']()['invertToRef'](this['_invProjection']),this['_cameraLinesMesh']['setPivotMatrix'](this['_invProjection'],!0x1),this['_cameraLinesMesh']['scaling']['x']=0x1/this['_rootMesh']['scaling']['x'],this['_cameraLinesMesh']['scaling']['y']=0x1/this['_rootMesh']['scaling']['y'],this['_cameraLinesMesh']['scaling']['z']=0x1/this['_rootMesh']['scaling']['z'],this['_cameraMesh']['parent']=null,this['_cameraMesh']['rotation']['y']=0.5*Math['PI']*(this['_camera']['getScene']()['useRightHandedSystem']?0x1:-0x1),this['_cameraMesh']['parent']=this['_rootMesh']);},_0x539e30['prototype']['dispose']=function(){this['onClickedObservable']['clear'](),this['gizmoLayer']['utilityLayerScene']['onPointerObservable']['remove'](this['_pointerObserver']),this['_cameraMesh']&&this['_cameraMesh']['dispose'](),this['_cameraLinesMesh']&&this['_cameraLinesMesh']['dispose'](),this['_material']['dispose'](),_0x24d9a9['prototype']['dispose']['call'](this);},_0x539e30['_CreateCameraMesh']=function(_0x4988a3){var _0x892292=new _0x3cf5e5['a']('rootCameraGizmo',_0x4988a3),_0x392c7f=new _0x3cf5e5['a'](_0x892292['name'],_0x4988a3);_0x392c7f['parent']=_0x892292,_0x144742['a']['CreateBox'](_0x892292['name'],{'width':0x1,'height':0.8,'depth':0.5},_0x4988a3)['parent']=_0x392c7f;var _0x313ef7=_0x179064['a']['CreateCylinder'](_0x892292['name'],{'height':0.5,'diameterTop':0.8,'diameterBottom':0.8},_0x4988a3);_0x313ef7['parent']=_0x392c7f,_0x313ef7['position']['y']=0.3,_0x313ef7['position']['x']=-0.6,_0x313ef7['rotation']['x']=0.5*Math['PI'];var _0x365f14=_0x179064['a']['CreateCylinder'](_0x892292['name'],{'height':0.5,'diameterTop':0.6,'diameterBottom':0.6},_0x4988a3);_0x365f14['parent']=_0x392c7f,_0x365f14['position']['y']=0.5,_0x365f14['position']['x']=0.4,_0x365f14['rotation']['x']=0.5*Math['PI'];var _0x5634ec=_0x179064['a']['CreateCylinder'](_0x892292['name'],{'height':0.5,'diameterTop':0.5,'diameterBottom':0.5},_0x4988a3);return _0x5634ec['parent']=_0x392c7f,_0x5634ec['position']['y']=0x0,_0x5634ec['position']['x']=0.6,_0x5634ec['rotation']['z']=0.5*Math['PI'],_0x892292['scaling']['scaleInPlace'](_0x539e30['_Scale']),_0x392c7f['position']['x']=-0.9,_0x892292;},_0x539e30['_CreateCameraFrustum']=function(_0x517d80){var _0x55e06f=new _0x3cf5e5['a']('rootCameraGizmo',_0x517d80),_0x5cc93c=new _0x3cf5e5['a'](_0x55e06f['name'],_0x517d80);_0x5cc93c['parent']=_0x55e06f;for(var _0x285bbd=0x0;_0x285bbd<0x4;_0x285bbd+=0x2)for(var _0x33074e=0x0;_0x33074e<0x4;_0x33074e+=0x2){var _0x4d4af9;(_0x4d4af9=_0x333a74['a']['CreateLines']('lines',{'points':[new _0x74d525['e'](-0x1+_0x33074e,-0x1+_0x285bbd,-0x1),new _0x74d525['e'](-0x1+_0x33074e,-0x1+_0x285bbd,0x1)]},_0x517d80))['parent']=_0x5cc93c,_0x4d4af9['alwaysSelectAsActiveMesh']=!0x0,_0x4d4af9['isPickable']=!0x1,(_0x4d4af9=_0x333a74['a']['CreateLines']('lines',{'points':[new _0x74d525['e'](-0x1,-0x1+_0x33074e,-0x1+_0x285bbd),new _0x74d525['e'](0x1,-0x1+_0x33074e,-0x1+_0x285bbd)]},_0x517d80))['parent']=_0x5cc93c,_0x4d4af9['alwaysSelectAsActiveMesh']=!0x0,_0x4d4af9['isPickable']=!0x1,(_0x4d4af9=_0x333a74['a']['CreateLines']('lines',{'points':[new _0x74d525['e'](-0x1+_0x33074e,-0x1,-0x1+_0x285bbd),new _0x74d525['e'](-0x1+_0x33074e,0x1,-0x1+_0x285bbd)]},_0x517d80))['parent']=_0x5cc93c,_0x4d4af9['alwaysSelectAsActiveMesh']=!0x0,_0x4d4af9['isPickable']=!0x1;}return _0x55e06f;},_0x539e30['_Scale']=0.05,_0x539e30;}(_0x417dc8['a']);_0x494b01['a']['IncludesShadersStore']['kernelBlurVaryingDeclaration']='varying\x20vec2\x20sampleCoord{X};';var _0x45167f='vec4\x20pack(float\x20depth)\x0a{\x0aconst\x20vec4\x20bit_shift=vec4(255.0*255.0*255.0,255.0*255.0,255.0,1.0);\x0aconst\x20vec4\x20bit_mask=vec4(0.0,1.0/255.0,1.0/255.0,1.0/255.0);\x0avec4\x20res=fract(depth*bit_shift);\x0ares-=res.xxyz*bit_mask;\x0areturn\x20res;\x0a}\x0afloat\x20unpack(vec4\x20color)\x0a{\x0aconst\x20vec4\x20bit_shift=vec4(1.0/(255.0*255.0*255.0),1.0/(255.0*255.0),1.0/255.0,1.0);\x0areturn\x20dot(color,bit_shift);\x0a}';_0x494b01['a']['IncludesShadersStore']['packingFunctions']=_0x45167f;var _0xe7e9c0='#ifdef\x20DOF\x0afactor=sampleCoC(sampleCoord{X});\x0acomputedWeight=KERNEL_WEIGHT{X}*factor;\x0asumOfWeights+=computedWeight;\x0a#else\x0acomputedWeight=KERNEL_WEIGHT{X};\x0a#endif\x0a#ifdef\x20PACKEDFLOAT\x0ablend+=unpack(texture2D(textureSampler,sampleCoord{X}))*computedWeight;\x0a#else\x0ablend+=texture2D(textureSampler,sampleCoord{X})*computedWeight;\x0a#endif';_0x494b01['a']['IncludesShadersStore']['kernelBlurFragment']=_0xe7e9c0;var _0x39a3d8='#ifdef\x20DOF\x0afactor=sampleCoC(sampleCenter+delta*KERNEL_DEP_OFFSET{X});\x0acomputedWeight=KERNEL_DEP_WEIGHT{X}*factor;\x0asumOfWeights+=computedWeight;\x0a#else\x0acomputedWeight=KERNEL_DEP_WEIGHT{X};\x0a#endif\x0a#ifdef\x20PACKEDFLOAT\x0ablend+=unpack(texture2D(textureSampler,sampleCenter+delta*KERNEL_DEP_OFFSET{X}))*computedWeight;\x0a#else\x0ablend+=texture2D(textureSampler,sampleCenter+delta*KERNEL_DEP_OFFSET{X})*computedWeight;\x0a#endif';_0x494b01['a']['IncludesShadersStore']['kernelBlurFragment2']=_0x39a3d8;var _0x420540='\x0auniform\x20sampler2D\x20textureSampler;\x0auniform\x20vec2\x20delta;\x0a\x0avarying\x20vec2\x20sampleCenter;\x0a#ifdef\x20DOF\x0auniform\x20sampler2D\x20circleOfConfusionSampler;\x0auniform\x20vec2\x20cameraMinMaxZ;\x0afloat\x20sampleDistance(const\x20in\x20vec2\x20offset)\x20{\x0afloat\x20depth=texture2D(circleOfConfusionSampler,offset).g;\x0areturn\x20cameraMinMaxZ.x+(cameraMinMaxZ.y-cameraMinMaxZ.x)*depth;\x0a}\x0afloat\x20sampleCoC(const\x20in\x20vec2\x20offset)\x20{\x0afloat\x20coc=texture2D(circleOfConfusionSampler,offset).r;\x0areturn\x20coc;\x0a}\x0a#endif\x0a#include[0..varyingCount]\x0a#ifdef\x20PACKEDFLOAT\x0a#include\x0a#endif\x0avoid\x20main(void)\x0a{\x0afloat\x20computedWeight=0.0;\x0a#ifdef\x20PACKEDFLOAT\x0afloat\x20blend=0.;\x0a#else\x0avec4\x20blend=vec4(0.);\x0a#endif\x0a#ifdef\x20DOF\x0afloat\x20sumOfWeights=CENTER_WEIGHT;\x0afloat\x20factor=0.0;\x0a\x0a#ifdef\x20PACKEDFLOAT\x0ablend+=unpack(texture2D(textureSampler,sampleCenter))*CENTER_WEIGHT;\x0a#else\x0ablend+=texture2D(textureSampler,sampleCenter)*CENTER_WEIGHT;\x0a#endif\x0a#endif\x0a#include[0..varyingCount]\x0a#include[0..depCount]\x0a#ifdef\x20PACKEDFLOAT\x0agl_FragColor=pack(blend);\x0a#else\x0agl_FragColor=blend;\x0a#endif\x0a#ifdef\x20DOF\x0agl_FragColor/=sumOfWeights;\x0a#endif\x0a}';_0x494b01['a']['ShadersStore']['kernelBlurPixelShader']=_0x420540,_0x494b01['a']['IncludesShadersStore']['kernelBlurVertex']='sampleCoord{X}=sampleCenter+delta*KERNEL_OFFSET{X};';var _0x15cb8e='\x0aattribute\x20vec2\x20position;\x0a\x0auniform\x20vec2\x20delta;\x0a\x0avarying\x20vec2\x20sampleCenter;\x0a#include[0..varyingCount]\x0aconst\x20vec2\x20madd=vec2(0.5,0.5);\x0avoid\x20main(void)\x20{\x0asampleCenter=(position*madd+madd);\x0a#include[0..varyingCount]\x0agl_Position=vec4(position,0.0,1.0);\x0a}';_0x494b01['a']['ShadersStore']['kernelBlurVertexShader']=_0x15cb8e;var _0x487d78=function(_0x4b9b41){function _0x52ff5f(_0x6f4fbe,_0x390775,_0x338ea4,_0x169970,_0x260e74,_0x3a44d3,_0x12bb47,_0x46d233,_0x2252ae,_0x383369,_0x53366a){void 0x0===_0x3a44d3&&(_0x3a44d3=_0xaf3c80['a']['BILINEAR_SAMPLINGMODE']),void 0x0===_0x2252ae&&(_0x2252ae=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),void 0x0===_0x383369&&(_0x383369=''),void 0x0===_0x53366a&&(_0x53366a=!0x1);var _0x2597e0=_0x4b9b41['call'](this,_0x6f4fbe,'kernelBlur',['delta','direction','cameraMinMaxZ'],['circleOfConfusionSampler'],_0x169970,_0x260e74,_0x3a44d3,_0x12bb47,_0x46d233,null,_0x2252ae,'kernelBlur',{'varyingCount':0x0,'depCount':0x0},!0x0)||this;return _0x2597e0['blockCompilation']=_0x53366a,_0x2597e0['_packedFloat']=!0x1,_0x2597e0['_staticDefines']='',_0x2597e0['_staticDefines']=_0x383369,_0x2597e0['direction']=_0x390775,_0x2597e0['onApplyObservable']['add'](function(_0x1a4477){_0x2597e0['_outputTexture']?_0x1a4477['setFloat2']('delta',0x1/_0x2597e0['_outputTexture']['width']*_0x2597e0['direction']['x'],0x1/_0x2597e0['_outputTexture']['height']*_0x2597e0['direction']['y']):_0x1a4477['setFloat2']('delta',0x1/_0x2597e0['width']*_0x2597e0['direction']['x'],0x1/_0x2597e0['height']*_0x2597e0['direction']['y']);}),_0x2597e0['kernel']=_0x338ea4,_0x2597e0;}return Object(_0x18e13d['d'])(_0x52ff5f,_0x4b9b41),Object['defineProperty'](_0x52ff5f['prototype'],'kernel',{'get':function(){return this['_idealKernel'];},'set':function(_0x1b6045){this['_idealKernel']!==_0x1b6045&&(_0x1b6045=Math['max'](_0x1b6045,0x1),this['_idealKernel']=_0x1b6045,this['_kernel']=this['_nearestBestKernel'](_0x1b6045),this['blockCompilation']||this['_updateParameters']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x52ff5f['prototype'],'packedFloat',{'get':function(){return this['_packedFloat'];},'set':function(_0x5243a0){this['_packedFloat']!==_0x5243a0&&(this['_packedFloat']=_0x5243a0,this['blockCompilation']||this['_updateParameters']());},'enumerable':!0x1,'configurable':!0x0}),_0x52ff5f['prototype']['getClassName']=function(){return'BlurPostProcess';},_0x52ff5f['prototype']['updateEffect']=function(_0x478874,_0x4d3100,_0xc64be2,_0xcc53e6,_0x3e6c85,_0x10ae5a){void 0x0===_0x478874&&(_0x478874=null),void 0x0===_0x4d3100&&(_0x4d3100=null),void 0x0===_0xc64be2&&(_0xc64be2=null),this['_updateParameters'](_0x3e6c85,_0x10ae5a);},_0x52ff5f['prototype']['_updateParameters']=function(_0x5d7822,_0x29d393){for(var _0x38f369=this['_kernel'],_0x466700=(_0x38f369-0x1)/0x2,_0x296e15=[],_0x3c8844=[],_0x4dc6f1=0x0,_0x82a103=0x0;_0x82a103<_0x38f369;_0x82a103++){var _0x11c407=_0x82a103/(_0x38f369-0x1),_0x415e53=this['_gaussianWeight'](0x2*_0x11c407-0x1);_0x296e15[_0x82a103]=_0x82a103-_0x466700,_0x3c8844[_0x82a103]=_0x415e53,_0x4dc6f1+=_0x415e53;}for(_0x82a103=0x0;_0x82a103<_0x3c8844['length'];_0x82a103++)_0x3c8844[_0x82a103]/=_0x4dc6f1;var _0x2655eb=[],_0x1f8b3c=[],_0xba6c3b=[];for(_0x82a103=0x0;_0x82a103<=_0x466700;_0x82a103+=0x2){var _0x206a7=Math['min'](_0x82a103+0x1,Math['floor'](_0x466700));if(_0x82a103===_0x206a7)_0xba6c3b['push']({'o':_0x296e15[_0x82a103],'w':_0x3c8844[_0x82a103]});else{var _0x3d91b8=_0x206a7===_0x466700,_0x42d4f3=_0x3c8844[_0x82a103]+_0x3c8844[_0x206a7]*(_0x3d91b8?0.5:0x1),_0xc453b4=_0x296e15[_0x82a103]+0x1/(0x1+_0x3c8844[_0x82a103]/_0x3c8844[_0x206a7]);0x0===_0xc453b4?(_0xba6c3b['push']({'o':_0x296e15[_0x82a103],'w':_0x3c8844[_0x82a103]}),_0xba6c3b['push']({'o':_0x296e15[_0x82a103+0x1],'w':_0x3c8844[_0x82a103+0x1]})):(_0xba6c3b['push']({'o':_0xc453b4,'w':_0x42d4f3}),_0xba6c3b['push']({'o':-_0xc453b4,'w':_0x42d4f3}));}}for(_0x82a103=0x0;_0x82a103<_0xba6c3b['length'];_0x82a103++)_0x1f8b3c[_0x82a103]=_0xba6c3b[_0x82a103]['o'],_0x2655eb[_0x82a103]=_0xba6c3b[_0x82a103]['w'];_0x296e15=_0x1f8b3c,_0x3c8844=_0x2655eb;var _0x191efa=this['getEngine']()['getCaps']()['maxVaryingVectors'],_0x560fda=Math['max'](_0x191efa,0x0)-0x1,_0x126e3b=Math['min'](_0x296e15['length'],_0x560fda),_0x8785f0='';_0x8785f0+=this['_staticDefines'],-0x1!=this['_staticDefines']['indexOf']('DOF')&&(_0x8785f0+='#define\x20CENTER_WEIGHT\x20'+this['_glslFloat'](_0x3c8844[_0x126e3b-0x1])+'\x0d\x0a',_0x126e3b--);for(_0x82a103=0x0;_0x82a103<_0x126e3b;_0x82a103++)_0x8785f0+='#define\x20KERNEL_OFFSET'+_0x82a103+'\x20'+this['_glslFloat'](_0x296e15[_0x82a103])+'\x0d\x0a',_0x8785f0+='#define\x20KERNEL_WEIGHT'+_0x82a103+'\x20'+this['_glslFloat'](_0x3c8844[_0x82a103])+'\x0d\x0a';var _0x4d331a=0x0;for(_0x82a103=_0x560fda;_0x82a103<_0x296e15['length'];_0x82a103++)_0x8785f0+='#define\x20KERNEL_DEP_OFFSET'+_0x4d331a+'\x20'+this['_glslFloat'](_0x296e15[_0x82a103])+'\x0d\x0a',_0x8785f0+='#define\x20KERNEL_DEP_WEIGHT'+_0x4d331a+'\x20'+this['_glslFloat'](_0x3c8844[_0x82a103])+'\x0d\x0a',_0x4d331a++;this['packedFloat']&&(_0x8785f0+='#define\x20PACKEDFLOAT\x201'),this['blockCompilation']=!0x1,_0x4b9b41['prototype']['updateEffect']['call'](this,_0x8785f0,null,null,{'varyingCount':_0x126e3b,'depCount':_0x4d331a},_0x5d7822,_0x29d393);},_0x52ff5f['prototype']['_nearestBestKernel']=function(_0x43e74c){for(var _0x32f4c2=Math['round'](_0x43e74c),_0x36aff7=0x0,_0x3546d7=[_0x32f4c2,_0x32f4c2-0x1,_0x32f4c2+0x1,_0x32f4c2-0x2,_0x32f4c2+0x2];_0x36aff7<_0x3546d7['length'];_0x36aff7++){var _0x573c16=_0x3546d7[_0x36aff7];if(_0x573c16%0x2!=0x0&&Math['floor'](_0x573c16/0x2)%0x2==0x0&&_0x573c16>0x0)return Math['max'](_0x573c16,0x3);}return Math['max'](_0x32f4c2,0x3);},_0x52ff5f['prototype']['_gaussianWeight']=function(_0x56cdbe){var _0x391e3c=-_0x56cdbe*_0x56cdbe/(0x1/0x3*0x2*(0x1/0x3));return 0x1/(Math['sqrt'](0x2*Math['PI'])*(0x1/0x3))*Math['exp'](_0x391e3c);},_0x52ff5f['prototype']['_glslFloat']=function(_0x59abf1,_0x16393c){return void 0x0===_0x16393c&&(_0x16393c=0x8),_0x59abf1['toFixed'](_0x16393c)['replace'](/0+$/,'');},_0x52ff5f['_Parse']=function(_0x363c77,_0x2a82ca,_0x153e79,_0x346b57){return _0x495d06['a']['Parse'](function(){return new _0x52ff5f(_0x363c77['name'],_0x363c77['direction'],_0x363c77['kernel'],_0x363c77['options'],_0x2a82ca,_0x363c77['renderTargetSamplingMode'],_0x153e79['getEngine'](),_0x363c77['reusable'],_0x363c77['textureType'],void 0x0,!0x1);},_0x363c77,_0x153e79,_0x346b57);},Object(_0x18e13d['c'])([Object(_0x495d06['c'])('kernel')],_0x52ff5f['prototype'],'_kernel',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])('packedFloat')],_0x52ff5f['prototype'],'_packedFloat',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['n'])()],_0x52ff5f['prototype'],'direction',void 0x0),_0x52ff5f;}(_0x5cae84);_0x3cd573['a']['RegisteredTypes']['BABYLON.BlurPostProcess']=_0x487d78;var _0xb1e723=function(_0xd9b733){function _0x2eaa62(_0xba980e,_0xe4f5b3,_0x3053dc,_0x3b7f30,_0x2086b0,_0xc213ea,_0x50fdff){void 0x0===_0x2086b0&&(_0x2086b0=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),void 0x0===_0xc213ea&&(_0xc213ea=_0xaf3c80['a']['BILINEAR_SAMPLINGMODE']),void 0x0===_0x50fdff&&(_0x50fdff=!0x0);var _0xbbc670=_0xd9b733['call'](this,_0xba980e,_0xe4f5b3,_0x3053dc,_0x3b7f30,!0x0,_0x2086b0,!0x1,_0xc213ea,_0x50fdff)||this;return _0xbbc670['scene']=_0x3053dc,_0xbbc670['mirrorPlane']=new _0x5c8dd6['a'](0x0,0x1,0x0,0x1),_0xbbc670['_transformMatrix']=_0x74d525['a']['Zero'](),_0xbbc670['_mirrorMatrix']=_0x74d525['a']['Zero'](),_0xbbc670['_adaptiveBlurKernel']=0x0,_0xbbc670['_blurKernelX']=0x0,_0xbbc670['_blurKernelY']=0x0,_0xbbc670['_blurRatio']=0x1,_0xbbc670['ignoreCameraViewport']=!0x0,_0xbbc670['_updateGammaSpace'](),_0xbbc670['_imageProcessingConfigChangeObserver']=_0x3053dc['imageProcessingConfiguration']['onUpdateParameters']['add'](function(){_0xbbc670['_updateGammaSpace'];}),_0xbbc670['onBeforeRenderObservable']['add'](function(){_0x74d525['a']['ReflectionToRef'](_0xbbc670['mirrorPlane'],_0xbbc670['_mirrorMatrix']),_0xbbc670['_savedViewMatrix']=_0x3053dc['getViewMatrix'](),_0xbbc670['_mirrorMatrix']['multiplyToRef'](_0xbbc670['_savedViewMatrix'],_0xbbc670['_transformMatrix']),_0x3053dc['setTransformMatrix'](_0xbbc670['_transformMatrix'],_0x3053dc['getProjectionMatrix']()),_0x3053dc['clipPlane']=_0xbbc670['mirrorPlane'],_0x3053dc['getEngine']()['cullBackFaces']=!0x1,_0x3053dc['_mirroredCameraPosition']=_0x74d525['e']['TransformCoordinates'](_0x3053dc['activeCamera']['globalPosition'],_0xbbc670['_mirrorMatrix']);}),_0xbbc670['onAfterRenderObservable']['add'](function(){_0x3053dc['setTransformMatrix'](_0xbbc670['_savedViewMatrix'],_0x3053dc['getProjectionMatrix']()),_0x3053dc['getEngine']()['cullBackFaces']=!0x0,_0x3053dc['_mirroredCameraPosition']=null,_0x3053dc['clipPlane']=null;}),_0xbbc670;}return Object(_0x18e13d['d'])(_0x2eaa62,_0xd9b733),Object['defineProperty'](_0x2eaa62['prototype'],'blurRatio',{'get':function(){return this['_blurRatio'];},'set':function(_0x5763bf){this['_blurRatio']!==_0x5763bf&&(this['_blurRatio']=_0x5763bf,this['_preparePostProcesses']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2eaa62['prototype'],'adaptiveBlurKernel',{'set':function(_0x531fda){this['_adaptiveBlurKernel']=_0x531fda,this['_autoComputeBlurKernel']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2eaa62['prototype'],'blurKernel',{'set':function(_0x3eeb43){this['blurKernelX']=_0x3eeb43,this['blurKernelY']=_0x3eeb43;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2eaa62['prototype'],'blurKernelX',{'get':function(){return this['_blurKernelX'];},'set':function(_0x32715a){this['_blurKernelX']!==_0x32715a&&(this['_blurKernelX']=_0x32715a,this['_preparePostProcesses']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2eaa62['prototype'],'blurKernelY',{'get':function(){return this['_blurKernelY'];},'set':function(_0x2a5735){this['_blurKernelY']!==_0x2a5735&&(this['_blurKernelY']=_0x2a5735,this['_preparePostProcesses']());},'enumerable':!0x1,'configurable':!0x0}),_0x2eaa62['prototype']['_autoComputeBlurKernel']=function(){var _0x2f7244=this['getScene']()['getEngine'](),_0xe24125=this['getRenderWidth']()/_0x2f7244['getRenderWidth'](),_0x5785b5=this['getRenderHeight']()/_0x2f7244['getRenderHeight']();this['blurKernelX']=this['_adaptiveBlurKernel']*_0xe24125,this['blurKernelY']=this['_adaptiveBlurKernel']*_0x5785b5;},_0x2eaa62['prototype']['_onRatioRescale']=function(){this['_sizeRatio']&&(this['resize'](this['_initialSizeParameter']),this['_adaptiveBlurKernel']||this['_preparePostProcesses']()),this['_adaptiveBlurKernel']&&this['_autoComputeBlurKernel']();},_0x2eaa62['prototype']['_updateGammaSpace']=function(){this['gammaSpace']=!this['scene']['imageProcessingConfiguration']['isEnabled']||!this['scene']['imageProcessingConfiguration']['applyByPostProcess'];},_0x2eaa62['prototype']['_preparePostProcesses']=function(){if(this['clearPostProcesses'](!0x0),this['_blurKernelX']&&this['_blurKernelY']){var _0x59a3c0=this['getScene']()['getEngine'](),_0x1ad3c5=_0x59a3c0['getCaps']()['textureFloatRender']?_0x2103ba['a']['TEXTURETYPE_FLOAT']:_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT'];this['_blurX']=new _0x487d78('horizontal\x20blur',new _0x74d525['d'](0x1,0x0),this['_blurKernelX'],this['_blurRatio'],null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x59a3c0,!0x1,_0x1ad3c5),this['_blurX']['autoClear']=!0x1,0x1===this['_blurRatio']&&this['samples']<0x2&&this['_texture']?this['_blurX']['inputTexture']=this['_texture']:this['_blurX']['alwaysForcePOT']=!0x0,this['_blurY']=new _0x487d78('vertical\x20blur',new _0x74d525['d'](0x0,0x1),this['_blurKernelY'],this['_blurRatio'],null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x59a3c0,!0x1,_0x1ad3c5),this['_blurY']['autoClear']=!0x1,this['_blurY']['alwaysForcePOT']=0x1!==this['_blurRatio'],this['addPostProcess'](this['_blurX']),this['addPostProcess'](this['_blurY']);}else this['_blurY']&&(this['removePostProcess'](this['_blurY']),this['_blurY']['dispose'](),this['_blurY']=null),this['_blurX']&&(this['removePostProcess'](this['_blurX']),this['_blurX']['dispose'](),this['_blurX']=null);},_0x2eaa62['prototype']['clone']=function(){var _0x5e17f6=this['getScene']();if(!_0x5e17f6)return this;var _0x1084f3=this['getSize'](),_0x42cfa9=new _0x2eaa62(this['name'],_0x1084f3['width'],_0x5e17f6,this['_renderTargetOptions']['generateMipMaps'],this['_renderTargetOptions']['type'],this['_renderTargetOptions']['samplingMode'],this['_renderTargetOptions']['generateDepthBuffer']);return _0x42cfa9['hasAlpha']=this['hasAlpha'],_0x42cfa9['level']=this['level'],_0x42cfa9['mirrorPlane']=this['mirrorPlane']['clone'](),this['renderList']&&(_0x42cfa9['renderList']=this['renderList']['slice'](0x0)),_0x42cfa9;},_0x2eaa62['prototype']['serialize']=function(){if(!this['name'])return null;var _0x52c7f4=_0xd9b733['prototype']['serialize']['call'](this);return _0x52c7f4['mirrorPlane']=this['mirrorPlane']['asArray'](),_0x52c7f4;},_0x2eaa62['prototype']['dispose']=function(){_0xd9b733['prototype']['dispose']['call'](this),this['scene']['imageProcessingConfiguration']['onUpdateParameters']['remove'](this['_imageProcessingConfigChangeObserver']);},_0x2eaa62;}(_0x310f87);_0xaf3c80['a']['_CreateMirror']=function(_0x2fccd4,_0x493a03,_0x4657c9,_0x36fe1d){return new _0xb1e723(_0x2fccd4,_0x493a03,_0x4657c9,_0x36fe1d);};var _0x5950ed=_0x162675(0x22),_0x33892f=function(_0x225f0d){function _0xc0c15f(_0x378bf2,_0x1fe8bb,_0x5ebd94,_0x1740ed,_0x205646,_0x4654cd,_0x27d271,_0x370a98,_0x3e5804,_0x223853,_0x254ed0,_0x9c7436,_0x392faf,_0x25be2b){var _0x5b99a1;void 0x0===_0x5ebd94&&(_0x5ebd94=null),void 0x0===_0x1740ed&&(_0x1740ed=!0x1),void 0x0===_0x205646&&(_0x205646=null),void 0x0===_0x4654cd&&(_0x4654cd=null),void 0x0===_0x27d271&&(_0x27d271=null),void 0x0===_0x370a98&&(_0x370a98=_0x2103ba['a']['TEXTUREFORMAT_RGBA']),void 0x0===_0x3e5804&&(_0x3e5804=!0x1),void 0x0===_0x223853&&(_0x223853=null),void 0x0===_0x254ed0&&(_0x254ed0=!0x1),void 0x0===_0x9c7436&&(_0x9c7436=0.8),void 0x0===_0x392faf&&(_0x392faf=0x0);var _0xefc59c=_0x225f0d['call'](this,_0x1fe8bb)||this;if(_0xefc59c['onLoadObservable']=new _0x6ac1f7['c'](),_0xefc59c['boundingBoxPosition']=_0x74d525['e']['Zero'](),_0xefc59c['_rotationY']=0x0,_0xefc59c['_files']=null,_0xefc59c['_forcedExtension']=null,_0xefc59c['_extensions']=null,_0xefc59c['name']=_0x378bf2,_0xefc59c['url']=_0x378bf2,_0xefc59c['_noMipmap']=_0x1740ed,_0xefc59c['hasAlpha']=!0x1,_0xefc59c['_format']=_0x370a98,_0xefc59c['isCube']=!0x0,_0xefc59c['_textureMatrix']=_0x74d525['a']['Identity'](),_0xefc59c['_createPolynomials']=_0x254ed0,_0xefc59c['coordinatesMode']=_0xaf3c80['a']['CUBIC_MODE'],_0xefc59c['_extensions']=_0x5ebd94,_0xefc59c['_files']=_0x205646,_0xefc59c['_forcedExtension']=_0x223853,_0xefc59c['_loaderOptions']=_0x25be2b,!_0x378bf2&&!_0x205646)return _0xefc59c;var _0x394655=_0x378bf2['lastIndexOf']('.'),_0x24e20b=_0x223853||(_0x394655>-0x1?_0x378bf2['substring'](_0x394655)['toLowerCase']():''),_0x29ce1e='.dds'===_0x24e20b,_0x1cabcb='.env'===_0x24e20b;if(_0x1cabcb?(_0xefc59c['gammaSpace']=!0x1,_0xefc59c['_prefiltered']=!0x1,_0xefc59c['anisotropicFilteringLevel']=0x1):(_0xefc59c['_prefiltered']=_0x3e5804,_0x3e5804&&(_0xefc59c['gammaSpace']=!0x1,_0xefc59c['anisotropicFilteringLevel']=0x1)),_0xefc59c['_texture']=_0xefc59c['_getFromCache'](_0x378bf2,_0x1740ed),!_0x205646&&(_0x1cabcb||_0x29ce1e||_0x5ebd94||(_0x5ebd94=['_px.jpg','_py.jpg','_pz.jpg','_nx.jpg','_ny.jpg','_nz.jpg']),_0x205646=[],_0x5ebd94)){for(var _0x51e9cf=0x0;_0x51e9cf<_0x5ebd94['length'];_0x51e9cf++)_0x205646['push'](_0x378bf2+_0x5ebd94[_0x51e9cf]);}_0xefc59c['_files']=_0x205646;var _0x170144=function(){_0xefc59c['onLoadObservable']['notifyObservers'](_0xefc59c),_0x4654cd&&_0x4654cd();};if(_0xefc59c['_texture'])_0xefc59c['_texture']['isReady']?_0x5d754c['b']['SetImmediate'](function(){return _0x170144();}):_0xefc59c['_texture']['onLoadedObservable']['add'](function(){return _0x170144();});else{var _0x3db969=_0xefc59c['getScene']();(null==_0x3db969?void 0x0:_0x3db969['useDelayedTextureLoading'])?_0xefc59c['delayLoadState']=_0x2103ba['a']['DELAYLOADSTATE_NOTLOADED']:(_0xefc59c['_texture']=_0x3e5804?_0xefc59c['_getEngine']()['createPrefilteredCubeTexture'](_0x378bf2,_0x3db969,_0x9c7436,_0x392faf,_0x4654cd,_0x27d271,_0x370a98,_0x223853,_0xefc59c['_createPolynomials']):_0xefc59c['_getEngine']()['createCubeTexture'](_0x378bf2,_0x3db969,_0x205646,_0x1740ed,_0x4654cd,_0x27d271,_0xefc59c['_format'],_0x223853,!0x1,_0x9c7436,_0x392faf,null,_0x25be2b),null===(_0x5b99a1=_0xefc59c['_texture'])||void 0x0===_0x5b99a1||_0x5b99a1['onLoadedObservable']['add'](function(){return _0xefc59c['onLoadObservable']['notifyObservers'](_0xefc59c);}));}return _0xefc59c;}return Object(_0x18e13d['d'])(_0xc0c15f,_0x225f0d),Object['defineProperty'](_0xc0c15f['prototype'],'boundingBoxSize',{'get':function(){return this['_boundingBoxSize'];},'set':function(_0x9550bf){if(!this['_boundingBoxSize']||!this['_boundingBoxSize']['equals'](_0x9550bf)){this['_boundingBoxSize']=_0x9550bf;var _0xc38e07=this['getScene']();_0xc38e07&&_0xc38e07['markAllMaterialsAsDirty'](_0x2103ba['a']['MATERIAL_TextureDirtyFlag']);}},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xc0c15f['prototype'],'rotationY',{'get':function(){return this['_rotationY'];},'set':function(_0x4e2f37){this['_rotationY']=_0x4e2f37,this['setReflectionTextureMatrix'](_0x74d525['a']['RotationY'](this['_rotationY']));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xc0c15f['prototype'],'noMipmap',{'get':function(){return this['_noMipmap'];},'enumerable':!0x1,'configurable':!0x0}),_0xc0c15f['CreateFromImages']=function(_0x33d836,_0x41cd00,_0x1f9168){var _0x3378bd='';return _0x33d836['forEach'](function(_0x2a0a74){return _0x3378bd+=_0x2a0a74;}),new _0xc0c15f(_0x3378bd,_0x41cd00,null,_0x1f9168,_0x33d836);},_0xc0c15f['CreateFromPrefilteredData']=function(_0x1fd716,_0x57e34f,_0x4c128b,_0x212d21){void 0x0===_0x4c128b&&(_0x4c128b=null),void 0x0===_0x212d21&&(_0x212d21=!0x0);var _0x4326a3=_0x57e34f['useDelayedTextureLoading'];_0x57e34f['useDelayedTextureLoading']=!0x1;var _0x105863=new _0xc0c15f(_0x1fd716,_0x57e34f,null,!0x1,null,null,null,void 0x0,!0x0,_0x4c128b,_0x212d21);return _0x57e34f['useDelayedTextureLoading']=_0x4326a3,_0x105863;},_0xc0c15f['prototype']['getClassName']=function(){return'CubeTexture';},_0xc0c15f['prototype']['updateURL']=function(_0x647950,_0x4119a8,_0x7fb654,_0x2eb1c7){var _0x36b13b;void 0x0===_0x2eb1c7&&(_0x2eb1c7=!0x1),this['url']&&(this['releaseInternalTexture'](),null===(_0x36b13b=this['getScene']())||void 0x0===_0x36b13b||_0x36b13b['markAllMaterialsAsDirty'](_0x2103ba['a']['MATERIAL_TextureDirtyFlag'])),this['name']&&!_0x5950ed['a']['StartsWith'](this['name'],'data:')||(this['name']=_0x647950),this['url']=_0x647950,this['delayLoadState']=_0x2103ba['a']['DELAYLOADSTATE_NOTLOADED'],this['_prefiltered']=_0x2eb1c7,this['_prefiltered']&&(this['gammaSpace']=!0x1,this['anisotropicFilteringLevel']=0x1),this['_forcedExtension']=_0x4119a8||null,_0x7fb654&&(this['_delayedOnLoad']=_0x7fb654),this['delayLoad'](_0x4119a8);},_0xc0c15f['prototype']['delayLoad']=function(_0x52d430){var _0x3b80f5,_0x2cdac9=this;if(this['delayLoadState']===_0x2103ba['a']['DELAYLOADSTATE_NOTLOADED']&&(this['delayLoadState']=_0x2103ba['a']['DELAYLOADSTATE_LOADED'],this['_texture']=this['_getFromCache'](this['url'],this['_noMipmap']),!this['_texture'])){var _0x48d284=this['getScene']();this['_prefiltered']?this['_texture']=this['_getEngine']()['createPrefilteredCubeTexture'](this['url'],_0x48d284,0.8,0x0,this['_delayedOnLoad'],void 0x0,this['_format'],_0x52d430,this['_createPolynomials']):this['_texture']=this['_getEngine']()['createCubeTexture'](this['url'],_0x48d284,this['_files'],this['_noMipmap'],this['_delayedOnLoad'],null,this['_format'],_0x52d430,!0x1,0x0,0x0,null,this['_loaderOptions']),null===(_0x3b80f5=this['_texture'])||void 0x0===_0x3b80f5||_0x3b80f5['onLoadedObservable']['add'](function(){return _0x2cdac9['onLoadObservable']['notifyObservers'](_0x2cdac9);});}},_0xc0c15f['prototype']['getReflectionTextureMatrix']=function(){return this['_textureMatrix'];},_0xc0c15f['prototype']['setReflectionTextureMatrix']=function(_0x50fca5){var _0xa035f1,_0x22439e=this;_0x50fca5['updateFlag']!==this['_textureMatrix']['updateFlag']&&(_0x50fca5['isIdentity']()!==this['_textureMatrix']['isIdentity']()&&(null===(_0xa035f1=this['getScene']())||void 0x0===_0xa035f1||_0xa035f1['markAllMaterialsAsDirty'](_0x2103ba['a']['MATERIAL_TextureDirtyFlag'],function(_0x3ad0d2){return-0x1!==_0x3ad0d2['getActiveTextures']()['indexOf'](_0x22439e);})),this['_textureMatrix']=_0x50fca5);},_0xc0c15f['Parse']=function(_0x283621,_0x414b2b,_0x4e3e9f){var _0x38c3f7=_0x495d06['a']['Parse'](function(){var _0x4c911d=!0x1;return _0x283621['prefiltered']&&(_0x4c911d=_0x283621['prefiltered']),new _0xc0c15f(_0x4e3e9f+_0x283621['name'],_0x414b2b,_0x283621['extensions'],!0x1,_0x283621['files']||null,null,null,void 0x0,_0x4c911d,_0x283621['forcedExtension']);},_0x283621,_0x414b2b);if(_0x283621['boundingBoxPosition']&&(_0x38c3f7['boundingBoxPosition']=_0x74d525['e']['FromArray'](_0x283621['boundingBoxPosition'])),_0x283621['boundingBoxSize']&&(_0x38c3f7['boundingBoxSize']=_0x74d525['e']['FromArray'](_0x283621['boundingBoxSize'])),_0x283621['animations'])for(var _0x1ae4da=0x0;_0x1ae4da<_0x283621['animations']['length'];_0x1ae4da++){var _0x55f63e=_0x283621['animations'][_0x1ae4da],_0x33a1b5=_0x3cd573['a']['GetClass']('BABYLON.Animation');_0x33a1b5&&_0x38c3f7['animations']['push'](_0x33a1b5['Parse'](_0x55f63e));}return _0x38c3f7;},_0xc0c15f['prototype']['clone']=function(){var _0x1e0882=this,_0x5ecec6=0x0,_0x15af7a=_0x495d06['a']['Clone'](function(){var _0x106109=new _0xc0c15f(_0x1e0882['url'],_0x1e0882['getScene']()||_0x1e0882['_getEngine'](),_0x1e0882['_extensions'],_0x1e0882['_noMipmap'],_0x1e0882['_files']);return _0x5ecec6=_0x106109['uniqueId'],_0x106109;},this);return _0x15af7a['uniqueId']=_0x5ecec6,_0x15af7a;},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xc0c15f['prototype'],'url',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])('rotationY')],_0xc0c15f['prototype'],'rotationY',null),Object(_0x18e13d['c'])([Object(_0x495d06['c'])('files')],_0xc0c15f['prototype'],'_files',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])('forcedExtension')],_0xc0c15f['prototype'],'_forcedExtension',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])('extensions')],_0xc0c15f['prototype'],'_extensions',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['j'])('textureMatrix')],_0xc0c15f['prototype'],'_textureMatrix',void 0x0),_0xc0c15f;}(_0x2268ea['a']);_0xaf3c80['a']['_CubeTextureParser']=_0x33892f['Parse'],_0x3cd573['a']['RegisteredTypes']['BABYLON.CubeTexture']=_0x33892f;var _0x464f31=_0x162675(0xf),_0x35e5d5=_0x162675(0x4c),_0x1bb048=_0x162675(0x57),_0x4e6421=_0x162675(0x13),_0x39e38b='\x20uniform\x20vec4\x20vPrimaryColor;\x0a#ifdef\x20USEHIGHLIGHTANDSHADOWCOLORS\x0auniform\x20vec4\x20vPrimaryColorShadow;\x0a#endif\x0auniform\x20float\x20shadowLevel;\x0auniform\x20float\x20alpha;\x0a#ifdef\x20DIFFUSE\x0auniform\x20vec2\x20vDiffuseInfos;\x0a#endif\x0a#ifdef\x20REFLECTION\x0auniform\x20vec2\x20vReflectionInfos;\x0auniform\x20mat4\x20reflectionMatrix;\x0auniform\x20vec3\x20vReflectionMicrosurfaceInfos;\x0a#endif\x0a#if\x20defined(REFLECTIONFRESNEL)\x20||\x20defined(OPACITYFRESNEL)\x0auniform\x20vec3\x20vBackgroundCenter;\x0a#endif\x0a#ifdef\x20REFLECTIONFRESNEL\x0auniform\x20vec4\x20vReflectionControl;\x0a#endif\x0a#if\x20defined(REFLECTIONMAP_SPHERICAL)\x20||\x20defined(REFLECTIONMAP_PROJECTION)\x20||\x20defined(REFRACTION)\x0auniform\x20mat4\x20view;\x0a#endif';_0x494b01['a']['IncludesShadersStore']['backgroundFragmentDeclaration']=_0x39e38b;var _0x44b696='layout(std140,column_major)\x20uniform;\x0auniform\x20Material\x0a{\x0auniform\x20vec4\x20vPrimaryColor;\x0auniform\x20vec4\x20vPrimaryColorShadow;\x0auniform\x20vec2\x20vDiffuseInfos;\x0auniform\x20vec2\x20vReflectionInfos;\x0auniform\x20mat4\x20diffuseMatrix;\x0auniform\x20mat4\x20reflectionMatrix;\x0auniform\x20vec3\x20vReflectionMicrosurfaceInfos;\x0auniform\x20float\x20fFovMultiplier;\x0auniform\x20float\x20pointSize;\x0auniform\x20float\x20shadowLevel;\x0auniform\x20float\x20alpha;\x0a#if\x20defined(REFLECTIONFRESNEL)\x20||\x20defined(OPACITYFRESNEL)\x0auniform\x20vec3\x20vBackgroundCenter;\x0a#endif\x0a#ifdef\x20REFLECTIONFRESNEL\x0auniform\x20vec4\x20vReflectionControl;\x0a#endif\x0a};\x0auniform\x20Scene\x20{\x0amat4\x20viewProjection;\x0a#ifdef\x20MULTIVIEW\x0amat4\x20viewProjectionR;\x0a#endif\x0amat4\x20view;\x0a};';_0x494b01['a']['IncludesShadersStore']['backgroundUboDeclaration']=_0x44b696,(_0x162675(0x83),_0x162675(0x6a),_0x162675(0x6b),_0x162675(0x9a),_0x162675(0x82),_0x162675(0x73),_0x162675(0x7d),_0x162675(0x6e),_0x162675(0x87),_0x162675(0x88));var _0x18731f='#ifdef\x20TEXTURELODSUPPORT\x0a#extension\x20GL_EXT_shader_texture_lod\x20:\x20enable\x0a#endif\x0aprecision\x20highp\x20float;\x0a#include<__decl__backgroundFragment>\x0a#define\x20RECIPROCAL_PI2\x200.15915494\x0a\x0auniform\x20vec3\x20vEyePosition;\x0a\x0avarying\x20vec3\x20vPositionW;\x0a#ifdef\x20MAINUV1\x0avarying\x20vec2\x20vMainUV1;\x0a#endif\x0a#ifdef\x20MAINUV2\x0avarying\x20vec2\x20vMainUV2;\x0a#endif\x0a#ifdef\x20NORMAL\x0avarying\x20vec3\x20vNormalW;\x0a#endif\x0a#ifdef\x20DIFFUSE\x0a#if\x20DIFFUSEDIRECTUV\x20==\x201\x0a#define\x20vDiffuseUV\x20vMainUV1\x0a#elif\x20DIFFUSEDIRECTUV\x20==\x202\x0a#define\x20vDiffuseUV\x20vMainUV2\x0a#else\x0avarying\x20vec2\x20vDiffuseUV;\x0a#endif\x0auniform\x20sampler2D\x20diffuseSampler;\x0a#endif\x0a\x0a#ifdef\x20REFLECTION\x0a#ifdef\x20REFLECTIONMAP_3D\x0a#define\x20sampleReflection(s,c)\x20textureCube(s,c)\x0auniform\x20samplerCube\x20reflectionSampler;\x0a#ifdef\x20TEXTURELODSUPPORT\x0a#define\x20sampleReflectionLod(s,c,l)\x20textureCubeLodEXT(s,c,l)\x0a#else\x0auniform\x20samplerCube\x20reflectionSamplerLow;\x0auniform\x20samplerCube\x20reflectionSamplerHigh;\x0a#endif\x0a#else\x0a#define\x20sampleReflection(s,c)\x20texture2D(s,c)\x0auniform\x20sampler2D\x20reflectionSampler;\x0a#ifdef\x20TEXTURELODSUPPORT\x0a#define\x20sampleReflectionLod(s,c,l)\x20texture2DLodEXT(s,c,l)\x0a#else\x0auniform\x20samplerCube\x20reflectionSamplerLow;\x0auniform\x20samplerCube\x20reflectionSamplerHigh;\x0a#endif\x0a#endif\x0a#ifdef\x20REFLECTIONMAP_SKYBOX\x0avarying\x20vec3\x20vPositionUVW;\x0a#else\x0a#if\x20defined(REFLECTIONMAP_EQUIRECTANGULAR_FIXED)\x20||\x20defined(REFLECTIONMAP_MIRROREDEQUIRECTANGULAR_FIXED)\x0avarying\x20vec3\x20vDirectionW;\x0a#endif\x0a#endif\x0a#include\x0a#endif\x0a\x0a#ifndef\x20FROMLINEARSPACE\x0a#define\x20FROMLINEARSPACE;\x0a#endif\x0a\x0a#ifndef\x20SHADOWONLY\x0a#define\x20SHADOWONLY;\x0a#endif\x0a#include\x0a\x0a#include<__decl__lightFragment>[0..maxSimultaneousLights]\x0a#include\x0a#include\x0a#include\x0a#include\x0a#include\x0a\x0a#include\x0a#ifdef\x20REFLECTIONFRESNEL\x0a#define\x20FRESNEL_MAXIMUM_ON_ROUGH\x200.25\x0avec3\x20fresnelSchlickEnvironmentGGX(float\x20VdotN,vec3\x20reflectance0,vec3\x20reflectance90,float\x20smoothness)\x0a{\x0a\x0afloat\x20weight=mix(FRESNEL_MAXIMUM_ON_ROUGH,1.0,smoothness);\x0areturn\x20reflectance0+weight*(reflectance90-reflectance0)*pow5(saturate(1.0-VdotN));\x0a}\x0a#endif\x0avoid\x20main(void)\x20{\x0a#include\x0avec3\x20viewDirectionW=normalize(vEyePosition-vPositionW);\x0a\x0a#ifdef\x20NORMAL\x0avec3\x20normalW=normalize(vNormalW);\x0a#else\x0avec3\x20normalW=vec3(0.0,1.0,0.0);\x0a#endif\x0a\x0afloat\x20shadow=1.;\x0afloat\x20globalShadow=0.;\x0afloat\x20shadowLightCount=0.;\x0a#include[0..maxSimultaneousLights]\x0a#ifdef\x20SHADOWINUSE\x0aglobalShadow/=shadowLightCount;\x0a#else\x0aglobalShadow=1.0;\x0a#endif\x0a#ifndef\x20BACKMAT_SHADOWONLY\x0a\x0avec4\x20reflectionColor=vec4(1.,1.,1.,1.);\x0a#ifdef\x20REFLECTION\x0avec3\x20reflectionVector=computeReflectionCoords(vec4(vPositionW,1.0),normalW);\x0a#ifdef\x20REFLECTIONMAP_OPPOSITEZ\x0areflectionVector.z*=-1.0;\x0a#endif\x0a\x0a#ifdef\x20REFLECTIONMAP_3D\x0avec3\x20reflectionCoords=reflectionVector;\x0a#else\x0avec2\x20reflectionCoords=reflectionVector.xy;\x0a#ifdef\x20REFLECTIONMAP_PROJECTION\x0areflectionCoords/=reflectionVector.z;\x0a#endif\x0areflectionCoords.y=1.0-reflectionCoords.y;\x0a#endif\x0a#ifdef\x20REFLECTIONBLUR\x0afloat\x20reflectionLOD=vReflectionInfos.y;\x0a#ifdef\x20TEXTURELODSUPPORT\x0a\x0areflectionLOD=reflectionLOD*log2(vReflectionMicrosurfaceInfos.x)*vReflectionMicrosurfaceInfos.y+vReflectionMicrosurfaceInfos.z;\x0areflectionColor=sampleReflectionLod(reflectionSampler,reflectionCoords,reflectionLOD);\x0a#else\x0afloat\x20lodReflectionNormalized=saturate(reflectionLOD);\x0afloat\x20lodReflectionNormalizedDoubled=lodReflectionNormalized*2.0;\x0avec4\x20reflectionSpecularMid=sampleReflection(reflectionSampler,reflectionCoords);\x0aif(lodReflectionNormalizedDoubled<1.0){\x0areflectionColor=mix(\x0asampleReflection(reflectionSamplerHigh,reflectionCoords),\x0areflectionSpecularMid,\x0alodReflectionNormalizedDoubled\x0a);\x0a}\x20else\x20{\x0areflectionColor=mix(\x0areflectionSpecularMid,\x0asampleReflection(reflectionSamplerLow,reflectionCoords),\x0alodReflectionNormalizedDoubled-1.0\x0a);\x0a}\x0a#endif\x0a#else\x0avec4\x20reflectionSample=sampleReflection(reflectionSampler,reflectionCoords);\x0areflectionColor=reflectionSample;\x0a#endif\x0a#ifdef\x20RGBDREFLECTION\x0areflectionColor.rgb=fromRGBD(reflectionColor);\x0a#endif\x0a#ifdef\x20GAMMAREFLECTION\x0areflectionColor.rgb=toLinearSpace(reflectionColor.rgb);\x0a#endif\x0a#ifdef\x20REFLECTIONBGR\x0areflectionColor.rgb=reflectionColor.bgr;\x0a#endif\x0a\x0areflectionColor.rgb*=vReflectionInfos.x;\x0a#endif\x0a\x0avec3\x20diffuseColor=vec3(1.,1.,1.);\x0afloat\x20finalAlpha=alpha;\x0a#ifdef\x20DIFFUSE\x0avec4\x20diffuseMap=texture2D(diffuseSampler,vDiffuseUV);\x0a#ifdef\x20GAMMADIFFUSE\x0adiffuseMap.rgb=toLinearSpace(diffuseMap.rgb);\x0a#endif\x0a\x0adiffuseMap.rgb*=vDiffuseInfos.y;\x0a#ifdef\x20DIFFUSEHASALPHA\x0afinalAlpha*=diffuseMap.a;\x0a#endif\x0adiffuseColor=diffuseMap.rgb;\x0a#endif\x0a\x0a#ifdef\x20REFLECTIONFRESNEL\x0avec3\x20colorBase=diffuseColor;\x0a#else\x0avec3\x20colorBase=reflectionColor.rgb*diffuseColor;\x0a#endif\x0acolorBase=max(colorBase,0.0);\x0a\x0a#ifdef\x20USERGBCOLOR\x0avec3\x20finalColor=colorBase;\x0a#else\x0a#ifdef\x20USEHIGHLIGHTANDSHADOWCOLORS\x0avec3\x20mainColor=mix(vPrimaryColorShadow.rgb,vPrimaryColor.rgb,colorBase);\x0a#else\x0avec3\x20mainColor=vPrimaryColor.rgb;\x0a#endif\x0avec3\x20finalColor=colorBase*mainColor;\x0a#endif\x0a\x0a#ifdef\x20REFLECTIONFRESNEL\x0avec3\x20reflectionAmount=vReflectionControl.xxx;\x0avec3\x20reflectionReflectance0=vReflectionControl.yyy;\x0avec3\x20reflectionReflectance90=vReflectionControl.zzz;\x0afloat\x20VdotN=dot(normalize(vEyePosition),normalW);\x0avec3\x20planarReflectionFresnel=fresnelSchlickEnvironmentGGX(saturate(VdotN),reflectionReflectance0,reflectionReflectance90,1.0);\x0areflectionAmount*=planarReflectionFresnel;\x0a#ifdef\x20REFLECTIONFALLOFF\x0afloat\x20reflectionDistanceFalloff=1.0-saturate(length(vPositionW.xyz-vBackgroundCenter)*vReflectionControl.w);\x0areflectionDistanceFalloff*=reflectionDistanceFalloff;\x0areflectionAmount*=reflectionDistanceFalloff;\x0a#endif\x0afinalColor=mix(finalColor,reflectionColor.rgb,saturate(reflectionAmount));\x0a#endif\x0a#ifdef\x20OPACITYFRESNEL\x0afloat\x20viewAngleToFloor=dot(normalW,normalize(vEyePosition-vBackgroundCenter));\x0a\x0aconst\x20float\x20startAngle=0.1;\x0afloat\x20fadeFactor=saturate(viewAngleToFloor/startAngle);\x0afinalAlpha*=fadeFactor*fadeFactor;\x0a#endif\x0a\x0a#ifdef\x20SHADOWINUSE\x0afinalColor=mix(finalColor*shadowLevel,finalColor,globalShadow);\x0a#endif\x0a\x0avec4\x20color=vec4(finalColor,finalAlpha);\x0a#else\x0avec4\x20color=vec4(vPrimaryColor.rgb,(1.0-clamp(globalShadow,0.,1.))*alpha);\x0a#endif\x0a#include\x0a#ifdef\x20IMAGEPROCESSINGPOSTPROCESS\x0a\x0a\x0acolor.rgb=clamp(color.rgb,0.,30.0);\x0a#else\x0a\x0acolor=applyImageProcessing(color);\x0a#endif\x0a#ifdef\x20PREMULTIPLYALPHA\x0a\x0acolor.rgb*=color.a;\x0a#endif\x0a#ifdef\x20NOISE\x0acolor.rgb+=dither(vPositionW.xy,0.5);\x0acolor=max(color,0.0);\x0a#endif\x0agl_FragColor=color;\x0a}\x0a';_0x494b01['a']['ShadersStore']['backgroundPixelShader']=_0x18731f;var _0x597d43='uniform\x20mat4\x20view;\x0auniform\x20mat4\x20viewProjection;\x0auniform\x20float\x20shadowLevel;\x0a#ifdef\x20DIFFUSE\x0auniform\x20mat4\x20diffuseMatrix;\x0auniform\x20vec2\x20vDiffuseInfos;\x0a#endif\x0a#ifdef\x20REFLECTION\x0auniform\x20vec2\x20vReflectionInfos;\x0auniform\x20mat4\x20reflectionMatrix;\x0auniform\x20vec3\x20vReflectionMicrosurfaceInfos;\x0auniform\x20float\x20fFovMultiplier;\x0a#endif\x0a#ifdef\x20POINTSIZE\x0auniform\x20float\x20pointSize;\x0a#endif';_0x494b01['a']['IncludesShadersStore']['backgroundVertexDeclaration']=_0x597d43,(_0x162675(0x4e),_0x162675(0x4f),_0x162675(0x75),_0x162675(0x89),_0x162675(0x50),_0x162675(0x51),_0x162675(0x6f),_0x162675(0x9d),_0x162675(0x8a));var _0x1bb6d4='precision\x20highp\x20float;\x0a#include<__decl__backgroundVertex>\x0a#include\x0a\x0aattribute\x20vec3\x20position;\x0a#ifdef\x20NORMAL\x0aattribute\x20vec3\x20normal;\x0a#endif\x0a#include\x0a\x0a#include\x0a\x0avarying\x20vec3\x20vPositionW;\x0a#ifdef\x20NORMAL\x0avarying\x20vec3\x20vNormalW;\x0a#endif\x0a#ifdef\x20UV1\x0aattribute\x20vec2\x20uv;\x0a#endif\x0a#ifdef\x20UV2\x0aattribute\x20vec2\x20uv2;\x0a#endif\x0a#ifdef\x20MAINUV1\x0avarying\x20vec2\x20vMainUV1;\x0a#endif\x0a#ifdef\x20MAINUV2\x0avarying\x20vec2\x20vMainUV2;\x0a#endif\x0a#if\x20defined(DIFFUSE)\x20&&\x20DIFFUSEDIRECTUV\x20==\x200\x0avarying\x20vec2\x20vDiffuseUV;\x0a#endif\x0a#include\x0a#include\x0a#include<__decl__lightFragment>[0..maxSimultaneousLights]\x0a#ifdef\x20REFLECTIONMAP_SKYBOX\x0avarying\x20vec3\x20vPositionUVW;\x0a#endif\x0a#if\x20defined(REFLECTIONMAP_EQUIRECTANGULAR_FIXED)\x20||\x20defined(REFLECTIONMAP_MIRROREDEQUIRECTANGULAR_FIXED)\x0avarying\x20vec3\x20vDirectionW;\x0a#endif\x0avoid\x20main(void)\x20{\x0a#ifdef\x20REFLECTIONMAP_SKYBOX\x0avPositionUVW=position;\x0a#endif\x0a#include\x0a#include\x0a#ifdef\x20MULTIVIEW\x0aif\x20(gl_ViewID_OVR\x20==\x200u)\x20{\x0agl_Position=viewProjection*finalWorld*vec4(position,1.0);\x0a}\x20else\x20{\x0agl_Position=viewProjectionR*finalWorld*vec4(position,1.0);\x0a}\x0a#else\x0agl_Position=viewProjection*finalWorld*vec4(position,1.0);\x0a#endif\x0avec4\x20worldPos=finalWorld*vec4(position,1.0);\x0avPositionW=vec3(worldPos);\x0a#ifdef\x20NORMAL\x0amat3\x20normalWorld=mat3(finalWorld);\x0a#ifdef\x20NONUNIFORMSCALING\x0anormalWorld=transposeMat3(inverseMat3(normalWorld));\x0a#endif\x0avNormalW=normalize(normalWorld*normal);\x0a#endif\x0a#if\x20defined(REFLECTIONMAP_EQUIRECTANGULAR_FIXED)\x20||\x20defined(REFLECTIONMAP_MIRROREDEQUIRECTANGULAR_FIXED)\x0avDirectionW=normalize(vec3(finalWorld*vec4(position,0.0)));\x0a#ifdef\x20EQUIRECTANGULAR_RELFECTION_FOV\x0amat3\x20screenToWorld=inverseMat3(mat3(finalWorld*viewProjection));\x0avec3\x20segment=mix(vDirectionW,screenToWorld*vec3(0.0,0.0,1.0),abs(fFovMultiplier-1.0));\x0aif\x20(fFovMultiplier<=1.0)\x20{\x0avDirectionW=normalize(segment);\x0a}\x20else\x20{\x0avDirectionW=normalize(vDirectionW+(vDirectionW-segment));\x0a}\x0a#endif\x0a#endif\x0a#ifndef\x20UV1\x0avec2\x20uv=vec2(0.,0.);\x0a#endif\x0a#ifndef\x20UV2\x0avec2\x20uv2=vec2(0.,0.);\x0a#endif\x0a#ifdef\x20MAINUV1\x0avMainUV1=uv;\x0a#endif\x0a#ifdef\x20MAINUV2\x0avMainUV2=uv2;\x0a#endif\x0a#if\x20defined(DIFFUSE)\x20&&\x20DIFFUSEDIRECTUV\x20==\x200\x0aif\x20(vDiffuseInfos.x\x20==\x200.)\x0a{\x0avDiffuseUV=vec2(diffuseMatrix*vec4(uv,1.0,0.0));\x0a}\x0aelse\x0a{\x0avDiffuseUV=vec2(diffuseMatrix*vec4(uv2,1.0,0.0));\x0a}\x0a#endif\x0a\x0a#include\x0a\x0a#include\x0a\x0a#include[0..maxSimultaneousLights]\x0a\x0a#ifdef\x20VERTEXCOLOR\x0avColor=color;\x0a#endif\x0a\x0a#ifdef\x20POINTSIZE\x0agl_PointSize=pointSize;\x0a#endif\x0a}\x0a';_0x494b01['a']['ShadersStore']['backgroundVertexShader']=_0x1bb6d4;var _0x1603d9=_0x162675(0x43),_0x2fa1c6=function(_0x5ad25e){function _0x524bea(){var _0x55cf1b=_0x5ad25e['call'](this)||this;return _0x55cf1b['DIFFUSE']=!0x1,_0x55cf1b['DIFFUSEDIRECTUV']=0x0,_0x55cf1b['GAMMADIFFUSE']=!0x1,_0x55cf1b['DIFFUSEHASALPHA']=!0x1,_0x55cf1b['OPACITYFRESNEL']=!0x1,_0x55cf1b['REFLECTIONBLUR']=!0x1,_0x55cf1b['REFLECTIONFRESNEL']=!0x1,_0x55cf1b['REFLECTIONFALLOFF']=!0x1,_0x55cf1b['TEXTURELODSUPPORT']=!0x1,_0x55cf1b['PREMULTIPLYALPHA']=!0x1,_0x55cf1b['USERGBCOLOR']=!0x1,_0x55cf1b['USEHIGHLIGHTANDSHADOWCOLORS']=!0x1,_0x55cf1b['BACKMAT_SHADOWONLY']=!0x1,_0x55cf1b['NOISE']=!0x1,_0x55cf1b['REFLECTIONBGR']=!0x1,_0x55cf1b['IMAGEPROCESSING']=!0x1,_0x55cf1b['VIGNETTE']=!0x1,_0x55cf1b['VIGNETTEBLENDMODEMULTIPLY']=!0x1,_0x55cf1b['VIGNETTEBLENDMODEOPAQUE']=!0x1,_0x55cf1b['TONEMAPPING']=!0x1,_0x55cf1b['TONEMAPPING_ACES']=!0x1,_0x55cf1b['CONTRAST']=!0x1,_0x55cf1b['COLORCURVES']=!0x1,_0x55cf1b['COLORGRADING']=!0x1,_0x55cf1b['COLORGRADING3D']=!0x1,_0x55cf1b['SAMPLER3DGREENDEPTH']=!0x1,_0x55cf1b['SAMPLER3DBGRMAP']=!0x1,_0x55cf1b['IMAGEPROCESSINGPOSTPROCESS']=!0x1,_0x55cf1b['EXPOSURE']=!0x1,_0x55cf1b['MULTIVIEW']=!0x1,_0x55cf1b['REFLECTION']=!0x1,_0x55cf1b['REFLECTIONMAP_3D']=!0x1,_0x55cf1b['REFLECTIONMAP_SPHERICAL']=!0x1,_0x55cf1b['REFLECTIONMAP_PLANAR']=!0x1,_0x55cf1b['REFLECTIONMAP_CUBIC']=!0x1,_0x55cf1b['REFLECTIONMAP_PROJECTION']=!0x1,_0x55cf1b['REFLECTIONMAP_SKYBOX']=!0x1,_0x55cf1b['REFLECTIONMAP_EXPLICIT']=!0x1,_0x55cf1b['REFLECTIONMAP_EQUIRECTANGULAR']=!0x1,_0x55cf1b['REFLECTIONMAP_EQUIRECTANGULAR_FIXED']=!0x1,_0x55cf1b['REFLECTIONMAP_MIRROREDEQUIRECTANGULAR_FIXED']=!0x1,_0x55cf1b['INVERTCUBICMAP']=!0x1,_0x55cf1b['REFLECTIONMAP_OPPOSITEZ']=!0x1,_0x55cf1b['LODINREFLECTIONALPHA']=!0x1,_0x55cf1b['GAMMAREFLECTION']=!0x1,_0x55cf1b['RGBDREFLECTION']=!0x1,_0x55cf1b['EQUIRECTANGULAR_RELFECTION_FOV']=!0x1,_0x55cf1b['MAINUV1']=!0x1,_0x55cf1b['MAINUV2']=!0x1,_0x55cf1b['UV1']=!0x1,_0x55cf1b['UV2']=!0x1,_0x55cf1b['CLIPPLANE']=!0x1,_0x55cf1b['CLIPPLANE2']=!0x1,_0x55cf1b['CLIPPLANE3']=!0x1,_0x55cf1b['CLIPPLANE4']=!0x1,_0x55cf1b['CLIPPLANE5']=!0x1,_0x55cf1b['CLIPPLANE6']=!0x1,_0x55cf1b['POINTSIZE']=!0x1,_0x55cf1b['FOG']=!0x1,_0x55cf1b['NORMAL']=!0x1,_0x55cf1b['NUM_BONE_INFLUENCERS']=0x0,_0x55cf1b['BonesPerMesh']=0x0,_0x55cf1b['INSTANCES']=!0x1,_0x55cf1b['SHADOWFLOAT']=!0x1,_0x55cf1b['rebuild'](),_0x55cf1b;}return Object(_0x18e13d['d'])(_0x524bea,_0x5ad25e),_0x524bea;}(_0x35e5d5['a']),_0x4fe332=function(_0x4b8224){function _0x5d7460(_0x544fb7,_0x313e01){var _0x97256=_0x4b8224['call'](this,_0x544fb7,_0x313e01)||this;return _0x97256['primaryColor']=_0x39310d['a']['White'](),_0x97256['_primaryColorShadowLevel']=0x0,_0x97256['_primaryColorHighlightLevel']=0x0,_0x97256['reflectionTexture']=null,_0x97256['reflectionBlur']=0x0,_0x97256['diffuseTexture']=null,_0x97256['_shadowLights']=null,_0x97256['shadowLights']=null,_0x97256['shadowLevel']=0x0,_0x97256['sceneCenter']=_0x74d525['e']['Zero'](),_0x97256['opacityFresnel']=!0x0,_0x97256['reflectionFresnel']=!0x1,_0x97256['reflectionFalloffDistance']=0x0,_0x97256['reflectionAmount']=0x1,_0x97256['reflectionReflectance0']=0.05,_0x97256['reflectionReflectance90']=0.5,_0x97256['useRGBColor']=!0x0,_0x97256['enableNoise']=!0x1,_0x97256['_fovMultiplier']=0x1,_0x97256['useEquirectangularFOV']=!0x1,_0x97256['_maxSimultaneousLights']=0x4,_0x97256['maxSimultaneousLights']=0x4,_0x97256['_shadowOnly']=!0x1,_0x97256['shadowOnly']=!0x1,_0x97256['_imageProcessingObserver']=null,_0x97256['switchToBGR']=!0x1,_0x97256['_renderTargets']=new _0x2266f9['a'](0x10),_0x97256['_reflectionControls']=_0x74d525['f']['Zero'](),_0x97256['_white']=_0x39310d['a']['White'](),_0x97256['_primaryShadowColor']=_0x39310d['a']['Black'](),_0x97256['_primaryHighlightColor']=_0x39310d['a']['Black'](),_0x97256['_attachImageProcessingConfiguration'](null),_0x97256['getRenderTargetTextures']=function(){return _0x97256['_renderTargets']['reset'](),_0x97256['_diffuseTexture']&&_0x97256['_diffuseTexture']['isRenderTarget']&&_0x97256['_renderTargets']['push'](_0x97256['_diffuseTexture']),_0x97256['_reflectionTexture']&&_0x97256['_reflectionTexture']['isRenderTarget']&&_0x97256['_renderTargets']['push'](_0x97256['_reflectionTexture']),_0x97256['_renderTargets'];},_0x97256;}return Object(_0x18e13d['d'])(_0x5d7460,_0x4b8224),Object['defineProperty'](_0x5d7460['prototype'],'_perceptualColor',{'get':function(){return this['__perceptualColor'];},'set':function(_0x55dec5){this['__perceptualColor']=_0x55dec5,this['_computePrimaryColorFromPerceptualColor'](),this['_markAllSubMeshesAsLightsDirty']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5d7460['prototype'],'primaryColorShadowLevel',{'get':function(){return this['_primaryColorShadowLevel'];},'set':function(_0x365dae){this['_primaryColorShadowLevel']=_0x365dae,this['_computePrimaryColors'](),this['_markAllSubMeshesAsLightsDirty']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5d7460['prototype'],'primaryColorHighlightLevel',{'get':function(){return this['_primaryColorHighlightLevel'];},'set':function(_0x5b01d5){this['_primaryColorHighlightLevel']=_0x5b01d5,this['_computePrimaryColors'](),this['_markAllSubMeshesAsLightsDirty']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5d7460['prototype'],'reflectionStandardFresnelWeight',{'set':function(_0x246ea2){var _0x31c9b9=_0x246ea2;_0x31c9b9<0.5?(_0x31c9b9*=0x2,this['reflectionReflectance0']=_0x5d7460['StandardReflectance0']*_0x31c9b9,this['reflectionReflectance90']=_0x5d7460['StandardReflectance90']*_0x31c9b9):(_0x31c9b9=0x2*_0x31c9b9-0x1,this['reflectionReflectance0']=_0x5d7460['StandardReflectance0']+(0x1-_0x5d7460['StandardReflectance0'])*_0x31c9b9,this['reflectionReflectance90']=_0x5d7460['StandardReflectance90']+(0x1-_0x5d7460['StandardReflectance90'])*_0x31c9b9);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5d7460['prototype'],'fovMultiplier',{'get':function(){return this['_fovMultiplier'];},'set':function(_0x1f61b6){isNaN(_0x1f61b6)&&(_0x1f61b6=0x1),this['_fovMultiplier']=Math['max'](0x0,Math['min'](0x2,_0x1f61b6));},'enumerable':!0x1,'configurable':!0x0}),_0x5d7460['prototype']['_attachImageProcessingConfiguration']=function(_0x494e4e){var _0x8d866b=this;_0x494e4e!==this['_imageProcessingConfiguration']&&(this['_imageProcessingConfiguration']&&this['_imageProcessingObserver']&&this['_imageProcessingConfiguration']['onUpdateParameters']['remove'](this['_imageProcessingObserver']),this['_imageProcessingConfiguration']=_0x494e4e||this['getScene']()['imageProcessingConfiguration'],this['_imageProcessingConfiguration']&&(this['_imageProcessingObserver']=this['_imageProcessingConfiguration']['onUpdateParameters']['add'](function(){_0x8d866b['_computePrimaryColorFromPerceptualColor'](),_0x8d866b['_markAllSubMeshesAsImageProcessingDirty']();})));},Object['defineProperty'](_0x5d7460['prototype'],'imageProcessingConfiguration',{'get':function(){return this['_imageProcessingConfiguration'];},'set':function(_0x236e0c){this['_attachImageProcessingConfiguration'](_0x236e0c),this['_markAllSubMeshesAsTexturesDirty']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5d7460['prototype'],'cameraColorCurvesEnabled',{'get':function(){return this['imageProcessingConfiguration']['colorCurvesEnabled'];},'set':function(_0x2c28b0){this['imageProcessingConfiguration']['colorCurvesEnabled']=_0x2c28b0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5d7460['prototype'],'cameraColorGradingEnabled',{'get':function(){return this['imageProcessingConfiguration']['colorGradingEnabled'];},'set':function(_0x48cbb2){this['imageProcessingConfiguration']['colorGradingEnabled']=_0x48cbb2;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5d7460['prototype'],'cameraToneMappingEnabled',{'get':function(){return this['_imageProcessingConfiguration']['toneMappingEnabled'];},'set':function(_0x533a78){this['_imageProcessingConfiguration']['toneMappingEnabled']=_0x533a78;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5d7460['prototype'],'cameraExposure',{'get':function(){return this['_imageProcessingConfiguration']['exposure'];},'set':function(_0x51981e){this['_imageProcessingConfiguration']['exposure']=_0x51981e;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5d7460['prototype'],'cameraContrast',{'get':function(){return this['_imageProcessingConfiguration']['contrast'];},'set':function(_0x3caee5){this['_imageProcessingConfiguration']['contrast']=_0x3caee5;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5d7460['prototype'],'cameraColorGradingTexture',{'get':function(){return this['_imageProcessingConfiguration']['colorGradingTexture'];},'set':function(_0x195d93){this['imageProcessingConfiguration']['colorGradingTexture']=_0x195d93;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5d7460['prototype'],'cameraColorCurves',{'get':function(){return this['imageProcessingConfiguration']['colorCurves'];},'set':function(_0x23560c){this['imageProcessingConfiguration']['colorCurves']=_0x23560c;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5d7460['prototype'],'hasRenderTargetTextures',{'get':function(){return!(!this['_diffuseTexture']||!this['_diffuseTexture']['isRenderTarget'])||!(!this['_reflectionTexture']||!this['_reflectionTexture']['isRenderTarget']);},'enumerable':!0x1,'configurable':!0x0}),_0x5d7460['prototype']['needAlphaTesting']=function(){return!0x0;},_0x5d7460['prototype']['needAlphaBlending']=function(){return this['alpha']<0x1||null!=this['_diffuseTexture']&&this['_diffuseTexture']['hasAlpha']||this['_shadowOnly'];},_0x5d7460['prototype']['isReadyForSubMesh']=function(_0x3a215d,_0x2e00d0,_0x42716a){var _0x5b1bc6=this;if(void 0x0===_0x42716a&&(_0x42716a=!0x1),_0x2e00d0['effect']&&this['isFrozen']&&_0x2e00d0['effect']['_wasPreviouslyReady'])return!0x0;_0x2e00d0['_materialDefines']||(_0x2e00d0['_materialDefines']=new _0x2fa1c6());var _0x11a91a=this['getScene'](),_0x118d67=_0x2e00d0['_materialDefines'];if(this['_isReadyForSubMesh'](_0x2e00d0))return!0x0;var _0x3c2003=_0x11a91a['getEngine']();if(_0x464f31['a']['PrepareDefinesForLights'](_0x11a91a,_0x3a215d,_0x118d67,!0x1,this['_maxSimultaneousLights']),_0x118d67['_needNormals']=!0x0,_0x464f31['a']['PrepareDefinesForMultiview'](_0x11a91a,_0x118d67),_0x118d67['_areTexturesDirty']){if(_0x118d67['_needUVs']=!0x1,_0x11a91a['texturesEnabled']){if(_0x11a91a['getEngine']()['getCaps']()['textureLOD']&&(_0x118d67['TEXTURELODSUPPORT']=!0x0),this['_diffuseTexture']&&_0x4e6421['a']['DiffuseTextureEnabled']){if(!this['_diffuseTexture']['isReadyOrNotBlocking']())return!0x1;_0x464f31['a']['PrepareDefinesForMergedUV'](this['_diffuseTexture'],_0x118d67,'DIFFUSE'),_0x118d67['DIFFUSEHASALPHA']=this['_diffuseTexture']['hasAlpha'],_0x118d67['GAMMADIFFUSE']=this['_diffuseTexture']['gammaSpace'],_0x118d67['OPACITYFRESNEL']=this['_opacityFresnel'];}else _0x118d67['DIFFUSE']=!0x1,_0x118d67['DIFFUSEHASALPHA']=!0x1,_0x118d67['GAMMADIFFUSE']=!0x1,_0x118d67['OPACITYFRESNEL']=!0x1;var _0x454974=this['_reflectionTexture'];if(_0x454974&&_0x4e6421['a']['ReflectionTextureEnabled']){if(!_0x454974['isReadyOrNotBlocking']())return!0x1;switch(_0x118d67['REFLECTION']=!0x0,_0x118d67['GAMMAREFLECTION']=_0x454974['gammaSpace'],_0x118d67['RGBDREFLECTION']=_0x454974['isRGBD'],_0x118d67['REFLECTIONBLUR']=this['_reflectionBlur']>0x0,_0x118d67['REFLECTIONMAP_OPPOSITEZ']=this['getScene']()['useRightHandedSystem']?!_0x454974['invertZ']:_0x454974['invertZ'],_0x118d67['LODINREFLECTIONALPHA']=_0x454974['lodLevelInAlpha'],_0x118d67['EQUIRECTANGULAR_RELFECTION_FOV']=this['useEquirectangularFOV'],_0x118d67['REFLECTIONBGR']=this['switchToBGR'],_0x454974['coordinatesMode']===_0xaf3c80['a']['INVCUBIC_MODE']&&(_0x118d67['INVERTCUBICMAP']=!0x0),_0x118d67['REFLECTIONMAP_3D']=_0x454974['isCube'],_0x454974['coordinatesMode']){case _0xaf3c80['a']['EXPLICIT_MODE']:_0x118d67['REFLECTIONMAP_EXPLICIT']=!0x0;break;case _0xaf3c80['a']['PLANAR_MODE']:_0x118d67['REFLECTIONMAP_PLANAR']=!0x0;break;case _0xaf3c80['a']['PROJECTION_MODE']:_0x118d67['REFLECTIONMAP_PROJECTION']=!0x0;break;case _0xaf3c80['a']['SKYBOX_MODE']:_0x118d67['REFLECTIONMAP_SKYBOX']=!0x0;break;case _0xaf3c80['a']['SPHERICAL_MODE']:_0x118d67['REFLECTIONMAP_SPHERICAL']=!0x0;break;case _0xaf3c80['a']['EQUIRECTANGULAR_MODE']:_0x118d67['REFLECTIONMAP_EQUIRECTANGULAR']=!0x0;break;case _0xaf3c80['a']['FIXED_EQUIRECTANGULAR_MODE']:_0x118d67['REFLECTIONMAP_EQUIRECTANGULAR_FIXED']=!0x0;break;case _0xaf3c80['a']['FIXED_EQUIRECTANGULAR_MIRRORED_MODE']:_0x118d67['REFLECTIONMAP_MIRROREDEQUIRECTANGULAR_FIXED']=!0x0;break;case _0xaf3c80['a']['CUBIC_MODE']:case _0xaf3c80['a']['INVCUBIC_MODE']:default:_0x118d67['REFLECTIONMAP_CUBIC']=!0x0;}this['reflectionFresnel']?(_0x118d67['REFLECTIONFRESNEL']=!0x0,_0x118d67['REFLECTIONFALLOFF']=this['reflectionFalloffDistance']>0x0,this['_reflectionControls']['x']=this['reflectionAmount'],this['_reflectionControls']['y']=this['reflectionReflectance0'],this['_reflectionControls']['z']=this['reflectionReflectance90'],this['_reflectionControls']['w']=0x1/this['reflectionFalloffDistance']):(_0x118d67['REFLECTIONFRESNEL']=!0x1,_0x118d67['REFLECTIONFALLOFF']=!0x1);}else _0x118d67['REFLECTION']=!0x1,_0x118d67['REFLECTIONFRESNEL']=!0x1,_0x118d67['REFLECTIONFALLOFF']=!0x1,_0x118d67['REFLECTIONBLUR']=!0x1,_0x118d67['REFLECTIONMAP_3D']=!0x1,_0x118d67['REFLECTIONMAP_SPHERICAL']=!0x1,_0x118d67['REFLECTIONMAP_PLANAR']=!0x1,_0x118d67['REFLECTIONMAP_CUBIC']=!0x1,_0x118d67['REFLECTIONMAP_PROJECTION']=!0x1,_0x118d67['REFLECTIONMAP_SKYBOX']=!0x1,_0x118d67['REFLECTIONMAP_EXPLICIT']=!0x1,_0x118d67['REFLECTIONMAP_EQUIRECTANGULAR']=!0x1,_0x118d67['REFLECTIONMAP_EQUIRECTANGULAR_FIXED']=!0x1,_0x118d67['REFLECTIONMAP_MIRROREDEQUIRECTANGULAR_FIXED']=!0x1,_0x118d67['INVERTCUBICMAP']=!0x1,_0x118d67['REFLECTIONMAP_OPPOSITEZ']=!0x1,_0x118d67['LODINREFLECTIONALPHA']=!0x1,_0x118d67['GAMMAREFLECTION']=!0x1,_0x118d67['RGBDREFLECTION']=!0x1;}_0x118d67['PREMULTIPLYALPHA']=this['alphaMode']===_0x2103ba['a']['ALPHA_PREMULTIPLIED']||this['alphaMode']===_0x2103ba['a']['ALPHA_PREMULTIPLIED_PORTERDUFF'],_0x118d67['USERGBCOLOR']=this['_useRGBColor'],_0x118d67['NOISE']=this['_enableNoise'];}if(_0x118d67['_areLightsDirty']&&(_0x118d67['USEHIGHLIGHTANDSHADOWCOLORS']=!this['_useRGBColor']&&(0x0!==this['_primaryColorShadowLevel']||0x0!==this['_primaryColorHighlightLevel']),_0x118d67['BACKMAT_SHADOWONLY']=this['_shadowOnly']),_0x118d67['_areImageProcessingDirty']&&this['_imageProcessingConfiguration']){if(!this['_imageProcessingConfiguration']['isReady']())return!0x1;this['_imageProcessingConfiguration']['prepareDefines'](_0x118d67);}if(_0x464f31['a']['PrepareDefinesForMisc'](_0x3a215d,_0x11a91a,!0x1,this['pointsCloud'],this['fogEnabled'],this['_shouldTurnAlphaTestOn'](_0x3a215d),_0x118d67),_0x464f31['a']['PrepareDefinesForFrameBoundValues'](_0x11a91a,_0x3c2003,_0x118d67,_0x42716a,null,_0x2e00d0['getRenderingMesh']()['hasThinInstances']),_0x464f31['a']['PrepareDefinesForAttributes'](_0x3a215d,_0x118d67,!0x1,!0x0,!0x1)&&_0x3a215d&&(_0x11a91a['getEngine']()['getCaps']()['standardDerivatives']||_0x3a215d['isVerticesDataPresent'](_0x212fbd['b']['NormalKind'])||(_0x3a215d['createNormals'](!0x0),_0x75193d['a']['Warn']('BackgroundMaterial:\x20Normals\x20have\x20been\x20created\x20for\x20the\x20mesh:\x20'+_0x3a215d['name']))),_0x118d67['isDirty']){_0x118d67['markAsProcessed'](),_0x11a91a['resetCachedMaterial']();var _0x4e4973=new _0x1603d9['a']();_0x118d67['FOG']&&_0x4e4973['addFallback'](0x0,'FOG'),_0x118d67['POINTSIZE']&&_0x4e4973['addFallback'](0x1,'POINTSIZE'),_0x118d67['MULTIVIEW']&&_0x4e4973['addFallback'](0x0,'MULTIVIEW'),_0x464f31['a']['HandleFallbacksForShadows'](_0x118d67,_0x4e4973,this['_maxSimultaneousLights']);var _0x86748=[_0x212fbd['b']['PositionKind']];_0x118d67['NORMAL']&&_0x86748['push'](_0x212fbd['b']['NormalKind']),_0x118d67['UV1']&&_0x86748['push'](_0x212fbd['b']['UVKind']),_0x118d67['UV2']&&_0x86748['push'](_0x212fbd['b']['UV2Kind']),_0x464f31['a']['PrepareAttributesForBones'](_0x86748,_0x3a215d,_0x118d67,_0x4e4973),_0x464f31['a']['PrepareAttributesForInstances'](_0x86748,_0x118d67);var _0x5c5c3d=['world','view','viewProjection','vEyePosition','vLightsType','vFogInfos','vFogColor','pointSize','vClipPlane','vClipPlane2','vClipPlane3','vClipPlane4','vClipPlane5','vClipPlane6','mBones','vPrimaryColor','vPrimaryColorShadow','vReflectionInfos','reflectionMatrix','vReflectionMicrosurfaceInfos','fFovMultiplier','shadowLevel','alpha','vBackgroundCenter','vReflectionControl','vDiffuseInfos','diffuseMatrix'],_0x4b2bdb=['diffuseSampler','reflectionSampler','reflectionSamplerLow','reflectionSamplerHigh'],_0x58bef0=['Material','Scene'];_0x3f08d6['a']&&(_0x3f08d6['a']['PrepareUniforms'](_0x5c5c3d,_0x118d67),_0x3f08d6['a']['PrepareSamplers'](_0x4b2bdb,_0x118d67)),_0x464f31['a']['PrepareUniformsAndSamplersList']({'uniformsNames':_0x5c5c3d,'uniformBuffersNames':_0x58bef0,'samplers':_0x4b2bdb,'defines':_0x118d67,'maxSimultaneousLights':this['_maxSimultaneousLights']});var _0x3dde00=_0x118d67['toString']();_0x2e00d0['setEffect'](_0x11a91a['getEngine']()['createEffect']('background',{'attributes':_0x86748,'uniformsNames':_0x5c5c3d,'uniformBuffersNames':_0x58bef0,'samplers':_0x4b2bdb,'defines':_0x3dde00,'fallbacks':_0x4e4973,'onCompiled':function(_0x2656b3){_0x5b1bc6['onCompiled']&&_0x5b1bc6['onCompiled'](_0x2656b3),_0x5b1bc6['bindSceneUniformBuffer'](_0x2656b3,_0x11a91a['getSceneUniformBuffer']());},'onError':this['onError'],'indexParameters':{'maxSimultaneousLights':this['_maxSimultaneousLights']}},_0x3c2003),_0x118d67),this['buildUniformLayout']();}return!(!_0x2e00d0['effect']||!_0x2e00d0['effect']['isReady']())&&(_0x118d67['_renderId']=_0x11a91a['getRenderId'](),_0x2e00d0['effect']['_wasPreviouslyReady']=!0x0,!0x0);},_0x5d7460['prototype']['_computePrimaryColorFromPerceptualColor']=function(){this['__perceptualColor']&&(this['_primaryColor']['copyFrom'](this['__perceptualColor']),this['_primaryColor']['toLinearSpaceToRef'](this['_primaryColor']),this['_imageProcessingConfiguration']&&this['_primaryColor']['scaleToRef'](0x1/this['_imageProcessingConfiguration']['exposure'],this['_primaryColor']),this['_computePrimaryColors']());},_0x5d7460['prototype']['_computePrimaryColors']=function(){0x0===this['_primaryColorShadowLevel']&&0x0===this['_primaryColorHighlightLevel']||(this['_primaryColor']['scaleToRef'](this['_primaryColorShadowLevel'],this['_primaryShadowColor']),this['_primaryColor']['subtractToRef'](this['_primaryShadowColor'],this['_primaryShadowColor']),this['_white']['subtractToRef'](this['_primaryColor'],this['_primaryHighlightColor']),this['_primaryHighlightColor']['scaleToRef'](this['_primaryColorHighlightLevel'],this['_primaryHighlightColor']),this['_primaryColor']['addToRef'](this['_primaryHighlightColor'],this['_primaryHighlightColor']));},_0x5d7460['prototype']['buildUniformLayout']=function(){this['_uniformBuffer']['addUniform']('vPrimaryColor',0x4),this['_uniformBuffer']['addUniform']('vPrimaryColorShadow',0x4),this['_uniformBuffer']['addUniform']('vDiffuseInfos',0x2),this['_uniformBuffer']['addUniform']('vReflectionInfos',0x2),this['_uniformBuffer']['addUniform']('diffuseMatrix',0x10),this['_uniformBuffer']['addUniform']('reflectionMatrix',0x10),this['_uniformBuffer']['addUniform']('vReflectionMicrosurfaceInfos',0x3),this['_uniformBuffer']['addUniform']('fFovMultiplier',0x1),this['_uniformBuffer']['addUniform']('pointSize',0x1),this['_uniformBuffer']['addUniform']('shadowLevel',0x1),this['_uniformBuffer']['addUniform']('alpha',0x1),this['_uniformBuffer']['addUniform']('vBackgroundCenter',0x3),this['_uniformBuffer']['addUniform']('vReflectionControl',0x4),this['_uniformBuffer']['create']();},_0x5d7460['prototype']['unbind']=function(){this['_diffuseTexture']&&this['_diffuseTexture']['isRenderTarget']&&this['_uniformBuffer']['setTexture']('diffuseSampler',null),this['_reflectionTexture']&&this['_reflectionTexture']['isRenderTarget']&&this['_uniformBuffer']['setTexture']('reflectionSampler',null),_0x4b8224['prototype']['unbind']['call'](this);},_0x5d7460['prototype']['bindOnlyWorldMatrix']=function(_0x5f219b){this['_activeEffect']['setMatrix']('world',_0x5f219b);},_0x5d7460['prototype']['bindForSubMesh']=function(_0x487595,_0x5e4ea2,_0x1ded16){var _0x5f4780=this['getScene'](),_0xa886f0=_0x1ded16['_materialDefines'];if(_0xa886f0){var _0x525479=_0x1ded16['effect'];if(_0x525479){this['_activeEffect']=_0x525479,this['bindOnlyWorldMatrix'](_0x487595),_0x464f31['a']['BindBonesParameters'](_0x5e4ea2,this['_activeEffect']);var _0x22d6aa=this['_mustRebind'](_0x5f4780,_0x525479,_0x5e4ea2['visibility']);if(_0x22d6aa){this['_uniformBuffer']['bindToEffect'](_0x525479,'Material'),this['bindViewProjection'](_0x525479);var _0x568a48=this['_reflectionTexture'];this['_uniformBuffer']['useUbo']&&this['isFrozen']&&this['_uniformBuffer']['isSync']||(_0x5f4780['texturesEnabled']&&(this['_diffuseTexture']&&_0x4e6421['a']['DiffuseTextureEnabled']&&(this['_uniformBuffer']['updateFloat2']('vDiffuseInfos',this['_diffuseTexture']['coordinatesIndex'],this['_diffuseTexture']['level']),_0x464f31['a']['BindTextureMatrix'](this['_diffuseTexture'],this['_uniformBuffer'],'diffuse')),_0x568a48&&_0x4e6421['a']['ReflectionTextureEnabled']&&(this['_uniformBuffer']['updateMatrix']('reflectionMatrix',_0x568a48['getReflectionTextureMatrix']()),this['_uniformBuffer']['updateFloat2']('vReflectionInfos',_0x568a48['level'],this['_reflectionBlur']),this['_uniformBuffer']['updateFloat3']('vReflectionMicrosurfaceInfos',_0x568a48['getSize']()['width'],_0x568a48['lodGenerationScale'],_0x568a48['lodGenerationOffset']))),this['shadowLevel']>0x0&&this['_uniformBuffer']['updateFloat']('shadowLevel',this['shadowLevel']),this['_uniformBuffer']['updateFloat']('alpha',this['alpha']),this['pointsCloud']&&this['_uniformBuffer']['updateFloat']('pointSize',this['pointSize']),_0xa886f0['USEHIGHLIGHTANDSHADOWCOLORS']?(this['_uniformBuffer']['updateColor4']('vPrimaryColor',this['_primaryHighlightColor'],0x1),this['_uniformBuffer']['updateColor4']('vPrimaryColorShadow',this['_primaryShadowColor'],0x1)):this['_uniformBuffer']['updateColor4']('vPrimaryColor',this['_primaryColor'],0x1)),this['_uniformBuffer']['updateFloat']('fFovMultiplier',this['_fovMultiplier']),_0x5f4780['texturesEnabled']&&(this['_diffuseTexture']&&_0x4e6421['a']['DiffuseTextureEnabled']&&this['_uniformBuffer']['setTexture']('diffuseSampler',this['_diffuseTexture']),_0x568a48&&_0x4e6421['a']['ReflectionTextureEnabled']&&(_0xa886f0['REFLECTIONBLUR']&&_0xa886f0['TEXTURELODSUPPORT']?this['_uniformBuffer']['setTexture']('reflectionSampler',_0x568a48):_0xa886f0['REFLECTIONBLUR']?(this['_uniformBuffer']['setTexture']('reflectionSampler',_0x568a48['_lodTextureMid']||_0x568a48),this['_uniformBuffer']['setTexture']('reflectionSamplerLow',_0x568a48['_lodTextureLow']||_0x568a48),this['_uniformBuffer']['setTexture']('reflectionSamplerHigh',_0x568a48['_lodTextureHigh']||_0x568a48)):this['_uniformBuffer']['setTexture']('reflectionSampler',_0x568a48),_0xa886f0['REFLECTIONFRESNEL']&&(this['_uniformBuffer']['updateFloat3']('vBackgroundCenter',this['sceneCenter']['x'],this['sceneCenter']['y'],this['sceneCenter']['z']),this['_uniformBuffer']['updateFloat4']('vReflectionControl',this['_reflectionControls']['x'],this['_reflectionControls']['y'],this['_reflectionControls']['z'],this['_reflectionControls']['w'])))),_0x464f31['a']['BindClipPlane'](this['_activeEffect'],_0x5f4780),_0x464f31['a']['BindEyePosition'](_0x525479,_0x5f4780);}!_0x22d6aa&&this['isFrozen']||(_0x5f4780['lightsEnabled']&&_0x464f31['a']['BindLights'](_0x5f4780,_0x5e4ea2,this['_activeEffect'],_0xa886f0,this['_maxSimultaneousLights'],!0x1),this['bindView'](_0x525479),_0x464f31['a']['BindFogParameters'](_0x5f4780,_0x5e4ea2,this['_activeEffect'],!0x0),this['_imageProcessingConfiguration']&&this['_imageProcessingConfiguration']['bind'](this['_activeEffect'])),this['_uniformBuffer']['update'](),this['_afterBind'](_0x5e4ea2,this['_activeEffect']);}}},_0x5d7460['prototype']['hasTexture']=function(_0x239631){return!!_0x4b8224['prototype']['hasTexture']['call'](this,_0x239631)||(this['_reflectionTexture']===_0x239631||this['_diffuseTexture']===_0x239631);},_0x5d7460['prototype']['dispose']=function(_0x7f27a5,_0x50c7bb){void 0x0===_0x7f27a5&&(_0x7f27a5=!0x1),void 0x0===_0x50c7bb&&(_0x50c7bb=!0x1),_0x50c7bb&&(this['diffuseTexture']&&this['diffuseTexture']['dispose'](),this['reflectionTexture']&&this['reflectionTexture']['dispose']()),this['_renderTargets']['dispose'](),this['_imageProcessingConfiguration']&&this['_imageProcessingObserver']&&this['_imageProcessingConfiguration']['onUpdateParameters']['remove'](this['_imageProcessingObserver']),_0x4b8224['prototype']['dispose']['call'](this,_0x7f27a5);},_0x5d7460['prototype']['clone']=function(_0x474fbd){var _0x1522e0=this;return _0x495d06['a']['Clone'](function(){return new _0x5d7460(_0x474fbd,_0x1522e0['getScene']());},this);},_0x5d7460['prototype']['serialize']=function(){var _0x2429c7=_0x495d06['a']['Serialize'](this);return _0x2429c7['customType']='BABYLON.BackgroundMaterial',_0x2429c7;},_0x5d7460['prototype']['getClassName']=function(){return'BackgroundMaterial';},_0x5d7460['Parse']=function(_0x415f3e,_0x1d6716,_0x58ff33){return _0x495d06['a']['Parse'](function(){return new _0x5d7460(_0x415f3e['name'],_0x1d6716);},_0x415f3e,_0x1d6716,_0x58ff33);},_0x5d7460['StandardReflectance0']=0.05,_0x5d7460['StandardReflectance90']=0.5,Object(_0x18e13d['c'])([Object(_0x495d06['e'])()],_0x5d7460['prototype'],'_primaryColor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['b'])('_markAllSubMeshesAsLightsDirty')],_0x5d7460['prototype'],'primaryColor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['e'])()],_0x5d7460['prototype'],'__perceptualColor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x5d7460['prototype'],'_primaryColorShadowLevel',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x5d7460['prototype'],'_primaryColorHighlightLevel',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['b'])('_markAllSubMeshesAsLightsDirty')],_0x5d7460['prototype'],'primaryColorHighlightLevel',null),Object(_0x18e13d['c'])([Object(_0x495d06['m'])()],_0x5d7460['prototype'],'_reflectionTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x5d7460['prototype'],'reflectionTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x5d7460['prototype'],'_reflectionBlur',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x5d7460['prototype'],'reflectionBlur',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])()],_0x5d7460['prototype'],'_diffuseTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x5d7460['prototype'],'diffuseTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x5d7460['prototype'],'shadowLights',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x5d7460['prototype'],'_shadowLevel',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x5d7460['prototype'],'shadowLevel',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['o'])()],_0x5d7460['prototype'],'_sceneCenter',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x5d7460['prototype'],'sceneCenter',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x5d7460['prototype'],'_opacityFresnel',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x5d7460['prototype'],'opacityFresnel',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x5d7460['prototype'],'_reflectionFresnel',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x5d7460['prototype'],'reflectionFresnel',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x5d7460['prototype'],'_reflectionFalloffDistance',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x5d7460['prototype'],'reflectionFalloffDistance',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x5d7460['prototype'],'_reflectionAmount',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x5d7460['prototype'],'reflectionAmount',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x5d7460['prototype'],'_reflectionReflectance0',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x5d7460['prototype'],'reflectionReflectance0',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x5d7460['prototype'],'_reflectionReflectance90',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x5d7460['prototype'],'reflectionReflectance90',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x5d7460['prototype'],'_useRGBColor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x5d7460['prototype'],'useRGBColor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x5d7460['prototype'],'_enableNoise',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x5d7460['prototype'],'enableNoise',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x5d7460['prototype'],'_maxSimultaneousLights',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x5d7460['prototype'],'maxSimultaneousLights',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x5d7460['prototype'],'_shadowOnly',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['b'])('_markAllSubMeshesAsLightsDirty')],_0x5d7460['prototype'],'shadowOnly',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['i'])()],_0x5d7460['prototype'],'_imageProcessingConfiguration',void 0x0),_0x5d7460;}(_0x1bb048['a']);_0x3cd573['a']['RegisteredTypes']['BABYLON.BackgroundMaterial']=_0x4fe332;var _0xec7a4b=(function(){function _0x5be0c6(_0x53883d,_0x3ab9f4){var _0x4a8352=this;this['_errorHandler']=function(_0x507b3c,_0x2249ba){_0x4a8352['onErrorObservable']['notifyObservers']({'message':_0x507b3c,'exception':_0x2249ba});},this['_options']=Object(_0x18e13d['a'])(Object(_0x18e13d['a'])({},_0x5be0c6['_getDefaultOptions']()),_0x53883d),this['_scene']=_0x3ab9f4,this['onErrorObservable']=new _0x6ac1f7['c'](),this['_setupBackground'](),this['_setupImageProcessing']();}return _0x5be0c6['_getDefaultOptions']=function(){return{'createGround':!0x0,'groundSize':0xf,'groundTexture':this['_groundTextureCDNUrl'],'groundColor':new _0x39310d['a'](0.2,0.2,0.3)['toLinearSpace']()['scale'](0x3),'groundOpacity':0.9,'enableGroundShadow':!0x0,'groundShadowLevel':0.5,'enableGroundMirror':!0x1,'groundMirrorSizeRatio':0.3,'groundMirrorBlurKernel':0x40,'groundMirrorAmount':0x1,'groundMirrorFresnelWeight':0x1,'groundMirrorFallOffDistance':0x0,'groundMirrorTextureType':_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'],'groundYBias':0.00001,'createSkybox':!0x0,'skyboxSize':0x14,'skyboxTexture':this['_skyboxTextureCDNUrl'],'skyboxColor':new _0x39310d['a'](0.2,0.2,0.3)['toLinearSpace']()['scale'](0x3),'backgroundYRotation':0x0,'sizeAuto':!0x0,'rootPosition':_0x74d525['e']['Zero'](),'setupImageProcessing':!0x0,'environmentTexture':this['_environmentTextureCDNUrl'],'cameraExposure':0.8,'cameraContrast':1.2,'toneMappingEnabled':!0x0};},Object['defineProperty'](_0x5be0c6['prototype'],'rootMesh',{'get':function(){return this['_rootMesh'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5be0c6['prototype'],'skybox',{'get':function(){return this['_skybox'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5be0c6['prototype'],'skyboxTexture',{'get':function(){return this['_skyboxTexture'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5be0c6['prototype'],'skyboxMaterial',{'get':function(){return this['_skyboxMaterial'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5be0c6['prototype'],'ground',{'get':function(){return this['_ground'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5be0c6['prototype'],'groundTexture',{'get':function(){return this['_groundTexture'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5be0c6['prototype'],'groundMirror',{'get':function(){return this['_groundMirror'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5be0c6['prototype'],'groundMirrorRenderList',{'get':function(){return this['_groundMirror']?this['_groundMirror']['renderList']:null;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5be0c6['prototype'],'groundMaterial',{'get':function(){return this['_groundMaterial'];},'enumerable':!0x1,'configurable':!0x0}),_0x5be0c6['prototype']['updateOptions']=function(_0x111ead){var _0x2b9eb2=Object(_0x18e13d['a'])(Object(_0x18e13d['a'])({},this['_options']),_0x111ead);this['_ground']&&!_0x2b9eb2['createGround']&&(this['_ground']['dispose'](),this['_ground']=null),this['_groundMaterial']&&!_0x2b9eb2['createGround']&&(this['_groundMaterial']['dispose'](),this['_groundMaterial']=null),this['_groundTexture']&&this['_options']['groundTexture']!=_0x2b9eb2['groundTexture']&&(this['_groundTexture']['dispose'](),this['_groundTexture']=null),this['_skybox']&&!_0x2b9eb2['createSkybox']&&(this['_skybox']['dispose'](),this['_skybox']=null),this['_skyboxMaterial']&&!_0x2b9eb2['createSkybox']&&(this['_skyboxMaterial']['dispose'](),this['_skyboxMaterial']=null),this['_skyboxTexture']&&this['_options']['skyboxTexture']!=_0x2b9eb2['skyboxTexture']&&(this['_skyboxTexture']['dispose'](),this['_skyboxTexture']=null),this['_groundMirror']&&!_0x2b9eb2['enableGroundMirror']&&(this['_groundMirror']['dispose'](),this['_groundMirror']=null),this['_scene']['environmentTexture']&&this['_options']['environmentTexture']!=_0x2b9eb2['environmentTexture']&&this['_scene']['environmentTexture']['dispose'](),this['_options']=_0x2b9eb2,this['_setupBackground'](),this['_setupImageProcessing']();},_0x5be0c6['prototype']['setMainColor']=function(_0x1e2e3f){this['groundMaterial']&&(this['groundMaterial']['primaryColor']=_0x1e2e3f),this['skyboxMaterial']&&(this['skyboxMaterial']['primaryColor']=_0x1e2e3f),this['groundMirror']&&(this['groundMirror']['clearColor']=new _0x39310d['b'](_0x1e2e3f['r'],_0x1e2e3f['g'],_0x1e2e3f['b'],0x1));},_0x5be0c6['prototype']['_setupImageProcessing']=function(){this['_options']['setupImageProcessing']&&(this['_scene']['imageProcessingConfiguration']['contrast']=this['_options']['cameraContrast'],this['_scene']['imageProcessingConfiguration']['exposure']=this['_options']['cameraExposure'],this['_scene']['imageProcessingConfiguration']['toneMappingEnabled']=this['_options']['toneMappingEnabled'],this['_setupEnvironmentTexture']());},_0x5be0c6['prototype']['_setupEnvironmentTexture']=function(){if(!this['_scene']['environmentTexture']){if(this['_options']['environmentTexture']instanceof _0x2268ea['a'])this['_scene']['environmentTexture']=this['_options']['environmentTexture'];else{var _0x18e642=_0x33892f['CreateFromPrefilteredData'](this['_options']['environmentTexture'],this['_scene']);this['_scene']['environmentTexture']=_0x18e642;}}},_0x5be0c6['prototype']['_setupBackground']=function(){this['_rootMesh']||(this['_rootMesh']=new _0x3cf5e5['a']('BackgroundHelper',this['_scene'])),this['_rootMesh']['rotation']['y']=this['_options']['backgroundYRotation'];var _0x226dfd=this['_getSceneSize']();this['_options']['createGround']&&(this['_setupGround'](_0x226dfd),this['_setupGroundMaterial'](),this['_setupGroundDiffuseTexture'](),this['_options']['enableGroundMirror']&&this['_setupGroundMirrorTexture'](_0x226dfd),this['_setupMirrorInGroundMaterial']()),this['_options']['createSkybox']&&(this['_setupSkybox'](_0x226dfd),this['_setupSkyboxMaterial'](),this['_setupSkyboxReflectionTexture']()),this['_rootMesh']['position']['x']=_0x226dfd['rootPosition']['x'],this['_rootMesh']['position']['z']=_0x226dfd['rootPosition']['z'],this['_rootMesh']['position']['y']=_0x226dfd['rootPosition']['y'];},_0x5be0c6['prototype']['_getSceneSize']=function(){var _0xfaec08=this,_0x4fec20=this['_options']['groundSize'],_0x364b53=this['_options']['skyboxSize'],_0x1fa634=this['_options']['rootPosition'];if(!this['_scene']['meshes']||0x1===this['_scene']['meshes']['length'])return{'groundSize':_0x4fec20,'skyboxSize':_0x364b53,'rootPosition':_0x1fa634};var _0x28e0f9=this['_scene']['getWorldExtends'](function(_0x4db96e){return _0x4db96e!==_0xfaec08['_ground']&&_0x4db96e!==_0xfaec08['_rootMesh']&&_0x4db96e!==_0xfaec08['_skybox'];}),_0x2cb6e8=_0x28e0f9['max']['subtract'](_0x28e0f9['min']);if(this['_options']['sizeAuto']){this['_scene']['activeCamera']instanceof _0xe57e08&&this['_scene']['activeCamera']['upperRadiusLimit']&&(_0x364b53=_0x4fec20=0x2*this['_scene']['activeCamera']['upperRadiusLimit']);var _0x2f9985=_0x2cb6e8['length']();_0x2f9985>_0x4fec20&&(_0x364b53=_0x4fec20=0x2*_0x2f9985),_0x4fec20*=1.1,_0x364b53*=1.5,(_0x1fa634=_0x28e0f9['min']['add'](_0x2cb6e8['scale'](0.5)))['y']=_0x28e0f9['min']['y']-this['_options']['groundYBias'];}return{'groundSize':_0x4fec20,'skyboxSize':_0x364b53,'rootPosition':_0x1fa634};},_0x5be0c6['prototype']['_setupGround']=function(_0x4e51ed){var _0x54dbde=this;this['_ground']&&!this['_ground']['isDisposed']()||(this['_ground']=_0x3cf5e5['a']['CreatePlane']('BackgroundPlane',_0x4e51ed['groundSize'],this['_scene']),this['_ground']['rotation']['x']=Math['PI']/0x2,this['_ground']['parent']=this['_rootMesh'],this['_ground']['onDisposeObservable']['add'](function(){_0x54dbde['_ground']=null;})),this['_ground']['receiveShadows']=this['_options']['enableGroundShadow'];},_0x5be0c6['prototype']['_setupGroundMaterial']=function(){this['_groundMaterial']||(this['_groundMaterial']=new _0x4fe332('BackgroundPlaneMaterial',this['_scene'])),this['_groundMaterial']['alpha']=this['_options']['groundOpacity'],this['_groundMaterial']['alphaMode']=_0x2103ba['a']['ALPHA_PREMULTIPLIED_PORTERDUFF'],this['_groundMaterial']['shadowLevel']=this['_options']['groundShadowLevel'],this['_groundMaterial']['primaryColor']=this['_options']['groundColor'],this['_groundMaterial']['useRGBColor']=!0x1,this['_groundMaterial']['enableNoise']=!0x0,this['_ground']&&(this['_ground']['material']=this['_groundMaterial']);},_0x5be0c6['prototype']['_setupGroundDiffuseTexture']=function(){this['_groundMaterial']&&(this['_groundTexture']||(this['_options']['groundTexture']instanceof _0x2268ea['a']?this['_groundMaterial']['diffuseTexture']=this['_options']['groundTexture']:(this['_groundTexture']=new _0xaf3c80['a'](this['_options']['groundTexture'],this['_scene'],void 0x0,void 0x0,void 0x0,void 0x0,this['_errorHandler']),this['_groundTexture']['gammaSpace']=!0x1,this['_groundTexture']['hasAlpha']=!0x0,this['_groundMaterial']['diffuseTexture']=this['_groundTexture'])));},_0x5be0c6['prototype']['_setupGroundMirrorTexture']=function(_0xe44eb0){var _0x31f16a=_0xaf3c80['a']['CLAMP_ADDRESSMODE'];if(!this['_groundMirror']&&(this['_groundMirror']=new _0xb1e723('BackgroundPlaneMirrorTexture',{'ratio':this['_options']['groundMirrorSizeRatio']},this['_scene'],!0x1,this['_options']['groundMirrorTextureType'],_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],!0x0),this['_groundMirror']['mirrorPlane']=new _0x5c8dd6['a'](0x0,-0x1,0x0,_0xe44eb0['rootPosition']['y']),this['_groundMirror']['anisotropicFilteringLevel']=0x1,this['_groundMirror']['wrapU']=_0x31f16a,this['_groundMirror']['wrapV']=_0x31f16a,this['_groundMirror']['gammaSpace']=!0x1,this['_groundMirror']['renderList']))for(var _0x38499b=0x0;_0x38499b0x0&&_0x56c787['push'](this['_texture']),this['_textureRoughness']&&this['_textureRoughness']['animations']&&this['_textureRoughness']['animations']['length']>0x0&&_0x56c787['push'](this['_textureRoughness']),this['_bumpTexture']&&this['_bumpTexture']['animations']&&this['_bumpTexture']['animations']['length']>0x0&&_0x56c787['push'](this['_bumpTexture']),this['_tintTexture']&&this['_tintTexture']['animations']&&this['_tintTexture']['animations']['length']>0x0&&_0x56c787['push'](this['_tintTexture']);},_0xb0d4e2['prototype']['dispose']=function(_0x5e6613){var _0x51cea1,_0x1222a9,_0x20d4de,_0x1b42a8;_0x5e6613&&(null===(_0x51cea1=this['_texture'])||void 0x0===_0x51cea1||_0x51cea1['dispose'](),null===(_0x1222a9=this['_textureRoughness'])||void 0x0===_0x1222a9||_0x1222a9['dispose'](),null===(_0x20d4de=this['_bumpTexture'])||void 0x0===_0x20d4de||_0x20d4de['dispose'](),null===(_0x1b42a8=this['_tintTexture'])||void 0x0===_0x1b42a8||_0x1b42a8['dispose']());},_0xb0d4e2['prototype']['getClassName']=function(){return'PBRClearCoatConfiguration';},_0xb0d4e2['AddFallbacks']=function(_0x211e6f,_0x95cd20,_0x1b9ef7){return _0x211e6f['CLEARCOAT_BUMP']&&_0x95cd20['addFallback'](_0x1b9ef7++,'CLEARCOAT_BUMP'),_0x211e6f['CLEARCOAT_TINT']&&_0x95cd20['addFallback'](_0x1b9ef7++,'CLEARCOAT_TINT'),_0x211e6f['CLEARCOAT']&&_0x95cd20['addFallback'](_0x1b9ef7++,'CLEARCOAT'),_0x1b9ef7;},_0xb0d4e2['AddUniforms']=function(_0x12d527){_0x12d527['push']('vClearCoatTangentSpaceParams','vClearCoatParams','vClearCoatRefractionParams','vClearCoatTintParams','clearCoatColorAtDistance','clearCoatMatrix','clearCoatRoughnessMatrix','clearCoatBumpMatrix','clearCoatTintMatrix','vClearCoatInfos','vClearCoatBumpInfos','vClearCoatTintInfos');},_0xb0d4e2['AddSamplers']=function(_0x2f5ad){_0x2f5ad['push']('clearCoatSampler','clearCoatRoughnessSampler','clearCoatBumpSampler','clearCoatTintSampler');},_0xb0d4e2['PrepareUniformBuffer']=function(_0x5b6391){_0x5b6391['addUniform']('vClearCoatParams',0x2),_0x5b6391['addUniform']('vClearCoatRefractionParams',0x4),_0x5b6391['addUniform']('vClearCoatInfos',0x4),_0x5b6391['addUniform']('clearCoatMatrix',0x10),_0x5b6391['addUniform']('clearCoatRoughnessMatrix',0x10),_0x5b6391['addUniform']('vClearCoatBumpInfos',0x2),_0x5b6391['addUniform']('vClearCoatTangentSpaceParams',0x2),_0x5b6391['addUniform']('clearCoatBumpMatrix',0x10),_0x5b6391['addUniform']('vClearCoatTintParams',0x4),_0x5b6391['addUniform']('clearCoatColorAtDistance',0x1),_0x5b6391['addUniform']('vClearCoatTintInfos',0x2),_0x5b6391['addUniform']('clearCoatTintMatrix',0x10);},_0xb0d4e2['prototype']['copyTo']=function(_0x5bbb3b){_0x495d06['a']['Clone'](function(){return _0x5bbb3b;},this);},_0xb0d4e2['prototype']['serialize']=function(){return _0x495d06['a']['Serialize'](this);},_0xb0d4e2['prototype']['parse']=function(_0x4cb409,_0x5ec4f2,_0x4f9d49){var _0x3e1d45=this;_0x495d06['a']['Parse'](function(){return _0x3e1d45;},_0x4cb409,_0x5ec4f2,_0x4f9d49);},_0xb0d4e2['_DefaultIndexOfRefraction']=1.5,Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0xb0d4e2['prototype'],'isEnabled',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xb0d4e2['prototype'],'intensity',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xb0d4e2['prototype'],'roughness',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0xb0d4e2['prototype'],'indexOfRefraction',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0xb0d4e2['prototype'],'texture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0xb0d4e2['prototype'],'useRoughnessFromMainTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0xb0d4e2['prototype'],'textureRoughness',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0xb0d4e2['prototype'],'remapF0OnInterfaceChange',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0xb0d4e2['prototype'],'bumpTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0xb0d4e2['prototype'],'isTintEnabled',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['e'])()],_0xb0d4e2['prototype'],'tintColor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xb0d4e2['prototype'],'tintColorAtDistance',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0xb0d4e2['prototype'],'tintThickness',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0xb0d4e2['prototype'],'tintTexture',void 0x0),_0xb0d4e2;}()),_0x41ac2f=(function(){function _0x4e019b(_0x274819){this['_isEnabled']=!0x1,this['isEnabled']=!0x1,this['intensity']=0x1,this['direction']=new _0x74d525['d'](0x1,0x0),this['_texture']=null,this['texture']=null,this['_internalMarkAllSubMeshesAsTexturesDirty']=_0x274819;}return _0x4e019b['prototype']['_markAllSubMeshesAsTexturesDirty']=function(){this['_internalMarkAllSubMeshesAsTexturesDirty']();},_0x4e019b['prototype']['isReadyForSubMesh']=function(_0x4fbf70,_0x416f52){return!(_0x4fbf70['_areTexturesDirty']&&_0x416f52['texturesEnabled']&&this['_texture']&&_0x4e6421['a']['AnisotropicTextureEnabled']&&!this['_texture']['isReadyOrNotBlocking']());},_0x4e019b['prototype']['prepareDefines']=function(_0x38c3bc,_0x3b4339,_0x4f489c){this['_isEnabled']?(_0x38c3bc['ANISOTROPIC']=this['_isEnabled'],this['_isEnabled']&&!_0x3b4339['isVerticesDataPresent'](_0x212fbd['b']['TangentKind'])&&(_0x38c3bc['_needUVs']=!0x0,_0x38c3bc['MAINUV1']=!0x0),_0x38c3bc['_areTexturesDirty']&&_0x4f489c['texturesEnabled']&&(this['_texture']&&_0x4e6421['a']['AnisotropicTextureEnabled']?_0x464f31['a']['PrepareDefinesForMergedUV'](this['_texture'],_0x38c3bc,'ANISOTROPIC_TEXTURE'):_0x38c3bc['ANISOTROPIC_TEXTURE']=!0x1)):(_0x38c3bc['ANISOTROPIC']=!0x1,_0x38c3bc['ANISOTROPIC_TEXTURE']=!0x1);},_0x4e019b['prototype']['bindForSubMesh']=function(_0x2efb44,_0x19fc8f,_0x500260){_0x2efb44['useUbo']&&_0x500260&&_0x2efb44['isSync']||(this['_texture']&&_0x4e6421['a']['AnisotropicTextureEnabled']&&(_0x2efb44['updateFloat2']('vAnisotropyInfos',this['_texture']['coordinatesIndex'],this['_texture']['level']),_0x464f31['a']['BindTextureMatrix'](this['_texture'],_0x2efb44,'anisotropy')),_0x2efb44['updateFloat3']('vAnisotropy',this['direction']['x'],this['direction']['y'],this['intensity'])),_0x19fc8f['texturesEnabled']&&this['_texture']&&_0x4e6421['a']['AnisotropicTextureEnabled']&&_0x2efb44['setTexture']('anisotropySampler',this['_texture']);},_0x4e019b['prototype']['hasTexture']=function(_0x4f188b){return this['_texture']===_0x4f188b;},_0x4e019b['prototype']['getActiveTextures']=function(_0xc08601){this['_texture']&&_0xc08601['push'](this['_texture']);},_0x4e019b['prototype']['getAnimatables']=function(_0x147647){this['_texture']&&this['_texture']['animations']&&this['_texture']['animations']['length']>0x0&&_0x147647['push'](this['_texture']);},_0x4e019b['prototype']['dispose']=function(_0x5dbefe){_0x5dbefe&&this['_texture']&&this['_texture']['dispose']();},_0x4e019b['prototype']['getClassName']=function(){return'PBRAnisotropicConfiguration';},_0x4e019b['AddFallbacks']=function(_0x2670e8,_0x2420e8,_0xc84a56){return _0x2670e8['ANISOTROPIC']&&_0x2420e8['addFallback'](_0xc84a56++,'ANISOTROPIC'),_0xc84a56;},_0x4e019b['AddUniforms']=function(_0x269e60){_0x269e60['push']('vAnisotropy','vAnisotropyInfos','anisotropyMatrix');},_0x4e019b['PrepareUniformBuffer']=function(_0x3afcdf){_0x3afcdf['addUniform']('vAnisotropy',0x3),_0x3afcdf['addUniform']('vAnisotropyInfos',0x2),_0x3afcdf['addUniform']('anisotropyMatrix',0x10);},_0x4e019b['AddSamplers']=function(_0x363376){_0x363376['push']('anisotropySampler');},_0x4e019b['prototype']['copyTo']=function(_0x5d7e26){_0x495d06['a']['Clone'](function(){return _0x5d7e26;},this);},_0x4e019b['prototype']['serialize']=function(){return _0x495d06['a']['Serialize'](this);},_0x4e019b['prototype']['parse']=function(_0x4deb10,_0x28de0b,_0x50efa2){var _0x105112=this;_0x495d06['a']['Parse'](function(){return _0x105112;},_0x4deb10,_0x28de0b,_0x50efa2);},Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x4e019b['prototype'],'isEnabled',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x4e019b['prototype'],'intensity',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['n'])()],_0x4e019b['prototype'],'direction',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x4e019b['prototype'],'texture',void 0x0),_0x4e019b;}()),_0x5738d0=(function(){function _0x55c797(_0xaf0bdd){this['_useEnergyConservation']=_0x55c797['DEFAULT_USE_ENERGY_CONSERVATION'],this['useEnergyConservation']=_0x55c797['DEFAULT_USE_ENERGY_CONSERVATION'],this['_useSmithVisibilityHeightCorrelated']=_0x55c797['DEFAULT_USE_SMITH_VISIBILITY_HEIGHT_CORRELATED'],this['useSmithVisibilityHeightCorrelated']=_0x55c797['DEFAULT_USE_SMITH_VISIBILITY_HEIGHT_CORRELATED'],this['_useSphericalHarmonics']=_0x55c797['DEFAULT_USE_SPHERICAL_HARMONICS'],this['useSphericalHarmonics']=_0x55c797['DEFAULT_USE_SPHERICAL_HARMONICS'],this['_useSpecularGlossinessInputEnergyConservation']=_0x55c797['DEFAULT_USE_SPECULAR_GLOSSINESS_INPUT_ENERGY_CONSERVATION'],this['useSpecularGlossinessInputEnergyConservation']=_0x55c797['DEFAULT_USE_SPECULAR_GLOSSINESS_INPUT_ENERGY_CONSERVATION'],this['_internalMarkAllSubMeshesAsMiscDirty']=_0xaf0bdd;}return _0x55c797['prototype']['_markAllSubMeshesAsMiscDirty']=function(){this['_internalMarkAllSubMeshesAsMiscDirty']();},_0x55c797['prototype']['prepareDefines']=function(_0x40eb6c){_0x40eb6c['BRDF_V_HEIGHT_CORRELATED']=this['_useSmithVisibilityHeightCorrelated'],_0x40eb6c['MS_BRDF_ENERGY_CONSERVATION']=this['_useEnergyConservation']&&this['_useSmithVisibilityHeightCorrelated'],_0x40eb6c['SPHERICAL_HARMONICS']=this['_useSphericalHarmonics'],_0x40eb6c['SPECULAR_GLOSSINESS_ENERGY_CONSERVATION']=this['_useSpecularGlossinessInputEnergyConservation'];},_0x55c797['prototype']['getClassName']=function(){return'PBRBRDFConfiguration';},_0x55c797['prototype']['copyTo']=function(_0x5f0a40){_0x495d06['a']['Clone'](function(){return _0x5f0a40;},this);},_0x55c797['prototype']['serialize']=function(){return _0x495d06['a']['Serialize'](this);},_0x55c797['prototype']['parse']=function(_0x297a7e,_0x8d6d47,_0x97c738){var _0x1d1d56=this;_0x495d06['a']['Parse'](function(){return _0x1d1d56;},_0x297a7e,_0x8d6d47,_0x97c738);},_0x55c797['DEFAULT_USE_ENERGY_CONSERVATION']=!0x0,_0x55c797['DEFAULT_USE_SMITH_VISIBILITY_HEIGHT_CORRELATED']=!0x0,_0x55c797['DEFAULT_USE_SPHERICAL_HARMONICS']=!0x0,_0x55c797['DEFAULT_USE_SPECULAR_GLOSSINESS_INPUT_ENERGY_CONSERVATION']=!0x0,Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsMiscDirty')],_0x55c797['prototype'],'useEnergyConservation',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsMiscDirty')],_0x55c797['prototype'],'useSmithVisibilityHeightCorrelated',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsMiscDirty')],_0x55c797['prototype'],'useSphericalHarmonics',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsMiscDirty')],_0x55c797['prototype'],'useSpecularGlossinessInputEnergyConservation',void 0x0),_0x55c797;}()),_0xc42c4d=(function(){function _0x2863eb(_0x1e5754){this['_isEnabled']=!0x1,this['isEnabled']=!0x1,this['_linkSheenWithAlbedo']=!0x1,this['linkSheenWithAlbedo']=!0x1,this['intensity']=0x1,this['color']=_0x39310d['a']['White'](),this['_texture']=null,this['texture']=null,this['_useRoughnessFromMainTexture']=!0x0,this['useRoughnessFromMainTexture']=!0x0,this['_roughness']=null,this['roughness']=null,this['_textureRoughness']=null,this['textureRoughness']=null,this['_albedoScaling']=!0x1,this['albedoScaling']=!0x1,this['_internalMarkAllSubMeshesAsTexturesDirty']=_0x1e5754;}return _0x2863eb['prototype']['_markAllSubMeshesAsTexturesDirty']=function(){this['_internalMarkAllSubMeshesAsTexturesDirty']();},_0x2863eb['prototype']['isReadyForSubMesh']=function(_0x1515ed,_0x453341){if(_0x1515ed['_areTexturesDirty']&&_0x453341['texturesEnabled']){if(this['_texture']&&_0x4e6421['a']['SheenTextureEnabled']&&!this['_texture']['isReadyOrNotBlocking']())return!0x1;if(this['_textureRoughness']&&_0x4e6421['a']['SheenTextureEnabled']&&!this['_textureRoughness']['isReadyOrNotBlocking']())return!0x1;}return!0x0;},_0x2863eb['prototype']['prepareDefines']=function(_0x6e2467,_0x9e64a){var _0x5c3cd9;this['_isEnabled']?(_0x6e2467['SHEEN']=this['_isEnabled'],_0x6e2467['SHEEN_LINKWITHALBEDO']=this['_linkSheenWithAlbedo'],_0x6e2467['SHEEN_ROUGHNESS']=null!==this['_roughness'],_0x6e2467['SHEEN_ALBEDOSCALING']=this['_albedoScaling'],_0x6e2467['SHEEN_USE_ROUGHNESS_FROM_MAINTEXTURE']=this['_useRoughnessFromMainTexture'],_0x6e2467['SHEEN_TEXTURE_ROUGHNESS_IDENTICAL']=null!==this['_texture']&&this['_texture']['_texture']===(null===(_0x5c3cd9=this['_textureRoughness'])||void 0x0===_0x5c3cd9?void 0x0:_0x5c3cd9['_texture'])&&this['_texture']['checkTransformsAreIdentical'](this['_textureRoughness']),_0x6e2467['_areTexturesDirty']&&_0x9e64a['texturesEnabled']&&(this['_texture']&&_0x4e6421['a']['SheenTextureEnabled']?_0x464f31['a']['PrepareDefinesForMergedUV'](this['_texture'],_0x6e2467,'SHEEN_TEXTURE'):_0x6e2467['SHEEN_TEXTURE']=!0x1,this['_textureRoughness']&&_0x4e6421['a']['SheenTextureEnabled']?_0x464f31['a']['PrepareDefinesForMergedUV'](this['_textureRoughness'],_0x6e2467,'SHEEN_TEXTURE_ROUGHNESS'):_0x6e2467['SHEEN_TEXTURE_ROUGHNESS']=!0x1)):(_0x6e2467['SHEEN']=!0x1,_0x6e2467['SHEEN_TEXTURE']=!0x1,_0x6e2467['SHEEN_TEXTURE_ROUGHNESS']=!0x1,_0x6e2467['SHEEN_LINKWITHALBEDO']=!0x1,_0x6e2467['SHEEN_ROUGHNESS']=!0x1,_0x6e2467['SHEEN_ALBEDOSCALING']=!0x1,_0x6e2467['SHEEN_USE_ROUGHNESS_FROM_MAINTEXTURE']=!0x1,_0x6e2467['SHEEN_TEXTURE_ROUGHNESS_IDENTICAL']=!0x1);},_0x2863eb['prototype']['bindForSubMesh']=function(_0x17b608,_0x366891,_0x26254c,_0x3976d9){var _0x4a81e5,_0x37d71f,_0x286c4b,_0x59b498,_0x392c1b,_0x2f4083,_0x1c2ac0,_0x57799e,_0x3ec82d=_0x3976d9['_materialDefines'],_0x369987=_0x3ec82d['SHEEN_TEXTURE_ROUGHNESS_IDENTICAL'];_0x17b608['useUbo']&&_0x26254c&&_0x17b608['isSync']||(_0x369987&&_0x4e6421['a']['SheenTextureEnabled']?(_0x17b608['updateFloat4']('vSheenInfos',this['_texture']['coordinatesIndex'],this['_texture']['level'],-0x1,-0x1),_0x464f31['a']['BindTextureMatrix'](this['_texture'],_0x17b608,'sheen')):(this['_texture']||this['_textureRoughness'])&&_0x4e6421['a']['SheenTextureEnabled']&&(_0x17b608['updateFloat4']('vSheenInfos',null!==(_0x37d71f=null===(_0x4a81e5=this['_texture'])||void 0x0===_0x4a81e5?void 0x0:_0x4a81e5['coordinatesIndex'])&&void 0x0!==_0x37d71f?_0x37d71f:0x0,null!==(_0x59b498=null===(_0x286c4b=this['_texture'])||void 0x0===_0x286c4b?void 0x0:_0x286c4b['level'])&&void 0x0!==_0x59b498?_0x59b498:0x0,null!==(_0x2f4083=null===(_0x392c1b=this['_textureRoughness'])||void 0x0===_0x392c1b?void 0x0:_0x392c1b['coordinatesIndex'])&&void 0x0!==_0x2f4083?_0x2f4083:0x0,null!==(_0x57799e=null===(_0x1c2ac0=this['_textureRoughness'])||void 0x0===_0x1c2ac0?void 0x0:_0x1c2ac0['level'])&&void 0x0!==_0x57799e?_0x57799e:0x0),this['_texture']&&_0x464f31['a']['BindTextureMatrix'](this['_texture'],_0x17b608,'sheen'),!this['_textureRoughness']||_0x369987||_0x3ec82d['SHEEN_USE_ROUGHNESS_FROM_MAINTEXTURE']||_0x464f31['a']['BindTextureMatrix'](this['_textureRoughness'],_0x17b608,'sheenRoughness')),_0x17b608['updateFloat4']('vSheenColor',this['color']['r'],this['color']['g'],this['color']['b'],this['intensity']),null!==this['_roughness']&&_0x17b608['updateFloat']('vSheenRoughness',this['_roughness'])),_0x366891['texturesEnabled']&&(this['_texture']&&_0x4e6421['a']['SheenTextureEnabled']&&_0x17b608['setTexture']('sheenSampler',this['_texture']),this['_textureRoughness']&&!_0x369987&&!_0x3ec82d['SHEEN_USE_ROUGHNESS_FROM_MAINTEXTURE']&&_0x4e6421['a']['SheenTextureEnabled']&&_0x17b608['setTexture']('sheenRoughnessSampler',this['_textureRoughness']));},_0x2863eb['prototype']['hasTexture']=function(_0x5cf28e){return this['_texture']===_0x5cf28e||this['_textureRoughness']===_0x5cf28e;},_0x2863eb['prototype']['getActiveTextures']=function(_0x2a6c8e){this['_texture']&&_0x2a6c8e['push'](this['_texture']),this['_textureRoughness']&&_0x2a6c8e['push'](this['_textureRoughness']);},_0x2863eb['prototype']['getAnimatables']=function(_0x20b068){this['_texture']&&this['_texture']['animations']&&this['_texture']['animations']['length']>0x0&&_0x20b068['push'](this['_texture']),this['_textureRoughness']&&this['_textureRoughness']['animations']&&this['_textureRoughness']['animations']['length']>0x0&&_0x20b068['push'](this['_textureRoughness']);},_0x2863eb['prototype']['dispose']=function(_0x208576){var _0x5465d3,_0x26ec12;_0x208576&&(null===(_0x5465d3=this['_texture'])||void 0x0===_0x5465d3||_0x5465d3['dispose'](),null===(_0x26ec12=this['_textureRoughness'])||void 0x0===_0x26ec12||_0x26ec12['dispose']());},_0x2863eb['prototype']['getClassName']=function(){return'PBRSheenConfiguration';},_0x2863eb['AddFallbacks']=function(_0x24027c,_0x573c9c,_0x220fb3){return _0x24027c['SHEEN']&&_0x573c9c['addFallback'](_0x220fb3++,'SHEEN'),_0x220fb3;},_0x2863eb['AddUniforms']=function(_0x3130da){_0x3130da['push']('vSheenColor','vSheenRoughness','vSheenInfos','sheenMatrix','sheenRoughnessMatrix');},_0x2863eb['PrepareUniformBuffer']=function(_0x3a3caa){_0x3a3caa['addUniform']('vSheenColor',0x4),_0x3a3caa['addUniform']('vSheenRoughness',0x1),_0x3a3caa['addUniform']('vSheenInfos',0x4),_0x3a3caa['addUniform']('sheenMatrix',0x10),_0x3a3caa['addUniform']('sheenRoughnessMatrix',0x10);},_0x2863eb['AddSamplers']=function(_0x1cc5f0){_0x1cc5f0['push']('sheenSampler'),_0x1cc5f0['push']('sheenRoughnessSampler');},_0x2863eb['prototype']['copyTo']=function(_0x318391){_0x495d06['a']['Clone'](function(){return _0x318391;},this);},_0x2863eb['prototype']['serialize']=function(){return _0x495d06['a']['Serialize'](this);},_0x2863eb['prototype']['parse']=function(_0x2be962,_0x56def2,_0x11d7a0){var _0x47bbdf=this;_0x495d06['a']['Parse'](function(){return _0x47bbdf;},_0x2be962,_0x56def2,_0x11d7a0);},Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x2863eb['prototype'],'isEnabled',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x2863eb['prototype'],'linkSheenWithAlbedo',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x2863eb['prototype'],'intensity',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['e'])()],_0x2863eb['prototype'],'color',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x2863eb['prototype'],'texture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x2863eb['prototype'],'useRoughnessFromMainTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x2863eb['prototype'],'roughness',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x2863eb['prototype'],'textureRoughness',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x2863eb['prototype'],'albedoScaling',void 0x0),_0x2863eb;}()),_0x582aa7=(function(){function _0x4f5728(_0x27739d,_0xcf888a,_0x3ddaa9){this['_isRefractionEnabled']=!0x1,this['isRefractionEnabled']=!0x1,this['_isTranslucencyEnabled']=!0x1,this['isTranslucencyEnabled']=!0x1,this['_isScatteringEnabled']=!0x1,this['isScatteringEnabled']=!0x1,this['_scatteringDiffusionProfileIndex']=0x0,this['refractionIntensity']=0x1,this['translucencyIntensity']=0x1,this['useAlbedoToTintRefraction']=!0x1,this['_thicknessTexture']=null,this['thicknessTexture']=null,this['_refractionTexture']=null,this['refractionTexture']=null,this['_indexOfRefraction']=1.5,this['indexOfRefraction']=1.5,this['_volumeIndexOfRefraction']=-0x1,this['_invertRefractionY']=!0x1,this['invertRefractionY']=!0x1,this['_linkRefractionWithTransparency']=!0x1,this['linkRefractionWithTransparency']=!0x1,this['minimumThickness']=0x0,this['maximumThickness']=0x1,this['tintColor']=_0x39310d['a']['White'](),this['tintColorAtDistance']=0x1,this['diffusionDistance']=_0x39310d['a']['White'](),this['_useMaskFromThicknessTexture']=!0x1,this['useMaskFromThicknessTexture']=!0x1,this['_useMaskFromThicknessTextureGltf']=!0x1,this['useMaskFromThicknessTextureGltf']=!0x1,this['_internalMarkAllSubMeshesAsTexturesDirty']=_0x27739d,this['_internalMarkScenePrePassDirty']=_0xcf888a,this['_scene']=_0x3ddaa9;}return Object['defineProperty'](_0x4f5728['prototype'],'scatteringDiffusionProfile',{'get':function(){return this['_scene']['subSurfaceConfiguration']?this['_scene']['subSurfaceConfiguration']['ssDiffusionProfileColors'][this['_scatteringDiffusionProfileIndex']]:null;},'set':function(_0x4ef787){this['_scene']['enableSubSurfaceForPrePass']()&&_0x4ef787&&(this['_scatteringDiffusionProfileIndex']=this['_scene']['subSurfaceConfiguration']['addDiffusionProfile'](_0x4ef787));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4f5728['prototype'],'volumeIndexOfRefraction',{'get':function(){return this['_volumeIndexOfRefraction']>=0x1?this['_volumeIndexOfRefraction']:this['_indexOfRefraction'];},'set':function(_0x3832ae){this['_volumeIndexOfRefraction']=_0x3832ae>=0x1?_0x3832ae:-0x1;},'enumerable':!0x1,'configurable':!0x0}),_0x4f5728['prototype']['_markAllSubMeshesAsTexturesDirty']=function(){this['_internalMarkAllSubMeshesAsTexturesDirty']();},_0x4f5728['prototype']['_markScenePrePassDirty']=function(){this['_internalMarkAllSubMeshesAsTexturesDirty'](),this['_internalMarkScenePrePassDirty']();},_0x4f5728['prototype']['isReadyForSubMesh']=function(_0xa6fbb3,_0x2571e1){if(_0xa6fbb3['_areTexturesDirty']&&_0x2571e1['texturesEnabled']){if(this['_thicknessTexture']&&_0x4e6421['a']['ThicknessTextureEnabled']&&!this['_thicknessTexture']['isReadyOrNotBlocking']())return!0x1;var _0x3954c5=this['_getRefractionTexture'](_0x2571e1);if(_0x3954c5&&_0x4e6421['a']['RefractionTextureEnabled']&&!_0x3954c5['isReadyOrNotBlocking']())return!0x1;}return!0x0;},_0x4f5728['prototype']['prepareDefines']=function(_0x4b2254,_0x131a1b){if(_0x4b2254['_areTexturesDirty']&&(_0x4b2254['SUBSURFACE']=!0x1,_0x4b2254['SS_TRANSLUCENCY']=this['_isTranslucencyEnabled'],_0x4b2254['SS_SCATTERING']=this['_isScatteringEnabled'],_0x4b2254['SS_THICKNESSANDMASK_TEXTURE']=!0x1,_0x4b2254['SS_MASK_FROM_THICKNESS_TEXTURE']=!0x1,_0x4b2254['SS_MASK_FROM_THICKNESS_TEXTURE_GLTF']=!0x1,_0x4b2254['SS_REFRACTION']=!0x1,_0x4b2254['SS_REFRACTIONMAP_3D']=!0x1,_0x4b2254['SS_GAMMAREFRACTION']=!0x1,_0x4b2254['SS_RGBDREFRACTION']=!0x1,_0x4b2254['SS_LINEARSPECULARREFRACTION']=!0x1,_0x4b2254['SS_REFRACTIONMAP_OPPOSITEZ']=!0x1,_0x4b2254['SS_LODINREFRACTIONALPHA']=!0x1,_0x4b2254['SS_LINKREFRACTIONTOTRANSPARENCY']=!0x1,_0x4b2254['SS_ALBEDOFORREFRACTIONTINT']=!0x1,(this['_isRefractionEnabled']||this['_isTranslucencyEnabled']||this['_isScatteringEnabled'])&&(_0x4b2254['SUBSURFACE']=!0x0,_0x4b2254['_areTexturesDirty']&&_0x131a1b['texturesEnabled']&&this['_thicknessTexture']&&_0x4e6421['a']['ThicknessTextureEnabled']&&_0x464f31['a']['PrepareDefinesForMergedUV'](this['_thicknessTexture'],_0x4b2254,'SS_THICKNESSANDMASK_TEXTURE'),_0x4b2254['SS_MASK_FROM_THICKNESS_TEXTURE']=this['_useMaskFromThicknessTexture'],_0x4b2254['SS_MASK_FROM_THICKNESS_TEXTURE_GLTF']=this['_useMaskFromThicknessTextureGltf']),this['_isRefractionEnabled']&&_0x131a1b['texturesEnabled'])){var _0x57159a=this['_getRefractionTexture'](_0x131a1b);_0x57159a&&_0x4e6421['a']['RefractionTextureEnabled']&&(_0x4b2254['SS_REFRACTION']=!0x0,_0x4b2254['SS_REFRACTIONMAP_3D']=_0x57159a['isCube'],_0x4b2254['SS_GAMMAREFRACTION']=_0x57159a['gammaSpace'],_0x4b2254['SS_RGBDREFRACTION']=_0x57159a['isRGBD'],_0x4b2254['SS_LINEARSPECULARREFRACTION']=_0x57159a['linearSpecularLOD'],_0x4b2254['SS_REFRACTIONMAP_OPPOSITEZ']=_0x57159a['invertZ'],_0x4b2254['SS_LODINREFRACTIONALPHA']=_0x57159a['lodLevelInAlpha'],_0x4b2254['SS_LINKREFRACTIONTOTRANSPARENCY']=this['_linkRefractionWithTransparency'],_0x4b2254['SS_ALBEDOFORREFRACTIONTINT']=this['useAlbedoToTintRefraction']);}},_0x4f5728['prototype']['bindForSubMesh']=function(_0x4389c8,_0x20e81f,_0x3bfde6,_0x15e773,_0x28caae,_0x1b254d){var _0x51a476=this['_getRefractionTexture'](_0x20e81f);if(!_0x4389c8['useUbo']||!_0x15e773||!_0x4389c8['isSync']){if(this['_thicknessTexture']&&_0x4e6421['a']['ThicknessTextureEnabled']&&(_0x4389c8['updateFloat2']('vThicknessInfos',this['_thicknessTexture']['coordinatesIndex'],this['_thicknessTexture']['level']),_0x464f31['a']['BindTextureMatrix'](this['_thicknessTexture'],_0x4389c8,'thickness')),_0x4389c8['updateFloat2']('vThicknessParam',this['minimumThickness'],this['maximumThickness']-this['minimumThickness']),_0x51a476&&_0x4e6421['a']['RefractionTextureEnabled']){_0x4389c8['updateMatrix']('refractionMatrix',_0x51a476['getReflectionTextureMatrix']());var _0xa36157=0x1;_0x51a476['isCube']||_0x51a476['depth']&&(_0xa36157=_0x51a476['depth']);var _0x3d4217=_0x51a476['getSize']()['width'],_0x289961=this['volumeIndexOfRefraction'];_0x4389c8['updateFloat4']('vRefractionInfos',_0x51a476['level'],0x1/_0x289961,_0xa36157,this['_invertRefractionY']?-0x1:0x1),_0x4389c8['updateFloat3']('vRefractionMicrosurfaceInfos',_0x3d4217,_0x51a476['lodGenerationScale'],_0x51a476['lodGenerationOffset']),_0x1b254d&&_0x4389c8['updateFloat2']('vRefractionFilteringInfo',_0x3d4217,_0x4a0cf0['a']['Log2'](_0x3d4217));}this['isScatteringEnabled']&&_0x4389c8['updateFloat']('scatteringDiffusionProfile',this['_scatteringDiffusionProfileIndex']),_0x4389c8['updateColor3']('vDiffusionDistance',this['diffusionDistance']),_0x4389c8['updateFloat4']('vTintColor',this['tintColor']['r'],this['tintColor']['g'],this['tintColor']['b'],this['tintColorAtDistance']),_0x4389c8['updateFloat3']('vSubSurfaceIntensity',this['refractionIntensity'],this['translucencyIntensity'],0x0);}_0x20e81f['texturesEnabled']&&(this['_thicknessTexture']&&_0x4e6421['a']['ThicknessTextureEnabled']&&_0x4389c8['setTexture']('thicknessSampler',this['_thicknessTexture']),_0x51a476&&_0x4e6421['a']['RefractionTextureEnabled']&&(_0x28caae?_0x4389c8['setTexture']('refractionSampler',_0x51a476):(_0x4389c8['setTexture']('refractionSampler',_0x51a476['_lodTextureMid']||_0x51a476),_0x4389c8['setTexture']('refractionSamplerLow',_0x51a476['_lodTextureLow']||_0x51a476),_0x4389c8['setTexture']('refractionSamplerHigh',_0x51a476['_lodTextureHigh']||_0x51a476))));},_0x4f5728['prototype']['unbind']=function(_0x2c80be){return!(!this['_refractionTexture']||!this['_refractionTexture']['isRenderTarget'])&&(_0x2c80be['setTexture']('refractionSampler',null),!0x0);},_0x4f5728['prototype']['_getRefractionTexture']=function(_0x37c589){return this['_refractionTexture']?this['_refractionTexture']:this['_isRefractionEnabled']?_0x37c589['environmentTexture']:null;},Object['defineProperty'](_0x4f5728['prototype'],'disableAlphaBlending',{'get':function(){return this['isRefractionEnabled']&&this['_linkRefractionWithTransparency'];},'enumerable':!0x1,'configurable':!0x0}),_0x4f5728['prototype']['fillRenderTargetTextures']=function(_0x4840ff){_0x4e6421['a']['RefractionTextureEnabled']&&this['_refractionTexture']&&this['_refractionTexture']['isRenderTarget']&&_0x4840ff['push'](this['_refractionTexture']);},_0x4f5728['prototype']['hasTexture']=function(_0x3c3801){return this['_thicknessTexture']===_0x3c3801||this['_refractionTexture']===_0x3c3801;},_0x4f5728['prototype']['hasRenderTargetTextures']=function(){return!!(_0x4e6421['a']['RefractionTextureEnabled']&&this['_refractionTexture']&&this['_refractionTexture']['isRenderTarget']);},_0x4f5728['prototype']['getActiveTextures']=function(_0x66f9b2){this['_thicknessTexture']&&_0x66f9b2['push'](this['_thicknessTexture']),this['_refractionTexture']&&_0x66f9b2['push'](this['_refractionTexture']);},_0x4f5728['prototype']['getAnimatables']=function(_0x3a3b5e){this['_thicknessTexture']&&this['_thicknessTexture']['animations']&&this['_thicknessTexture']['animations']['length']>0x0&&_0x3a3b5e['push'](this['_thicknessTexture']),this['_refractionTexture']&&this['_refractionTexture']['animations']&&this['_refractionTexture']['animations']['length']>0x0&&_0x3a3b5e['push'](this['_refractionTexture']);},_0x4f5728['prototype']['dispose']=function(_0x4c0c32){_0x4c0c32&&(this['_thicknessTexture']&&this['_thicknessTexture']['dispose'](),this['_refractionTexture']&&this['_refractionTexture']['dispose']());},_0x4f5728['prototype']['getClassName']=function(){return'PBRSubSurfaceConfiguration';},_0x4f5728['AddFallbacks']=function(_0x2019ba,_0x3a2d70,_0x14ac1b){return _0x2019ba['SS_SCATTERING']&&_0x3a2d70['addFallback'](_0x14ac1b++,'SS_SCATTERING'),_0x2019ba['SS_TRANSLUCENCY']&&_0x3a2d70['addFallback'](_0x14ac1b++,'SS_TRANSLUCENCY'),_0x14ac1b;},_0x4f5728['AddUniforms']=function(_0x6d7e6f){_0x6d7e6f['push']('vDiffusionDistance','vTintColor','vSubSurfaceIntensity','vRefractionMicrosurfaceInfos','vRefractionFilteringInfo','vRefractionInfos','vThicknessInfos','vThicknessParam','refractionMatrix','thicknessMatrix','scatteringDiffusionProfile');},_0x4f5728['AddSamplers']=function(_0x55198e){_0x55198e['push']('thicknessSampler','refractionSampler','refractionSamplerLow','refractionSamplerHigh');},_0x4f5728['PrepareUniformBuffer']=function(_0x12ea98){_0x12ea98['addUniform']('vRefractionMicrosurfaceInfos',0x3),_0x12ea98['addUniform']('vRefractionFilteringInfo',0x2),_0x12ea98['addUniform']('vRefractionInfos',0x4),_0x12ea98['addUniform']('refractionMatrix',0x10),_0x12ea98['addUniform']('vThicknessInfos',0x2),_0x12ea98['addUniform']('thicknessMatrix',0x10),_0x12ea98['addUniform']('vThicknessParam',0x2),_0x12ea98['addUniform']('vDiffusionDistance',0x3),_0x12ea98['addUniform']('vTintColor',0x4),_0x12ea98['addUniform']('vSubSurfaceIntensity',0x3),_0x12ea98['addUniform']('scatteringDiffusionProfile',0x1);},_0x4f5728['prototype']['copyTo']=function(_0x466d22){_0x495d06['a']['Clone'](function(){return _0x466d22;},this);},_0x4f5728['prototype']['serialize']=function(){return _0x495d06['a']['Serialize'](this);},_0x4f5728['prototype']['parse']=function(_0xeb52d9,_0x24e575,_0xf351d6){var _0x46f3a0=this;_0x495d06['a']['Parse'](function(){return _0x46f3a0;},_0xeb52d9,_0x24e575,_0xf351d6);},Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x4f5728['prototype'],'isRefractionEnabled',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x4f5728['prototype'],'isTranslucencyEnabled',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markScenePrePassDirty')],_0x4f5728['prototype'],'isScatteringEnabled',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x4f5728['prototype'],'_scatteringDiffusionProfileIndex',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x4f5728['prototype'],'refractionIntensity',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x4f5728['prototype'],'translucencyIntensity',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x4f5728['prototype'],'useAlbedoToTintRefraction',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x4f5728['prototype'],'thicknessTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x4f5728['prototype'],'refractionTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x4f5728['prototype'],'indexOfRefraction',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x4f5728['prototype'],'_volumeIndexOfRefraction',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x4f5728['prototype'],'volumeIndexOfRefraction',null),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x4f5728['prototype'],'invertRefractionY',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x4f5728['prototype'],'linkRefractionWithTransparency',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x4f5728['prototype'],'minimumThickness',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x4f5728['prototype'],'maximumThickness',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['e'])()],_0x4f5728['prototype'],'tintColor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x4f5728['prototype'],'tintColorAtDistance',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['e'])()],_0x4f5728['prototype'],'diffusionDistance',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x4f5728['prototype'],'useMaskFromThicknessTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x4f5728['prototype'],'useMaskFromThicknessTextureGltf',void 0x0),_0x4f5728;}()),_0x3f0e23=_0x162675(0x69),_0x33c2e5=_0x162675(0x19),_0x15ec2e=(_0x162675(0xa0),'uniform\x20vec3\x20vReflectionColor;\x0auniform\x20vec4\x20vAlbedoColor;\x0a\x0auniform\x20vec4\x20vLightingIntensity;\x0auniform\x20vec4\x20vReflectivityColor;\x0auniform\x20vec4\x20vMetallicReflectanceFactors;\x0auniform\x20vec3\x20vEmissiveColor;\x0auniform\x20float\x20visibility;\x0a\x0a#ifdef\x20ALBEDO\x0auniform\x20vec2\x20vAlbedoInfos;\x0a#endif\x0a#ifdef\x20AMBIENT\x0auniform\x20vec4\x20vAmbientInfos;\x0a#endif\x0a#ifdef\x20BUMP\x0auniform\x20vec3\x20vBumpInfos;\x0auniform\x20vec2\x20vTangentSpaceParams;\x0a#endif\x0a#ifdef\x20OPACITY\x0auniform\x20vec2\x20vOpacityInfos;\x0a#endif\x0a#ifdef\x20EMISSIVE\x0auniform\x20vec2\x20vEmissiveInfos;\x0a#endif\x0a#ifdef\x20LIGHTMAP\x0auniform\x20vec2\x20vLightmapInfos;\x0a#endif\x0a#ifdef\x20REFLECTIVITY\x0auniform\x20vec3\x20vReflectivityInfos;\x0a#endif\x0a#ifdef\x20MICROSURFACEMAP\x0auniform\x20vec2\x20vMicroSurfaceSamplerInfos;\x0a#endif\x0a\x0a#if\x20defined(REFLECTIONMAP_SPHERICAL)\x20||\x20defined(REFLECTIONMAP_PROJECTION)\x20||\x20defined(SS_REFRACTION)\x0auniform\x20mat4\x20view;\x0a#endif\x0a\x0a#ifdef\x20REFLECTION\x0auniform\x20vec2\x20vReflectionInfos;\x0a#ifdef\x20REALTIME_FILTERING\x0auniform\x20vec2\x20vReflectionFilteringInfo;\x0a#endif\x0auniform\x20mat4\x20reflectionMatrix;\x0auniform\x20vec3\x20vReflectionMicrosurfaceInfos;\x0a#if\x20defined(USE_LOCAL_REFLECTIONMAP_CUBIC)\x20&&\x20defined(REFLECTIONMAP_CUBIC)\x0auniform\x20vec3\x20vReflectionPosition;\x0auniform\x20vec3\x20vReflectionSize;\x0a#endif\x0a#endif\x0a\x0a#ifdef\x20CLEARCOAT\x0auniform\x20vec2\x20vClearCoatParams;\x0auniform\x20vec4\x20vClearCoatRefractionParams;\x0a#if\x20defined(CLEARCOAT_TEXTURE)\x20||\x20defined(CLEARCOAT_TEXTURE_ROUGHNESS)\x0auniform\x20vec4\x20vClearCoatInfos;\x0a#endif\x0a#ifdef\x20CLEARCOAT_TEXTURE\x0auniform\x20mat4\x20clearCoatMatrix;\x0a#endif\x0a#ifdef\x20CLEARCOAT_TEXTURE_ROUGHNESS\x0auniform\x20mat4\x20clearCoatRoughnessMatrix;\x0a#endif\x0a#ifdef\x20CLEARCOAT_BUMP\x0auniform\x20vec2\x20vClearCoatBumpInfos;\x0auniform\x20vec2\x20vClearCoatTangentSpaceParams;\x0auniform\x20mat4\x20clearCoatBumpMatrix;\x0a#endif\x0a#ifdef\x20CLEARCOAT_TINT\x0auniform\x20vec4\x20vClearCoatTintParams;\x0auniform\x20float\x20clearCoatColorAtDistance;\x0a#ifdef\x20CLEARCOAT_TINT_TEXTURE\x0auniform\x20vec2\x20vClearCoatTintInfos;\x0auniform\x20mat4\x20clearCoatTintMatrix;\x0a#endif\x0a#endif\x0a#endif\x0a\x0a#ifdef\x20ANISOTROPIC\x0auniform\x20vec3\x20vAnisotropy;\x0a#ifdef\x20ANISOTROPIC_TEXTURE\x0auniform\x20vec2\x20vAnisotropyInfos;\x0auniform\x20mat4\x20anisotropyMatrix;\x0a#endif\x0a#endif\x0a\x0a#ifdef\x20SHEEN\x0auniform\x20vec4\x20vSheenColor;\x0a#ifdef\x20SHEEN_ROUGHNESS\x0auniform\x20float\x20vSheenRoughness;\x0a#endif\x0a#if\x20defined(SHEEN_TEXTURE)\x20||\x20defined(SHEEN_TEXTURE_ROUGHNESS)\x0auniform\x20vec4\x20vSheenInfos;\x0a#endif\x0a#ifdef\x20SHEEN_TEXTURE\x0auniform\x20mat4\x20sheenMatrix;\x0a#endif\x0a#ifdef\x20SHEEN_TEXTURE_ROUGHNESS\x0auniform\x20mat4\x20sheenRoughnessMatrix;\x0a#endif\x0a#endif\x0a\x0a#ifdef\x20SUBSURFACE\x0a#ifdef\x20SS_REFRACTION\x0auniform\x20vec3\x20vRefractionMicrosurfaceInfos;\x0auniform\x20vec4\x20vRefractionInfos;\x0auniform\x20mat4\x20refractionMatrix;\x0a#ifdef\x20REALTIME_FILTERING\x0auniform\x20vec2\x20vRefractionFilteringInfo;\x0a#endif\x0a#endif\x0a#ifdef\x20SS_THICKNESSANDMASK_TEXTURE\x0auniform\x20vec2\x20vThicknessInfos;\x0auniform\x20mat4\x20thicknessMatrix;\x0a#endif\x0auniform\x20vec2\x20vThicknessParam;\x0auniform\x20vec3\x20vDiffusionDistance;\x0auniform\x20vec4\x20vTintColor;\x0auniform\x20vec3\x20vSubSurfaceIntensity;\x0a#endif\x0a#ifdef\x20PREPASS\x0a#ifdef\x20PREPASS_IRRADIANCE\x0auniform\x20float\x20scatteringDiffusionProfile;\x0a#endif\x0a#endif');_0x494b01['a']['IncludesShadersStore']['pbrFragmentDeclaration']=_0x15ec2e;var _0x35ee7c='layout(std140,column_major)\x20uniform;\x0auniform\x20Material\x0a{\x0auniform\x20vec2\x20vAlbedoInfos;\x0auniform\x20vec4\x20vAmbientInfos;\x0auniform\x20vec2\x20vOpacityInfos;\x0auniform\x20vec2\x20vEmissiveInfos;\x0auniform\x20vec2\x20vLightmapInfos;\x0auniform\x20vec3\x20vReflectivityInfos;\x0auniform\x20vec2\x20vMicroSurfaceSamplerInfos;\x0auniform\x20vec2\x20vReflectionInfos;\x0auniform\x20vec2\x20vReflectionFilteringInfo;\x0auniform\x20vec3\x20vReflectionPosition;\x0auniform\x20vec3\x20vReflectionSize;\x0auniform\x20vec3\x20vBumpInfos;\x0auniform\x20mat4\x20albedoMatrix;\x0auniform\x20mat4\x20ambientMatrix;\x0auniform\x20mat4\x20opacityMatrix;\x0auniform\x20mat4\x20emissiveMatrix;\x0auniform\x20mat4\x20lightmapMatrix;\x0auniform\x20mat4\x20reflectivityMatrix;\x0auniform\x20mat4\x20microSurfaceSamplerMatrix;\x0auniform\x20mat4\x20bumpMatrix;\x0auniform\x20vec2\x20vTangentSpaceParams;\x0auniform\x20mat4\x20reflectionMatrix;\x0auniform\x20vec3\x20vReflectionColor;\x0auniform\x20vec4\x20vAlbedoColor;\x0auniform\x20vec4\x20vLightingIntensity;\x0auniform\x20vec3\x20vReflectionMicrosurfaceInfos;\x0auniform\x20float\x20pointSize;\x0auniform\x20vec4\x20vReflectivityColor;\x0auniform\x20vec3\x20vEmissiveColor;\x0auniform\x20float\x20visibility;\x0auniform\x20vec4\x20vMetallicReflectanceFactors;\x0auniform\x20vec2\x20vMetallicReflectanceInfos;\x0auniform\x20mat4\x20metallicReflectanceMatrix;\x0auniform\x20vec2\x20vClearCoatParams;\x0auniform\x20vec4\x20vClearCoatRefractionParams;\x0auniform\x20vec4\x20vClearCoatInfos;\x0auniform\x20mat4\x20clearCoatMatrix;\x0auniform\x20mat4\x20clearCoatRoughnessMatrix;\x0auniform\x20vec2\x20vClearCoatBumpInfos;\x0auniform\x20vec2\x20vClearCoatTangentSpaceParams;\x0auniform\x20mat4\x20clearCoatBumpMatrix;\x0auniform\x20vec4\x20vClearCoatTintParams;\x0auniform\x20float\x20clearCoatColorAtDistance;\x0auniform\x20vec2\x20vClearCoatTintInfos;\x0auniform\x20mat4\x20clearCoatTintMatrix;\x0auniform\x20vec3\x20vAnisotropy;\x0auniform\x20vec2\x20vAnisotropyInfos;\x0auniform\x20mat4\x20anisotropyMatrix;\x0auniform\x20vec4\x20vSheenColor;\x0auniform\x20float\x20vSheenRoughness;\x0auniform\x20vec4\x20vSheenInfos;\x0auniform\x20mat4\x20sheenMatrix;\x0auniform\x20mat4\x20sheenRoughnessMatrix;\x0auniform\x20vec3\x20vRefractionMicrosurfaceInfos;\x0auniform\x20vec2\x20vRefractionFilteringInfo;\x0auniform\x20vec4\x20vRefractionInfos;\x0auniform\x20mat4\x20refractionMatrix;\x0auniform\x20vec2\x20vThicknessInfos;\x0auniform\x20mat4\x20thicknessMatrix;\x0auniform\x20vec2\x20vThicknessParam;\x0auniform\x20vec3\x20vDiffusionDistance;\x0auniform\x20vec4\x20vTintColor;\x0auniform\x20vec3\x20vSubSurfaceIntensity;\x0auniform\x20float\x20scatteringDiffusionProfile;\x0auniform\x20vec4\x20vDetailInfos;\x0auniform\x20mat4\x20detailMatrix;\x0a};\x0auniform\x20Scene\x20{\x0amat4\x20viewProjection;\x0a#ifdef\x20MULTIVIEW\x0amat4\x20viewProjectionR;\x0a#endif\x0amat4\x20view;\x0a};';_0x494b01['a']['IncludesShadersStore']['pbrUboDeclaration']=_0x35ee7c;var _0x4467eb='uniform\x20vec4\x20vEyePosition;\x0auniform\x20vec3\x20vAmbientColor;\x0auniform\x20vec4\x20vCameraInfos;\x0a\x0avarying\x20vec3\x20vPositionW;\x0a#if\x20DEBUGMODE>0\x0auniform\x20vec2\x20vDebugMode;\x0avarying\x20vec4\x20vClipSpacePosition;\x0a#endif\x0a#ifdef\x20MAINUV1\x0avarying\x20vec2\x20vMainUV1;\x0a#endif\x0a#ifdef\x20MAINUV2\x0avarying\x20vec2\x20vMainUV2;\x0a#endif\x0a#ifdef\x20NORMAL\x0avarying\x20vec3\x20vNormalW;\x0a#if\x20defined(USESPHERICALFROMREFLECTIONMAP)\x20&&\x20defined(USESPHERICALINVERTEX)\x0avarying\x20vec3\x20vEnvironmentIrradiance;\x0a#endif\x0a#endif\x0a#ifdef\x20VERTEXCOLOR\x0avarying\x20vec4\x20vColor;\x0a#endif';_0x494b01['a']['IncludesShadersStore']['pbrFragmentExtraDeclaration']=_0x4467eb;var _0x36e06c='#ifdef\x20ALBEDO\x0a#if\x20ALBEDODIRECTUV\x20==\x201\x0a#define\x20vAlbedoUV\x20vMainUV1\x0a#elif\x20ALBEDODIRECTUV\x20==\x202\x0a#define\x20vAlbedoUV\x20vMainUV2\x0a#else\x0avarying\x20vec2\x20vAlbedoUV;\x0a#endif\x0auniform\x20sampler2D\x20albedoSampler;\x0a#endif\x0a#ifdef\x20AMBIENT\x0a#if\x20AMBIENTDIRECTUV\x20==\x201\x0a#define\x20vAmbientUV\x20vMainUV1\x0a#elif\x20AMBIENTDIRECTUV\x20==\x202\x0a#define\x20vAmbientUV\x20vMainUV2\x0a#else\x0avarying\x20vec2\x20vAmbientUV;\x0a#endif\x0auniform\x20sampler2D\x20ambientSampler;\x0a#endif\x0a#ifdef\x20OPACITY\x0a#if\x20OPACITYDIRECTUV\x20==\x201\x0a#define\x20vOpacityUV\x20vMainUV1\x0a#elif\x20OPACITYDIRECTUV\x20==\x202\x0a#define\x20vOpacityUV\x20vMainUV2\x0a#else\x0avarying\x20vec2\x20vOpacityUV;\x0a#endif\x0auniform\x20sampler2D\x20opacitySampler;\x0a#endif\x0a#ifdef\x20EMISSIVE\x0a#if\x20EMISSIVEDIRECTUV\x20==\x201\x0a#define\x20vEmissiveUV\x20vMainUV1\x0a#elif\x20EMISSIVEDIRECTUV\x20==\x202\x0a#define\x20vEmissiveUV\x20vMainUV2\x0a#else\x0avarying\x20vec2\x20vEmissiveUV;\x0a#endif\x0auniform\x20sampler2D\x20emissiveSampler;\x0a#endif\x0a#ifdef\x20LIGHTMAP\x0a#if\x20LIGHTMAPDIRECTUV\x20==\x201\x0a#define\x20vLightmapUV\x20vMainUV1\x0a#elif\x20LIGHTMAPDIRECTUV\x20==\x202\x0a#define\x20vLightmapUV\x20vMainUV2\x0a#else\x0avarying\x20vec2\x20vLightmapUV;\x0a#endif\x0auniform\x20sampler2D\x20lightmapSampler;\x0a#endif\x0a#ifdef\x20REFLECTIVITY\x0a#if\x20REFLECTIVITYDIRECTUV\x20==\x201\x0a#define\x20vReflectivityUV\x20vMainUV1\x0a#elif\x20REFLECTIVITYDIRECTUV\x20==\x202\x0a#define\x20vReflectivityUV\x20vMainUV2\x0a#else\x0avarying\x20vec2\x20vReflectivityUV;\x0a#endif\x0auniform\x20sampler2D\x20reflectivitySampler;\x0a#endif\x0a#ifdef\x20MICROSURFACEMAP\x0a#if\x20MICROSURFACEMAPDIRECTUV\x20==\x201\x0a#define\x20vMicroSurfaceSamplerUV\x20vMainUV1\x0a#elif\x20MICROSURFACEMAPDIRECTUV\x20==\x202\x0a#define\x20vMicroSurfaceSamplerUV\x20vMainUV2\x0a#else\x0avarying\x20vec2\x20vMicroSurfaceSamplerUV;\x0a#endif\x0auniform\x20sampler2D\x20microSurfaceSampler;\x0a#endif\x0a#ifdef\x20METALLIC_REFLECTANCE\x0a#if\x20METALLIC_REFLECTANCEDIRECTUV\x20==\x201\x0a#define\x20vMetallicReflectanceUV\x20vMainUV1\x0a#elif\x20METALLIC_REFLECTANCEDIRECTUV\x20==\x202\x0a#define\x20vMetallicReflectanceUV\x20vMainUV2\x0a#else\x0avarying\x20vec2\x20vMetallicReflectanceUV;\x0a#endif\x0auniform\x20sampler2D\x20metallicReflectanceSampler;\x0a#endif\x0a#ifdef\x20CLEARCOAT\x0a#if\x20defined(CLEARCOAT_TEXTURE)\x0a#if\x20CLEARCOAT_TEXTUREDIRECTUV\x20==\x201\x0a#define\x20vClearCoatUV\x20vMainUV1\x0a#elif\x20CLEARCOAT_TEXTUREDIRECTUV\x20==\x202\x0a#define\x20vClearCoatUV\x20vMainUV2\x0a#else\x0avarying\x20vec2\x20vClearCoatUV;\x0a#endif\x0a#endif\x0a#if\x20defined(CLEARCOAT_TEXTURE_ROUGHNESS)\x0a#if\x20CLEARCOAT_TEXTURE_ROUGHNESSDIRECTUV\x20==\x201\x0a#define\x20vClearCoatRoughnessUV\x20vMainUV1\x0a#elif\x20CLEARCOAT_TEXTURE_ROUGHNESSDIRECTUV\x20==\x202\x0a#define\x20vClearCoatRoughnessUV\x20vMainUV2\x0a#else\x0avarying\x20vec2\x20vClearCoatRoughnessUV;\x0a#endif\x0a#endif\x0a#ifdef\x20CLEARCOAT_TEXTURE\x0auniform\x20sampler2D\x20clearCoatSampler;\x0a#endif\x0a#if\x20defined(CLEARCOAT_TEXTURE_ROUGHNESS)\x20&&\x20!defined(CLEARCOAT_TEXTURE_ROUGHNESS_IDENTICAL)\x0auniform\x20sampler2D\x20clearCoatRoughnessSampler;\x0a#endif\x0a#ifdef\x20CLEARCOAT_BUMP\x0a#if\x20CLEARCOAT_BUMPDIRECTUV\x20==\x201\x0a#define\x20vClearCoatBumpUV\x20vMainUV1\x0a#elif\x20CLEARCOAT_BUMPDIRECTUV\x20==\x202\x0a#define\x20vClearCoatBumpUV\x20vMainUV2\x0a#else\x0avarying\x20vec2\x20vClearCoatBumpUV;\x0a#endif\x0auniform\x20sampler2D\x20clearCoatBumpSampler;\x0a#endif\x0a#ifdef\x20CLEARCOAT_TINT_TEXTURE\x0a#if\x20CLEARCOAT_TINT_TEXTUREDIRECTUV\x20==\x201\x0a#define\x20vClearCoatTintUV\x20vMainUV1\x0a#elif\x20CLEARCOAT_TINT_TEXTUREDIRECTUV\x20==\x202\x0a#define\x20vClearCoatTintUV\x20vMainUV2\x0a#else\x0avarying\x20vec2\x20vClearCoatTintUV;\x0a#endif\x0auniform\x20sampler2D\x20clearCoatTintSampler;\x0a#endif\x0a#endif\x0a#ifdef\x20SHEEN\x0a#ifdef\x20SHEEN_TEXTURE\x0a#if\x20SHEEN_TEXTUREDIRECTUV\x20==\x201\x0a#define\x20vSheenUV\x20vMainUV1\x0a#elif\x20SHEEN_TEXTUREDIRECTUV\x20==\x202\x0a#define\x20vSheenUV\x20vMainUV2\x0a#else\x0avarying\x20vec2\x20vSheenUV;\x0a#endif\x0a#endif\x0a#ifdef\x20SHEEN_TEXTURE_ROUGHNESS\x0a#if\x20SHEEN_TEXTURE_ROUGHNESSDIRECTUV\x20==\x201\x0a#define\x20vSheenRoughnessUV\x20vMainUV1\x0a#elif\x20SHEEN_TEXTURE_ROUGHNESSDIRECTUV\x20==\x202\x0a#define\x20vSheenRoughnessUV\x20vMainUV2\x0a#else\x0avarying\x20vec2\x20vSheenRoughnessUV;\x0a#endif\x0a#endif\x0a#ifdef\x20SHEEN_TEXTURE\x0auniform\x20sampler2D\x20sheenSampler;\x0a#endif\x0a#if\x20defined(SHEEN_ROUGHNESS)\x20&&\x20defined(SHEEN_TEXTURE_ROUGHNESS)\x20&&\x20!defined(SHEEN_TEXTURE_ROUGHNESS_IDENTICAL)\x0auniform\x20sampler2D\x20sheenRoughnessSampler;\x0a#endif\x0a#endif\x0a#ifdef\x20ANISOTROPIC\x0a#ifdef\x20ANISOTROPIC_TEXTURE\x0a#if\x20ANISOTROPIC_TEXTUREDIRECTUV\x20==\x201\x0a#define\x20vAnisotropyUV\x20vMainUV1\x0a#elif\x20ANISOTROPIC_TEXTUREDIRECTUV\x20==\x202\x0a#define\x20vAnisotropyUV\x20vMainUV2\x0a#else\x0avarying\x20vec2\x20vAnisotropyUV;\x0a#endif\x0auniform\x20sampler2D\x20anisotropySampler;\x0a#endif\x0a#endif\x0a\x0a#ifdef\x20REFLECTION\x0a#ifdef\x20REFLECTIONMAP_3D\x0a#define\x20sampleReflection(s,c)\x20textureCube(s,c)\x0auniform\x20samplerCube\x20reflectionSampler;\x0a#ifdef\x20LODBASEDMICROSFURACE\x0a#define\x20sampleReflectionLod(s,c,l)\x20textureCubeLodEXT(s,c,l)\x0a#else\x0auniform\x20samplerCube\x20reflectionSamplerLow;\x0auniform\x20samplerCube\x20reflectionSamplerHigh;\x0a#endif\x0a#ifdef\x20USEIRRADIANCEMAP\x0auniform\x20samplerCube\x20irradianceSampler;\x0a#endif\x0a#else\x0a#define\x20sampleReflection(s,c)\x20texture2D(s,c)\x0auniform\x20sampler2D\x20reflectionSampler;\x0a#ifdef\x20LODBASEDMICROSFURACE\x0a#define\x20sampleReflectionLod(s,c,l)\x20texture2DLodEXT(s,c,l)\x0a#else\x0auniform\x20sampler2D\x20reflectionSamplerLow;\x0auniform\x20sampler2D\x20reflectionSamplerHigh;\x0a#endif\x0a#ifdef\x20USEIRRADIANCEMAP\x0auniform\x20sampler2D\x20irradianceSampler;\x0a#endif\x0a#endif\x0a#ifdef\x20REFLECTIONMAP_SKYBOX\x0avarying\x20vec3\x20vPositionUVW;\x0a#else\x0a#if\x20defined(REFLECTIONMAP_EQUIRECTANGULAR_FIXED)\x20||\x20defined(REFLECTIONMAP_MIRROREDEQUIRECTANGULAR_FIXED)\x0avarying\x20vec3\x20vDirectionW;\x0a#endif\x0a#endif\x0a#endif\x0a#ifdef\x20ENVIRONMENTBRDF\x0auniform\x20sampler2D\x20environmentBrdfSampler;\x0a#endif\x0a\x0a#ifdef\x20SUBSURFACE\x0a#ifdef\x20SS_REFRACTION\x0a#ifdef\x20SS_REFRACTIONMAP_3D\x0a#define\x20sampleRefraction(s,c)\x20textureCube(s,c)\x0auniform\x20samplerCube\x20refractionSampler;\x0a#ifdef\x20LODBASEDMICROSFURACE\x0a#define\x20sampleRefractionLod(s,c,l)\x20textureCubeLodEXT(s,c,l)\x0a#else\x0auniform\x20samplerCube\x20refractionSamplerLow;\x0auniform\x20samplerCube\x20refractionSamplerHigh;\x0a#endif\x0a#else\x0a#define\x20sampleRefraction(s,c)\x20texture2D(s,c)\x0auniform\x20sampler2D\x20refractionSampler;\x0a#ifdef\x20LODBASEDMICROSFURACE\x0a#define\x20sampleRefractionLod(s,c,l)\x20texture2DLodEXT(s,c,l)\x0a#else\x0auniform\x20sampler2D\x20refractionSamplerLow;\x0auniform\x20sampler2D\x20refractionSamplerHigh;\x0a#endif\x0a#endif\x0a#endif\x0a#ifdef\x20SS_THICKNESSANDMASK_TEXTURE\x0a#if\x20SS_THICKNESSANDMASK_TEXTUREDIRECTUV\x20==\x201\x0a#define\x20vThicknessUV\x20vMainUV1\x0a#elif\x20SS_THICKNESSANDMASK_TEXTUREDIRECTUV\x20==\x202\x0a#define\x20vThicknessUV\x20vMainUV2\x0a#else\x0avarying\x20vec2\x20vThicknessUV;\x0a#endif\x0auniform\x20sampler2D\x20thicknessSampler;\x0a#endif\x0a#endif';_0x494b01['a']['IncludesShadersStore']['pbrFragmentSamplersDeclaration']=_0x36e06c,_0x162675(0x74),_0x494b01['a']['IncludesShadersStore']['subSurfaceScatteringFunctions']='bool\x20testLightingForSSS(float\x20diffusionProfile)\x0a{\x0areturn\x20diffusionProfile<1.;\x0a}';var _0x563b1f='\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0avec3\x20hemisphereCosSample(vec2\x20u)\x20{\x0a\x0afloat\x20phi=2.*PI*u.x;\x0afloat\x20cosTheta2=1.-u.y;\x0afloat\x20cosTheta=sqrt(cosTheta2);\x0afloat\x20sinTheta=sqrt(1.-cosTheta2);\x0areturn\x20vec3(sinTheta*cos(phi),sinTheta*sin(phi),cosTheta);\x0a}\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0avec3\x20hemisphereImportanceSampleDggx(vec2\x20u,float\x20a)\x20{\x0a\x0afloat\x20phi=2.*PI*u.x;\x0a\x0afloat\x20cosTheta2=(1.-u.y)/(1.+(a+1.)*((a-1.)*u.y));\x0afloat\x20cosTheta=sqrt(cosTheta2);\x0afloat\x20sinTheta=sqrt(1.-cosTheta2);\x0areturn\x20vec3(sinTheta*cos(phi),sinTheta*sin(phi),cosTheta);\x0a}\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0avec3\x20hemisphereImportanceSampleDCharlie(vec2\x20u,float\x20a)\x20{\x0a\x0afloat\x20phi=2.*PI*u.x;\x0afloat\x20sinTheta=pow(u.y,a/(2.*a+1.));\x0afloat\x20cosTheta=sqrt(1.-sinTheta*sinTheta);\x0areturn\x20vec3(sinTheta*cos(phi),sinTheta*sin(phi),cosTheta);\x0a}';_0x494b01['a']['IncludesShadersStore']['importanceSampling']=_0x563b1f;var _0x210a7d='\x0a#define\x20RECIPROCAL_PI2\x200.15915494\x0a#define\x20RECIPROCAL_PI\x200.31830988618\x0a\x0a#define\x20MINIMUMVARIANCE\x200.0005\x0afloat\x20convertRoughnessToAverageSlope(float\x20roughness)\x0a{\x0a\x0areturn\x20square(roughness)+MINIMUMVARIANCE;\x0a}\x0afloat\x20fresnelGrazingReflectance(float\x20reflectance0)\x20{\x0a\x0a\x0afloat\x20reflectance90=saturate(reflectance0*25.0);\x0areturn\x20reflectance90;\x0a}\x0avec2\x20getAARoughnessFactors(vec3\x20normalVector)\x20{\x0a#ifdef\x20SPECULARAA\x0avec3\x20nDfdx=dFdx(normalVector.xyz);\x0avec3\x20nDfdy=dFdy(normalVector.xyz);\x0afloat\x20slopeSquare=max(dot(nDfdx,nDfdx),dot(nDfdy,nDfdy));\x0a\x0afloat\x20geometricRoughnessFactor=pow(saturate(slopeSquare),0.333);\x0a\x0afloat\x20geometricAlphaGFactor=sqrt(slopeSquare);\x0a\x0ageometricAlphaGFactor*=0.75;\x0areturn\x20vec2(geometricRoughnessFactor,geometricAlphaGFactor);\x0a#else\x0areturn\x20vec2(0.);\x0a#endif\x0a}\x0a#ifdef\x20ANISOTROPIC\x0a\x0a\x0avec2\x20getAnisotropicRoughness(float\x20alphaG,float\x20anisotropy)\x20{\x0afloat\x20alphaT=max(alphaG*(1.0+anisotropy),MINIMUMVARIANCE);\x0afloat\x20alphaB=max(alphaG*(1.0-anisotropy),MINIMUMVARIANCE);\x0areturn\x20vec2(alphaT,alphaB);\x0a}\x0a\x0a\x0avec3\x20getAnisotropicBentNormals(const\x20vec3\x20T,const\x20vec3\x20B,const\x20vec3\x20N,const\x20vec3\x20V,float\x20anisotropy)\x20{\x0avec3\x20anisotropicFrameDirection=anisotropy>=0.0\x20?\x20B\x20:\x20T;\x0avec3\x20anisotropicFrameTangent=cross(normalize(anisotropicFrameDirection),V);\x0avec3\x20anisotropicFrameNormal=cross(anisotropicFrameTangent,anisotropicFrameDirection);\x0avec3\x20anisotropicNormal=normalize(mix(N,anisotropicFrameNormal,abs(anisotropy)));\x0areturn\x20anisotropicNormal;\x0a\x0a}\x0a#endif\x0a#if\x20defined(CLEARCOAT)\x20||\x20defined(SS_REFRACTION)\x0a\x0a\x0a\x0avec3\x20cocaLambert(vec3\x20alpha,float\x20distance)\x20{\x0areturn\x20exp(-alpha*distance);\x0a}\x0a\x0avec3\x20cocaLambert(float\x20NdotVRefract,float\x20NdotLRefract,vec3\x20alpha,float\x20thickness)\x20{\x0areturn\x20cocaLambert(alpha,(thickness*((NdotLRefract+NdotVRefract)/(NdotLRefract*NdotVRefract))));\x0a}\x0a\x0avec3\x20computeColorAtDistanceInMedia(vec3\x20color,float\x20distance)\x20{\x0areturn\x20-log(color)/distance;\x0a}\x0avec3\x20computeClearCoatAbsorption(float\x20NdotVRefract,float\x20NdotLRefract,vec3\x20clearCoatColor,float\x20clearCoatThickness,float\x20clearCoatIntensity)\x20{\x0avec3\x20clearCoatAbsorption=mix(vec3(1.0),\x0acocaLambert(NdotVRefract,NdotLRefract,clearCoatColor,clearCoatThickness),\x0aclearCoatIntensity);\x0areturn\x20clearCoatAbsorption;\x0a}\x0a#endif\x0a\x0a\x0a\x0a\x0a#ifdef\x20MICROSURFACEAUTOMATIC\x0afloat\x20computeDefaultMicroSurface(float\x20microSurface,vec3\x20reflectivityColor)\x0a{\x0aconst\x20float\x20kReflectivityNoAlphaWorkflow_SmoothnessMax=0.95;\x0afloat\x20reflectivityLuminance=getLuminance(reflectivityColor);\x0afloat\x20reflectivityLuma=sqrt(reflectivityLuminance);\x0amicroSurface=reflectivityLuma*kReflectivityNoAlphaWorkflow_SmoothnessMax;\x0areturn\x20microSurface;\x0a}\x0a#endif';_0x494b01['a']['IncludesShadersStore']['pbrHelperFunctions']=_0x210a7d;var _0x2c4b57='#ifdef\x20USESPHERICALFROMREFLECTIONMAP\x0a#ifdef\x20SPHERICAL_HARMONICS\x0auniform\x20vec3\x20vSphericalL00;\x0auniform\x20vec3\x20vSphericalL1_1;\x0auniform\x20vec3\x20vSphericalL10;\x0auniform\x20vec3\x20vSphericalL11;\x0auniform\x20vec3\x20vSphericalL2_2;\x0auniform\x20vec3\x20vSphericalL2_1;\x0auniform\x20vec3\x20vSphericalL20;\x0auniform\x20vec3\x20vSphericalL21;\x0auniform\x20vec3\x20vSphericalL22;\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0avec3\x20computeEnvironmentIrradiance(vec3\x20normal)\x20{\x0areturn\x20vSphericalL00\x0a+vSphericalL1_1*(normal.y)\x0a+vSphericalL10*(normal.z)\x0a+vSphericalL11*(normal.x)\x0a+vSphericalL2_2*(normal.y*normal.x)\x0a+vSphericalL2_1*(normal.y*normal.z)\x0a+vSphericalL20*((3.0*normal.z*normal.z)-1.0)\x0a+vSphericalL21*(normal.z*normal.x)\x0a+vSphericalL22*(normal.x*normal.x-(normal.y*normal.y));\x0a}\x0a#else\x0auniform\x20vec3\x20vSphericalX;\x0auniform\x20vec3\x20vSphericalY;\x0auniform\x20vec3\x20vSphericalZ;\x0auniform\x20vec3\x20vSphericalXX_ZZ;\x0auniform\x20vec3\x20vSphericalYY_ZZ;\x0auniform\x20vec3\x20vSphericalZZ;\x0auniform\x20vec3\x20vSphericalXY;\x0auniform\x20vec3\x20vSphericalYZ;\x0auniform\x20vec3\x20vSphericalZX;\x0a\x0avec3\x20computeEnvironmentIrradiance(vec3\x20normal)\x20{\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0afloat\x20Nx=normal.x;\x0afloat\x20Ny=normal.y;\x0afloat\x20Nz=normal.z;\x0avec3\x20C1=vSphericalZZ.rgb;\x0avec3\x20Cx=vSphericalX.rgb;\x0avec3\x20Cy=vSphericalY.rgb;\x0avec3\x20Cz=vSphericalZ.rgb;\x0avec3\x20Cxx_zz=vSphericalXX_ZZ.rgb;\x0avec3\x20Cyy_zz=vSphericalYY_ZZ.rgb;\x0avec3\x20Cxy=vSphericalXY.rgb;\x0avec3\x20Cyz=vSphericalYZ.rgb;\x0avec3\x20Czx=vSphericalZX.rgb;\x0avec3\x20a1=Cyy_zz*Ny+Cy;\x0avec3\x20a2=Cyz*Nz+a1;\x0avec3\x20b1=Czx*Nz+Cx;\x0avec3\x20b2=Cxy*Ny+b1;\x0avec3\x20b3=Cxx_zz*Nx+b2;\x0avec3\x20t1=Cz*Nz+C1;\x0avec3\x20t2=a2*Ny+t1;\x0avec3\x20t3=b3*Nx+t2;\x0areturn\x20t3;\x0a}\x0a#endif\x0a#endif';_0x494b01['a']['IncludesShadersStore']['harmonicsFunctions']=_0x2c4b57;var _0x45d98b='\x0astruct\x20preLightingInfo\x0a{\x0a\x0avec3\x20lightOffset;\x0afloat\x20lightDistanceSquared;\x0afloat\x20lightDistance;\x0a\x0afloat\x20attenuation;\x0a\x0avec3\x20L;\x0avec3\x20H;\x0afloat\x20NdotV;\x0afloat\x20NdotLUnclamped;\x0afloat\x20NdotL;\x0afloat\x20VdotH;\x0afloat\x20roughness;\x0a};\x0apreLightingInfo\x20computePointAndSpotPreLightingInfo(vec4\x20lightData,vec3\x20V,vec3\x20N)\x20{\x0apreLightingInfo\x20result;\x0a\x0aresult.lightOffset=lightData.xyz-vPositionW;\x0aresult.lightDistanceSquared=dot(result.lightOffset,result.lightOffset);\x0a\x0aresult.lightDistance=sqrt(result.lightDistanceSquared);\x0a\x0aresult.L=normalize(result.lightOffset);\x0aresult.H=normalize(V+result.L);\x0aresult.VdotH=saturate(dot(V,result.H));\x0aresult.NdotLUnclamped=dot(N,result.L);\x0aresult.NdotL=saturateEps(result.NdotLUnclamped);\x0areturn\x20result;\x0a}\x0apreLightingInfo\x20computeDirectionalPreLightingInfo(vec4\x20lightData,vec3\x20V,vec3\x20N)\x20{\x0apreLightingInfo\x20result;\x0a\x0aresult.lightDistance=length(-lightData.xyz);\x0a\x0aresult.L=normalize(-lightData.xyz);\x0aresult.H=normalize(V+result.L);\x0aresult.VdotH=saturate(dot(V,result.H));\x0aresult.NdotLUnclamped=dot(N,result.L);\x0aresult.NdotL=saturateEps(result.NdotLUnclamped);\x0areturn\x20result;\x0a}\x0apreLightingInfo\x20computeHemisphericPreLightingInfo(vec4\x20lightData,vec3\x20V,vec3\x20N)\x20{\x0apreLightingInfo\x20result;\x0a\x0a\x0aresult.NdotL=dot(N,lightData.xyz)*0.5+0.5;\x0aresult.NdotL=saturateEps(result.NdotL);\x0aresult.NdotLUnclamped=result.NdotL;\x0a#ifdef\x20SPECULARTERM\x0aresult.L=normalize(lightData.xyz);\x0aresult.H=normalize(V+result.L);\x0aresult.VdotH=saturate(dot(V,result.H));\x0a#endif\x0areturn\x20result;\x0a}';_0x494b01['a']['IncludesShadersStore']['pbrDirectLightingSetupFunctions']=_0x45d98b;var _0x4af2dd='float\x20computeDistanceLightFalloff_Standard(vec3\x20lightOffset,float\x20range)\x0a{\x0areturn\x20max(0.,1.0-length(lightOffset)/range);\x0a}\x0afloat\x20computeDistanceLightFalloff_Physical(float\x20lightDistanceSquared)\x0a{\x0areturn\x201.0/maxEps(lightDistanceSquared);\x0a}\x0afloat\x20computeDistanceLightFalloff_GLTF(float\x20lightDistanceSquared,float\x20inverseSquaredRange)\x0a{\x0afloat\x20lightDistanceFalloff=1.0/maxEps(lightDistanceSquared);\x0afloat\x20factor=lightDistanceSquared*inverseSquaredRange;\x0afloat\x20attenuation=saturate(1.0-factor*factor);\x0aattenuation*=attenuation;\x0a\x0alightDistanceFalloff*=attenuation;\x0areturn\x20lightDistanceFalloff;\x0a}\x0afloat\x20computeDistanceLightFalloff(vec3\x20lightOffset,float\x20lightDistanceSquared,float\x20range,float\x20inverseSquaredRange)\x0a{\x0a#ifdef\x20USEPHYSICALLIGHTFALLOFF\x0areturn\x20computeDistanceLightFalloff_Physical(lightDistanceSquared);\x0a#elif\x20defined(USEGLTFLIGHTFALLOFF)\x0areturn\x20computeDistanceLightFalloff_GLTF(lightDistanceSquared,inverseSquaredRange);\x0a#else\x0areturn\x20computeDistanceLightFalloff_Standard(lightOffset,range);\x0a#endif\x0a}\x0afloat\x20computeDirectionalLightFalloff_Standard(vec3\x20lightDirection,vec3\x20directionToLightCenterW,float\x20cosHalfAngle,float\x20exponent)\x0a{\x0afloat\x20falloff=0.0;\x0afloat\x20cosAngle=maxEps(dot(-lightDirection,directionToLightCenterW));\x0aif\x20(cosAngle>=cosHalfAngle)\x0a{\x0afalloff=max(0.,pow(cosAngle,exponent));\x0a}\x0areturn\x20falloff;\x0a}\x0afloat\x20computeDirectionalLightFalloff_Physical(vec3\x20lightDirection,vec3\x20directionToLightCenterW,float\x20cosHalfAngle)\x0a{\x0aconst\x20float\x20kMinusLog2ConeAngleIntensityRatio=6.64385618977;\x0a\x0a\x0a\x0a\x0a\x0afloat\x20concentrationKappa=kMinusLog2ConeAngleIntensityRatio/(1.0-cosHalfAngle);\x0a\x0a\x0avec4\x20lightDirectionSpreadSG=vec4(-lightDirection*concentrationKappa,-concentrationKappa);\x0afloat\x20falloff=exp2(dot(vec4(directionToLightCenterW,1.0),lightDirectionSpreadSG));\x0areturn\x20falloff;\x0a}\x0afloat\x20computeDirectionalLightFalloff_GLTF(vec3\x20lightDirection,vec3\x20directionToLightCenterW,float\x20lightAngleScale,float\x20lightAngleOffset)\x0a{\x0a\x0a\x0a\x0afloat\x20cd=dot(-lightDirection,directionToLightCenterW);\x0afloat\x20falloff=saturate(cd*lightAngleScale+lightAngleOffset);\x0a\x0afalloff*=falloff;\x0areturn\x20falloff;\x0a}\x0afloat\x20computeDirectionalLightFalloff(vec3\x20lightDirection,vec3\x20directionToLightCenterW,float\x20cosHalfAngle,float\x20exponent,float\x20lightAngleScale,float\x20lightAngleOffset)\x0a{\x0a#ifdef\x20USEPHYSICALLIGHTFALLOFF\x0areturn\x20computeDirectionalLightFalloff_Physical(lightDirection,directionToLightCenterW,cosHalfAngle);\x0a#elif\x20defined(USEGLTFLIGHTFALLOFF)\x0areturn\x20computeDirectionalLightFalloff_GLTF(lightDirection,directionToLightCenterW,lightAngleScale,lightAngleOffset);\x0a#else\x0areturn\x20computeDirectionalLightFalloff_Standard(lightDirection,directionToLightCenterW,cosHalfAngle,exponent);\x0a#endif\x0a}';_0x494b01['a']['IncludesShadersStore']['pbrDirectLightingFalloffFunctions']=_0x4af2dd;var _0x2e55af='\x0a#define\x20FRESNEL_MAXIMUM_ON_ROUGH\x200.25\x0a\x0a\x0a\x0a\x0a#ifdef\x20MS_BRDF_ENERGY_CONSERVATION\x0a\x0a\x0avec3\x20getEnergyConservationFactor(const\x20vec3\x20specularEnvironmentR0,const\x20vec3\x20environmentBrdf)\x20{\x0areturn\x201.0+specularEnvironmentR0*(1.0/environmentBrdf.y-1.0);\x0a}\x0a#endif\x0a#ifdef\x20ENVIRONMENTBRDF\x0avec3\x20getBRDFLookup(float\x20NdotV,float\x20perceptualRoughness)\x20{\x0a\x0avec2\x20UV=vec2(NdotV,perceptualRoughness);\x0a\x0avec4\x20brdfLookup=texture2D(environmentBrdfSampler,UV);\x0a#ifdef\x20ENVIRONMENTBRDF_RGBD\x0abrdfLookup.rgb=fromRGBD(brdfLookup.rgba);\x0a#endif\x0areturn\x20brdfLookup.rgb;\x0a}\x0avec3\x20getReflectanceFromBRDFLookup(const\x20vec3\x20specularEnvironmentR0,const\x20vec3\x20specularEnvironmentR90,const\x20vec3\x20environmentBrdf)\x20{\x0a#ifdef\x20BRDF_V_HEIGHT_CORRELATED\x0avec3\x20reflectance=(specularEnvironmentR90-specularEnvironmentR0)*environmentBrdf.x+specularEnvironmentR0*environmentBrdf.y;\x0a\x0a#else\x0avec3\x20reflectance=specularEnvironmentR0*environmentBrdf.x+specularEnvironmentR90*environmentBrdf.y;\x0a#endif\x0areturn\x20reflectance;\x0a}\x0avec3\x20getReflectanceFromBRDFLookup(const\x20vec3\x20specularEnvironmentR0,const\x20vec3\x20environmentBrdf)\x20{\x0a#ifdef\x20BRDF_V_HEIGHT_CORRELATED\x0avec3\x20reflectance=mix(environmentBrdf.xxx,environmentBrdf.yyy,specularEnvironmentR0);\x0a#else\x0avec3\x20reflectance=specularEnvironmentR0*environmentBrdf.x+environmentBrdf.y;\x0a#endif\x0areturn\x20reflectance;\x0a}\x0a#endif\x0a\x0a#if\x20!defined(ENVIRONMENTBRDF)\x20||\x20defined(REFLECTIONMAP_SKYBOX)\x20||\x20defined(ALPHAFRESNEL)\x0avec3\x20getReflectanceFromAnalyticalBRDFLookup_Jones(float\x20VdotN,vec3\x20reflectance0,vec3\x20reflectance90,float\x20smoothness)\x0a{\x0a\x0afloat\x20weight=mix(FRESNEL_MAXIMUM_ON_ROUGH,1.0,smoothness);\x0areturn\x20reflectance0+weight*(reflectance90-reflectance0)*pow5(saturate(1.0-VdotN));\x0a}\x0a#endif\x0a#if\x20defined(SHEEN)\x20&&\x20defined(ENVIRONMENTBRDF)\x0a\x0avec3\x20getSheenReflectanceFromBRDFLookup(const\x20vec3\x20reflectance0,const\x20vec3\x20environmentBrdf)\x20{\x0avec3\x20sheenEnvironmentReflectance=reflectance0*environmentBrdf.b;\x0areturn\x20sheenEnvironmentReflectance;\x0a}\x0a#endif\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0avec3\x20fresnelSchlickGGX(float\x20VdotH,vec3\x20reflectance0,vec3\x20reflectance90)\x0a{\x0areturn\x20reflectance0+(reflectance90-reflectance0)*pow5(1.0-VdotH);\x0a}\x0afloat\x20fresnelSchlickGGX(float\x20VdotH,float\x20reflectance0,float\x20reflectance90)\x0a{\x0areturn\x20reflectance0+(reflectance90-reflectance0)*pow5(1.0-VdotH);\x0a}\x0a#ifdef\x20CLEARCOAT\x0a\x0a\x0a\x0a\x0a\x0avec3\x20getR0RemappedForClearCoat(vec3\x20f0)\x20{\x0a#ifdef\x20CLEARCOAT_DEFAULTIOR\x0a#ifdef\x20MOBILE\x0areturn\x20saturate(f0*(f0*0.526868+0.529324)-0.0482256);\x0a#else\x0areturn\x20saturate(f0*(f0*(0.941892-0.263008*f0)+0.346479)-0.0285998);\x0a#endif\x0a#else\x0avec3\x20s=sqrt(f0);\x0avec3\x20t=(vClearCoatRefractionParams.z+vClearCoatRefractionParams.w*s)/(vClearCoatRefractionParams.w+vClearCoatRefractionParams.z*s);\x0areturn\x20t*t;\x0a#endif\x0a}\x0a#endif\x0a\x0a\x0a\x0a\x0a\x0a\x0afloat\x20normalDistributionFunction_TrowbridgeReitzGGX(float\x20NdotH,float\x20alphaG)\x0a{\x0a\x0a\x0a\x0afloat\x20a2=square(alphaG);\x0afloat\x20d=NdotH*NdotH*(a2-1.0)+1.0;\x0areturn\x20a2/(PI*d*d);\x0a}\x0a#ifdef\x20SHEEN\x0a\x0a\x0afloat\x20normalDistributionFunction_CharlieSheen(float\x20NdotH,float\x20alphaG)\x0a{\x0afloat\x20invR=1./alphaG;\x0afloat\x20cos2h=NdotH*NdotH;\x0afloat\x20sin2h=1.-cos2h;\x0areturn\x20(2.+invR)*pow(sin2h,invR*.5)/(2.*PI);\x0a}\x0a#endif\x0a#ifdef\x20ANISOTROPIC\x0a\x0a\x0afloat\x20normalDistributionFunction_BurleyGGX_Anisotropic(float\x20NdotH,float\x20TdotH,float\x20BdotH,const\x20vec2\x20alphaTB)\x20{\x0afloat\x20a2=alphaTB.x*alphaTB.y;\x0avec3\x20v=vec3(alphaTB.y*TdotH,alphaTB.x*BdotH,a2*NdotH);\x0afloat\x20v2=dot(v,v);\x0afloat\x20w2=a2/v2;\x0areturn\x20a2*w2*w2*RECIPROCAL_PI;\x0a}\x0a#endif\x0a\x0a\x0a\x0a\x0a#ifdef\x20BRDF_V_HEIGHT_CORRELATED\x0a\x0a\x0a\x0afloat\x20smithVisibility_GGXCorrelated(float\x20NdotL,float\x20NdotV,float\x20alphaG)\x20{\x0a#ifdef\x20MOBILE\x0a\x0afloat\x20GGXV=NdotL*(NdotV*(1.0-alphaG)+alphaG);\x0afloat\x20GGXL=NdotV*(NdotL*(1.0-alphaG)+alphaG);\x0areturn\x200.5/(GGXV+GGXL);\x0a#else\x0afloat\x20a2=alphaG*alphaG;\x0afloat\x20GGXV=NdotL*sqrt(NdotV*(NdotV-a2*NdotV)+a2);\x0afloat\x20GGXL=NdotV*sqrt(NdotL*(NdotL-a2*NdotL)+a2);\x0areturn\x200.5/(GGXV+GGXL);\x0a#endif\x0a}\x0a#else\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0afloat\x20smithVisibilityG1_TrowbridgeReitzGGXFast(float\x20dot,float\x20alphaG)\x0a{\x0a#ifdef\x20MOBILE\x0a\x0areturn\x201.0/(dot+alphaG+(1.0-alphaG)*dot\x20));\x0a#else\x0afloat\x20alphaSquared=alphaG*alphaG;\x0areturn\x201.0/(dot+sqrt(alphaSquared+(1.0-alphaSquared)*dot*dot));\x0a#endif\x0a}\x0afloat\x20smithVisibility_TrowbridgeReitzGGXFast(float\x20NdotL,float\x20NdotV,float\x20alphaG)\x0a{\x0afloat\x20visibility=smithVisibilityG1_TrowbridgeReitzGGXFast(NdotL,alphaG)*smithVisibilityG1_TrowbridgeReitzGGXFast(NdotV,alphaG);\x0a\x0areturn\x20visibility;\x0a}\x0a#endif\x0a#ifdef\x20ANISOTROPIC\x0a\x0a\x0afloat\x20smithVisibility_GGXCorrelated_Anisotropic(float\x20NdotL,float\x20NdotV,float\x20TdotV,float\x20BdotV,float\x20TdotL,float\x20BdotL,const\x20vec2\x20alphaTB)\x20{\x0afloat\x20lambdaV=NdotL*length(vec3(alphaTB.x*TdotV,alphaTB.y*BdotV,NdotV));\x0afloat\x20lambdaL=NdotV*length(vec3(alphaTB.x*TdotL,alphaTB.y*BdotL,NdotL));\x0afloat\x20v=0.5/(lambdaV+lambdaL);\x0areturn\x20v;\x0a}\x0a#endif\x0a#ifdef\x20CLEARCOAT\x0afloat\x20visibility_Kelemen(float\x20VdotH)\x20{\x0a\x0a\x0a\x0areturn\x200.25/(VdotH*VdotH);\x0a}\x0a#endif\x0a#ifdef\x20SHEEN\x0a\x0a\x0a\x0afloat\x20visibility_Ashikhmin(float\x20NdotL,float\x20NdotV)\x0a{\x0areturn\x201./(4.*(NdotL+NdotV-NdotL*NdotV));\x0a}\x0a\x0a#endif\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0afloat\x20diffuseBRDF_Burley(float\x20NdotL,float\x20NdotV,float\x20VdotH,float\x20roughness)\x20{\x0a\x0a\x0afloat\x20diffuseFresnelNV=pow5(saturateEps(1.0-NdotL));\x0afloat\x20diffuseFresnelNL=pow5(saturateEps(1.0-NdotV));\x0afloat\x20diffuseFresnel90=0.5+2.0*VdotH*VdotH*roughness;\x0afloat\x20fresnel\x20=\x0a(1.0+(diffuseFresnel90-1.0)*diffuseFresnelNL)\x20*\x0a(1.0+(diffuseFresnel90-1.0)*diffuseFresnelNV);\x0areturn\x20fresnel/PI;\x0a}\x0a#ifdef\x20SS_TRANSLUCENCY\x0a\x0a\x0avec3\x20transmittanceBRDF_Burley(const\x20vec3\x20tintColor,const\x20vec3\x20diffusionDistance,float\x20thickness)\x20{\x0avec3\x20S=1./maxEps(diffusionDistance);\x0avec3\x20temp=exp((-0.333333333*thickness)*S);\x0areturn\x20tintColor.rgb*0.25*(temp*temp*temp+3.0*temp);\x0a}\x0a\x0a\x0afloat\x20computeWrappedDiffuseNdotL(float\x20NdotL,float\x20w)\x20{\x0afloat\x20t=1.0+w;\x0afloat\x20invt2=1.0/square(t);\x0areturn\x20saturate((NdotL+w)*invt2);\x0a}\x0a#endif\x0a';_0x494b01['a']['IncludesShadersStore']['pbrBRDFFunctions']=_0x2e55af;var _0x2f2e33='#ifdef\x20NUM_SAMPLES\x0a#if\x20NUM_SAMPLES>0\x0a#ifdef\x20WEBGL2\x0a\x0a\x0afloat\x20radicalInverse_VdC(uint\x20bits)\x0a{\x0abits=(bits\x20<<\x2016u)\x20|\x20(bits\x20>>\x2016u);\x0abits=((bits\x20&\x200x55555555u)\x20<<\x201u)\x20|\x20((bits\x20&\x200xAAAAAAAAu)\x20>>\x201u);\x0abits=((bits\x20&\x200x33333333u)\x20<<\x202u)\x20|\x20((bits\x20&\x200xCCCCCCCCu)\x20>>\x202u);\x0abits=((bits\x20&\x200x0F0F0F0Fu)\x20<<\x204u)\x20|\x20((bits\x20&\x200xF0F0F0F0u)\x20>>\x204u);\x0abits=((bits\x20&\x200x00FF00FFu)\x20<<\x208u)\x20|\x20((bits\x20&\x200xFF00FF00u)\x20>>\x208u);\x0areturn\x20float(bits)*2.3283064365386963e-10;\x0a}\x0avec2\x20hammersley(uint\x20i,uint\x20N)\x0a{\x0areturn\x20vec2(float(i)/float(N),radicalInverse_VdC(i));\x0a}\x0a#else\x0afloat\x20vanDerCorpus(int\x20n,int\x20base)\x0a{\x0afloat\x20invBase=1.0/float(base);\x0afloat\x20denom=1.0;\x0afloat\x20result=0.0;\x0afor(int\x20i=0;\x20i<32;\x20++i)\x0a{\x0aif(n>0)\x0a{\x0adenom=mod(float(n),2.0);\x0aresult+=denom*invBase;\x0ainvBase=invBase/2.0;\x0an=int(float(n)/2.0);\x0a}\x0a}\x0areturn\x20result;\x0a}\x0avec2\x20hammersley(int\x20i,int\x20N)\x0a{\x0areturn\x20vec2(float(i)/float(N),vanDerCorpus(i,2));\x0a}\x0a#endif\x0afloat\x20log4(float\x20x)\x20{\x0areturn\x20log2(x)/2.;\x0a}\x0aconst\x20float\x20NUM_SAMPLES_FLOAT=float(NUM_SAMPLES);\x0aconst\x20float\x20NUM_SAMPLES_FLOAT_INVERSED=1./NUM_SAMPLES_FLOAT;\x0aconst\x20float\x20K=4.;\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a\x0a#define\x20inline\x0avec3\x20irradiance(samplerCube\x20inputTexture,vec3\x20inputN,vec2\x20filteringInfo)\x0a{\x0avec3\x20n=normalize(inputN);\x0avec3\x20result=vec3(0.0);\x0avec3\x20tangent=abs(n.z)<0.999\x20?\x20vec3(0.,0.,1.)\x20:\x20vec3(1.,0.,0.);\x0atangent=normalize(cross(tangent,n));\x0avec3\x20bitangent=cross(n,tangent);\x0amat3\x20tbn=mat3(tangent,bitangent,n);\x0afloat\x20maxLevel=filteringInfo.y;\x0afloat\x20dim0=filteringInfo.x;\x0afloat\x20omegaP=(4.*PI)/(6.*dim0*dim0);\x0a#ifdef\x20WEBGL2\x0afor(uint\x20i=0u;\x20i0.)\x20{\x0afloat\x20pdf_inversed=PI/NoL;\x0afloat\x20omegaS=NUM_SAMPLES_FLOAT_INVERSED*pdf_inversed;\x0afloat\x20l=log4(omegaS)-log4(omegaP)+log4(K);\x0afloat\x20mipLevel=clamp(l,0.0,maxLevel);\x0avec3\x20c=textureCubeLodEXT(inputTexture,tbn*Ls,mipLevel).rgb;\x0a#ifdef\x20GAMMA_INPUT\x0ac=toLinearSpace(c);\x0a#endif\x0aresult+=c;\x0a}\x0a}\x0aresult=result*NUM_SAMPLES_FLOAT_INVERSED;\x0areturn\x20result;\x0a}\x0a#define\x20inline\x0avec3\x20radiance(float\x20alphaG,samplerCube\x20inputTexture,vec3\x20inputN,vec2\x20filteringInfo)\x0a{\x0avec3\x20n=normalize(inputN);\x0aif\x20(alphaG\x20==\x200.)\x20{\x0avec3\x20c=textureCube(inputTexture,n).rgb;\x0a#ifdef\x20GAMMA_INPUT\x0ac=toLinearSpace(c);\x0a#endif\x0areturn\x20c;\x0a}\x0avec3\x20result=vec3(0.);\x0avec3\x20tangent=abs(n.z)<0.999\x20?\x20vec3(0.,0.,1.)\x20:\x20vec3(1.,0.,0.);\x0atangent=normalize(cross(tangent,n));\x0avec3\x20bitangent=cross(n,tangent);\x0amat3\x20tbn=mat3(tangent,bitangent,n);\x0afloat\x20maxLevel=filteringInfo.y;\x0afloat\x20dim0=filteringInfo.x;\x0afloat\x20omegaP=(4.*PI)/(6.*dim0*dim0);\x0afloat\x20weight=0.;\x0a#ifdef\x20WEBGL2\x0afor(uint\x20i=0u;\x20i0.)\x20{\x0afloat\x20pdf_inversed=4./normalDistributionFunction_TrowbridgeReitzGGX(NoH,alphaG);\x0afloat\x20omegaS=NUM_SAMPLES_FLOAT_INVERSED*pdf_inversed;\x0afloat\x20l=log4(omegaS)-log4(omegaP)+log4(K);\x0afloat\x20mipLevel=clamp(float(l),0.0,maxLevel);\x0aweight+=NoL;\x0avec3\x20c=textureCubeLodEXT(inputTexture,tbn*L,mipLevel).rgb;\x0a#ifdef\x20GAMMA_INPUT\x0ac=toLinearSpace(c);\x0a#endif\x0aresult+=c*NoL;\x0a}\x0a}\x0aresult=result/weight;\x0areturn\x20result;\x0a}\x0a#endif\x0a#endif';_0x494b01['a']['IncludesShadersStore']['hdrFilteringFunctions']=_0x2f2e33;var _0x2ba81f='#define\x20CLEARCOATREFLECTANCE90\x201.0\x0a\x0astruct\x20lightingInfo\x0a{\x0avec3\x20diffuse;\x0a#ifdef\x20SPECULARTERM\x0avec3\x20specular;\x0a#endif\x0a#ifdef\x20CLEARCOAT\x0a\x0a\x0avec4\x20clearCoat;\x0a#endif\x0a#ifdef\x20SHEEN\x0avec3\x20sheen;\x0a#endif\x0a};\x0a\x0afloat\x20adjustRoughnessFromLightProperties(float\x20roughness,float\x20lightRadius,float\x20lightDistance)\x20{\x0a#if\x20defined(USEPHYSICALLIGHTFALLOFF)\x20||\x20defined(USEGLTFLIGHTFALLOFF)\x0a\x0afloat\x20lightRoughness=lightRadius/lightDistance;\x0a\x0afloat\x20totalRoughness=saturate(lightRoughness+roughness);\x0areturn\x20totalRoughness;\x0a#else\x0areturn\x20roughness;\x0a#endif\x0a}\x0avec3\x20computeHemisphericDiffuseLighting(preLightingInfo\x20info,vec3\x20lightColor,vec3\x20groundColor)\x20{\x0areturn\x20mix(groundColor,lightColor,info.NdotL);\x0a}\x0avec3\x20computeDiffuseLighting(preLightingInfo\x20info,vec3\x20lightColor)\x20{\x0afloat\x20diffuseTerm=diffuseBRDF_Burley(info.NdotL,info.NdotV,info.VdotH,info.roughness);\x0areturn\x20diffuseTerm*info.attenuation*info.NdotL*lightColor;\x0a}\x0a#define\x20inline\x0avec3\x20computeProjectionTextureDiffuseLighting(sampler2D\x20projectionLightSampler,mat4\x20textureProjectionMatrix){\x0avec4\x20strq=textureProjectionMatrix*vec4(vPositionW,1.0);\x0astrq/=strq.w;\x0avec3\x20textureColor=texture2D(projectionLightSampler,strq.xy).rgb;\x0areturn\x20toLinearSpace(textureColor);\x0a}\x0a#ifdef\x20SS_TRANSLUCENCY\x0avec3\x20computeDiffuseAndTransmittedLighting(preLightingInfo\x20info,vec3\x20lightColor,vec3\x20transmittance)\x20{\x0afloat\x20NdotL=absEps(info.NdotLUnclamped);\x0a\x0afloat\x20wrapNdotL=computeWrappedDiffuseNdotL(NdotL,0.02);\x0a\x0afloat\x20trAdapt=step(0.,info.NdotLUnclamped);\x0avec3\x20transmittanceNdotL=mix(transmittance*wrapNdotL,vec3(wrapNdotL),trAdapt);\x0afloat\x20diffuseTerm=diffuseBRDF_Burley(NdotL,info.NdotV,info.VdotH,info.roughness);\x0areturn\x20diffuseTerm*transmittanceNdotL*info.attenuation*lightColor;\x0a}\x0a#endif\x0a#ifdef\x20SPECULARTERM\x0avec3\x20computeSpecularLighting(preLightingInfo\x20info,vec3\x20N,vec3\x20reflectance0,vec3\x20reflectance90,float\x20geometricRoughnessFactor,vec3\x20lightColor)\x20{\x0afloat\x20NdotH=saturateEps(dot(N,info.H));\x0afloat\x20roughness=max(info.roughness,geometricRoughnessFactor);\x0afloat\x20alphaG=convertRoughnessToAverageSlope(roughness);\x0avec3\x20fresnel=fresnelSchlickGGX(info.VdotH,reflectance0,reflectance90);\x0afloat\x20distribution=normalDistributionFunction_TrowbridgeReitzGGX(NdotH,alphaG);\x0a#ifdef\x20BRDF_V_HEIGHT_CORRELATED\x0afloat\x20smithVisibility=smithVisibility_GGXCorrelated(info.NdotL,info.NdotV,alphaG);\x0a#else\x0afloat\x20smithVisibility=smithVisibility_TrowbridgeReitzGGXFast(info.NdotL,info.NdotV,alphaG);\x0a#endif\x0avec3\x20specTerm=fresnel*distribution*smithVisibility;\x0areturn\x20specTerm*info.attenuation*info.NdotL*lightColor;\x0a}\x0a#endif\x0a#ifdef\x20ANISOTROPIC\x0avec3\x20computeAnisotropicSpecularLighting(preLightingInfo\x20info,vec3\x20V,vec3\x20N,vec3\x20T,vec3\x20B,float\x20anisotropy,vec3\x20reflectance0,vec3\x20reflectance90,float\x20geometricRoughnessFactor,vec3\x20lightColor)\x20{\x0afloat\x20NdotH=saturateEps(dot(N,info.H));\x0afloat\x20TdotH=dot(T,info.H);\x0afloat\x20BdotH=dot(B,info.H);\x0afloat\x20TdotV=dot(T,V);\x0afloat\x20BdotV=dot(B,V);\x0afloat\x20TdotL=dot(T,info.L);\x0afloat\x20BdotL=dot(B,info.L);\x0afloat\x20alphaG=convertRoughnessToAverageSlope(info.roughness);\x0avec2\x20alphaTB=getAnisotropicRoughness(alphaG,anisotropy);\x0aalphaTB=max(alphaTB,square(geometricRoughnessFactor));\x0avec3\x20fresnel=fresnelSchlickGGX(info.VdotH,reflectance0,reflectance90);\x0afloat\x20distribution=normalDistributionFunction_BurleyGGX_Anisotropic(NdotH,TdotH,BdotH,alphaTB);\x0afloat\x20smithVisibility=smithVisibility_GGXCorrelated_Anisotropic(info.NdotL,info.NdotV,TdotV,BdotV,TdotL,BdotL,alphaTB);\x0avec3\x20specTerm=fresnel*distribution*smithVisibility;\x0areturn\x20specTerm*info.attenuation*info.NdotL*lightColor;\x0a}\x0a#endif\x0a#ifdef\x20CLEARCOAT\x0avec4\x20computeClearCoatLighting(preLightingInfo\x20info,vec3\x20Ncc,float\x20geometricRoughnessFactor,float\x20clearCoatIntensity,vec3\x20lightColor)\x20{\x0afloat\x20NccdotL=saturateEps(dot(Ncc,info.L));\x0afloat\x20NccdotH=saturateEps(dot(Ncc,info.H));\x0afloat\x20clearCoatRoughness=max(info.roughness,geometricRoughnessFactor);\x0afloat\x20alphaG=convertRoughnessToAverageSlope(clearCoatRoughness);\x0afloat\x20fresnel=fresnelSchlickGGX(info.VdotH,vClearCoatRefractionParams.x,CLEARCOATREFLECTANCE90);\x0afresnel*=clearCoatIntensity;\x0afloat\x20distribution=normalDistributionFunction_TrowbridgeReitzGGX(NccdotH,alphaG);\x0afloat\x20kelemenVisibility=visibility_Kelemen(info.VdotH);\x0afloat\x20clearCoatTerm=fresnel*distribution*kelemenVisibility;\x0areturn\x20vec4(\x0aclearCoatTerm*info.attenuation*NccdotL*lightColor,\x0a1.0-fresnel\x0a);\x0a}\x0avec3\x20computeClearCoatLightingAbsorption(float\x20NdotVRefract,vec3\x20L,vec3\x20Ncc,vec3\x20clearCoatColor,float\x20clearCoatThickness,float\x20clearCoatIntensity)\x20{\x0avec3\x20LRefract=-refract(L,Ncc,vClearCoatRefractionParams.y);\x0afloat\x20NdotLRefract=saturateEps(dot(Ncc,LRefract));\x0avec3\x20absorption=computeClearCoatAbsorption(NdotVRefract,NdotLRefract,clearCoatColor,clearCoatThickness,clearCoatIntensity);\x0areturn\x20absorption;\x0a}\x0a#endif\x0a#ifdef\x20SHEEN\x0avec3\x20computeSheenLighting(preLightingInfo\x20info,vec3\x20N,vec3\x20reflectance0,vec3\x20reflectance90,float\x20geometricRoughnessFactor,vec3\x20lightColor)\x20{\x0afloat\x20NdotH=saturateEps(dot(N,info.H));\x0afloat\x20roughness=max(info.roughness,geometricRoughnessFactor);\x0afloat\x20alphaG=convertRoughnessToAverageSlope(roughness);\x0a\x0a\x0afloat\x20fresnel=1.;\x0afloat\x20distribution=normalDistributionFunction_CharlieSheen(NdotH,alphaG);\x0a\x0afloat\x20visibility=visibility_Ashikhmin(info.NdotL,info.NdotV);\x0a\x0afloat\x20sheenTerm=fresnel*distribution*visibility;\x0areturn\x20sheenTerm*info.attenuation*info.NdotL*lightColor;\x0a}\x0a#endif\x0a';_0x494b01['a']['IncludesShadersStore']['pbrDirectLightingFunctions']=_0x2ba81f;var _0x5d9819='#if\x20defined(REFLECTION)\x20||\x20defined(SS_REFRACTION)\x0afloat\x20getLodFromAlphaG(float\x20cubeMapDimensionPixels,float\x20microsurfaceAverageSlope)\x20{\x0afloat\x20microsurfaceAverageSlopeTexels=cubeMapDimensionPixels*microsurfaceAverageSlope;\x0afloat\x20lod=log2(microsurfaceAverageSlopeTexels);\x0areturn\x20lod;\x0a}\x0afloat\x20getLinearLodFromRoughness(float\x20cubeMapDimensionPixels,float\x20roughness)\x20{\x0afloat\x20lod=log2(cubeMapDimensionPixels)*roughness;\x0areturn\x20lod;\x0a}\x0a#endif\x0a#if\x20defined(ENVIRONMENTBRDF)\x20&&\x20defined(RADIANCEOCCLUSION)\x0afloat\x20environmentRadianceOcclusion(float\x20ambientOcclusion,float\x20NdotVUnclamped)\x20{\x0a\x0a\x0afloat\x20temp=NdotVUnclamped+ambientOcclusion;\x0areturn\x20saturate(square(temp)-1.0+ambientOcclusion);\x0a}\x0a#endif\x0a#if\x20defined(ENVIRONMENTBRDF)\x20&&\x20defined(HORIZONOCCLUSION)\x0afloat\x20environmentHorizonOcclusion(vec3\x20view,vec3\x20normal,vec3\x20geometricNormal)\x20{\x0a\x0avec3\x20reflection=reflect(view,normal);\x0afloat\x20temp=saturate(1.0+1.1*dot(reflection,geometricNormal));\x0areturn\x20square(temp);\x0a}\x0a#endif\x0a\x0a\x0a\x0a\x0a#if\x20defined(LODINREFLECTIONALPHA)\x20||\x20defined(SS_LODINREFRACTIONALPHA)\x0a\x0a\x0a#define\x20UNPACK_LOD(x)\x20(1.0-x)*255.0\x0afloat\x20getLodFromAlphaG(float\x20cubeMapDimensionPixels,float\x20alphaG,float\x20NdotV)\x20{\x0afloat\x20microsurfaceAverageSlope=alphaG;\x0a\x0a\x0a\x0a\x0a\x0a\x0amicrosurfaceAverageSlope*=sqrt(abs(NdotV));\x0areturn\x20getLodFromAlphaG(cubeMapDimensionPixels,microsurfaceAverageSlope);\x0a}\x0a#endif';_0x494b01['a']['IncludesShadersStore']['pbrIBLFunctions']=_0x5d9819,(_0x162675(0x84),_0x162675(0x85));var _0x41c6ec='struct\x20albedoOpacityOutParams\x0a{\x0avec3\x20surfaceAlbedo;\x0afloat\x20alpha;\x0a};\x0a#define\x20pbr_inline\x0avoid\x20albedoOpacityBlock(\x0aconst\x20in\x20vec4\x20vAlbedoColor,\x0a#ifdef\x20ALBEDO\x0aconst\x20in\x20vec4\x20albedoTexture,\x0aconst\x20in\x20vec2\x20albedoInfos,\x0a#endif\x0a#ifdef\x20OPACITY\x0aconst\x20in\x20vec4\x20opacityMap,\x0aconst\x20in\x20vec2\x20vOpacityInfos,\x0a#endif\x0a#ifdef\x20DETAIL\x0aconst\x20in\x20vec4\x20detailColor,\x0aconst\x20in\x20vec4\x20vDetailInfos,\x0a#endif\x0aout\x20albedoOpacityOutParams\x20outParams\x0a)\x0a{\x0a\x0avec3\x20surfaceAlbedo=vAlbedoColor.rgb;\x0afloat\x20alpha=vAlbedoColor.a;\x0a#ifdef\x20ALBEDO\x0a#if\x20defined(ALPHAFROMALBEDO)\x20||\x20defined(ALPHATEST)\x0aalpha*=albedoTexture.a;\x0a#endif\x0a#ifdef\x20GAMMAALBEDO\x0asurfaceAlbedo*=toLinearSpace(albedoTexture.rgb);\x0a#else\x0asurfaceAlbedo*=albedoTexture.rgb;\x0a#endif\x0asurfaceAlbedo*=albedoInfos.y;\x0a#endif\x0a#ifdef\x20VERTEXCOLOR\x0asurfaceAlbedo*=vColor.rgb;\x0a#endif\x0a#ifdef\x20DETAIL\x0afloat\x20detailAlbedo=2.0*mix(0.5,detailColor.r,vDetailInfos.y);\x0asurfaceAlbedo.rgb=surfaceAlbedo.rgb*detailAlbedo*detailAlbedo;\x0a#endif\x0a#define\x20CUSTOM_FRAGMENT_UPDATE_ALBEDO\x0a\x0a#ifdef\x20OPACITY\x0a#ifdef\x20OPACITYRGB\x0aalpha=getLuminance(opacityMap.rgb);\x0a#else\x0aalpha*=opacityMap.a;\x0a#endif\x0aalpha*=vOpacityInfos.y;\x0a#endif\x0a#ifdef\x20VERTEXALPHA\x0aalpha*=vColor.a;\x0a#endif\x0a#if\x20!defined(SS_LINKREFRACTIONTOTRANSPARENCY)\x20&&\x20!defined(ALPHAFRESNEL)\x0a#ifdef\x20ALPHATEST\x0aif\x20(alpha0x0?(_0x183d82['NUM_SAMPLES']=''+this['realTimeFilteringQuality'],_0x5d8e16['webGLVersion']>0x1&&(_0x183d82['NUM_SAMPLES']=_0x183d82['NUM_SAMPLES']+'u'),_0x183d82['REALTIME_FILTERING']=!0x0):_0x183d82['REALTIME_FILTERING']=!0x1,_0x286f07['coordinatesMode']===_0xaf3c80['a']['INVCUBIC_MODE']&&(_0x183d82['INVERTCUBICMAP']=!0x0),_0x183d82['REFLECTIONMAP_3D']=_0x286f07['isCube'],_0x183d82['REFLECTIONMAP_CUBIC']=!0x1,_0x183d82['REFLECTIONMAP_EXPLICIT']=!0x1,_0x183d82['REFLECTIONMAP_PLANAR']=!0x1,_0x183d82['REFLECTIONMAP_PROJECTION']=!0x1,_0x183d82['REFLECTIONMAP_SKYBOX']=!0x1,_0x183d82['REFLECTIONMAP_SPHERICAL']=!0x1,_0x183d82['REFLECTIONMAP_EQUIRECTANGULAR']=!0x1,_0x183d82['REFLECTIONMAP_EQUIRECTANGULAR_FIXED']=!0x1,_0x183d82['REFLECTIONMAP_MIRROREDEQUIRECTANGULAR_FIXED']=!0x1,_0x286f07['coordinatesMode']){case _0xaf3c80['a']['EXPLICIT_MODE']:_0x183d82['REFLECTIONMAP_EXPLICIT']=!0x0;break;case _0xaf3c80['a']['PLANAR_MODE']:_0x183d82['REFLECTIONMAP_PLANAR']=!0x0;break;case _0xaf3c80['a']['PROJECTION_MODE']:_0x183d82['REFLECTIONMAP_PROJECTION']=!0x0;break;case _0xaf3c80['a']['SKYBOX_MODE']:_0x183d82['REFLECTIONMAP_SKYBOX']=!0x0;break;case _0xaf3c80['a']['SPHERICAL_MODE']:_0x183d82['REFLECTIONMAP_SPHERICAL']=!0x0;break;case _0xaf3c80['a']['EQUIRECTANGULAR_MODE']:_0x183d82['REFLECTIONMAP_EQUIRECTANGULAR']=!0x0;break;case _0xaf3c80['a']['FIXED_EQUIRECTANGULAR_MODE']:_0x183d82['REFLECTIONMAP_EQUIRECTANGULAR_FIXED']=!0x0;break;case _0xaf3c80['a']['FIXED_EQUIRECTANGULAR_MIRRORED_MODE']:_0x183d82['REFLECTIONMAP_MIRROREDEQUIRECTANGULAR_FIXED']=!0x0;break;case _0xaf3c80['a']['CUBIC_MODE']:case _0xaf3c80['a']['INVCUBIC_MODE']:default:_0x183d82['REFLECTIONMAP_CUBIC']=!0x0,_0x183d82['USE_LOCAL_REFLECTIONMAP_CUBIC']=!!_0x286f07['boundingBoxSize'];}_0x286f07['coordinatesMode']!==_0xaf3c80['a']['SKYBOX_MODE']&&(_0x286f07['irradianceTexture']?(_0x183d82['USEIRRADIANCEMAP']=!0x0,_0x183d82['USESPHERICALFROMREFLECTIONMAP']=!0x1):_0x286f07['isCube']&&(_0x183d82['USESPHERICALFROMREFLECTIONMAP']=!0x0,_0x183d82['USEIRRADIANCEMAP']=!0x1,this['_forceIrradianceInFragment']||this['realTimeFiltering']||_0xae2ab3['getEngine']()['getCaps']()['maxVaryingVectors']<=0x8?_0x183d82['USESPHERICALINVERTEX']=!0x1:_0x183d82['USESPHERICALINVERTEX']=!0x0));}else _0x183d82['REFLECTION']=!0x1,_0x183d82['REFLECTIONMAP_3D']=!0x1,_0x183d82['REFLECTIONMAP_SPHERICAL']=!0x1,_0x183d82['REFLECTIONMAP_PLANAR']=!0x1,_0x183d82['REFLECTIONMAP_CUBIC']=!0x1,_0x183d82['USE_LOCAL_REFLECTIONMAP_CUBIC']=!0x1,_0x183d82['REFLECTIONMAP_PROJECTION']=!0x1,_0x183d82['REFLECTIONMAP_SKYBOX']=!0x1,_0x183d82['REFLECTIONMAP_EXPLICIT']=!0x1,_0x183d82['REFLECTIONMAP_EQUIRECTANGULAR']=!0x1,_0x183d82['REFLECTIONMAP_EQUIRECTANGULAR_FIXED']=!0x1,_0x183d82['REFLECTIONMAP_MIRROREDEQUIRECTANGULAR_FIXED']=!0x1,_0x183d82['INVERTCUBICMAP']=!0x1,_0x183d82['USESPHERICALFROMREFLECTIONMAP']=!0x1,_0x183d82['USEIRRADIANCEMAP']=!0x1,_0x183d82['USESPHERICALINVERTEX']=!0x1,_0x183d82['REFLECTIONMAP_OPPOSITEZ']=!0x1,_0x183d82['LODINREFLECTIONALPHA']=!0x1,_0x183d82['GAMMAREFLECTION']=!0x1,_0x183d82['RGBDREFLECTION']=!0x1,_0x183d82['LINEARSPECULARREFLECTION']=!0x1;this['_lightmapTexture']&&_0x4e6421['a']['LightmapTextureEnabled']?(_0x464f31['a']['PrepareDefinesForMergedUV'](this['_lightmapTexture'],_0x183d82,'LIGHTMAP'),_0x183d82['USELIGHTMAPASSHADOWMAP']=this['_useLightmapAsShadowmap'],_0x183d82['GAMMALIGHTMAP']=this['_lightmapTexture']['gammaSpace'],_0x183d82['RGBDLIGHTMAP']=this['_lightmapTexture']['isRGBD']):_0x183d82['LIGHTMAP']=!0x1,this['_emissiveTexture']&&_0x4e6421['a']['EmissiveTextureEnabled']?_0x464f31['a']['PrepareDefinesForMergedUV'](this['_emissiveTexture'],_0x183d82,'EMISSIVE'):_0x183d82['EMISSIVE']=!0x1,_0x4e6421['a']['SpecularTextureEnabled']?(this['_metallicTexture']?(_0x464f31['a']['PrepareDefinesForMergedUV'](this['_metallicTexture'],_0x183d82,'REFLECTIVITY'),_0x183d82['ROUGHNESSSTOREINMETALMAPALPHA']=this['_useRoughnessFromMetallicTextureAlpha'],_0x183d82['ROUGHNESSSTOREINMETALMAPGREEN']=!this['_useRoughnessFromMetallicTextureAlpha']&&this['_useRoughnessFromMetallicTextureGreen'],_0x183d82['METALLNESSSTOREINMETALMAPBLUE']=this['_useMetallnessFromMetallicTextureBlue'],_0x183d82['AOSTOREINMETALMAPRED']=this['_useAmbientOcclusionFromMetallicTextureRed']):this['_reflectivityTexture']?(_0x464f31['a']['PrepareDefinesForMergedUV'](this['_reflectivityTexture'],_0x183d82,'REFLECTIVITY'),_0x183d82['MICROSURFACEFROMREFLECTIVITYMAP']=this['_useMicroSurfaceFromReflectivityMapAlpha'],_0x183d82['MICROSURFACEAUTOMATIC']=this['_useAutoMicroSurfaceFromReflectivityMap']):_0x183d82['REFLECTIVITY']=!0x1,this['_metallicReflectanceTexture']?_0x464f31['a']['PrepareDefinesForMergedUV'](this['_metallicReflectanceTexture'],_0x183d82,'METALLIC_REFLECTANCE'):_0x183d82['METALLIC_REFLECTANCE']=!0x1,this['_microSurfaceTexture']?_0x464f31['a']['PrepareDefinesForMergedUV'](this['_microSurfaceTexture'],_0x183d82,'MICROSURFACEMAP'):_0x183d82['MICROSURFACEMAP']=!0x1):(_0x183d82['REFLECTIVITY']=!0x1,_0x183d82['MICROSURFACEMAP']=!0x1),_0xae2ab3['getEngine']()['getCaps']()['standardDerivatives']&&this['_bumpTexture']&&_0x4e6421['a']['BumpTextureEnabled']&&!this['_disableBumpMap']?(_0x464f31['a']['PrepareDefinesForMergedUV'](this['_bumpTexture'],_0x183d82,'BUMP'),this['_useParallax']&&this['_albedoTexture']&&_0x4e6421['a']['DiffuseTextureEnabled']?(_0x183d82['PARALLAX']=!0x0,_0x183d82['PARALLAXOCCLUSION']=!!this['_useParallaxOcclusion']):_0x183d82['PARALLAX']=!0x1,_0x183d82['OBJECTSPACE_NORMALMAP']=this['_useObjectSpaceNormalMap']):_0x183d82['BUMP']=!0x1,this['_environmentBRDFTexture']&&_0x4e6421['a']['ReflectionTextureEnabled']?(_0x183d82['ENVIRONMENTBRDF']=!0x0,_0x183d82['ENVIRONMENTBRDF_RGBD']=this['_environmentBRDFTexture']['isRGBD']):(_0x183d82['ENVIRONMENTBRDF']=!0x1,_0x183d82['ENVIRONMENTBRDF_RGBD']=!0x1),this['_shouldUseAlphaFromAlbedoTexture']()?_0x183d82['ALPHAFROMALBEDO']=!0x0:_0x183d82['ALPHAFROMALBEDO']=!0x1;}_0x183d82['SPECULAROVERALPHA']=this['_useSpecularOverAlpha'],this['_lightFalloff']===_0x507cd3['LIGHTFALLOFF_STANDARD']?(_0x183d82['USEPHYSICALLIGHTFALLOFF']=!0x1,_0x183d82['USEGLTFLIGHTFALLOFF']=!0x1):this['_lightFalloff']===_0x507cd3['LIGHTFALLOFF_GLTF']?(_0x183d82['USEPHYSICALLIGHTFALLOFF']=!0x1,_0x183d82['USEGLTFLIGHTFALLOFF']=!0x0):(_0x183d82['USEPHYSICALLIGHTFALLOFF']=!0x0,_0x183d82['USEGLTFLIGHTFALLOFF']=!0x1),_0x183d82['RADIANCEOVERALPHA']=this['_useRadianceOverAlpha'],!this['backFaceCulling']&&this['_twoSidedLighting']?_0x183d82['TWOSIDEDLIGHTING']=!0x0:_0x183d82['TWOSIDEDLIGHTING']=!0x1,_0x183d82['SPECULARAA']=_0xae2ab3['getEngine']()['getCaps']()['standardDerivatives']&&this['_enableSpecularAntiAliasing'];}(_0x183d82['_areTexturesDirty']||_0x183d82['_areMiscDirty'])&&(_0x183d82['ALPHATESTVALUE']=this['_alphaCutOff']+(this['_alphaCutOff']%0x1==0x0?'.':''),_0x183d82['PREMULTIPLYALPHA']=this['alphaMode']===_0x2103ba['a']['ALPHA_PREMULTIPLIED']||this['alphaMode']===_0x2103ba['a']['ALPHA_PREMULTIPLIED_PORTERDUFF'],_0x183d82['ALPHABLEND']=this['needAlphaBlendingForMesh'](_0x220547),_0x183d82['ALPHAFRESNEL']=this['_useAlphaFresnel']||this['_useLinearAlphaFresnel'],_0x183d82['LINEARALPHAFRESNEL']=this['_useLinearAlphaFresnel']),_0x183d82['_areImageProcessingDirty']&&this['_imageProcessingConfiguration']&&this['_imageProcessingConfiguration']['prepareDefines'](_0x183d82),_0x183d82['FORCENORMALFORWARD']=this['_forceNormalForward'],_0x183d82['RADIANCEOCCLUSION']=this['_useRadianceOcclusion'],_0x183d82['HORIZONOCCLUSION']=this['_useHorizonOcclusion'],_0x183d82['_areMiscDirty']&&(_0x464f31['a']['PrepareDefinesForMisc'](_0x220547,_0xae2ab3,this['_useLogarithmicDepth'],this['pointsCloud'],this['fogEnabled'],this['_shouldTurnAlphaTestOn'](_0x220547)||this['_forceAlphaTest'],_0x183d82),_0x183d82['UNLIT']=this['_unlit']||(this['pointsCloud']||this['wireframe'])&&!_0x220547['isVerticesDataPresent'](_0x212fbd['b']['NormalKind']),_0x183d82['DEBUGMODE']=this['_debugMode']),this['detailMap']['prepareDefines'](_0x183d82,_0xae2ab3),this['subSurface']['prepareDefines'](_0x183d82,_0xae2ab3),this['clearCoat']['prepareDefines'](_0x183d82,_0xae2ab3),this['anisotropy']['prepareDefines'](_0x183d82,_0x220547,_0xae2ab3),this['brdf']['prepareDefines'](_0x183d82),this['sheen']['prepareDefines'](_0x183d82,_0xae2ab3),_0x464f31['a']['PrepareDefinesForFrameBoundValues'](_0xae2ab3,_0x5d8e16,_0x183d82,!!_0x3d4b7c,_0x369b6b,_0x3fe975),_0x464f31['a']['PrepareDefinesForAttributes'](_0x220547,_0x183d82,!0x0,!0x0,!0x0,this['_transparencyMode']!==_0x507cd3['PBRMATERIAL_OPAQUE']);},_0x507cd3['prototype']['forceCompilation']=function(_0x2565b0,_0x4e20ca,_0x38edfb){var _0x5686e5=this,_0x34ac65=Object(_0x18e13d['a'])({'clipPlane':!0x1,'useInstances':!0x1},_0x38edfb),_0x1ceb35=new _0x4fc3ba(),_0xf42e78=this['_prepareEffect'](_0x2565b0,_0x1ceb35,void 0x0,void 0x0,_0x34ac65['useInstances'],_0x34ac65['clipPlane'],_0x2565b0['hasThinInstances']);this['_onEffectCreatedObservable']&&(_0x3c0510['effect']=_0xf42e78,_0x3c0510['subMesh']=null,this['_onEffectCreatedObservable']['notifyObservers'](_0x3c0510)),_0xf42e78['isReady']()?_0x4e20ca&&_0x4e20ca(this):_0xf42e78['onCompileObservable']['add'](function(){_0x4e20ca&&_0x4e20ca(_0x5686e5);});},_0x507cd3['prototype']['buildUniformLayout']=function(){var _0x286a8a=this['_uniformBuffer'];_0x286a8a['addUniform']('vAlbedoInfos',0x2),_0x286a8a['addUniform']('vAmbientInfos',0x4),_0x286a8a['addUniform']('vOpacityInfos',0x2),_0x286a8a['addUniform']('vEmissiveInfos',0x2),_0x286a8a['addUniform']('vLightmapInfos',0x2),_0x286a8a['addUniform']('vReflectivityInfos',0x3),_0x286a8a['addUniform']('vMicroSurfaceSamplerInfos',0x2),_0x286a8a['addUniform']('vReflectionInfos',0x2),_0x286a8a['addUniform']('vReflectionFilteringInfo',0x2),_0x286a8a['addUniform']('vReflectionPosition',0x3),_0x286a8a['addUniform']('vReflectionSize',0x3),_0x286a8a['addUniform']('vBumpInfos',0x3),_0x286a8a['addUniform']('albedoMatrix',0x10),_0x286a8a['addUniform']('ambientMatrix',0x10),_0x286a8a['addUniform']('opacityMatrix',0x10),_0x286a8a['addUniform']('emissiveMatrix',0x10),_0x286a8a['addUniform']('lightmapMatrix',0x10),_0x286a8a['addUniform']('reflectivityMatrix',0x10),_0x286a8a['addUniform']('microSurfaceSamplerMatrix',0x10),_0x286a8a['addUniform']('bumpMatrix',0x10),_0x286a8a['addUniform']('vTangentSpaceParams',0x2),_0x286a8a['addUniform']('reflectionMatrix',0x10),_0x286a8a['addUniform']('vReflectionColor',0x3),_0x286a8a['addUniform']('vAlbedoColor',0x4),_0x286a8a['addUniform']('vLightingIntensity',0x4),_0x286a8a['addUniform']('vReflectionMicrosurfaceInfos',0x3),_0x286a8a['addUniform']('pointSize',0x1),_0x286a8a['addUniform']('vReflectivityColor',0x4),_0x286a8a['addUniform']('vEmissiveColor',0x3),_0x286a8a['addUniform']('visibility',0x1),_0x286a8a['addUniform']('vMetallicReflectanceFactors',0x4),_0x286a8a['addUniform']('vMetallicReflectanceInfos',0x2),_0x286a8a['addUniform']('metallicReflectanceMatrix',0x10),_0x22aa38['PrepareUniformBuffer'](_0x286a8a),_0x41ac2f['PrepareUniformBuffer'](_0x286a8a),_0xc42c4d['PrepareUniformBuffer'](_0x286a8a),_0x582aa7['PrepareUniformBuffer'](_0x286a8a),_0x291b80['a']['PrepareUniformBuffer'](_0x286a8a),_0x286a8a['create']();},_0x507cd3['prototype']['unbind']=function(){if(this['_activeEffect']){var _0x3811d7=!0x1;this['_reflectionTexture']&&this['_reflectionTexture']['isRenderTarget']&&(this['_activeEffect']['setTexture']('reflection2DSampler',null),_0x3811d7=!0x0),this['subSurface']['unbind'](this['_activeEffect'])&&(_0x3811d7=!0x0),_0x3811d7&&this['_markAllSubMeshesAsTexturesDirty']();}_0xcef097['prototype']['unbind']['call'](this);},_0x507cd3['prototype']['bindForSubMesh']=function(_0x554550,_0x5ec2b8,_0x1a95b1){var _0x43b194=this['getScene'](),_0x3904cb=_0x1a95b1['_materialDefines'];if(_0x3904cb){var _0x1792d5=_0x1a95b1['effect'];if(_0x1792d5){this['_activeEffect']=_0x1792d5,_0x3904cb['INSTANCES']&&!_0x3904cb['THIN_INSTANCES']||this['bindOnlyWorldMatrix'](_0x554550),this['prePassConfiguration']['bindForSubMesh'](this['_activeEffect'],_0x43b194,_0x5ec2b8,_0x554550,this['isFrozen']),_0x3904cb['OBJECTSPACE_NORMALMAP']&&(_0x554550['toNormalMatrix'](this['_normalMatrix']),this['bindOnlyNormalMatrix'](this['_normalMatrix']));var _0x520233=this['_mustRebind'](_0x43b194,_0x1792d5,_0x5ec2b8['visibility']);_0x464f31['a']['BindBonesParameters'](_0x5ec2b8,this['_activeEffect'],this['prePassConfiguration']);var _0x5c5b8e=null,_0x5cd7db=this['_uniformBuffer'];if(_0x520233){var _0x5c811c=_0x43b194['getEngine']();if(_0x5cd7db['bindToEffect'](_0x1792d5,'Material'),this['bindViewProjection'](_0x1792d5),_0x5c5b8e=this['_getReflectionTexture'](),!_0x5cd7db['useUbo']||!this['isFrozen']||!_0x5cd7db['isSync']){if(_0x43b194['texturesEnabled']){if(this['_albedoTexture']&&_0x4e6421['a']['DiffuseTextureEnabled']&&(_0x5cd7db['updateFloat2']('vAlbedoInfos',this['_albedoTexture']['coordinatesIndex'],this['_albedoTexture']['level']),_0x464f31['a']['BindTextureMatrix'](this['_albedoTexture'],_0x5cd7db,'albedo')),this['_ambientTexture']&&_0x4e6421['a']['AmbientTextureEnabled']&&(_0x5cd7db['updateFloat4']('vAmbientInfos',this['_ambientTexture']['coordinatesIndex'],this['_ambientTexture']['level'],this['_ambientTextureStrength'],this['_ambientTextureImpactOnAnalyticalLights']),_0x464f31['a']['BindTextureMatrix'](this['_ambientTexture'],_0x5cd7db,'ambient')),this['_opacityTexture']&&_0x4e6421['a']['OpacityTextureEnabled']&&(_0x5cd7db['updateFloat2']('vOpacityInfos',this['_opacityTexture']['coordinatesIndex'],this['_opacityTexture']['level']),_0x464f31['a']['BindTextureMatrix'](this['_opacityTexture'],_0x5cd7db,'opacity')),_0x5c5b8e&&_0x4e6421['a']['ReflectionTextureEnabled']){if(_0x5cd7db['updateMatrix']('reflectionMatrix',_0x5c5b8e['getReflectionTextureMatrix']()),_0x5cd7db['updateFloat2']('vReflectionInfos',_0x5c5b8e['level'],0x0),_0x5c5b8e['boundingBoxSize']){var _0x375710=_0x5c5b8e;_0x5cd7db['updateVector3']('vReflectionPosition',_0x375710['boundingBoxPosition']),_0x5cd7db['updateVector3']('vReflectionSize',_0x375710['boundingBoxSize']);}if(this['realTimeFiltering']){var _0x186c41=_0x5c5b8e['getSize']()['width'];_0x5cd7db['updateFloat2']('vReflectionFilteringInfo',_0x186c41,_0x4a0cf0['a']['Log2'](_0x186c41));}if(!_0x3904cb['USEIRRADIANCEMAP']){var _0x4bdefd=_0x5c5b8e['sphericalPolynomial'];if(_0x3904cb['USESPHERICALFROMREFLECTIONMAP']&&_0x4bdefd){if(_0x3904cb['SPHERICAL_HARMONICS']){var _0x54929d=_0x4bdefd['preScaledHarmonics'];this['_activeEffect']['setVector3']('vSphericalL00',_0x54929d['l00']),this['_activeEffect']['setVector3']('vSphericalL1_1',_0x54929d['l1_1']),this['_activeEffect']['setVector3']('vSphericalL10',_0x54929d['l10']),this['_activeEffect']['setVector3']('vSphericalL11',_0x54929d['l11']),this['_activeEffect']['setVector3']('vSphericalL2_2',_0x54929d['l2_2']),this['_activeEffect']['setVector3']('vSphericalL2_1',_0x54929d['l2_1']),this['_activeEffect']['setVector3']('vSphericalL20',_0x54929d['l20']),this['_activeEffect']['setVector3']('vSphericalL21',_0x54929d['l21']),this['_activeEffect']['setVector3']('vSphericalL22',_0x54929d['l22']);}else this['_activeEffect']['setFloat3']('vSphericalX',_0x4bdefd['x']['x'],_0x4bdefd['x']['y'],_0x4bdefd['x']['z']),this['_activeEffect']['setFloat3']('vSphericalY',_0x4bdefd['y']['x'],_0x4bdefd['y']['y'],_0x4bdefd['y']['z']),this['_activeEffect']['setFloat3']('vSphericalZ',_0x4bdefd['z']['x'],_0x4bdefd['z']['y'],_0x4bdefd['z']['z']),this['_activeEffect']['setFloat3']('vSphericalXX_ZZ',_0x4bdefd['xx']['x']-_0x4bdefd['zz']['x'],_0x4bdefd['xx']['y']-_0x4bdefd['zz']['y'],_0x4bdefd['xx']['z']-_0x4bdefd['zz']['z']),this['_activeEffect']['setFloat3']('vSphericalYY_ZZ',_0x4bdefd['yy']['x']-_0x4bdefd['zz']['x'],_0x4bdefd['yy']['y']-_0x4bdefd['zz']['y'],_0x4bdefd['yy']['z']-_0x4bdefd['zz']['z']),this['_activeEffect']['setFloat3']('vSphericalZZ',_0x4bdefd['zz']['x'],_0x4bdefd['zz']['y'],_0x4bdefd['zz']['z']),this['_activeEffect']['setFloat3']('vSphericalXY',_0x4bdefd['xy']['x'],_0x4bdefd['xy']['y'],_0x4bdefd['xy']['z']),this['_activeEffect']['setFloat3']('vSphericalYZ',_0x4bdefd['yz']['x'],_0x4bdefd['yz']['y'],_0x4bdefd['yz']['z']),this['_activeEffect']['setFloat3']('vSphericalZX',_0x4bdefd['zx']['x'],_0x4bdefd['zx']['y'],_0x4bdefd['zx']['z']);}}_0x5cd7db['updateFloat3']('vReflectionMicrosurfaceInfos',_0x5c5b8e['getSize']()['width'],_0x5c5b8e['lodGenerationScale'],_0x5c5b8e['lodGenerationOffset']);}this['_emissiveTexture']&&_0x4e6421['a']['EmissiveTextureEnabled']&&(_0x5cd7db['updateFloat2']('vEmissiveInfos',this['_emissiveTexture']['coordinatesIndex'],this['_emissiveTexture']['level']),_0x464f31['a']['BindTextureMatrix'](this['_emissiveTexture'],_0x5cd7db,'emissive')),this['_lightmapTexture']&&_0x4e6421['a']['LightmapTextureEnabled']&&(_0x5cd7db['updateFloat2']('vLightmapInfos',this['_lightmapTexture']['coordinatesIndex'],this['_lightmapTexture']['level']),_0x464f31['a']['BindTextureMatrix'](this['_lightmapTexture'],_0x5cd7db,'lightmap')),_0x4e6421['a']['SpecularTextureEnabled']&&(this['_metallicTexture']?(_0x5cd7db['updateFloat3']('vReflectivityInfos',this['_metallicTexture']['coordinatesIndex'],this['_metallicTexture']['level'],this['_ambientTextureStrength']),_0x464f31['a']['BindTextureMatrix'](this['_metallicTexture'],_0x5cd7db,'reflectivity')):this['_reflectivityTexture']&&(_0x5cd7db['updateFloat3']('vReflectivityInfos',this['_reflectivityTexture']['coordinatesIndex'],this['_reflectivityTexture']['level'],0x1),_0x464f31['a']['BindTextureMatrix'](this['_reflectivityTexture'],_0x5cd7db,'reflectivity')),this['_metallicReflectanceTexture']&&(_0x5cd7db['updateFloat2']('vMetallicReflectanceInfos',this['_metallicReflectanceTexture']['coordinatesIndex'],this['_metallicReflectanceTexture']['level']),_0x464f31['a']['BindTextureMatrix'](this['_metallicReflectanceTexture'],_0x5cd7db,'metallicReflectance')),this['_microSurfaceTexture']&&(_0x5cd7db['updateFloat2']('vMicroSurfaceSamplerInfos',this['_microSurfaceTexture']['coordinatesIndex'],this['_microSurfaceTexture']['level']),_0x464f31['a']['BindTextureMatrix'](this['_microSurfaceTexture'],_0x5cd7db,'microSurfaceSampler'))),this['_bumpTexture']&&_0x5c811c['getCaps']()['standardDerivatives']&&_0x4e6421['a']['BumpTextureEnabled']&&!this['_disableBumpMap']&&(_0x5cd7db['updateFloat3']('vBumpInfos',this['_bumpTexture']['coordinatesIndex'],this['_bumpTexture']['level'],this['_parallaxScaleBias']),_0x464f31['a']['BindTextureMatrix'](this['_bumpTexture'],_0x5cd7db,'bump'),_0x43b194['_mirroredCameraPosition']?_0x5cd7db['updateFloat2']('vTangentSpaceParams',this['_invertNormalMapX']?0x1:-0x1,this['_invertNormalMapY']?0x1:-0x1):_0x5cd7db['updateFloat2']('vTangentSpaceParams',this['_invertNormalMapX']?-0x1:0x1,this['_invertNormalMapY']?-0x1:0x1));}if(this['pointsCloud']&&_0x5cd7db['updateFloat']('pointSize',this['pointSize']),_0x3904cb['METALLICWORKFLOW']){_0x39310d['c']['Color3'][0x0]['r']=void 0x0===this['_metallic']||null===this['_metallic']?0x1:this['_metallic'],_0x39310d['c']['Color3'][0x0]['g']=void 0x0===this['_roughness']||null===this['_roughness']?0x1:this['_roughness'],_0x5cd7db['updateColor4']('vReflectivityColor',_0x39310d['c']['Color3'][0x0],0x1);var _0x31d8f4=this['subSurface']['indexOfRefraction'],_0x3a4f4f=Math['pow']((_0x31d8f4-0x1)/(_0x31d8f4+0x1),0x2);this['_metallicReflectanceColor']['scaleToRef'](_0x3a4f4f*this['_metallicF0Factor'],_0x39310d['c']['Color3'][0x0]);var _0x5d6edf=this['_metallicF0Factor'];_0x5cd7db['updateColor4']('vMetallicReflectanceFactors',_0x39310d['c']['Color3'][0x0],_0x5d6edf);}else _0x5cd7db['updateColor4']('vReflectivityColor',this['_reflectivityColor'],this['_microSurface']);_0x5cd7db['updateColor3']('vEmissiveColor',_0x4e6421['a']['EmissiveTextureEnabled']?this['_emissiveColor']:_0x39310d['a']['BlackReadOnly']),_0x5cd7db['updateColor3']('vReflectionColor',this['_reflectionColor']),!_0x3904cb['SS_REFRACTION']&&this['subSurface']['linkRefractionWithTransparency']?_0x5cd7db['updateColor4']('vAlbedoColor',this['_albedoColor'],0x1):_0x5cd7db['updateColor4']('vAlbedoColor',this['_albedoColor'],this['alpha']),this['_lightingInfos']['x']=this['_directIntensity'],this['_lightingInfos']['y']=this['_emissiveIntensity'],this['_lightingInfos']['z']=this['_environmentIntensity']*_0x43b194['environmentIntensity'],this['_lightingInfos']['w']=this['_specularIntensity'],_0x5cd7db['updateVector4']('vLightingIntensity',this['_lightingInfos']);}_0x5cd7db['updateFloat']('visibility',_0x5ec2b8['visibility']),_0x43b194['texturesEnabled']&&(this['_albedoTexture']&&_0x4e6421['a']['DiffuseTextureEnabled']&&_0x5cd7db['setTexture']('albedoSampler',this['_albedoTexture']),this['_ambientTexture']&&_0x4e6421['a']['AmbientTextureEnabled']&&_0x5cd7db['setTexture']('ambientSampler',this['_ambientTexture']),this['_opacityTexture']&&_0x4e6421['a']['OpacityTextureEnabled']&&_0x5cd7db['setTexture']('opacitySampler',this['_opacityTexture']),_0x5c5b8e&&_0x4e6421['a']['ReflectionTextureEnabled']&&(_0x3904cb['LODBASEDMICROSFURACE']?_0x5cd7db['setTexture']('reflectionSampler',_0x5c5b8e):(_0x5cd7db['setTexture']('reflectionSampler',_0x5c5b8e['_lodTextureMid']||_0x5c5b8e),_0x5cd7db['setTexture']('reflectionSamplerLow',_0x5c5b8e['_lodTextureLow']||_0x5c5b8e),_0x5cd7db['setTexture']('reflectionSamplerHigh',_0x5c5b8e['_lodTextureHigh']||_0x5c5b8e)),_0x3904cb['USEIRRADIANCEMAP']&&_0x5cd7db['setTexture']('irradianceSampler',_0x5c5b8e['irradianceTexture'])),_0x3904cb['ENVIRONMENTBRDF']&&_0x5cd7db['setTexture']('environmentBrdfSampler',this['_environmentBRDFTexture']),this['_emissiveTexture']&&_0x4e6421['a']['EmissiveTextureEnabled']&&_0x5cd7db['setTexture']('emissiveSampler',this['_emissiveTexture']),this['_lightmapTexture']&&_0x4e6421['a']['LightmapTextureEnabled']&&_0x5cd7db['setTexture']('lightmapSampler',this['_lightmapTexture']),_0x4e6421['a']['SpecularTextureEnabled']&&(this['_metallicTexture']?_0x5cd7db['setTexture']('reflectivitySampler',this['_metallicTexture']):this['_reflectivityTexture']&&_0x5cd7db['setTexture']('reflectivitySampler',this['_reflectivityTexture']),this['_metallicReflectanceTexture']&&_0x5cd7db['setTexture']('metallicReflectanceSampler',this['_metallicReflectanceTexture']),this['_microSurfaceTexture']&&_0x5cd7db['setTexture']('microSurfaceSampler',this['_microSurfaceTexture'])),this['_bumpTexture']&&_0x5c811c['getCaps']()['standardDerivatives']&&_0x4e6421['a']['BumpTextureEnabled']&&!this['_disableBumpMap']&&_0x5cd7db['setTexture']('bumpSampler',this['_bumpTexture'])),this['detailMap']['bindForSubMesh'](_0x5cd7db,_0x43b194,this['isFrozen']),this['subSurface']['bindForSubMesh'](_0x5cd7db,_0x43b194,_0x5c811c,this['isFrozen'],_0x3904cb['LODBASEDMICROSFURACE'],this['realTimeFiltering']),this['clearCoat']['bindForSubMesh'](_0x5cd7db,_0x43b194,_0x5c811c,this['_disableBumpMap'],this['isFrozen'],this['_invertNormalMapX'],this['_invertNormalMapY'],_0x1a95b1),this['anisotropy']['bindForSubMesh'](_0x5cd7db,_0x43b194,this['isFrozen']),this['sheen']['bindForSubMesh'](_0x5cd7db,_0x43b194,this['isFrozen'],_0x1a95b1),_0x464f31['a']['BindClipPlane'](this['_activeEffect'],_0x43b194),_0x43b194['ambientColor']['multiplyToRef'](this['_ambientColor'],this['_globalAmbientColor']);var _0x2c4639=_0x43b194['_forcedViewPosition']?_0x43b194['_forcedViewPosition']:_0x43b194['_mirroredCameraPosition']?_0x43b194['_mirroredCameraPosition']:_0x43b194['activeCamera']['globalPosition'],_0x486013=_0x43b194['useRightHandedSystem']===(null!=_0x43b194['_mirroredCameraPosition']);_0x1792d5['setFloat4']('vEyePosition',_0x2c4639['x'],_0x2c4639['y'],_0x2c4639['z'],_0x486013?-0x1:0x1),_0x1792d5['setColor3']('vAmbientColor',this['_globalAmbientColor']),_0x1792d5['setFloat2']('vDebugMode',this['debugLimit'],this['debugFactor']);}!_0x520233&&this['isFrozen']||(_0x43b194['lightsEnabled']&&!this['_disableLighting']&&_0x464f31['a']['BindLights'](_0x43b194,_0x5ec2b8,this['_activeEffect'],_0x3904cb,this['_maxSimultaneousLights'],this['_rebuildInParallel']),(_0x43b194['fogEnabled']&&_0x5ec2b8['applyFog']&&_0x43b194['fogMode']!==_0x59370b['a']['FOGMODE_NONE']||_0x5c5b8e)&&this['bindView'](_0x1792d5),_0x464f31['a']['BindFogParameters'](_0x43b194,_0x5ec2b8,this['_activeEffect'],!0x0),_0x3904cb['NUM_MORPH_INFLUENCERS']&&_0x464f31['a']['BindMorphTargetParameters'](_0x5ec2b8,this['_activeEffect']),this['_imageProcessingConfiguration']['bind'](this['_activeEffect']),_0x464f31['a']['BindLogDepth'](_0x3904cb,this['_activeEffect'],_0x43b194)),_0x5cd7db['update'](),this['_afterBind'](_0x5ec2b8,this['_activeEffect']);}}},_0x507cd3['prototype']['getAnimatables']=function(){var _0xaf254b=[];return this['_albedoTexture']&&this['_albedoTexture']['animations']&&this['_albedoTexture']['animations']['length']>0x0&&_0xaf254b['push'](this['_albedoTexture']),this['_ambientTexture']&&this['_ambientTexture']['animations']&&this['_ambientTexture']['animations']['length']>0x0&&_0xaf254b['push'](this['_ambientTexture']),this['_opacityTexture']&&this['_opacityTexture']['animations']&&this['_opacityTexture']['animations']['length']>0x0&&_0xaf254b['push'](this['_opacityTexture']),this['_reflectionTexture']&&this['_reflectionTexture']['animations']&&this['_reflectionTexture']['animations']['length']>0x0&&_0xaf254b['push'](this['_reflectionTexture']),this['_emissiveTexture']&&this['_emissiveTexture']['animations']&&this['_emissiveTexture']['animations']['length']>0x0&&_0xaf254b['push'](this['_emissiveTexture']),this['_metallicTexture']&&this['_metallicTexture']['animations']&&this['_metallicTexture']['animations']['length']>0x0?_0xaf254b['push'](this['_metallicTexture']):this['_reflectivityTexture']&&this['_reflectivityTexture']['animations']&&this['_reflectivityTexture']['animations']['length']>0x0&&_0xaf254b['push'](this['_reflectivityTexture']),this['_bumpTexture']&&this['_bumpTexture']['animations']&&this['_bumpTexture']['animations']['length']>0x0&&_0xaf254b['push'](this['_bumpTexture']),this['_lightmapTexture']&&this['_lightmapTexture']['animations']&&this['_lightmapTexture']['animations']['length']>0x0&&_0xaf254b['push'](this['_lightmapTexture']),this['detailMap']['getAnimatables'](_0xaf254b),this['subSurface']['getAnimatables'](_0xaf254b),this['clearCoat']['getAnimatables'](_0xaf254b),this['sheen']['getAnimatables'](_0xaf254b),this['anisotropy']['getAnimatables'](_0xaf254b),_0xaf254b;},_0x507cd3['prototype']['_getReflectionTexture']=function(){return this['_reflectionTexture']?this['_reflectionTexture']:this['getScene']()['environmentTexture'];},_0x507cd3['prototype']['getActiveTextures']=function(){var _0x289df5=_0xcef097['prototype']['getActiveTextures']['call'](this);return this['_albedoTexture']&&_0x289df5['push'](this['_albedoTexture']),this['_ambientTexture']&&_0x289df5['push'](this['_ambientTexture']),this['_opacityTexture']&&_0x289df5['push'](this['_opacityTexture']),this['_reflectionTexture']&&_0x289df5['push'](this['_reflectionTexture']),this['_emissiveTexture']&&_0x289df5['push'](this['_emissiveTexture']),this['_reflectivityTexture']&&_0x289df5['push'](this['_reflectivityTexture']),this['_metallicTexture']&&_0x289df5['push'](this['_metallicTexture']),this['_metallicReflectanceTexture']&&_0x289df5['push'](this['_metallicReflectanceTexture']),this['_microSurfaceTexture']&&_0x289df5['push'](this['_microSurfaceTexture']),this['_bumpTexture']&&_0x289df5['push'](this['_bumpTexture']),this['_lightmapTexture']&&_0x289df5['push'](this['_lightmapTexture']),this['detailMap']['getActiveTextures'](_0x289df5),this['subSurface']['getActiveTextures'](_0x289df5),this['clearCoat']['getActiveTextures'](_0x289df5),this['sheen']['getActiveTextures'](_0x289df5),this['anisotropy']['getActiveTextures'](_0x289df5),_0x289df5;},_0x507cd3['prototype']['hasTexture']=function(_0x2f55fa){return!!_0xcef097['prototype']['hasTexture']['call'](this,_0x2f55fa)||(this['_albedoTexture']===_0x2f55fa||(this['_ambientTexture']===_0x2f55fa||(this['_opacityTexture']===_0x2f55fa||(this['_reflectionTexture']===_0x2f55fa||(this['_reflectivityTexture']===_0x2f55fa||(this['_metallicTexture']===_0x2f55fa||(this['_metallicReflectanceTexture']===_0x2f55fa||(this['_microSurfaceTexture']===_0x2f55fa||(this['_bumpTexture']===_0x2f55fa||(this['_lightmapTexture']===_0x2f55fa||(this['detailMap']['hasTexture'](_0x2f55fa)||this['subSurface']['hasTexture'](_0x2f55fa)||this['clearCoat']['hasTexture'](_0x2f55fa)||this['sheen']['hasTexture'](_0x2f55fa)||this['anisotropy']['hasTexture'](_0x2f55fa))))))))))));},_0x507cd3['prototype']['setPrePassRenderer']=function(_0x32265c){if(this['subSurface']['isScatteringEnabled']){var _0x55b3fc=this['getScene']()['enableSubSurfaceForPrePass']();return _0x55b3fc&&(_0x55b3fc['enabled']=!0x0),!0x0;}return!0x1;},_0x507cd3['prototype']['dispose']=function(_0x10cd0f,_0x10c2c7){var _0x362495,_0x150dd5,_0x22dbdd,_0x32053f,_0x32b796,_0x251156,_0x4ae0be,_0x246f9d,_0x38734e,_0x3f7530,_0xbe8a07;_0x10c2c7&&(this['_environmentBRDFTexture']&&this['getScene']()['environmentBRDFTexture']!==this['_environmentBRDFTexture']&&this['_environmentBRDFTexture']['dispose'](),null===(_0x362495=this['_albedoTexture'])||void 0x0===_0x362495||_0x362495['dispose'](),null===(_0x150dd5=this['_ambientTexture'])||void 0x0===_0x150dd5||_0x150dd5['dispose'](),null===(_0x22dbdd=this['_opacityTexture'])||void 0x0===_0x22dbdd||_0x22dbdd['dispose'](),null===(_0x32053f=this['_reflectionTexture'])||void 0x0===_0x32053f||_0x32053f['dispose'](),null===(_0x32b796=this['_emissiveTexture'])||void 0x0===_0x32b796||_0x32b796['dispose'](),null===(_0x251156=this['_metallicTexture'])||void 0x0===_0x251156||_0x251156['dispose'](),null===(_0x4ae0be=this['_reflectivityTexture'])||void 0x0===_0x4ae0be||_0x4ae0be['dispose'](),null===(_0x246f9d=this['_bumpTexture'])||void 0x0===_0x246f9d||_0x246f9d['dispose'](),null===(_0x38734e=this['_lightmapTexture'])||void 0x0===_0x38734e||_0x38734e['dispose'](),null===(_0x3f7530=this['_metallicReflectanceTexture'])||void 0x0===_0x3f7530||_0x3f7530['dispose'](),null===(_0xbe8a07=this['_microSurfaceTexture'])||void 0x0===_0xbe8a07||_0xbe8a07['dispose']()),this['detailMap']['dispose'](_0x10c2c7),this['subSurface']['dispose'](_0x10c2c7),this['clearCoat']['dispose'](_0x10c2c7),this['sheen']['dispose'](_0x10c2c7),this['anisotropy']['dispose'](_0x10c2c7),this['_renderTargets']['dispose'](),this['_imageProcessingConfiguration']&&this['_imageProcessingObserver']&&this['_imageProcessingConfiguration']['onUpdateParameters']['remove'](this['_imageProcessingObserver']),_0xcef097['prototype']['dispose']['call'](this,_0x10cd0f,_0x10c2c7);},_0x507cd3['PBRMATERIAL_OPAQUE']=_0x33c2e5['a']['MATERIAL_OPAQUE'],_0x507cd3['PBRMATERIAL_ALPHATEST']=_0x33c2e5['a']['MATERIAL_ALPHATEST'],_0x507cd3['PBRMATERIAL_ALPHABLEND']=_0x33c2e5['a']['MATERIAL_ALPHABLEND'],_0x507cd3['PBRMATERIAL_ALPHATESTANDBLEND']=_0x33c2e5['a']['MATERIAL_ALPHATESTANDBLEND'],_0x507cd3['DEFAULT_AO_ON_ANALYTICAL_LIGHTS']=0x0,_0x507cd3['LIGHTFALLOFF_PHYSICAL']=0x0,_0x507cd3['LIGHTFALLOFF_GLTF']=0x1,_0x507cd3['LIGHTFALLOFF_STANDARD']=0x2,Object(_0x18e13d['c'])([Object(_0x495d06['i'])()],_0x507cd3['prototype'],'_imageProcessingConfiguration',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['b'])('_markAllSubMeshesAsMiscDirty')],_0x507cd3['prototype'],'debugMode',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x507cd3['prototype'],'useLogarithmicDepth',null),_0x507cd3;}(_0x1bb048['a']),_0x4cd87a=function(_0x400096){function _0x21117c(_0x390ed2,_0x2fffdc){var _0x1df9f4=_0x400096['call'](this,_0x390ed2,_0x2fffdc)||this;return _0x1df9f4['directIntensity']=0x1,_0x1df9f4['emissiveIntensity']=0x1,_0x1df9f4['environmentIntensity']=0x1,_0x1df9f4['specularIntensity']=0x1,_0x1df9f4['disableBumpMap']=!0x1,_0x1df9f4['ambientTextureStrength']=0x1,_0x1df9f4['ambientTextureImpactOnAnalyticalLights']=_0x21117c['DEFAULT_AO_ON_ANALYTICAL_LIGHTS'],_0x1df9f4['metallicF0Factor']=0x1,_0x1df9f4['metallicReflectanceColor']=_0x39310d['a']['White'](),_0x1df9f4['ambientColor']=new _0x39310d['a'](0x0,0x0,0x0),_0x1df9f4['albedoColor']=new _0x39310d['a'](0x1,0x1,0x1),_0x1df9f4['reflectivityColor']=new _0x39310d['a'](0x1,0x1,0x1),_0x1df9f4['reflectionColor']=new _0x39310d['a'](0x1,0x1,0x1),_0x1df9f4['emissiveColor']=new _0x39310d['a'](0x0,0x0,0x0),_0x1df9f4['microSurface']=0x1,_0x1df9f4['useLightmapAsShadowmap']=!0x1,_0x1df9f4['useAlphaFromAlbedoTexture']=!0x1,_0x1df9f4['forceAlphaTest']=!0x1,_0x1df9f4['alphaCutOff']=0.4,_0x1df9f4['useSpecularOverAlpha']=!0x0,_0x1df9f4['useMicroSurfaceFromReflectivityMapAlpha']=!0x1,_0x1df9f4['useRoughnessFromMetallicTextureAlpha']=!0x0,_0x1df9f4['useRoughnessFromMetallicTextureGreen']=!0x1,_0x1df9f4['useMetallnessFromMetallicTextureBlue']=!0x1,_0x1df9f4['useAmbientOcclusionFromMetallicTextureRed']=!0x1,_0x1df9f4['useAmbientInGrayScale']=!0x1,_0x1df9f4['useAutoMicroSurfaceFromReflectivityMap']=!0x1,_0x1df9f4['useRadianceOverAlpha']=!0x0,_0x1df9f4['useObjectSpaceNormalMap']=!0x1,_0x1df9f4['useParallax']=!0x1,_0x1df9f4['useParallaxOcclusion']=!0x1,_0x1df9f4['parallaxScaleBias']=0.05,_0x1df9f4['disableLighting']=!0x1,_0x1df9f4['forceIrradianceInFragment']=!0x1,_0x1df9f4['maxSimultaneousLights']=0x4,_0x1df9f4['invertNormalMapX']=!0x1,_0x1df9f4['invertNormalMapY']=!0x1,_0x1df9f4['twoSidedLighting']=!0x1,_0x1df9f4['useAlphaFresnel']=!0x1,_0x1df9f4['useLinearAlphaFresnel']=!0x1,_0x1df9f4['environmentBRDFTexture']=null,_0x1df9f4['forceNormalForward']=!0x1,_0x1df9f4['enableSpecularAntiAliasing']=!0x1,_0x1df9f4['useHorizonOcclusion']=!0x0,_0x1df9f4['useRadianceOcclusion']=!0x0,_0x1df9f4['unlit']=!0x1,_0x1df9f4['_environmentBRDFTexture']=_0x4d5377['GetEnvironmentBRDFTexture'](_0x2fffdc),_0x1df9f4;}return Object(_0x18e13d['d'])(_0x21117c,_0x400096),Object['defineProperty'](_0x21117c['prototype'],'refractionTexture',{'get':function(){return this['subSurface']['refractionTexture'];},'set':function(_0x34be33){this['subSurface']['refractionTexture']=_0x34be33,_0x34be33?this['subSurface']['isRefractionEnabled']=!0x0:this['subSurface']['linkRefractionWithTransparency']||(this['subSurface']['isRefractionEnabled']=!0x1);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x21117c['prototype'],'indexOfRefraction',{'get':function(){return this['subSurface']['indexOfRefraction'];},'set':function(_0x2f7987){this['subSurface']['indexOfRefraction']=_0x2f7987;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x21117c['prototype'],'invertRefractionY',{'get':function(){return this['subSurface']['invertRefractionY'];},'set':function(_0x5d7b36){this['subSurface']['invertRefractionY']=_0x5d7b36;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x21117c['prototype'],'linkRefractionWithTransparency',{'get':function(){return this['subSurface']['linkRefractionWithTransparency'];},'set':function(_0x324db0){this['subSurface']['linkRefractionWithTransparency']=_0x324db0,_0x324db0&&(this['subSurface']['isRefractionEnabled']=!0x0);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x21117c['prototype'],'usePhysicalLightFalloff',{'get':function(){return this['_lightFalloff']===_0x136113['LIGHTFALLOFF_PHYSICAL'];},'set':function(_0x1aa667){_0x1aa667!==this['usePhysicalLightFalloff']&&(this['_markAllSubMeshesAsTexturesDirty'](),this['_lightFalloff']=_0x1aa667?_0x136113['LIGHTFALLOFF_PHYSICAL']:_0x136113['LIGHTFALLOFF_STANDARD']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x21117c['prototype'],'useGLTFLightFalloff',{'get':function(){return this['_lightFalloff']===_0x136113['LIGHTFALLOFF_GLTF'];},'set':function(_0x321dd6){_0x321dd6!==this['useGLTFLightFalloff']&&(this['_markAllSubMeshesAsTexturesDirty'](),this['_lightFalloff']=_0x321dd6?_0x136113['LIGHTFALLOFF_GLTF']:_0x136113['LIGHTFALLOFF_STANDARD']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x21117c['prototype'],'imageProcessingConfiguration',{'get':function(){return this['_imageProcessingConfiguration'];},'set':function(_0xe76b8b){this['_attachImageProcessingConfiguration'](_0xe76b8b),this['_markAllSubMeshesAsTexturesDirty']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x21117c['prototype'],'cameraColorCurvesEnabled',{'get':function(){return this['imageProcessingConfiguration']['colorCurvesEnabled'];},'set':function(_0x55ed63){this['imageProcessingConfiguration']['colorCurvesEnabled']=_0x55ed63;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x21117c['prototype'],'cameraColorGradingEnabled',{'get':function(){return this['imageProcessingConfiguration']['colorGradingEnabled'];},'set':function(_0x562dc1){this['imageProcessingConfiguration']['colorGradingEnabled']=_0x562dc1;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x21117c['prototype'],'cameraToneMappingEnabled',{'get':function(){return this['_imageProcessingConfiguration']['toneMappingEnabled'];},'set':function(_0x5daae7){this['_imageProcessingConfiguration']['toneMappingEnabled']=_0x5daae7;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x21117c['prototype'],'cameraExposure',{'get':function(){return this['_imageProcessingConfiguration']['exposure'];},'set':function(_0x284cca){this['_imageProcessingConfiguration']['exposure']=_0x284cca;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x21117c['prototype'],'cameraContrast',{'get':function(){return this['_imageProcessingConfiguration']['contrast'];},'set':function(_0x26734f){this['_imageProcessingConfiguration']['contrast']=_0x26734f;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x21117c['prototype'],'cameraColorGradingTexture',{'get':function(){return this['_imageProcessingConfiguration']['colorGradingTexture'];},'set':function(_0x5a9c7f){this['_imageProcessingConfiguration']['colorGradingTexture']=_0x5a9c7f;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x21117c['prototype'],'cameraColorCurves',{'get':function(){return this['_imageProcessingConfiguration']['colorCurves'];},'set':function(_0x3d644c){this['_imageProcessingConfiguration']['colorCurves']=_0x3d644c;},'enumerable':!0x1,'configurable':!0x0}),_0x21117c['prototype']['getClassName']=function(){return'PBRMaterial';},_0x21117c['prototype']['clone']=function(_0x4a6eb0){var _0x414362=this,_0x5579e2=_0x495d06['a']['Clone'](function(){return new _0x21117c(_0x4a6eb0,_0x414362['getScene']());},this);return _0x5579e2['id']=_0x4a6eb0,_0x5579e2['name']=_0x4a6eb0,this['clearCoat']['copyTo'](_0x5579e2['clearCoat']),this['anisotropy']['copyTo'](_0x5579e2['anisotropy']),this['brdf']['copyTo'](_0x5579e2['brdf']),this['sheen']['copyTo'](_0x5579e2['sheen']),this['subSurface']['copyTo'](_0x5579e2['subSurface']),_0x5579e2;},_0x21117c['prototype']['serialize']=function(){var _0x1e5201=_0x495d06['a']['Serialize'](this);return _0x1e5201['customType']='BABYLON.PBRMaterial',_0x1e5201['clearCoat']=this['clearCoat']['serialize'](),_0x1e5201['anisotropy']=this['anisotropy']['serialize'](),_0x1e5201['brdf']=this['brdf']['serialize'](),_0x1e5201['sheen']=this['sheen']['serialize'](),_0x1e5201['subSurface']=this['subSurface']['serialize'](),_0x1e5201;},_0x21117c['Parse']=function(_0x2ccbab,_0x48f29d,_0x24acbd){var _0x67f6e2=_0x495d06['a']['Parse'](function(){return new _0x21117c(_0x2ccbab['name'],_0x48f29d);},_0x2ccbab,_0x48f29d,_0x24acbd);return _0x2ccbab['clearCoat']&&_0x67f6e2['clearCoat']['parse'](_0x2ccbab['clearCoat'],_0x48f29d,_0x24acbd),_0x2ccbab['anisotropy']&&_0x67f6e2['anisotropy']['parse'](_0x2ccbab['anisotropy'],_0x48f29d,_0x24acbd),_0x2ccbab['brdf']&&_0x67f6e2['brdf']['parse'](_0x2ccbab['brdf'],_0x48f29d,_0x24acbd),_0x2ccbab['sheen']&&_0x67f6e2['sheen']['parse'](_0x2ccbab['sheen'],_0x48f29d,_0x24acbd),_0x2ccbab['subSurface']&&_0x67f6e2['subSurface']['parse'](_0x2ccbab['subSurface'],_0x48f29d,_0x24acbd),_0x67f6e2;},_0x21117c['PBRMATERIAL_OPAQUE']=_0x136113['PBRMATERIAL_OPAQUE'],_0x21117c['PBRMATERIAL_ALPHATEST']=_0x136113['PBRMATERIAL_ALPHATEST'],_0x21117c['PBRMATERIAL_ALPHABLEND']=_0x136113['PBRMATERIAL_ALPHABLEND'],_0x21117c['PBRMATERIAL_ALPHATESTANDBLEND']=_0x136113['PBRMATERIAL_ALPHATESTANDBLEND'],_0x21117c['DEFAULT_AO_ON_ANALYTICAL_LIGHTS']=_0x136113['DEFAULT_AO_ON_ANALYTICAL_LIGHTS'],Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'directIntensity',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'emissiveIntensity',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'environmentIntensity',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'specularIntensity',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'disableBumpMap',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'albedoTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'ambientTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'ambientTextureStrength',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'ambientTextureImpactOnAnalyticalLights',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesAndMiscDirty')],_0x21117c['prototype'],'opacityTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'reflectionTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'emissiveTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'reflectivityTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'metallicTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'metallic',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'roughness',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'metallicF0Factor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['e'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'metallicReflectanceColor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'metallicReflectanceTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'microSurfaceTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'bumpTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty',null)],_0x21117c['prototype'],'lightmapTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['e'])('ambient'),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'ambientColor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['e'])('albedo'),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'albedoColor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['e'])('reflectivity'),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'reflectivityColor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['e'])('reflection'),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'reflectionColor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['e'])('emissive'),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'emissiveColor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'microSurface',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'useLightmapAsShadowmap',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesAndMiscDirty')],_0x21117c['prototype'],'useAlphaFromAlbedoTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesAndMiscDirty')],_0x21117c['prototype'],'forceAlphaTest',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesAndMiscDirty')],_0x21117c['prototype'],'alphaCutOff',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'useSpecularOverAlpha',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'useMicroSurfaceFromReflectivityMapAlpha',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'useRoughnessFromMetallicTextureAlpha',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'useRoughnessFromMetallicTextureGreen',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'useMetallnessFromMetallicTextureBlue',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'useAmbientOcclusionFromMetallicTextureRed',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'useAmbientInGrayScale',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'useAutoMicroSurfaceFromReflectivityMap',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x21117c['prototype'],'usePhysicalLightFalloff',null),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x21117c['prototype'],'useGLTFLightFalloff',null),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'useRadianceOverAlpha',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'useObjectSpaceNormalMap',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'useParallax',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'useParallaxOcclusion',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'parallaxScaleBias',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsLightsDirty')],_0x21117c['prototype'],'disableLighting',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'forceIrradianceInFragment',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsLightsDirty')],_0x21117c['prototype'],'maxSimultaneousLights',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'invertNormalMapX',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'invertNormalMapY',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'twoSidedLighting',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'useAlphaFresnel',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'useLinearAlphaFresnel',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'environmentBRDFTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'forceNormalForward',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'enableSpecularAntiAliasing',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'useHorizonOcclusion',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x21117c['prototype'],'useRadianceOcclusion',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsMiscDirty')],_0x21117c['prototype'],'unlit',void 0x0),_0x21117c;}(_0x136113);_0x3cd573['a']['RegisteredTypes']['BABYLON.PBRMaterial']=_0x4cd87a;function _0x656463(_0x507083){return _0x507083['charCodeAt'](0x0)+(_0x507083['charCodeAt'](0x1)<<0x8)+(_0x507083['charCodeAt'](0x2)<<0x10)+(_0x507083['charCodeAt'](0x3)<<0x18);}var _0x20163b=_0x656463('DXT1'),_0x17d80b=_0x656463('DXT3'),_0x3fd2f4=_0x656463('DXT5'),_0x56d4df=_0x656463('DX10'),_0x568c36=(function(){function _0x2b0837(){}return _0x2b0837['GetDDSInfo']=function(_0xaa572d){var _0x5ba06c=new Int32Array(_0xaa572d['buffer'],_0xaa572d['byteOffset'],0x1f),_0x1029e0=new Int32Array(_0xaa572d['buffer'],_0xaa572d['byteOffset'],0x23),_0xee38e6=0x1;0x20000&_0x5ba06c[0x2]&&(_0xee38e6=Math['max'](0x1,_0x5ba06c[0x7]));var _0x4e67a1=_0x5ba06c[0x15],_0x396b2c=_0x4e67a1===_0x56d4df?_0x1029e0[0x20]:0x0,_0x4ea3cb=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'];switch(_0x4e67a1){case 0x71:_0x4ea3cb=_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT'];break;case 0x74:_0x4ea3cb=_0x2103ba['a']['TEXTURETYPE_FLOAT'];break;case _0x56d4df:if(0xa===_0x396b2c){_0x4ea3cb=_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT'];break;}if(0x2===_0x396b2c){_0x4ea3cb=_0x2103ba['a']['TEXTURETYPE_FLOAT'];break;}}return{'width':_0x5ba06c[0x4],'height':_0x5ba06c[0x3],'mipmapCount':_0xee38e6,'isFourCC':0x4==(0x4&_0x5ba06c[0x14]),'isRGB':0x40==(0x40&_0x5ba06c[0x14]),'isLuminance':0x20000==(0x20000&_0x5ba06c[0x14]),'isCube':0x200==(0x200&_0x5ba06c[0x1c]),'isCompressed':_0x4e67a1===_0x20163b||_0x4e67a1===_0x17d80b||_0x4e67a1===_0x3fd2f4,'dxgiFormat':_0x396b2c,'textureType':_0x4ea3cb};},_0x2b0837['_ToHalfFloat']=function(_0x10dc0a){_0x2b0837['_FloatView']||(_0x2b0837['_FloatView']=new Float32Array(0x1),_0x2b0837['_Int32View']=new Int32Array(_0x2b0837['_FloatView']['buffer'])),_0x2b0837['_FloatView'][0x0]=_0x10dc0a;var _0x225c6b=_0x2b0837['_Int32View'][0x0],_0x522ae6=_0x225c6b>>0x10&0x8000,_0x3d40b1=_0x225c6b>>0xc&0x7ff,_0x5563c6=_0x225c6b>>0x17&0xff;return _0x5563c6<0x67?_0x522ae6:_0x5563c6>0x8e?(_0x522ae6|=0x7c00,_0x522ae6|=(0xff==_0x5563c6?0x0:0x1)&&0x7fffff&_0x225c6b):_0x5563c6<0x71?_0x522ae6|=((_0x3d40b1|=0x800)>>0x72-_0x5563c6)+(_0x3d40b1>>0x71-_0x5563c6&0x1):(_0x522ae6|=_0x5563c6-0x70<<0xa|_0x3d40b1>>0x1,_0x522ae6+=0x1&_0x3d40b1);},_0x2b0837['_FromHalfFloat']=function(_0x24085b){var _0x293786=(0x8000&_0x24085b)>>0xf,_0x49c705=(0x7c00&_0x24085b)>>0xa,_0x30524d=0x3ff&_0x24085b;return 0x0===_0x49c705?(_0x293786?-0x1:0x1)*Math['pow'](0x2,-0xe)*(_0x30524d/Math['pow'](0x2,0xa)):0x1f==_0x49c705?_0x30524d?NaN:0x1/0x0*(_0x293786?-0x1:0x1):(_0x293786?-0x1:0x1)*Math['pow'](0x2,_0x49c705-0xf)*(0x1+_0x30524d/Math['pow'](0x2,0xa));},_0x2b0837['_GetHalfFloatAsFloatRGBAArrayBuffer']=function(_0xb0dc28,_0x1ca824,_0x1e2f2b,_0x318765,_0x46e74c,_0x515643){for(var _0x51b868=new Float32Array(_0x318765),_0x3b33a1=new Uint16Array(_0x46e74c,_0x1e2f2b),_0x53e7e2=0x0,_0x4f1cc1=0x0;_0x4f1cc1<_0x1ca824;_0x4f1cc1++)for(var _0x5bd1fb=0x0;_0x5bd1fb<_0xb0dc28;_0x5bd1fb++){var _0xe8b7c3=0x4*(_0x5bd1fb+_0x4f1cc1*_0xb0dc28);_0x51b868[_0x53e7e2]=_0x2b0837['_FromHalfFloat'](_0x3b33a1[_0xe8b7c3]),_0x51b868[_0x53e7e2+0x1]=_0x2b0837['_FromHalfFloat'](_0x3b33a1[_0xe8b7c3+0x1]),_0x51b868[_0x53e7e2+0x2]=_0x2b0837['_FromHalfFloat'](_0x3b33a1[_0xe8b7c3+0x2]),_0x2b0837['StoreLODInAlphaChannel']?_0x51b868[_0x53e7e2+0x3]=_0x515643:_0x51b868[_0x53e7e2+0x3]=_0x2b0837['_FromHalfFloat'](_0x3b33a1[_0xe8b7c3+0x3]),_0x53e7e2+=0x4;}return _0x51b868;},_0x2b0837['_GetHalfFloatRGBAArrayBuffer']=function(_0x4aac39,_0x243650,_0x500ad5,_0x1edf0d,_0x1182e8,_0x35b61d){if(_0x2b0837['StoreLODInAlphaChannel']){for(var _0x48b79b=new Uint16Array(_0x1edf0d),_0x43a61a=new Uint16Array(_0x1182e8,_0x500ad5),_0x427f16=0x0,_0x65c9e9=0x0;_0x65c9e9<_0x243650;_0x65c9e9++)for(var _0x56ce99=0x0;_0x56ce99<_0x4aac39;_0x56ce99++){var _0x4bdcd1=0x4*(_0x56ce99+_0x65c9e9*_0x4aac39);_0x48b79b[_0x427f16]=_0x43a61a[_0x4bdcd1],_0x48b79b[_0x427f16+0x1]=_0x43a61a[_0x4bdcd1+0x1],_0x48b79b[_0x427f16+0x2]=_0x43a61a[_0x4bdcd1+0x2],_0x48b79b[_0x427f16+0x3]=_0x2b0837['_ToHalfFloat'](_0x35b61d),_0x427f16+=0x4;}return _0x48b79b;}return new Uint16Array(_0x1182e8,_0x500ad5,_0x1edf0d);},_0x2b0837['_GetFloatRGBAArrayBuffer']=function(_0x4a7ac4,_0x42043b,_0x52b309,_0x5eb51f,_0xd04566,_0x192422){if(_0x2b0837['StoreLODInAlphaChannel']){for(var _0xb59062=new Float32Array(_0x5eb51f),_0x1c2c91=new Float32Array(_0xd04566,_0x52b309),_0x298b31=0x0,_0xc1b4f7=0x0;_0xc1b4f7<_0x42043b;_0xc1b4f7++)for(var _0x2dfb65=0x0;_0x2dfb65<_0x4a7ac4;_0x2dfb65++){var _0x50f999=0x4*(_0x2dfb65+_0xc1b4f7*_0x4a7ac4);_0xb59062[_0x298b31]=_0x1c2c91[_0x50f999],_0xb59062[_0x298b31+0x1]=_0x1c2c91[_0x50f999+0x1],_0xb59062[_0x298b31+0x2]=_0x1c2c91[_0x50f999+0x2],_0xb59062[_0x298b31+0x3]=_0x192422,_0x298b31+=0x4;}return _0xb59062;}return new Float32Array(_0xd04566,_0x52b309,_0x5eb51f);},_0x2b0837['_GetFloatAsUIntRGBAArrayBuffer']=function(_0x3ea870,_0x371c62,_0x313920,_0xb2c0f3,_0x24ec17,_0x3358d8){for(var _0x3bc128=new Uint8Array(_0xb2c0f3),_0x181d3a=new Float32Array(_0x24ec17,_0x313920),_0x4455f0=0x0,_0x47a042=0x0;_0x47a042<_0x371c62;_0x47a042++)for(var _0x354163=0x0;_0x354163<_0x3ea870;_0x354163++){var _0x1294bc=0x4*(_0x354163+_0x47a042*_0x3ea870);_0x3bc128[_0x4455f0]=0xff*_0x4a0cf0['a']['Clamp'](_0x181d3a[_0x1294bc]),_0x3bc128[_0x4455f0+0x1]=0xff*_0x4a0cf0['a']['Clamp'](_0x181d3a[_0x1294bc+0x1]),_0x3bc128[_0x4455f0+0x2]=0xff*_0x4a0cf0['a']['Clamp'](_0x181d3a[_0x1294bc+0x2]),_0x2b0837['StoreLODInAlphaChannel']?_0x3bc128[_0x4455f0+0x3]=_0x3358d8:_0x3bc128[_0x4455f0+0x3]=0xff*_0x4a0cf0['a']['Clamp'](_0x181d3a[_0x1294bc+0x3]),_0x4455f0+=0x4;}return _0x3bc128;},_0x2b0837['_GetHalfFloatAsUIntRGBAArrayBuffer']=function(_0x3f1250,_0x137659,_0x1593b2,_0x5c4e76,_0x9c9edc,_0x493a99){for(var _0x5f5aa5=new Uint8Array(_0x5c4e76),_0x17a8b4=new Uint16Array(_0x9c9edc,_0x1593b2),_0x2bffa9=0x0,_0x1223d6=0x0;_0x1223d6<_0x137659;_0x1223d6++)for(var _0x5e03ee=0x0;_0x5e03ee<_0x3f1250;_0x5e03ee++){var _0x1c0a3c=0x4*(_0x5e03ee+_0x1223d6*_0x3f1250);_0x5f5aa5[_0x2bffa9]=0xff*_0x4a0cf0['a']['Clamp'](_0x2b0837['_FromHalfFloat'](_0x17a8b4[_0x1c0a3c])),_0x5f5aa5[_0x2bffa9+0x1]=0xff*_0x4a0cf0['a']['Clamp'](_0x2b0837['_FromHalfFloat'](_0x17a8b4[_0x1c0a3c+0x1])),_0x5f5aa5[_0x2bffa9+0x2]=0xff*_0x4a0cf0['a']['Clamp'](_0x2b0837['_FromHalfFloat'](_0x17a8b4[_0x1c0a3c+0x2])),_0x2b0837['StoreLODInAlphaChannel']?_0x5f5aa5[_0x2bffa9+0x3]=_0x493a99:_0x5f5aa5[_0x2bffa9+0x3]=0xff*_0x4a0cf0['a']['Clamp'](_0x2b0837['_FromHalfFloat'](_0x17a8b4[_0x1c0a3c+0x3])),_0x2bffa9+=0x4;}return _0x5f5aa5;},_0x2b0837['_GetRGBAArrayBuffer']=function(_0x294105,_0x29791d,_0x47900e,_0x152b2a,_0x4d0bc3,_0x562c94,_0x16a2ff,_0xf7c2f6,_0x3c7ab0){for(var _0x3f2446=new Uint8Array(_0x152b2a),_0x12462d=new Uint8Array(_0x4d0bc3,_0x47900e),_0x505862=0x0,_0x338ef9=0x0;_0x338ef9<_0x29791d;_0x338ef9++)for(var _0x30f56d=0x0;_0x30f56d<_0x294105;_0x30f56d++){var _0x200390=0x4*(_0x30f56d+_0x338ef9*_0x294105);_0x3f2446[_0x505862]=_0x12462d[_0x200390+_0x562c94],_0x3f2446[_0x505862+0x1]=_0x12462d[_0x200390+_0x16a2ff],_0x3f2446[_0x505862+0x2]=_0x12462d[_0x200390+_0xf7c2f6],_0x3f2446[_0x505862+0x3]=_0x12462d[_0x200390+_0x3c7ab0],_0x505862+=0x4;}return _0x3f2446;},_0x2b0837['_ExtractLongWordOrder']=function(_0x3cb2cc){return 0x0===_0x3cb2cc||0xff===_0x3cb2cc||-0x1000000===_0x3cb2cc?0x0:0x1+_0x2b0837['_ExtractLongWordOrder'](_0x3cb2cc>>0x8);},_0x2b0837['_GetRGBArrayBuffer']=function(_0x1c2266,_0x2022b3,_0x210ca1,_0x3564b1,_0x3efb3a,_0x162e90,_0x279d23,_0x4217b7){for(var _0x1e5209=new Uint8Array(_0x3564b1),_0x5e79fb=new Uint8Array(_0x3efb3a,_0x210ca1),_0x356f84=0x0,_0x3ceeac=0x0;_0x3ceeac<_0x2022b3;_0x3ceeac++)for(var _0x1fd7ad=0x0;_0x1fd7ad<_0x1c2266;_0x1fd7ad++){var _0x1b2a45=0x3*(_0x1fd7ad+_0x3ceeac*_0x1c2266);_0x1e5209[_0x356f84]=_0x5e79fb[_0x1b2a45+_0x162e90],_0x1e5209[_0x356f84+0x1]=_0x5e79fb[_0x1b2a45+_0x279d23],_0x1e5209[_0x356f84+0x2]=_0x5e79fb[_0x1b2a45+_0x4217b7],_0x356f84+=0x3;}return _0x1e5209;},_0x2b0837['_GetLuminanceArrayBuffer']=function(_0x4778fa,_0x809e3,_0x242c86,_0x49ad6a,_0x1ef6d6){for(var _0x5086a5=new Uint8Array(_0x49ad6a),_0x1ec9e5=new Uint8Array(_0x1ef6d6,_0x242c86),_0x320b12=0x0,_0xc8469a=0x0;_0xc8469a<_0x809e3;_0xc8469a++)for(var _0x5cdfcf=0x0;_0x5cdfcf<_0x4778fa;_0x5cdfcf++){var _0x424ea7=_0x5cdfcf+_0xc8469a*_0x4778fa;_0x5086a5[_0x320b12]=_0x1ec9e5[_0x424ea7],_0x320b12++;}return _0x5086a5;},_0x2b0837['UploadDDSLevels']=function(_0x1dae49,_0x297b86,_0x4489b9,_0x89caa3,_0xac296a,_0xc45fde,_0x3bff07,_0x385be7){void 0x0===_0x3bff07&&(_0x3bff07=-0x1);var _0x19e242=null;_0x89caa3['sphericalPolynomial']&&(_0x19e242=new Array());var _0x1e8142,_0x12856d,_0x5a6f12,_0x48af6a,_0x433c2e,_0xfa9c54,_0x11ed3a,_0x14b980=_0x1dae49['getCaps']()['s3tc'],_0x53a348=new Int32Array(_0x4489b9['buffer'],_0x4489b9['byteOffset'],0x1f),_0x19e569=0x0,_0x449338=0x0,_0x4a3680=0x1;if(0x20534444===_0x53a348[0x0]){if(_0x89caa3['isFourCC']||_0x89caa3['isRGB']||_0x89caa3['isLuminance']){if(!_0x89caa3['isCompressed']||_0x14b980){var _0x182ac9=_0x53a348[0x16];_0x48af6a=_0x53a348[0x1]+0x4;var _0x5b76b1,_0x10f726=!0x1;if(_0x89caa3['isFourCC'])switch(_0x1e8142=_0x53a348[0x15]){case _0x20163b:_0x4a3680=0x8,_0x449338=_0x14b980['COMPRESSED_RGBA_S3TC_DXT1_EXT'];break;case _0x17d80b:_0x4a3680=0x10,_0x449338=_0x14b980['COMPRESSED_RGBA_S3TC_DXT3_EXT'];break;case _0x3fd2f4:_0x4a3680=0x10,_0x449338=_0x14b980['COMPRESSED_RGBA_S3TC_DXT5_EXT'];break;case 0x71:case 0x74:_0x10f726=!0x0;break;case _0x56d4df:_0x48af6a+=0x14;var _0x10adbb=!0x1;switch(_0x89caa3['dxgiFormat']){case 0xa:case 0x2:_0x10f726=!0x0,_0x10adbb=!0x0;break;case 0x58:_0x89caa3['isRGB']=!0x0,_0x89caa3['isFourCC']=!0x1,_0x182ac9=0x20,_0x10adbb=!0x0;}if(_0x10adbb)break;default:return void console['error']('Unsupported\x20FourCC\x20code:',(_0x5b76b1=_0x1e8142,String['fromCharCode'](0xff&_0x5b76b1,_0x5b76b1>>0x8&0xff,_0x5b76b1>>0x10&0xff,_0x5b76b1>>0x18&0xff)));}var _0x5665e3=_0x2b0837['_ExtractLongWordOrder'](_0x53a348[0x17]),_0x2bfe61=_0x2b0837['_ExtractLongWordOrder'](_0x53a348[0x18]),_0x3ec871=_0x2b0837['_ExtractLongWordOrder'](_0x53a348[0x19]),_0x1e61f6=_0x2b0837['_ExtractLongWordOrder'](_0x53a348[0x1a]);_0x10f726&&(_0x449338=_0x1dae49['_getRGBABufferInternalSizedFormat'](_0x89caa3['textureType'])),_0xfa9c54=0x1,0x20000&_0x53a348[0x2]&&!0x1!==_0xac296a&&(_0xfa9c54=Math['max'](0x1,_0x53a348[0x7]));for(var _0x246e8b=_0x385be7||0x0;_0x246e8b<_0xc45fde;_0x246e8b++){for(_0x12856d=_0x53a348[0x4],_0x5a6f12=_0x53a348[0x3],_0x11ed3a=0x0;_0x11ed3a<_0xfa9c54;++_0x11ed3a){if(-0x1===_0x3bff07||_0x3bff07===_0x11ed3a){var _0x53aae9=-0x1===_0x3bff07?_0x11ed3a:0x0;if(!_0x89caa3['isCompressed']&&_0x89caa3['isFourCC']){_0x297b86['format']=_0x2103ba['a']['TEXTUREFORMAT_RGBA'],_0x19e569=_0x12856d*_0x5a6f12*0x4;var _0x59d503=null;_0x1dae49['_badOS']||_0x1dae49['_badDesktopOS']||!_0x1dae49['getCaps']()['textureHalfFloat']&&!_0x1dae49['getCaps']()['textureFloat']?(0x80===_0x182ac9?(_0x59d503=_0x2b0837['_GetFloatAsUIntRGBAArrayBuffer'](_0x12856d,_0x5a6f12,_0x4489b9['byteOffset']+_0x48af6a,_0x19e569,_0x4489b9['buffer'],_0x53aae9),_0x19e242&&0x0==_0x53aae9&&_0x19e242['push'](_0x2b0837['_GetFloatRGBAArrayBuffer'](_0x12856d,_0x5a6f12,_0x4489b9['byteOffset']+_0x48af6a,_0x19e569,_0x4489b9['buffer'],_0x53aae9))):0x40===_0x182ac9&&(_0x59d503=_0x2b0837['_GetHalfFloatAsUIntRGBAArrayBuffer'](_0x12856d,_0x5a6f12,_0x4489b9['byteOffset']+_0x48af6a,_0x19e569,_0x4489b9['buffer'],_0x53aae9),_0x19e242&&0x0==_0x53aae9&&_0x19e242['push'](_0x2b0837['_GetHalfFloatAsFloatRGBAArrayBuffer'](_0x12856d,_0x5a6f12,_0x4489b9['byteOffset']+_0x48af6a,_0x19e569,_0x4489b9['buffer'],_0x53aae9))),_0x297b86['type']=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']):0x80===_0x182ac9?(_0x297b86['type']=_0x2103ba['a']['TEXTURETYPE_FLOAT'],_0x59d503=_0x2b0837['_GetFloatRGBAArrayBuffer'](_0x12856d,_0x5a6f12,_0x4489b9['byteOffset']+_0x48af6a,_0x19e569,_0x4489b9['buffer'],_0x53aae9),_0x19e242&&0x0==_0x53aae9&&_0x19e242['push'](_0x59d503)):0x40!==_0x182ac9||_0x1dae49['getCaps']()['textureHalfFloat']?(_0x297b86['type']=_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT'],_0x59d503=_0x2b0837['_GetHalfFloatRGBAArrayBuffer'](_0x12856d,_0x5a6f12,_0x4489b9['byteOffset']+_0x48af6a,_0x19e569,_0x4489b9['buffer'],_0x53aae9),_0x19e242&&0x0==_0x53aae9&&_0x19e242['push'](_0x2b0837['_GetHalfFloatAsFloatRGBAArrayBuffer'](_0x12856d,_0x5a6f12,_0x48af6a,_0x19e569,_0x4489b9['buffer'],_0x53aae9))):(_0x297b86['type']=_0x2103ba['a']['TEXTURETYPE_FLOAT'],_0x59d503=_0x2b0837['_GetHalfFloatAsFloatRGBAArrayBuffer'](_0x12856d,_0x5a6f12,_0x4489b9['byteOffset']+_0x48af6a,_0x19e569,_0x4489b9['buffer'],_0x53aae9),_0x19e242&&0x0==_0x53aae9&&_0x19e242['push'](_0x59d503)),_0x59d503&&_0x1dae49['_uploadDataToTextureDirectly'](_0x297b86,_0x59d503,_0x246e8b,_0x53aae9);}else{if(_0x89caa3['isRGB'])_0x297b86['type']=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'],0x18===_0x182ac9?(_0x297b86['format']=_0x2103ba['a']['TEXTUREFORMAT_RGB'],_0x19e569=_0x12856d*_0x5a6f12*0x3,_0x433c2e=_0x2b0837['_GetRGBArrayBuffer'](_0x12856d,_0x5a6f12,_0x4489b9['byteOffset']+_0x48af6a,_0x19e569,_0x4489b9['buffer'],_0x5665e3,_0x2bfe61,_0x3ec871),_0x1dae49['_uploadDataToTextureDirectly'](_0x297b86,_0x433c2e,_0x246e8b,_0x53aae9)):(_0x297b86['format']=_0x2103ba['a']['TEXTUREFORMAT_RGBA'],_0x19e569=_0x12856d*_0x5a6f12*0x4,_0x433c2e=_0x2b0837['_GetRGBAArrayBuffer'](_0x12856d,_0x5a6f12,_0x4489b9['byteOffset']+_0x48af6a,_0x19e569,_0x4489b9['buffer'],_0x5665e3,_0x2bfe61,_0x3ec871,_0x1e61f6),_0x1dae49['_uploadDataToTextureDirectly'](_0x297b86,_0x433c2e,_0x246e8b,_0x53aae9));else{if(_0x89caa3['isLuminance']){var _0x2560d3=_0x1dae49['_getUnpackAlignement'](),_0x2ef77c=_0x12856d;_0x19e569=Math['floor']((_0x12856d+_0x2560d3-0x1)/_0x2560d3)*_0x2560d3*(_0x5a6f12-0x1)+_0x2ef77c,_0x433c2e=_0x2b0837['_GetLuminanceArrayBuffer'](_0x12856d,_0x5a6f12,_0x4489b9['byteOffset']+_0x48af6a,_0x19e569,_0x4489b9['buffer']),_0x297b86['format']=_0x2103ba['a']['TEXTUREFORMAT_LUMINANCE'],_0x297b86['type']=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'],_0x1dae49['_uploadDataToTextureDirectly'](_0x297b86,_0x433c2e,_0x246e8b,_0x53aae9);}else _0x19e569=Math['max'](0x4,_0x12856d)/0x4*Math['max'](0x4,_0x5a6f12)/0x4*_0x4a3680,_0x433c2e=new Uint8Array(_0x4489b9['buffer'],_0x4489b9['byteOffset']+_0x48af6a,_0x19e569),_0x297b86['type']=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'],_0x1dae49['_uploadCompressedDataToTextureDirectly'](_0x297b86,_0x449338,_0x12856d,_0x5a6f12,_0x433c2e,_0x246e8b,_0x53aae9);}}}_0x48af6a+=_0x182ac9?_0x12856d*_0x5a6f12*(_0x182ac9/0x8):_0x19e569,_0x12856d*=0.5,_0x5a6f12*=0.5,_0x12856d=Math['max'](0x1,_0x12856d),_0x5a6f12=Math['max'](0x1,_0x5a6f12);}if(void 0x0!==_0x385be7)break;}_0x19e242&&_0x19e242['length']>0x0?_0x89caa3['sphericalPolynomial']=_0x3fdf9a['ConvertCubeMapToSphericalPolynomial']({'size':_0x53a348[0x4],'right':_0x19e242[0x0],'left':_0x19e242[0x1],'up':_0x19e242[0x2],'down':_0x19e242[0x3],'front':_0x19e242[0x4],'back':_0x19e242[0x5],'format':_0x2103ba['a']['TEXTUREFORMAT_RGBA'],'type':_0x2103ba['a']['TEXTURETYPE_FLOAT'],'gammaSpace':!0x1}):_0x89caa3['sphericalPolynomial']=void 0x0;}else _0x75193d['a']['Error']('Compressed\x20textures\x20are\x20not\x20supported\x20on\x20this\x20platform.');}else _0x75193d['a']['Error']('Unsupported\x20format,\x20must\x20contain\x20a\x20FourCC,\x20RGB\x20or\x20LUMINANCE\x20code');}else _0x75193d['a']['Error']('Invalid\x20magic\x20number\x20in\x20DDS\x20header');},_0x2b0837['StoreLODInAlphaChannel']=!0x1,_0x2b0837;}());_0x26966b['a']['prototype']['createPrefilteredCubeTexture']=function(_0x57def4,_0x1d5d08,_0x2ad89b,_0x19d993,_0x5ea12f,_0x4cf569,_0x17a5c0,_0x338c53,_0x48eb4f){var _0x28bfc8=this;return void 0x0===_0x5ea12f&&(_0x5ea12f=null),void 0x0===_0x4cf569&&(_0x4cf569=null),void 0x0===_0x338c53&&(_0x338c53=null),void 0x0===_0x48eb4f&&(_0x48eb4f=!0x0),this['createCubeTexture'](_0x57def4,_0x1d5d08,null,!0x1,function(_0x168f71){if(_0x168f71){var _0x48edb4=_0x168f71['texture'];if(_0x48eb4f?_0x168f71['info']['sphericalPolynomial']&&(_0x48edb4['_sphericalPolynomial']=_0x168f71['info']['sphericalPolynomial']):_0x48edb4['_sphericalPolynomial']=new _0x23d472(),_0x48edb4['_source']=_0x21ea74['b']['CubePrefiltered'],_0x28bfc8['getCaps']()['textureLOD'])_0x5ea12f&&_0x5ea12f(_0x48edb4);else{var _0x37aebe=_0x28bfc8['_gl'],_0x1035b1=_0x168f71['width'];if(_0x1035b1){for(var _0x4e381c=[],_0x408a48=0x0;_0x408a48<0x3;_0x408a48++){var _0x12d1df=0x1-_0x408a48/0x2,_0x506198=_0x19d993,_0x4c28a3=_0x4a0cf0['a']['Log2'](_0x1035b1)*_0x2ad89b+_0x19d993,_0x143dd9=_0x506198+(_0x4c28a3-_0x506198)*_0x12d1df,_0x4c7a5e=Math['round'](Math['min'](Math['max'](_0x143dd9,0x0),_0x4c28a3)),_0x27d671=new _0x21ea74['a'](_0x28bfc8,_0x21ea74['b']['Temp']);if(_0x27d671['type']=_0x48edb4['type'],_0x27d671['format']=_0x48edb4['format'],_0x27d671['width']=Math['pow'](0x2,Math['max'](_0x4a0cf0['a']['Log2'](_0x1035b1)-_0x4c7a5e,0x0)),_0x27d671['height']=_0x27d671['width'],_0x27d671['isCube']=!0x0,_0x28bfc8['_bindTextureDirectly'](_0x37aebe['TEXTURE_CUBE_MAP'],_0x27d671,!0x0),_0x27d671['samplingMode']=_0x2103ba['a']['TEXTURE_LINEAR_LINEAR'],_0x37aebe['texParameteri'](_0x37aebe['TEXTURE_CUBE_MAP'],_0x37aebe['TEXTURE_MAG_FILTER'],_0x37aebe['LINEAR']),_0x37aebe['texParameteri'](_0x37aebe['TEXTURE_CUBE_MAP'],_0x37aebe['TEXTURE_MIN_FILTER'],_0x37aebe['LINEAR']),_0x37aebe['texParameteri'](_0x37aebe['TEXTURE_CUBE_MAP'],_0x37aebe['TEXTURE_WRAP_S'],_0x37aebe['CLAMP_TO_EDGE']),_0x37aebe['texParameteri'](_0x37aebe['TEXTURE_CUBE_MAP'],_0x37aebe['TEXTURE_WRAP_T'],_0x37aebe['CLAMP_TO_EDGE']),_0x168f71['isDDS']){var _0x5ed78c=_0x168f71['info'],_0x46d3b8=_0x168f71['data'];_0x28bfc8['_unpackFlipY'](_0x5ed78c['isCompressed']),_0x568c36['UploadDDSLevels'](_0x28bfc8,_0x27d671,_0x46d3b8,_0x5ed78c,!0x0,0x6,_0x4c7a5e);}else _0x75193d['a']['Warn']('DDS\x20is\x20the\x20only\x20prefiltered\x20cube\x20map\x20supported\x20so\x20far.');_0x28bfc8['_bindTextureDirectly'](_0x37aebe['TEXTURE_CUBE_MAP'],null);var _0x45b440=new _0x2268ea['a'](_0x1d5d08);_0x45b440['isCube']=!0x0,_0x45b440['_texture']=_0x27d671,_0x27d671['isReady']=!0x0,_0x4e381c['push'](_0x45b440);}_0x48edb4['_lodTextureHigh']=_0x4e381c[0x2],_0x48edb4['_lodTextureMid']=_0x4e381c[0x1],_0x48edb4['_lodTextureLow']=_0x4e381c[0x0],_0x5ea12f&&_0x5ea12f(_0x48edb4);}}}else _0x5ea12f&&_0x5ea12f(null);},_0x4cf569,_0x17a5c0,_0x338c53,_0x48eb4f,_0x2ad89b,_0x19d993);};var _0x5ca044=(function(){function _0x12a95c(){this['supportCascades']=!0x0;}return _0x12a95c['prototype']['canLoad']=function(_0x58e5a7){return _0x5950ed['a']['EndsWith'](_0x58e5a7,'.dds');},_0x12a95c['prototype']['loadCubeData']=function(_0x2d4888,_0x3802ed,_0x3a95df,_0x3a7b2a,_0x5f577a){var _0x4858ef,_0x4afc45=_0x3802ed['getEngine'](),_0x4e7c67=!0x1;if(Array['isArray'](_0x2d4888))for(var _0x438d8e=0x0;_0x438d8e<_0x2d4888['length'];_0x438d8e++){var _0x435f2d=_0x2d4888[_0x438d8e];_0x4858ef=_0x568c36['GetDDSInfo'](_0x435f2d),_0x3802ed['width']=_0x4858ef['width'],_0x3802ed['height']=_0x4858ef['height'],_0x4e7c67=(_0x4858ef['isRGB']||_0x4858ef['isLuminance']||_0x4858ef['mipmapCount']>0x1)&&_0x3802ed['generateMipMaps'],_0x4afc45['_unpackFlipY'](_0x4858ef['isCompressed']),_0x568c36['UploadDDSLevels'](_0x4afc45,_0x3802ed,_0x435f2d,_0x4858ef,_0x4e7c67,0x6,-0x1,_0x438d8e),_0x4858ef['isFourCC']||0x1!==_0x4858ef['mipmapCount']||_0x4afc45['generateMipMapsForCubemap'](_0x3802ed);}else{var _0x523280=_0x2d4888;_0x4858ef=_0x568c36['GetDDSInfo'](_0x523280),_0x3802ed['width']=_0x4858ef['width'],_0x3802ed['height']=_0x4858ef['height'],_0x3a95df&&(_0x4858ef['sphericalPolynomial']=new _0x23d472()),_0x4e7c67=(_0x4858ef['isRGB']||_0x4858ef['isLuminance']||_0x4858ef['mipmapCount']>0x1)&&_0x3802ed['generateMipMaps'],_0x4afc45['_unpackFlipY'](_0x4858ef['isCompressed']),_0x568c36['UploadDDSLevels'](_0x4afc45,_0x3802ed,_0x523280,_0x4858ef,_0x4e7c67,0x6),_0x4858ef['isFourCC']||0x1!==_0x4858ef['mipmapCount']||_0x4afc45['generateMipMapsForCubemap'](_0x3802ed,!0x1);}_0x4afc45['_setCubeMapTextureParams'](_0x3802ed,_0x4e7c67),_0x3802ed['isReady']=!0x0,_0x3802ed['onLoadedObservable']['notifyObservers'](_0x3802ed),_0x3802ed['onLoadedObservable']['clear'](),_0x3a7b2a&&_0x3a7b2a({'isDDS':!0x0,'width':_0x3802ed['width'],'info':_0x4858ef,'data':_0x2d4888,'texture':_0x3802ed});},_0x12a95c['prototype']['loadData']=function(_0x9c53,_0x2b892f,_0x40e219){var _0xccece4=_0x568c36['GetDDSInfo'](_0x9c53),_0x56d661=(_0xccece4['isRGB']||_0xccece4['isLuminance']||_0xccece4['mipmapCount']>0x1)&&_0x2b892f['generateMipMaps']&&_0xccece4['width']>>_0xccece4['mipmapCount']-0x1==0x1;_0x40e219(_0xccece4['width'],_0xccece4['height'],_0x56d661,_0xccece4['isFourCC'],function(){_0x568c36['UploadDDSLevels'](_0x2b892f['getEngine'](),_0x2b892f,_0x9c53,_0xccece4,_0x56d661,0x1);});},_0x12a95c;}());_0x300b38['a']['_TextureLoaders']['push'](new _0x5ca044());var _0x1efa48=(function(){function _0x2aa9e4(){this['supportCascades']=!0x1;}return _0x2aa9e4['prototype']['canLoad']=function(_0x4ca06f){return _0x5950ed['a']['EndsWith'](_0x4ca06f,'.env');},_0x2aa9e4['prototype']['loadCubeData']=function(_0x357417,_0x70a2bb,_0x5edcf8,_0x2083be,_0xd91f0b){if(!Array['isArray'](_0x357417)){var _0x5b41ba=_0x480d46['GetEnvInfo'](_0x357417);_0x5b41ba?(_0x70a2bb['width']=_0x5b41ba['width'],_0x70a2bb['height']=_0x5b41ba['width'],_0x480d46['UploadEnvSpherical'](_0x70a2bb,_0x5b41ba),_0x480d46['UploadEnvLevelsAsync'](_0x70a2bb,_0x357417,_0x5b41ba)['then'](function(){_0x70a2bb['isReady']=!0x0,_0x70a2bb['onLoadedObservable']['notifyObservers'](_0x70a2bb),_0x70a2bb['onLoadedObservable']['clear'](),_0x2083be&&_0x2083be();})):_0xd91f0b&&_0xd91f0b('Can\x20not\x20parse\x20the\x20environment\x20file',null);}},_0x2aa9e4['prototype']['loadData']=function(_0x4264fd,_0x41625c,_0x2ce150){throw'.env\x20not\x20supported\x20in\x202d.';},_0x2aa9e4;}());_0x300b38['a']['_TextureLoaders']['push'](new _0x1efa48());var _0x8ca7f1=(function(){function _0x5d0199(_0x1eaaf2,_0x614912,_0x32a38d,_0x3c9d03){if(this['data']=_0x1eaaf2,this['isInvalid']=!0x1,!_0x5d0199['IsValid'](_0x1eaaf2))return this['isInvalid']=!0x0,void _0x75193d['a']['Error']('texture\x20missing\x20KTX\x20identifier');var _0x198659=Uint32Array['BYTES_PER_ELEMENT'],_0x429401=new DataView(this['data']['buffer'],this['data']['byteOffset']+0xc,0xd*_0x198659),_0x1bebc6=0x4030201===_0x429401['getUint32'](0x0,!0x0);this['glType']=_0x429401['getUint32'](0x1*_0x198659,_0x1bebc6),this['glTypeSize']=_0x429401['getUint32'](0x2*_0x198659,_0x1bebc6),this['glFormat']=_0x429401['getUint32'](0x3*_0x198659,_0x1bebc6),this['glInternalFormat']=_0x429401['getUint32'](0x4*_0x198659,_0x1bebc6),this['glBaseInternalFormat']=_0x429401['getUint32'](0x5*_0x198659,_0x1bebc6),this['pixelWidth']=_0x429401['getUint32'](0x6*_0x198659,_0x1bebc6),this['pixelHeight']=_0x429401['getUint32'](0x7*_0x198659,_0x1bebc6),this['pixelDepth']=_0x429401['getUint32'](0x8*_0x198659,_0x1bebc6),this['numberOfArrayElements']=_0x429401['getUint32'](0x9*_0x198659,_0x1bebc6),this['numberOfFaces']=_0x429401['getUint32'](0xa*_0x198659,_0x1bebc6),this['numberOfMipmapLevels']=_0x429401['getUint32'](0xb*_0x198659,_0x1bebc6),this['bytesOfKeyValueData']=_0x429401['getUint32'](0xc*_0x198659,_0x1bebc6),0x0===this['glType']?(this['numberOfMipmapLevels']=Math['max'](0x1,this['numberOfMipmapLevels']),0x0!==this['pixelHeight']&&0x0===this['pixelDepth']?0x0===this['numberOfArrayElements']?this['numberOfFaces']===_0x614912?this['loadType']=_0x5d0199['COMPRESSED_2D']:_0x75193d['a']['Error']('number\x20of\x20faces\x20expected'+_0x614912+',\x20but\x20found\x20'+this['numberOfFaces']):_0x75193d['a']['Error']('texture\x20arrays\x20not\x20currently\x20supported'):_0x75193d['a']['Error']('only\x202D\x20textures\x20currently\x20supported')):_0x75193d['a']['Error']('only\x20compressed\x20formats\x20currently\x20supported');}return _0x5d0199['prototype']['uploadLevels']=function(_0x38fd30,_0x2f6e94){switch(this['loadType']){case _0x5d0199['COMPRESSED_2D']:this['_upload2DCompressedLevels'](_0x38fd30,_0x2f6e94);break;case _0x5d0199['TEX_2D']:case _0x5d0199['COMPRESSED_3D']:case _0x5d0199['TEX_3D']:}},_0x5d0199['prototype']['_upload2DCompressedLevels']=function(_0x41a0f3,_0x52448c){for(var _0x2eb901=_0x5d0199['HEADER_LEN']+this['bytesOfKeyValueData'],_0x48c660=this['pixelWidth'],_0x378af8=this['pixelHeight'],_0x498a9d=_0x52448c?this['numberOfMipmapLevels']:0x1,_0x13c2bb=0x0;_0x13c2bb<_0x498a9d;_0x13c2bb++){var _0x461d50=new Int32Array(this['data']['buffer'],this['data']['byteOffset']+_0x2eb901,0x1)[0x0];_0x2eb901+=0x4;for(var _0x298c37=0x0;_0x298c37=0xc){var _0x2ad8c8=new Uint8Array(_0x2ed17d['buffer'],_0x2ed17d['byteOffset'],0xc);if(0xab===_0x2ad8c8[0x0]&&0x4b===_0x2ad8c8[0x1]&&0x54===_0x2ad8c8[0x2]&&0x58===_0x2ad8c8[0x3]&&0x20===_0x2ad8c8[0x4]&&0x31===_0x2ad8c8[0x5]&&0x31===_0x2ad8c8[0x6]&&0xbb===_0x2ad8c8[0x7]&&0xd===_0x2ad8c8[0x8]&&0xa===_0x2ad8c8[0x9]&&0x1a===_0x2ad8c8[0xa]&&0xa===_0x2ad8c8[0xb])return!0x0;}return!0x1;},_0x5d0199['HEADER_LEN']=0x40,_0x5d0199['COMPRESSED_2D']=0x0,_0x5d0199['COMPRESSED_3D']=0x1,_0x5d0199['TEX_2D']=0x2,_0x5d0199['TEX_3D']=0x3,_0x5d0199;}()),_0xe2001d=(function(){function _0x2b9f1c(_0x3ba140){this['_pendingActions']=new Array(),this['_workerInfos']=_0x3ba140['map'](function(_0x448bb5){return{'worker':_0x448bb5,'active':!0x1};});}return _0x2b9f1c['prototype']['dispose']=function(){for(var _0x7cdcb8=0x0,_0x1a0476=this['_workerInfos'];_0x7cdcb8<_0x1a0476['length'];_0x7cdcb8++){_0x1a0476[_0x7cdcb8]['worker']['terminate']();}this['_workerInfos']=[],this['_pendingActions']=[];},_0x2b9f1c['prototype']['push']=function(_0x1aa00a){for(var _0x66b232=0x0,_0x122c84=this['_workerInfos'];_0x66b232<_0x122c84['length'];_0x66b232++){var _0xdd17f5=_0x122c84[_0x66b232];if(!_0xdd17f5['active'])return void this['_execute'](_0xdd17f5,_0x1aa00a);}this['_pendingActions']['push'](_0x1aa00a);},_0x2b9f1c['prototype']['_execute']=function(_0x4c32d5,_0x195f60){var _0x50dfb9=this;_0x4c32d5['active']=!0x0,_0x195f60(_0x4c32d5['worker'],function(){_0x4c32d5['active']=!0x1;var _0x3c87d8=_0x50dfb9['_pendingActions']['shift']();_0x3c87d8&&_0x50dfb9['_execute'](_0x4c32d5,_0x3c87d8);});},_0x2b9f1c;}()),_0x20352=(function(){function _0xa38eff(_0x26a64e,_0x25773d){void 0x0===_0x25773d&&(_0x25773d=_0xa38eff['DefaultNumWorkers']),this['_engine']=_0x26a64e,_0xa38eff['_Initialized']||_0xa38eff['_CreateWorkerPool'](_0x25773d);}return _0xa38eff['GetDefaultNumWorkers']=function(){return'object'==typeof navigator&&navigator['hardwareConcurrency']?Math['min'](Math['floor'](0.5*navigator['hardwareConcurrency']),0x4):0x1;},_0xa38eff['_CreateWorkerPool']=function(_0xd54e5c){this['_Initialized']=!0x0,_0xd54e5c&&'function'==typeof Worker?_0xa38eff['_WorkerPoolPromise']=new Promise(function(_0x12a094){for(var _0x33cf7f='('+_0x1297f4+')()',_0x3d363e=URL['createObjectURL'](new Blob([_0x33cf7f],{'type':'application/javascript'})),_0x4aabd7=new Array(_0xd54e5c),_0x2eeb12=0x0;_0x2eeb12<_0x4aabd7['length'];_0x2eeb12++)_0x4aabd7[_0x2eeb12]=new Promise(function(_0x573641,_0x2ff8f6){var _0xa5f359=new Worker(_0x3d363e),_0xf42131=function(_0x1af8aa){_0xa5f359['removeEventListener']('error',_0xf42131),_0xa5f359['removeEventListener']('message',_0x3a15c5),_0x2ff8f6(_0x1af8aa);},_0x3a15c5=function(_0x3bac79){'init'===_0x3bac79['data']['action']&&(_0xa5f359['removeEventListener']('error',_0xf42131),_0xa5f359['removeEventListener']('message',_0x3a15c5),_0x573641(_0xa5f359));};_0xa5f359['addEventListener']('error',_0xf42131),_0xa5f359['addEventListener']('message',_0x3a15c5),_0xa5f359['postMessage']({'action':'init','urls':_0xa38eff['URLConfig']});});Promise['all'](_0x4aabd7)['then'](function(_0x911b4d){_0x12a094(new _0xe2001d(_0x911b4d));});}):(KTX2DECODER['MSCTranscoder']['UseFromWorkerThread']=!0x1,KTX2DECODER['WASMMemoryManager']['LoadBinariesFromCurrentThread']=!0x0);},_0xa38eff['prototype']['uploadAsync']=function(_0x1aecdd,_0x24c60f,_0xe60d59){var _0xe08814=this,_0x29a151=this['_engine']['getCaps'](),_0x230e9c={'astc':!!_0x29a151['astc'],'bptc':!!_0x29a151['bptc'],'s3tc':!!_0x29a151['s3tc'],'pvrtc':!!_0x29a151['pvrtc'],'etc2':!!_0x29a151['etc2'],'etc1':!!_0x29a151['etc1']};return _0xa38eff['_WorkerPoolPromise']?_0xa38eff['_WorkerPoolPromise']['then'](function(_0x13e101){return new Promise(function(_0x12c87f,_0x33cb69){_0x13e101['push'](function(_0x4f29a5,_0x4ae757){var _0xcfedfd=function(_0x965bd7){_0x4f29a5['removeEventListener']('error',_0xcfedfd),_0x4f29a5['removeEventListener']('message',_0x1b6602),_0x33cb69(_0x965bd7),_0x4ae757();},_0x1b6602=function(_0x49ccb8){if('decoded'===_0x49ccb8['data']['action']){if(_0x4f29a5['removeEventListener']('error',_0xcfedfd),_0x4f29a5['removeEventListener']('message',_0x1b6602),_0x49ccb8['data']['success'])try{_0xe08814['_createTexture'](_0x49ccb8['data']['decodedData'],_0x24c60f,_0xe60d59),_0x12c87f();}catch(_0x6a3395){_0x33cb69({'message':_0x6a3395});}else _0x33cb69({'message':_0x49ccb8['data']['msg']});_0x4ae757();}};_0x4f29a5['addEventListener']('error',_0xcfedfd),_0x4f29a5['addEventListener']('message',_0x1b6602),_0x4f29a5['postMessage']({'action':'decode','data':_0x1aecdd,'caps':_0x230e9c,'options':_0xe60d59});});});}):new Promise(function(_0x3e6801,_0xb7cd50){_0xa38eff['_Ktx2Decoder']||(_0xa38eff['_Ktx2Decoder']=new KTX2DECODER['KTX2Decoder']()),_0xa38eff['_Ktx2Decoder']['decode'](_0x1aecdd,_0x29a151)['then'](function(_0x22681a){_0xe08814['_createTexture'](_0x22681a,_0x24c60f),_0x3e6801();})['catch'](function(_0x213e0d){_0xb7cd50({'message':_0x213e0d});});});},_0xa38eff['prototype']['dispose']=function(){_0xa38eff['_WorkerPoolPromise']&&_0xa38eff['_WorkerPoolPromise']['then'](function(_0x29b820){_0x29b820['dispose']();}),delete _0xa38eff['_WorkerPoolPromise'];},_0xa38eff['prototype']['_createTexture']=function(_0x12f4c6,_0x3c1dcd,_0x1b1a5b){if(this['_engine']['_bindTextureDirectly'](this['_engine']['_gl']['TEXTURE_2D'],_0x3c1dcd),_0x1b1a5b&&(_0x1b1a5b['transcodedFormat']=_0x12f4c6['transcodedFormat'],_0x1b1a5b['isInGammaSpace']=_0x12f4c6['isInGammaSpace'],_0x1b1a5b['transcoderName']=_0x12f4c6['transcoderName']),0x8058===_0x12f4c6['transcodedFormat']?(_0x3c1dcd['type']=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_BYTE'],_0x3c1dcd['format']=_0x2103ba['a']['TEXTUREFORMAT_RGBA']):_0x3c1dcd['format']=_0x12f4c6['transcodedFormat'],_0x3c1dcd['_gammaSpace']=_0x12f4c6['isInGammaSpace'],_0x12f4c6['errors'])throw new Error('KTX2\x20container\x20-\x20could\x20not\x20transcode\x20the\x20data.\x20'+_0x12f4c6['errors']);for(var _0xc54c29=0x0;_0xc54c29<_0x12f4c6['mipmaps']['length'];++_0xc54c29){var _0x1b96c6=_0x12f4c6['mipmaps'][_0xc54c29];if(!_0x1b96c6||!_0x1b96c6['data'])throw new Error('KTX2\x20container\x20-\x20could\x20not\x20transcode\x20one\x20of\x20the\x20image');0x8058===_0x12f4c6['transcodedFormat']?(_0x3c1dcd['width']=_0x1b96c6['width'],_0x3c1dcd['height']=_0x1b96c6['height'],this['_engine']['_uploadDataToTextureDirectly'](_0x3c1dcd,_0x1b96c6['data'],0x0,_0xc54c29,void 0x0,!0x0)):this['_engine']['_uploadCompressedDataToTextureDirectly'](_0x3c1dcd,_0x12f4c6['transcodedFormat'],_0x1b96c6['width'],_0x1b96c6['height'],_0x1b96c6['data'],0x0,_0xc54c29);}_0x3c1dcd['width']=_0x12f4c6['mipmaps'][0x0]['width'],_0x3c1dcd['height']=_0x12f4c6['mipmaps'][0x0]['height'],_0x3c1dcd['generateMipMaps']=_0x12f4c6['mipmaps']['length']>0x1,_0x3c1dcd['isReady']=!0x0,this['_engine']['_bindTextureDirectly'](this['_engine']['_gl']['TEXTURE_2D'],null);},_0xa38eff['IsValid']=function(_0x1690da){if(_0x1690da['byteLength']>=0xc){var _0x20a648=new Uint8Array(_0x1690da['buffer'],_0x1690da['byteOffset'],0xc);if(0xab===_0x20a648[0x0]&&0x4b===_0x20a648[0x1]&&0x54===_0x20a648[0x2]&&0x58===_0x20a648[0x3]&&0x20===_0x20a648[0x4]&&0x32===_0x20a648[0x5]&&0x30===_0x20a648[0x6]&&0xbb===_0x20a648[0x7]&&0xd===_0x20a648[0x8]&&0xa===_0x20a648[0x9]&&0x1a===_0x20a648[0xa]&&0xa===_0x20a648[0xb])return!0x0;}return!0x1;},_0xa38eff['URLConfig']={'jsDecoderModule':'https://preview.babylonjs.com/babylon.ktx2Decoder.js','wasmUASTCToASTC':null,'wasmUASTCToBC7':null,'wasmUASTCToRGBA_UNORM':null,'wasmUASTCToRGBA_SRGB':null,'jsMSCTranscoder':null,'wasmMSCTranscoder':null},_0xa38eff['DefaultNumWorkers']=_0xa38eff['GetDefaultNumWorkers'](),_0xa38eff;}());function _0x1297f4(){var _0x4a7f97;onmessage=function(_0x163707){switch(_0x163707['data']['action']){case'init':var _0x23e2f5=_0x163707['data']['urls'];importScripts(_0x23e2f5['jsDecoderModule']),null!==_0x23e2f5['wasmUASTCToASTC']&&(KTX2DECODER['LiteTranscoder_UASTC_ASTC']['WasmModuleURL']=_0x23e2f5['wasmUASTCToASTC']),null!==_0x23e2f5['wasmUASTCToBC7']&&(KTX2DECODER['LiteTranscoder_UASTC_BC7']['WasmModuleURL']=_0x23e2f5['wasmUASTCToBC7']),null!==_0x23e2f5['wasmUASTCToRGBA_UNORM']&&(KTX2DECODER['LiteTranscoder_UASTC_RGBA_UNORM']['WasmModuleURL']=_0x23e2f5['wasmUASTCToRGBA_UNORM']),null!==_0x23e2f5['wasmUASTCToRGBA_SRGB']&&(KTX2DECODER['LiteTranscoder_UASTC_RGBA_SRGB']['WasmModuleURL']=_0x23e2f5['wasmUASTCToRGBA_SRGB']),null!==_0x23e2f5['jsMSCTranscoder']&&(KTX2DECODER['MSCTranscoder']['JSModuleURL']=_0x23e2f5['jsMSCTranscoder']),null!==_0x23e2f5['wasmMSCTranscoder']&&(KTX2DECODER['MSCTranscoder']['WasmModuleURL']=_0x23e2f5['wasmMSCTranscoder']),_0x4a7f97=new KTX2DECODER['KTX2Decoder'](),postMessage({'action':'init'});break;case'decode':_0x4a7f97['decode'](_0x163707['data']['data'],_0x163707['data']['caps'],_0x163707['data']['options'])['then'](function(_0x36f2ce){for(var _0x9682ba=[],_0x29ec55=0x0;_0x29ec55<_0x36f2ce['mipmaps']['length'];++_0x29ec55){var _0x336956=_0x36f2ce['mipmaps'][_0x29ec55];_0x336956&&_0x336956['data']&&_0x9682ba['push'](_0x336956['data']['buffer']);}postMessage({'action':'decoded','success':!0x0,'decodedData':_0x36f2ce},_0x9682ba);})['catch'](function(_0x4606e2){postMessage({'action':'decoded','success':!0x1,'msg':_0x4606e2});});}};}var _0x351007=(function(){function _0x5b34c4(){this['supportCascades']=!0x1;}return _0x5b34c4['prototype']['canLoad']=function(_0x50365a,_0x474269){return _0x5950ed['a']['EndsWith'](_0x50365a,'.ktx')||_0x5950ed['a']['EndsWith'](_0x50365a,'.ktx2')||'image/ktx'===_0x474269||'image/ktx2'===_0x474269;},_0x5b34c4['prototype']['loadCubeData']=function(_0x2102ae,_0x460f26,_0x4eaa03,_0x23af2f,_0x50d120){if(!Array['isArray'](_0x2102ae)){_0x460f26['_invertVScale']=!_0x460f26['invertY'];var _0x57bc8b=_0x460f26['getEngine'](),_0x40f4b6=new _0x8ca7f1(_0x2102ae,0x6),_0x2b1c81=_0x40f4b6['numberOfMipmapLevels']>0x1&&_0x460f26['generateMipMaps'];_0x57bc8b['_unpackFlipY'](!0x0),_0x40f4b6['uploadLevels'](_0x460f26,_0x460f26['generateMipMaps']),_0x460f26['width']=_0x40f4b6['pixelWidth'],_0x460f26['height']=_0x40f4b6['pixelHeight'],_0x57bc8b['_setCubeMapTextureParams'](_0x460f26,_0x2b1c81),_0x460f26['isReady']=!0x0,_0x460f26['onLoadedObservable']['notifyObservers'](_0x460f26),_0x460f26['onLoadedObservable']['clear'](),_0x23af2f&&_0x23af2f();}},_0x5b34c4['prototype']['loadData']=function(_0x59f954,_0x4b8002,_0x53a34b,_0x9690a4){if(_0x8ca7f1['IsValid'](_0x59f954)){_0x4b8002['_invertVScale']=!_0x4b8002['invertY'];var _0x24ba08=new _0x8ca7f1(_0x59f954,0x1);_0x53a34b(_0x24ba08['pixelWidth'],_0x24ba08['pixelHeight'],_0x4b8002['generateMipMaps'],!0x0,function(){_0x24ba08['uploadLevels'](_0x4b8002,_0x4b8002['generateMipMaps']);},_0x24ba08['isInvalid']);}else{if(_0x20352['IsValid'](_0x59f954))new _0x20352(_0x4b8002['getEngine']())['uploadAsync'](_0x59f954,_0x4b8002,_0x9690a4)['then'](function(){_0x53a34b(_0x4b8002['width'],_0x4b8002['height'],_0x4b8002['generateMipMaps'],!0x0,function(){},!0x1);},function(_0x47cf2a){_0x75193d['a']['Warn']('Failed\x20to\x20load\x20KTX2\x20texture\x20data:\x20'+_0x47cf2a['message']),_0x53a34b(0x0,0x0,!0x1,!0x1,function(){},!0x0);});else _0x75193d['a']['Error']('texture\x20missing\x20KTX\x20identifier'),_0x53a34b(0x0,0x0,!0x1,!0x1,function(){},!0x0);}},_0x5b34c4;}());_0x300b38['a']['_TextureLoaders']['unshift'](new _0x351007());var _0x4aea41=function(_0x4f7e68){function _0x525a72(_0x1297f2,_0x42cdd6,_0x1bed87){var _0x4f7ef2=_0x4f7e68['call'](this,_0x1297f2,_0x74d525['e']['Zero'](),_0x42cdd6)||this;return _0x4f7ef2['_xrSessionManager']=_0x1bed87,_0x4f7ef2['_firstFrame']=!0x1,_0x4f7ef2['_referenceQuaternion']=_0x74d525['b']['Identity'](),_0x4f7ef2['_referencedPosition']=new _0x74d525['e'](),_0x4f7ef2['_xrInvPositionCache']=new _0x74d525['e'](),_0x4f7ef2['_xrInvQuaternionCache']=_0x74d525['b']['Identity'](),_0x4f7ef2['_trackingState']=_0x49ab50['NOT_TRACKING'],_0x4f7ef2['onBeforeCameraTeleport']=new _0x6ac1f7['c'](),_0x4f7ef2['onAfterCameraTeleport']=new _0x6ac1f7['c'](),_0x4f7ef2['onTrackingStateChanged']=new _0x6ac1f7['c'](),_0x4f7ef2['compensateOnFirstFrame']=!0x0,_0x4f7ef2['_rotate180']=new _0x74d525['b'](0x0,0x1,0x0,0x0),_0x4f7ef2['minZ']=0.1,_0x4f7ef2['rotationQuaternion']=new _0x74d525['b'](),_0x4f7ef2['cameraRigMode']=_0x568729['a']['RIG_MODE_CUSTOM'],_0x4f7ef2['updateUpVectorFromRotation']=!0x0,_0x4f7ef2['_updateNumberOfRigCameras'](0x1),_0x4f7ef2['freezeProjectionMatrix'](),_0x4f7ef2['_xrSessionManager']['onXRSessionInit']['add'](function(){_0x4f7ef2['_referencedPosition']['copyFromFloats'](0x0,0x0,0x0),_0x4f7ef2['_referenceQuaternion']['copyFromFloats'](0x0,0x0,0x0,0x1),_0x4f7ef2['_firstFrame']=_0x4f7ef2['compensateOnFirstFrame'];}),_0x4f7ef2['_xrSessionManager']['onXRFrameObservable']['add'](function(_0x48ae0a){_0x4f7ef2['_firstFrame']&&_0x4f7ef2['_updateFromXRSession'](),_0x4f7ef2['_updateReferenceSpace'](),_0x4f7ef2['_updateFromXRSession']();},void 0x0,!0x0),_0x4f7ef2;}return Object(_0x18e13d['d'])(_0x525a72,_0x4f7e68),Object['defineProperty'](_0x525a72['prototype'],'trackingState',{'get':function(){return this['_trackingState'];},'enumerable':!0x1,'configurable':!0x0}),_0x525a72['prototype']['_setTrackingState']=function(_0x31d1af){this['_trackingState']!==_0x31d1af&&(this['_trackingState']=_0x31d1af,this['onTrackingStateChanged']['notifyObservers'](_0x31d1af));},Object['defineProperty'](_0x525a72['prototype'],'realWorldHeight',{'get':function(){var _0x110285=this['_xrSessionManager']['currentFrame']&&this['_xrSessionManager']['currentFrame']['getViewerPose'](this['_xrSessionManager']['baseReferenceSpace']);return _0x110285&&_0x110285['transform']?_0x110285['transform']['position']['y']:0x0;},'enumerable':!0x1,'configurable':!0x0}),_0x525a72['prototype']['_updateForDualEyeDebugging']=function(){this['_updateNumberOfRigCameras'](0x2),this['rigCameras'][0x0]['viewport']=new _0x4548b0['a'](0x0,0x0,0.5,0x1),this['rigCameras'][0x0]['outputRenderTarget']=null,this['rigCameras'][0x1]['viewport']=new _0x4548b0['a'](0.5,0x0,0.5,0x1),this['rigCameras'][0x1]['outputRenderTarget']=null;},_0x525a72['prototype']['setTransformationFromNonVRCamera']=function(_0x182aae,_0x4bf79c){(void 0x0===_0x182aae&&(_0x182aae=this['getScene']()['activeCamera']),void 0x0===_0x4bf79c&&(_0x4bf79c=!0x0),_0x182aae&&_0x182aae!==this)&&(_0x182aae['computeWorldMatrix']()['decompose'](void 0x0,this['rotationQuaternion'],this['position']),this['position']['y']=0x0,_0x74d525['b']['FromEulerAnglesToRef'](0x0,this['rotationQuaternion']['toEulerAngles']()['y'],0x0,this['rotationQuaternion']),this['_firstFrame']=!0x0,_0x4bf79c&&this['_xrSessionManager']['resetReferenceSpace']());},_0x525a72['prototype']['getClassName']=function(){return'WebXRCamera';},_0x525a72['prototype']['_updateFromXRSession']=function(){var _0x46ce04=this,_0x1b1b01=this['_xrSessionManager']['currentFrame']&&this['_xrSessionManager']['currentFrame']['getViewerPose'](this['_xrSessionManager']['referenceSpace']);if(_0x1b1b01){var _0x253112=_0x1b1b01['emulatedPosition']?_0x49ab50['TRACKING_LOST']:_0x49ab50['TRACKING'];if(this['_setTrackingState'](_0x253112),_0x1b1b01['transform']){var _0x15e4f6=_0x1b1b01['transform']['position'];this['_referencedPosition']['set'](_0x15e4f6['x'],_0x15e4f6['y'],_0x15e4f6['z']);var _0x5efa82=_0x1b1b01['transform']['orientation'];this['_referenceQuaternion']['set'](_0x5efa82['x'],_0x5efa82['y'],_0x5efa82['z'],_0x5efa82['w']),this['_scene']['useRightHandedSystem']||(this['_referencedPosition']['z']*=-0x1,this['_referenceQuaternion']['z']*=-0x1,this['_referenceQuaternion']['w']*=-0x1),this['_firstFrame']?(this['_firstFrame']=!0x1,this['position']['y']+=this['_referencedPosition']['y'],this['_referenceQuaternion']['copyFromFloats'](0x0,0x0,0x0,0x1)):(this['rotationQuaternion']['copyFrom'](this['_referenceQuaternion']),this['position']['copyFrom'](this['_referencedPosition']));}this['rigCameras']['length']!==_0x1b1b01['views']['length']&&this['_updateNumberOfRigCameras'](_0x1b1b01['views']['length']),_0x1b1b01['views']['forEach'](function(_0x2cc2eb,_0x424364){var _0x5b2f4b=_0x46ce04['rigCameras'][_0x424364];_0x5b2f4b['isLeftCamera']||_0x5b2f4b['isRightCamera']||('right'===_0x2cc2eb['eye']?_0x5b2f4b['_isRightCamera']=!0x0:'left'===_0x2cc2eb['eye']&&(_0x5b2f4b['_isLeftCamera']=!0x0));var _0x2b72a8=_0x2cc2eb['transform']['position'],_0xeb3070=_0x2cc2eb['transform']['orientation'];if(_0x5b2f4b['position']['set'](_0x2b72a8['x'],_0x2b72a8['y'],_0x2b72a8['z']),_0x5b2f4b['rotationQuaternion']['set'](_0xeb3070['x'],_0xeb3070['y'],_0xeb3070['z'],_0xeb3070['w']),_0x46ce04['_scene']['useRightHandedSystem']?_0x5b2f4b['rotationQuaternion']['multiplyInPlace'](_0x46ce04['_rotate180']):(_0x5b2f4b['position']['z']*=-0x1,_0x5b2f4b['rotationQuaternion']['z']*=-0x1,_0x5b2f4b['rotationQuaternion']['w']*=-0x1),_0x74d525['a']['FromFloat32ArrayToRefScaled'](_0x2cc2eb['projectionMatrix'],0x0,0x1,_0x5b2f4b['_projectionMatrix']),_0x46ce04['_scene']['useRightHandedSystem']||_0x5b2f4b['_projectionMatrix']['toggleProjectionMatrixHandInPlace'](),0x0===_0x424364&&_0x46ce04['_projectionMatrix']['copyFrom'](_0x5b2f4b['_projectionMatrix']),_0x46ce04['_xrSessionManager']['session']['renderState']['baseLayer']){var _0x15ae6d=_0x46ce04['_xrSessionManager']['session']['renderState']['baseLayer']['getViewport'](_0x2cc2eb),_0x1b4b7d=_0x46ce04['_xrSessionManager']['session']['renderState']['baseLayer']['framebufferWidth'],_0x46cd1b=_0x46ce04['_xrSessionManager']['session']['renderState']['baseLayer']['framebufferHeight'];_0x5b2f4b['viewport']['width']=_0x15ae6d['width']/_0x1b4b7d,_0x5b2f4b['viewport']['height']=_0x15ae6d['height']/_0x46cd1b,_0x5b2f4b['viewport']['x']=_0x15ae6d['x']/_0x1b4b7d,_0x5b2f4b['viewport']['y']=_0x15ae6d['y']/_0x46cd1b;}_0x5b2f4b['outputRenderTarget']=_0x46ce04['_xrSessionManager']['getRenderTargetTextureForEye'](_0x2cc2eb['eye']);});}else this['_setTrackingState'](_0x49ab50['NOT_TRACKING']);},_0x525a72['prototype']['_updateNumberOfRigCameras']=function(_0x31658b){for(void 0x0===_0x31658b&&(_0x31658b=0x1);this['rigCameras']['length']<_0x31658b;){var _0x124220=new _0x5f32ae('XR-RigCamera:\x20'+this['rigCameras']['length'],_0x74d525['e']['Zero'](),this['getScene']());_0x124220['minZ']=0.1,_0x124220['rotationQuaternion']=new _0x74d525['b'](),_0x124220['updateUpVectorFromRotation']=!0x0,_0x124220['isRigCamera']=!0x0,_0x124220['rigParent']=this,_0x124220['freezeProjectionMatrix'](),this['rigCameras']['push'](_0x124220);}for(;this['rigCameras']['length']>_0x31658b;){var _0x297aab=this['rigCameras']['pop']();_0x297aab&&_0x297aab['dispose']();}},_0x525a72['prototype']['_updateReferenceSpace']=function(){this['position']['equals'](this['_referencedPosition'])&&this['rotationQuaternion']['equals'](this['_referenceQuaternion'])||(this['position']['subtractToRef'](this['_referencedPosition'],this['_referencedPosition']),this['_referenceQuaternion']['conjugateInPlace'](),this['_referenceQuaternion']['multiplyToRef'](this['rotationQuaternion'],this['_referenceQuaternion']),this['_updateReferenceSpaceOffset'](this['_referencedPosition'],this['_referenceQuaternion']['normalize']()));},_0x525a72['prototype']['_updateReferenceSpaceOffset']=function(_0x501c2f,_0x2bdced,_0x444662){if(void 0x0===_0x444662&&(_0x444662=!0x1),this['_xrSessionManager']['referenceSpace']&&this['_xrSessionManager']['currentFrame']){this['_xrInvPositionCache']['copyFrom'](_0x501c2f),_0x2bdced?this['_xrInvQuaternionCache']['copyFrom'](_0x2bdced):this['_xrInvQuaternionCache']['copyFromFloats'](0x0,0x0,0x0,0x1),this['_scene']['useRightHandedSystem']||(this['_xrInvPositionCache']['z']*=-0x1,this['_xrInvQuaternionCache']['z']*=-0x1,this['_xrInvQuaternionCache']['w']*=-0x1),this['_xrInvPositionCache']['negateInPlace'](),this['_xrInvQuaternionCache']['conjugateInPlace'](),this['_xrInvPositionCache']['rotateByQuaternionToRef'](this['_xrInvQuaternionCache'],this['_xrInvPositionCache']),_0x444662&&(this['_xrInvPositionCache']['y']=0x0);var _0x24d695=new XRRigidTransform({'x':this['_xrInvPositionCache']['x'],'y':this['_xrInvPositionCache']['y'],'z':this['_xrInvPositionCache']['z']},{'x':this['_xrInvQuaternionCache']['x'],'y':this['_xrInvQuaternionCache']['y'],'z':this['_xrInvQuaternionCache']['z'],'w':this['_xrInvQuaternionCache']['w']}),_0x4e9f23=this['_xrSessionManager']['referenceSpace']['getOffsetReferenceSpace'](_0x24d695),_0x45fc7d=this['_xrSessionManager']['currentFrame']&&this['_xrSessionManager']['currentFrame']['getViewerPose'](_0x4e9f23);if(_0x45fc7d){var _0x1d0513=new _0x74d525['e'](_0x45fc7d['transform']['position']['x'],_0x45fc7d['transform']['position']['y'],_0x45fc7d['transform']['position']['z']);this['_scene']['useRightHandedSystem']||(_0x1d0513['z']*=-0x1),this['position']['subtractToRef'](_0x1d0513,_0x1d0513),this['_scene']['useRightHandedSystem']||(_0x1d0513['z']*=-0x1),_0x1d0513['negateInPlace']();var _0x170001=new XRRigidTransform({'x':_0x1d0513['x'],'y':_0x1d0513['y'],'z':_0x1d0513['z']});this['_xrSessionManager']['referenceSpace']=_0x4e9f23['getOffsetReferenceSpace'](_0x170001);}}},_0x525a72;}(_0x5625b9),_0x216b10=(function(){function _0x5e5ab5(){}return _0x5e5ab5['ANCHOR_SYSTEM']='xr-anchor-system',_0x5e5ab5['BACKGROUND_REMOVER']='xr-background-remover',_0x5e5ab5['HIT_TEST']='xr-hit-test',_0x5e5ab5['PHYSICS_CONTROLLERS']='xr-physics-controller',_0x5e5ab5['PLANE_DETECTION']='xr-plane-detection',_0x5e5ab5['POINTER_SELECTION']='xr-controller-pointer-selection',_0x5e5ab5['TELEPORTATION']='xr-controller-teleportation',_0x5e5ab5['FEATURE_POINTS']='xr-feature-points',_0x5e5ab5['HAND_TRACKING']='xr-hand-tracking',_0x5e5ab5;}()),_0x5ef0ab=(function(){function _0x2f5608(_0x3f77af){var _0x4215bf=this;this['_xrSessionManager']=_0x3f77af,this['_features']={},this['_xrSessionManager']['onXRSessionInit']['add'](function(){_0x4215bf['getEnabledFeatures']()['forEach'](function(_0x14ba74){var _0x181b31=_0x4215bf['_features'][_0x14ba74];!_0x181b31['enabled']||_0x181b31['featureImplementation']['attached']||_0x181b31['featureImplementation']['disableAutoAttach']||_0x4215bf['attachFeature'](_0x14ba74);});}),this['_xrSessionManager']['onXRSessionEnded']['add'](function(){_0x4215bf['getEnabledFeatures']()['forEach'](function(_0x2e92d9){var _0x1591cc=_0x4215bf['_features'][_0x2e92d9];_0x1591cc['enabled']&&_0x1591cc['featureImplementation']['attached']&&_0x4215bf['detachFeature'](_0x2e92d9);});});}return _0x2f5608['AddWebXRFeature']=function(_0x181445,_0x562b0d,_0x27982e,_0xa91e18){void 0x0===_0x27982e&&(_0x27982e=0x1),void 0x0===_0xa91e18&&(_0xa91e18=!0x1),this['_AvailableFeatures'][_0x181445]=this['_AvailableFeatures'][_0x181445]||{'latest':_0x27982e},_0x27982e>this['_AvailableFeatures'][_0x181445]['latest']&&(this['_AvailableFeatures'][_0x181445]['latest']=_0x27982e),_0xa91e18&&(this['_AvailableFeatures'][_0x181445]['stable']=_0x27982e),this['_AvailableFeatures'][_0x181445][_0x27982e]=_0x562b0d;},_0x2f5608['ConstructFeature']=function(_0x810140,_0x55b925,_0x27e97e,_0xf86532){void 0x0===_0x55b925&&(_0x55b925=0x1);var _0x5eaf40=this['_AvailableFeatures'][_0x810140][_0x55b925];if(!_0x5eaf40)throw new Error('feature\x20not\x20found');return _0x5eaf40(_0x27e97e,_0xf86532);},_0x2f5608['GetAvailableFeatures']=function(){return Object['keys'](this['_AvailableFeatures']);},_0x2f5608['GetAvailableVersions']=function(_0xddf3c5){return Object['keys'](this['_AvailableFeatures'][_0xddf3c5]);},_0x2f5608['GetLatestVersionOfFeature']=function(_0xe18213){return this['_AvailableFeatures'][_0xe18213]&&this['_AvailableFeatures'][_0xe18213]['latest']||-0x1;},_0x2f5608['GetStableVersionOfFeature']=function(_0x46d4ab){return this['_AvailableFeatures'][_0x46d4ab]&&this['_AvailableFeatures'][_0x46d4ab]['stable']||-0x1;},_0x2f5608['prototype']['attachFeature']=function(_0x5e4387){var _0x8c166c=this['_features'][_0x5e4387];_0x8c166c&&_0x8c166c['enabled']&&!_0x8c166c['featureImplementation']['attached']&&_0x8c166c['featureImplementation']['attach']();},_0x2f5608['prototype']['detachFeature']=function(_0x74f2b0){var _0x22e580=this['_features'][_0x74f2b0];_0x22e580&&_0x22e580['featureImplementation']['attached']&&_0x22e580['featureImplementation']['detach']();},_0x2f5608['prototype']['disableFeature']=function(_0x3035d7){var _0x4ff0d0='string'==typeof _0x3035d7?_0x3035d7:_0x3035d7['Name'],_0x1d210e=this['_features'][_0x4ff0d0];return!(!_0x1d210e||!_0x1d210e['enabled'])&&(_0x1d210e['enabled']=!0x1,this['detachFeature'](_0x4ff0d0),_0x1d210e['featureImplementation']['dispose'](),!0x0);},_0x2f5608['prototype']['dispose']=function(){var _0x4ab559=this;this['getEnabledFeatures']()['forEach'](function(_0x13f541){_0x4ab559['disableFeature'](_0x13f541),_0x4ab559['_features'][_0x13f541]['featureImplementation']['dispose']();});},_0x2f5608['prototype']['enableFeature']=function(_0x3ed0e2,_0x1a4484,_0x12897d,_0x5b4fb3,_0x85eaf8){var _0x399435=this;void 0x0===_0x1a4484&&(_0x1a4484='latest'),void 0x0===_0x12897d&&(_0x12897d={}),void 0x0===_0x5b4fb3&&(_0x5b4fb3=!0x0),void 0x0===_0x85eaf8&&(_0x85eaf8=!0x0);var _0x56263c='string'==typeof _0x3ed0e2?_0x3ed0e2:_0x3ed0e2['Name'],_0x44173d=0x0;if('string'==typeof _0x1a4484){if(!_0x1a4484)throw new Error('Error\x20in\x20provided\x20version\x20-\x20'+_0x56263c+'\x20('+_0x1a4484+')');if(-0x1===(_0x44173d='stable'===_0x1a4484?_0x2f5608['GetStableVersionOfFeature'](_0x56263c):'latest'===_0x1a4484?_0x2f5608['GetLatestVersionOfFeature'](_0x56263c):+_0x1a4484)||isNaN(_0x44173d))throw new Error('feature\x20not\x20found\x20-\x20'+_0x56263c+'\x20('+_0x1a4484+')');}else _0x44173d=_0x1a4484;var _0x45209e=this['_features'][_0x56263c],_0x46efd3=_0x2f5608['ConstructFeature'](_0x56263c,_0x44173d,this['_xrSessionManager'],_0x12897d);if(!_0x46efd3)throw new Error('feature\x20not\x20found\x20-\x20'+_0x56263c);_0x45209e&&this['disableFeature'](_0x56263c);var _0x5da0d1=_0x46efd3();if(_0x5da0d1['dependsOn']&&!_0x5da0d1['dependsOn']['every'](function(_0x42f1c5){return!!_0x399435['_features'][_0x42f1c5];}))throw new Error('Dependant\x20features\x20missing.\x20Make\x20sure\x20the\x20following\x20features\x20are\x20enabled\x20-\x20'+_0x5da0d1['dependsOn']['join'](',\x20'));if(_0x5da0d1['isCompatible']())return this['_features'][_0x56263c]={'featureImplementation':_0x5da0d1,'enabled':!0x0,'version':_0x44173d,'required':_0x85eaf8},_0x5b4fb3?this['_xrSessionManager']['session']&&!this['_features'][_0x56263c]['featureImplementation']['attached']&&this['attachFeature'](_0x56263c):this['_features'][_0x56263c]['featureImplementation']['disableAutoAttach']=!0x0,this['_features'][_0x56263c]['featureImplementation'];if(_0x85eaf8)throw new Error('required\x20feature\x20not\x20compatible');return _0x5d754c['b']['Warn']('Feature\x20'+_0x56263c+'\x20not\x20compatible\x20with\x20the\x20current\x20environment/browser\x20and\x20was\x20not\x20enabled.'),_0x5da0d1;},_0x2f5608['prototype']['getEnabledFeature']=function(_0x198cdf){return this['_features'][_0x198cdf]&&this['_features'][_0x198cdf]['featureImplementation'];},_0x2f5608['prototype']['getEnabledFeatures']=function(){return Object['keys'](this['_features']);},_0x2f5608['prototype']['extendXRSessionInitObject']=function(_0x55ec65){var _0x523162=this;return this['getEnabledFeatures']()['forEach'](function(_0x5e842c){var _0x172b7a=_0x523162['_features'][_0x5e842c],_0x588257=_0x172b7a['featureImplementation']['xrNativeFeatureName'];_0x588257&&(_0x172b7a['required']?(_0x55ec65['requiredFeatures']=_0x55ec65['requiredFeatures']||[],-0x1===_0x55ec65['requiredFeatures']['indexOf'](_0x588257)&&_0x55ec65['requiredFeatures']['push'](_0x588257)):(_0x55ec65['optionalFeatures']=_0x55ec65['optionalFeatures']||[],-0x1===_0x55ec65['optionalFeatures']['indexOf'](_0x588257)&&_0x55ec65['optionalFeatures']['push'](_0x588257)));}),_0x55ec65;},_0x2f5608['_AvailableFeatures']={},_0x2f5608;}()),_0xaf8b47=(function(){function _0x199c6f(_0x23cde8){var _0x10b7d6=this;this['scene']=_0x23cde8,this['_nonVRCamera']=null,this['_originalSceneAutoClear']=!0x0,this['_supported']=!0x1,this['onInitialXRPoseSetObservable']=new _0x6ac1f7['c'](),this['onStateChangedObservable']=new _0x6ac1f7['c'](),this['state']=_0xada4aa['NOT_IN_XR'],this['sessionManager']=new _0x31ca49(_0x23cde8),this['camera']=new _0x4aea41('',_0x23cde8,this['sessionManager']),this['featuresManager']=new _0x5ef0ab(this['sessionManager']),_0x23cde8['onDisposeObservable']['add'](function(){_0x10b7d6['exitXRAsync']();});}return _0x199c6f['CreateAsync']=function(_0x4a36c3){var _0x591d1c=new _0x199c6f(_0x4a36c3);return _0x591d1c['sessionManager']['initializeAsync']()['then'](function(){return _0x591d1c['_supported']=!0x0,_0x591d1c;})['catch'](function(_0x5531a2){throw _0x591d1c['_setState'](_0xada4aa['NOT_IN_XR']),_0x591d1c['dispose'](),_0x5531a2;});},_0x199c6f['prototype']['dispose']=function(){this['camera']['dispose'](),this['onStateChangedObservable']['clear'](),this['onInitialXRPoseSetObservable']['clear'](),this['sessionManager']['dispose'](),this['_nonVRCamera']&&(this['scene']['activeCamera']=this['_nonVRCamera']);},_0x199c6f['prototype']['enterXRAsync']=function(_0x1bd9cd,_0x4fee38,_0x34f2e4,_0x591331){var _0x37afc3=this;if(void 0x0===_0x34f2e4&&(_0x34f2e4=this['sessionManager']['getWebXRRenderTarget']()),void 0x0===_0x591331&&(_0x591331={}),!this['_supported'])throw'WebXR\x20not\x20supported\x20in\x20this\x20browser\x20or\x20environment';return this['_setState'](_0xada4aa['ENTERING_XR']),'viewer'!==_0x4fee38&&'local'!==_0x4fee38&&(_0x591331['optionalFeatures']=_0x591331['optionalFeatures']||[],_0x591331['optionalFeatures']['push'](_0x4fee38)),this['featuresManager']['extendXRSessionInitObject'](_0x591331),'immersive-ar'===_0x1bd9cd&&'unbounded'!==_0x4fee38&&_0x75193d['a']['Warn']('We\x20recommend\x20using\x20\x27unbounded\x27\x20reference\x20space\x20type\x20when\x20using\x20\x27immersive-ar\x27\x20session\x20mode'),this['sessionManager']['initializeSessionAsync'](_0x1bd9cd,_0x591331)['then'](function(){return _0x37afc3['sessionManager']['setReferenceSpaceTypeAsync'](_0x4fee38);})['then'](function(){return _0x34f2e4['initializeXRLayerAsync'](_0x37afc3['sessionManager']['session']);})['then'](function(){return _0x37afc3['sessionManager']['updateRenderStateAsync']({'depthFar':_0x37afc3['camera']['maxZ'],'depthNear':_0x37afc3['camera']['minZ'],'baseLayer':_0x34f2e4['xrLayer']});})['then'](function(){return _0x37afc3['sessionManager']['runXRRenderLoop'](),_0x37afc3['_originalSceneAutoClear']=_0x37afc3['scene']['autoClear'],_0x37afc3['_nonVRCamera']=_0x37afc3['scene']['activeCamera'],_0x37afc3['scene']['activeCamera']=_0x37afc3['camera'],'immersive-ar'!==_0x1bd9cd?_0x37afc3['_nonXRToXRCamera']():(_0x37afc3['scene']['autoClear']=!0x1,_0x37afc3['camera']['compensateOnFirstFrame']=!0x1),_0x37afc3['sessionManager']['onXRSessionEnded']['addOnce'](function(){_0x37afc3['camera']['rigCameras']['forEach'](function(_0x2c81b7){_0x2c81b7['outputRenderTarget']=null;}),_0x37afc3['scene']['autoClear']=_0x37afc3['_originalSceneAutoClear'],_0x37afc3['scene']['activeCamera']=_0x37afc3['_nonVRCamera'],'immersive-ar'!==_0x1bd9cd&&_0x37afc3['camera']['compensateOnFirstFrame']&&(_0x37afc3['_nonVRCamera']['setPosition']?_0x37afc3['_nonVRCamera']['setPosition'](_0x37afc3['camera']['position']):_0x37afc3['_nonVRCamera']['position']['copyFrom'](_0x37afc3['camera']['position'])),_0x37afc3['_setState'](_0xada4aa['NOT_IN_XR']);}),_0x37afc3['sessionManager']['onXRFrameObservable']['addOnce'](function(){_0x37afc3['_setState'](_0xada4aa['IN_XR']);}),_0x37afc3['sessionManager'];})['catch'](function(_0xd1a146){throw console['log'](_0xd1a146),console['log'](_0xd1a146['message']),_0x37afc3['_setState'](_0xada4aa['NOT_IN_XR']),_0xd1a146;});},_0x199c6f['prototype']['exitXRAsync']=function(){return this['state']!==_0xada4aa['IN_XR']?Promise['resolve']():(this['_setState'](_0xada4aa['EXITING_XR']),this['sessionManager']['exitXRAsync']());},_0x199c6f['prototype']['_nonXRToXRCamera']=function(){this['camera']['setTransformationFromNonVRCamera'](this['_nonVRCamera']),this['onInitialXRPoseSetObservable']['notifyObservers'](this['camera']);},_0x199c6f['prototype']['_setState']=function(_0xd39921){this['state']!==_0xd39921&&(this['state']=_0xd39921,this['onStateChangedObservable']['notifyObservers'](this['state']));},_0x199c6f;}()),_0x38e6cf=(function(){function _0x123ff8(_0x3df04a,_0x3ec996,_0x8e0772,_0x874cee){void 0x0===_0x8e0772&&(_0x8e0772=-0x1),void 0x0===_0x874cee&&(_0x874cee=[]),this['id']=_0x3df04a,this['type']=_0x3ec996,this['_buttonIndex']=_0x8e0772,this['_axesIndices']=_0x874cee,this['_axes']={'x':0x0,'y':0x0},this['_changes']={},this['_currentValue']=0x0,this['_hasChanges']=!0x1,this['_pressed']=!0x1,this['_touched']=!0x1,this['onAxisValueChangedObservable']=new _0x6ac1f7['c'](),this['onButtonStateChangedObservable']=new _0x6ac1f7['c']();}return Object['defineProperty'](_0x123ff8['prototype'],'axes',{'get':function(){return this['_axes'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x123ff8['prototype'],'changes',{'get':function(){return this['_changes'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x123ff8['prototype'],'hasChanges',{'get':function(){return this['_hasChanges'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x123ff8['prototype'],'pressed',{'get':function(){return this['_pressed'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x123ff8['prototype'],'touched',{'get':function(){return this['_touched'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x123ff8['prototype'],'value',{'get':function(){return this['_currentValue'];},'enumerable':!0x1,'configurable':!0x0}),_0x123ff8['prototype']['dispose']=function(){this['onAxisValueChangedObservable']['clear'](),this['onButtonStateChangedObservable']['clear']();},_0x123ff8['prototype']['isAxes']=function(){return 0x0!==this['_axesIndices']['length'];},_0x123ff8['prototype']['isButton']=function(){return-0x1!==this['_buttonIndex'];},_0x123ff8['prototype']['update']=function(_0xebbf86){var _0x422b2b=!0x1,_0x26d5e7=!0x1;if(this['_hasChanges']=!0x1,this['_changes']={},this['isButton']()){var _0x933fef=_0xebbf86['buttons'][this['_buttonIndex']];if(!_0x933fef)return;this['_currentValue']!==_0x933fef['value']&&(this['changes']['value']={'current':_0x933fef['value'],'previous':this['_currentValue']},_0x422b2b=!0x0,this['_currentValue']=_0x933fef['value']),this['_touched']!==_0x933fef['touched']&&(this['changes']['touched']={'current':_0x933fef['touched'],'previous':this['_touched']},_0x422b2b=!0x0,this['_touched']=_0x933fef['touched']),this['_pressed']!==_0x933fef['pressed']&&(this['changes']['pressed']={'current':_0x933fef['pressed'],'previous':this['_pressed']},_0x422b2b=!0x0,this['_pressed']=_0x933fef['pressed']);}this['isAxes']()&&(this['_axes']['x']!==_0xebbf86['axes'][this['_axesIndices'][0x0]]&&(this['changes']['axes']={'current':{'x':_0xebbf86['axes'][this['_axesIndices'][0x0]],'y':this['_axes']['y']},'previous':{'x':this['_axes']['x'],'y':this['_axes']['y']}},this['_axes']['x']=_0xebbf86['axes'][this['_axesIndices'][0x0]],_0x26d5e7=!0x0),this['_axes']['y']!==_0xebbf86['axes'][this['_axesIndices'][0x1]]&&(this['changes']['axes']?this['changes']['axes']['current']['y']=_0xebbf86['axes'][this['_axesIndices'][0x1]]:this['changes']['axes']={'current':{'x':this['_axes']['x'],'y':_0xebbf86['axes'][this['_axesIndices'][0x1]]},'previous':{'x':this['_axes']['x'],'y':this['_axes']['y']}},this['_axes']['y']=_0xebbf86['axes'][this['_axesIndices'][0x1]],_0x26d5e7=!0x0)),_0x422b2b&&(this['_hasChanges']=!0x0,this['onButtonStateChangedObservable']['notifyObservers'](this)),_0x26d5e7&&(this['_hasChanges']=!0x0,this['onAxisValueChangedObservable']['notifyObservers'](this['_axes']));},_0x123ff8['BUTTON_TYPE']='button',_0x123ff8['SQUEEZE_TYPE']='squeeze',_0x123ff8['THUMBSTICK_TYPE']='thumbstick',_0x123ff8['TOUCHPAD_TYPE']='touchpad',_0x123ff8['TRIGGER_TYPE']='trigger',_0x123ff8;}()),_0x48fb5b=(function(){function _0x5d0262(_0x21a1ac,_0x206011,_0x52cc91,_0x4fa3ac,_0x3b3751){var _0x1b0016=this;void 0x0===_0x3b3751&&(_0x3b3751=!0x1),this['scene']=_0x21a1ac,this['layout']=_0x206011,this['gamepadObject']=_0x52cc91,this['handedness']=_0x4fa3ac,this['_initComponent']=function(_0x198e16){if(_0x198e16){var _0x234a07=_0x1b0016['layout']['components'][_0x198e16],_0x2806b7=_0x234a07['type'],_0x2a2dba=_0x234a07['gamepadIndices']['button'],_0x40d71f=[];void 0x0!==_0x234a07['gamepadIndices']['xAxis']&&void 0x0!==_0x234a07['gamepadIndices']['yAxis']&&_0x40d71f['push'](_0x234a07['gamepadIndices']['xAxis'],_0x234a07['gamepadIndices']['yAxis']),_0x1b0016['components'][_0x198e16]=new _0x38e6cf(_0x198e16,_0x2806b7,_0x2a2dba,_0x40d71f);}},this['_modelReady']=!0x1,this['components']={},this['disableAnimation']=!0x1,this['onModelLoadedObservable']=new _0x6ac1f7['c'](),_0x206011['components']&&Object['keys'](_0x206011['components'])['forEach'](this['_initComponent']);}return _0x5d0262['prototype']['dispose']=function(){var _0x25f7d1=this;this['getComponentIds']()['forEach'](function(_0x5c51dd){return _0x25f7d1['getComponent'](_0x5c51dd)['dispose']();}),this['rootMesh']&&this['rootMesh']['dispose']();},_0x5d0262['prototype']['getAllComponentsOfType']=function(_0x40590a){var _0x4b19e9=this;return this['getComponentIds']()['map'](function(_0x2b4827){return _0x4b19e9['components'][_0x2b4827];})['filter'](function(_0x3073b6){return _0x3073b6['type']===_0x40590a;});},_0x5d0262['prototype']['getComponent']=function(_0x9e7eb4){return this['components'][_0x9e7eb4];},_0x5d0262['prototype']['getComponentIds']=function(){return Object['keys'](this['components']);},_0x5d0262['prototype']['getComponentOfType']=function(_0x4e50db){return this['getAllComponentsOfType'](_0x4e50db)[0x0]||null;},_0x5d0262['prototype']['getMainComponent']=function(){return this['getComponent'](this['layout']['selectComponentId']);},_0x5d0262['prototype']['loadModel']=function(){return Object(_0x18e13d['b'])(this,void 0x0,void 0x0,function(){var _0x3f2bac,_0x51007d,_0x1f1cf9=this;return Object(_0x18e13d['e'])(this,function(_0x248511){return _0x3f2bac=!this['_getModelLoadingConstraints'](),_0x51007d=this['_getGenericFilenameAndPath'](),_0x3f2bac?_0x75193d['a']['Warn']('Falling\x20back\x20to\x20generic\x20models'):_0x51007d=this['_getFilenameAndPath'](),[0x2,new Promise(function(_0x353882,_0x159e5f){_0x5de01e['ImportMesh']('',_0x51007d['path'],_0x51007d['filename'],_0x1f1cf9['scene'],function(_0x1e9e55){_0x3f2bac?_0x1f1cf9['_getGenericParentMesh'](_0x1e9e55):_0x1f1cf9['_setRootMesh'](_0x1e9e55),_0x1f1cf9['_processLoadedModel'](_0x1e9e55),_0x1f1cf9['_modelReady']=!0x0,_0x1f1cf9['onModelLoadedObservable']['notifyObservers'](_0x1f1cf9),_0x353882(!0x0);},null,function(_0x13e44c,_0x3732be){_0x75193d['a']['Log'](_0x3732be),_0x75193d['a']['Warn']('Failed\x20to\x20retrieve\x20controller\x20model\x20of\x20type\x20'+_0x1f1cf9['profileId']+'\x20from\x20the\x20remote\x20server:\x20'+_0x51007d['path']+_0x51007d['filename']),_0x159e5f(_0x3732be);});})];});});},_0x5d0262['prototype']['updateFromXRFrame']=function(_0x5124eb){var _0x3e4c92=this;this['getComponentIds']()['forEach'](function(_0x1d33ad){return _0x3e4c92['getComponent'](_0x1d33ad)['update'](_0x3e4c92['gamepadObject']);}),this['updateModel'](_0x5124eb);},Object['defineProperty'](_0x5d0262['prototype'],'handness',{'get':function(){return this['handedness'];},'enumerable':!0x1,'configurable':!0x0}),_0x5d0262['prototype']['pulse']=function(_0x59d90e,_0x21a2d1,_0x2080e8){return void 0x0===_0x2080e8&&(_0x2080e8=0x0),this['gamepadObject']['hapticActuators']&&this['gamepadObject']['hapticActuators'][_0x2080e8]?this['gamepadObject']['hapticActuators'][_0x2080e8]['pulse'](_0x59d90e,_0x21a2d1):Promise['resolve'](!0x1);},_0x5d0262['prototype']['_getChildByName']=function(_0x1783f5,_0x5b7b7c){return _0x1783f5['getChildren'](function(_0x67f858){return _0x67f858['name']===_0x5b7b7c;},!0x1)[0x0];},_0x5d0262['prototype']['_getImmediateChildByName']=function(_0x55afb2,_0x20f554){return _0x55afb2['getChildren'](function(_0x4ad8bc){return _0x4ad8bc['name']==_0x20f554;},!0x0)[0x0];},_0x5d0262['prototype']['_lerpTransform']=function(_0x45d23c,_0x1c6d8c,_0x5c0fb){if(_0x45d23c['minMesh']&&_0x45d23c['maxMesh']&&_0x45d23c['valueMesh']&&_0x45d23c['minMesh']['rotationQuaternion']&&_0x45d23c['maxMesh']['rotationQuaternion']&&_0x45d23c['valueMesh']['rotationQuaternion']){var _0x306bf2=_0x5c0fb?0.5*_0x1c6d8c+0.5:_0x1c6d8c;_0x74d525['b']['SlerpToRef'](_0x45d23c['minMesh']['rotationQuaternion'],_0x45d23c['maxMesh']['rotationQuaternion'],_0x306bf2,_0x45d23c['valueMesh']['rotationQuaternion']),_0x74d525['e']['LerpToRef'](_0x45d23c['minMesh']['position'],_0x45d23c['maxMesh']['position'],_0x306bf2,_0x45d23c['valueMesh']['position']);}},_0x5d0262['prototype']['updateModel']=function(_0x346659){this['_modelReady']&&this['_updateModel'](_0x346659);},_0x5d0262['prototype']['_getGenericFilenameAndPath']=function(){return{'filename':'generic.babylon','path':'https://controllers.babylonjs.com/generic/'};},_0x5d0262['prototype']['_getGenericParentMesh']=function(_0x3f73d6){var _0xe44826=this;this['rootMesh']=new _0x3cf5e5['a'](this['profileId']+'\x20'+this['handedness'],this['scene']),_0x3f73d6['forEach'](function(_0x3f0ea7){_0x3f0ea7['parent']||(_0x3f0ea7['isPickable']=!0x1,_0x3f0ea7['setParent'](_0xe44826['rootMesh']));}),this['rootMesh']['rotationQuaternion']=_0x74d525['b']['FromEulerAngles'](0x0,Math['PI'],0x0);},_0x5d0262;}()),_0x11269c=function(_0x1f8769){function _0x39759a(_0x2945b9,_0x6c9cff,_0x1327f8){var _0x1065d3=_0x1f8769['call'](this,_0x2945b9,_0x4f9636[_0x1327f8],_0x6c9cff,_0x1327f8)||this;return _0x1065d3['profileId']=_0x39759a['ProfileId'],_0x1065d3;}return Object(_0x18e13d['d'])(_0x39759a,_0x1f8769),_0x39759a['prototype']['_getFilenameAndPath']=function(){return{'filename':'generic.babylon','path':'https://controllers.babylonjs.com/generic/'};},_0x39759a['prototype']['_getModelLoadingConstraints']=function(){return!0x0;},_0x39759a['prototype']['_processLoadedModel']=function(_0x11d8ac){},_0x39759a['prototype']['_setRootMesh']=function(_0x52ba55){var _0x16272b=this;this['rootMesh']=new _0x3cf5e5['a'](this['profileId']+'\x20'+this['handedness'],this['scene']),_0x52ba55['forEach'](function(_0xa7e13d){_0xa7e13d['isPickable']=!0x1,_0xa7e13d['parent']||_0xa7e13d['setParent'](_0x16272b['rootMesh']);}),this['rootMesh']['rotationQuaternion']=_0x74d525['b']['FromEulerAngles'](0x0,Math['PI'],0x0);},_0x39759a['prototype']['_updateModel']=function(){},_0x39759a['ProfileId']='generic-trigger',_0x39759a;}(_0x48fb5b),_0x4f9636={'left':{'selectComponentId':'xr-standard-trigger','components':{'xr-standard-trigger':{'type':'trigger','gamepadIndices':{'button':0x0},'rootNodeName':'xr_standard_trigger','visualResponses':{}}},'gamepadMapping':'xr-standard','rootNodeName':'generic-trigger-left','assetPath':'left.glb'},'right':{'selectComponentId':'xr-standard-trigger','components':{'xr-standard-trigger':{'type':'trigger','gamepadIndices':{'button':0x0},'rootNodeName':'xr_standard_trigger','visualResponses':{}}},'gamepadMapping':'xr-standard','rootNodeName':'generic-trigger-right','assetPath':'right.glb'},'none':{'selectComponentId':'xr-standard-trigger','components':{'xr-standard-trigger':{'type':'trigger','gamepadIndices':{'button':0x0},'rootNodeName':'xr_standard_trigger','visualResponses':{}}},'gamepadMapping':'xr-standard','rootNodeName':'generic-trigger-none','assetPath':'none.glb'}},_0x546c04=function(_0x1e4d3c){function _0x554b20(_0xfa4fc6,_0x51d143,_0x383a81,_0x4e5cf7){var _0x156dc3=_0x1e4d3c['call'](this,_0xfa4fc6,_0x383a81['layouts'][_0x51d143['handedness']||'none'],_0x51d143['gamepad'],_0x51d143['handedness'])||this;return _0x156dc3['_repositoryUrl']=_0x4e5cf7,_0x156dc3['_buttonMeshMapping']={},_0x156dc3['_touchDots']={},_0x156dc3['profileId']=_0x383a81['profileId'],_0x156dc3;}return Object(_0x18e13d['d'])(_0x554b20,_0x1e4d3c),_0x554b20['prototype']['dispose']=function(){var _0x4d455f=this;_0x1e4d3c['prototype']['dispose']['call'](this),Object['keys'](this['_touchDots'])['forEach'](function(_0x3c98bd){_0x4d455f['_touchDots'][_0x3c98bd]['dispose']();});},_0x554b20['prototype']['_getFilenameAndPath']=function(){return{'filename':this['layout']['assetPath'],'path':this['_repositoryUrl']+'/profiles/'+this['profileId']+'/'};},_0x554b20['prototype']['_getModelLoadingConstraints']=function(){var _0x2fc5c9=_0x5de01e['IsPluginForExtensionAvailable']('.glb');return _0x2fc5c9||_0x75193d['a']['Warn']('glTF\x20/\x20glb\x20loaded\x20was\x20not\x20registered,\x20using\x20generic\x20controller\x20instead'),_0x2fc5c9;},_0x554b20['prototype']['_processLoadedModel']=function(_0x271731){var _0x41fd71=this;this['getComponentIds']()['forEach'](function(_0x5b2337){var _0x555e9a=_0x41fd71['layout']['components'][_0x5b2337];_0x41fd71['_buttonMeshMapping'][_0x5b2337]={'mainMesh':_0x41fd71['_getChildByName'](_0x41fd71['rootMesh'],_0x555e9a['rootNodeName']),'states':{}},Object['keys'](_0x555e9a['visualResponses'])['forEach'](function(_0x9cb8c7){var _0x4d1a28=_0x555e9a['visualResponses'][_0x9cb8c7];if('transform'===_0x4d1a28['valueNodeProperty'])_0x41fd71['_buttonMeshMapping'][_0x5b2337]['states'][_0x9cb8c7]={'valueMesh':_0x41fd71['_getChildByName'](_0x41fd71['rootMesh'],_0x4d1a28['valueNodeName']),'minMesh':_0x41fd71['_getChildByName'](_0x41fd71['rootMesh'],_0x4d1a28['minNodeName']),'maxMesh':_0x41fd71['_getChildByName'](_0x41fd71['rootMesh'],_0x4d1a28['maxNodeName'])};else{var _0x425d2d=_0x555e9a['type']===_0x38e6cf['TOUCHPAD_TYPE']&&_0x555e9a['touchPointNodeName']?_0x555e9a['touchPointNodeName']:_0x4d1a28['valueNodeName'];if(_0x41fd71['_buttonMeshMapping'][_0x5b2337]['states'][_0x9cb8c7]={'valueMesh':_0x41fd71['_getChildByName'](_0x41fd71['rootMesh'],_0x425d2d)},_0x555e9a['type']===_0x38e6cf['TOUCHPAD_TYPE']&&!_0x41fd71['_touchDots'][_0x9cb8c7]){var _0x4cda66=_0x5c4f8d['a']['CreateSphere'](_0x9cb8c7+'dot',{'diameter':0.0015,'segments':0x8},_0x41fd71['scene']);_0x4cda66['material']=new _0x5905ab['a'](_0x9cb8c7+'mat',_0x41fd71['scene']),_0x4cda66['material']['diffuseColor']=_0x39310d['a']['Red'](),_0x4cda66['parent']=_0x41fd71['_buttonMeshMapping'][_0x5b2337]['states'][_0x9cb8c7]['valueMesh']||null,_0x4cda66['isVisible']=!0x1,_0x41fd71['_touchDots'][_0x9cb8c7]=_0x4cda66;}}});});},_0x554b20['prototype']['_setRootMesh']=function(_0x251e33){var _0xb5082f;this['rootMesh']=new _0x3cf5e5['a'](this['profileId']+'-'+this['handedness'],this['scene']),this['rootMesh']['isPickable']=!0x1;for(var _0x470cab=0x0;_0x470cab<_0x251e33['length'];_0x470cab++){var _0x75e17b=_0x251e33[_0x470cab];_0x75e17b['isPickable']=!0x1,_0x75e17b['parent']||(_0xb5082f=_0x75e17b);}_0xb5082f&&_0xb5082f['setParent'](this['rootMesh']),this['scene']['useRightHandedSystem']||this['rootMesh']['rotate'](_0x4a79a2['a']['Y'],Math['PI'],_0x4a79a2['c']['WORLD']);},_0x554b20['prototype']['_updateModel']=function(_0x2e83bf){var _0x1f912a=this;this['disableAnimation']||this['getComponentIds']()['forEach'](function(_0x3a7c61){var _0xfaff06=_0x1f912a['getComponent'](_0x3a7c61);if(_0xfaff06['hasChanges']){var _0x4aa257=_0x1f912a['_buttonMeshMapping'][_0x3a7c61],_0x17844=_0x1f912a['layout']['components'][_0x3a7c61];Object['keys'](_0x17844['visualResponses'])['forEach'](function(_0x1aef59){var _0x1ece78=_0x17844['visualResponses'][_0x1aef59],_0x2e9bbc=_0xfaff06['value'];if('xAxis'===_0x1ece78['componentProperty']?_0x2e9bbc=_0xfaff06['axes']['x']:'yAxis'===_0x1ece78['componentProperty']&&(_0x2e9bbc=_0xfaff06['axes']['y']),'transform'===_0x1ece78['valueNodeProperty'])_0x1f912a['_lerpTransform'](_0x4aa257['states'][_0x1aef59],_0x2e9bbc,'button'!==_0x1ece78['componentProperty']);else{var _0x328b79=_0x4aa257['states'][_0x1aef59]['valueMesh'];_0x328b79&&(_0x328b79['isVisible']=_0xfaff06['touched']||_0xfaff06['pressed']),_0x1f912a['_touchDots'][_0x1aef59]&&(_0x1f912a['_touchDots'][_0x1aef59]['isVisible']=_0xfaff06['touched']||_0xfaff06['pressed']);}});}});},_0x554b20;}(_0x48fb5b),_0x13267d=(function(){function _0x178f04(){}return _0x178f04['ClearProfilesCache']=function(){this['_ProfilesList']=null,this['_ProfileLoadingPromises']={};},_0x178f04['DefaultFallbacks']=function(){this['RegisterFallbacksForProfileId']('google-daydream',['generic-touchpad']),this['RegisterFallbacksForProfileId']('htc-vive-focus',['generic-trigger-touchpad']),this['RegisterFallbacksForProfileId']('htc-vive',['generic-trigger-squeeze-touchpad']),this['RegisterFallbacksForProfileId']('magicleap-one',['generic-trigger-squeeze-touchpad']),this['RegisterFallbacksForProfileId']('windows-mixed-reality',['generic-trigger-squeeze-touchpad-thumbstick']),this['RegisterFallbacksForProfileId']('microsoft-mixed-reality',['windows-mixed-reality','generic-trigger-squeeze-touchpad-thumbstick']),this['RegisterFallbacksForProfileId']('oculus-go',['generic-trigger-touchpad']),this['RegisterFallbacksForProfileId']('oculus-touch-v2',['oculus-touch','generic-trigger-squeeze-thumbstick']),this['RegisterFallbacksForProfileId']('oculus-touch',['generic-trigger-squeeze-thumbstick']),this['RegisterFallbacksForProfileId']('samsung-gearvr',['windows-mixed-reality','generic-trigger-squeeze-touchpad-thumbstick']),this['RegisterFallbacksForProfileId']('samsung-odyssey',['generic-touchpad']),this['RegisterFallbacksForProfileId']('valve-index',['generic-trigger-squeeze-touchpad-thumbstick']);},_0x178f04['FindFallbackWithProfileId']=function(_0x4b5c7d){var _0x1f7df1=this['_Fallbacks'][_0x4b5c7d]||[];return _0x1f7df1['unshift'](_0x4b5c7d),_0x1f7df1;},_0x178f04['GetMotionControllerWithXRInput']=function(_0x9033d1,_0x248f07,_0x5e0ee0){var _0x500e66=this,_0x2c5f26=[];if(_0x5e0ee0&&_0x2c5f26['push'](_0x5e0ee0),_0x2c5f26['push']['apply'](_0x2c5f26,_0x9033d1['profiles']||[]),_0x2c5f26['length']&&!_0x2c5f26[0x0]&&_0x2c5f26['pop'](),_0x9033d1['gamepad']&&_0x9033d1['gamepad']['id'])switch(_0x9033d1['gamepad']['id']){case _0x9033d1['gamepad']['id']['match'](/oculus touch/gi)?_0x9033d1['gamepad']['id']:void 0x0:_0x2c5f26['push']('oculus-touch-v2');}var _0x1ebe64=_0x2c5f26['indexOf']('windows-mixed-reality');if(-0x1!==_0x1ebe64&&_0x2c5f26['splice'](_0x1ebe64,0x0,'microsoft-mixed-reality'),_0x2c5f26['length']||_0x2c5f26['push']('generic-trigger'),this['UseOnlineRepository']){var _0x169796=this['PrioritizeOnlineRepository']?this['_LoadProfileFromRepository']:this['_LoadProfilesFromAvailableControllers'],_0x2279cb=this['PrioritizeOnlineRepository']?this['_LoadProfilesFromAvailableControllers']:this['_LoadProfileFromRepository'];return _0x169796['call'](this,_0x2c5f26,_0x9033d1,_0x248f07)['catch'](function(){return _0x2279cb['call'](_0x500e66,_0x2c5f26,_0x9033d1,_0x248f07);});}return this['_LoadProfilesFromAvailableControllers'](_0x2c5f26,_0x9033d1,_0x248f07);},_0x178f04['RegisterController']=function(_0x19485e,_0x3a28b0){this['_AvailableControllers'][_0x19485e]=_0x3a28b0;},_0x178f04['RegisterFallbacksForProfileId']=function(_0x3b6f31,_0x5e8c84){var _0x4f490b;this['_Fallbacks'][_0x3b6f31]?(_0x4f490b=this['_Fallbacks'][_0x3b6f31])['push']['apply'](_0x4f490b,_0x5e8c84):this['_Fallbacks'][_0x3b6f31]=_0x5e8c84;},_0x178f04['UpdateProfilesList']=function(){return this['_ProfilesList']=_0x5d754c['b']['LoadFileAsync'](this['BaseRepositoryUrl']+'/profiles/profilesList.json',!0x1)['then'](function(_0x196f7b){return JSON['parse'](_0x196f7b['toString']());}),this['_ProfilesList'];},_0x178f04['_LoadProfileFromRepository']=function(_0x227a32,_0x37d0a7,_0x4d4b6c){var _0x161796=this;return Promise['resolve']()['then'](function(){return _0x161796['_ProfilesList']?_0x161796['_ProfilesList']:_0x161796['UpdateProfilesList']();})['then'](function(_0x29ff33){for(var _0x2a2927=0x0;_0x2a2927<_0x227a32['length'];++_0x2a2927)if(_0x227a32[_0x2a2927]&&_0x29ff33[_0x227a32[_0x2a2927]])return _0x227a32[_0x2a2927];throw new Error('neither\x20controller\x20'+_0x227a32[0x0]+'\x20nor\x20all\x20fallbacks\x20were\x20found\x20in\x20the\x20repository,');})['then'](function(_0x1b01fa){return _0x161796['_ProfileLoadingPromises'][_0x1b01fa]||(_0x161796['_ProfileLoadingPromises'][_0x1b01fa]=_0x5d754c['b']['LoadFileAsync'](_0x161796['BaseRepositoryUrl']+'/profiles/'+_0x1b01fa+'/profile.json',!0x1)['then'](function(_0x38d47b){return JSON['parse'](_0x38d47b);})),_0x161796['_ProfileLoadingPromises'][_0x1b01fa];})['then'](function(_0x33c402){return new _0x546c04(_0x4d4b6c,_0x37d0a7,_0x33c402,_0x161796['BaseRepositoryUrl']);});},_0x178f04['_LoadProfilesFromAvailableControllers']=function(_0xbefd35,_0x39ab4b,_0x245a34){for(var _0x3a5ae4=0x0;_0x3a5ae4<_0xbefd35['length'];++_0x3a5ae4)if(_0xbefd35[_0x3a5ae4])for(var _0x3d47af=this['FindFallbackWithProfileId'](_0xbefd35[_0x3a5ae4]),_0x834620=0x0;_0x834620<_0x3d47af['length'];++_0x834620){var _0x30caf8=this['_AvailableControllers'][_0x3d47af[_0x834620]];if(_0x30caf8)return Promise['resolve'](_0x30caf8(_0x39ab4b,_0x245a34));}throw new Error('no\x20controller\x20requested\x20was\x20found\x20in\x20the\x20available\x20controllers\x20list');},_0x178f04['_AvailableControllers']={},_0x178f04['_Fallbacks']={},_0x178f04['_ProfileLoadingPromises']={},_0x178f04['BaseRepositoryUrl']='https://immersive-web.github.io/webxr-input-profiles/packages/viewer/dist',_0x178f04['PrioritizeOnlineRepository']=!0x0,_0x178f04['UseOnlineRepository']=!0x0,_0x178f04;}());_0x13267d['RegisterController'](_0x11269c['ProfileId'],function(_0x4f7b76,_0x4afa60){return new _0x11269c(_0x4afa60,_0x4f7b76['gamepad'],_0x4f7b76['handedness']);}),_0x13267d['DefaultFallbacks']();var _0x5b2933=0x0,_0x567d87=(function(){function _0xb4a04b(_0x41a1f5,_0x505da9,_0x2ba743){var _0x2c4d5f=this;void 0x0===_0x2ba743&&(_0x2ba743={}),this['_scene']=_0x41a1f5,this['inputSource']=_0x505da9,this['_options']=_0x2ba743,this['_tmpVector']=new _0x74d525['e'](),this['_disposed']=!0x1,this['onDisposeObservable']=new _0x6ac1f7['c'](),this['onMeshLoadedObservable']=new _0x6ac1f7['c'](),this['onMotionControllerInitObservable']=new _0x6ac1f7['c'](),this['_uniqueId']='controller-'+_0x5b2933++ +'-'+_0x505da9['targetRayMode']+'-'+_0x505da9['handedness'],this['pointer']=new _0x40d22e['a'](this['_uniqueId']+'-pointer',_0x41a1f5),this['pointer']['rotationQuaternion']=new _0x74d525['b'](),this['inputSource']['gripSpace']&&(this['grip']=new _0x40d22e['a'](this['_uniqueId']+'-grip',this['_scene']),this['grip']['rotationQuaternion']=new _0x74d525['b']()),this['_tmpVector']['set'](0x0,0x0,this['_scene']['useRightHandedSystem']?-0x1:0x1),this['inputSource']['gamepad']&&_0x13267d['GetMotionControllerWithXRInput'](_0x505da9,_0x41a1f5,this['_options']['forceControllerProfile'])['then'](function(_0x3f9cf5){_0x2c4d5f['motionController']=_0x3f9cf5,_0x2c4d5f['onMotionControllerInitObservable']['notifyObservers'](_0x3f9cf5),_0x2c4d5f['_options']['doNotLoadControllerMesh']||_0x2c4d5f['motionController']['loadModel']()['then'](function(_0x62d267){var _0x5ef68f;_0x62d267&&_0x2c4d5f['motionController']&&_0x2c4d5f['motionController']['rootMesh']&&(_0x2c4d5f['_options']['renderingGroupId']&&(_0x2c4d5f['motionController']['rootMesh']['renderingGroupId']=_0x2c4d5f['_options']['renderingGroupId'],_0x2c4d5f['motionController']['rootMesh']['getChildMeshes'](!0x1)['forEach'](function(_0x26cdd6){return _0x26cdd6['renderingGroupId']=_0x2c4d5f['_options']['renderingGroupId'];})),_0x2c4d5f['onMeshLoadedObservable']['notifyObservers'](_0x2c4d5f['motionController']['rootMesh']),_0x2c4d5f['motionController']['rootMesh']['parent']=_0x2c4d5f['grip']||_0x2c4d5f['pointer'],_0x2c4d5f['motionController']['disableAnimation']=!!_0x2c4d5f['_options']['disableMotionControllerAnimation']),_0x2c4d5f['_disposed']&&(null===(_0x5ef68f=_0x2c4d5f['motionController'])||void 0x0===_0x5ef68f||_0x5ef68f['dispose']());});},function(){_0x5d754c['b']['Warn']('Could\x20not\x20find\x20a\x20matching\x20motion\x20controller\x20for\x20the\x20registered\x20input\x20source');});}return Object['defineProperty'](_0xb4a04b['prototype'],'uniqueId',{'get':function(){return this['_uniqueId'];},'enumerable':!0x1,'configurable':!0x0}),_0xb4a04b['prototype']['dispose']=function(){this['grip']&&this['grip']['dispose'](),this['motionController']&&this['motionController']['dispose'](),this['pointer']['dispose'](),this['onMotionControllerInitObservable']['clear'](),this['onMeshLoadedObservable']['clear'](),this['onDisposeObservable']['notifyObservers'](this),this['onDisposeObservable']['clear'](),this['_disposed']=!0x0;},_0xb4a04b['prototype']['getWorldPointerRayToRef']=function(_0x145325,_0x524648){void 0x0===_0x524648&&(_0x524648=!0x1);var _0x4b5c02=_0x524648&&this['grip']?this['grip']:this['pointer'];_0x74d525['e']['TransformNormalToRef'](this['_tmpVector'],_0x4b5c02['getWorldMatrix'](),_0x145325['direction']),_0x145325['direction']['normalize'](),_0x145325['origin']['copyFrom'](_0x4b5c02['absolutePosition']),_0x145325['length']=0x3e8;},_0xb4a04b['prototype']['updateFromXRFrame']=function(_0x1dcbe5,_0x8091fe){var _0x22baf5=_0x1dcbe5['getPose'](this['inputSource']['targetRaySpace'],_0x8091fe);if(_0x22baf5){var _0x101344=_0x22baf5['transform']['position'];this['pointer']['position']['set'](_0x101344['x'],_0x101344['y'],_0x101344['z']);var _0x31f2fc=_0x22baf5['transform']['orientation'];this['pointer']['rotationQuaternion']['set'](_0x31f2fc['x'],_0x31f2fc['y'],_0x31f2fc['z'],_0x31f2fc['w']),this['_scene']['useRightHandedSystem']||(this['pointer']['position']['z']*=-0x1,this['pointer']['rotationQuaternion']['z']*=-0x1,this['pointer']['rotationQuaternion']['w']*=-0x1);}if(this['inputSource']['gripSpace']&&this['grip']){var _0x326cd8=_0x1dcbe5['getPose'](this['inputSource']['gripSpace'],_0x8091fe);if(_0x326cd8){_0x101344=_0x326cd8['transform']['position'];var _0x39bf3f=_0x326cd8['transform']['orientation'];this['grip']['position']['set'](_0x101344['x'],_0x101344['y'],_0x101344['z']),this['grip']['rotationQuaternion']['set'](_0x39bf3f['x'],_0x39bf3f['y'],_0x39bf3f['z'],_0x39bf3f['w']),this['_scene']['useRightHandedSystem']||(this['grip']['position']['z']*=-0x1,this['grip']['rotationQuaternion']['z']*=-0x1,this['grip']['rotationQuaternion']['w']*=-0x1);}}this['motionController']&&this['motionController']['updateFromXRFrame'](_0x1dcbe5);},_0xb4a04b;}()),_0x51d413=(function(){function _0x2ffdeb(_0x561e5d,_0x1ce97c,_0x3ee7a0){var _0x2a6d8a=this;if(void 0x0===_0x3ee7a0&&(_0x3ee7a0={}),this['xrSessionManager']=_0x561e5d,this['xrCamera']=_0x1ce97c,this['options']=_0x3ee7a0,this['controllers']=[],this['onControllerAddedObservable']=new _0x6ac1f7['c'](),this['onControllerRemovedObservable']=new _0x6ac1f7['c'](),this['_onInputSourcesChange']=function(_0x5dd72e){_0x2a6d8a['_addAndRemoveControllers'](_0x5dd72e['added'],_0x5dd72e['removed']);},this['_sessionEndedObserver']=this['xrSessionManager']['onXRSessionEnded']['add'](function(){_0x2a6d8a['_addAndRemoveControllers']([],_0x2a6d8a['controllers']['map'](function(_0x4bdfd2){return _0x4bdfd2['inputSource'];}));}),this['_sessionInitObserver']=this['xrSessionManager']['onXRSessionInit']['add'](function(_0x47a5d2){_0x47a5d2['addEventListener']('inputsourceschange',_0x2a6d8a['_onInputSourcesChange']);}),this['_frameObserver']=this['xrSessionManager']['onXRFrameObservable']['add'](function(_0x101816){_0x2a6d8a['controllers']['forEach'](function(_0xc4368d){_0xc4368d['updateFromXRFrame'](_0x101816,_0x2a6d8a['xrSessionManager']['referenceSpace']);});}),this['options']['customControllersRepositoryURL']&&(_0x13267d['BaseRepositoryUrl']=this['options']['customControllersRepositoryURL']),_0x13267d['UseOnlineRepository']=!this['options']['disableOnlineControllerRepository'],_0x13267d['UseOnlineRepository'])try{_0x13267d['UpdateProfilesList']()['catch'](function(){_0x13267d['UseOnlineRepository']=!0x1;});}catch(_0x3dc25e){_0x13267d['UseOnlineRepository']=!0x1;}}return _0x2ffdeb['prototype']['_addAndRemoveControllers']=function(_0x3bab44,_0x37f593){for(var _0x1839a7=this,_0x4afa8d=this['controllers']['map'](function(_0x1939b7){return _0x1939b7['inputSource'];}),_0x2afe48=0x0,_0x459b93=_0x3bab44;_0x2afe48<_0x459b93['length'];_0x2afe48++){var _0x321010=_0x459b93[_0x2afe48];if(-0x1===_0x4afa8d['indexOf'](_0x321010)){var _0x415d25=new _0x567d87(this['xrSessionManager']['scene'],_0x321010,Object(_0x18e13d['a'])(Object(_0x18e13d['a'])({},this['options']['controllerOptions']||{}),{'forceControllerProfile':this['options']['forceInputProfile'],'doNotLoadControllerMesh':this['options']['doNotLoadControllerMeshes'],'disableMotionControllerAnimation':this['options']['disableControllerAnimation']}));this['controllers']['push'](_0x415d25),this['onControllerAddedObservable']['notifyObservers'](_0x415d25);}}var _0x24d54d=[],_0x173fed=[];this['controllers']['forEach'](function(_0x1ef817){-0x1===_0x37f593['indexOf'](_0x1ef817['inputSource'])?_0x24d54d['push'](_0x1ef817):_0x173fed['push'](_0x1ef817);}),this['controllers']=_0x24d54d,_0x173fed['forEach'](function(_0x18f6f4){_0x1839a7['onControllerRemovedObservable']['notifyObservers'](_0x18f6f4),_0x18f6f4['dispose']();});},_0x2ffdeb['prototype']['dispose']=function(){this['controllers']['forEach'](function(_0x5cfeb3){_0x5cfeb3['dispose']();}),this['xrSessionManager']['onXRFrameObservable']['remove'](this['_frameObserver']),this['xrSessionManager']['onXRSessionInit']['remove'](this['_sessionInitObserver']),this['xrSessionManager']['onXRSessionEnded']['remove'](this['_sessionEndedObserver']),this['onControllerAddedObservable']['clear'](),this['onControllerRemovedObservable']['clear']();},_0x2ffdeb;}()),_0x2fd67e=(function(){function _0x314718(_0x3bd319){this['_xrSessionManager']=_0x3bd319,this['_attached']=!0x1,this['_removeOnDetach']=[],this['isDisposed']=!0x1,this['disableAutoAttach']=!0x1,this['xrNativeFeatureName']='';}return Object['defineProperty'](_0x314718['prototype'],'attached',{'get':function(){return this['_attached'];},'enumerable':!0x1,'configurable':!0x0}),_0x314718['prototype']['attach']=function(_0x5383cd){var _0x72149e=this;if(this['isDisposed'])return!0x1;if(_0x5383cd)this['attached']&&this['detach']();else{if(this['attached'])return!0x1;}return this['_attached']=!0x0,this['_addNewAttachObserver'](this['_xrSessionManager']['onXRFrameObservable'],function(_0x6375d4){return _0x72149e['_onXRFrame'](_0x6375d4);}),!0x0;},_0x314718['prototype']['detach']=function(){return this['_attached']?(this['_attached']=!0x1,this['_removeOnDetach']['forEach'](function(_0x4d0c8e){_0x4d0c8e['observable']['remove'](_0x4d0c8e['observer']);}),!0x0):(this['disableAutoAttach']=!0x0,!0x1);},_0x314718['prototype']['dispose']=function(){this['detach'](),this['isDisposed']=!0x0;},_0x314718['prototype']['isCompatible']=function(){return!0x0;},_0x314718['prototype']['_addNewAttachObserver']=function(_0x459fef,_0x20e911){this['_removeOnDetach']['push']({'observable':_0x459fef,'observer':_0x459fef['add'](_0x20e911)});},_0x314718;}()),_0x4a05bd=function(_0x53f60f){function _0x31425a(_0x7819a0,_0x3407f2){var _0x1c6c4c=_0x53f60f['call'](this,_0x7819a0)||this;return _0x1c6c4c['_options']=_0x3407f2,_0x1c6c4c['_attachController']=function(_0x2ebc61){if(!_0x1c6c4c['_controllers'][_0x2ebc61['uniqueId']]){var _0x37d327=_0x1c6c4c['_generateNewMeshPair'](_0x2ebc61['pointer']),_0x554cfe=_0x37d327['laserPointer'],_0x7ec700=_0x37d327['selectionMesh'];switch(_0x1c6c4c['_controllers'][_0x2ebc61['uniqueId']]={'xrController':_0x2ebc61,'laserPointer':_0x554cfe,'selectionMesh':_0x7ec700,'meshUnderPointer':null,'pick':null,'tmpRay':new _0x36fb4d['a'](new _0x74d525['e'](),new _0x74d525['e']()),'id':_0x31425a['_idCounter']++},_0x1c6c4c['_attachedController']?!_0x1c6c4c['_options']['enablePointerSelectionOnAllControllers']&&_0x1c6c4c['_options']['preferredHandedness']&&_0x2ebc61['inputSource']['handedness']===_0x1c6c4c['_options']['preferredHandedness']&&(_0x1c6c4c['_attachedController']=_0x2ebc61['uniqueId']):_0x1c6c4c['_options']['enablePointerSelectionOnAllControllers']||(_0x1c6c4c['_attachedController']=_0x2ebc61['uniqueId']),_0x2ebc61['inputSource']['targetRayMode']){case'tracked-pointer':return _0x1c6c4c['_attachTrackedPointerRayMode'](_0x2ebc61);case'gaze':return _0x1c6c4c['_attachGazeMode'](_0x2ebc61);case'screen':return _0x1c6c4c['_attachScreenRayMode'](_0x2ebc61);}}},_0x1c6c4c['_controllers']={},_0x1c6c4c['_tmpVectorForPickCompare']=new _0x74d525['e'](),_0x1c6c4c['disablePointerLighting']=!0x0,_0x1c6c4c['disableSelectionMeshLighting']=!0x0,_0x1c6c4c['displayLaserPointer']=!0x0,_0x1c6c4c['displaySelectionMesh']=!0x0,_0x1c6c4c['laserPointerPickedColor']=new _0x39310d['a'](0.9,0.9,0.9),_0x1c6c4c['laserPointerDefaultColor']=new _0x39310d['a'](0.7,0.7,0.7),_0x1c6c4c['selectionMeshDefaultColor']=new _0x39310d['a'](0.8,0.8,0.8),_0x1c6c4c['selectionMeshPickedColor']=new _0x39310d['a'](0.3,0.3,0x1),_0x1c6c4c['_identityMatrix']=_0x74d525['a']['Identity'](),_0x1c6c4c['_screenCoordinatesRef']=_0x74d525['e']['Zero'](),_0x1c6c4c['_viewportRef']=new _0x4548b0['a'](0x0,0x0,0x0,0x0),_0x1c6c4c['_scene']=_0x1c6c4c['_xrSessionManager']['scene'],_0x1c6c4c;}return Object(_0x18e13d['d'])(_0x31425a,_0x53f60f),_0x31425a['prototype']['attach']=function(){var _0x554df0=this;if(!_0x53f60f['prototype']['attach']['call'](this))return!0x1;if(this['_options']['xrInput']['controllers']['forEach'](this['_attachController']),this['_addNewAttachObserver'](this['_options']['xrInput']['onControllerAddedObservable'],this['_attachController']),this['_addNewAttachObserver'](this['_options']['xrInput']['onControllerRemovedObservable'],function(_0x2e3307){_0x554df0['_detachController'](_0x2e3307['uniqueId']);}),this['_scene']['constantlyUpdateMeshUnderPointer']=!0x0,this['_options']['gazeCamera']){var _0x197703=this['_options']['gazeCamera'],_0x31bafe=this['_generateNewMeshPair'](_0x197703),_0x1e2f11=_0x31bafe['laserPointer'],_0x13b1d0=_0x31bafe['selectionMesh'];this['_controllers']['camera']={'webXRCamera':_0x197703,'laserPointer':_0x1e2f11,'selectionMesh':_0x13b1d0,'meshUnderPointer':null,'pick':null,'tmpRay':new _0x36fb4d['a'](new _0x74d525['e'](),new _0x74d525['e']()),'id':_0x31425a['_idCounter']++},this['_attachGazeMode']();}return!0x0;},_0x31425a['prototype']['detach']=function(){var _0x30707a=this;return!!_0x53f60f['prototype']['detach']['call'](this)&&(Object['keys'](this['_controllers'])['forEach'](function(_0x13fc4f){_0x30707a['_detachController'](_0x13fc4f);}),!0x0);},_0x31425a['prototype']['getMeshUnderPointer']=function(_0x3fc707){return this['_controllers'][_0x3fc707]?this['_controllers'][_0x3fc707]['meshUnderPointer']:null;},_0x31425a['prototype']['getXRControllerByPointerId']=function(_0x308530){for(var _0x453efa=Object['keys'](this['_controllers']),_0x43376e=0x0;_0x43376e<_0x453efa['length'];++_0x43376e)if(this['_controllers'][_0x453efa[_0x43376e]]['id']===_0x308530)return this['_controllers'][_0x453efa[_0x43376e]]['xrController']||null;return null;},_0x31425a['prototype']['_onXRFrame']=function(_0x479fec){var _0x33e1df=this;Object['keys'](this['_controllers'])['forEach'](function(_0xf66c72){var _0x3dd425,_0x20d056=_0x33e1df['_controllers'][_0xf66c72];if(!_0x33e1df['_options']['enablePointerSelectionOnAllControllers']&&_0xf66c72!==_0x33e1df['_attachedController'])return _0x20d056['selectionMesh']['isVisible']=!0x1,_0x20d056['laserPointer']['isVisible']=!0x1,void(_0x20d056['pick']=null);if(_0x20d056['laserPointer']['isVisible']=_0x33e1df['displayLaserPointer'],_0x20d056['xrController'])_0x3dd425=_0x20d056['xrController']['pointer']['position'],_0x20d056['xrController']['getWorldPointerRayToRef'](_0x20d056['tmpRay']);else{if(!_0x20d056['webXRCamera'])return;_0x3dd425=_0x20d056['webXRCamera']['position'],_0x20d056['webXRCamera']['getForwardRayToRef'](_0x20d056['tmpRay']);}if(_0x33e1df['_options']['maxPointerDistance']&&(_0x20d056['tmpRay']['length']=_0x33e1df['_options']['maxPointerDistance']),!_0x33e1df['_options']['disableScenePointerVectorUpdate']&&_0x3dd425){var _0x25e468=_0x33e1df['_xrSessionManager']['scene'],_0x95ceea=_0x33e1df['_options']['xrInput']['xrCamera'];_0x95ceea&&(_0x95ceea['viewport']['toGlobalToRef'](_0x25e468['getEngine']()['getRenderWidth'](),_0x25e468['getEngine']()['getRenderHeight'](),_0x33e1df['_viewportRef']),_0x74d525['e']['ProjectToRef'](_0x3dd425,_0x33e1df['_identityMatrix'],_0x25e468['getTransformMatrix'](),_0x33e1df['_viewportRef'],_0x33e1df['_screenCoordinatesRef']),_0x25e468['pointerX']=_0x33e1df['_screenCoordinatesRef']['x'],_0x25e468['pointerY']=_0x33e1df['_screenCoordinatesRef']['y']);}_0x20d056['pick']=_0x33e1df['_scene']['pickWithRay'](_0x20d056['tmpRay'],_0x33e1df['_scene']['pointerMovePredicate']||_0x33e1df['raySelectionPredicate']);var _0x5ab1a2=_0x20d056['pick'];if(_0x5ab1a2&&_0x5ab1a2['pickedPoint']&&_0x5ab1a2['hit']){_0x33e1df['_updatePointerDistance'](_0x20d056['laserPointer'],_0x5ab1a2['distance']),_0x20d056['selectionMesh']['position']['copyFrom'](_0x5ab1a2['pickedPoint']),_0x20d056['selectionMesh']['scaling']['x']=Math['sqrt'](_0x5ab1a2['distance']),_0x20d056['selectionMesh']['scaling']['y']=Math['sqrt'](_0x5ab1a2['distance']),_0x20d056['selectionMesh']['scaling']['z']=Math['sqrt'](_0x5ab1a2['distance']);var _0x39851b=_0x33e1df['_convertNormalToDirectionOfRay'](_0x5ab1a2['getNormal'](!0x0),_0x20d056['tmpRay']);if(_0x20d056['selectionMesh']['position']['copyFrom'](_0x5ab1a2['pickedPoint']),_0x39851b){var _0x469f33=_0x74d525['e']['Cross'](_0x4a79a2['a']['Y'],_0x39851b),_0x2c5f3c=_0x74d525['e']['Cross'](_0x39851b,_0x469f33);_0x74d525['e']['RotationFromAxisToRef'](_0x2c5f3c,_0x39851b,_0x469f33,_0x20d056['selectionMesh']['rotation']),_0x20d056['selectionMesh']['position']['addInPlace'](_0x39851b['scale'](0.001));}_0x20d056['selectionMesh']['isVisible']=_0x33e1df['displaySelectionMesh'],_0x20d056['meshUnderPointer']=_0x5ab1a2['pickedMesh'];}else _0x20d056['selectionMesh']['isVisible']=!0x1,_0x33e1df['_updatePointerDistance'](_0x20d056['laserPointer'],0x1),_0x20d056['meshUnderPointer']=null;});},_0x31425a['prototype']['_attachGazeMode']=function(_0x3c0a60){var _0x161ea7=this,_0x2ffbba=this['_controllers'][_0x3c0a60&&_0x3c0a60['uniqueId']||'camera'],_0x450684=this['_options']['timeToSelect']||0xbb8,_0x2649f7=this['_options']['useUtilityLayer']?this['_options']['customUtilityLayerScene']||_0x539118['a']['DefaultUtilityLayer']['utilityLayerScene']:this['_scene'],_0x31ebbf=new _0x1fa05e['a'](),_0x5917f3=_0x4a716b['CreateTorus']('selection',{'diameter':0.0525,'thickness':0.015,'tessellation':0x14},_0x2649f7);_0x5917f3['isVisible']=!0x1,_0x5917f3['isPickable']=!0x1,_0x5917f3['parent']=_0x2ffbba['selectionMesh'];var _0x1f7179=0x0,_0x4298cf=!0x1;_0x2ffbba['onFrameObserver']=this['_xrSessionManager']['onXRFrameObservable']['add'](function(){if(_0x2ffbba['pick']){if(_0x2ffbba['laserPointer']['material']['alpha']=0x0,_0x5917f3['isVisible']=!0x1,_0x2ffbba['pick']['hit']){if(_0x161ea7['_pickingMoved'](_0x31ebbf,_0x2ffbba['pick']))_0x4298cf&&(_0x161ea7['_options']['disablePointerUpOnTouchOut']||_0x161ea7['_scene']['simulatePointerUp'](_0x2ffbba['pick'],{'pointerId':_0x2ffbba['id']})),_0x4298cf=!0x1,_0x1f7179=0x0;else{if(_0x1f7179>_0x450684/0xa&&(_0x5917f3['isVisible']=!0x0),(_0x1f7179+=_0x161ea7['_scene']['getEngine']()['getDeltaTime']())>=_0x450684)_0x161ea7['_scene']['simulatePointerDown'](_0x2ffbba['pick'],{'pointerId':_0x2ffbba['id']}),_0x4298cf=!0x0,_0x161ea7['_options']['disablePointerUpOnTouchOut']&&_0x161ea7['_scene']['simulatePointerUp'](_0x2ffbba['pick'],{'pointerId':_0x2ffbba['id']}),_0x5917f3['isVisible']=!0x1;else{var _0x11fea4=0x1-_0x1f7179/_0x450684;_0x5917f3['scaling']['set'](_0x11fea4,_0x11fea4,_0x11fea4);}}}else _0x4298cf=!0x1,_0x1f7179=0x0;_0x161ea7['_scene']['simulatePointerMove'](_0x2ffbba['pick'],{'pointerId':_0x2ffbba['id']}),_0x31ebbf=_0x2ffbba['pick'];}}),void 0x0!==this['_options']['renderingGroupId']&&(_0x5917f3['renderingGroupId']=this['_options']['renderingGroupId']),_0x3c0a60&&_0x3c0a60['onDisposeObservable']['addOnce'](function(){_0x2ffbba['pick']&&!_0x161ea7['_options']['disablePointerUpOnTouchOut']&&_0x4298cf&&_0x161ea7['_scene']['simulatePointerUp'](_0x2ffbba['pick'],{'pointerId':_0x2ffbba['id']}),_0x5917f3['dispose']();});},_0x31425a['prototype']['_attachScreenRayMode']=function(_0x1cad0e){var _0x333327=this,_0xc76e65=this['_controllers'][_0x1cad0e['uniqueId']],_0x3baa3e=!0x1;_0xc76e65['onFrameObserver']=this['_xrSessionManager']['onXRFrameObservable']['add'](function(){!_0xc76e65['pick']||_0x333327['_options']['disablePointerUpOnTouchOut']&&_0x3baa3e||(_0x3baa3e?_0x333327['_scene']['simulatePointerMove'](_0xc76e65['pick'],{'pointerId':_0xc76e65['id']}):(_0x333327['_scene']['simulatePointerDown'](_0xc76e65['pick'],{'pointerId':_0xc76e65['id']}),_0x3baa3e=!0x0,_0x333327['_options']['disablePointerUpOnTouchOut']&&_0x333327['_scene']['simulatePointerUp'](_0xc76e65['pick'],{'pointerId':_0xc76e65['id']})));}),_0x1cad0e['onDisposeObservable']['addOnce'](function(){_0xc76e65['pick']&&_0x3baa3e&&!_0x333327['_options']['disablePointerUpOnTouchOut']&&_0x333327['_scene']['simulatePointerUp'](_0xc76e65['pick'],{'pointerId':_0xc76e65['id']});});},_0x31425a['prototype']['_attachTrackedPointerRayMode']=function(_0x2def02){var _0x408bcc=this,_0xcfe97c=this['_controllers'][_0x2def02['uniqueId']];if(this['_options']['forceGazeMode'])return this['_attachGazeMode'](_0x2def02);if(_0xcfe97c['onFrameObserver']=this['_xrSessionManager']['onXRFrameObservable']['add'](function(){_0xcfe97c['laserPointer']['material']['disableLighting']=_0x408bcc['disablePointerLighting'],_0xcfe97c['selectionMesh']['material']['disableLighting']=_0x408bcc['disableSelectionMeshLighting'],_0xcfe97c['pick']&&_0x408bcc['_scene']['simulatePointerMove'](_0xcfe97c['pick'],{'pointerId':_0xcfe97c['id']});}),_0x2def02['inputSource']['gamepad']){var _0x186aa=function(_0x4f18fe){_0x408bcc['_options']['overrideButtonId']&&(_0xcfe97c['selectionComponent']=_0x4f18fe['getComponent'](_0x408bcc['_options']['overrideButtonId'])),_0xcfe97c['selectionComponent']||(_0xcfe97c['selectionComponent']=_0x4f18fe['getMainComponent']()),_0xcfe97c['onButtonChangedObserver']=_0xcfe97c['selectionComponent']['onButtonStateChangedObservable']['add'](function(_0xa2202){if(_0xa2202['changes']['pressed']){var _0x373ac5=_0xa2202['changes']['pressed']['current'];_0xcfe97c['pick']?(_0x408bcc['_options']['enablePointerSelectionOnAllControllers']||_0x2def02['uniqueId']===_0x408bcc['_attachedController'])&&(_0x373ac5?(_0x408bcc['_scene']['simulatePointerDown'](_0xcfe97c['pick'],{'pointerId':_0xcfe97c['id']}),_0xcfe97c['selectionMesh']['material']['emissiveColor']=_0x408bcc['selectionMeshPickedColor'],_0xcfe97c['laserPointer']['material']['emissiveColor']=_0x408bcc['laserPointerPickedColor']):(_0x408bcc['_scene']['simulatePointerUp'](_0xcfe97c['pick'],{'pointerId':_0xcfe97c['id']}),_0xcfe97c['selectionMesh']['material']['emissiveColor']=_0x408bcc['selectionMeshDefaultColor'],_0xcfe97c['laserPointer']['material']['emissiveColor']=_0x408bcc['laserPointerDefaultColor'])):!_0x373ac5||_0x408bcc['_options']['enablePointerSelectionOnAllControllers']||_0x408bcc['_options']['disableSwitchOnClick']||(_0x408bcc['_attachedController']=_0x2def02['uniqueId']);}});};_0x2def02['motionController']?_0x186aa(_0x2def02['motionController']):_0x2def02['onMotionControllerInitObservable']['add'](_0x186aa);}else{var _0x51121c=function(_0x5d1ad4){_0xcfe97c['xrController']&&_0x5d1ad4['inputSource']===_0xcfe97c['xrController']['inputSource']&&_0xcfe97c['pick']&&(_0x408bcc['_scene']['simulatePointerDown'](_0xcfe97c['pick'],{'pointerId':_0xcfe97c['id']}),_0xcfe97c['selectionMesh']['material']['emissiveColor']=_0x408bcc['selectionMeshPickedColor'],_0xcfe97c['laserPointer']['material']['emissiveColor']=_0x408bcc['laserPointerPickedColor']);},_0x5c2deb=function(_0x47efae){_0xcfe97c['xrController']&&_0x47efae['inputSource']===_0xcfe97c['xrController']['inputSource']&&_0xcfe97c['pick']&&(_0x408bcc['_scene']['simulatePointerUp'](_0xcfe97c['pick'],{'pointerId':_0xcfe97c['id']}),_0xcfe97c['selectionMesh']['material']['emissiveColor']=_0x408bcc['selectionMeshDefaultColor'],_0xcfe97c['laserPointer']['material']['emissiveColor']=_0x408bcc['laserPointerDefaultColor']);};_0xcfe97c['eventListeners']={'selectend':_0x5c2deb,'selectstart':_0x51121c},this['_xrSessionManager']['session']['addEventListener']('selectstart',_0x51121c),this['_xrSessionManager']['session']['addEventListener']('selectend',_0x5c2deb);}},_0x31425a['prototype']['_convertNormalToDirectionOfRay']=function(_0x5ab87e,_0x31d97c){return _0x5ab87e&&(Math['acos'](_0x74d525['e']['Dot'](_0x5ab87e,_0x31d97c['direction']))_0x4d5571;},_0x31425a['prototype']['_updatePointerDistance']=function(_0x505ae7,_0x3d6d45){void 0x0===_0x3d6d45&&(_0x3d6d45=0x64),_0x505ae7['scaling']['y']=_0x3d6d45,this['_scene']['useRightHandedSystem']&&(_0x3d6d45*=-0x1),_0x505ae7['position']['z']=_0x3d6d45/0x2+0.05;},Object['defineProperty'](_0x31425a['prototype'],'lasterPointerDefaultColor',{'get':function(){return this['laserPointerDefaultColor'];},'enumerable':!0x1,'configurable':!0x0}),_0x31425a['_idCounter']=0xc8,_0x31425a['Name']=_0x216b10['POINTER_SELECTION'],_0x31425a['Version']=0x1,_0x31425a;}(_0x2fd67e);_0x5ef0ab['AddWebXRFeature'](_0x4a05bd['Name'],function(_0x5452d8,_0x52881d){return function(){return new _0x4a05bd(_0x5452d8,_0x52881d);};},_0x4a05bd['Version'],!0x0);var _0x496a16,_0x1875af=(function(){function _0x34d063(_0x24407b,_0x5ac59c,_0x5d2c33){this['element']=_0x24407b,this['sessionMode']=_0x5ac59c,this['referenceSpaceType']=_0x5d2c33;}return _0x34d063['prototype']['update']=function(_0x3a8a48){},_0x34d063;}()),_0x318d40=function(){},_0x57fcd2=(function(){function _0xb2ef6b(_0xbfeecb,_0x2c4d18){var _0x15b16d=this;if(this['scene']=_0xbfeecb,this['options']=_0x2c4d18,this['_activeButton']=null,this['_buttons']=[],this['activeButtonChangedObservable']=new _0x6ac1f7['c'](),this['overlay']=document['createElement']('div'),this['overlay']['classList']['add']('xr-button-overlay'),this['overlay']['style']['cssText']='z-index:11;position:\x20absolute;\x20right:\x2020px;bottom:\x2050px;','undefined'!=typeof window&&window['location']&&'http:'===window['location']['protocol']&&_0x5d754c['b']['Warn']('WebXR\x20can\x20only\x20be\x20served\x20over\x20HTTPS'),_0x2c4d18['customButtons'])this['_buttons']=_0x2c4d18['customButtons'];else{var _0x50797a=_0x2c4d18['sessionMode']||'immersive-vr',_0xe1a36f=_0x2c4d18['referenceSpaceType']||'local-floor',_0x373290='.babylonVRicon\x20{\x20color:\x20#868686;\x20border-color:\x20#868686;\x20border-style:\x20solid;\x20margin-left:\x2010px;\x20height:\x2050px;\x20width:\x2080px;\x20background-color:\x20rgba(51,51,51,0.7);\x20background-image:\x20url('+('undefined'==typeof SVGSVGElement?'https://cdn.babylonjs.com/Assets/vrButton.png':'data:image/svg+xml;charset=UTF-8,%3Csvg%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%20width%3D%222048%22%20height%3D%221152%22%20viewBox%3D%220%200%202048%201152%22%20version%3D%221.1%22%3E%3Cpath%20transform%3D%22rotate%28180%201024%2C576.0000000000001%29%22%20d%3D%22m1109%2C896q17%2C0%2030%2C-12t13%2C-30t-12.5%2C-30.5t-30.5%2C-12.5l-170%2C0q-18%2C0%20-30.5%2C12.5t-12.5%2C30.5t13%2C30t30%2C12l170%2C0zm-85%2C256q59%2C0%20132.5%2C-1.5t154.5%2C-5.5t164.5%2C-11.5t163%2C-20t150%2C-30t124.5%2C-41.5q23%2C-11%2042%2C-24t38%2C-30q27%2C-25%2041%2C-61.5t14%2C-72.5l0%2C-257q0%2C-123%20-47%2C-232t-128%2C-190t-190%2C-128t-232%2C-47l-81%2C0q-37%2C0%20-68.5%2C14t-60.5%2C34.5t-55.5%2C45t-53%2C45t-53%2C34.5t-55.5%2C14t-55.5%2C-14t-53%2C-34.5t-53%2C-45t-55.5%2C-45t-60.5%2C-34.5t-68.5%2C-14l-81%2C0q-123%2C0%20-232%2C47t-190%2C128t-128%2C190t-47%2C232l0%2C257q0%2C68%2038%2C115t97%2C73q54%2C24%20124.5%2C41.5t150%2C30t163%2C20t164.5%2C11.5t154.5%2C5.5t132.5%2C1.5zm939%2C-298q0%2C39%20-24.5%2C67t-58.5%2C42q-54%2C23%20-122%2C39.5t-143.5%2C28t-155.5%2C19t-157%2C11t-148.5%2C5t-129.5%2C1.5q-59%2C0%20-130%2C-1.5t-148%2C-5t-157%2C-11t-155.5%2C-19t-143.5%2C-28t-122%2C-39.5q-34%2C-14%20-58.5%2C-42t-24.5%2C-67l0%2C-257q0%2C-106%2040.5%2C-199t110%2C-162.5t162.5%2C-109.5t199%2C-40l81%2C0q27%2C0%2052%2C14t50%2C34.5t51%2C44.5t55.5%2C44.5t63.5%2C34.5t74%2C14t74%2C-14t63.5%2C-34.5t55.5%2C-44.5t51%2C-44.5t50%2C-34.5t52%2C-14l14%2C0q37%2C0%2070%2C0.5t64.5%2C4.5t63.5%2C12t68%2C23q71%2C30%20128.5%2C78.5t98.5%2C110t63.5%2C133.5t22.5%2C149l0%2C257z%22%20fill%3D%22white%22%20/%3E%3C/svg%3E%0A')+');\x20background-size:\x2080%;\x20background-repeat:no-repeat;\x20background-position:\x20center;\x20border:\x20none;\x20outline:\x20none;\x20transition:\x20transform\x200.125s\x20ease-out\x20}\x20.babylonVRicon:hover\x20{\x20transform:\x20scale(1.05)\x20}\x20.babylonVRicon:active\x20{background-color:\x20rgba(51,51,51,1)\x20}\x20.babylonVRicon:focus\x20{background-color:\x20rgba(51,51,51,1)\x20}';_0x373290+='.babylonVRicon.vrdisplaypresenting\x20{\x20background-image:\x20none;}\x20.vrdisplaypresenting::after\x20{\x20content:\x20\x22EXIT\x22}\x20.xr-error::after\x20{\x20content:\x20\x22ERROR\x22}';var _0x168e97=document['createElement']('style');_0x168e97['appendChild'](document['createTextNode'](_0x373290)),document['getElementsByTagName']('head')[0x0]['appendChild'](_0x168e97);var _0x34e58d=document['createElement']('button');_0x34e58d['className']='babylonVRicon',_0x34e58d['title']=_0x50797a+'\x20-\x20'+_0xe1a36f,this['_buttons']['push'](new _0x1875af(_0x34e58d,_0x50797a,_0xe1a36f)),this['_buttons'][this['_buttons']['length']-0x1]['update']=function(_0x385ed4){this['element']['style']['display']=null===_0x385ed4||_0x385ed4===this?'':'none',_0x34e58d['className']='babylonVRicon'+(_0x385ed4===this?'\x20vrdisplaypresenting':'');},this['_updateButtons'](null);}var _0x4b9982=_0xbfeecb['getEngine']()['getInputElement']();_0x4b9982&&_0x4b9982['parentNode']&&(_0x4b9982['parentNode']['appendChild'](this['overlay']),_0xbfeecb['onDisposeObservable']['addOnce'](function(){_0x15b16d['dispose']();}));}return _0xb2ef6b['CreateAsync']=function(_0x4fa82f,_0x386238,_0x5723ab){var _0x1ebadd=this,_0x59b3b8=new _0xb2ef6b(_0x4fa82f,_0x5723ab),_0x1905ef=_0x59b3b8['_buttons']['map'](function(_0x3ee835){return _0x386238['sessionManager']['isSessionSupportedAsync'](_0x3ee835['sessionMode']);});return _0x386238['onStateChangedObservable']['add'](function(_0x174fed){_0x174fed==_0xada4aa['NOT_IN_XR']&&_0x59b3b8['_updateButtons'](null);}),Promise['all'](_0x1905ef)['then'](function(_0x3e7db2){return _0x3e7db2['forEach'](function(_0x14e053,_0x31a138){_0x14e053?(_0x59b3b8['overlay']['appendChild'](_0x59b3b8['_buttons'][_0x31a138]['element']),_0x59b3b8['_buttons'][_0x31a138]['element']['onclick']=function(){return Object(_0x18e13d['b'])(_0x1ebadd,void 0x0,void 0x0,function(){var _0x1a04b2,_0x451374,_0x416275;return Object(_0x18e13d['e'])(this,function(_0x32393a){switch(_0x32393a['label']){case 0x0:return _0x386238['state']!=_0xada4aa['IN_XR']?[0x3,0x2]:[0x4,_0x386238['exitXRAsync']()];case 0x1:return _0x32393a['sent'](),_0x59b3b8['_updateButtons'](null),[0x3,0x6];case 0x2:if(_0x386238['state']!=_0xada4aa['NOT_IN_XR'])return[0x3,0x6];if(!_0x5723ab['renderTarget'])return[0x3,0x6];_0x32393a['label']=0x3;case 0x3:return _0x32393a['trys']['push']([0x3,0x5,,0x6]),[0x4,_0x386238['enterXRAsync'](_0x59b3b8['_buttons'][_0x31a138]['sessionMode'],_0x59b3b8['_buttons'][_0x31a138]['referenceSpaceType'],_0x5723ab['renderTarget'],{'optionalFeatures':_0x5723ab['optionalFeatures'],'requiredFeatures':_0x5723ab['requiredFeatures']})];case 0x4:return _0x32393a['sent'](),_0x59b3b8['_updateButtons'](_0x59b3b8['_buttons'][_0x31a138]),[0x3,0x6];case 0x5:return _0x1a04b2=_0x32393a['sent'](),_0x59b3b8['_updateButtons'](null),_0x451374=_0x59b3b8['_buttons'][_0x31a138]['element'],_0x416275=_0x451374['title'],_0x451374['title']='Error\x20entering\x20XR\x20session\x20:\x20'+_0x416275,_0x451374['classList']['add']('xr-error'),_0x5723ab['onError']&&_0x5723ab['onError'](_0x1a04b2),[0x3,0x6];case 0x6:return[0x2];}});});}):_0x5d754c['b']['Warn']('Session\x20mode\x20\x22'+_0x59b3b8['_buttons'][_0x31a138]['sessionMode']+'\x22\x20not\x20supported\x20in\x20browser');}),_0x59b3b8;});},_0xb2ef6b['prototype']['dispose']=function(){var _0x240b7f=this['scene']['getEngine']()['getInputElement']();_0x240b7f&&_0x240b7f['parentNode']&&_0x240b7f['parentNode']['contains'](this['overlay'])&&_0x240b7f['parentNode']['removeChild'](this['overlay']),this['activeButtonChangedObservable']['clear']();},_0xb2ef6b['prototype']['_updateButtons']=function(_0x5b409c){var _0xd28492=this;this['_activeButton']=_0x5b409c,this['_buttons']['forEach'](function(_0x5d038e){_0x5d038e['update'](_0xd28492['_activeButton']);}),this['activeButtonChangedObservable']['notifyObservers'](this['_activeButton']);},_0xb2ef6b;}());function _0xad9c7a(_0x2a690b){var _0x352cf2,_0x331744=0x0,_0x49df66=Date['now']();_0x2a690b['observableParameters']=null!==(_0x352cf2=_0x2a690b['observableParameters'])&&void 0x0!==_0x352cf2?_0x352cf2:{};var _0x2a71aa=_0x2a690b['contextObservable']['add'](function(_0x223e5a){var _0xef7c61=Date['now'](),_0x502a55={'startTime':_0x49df66,'currentTime':_0xef7c61,'deltaTime':_0x331744=_0xef7c61-_0x49df66,'completeRate':_0x331744/_0x2a690b['timeout'],'payload':_0x223e5a};_0x2a690b['onTick']&&_0x2a690b['onTick'](_0x502a55),_0x2a690b['breakCondition']&&_0x2a690b['breakCondition']()&&(_0x2a690b['contextObservable']['remove'](_0x2a71aa),_0x2a690b['onAborted']&&_0x2a690b['onAborted'](_0x502a55)),_0x331744>=_0x2a690b['timeout']&&(_0x2a690b['contextObservable']['remove'](_0x2a71aa),_0x2a690b['onEnded']&&_0x2a690b['onEnded'](_0x502a55));},_0x2a690b['observableParameters']['mask'],_0x2a690b['observableParameters']['insertFirst'],_0x2a690b['observableParameters']['scope']);return _0x2a71aa;}!function(_0x3bae6c){_0x3bae6c[_0x3bae6c['INIT']=0x0]='INIT',_0x3bae6c[_0x3bae6c['STARTED']=0x1]='STARTED',_0x3bae6c[_0x3bae6c['ENDED']=0x2]='ENDED';}(_0x496a16||(_0x496a16={}));var _0x8fbeb1=(function(){function _0x3f3d78(_0x2a4b6c){var _0x11f698,_0x7bc585,_0x1adbca=this;this['onEachCountObservable']=new _0x6ac1f7['c'](),this['onTimerAbortedObservable']=new _0x6ac1f7['c'](),this['onTimerEndedObservable']=new _0x6ac1f7['c'](),this['onStateChangedObservable']=new _0x6ac1f7['c'](),this['_observer']=null,this['_breakOnNextTick']=!0x1,this['_tick']=function(_0xef3be){var _0x3dc10f=Date['now']();_0x1adbca['_timer']=_0x3dc10f-_0x1adbca['_startTime'];var _0x1964a9={'startTime':_0x1adbca['_startTime'],'currentTime':_0x3dc10f,'deltaTime':_0x1adbca['_timer'],'completeRate':_0x1adbca['_timer']/_0x1adbca['_timeToEnd'],'payload':_0xef3be},_0x58c771=_0x1adbca['_breakOnNextTick']||_0x1adbca['_breakCondition'](_0x1964a9);_0x58c771||_0x1adbca['_timer']>=_0x1adbca['_timeToEnd']?_0x1adbca['_stop'](_0x1964a9,_0x58c771):_0x1adbca['onEachCountObservable']['notifyObservers'](_0x1964a9);},this['_setState'](_0x496a16['INIT']),this['_contextObservable']=_0x2a4b6c['contextObservable'],this['_observableParameters']=null!==(_0x11f698=_0x2a4b6c['observableParameters'])&&void 0x0!==_0x11f698?_0x11f698:{},this['_breakCondition']=null!==(_0x7bc585=_0x2a4b6c['breakCondition'])&&void 0x0!==_0x7bc585?_0x7bc585:function(){return!0x1;},_0x2a4b6c['onEnded']&&this['onTimerEndedObservable']['add'](_0x2a4b6c['onEnded']),_0x2a4b6c['onTick']&&this['onEachCountObservable']['add'](_0x2a4b6c['onTick']),_0x2a4b6c['onAborted']&&this['onTimerAbortedObservable']['add'](_0x2a4b6c['onAborted']);}return Object['defineProperty'](_0x3f3d78['prototype'],'breakCondition',{'set':function(_0x350f1d){this['_breakCondition']=_0x350f1d;},'enumerable':!0x1,'configurable':!0x0}),_0x3f3d78['prototype']['clearObservables']=function(){this['onEachCountObservable']['clear'](),this['onTimerAbortedObservable']['clear'](),this['onTimerEndedObservable']['clear'](),this['onStateChangedObservable']['clear']();},_0x3f3d78['prototype']['start']=function(_0x35442b){if(void 0x0===_0x35442b&&(_0x35442b=this['_timeToEnd']),this['_state']===_0x496a16['STARTED'])throw new Error('Timer\x20already\x20started.\x20Please\x20stop\x20it\x20before\x20starting\x20again');this['_timeToEnd']=_0x35442b,this['_startTime']=Date['now'](),this['_timer']=0x0,this['_observer']=this['_contextObservable']['add'](this['_tick'],this['_observableParameters']['mask'],this['_observableParameters']['insertFirst'],this['_observableParameters']['scope']),this['_setState'](_0x496a16['STARTED']);},_0x3f3d78['prototype']['stop']=function(){this['_state']===_0x496a16['STARTED']&&(this['_breakOnNextTick']=!0x0);},_0x3f3d78['prototype']['dispose']=function(){this['_observer']&&this['_contextObservable']['remove'](this['_observer']),this['clearObservables']();},_0x3f3d78['prototype']['_setState']=function(_0x490d64){this['_state']=_0x490d64,this['onStateChangedObservable']['notifyObservers'](this['_state']);},_0x3f3d78['prototype']['_stop']=function(_0x1762a5,_0x1f803e){void 0x0===_0x1f803e&&(_0x1f803e=!0x1),this['_contextObservable']['remove'](this['_observer']),this['_setState'](_0x496a16['ENDED']),_0x1f803e?this['onTimerAbortedObservable']['notifyObservers'](_0x1762a5):this['onTimerEndedObservable']['notifyObservers'](_0x1762a5);},_0x3f3d78;}()),_0x55b553=function(_0xce7939){function _0x480fcd(_0x37b118,_0x5f3fc0){var _0x12ffe7=_0xce7939['call'](this,_0x37b118)||this;return _0x12ffe7['_options']=_0x5f3fc0,_0x12ffe7['_controllers']={},_0x12ffe7['_snappedToPoint']=!0x1,_0x12ffe7['_tmpRay']=new _0x36fb4d['a'](new _0x74d525['e'](),new _0x74d525['e']()),_0x12ffe7['_tmpVector']=new _0x74d525['e'](),_0x12ffe7['_tmpQuaternion']=new _0x74d525['b'](),_0x12ffe7['backwardsMovementEnabled']=!0x0,_0x12ffe7['backwardsTeleportationDistance']=0.7,_0x12ffe7['parabolicCheckRadius']=0x5,_0x12ffe7['parabolicRayEnabled']=!0x0,_0x12ffe7['straightRayEnabled']=!0x0,_0x12ffe7['rotationAngle']=Math['PI']/0x8,_0x12ffe7['_rotationEnabled']=!0x0,_0x12ffe7['_attachController']=function(_0x4ad975){if(!(_0x12ffe7['_controllers'][_0x4ad975['uniqueId']]||_0x12ffe7['_options']['forceHandedness']&&_0x4ad975['inputSource']['handedness']!==_0x12ffe7['_options']['forceHandedness'])){_0x12ffe7['_controllers'][_0x4ad975['uniqueId']]={'xrController':_0x4ad975,'teleportationState':{'forward':!0x1,'backwards':!0x1,'rotating':!0x1,'currentRotation':0x0,'baseRotation':0x0}};var _0x17650d=_0x12ffe7['_controllers'][_0x4ad975['uniqueId']];if('tracked-pointer'===_0x17650d['xrController']['inputSource']['targetRayMode']&&_0x17650d['xrController']['inputSource']['gamepad']){var _0x336e08=function(){if(_0x4ad975['motionController']){var _0x6476b2=_0x4ad975['motionController']['getComponentOfType'](_0x38e6cf['THUMBSTICK_TYPE'])||_0x4ad975['motionController']['getComponentOfType'](_0x38e6cf['TOUCHPAD_TYPE']);if(!_0x6476b2||_0x12ffe7['_options']['useMainComponentOnly']){var _0x1b401a=_0x4ad975['motionController']['getMainComponent']();if(!_0x1b401a)return;_0x17650d['teleportationComponent']=_0x1b401a,_0x17650d['onButtonChangedObserver']=_0x1b401a['onButtonStateChangedObservable']['add'](function(){_0x1b401a['changes']['pressed']&&(_0x1b401a['changes']['pressed']['current']?(_0x17650d['teleportationState']['forward']=!0x0,_0x12ffe7['_currentTeleportationControllerId']=_0x17650d['xrController']['uniqueId'],_0x17650d['teleportationState']['baseRotation']=_0x12ffe7['_options']['xrInput']['xrCamera']['rotationQuaternion']['toEulerAngles']()['y'],_0x17650d['teleportationState']['currentRotation']=0x0,_0xad9c7a({'timeout':_0x12ffe7['_options']['timeToTeleport']||0xbb8,'contextObservable':_0x12ffe7['_xrSessionManager']['onXRFrameObservable'],'breakCondition':function(){return!_0x1b401a['pressed'];},'onEnded':function(){_0x12ffe7['_currentTeleportationControllerId']===_0x17650d['xrController']['uniqueId']&&_0x17650d['teleportationState']['forward']&&_0x12ffe7['_teleportForward'](_0x4ad975['uniqueId']);}})):(_0x17650d['teleportationState']['forward']=!0x1,_0x12ffe7['_currentTeleportationControllerId']=''));});}else _0x17650d['teleportationComponent']=_0x6476b2,_0x17650d['onAxisChangedObserver']=_0x6476b2['onAxisValueChangedObservable']['add'](function(_0xe71a01){if(_0xe71a01['y']<=0.7&&_0x17650d['teleportationState']['backwards']&&(_0x17650d['teleportationState']['backwards']=!0x1),_0xe71a01['y']>0.7&&!_0x17650d['teleportationState']['forward']&&_0x12ffe7['backwardsMovementEnabled']&&!_0x12ffe7['snapPointsOnly']&&!_0x17650d['teleportationState']['backwards']){_0x17650d['teleportationState']['backwards']=!0x0,_0x12ffe7['_tmpQuaternion']['copyFrom'](_0x12ffe7['_options']['xrInput']['xrCamera']['rotationQuaternion']),_0x12ffe7['_tmpQuaternion']['toEulerAnglesToRef'](_0x12ffe7['_tmpVector']),_0x12ffe7['_tmpVector']['x']=0x0,_0x12ffe7['_tmpVector']['z']=0x0,_0x74d525['b']['FromEulerVectorToRef'](_0x12ffe7['_tmpVector'],_0x12ffe7['_tmpQuaternion']),_0x12ffe7['_tmpVector']['set'](0x0,0x0,_0x12ffe7['backwardsTeleportationDistance']*(_0x12ffe7['_xrSessionManager']['scene']['useRightHandedSystem']?0x1:-0x1)),_0x12ffe7['_tmpVector']['rotateByQuaternionToRef'](_0x12ffe7['_tmpQuaternion'],_0x12ffe7['_tmpVector']),_0x12ffe7['_tmpVector']['addInPlace'](_0x12ffe7['_options']['xrInput']['xrCamera']['position']),_0x12ffe7['_tmpRay']['origin']['copyFrom'](_0x12ffe7['_tmpVector']),_0x12ffe7['_tmpRay']['length']=_0x12ffe7['_options']['xrInput']['xrCamera']['realWorldHeight']+0.1,_0x12ffe7['_tmpRay']['direction']['set'](0x0,-0x1,0x0);var _0x2e36bd=_0x12ffe7['_xrSessionManager']['scene']['pickWithRay'](_0x12ffe7['_tmpRay'],function(_0x4fcade){return-0x1!==_0x12ffe7['_floorMeshes']['indexOf'](_0x4fcade);});_0x2e36bd&&_0x2e36bd['pickedPoint']&&(_0x12ffe7['_options']['xrInput']['xrCamera']['position']['x']=_0x2e36bd['pickedPoint']['x'],_0x12ffe7['_options']['xrInput']['xrCamera']['position']['z']=_0x2e36bd['pickedPoint']['z']);}if(_0xe71a01['y']<-0.7&&!_0x12ffe7['_currentTeleportationControllerId']&&!_0x17650d['teleportationState']['rotating']&&(_0x17650d['teleportationState']['forward']=!0x0,_0x12ffe7['_currentTeleportationControllerId']=_0x17650d['xrController']['uniqueId'],_0x17650d['teleportationState']['baseRotation']=_0x12ffe7['_options']['xrInput']['xrCamera']['rotationQuaternion']['toEulerAngles']()['y']),_0xe71a01['x']){if(_0x17650d['teleportationState']['forward'])_0x12ffe7['_currentTeleportationControllerId']===_0x17650d['xrController']['uniqueId']&&(_0x12ffe7['rotationEnabled']?setTimeout(function(){_0x17650d['teleportationState']['currentRotation']=Math['atan2'](_0xe71a01['x'],_0xe71a01['y']*(_0x12ffe7['_xrSessionManager']['scene']['useRightHandedSystem']?0x1:-0x1));}):_0x17650d['teleportationState']['currentRotation']=0x0);else{if(!_0x17650d['teleportationState']['rotating']&&Math['abs'](_0xe71a01['x'])>0.7){_0x17650d['teleportationState']['rotating']=!0x0;var _0x3adf53=_0x12ffe7['rotationAngle']*(_0xe71a01['x']>0x0?0x1:-0x1)*(_0x12ffe7['_xrSessionManager']['scene']['useRightHandedSystem']?-0x1:0x1);_0x12ffe7['_options']['xrInput']['xrCamera']['rotationQuaternion']['multiplyInPlace'](_0x74d525['b']['FromEulerAngles'](0x0,_0x3adf53,0x0));}}}else _0x17650d['teleportationState']['rotating']=!0x1;0x0===_0xe71a01['x']&&0x0===_0xe71a01['y']&&_0x17650d['teleportationState']['forward']&&_0x12ffe7['_teleportForward'](_0x4ad975['uniqueId']);});}};_0x4ad975['motionController']?_0x336e08():_0x4ad975['onMotionControllerInitObservable']['addOnce'](function(){_0x336e08();});}else _0x12ffe7['_xrSessionManager']['scene']['onPointerObservable']['add'](function(_0x103b2a){_0x103b2a['type']===_0x1cb628['a']['POINTERDOWN']?(_0x17650d['teleportationState']['forward']=!0x0,_0x12ffe7['_currentTeleportationControllerId']=_0x17650d['xrController']['uniqueId'],_0x17650d['teleportationState']['baseRotation']=_0x12ffe7['_options']['xrInput']['xrCamera']['rotationQuaternion']['toEulerAngles']()['y'],_0x17650d['teleportationState']['currentRotation']=0x0,_0xad9c7a({'timeout':_0x12ffe7['_options']['timeToTeleport']||0xbb8,'contextObservable':_0x12ffe7['_xrSessionManager']['onXRFrameObservable'],'onEnded':function(){_0x12ffe7['_currentTeleportationControllerId']===_0x17650d['xrController']['uniqueId']&&_0x17650d['teleportationState']['forward']&&_0x12ffe7['_teleportForward'](_0x4ad975['uniqueId']);}})):_0x103b2a['type']===_0x1cb628['a']['POINTERUP']&&(_0x17650d['teleportationState']['forward']=!0x1,_0x12ffe7['_currentTeleportationControllerId']='');});}},_0x12ffe7['_options']['teleportationTargetMesh']||_0x12ffe7['_createDefaultTargetMesh'](),_0x12ffe7['_floorMeshes']=_0x12ffe7['_options']['floorMeshes']||[],_0x12ffe7['_snapToPositions']=_0x12ffe7['_options']['snapPositions']||[],_0x12ffe7['_setTargetMeshVisibility'](!0x1),_0x12ffe7;}return Object(_0x18e13d['d'])(_0x480fcd,_0xce7939),Object['defineProperty'](_0x480fcd['prototype'],'rotationEnabled',{'get':function(){return this['_rotationEnabled'];},'set':function(_0x2469a2){if(this['_rotationEnabled']=_0x2469a2,this['_options']['teleportationTargetMesh']){var _0x2b50d6=this['_options']['teleportationTargetMesh']['getChildMeshes'](!0x1,function(_0x3d4270){return'rotationCone'===_0x3d4270['name'];});_0x2b50d6[0x0]&&_0x2b50d6[0x0]['setEnabled'](_0x2469a2);}},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x480fcd['prototype'],'teleportationTargetMesh',{'get':function(){return this['_options']['teleportationTargetMesh']||null;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x480fcd['prototype'],'snapPointsOnly',{'get':function(){return!!this['_options']['snapPointsOnly'];},'set':function(_0x39c77c){this['_options']['snapPointsOnly']=_0x39c77c;},'enumerable':!0x1,'configurable':!0x0}),_0x480fcd['prototype']['addFloorMesh']=function(_0x1c4e0f){this['_floorMeshes']['push'](_0x1c4e0f);},_0x480fcd['prototype']['addSnapPoint']=function(_0x5737c8){this['_snapToPositions']['push'](_0x5737c8);},_0x480fcd['prototype']['attach']=function(){var _0x15fbd2=this;return!!_0xce7939['prototype']['attach']['call'](this)&&(this['_currentTeleportationControllerId']='',this['_options']['xrInput']['controllers']['forEach'](this['_attachController']),this['_addNewAttachObserver'](this['_options']['xrInput']['onControllerAddedObservable'],this['_attachController']),this['_addNewAttachObserver'](this['_options']['xrInput']['onControllerRemovedObservable'],function(_0x2c5b03){_0x15fbd2['_detachController'](_0x2c5b03['uniqueId']);}),!0x0);},_0x480fcd['prototype']['detach']=function(){var _0x27d718=this;return!!_0xce7939['prototype']['detach']['call'](this)&&(Object['keys'](this['_controllers'])['forEach'](function(_0xe34031){_0x27d718['_detachController'](_0xe34031);}),this['_setTargetMeshVisibility'](!0x1),this['_currentTeleportationControllerId']='',this['_controllers']={},!0x0);},_0x480fcd['prototype']['dispose']=function(){_0xce7939['prototype']['dispose']['call'](this),this['_options']['teleportationTargetMesh']&&this['_options']['teleportationTargetMesh']['dispose'](!0x1,!0x0);},_0x480fcd['prototype']['removeFloorMesh']=function(_0x2660cc){var _0x48d54e=this['_floorMeshes']['indexOf'](_0x2660cc);-0x1!==_0x48d54e&&this['_floorMeshes']['splice'](_0x48d54e,0x1);},_0x480fcd['prototype']['removeFloorMeshByName']=function(_0x4adf33){var _0x2ef8e9=this['_xrSessionManager']['scene']['getMeshByName'](_0x4adf33);_0x2ef8e9&&this['removeFloorMesh'](_0x2ef8e9);},_0x480fcd['prototype']['removeSnapPoint']=function(_0x3aee03){var _0x78d949=this['_snapToPositions']['indexOf'](_0x3aee03);if(-0x1===_0x78d949){for(var _0x55e502=0x0;_0x55e502=_0x35b5dd['video']['HAVE_CURRENT_DATA'];return!_0x2c8484['poster']||_0x2c8484['autoPlay']&&_0x5b6c33?_0x5b6c33&&_0x35b5dd['_createInternalTexture']():(_0x35b5dd['_texture']=_0x35b5dd['_getEngine']()['createTexture'](_0x2c8484['poster'],!0x1,!_0x35b5dd['invertY'],_0x5693b0),_0x35b5dd['_displayingPosterTexture']=!0x0),_0x35b5dd;}return Object(_0x18e13d['d'])(_0x298dec,_0x321701),Object['defineProperty'](_0x298dec['prototype'],'onUserActionRequestedObservable',{'get':function(){return this['_onUserActionRequestedObservable']||(this['_onUserActionRequestedObservable']=new _0x6ac1f7['c']()),this['_onUserActionRequestedObservable'];},'enumerable':!0x1,'configurable':!0x0}),_0x298dec['prototype']['_getName']=function(_0x11a0ef){return _0x11a0ef instanceof HTMLVideoElement?_0x11a0ef['currentSrc']:'object'==typeof _0x11a0ef?_0x11a0ef['toString']():_0x11a0ef;},_0x298dec['prototype']['_getVideo']=function(_0x518796){if(_0x518796 instanceof HTMLVideoElement)return _0x5d754c['b']['SetCorsBehavior'](_0x518796['currentSrc'],_0x518796),_0x518796;var _0x209f20=document['createElement']('video');return'string'==typeof _0x518796?(_0x5d754c['b']['SetCorsBehavior'](_0x518796,_0x209f20),_0x209f20['src']=_0x518796):(_0x5d754c['b']['SetCorsBehavior'](_0x518796[0x0],_0x209f20),_0x518796['forEach'](function(_0x179af0){var _0x173299=document['createElement']('source');_0x173299['src']=_0x179af0,_0x209f20['appendChild'](_0x173299);})),_0x209f20;},_0x298dec['prototype']['_rebuild']=function(){this['update']();},_0x298dec['prototype']['update']=function(){this['autoUpdateTexture']&&this['updateTexture'](!0x0);},_0x298dec['prototype']['updateTexture']=function(_0x444ad2){_0x444ad2&&(this['video']['paused']&&this['_stillImageCaptured']||(this['_stillImageCaptured']=!0x0,this['_updateInternalTexture']()));},_0x298dec['prototype']['updateURL']=function(_0x5c2b9e){this['video']['src']=_0x5c2b9e,this['_currentSrc']=_0x5c2b9e;},_0x298dec['prototype']['clone']=function(){return new _0x298dec(this['name'],this['_currentSrc'],this['getScene'](),this['_generateMipMaps'],this['invertY'],this['samplingMode'],this['_settings']);},_0x298dec['prototype']['dispose']=function(){_0x321701['prototype']['dispose']['call'](this),this['_currentSrc']=null,this['_onUserActionRequestedObservable']&&(this['_onUserActionRequestedObservable']['clear'](),this['_onUserActionRequestedObservable']=null),this['video']['removeEventListener'](this['_createInternalTextureOnEvent'],this['_createInternalTexture']),this['video']['removeEventListener']('paused',this['_updateInternalTexture']),this['video']['removeEventListener']('seeked',this['_updateInternalTexture']),this['video']['removeEventListener']('emptied',this['reset']),this['video']['pause']();},_0x298dec['CreateFromStreamAsync']=function(_0x1a3103,_0x1d8b33){var _0x63cef=document['createElement']('video');return _0x1a3103['getEngine']()['_badOS']&&(document['body']['appendChild'](_0x63cef),_0x63cef['style']['transform']='scale(0.0001,\x200.0001)',_0x63cef['style']['opacity']='0',_0x63cef['style']['position']='fixed',_0x63cef['style']['bottom']='0px',_0x63cef['style']['right']='0px'),_0x63cef['setAttribute']('autoplay',''),_0x63cef['setAttribute']('muted','true'),_0x63cef['setAttribute']('playsinline',''),_0x63cef['muted']=!0x0,void 0x0!==_0x63cef['mozSrcObject']?_0x63cef['mozSrcObject']=_0x1d8b33:'object'==typeof _0x63cef['srcObject']?_0x63cef['srcObject']=_0x1d8b33:(window['URL']=window['URL']||window['webkitURL']||window['mozURL']||window['msURL'],_0x63cef['src']=window['URL']&&window['URL']['createObjectURL'](_0x1d8b33)),new Promise(function(_0x3a42ea){var _0x40d524=function(){_0x3a42ea(new _0x298dec('video',_0x63cef,_0x1a3103,!0x0,!0x0)),_0x63cef['removeEventListener']('playing',_0x40d524);};_0x63cef['addEventListener']('playing',_0x40d524),_0x63cef['play']();});},_0x298dec['CreateFromWebCamAsync']=function(_0x51d689,_0x247f6a,_0x27cb70){var _0x1ba8f7,_0x38cd10=this;return void 0x0===_0x27cb70&&(_0x27cb70=!0x1),_0x247f6a&&_0x247f6a['deviceId']&&(_0x1ba8f7={'exact':_0x247f6a['deviceId']}),navigator['mediaDevices']?navigator['mediaDevices']['getUserMedia']({'video':_0x247f6a,'audio':_0x27cb70})['then'](function(_0x1684c4){return _0x38cd10['CreateFromStreamAsync'](_0x51d689,_0x1684c4);}):(navigator['getUserMedia']=navigator['getUserMedia']||navigator['webkitGetUserMedia']||navigator['mozGetUserMedia']||navigator['msGetUserMedia'],navigator['getUserMedia']&&navigator['getUserMedia']({'video':{'deviceId':_0x1ba8f7,'width':{'min':_0x247f6a&&_0x247f6a['minWidth']||0x100,'max':_0x247f6a&&_0x247f6a['maxWidth']||0x280},'height':{'min':_0x247f6a&&_0x247f6a['minHeight']||0x100,'max':_0x247f6a&&_0x247f6a['maxHeight']||0x1e0}},'audio':_0x27cb70},function(_0x16461f){return _0x38cd10['CreateFromStreamAsync'](_0x51d689,_0x16461f);},function(_0x3d7b55){_0x75193d['a']['Error'](_0x3d7b55['name']);}),Promise['reject']('No\x20support\x20for\x20userMedia\x20on\x20this\x20device'));},_0x298dec['CreateFromWebCam']=function(_0x35cbbf,_0x2ae9b4,_0x45845d,_0x1013f7){void 0x0===_0x1013f7&&(_0x1013f7=!0x1),this['CreateFromWebCamAsync'](_0x35cbbf,_0x45845d,_0x1013f7)['then'](function(_0x54ec05){_0x2ae9b4&&_0x2ae9b4(_0x54ec05);})['catch'](function(_0x4e4baf){_0x75193d['a']['Error'](_0x4e4baf['name']);});},_0x298dec;}(_0xaf3c80['a']),_0xcbcd01=function(_0x4e3a6f){function _0x57985e(){return null!==_0x4e3a6f&&_0x4e3a6f['apply'](this,arguments)||this;}return Object(_0x18e13d['d'])(_0x57985e,_0x4e3a6f),Object['defineProperty'](_0x57985e['prototype'],'videoTexture',{'get':function(){return this['_texture'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x57985e['prototype'],'videoMode',{'get':function(){return this['textureMode'];},'set':function(_0x10167){this['textureMode']=_0x10167;},'enumerable':!0x1,'configurable':!0x0}),_0x57985e['prototype']['_initTexture']=function(_0x2a3e52,_0x3abdd9,_0x13ca31){var _0x3b600b=this,_0x1ee9ef={'loop':_0x13ca31['loop'],'autoPlay':_0x13ca31['autoPlay'],'autoUpdateTexture':!0x0,'poster':_0x13ca31['poster']},_0x510dbc=new _0x411196((this['name']||'videoDome')+'_texture',_0x2a3e52,_0x3abdd9,_0x13ca31['generateMipMaps'],this['_useDirectMapping'],_0xaf3c80['a']['TRILINEAR_SAMPLINGMODE'],_0x1ee9ef);return _0x13ca31['clickToPlay']&&(_0x3abdd9['onPointerUp']=function(){_0x3b600b['_texture']['video']['play']();}),_0x510dbc;},_0x57985e['MODE_MONOSCOPIC']=_0x2e2b5['MODE_MONOSCOPIC'],_0x57985e['MODE_TOPBOTTOM']=_0x2e2b5['MODE_TOPBOTTOM'],_0x57985e['MODE_SIDEBYSIDE']=_0x2e2b5['MODE_SIDEBYSIDE'],_0x57985e;}(_0x2e2b5),_0x177abf=_0x162675(0x37),_0x235e55=(function(){function _0x153ddf(_0x1e4064){this['engine']=_0x1e4064,this['_captureGPUFrameTime']=!0x1,this['_gpuFrameTime']=new _0x177abf['a'](),this['_captureShaderCompilationTime']=!0x1,this['_shaderCompilationTime']=new _0x177abf['a'](),this['_onBeginFrameObserver']=null,this['_onEndFrameObserver']=null,this['_onBeforeShaderCompilationObserver']=null,this['_onAfterShaderCompilationObserver']=null;}return Object['defineProperty'](_0x153ddf['prototype'],'gpuFrameTimeCounter',{'get':function(){return this['_gpuFrameTime'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x153ddf['prototype'],'captureGPUFrameTime',{'get':function(){return this['_captureGPUFrameTime'];},'set':function(_0x2503ed){var _0x43fbcb=this;_0x2503ed!==this['_captureGPUFrameTime']&&(this['_captureGPUFrameTime']=_0x2503ed,_0x2503ed?(this['_onBeginFrameObserver']=this['engine']['onBeginFrameObservable']['add'](function(){_0x43fbcb['_gpuFrameTimeToken']||(_0x43fbcb['_gpuFrameTimeToken']=_0x43fbcb['engine']['startTimeQuery']());}),this['_onEndFrameObserver']=this['engine']['onEndFrameObservable']['add'](function(){if(_0x43fbcb['_gpuFrameTimeToken']){var _0x543afc=_0x43fbcb['engine']['endTimeQuery'](_0x43fbcb['_gpuFrameTimeToken']);_0x543afc>-0x1&&(_0x43fbcb['_gpuFrameTimeToken']=null,_0x43fbcb['_gpuFrameTime']['fetchNewFrame'](),_0x43fbcb['_gpuFrameTime']['addCount'](_0x543afc,!0x0));}})):(this['engine']['onBeginFrameObservable']['remove'](this['_onBeginFrameObserver']),this['_onBeginFrameObserver']=null,this['engine']['onEndFrameObservable']['remove'](this['_onEndFrameObserver']),this['_onEndFrameObserver']=null));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x153ddf['prototype'],'shaderCompilationTimeCounter',{'get':function(){return this['_shaderCompilationTime'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x153ddf['prototype'],'captureShaderCompilationTime',{'get':function(){return this['_captureShaderCompilationTime'];},'set':function(_0x1d4ffa){var _0x252f94=this;_0x1d4ffa!==this['_captureShaderCompilationTime']&&(this['_captureShaderCompilationTime']=_0x1d4ffa,_0x1d4ffa?(this['_onBeforeShaderCompilationObserver']=this['engine']['onBeforeShaderCompilationObservable']['add'](function(){_0x252f94['_shaderCompilationTime']['fetchNewFrame'](),_0x252f94['_shaderCompilationTime']['beginMonitoring']();}),this['_onAfterShaderCompilationObserver']=this['engine']['onAfterShaderCompilationObservable']['add'](function(){_0x252f94['_shaderCompilationTime']['endMonitoring']();})):(this['engine']['onBeforeShaderCompilationObservable']['remove'](this['_onBeforeShaderCompilationObserver']),this['_onBeforeShaderCompilationObserver']=null,this['engine']['onAfterShaderCompilationObservable']['remove'](this['_onAfterShaderCompilationObserver']),this['_onAfterShaderCompilationObserver']=null));},'enumerable':!0x1,'configurable':!0x0}),_0x153ddf['prototype']['dispose']=function(){this['engine']['onBeginFrameObservable']['remove'](this['_onBeginFrameObserver']),this['_onBeginFrameObserver']=null,this['engine']['onEndFrameObservable']['remove'](this['_onEndFrameObserver']),this['_onEndFrameObserver']=null,this['engine']['onBeforeShaderCompilationObservable']['remove'](this['_onBeforeShaderCompilationObserver']),this['_onBeforeShaderCompilationObserver']=null,this['engine']['onAfterShaderCompilationObservable']['remove'](this['_onAfterShaderCompilationObserver']),this['_onAfterShaderCompilationObserver']=null,this['engine']=null;},_0x153ddf;}()),_0xe36a6b=(function(){function _0x4fb936(_0x41f982){var _0x168b3e=this;this['scene']=_0x41f982,this['_captureActiveMeshesEvaluationTime']=!0x1,this['_activeMeshesEvaluationTime']=new _0x177abf['a'](),this['_captureRenderTargetsRenderTime']=!0x1,this['_renderTargetsRenderTime']=new _0x177abf['a'](),this['_captureFrameTime']=!0x1,this['_frameTime']=new _0x177abf['a'](),this['_captureRenderTime']=!0x1,this['_renderTime']=new _0x177abf['a'](),this['_captureInterFrameTime']=!0x1,this['_interFrameTime']=new _0x177abf['a'](),this['_captureParticlesRenderTime']=!0x1,this['_particlesRenderTime']=new _0x177abf['a'](),this['_captureSpritesRenderTime']=!0x1,this['_spritesRenderTime']=new _0x177abf['a'](),this['_capturePhysicsTime']=!0x1,this['_physicsTime']=new _0x177abf['a'](),this['_captureAnimationsTime']=!0x1,this['_animationsTime']=new _0x177abf['a'](),this['_captureCameraRenderTime']=!0x1,this['_cameraRenderTime']=new _0x177abf['a'](),this['_onBeforeActiveMeshesEvaluationObserver']=null,this['_onAfterActiveMeshesEvaluationObserver']=null,this['_onBeforeRenderTargetsRenderObserver']=null,this['_onAfterRenderTargetsRenderObserver']=null,this['_onAfterRenderObserver']=null,this['_onBeforeDrawPhaseObserver']=null,this['_onAfterDrawPhaseObserver']=null,this['_onBeforeAnimationsObserver']=null,this['_onBeforeParticlesRenderingObserver']=null,this['_onAfterParticlesRenderingObserver']=null,this['_onBeforeSpritesRenderingObserver']=null,this['_onAfterSpritesRenderingObserver']=null,this['_onBeforePhysicsObserver']=null,this['_onAfterPhysicsObserver']=null,this['_onAfterAnimationsObserver']=null,this['_onBeforeCameraRenderObserver']=null,this['_onAfterCameraRenderObserver']=null,this['_onBeforeAnimationsObserver']=_0x41f982['onBeforeAnimationsObservable']['add'](function(){_0x168b3e['_captureActiveMeshesEvaluationTime']&&_0x168b3e['_activeMeshesEvaluationTime']['fetchNewFrame'](),_0x168b3e['_captureRenderTargetsRenderTime']&&_0x168b3e['_renderTargetsRenderTime']['fetchNewFrame'](),_0x168b3e['_captureFrameTime']&&(_0x5d754c['b']['StartPerformanceCounter']('Scene\x20rendering'),_0x168b3e['_frameTime']['beginMonitoring']()),_0x168b3e['_captureInterFrameTime']&&_0x168b3e['_interFrameTime']['endMonitoring'](),_0x168b3e['_captureParticlesRenderTime']&&_0x168b3e['_particlesRenderTime']['fetchNewFrame'](),_0x168b3e['_captureSpritesRenderTime']&&_0x168b3e['_spritesRenderTime']['fetchNewFrame'](),_0x168b3e['_captureAnimationsTime']&&_0x168b3e['_animationsTime']['beginMonitoring'](),_0x168b3e['scene']['getEngine']()['_drawCalls']['fetchNewFrame']();}),this['_onAfterRenderObserver']=_0x41f982['onAfterRenderObservable']['add'](function(){_0x168b3e['_captureFrameTime']&&(_0x5d754c['b']['EndPerformanceCounter']('Scene\x20rendering'),_0x168b3e['_frameTime']['endMonitoring']()),_0x168b3e['_captureRenderTime']&&_0x168b3e['_renderTime']['endMonitoring'](!0x1),_0x168b3e['_captureInterFrameTime']&&_0x168b3e['_interFrameTime']['beginMonitoring']();});}return Object['defineProperty'](_0x4fb936['prototype'],'activeMeshesEvaluationTimeCounter',{'get':function(){return this['_activeMeshesEvaluationTime'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4fb936['prototype'],'captureActiveMeshesEvaluationTime',{'get':function(){return this['_captureActiveMeshesEvaluationTime'];},'set':function(_0xa226b3){var _0x1e63b0=this;_0xa226b3!==this['_captureActiveMeshesEvaluationTime']&&(this['_captureActiveMeshesEvaluationTime']=_0xa226b3,_0xa226b3?(this['_onBeforeActiveMeshesEvaluationObserver']=this['scene']['onBeforeActiveMeshesEvaluationObservable']['add'](function(){_0x5d754c['b']['StartPerformanceCounter']('Active\x20meshes\x20evaluation'),_0x1e63b0['_activeMeshesEvaluationTime']['beginMonitoring']();}),this['_onAfterActiveMeshesEvaluationObserver']=this['scene']['onAfterActiveMeshesEvaluationObservable']['add'](function(){_0x5d754c['b']['EndPerformanceCounter']('Active\x20meshes\x20evaluation'),_0x1e63b0['_activeMeshesEvaluationTime']['endMonitoring']();})):(this['scene']['onBeforeActiveMeshesEvaluationObservable']['remove'](this['_onBeforeActiveMeshesEvaluationObserver']),this['_onBeforeActiveMeshesEvaluationObserver']=null,this['scene']['onAfterActiveMeshesEvaluationObservable']['remove'](this['_onAfterActiveMeshesEvaluationObserver']),this['_onAfterActiveMeshesEvaluationObserver']=null));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4fb936['prototype'],'renderTargetsRenderTimeCounter',{'get':function(){return this['_renderTargetsRenderTime'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4fb936['prototype'],'captureRenderTargetsRenderTime',{'get':function(){return this['_captureRenderTargetsRenderTime'];},'set':function(_0x3186c5){var _0xb141e6=this;_0x3186c5!==this['_captureRenderTargetsRenderTime']&&(this['_captureRenderTargetsRenderTime']=_0x3186c5,_0x3186c5?(this['_onBeforeRenderTargetsRenderObserver']=this['scene']['onBeforeRenderTargetsRenderObservable']['add'](function(){_0x5d754c['b']['StartPerformanceCounter']('Render\x20targets\x20rendering'),_0xb141e6['_renderTargetsRenderTime']['beginMonitoring']();}),this['_onAfterRenderTargetsRenderObserver']=this['scene']['onAfterRenderTargetsRenderObservable']['add'](function(){_0x5d754c['b']['EndPerformanceCounter']('Render\x20targets\x20rendering'),_0xb141e6['_renderTargetsRenderTime']['endMonitoring'](!0x1);})):(this['scene']['onBeforeRenderTargetsRenderObservable']['remove'](this['_onBeforeRenderTargetsRenderObserver']),this['_onBeforeRenderTargetsRenderObserver']=null,this['scene']['onAfterRenderTargetsRenderObservable']['remove'](this['_onAfterRenderTargetsRenderObserver']),this['_onAfterRenderTargetsRenderObserver']=null));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4fb936['prototype'],'particlesRenderTimeCounter',{'get':function(){return this['_particlesRenderTime'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4fb936['prototype'],'captureParticlesRenderTime',{'get':function(){return this['_captureParticlesRenderTime'];},'set':function(_0x47e712){var _0x585e5a=this;_0x47e712!==this['_captureParticlesRenderTime']&&(this['_captureParticlesRenderTime']=_0x47e712,_0x47e712?(this['_onBeforeParticlesRenderingObserver']=this['scene']['onBeforeParticlesRenderingObservable']['add'](function(){_0x5d754c['b']['StartPerformanceCounter']('Particles'),_0x585e5a['_particlesRenderTime']['beginMonitoring']();}),this['_onAfterParticlesRenderingObserver']=this['scene']['onAfterParticlesRenderingObservable']['add'](function(){_0x5d754c['b']['EndPerformanceCounter']('Particles'),_0x585e5a['_particlesRenderTime']['endMonitoring'](!0x1);})):(this['scene']['onBeforeParticlesRenderingObservable']['remove'](this['_onBeforeParticlesRenderingObserver']),this['_onBeforeParticlesRenderingObserver']=null,this['scene']['onAfterParticlesRenderingObservable']['remove'](this['_onAfterParticlesRenderingObserver']),this['_onAfterParticlesRenderingObserver']=null));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4fb936['prototype'],'spritesRenderTimeCounter',{'get':function(){return this['_spritesRenderTime'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4fb936['prototype'],'captureSpritesRenderTime',{'get':function(){return this['_captureSpritesRenderTime'];},'set':function(_0x142ea4){var _0x2dd9e6=this;_0x142ea4!==this['_captureSpritesRenderTime']&&(this['_captureSpritesRenderTime']=_0x142ea4,this['scene']['spriteManagers']&&(_0x142ea4?(this['_onBeforeSpritesRenderingObserver']=this['scene']['onBeforeSpritesRenderingObservable']['add'](function(){_0x5d754c['b']['StartPerformanceCounter']('Sprites'),_0x2dd9e6['_spritesRenderTime']['beginMonitoring']();}),this['_onAfterSpritesRenderingObserver']=this['scene']['onAfterSpritesRenderingObservable']['add'](function(){_0x5d754c['b']['EndPerformanceCounter']('Sprites'),_0x2dd9e6['_spritesRenderTime']['endMonitoring'](!0x1);})):(this['scene']['onBeforeSpritesRenderingObservable']['remove'](this['_onBeforeSpritesRenderingObserver']),this['_onBeforeSpritesRenderingObserver']=null,this['scene']['onAfterSpritesRenderingObservable']['remove'](this['_onAfterSpritesRenderingObserver']),this['_onAfterSpritesRenderingObserver']=null)));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4fb936['prototype'],'physicsTimeCounter',{'get':function(){return this['_physicsTime'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4fb936['prototype'],'capturePhysicsTime',{'get':function(){return this['_capturePhysicsTime'];},'set':function(_0x3a3f72){var _0x4eea95=this;_0x3a3f72!==this['_capturePhysicsTime']&&this['scene']['onBeforePhysicsObservable']&&(this['_capturePhysicsTime']=_0x3a3f72,_0x3a3f72?(this['_onBeforePhysicsObserver']=this['scene']['onBeforePhysicsObservable']['add'](function(){_0x5d754c['b']['StartPerformanceCounter']('Physics'),_0x4eea95['_physicsTime']['beginMonitoring']();}),this['_onAfterPhysicsObserver']=this['scene']['onAfterPhysicsObservable']['add'](function(){_0x5d754c['b']['EndPerformanceCounter']('Physics'),_0x4eea95['_physicsTime']['endMonitoring']();})):(this['scene']['onBeforePhysicsObservable']['remove'](this['_onBeforePhysicsObserver']),this['_onBeforePhysicsObserver']=null,this['scene']['onAfterPhysicsObservable']['remove'](this['_onAfterPhysicsObserver']),this['_onAfterPhysicsObserver']=null));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4fb936['prototype'],'animationsTimeCounter',{'get':function(){return this['_animationsTime'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4fb936['prototype'],'captureAnimationsTime',{'get':function(){return this['_captureAnimationsTime'];},'set':function(_0x1ea7ab){var _0x5ebbb7=this;_0x1ea7ab!==this['_captureAnimationsTime']&&(this['_captureAnimationsTime']=_0x1ea7ab,_0x1ea7ab?this['_onAfterAnimationsObserver']=this['scene']['onAfterAnimationsObservable']['add'](function(){_0x5ebbb7['_animationsTime']['endMonitoring']();}):(this['scene']['onAfterAnimationsObservable']['remove'](this['_onAfterAnimationsObserver']),this['_onAfterAnimationsObserver']=null));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4fb936['prototype'],'frameTimeCounter',{'get':function(){return this['_frameTime'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4fb936['prototype'],'captureFrameTime',{'get':function(){return this['_captureFrameTime'];},'set':function(_0x463349){this['_captureFrameTime']=_0x463349;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4fb936['prototype'],'interFrameTimeCounter',{'get':function(){return this['_interFrameTime'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4fb936['prototype'],'captureInterFrameTime',{'get':function(){return this['_captureInterFrameTime'];},'set':function(_0x364edd){this['_captureInterFrameTime']=_0x364edd;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4fb936['prototype'],'renderTimeCounter',{'get':function(){return this['_renderTime'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4fb936['prototype'],'captureRenderTime',{'get':function(){return this['_captureRenderTime'];},'set':function(_0x1659bd){var _0x31c5e1=this;_0x1659bd!==this['_captureRenderTime']&&(this['_captureRenderTime']=_0x1659bd,_0x1659bd?(this['_onBeforeDrawPhaseObserver']=this['scene']['onBeforeDrawPhaseObservable']['add'](function(){_0x31c5e1['_renderTime']['beginMonitoring'](),_0x5d754c['b']['StartPerformanceCounter']('Main\x20render');}),this['_onAfterDrawPhaseObserver']=this['scene']['onAfterDrawPhaseObservable']['add'](function(){_0x31c5e1['_renderTime']['endMonitoring'](!0x1),_0x5d754c['b']['EndPerformanceCounter']('Main\x20render');})):(this['scene']['onBeforeDrawPhaseObservable']['remove'](this['_onBeforeDrawPhaseObserver']),this['_onBeforeDrawPhaseObserver']=null,this['scene']['onAfterDrawPhaseObservable']['remove'](this['_onAfterDrawPhaseObserver']),this['_onAfterDrawPhaseObserver']=null));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4fb936['prototype'],'cameraRenderTimeCounter',{'get':function(){return this['_cameraRenderTime'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4fb936['prototype'],'captureCameraRenderTime',{'get':function(){return this['_captureCameraRenderTime'];},'set':function(_0x1939c0){var _0x444b22=this;_0x1939c0!==this['_captureCameraRenderTime']&&(this['_captureCameraRenderTime']=_0x1939c0,_0x1939c0?(this['_onBeforeCameraRenderObserver']=this['scene']['onBeforeCameraRenderObservable']['add'](function(_0x55563a){_0x444b22['_cameraRenderTime']['beginMonitoring'](),_0x5d754c['b']['StartPerformanceCounter']('Rendering\x20camera\x20'+_0x55563a['name']);}),this['_onAfterCameraRenderObserver']=this['scene']['onAfterCameraRenderObservable']['add'](function(_0x23ff6a){_0x444b22['_cameraRenderTime']['endMonitoring'](!0x1),_0x5d754c['b']['EndPerformanceCounter']('Rendering\x20camera\x20'+_0x23ff6a['name']);})):(this['scene']['onBeforeCameraRenderObservable']['remove'](this['_onBeforeCameraRenderObserver']),this['_onBeforeCameraRenderObserver']=null,this['scene']['onAfterCameraRenderObservable']['remove'](this['_onAfterCameraRenderObserver']),this['_onAfterCameraRenderObserver']=null));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4fb936['prototype'],'drawCallsCounter',{'get':function(){return this['scene']['getEngine']()['_drawCalls'];},'enumerable':!0x1,'configurable':!0x0}),_0x4fb936['prototype']['dispose']=function(){this['scene']['onAfterRenderObservable']['remove'](this['_onAfterRenderObserver']),this['_onAfterRenderObserver']=null,this['scene']['onBeforeActiveMeshesEvaluationObservable']['remove'](this['_onBeforeActiveMeshesEvaluationObserver']),this['_onBeforeActiveMeshesEvaluationObserver']=null,this['scene']['onAfterActiveMeshesEvaluationObservable']['remove'](this['_onAfterActiveMeshesEvaluationObserver']),this['_onAfterActiveMeshesEvaluationObserver']=null,this['scene']['onBeforeRenderTargetsRenderObservable']['remove'](this['_onBeforeRenderTargetsRenderObserver']),this['_onBeforeRenderTargetsRenderObserver']=null,this['scene']['onAfterRenderTargetsRenderObservable']['remove'](this['_onAfterRenderTargetsRenderObserver']),this['_onAfterRenderTargetsRenderObserver']=null,this['scene']['onBeforeAnimationsObservable']['remove'](this['_onBeforeAnimationsObserver']),this['_onBeforeAnimationsObserver']=null,this['scene']['onBeforeParticlesRenderingObservable']['remove'](this['_onBeforeParticlesRenderingObserver']),this['_onBeforeParticlesRenderingObserver']=null,this['scene']['onAfterParticlesRenderingObservable']['remove'](this['_onAfterParticlesRenderingObserver']),this['_onAfterParticlesRenderingObserver']=null,this['_onBeforeSpritesRenderingObserver']&&(this['scene']['onBeforeSpritesRenderingObservable']['remove'](this['_onBeforeSpritesRenderingObserver']),this['_onBeforeSpritesRenderingObserver']=null),this['_onAfterSpritesRenderingObserver']&&(this['scene']['onAfterSpritesRenderingObservable']['remove'](this['_onAfterSpritesRenderingObserver']),this['_onAfterSpritesRenderingObserver']=null),this['scene']['onBeforeDrawPhaseObservable']['remove'](this['_onBeforeDrawPhaseObserver']),this['_onBeforeDrawPhaseObserver']=null,this['scene']['onAfterDrawPhaseObservable']['remove'](this['_onAfterDrawPhaseObserver']),this['_onAfterDrawPhaseObserver']=null,this['_onBeforePhysicsObserver']&&(this['scene']['onBeforePhysicsObservable']['remove'](this['_onBeforePhysicsObserver']),this['_onBeforePhysicsObserver']=null),this['_onAfterPhysicsObserver']&&(this['scene']['onAfterPhysicsObservable']['remove'](this['_onAfterPhysicsObserver']),this['_onAfterPhysicsObserver']=null),this['scene']['onAfterAnimationsObservable']['remove'](this['_onAfterAnimationsObserver']),this['_onAfterAnimationsObserver']=null,this['scene']['onBeforeCameraRenderObservable']['remove'](this['_onBeforeCameraRenderObserver']),this['_onBeforeCameraRenderObserver']=null,this['scene']['onAfterCameraRenderObservable']['remove'](this['_onAfterCameraRenderObserver']),this['_onAfterCameraRenderObserver']=null,this['scene']=null;},_0x4fb936;}()),_0x3ebae2='#ifdef\x20DIFFUSE\x0avarying\x20vec2\x20vUVDiffuse;\x0auniform\x20sampler2D\x20diffuseSampler;\x0a#endif\x0a#ifdef\x20OPACITY\x0avarying\x20vec2\x20vUVOpacity;\x0auniform\x20sampler2D\x20opacitySampler;\x0auniform\x20float\x20opacityIntensity;\x0a#endif\x0a#ifdef\x20EMISSIVE\x0avarying\x20vec2\x20vUVEmissive;\x0auniform\x20sampler2D\x20emissiveSampler;\x0a#endif\x0a#ifdef\x20VERTEXALPHA\x0avarying\x20vec4\x20vColor;\x0a#endif\x0auniform\x20vec4\x20glowColor;\x0avoid\x20main(void)\x0a{\x0avec4\x20finalColor=glowColor;\x0a\x0a#ifdef\x20DIFFUSE\x0avec4\x20albedoTexture=texture2D(diffuseSampler,vUVDiffuse);\x0a#ifdef\x20GLOW\x0a\x0afinalColor.a*=albedoTexture.a;\x0a#endif\x0a#ifdef\x20HIGHLIGHT\x0a\x0afinalColor.a=albedoTexture.a;\x0a#endif\x0a#endif\x0a#ifdef\x20OPACITY\x0avec4\x20opacityMap=texture2D(opacitySampler,vUVOpacity);\x0a#ifdef\x20OPACITYRGB\x0afinalColor.a*=getLuminance(opacityMap.rgb);\x0a#else\x0afinalColor.a*=opacityMap.a;\x0a#endif\x0afinalColor.a*=opacityIntensity;\x0a#endif\x0a#ifdef\x20VERTEXALPHA\x0afinalColor.a*=vColor.a;\x0a#endif\x0a#ifdef\x20ALPHATEST\x0aif\x20(finalColor.a0x4&&(_0x3f9614['push'](_0x212fbd['b']['MatricesIndicesExtraKind']),_0x3f9614['push'](_0x212fbd['b']['MatricesWeightsExtraKind'])),_0x2fcce5['push']('#define\x20NUM_BONE_INFLUENCERS\x20'+_0xc06de8['numBoneInfluencers']);var _0x1bd233=_0xc06de8['skeleton'];_0x1bd233&&_0x1bd233['isUsingTextureForMatrices']?_0x2fcce5['push']('#define\x20BONETEXTURE'):_0x2fcce5['push']('#define\x20BonesPerMesh\x20'+(_0x1bd233?_0x1bd233['bones']['length']+0x1:0x0)),_0xc06de8['numBoneInfluencers']>0x0&&_0x401028['addCPUSkinningFallback'](0x0,_0xc06de8);}else _0x2fcce5['push']('#define\x20NUM_BONE_INFLUENCERS\x200');var _0x2a8a63=_0xc06de8['morphTargetManager'],_0x56c85e=0x0;_0x2a8a63&&_0x2a8a63['numInfluencers']>0x0&&(_0x2fcce5['push']('#define\x20MORPHTARGETS'),_0x56c85e=_0x2a8a63['numInfluencers'],_0x2fcce5['push']('#define\x20NUM_MORPH_INFLUENCERS\x20'+_0x56c85e),_0x464f31['a']['PrepareAttributesForMorphTargetsInfluencers'](_0x3f9614,_0xc06de8,_0x56c85e)),_0x549df2&&(_0x2fcce5['push']('#define\x20INSTANCES'),_0x464f31['a']['PushAttributesForInstances'](_0x3f9614),_0xdeca2c['getRenderingMesh']()['hasThinInstances']&&_0x2fcce5['push']('#define\x20THIN_INSTANCES')),this['_addCustomEffectDefines'](_0x2fcce5);var _0x5503a1=_0x2fcce5['join']('\x0a');return this['_cachedDefines']!==_0x5503a1&&(this['_cachedDefines']=_0x5503a1,this['_effectLayerMapGenerationEffect']=this['_scene']['getEngine']()['createEffect']('glowMapGeneration',_0x3f9614,['world','mBones','viewProjection','glowColor','morphTargetInfluences','boneTextureWidth','diffuseMatrix','emissiveMatrix','opacityMatrix','opacityIntensity'],['diffuseSampler','emissiveSampler','opacitySampler','boneSampler'],_0x5503a1,_0x401028,void 0x0,void 0x0,{'maxSimultaneousMorphTargets':_0x56c85e})),this['_effectLayerMapGenerationEffect']['isReady']();},_0x195f3a['prototype']['render']=function(){var _0x6918c7=this['_mergeEffect'];if(_0x6918c7['isReady']()){for(var _0x179e2f=0x0;_0x179e2f-0x1&&this['_scene']['effectLayers']['splice'](_0xf3dd04,0x1),this['onDisposeObservable']['notifyObservers'](this),this['onDisposeObservable']['clear'](),this['onBeforeRenderMainTextureObservable']['clear'](),this['onBeforeComposeObservable']['clear'](),this['onBeforeRenderMeshToEffect']['clear'](),this['onAfterRenderMeshToEffect']['clear'](),this['onAfterComposeObservable']['clear'](),this['onSizeChangedObservable']['clear']();},_0x195f3a['prototype']['getClassName']=function(){return'EffectLayer';},_0x195f3a['Parse']=function(_0x4165c5,_0x28bd68,_0x4721f9){return _0x5d754c['b']['Instantiate'](_0x4165c5['customType'])['Parse'](_0x4165c5,_0x28bd68,_0x4721f9);},_0x195f3a['_SceneComponentInitialization']=function(_0x40b222){throw _0x2de344['a']['WarnImport']('EffectLayerSceneComponent');},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x195f3a['prototype'],'name',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['f'])()],_0x195f3a['prototype'],'neutralColor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x195f3a['prototype'],'isEnabled',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['d'])()],_0x195f3a['prototype'],'camera',null),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x195f3a['prototype'],'renderingGroupId',null),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x195f3a['prototype'],'disableBoundingBoxesFromEffectLayer',void 0x0),_0x195f3a;}());_0x3598db['a']['AddParser'](_0x384de3['a']['NAME_EFFECTLAYER'],function(_0x16fcfe,_0x312155,_0x2454ae,_0x2a07c1){if(_0x16fcfe['effectLayers']){_0x2454ae['effectLayers']||(_0x2454ae['effectLayers']=new Array());for(var _0x4301ed=0x0;_0x4301ed<_0x16fcfe['effectLayers']['length'];_0x4301ed++){var _0x23ca67=_0x1fb328['Parse'](_0x16fcfe['effectLayers'][_0x4301ed],_0x312155,_0x2a07c1);_0x2454ae['effectLayers']['push'](_0x23ca67);}}}),_0x3598db['a']['prototype']['removeEffectLayer']=function(_0x2f5270){var _0x148989=this['effectLayers']['indexOf'](_0x2f5270);return-0x1!==_0x148989&&this['effectLayers']['splice'](_0x148989,0x1),_0x148989;},_0x3598db['a']['prototype']['addEffectLayer']=function(_0x3d1266){this['effectLayers']['push'](_0x3d1266);};var _0x3c6a4a=(function(){function _0x4b4bf3(_0x3aa777){this['name']=_0x384de3['a']['NAME_EFFECTLAYER'],this['_renderEffects']=!0x1,this['_needStencil']=!0x1,this['_previousStencilState']=!0x1,this['scene']=_0x3aa777,this['_engine']=_0x3aa777['getEngine'](),_0x3aa777['effectLayers']=new Array();}return _0x4b4bf3['prototype']['register']=function(){this['scene']['_isReadyForMeshStage']['registerStep'](_0x384de3['a']['STEP_ISREADYFORMESH_EFFECTLAYER'],this,this['_isReadyForMesh']),this['scene']['_cameraDrawRenderTargetStage']['registerStep'](_0x384de3['a']['STEP_CAMERADRAWRENDERTARGET_EFFECTLAYER'],this,this['_renderMainTexture']),this['scene']['_beforeCameraDrawStage']['registerStep'](_0x384de3['a']['STEP_BEFORECAMERADRAW_EFFECTLAYER'],this,this['_setStencil']),this['scene']['_afterRenderingGroupDrawStage']['registerStep'](_0x384de3['a']['STEP_AFTERRENDERINGGROUPDRAW_EFFECTLAYER_DRAW'],this,this['_drawRenderingGroup']),this['scene']['_afterCameraDrawStage']['registerStep'](_0x384de3['a']['STEP_AFTERCAMERADRAW_EFFECTLAYER'],this,this['_setStencilBack']),this['scene']['_afterCameraDrawStage']['registerStep'](_0x384de3['a']['STEP_AFTERCAMERADRAW_EFFECTLAYER_DRAW'],this,this['_drawCamera']);},_0x4b4bf3['prototype']['rebuild']=function(){for(var _0x32a773=0x0,_0xe0146f=this['scene']['effectLayers'];_0x32a773<_0xe0146f['length'];_0x32a773++){_0xe0146f[_0x32a773]['_rebuild']();}},_0x4b4bf3['prototype']['serialize']=function(_0x186760){_0x186760['effectLayers']=[];for(var _0xa67931=0x0,_0x536db5=this['scene']['effectLayers'];_0xa67931<_0x536db5['length'];_0xa67931++){var _0x212d64=_0x536db5[_0xa67931];_0x212d64['serialize']&&_0x186760['effectLayers']['push'](_0x212d64['serialize']());}},_0x4b4bf3['prototype']['addFromContainer']=function(_0x3fb7c8){var _0x348bb6=this;_0x3fb7c8['effectLayers']&&_0x3fb7c8['effectLayers']['forEach'](function(_0x1b6b19){_0x348bb6['scene']['addEffectLayer'](_0x1b6b19);});},_0x4b4bf3['prototype']['removeFromContainer']=function(_0x119043,_0x5dae3d){var _0x539bf0=this;_0x119043['effectLayers']&&_0x119043['effectLayers']['forEach'](function(_0x21788f){_0x539bf0['scene']['removeEffectLayer'](_0x21788f),_0x5dae3d&&_0x21788f['dispose']();});},_0x4b4bf3['prototype']['dispose']=function(){for(var _0x3507f8=this['scene']['effectLayers'];_0x3507f8['length'];)_0x3507f8[0x0]['dispose']();},_0x4b4bf3['prototype']['_isReadyForMesh']=function(_0x18d62c,_0x2394c1){for(var _0x5bc745=0x0,_0x5b24b9=this['scene']['effectLayers'];_0x5bc745<_0x5b24b9['length'];_0x5bc745++){var _0x1a1293=_0x5b24b9[_0x5bc745];if(_0x1a1293['hasMesh'](_0x18d62c))for(var _0x450650=0x0,_0x2e48b5=_0x18d62c['subMeshes'];_0x450650<_0x2e48b5['length'];_0x450650++){var _0x3b1bf0=_0x2e48b5[_0x450650];if(!_0x1a1293['isReady'](_0x3b1bf0,_0x2394c1))return!0x1;}}return!0x0;},_0x4b4bf3['prototype']['_renderMainTexture']=function(_0x12fa58){this['_renderEffects']=!0x1,this['_needStencil']=!0x1;var _0x27ca1a=!0x1,_0x1101b7=this['scene']['effectLayers'];if(_0x1101b7&&_0x1101b7['length']>0x0){this['_previousStencilState']=this['_engine']['getStencilBuffer']();for(var _0x2a9e95=0x0,_0x38a075=_0x1101b7;_0x2a9e95<_0x38a075['length'];_0x2a9e95++){var _0x21c70a=_0x38a075[_0x2a9e95];if(_0x21c70a['shouldRender']()&&(!_0x21c70a['camera']||_0x21c70a['camera']['cameraRigMode']===_0x568729['a']['RIG_MODE_NONE']&&_0x12fa58===_0x21c70a['camera']||_0x21c70a['camera']['cameraRigMode']!==_0x568729['a']['RIG_MODE_NONE']&&_0x21c70a['camera']['_rigCameras']['indexOf'](_0x12fa58)>-0x1)){this['_renderEffects']=!0x0,this['_needStencil']=this['_needStencil']||_0x21c70a['needStencil']();var _0x4b40ef=_0x21c70a['_mainTexture'];_0x4b40ef['_shouldRender']()&&(this['scene']['incrementRenderId'](),_0x4b40ef['render'](!0x1,!0x1),_0x27ca1a=!0x0);}}this['scene']['incrementRenderId']();}return _0x27ca1a;},_0x4b4bf3['prototype']['_setStencil']=function(){this['_needStencil']&&this['_engine']['setStencilBuffer'](!0x0);},_0x4b4bf3['prototype']['_setStencilBack']=function(){this['_needStencil']&&this['_engine']['setStencilBuffer'](this['_previousStencilState']);},_0x4b4bf3['prototype']['_draw']=function(_0x37e159){if(this['_renderEffects']){this['_engine']['setDepthBuffer'](!0x1);for(var _0x145b1b=this['scene']['effectLayers'],_0x3ee72c=0x0;_0x3ee72c<_0x145b1b['length'];_0x3ee72c++){var _0x5e443d=_0x145b1b[_0x3ee72c];_0x5e443d['renderingGroupId']===_0x37e159&&_0x5e443d['shouldRender']()&&_0x5e443d['render']();}this['_engine']['setDepthBuffer'](!0x0);}},_0x4b4bf3['prototype']['_drawCamera']=function(){this['_renderEffects']&&this['_draw'](-0x1);},_0x4b4bf3['prototype']['_drawRenderingGroup']=function(_0x32b610){!this['scene']['_isInIntermediateRendering']()&&this['_renderEffects']&&this['_draw'](_0x32b610);},_0x4b4bf3;}());_0x1fb328['_SceneComponentInitialization']=function(_0x5c834a){var _0x243c4d=_0x5c834a['_getComponent'](_0x384de3['a']['NAME_EFFECTLAYER']);_0x243c4d||(_0x243c4d=new _0x3c6a4a(_0x5c834a),_0x5c834a['_addComponent'](_0x243c4d));};var _0x20a588='\x0avarying\x20vec2\x20vUV;\x0auniform\x20sampler2D\x20textureSampler;\x0a#ifdef\x20EMISSIVE\x0auniform\x20sampler2D\x20textureSampler2;\x0a#endif\x0a\x0auniform\x20float\x20offset;\x0avoid\x20main(void)\x20{\x0avec4\x20baseColor=texture2D(textureSampler,vUV);\x0a#ifdef\x20EMISSIVE\x0abaseColor+=texture2D(textureSampler2,vUV);\x0abaseColor*=offset;\x0a#else\x0abaseColor.a=abs(offset-baseColor.a);\x0a#ifdef\x20STROKE\x0afloat\x20alpha=smoothstep(.0,.1,baseColor.a);\x0abaseColor.a=alpha;\x0abaseColor.rgb=baseColor.rgb*alpha;\x0a#endif\x0a#endif\x0agl_FragColor=baseColor;\x0a}';_0x494b01['a']['ShadersStore']['glowMapMergePixelShader']=_0x20a588;var _0x4df6fd='\x0aattribute\x20vec2\x20position;\x0a\x0avarying\x20vec2\x20vUV;\x0aconst\x20vec2\x20madd=vec2(0.5,0.5);\x0avoid\x20main(void)\x20{\x0avUV=position*madd+madd;\x0agl_Position=vec4(position,0.0,1.0);\x0a}';_0x494b01['a']['ShadersStore']['glowMapMergeVertexShader']=_0x4df6fd,_0x3598db['a']['prototype']['getGlowLayerByName']=function(_0x1c0fff){for(var _0x58db5c=0x0;_0x58db5c-0x1;},_0x55b36c['prototype']['referenceMeshToUseItsOwnMaterial']=function(_0x5cb897){this['_meshesUsingTheirOwnMaterials']['push'](_0x5cb897['uniqueId']);},_0x55b36c['prototype']['unReferenceMeshFromUsingItsOwnMaterial']=function(_0xfd16fa){for(var _0x25cc74=this['_meshesUsingTheirOwnMaterials']['indexOf'](_0xfd16fa['uniqueId']);_0x25cc74>=0x0;)this['_meshesUsingTheirOwnMaterials']['splice'](_0x25cc74,0x1),_0x25cc74=this['_meshesUsingTheirOwnMaterials']['indexOf'](_0xfd16fa['uniqueId']);},_0x55b36c['prototype']['_disposeMesh']=function(_0x2bd772){this['removeIncludedOnlyMesh'](_0x2bd772),this['removeExcludedMesh'](_0x2bd772);},_0x55b36c['prototype']['getClassName']=function(){return'GlowLayer';},_0x55b36c['prototype']['serialize']=function(){var _0x1d6c8e,_0x4f32c5=_0x495d06['a']['Serialize'](this);if(_0x4f32c5['customType']='BABYLON.GlowLayer',_0x4f32c5['includedMeshes']=[],this['_includedOnlyMeshes']['length'])for(_0x1d6c8e=0x0;_0x1d6c8e0x0&&_0x462ec4['isBackground']===_0x207097&&_0x462ec4['renderTargetTextures']['indexOf'](_0x46d6e2)>-0x1&&0x0!=(_0x462ec4['layerMask']&_0x160b28);},_0x2b2eb9['prototype']['_drawRenderTargetBackground']=function(_0x3a2239){var _0x382541=this;this['_draw'](function(_0x7f25cd){return _0x382541['_drawRenderTargetPredicate'](_0x7f25cd,!0x0,_0x382541['scene']['activeCamera']['layerMask'],_0x3a2239);});},_0x2b2eb9['prototype']['_drawRenderTargetForeground']=function(_0x1b85ea){var _0x19d2e6=this;this['_draw'](function(_0xb8e4cd){return _0x19d2e6['_drawRenderTargetPredicate'](_0xb8e4cd,!0x1,_0x19d2e6['scene']['activeCamera']['layerMask'],_0x1b85ea);});},_0x2b2eb9['prototype']['addFromContainer']=function(_0x49c913){var _0x384d46=this;_0x49c913['layers']&&_0x49c913['layers']['forEach'](function(_0x41e07a){_0x384d46['scene']['layers']['push'](_0x41e07a);});},_0x2b2eb9['prototype']['removeFromContainer']=function(_0x46aae9,_0x2aa3fa){var _0x160314=this;void 0x0===_0x2aa3fa&&(_0x2aa3fa=!0x1),_0x46aae9['layers']&&_0x46aae9['layers']['forEach'](function(_0x2ef4fe){var _0x50fcd0=_0x160314['scene']['layers']['indexOf'](_0x2ef4fe);-0x1!==_0x50fcd0&&_0x160314['scene']['layers']['splice'](_0x50fcd0,0x1),_0x2aa3fa&&_0x2ef4fe['dispose']();});},_0x2b2eb9;}()),_0x2def21='\x0avarying\x20vec2\x20vUV;\x0auniform\x20sampler2D\x20textureSampler;\x0a\x0auniform\x20vec4\x20color;\x0a\x0a#include\x0avoid\x20main(void)\x20{\x0avec4\x20baseColor=texture2D(textureSampler,vUV);\x0a#ifdef\x20LINEAR\x0abaseColor.rgb=toGammaSpace(baseColor.rgb);\x0a#endif\x0a#ifdef\x20ALPHATEST\x0aif\x20(baseColor.a<0.4)\x0adiscard;\x0a#endif\x0agl_FragColor=baseColor*color;\x0a}';_0x494b01['a']['ShadersStore']['layerPixelShader']=_0x2def21;var _0x3bdbaa='\x0aattribute\x20vec2\x20position;\x0a\x0auniform\x20vec2\x20scale;\x0auniform\x20vec2\x20offset;\x0auniform\x20mat4\x20textureMatrix;\x0a\x0avarying\x20vec2\x20vUV;\x0aconst\x20vec2\x20madd=vec2(0.5,0.5);\x0avoid\x20main(void)\x20{\x0avec2\x20shiftedPosition=position*scale+offset;\x0avUV=vec2(textureMatrix*vec4(shiftedPosition*madd+madd,1.0,0.0));\x0agl_Position=vec4(shiftedPosition,0.0,1.0);\x0a}';_0x494b01['a']['ShadersStore']['layerVertexShader']=_0x3bdbaa;var _0x688512=(function(){function _0x1bcb87(_0x2af250,_0x204ec8,_0x2417a9,_0x768a88,_0x3dbb6b){this['name']=_0x2af250,this['scale']=new _0x74d525['d'](0x1,0x1),this['offset']=new _0x74d525['d'](0x0,0x0),this['alphaBlendingMode']=_0x2103ba['a']['ALPHA_COMBINE'],this['layerMask']=0xfffffff,this['renderTargetTextures']=[],this['renderOnlyInRenderTargetTextures']=!0x1,this['_vertexBuffers']={},this['onDisposeObservable']=new _0x6ac1f7['c'](),this['onBeforeRenderObservable']=new _0x6ac1f7['c'](),this['onAfterRenderObservable']=new _0x6ac1f7['c'](),this['texture']=_0x204ec8?new _0xaf3c80['a'](_0x204ec8,_0x2417a9,!0x0):null,this['isBackground']=void 0x0===_0x768a88||_0x768a88,this['color']=void 0x0===_0x3dbb6b?new _0x39310d['b'](0x1,0x1,0x1,0x1):_0x3dbb6b,this['_scene']=_0x2417a9||_0x44b9ce['a']['LastCreatedScene'];var _0xf5b6bd=this['_scene']['_getComponent'](_0x384de3['a']['NAME_LAYER']);_0xf5b6bd||(_0xf5b6bd=new _0xf67129(this['_scene']),this['_scene']['_addComponent'](_0xf5b6bd)),this['_scene']['layers']['push'](this);var _0x3676b3=this['_scene']['getEngine'](),_0x3a45ec=[];_0x3a45ec['push'](0x1,0x1),_0x3a45ec['push'](-0x1,0x1),_0x3a45ec['push'](-0x1,-0x1),_0x3a45ec['push'](0x1,-0x1);var _0x146480=new _0x212fbd['b'](_0x3676b3,_0x3a45ec,_0x212fbd['b']['PositionKind'],!0x1,!0x1,0x2);this['_vertexBuffers'][_0x212fbd['b']['PositionKind']]=_0x146480,this['_createIndexBuffer']();}return Object['defineProperty'](_0x1bcb87['prototype'],'onDispose',{'set':function(_0x2b72d9){this['_onDisposeObserver']&&this['onDisposeObservable']['remove'](this['_onDisposeObserver']),this['_onDisposeObserver']=this['onDisposeObservable']['add'](_0x2b72d9);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1bcb87['prototype'],'onBeforeRender',{'set':function(_0x517153){this['_onBeforeRenderObserver']&&this['onBeforeRenderObservable']['remove'](this['_onBeforeRenderObserver']),this['_onBeforeRenderObserver']=this['onBeforeRenderObservable']['add'](_0x517153);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1bcb87['prototype'],'onAfterRender',{'set':function(_0x53618f){this['_onAfterRenderObserver']&&this['onAfterRenderObservable']['remove'](this['_onAfterRenderObserver']),this['_onAfterRenderObserver']=this['onAfterRenderObservable']['add'](_0x53618f);},'enumerable':!0x1,'configurable':!0x0}),_0x1bcb87['prototype']['_createIndexBuffer']=function(){var _0x25e86d=this['_scene']['getEngine'](),_0x2b0a5d=[];_0x2b0a5d['push'](0x0),_0x2b0a5d['push'](0x1),_0x2b0a5d['push'](0x2),_0x2b0a5d['push'](0x0),_0x2b0a5d['push'](0x2),_0x2b0a5d['push'](0x3),this['_indexBuffer']=_0x25e86d['createIndexBuffer'](_0x2b0a5d);},_0x1bcb87['prototype']['_rebuild']=function(){var _0x5aadcb=this['_vertexBuffers'][_0x212fbd['b']['PositionKind']];_0x5aadcb&&_0x5aadcb['_rebuild'](),this['_createIndexBuffer']();},_0x1bcb87['prototype']['render']=function(){var _0x18886c=this['_scene']['getEngine'](),_0x3ac6f3='';this['alphaTest']&&(_0x3ac6f3='#define\x20ALPHATEST'),this['texture']&&!this['texture']['gammaSpace']&&(_0x3ac6f3+='\x0d\x0a#define\x20LINEAR'),this['_previousDefines']!==_0x3ac6f3&&(this['_previousDefines']=_0x3ac6f3,this['_effect']=_0x18886c['createEffect']('layer',[_0x212fbd['b']['PositionKind']],['textureMatrix','color','scale','offset'],['textureSampler'],_0x3ac6f3));var _0xd3ba75=this['_effect'];_0xd3ba75&&_0xd3ba75['isReady']()&&this['texture']&&this['texture']['isReady']()&&(_0x18886c=this['_scene']['getEngine'](),(this['onBeforeRenderObservable']['notifyObservers'](this),_0x18886c['enableEffect'](_0xd3ba75),_0x18886c['setState'](!0x1),_0xd3ba75['setTexture']('textureSampler',this['texture']),_0xd3ba75['setMatrix']('textureMatrix',this['texture']['getTextureMatrix']()),_0xd3ba75['setFloat4']('color',this['color']['r'],this['color']['g'],this['color']['b'],this['color']['a']),_0xd3ba75['setVector2']('offset',this['offset']),_0xd3ba75['setVector2']('scale',this['scale']),_0x18886c['bindBuffers'](this['_vertexBuffers'],this['_indexBuffer'],_0xd3ba75),this['alphaTest']?_0x18886c['drawElementsType'](_0x33c2e5['a']['TriangleFillMode'],0x0,0x6):(_0x18886c['setAlphaMode'](this['alphaBlendingMode']),_0x18886c['drawElementsType'](_0x33c2e5['a']['TriangleFillMode'],0x0,0x6),_0x18886c['setAlphaMode'](_0x2103ba['a']['ALPHA_DISABLE'])),this['onAfterRenderObservable']['notifyObservers'](this)));},_0x1bcb87['prototype']['dispose']=function(){var _0x385273=this['_vertexBuffers'][_0x212fbd['b']['PositionKind']];_0x385273&&(_0x385273['dispose'](),this['_vertexBuffers'][_0x212fbd['b']['PositionKind']]=null),this['_indexBuffer']&&(this['_scene']['getEngine']()['_releaseBuffer'](this['_indexBuffer']),this['_indexBuffer']=null),this['texture']&&(this['texture']['dispose'](),this['texture']=null),this['renderTargetTextures']=[];var _0x21a814=this['_scene']['layers']['indexOf'](this);this['_scene']['layers']['splice'](_0x21a814,0x1),this['onDisposeObservable']['notifyObservers'](this),this['onDisposeObservable']['clear'](),this['onAfterRenderObservable']['clear'](),this['onBeforeRenderObservable']['clear']();},_0x1bcb87;}()),_0x5390a4=(function(){function _0x11aa9a(_0x534fa9,_0x42afcb,_0x18cb1d,_0x3e387e,_0x49dad2){this['size']=_0x534fa9,this['position']=_0x42afcb,this['alphaMode']=_0x2103ba['a']['ALPHA_ONEONE'],this['color']=_0x18cb1d||new _0x39310d['a'](0x1,0x1,0x1),this['texture']=_0x3e387e?new _0xaf3c80['a'](_0x3e387e,_0x49dad2['getScene'](),!0x0):null,this['_system']=_0x49dad2,_0x49dad2['lensFlares']['push'](this);}return _0x11aa9a['AddFlare']=function(_0x3a5ad7,_0x230662,_0x5d8b23,_0x69c399,_0x12a5e7){return new _0x11aa9a(_0x3a5ad7,_0x230662,_0x5d8b23,_0x69c399,_0x12a5e7);},_0x11aa9a['prototype']['dispose']=function(){this['texture']&&this['texture']['dispose']();var _0x580d69=this['_system']['lensFlares']['indexOf'](this);this['_system']['lensFlares']['splice'](_0x580d69,0x1);},_0x11aa9a;}()),_0x29123a='\x0avarying\x20vec2\x20vUV;\x0auniform\x20sampler2D\x20textureSampler;\x0a\x0auniform\x20vec4\x20color;\x0avoid\x20main(void)\x20{\x0avec4\x20baseColor=texture2D(textureSampler,vUV);\x0agl_FragColor=baseColor*color;\x0a}';_0x494b01['a']['ShadersStore']['lensFlarePixelShader']=_0x29123a;var _0x5ca9b8='\x0aattribute\x20vec2\x20position;\x0a\x0auniform\x20mat4\x20viewportMatrix;\x0a\x0avarying\x20vec2\x20vUV;\x0aconst\x20vec2\x20madd=vec2(0.5,0.5);\x0avoid\x20main(void)\x20{\x0avUV=position*madd+madd;\x0agl_Position=viewportMatrix*vec4(position,0.0,1.0);\x0a}';_0x494b01['a']['ShadersStore']['lensFlareVertexShader']=_0x5ca9b8;var _0x23fcdc=(function(){function _0x190799(_0x5ab9c7,_0x113397,_0x2c4668){this['name']=_0x5ab9c7,this['lensFlares']=new Array(),this['borderLimit']=0x12c,this['viewportBorder']=0x0,this['layerMask']=0xfffffff,this['_vertexBuffers']={},this['_isEnabled']=!0x0,this['_scene']=_0x2c4668||_0x44b9ce['a']['LastCreatedScene'],_0x190799['_SceneComponentInitialization'](this['_scene']),this['_emitter']=_0x113397,this['id']=_0x5ab9c7,_0x2c4668['lensFlareSystems']['push'](this),this['meshesSelectionPredicate']=function(_0x5d892c){return _0x2c4668['activeCamera']&&_0x5d892c['material']&&_0x5d892c['isVisible']&&_0x5d892c['isEnabled']()&&_0x5d892c['isBlocker']&&0x0!=(_0x5d892c['layerMask']&_0x2c4668['activeCamera']['layerMask']);};var _0x2ab260=_0x2c4668['getEngine'](),_0xa24d51=[];_0xa24d51['push'](0x1,0x1),_0xa24d51['push'](-0x1,0x1),_0xa24d51['push'](-0x1,-0x1),_0xa24d51['push'](0x1,-0x1),this['_vertexBuffers'][_0x212fbd['b']['PositionKind']]=new _0x212fbd['b'](_0x2ab260,_0xa24d51,_0x212fbd['b']['PositionKind'],!0x1,!0x1,0x2);var _0x3c8cb6=[];_0x3c8cb6['push'](0x0),_0x3c8cb6['push'](0x1),_0x3c8cb6['push'](0x2),_0x3c8cb6['push'](0x0),_0x3c8cb6['push'](0x2),_0x3c8cb6['push'](0x3),this['_indexBuffer']=_0x2ab260['createIndexBuffer'](_0x3c8cb6),this['_effect']=_0x2ab260['createEffect']('lensFlare',[_0x212fbd['b']['PositionKind']],['color','viewportMatrix'],['textureSampler'],'');}return Object['defineProperty'](_0x190799['prototype'],'isEnabled',{'get':function(){return this['_isEnabled'];},'set':function(_0x3004fa){this['_isEnabled']=_0x3004fa;},'enumerable':!0x1,'configurable':!0x0}),_0x190799['prototype']['getScene']=function(){return this['_scene'];},_0x190799['prototype']['getEmitter']=function(){return this['_emitter'];},_0x190799['prototype']['setEmitter']=function(_0x145adc){this['_emitter']=_0x145adc;},_0x190799['prototype']['getEmitterPosition']=function(){return this['_emitter']['getAbsolutePosition']?this['_emitter']['getAbsolutePosition']():this['_emitter']['position'];},_0x190799['prototype']['computeEffectivePosition']=function(_0x36eb4b){var _0x5eb791=this['getEmitterPosition']();return _0x5eb791=_0x74d525['e']['Project'](_0x5eb791,_0x74d525['a']['Identity'](),this['_scene']['getTransformMatrix'](),_0x36eb4b),this['_positionX']=_0x5eb791['x'],this['_positionY']=_0x5eb791['y'],_0x5eb791=_0x74d525['e']['TransformCoordinates'](this['getEmitterPosition'](),this['_scene']['getViewMatrix']()),this['viewportBorder']>0x0&&(_0x36eb4b['x']-=this['viewportBorder'],_0x36eb4b['y']-=this['viewportBorder'],_0x36eb4b['width']+=0x2*this['viewportBorder'],_0x36eb4b['height']+=0x2*this['viewportBorder'],_0x5eb791['x']+=this['viewportBorder'],_0x5eb791['y']+=this['viewportBorder'],this['_positionX']+=this['viewportBorder'],this['_positionY']+=this['viewportBorder']),_0x5eb791['z']>0x0&&(this['_positionX']>_0x36eb4b['x']&&this['_positionX']<_0x36eb4b['x']+_0x36eb4b['width']&&this['_positionY']>_0x36eb4b['y']&&(this['_positionY'],_0x36eb4b['y'],_0x36eb4b['height']),!0x0);},_0x190799['prototype']['_isVisible']=function(){if(!this['_isEnabled']||!this['_scene']['activeCamera'])return!0x1;var _0x52bc57=this['getEmitterPosition']()['subtract'](this['_scene']['activeCamera']['globalPosition']),_0x2384f7=_0x52bc57['length']();_0x52bc57['normalize']();var _0x2fc5a2=new _0x36fb4d['a'](this['_scene']['activeCamera']['globalPosition'],_0x52bc57),_0x9d3d7e=this['_scene']['pickWithRay'](_0x2fc5a2,this['meshesSelectionPredicate'],!0x0);return!_0x9d3d7e||!_0x9d3d7e['hit']||_0x9d3d7e['distance']>_0x2384f7;},_0x190799['prototype']['render']=function(){if(!this['_effect']['isReady']()||!this['_scene']['activeCamera'])return!0x1;var _0x592df6,_0x2068fa,_0x37bf0e=this['_scene']['getEngine'](),_0x288038=this['_scene']['activeCamera']['viewport']['toGlobal'](_0x37bf0e['getRenderWidth'](!0x0),_0x37bf0e['getRenderHeight'](!0x0));if(!this['computeEffectivePosition'](_0x288038))return!0x1;if(!this['_isVisible']())return!0x1;var _0x9e64ba=(_0x592df6=this['_positionX']_0x288038['x']+_0x288038['width']-this['borderLimit']?this['_positionX']-_0x288038['x']-_0x288038['width']+this['borderLimit']:0x0)>(_0x2068fa=this['_positionY']_0x288038['y']+_0x288038['height']-this['borderLimit']?this['_positionY']-_0x288038['y']-_0x288038['height']+this['borderLimit']:0x0)?_0x592df6:_0x2068fa;(_0x9e64ba-=this['viewportBorder'])>this['borderLimit']&&(_0x9e64ba=this['borderLimit']);var _0x3440e3=0x1-_0x4a0cf0['a']['Clamp'](_0x9e64ba/this['borderLimit'],0x0,0x1);if(_0x3440e3<0x0)return!0x1;_0x3440e3>0x1&&(_0x3440e3=0x1),this['viewportBorder']>0x0&&(_0x288038['x']+=this['viewportBorder'],_0x288038['y']+=this['viewportBorder'],_0x288038['width']-=0x2*this['viewportBorder'],_0x288038['height']-=0x2*this['viewportBorder'],this['_positionX']-=this['viewportBorder'],this['_positionY']-=this['viewportBorder']);var _0x1ffb9f=_0x288038['x']+_0x288038['width']/0x2,_0x36a742=_0x288038['y']+_0x288038['height']/0x2,_0x58afa1=_0x1ffb9f-this['_positionX'],_0x11c482=_0x36a742-this['_positionY'];_0x37bf0e['enableEffect'](this['_effect']),_0x37bf0e['setState'](!0x1),_0x37bf0e['setDepthBuffer'](!0x1),_0x37bf0e['bindBuffers'](this['_vertexBuffers'],this['_indexBuffer'],this['_effect']);for(var _0x47b780=0x0;_0x47b7800x0);for(var _0x3c3943=0x0,_0x5d6a21=_0x12b432;_0x3c3943<_0x5d6a21['length'];_0x3c3943++){var _0x235e85=_0x5d6a21[_0x3c3943];0x0!=(_0x3cf729['layerMask']&_0x235e85['layerMask'])&&_0x235e85['render']();}_0x5d754c['b']['EndPerformanceCounter']('Lens\x20flares',_0x12b432['length']>0x0);}},_0x5ca010;}());_0x23fcdc['_SceneComponentInitialization']=function(_0x595b45){var _0x220d07=_0x595b45['_getComponent'](_0x384de3['a']['NAME_LENSFLARESYSTEM']);_0x220d07||(_0x220d07=new _0x28c767(_0x595b45),_0x595b45['_addComponent'](_0x220d07));};var _0x2985d2='\x0a\x0a\x0a\x0a\x0afloat\x20bayerDither2(vec2\x20_P)\x20{\x0areturn\x20mod(2.0*_P.y+_P.x+1.0,4.0);\x0a}\x0a\x0a\x0afloat\x20bayerDither4(vec2\x20_P)\x20{\x0avec2\x20P1=mod(_P,2.0);\x0avec2\x20P2=floor(0.5*mod(_P,4.0));\x0areturn\x204.0*bayerDither2(P1)+bayerDither2(P2);\x0a}\x0a\x0afloat\x20bayerDither8(vec2\x20_P)\x20{\x0avec2\x20P1=mod(_P,2.0);\x0avec2\x20P2=floor(0.5*mod(_P,4.0));\x0avec2\x20P4=floor(0.25*mod(_P,8.0));\x0areturn\x204.0*(4.0*bayerDither2(P1)+bayerDither2(P2))+bayerDither2(P4);\x0a}\x0a';_0x494b01['a']['IncludesShadersStore']['bayerDitherFunctions']=_0x2985d2;var _0x4bd237='#if\x20SM_FLOAT\x20==\x200\x0a#include\x0a#endif\x0a#if\x20SM_SOFTTRANSPARENTSHADOW\x20==\x201\x0a#include\x0auniform\x20float\x20softTransparentShadowSM;\x0a#endif\x0avarying\x20float\x20vDepthMetricSM;\x0a#if\x20SM_USEDISTANCE\x20==\x201\x0auniform\x20vec3\x20lightDataSM;\x0avarying\x20vec3\x20vPositionWSM;\x0a#endif\x0auniform\x20vec3\x20biasAndScaleSM;\x0auniform\x20vec2\x20depthValuesSM;\x0a#if\x20defined(SM_DEPTHCLAMP)\x20&&\x20SM_DEPTHCLAMP\x20==\x201\x0avarying\x20float\x20zSM;\x0a#endif\x0a';_0x494b01['a']['IncludesShadersStore']['shadowMapFragmentDeclaration']=_0x4bd237;var _0x3eae71='\x20float\x20depthSM=vDepthMetricSM;\x0a#if\x20defined(SM_DEPTHCLAMP)\x20&&\x20SM_DEPTHCLAMP\x20==\x201\x0a#if\x20SM_USEDISTANCE\x20==\x201\x0adepthSM=clamp(((length(vPositionWSM-lightDataSM)+depthValuesSM.x)/(depthValuesSM.y))+biasAndScaleSM.x,0.0,1.0);\x0a#else\x0adepthSM=clamp(((zSM+depthValuesSM.x)/(depthValuesSM.y))+biasAndScaleSM.x,0.0,1.0);\x0a#endif\x0agl_FragDepth=depthSM;\x0a#elif\x20SM_USEDISTANCE\x20==\x201\x0adepthSM=(length(vPositionWSM-lightDataSM)+depthValuesSM.x)/(depthValuesSM.y)+biasAndScaleSM.x;\x0a#endif\x0a#if\x20SM_ESM\x20==\x201\x0adepthSM=clamp(exp(-min(87.,biasAndScaleSM.z*depthSM)),0.,1.);\x0a#endif\x0a#if\x20SM_FLOAT\x20==\x201\x0agl_FragColor=vec4(depthSM,1.0,1.0,1.0);\x0a#else\x0agl_FragColor=pack(depthSM);\x0a#endif\x0areturn;';_0x494b01['a']['IncludesShadersStore']['shadowMapFragment']=_0x3eae71;var _0x113c9c='#include\x0a#ifdef\x20ALPHATEST\x0avarying\x20vec2\x20vUV;\x0auniform\x20sampler2D\x20diffuseSampler;\x0a#endif\x0a#include\x0avoid\x20main(void)\x0a{\x0a#include\x0a#ifdef\x20ALPHATEST\x0afloat\x20alphaFromAlphaTexture=texture2D(diffuseSampler,vUV).a;\x0aif\x20(alphaFromAlphaTexture<0.4)\x0adiscard;\x0a#endif\x0a#if\x20SM_SOFTTRANSPARENTSHADOW\x20==\x201\x0a#ifdef\x20ALPHATEST\x0aif\x20((bayerDither8(floor(mod(gl_FragCoord.xy,8.0))))/64.0>=softTransparentShadowSM*alphaFromAlphaTexture)\x20discard;\x0a#else\x0aif\x20((bayerDither8(floor(mod(gl_FragCoord.xy,8.0))))/64.0>=softTransparentShadowSM)\x20discard;\x0a#endif\x0a#endif\x0a#include\x0a}';_0x494b01['a']['ShadersStore']['shadowMapPixelShader']=_0x113c9c;var _0x29b45f='#if\x20SM_NORMALBIAS\x20==\x201\x0auniform\x20vec3\x20lightDataSM;\x0a#endif\x0auniform\x20vec3\x20biasAndScaleSM;\x0auniform\x20vec2\x20depthValuesSM;\x0avarying\x20float\x20vDepthMetricSM;\x0a#if\x20SM_USEDISTANCE\x20==\x201\x0avarying\x20vec3\x20vPositionWSM;\x0a#endif\x0a#if\x20defined(SM_DEPTHCLAMP)\x20&&\x20SM_DEPTHCLAMP\x20==\x201\x0avarying\x20float\x20zSM;\x0a#endif\x0a';_0x494b01['a']['IncludesShadersStore']['shadowMapVertexDeclaration']=_0x29b45f;var _0x516ec1='\x0a#if\x20SM_NORMALBIAS\x20==\x201\x0a#if\x20SM_DIRECTIONINLIGHTDATA\x20==\x201\x0avec3\x20worldLightDirSM=normalize(-lightDataSM.xyz);\x0a#else\x0avec3\x20directionToLightSM=lightDataSM.xyz-worldPos.xyz;\x0avec3\x20worldLightDirSM=normalize(directionToLightSM);\x0a#endif\x0afloat\x20ndlSM=dot(vNormalW,worldLightDirSM);\x0afloat\x20sinNLSM=sqrt(1.0-ndlSM*ndlSM);\x0afloat\x20normalBiasSM=biasAndScaleSM.y*sinNLSM;\x0aworldPos.xyz-=vNormalW*normalBiasSM;\x0a#endif\x0a';_0x494b01['a']['IncludesShadersStore']['shadowMapVertexNormalBias']=_0x516ec1;var _0x209a60='#if\x20SM_USEDISTANCE\x20==\x201\x0avPositionWSM=worldPos.xyz;\x0a#endif\x0a#if\x20SM_DEPTHTEXTURE\x20==\x201\x0a\x0agl_Position.z+=biasAndScaleSM.x*gl_Position.w;\x0a#endif\x0a#if\x20defined(SM_DEPTHCLAMP)\x20&&\x20SM_DEPTHCLAMP\x20==\x201\x0azSM=gl_Position.z;\x0agl_Position.z=0.0;\x0a#elif\x20SM_USEDISTANCE\x20==\x200\x0a\x0avDepthMetricSM=((gl_Position.z+depthValuesSM.x)/(depthValuesSM.y))+biasAndScaleSM.x;\x0a#endif\x0a';_0x494b01['a']['IncludesShadersStore']['shadowMapVertexMetric']=_0x209a60;var _0x4e5d3b='\x0aattribute\x20vec3\x20position;\x0a#ifdef\x20NORMAL\x0aattribute\x20vec3\x20normal;\x0a#endif\x0a#include\x0a#include\x0a#include[0..maxSimultaneousMorphTargets]\x0a\x0a#include\x0a#include\x0auniform\x20mat4\x20viewProjection;\x0a#ifdef\x20ALPHATEST\x0avarying\x20vec2\x20vUV;\x0auniform\x20mat4\x20diffuseMatrix;\x0a#ifdef\x20UV1\x0aattribute\x20vec2\x20uv;\x0a#endif\x0a#ifdef\x20UV2\x0aattribute\x20vec2\x20uv2;\x0a#endif\x0a#endif\x0a#include\x0a#include\x0avoid\x20main(void)\x0a{\x0avec3\x20positionUpdated=position;\x0a#ifdef\x20UV1\x0avec2\x20uvUpdated=uv;\x0a#endif\x0a#ifdef\x20NORMAL\x0avec3\x20normalUpdated=normal;\x0a#endif\x0a#include[0..maxSimultaneousMorphTargets]\x0a#include\x0a#include\x0avec4\x20worldPos=finalWorld*vec4(positionUpdated,1.0);\x0a#ifdef\x20NORMAL\x0amat3\x20normWorldSM=mat3(finalWorld);\x0a#if\x20defined(INSTANCES)\x20&&\x20defined(THIN_INSTANCES)\x0avec3\x20vNormalW=normalUpdated/vec3(dot(normWorldSM[0],normWorldSM[0]),dot(normWorldSM[1],normWorldSM[1]),dot(normWorldSM[2],normWorldSM[2]));\x0avNormalW=normalize(normWorldSM*vNormalW);\x0a#else\x0a#ifdef\x20NONUNIFORMSCALING\x0anormWorldSM=transposeMat3(inverseMat3(normWorldSM));\x0a#endif\x0avec3\x20vNormalW=normalize(normWorldSM*normalUpdated);\x0a#endif\x0a#endif\x0a#include\x0a\x0agl_Position=viewProjection*worldPos;\x0a#include\x0a#ifdef\x20ALPHATEST\x0a#ifdef\x20UV1\x0avUV=vec2(diffuseMatrix*vec4(uvUpdated,1.0,0.0));\x0a#endif\x0a#ifdef\x20UV2\x0avUV=vec2(diffuseMatrix*vec4(uv2,1.0,0.0));\x0a#endif\x0a#endif\x0a#include\x0a}';_0x494b01['a']['ShadersStore']['shadowMapVertexShader']=_0x4e5d3b;var _0x540026='\x0avarying\x20vec2\x20vUV;\x0auniform\x20sampler2D\x20textureSampler;\x0a\x0auniform\x20vec2\x20screenSize;\x0avoid\x20main(void)\x0a{\x0avec4\x20colorDepth=vec4(0.0);\x0afor\x20(int\x20x=-OFFSET;\x20x<=OFFSET;\x20x++)\x0afor\x20(int\x20y=-OFFSET;\x20y<=OFFSET;\x20y++)\x0acolorDepth+=texture2D(textureSampler,vUV+vec2(x,y)/screenSize);\x0agl_FragColor=(colorDepth/float((OFFSET*2+1)*(OFFSET*2+1)));\x0a}';_0x494b01['a']['ShadersStore']['depthBoxBlurPixelShader']=_0x540026;var _0x16e26b='#if\x20SM_SOFTTRANSPARENTSHADOW\x20==\x201\x0aif\x20((bayerDither8(floor(mod(gl_FragCoord.xy,8.0))))/64.0>=softTransparentShadowSM*alpha)\x20discard;\x0a#endif\x0a';_0x494b01['a']['IncludesShadersStore']['shadowMapFragmentSoftTransparentShadow']=_0x16e26b;var _0x58720b=new _0x74d525['a'](),_0x42a66f=new _0x74d525['a'](),_0x4f0fba=(function(){function _0x3fb54f(_0xe9bcdf,_0x58dbbe,_0x29ec36){this['onBeforeShadowMapRenderObservable']=new _0x6ac1f7['c'](),this['onAfterShadowMapRenderObservable']=new _0x6ac1f7['c'](),this['onBeforeShadowMapRenderMeshObservable']=new _0x6ac1f7['c'](),this['onAfterShadowMapRenderMeshObservable']=new _0x6ac1f7['c'](),this['_bias']=0.00005,this['_normalBias']=0x0,this['_blurBoxOffset']=0x1,this['_blurScale']=0x2,this['_blurKernel']=0x1,this['_useKernelBlur']=!0x1,this['_filter']=_0x3fb54f['FILTER_NONE'],this['_filteringQuality']=_0x3fb54f['QUALITY_HIGH'],this['_contactHardeningLightSizeUVRatio']=0.1,this['_darkness']=0x0,this['_transparencyShadow']=!0x1,this['enableSoftTransparentShadow']=!0x1,this['frustumEdgeFalloff']=0x0,this['forceBackFacesOnly']=!0x1,this['_lightDirection']=_0x74d525['e']['Zero'](),this['_viewMatrix']=_0x74d525['a']['Zero'](),this['_projectionMatrix']=_0x74d525['a']['Zero'](),this['_transformMatrix']=_0x74d525['a']['Zero'](),this['_cachedPosition']=new _0x74d525['e'](Number['MAX_VALUE'],Number['MAX_VALUE'],Number['MAX_VALUE']),this['_cachedDirection']=new _0x74d525['e'](Number['MAX_VALUE'],Number['MAX_VALUE'],Number['MAX_VALUE']),this['_currentFaceIndex']=0x0,this['_currentFaceIndexCache']=0x0,this['_defaultTextureMatrix']=_0x74d525['a']['Identity'](),this['_mapSize']=_0xe9bcdf,this['_light']=_0x58dbbe,this['_scene']=_0x58dbbe['getScene'](),_0x58dbbe['_shadowGenerator']=this,this['id']=_0x58dbbe['id'],_0x3fb54f['_SceneComponentInitialization'](this['_scene']);var _0x3b1921=this['_scene']['getEngine']()['getCaps']();_0x29ec36?_0x3b1921['textureFloatRender']&&_0x3b1921['textureFloatLinearFiltering']?this['_textureType']=_0x2103ba['a']['TEXTURETYPE_FLOAT']:_0x3b1921['textureHalfFloatRender']&&_0x3b1921['textureHalfFloatLinearFiltering']?this['_textureType']=_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT']:this['_textureType']=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']:_0x3b1921['textureHalfFloatRender']&&_0x3b1921['textureHalfFloatLinearFiltering']?this['_textureType']=_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT']:_0x3b1921['textureFloatRender']&&_0x3b1921['textureFloatLinearFiltering']?this['_textureType']=_0x2103ba['a']['TEXTURETYPE_FLOAT']:this['_textureType']=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'],this['_initializeGenerator'](),this['_applyFilterValues']();}return Object['defineProperty'](_0x3fb54f['prototype'],'bias',{'get':function(){return this['_bias'];},'set':function(_0x2f31dc){this['_bias']=_0x2f31dc;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3fb54f['prototype'],'normalBias',{'get':function(){return this['_normalBias'];},'set':function(_0x3253bc){this['_normalBias']=_0x3253bc;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3fb54f['prototype'],'blurBoxOffset',{'get':function(){return this['_blurBoxOffset'];},'set':function(_0x52a90f){this['_blurBoxOffset']!==_0x52a90f&&(this['_blurBoxOffset']=_0x52a90f,this['_disposeBlurPostProcesses']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3fb54f['prototype'],'blurScale',{'get':function(){return this['_blurScale'];},'set':function(_0x3d4e08){this['_blurScale']!==_0x3d4e08&&(this['_blurScale']=_0x3d4e08,this['_disposeBlurPostProcesses']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3fb54f['prototype'],'blurKernel',{'get':function(){return this['_blurKernel'];},'set':function(_0x4e7fd5){this['_blurKernel']!==_0x4e7fd5&&(this['_blurKernel']=_0x4e7fd5,this['_disposeBlurPostProcesses']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3fb54f['prototype'],'useKernelBlur',{'get':function(){return this['_useKernelBlur'];},'set':function(_0x318f69){this['_useKernelBlur']!==_0x318f69&&(this['_useKernelBlur']=_0x318f69,this['_disposeBlurPostProcesses']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3fb54f['prototype'],'depthScale',{'get':function(){return void 0x0!==this['_depthScale']?this['_depthScale']:this['_light']['getDepthScale']();},'set':function(_0x34dc2e){this['_depthScale']=_0x34dc2e;},'enumerable':!0x1,'configurable':!0x0}),_0x3fb54f['prototype']['_validateFilter']=function(_0x4c0cc0){return _0x4c0cc0;},Object['defineProperty'](_0x3fb54f['prototype'],'filter',{'get':function(){return this['_filter'];},'set':function(_0x5989d0){if(_0x5989d0=this['_validateFilter'](_0x5989d0),this['_light']['needCube']()){if(_0x5989d0===_0x3fb54f['FILTER_BLUREXPONENTIALSHADOWMAP'])return void(this['useExponentialShadowMap']=!0x0);if(_0x5989d0===_0x3fb54f['FILTER_BLURCLOSEEXPONENTIALSHADOWMAP'])return void(this['useCloseExponentialShadowMap']=!0x0);if(_0x5989d0===_0x3fb54f['FILTER_PCF']||_0x5989d0===_0x3fb54f['FILTER_PCSS'])return void(this['usePoissonSampling']=!0x0);}_0x5989d0!==_0x3fb54f['FILTER_PCF']&&_0x5989d0!==_0x3fb54f['FILTER_PCSS']||0x1!==this['_scene']['getEngine']()['webGLVersion']?this['_filter']!==_0x5989d0&&(this['_filter']=_0x5989d0,this['_disposeBlurPostProcesses'](),this['_applyFilterValues'](),this['_light']['_markMeshesAsLightDirty']()):this['usePoissonSampling']=!0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3fb54f['prototype'],'usePoissonSampling',{'get':function(){return this['filter']===_0x3fb54f['FILTER_POISSONSAMPLING'];},'set':function(_0x31d0d2){var _0x5f42d6=this['_validateFilter'](_0x3fb54f['FILTER_POISSONSAMPLING']);(_0x31d0d2||this['filter']===_0x3fb54f['FILTER_POISSONSAMPLING'])&&(this['filter']=_0x31d0d2?_0x5f42d6:_0x3fb54f['FILTER_NONE']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3fb54f['prototype'],'useExponentialShadowMap',{'get':function(){return this['filter']===_0x3fb54f['FILTER_EXPONENTIALSHADOWMAP'];},'set':function(_0x440987){var _0x8ed65c=this['_validateFilter'](_0x3fb54f['FILTER_EXPONENTIALSHADOWMAP']);(_0x440987||this['filter']===_0x3fb54f['FILTER_EXPONENTIALSHADOWMAP'])&&(this['filter']=_0x440987?_0x8ed65c:_0x3fb54f['FILTER_NONE']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3fb54f['prototype'],'useBlurExponentialShadowMap',{'get':function(){return this['filter']===_0x3fb54f['FILTER_BLUREXPONENTIALSHADOWMAP'];},'set':function(_0x58ec05){var _0x2c8af4=this['_validateFilter'](_0x3fb54f['FILTER_BLUREXPONENTIALSHADOWMAP']);(_0x58ec05||this['filter']===_0x3fb54f['FILTER_BLUREXPONENTIALSHADOWMAP'])&&(this['filter']=_0x58ec05?_0x2c8af4:_0x3fb54f['FILTER_NONE']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3fb54f['prototype'],'useCloseExponentialShadowMap',{'get':function(){return this['filter']===_0x3fb54f['FILTER_CLOSEEXPONENTIALSHADOWMAP'];},'set':function(_0x43eaec){var _0x244759=this['_validateFilter'](_0x3fb54f['FILTER_CLOSEEXPONENTIALSHADOWMAP']);(_0x43eaec||this['filter']===_0x3fb54f['FILTER_CLOSEEXPONENTIALSHADOWMAP'])&&(this['filter']=_0x43eaec?_0x244759:_0x3fb54f['FILTER_NONE']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3fb54f['prototype'],'useBlurCloseExponentialShadowMap',{'get':function(){return this['filter']===_0x3fb54f['FILTER_BLURCLOSEEXPONENTIALSHADOWMAP'];},'set':function(_0x3b7d12){var _0x453df2=this['_validateFilter'](_0x3fb54f['FILTER_BLURCLOSEEXPONENTIALSHADOWMAP']);(_0x3b7d12||this['filter']===_0x3fb54f['FILTER_BLURCLOSEEXPONENTIALSHADOWMAP'])&&(this['filter']=_0x3b7d12?_0x453df2:_0x3fb54f['FILTER_NONE']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3fb54f['prototype'],'usePercentageCloserFiltering',{'get':function(){return this['filter']===_0x3fb54f['FILTER_PCF'];},'set':function(_0x39299b){var _0x14ed77=this['_validateFilter'](_0x3fb54f['FILTER_PCF']);(_0x39299b||this['filter']===_0x3fb54f['FILTER_PCF'])&&(this['filter']=_0x39299b?_0x14ed77:_0x3fb54f['FILTER_NONE']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3fb54f['prototype'],'filteringQuality',{'get':function(){return this['_filteringQuality'];},'set':function(_0x1ce62a){this['_filteringQuality']!==_0x1ce62a&&(this['_filteringQuality']=_0x1ce62a,this['_disposeBlurPostProcesses'](),this['_applyFilterValues'](),this['_light']['_markMeshesAsLightDirty']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3fb54f['prototype'],'useContactHardeningShadow',{'get':function(){return this['filter']===_0x3fb54f['FILTER_PCSS'];},'set':function(_0x217c98){var _0x1cf6fc=this['_validateFilter'](_0x3fb54f['FILTER_PCSS']);(_0x217c98||this['filter']===_0x3fb54f['FILTER_PCSS'])&&(this['filter']=_0x217c98?_0x1cf6fc:_0x3fb54f['FILTER_NONE']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3fb54f['prototype'],'contactHardeningLightSizeUVRatio',{'get':function(){return this['_contactHardeningLightSizeUVRatio'];},'set':function(_0x12662e){this['_contactHardeningLightSizeUVRatio']=_0x12662e;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3fb54f['prototype'],'darkness',{'get':function(){return this['_darkness'];},'set':function(_0x542d81){this['setDarkness'](_0x542d81);},'enumerable':!0x1,'configurable':!0x0}),_0x3fb54f['prototype']['getDarkness']=function(){return this['_darkness'];},_0x3fb54f['prototype']['setDarkness']=function(_0x18799a){return this['_darkness']=_0x18799a>=0x1?0x1:_0x18799a<=0x0?0x0:_0x18799a,this;},Object['defineProperty'](_0x3fb54f['prototype'],'transparencyShadow',{'get':function(){return this['_transparencyShadow'];},'set':function(_0x1bde26){this['setTransparencyShadow'](_0x1bde26);},'enumerable':!0x1,'configurable':!0x0}),_0x3fb54f['prototype']['setTransparencyShadow']=function(_0x244de7){return this['_transparencyShadow']=_0x244de7,this;},_0x3fb54f['prototype']['getShadowMap']=function(){return this['_shadowMap'];},_0x3fb54f['prototype']['getShadowMapForRendering']=function(){return this['_shadowMap2']?this['_shadowMap2']:this['_shadowMap'];},_0x3fb54f['prototype']['getClassName']=function(){return _0x3fb54f['CLASSNAME'];},_0x3fb54f['prototype']['addShadowCaster']=function(_0x31b99a,_0x3374cc){var _0x470fd5;return void 0x0===_0x3374cc&&(_0x3374cc=!0x0),this['_shadowMap']?(this['_shadowMap']['renderList']||(this['_shadowMap']['renderList']=[]),this['_shadowMap']['renderList']['push'](_0x31b99a),_0x3374cc&&(_0x470fd5=this['_shadowMap']['renderList'])['push']['apply'](_0x470fd5,_0x31b99a['getChildMeshes']()),this):this;},_0x3fb54f['prototype']['removeShadowCaster']=function(_0x24bf35,_0xb8dba0){if(void 0x0===_0xb8dba0&&(_0xb8dba0=!0x0),!this['_shadowMap']||!this['_shadowMap']['renderList'])return this;var _0x13a91d=this['_shadowMap']['renderList']['indexOf'](_0x24bf35);if(-0x1!==_0x13a91d&&this['_shadowMap']['renderList']['splice'](_0x13a91d,0x1),_0xb8dba0)for(var _0x282df=0x0,_0x30430d=_0x24bf35['getChildren']();_0x282df<_0x30430d['length'];_0x282df++){var _0x5de735=_0x30430d[_0x282df];this['removeShadowCaster'](_0x5de735);}return this;},_0x3fb54f['prototype']['getLight']=function(){return this['_light'];},Object['defineProperty'](_0x3fb54f['prototype'],'mapSize',{'get':function(){return this['_mapSize'];},'set':function(_0x3cad93){this['_mapSize']=_0x3cad93,this['_light']['_markMeshesAsLightDirty'](),this['recreateShadowMap']();},'enumerable':!0x1,'configurable':!0x0}),_0x3fb54f['prototype']['_initializeGenerator']=function(){this['_light']['_markMeshesAsLightDirty'](),this['_initializeShadowMap']();},_0x3fb54f['prototype']['_createTargetRenderTexture']=function(){this['_scene']['getEngine']()['webGLVersion']>0x1?(this['_shadowMap']=new _0x310f87(this['_light']['name']+'_shadowMap',this['_mapSize'],this['_scene'],!0x1,!0x0,this['_textureType'],this['_light']['needCube'](),void 0x0,!0x1,!0x1),this['_shadowMap']['createDepthStencilTexture'](_0x2103ba['a']['LESS'],!0x0)):this['_shadowMap']=new _0x310f87(this['_light']['name']+'_shadowMap',this['_mapSize'],this['_scene'],!0x1,!0x0,this['_textureType'],this['_light']['needCube']());},_0x3fb54f['prototype']['_initializeShadowMap']=function(){var _0x9a2eab=this;if(this['_createTargetRenderTexture'](),null!==this['_shadowMap']){this['_shadowMap']['wrapU']=_0xaf3c80['a']['CLAMP_ADDRESSMODE'],this['_shadowMap']['wrapV']=_0xaf3c80['a']['CLAMP_ADDRESSMODE'],this['_shadowMap']['anisotropicFilteringLevel']=0x1,this['_shadowMap']['updateSamplingMode'](_0xaf3c80['a']['BILINEAR_SAMPLINGMODE']),this['_shadowMap']['renderParticles']=!0x1,this['_shadowMap']['ignoreCameraViewport']=!0x0,this['_storedUniqueId']&&(this['_shadowMap']['uniqueId']=this['_storedUniqueId']),this['_shadowMap']['customRenderFunction']=this['_renderForShadowMap']['bind'](this),this['_shadowMap']['customIsReadyFunction']=function(_0x303afa,_0x57bb5b){return!0x0;};var _0x36d53f=this['_scene']['getEngine']();this['_shadowMap']['onBeforeRenderObservable']['add'](function(_0x46c060){if(_0x9a2eab['_currentFaceIndex']=_0x46c060,_0x9a2eab['_filter']===_0x3fb54f['FILTER_PCF']&&_0x36d53f['setColorWrite'](!0x1),_0x9a2eab['_scene']['getSceneUniformBuffer']()['useUbo']){var _0x2bd3f6=_0x9a2eab['_scene']['getSceneUniformBuffer']();_0x2bd3f6['updateMatrix']('viewProjection',_0x9a2eab['getTransformMatrix']()),_0x2bd3f6['updateMatrix']('view',_0x9a2eab['_viewMatrix']),_0x2bd3f6['update']();}}),this['_shadowMap']['onAfterUnbindObservable']['add'](function(){if(_0x9a2eab['_scene']['getSceneUniformBuffer']()['useUbo']){var _0x4b33c4=_0x9a2eab['_scene']['getSceneUniformBuffer']();_0x4b33c4['updateMatrix']('viewProjection',_0x9a2eab['_scene']['getTransformMatrix']()),_0x4b33c4['updateMatrix']('view',_0x9a2eab['_scene']['getViewMatrix']()),_0x4b33c4['update']();}if(_0x9a2eab['_filter']===_0x3fb54f['FILTER_PCF']&&_0x36d53f['setColorWrite'](!0x0),_0x9a2eab['useBlurExponentialShadowMap']||_0x9a2eab['useBlurCloseExponentialShadowMap']){var _0x16a43a=_0x9a2eab['getShadowMapForRendering']();if(_0x16a43a){var _0x47f4aa=_0x16a43a['getInternalTexture']();_0x9a2eab['_scene']['postProcessManager']['directRender'](_0x9a2eab['_blurPostProcesses'],_0x47f4aa,!0x0),_0x36d53f['unBindFramebuffer'](_0x47f4aa,!0x0);}}});var _0x122513=new _0x39310d['b'](0x0,0x0,0x0,0x0),_0x49830f=new _0x39310d['b'](0x1,0x1,0x1,0x1);this['_shadowMap']['onClearObservable']['add'](function(_0x5a07c0){_0x9a2eab['_filter']===_0x3fb54f['FILTER_PCF']?_0x5a07c0['clear'](_0x49830f,!0x1,!0x0,!0x1):_0x9a2eab['useExponentialShadowMap']||_0x9a2eab['useBlurExponentialShadowMap']?_0x5a07c0['clear'](_0x122513,!0x0,!0x0,!0x1):_0x5a07c0['clear'](_0x49830f,!0x0,!0x0,!0x1);}),this['_shadowMap']['onResizeObservable']['add'](function(_0x46aa45){_0x9a2eab['_storedUniqueId']=_0x9a2eab['_shadowMap']['uniqueId'],_0x9a2eab['_mapSize']=_0x46aa45['getRenderSize'](),_0x9a2eab['_light']['_markMeshesAsLightDirty'](),_0x9a2eab['recreateShadowMap']();});for(var _0x5d78a6=_0x46a497['b']['MIN_RENDERINGGROUPS'];_0x5d78a6<_0x46a497['b']['MAX_RENDERINGGROUPS'];_0x5d78a6++)this['_shadowMap']['setRenderingAutoClearDepthStencil'](_0x5d78a6,!0x1);}},_0x3fb54f['prototype']['_initializeBlurRTTAndPostProcesses']=function(){var _0x1467dd=this,_0x639a4b=this['_scene']['getEngine'](),_0x4114ca=this['_mapSize']/this['blurScale'];this['useKernelBlur']&&0x1===this['blurScale']||(this['_shadowMap2']=new _0x310f87(this['_light']['name']+'_shadowMap2',_0x4114ca,this['_scene'],!0x1,!0x0,this['_textureType']),this['_shadowMap2']['wrapU']=_0xaf3c80['a']['CLAMP_ADDRESSMODE'],this['_shadowMap2']['wrapV']=_0xaf3c80['a']['CLAMP_ADDRESSMODE'],this['_shadowMap2']['updateSamplingMode'](_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'])),this['useKernelBlur']?(this['_kernelBlurXPostprocess']=new _0x487d78(this['_light']['name']+'KernelBlurX',new _0x74d525['d'](0x1,0x0),this['blurKernel'],0x1,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x639a4b,!0x1,this['_textureType']),this['_kernelBlurXPostprocess']['width']=_0x4114ca,this['_kernelBlurXPostprocess']['height']=_0x4114ca,this['_kernelBlurXPostprocess']['onApplyObservable']['add'](function(_0xfe8f44){_0xfe8f44['setTexture']('textureSampler',_0x1467dd['_shadowMap']);}),this['_kernelBlurYPostprocess']=new _0x487d78(this['_light']['name']+'KernelBlurY',new _0x74d525['d'](0x0,0x1),this['blurKernel'],0x1,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x639a4b,!0x1,this['_textureType']),this['_kernelBlurXPostprocess']['autoClear']=!0x1,this['_kernelBlurYPostprocess']['autoClear']=!0x1,this['_textureType']===_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']&&(this['_kernelBlurXPostprocess']['packedFloat']=!0x0,this['_kernelBlurYPostprocess']['packedFloat']=!0x0),this['_blurPostProcesses']=[this['_kernelBlurXPostprocess'],this['_kernelBlurYPostprocess']]):(this['_boxBlurPostprocess']=new _0x5cae84(this['_light']['name']+'DepthBoxBlur','depthBoxBlur',['screenSize','boxOffset'],[],0x1,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x639a4b,!0x1,'#define\x20OFFSET\x20'+this['_blurBoxOffset'],this['_textureType']),this['_boxBlurPostprocess']['onApplyObservable']['add'](function(_0x921796){_0x921796['setFloat2']('screenSize',_0x4114ca,_0x4114ca),_0x921796['setTexture']('textureSampler',_0x1467dd['_shadowMap']);}),this['_boxBlurPostprocess']['autoClear']=!0x1,this['_blurPostProcesses']=[this['_boxBlurPostprocess']]);},_0x3fb54f['prototype']['_renderForShadowMap']=function(_0x25b344,_0x10947e,_0x19943b,_0x56ff9d){var _0x2e622b,_0x2573fe=this['_scene']['getEngine'](),_0x77984f=_0x2573fe['getColorWrite']();if(_0x56ff9d['length']){for(_0x2573fe['setColorWrite'](!0x1),_0x2e622b=0x0;_0x2e622b<_0x56ff9d['length'];_0x2e622b++)this['_renderSubMeshForShadowMap'](_0x56ff9d['data'][_0x2e622b]);_0x2573fe['setColorWrite'](_0x77984f);}for(_0x2e622b=0x0;_0x2e622b<_0x25b344['length'];_0x2e622b++)this['_renderSubMeshForShadowMap'](_0x25b344['data'][_0x2e622b]);for(_0x2e622b=0x0;_0x2e622b<_0x10947e['length'];_0x2e622b++)this['_renderSubMeshForShadowMap'](_0x10947e['data'][_0x2e622b]);if(this['_transparencyShadow']){for(_0x2e622b=0x0;_0x2e622b<_0x19943b['length'];_0x2e622b++)this['_renderSubMeshForShadowMap'](_0x19943b['data'][_0x2e622b],!0x0);}else{for(_0x2e622b=0x0;_0x2e622b<_0x19943b['length'];_0x2e622b++)_0x19943b['data'][_0x2e622b]['getEffectiveMesh']()['_internalAbstractMeshDataInfo']['_isActiveIntermediate']=!0x1;}},_0x3fb54f['prototype']['_bindCustomEffectForRenderSubMeshForShadowMap']=function(_0x29262c,_0xc54c41,_0x4ef50b,_0x56491b){var _0x45e5d3,_0x1a30b5,_0x4ca6fe,_0x51acf7,_0x1ca9ee,_0x1e1faf;_0xc54c41['setMatrix'](null!==(_0x45e5d3=null==_0x4ef50b?void 0x0:_0x4ef50b['viewProjection'])&&void 0x0!==_0x45e5d3?_0x45e5d3:'viewProjection',this['getTransformMatrix']()),_0xc54c41['setMatrix'](null!==(_0x1a30b5=null==_0x4ef50b?void 0x0:_0x4ef50b['view'])&&void 0x0!==_0x1a30b5?_0x1a30b5:'view',this['_viewMatrix']),_0xc54c41['setMatrix'](null!==(_0x4ca6fe=null==_0x4ef50b?void 0x0:_0x4ef50b['projection'])&&void 0x0!==_0x4ca6fe?_0x4ca6fe:'projection',this['_projectionMatrix']);var _0x2dd3b7=_0x56491b['getWorldMatrix']();_0xc54c41['setMatrix'](null!==(_0x51acf7=null==_0x4ef50b?void 0x0:_0x4ef50b['world'])&&void 0x0!==_0x51acf7?_0x51acf7:'world',_0x2dd3b7),_0x2dd3b7['multiplyToRef'](this['getTransformMatrix'](),_0x58720b),_0xc54c41['setMatrix'](null!==(_0x1ca9ee=null==_0x4ef50b?void 0x0:_0x4ef50b['worldViewProjection'])&&void 0x0!==_0x1ca9ee?_0x1ca9ee:'worldViewProjection',_0x58720b),_0x2dd3b7['multiplyToRef'](this['_viewMatrix'],_0x42a66f),_0xc54c41['setMatrix'](null!==(_0x1e1faf=null==_0x4ef50b?void 0x0:_0x4ef50b['worldView'])&&void 0x0!==_0x1e1faf?_0x1e1faf:'worldView',_0x42a66f);},_0x3fb54f['prototype']['_renderSubMeshForShadowMap']=function(_0x18d25b,_0xbce5af){var _0x3d6aea,_0x5eca68;void 0x0===_0xbce5af&&(_0xbce5af=!0x1);var _0x1960b2=_0x18d25b['getRenderingMesh'](),_0x186389=_0x18d25b['getEffectiveMesh'](),_0x4c5541=this['_scene'],_0x12ef5a=_0x4c5541['getEngine'](),_0x37fa09=_0x18d25b['getMaterial']();if(_0x186389['_internalAbstractMeshDataInfo']['_isActiveIntermediate']=!0x1,_0x37fa09&&0x0!==_0x18d25b['verticesCount']&&_0x18d25b['_renderId']!==_0x4c5541['getRenderId']()){_0x12ef5a['setState'](_0x37fa09['backFaceCulling']);var _0x3397b3=_0x1960b2['_getInstancesRenderList'](_0x18d25b['_id'],!!_0x18d25b['getReplacementMesh']());if(!_0x3397b3['mustReturn']){var _0xbfdd68=_0x12ef5a['getCaps']()['instancedArrays']&&(null!==_0x3397b3['visibleInstances'][_0x18d25b['_id']]&&void 0x0!==_0x3397b3['visibleInstances'][_0x18d25b['_id']]||_0x1960b2['hasThinInstances']);if(!this['customAllowRendering']||this['customAllowRendering'](_0x18d25b)){if(this['isReady'](_0x18d25b,_0xbfdd68,_0xbce5af)){_0x18d25b['_renderId']=_0x4c5541['getRenderId']();var _0x44a139=null===(_0x3d6aea=_0x1960b2['material'])||void 0x0===_0x3d6aea?void 0x0:_0x3d6aea['shadowDepthWrapper'],_0x1afcd8=null!==(_0x5eca68=null==_0x44a139?void 0x0:_0x44a139['getEffect'](_0x18d25b,this))&&void 0x0!==_0x5eca68?_0x5eca68:this['_effect'];if(_0x12ef5a['enableEffect'](_0x1afcd8),_0x1960b2['_bind'](_0x18d25b,_0x1afcd8,_0x37fa09['fillMode']),this['getTransformMatrix'](),_0x1afcd8['setFloat3']('biasAndScaleSM',this['bias'],this['normalBias'],this['depthScale']),this['getLight']()['getTypeID']()===_0x4e3e4a['a']['LIGHTTYPEID_DIRECTIONALLIGHT']?_0x1afcd8['setVector3']('lightDataSM',this['_cachedDirection']):_0x1afcd8['setVector3']('lightDataSM',this['_cachedPosition']),_0x4c5541['activeCamera']&&_0x1afcd8['setFloat2']('depthValuesSM',this['getLight']()['getDepthMinZ'](_0x4c5541['activeCamera']),this['getLight']()['getDepthMinZ'](_0x4c5541['activeCamera'])+this['getLight']()['getDepthMaxZ'](_0x4c5541['activeCamera'])),_0xbce5af&&this['enableSoftTransparentShadow']&&_0x1afcd8['setFloat']('softTransparentShadowSM',_0x186389['visibility']),_0x44a139)_0x18d25b['_effectOverride']=_0x1afcd8,_0x44a139['standalone']?_0x44a139['baseMaterial']['bindForSubMesh'](_0x186389['getWorldMatrix'](),_0x1960b2,_0x18d25b):_0x37fa09['bindForSubMesh'](_0x186389['getWorldMatrix'](),_0x1960b2,_0x18d25b),_0x18d25b['_effectOverride']=null;else{if(_0x1afcd8['setMatrix']('viewProjection',this['getTransformMatrix']()),_0x37fa09&&_0x37fa09['needAlphaTesting']()){var _0x1706e3=_0x37fa09['getAlphaTestTexture']();_0x1706e3&&(_0x1afcd8['setTexture']('diffuseSampler',_0x1706e3),_0x1afcd8['setMatrix']('diffuseMatrix',_0x1706e3['getTextureMatrix']()||this['_defaultTextureMatrix']));}if(_0x1960b2['useBones']&&_0x1960b2['computeBonesUsingShaders']&&_0x1960b2['skeleton']){var _0x396eb4=_0x1960b2['skeleton'];if(_0x396eb4['isUsingTextureForMatrices']){var _0x3531e2=_0x396eb4['getTransformMatrixTexture'](_0x1960b2);if(!_0x3531e2)return;_0x1afcd8['setTexture']('boneSampler',_0x3531e2),_0x1afcd8['setFloat']('boneTextureWidth',0x4*(_0x396eb4['bones']['length']+0x1));}else _0x1afcd8['setMatrices']('mBones',_0x396eb4['getTransformMatrices'](_0x1960b2));}_0x464f31['a']['BindMorphTargetParameters'](_0x1960b2,_0x1afcd8),_0x464f31['a']['BindClipPlane'](_0x1afcd8,_0x4c5541);}this['_bindCustomEffectForRenderSubMeshForShadowMap'](_0x18d25b,_0x1afcd8,null==_0x44a139?void 0x0:_0x44a139['_matriceNames'],_0x186389),this['forceBackFacesOnly']&&_0x12ef5a['setState'](!0x0,0x0,!0x1,!0x0),this['onBeforeShadowMapRenderMeshObservable']['notifyObservers'](_0x1960b2),this['onBeforeShadowMapRenderObservable']['notifyObservers'](_0x1afcd8),_0x1960b2['_processRendering'](_0x186389,_0x18d25b,_0x1afcd8,_0x37fa09['fillMode'],_0x3397b3,_0xbfdd68,function(_0x360e0e,_0x2a937d){return _0x1afcd8['setMatrix']('world',_0x2a937d);}),this['forceBackFacesOnly']&&_0x12ef5a['setState'](!0x0,0x0,!0x1,!0x1),this['onAfterShadowMapRenderObservable']['notifyObservers'](_0x1afcd8),this['onAfterShadowMapRenderMeshObservable']['notifyObservers'](_0x1960b2);}else this['_shadowMap']&&this['_shadowMap']['resetRefreshCounter']();}}}},_0x3fb54f['prototype']['_applyFilterValues']=function(){this['_shadowMap']&&(this['filter']===_0x3fb54f['FILTER_NONE']||this['filter']===_0x3fb54f['FILTER_PCSS']?this['_shadowMap']['updateSamplingMode'](_0xaf3c80['a']['NEAREST_SAMPLINGMODE']):this['_shadowMap']['updateSamplingMode'](_0xaf3c80['a']['BILINEAR_SAMPLINGMODE']));},_0x3fb54f['prototype']['forceCompilation']=function(_0x462000,_0xb9c5c8){var _0x182da1=this,_0x847cbb=Object(_0x18e13d['a'])({'useInstances':!0x1},_0xb9c5c8),_0x1c16f5=this['getShadowMap']();if(_0x1c16f5){var _0x22d733=_0x1c16f5['renderList'];if(_0x22d733){for(var _0x25c1a3=new Array(),_0x2097f8=0x0,_0x1d76c3=_0x22d733;_0x2097f8<_0x1d76c3['length'];_0x2097f8++){var _0x360310=_0x1d76c3[_0x2097f8];_0x25c1a3['push']['apply'](_0x25c1a3,_0x360310['subMeshes']);}if(0x0!==_0x25c1a3['length']){var _0x2ecd42=0x0,_0x132642=function(){var _0x3fed5b,_0x18bdbd;if(_0x182da1['_scene']&&_0x182da1['_scene']['getEngine']()){for(;_0x182da1['isReady'](_0x25c1a3[_0x2ecd42],_0x847cbb['useInstances'],null!==(_0x18bdbd=null===(_0x3fed5b=_0x25c1a3[_0x2ecd42]['getMaterial']())||void 0x0===_0x3fed5b?void 0x0:_0x3fed5b['needAlphaBlendingForMesh'](_0x25c1a3[_0x2ecd42]['getMesh']()))&&void 0x0!==_0x18bdbd&&_0x18bdbd);)if(++_0x2ecd42>=_0x25c1a3['length'])return void(_0x462000&&_0x462000(_0x182da1));setTimeout(_0x132642,0x10);}};_0x132642();}else _0x462000&&_0x462000(this);}else _0x462000&&_0x462000(this);}else _0x462000&&_0x462000(this);},_0x3fb54f['prototype']['forceCompilationAsync']=function(_0x1b3aef){var _0x41e14c=this;return new Promise(function(_0x4e0a96){_0x41e14c['forceCompilation'](function(){_0x4e0a96();},_0x1b3aef);});},_0x3fb54f['prototype']['_isReadyCustomDefines']=function(_0x55be93,_0x115b6d,_0x549730){},_0x3fb54f['prototype']['_prepareShadowDefines']=function(_0x359ab2,_0x279cdb,_0x371a1b,_0x4e6c24){_0x371a1b['push']('#define\x20SM_FLOAT\x20'+(this['_textureType']!==_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']?'1':'0')),_0x371a1b['push']('#define\x20SM_ESM\x20'+(this['useExponentialShadowMap']||this['useBlurExponentialShadowMap']?'1':'0')),_0x371a1b['push']('#define\x20SM_DEPTHTEXTURE\x20'+(this['usePercentageCloserFiltering']||this['useContactHardeningShadow']?'1':'0'));var _0x425509=_0x359ab2['getMesh']();return _0x371a1b['push']('#define\x20SM_NORMALBIAS\x20'+(this['normalBias']&&_0x425509['isVerticesDataPresent'](_0x212fbd['b']['NormalKind'])?'1':'0')),_0x371a1b['push']('#define\x20SM_DIRECTIONINLIGHTDATA\x20'+(this['getLight']()['getTypeID']()===_0x4e3e4a['a']['LIGHTTYPEID_DIRECTIONALLIGHT']?'1':'0')),_0x371a1b['push']('#define\x20SM_USEDISTANCE\x20'+(this['_light']['needCube']()?'1':'0')),_0x371a1b['push']('#define\x20SM_SOFTTRANSPARENTSHADOW\x20'+(this['enableSoftTransparentShadow']&&_0x4e6c24?'1':'0')),this['_isReadyCustomDefines'](_0x371a1b,_0x359ab2,_0x279cdb),_0x371a1b;},_0x3fb54f['prototype']['isReady']=function(_0x5effca,_0x580b2b,_0x5806b0){var _0x467952=_0x5effca['getMaterial'](),_0x29f647=null==_0x467952?void 0x0:_0x467952['shadowDepthWrapper'],_0x3ad1b8=[];if(this['_prepareShadowDefines'](_0x5effca,_0x580b2b,_0x3ad1b8,_0x5806b0),_0x29f647){if(!_0x29f647['isReadyForSubMesh'](_0x5effca,_0x3ad1b8,this,_0x580b2b))return!0x1;}else{var _0x1dc801=[_0x212fbd['b']['PositionKind']],_0x3eabe0=_0x5effca['getMesh']();if(this['normalBias']&&_0x3eabe0['isVerticesDataPresent'](_0x212fbd['b']['NormalKind'])&&(_0x1dc801['push'](_0x212fbd['b']['NormalKind']),_0x3ad1b8['push']('#define\x20NORMAL'),_0x3eabe0['nonUniformScaling']&&_0x3ad1b8['push']('#define\x20NONUNIFORMSCALING')),_0x467952&&_0x467952['needAlphaTesting']()){var _0x50961a=_0x467952['getAlphaTestTexture']();if(_0x50961a){if(!_0x50961a['isReady']())return!0x1;_0x3ad1b8['push']('#define\x20ALPHATEST'),_0x3eabe0['isVerticesDataPresent'](_0x212fbd['b']['UVKind'])&&(_0x1dc801['push'](_0x212fbd['b']['UVKind']),_0x3ad1b8['push']('#define\x20UV1')),_0x3eabe0['isVerticesDataPresent'](_0x212fbd['b']['UV2Kind'])&&0x1===_0x50961a['coordinatesIndex']&&(_0x1dc801['push'](_0x212fbd['b']['UV2Kind']),_0x3ad1b8['push']('#define\x20UV2'));}}var _0x31ae3a=new _0x1603d9['a']();if(_0x3eabe0['useBones']&&_0x3eabe0['computeBonesUsingShaders']&&_0x3eabe0['skeleton']){_0x1dc801['push'](_0x212fbd['b']['MatricesIndicesKind']),_0x1dc801['push'](_0x212fbd['b']['MatricesWeightsKind']),_0x3eabe0['numBoneInfluencers']>0x4&&(_0x1dc801['push'](_0x212fbd['b']['MatricesIndicesExtraKind']),_0x1dc801['push'](_0x212fbd['b']['MatricesWeightsExtraKind']));var _0x1a016c=_0x3eabe0['skeleton'];_0x3ad1b8['push']('#define\x20NUM_BONE_INFLUENCERS\x20'+_0x3eabe0['numBoneInfluencers']),_0x3eabe0['numBoneInfluencers']>0x0&&_0x31ae3a['addCPUSkinningFallback'](0x0,_0x3eabe0),_0x1a016c['isUsingTextureForMatrices']?_0x3ad1b8['push']('#define\x20BONETEXTURE'):_0x3ad1b8['push']('#define\x20BonesPerMesh\x20'+(_0x1a016c['bones']['length']+0x1));}else _0x3ad1b8['push']('#define\x20NUM_BONE_INFLUENCERS\x200');var _0x50b49d=_0x3eabe0['morphTargetManager'],_0x30016f=0x0;_0x50b49d&&_0x50b49d['numInfluencers']>0x0&&(_0x3ad1b8['push']('#define\x20MORPHTARGETS'),_0x30016f=_0x50b49d['numInfluencers'],_0x3ad1b8['push']('#define\x20NUM_MORPH_INFLUENCERS\x20'+_0x30016f),_0x464f31['a']['PrepareAttributesForMorphTargetsInfluencers'](_0x1dc801,_0x3eabe0,_0x30016f));var _0x52cb17=this['_scene'];if(_0x52cb17['clipPlane']&&_0x3ad1b8['push']('#define\x20CLIPPLANE'),_0x52cb17['clipPlane2']&&_0x3ad1b8['push']('#define\x20CLIPPLANE2'),_0x52cb17['clipPlane3']&&_0x3ad1b8['push']('#define\x20CLIPPLANE3'),_0x52cb17['clipPlane4']&&_0x3ad1b8['push']('#define\x20CLIPPLANE4'),_0x52cb17['clipPlane5']&&_0x3ad1b8['push']('#define\x20CLIPPLANE5'),_0x52cb17['clipPlane6']&&_0x3ad1b8['push']('#define\x20CLIPPLANE6'),_0x580b2b&&(_0x3ad1b8['push']('#define\x20INSTANCES'),_0x464f31['a']['PushAttributesForInstances'](_0x1dc801),_0x5effca['getRenderingMesh']()['hasThinInstances']&&_0x3ad1b8['push']('#define\x20THIN_INSTANCES')),this['customShaderOptions']&&this['customShaderOptions']['defines'])for(var _0x1daf07=0x0,_0x1f49a4=this['customShaderOptions']['defines'];_0x1daf07<_0x1f49a4['length'];_0x1daf07++){var _0x4f451c=_0x1f49a4[_0x1daf07];-0x1===_0x3ad1b8['indexOf'](_0x4f451c)&&_0x3ad1b8['push'](_0x4f451c);}var _0x1b1673=_0x3ad1b8['join']('\x0a');if(this['_cachedDefines']!==_0x1b1673){this['_cachedDefines']=_0x1b1673;var _0x7250bb='shadowMap',_0x74d98a=['world','mBones','viewProjection','diffuseMatrix','lightDataSM','depthValuesSM','biasAndScaleSM','morphTargetInfluences','boneTextureWidth','vClipPlane','vClipPlane2','vClipPlane3','vClipPlane4','vClipPlane5','vClipPlane6','softTransparentShadowSM'],_0x312724=['diffuseSampler','boneSampler'];if(this['customShaderOptions']){if(_0x7250bb=this['customShaderOptions']['shaderName'],this['customShaderOptions']['attributes'])for(var _0x2421e7=0x0,_0x5ce017=this['customShaderOptions']['attributes'];_0x2421e7<_0x5ce017['length'];_0x2421e7++){var _0x5529c6=_0x5ce017[_0x2421e7];-0x1===_0x1dc801['indexOf'](_0x5529c6)&&_0x1dc801['push'](_0x5529c6);}if(this['customShaderOptions']['uniforms'])for(var _0x40a554=0x0,_0x526747=this['customShaderOptions']['uniforms'];_0x40a554<_0x526747['length'];_0x40a554++){var _0x262fa2=_0x526747[_0x40a554];-0x1===_0x74d98a['indexOf'](_0x262fa2)&&_0x74d98a['push'](_0x262fa2);}if(this['customShaderOptions']['samplers'])for(var _0x471439=0x0,_0x157994=this['customShaderOptions']['samplers'];_0x471439<_0x157994['length'];_0x471439++){var _0x33ad50=_0x157994[_0x471439];-0x1===_0x312724['indexOf'](_0x33ad50)&&_0x312724['push'](_0x33ad50);}}this['_effect']=this['_scene']['getEngine']()['createEffect'](_0x7250bb,_0x1dc801,_0x74d98a,_0x312724,_0x1b1673,_0x31ae3a,void 0x0,void 0x0,{'maxSimultaneousMorphTargets':_0x30016f});}if(!this['_effect']['isReady']())return!0x1;}return(this['useBlurExponentialShadowMap']||this['useBlurCloseExponentialShadowMap'])&&(this['_blurPostProcesses']&&this['_blurPostProcesses']['length']||this['_initializeBlurRTTAndPostProcesses']()),!(this['_kernelBlurXPostprocess']&&!this['_kernelBlurXPostprocess']['isReady']())&&(!(this['_kernelBlurYPostprocess']&&!this['_kernelBlurYPostprocess']['isReady']())&&!(this['_boxBlurPostprocess']&&!this['_boxBlurPostprocess']['isReady']()));},_0x3fb54f['prototype']['prepareDefines']=function(_0x2016f1,_0x38c90b){var _0x5d88af=this['_scene'],_0x16ac6b=this['_light'];_0x5d88af['shadowsEnabled']&&_0x16ac6b['shadowEnabled']&&(_0x2016f1['SHADOW'+_0x38c90b]=!0x0,this['useContactHardeningShadow']?(_0x2016f1['SHADOWPCSS'+_0x38c90b]=!0x0,this['_filteringQuality']===_0x3fb54f['QUALITY_LOW']?_0x2016f1['SHADOWLOWQUALITY'+_0x38c90b]=!0x0:this['_filteringQuality']===_0x3fb54f['QUALITY_MEDIUM']&&(_0x2016f1['SHADOWMEDIUMQUALITY'+_0x38c90b]=!0x0)):this['usePercentageCloserFiltering']?(_0x2016f1['SHADOWPCF'+_0x38c90b]=!0x0,this['_filteringQuality']===_0x3fb54f['QUALITY_LOW']?_0x2016f1['SHADOWLOWQUALITY'+_0x38c90b]=!0x0:this['_filteringQuality']===_0x3fb54f['QUALITY_MEDIUM']&&(_0x2016f1['SHADOWMEDIUMQUALITY'+_0x38c90b]=!0x0)):this['usePoissonSampling']?_0x2016f1['SHADOWPOISSON'+_0x38c90b]=!0x0:this['useExponentialShadowMap']||this['useBlurExponentialShadowMap']?_0x2016f1['SHADOWESM'+_0x38c90b]=!0x0:(this['useCloseExponentialShadowMap']||this['useBlurCloseExponentialShadowMap'])&&(_0x2016f1['SHADOWCLOSEESM'+_0x38c90b]=!0x0),_0x16ac6b['needCube']()&&(_0x2016f1['SHADOWCUBE'+_0x38c90b]=!0x0));},_0x3fb54f['prototype']['bindShadowLight']=function(_0x4f96cb,_0x377e33){var _0x486bb4=this['_light'],_0x213188=this['_scene'];if(_0x213188['shadowsEnabled']&&_0x486bb4['shadowEnabled']){var _0x15e7ad=_0x213188['activeCamera'];if(_0x15e7ad){var _0x2adb05=this['getShadowMap']();_0x2adb05&&(_0x486bb4['needCube']()||_0x377e33['setMatrix']('lightMatrix'+_0x4f96cb,this['getTransformMatrix']()),this['_filter']===_0x3fb54f['FILTER_PCF']?(_0x377e33['setDepthStencilTexture']('shadowSampler'+_0x4f96cb,this['getShadowMapForRendering']()),_0x486bb4['_uniformBuffer']['updateFloat4']('shadowsInfo',this['getDarkness'](),_0x2adb05['getSize']()['width'],0x1/_0x2adb05['getSize']()['width'],this['frustumEdgeFalloff'],_0x4f96cb)):this['_filter']===_0x3fb54f['FILTER_PCSS']?(_0x377e33['setDepthStencilTexture']('shadowSampler'+_0x4f96cb,this['getShadowMapForRendering']()),_0x377e33['setTexture']('depthSampler'+_0x4f96cb,this['getShadowMapForRendering']()),_0x486bb4['_uniformBuffer']['updateFloat4']('shadowsInfo',this['getDarkness'](),0x1/_0x2adb05['getSize']()['width'],this['_contactHardeningLightSizeUVRatio']*_0x2adb05['getSize']()['width'],this['frustumEdgeFalloff'],_0x4f96cb)):(_0x377e33['setTexture']('shadowSampler'+_0x4f96cb,this['getShadowMapForRendering']()),_0x486bb4['_uniformBuffer']['updateFloat4']('shadowsInfo',this['getDarkness'](),this['blurScale']/_0x2adb05['getSize']()['width'],this['depthScale'],this['frustumEdgeFalloff'],_0x4f96cb)),_0x486bb4['_uniformBuffer']['updateFloat2']('depthValues',this['getLight']()['getDepthMinZ'](_0x15e7ad),this['getLight']()['getDepthMinZ'](_0x15e7ad)+this['getLight']()['getDepthMaxZ'](_0x15e7ad),_0x4f96cb));}}},_0x3fb54f['prototype']['getTransformMatrix']=function(){var _0x2ec5ba=this['_scene'];if(this['_currentRenderID']===_0x2ec5ba['getRenderId']()&&this['_currentFaceIndexCache']===this['_currentFaceIndex'])return this['_transformMatrix'];this['_currentRenderID']=_0x2ec5ba['getRenderId'](),this['_currentFaceIndexCache']=this['_currentFaceIndex'];var _0x43257c=this['_light']['position'];if(this['_light']['computeTransformedInformation']()&&(_0x43257c=this['_light']['transformedPosition']),_0x74d525['e']['NormalizeToRef'](this['_light']['getShadowDirection'](this['_currentFaceIndex']),this['_lightDirection']),0x1===Math['abs'](_0x74d525['e']['Dot'](this['_lightDirection'],_0x74d525['e']['Up']()))&&(this['_lightDirection']['z']=1e-13),this['_light']['needProjectionMatrixCompute']()||!this['_cachedPosition']||!this['_cachedDirection']||!_0x43257c['equals'](this['_cachedPosition'])||!this['_lightDirection']['equals'](this['_cachedDirection'])){this['_cachedPosition']['copyFrom'](_0x43257c),this['_cachedDirection']['copyFrom'](this['_lightDirection']),_0x74d525['a']['LookAtLHToRef'](_0x43257c,_0x43257c['add'](this['_lightDirection']),_0x74d525['e']['Up'](),this['_viewMatrix']);var _0x44f9c8=this['getShadowMap']();if(_0x44f9c8){var _0x44a885=_0x44f9c8['renderList'];_0x44a885&&this['_light']['setShadowProjectionMatrix'](this['_projectionMatrix'],this['_viewMatrix'],_0x44a885);}this['_viewMatrix']['multiplyToRef'](this['_projectionMatrix'],this['_transformMatrix']);}return this['_transformMatrix'];},_0x3fb54f['prototype']['recreateShadowMap']=function(){var _0x2fcbc1=this['_shadowMap'];if(_0x2fcbc1){var _0x66b47a=_0x2fcbc1['renderList'];this['_disposeRTTandPostProcesses'](),this['_initializeGenerator'](),this['filter']=this['filter'],this['_applyFilterValues'](),this['_shadowMap']['renderList']=_0x66b47a;}},_0x3fb54f['prototype']['_disposeBlurPostProcesses']=function(){this['_shadowMap2']&&(this['_shadowMap2']['dispose'](),this['_shadowMap2']=null),this['_boxBlurPostprocess']&&(this['_boxBlurPostprocess']['dispose'](),this['_boxBlurPostprocess']=null),this['_kernelBlurXPostprocess']&&(this['_kernelBlurXPostprocess']['dispose'](),this['_kernelBlurXPostprocess']=null),this['_kernelBlurYPostprocess']&&(this['_kernelBlurYPostprocess']['dispose'](),this['_kernelBlurYPostprocess']=null),this['_blurPostProcesses']=[];},_0x3fb54f['prototype']['_disposeRTTandPostProcesses']=function(){this['_shadowMap']&&(this['_shadowMap']['dispose'](),this['_shadowMap']=null),this['_disposeBlurPostProcesses']();},_0x3fb54f['prototype']['dispose']=function(){this['_disposeRTTandPostProcesses'](),this['_light']&&(this['_light']['_shadowGenerator']=null,this['_light']['_markMeshesAsLightDirty']()),this['onBeforeShadowMapRenderMeshObservable']['clear'](),this['onBeforeShadowMapRenderObservable']['clear'](),this['onAfterShadowMapRenderMeshObservable']['clear'](),this['onAfterShadowMapRenderObservable']['clear']();},_0x3fb54f['prototype']['serialize']=function(){var _0x49f855={},_0x4894ca=this['getShadowMap']();if(!_0x4894ca)return _0x49f855;if(_0x49f855['className']=this['getClassName'](),_0x49f855['lightId']=this['_light']['id'],_0x49f855['id']=this['_light']['id'],_0x49f855['mapSize']=_0x4894ca['getRenderSize'](),_0x49f855['forceBackFacesOnly']=this['forceBackFacesOnly'],_0x49f855['darkness']=this['getDarkness'](),_0x49f855['transparencyShadow']=this['_transparencyShadow'],_0x49f855['frustumEdgeFalloff']=this['frustumEdgeFalloff'],_0x49f855['bias']=this['bias'],_0x49f855['normalBias']=this['normalBias'],_0x49f855['usePercentageCloserFiltering']=this['usePercentageCloserFiltering'],_0x49f855['useContactHardeningShadow']=this['useContactHardeningShadow'],_0x49f855['contactHardeningLightSizeUVRatio']=this['contactHardeningLightSizeUVRatio'],_0x49f855['filteringQuality']=this['filteringQuality'],_0x49f855['useExponentialShadowMap']=this['useExponentialShadowMap'],_0x49f855['useBlurExponentialShadowMap']=this['useBlurExponentialShadowMap'],_0x49f855['useCloseExponentialShadowMap']=this['useBlurExponentialShadowMap'],_0x49f855['useBlurCloseExponentialShadowMap']=this['useBlurExponentialShadowMap'],_0x49f855['usePoissonSampling']=this['usePoissonSampling'],_0x49f855['depthScale']=this['depthScale'],_0x49f855['blurBoxOffset']=this['blurBoxOffset'],_0x49f855['blurKernel']=this['blurKernel'],_0x49f855['blurScale']=this['blurScale'],_0x49f855['useKernelBlur']=this['useKernelBlur'],_0x49f855['renderList']=[],_0x4894ca['renderList'])for(var _0x234746=0x0;_0x234746<_0x4894ca['renderList']['length'];_0x234746++){var _0x4bc193=_0x4894ca['renderList'][_0x234746];_0x49f855['renderList']['push'](_0x4bc193['id']);}return _0x49f855;},_0x3fb54f['Parse']=function(_0x5d5393,_0x3c00f3,_0x273bbc){for(var _0x403b25=_0x3c00f3['getLightByID'](_0x5d5393['lightId']),_0x856813=_0x273bbc?_0x273bbc(_0x5d5393['mapSize'],_0x403b25):new _0x3fb54f(_0x5d5393['mapSize'],_0x403b25),_0x2b6ffd=_0x856813['getShadowMap'](),_0x4e24c8=0x0;_0x4e24c8<_0x5d5393['renderList']['length'];_0x4e24c8++){_0x3c00f3['getMeshesByID'](_0x5d5393['renderList'][_0x4e24c8])['forEach'](function(_0x1d5d4d){_0x2b6ffd&&(_0x2b6ffd['renderList']||(_0x2b6ffd['renderList']=[]),_0x2b6ffd['renderList']['push'](_0x1d5d4d));});}return void 0x0!==_0x5d5393['id']&&(_0x856813['id']=_0x5d5393['id']),_0x856813['forceBackFacesOnly']=!!_0x5d5393['forceBackFacesOnly'],void 0x0!==_0x5d5393['darkness']&&_0x856813['setDarkness'](_0x5d5393['darkness']),_0x5d5393['transparencyShadow']&&_0x856813['setTransparencyShadow'](!0x0),void 0x0!==_0x5d5393['frustumEdgeFalloff']&&(_0x856813['frustumEdgeFalloff']=_0x5d5393['frustumEdgeFalloff']),void 0x0!==_0x5d5393['bias']&&(_0x856813['bias']=_0x5d5393['bias']),void 0x0!==_0x5d5393['normalBias']&&(_0x856813['normalBias']=_0x5d5393['normalBias']),_0x5d5393['usePercentageCloserFiltering']?_0x856813['usePercentageCloserFiltering']=!0x0:_0x5d5393['useContactHardeningShadow']?_0x856813['useContactHardeningShadow']=!0x0:_0x5d5393['usePoissonSampling']?_0x856813['usePoissonSampling']=!0x0:_0x5d5393['useExponentialShadowMap']?_0x856813['useExponentialShadowMap']=!0x0:_0x5d5393['useBlurExponentialShadowMap']?_0x856813['useBlurExponentialShadowMap']=!0x0:_0x5d5393['useCloseExponentialShadowMap']?_0x856813['useCloseExponentialShadowMap']=!0x0:_0x5d5393['useBlurCloseExponentialShadowMap']?_0x856813['useBlurCloseExponentialShadowMap']=!0x0:_0x5d5393['useVarianceShadowMap']?_0x856813['useExponentialShadowMap']=!0x0:_0x5d5393['useBlurVarianceShadowMap']&&(_0x856813['useBlurExponentialShadowMap']=!0x0),void 0x0!==_0x5d5393['contactHardeningLightSizeUVRatio']&&(_0x856813['contactHardeningLightSizeUVRatio']=_0x5d5393['contactHardeningLightSizeUVRatio']),void 0x0!==_0x5d5393['filteringQuality']&&(_0x856813['filteringQuality']=_0x5d5393['filteringQuality']),_0x5d5393['depthScale']&&(_0x856813['depthScale']=_0x5d5393['depthScale']),_0x5d5393['blurScale']&&(_0x856813['blurScale']=_0x5d5393['blurScale']),_0x5d5393['blurBoxOffset']&&(_0x856813['blurBoxOffset']=_0x5d5393['blurBoxOffset']),_0x5d5393['useKernelBlur']&&(_0x856813['useKernelBlur']=_0x5d5393['useKernelBlur']),_0x5d5393['blurKernel']&&(_0x856813['blurKernel']=_0x5d5393['blurKernel']),_0x856813;},_0x3fb54f['CLASSNAME']='ShadowGenerator',_0x3fb54f['FILTER_NONE']=0x0,_0x3fb54f['FILTER_EXPONENTIALSHADOWMAP']=0x1,_0x3fb54f['FILTER_POISSONSAMPLING']=0x2,_0x3fb54f['FILTER_BLUREXPONENTIALSHADOWMAP']=0x3,_0x3fb54f['FILTER_CLOSEEXPONENTIALSHADOWMAP']=0x4,_0x3fb54f['FILTER_BLURCLOSEEXPONENTIALSHADOWMAP']=0x5,_0x3fb54f['FILTER_PCF']=0x6,_0x3fb54f['FILTER_PCSS']=0x7,_0x3fb54f['QUALITY_HIGH']=0x0,_0x3fb54f['QUALITY_MEDIUM']=0x1,_0x3fb54f['QUALITY_LOW']=0x2,_0x3fb54f['_SceneComponentInitialization']=function(_0x5566c8){throw _0x2de344['a']['WarnImport']('ShadowGeneratorSceneComponent');},_0x3fb54f;}()),_0x3834bb='#ifdef\x20ALPHATEST\x0avarying\x20vec2\x20vUV;\x0auniform\x20sampler2D\x20diffuseSampler;\x0a#endif\x0avarying\x20float\x20vDepthMetric;\x0a#ifdef\x20PACKED\x0a#include\x0a#endif\x0avoid\x20main(void)\x0a{\x0a#ifdef\x20ALPHATEST\x0aif\x20(texture2D(diffuseSampler,vUV).a<0.4)\x0adiscard;\x0a#endif\x0a#ifdef\x20NONLINEARDEPTH\x0a#ifdef\x20PACKED\x0agl_FragColor=pack(gl_FragCoord.z);\x0a#else\x0agl_FragColor=vec4(gl_FragCoord.z,0.0,0.0,0.0);\x0a#endif\x0a#else\x0a#ifdef\x20PACKED\x0agl_FragColor=pack(vDepthMetric);\x0a#else\x0agl_FragColor=vec4(vDepthMetric,0.0,0.0,1.0);\x0a#endif\x0a#endif\x0a}';_0x494b01['a']['ShadersStore']['depthPixelShader']=_0x3834bb;var _0x4ebca8='\x0aattribute\x20vec3\x20position;\x0a#include\x0a#include\x0a#include[0..maxSimultaneousMorphTargets]\x0a\x0a#include\x0auniform\x20mat4\x20viewProjection;\x0auniform\x20vec2\x20depthValues;\x0a#if\x20defined(ALPHATEST)\x20||\x20defined(NEED_UV)\x0avarying\x20vec2\x20vUV;\x0auniform\x20mat4\x20diffuseMatrix;\x0a#ifdef\x20UV1\x0aattribute\x20vec2\x20uv;\x0a#endif\x0a#ifdef\x20UV2\x0aattribute\x20vec2\x20uv2;\x0a#endif\x0a#endif\x0avarying\x20float\x20vDepthMetric;\x0avoid\x20main(void)\x0a{\x0avec3\x20positionUpdated=position;\x0a#ifdef\x20UV1\x0avec2\x20uvUpdated=uv;\x0a#endif\x0a#include[0..maxSimultaneousMorphTargets]\x0a#include\x0a#include\x0agl_Position=viewProjection*finalWorld*vec4(positionUpdated,1.0);\x0avDepthMetric=((gl_Position.z+depthValues.x)/(depthValues.y));\x0a#if\x20defined(ALPHATEST)\x20||\x20defined(BASIC_RENDER)\x0a#ifdef\x20UV1\x0avUV=vec2(diffuseMatrix*vec4(uvUpdated,1.0,0.0));\x0a#endif\x0a#ifdef\x20UV2\x0avUV=vec2(diffuseMatrix*vec4(uv2,1.0,0.0));\x0a#endif\x0a#endif\x0a}\x0a';_0x494b01['a']['ShadersStore']['depthVertexShader']=_0x4ebca8;var _0x4ba7ed=(function(){function _0x1e75ea(_0x2dc160,_0x567dc5,_0x4f5362,_0x3531da){var _0x487a0a=this;void 0x0===_0x567dc5&&(_0x567dc5=_0x2103ba['a']['TEXTURETYPE_FLOAT']),void 0x0===_0x4f5362&&(_0x4f5362=null),void 0x0===_0x3531da&&(_0x3531da=!0x1),this['enabled']=!0x0,this['useOnlyInActiveCamera']=!0x1,this['_scene']=_0x2dc160,this['_storeNonLinearDepth']=_0x3531da,this['isPacked']=_0x567dc5===_0x2103ba['a']['TEXTURETYPE_UNSIGNED_BYTE'],this['isPacked']?this['_clearColor']=new _0x39310d['b'](0x1,0x1,0x1,0x1):this['_clearColor']=new _0x39310d['b'](0x1,0x0,0x0,0x1),_0x1e75ea['_SceneComponentInitialization'](this['_scene']),this['_camera']=_0x4f5362;var _0x3705c0=_0x2dc160['getEngine'](),_0x4bfb31=this['isPacked']||0x1===_0x3705c0['webGLVersion']?_0x2103ba['a']['TEXTUREFORMAT_RGBA']:_0x2103ba['a']['TEXTUREFORMAT_R'];this['_depthMap']=new _0x310f87('depthMap',{'width':_0x3705c0['getRenderWidth'](),'height':_0x3705c0['getRenderHeight']()},this['_scene'],!0x1,!0x0,_0x567dc5,!0x1,void 0x0,void 0x0,void 0x0,void 0x0,_0x4bfb31),this['_depthMap']['wrapU']=_0xaf3c80['a']['CLAMP_ADDRESSMODE'],this['_depthMap']['wrapV']=_0xaf3c80['a']['CLAMP_ADDRESSMODE'],this['_depthMap']['refreshRate']=0x1,this['_depthMap']['renderParticles']=!0x1,this['_depthMap']['renderList']=null,this['_depthMap']['activeCamera']=this['_camera'],this['_depthMap']['ignoreCameraViewport']=!0x0,this['_depthMap']['useCameraPostProcesses']=!0x1,this['_depthMap']['onClearObservable']['add'](function(_0x305493){_0x305493['clear'](_0x487a0a['_clearColor'],!0x0,!0x0,!0x0);});var _0x1d951a=function(_0x3143f3){var _0xef3768=_0x3143f3['getRenderingMesh'](),_0x2a0ab0=_0x3143f3['getEffectiveMesh'](),_0x507d9d=_0x487a0a['_scene'],_0x4e8ace=_0x507d9d['getEngine'](),_0x843538=_0x3143f3['getMaterial']();if(_0x2a0ab0['_internalAbstractMeshDataInfo']['_isActiveIntermediate']=!0x1,_0x843538&&0x0!==_0x3143f3['verticesCount']&&_0x3143f3['_renderId']!==_0x507d9d['getRenderId']()){_0x4e8ace['setState'](_0x843538['backFaceCulling'],0x0,!0x1,_0x507d9d['useRightHandedSystem']);var _0x4beb74=_0xef3768['_getInstancesRenderList'](_0x3143f3['_id'],!!_0x3143f3['getReplacementMesh']());if(!_0x4beb74['mustReturn']){var _0x489afd=_0x4e8ace['getCaps']()['instancedArrays']&&(null!==_0x4beb74['visibleInstances'][_0x3143f3['_id']]&&void 0x0!==_0x4beb74['visibleInstances'][_0x3143f3['_id']]||_0xef3768['hasThinInstances']),_0xbbe1e4=_0x487a0a['_camera']||_0x507d9d['activeCamera'];if(_0x487a0a['isReady'](_0x3143f3,_0x489afd)&&_0xbbe1e4){if(_0x3143f3['_renderId']=_0x507d9d['getRenderId'](),_0x4e8ace['enableEffect'](_0x487a0a['_effect']),_0xef3768['_bind'](_0x3143f3,_0x487a0a['_effect'],_0x843538['fillMode']),_0x487a0a['_effect']['setMatrix']('viewProjection',_0x507d9d['getTransformMatrix']()),_0x487a0a['_effect']['setFloat2']('depthValues',_0xbbe1e4['minZ'],_0xbbe1e4['minZ']+_0xbbe1e4['maxZ']),_0x843538&&_0x843538['needAlphaTesting']()){var _0x36713d=_0x843538['getAlphaTestTexture']();_0x36713d&&(_0x487a0a['_effect']['setTexture']('diffuseSampler',_0x36713d),_0x487a0a['_effect']['setMatrix']('diffuseMatrix',_0x36713d['getTextureMatrix']()));}_0xef3768['useBones']&&_0xef3768['computeBonesUsingShaders']&&_0xef3768['skeleton']&&_0x487a0a['_effect']['setMatrices']('mBones',_0xef3768['skeleton']['getTransformMatrices'](_0xef3768)),_0x464f31['a']['BindMorphTargetParameters'](_0xef3768,_0x487a0a['_effect']),_0xef3768['_processRendering'](_0x2a0ab0,_0x3143f3,_0x487a0a['_effect'],_0x843538['fillMode'],_0x4beb74,_0x489afd,function(_0x545a99,_0x2d2651){return _0x487a0a['_effect']['setMatrix']('world',_0x2d2651);});}}}};this['_depthMap']['customRenderFunction']=function(_0x1bdb7a,_0x34f3cf,_0x227d5d,_0x156aef){var _0x3b1281;if(_0x156aef['length']){for(_0x3705c0['setColorWrite'](!0x1),_0x3b1281=0x0;_0x3b1281<_0x156aef['length'];_0x3b1281++)_0x1d951a(_0x156aef['data'][_0x3b1281]);_0x3705c0['setColorWrite'](!0x0);}for(_0x3b1281=0x0;_0x3b1281<_0x1bdb7a['length'];_0x3b1281++)_0x1d951a(_0x1bdb7a['data'][_0x3b1281]);for(_0x3b1281=0x0;_0x3b1281<_0x34f3cf['length'];_0x3b1281++)_0x1d951a(_0x34f3cf['data'][_0x3b1281]);};}return _0x1e75ea['prototype']['isReady']=function(_0x3d303f,_0x3d8974){var _0x3bdb7b=_0x3d303f['getMaterial']();if(_0x3bdb7b['disableDepthWrite'])return!0x1;var _0x24abd7=[],_0x52ffa9=[_0x212fbd['b']['PositionKind']],_0x33f1cb=_0x3d303f['getMesh']();_0x3bdb7b&&_0x3bdb7b['needAlphaTesting']()&&_0x3bdb7b['getAlphaTestTexture']()&&(_0x24abd7['push']('#define\x20ALPHATEST'),_0x33f1cb['isVerticesDataPresent'](_0x212fbd['b']['UVKind'])&&(_0x52ffa9['push'](_0x212fbd['b']['UVKind']),_0x24abd7['push']('#define\x20UV1')),_0x33f1cb['isVerticesDataPresent'](_0x212fbd['b']['UV2Kind'])&&(_0x52ffa9['push'](_0x212fbd['b']['UV2Kind']),_0x24abd7['push']('#define\x20UV2'))),_0x33f1cb['useBones']&&_0x33f1cb['computeBonesUsingShaders']?(_0x52ffa9['push'](_0x212fbd['b']['MatricesIndicesKind']),_0x52ffa9['push'](_0x212fbd['b']['MatricesWeightsKind']),_0x33f1cb['numBoneInfluencers']>0x4&&(_0x52ffa9['push'](_0x212fbd['b']['MatricesIndicesExtraKind']),_0x52ffa9['push'](_0x212fbd['b']['MatricesWeightsExtraKind'])),_0x24abd7['push']('#define\x20NUM_BONE_INFLUENCERS\x20'+_0x33f1cb['numBoneInfluencers']),_0x24abd7['push']('#define\x20BonesPerMesh\x20'+(_0x33f1cb['skeleton']?_0x33f1cb['skeleton']['bones']['length']+0x1:0x0))):_0x24abd7['push']('#define\x20NUM_BONE_INFLUENCERS\x200');var _0x874d16=_0x33f1cb['morphTargetManager'],_0x3439ea=0x0;_0x874d16&&_0x874d16['numInfluencers']>0x0&&(_0x3439ea=_0x874d16['numInfluencers'],_0x24abd7['push']('#define\x20MORPHTARGETS'),_0x24abd7['push']('#define\x20NUM_MORPH_INFLUENCERS\x20'+_0x3439ea),_0x464f31['a']['PrepareAttributesForMorphTargetsInfluencers'](_0x52ffa9,_0x33f1cb,_0x3439ea)),_0x3d8974&&(_0x24abd7['push']('#define\x20INSTANCES'),_0x464f31['a']['PushAttributesForInstances'](_0x52ffa9),_0x3d303f['getRenderingMesh']()['hasThinInstances']&&_0x24abd7['push']('#define\x20THIN_INSTANCES')),this['_storeNonLinearDepth']&&_0x24abd7['push']('#define\x20NONLINEARDEPTH'),this['isPacked']&&_0x24abd7['push']('#define\x20PACKED');var _0x4727c9=_0x24abd7['join']('\x0a');return this['_cachedDefines']!==_0x4727c9&&(this['_cachedDefines']=_0x4727c9,this['_effect']=this['_scene']['getEngine']()['createEffect']('depth',_0x52ffa9,['world','mBones','viewProjection','diffuseMatrix','depthValues','morphTargetInfluences'],['diffuseSampler'],_0x4727c9,void 0x0,void 0x0,void 0x0,{'maxSimultaneousMorphTargets':_0x3439ea})),this['_effect']['isReady']();},_0x1e75ea['prototype']['getDepthMap']=function(){return this['_depthMap'];},_0x1e75ea['prototype']['dispose']=function(){this['_depthMap']['dispose']();},_0x1e75ea['_SceneComponentInitialization']=function(_0x161633){throw _0x2de344['a']['WarnImport']('DepthRendererSceneComponent');},_0x1e75ea;}()),_0x18cdc5='attribute\x20vec2\x20vUV;\x0auniform\x20sampler2D\x20textureSampler;\x0a#if\x20defined(INITIAL)\x0auniform\x20sampler2D\x20sourceTexture;\x0auniform\x20vec2\x20texSize;\x0avoid\x20main(void)\x0a{\x0aivec2\x20coord=ivec2(vUV*(texSize-1.0));\x0afloat\x20f1=texelFetch(sourceTexture,coord,0).r;\x0afloat\x20f2=texelFetch(sourceTexture,coord+ivec2(1,0),0).r;\x0afloat\x20f3=texelFetch(sourceTexture,coord+ivec2(1,1),0).r;\x0afloat\x20f4=texelFetch(sourceTexture,coord+ivec2(0,1),0).r;\x0afloat\x20minz=min(min(min(f1,f2),f3),f4);\x0a#ifdef\x20DEPTH_REDUX\x0afloat\x20maxz=max(max(max(sign(1.0-f1)*f1,sign(1.0-f2)*f2),sign(1.0-f3)*f3),sign(1.0-f4)*f4);\x0a#else\x0afloat\x20maxz=max(max(max(f1,f2),f3),f4);\x0a#endif\x0aglFragColor=vec4(minz,maxz,0.,0.);\x0a}\x0a#elif\x20defined(MAIN)\x0auniform\x20vec2\x20texSize;\x0avoid\x20main(void)\x0a{\x0aivec2\x20coord=ivec2(vUV*(texSize-1.0));\x0avec2\x20f1=texelFetch(textureSampler,coord,0).rg;\x0avec2\x20f2=texelFetch(textureSampler,coord+ivec2(1,0),0).rg;\x0avec2\x20f3=texelFetch(textureSampler,coord+ivec2(1,1),0).rg;\x0avec2\x20f4=texelFetch(textureSampler,coord+ivec2(0,1),0).rg;\x0afloat\x20minz=min(min(min(f1.x,f2.x),f3.x),f4.x);\x0afloat\x20maxz=max(max(max(f1.y,f2.y),f3.y),f4.y);\x0aglFragColor=vec4(minz,maxz,0.,0.);\x0a}\x0a#elif\x20defined(ONEBEFORELAST)\x0auniform\x20ivec2\x20texSize;\x0avoid\x20main(void)\x0a{\x0aivec2\x20coord=ivec2(vUV*vec2(texSize-1));\x0avec2\x20f1=texelFetch(textureSampler,coord\x20%\x20texSize,0).rg;\x0avec2\x20f2=texelFetch(textureSampler,(coord+ivec2(1,0))\x20%\x20texSize,0).rg;\x0avec2\x20f3=texelFetch(textureSampler,(coord+ivec2(1,1))\x20%\x20texSize,0).rg;\x0avec2\x20f4=texelFetch(textureSampler,(coord+ivec2(0,1))\x20%\x20texSize,0).rg;\x0afloat\x20minz=min(f1.x,f2.x);\x0afloat\x20maxz=max(f1.y,f2.y);\x0aglFragColor=vec4(minz,maxz,0.,0.);\x0a}\x0a#elif\x20defined(LAST)\x0avoid\x20main(void)\x0a{\x0adiscard;\x0aglFragColor=vec4(0.);\x0a}\x0a#endif\x0a';_0x494b01['a']['ShadersStore']['minmaxReduxPixelShader']=_0x18cdc5;var _0x5be8fc=(function(){function _0xd66104(_0x471fdf){this['onAfterReductionPerformed']=new _0x6ac1f7['c'](),this['_forceFullscreenViewport']=!0x0,this['_activated']=!0x1,this['_camera']=_0x471fdf,this['_postProcessManager']=new _0x1a1fc2['a'](_0x471fdf['getScene']());}return Object['defineProperty'](_0xd66104['prototype'],'sourceTexture',{'get':function(){return this['_sourceTexture'];},'enumerable':!0x1,'configurable':!0x0}),_0xd66104['prototype']['setSourceTexture']=function(_0x322719,_0x329465,_0x538ec5,_0x342889){var _0x789028=this;if(void 0x0===_0x538ec5&&(_0x538ec5=_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT']),void 0x0===_0x342889&&(_0x342889=!0x0),_0x322719!==this['_sourceTexture']){this['dispose'](!0x1),this['_sourceTexture']=_0x322719,this['_reductionSteps']=[],this['_forceFullscreenViewport']=_0x342889;var _0x420cc3=this['_camera']['getScene'](),_0x37481f=new _0x5cae84('Initial\x20reduction\x20phase','minmaxRedux',['texSize'],['sourceTexture'],0x1,null,_0x2103ba['a']['TEXTURE_NEAREST_NEAREST'],_0x420cc3['getEngine'](),!0x1,'#define\x20INITIAL'+(_0x329465?'\x0a#define\x20DEPTH_REDUX':''),_0x538ec5,void 0x0,void 0x0,void 0x0,_0x2103ba['a']['TEXTUREFORMAT_RG']);_0x37481f['autoClear']=!0x1,_0x37481f['forceFullscreenViewport']=_0x342889;var _0x2de59a=this['_sourceTexture']['getRenderWidth'](),_0x47e4c7=this['_sourceTexture']['getRenderHeight']();_0x37481f['onApply']=function(_0x1c1653,_0x31c1c9){return function(_0x4c1c12){_0x4c1c12['setTexture']('sourceTexture',_0x789028['_sourceTexture']),_0x4c1c12['setFloatArray2']('texSize',new Float32Array([_0x1c1653,_0x31c1c9]));};}(_0x2de59a,_0x47e4c7),this['_reductionSteps']['push'](_0x37481f);for(var _0x3ee06a=0x1;_0x2de59a>0x1||_0x47e4c7>0x1;){_0x2de59a=Math['max'](Math['round'](_0x2de59a/0x2),0x1),_0x47e4c7=Math['max'](Math['round'](_0x47e4c7/0x2),0x1);var _0x2fc708=new _0x5cae84('Reduction\x20phase\x20'+_0x3ee06a,'minmaxRedux',['texSize'],null,{'width':_0x2de59a,'height':_0x47e4c7},null,_0x2103ba['a']['TEXTURE_NEAREST_NEAREST'],_0x420cc3['getEngine'](),!0x1,'#define\x20'+(0x1==_0x2de59a&&0x1==_0x47e4c7?'LAST':0x1==_0x2de59a||0x1==_0x47e4c7?'ONEBEFORELAST':'MAIN'),_0x538ec5,void 0x0,void 0x0,void 0x0,_0x2103ba['a']['TEXTUREFORMAT_RG']);(_0x2fc708['autoClear']=!0x1,_0x2fc708['forceFullscreenViewport']=_0x342889,_0x2fc708['onApply']=function(_0x350358,_0x48c786){return function(_0x1bde3a){0x1==_0x350358||0x1==_0x48c786?_0x1bde3a['setIntArray2']('texSize',new Int32Array([_0x350358,_0x48c786])):_0x1bde3a['setFloatArray2']('texSize',new Float32Array([_0x350358,_0x48c786]));};}(_0x2de59a,_0x47e4c7),this['_reductionSteps']['push'](_0x2fc708),_0x3ee06a++,0x1==_0x2de59a&&0x1==_0x47e4c7)&&_0x2fc708['onAfterRenderObservable']['add'](function(_0x23e8f8,_0x407074,_0x2f8831){var _0x42e00b=new Float32Array(0x4*_0x23e8f8*_0x407074),_0x4c7f19={'min':0x0,'max':0x0};return function(){_0x420cc3['getEngine']()['_readTexturePixels'](_0x2f8831['inputTexture'],_0x23e8f8,_0x407074,-0x1,0x0,_0x42e00b),_0x4c7f19['min']=_0x42e00b[0x0],_0x4c7f19['max']=_0x42e00b[0x1],_0x789028['onAfterReductionPerformed']['notifyObservers'](_0x4c7f19);};}(_0x2de59a,_0x47e4c7,_0x2fc708));}}},Object['defineProperty'](_0xd66104['prototype'],'refreshRate',{'get':function(){return this['_sourceTexture']?this['_sourceTexture']['refreshRate']:-0x1;},'set':function(_0x339ad1){this['_sourceTexture']&&(this['_sourceTexture']['refreshRate']=_0x339ad1);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xd66104['prototype'],'activated',{'get':function(){return this['_activated'];},'enumerable':!0x1,'configurable':!0x0}),_0xd66104['prototype']['activate']=function(){var _0x47e9b7=this;!this['_onAfterUnbindObserver']&&this['_sourceTexture']&&(this['_onAfterUnbindObserver']=this['_sourceTexture']['onAfterUnbindObservable']['add'](function(){_0x47e9b7['_reductionSteps'][0x0]['activate'](_0x47e9b7['_camera']),_0x47e9b7['_postProcessManager']['directRender'](_0x47e9b7['_reductionSteps'],_0x47e9b7['_reductionSteps'][0x0]['inputTexture'],_0x47e9b7['_forceFullscreenViewport']),_0x47e9b7['_camera']['getScene']()['getEngine']()['unBindFramebuffer'](_0x47e9b7['_reductionSteps'][0x0]['inputTexture'],!0x1);}),this['_activated']=!0x0);},_0xd66104['prototype']['deactivate']=function(){this['_onAfterUnbindObserver']&&this['_sourceTexture']&&(this['_sourceTexture']['onAfterUnbindObservable']['remove'](this['_onAfterUnbindObserver']),this['_onAfterUnbindObserver']=null,this['_activated']=!0x1);},_0xd66104['prototype']['dispose']=function(_0x5f0e57){if(void 0x0===_0x5f0e57&&(_0x5f0e57=!0x0),_0x5f0e57&&this['onAfterReductionPerformed']['clear'](),this['deactivate'](),this['_reductionSteps']){for(var _0x2d959c=0x0;_0x2d959c_0x4375a4&&(_0x3c6467=0x0,_0x4375a4=0x1),_0x3c6467<0x0&&(_0x3c6467=0x0),_0x4375a4>0x1&&(_0x4375a4=0x1),this['_minDistance']=_0x3c6467,this['_maxDistance']=_0x4375a4,this['_breaksAreDirty']=!0x0);},Object['defineProperty'](_0x5eab78['prototype'],'minDistance',{'get':function(){return this['_minDistance'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5eab78['prototype'],'maxDistance',{'get':function(){return this['_maxDistance'];},'enumerable':!0x1,'configurable':!0x0}),_0x5eab78['prototype']['getClassName']=function(){return _0x5eab78['CLASSNAME'];},_0x5eab78['prototype']['getCascadeMinExtents']=function(_0x4b9bf8){return _0x4b9bf8>=0x0&&_0x4b9bf8=0x0&&_0x32a41cthis['_scene']['activeCamera']['maxZ']||(this['_shadowMaxZ']=_0xc9d01f,this['_light']['_markMeshesAsLightDirty'](),this['_breaksAreDirty']=!0x0):this['_shadowMaxZ']=_0xc9d01f;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5eab78['prototype'],'debug',{'get':function(){return this['_debug'];},'set':function(_0x105c47){this['_debug']=_0x105c47,this['_light']['_markMeshesAsLightDirty']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5eab78['prototype'],'depthClamp',{'get':function(){return this['_depthClamp'];},'set':function(_0x528121){this['_depthClamp']=_0x528121;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5eab78['prototype'],'cascadeBlendPercentage',{'get':function(){return this['_cascadeBlendPercentage'];},'set':function(_0x33cfea){this['_cascadeBlendPercentage']=_0x33cfea,this['_light']['_markMeshesAsLightDirty']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5eab78['prototype'],'lambda',{'get':function(){return this['_lambda'];},'set':function(_0x18e059){var _0x1ec42f=Math['min'](Math['max'](_0x18e059,0x0),0x1);this['_lambda']!=_0x1ec42f&&(this['_lambda']=_0x1ec42f,this['_breaksAreDirty']=!0x0);},'enumerable':!0x1,'configurable':!0x0}),_0x5eab78['prototype']['getCascadeViewMatrix']=function(_0x18f86b){return _0x18f86b>=0x0&&_0x18f86b=0x0&&_0x1570ef=0x0&&_0x3d66b4=_0x59510b&&(_0x5e5734=0x0,_0x59510b=0x1),_0x5e5734==_0x39c1a6['_minDistance']&&_0x59510b==_0x39c1a6['_maxDistance']||_0x39c1a6['setMinMaxDistance'](_0x5e5734,_0x59510b);}),this['_depthReducer']['setDepthRenderer'](this['_depthRenderer'])),this['_depthReducer']['activate']();}},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5eab78['prototype'],'autoCalcDepthBoundsRefreshRate',{'get':function(){var _0x2c8fbe,_0xfcc89f,_0x1df1bd;return null!==(_0x1df1bd=null===(_0xfcc89f=null===(_0x2c8fbe=this['_depthReducer'])||void 0x0===_0x2c8fbe?void 0x0:_0x2c8fbe['depthRenderer'])||void 0x0===_0xfcc89f?void 0x0:_0xfcc89f['getDepthMap']()['refreshRate'])&&void 0x0!==_0x1df1bd?_0x1df1bd:-0x1;},'set':function(_0x4c90de){var _0x471a6e;(null===(_0x471a6e=this['_depthReducer'])||void 0x0===_0x471a6e?void 0x0:_0x471a6e['depthRenderer'])&&(this['_depthReducer']['depthRenderer']['getDepthMap']()['refreshRate']=_0x4c90de);},'enumerable':!0x1,'configurable':!0x0}),_0x5eab78['prototype']['splitFrustum']=function(){this['_breaksAreDirty']=!0x0;},_0x5eab78['prototype']['_splitFrustum']=function(){var _0xe7c86f=this['_scene']['activeCamera'];if(_0xe7c86f){for(var _0x59fec4=_0xe7c86f['minZ'],_0x22204e=_0xe7c86f['maxZ'],_0x25453a=_0x22204e-_0x59fec4,_0x5b7826=this['_minDistance'],_0x3c5d35=_0x59fec4+_0x5b7826*_0x25453a,_0x4ac55a=_0x59fec4+(this['_shadowMaxZ']<_0x22204e&&this['_shadowMaxZ']>=_0x59fec4?Math['min']((this['_shadowMaxZ']-_0x59fec4)/(_0x22204e-_0x59fec4),this['_maxDistance']):this['_maxDistance'])*_0x25453a,_0x5ba792=_0x4ac55a-_0x3c5d35,_0x31d1da=_0x4ac55a/_0x3c5d35,_0x28a19f=0x0;_0x28a19fMath['PI'];)_0x731d23-=0x2*Math['PI'];var _0x491d1f=_0x731d23/Math['PI'],_0x24669a=_0x14abc8/Math['PI'];_0x491d1f=0.5*_0x491d1f+0.5;var _0x4d929f=Math['round'](_0x491d1f*_0x19473e);_0x4d929f<0x0?_0x4d929f=0x0:_0x4d929f>=_0x19473e&&(_0x4d929f=_0x19473e-0x1);var _0x113031=Math['round'](_0x24669a*_0xca9e03);_0x113031<0x0?_0x113031=0x0:_0x113031>=_0xca9e03&&(_0x113031=_0xca9e03-0x1);var _0x54e87b=_0xca9e03-_0x113031-0x1;return{'r':_0x47b437[_0x54e87b*_0x19473e*0x3+0x3*_0x4d929f+0x0],'g':_0x47b437[_0x54e87b*_0x19473e*0x3+0x3*_0x4d929f+0x1],'b':_0x47b437[_0x54e87b*_0x19473e*0x3+0x3*_0x4d929f+0x2]};},_0x451dae['FACE_LEFT']=[new _0x74d525['e'](-0x1,-0x1,-0x1),new _0x74d525['e'](0x1,-0x1,-0x1),new _0x74d525['e'](-0x1,0x1,-0x1),new _0x74d525['e'](0x1,0x1,-0x1)],_0x451dae['FACE_RIGHT']=[new _0x74d525['e'](0x1,-0x1,0x1),new _0x74d525['e'](-0x1,-0x1,0x1),new _0x74d525['e'](0x1,0x1,0x1),new _0x74d525['e'](-0x1,0x1,0x1)],_0x451dae['FACE_FRONT']=[new _0x74d525['e'](0x1,-0x1,-0x1),new _0x74d525['e'](0x1,-0x1,0x1),new _0x74d525['e'](0x1,0x1,-0x1),new _0x74d525['e'](0x1,0x1,0x1)],_0x451dae['FACE_BACK']=[new _0x74d525['e'](-0x1,-0x1,0x1),new _0x74d525['e'](-0x1,-0x1,-0x1),new _0x74d525['e'](-0x1,0x1,0x1),new _0x74d525['e'](-0x1,0x1,-0x1)],_0x451dae['FACE_DOWN']=[new _0x74d525['e'](0x1,0x1,-0x1),new _0x74d525['e'](0x1,0x1,0x1),new _0x74d525['e'](-0x1,0x1,-0x1),new _0x74d525['e'](-0x1,0x1,0x1)],_0x451dae['FACE_UP']=[new _0x74d525['e'](-0x1,-0x1,-0x1),new _0x74d525['e'](-0x1,-0x1,0x1),new _0x74d525['e'](0x1,-0x1,-0x1),new _0x74d525['e'](0x1,-0x1,0x1)],_0x451dae;}()),_0x1fec63=(function(){function _0x4064ba(){}return _0x4064ba['Ldexp']=function(_0x3e8ca3,_0x3d698a){return _0x3d698a>0x3ff?_0x3e8ca3*Math['pow'](0x2,0x3ff)*Math['pow'](0x2,_0x3d698a-0x3ff):_0x3d698a<-0x432?_0x3e8ca3*Math['pow'](0x2,-0x432)*Math['pow'](0x2,_0x3d698a+0x432):_0x3e8ca3*Math['pow'](0x2,_0x3d698a);},_0x4064ba['Rgbe2float']=function(_0x1d266b,_0x566a17,_0x4fdd46,_0x117605,_0x46e2db,_0x477ad7){_0x46e2db>0x0?(_0x46e2db=this['Ldexp'](0x1,_0x46e2db-0x88),_0x1d266b[_0x477ad7+0x0]=_0x566a17*_0x46e2db,_0x1d266b[_0x477ad7+0x1]=_0x4fdd46*_0x46e2db,_0x1d266b[_0x477ad7+0x2]=_0x117605*_0x46e2db):(_0x1d266b[_0x477ad7+0x0]=0x0,_0x1d266b[_0x477ad7+0x1]=0x0,_0x1d266b[_0x477ad7+0x2]=0x0);},_0x4064ba['readStringLine']=function(_0x42c9c3,_0x5ee510){for(var _0x5cf917='',_0x14e387='',_0x32501a=_0x5ee510;_0x32501a<_0x42c9c3['length']-_0x5ee510&&'\x0a'!=(_0x14e387=String['fromCharCode'](_0x42c9c3[_0x32501a]));_0x32501a++)_0x5cf917+=_0x14e387;return _0x5cf917;},_0x4064ba['RGBE_ReadHeader']=function(_0x544e7b){var _0x2a72d0,_0x38aeff,_0x2de666=this['readStringLine'](_0x544e7b,0x0);if('#'!=_0x2de666[0x0]||'?'!=_0x2de666[0x1])throw'Bad\x20HDR\x20Format.';var _0x23f74a=!0x1,_0x2b8c29=!0x1,_0x4fe97e=0x0;do{_0x4fe97e+=_0x2de666['length']+0x1,'FORMAT=32-bit_rle_rgbe'==(_0x2de666=this['readStringLine'](_0x544e7b,_0x4fe97e))?_0x2b8c29=!0x0:0x0==_0x2de666['length']&&(_0x23f74a=!0x0);}while(!_0x23f74a);if(!_0x2b8c29)throw'HDR\x20Bad\x20header\x20format,\x20unsupported\x20FORMAT';_0x4fe97e+=_0x2de666['length']+0x1,_0x2de666=this['readStringLine'](_0x544e7b,_0x4fe97e);var _0x1d15f6=/^\-Y (.*) \+X (.*)$/g['exec'](_0x2de666);if(!_0x1d15f6||_0x1d15f6['length']<0x3)throw'HDR\x20Bad\x20header\x20format,\x20no\x20size';if(_0x38aeff=parseInt(_0x1d15f6[0x2]),_0x2a72d0=parseInt(_0x1d15f6[0x1]),_0x38aeff<0x8||_0x38aeff>0x7fff)throw'HDR\x20Bad\x20header\x20format,\x20unsupported\x20size';return{'height':_0x2a72d0,'width':_0x38aeff,'dataPosition':_0x4fe97e+=_0x2de666['length']+0x1};},_0x4064ba['GetCubeMapTextureData']=function(_0x43f491,_0x16ecc1){var _0x11dd9b=new Uint8Array(_0x43f491),_0x9e45d4=this['RGBE_ReadHeader'](_0x11dd9b),_0x1273fa=this['RGBE_ReadPixels'](_0x11dd9b,_0x9e45d4);return _0x11ae99['ConvertPanoramaToCubemap'](_0x1273fa,_0x9e45d4['width'],_0x9e45d4['height'],_0x16ecc1);},_0x4064ba['RGBE_ReadPixels']=function(_0x9dad43,_0x4c883f){return this['RGBE_ReadPixels_RLE'](_0x9dad43,_0x4c883f);},_0x4064ba['RGBE_ReadPixels_RLE']=function(_0x451980,_0x9f9b57){for(var _0x450aaa,_0x1ea55e,_0x58422c,_0x2e06bc,_0x5ac27b,_0xbf4d1b=_0x9f9b57['height'],_0x3b00c9=_0x9f9b57['width'],_0x6fc716=_0x9f9b57['dataPosition'],_0x4b6498=0x0,_0x4affbb=0x0,_0x59b48c=0x0,_0x1108d5=new ArrayBuffer(0x4*_0x3b00c9),_0x582ff8=new Uint8Array(_0x1108d5),_0x11c52d=new ArrayBuffer(_0x9f9b57['width']*_0x9f9b57['height']*0x4*0x3),_0x495071=new Float32Array(_0x11c52d);_0xbf4d1b>0x0;){if(_0x450aaa=_0x451980[_0x6fc716++],_0x1ea55e=_0x451980[_0x6fc716++],_0x58422c=_0x451980[_0x6fc716++],_0x2e06bc=_0x451980[_0x6fc716++],0x2!=_0x450aaa||0x2!=_0x1ea55e||0x80&_0x58422c||_0x9f9b57['width']<0x8||_0x9f9b57['width']>0x7fff)return this['RGBE_ReadPixels_NOT_RLE'](_0x451980,_0x9f9b57);if((_0x58422c<<0x8|_0x2e06bc)!=_0x3b00c9)throw'HDR\x20Bad\x20header\x20format,\x20wrong\x20scan\x20line\x20width';for(_0x4b6498=0x0,_0x59b48c=0x0;_0x59b48c<0x4;_0x59b48c++)for(_0x4affbb=(_0x59b48c+0x1)*_0x3b00c9;_0x4b6498<_0x4affbb;)if(_0x450aaa=_0x451980[_0x6fc716++],_0x1ea55e=_0x451980[_0x6fc716++],_0x450aaa>0x80){if(0x0==(_0x5ac27b=_0x450aaa-0x80)||_0x5ac27b>_0x4affbb-_0x4b6498)throw'HDR\x20Bad\x20Format,\x20bad\x20scanline\x20data\x20(run)';for(;_0x5ac27b-->0x0;)_0x582ff8[_0x4b6498++]=_0x1ea55e;}else{if(0x0==(_0x5ac27b=_0x450aaa)||_0x5ac27b>_0x4affbb-_0x4b6498)throw'HDR\x20Bad\x20Format,\x20bad\x20scanline\x20data\x20(non-run)';if(_0x582ff8[_0x4b6498++]=_0x1ea55e,--_0x5ac27b>0x0){for(var _0x5b8b8a=0x0;_0x5b8b8a<_0x5ac27b;_0x5b8b8a++)_0x582ff8[_0x4b6498++]=_0x451980[_0x6fc716++];}}for(_0x59b48c=0x0;_0x59b48c<_0x3b00c9;_0x59b48c++)_0x450aaa=_0x582ff8[_0x59b48c],_0x1ea55e=_0x582ff8[_0x59b48c+_0x3b00c9],_0x58422c=_0x582ff8[_0x59b48c+0x2*_0x3b00c9],_0x2e06bc=_0x582ff8[_0x59b48c+0x3*_0x3b00c9],this['Rgbe2float'](_0x495071,_0x450aaa,_0x1ea55e,_0x58422c,_0x2e06bc,(_0x9f9b57['height']-_0xbf4d1b)*_0x3b00c9*0x3+0x3*_0x59b48c);_0xbf4d1b--;}return _0x495071;},_0x4064ba['RGBE_ReadPixels_NOT_RLE']=function(_0x2ca2ec,_0x585eb8){for(var _0x1bb8ea,_0x192ffc,_0x29f391,_0x48d033,_0x1b4647,_0x455b62=_0x585eb8['height'],_0xd6d04d=_0x585eb8['width'],_0x50b1b7=_0x585eb8['dataPosition'],_0x1aa067=new ArrayBuffer(_0x585eb8['width']*_0x585eb8['height']*0x4*0x3),_0x51c5ad=new Float32Array(_0x1aa067);_0x455b62>0x0;){for(_0x1b4647=0x0;_0x1b4647<_0x585eb8['width'];_0x1b4647++)_0x1bb8ea=_0x2ca2ec[_0x50b1b7++],_0x192ffc=_0x2ca2ec[_0x50b1b7++],_0x29f391=_0x2ca2ec[_0x50b1b7++],_0x48d033=_0x2ca2ec[_0x50b1b7++],this['Rgbe2float'](_0x51c5ad,_0x1bb8ea,_0x192ffc,_0x29f391,_0x48d033,(_0x585eb8['height']-_0x455b62)*_0xd6d04d*0x3+0x3*_0x1b4647);_0x455b62--;}return _0x51c5ad;},_0x4064ba;}()),_0x30619e=(function(){function _0x54f398(_0x13ad59,_0x251892){var _0x42e003;void 0x0===_0x251892&&(_0x251892=_0x54f398['_DefaultOptions']),this['engine']=_0x13ad59,this['_fullscreenViewport']=new _0x4548b0['a'](0x0,0x0,0x1,0x1),_0x251892=Object(_0x18e13d['a'])(Object(_0x18e13d['a'])({},_0x54f398['_DefaultOptions']),_0x251892),this['_vertexBuffers']=((_0x42e003={})[_0x212fbd['b']['PositionKind']]=new _0x212fbd['b'](_0x13ad59,_0x251892['positions'],_0x212fbd['b']['PositionKind'],!0x1,!0x1,0x2),_0x42e003),this['_indexBuffer']=_0x13ad59['createIndexBuffer'](_0x251892['indices']);}return _0x54f398['prototype']['setViewport']=function(_0x4b3a10){void 0x0===_0x4b3a10&&(_0x4b3a10=this['_fullscreenViewport']),this['engine']['setViewport'](_0x4b3a10);},_0x54f398['prototype']['bindBuffers']=function(_0x2e52b4){this['engine']['bindBuffers'](this['_vertexBuffers'],this['_indexBuffer'],_0x2e52b4);},_0x54f398['prototype']['applyEffectWrapper']=function(_0x1f897f){this['engine']['depthCullingState']['depthTest']=!0x1,this['engine']['stencilState']['stencilTest']=!0x1,this['engine']['enableEffect'](_0x1f897f['effect']),this['bindBuffers'](_0x1f897f['effect']),_0x1f897f['onApplyObservable']['notifyObservers']({});},_0x54f398['prototype']['restoreStates']=function(){this['engine']['depthCullingState']['depthTest']=!0x0,this['engine']['stencilState']['stencilTest']=!0x0;},_0x54f398['prototype']['draw']=function(){this['engine']['drawElementsType'](_0x2103ba['a']['MATERIAL_TriangleFillMode'],0x0,0x6);},_0x54f398['prototype']['isRenderTargetTexture']=function(_0x3c9b67){return void 0x0!==_0x3c9b67['renderList'];},_0x54f398['prototype']['render']=function(_0x3cece2,_0x27486d){if(void 0x0===_0x27486d&&(_0x27486d=null),_0x3cece2['effect']['isReady']()){this['setViewport']();var _0x1daa72=null===_0x27486d?null:this['isRenderTargetTexture'](_0x27486d)?_0x27486d['getInternalTexture']():_0x27486d;_0x1daa72&&this['engine']['bindFramebuffer'](_0x1daa72),this['applyEffectWrapper'](_0x3cece2),this['draw'](),_0x1daa72&&this['engine']['unBindFramebuffer'](_0x1daa72),this['restoreStates']();}},_0x54f398['prototype']['dispose']=function(){var _0x1d36b2=this['_vertexBuffers'][_0x212fbd['b']['PositionKind']];_0x1d36b2&&(_0x1d36b2['dispose'](),delete this['_vertexBuffers'][_0x212fbd['b']['PositionKind']]),this['_indexBuffer']&&this['engine']['_releaseBuffer'](this['_indexBuffer']);},_0x54f398['_DefaultOptions']={'positions':[0x1,0x1,-0x1,0x1,-0x1,-0x1,0x1,-0x1],'indices':[0x0,0x1,0x2,0x0,0x2,0x3]},_0x54f398;}()),_0x15c8ff=(function(){function _0x55cd43(_0x246125){var _0x4ad2a1,_0x157e65=this;this['onApplyObservable']=new _0x6ac1f7['c']();var _0x312595=_0x246125['uniformNames']||[];_0x246125['vertexShader']?_0x4ad2a1={'fragmentSource':_0x246125['fragmentShader'],'vertexSource':_0x246125['vertexShader'],'spectorName':_0x246125['name']||'effectWrapper'}:(_0x312595['push']('scale'),_0x4ad2a1={'fragmentSource':_0x246125['fragmentShader'],'vertex':'postprocess','spectorName':_0x246125['name']||'effectWrapper'},this['onApplyObservable']['add'](function(){_0x157e65['effect']['setFloat2']('scale',0x1,0x1);}));var _0x316d51=_0x246125['defines']?_0x246125['defines']['join']('\x0a'):'';_0x246125['useShaderStore']?(_0x4ad2a1['fragment']=_0x4ad2a1['fragmentSource'],_0x4ad2a1['vertex']||(_0x4ad2a1['vertex']=_0x4ad2a1['vertexSource']),delete _0x4ad2a1['fragmentSource'],delete _0x4ad2a1['vertexSource'],this['effect']=_0x246125['engine']['createEffect'](_0x4ad2a1['spectorName'],_0x246125['attributeNames']||['position'],_0x312595,_0x246125['samplerNames'],_0x316d51,void 0x0,_0x246125['onCompiled'])):this['effect']=new _0x494b01['a'](_0x4ad2a1,_0x246125['attributeNames']||['position'],_0x312595,_0x246125['samplerNames'],_0x246125['engine'],_0x316d51,void 0x0,_0x246125['onCompiled']);}return _0x55cd43['prototype']['dispose']=function(){this['effect']['dispose']();},_0x55cd43;}()),_0x487ed3='\x0aattribute\x20vec2\x20position;\x0a\x0avarying\x20vec3\x20direction;\x0a\x0auniform\x20vec3\x20up;\x0auniform\x20vec3\x20right;\x0auniform\x20vec3\x20front;\x0avoid\x20main(void)\x20{\x0amat3\x20view=mat3(up,right,front);\x0adirection=view*vec3(position,1.0);\x0agl_Position=vec4(position,0.0,1.0);\x0a}';_0x494b01['a']['ShadersStore']['hdrFilteringVertexShader']=_0x487ed3;var _0x27d3a3='#include\x0a#include\x0a#include\x0a#include\x0auniform\x20float\x20alphaG;\x0auniform\x20samplerCube\x20inputTexture;\x0auniform\x20vec2\x20vFilteringInfo;\x0auniform\x20float\x20hdrScale;\x0avarying\x20vec3\x20direction;\x0avoid\x20main()\x20{\x0avec3\x20color=radiance(alphaG,inputTexture,direction,vFilteringInfo);\x0agl_FragColor=vec4(color*hdrScale,1.0);\x0a}';_0x494b01['a']['ShadersStore']['hdrFilteringPixelShader']=_0x27d3a3;var _0x43f45b=(function(){function _0x5e7b5d(_0x534e4b,_0xa1d72d){void 0x0===_0xa1d72d&&(_0xa1d72d={}),this['_lodGenerationOffset']=0x0,this['_lodGenerationScale']=0.8,this['quality']=_0x2103ba['a']['TEXTURE_FILTERING_QUALITY_OFFLINE'],this['hdrScale']=0x1,this['_engine']=_0x534e4b,this['hdrScale']=_0xa1d72d['hdrScale']||this['hdrScale'],this['quality']=_0xa1d72d['hdrScale']||this['quality'];}return _0x5e7b5d['prototype']['_createRenderTarget']=function(_0x256939){var _0x5e44fa=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_BYTE'];this['_engine']['getCaps']()['textureHalfFloatRender']?_0x5e44fa=_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT']:this['_engine']['getCaps']()['textureFloatRender']&&(_0x5e44fa=_0x2103ba['a']['TEXTURETYPE_FLOAT']);var _0x478952=this['_engine']['createRenderTargetCubeTexture'](_0x256939,{'format':_0x2103ba['a']['TEXTUREFORMAT_RGBA'],'type':_0x5e44fa,'generateMipMaps':!0x1,'generateDepthBuffer':!0x1,'generateStencilBuffer':!0x1,'samplingMode':_0x2103ba['a']['TEXTURE_NEAREST_SAMPLINGMODE']});return this['_engine']['updateTextureWrappingMode'](_0x478952,_0x2103ba['a']['TEXTURE_CLAMP_ADDRESSMODE'],_0x2103ba['a']['TEXTURE_CLAMP_ADDRESSMODE'],_0x2103ba['a']['TEXTURE_CLAMP_ADDRESSMODE']),this['_engine']['updateTextureSamplingMode'](_0x2103ba['a']['TEXTURE_TRILINEAR_SAMPLINGMODE'],_0x478952,!0x0),_0x478952;},_0x5e7b5d['prototype']['_prefilterInternal']=function(_0x12d246){var _0x17c667=_0x12d246['getSize']()['width'],_0x47dfb2=Math['round'](_0x4a0cf0['a']['Log2'](_0x17c667))+0x1,_0x3f4d18=this['_effectWrapper']['effect'],_0x4ba342=this['_createRenderTarget'](_0x17c667);this['_effectRenderer']['setViewport']();var _0x26dc2b=_0x12d246['getInternalTexture']();_0x26dc2b&&this['_engine']['updateTextureSamplingMode'](_0x2103ba['a']['TEXTURE_TRILINEAR_SAMPLINGMODE'],_0x26dc2b,!0x0),this['_effectRenderer']['applyEffectWrapper'](this['_effectWrapper']);var _0x591a23=[[new _0x74d525['e'](0x0,0x0,-0x1),new _0x74d525['e'](0x0,-0x1,0x0),new _0x74d525['e'](0x1,0x0,0x0)],[new _0x74d525['e'](0x0,0x0,0x1),new _0x74d525['e'](0x0,-0x1,0x0),new _0x74d525['e'](-0x1,0x0,0x0)],[new _0x74d525['e'](0x1,0x0,0x0),new _0x74d525['e'](0x0,0x0,0x1),new _0x74d525['e'](0x0,0x1,0x0)],[new _0x74d525['e'](0x1,0x0,0x0),new _0x74d525['e'](0x0,0x0,-0x1),new _0x74d525['e'](0x0,-0x1,0x0)],[new _0x74d525['e'](0x1,0x0,0x0),new _0x74d525['e'](0x0,-0x1,0x0),new _0x74d525['e'](0x0,0x0,0x1)],[new _0x74d525['e'](-0x1,0x0,0x0),new _0x74d525['e'](0x0,-0x1,0x0),new _0x74d525['e'](0x0,0x0,-0x1)]];_0x3f4d18['setFloat']('hdrScale',this['hdrScale']),_0x3f4d18['setFloat2']('vFilteringInfo',_0x12d246['getSize']()['width'],_0x47dfb2),_0x3f4d18['setTexture']('inputTexture',_0x12d246);for(var _0x2fc7d0=0x0;_0x2fc7d0<0x6;_0x2fc7d0++){_0x3f4d18['setVector3']('up',_0x591a23[_0x2fc7d0][0x0]),_0x3f4d18['setVector3']('right',_0x591a23[_0x2fc7d0][0x1]),_0x3f4d18['setVector3']('front',_0x591a23[_0x2fc7d0][0x2]);for(var _0x1718e6=0x0;_0x1718e6<_0x47dfb2;_0x1718e6++){this['_engine']['bindFramebuffer'](_0x4ba342,_0x2fc7d0,void 0x0,void 0x0,!0x0,_0x1718e6),this['_effectRenderer']['applyEffectWrapper'](this['_effectWrapper']);var _0x43005d=Math['pow'](0x2,(_0x1718e6-this['_lodGenerationOffset'])/this['_lodGenerationScale'])/_0x17c667;0x0===_0x1718e6&&(_0x43005d=0x0),_0x3f4d18['setFloat']('alphaG',_0x43005d),this['_effectRenderer']['draw']();}}return this['_effectRenderer']['restoreStates'](),this['_engine']['restoreDefaultFramebuffer'](),this['_engine']['_releaseFramebufferObjects'](_0x4ba342),this['_engine']['_releaseTexture'](_0x12d246['_texture']),_0x4ba342['_swapAndDie'](_0x12d246['_texture']),_0x12d246['_prefiltered']=!0x0,_0x12d246;},_0x5e7b5d['prototype']['_createEffect']=function(_0x311dc9,_0x4f4866){var _0x431c71=[];return _0x311dc9['gammaSpace']&&_0x431c71['push']('#define\x20GAMMA_INPUT'),_0x431c71['push']('#define\x20NUM_SAMPLES\x20'+this['quality']+'u'),new _0x15c8ff({'engine':this['_engine'],'name':'hdrFiltering','vertexShader':'hdrFiltering','fragmentShader':'hdrFiltering','samplerNames':['inputTexture'],'uniformNames':['vSampleDirections','vWeights','up','right','front','vFilteringInfo','hdrScale','alphaG'],'useShaderStore':!0x0,'defines':_0x431c71,'onCompiled':_0x4f4866});},_0x5e7b5d['prototype']['isReady']=function(_0x3be69e){return _0x3be69e['isReady']()&&this['_effectWrapper']['effect']['isReady']();},_0x5e7b5d['prototype']['prefilter']=function(_0x5b6d47,_0x641c3f){var _0x18255d=this;if(void 0x0===_0x641c3f&&(_0x641c3f=null),0x1!==this['_engine']['webGLVersion'])return new Promise(function(_0x46a792){_0x18255d['_effectRenderer']=new _0x30619e(_0x18255d['_engine']),_0x18255d['_effectWrapper']=_0x18255d['_createEffect'](_0x5b6d47),_0x18255d['_effectWrapper']['effect']['executeWhenCompiled'](function(){_0x18255d['_prefilterInternal'](_0x5b6d47),_0x18255d['_effectRenderer']['dispose'](),_0x18255d['_effectWrapper']['dispose'](),_0x46a792(),_0x641c3f&&_0x641c3f();});});_0x75193d['a']['Warn']('HDR\x20prefiltering\x20is\x20not\x20available\x20in\x20WebGL\x201.,\x20you\x20can\x20use\x20real\x20time\x20filtering\x20instead.');},_0x5e7b5d;}()),_0x26e1bc=function(_0x5c8cfa){function _0x35532c(_0x5b333a,_0x34ff53,_0x2d52b4,_0x231fe7,_0x54142f,_0x18cabe,_0x544352,_0x15d416,_0x134a1f){var _0x16fe69;void 0x0===_0x231fe7&&(_0x231fe7=!0x1),void 0x0===_0x54142f&&(_0x54142f=!0x0),void 0x0===_0x18cabe&&(_0x18cabe=!0x1),void 0x0===_0x544352&&(_0x544352=!0x1),void 0x0===_0x15d416&&(_0x15d416=null),void 0x0===_0x134a1f&&(_0x134a1f=null);var _0xe111f6=_0x5c8cfa['call'](this,_0x34ff53)||this;return _0xe111f6['_generateHarmonics']=!0x0,_0xe111f6['_onLoad']=null,_0xe111f6['_onError']=null,_0xe111f6['_isBlocking']=!0x0,_0xe111f6['_rotationY']=0x0,_0xe111f6['boundingBoxPosition']=_0x74d525['e']['Zero'](),_0x5b333a?(_0xe111f6['_coordinatesMode']=_0xaf3c80['a']['CUBIC_MODE'],_0xe111f6['name']=_0x5b333a,_0xe111f6['url']=_0x5b333a,_0xe111f6['hasAlpha']=!0x1,_0xe111f6['isCube']=!0x0,_0xe111f6['_textureMatrix']=_0x74d525['a']['Identity'](),_0xe111f6['_prefilterOnLoad']=_0x544352,_0xe111f6['_onLoad']=_0x15d416,_0xe111f6['_onError']=_0x134a1f,_0xe111f6['gammaSpace']=_0x18cabe,_0xe111f6['_noMipmap']=_0x231fe7,_0xe111f6['_size']=_0x2d52b4,_0xe111f6['_generateHarmonics']=_0x54142f,_0xe111f6['_texture']=_0xe111f6['_getFromCache'](_0x5b333a,_0xe111f6['_noMipmap']),_0xe111f6['_texture']?_0x15d416&&(_0xe111f6['_texture']['isReady']?_0x5d754c['b']['SetImmediate'](function(){return _0x15d416();}):_0xe111f6['_texture']['onLoadedObservable']['add'](_0x15d416)):(null===(_0x16fe69=_0xe111f6['getScene']())||void 0x0===_0x16fe69?void 0x0:_0x16fe69['useDelayedTextureLoading'])?_0xe111f6['delayLoadState']=_0x2103ba['a']['DELAYLOADSTATE_NOTLOADED']:_0xe111f6['loadTexture'](),_0xe111f6):_0xe111f6;}return Object(_0x18e13d['d'])(_0x35532c,_0x5c8cfa),Object['defineProperty'](_0x35532c['prototype'],'isBlocking',{'get':function(){return this['_isBlocking'];},'set':function(_0x3e9b35){this['_isBlocking']=_0x3e9b35;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x35532c['prototype'],'rotationY',{'get':function(){return this['_rotationY'];},'set':function(_0x536590){this['_rotationY']=_0x536590,this['setReflectionTextureMatrix'](_0x74d525['a']['RotationY'](this['_rotationY']));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x35532c['prototype'],'boundingBoxSize',{'get':function(){return this['_boundingBoxSize'];},'set':function(_0x2bbd58){if(!this['_boundingBoxSize']||!this['_boundingBoxSize']['equals'](_0x2bbd58)){this['_boundingBoxSize']=_0x2bbd58;var _0x2cd73f=this['getScene']();_0x2cd73f&&_0x2cd73f['markAllMaterialsAsDirty'](_0x2103ba['a']['MATERIAL_TextureDirtyFlag']);}},'enumerable':!0x1,'configurable':!0x0}),_0x35532c['prototype']['getClassName']=function(){return'HDRCubeTexture';},_0x35532c['prototype']['loadTexture']=function(){var _0x181bc4=this,_0x3f33a2=this['_getEngine']();if(this['_getEngine']()['webGLVersion']>=0x2&&this['_prefilterOnLoad']){var _0x19c010=this['_onLoad'],_0x286262=new _0x43f45b(_0x3f33a2);this['_onLoad']=function(){_0x286262['prefilter'](_0x181bc4,_0x19c010);};}this['_texture']=_0x3f33a2['createRawCubeTextureFromUrl'](this['url'],this['getScene'](),this['_size'],_0x2103ba['a']['TEXTUREFORMAT_RGB'],_0x3f33a2['getCaps']()['textureFloat']?_0x2103ba['a']['TEXTURETYPE_FLOAT']:_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'],this['_noMipmap'],function(_0x2accea){_0x181bc4['lodGenerationOffset']=0x0,_0x181bc4['lodGenerationScale']=0.8;var _0xd187de=_0x1fec63['GetCubeMapTextureData'](_0x2accea,_0x181bc4['_size']);if(_0x181bc4['_generateHarmonics']){var _0x2ebf12=_0x3fdf9a['ConvertCubeMapToSphericalPolynomial'](_0xd187de);_0x181bc4['sphericalPolynomial']=_0x2ebf12;}for(var _0x1af647=[],_0x5072d7=null,_0x4cfd35=0x0;_0x4cfd35<0x6;_0x4cfd35++){if(!_0x3f33a2['getCaps']()['textureFloat']){var _0x57e70f=new ArrayBuffer(_0x181bc4['_size']*_0x181bc4['_size']*0x3);_0x5072d7=new Uint8Array(_0x57e70f);}var _0x2715a9=_0xd187de[_0x35532c['_facesMapping'][_0x4cfd35]];if(_0x181bc4['gammaSpace']||_0x5072d7){for(var _0x576afc=0x0;_0x576afc<_0x181bc4['_size']*_0x181bc4['_size'];_0x576afc++)if(_0x181bc4['gammaSpace']&&(_0x2715a9[0x3*_0x576afc+0x0]=Math['pow'](_0x2715a9[0x3*_0x576afc+0x0],_0x27da6e['b']),_0x2715a9[0x3*_0x576afc+0x1]=Math['pow'](_0x2715a9[0x3*_0x576afc+0x1],_0x27da6e['b']),_0x2715a9[0x3*_0x576afc+0x2]=Math['pow'](_0x2715a9[0x3*_0x576afc+0x2],_0x27da6e['b'])),_0x5072d7){var _0x579624=Math['max'](0xff*_0x2715a9[0x3*_0x576afc+0x0],0x0),_0xd62b05=Math['max'](0xff*_0x2715a9[0x3*_0x576afc+0x1],0x0),_0x277b89=Math['max'](0xff*_0x2715a9[0x3*_0x576afc+0x2],0x0),_0x331151=Math['max'](Math['max'](_0x579624,_0xd62b05),_0x277b89);if(_0x331151>0xff){var _0x48718d=0xff/_0x331151;_0x579624*=_0x48718d,_0xd62b05*=_0x48718d,_0x277b89*=_0x48718d;}_0x5072d7[0x3*_0x576afc+0x0]=_0x579624,_0x5072d7[0x3*_0x576afc+0x1]=_0xd62b05,_0x5072d7[0x3*_0x576afc+0x2]=_0x277b89;}}_0x5072d7?_0x1af647['push'](_0x5072d7):_0x1af647['push'](_0x2715a9);}return _0x1af647;},null,this['_onLoad'],this['_onError']);},_0x35532c['prototype']['clone']=function(){var _0x581988=new _0x35532c(this['url'],this['getScene']()||this['_getEngine'](),this['_size'],this['_noMipmap'],this['_generateHarmonics'],this['gammaSpace']);return _0x581988['level']=this['level'],_0x581988['wrapU']=this['wrapU'],_0x581988['wrapV']=this['wrapV'],_0x581988['coordinatesIndex']=this['coordinatesIndex'],_0x581988['coordinatesMode']=this['coordinatesMode'],_0x581988;},_0x35532c['prototype']['delayLoad']=function(){this['delayLoadState']===_0x2103ba['a']['DELAYLOADSTATE_NOTLOADED']&&(this['delayLoadState']=_0x2103ba['a']['DELAYLOADSTATE_LOADED'],this['_texture']=this['_getFromCache'](this['url'],this['_noMipmap']),this['_texture']||this['loadTexture']());},_0x35532c['prototype']['getReflectionTextureMatrix']=function(){return this['_textureMatrix'];},_0x35532c['prototype']['setReflectionTextureMatrix']=function(_0x351dd4){var _0x1f0da4,_0x2e6529=this;this['_textureMatrix']=_0x351dd4,_0x351dd4['updateFlag']!==this['_textureMatrix']['updateFlag']&&_0x351dd4['isIdentity']()!==this['_textureMatrix']['isIdentity']()&&(null===(_0x1f0da4=this['getScene']())||void 0x0===_0x1f0da4||_0x1f0da4['markAllMaterialsAsDirty'](_0x2103ba['a']['MATERIAL_TextureDirtyFlag'],function(_0x5218d6){return-0x1!==_0x5218d6['getActiveTextures']()['indexOf'](_0x2e6529);}));},_0x35532c['Parse']=function(_0x4fa9bf,_0x17e401,_0xd3d594){var _0x4c461b=null;return _0x4fa9bf['name']&&!_0x4fa9bf['isRenderTarget']&&((_0x4c461b=new _0x35532c(_0xd3d594+_0x4fa9bf['name'],_0x17e401,_0x4fa9bf['size'],_0x4fa9bf['noMipmap'],_0x4fa9bf['generateHarmonics'],_0x4fa9bf['useInGammaSpace']))['name']=_0x4fa9bf['name'],_0x4c461b['hasAlpha']=_0x4fa9bf['hasAlpha'],_0x4c461b['level']=_0x4fa9bf['level'],_0x4c461b['coordinatesMode']=_0x4fa9bf['coordinatesMode'],_0x4c461b['isBlocking']=_0x4fa9bf['isBlocking']),_0x4c461b&&(_0x4fa9bf['boundingBoxPosition']&&(_0x4c461b['boundingBoxPosition']=_0x74d525['e']['FromArray'](_0x4fa9bf['boundingBoxPosition'])),_0x4fa9bf['boundingBoxSize']&&(_0x4c461b['boundingBoxSize']=_0x74d525['e']['FromArray'](_0x4fa9bf['boundingBoxSize'])),_0x4fa9bf['rotationY']&&(_0x4c461b['rotationY']=_0x4fa9bf['rotationY'])),_0x4c461b;},_0x35532c['prototype']['serialize']=function(){if(!this['name'])return null;var _0x7e6904={};return _0x7e6904['name']=this['name'],_0x7e6904['hasAlpha']=this['hasAlpha'],_0x7e6904['isCube']=!0x0,_0x7e6904['level']=this['level'],_0x7e6904['size']=this['_size'],_0x7e6904['coordinatesMode']=this['coordinatesMode'],_0x7e6904['useInGammaSpace']=this['gammaSpace'],_0x7e6904['generateHarmonics']=this['_generateHarmonics'],_0x7e6904['customType']='BABYLON.HDRCubeTexture',_0x7e6904['noMipmap']=this['_noMipmap'],_0x7e6904['isBlocking']=this['_isBlocking'],_0x7e6904['rotationY']=this['_rotationY'],_0x7e6904;},_0x35532c['_facesMapping']=['right','left','up','down','front','back'],_0x35532c;}(_0x2268ea['a']);_0x3cd573['a']['RegisteredTypes']['BABYLON.HDRCubeTexture']=_0x26e1bc;var _0x233e18=(function(){function _0x1c72ec(_0x570a5f,_0x2758b9,_0x4a3bbf){void 0x0===_0x2758b9&&(_0x2758b9=0x0),void 0x0===_0x4a3bbf&&(_0x4a3bbf=null),this['name']=_0x570a5f,this['animations']=new Array(),this['_positions']=null,this['_normals']=null,this['_tangents']=null,this['_uvs']=null,this['_uniqueId']=0x0,this['onInfluenceChanged']=new _0x6ac1f7['c'](),this['_onDataLayoutChanged']=new _0x6ac1f7['c'](),this['_animationPropertiesOverride']=null,this['_scene']=_0x4a3bbf||_0x44b9ce['a']['LastCreatedScene'],this['influence']=_0x2758b9,this['_scene']&&(this['_uniqueId']=this['_scene']['getUniqueId']());}return Object['defineProperty'](_0x1c72ec['prototype'],'influence',{'get':function(){return this['_influence'];},'set':function(_0x5e63a6){if(this['_influence']!==_0x5e63a6){var _0x1cca10=this['_influence'];this['_influence']=_0x5e63a6,this['onInfluenceChanged']['hasObservers']()&&this['onInfluenceChanged']['notifyObservers'](0x0===_0x1cca10||0x0===_0x5e63a6);}},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1c72ec['prototype'],'animationPropertiesOverride',{'get':function(){return!this['_animationPropertiesOverride']&&this['_scene']?this['_scene']['animationPropertiesOverride']:this['_animationPropertiesOverride'];},'set':function(_0xa5979d){this['_animationPropertiesOverride']=_0xa5979d;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1c72ec['prototype'],'uniqueId',{'get':function(){return this['_uniqueId'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1c72ec['prototype'],'hasPositions',{'get':function(){return!!this['_positions'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1c72ec['prototype'],'hasNormals',{'get':function(){return!!this['_normals'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1c72ec['prototype'],'hasTangents',{'get':function(){return!!this['_tangents'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1c72ec['prototype'],'hasUVs',{'get':function(){return!!this['_uvs'];},'enumerable':!0x1,'configurable':!0x0}),_0x1c72ec['prototype']['setPositions']=function(_0x38b86f){var _0x70ef25=this['hasPositions'];this['_positions']=_0x38b86f,_0x70ef25!==this['hasPositions']&&this['_onDataLayoutChanged']['notifyObservers'](void 0x0);},_0x1c72ec['prototype']['getPositions']=function(){return this['_positions'];},_0x1c72ec['prototype']['setNormals']=function(_0x359e07){var _0x40669d=this['hasNormals'];this['_normals']=_0x359e07,_0x40669d!==this['hasNormals']&&this['_onDataLayoutChanged']['notifyObservers'](void 0x0);},_0x1c72ec['prototype']['getNormals']=function(){return this['_normals'];},_0x1c72ec['prototype']['setTangents']=function(_0x9cca76){var _0x2acd27=this['hasTangents'];this['_tangents']=_0x9cca76,_0x2acd27!==this['hasTangents']&&this['_onDataLayoutChanged']['notifyObservers'](void 0x0);},_0x1c72ec['prototype']['getTangents']=function(){return this['_tangents'];},_0x1c72ec['prototype']['setUVs']=function(_0x3e0134){var _0x2b7155=this['hasUVs'];this['_uvs']=_0x3e0134,_0x2b7155!==this['hasUVs']&&this['_onDataLayoutChanged']['notifyObservers'](void 0x0);},_0x1c72ec['prototype']['getUVs']=function(){return this['_uvs'];},_0x1c72ec['prototype']['clone']=function(){var _0x4cbcc0=this,_0x28b259=_0x495d06['a']['Clone'](function(){return new _0x1c72ec(_0x4cbcc0['name'],_0x4cbcc0['influence'],_0x4cbcc0['_scene']);},this);return _0x28b259['_positions']=this['_positions'],_0x28b259['_normals']=this['_normals'],_0x28b259['_tangents']=this['_tangents'],_0x28b259['_uvs']=this['_uvs'],_0x28b259;},_0x1c72ec['prototype']['serialize']=function(){var _0x5dba3a={};return _0x5dba3a['name']=this['name'],_0x5dba3a['influence']=this['influence'],_0x5dba3a['positions']=Array['prototype']['slice']['call'](this['getPositions']()),null!=this['id']&&(_0x5dba3a['id']=this['id']),this['hasNormals']&&(_0x5dba3a['normals']=Array['prototype']['slice']['call'](this['getNormals']())),this['hasTangents']&&(_0x5dba3a['tangents']=Array['prototype']['slice']['call'](this['getTangents']())),this['hasUVs']&&(_0x5dba3a['uvs']=Array['prototype']['slice']['call'](this['getUVs']())),_0x495d06['a']['AppendSerializedAnimations'](this,_0x5dba3a),_0x5dba3a;},_0x1c72ec['prototype']['getClassName']=function(){return'MorphTarget';},_0x1c72ec['Parse']=function(_0x4252c9){var _0x22db25=new _0x1c72ec(_0x4252c9['name'],_0x4252c9['influence']);if(_0x22db25['setPositions'](_0x4252c9['positions']),null!=_0x4252c9['id']&&(_0x22db25['id']=_0x4252c9['id']),_0x4252c9['normals']&&_0x22db25['setNormals'](_0x4252c9['normals']),_0x4252c9['tangents']&&_0x22db25['setTangents'](_0x4252c9['tangents']),_0x4252c9['uvs']&&_0x22db25['setUVs'](_0x4252c9['uvs']),_0x4252c9['animations'])for(var _0x53957f=0x0;_0x53957f<_0x4252c9['animations']['length'];_0x53957f++){var _0x204478=_0x4252c9['animations'][_0x53957f],_0x25df96=_0x3cd573['a']['GetClass']('BABYLON.Animation');_0x25df96&&_0x22db25['animations']['push'](_0x25df96['Parse'](_0x204478));}return _0x22db25;},_0x1c72ec['FromMesh']=function(_0x2f95e4,_0x453780,_0x37a87d){_0x453780||(_0x453780=_0x2f95e4['name']);var _0x2a8e4e=new _0x1c72ec(_0x453780,_0x37a87d,_0x2f95e4['getScene']());return _0x2a8e4e['setPositions'](_0x2f95e4['getVerticesData'](_0x212fbd['b']['PositionKind'])),_0x2f95e4['isVerticesDataPresent'](_0x212fbd['b']['NormalKind'])&&_0x2a8e4e['setNormals'](_0x2f95e4['getVerticesData'](_0x212fbd['b']['NormalKind'])),_0x2f95e4['isVerticesDataPresent'](_0x212fbd['b']['TangentKind'])&&_0x2a8e4e['setTangents'](_0x2f95e4['getVerticesData'](_0x212fbd['b']['TangentKind'])),_0x2f95e4['isVerticesDataPresent'](_0x212fbd['b']['UVKind'])&&_0x2a8e4e['setUVs'](_0x2f95e4['getVerticesData'](_0x212fbd['b']['UVKind'])),_0x2a8e4e;},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x1c72ec['prototype'],'id',void 0x0),_0x1c72ec;}()),_0x43ac20=(function(){function _0x123021(_0x8af3c4){void 0x0===_0x8af3c4&&(_0x8af3c4=null),this['_targets']=new Array(),this['_targetInfluenceChangedObservers']=new Array(),this['_targetDataLayoutChangedObservers']=new Array(),this['_activeTargets']=new _0x2266f9['a'](0x10),this['_supportsNormals']=!0x1,this['_supportsTangents']=!0x1,this['_supportsUVs']=!0x1,this['_vertexCount']=0x0,this['_uniqueId']=0x0,this['_tempInfluences']=new Array(),this['enableNormalMorphing']=!0x0,this['enableTangentMorphing']=!0x0,this['enableUVMorphing']=!0x0,_0x8af3c4||(_0x8af3c4=_0x44b9ce['a']['LastCreatedScene']),this['_scene']=_0x8af3c4,this['_scene']&&(this['_scene']['morphTargetManagers']['push'](this),this['_uniqueId']=this['_scene']['getUniqueId']());}return Object['defineProperty'](_0x123021['prototype'],'uniqueId',{'get':function(){return this['_uniqueId'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x123021['prototype'],'vertexCount',{'get':function(){return this['_vertexCount'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x123021['prototype'],'supportsNormals',{'get':function(){return this['_supportsNormals']&&this['enableNormalMorphing'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x123021['prototype'],'supportsTangents',{'get':function(){return this['_supportsTangents']&&this['enableTangentMorphing'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x123021['prototype'],'supportsUVs',{'get':function(){return this['_supportsUVs']&&this['enableUVMorphing'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x123021['prototype'],'numTargets',{'get':function(){return this['_targets']['length'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x123021['prototype'],'numInfluencers',{'get':function(){return this['_activeTargets']['length'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x123021['prototype'],'influences',{'get':function(){return this['_influences'];},'enumerable':!0x1,'configurable':!0x0}),_0x123021['prototype']['getActiveTarget']=function(_0x4a0fff){return this['_activeTargets']['data'][_0x4a0fff];},_0x123021['prototype']['getTarget']=function(_0x11ad4f){return this['_targets'][_0x11ad4f];},_0x123021['prototype']['addTarget']=function(_0x4b3fad){var _0x2e8db3=this;this['_targets']['push'](_0x4b3fad),this['_targetInfluenceChangedObservers']['push'](_0x4b3fad['onInfluenceChanged']['add'](function(_0xc05fd0){_0x2e8db3['_syncActiveTargets'](_0xc05fd0);})),this['_targetDataLayoutChangedObservers']['push'](_0x4b3fad['_onDataLayoutChanged']['add'](function(){_0x2e8db3['_syncActiveTargets'](!0x0);})),this['_syncActiveTargets'](!0x0);},_0x123021['prototype']['removeTarget']=function(_0x543a99){var _0x10bdd7=this['_targets']['indexOf'](_0x543a99);_0x10bdd7>=0x0&&(this['_targets']['splice'](_0x10bdd7,0x1),_0x543a99['onInfluenceChanged']['remove'](this['_targetInfluenceChangedObservers']['splice'](_0x10bdd7,0x1)[0x0]),_0x543a99['_onDataLayoutChanged']['remove'](this['_targetDataLayoutChangedObservers']['splice'](_0x10bdd7,0x1)[0x0]),this['_syncActiveTargets'](!0x0));},_0x123021['prototype']['clone']=function(){for(var _0x5a1d0f=new _0x123021(this['_scene']),_0x30e481=0x0,_0xe03533=this['_targets'];_0x30e481<_0xe03533['length'];_0x30e481++){var _0x40f9a9=_0xe03533[_0x30e481];_0x5a1d0f['addTarget'](_0x40f9a9['clone']());}return _0x5a1d0f['enableNormalMorphing']=this['enableNormalMorphing'],_0x5a1d0f['enableTangentMorphing']=this['enableTangentMorphing'],_0x5a1d0f['enableUVMorphing']=this['enableUVMorphing'],_0x5a1d0f;},_0x123021['prototype']['serialize']=function(){var _0x55e99b={};_0x55e99b['id']=this['uniqueId'],_0x55e99b['targets']=[];for(var _0x59af7e=0x0,_0x1a6084=this['_targets'];_0x59af7e<_0x1a6084['length'];_0x59af7e++){var _0x1c3f5e=_0x1a6084[_0x59af7e];_0x55e99b['targets']['push'](_0x1c3f5e['serialize']());}return _0x55e99b;},_0x123021['prototype']['_syncActiveTargets']=function(_0x377ff4){var _0x468ddc=0x0;this['_activeTargets']['reset'](),this['_supportsNormals']=!0x0,this['_supportsTangents']=!0x0,this['_supportsUVs']=!0x0,this['_vertexCount']=0x0;for(var _0x330fb2=0x0,_0x14de2a=this['_targets'];_0x330fb2<_0x14de2a['length'];_0x330fb2++){var _0x2234cf=_0x14de2a[_0x330fb2];if(0x0!==_0x2234cf['influence']){this['_activeTargets']['push'](_0x2234cf),this['_tempInfluences'][_0x468ddc++]=_0x2234cf['influence'],this['_supportsNormals']=this['_supportsNormals']&&_0x2234cf['hasNormals'],this['_supportsTangents']=this['_supportsTangents']&&_0x2234cf['hasTangents'],this['_supportsUVs']=this['_supportsUVs']&&_0x2234cf['hasUVs'];var _0x1f2dc8=_0x2234cf['getPositions']();if(_0x1f2dc8){var _0x4cbd31=_0x1f2dc8['length']/0x3;if(0x0===this['_vertexCount'])this['_vertexCount']=_0x4cbd31;else{if(this['_vertexCount']!==_0x4cbd31)return void _0x75193d['a']['Error']('Incompatible\x20target.\x20Targets\x20must\x20all\x20have\x20the\x20same\x20vertices\x20count.');}}}}this['_influences']&&this['_influences']['length']===_0x468ddc||(this['_influences']=new Float32Array(_0x468ddc));for(var _0x3c73ff=0x0;_0x3c73ff<_0x468ddc;_0x3c73ff++)this['_influences'][_0x3c73ff]=this['_tempInfluences'][_0x3c73ff];_0x377ff4&&this['synchronize']();},_0x123021['prototype']['synchronize']=function(){if(this['_scene'])for(var _0x3969a5=0x0,_0x2c04b9=this['_scene']['meshes'];_0x3969a5<_0x2c04b9['length'];_0x3969a5++){var _0x1d7494=_0x2c04b9[_0x3969a5];_0x1d7494['morphTargetManager']===this&&_0x1d7494['_syncGeometryWithMorphTargetManager']();}},_0x123021['Parse']=function(_0x48ea17,_0x258d3e){var _0x43d340=new _0x123021(_0x258d3e);_0x43d340['_uniqueId']=_0x48ea17['id'];for(var _0x347a4c=0x0,_0x5f1e81=_0x48ea17['targets'];_0x347a4c<_0x5f1e81['length'];_0x347a4c++){var _0x2de060=_0x5f1e81[_0x347a4c];_0x43d340['addTarget'](_0x233e18['Parse'](_0x2de060));}return _0x43d340;},_0x123021;}()),_0x3c10c7=_0x162675(0x20),_0x288b05=_0x162675(0x32),_0x598ff1=(function(){function _0x5cbea6(_0x4545d6,_0x30ea0b){if(void 0x0===_0x30ea0b&&(_0x30ea0b=_0x5cbea6['DefaultPluginFactory']()),this['_physicsPlugin']=_0x30ea0b,this['_impostors']=[],this['_joints']=[],this['_subTimeStep']=0x0,!this['_physicsPlugin']['isSupported']())throw new Error('Physics\x20Engine\x20'+this['_physicsPlugin']['name']+'\x20cannot\x20be\x20found.\x20Please\x20make\x20sure\x20it\x20is\x20included.');_0x4545d6=_0x4545d6||new _0x74d525['e'](0x0,-9.807,0x0),this['setGravity'](_0x4545d6),this['setTimeStep']();}return _0x5cbea6['DefaultPluginFactory']=function(){throw _0x2de344['a']['WarnImport']('CannonJSPlugin');},_0x5cbea6['prototype']['setGravity']=function(_0x3e635e){this['gravity']=_0x3e635e,this['_physicsPlugin']['setGravity'](this['gravity']);},_0x5cbea6['prototype']['setTimeStep']=function(_0x316f6d){void 0x0===_0x316f6d&&(_0x316f6d=0x1/0x3c),this['_physicsPlugin']['setTimeStep'](_0x316f6d);},_0x5cbea6['prototype']['getTimeStep']=function(){return this['_physicsPlugin']['getTimeStep']();},_0x5cbea6['prototype']['setSubTimeStep']=function(_0x50aeb8){void 0x0===_0x50aeb8&&(_0x50aeb8=0x0),this['_subTimeStep']=_0x50aeb8;},_0x5cbea6['prototype']['getSubTimeStep']=function(){return this['_subTimeStep'];},_0x5cbea6['prototype']['dispose']=function(){this['_impostors']['forEach'](function(_0x4ac928){_0x4ac928['dispose']();}),this['_physicsPlugin']['dispose']();},_0x5cbea6['prototype']['getPhysicsPluginName']=function(){return this['_physicsPlugin']['name'];},_0x5cbea6['prototype']['addImpostor']=function(_0x20d3ad){_0x20d3ad['uniqueId']=this['_impostors']['push'](_0x20d3ad),_0x20d3ad['parent']||this['_physicsPlugin']['generatePhysicsBody'](_0x20d3ad);},_0x5cbea6['prototype']['removeImpostor']=function(_0x165f7d){var _0xacf01c=this['_impostors']['indexOf'](_0x165f7d);_0xacf01c>-0x1&&(this['_impostors']['splice'](_0xacf01c,0x1)['length']&&this['getPhysicsPlugin']()['removePhysicsBody'](_0x165f7d));},_0x5cbea6['prototype']['addJoint']=function(_0x31c44a,_0x133cb1,_0x48327d){var _0x492cc2={'mainImpostor':_0x31c44a,'connectedImpostor':_0x133cb1,'joint':_0x48327d};_0x48327d['physicsPlugin']=this['_physicsPlugin'],this['_joints']['push'](_0x492cc2),this['_physicsPlugin']['generateJoint'](_0x492cc2);},_0x5cbea6['prototype']['removeJoint']=function(_0x4f85c7,_0x5d8aac,_0x3794a2){var _0x47f5cd=this['_joints']['filter'](function(_0x561438){return _0x561438['connectedImpostor']===_0x5d8aac&&_0x561438['joint']===_0x3794a2&&_0x561438['mainImpostor']===_0x4f85c7;});_0x47f5cd['length']&&this['_physicsPlugin']['removeJoint'](_0x47f5cd[0x0]);},_0x5cbea6['prototype']['_step']=function(_0x67051f){var _0x4e15a5=this;this['_impostors']['forEach'](function(_0x20b2f8){_0x20b2f8['isBodyInitRequired']()&&_0x4e15a5['_physicsPlugin']['generatePhysicsBody'](_0x20b2f8);}),_0x67051f>0.1?_0x67051f=0.1:_0x67051f<=0x0&&(_0x67051f=0x1/0x3c),this['_physicsPlugin']['executeStep'](_0x67051f,this['_impostors']);},_0x5cbea6['prototype']['getPhysicsPlugin']=function(){return this['_physicsPlugin'];},_0x5cbea6['prototype']['getImpostors']=function(){return this['_impostors'];},_0x5cbea6['prototype']['getImpostorForPhysicsObject']=function(_0x1f85cf){for(var _0x1e840a=0x0;_0x1e840a0x0&&(this['_physicsBodysToRemoveAfterStep']['forEach'](function(_0x3be54e){_0x34855e['world']['remove'](_0x3be54e);}),this['_physicsBodysToRemoveAfterStep']=[]);},_0x3f4266['prototype']['applyImpulse']=function(_0x55afda,_0xa95f59,_0x4f760b){var _0x57449d=new this['BJSCANNON']['Vec3'](_0x4f760b['x'],_0x4f760b['y'],_0x4f760b['z']),_0x57aa3a=new this['BJSCANNON']['Vec3'](_0xa95f59['x'],_0xa95f59['y'],_0xa95f59['z']);_0x55afda['physicsBody']['applyImpulse'](_0x57aa3a,_0x57449d);},_0x3f4266['prototype']['applyForce']=function(_0x5ed26a,_0x3c27ca,_0xfbda40){var _0x72b2dc=new this['BJSCANNON']['Vec3'](_0xfbda40['x'],_0xfbda40['y'],_0xfbda40['z']),_0x5edea1=new this['BJSCANNON']['Vec3'](_0x3c27ca['x'],_0x3c27ca['y'],_0x3c27ca['z']);_0x5ed26a['physicsBody']['applyForce'](_0x5edea1,_0x72b2dc);},_0x3f4266['prototype']['generatePhysicsBody']=function(_0x24e9b7){if(this['_removeMarkedPhysicsBodiesFromWorld'](),_0x24e9b7['parent'])_0x24e9b7['physicsBody']&&(this['removePhysicsBody'](_0x24e9b7),_0x24e9b7['forceUpdate']());else{if(_0x24e9b7['isBodyInitRequired']()){var _0x2f1cf7=this['_createShape'](_0x24e9b7),_0x499e18=_0x24e9b7['physicsBody'];_0x499e18&&this['removePhysicsBody'](_0x24e9b7);var _0xb337e8=this['_addMaterial']('mat-'+_0x24e9b7['uniqueId'],_0x24e9b7['getParam']('friction'),_0x24e9b7['getParam']('restitution')),_0x14111a={'mass':_0x24e9b7['getParam']('mass'),'material':_0xb337e8},_0x2ad300=_0x24e9b7['getParam']('nativeOptions');for(var _0x51b5fb in _0x2ad300)_0x2ad300['hasOwnProperty'](_0x51b5fb)&&(_0x14111a[_0x51b5fb]=_0x2ad300[_0x51b5fb]);_0x24e9b7['physicsBody']=new this['BJSCANNON']['Body'](_0x14111a),_0x24e9b7['physicsBody']['addEventListener']('collide',_0x24e9b7['onCollide']),this['world']['addEventListener']('preStep',_0x24e9b7['beforeStep']),this['world']['addEventListener']('postStep',_0x24e9b7['afterStep']),_0x24e9b7['physicsBody']['addShape'](_0x2f1cf7),this['world']['add'](_0x24e9b7['physicsBody']),_0x499e18&&['force','torque','velocity','angularVelocity']['forEach'](function(_0x169a54){var _0x1ee42d=_0x499e18[_0x169a54];_0x24e9b7['physicsBody'][_0x169a54]['set'](_0x1ee42d['x'],_0x1ee42d['y'],_0x1ee42d['z']);}),this['_processChildMeshes'](_0x24e9b7);}this['_updatePhysicsBodyTransformation'](_0x24e9b7);}},_0x3f4266['prototype']['_processChildMeshes']=function(_0x3d8444){var _0x346d38=this,_0xa21bac=_0x3d8444['object']['getChildMeshes']?_0x3d8444['object']['getChildMeshes'](!0x0):[],_0xf93c37=_0x3d8444['object']['rotationQuaternion'];if(_0xa21bac['length']){var _0xa2486d=function(_0x98ff2d){if(_0xf93c37&&_0x98ff2d['rotationQuaternion']){var _0x10a2db=_0x98ff2d['getPhysicsImpostor']();if(_0x10a2db){if(_0x10a2db['parent']!==_0x3d8444){var _0x135ab0=_0x98ff2d['getAbsolutePosition']()['subtract'](_0x98ff2d['parent']['getAbsolutePosition']()),_0x5e076d=_0x98ff2d['rotationQuaternion'];_0x10a2db['physicsBody']&&(_0x346d38['removePhysicsBody'](_0x10a2db),_0x10a2db['physicsBody']=null),_0x10a2db['parent']=_0x3d8444,_0x10a2db['resetUpdateFlags'](),_0x3d8444['physicsBody']['addShape'](_0x346d38['_createShape'](_0x10a2db),new _0x346d38['BJSCANNON']['Vec3'](_0x135ab0['x'],_0x135ab0['y'],_0x135ab0['z']),new _0x346d38['BJSCANNON']['Quaternion'](_0x5e076d['x'],_0x5e076d['y'],_0x5e076d['z'],_0x5e076d['w'])),_0x3d8444['physicsBody']['mass']+=_0x10a2db['getParam']('mass');}}_0xf93c37['multiplyInPlace'](_0x98ff2d['rotationQuaternion']),_0x98ff2d['getChildMeshes'](!0x0)['filter'](function(_0x3fb751){return!!_0x3fb751['physicsImpostor'];})['forEach'](_0xa2486d);}};_0xa21bac['filter'](function(_0x4dee01){return!!_0x4dee01['physicsImpostor'];})['forEach'](_0xa2486d);}},_0x3f4266['prototype']['removePhysicsBody']=function(_0xd53adf){_0xd53adf['physicsBody']['removeEventListener']('collide',_0xd53adf['onCollide']),this['world']['removeEventListener']('preStep',_0xd53adf['beforeStep']),this['world']['removeEventListener']('postStep',_0xd53adf['afterStep']),-0x1===this['_physicsBodysToRemoveAfterStep']['indexOf'](_0xd53adf['physicsBody'])&&this['_physicsBodysToRemoveAfterStep']['push'](_0xd53adf['physicsBody']);},_0x3f4266['prototype']['generateJoint']=function(_0x5593eb){var _0xb85ba1=_0x5593eb['mainImpostor']['physicsBody'],_0x4a14df=_0x5593eb['connectedImpostor']['physicsBody'];if(_0xb85ba1&&_0x4a14df){var _0x42e178,_0x3e3047=_0x5593eb['joint']['jointData'],_0x11249e={'pivotA':_0x3e3047['mainPivot']?new this['BJSCANNON']['Vec3']()['set'](_0x3e3047['mainPivot']['x'],_0x3e3047['mainPivot']['y'],_0x3e3047['mainPivot']['z']):null,'pivotB':_0x3e3047['connectedPivot']?new this['BJSCANNON']['Vec3']()['set'](_0x3e3047['connectedPivot']['x'],_0x3e3047['connectedPivot']['y'],_0x3e3047['connectedPivot']['z']):null,'axisA':_0x3e3047['mainAxis']?new this['BJSCANNON']['Vec3']()['set'](_0x3e3047['mainAxis']['x'],_0x3e3047['mainAxis']['y'],_0x3e3047['mainAxis']['z']):null,'axisB':_0x3e3047['connectedAxis']?new this['BJSCANNON']['Vec3']()['set'](_0x3e3047['connectedAxis']['x'],_0x3e3047['connectedAxis']['y'],_0x3e3047['connectedAxis']['z']):null,'maxForce':_0x3e3047['nativeParams']['maxForce'],'collideConnected':!!_0x3e3047['collision']};switch(_0x5593eb['joint']['type']){case _0x288b05['e']['HingeJoint']:case _0x288b05['e']['Hinge2Joint']:_0x42e178=new this['BJSCANNON']['HingeConstraint'](_0xb85ba1,_0x4a14df,_0x11249e);break;case _0x288b05['e']['DistanceJoint']:_0x42e178=new this['BJSCANNON']['DistanceConstraint'](_0xb85ba1,_0x4a14df,_0x3e3047['maxDistance']||0x2);break;case _0x288b05['e']['SpringJoint']:var _0x504145=_0x3e3047;_0x42e178=new this['BJSCANNON']['Spring'](_0xb85ba1,_0x4a14df,{'restLength':_0x504145['length'],'stiffness':_0x504145['stiffness'],'damping':_0x504145['damping'],'localAnchorA':_0x11249e['pivotA'],'localAnchorB':_0x11249e['pivotB']});break;case _0x288b05['e']['LockJoint']:_0x42e178=new this['BJSCANNON']['LockConstraint'](_0xb85ba1,_0x4a14df,_0x11249e);break;case _0x288b05['e']['PointToPointJoint']:case _0x288b05['e']['BallAndSocketJoint']:default:_0x42e178=new this['BJSCANNON']['PointToPointConstraint'](_0xb85ba1,_0x11249e['pivotA'],_0x4a14df,_0x11249e['pivotB'],_0x11249e['maxForce']);}_0x42e178['collideConnected']=!!_0x3e3047['collision'],_0x5593eb['joint']['physicsJoint']=_0x42e178,_0x5593eb['joint']['type']!==_0x288b05['e']['SpringJoint']?this['world']['addConstraint'](_0x42e178):(_0x5593eb['joint']['jointData']['forceApplicationCallback']=_0x5593eb['joint']['jointData']['forceApplicationCallback']||function(){_0x42e178['applyForce']();},_0x5593eb['mainImpostor']['registerAfterPhysicsStep'](_0x5593eb['joint']['jointData']['forceApplicationCallback']));}},_0x3f4266['prototype']['removeJoint']=function(_0x1aab31){_0x1aab31['joint']['type']!==_0x288b05['e']['SpringJoint']?this['world']['removeConstraint'](_0x1aab31['joint']['physicsJoint']):_0x1aab31['mainImpostor']['unregisterAfterPhysicsStep'](_0x1aab31['joint']['jointData']['forceApplicationCallback']);},_0x3f4266['prototype']['_addMaterial']=function(_0x12cb5f,_0x5e874d,_0x59fff9){var _0x31cf90,_0x4fd7f8;for(_0x31cf90=0x0;_0x31cf900x3e8*_0x1f1a5a));_0x766236++);this['time']+=_0x3543f7;for(var _0x3365a3=this['time']%_0x1f1a5a/_0x1f1a5a,_0x4592c8=_0xaaee07,_0x4ef6e9=this['bodies'],_0x8f70e3=0x0;_0x8f70e3!==_0x4ef6e9['length'];_0x8f70e3++){var _0x4faa37=_0x4ef6e9[_0x8f70e3];_0x4faa37['type']!==_0x5d9249['Body']['STATIC']&&_0x4faa37['sleepState']!==_0x5d9249['Body']['SLEEPING']?(_0x4faa37['position']['vsub'](_0x4faa37['previousPosition'],_0x4592c8),_0x4592c8['scale'](_0x3365a3,_0x4592c8),_0x4faa37['position']['vadd'](_0x4592c8,_0x4faa37['interpolatedPosition'])):(_0x4faa37['interpolatedPosition']['set'](_0x4faa37['position']['x'],_0x4faa37['position']['y'],_0x4faa37['position']['z']),_0x4faa37['interpolatedQuaternion']['set'](_0x4faa37['quaternion']['x'],_0x4faa37['quaternion']['y'],_0x4faa37['quaternion']['z'],_0x4faa37['quaternion']['w']));}}};},_0x3f4266['prototype']['raycast']=function(_0x2d3c0f,_0x14b233){return this['_cannonRaycastResult']['reset'](),this['world']['raycastClosest'](_0x2d3c0f,_0x14b233,{},this['_cannonRaycastResult']),this['_raycastResult']['reset'](_0x2d3c0f,_0x14b233),this['_cannonRaycastResult']['hasHit']&&(this['_raycastResult']['setHitData']({'x':this['_cannonRaycastResult']['hitNormalWorld']['x'],'y':this['_cannonRaycastResult']['hitNormalWorld']['y'],'z':this['_cannonRaycastResult']['hitNormalWorld']['z']},{'x':this['_cannonRaycastResult']['hitPointWorld']['x'],'y':this['_cannonRaycastResult']['hitPointWorld']['y'],'z':this['_cannonRaycastResult']['hitPointWorld']['z']}),this['_raycastResult']['setHitDistance'](this['_cannonRaycastResult']['distance'])),this['_raycastResult'];},_0x3f4266;}());_0x598ff1['DefaultPluginFactory']=function(){return new _0x52f9b1();};var _0x128d84=(function(){function _0x1d7592(_0x140080,_0x5c36d4,_0x31e4bb){void 0x0===_0x140080&&(_0x140080=!0x0),void 0x0===_0x31e4bb&&(_0x31e4bb=OIMO),this['_useDeltaForWorldStep']=_0x140080,this['name']='OimoJSPlugin',this['_fixedTimeStep']=0x1/0x3c,this['_tmpImpostorsArray']=[],this['_tmpPositionVector']=_0x74d525['e']['Zero'](),this['BJSOIMO']=_0x31e4bb,this['world']=new this['BJSOIMO']['World']({'iterations':_0x5c36d4}),this['world']['clear'](),this['_raycastResult']=new _0x2e5c1f();}return _0x1d7592['prototype']['setGravity']=function(_0x23ff84){this['world']['gravity']['set'](_0x23ff84['x'],_0x23ff84['y'],_0x23ff84['z']);},_0x1d7592['prototype']['setTimeStep']=function(_0x52c081){this['world']['timeStep']=_0x52c081;},_0x1d7592['prototype']['getTimeStep']=function(){return this['world']['timeStep'];},_0x1d7592['prototype']['executeStep']=function(_0x4674c5,_0x5d8280){var _0x3a41df=this;_0x5d8280['forEach'](function(_0x24665d){_0x24665d['beforeStep']();}),this['world']['timeStep']=this['_useDeltaForWorldStep']?_0x4674c5:this['_fixedTimeStep'],this['world']['step'](),_0x5d8280['forEach'](function(_0x44463c){_0x44463c['afterStep'](),_0x3a41df['_tmpImpostorsArray'][_0x44463c['uniqueId']]=_0x44463c;});for(var _0x522668=this['world']['contacts'];null!==_0x522668;)if(!_0x522668['touching']||_0x522668['body1']['sleeping']||_0x522668['body2']['sleeping']){var _0x637493=this['_tmpImpostorsArray'][+_0x522668['body1']['name']],_0x83f6b7=this['_tmpImpostorsArray'][+_0x522668['body2']['name']];_0x637493&&_0x83f6b7?(_0x637493['onCollide']({'body':_0x83f6b7['physicsBody'],'point':null}),_0x83f6b7['onCollide']({'body':_0x637493['physicsBody'],'point':null}),_0x522668=_0x522668['next']):_0x522668=_0x522668['next'];}else _0x522668=_0x522668['next'];},_0x1d7592['prototype']['applyImpulse']=function(_0x4563bd,_0x659d30,_0x1a6586){var _0x5a98c6=_0x4563bd['physicsBody']['mass'];_0x4563bd['physicsBody']['applyImpulse'](_0x1a6586['scale'](this['world']['invScale']),_0x659d30['scale'](this['world']['invScale']*_0x5a98c6));},_0x1d7592['prototype']['applyForce']=function(_0x3c19c1,_0x57cbfa,_0x4a19e0){_0x75193d['a']['Warn']('Oimo\x20doesn\x27t\x20support\x20applying\x20force.\x20Using\x20impule\x20instead.'),this['applyImpulse'](_0x3c19c1,_0x57cbfa,_0x4a19e0);},_0x1d7592['prototype']['generatePhysicsBody']=function(_0x564409){var _0x6ba9c5=this;if(_0x564409['parent'])_0x564409['physicsBody']&&(this['removePhysicsBody'](_0x564409),_0x564409['forceUpdate']());else{if(_0x564409['isBodyInitRequired']()){var _0x1c1636={'name':_0x564409['uniqueId'],'config':[_0x564409['getParam']('mass')||0.001,_0x564409['getParam']('friction'),_0x564409['getParam']('restitution')],'size':[],'type':[],'pos':[],'posShape':[],'rot':[],'rotShape':[],'move':0x0!==_0x564409['getParam']('mass'),'density':_0x564409['getParam']('mass'),'friction':_0x564409['getParam']('friction'),'restitution':_0x564409['getParam']('restitution'),'world':this['world']},_0x5e5a4b=[_0x564409];(_0x4f555e=_0x564409['object'])['getChildMeshes']&&_0x4f555e['getChildMeshes']()['forEach'](function(_0x1eccdc){_0x1eccdc['physicsImpostor']&&_0x5e5a4b['push'](_0x1eccdc['physicsImpostor']);});var _0x2585f0=function(_0x52752d){return Math['max'](_0x52752d,_0x598ff1['Epsilon']);},_0x552cb1=new _0x74d525['b']();_0x5e5a4b['forEach'](function(_0x48c846){if(_0x48c846['object']['rotationQuaternion']){var _0x3944e7=_0x48c846['object']['rotationQuaternion'];_0x552cb1['copyFrom'](_0x3944e7),_0x48c846['object']['rotationQuaternion']['set'](0x0,0x0,0x0,0x1),_0x48c846['object']['computeWorldMatrix'](!0x0);var _0x26a443=_0x552cb1['toEulerAngles'](),_0x57a5e2=_0x48c846['getObjectExtendSize']();if(_0x48c846===_0x564409){var _0x3e0bc3=_0x564409['getObjectCenter']();_0x564409['object']['getAbsolutePivotPoint']()['subtractToRef'](_0x3e0bc3,_0x6ba9c5['_tmpPositionVector']),_0x6ba9c5['_tmpPositionVector']['divideInPlace'](_0x564409['object']['scaling']),_0x1c1636['pos']['push'](_0x3e0bc3['x']),_0x1c1636['pos']['push'](_0x3e0bc3['y']),_0x1c1636['pos']['push'](_0x3e0bc3['z']),_0x1c1636['posShape']['push'](0x0,0x0,0x0),_0x1c1636['rotShape']['push'](0x0,0x0,0x0);}else{var _0x356c99=_0x48c846['object']['position']['clone']();_0x1c1636['posShape']['push'](_0x356c99['x']),_0x1c1636['posShape']['push'](_0x356c99['y']),_0x1c1636['posShape']['push'](_0x356c99['z']),_0x1c1636['rotShape']['push'](57.29577951308232*_0x26a443['x'],57.29577951308232*_0x26a443['y'],57.29577951308232*_0x26a443['z']);}switch(_0x48c846['object']['rotationQuaternion']['copyFrom'](_0x552cb1),_0x48c846['type']){case _0x3c10c7['a']['ParticleImpostor']:_0x75193d['a']['Warn']('No\x20Particle\x20support\x20in\x20OIMO.js.\x20using\x20SphereImpostor\x20instead');case _0x3c10c7['a']['SphereImpostor']:var _0x177a49=_0x57a5e2['x'],_0xac5f67=_0x57a5e2['y'],_0x1d70f4=_0x57a5e2['z'],_0x4cfb99=Math['max'](_0x2585f0(_0x177a49),_0x2585f0(_0xac5f67),_0x2585f0(_0x1d70f4))/0x2;_0x1c1636['type']['push']('sphere'),_0x1c1636['size']['push'](_0x4cfb99),_0x1c1636['size']['push'](_0x4cfb99),_0x1c1636['size']['push'](_0x4cfb99);break;case _0x3c10c7['a']['CylinderImpostor']:var _0x3a4d07=_0x2585f0(_0x57a5e2['x'])/0x2,_0x338ab5=_0x2585f0(_0x57a5e2['y']);_0x1c1636['type']['push']('cylinder'),_0x1c1636['size']['push'](_0x3a4d07),_0x1c1636['size']['push'](_0x338ab5),_0x1c1636['size']['push'](_0x338ab5);break;case _0x3c10c7['a']['PlaneImpostor']:case _0x3c10c7['a']['BoxImpostor']:default:_0x3a4d07=_0x2585f0(_0x57a5e2['x']),_0x338ab5=_0x2585f0(_0x57a5e2['y']);var _0x272eb0=_0x2585f0(_0x57a5e2['z']);_0x1c1636['type']['push']('box'),_0x1c1636['size']['push'](_0x3a4d07),_0x1c1636['size']['push'](_0x338ab5),_0x1c1636['size']['push'](_0x272eb0);}_0x48c846['object']['rotationQuaternion']=_0x3944e7;}}),_0x564409['physicsBody']=this['world']['add'](_0x1c1636),_0x564409['physicsBody']['resetQuaternion'](_0x552cb1),_0x564409['physicsBody']['updatePosition'](0x0);}else this['_tmpPositionVector']['copyFromFloats'](0x0,0x0,0x0);var _0x4f555e;_0x564409['setDeltaPosition'](this['_tmpPositionVector']);}},_0x1d7592['prototype']['removePhysicsBody']=function(_0x1b2103){this['world']['removeRigidBody'](_0x1b2103['physicsBody']);},_0x1d7592['prototype']['generateJoint']=function(_0x59b6b7){var _0x45e513=_0x59b6b7['mainImpostor']['physicsBody'],_0x147241=_0x59b6b7['connectedImpostor']['physicsBody'];if(_0x45e513&&_0x147241){var _0x2c8d04,_0x57e153=_0x59b6b7['joint']['jointData'],_0x1485b1=_0x57e153['nativeParams']||{},_0x4a5484={'body1':_0x45e513,'body2':_0x147241,'axe1':_0x1485b1['axe1']||(_0x57e153['mainAxis']?_0x57e153['mainAxis']['asArray']():null),'axe2':_0x1485b1['axe2']||(_0x57e153['connectedAxis']?_0x57e153['connectedAxis']['asArray']():null),'pos1':_0x1485b1['pos1']||(_0x57e153['mainPivot']?_0x57e153['mainPivot']['asArray']():null),'pos2':_0x1485b1['pos2']||(_0x57e153['connectedPivot']?_0x57e153['connectedPivot']['asArray']():null),'min':_0x1485b1['min'],'max':_0x1485b1['max'],'collision':_0x1485b1['collision']||_0x57e153['collision'],'spring':_0x1485b1['spring'],'world':this['world']};switch(_0x59b6b7['joint']['type']){case _0x288b05['e']['BallAndSocketJoint']:_0x2c8d04='jointBall';break;case _0x288b05['e']['SpringJoint']:_0x75193d['a']['Warn']('OIMO.js\x20doesn\x27t\x20support\x20Spring\x20Constraint.\x20Simulating\x20using\x20DistanceJoint\x20instead');var _0x1cc786=_0x57e153;_0x4a5484['min']=_0x1cc786['length']||_0x4a5484['min'],_0x4a5484['max']=Math['max'](_0x4a5484['min'],_0x4a5484['max']);case _0x288b05['e']['DistanceJoint']:_0x2c8d04='jointDistance',_0x4a5484['max']=_0x57e153['maxDistance'];break;case _0x288b05['e']['PrismaticJoint']:_0x2c8d04='jointPrisme';break;case _0x288b05['e']['SliderJoint']:_0x2c8d04='jointSlide';break;case _0x288b05['e']['WheelJoint']:_0x2c8d04='jointWheel';break;case _0x288b05['e']['HingeJoint']:default:_0x2c8d04='jointHinge';}_0x4a5484['type']=_0x2c8d04,_0x59b6b7['joint']['physicsJoint']=this['world']['add'](_0x4a5484);}},_0x1d7592['prototype']['removeJoint']=function(_0x18c9e4){try{this['world']['removeJoint'](_0x18c9e4['joint']['physicsJoint']);}catch(_0x4b74b7){_0x75193d['a']['Warn'](_0x4b74b7);}},_0x1d7592['prototype']['isSupported']=function(){return void 0x0!==this['BJSOIMO'];},_0x1d7592['prototype']['setTransformationFromPhysicsBody']=function(_0x2f98af){if(!_0x2f98af['physicsBody']['sleeping']){if(_0x2f98af['physicsBody']['shapes']['next']){for(var _0x36edc2=_0x2f98af['physicsBody']['shapes'];_0x36edc2['next'];)_0x36edc2=_0x36edc2['next'];_0x2f98af['object']['position']['set'](_0x36edc2['position']['x'],_0x36edc2['position']['y'],_0x36edc2['position']['z']);}else{var _0x5d39fc=_0x2f98af['physicsBody']['getPosition']();_0x2f98af['object']['position']['set'](_0x5d39fc['x'],_0x5d39fc['y'],_0x5d39fc['z']);}if(_0x2f98af['object']['rotationQuaternion']){var _0x429583=_0x2f98af['physicsBody']['getQuaternion']();_0x2f98af['object']['rotationQuaternion']['set'](_0x429583['x'],_0x429583['y'],_0x429583['z'],_0x429583['w']);}}},_0x1d7592['prototype']['setPhysicsBodyTransformation']=function(_0x5570b6,_0x158b7c,_0x3fe188){var _0x33055a=_0x5570b6['physicsBody'];_0x5570b6['physicsBody']['shapes']['next']||(_0x33055a['position']['set'](_0x158b7c['x'],_0x158b7c['y'],_0x158b7c['z']),_0x33055a['orientation']['set'](_0x3fe188['x'],_0x3fe188['y'],_0x3fe188['z'],_0x3fe188['w']),_0x33055a['syncShapes'](),_0x33055a['awake']());},_0x1d7592['prototype']['setLinearVelocity']=function(_0x359792,_0x44db73){_0x359792['physicsBody']['linearVelocity']['set'](_0x44db73['x'],_0x44db73['y'],_0x44db73['z']);},_0x1d7592['prototype']['setAngularVelocity']=function(_0x10329f,_0x4d1f51){_0x10329f['physicsBody']['angularVelocity']['set'](_0x4d1f51['x'],_0x4d1f51['y'],_0x4d1f51['z']);},_0x1d7592['prototype']['getLinearVelocity']=function(_0x310827){var _0x4ed64e=_0x310827['physicsBody']['linearVelocity'];return _0x4ed64e?new _0x74d525['e'](_0x4ed64e['x'],_0x4ed64e['y'],_0x4ed64e['z']):null;},_0x1d7592['prototype']['getAngularVelocity']=function(_0x4e33b9){var _0x221fe1=_0x4e33b9['physicsBody']['angularVelocity'];return _0x221fe1?new _0x74d525['e'](_0x221fe1['x'],_0x221fe1['y'],_0x221fe1['z']):null;},_0x1d7592['prototype']['setBodyMass']=function(_0x44088c,_0x3a9266){var _0x49f236=0x0===_0x3a9266;_0x44088c['physicsBody']['shapes']['density']=_0x49f236?0x1:_0x3a9266,_0x44088c['physicsBody']['setupMass'](_0x49f236?0x2:0x1);},_0x1d7592['prototype']['getBodyMass']=function(_0x21be1a){return _0x21be1a['physicsBody']['shapes']['density'];},_0x1d7592['prototype']['getBodyFriction']=function(_0xec527c){return _0xec527c['physicsBody']['shapes']['friction'];},_0x1d7592['prototype']['setBodyFriction']=function(_0x2751ae,_0x5f1aa1){_0x2751ae['physicsBody']['shapes']['friction']=_0x5f1aa1;},_0x1d7592['prototype']['getBodyRestitution']=function(_0x1837e3){return _0x1837e3['physicsBody']['shapes']['restitution'];},_0x1d7592['prototype']['setBodyRestitution']=function(_0x1182e2,_0x295c89){_0x1182e2['physicsBody']['shapes']['restitution']=_0x295c89;},_0x1d7592['prototype']['sleepBody']=function(_0x5801cc){_0x5801cc['physicsBody']['sleep']();},_0x1d7592['prototype']['wakeUpBody']=function(_0x29db99){_0x29db99['physicsBody']['awake']();},_0x1d7592['prototype']['updateDistanceJoint']=function(_0x36d2b5,_0x2c3893,_0x54653a){_0x36d2b5['physicsJoint']['limitMotor']['upperLimit']=_0x2c3893,void 0x0!==_0x54653a&&(_0x36d2b5['physicsJoint']['limitMotor']['lowerLimit']=_0x54653a);},_0x1d7592['prototype']['setMotor']=function(_0xd2a2c4,_0x48b354,_0x2503d4,_0x36eaec){void 0x0!==_0x2503d4?_0x75193d['a']['Warn']('OimoJS\x20plugin\x20currently\x20has\x20unexpected\x20behavior\x20when\x20using\x20setMotor\x20with\x20force\x20parameter'):_0x2503d4=0xf4240,_0x48b354*=-0x1;var _0x1524f7=_0x36eaec?_0xd2a2c4['physicsJoint']['rotationalLimitMotor2']:_0xd2a2c4['physicsJoint']['rotationalLimitMotor1']||_0xd2a2c4['physicsJoint']['rotationalLimitMotor']||_0xd2a2c4['physicsJoint']['limitMotor'];_0x1524f7&&_0x1524f7['setMotor'](_0x48b354,_0x2503d4);},_0x1d7592['prototype']['setLimit']=function(_0x1f55c6,_0x2fd422,_0x292ad8,_0x43ef4f){var _0x5483d8=_0x43ef4f?_0x1f55c6['physicsJoint']['rotationalLimitMotor2']:_0x1f55c6['physicsJoint']['rotationalLimitMotor1']||_0x1f55c6['physicsJoint']['rotationalLimitMotor']||_0x1f55c6['physicsJoint']['limitMotor'];_0x5483d8&&_0x5483d8['setLimit'](_0x2fd422,void 0x0===_0x292ad8?-_0x2fd422:_0x292ad8);},_0x1d7592['prototype']['syncMeshWithImpostor']=function(_0x112fcf,_0x50017f){var _0x20a5f7=_0x50017f['physicsBody'];_0x112fcf['position']['x']=_0x20a5f7['position']['x'],_0x112fcf['position']['y']=_0x20a5f7['position']['y'],_0x112fcf['position']['z']=_0x20a5f7['position']['z'],_0x112fcf['rotationQuaternion']&&(_0x112fcf['rotationQuaternion']['x']=_0x20a5f7['orientation']['x'],_0x112fcf['rotationQuaternion']['y']=_0x20a5f7['orientation']['y'],_0x112fcf['rotationQuaternion']['z']=_0x20a5f7['orientation']['z'],_0x112fcf['rotationQuaternion']['w']=_0x20a5f7['orientation']['s']);},_0x1d7592['prototype']['getRadius']=function(_0x1c3f5f){return _0x1c3f5f['physicsBody']['shapes']['radius'];},_0x1d7592['prototype']['getBoxSizeToRef']=function(_0x3b0b76,_0x2bf2da){var _0x149dc3=_0x3b0b76['physicsBody']['shapes'];_0x2bf2da['x']=0x2*_0x149dc3['halfWidth'],_0x2bf2da['y']=0x2*_0x149dc3['halfHeight'],_0x2bf2da['z']=0x2*_0x149dc3['halfDepth'];},_0x1d7592['prototype']['dispose']=function(){this['world']['clear']();},_0x1d7592['prototype']['raycast']=function(_0x3302ba,_0x54ba23){return _0x75193d['a']['Warn']('raycast\x20is\x20not\x20currently\x20supported\x20by\x20the\x20Oimo\x20physics\x20plugin'),this['_raycastResult']['reset'](_0x3302ba,_0x54ba23),this['_raycastResult'];},_0x1d7592;}()),_0x13b0e7=_0x162675(0x61),_0x1e7dd4=(function(){function _0x5896c3(_0x36036c,_0x391c7b,_0x57100f){var _0x56e33f=this;void 0x0===_0x36036c&&(_0x36036c=!0x0),void 0x0===_0x391c7b&&(_0x391c7b=Ammo),void 0x0===_0x57100f&&(_0x57100f=null),this['_useDeltaForWorldStep']=_0x36036c,this['bjsAMMO']={},this['name']='AmmoJSPlugin',this['_timeStep']=0x1/0x3c,this['_fixedTimeStep']=0x1/0x3c,this['_maxSteps']=0x5,this['_tmpQuaternion']=new _0x74d525['b'](),this['_tmpContactCallbackResult']=!0x1,this['_tmpContactPoint']=new _0x74d525['e'](),this['_tmpMatrix']=new _0x74d525['a'](),'function'==typeof _0x391c7b?_0x391c7b(this['bjsAMMO']):this['bjsAMMO']=_0x391c7b,this['isSupported']()?(this['_collisionConfiguration']=new this['bjsAMMO']['btSoftBodyRigidBodyCollisionConfiguration'](),this['_dispatcher']=new this['bjsAMMO']['btCollisionDispatcher'](this['_collisionConfiguration']),this['_overlappingPairCache']=_0x57100f||new this['bjsAMMO']['btDbvtBroadphase'](),this['_solver']=new this['bjsAMMO']['btSequentialImpulseConstraintSolver'](),this['_softBodySolver']=new this['bjsAMMO']['btDefaultSoftBodySolver'](),this['world']=new this['bjsAMMO']['btSoftRigidDynamicsWorld'](this['_dispatcher'],this['_overlappingPairCache'],this['_solver'],this['_collisionConfiguration'],this['_softBodySolver']),this['_tmpAmmoConcreteContactResultCallback']=new this['bjsAMMO']['ConcreteContactResultCallback'](),this['_tmpAmmoConcreteContactResultCallback']['addSingleResult']=function(_0x4928ad,_0x73def1,_0x2013a1,_0x57c077){var _0x3320d5=(_0x4928ad=_0x56e33f['bjsAMMO']['wrapPointer'](_0x4928ad,Ammo['btManifoldPoint']))['getPositionWorldOnA']();_0x56e33f['_tmpContactPoint']['x']=_0x3320d5['x'](),_0x56e33f['_tmpContactPoint']['y']=_0x3320d5['y'](),_0x56e33f['_tmpContactPoint']['z']=_0x3320d5['z'](),_0x56e33f['_tmpContactCallbackResult']=!0x0;},this['_raycastResult']=new _0x2e5c1f(),this['_tmpAmmoTransform']=new this['bjsAMMO']['btTransform'](),this['_tmpAmmoTransform']['setIdentity'](),this['_tmpAmmoQuaternion']=new this['bjsAMMO']['btQuaternion'](0x0,0x0,0x0,0x1),this['_tmpAmmoVectorA']=new this['bjsAMMO']['btVector3'](0x0,0x0,0x0),this['_tmpAmmoVectorB']=new this['bjsAMMO']['btVector3'](0x0,0x0,0x0),this['_tmpAmmoVectorC']=new this['bjsAMMO']['btVector3'](0x0,0x0,0x0),this['_tmpAmmoVectorD']=new this['bjsAMMO']['btVector3'](0x0,0x0,0x0)):_0x75193d['a']['Error']('AmmoJS\x20is\x20not\x20available.\x20Please\x20make\x20sure\x20you\x20included\x20the\x20js\x20file.');}return _0x5896c3['prototype']['setGravity']=function(_0xdb51ff){this['_tmpAmmoVectorA']['setValue'](_0xdb51ff['x'],_0xdb51ff['y'],_0xdb51ff['z']),this['world']['setGravity'](this['_tmpAmmoVectorA']),this['world']['getWorldInfo']()['set_m_gravity'](this['_tmpAmmoVectorA']);},_0x5896c3['prototype']['setTimeStep']=function(_0x288697){this['_timeStep']=_0x288697;},_0x5896c3['prototype']['setFixedTimeStep']=function(_0x420ed5){this['_fixedTimeStep']=_0x420ed5;},_0x5896c3['prototype']['setMaxSteps']=function(_0x2628db){this['_maxSteps']=_0x2628db;},_0x5896c3['prototype']['getTimeStep']=function(){return this['_timeStep'];},_0x5896c3['prototype']['_isImpostorInContact']=function(_0x30a797){return this['_tmpContactCallbackResult']=!0x1,this['world']['contactTest'](_0x30a797['physicsBody'],this['_tmpAmmoConcreteContactResultCallback']),this['_tmpContactCallbackResult'];},_0x5896c3['prototype']['_isImpostorPairInContact']=function(_0x54a8ec,_0x3989d2){return this['_tmpContactCallbackResult']=!0x1,this['world']['contactPairTest'](_0x54a8ec['physicsBody'],_0x3989d2['physicsBody'],this['_tmpAmmoConcreteContactResultCallback']),this['_tmpContactCallbackResult'];},_0x5896c3['prototype']['_stepSimulation']=function(_0x3c1944,_0x13bc44,_0xea155d){if(void 0x0===_0x3c1944&&(_0x3c1944=0x1/0x3c),void 0x0===_0x13bc44&&(_0x13bc44=0xa),void 0x0===_0xea155d&&(_0xea155d=0x1/0x3c),0x0==_0x13bc44)this['world']['stepSimulation'](_0x3c1944,0x0);else{for(;_0x13bc44>0x0&&_0x3c1944>0x0;)_0x3c1944-_0xea155d<_0xea155d?(this['world']['stepSimulation'](_0x3c1944,0x0),_0x3c1944=0x0):(_0x3c1944-=_0xea155d,this['world']['stepSimulation'](_0xea155d,0x0)),_0x13bc44--;}},_0x5896c3['prototype']['executeStep']=function(_0x420214,_0x179174){for(var _0x527c28=0x0,_0x24b4db=_0x179174;_0x527c28<_0x24b4db['length'];_0x527c28++){var _0x35e093=_0x24b4db[_0x527c28];_0x35e093['soft']||_0x35e093['beforeStep']();}this['_stepSimulation'](this['_useDeltaForWorldStep']?_0x420214:this['_timeStep'],this['_maxSteps'],this['_fixedTimeStep']);for(var _0x397cf6=0x0,_0x1fb67c=_0x179174;_0x397cf6<_0x1fb67c['length'];_0x397cf6++){var _0x10c7d6=_0x1fb67c[_0x397cf6];if(_0x10c7d6['soft']?this['_afterSoftStep'](_0x10c7d6):_0x10c7d6['afterStep'](),_0x10c7d6['_onPhysicsCollideCallbacks']['length']>0x0&&this['_isImpostorInContact'](_0x10c7d6)){for(var _0x402848=0x0,_0x4fdd31=_0x10c7d6['_onPhysicsCollideCallbacks'];_0x402848<_0x4fdd31['length'];_0x402848++)for(var _0x288382=0x0,_0x9d8503=_0x4fdd31[_0x402848]['otherImpostors'];_0x288382<_0x9d8503['length'];_0x288382++){var _0x857f64=_0x9d8503[_0x288382];(_0x10c7d6['physicsBody']['isActive']()||_0x857f64['physicsBody']['isActive']())&&this['_isImpostorPairInContact'](_0x10c7d6,_0x857f64)&&(_0x10c7d6['onCollide']({'body':_0x857f64['physicsBody'],'point':this['_tmpContactPoint']}),_0x857f64['onCollide']({'body':_0x10c7d6['physicsBody'],'point':this['_tmpContactPoint']}));}}}},_0x5896c3['prototype']['_afterSoftStep']=function(_0x1672da){_0x1672da['type']===_0x3c10c7['a']['RopeImpostor']?this['_ropeStep'](_0x1672da):this['_softbodyOrClothStep'](_0x1672da);},_0x5896c3['prototype']['_ropeStep']=function(_0x19c72c){for(var _0x4448ab,_0x548eaa,_0xf07152,_0x3e865c,_0x8b2e19=_0x19c72c['physicsBody']['get_m_nodes'](),_0x5c5452=_0x8b2e19['size'](),_0x61a35d=new Array(),_0x14ad8f=0x0;_0x14ad8f<_0x5c5452;_0x14ad8f++)_0x548eaa=(_0x4448ab=_0x8b2e19['at'](_0x14ad8f)['get_m_x']())['x'](),_0xf07152=_0x4448ab['y'](),_0x3e865c=_0x4448ab['z'](),_0x61a35d['push'](new _0x74d525['e'](_0x548eaa,_0xf07152,_0x3e865c));var _0x3116c2=_0x19c72c['object'],_0x3f5295=_0x19c72c['getParam']('shape');_0x19c72c['_isFromLine']?_0x19c72c['object']=_0x333a74['a']['CreateLines']('lines',{'points':_0x61a35d,'instance':_0x3116c2}):_0x19c72c['object']=_0x13b0e7['a']['ExtrudeShape']('ext',{'shape':_0x3f5295,'path':_0x61a35d,'instance':_0x3116c2});},_0x5896c3['prototype']['_softbodyOrClothStep']=function(_0x5b7f0b){var _0x4df513=_0x5b7f0b['type']===_0x3c10c7['a']['ClothImpostor']?0x1:-0x1,_0x5c24e3=_0x5b7f0b['object'],_0x476911=_0x5c24e3['getVerticesData'](_0x212fbd['b']['PositionKind']);_0x476911||(_0x476911=[]);var _0x1ec485=_0x5c24e3['getVerticesData'](_0x212fbd['b']['NormalKind']);_0x1ec485||(_0x1ec485=[]);for(var _0x56782a,_0x121fdb,_0x449f6c,_0x140190,_0x152408,_0x4d93cc,_0x55fd44,_0x258360,_0x1db37b=_0x476911['length']/0x3,_0x1c73d1=_0x5b7f0b['physicsBody']['get_m_nodes'](),_0x1d491f=0x0;_0x1d491f<_0x1db37b;_0x1d491f++){var _0x5eda4c;_0x449f6c=(_0x121fdb=(_0x56782a=_0x1c73d1['at'](_0x1d491f))['get_m_x']())['x'](),_0x140190=_0x121fdb['y'](),_0x152408=_0x121fdb['z']()*_0x4df513,_0x4d93cc=(_0x5eda4c=_0x56782a['get_m_n']())['x'](),_0x55fd44=_0x5eda4c['y'](),_0x258360=_0x5eda4c['z']()*_0x4df513,_0x476911[0x3*_0x1d491f]=_0x449f6c,_0x476911[0x3*_0x1d491f+0x1]=_0x140190,_0x476911[0x3*_0x1d491f+0x2]=_0x152408,_0x1ec485[0x3*_0x1d491f]=_0x4d93cc,_0x1ec485[0x3*_0x1d491f+0x1]=_0x55fd44,_0x1ec485[0x3*_0x1d491f+0x2]=_0x258360;}var _0x3e0dc7=new _0xa18063['a']();_0x3e0dc7['positions']=_0x476911,_0x3e0dc7['normals']=_0x1ec485,_0x3e0dc7['uvs']=_0x5c24e3['getVerticesData'](_0x212fbd['b']['UVKind']),_0x3e0dc7['colors']=_0x5c24e3['getVerticesData'](_0x212fbd['b']['ColorKind']),_0x5c24e3&&_0x5c24e3['getIndices']&&(_0x3e0dc7['indices']=_0x5c24e3['getIndices']()),_0x3e0dc7['applyToMesh'](_0x5c24e3);},_0x5896c3['prototype']['applyImpulse']=function(_0x4a111e,_0x511ba5,_0x42a9f7){if(_0x4a111e['soft'])_0x75193d['a']['Warn']('Cannot\x20be\x20applied\x20to\x20a\x20soft\x20body');else{_0x4a111e['physicsBody']['activate']();var _0x218233=this['_tmpAmmoVectorA'],_0x460f43=this['_tmpAmmoVectorB'];_0x4a111e['object']&&_0x4a111e['object']['getWorldMatrix']&&_0x42a9f7['subtractInPlace'](_0x4a111e['object']['getWorldMatrix']()['getTranslation']()),_0x218233['setValue'](_0x42a9f7['x'],_0x42a9f7['y'],_0x42a9f7['z']),_0x460f43['setValue'](_0x511ba5['x'],_0x511ba5['y'],_0x511ba5['z']),_0x4a111e['physicsBody']['applyImpulse'](_0x460f43,_0x218233);}},_0x5896c3['prototype']['applyForce']=function(_0x593b0f,_0x23d522,_0xc8a9ce){if(_0x593b0f['soft'])_0x75193d['a']['Warn']('Cannot\x20be\x20applied\x20to\x20a\x20soft\x20body');else{_0x593b0f['physicsBody']['activate']();var _0x511104=this['_tmpAmmoVectorA'],_0x5c6783=this['_tmpAmmoVectorB'];_0x593b0f['object']&&_0x593b0f['object']['getWorldMatrix']&&_0xc8a9ce['subtractInPlace'](_0x593b0f['object']['getWorldMatrix']()['getTranslation']()),_0x511104['setValue'](_0xc8a9ce['x'],_0xc8a9ce['y'],_0xc8a9ce['z']),_0x5c6783['setValue'](_0x23d522['x'],_0x23d522['y'],_0x23d522['z']),_0x593b0f['physicsBody']['applyForce'](_0x5c6783,_0x511104);}},_0x5896c3['prototype']['generatePhysicsBody']=function(_0x3f5dd4){if(_0x3f5dd4['_pluginData']['toDispose']=[],_0x3f5dd4['parent'])_0x3f5dd4['physicsBody']&&(this['removePhysicsBody'](_0x3f5dd4),_0x3f5dd4['forceUpdate']());else{if(_0x3f5dd4['isBodyInitRequired']()){var _0x313cfc=this['_createShape'](_0x3f5dd4),_0x1fc98e=_0x3f5dd4['getParam']('mass');if(_0x3f5dd4['_pluginData']['mass']=_0x1fc98e,_0x3f5dd4['soft'])_0x313cfc['get_m_cfg']()['set_collisions'](0x11),_0x313cfc['get_m_cfg']()['set_kDP'](_0x3f5dd4['getParam']('damping')),this['bjsAMMO']['castObject'](_0x313cfc,this['bjsAMMO']['btCollisionObject'])['getCollisionShape']()['setMargin'](_0x3f5dd4['getParam']('margin')),_0x313cfc['setActivationState'](_0x5896c3['DISABLE_DEACTIVATION_FLAG']),this['world']['addSoftBody'](_0x313cfc,0x1,-0x1),_0x3f5dd4['physicsBody']=_0x313cfc,_0x3f5dd4['_pluginData']['toDispose']['push'](_0x313cfc),this['setBodyPressure'](_0x3f5dd4,0x0),_0x3f5dd4['type']===_0x3c10c7['a']['SoftbodyImpostor']&&this['setBodyPressure'](_0x3f5dd4,_0x3f5dd4['getParam']('pressure')),this['setBodyStiffness'](_0x3f5dd4,_0x3f5dd4['getParam']('stiffness')),this['setBodyVelocityIterations'](_0x3f5dd4,_0x3f5dd4['getParam']('velocityIterations')),this['setBodyPositionIterations'](_0x3f5dd4,_0x3f5dd4['getParam']('positionIterations'));else{var _0x3fcbb0=new this['bjsAMMO']['btVector3'](0x0,0x0,0x0),_0x3e8d6f=new this['bjsAMMO']['btTransform']();_0x3e8d6f['setIdentity'](),0x0!==_0x1fc98e&&_0x313cfc['calculateLocalInertia'](_0x1fc98e,_0x3fcbb0),this['_tmpAmmoVectorA']['setValue'](_0x3f5dd4['object']['position']['x'],_0x3f5dd4['object']['position']['y'],_0x3f5dd4['object']['position']['z']),this['_tmpAmmoQuaternion']['setValue'](_0x3f5dd4['object']['rotationQuaternion']['x'],_0x3f5dd4['object']['rotationQuaternion']['y'],_0x3f5dd4['object']['rotationQuaternion']['z'],_0x3f5dd4['object']['rotationQuaternion']['w']),_0x3e8d6f['setOrigin'](this['_tmpAmmoVectorA']),_0x3e8d6f['setRotation'](this['_tmpAmmoQuaternion']);var _0x2ceb54=new this['bjsAMMO']['btDefaultMotionState'](_0x3e8d6f),_0x39c385=new this['bjsAMMO']['btRigidBodyConstructionInfo'](_0x1fc98e,_0x2ceb54,_0x313cfc,_0x3fcbb0),_0xfe37a6=new this['bjsAMMO']['btRigidBody'](_0x39c385);0x0===_0x1fc98e&&(_0xfe37a6['setCollisionFlags'](_0xfe37a6['getCollisionFlags']()|_0x5896c3['KINEMATIC_FLAG']),_0xfe37a6['setActivationState'](_0x5896c3['DISABLE_DEACTIVATION_FLAG'])),_0x3f5dd4['type']!=_0x3c10c7['a']['NoImpostor']||_0x313cfc['getChildShape']||_0xfe37a6['setCollisionFlags'](_0xfe37a6['getCollisionFlags']()|_0x5896c3['DISABLE_COLLISION_FLAG']);var _0x21c7f7=_0x3f5dd4['getParam']('group'),_0xe8042c=_0x3f5dd4['getParam']('mask');_0x21c7f7&&_0xe8042c?this['world']['addRigidBody'](_0xfe37a6,_0x21c7f7,_0xe8042c):this['world']['addRigidBody'](_0xfe37a6),_0x3f5dd4['physicsBody']=_0xfe37a6,_0x3f5dd4['_pluginData']['toDispose']=_0x3f5dd4['_pluginData']['toDispose']['concat']([_0xfe37a6,_0x39c385,_0x2ceb54,_0x3e8d6f,_0x3fcbb0,_0x313cfc]);}this['setBodyRestitution'](_0x3f5dd4,_0x3f5dd4['getParam']('restitution')),this['setBodyFriction'](_0x3f5dd4,_0x3f5dd4['getParam']('friction'));}}},_0x5896c3['prototype']['removePhysicsBody']=function(_0x4a1699){var _0x59b130=this;this['world']&&(_0x4a1699['soft']?this['world']['removeSoftBody'](_0x4a1699['physicsBody']):this['world']['removeRigidBody'](_0x4a1699['physicsBody']),_0x4a1699['_pluginData']&&(_0x4a1699['_pluginData']['toDispose']['forEach'](function(_0x3dc7a7){_0x59b130['bjsAMMO']['destroy'](_0x3dc7a7);}),_0x4a1699['_pluginData']['toDispose']=[]));},_0x5896c3['prototype']['generateJoint']=function(_0x5b2449){var _0xfd64fa=_0x5b2449['mainImpostor']['physicsBody'],_0x388547=_0x5b2449['connectedImpostor']['physicsBody'];if(_0xfd64fa&&_0x388547){var _0x4cd7e,_0x27fc40=_0x5b2449['joint']['jointData'];switch(_0x27fc40['mainPivot']||(_0x27fc40['mainPivot']=new _0x74d525['e'](0x0,0x0,0x0)),_0x27fc40['connectedPivot']||(_0x27fc40['connectedPivot']=new _0x74d525['e'](0x0,0x0,0x0)),_0x5b2449['joint']['type']){case _0x288b05['e']['DistanceJoint']:var _0xb36da=_0x27fc40['maxDistance'];_0xb36da&&(_0x27fc40['mainPivot']=new _0x74d525['e'](0x0,-_0xb36da/0x2,0x0),_0x27fc40['connectedPivot']=new _0x74d525['e'](0x0,_0xb36da/0x2,0x0)),_0x4cd7e=new this['bjsAMMO']['btPoint2PointConstraint'](_0xfd64fa,_0x388547,new this['bjsAMMO']['btVector3'](_0x27fc40['mainPivot']['x'],_0x27fc40['mainPivot']['y'],_0x27fc40['mainPivot']['z']),new this['bjsAMMO']['btVector3'](_0x27fc40['connectedPivot']['x'],_0x27fc40['connectedPivot']['y'],_0x27fc40['connectedPivot']['z']));break;case _0x288b05['e']['HingeJoint']:_0x27fc40['mainAxis']||(_0x27fc40['mainAxis']=new _0x74d525['e'](0x0,0x0,0x0)),_0x27fc40['connectedAxis']||(_0x27fc40['connectedAxis']=new _0x74d525['e'](0x0,0x0,0x0));var _0x35008c=new this['bjsAMMO']['btVector3'](_0x27fc40['mainAxis']['x'],_0x27fc40['mainAxis']['y'],_0x27fc40['mainAxis']['z']),_0x19280e=new this['bjsAMMO']['btVector3'](_0x27fc40['connectedAxis']['x'],_0x27fc40['connectedAxis']['y'],_0x27fc40['connectedAxis']['z']);_0x4cd7e=new this['bjsAMMO']['btHingeConstraint'](_0xfd64fa,_0x388547,new this['bjsAMMO']['btVector3'](_0x27fc40['mainPivot']['x'],_0x27fc40['mainPivot']['y'],_0x27fc40['mainPivot']['z']),new this['bjsAMMO']['btVector3'](_0x27fc40['connectedPivot']['x'],_0x27fc40['connectedPivot']['y'],_0x27fc40['connectedPivot']['z']),_0x35008c,_0x19280e);break;case _0x288b05['e']['BallAndSocketJoint']:_0x4cd7e=new this['bjsAMMO']['btPoint2PointConstraint'](_0xfd64fa,_0x388547,new this['bjsAMMO']['btVector3'](_0x27fc40['mainPivot']['x'],_0x27fc40['mainPivot']['y'],_0x27fc40['mainPivot']['z']),new this['bjsAMMO']['btVector3'](_0x27fc40['connectedPivot']['x'],_0x27fc40['connectedPivot']['y'],_0x27fc40['connectedPivot']['z']));break;default:_0x75193d['a']['Warn']('JointType\x20not\x20currently\x20supported\x20by\x20the\x20Ammo\x20plugin,\x20falling\x20back\x20to\x20PhysicsJoint.BallAndSocketJoint'),_0x4cd7e=new this['bjsAMMO']['btPoint2PointConstraint'](_0xfd64fa,_0x388547,new this['bjsAMMO']['btVector3'](_0x27fc40['mainPivot']['x'],_0x27fc40['mainPivot']['y'],_0x27fc40['mainPivot']['z']),new this['bjsAMMO']['btVector3'](_0x27fc40['connectedPivot']['x'],_0x27fc40['connectedPivot']['y'],_0x27fc40['connectedPivot']['z']));}this['world']['addConstraint'](_0x4cd7e,!_0x5b2449['joint']['jointData']['collision']),_0x5b2449['joint']['physicsJoint']=_0x4cd7e;}},_0x5896c3['prototype']['removeJoint']=function(_0x1ae83c){this['world']&&this['world']['removeConstraint'](_0x1ae83c['joint']['physicsJoint']);},_0x5896c3['prototype']['_addMeshVerts']=function(_0x4fd058,_0x39c932,_0x29779){var _0x137b12=this,_0x767ff6=0x0;if(_0x29779&&_0x29779['getIndices']&&_0x29779['getWorldMatrix']&&_0x29779['getChildMeshes']){var _0x34f7b0=_0x29779['getIndices']();_0x34f7b0||(_0x34f7b0=[]);var _0x3121a4=_0x29779['getVerticesData'](_0x212fbd['b']['PositionKind']);_0x3121a4||(_0x3121a4=[]),_0x29779['computeWorldMatrix'](!0x1);for(var _0x8fec41=_0x34f7b0['length']/0x3,_0x25e252=0x0;_0x25e252<_0x8fec41;_0x25e252++){for(var _0x56a51b=[],_0x5f33a2=0x0;_0x5f33a2<0x3;_0x5f33a2++){var _0x3ab3b0,_0x3aaec4=new _0x74d525['e'](_0x3121a4[0x3*_0x34f7b0[0x3*_0x25e252+_0x5f33a2]+0x0],_0x3121a4[0x3*_0x34f7b0[0x3*_0x25e252+_0x5f33a2]+0x1],_0x3121a4[0x3*_0x34f7b0[0x3*_0x25e252+_0x5f33a2]+0x2]);_0x74d525['a']['ScalingToRef'](_0x29779['scaling']['x'],_0x29779['scaling']['y'],_0x29779['scaling']['z'],this['_tmpMatrix']),_0x3aaec4=_0x74d525['e']['TransformCoordinates'](_0x3aaec4,this['_tmpMatrix']),(_0x3ab3b0=0x0==_0x5f33a2?this['_tmpAmmoVectorA']:0x1==_0x5f33a2?this['_tmpAmmoVectorB']:this['_tmpAmmoVectorC'])['setValue'](_0x3aaec4['x'],_0x3aaec4['y'],_0x3aaec4['z']),_0x56a51b['push'](_0x3ab3b0);}_0x4fd058['addTriangle'](_0x56a51b[0x0],_0x56a51b[0x1],_0x56a51b[0x2]),_0x767ff6++;}_0x29779['getChildMeshes']()['forEach'](function(_0x10b3be){_0x767ff6+=_0x137b12['_addMeshVerts'](_0x4fd058,_0x39c932,_0x10b3be);});}return _0x767ff6;},_0x5896c3['prototype']['_softVertexData']=function(_0x37a1ea){var _0x188576=_0x37a1ea['object'];if(_0x188576&&_0x188576['getIndices']&&_0x188576['getWorldMatrix']&&_0x188576['getChildMeshes']){var _0x71eb75=_0x188576['getIndices']();_0x71eb75||(_0x71eb75=[]);var _0x249b8c=_0x188576['getVerticesData'](_0x212fbd['b']['PositionKind']);_0x249b8c||(_0x249b8c=[]);var _0x133931=_0x188576['getVerticesData'](_0x212fbd['b']['NormalKind']);_0x133931||(_0x133931=[]),_0x188576['computeWorldMatrix'](!0x1);for(var _0x3949aa=[],_0x42668a=[],_0x1bf3f6=0x0;_0x1bf3f6<_0x249b8c['length'];_0x1bf3f6+=0x3){var _0x9d8017=new _0x74d525['e'](_0x249b8c[_0x1bf3f6],_0x249b8c[_0x1bf3f6+0x1],_0x249b8c[_0x1bf3f6+0x2]),_0xc57d0c=new _0x74d525['e'](_0x133931[_0x1bf3f6],_0x133931[_0x1bf3f6+0x1],_0x133931[_0x1bf3f6+0x2]);_0x9d8017=_0x74d525['e']['TransformCoordinates'](_0x9d8017,_0x188576['getWorldMatrix']()),_0xc57d0c=_0x74d525['e']['TransformNormal'](_0xc57d0c,_0x188576['getWorldMatrix']()),_0x3949aa['push'](_0x9d8017['x'],_0x9d8017['y'],_0x9d8017['z']),_0x42668a['push'](_0xc57d0c['x'],_0xc57d0c['y'],_0xc57d0c['z']);}var _0x47e2cc=new _0xa18063['a']();return _0x47e2cc['positions']=_0x3949aa,_0x47e2cc['normals']=_0x42668a,_0x47e2cc['uvs']=_0x188576['getVerticesData'](_0x212fbd['b']['UVKind']),_0x47e2cc['colors']=_0x188576['getVerticesData'](_0x212fbd['b']['ColorKind']),_0x188576&&_0x188576['getIndices']&&(_0x47e2cc['indices']=_0x188576['getIndices']()),_0x47e2cc['applyToMesh'](_0x188576),_0x188576['position']=_0x74d525['e']['Zero'](),_0x188576['rotationQuaternion']=null,_0x188576['rotation']=_0x74d525['e']['Zero'](),_0x188576['computeWorldMatrix'](!0x0),_0x47e2cc;}return _0xa18063['a']['ExtractFromMesh'](_0x188576);},_0x5896c3['prototype']['_createSoftbody']=function(_0x2e79cf){var _0x957324=_0x2e79cf['object'];if(_0x957324&&_0x957324['getIndices']){var _0x26c8c9=_0x957324['getIndices']();_0x26c8c9||(_0x26c8c9=[]);var _0x14743f=this['_softVertexData'](_0x2e79cf),_0x232850=_0x14743f['positions'],_0x109772=_0x14743f['normals'];if(null===_0x232850||null===_0x109772)return new this['bjsAMMO']['btCompoundShape']();for(var _0x571c25=[],_0x4056a7=[],_0x51de33=0x0;_0x51de33<_0x232850['length'];_0x51de33+=0x3){var _0x2c68b8=new _0x74d525['e'](_0x232850[_0x51de33],_0x232850[_0x51de33+0x1],_0x232850[_0x51de33+0x2]),_0x56709e=new _0x74d525['e'](_0x109772[_0x51de33],_0x109772[_0x51de33+0x1],_0x109772[_0x51de33+0x2]);_0x571c25['push'](_0x2c68b8['x'],_0x2c68b8['y'],-_0x2c68b8['z']),_0x4056a7['push'](_0x56709e['x'],_0x56709e['y'],-_0x56709e['z']);}var _0x35499d=new this['bjsAMMO']['btSoftBodyHelpers']()['CreateFromTriMesh'](this['world']['getWorldInfo'](),_0x571c25,_0x957324['getIndices'](),_0x26c8c9['length']/0x3,!0x0),_0x2bf587=_0x232850['length']/0x3,_0x1851c7=_0x35499d['get_m_nodes']();for(_0x51de33=0x0;_0x51de33<_0x2bf587;_0x51de33++){var _0x19aab0;(_0x19aab0=_0x1851c7['at'](_0x51de33)['get_m_n']())['setX'](_0x4056a7[0x3*_0x51de33]),_0x19aab0['setY'](_0x4056a7[0x3*_0x51de33+0x1]),_0x19aab0['setZ'](_0x4056a7[0x3*_0x51de33+0x2]);}return _0x35499d;}},_0x5896c3['prototype']['_createCloth']=function(_0x2b5ac2){var _0x1dd534=_0x2b5ac2['object'];if(_0x1dd534&&_0x1dd534['getIndices']){var _0x135471=_0x1dd534['getIndices']();_0x135471||(_0x135471=[]);var _0x26ff92=this['_softVertexData'](_0x2b5ac2),_0x2492d5=_0x26ff92['positions'],_0x3a5d5c=_0x26ff92['normals'];if(null===_0x2492d5||null===_0x3a5d5c)return new this['bjsAMMO']['btCompoundShape']();var _0x5e9305=_0x2492d5['length'],_0x4d63f5=Math['sqrt'](_0x5e9305/0x3);_0x2b5ac2['segments']=_0x4d63f5;var _0x2e3e58=_0x4d63f5-0x1;return this['_tmpAmmoVectorA']['setValue'](_0x2492d5[0x0],_0x2492d5[0x1],_0x2492d5[0x2]),this['_tmpAmmoVectorB']['setValue'](_0x2492d5[0x3*_0x2e3e58],_0x2492d5[0x3*_0x2e3e58+0x1],_0x2492d5[0x3*_0x2e3e58+0x2]),this['_tmpAmmoVectorD']['setValue'](_0x2492d5[_0x5e9305-0x3],_0x2492d5[_0x5e9305-0x2],_0x2492d5[_0x5e9305-0x1]),this['_tmpAmmoVectorC']['setValue'](_0x2492d5[_0x5e9305-0x3-0x3*_0x2e3e58],_0x2492d5[_0x5e9305-0x2-0x3*_0x2e3e58],_0x2492d5[_0x5e9305-0x1-0x3*_0x2e3e58]),new this['bjsAMMO']['btSoftBodyHelpers']()['CreatePatch'](this['world']['getWorldInfo'](),this['_tmpAmmoVectorA'],this['_tmpAmmoVectorB'],this['_tmpAmmoVectorC'],this['_tmpAmmoVectorD'],_0x4d63f5,_0x4d63f5,_0x2b5ac2['getParam']('fixedPoints'),!0x0);}},_0x5896c3['prototype']['_createRope']=function(_0x731ef4){var _0x34b619,_0x1a7aae,_0x3afa17=this['_softVertexData'](_0x731ef4),_0x2ec409=_0x3afa17['positions'],_0x265f2d=_0x3afa17['normals'];if(null===_0x2ec409||null===_0x265f2d)return new this['bjsAMMO']['btCompoundShape']();_0x3afa17['applyToMesh'](_0x731ef4['object'],!0x0),_0x731ef4['_isFromLine']=!0x0;if(0x0===_0x265f2d['map'](function(_0x4adfe7){return _0x4adfe7*_0x4adfe7;})['reduce'](function(_0x57b662,_0x2ee311){return _0x57b662+_0x2ee311;}))_0x1a7aae=(_0x34b619=_0x2ec409['length'])/0x3-0x1,this['_tmpAmmoVectorA']['setValue'](_0x2ec409[0x0],_0x2ec409[0x1],_0x2ec409[0x2]),this['_tmpAmmoVectorB']['setValue'](_0x2ec409[_0x34b619-0x3],_0x2ec409[_0x34b619-0x2],_0x2ec409[_0x34b619-0x1]);else{_0x731ef4['_isFromLine']=!0x1;var _0x872fa5=_0x731ef4['getParam']('path');if(null===_0x731ef4['getParam']('shape'))return _0x75193d['a']['Warn']('No\x20shape\x20available\x20for\x20extruded\x20mesh'),new this['bjsAMMO']['btCompoundShape']();if(_0x2ec409['length']%(0x3*_0x872fa5['length'])!=0x0)return _0x75193d['a']['Warn']('Path\x20does\x20not\x20match\x20extrusion'),new this['bjsAMMO']['btCompoundShape']();_0x1a7aae=(_0x34b619=_0x872fa5['length'])-0x1,this['_tmpAmmoVectorA']['setValue'](_0x872fa5[0x0]['x'],_0x872fa5[0x0]['y'],_0x872fa5[0x0]['z']),this['_tmpAmmoVectorB']['setValue'](_0x872fa5[_0x34b619-0x1]['x'],_0x872fa5[_0x34b619-0x1]['y'],_0x872fa5[_0x34b619-0x1]['z']);}_0x731ef4['segments']=_0x1a7aae;var _0x325cbc=_0x731ef4['getParam']('fixedPoints');_0x325cbc=_0x325cbc>0x3?0x3:_0x325cbc;var _0x19b151=new this['bjsAMMO']['btSoftBodyHelpers']()['CreateRope'](this['world']['getWorldInfo'](),this['_tmpAmmoVectorA'],this['_tmpAmmoVectorB'],_0x1a7aae-0x1,_0x325cbc);return _0x19b151['get_m_cfg']()['set_collisions'](0x11),_0x19b151;},_0x5896c3['prototype']['_createCustom']=function(_0x5c1c2a){var _0x460aaa=null;return this['onCreateCustomShape']&&(_0x460aaa=this['onCreateCustomShape'](_0x5c1c2a)),null==_0x460aaa&&(_0x460aaa=new this['bjsAMMO']['btCompoundShape']()),_0x460aaa;},_0x5896c3['prototype']['_addHullVerts']=function(_0x25f4c1,_0x3412ab,_0x5f4512){var _0x28886b=this,_0x5d51ba=0x0;if(_0x5f4512&&_0x5f4512['getIndices']&&_0x5f4512['getWorldMatrix']&&_0x5f4512['getChildMeshes']){var _0x1688c6=_0x5f4512['getIndices']();_0x1688c6||(_0x1688c6=[]);var _0x235ddd=_0x5f4512['getVerticesData'](_0x212fbd['b']['PositionKind']);_0x235ddd||(_0x235ddd=[]),_0x5f4512['computeWorldMatrix'](!0x1);for(var _0x12a309=_0x1688c6['length']/0x3,_0x4ec0da=0x0;_0x4ec0da<_0x12a309;_0x4ec0da++){for(var _0x2f2741=[],_0xb1cb8d=0x0;_0xb1cb8d<0x3;_0xb1cb8d++){var _0x43bffe,_0x40e2a1=new _0x74d525['e'](_0x235ddd[0x3*_0x1688c6[0x3*_0x4ec0da+_0xb1cb8d]+0x0],_0x235ddd[0x3*_0x1688c6[0x3*_0x4ec0da+_0xb1cb8d]+0x1],_0x235ddd[0x3*_0x1688c6[0x3*_0x4ec0da+_0xb1cb8d]+0x2]);_0x74d525['a']['ScalingToRef'](_0x5f4512['scaling']['x'],_0x5f4512['scaling']['y'],_0x5f4512['scaling']['z'],this['_tmpMatrix']),_0x40e2a1=_0x74d525['e']['TransformCoordinates'](_0x40e2a1,this['_tmpMatrix']),(_0x43bffe=0x0==_0xb1cb8d?this['_tmpAmmoVectorA']:0x1==_0xb1cb8d?this['_tmpAmmoVectorB']:this['_tmpAmmoVectorC'])['setValue'](_0x40e2a1['x'],_0x40e2a1['y'],_0x40e2a1['z']),_0x2f2741['push'](_0x43bffe);}_0x25f4c1['addPoint'](_0x2f2741[0x0],!0x0),_0x25f4c1['addPoint'](_0x2f2741[0x1],!0x0),_0x25f4c1['addPoint'](_0x2f2741[0x2],!0x0),_0x5d51ba++;}_0x5f4512['getChildMeshes']()['forEach'](function(_0x186068){_0x5d51ba+=_0x28886b['_addHullVerts'](_0x25f4c1,_0x3412ab,_0x186068);});}return _0x5d51ba;},_0x5896c3['prototype']['_createShape']=function(_0x3483aa,_0x1656fa){var _0x486694=this;void 0x0===_0x1656fa&&(_0x1656fa=!0x1);var _0x181f29,_0x61688f=_0x3483aa['object'],_0x528863=_0x3483aa['getObjectExtendSize']();if(!_0x1656fa){var _0x3f6299=_0x3483aa['object']['getChildMeshes']?_0x3483aa['object']['getChildMeshes'](!0x0):[];_0x181f29=new this['bjsAMMO']['btCompoundShape']();var _0xcc9c9=0x0;if(_0x3f6299['forEach'](function(_0x15b265){var _0x3889ee=_0x15b265['getPhysicsImpostor']();if(_0x3889ee){if(_0x3889ee['type']==_0x3c10c7['a']['MeshImpostor'])throw'A\x20child\x20MeshImpostor\x20is\x20not\x20supported.\x20Only\x20primitive\x20impostors\x20are\x20supported\x20as\x20children\x20(eg.\x20box\x20or\x20sphere)';var _0x791d0a=_0x486694['_createShape'](_0x3889ee),_0x747934=_0x15b265['parent']['getWorldMatrix']()['clone'](),_0x5ecd55=new _0x74d525['e']();_0x747934['decompose'](_0x5ecd55),_0x486694['_tmpAmmoTransform']['getOrigin']()['setValue'](_0x15b265['position']['x']*_0x5ecd55['x'],_0x15b265['position']['y']*_0x5ecd55['y'],_0x15b265['position']['z']*_0x5ecd55['z']),_0x486694['_tmpAmmoQuaternion']['setValue'](_0x15b265['rotationQuaternion']['x'],_0x15b265['rotationQuaternion']['y'],_0x15b265['rotationQuaternion']['z'],_0x15b265['rotationQuaternion']['w']),_0x486694['_tmpAmmoTransform']['setRotation'](_0x486694['_tmpAmmoQuaternion']),_0x181f29['addChildShape'](_0x486694['_tmpAmmoTransform'],_0x791d0a),_0x3889ee['dispose'](),_0xcc9c9++;}}),_0xcc9c9>0x0){if(_0x3483aa['type']!=_0x3c10c7['a']['NoImpostor']){var _0x3e3fea=this['_createShape'](_0x3483aa,!0x0);_0x3e3fea&&(this['_tmpAmmoTransform']['getOrigin']()['setValue'](0x0,0x0,0x0),this['_tmpAmmoQuaternion']['setValue'](0x0,0x0,0x0,0x1),this['_tmpAmmoTransform']['setRotation'](this['_tmpAmmoQuaternion']),_0x181f29['addChildShape'](this['_tmpAmmoTransform'],_0x3e3fea));}return _0x181f29;}this['bjsAMMO']['destroy'](_0x181f29),_0x181f29=null;}switch(_0x3483aa['type']){case _0x3c10c7['a']['SphereImpostor']:if(_0x4a0cf0['a']['WithinEpsilon'](_0x528863['x'],_0x528863['y'],0.0001)&&_0x4a0cf0['a']['WithinEpsilon'](_0x528863['x'],_0x528863['z'],0.0001))_0x181f29=new this['bjsAMMO']['btSphereShape'](_0x528863['x']/0x2);else{var _0x5d708b=[new this['bjsAMMO']['btVector3'](0x0,0x0,0x0)];(_0x181f29=new this['bjsAMMO']['btMultiSphereShape'](_0x5d708b,[0x1],0x1))['setLocalScaling'](new this['bjsAMMO']['btVector3'](_0x528863['x']/0x2,_0x528863['y']/0x2,_0x528863['z']/0x2));}break;case _0x3c10c7['a']['CapsuleImpostor']:_0x181f29=new this['bjsAMMO']['btCapsuleShape'](_0x528863['x']/0x2,_0x528863['y']/0x2);break;case _0x3c10c7['a']['CylinderImpostor']:this['_tmpAmmoVectorA']['setValue'](_0x528863['x']/0x2,_0x528863['y']/0x2,_0x528863['z']/0x2),_0x181f29=new this['bjsAMMO']['btCylinderShape'](this['_tmpAmmoVectorA']);break;case _0x3c10c7['a']['PlaneImpostor']:case _0x3c10c7['a']['BoxImpostor']:this['_tmpAmmoVectorA']['setValue'](_0x528863['x']/0x2,_0x528863['y']/0x2,_0x528863['z']/0x2),_0x181f29=new this['bjsAMMO']['btBoxShape'](this['_tmpAmmoVectorA']);break;case _0x3c10c7['a']['MeshImpostor']:if(0x0==_0x3483aa['getParam']('mass')){var _0x57599c=new this['bjsAMMO']['btTriangleMesh']();_0x3483aa['_pluginData']['toDispose']['push'](_0x57599c);var _0x3e8e3=this['_addMeshVerts'](_0x57599c,_0x61688f,_0x61688f);_0x181f29=0x0==_0x3e8e3?new this['bjsAMMO']['btCompoundShape']():new this['bjsAMMO']['btBvhTriangleMeshShape'](_0x57599c);break;}case _0x3c10c7['a']['ConvexHullImpostor']:var _0x195624=new this['bjsAMMO']['btConvexHullShape']();0x0==(_0x3e8e3=this['_addHullVerts'](_0x195624,_0x61688f,_0x61688f))?(_0x3483aa['_pluginData']['toDispose']['push'](_0x195624),_0x181f29=new this['bjsAMMO']['btCompoundShape']()):_0x181f29=_0x195624;break;case _0x3c10c7['a']['NoImpostor']:_0x181f29=new this['bjsAMMO']['btSphereShape'](_0x528863['x']/0x2);break;case _0x3c10c7['a']['CustomImpostor']:_0x181f29=this['_createCustom'](_0x3483aa);break;case _0x3c10c7['a']['SoftbodyImpostor']:_0x181f29=this['_createSoftbody'](_0x3483aa);break;case _0x3c10c7['a']['ClothImpostor']:_0x181f29=this['_createCloth'](_0x3483aa);break;case _0x3c10c7['a']['RopeImpostor']:_0x181f29=this['_createRope'](_0x3483aa);break;default:_0x75193d['a']['Warn']('The\x20impostor\x20type\x20is\x20not\x20currently\x20supported\x20by\x20the\x20ammo\x20plugin.');}return _0x181f29;},_0x5896c3['prototype']['setTransformationFromPhysicsBody']=function(_0x5effaf){_0x5effaf['physicsBody']['getMotionState']()['getWorldTransform'](this['_tmpAmmoTransform']),_0x5effaf['object']['position']['set'](this['_tmpAmmoTransform']['getOrigin']()['x'](),this['_tmpAmmoTransform']['getOrigin']()['y'](),this['_tmpAmmoTransform']['getOrigin']()['z']()),_0x5effaf['object']['rotationQuaternion']?_0x5effaf['object']['rotationQuaternion']['set'](this['_tmpAmmoTransform']['getRotation']()['x'](),this['_tmpAmmoTransform']['getRotation']()['y'](),this['_tmpAmmoTransform']['getRotation']()['z'](),this['_tmpAmmoTransform']['getRotation']()['w']()):_0x5effaf['object']['rotation']&&(this['_tmpQuaternion']['set'](this['_tmpAmmoTransform']['getRotation']()['x'](),this['_tmpAmmoTransform']['getRotation']()['y'](),this['_tmpAmmoTransform']['getRotation']()['z'](),this['_tmpAmmoTransform']['getRotation']()['w']()),this['_tmpQuaternion']['toEulerAnglesToRef'](_0x5effaf['object']['rotation']));},_0x5896c3['prototype']['setPhysicsBodyTransformation']=function(_0x4ab34c,_0x6ee611,_0x51d3c5){var _0x393ad3=_0x4ab34c['physicsBody']['getWorldTransform']();if(Math['abs'](_0x393ad3['getOrigin']()['x']()-_0x6ee611['x'])>_0x27da6e['a']||Math['abs'](_0x393ad3['getOrigin']()['y']()-_0x6ee611['y'])>_0x27da6e['a']||Math['abs'](_0x393ad3['getOrigin']()['z']()-_0x6ee611['z'])>_0x27da6e['a']||Math['abs'](_0x393ad3['getRotation']()['x']()-_0x51d3c5['x'])>_0x27da6e['a']||Math['abs'](_0x393ad3['getRotation']()['y']()-_0x51d3c5['y'])>_0x27da6e['a']||Math['abs'](_0x393ad3['getRotation']()['z']()-_0x51d3c5['z'])>_0x27da6e['a']||Math['abs'](_0x393ad3['getRotation']()['w']()-_0x51d3c5['w'])>_0x27da6e['a']){if(this['_tmpAmmoVectorA']['setValue'](_0x6ee611['x'],_0x6ee611['y'],_0x6ee611['z']),_0x393ad3['setOrigin'](this['_tmpAmmoVectorA']),this['_tmpAmmoQuaternion']['setValue'](_0x51d3c5['x'],_0x51d3c5['y'],_0x51d3c5['z'],_0x51d3c5['w']),_0x393ad3['setRotation'](this['_tmpAmmoQuaternion']),_0x4ab34c['physicsBody']['setWorldTransform'](_0x393ad3),0x0==_0x4ab34c['mass']){var _0x1be05c=_0x4ab34c['physicsBody']['getMotionState']();_0x1be05c&&_0x1be05c['setWorldTransform'](_0x393ad3);}else _0x4ab34c['physicsBody']['activate']();}},_0x5896c3['prototype']['isSupported']=function(){return void 0x0!==this['bjsAMMO'];},_0x5896c3['prototype']['setLinearVelocity']=function(_0x3584a1,_0x51794e){this['_tmpAmmoVectorA']['setValue'](_0x51794e['x'],_0x51794e['y'],_0x51794e['z']),_0x3584a1['soft']?_0x3584a1['physicsBody']['linearVelocity'](this['_tmpAmmoVectorA']):_0x3584a1['physicsBody']['setLinearVelocity'](this['_tmpAmmoVectorA']);},_0x5896c3['prototype']['setAngularVelocity']=function(_0x31e841,_0x29c4e3){this['_tmpAmmoVectorA']['setValue'](_0x29c4e3['x'],_0x29c4e3['y'],_0x29c4e3['z']),_0x31e841['soft']?_0x31e841['physicsBody']['angularVelocity'](this['_tmpAmmoVectorA']):_0x31e841['physicsBody']['setAngularVelocity'](this['_tmpAmmoVectorA']);},_0x5896c3['prototype']['getLinearVelocity']=function(_0x11b879){if(_0x11b879['soft'])var _0x1d9ee7=_0x11b879['physicsBody']['linearVelocity']();else _0x1d9ee7=_0x11b879['physicsBody']['getLinearVelocity']();if(!_0x1d9ee7)return null;var _0x35c558=new _0x74d525['e'](_0x1d9ee7['x'](),_0x1d9ee7['y'](),_0x1d9ee7['z']());return this['bjsAMMO']['destroy'](_0x1d9ee7),_0x35c558;},_0x5896c3['prototype']['getAngularVelocity']=function(_0x53e07f){if(_0x53e07f['soft'])var _0x451f45=_0x53e07f['physicsBody']['angularVelocity']();else _0x451f45=_0x53e07f['physicsBody']['getAngularVelocity']();if(!_0x451f45)return null;var _0x1c2413=new _0x74d525['e'](_0x451f45['x'](),_0x451f45['y'](),_0x451f45['z']());return this['bjsAMMO']['destroy'](_0x451f45),_0x1c2413;},_0x5896c3['prototype']['setBodyMass']=function(_0x157ac3,_0x2feac1){_0x157ac3['soft']?_0x157ac3['physicsBody']['setTotalMass'](_0x2feac1,!0x1):_0x157ac3['physicsBody']['setMassProps'](_0x2feac1),_0x157ac3['_pluginData']['mass']=_0x2feac1;},_0x5896c3['prototype']['getBodyMass']=function(_0x4ea217){return _0x4ea217['_pluginData']['mass']||0x0;},_0x5896c3['prototype']['getBodyFriction']=function(_0x4e4220){return _0x4e4220['_pluginData']['friction']||0x0;},_0x5896c3['prototype']['setBodyFriction']=function(_0x2124f3,_0x435dae){_0x2124f3['soft']?_0x2124f3['physicsBody']['get_m_cfg']()['set_kDF'](_0x435dae):_0x2124f3['physicsBody']['setFriction'](_0x435dae),_0x2124f3['_pluginData']['friction']=_0x435dae;},_0x5896c3['prototype']['getBodyRestitution']=function(_0x5c637d){return _0x5c637d['_pluginData']['restitution']||0x0;},_0x5896c3['prototype']['setBodyRestitution']=function(_0x47b856,_0x4add41){_0x47b856['physicsBody']['setRestitution'](_0x4add41),_0x47b856['_pluginData']['restitution']=_0x4add41;},_0x5896c3['prototype']['getBodyPressure']=function(_0xe734){return _0xe734['soft']?_0xe734['_pluginData']['pressure']||0x0:(_0x75193d['a']['Warn']('Pressure\x20is\x20not\x20a\x20property\x20of\x20a\x20rigid\x20body'),0x0);},_0x5896c3['prototype']['setBodyPressure']=function(_0x2d096f,_0x35c385){_0x2d096f['soft']?_0x2d096f['type']===_0x3c10c7['a']['SoftbodyImpostor']?(_0x2d096f['physicsBody']['get_m_cfg']()['set_kPR'](_0x35c385),_0x2d096f['_pluginData']['pressure']=_0x35c385):(_0x2d096f['physicsBody']['get_m_cfg']()['set_kPR'](0x0),_0x2d096f['_pluginData']['pressure']=0x0):_0x75193d['a']['Warn']('Pressure\x20can\x20only\x20be\x20applied\x20to\x20a\x20softbody');},_0x5896c3['prototype']['getBodyStiffness']=function(_0x164b20){return _0x164b20['soft']?_0x164b20['_pluginData']['stiffness']||0x0:(_0x75193d['a']['Warn']('Stiffness\x20is\x20not\x20a\x20property\x20of\x20a\x20rigid\x20body'),0x0);},_0x5896c3['prototype']['setBodyStiffness']=function(_0x298946,_0x21e687){_0x298946['soft']?(_0x21e687=(_0x21e687=_0x21e687<0x0?0x0:_0x21e687)>0x1?0x1:_0x21e687,_0x298946['physicsBody']['get_m_materials']()['at'](0x0)['set_m_kLST'](_0x21e687),_0x298946['_pluginData']['stiffness']=_0x21e687):_0x75193d['a']['Warn']('Stiffness\x20cannot\x20be\x20applied\x20to\x20a\x20rigid\x20body');},_0x5896c3['prototype']['getBodyVelocityIterations']=function(_0x3b48ee){return _0x3b48ee['soft']?_0x3b48ee['_pluginData']['velocityIterations']||0x0:(_0x75193d['a']['Warn']('Velocity\x20iterations\x20is\x20not\x20a\x20property\x20of\x20a\x20rigid\x20body'),0x0);},_0x5896c3['prototype']['setBodyVelocityIterations']=function(_0x428623,_0x1bd0bf){_0x428623['soft']?(_0x1bd0bf=_0x1bd0bf<0x0?0x0:_0x1bd0bf,_0x428623['physicsBody']['get_m_cfg']()['set_viterations'](_0x1bd0bf),_0x428623['_pluginData']['velocityIterations']=_0x1bd0bf):_0x75193d['a']['Warn']('Velocity\x20iterations\x20cannot\x20be\x20applied\x20to\x20a\x20rigid\x20body');},_0x5896c3['prototype']['getBodyPositionIterations']=function(_0x308f12){return _0x308f12['soft']?_0x308f12['_pluginData']['positionIterations']||0x0:(_0x75193d['a']['Warn']('Position\x20iterations\x20is\x20not\x20a\x20property\x20of\x20a\x20rigid\x20body'),0x0);},_0x5896c3['prototype']['setBodyPositionIterations']=function(_0x1c6195,_0x1968bb){_0x1c6195['soft']?(_0x1968bb=_0x1968bb<0x0?0x0:_0x1968bb,_0x1c6195['physicsBody']['get_m_cfg']()['set_piterations'](_0x1968bb),_0x1c6195['_pluginData']['positionIterations']=_0x1968bb):_0x75193d['a']['Warn']('Position\x20iterations\x20cannot\x20be\x20applied\x20to\x20a\x20rigid\x20body');},_0x5896c3['prototype']['appendAnchor']=function(_0x2b0f0d,_0x156eaf,_0x50f1d3,_0xb9b85,_0x54c67c,_0xe43f87){void 0x0===_0x54c67c&&(_0x54c67c=0x1),void 0x0===_0xe43f87&&(_0xe43f87=!0x1);var _0x1df2dc=_0x2b0f0d['segments'],_0x25547b=Math['round']((_0x1df2dc-0x1)*_0x50f1d3)+_0x1df2dc*(_0x1df2dc-0x1-Math['round']((_0x1df2dc-0x1)*_0xb9b85));_0x2b0f0d['physicsBody']['appendAnchor'](_0x25547b,_0x156eaf['physicsBody'],_0xe43f87,_0x54c67c);},_0x5896c3['prototype']['appendHook']=function(_0x55a686,_0x352124,_0x1c4c52,_0x59b2f2,_0xe65f95){void 0x0===_0x59b2f2&&(_0x59b2f2=0x1),void 0x0===_0xe65f95&&(_0xe65f95=!0x1);var _0x344578=Math['round'](_0x55a686['segments']*_0x1c4c52);_0x55a686['physicsBody']['appendAnchor'](_0x344578,_0x352124['physicsBody'],_0xe65f95,_0x59b2f2);},_0x5896c3['prototype']['sleepBody']=function(_0x34da20){_0x75193d['a']['Warn']('sleepBody\x20is\x20not\x20currently\x20supported\x20by\x20the\x20Ammo\x20physics\x20plugin');},_0x5896c3['prototype']['wakeUpBody']=function(_0x4932ff){_0x4932ff['physicsBody']['activate']();},_0x5896c3['prototype']['updateDistanceJoint']=function(_0xc65f88,_0x4012bc,_0x3669f4){_0x75193d['a']['Warn']('updateDistanceJoint\x20is\x20not\x20currently\x20supported\x20by\x20the\x20Ammo\x20physics\x20plugin');},_0x5896c3['prototype']['setMotor']=function(_0x4ce962,_0x2ddc9b,_0x17bd0d,_0x59bb8a){_0x4ce962['physicsJoint']['enableAngularMotor'](!0x0,_0x2ddc9b,_0x17bd0d);},_0x5896c3['prototype']['setLimit']=function(_0x428c37,_0x1210fd,_0x2243ec){_0x75193d['a']['Warn']('setLimit\x20is\x20not\x20currently\x20supported\x20by\x20the\x20Ammo\x20physics\x20plugin');},_0x5896c3['prototype']['syncMeshWithImpostor']=function(_0x261cef,_0x3acf55){_0x3acf55['physicsBody']['getMotionState']()['getWorldTransform'](this['_tmpAmmoTransform']),_0x261cef['position']['x']=this['_tmpAmmoTransform']['getOrigin']()['x'](),_0x261cef['position']['y']=this['_tmpAmmoTransform']['getOrigin']()['y'](),_0x261cef['position']['z']=this['_tmpAmmoTransform']['getOrigin']()['z'](),_0x261cef['rotationQuaternion']&&(_0x261cef['rotationQuaternion']['x']=this['_tmpAmmoTransform']['getRotation']()['x'](),_0x261cef['rotationQuaternion']['y']=this['_tmpAmmoTransform']['getRotation']()['y'](),_0x261cef['rotationQuaternion']['z']=this['_tmpAmmoTransform']['getRotation']()['z'](),_0x261cef['rotationQuaternion']['w']=this['_tmpAmmoTransform']['getRotation']()['w']());},_0x5896c3['prototype']['getRadius']=function(_0x4cd946){return _0x4cd946['getObjectExtendSize']()['x']/0x2;},_0x5896c3['prototype']['getBoxSizeToRef']=function(_0x25439e,_0x16d2fc){var _0x3ae0ee=_0x25439e['getObjectExtendSize']();_0x16d2fc['x']=_0x3ae0ee['x'],_0x16d2fc['y']=_0x3ae0ee['y'],_0x16d2fc['z']=_0x3ae0ee['z'];},_0x5896c3['prototype']['dispose']=function(){this['bjsAMMO']['destroy'](this['world']),this['bjsAMMO']['destroy'](this['_solver']),this['bjsAMMO']['destroy'](this['_overlappingPairCache']),this['bjsAMMO']['destroy'](this['_dispatcher']),this['bjsAMMO']['destroy'](this['_collisionConfiguration']),this['bjsAMMO']['destroy'](this['_tmpAmmoVectorA']),this['bjsAMMO']['destroy'](this['_tmpAmmoVectorB']),this['bjsAMMO']['destroy'](this['_tmpAmmoVectorC']),this['bjsAMMO']['destroy'](this['_tmpAmmoTransform']),this['bjsAMMO']['destroy'](this['_tmpAmmoQuaternion']),this['bjsAMMO']['destroy'](this['_tmpAmmoConcreteContactResultCallback']),this['world']=null;},_0x5896c3['prototype']['raycast']=function(_0x426661,_0x13252e){this['_tmpAmmoVectorRCA']=new this['bjsAMMO']['btVector3'](_0x426661['x'],_0x426661['y'],_0x426661['z']),this['_tmpAmmoVectorRCB']=new this['bjsAMMO']['btVector3'](_0x13252e['x'],_0x13252e['y'],_0x13252e['z']);var _0x501d0c=new this['bjsAMMO']['ClosestRayResultCallback'](this['_tmpAmmoVectorRCA'],this['_tmpAmmoVectorRCB']);return this['world']['rayTest'](this['_tmpAmmoVectorRCA'],this['_tmpAmmoVectorRCB'],_0x501d0c),this['_raycastResult']['reset'](_0x426661,_0x13252e),_0x501d0c['hasHit']()&&(this['_raycastResult']['setHitData']({'x':_0x501d0c['get_m_hitNormalWorld']()['x'](),'y':_0x501d0c['get_m_hitNormalWorld']()['y'](),'z':_0x501d0c['get_m_hitNormalWorld']()['z']()},{'x':_0x501d0c['get_m_hitPointWorld']()['x'](),'y':_0x501d0c['get_m_hitPointWorld']()['y'](),'z':_0x501d0c['get_m_hitPointWorld']()['z']()}),this['_raycastResult']['calculateHitDistance']()),this['bjsAMMO']['destroy'](_0x501d0c),this['bjsAMMO']['destroy'](this['_tmpAmmoVectorRCA']),this['bjsAMMO']['destroy'](this['_tmpAmmoVectorRCB']),this['_raycastResult'];},_0x5896c3['DISABLE_COLLISION_FLAG']=0x4,_0x5896c3['KINEMATIC_FLAG']=0x2,_0x5896c3['DISABLE_DEACTIVATION_FLAG']=0x4,_0x5896c3;}());_0x3598db['a']['prototype']['removeReflectionProbe']=function(_0x3eca6d){if(!this['reflectionProbes'])return-0x1;var _0x4b20ad=this['reflectionProbes']['indexOf'](_0x3eca6d);return-0x1!==_0x4b20ad&&this['reflectionProbes']['splice'](_0x4b20ad,0x1),_0x4b20ad;},_0x3598db['a']['prototype']['addReflectionProbe']=function(_0x4887ed){this['reflectionProbes']||(this['reflectionProbes']=[]),this['reflectionProbes']['push'](_0x4887ed);};var _0x39356b=(function(){function _0x1d6d6a(_0x1e1e88,_0x36d8a5,_0x59e461,_0x32a108,_0x4a5b90){var _0xc1c029=this;void 0x0===_0x32a108&&(_0x32a108=!0x0),void 0x0===_0x4a5b90&&(_0x4a5b90=!0x1),this['name']=_0x1e1e88,this['_viewMatrix']=_0x74d525['a']['Identity'](),this['_target']=_0x74d525['e']['Zero'](),this['_add']=_0x74d525['e']['Zero'](),this['_invertYAxis']=!0x1,this['position']=_0x74d525['e']['Zero'](),this['_scene']=_0x59e461,this['_scene']['reflectionProbes']||(this['_scene']['reflectionProbes']=new Array()),this['_scene']['reflectionProbes']['push'](this);var _0x44b224=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_BYTE'];if(_0x4a5b90){var _0x1d3c46=this['_scene']['getEngine']()['getCaps']();_0x1d3c46['textureHalfFloatRender']?_0x44b224=_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT']:_0x1d3c46['textureFloatRender']&&(_0x44b224=_0x2103ba['a']['TEXTURETYPE_FLOAT']);}this['_renderTargetTexture']=new _0x310f87(_0x1e1e88,_0x36d8a5,_0x59e461,_0x32a108,!0x0,_0x44b224,!0x0),this['_renderTargetTexture']['onBeforeRenderObservable']['add'](function(_0x12c27f){switch(_0x12c27f){case 0x0:_0xc1c029['_add']['copyFromFloats'](0x1,0x0,0x0);break;case 0x1:_0xc1c029['_add']['copyFromFloats'](-0x1,0x0,0x0);break;case 0x2:_0xc1c029['_add']['copyFromFloats'](0x0,_0xc1c029['_invertYAxis']?0x1:-0x1,0x0);break;case 0x3:_0xc1c029['_add']['copyFromFloats'](0x0,_0xc1c029['_invertYAxis']?-0x1:0x1,0x0);break;case 0x4:_0xc1c029['_add']['copyFromFloats'](0x0,0x0,0x1);break;case 0x5:_0xc1c029['_add']['copyFromFloats'](0x0,0x0,-0x1);}_0xc1c029['_attachedMesh']&&_0xc1c029['position']['copyFrom'](_0xc1c029['_attachedMesh']['getAbsolutePosition']()),_0xc1c029['position']['addToRef'](_0xc1c029['_add'],_0xc1c029['_target']),_0x74d525['a']['LookAtLHToRef'](_0xc1c029['position'],_0xc1c029['_target'],_0x74d525['e']['Up'](),_0xc1c029['_viewMatrix']),_0x59e461['activeCamera']&&(_0xc1c029['_projectionMatrix']=_0x74d525['a']['PerspectiveFovLH'](Math['PI']/0x2,0x1,_0x59e461['activeCamera']['minZ'],_0x59e461['activeCamera']['maxZ']),_0x59e461['setTransformMatrix'](_0xc1c029['_viewMatrix'],_0xc1c029['_projectionMatrix'])),_0x59e461['_forcedViewPosition']=_0xc1c029['position'];}),this['_renderTargetTexture']['onAfterUnbindObservable']['add'](function(){_0x59e461['_forcedViewPosition']=null,_0x59e461['updateTransformMatrix'](!0x0);});}return Object['defineProperty'](_0x1d6d6a['prototype'],'samples',{'get':function(){return this['_renderTargetTexture']['samples'];},'set':function(_0x294b99){this['_renderTargetTexture']['samples']=_0x294b99;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1d6d6a['prototype'],'refreshRate',{'get':function(){return this['_renderTargetTexture']['refreshRate'];},'set':function(_0x1eb508){this['_renderTargetTexture']['refreshRate']=_0x1eb508;},'enumerable':!0x1,'configurable':!0x0}),_0x1d6d6a['prototype']['getScene']=function(){return this['_scene'];},Object['defineProperty'](_0x1d6d6a['prototype'],'cubeTexture',{'get':function(){return this['_renderTargetTexture'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1d6d6a['prototype'],'renderList',{'get':function(){return this['_renderTargetTexture']['renderList'];},'enumerable':!0x1,'configurable':!0x0}),_0x1d6d6a['prototype']['attachToMesh']=function(_0xdab394){this['_attachedMesh']=_0xdab394;},_0x1d6d6a['prototype']['setRenderingAutoClearDepthStencil']=function(_0x28af8f,_0x50574b){this['_renderTargetTexture']['setRenderingAutoClearDepthStencil'](_0x28af8f,_0x50574b);},_0x1d6d6a['prototype']['dispose']=function(){var _0x252f09=this['_scene']['reflectionProbes']['indexOf'](this);-0x1!==_0x252f09&&this['_scene']['reflectionProbes']['splice'](_0x252f09,0x1),this['_renderTargetTexture']&&(this['_renderTargetTexture']['dispose'](),this['_renderTargetTexture']=null);},_0x1d6d6a['prototype']['toString']=function(_0x42e499){var _0x343767='Name:\x20'+this['name'];return _0x42e499&&(_0x343767+=',\x20position:\x20'+this['position']['toString'](),this['_attachedMesh']&&(_0x343767+=',\x20attached\x20mesh:\x20'+this['_attachedMesh']['name'])),_0x343767;},_0x1d6d6a['prototype']['getClassName']=function(){return'ReflectionProbe';},_0x1d6d6a['prototype']['serialize']=function(){var _0x1a223c=_0x495d06['a']['Serialize'](this,this['_renderTargetTexture']['serialize']());return _0x1a223c['isReflectionProbe']=!0x0,_0x1a223c;},_0x1d6d6a['Parse']=function(_0x34cc0a,_0x3ac042,_0x327cb3){var _0x12e412=null;if(_0x3ac042['reflectionProbes'])for(var _0x1c050d=0x0;_0x1c050d<_0x3ac042['reflectionProbes']['length'];_0x1c050d++){var _0x389d8d=_0x3ac042['reflectionProbes'][_0x1c050d];if(_0x389d8d['name']===_0x34cc0a['name']){_0x12e412=_0x389d8d;break;}}return(_0x12e412=_0x495d06['a']['Parse'](function(){return _0x12e412||new _0x1d6d6a(_0x34cc0a['name'],_0x34cc0a['renderTargetSize'],_0x3ac042,_0x34cc0a['_generateMipMaps']);},_0x34cc0a,_0x3ac042,_0x327cb3))['cubeTexture']['_waitingRenderList']=_0x34cc0a['renderList'],_0x34cc0a['_attachedMesh']&&_0x12e412['attachToMesh'](_0x3ac042['getMeshByID'](_0x34cc0a['_attachedMesh'])),_0x12e412;},Object(_0x18e13d['c'])([Object(_0x495d06['k'])()],_0x1d6d6a['prototype'],'_attachedMesh',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['o'])()],_0x1d6d6a['prototype'],'position',void 0x0),_0x1d6d6a;}()),_0x3fddea=!0x0,_0x4f9256=(function(){function _0x736ac7(){}return _0x736ac7['LoaderInjectedPhysicsEngine']=void 0x0,_0x736ac7;}()),_0x52057e=function(_0x1b7377,_0x592004,_0x52a22a,_0x4481a6){for(var _0x573938=0x0,_0x24f144=_0x592004['materials']['length'];_0x573938<_0x24f144;_0x573938++){var _0xd6d3ae=_0x592004['materials'][_0x573938];if(_0xd6d3ae['id']===_0x1b7377)return _0x33c2e5['a']['Parse'](_0xd6d3ae,_0x52a22a,_0x4481a6);}return null;},_0x44c3dd=function(_0x55184c,_0x2b3c69,_0x804ad8){for(var _0x5e62b8 in _0x2b3c69)if(_0x55184c['name']===_0x2b3c69[_0x5e62b8])return _0x804ad8['push'](_0x55184c['id']),!0x0;return!(!_0x55184c['parentId']||-0x1===_0x804ad8['indexOf'](_0x55184c['parentId']))&&(_0x804ad8['push'](_0x55184c['id']),!0x0);},_0x267e26=function(_0x2b429e,_0x46f339){return _0x2b429e+'\x20of\x20'+(_0x46f339?_0x46f339['file']+'\x20from\x20'+_0x46f339['name']+'\x20version:\x20'+_0x46f339['version']+',\x20exporter\x20version:\x20'+_0x46f339['exporter_version']:'unknown');},_0x4c17bd=function(_0x5c2ece,_0x1378f9){var _0x12dd9d=_0x1378f9;if(_0x1378f9['_waitingData']['lods']){if(_0x1378f9['_waitingData']['lods']['ids']&&_0x1378f9['_waitingData']['lods']['ids']['length']>0x0){var _0x24dfdf=_0x1378f9['_waitingData']['lods']['ids'],_0x5c04a1=_0x12dd9d['isEnabled'](!0x1);if(_0x1378f9['_waitingData']['lods']['distances']){var _0xb6a740=_0x1378f9['_waitingData']['lods']['distances'];if(_0xb6a740['length']>=_0x24dfdf['length']){var _0xbb79cc=_0xb6a740['length']>_0x24dfdf['length']?_0xb6a740[_0xb6a740['length']-0x1]:0x0;_0x12dd9d['setEnabled'](!0x1);for(var _0x399ab4=0x0;_0x399ab4<_0x24dfdf['length'];_0x399ab4++){var _0x380ba9=_0x24dfdf[_0x399ab4],_0x5cac32=_0x5c2ece['getMeshByID'](_0x380ba9);null!=_0x5cac32&&_0x12dd9d['addLODLevel'](_0xb6a740[_0x399ab4],_0x5cac32);}_0xbb79cc>0x0&&_0x12dd9d['addLODLevel'](_0xbb79cc,null),!0x0===_0x5c04a1&&_0x12dd9d['setEnabled'](!0x0);}else _0x5d754c['b']['Warn']('Invalid\x20level\x20of\x20detail\x20distances\x20for\x20'+_0x1378f9['name']);}}_0x1378f9['_waitingData']['lods']=null;}},_0x36d708=function(_0x34ea3a,_0x366bb0,_0xf68419,_0x389377,_0x3c97d8){void 0x0===_0x3c97d8&&(_0x3c97d8=!0x1);var _0x36c46d=new _0x3a6778(_0x34ea3a),_0xf101ee='importScene\x20has\x20failed\x20JSON\x20parse';try{var _0x46274b=JSON['parse'](_0x366bb0);_0xf101ee='';var _0x2fffb7,_0x4d83c6,_0xc1ef0c=_0x5de01e['loggingLevel']===_0x5de01e['DETAILED_LOGGING'];if(void 0x0!==_0x46274b['environmentTexture']&&null!==_0x46274b['environmentTexture']){var _0x4ba0c0=void 0x0===_0x46274b['isPBR']||_0x46274b['isPBR'];if(_0x46274b['environmentTextureType']&&'BABYLON.HDRCubeTexture'===_0x46274b['environmentTextureType']){var _0x460488=_0x46274b['environmentTextureSize']?_0x46274b['environmentTextureSize']:0x80,_0x1caeb3=new _0x26e1bc((_0x46274b['environmentTexture']['match'](/https?:\/\//g)?'':_0xf68419)+_0x46274b['environmentTexture'],_0x34ea3a,_0x460488,!0x0,!_0x4ba0c0);_0x46274b['environmentTextureRotationY']&&(_0x1caeb3['rotationY']=_0x46274b['environmentTextureRotationY']),_0x34ea3a['environmentTexture']=_0x1caeb3;}else{if(_0x5950ed['a']['EndsWith'](_0x46274b['environmentTexture'],'.env')){var _0x39088b=new _0x33892f((_0x46274b['environmentTexture']['match'](/https?:\/\//g)?'':_0xf68419)+_0x46274b['environmentTexture'],_0x34ea3a);_0x46274b['environmentTextureRotationY']&&(_0x39088b['rotationY']=_0x46274b['environmentTextureRotationY']),_0x34ea3a['environmentTexture']=_0x39088b;}else{var _0xef5766=_0x33892f['CreateFromPrefilteredData']((_0x46274b['environmentTexture']['match'](/https?:\/\//g)?'':_0xf68419)+_0x46274b['environmentTexture'],_0x34ea3a);_0x46274b['environmentTextureRotationY']&&(_0xef5766['rotationY']=_0x46274b['environmentTextureRotationY']),_0x34ea3a['environmentTexture']=_0xef5766;}}if(!0x0===_0x46274b['createDefaultSkybox']){var _0x161a0a=void 0x0!==_0x34ea3a['activeCamera']&&null!==_0x34ea3a['activeCamera']?(_0x34ea3a['activeCamera']['maxZ']-_0x34ea3a['activeCamera']['minZ'])/0x2:0x3e8,_0x2ec86b=_0x46274b['skyboxBlurLevel']||0x0;_0x34ea3a['createDefaultSkybox'](_0x34ea3a['environmentTexture'],_0x4ba0c0,_0x161a0a,_0x2ec86b);}_0x36c46d['environmentTexture']=_0x34ea3a['environmentTexture'];}if(void 0x0!==_0x46274b['environmentIntensity']&&null!==_0x46274b['environmentIntensity']&&(_0x34ea3a['environmentIntensity']=_0x46274b['environmentIntensity']),void 0x0!==_0x46274b['lights']&&null!==_0x46274b['lights'])for(_0x2fffb7=0x0,_0x4d83c6=_0x46274b['lights']['length'];_0x2fffb7<_0x4d83c6;_0x2fffb7++){var _0xaf0ddd=_0x46274b['lights'][_0x2fffb7],_0x376bdb=_0x4e3e4a['a']['Parse'](_0xaf0ddd,_0x34ea3a);_0x376bdb&&(_0x36c46d['lights']['push'](_0x376bdb),_0xf101ee+=0x0===_0x2fffb7?'\x0a\x09Lights:':'',_0xf101ee+='\x0a\x09\x09'+_0x376bdb['toString'](_0xc1ef0c));}if(void 0x0!==_0x46274b['reflectionProbes']&&null!==_0x46274b['reflectionProbes'])for(_0x2fffb7=0x0,_0x4d83c6=_0x46274b['reflectionProbes']['length'];_0x2fffb7<_0x4d83c6;_0x2fffb7++){var _0x5dffb5=_0x46274b['reflectionProbes'][_0x2fffb7],_0x5e3b00=_0x39356b['Parse'](_0x5dffb5,_0x34ea3a,_0xf68419);_0x5e3b00&&(_0x36c46d['reflectionProbes']['push'](_0x5e3b00),_0xf101ee+=0x0===_0x2fffb7?'\x0a\x09Reflection\x20Probes:':'',_0xf101ee+='\x0a\x09\x09'+_0x5e3b00['toString'](_0xc1ef0c));}if(void 0x0!==_0x46274b['animations']&&null!==_0x46274b['animations'])for(_0x2fffb7=0x0,_0x4d83c6=_0x46274b['animations']['length'];_0x2fffb7<_0x4d83c6;_0x2fffb7++){var _0x1d7522=_0x46274b['animations'][_0x2fffb7],_0x1da6ed=_0x3cd573['a']['GetClass']('BABYLON.Animation');if(_0x1da6ed){var _0x2579fd=_0x1da6ed['Parse'](_0x1d7522);_0x34ea3a['animations']['push'](_0x2579fd),_0x36c46d['animations']['push'](_0x2579fd),_0xf101ee+=0x0===_0x2fffb7?'\x0a\x09Animations:':'',_0xf101ee+='\x0a\x09\x09'+_0x2579fd['toString'](_0xc1ef0c);}}if(void 0x0!==_0x46274b['materials']&&null!==_0x46274b['materials'])for(_0x2fffb7=0x0,_0x4d83c6=_0x46274b['materials']['length'];_0x2fffb7<_0x4d83c6;_0x2fffb7++){var _0x34aee6=_0x46274b['materials'][_0x2fffb7],_0x765352=_0x33c2e5['a']['Parse'](_0x34aee6,_0x34ea3a,_0xf68419);if(_0x765352)_0x36c46d['materials']['push'](_0x765352),_0xf101ee+=0x0===_0x2fffb7?'\x0a\x09Materials:':'',_0xf101ee+='\x0a\x09\x09'+_0x765352['toString'](_0xc1ef0c),_0x765352['getActiveTextures']()['forEach'](function(_0x57c10d){-0x1==_0x36c46d['textures']['indexOf'](_0x57c10d)&&_0x36c46d['textures']['push'](_0x57c10d);});}if(void 0x0!==_0x46274b['multiMaterials']&&null!==_0x46274b['multiMaterials'])for(_0x2fffb7=0x0,_0x4d83c6=_0x46274b['multiMaterials']['length'];_0x2fffb7<_0x4d83c6;_0x2fffb7++){var _0x2fb2a0=_0x46274b['multiMaterials'][_0x2fffb7],_0x2c4211=_0x5a4b2b['a']['ParseMultiMaterial'](_0x2fb2a0,_0x34ea3a);_0x36c46d['multiMaterials']['push'](_0x2c4211),_0xf101ee+=0x0===_0x2fffb7?'\x0a\x09MultiMaterials:':'',_0xf101ee+='\x0a\x09\x09'+_0x2c4211['toString'](_0xc1ef0c),_0x2c4211['getActiveTextures']()['forEach'](function(_0x5755c9){-0x1==_0x36c46d['textures']['indexOf'](_0x5755c9)&&_0x36c46d['textures']['push'](_0x5755c9);});}if(void 0x0!==_0x46274b['morphTargetManagers']&&null!==_0x46274b['morphTargetManagers'])for(var _0x5f2f50=0x0,_0x4535a9=_0x46274b['morphTargetManagers'];_0x5f2f50<_0x4535a9['length'];_0x5f2f50++){var _0x4dc4b8=_0x4535a9[_0x5f2f50];_0x36c46d['morphTargetManagers']['push'](_0x43ac20['Parse'](_0x4dc4b8,_0x34ea3a));}if(void 0x0!==_0x46274b['skeletons']&&null!==_0x46274b['skeletons'])for(_0x2fffb7=0x0,_0x4d83c6=_0x46274b['skeletons']['length'];_0x2fffb7<_0x4d83c6;_0x2fffb7++){var _0x7cbde2=_0x46274b['skeletons'][_0x2fffb7],_0x20f5a6=_0x4198a1['Parse'](_0x7cbde2,_0x34ea3a);_0x36c46d['skeletons']['push'](_0x20f5a6),_0xf101ee+=0x0===_0x2fffb7?'\x0a\x09Skeletons:':'',_0xf101ee+='\x0a\x09\x09'+_0x20f5a6['toString'](_0xc1ef0c);}var _0x3d311d=_0x46274b['geometries'];if(null!=_0x3d311d){var _0x333267=new Array(),_0x505be4=_0x3d311d['vertexData'];if(null!=_0x505be4)for(_0x2fffb7=0x0,_0x4d83c6=_0x505be4['length'];_0x2fffb7<_0x4d83c6;_0x2fffb7++){var _0x41cd2d=_0x505be4[_0x2fffb7];_0x333267['push'](_0xe6018['a']['Parse'](_0x41cd2d,_0x34ea3a,_0xf68419));}_0x333267['forEach'](function(_0x1deaa4){_0x1deaa4&&_0x36c46d['geometries']['push'](_0x1deaa4);});}if(void 0x0!==_0x46274b['transformNodes']&&null!==_0x46274b['transformNodes'])for(_0x2fffb7=0x0,_0x4d83c6=_0x46274b['transformNodes']['length'];_0x2fffb7<_0x4d83c6;_0x2fffb7++){var _0x453fd2=_0x46274b['transformNodes'][_0x2fffb7],_0xcdacc2=_0x200669['a']['Parse'](_0x453fd2,_0x34ea3a,_0xf68419);_0x36c46d['transformNodes']['push'](_0xcdacc2);}if(void 0x0!==_0x46274b['meshes']&&null!==_0x46274b['meshes'])for(_0x2fffb7=0x0,_0x4d83c6=_0x46274b['meshes']['length'];_0x2fffb7<_0x4d83c6;_0x2fffb7++){var _0x150bea=_0x46274b['meshes'][_0x2fffb7],_0x422dff=_0x3cf5e5['a']['Parse'](_0x150bea,_0x34ea3a,_0xf68419);if(_0x36c46d['meshes']['push'](_0x422dff),_0x422dff['hasInstances'])for(var _0x515ca1=0x0,_0x2f1548=_0x422dff['instances'];_0x515ca1<_0x2f1548['length'];_0x515ca1++){var _0x5d47fd=_0x2f1548[_0x515ca1];_0x36c46d['meshes']['push'](_0x5d47fd);}_0xf101ee+=0x0===_0x2fffb7?'\x0a\x09Meshes:':'',_0xf101ee+='\x0a\x09\x09'+_0x422dff['toString'](_0xc1ef0c);}if(void 0x0!==_0x46274b['cameras']&&null!==_0x46274b['cameras'])for(_0x2fffb7=0x0,_0x4d83c6=_0x46274b['cameras']['length'];_0x2fffb7<_0x4d83c6;_0x2fffb7++){var _0x37e96e=_0x46274b['cameras'][_0x2fffb7],_0x3cae5c=_0x568729['a']['Parse'](_0x37e96e,_0x34ea3a);_0x36c46d['cameras']['push'](_0x3cae5c),_0xf101ee+=0x0===_0x2fffb7?'\x0a\x09Cameras:':'',_0xf101ee+='\x0a\x09\x09'+_0x3cae5c['toString'](_0xc1ef0c);}if(void 0x0!==_0x46274b['postProcesses']&&null!==_0x46274b['postProcesses'])for(_0x2fffb7=0x0,_0x4d83c6=_0x46274b['postProcesses']['length'];_0x2fffb7<_0x4d83c6;_0x2fffb7++){var _0x3a0718=_0x46274b['postProcesses'][_0x2fffb7],_0x4a827d=_0x5cae84['Parse'](_0x3a0718,_0x34ea3a,_0xf68419);_0x4a827d&&(_0x36c46d['postProcesses']['push'](_0x4a827d),_0xf101ee+=0x0===_0x2fffb7?'\x0aPostprocesses:':'',_0xf101ee+='\x0a\x09\x09'+_0x4a827d['toString']());}if(void 0x0!==_0x46274b['animationGroups']&&null!==_0x46274b['animationGroups'])for(_0x2fffb7=0x0,_0x4d83c6=_0x46274b['animationGroups']['length'];_0x2fffb7<_0x4d83c6;_0x2fffb7++){var _0x516030=_0x46274b['animationGroups'][_0x2fffb7],_0x1e7fa1=_0x433562['Parse'](_0x516030,_0x34ea3a);_0x36c46d['animationGroups']['push'](_0x1e7fa1),_0xf101ee+=0x0===_0x2fffb7?'\x0a\x09AnimationGroups:':'',_0xf101ee+='\x0a\x09\x09'+_0x1e7fa1['toString'](_0xc1ef0c);}for(_0x2fffb7=0x0,_0x4d83c6=_0x34ea3a['cameras']['length'];_0x2fffb7<_0x4d83c6;_0x2fffb7++){(_0x3cae5c=_0x34ea3a['cameras'][_0x2fffb7])['_waitingParentId']&&(_0x3cae5c['parent']=_0x34ea3a['getLastEntryByID'](_0x3cae5c['_waitingParentId']),_0x3cae5c['_waitingParentId']=null);}for(_0x2fffb7=0x0,_0x4d83c6=_0x34ea3a['lights']['length'];_0x2fffb7<_0x4d83c6;_0x2fffb7++){var _0x58623a=_0x34ea3a['lights'][_0x2fffb7];_0x58623a&&_0x58623a['_waitingParentId']&&(_0x58623a['parent']=_0x34ea3a['getLastEntryByID'](_0x58623a['_waitingParentId']),_0x58623a['_waitingParentId']=null);}for(_0x2fffb7=0x0,_0x4d83c6=_0x34ea3a['transformNodes']['length'];_0x2fffb7<_0x4d83c6;_0x2fffb7++){var _0x5d0f68=_0x34ea3a['transformNodes'][_0x2fffb7];_0x5d0f68['_waitingParentId']&&(_0x5d0f68['parent']=_0x34ea3a['getLastEntryByID'](_0x5d0f68['_waitingParentId']),_0x5d0f68['_waitingParentId']=null);}for(_0x2fffb7=0x0,_0x4d83c6=_0x34ea3a['meshes']['length'];_0x2fffb7<_0x4d83c6;_0x2fffb7++){(_0x422dff=_0x34ea3a['meshes'][_0x2fffb7])['_waitingParentId']&&(_0x422dff['parent']=_0x34ea3a['getLastEntryByID'](_0x422dff['_waitingParentId']),_0x422dff['_waitingParentId']=null),_0x422dff['_waitingData']['lods']&&_0x4c17bd(_0x34ea3a,_0x422dff);}for(_0x2fffb7=0x0,_0x4d83c6=_0x34ea3a['skeletons']['length'];_0x2fffb7<_0x4d83c6;_0x2fffb7++){(_0x20f5a6=_0x34ea3a['skeletons'][_0x2fffb7])['_hasWaitingData']&&(null!=_0x20f5a6['bones']&&_0x20f5a6['bones']['forEach'](function(_0x373b2b){if(_0x373b2b['_waitingTransformNodeId']){var _0x1a1b71=_0x34ea3a['getLastEntryByID'](_0x373b2b['_waitingTransformNodeId']);_0x1a1b71&&_0x373b2b['linkTransformNode'](_0x1a1b71),_0x373b2b['_waitingTransformNodeId']=null;}}),_0x20f5a6['_waitingOverrideMeshId']&&(_0x20f5a6['overrideMesh']=_0x34ea3a['getMeshByID'](_0x20f5a6['_waitingOverrideMeshId']),_0x20f5a6['_waitingOverrideMeshId']=null),_0x20f5a6['_hasWaitingData']=null);}for(_0x2fffb7=0x0,_0x4d83c6=_0x34ea3a['meshes']['length'];_0x2fffb7<_0x4d83c6;_0x2fffb7++){var _0x45a627=_0x34ea3a['meshes'][_0x2fffb7];_0x45a627['_waitingData']['freezeWorldMatrix']?(_0x45a627['freezeWorldMatrix'](),_0x45a627['_waitingData']['freezeWorldMatrix']=null):_0x45a627['computeWorldMatrix'](!0x0);}for(_0x2fffb7=0x0,_0x4d83c6=_0x34ea3a['lights']['length'];_0x2fffb7<_0x4d83c6;_0x2fffb7++){var _0x54254f=_0x34ea3a['lights'][_0x2fffb7];if(_0x54254f['_excludedMeshesIds']['length']>0x0){for(var _0x50d0a6=0x0;_0x50d0a6<_0x54254f['_excludedMeshesIds']['length'];_0x50d0a6++){var _0x146baf=_0x34ea3a['getMeshByID'](_0x54254f['_excludedMeshesIds'][_0x50d0a6]);_0x146baf&&_0x54254f['excludedMeshes']['push'](_0x146baf);}_0x54254f['_excludedMeshesIds']=[];}if(_0x54254f['_includedOnlyMeshesIds']['length']>0x0){for(var _0x5b6426=0x0;_0x5b6426<_0x54254f['_includedOnlyMeshesIds']['length'];_0x5b6426++){var _0x516271=_0x34ea3a['getMeshByID'](_0x54254f['_includedOnlyMeshesIds'][_0x5b6426]);_0x516271&&_0x54254f['includedOnlyMeshes']['push'](_0x516271);}_0x54254f['_includedOnlyMeshesIds']=[];}}for(_0x3598db['a']['Parse'](_0x46274b,_0x34ea3a,_0x36c46d,_0xf68419),_0x2fffb7=0x0,_0x4d83c6=_0x34ea3a['meshes']['length'];_0x2fffb7<_0x4d83c6;_0x2fffb7++){(_0x422dff=_0x34ea3a['meshes'][_0x2fffb7])['_waitingData']['actions']&&(_0x443d42['Parse'](_0x422dff['_waitingData']['actions'],_0x422dff,_0x34ea3a),_0x422dff['_waitingData']['actions']=null);}void 0x0!==_0x46274b['actions']&&null!==_0x46274b['actions']&&_0x443d42['Parse'](_0x46274b['actions'],null,_0x34ea3a);}catch(_0x2eb116){var _0x5829e3=_0x267e26('loadAssets',_0x46274b?_0x46274b['producer']:'Unknown')+_0xf101ee;if(!_0x389377)throw _0x75193d['a']['Log'](_0x5829e3),_0x2eb116;_0x389377(_0x5829e3,_0x2eb116);}finally{_0x3c97d8||_0x36c46d['removeAllFromScene'](),null!==_0xf101ee&&_0x5de01e['loggingLevel']!==_0x5de01e['NO_LOGGING']&&_0x75193d['a']['Log'](_0x267e26('loadAssets',_0x46274b?_0x46274b['producer']:'Unknown')+(_0x5de01e['loggingLevel']!==_0x5de01e['MINIMAL_LOGGING']?_0xf101ee:''));}return _0x36c46d;};_0x5de01e['RegisterPlugin']({'name':'babylon.js','extensions':'.babylon','canDirectLoad':function(_0x13998c){return-0x1!==_0x13998c['indexOf']('babylon');},'importMesh':function(_0x332271,_0x259654,_0x59ec7c,_0x24e02a,_0x2a5f4d,_0x1421bf,_0x2a4ddc,_0x1d2f16){var _0x51adbb='importMesh\x20has\x20failed\x20JSON\x20parse';try{var _0x5aa0ce=JSON['parse'](_0x59ec7c);_0x51adbb='';var _0x53cb56=_0x5de01e['loggingLevel']===_0x5de01e['DETAILED_LOGGING'];_0x332271?Array['isArray'](_0x332271)||(_0x332271=[_0x332271]):_0x332271=null;var _0x5c9a3e=new Array();if(void 0x0!==_0x5aa0ce['meshes']&&null!==_0x5aa0ce['meshes']){var _0x1ea69f,_0x507d21,_0x44e977,_0xcabc9c=[],_0x28d960=[];for(_0x1ea69f=0x0,_0x507d21=_0x5aa0ce['meshes']['length'];_0x1ea69f<_0x507d21;_0x1ea69f++){var _0x591138=_0x5aa0ce['meshes'][_0x1ea69f];if(null===_0x332271||_0x44c3dd(_0x591138,_0x332271,_0x5c9a3e)){if(null!==_0x332271&&delete _0x332271[_0x332271['indexOf'](_0x591138['name'])],void 0x0!==_0x591138['geometryId']&&null!==_0x591138['geometryId']&&void 0x0!==_0x5aa0ce['geometries']&&null!==_0x5aa0ce['geometries']){var _0x2b516a=!0x1;['boxes','spheres','cylinders','toruses','grounds','planes','torusKnots','vertexData']['forEach'](function(_0x26aad0){!0x0!==_0x2b516a&&_0x5aa0ce['geometries'][_0x26aad0]&&Array['isArray'](_0x5aa0ce['geometries'][_0x26aad0])&&_0x5aa0ce['geometries'][_0x26aad0]['forEach'](function(_0x555acb){if(_0x555acb['id']===_0x591138['geometryId']){switch(_0x26aad0){case'vertexData':_0xe6018['a']['Parse'](_0x555acb,_0x259654,_0x24e02a);}_0x2b516a=!0x0;}});}),!0x1===_0x2b516a&&_0x75193d['a']['Warn']('Geometry\x20not\x20found\x20for\x20mesh\x20'+_0x591138['id']);}if(_0x591138['materialId']){var _0x3ae822=-0x1!==_0x28d960['indexOf'](_0x591138['materialId']);if(!0x1===_0x3ae822&&void 0x0!==_0x5aa0ce['multiMaterials']&&null!==_0x5aa0ce['multiMaterials'])for(var _0x2f9d2d=0x0,_0x297f74=_0x5aa0ce['multiMaterials']['length'];_0x2f9d2d<_0x297f74;_0x2f9d2d++){var _0x4a3fb6=_0x5aa0ce['multiMaterials'][_0x2f9d2d];if(_0x4a3fb6['id']===_0x591138['materialId']){for(var _0xf27901=0x0,_0x1d6d04=_0x4a3fb6['materials']['length'];_0xf27901<_0x1d6d04;_0xf27901++){var _0x22fd48,_0x3818cc=_0x4a3fb6['materials'][_0xf27901];_0x28d960['push'](_0x3818cc),(_0x22fd48=_0x52057e(_0x3818cc,_0x5aa0ce,_0x259654,_0x24e02a))&&(_0x51adbb+='\x0a\x09Material\x20'+_0x22fd48['toString'](_0x53cb56));}_0x28d960['push'](_0x4a3fb6['id']);var _0x2ef944=_0x5a4b2b['a']['ParseMultiMaterial'](_0x4a3fb6,_0x259654);_0x2ef944&&(_0x3ae822=!0x0,_0x51adbb+='\x0a\x09Multi-Material\x20'+_0x2ef944['toString'](_0x53cb56));break;}}if(!0x1===_0x3ae822)_0x28d960['push'](_0x591138['materialId']),(_0x22fd48=_0x52057e(_0x591138['materialId'],_0x5aa0ce,_0x259654,_0x24e02a))?_0x51adbb+='\x0a\x09Material\x20'+_0x22fd48['toString'](_0x53cb56):_0x75193d['a']['Warn']('Material\x20not\x20found\x20for\x20mesh\x20'+_0x591138['id']);}if(_0x591138['skeletonId']>-0x1&&void 0x0!==_0x5aa0ce['skeletons']&&null!==_0x5aa0ce['skeletons']){if(!0x1===_0xcabc9c['indexOf'](_0x591138['skeletonId'])>-0x1)for(var _0x38f778=0x0,_0x20ff39=_0x5aa0ce['skeletons']['length'];_0x38f778<_0x20ff39;_0x38f778++){var _0x4e44d8=_0x5aa0ce['skeletons'][_0x38f778];if(_0x4e44d8['id']===_0x591138['skeletonId']){var _0x2416d3=_0x4198a1['Parse'](_0x4e44d8,_0x259654);_0x2a4ddc['push'](_0x2416d3),_0xcabc9c['push'](_0x4e44d8['id']),_0x51adbb+='\x0a\x09Skeleton\x20'+_0x2416d3['toString'](_0x53cb56);}}}if(void 0x0!==_0x5aa0ce['morphTargetManagers']&&null!==_0x5aa0ce['morphTargetManagers'])for(var _0x4a046e=0x0,_0x1d85c7=_0x5aa0ce['morphTargetManagers'];_0x4a046e<_0x1d85c7['length'];_0x4a046e++){var _0x242a32=_0x1d85c7[_0x4a046e];_0x43ac20['Parse'](_0x242a32,_0x259654);}var _0x1a05c5=_0x3cf5e5['a']['Parse'](_0x591138,_0x259654,_0x24e02a);_0x2a5f4d['push'](_0x1a05c5),_0x51adbb+='\x0a\x09Mesh\x20'+_0x1a05c5['toString'](_0x53cb56);}}for(_0x1ea69f=0x0,_0x507d21=_0x259654['meshes']['length'];_0x1ea69f<_0x507d21;_0x1ea69f++)(_0x44e977=_0x259654['meshes'][_0x1ea69f])['_waitingParentId']&&(_0x44e977['parent']=_0x259654['getLastEntryByID'](_0x44e977['_waitingParentId']),_0x44e977['_waitingParentId']=null),_0x44e977['_waitingData']['lods']&&_0x4c17bd(_0x259654,_0x44e977);for(_0x1ea69f=0x0,_0x507d21=_0x259654['skeletons']['length'];_0x1ea69f<_0x507d21;_0x1ea69f++){(_0x2416d3=_0x259654['skeletons'][_0x1ea69f])['_hasWaitingData']&&(null!=_0x2416d3['bones']&&_0x2416d3['bones']['forEach'](function(_0xabb50e){if(_0xabb50e['_waitingTransformNodeId']){var _0x2ace0f=_0x259654['getLastEntryByID'](_0xabb50e['_waitingTransformNodeId']);_0x2ace0f&&_0xabb50e['linkTransformNode'](_0x2ace0f),_0xabb50e['_waitingTransformNodeId']=null;}}),_0x2416d3['_waitingOverrideMeshId']&&(_0x2416d3['overrideMesh']=_0x259654['getMeshByID'](_0x2416d3['_waitingOverrideMeshId']),_0x2416d3['_waitingOverrideMeshId']=null),_0x2416d3['_hasWaitingData']=null);}for(_0x1ea69f=0x0,_0x507d21=_0x259654['meshes']['length'];_0x1ea69f<_0x507d21;_0x1ea69f++)(_0x44e977=_0x259654['meshes'][_0x1ea69f])['_waitingData']['freezeWorldMatrix']?(_0x44e977['freezeWorldMatrix'](),_0x44e977['_waitingData']['freezeWorldMatrix']=null):_0x44e977['computeWorldMatrix'](!0x0);}if(void 0x0!==_0x5aa0ce['particleSystems']&&null!==_0x5aa0ce['particleSystems']){var _0x336d13=_0x3598db['a']['GetIndividualParser'](_0x384de3['a']['NAME_PARTICLESYSTEM']);if(_0x336d13)for(_0x1ea69f=0x0,_0x507d21=_0x5aa0ce['particleSystems']['length'];_0x1ea69f<_0x507d21;_0x1ea69f++){var _0x480269=_0x5aa0ce['particleSystems'][_0x1ea69f];-0x1!==_0x5c9a3e['indexOf'](_0x480269['emitterId'])&&_0x1421bf['push'](_0x336d13(_0x480269,_0x259654,_0x24e02a));}}return!0x0;}catch(_0x4b1259){var _0x577167=_0x267e26('importMesh',_0x5aa0ce?_0x5aa0ce['producer']:'Unknown')+_0x51adbb;if(!_0x1d2f16)throw _0x75193d['a']['Log'](_0x577167),_0x4b1259;_0x1d2f16(_0x577167,_0x4b1259);}finally{null!==_0x51adbb&&_0x5de01e['loggingLevel']!==_0x5de01e['NO_LOGGING']&&_0x75193d['a']['Log'](_0x267e26('importMesh',_0x5aa0ce?_0x5aa0ce['producer']:'Unknown')+(_0x5de01e['loggingLevel']!==_0x5de01e['MINIMAL_LOGGING']?_0x51adbb:''));}return!0x1;},'load':function(_0x3bc96f,_0x1c4b52,_0x5deb6c,_0x30ed7a){var _0x12f045='importScene\x20has\x20failed\x20JSON\x20parse';try{var _0x3d6426=JSON['parse'](_0x1c4b52);if(_0x12f045='',void 0x0!==_0x3d6426['useDelayedTextureLoading']&&null!==_0x3d6426['useDelayedTextureLoading']&&(_0x3bc96f['useDelayedTextureLoading']=_0x3d6426['useDelayedTextureLoading']&&!_0x5de01e['ForceFullSceneLoadingForIncremental']),void 0x0!==_0x3d6426['autoClear']&&null!==_0x3d6426['autoClear']&&(_0x3bc96f['autoClear']=_0x3d6426['autoClear']),void 0x0!==_0x3d6426['clearColor']&&null!==_0x3d6426['clearColor']&&(_0x3bc96f['clearColor']=_0x39310d['b']['FromArray'](_0x3d6426['clearColor'])),void 0x0!==_0x3d6426['ambientColor']&&null!==_0x3d6426['ambientColor']&&(_0x3bc96f['ambientColor']=_0x39310d['a']['FromArray'](_0x3d6426['ambientColor'])),void 0x0!==_0x3d6426['gravity']&&null!==_0x3d6426['gravity']&&(_0x3bc96f['gravity']=_0x74d525['e']['FromArray'](_0x3d6426['gravity'])),_0x3d6426['fogMode']&&0x0!==_0x3d6426['fogMode'])switch(_0x3bc96f['fogMode']=_0x3d6426['fogMode'],_0x3bc96f['fogColor']=_0x39310d['a']['FromArray'](_0x3d6426['fogColor']),_0x3bc96f['fogStart']=_0x3d6426['fogStart'],_0x3bc96f['fogEnd']=_0x3d6426['fogEnd'],_0x3bc96f['fogDensity']=_0x3d6426['fogDensity'],_0x12f045+='\x09Fog\x20mode\x20for\x20scene:\x20\x20',_0x3bc96f['fogMode']){case 0x1:_0x12f045+='exp\x0a';break;case 0x2:_0x12f045+='exp2\x0a';break;case 0x3:_0x12f045+='linear\x0a';}if(_0x3d6426['physicsEnabled']){var _0x46f23d;'cannon'===_0x3d6426['physicsEngine']?_0x46f23d=new _0x52f9b1(void 0x0,void 0x0,_0x4f9256['LoaderInjectedPhysicsEngine']):'oimo'===_0x3d6426['physicsEngine']?_0x46f23d=new _0x128d84(void 0x0,_0x4f9256['LoaderInjectedPhysicsEngine']):'ammo'===_0x3d6426['physicsEngine']&&(_0x46f23d=new _0x1e7dd4(void 0x0,_0x4f9256['LoaderInjectedPhysicsEngine'],void 0x0)),_0x12f045='\x09Physics\x20engine\x20'+(_0x3d6426['physicsEngine']?_0x3d6426['physicsEngine']:'oimo')+'\x20enabled\x0a';var _0x53b5a8=_0x3d6426['physicsGravity']?_0x74d525['e']['FromArray'](_0x3d6426['physicsGravity']):null;_0x3bc96f['enablePhysics'](_0x53b5a8,_0x46f23d);}return void 0x0!==_0x3d6426['metadata']&&null!==_0x3d6426['metadata']&&(_0x3bc96f['metadata']=_0x3d6426['metadata']),void 0x0!==_0x3d6426['collisionsEnabled']&&null!==_0x3d6426['collisionsEnabled']&&(_0x3bc96f['collisionsEnabled']=_0x3d6426['collisionsEnabled']),!!_0x36d708(_0x3bc96f,_0x1c4b52,_0x5deb6c,_0x30ed7a,!0x0)&&(_0x3d6426['autoAnimate']&&_0x3bc96f['beginAnimation'](_0x3bc96f,_0x3d6426['autoAnimateFrom'],_0x3d6426['autoAnimateTo'],_0x3d6426['autoAnimateLoop'],_0x3d6426['autoAnimateSpeed']||0x1),void 0x0!==_0x3d6426['activeCameraID']&&null!==_0x3d6426['activeCameraID']&&_0x3bc96f['setActiveCameraByID'](_0x3d6426['activeCameraID']),!0x0);}catch(_0x3515f2){var _0x42b27f=_0x267e26('importScene',_0x3d6426?_0x3d6426['producer']:'Unknown')+_0x12f045;if(!_0x30ed7a)throw _0x75193d['a']['Log'](_0x42b27f),_0x3515f2;_0x30ed7a(_0x42b27f,_0x3515f2);}finally{null!==_0x12f045&&_0x5de01e['loggingLevel']!==_0x5de01e['NO_LOGGING']&&_0x75193d['a']['Log'](_0x267e26('importScene',_0x3d6426?_0x3d6426['producer']:'Unknown')+(_0x5de01e['loggingLevel']!==_0x5de01e['MINIMAL_LOGGING']?_0x12f045:''));}return!0x1;},'loadAssetContainer':function(_0x160fc4,_0x142b72,_0x1c5c2c,_0x56dc89){return _0x36d708(_0x160fc4,_0x142b72,_0x1c5c2c,_0x56dc89);}});var _0x133a53=_0x162675(0x79),_0x541f6d=(function(){function _0x18d849(_0x35f099){void 0x0===_0x35f099&&(_0x35f099={}),this['_isEnabled']=!0x0,this['bias']=void 0x0===_0x35f099['bias']?0x0:_0x35f099['bias'],this['power']=void 0x0===_0x35f099['power']?0x1:_0x35f099['power'],this['leftColor']=_0x35f099['leftColor']||_0x39310d['a']['White'](),this['rightColor']=_0x35f099['rightColor']||_0x39310d['a']['Black'](),!0x1===_0x35f099['isEnabled']&&(this['isEnabled']=!0x1);}return Object['defineProperty'](_0x18d849['prototype'],'isEnabled',{'get':function(){return this['_isEnabled'];},'set':function(_0x4e17ff){this['_isEnabled']!==_0x4e17ff&&(this['_isEnabled']=_0x4e17ff,_0x300b38['a']['MarkAllMaterialsAsDirty'](_0x2103ba['a']['MATERIAL_FresnelDirtyFlag']|_0x2103ba['a']['MATERIAL_MiscDirtyFlag']));},'enumerable':!0x1,'configurable':!0x0}),_0x18d849['prototype']['clone']=function(){var _0x4ce8f1=new _0x18d849();return _0x5d9c83['a']['DeepCopy'](this,_0x4ce8f1),_0x4ce8f1;},_0x18d849['prototype']['equals']=function(_0x4eb5c9){return _0x4eb5c9&&this['bias']===_0x4eb5c9['bias']&&this['power']===_0x4eb5c9['power']&&this['leftColor']['equals'](_0x4eb5c9['leftColor'])&&this['rightColor']['equals'](_0x4eb5c9['rightColor'])&&this['isEnabled']===_0x4eb5c9['isEnabled'];},_0x18d849['prototype']['serialize']=function(){return{'isEnabled':this['isEnabled'],'leftColor':this['leftColor']['asArray'](),'rightColor':this['rightColor']['asArray'](),'bias':this['bias'],'power':this['power']};},_0x18d849['Parse']=function(_0x5c13b7){return new _0x18d849({'isEnabled':_0x5c13b7['isEnabled'],'leftColor':_0x39310d['a']['FromArray'](_0x5c13b7['leftColor']),'rightColor':_0x39310d['a']['FromArray'](_0x5c13b7['rightColor']),'bias':_0x5c13b7['bias'],'power':_0x5c13b7['power']||0x1});},_0x18d849;}());_0x495d06['a']['_FresnelParametersParser']=_0x541f6d['Parse'];var _0x51ff42=_0x162675(0x77),_0x532fe4=function(_0x33faed){function _0x2dce5e(_0x32d79c,_0x57850d){var _0x287b7e=_0x33faed['call'](this,_0x32d79c,_0x57850d)||this;return _0x287b7e['maxSimultaneousLights']=0x4,_0x287b7e['disableLighting']=!0x1,_0x287b7e['invertNormalMapX']=!0x1,_0x287b7e['invertNormalMapY']=!0x1,_0x287b7e['emissiveColor']=new _0x39310d['a'](0x0,0x0,0x0),_0x287b7e['occlusionStrength']=0x1,_0x287b7e['useLightmapAsShadowmap']=!0x1,_0x287b7e['_useAlphaFromAlbedoTexture']=!0x0,_0x287b7e['_useAmbientInGrayScale']=!0x0,_0x287b7e;}return Object(_0x18e13d['d'])(_0x2dce5e,_0x33faed),Object['defineProperty'](_0x2dce5e['prototype'],'doubleSided',{'get':function(){return this['_twoSidedLighting'];},'set':function(_0x124cc7){this['_twoSidedLighting']!==_0x124cc7&&(this['_twoSidedLighting']=_0x124cc7,this['backFaceCulling']=!_0x124cc7,this['_markAllSubMeshesAsTexturesDirty']());},'enumerable':!0x1,'configurable':!0x0}),_0x2dce5e['prototype']['getClassName']=function(){return'PBRBaseSimpleMaterial';},Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsLightsDirty')],_0x2dce5e['prototype'],'maxSimultaneousLights',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsLightsDirty')],_0x2dce5e['prototype'],'disableLighting',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty','_reflectionTexture')],_0x2dce5e['prototype'],'environmentTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x2dce5e['prototype'],'invertNormalMapX',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x2dce5e['prototype'],'invertNormalMapY',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty','_bumpTexture')],_0x2dce5e['prototype'],'normalTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['e'])('emissive'),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x2dce5e['prototype'],'emissiveColor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x2dce5e['prototype'],'emissiveTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty','_ambientTextureStrength')],_0x2dce5e['prototype'],'occlusionStrength',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty','_ambientTexture')],_0x2dce5e['prototype'],'occlusionTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty','_alphaCutOff')],_0x2dce5e['prototype'],'alphaCutOff',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x2dce5e['prototype'],'doubleSided',null),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty',null)],_0x2dce5e['prototype'],'lightmapTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x2dce5e['prototype'],'useLightmapAsShadowmap',void 0x0),_0x2dce5e;}(_0x136113),_0x495b0c=function(_0x3692c6){function _0x82d5d6(_0x589c59,_0x55a5b6){var _0x4223f5=_0x3692c6['call'](this,_0x589c59,_0x55a5b6)||this;return _0x4223f5['_useRoughnessFromMetallicTextureAlpha']=!0x1,_0x4223f5['_useRoughnessFromMetallicTextureGreen']=!0x0,_0x4223f5['_useMetallnessFromMetallicTextureBlue']=!0x0,_0x4223f5['metallic']=0x1,_0x4223f5['roughness']=0x1,_0x4223f5;}return Object(_0x18e13d['d'])(_0x82d5d6,_0x3692c6),_0x82d5d6['prototype']['getClassName']=function(){return'PBRMetallicRoughnessMaterial';},_0x82d5d6['prototype']['clone']=function(_0x2254ae){var _0x16b739=this,_0x391e84=_0x495d06['a']['Clone'](function(){return new _0x82d5d6(_0x2254ae,_0x16b739['getScene']());},this);return _0x391e84['id']=_0x2254ae,_0x391e84['name']=_0x2254ae,this['clearCoat']['copyTo'](_0x391e84['clearCoat']),this['anisotropy']['copyTo'](_0x391e84['anisotropy']),this['brdf']['copyTo'](_0x391e84['brdf']),this['sheen']['copyTo'](_0x391e84['sheen']),this['subSurface']['copyTo'](_0x391e84['subSurface']),_0x391e84;},_0x82d5d6['prototype']['serialize']=function(){var _0x582954=_0x495d06['a']['Serialize'](this);return _0x582954['customType']='BABYLON.PBRMetallicRoughnessMaterial',_0x582954['clearCoat']=this['clearCoat']['serialize'](),_0x582954['anisotropy']=this['anisotropy']['serialize'](),_0x582954['brdf']=this['brdf']['serialize'](),_0x582954['sheen']=this['sheen']['serialize'](),_0x582954['subSurface']=this['subSurface']['serialize'](),_0x582954;},_0x82d5d6['Parse']=function(_0x5b9f4f,_0x3cc050,_0x5b6ee0){var _0x19664c=_0x495d06['a']['Parse'](function(){return new _0x82d5d6(_0x5b9f4f['name'],_0x3cc050);},_0x5b9f4f,_0x3cc050,_0x5b6ee0);return _0x5b9f4f['clearCoat']&&_0x19664c['clearCoat']['parse'](_0x5b9f4f['clearCoat'],_0x3cc050,_0x5b6ee0),_0x5b9f4f['anisotropy']&&_0x19664c['anisotropy']['parse'](_0x5b9f4f['anisotropy'],_0x3cc050,_0x5b6ee0),_0x5b9f4f['brdf']&&_0x19664c['brdf']['parse'](_0x5b9f4f['brdf'],_0x3cc050,_0x5b6ee0),_0x5b9f4f['sheen']&&_0x19664c['sheen']['parse'](_0x5b9f4f['sheen'],_0x3cc050,_0x5b6ee0),_0x5b9f4f['subSurface']&&_0x19664c['subSurface']['parse'](_0x5b9f4f['subSurface'],_0x3cc050,_0x5b6ee0),_0x19664c;},Object(_0x18e13d['c'])([Object(_0x495d06['e'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty','_albedoColor')],_0x82d5d6['prototype'],'baseColor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty','_albedoTexture')],_0x82d5d6['prototype'],'baseTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x82d5d6['prototype'],'metallic',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty')],_0x82d5d6['prototype'],'roughness',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty','_metallicTexture')],_0x82d5d6['prototype'],'metallicRoughnessTexture',void 0x0),_0x82d5d6;}(_0x532fe4);_0x3cd573['a']['RegisteredTypes']['BABYLON.PBRMetallicRoughnessMaterial']=_0x495b0c;var _0x51895b=function(_0x3231bb){function _0x9b3459(_0x449e03,_0x54bd81){var _0x40b572=_0x3231bb['call'](this,_0x449e03,_0x54bd81)||this;return _0x40b572['_useMicroSurfaceFromReflectivityMapAlpha']=!0x0,_0x40b572;}return Object(_0x18e13d['d'])(_0x9b3459,_0x3231bb),_0x9b3459['prototype']['getClassName']=function(){return'PBRSpecularGlossinessMaterial';},_0x9b3459['prototype']['clone']=function(_0x164d42){var _0x1ebcbf=this,_0x551a02=_0x495d06['a']['Clone'](function(){return new _0x9b3459(_0x164d42,_0x1ebcbf['getScene']());},this);return _0x551a02['id']=_0x164d42,_0x551a02['name']=_0x164d42,this['clearCoat']['copyTo'](_0x551a02['clearCoat']),this['anisotropy']['copyTo'](_0x551a02['anisotropy']),this['brdf']['copyTo'](_0x551a02['brdf']),this['sheen']['copyTo'](_0x551a02['sheen']),this['subSurface']['copyTo'](_0x551a02['subSurface']),_0x551a02;},_0x9b3459['prototype']['serialize']=function(){var _0x4035f7=_0x495d06['a']['Serialize'](this);return _0x4035f7['customType']='BABYLON.PBRSpecularGlossinessMaterial',_0x4035f7['clearCoat']=this['clearCoat']['serialize'](),_0x4035f7['anisotropy']=this['anisotropy']['serialize'](),_0x4035f7['brdf']=this['brdf']['serialize'](),_0x4035f7['sheen']=this['sheen']['serialize'](),_0x4035f7['subSurface']=this['subSurface']['serialize'](),_0x4035f7;},_0x9b3459['Parse']=function(_0x5b8e50,_0x1ba24c,_0x39312c){var _0x2f1c58=_0x495d06['a']['Parse'](function(){return new _0x9b3459(_0x5b8e50['name'],_0x1ba24c);},_0x5b8e50,_0x1ba24c,_0x39312c);return _0x5b8e50['clearCoat']&&_0x2f1c58['clearCoat']['parse'](_0x5b8e50['clearCoat'],_0x1ba24c,_0x39312c),_0x5b8e50['anisotropy']&&_0x2f1c58['anisotropy']['parse'](_0x5b8e50['anisotropy'],_0x1ba24c,_0x39312c),_0x5b8e50['brdf']&&_0x2f1c58['brdf']['parse'](_0x5b8e50['brdf'],_0x1ba24c,_0x39312c),_0x5b8e50['sheen']&&_0x2f1c58['sheen']['parse'](_0x5b8e50['sheen'],_0x1ba24c,_0x39312c),_0x5b8e50['subSurface']&&_0x2f1c58['subSurface']['parse'](_0x5b8e50['subSurface'],_0x1ba24c,_0x39312c),_0x2f1c58;},Object(_0x18e13d['c'])([Object(_0x495d06['e'])('diffuse'),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty','_albedoColor')],_0x9b3459['prototype'],'diffuseColor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty','_albedoTexture')],_0x9b3459['prototype'],'diffuseTexture',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['e'])('specular'),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty','_reflectivityColor')],_0x9b3459['prototype'],'specularColor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty','_microSurface')],_0x9b3459['prototype'],'glossiness',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['m'])(),Object(_0x495d06['b'])('_markAllSubMeshesAsTexturesDirty','_reflectivityTexture')],_0x9b3459['prototype'],'specularGlossinessTexture',void 0x0),_0x9b3459;}(_0x532fe4);_0x3cd573['a']['RegisteredTypes']['BABYLON.PBRSpecularGlossinessMaterial']=_0x51895b;var _0x14ee07=_0x162675(0x49),_0x4b03c9=function(_0x3f190a){function _0x11da7d(_0x24f916,_0x2465e8,_0x3e1bf7){void 0x0===_0x3e1bf7&&(_0x3e1bf7=null);var _0x40743f=_0x3f190a['call'](this,_0x2465e8)||this;if(!_0x24f916)return _0x40743f;if(_0x40743f['_textureMatrix']=_0x74d525['a']['Identity'](),_0x40743f['name']=_0x24f916,_0x40743f['url']=_0x24f916,_0x40743f['_onLoad']=_0x3e1bf7,_0x40743f['_texture']=_0x40743f['_getFromCache'](_0x24f916,!0x0),_0x40743f['_texture'])_0x40743f['_triggerOnLoad']();else{var _0x391f42=_0x40743f['getScene']();_0x391f42&&_0x391f42['useDelayedTextureLoading']?_0x40743f['delayLoadState']=_0x2103ba['a']['DELAYLOADSTATE_NOTLOADED']:_0x40743f['loadTexture']();}return _0x40743f;}return Object(_0x18e13d['d'])(_0x11da7d,_0x3f190a),_0x11da7d['prototype']['_triggerOnLoad']=function(){this['_onLoad']&&this['_onLoad']();},_0x11da7d['prototype']['getTextureMatrix']=function(){return this['_textureMatrix'];},_0x11da7d['prototype']['load3dlTexture']=function(){var _0x1de79f,_0x2c4b05=this,_0x2014fb=this['_getEngine']();_0x1de79f=0x1===_0x2014fb['webGLVersion']?_0x2014fb['createRawTexture'](null,0x1,0x1,_0x2103ba['a']['TEXTUREFORMAT_RGBA'],!0x1,!0x1,_0x2103ba['a']['TEXTURE_BILINEAR_SAMPLINGMODE'],null,_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']):_0x2014fb['createRawTexture3D'](null,0x1,0x1,0x1,_0x2103ba['a']['TEXTUREFORMAT_RGBA'],!0x1,!0x1,_0x2103ba['a']['TEXTURE_BILINEAR_SAMPLINGMODE'],null,_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),this['_texture']=_0x1de79f,this['_texture']['isReady']=!0x1,this['isCube']=!0x1,this['is3D']=_0x2014fb['webGLVersion']>0x1,this['wrapU']=_0x2103ba['a']['TEXTURE_CLAMP_ADDRESSMODE'],this['wrapV']=_0x2103ba['a']['TEXTURE_CLAMP_ADDRESSMODE'],this['wrapR']=_0x2103ba['a']['TEXTURE_CLAMP_ADDRESSMODE'],this['anisotropicFilteringLevel']=0x1;var _0x2d1381=function(_0x3738ac){if('string'==typeof _0x3738ac){for(var _0x32d1fd,_0x34f88d=null,_0x3e700f=null,_0x2d95c6=_0x3738ac['split']('\x0a'),_0x383892=0x0,_0x11efd3=0x0,_0x45e716=0x0,_0x410768=0x0,_0x3ef473=0x0,_0x586713=0x0;_0x586713<_0x2d95c6['length'];_0x586713++)if(_0x32d1fd=_0x2d95c6[_0x586713],_0x11da7d['_noneEmptyLineRegex']['test'](_0x32d1fd)&&0x0!==_0x32d1fd['indexOf']('#')){var _0x306828=_0x32d1fd['split']('\x20');if(0x0!==_0x383892){if(0x0!=_0x383892){var _0x53a419=Math['max'](parseInt(_0x306828[0x0]),0x0),_0x54a96c=Math['max'](parseInt(_0x306828[0x1]),0x0),_0x2fdefe=Math['max'](parseInt(_0x306828[0x2]),0x0);_0x3ef473=Math['max'](_0x53a419,_0x3ef473),_0x3ef473=Math['max'](_0x54a96c,_0x3ef473),_0x3ef473=Math['max'](_0x2fdefe,_0x3ef473);var _0xb4fb05=0x4*(_0x11efd3+_0x410768*_0x383892+_0x45e716*_0x383892*_0x383892);_0x3e700f&&(_0x3e700f[_0xb4fb05+0x0]=_0x53a419,_0x3e700f[_0xb4fb05+0x1]=_0x54a96c,_0x3e700f[_0xb4fb05+0x2]=_0x2fdefe),++_0x45e716%_0x383892==0x0&&(_0x45e716=0x0,++_0x410768%_0x383892==0x0&&(_0x11efd3++,_0x410768=0x0));}}else _0x383892=_0x306828['length'],_0x34f88d=new Uint8Array(_0x383892*_0x383892*_0x383892*0x4),_0x3e700f=new Float32Array(_0x383892*_0x383892*_0x383892*0x4);}if(_0x3e700f&&_0x34f88d){for(_0x586713=0x0;_0x586713<_0x3e700f['length'];_0x586713++)if(_0x586713>0x0&&(_0x586713+0x1)%0x4==0x0)_0x34f88d[_0x586713]=0xff;else{var _0x443015=_0x3e700f[_0x586713];_0x34f88d[_0x586713]=_0x443015/_0x3ef473*0xff;}}_0x1de79f['is3D']?(_0x1de79f['updateSize'](_0x383892,_0x383892,_0x383892),_0x2014fb['updateRawTexture3D'](_0x1de79f,_0x34f88d,_0x2103ba['a']['TEXTUREFORMAT_RGBA'],!0x1)):(_0x1de79f['updateSize'](_0x383892*_0x383892,_0x383892),_0x2014fb['updateRawTexture'](_0x1de79f,_0x34f88d,_0x2103ba['a']['TEXTUREFORMAT_RGBA'],!0x1)),_0x1de79f['isReady']=!0x0,_0x2c4b05['_triggerOnLoad']();}},_0x21547a=this['getScene']();return _0x21547a?_0x21547a['_loadFile'](this['url'],_0x2d1381):_0x2014fb['_loadFile'](this['url'],_0x2d1381),this['_texture'];},_0x11da7d['prototype']['loadTexture']=function(){this['url']&&this['url']['toLocaleLowerCase']()['indexOf']('.3dl')==this['url']['length']-0x4&&this['load3dlTexture']();},_0x11da7d['prototype']['clone']=function(){var _0x2293d1=new _0x11da7d(this['url'],this['getScene']()||this['_getEngine']());return _0x2293d1['level']=this['level'],_0x2293d1;},_0x11da7d['prototype']['delayLoad']=function(){this['delayLoadState']===_0x2103ba['a']['DELAYLOADSTATE_NOTLOADED']&&(this['delayLoadState']=_0x2103ba['a']['DELAYLOADSTATE_LOADED'],this['_texture']=this['_getFromCache'](this['url'],!0x0),this['_texture']||this['loadTexture']());},_0x11da7d['Parse']=function(_0x2e7e61,_0x5bfaff){var _0x27c3a7=null;return _0x2e7e61['name']&&!_0x2e7e61['isRenderTarget']&&((_0x27c3a7=new _0x11da7d(_0x2e7e61['name'],_0x5bfaff))['name']=_0x2e7e61['name'],_0x27c3a7['level']=_0x2e7e61['level']),_0x27c3a7;},_0x11da7d['prototype']['serialize']=function(){if(!this['name'])return null;var _0x3bff86={};return _0x3bff86['name']=this['name'],_0x3bff86['level']=this['level'],_0x3bff86['customType']='BABYLON.ColorGradingTexture',_0x3bff86;},_0x11da7d['_noneEmptyLineRegex']=/\S+/,_0x11da7d;}(_0x2268ea['a']);_0x3cd573['a']['RegisteredTypes']['BABYLON.ColorGradingTexture']=_0x4b03c9;var _0x5beaea=function(_0x25c45e){function _0x3fa08a(_0x418d98,_0x3a5864,_0x455dee,_0x3fa5b9,_0x45698a,_0x713d25,_0x5052c8){void 0x0===_0x3fa5b9&&(_0x3fa5b9=!0x1),void 0x0===_0x45698a&&(_0x45698a=!0x0),void 0x0===_0x713d25&&(_0x713d25=null),void 0x0===_0x5052c8&&(_0x5052c8=null);var _0x363dae=_0x25c45e['call'](this,_0x3a5864)||this;if(_0x363dae['_onLoad']=null,_0x363dae['_onError']=null,!_0x418d98)throw new Error('Image\x20url\x20is\x20not\x20set');return _0x363dae['_coordinatesMode']=_0xaf3c80['a']['CUBIC_MODE'],_0x363dae['name']=_0x418d98,_0x363dae['url']=_0x418d98,_0x363dae['_size']=_0x455dee,_0x363dae['_noMipmap']=_0x3fa5b9,_0x363dae['gammaSpace']=_0x45698a,_0x363dae['_onLoad']=_0x713d25,_0x363dae['_onError']=_0x5052c8,_0x363dae['hasAlpha']=!0x1,_0x363dae['isCube']=!0x0,_0x363dae['_texture']=_0x363dae['_getFromCache'](_0x418d98,_0x363dae['_noMipmap']),_0x363dae['_texture']?_0x713d25&&(_0x363dae['_texture']['isReady']?_0x5d754c['b']['SetImmediate'](function(){return _0x713d25();}):_0x363dae['_texture']['onLoadedObservable']['add'](_0x713d25)):_0x3a5864['useDelayedTextureLoading']?_0x363dae['delayLoadState']=_0x2103ba['a']['DELAYLOADSTATE_NOTLOADED']:_0x363dae['loadImage'](_0x363dae['loadTexture']['bind'](_0x363dae),_0x363dae['_onError']),_0x363dae;}return Object(_0x18e13d['d'])(_0x3fa08a,_0x25c45e),_0x3fa08a['prototype']['loadImage']=function(_0x1eae43,_0x304653){var _0x117da5=this,_0x3affdf=document['createElement']('canvas'),_0x4a7224=new Image();_0x4a7224['addEventListener']('load',function(){_0x117da5['_width']=_0x4a7224['width'],_0x117da5['_height']=_0x4a7224['height'],_0x3affdf['width']=_0x117da5['_width'],_0x3affdf['height']=_0x117da5['_height'];var _0x2d8bc6=_0x3affdf['getContext']('2d');_0x2d8bc6['drawImage'](_0x4a7224,0x0,0x0);var _0x35460f=_0x2d8bc6['getImageData'](0x0,0x0,_0x4a7224['width'],_0x4a7224['height']);_0x117da5['_buffer']=_0x35460f['data']['buffer'],_0x3affdf['remove'](),_0x1eae43();}),_0x4a7224['addEventListener']('error',function(_0x3ce3ab){_0x304653&&_0x304653(_0x117da5['getClassName']()+'\x20could\x20not\x20be\x20loaded',_0x3ce3ab);}),_0x4a7224['src']=this['url'];},_0x3fa08a['prototype']['loadTexture']=function(){var _0x1ac1ac=this,_0x3dafb1=this['getScene']();_0x3dafb1&&(this['_texture']=_0x3dafb1['getEngine']()['createRawCubeTextureFromUrl'](this['url'],_0x3dafb1,this['_size'],_0x2103ba['a']['TEXTUREFORMAT_RGB'],_0x3dafb1['getEngine']()['getCaps']()['textureFloat']?_0x2103ba['a']['TEXTURETYPE_FLOAT']:_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INTEGER'],this['_noMipmap'],function(){for(var _0x125876=_0x1ac1ac['getFloat32ArrayFromArrayBuffer'](_0x1ac1ac['_buffer']),_0x2fed25=_0x11ae99['ConvertPanoramaToCubemap'](_0x125876,_0x1ac1ac['_width'],_0x1ac1ac['_height'],_0x1ac1ac['_size']),_0x5dfb68=[],_0x46f124=0x0;_0x46f124<0x6;_0x46f124++){var _0x4de977=_0x2fed25[_0x3fa08a['_FacesMapping'][_0x46f124]];_0x5dfb68['push'](_0x4de977);}return _0x5dfb68;},null,this['_onLoad'],this['_onError']));},_0x3fa08a['prototype']['getFloat32ArrayFromArrayBuffer']=function(_0x27db74){for(var _0xe368b=new DataView(_0x27db74),_0x2141cd=new Float32Array(0x3*_0x27db74['byteLength']/0x4),_0x6ff993=0x0,_0x52107c=0x0;_0x52107c<_0x27db74['byteLength'];_0x52107c++)(_0x52107c+0x1)%0x4!=0x0&&(_0x2141cd[_0x6ff993++]=_0xe368b['getUint8'](_0x52107c)/0xff);return _0x2141cd;},_0x3fa08a['prototype']['getClassName']=function(){return'EquiRectangularCubeTexture';},_0x3fa08a['prototype']['clone']=function(){var _0x6d098e=this['getScene']();if(!_0x6d098e)return this;var _0x1021d1=new _0x3fa08a(this['url'],_0x6d098e,this['_size'],this['_noMipmap'],this['gammaSpace']);return _0x1021d1['level']=this['level'],_0x1021d1['wrapU']=this['wrapU'],_0x1021d1['wrapV']=this['wrapV'],_0x1021d1['coordinatesIndex']=this['coordinatesIndex'],_0x1021d1['coordinatesMode']=this['coordinatesMode'],_0x1021d1;},_0x3fa08a['_FacesMapping']=['right','left','up','down','front','back'],_0x3fa08a;}(_0x2268ea['a']),_0x2104d5=function(_0xc16fcd){function _0x44dce0(_0x5a9d86,_0x4cb4b0,_0x213d45){var _0x22994a=_0xc16fcd['call'](this,_0x213d45['scene']||_0x213d45['engine'])||this;return _0x4cb4b0&&(_0x213d45['engine']||_0x213d45['scene'])?(_0x213d45=Object(_0x18e13d['a'])(Object(_0x18e13d['a'])({},_0x44dce0['DefaultOptions']),_0x213d45),_0x22994a['_generateMipMaps']=_0x213d45['generateMipMaps'],_0x22994a['_samplingMode']=_0x213d45['samplingMode'],_0x22994a['_textureMatrix']=_0x74d525['a']['Identity'](),_0x22994a['name']=_0x5a9d86,_0x22994a['element']=_0x4cb4b0,_0x22994a['_isVideo']=_0x4cb4b0 instanceof HTMLVideoElement,_0x22994a['anisotropicFilteringLevel']=0x1,_0x22994a['_createInternalTexture'](),_0x22994a):_0x22994a;}return Object(_0x18e13d['d'])(_0x44dce0,_0xc16fcd),_0x44dce0['prototype']['_createInternalTexture']=function(){var _0x4724cf=0x0,_0xf69da0=0x0;this['_isVideo']?(_0x4724cf=this['element']['videoWidth'],_0xf69da0=this['element']['videoHeight']):(_0x4724cf=this['element']['width'],_0xf69da0=this['element']['height']);var _0x441762=this['_getEngine']();_0x441762&&(this['_texture']=_0x441762['createDynamicTexture'](_0x4724cf,_0xf69da0,this['_generateMipMaps'],this['_samplingMode'])),this['update']();},_0x44dce0['prototype']['getTextureMatrix']=function(){return this['_textureMatrix'];},_0x44dce0['prototype']['update']=function(_0x18fa4f){void 0x0===_0x18fa4f&&(_0x18fa4f=null);var _0x58736a=this['_getEngine']();if(null!=this['_texture']&&null!=_0x58736a){if(this['_isVideo']){var _0xb473e7=this['element'];if(_0xb473e7['readyState']<_0xb473e7['HAVE_CURRENT_DATA'])return;_0x58736a['updateVideoTexture'](this['_texture'],_0xb473e7,null===_0x18fa4f||_0x18fa4f);}else{var _0x41c0bc=this['element'];_0x58736a['updateDynamicTexture'](this['_texture'],_0x41c0bc,null===_0x18fa4f||_0x18fa4f,!0x1);}}},_0x44dce0['DefaultOptions']={'generateMipMaps':!0x1,'samplingMode':_0x2103ba['a']['TEXTURE_BILINEAR_SAMPLINGMODE'],'engine':null,'scene':null},_0x44dce0;}(_0x2268ea['a']),_0x4a363d=(function(){function _0x59dda3(){}return _0x59dda3['GetTGAHeader']=function(_0x5f4af4){var _0x524358=0x0;return{'id_length':_0x5f4af4[_0x524358++],'colormap_type':_0x5f4af4[_0x524358++],'image_type':_0x5f4af4[_0x524358++],'colormap_index':_0x5f4af4[_0x524358++]|_0x5f4af4[_0x524358++]<<0x8,'colormap_length':_0x5f4af4[_0x524358++]|_0x5f4af4[_0x524358++]<<0x8,'colormap_size':_0x5f4af4[_0x524358++],'origin':[_0x5f4af4[_0x524358++]|_0x5f4af4[_0x524358++]<<0x8,_0x5f4af4[_0x524358++]|_0x5f4af4[_0x524358++]<<0x8],'width':_0x5f4af4[_0x524358++]|_0x5f4af4[_0x524358++]<<0x8,'height':_0x5f4af4[_0x524358++]|_0x5f4af4[_0x524358++]<<0x8,'pixel_size':_0x5f4af4[_0x524358++],'flags':_0x5f4af4[_0x524358++]};},_0x59dda3['UploadContent']=function(_0x58d097,_0x4d11e8){if(_0x4d11e8['length']<0x13)_0x75193d['a']['Error']('Unable\x20to\x20load\x20TGA\x20file\x20-\x20Not\x20enough\x20data\x20to\x20contain\x20header');else{var _0x566264=0x12,_0x4b8adc=_0x59dda3['GetTGAHeader'](_0x4d11e8);if(_0x4b8adc['id_length']+_0x566264>_0x4d11e8['length'])_0x75193d['a']['Error']('Unable\x20to\x20load\x20TGA\x20file\x20-\x20Not\x20enough\x20data');else{_0x566264+=_0x4b8adc['id_length'];var _0x27196f,_0x491601=!0x1,_0x2e2c77=!0x1,_0x19d336=!0x1;switch(_0x4b8adc['image_type']){case _0x59dda3['_TYPE_RLE_INDEXED']:_0x491601=!0x0;case _0x59dda3['_TYPE_INDEXED']:_0x2e2c77=!0x0;break;case _0x59dda3['_TYPE_RLE_RGB']:_0x491601=!0x0;case _0x59dda3['_TYPE_RGB']:break;case _0x59dda3['_TYPE_RLE_GREY']:_0x491601=!0x0;case _0x59dda3['_TYPE_GREY']:_0x19d336=!0x0;}var _0x1ff0ff,_0x818d7e,_0x32ce57,_0x118d04,_0x578924,_0x4db29d,_0x2094f2,_0x2019c4=_0x4b8adc['pixel_size']>>0x3,_0x9706c5=_0x4b8adc['width']*_0x4b8adc['height']*_0x2019c4;if(_0x2e2c77&&(_0x1ff0ff=_0x4d11e8['subarray'](_0x566264,_0x566264+=_0x4b8adc['colormap_length']*(_0x4b8adc['colormap_size']>>0x3))),_0x491601){var _0x18992b,_0x138ea8,_0x52c859;_0x27196f=new Uint8Array(_0x9706c5);for(var _0x36def2=0x0,_0x250633=new Uint8Array(_0x2019c4);_0x566264<_0x9706c5&&_0x36def2<_0x9706c5;)if(_0x138ea8=0x1+(0x7f&(_0x18992b=_0x4d11e8[_0x566264++])),0x80&_0x18992b){for(_0x52c859=0x0;_0x52c859<_0x2019c4;++_0x52c859)_0x250633[_0x52c859]=_0x4d11e8[_0x566264++];for(_0x52c859=0x0;_0x52c859<_0x138ea8;++_0x52c859)_0x27196f['set'](_0x250633,_0x36def2+_0x52c859*_0x2019c4);_0x36def2+=_0x2019c4*_0x138ea8;}else{for(_0x138ea8*=_0x2019c4,_0x52c859=0x0;_0x52c859<_0x138ea8;++_0x52c859)_0x27196f[_0x36def2+_0x52c859]=_0x4d11e8[_0x566264++];_0x36def2+=_0x138ea8;}}else _0x27196f=_0x4d11e8['subarray'](_0x566264,_0x566264+=_0x2e2c77?_0x4b8adc['width']*_0x4b8adc['height']:_0x9706c5);switch((_0x4b8adc['flags']&_0x59dda3['_ORIGIN_MASK'])>>_0x59dda3['_ORIGIN_SHIFT']){default:case _0x59dda3['_ORIGIN_UL']:_0x818d7e=0x0,_0x118d04=0x1,_0x2094f2=_0x4b8adc['width'],_0x32ce57=0x0,_0x578924=0x1,_0x4db29d=_0x4b8adc['height'];break;case _0x59dda3['_ORIGIN_BL']:_0x818d7e=0x0,_0x118d04=0x1,_0x2094f2=_0x4b8adc['width'],_0x32ce57=_0x4b8adc['height']-0x1,_0x578924=-0x1,_0x4db29d=-0x1;break;case _0x59dda3['_ORIGIN_UR']:_0x818d7e=_0x4b8adc['width']-0x1,_0x118d04=-0x1,_0x2094f2=-0x1,_0x32ce57=0x0,_0x578924=0x1,_0x4db29d=_0x4b8adc['height'];break;case _0x59dda3['_ORIGIN_BR']:_0x818d7e=_0x4b8adc['width']-0x1,_0x118d04=-0x1,_0x2094f2=-0x1,_0x32ce57=_0x4b8adc['height']-0x1,_0x578924=-0x1,_0x4db29d=-0x1;}var _0x78e771=_0x59dda3['_getImageData'+(_0x19d336?'Grey':'')+_0x4b8adc['pixel_size']+'bits'](_0x4b8adc,_0x1ff0ff,_0x27196f,_0x32ce57,_0x578924,_0x4db29d,_0x818d7e,_0x118d04,_0x2094f2);_0x58d097['getEngine']()['_uploadDataToTextureDirectly'](_0x58d097,_0x78e771);}}},_0x59dda3['_getImageData8bits']=function(_0x46e6b7,_0x48eab7,_0x1180e9,_0x1fd317,_0x4c558d,_0x430865,_0x513c69,_0x5abded,_0x46426f){var _0x16c978,_0x4422d0,_0x5cffcc,_0x51c74c=_0x1180e9,_0x4626c3=_0x48eab7,_0x4c9616=_0x46e6b7['width'],_0x5d294f=_0x46e6b7['height'],_0x2e7bdd=0x0,_0x10f8a7=new Uint8Array(_0x4c9616*_0x5d294f*0x4);for(_0x5cffcc=_0x1fd317;_0x5cffcc!==_0x430865;_0x5cffcc+=_0x4c558d)for(_0x4422d0=_0x513c69;_0x4422d0!==_0x46426f;_0x4422d0+=_0x5abded,_0x2e7bdd++)_0x16c978=_0x51c74c[_0x2e7bdd],_0x10f8a7[0x4*(_0x4422d0+_0x4c9616*_0x5cffcc)+0x3]=0xff,_0x10f8a7[0x4*(_0x4422d0+_0x4c9616*_0x5cffcc)+0x2]=_0x4626c3[0x3*_0x16c978+0x0],_0x10f8a7[0x4*(_0x4422d0+_0x4c9616*_0x5cffcc)+0x1]=_0x4626c3[0x3*_0x16c978+0x1],_0x10f8a7[0x4*(_0x4422d0+_0x4c9616*_0x5cffcc)+0x0]=_0x4626c3[0x3*_0x16c978+0x2];return _0x10f8a7;},_0x59dda3['_getImageData16bits']=function(_0x46bc35,_0x10debc,_0x365210,_0x291a8c,_0x3ec568,_0x8c259f,_0x54b096,_0x3b7fed,_0x4ff240){var _0x2c3a31,_0x18671f,_0x31f468,_0xa0b268=_0x365210,_0x35ee6b=_0x46bc35['width'],_0x1ee04e=_0x46bc35['height'],_0x9da490=0x0,_0x3113e4=new Uint8Array(_0x35ee6b*_0x1ee04e*0x4);for(_0x31f468=_0x291a8c;_0x31f468!==_0x8c259f;_0x31f468+=_0x3ec568)for(_0x18671f=_0x54b096;_0x18671f!==_0x4ff240;_0x18671f+=_0x3b7fed,_0x9da490+=0x2){var _0x3b2f60=0xff*((0x7c00&(_0x2c3a31=_0xa0b268[_0x9da490+0x0]+(_0xa0b268[_0x9da490+0x1]<<0x8)))>>0xa)/0x1f|0x0,_0x586d70=0xff*((0x3e0&_0x2c3a31)>>0x5)/0x1f|0x0,_0x320064=0xff*(0x1f&_0x2c3a31)/0x1f|0x0;_0x3113e4[0x4*(_0x18671f+_0x35ee6b*_0x31f468)+0x0]=_0x3b2f60,_0x3113e4[0x4*(_0x18671f+_0x35ee6b*_0x31f468)+0x1]=_0x586d70,_0x3113e4[0x4*(_0x18671f+_0x35ee6b*_0x31f468)+0x2]=_0x320064,_0x3113e4[0x4*(_0x18671f+_0x35ee6b*_0x31f468)+0x3]=0x8000&_0x2c3a31?0x0:0xff;}return _0x3113e4;},_0x59dda3['_getImageData24bits']=function(_0x572ca6,_0x12de41,_0x7d5796,_0x327f3f,_0x412887,_0x3db831,_0x4f5334,_0xb4360a,_0x30d880){var _0x2a179d,_0x2bde12,_0x563759=_0x7d5796,_0x436cfe=_0x572ca6['width'],_0x160140=_0x572ca6['height'],_0x487220=0x0,_0xff2be1=new Uint8Array(_0x436cfe*_0x160140*0x4);for(_0x2bde12=_0x327f3f;_0x2bde12!==_0x3db831;_0x2bde12+=_0x412887)for(_0x2a179d=_0x4f5334;_0x2a179d!==_0x30d880;_0x2a179d+=_0xb4360a,_0x487220+=0x3)_0xff2be1[0x4*(_0x2a179d+_0x436cfe*_0x2bde12)+0x3]=0xff,_0xff2be1[0x4*(_0x2a179d+_0x436cfe*_0x2bde12)+0x2]=_0x563759[_0x487220+0x0],_0xff2be1[0x4*(_0x2a179d+_0x436cfe*_0x2bde12)+0x1]=_0x563759[_0x487220+0x1],_0xff2be1[0x4*(_0x2a179d+_0x436cfe*_0x2bde12)+0x0]=_0x563759[_0x487220+0x2];return _0xff2be1;},_0x59dda3['_getImageData32bits']=function(_0x280438,_0x15ffde,_0x27188a,_0x2074ff,_0x39b8d6,_0x203176,_0x5cda1b,_0x3b0c4b,_0x627966){var _0x43fee1,_0x353526,_0x1a1409=_0x27188a,_0x5bf22a=_0x280438['width'],_0x3ad764=_0x280438['height'],_0x447ad9=0x0,_0xddb8d0=new Uint8Array(_0x5bf22a*_0x3ad764*0x4);for(_0x353526=_0x2074ff;_0x353526!==_0x203176;_0x353526+=_0x39b8d6)for(_0x43fee1=_0x5cda1b;_0x43fee1!==_0x627966;_0x43fee1+=_0x3b0c4b,_0x447ad9+=0x4)_0xddb8d0[0x4*(_0x43fee1+_0x5bf22a*_0x353526)+0x2]=_0x1a1409[_0x447ad9+0x0],_0xddb8d0[0x4*(_0x43fee1+_0x5bf22a*_0x353526)+0x1]=_0x1a1409[_0x447ad9+0x1],_0xddb8d0[0x4*(_0x43fee1+_0x5bf22a*_0x353526)+0x0]=_0x1a1409[_0x447ad9+0x2],_0xddb8d0[0x4*(_0x43fee1+_0x5bf22a*_0x353526)+0x3]=_0x1a1409[_0x447ad9+0x3];return _0xddb8d0;},_0x59dda3['_getImageDataGrey8bits']=function(_0x67d4d7,_0x5b72cf,_0x1a614a,_0x5bded6,_0xbb18,_0x288cfa,_0xed20da,_0x556a93,_0x51de31){var _0x4300ca,_0x2da95a,_0x319eee,_0x333a33=_0x1a614a,_0x398f8e=_0x67d4d7['width'],_0x43dacb=_0x67d4d7['height'],_0x155101=0x0,_0x4a64f5=new Uint8Array(_0x398f8e*_0x43dacb*0x4);for(_0x319eee=_0x5bded6;_0x319eee!==_0x288cfa;_0x319eee+=_0xbb18)for(_0x2da95a=_0xed20da;_0x2da95a!==_0x51de31;_0x2da95a+=_0x556a93,_0x155101++)_0x4300ca=_0x333a33[_0x155101],_0x4a64f5[0x4*(_0x2da95a+_0x398f8e*_0x319eee)+0x0]=_0x4300ca,_0x4a64f5[0x4*(_0x2da95a+_0x398f8e*_0x319eee)+0x1]=_0x4300ca,_0x4a64f5[0x4*(_0x2da95a+_0x398f8e*_0x319eee)+0x2]=_0x4300ca,_0x4a64f5[0x4*(_0x2da95a+_0x398f8e*_0x319eee)+0x3]=0xff;return _0x4a64f5;},_0x59dda3['_getImageDataGrey16bits']=function(_0x339398,_0x4118ec,_0x2af133,_0x2e51eb,_0x24b96b,_0x4b9fac,_0xac877,_0x32f4ef,_0x3e7702){var _0x5610e0,_0x5aa73d,_0x32e9f1=_0x2af133,_0x2b9b14=_0x339398['width'],_0x30fdf2=_0x339398['height'],_0x50d8bf=0x0,_0x5a0127=new Uint8Array(_0x2b9b14*_0x30fdf2*0x4);for(_0x5aa73d=_0x2e51eb;_0x5aa73d!==_0x4b9fac;_0x5aa73d+=_0x24b96b)for(_0x5610e0=_0xac877;_0x5610e0!==_0x3e7702;_0x5610e0+=_0x32f4ef,_0x50d8bf+=0x2)_0x5a0127[0x4*(_0x5610e0+_0x2b9b14*_0x5aa73d)+0x0]=_0x32e9f1[_0x50d8bf+0x0],_0x5a0127[0x4*(_0x5610e0+_0x2b9b14*_0x5aa73d)+0x1]=_0x32e9f1[_0x50d8bf+0x0],_0x5a0127[0x4*(_0x5610e0+_0x2b9b14*_0x5aa73d)+0x2]=_0x32e9f1[_0x50d8bf+0x0],_0x5a0127[0x4*(_0x5610e0+_0x2b9b14*_0x5aa73d)+0x3]=_0x32e9f1[_0x50d8bf+0x1];return _0x5a0127;},_0x59dda3['_TYPE_INDEXED']=0x1,_0x59dda3['_TYPE_RGB']=0x2,_0x59dda3['_TYPE_GREY']=0x3,_0x59dda3['_TYPE_RLE_INDEXED']=0x9,_0x59dda3['_TYPE_RLE_RGB']=0xa,_0x59dda3['_TYPE_RLE_GREY']=0xb,_0x59dda3['_ORIGIN_MASK']=0x30,_0x59dda3['_ORIGIN_SHIFT']=0x4,_0x59dda3['_ORIGIN_BL']=0x0,_0x59dda3['_ORIGIN_BR']=0x1,_0x59dda3['_ORIGIN_UL']=0x2,_0x59dda3['_ORIGIN_UR']=0x3,_0x59dda3;}()),_0x1c1333=(function(){function _0x3f83e6(){this['supportCascades']=!0x1;}return _0x3f83e6['prototype']['canLoad']=function(_0x596f5c){return _0x5950ed['a']['EndsWith'](_0x596f5c,'.tga');},_0x3f83e6['prototype']['loadCubeData']=function(_0x4cd9e9,_0x3cc946,_0x5a1198,_0x282667,_0x5104bf){throw'.env\x20not\x20supported\x20in\x20Cube.';},_0x3f83e6['prototype']['loadData']=function(_0x40cf73,_0x20009d,_0x59aba3){var _0x53efd4=new Uint8Array(_0x40cf73['buffer'],_0x40cf73['byteOffset'],_0x40cf73['byteLength']),_0x57682f=_0x4a363d['GetTGAHeader'](_0x53efd4);_0x59aba3(_0x57682f['width'],_0x57682f['height'],_0x20009d['generateMipMaps'],!0x1,function(){_0x4a363d['UploadContent'](_0x20009d,_0x53efd4);});},_0x3f83e6;}());_0x300b38['a']['_TextureLoaders']['push'](new _0x1c1333());var _0xe1dfee,_0x3d12cf=function(){};!function(_0x252cb9){_0x252cb9[_0x252cb9['cTFETC1']=0x0]='cTFETC1',_0x252cb9[_0x252cb9['cTFBC1']=0x1]='cTFBC1',_0x252cb9[_0x252cb9['cTFBC4']=0x2]='cTFBC4',_0x252cb9[_0x252cb9['cTFPVRTC1_4_OPAQUE_ONLY']=0x3]='cTFPVRTC1_4_OPAQUE_ONLY',_0x252cb9[_0x252cb9['cTFBC7_M6_OPAQUE_ONLY']=0x4]='cTFBC7_M6_OPAQUE_ONLY',_0x252cb9[_0x252cb9['cTFETC2']=0x5]='cTFETC2',_0x252cb9[_0x252cb9['cTFBC3']=0x6]='cTFBC3',_0x252cb9[_0x252cb9['cTFBC5']=0x7]='cTFBC5';}(_0xe1dfee||(_0xe1dfee={}));var _0x9fc683=(function(){function _0x1bd66d(){}return _0x1bd66d['GetInternalFormatFromBasisFormat']=function(_0x353ba6){if(_0x353ba6===_0xe1dfee['cTFETC1'])return 0x8d64;if(_0x353ba6===_0xe1dfee['cTFBC1'])return 0x83f0;if(_0x353ba6===_0xe1dfee['cTFBC3'])return 0x83f3;throw'The\x20chosen\x20Basis\x20transcoder\x20format\x20is\x20not\x20currently\x20supported';},_0x1bd66d['_CreateWorkerAsync']=function(){var _0x33fb8a=this;return this['_WorkerPromise']||(this['_WorkerPromise']=new Promise(function(_0xe9acab){_0x33fb8a['_Worker']?_0xe9acab(_0x33fb8a['_Worker']):_0x5d754c['b']['LoadFileAsync'](_0x1bd66d['WasmModuleURL'])['then'](function(_0x4c7077){var _0x4ad9d3=URL['createObjectURL'](new Blob(['('+_0x2f6b11+')()'],{'type':'application/javascript'}));_0x33fb8a['_Worker']=new Worker(_0x4ad9d3);var _0x3cfd32=function(_0x2feee6){'init'===_0x2feee6['data']['action']&&(_0x33fb8a['_Worker']['removeEventListener']('message',_0x3cfd32),_0xe9acab(_0x33fb8a['_Worker']));};_0x33fb8a['_Worker']['addEventListener']('message',_0x3cfd32),_0x33fb8a['_Worker']['postMessage']({'action':'init','url':_0x1bd66d['JSModuleURL'],'wasmBinary':_0x4c7077});});})),this['_WorkerPromise'];},_0x1bd66d['TranscodeAsync']=function(_0x118b8e,_0x466061){var _0xd618c3=this,_0x57fc7f=_0x118b8e instanceof ArrayBuffer?new Uint8Array(_0x118b8e):_0x118b8e;return new Promise(function(_0x755e58,_0x4b5284){_0xd618c3['_CreateWorkerAsync']()['then'](function(){var _0x4209aa=_0xd618c3['_actionId']++,_0x27b192=function(_0x2abad7){'transcode'===_0x2abad7['data']['action']&&_0x2abad7['data']['id']===_0x4209aa&&(_0xd618c3['_Worker']['removeEventListener']('message',_0x27b192),_0x2abad7['data']['success']?_0x755e58(_0x2abad7['data']):_0x4b5284('Transcode\x20is\x20not\x20supported\x20on\x20this\x20device'));};_0xd618c3['_Worker']['addEventListener']('message',_0x27b192);var _0x421a9e=new Uint8Array(_0x57fc7f['byteLength']);_0x421a9e['set'](new Uint8Array(_0x57fc7f['buffer'],_0x57fc7f['byteOffset'],_0x57fc7f['byteLength'])),_0xd618c3['_Worker']['postMessage']({'action':'transcode','id':_0x4209aa,'imageData':_0x421a9e,'config':_0x466061,'ignoreSupportedFormats':_0xd618c3['_IgnoreSupportedFormats']},[_0x421a9e['buffer']]);});});},_0x1bd66d['LoadTextureFromTranscodeResult']=function(_0x2c54fa,_0xdbc9d9){for(var _0x4a40ac,_0x15432a=_0x2c54fa['getEngine'](),_0x57f34f=function(){if(_0x4a40ac=_0xdbc9d9['fileInfo']['images'][_0x34cdd4]['levels'][0x0],_0x2c54fa['_invertVScale']=_0x2c54fa['invertY'],-0x1===_0xdbc9d9['format']){if(_0x2c54fa['type']=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_SHORT_5_6_5'],_0x2c54fa['format']=_0x2103ba['a']['TEXTUREFORMAT_RGB'],_0x15432a['webGLVersion']<0x2&&(_0x4a0cf0['a']['Log2'](_0x4a40ac['width'])%0x1!=0x0||_0x4a0cf0['a']['Log2'](_0x4a40ac['height'])%0x1!=0x0)){var _0xfe44f7=new _0x21ea74['a'](_0x15432a,_0x21ea74['b']['Temp']);_0x2c54fa['_invertVScale']=_0x2c54fa['invertY'],_0xfe44f7['type']=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_SHORT_5_6_5'],_0xfe44f7['format']=_0x2103ba['a']['TEXTUREFORMAT_RGB'],_0xfe44f7['width']=_0x4a40ac['width']+0x3&-0x4,_0xfe44f7['height']=_0x4a40ac['height']+0x3&-0x4,_0x15432a['_bindTextureDirectly'](_0x15432a['_gl']['TEXTURE_2D'],_0xfe44f7,!0x0),_0x15432a['_uploadDataToTextureDirectly'](_0xfe44f7,_0x4a40ac['transcodedPixels'],_0x34cdd4,0x0,_0x2103ba['a']['TEXTUREFORMAT_RGB'],!0x0),_0x15432a['_rescaleTexture'](_0xfe44f7,_0x2c54fa,_0x15432a['scenes'][0x0],_0x15432a['_getInternalFormat'](_0x2103ba['a']['TEXTUREFORMAT_RGB']),function(){_0x15432a['_releaseTexture'](_0xfe44f7),_0x15432a['_bindTextureDirectly'](_0x15432a['_gl']['TEXTURE_2D'],_0x2c54fa,!0x0);});}else _0x2c54fa['_invertVScale']=!_0x2c54fa['invertY'],_0x2c54fa['width']=_0x4a40ac['width']+0x3&-0x4,_0x2c54fa['height']=_0x4a40ac['height']+0x3&-0x4,_0x15432a['_uploadDataToTextureDirectly'](_0x2c54fa,_0x4a40ac['transcodedPixels'],_0x34cdd4,0x0,_0x2103ba['a']['TEXTUREFORMAT_RGB'],!0x0);}else _0x2c54fa['width']=_0x4a40ac['width'],_0x2c54fa['height']=_0x4a40ac['height'],_0xdbc9d9['fileInfo']['images'][_0x34cdd4]['levels']['forEach'](function(_0x4c3de2,_0x2afc55){_0x15432a['_uploadCompressedDataToTextureDirectly'](_0x2c54fa,_0x1bd66d['GetInternalFormatFromBasisFormat'](_0xdbc9d9['format']),_0x4c3de2['width'],_0x4c3de2['height'],_0x4c3de2['transcodedPixels'],_0x34cdd4,_0x2afc55);}),_0x15432a['webGLVersion']<0x2&&(_0x4a0cf0['a']['Log2'](_0x2c54fa['width'])%0x1!=0x0||_0x4a0cf0['a']['Log2'](_0x2c54fa['height'])%0x1!=0x0)&&(_0x5d754c['b']['Warn']('Loaded\x20.basis\x20texture\x20width\x20and\x20height\x20are\x20not\x20a\x20power\x20of\x20two.\x20Texture\x20wrapping\x20will\x20be\x20set\x20to\x20Texture.CLAMP_ADDRESSMODE\x20as\x20other\x20modes\x20are\x20not\x20supported\x20with\x20non\x20power\x20of\x20two\x20dimensions\x20in\x20webGL\x201.'),_0x2c54fa['_cachedWrapU']=_0xaf3c80['a']['CLAMP_ADDRESSMODE'],_0x2c54fa['_cachedWrapV']=_0xaf3c80['a']['CLAMP_ADDRESSMODE']);},_0x34cdd4=0x0;_0x34cdd4<_0xdbc9d9['fileInfo']['images']['length'];_0x34cdd4++)_0x57f34f();},_0x1bd66d['_IgnoreSupportedFormats']=!0x1,_0x1bd66d['JSModuleURL']='https://preview.babylonjs.com/basisTranscoder/basis_transcoder.js',_0x1bd66d['WasmModuleURL']='https://preview.babylonjs.com/basisTranscoder/basis_transcoder.wasm',_0x1bd66d['_WorkerPromise']=null,_0x1bd66d['_Worker']=null,_0x1bd66d['_actionId']=0x0,_0x1bd66d;}());function _0x2f6b11(){var _0x2da0a7=0x0,_0x53d949=0x1,_0x7b23ec=0x5,_0x3c6446=0x6,_0x4f82a4=null;function _0x258760(_0x2f058f,_0x1895e,_0x3fd722,_0x4129d5,_0x4613de){var _0x4f1b81=_0x2f058f['getImageTranscodedSizeInBytes'](_0x1895e,_0x3fd722,_0x4129d5),_0x5b6644=new Uint8Array(_0x4f1b81);if(!_0x2f058f['transcodeImage'](_0x5b6644,_0x1895e,_0x3fd722,_0x4129d5,0x1,0x0))return null;return _0x4613de&&(_0x5b6644=function(_0x3833c2,_0x37da82,_0x3d2a7a,_0x3276c5){for(var _0x5b2b69=new Uint16Array(0x4),_0x5a54be=new Uint16Array(_0x3d2a7a*_0x3276c5),_0x3f4142=_0x3d2a7a/0x4,_0x216a4a=_0x3276c5/0x4,_0x2cfc5d=0x0;_0x2cfc5d<_0x216a4a;_0x2cfc5d++)for(var _0x21a958=0x0;_0x21a958<_0x3f4142;_0x21a958++){var _0x17772a=_0x37da82+0x8*(_0x2cfc5d*_0x3f4142+_0x21a958);_0x5b2b69[0x0]=_0x3833c2[_0x17772a]|_0x3833c2[_0x17772a+0x1]<<0x8,_0x5b2b69[0x1]=_0x3833c2[_0x17772a+0x2]|_0x3833c2[_0x17772a+0x3]<<0x8,_0x5b2b69[0x2]=(0x2*(0x1f&_0x5b2b69[0x0])+0x1*(0x1f&_0x5b2b69[0x1]))/0x3|(0x2*(0x7e0&_0x5b2b69[0x0])+0x1*(0x7e0&_0x5b2b69[0x1]))/0x3&0x7e0|(0x2*(0xf800&_0x5b2b69[0x0])+0x1*(0xf800&_0x5b2b69[0x1]))/0x3&0xf800,_0x5b2b69[0x3]=(0x2*(0x1f&_0x5b2b69[0x1])+0x1*(0x1f&_0x5b2b69[0x0]))/0x3|(0x2*(0x7e0&_0x5b2b69[0x1])+0x1*(0x7e0&_0x5b2b69[0x0]))/0x3&0x7e0|(0x2*(0xf800&_0x5b2b69[0x1])+0x1*(0xf800&_0x5b2b69[0x0]))/0x3&0xf800;for(var _0x278c73=0x0;_0x278c73<0x4;_0x278c73++){var _0x157ecc=_0x3833c2[_0x17772a+0x4+_0x278c73],_0x5a34ba=(0x4*_0x2cfc5d+_0x278c73)*_0x3d2a7a+0x4*_0x21a958;_0x5a54be[_0x5a34ba++]=_0x5b2b69[0x3&_0x157ecc],_0x5a54be[_0x5a34ba++]=_0x5b2b69[_0x157ecc>>0x2&0x3],_0x5a54be[_0x5a34ba++]=_0x5b2b69[_0x157ecc>>0x4&0x3],_0x5a54be[_0x5a34ba++]=_0x5b2b69[_0x157ecc>>0x6&0x3];}}return _0x5a54be;}(_0x5b6644,0x0,_0x2f058f['getImageWidth'](_0x1895e,_0x3fd722)+0x3&-0x4,_0x2f058f['getImageHeight'](_0x1895e,_0x3fd722)+0x3&-0x4)),_0x5b6644;}onmessage=function(_0x2e9295){if('init'===_0x2e9295['data']['action'])_0x4f82a4||(Module={'wasmBinary':_0x2e9295['data']['wasmBinary']},importScripts(_0x2e9295['data']['url']),_0x4f82a4=new Promise(function(_0x31ee35){Module['onRuntimeInitialized']=function(){Module['initializeBasis'](),_0x31ee35();};})),_0x4f82a4['then'](function(){postMessage({'action':'init'});});else{if('transcode'===_0x2e9295['data']['action']){var _0x71b91e=_0x2e9295['data']['config'],_0x29deab=_0x2e9295['data']['imageData'],_0x114b9b=new Module['BasisFile'](_0x29deab),_0x3a6e4d=function(_0x41a16a){for(var _0x49b416=_0x41a16a['getHasAlpha'](),_0x2e1738=_0x41a16a['getNumImages'](),_0x25d3ab=[],_0x11c023=0x0;_0x11c023<_0x2e1738;_0x11c023++){for(var _0x160ee4={'levels':[]},_0x34feab=_0x41a16a['getNumLevels'](_0x11c023),_0x572c58=0x0;_0x572c58<_0x34feab;_0x572c58++){var _0x52e6b4={'width':_0x41a16a['getImageWidth'](_0x11c023,_0x572c58),'height':_0x41a16a['getImageHeight'](_0x11c023,_0x572c58)};_0x160ee4['levels']['push'](_0x52e6b4);}_0x25d3ab['push'](_0x160ee4);}return{'hasAlpha':_0x49b416,'images':_0x25d3ab};}(_0x114b9b),_0x5ea6e4=_0x2e9295['data']['ignoreSupportedFormats']?null:function(_0x26e18c,_0x26f0ff){var _0x1dc0c8=null;return _0x26e18c['supportedCompressionFormats']&&(_0x26e18c['supportedCompressionFormats']['etc1']?_0x1dc0c8=_0x2da0a7:_0x26e18c['supportedCompressionFormats']['s3tc']?_0x1dc0c8=_0x26f0ff['hasAlpha']?_0x3c6446:_0x53d949:_0x26e18c['supportedCompressionFormats']['pvrtc']||_0x26e18c['supportedCompressionFormats']['etc2']&&(_0x1dc0c8=_0x7b23ec)),_0x1dc0c8;}(_0x2e9295['data']['config'],_0x3a6e4d),_0x4306ca=!0x1;null===_0x5ea6e4&&(_0x4306ca=!0x0,_0x5ea6e4=_0x3a6e4d['hasAlpha']?_0x3c6446:_0x53d949);var _0x31fb95=!0x0;_0x114b9b['startTranscoding']()||(_0x31fb95=!0x1);for(var _0x5bc958=[],_0x19e1ad=0x0;_0x19e1ad<_0x3a6e4d['images']['length']&&_0x31fb95;_0x19e1ad++){var _0x123f8d=_0x3a6e4d['images'][_0x19e1ad];if(void 0x0===_0x71b91e['loadSingleImage']||_0x71b91e['loadSingleImage']===_0x19e1ad){var _0x27a3d0=_0x123f8d['levels']['length'];!0x1===_0x71b91e['loadMipmapLevels']&&(_0x27a3d0=0x1);for(var _0x84ef9a=0x0;_0x84ef9a<_0x27a3d0;_0x84ef9a++){var _0x26865d=_0x123f8d['levels'][_0x84ef9a],_0x4e8037=_0x258760(_0x114b9b,_0x19e1ad,_0x84ef9a,_0x5ea6e4,_0x4306ca);if(!_0x4e8037){_0x31fb95=!0x1;break;}_0x26865d['transcodedPixels']=_0x4e8037,_0x5bc958['push'](_0x26865d['transcodedPixels']['buffer']);}}}_0x114b9b['close'](),_0x114b9b['delete'](),_0x4306ca&&(_0x5ea6e4=-0x1),_0x31fb95?postMessage({'action':'transcode','success':_0x31fb95,'id':_0x2e9295['data']['id'],'fileInfo':_0x3a6e4d,'format':_0x5ea6e4},_0x5bc958):postMessage({'action':'transcode','success':_0x31fb95,'id':_0x2e9295['data']['id']});}}};}var _0x5da230=(function(){function _0xeb89b3(){this['supportCascades']=!0x1;}return _0xeb89b3['prototype']['canLoad']=function(_0x4b0732){return _0x5950ed['a']['EndsWith'](_0x4b0732,'.basis');},_0xeb89b3['prototype']['loadCubeData']=function(_0x31e99b,_0x4cd927,_0x3a48d2,_0xa7ebff,_0x441164){if(!Array['isArray'](_0x31e99b)){var _0x5ebc04=_0x4cd927['getEngine']()['getCaps'](),_0xe2eec={'supportedCompressionFormats':{'etc1':!!_0x5ebc04['etc1'],'s3tc':!!_0x5ebc04['s3tc'],'pvrtc':!!_0x5ebc04['pvrtc'],'etc2':!!_0x5ebc04['etc2']}};_0x9fc683['TranscodeAsync'](_0x31e99b,_0xe2eec)['then'](function(_0x5454e3){var _0x331ffe=_0x5454e3['fileInfo']['images'][0x0]['levels']['length']>0x1&&_0x4cd927['generateMipMaps'];_0x9fc683['LoadTextureFromTranscodeResult'](_0x4cd927,_0x5454e3),_0x4cd927['getEngine']()['_setCubeMapTextureParams'](_0x4cd927,_0x331ffe),_0x4cd927['isReady']=!0x0,_0x4cd927['onLoadedObservable']['notifyObservers'](_0x4cd927),_0x4cd927['onLoadedObservable']['clear'](),_0xa7ebff&&_0xa7ebff();})['catch'](function(_0x3cc346){_0x5d754c['b']['Warn']('Failed\x20to\x20transcode\x20Basis\x20file,\x20transcoding\x20may\x20not\x20be\x20supported\x20on\x20this\x20device'),_0x4cd927['isReady']=!0x0;});}},_0xeb89b3['prototype']['loadData']=function(_0x5e1659,_0x75410c,_0x38b27a){var _0xf96c08=_0x75410c['getEngine']()['getCaps'](),_0x229bf1={'supportedCompressionFormats':{'etc1':!!_0xf96c08['etc1'],'s3tc':!!_0xf96c08['s3tc'],'pvrtc':!!_0xf96c08['pvrtc'],'etc2':!!_0xf96c08['etc2']}};_0x9fc683['TranscodeAsync'](_0x5e1659,_0x229bf1)['then'](function(_0x4a3ecb){var _0x15dd5d=_0x4a3ecb['fileInfo']['images'][0x0]['levels'][0x0],_0x11d57f=_0x4a3ecb['fileInfo']['images'][0x0]['levels']['length']>0x1&&_0x75410c['generateMipMaps'];_0x38b27a(_0x15dd5d['width'],_0x15dd5d['height'],_0x11d57f,-0x1!==_0x4a3ecb['format'],function(){_0x9fc683['LoadTextureFromTranscodeResult'](_0x75410c,_0x4a3ecb);});})['catch'](function(_0x44904b){_0x5d754c['b']['Warn']('Failed\x20to\x20transcode\x20Basis\x20file,\x20transcoding\x20may\x20not\x20be\x20supported\x20on\x20this\x20device'),_0x38b27a(0x0,0x0,!0x1,!0x1,function(){});});},_0xeb89b3;}());_0x300b38['a']['_TextureLoaders']['push'](new _0x5da230());var _0x152eb4=function(_0x3f805d){function _0x1c8199(_0x31a5e3,_0x517d47,_0x5a22da,_0x14c919,_0x58f4e5){var _0x16942d=this,_0x46c3d1=!(!_0x58f4e5||!_0x58f4e5['generateMipMaps'])&&_0x58f4e5['generateMipMaps'],_0x9e7162=!(!_0x58f4e5||!_0x58f4e5['generateDepthTexture'])&&_0x58f4e5['generateDepthTexture'],_0x3da5de=!_0x58f4e5||void 0x0===_0x58f4e5['doNotChangeAspectRatio']||_0x58f4e5['doNotChangeAspectRatio'];if((_0x16942d=_0x3f805d['call'](this,_0x31a5e3,_0x517d47,_0x14c919,_0x46c3d1,_0x3da5de)||this)['isSupported']){var _0x401ab4=[],_0x149736=[];_0x16942d['_initTypes'](_0x5a22da,_0x401ab4,_0x149736,_0x58f4e5);var _0x5a6717=!_0x58f4e5||void 0x0===_0x58f4e5['generateDepthBuffer']||_0x58f4e5['generateDepthBuffer'],_0x52e939=!(!_0x58f4e5||void 0x0===_0x58f4e5['generateStencilBuffer'])&&_0x58f4e5['generateStencilBuffer'];return _0x16942d['_size']=_0x517d47,_0x16942d['_multiRenderTargetOptions']={'samplingModes':_0x149736,'generateMipMaps':_0x46c3d1,'generateDepthBuffer':_0x5a6717,'generateStencilBuffer':_0x52e939,'generateDepthTexture':_0x9e7162,'types':_0x401ab4,'textureCount':_0x5a22da},_0x16942d['_count']=_0x5a22da,_0x16942d['_createInternalTextures'](),_0x16942d['_createTextures'](),_0x16942d;}_0x16942d['dispose']();}return Object(_0x18e13d['d'])(_0x1c8199,_0x3f805d),Object['defineProperty'](_0x1c8199['prototype'],'isSupported',{'get':function(){return this['_getEngine']()['webGLVersion']>0x1||this['_getEngine']()['getCaps']()['drawBuffersExtension'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1c8199['prototype'],'textures',{'get':function(){return this['_textures'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1c8199['prototype'],'count',{'get':function(){return this['_count'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1c8199['prototype'],'depthTexture',{'get':function(){return this['_textures'][this['_textures']['length']-0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1c8199['prototype'],'wrapU',{'set':function(_0x2be362){if(this['_textures']){for(var _0x1be418=0x0;_0x1be418=0x0;_0x3bc560--)void 0x0!==this['_internalTextures'][_0x3bc560]&&(this['_internalTextures'][_0x3bc560]['dispose'](),this['_internalTextures']['splice'](_0x3bc560,0x1));}},_0x1c8199;}(_0x310f87),_0x5e85bf=function(_0x53c92e,_0x5e7e2e,_0x1c421b){this['id']=_0x53c92e,this['scale']=_0x5e7e2e,this['offset']=_0x1c421b;},_0x3c3d20=(function(){function _0x318ae1(_0x393af1,_0x5e9bb3,_0x4ea699,_0x3b2aad){var _0x1fb9bb,_0x10476,_0x3fc929,_0x3790e7,_0x1ed937,_0xafc2c2,_0xb28cd3,_0x20d3a3,_0x24d64c,_0x34d675,_0x4544c7,_0x3f4bbd,_0x1fbee5;return this['name']=_0x393af1,this['meshes']=_0x5e9bb3,this['scene']=_0x3b2aad,this['options']=_0x4ea699,this['options']['map']=null!==(_0x1fb9bb=this['options']['map'])&&void 0x0!==_0x1fb9bb?_0x1fb9bb:['ambientTexture','bumpTexture','diffuseTexture','emissiveTexture','lightmapTexture','opacityTexture','reflectionTexture','refractionTexture','specularTexture'],this['options']['uvsIn']=null!==(_0x10476=this['options']['uvsIn'])&&void 0x0!==_0x10476?_0x10476:_0x212fbd['b']['UVKind'],this['options']['uvsOut']=null!==(_0x3fc929=this['options']['uvsOut'])&&void 0x0!==_0x3fc929?_0x3fc929:_0x212fbd['b']['UVKind'],this['options']['layout']=null!==(_0x3790e7=this['options']['layout'])&&void 0x0!==_0x3790e7?_0x3790e7:_0x318ae1['LAYOUT_STRIP'],this['options']['layout']===_0x318ae1['LAYOUT_COLNUM']&&(this['options']['colnum']=null!==(_0x1ed937=this['options']['colnum'])&&void 0x0!==_0x1ed937?_0x1ed937:0x8),this['options']['updateInputMeshes']=null===(_0xafc2c2=this['options']['updateInputMeshes'])||void 0x0===_0xafc2c2||_0xafc2c2,this['options']['disposeSources']=null===(_0xb28cd3=this['options']['disposeSources'])||void 0x0===_0xb28cd3||_0xb28cd3,this['_expecting']=0x0,this['options']['fillBlanks']=null===(_0x20d3a3=this['options']['fillBlanks'])||void 0x0===_0x20d3a3||_0x20d3a3,!0x0===this['options']['fillBlanks']&&(this['options']['customFillColor']=null!==(_0x24d64c=this['options']['customFillColor'])&&void 0x0!==_0x24d64c?_0x24d64c:'black'),this['options']['frameSize']=null!==(_0x34d675=this['options']['frameSize'])&&void 0x0!==_0x34d675?_0x34d675:0x100,this['options']['paddingRatio']=null!==(_0x4544c7=this['options']['paddingRatio'])&&void 0x0!==_0x4544c7?_0x4544c7:0.0115,this['_paddingValue']=Math['ceil'](this['options']['frameSize']*this['options']['paddingRatio']),this['_paddingValue']%0x2!=0x0&&this['_paddingValue']++,this['options']['paddingMode']=null!==(_0x3f4bbd=this['options']['paddingMode'])&&void 0x0!==_0x3f4bbd?_0x3f4bbd:_0x318ae1['SUBUV_WRAP'],this['options']['paddingMode']===_0x318ae1['SUBUV_COLOR']&&(this['options']['paddingColor']=null!==(_0x1fbee5=this['options']['paddingColor'])&&void 0x0!==_0x1fbee5?_0x1fbee5:new _0x39310d['b'](0x0,0x0,0x0,0x1)),this['sets']={},this['frames']=[],this;}return _0x318ae1['prototype']['_createFrames']=function(_0x44a7b0){for(var _0x59c455=this,_0x302c0a=this['_calculateSize'](),_0x2a5151=new _0x74d525['d'](0x1,0x1)['divide'](_0x302c0a),_0x3b8e63=0x0,_0x502506=this['_expecting'],_0x50d386=this['meshes']['length'],_0x5ccf41=Object['keys'](this['sets']),_0x499ccc=0x0;_0x499ccc<_0x5ccf41['length'];_0x499ccc++){var _0x112cdc=_0x5ccf41[_0x499ccc],_0x40cbd3=new _0x41f891['a'](this['name']+'.TexturePack.'+_0x112cdc+'Set',{'width':_0x302c0a['x'],'height':_0x302c0a['y']},this['scene'],!0x0,_0xaf3c80['a']['TRILINEAR_SAMPLINGMODE'],_0x300b38['a']['TEXTUREFORMAT_RGBA']),_0x516061=_0x40cbd3['getContext']();_0x516061['fillStyle']='rgba(0,0,0,0)',_0x516061['fillRect'](0x0,0x0,_0x302c0a['x'],_0x302c0a['y']),_0x40cbd3['update'](!0x1),this['sets'][_0x112cdc]=_0x40cbd3;}var _0x2baa18=this['options']['frameSize']||0x100,_0x8babaf=this['_paddingValue'],_0x34346b=_0x2baa18+0x2*_0x8babaf;for(_0x499ccc=0x0;_0x499ccc<_0x50d386;_0x499ccc++)for(var _0x187aaa=this['meshes'][_0x499ccc]['material'],_0x3c1bc8=function(_0x4e25c0){var _0x1dd549=new _0x41f891['a']('temp',_0x34346b,_0x74e4f4['scene'],!0x0),_0x38259f=_0x1dd549['getContext'](),_0x37f4b5=_0x74e4f4['_getFrameOffset'](_0x499ccc),_0x429134=function(){_0x3b8e63++,_0x1dd549['update'](!0x1);var _0x3b47aa=_0x38259f['getImageData'](0x0,0x0,_0x34346b,_0x34346b),_0x4c598a=_0x59c455['sets'][_0x57702c];if(_0x4c598a['getContext']()['putImageData'](_0x3b47aa,_0x302c0a['x']*_0x37f4b5['x'],_0x302c0a['y']*_0x37f4b5['y']),_0x1dd549['dispose'](),_0x4c598a['update'](!0x1),_0x3b8e63==_0x502506)return _0x59c455['_calculateMeshUVFrames'](_0x2baa18,_0x8babaf,_0x302c0a,_0x2a5151,_0x59c455['options']['updateInputMeshes']||!0x1),void _0x44a7b0();},_0x57702c=_0x5ccf41[_0x4e25c0]||'_blank';if(_0x187aaa&&null!==_0x187aaa[_0x57702c]){var _0x58809b=_0x187aaa[_0x57702c],_0xd46f74=new Image();_0x58809b instanceof _0x41f891['a']?_0xd46f74['src']=_0x58809b['getContext']()['canvas']['toDataURL']('image/png'):_0xd46f74['src']=_0x58809b['url'],_0x5d754c['b']['SetCorsBehavior'](_0xd46f74['src'],_0xd46f74),_0xd46f74['onload']=function(){_0x38259f['fillStyle']='rgba(0,0,0,0)',_0x38259f['fillRect'](0x0,0x0,_0x34346b,_0x34346b),_0x1dd549['update'](!0x1),_0x38259f['setTransform'](0x1,0x0,0x0,-0x1,0x0,0x0);var _0x21ce13=[0x0,0x0,0x1,0x0,0x1,0x1,0x0,0x1,-0x1,0x1,-0x1,0x0,-0x2,0x0,-0x1,0x1,-0x1];switch(_0x59c455['options']['paddingMode']){case 0x0:for(var _0x944e85=0x0;_0x944e85<0x9;_0x944e85++)_0x38259f['drawImage'](_0xd46f74,0x0,0x0,_0xd46f74['width'],_0xd46f74['height'],_0x8babaf+_0x2baa18*_0x21ce13[_0x944e85],_0x8babaf+_0x2baa18*_0x21ce13[_0x944e85+0x1]-_0x34346b,_0x2baa18,_0x2baa18);break;case 0x1:for(var _0x4db7d6=0x0;_0x4db7d6<_0x8babaf;_0x4db7d6++)_0x38259f['drawImage'](_0xd46f74,0x0,0x0,_0xd46f74['width'],_0xd46f74['height'],_0x4db7d6+_0x2baa18*_0x21ce13[0x0],_0x8babaf-_0x34346b,_0x2baa18,_0x2baa18),_0x38259f['drawImage'](_0xd46f74,0x0,0x0,_0xd46f74['width'],_0xd46f74['height'],0x2*_0x8babaf-_0x4db7d6,_0x8babaf-_0x34346b,_0x2baa18,_0x2baa18),_0x38259f['drawImage'](_0xd46f74,0x0,0x0,_0xd46f74['width'],_0xd46f74['height'],_0x8babaf,_0x4db7d6-_0x34346b,_0x2baa18,_0x2baa18),_0x38259f['drawImage'](_0xd46f74,0x0,0x0,_0xd46f74['width'],_0xd46f74['height'],_0x8babaf,0x2*_0x8babaf-_0x4db7d6-_0x34346b,_0x2baa18,_0x2baa18);_0x38259f['drawImage'](_0xd46f74,0x0,0x0,_0xd46f74['width'],_0xd46f74['height'],_0x8babaf+_0x2baa18*_0x21ce13[0x0],_0x8babaf+_0x2baa18*_0x21ce13[0x1]-_0x34346b,_0x2baa18,_0x2baa18);break;case 0x2:_0x38259f['fillStyle']=(_0x59c455['options']['paddingColor']||_0x39310d['a']['Black']())['toHexString'](),_0x38259f['fillRect'](0x0,0x0,_0x34346b,-_0x34346b),_0x38259f['clearRect'](_0x8babaf,_0x8babaf,_0x2baa18,_0x2baa18),_0x38259f['drawImage'](_0xd46f74,0x0,0x0,_0xd46f74['width'],_0xd46f74['height'],_0x8babaf+_0x2baa18*_0x21ce13[0x0],_0x8babaf+_0x2baa18*_0x21ce13[0x1]-_0x34346b,_0x2baa18,_0x2baa18);}_0x38259f['setTransform'](0x1,0x0,0x0,0x1,0x0,0x0),_0x429134();};}else _0x38259f['fillStyle']='rgba(0,0,0,0)',_0x74e4f4['options']['fillBlanks']&&(_0x38259f['fillStyle']=_0x74e4f4['options']['customFillColor']),_0x38259f['fillRect'](0x0,0x0,_0x34346b,_0x34346b),_0x429134();},_0x74e4f4=this,_0x12d4ce=0x0;_0x12d4ce<_0x5ccf41['length'];_0x12d4ce++)_0x3c1bc8(_0x12d4ce);},_0x318ae1['prototype']['_calculateSize']=function(){var _0xef6fec=this['meshes']['length']||0x0,_0x41a33d=this['options']['frameSize']||0x0,_0x33c447=this['_paddingValue']||0x0;switch(this['options']['layout']){case 0x0:return new _0x74d525['d'](_0x41a33d*_0xef6fec+0x2*_0x33c447*_0xef6fec,_0x41a33d+0x2*_0x33c447);case 0x1:var _0x2e7e29=Math['max'](0x2,Math['ceil'](Math['sqrt'](_0xef6fec))),_0x1e7bdf=_0x41a33d*_0x2e7e29+0x2*_0x33c447*_0x2e7e29;return new _0x74d525['d'](_0x1e7bdf,_0x1e7bdf);case 0x2:var _0x48bb0d=this['options']['colnum']||0x1,_0x3b3684=Math['max'](0x1,Math['ceil'](_0xef6fec/_0x48bb0d));return new _0x74d525['d'](_0x41a33d*_0x48bb0d+0x2*_0x33c447*_0x48bb0d,_0x41a33d*_0x3b3684+0x2*_0x33c447*_0x3b3684);}return _0x74d525['d']['Zero']();},_0x318ae1['prototype']['_calculateMeshUVFrames']=function(_0x1baf2a,_0x43c4b2,_0x1d35e5,_0x5937bf,_0x29a8a1){for(var _0xcf0f9f=this['meshes']['length'],_0x306e00=0x0;_0x306e00<_0xcf0f9f;_0x306e00++){var _0x22cdef=this['meshes'][_0x306e00],_0x58ddc5=new _0x74d525['d'](_0x1baf2a/_0x1d35e5['x'],_0x1baf2a/_0x1d35e5['y']),_0x106039=_0x5937bf['clone']()['scale'](_0x43c4b2),_0x9b2d8c=this['_getFrameOffset'](_0x306e00)['add'](_0x106039),_0x574d1d=new _0x5e85bf(_0x306e00,_0x58ddc5,_0x9b2d8c);this['frames']['push'](_0x574d1d),_0x29a8a1&&(this['_updateMeshUV'](_0x22cdef,_0x306e00),this['_updateTextureReferences'](_0x22cdef));}},_0x318ae1['prototype']['_getFrameOffset']=function(_0x128dbe){var _0x17ed2b,_0x3d161c,_0x29d38a,_0x411467=this['meshes']['length'];switch(this['options']['layout']){case 0x0:return _0x17ed2b=0x1/_0x411467,new _0x74d525['d'](_0x128dbe*_0x17ed2b,0x0);case 0x1:var _0x499b71=Math['max'](0x2,Math['ceil'](Math['sqrt'](_0x411467)));return _0x29d38a=_0x128dbe-(_0x3d161c=Math['floor'](_0x128dbe/_0x499b71))*_0x499b71,_0x17ed2b=0x1/_0x499b71,new _0x74d525['d'](_0x29d38a*_0x17ed2b,_0x3d161c*_0x17ed2b);case 0x2:var _0x413c82=this['options']['colnum']||0x1,_0x5768d3=Math['max'](0x1,Math['ceil'](_0x411467/_0x413c82));return _0x3d161c=_0x128dbe-(_0x29d38a=Math['floor'](_0x128dbe/_0x5768d3))*_0x5768d3,_0x17ed2b=new _0x74d525['d'](0x1/_0x413c82,0x1/_0x5768d3),new _0x74d525['d'](_0x29d38a*_0x17ed2b['x'],_0x3d161c*_0x17ed2b['y']);}return _0x74d525['d']['Zero']();},_0x318ae1['prototype']['_updateMeshUV']=function(_0x6b0b33,_0x5e16bc){var _0x2bf945=this['frames'][_0x5e16bc],_0x5ead26=_0x6b0b33['getVerticesData'](this['options']['uvsIn']||_0x212fbd['b']['UVKind']),_0x60deeb=[],_0x58538b=0x0;_0x5ead26['length']&&(_0x58538b=_0x5ead26['length']||0x0);for(var _0x7dba10=0x0;_0x7dba10<_0x58538b;_0x7dba10+=0x2)_0x60deeb['push'](_0x5ead26[_0x7dba10]*_0x2bf945['scale']['x']+_0x2bf945['offset']['x'],_0x5ead26[_0x7dba10+0x1]*_0x2bf945['scale']['y']+_0x2bf945['offset']['y']);_0x6b0b33['setVerticesData'](this['options']['uvsOut']||_0x212fbd['b']['UVKind'],_0x60deeb);},_0x318ae1['prototype']['_updateTextureReferences']=function(_0xd791f3,_0x33775d){void 0x0===_0x33775d&&(_0x33775d=!0x1);for(var _0x4d7c54=_0xd791f3['material'],_0x351604=Object['keys'](this['sets']),_0x234a78=function(_0x36db99){_0x36db99['dispose']&&_0x36db99['dispose']();},_0x8994ff=0x0;_0x8994ff<_0x351604['length'];_0x8994ff++){var _0x8e0aee=_0x351604[_0x8994ff];if(_0x33775d)null!==_0x4d7c54[_0x8e0aee]&&_0x234a78(_0x4d7c54[_0x8e0aee]),_0x4d7c54[_0x8e0aee]=this['sets'][_0x8e0aee];else{if(!_0x4d7c54)return;null!==_0x4d7c54[_0x8e0aee]&&(_0x234a78(_0x4d7c54[_0x8e0aee]),_0x4d7c54[_0x8e0aee]=this['sets'][_0x8e0aee]);}}},_0x318ae1['prototype']['setMeshToFrame']=function(_0x4465af,_0x4a5376,_0x13d14f){void 0x0===_0x13d14f&&(_0x13d14f=!0x1),this['_updateMeshUV'](_0x4465af,_0x4a5376),_0x13d14f&&this['_updateTextureReferences'](_0x4465af,!0x0);},_0x318ae1['prototype']['processAsync']=function(){var _0x56c216=this;return new Promise(function(_0x34d592,_0x24f8fd){try{if(0x0===_0x56c216['meshes']['length'])return void _0x34d592();for(var _0xe8e0fd=0x0,_0x562f74=function(_0x21ea9c){var _0x5c6dcf=_0x56c216['meshes'][_0x21ea9c],_0x227f6e=_0x5c6dcf['material'];if(!_0x227f6e)return++_0xe8e0fd===_0x56c216['meshes']['length']?{'value':_0x56c216['_createFrames'](_0x34d592)}:'continue';_0x227f6e['forceCompilationAsync'](_0x5c6dcf)['then'](function(){!function(_0x4c16ef){if(_0xe8e0fd++,_0x56c216['options']['map']){for(var _0x3788db=0x0;_0x3788db<_0x56c216['options']['map']['length'];_0x3788db++){null!==_0x4c16ef[_0x56c216['options']['map'][_0x3788db]]&&(_0x56c216['sets'][_0x56c216['options']['map'][_0x3788db]]||(_0x56c216['sets'][_0x56c216['options']['map'][_0x3788db]]=!0x0),_0x56c216['_expecting']++);}_0xe8e0fd===_0x56c216['meshes']['length']&&_0x56c216['_createFrames'](_0x34d592);}}(_0x227f6e);});},_0x4d24ac=0x0;_0x4d24ac<_0x56c216['meshes']['length'];_0x4d24ac++){var _0x926bc1=_0x562f74(_0x4d24ac);if('object'==typeof _0x926bc1)return _0x926bc1['value'];}}catch(_0x5dc366){return _0x24f8fd(_0x5dc366);}});},_0x318ae1['prototype']['dispose']=function(){for(var _0x3f0cdc=Object['keys'](this['sets']),_0x20d0e5=0x0;_0x20d0e5<_0x3f0cdc['length'];_0x20d0e5++){var _0x209f2e=_0x3f0cdc[_0x20d0e5];this['sets'][_0x209f2e]['dispose']();}},_0x318ae1['prototype']['download']=function(_0x5be217,_0x547ff3){var _0x48cc32=this;void 0x0===_0x5be217&&(_0x5be217='png'),void 0x0===_0x547ff3&&(_0x547ff3=0x1),setTimeout(function(){var _0x130f76={'name':_0x48cc32['name'],'sets':{},'options':{},'frames':[]},_0x866f19=Object['keys'](_0x48cc32['sets']),_0x2df8f9=Object['keys'](_0x48cc32['options']);try{for(var _0x59caf9=0x0;_0x59caf9<_0x866f19['length'];_0x59caf9++){var _0x2949d0=_0x866f19[_0x59caf9],_0x584490=_0x48cc32['sets'][_0x2949d0];_0x130f76['sets'][_0x2949d0]=_0x584490['getContext']()['canvas']['toDataURL']('image/'+_0x5be217,_0x547ff3);}for(_0x59caf9=0x0;_0x59caf9<_0x2df8f9['length'];_0x59caf9++){var _0x1702f2=_0x2df8f9[_0x59caf9];_0x130f76['options'][_0x1702f2]=_0x48cc32['options'][_0x1702f2];}for(_0x59caf9=0x0;_0x59caf9<_0x48cc32['frames']['length'];_0x59caf9++){var _0x1598ee=_0x48cc32['frames'][_0x59caf9];_0x130f76['frames']['push'](_0x1598ee['scale']['x'],_0x1598ee['scale']['y'],_0x1598ee['offset']['x'],_0x1598ee['offset']['y']);}}catch(_0x2bcf3d){return void _0x75193d['a']['Warn']('Unable\x20to\x20download:\x20'+_0x2bcf3d);}var _0x47b139='data:text/json;charset=utf-8,'+encodeURIComponent(JSON['stringify'](_0x130f76,null,0x4)),_0x53f759=document['createElement']('a');_0x53f759['setAttribute']('href',_0x47b139),_0x53f759['setAttribute']('download',_0x48cc32['name']+'_texurePackage.json'),document['body']['appendChild'](_0x53f759),_0x53f759['click'](),_0x53f759['remove']();},0x0);},_0x318ae1['prototype']['updateFromJSON']=function(_0xd24710){try{var _0x454e10=JSON['parse'](_0xd24710);this['name']=_0x454e10['name'];for(var _0x10e16a=Object['keys'](_0x454e10['options']),_0x57511c=0x0;_0x57511c<_0x10e16a['length'];_0x57511c++)this['options'][_0x10e16a[_0x57511c]]=_0x454e10['options'][_0x10e16a[_0x57511c]];for(_0x57511c=0x0;_0x57511c<_0x454e10['frames']['length'];_0x57511c+=0x4){var _0x49d928=new _0x5e85bf(_0x57511c/0x4,new _0x74d525['d'](_0x454e10['frames'][_0x57511c],_0x454e10['frames'][_0x57511c+0x1]),new _0x74d525['d'](_0x454e10['frames'][_0x57511c+0x2],_0x454e10['frames'][_0x57511c+0x3]));this['frames']['push'](_0x49d928);}var _0x56b7b0=Object['keys'](_0x454e10['sets']);for(_0x57511c=0x0;_0x57511c<_0x56b7b0['length'];_0x57511c++){var _0x2a6376=new _0xaf3c80['a'](_0x454e10['sets'][_0x56b7b0[_0x57511c]],this['scene'],!0x1,!0x1);this['sets'][_0x56b7b0[_0x57511c]]=_0x2a6376;}}catch(_0x3750db){_0x75193d['a']['Warn']('Unable\x20to\x20update\x20from\x20JSON:\x20'+_0x3750db);}},_0x318ae1['LAYOUT_STRIP']=0x0,_0x318ae1['LAYOUT_POWER2']=0x1,_0x318ae1['LAYOUT_COLNUM']=0x2,_0x318ae1['SUBUV_WRAP']=0x0,_0x318ae1['SUBUV_EXTEND']=0x1,_0x318ae1['SUBUV_COLOR']=0x2,_0x318ae1;}()),_0x1d57c9=(function(){function _0x3ad0ef(_0x286a8e){this['name']=_0x384de3['a']['NAME_PROCEDURALTEXTURE'],this['scene']=_0x286a8e,this['scene']['proceduralTextures']=new Array();}return _0x3ad0ef['prototype']['register']=function(){this['scene']['_beforeClearStage']['registerStep'](_0x384de3['a']['STEP_BEFORECLEAR_PROCEDURALTEXTURE'],this,this['_beforeClear']);},_0x3ad0ef['prototype']['rebuild']=function(){},_0x3ad0ef['prototype']['dispose']=function(){},_0x3ad0ef['prototype']['_beforeClear']=function(){if(this['scene']['proceduralTexturesEnabled']){_0x5d754c['b']['StartPerformanceCounter']('Procedural\x20textures',this['scene']['proceduralTextures']['length']>0x0);for(var _0x3e035f=0x0;_0x3e035f0x0);}},_0x3ad0ef;}()),_0x18c14a='\x0aattribute\x20vec2\x20position;\x0a\x0avarying\x20vec2\x20vPosition;\x0avarying\x20vec2\x20vUV;\x0aconst\x20vec2\x20madd=vec2(0.5,0.5);\x0avoid\x20main(void)\x20{\x0avPosition=position;\x0avUV=position*madd+madd;\x0agl_Position=vec4(position,0.0,1.0);\x0a}';_0x494b01['a']['ShadersStore']['proceduralVertexShader']=_0x18c14a;var _0x27f07d=function(_0x57ad19){function _0x2b91a8(_0x57c7e8,_0x22fdfd,_0x4a40bf,_0xf13410,_0x1aa738,_0x2dd38d,_0x171a07,_0x438f1d){void 0x0===_0x1aa738&&(_0x1aa738=null),void 0x0===_0x2dd38d&&(_0x2dd38d=!0x0),void 0x0===_0x171a07&&(_0x171a07=!0x1),void 0x0===_0x438f1d&&(_0x438f1d=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']);var _0x37616f=_0x57ad19['call'](this,null,_0xf13410,!_0x2dd38d)||this;_0x37616f['isEnabled']=!0x0,_0x37616f['autoClear']=!0x0,_0x37616f['onGeneratedObservable']=new _0x6ac1f7['c'](),_0x37616f['onBeforeGenerationObservable']=new _0x6ac1f7['c'](),_0x37616f['nodeMaterialSource']=null,_0x37616f['_textures']={},_0x37616f['_currentRefreshId']=-0x1,_0x37616f['_frameId']=-0x1,_0x37616f['_refreshRate']=0x1,_0x37616f['_vertexBuffers']={},_0x37616f['_uniforms']=new Array(),_0x37616f['_samplers']=new Array(),_0x37616f['_floats']={},_0x37616f['_ints']={},_0x37616f['_floatsArrays']={},_0x37616f['_colors3']={},_0x37616f['_colors4']={},_0x37616f['_vectors2']={},_0x37616f['_vectors3']={},_0x37616f['_matrices']={},_0x37616f['_fallbackTextureUsed']=!0x1,_0x37616f['_cachedDefines']='',_0x37616f['_contentUpdateId']=-0x1;var _0x5a4a74=(_0xf13410=_0x37616f['getScene']()||_0x44b9ce['a']['LastCreatedScene'])['_getComponent'](_0x384de3['a']['NAME_PROCEDURALTEXTURE']);_0x5a4a74||(_0x5a4a74=new _0x1d57c9(_0xf13410),_0xf13410['_addComponent'](_0x5a4a74)),_0xf13410['proceduralTextures']['push'](_0x37616f),_0x37616f['_fullEngine']=_0xf13410['getEngine'](),_0x37616f['name']=_0x57c7e8,_0x37616f['isRenderTarget']=!0x0,_0x37616f['_size']=_0x22fdfd,_0x37616f['_generateMipMaps']=_0x2dd38d,_0x37616f['setFragment'](_0x4a40bf),_0x37616f['_fallbackTexture']=_0x1aa738,_0x171a07?(_0x37616f['_texture']=_0x37616f['_fullEngine']['createRenderTargetCubeTexture'](_0x22fdfd,{'generateMipMaps':_0x2dd38d,'generateDepthBuffer':!0x1,'generateStencilBuffer':!0x1,'type':_0x438f1d}),_0x37616f['setFloat']('face',0x0)):_0x37616f['_texture']=_0x37616f['_fullEngine']['createRenderTargetTexture'](_0x22fdfd,{'generateMipMaps':_0x2dd38d,'generateDepthBuffer':!0x1,'generateStencilBuffer':!0x1,'type':_0x438f1d});var _0x5cc427=[];return _0x5cc427['push'](0x1,0x1),_0x5cc427['push'](-0x1,0x1),_0x5cc427['push'](-0x1,-0x1),_0x5cc427['push'](0x1,-0x1),_0x37616f['_vertexBuffers'][_0x212fbd['b']['PositionKind']]=new _0x212fbd['b'](_0x37616f['_fullEngine'],_0x5cc427,_0x212fbd['b']['PositionKind'],!0x1,!0x1,0x2),_0x37616f['_createIndexBuffer'](),_0x37616f;}return Object(_0x18e13d['d'])(_0x2b91a8,_0x57ad19),_0x2b91a8['prototype']['getEffect']=function(){return this['_effect'];},_0x2b91a8['prototype']['getContent']=function(){return this['_contentData']&&this['_frameId']===this['_contentUpdateId']||(this['_contentData']=this['readPixels'](0x0,0x0,this['_contentData']),this['_contentUpdateId']=this['_frameId']),this['_contentData'];},_0x2b91a8['prototype']['_createIndexBuffer']=function(){var _0x2027b6=this['_fullEngine'],_0x16017f=[];_0x16017f['push'](0x0),_0x16017f['push'](0x1),_0x16017f['push'](0x2),_0x16017f['push'](0x0),_0x16017f['push'](0x2),_0x16017f['push'](0x3),this['_indexBuffer']=_0x2027b6['createIndexBuffer'](_0x16017f);},_0x2b91a8['prototype']['_rebuild']=function(){var _0x4f34a3=this['_vertexBuffers'][_0x212fbd['b']['PositionKind']];_0x4f34a3&&_0x4f34a3['_rebuild'](),this['_createIndexBuffer'](),this['refreshRate']===_0x310f87['REFRESHRATE_RENDER_ONCE']&&(this['refreshRate']=_0x310f87['REFRESHRATE_RENDER_ONCE']);},_0x2b91a8['prototype']['reset']=function(){void 0x0!==this['_effect']&&this['_effect']['dispose']();},_0x2b91a8['prototype']['_getDefines']=function(){return'';},_0x2b91a8['prototype']['isReady']=function(){var _0x42da0c,_0x448d85=this,_0x4aad00=this['_fullEngine'];if(this['nodeMaterialSource'])return this['_effect']['isReady']();if(!this['_fragment'])return!0x1;if(this['_fallbackTextureUsed'])return!0x0;var _0x4cb8c2=this['_getDefines']();return!(!this['_effect']||_0x4cb8c2!==this['_cachedDefines']||!this['_effect']['isReady']())||(_0x42da0c=void 0x0!==this['_fragment']['fragmentElement']?{'vertex':'procedural','fragmentElement':this['_fragment']['fragmentElement']}:{'vertex':'procedural','fragment':this['_fragment']},this['_cachedDefines']=_0x4cb8c2,this['_effect']=_0x4aad00['createEffect'](_0x42da0c,[_0x212fbd['b']['PositionKind']],this['_uniforms'],this['_samplers'],_0x4cb8c2,void 0x0,void 0x0,function(){_0x448d85['releaseInternalTexture'](),_0x448d85['_fallbackTexture']&&(_0x448d85['_texture']=_0x448d85['_fallbackTexture']['_texture'],_0x448d85['_texture']&&_0x448d85['_texture']['incrementReferences']()),_0x448d85['_fallbackTextureUsed']=!0x0;}),this['_effect']['isReady']());},_0x2b91a8['prototype']['resetRefreshCounter']=function(){this['_currentRefreshId']=-0x1;},_0x2b91a8['prototype']['setFragment']=function(_0x28888f){this['_fragment']=_0x28888f;},Object['defineProperty'](_0x2b91a8['prototype'],'refreshRate',{'get':function(){return this['_refreshRate'];},'set':function(_0x405a4a){this['_refreshRate']=_0x405a4a,this['resetRefreshCounter']();},'enumerable':!0x1,'configurable':!0x0}),_0x2b91a8['prototype']['_shouldRender']=function(){return this['isEnabled']&&this['isReady']()&&this['_texture']?!this['_fallbackTextureUsed']&&(-0x1===this['_currentRefreshId']||this['refreshRate']===this['_currentRefreshId']?(this['_currentRefreshId']=0x1,this['_frameId']++,!0x0):(this['_currentRefreshId']++,!0x1)):(this['_texture']&&(this['_texture']['isReady']=!0x1),!0x1);},_0x2b91a8['prototype']['getRenderSize']=function(){return this['_size'];},_0x2b91a8['prototype']['resize']=function(_0x3f483f,_0x535ef0){this['_fallbackTextureUsed']||(this['releaseInternalTexture'](),this['_texture']=this['_fullEngine']['createRenderTargetTexture'](_0x3f483f,_0x535ef0),this['_size']=_0x3f483f,this['_generateMipMaps']=_0x535ef0);},_0x2b91a8['prototype']['_checkUniform']=function(_0x1c446e){-0x1===this['_uniforms']['indexOf'](_0x1c446e)&&this['_uniforms']['push'](_0x1c446e);},_0x2b91a8['prototype']['setTexture']=function(_0x309a0d,_0x8ad15c){return-0x1===this['_samplers']['indexOf'](_0x309a0d)&&this['_samplers']['push'](_0x309a0d),this['_textures'][_0x309a0d]=_0x8ad15c,this;},_0x2b91a8['prototype']['setFloat']=function(_0x50c721,_0x5f11f6){return this['_checkUniform'](_0x50c721),this['_floats'][_0x50c721]=_0x5f11f6,this;},_0x2b91a8['prototype']['setInt']=function(_0x659b31,_0x2a799f){return this['_checkUniform'](_0x659b31),this['_ints'][_0x659b31]=_0x2a799f,this;},_0x2b91a8['prototype']['setFloats']=function(_0x5a2054,_0x45c6ff){return this['_checkUniform'](_0x5a2054),this['_floatsArrays'][_0x5a2054]=_0x45c6ff,this;},_0x2b91a8['prototype']['setColor3']=function(_0x2e6a4c,_0x418582){return this['_checkUniform'](_0x2e6a4c),this['_colors3'][_0x2e6a4c]=_0x418582,this;},_0x2b91a8['prototype']['setColor4']=function(_0x1cbee2,_0x3f5727){return this['_checkUniform'](_0x1cbee2),this['_colors4'][_0x1cbee2]=_0x3f5727,this;},_0x2b91a8['prototype']['setVector2']=function(_0x1f1647,_0x16d284){return this['_checkUniform'](_0x1f1647),this['_vectors2'][_0x1f1647]=_0x16d284,this;},_0x2b91a8['prototype']['setVector3']=function(_0x20efa1,_0x39e011){return this['_checkUniform'](_0x20efa1),this['_vectors3'][_0x20efa1]=_0x39e011,this;},_0x2b91a8['prototype']['setMatrix']=function(_0x404e8c,_0x2a3cb7){return this['_checkUniform'](_0x404e8c),this['_matrices'][_0x404e8c]=_0x2a3cb7,this;},_0x2b91a8['prototype']['render']=function(_0x52edb7){var _0x2e1047=this['getScene']();if(_0x2e1047){var _0x4e1e4d=this['_fullEngine'];if(_0x4e1e4d['enableEffect'](this['_effect']),this['onBeforeGenerationObservable']['notifyObservers'](this),_0x4e1e4d['setState'](!0x1),!this['nodeMaterialSource']){for(var _0x28dcce in this['_textures'])this['_effect']['setTexture'](_0x28dcce,this['_textures'][_0x28dcce]);for(_0x28dcce in this['_ints'])this['_effect']['setInt'](_0x28dcce,this['_ints'][_0x28dcce]);for(_0x28dcce in this['_floats'])this['_effect']['setFloat'](_0x28dcce,this['_floats'][_0x28dcce]);for(_0x28dcce in this['_floatsArrays'])this['_effect']['setArray'](_0x28dcce,this['_floatsArrays'][_0x28dcce]);for(_0x28dcce in this['_colors3'])this['_effect']['setColor3'](_0x28dcce,this['_colors3'][_0x28dcce]);for(_0x28dcce in this['_colors4']){var _0x4aa028=this['_colors4'][_0x28dcce];this['_effect']['setFloat4'](_0x28dcce,_0x4aa028['r'],_0x4aa028['g'],_0x4aa028['b'],_0x4aa028['a']);}for(_0x28dcce in this['_vectors2'])this['_effect']['setVector2'](_0x28dcce,this['_vectors2'][_0x28dcce]);for(_0x28dcce in this['_vectors3'])this['_effect']['setVector3'](_0x28dcce,this['_vectors3'][_0x28dcce]);for(_0x28dcce in this['_matrices'])this['_effect']['setMatrix'](_0x28dcce,this['_matrices'][_0x28dcce]);}if(this['_texture']){if(this['isCube']){for(var _0x5d793e=0x0;_0x5d793e<0x6;_0x5d793e++)_0x4e1e4d['bindFramebuffer'](this['_texture'],_0x5d793e,void 0x0,void 0x0,!0x0),_0x4e1e4d['bindBuffers'](this['_vertexBuffers'],this['_indexBuffer'],this['_effect']),this['_effect']['setFloat']('face',_0x5d793e),this['autoClear']&&_0x4e1e4d['clear'](_0x2e1047['clearColor'],!0x0,!0x1,!0x1),_0x4e1e4d['drawElementsType'](_0x33c2e5['a']['TriangleFillMode'],0x0,0x6),0x5===_0x5d793e&&_0x4e1e4d['generateMipMapsForCubemap'](this['_texture']);}else _0x4e1e4d['bindFramebuffer'](this['_texture'],0x0,void 0x0,void 0x0,!0x0),_0x4e1e4d['bindBuffers'](this['_vertexBuffers'],this['_indexBuffer'],this['_effect']),this['autoClear']&&_0x4e1e4d['clear'](_0x2e1047['clearColor'],!0x0,!0x1,!0x1),_0x4e1e4d['drawElementsType'](_0x33c2e5['a']['TriangleFillMode'],0x0,0x6);_0x4e1e4d['unBindFramebuffer'](this['_texture'],this['isCube']),this['onGenerated']&&this['onGenerated'](),this['onGeneratedObservable']['notifyObservers'](this);}}},_0x2b91a8['prototype']['clone']=function(){var _0xd6b1d0=this['getSize'](),_0x5225e1=new _0x2b91a8(this['name'],_0xd6b1d0['width'],this['_fragment'],this['getScene'](),this['_fallbackTexture'],this['_generateMipMaps']);return _0x5225e1['hasAlpha']=this['hasAlpha'],_0x5225e1['level']=this['level'],_0x5225e1['coordinatesMode']=this['coordinatesMode'],_0x5225e1;},_0x2b91a8['prototype']['dispose']=function(){var _0x4fb532=this['getScene']();if(_0x4fb532){var _0x4c727a=_0x4fb532['proceduralTextures']['indexOf'](this);_0x4c727a>=0x0&&_0x4fb532['proceduralTextures']['splice'](_0x4c727a,0x1);var _0x1dee99=this['_vertexBuffers'][_0x212fbd['b']['PositionKind']];_0x1dee99&&(_0x1dee99['dispose'](),this['_vertexBuffers'][_0x212fbd['b']['PositionKind']]=null),this['_indexBuffer']&&this['_fullEngine']['_releaseBuffer'](this['_indexBuffer'])&&(this['_indexBuffer']=null),this['onGeneratedObservable']['clear'](),this['onBeforeGenerationObservable']['clear'](),_0x57ad19['prototype']['dispose']['call'](this);}},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x2b91a8['prototype'],'isEnabled',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x2b91a8['prototype'],'autoClear',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x2b91a8['prototype'],'_generateMipMaps',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x2b91a8['prototype'],'_size',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x2b91a8['prototype'],'refreshRate',null),_0x2b91a8;}(_0xaf3c80['a']);_0x3cd573['a']['RegisteredTypes']['BABYLON.ProceduralTexture']=_0x27f07d;var _0x4a929e=function(_0x3c24d2){function _0x34dbb4(_0x30b90d,_0x1afb7d,_0x10003f,_0x386482,_0x118922,_0x22bb06){var _0x202d1e=_0x3c24d2['call'](this,_0x30b90d,_0x10003f,null,_0x386482,_0x118922,_0x22bb06)||this;return _0x202d1e['_animate']=!0x0,_0x202d1e['_time']=0x0,_0x202d1e['_texturePath']=_0x1afb7d,_0x202d1e['_loadJson'](_0x1afb7d),_0x202d1e['refreshRate']=0x1,_0x202d1e;}return Object(_0x18e13d['d'])(_0x34dbb4,_0x3c24d2),_0x34dbb4['prototype']['_loadJson']=function(_0x18cc78){var _0x2eb220=this,_0x52e69f=function(){try{_0x2eb220['setFragment'](_0x2eb220['_texturePath']);}catch(_0x43bcad){_0x75193d['a']['Error']('No\x20json\x20or\x20ShaderStore\x20or\x20DOM\x20element\x20found\x20for\x20CustomProceduralTexture');}},_0x1e9894=_0x18cc78+'/config.json',_0x21e478=new _0x25cf22['a']();_0x21e478['open']('GET',_0x1e9894),_0x21e478['addEventListener']('load',function(){if(0xc8===_0x21e478['status']||_0x21e478['responseText']&&_0x21e478['responseText']['length']>0x0)try{_0x2eb220['_config']=JSON['parse'](_0x21e478['response']),_0x2eb220['updateShaderUniforms'](),_0x2eb220['updateTextures'](),_0x2eb220['setFragment'](_0x2eb220['_texturePath']+'/custom'),_0x2eb220['_animate']=_0x2eb220['_config']['animate'],_0x2eb220['refreshRate']=_0x2eb220['_config']['refreshrate'];}catch(_0x4585aa){_0x52e69f();}else _0x52e69f();},!0x1),_0x21e478['addEventListener']('error',function(){_0x52e69f();},!0x1);try{_0x21e478['send']();}catch(_0x11b921){_0x75193d['a']['Error']('CustomProceduralTexture:\x20Error\x20on\x20XHR\x20send\x20request.');}},_0x34dbb4['prototype']['isReady']=function(){if(!_0x3c24d2['prototype']['isReady']['call'](this))return!0x1;for(var _0x46a98e in this['_textures']){if(!this['_textures'][_0x46a98e]['isReady']())return!0x1;}return!0x0;},_0x34dbb4['prototype']['render']=function(_0x5b76cb){var _0x51bdd4=this['getScene']();this['_animate']&&_0x51bdd4&&(this['_time']+=0.03*_0x51bdd4['getAnimationRatio'](),this['updateShaderUniforms']()),_0x3c24d2['prototype']['render']['call'](this,_0x5b76cb);},_0x34dbb4['prototype']['updateTextures']=function(){for(var _0x4bef3a=0x0;_0x4bef3a0x0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1ac14e['prototype'],'isConnectedInVertexShader',{'get':function(){if(this['target']===_0x4e54a1['Vertex'])return!0x0;if(!this['hasEndpoints'])return!0x1;for(var _0x2f2ae0=0x0,_0x465a1b=this['_endpoints'];_0x2f2ae0<_0x465a1b['length'];_0x2f2ae0++){var _0x397cdc=_0x465a1b[_0x2f2ae0];if(_0x397cdc['ownerBlock']['target']===_0x4e54a1['Vertex'])return!0x0;if(_0x397cdc['target']===_0x4e54a1['Vertex'])return!0x0;if((_0x397cdc['ownerBlock']['target']===_0x4e54a1['Neutral']||_0x397cdc['ownerBlock']['target']===_0x4e54a1['VertexAndFragment'])&&_0x397cdc['ownerBlock']['outputs']['some'](function(_0x4c0b5a){return _0x4c0b5a['isConnectedInVertexShader'];}))return!0x0;}return!0x1;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1ac14e['prototype'],'isConnectedInFragmentShader',{'get':function(){if(this['target']===_0x4e54a1['Fragment'])return!0x0;if(!this['hasEndpoints'])return!0x1;for(var _0xa43604=0x0,_0x2cde75=this['_endpoints'];_0xa43604<_0x2cde75['length'];_0xa43604++){var _0x38780a=_0x2cde75[_0xa43604];if(_0x38780a['ownerBlock']['target']===_0x4e54a1['Fragment'])return!0x0;if((_0x38780a['ownerBlock']['target']===_0x4e54a1['Neutral']||_0x38780a['ownerBlock']['target']===_0x4e54a1['VertexAndFragment'])&&_0x38780a['ownerBlock']['outputs']['some'](function(_0x4c1080){return _0x4c1080['isConnectedInFragmentShader'];}))return!0x0;}return!0x1;},'enumerable':!0x1,'configurable':!0x0}),_0x1ac14e['prototype']['createCustomInputBlock']=function(){return null;},_0x1ac14e['prototype']['getClassName']=function(){return'NodeMaterialConnectionPoint';},_0x1ac14e['prototype']['canConnectTo']=function(_0x29754f){return this['checkCompatibilityState'](_0x29754f)===_0x530b1e['Compatible'];},_0x1ac14e['prototype']['checkCompatibilityState']=function(_0x5781d9){if(this['_ownerBlock']['target']===_0x4e54a1['Fragment']){var _0x4529b4=_0x5781d9['ownerBlock'];if(_0x4529b4['target']===_0x4e54a1['Vertex'])return _0x530b1e['TargetIncompatible'];for(var _0x10af4f=0x0,_0xb3f018=_0x4529b4['outputs'];_0x10af4f<_0xb3f018['length'];_0x10af4f++){if(_0xb3f018[_0x10af4f]['isConnectedInVertexShader'])return _0x530b1e['TargetIncompatible'];}}return this['type']!==_0x5781d9['type']&&_0x5781d9['innerType']!==_0x3bb339['AutoDetect']?_0x1ac14e['AreEquivalentTypes'](this['type'],_0x5781d9['type'])||_0x5781d9['acceptedConnectionPointTypes']&&-0x1!==_0x5781d9['acceptedConnectionPointTypes']['indexOf'](this['type'])||_0x5781d9['_acceptedConnectionPointType']&&_0x1ac14e['AreEquivalentTypes'](_0x5781d9['_acceptedConnectionPointType']['type'],this['type'])?_0x530b1e['Compatible']:_0x530b1e['TypeIncompatible']:_0x5781d9['excludedConnectionPointTypes']&&-0x1!==_0x5781d9['excludedConnectionPointTypes']['indexOf'](this['type'])?0x1:_0x530b1e['Compatible'];},_0x1ac14e['prototype']['connectTo']=function(_0x27d8be,_0x3704e0){if(void 0x0===_0x3704e0&&(_0x3704e0=!0x1),!_0x3704e0&&!this['canConnectTo'](_0x27d8be))throw'Cannot\x20connect\x20these\x20two\x20connectors.';return this['_endpoints']['push'](_0x27d8be),_0x27d8be['_connectedPoint']=this,this['_enforceAssociatedVariableName']=!0x1,this['onConnectionObservable']['notifyObservers'](_0x27d8be),_0x27d8be['onConnectionObservable']['notifyObservers'](this),this;},_0x1ac14e['prototype']['disconnectFrom']=function(_0x1d6beb){var _0x1ffd08=this['_endpoints']['indexOf'](_0x1d6beb);return-0x1===_0x1ffd08||(this['_endpoints']['splice'](_0x1ffd08,0x1),_0x1d6beb['_connectedPoint']=null,this['_enforceAssociatedVariableName']=!0x1,_0x1d6beb['_enforceAssociatedVariableName']=!0x1),this;},_0x1ac14e['prototype']['serialize']=function(_0xcfa0cc){void 0x0===_0xcfa0cc&&(_0xcfa0cc=!0x0);var _0x57c74a={};return _0x57c74a['name']=this['name'],_0x57c74a['displayName']=this['displayName'],_0xcfa0cc&&this['connectedPoint']&&(_0x57c74a['inputName']=this['name'],_0x57c74a['targetBlockId']=this['connectedPoint']['ownerBlock']['uniqueId'],_0x57c74a['targetConnectionName']=this['connectedPoint']['name'],_0x57c74a['isExposedOnFrame']=!0x0,_0x57c74a['exposedPortPosition']=this['exposedPortPosition']),(this['isExposedOnFrame']||this['exposedPortPosition']>=0x0)&&(_0x57c74a['isExposedOnFrame']=!0x0,_0x57c74a['exposedPortPosition']=this['exposedPortPosition']),_0x57c74a;},_0x1ac14e['prototype']['dispose']=function(){this['onConnectionObservable']['clear']();},_0x1ac14e;}()),_0x48d824=_0x162675(0x98),_0x52300e=(function(){function _0x403b73(_0xe9e37b,_0x3d5f7d,_0x1b0ea1,_0x3aba17){void 0x0===_0x3d5f7d&&(_0x3d5f7d=_0x4e54a1['Vertex']),void 0x0===_0x1b0ea1&&(_0x1b0ea1=!0x1),void 0x0===_0x3aba17&&(_0x3aba17=!0x1),this['_isFinalMerger']=!0x1,this['_isInput']=!0x1,this['_name']='',this['_isUnique']=!0x1,this['inputsAreExclusive']=!0x1,this['_codeVariableName']='',this['_inputs']=new Array(),this['_outputs']=new Array(),this['comments']='',this['visibleInInspector']=!0x1,this['_target']=_0x3d5f7d,this['_isFinalMerger']=_0x1b0ea1,this['_isInput']=_0x3aba17,this['_name']=_0xe9e37b,this['uniqueId']=_0x48d824['a']['UniqueId'];}return Object['defineProperty'](_0x403b73['prototype'],'name',{'get':function(){return this['_name'];},'set':function(_0x12debd){this['validateBlockName'](_0x12debd)&&(this['_name']=_0x12debd);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x403b73['prototype'],'isUnique',{'get':function(){return this['_isUnique'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x403b73['prototype'],'isFinalMerger',{'get':function(){return this['_isFinalMerger'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x403b73['prototype'],'isInput',{'get':function(){return this['_isInput'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x403b73['prototype'],'buildId',{'get':function(){return this['_buildId'];},'set':function(_0x2753f5){this['_buildId']=_0x2753f5;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x403b73['prototype'],'target',{'get':function(){return this['_target'];},'set':function(_0x4b6d53){0x0==(this['_target']&_0x4b6d53)&&(this['_target']=_0x4b6d53);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x403b73['prototype'],'inputs',{'get':function(){return this['_inputs'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x403b73['prototype'],'outputs',{'get':function(){return this['_outputs'];},'enumerable':!0x1,'configurable':!0x0}),_0x403b73['prototype']['getInputByName']=function(_0x2a5324){var _0x1a7ea4=this['_inputs']['filter'](function(_0x42b516){return _0x42b516['name']===_0x2a5324;});return _0x1a7ea4['length']?_0x1a7ea4[0x0]:null;},_0x403b73['prototype']['getOutputByName']=function(_0x513375){var _0x9af7bd=this['_outputs']['filter'](function(_0x344529){return _0x344529['name']===_0x513375;});return _0x9af7bd['length']?_0x9af7bd[0x0]:null;},_0x403b73['prototype']['initialize']=function(_0x24f2e3){},_0x403b73['prototype']['bind']=function(_0x290ebd,_0x2fbcf0,_0xb7a2e0,_0xb57df4){},_0x403b73['prototype']['_declareOutput']=function(_0x3a32e3,_0x3abdab){return _0x3abdab['_getGLType'](_0x3a32e3['type'])+'\x20'+_0x3a32e3['associatedVariableName'];},_0x403b73['prototype']['_writeVariable']=function(_0x3f6943){return _0x3f6943['connectedPoint']?''+_0x3f6943['associatedVariableName']:'0.';},_0x403b73['prototype']['_writeFloat']=function(_0x59462d){var _0x3c0403=_0x59462d['toString']();return-0x1===_0x3c0403['indexOf']('.')&&(_0x3c0403+='.0'),''+_0x3c0403;},_0x403b73['prototype']['getClassName']=function(){return'NodeMaterialBlock';},_0x403b73['prototype']['registerInput']=function(_0x1dd2fd,_0x4e10bc,_0x9bb7c0,_0xd540c6,_0x296cf0){return void 0x0===_0x9bb7c0&&(_0x9bb7c0=!0x1),(_0x296cf0=null!=_0x296cf0?_0x296cf0:new _0x33b7d2(_0x1dd2fd,this,_0x13ce46['Input']))['type']=_0x4e10bc,_0x296cf0['isOptional']=_0x9bb7c0,_0xd540c6&&(_0x296cf0['target']=_0xd540c6),this['_inputs']['push'](_0x296cf0),this;},_0x403b73['prototype']['registerOutput']=function(_0x2c4e9a,_0x32fc7c,_0x30875c,_0xd6bf81){return(_0xd6bf81=null!=_0xd6bf81?_0xd6bf81:new _0x33b7d2(_0x2c4e9a,this,_0x13ce46['Output']))['type']=_0x32fc7c,_0x30875c&&(_0xd6bf81['target']=_0x30875c),this['_outputs']['push'](_0xd6bf81),this;},_0x403b73['prototype']['getFirstAvailableInput']=function(_0xc8d0a9){void 0x0===_0xc8d0a9&&(_0xc8d0a9=null);for(var _0x380b6b=0x0,_0x5b788a=this['_inputs'];_0x380b6b<_0x5b788a['length'];_0x380b6b++){var _0x21efbf=_0x5b788a[_0x380b6b];if(!(_0x21efbf['connectedPoint']||_0xc8d0a9&&_0xc8d0a9['type']!==_0x21efbf['type']&&_0x21efbf['type']!==_0x3bb339['AutoDetect']))return _0x21efbf;}return null;},_0x403b73['prototype']['getFirstAvailableOutput']=function(_0x25c9e4){void 0x0===_0x25c9e4&&(_0x25c9e4=null);for(var _0x32331c=0x0,_0x13c66d=this['_outputs'];_0x32331c<_0x13c66d['length'];_0x32331c++){var _0x19fc34=_0x13c66d[_0x32331c];if(!_0x25c9e4||!_0x25c9e4['target']||_0x25c9e4['target']===_0x4e54a1['Neutral']||0x0!=(_0x25c9e4['target']&_0x19fc34['target']))return _0x19fc34;}return null;},_0x403b73['prototype']['getSiblingOutput']=function(_0x1e43f8){var _0x395499=this['_outputs']['indexOf'](_0x1e43f8);return-0x1===_0x395499||_0x395499>=this['_outputs']['length']?null:this['_outputs'][_0x395499+0x1];},_0x403b73['prototype']['connectTo']=function(_0x5425e0,_0x1c4260){if(0x0!==this['_outputs']['length']){for(var _0x4b6820=_0x1c4260&&_0x1c4260['output']?this['getOutputByName'](_0x1c4260['output']):this['getFirstAvailableOutput'](_0x5425e0),_0x5b182a=!0x0;_0x5b182a;){var _0x23dca6=_0x1c4260&&_0x1c4260['input']?_0x5425e0['getInputByName'](_0x1c4260['input']):_0x5425e0['getFirstAvailableInput'](_0x4b6820);if(_0x4b6820&&_0x23dca6&&_0x4b6820['canConnectTo'](_0x23dca6))_0x4b6820['connectTo'](_0x23dca6),_0x5b182a=!0x1;else{if(!_0x4b6820)throw'Unable\x20to\x20find\x20a\x20compatible\x20match';_0x4b6820=this['getSiblingOutput'](_0x4b6820);}}return this;}},_0x403b73['prototype']['_buildBlock']=function(_0x59b1e3){},_0x403b73['prototype']['updateUniformsAndSamples']=function(_0x48c7fb,_0x5837bf,_0x1c5b59,_0x3e4524){},_0x403b73['prototype']['provideFallbacks']=function(_0x269e22,_0x5c67ad){},_0x403b73['prototype']['initializeDefines']=function(_0x50dfe8,_0x1133f4,_0x3ee137,_0x94f34a){void 0x0===_0x94f34a&&(_0x94f34a=!0x1);},_0x403b73['prototype']['prepareDefines']=function(_0x9d51bb,_0x2908f7,_0x3b041c,_0x5ef18b,_0x3b8fb2){void 0x0===_0x5ef18b&&(_0x5ef18b=!0x1);},_0x403b73['prototype']['autoConfigure']=function(_0x353884){},_0x403b73['prototype']['replaceRepeatableContent']=function(_0x2b17b2,_0x442c57,_0x1d0956,_0xe6b159){},_0x403b73['prototype']['isReady']=function(_0x4349d9,_0x438e9e,_0x108cc4,_0x580f7b){return void 0x0===_0x580f7b&&(_0x580f7b=!0x1),!0x0;},_0x403b73['prototype']['_linkConnectionTypes']=function(_0x1e98a4,_0x5ded6e,_0x5c17b6){void 0x0===_0x5c17b6&&(_0x5c17b6=!0x1),_0x5c17b6?this['_inputs'][_0x5ded6e]['_acceptedConnectionPointType']=this['_inputs'][_0x1e98a4]:this['_inputs'][_0x1e98a4]['_linkedConnectionSource']=this['_inputs'][_0x5ded6e],this['_inputs'][_0x5ded6e]['_linkedConnectionSource']=this['_inputs'][_0x1e98a4];},_0x403b73['prototype']['_processBuild']=function(_0x213704,_0x5caec5,_0x3e597e,_0xec24ca){_0x213704['build'](_0x5caec5,_0xec24ca);var _0x2f2631=null!=_0x5caec5['_vertexState'],_0x169732=_0x213704['_buildTarget']===_0x4e54a1['Vertex']&&_0x213704['target']!==_0x4e54a1['VertexAndFragment'];if(_0x2f2631&&(0x0==(_0x213704['target']&_0x213704['_buildTarget'])||0x0==(_0x213704['target']&_0x3e597e['target'])||this['target']!==_0x4e54a1['VertexAndFragment']&&_0x169732)&&(!_0x213704['isInput']&&_0x5caec5['target']!==_0x213704['_buildTarget']||_0x213704['isInput']&&_0x213704['isAttribute']&&!_0x213704['_noContextSwitch'])){var _0x221734=_0x3e597e['connectedPoint'];_0x5caec5['_vertexState']['_emitVaryingFromString']('v_'+_0x221734['associatedVariableName'],_0x5caec5['_getGLType'](_0x221734['type']))&&(_0x5caec5['_vertexState']['compilationString']+='v_'+_0x221734['associatedVariableName']+'\x20=\x20'+_0x221734['associatedVariableName']+';\x0d\x0a'),_0x3e597e['associatedVariableName']='v_'+_0x221734['associatedVariableName'],_0x3e597e['_enforceAssociatedVariableName']=!0x0;}},_0x403b73['prototype']['validateBlockName']=function(_0x5c7501){for(var _0x3d123b=0x0,_0x1fb2f6=['position','normal','tangent','particle_positionw','uv','uv2','position2d','particle_uv','matricesIndices','matricesWeights','world0','world1','world2','world3','particle_color','particle_texturemask'];_0x3d123b<_0x1fb2f6['length'];_0x3d123b++){if(_0x5c7501===_0x1fb2f6[_0x3d123b])return!0x1;}return!0x0;},_0x403b73['prototype']['build']=function(_0x36480f,_0x432be0){if(this['_buildId']===_0x36480f['sharedData']['buildId'])return!0x0;if(!this['isInput'])for(var _0x1bbf8f=0x0,_0x42ea00=this['_outputs'];_0x1bbf8f<_0x42ea00['length'];_0x1bbf8f++){(_0x45179b=_0x42ea00[_0x1bbf8f])['associatedVariableName']||(_0x45179b['associatedVariableName']=_0x36480f['_getFreeVariableName'](_0x45179b['name']));}for(var _0x224564=0x0,_0x21dbc6=this['_inputs'];_0x224564<_0x21dbc6['length'];_0x224564++){var _0x2f9ac8=_0x21dbc6[_0x224564];if(_0x2f9ac8['connectedPoint']){if(this['target']!==_0x4e54a1['Neutral']){if(0x0==(_0x2f9ac8['target']&this['target']))continue;if(0x0==(_0x2f9ac8['target']&_0x36480f['target']))continue;}(_0x2b627e=_0x2f9ac8['connectedPoint']['ownerBlock'])&&_0x2b627e!==this&&this['_processBuild'](_0x2b627e,_0x36480f,_0x2f9ac8,_0x432be0);}else _0x2f9ac8['isOptional']||_0x36480f['sharedData']['checks']['notConnectedNonOptionalInputs']['push'](_0x2f9ac8);}if(this['_buildId']===_0x36480f['sharedData']['buildId'])return!0x0;if(_0x36480f['sharedData']['verbose']&&console['log']((_0x36480f['target']===_0x4e54a1['Vertex']?'Vertex\x20shader':'Fragment\x20shader')+':\x20Building\x20'+this['name']+'\x20['+this['getClassName']()+']'),this['isFinalMerger'])switch(_0x36480f['target']){case _0x4e54a1['Vertex']:_0x36480f['sharedData']['checks']['emitVertex']=!0x0;break;case _0x4e54a1['Fragment']:_0x36480f['sharedData']['checks']['emitFragment']=!0x0;}!this['isInput']&&_0x36480f['sharedData']['emitComments']&&(_0x36480f['compilationString']+='\x0d\x0a//'+this['name']+'\x0d\x0a'),this['_buildBlock'](_0x36480f),this['_buildId']=_0x36480f['sharedData']['buildId'],this['_buildTarget']=_0x36480f['target'];for(var _0x2a938f=0x0,_0xa7228a=this['_outputs'];_0x2a938f<_0xa7228a['length'];_0x2a938f++){var _0x45179b;if(0x0!=((_0x45179b=_0xa7228a[_0x2a938f])['target']&_0x36480f['target']))for(var _0x191230=0x0,_0x12cdc3=_0x45179b['endpoints'];_0x191230<_0x12cdc3['length'];_0x191230++){var _0x2b627e,_0x92dc72=_0x12cdc3[_0x191230];(_0x2b627e=_0x92dc72['ownerBlock'])&&0x0!=(_0x2b627e['target']&_0x36480f['target'])&&-0x1!==_0x432be0['indexOf'](_0x2b627e)&&this['_processBuild'](_0x2b627e,_0x36480f,_0x92dc72,_0x432be0);}}return!0x1;},_0x403b73['prototype']['_inputRename']=function(_0x9b7c63){return _0x9b7c63;},_0x403b73['prototype']['_outputRename']=function(_0x38d0a5){return _0x38d0a5;},_0x403b73['prototype']['_dumpPropertiesCode']=function(){return this['_codeVariableName']+'.visibleInInspector\x20=\x20'+this['visibleInInspector']+';\x0d\x0a';},_0x403b73['prototype']['_dumpCode']=function(_0x2297b8,_0x995dee){var _0x3e8544;_0x995dee['push'](this);var _0x2d2df7=this['name']['replace'](/[^A-Za-z_]+/g,'');if(this['_codeVariableName']=_0x2d2df7||this['getClassName']()+'_'+this['uniqueId'],-0x1!==_0x2297b8['indexOf'](this['_codeVariableName'])){var _0x469296=0x0;do{_0x469296++,this['_codeVariableName']=_0x2d2df7+_0x469296;}while(-0x1!==_0x2297b8['indexOf'](this['_codeVariableName']));}_0x2297b8['push'](this['_codeVariableName']),_0x3e8544='\x0d\x0a//\x20'+this['getClassName']()+'\x0d\x0a',this['comments']&&(_0x3e8544+='//\x20'+this['comments']+'\x0d\x0a'),_0x3e8544+='var\x20'+this['_codeVariableName']+'\x20=\x20new\x20BABYLON.'+this['getClassName']()+'(\x22'+this['name']+'\x22);\x0d\x0a',_0x3e8544+=this['_dumpPropertiesCode']();for(var _0x3bf4ac=0x0,_0xd9d284=this['inputs'];_0x3bf4ac<_0xd9d284['length'];_0x3bf4ac++){var _0x3ed3dd=_0xd9d284[_0x3bf4ac];if(_0x3ed3dd['isConnected']){var _0x2bc793=_0x3ed3dd['connectedPoint']['ownerBlock'];-0x1===_0x995dee['indexOf'](_0x2bc793)&&(_0x3e8544+=_0x2bc793['_dumpCode'](_0x2297b8,_0x995dee));}}for(var _0x2edc5a=0x0,_0x4103e1=this['outputs'];_0x2edc5a<_0x4103e1['length'];_0x2edc5a++){var _0x5a84c3=_0x4103e1[_0x2edc5a];if(_0x5a84c3['hasEndpoints'])for(var _0x57af4c=0x0,_0x2ab328=_0x5a84c3['endpoints'];_0x57af4c<_0x2ab328['length'];_0x57af4c++){(_0x2bc793=_0x2ab328[_0x57af4c]['ownerBlock'])&&-0x1===_0x995dee['indexOf'](_0x2bc793)&&(_0x3e8544+=_0x2bc793['_dumpCode'](_0x2297b8,_0x995dee));}}return _0x3e8544;},_0x403b73['prototype']['_dumpCodeForOutputConnections']=function(_0x28e0fc){var _0x176d7a='';if(-0x1!==_0x28e0fc['indexOf'](this))return _0x176d7a;_0x28e0fc['push'](this);for(var _0x571843=0x0,_0x13b797=this['inputs'];_0x571843<_0x13b797['length'];_0x571843++){var _0x4366c0=_0x13b797[_0x571843];if(_0x4366c0['isConnected']){var _0x23ee57=_0x4366c0['connectedPoint'],_0x3ab53b=_0x23ee57['ownerBlock'];_0x176d7a+=_0x3ab53b['_dumpCodeForOutputConnections'](_0x28e0fc),_0x176d7a+=_0x3ab53b['_codeVariableName']+'.'+_0x3ab53b['_outputRename'](_0x23ee57['name'])+'.connectTo('+this['_codeVariableName']+'.'+this['_inputRename'](_0x4366c0['name'])+');\x0d\x0a';}}return _0x176d7a;},_0x403b73['prototype']['clone']=function(_0x1e2e24,_0x247670){void 0x0===_0x247670&&(_0x247670='');var _0x3b3a16=this['serialize'](),_0x19dfaf=_0x3cd573['a']['GetClass'](_0x3b3a16['customType']);if(_0x19dfaf){var _0x3fd485=new _0x19dfaf();return _0x3fd485['_deserialize'](_0x3b3a16,_0x1e2e24,_0x247670),_0x3fd485;}return null;},_0x403b73['prototype']['serialize']=function(){var _0x541ea6={};_0x541ea6['customType']='BABYLON.'+this['getClassName'](),_0x541ea6['id']=this['uniqueId'],_0x541ea6['name']=this['name'],_0x541ea6['comments']=this['comments'],_0x541ea6['visibleInInspector']=this['visibleInInspector'],_0x541ea6['inputs']=[],_0x541ea6['outputs']=[];for(var _0x214a2f=0x0,_0x5384a3=this['inputs'];_0x214a2f<_0x5384a3['length'];_0x214a2f++){var _0x42a980=_0x5384a3[_0x214a2f];_0x541ea6['inputs']['push'](_0x42a980['serialize']());}for(var _0x448e4b=0x0,_0x542c92=this['outputs'];_0x448e4b<_0x542c92['length'];_0x448e4b++){var _0x3de3f5=_0x542c92[_0x448e4b];_0x541ea6['outputs']['push'](_0x3de3f5['serialize'](!0x1));}return _0x541ea6;},_0x403b73['prototype']['_deserialize']=function(_0x12b2f8,_0x588d22,_0xbe269e){this['name']=_0x12b2f8['name'],this['comments']=_0x12b2f8['comments'],this['visibleInInspector']=!!_0x12b2f8['visibleInInspector'],this['_deserializePortDisplayNamesAndExposedOnFrame'](_0x12b2f8);},_0x403b73['prototype']['_deserializePortDisplayNamesAndExposedOnFrame']=function(_0x3d16d0){var _0x11c2f1=this,_0x40144b=_0x3d16d0['inputs'],_0x39c052=_0x3d16d0['outputs'];_0x40144b&&_0x40144b['forEach'](function(_0x22518a,_0x23b2fe){_0x22518a['displayName']&&(_0x11c2f1['inputs'][_0x23b2fe]['displayName']=_0x22518a['displayName']),_0x22518a['isExposedOnFrame']&&(_0x11c2f1['inputs'][_0x23b2fe]['isExposedOnFrame']=_0x22518a['isExposedOnFrame'],_0x11c2f1['inputs'][_0x23b2fe]['exposedPortPosition']=_0x22518a['exposedPortPosition']);}),_0x39c052&&_0x39c052['forEach'](function(_0xaaaba4,_0x2a2945){_0xaaaba4['displayName']&&(_0x11c2f1['outputs'][_0x2a2945]['displayName']=_0xaaaba4['displayName']),_0xaaaba4['isExposedOnFrame']&&(_0x11c2f1['outputs'][_0x2a2945]['isExposedOnFrame']=_0xaaaba4['isExposedOnFrame'],_0x11c2f1['outputs'][_0x2a2945]['exposedPortPosition']=_0xaaaba4['exposedPortPosition']);});},_0x403b73['prototype']['dispose']=function(){for(var _0x504b61=0x0,_0x155c82=this['inputs'];_0x504b61<_0x155c82['length'];_0x504b61++){_0x155c82[_0x504b61]['dispose']();}for(var _0x4a81a4=0x0,_0x513363=this['outputs'];_0x4a81a4<_0x513363['length'];_0x4a81a4++){_0x513363[_0x4a81a4]['dispose']();}},_0x403b73;}()),_0x39c704=(function(){function _0x4dd80d(){this['supportUniformBuffers']=!0x1,this['attributes']=new Array(),this['uniforms']=new Array(),this['constants']=new Array(),this['samplers']=new Array(),this['functions']={},this['extensions']={},this['counters']={},this['_attributeDeclaration']='',this['_uniformDeclaration']='',this['_constantDeclaration']='',this['_samplerDeclaration']='',this['_varyingTransfer']='',this['_injectAtEnd']='',this['_repeatableContentAnchorIndex']=0x0,this['_builtCompilationString']='',this['compilationString']='';}return _0x4dd80d['prototype']['finalize']=function(_0x3a51af){var _0x4b5d81=_0x3a51af['sharedData']['emitComments'],_0x2d0ffb=this['target']===_0x4e54a1['Fragment'];this['compilationString']='\x0d\x0a'+(_0x4b5d81?'//Entry\x20point\x0d\x0a':'')+'void\x20main(void)\x20{\x0d\x0a'+this['compilationString'],this['_constantDeclaration']&&(this['compilationString']='\x0d\x0a'+(_0x4b5d81?'//Constants\x0d\x0a':'')+this['_constantDeclaration']+'\x0d\x0a'+this['compilationString']);var _0x4113db='';for(var _0x52e4a4 in this['functions'])_0x4113db+=this['functions'][_0x52e4a4]+'\x0d\x0a';for(var _0x27af86 in(this['compilationString']='\x0d\x0a'+_0x4113db+'\x0d\x0a'+this['compilationString'],!_0x2d0ffb&&this['_varyingTransfer']&&(this['compilationString']=this['compilationString']+'\x0d\x0a'+this['_varyingTransfer']),this['_injectAtEnd']&&(this['compilationString']=this['compilationString']+'\x0d\x0a'+this['_injectAtEnd']),this['compilationString']=this['compilationString']+'\x0d\x0a}',this['sharedData']['varyingDeclaration']&&(this['compilationString']='\x0d\x0a'+(_0x4b5d81?'//Varyings\x0d\x0a':'')+this['sharedData']['varyingDeclaration']+'\x0d\x0a'+this['compilationString']),this['_samplerDeclaration']&&(this['compilationString']='\x0d\x0a'+(_0x4b5d81?'//Samplers\x0d\x0a':'')+this['_samplerDeclaration']+'\x0d\x0a'+this['compilationString']),this['_uniformDeclaration']&&(this['compilationString']='\x0d\x0a'+(_0x4b5d81?'//Uniforms\x0d\x0a':'')+this['_uniformDeclaration']+'\x0d\x0a'+this['compilationString']),this['_attributeDeclaration']&&!_0x2d0ffb&&(this['compilationString']='\x0d\x0a'+(_0x4b5d81?'//Attributes\x0d\x0a':'')+this['_attributeDeclaration']+'\x0d\x0a'+this['compilationString']),this['compilationString']='precision\x20highp\x20float;\x0d\x0a'+this['compilationString'],this['extensions'])){var _0x402f74=this['extensions'][_0x27af86];this['compilationString']='\x0d\x0a'+_0x402f74+'\x0d\x0a'+this['compilationString'];}this['_builtCompilationString']=this['compilationString'];},Object['defineProperty'](_0x4dd80d['prototype'],'_repeatableContentAnchor',{'get':function(){return'###___ANCHOR'+this['_repeatableContentAnchorIndex']++ +'___###';},'enumerable':!0x1,'configurable':!0x0}),_0x4dd80d['prototype']['_getFreeVariableName']=function(_0x2dc289){return _0x2dc289=_0x2dc289['replace'](/[^a-zA-Z_]+/g,''),void 0x0===this['sharedData']['variableNames'][_0x2dc289]?(this['sharedData']['variableNames'][_0x2dc289]=0x0,'output'===_0x2dc289||'texture'===_0x2dc289?_0x2dc289+this['sharedData']['variableNames'][_0x2dc289]:_0x2dc289):(this['sharedData']['variableNames'][_0x2dc289]++,_0x2dc289+this['sharedData']['variableNames'][_0x2dc289]);},_0x4dd80d['prototype']['_getFreeDefineName']=function(_0x555355){return void 0x0===this['sharedData']['defineNames'][_0x555355]?this['sharedData']['defineNames'][_0x555355]=0x0:this['sharedData']['defineNames'][_0x555355]++,_0x555355+this['sharedData']['defineNames'][_0x555355];},_0x4dd80d['prototype']['_excludeVariableName']=function(_0x196f75){this['sharedData']['variableNames'][_0x196f75]=0x0;},_0x4dd80d['prototype']['_emit2DSampler']=function(_0x304fb6){this['samplers']['indexOf'](_0x304fb6)<0x0&&(this['_samplerDeclaration']+='uniform\x20sampler2D\x20'+_0x304fb6+';\x0d\x0a',this['samplers']['push'](_0x304fb6));},_0x4dd80d['prototype']['_getGLType']=function(_0x9c88e0){switch(_0x9c88e0){case _0x3bb339['Float']:return'float';case _0x3bb339['Int']:return'int';case _0x3bb339['Vector2']:return'vec2';case _0x3bb339['Color3']:case _0x3bb339['Vector3']:return'vec3';case _0x3bb339['Color4']:case _0x3bb339['Vector4']:return'vec4';case _0x3bb339['Matrix']:return'mat4';}return'';},_0x4dd80d['prototype']['_emitExtension']=function(_0x5d7247,_0x54ad77,_0x293dc1){void 0x0===_0x293dc1&&(_0x293dc1=''),this['extensions'][_0x5d7247]||(_0x293dc1&&(_0x54ad77='#if\x20'+_0x293dc1+'\x0d\x0a'+_0x54ad77+'\x0d\x0a#endif'),this['extensions'][_0x5d7247]=_0x54ad77);},_0x4dd80d['prototype']['_emitFunction']=function(_0x1bf8df,_0x4baf60,_0x4940b1){this['functions'][_0x1bf8df]||(this['sharedData']['emitComments']&&(_0x4baf60=_0x4940b1+'\x0d\x0a'+_0x4baf60),this['functions'][_0x1bf8df]=_0x4baf60);},_0x4dd80d['prototype']['_emitCodeFromInclude']=function(_0x3f7cf6,_0x4ca99e,_0x515ce3){if(_0x515ce3&&_0x515ce3['repeatKey'])return'#include<'+_0x3f7cf6+'>[0..'+_0x515ce3['repeatKey']+']\x0d\x0a';var _0x3f13ba=_0x494b01['a']['IncludesShadersStore'][_0x3f7cf6]+'\x0d\x0a';if(this['sharedData']['emitComments']&&(_0x3f13ba=_0x4ca99e+'\x0d\x0a'+_0x3f13ba),!_0x515ce3)return _0x3f13ba;if(_0x515ce3['replaceStrings'])for(var _0x13befa=0x0;_0x13befa<_0x515ce3['replaceStrings']['length'];_0x13befa++){var _0xf4992a=_0x515ce3['replaceStrings'][_0x13befa];_0x3f13ba=_0x3f13ba['replace'](_0xf4992a['search'],_0xf4992a['replace']);}return _0x3f13ba;},_0x4dd80d['prototype']['_emitFunctionFromInclude']=function(_0xdb5975,_0xbc73ed,_0x5d599e,_0x3b0b63){void 0x0===_0x3b0b63&&(_0x3b0b63='');var _0x4ea358=_0xdb5975+_0x3b0b63;if(!this['functions'][_0x4ea358]){if(!(_0x5d599e&&(_0x5d599e['removeAttributes']||_0x5d599e['removeUniforms']||_0x5d599e['removeVaryings']||_0x5d599e['removeIfDef']||_0x5d599e['replaceStrings'])))return _0x5d599e&&_0x5d599e['repeatKey']?this['functions'][_0x4ea358]='#include<'+_0xdb5975+'>[0..'+_0x5d599e['repeatKey']+']\x0d\x0a':this['functions'][_0x4ea358]='#include<'+_0xdb5975+'>\x0d\x0a',void(this['sharedData']['emitComments']&&(this['functions'][_0x4ea358]=_0xbc73ed+'\x0d\x0a'+this['functions'][_0x4ea358]));if(this['functions'][_0x4ea358]=_0x494b01['a']['IncludesShadersStore'][_0xdb5975],this['sharedData']['emitComments']&&(this['functions'][_0x4ea358]=_0xbc73ed+'\x0d\x0a'+this['functions'][_0x4ea358]),_0x5d599e['removeIfDef']&&(this['functions'][_0x4ea358]=this['functions'][_0x4ea358]['replace'](/^\s*?#ifdef.+$/gm,''),this['functions'][_0x4ea358]=this['functions'][_0x4ea358]['replace'](/^\s*?#endif.*$/gm,''),this['functions'][_0x4ea358]=this['functions'][_0x4ea358]['replace'](/^\s*?#else.*$/gm,''),this['functions'][_0x4ea358]=this['functions'][_0x4ea358]['replace'](/^\s*?#elif.*$/gm,'')),_0x5d599e['removeAttributes']&&(this['functions'][_0x4ea358]=this['functions'][_0x4ea358]['replace'](/^\s*?attribute.+$/gm,'')),_0x5d599e['removeUniforms']&&(this['functions'][_0x4ea358]=this['functions'][_0x4ea358]['replace'](/^\s*?uniform.+$/gm,'')),_0x5d599e['removeVaryings']&&(this['functions'][_0x4ea358]=this['functions'][_0x4ea358]['replace'](/^\s*?varying.+$/gm,'')),_0x5d599e['replaceStrings'])for(var _0x3fa890=0x0;_0x3fa890<_0x5d599e['replaceStrings']['length'];_0x3fa890++){var _0x5a0cc2=_0x5d599e['replaceStrings'][_0x3fa890];this['functions'][_0x4ea358]=this['functions'][_0x4ea358]['replace'](_0x5a0cc2['search'],_0x5a0cc2['replace']);}}},_0x4dd80d['prototype']['_registerTempVariable']=function(_0x2a3f2d){return-0x1===this['sharedData']['temps']['indexOf'](_0x2a3f2d)&&(this['sharedData']['temps']['push'](_0x2a3f2d),!0x0);},_0x4dd80d['prototype']['_emitVaryingFromString']=function(_0x86c0a4,_0x385773,_0x30562c,_0x4317f2){return void 0x0===_0x30562c&&(_0x30562c=''),void 0x0===_0x4317f2&&(_0x4317f2=!0x1),-0x1===this['sharedData']['varyings']['indexOf'](_0x86c0a4)&&(this['sharedData']['varyings']['push'](_0x86c0a4),_0x30562c&&(_0x5950ed['a']['StartsWith'](_0x30562c,'defined(')?this['sharedData']['varyingDeclaration']+='#if\x20'+_0x30562c+'\x0d\x0a':this['sharedData']['varyingDeclaration']+=(_0x4317f2?'#ifndef':'#ifdef')+'\x20'+_0x30562c+'\x0d\x0a'),this['sharedData']['varyingDeclaration']+='varying\x20'+_0x385773+'\x20'+_0x86c0a4+';\x0d\x0a',_0x30562c&&(this['sharedData']['varyingDeclaration']+='#endif\x0d\x0a'),!0x0);},_0x4dd80d['prototype']['_emitUniformFromString']=function(_0x4419b6,_0x742f7d,_0x501621,_0x3f3f5e){void 0x0===_0x501621&&(_0x501621=''),void 0x0===_0x3f3f5e&&(_0x3f3f5e=!0x1),-0x1===this['uniforms']['indexOf'](_0x4419b6)&&(this['uniforms']['push'](_0x4419b6),_0x501621&&(_0x5950ed['a']['StartsWith'](_0x501621,'defined(')?this['_uniformDeclaration']+='#if\x20'+_0x501621+'\x0d\x0a':this['_uniformDeclaration']+=(_0x3f3f5e?'#ifndef':'#ifdef')+'\x20'+_0x501621+'\x0d\x0a'),this['_uniformDeclaration']+='uniform\x20'+_0x742f7d+'\x20'+_0x4419b6+';\x0d\x0a',_0x501621&&(this['_uniformDeclaration']+='#endif\x0d\x0a'));},_0x4dd80d['prototype']['_emitFloat']=function(_0x2248bf){return _0x2248bf['toString']()===_0x2248bf['toFixed'](0x0)?_0x2248bf+'.0':_0x2248bf['toString']();},_0x4dd80d;}()),_0x144676=(function(){function _0xc565d7(){this['temps']=new Array(),this['varyings']=new Array(),this['varyingDeclaration']='',this['inputBlocks']=new Array(),this['textureBlocks']=new Array(),this['bindableBlocks']=new Array(),this['blocksWithFallbacks']=new Array(),this['blocksWithDefines']=new Array(),this['repeatableContentBlocks']=new Array(),this['dynamicUniformBlocks']=new Array(),this['blockingBlocks']=new Array(),this['animatedInputs']=new Array(),this['variableNames']={},this['defineNames']={},this['hints']={'needWorldViewMatrix':!0x1,'needWorldViewProjectionMatrix':!0x1,'needAlphaBlending':!0x1,'needAlphaTesting':!0x1},this['checks']={'emitVertex':!0x1,'emitFragment':!0x1,'notConnectedNonOptionalInputs':new Array()},this['allowEmptyVertexProgram']=!0x1,this['variableNames']['position']=0x0,this['variableNames']['normal']=0x0,this['variableNames']['tangent']=0x0,this['variableNames']['uv']=0x0,this['variableNames']['uv2']=0x0,this['variableNames']['uv3']=0x0,this['variableNames']['uv4']=0x0,this['variableNames']['uv4']=0x0,this['variableNames']['uv5']=0x0,this['variableNames']['uv6']=0x0,this['variableNames']['color']=0x0,this['variableNames']['matricesIndices']=0x0,this['variableNames']['matricesWeights']=0x0,this['variableNames']['matricesIndicesExtra']=0x0,this['variableNames']['matricesWeightsExtra']=0x0,this['variableNames']['diffuseBase']=0x0,this['variableNames']['specularBase']=0x0,this['variableNames']['worldPos']=0x0,this['variableNames']['shadow']=0x0,this['variableNames']['view']=0x0,this['variableNames']['vTBN']=0x0,this['defineNames']['MAINUV0']=0x0,this['defineNames']['MAINUV1']=0x0,this['defineNames']['MAINUV2']=0x0,this['defineNames']['MAINUV3']=0x0,this['defineNames']['MAINUV4']=0x0,this['defineNames']['MAINUV5']=0x0,this['defineNames']['MAINUV6']=0x0,this['defineNames']['MAINUV7']=0x0;}return _0xc565d7['prototype']['emitErrors']=function(){var _0x5f1fb0='';this['checks']['emitVertex']||this['allowEmptyVertexProgram']||(_0x5f1fb0+='NodeMaterial\x20does\x20not\x20have\x20a\x20vertex\x20output.\x20You\x20need\x20to\x20at\x20least\x20add\x20a\x20block\x20that\x20generates\x20a\x20glPosition\x20value.\x0d\x0a'),this['checks']['emitFragment']||(_0x5f1fb0+='NodeMaterial\x20does\x20not\x20have\x20a\x20fragment\x20output.\x20You\x20need\x20to\x20at\x20least\x20add\x20a\x20block\x20that\x20generates\x20a\x20glFragColor\x20value.\x0d\x0a');for(var _0x37c53c=0x0,_0x5bf8fa=this['checks']['notConnectedNonOptionalInputs'];_0x37c53c<_0x5bf8fa['length'];_0x37c53c++){var _0x2b9ea5=_0x5bf8fa[_0x37c53c];_0x5f1fb0+='input\x20'+_0x2b9ea5['name']+'\x20from\x20block\x20'+_0x2b9ea5['ownerBlock']['name']+'['+_0x2b9ea5['ownerBlock']['getClassName']()+']\x20is\x20not\x20connected\x20and\x20is\x20not\x20optional.\x0d\x0a';}if(_0x5f1fb0)throw'Build\x20of\x20NodeMaterial\x20failed:\x0d\x0a'+_0x5f1fb0;},_0xc565d7;}()),_0x3fcbd4=function(_0x5af553){function _0x20346e(_0x19676f){var _0x259029=_0x5af553['call'](this,_0x19676f,_0x4e54a1['Vertex'])||this;return _0x259029['complementW']=0x1,_0x259029['complementZ']=0x0,_0x259029['registerInput']('vector',_0x3bb339['AutoDetect']),_0x259029['registerInput']('transform',_0x3bb339['Matrix']),_0x259029['registerOutput']('output',_0x3bb339['Vector4']),_0x259029['registerOutput']('xyz',_0x3bb339['Vector3']),_0x259029['_inputs'][0x0]['onConnectionObservable']['add'](function(_0x1b51e8){if(_0x1b51e8['ownerBlock']['isInput']){var _0xa76984=_0x1b51e8['ownerBlock'];'normal'!==_0xa76984['name']&&'tangent'!==_0xa76984['name']||(_0x259029['complementW']=0x0);}}),_0x259029;}return Object(_0x18e13d['d'])(_0x20346e,_0x5af553),_0x20346e['prototype']['getClassName']=function(){return'TransformBlock';},Object['defineProperty'](_0x20346e['prototype'],'vector',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x20346e['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x20346e['prototype'],'xyz',{'get':function(){return this['_outputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x20346e['prototype'],'transform',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),_0x20346e['prototype']['_buildBlock']=function(_0x4e2a57){_0x5af553['prototype']['_buildBlock']['call'](this,_0x4e2a57);var _0x4800aa=this['vector'],_0x1f6c44=this['transform'];if(_0x4800aa['connectedPoint']){if(0x0===this['complementW']){var _0x182135='//'+this['name'];_0x4e2a57['_emitFunctionFromInclude']('helperFunctions',_0x182135),_0x4e2a57['sharedData']['blocksWithDefines']['push'](this);var _0x55c33c=_0x4e2a57['_getFreeVariableName'](_0x1f6c44['associatedVariableName']+'_NUS');switch(_0x4e2a57['compilationString']+='mat3\x20'+_0x55c33c+'\x20=\x20mat3('+_0x1f6c44['associatedVariableName']+');\x0d\x0a',_0x4e2a57['compilationString']+='#ifdef\x20NONUNIFORMSCALING\x0d\x0a',_0x4e2a57['compilationString']+=_0x55c33c+'\x20=\x20transposeMat3(inverseMat3('+_0x55c33c+'));\x0d\x0a',_0x4e2a57['compilationString']+='#endif\x0d\x0a',_0x4800aa['connectedPoint']['type']){case _0x3bb339['Vector2']:_0x4e2a57['compilationString']+=this['_declareOutput'](this['output'],_0x4e2a57)+'\x20=\x20vec4('+_0x55c33c+'\x20*\x20vec3('+_0x4800aa['associatedVariableName']+',\x20'+this['_writeFloat'](this['complementZ'])+'),\x20'+this['_writeFloat'](this['complementW'])+');\x0d\x0a';break;case _0x3bb339['Vector3']:case _0x3bb339['Color3']:_0x4e2a57['compilationString']+=this['_declareOutput'](this['output'],_0x4e2a57)+'\x20=\x20vec4('+_0x55c33c+'\x20*\x20'+_0x4800aa['associatedVariableName']+',\x20'+this['_writeFloat'](this['complementW'])+');\x0d\x0a';break;default:_0x4e2a57['compilationString']+=this['_declareOutput'](this['output'],_0x4e2a57)+'\x20=\x20vec4('+_0x55c33c+'\x20*\x20'+_0x4800aa['associatedVariableName']+'.xyz,\x20'+this['_writeFloat'](this['complementW'])+');\x0d\x0a';}}else{_0x55c33c=_0x1f6c44['associatedVariableName'];switch(_0x4800aa['connectedPoint']['type']){case _0x3bb339['Vector2']:_0x4e2a57['compilationString']+=this['_declareOutput'](this['output'],_0x4e2a57)+'\x20=\x20'+_0x55c33c+'\x20*\x20vec4('+_0x4800aa['associatedVariableName']+',\x20'+this['_writeFloat'](this['complementZ'])+',\x20'+this['_writeFloat'](this['complementW'])+');\x0d\x0a';break;case _0x3bb339['Vector3']:case _0x3bb339['Color3']:_0x4e2a57['compilationString']+=this['_declareOutput'](this['output'],_0x4e2a57)+'\x20=\x20'+_0x55c33c+'\x20*\x20vec4('+_0x4800aa['associatedVariableName']+',\x20'+this['_writeFloat'](this['complementW'])+');\x0d\x0a';break;default:_0x4e2a57['compilationString']+=this['_declareOutput'](this['output'],_0x4e2a57)+'\x20=\x20'+_0x55c33c+'\x20*\x20'+_0x4800aa['associatedVariableName']+';\x0d\x0a';}}this['xyz']['hasEndpoints']&&(_0x4e2a57['compilationString']+=this['_declareOutput'](this['xyz'],_0x4e2a57)+'\x20=\x20'+this['output']['associatedVariableName']+'.xyz;\x0d\x0a');}return this;},_0x20346e['prototype']['prepareDefines']=function(_0x43e196,_0x41b62a,_0x2a828d,_0x4d7bcc,_0x51ff3d){void 0x0===_0x4d7bcc&&(_0x4d7bcc=!0x1),_0x43e196['nonUniformScaling']&&_0x2a828d['setValue']('NONUNIFORMSCALING',!0x0);},_0x20346e['prototype']['serialize']=function(){var _0x4325b4=_0x5af553['prototype']['serialize']['call'](this);return _0x4325b4['complementZ']=this['complementZ'],_0x4325b4['complementW']=this['complementW'],_0x4325b4;},_0x20346e['prototype']['_deserialize']=function(_0x15f981,_0x5beb60,_0x234424){_0x5af553['prototype']['_deserialize']['call'](this,_0x15f981,_0x5beb60,_0x234424),this['complementZ']=void 0x0!==_0x15f981['complementZ']?_0x15f981['complementZ']:0x0,this['complementW']=void 0x0!==_0x15f981['complementW']?_0x15f981['complementW']:0x1;},_0x20346e['prototype']['_dumpPropertiesCode']=function(){var _0x120aa9=this['_codeVariableName']+'.complementZ\x20=\x20'+this['complementZ']+';\x0d\x0a';return _0x120aa9+=this['_codeVariableName']+'.complementW\x20=\x20'+this['complementW']+';\x0d\x0a';},_0x20346e;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.TransformBlock']=_0x3fcbd4;var _0x5b4f0e=function(_0x3e2360){function _0x1dd725(_0x918af1){var _0xd4c4c0=_0x3e2360['call'](this,_0x918af1,_0x4e54a1['Vertex'],!0x0)||this;return _0xd4c4c0['registerInput']('vector',_0x3bb339['Vector4']),_0xd4c4c0;}return Object(_0x18e13d['d'])(_0x1dd725,_0x3e2360),_0x1dd725['prototype']['getClassName']=function(){return'VertexOutputBlock';},Object['defineProperty'](_0x1dd725['prototype'],'vector',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x1dd725['prototype']['_buildBlock']=function(_0x55161b){_0x3e2360['prototype']['_buildBlock']['call'](this,_0x55161b);var _0x71e85c=this['vector'];return _0x55161b['compilationString']+='gl_Position\x20=\x20'+_0x71e85c['associatedVariableName']+';\x0d\x0a',this;},_0x1dd725;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.VertexOutputBlock']=_0x5b4f0e;var _0x5b0248,_0x1f2748=function(_0x23072c){function _0x132219(_0x14f5b0){var _0x594689=_0x23072c['call'](this,_0x14f5b0,_0x4e54a1['Fragment'],!0x0)||this;return _0x594689['registerInput']('rgba',_0x3bb339['Color4'],!0x0),_0x594689['registerInput']('rgb',_0x3bb339['Color3'],!0x0),_0x594689['registerInput']('a',_0x3bb339['Float'],!0x0),_0x594689['rgb']['acceptedConnectionPointTypes']['push'](_0x3bb339['Float']),_0x594689;}return Object(_0x18e13d['d'])(_0x132219,_0x23072c),_0x132219['prototype']['getClassName']=function(){return'FragmentOutputBlock';},Object['defineProperty'](_0x132219['prototype'],'rgba',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x132219['prototype'],'rgb',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x132219['prototype'],'a',{'get':function(){return this['_inputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),_0x132219['prototype']['_buildBlock']=function(_0xd5c05){_0x23072c['prototype']['_buildBlock']['call'](this,_0xd5c05);var _0x493f64=this['rgba'],_0xa3fbbf=this['rgb'],_0x4c6a55=this['a'];if(_0xd5c05['sharedData']['hints']['needAlphaBlending']=_0x493f64['isConnected']||_0x4c6a55['isConnected'],_0x493f64['connectedPoint'])_0x4c6a55['isConnected']?_0xd5c05['compilationString']+='gl_FragColor\x20=\x20vec4('+_0x493f64['associatedVariableName']+'.rgb,\x20'+_0x4c6a55['associatedVariableName']+');\x0d\x0a':_0xd5c05['compilationString']+='gl_FragColor\x20=\x20'+_0x493f64['associatedVariableName']+';\x0d\x0a';else{if(_0xa3fbbf['connectedPoint']){var _0x1df65f='1.0';_0x4c6a55['connectedPoint']&&(_0x1df65f=_0x4c6a55['associatedVariableName']),_0xa3fbbf['connectedPoint']['type']===_0x3bb339['Float']?_0xd5c05['compilationString']+='gl_FragColor\x20=\x20vec4('+_0xa3fbbf['associatedVariableName']+',\x20'+_0xa3fbbf['associatedVariableName']+',\x20'+_0xa3fbbf['associatedVariableName']+',\x20'+_0x1df65f+');\x0d\x0a':_0xd5c05['compilationString']+='gl_FragColor\x20=\x20vec4('+_0xa3fbbf['associatedVariableName']+',\x20'+_0x1df65f+');\x0d\x0a';}else _0xd5c05['sharedData']['checks']['notConnectedNonOptionalInputs']['push'](_0x493f64);}return this;},_0x132219;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.FragmentOutputBlock']=_0x1f2748,function(_0x31c14a){_0x31c14a[_0x31c14a['None']=0x0]='None',_0x31c14a[_0x31c14a['Time']=0x1]='Time';}(_0x5b0248||(_0x5b0248={}));var _0x5a75f4={'position2d':'position','particle_uv':'vUV','particle_color':'vColor','particle_texturemask':'textureMask','particle_positionw':'vPositionW'},_0x3bca57={'particle_uv':!0x0,'particle_color':!0x0,'particle_texturemask':!0x0,'particle_positionw':!0x0},_0x21c9db={'particle_texturemask':!0x0},_0x581182=function(_0x88a5c5){function _0x5bf27d(_0x4b7286,_0x11e14e,_0x2dd7fb){void 0x0===_0x11e14e&&(_0x11e14e=_0x4e54a1['Vertex']),void 0x0===_0x2dd7fb&&(_0x2dd7fb=_0x3bb339['AutoDetect']);var _0x2cc7af=_0x88a5c5['call'](this,_0x4b7286,_0x11e14e,!0x1,!0x0)||this;return _0x2cc7af['_mode']=_0x370a71['Undefined'],_0x2cc7af['_animationType']=_0x5b0248['None'],_0x2cc7af['min']=0x0,_0x2cc7af['max']=0x0,_0x2cc7af['isBoolean']=!0x1,_0x2cc7af['matrixMode']=0x0,_0x2cc7af['_systemValue']=null,_0x2cc7af['isConstant']=!0x1,_0x2cc7af['groupInInspector']='',_0x2cc7af['onValueChangedObservable']=new _0x6ac1f7['c'](),_0x2cc7af['convertToGammaSpace']=!0x1,_0x2cc7af['convertToLinearSpace']=!0x1,_0x2cc7af['_type']=_0x2dd7fb,_0x2cc7af['setDefaultValue'](),_0x2cc7af['registerOutput']('output',_0x2dd7fb),_0x2cc7af;}return Object(_0x18e13d['d'])(_0x5bf27d,_0x88a5c5),Object['defineProperty'](_0x5bf27d['prototype'],'type',{'get':function(){if(this['_type']===_0x3bb339['AutoDetect']){if(this['isUniform']&&null!=this['value']){if(!isNaN(this['value']))return this['_type']=_0x3bb339['Float'],this['_type'];switch(this['value']['getClassName']()){case'Vector2':return this['_type']=_0x3bb339['Vector2'],this['_type'];case'Vector3':return this['_type']=_0x3bb339['Vector3'],this['_type'];case'Vector4':return this['_type']=_0x3bb339['Vector4'],this['_type'];case'Color3':return this['_type']=_0x3bb339['Color3'],this['_type'];case'Color4':return this['_type']=_0x3bb339['Color4'],this['_type'];case'Matrix':return this['_type']=_0x3bb339['Matrix'],this['_type'];}}if(this['isAttribute'])switch(this['name']){case'position':case'normal':case'tangent':case'particle_positionw':return this['_type']=_0x3bb339['Vector3'],this['_type'];case'uv':case'uv2':case'position2d':case'particle_uv':return this['_type']=_0x3bb339['Vector2'],this['_type'];case'matricesIndices':case'matricesWeights':case'world0':case'world1':case'world2':case'world3':return this['_type']=_0x3bb339['Vector4'],this['_type'];case'color':case'particle_color':case'particle_texturemask':return this['_type']=_0x3bb339['Color4'],this['_type'];}if(this['isSystemValue'])switch(this['_systemValue']){case _0x509c82['World']:case _0x509c82['WorldView']:case _0x509c82['WorldViewProjection']:case _0x509c82['View']:case _0x509c82['ViewProjection']:case _0x509c82['Projection']:return this['_type']=_0x3bb339['Matrix'],this['_type'];case _0x509c82['CameraPosition']:return this['_type']=_0x3bb339['Vector3'],this['_type'];case _0x509c82['FogColor']:return this['_type']=_0x3bb339['Color3'],this['_type'];case _0x509c82['DeltaTime']:return this['_type']=_0x3bb339['Float'],this['_type'];}}return this['_type'];},'enumerable':!0x1,'configurable':!0x0}),_0x5bf27d['prototype']['validateBlockName']=function(_0x59e4e7){return!!this['isAttribute']||_0x88a5c5['prototype']['validateBlockName']['call'](this,_0x59e4e7);},Object['defineProperty'](_0x5bf27d['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x5bf27d['prototype']['setAsAttribute']=function(_0x3125a3){return this['_mode']=_0x370a71['Attribute'],_0x3125a3&&(this['name']=_0x3125a3),this;},_0x5bf27d['prototype']['setAsSystemValue']=function(_0x188d48){return this['systemValue']=_0x188d48,this;},Object['defineProperty'](_0x5bf27d['prototype'],'value',{'get':function(){return this['_storedValue'];},'set':function(_0xbb9222){this['type']===_0x3bb339['Float']&&(this['isBoolean']?_0xbb9222=_0xbb9222?0x1:0x0:this['min']!==this['max']&&(_0xbb9222=Math['max'](this['min'],_0xbb9222),_0xbb9222=Math['min'](this['max'],_0xbb9222))),this['_storedValue']=_0xbb9222,this['_mode']=_0x370a71['Uniform'],this['onValueChangedObservable']['notifyObservers'](this);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5bf27d['prototype'],'valueCallback',{'get':function(){return this['_valueCallback'];},'set':function(_0x18234d){this['_valueCallback']=_0x18234d,this['_mode']=_0x370a71['Uniform'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5bf27d['prototype'],'associatedVariableName',{'get':function(){return this['_associatedVariableName'];},'set':function(_0x4ab5e2){this['_associatedVariableName']=_0x4ab5e2;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5bf27d['prototype'],'animationType',{'get':function(){return this['_animationType'];},'set':function(_0x47ca75){this['_animationType']=_0x47ca75;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5bf27d['prototype'],'isUndefined',{'get':function(){return this['_mode']===_0x370a71['Undefined'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5bf27d['prototype'],'isUniform',{'get':function(){return this['_mode']===_0x370a71['Uniform'];},'set':function(_0x4bea3e){this['_mode']=_0x4bea3e?_0x370a71['Uniform']:_0x370a71['Undefined'],this['associatedVariableName']='';},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5bf27d['prototype'],'isAttribute',{'get':function(){return this['_mode']===_0x370a71['Attribute'];},'set':function(_0x3d4489){this['_mode']=_0x3d4489?_0x370a71['Attribute']:_0x370a71['Undefined'],this['associatedVariableName']='';},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5bf27d['prototype'],'isVarying',{'get':function(){return this['_mode']===_0x370a71['Varying'];},'set':function(_0x4b3bd7){this['_mode']=_0x4b3bd7?_0x370a71['Varying']:_0x370a71['Undefined'],this['associatedVariableName']='';},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5bf27d['prototype'],'isSystemValue',{'get':function(){return null!=this['_systemValue'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5bf27d['prototype'],'systemValue',{'get':function(){return this['_systemValue'];},'set':function(_0x51b842){this['_mode']=_0x370a71['Uniform'],this['associatedVariableName']='',this['_systemValue']=_0x51b842;},'enumerable':!0x1,'configurable':!0x0}),_0x5bf27d['prototype']['getClassName']=function(){return'InputBlock';},_0x5bf27d['prototype']['animate']=function(_0x593468){switch(this['_animationType']){case _0x5b0248['Time']:this['type']===_0x3bb339['Float']&&(this['value']+=0.01*_0x593468['getAnimationRatio']());}},_0x5bf27d['prototype']['_emitDefine']=function(_0xcb915){return'!'===_0xcb915[0x0]?'#ifndef\x20'+_0xcb915['substring'](0x1)+'\x0d\x0a':'#ifdef\x20'+_0xcb915+'\x0d\x0a';},_0x5bf27d['prototype']['initialize']=function(_0x1371ad){this['associatedVariableName']='';},_0x5bf27d['prototype']['setDefaultValue']=function(){switch(this['type']){case _0x3bb339['Float']:this['value']=0x0;break;case _0x3bb339['Vector2']:this['value']=_0x74d525['d']['Zero']();break;case _0x3bb339['Vector3']:this['value']=_0x74d525['e']['Zero']();break;case _0x3bb339['Vector4']:this['value']=_0x74d525['f']['Zero']();break;case _0x3bb339['Color3']:this['value']=_0x39310d['a']['White']();break;case _0x3bb339['Color4']:this['value']=new _0x39310d['b'](0x1,0x1,0x1,0x1);break;case _0x3bb339['Matrix']:this['value']=_0x74d525['a']['Identity']();}},_0x5bf27d['prototype']['_emitConstant']=function(_0x2dd683){switch(this['type']){case _0x3bb339['Float']:return''+_0x2dd683['_emitFloat'](this['value']);case _0x3bb339['Vector2']:return'vec2('+this['value']['x']+',\x20'+this['value']['y']+')';case _0x3bb339['Vector3']:return'vec3('+this['value']['x']+',\x20'+this['value']['y']+',\x20'+this['value']['z']+')';case _0x3bb339['Vector4']:return'vec4('+this['value']['x']+',\x20'+this['value']['y']+',\x20'+this['value']['z']+',\x20'+this['value']['w']+')';case _0x3bb339['Color3']:return _0x39310d['c']['Color3'][0x0]['set'](this['value']['r'],this['value']['g'],this['value']['b']),this['convertToGammaSpace']&&_0x39310d['c']['Color3'][0x0]['toGammaSpaceToRef'](_0x39310d['c']['Color3'][0x0]),this['convertToLinearSpace']&&_0x39310d['c']['Color3'][0x0]['toLinearSpaceToRef'](_0x39310d['c']['Color3'][0x0]),'vec3('+_0x39310d['c']['Color3'][0x0]['r']+',\x20'+_0x39310d['c']['Color3'][0x0]['g']+',\x20'+_0x39310d['c']['Color3'][0x0]['b']+')';case _0x3bb339['Color4']:return _0x39310d['c']['Color4'][0x0]['set'](this['value']['r'],this['value']['g'],this['value']['b'],this['value']['a']),this['convertToGammaSpace']&&_0x39310d['c']['Color4'][0x0]['toGammaSpaceToRef'](_0x39310d['c']['Color4'][0x0]),this['convertToLinearSpace']&&_0x39310d['c']['Color4'][0x0]['toLinearSpaceToRef'](_0x39310d['c']['Color4'][0x0]),'vec4('+_0x39310d['c']['Color4'][0x0]['r']+',\x20'+_0x39310d['c']['Color4'][0x0]['g']+',\x20'+_0x39310d['c']['Color4'][0x0]['b']+',\x20'+_0x39310d['c']['Color4'][0x0]['a']+')';}return'';},Object['defineProperty'](_0x5bf27d['prototype'],'_noContextSwitch',{'get':function(){return _0x3bca57[this['name']];},'enumerable':!0x1,'configurable':!0x0}),_0x5bf27d['prototype']['_emit']=function(_0x8c277c,_0x524955){var _0x587e1a;if(this['isUniform']){if(this['associatedVariableName']||(this['associatedVariableName']=_0x8c277c['_getFreeVariableName']('u_'+this['name'])),this['isConstant']){if(-0x1!==_0x8c277c['constants']['indexOf'](this['associatedVariableName']))return;return _0x8c277c['constants']['push'](this['associatedVariableName']),void(_0x8c277c['_constantDeclaration']+=this['_declareOutput'](this['output'],_0x8c277c)+'\x20=\x20'+this['_emitConstant'](_0x8c277c)+';\x0d\x0a');}if(-0x1!==_0x8c277c['uniforms']['indexOf'](this['associatedVariableName']))return;_0x8c277c['uniforms']['push'](this['associatedVariableName']),_0x524955&&(_0x8c277c['_uniformDeclaration']+=this['_emitDefine'](_0x524955)),_0x8c277c['_uniformDeclaration']+='uniform\x20'+_0x8c277c['_getGLType'](this['type'])+'\x20'+this['associatedVariableName']+';\x0d\x0a',_0x524955&&(_0x8c277c['_uniformDeclaration']+='#endif\x0d\x0a');var _0x4adb97=_0x8c277c['sharedData']['hints'];if(null!==this['_systemValue']&&void 0x0!==this['_systemValue'])switch(this['_systemValue']){case _0x509c82['WorldView']:_0x4adb97['needWorldViewMatrix']=!0x0;break;case _0x509c82['WorldViewProjection']:_0x4adb97['needWorldViewProjectionMatrix']=!0x0;}else this['_animationType']!==_0x5b0248['None']&&_0x8c277c['sharedData']['animatedInputs']['push'](this);}else{if(this['isAttribute']){if(this['associatedVariableName']=null!==(_0x587e1a=_0x5a75f4[this['name']])&&void 0x0!==_0x587e1a?_0x587e1a:this['name'],this['target']===_0x4e54a1['Vertex']&&_0x8c277c['_vertexState'])return void(_0x3bca57[this['name']]?_0x21c9db[this['name']]?_0x8c277c['_emitUniformFromString'](this['associatedVariableName'],_0x8c277c['_getGLType'](this['type']),_0x524955):_0x8c277c['_emitVaryingFromString'](this['associatedVariableName'],_0x8c277c['_getGLType'](this['type']),_0x524955):this['_emit'](_0x8c277c['_vertexState'],_0x524955));if(-0x1!==_0x8c277c['attributes']['indexOf'](this['associatedVariableName']))return;_0x8c277c['attributes']['push'](this['associatedVariableName']),_0x3bca57[this['name']]?_0x21c9db[this['name']]?_0x8c277c['_emitUniformFromString'](this['associatedVariableName'],_0x8c277c['_getGLType'](this['type']),_0x524955):_0x8c277c['_emitVaryingFromString'](this['associatedVariableName'],_0x8c277c['_getGLType'](this['type']),_0x524955):(_0x524955&&(_0x8c277c['_attributeDeclaration']+=this['_emitDefine'](_0x524955)),_0x8c277c['_attributeDeclaration']+='attribute\x20'+_0x8c277c['_getGLType'](this['type'])+'\x20'+this['associatedVariableName']+';\x0d\x0a',_0x524955&&(_0x8c277c['_attributeDeclaration']+='#endif\x0d\x0a'));}}},_0x5bf27d['prototype']['_transmitWorld']=function(_0xb72697,_0x81b95a,_0x1f5bf5,_0x115058){if(this['_systemValue']){var _0x973613=this['associatedVariableName'];switch(this['_systemValue']){case _0x509c82['World']:_0xb72697['setMatrix'](_0x973613,_0x81b95a);break;case _0x509c82['WorldView']:_0xb72697['setMatrix'](_0x973613,_0x1f5bf5);break;case _0x509c82['WorldViewProjection']:_0xb72697['setMatrix'](_0x973613,_0x115058);}}},_0x5bf27d['prototype']['_transmit']=function(_0x5108ef,_0x58a71c){if(!this['isAttribute']){var _0x308475=this['associatedVariableName'];if(this['_systemValue'])switch(this['_systemValue']){case _0x509c82['World']:case _0x509c82['WorldView']:case _0x509c82['WorldViewProjection']:return;case _0x509c82['View']:_0x5108ef['setMatrix'](_0x308475,_0x58a71c['getViewMatrix']());break;case _0x509c82['Projection']:_0x5108ef['setMatrix'](_0x308475,_0x58a71c['getProjectionMatrix']());break;case _0x509c82['ViewProjection']:_0x5108ef['setMatrix'](_0x308475,_0x58a71c['getTransformMatrix']());break;case _0x509c82['CameraPosition']:_0x464f31['a']['BindEyePosition'](_0x5108ef,_0x58a71c,_0x308475);break;case _0x509c82['FogColor']:_0x5108ef['setColor3'](_0x308475,_0x58a71c['fogColor']);break;case _0x509c82['DeltaTime']:_0x5108ef['setFloat'](_0x308475,_0x58a71c['deltaTime']/0x3e8);}else{var _0x191acd=this['_valueCallback']?this['_valueCallback']():this['_storedValue'];if(null!==_0x191acd)switch(this['type']){case _0x3bb339['Float']:_0x5108ef['setFloat'](_0x308475,_0x191acd);break;case _0x3bb339['Int']:_0x5108ef['setInt'](_0x308475,_0x191acd);break;case _0x3bb339['Color3']:_0x39310d['c']['Color3'][0x0]['set'](this['value']['r'],this['value']['g'],this['value']['b']),this['convertToGammaSpace']&&_0x39310d['c']['Color3'][0x0]['toGammaSpaceToRef'](_0x39310d['c']['Color3'][0x0]),this['convertToLinearSpace']&&_0x39310d['c']['Color3'][0x0]['toLinearSpaceToRef'](_0x39310d['c']['Color3'][0x0]),_0x5108ef['setColor3'](_0x308475,_0x39310d['c']['Color3'][0x0]);break;case _0x3bb339['Color4']:_0x39310d['c']['Color4'][0x0]['set'](this['value']['r'],this['value']['g'],this['value']['b'],this['value']['a']),this['convertToGammaSpace']&&_0x39310d['c']['Color4'][0x0]['toGammaSpaceToRef'](_0x39310d['c']['Color4'][0x0]),this['convertToLinearSpace']&&_0x39310d['c']['Color4'][0x0]['toLinearSpaceToRef'](_0x39310d['c']['Color4'][0x0]),_0x5108ef['setDirectColor4'](_0x308475,_0x39310d['c']['Color4'][0x0]);break;case _0x3bb339['Vector2']:_0x5108ef['setVector2'](_0x308475,_0x191acd);break;case _0x3bb339['Vector3']:_0x5108ef['setVector3'](_0x308475,_0x191acd);break;case _0x3bb339['Vector4']:_0x5108ef['setVector4'](_0x308475,_0x191acd);break;case _0x3bb339['Matrix']:_0x5108ef['setMatrix'](_0x308475,_0x191acd);}}}},_0x5bf27d['prototype']['_buildBlock']=function(_0x5bd752){_0x88a5c5['prototype']['_buildBlock']['call'](this,_0x5bd752),(this['isUniform']||this['isSystemValue'])&&_0x5bd752['sharedData']['inputBlocks']['push'](this),this['_emit'](_0x5bd752);},_0x5bf27d['prototype']['_dumpPropertiesCode']=function(){var _0xa430f6=this['_codeVariableName'];if(this['isAttribute'])return _0xa430f6+'.setAsAttribute(\x22'+this['name']+'\x22);\x0d\x0a';if(this['isSystemValue'])return _0xa430f6+'.setAsSystemValue(BABYLON.NodeMaterialSystemValues.'+_0x509c82[this['_systemValue']]+');\x0d\x0a';if(this['isUniform']){var _0x490fc5=[],_0x25d1cc='';switch(this['type']){case _0x3bb339['Float']:_0x25d1cc=''+this['value'];break;case _0x3bb339['Vector2']:_0x25d1cc='new\x20BABYLON.Vector2('+this['value']['x']+',\x20'+this['value']['y']+')';break;case _0x3bb339['Vector3']:_0x25d1cc='new\x20BABYLON.Vector3('+this['value']['x']+',\x20'+this['value']['y']+',\x20'+this['value']['z']+')';break;case _0x3bb339['Vector4']:_0x25d1cc='new\x20BABYLON.Vector4('+this['value']['x']+',\x20'+this['value']['y']+',\x20'+this['value']['z']+',\x20'+this['value']['w']+')';break;case _0x3bb339['Color3']:_0x25d1cc='new\x20BABYLON.Color3('+this['value']['r']+',\x20'+this['value']['g']+',\x20'+this['value']['b']+')',this['convertToGammaSpace']&&(_0x25d1cc+='.toGammaSpace()'),this['convertToLinearSpace']&&(_0x25d1cc+='.toLinearSpace()');break;case _0x3bb339['Color4']:_0x25d1cc='new\x20BABYLON.Color4('+this['value']['r']+',\x20'+this['value']['g']+',\x20'+this['value']['b']+',\x20'+this['value']['a']+')',this['convertToGammaSpace']&&(_0x25d1cc+='.toGammaSpace()'),this['convertToLinearSpace']&&(_0x25d1cc+='.toLinearSpace()');break;case _0x3bb339['Matrix']:_0x25d1cc='BABYLON.Matrix.FromArray(['+this['value']['m']+'])';}return _0x490fc5['push'](_0xa430f6+'.value\x20=\x20'+_0x25d1cc),this['type']===_0x3bb339['Float']&&_0x490fc5['push'](_0xa430f6+'.min\x20=\x20'+this['min'],_0xa430f6+'.max\x20=\x20'+this['max'],_0xa430f6+'.isBoolean\x20=\x20'+this['isBoolean'],_0xa430f6+'.matrixMode\x20=\x20'+this['matrixMode'],_0xa430f6+'.animationType\x20=\x20BABYLON.AnimatedInputBlockTypes.'+_0x5b0248[this['animationType']]),_0x490fc5['push'](_0xa430f6+'.isConstant\x20=\x20'+this['isConstant']),_0x490fc5['push'](''),_0x490fc5['join'](';\x0d\x0a');}return'';},_0x5bf27d['prototype']['dispose']=function(){this['onValueChangedObservable']['clear'](),_0x88a5c5['prototype']['dispose']['call'](this);},_0x5bf27d['prototype']['serialize']=function(){var _0x13032f=_0x88a5c5['prototype']['serialize']['call'](this);return _0x13032f['type']=this['type'],_0x13032f['mode']=this['_mode'],_0x13032f['systemValue']=this['_systemValue'],_0x13032f['animationType']=this['_animationType'],_0x13032f['min']=this['min'],_0x13032f['max']=this['max'],_0x13032f['isBoolean']=this['isBoolean'],_0x13032f['matrixMode']=this['matrixMode'],_0x13032f['isConstant']=this['isConstant'],_0x13032f['groupInInspector']=this['groupInInspector'],_0x13032f['convertToGammaSpace']=this['convertToGammaSpace'],_0x13032f['convertToLinearSpace']=this['convertToLinearSpace'],null!=this['_storedValue']&&this['_mode']===_0x370a71['Uniform']&&(this['_storedValue']['asArray']?(_0x13032f['valueType']='BABYLON.'+this['_storedValue']['getClassName'](),_0x13032f['value']=this['_storedValue']['asArray']()):(_0x13032f['valueType']='number',_0x13032f['value']=this['_storedValue'])),_0x13032f;},_0x5bf27d['prototype']['_deserialize']=function(_0x7d225,_0x4c2388,_0x4ecdec){if(this['_mode']=_0x7d225['mode'],_0x88a5c5['prototype']['_deserialize']['call'](this,_0x7d225,_0x4c2388,_0x4ecdec),this['_type']=_0x7d225['type'],this['_systemValue']=_0x7d225['systemValue']||_0x7d225['wellKnownValue'],this['_animationType']=_0x7d225['animationType'],this['min']=_0x7d225['min']||0x0,this['max']=_0x7d225['max']||0x0,this['isBoolean']=!!_0x7d225['isBoolean'],this['matrixMode']=_0x7d225['matrixMode']||0x0,this['isConstant']=!!_0x7d225['isConstant'],this['groupInInspector']=_0x7d225['groupInInspector']||'',this['convertToGammaSpace']=!!_0x7d225['convertToGammaSpace'],this['convertToLinearSpace']=!!_0x7d225['convertToLinearSpace'],_0x7d225['valueType']){if('number'===_0x7d225['valueType'])this['_storedValue']=_0x7d225['value'];else{var _0x50e488=_0x3cd573['a']['GetClass'](_0x7d225['valueType']);_0x50e488&&(this['_storedValue']=_0x50e488['FromArray'](_0x7d225['value']));}}},_0x5bf27d;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.InputBlock']=_0x581182;var _0x6d15a7=function(_0x46db3e){function _0x2a5a68(_0x56f975){var _0x20b992=_0x46db3e['call'](this,_0x56f975,_0x4e54a1['VertexAndFragment'])||this;return _0x20b992['_samplerName']='textureSampler',_0x20b992['convertToGammaSpace']=!0x1,_0x20b992['convertToLinearSpace']=!0x1,_0x20b992['_isUnique']=!0x1,_0x20b992['registerInput']('uv',_0x3bb339['Vector2'],!0x1,_0x4e54a1['VertexAndFragment']),_0x20b992['registerOutput']('rgba',_0x3bb339['Color4'],_0x4e54a1['Neutral']),_0x20b992['registerOutput']('rgb',_0x3bb339['Color3'],_0x4e54a1['Neutral']),_0x20b992['registerOutput']('r',_0x3bb339['Float'],_0x4e54a1['Neutral']),_0x20b992['registerOutput']('g',_0x3bb339['Float'],_0x4e54a1['Neutral']),_0x20b992['registerOutput']('b',_0x3bb339['Float'],_0x4e54a1['Neutral']),_0x20b992['registerOutput']('a',_0x3bb339['Float'],_0x4e54a1['Neutral']),_0x20b992['_inputs'][0x0]['acceptedConnectionPointTypes']['push'](_0x3bb339['Vector3']),_0x20b992['_inputs'][0x0]['acceptedConnectionPointTypes']['push'](_0x3bb339['Vector4']),_0x20b992['_inputs'][0x0]['_prioritizeVertex']=!0x1,_0x20b992;}return Object(_0x18e13d['d'])(_0x2a5a68,_0x46db3e),_0x2a5a68['prototype']['getClassName']=function(){return'CurrentScreenBlock';},Object['defineProperty'](_0x2a5a68['prototype'],'uv',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2a5a68['prototype'],'rgba',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2a5a68['prototype'],'rgb',{'get':function(){return this['_outputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2a5a68['prototype'],'r',{'get':function(){return this['_outputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2a5a68['prototype'],'g',{'get':function(){return this['_outputs'][0x3];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2a5a68['prototype'],'b',{'get':function(){return this['_outputs'][0x4];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2a5a68['prototype'],'a',{'get':function(){return this['_outputs'][0x5];},'enumerable':!0x1,'configurable':!0x0}),_0x2a5a68['prototype']['initialize']=function(_0x4a75f2){_0x4a75f2['_excludeVariableName']('textureSampler');},Object['defineProperty'](_0x2a5a68['prototype'],'target',{'get':function(){return this['uv']['isConnected']?this['uv']['sourceBlock']['isInput']?_0x4e54a1['VertexAndFragment']:_0x4e54a1['Fragment']:_0x4e54a1['VertexAndFragment'];},'enumerable':!0x1,'configurable':!0x0}),_0x2a5a68['prototype']['prepareDefines']=function(_0x53df45,_0x40324a,_0x1f24cd){_0x1f24cd['setValue'](this['_linearDefineName'],this['convertToGammaSpace'],!0x0),_0x1f24cd['setValue'](this['_gammaDefineName'],this['convertToLinearSpace'],!0x0);},_0x2a5a68['prototype']['isReady']=function(){return!(this['texture']&&!this['texture']['isReadyOrNotBlocking']());},_0x2a5a68['prototype']['_injectVertexCode']=function(_0x24a397){var _0x4c3875=this['uv'];_0x4c3875['connectedPoint']['ownerBlock']['isInput']&&(_0x4c3875['connectedPoint']['ownerBlock']['isAttribute']||_0x24a397['_emitUniformFromString'](_0x4c3875['associatedVariableName'],'vec2'));if(this['_mainUVName']='vMain'+_0x4c3875['associatedVariableName'],_0x24a397['_emitVaryingFromString'](this['_mainUVName'],'vec2'),_0x24a397['compilationString']+=this['_mainUVName']+'\x20=\x20'+_0x4c3875['associatedVariableName']+'.xy;\x0d\x0a',this['_outputs']['some'](function(_0x59c3ea){return _0x59c3ea['isConnectedInVertexShader'];})){this['_writeTextureRead'](_0x24a397,!0x0);for(var _0x3c65a5=0x0,_0x3ce7d4=this['_outputs'];_0x3c65a5<_0x3ce7d4['length'];_0x3c65a5++){var _0x51414f=_0x3ce7d4[_0x3c65a5];_0x51414f['hasEndpoints']&&this['_writeOutput'](_0x24a397,_0x51414f,_0x51414f['name'],!0x0);}}},_0x2a5a68['prototype']['_writeTextureRead']=function(_0x327c11,_0x47be85){void 0x0===_0x47be85&&(_0x47be85=!0x1);var _0x185bad=this['uv'];if(_0x47be85){if(_0x327c11['target']===_0x4e54a1['Fragment'])return;_0x327c11['compilationString']+='vec4\x20'+this['_tempTextureRead']+'\x20=\x20texture2D('+this['_samplerName']+',\x20'+_0x185bad['associatedVariableName']+');\x0d\x0a';}else this['uv']['ownerBlock']['target']!==_0x4e54a1['Fragment']?_0x327c11['compilationString']+='vec4\x20'+this['_tempTextureRead']+'\x20=\x20texture2D('+this['_samplerName']+',\x20'+this['_mainUVName']+');\x0d\x0a':_0x327c11['compilationString']+='vec4\x20'+this['_tempTextureRead']+'\x20=\x20texture2D('+this['_samplerName']+',\x20'+_0x185bad['associatedVariableName']+');\x0d\x0a';},_0x2a5a68['prototype']['_writeOutput']=function(_0x227371,_0x91b35d,_0x58fd70,_0x263e4c){if(void 0x0===_0x263e4c&&(_0x263e4c=!0x1),_0x263e4c){if(_0x227371['target']===_0x4e54a1['Fragment'])return;_0x227371['compilationString']+=this['_declareOutput'](_0x91b35d,_0x227371)+'\x20=\x20'+this['_tempTextureRead']+'.'+_0x58fd70+';\x0d\x0a';}else this['uv']['ownerBlock']['target']!==_0x4e54a1['Fragment']?(_0x227371['compilationString']+=this['_declareOutput'](_0x91b35d,_0x227371)+'\x20=\x20'+this['_tempTextureRead']+'.'+_0x58fd70+';\x0d\x0a',_0x227371['compilationString']+='#ifdef\x20'+this['_linearDefineName']+'\x0d\x0a',_0x227371['compilationString']+=_0x91b35d['associatedVariableName']+'\x20=\x20toGammaSpace('+_0x91b35d['associatedVariableName']+');\x0d\x0a',_0x227371['compilationString']+='#endif\x0d\x0a',_0x227371['compilationString']+='#ifdef\x20'+this['_gammaDefineName']+'\x0d\x0a',_0x227371['compilationString']+=_0x91b35d['associatedVariableName']+'\x20=\x20toLinearSpace('+_0x91b35d['associatedVariableName']+');\x0d\x0a',_0x227371['compilationString']+='#endif\x0d\x0a'):_0x227371['compilationString']+=this['_declareOutput'](_0x91b35d,_0x227371)+'\x20=\x20'+this['_tempTextureRead']+'.'+_0x58fd70+';\x0d\x0a';},_0x2a5a68['prototype']['_buildBlock']=function(_0x388340){if(_0x46db3e['prototype']['_buildBlock']['call'](this,_0x388340),this['_tempTextureRead']=_0x388340['_getFreeVariableName']('tempTextureRead'),_0x388340['sharedData']['blockingBlocks']['indexOf'](this)<0x0&&_0x388340['sharedData']['blockingBlocks']['push'](this),_0x388340['sharedData']['textureBlocks']['indexOf'](this)<0x0&&_0x388340['sharedData']['textureBlocks']['push'](this),_0x388340['sharedData']['blocksWithDefines']['indexOf'](this)<0x0&&_0x388340['sharedData']['blocksWithDefines']['push'](this),_0x388340['target']!==_0x4e54a1['Fragment'])return _0x388340['_emit2DSampler'](this['_samplerName']),void this['_injectVertexCode'](_0x388340);if(this['_outputs']['some'](function(_0x2c8349){return _0x2c8349['isConnectedInFragmentShader'];})){_0x388340['_emit2DSampler'](this['_samplerName']),this['_linearDefineName']=_0x388340['_getFreeDefineName']('ISLINEAR'),this['_gammaDefineName']=_0x388340['_getFreeDefineName']('ISGAMMA');var _0x5e43e6='//'+this['name'];_0x388340['_emitFunctionFromInclude']('helperFunctions',_0x5e43e6),this['_writeTextureRead'](_0x388340);for(var _0x42ba46=0x0,_0x55a797=this['_outputs'];_0x42ba46<_0x55a797['length'];_0x42ba46++){var _0x13d39d=_0x55a797[_0x42ba46];_0x13d39d['hasEndpoints']&&this['_writeOutput'](_0x388340,_0x13d39d,_0x13d39d['name']);}return this;}},_0x2a5a68['prototype']['serialize']=function(){var _0x542f90=_0x46db3e['prototype']['serialize']['call'](this);return _0x542f90['convertToGammaSpace']=this['convertToGammaSpace'],_0x542f90['convertToLinearSpace']=this['convertToLinearSpace'],this['texture']&&(_0x542f90['texture']=this['texture']['serialize']()),_0x542f90;},_0x2a5a68['prototype']['_deserialize']=function(_0x1351d7,_0x3afb08,_0x5aa048){_0x46db3e['prototype']['_deserialize']['call'](this,_0x1351d7,_0x3afb08,_0x5aa048),this['convertToGammaSpace']=_0x1351d7['convertToGammaSpace'],this['convertToLinearSpace']=!!_0x1351d7['convertToLinearSpace'],_0x1351d7['texture']&&(_0x5aa048=0x0===_0x1351d7['texture']['url']['indexOf']('data:')?'':_0x5aa048,this['texture']=_0xaf3c80['a']['Parse'](_0x1351d7['texture'],_0x3afb08,_0x5aa048));},_0x2a5a68;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.CurrentScreenBlock']=_0x6d15a7;var _0x56dc96=function(_0x10f781){function _0x394865(_0x3d0d9b){var _0x18998e=_0x10f781['call'](this,_0x3d0d9b,_0x4e54a1['Fragment'])||this;return _0x18998e['_samplerName']='diffuseSampler',_0x18998e['convertToGammaSpace']=!0x1,_0x18998e['convertToLinearSpace']=!0x1,_0x18998e['_isUnique']=!0x1,_0x18998e['registerInput']('uv',_0x3bb339['Vector2'],!0x1,_0x4e54a1['VertexAndFragment']),_0x18998e['registerOutput']('rgba',_0x3bb339['Color4'],_0x4e54a1['Neutral']),_0x18998e['registerOutput']('rgb',_0x3bb339['Color3'],_0x4e54a1['Neutral']),_0x18998e['registerOutput']('r',_0x3bb339['Float'],_0x4e54a1['Neutral']),_0x18998e['registerOutput']('g',_0x3bb339['Float'],_0x4e54a1['Neutral']),_0x18998e['registerOutput']('b',_0x3bb339['Float'],_0x4e54a1['Neutral']),_0x18998e['registerOutput']('a',_0x3bb339['Float'],_0x4e54a1['Neutral']),_0x18998e['_inputs'][0x0]['acceptedConnectionPointTypes']['push'](_0x3bb339['Vector3']),_0x18998e['_inputs'][0x0]['acceptedConnectionPointTypes']['push'](_0x3bb339['Vector4']),_0x18998e;}return Object(_0x18e13d['d'])(_0x394865,_0x10f781),_0x394865['prototype']['getClassName']=function(){return'ParticleTextureBlock';},Object['defineProperty'](_0x394865['prototype'],'uv',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x394865['prototype'],'rgba',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x394865['prototype'],'rgb',{'get':function(){return this['_outputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x394865['prototype'],'r',{'get':function(){return this['_outputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x394865['prototype'],'g',{'get':function(){return this['_outputs'][0x3];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x394865['prototype'],'b',{'get':function(){return this['_outputs'][0x4];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x394865['prototype'],'a',{'get':function(){return this['_outputs'][0x5];},'enumerable':!0x1,'configurable':!0x0}),_0x394865['prototype']['initialize']=function(_0x16b333){_0x16b333['_excludeVariableName']('diffuseSampler');},_0x394865['prototype']['autoConfigure']=function(_0xd29360){if(!this['uv']['isConnected']){var _0x545092=_0xd29360['getInputBlockByPredicate'](function(_0x306082){return _0x306082['isAttribute']&&'particle_uv'===_0x306082['name'];});_0x545092||(_0x545092=new _0x581182('uv'))['setAsAttribute']('particle_uv'),_0x545092['output']['connectTo'](this['uv']);}},_0x394865['prototype']['prepareDefines']=function(_0x2014e9,_0x15740d,_0x2b8bcc){_0x2b8bcc['setValue'](this['_linearDefineName'],this['convertToGammaSpace'],!0x0),_0x2b8bcc['setValue'](this['_gammaDefineName'],this['convertToLinearSpace'],!0x0);},_0x394865['prototype']['isReady']=function(){return!(this['texture']&&!this['texture']['isReadyOrNotBlocking']());},_0x394865['prototype']['_writeOutput']=function(_0x202572,_0x417312,_0x12d133){_0x202572['compilationString']+=this['_declareOutput'](_0x417312,_0x202572)+'\x20=\x20'+this['_tempTextureRead']+'.'+_0x12d133+';\x0d\x0a',_0x202572['compilationString']+='#ifdef\x20'+this['_linearDefineName']+'\x0d\x0a',_0x202572['compilationString']+=_0x417312['associatedVariableName']+'\x20=\x20toGammaSpace('+_0x417312['associatedVariableName']+');\x0d\x0a',_0x202572['compilationString']+='#endif\x0d\x0a',_0x202572['compilationString']+='#ifdef\x20'+this['_gammaDefineName']+'\x0d\x0a',_0x202572['compilationString']+=_0x417312['associatedVariableName']+'\x20=\x20toLinearSpace('+_0x417312['associatedVariableName']+');\x0d\x0a',_0x202572['compilationString']+='#endif\x0d\x0a';},_0x394865['prototype']['_buildBlock']=function(_0x4dca43){if(_0x10f781['prototype']['_buildBlock']['call'](this,_0x4dca43),_0x4dca43['target']!==_0x4e54a1['Vertex']){this['_tempTextureRead']=_0x4dca43['_getFreeVariableName']('tempTextureRead'),_0x4dca43['_emit2DSampler'](this['_samplerName']),_0x4dca43['sharedData']['blockingBlocks']['push'](this),_0x4dca43['sharedData']['textureBlocks']['push'](this),_0x4dca43['sharedData']['blocksWithDefines']['push'](this),this['_linearDefineName']=_0x4dca43['_getFreeDefineName']('ISLINEAR'),this['_gammaDefineName']=_0x4dca43['_getFreeDefineName']('ISGAMMA');var _0x515490='//'+this['name'];_0x4dca43['_emitFunctionFromInclude']('helperFunctions',_0x515490),_0x4dca43['compilationString']+='vec4\x20'+this['_tempTextureRead']+'\x20=\x20texture2D('+this['_samplerName']+',\x20'+this['uv']['associatedVariableName']+');\x0d\x0a';for(var _0x1184b9=0x0,_0x3752fe=this['_outputs'];_0x1184b9<_0x3752fe['length'];_0x1184b9++){var _0x21cf9c=_0x3752fe[_0x1184b9];_0x21cf9c['hasEndpoints']&&this['_writeOutput'](_0x4dca43,_0x21cf9c,_0x21cf9c['name']);}return this;}},_0x394865['prototype']['serialize']=function(){var _0x1dfe42=_0x10f781['prototype']['serialize']['call'](this);return _0x1dfe42['convertToGammaSpace']=this['convertToGammaSpace'],_0x1dfe42['convertToLinearSpace']=this['convertToLinearSpace'],this['texture']&&(_0x1dfe42['texture']=this['texture']['serialize']()),_0x1dfe42;},_0x394865['prototype']['_deserialize']=function(_0x54ccbe,_0x53cd69,_0x416ef8){_0x10f781['prototype']['_deserialize']['call'](this,_0x54ccbe,_0x53cd69,_0x416ef8),this['convertToGammaSpace']=_0x54ccbe['convertToGammaSpace'],this['convertToLinearSpace']=!!_0x54ccbe['convertToLinearSpace'],_0x54ccbe['texture']&&(_0x416ef8=0x0===_0x54ccbe['texture']['url']['indexOf']('data:')?'':_0x416ef8,this['texture']=_0xaf3c80['a']['Parse'](_0x54ccbe['texture'],_0x53cd69,_0x416ef8));},_0x394865;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.ParticleTextureBlock']=_0x56dc96;var _0x154efb=function(_0x3a6419){function _0x4ab2b3(_0x89ef45){var _0x42ff38=_0x3a6419['call'](this,_0x89ef45,_0x4e54a1['Fragment'])||this;return _0x42ff38['_isUnique']=!0x0,_0x42ff38['registerInput']('color',_0x3bb339['Color4'],!0x1,_0x4e54a1['Fragment']),_0x42ff38['registerOutput']('rampColor',_0x3bb339['Color4'],_0x4e54a1['Fragment']),_0x42ff38;}return Object(_0x18e13d['d'])(_0x4ab2b3,_0x3a6419),_0x4ab2b3['prototype']['getClassName']=function(){return'ParticleRampGradientBlock';},Object['defineProperty'](_0x4ab2b3['prototype'],'color',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4ab2b3['prototype'],'rampColor',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x4ab2b3['prototype']['initialize']=function(_0x570293){_0x570293['_excludeVariableName']('remapRanges'),_0x570293['_excludeVariableName']('rampSampler'),_0x570293['_excludeVariableName']('baseColor'),_0x570293['_excludeVariableName']('alpha'),_0x570293['_excludeVariableName']('remappedColorIndex'),_0x570293['_excludeVariableName']('rampColor'),_0x570293['_excludeVariableName']('finalAlpha');},_0x4ab2b3['prototype']['_buildBlock']=function(_0x4f7f2f){if(_0x3a6419['prototype']['_buildBlock']['call'](this,_0x4f7f2f),_0x4f7f2f['target']!==_0x4e54a1['Vertex'])return _0x4f7f2f['_emit2DSampler']('rampSampler'),_0x4f7f2f['_emitVaryingFromString']('remapRanges','vec4','RAMPGRADIENT'),_0x4f7f2f['compilationString']+='\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20RAMPGRADIENT\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec4\x20baseColor\x20=\x20'+this['color']['associatedVariableName']+';\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20float\x20alpha\x20=\x20'+this['color']['associatedVariableName']+'.a;\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20float\x20remappedColorIndex\x20=\x20clamp((alpha\x20-\x20remapRanges.x)\x20/\x20remapRanges.y,\x200.0,\x201.0);\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec4\x20rampColor\x20=\x20texture2D(rampSampler,\x20vec2(1.0\x20-\x20remappedColorIndex,\x200.));\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20baseColor.rgb\x20*=\x20rampColor.rgb;\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20Remapped\x20alpha\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20float\x20finalAlpha\x20=\x20baseColor.a;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20baseColor.a\x20=\x20clamp((alpha\x20*\x20rampColor.a\x20-\x20remapRanges.z)\x20/\x20remapRanges.w,\x200.0,\x201.0);\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+this['_declareOutput'](this['rampColor'],_0x4f7f2f)+'\x20=\x20baseColor;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#else\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+this['_declareOutput'](this['rampColor'],_0x4f7f2f)+'\x20=\x20'+this['color']['associatedVariableName']+';\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x20\x20\x20\x20\x20\x20\x20\x20',this;},_0x4ab2b3;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.ParticleRampGradientBlock']=_0x154efb;var _0x4bafb1=function(_0x2d46a5){function _0x1cdf37(_0x42dfe8){var _0x919e2f=_0x2d46a5['call'](this,_0x42dfe8,_0x4e54a1['Fragment'])||this;return _0x919e2f['_isUnique']=!0x0,_0x919e2f['registerInput']('color',_0x3bb339['Color4'],!0x1,_0x4e54a1['Fragment']),_0x919e2f['registerInput']('alphaTexture',_0x3bb339['Float'],!0x1,_0x4e54a1['Fragment']),_0x919e2f['registerInput']('alphaColor',_0x3bb339['Float'],!0x1,_0x4e54a1['Fragment']),_0x919e2f['registerOutput']('blendColor',_0x3bb339['Color4'],_0x4e54a1['Fragment']),_0x919e2f;}return Object(_0x18e13d['d'])(_0x1cdf37,_0x2d46a5),_0x1cdf37['prototype']['getClassName']=function(){return'ParticleBlendMultiplyBlock';},Object['defineProperty'](_0x1cdf37['prototype'],'color',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1cdf37['prototype'],'alphaTexture',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1cdf37['prototype'],'alphaColor',{'get':function(){return this['_inputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1cdf37['prototype'],'blendColor',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x1cdf37['prototype']['initialize']=function(_0x4c8c14){_0x4c8c14['_excludeVariableName']('sourceAlpha');},_0x1cdf37['prototype']['_buildBlock']=function(_0x5702fb){if(_0x2d46a5['prototype']['_buildBlock']['call'](this,_0x5702fb),_0x5702fb['target']!==_0x4e54a1['Vertex'])return _0x5702fb['compilationString']+='\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20BLENDMULTIPLYMODE\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+this['_declareOutput'](this['blendColor'],_0x5702fb)+';\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20float\x20sourceAlpha\x20=\x20'+this['alphaColor']['associatedVariableName']+'\x20*\x20'+this['alphaTexture']['associatedVariableName']+';\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+this['blendColor']['associatedVariableName']+'.rgb\x20=\x20'+this['color']['associatedVariableName']+'.rgb\x20*\x20sourceAlpha\x20+\x20vec3(1.0)\x20*\x20(1.0\x20-\x20sourceAlpha);\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+this['blendColor']['associatedVariableName']+'.a\x20=\x20'+this['color']['associatedVariableName']+'.a;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#else\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+this['_declareOutput'](this['blendColor'],_0x5702fb)+'\x20=\x20'+this['color']['associatedVariableName']+';\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x20\x20\x20\x20\x20\x20\x20\x20',this;},_0x1cdf37;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.ParticleBlendMultiplyBlock']=_0x4bafb1;var _0x4bd31d,_0x2ef6e9=function(_0x495fe5){function _0x7261b5(_0x340cf7){var _0x140931=_0x495fe5['call'](this,_0x340cf7,_0x4e54a1['Neutral'])||this;return _0x140931['registerInput']('xyz\x20',_0x3bb339['Vector3'],!0x0),_0x140931['registerInput']('xy\x20',_0x3bb339['Vector2'],!0x0),_0x140931['registerInput']('x',_0x3bb339['Float'],!0x0),_0x140931['registerInput']('y',_0x3bb339['Float'],!0x0),_0x140931['registerInput']('z',_0x3bb339['Float'],!0x0),_0x140931['registerInput']('w',_0x3bb339['Float'],!0x0),_0x140931['registerOutput']('xyzw',_0x3bb339['Vector4']),_0x140931['registerOutput']('xyz',_0x3bb339['Vector3']),_0x140931['registerOutput']('xy',_0x3bb339['Vector2']),_0x140931;}return Object(_0x18e13d['d'])(_0x7261b5,_0x495fe5),_0x7261b5['prototype']['getClassName']=function(){return'VectorMergerBlock';},Object['defineProperty'](_0x7261b5['prototype'],'xyzIn',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x7261b5['prototype'],'xyIn',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x7261b5['prototype'],'x',{'get':function(){return this['_inputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x7261b5['prototype'],'y',{'get':function(){return this['_inputs'][0x3];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x7261b5['prototype'],'z',{'get':function(){return this['_inputs'][0x4];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x7261b5['prototype'],'w',{'get':function(){return this['_inputs'][0x5];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x7261b5['prototype'],'xyzw',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x7261b5['prototype'],'xyzOut',{'get':function(){return this['_outputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x7261b5['prototype'],'xyOut',{'get':function(){return this['_outputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x7261b5['prototype'],'xy',{'get':function(){return this['xyOut'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x7261b5['prototype'],'xyz',{'get':function(){return this['xyzOut'];},'enumerable':!0x1,'configurable':!0x0}),_0x7261b5['prototype']['_buildBlock']=function(_0x14cdff){_0x495fe5['prototype']['_buildBlock']['call'](this,_0x14cdff);var _0x17295d=this['x'],_0x3dcf22=this['y'],_0x581384=this['z'],_0x12ef29=this['w'],_0x3e15d8=this['xyIn'],_0x46e66e=this['xyzIn'],_0x2fdd68=this['_outputs'][0x0],_0x1fa18e=this['_outputs'][0x1],_0x48a018=this['_outputs'][0x2];return _0x46e66e['isConnected']?_0x2fdd68['hasEndpoints']?_0x14cdff['compilationString']+=this['_declareOutput'](_0x2fdd68,_0x14cdff)+'\x20=\x20vec4('+_0x46e66e['associatedVariableName']+',\x20'+(_0x12ef29['isConnected']?this['_writeVariable'](_0x12ef29):'0.0')+');\x0d\x0a':_0x1fa18e['hasEndpoints']?_0x14cdff['compilationString']+=this['_declareOutput'](_0x1fa18e,_0x14cdff)+'\x20=\x20'+_0x46e66e['associatedVariableName']+';\x0d\x0a':_0x48a018['hasEndpoints']&&(_0x14cdff['compilationString']+=this['_declareOutput'](_0x48a018,_0x14cdff)+'\x20=\x20'+_0x46e66e['associatedVariableName']+'.xy;\x0d\x0a'):_0x3e15d8['isConnected']?_0x2fdd68['hasEndpoints']?_0x14cdff['compilationString']+=this['_declareOutput'](_0x2fdd68,_0x14cdff)+'\x20=\x20vec4('+_0x3e15d8['associatedVariableName']+',\x20'+(_0x581384['isConnected']?this['_writeVariable'](_0x581384):'0.0')+',\x20'+(_0x12ef29['isConnected']?this['_writeVariable'](_0x12ef29):'0.0')+');\x0d\x0a':_0x1fa18e['hasEndpoints']?_0x14cdff['compilationString']+=this['_declareOutput'](_0x1fa18e,_0x14cdff)+'\x20=\x20vec3('+_0x3e15d8['associatedVariableName']+',\x20'+(_0x581384['isConnected']?this['_writeVariable'](_0x581384):'0.0')+');\x0d\x0a':_0x48a018['hasEndpoints']&&(_0x14cdff['compilationString']+=this['_declareOutput'](_0x48a018,_0x14cdff)+'\x20=\x20'+_0x3e15d8['associatedVariableName']+';\x0d\x0a'):_0x2fdd68['hasEndpoints']?_0x14cdff['compilationString']+=this['_declareOutput'](_0x2fdd68,_0x14cdff)+'\x20=\x20vec4('+(_0x17295d['isConnected']?this['_writeVariable'](_0x17295d):'0.0')+',\x20'+(_0x3dcf22['isConnected']?this['_writeVariable'](_0x3dcf22):'0.0')+',\x20'+(_0x581384['isConnected']?this['_writeVariable'](_0x581384):'0.0')+',\x20'+(_0x12ef29['isConnected']?this['_writeVariable'](_0x12ef29):'0.0')+');\x0d\x0a':_0x1fa18e['hasEndpoints']?_0x14cdff['compilationString']+=this['_declareOutput'](_0x1fa18e,_0x14cdff)+'\x20=\x20vec3('+(_0x17295d['isConnected']?this['_writeVariable'](_0x17295d):'0.0')+',\x20'+(_0x3dcf22['isConnected']?this['_writeVariable'](_0x3dcf22):'0.0')+',\x20'+(_0x581384['isConnected']?this['_writeVariable'](_0x581384):'0.0')+');\x0d\x0a':_0x48a018['hasEndpoints']&&(_0x14cdff['compilationString']+=this['_declareOutput'](_0x48a018,_0x14cdff)+'\x20=\x20vec2('+(_0x17295d['isConnected']?this['_writeVariable'](_0x17295d):'0.0')+',\x20'+(_0x3dcf22['isConnected']?this['_writeVariable'](_0x3dcf22):'0.0')+');\x0d\x0a'),this;},_0x7261b5;}(_0x52300e);function _0x148e9b(_0x6ab4da,_0x384487,_0xe33a3b,_0x29df1a){return void 0x0===_0x384487&&(_0x384487=_0x4bd31d['Boolean']),void 0x0===_0xe33a3b&&(_0xe33a3b='PROPERTIES'),function(_0x3e68df,_0x1ca3e8){var _0x213e00=_0x3e68df['_propStore'];_0x213e00||(_0x213e00=[],_0x3e68df['_propStore']=_0x213e00),_0x213e00['push']({'propertyName':_0x1ca3e8,'displayName':_0x6ab4da,'type':_0x384487,'groupName':_0xe33a3b,'options':null!=_0x29df1a?_0x29df1a:{}});};}_0x3cd573['a']['RegisteredTypes']['BABYLON.VectorMergerBlock']=_0x2ef6e9,function(_0x5d1dbc){_0x5d1dbc[_0x5d1dbc['Boolean']=0x0]='Boolean',_0x5d1dbc[_0x5d1dbc['Float']=0x1]='Float',_0x5d1dbc[_0x5d1dbc['Vector2']=0x2]='Vector2',_0x5d1dbc[_0x5d1dbc['List']=0x3]='List';}(_0x4bd31d||(_0x4bd31d={}));var _0x662ea4=function(_0x53dfa2){function _0x17ba38(_0xca8d3d){var _0x33a6f1=_0x53dfa2['call'](this,_0xca8d3d,_0x4e54a1['Neutral'])||this;return _0x33a6f1['sourceRange']=new _0x74d525['d'](-0x1,0x1),_0x33a6f1['targetRange']=new _0x74d525['d'](0x0,0x1),_0x33a6f1['registerInput']('input',_0x3bb339['AutoDetect']),_0x33a6f1['registerInput']('sourceMin',_0x3bb339['Float'],!0x0),_0x33a6f1['registerInput']('sourceMax',_0x3bb339['Float'],!0x0),_0x33a6f1['registerInput']('targetMin',_0x3bb339['Float'],!0x0),_0x33a6f1['registerInput']('targetMax',_0x3bb339['Float'],!0x0),_0x33a6f1['registerOutput']('output',_0x3bb339['BasedOnInput']),_0x33a6f1['_outputs'][0x0]['_typeConnectionSource']=_0x33a6f1['_inputs'][0x0],_0x33a6f1;}return Object(_0x18e13d['d'])(_0x17ba38,_0x53dfa2),_0x17ba38['prototype']['getClassName']=function(){return'RemapBlock';},Object['defineProperty'](_0x17ba38['prototype'],'input',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x17ba38['prototype'],'sourceMin',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x17ba38['prototype'],'sourceMax',{'get':function(){return this['_inputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x17ba38['prototype'],'targetMin',{'get':function(){return this['_inputs'][0x3];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x17ba38['prototype'],'targetMax',{'get':function(){return this['_inputs'][0x4];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x17ba38['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x17ba38['prototype']['_buildBlock']=function(_0x52016f){_0x53dfa2['prototype']['_buildBlock']['call'](this,_0x52016f);var _0x57da52=this['_outputs'][0x0],_0x4ad0cc=this['sourceMin']['isConnected']?this['sourceMin']['associatedVariableName']:this['_writeFloat'](this['sourceRange']['x']),_0x385d59=this['sourceMax']['isConnected']?this['sourceMax']['associatedVariableName']:this['_writeFloat'](this['sourceRange']['y']),_0x4b876c=this['targetMin']['isConnected']?this['targetMin']['associatedVariableName']:this['_writeFloat'](this['targetRange']['x']),_0x4a14e6=this['targetMax']['isConnected']?this['targetMax']['associatedVariableName']:this['_writeFloat'](this['targetRange']['y']);return _0x52016f['compilationString']+=this['_declareOutput'](_0x57da52,_0x52016f)+'\x20=\x20'+_0x4b876c+'\x20+\x20('+this['_inputs'][0x0]['associatedVariableName']+'\x20-\x20'+_0x4ad0cc+')\x20*\x20('+_0x4a14e6+'\x20-\x20'+_0x4b876c+')\x20/\x20('+_0x385d59+'\x20-\x20'+_0x4ad0cc+');\x0d\x0a',this;},_0x17ba38['prototype']['_dumpPropertiesCode']=function(){var _0x22c61a=this['_codeVariableName']+'.sourceRange\x20=\x20new\x20BABYLON.Vector2('+this['sourceRange']['x']+',\x20'+this['sourceRange']['y']+');\x0d\x0a';return _0x22c61a+=this['_codeVariableName']+'.targetRange\x20=\x20new\x20BABYLON.Vector2('+this['targetRange']['x']+',\x20'+this['targetRange']['y']+');\x0d\x0a';},_0x17ba38['prototype']['serialize']=function(){var _0x5ca1cd=_0x53dfa2['prototype']['serialize']['call'](this);return _0x5ca1cd['sourceRange']=this['sourceRange']['asArray'](),_0x5ca1cd['targetRange']=this['targetRange']['asArray'](),_0x5ca1cd;},_0x17ba38['prototype']['_deserialize']=function(_0x1b28e9,_0x170841,_0x13ba0a){_0x53dfa2['prototype']['_deserialize']['call'](this,_0x1b28e9,_0x170841,_0x13ba0a),this['sourceRange']=_0x74d525['d']['FromArray'](_0x1b28e9['sourceRange']),this['targetRange']=_0x74d525['d']['FromArray'](_0x1b28e9['targetRange']);},Object(_0x18e13d['c'])([_0x148e9b('From',_0x4bd31d['Vector2'])],_0x17ba38['prototype'],'sourceRange',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('To',_0x4bd31d['Vector2'])],_0x17ba38['prototype'],'targetRange',void 0x0),_0x17ba38;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.RemapBlock']=_0x662ea4;var _0x4b8ff3=function(_0x437067){function _0x19514d(_0x160c28){var _0x558a6e=_0x437067['call'](this,_0x160c28,_0x4e54a1['Neutral'])||this;return _0x558a6e['registerInput']('left',_0x3bb339['AutoDetect']),_0x558a6e['registerInput']('right',_0x3bb339['AutoDetect']),_0x558a6e['registerOutput']('output',_0x3bb339['BasedOnInput']),_0x558a6e['_outputs'][0x0]['_typeConnectionSource']=_0x558a6e['_inputs'][0x0],_0x558a6e['_linkConnectionTypes'](0x0,0x1),_0x558a6e;}return Object(_0x18e13d['d'])(_0x19514d,_0x437067),_0x19514d['prototype']['getClassName']=function(){return'MultiplyBlock';},Object['defineProperty'](_0x19514d['prototype'],'left',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x19514d['prototype'],'right',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x19514d['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x19514d['prototype']['_buildBlock']=function(_0x79891d){_0x437067['prototype']['_buildBlock']['call'](this,_0x79891d);var _0x1ef422=this['_outputs'][0x0];return _0x79891d['compilationString']+=this['_declareOutput'](_0x1ef422,_0x79891d)+'\x20=\x20'+this['left']['associatedVariableName']+'\x20*\x20'+this['right']['associatedVariableName']+';\x0d\x0a',this;},_0x19514d;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.MultiplyBlock']=_0x4b8ff3;var _0x3faf18=(function(){function _0x1aee65(){this['direction1']=new _0x74d525['e'](0x0,0x1,0x0),this['direction2']=new _0x74d525['e'](0x0,0x1,0x0),this['minEmitBox']=new _0x74d525['e'](-0.5,-0.5,-0.5),this['maxEmitBox']=new _0x74d525['e'](0.5,0.5,0.5);}return _0x1aee65['prototype']['startDirectionFunction']=function(_0x52dbb2,_0x1e7e93,_0x6fba20,_0x9bfbf5){var _0x55d9cd=_0x4a0cf0['a']['RandomRange'](this['direction1']['x'],this['direction2']['x']),_0x331d68=_0x4a0cf0['a']['RandomRange'](this['direction1']['y'],this['direction2']['y']),_0x1a99ec=_0x4a0cf0['a']['RandomRange'](this['direction1']['z'],this['direction2']['z']);if(_0x9bfbf5)return _0x1e7e93['x']=_0x55d9cd,_0x1e7e93['y']=_0x331d68,void(_0x1e7e93['z']=_0x1a99ec);_0x74d525['e']['TransformNormalFromFloatsToRef'](_0x55d9cd,_0x331d68,_0x1a99ec,_0x52dbb2,_0x1e7e93);},_0x1aee65['prototype']['startPositionFunction']=function(_0x42d761,_0x71e7ed,_0x325d4c,_0x195137){var _0x1e361=_0x4a0cf0['a']['RandomRange'](this['minEmitBox']['x'],this['maxEmitBox']['x']),_0x1c4df6=_0x4a0cf0['a']['RandomRange'](this['minEmitBox']['y'],this['maxEmitBox']['y']),_0x4c37e5=_0x4a0cf0['a']['RandomRange'](this['minEmitBox']['z'],this['maxEmitBox']['z']);if(_0x195137)return _0x71e7ed['x']=_0x1e361,_0x71e7ed['y']=_0x1c4df6,void(_0x71e7ed['z']=_0x4c37e5);_0x74d525['e']['TransformCoordinatesFromFloatsToRef'](_0x1e361,_0x1c4df6,_0x4c37e5,_0x42d761,_0x71e7ed);},_0x1aee65['prototype']['clone']=function(){var _0x1cff1c=new _0x1aee65();return _0x5d9c83['a']['DeepCopy'](this,_0x1cff1c),_0x1cff1c;},_0x1aee65['prototype']['applyToShader']=function(_0x5f12de){_0x5f12de['setVector3']('direction1',this['direction1']),_0x5f12de['setVector3']('direction2',this['direction2']),_0x5f12de['setVector3']('minEmitBox',this['minEmitBox']),_0x5f12de['setVector3']('maxEmitBox',this['maxEmitBox']);},_0x1aee65['prototype']['getEffectDefines']=function(){return'#define\x20BOXEMITTER';},_0x1aee65['prototype']['getClassName']=function(){return'BoxParticleEmitter';},_0x1aee65['prototype']['serialize']=function(){var _0x2056d0={};return _0x2056d0['type']=this['getClassName'](),_0x2056d0['direction1']=this['direction1']['asArray'](),_0x2056d0['direction2']=this['direction2']['asArray'](),_0x2056d0['minEmitBox']=this['minEmitBox']['asArray'](),_0x2056d0['maxEmitBox']=this['maxEmitBox']['asArray'](),_0x2056d0;},_0x1aee65['prototype']['parse']=function(_0x2ab733){_0x74d525['e']['FromArrayToRef'](_0x2ab733['direction1'],0x0,this['direction1']),_0x74d525['e']['FromArrayToRef'](_0x2ab733['direction2'],0x0,this['direction2']),_0x74d525['e']['FromArrayToRef'](_0x2ab733['minEmitBox'],0x0,this['minEmitBox']),_0x74d525['e']['FromArrayToRef'](_0x2ab733['maxEmitBox'],0x0,this['maxEmitBox']);},_0x1aee65;}()),_0x2cb2ef=(function(){function _0x322eac(_0x1f56bf,_0x29392b,_0x52f679){void 0x0===_0x1f56bf&&(_0x1f56bf=0x1),void 0x0===_0x29392b&&(_0x29392b=Math['PI']),void 0x0===_0x52f679&&(_0x52f679=0x0),this['directionRandomizer']=_0x52f679,this['radiusRange']=0x1,this['heightRange']=0x1,this['emitFromSpawnPointOnly']=!0x1,this['angle']=_0x29392b,this['radius']=_0x1f56bf;}return Object['defineProperty'](_0x322eac['prototype'],'radius',{'get':function(){return this['_radius'];},'set':function(_0x450d99){this['_radius']=_0x450d99,this['_buildHeight']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x322eac['prototype'],'angle',{'get':function(){return this['_angle'];},'set':function(_0x103a44){this['_angle']=_0x103a44,this['_buildHeight']();},'enumerable':!0x1,'configurable':!0x0}),_0x322eac['prototype']['_buildHeight']=function(){0x0!==this['_angle']?this['_height']=this['_radius']/Math['tan'](this['_angle']/0x2):this['_height']=0x1;},_0x322eac['prototype']['startDirectionFunction']=function(_0x42cb0b,_0x519cab,_0x412b5c,_0x179e23){_0x179e23?_0x74d525['c']['Vector3'][0x0]['copyFrom'](_0x412b5c['_localPosition'])['normalize']():_0x412b5c['position']['subtractToRef'](_0x42cb0b['getTranslation'](),_0x74d525['c']['Vector3'][0x0])['normalize']();var _0x2cda55=_0x4a0cf0['a']['RandomRange'](0x0,this['directionRandomizer']),_0x29ee88=_0x4a0cf0['a']['RandomRange'](0x0,this['directionRandomizer']),_0x18ff60=_0x4a0cf0['a']['RandomRange'](0x0,this['directionRandomizer']);_0x519cab['x']=_0x74d525['c']['Vector3'][0x0]['x']+_0x2cda55,_0x519cab['y']=_0x74d525['c']['Vector3'][0x0]['y']+_0x29ee88,_0x519cab['z']=_0x74d525['c']['Vector3'][0x0]['z']+_0x18ff60,_0x519cab['normalize']();},_0x322eac['prototype']['startPositionFunction']=function(_0x58c8bf,_0x22b92a,_0xc6e562,_0x176565){var _0x1c5495,_0x474747=_0x4a0cf0['a']['RandomRange'](0x0,0x2*Math['PI']);_0x1c5495=this['emitFromSpawnPointOnly']?0.0001:0x1-(_0x1c5495=_0x4a0cf0['a']['RandomRange'](0x0,this['heightRange']))*_0x1c5495;var _0x4c803b=this['_radius']-_0x4a0cf0['a']['RandomRange'](0x0,this['_radius']*this['radiusRange']),_0x8a0b67=(_0x4c803b*=_0x1c5495)*Math['sin'](_0x474747),_0x4388ae=_0x4c803b*Math['cos'](_0x474747),_0x46312b=_0x1c5495*this['_height'];if(_0x176565)return _0x22b92a['x']=_0x8a0b67,_0x22b92a['y']=_0x46312b,void(_0x22b92a['z']=_0x4388ae);_0x74d525['e']['TransformCoordinatesFromFloatsToRef'](_0x8a0b67,_0x46312b,_0x4388ae,_0x58c8bf,_0x22b92a);},_0x322eac['prototype']['clone']=function(){var _0x21aac7=new _0x322eac(this['_radius'],this['_angle'],this['directionRandomizer']);return _0x5d9c83['a']['DeepCopy'](this,_0x21aac7),_0x21aac7;},_0x322eac['prototype']['applyToShader']=function(_0x3eaa01){_0x3eaa01['setFloat2']('radius',this['_radius'],this['radiusRange']),_0x3eaa01['setFloat']('coneAngle',this['_angle']),_0x3eaa01['setFloat2']('height',this['_height'],this['heightRange']),_0x3eaa01['setFloat']('directionRandomizer',this['directionRandomizer']);},_0x322eac['prototype']['getEffectDefines']=function(){var _0x296950='#define\x20CONEEMITTER';return this['emitFromSpawnPointOnly']&&(_0x296950+='\x0a#define\x20CONEEMITTERSPAWNPOINT'),_0x296950;},_0x322eac['prototype']['getClassName']=function(){return'ConeParticleEmitter';},_0x322eac['prototype']['serialize']=function(){var _0x4f7635={};return _0x4f7635['type']=this['getClassName'](),_0x4f7635['radius']=this['_radius'],_0x4f7635['angle']=this['_angle'],_0x4f7635['directionRandomizer']=this['directionRandomizer'],_0x4f7635['radiusRange']=this['radiusRange'],_0x4f7635['heightRange']=this['heightRange'],_0x4f7635['emitFromSpawnPointOnly']=this['emitFromSpawnPointOnly'],_0x4f7635;},_0x322eac['prototype']['parse']=function(_0x44ce88){this['radius']=_0x44ce88['radius'],this['angle']=_0x44ce88['angle'],this['directionRandomizer']=_0x44ce88['directionRandomizer'],this['radiusRange']=void 0x0!==_0x44ce88['radiusRange']?_0x44ce88['radiusRange']:0x1,this['heightRange']=void 0x0!==_0x44ce88['radiusRange']?_0x44ce88['heightRange']:0x1,this['emitFromSpawnPointOnly']=void 0x0!==_0x44ce88['emitFromSpawnPointOnly']&&_0x44ce88['emitFromSpawnPointOnly'];},_0x322eac;}()),_0x4c9a66=(function(){function _0x2cc393(_0x16c079,_0x177a94,_0x51ad22,_0xd77eab){void 0x0===_0x16c079&&(_0x16c079=0x1),void 0x0===_0x177a94&&(_0x177a94=0x1),void 0x0===_0x51ad22&&(_0x51ad22=0x1),void 0x0===_0xd77eab&&(_0xd77eab=0x0),this['radius']=_0x16c079,this['height']=_0x177a94,this['radiusRange']=_0x51ad22,this['directionRandomizer']=_0xd77eab;}return _0x2cc393['prototype']['startDirectionFunction']=function(_0x393558,_0x39aa5a,_0x1cc7e5,_0x5b5373){var _0x47067a=_0x1cc7e5['position']['subtract'](_0x393558['getTranslation']())['normalize'](),_0x4cffd8=_0x4a0cf0['a']['RandomRange'](-this['directionRandomizer']/0x2,this['directionRandomizer']/0x2),_0x249061=Math['atan2'](_0x47067a['x'],_0x47067a['z']);_0x249061+=_0x4a0cf0['a']['RandomRange'](-Math['PI']/0x2,Math['PI']/0x2)*this['directionRandomizer'],_0x47067a['y']=_0x4cffd8,_0x47067a['x']=Math['sin'](_0x249061),_0x47067a['z']=Math['cos'](_0x249061),_0x47067a['normalize'](),_0x5b5373?_0x39aa5a['copyFrom'](_0x47067a):_0x74d525['e']['TransformNormalFromFloatsToRef'](_0x47067a['x'],_0x47067a['y'],_0x47067a['z'],_0x393558,_0x39aa5a);},_0x2cc393['prototype']['startPositionFunction']=function(_0x57657d,_0x112c6e,_0x416473,_0x2f554e){var _0x476a38=_0x4a0cf0['a']['RandomRange'](-this['height']/0x2,this['height']/0x2),_0x41bc97=_0x4a0cf0['a']['RandomRange'](0x0,0x2*Math['PI']),_0x414b7d=_0x4a0cf0['a']['RandomRange']((0x1-this['radiusRange'])*(0x1-this['radiusRange']),0x1),_0x5e0f59=Math['sqrt'](_0x414b7d)*this['radius'],_0x320519=_0x5e0f59*Math['cos'](_0x41bc97),_0x4324ee=_0x5e0f59*Math['sin'](_0x41bc97);_0x2f554e?_0x112c6e['copyFromFloats'](_0x320519,_0x476a38,_0x4324ee):_0x74d525['e']['TransformCoordinatesFromFloatsToRef'](_0x320519,_0x476a38,_0x4324ee,_0x57657d,_0x112c6e);},_0x2cc393['prototype']['clone']=function(){var _0x1bdf65=new _0x2cc393(this['radius'],this['directionRandomizer']);return _0x5d9c83['a']['DeepCopy'](this,_0x1bdf65),_0x1bdf65;},_0x2cc393['prototype']['applyToShader']=function(_0x4557bb){_0x4557bb['setFloat']('radius',this['radius']),_0x4557bb['setFloat']('height',this['height']),_0x4557bb['setFloat']('radiusRange',this['radiusRange']),_0x4557bb['setFloat']('directionRandomizer',this['directionRandomizer']);},_0x2cc393['prototype']['getEffectDefines']=function(){return'#define\x20CYLINDEREMITTER';},_0x2cc393['prototype']['getClassName']=function(){return'CylinderParticleEmitter';},_0x2cc393['prototype']['serialize']=function(){var _0x82a8f5={};return _0x82a8f5['type']=this['getClassName'](),_0x82a8f5['radius']=this['radius'],_0x82a8f5['height']=this['height'],_0x82a8f5['radiusRange']=this['radiusRange'],_0x82a8f5['directionRandomizer']=this['directionRandomizer'],_0x82a8f5;},_0x2cc393['prototype']['parse']=function(_0x229d27){this['radius']=_0x229d27['radius'],this['height']=_0x229d27['height'],this['radiusRange']=_0x229d27['radiusRange'],this['directionRandomizer']=_0x229d27['directionRandomizer'];},_0x2cc393;}()),_0x1b1b95=function(_0x195936){function _0x22c26a(_0x133b16,_0x48ed6d,_0x2cb05f,_0x1c7460,_0x1ad9a0){void 0x0===_0x133b16&&(_0x133b16=0x1),void 0x0===_0x48ed6d&&(_0x48ed6d=0x1),void 0x0===_0x2cb05f&&(_0x2cb05f=0x1),void 0x0===_0x1c7460&&(_0x1c7460=new _0x74d525['e'](0x0,0x1,0x0)),void 0x0===_0x1ad9a0&&(_0x1ad9a0=new _0x74d525['e'](0x0,0x1,0x0));var _0x12e594=_0x195936['call'](this,_0x133b16,_0x48ed6d,_0x2cb05f)||this;return _0x12e594['direction1']=_0x1c7460,_0x12e594['direction2']=_0x1ad9a0,_0x12e594;}return Object(_0x18e13d['d'])(_0x22c26a,_0x195936),_0x22c26a['prototype']['startDirectionFunction']=function(_0x4abaa6,_0x55518e,_0x4f7bce){var _0x472f2a=_0x4a0cf0['a']['RandomRange'](this['direction1']['x'],this['direction2']['x']),_0x5a836c=_0x4a0cf0['a']['RandomRange'](this['direction1']['y'],this['direction2']['y']),_0xafabf6=_0x4a0cf0['a']['RandomRange'](this['direction1']['z'],this['direction2']['z']);_0x74d525['e']['TransformNormalFromFloatsToRef'](_0x472f2a,_0x5a836c,_0xafabf6,_0x4abaa6,_0x55518e);},_0x22c26a['prototype']['clone']=function(){var _0x13d393=new _0x22c26a(this['radius'],this['height'],this['radiusRange'],this['direction1'],this['direction2']);return _0x5d9c83['a']['DeepCopy'](this,_0x13d393),_0x13d393;},_0x22c26a['prototype']['applyToShader']=function(_0x4d39d5){_0x4d39d5['setFloat']('radius',this['radius']),_0x4d39d5['setFloat']('height',this['height']),_0x4d39d5['setFloat']('radiusRange',this['radiusRange']),_0x4d39d5['setVector3']('direction1',this['direction1']),_0x4d39d5['setVector3']('direction2',this['direction2']);},_0x22c26a['prototype']['getEffectDefines']=function(){return'#define\x20CYLINDEREMITTER\x0a#define\x20DIRECTEDCYLINDEREMITTER';},_0x22c26a['prototype']['getClassName']=function(){return'CylinderDirectedParticleEmitter';},_0x22c26a['prototype']['serialize']=function(){var _0xc6c494=_0x195936['prototype']['serialize']['call'](this);return _0xc6c494['direction1']=this['direction1']['asArray'](),_0xc6c494['direction2']=this['direction2']['asArray'](),_0xc6c494;},_0x22c26a['prototype']['parse']=function(_0x12dac0){_0x195936['prototype']['parse']['call'](this,_0x12dac0),this['direction1']['copyFrom'](_0x12dac0['direction1']),this['direction2']['copyFrom'](_0x12dac0['direction2']);},_0x22c26a;}(_0x4c9a66),_0x18cf99=(function(){function _0x2a8cb8(_0x42545f,_0xcdc7a9,_0x1779b0){void 0x0===_0x42545f&&(_0x42545f=0x1),void 0x0===_0xcdc7a9&&(_0xcdc7a9=0x1),void 0x0===_0x1779b0&&(_0x1779b0=0x0),this['radius']=_0x42545f,this['radiusRange']=_0xcdc7a9,this['directionRandomizer']=_0x1779b0;}return _0x2a8cb8['prototype']['startDirectionFunction']=function(_0x39af54,_0x2f3704,_0xb702ac,_0x1a3b64){var _0x2c2277=_0xb702ac['position']['subtract'](_0x39af54['getTranslation']())['normalize'](),_0x19a29f=_0x4a0cf0['a']['RandomRange'](0x0,this['directionRandomizer']),_0x537b52=_0x4a0cf0['a']['RandomRange'](0x0,this['directionRandomizer']),_0x22c954=_0x4a0cf0['a']['RandomRange'](0x0,this['directionRandomizer']);_0x2c2277['x']+=_0x19a29f,_0x2c2277['y']+=_0x537b52,_0x2c2277['z']+=_0x22c954,_0x2c2277['normalize'](),_0x1a3b64?_0x2f3704['copyFrom'](_0x2c2277):_0x74d525['e']['TransformNormalFromFloatsToRef'](_0x2c2277['x'],_0x2c2277['y'],_0x2c2277['z'],_0x39af54,_0x2f3704);},_0x2a8cb8['prototype']['startPositionFunction']=function(_0x36a98e,_0xc30dd,_0x530316,_0xdfb329){var _0x50b02b=this['radius']-_0x4a0cf0['a']['RandomRange'](0x0,this['radius']*this['radiusRange']),_0x527134=_0x4a0cf0['a']['RandomRange'](0x0,0x1),_0x547c66=_0x4a0cf0['a']['RandomRange'](0x0,0x2*Math['PI']),_0x1b9b72=Math['acos'](0x2*_0x527134-0x1),_0x4bc413=_0x50b02b*Math['cos'](_0x547c66)*Math['sin'](_0x1b9b72),_0x85c823=_0x50b02b*Math['cos'](_0x1b9b72),_0x52b485=_0x50b02b*Math['sin'](_0x547c66)*Math['sin'](_0x1b9b72);_0xdfb329?_0xc30dd['copyFromFloats'](_0x4bc413,Math['abs'](_0x85c823),_0x52b485):_0x74d525['e']['TransformCoordinatesFromFloatsToRef'](_0x4bc413,Math['abs'](_0x85c823),_0x52b485,_0x36a98e,_0xc30dd);},_0x2a8cb8['prototype']['clone']=function(){var _0x7ea045=new _0x2a8cb8(this['radius'],this['directionRandomizer']);return _0x5d9c83['a']['DeepCopy'](this,_0x7ea045),_0x7ea045;},_0x2a8cb8['prototype']['applyToShader']=function(_0x13ef4e){_0x13ef4e['setFloat']('radius',this['radius']),_0x13ef4e['setFloat']('radiusRange',this['radiusRange']),_0x13ef4e['setFloat']('directionRandomizer',this['directionRandomizer']);},_0x2a8cb8['prototype']['getEffectDefines']=function(){return'#define\x20HEMISPHERICEMITTER';},_0x2a8cb8['prototype']['getClassName']=function(){return'HemisphericParticleEmitter';},_0x2a8cb8['prototype']['serialize']=function(){var _0x3795d4={};return _0x3795d4['type']=this['getClassName'](),_0x3795d4['radius']=this['radius'],_0x3795d4['radiusRange']=this['radiusRange'],_0x3795d4['directionRandomizer']=this['directionRandomizer'],_0x3795d4;},_0x2a8cb8['prototype']['parse']=function(_0x4a23f3){this['radius']=_0x4a23f3['radius'],this['radiusRange']=_0x4a23f3['radiusRange'],this['directionRandomizer']=_0x4a23f3['directionRandomizer'];},_0x2a8cb8;}()),_0x48f6b1=(function(){function _0x5860ad(){this['direction1']=new _0x74d525['e'](0x0,0x1,0x0),this['direction2']=new _0x74d525['e'](0x0,0x1,0x0);}return _0x5860ad['prototype']['startDirectionFunction']=function(_0x3060e5,_0x97a106,_0x48c77d,_0x2d85ab){var _0x296fe3=_0x4a0cf0['a']['RandomRange'](this['direction1']['x'],this['direction2']['x']),_0x240792=_0x4a0cf0['a']['RandomRange'](this['direction1']['y'],this['direction2']['y']),_0x50e5f0=_0x4a0cf0['a']['RandomRange'](this['direction1']['z'],this['direction2']['z']);_0x2d85ab?_0x97a106['copyFromFloats'](_0x296fe3,_0x240792,_0x50e5f0):_0x74d525['e']['TransformNormalFromFloatsToRef'](_0x296fe3,_0x240792,_0x50e5f0,_0x3060e5,_0x97a106);},_0x5860ad['prototype']['startPositionFunction']=function(_0x18da40,_0x1a5cb3,_0x5df62c,_0x41e0c3){_0x41e0c3?_0x1a5cb3['copyFromFloats'](0x0,0x0,0x0):_0x74d525['e']['TransformCoordinatesFromFloatsToRef'](0x0,0x0,0x0,_0x18da40,_0x1a5cb3);},_0x5860ad['prototype']['clone']=function(){var _0x4cd9a0=new _0x5860ad();return _0x5d9c83['a']['DeepCopy'](this,_0x4cd9a0),_0x4cd9a0;},_0x5860ad['prototype']['applyToShader']=function(_0x200282){_0x200282['setVector3']('direction1',this['direction1']),_0x200282['setVector3']('direction2',this['direction2']);},_0x5860ad['prototype']['getEffectDefines']=function(){return'#define\x20POINTEMITTER';},_0x5860ad['prototype']['getClassName']=function(){return'PointParticleEmitter';},_0x5860ad['prototype']['serialize']=function(){var _0x48906c={};return _0x48906c['type']=this['getClassName'](),_0x48906c['direction1']=this['direction1']['asArray'](),_0x48906c['direction2']=this['direction2']['asArray'](),_0x48906c;},_0x5860ad['prototype']['parse']=function(_0x375b0a){_0x74d525['e']['FromArrayToRef'](_0x375b0a['direction1'],0x0,this['direction1']),_0x74d525['e']['FromArrayToRef'](_0x375b0a['direction2'],0x0,this['direction2']);},_0x5860ad;}()),_0x338038=(function(){function _0x255a10(_0x12d53d,_0x56c078,_0x3bb91d){void 0x0===_0x12d53d&&(_0x12d53d=0x1),void 0x0===_0x56c078&&(_0x56c078=0x1),void 0x0===_0x3bb91d&&(_0x3bb91d=0x0),this['radius']=_0x12d53d,this['radiusRange']=_0x56c078,this['directionRandomizer']=_0x3bb91d;}return _0x255a10['prototype']['startDirectionFunction']=function(_0xdf7173,_0x24bf1a,_0x34291f,_0x3b9db6){var _0x24275b=_0x34291f['position']['subtract'](_0xdf7173['getTranslation']())['normalize'](),_0x4a0c91=_0x4a0cf0['a']['RandomRange'](0x0,this['directionRandomizer']),_0x3fdfb6=_0x4a0cf0['a']['RandomRange'](0x0,this['directionRandomizer']),_0x4dd7ec=_0x4a0cf0['a']['RandomRange'](0x0,this['directionRandomizer']);_0x24275b['x']+=_0x4a0c91,_0x24275b['y']+=_0x3fdfb6,_0x24275b['z']+=_0x4dd7ec,_0x24275b['normalize'](),_0x3b9db6?_0x24bf1a['copyFrom'](_0x24275b):_0x74d525['e']['TransformNormalFromFloatsToRef'](_0x24275b['x'],_0x24275b['y'],_0x24275b['z'],_0xdf7173,_0x24bf1a);},_0x255a10['prototype']['startPositionFunction']=function(_0x25fb41,_0x115dd5,_0x304a90,_0x309a38){var _0xf154ea=this['radius']-_0x4a0cf0['a']['RandomRange'](0x0,this['radius']*this['radiusRange']),_0x4adcbd=_0x4a0cf0['a']['RandomRange'](0x0,0x1),_0x22362e=_0x4a0cf0['a']['RandomRange'](0x0,0x2*Math['PI']),_0x5de1d6=Math['acos'](0x2*_0x4adcbd-0x1),_0x2b2a0b=_0xf154ea*Math['cos'](_0x22362e)*Math['sin'](_0x5de1d6),_0x5c1dcd=_0xf154ea*Math['cos'](_0x5de1d6),_0xfa1122=_0xf154ea*Math['sin'](_0x22362e)*Math['sin'](_0x5de1d6);_0x309a38?_0x115dd5['copyFromFloats'](_0x2b2a0b,_0x5c1dcd,_0xfa1122):_0x74d525['e']['TransformCoordinatesFromFloatsToRef'](_0x2b2a0b,_0x5c1dcd,_0xfa1122,_0x25fb41,_0x115dd5);},_0x255a10['prototype']['clone']=function(){var _0x450352=new _0x255a10(this['radius'],this['directionRandomizer']);return _0x5d9c83['a']['DeepCopy'](this,_0x450352),_0x450352;},_0x255a10['prototype']['applyToShader']=function(_0x1dc731){_0x1dc731['setFloat']('radius',this['radius']),_0x1dc731['setFloat']('radiusRange',this['radiusRange']),_0x1dc731['setFloat']('directionRandomizer',this['directionRandomizer']);},_0x255a10['prototype']['getEffectDefines']=function(){return'#define\x20SPHEREEMITTER';},_0x255a10['prototype']['getClassName']=function(){return'SphereParticleEmitter';},_0x255a10['prototype']['serialize']=function(){var _0x4d2928={};return _0x4d2928['type']=this['getClassName'](),_0x4d2928['radius']=this['radius'],_0x4d2928['radiusRange']=this['radiusRange'],_0x4d2928['directionRandomizer']=this['directionRandomizer'],_0x4d2928;},_0x255a10['prototype']['parse']=function(_0x573783){this['radius']=_0x573783['radius'],this['radiusRange']=_0x573783['radiusRange'],this['directionRandomizer']=_0x573783['directionRandomizer'];},_0x255a10;}()),_0x111265=function(_0x8d2855){function _0x4d1fc8(_0x3c6646,_0x2b5796,_0x232515){void 0x0===_0x3c6646&&(_0x3c6646=0x1),void 0x0===_0x2b5796&&(_0x2b5796=new _0x74d525['e'](0x0,0x1,0x0)),void 0x0===_0x232515&&(_0x232515=new _0x74d525['e'](0x0,0x1,0x0));var _0x1749fd=_0x8d2855['call'](this,_0x3c6646)||this;return _0x1749fd['direction1']=_0x2b5796,_0x1749fd['direction2']=_0x232515,_0x1749fd;}return Object(_0x18e13d['d'])(_0x4d1fc8,_0x8d2855),_0x4d1fc8['prototype']['startDirectionFunction']=function(_0x3bfb3e,_0x35f7d6,_0x4bcbaf){var _0x77ac45=_0x4a0cf0['a']['RandomRange'](this['direction1']['x'],this['direction2']['x']),_0x327c04=_0x4a0cf0['a']['RandomRange'](this['direction1']['y'],this['direction2']['y']),_0x294268=_0x4a0cf0['a']['RandomRange'](this['direction1']['z'],this['direction2']['z']);_0x74d525['e']['TransformNormalFromFloatsToRef'](_0x77ac45,_0x327c04,_0x294268,_0x3bfb3e,_0x35f7d6);},_0x4d1fc8['prototype']['clone']=function(){var _0x34d238=new _0x4d1fc8(this['radius'],this['direction1'],this['direction2']);return _0x5d9c83['a']['DeepCopy'](this,_0x34d238),_0x34d238;},_0x4d1fc8['prototype']['applyToShader']=function(_0x563d09){_0x563d09['setFloat']('radius',this['radius']),_0x563d09['setFloat']('radiusRange',this['radiusRange']),_0x563d09['setVector3']('direction1',this['direction1']),_0x563d09['setVector3']('direction2',this['direction2']);},_0x4d1fc8['prototype']['getEffectDefines']=function(){return'#define\x20SPHEREEMITTER\x0a#define\x20DIRECTEDSPHEREEMITTER';},_0x4d1fc8['prototype']['getClassName']=function(){return'SphereDirectedParticleEmitter';},_0x4d1fc8['prototype']['serialize']=function(){var _0x4bd25e=_0x8d2855['prototype']['serialize']['call'](this);return _0x4bd25e['direction1']=this['direction1']['asArray'](),_0x4bd25e['direction2']=this['direction2']['asArray'](),_0x4bd25e;},_0x4d1fc8['prototype']['parse']=function(_0x3b48c5){_0x8d2855['prototype']['parse']['call'](this,_0x3b48c5),this['direction1']['copyFrom'](_0x3b48c5['direction1']),this['direction2']['copyFrom'](_0x3b48c5['direction2']);},_0x4d1fc8;}(_0x338038),_0x10a54c=(function(){function _0x28b118(){this['particlePositionGenerator']=function(){},this['particleDestinationGenerator']=function(){};}return _0x28b118['prototype']['startDirectionFunction']=function(_0x432171,_0x32c848,_0x44cbb1,_0x4c7914){var _0x20d8f4=_0x74d525['c']['Vector3'][0x0];if(this['particleDestinationGenerator']){this['particleDestinationGenerator'](-0x1,_0x44cbb1,_0x20d8f4);var _0x5ea188=_0x74d525['c']['Vector3'][0x1];_0x20d8f4['subtractToRef'](_0x44cbb1['position'],_0x5ea188),_0x5ea188['scaleToRef'](0x1/_0x44cbb1['lifeTime'],_0x20d8f4);}else _0x20d8f4['set'](0x0,0x0,0x0);_0x4c7914?_0x32c848['copyFrom'](_0x20d8f4):_0x74d525['e']['TransformNormalToRef'](_0x20d8f4,_0x432171,_0x32c848);},_0x28b118['prototype']['startPositionFunction']=function(_0x473e83,_0x4fabd0,_0x426f3f,_0x456573){var _0x3f957e=_0x74d525['c']['Vector3'][0x0];this['particlePositionGenerator']?this['particlePositionGenerator'](-0x1,_0x426f3f,_0x3f957e):_0x3f957e['set'](0x0,0x0,0x0),_0x456573?_0x4fabd0['copyFrom'](_0x3f957e):_0x74d525['e']['TransformCoordinatesToRef'](_0x3f957e,_0x473e83,_0x4fabd0);},_0x28b118['prototype']['clone']=function(){var _0x22a710=new _0x28b118();return _0x5d9c83['a']['DeepCopy'](this,_0x22a710),_0x22a710;},_0x28b118['prototype']['applyToShader']=function(_0x5d4f84){},_0x28b118['prototype']['getEffectDefines']=function(){return'#define\x20CUSTOMEMITTER';},_0x28b118['prototype']['getClassName']=function(){return'CustomParticleEmitter';},_0x28b118['prototype']['serialize']=function(){var _0x3c1152={};return _0x3c1152['type']=this['getClassName'](),_0x3c1152;},_0x28b118['prototype']['parse']=function(_0x2d3c1b){},_0x28b118;}()),_0x219b07=(function(){function _0x2f8737(_0x55472f){void 0x0===_0x55472f&&(_0x55472f=null),this['_indices']=null,this['_positions']=null,this['_normals']=null,this['_storedNormal']=_0x74d525['e']['Zero'](),this['_mesh']=null,this['direction1']=new _0x74d525['e'](0x0,0x1,0x0),this['direction2']=new _0x74d525['e'](0x0,0x1,0x0),this['useMeshNormalsForDirection']=!0x0,this['mesh']=_0x55472f;}return Object['defineProperty'](_0x2f8737['prototype'],'mesh',{'get':function(){return this['_mesh'];},'set':function(_0x55174f){this['_mesh']!==_0x55174f&&(this['_mesh']=_0x55174f,_0x55174f?(this['_indices']=_0x55174f['getIndices'](),this['_positions']=_0x55174f['getVerticesData'](_0x212fbd['b']['PositionKind']),this['_normals']=_0x55174f['getVerticesData'](_0x212fbd['b']['NormalKind'])):(this['_indices']=null,this['_positions']=null,this['_normals']=null));},'enumerable':!0x1,'configurable':!0x0}),_0x2f8737['prototype']['startDirectionFunction']=function(_0x18db1c,_0x598340,_0x2baa35,_0x328643){if(this['useMeshNormalsForDirection']&&this['_normals'])_0x74d525['e']['TransformNormalToRef'](this['_storedNormal'],_0x18db1c,_0x598340);else{var _0xceaeaa=_0x4a0cf0['a']['RandomRange'](this['direction1']['x'],this['direction2']['x']),_0x405555=_0x4a0cf0['a']['RandomRange'](this['direction1']['y'],this['direction2']['y']),_0x394436=_0x4a0cf0['a']['RandomRange'](this['direction1']['z'],this['direction2']['z']);_0x328643?_0x598340['copyFromFloats'](_0xceaeaa,_0x405555,_0x394436):_0x74d525['e']['TransformNormalFromFloatsToRef'](_0xceaeaa,_0x405555,_0x394436,_0x18db1c,_0x598340);}},_0x2f8737['prototype']['startPositionFunction']=function(_0x1b77cf,_0x547566,_0x51037c,_0x3c2d59){if(this['_indices']&&this['_positions']){var _0x3c002b=0x3*Math['random']()*(this['_indices']['length']/0x3)|0x0,_0x375e7e=Math['random'](),_0x78c388=Math['random']()*(0x1-_0x375e7e),_0x1fe86c=0x1-_0x375e7e-_0x78c388,_0xfb056e=this['_indices'][_0x3c002b],_0x538291=this['_indices'][_0x3c002b+0x1],_0x2fac0b=this['_indices'][_0x3c002b+0x2],_0x145a46=_0x74d525['c']['Vector3'][0x0],_0x5f1515=_0x74d525['c']['Vector3'][0x1],_0x77d375=_0x74d525['c']['Vector3'][0x2],_0x6df895=_0x74d525['c']['Vector3'][0x3];_0x74d525['e']['FromArrayToRef'](this['_positions'],0x3*_0xfb056e,_0x145a46),_0x74d525['e']['FromArrayToRef'](this['_positions'],0x3*_0x538291,_0x5f1515),_0x74d525['e']['FromArrayToRef'](this['_positions'],0x3*_0x2fac0b,_0x77d375),_0x6df895['x']=_0x375e7e*_0x145a46['x']+_0x78c388*_0x5f1515['x']+_0x1fe86c*_0x77d375['x'],_0x6df895['y']=_0x375e7e*_0x145a46['y']+_0x78c388*_0x5f1515['y']+_0x1fe86c*_0x77d375['y'],_0x6df895['z']=_0x375e7e*_0x145a46['z']+_0x78c388*_0x5f1515['z']+_0x1fe86c*_0x77d375['z'],_0x3c2d59?_0x547566['copyFromFloats'](_0x6df895['x'],_0x6df895['y'],_0x6df895['z']):_0x74d525['e']['TransformCoordinatesFromFloatsToRef'](_0x6df895['x'],_0x6df895['y'],_0x6df895['z'],_0x1b77cf,_0x547566),this['useMeshNormalsForDirection']&&this['_normals']&&(_0x74d525['e']['FromArrayToRef'](this['_normals'],0x3*_0xfb056e,_0x145a46),_0x74d525['e']['FromArrayToRef'](this['_normals'],0x3*_0x538291,_0x5f1515),_0x74d525['e']['FromArrayToRef'](this['_normals'],0x3*_0x2fac0b,_0x77d375),this['_storedNormal']['x']=_0x375e7e*_0x145a46['x']+_0x78c388*_0x5f1515['x']+_0x1fe86c*_0x77d375['x'],this['_storedNormal']['y']=_0x375e7e*_0x145a46['y']+_0x78c388*_0x5f1515['y']+_0x1fe86c*_0x77d375['y'],this['_storedNormal']['z']=_0x375e7e*_0x145a46['z']+_0x78c388*_0x5f1515['z']+_0x1fe86c*_0x77d375['z']);}},_0x2f8737['prototype']['clone']=function(){var _0x364414=new _0x2f8737(this['mesh']);return _0x5d9c83['a']['DeepCopy'](this,_0x364414),_0x364414;},_0x2f8737['prototype']['applyToShader']=function(_0x4e68e0){_0x4e68e0['setVector3']('direction1',this['direction1']),_0x4e68e0['setVector3']('direction2',this['direction2']);},_0x2f8737['prototype']['getEffectDefines']=function(){return'';},_0x2f8737['prototype']['getClassName']=function(){return'MeshParticleEmitter';},_0x2f8737['prototype']['serialize']=function(){var _0x47a29c,_0x293028={};return _0x293028['type']=this['getClassName'](),_0x293028['direction1']=this['direction1']['asArray'](),_0x293028['direction2']=this['direction2']['asArray'](),_0x293028['meshId']=null===(_0x47a29c=this['mesh'])||void 0x0===_0x47a29c?void 0x0:_0x47a29c['id'],_0x293028['useMeshNormalsForDirection']=this['useMeshNormalsForDirection'],_0x293028;},_0x2f8737['prototype']['parse']=function(_0xb265d9,_0x101df6){_0x74d525['e']['FromArrayToRef'](_0xb265d9['direction1'],0x0,this['direction1']),_0x74d525['e']['FromArrayToRef'](_0xb265d9['direction2'],0x0,this['direction2']),_0xb265d9['meshId']&&_0x101df6&&(this['mesh']=_0x101df6['getLastMeshByID'](_0xb265d9['meshId'])),this['useMeshNormalsForDirection']=_0xb265d9['useMeshNormalsForDirection'];},_0x2f8737;}()),_0x2e1395=(function(){function _0x5173a8(_0x570895){this['animations']=[],this['renderingGroupId']=0x0,this['emitter']=_0x74d525['e']['Zero'](),this['emitRate']=0xa,this['manualEmitCount']=-0x1,this['updateSpeed']=0.01,this['targetStopDuration']=0x0,this['disposeOnStop']=!0x1,this['minEmitPower']=0x1,this['maxEmitPower']=0x1,this['minLifeTime']=0x1,this['maxLifeTime']=0x1,this['minSize']=0x1,this['maxSize']=0x1,this['minScaleX']=0x1,this['maxScaleX']=0x1,this['minScaleY']=0x1,this['maxScaleY']=0x1,this['minInitialRotation']=0x0,this['maxInitialRotation']=0x0,this['minAngularSpeed']=0x0,this['maxAngularSpeed']=0x0,this['layerMask']=0xfffffff,this['customShader']=null,this['preventAutoStart']=!0x1,this['noiseStrength']=new _0x74d525['e'](0xa,0xa,0xa),this['onAnimationEnd']=null,this['blendMode']=_0x5173a8['BLENDMODE_ONEONE'],this['forceDepthWrite']=!0x1,this['preWarmCycles']=0x0,this['preWarmStepOffset']=0x1,this['spriteCellChangeSpeed']=0x1,this['startSpriteCellID']=0x0,this['endSpriteCellID']=0x0,this['spriteCellWidth']=0x0,this['spriteCellHeight']=0x0,this['spriteRandomStartCell']=!0x1,this['translationPivot']=new _0x74d525['d'](0x0,0x0),this['beginAnimationOnStart']=!0x1,this['beginAnimationFrom']=0x0,this['beginAnimationTo']=0x3c,this['beginAnimationLoop']=!0x1,this['worldOffset']=new _0x74d525['e'](0x0,0x0,0x0),this['gravity']=_0x74d525['e']['Zero'](),this['_colorGradients']=null,this['_sizeGradients']=null,this['_lifeTimeGradients']=null,this['_angularSpeedGradients']=null,this['_velocityGradients']=null,this['_limitVelocityGradients']=null,this['_dragGradients']=null,this['_emitRateGradients']=null,this['_startSizeGradients']=null,this['_rampGradients']=null,this['_colorRemapGradients']=null,this['_alphaRemapGradients']=null,this['startDelay']=0x0,this['limitVelocityDamping']=0.4,this['color1']=new _0x39310d['b'](0x1,0x1,0x1,0x1),this['color2']=new _0x39310d['b'](0x1,0x1,0x1,0x1),this['colorDead']=new _0x39310d['b'](0x0,0x0,0x0,0x1),this['textureMask']=new _0x39310d['b'](0x1,0x1,0x1,0x1),this['_isSubEmitter']=!0x1,this['billboardMode']=_0x2103ba['a']['PARTICLES_BILLBOARDMODE_ALL'],this['_isBillboardBased']=!0x0,this['_imageProcessingConfigurationDefines']=new _0x3f08d6['b'](),this['id']=_0x570895,this['name']=_0x570895;}return Object['defineProperty'](_0x5173a8['prototype'],'noiseTexture',{'get':function(){return this['_noiseTexture'];},'set':function(_0x17c34b){this['_noiseTexture']!==_0x17c34b&&(this['_noiseTexture']=_0x17c34b,this['_reset']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5173a8['prototype'],'isAnimationSheetEnabled',{'get':function(){return this['_isAnimationSheetEnabled'];},'set':function(_0xc077e9){this['_isAnimationSheetEnabled']!=_0xc077e9&&(this['_isAnimationSheetEnabled']=_0xc077e9,this['_reset']());},'enumerable':!0x1,'configurable':!0x0}),_0x5173a8['prototype']['getScene']=function(){return this['_scene'];},_0x5173a8['prototype']['_hasTargetStopDurationDependantGradient']=function(){return this['_startSizeGradients']&&this['_startSizeGradients']['length']>0x0||this['_emitRateGradients']&&this['_emitRateGradients']['length']>0x0||this['_lifeTimeGradients']&&this['_lifeTimeGradients']['length']>0x0;},_0x5173a8['prototype']['getDragGradients']=function(){return this['_dragGradients'];},_0x5173a8['prototype']['getLimitVelocityGradients']=function(){return this['_limitVelocityGradients'];},_0x5173a8['prototype']['getColorGradients']=function(){return this['_colorGradients'];},_0x5173a8['prototype']['getSizeGradients']=function(){return this['_sizeGradients'];},_0x5173a8['prototype']['getColorRemapGradients']=function(){return this['_colorRemapGradients'];},_0x5173a8['prototype']['getAlphaRemapGradients']=function(){return this['_alphaRemapGradients'];},_0x5173a8['prototype']['getLifeTimeGradients']=function(){return this['_lifeTimeGradients'];},_0x5173a8['prototype']['getAngularSpeedGradients']=function(){return this['_angularSpeedGradients'];},_0x5173a8['prototype']['getVelocityGradients']=function(){return this['_velocityGradients'];},_0x5173a8['prototype']['getStartSizeGradients']=function(){return this['_startSizeGradients'];},_0x5173a8['prototype']['getEmitRateGradients']=function(){return this['_emitRateGradients'];},Object['defineProperty'](_0x5173a8['prototype'],'direction1',{'get':function(){return this['particleEmitterType']['direction1']?this['particleEmitterType']['direction1']:_0x74d525['e']['Zero']();},'set':function(_0x1ccd5d){this['particleEmitterType']['direction1']&&(this['particleEmitterType']['direction1']=_0x1ccd5d);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5173a8['prototype'],'direction2',{'get':function(){return this['particleEmitterType']['direction2']?this['particleEmitterType']['direction2']:_0x74d525['e']['Zero']();},'set':function(_0x46df14){this['particleEmitterType']['direction2']&&(this['particleEmitterType']['direction2']=_0x46df14);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5173a8['prototype'],'minEmitBox',{'get':function(){return this['particleEmitterType']['minEmitBox']?this['particleEmitterType']['minEmitBox']:_0x74d525['e']['Zero']();},'set':function(_0x158b0c){this['particleEmitterType']['minEmitBox']&&(this['particleEmitterType']['minEmitBox']=_0x158b0c);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5173a8['prototype'],'maxEmitBox',{'get':function(){return this['particleEmitterType']['maxEmitBox']?this['particleEmitterType']['maxEmitBox']:_0x74d525['e']['Zero']();},'set':function(_0x569440){this['particleEmitterType']['maxEmitBox']&&(this['particleEmitterType']['maxEmitBox']=_0x569440);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5173a8['prototype'],'isBillboardBased',{'get':function(){return this['_isBillboardBased'];},'set':function(_0x3faaa1){this['_isBillboardBased']!==_0x3faaa1&&(this['_isBillboardBased']=_0x3faaa1,this['_reset']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5173a8['prototype'],'imageProcessingConfiguration',{'get':function(){return this['_imageProcessingConfiguration'];},'set':function(_0x30fb61){this['_attachImageProcessingConfiguration'](_0x30fb61);},'enumerable':!0x1,'configurable':!0x0}),_0x5173a8['prototype']['_attachImageProcessingConfiguration']=function(_0x29b110){_0x29b110!==this['_imageProcessingConfiguration']&&(!_0x29b110&&this['_scene']?this['_imageProcessingConfiguration']=this['_scene']['imageProcessingConfiguration']:this['_imageProcessingConfiguration']=_0x29b110);},_0x5173a8['prototype']['_reset']=function(){},_0x5173a8['prototype']['_removeGradientAndTexture']=function(_0x57800e,_0x4e5f7a,_0x5d9d08){if(!_0x4e5f7a)return this;for(var _0x1a9643=0x0,_0x378d72=0x0,_0x3c4322=_0x4e5f7a;_0x378d72<_0x3c4322['length'];_0x378d72++){if(_0x3c4322[_0x378d72]['gradient']===_0x57800e){_0x4e5f7a['splice'](_0x1a9643,0x1);break;}_0x1a9643++;}return _0x5d9d08&&_0x5d9d08['dispose'](),this;},_0x5173a8['prototype']['createPointEmitter']=function(_0x358e0b,_0x4c2120){var _0x301f63=new _0x48f6b1();return _0x301f63['direction1']=_0x358e0b,_0x301f63['direction2']=_0x4c2120,this['particleEmitterType']=_0x301f63,_0x301f63;},_0x5173a8['prototype']['createHemisphericEmitter']=function(_0x517e22,_0xd91126){void 0x0===_0x517e22&&(_0x517e22=0x1),void 0x0===_0xd91126&&(_0xd91126=0x1);var _0x9f2ab5=new _0x18cf99(_0x517e22,_0xd91126);return this['particleEmitterType']=_0x9f2ab5,_0x9f2ab5;},_0x5173a8['prototype']['createSphereEmitter']=function(_0x462458,_0x46d0a5){void 0x0===_0x462458&&(_0x462458=0x1),void 0x0===_0x46d0a5&&(_0x46d0a5=0x1);var _0x141295=new _0x338038(_0x462458,_0x46d0a5);return this['particleEmitterType']=_0x141295,_0x141295;},_0x5173a8['prototype']['createDirectedSphereEmitter']=function(_0x1f4983,_0x5d7419,_0x547233){void 0x0===_0x1f4983&&(_0x1f4983=0x1),void 0x0===_0x5d7419&&(_0x5d7419=new _0x74d525['e'](0x0,0x1,0x0)),void 0x0===_0x547233&&(_0x547233=new _0x74d525['e'](0x0,0x1,0x0));var _0x51494d=new _0x111265(_0x1f4983,_0x5d7419,_0x547233);return this['particleEmitterType']=_0x51494d,_0x51494d;},_0x5173a8['prototype']['createCylinderEmitter']=function(_0x1b94e2,_0x225c77,_0x3405f2,_0x4b3416){void 0x0===_0x1b94e2&&(_0x1b94e2=0x1),void 0x0===_0x225c77&&(_0x225c77=0x1),void 0x0===_0x3405f2&&(_0x3405f2=0x1),void 0x0===_0x4b3416&&(_0x4b3416=0x0);var _0x25dffb=new _0x4c9a66(_0x1b94e2,_0x225c77,_0x3405f2,_0x4b3416);return this['particleEmitterType']=_0x25dffb,_0x25dffb;},_0x5173a8['prototype']['createDirectedCylinderEmitter']=function(_0x421d3c,_0x1403c0,_0x557657,_0xcb9934,_0x3396ae){void 0x0===_0x421d3c&&(_0x421d3c=0x1),void 0x0===_0x1403c0&&(_0x1403c0=0x1),void 0x0===_0x557657&&(_0x557657=0x1),void 0x0===_0xcb9934&&(_0xcb9934=new _0x74d525['e'](0x0,0x1,0x0)),void 0x0===_0x3396ae&&(_0x3396ae=new _0x74d525['e'](0x0,0x1,0x0));var _0xbbfa1f=new _0x1b1b95(_0x421d3c,_0x1403c0,_0x557657,_0xcb9934,_0x3396ae);return this['particleEmitterType']=_0xbbfa1f,_0xbbfa1f;},_0x5173a8['prototype']['createConeEmitter']=function(_0x26c47a,_0x3b6fd1){void 0x0===_0x26c47a&&(_0x26c47a=0x1),void 0x0===_0x3b6fd1&&(_0x3b6fd1=Math['PI']/0x4);var _0x1b4e83=new _0x2cb2ef(_0x26c47a,_0x3b6fd1);return this['particleEmitterType']=_0x1b4e83,_0x1b4e83;},_0x5173a8['prototype']['createBoxEmitter']=function(_0x4104ee,_0x12f1d4,_0x26bba3,_0x5053db){var _0x32fb81=new _0x3faf18();return this['particleEmitterType']=_0x32fb81,this['direction1']=_0x4104ee,this['direction2']=_0x12f1d4,this['minEmitBox']=_0x26bba3,this['maxEmitBox']=_0x5053db,_0x32fb81;},_0x5173a8['BLENDMODE_ONEONE']=0x0,_0x5173a8['BLENDMODE_STANDARD']=0x1,_0x5173a8['BLENDMODE_ADD']=0x2,_0x5173a8['BLENDMODE_MULTIPLY']=0x3,_0x5173a8['BLENDMODE_MULTIPLYADD']=0x4,_0x5173a8;}()),_0x48f9fa=function(_0x1ff720){function _0x131edf(_0x530015){var _0x210c3f=_0x1ff720['call'](this,_0x530015,_0x4e54a1['Neutral'])||this;return _0x210c3f['registerInput']('rgba',_0x3bb339['Color4'],!0x0),_0x210c3f['registerInput']('rgb\x20',_0x3bb339['Color3'],!0x0),_0x210c3f['registerOutput']('rgb',_0x3bb339['Color3']),_0x210c3f['registerOutput']('r',_0x3bb339['Float']),_0x210c3f['registerOutput']('g',_0x3bb339['Float']),_0x210c3f['registerOutput']('b',_0x3bb339['Float']),_0x210c3f['registerOutput']('a',_0x3bb339['Float']),_0x210c3f['inputsAreExclusive']=!0x0,_0x210c3f;}return Object(_0x18e13d['d'])(_0x131edf,_0x1ff720),_0x131edf['prototype']['getClassName']=function(){return'ColorSplitterBlock';},Object['defineProperty'](_0x131edf['prototype'],'rgba',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x131edf['prototype'],'rgbIn',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x131edf['prototype'],'rgbOut',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x131edf['prototype'],'r',{'get':function(){return this['_outputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x131edf['prototype'],'g',{'get':function(){return this['_outputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x131edf['prototype'],'b',{'get':function(){return this['_outputs'][0x3];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x131edf['prototype'],'a',{'get':function(){return this['_outputs'][0x4];},'enumerable':!0x1,'configurable':!0x0}),_0x131edf['prototype']['_inputRename']=function(_0x866b9f){return'rgb\x20'===_0x866b9f?'rgbIn':_0x866b9f;},_0x131edf['prototype']['_outputRename']=function(_0x45eb6d){return'rgb'===_0x45eb6d?'rgbOut':_0x45eb6d;},_0x131edf['prototype']['_buildBlock']=function(_0x1692c8){_0x1ff720['prototype']['_buildBlock']['call'](this,_0x1692c8);var _0xf080e0=this['rgba']['isConnected']?this['rgba']:this['rgbIn'];if(_0xf080e0['isConnected']){var _0x1d60a6=this['_outputs'][0x0],_0x1684fd=this['_outputs'][0x1],_0x5b0ee0=this['_outputs'][0x2],_0x2c5158=this['_outputs'][0x3],_0x2a68dd=this['_outputs'][0x4];return _0x1d60a6['hasEndpoints']&&(_0x1692c8['compilationString']+=this['_declareOutput'](_0x1d60a6,_0x1692c8)+'\x20=\x20'+_0xf080e0['associatedVariableName']+'.rgb;\x0d\x0a'),_0x1684fd['hasEndpoints']&&(_0x1692c8['compilationString']+=this['_declareOutput'](_0x1684fd,_0x1692c8)+'\x20=\x20'+_0xf080e0['associatedVariableName']+'.r;\x0d\x0a'),_0x5b0ee0['hasEndpoints']&&(_0x1692c8['compilationString']+=this['_declareOutput'](_0x5b0ee0,_0x1692c8)+'\x20=\x20'+_0xf080e0['associatedVariableName']+'.g;\x0d\x0a'),_0x2c5158['hasEndpoints']&&(_0x1692c8['compilationString']+=this['_declareOutput'](_0x2c5158,_0x1692c8)+'\x20=\x20'+_0xf080e0['associatedVariableName']+'.b;\x0d\x0a'),_0x2a68dd['hasEndpoints']&&(_0x1692c8['compilationString']+=this['_declareOutput'](_0x2a68dd,_0x1692c8)+'\x20=\x20'+_0xf080e0['associatedVariableName']+'.a;\x0d\x0a'),this;}},_0x131edf;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.ColorSplitterBlock']=_0x48f9fa;var _0x4872c7,_0x3ecaa7=_0x162675(0x68);!function(_0x1b6758){_0x1b6758[_0x1b6758['Cos']=0x0]='Cos',_0x1b6758[_0x1b6758['Sin']=0x1]='Sin',_0x1b6758[_0x1b6758['Abs']=0x2]='Abs',_0x1b6758[_0x1b6758['Exp']=0x3]='Exp',_0x1b6758[_0x1b6758['Exp2']=0x4]='Exp2',_0x1b6758[_0x1b6758['Round']=0x5]='Round',_0x1b6758[_0x1b6758['Floor']=0x6]='Floor',_0x1b6758[_0x1b6758['Ceiling']=0x7]='Ceiling',_0x1b6758[_0x1b6758['Sqrt']=0x8]='Sqrt',_0x1b6758[_0x1b6758['Log']=0x9]='Log',_0x1b6758[_0x1b6758['Tan']=0xa]='Tan',_0x1b6758[_0x1b6758['ArcTan']=0xb]='ArcTan',_0x1b6758[_0x1b6758['ArcCos']=0xc]='ArcCos',_0x1b6758[_0x1b6758['ArcSin']=0xd]='ArcSin',_0x1b6758[_0x1b6758['Fract']=0xe]='Fract',_0x1b6758[_0x1b6758['Sign']=0xf]='Sign',_0x1b6758[_0x1b6758['Radians']=0x10]='Radians',_0x1b6758[_0x1b6758['Degrees']=0x11]='Degrees';}(_0x4872c7||(_0x4872c7={}));var _0xfe96fa=function(_0x4d78e4){function _0x263ae1(_0x29b2bb){var _0x187428=_0x4d78e4['call'](this,_0x29b2bb,_0x4e54a1['Neutral'])||this;return _0x187428['operation']=_0x4872c7['Cos'],_0x187428['registerInput']('input',_0x3bb339['AutoDetect']),_0x187428['registerOutput']('output',_0x3bb339['BasedOnInput']),_0x187428['_outputs'][0x0]['_typeConnectionSource']=_0x187428['_inputs'][0x0],_0x187428;}return Object(_0x18e13d['d'])(_0x263ae1,_0x4d78e4),_0x263ae1['prototype']['getClassName']=function(){return'TrigonometryBlock';},Object['defineProperty'](_0x263ae1['prototype'],'input',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x263ae1['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x263ae1['prototype']['_buildBlock']=function(_0x2b65ce){_0x4d78e4['prototype']['_buildBlock']['call'](this,_0x2b65ce);var _0x55a7ab=this['_outputs'][0x0],_0x5db187='';switch(this['operation']){case _0x4872c7['Cos']:_0x5db187='cos';break;case _0x4872c7['Sin']:_0x5db187='sin';break;case _0x4872c7['Abs']:_0x5db187='abs';break;case _0x4872c7['Exp']:_0x5db187='exp';break;case _0x4872c7['Exp2']:_0x5db187='exp2';break;case _0x4872c7['Round']:_0x5db187='round';break;case _0x4872c7['Floor']:_0x5db187='floor';break;case _0x4872c7['Ceiling']:_0x5db187='ceil';break;case _0x4872c7['Sqrt']:_0x5db187='sqrt';break;case _0x4872c7['Log']:_0x5db187='log';break;case _0x4872c7['Tan']:_0x5db187='tan';break;case _0x4872c7['ArcTan']:_0x5db187='atan';break;case _0x4872c7['ArcCos']:_0x5db187='acos';break;case _0x4872c7['ArcSin']:_0x5db187='asin';break;case _0x4872c7['Fract']:_0x5db187='fract';break;case _0x4872c7['Sign']:_0x5db187='sign';break;case _0x4872c7['Radians']:_0x5db187='radians';break;case _0x4872c7['Degrees']:_0x5db187='degrees';}return _0x2b65ce['compilationString']+=this['_declareOutput'](_0x55a7ab,_0x2b65ce)+'\x20=\x20'+_0x5db187+'('+this['input']['associatedVariableName']+');\x0d\x0a',this;},_0x263ae1['prototype']['serialize']=function(){var _0x2ecf0d=_0x4d78e4['prototype']['serialize']['call'](this);return _0x2ecf0d['operation']=this['operation'],_0x2ecf0d;},_0x263ae1['prototype']['_deserialize']=function(_0x2dc33a,_0x314ecd,_0x402a6a){_0x4d78e4['prototype']['_deserialize']['call'](this,_0x2dc33a,_0x314ecd,_0x402a6a),this['operation']=_0x2dc33a['operation'];},_0x263ae1['prototype']['_dumpPropertiesCode']=function(){return this['_codeVariableName']+'.operation\x20=\x20BABYLON.TrigonometryBlockOperations.'+_0x4872c7[this['operation']]+';\x0d\x0a';},_0x263ae1;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.TrigonometryBlock']=_0xfe96fa;var _0x3edf52={'effect':null,'subMesh':null},_0x412d6e=function(_0x4a0f8c){function _0x1201ea(){var _0x4f928f=_0x4a0f8c['call'](this)||this;return _0x4f928f['NORMAL']=!0x1,_0x4f928f['TANGENT']=!0x1,_0x4f928f['UV1']=!0x1,_0x4f928f['NUM_BONE_INFLUENCERS']=0x0,_0x4f928f['BonesPerMesh']=0x0,_0x4f928f['BONETEXTURE']=!0x1,_0x4f928f['MORPHTARGETS']=!0x1,_0x4f928f['MORPHTARGETS_NORMAL']=!0x1,_0x4f928f['MORPHTARGETS_TANGENT']=!0x1,_0x4f928f['MORPHTARGETS_UV']=!0x1,_0x4f928f['NUM_MORPH_INFLUENCERS']=0x0,_0x4f928f['IMAGEPROCESSING']=!0x1,_0x4f928f['VIGNETTE']=!0x1,_0x4f928f['VIGNETTEBLENDMODEMULTIPLY']=!0x1,_0x4f928f['VIGNETTEBLENDMODEOPAQUE']=!0x1,_0x4f928f['TONEMAPPING']=!0x1,_0x4f928f['TONEMAPPING_ACES']=!0x1,_0x4f928f['CONTRAST']=!0x1,_0x4f928f['EXPOSURE']=!0x1,_0x4f928f['COLORCURVES']=!0x1,_0x4f928f['COLORGRADING']=!0x1,_0x4f928f['COLORGRADING3D']=!0x1,_0x4f928f['SAMPLER3DGREENDEPTH']=!0x1,_0x4f928f['SAMPLER3DBGRMAP']=!0x1,_0x4f928f['IMAGEPROCESSINGPOSTPROCESS']=!0x1,_0x4f928f['BUMPDIRECTUV']=0x0,_0x4f928f['rebuild'](),_0x4f928f;}return Object(_0x18e13d['d'])(_0x1201ea,_0x4a0f8c),_0x1201ea['prototype']['setValue']=function(_0x3add86,_0x106be5,_0x376bd0){void 0x0===_0x376bd0&&(_0x376bd0=!0x1),void 0x0===this[_0x3add86]&&this['_keys']['push'](_0x3add86),_0x376bd0&&this[_0x3add86]!==_0x106be5&&this['markAsUnprocessed'](),this[_0x3add86]=_0x106be5;},_0x1201ea;}(_0x35e5d5['a']),_0x457d3e=function(_0x2d75ed){function _0x3f265b(_0x174b6a,_0x1afc39,_0x16e454){void 0x0===_0x16e454&&(_0x16e454={});var _0xa5fadf=_0x2d75ed['call'](this,_0x174b6a,_0x1afc39||_0x300b38['a']['LastCreatedScene'])||this;return _0xa5fadf['_buildId']=_0x3f265b['_BuildIdGenerator']++,_0xa5fadf['_buildWasSuccessful']=!0x1,_0xa5fadf['_cachedWorldViewMatrix']=new _0x74d525['a'](),_0xa5fadf['_cachedWorldViewProjectionMatrix']=new _0x74d525['a'](),_0xa5fadf['_optimizers']=new Array(),_0xa5fadf['_animationFrame']=-0x1,_0xa5fadf['BJSNODEMATERIALEDITOR']=_0xa5fadf['_getGlobalNodeMaterialEditor'](),_0xa5fadf['editorData']=null,_0xa5fadf['ignoreAlpha']=!0x1,_0xa5fadf['maxSimultaneousLights']=0x4,_0xa5fadf['onBuildObservable']=new _0x6ac1f7['c'](),_0xa5fadf['_vertexOutputNodes']=new Array(),_0xa5fadf['_fragmentOutputNodes']=new Array(),_0xa5fadf['attachedBlocks']=new Array(),_0xa5fadf['_mode']=_0x608fec['Material'],_0xa5fadf['_options']=Object(_0x18e13d['a'])({'emitComments':!0x1},_0x16e454),_0xa5fadf['_attachImageProcessingConfiguration'](null),_0xa5fadf;}return Object(_0x18e13d['d'])(_0x3f265b,_0x2d75ed),_0x3f265b['prototype']['_getGlobalNodeMaterialEditor']=function(){return'undefined'!=typeof NODEEDITOR?NODEEDITOR:'undefined'!=typeof BABYLON&&void 0x0!==BABYLON['NodeEditor']?BABYLON:void 0x0;},Object['defineProperty'](_0x3f265b['prototype'],'options',{'get':function(){return this['_options'];},'set':function(_0xe2415c){this['_options']=_0xe2415c;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3f265b['prototype'],'imageProcessingConfiguration',{'get':function(){return this['_imageProcessingConfiguration'];},'set':function(_0x2237bf){this['_attachImageProcessingConfiguration'](_0x2237bf),this['_markAllSubMeshesAsTexturesDirty']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3f265b['prototype'],'mode',{'get':function(){return this['_mode'];},'enumerable':!0x1,'configurable':!0x0}),_0x3f265b['prototype']['getClassName']=function(){return'NodeMaterial';},_0x3f265b['prototype']['_attachImageProcessingConfiguration']=function(_0x1b1154){var _0x183144=this;_0x1b1154!==this['_imageProcessingConfiguration']&&(this['_imageProcessingConfiguration']&&this['_imageProcessingObserver']&&this['_imageProcessingConfiguration']['onUpdateParameters']['remove'](this['_imageProcessingObserver']),this['_imageProcessingConfiguration']=_0x1b1154||this['getScene']()['imageProcessingConfiguration'],this['_imageProcessingConfiguration']&&(this['_imageProcessingObserver']=this['_imageProcessingConfiguration']['onUpdateParameters']['add'](function(){_0x183144['_markAllSubMeshesAsImageProcessingDirty']();})));},_0x3f265b['prototype']['getBlockByName']=function(_0x221cc3){for(var _0x5ab747=null,_0x4f8962=0x0,_0x53873a=this['attachedBlocks'];_0x4f8962<_0x53873a['length'];_0x4f8962++){var _0x5dc20b=_0x53873a[_0x4f8962];if(_0x5dc20b['name']===_0x221cc3){if(_0x5ab747)return _0x5d754c['b']['Warn']('More\x20than\x20one\x20block\x20was\x20found\x20with\x20the\x20name\x20`'+_0x221cc3+'`'),_0x5ab747;_0x5ab747=_0x5dc20b;}}return _0x5ab747;},_0x3f265b['prototype']['getBlockByPredicate']=function(_0xea5c62){for(var _0x58f885=0x0,_0x3b48ab=this['attachedBlocks'];_0x58f885<_0x3b48ab['length'];_0x58f885++){var _0x396c17=_0x3b48ab[_0x58f885];if(_0xea5c62(_0x396c17))return _0x396c17;}return null;},_0x3f265b['prototype']['getInputBlockByPredicate']=function(_0x1c59cb){for(var _0x122202=0x0,_0x49ed50=this['attachedBlocks'];_0x122202<_0x49ed50['length'];_0x122202++){var _0x14a880=_0x49ed50[_0x122202];if(_0x14a880['isInput']&&_0x1c59cb(_0x14a880))return _0x14a880;}return null;},_0x3f265b['prototype']['getInputBlocks']=function(){for(var _0x342525=[],_0x1c8e4e=0x0,_0x2363ac=this['attachedBlocks'];_0x1c8e4e<_0x2363ac['length'];_0x1c8e4e++){var _0x14e60f=_0x2363ac[_0x1c8e4e];_0x14e60f['isInput']&&_0x342525['push'](_0x14e60f);}return _0x342525;},_0x3f265b['prototype']['registerOptimizer']=function(_0x12ea5c){if(!(this['_optimizers']['indexOf'](_0x12ea5c)>-0x1))return this['_optimizers']['push'](_0x12ea5c),this;},_0x3f265b['prototype']['unregisterOptimizer']=function(_0x28c853){var _0x4fa69f=this['_optimizers']['indexOf'](_0x28c853);if(-0x1!==_0x4fa69f)return this['_optimizers']['splice'](_0x4fa69f,0x1),this;},_0x3f265b['prototype']['addOutputNode']=function(_0x2e7c89){if(null===_0x2e7c89['target'])throw'This\x20node\x20is\x20not\x20meant\x20to\x20be\x20an\x20output\x20node.\x20You\x20may\x20want\x20to\x20explicitly\x20set\x20its\x20target\x20value.';return 0x0!=(_0x2e7c89['target']&_0x4e54a1['Vertex'])&&this['_addVertexOutputNode'](_0x2e7c89),0x0!=(_0x2e7c89['target']&_0x4e54a1['Fragment'])&&this['_addFragmentOutputNode'](_0x2e7c89),this;},_0x3f265b['prototype']['removeOutputNode']=function(_0x3db399){return null===_0x3db399['target']||(0x0!=(_0x3db399['target']&_0x4e54a1['Vertex'])&&this['_removeVertexOutputNode'](_0x3db399),0x0!=(_0x3db399['target']&_0x4e54a1['Fragment'])&&this['_removeFragmentOutputNode'](_0x3db399)),this;},_0x3f265b['prototype']['_addVertexOutputNode']=function(_0x3d42b0){if(-0x1===this['_vertexOutputNodes']['indexOf'](_0x3d42b0))return _0x3d42b0['target']=_0x4e54a1['Vertex'],this['_vertexOutputNodes']['push'](_0x3d42b0),this;},_0x3f265b['prototype']['_removeVertexOutputNode']=function(_0x4a5aa0){var _0x3d64d4=this['_vertexOutputNodes']['indexOf'](_0x4a5aa0);if(-0x1!==_0x3d64d4)return this['_vertexOutputNodes']['splice'](_0x3d64d4,0x1),this;},_0x3f265b['prototype']['_addFragmentOutputNode']=function(_0x217867){if(-0x1===this['_fragmentOutputNodes']['indexOf'](_0x217867))return _0x217867['target']=_0x4e54a1['Fragment'],this['_fragmentOutputNodes']['push'](_0x217867),this;},_0x3f265b['prototype']['_removeFragmentOutputNode']=function(_0xe903bd){var _0x157048=this['_fragmentOutputNodes']['indexOf'](_0xe903bd);if(-0x1!==_0x157048)return this['_fragmentOutputNodes']['splice'](_0x157048,0x1),this;},_0x3f265b['prototype']['needAlphaBlending']=function(){return!this['ignoreAlpha']&&(this['alpha']<0x1||this['_sharedData']&&this['_sharedData']['hints']['needAlphaBlending']);},_0x3f265b['prototype']['needAlphaTesting']=function(){return this['_sharedData']&&this['_sharedData']['hints']['needAlphaTesting'];},_0x3f265b['prototype']['_initializeBlock']=function(_0x3e2f34,_0x2f3505,_0x607e1d){if(_0x3e2f34['initialize'](_0x2f3505),_0x3e2f34['autoConfigure'](this),_0x3e2f34['_preparationId']=this['_buildId'],-0x1===this['attachedBlocks']['indexOf'](_0x3e2f34)){if(_0x3e2f34['isUnique'])for(var _0xeace0a=_0x3e2f34['getClassName'](),_0x34caf0=0x0,_0x46d3b9=this['attachedBlocks'];_0x34caf0<_0x46d3b9['length'];_0x34caf0++){if(_0x46d3b9[_0x34caf0]['getClassName']()===_0xeace0a)throw'Cannot\x20have\x20multiple\x20blocks\x20of\x20type\x20'+_0xeace0a+'\x20in\x20the\x20same\x20NodeMaterial';}this['attachedBlocks']['push'](_0x3e2f34);}for(var _0x42d38a=0x0,_0x3882d2=_0x3e2f34['inputs'];_0x42d38a<_0x3882d2['length'];_0x42d38a++){var _0x418964=_0x3882d2[_0x42d38a];_0x418964['associatedVariableName']='';var _0x3d483e=_0x418964['connectedPoint'];if(_0x3d483e){var _0x28717a=_0x3d483e['ownerBlock'];_0x28717a!==_0x3e2f34&&((_0x28717a['target']===_0x4e54a1['VertexAndFragment']||_0x2f3505['target']===_0x4e54a1['Fragment']&&_0x28717a['target']===_0x4e54a1['Vertex']&&_0x28717a['_preparationId']!==this['_buildId'])&&_0x607e1d['push'](_0x28717a),this['_initializeBlock'](_0x28717a,_0x2f3505,_0x607e1d));}}for(var _0x533e86=0x0,_0x28f8f1=_0x3e2f34['outputs'];_0x533e86<_0x28f8f1['length'];_0x533e86++){_0x28f8f1[_0x533e86]['associatedVariableName']='';}},_0x3f265b['prototype']['_resetDualBlocks']=function(_0x346e5e,_0x32383a){_0x346e5e['target']===_0x4e54a1['VertexAndFragment']&&(_0x346e5e['buildId']=_0x32383a);for(var _0x1b78e8=0x0,_0x387b29=_0x346e5e['inputs'];_0x1b78e8<_0x387b29['length'];_0x1b78e8++){var _0x161ef9=_0x387b29[_0x1b78e8]['connectedPoint'];if(_0x161ef9){var _0x434a0f=_0x161ef9['ownerBlock'];_0x434a0f!==_0x346e5e&&this['_resetDualBlocks'](_0x434a0f,_0x32383a);}}},_0x3f265b['prototype']['removeBlock']=function(_0x2bc0d3){var _0xf7086c=this['attachedBlocks']['indexOf'](_0x2bc0d3);_0xf7086c>-0x1&&this['attachedBlocks']['splice'](_0xf7086c,0x1),_0x2bc0d3['isFinalMerger']&&this['removeOutputNode'](_0x2bc0d3);},_0x3f265b['prototype']['build']=function(_0x3e8628){void 0x0===_0x3e8628&&(_0x3e8628=!0x1),this['_buildWasSuccessful']=!0x1;var _0x5cfb62=this['getScene']()['getEngine'](),_0x553905=this['_mode']===_0x608fec['Particle'];if(0x0===this['_vertexOutputNodes']['length']&&!_0x553905)throw'You\x20must\x20define\x20at\x20least\x20one\x20vertexOutputNode';if(0x0===this['_fragmentOutputNodes']['length'])throw'You\x20must\x20define\x20at\x20least\x20one\x20fragmentOutputNode';this['_vertexCompilationState']=new _0x39c704(),this['_vertexCompilationState']['supportUniformBuffers']=_0x5cfb62['supportsUniformBuffers'],this['_vertexCompilationState']['target']=_0x4e54a1['Vertex'],this['_fragmentCompilationState']=new _0x39c704(),this['_fragmentCompilationState']['supportUniformBuffers']=_0x5cfb62['supportsUniformBuffers'],this['_fragmentCompilationState']['target']=_0x4e54a1['Fragment'],this['_sharedData']=new _0x144676(),this['_vertexCompilationState']['sharedData']=this['_sharedData'],this['_fragmentCompilationState']['sharedData']=this['_sharedData'],this['_sharedData']['buildId']=this['_buildId'],this['_sharedData']['emitComments']=this['_options']['emitComments'],this['_sharedData']['verbose']=_0x3e8628,this['_sharedData']['scene']=this['getScene'](),this['_sharedData']['allowEmptyVertexProgram']=_0x553905;for(var _0x3ca99d=[],_0x299c85=[],_0x32645b=0x0,_0x4135a5=this['_vertexOutputNodes'];_0x32645b<_0x4135a5['length'];_0x32645b++){var _0x5e02ec=_0x4135a5[_0x32645b];_0x3ca99d['push'](_0x5e02ec),this['_initializeBlock'](_0x5e02ec,this['_vertexCompilationState'],_0x299c85);}for(var _0x4689dd=0x0,_0x473519=this['_fragmentOutputNodes'];_0x4689dd<_0x473519['length'];_0x4689dd++){var _0x52e167=_0x473519[_0x4689dd];_0x299c85['push'](_0x52e167),this['_initializeBlock'](_0x52e167,this['_fragmentCompilationState'],_0x3ca99d);}this['optimize']();for(var _0x3fcdf8=0x0,_0x41d81a=_0x3ca99d;_0x3fcdf8<_0x41d81a['length'];_0x3fcdf8++){(_0x5e02ec=_0x41d81a[_0x3fcdf8])['build'](this['_vertexCompilationState'],_0x3ca99d);}this['_fragmentCompilationState']['uniforms']=this['_vertexCompilationState']['uniforms']['slice'](0x0),this['_fragmentCompilationState']['_uniformDeclaration']=this['_vertexCompilationState']['_uniformDeclaration'],this['_fragmentCompilationState']['_constantDeclaration']=this['_vertexCompilationState']['_constantDeclaration'],this['_fragmentCompilationState']['_vertexState']=this['_vertexCompilationState'];for(var _0xbab291=0x0,_0x34d56f=_0x299c85;_0xbab291<_0x34d56f['length'];_0xbab291++){_0x52e167=_0x34d56f[_0xbab291],this['_resetDualBlocks'](_0x52e167,this['_buildId']-0x1);}for(var _0x3b3262=0x0,_0x228dad=_0x299c85;_0x3b3262<_0x228dad['length'];_0x3b3262++){(_0x52e167=_0x228dad[_0x3b3262])['build'](this['_fragmentCompilationState'],_0x299c85);}this['_vertexCompilationState']['finalize'](this['_vertexCompilationState']),this['_fragmentCompilationState']['finalize'](this['_fragmentCompilationState']),this['_buildId']=_0x3f265b['_BuildIdGenerator']++,this['_sharedData']['emitErrors'](),_0x3e8628&&(console['log']('Vertex\x20shader:'),console['log'](this['_vertexCompilationState']['compilationString']),console['log']('Fragment\x20shader:'),console['log'](this['_fragmentCompilationState']['compilationString'])),this['_buildWasSuccessful']=!0x0,this['onBuildObservable']['notifyObservers'](this);for(var _0x1f8735=0x0,_0x14769e=this['getScene']()['meshes'];_0x1f8735<_0x14769e['length'];_0x1f8735++){var _0x5140d3=_0x14769e[_0x1f8735];if(_0x5140d3['subMeshes'])for(var _0x35284c=0x0,_0x57c822=_0x5140d3['subMeshes'];_0x35284c<_0x57c822['length'];_0x35284c++){var _0x5e775a=_0x57c822[_0x35284c];if(_0x5e775a['getMaterial']()===this&&_0x5e775a['_materialDefines']){var _0x198243=_0x5e775a['_materialDefines'];_0x198243['markAllAsDirty'](),_0x198243['reset']();}}}},_0x3f265b['prototype']['optimize']=function(){for(var _0x4522d1=0x0,_0x7b771f=this['_optimizers'];_0x4522d1<_0x7b771f['length'];_0x4522d1++){_0x7b771f[_0x4522d1]['optimize'](this['_vertexOutputNodes'],this['_fragmentOutputNodes']);}},_0x3f265b['prototype']['_prepareDefinesForAttributes']=function(_0x3bf93c,_0x3105a4){var _0x1cc7ee=_0x3105a4['NORMAL'],_0xdfa588=_0x3105a4['TANGENT'],_0x21dcf0=_0x3105a4['UV1'];_0x3105a4['NORMAL']=_0x3bf93c['isVerticesDataPresent'](_0x212fbd['b']['NormalKind']),_0x3105a4['TANGENT']=_0x3bf93c['isVerticesDataPresent'](_0x212fbd['b']['TangentKind']),_0x3105a4['UV1']=_0x3bf93c['isVerticesDataPresent'](_0x212fbd['b']['UVKind']),_0x1cc7ee===_0x3105a4['NORMAL']&&_0xdfa588===_0x3105a4['TANGENT']&&_0x21dcf0===_0x3105a4['UV1']||_0x3105a4['markAsAttributesDirty']();},_0x3f265b['prototype']['createPostProcess']=function(_0x4c771d,_0x4339fb,_0x5f33cd,_0x235aef,_0x39cb80,_0x22aa21,_0x9c44b1){return void 0x0===_0x4339fb&&(_0x4339fb=0x1),void 0x0===_0x5f33cd&&(_0x5f33cd=_0x2103ba['a']['TEXTURE_NEAREST_SAMPLINGMODE']),void 0x0===_0x22aa21&&(_0x22aa21=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),void 0x0===_0x9c44b1&&(_0x9c44b1=_0x2103ba['a']['TEXTUREFORMAT_RGBA']),this['mode']!==_0x608fec['PostProcess']?(console['log']('Incompatible\x20material\x20mode'),null):this['_createEffectForPostProcess'](null,_0x4c771d,_0x4339fb,_0x5f33cd,_0x235aef,_0x39cb80,_0x22aa21,_0x9c44b1);},_0x3f265b['prototype']['createEffectForPostProcess']=function(_0xa1151c){this['_createEffectForPostProcess'](_0xa1151c);},_0x3f265b['prototype']['_createEffectForPostProcess']=function(_0xba485a,_0x581787,_0xe09b0b,_0x1487d8,_0x529889,_0x32974a,_0x368377,_0x3ac1dd){var _0x482b7c=this;void 0x0===_0xe09b0b&&(_0xe09b0b=0x1),void 0x0===_0x1487d8&&(_0x1487d8=_0x2103ba['a']['TEXTURE_NEAREST_SAMPLINGMODE']),void 0x0===_0x368377&&(_0x368377=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),void 0x0===_0x3ac1dd&&(_0x3ac1dd=_0x2103ba['a']['TEXTUREFORMAT_RGBA']);var _0x42b30a=this['name']+this['_buildId'],_0x29b8d2=new _0x412d6e(),_0x3e0ff1=new _0x40d22e['a'](_0x42b30a+'PostProcess',this['getScene']()),_0x5cb06d=this['_buildId'];return this['_processDefines'](_0x3e0ff1,_0x29b8d2),_0x494b01['a']['RegisterShader'](_0x42b30a,this['_fragmentCompilationState']['_builtCompilationString'],this['_vertexCompilationState']['_builtCompilationString']),_0xba485a?_0xba485a['updateEffect'](_0x29b8d2['toString'](),this['_fragmentCompilationState']['uniforms'],this['_fragmentCompilationState']['samplers'],{'maxSimultaneousLights':this['maxSimultaneousLights']},void 0x0,void 0x0,_0x42b30a,_0x42b30a):_0xba485a=new _0x5cae84(this['name']+'PostProcess',_0x42b30a,this['_fragmentCompilationState']['uniforms'],this['_fragmentCompilationState']['samplers'],_0xe09b0b,_0x581787,_0x1487d8,_0x529889,_0x32974a,_0x29b8d2['toString'](),_0x368377,_0x42b30a,{'maxSimultaneousLights':this['maxSimultaneousLights']},!0x1,_0x3ac1dd),_0xba485a['nodeMaterialSource']=this,_0xba485a['onApplyObservable']['add'](function(_0x322d6a){_0x5cb06d!==_0x482b7c['_buildId']&&(delete _0x494b01['a']['ShadersStore'][_0x42b30a+'VertexShader'],delete _0x494b01['a']['ShadersStore'][_0x42b30a+'PixelShader'],_0x42b30a=_0x482b7c['name']+_0x482b7c['_buildId'],_0x29b8d2['markAsUnprocessed'](),_0x5cb06d=_0x482b7c['_buildId']),_0x482b7c['_processDefines'](_0x3e0ff1,_0x29b8d2)&&(_0x494b01['a']['RegisterShader'](_0x42b30a,_0x482b7c['_fragmentCompilationState']['_builtCompilationString'],_0x482b7c['_vertexCompilationState']['_builtCompilationString']),_0x3ecaa7['a']['SetImmediate'](function(){return _0xba485a['updateEffect'](_0x29b8d2['toString'](),_0x482b7c['_fragmentCompilationState']['uniforms'],_0x482b7c['_fragmentCompilationState']['samplers'],{'maxSimultaneousLights':_0x482b7c['maxSimultaneousLights']},void 0x0,void 0x0,_0x42b30a,_0x42b30a);})),_0x482b7c['_checkInternals'](_0x322d6a);}),_0xba485a;},_0x3f265b['prototype']['createProceduralTexture']=function(_0x2257a8,_0x66dd3c){var _0x39ef42=this;if(this['mode']!==_0x608fec['ProceduralTexture'])return console['log']('Incompatible\x20material\x20mode'),null;var _0x59df17=this['name']+this['_buildId'],_0x363e36=new _0x27f07d(_0x59df17,_0x2257a8,null,_0x66dd3c),_0x50fdde=new _0x40d22e['a'](_0x59df17+'Procedural',this['getScene']());_0x50fdde['reservedDataStore']={'hidden':!0x0};var _0x208a53=new _0x412d6e(),_0xdde33d=this['_processDefines'](_0x50fdde,_0x208a53);_0x494b01['a']['RegisterShader'](_0x59df17,this['_fragmentCompilationState']['_builtCompilationString'],this['_vertexCompilationState']['_builtCompilationString']);var _0x2b36db=this['getScene']()['getEngine']()['createEffect']({'vertexElement':_0x59df17,'fragmentElement':_0x59df17},[_0x212fbd['b']['PositionKind']],this['_fragmentCompilationState']['uniforms'],this['_fragmentCompilationState']['samplers'],_0x208a53['toString'](),null==_0xdde33d?void 0x0:_0xdde33d['fallbacks'],void 0x0);_0x363e36['nodeMaterialSource']=this,_0x363e36['_effect']=_0x2b36db;var _0x194c77=this['_buildId'];return _0x363e36['onBeforeGenerationObservable']['add'](function(){_0x194c77!==_0x39ef42['_buildId']&&(delete _0x494b01['a']['ShadersStore'][_0x59df17+'VertexShader'],delete _0x494b01['a']['ShadersStore'][_0x59df17+'PixelShader'],_0x59df17=_0x39ef42['name']+_0x39ef42['_buildId'],_0x208a53['markAsUnprocessed'](),_0x194c77=_0x39ef42['_buildId']);var _0x2bf48f=_0x39ef42['_processDefines'](_0x50fdde,_0x208a53);_0x2bf48f&&(_0x494b01['a']['RegisterShader'](_0x59df17,_0x39ef42['_fragmentCompilationState']['_builtCompilationString'],_0x39ef42['_vertexCompilationState']['_builtCompilationString']),_0x3ecaa7['a']['SetImmediate'](function(){_0x2b36db=_0x39ef42['getScene']()['getEngine']()['createEffect']({'vertexElement':_0x59df17,'fragmentElement':_0x59df17},[_0x212fbd['b']['PositionKind']],_0x39ef42['_fragmentCompilationState']['uniforms'],_0x39ef42['_fragmentCompilationState']['samplers'],_0x208a53['toString'](),null==_0x2bf48f?void 0x0:_0x2bf48f['fallbacks'],void 0x0),_0x363e36['_effect']=_0x2b36db;})),_0x39ef42['_checkInternals'](_0x2b36db);}),_0x363e36;},_0x3f265b['prototype']['_createEffectForParticles']=function(_0x2d516c,_0x23c261,_0xee3db3,_0x211ce1,_0x2dadfc,_0x54c195,_0x1885d1,_0xfcdc90){var _0x4bd7ba=this;void 0x0===_0xfcdc90&&(_0xfcdc90='');var _0x33f011=this['name']+this['_buildId']+'_'+_0x23c261;_0x54c195||(_0x54c195=new _0x412d6e()),_0x1885d1||(_0x1885d1=this['getScene']()['getMeshByName'](this['name']+'Particle'))||((_0x1885d1=new _0x40d22e['a'](this['name']+'Particle',this['getScene']()))['reservedDataStore']={'hidden':!0x0});var _0x2ab172=this['_buildId'],_0x1f3c25=[],_0xaedf06=_0xfcdc90;if(!_0x2dadfc){var _0x39534d=this['_processDefines'](_0x1885d1,_0x54c195);_0x494b01['a']['RegisterShader'](_0x33f011,this['_fragmentCompilationState']['_builtCompilationString']),_0x2d516c['fillDefines'](_0x1f3c25,_0x23c261),_0xaedf06=_0x1f3c25['join']('\x0a'),_0x2dadfc=this['getScene']()['getEngine']()['createEffectForParticles'](_0x33f011,this['_fragmentCompilationState']['uniforms'],this['_fragmentCompilationState']['samplers'],_0x54c195['toString']()+'\x0a'+_0xaedf06,null==_0x39534d?void 0x0:_0x39534d['fallbacks'],_0xee3db3,_0x211ce1,_0x2d516c),_0x2d516c['setCustomEffect'](_0x2dadfc,_0x23c261);}_0x2dadfc['onBindObservable']['add'](function(_0x3bd813){_0x2ab172!==_0x4bd7ba['_buildId']&&(delete _0x494b01['a']['ShadersStore'][_0x33f011+'PixelShader'],_0x33f011=_0x4bd7ba['name']+_0x4bd7ba['_buildId']+'_'+_0x23c261,_0x54c195['markAsUnprocessed'](),_0x2ab172=_0x4bd7ba['_buildId']),_0x1f3c25['length']=0x0,_0x2d516c['fillDefines'](_0x1f3c25,_0x23c261);var _0x5b7eed=_0x1f3c25['join']('\x0a');_0x5b7eed!==_0xaedf06&&(_0x54c195['markAsUnprocessed'](),_0xaedf06=_0x5b7eed);var _0x339847=_0x4bd7ba['_processDefines'](_0x1885d1,_0x54c195);if(_0x339847)return _0x494b01['a']['RegisterShader'](_0x33f011,_0x4bd7ba['_fragmentCompilationState']['_builtCompilationString']),_0x3bd813=_0x4bd7ba['getScene']()['getEngine']()['createEffectForParticles'](_0x33f011,_0x4bd7ba['_fragmentCompilationState']['uniforms'],_0x4bd7ba['_fragmentCompilationState']['samplers'],_0x54c195['toString']()+'\x0a'+_0xaedf06,null==_0x339847?void 0x0:_0x339847['fallbacks'],_0xee3db3,_0x211ce1,_0x2d516c),_0x2d516c['setCustomEffect'](_0x3bd813,_0x23c261),void _0x4bd7ba['_createEffectForParticles'](_0x2d516c,_0x23c261,_0xee3db3,_0x211ce1,_0x3bd813,_0x54c195,_0x1885d1,_0xaedf06);_0x4bd7ba['_checkInternals'](_0x3bd813);});},_0x3f265b['prototype']['_checkInternals']=function(_0x3333be){if(this['_sharedData']['animatedInputs']){var _0x1e45d8=this['getScene'](),_0x4f1d3f=_0x1e45d8['getFrameId']();if(this['_animationFrame']!==_0x4f1d3f){for(var _0x1ae317=0x0,_0x466ff9=this['_sharedData']['animatedInputs'];_0x1ae317<_0x466ff9['length'];_0x1ae317++){_0x466ff9[_0x1ae317]['animate'](_0x1e45d8);}this['_animationFrame']=_0x4f1d3f;}}for(var _0x3b7f65=0x0,_0x195707=this['_sharedData']['bindableBlocks'];_0x3b7f65<_0x195707['length'];_0x3b7f65++){_0x195707[_0x3b7f65]['bind'](_0x3333be,this);}for(var _0x16d67b=0x0,_0x282612=this['_sharedData']['inputBlocks'];_0x16d67b<_0x282612['length'];_0x16d67b++){_0x282612[_0x16d67b]['_transmit'](_0x3333be,this['getScene']());}},_0x3f265b['prototype']['createEffectForParticles']=function(_0x23b36b,_0x3c878e,_0x54bb89){this['mode']===_0x608fec['Particle']?(this['_createEffectForParticles'](_0x23b36b,_0x2e1395['BLENDMODE_ONEONE'],_0x3c878e,_0x54bb89),this['_createEffectForParticles'](_0x23b36b,_0x2e1395['BLENDMODE_MULTIPLY'],_0x3c878e,_0x54bb89)):console['log']('Incompatible\x20material\x20mode');},_0x3f265b['prototype']['_processDefines']=function(_0x53cc33,_0x24ba87,_0x5bf9a3,_0x5eb5aa){var _0x4d52f0=this;void 0x0===_0x5bf9a3&&(_0x5bf9a3=!0x1);var _0x573e69=null;if(this['_sharedData']['blocksWithDefines']['forEach'](function(_0x4d008e){_0x4d008e['initializeDefines'](_0x53cc33,_0x4d52f0,_0x24ba87,_0x5bf9a3);}),this['_sharedData']['blocksWithDefines']['forEach'](function(_0x51ff09){_0x51ff09['prepareDefines'](_0x53cc33,_0x4d52f0,_0x24ba87,_0x5bf9a3,_0x5eb5aa);}),_0x24ba87['isDirty']){var _0x306fb1=_0x24ba87['_areLightsDisposed'];_0x24ba87['markAsProcessed'](),this['_vertexCompilationState']['compilationString']=this['_vertexCompilationState']['_builtCompilationString'],this['_fragmentCompilationState']['compilationString']=this['_fragmentCompilationState']['_builtCompilationString'],this['_sharedData']['repeatableContentBlocks']['forEach'](function(_0x3278de){_0x3278de['replaceRepeatableContent'](_0x4d52f0['_vertexCompilationState'],_0x4d52f0['_fragmentCompilationState'],_0x53cc33,_0x24ba87);});var _0x552354=[];this['_sharedData']['dynamicUniformBlocks']['forEach'](function(_0xb4ddca){_0xb4ddca['updateUniformsAndSamples'](_0x4d52f0['_vertexCompilationState'],_0x4d52f0,_0x24ba87,_0x552354);});var _0x365da5=this['_vertexCompilationState']['uniforms'];this['_fragmentCompilationState']['uniforms']['forEach'](function(_0x48b9d3){-0x1===_0x365da5['indexOf'](_0x48b9d3)&&_0x365da5['push'](_0x48b9d3);});var _0x1486da=this['_vertexCompilationState']['samplers'];this['_fragmentCompilationState']['samplers']['forEach'](function(_0x97579a){-0x1===_0x1486da['indexOf'](_0x97579a)&&_0x1486da['push'](_0x97579a);});var _0x1dc541=new _0x1603d9['a']();this['_sharedData']['blocksWithFallbacks']['forEach'](function(_0x1cafaf){_0x1cafaf['provideFallbacks'](_0x53cc33,_0x1dc541);}),_0x573e69={'lightDisposed':_0x306fb1,'uniformBuffers':_0x552354,'mergedUniforms':_0x365da5,'mergedSamplers':_0x1486da,'fallbacks':_0x1dc541};}return _0x573e69;},_0x3f265b['prototype']['isReadyForSubMesh']=function(_0x5a8fdc,_0x22c278,_0x45a36a){var _0x11e4e1=this;if(void 0x0===_0x45a36a&&(_0x45a36a=!0x1),!this['_buildWasSuccessful'])return!0x1;var _0x19d22b=this['getScene']();if(this['_sharedData']['animatedInputs']){var _0x4975bc=_0x19d22b['getFrameId']();if(this['_animationFrame']!==_0x4975bc){for(var _0x78f15e=0x0,_0x49bc2b=this['_sharedData']['animatedInputs'];_0x78f15e<_0x49bc2b['length'];_0x78f15e++){_0x49bc2b[_0x78f15e]['animate'](_0x19d22b);}this['_animationFrame']=_0x4975bc;}}if(_0x22c278['effect']&&this['isFrozen']&&_0x22c278['effect']['_wasPreviouslyReady'])return!0x0;_0x22c278['_materialDefines']||(_0x22c278['_materialDefines']=new _0x412d6e());var _0x326bc4=_0x22c278['_materialDefines'];if(this['_isReadyForSubMesh'](_0x22c278))return!0x0;var _0x1b5e44=_0x19d22b['getEngine']();if(this['_prepareDefinesForAttributes'](_0x5a8fdc,_0x326bc4),this['_sharedData']['blockingBlocks']['some'](function(_0x28c871){return!_0x28c871['isReady'](_0x5a8fdc,_0x11e4e1,_0x326bc4,_0x45a36a);}))return!0x1;var _0x2e5eba=this['_processDefines'](_0x5a8fdc,_0x326bc4,_0x45a36a,_0x22c278);if(_0x2e5eba){var _0x211fb0=_0x22c278['effect'],_0x50492a=_0x326bc4['toString'](),_0xe3ab6a=_0x1b5e44['createEffect']({'vertex':'nodeMaterial'+this['_buildId'],'fragment':'nodeMaterial'+this['_buildId'],'vertexSource':this['_vertexCompilationState']['compilationString'],'fragmentSource':this['_fragmentCompilationState']['compilationString']},{'attributes':this['_vertexCompilationState']['attributes'],'uniformsNames':_0x2e5eba['mergedUniforms'],'uniformBuffersNames':_0x2e5eba['uniformBuffers'],'samplers':_0x2e5eba['mergedSamplers'],'defines':_0x50492a,'fallbacks':_0x2e5eba['fallbacks'],'onCompiled':this['onCompiled'],'onError':this['onError'],'indexParameters':{'maxSimultaneousLights':this['maxSimultaneousLights'],'maxSimultaneousMorphTargets':_0x326bc4['NUM_MORPH_INFLUENCERS']}},_0x1b5e44);if(_0xe3ab6a){if(this['_onEffectCreatedObservable']&&(_0x3edf52['effect']=_0xe3ab6a,_0x3edf52['subMesh']=_0x22c278,this['_onEffectCreatedObservable']['notifyObservers'](_0x3edf52)),this['allowShaderHotSwapping']&&_0x211fb0&&!_0xe3ab6a['isReady']()){if(_0xe3ab6a=_0x211fb0,_0x326bc4['markAsUnprocessed'](),_0x2e5eba['lightDisposed'])return _0x326bc4['_areLightsDisposed']=!0x0,!0x1;}else _0x19d22b['resetCachedMaterial'](),_0x22c278['setEffect'](_0xe3ab6a,_0x326bc4);}}return!(!_0x22c278['effect']||!_0x22c278['effect']['isReady']())&&(_0x326bc4['_renderId']=_0x19d22b['getRenderId'](),_0x22c278['effect']['_wasPreviouslyReady']=!0x0,!0x0);},Object['defineProperty'](_0x3f265b['prototype'],'compiledShaders',{'get':function(){return'//\x20Vertex\x20shader\x0d\x0a'+this['_vertexCompilationState']['compilationString']+'\x0d\x0a\x0d\x0a//\x20Fragment\x20shader\x0d\x0a'+this['_fragmentCompilationState']['compilationString'];},'enumerable':!0x1,'configurable':!0x0}),_0x3f265b['prototype']['bindOnlyWorldMatrix']=function(_0x3f45f5){var _0x5b2148=this['getScene']();if(this['_activeEffect']){var _0x48d77e=this['_sharedData']['hints'];_0x48d77e['needWorldViewMatrix']&&_0x3f45f5['multiplyToRef'](_0x5b2148['getViewMatrix'](),this['_cachedWorldViewMatrix']),_0x48d77e['needWorldViewProjectionMatrix']&&_0x3f45f5['multiplyToRef'](_0x5b2148['getTransformMatrix'](),this['_cachedWorldViewProjectionMatrix']);for(var _0xd7c617=0x0,_0xd67be=this['_sharedData']['inputBlocks'];_0xd7c617<_0xd67be['length'];_0xd7c617++){_0xd67be[_0xd7c617]['_transmitWorld'](this['_activeEffect'],_0x3f45f5,this['_cachedWorldViewMatrix'],this['_cachedWorldViewProjectionMatrix']);}}},_0x3f265b['prototype']['bindForSubMesh']=function(_0x46839c,_0x1cfb7c,_0x2c7ad8){var _0x1dff40=this['getScene'](),_0x48a4a1=_0x2c7ad8['effect'];if(_0x48a4a1){if(this['_activeEffect']=_0x48a4a1,this['bindOnlyWorldMatrix'](_0x46839c),this['_mustRebind'](_0x1dff40,_0x48a4a1,_0x1cfb7c['visibility'])){var _0x4b652f=this['_sharedData'];if(_0x48a4a1&&_0x1dff40['getCachedEffect']()!==_0x48a4a1){for(var _0x1694f6=0x0,_0xee7edd=_0x4b652f['bindableBlocks'];_0x1694f6<_0xee7edd['length'];_0x1694f6++){_0xee7edd[_0x1694f6]['bind'](_0x48a4a1,this,_0x1cfb7c,_0x2c7ad8);}for(var _0x16fc27=0x0,_0x64984a=_0x4b652f['inputBlocks'];_0x16fc27<_0x64984a['length'];_0x16fc27++){_0x64984a[_0x16fc27]['_transmit'](_0x48a4a1,_0x1dff40);}}}this['_afterBind'](_0x1cfb7c,this['_activeEffect']);}},_0x3f265b['prototype']['getActiveTextures']=function(){var _0x5374cf=_0x2d75ed['prototype']['getActiveTextures']['call'](this);return this['_sharedData']&&_0x5374cf['push']['apply'](_0x5374cf,this['_sharedData']['textureBlocks']['filter'](function(_0x39fb08){return _0x39fb08['texture'];})['map'](function(_0x2d5dd0){return _0x2d5dd0['texture'];})),_0x5374cf;},_0x3f265b['prototype']['getTextureBlocks']=function(){return this['_sharedData']?this['_sharedData']['textureBlocks']:[];},_0x3f265b['prototype']['hasTexture']=function(_0x129e95){if(_0x2d75ed['prototype']['hasTexture']['call'](this,_0x129e95))return!0x0;if(!this['_sharedData'])return!0x1;for(var _0x19affe=0x0,_0x3340ea=this['_sharedData']['textureBlocks'];_0x19affe<_0x3340ea['length'];_0x19affe++){if(_0x3340ea[_0x19affe]['texture']===_0x129e95)return!0x0;}return!0x1;},_0x3f265b['prototype']['dispose']=function(_0x920fa9,_0x4a1243,_0x3ce71d){if(_0x4a1243)for(var _0x5d62ed=0x0,_0x508c04=this['_sharedData']['textureBlocks']['filter'](function(_0x538da8){return _0x538da8['texture'];})['map'](function(_0x48c031){return _0x48c031['texture'];});_0x5d62ed<_0x508c04['length'];_0x5d62ed++){_0x508c04[_0x5d62ed]['dispose']();}for(var _0x3d4828=0x0,_0x294de8=this['attachedBlocks'];_0x3d4828<_0x294de8['length'];_0x3d4828++){_0x294de8[_0x3d4828]['dispose']();}this['onBuildObservable']['clear'](),_0x2d75ed['prototype']['dispose']['call'](this,_0x920fa9,_0x4a1243,_0x3ce71d);},_0x3f265b['prototype']['_createNodeEditor']=function(){this['BJSNODEMATERIALEDITOR']=this['BJSNODEMATERIALEDITOR']||this['_getGlobalNodeMaterialEditor'](),this['BJSNODEMATERIALEDITOR']['NodeEditor']['Show']({'nodeMaterial':this});},_0x3f265b['prototype']['edit']=function(_0x6e9f90){var _0x3ded79=this;return new Promise(function(_0x47a093,_0x376c42){if(void 0x0===_0x3ded79['BJSNODEMATERIALEDITOR']){var _0xced1d=_0x6e9f90&&_0x6e9f90['editorURL']?_0x6e9f90['editorURL']:_0x3f265b['EditorURL'];_0x5d754c['b']['LoadScript'](_0xced1d,function(){_0x3ded79['_createNodeEditor'](),_0x47a093();});}else _0x3ded79['_createNodeEditor'](),_0x47a093();});},_0x3f265b['prototype']['clear']=function(){this['_vertexOutputNodes']=[],this['_fragmentOutputNodes']=[],this['attachedBlocks']=[];},_0x3f265b['prototype']['setToDefault']=function(){this['clear'](),this['editorData']=null;var _0x127976=new _0x581182('Position');_0x127976['setAsAttribute']('position');var _0x15f84a=new _0x581182('World');_0x15f84a['setAsSystemValue'](BABYLON['NodeMaterialSystemValues']['World']);var _0x50defa=new _0x3fcbd4('WorldPos');_0x127976['connectTo'](_0x50defa),_0x15f84a['connectTo'](_0x50defa);var _0x4c028a=new _0x581182('ViewProjection');_0x4c028a['setAsSystemValue'](BABYLON['NodeMaterialSystemValues']['ViewProjection']);var _0x1c58b7=new _0x3fcbd4('WorldPos\x20*\x20ViewProjectionTransform');_0x50defa['connectTo'](_0x1c58b7),_0x4c028a['connectTo'](_0x1c58b7);var _0xb25e2f=new _0x5b4f0e('VertexOutput');_0x1c58b7['connectTo'](_0xb25e2f);var _0x4bfeab=new _0x581182('color');_0x4bfeab['value']=new _0x39310d['b'](0.8,0.8,0.8,0x1);var _0x45e9bf=new _0x1f2748('FragmentOutput');_0x4bfeab['connectTo'](_0x45e9bf),this['addOutputNode'](_0xb25e2f),this['addOutputNode'](_0x45e9bf),this['_mode']=_0x608fec['Material'];},_0x3f265b['prototype']['setToDefaultPostProcess']=function(){this['clear'](),this['editorData']=null;var _0xcc50c8=new _0x581182('Position');_0xcc50c8['setAsAttribute']('position2d');var _0x274cf9=new _0x581182('Constant1');_0x274cf9['isConstant']=!0x0,_0x274cf9['value']=0x1;var _0x4d930e=new _0x2ef6e9('Position3D');_0xcc50c8['connectTo'](_0x4d930e),_0x274cf9['connectTo'](_0x4d930e,{'input':'w'});var _0x52c73a=new _0x5b4f0e('VertexOutput');_0x4d930e['connectTo'](_0x52c73a);var _0x22f716=new _0x581182('Scale');_0x22f716['visibleInInspector']=!0x0,_0x22f716['value']=new _0x74d525['d'](0x1,0x1);var _0x6344b4=new _0x662ea4('uv0');_0xcc50c8['connectTo'](_0x6344b4);var _0x3a8e29=new _0x4b8ff3('UV\x20scale');_0x6344b4['connectTo'](_0x3a8e29),_0x22f716['connectTo'](_0x3a8e29);var _0x4354d0=new _0x6d15a7('CurrentScreen');_0x3a8e29['connectTo'](_0x4354d0),_0x4354d0['texture']=new _0xaf3c80['a']('https://assets.babylonjs.com/nme/currentScreenPostProcess.png',this['getScene']());var _0x2ad601=new _0x1f2748('FragmentOutput');_0x4354d0['connectTo'](_0x2ad601,{'output':'rgba'}),this['addOutputNode'](_0x52c73a),this['addOutputNode'](_0x2ad601),this['_mode']=_0x608fec['PostProcess'];},_0x3f265b['prototype']['setToDefaultProceduralTexture']=function(){this['clear'](),this['editorData']=null;var _0x1403f3=new _0x581182('Position');_0x1403f3['setAsAttribute']('position2d');var _0x23689e=new _0x581182('Constant1');_0x23689e['isConstant']=!0x0,_0x23689e['value']=0x1;var _0x539371=new _0x2ef6e9('Position3D');_0x1403f3['connectTo'](_0x539371),_0x23689e['connectTo'](_0x539371,{'input':'w'});var _0x5bf469=new _0x5b4f0e('VertexOutput');_0x539371['connectTo'](_0x5bf469);var _0x29c937=new _0x581182('Time');_0x29c937['value']=0x0,_0x29c937['min']=0x0,_0x29c937['max']=0x0,_0x29c937['isBoolean']=!0x1,_0x29c937['matrixMode']=0x0,_0x29c937['animationType']=_0x5b0248['Time'],_0x29c937['isConstant']=!0x1;var _0xa8ffc=new _0x581182('Color3');_0xa8ffc['value']=new _0x39310d['a'](0x1,0x1,0x1),_0xa8ffc['isConstant']=!0x1;var _0x2f7518=new _0x1f2748('FragmentOutput'),_0x393814=new _0x2ef6e9('VectorMerger');_0x393814['visibleInInspector']=!0x1;var _0x10b47c=new _0xfe96fa('Cos');_0x10b47c['operation']=_0x4872c7['Cos'],_0x1403f3['connectTo'](_0x393814),_0x29c937['output']['connectTo'](_0x10b47c['input']),_0x10b47c['output']['connectTo'](_0x393814['z']),_0x393814['xyzOut']['connectTo'](_0x2f7518['rgb']),this['addOutputNode'](_0x5bf469),this['addOutputNode'](_0x2f7518),this['_mode']=_0x608fec['ProceduralTexture'];},_0x3f265b['prototype']['setToDefaultParticle']=function(){this['clear'](),this['editorData']=null;var _0x6a0d36=new _0x581182('uv');_0x6a0d36['setAsAttribute']('particle_uv');var _0x10443f=new _0x56dc96('ParticleTexture');_0x6a0d36['connectTo'](_0x10443f);var _0x45b529=new _0x581182('Color');_0x45b529['setAsAttribute']('particle_color');var _0x285fb8=new _0x4b8ff3('Texture\x20*\x20Color');_0x10443f['connectTo'](_0x285fb8),_0x45b529['connectTo'](_0x285fb8);var _0x2a280a=new _0x154efb('ParticleRampGradient');_0x285fb8['connectTo'](_0x2a280a);var _0x50963d=new _0x48f9fa('ColorSplitter');_0x45b529['connectTo'](_0x50963d);var _0x572473=new _0x4bafb1('ParticleBlendMultiply');_0x2a280a['connectTo'](_0x572473),_0x10443f['connectTo'](_0x572473,{'output':'a'}),_0x50963d['connectTo'](_0x572473,{'output':'a'});var _0x21cb1d=new _0x1f2748('FragmentOutput');_0x572473['connectTo'](_0x21cb1d),this['addOutputNode'](_0x21cb1d),this['_mode']=_0x608fec['Particle'];},_0x3f265b['prototype']['loadAsync']=function(_0x10f4ed){var _0x49b4c3=this;return this['getScene']()['_loadFileAsync'](_0x10f4ed)['then'](function(_0x5eb351){var _0xa2d54d=JSON['parse'](_0x5eb351);_0x49b4c3['loadFromSerialization'](_0xa2d54d,'');});},_0x3f265b['prototype']['_gatherBlocks']=function(_0x2699d9,_0x332168){if(-0x1===_0x332168['indexOf'](_0x2699d9)){_0x332168['push'](_0x2699d9);for(var _0x155c2e=0x0,_0x43a7ff=_0x2699d9['inputs'];_0x155c2e<_0x43a7ff['length'];_0x155c2e++){var _0x3d52b9=_0x43a7ff[_0x155c2e]['connectedPoint'];if(_0x3d52b9){var _0x2c95e6=_0x3d52b9['ownerBlock'];_0x2c95e6!==_0x2699d9&&this['_gatherBlocks'](_0x2c95e6,_0x332168);}}}},_0x3f265b['prototype']['generateCode']=function(){for(var _0x21dd92=[],_0x598dc1=[],_0x1fb3f4=[],_0xca3321=0x0,_0x2ed4f4=this['_vertexOutputNodes'];_0xca3321<_0x2ed4f4['length'];_0xca3321++){var _0x383ecc=_0x2ed4f4[_0xca3321];this['_gatherBlocks'](_0x383ecc,_0x598dc1);}for(var _0x18b6fa=[],_0x87b3ad=0x0,_0x54fdb2=this['_fragmentOutputNodes'];_0x87b3ad<_0x54fdb2['length'];_0x87b3ad++){_0x383ecc=_0x54fdb2[_0x87b3ad],this['_gatherBlocks'](_0x383ecc,_0x18b6fa);}for(var _0x1a3a48='var\x20nodeMaterial\x20=\x20new\x20BABYLON.NodeMaterial(\x22'+(this['name']||'node\x20material')+'\x22);\x0d\x0a',_0x2a2e77=0x0,_0x2dd9d0=_0x598dc1;_0x2a2e77<_0x2dd9d0['length'];_0x2a2e77++){(_0x55268e=_0x2dd9d0[_0x2a2e77])['isInput']&&-0x1===_0x21dd92['indexOf'](_0x55268e)&&(_0x1a3a48+=_0x55268e['_dumpCode'](_0x1fb3f4,_0x21dd92));}for(var _0x2afd09=0x0,_0x2e43b5=_0x18b6fa;_0x2afd09<_0x2e43b5['length'];_0x2afd09++){(_0x55268e=_0x2e43b5[_0x2afd09])['isInput']&&-0x1===_0x21dd92['indexOf'](_0x55268e)&&(_0x1a3a48+=_0x55268e['_dumpCode'](_0x1fb3f4,_0x21dd92));}_0x21dd92=[],_0x1a3a48+='\x0d\x0a//\x20Connections\x0d\x0a';for(var _0xbe3188=0x0,_0x61b469=this['_vertexOutputNodes'];_0xbe3188<_0x61b469['length'];_0xbe3188++){_0x1a3a48+=(_0x55268e=_0x61b469[_0xbe3188])['_dumpCodeForOutputConnections'](_0x21dd92);}for(var _0xfd59f5=0x0,_0xa133c6=this['_fragmentOutputNodes'];_0xfd59f5<_0xa133c6['length'];_0xfd59f5++){_0x1a3a48+=(_0x55268e=_0xa133c6[_0xfd59f5])['_dumpCodeForOutputConnections'](_0x21dd92);}_0x1a3a48+='\x0d\x0a//\x20Output\x20nodes\x0d\x0a';for(var _0x366107=0x0,_0x1df4d8=this['_vertexOutputNodes'];_0x366107<_0x1df4d8['length'];_0x366107++){_0x1a3a48+='nodeMaterial.addOutputNode('+(_0x55268e=_0x1df4d8[_0x366107])['_codeVariableName']+');\x0d\x0a';}for(var _0x55428c=0x0,_0x4e4bbe=this['_fragmentOutputNodes'];_0x55428c<_0x4e4bbe['length'];_0x55428c++){var _0x55268e;_0x1a3a48+='nodeMaterial.addOutputNode('+(_0x55268e=_0x4e4bbe[_0x55428c])['_codeVariableName']+');\x0d\x0a';}return _0x1a3a48+='nodeMaterial.build();\x0d\x0a';},_0x3f265b['prototype']['serialize']=function(_0x2baf6b){var _0x87bf9e=_0x2baf6b?{}:_0x495d06['a']['Serialize'](this);_0x87bf9e['editorData']=JSON['parse'](JSON['stringify'](this['editorData']));var _0x101859=[];if(_0x2baf6b)_0x101859=_0x2baf6b;else{_0x87bf9e['customType']='BABYLON.NodeMaterial',_0x87bf9e['outputNodes']=[];for(var _0x2015a7=0x0,_0x352ee7=this['_vertexOutputNodes'];_0x2015a7<_0x352ee7['length'];_0x2015a7++){var _0x30202c=_0x352ee7[_0x2015a7];this['_gatherBlocks'](_0x30202c,_0x101859),_0x87bf9e['outputNodes']['push'](_0x30202c['uniqueId']);}for(var _0x209915=0x0,_0x15b4ba=this['_fragmentOutputNodes'];_0x209915<_0x15b4ba['length'];_0x209915++){_0x30202c=_0x15b4ba[_0x209915],(this['_gatherBlocks'](_0x30202c,_0x101859),-0x1===_0x87bf9e['outputNodes']['indexOf'](_0x30202c['uniqueId'])&&_0x87bf9e['outputNodes']['push'](_0x30202c['uniqueId']));}}_0x87bf9e['blocks']=[];for(var _0x3d85d2=0x0,_0x37f36b=_0x101859;_0x3d85d2<_0x37f36b['length'];_0x3d85d2++){var _0x166e66=_0x37f36b[_0x3d85d2];_0x87bf9e['blocks']['push'](_0x166e66['serialize']());}if(!_0x2baf6b)for(var _0x29db28=0x0,_0x4436f6=this['attachedBlocks'];_0x29db28<_0x4436f6['length'];_0x29db28++){_0x166e66=_0x4436f6[_0x29db28],-0x1===_0x101859['indexOf'](_0x166e66)&&_0x87bf9e['blocks']['push'](_0x166e66['serialize']());}return _0x87bf9e;},_0x3f265b['prototype']['_restoreConnections']=function(_0x53a5ef,_0x37fdb1,_0x93e9f0){for(var _0x511544=0x0,_0x34ab89=_0x53a5ef['outputs'];_0x511544<_0x34ab89['length'];_0x511544++)for(var _0x5e426e=_0x34ab89[_0x511544],_0x2bd7b8=0x0,_0x19c343=_0x37fdb1['blocks'];_0x2bd7b8<_0x19c343['length'];_0x2bd7b8++){var _0x59e206=_0x19c343[_0x2bd7b8],_0x23ccb9=_0x93e9f0[_0x59e206['id']];if(_0x23ccb9)for(var _0x2d7681=0x0,_0xd123e2=_0x59e206['inputs'];_0x2d7681<_0xd123e2['length'];_0x2d7681++){var _0x3d882e=_0xd123e2[_0x2d7681];if(_0x93e9f0[_0x3d882e['targetBlockId']]!==_0x53a5ef||_0x3d882e['targetConnectionName']!==_0x5e426e['name']);else{var _0x2941e0=_0x23ccb9['getInputByName'](_0x3d882e['inputName']);if(!_0x2941e0||_0x2941e0['isConnected'])continue;_0x5e426e['connectTo'](_0x2941e0,!0x0),this['_restoreConnections'](_0x23ccb9,_0x37fdb1,_0x93e9f0);}}}},_0x3f265b['prototype']['loadFromSerialization']=function(_0x52701,_0x50e27c,_0x44dc1a){var _0x299931;void 0x0===_0x50e27c&&(_0x50e27c=''),void 0x0===_0x44dc1a&&(_0x44dc1a=!0x1),_0x44dc1a||this['clear']();for(var _0x29a3e4={},_0x1247cc=0x0,_0x39c9ee=_0x52701['blocks'];_0x1247cc<_0x39c9ee['length'];_0x1247cc++){var _0x2f9fe8=_0x39c9ee[_0x1247cc],_0x4af45f=_0x3cd573['a']['GetClass'](_0x2f9fe8['customType']);if(_0x4af45f)(_0x2b4320=new _0x4af45f())['_deserialize'](_0x2f9fe8,this['getScene'](),_0x50e27c),_0x29a3e4[_0x2f9fe8['id']]=_0x2b4320,this['attachedBlocks']['push'](_0x2b4320);}for(var _0x1f6514=0x0;_0x1f6514<_0x52701['blocks']['length'];_0x1f6514++){var _0x2b4320;(_0x2b4320=_0x29a3e4[_0x52701['blocks'][_0x1f6514]['id']])&&(_0x2b4320['inputs']['length']&&!_0x44dc1a||this['_restoreConnections'](_0x2b4320,_0x52701,_0x29a3e4));}if(_0x52701['outputNodes'])for(var _0x5b5058=0x0,_0x385765=_0x52701['outputNodes'];_0x5b5058<_0x385765['length'];_0x5b5058++){var _0x54d921=_0x385765[_0x5b5058];this['addOutputNode'](_0x29a3e4[_0x54d921]);}if(_0x52701['locations']||_0x52701['editorData']&&_0x52701['editorData']['locations']){for(var _0x1373b0=_0x52701['locations']||_0x52701['editorData']['locations'],_0x2c105c=0x0,_0x530bf8=_0x1373b0;_0x2c105c<_0x530bf8['length'];_0x2c105c++){var _0x53fa1a=_0x530bf8[_0x2c105c];_0x29a3e4[_0x53fa1a['blockId']]&&(_0x53fa1a['blockId']=_0x29a3e4[_0x53fa1a['blockId']]['uniqueId']);}_0x44dc1a&&this['editorData']&&this['editorData']['locations']&&_0x1373b0['concat'](this['editorData']['locations']),_0x52701['locations']?this['editorData']={'locations':_0x1373b0}:(this['editorData']=_0x52701['editorData'],this['editorData']['locations']=_0x1373b0);var _0x122c04=[];for(var _0x1dadd3 in _0x29a3e4)_0x122c04[_0x1dadd3]=_0x29a3e4[_0x1dadd3]['uniqueId'];this['editorData']['map']=_0x122c04;}this['comment']=_0x52701['comment'],_0x44dc1a||(this['_mode']=null!==(_0x299931=_0x52701['mode'])&&void 0x0!==_0x299931?_0x299931:_0x608fec['Material']);},_0x3f265b['prototype']['clone']=function(_0xbd520c){var _0x87bd58=this,_0x1d0c3d=this['serialize'](),_0x1d7d5c=_0x495d06['a']['Clone'](function(){return new _0x3f265b(_0xbd520c,_0x87bd58['getScene'](),_0x87bd58['options']);},this);return _0x1d7d5c['id']=_0xbd520c,_0x1d7d5c['name']=_0xbd520c,_0x1d7d5c['loadFromSerialization'](_0x1d0c3d),_0x1d7d5c['build'](),_0x1d7d5c;},_0x3f265b['Parse']=function(_0x455d8c,_0xd720d1,_0x17fdc9){void 0x0===_0x17fdc9&&(_0x17fdc9='');var _0x3be712=_0x495d06['a']['Parse'](function(){return new _0x3f265b(_0x455d8c['name'],_0xd720d1);},_0x455d8c,_0xd720d1,_0x17fdc9);return _0x3be712['loadFromSerialization'](_0x455d8c,_0x17fdc9),_0x3be712['build'](),_0x3be712;},_0x3f265b['ParseFromFileAsync']=function(_0x232f93,_0x1df1d9,_0x484a49){var _0x5e3dbd=new _0x3f265b(_0x232f93,_0x484a49);return new Promise(function(_0x52b4a2,_0x44cc02){return _0x5e3dbd['loadAsync'](_0x1df1d9)['then'](function(){_0x5e3dbd['build'](),_0x52b4a2(_0x5e3dbd);})['catch'](_0x44cc02);});},_0x3f265b['ParseFromSnippetAsync']=function(_0x12043a,_0x21d5f3,_0xed67f4,_0x79ff8){var _0x12f1f1=this;return void 0x0===_0xed67f4&&(_0xed67f4=''),'_BLANK'===_0x12043a?Promise['resolve'](this['CreateDefault']('blank',_0x21d5f3)):new Promise(function(_0x4efdf0,_0x412b43){var _0x5aea91=new _0x25cf22['a']();_0x5aea91['addEventListener']('readystatechange',function(){if(0x4==_0x5aea91['readyState']){if(0xc8==_0x5aea91['status']){var _0x5507aa=JSON['parse'](JSON['parse'](_0x5aea91['responseText'])['jsonPayload']),_0x3e3a31=JSON['parse'](_0x5507aa['nodeMaterial']);_0x79ff8||((_0x79ff8=_0x495d06['a']['Parse'](function(){return new _0x3f265b(_0x12043a,_0x21d5f3);},_0x3e3a31,_0x21d5f3,_0xed67f4))['uniqueId']=_0x21d5f3['getUniqueId']()),_0x79ff8['loadFromSerialization'](_0x3e3a31),_0x79ff8['snippetId']=_0x12043a;try{_0x79ff8['build'](),_0x4efdf0(_0x79ff8);}catch(_0x268d8d){_0x412b43(_0x268d8d);}}else _0x412b43('Unable\x20to\x20load\x20the\x20snippet\x20'+_0x12043a);}}),_0x5aea91['open']('GET',_0x12f1f1['SnippetUrl']+'/'+_0x12043a['replace'](/#/g,'/')),_0x5aea91['send']();});},_0x3f265b['CreateDefault']=function(_0x1e66e4,_0x485679){var _0xce666b=new _0x3f265b(_0x1e66e4,_0x485679);return _0xce666b['setToDefault'](),_0xce666b['build'](),_0xce666b;},_0x3f265b['_BuildIdGenerator']=0x0,_0x3f265b['EditorURL']='https://unpkg.com/babylonjs-node-editor@'+_0x300b38['a']['Version']+'/babylon.nodeEditor.js',_0x3f265b['SnippetUrl']='https://snippet.babylonjs.com',_0x3f265b['IgnoreTexturesAtLoadTime']=!0x1,Object(_0x18e13d['c'])([Object(_0x495d06['c'])('mode')],_0x3f265b['prototype'],'_mode',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])('comment')],_0x3f265b['prototype'],'comment',void 0x0),_0x3f265b;}(_0x1bb048['a']);_0x3cd573['a']['RegisteredTypes']['BABYLON.NodeMaterial']=_0x457d3e;var _0x13d2bc=function(_0x3a5489){function _0x1d9bb0(_0x303007){var _0xe41c4e=_0x3a5489['call'](this,_0x303007,_0x4e54a1['Vertex'])||this;return _0xe41c4e['registerInput']('matricesIndices',_0x3bb339['Vector4']),_0xe41c4e['registerInput']('matricesWeights',_0x3bb339['Vector4']),_0xe41c4e['registerInput']('matricesIndicesExtra',_0x3bb339['Vector4'],!0x0),_0xe41c4e['registerInput']('matricesWeightsExtra',_0x3bb339['Vector4'],!0x0),_0xe41c4e['registerInput']('world',_0x3bb339['Matrix']),_0xe41c4e['registerOutput']('output',_0x3bb339['Matrix']),_0xe41c4e;}return Object(_0x18e13d['d'])(_0x1d9bb0,_0x3a5489),_0x1d9bb0['prototype']['initialize']=function(_0x25c379){_0x25c379['_excludeVariableName']('boneSampler'),_0x25c379['_excludeVariableName']('boneTextureWidth'),_0x25c379['_excludeVariableName']('mBones'),_0x25c379['_excludeVariableName']('BonesPerMesh');},_0x1d9bb0['prototype']['getClassName']=function(){return'BonesBlock';},Object['defineProperty'](_0x1d9bb0['prototype'],'matricesIndices',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1d9bb0['prototype'],'matricesWeights',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1d9bb0['prototype'],'matricesIndicesExtra',{'get':function(){return this['_inputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1d9bb0['prototype'],'matricesWeightsExtra',{'get':function(){return this['_inputs'][0x3];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1d9bb0['prototype'],'world',{'get':function(){return this['_inputs'][0x4];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1d9bb0['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x1d9bb0['prototype']['autoConfigure']=function(_0x2631cc){if(!this['matricesIndices']['isConnected']){var _0x5e76b0=_0x2631cc['getInputBlockByPredicate'](function(_0x249659){return _0x249659['isAttribute']&&'matricesIndices'===_0x249659['name'];});_0x5e76b0||(_0x5e76b0=new _0x581182('matricesIndices'))['setAsAttribute']('matricesIndices'),_0x5e76b0['output']['connectTo'](this['matricesIndices']);}if(!this['matricesWeights']['isConnected']){var _0x66abac=_0x2631cc['getInputBlockByPredicate'](function(_0x208147){return _0x208147['isAttribute']&&'matricesWeights'===_0x208147['name'];});_0x66abac||(_0x66abac=new _0x581182('matricesWeights'))['setAsAttribute']('matricesWeights'),_0x66abac['output']['connectTo'](this['matricesWeights']);}if(!this['world']['isConnected']){var _0x56f2ca=_0x2631cc['getInputBlockByPredicate'](function(_0x4b8791){return _0x4b8791['systemValue']===_0x509c82['World'];});_0x56f2ca||(_0x56f2ca=new _0x581182('world'))['setAsSystemValue'](_0x509c82['World']),_0x56f2ca['output']['connectTo'](this['world']);}},_0x1d9bb0['prototype']['provideFallbacks']=function(_0x33cae2,_0x4d2b7d){_0x33cae2&&_0x33cae2['useBones']&&_0x33cae2['computeBonesUsingShaders']&&_0x33cae2['skeleton']&&_0x4d2b7d['addCPUSkinningFallback'](0x0,_0x33cae2);},_0x1d9bb0['prototype']['bind']=function(_0x520cf9,_0x481e14,_0x5e53f2){_0x464f31['a']['BindBonesParameters'](_0x5e53f2,_0x520cf9);},_0x1d9bb0['prototype']['prepareDefines']=function(_0xd7d685,_0x5ae690,_0x256f75){_0x256f75['_areAttributesDirty']&&_0x464f31['a']['PrepareDefinesForBones'](_0xd7d685,_0x256f75);},_0x1d9bb0['prototype']['_buildBlock']=function(_0x13e506){_0x3a5489['prototype']['_buildBlock']['call'](this,_0x13e506),_0x13e506['sharedData']['blocksWithFallbacks']['push'](this),_0x13e506['sharedData']['bindableBlocks']['push'](this),_0x13e506['sharedData']['blocksWithDefines']['push'](this),_0x13e506['uniforms']['push']('boneTextureWidth'),_0x13e506['uniforms']['push']('mBones'),_0x13e506['samplers']['push']('boneSampler');var _0x456e7e='//'+this['name'];_0x13e506['_emitFunctionFromInclude']('bonesDeclaration',_0x456e7e,{'removeAttributes':!0x0,'removeUniforms':!0x1,'removeVaryings':!0x0,'removeIfDef':!0x1});var _0x15c064=_0x13e506['_getFreeVariableName']('influence');_0x13e506['compilationString']+=_0x13e506['_emitCodeFromInclude']('bonesVertex',_0x456e7e,{'replaceStrings':[{'search':/finalWorld=finalWorld\*influence;/,'replace':''},{'search':/influence/gm,'replace':_0x15c064}]});var _0x193c19=this['_outputs'][0x0],_0xfeb112=this['world'];return _0x13e506['compilationString']+='#if\x20NUM_BONE_INFLUENCERS>0\x0d\x0a',_0x13e506['compilationString']+=this['_declareOutput'](_0x193c19,_0x13e506)+'\x20=\x20'+_0xfeb112['associatedVariableName']+'\x20*\x20'+_0x15c064+';\x0d\x0a',_0x13e506['compilationString']+='#else\x0d\x0a',_0x13e506['compilationString']+=this['_declareOutput'](_0x193c19,_0x13e506)+'\x20=\x20'+_0xfeb112['associatedVariableName']+';\x0d\x0a',_0x13e506['compilationString']+='#endif\x0d\x0a',this;},_0x1d9bb0;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.BonesBlock']=_0x13d2bc;var _0xc2c26b=function(_0x478004){function _0x5103cd(_0x13e643){var _0x46314e=_0x478004['call'](this,_0x13e643,_0x4e54a1['Vertex'])||this;return _0x46314e['registerInput']('world0',_0x3bb339['Vector4']),_0x46314e['registerInput']('world1',_0x3bb339['Vector4']),_0x46314e['registerInput']('world2',_0x3bb339['Vector4']),_0x46314e['registerInput']('world3',_0x3bb339['Vector4']),_0x46314e['registerInput']('world',_0x3bb339['Matrix'],!0x0),_0x46314e['registerOutput']('output',_0x3bb339['Matrix']),_0x46314e['registerOutput']('instanceID',_0x3bb339['Float']),_0x46314e;}return Object(_0x18e13d['d'])(_0x5103cd,_0x478004),_0x5103cd['prototype']['getClassName']=function(){return'InstancesBlock';},Object['defineProperty'](_0x5103cd['prototype'],'world0',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5103cd['prototype'],'world1',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5103cd['prototype'],'world2',{'get':function(){return this['_inputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5103cd['prototype'],'world3',{'get':function(){return this['_inputs'][0x3];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5103cd['prototype'],'world',{'get':function(){return this['_inputs'][0x4];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5103cd['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5103cd['prototype'],'instanceID',{'get':function(){return this['_outputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),_0x5103cd['prototype']['autoConfigure']=function(_0x272633){if(!this['world0']['connectedPoint']){var _0x312373=_0x272633['getInputBlockByPredicate'](function(_0x5d7f42){return _0x5d7f42['isAttribute']&&'world0'===_0x5d7f42['name'];});_0x312373||(_0x312373=new _0x581182('world0'))['setAsAttribute']('world0'),_0x312373['output']['connectTo'](this['world0']);}if(!this['world1']['connectedPoint']){var _0x19d5fb=_0x272633['getInputBlockByPredicate'](function(_0x1c7994){return _0x1c7994['isAttribute']&&'world1'===_0x1c7994['name'];});_0x19d5fb||(_0x19d5fb=new _0x581182('world1'))['setAsAttribute']('world1'),_0x19d5fb['output']['connectTo'](this['world1']);}if(!this['world2']['connectedPoint']){var _0x2669aa=_0x272633['getInputBlockByPredicate'](function(_0x18c43a){return _0x18c43a['isAttribute']&&'world2'===_0x18c43a['name'];});_0x2669aa||(_0x2669aa=new _0x581182('world2'))['setAsAttribute']('world2'),_0x2669aa['output']['connectTo'](this['world2']);}if(!this['world3']['connectedPoint']){var _0x360281=_0x272633['getInputBlockByPredicate'](function(_0x406f5b){return _0x406f5b['isAttribute']&&'world3'===_0x406f5b['name'];});_0x360281||(_0x360281=new _0x581182('world3'))['setAsAttribute']('world3'),_0x360281['output']['connectTo'](this['world3']);}if(!this['world']['connectedPoint']){var _0x53ebb8=_0x272633['getInputBlockByPredicate'](function(_0x5c6862){return _0x5c6862['isAttribute']&&'world'===_0x5c6862['name'];});_0x53ebb8||(_0x53ebb8=new _0x581182('world'))['setAsSystemValue'](_0x509c82['World']),_0x53ebb8['output']['connectTo'](this['world']);}this['world']['define']='!INSTANCES\x20||\x20THIN_INSTANCES';},_0x5103cd['prototype']['prepareDefines']=function(_0x44969c,_0x23d929,_0x50a1d6,_0x27134d,_0x4a337f){void 0x0===_0x27134d&&(_0x27134d=!0x1);var _0x4a71a1=!0x1;_0x50a1d6['INSTANCES']!==_0x27134d&&(_0x50a1d6['setValue']('INSTANCES',_0x27134d),_0x4a71a1=!0x0),_0x4a337f&&_0x50a1d6['THIN_INSTANCES']!==!!(null==_0x4a337f?void 0x0:_0x4a337f['getRenderingMesh']()['hasThinInstances'])&&(_0x50a1d6['setValue']('THIN_INSTANCES',!!(null==_0x4a337f?void 0x0:_0x4a337f['getRenderingMesh']()['hasThinInstances'])),_0x4a71a1=!0x0),_0x4a71a1&&_0x50a1d6['markAsUnprocessed']();},_0x5103cd['prototype']['_buildBlock']=function(_0x4def79){_0x478004['prototype']['_buildBlock']['call'](this,_0x4def79),_0x4def79['sharedData']['blocksWithDefines']['push'](this);var _0x49fac7=this['_outputs'][0x0],_0x2c7539=this['_outputs'][0x1],_0x58d23b=this['world0'],_0x4130ba=this['world1'],_0x360999=this['world2'],_0x4f9b57=this['world3'];return _0x4def79['compilationString']+='#ifdef\x20INSTANCES\x0d\x0a',_0x4def79['compilationString']+=this['_declareOutput'](_0x49fac7,_0x4def79)+'\x20=\x20mat4('+_0x58d23b['associatedVariableName']+',\x20'+_0x4130ba['associatedVariableName']+',\x20'+_0x360999['associatedVariableName']+',\x20'+_0x4f9b57['associatedVariableName']+');\x0d\x0a',_0x4def79['compilationString']+='#ifdef\x20THIN_INSTANCES\x0d\x0a',_0x4def79['compilationString']+=_0x49fac7['associatedVariableName']+'\x20=\x20'+this['world']['associatedVariableName']+'\x20*\x20'+_0x49fac7['associatedVariableName']+';\x0d\x0a',_0x4def79['compilationString']+='#endif\x0d\x0a',_0x4def79['compilationString']+=this['_declareOutput'](_0x2c7539,_0x4def79)+'\x20=\x20float(gl_InstanceID);\x0d\x0a',_0x4def79['compilationString']+='#else\x0d\x0a',_0x4def79['compilationString']+=this['_declareOutput'](_0x49fac7,_0x4def79)+'\x20=\x20'+this['world']['associatedVariableName']+';\x0d\x0a',_0x4def79['compilationString']+=this['_declareOutput'](_0x2c7539,_0x4def79)+'\x20=\x200.0;\x0d\x0a',_0x4def79['compilationString']+='#endif\x0d\x0a',this;},_0x5103cd;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.InstancesBlock']=_0xc2c26b;var _0x1d5af4=function(_0x401f22){function _0x21ca02(_0x55f983){var _0x2d3de6=_0x401f22['call'](this,_0x55f983,_0x4e54a1['Vertex'])||this;return _0x2d3de6['registerInput']('position',_0x3bb339['Vector3']),_0x2d3de6['registerInput']('normal',_0x3bb339['Vector3']),_0x2d3de6['registerInput']('tangent',_0x3bb339['Vector3']),_0x2d3de6['registerInput']('uv',_0x3bb339['Vector2']),_0x2d3de6['registerOutput']('positionOutput',_0x3bb339['Vector3']),_0x2d3de6['registerOutput']('normalOutput',_0x3bb339['Vector3']),_0x2d3de6['registerOutput']('tangentOutput',_0x3bb339['Vector3']),_0x2d3de6['registerOutput']('uvOutput',_0x3bb339['Vector2']),_0x2d3de6;}return Object(_0x18e13d['d'])(_0x21ca02,_0x401f22),_0x21ca02['prototype']['getClassName']=function(){return'MorphTargetsBlock';},Object['defineProperty'](_0x21ca02['prototype'],'position',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x21ca02['prototype'],'normal',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x21ca02['prototype'],'tangent',{'get':function(){return this['_inputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x21ca02['prototype'],'uv',{'get':function(){return this['_inputs'][0x3];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x21ca02['prototype'],'positionOutput',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x21ca02['prototype'],'normalOutput',{'get':function(){return this['_outputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x21ca02['prototype'],'tangentOutput',{'get':function(){return this['_outputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x21ca02['prototype'],'uvOutput',{'get':function(){return this['_outputs'][0x3];},'enumerable':!0x1,'configurable':!0x0}),_0x21ca02['prototype']['initialize']=function(_0x15f0ee){_0x15f0ee['_excludeVariableName']('morphTargetInfluences');},_0x21ca02['prototype']['autoConfigure']=function(_0x68f705){if(!this['position']['isConnected']){var _0xbbb02f=_0x68f705['getInputBlockByPredicate'](function(_0x29e6e2){return _0x29e6e2['isAttribute']&&'position'===_0x29e6e2['name'];});_0xbbb02f||(_0xbbb02f=new _0x581182('position'))['setAsAttribute'](),_0xbbb02f['output']['connectTo'](this['position']);}if(!this['normal']['isConnected']){var _0x340793=_0x68f705['getInputBlockByPredicate'](function(_0x47c736){return _0x47c736['isAttribute']&&'normal'===_0x47c736['name'];});_0x340793||(_0x340793=new _0x581182('normal'))['setAsAttribute']('normal'),_0x340793['output']['connectTo'](this['normal']);}if(!this['tangent']['isConnected']){var _0x430dc8=_0x68f705['getInputBlockByPredicate'](function(_0x1654bf){return _0x1654bf['isAttribute']&&'tangent'===_0x1654bf['name'];});_0x430dc8||(_0x430dc8=new _0x581182('tangent'))['setAsAttribute']('tangent'),_0x430dc8['output']['connectTo'](this['tangent']);}if(!this['uv']['isConnected']){var _0x2dc299=_0x68f705['getInputBlockByPredicate'](function(_0x3b9a84){return _0x3b9a84['isAttribute']&&'uv'===_0x3b9a84['name'];});_0x2dc299||(_0x2dc299=new _0x581182('uv'))['setAsAttribute']('uv'),_0x2dc299['output']['connectTo'](this['uv']);}},_0x21ca02['prototype']['prepareDefines']=function(_0x2d3641,_0x48a5cd,_0x37a730){_0x37a730['_areAttributesDirty']&&_0x464f31['a']['PrepareDefinesForMorphTargets'](_0x2d3641,_0x37a730);},_0x21ca02['prototype']['bind']=function(_0x55edc3,_0x22adbe,_0x12b2e5){_0x12b2e5&&_0x12b2e5['morphTargetManager']&&_0x12b2e5['morphTargetManager']['numInfluencers']>0x0&&_0x464f31['a']['BindMorphTargetParameters'](_0x12b2e5,_0x55edc3);},_0x21ca02['prototype']['replaceRepeatableContent']=function(_0x1fa9a9,_0x1fda8d,_0x2409a6,_0x4e54f6){for(var _0x152a92=this['position'],_0x21b13c=this['normal'],_0x13e28a=this['tangent'],_0x1538af=this['uv'],_0x228b39=this['positionOutput'],_0x2480d3=this['normalOutput'],_0x4a4eeb=this['tangentOutput'],_0x273951=this['uvOutput'],_0xebe6dd=_0x1fa9a9,_0x471b71=_0x4e54f6['NUM_MORPH_INFLUENCERS'],_0x4f9d15=_0x2409a6['morphTargetManager'],_0x169b56=_0x4f9d15&&_0x4f9d15['supportsNormals']&&_0x4e54f6['NORMAL'],_0x1f1c23=_0x4f9d15&&_0x4f9d15['supportsTangents']&&_0x4e54f6['TANGENT'],_0x27b61c=_0x4f9d15&&_0x4f9d15['supportsUVs']&&_0x4e54f6['UV1'],_0x37cb2b='',_0x2f17d5=0x0;_0x2f17d5<_0x471b71;_0x2f17d5++)_0x37cb2b+='#ifdef\x20MORPHTARGETS\x0d\x0a',_0x37cb2b+=_0x228b39['associatedVariableName']+'\x20+=\x20(position'+_0x2f17d5+'\x20-\x20'+_0x152a92['associatedVariableName']+')\x20*\x20morphTargetInfluences['+_0x2f17d5+'];\x0d\x0a',_0x169b56&&(_0x37cb2b+='#ifdef\x20MORPHTARGETS_NORMAL\x0d\x0a',_0x37cb2b+=_0x2480d3['associatedVariableName']+'\x20+=\x20(normal'+_0x2f17d5+'\x20-\x20'+_0x21b13c['associatedVariableName']+')\x20*\x20morphTargetInfluences['+_0x2f17d5+'];\x0d\x0a',_0x37cb2b+='#endif\x0d\x0a'),_0x1f1c23&&(_0x37cb2b+='#ifdef\x20MORPHTARGETS_TANGENT\x0d\x0a',_0x37cb2b+=_0x4a4eeb['associatedVariableName']+'.xyz\x20+=\x20(tangent'+_0x2f17d5+'\x20-\x20'+_0x13e28a['associatedVariableName']+'.xyz)\x20*\x20morphTargetInfluences['+_0x2f17d5+'];\x0d\x0a',_0x37cb2b+='#endif\x0d\x0a'),_0x27b61c&&(_0x37cb2b+='#ifdef\x20MORPHTARGETS_UV\x0d\x0a',_0x37cb2b+=_0x273951['associatedVariableName']+'.xy\x20+=\x20(uv_'+_0x2f17d5+'\x20-\x20'+_0x1538af['associatedVariableName']+'.xy)\x20*\x20morphTargetInfluences['+_0x2f17d5+'];\x0d\x0a',_0x37cb2b+='#endif\x0d\x0a'),_0x37cb2b+='#endif\x0d\x0a';if(_0xebe6dd['compilationString']=_0xebe6dd['compilationString']['replace'](this['_repeatableContentAnchor'],_0x37cb2b),_0x471b71>0x0){for(_0x2f17d5=0x0;_0x2f17d5<_0x471b71;_0x2f17d5++)_0xebe6dd['attributes']['push'](_0x212fbd['b']['PositionKind']+_0x2f17d5),_0x169b56&&_0xebe6dd['attributes']['push'](_0x212fbd['b']['NormalKind']+_0x2f17d5),_0x1f1c23&&_0xebe6dd['attributes']['push'](_0x212fbd['b']['TangentKind']+_0x2f17d5),_0x27b61c&&_0xebe6dd['attributes']['push'](_0x212fbd['b']['UVKind']+'_'+_0x2f17d5);}},_0x21ca02['prototype']['_buildBlock']=function(_0x27fa09){_0x401f22['prototype']['_buildBlock']['call'](this,_0x27fa09),_0x27fa09['sharedData']['blocksWithDefines']['push'](this),_0x27fa09['sharedData']['bindableBlocks']['push'](this),_0x27fa09['sharedData']['repeatableContentBlocks']['push'](this);var _0x247136=this['position'],_0x285d00=this['normal'],_0x47531=this['tangent'],_0x357607=this['uv'],_0x3c0975=this['positionOutput'],_0x271e36=this['normalOutput'],_0x5ab03d=this['tangentOutput'],_0x2404f2=this['uvOutput'],_0x4a314e='//'+this['name'];return _0x27fa09['uniforms']['push']('morphTargetInfluences'),_0x27fa09['_emitFunctionFromInclude']('morphTargetsVertexGlobalDeclaration',_0x4a314e),_0x27fa09['_emitFunctionFromInclude']('morphTargetsVertexDeclaration',_0x4a314e,{'repeatKey':'maxSimultaneousMorphTargets'}),_0x27fa09['compilationString']+=this['_declareOutput'](_0x3c0975,_0x27fa09)+'\x20=\x20'+_0x247136['associatedVariableName']+';\x0d\x0a',_0x27fa09['compilationString']+='#ifdef\x20NORMAL\x0d\x0a',_0x27fa09['compilationString']+=this['_declareOutput'](_0x271e36,_0x27fa09)+'\x20=\x20'+_0x285d00['associatedVariableName']+';\x0d\x0a',_0x27fa09['compilationString']+='#else\x0d\x0a',_0x27fa09['compilationString']+=this['_declareOutput'](_0x271e36,_0x27fa09)+'\x20=\x20vec3(0.,\x200.,\x200.);\x0d\x0a',_0x27fa09['compilationString']+='#endif\x0d\x0a',_0x27fa09['compilationString']+='#ifdef\x20TANGENT\x0d\x0a',_0x27fa09['compilationString']+=this['_declareOutput'](_0x5ab03d,_0x27fa09)+'\x20=\x20'+_0x47531['associatedVariableName']+';\x0d\x0a',_0x27fa09['compilationString']+='#else\x0d\x0a',_0x27fa09['compilationString']+=this['_declareOutput'](_0x5ab03d,_0x27fa09)+'\x20=\x20vec3(0.,\x200.,\x200.);\x0d\x0a',_0x27fa09['compilationString']+='#endif\x0d\x0a',_0x27fa09['compilationString']+='#ifdef\x20UV1\x0d\x0a',_0x27fa09['compilationString']+=this['_declareOutput'](_0x2404f2,_0x27fa09)+'\x20=\x20'+_0x357607['associatedVariableName']+';\x0d\x0a',_0x27fa09['compilationString']+='#else\x0d\x0a',_0x27fa09['compilationString']+=this['_declareOutput'](_0x2404f2,_0x27fa09)+'\x20=\x20vec2(0.,\x200.);\x0d\x0a',_0x27fa09['compilationString']+='#endif\x0d\x0a',this['_repeatableContentAnchor']=_0x27fa09['_repeatableContentAnchor'],_0x27fa09['compilationString']+=this['_repeatableContentAnchor'],this;},_0x21ca02;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.MorphTargetsBlock']=_0x1d5af4;var _0x52442e=function(_0x485de0){function _0x1a45dc(_0x1c0db7){var _0x893401=_0x485de0['call'](this,_0x1c0db7,_0x4e54a1['Vertex'])||this;return _0x893401['registerInput']('worldPosition',_0x3bb339['Vector4'],!0x1,_0x4e54a1['Vertex']),_0x893401['registerOutput']('direction',_0x3bb339['Vector3']),_0x893401['registerOutput']('color',_0x3bb339['Color3']),_0x893401['registerOutput']('intensity',_0x3bb339['Float']),_0x893401;}return Object(_0x18e13d['d'])(_0x1a45dc,_0x485de0),_0x1a45dc['prototype']['getClassName']=function(){return'LightInformationBlock';},Object['defineProperty'](_0x1a45dc['prototype'],'worldPosition',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1a45dc['prototype'],'direction',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1a45dc['prototype'],'color',{'get':function(){return this['_outputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1a45dc['prototype'],'intensity',{'get':function(){return this['_outputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),_0x1a45dc['prototype']['bind']=function(_0x139a0e,_0xa304fc,_0x5056e5){if(_0x5056e5){this['light']&&this['light']['isDisposed']&&(this['light']=null);var _0x230336=this['light'],_0x12e2ae=_0xa304fc['getScene']();if(!_0x230336&&_0x12e2ae['lights']['length']&&(_0x230336=_0x12e2ae['lights'][0x0]),!_0x230336||!_0x230336['isEnabled'])return _0x139a0e['setFloat3'](this['_lightDataUniformName'],0x0,0x0,0x0),void _0x139a0e['setFloat4'](this['_lightColorUniformName'],0x0,0x0,0x0,0x0);_0x230336['transferToNodeMaterialEffect'](_0x139a0e,this['_lightDataUniformName']),_0x139a0e['setColor4'](this['_lightColorUniformName'],_0x230336['diffuse'],_0x230336['intensity']);}},_0x1a45dc['prototype']['prepareDefines']=function(_0x5b7465,_0x5a184c,_0x1edb81){if(_0x1edb81['_areLightsDirty']){var _0x502442=this['light'];_0x1edb81['setValue'](this['_lightTypeDefineName'],!!(_0x502442&&_0x502442 instanceof _0x4c489f));}},_0x1a45dc['prototype']['_buildBlock']=function(_0x5bb579){_0x485de0['prototype']['_buildBlock']['call'](this,_0x5bb579),_0x5bb579['sharedData']['bindableBlocks']['push'](this),_0x5bb579['sharedData']['blocksWithDefines']['push'](this);var _0x8b3564=this['direction'],_0x21f117=this['color'],_0x5e49a2=this['intensity'];return this['_lightDataUniformName']=_0x5bb579['_getFreeVariableName']('lightData'),this['_lightColorUniformName']=_0x5bb579['_getFreeVariableName']('lightColor'),this['_lightTypeDefineName']=_0x5bb579['_getFreeDefineName']('LIGHTPOINTTYPE'),_0x5bb579['_emitUniformFromString'](this['_lightDataUniformName'],'vec3'),_0x5bb579['_emitUniformFromString'](this['_lightColorUniformName'],'vec4'),_0x5bb579['compilationString']+='#ifdef\x20'+this['_lightTypeDefineName']+'\x0d\x0a',_0x5bb579['compilationString']+=this['_declareOutput'](_0x8b3564,_0x5bb579)+'\x20=\x20normalize('+this['worldPosition']['associatedVariableName']+'.xyz\x20-\x20'+this['_lightDataUniformName']+');\x0d\x0a',_0x5bb579['compilationString']+='#else\x0d\x0a',_0x5bb579['compilationString']+=this['_declareOutput'](_0x8b3564,_0x5bb579)+'\x20=\x20'+this['_lightDataUniformName']+';\x0d\x0a',_0x5bb579['compilationString']+='#endif\x0d\x0a',_0x5bb579['compilationString']+=this['_declareOutput'](_0x21f117,_0x5bb579)+'\x20=\x20'+this['_lightColorUniformName']+'.rgb;\x0d\x0a',_0x5bb579['compilationString']+=this['_declareOutput'](_0x5e49a2,_0x5bb579)+'\x20=\x20'+this['_lightColorUniformName']+'.a;\x0d\x0a',this;},_0x1a45dc['prototype']['serialize']=function(){var _0x29c29b=_0x485de0['prototype']['serialize']['call'](this);return this['light']&&(_0x29c29b['lightId']=this['light']['id']),_0x29c29b;},_0x1a45dc['prototype']['_deserialize']=function(_0xc8c295,_0x2b875b,_0x32ad0a){_0x485de0['prototype']['_deserialize']['call'](this,_0xc8c295,_0x2b875b,_0x32ad0a),_0xc8c295['lightId']&&(this['light']=_0x2b875b['getLightByID'](_0xc8c295['lightId']));},_0x1a45dc;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.LightInformationBlock']=_0x52442e;var _0x2a97bd=function(_0x5e327c){function _0x158b8e(_0x3d4f70){var _0x163429=_0x5e327c['call'](this,_0x3d4f70,_0x4e54a1['Fragment'])||this;return _0x163429['registerInput']('color',_0x3bb339['Color4']),_0x163429['registerOutput']('output',_0x3bb339['Color4']),_0x163429['_inputs'][0x0]['acceptedConnectionPointTypes']['push'](_0x3bb339['Color3']),_0x163429;}return Object(_0x18e13d['d'])(_0x158b8e,_0x5e327c),_0x158b8e['prototype']['getClassName']=function(){return'ImageProcessingBlock';},Object['defineProperty'](_0x158b8e['prototype'],'color',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x158b8e['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x158b8e['prototype']['initialize']=function(_0x1877ee){_0x1877ee['_excludeVariableName']('exposureLinear'),_0x1877ee['_excludeVariableName']('contrast'),_0x1877ee['_excludeVariableName']('vInverseScreenSize'),_0x1877ee['_excludeVariableName']('vignetteSettings1'),_0x1877ee['_excludeVariableName']('vignetteSettings2'),_0x1877ee['_excludeVariableName']('vCameraColorCurveNegative'),_0x1877ee['_excludeVariableName']('vCameraColorCurveNeutral'),_0x1877ee['_excludeVariableName']('vCameraColorCurvePositive'),_0x1877ee['_excludeVariableName']('txColorTransform'),_0x1877ee['_excludeVariableName']('colorTransformSettings');},_0x158b8e['prototype']['isReady']=function(_0x11b151,_0x35a5f7,_0x3720bb){return!(_0x3720bb['_areImageProcessingDirty']&&_0x35a5f7['imageProcessingConfiguration']&&!_0x35a5f7['imageProcessingConfiguration']['isReady']());},_0x158b8e['prototype']['prepareDefines']=function(_0xf861c9,_0x295b98,_0x20672e){_0x20672e['_areImageProcessingDirty']&&_0x295b98['imageProcessingConfiguration']&&_0x295b98['imageProcessingConfiguration']['prepareDefines'](_0x20672e);},_0x158b8e['prototype']['bind']=function(_0x407d9e,_0x4ee40d,_0x278d9d){_0x278d9d&&_0x4ee40d['imageProcessingConfiguration']&&_0x4ee40d['imageProcessingConfiguration']['bind'](_0x407d9e);},_0x158b8e['prototype']['_buildBlock']=function(_0x1924b2){_0x5e327c['prototype']['_buildBlock']['call'](this,_0x1924b2),_0x1924b2['sharedData']['blocksWithDefines']['push'](this),_0x1924b2['sharedData']['blockingBlocks']['push'](this),_0x1924b2['sharedData']['bindableBlocks']['push'](this),_0x1924b2['uniforms']['push']('exposureLinear'),_0x1924b2['uniforms']['push']('contrast'),_0x1924b2['uniforms']['push']('vInverseScreenSize'),_0x1924b2['uniforms']['push']('vignetteSettings1'),_0x1924b2['uniforms']['push']('vignetteSettings2'),_0x1924b2['uniforms']['push']('vCameraColorCurveNegative'),_0x1924b2['uniforms']['push']('vCameraColorCurveNeutral'),_0x1924b2['uniforms']['push']('vCameraColorCurvePositive'),_0x1924b2['uniforms']['push']('txColorTransform'),_0x1924b2['uniforms']['push']('colorTransformSettings');var _0x828488=this['color'],_0x4fd205=this['_outputs'][0x0],_0x5a6815='//'+this['name'];return _0x1924b2['_emitFunctionFromInclude']('helperFunctions',_0x5a6815),_0x1924b2['_emitFunctionFromInclude']('imageProcessingDeclaration',_0x5a6815),_0x1924b2['_emitFunctionFromInclude']('imageProcessingFunctions',_0x5a6815),_0x828488['connectedPoint']['type']===_0x3bb339['Color4']||_0x828488['connectedPoint']['type']===_0x3bb339['Vector4']?_0x1924b2['compilationString']+=this['_declareOutput'](_0x4fd205,_0x1924b2)+'\x20=\x20'+_0x828488['associatedVariableName']+';\x0d\x0a':_0x1924b2['compilationString']+=this['_declareOutput'](_0x4fd205,_0x1924b2)+'\x20=\x20vec4('+_0x828488['associatedVariableName']+',\x201.0);\x0d\x0a',_0x1924b2['compilationString']+='#ifdef\x20IMAGEPROCESSINGPOSTPROCESS\x0d\x0a',_0x1924b2['compilationString']+=_0x4fd205['associatedVariableName']+'.rgb\x20=\x20toLinearSpace('+_0x828488['associatedVariableName']+'.rgb);\x0d\x0a',_0x1924b2['compilationString']+='#else\x0d\x0a',_0x1924b2['compilationString']+='#ifdef\x20IMAGEPROCESSING\x0d\x0a',_0x1924b2['compilationString']+=_0x4fd205['associatedVariableName']+'.rgb\x20=\x20toLinearSpace('+_0x828488['associatedVariableName']+'.rgb);\x0d\x0a',_0x1924b2['compilationString']+=_0x4fd205['associatedVariableName']+'\x20=\x20applyImageProcessing('+_0x4fd205['associatedVariableName']+');\x0d\x0a',_0x1924b2['compilationString']+='#endif\x0d\x0a',_0x1924b2['compilationString']+='#endif\x0d\x0a',this;},_0x158b8e;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.ImageProcessingBlock']=_0x2a97bd;var _0x2f04d9=function(_0x405d3d){function _0x4300a1(_0x178ca0){var _0x2eda46=_0x405d3d['call'](this,_0x178ca0,_0x4e54a1['Fragment'])||this;return _0x2eda46['_tangentSpaceParameterName']='',_0x2eda46['invertX']=!0x1,_0x2eda46['invertY']=!0x1,_0x2eda46['registerInput']('worldPosition',_0x3bb339['Vector4'],!0x1),_0x2eda46['registerInput']('worldNormal',_0x3bb339['Vector4'],!0x1),_0x2eda46['registerInput']('worldTangent',_0x3bb339['Vector4'],!0x0),_0x2eda46['registerInput']('uv',_0x3bb339['Vector2'],!0x1),_0x2eda46['registerInput']('normalMapColor',_0x3bb339['Color3'],!0x1),_0x2eda46['registerInput']('strength',_0x3bb339['Float'],!0x1),_0x2eda46['registerOutput']('output',_0x3bb339['Vector4']),_0x2eda46;}return Object(_0x18e13d['d'])(_0x4300a1,_0x405d3d),_0x4300a1['prototype']['getClassName']=function(){return'PerturbNormalBlock';},Object['defineProperty'](_0x4300a1['prototype'],'worldPosition',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4300a1['prototype'],'worldNormal',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4300a1['prototype'],'worldTangent',{'get':function(){return this['_inputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4300a1['prototype'],'uv',{'get':function(){return this['_inputs'][0x3];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4300a1['prototype'],'normalMapColor',{'get':function(){return this['_inputs'][0x4];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4300a1['prototype'],'strength',{'get':function(){return this['_inputs'][0x5];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4300a1['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x4300a1['prototype']['prepareDefines']=function(_0x5b4645,_0x334319,_0x131907){_0x131907['setValue']('BUMP',!0x0);},_0x4300a1['prototype']['bind']=function(_0x3cef3b,_0x254ac9,_0x473b75){_0x254ac9['getScene']()['_mirroredCameraPosition']?_0x3cef3b['setFloat2'](this['_tangentSpaceParameterName'],this['invertX']?0x1:-0x1,this['invertY']?0x1:-0x1):_0x3cef3b['setFloat2'](this['_tangentSpaceParameterName'],this['invertX']?-0x1:0x1,this['invertY']?-0x1:0x1);},_0x4300a1['prototype']['autoConfigure']=function(_0x1b0baa){if(!this['uv']['isConnected']){var _0x58a641=_0x1b0baa['getInputBlockByPredicate'](function(_0x344c0c){return _0x344c0c['isAttribute']&&'uv'===_0x344c0c['name'];});_0x58a641||(_0x58a641=new _0x581182('uv'))['setAsAttribute'](),_0x58a641['output']['connectTo'](this['uv']);}if(!this['strength']['isConnected']){var _0x3110c7=new _0x581182('strength');_0x3110c7['value']=0x1,_0x3110c7['output']['connectTo'](this['strength']);}},_0x4300a1['prototype']['_buildBlock']=function(_0x1a3ead){_0x405d3d['prototype']['_buildBlock']['call'](this,_0x1a3ead);var _0x12eab9='//'+this['name'],_0x505f61=this['uv'],_0x2ba86b=this['worldPosition'],_0x3de2aa=this['worldNormal'],_0x3d0b53=this['worldTangent'];_0x1a3ead['sharedData']['blocksWithDefines']['push'](this),_0x1a3ead['sharedData']['bindableBlocks']['push'](this),this['_tangentSpaceParameterName']=_0x1a3ead['_getFreeDefineName']('tangentSpaceParameter'),_0x1a3ead['_emitUniformFromString'](this['_tangentSpaceParameterName'],'vec2');var _0x57184d=this['strength']['isConnectedToInputBlock']&&this['strength']['connectInputBlock']['isConstant']?''+_0x1a3ead['_emitFloat'](0x1/this['strength']['connectInputBlock']['value']):'1.0\x20/\x20'+this['strength']['associatedVariableName'];_0x1a3ead['_emitExtension']('derivatives','#extension\x20GL_OES_standard_derivatives\x20:\x20enable');var _0x39a76e={'search':/defined\(TANGENT\)/g,'replace':_0x3d0b53['isConnected']?'defined(TANGENT)':'defined(IGNORE)'};return _0x3d0b53['isConnected']&&(_0x1a3ead['compilationString']+='vec3\x20tbnNormal\x20=\x20normalize('+_0x3de2aa['associatedVariableName']+'.xyz);\x0d\x0a',_0x1a3ead['compilationString']+='vec3\x20tbnTangent\x20=\x20normalize('+_0x3d0b53['associatedVariableName']+'.xyz);\x0d\x0a',_0x1a3ead['compilationString']+='vec3\x20tbnBitangent\x20=\x20cross(tbnNormal,\x20tbnTangent);\x0d\x0a',_0x1a3ead['compilationString']+='mat3\x20vTBN\x20=\x20mat3(tbnTangent,\x20tbnBitangent,\x20tbnNormal);\x0d\x0a'),_0x1a3ead['_emitFunctionFromInclude']('bumpFragmentMainFunctions',_0x12eab9,{'replaceStrings':[_0x39a76e]}),_0x1a3ead['_emitFunctionFromInclude']('bumpFragmentFunctions',_0x12eab9,{'replaceStrings':[{'search':/vBumpInfos.y/g,'replace':_0x57184d},{'search':/vTangentSpaceParams/g,'replace':this['_tangentSpaceParameterName']},{'search':/vPositionW/g,'replace':_0x2ba86b['associatedVariableName']+'.xyz'}]}),_0x1a3ead['compilationString']+=this['_declareOutput'](this['output'],_0x1a3ead)+'\x20=\x20vec4(0.);\x0d\x0a',_0x1a3ead['compilationString']+=_0x1a3ead['_emitCodeFromInclude']('bumpFragment',_0x12eab9,{'replaceStrings':[{'search':/perturbNormal\(TBN,vBumpUV\+uvOffset\)/g,'replace':'perturbNormal(TBN,\x20'+this['normalMapColor']['associatedVariableName']+')'},{'search':/vBumpInfos.y/g,'replace':_0x57184d},{'search':/vBumpUV/g,'replace':_0x505f61['associatedVariableName']},{'search':/vPositionW/g,'replace':_0x2ba86b['associatedVariableName']+'.xyz'},{'search':/normalW=/g,'replace':this['output']['associatedVariableName']+'.xyz\x20=\x20'},{'search':/mat3\(normalMatrix\)\*normalW/g,'replace':'mat3(normalMatrix)\x20*\x20'+this['output']['associatedVariableName']+'.xyz'},{'search':/normalW/g,'replace':_0x3de2aa['associatedVariableName']+'.xyz'},_0x39a76e]}),this;},_0x4300a1['prototype']['_dumpPropertiesCode']=function(){var _0x599fcd=this['_codeVariableName']+'.invertX\x20=\x20'+this['invertX']+';\x0d\x0a';return _0x599fcd+=this['_codeVariableName']+'.invertY\x20=\x20'+this['invertY']+';\x0d\x0a';},_0x4300a1['prototype']['serialize']=function(){var _0x46f429=_0x405d3d['prototype']['serialize']['call'](this);return _0x46f429['invertX']=this['invertX'],_0x46f429['invertY']=this['invertY'],_0x46f429;},_0x4300a1['prototype']['_deserialize']=function(_0x58f9b7,_0xfdcadb,_0x4091f9){_0x405d3d['prototype']['_deserialize']['call'](this,_0x58f9b7,_0xfdcadb,_0x4091f9),this['invertX']=_0x58f9b7['invertX'],this['invertY']=_0x58f9b7['invertY'];},Object(_0x18e13d['c'])([_0x148e9b('Invert\x20X\x20axis',_0x4bd31d['Boolean'],'PROPERTIES',{'notifiers':{'update':!0x1}})],_0x4300a1['prototype'],'invertX',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('Invert\x20Y\x20axis',_0x4bd31d['Boolean'],'PROPERTIES',{'notifiers':{'update':!0x1}})],_0x4300a1['prototype'],'invertY',void 0x0),_0x4300a1;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.PerturbNormalBlock']=_0x2f04d9;var _0xb71fa6=function(_0x575e7e){function _0x3d43b8(_0x3e6adc){var _0x213d9d=_0x575e7e['call'](this,_0x3e6adc,_0x4e54a1['Fragment'],!0x0)||this;return _0x213d9d['registerInput']('value',_0x3bb339['Float'],!0x0),_0x213d9d['registerInput']('cutoff',_0x3bb339['Float'],!0x0),_0x213d9d;}return Object(_0x18e13d['d'])(_0x3d43b8,_0x575e7e),_0x3d43b8['prototype']['getClassName']=function(){return'DiscardBlock';},Object['defineProperty'](_0x3d43b8['prototype'],'value',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3d43b8['prototype'],'cutoff',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),_0x3d43b8['prototype']['_buildBlock']=function(_0x47efad){if(_0x575e7e['prototype']['_buildBlock']['call'](this,_0x47efad),_0x47efad['sharedData']['hints']['needAlphaTesting']=!0x0,this['cutoff']['isConnected']&&this['value']['isConnected'])return _0x47efad['compilationString']+='if\x20('+this['value']['associatedVariableName']+'\x20<\x20'+this['cutoff']['associatedVariableName']+')\x20discard;\x0d\x0a',this;},_0x3d43b8;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.DiscardBlock']=_0xb71fa6;var _0x3cabc9=function(_0x32e4e9){function _0x3c20ba(_0xcb116d){var _0x215e18=_0x32e4e9['call'](this,_0xcb116d,_0x4e54a1['Fragment'])||this;return _0x215e18['registerOutput']('output',_0x3bb339['Float'],_0x4e54a1['Fragment']),_0x215e18;}return Object(_0x18e13d['d'])(_0x3c20ba,_0x32e4e9),_0x3c20ba['prototype']['getClassName']=function(){return'FrontFacingBlock';},Object['defineProperty'](_0x3c20ba['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x3c20ba['prototype']['_buildBlock']=function(_0x5b16fc){if(_0x32e4e9['prototype']['_buildBlock']['call'](this,_0x5b16fc),_0x5b16fc['target']===_0x4e54a1['Vertex'])throw'FrontFacingBlock\x20must\x20only\x20be\x20used\x20in\x20a\x20fragment\x20shader';var _0x5d39fe=this['_outputs'][0x0];return _0x5b16fc['compilationString']+=this['_declareOutput'](_0x5d39fe,_0x5b16fc)+'\x20=\x20gl_FrontFacing\x20?\x201.0\x20:\x200.0;\x0d\x0a',this;},_0x3c20ba;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.FrontFacingBlock']=_0x3cabc9;var _0x514d99=function(_0x5a33ad){function _0x390897(_0x18de01){var _0x2b6bbd=_0x5a33ad['call'](this,_0x18de01,_0x4e54a1['Fragment'])||this;return _0x2b6bbd['registerInput']('input',_0x3bb339['AutoDetect'],!0x1),_0x2b6bbd['registerOutput']('dx',_0x3bb339['BasedOnInput']),_0x2b6bbd['registerOutput']('dy',_0x3bb339['BasedOnInput']),_0x2b6bbd['_outputs'][0x0]['_typeConnectionSource']=_0x2b6bbd['_inputs'][0x0],_0x2b6bbd['_outputs'][0x1]['_typeConnectionSource']=_0x2b6bbd['_inputs'][0x0],_0x2b6bbd;}return Object(_0x18e13d['d'])(_0x390897,_0x5a33ad),_0x390897['prototype']['getClassName']=function(){return'DerivativeBlock';},Object['defineProperty'](_0x390897['prototype'],'input',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x390897['prototype'],'dx',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x390897['prototype'],'dy',{'get':function(){return this['_outputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),_0x390897['prototype']['_buildBlock']=function(_0x39a93f){_0x5a33ad['prototype']['_buildBlock']['call'](this,_0x39a93f);var _0x56ec0e=this['_outputs'][0x0],_0x5378f8=this['_outputs'][0x1];return _0x39a93f['_emitExtension']('derivatives','#extension\x20GL_OES_standard_derivatives\x20:\x20enable'),_0x56ec0e['hasEndpoints']&&(_0x39a93f['compilationString']+=this['_declareOutput'](_0x56ec0e,_0x39a93f)+'\x20=\x20dFdx('+this['input']['associatedVariableName']+');\x0d\x0a'),_0x5378f8['hasEndpoints']&&(_0x39a93f['compilationString']+=this['_declareOutput'](_0x5378f8,_0x39a93f)+'\x20=\x20dFdy('+this['input']['associatedVariableName']+');\x0d\x0a'),this;},_0x390897;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.DerivativeBlock']=_0x514d99;var _0x1e93a8=function(_0x27d7ad){function _0xd4416c(_0x235ad9){var _0x5816e9=_0x27d7ad['call'](this,_0x235ad9,_0x4e54a1['Fragment'])||this;return _0x5816e9['registerOutput']('xy',_0x3bb339['Vector2'],_0x4e54a1['Fragment']),_0x5816e9['registerOutput']('xyz',_0x3bb339['Vector3'],_0x4e54a1['Fragment']),_0x5816e9['registerOutput']('xyzw',_0x3bb339['Vector4'],_0x4e54a1['Fragment']),_0x5816e9['registerOutput']('x',_0x3bb339['Float'],_0x4e54a1['Fragment']),_0x5816e9['registerOutput']('y',_0x3bb339['Float'],_0x4e54a1['Fragment']),_0x5816e9['registerOutput']('z',_0x3bb339['Float'],_0x4e54a1['Fragment']),_0x5816e9['registerOutput']('w',_0x3bb339['Float'],_0x4e54a1['Fragment']),_0x5816e9;}return Object(_0x18e13d['d'])(_0xd4416c,_0x27d7ad),_0xd4416c['prototype']['getClassName']=function(){return'FragCoordBlock';},Object['defineProperty'](_0xd4416c['prototype'],'xy',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xd4416c['prototype'],'xyz',{'get':function(){return this['_outputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xd4416c['prototype'],'xyzw',{'get':function(){return this['_outputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xd4416c['prototype'],'x',{'get':function(){return this['_outputs'][0x3];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xd4416c['prototype'],'y',{'get':function(){return this['_outputs'][0x4];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xd4416c['prototype'],'z',{'get':function(){return this['_outputs'][0x5];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xd4416c['prototype'],'output',{'get':function(){return this['_outputs'][0x6];},'enumerable':!0x1,'configurable':!0x0}),_0xd4416c['prototype']['writeOutputs']=function(_0x14adba){for(var _0xfdf1cc='',_0x1a8b49=0x0,_0x1728b1=this['_outputs'];_0x1a8b49<_0x1728b1['length'];_0x1a8b49++){var _0x14a586=_0x1728b1[_0x1a8b49];_0x14a586['hasEndpoints']&&(_0xfdf1cc+=this['_declareOutput'](_0x14a586,_0x14adba)+'\x20=\x20gl_FragCoord.'+_0x14a586['name']+';\x0d\x0a');}return _0xfdf1cc;},_0xd4416c['prototype']['_buildBlock']=function(_0x5207a1){if(_0x27d7ad['prototype']['_buildBlock']['call'](this,_0x5207a1),_0x5207a1['target']===_0x4e54a1['Vertex'])throw'FragCoordBlock\x20must\x20only\x20be\x20used\x20in\x20a\x20fragment\x20shader';return _0x5207a1['compilationString']+=this['writeOutputs'](_0x5207a1),this;},_0xd4416c;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.FragCoordBlock']=_0x1e93a8;var _0x466e76=function(_0x2f22a5){function _0x2532a4(_0x1c96ac){var _0x26ae1e=_0x2f22a5['call'](this,_0x1c96ac,_0x4e54a1['Fragment'])||this;return _0x26ae1e['registerOutput']('xy',_0x3bb339['Vector2'],_0x4e54a1['Fragment']),_0x26ae1e['registerOutput']('x',_0x3bb339['Float'],_0x4e54a1['Fragment']),_0x26ae1e['registerOutput']('y',_0x3bb339['Float'],_0x4e54a1['Fragment']),_0x26ae1e;}return Object(_0x18e13d['d'])(_0x2532a4,_0x2f22a5),_0x2532a4['prototype']['getClassName']=function(){return'ScreenSizeBlock';},Object['defineProperty'](_0x2532a4['prototype'],'xy',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2532a4['prototype'],'x',{'get':function(){return this['_outputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2532a4['prototype'],'y',{'get':function(){return this['_outputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),_0x2532a4['prototype']['bind']=function(_0x5d0327,_0x2ce93e,_0x45be40){var _0x135b00=this['_scene']['getEngine']();_0x5d0327['setFloat2'](this['_varName'],_0x135b00['getRenderWidth'](),_0x135b00['getRenderWidth']());},_0x2532a4['prototype']['writeOutputs']=function(_0x146703,_0x90f9c9){for(var _0x4db56c='',_0x570933=0x0,_0x549b61=this['_outputs'];_0x570933<_0x549b61['length'];_0x570933++){var _0x2806cb=_0x549b61[_0x570933];_0x2806cb['hasEndpoints']&&(_0x4db56c+=this['_declareOutput'](_0x2806cb,_0x146703)+'\x20=\x20'+_0x90f9c9+'.'+_0x2806cb['name']+';\x0d\x0a');}return _0x4db56c;},_0x2532a4['prototype']['_buildBlock']=function(_0xfd2a06){if(_0x2f22a5['prototype']['_buildBlock']['call'](this,_0xfd2a06),this['_scene']=_0xfd2a06['sharedData']['scene'],_0xfd2a06['target']===_0x4e54a1['Vertex'])throw'ScreenSizeBlock\x20must\x20only\x20be\x20used\x20in\x20a\x20fragment\x20shader';return _0xfd2a06['sharedData']['bindableBlocks']['push'](this),this['_varName']=_0xfd2a06['_getFreeVariableName']('screenSize'),_0xfd2a06['_emitUniformFromString'](this['_varName'],'vec2'),_0xfd2a06['compilationString']+=this['writeOutputs'](_0xfd2a06,this['_varName']),this;},_0x2532a4;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.ScreenSizeBlock']=_0x466e76;var _0x13668a=function(_0x442fa5){function _0x3e5b3f(_0x154d48){var _0x3599ca=_0x442fa5['call'](this,_0x154d48,_0x4e54a1['VertexAndFragment'],!0x0)||this;return _0x3599ca['registerInput']('worldPosition',_0x3bb339['Vector4'],!0x1,_0x4e54a1['Vertex']),_0x3599ca['registerInput']('view',_0x3bb339['Matrix'],!0x1,_0x4e54a1['Vertex']),_0x3599ca['registerInput']('input',_0x3bb339['Color3'],!0x1,_0x4e54a1['Fragment']),_0x3599ca['registerInput']('fogColor',_0x3bb339['Color3'],!0x1,_0x4e54a1['Fragment']),_0x3599ca['registerOutput']('output',_0x3bb339['Color3'],_0x4e54a1['Fragment']),_0x3599ca['input']['acceptedConnectionPointTypes']['push'](_0x3bb339['Color4']),_0x3599ca['fogColor']['acceptedConnectionPointTypes']['push'](_0x3bb339['Color4']),_0x3599ca;}return Object(_0x18e13d['d'])(_0x3e5b3f,_0x442fa5),_0x3e5b3f['prototype']['getClassName']=function(){return'FogBlock';},Object['defineProperty'](_0x3e5b3f['prototype'],'worldPosition',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3e5b3f['prototype'],'view',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3e5b3f['prototype'],'input',{'get':function(){return this['_inputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3e5b3f['prototype'],'fogColor',{'get':function(){return this['_inputs'][0x3];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3e5b3f['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x3e5b3f['prototype']['autoConfigure']=function(_0x28ad9a){if(!this['view']['isConnected']){var _0xf0e6c9=_0x28ad9a['getInputBlockByPredicate'](function(_0x4b7a73){return _0x4b7a73['systemValue']===_0x509c82['View'];});_0xf0e6c9||(_0xf0e6c9=new _0x581182('view'))['setAsSystemValue'](_0x509c82['View']),_0xf0e6c9['output']['connectTo'](this['view']);}if(!this['fogColor']['isConnected']){var _0x3e6777=_0x28ad9a['getInputBlockByPredicate'](function(_0x55fb57){return _0x55fb57['systemValue']===_0x509c82['FogColor'];});_0x3e6777||(_0x3e6777=new _0x581182('fogColor',void 0x0,_0x3bb339['Color3']))['setAsSystemValue'](_0x509c82['FogColor']),_0x3e6777['output']['connectTo'](this['fogColor']);}},_0x3e5b3f['prototype']['prepareDefines']=function(_0x3c291f,_0x5af4e5,_0x390274){var _0x280f01=_0x3c291f['getScene']();_0x390274['setValue']('FOG',_0x5af4e5['fogEnabled']&&_0x464f31['a']['GetFogState'](_0x3c291f,_0x280f01));},_0x3e5b3f['prototype']['bind']=function(_0x2fab81,_0x3da5ab,_0x1434b5){if(_0x1434b5){var _0x1c1712=_0x1434b5['getScene']();_0x2fab81['setFloat4'](this['_fogParameters'],_0x1c1712['fogMode'],_0x1c1712['fogStart'],_0x1c1712['fogEnd'],_0x1c1712['fogDensity']);}},_0x3e5b3f['prototype']['_buildBlock']=function(_0x1df256){if(_0x442fa5['prototype']['_buildBlock']['call'](this,_0x1df256),_0x1df256['target']===_0x4e54a1['Fragment']){_0x1df256['sharedData']['blocksWithDefines']['push'](this),_0x1df256['sharedData']['bindableBlocks']['push'](this),_0x1df256['_emitFunctionFromInclude']('fogFragmentDeclaration','//'+this['name'],{'removeUniforms':!0x0,'removeVaryings':!0x0,'removeIfDef':!0x1,'replaceStrings':[{'search':/float CalcFogFactor\(\)/,'replace':'float\x20CalcFogFactor(vec3\x20vFogDistance,\x20vec4\x20vFogInfos)'}]});var _0x36314f=_0x1df256['_getFreeVariableName']('fog'),_0x3ef7f7=this['input'],_0x1a6a32=this['fogColor'];this['_fogParameters']=_0x1df256['_getFreeVariableName']('fogParameters');var _0x45263b=this['_outputs'][0x0];_0x1df256['_emitUniformFromString'](this['_fogParameters'],'vec4'),_0x1df256['compilationString']+='#ifdef\x20FOG\x0d\x0a',_0x1df256['compilationString']+='float\x20'+_0x36314f+'\x20=\x20CalcFogFactor('+this['_fogDistanceName']+',\x20'+this['_fogParameters']+');\x0d\x0a',_0x1df256['compilationString']+=this['_declareOutput'](_0x45263b,_0x1df256)+'\x20=\x20'+_0x36314f+'\x20*\x20'+_0x3ef7f7['associatedVariableName']+'.rgb\x20+\x20(1.0\x20-\x20'+_0x36314f+')\x20*\x20'+_0x1a6a32['associatedVariableName']+'.rgb;\x0d\x0a',_0x1df256['compilationString']+='#else\x0d\x0a'+this['_declareOutput'](_0x45263b,_0x1df256)+'\x20=\x20\x20'+_0x3ef7f7['associatedVariableName']+'.rgb;\x0d\x0a',_0x1df256['compilationString']+='#endif\x0d\x0a';}else{var _0x413098=this['worldPosition'],_0x3588ac=this['view'];this['_fogDistanceName']=_0x1df256['_getFreeVariableName']('vFogDistance'),_0x1df256['_emitVaryingFromString'](this['_fogDistanceName'],'vec3'),_0x1df256['compilationString']+=this['_fogDistanceName']+'\x20=\x20('+_0x3588ac['associatedVariableName']+'\x20*\x20'+_0x413098['associatedVariableName']+').xyz;\x0d\x0a';}return this;},_0x3e5b3f;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.FogBlock']=_0x13668a;var _0x531a4e=function(_0x17d40a){function _0x4c50f1(_0x52475f){var _0x36d3c6=_0x17d40a['call'](this,_0x52475f,_0x4e54a1['VertexAndFragment'])||this;return _0x36d3c6['_isUnique']=!0x0,_0x36d3c6['registerInput']('worldPosition',_0x3bb339['Vector4'],!0x1,_0x4e54a1['Vertex']),_0x36d3c6['registerInput']('worldNormal',_0x3bb339['Vector4'],!0x1,_0x4e54a1['Fragment']),_0x36d3c6['registerInput']('cameraPosition',_0x3bb339['Vector3'],!0x1,_0x4e54a1['Fragment']),_0x36d3c6['registerInput']('glossiness',_0x3bb339['Float'],!0x0,_0x4e54a1['Fragment']),_0x36d3c6['registerInput']('glossPower',_0x3bb339['Float'],!0x0,_0x4e54a1['Fragment']),_0x36d3c6['registerInput']('diffuseColor',_0x3bb339['Color3'],!0x0,_0x4e54a1['Fragment']),_0x36d3c6['registerInput']('specularColor',_0x3bb339['Color3'],!0x0,_0x4e54a1['Fragment']),_0x36d3c6['registerInput']('view',_0x3bb339['Matrix'],!0x0),_0x36d3c6['registerOutput']('diffuseOutput',_0x3bb339['Color3'],_0x4e54a1['Fragment']),_0x36d3c6['registerOutput']('specularOutput',_0x3bb339['Color3'],_0x4e54a1['Fragment']),_0x36d3c6['registerOutput']('shadow',_0x3bb339['Float'],_0x4e54a1['Fragment']),_0x36d3c6;}return Object(_0x18e13d['d'])(_0x4c50f1,_0x17d40a),_0x4c50f1['prototype']['getClassName']=function(){return'LightBlock';},Object['defineProperty'](_0x4c50f1['prototype'],'worldPosition',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4c50f1['prototype'],'worldNormal',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4c50f1['prototype'],'cameraPosition',{'get':function(){return this['_inputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4c50f1['prototype'],'glossiness',{'get':function(){return this['_inputs'][0x3];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4c50f1['prototype'],'glossPower',{'get':function(){return this['_inputs'][0x4];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4c50f1['prototype'],'diffuseColor',{'get':function(){return this['_inputs'][0x5];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4c50f1['prototype'],'specularColor',{'get':function(){return this['_inputs'][0x6];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4c50f1['prototype'],'view',{'get':function(){return this['_inputs'][0x7];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4c50f1['prototype'],'diffuseOutput',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4c50f1['prototype'],'specularOutput',{'get':function(){return this['_outputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4c50f1['prototype'],'shadow',{'get':function(){return this['_outputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),_0x4c50f1['prototype']['autoConfigure']=function(_0x28d250){if(!this['cameraPosition']['isConnected']){var _0x3a3414=_0x28d250['getInputBlockByPredicate'](function(_0x1d0e92){return _0x1d0e92['systemValue']===_0x509c82['CameraPosition'];});_0x3a3414||(_0x3a3414=new _0x581182('cameraPosition'))['setAsSystemValue'](_0x509c82['CameraPosition']),_0x3a3414['output']['connectTo'](this['cameraPosition']);}},_0x4c50f1['prototype']['prepareDefines']=function(_0x18f79e,_0x17eb3e,_0x3d42d7){if(_0x3d42d7['_areLightsDirty']){var _0x3ef0f8=_0x18f79e['getScene']();if(this['light']){var _0x39f69e={'needNormals':!0x1,'needRebuild':!0x1,'lightmapMode':!0x1,'shadowEnabled':!0x1,'specularEnabled':!0x1};_0x464f31['a']['PrepareDefinesForLight'](_0x3ef0f8,_0x18f79e,this['light'],this['_lightId'],_0x3d42d7,!0x0,_0x39f69e),_0x39f69e['needRebuild']&&_0x3d42d7['rebuild']();}else _0x464f31['a']['PrepareDefinesForLights'](_0x3ef0f8,_0x18f79e,_0x3d42d7,!0x0,_0x17eb3e['maxSimultaneousLights']);}},_0x4c50f1['prototype']['updateUniformsAndSamples']=function(_0x4e07c8,_0x5935af,_0x1f41da,_0x33d86f){for(var _0x4751e3=0x0;_0x4751e3<_0x5935af['maxSimultaneousLights']&&_0x1f41da['LIGHT'+_0x4751e3];_0x4751e3++){var _0xc0d36=_0x4e07c8['uniforms']['indexOf']('vLightData'+_0x4751e3)>=0x0;_0x464f31['a']['PrepareUniformsAndSamplersForLight'](_0x4751e3,_0x4e07c8['uniforms'],_0x4e07c8['samplers'],_0x1f41da['PROJECTEDLIGHTTEXTURE'+_0x4751e3],_0x33d86f,_0xc0d36);}},_0x4c50f1['prototype']['bind']=function(_0x1b46d5,_0x15496d,_0x33ecf1){if(_0x33ecf1){var _0x549c6e=_0x33ecf1['getScene']();this['light']?_0x464f31['a']['BindLight'](this['light'],this['_lightId'],_0x549c6e,_0x1b46d5,!0x0):_0x464f31['a']['BindLights'](_0x549c6e,_0x33ecf1,_0x1b46d5,!0x0,_0x15496d['maxSimultaneousLights']);}},_0x4c50f1['prototype']['_injectVertexCode']=function(_0x180fa3){var _0xb16a10=this['worldPosition'],_0xd7b6af='//'+this['name'];this['light']?(this['_lightId']=(void 0x0!==_0x180fa3['counters']['lightCounter']?_0x180fa3['counters']['lightCounter']:-0x1)+0x1,_0x180fa3['counters']['lightCounter']=this['_lightId'],_0x180fa3['_emitFunctionFromInclude'](_0x180fa3['supportUniformBuffers']?'lightUboDeclaration':'lightFragmentDeclaration',_0xd7b6af,{'replaceStrings':[{'search':/{X}/g,'replace':this['_lightId']['toString']()}]},this['_lightId']['toString']())):(_0x180fa3['_emitFunctionFromInclude'](_0x180fa3['supportUniformBuffers']?'lightUboDeclaration':'lightFragmentDeclaration',_0xd7b6af,{'repeatKey':'maxSimultaneousLights'}),this['_lightId']=0x0,_0x180fa3['sharedData']['dynamicUniformBlocks']['push'](this));var _0x4df2c7='v_'+_0xb16a10['associatedVariableName'];_0x180fa3['_emitVaryingFromString'](_0x4df2c7,'vec4')&&(_0x180fa3['compilationString']+=_0x4df2c7+'\x20=\x20'+_0xb16a10['associatedVariableName']+';\x0d\x0a'),this['light']?_0x180fa3['compilationString']+=_0x180fa3['_emitCodeFromInclude']('shadowsVertex',_0xd7b6af,{'replaceStrings':[{'search':/{X}/g,'replace':this['_lightId']['toString']()},{'search':/worldPos/g,'replace':_0xb16a10['associatedVariableName']}]}):(_0x180fa3['compilationString']+='vec4\x20worldPos\x20=\x20'+_0xb16a10['associatedVariableName']+';\x0d\x0a',this['view']['isConnected']&&(_0x180fa3['compilationString']+='mat4\x20view\x20=\x20'+this['view']['associatedVariableName']+';\x0d\x0a'),_0x180fa3['compilationString']+=_0x180fa3['_emitCodeFromInclude']('shadowsVertex',_0xd7b6af,{'repeatKey':'maxSimultaneousLights'}));},_0x4c50f1['prototype']['_buildBlock']=function(_0x23bc01){if(_0x17d40a['prototype']['_buildBlock']['call'](this,_0x23bc01),_0x23bc01['target']===_0x4e54a1['Fragment']){_0x23bc01['sharedData']['bindableBlocks']['push'](this),_0x23bc01['sharedData']['blocksWithDefines']['push'](this);var _0x28d03c='//'+this['name'],_0x42ede1=this['worldPosition'];_0x23bc01['_emitFunctionFromInclude']('helperFunctions',_0x28d03c),_0x23bc01['_emitFunctionFromInclude']('lightsFragmentFunctions',_0x28d03c,{'replaceStrings':[{'search':/vPositionW/g,'replace':'v_'+_0x42ede1['associatedVariableName']+'.xyz'}]}),_0x23bc01['_emitFunctionFromInclude']('shadowsFragmentFunctions',_0x28d03c,{'replaceStrings':[{'search':/vPositionW/g,'replace':'v_'+_0x42ede1['associatedVariableName']+'.xyz'}]}),this['light']?_0x23bc01['_emitFunctionFromInclude'](_0x23bc01['supportUniformBuffers']?'lightUboDeclaration':'lightFragmentDeclaration',_0x28d03c,{'replaceStrings':[{'search':/{X}/g,'replace':this['_lightId']['toString']()}]},this['_lightId']['toString']()):_0x23bc01['_emitFunctionFromInclude'](_0x23bc01['supportUniformBuffers']?'lightUboDeclaration':'lightFragmentDeclaration',_0x28d03c,{'repeatKey':'maxSimultaneousLights'}),0x0===this['_lightId']&&(_0x23bc01['_registerTempVariable']('viewDirectionW')&&(_0x23bc01['compilationString']+='vec3\x20viewDirectionW\x20=\x20normalize('+this['cameraPosition']['associatedVariableName']+'\x20-\x20v_'+_0x42ede1['associatedVariableName']+'.xyz);\x0d\x0a'),_0x23bc01['compilationString']+='lightingInfo\x20info;\x0d\x0a',_0x23bc01['compilationString']+='float\x20shadow\x20=\x201.;\x0d\x0a',_0x23bc01['compilationString']+='float\x20glossiness\x20=\x20'+(this['glossiness']['isConnected']?this['glossiness']['associatedVariableName']:'1.0')+'\x20*\x20'+(this['glossPower']['isConnected']?this['glossPower']['associatedVariableName']:'1024.0')+';\x0d\x0a',_0x23bc01['compilationString']+='vec3\x20diffuseBase\x20=\x20vec3(0.,\x200.,\x200.);\x0d\x0a',_0x23bc01['compilationString']+='vec3\x20specularBase\x20=\x20vec3(0.,\x200.,\x200.);\x0d\x0a',_0x23bc01['compilationString']+='vec3\x20normalW\x20=\x20'+this['worldNormal']['associatedVariableName']+'.xyz;\x0d\x0a'),this['light']?_0x23bc01['compilationString']+=_0x23bc01['_emitCodeFromInclude']('lightFragment',_0x28d03c,{'replaceStrings':[{'search':/{X}/g,'replace':this['_lightId']['toString']()}]}):_0x23bc01['compilationString']+=_0x23bc01['_emitCodeFromInclude']('lightFragment',_0x28d03c,{'repeatKey':'maxSimultaneousLights'});var _0x56a10c=this['diffuseOutput'],_0x45965e=this['specularOutput'];return _0x23bc01['compilationString']+=this['_declareOutput'](_0x56a10c,_0x23bc01)+'\x20=\x20diffuseBase'+(this['diffuseColor']['isConnected']?'\x20*\x20'+this['diffuseColor']['associatedVariableName']:'')+';\x0d\x0a',_0x45965e['hasEndpoints']&&(_0x23bc01['compilationString']+=this['_declareOutput'](_0x45965e,_0x23bc01)+'\x20=\x20specularBase'+(this['specularColor']['isConnected']?'\x20*\x20'+this['specularColor']['associatedVariableName']:'')+';\x0d\x0a'),this['shadow']['hasEndpoints']&&(_0x23bc01['compilationString']+=this['_declareOutput'](this['shadow'],_0x23bc01)+'\x20=\x20shadow;\x0d\x0a'),this;}this['_injectVertexCode'](_0x23bc01);},_0x4c50f1['prototype']['serialize']=function(){var _0x2d8670=_0x17d40a['prototype']['serialize']['call'](this);return this['light']&&(_0x2d8670['lightId']=this['light']['id']),_0x2d8670;},_0x4c50f1['prototype']['_deserialize']=function(_0x1a93bb,_0x184233,_0x48b893){_0x17d40a['prototype']['_deserialize']['call'](this,_0x1a93bb,_0x184233,_0x48b893),_0x1a93bb['lightId']&&(this['light']=_0x184233['getLightByID'](_0x1a93bb['lightId']));},_0x4c50f1;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.LightBlock']=_0x531a4e;var _0x3c5db7=function(_0x28d077){function _0x3b30cb(_0xb144a3,_0x264c5b){void 0x0===_0x264c5b&&(_0x264c5b=!0x1);var _0x3b7501=_0x28d077['call'](this,_0xb144a3,_0x264c5b?_0x4e54a1['Fragment']:_0x4e54a1['VertexAndFragment'])||this;return _0x3b7501['convertToGammaSpace']=!0x1,_0x3b7501['convertToLinearSpace']=!0x1,_0x3b7501['_fragmentOnly']=_0x264c5b,_0x3b7501['registerInput']('uv',_0x3bb339['Vector2'],!0x1,_0x4e54a1['VertexAndFragment']),_0x3b7501['registerOutput']('rgba',_0x3bb339['Color4'],_0x4e54a1['Neutral']),_0x3b7501['registerOutput']('rgb',_0x3bb339['Color3'],_0x4e54a1['Neutral']),_0x3b7501['registerOutput']('r',_0x3bb339['Float'],_0x4e54a1['Neutral']),_0x3b7501['registerOutput']('g',_0x3bb339['Float'],_0x4e54a1['Neutral']),_0x3b7501['registerOutput']('b',_0x3bb339['Float'],_0x4e54a1['Neutral']),_0x3b7501['registerOutput']('a',_0x3bb339['Float'],_0x4e54a1['Neutral']),_0x3b7501['_inputs'][0x0]['acceptedConnectionPointTypes']['push'](_0x3bb339['Vector3']),_0x3b7501['_inputs'][0x0]['acceptedConnectionPointTypes']['push'](_0x3bb339['Vector4']),_0x3b7501['_inputs'][0x0]['_prioritizeVertex']=!_0x264c5b,_0x3b7501;}return Object(_0x18e13d['d'])(_0x3b30cb,_0x28d077),_0x3b30cb['prototype']['getClassName']=function(){return'TextureBlock';},Object['defineProperty'](_0x3b30cb['prototype'],'uv',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3b30cb['prototype'],'rgba',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3b30cb['prototype'],'rgb',{'get':function(){return this['_outputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3b30cb['prototype'],'r',{'get':function(){return this['_outputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3b30cb['prototype'],'g',{'get':function(){return this['_outputs'][0x3];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3b30cb['prototype'],'b',{'get':function(){return this['_outputs'][0x4];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3b30cb['prototype'],'a',{'get':function(){return this['_outputs'][0x5];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3b30cb['prototype'],'target',{'get':function(){if(this['_fragmentOnly'])return _0x4e54a1['Fragment'];if(!this['uv']['isConnected'])return _0x4e54a1['VertexAndFragment'];if(this['uv']['sourceBlock']['isInput'])return _0x4e54a1['VertexAndFragment'];for(var _0x5c1d8f=this['uv']['connectedPoint'];_0x5c1d8f;){if(_0x5c1d8f['target']===_0x4e54a1['Fragment'])return _0x4e54a1['Fragment'];if(_0x5c1d8f['target']===_0x4e54a1['Vertex'])return _0x4e54a1['VertexAndFragment'];if(_0x5c1d8f['target']===_0x4e54a1['Neutral']||_0x5c1d8f['target']===_0x4e54a1['VertexAndFragment']){var _0x1e5116=_0x5c1d8f['ownerBlock'];_0x5c1d8f=null;for(var _0xda2290=0x0,_0x37d0cd=_0x1e5116['inputs'];_0xda2290<_0x37d0cd['length'];_0xda2290++){var _0x55440a=_0x37d0cd[_0xda2290];if(_0x55440a['connectedPoint']){_0x5c1d8f=_0x55440a['connectedPoint'];break;}}}}return _0x4e54a1['VertexAndFragment'];},'enumerable':!0x1,'configurable':!0x0}),_0x3b30cb['prototype']['autoConfigure']=function(_0x2b88f2){if(!this['uv']['isConnected']){if(_0x2b88f2['mode']===_0x608fec['PostProcess'])(_0x2a6411=_0x2b88f2['getBlockByPredicate'](function(_0x5e88e2){return'uv'===_0x5e88e2['name'];}))&&_0x2a6411['connectTo'](this);else{var _0x2a6411,_0x4598c0=_0x2b88f2['mode']===_0x608fec['Particle']?'particle_uv':'uv';(_0x2a6411=_0x2b88f2['getInputBlockByPredicate'](function(_0x1f0b99){return _0x1f0b99['isAttribute']&&_0x1f0b99['name']===_0x4598c0;}))||(_0x2a6411=new _0x581182('uv'))['setAsAttribute'](_0x4598c0),_0x2a6411['output']['connectTo'](this['uv']);}}},_0x3b30cb['prototype']['initializeDefines']=function(_0x1a4877,_0x2943bc,_0x27e07e,_0x5b2f04){void 0x0===_0x5b2f04&&(_0x5b2f04=!0x1),_0x27e07e['_areTexturesDirty']&&_0x27e07e['setValue'](this['_mainUVDefineName'],!0x1);},_0x3b30cb['prototype']['prepareDefines']=function(_0x15fdd2,_0x1e73c5,_0x2c7a31){if(_0x2c7a31['_areTexturesDirty']){if(!this['texture']||!this['texture']['getTextureMatrix'])return _0x2c7a31['setValue'](this['_defineName'],!0x1),void _0x2c7a31['setValue'](this['_mainUVDefineName'],!0x0);_0x2c7a31['setValue'](this['_linearDefineName'],this['convertToGammaSpace']),_0x2c7a31['setValue'](this['_gammaDefineName'],this['convertToLinearSpace']),this['_isMixed']&&(this['texture']['getTextureMatrix']()['isIdentityAs3x2']()?(_0x2c7a31['setValue'](this['_defineName'],!0x1),_0x2c7a31['setValue'](this['_mainUVDefineName'],!0x0)):_0x2c7a31['setValue'](this['_defineName'],!0x0));}},_0x3b30cb['prototype']['isReady']=function(){return!(this['texture']&&!this['texture']['isReadyOrNotBlocking']());},_0x3b30cb['prototype']['bind']=function(_0x41cace,_0x320ecf,_0x14e335){this['texture']&&(this['_isMixed']&&(_0x41cace['setFloat'](this['_textureInfoName'],this['texture']['level']),_0x41cace['setMatrix'](this['_textureTransformName'],this['texture']['getTextureMatrix']())),_0x41cace['setTexture'](this['_samplerName'],this['texture']));},Object['defineProperty'](_0x3b30cb['prototype'],'_isMixed',{'get':function(){return this['target']!==_0x4e54a1['Fragment'];},'enumerable':!0x1,'configurable':!0x0}),_0x3b30cb['prototype']['_injectVertexCode']=function(_0x1a6bcc){var _0x5c0782=this['uv'];(this['_defineName']=_0x1a6bcc['_getFreeDefineName']('UVTRANSFORM'),this['_mainUVDefineName']='VMAIN'+_0x5c0782['associatedVariableName']['toUpperCase'](),_0x5c0782['connectedPoint']['ownerBlock']['isInput'])&&(_0x5c0782['connectedPoint']['ownerBlock']['isAttribute']||_0x1a6bcc['_emitUniformFromString'](_0x5c0782['associatedVariableName'],'vec2'));if(this['_mainUVName']='vMain'+_0x5c0782['associatedVariableName'],this['_transformedUVName']=_0x1a6bcc['_getFreeVariableName']('transformedUV'),this['_textureTransformName']=_0x1a6bcc['_getFreeVariableName']('textureTransform'),this['_textureInfoName']=_0x1a6bcc['_getFreeVariableName']('textureInfoName'),_0x1a6bcc['_emitVaryingFromString'](this['_transformedUVName'],'vec2',this['_defineName']),_0x1a6bcc['_emitVaryingFromString'](this['_mainUVName'],'vec2',this['_mainUVDefineName']),_0x1a6bcc['_emitUniformFromString'](this['_textureTransformName'],'mat4',this['_defineName']),_0x1a6bcc['compilationString']+='#ifdef\x20'+this['_defineName']+'\x0d\x0a',_0x1a6bcc['compilationString']+=this['_transformedUVName']+'\x20=\x20vec2('+this['_textureTransformName']+'\x20*\x20vec4('+_0x5c0782['associatedVariableName']+'.xy,\x201.0,\x200.0));\x0d\x0a',_0x1a6bcc['compilationString']+='#elif\x20defined('+this['_mainUVDefineName']+')\x0d\x0a',_0x1a6bcc['compilationString']+=this['_mainUVName']+'\x20=\x20'+_0x5c0782['associatedVariableName']+'.xy;\x0d\x0a',_0x1a6bcc['compilationString']+='#endif\x0d\x0a',this['_outputs']['some'](function(_0x1d39fe){return _0x1d39fe['isConnectedInVertexShader'];})){this['_writeTextureRead'](_0x1a6bcc,!0x0);for(var _0x324fe8=0x0,_0x422c2b=this['_outputs'];_0x324fe8<_0x422c2b['length'];_0x324fe8++){var _0x3b903a=_0x422c2b[_0x324fe8];_0x3b903a['hasEndpoints']&&this['_writeOutput'](_0x1a6bcc,_0x3b903a,_0x3b903a['name'],!0x0);}}},_0x3b30cb['prototype']['_writeTextureRead']=function(_0x43b07b,_0x3cfda6){void 0x0===_0x3cfda6&&(_0x3cfda6=!0x1);var _0x2644f6=this['uv'];if(_0x3cfda6){if(_0x43b07b['target']===_0x4e54a1['Fragment'])return;_0x43b07b['compilationString']+='vec4\x20'+this['_tempTextureRead']+'\x20=\x20texture2D('+this['_samplerName']+',\x20'+_0x2644f6['associatedVariableName']+');\x0d\x0a';}else this['uv']['ownerBlock']['target']!==_0x4e54a1['Fragment']?(_0x43b07b['compilationString']+='#ifdef\x20'+this['_defineName']+'\x0d\x0a',_0x43b07b['compilationString']+='vec4\x20'+this['_tempTextureRead']+'\x20=\x20texture2D('+this['_samplerName']+',\x20'+this['_transformedUVName']+');\x0d\x0a',_0x43b07b['compilationString']+='#elif\x20defined('+this['_mainUVDefineName']+')\x0d\x0a',_0x43b07b['compilationString']+='vec4\x20'+this['_tempTextureRead']+'\x20=\x20texture2D('+this['_samplerName']+',\x20'+this['_mainUVName']+');\x0d\x0a',_0x43b07b['compilationString']+='#endif\x0d\x0a'):_0x43b07b['compilationString']+='vec4\x20'+this['_tempTextureRead']+'\x20=\x20texture2D('+this['_samplerName']+',\x20'+_0x2644f6['associatedVariableName']+');\x0d\x0a';},_0x3b30cb['prototype']['_writeOutput']=function(_0xcd0a06,_0x568676,_0x2f2748,_0x86f65f){if(void 0x0===_0x86f65f&&(_0x86f65f=!0x1),_0x86f65f){if(_0xcd0a06['target']===_0x4e54a1['Fragment'])return;_0xcd0a06['compilationString']+=this['_declareOutput'](_0x568676,_0xcd0a06)+'\x20=\x20'+this['_tempTextureRead']+'.'+_0x2f2748+';\x0d\x0a';}else{if(this['uv']['ownerBlock']['target']!==_0x4e54a1['Fragment']){var _0x53f961='\x20*\x20'+this['_textureInfoName'];_0xcd0a06['compilationString']+=this['_declareOutput'](_0x568676,_0xcd0a06)+'\x20=\x20'+this['_tempTextureRead']+'.'+_0x2f2748+_0x53f961+';\x0d\x0a','a'!==_0x2f2748&&(_0xcd0a06['compilationString']+='#ifdef\x20'+this['_linearDefineName']+'\x0d\x0a',_0xcd0a06['compilationString']+=_0x568676['associatedVariableName']+'\x20=\x20toGammaSpace('+_0x568676['associatedVariableName']+');\x0d\x0a',_0xcd0a06['compilationString']+='#endif\x0d\x0a',_0xcd0a06['compilationString']+='#ifdef\x20'+this['_gammaDefineName']+'\x0d\x0a',_0xcd0a06['compilationString']+=_0x568676['associatedVariableName']+'\x20=\x20toLinearSpace('+_0x568676['associatedVariableName']+');\x0d\x0a',_0xcd0a06['compilationString']+='#endif\x0d\x0a');}else _0xcd0a06['compilationString']+=this['_declareOutput'](_0x568676,_0xcd0a06)+'\x20=\x20'+this['_tempTextureRead']+'.'+_0x2f2748+';\x0d\x0a';}},_0x3b30cb['prototype']['_buildBlock']=function(_0x5104d3){if(_0x28d077['prototype']['_buildBlock']['call'](this,_0x5104d3),(_0x5104d3['target']===_0x4e54a1['Vertex']||this['_fragmentOnly'])&&(this['_tempTextureRead']=_0x5104d3['_getFreeVariableName']('tempTextureRead')),(!this['_isMixed']&&_0x5104d3['target']===_0x4e54a1['Fragment']||this['_isMixed']&&_0x5104d3['target']===_0x4e54a1['Vertex'])&&(this['_samplerName']=_0x5104d3['_getFreeVariableName'](this['name']+'Sampler'),_0x5104d3['_emit2DSampler'](this['_samplerName']),_0x5104d3['sharedData']['blockingBlocks']['push'](this),_0x5104d3['sharedData']['textureBlocks']['push'](this),_0x5104d3['sharedData']['blocksWithDefines']['push'](this),_0x5104d3['sharedData']['bindableBlocks']['push'](this)),_0x5104d3['target']===_0x4e54a1['Fragment']){if(this['_outputs']['some'](function(_0x3ecad1){return _0x3ecad1['isConnectedInFragmentShader'];})){this['_isMixed']&&_0x5104d3['_emit2DSampler'](this['_samplerName']),this['_linearDefineName']=_0x5104d3['_getFreeDefineName']('ISLINEAR'),this['_gammaDefineName']=_0x5104d3['_getFreeDefineName']('ISGAMMA');var _0x491c38='//'+this['name'];_0x5104d3['_emitFunctionFromInclude']('helperFunctions',_0x491c38),this['_isMixed']&&_0x5104d3['_emitUniformFromString'](this['_textureInfoName'],'float'),this['_writeTextureRead'](_0x5104d3);for(var _0x17ff88=0x0,_0x41e863=this['_outputs'];_0x17ff88<_0x41e863['length'];_0x17ff88++){var _0x2e1366=_0x41e863[_0x17ff88];_0x2e1366['hasEndpoints']&&this['_writeOutput'](_0x5104d3,_0x2e1366,_0x2e1366['name']);}return this;}}else this['_injectVertexCode'](_0x5104d3);},_0x3b30cb['prototype']['_dumpPropertiesCode']=function(){if(!this['texture'])return'';var _0x363925=this['_codeVariableName']+'.texture\x20=\x20new\x20BABYLON.Texture(\x22'+this['texture']['name']+'\x22,\x20null);\x0d\x0a';return _0x363925+=this['_codeVariableName']+'.texture.wrapU\x20=\x20'+this['texture']['wrapU']+';\x0d\x0a',_0x363925+=this['_codeVariableName']+'.texture.wrapV\x20=\x20'+this['texture']['wrapV']+';\x0d\x0a',_0x363925+=this['_codeVariableName']+'.texture.uAng\x20=\x20'+this['texture']['uAng']+';\x0d\x0a',_0x363925+=this['_codeVariableName']+'.texture.vAng\x20=\x20'+this['texture']['vAng']+';\x0d\x0a',_0x363925+=this['_codeVariableName']+'.texture.wAng\x20=\x20'+this['texture']['wAng']+';\x0d\x0a',_0x363925+=this['_codeVariableName']+'.texture.uOffset\x20=\x20'+this['texture']['uOffset']+';\x0d\x0a',_0x363925+=this['_codeVariableName']+'.texture.vOffset\x20=\x20'+this['texture']['vOffset']+';\x0d\x0a',_0x363925+=this['_codeVariableName']+'.texture.uScale\x20=\x20'+this['texture']['uScale']+';\x0d\x0a',_0x363925+=this['_codeVariableName']+'.texture.vScale\x20=\x20'+this['texture']['vScale']+';\x0d\x0a',_0x363925+=this['_codeVariableName']+'.convertToGammaSpace\x20=\x20'+this['convertToGammaSpace']+';\x0d\x0a',_0x363925+=this['_codeVariableName']+'.convertToLinearSpace\x20=\x20'+this['convertToLinearSpace']+';\x0d\x0a';},_0x3b30cb['prototype']['serialize']=function(){var _0x3a657d=_0x28d077['prototype']['serialize']['call'](this);return _0x3a657d['convertToGammaSpace']=this['convertToGammaSpace'],_0x3a657d['convertToLinearSpace']=this['convertToLinearSpace'],_0x3a657d['fragmentOnly']=this['_fragmentOnly'],this['texture']&&!this['texture']['isRenderTarget']&&(_0x3a657d['texture']=this['texture']['serialize']()),_0x3a657d;},_0x3b30cb['prototype']['_deserialize']=function(_0x2dbcdd,_0xbbb85f,_0x1b2468){_0x28d077['prototype']['_deserialize']['call'](this,_0x2dbcdd,_0xbbb85f,_0x1b2468),this['convertToGammaSpace']=_0x2dbcdd['convertToGammaSpace'],this['convertToLinearSpace']=!!_0x2dbcdd['convertToLinearSpace'],this['_fragmentOnly']=!!_0x2dbcdd['fragmentOnly'],_0x2dbcdd['texture']&&!_0x457d3e['IgnoreTexturesAtLoadTime']&&(_0x1b2468=0x0===_0x2dbcdd['texture']['url']['indexOf']('data:')?'':_0x1b2468,this['texture']=_0xaf3c80['a']['Parse'](_0x2dbcdd['texture'],_0xbbb85f,_0x1b2468));},_0x3b30cb;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.TextureBlock']=_0x3c5db7;var _0x5823d9=function(_0x496b81){function _0x2d6cfc(_0x3430c6){return _0x496b81['call'](this,_0x3430c6,_0x4e54a1['VertexAndFragment'])||this;}return Object(_0x18e13d['d'])(_0x2d6cfc,_0x496b81),_0x2d6cfc['prototype']['getClassName']=function(){return'ReflectionTextureBaseBlock';},_0x2d6cfc['prototype']['_getTexture']=function(){return this['texture'];},_0x2d6cfc['prototype']['autoConfigure']=function(_0x192bde){if(!this['position']['isConnected']){var _0x163305=_0x192bde['getInputBlockByPredicate'](function(_0x328082){return _0x328082['isAttribute']&&'position'===_0x328082['name'];});_0x163305||(_0x163305=new _0x581182('position'))['setAsAttribute'](),_0x163305['output']['connectTo'](this['position']);}if(!this['world']['isConnected']){var _0x30bc2c=_0x192bde['getInputBlockByPredicate'](function(_0x2fc61d){return _0x2fc61d['systemValue']===_0x509c82['World'];});_0x30bc2c||(_0x30bc2c=new _0x581182('world'))['setAsSystemValue'](_0x509c82['World']),_0x30bc2c['output']['connectTo'](this['world']);}if(this['view']&&!this['view']['isConnected']){var _0x1ebe5e=_0x192bde['getInputBlockByPredicate'](function(_0x10e39a){return _0x10e39a['systemValue']===_0x509c82['View'];});_0x1ebe5e||(_0x1ebe5e=new _0x581182('view'))['setAsSystemValue'](_0x509c82['View']),_0x1ebe5e['output']['connectTo'](this['view']);}},_0x2d6cfc['prototype']['prepareDefines']=function(_0xc7b411,_0x487ecf,_0x5dd849){if(_0x5dd849['_areTexturesDirty']){var _0x2d0370=this['_getTexture']();_0x2d0370&&_0x2d0370['getTextureMatrix']&&(_0x5dd849['setValue'](this['_define3DName'],_0x2d0370['isCube'],!0x0),_0x5dd849['setValue'](this['_defineLocalCubicName'],!!_0x2d0370['boundingBoxSize'],!0x0),_0x5dd849['setValue'](this['_defineExplicitName'],_0x2d0370['coordinatesMode']===_0x2103ba['a']['TEXTURE_EXPLICIT_MODE'],!0x0),_0x5dd849['setValue'](this['_defineSkyboxName'],_0x2d0370['coordinatesMode']===_0x2103ba['a']['TEXTURE_SKYBOX_MODE'],!0x0),_0x5dd849['setValue'](this['_defineCubicName'],_0x2d0370['coordinatesMode']===_0x2103ba['a']['TEXTURE_CUBIC_MODE']||_0x2d0370['coordinatesMode']===_0x2103ba['a']['TEXTURE_INVCUBIC_MODE'],!0x0),_0x5dd849['setValue']('INVERTCUBICMAP',_0x2d0370['coordinatesMode']===_0x2103ba['a']['TEXTURE_INVCUBIC_MODE'],!0x0),_0x5dd849['setValue'](this['_defineSphericalName'],_0x2d0370['coordinatesMode']===_0x2103ba['a']['TEXTURE_SPHERICAL_MODE'],!0x0),_0x5dd849['setValue'](this['_definePlanarName'],_0x2d0370['coordinatesMode']===_0x2103ba['a']['TEXTURE_PLANAR_MODE'],!0x0),_0x5dd849['setValue'](this['_defineProjectionName'],_0x2d0370['coordinatesMode']===_0x2103ba['a']['TEXTURE_PROJECTION_MODE'],!0x0),_0x5dd849['setValue'](this['_defineEquirectangularName'],_0x2d0370['coordinatesMode']===_0x2103ba['a']['TEXTURE_EQUIRECTANGULAR_MODE'],!0x0),_0x5dd849['setValue'](this['_defineEquirectangularFixedName'],_0x2d0370['coordinatesMode']===_0x2103ba['a']['TEXTURE_FIXED_EQUIRECTANGULAR_MODE'],!0x0),_0x5dd849['setValue'](this['_defineMirroredEquirectangularFixedName'],_0x2d0370['coordinatesMode']===_0x2103ba['a']['TEXTURE_FIXED_EQUIRECTANGULAR_MIRRORED_MODE'],!0x0));}},_0x2d6cfc['prototype']['isReady']=function(){var _0x1436dd=this['_getTexture']();return!(_0x1436dd&&!_0x1436dd['isReadyOrNotBlocking']());},_0x2d6cfc['prototype']['bind']=function(_0x2652d5,_0x3a601c,_0x498b23){var _0x49ad63=this['_getTexture']();_0x498b23&&_0x49ad63&&(_0x2652d5['setMatrix'](this['_reflectionMatrixName'],_0x49ad63['getReflectionTextureMatrix']()),_0x49ad63['isCube']?_0x2652d5['setTexture'](this['_cubeSamplerName'],_0x49ad63):_0x2652d5['setTexture'](this['_2DSamplerName'],_0x49ad63));},_0x2d6cfc['prototype']['handleVertexSide']=function(_0x35685b){this['_define3DName']=_0x35685b['_getFreeDefineName']('REFLECTIONMAP_3D'),this['_defineCubicName']=_0x35685b['_getFreeDefineName']('REFLECTIONMAP_CUBIC'),this['_defineSphericalName']=_0x35685b['_getFreeDefineName']('REFLECTIONMAP_SPHERICAL'),this['_definePlanarName']=_0x35685b['_getFreeDefineName']('REFLECTIONMAP_PLANAR'),this['_defineProjectionName']=_0x35685b['_getFreeDefineName']('REFLECTIONMAP_PROJECTION'),this['_defineExplicitName']=_0x35685b['_getFreeDefineName']('REFLECTIONMAP_EXPLICIT'),this['_defineEquirectangularName']=_0x35685b['_getFreeDefineName']('REFLECTIONMAP_EQUIRECTANGULAR'),this['_defineLocalCubicName']=_0x35685b['_getFreeDefineName']('USE_LOCAL_REFLECTIONMAP_CUBIC'),this['_defineMirroredEquirectangularFixedName']=_0x35685b['_getFreeDefineName']('REFLECTIONMAP_MIRROREDEQUIRECTANGULAR_FIXED'),this['_defineEquirectangularFixedName']=_0x35685b['_getFreeDefineName']('REFLECTIONMAP_EQUIRECTANGULAR_FIXED'),this['_defineSkyboxName']=_0x35685b['_getFreeDefineName']('REFLECTIONMAP_SKYBOX'),this['_defineOppositeZ']=_0x35685b['_getFreeDefineName']('REFLECTIONMAP_OPPOSITEZ'),this['_reflectionMatrixName']=_0x35685b['_getFreeVariableName']('reflectionMatrix'),_0x35685b['_emitUniformFromString'](this['_reflectionMatrixName'],'mat4');var _0x18ade0='',_0x495edb='v_'+this['worldPosition']['associatedVariableName'];return _0x35685b['_emitVaryingFromString'](_0x495edb,'vec4')&&(_0x18ade0+=_0x495edb+'\x20=\x20'+this['worldPosition']['associatedVariableName']+';\x0d\x0a'),this['_positionUVWName']=_0x35685b['_getFreeVariableName']('positionUVW'),this['_directionWName']=_0x35685b['_getFreeVariableName']('directionW'),_0x35685b['_emitVaryingFromString'](this['_positionUVWName'],'vec3',this['_defineSkyboxName'])&&(_0x18ade0+='#ifdef\x20'+this['_defineSkyboxName']+'\x0d\x0a',_0x18ade0+=this['_positionUVWName']+'\x20=\x20'+this['position']['associatedVariableName']+'.xyz;\x0d\x0a',_0x18ade0+='#endif\x0d\x0a'),_0x35685b['_emitVaryingFromString'](this['_directionWName'],'vec3','defined('+this['_defineEquirectangularFixedName']+')\x20||\x20defined('+this['_defineMirroredEquirectangularFixedName']+')')&&(_0x18ade0+='#if\x20defined('+this['_defineEquirectangularFixedName']+')\x20||\x20defined('+this['_defineMirroredEquirectangularFixedName']+')\x0d\x0a',_0x18ade0+=this['_directionWName']+'\x20=\x20normalize(vec3('+this['world']['associatedVariableName']+'\x20*\x20vec4('+this['position']['associatedVariableName']+'.xyz,\x200.0)));\x0d\x0a',_0x18ade0+='#endif\x0d\x0a'),_0x18ade0;},_0x2d6cfc['prototype']['handleFragmentSideInits']=function(_0x336ca2){_0x336ca2['sharedData']['blockingBlocks']['push'](this),_0x336ca2['sharedData']['textureBlocks']['push'](this),this['_cubeSamplerName']=_0x336ca2['_getFreeVariableName'](this['name']+'CubeSampler'),_0x336ca2['samplers']['push'](this['_cubeSamplerName']),this['_2DSamplerName']=_0x336ca2['_getFreeVariableName'](this['name']+'2DSampler'),_0x336ca2['samplers']['push'](this['_2DSamplerName']),_0x336ca2['_samplerDeclaration']+='#ifdef\x20'+this['_define3DName']+'\x0d\x0a',_0x336ca2['_samplerDeclaration']+='uniform\x20samplerCube\x20'+this['_cubeSamplerName']+';\x0d\x0a',_0x336ca2['_samplerDeclaration']+='#else\x0d\x0a',_0x336ca2['_samplerDeclaration']+='uniform\x20sampler2D\x20'+this['_2DSamplerName']+';\x0d\x0a',_0x336ca2['_samplerDeclaration']+='#endif\x0d\x0a',_0x336ca2['sharedData']['blocksWithDefines']['push'](this),_0x336ca2['sharedData']['bindableBlocks']['push'](this);var _0x3a204f='//'+this['name'];_0x336ca2['_emitFunction']('ReciprocalPI','#define\x20RECIPROCAL_PI2\x200.15915494',''),_0x336ca2['_emitFunctionFromInclude']('reflectionFunction',_0x3a204f,{'replaceStrings':[{'search':/vec3 computeReflectionCoords/g,'replace':'void\x20DUMMYFUNC'}]}),this['_reflectionColorName']=_0x336ca2['_getFreeVariableName']('reflectionColor'),this['_reflectionVectorName']=_0x336ca2['_getFreeVariableName']('reflectionUVW'),this['_reflectionCoordsName']=_0x336ca2['_getFreeVariableName']('reflectionCoords');},_0x2d6cfc['prototype']['handleFragmentSideCodeReflectionCoords']=function(_0x20dc55,_0x4f367b,_0x3cecad){void 0x0===_0x3cecad&&(_0x3cecad=!0x1),_0x4f367b||(_0x4f367b='v_'+this['worldPosition']['associatedVariableName']);var _0x2941fe=this['_reflectionMatrixName'],_0x1f1687='normalize('+this['_directionWName']+')',_0x14c642=''+this['_positionUVWName'],_0x31558e=''+this['cameraPosition']['associatedVariableName'],_0x2bdc7b=''+this['view']['associatedVariableName'];_0x20dc55+='.xyz';var _0x19cb45='\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20'+this['_defineMirroredEquirectangularFixedName']+'\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec3\x20'+this['_reflectionVectorName']+'\x20=\x20computeMirroredFixedEquirectangularCoords('+_0x4f367b+',\x20'+_0x20dc55+',\x20'+_0x1f1687+');\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20'+this['_defineEquirectangularFixedName']+'\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec3\x20'+this['_reflectionVectorName']+'\x20=\x20computeFixedEquirectangularCoords('+_0x4f367b+',\x20'+_0x20dc55+',\x20'+_0x1f1687+');\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20'+this['_defineEquirectangularName']+'\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec3\x20'+this['_reflectionVectorName']+'\x20=\x20computeEquirectangularCoords('+_0x4f367b+',\x20'+_0x20dc55+',\x20'+_0x31558e+'.xyz,\x20'+_0x2941fe+');\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20'+this['_defineSphericalName']+'\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec3\x20'+this['_reflectionVectorName']+'\x20=\x20computeSphericalCoords('+_0x4f367b+',\x20'+_0x20dc55+',\x20'+_0x2bdc7b+',\x20'+_0x2941fe+');\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20'+this['_definePlanarName']+'\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec3\x20'+this['_reflectionVectorName']+'\x20=\x20computePlanarCoords('+_0x4f367b+',\x20'+_0x20dc55+',\x20'+_0x31558e+'.xyz,\x20'+_0x2941fe+');\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20'+this['_defineCubicName']+'\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20'+this['_defineLocalCubicName']+'\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec3\x20'+this['_reflectionVectorName']+'\x20=\x20computeCubicLocalCoords('+_0x4f367b+',\x20'+_0x20dc55+',\x20'+_0x31558e+'.xyz,\x20'+_0x2941fe+',\x20vReflectionSize,\x20vReflectionPosition);\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#else\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec3\x20'+this['_reflectionVectorName']+'\x20=\x20computeCubicCoords('+_0x4f367b+',\x20'+_0x20dc55+',\x20'+_0x31558e+'.xyz,\x20'+_0x2941fe+');\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20'+this['_defineProjectionName']+'\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec3\x20'+this['_reflectionVectorName']+'\x20=\x20computeProjectionCoords('+_0x4f367b+',\x20'+_0x2bdc7b+',\x20'+_0x2941fe+');\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20'+this['_defineSkyboxName']+'\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec3\x20'+this['_reflectionVectorName']+'\x20=\x20computeSkyBoxCoords('+_0x14c642+',\x20'+_0x2941fe+');\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20'+this['_defineExplicitName']+'\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec3\x20'+this['_reflectionVectorName']+'\x20=\x20vec3(0,\x200,\x200);\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20'+this['_defineOppositeZ']+'\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+this['_reflectionVectorName']+'.z\x20*=\x20-1.0;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0d\x0a';return _0x3cecad||(_0x19cb45+='\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20'+this['_define3DName']+'\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec3\x20'+this['_reflectionCoordsName']+'\x20=\x20'+this['_reflectionVectorName']+';\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#else\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec2\x20'+this['_reflectionCoordsName']+'\x20=\x20'+this['_reflectionVectorName']+'.xy;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20'+this['_defineProjectionName']+'\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+this['_reflectionCoordsName']+'\x20/=\x20'+this['_reflectionVectorName']+'.z;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+this['_reflectionCoordsName']+'.y\x20=\x201.0\x20-\x20'+this['_reflectionCoordsName']+'.y;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0d\x0a'),_0x19cb45;},_0x2d6cfc['prototype']['handleFragmentSideCodeReflectionColor']=function(_0x53ecfc,_0x531349){void 0x0===_0x531349&&(_0x531349='.rgb');var _0xe22751='vec'+(0x0===_0x531349['length']?'4':_0x531349['length']-0x1)+'\x20'+this['_reflectionColorName']+';\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20'+this['_define3DName']+'\x0d\x0a';return _0xe22751+=_0x53ecfc?this['_reflectionColorName']+'\x20=\x20textureCubeLodEXT('+this['_cubeSamplerName']+',\x20'+this['_reflectionVectorName']+',\x20'+_0x53ecfc+')'+_0x531349+';\x0d\x0a':this['_reflectionColorName']+'\x20=\x20textureCube('+this['_cubeSamplerName']+',\x20'+this['_reflectionVectorName']+')'+_0x531349+';\x0d\x0a',_0xe22751+='\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#else\x0d\x0a',_0xe22751+=_0x53ecfc?this['_reflectionColorName']+'\x20=\x20texture2DLodEXT('+this['_2DSamplerName']+',\x20'+this['_reflectionCoordsName']+',\x20'+_0x53ecfc+')'+_0x531349+';\x0d\x0a':this['_reflectionColorName']+'\x20=\x20texture2D('+this['_2DSamplerName']+',\x20'+this['_reflectionCoordsName']+')'+_0x531349+';\x0d\x0a',_0xe22751+='#endif\x0d\x0a';},_0x2d6cfc['prototype']['writeOutputs']=function(_0x37c972,_0xc9391d){var _0x3edf05='';if(_0x37c972['target']===_0x4e54a1['Fragment'])for(var _0x583e48=0x0,_0x496c3b=this['_outputs'];_0x583e48<_0x496c3b['length'];_0x583e48++){var _0x2f9aa4=_0x496c3b[_0x583e48];_0x2f9aa4['hasEndpoints']&&(_0x3edf05+=this['_declareOutput'](_0x2f9aa4,_0x37c972)+'\x20=\x20'+_0xc9391d+'.'+_0x2f9aa4['name']+';\x0d\x0a');}return _0x3edf05;},_0x2d6cfc['prototype']['_buildBlock']=function(_0x68c842){return _0x496b81['prototype']['_buildBlock']['call'](this,_0x68c842),this;},_0x2d6cfc['prototype']['_dumpPropertiesCode']=function(){return this['texture']?(_0x367374=this['texture']['isCube']?this['_codeVariableName']+'.texture\x20=\x20new\x20BABYLON.CubeTexture(\x22'+this['texture']['name']+'\x22);\x0d\x0a':this['_codeVariableName']+'.texture\x20=\x20new\x20BABYLON.Texture(\x22'+this['texture']['name']+'\x22);\x0d\x0a',_0x367374+=this['_codeVariableName']+'.texture.coordinatesMode\x20=\x20'+this['texture']['coordinatesMode']+';\x0d\x0a'):'';var _0x367374;},_0x2d6cfc['prototype']['serialize']=function(){var _0x4cff19=_0x496b81['prototype']['serialize']['call'](this);return this['texture']&&(_0x4cff19['texture']=this['texture']['serialize']()),_0x4cff19;},_0x2d6cfc['prototype']['_deserialize']=function(_0x42c1f1,_0x4fa934,_0x3b9834){_0x496b81['prototype']['_deserialize']['call'](this,_0x42c1f1,_0x4fa934,_0x3b9834),_0x42c1f1['texture']&&(_0x3b9834=0x0===_0x42c1f1['texture']['url']['indexOf']('data:')?'':_0x3b9834,_0x42c1f1['texture']['isCube']?this['texture']=_0x33892f['Parse'](_0x42c1f1['texture'],_0x4fa934,_0x3b9834):this['texture']=_0xaf3c80['a']['Parse'](_0x42c1f1['texture'],_0x4fa934,_0x3b9834));},_0x2d6cfc;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.ReflectionTextureBaseBlock']=_0x5823d9;var _0x8e8494=function(_0x76577e){function _0x42e068(_0x10b167){var _0x4393ed=_0x76577e['call'](this,_0x10b167)||this;return _0x4393ed['registerInput']('position',_0x3bb339['Vector3'],!0x1,_0x4e54a1['Vertex']),_0x4393ed['registerInput']('worldPosition',_0x3bb339['Vector4'],!0x1,_0x4e54a1['Vertex']),_0x4393ed['registerInput']('worldNormal',_0x3bb339['Vector4'],!0x1,_0x4e54a1['Fragment']),_0x4393ed['registerInput']('world',_0x3bb339['Matrix'],!0x1,_0x4e54a1['Vertex']),_0x4393ed['registerInput']('cameraPosition',_0x3bb339['Vector3'],!0x1,_0x4e54a1['Fragment']),_0x4393ed['registerInput']('view',_0x3bb339['Matrix'],!0x1,_0x4e54a1['Fragment']),_0x4393ed['registerOutput']('rgb',_0x3bb339['Color3'],_0x4e54a1['Fragment']),_0x4393ed['registerOutput']('rgba',_0x3bb339['Color4'],_0x4e54a1['Fragment']),_0x4393ed['registerOutput']('r',_0x3bb339['Float'],_0x4e54a1['Fragment']),_0x4393ed['registerOutput']('g',_0x3bb339['Float'],_0x4e54a1['Fragment']),_0x4393ed['registerOutput']('b',_0x3bb339['Float'],_0x4e54a1['Fragment']),_0x4393ed['registerOutput']('a',_0x3bb339['Float'],_0x4e54a1['Fragment']),_0x4393ed['_inputs'][0x0]['acceptedConnectionPointTypes']['push'](_0x3bb339['Vector4']),_0x4393ed;}return Object(_0x18e13d['d'])(_0x42e068,_0x76577e),_0x42e068['prototype']['getClassName']=function(){return'ReflectionTextureBlock';},Object['defineProperty'](_0x42e068['prototype'],'position',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x42e068['prototype'],'worldPosition',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x42e068['prototype'],'worldNormal',{'get':function(){return this['_inputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x42e068['prototype'],'world',{'get':function(){return this['_inputs'][0x3];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x42e068['prototype'],'cameraPosition',{'get':function(){return this['_inputs'][0x4];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x42e068['prototype'],'view',{'get':function(){return this['_inputs'][0x5];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x42e068['prototype'],'rgb',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x42e068['prototype'],'rgba',{'get':function(){return this['_outputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x42e068['prototype'],'r',{'get':function(){return this['_outputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x42e068['prototype'],'g',{'get':function(){return this['_outputs'][0x3];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x42e068['prototype'],'b',{'get':function(){return this['_outputs'][0x4];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x42e068['prototype'],'a',{'get':function(){return this['_outputs'][0x5];},'enumerable':!0x1,'configurable':!0x0}),_0x42e068['prototype']['autoConfigure']=function(_0x14d976){if(_0x76577e['prototype']['autoConfigure']['call'](this,_0x14d976),!this['cameraPosition']['isConnected']){var _0x50c15b=_0x14d976['getInputBlockByPredicate'](function(_0x3d7c59){return _0x3d7c59['systemValue']===_0x509c82['CameraPosition'];});_0x50c15b||(_0x50c15b=new _0x581182('cameraPosition'))['setAsSystemValue'](_0x509c82['CameraPosition']),_0x50c15b['output']['connectTo'](this['cameraPosition']);}},_0x42e068['prototype']['_buildBlock']=function(_0x6369cf){if(_0x76577e['prototype']['_buildBlock']['call'](this,_0x6369cf),!this['texture'])return _0x6369cf['compilationString']+=this['writeOutputs'](_0x6369cf,'vec3(0.)'),this;if(_0x6369cf['target']!==_0x4e54a1['Fragment'])return _0x6369cf['compilationString']+=this['handleVertexSide'](_0x6369cf),this;this['handleFragmentSideInits'](_0x6369cf);var _0x4703bc=_0x6369cf['_getFreeVariableName']('normalWUnit');return _0x6369cf['compilationString']+='vec4\x20'+_0x4703bc+'\x20=\x20normalize('+this['worldNormal']['associatedVariableName']+');\x0d\x0a',_0x6369cf['compilationString']+=this['handleFragmentSideCodeReflectionCoords'](_0x4703bc),_0x6369cf['compilationString']+=this['handleFragmentSideCodeReflectionColor'](void 0x0,''),_0x6369cf['compilationString']+=this['writeOutputs'](_0x6369cf,this['_reflectionColorName']),this;},_0x42e068;}(_0x5823d9);_0x3cd573['a']['RegisteredTypes']['BABYLON.ReflectionTextureBlock']=_0x8e8494;var _0x1c572e=function(_0xc3a5ca){function _0x318ab8(_0x432c24){var _0x4f2605=_0xc3a5ca['call'](this,_0x432c24,_0x4e54a1['Neutral'])||this;return _0x4f2605['registerInput']('left',_0x3bb339['AutoDetect']),_0x4f2605['registerInput']('right',_0x3bb339['AutoDetect']),_0x4f2605['registerOutput']('output',_0x3bb339['BasedOnInput']),_0x4f2605['_outputs'][0x0]['_typeConnectionSource']=_0x4f2605['_inputs'][0x0],_0x4f2605['_linkConnectionTypes'](0x0,0x1),_0x4f2605;}return Object(_0x18e13d['d'])(_0x318ab8,_0xc3a5ca),_0x318ab8['prototype']['getClassName']=function(){return'AddBlock';},Object['defineProperty'](_0x318ab8['prototype'],'left',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x318ab8['prototype'],'right',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x318ab8['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x318ab8['prototype']['_buildBlock']=function(_0x57cb52){_0xc3a5ca['prototype']['_buildBlock']['call'](this,_0x57cb52);var _0x3aa295=this['_outputs'][0x0];return _0x57cb52['compilationString']+=this['_declareOutput'](_0x3aa295,_0x57cb52)+'\x20=\x20'+this['left']['associatedVariableName']+'\x20+\x20'+this['right']['associatedVariableName']+';\x0d\x0a',this;},_0x318ab8;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.AddBlock']=_0x1c572e;var _0xcf3d9e=function(_0x559668){function _0x59b933(_0x3bd769){var _0x4684a0=_0x559668['call'](this,_0x3bd769,_0x4e54a1['Neutral'])||this;return _0x4684a0['registerInput']('input',_0x3bb339['AutoDetect']),_0x4684a0['registerInput']('factor',_0x3bb339['Float']),_0x4684a0['registerOutput']('output',_0x3bb339['BasedOnInput']),_0x4684a0['_outputs'][0x0]['_typeConnectionSource']=_0x4684a0['_inputs'][0x0],_0x4684a0;}return Object(_0x18e13d['d'])(_0x59b933,_0x559668),_0x59b933['prototype']['getClassName']=function(){return'ScaleBlock';},Object['defineProperty'](_0x59b933['prototype'],'input',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x59b933['prototype'],'factor',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x59b933['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x59b933['prototype']['_buildBlock']=function(_0x44245a){_0x559668['prototype']['_buildBlock']['call'](this,_0x44245a);var _0x25ecb8=this['_outputs'][0x0];return _0x44245a['compilationString']+=this['_declareOutput'](_0x25ecb8,_0x44245a)+'\x20=\x20'+this['input']['associatedVariableName']+'\x20*\x20'+this['factor']['associatedVariableName']+';\x0d\x0a',this;},_0x59b933;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.ScaleBlock']=_0xcf3d9e;var _0x10c1c3=function(_0x597089){function _0x38bc07(_0x474d34){var _0x1ecefd=_0x597089['call'](this,_0x474d34,_0x4e54a1['Neutral'])||this;return _0x1ecefd['minimum']=0x0,_0x1ecefd['maximum']=0x1,_0x1ecefd['registerInput']('value',_0x3bb339['AutoDetect']),_0x1ecefd['registerOutput']('output',_0x3bb339['BasedOnInput']),_0x1ecefd['_outputs'][0x0]['_typeConnectionSource']=_0x1ecefd['_inputs'][0x0],_0x1ecefd;}return Object(_0x18e13d['d'])(_0x38bc07,_0x597089),_0x38bc07['prototype']['getClassName']=function(){return'ClampBlock';},Object['defineProperty'](_0x38bc07['prototype'],'value',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x38bc07['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x38bc07['prototype']['_buildBlock']=function(_0x49e294){_0x597089['prototype']['_buildBlock']['call'](this,_0x49e294);var _0x355ee2=this['_outputs'][0x0];return _0x49e294['compilationString']+=this['_declareOutput'](_0x355ee2,_0x49e294)+'\x20=\x20clamp('+this['value']['associatedVariableName']+',\x20'+this['_writeFloat'](this['minimum'])+',\x20'+this['_writeFloat'](this['maximum'])+');\x0d\x0a',this;},_0x38bc07['prototype']['_dumpPropertiesCode']=function(){var _0x1a109f=this['_codeVariableName']+'.minimum\x20=\x20'+this['minimum']+';\x0d\x0a';return _0x1a109f+=this['_codeVariableName']+'.maximum\x20=\x20'+this['maximum']+';\x0d\x0a';},_0x38bc07['prototype']['serialize']=function(){var _0x593d0b=_0x597089['prototype']['serialize']['call'](this);return _0x593d0b['minimum']=this['minimum'],_0x593d0b['maximum']=this['maximum'],_0x593d0b;},_0x38bc07['prototype']['_deserialize']=function(_0xe6929b,_0x42da16,_0x52e7ed){_0x597089['prototype']['_deserialize']['call'](this,_0xe6929b,_0x42da16,_0x52e7ed),this['minimum']=_0xe6929b['minimum'],this['maximum']=_0xe6929b['maximum'];},Object(_0x18e13d['c'])([_0x148e9b('Minimum',_0x4bd31d['Float'])],_0x38bc07['prototype'],'minimum',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('Maximum',_0x4bd31d['Float'])],_0x38bc07['prototype'],'maximum',void 0x0),_0x38bc07;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.ClampBlock']=_0x10c1c3;var _0xe40533=function(_0x1b91ab){function _0x53e8e2(_0x38681e){var _0x1c5101=_0x1b91ab['call'](this,_0x38681e,_0x4e54a1['Neutral'])||this;return _0x1c5101['registerInput']('left',_0x3bb339['AutoDetect']),_0x1c5101['registerInput']('right',_0x3bb339['AutoDetect']),_0x1c5101['registerOutput']('output',_0x3bb339['Vector3']),_0x1c5101['_linkConnectionTypes'](0x0,0x1),_0x1c5101['_inputs'][0x0]['excludedConnectionPointTypes']['push'](_0x3bb339['Float']),_0x1c5101['_inputs'][0x0]['excludedConnectionPointTypes']['push'](_0x3bb339['Matrix']),_0x1c5101['_inputs'][0x0]['excludedConnectionPointTypes']['push'](_0x3bb339['Vector2']),_0x1c5101['_inputs'][0x1]['excludedConnectionPointTypes']['push'](_0x3bb339['Float']),_0x1c5101['_inputs'][0x1]['excludedConnectionPointTypes']['push'](_0x3bb339['Matrix']),_0x1c5101['_inputs'][0x1]['excludedConnectionPointTypes']['push'](_0x3bb339['Vector2']),_0x1c5101;}return Object(_0x18e13d['d'])(_0x53e8e2,_0x1b91ab),_0x53e8e2['prototype']['getClassName']=function(){return'CrossBlock';},Object['defineProperty'](_0x53e8e2['prototype'],'left',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x53e8e2['prototype'],'right',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x53e8e2['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x53e8e2['prototype']['_buildBlock']=function(_0xded128){_0x1b91ab['prototype']['_buildBlock']['call'](this,_0xded128);var _0x2b5d18=this['_outputs'][0x0];return _0xded128['compilationString']+=this['_declareOutput'](_0x2b5d18,_0xded128)+'\x20=\x20cross('+this['left']['associatedVariableName']+'.xyz,\x20'+this['right']['associatedVariableName']+'.xyz);\x0d\x0a',this;},_0x53e8e2;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.CrossBlock']=_0xe40533;var _0x4ce394=function(_0xe35572){function _0x210126(_0x591512){var _0x438202=_0xe35572['call'](this,_0x591512,_0x4e54a1['Neutral'])||this;return _0x438202['registerInput']('left',_0x3bb339['AutoDetect']),_0x438202['registerInput']('right',_0x3bb339['AutoDetect']),_0x438202['registerOutput']('output',_0x3bb339['Float']),_0x438202['_linkConnectionTypes'](0x0,0x1),_0x438202['_inputs'][0x0]['excludedConnectionPointTypes']['push'](_0x3bb339['Float']),_0x438202['_inputs'][0x0]['excludedConnectionPointTypes']['push'](_0x3bb339['Matrix']),_0x438202['_inputs'][0x1]['excludedConnectionPointTypes']['push'](_0x3bb339['Float']),_0x438202['_inputs'][0x1]['excludedConnectionPointTypes']['push'](_0x3bb339['Matrix']),_0x438202;}return Object(_0x18e13d['d'])(_0x210126,_0xe35572),_0x210126['prototype']['getClassName']=function(){return'DotBlock';},Object['defineProperty'](_0x210126['prototype'],'left',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x210126['prototype'],'right',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x210126['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x210126['prototype']['_buildBlock']=function(_0x5c440e){_0xe35572['prototype']['_buildBlock']['call'](this,_0x5c440e);var _0x51abfb=this['_outputs'][0x0];return _0x5c440e['compilationString']+=this['_declareOutput'](_0x51abfb,_0x5c440e)+'\x20=\x20dot('+this['left']['associatedVariableName']+',\x20'+this['right']['associatedVariableName']+');\x0d\x0a',this;},_0x210126;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.DotBlock']=_0x4ce394;var _0x3b6eff=function(_0x64826){function _0x35cb0f(_0x1ec2f0){var _0x4dd540=_0x64826['call'](this,_0x1ec2f0,_0x4e54a1['Neutral'])||this;return _0x4dd540['registerInput']('input',_0x3bb339['AutoDetect']),_0x4dd540['registerOutput']('output',_0x3bb339['BasedOnInput']),_0x4dd540['_outputs'][0x0]['_typeConnectionSource']=_0x4dd540['_inputs'][0x0],_0x4dd540['_inputs'][0x0]['excludedConnectionPointTypes']['push'](_0x3bb339['Float']),_0x4dd540['_inputs'][0x0]['excludedConnectionPointTypes']['push'](_0x3bb339['Matrix']),_0x4dd540;}return Object(_0x18e13d['d'])(_0x35cb0f,_0x64826),_0x35cb0f['prototype']['getClassName']=function(){return'NormalizeBlock';},Object['defineProperty'](_0x35cb0f['prototype'],'input',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x35cb0f['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x35cb0f['prototype']['_buildBlock']=function(_0x35031d){_0x64826['prototype']['_buildBlock']['call'](this,_0x35031d);var _0x39743d=this['_outputs'][0x0],_0x2c3cc3=this['_inputs'][0x0];return _0x35031d['compilationString']+=this['_declareOutput'](_0x39743d,_0x35031d)+'\x20=\x20normalize('+_0x2c3cc3['associatedVariableName']+');\x0d\x0a',this;},_0x35cb0f;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.NormalizeBlock']=_0x3b6eff;var _0x8f09b8=function(_0x25bb93){function _0x3e6760(_0x1160b1){var _0x517dd5=_0x25bb93['call'](this,_0x1160b1,_0x4e54a1['Neutral'])||this;return _0x517dd5['registerInput']('rgb\x20',_0x3bb339['Color3'],!0x0),_0x517dd5['registerInput']('r',_0x3bb339['Float'],!0x0),_0x517dd5['registerInput']('g',_0x3bb339['Float'],!0x0),_0x517dd5['registerInput']('b',_0x3bb339['Float'],!0x0),_0x517dd5['registerInput']('a',_0x3bb339['Float'],!0x0),_0x517dd5['registerOutput']('rgba',_0x3bb339['Color4']),_0x517dd5['registerOutput']('rgb',_0x3bb339['Color3']),_0x517dd5;}return Object(_0x18e13d['d'])(_0x3e6760,_0x25bb93),_0x3e6760['prototype']['getClassName']=function(){return'ColorMergerBlock';},Object['defineProperty'](_0x3e6760['prototype'],'rgbIn',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3e6760['prototype'],'r',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3e6760['prototype'],'g',{'get':function(){return this['_inputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3e6760['prototype'],'b',{'get':function(){return this['_inputs'][0x3];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3e6760['prototype'],'a',{'get':function(){return this['_inputs'][0x4];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3e6760['prototype'],'rgba',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3e6760['prototype'],'rgbOut',{'get':function(){return this['_outputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3e6760['prototype'],'rgb',{'get':function(){return this['rgbOut'];},'enumerable':!0x1,'configurable':!0x0}),_0x3e6760['prototype']['_buildBlock']=function(_0x1ee2b5){_0x25bb93['prototype']['_buildBlock']['call'](this,_0x1ee2b5);var _0x333c43=this['r'],_0x2c1208=this['g'],_0x2f3d97=this['b'],_0x402bd4=this['a'],_0x29fb2d=this['rgbIn'],_0x493861=this['_outputs'][0x0],_0x2ab142=this['_outputs'][0x1];return _0x29fb2d['isConnected']?_0x493861['hasEndpoints']?_0x1ee2b5['compilationString']+=this['_declareOutput'](_0x493861,_0x1ee2b5)+'\x20=\x20vec4('+_0x29fb2d['associatedVariableName']+',\x20'+(_0x402bd4['isConnected']?this['_writeVariable'](_0x402bd4):'0.0')+');\x0d\x0a':_0x2ab142['hasEndpoints']&&(_0x1ee2b5['compilationString']+=this['_declareOutput'](_0x2ab142,_0x1ee2b5)+'\x20=\x20'+_0x29fb2d['associatedVariableName']+';\x0d\x0a'):_0x493861['hasEndpoints']?_0x1ee2b5['compilationString']+=this['_declareOutput'](_0x493861,_0x1ee2b5)+'\x20=\x20vec4('+(_0x333c43['isConnected']?this['_writeVariable'](_0x333c43):'0.0')+',\x20'+(_0x2c1208['isConnected']?this['_writeVariable'](_0x2c1208):'0.0')+',\x20'+(_0x2f3d97['isConnected']?this['_writeVariable'](_0x2f3d97):'0.0')+',\x20'+(_0x402bd4['isConnected']?this['_writeVariable'](_0x402bd4):'0.0')+');\x0d\x0a':_0x2ab142['hasEndpoints']&&(_0x1ee2b5['compilationString']+=this['_declareOutput'](_0x2ab142,_0x1ee2b5)+'\x20=\x20vec3('+(_0x333c43['isConnected']?this['_writeVariable'](_0x333c43):'0.0')+',\x20'+(_0x2c1208['isConnected']?this['_writeVariable'](_0x2c1208):'0.0')+',\x20'+(_0x2f3d97['isConnected']?this['_writeVariable'](_0x2f3d97):'0.0')+');\x0d\x0a'),this;},_0x3e6760;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.ColorMergerBlock']=_0x8f09b8;var _0x41cae2=function(_0x39ccd6){function _0x2333e0(_0x49172b){var _0xeb43db=_0x39ccd6['call'](this,_0x49172b,_0x4e54a1['Neutral'])||this;return _0xeb43db['registerInput']('xyzw',_0x3bb339['Vector4'],!0x0),_0xeb43db['registerInput']('xyz\x20',_0x3bb339['Vector3'],!0x0),_0xeb43db['registerInput']('xy\x20',_0x3bb339['Vector2'],!0x0),_0xeb43db['registerOutput']('xyz',_0x3bb339['Vector3']),_0xeb43db['registerOutput']('xy',_0x3bb339['Vector2']),_0xeb43db['registerOutput']('x',_0x3bb339['Float']),_0xeb43db['registerOutput']('y',_0x3bb339['Float']),_0xeb43db['registerOutput']('z',_0x3bb339['Float']),_0xeb43db['registerOutput']('w',_0x3bb339['Float']),_0xeb43db['inputsAreExclusive']=!0x0,_0xeb43db;}return Object(_0x18e13d['d'])(_0x2333e0,_0x39ccd6),_0x2333e0['prototype']['getClassName']=function(){return'VectorSplitterBlock';},Object['defineProperty'](_0x2333e0['prototype'],'xyzw',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2333e0['prototype'],'xyzIn',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2333e0['prototype'],'xyIn',{'get':function(){return this['_inputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2333e0['prototype'],'xyzOut',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2333e0['prototype'],'xyOut',{'get':function(){return this['_outputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2333e0['prototype'],'x',{'get':function(){return this['_outputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2333e0['prototype'],'y',{'get':function(){return this['_outputs'][0x3];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2333e0['prototype'],'z',{'get':function(){return this['_outputs'][0x4];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2333e0['prototype'],'w',{'get':function(){return this['_outputs'][0x5];},'enumerable':!0x1,'configurable':!0x0}),_0x2333e0['prototype']['_inputRename']=function(_0x405b7d){switch(_0x405b7d){case'xy\x20':return'xyIn';case'xyz\x20':return'xyzIn';default:return _0x405b7d;}},_0x2333e0['prototype']['_outputRename']=function(_0x53da7c){switch(_0x53da7c){case'xy':return'xyOut';case'xyz':return'xyzOut';default:return _0x53da7c;}},_0x2333e0['prototype']['_buildBlock']=function(_0x34a23b){_0x39ccd6['prototype']['_buildBlock']['call'](this,_0x34a23b);var _0x21175c=this['xyzw']['isConnected']?this['xyzw']:this['xyzIn']['isConnected']?this['xyzIn']:this['xyIn'],_0x1b51c5=this['_outputs'][0x0],_0x4a3abc=this['_outputs'][0x1],_0x1d67ba=this['_outputs'][0x2],_0x275fce=this['_outputs'][0x3],_0x13fc29=this['_outputs'][0x4],_0x45777a=this['_outputs'][0x5];return _0x1b51c5['hasEndpoints']&&(_0x21175c===this['xyIn']?_0x34a23b['compilationString']+=this['_declareOutput'](_0x1b51c5,_0x34a23b)+'\x20=\x20vec3('+_0x21175c['associatedVariableName']+',\x200.0);\x0d\x0a':_0x34a23b['compilationString']+=this['_declareOutput'](_0x1b51c5,_0x34a23b)+'\x20=\x20'+_0x21175c['associatedVariableName']+'.xyz;\x0d\x0a'),_0x4a3abc['hasEndpoints']&&(_0x34a23b['compilationString']+=this['_declareOutput'](_0x4a3abc,_0x34a23b)+'\x20=\x20'+_0x21175c['associatedVariableName']+'.xy;\x0d\x0a'),_0x1d67ba['hasEndpoints']&&(_0x34a23b['compilationString']+=this['_declareOutput'](_0x1d67ba,_0x34a23b)+'\x20=\x20'+_0x21175c['associatedVariableName']+'.x;\x0d\x0a'),_0x275fce['hasEndpoints']&&(_0x34a23b['compilationString']+=this['_declareOutput'](_0x275fce,_0x34a23b)+'\x20=\x20'+_0x21175c['associatedVariableName']+'.y;\x0d\x0a'),_0x13fc29['hasEndpoints']&&(_0x34a23b['compilationString']+=this['_declareOutput'](_0x13fc29,_0x34a23b)+'\x20=\x20'+_0x21175c['associatedVariableName']+'.z;\x0d\x0a'),_0x45777a['hasEndpoints']&&(_0x34a23b['compilationString']+=this['_declareOutput'](_0x45777a,_0x34a23b)+'\x20=\x20'+_0x21175c['associatedVariableName']+'.w;\x0d\x0a'),this;},_0x2333e0;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.VectorSplitterBlock']=_0x41cae2;var _0x5b8f17=function(_0x6dddd7){function _0x31377a(_0x540ca7){var _0x5a2934=_0x6dddd7['call'](this,_0x540ca7,_0x4e54a1['Neutral'])||this;return _0x5a2934['registerInput']('left',_0x3bb339['AutoDetect']),_0x5a2934['registerInput']('right',_0x3bb339['AutoDetect']),_0x5a2934['registerInput']('gradient',_0x3bb339['AutoDetect']),_0x5a2934['registerOutput']('output',_0x3bb339['BasedOnInput']),_0x5a2934['_outputs'][0x0]['_typeConnectionSource']=_0x5a2934['_inputs'][0x0],_0x5a2934['_linkConnectionTypes'](0x0,0x1),_0x5a2934['_linkConnectionTypes'](0x1,0x2,!0x0),_0x5a2934['_inputs'][0x2]['acceptedConnectionPointTypes']['push'](_0x3bb339['Float']),_0x5a2934;}return Object(_0x18e13d['d'])(_0x31377a,_0x6dddd7),_0x31377a['prototype']['getClassName']=function(){return'LerpBlock';},Object['defineProperty'](_0x31377a['prototype'],'left',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x31377a['prototype'],'right',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x31377a['prototype'],'gradient',{'get':function(){return this['_inputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x31377a['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x31377a['prototype']['_buildBlock']=function(_0x261972){_0x6dddd7['prototype']['_buildBlock']['call'](this,_0x261972);var _0x2b83d1=this['_outputs'][0x0];return _0x261972['compilationString']+=this['_declareOutput'](_0x2b83d1,_0x261972)+'\x20=\x20mix('+this['left']['associatedVariableName']+'\x20,\x20'+this['right']['associatedVariableName']+',\x20'+this['gradient']['associatedVariableName']+');\x0d\x0a',this;},_0x31377a;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.LerpBlock']=_0x5b8f17;var _0x3b4794=function(_0x3e83f4){function _0x1dc9a6(_0x36b523){var _0x264f30=_0x3e83f4['call'](this,_0x36b523,_0x4e54a1['Neutral'])||this;return _0x264f30['registerInput']('left',_0x3bb339['AutoDetect']),_0x264f30['registerInput']('right',_0x3bb339['AutoDetect']),_0x264f30['registerOutput']('output',_0x3bb339['BasedOnInput']),_0x264f30['_outputs'][0x0]['_typeConnectionSource']=_0x264f30['_inputs'][0x0],_0x264f30['_linkConnectionTypes'](0x0,0x1),_0x264f30;}return Object(_0x18e13d['d'])(_0x1dc9a6,_0x3e83f4),_0x1dc9a6['prototype']['getClassName']=function(){return'DivideBlock';},Object['defineProperty'](_0x1dc9a6['prototype'],'left',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1dc9a6['prototype'],'right',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1dc9a6['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x1dc9a6['prototype']['_buildBlock']=function(_0x27ebaf){_0x3e83f4['prototype']['_buildBlock']['call'](this,_0x27ebaf);var _0x2b4673=this['_outputs'][0x0];return _0x27ebaf['compilationString']+=this['_declareOutput'](_0x2b4673,_0x27ebaf)+'\x20=\x20'+this['left']['associatedVariableName']+'\x20/\x20'+this['right']['associatedVariableName']+';\x0d\x0a',this;},_0x1dc9a6;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.DivideBlock']=_0x3b4794;var _0x3c393b=function(_0xb1716){function _0x2e455d(_0x33c738){var _0x21b064=_0xb1716['call'](this,_0x33c738,_0x4e54a1['Neutral'])||this;return _0x21b064['registerInput']('left',_0x3bb339['AutoDetect']),_0x21b064['registerInput']('right',_0x3bb339['AutoDetect']),_0x21b064['registerOutput']('output',_0x3bb339['BasedOnInput']),_0x21b064['_outputs'][0x0]['_typeConnectionSource']=_0x21b064['_inputs'][0x0],_0x21b064['_linkConnectionTypes'](0x0,0x1),_0x21b064;}return Object(_0x18e13d['d'])(_0x2e455d,_0xb1716),_0x2e455d['prototype']['getClassName']=function(){return'SubtractBlock';},Object['defineProperty'](_0x2e455d['prototype'],'left',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2e455d['prototype'],'right',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2e455d['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x2e455d['prototype']['_buildBlock']=function(_0x11b358){_0xb1716['prototype']['_buildBlock']['call'](this,_0x11b358);var _0x536b7c=this['_outputs'][0x0];return _0x11b358['compilationString']+=this['_declareOutput'](_0x536b7c,_0x11b358)+'\x20=\x20'+this['left']['associatedVariableName']+'\x20-\x20'+this['right']['associatedVariableName']+';\x0d\x0a',this;},_0x2e455d;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.SubtractBlock']=_0x3c393b;var _0x56ce29=function(_0xd6a28d){function _0x1203c7(_0x3146b6){var _0x4a5ca8=_0xd6a28d['call'](this,_0x3146b6,_0x4e54a1['Neutral'])||this;return _0x4a5ca8['registerInput']('value',_0x3bb339['Float']),_0x4a5ca8['registerInput']('edge',_0x3bb339['Float']),_0x4a5ca8['registerOutput']('output',_0x3bb339['Float']),_0x4a5ca8;}return Object(_0x18e13d['d'])(_0x1203c7,_0xd6a28d),_0x1203c7['prototype']['getClassName']=function(){return'StepBlock';},Object['defineProperty'](_0x1203c7['prototype'],'value',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1203c7['prototype'],'edge',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1203c7['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x1203c7['prototype']['_buildBlock']=function(_0x3a5b54){_0xd6a28d['prototype']['_buildBlock']['call'](this,_0x3a5b54);var _0x4d64e6=this['_outputs'][0x0];return _0x3a5b54['compilationString']+=this['_declareOutput'](_0x4d64e6,_0x3a5b54)+'\x20=\x20step('+this['edge']['associatedVariableName']+',\x20'+this['value']['associatedVariableName']+');\x0d\x0a',this;},_0x1203c7;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.StepBlock']=_0x56ce29;var _0x3fe18e=function(_0x47a489){function _0x112785(_0x36086f){var _0x2c2519=_0x47a489['call'](this,_0x36086f,_0x4e54a1['Neutral'])||this;return _0x2c2519['registerInput']('input',_0x3bb339['AutoDetect']),_0x2c2519['registerOutput']('output',_0x3bb339['BasedOnInput']),_0x2c2519['_outputs'][0x0]['_typeConnectionSource']=_0x2c2519['_inputs'][0x0],_0x2c2519['_outputs'][0x0]['excludedConnectionPointTypes']['push'](_0x3bb339['Matrix']),_0x2c2519;}return Object(_0x18e13d['d'])(_0x112785,_0x47a489),_0x112785['prototype']['getClassName']=function(){return'OneMinusBlock';},Object['defineProperty'](_0x112785['prototype'],'input',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x112785['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x112785['prototype']['_buildBlock']=function(_0x17057e){_0x47a489['prototype']['_buildBlock']['call'](this,_0x17057e);var _0x1fe548=this['_outputs'][0x0];return _0x17057e['compilationString']+=this['_declareOutput'](_0x1fe548,_0x17057e)+'\x20=\x201.\x20-\x20'+this['input']['associatedVariableName']+';\x0d\x0a',this;},_0x112785;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.OneMinusBlock']=_0x3fe18e,_0x3cd573['a']['RegisteredTypes']['BABYLON.OppositeBlock']=_0x3fe18e;var _0x565aad=function(_0x5a8799){function _0x146888(_0x21225f){var _0x30cd04=_0x5a8799['call'](this,_0x21225f,_0x4e54a1['Neutral'])||this;return _0x30cd04['registerInput']('worldPosition',_0x3bb339['Vector4']),_0x30cd04['registerInput']('cameraPosition',_0x3bb339['Vector3']),_0x30cd04['registerOutput']('output',_0x3bb339['Vector3']),_0x30cd04;}return Object(_0x18e13d['d'])(_0x146888,_0x5a8799),_0x146888['prototype']['getClassName']=function(){return'ViewDirectionBlock';},Object['defineProperty'](_0x146888['prototype'],'worldPosition',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x146888['prototype'],'cameraPosition',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x146888['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x146888['prototype']['autoConfigure']=function(_0x35728f){if(!this['cameraPosition']['isConnected']){var _0x1cac47=_0x35728f['getInputBlockByPredicate'](function(_0x25a892){return _0x25a892['systemValue']===_0x509c82['CameraPosition'];});_0x1cac47||(_0x1cac47=new _0x581182('cameraPosition'))['setAsSystemValue'](_0x509c82['CameraPosition']),_0x1cac47['output']['connectTo'](this['cameraPosition']);}},_0x146888['prototype']['_buildBlock']=function(_0x16258c){_0x5a8799['prototype']['_buildBlock']['call'](this,_0x16258c);var _0x3ccb90=this['_outputs'][0x0];return _0x16258c['compilationString']+=this['_declareOutput'](_0x3ccb90,_0x16258c)+'\x20=\x20normalize('+this['cameraPosition']['associatedVariableName']+'\x20-\x20'+this['worldPosition']['associatedVariableName']+'.xyz);\x0d\x0a',this;},_0x146888;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.ViewDirectionBlock']=_0x565aad,_0x162675(0xa1);var _0x5adb42=function(_0x50096b){function _0x420a89(_0x343ebb){var _0x1bb277=_0x50096b['call'](this,_0x343ebb,_0x4e54a1['Neutral'])||this;return _0x1bb277['registerInput']('worldNormal',_0x3bb339['Vector4']),_0x1bb277['registerInput']('viewDirection',_0x3bb339['Vector3']),_0x1bb277['registerInput']('bias',_0x3bb339['Float']),_0x1bb277['registerInput']('power',_0x3bb339['Float']),_0x1bb277['registerOutput']('fresnel',_0x3bb339['Float']),_0x1bb277;}return Object(_0x18e13d['d'])(_0x420a89,_0x50096b),_0x420a89['prototype']['getClassName']=function(){return'FresnelBlock';},Object['defineProperty'](_0x420a89['prototype'],'worldNormal',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x420a89['prototype'],'viewDirection',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x420a89['prototype'],'bias',{'get':function(){return this['_inputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x420a89['prototype'],'power',{'get':function(){return this['_inputs'][0x3];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x420a89['prototype'],'fresnel',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x420a89['prototype']['autoConfigure']=function(_0x5d75cf){if(!this['viewDirection']['isConnected']){var _0x26c779=new _0x565aad('View\x20direction');_0x26c779['output']['connectTo'](this['viewDirection']),_0x26c779['autoConfigure'](_0x5d75cf);}if(!this['bias']['isConnected']){var _0x13f6b4=new _0x581182('bias');_0x13f6b4['value']=0x0,_0x13f6b4['output']['connectTo'](this['bias']);}if(!this['power']['isConnected']){var _0x4f71ea=new _0x581182('power');_0x4f71ea['value']=0x1,_0x4f71ea['output']['connectTo'](this['power']);}},_0x420a89['prototype']['_buildBlock']=function(_0xf63e8b){_0x50096b['prototype']['_buildBlock']['call'](this,_0xf63e8b);var _0x289189='//'+this['name'];return _0xf63e8b['_emitFunctionFromInclude']('fresnelFunction',_0x289189,{'removeIfDef':!0x0}),_0xf63e8b['compilationString']+=this['_declareOutput'](this['fresnel'],_0xf63e8b)+'\x20=\x20computeFresnelTerm('+this['viewDirection']['associatedVariableName']+'.xyz,\x20'+this['worldNormal']['associatedVariableName']+'.xyz,\x20'+this['bias']['associatedVariableName']+',\x20'+this['power']['associatedVariableName']+');\x0d\x0a',this;},_0x420a89;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.FresnelBlock']=_0x5adb42;var _0x1f615c=function(_0x569178){function _0x3edcfa(_0x4a0a14){var _0x1504b8=_0x569178['call'](this,_0x4a0a14,_0x4e54a1['Neutral'])||this;return _0x1504b8['registerInput']('left',_0x3bb339['AutoDetect']),_0x1504b8['registerInput']('right',_0x3bb339['AutoDetect']),_0x1504b8['registerOutput']('output',_0x3bb339['BasedOnInput']),_0x1504b8['_outputs'][0x0]['_typeConnectionSource']=_0x1504b8['_inputs'][0x0],_0x1504b8['_linkConnectionTypes'](0x0,0x1),_0x1504b8;}return Object(_0x18e13d['d'])(_0x3edcfa,_0x569178),_0x3edcfa['prototype']['getClassName']=function(){return'MaxBlock';},Object['defineProperty'](_0x3edcfa['prototype'],'left',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3edcfa['prototype'],'right',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3edcfa['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x3edcfa['prototype']['_buildBlock']=function(_0xe1054b){_0x569178['prototype']['_buildBlock']['call'](this,_0xe1054b);var _0x2c4477=this['_outputs'][0x0];return _0xe1054b['compilationString']+=this['_declareOutput'](_0x2c4477,_0xe1054b)+'\x20=\x20max('+this['left']['associatedVariableName']+',\x20'+this['right']['associatedVariableName']+');\x0d\x0a',this;},_0x3edcfa;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.MaxBlock']=_0x1f615c;var _0x258c26=function(_0x280f5a){function _0x3774a3(_0x4b124e){var _0x19ad5d=_0x280f5a['call'](this,_0x4b124e,_0x4e54a1['Neutral'])||this;return _0x19ad5d['registerInput']('left',_0x3bb339['AutoDetect']),_0x19ad5d['registerInput']('right',_0x3bb339['AutoDetect']),_0x19ad5d['registerOutput']('output',_0x3bb339['BasedOnInput']),_0x19ad5d['_outputs'][0x0]['_typeConnectionSource']=_0x19ad5d['_inputs'][0x0],_0x19ad5d['_linkConnectionTypes'](0x0,0x1),_0x19ad5d;}return Object(_0x18e13d['d'])(_0x3774a3,_0x280f5a),_0x3774a3['prototype']['getClassName']=function(){return'MinBlock';},Object['defineProperty'](_0x3774a3['prototype'],'left',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3774a3['prototype'],'right',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3774a3['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x3774a3['prototype']['_buildBlock']=function(_0x3a1994){_0x280f5a['prototype']['_buildBlock']['call'](this,_0x3a1994);var _0x4c9b08=this['_outputs'][0x0];return _0x3a1994['compilationString']+=this['_declareOutput'](_0x4c9b08,_0x3a1994)+'\x20=\x20min('+this['left']['associatedVariableName']+',\x20'+this['right']['associatedVariableName']+');\x0d\x0a',this;},_0x3774a3;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.MinBlock']=_0x258c26;var _0x5a3952=function(_0x47b635){function _0x2f956f(_0x219bca){var _0x26878c=_0x47b635['call'](this,_0x219bca,_0x4e54a1['Neutral'])||this;return _0x26878c['registerInput']('left',_0x3bb339['AutoDetect']),_0x26878c['registerInput']('right',_0x3bb339['AutoDetect']),_0x26878c['registerOutput']('output',_0x3bb339['Float']),_0x26878c['_linkConnectionTypes'](0x0,0x1),_0x26878c['_inputs'][0x0]['excludedConnectionPointTypes']['push'](_0x3bb339['Float']),_0x26878c['_inputs'][0x0]['excludedConnectionPointTypes']['push'](_0x3bb339['Matrix']),_0x26878c['_inputs'][0x1]['excludedConnectionPointTypes']['push'](_0x3bb339['Float']),_0x26878c['_inputs'][0x1]['excludedConnectionPointTypes']['push'](_0x3bb339['Matrix']),_0x26878c;}return Object(_0x18e13d['d'])(_0x2f956f,_0x47b635),_0x2f956f['prototype']['getClassName']=function(){return'DistanceBlock';},Object['defineProperty'](_0x2f956f['prototype'],'left',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2f956f['prototype'],'right',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2f956f['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x2f956f['prototype']['_buildBlock']=function(_0x1f8f23){_0x47b635['prototype']['_buildBlock']['call'](this,_0x1f8f23);var _0x173e64=this['_outputs'][0x0];return _0x1f8f23['compilationString']+=this['_declareOutput'](_0x173e64,_0x1f8f23)+'\x20=\x20length('+this['left']['associatedVariableName']+'\x20-\x20'+this['right']['associatedVariableName']+');\x0d\x0a',this;},_0x2f956f;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.DistanceBlock']=_0x5a3952;var _0x46caad=function(_0x21ce37){function _0x448c2b(_0x1f7158){var _0x279e89=_0x21ce37['call'](this,_0x1f7158,_0x4e54a1['Neutral'])||this;return _0x279e89['registerInput']('value',_0x3bb339['AutoDetect']),_0x279e89['registerOutput']('output',_0x3bb339['Float']),_0x279e89['_inputs'][0x0]['excludedConnectionPointTypes']['push'](_0x3bb339['Float']),_0x279e89['_inputs'][0x0]['excludedConnectionPointTypes']['push'](_0x3bb339['Matrix']),_0x279e89;}return Object(_0x18e13d['d'])(_0x448c2b,_0x21ce37),_0x448c2b['prototype']['getClassName']=function(){return'LengthBlock';},Object['defineProperty'](_0x448c2b['prototype'],'value',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x448c2b['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x448c2b['prototype']['_buildBlock']=function(_0x59ce75){_0x21ce37['prototype']['_buildBlock']['call'](this,_0x59ce75);var _0x587077=this['_outputs'][0x0];return _0x59ce75['compilationString']+=this['_declareOutput'](_0x587077,_0x59ce75)+'\x20=\x20length('+this['value']['associatedVariableName']+');\x0d\x0a',this;},_0x448c2b;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.LengthBlock']=_0x46caad;var _0x567545=function(_0x88ba4c){function _0x555379(_0x4ec194){var _0x49a253=_0x88ba4c['call'](this,_0x4ec194,_0x4e54a1['Neutral'])||this;return _0x49a253['registerInput']('value',_0x3bb339['AutoDetect']),_0x49a253['registerOutput']('output',_0x3bb339['BasedOnInput']),_0x49a253['_outputs'][0x0]['_typeConnectionSource']=_0x49a253['_inputs'][0x0],_0x49a253;}return Object(_0x18e13d['d'])(_0x555379,_0x88ba4c),_0x555379['prototype']['getClassName']=function(){return'NegateBlock';},Object['defineProperty'](_0x555379['prototype'],'value',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x555379['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x555379['prototype']['_buildBlock']=function(_0x2f8367){_0x88ba4c['prototype']['_buildBlock']['call'](this,_0x2f8367);var _0x58bf87=this['_outputs'][0x0];return _0x2f8367['compilationString']+=this['_declareOutput'](_0x58bf87,_0x2f8367)+'\x20=\x20-1.0\x20*\x20'+this['value']['associatedVariableName']+';\x0d\x0a',this;},_0x555379;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.NegateBlock']=_0x567545;var _0x49ea90=function(_0x2f995c){function _0x5949b0(_0x1abeca){var _0x16952d=_0x2f995c['call'](this,_0x1abeca,_0x4e54a1['Neutral'])||this;return _0x16952d['registerInput']('value',_0x3bb339['AutoDetect']),_0x16952d['registerInput']('power',_0x3bb339['AutoDetect']),_0x16952d['registerOutput']('output',_0x3bb339['BasedOnInput']),_0x16952d['_outputs'][0x0]['_typeConnectionSource']=_0x16952d['_inputs'][0x0],_0x16952d['_linkConnectionTypes'](0x0,0x1),_0x16952d;}return Object(_0x18e13d['d'])(_0x5949b0,_0x2f995c),_0x5949b0['prototype']['getClassName']=function(){return'PowBlock';},Object['defineProperty'](_0x5949b0['prototype'],'value',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5949b0['prototype'],'power',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5949b0['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x5949b0['prototype']['_buildBlock']=function(_0x2b5851){_0x2f995c['prototype']['_buildBlock']['call'](this,_0x2b5851);var _0x2a0e9b=this['_outputs'][0x0];return _0x2b5851['compilationString']+=this['_declareOutput'](_0x2a0e9b,_0x2b5851)+'\x20=\x20pow('+this['value']['associatedVariableName']+',\x20'+this['power']['associatedVariableName']+');\x0d\x0a',this;},_0x5949b0;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.PowBlock']=_0x49ea90;var _0x1cb448=function(_0x1cfa26){function _0x230468(_0x29e545){var _0x367967=_0x1cfa26['call'](this,_0x29e545,_0x4e54a1['Neutral'])||this;return _0x367967['registerInput']('seed',_0x3bb339['Vector2']),_0x367967['registerOutput']('output',_0x3bb339['Float']),_0x367967['_inputs'][0x0]['acceptedConnectionPointTypes']['push'](_0x3bb339['Vector3']),_0x367967['_inputs'][0x0]['acceptedConnectionPointTypes']['push'](_0x3bb339['Vector4']),_0x367967['_inputs'][0x0]['acceptedConnectionPointTypes']['push'](_0x3bb339['Color3']),_0x367967['_inputs'][0x0]['acceptedConnectionPointTypes']['push'](_0x3bb339['Color4']),_0x367967;}return Object(_0x18e13d['d'])(_0x230468,_0x1cfa26),_0x230468['prototype']['getClassName']=function(){return'RandomNumberBlock';},Object['defineProperty'](_0x230468['prototype'],'seed',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x230468['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x230468['prototype']['_buildBlock']=function(_0x215f73){_0x1cfa26['prototype']['_buildBlock']['call'](this,_0x215f73);var _0x3ecc27=this['_outputs'][0x0],_0x2f05cc='//'+this['name'];return _0x215f73['_emitFunctionFromInclude']('helperFunctions',_0x2f05cc),_0x215f73['compilationString']+=this['_declareOutput'](_0x3ecc27,_0x215f73)+'\x20=\x20getRand('+this['seed']['associatedVariableName']+'.xy);\x0d\x0a',this;},_0x230468;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.RandomNumberBlock']=_0x1cb448;var _0x4dcf7e=function(_0x53fd8a){function _0x1588be(_0x52f582){var _0x5cf855=_0x53fd8a['call'](this,_0x52f582,_0x4e54a1['Neutral'])||this;return _0x5cf855['registerInput']('x',_0x3bb339['Float']),_0x5cf855['registerInput']('y',_0x3bb339['Float']),_0x5cf855['registerOutput']('output',_0x3bb339['Float']),_0x5cf855;}return Object(_0x18e13d['d'])(_0x1588be,_0x53fd8a),_0x1588be['prototype']['getClassName']=function(){return'ArcTan2Block';},Object['defineProperty'](_0x1588be['prototype'],'x',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1588be['prototype'],'y',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x1588be['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x1588be['prototype']['_buildBlock']=function(_0x32e12e){_0x53fd8a['prototype']['_buildBlock']['call'](this,_0x32e12e);var _0x7250f8=this['_outputs'][0x0];return _0x32e12e['compilationString']+=this['_declareOutput'](_0x7250f8,_0x32e12e)+'\x20=\x20atan('+this['x']['associatedVariableName']+',\x20'+this['y']['associatedVariableName']+');\x0d\x0a',this;},_0x1588be;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.ArcTan2Block']=_0x4dcf7e;var _0x37b2a8=function(_0x128c2d){function _0x5e7ddd(_0x63f188){var _0x5ce8ee=_0x128c2d['call'](this,_0x63f188,_0x4e54a1['Neutral'])||this;return _0x5ce8ee['registerInput']('value',_0x3bb339['AutoDetect']),_0x5ce8ee['registerInput']('edge0',_0x3bb339['Float']),_0x5ce8ee['registerInput']('edge1',_0x3bb339['Float']),_0x5ce8ee['registerOutput']('output',_0x3bb339['BasedOnInput']),_0x5ce8ee['_outputs'][0x0]['_typeConnectionSource']=_0x5ce8ee['_inputs'][0x0],_0x5ce8ee;}return Object(_0x18e13d['d'])(_0x5e7ddd,_0x128c2d),_0x5e7ddd['prototype']['getClassName']=function(){return'SmoothStepBlock';},Object['defineProperty'](_0x5e7ddd['prototype'],'value',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5e7ddd['prototype'],'edge0',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5e7ddd['prototype'],'edge1',{'get':function(){return this['_inputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5e7ddd['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x5e7ddd['prototype']['_buildBlock']=function(_0x2860a2){_0x128c2d['prototype']['_buildBlock']['call'](this,_0x2860a2);var _0x2c8672=this['_outputs'][0x0];return _0x2860a2['compilationString']+=this['_declareOutput'](_0x2c8672,_0x2860a2)+'\x20=\x20smoothstep('+this['edge0']['associatedVariableName']+',\x20'+this['edge1']['associatedVariableName']+',\x20'+this['value']['associatedVariableName']+');\x0d\x0a',this;},_0x5e7ddd;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.SmoothStepBlock']=_0x37b2a8;var _0x4a9bbf=function(_0x17ca93){function _0x19c87e(_0x50e3b8){var _0x1acac0=_0x17ca93['call'](this,_0x50e3b8,_0x4e54a1['Neutral'])||this;return _0x1acac0['registerInput']('input',_0x3bb339['AutoDetect']),_0x1acac0['registerOutput']('output',_0x3bb339['BasedOnInput']),_0x1acac0['_outputs'][0x0]['_typeConnectionSource']=_0x1acac0['_inputs'][0x0],_0x1acac0['_outputs'][0x0]['excludedConnectionPointTypes']['push'](_0x3bb339['Matrix']),_0x1acac0;}return Object(_0x18e13d['d'])(_0x19c87e,_0x17ca93),_0x19c87e['prototype']['getClassName']=function(){return'ReciprocalBlock';},Object['defineProperty'](_0x19c87e['prototype'],'input',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x19c87e['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x19c87e['prototype']['_buildBlock']=function(_0x3ac2fb){_0x17ca93['prototype']['_buildBlock']['call'](this,_0x3ac2fb);var _0x2c16ed=this['_outputs'][0x0];return _0x3ac2fb['compilationString']+=this['_declareOutput'](_0x2c16ed,_0x3ac2fb)+'\x20=\x201.\x20/\x20'+this['input']['associatedVariableName']+';\x0d\x0a',this;},_0x19c87e;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.ReciprocalBlock']=_0x4a9bbf;var _0x30500a=function(_0x23c758){function _0x3e6c9b(_0x1dff2e){var _0x414e9e=_0x23c758['call'](this,_0x1dff2e,_0x4e54a1['Neutral'])||this;return _0x414e9e['registerInput']('value',_0x3bb339['AutoDetect']),_0x414e9e['registerInput']('reference',_0x3bb339['AutoDetect']),_0x414e9e['registerInput']('distance',_0x3bb339['Float']),_0x414e9e['registerInput']('replacement',_0x3bb339['AutoDetect']),_0x414e9e['registerOutput']('output',_0x3bb339['BasedOnInput']),_0x414e9e['_outputs'][0x0]['_typeConnectionSource']=_0x414e9e['_inputs'][0x0],_0x414e9e['_linkConnectionTypes'](0x0,0x1),_0x414e9e['_linkConnectionTypes'](0x0,0x3),_0x414e9e['_inputs'][0x0]['excludedConnectionPointTypes']['push'](_0x3bb339['Float']),_0x414e9e['_inputs'][0x0]['excludedConnectionPointTypes']['push'](_0x3bb339['Matrix']),_0x414e9e['_inputs'][0x1]['excludedConnectionPointTypes']['push'](_0x3bb339['Float']),_0x414e9e['_inputs'][0x1]['excludedConnectionPointTypes']['push'](_0x3bb339['Matrix']),_0x414e9e['_inputs'][0x3]['excludedConnectionPointTypes']['push'](_0x3bb339['Float']),_0x414e9e['_inputs'][0x3]['excludedConnectionPointTypes']['push'](_0x3bb339['Matrix']),_0x414e9e;}return Object(_0x18e13d['d'])(_0x3e6c9b,_0x23c758),_0x3e6c9b['prototype']['getClassName']=function(){return'ReplaceColorBlock';},Object['defineProperty'](_0x3e6c9b['prototype'],'value',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3e6c9b['prototype'],'reference',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3e6c9b['prototype'],'distance',{'get':function(){return this['_inputs'][0x2];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3e6c9b['prototype'],'replacement',{'get':function(){return this['_inputs'][0x3];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3e6c9b['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x3e6c9b['prototype']['_buildBlock']=function(_0x36fe8e){_0x23c758['prototype']['_buildBlock']['call'](this,_0x36fe8e);var _0x1578f0=this['_outputs'][0x0];return _0x36fe8e['compilationString']+=this['_declareOutput'](_0x1578f0,_0x36fe8e)+';\x0d\x0a',_0x36fe8e['compilationString']+='if\x20(length('+this['value']['associatedVariableName']+'\x20-\x20'+this['reference']['associatedVariableName']+')\x20<\x20'+this['distance']['associatedVariableName']+')\x20{\x0d\x0a',_0x36fe8e['compilationString']+=_0x1578f0['associatedVariableName']+'\x20=\x20'+this['replacement']['associatedVariableName']+';\x0d\x0a',_0x36fe8e['compilationString']+='}\x20else\x20{\x0d\x0a',_0x36fe8e['compilationString']+=_0x1578f0['associatedVariableName']+'\x20=\x20'+this['value']['associatedVariableName']+';\x0d\x0a',_0x36fe8e['compilationString']+='}\x0d\x0a',this;},_0x3e6c9b;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.ReplaceColorBlock']=_0x30500a;var _0x377874,_0x3ab45d=function(_0x4108d9){function _0x2fbe1c(_0x5be7ed){var _0x40974a=_0x4108d9['call'](this,_0x5be7ed,_0x4e54a1['Neutral'])||this;return _0x40974a['registerInput']('value',_0x3bb339['AutoDetect']),_0x40974a['registerInput']('steps',_0x3bb339['AutoDetect']),_0x40974a['registerOutput']('output',_0x3bb339['BasedOnInput']),_0x40974a['_outputs'][0x0]['_typeConnectionSource']=_0x40974a['_inputs'][0x0],_0x40974a['_linkConnectionTypes'](0x0,0x1),_0x40974a['_inputs'][0x0]['excludedConnectionPointTypes']['push'](_0x3bb339['Matrix']),_0x40974a['_inputs'][0x1]['excludedConnectionPointTypes']['push'](_0x3bb339['Matrix']),_0x40974a;}return Object(_0x18e13d['d'])(_0x2fbe1c,_0x4108d9),_0x2fbe1c['prototype']['getClassName']=function(){return'PosterizeBlock';},Object['defineProperty'](_0x2fbe1c['prototype'],'value',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2fbe1c['prototype'],'steps',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2fbe1c['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x2fbe1c['prototype']['_buildBlock']=function(_0x4bdb52){_0x4108d9['prototype']['_buildBlock']['call'](this,_0x4bdb52);var _0x2881d4=this['_outputs'][0x0];return _0x4bdb52['compilationString']+=this['_declareOutput'](_0x2881d4,_0x4bdb52)+'\x20=\x20floor('+this['value']['associatedVariableName']+'\x20/\x20(1.0\x20/\x20'+this['steps']['associatedVariableName']+'))\x20*\x20(1.0\x20/\x20'+this['steps']['associatedVariableName']+');\x0d\x0a',this;},_0x2fbe1c;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.PosterizeBlock']=_0x3ab45d,function(_0x5f5204){_0x5f5204[_0x5f5204['SawTooth']=0x0]='SawTooth',_0x5f5204[_0x5f5204['Square']=0x1]='Square',_0x5f5204[_0x5f5204['Triangle']=0x2]='Triangle';}(_0x377874||(_0x377874={}));var _0xe1c3a7=function(_0x2aaac8){function _0x18fca0(_0x286096){var _0x5ea781=_0x2aaac8['call'](this,_0x286096,_0x4e54a1['Neutral'])||this;return _0x5ea781['kind']=_0x377874['SawTooth'],_0x5ea781['registerInput']('input',_0x3bb339['AutoDetect']),_0x5ea781['registerOutput']('output',_0x3bb339['BasedOnInput']),_0x5ea781['_outputs'][0x0]['_typeConnectionSource']=_0x5ea781['_inputs'][0x0],_0x5ea781['_inputs'][0x0]['excludedConnectionPointTypes']['push'](_0x3bb339['Matrix']),_0x5ea781;}return Object(_0x18e13d['d'])(_0x18fca0,_0x2aaac8),_0x18fca0['prototype']['getClassName']=function(){return'WaveBlock';},Object['defineProperty'](_0x18fca0['prototype'],'input',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x18fca0['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x18fca0['prototype']['_buildBlock']=function(_0x5391a8){_0x2aaac8['prototype']['_buildBlock']['call'](this,_0x5391a8);var _0x514d7c=this['_outputs'][0x0];switch(this['kind']){case _0x377874['SawTooth']:_0x5391a8['compilationString']+=this['_declareOutput'](_0x514d7c,_0x5391a8)+'\x20=\x20'+this['input']['associatedVariableName']+'\x20-\x20floor(0.5\x20+\x20'+this['input']['associatedVariableName']+');\x0d\x0a';break;case _0x377874['Square']:_0x5391a8['compilationString']+=this['_declareOutput'](_0x514d7c,_0x5391a8)+'\x20=\x201.0\x20-\x202.0\x20*\x20round(fract('+this['input']['associatedVariableName']+'));\x0d\x0a';break;case _0x377874['Triangle']:_0x5391a8['compilationString']+=this['_declareOutput'](_0x514d7c,_0x5391a8)+'\x20=\x202.0\x20*\x20abs(2.0\x20*\x20('+this['input']['associatedVariableName']+'\x20-\x20floor(0.5\x20+\x20'+this['input']['associatedVariableName']+')))\x20-\x201.0;\x0d\x0a';}return this;},_0x18fca0['prototype']['serialize']=function(){var _0x1f0304=_0x2aaac8['prototype']['serialize']['call'](this);return _0x1f0304['kind']=this['kind'],_0x1f0304;},_0x18fca0['prototype']['_deserialize']=function(_0x192599,_0x468954,_0x203de8){_0x2aaac8['prototype']['_deserialize']['call'](this,_0x192599,_0x468954,_0x203de8),this['kind']=_0x192599['kind'];},_0x18fca0;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.WaveBlock']=_0xe1c3a7;var _0x56d334=(function(){function _0x51e17e(_0x49e3d7,_0x2d2a5f){this['step']=_0x49e3d7,this['color']=_0x2d2a5f;}return Object['defineProperty'](_0x51e17e['prototype'],'step',{'get':function(){return this['_step'];},'set':function(_0x43dae0){this['_step']=_0x43dae0;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x51e17e['prototype'],'color',{'get':function(){return this['_color'];},'set':function(_0x6ad1a9){this['_color']=_0x6ad1a9;},'enumerable':!0x1,'configurable':!0x0}),_0x51e17e;}()),_0x3acb6e=function(_0x37a2d7){function _0x49cbfe(_0x202a22){var _0x235065=_0x37a2d7['call'](this,_0x202a22,_0x4e54a1['Neutral'])||this;return _0x235065['colorSteps']=[new _0x56d334(0x0,_0x39310d['a']['Black']()),new _0x56d334(0x1,_0x39310d['a']['White']())],_0x235065['onValueChangedObservable']=new _0x6ac1f7['c'](),_0x235065['registerInput']('gradient',_0x3bb339['Float']),_0x235065['registerOutput']('output',_0x3bb339['Color3']),_0x235065['_inputs'][0x0]['acceptedConnectionPointTypes']['push'](_0x3bb339['Vector2']),_0x235065['_inputs'][0x0]['acceptedConnectionPointTypes']['push'](_0x3bb339['Vector3']),_0x235065['_inputs'][0x0]['acceptedConnectionPointTypes']['push'](_0x3bb339['Vector4']),_0x235065['_inputs'][0x0]['acceptedConnectionPointTypes']['push'](_0x3bb339['Color3']),_0x235065['_inputs'][0x0]['acceptedConnectionPointTypes']['push'](_0x3bb339['Color4']),_0x235065;}return Object(_0x18e13d['d'])(_0x49cbfe,_0x37a2d7),_0x49cbfe['prototype']['colorStepsUpdated']=function(){this['onValueChangedObservable']['notifyObservers'](this);},_0x49cbfe['prototype']['getClassName']=function(){return'GradientBlock';},Object['defineProperty'](_0x49cbfe['prototype'],'gradient',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x49cbfe['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x49cbfe['prototype']['_writeColorConstant']=function(_0x3d61fd){var _0x1fc74a=this['colorSteps'][_0x3d61fd];return'vec3('+_0x1fc74a['color']['r']+',\x20'+_0x1fc74a['color']['g']+',\x20'+_0x1fc74a['color']['b']+')';},_0x49cbfe['prototype']['_buildBlock']=function(_0x1193eb){_0x37a2d7['prototype']['_buildBlock']['call'](this,_0x1193eb);var _0x253a8a=this['_outputs'][0x0];if(this['colorSteps']['length']&&this['gradient']['connectedPoint']){var _0x3e3226=_0x1193eb['_getFreeVariableName']('gradientTempColor'),_0x41881e=_0x1193eb['_getFreeVariableName']('gradientTempPosition');_0x1193eb['compilationString']+='vec3\x20'+_0x3e3226+'\x20=\x20'+this['_writeColorConstant'](0x0)+';\x0d\x0a',_0x1193eb['compilationString']+='float\x20'+_0x41881e+';\x0d\x0a';var _0x1a0223=this['gradient']['associatedVariableName'];this['gradient']['connectedPoint']['type']!==_0x3bb339['Float']&&(_0x1a0223+='.x');for(var _0xb48c4e=0x1;_0xb48c4e0x1?_0xd5a22e['setValue']('NUM_SAMPLES',this['realTimeFilteringQuality']+'u',!0x0):_0xd5a22e['setValue']('NUM_SAMPLES',''+this['realTimeFilteringQuality'],!0x0),_0xd5a22e['setValue']('BRDF_V_HEIGHT_CORRELATED',!0x0),_0xd5a22e['setValue']('MS_BRDF_ENERGY_CONSERVATION',this['useEnergyConservation'],!0x0),_0xd5a22e['setValue']('RADIANCEOCCLUSION',this['useRadianceOcclusion'],!0x0),_0xd5a22e['setValue']('HORIZONOCCLUSION',this['useHorizonOcclusion'],!0x0),_0xd5a22e['setValue']('UNLIT',this['unlit'],!0x0),_0xd5a22e['setValue']('FORCENORMALFORWARD',this['forceNormalForward'],!0x0),this['_environmentBRDFTexture']&&_0x4e6421['a']['ReflectionTextureEnabled']?(_0xd5a22e['setValue']('ENVIRONMENTBRDF',!0x0),_0xd5a22e['setValue']('ENVIRONMENTBRDF_RGBD',this['_environmentBRDFTexture']['isRGBD'],!0x0)):(_0xd5a22e['setValue']('ENVIRONMENTBRDF',!0x1),_0xd5a22e['setValue']('ENVIRONMENTBRDF_RGBD',!0x1)),_0xd5a22e['_areLightsDirty']){var _0x57a470=_0x2d1d91['getScene']();if(this['light']){var _0x2099a0={'needNormals':!0x1,'needRebuild':!0x1,'lightmapMode':!0x1,'shadowEnabled':!0x1,'specularEnabled':!0x1};_0x464f31['a']['PrepareDefinesForLight'](_0x57a470,_0x2d1d91,this['light'],this['_lightId'],_0xd5a22e,!0x0,_0x2099a0),_0x2099a0['needRebuild']&&_0xd5a22e['rebuild']();}else _0x464f31['a']['PrepareDefinesForLights'](_0x57a470,_0x2d1d91,_0xd5a22e,!0x0,_0x4b52e5['maxSimultaneousLights']),_0xd5a22e['_needNormals']=!0x0,_0x464f31['a']['PrepareDefinesForMultiview'](_0x57a470,_0xd5a22e);}},_0x51ce40['prototype']['updateUniformsAndSamples']=function(_0x31b42e,_0x4eba30,_0x246c2a,_0xfb2f94){for(var _0x159468=0x0;_0x159468<_0x4eba30['maxSimultaneousLights']&&_0x246c2a['LIGHT'+_0x159468];_0x159468++){var _0x5e10ae=_0x31b42e['uniforms']['indexOf']('vLightData'+_0x159468)>=0x0;_0x464f31['a']['PrepareUniformsAndSamplersForLight'](_0x159468,_0x31b42e['uniforms'],_0x31b42e['samplers'],_0x246c2a['PROJECTEDLIGHTTEXTURE'+_0x159468],_0xfb2f94,_0x5e10ae);}},_0x51ce40['prototype']['bind']=function(_0x54c156,_0x4e1dcc,_0x5cfccb){var _0xe5233e,_0x323062;if(_0x5cfccb){var _0x35341e=_0x5cfccb['getScene']();this['light']?_0x464f31['a']['BindLight'](this['light'],this['_lightId'],_0x35341e,_0x54c156,!0x0):_0x464f31['a']['BindLights'](_0x35341e,_0x5cfccb,_0x54c156,!0x0,_0x4e1dcc['maxSimultaneousLights']),_0x54c156['setTexture'](this['_environmentBrdfSamplerName'],this['_environmentBRDFTexture']),_0x54c156['setFloat2']('vDebugMode',this['debugLimit'],this['debugFactor']);var _0x45919b=this['_scene']['ambientColor'];_0x45919b&&_0x54c156['setColor3']('ambientFromScene',_0x45919b);var _0x52bfec=_0x35341e['useRightHandedSystem']===(null!=_0x35341e['_mirroredCameraPosition']);_0x54c156['setFloat'](this['_invertNormalName'],_0x52bfec?-0x1:0x1),_0x54c156['setFloat4']('vLightingIntensity',this['directIntensity'],0x1,this['environmentIntensity']*this['_scene']['environmentIntensity'],this['specularIntensity']);var _0x1e5fa5=null!==(_0x323062=null===(_0xe5233e=this['indexOfRefraction']['connectInputBlock'])||void 0x0===_0xe5233e?void 0x0:_0xe5233e['value'])&&void 0x0!==_0x323062?_0x323062:1.5,_0x3a17e8=Math['pow']((_0x1e5fa5-0x1)/(_0x1e5fa5+0x1),0x2);this['_metallicReflectanceColor']['scaleToRef'](_0x3a17e8*this['_metallicF0Factor'],_0x39310d['c']['Color3'][0x0]);var _0x1b5dea=this['_metallicF0Factor'];_0x54c156['setColor4'](this['_vMetallicReflectanceFactorsName'],_0x39310d['c']['Color3'][0x0],_0x1b5dea);}},_0x51ce40['prototype']['_injectVertexCode']=function(_0x4612ee){var _0x29f2fe,_0xaa3498,_0x205b13=this['worldPosition'],_0x84e953='//'+this['name'];this['light']?(this['_lightId']=(void 0x0!==_0x4612ee['counters']['lightCounter']?_0x4612ee['counters']['lightCounter']:-0x1)+0x1,_0x4612ee['counters']['lightCounter']=this['_lightId'],_0x4612ee['_emitFunctionFromInclude'](_0x4612ee['supportUniformBuffers']?'lightUboDeclaration':'lightFragmentDeclaration',_0x84e953,{'replaceStrings':[{'search':/{X}/g,'replace':this['_lightId']['toString']()}]},this['_lightId']['toString']())):(_0x4612ee['_emitFunctionFromInclude'](_0x4612ee['supportUniformBuffers']?'lightUboDeclaration':'lightFragmentDeclaration',_0x84e953,{'repeatKey':'maxSimultaneousLights'}),this['_lightId']=0x0,_0x4612ee['sharedData']['dynamicUniformBlocks']['push'](this));var _0x19e908='v_'+_0x205b13['associatedVariableName'];_0x4612ee['_emitVaryingFromString'](_0x19e908,'vec4')&&(_0x4612ee['compilationString']+=_0x19e908+'\x20=\x20'+_0x205b13['associatedVariableName']+';\x0d\x0a');var _0x1ba4d2=this['reflection']['isConnected']?null===(_0x29f2fe=this['reflection']['connectedPoint'])||void 0x0===_0x29f2fe?void 0x0:_0x29f2fe['ownerBlock']:null;_0x1ba4d2&&(_0x1ba4d2['viewConnectionPoint']=this['view']),_0x4612ee['compilationString']+=null!==(_0xaa3498=null==_0x1ba4d2?void 0x0:_0x1ba4d2['handleVertexSide'](_0x4612ee))&&void 0x0!==_0xaa3498?_0xaa3498:'',_0x4612ee['_emitUniformFromString']('vDebugMode','vec2','defined(IGNORE)\x20||\x20DEBUGMODE\x20>\x200'),_0x4612ee['_emitUniformFromString']('ambientFromScene','vec3'),_0x4612ee['_emitVaryingFromString']('vClipSpacePosition','vec4','defined(IGNORE)\x20||\x20DEBUGMODE\x20>\x200')&&(_0x4612ee['_injectAtEnd']+='#if\x20DEBUGMODE\x20>\x200\x0d\x0a',_0x4612ee['_injectAtEnd']+='vClipSpacePosition\x20=\x20gl_Position;\x0d\x0a',_0x4612ee['_injectAtEnd']+='#endif\x0d\x0a'),this['light']?_0x4612ee['compilationString']+=_0x4612ee['_emitCodeFromInclude']('shadowsVertex',_0x84e953,{'replaceStrings':[{'search':/{X}/g,'replace':this['_lightId']['toString']()},{'search':/worldPos/g,'replace':_0x205b13['associatedVariableName']}]}):(_0x4612ee['compilationString']+='vec4\x20worldPos\x20=\x20'+_0x205b13['associatedVariableName']+';\x0d\x0a',this['view']['isConnected']&&(_0x4612ee['compilationString']+='mat4\x20view\x20=\x20'+this['view']['associatedVariableName']+';\x0d\x0a'),_0x4612ee['compilationString']+=_0x4612ee['_emitCodeFromInclude']('shadowsVertex',_0x84e953,{'repeatKey':'maxSimultaneousLights'}));},_0x51ce40['prototype']['_getAlbedoOpacityCode']=function(){var _0x55aeeb='albedoOpacityOutParams\x20albedoOpacityOut;\x0d\x0a';return _0x55aeeb+='albedoOpacityBlock(\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec4('+(this['baseColor']['isConnected']?this['baseColor']['associatedVariableName']:'vec3(1.)')+',\x201.),\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20ALBEDO\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec4(1.),\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec2(1.,\x201.),\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20OPACITY\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec4('+(this['opacity']['isConnected']?this['opacity']['associatedVariableName']:'1.')+'),\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec2(1.,\x201.),\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20albedoOpacityOut\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20);\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec3\x20surfaceAlbedo\x20=\x20albedoOpacityOut.surfaceAlbedo;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20float\x20alpha\x20=\x20albedoOpacityOut.alpha;\x0d\x0a';},_0x51ce40['prototype']['_getAmbientOcclusionCode']=function(){var _0x3ff6d2='ambientOcclusionOutParams\x20aoOut;\x0d\x0a';return _0x3ff6d2+='ambientOcclusionBlock(\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20AMBIENT\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec3('+(this['ambientOcc']['isConnected']?this['ambientOcc']['associatedVariableName']:'1.')+'),\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec4(0.,\x201.0,\x201.0,\x200.),\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20aoOut\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20);\x0d\x0a';},_0x51ce40['prototype']['_getReflectivityCode']=function(_0x3e876e){var _0x250196='reflectivityOutParams\x20reflectivityOut;\x0d\x0a';return this['_vMetallicReflectanceFactorsName']=_0x3e876e['_getFreeVariableName']('vMetallicReflectanceFactors'),_0x3e876e['_emitUniformFromString'](this['_vMetallicReflectanceFactorsName'],'vec4'),_0x250196+='vec3\x20baseColor\x20=\x20surfaceAlbedo;\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20reflectivityBlock(\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec4('+this['metallic']['associatedVariableName']+',\x20'+this['roughness']['associatedVariableName']+',\x200.,\x200.),\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20METALLICWORKFLOW\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20surfaceAlbedo,\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+this['_vMetallicReflectanceFactorsName']+',\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20REFLECTIVITY\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec3(0.,\x200.,\x201.),\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec4(1.),\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#if\x20defined(METALLICWORKFLOW)\x20&&\x20defined(REFLECTIVITY)\x20\x20&&\x20defined(AOSTOREINMETALMAPRED)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20aoOut.ambientOcclusionColor,\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20MICROSURFACEMAP\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20microSurfaceTexel,\x20<==\x20not\x20handled!\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20reflectivityOut\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20);\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20float\x20microSurface\x20=\x20reflectivityOut.microSurface;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20float\x20roughness\x20=\x20reflectivityOut.roughness;\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#ifdef\x20METALLICWORKFLOW\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20surfaceAlbedo\x20=\x20reflectivityOut.surfaceAlbedo;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#if\x20defined(METALLICWORKFLOW)\x20&&\x20defined(REFLECTIVITY)\x20&&\x20defined(AOSTOREINMETALMAPRED)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20aoOut.ambientOcclusionColor\x20=\x20reflectivityOut.ambientOcclusionColor;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#endif\x0d\x0a';},_0x51ce40['prototype']['_buildBlock']=function(_0x4ef28a){var _0x4df527,_0x2be68b,_0x5a06c4,_0x5b8eb8,_0x71ffc3,_0x4031cb,_0x13e5d8,_0x4de2f1,_0x7816e7,_0x371a49,_0x98517d,_0xcf5a11,_0x56f99b,_0x4b8970,_0x257f25,_0x50c110,_0x45967c,_0x1b9578,_0x1bf0d4,_0x1e8700,_0x1a32e5,_0x4e2280,_0x266fb2,_0x429ced,_0x13d623,_0x4600f1,_0x138193,_0x17ebb1,_0x159b5,_0x5a41e8,_0x1d1478,_0x427e23,_0x355d8c,_0x56d485,_0x12fd62,_0xa003fb,_0xdb67e0,_0x2004d7,_0x544ff7;_0x44631e['prototype']['_buildBlock']['call'](this,_0x4ef28a),this['_scene']=_0x4ef28a['sharedData']['scene'],this['_environmentBRDFTexture']||(this['_environmentBRDFTexture']=_0x4d5377['GetEnvironmentBRDFTexture'](this['_scene']));var _0x927b0=this['reflection']['isConnected']?null===(_0x4df527=this['reflection']['connectedPoint'])||void 0x0===_0x4df527?void 0x0:_0x4df527['ownerBlock']:null;if(_0x927b0&&(_0x927b0['worldPositionConnectionPoint']=this['worldPosition'],_0x927b0['cameraPositionConnectionPoint']=this['cameraPosition'],_0x927b0['worldNormalConnectionPoint']=this['worldNormal']),_0x4ef28a['target']!==_0x4e54a1['Fragment'])return this['_injectVertexCode'](_0x4ef28a),this;_0x4ef28a['sharedData']['bindableBlocks']['push'](this),_0x4ef28a['sharedData']['blocksWithDefines']['push'](this);var _0x15be27='//'+this['name'],_0x417a00='v_'+this['worldPosition']['associatedVariableName'],_0x42bc43=this['perturbedNormal'];this['_environmentBrdfSamplerName']=_0x4ef28a['_getFreeVariableName']('environmentBrdfSampler'),_0x4ef28a['_emit2DSampler'](this['_environmentBrdfSamplerName']),_0x4ef28a['sharedData']['hints']['needAlphaBlending']=_0x4ef28a['sharedData']['hints']['needAlphaBlending']||this['useAlphaBlending'],_0x4ef28a['sharedData']['hints']['needAlphaTesting']=_0x4ef28a['sharedData']['hints']['needAlphaTesting']||this['useAlphaTest'],_0x4ef28a['_emitExtension']('lod','#extension\x20GL_EXT_shader_texture_lod\x20:\x20enable','defined(LODBASEDMICROSFURACE)'),_0x4ef28a['_emitExtension']('derivatives','#extension\x20GL_OES_standard_derivatives\x20:\x20enable'),this['light']?_0x4ef28a['_emitFunctionFromInclude'](_0x4ef28a['supportUniformBuffers']?'lightUboDeclaration':'lightFragmentDeclaration',_0x15be27,{'replaceStrings':[{'search':/{X}/g,'replace':this['_lightId']['toString']()}]},this['_lightId']['toString']()):_0x4ef28a['_emitFunctionFromInclude'](_0x4ef28a['supportUniformBuffers']?'lightUboDeclaration':'lightFragmentDeclaration',_0x15be27,{'repeatKey':'maxSimultaneousLights'}),_0x4ef28a['_emitFunctionFromInclude']('helperFunctions',_0x15be27),_0x4ef28a['_emitFunctionFromInclude']('importanceSampling',_0x15be27),_0x4ef28a['_emitFunctionFromInclude']('pbrHelperFunctions',_0x15be27),_0x4ef28a['_emitFunctionFromInclude']('imageProcessingFunctions',_0x15be27),_0x4ef28a['_emitFunctionFromInclude']('shadowsFragmentFunctions',_0x15be27,{'replaceStrings':[{'search':/vPositionW/g,'replace':_0x417a00+'.xyz'}]}),_0x4ef28a['_emitFunctionFromInclude']('pbrDirectLightingSetupFunctions',_0x15be27,{'replaceStrings':[{'search':/vPositionW/g,'replace':_0x417a00+'.xyz'}]}),_0x4ef28a['_emitFunctionFromInclude']('pbrDirectLightingFalloffFunctions',_0x15be27),_0x4ef28a['_emitFunctionFromInclude']('pbrBRDFFunctions',_0x15be27,{'replaceStrings':[{'search':/REFLECTIONMAP_SKYBOX/g,'replace':null!==(_0x2be68b=null==_0x927b0?void 0x0:_0x927b0['_defineSkyboxName'])&&void 0x0!==_0x2be68b?_0x2be68b:'REFLECTIONMAP_SKYBOX'}]}),_0x4ef28a['_emitFunctionFromInclude']('hdrFilteringFunctions',_0x15be27),_0x4ef28a['_emitFunctionFromInclude']('pbrDirectLightingFunctions',_0x15be27,{'replaceStrings':[{'search':/vPositionW/g,'replace':_0x417a00+'.xyz'}]}),_0x4ef28a['_emitFunctionFromInclude']('pbrIBLFunctions',_0x15be27),_0x4ef28a['_emitFunctionFromInclude']('pbrBlockAlbedoOpacity',_0x15be27),_0x4ef28a['_emitFunctionFromInclude']('pbrBlockReflectivity',_0x15be27),_0x4ef28a['_emitFunctionFromInclude']('pbrBlockAmbientOcclusion',_0x15be27),_0x4ef28a['_emitFunctionFromInclude']('pbrBlockAlphaFresnel',_0x15be27),_0x4ef28a['_emitFunctionFromInclude']('pbrBlockAnisotropic',_0x15be27),_0x4ef28a['_emitUniformFromString']('vLightingIntensity','vec4'),this['_vNormalWName']=_0x4ef28a['_getFreeVariableName']('vNormalW'),_0x4ef28a['compilationString']+='vec4\x20'+this['_vNormalWName']+'\x20=\x20normalize('+this['worldNormal']['associatedVariableName']+');\x0d\x0a',_0x4ef28a['_registerTempVariable']('viewDirectionW')&&(_0x4ef28a['compilationString']+='vec3\x20viewDirectionW\x20=\x20normalize('+this['cameraPosition']['associatedVariableName']+'\x20-\x20'+_0x417a00+'.xyz);\x0d\x0a'),_0x4ef28a['compilationString']+='vec3\x20geometricNormalW\x20=\x20'+this['_vNormalWName']+'.xyz;\x0d\x0a',_0x4ef28a['compilationString']+='vec3\x20normalW\x20=\x20'+(_0x42bc43['isConnected']?'normalize('+_0x42bc43['associatedVariableName']+'.xyz)':'geometricNormalW')+';\x0d\x0a',this['_invertNormalName']=_0x4ef28a['_getFreeVariableName']('invertNormal'),_0x4ef28a['_emitUniformFromString'](this['_invertNormalName'],'float'),_0x4ef28a['compilationString']+=_0x4ef28a['_emitCodeFromInclude']('pbrBlockNormalFinal',_0x15be27,{'replaceStrings':[{'search':/vPositionW/g,'replace':_0x417a00+'.xyz'},{'search':/vEyePosition.w/g,'replace':this['_invertNormalName']}]}),_0x4ef28a['compilationString']+=this['_getAlbedoOpacityCode'](),_0x4ef28a['compilationString']+=_0x4ef28a['_emitCodeFromInclude']('depthPrePass',_0x15be27),_0x4ef28a['compilationString']+=this['_getAmbientOcclusionCode'](),_0x4ef28a['compilationString']+=_0x4ef28a['_emitCodeFromInclude']('pbrBlockLightmapInit',_0x15be27),_0x4ef28a['compilationString']+='#ifdef\x20UNLIT\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec3\x20diffuseBase\x20=\x20vec3(1.,\x201.,\x201.);\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#else\x0d\x0a',_0x4ef28a['compilationString']+=this['_getReflectivityCode'](_0x4ef28a),_0x4ef28a['compilationString']+=_0x4ef28a['_emitCodeFromInclude']('pbrBlockGeometryInfo',_0x15be27,{'replaceStrings':[{'search':/REFLECTIONMAP_SKYBOX/g,'replace':null!==(_0x5a06c4=null==_0x927b0?void 0x0:_0x927b0['_defineSkyboxName'])&&void 0x0!==_0x5a06c4?_0x5a06c4:'REFLECTIONMAP_SKYBOX'},{'search':/REFLECTIONMAP_3D/g,'replace':null!==(_0x5b8eb8=null==_0x927b0?void 0x0:_0x927b0['_define3DName'])&&void 0x0!==_0x5b8eb8?_0x5b8eb8:'REFLECTIONMAP_3D'}]});var _0x22bbd6=this['anisotropy']['isConnected']?null===(_0x71ffc3=this['anisotropy']['connectedPoint'])||void 0x0===_0x71ffc3?void 0x0:_0x71ffc3['ownerBlock']:null;_0x22bbd6&&(_0x22bbd6['worldPositionConnectionPoint']=this['worldPosition'],_0x22bbd6['worldNormalConnectionPoint']=this['worldNormal'],_0x4ef28a['compilationString']+=_0x22bbd6['getCode'](_0x4ef28a,!this['perturbedNormal']['isConnected'])),_0x927b0&&_0x927b0['hasTexture']&&(_0x4ef28a['compilationString']+=_0x927b0['getCode'](_0x4ef28a,_0x22bbd6?'anisotropicOut.anisotropicNormal':'normalW')),_0x4ef28a['_emitFunctionFromInclude']('pbrBlockReflection',_0x15be27,{'replaceStrings':[{'search':/computeReflectionCoords/g,'replace':'computeReflectionCoordsPBR'},{'search':/REFLECTIONMAP_3D/g,'replace':null!==(_0x4031cb=null==_0x927b0?void 0x0:_0x927b0['_define3DName'])&&void 0x0!==_0x4031cb?_0x4031cb:'REFLECTIONMAP_3D'},{'search':/REFLECTIONMAP_OPPOSITEZ/g,'replace':null!==(_0x13e5d8=null==_0x927b0?void 0x0:_0x927b0['_defineOppositeZ'])&&void 0x0!==_0x13e5d8?_0x13e5d8:'REFLECTIONMAP_OPPOSITEZ'},{'search':/REFLECTIONMAP_PROJECTION/g,'replace':null!==(_0x4de2f1=null==_0x927b0?void 0x0:_0x927b0['_defineProjectionName'])&&void 0x0!==_0x4de2f1?_0x4de2f1:'REFLECTIONMAP_PROJECTION'},{'search':/REFLECTIONMAP_SKYBOX/g,'replace':null!==(_0x7816e7=null==_0x927b0?void 0x0:_0x927b0['_defineSkyboxName'])&&void 0x0!==_0x7816e7?_0x7816e7:'REFLECTIONMAP_SKYBOX'},{'search':/LODINREFLECTIONALPHA/g,'replace':null!==(_0x371a49=null==_0x927b0?void 0x0:_0x927b0['_defineLODReflectionAlpha'])&&void 0x0!==_0x371a49?_0x371a49:'LODINREFLECTIONALPHA'},{'search':/LINEARSPECULARREFLECTION/g,'replace':null!==(_0x98517d=null==_0x927b0?void 0x0:_0x927b0['_defineLinearSpecularReflection'])&&void 0x0!==_0x98517d?_0x98517d:'LINEARSPECULARREFLECTION'},{'search':/vReflectionFilteringInfo/g,'replace':null!==(_0xcf5a11=null==_0x927b0?void 0x0:_0x927b0['_vReflectionFilteringInfoName'])&&void 0x0!==_0xcf5a11?_0xcf5a11:'vReflectionFilteringInfo'}]}),_0x4ef28a['compilationString']+=_0x4ef28a['_emitCodeFromInclude']('pbrBlockReflectance0',_0x15be27,{'replaceStrings':[{'search':/metallicReflectanceFactors/g,'replace':this['_vMetallicReflectanceFactorsName']}]});var _0x31d92a=this['sheen']['isConnected']?null===(_0x56f99b=this['sheen']['connectedPoint'])||void 0x0===_0x56f99b?void 0x0:_0x56f99b['ownerBlock']:null;_0x31d92a&&(_0x4ef28a['compilationString']+=_0x31d92a['getCode'](_0x927b0)),_0x4ef28a['_emitFunctionFromInclude']('pbrBlockSheen',_0x15be27,{'replaceStrings':[{'search':/REFLECTIONMAP_3D/g,'replace':null!==(_0x4b8970=null==_0x927b0?void 0x0:_0x927b0['_define3DName'])&&void 0x0!==_0x4b8970?_0x4b8970:'REFLECTIONMAP_3D'},{'search':/REFLECTIONMAP_SKYBOX/g,'replace':null!==(_0x257f25=null==_0x927b0?void 0x0:_0x927b0['_defineSkyboxName'])&&void 0x0!==_0x257f25?_0x257f25:'REFLECTIONMAP_SKYBOX'},{'search':/LODINREFLECTIONALPHA/g,'replace':null!==(_0x50c110=null==_0x927b0?void 0x0:_0x927b0['_defineLODReflectionAlpha'])&&void 0x0!==_0x50c110?_0x50c110:'LODINREFLECTIONALPHA'},{'search':/LINEARSPECULARREFLECTION/g,'replace':null!==(_0x45967c=null==_0x927b0?void 0x0:_0x927b0['_defineLinearSpecularReflection'])&&void 0x0!==_0x45967c?_0x45967c:'LINEARSPECULARREFLECTION'}]});var _0x5cea2b=this['clearcoat']['isConnected']?null===(_0x1b9578=this['clearcoat']['connectedPoint'])||void 0x0===_0x1b9578?void 0x0:_0x1b9578['ownerBlock']:null,_0x3bef28=!this['perturbedNormal']['isConnected']&&!this['anisotropy']['isConnected'],_0x30dfb3=this['perturbedNormal']['isConnected']&&(null===(_0x1bf0d4=this['perturbedNormal']['connectedPoint'])||void 0x0===_0x1bf0d4?void 0x0:_0x1bf0d4['ownerBlock'])['worldTangent']['isConnected'],_0x3b142d=this['anisotropy']['isConnected']&&(null===(_0x1e8700=this['anisotropy']['connectedPoint'])||void 0x0===_0x1e8700?void 0x0:_0x1e8700['ownerBlock'])['worldTangent']['isConnected'],_0x3ab6e7=_0x30dfb3||!this['perturbedNormal']['isConnected']&&_0x3b142d;_0x4ef28a['compilationString']+=_0x487217['GetCode'](_0x4ef28a,_0x5cea2b,_0x927b0,_0x417a00,_0x3bef28,_0x3ab6e7,this['worldNormal']['associatedVariableName']),_0x3bef28&&(_0x3ab6e7=null!==(_0x1a32e5=null==_0x5cea2b?void 0x0:_0x5cea2b['worldTangent']['isConnected'])&&void 0x0!==_0x1a32e5&&_0x1a32e5),_0x4ef28a['_emitFunctionFromInclude']('pbrBlockClearcoat',_0x15be27,{'replaceStrings':[{'search':/computeReflectionCoords/g,'replace':'computeReflectionCoordsPBR'},{'search':/REFLECTIONMAP_3D/g,'replace':null!==(_0x4e2280=null==_0x927b0?void 0x0:_0x927b0['_define3DName'])&&void 0x0!==_0x4e2280?_0x4e2280:'REFLECTIONMAP_3D'},{'search':/REFLECTIONMAP_OPPOSITEZ/g,'replace':null!==(_0x266fb2=null==_0x927b0?void 0x0:_0x927b0['_defineOppositeZ'])&&void 0x0!==_0x266fb2?_0x266fb2:'REFLECTIONMAP_OPPOSITEZ'},{'search':/REFLECTIONMAP_PROJECTION/g,'replace':null!==(_0x429ced=null==_0x927b0?void 0x0:_0x927b0['_defineProjectionName'])&&void 0x0!==_0x429ced?_0x429ced:'REFLECTIONMAP_PROJECTION'},{'search':/REFLECTIONMAP_SKYBOX/g,'replace':null!==(_0x13d623=null==_0x927b0?void 0x0:_0x927b0['_defineSkyboxName'])&&void 0x0!==_0x13d623?_0x13d623:'REFLECTIONMAP_SKYBOX'},{'search':/LODINREFLECTIONALPHA/g,'replace':null!==(_0x4600f1=null==_0x927b0?void 0x0:_0x927b0['_defineLODReflectionAlpha'])&&void 0x0!==_0x4600f1?_0x4600f1:'LODINREFLECTIONALPHA'},{'search':/LINEARSPECULARREFLECTION/g,'replace':null!==(_0x138193=null==_0x927b0?void 0x0:_0x927b0['_defineLinearSpecularReflection'])&&void 0x0!==_0x138193?_0x138193:'LINEARSPECULARREFLECTION'},{'search':/defined\(TANGENT\)/g,'replace':_0x3ab6e7?'defined(TANGENT)':'defined(IGNORE)'}]}),_0x4ef28a['compilationString']+=_0x4ef28a['_emitCodeFromInclude']('pbrBlockReflectance',_0x15be27,{'replaceStrings':[{'search':/REFLECTIONMAP_SKYBOX/g,'replace':null!==(_0x17ebb1=null==_0x927b0?void 0x0:_0x927b0['_defineSkyboxName'])&&void 0x0!==_0x17ebb1?_0x17ebb1:'REFLECTIONMAP_SKYBOX'},{'search':/REFLECTIONMAP_3D/g,'replace':null!==(_0x159b5=null==_0x927b0?void 0x0:_0x927b0['_define3DName'])&&void 0x0!==_0x159b5?_0x159b5:'REFLECTIONMAP_3D'}]});var _0x47b967=this['subsurface']['isConnected']?null===(_0x5a41e8=this['subsurface']['connectedPoint'])||void 0x0===_0x5a41e8?void 0x0:_0x5a41e8['ownerBlock']:null,_0x3e771d=this['subsurface']['isConnected']?null===(_0x427e23=(null===(_0x1d1478=this['subsurface']['connectedPoint'])||void 0x0===_0x1d1478?void 0x0:_0x1d1478['ownerBlock'])['refraction']['connectedPoint'])||void 0x0===_0x427e23?void 0x0:_0x427e23['ownerBlock']:null;_0x3e771d&&(_0x3e771d['viewConnectionPoint']=this['view'],_0x3e771d['indexOfRefractionConnectionPoint']=this['indexOfRefraction']),_0x4ef28a['compilationString']+=_0xc68b25['GetCode'](_0x4ef28a,_0x47b967,_0x927b0,_0x417a00),_0x4ef28a['_emitFunctionFromInclude']('pbrBlockSubSurface',_0x15be27,{'replaceStrings':[{'search':/REFLECTIONMAP_3D/g,'replace':null!==(_0x355d8c=null==_0x927b0?void 0x0:_0x927b0['_define3DName'])&&void 0x0!==_0x355d8c?_0x355d8c:'REFLECTIONMAP_3D'},{'search':/REFLECTIONMAP_OPPOSITEZ/g,'replace':null!==(_0x56d485=null==_0x927b0?void 0x0:_0x927b0['_defineOppositeZ'])&&void 0x0!==_0x56d485?_0x56d485:'REFLECTIONMAP_OPPOSITEZ'},{'search':/REFLECTIONMAP_PROJECTION/g,'replace':null!==(_0x12fd62=null==_0x927b0?void 0x0:_0x927b0['_defineProjectionName'])&&void 0x0!==_0x12fd62?_0x12fd62:'REFLECTIONMAP_PROJECTION'},{'search':/SS_REFRACTIONMAP_3D/g,'replace':null!==(_0xa003fb=null==_0x3e771d?void 0x0:_0x3e771d['_define3DName'])&&void 0x0!==_0xa003fb?_0xa003fb:'SS_REFRACTIONMAP_3D'},{'search':/SS_LODINREFRACTIONALPHA/g,'replace':null!==(_0xdb67e0=null==_0x3e771d?void 0x0:_0x3e771d['_defineLODRefractionAlpha'])&&void 0x0!==_0xdb67e0?_0xdb67e0:'SS_LODINREFRACTIONALPHA'},{'search':/SS_LINEARSPECULARREFRACTION/g,'replace':null!==(_0x2004d7=null==_0x3e771d?void 0x0:_0x3e771d['_defineLinearSpecularRefraction'])&&void 0x0!==_0x2004d7?_0x2004d7:'SS_LINEARSPECULARREFRACTION'},{'search':/SS_REFRACTIONMAP_OPPOSITEZ/g,'replace':null!==(_0x544ff7=null==_0x3e771d?void 0x0:_0x3e771d['_defineOppositeZ'])&&void 0x0!==_0x544ff7?_0x544ff7:'SS_REFRACTIONMAP_OPPOSITEZ'}]}),_0x4ef28a['compilationString']+=_0x4ef28a['_emitCodeFromInclude']('pbrBlockDirectLighting',_0x15be27),this['light']?_0x4ef28a['compilationString']+=_0x4ef28a['_emitCodeFromInclude']('lightFragment',_0x15be27,{'replaceStrings':[{'search':/{X}/g,'replace':this['_lightId']['toString']()}]}):_0x4ef28a['compilationString']+=_0x4ef28a['_emitCodeFromInclude']('lightFragment',_0x15be27,{'repeatKey':'maxSimultaneousLights'}),_0x4ef28a['compilationString']+=_0x4ef28a['_emitCodeFromInclude']('pbrBlockFinalLitComponents',_0x15be27),_0x4ef28a['compilationString']+='#endif\x0d\x0a';var _0x5293fb=this['ambientColor']['isConnected']?this['ambientColor']['associatedVariableName']:'vec3(0.,\x200.,\x200.)',_0x4d6765=_0x136113['DEFAULT_AO_ON_ANALYTICAL_LIGHTS']['toString']();-0x1===_0x4d6765['indexOf']('.')&&(_0x4d6765+='.'),_0x4ef28a['compilationString']+=_0x4ef28a['_emitCodeFromInclude']('pbrBlockFinalUnlitComponents',_0x15be27,{'replaceStrings':[{'search':/vec3 finalEmissive[\s\S]*?finalEmissive\*=vLightingIntensity\.y;/g,'replace':''},{'search':/vAmbientColor/g,'replace':_0x5293fb+'\x20*\x20ambientFromScene'},{'search':/vAmbientInfos\.w/g,'replace':_0x4d6765}]}),_0x4ef28a['compilationString']+=_0x4ef28a['_emitCodeFromInclude']('pbrBlockFinalColorComposition',_0x15be27,{'replaceStrings':[{'search':/finalEmissive/g,'replace':'vec3(0.)'}]}),_0x4ef28a['compilationString']+=_0x4ef28a['_emitCodeFromInclude']('pbrBlockImageProcessing',_0x15be27,{'replaceStrings':[{'search':/visibility/g,'replace':'1.'}]}),_0x4ef28a['compilationString']+=_0x4ef28a['_emitCodeFromInclude']('pbrDebug',_0x15be27,{'replaceStrings':[{'search':/vNormalW/g,'replace':this['_vNormalWName']},{'search':/vPositionW/g,'replace':_0x417a00},{'search':/albedoTexture\.rgb;/g,'replace':'vec3(1.);\x0d\x0agl_FragColor.rgb\x20=\x20toGammaSpace(gl_FragColor.rgb);\x0d\x0a'}]});for(var _0x7fd545=0x0,_0x263f89=this['_outputs'];_0x7fd545<_0x263f89['length'];_0x7fd545++){var _0x2050c5=_0x263f89[_0x7fd545];if(_0x2050c5['hasEndpoints']){var _0x19e7cb=_0x28e067[_0x2050c5['name']];if(_0x19e7cb){var _0x15e982=_0x19e7cb[0x0],_0x2e5db2=_0x19e7cb[0x1];_0x2e5db2&&(_0x4ef28a['compilationString']+='#if\x20'+_0x2e5db2+'\x0d\x0a'),_0x4ef28a['compilationString']+=this['_declareOutput'](_0x2050c5,_0x4ef28a)+'\x20=\x20'+_0x15e982+';\x0d\x0a',_0x2e5db2&&(_0x4ef28a['compilationString']+='#else\x0d\x0a',_0x4ef28a['compilationString']+=this['_declareOutput'](_0x2050c5,_0x4ef28a)+'\x20=\x20vec3(0.);\x0d\x0a',_0x4ef28a['compilationString']+='#endif\x0d\x0a');}else console['error']('There\x27s\x20no\x20remapping\x20for\x20the\x20'+_0x2050c5['name']+'\x20end\x20point!\x20No\x20code\x20generated');}}return this;},_0x51ce40['prototype']['_dumpPropertiesCode']=function(){var _0x4c53d3='';return _0x4c53d3+=this['_codeVariableName']+'.lightFalloff\x20=\x20'+this['lightFalloff']+';\x0d\x0a',_0x4c53d3+=this['_codeVariableName']+'.useAlphaTest\x20=\x20'+this['useAlphaTest']+';\x0d\x0a',_0x4c53d3+=this['_codeVariableName']+'.alphaTestCutoff\x20=\x20'+this['alphaTestCutoff']+';\x0d\x0a',_0x4c53d3+=this['_codeVariableName']+'.useAlphaBlending\x20=\x20'+this['useAlphaBlending']+';\x0d\x0a',_0x4c53d3+=this['_codeVariableName']+'.useRadianceOverAlpha\x20=\x20'+this['useRadianceOverAlpha']+';\x0d\x0a',_0x4c53d3+=this['_codeVariableName']+'.useSpecularOverAlpha\x20=\x20'+this['useSpecularOverAlpha']+';\x0d\x0a',_0x4c53d3+=this['_codeVariableName']+'.enableSpecularAntiAliasing\x20=\x20'+this['enableSpecularAntiAliasing']+';\x0d\x0a',_0x4c53d3+=this['_codeVariableName']+'.realTimeFiltering\x20=\x20'+this['realTimeFiltering']+';\x0d\x0a',_0x4c53d3+=this['_codeVariableName']+'.realTimeFilteringQuality\x20=\x20'+this['realTimeFilteringQuality']+';\x0d\x0a',_0x4c53d3+=this['_codeVariableName']+'.useEnergyConservation\x20=\x20'+this['useEnergyConservation']+';\x0d\x0a',_0x4c53d3+=this['_codeVariableName']+'.useRadianceOcclusion\x20=\x20'+this['useRadianceOcclusion']+';\x0d\x0a',_0x4c53d3+=this['_codeVariableName']+'.useHorizonOcclusion\x20=\x20'+this['useHorizonOcclusion']+';\x0d\x0a',_0x4c53d3+=this['_codeVariableName']+'.unlit\x20=\x20'+this['unlit']+';\x0d\x0a',_0x4c53d3+=this['_codeVariableName']+'.forceNormalForward\x20=\x20'+this['forceNormalForward']+';\x0d\x0a',_0x4c53d3+=this['_codeVariableName']+'.debugMode\x20=\x20'+this['debugMode']+';\x0d\x0a',_0x4c53d3+=this['_codeVariableName']+'.debugLimit\x20=\x20'+this['debugLimit']+';\x0d\x0a',_0x4c53d3+=this['_codeVariableName']+'.debugFactor\x20=\x20'+this['debugFactor']+';\x0d\x0a';},_0x51ce40['prototype']['serialize']=function(){var _0x5c4146=_0x44631e['prototype']['serialize']['call'](this);return this['light']&&(_0x5c4146['lightId']=this['light']['id']),_0x5c4146['lightFalloff']=this['lightFalloff'],_0x5c4146['useAlphaTest']=this['useAlphaTest'],_0x5c4146['alphaTestCutoff']=this['alphaTestCutoff'],_0x5c4146['useAlphaBlending']=this['useAlphaBlending'],_0x5c4146['useRadianceOverAlpha']=this['useRadianceOverAlpha'],_0x5c4146['useSpecularOverAlpha']=this['useSpecularOverAlpha'],_0x5c4146['enableSpecularAntiAliasing']=this['enableSpecularAntiAliasing'],_0x5c4146['realTimeFiltering']=this['realTimeFiltering'],_0x5c4146['realTimeFilteringQuality']=this['realTimeFilteringQuality'],_0x5c4146['useEnergyConservation']=this['useEnergyConservation'],_0x5c4146['useRadianceOcclusion']=this['useRadianceOcclusion'],_0x5c4146['useHorizonOcclusion']=this['useHorizonOcclusion'],_0x5c4146['unlit']=this['unlit'],_0x5c4146['forceNormalForward']=this['forceNormalForward'],_0x5c4146['debugMode']=this['debugMode'],_0x5c4146['debugLimit']=this['debugLimit'],_0x5c4146['debugFactor']=this['debugFactor'],_0x5c4146;},_0x51ce40['prototype']['_deserialize']=function(_0x45cfab,_0x309fc4,_0x3e98b3){var _0x17c983,_0x14e4ea;_0x44631e['prototype']['_deserialize']['call'](this,_0x45cfab,_0x309fc4,_0x3e98b3),_0x45cfab['lightId']&&(this['light']=_0x309fc4['getLightByID'](_0x45cfab['lightId'])),this['lightFalloff']=null!==(_0x17c983=_0x45cfab['lightFalloff'])&&void 0x0!==_0x17c983?_0x17c983:0x0,this['useAlphaTest']=_0x45cfab['useAlphaTest'],this['alphaTestCutoff']=_0x45cfab['alphaTestCutoff'],this['useAlphaBlending']=_0x45cfab['useAlphaBlending'],this['useRadianceOverAlpha']=_0x45cfab['useRadianceOverAlpha'],this['useSpecularOverAlpha']=_0x45cfab['useSpecularOverAlpha'],this['enableSpecularAntiAliasing']=_0x45cfab['enableSpecularAntiAliasing'],this['realTimeFiltering']=!!_0x45cfab['realTimeFiltering'],this['realTimeFilteringQuality']=null!==(_0x14e4ea=_0x45cfab['realTimeFilteringQuality'])&&void 0x0!==_0x14e4ea?_0x14e4ea:_0x2103ba['a']['TEXTURE_FILTERING_QUALITY_LOW'],this['useEnergyConservation']=_0x45cfab['useEnergyConservation'],this['useRadianceOcclusion']=_0x45cfab['useRadianceOcclusion'],this['useHorizonOcclusion']=_0x45cfab['useHorizonOcclusion'],this['unlit']=_0x45cfab['unlit'],this['forceNormalForward']=!!_0x45cfab['forceNormalForward'],this['debugMode']=_0x45cfab['debugMode'],this['debugLimit']=_0x45cfab['debugLimit'],this['debugFactor']=_0x45cfab['debugFactor'];},Object(_0x18e13d['c'])([_0x148e9b('Direct\x20lights',_0x4bd31d['Float'],'INTENSITY',{'min':0x0,'max':0x1,'notifiers':{'update':!0x0}})],_0x51ce40['prototype'],'directIntensity',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('Environment\x20lights',_0x4bd31d['Float'],'INTENSITY',{'min':0x0,'max':0x1,'notifiers':{'update':!0x0}})],_0x51ce40['prototype'],'environmentIntensity',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('Specular\x20highlights',_0x4bd31d['Float'],'INTENSITY',{'min':0x0,'max':0x1,'notifiers':{'update':!0x0}})],_0x51ce40['prototype'],'specularIntensity',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('Light\x20falloff',_0x4bd31d['List'],'LIGHTING\x20&\x20COLORS',{'notifiers':{'update':!0x0},'options':[{'label':'Physical','value':_0x136113['LIGHTFALLOFF_PHYSICAL']},{'label':'GLTF','value':_0x136113['LIGHTFALLOFF_GLTF']},{'label':'Standard','value':_0x136113['LIGHTFALLOFF_STANDARD']}]})],_0x51ce40['prototype'],'lightFalloff',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('Alpha\x20Testing',_0x4bd31d['Boolean'],'OPACITY')],_0x51ce40['prototype'],'useAlphaTest',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('Alpha\x20CutOff',_0x4bd31d['Float'],'OPACITY',{'min':0x0,'max':0x1,'notifiers':{'update':!0x0}})],_0x51ce40['prototype'],'alphaTestCutoff',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('Alpha\x20blending',_0x4bd31d['Boolean'],'OPACITY')],_0x51ce40['prototype'],'useAlphaBlending',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('Radiance\x20over\x20alpha',_0x4bd31d['Boolean'],'RENDERING',{'notifiers':{'update':!0x0}})],_0x51ce40['prototype'],'useRadianceOverAlpha',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('Specular\x20over\x20alpha',_0x4bd31d['Boolean'],'RENDERING',{'notifiers':{'update':!0x0}})],_0x51ce40['prototype'],'useSpecularOverAlpha',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('Specular\x20anti-aliasing',_0x4bd31d['Boolean'],'RENDERING',{'notifiers':{'update':!0x0}})],_0x51ce40['prototype'],'enableSpecularAntiAliasing',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('Realtime\x20filtering',_0x4bd31d['Boolean'],'RENDERING',{'notifiers':{'update':!0x0}})],_0x51ce40['prototype'],'realTimeFiltering',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('Realtime\x20filtering\x20quality',_0x4bd31d['List'],'RENDERING',{'notifiers':{'update':!0x0},'options':[{'label':'Low','value':_0x2103ba['a']['TEXTURE_FILTERING_QUALITY_LOW']},{'label':'Medium','value':_0x2103ba['a']['TEXTURE_FILTERING_QUALITY_MEDIUM']},{'label':'High','value':_0x2103ba['a']['TEXTURE_FILTERING_QUALITY_HIGH']}]})],_0x51ce40['prototype'],'realTimeFilteringQuality',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('Energy\x20Conservation',_0x4bd31d['Boolean'],'ADVANCED',{'notifiers':{'update':!0x0}})],_0x51ce40['prototype'],'useEnergyConservation',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('Radiance\x20occlusion',_0x4bd31d['Boolean'],'ADVANCED',{'notifiers':{'update':!0x0}})],_0x51ce40['prototype'],'useRadianceOcclusion',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('Horizon\x20occlusion',_0x4bd31d['Boolean'],'ADVANCED',{'notifiers':{'update':!0x0}})],_0x51ce40['prototype'],'useHorizonOcclusion',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('Unlit',_0x4bd31d['Boolean'],'ADVANCED',{'notifiers':{'update':!0x0}})],_0x51ce40['prototype'],'unlit',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('Force\x20normal\x20forward',_0x4bd31d['Boolean'],'ADVANCED',{'notifiers':{'update':!0x0}})],_0x51ce40['prototype'],'forceNormalForward',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('Debug\x20mode',_0x4bd31d['List'],'DEBUG',{'notifiers':{'update':!0x0},'options':[{'label':'None','value':0x0},{'label':'Normalized\x20position','value':0x1},{'label':'Normals','value':0x2},{'label':'Tangents','value':0x3},{'label':'Bitangents','value':0x4},{'label':'Bump\x20Normals','value':0x5},{'label':'ClearCoat\x20Normals','value':0x8},{'label':'ClearCoat\x20Tangents','value':0x9},{'label':'ClearCoat\x20Bitangents','value':0xa},{'label':'Anisotropic\x20Normals','value':0xb},{'label':'Anisotropic\x20Tangents','value':0xc},{'label':'Anisotropic\x20Bitangents','value':0xd},{'label':'Env\x20Refraction','value':0x28},{'label':'Env\x20Reflection','value':0x29},{'label':'Env\x20Clear\x20Coat','value':0x2a},{'label':'Direct\x20Diffuse','value':0x32},{'label':'Direct\x20Specular','value':0x33},{'label':'Direct\x20Clear\x20Coat','value':0x34},{'label':'Direct\x20Sheen','value':0x35},{'label':'Env\x20Irradiance','value':0x36},{'label':'Surface\x20Albedo','value':0x3c},{'label':'Reflectance\x200','value':0x3d},{'label':'Metallic','value':0x3e},{'label':'Metallic\x20F0','value':0x47},{'label':'Roughness','value':0x3f},{'label':'AlphaG','value':0x40},{'label':'NdotV','value':0x41},{'label':'ClearCoat\x20Color','value':0x42},{'label':'ClearCoat\x20Roughness','value':0x43},{'label':'ClearCoat\x20NdotV','value':0x44},{'label':'Transmittance','value':0x45},{'label':'Refraction\x20Transmittance','value':0x46},{'label':'SEO','value':0x50},{'label':'EHO','value':0x51},{'label':'Energy\x20Factor','value':0x52},{'label':'Specular\x20Reflectance','value':0x53},{'label':'Clear\x20Coat\x20Reflectance','value':0x54},{'label':'Sheen\x20Reflectance','value':0x55},{'label':'Luminance\x20Over\x20Alpha','value':0x56},{'label':'Alpha','value':0x57}]})],_0x51ce40['prototype'],'debugMode',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('Split\x20position',_0x4bd31d['Float'],'DEBUG',{'min':-0x1,'max':0x1,'notifiers':{'update':!0x0}})],_0x51ce40['prototype'],'debugLimit',void 0x0),Object(_0x18e13d['c'])([_0x148e9b('Output\x20factor',_0x4bd31d['Float'],'DEBUG',{'min':0x0,'max':0x5,'notifiers':{'update':!0x0}})],_0x51ce40['prototype'],'debugFactor',void 0x0),_0x51ce40;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.PBRMetallicRoughnessBlock']=_0x36709a;var _0x51bca1=function(_0x3963b0){function _0x3bdea0(_0x2fd8f9){var _0x2d6b03=_0x3963b0['call'](this,_0x2fd8f9,_0x4e54a1['Neutral'])||this;return _0x2d6b03['registerInput']('left',_0x3bb339['AutoDetect']),_0x2d6b03['registerInput']('right',_0x3bb339['AutoDetect']),_0x2d6b03['registerOutput']('output',_0x3bb339['BasedOnInput']),_0x2d6b03['_outputs'][0x0]['_typeConnectionSource']=_0x2d6b03['_inputs'][0x0],_0x2d6b03['_linkConnectionTypes'](0x0,0x1),_0x2d6b03;}return Object(_0x18e13d['d'])(_0x3bdea0,_0x3963b0),_0x3bdea0['prototype']['getClassName']=function(){return'ModBlock';},Object['defineProperty'](_0x3bdea0['prototype'],'left',{'get':function(){return this['_inputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3bdea0['prototype'],'right',{'get':function(){return this['_inputs'][0x1];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3bdea0['prototype'],'output',{'get':function(){return this['_outputs'][0x0];},'enumerable':!0x1,'configurable':!0x0}),_0x3bdea0['prototype']['_buildBlock']=function(_0x2a683c){_0x3963b0['prototype']['_buildBlock']['call'](this,_0x2a683c);var _0xcc5b32=this['_outputs'][0x0];return _0x2a683c['compilationString']+=this['_declareOutput'](_0xcc5b32,_0x2a683c)+'\x20=\x20mod('+this['left']['associatedVariableName']+',\x20'+this['right']['associatedVariableName']+');\x0d\x0a',this;},_0x3bdea0;}(_0x52300e);_0x3cd573['a']['RegisteredTypes']['BABYLON.ModBlock']=_0x51bca1;var _0x6d9930=(function(){function _0x1f3510(){}return _0x1f3510['prototype']['optimize']=function(_0x3f4e92,_0x448d97){},_0x1f3510;}()),_0x41acfd=_0x162675(0x78),_0x5402c4=(function(){function _0x20bcb1(){this['mm']=new Map();}return _0x20bcb1['prototype']['get']=function(_0x268d46,_0x11f26a){var _0x4d34bf=this['mm']['get'](_0x268d46);if(void 0x0!==_0x4d34bf)return _0x4d34bf['get'](_0x11f26a);},_0x20bcb1['prototype']['set']=function(_0x3cac26,_0x6d9d5a,_0x2d524){var _0x3128b4=this['mm']['get'](_0x3cac26);void 0x0===_0x3128b4&&this['mm']['set'](_0x3cac26,_0x3128b4=new Map()),_0x3128b4['set'](_0x6d9d5a,_0x2d524);},_0x20bcb1;}()),_0x5e1309=(function(){function _0x53cd04(_0x3855e2,_0x29b49f,_0x29d360){var _0x39751d=this;this['_baseMaterial']=_0x3855e2,this['_scene']=_0x29b49f,this['_options']=_0x29d360,this['_subMeshToEffect']=new Map(),this['_subMeshToDepthEffect']=new _0x5402c4(),this['_meshes']=new Map();var _0x3ed382='NodeMaterial'===_0x3855e2['getClassName']()?'u_':'';if(_0x3ed382){this['_matriceNames']={'world':_0x3ed382+'World','view':_0x3ed382+'View','projection':_0x3ed382+'Projection','viewProjection':_0x3ed382+'ViewProjection','worldView':_0x3ed382+'WorldxView','worldViewProjection':_0x3ed382+'WorldxViewxProjection'};for(var _0x4fba0d=_0x3855e2['getInputBlocks'](),_0x1550a0=0x0;_0x1550a0<_0x4fba0d['length'];++_0x1550a0)switch(_0x4fba0d[_0x1550a0]['_systemValue']){case _0x509c82['World']:this['_matriceNames']['world']=_0x4fba0d[_0x1550a0]['associatedVariableName'];break;case _0x509c82['View']:this['_matriceNames']['view']=_0x4fba0d[_0x1550a0]['associatedVariableName'];break;case _0x509c82['Projection']:this['_matriceNames']['projection']=_0x4fba0d[_0x1550a0]['associatedVariableName'];break;case _0x509c82['ViewProjection']:this['_matriceNames']['viewProjection']=_0x4fba0d[_0x1550a0]['associatedVariableName'];break;case _0x509c82['WorldView']:this['_matriceNames']['worldView']=_0x4fba0d[_0x1550a0]['associatedVariableName'];break;case _0x509c82['WorldViewProjection']:this['_matriceNames']['worldViewProjection']=_0x4fba0d[_0x1550a0]['associatedVariableName'];}}else this['_matriceNames']={'world':_0x3ed382+'world','view':_0x3ed382+'view','projection':_0x3ed382+'projection','viewProjection':_0x3ed382+'viewProjection','worldView':_0x3ed382+'worldView','worldViewProjection':_0x3ed382+'worldViewProjection'};this['_onEffectCreatedObserver']=this['_baseMaterial']['onEffectCreatedObservable']['add'](function(_0x5e3a06){var _0x1f15a2,_0x5524ce=null===(_0x1f15a2=_0x5e3a06['subMesh'])||void 0x0===_0x1f15a2?void 0x0:_0x1f15a2['getMesh']();_0x5524ce&&!_0x39751d['_meshes']['has'](_0x5524ce)&&_0x39751d['_meshes']['set'](_0x5524ce,_0x5524ce['onDisposeObservable']['add'](function(_0x4db285){for(var _0x12e041=_0x39751d['_subMeshToEffect']['keys'](),_0x1ac873=_0x12e041['next']();!0x0!==_0x1ac873['done'];_0x1ac873=_0x12e041['next']()){var _0x2282e7=_0x1ac873['value'];(null==_0x2282e7?void 0x0:_0x2282e7['getMesh']())===_0x4db285&&(_0x39751d['_subMeshToEffect']['delete'](_0x2282e7),_0x39751d['_subMeshToDepthEffect']['mm']['delete'](_0x2282e7));}})),_0x39751d['_subMeshToEffect']['set'](_0x5e3a06['subMesh'],_0x5e3a06['effect']),_0x39751d['_subMeshToDepthEffect']['mm']['delete'](_0x5e3a06['subMesh']);});}return Object['defineProperty'](_0x53cd04['prototype'],'standalone',{'get':function(){var _0xbe351b,_0x247d20;return null!==(_0x247d20=null===(_0xbe351b=this['_options'])||void 0x0===_0xbe351b?void 0x0:_0xbe351b['standalone'])&&void 0x0!==_0x247d20&&_0x247d20;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x53cd04['prototype'],'baseMaterial',{'get':function(){return this['_baseMaterial'];},'enumerable':!0x1,'configurable':!0x0}),_0x53cd04['prototype']['getEffect']=function(_0x35886e,_0x3c6020){var _0x5379cc,_0x36b320,_0x16b900,_0x336bee,_0x8bf8d9,_0x4217ea;return null!==(_0x4217ea=null!==(_0x16b900=null===(_0x36b320=null===(_0x5379cc=this['_subMeshToDepthEffect']['mm']['get'](_0x35886e))||void 0x0===_0x5379cc?void 0x0:_0x5379cc['get'](_0x3c6020))||void 0x0===_0x36b320?void 0x0:_0x36b320['depthEffect'])&&void 0x0!==_0x16b900?_0x16b900:null===(_0x8bf8d9=null===(_0x336bee=this['_subMeshToDepthEffect']['mm']['get'](null))||void 0x0===_0x336bee?void 0x0:_0x336bee['get'](_0x3c6020))||void 0x0===_0x8bf8d9?void 0x0:_0x8bf8d9['depthEffect'])&&void 0x0!==_0x4217ea?_0x4217ea:null;},_0x53cd04['prototype']['isReadyForSubMesh']=function(_0x4ca39b,_0x478f75,_0x19615d,_0x27a9be){var _0x204854,_0x23e29b;return this['standalone']&&this['_baseMaterial']['isReadyForSubMesh'](_0x4ca39b['getMesh'](),_0x4ca39b,_0x27a9be),null!==(_0x23e29b=null===(_0x204854=this['_makeEffect'](_0x4ca39b,_0x478f75,_0x19615d))||void 0x0===_0x204854?void 0x0:_0x204854['isReady']())&&void 0x0!==_0x23e29b&&_0x23e29b;},_0x53cd04['prototype']['dispose']=function(){this['_baseMaterial']['onEffectCreatedObservable']['remove'](this['_onEffectCreatedObserver']),this['_onEffectCreatedObserver']=null;for(var _0x27e72b=this['_meshes']['entries'](),_0x39cd88=_0x27e72b['next']();!0x0!==_0x39cd88['done'];_0x39cd88=_0x27e72b['next']()){var _0xd1fe73=_0x39cd88['value'],_0x18d575=_0xd1fe73[0x0],_0x4ee00a=_0xd1fe73[0x1];_0x18d575['onDisposeObservable']['remove'](_0x4ee00a);}},_0x53cd04['prototype']['_makeEffect']=function(_0x8d3ae7,_0x5c1bad,_0x510c60){var _0x542669,_0x595205=null!==(_0x542669=this['_subMeshToEffect']['get'](_0x8d3ae7))&&void 0x0!==_0x542669?_0x542669:this['_subMeshToEffect']['get'](null);if(!_0x595205)return null;var _0x5ca9ab=this['_subMeshToDepthEffect']['get'](_0x8d3ae7,_0x510c60);_0x5ca9ab||(_0x5ca9ab={'depthEffect':null,'depthDefines':'','token':_0x41acfd['a']['RandomId']()},this['_subMeshToDepthEffect']['set'](_0x8d3ae7,_0x510c60,_0x5ca9ab));var _0x248b7c=_0x5c1bad['join']('\x0a');if(_0x5ca9ab['depthEffect']&&_0x248b7c===_0x5ca9ab['depthDefines'])return _0x5ca9ab['depthEffect'];_0x5ca9ab['depthDefines']=_0x248b7c;var _0x47a388=_0x595205['rawVertexSourceCode'],_0x5b6176=_0x595205['rawFragmentSourceCode'],_0xbae1b4=this['_options']&&this['_options']['remappedVariables']?'#include('+this['_options']['remappedVariables']['join'](',')+')':_0x494b01['a']['IncludesShadersStore']['shadowMapVertexNormalBias'],_0x248553=this['_options']&&this['_options']['remappedVariables']?'#include('+this['_options']['remappedVariables']['join'](',')+')':_0x494b01['a']['IncludesShadersStore']['shadowMapVertexMetric'],_0x499c94=this['_options']&&this['_options']['remappedVariables']?'#include('+this['_options']['remappedVariables']['join'](',')+')':_0x494b01['a']['IncludesShadersStore']['shadowMapFragmentSoftTransparentShadow'],_0x58e19e=_0x494b01['a']['IncludesShadersStore']['shadowMapFragment'];_0x47a388=(_0x47a388=-0x1!==(_0x47a388=(_0x47a388=_0x47a388['replace'](/void\s+?main/g,_0x494b01['a']['IncludesShadersStore']['shadowMapVertexDeclaration']+'\x0d\x0avoid\x20main'))['replace'](/#define SHADOWDEPTH_NORMALBIAS|#define CUSTOM_VERTEX_UPDATE_WORLDPOS/g,_0xbae1b4))['indexOf']('#define\x20SHADOWDEPTH_METRIC')?_0x47a388['replace'](/#define SHADOWDEPTH_METRIC/g,_0x248553):_0x47a388['replace'](/}\s*$/g,_0x248553+'\x0d\x0a}'))['replace'](/#define SHADER_NAME.*?\n|out vec4 glFragColor;\n/g,'');var _0x547620=_0x5b6176['indexOf']('#define\x20SHADOWDEPTH_SOFTTRANSPARENTSHADOW')>=0x0||_0x5b6176['indexOf']('#define\x20CUSTOM_FRAGMENT_BEFORE_FOG')>=0x0,_0x5c2e98=-0x1!==_0x5b6176['indexOf']('#define\x20SHADOWDEPTH_FRAGMENT'),_0x8dbed4='';_0x547620?_0x5b6176=_0x5b6176['replace'](/#define SHADOWDEPTH_SOFTTRANSPARENTSHADOW|#define CUSTOM_FRAGMENT_BEFORE_FOG/g,_0x499c94):_0x8dbed4=_0x499c94+'\x0d\x0a',_0x5b6176=_0x5b6176['replace'](/void\s+?main/g,_0x494b01['a']['IncludesShadersStore']['shadowMapFragmentDeclaration']+'\x0d\x0avoid\x20main'),_0x5c2e98?_0x5b6176=_0x5b6176['replace'](/#define SHADOWDEPTH_FRAGMENT/g,_0x58e19e):_0x8dbed4+=_0x58e19e+'\x0d\x0a',_0x8dbed4&&(_0x5b6176=_0x5b6176['replace'](/}\s*$/g,_0x8dbed4+'}')),_0x5b6176=_0x5b6176['replace'](/#define SHADER_NAME.*?\n|out vec4 glFragColor;\n/g,'');var _0x181e16=_0x595205['getUniformNames']()['slice']();return _0x181e16['push']('biasAndScaleSM','depthValuesSM','lightDataSM','softTransparentShadowSM'),_0x5ca9ab['depthEffect']=this['_scene']['getEngine']()['createEffect']({'vertexSource':_0x47a388,'fragmentSource':_0x5b6176,'vertexToken':_0x5ca9ab['token'],'fragmentToken':_0x5ca9ab['token']},{'attributes':_0x595205['getAttributesNames'](),'uniformsNames':_0x181e16,'uniformBuffersNames':_0x595205['getUniformBuffersNames'](),'samplers':_0x595205['getSamplers'](),'defines':_0x248b7c+'\x0a'+_0x595205['defines']['replace']('#define\x20SHADOWS','')['replace'](/#define SHADOW\d/g,''),'indexParameters':_0x595205['getIndexParameters']()},this['_scene']['getEngine']()),_0x5ca9ab['depthEffect'];},_0x53cd04;}()),_0x595214=_0x162675(0x65);function _0x4f6b4c(_0x2c8853,_0xac6d44,_0x2f72a3,_0x13ae14,_0x34be7c){var _0xad592e=new _0x2c8853['DecoderBuffer']();_0xad592e['Init'](_0xac6d44,_0xac6d44['byteLength']);var _0x593a8c,_0xaa5aca,_0x447623=new _0x2c8853['Decoder']();try{var _0x53eda6=_0x447623['GetEncodedGeometryType'](_0xad592e);switch(_0x53eda6){case _0x2c8853['TRIANGULAR_MESH']:_0x593a8c=new _0x2c8853['Mesh'](),_0xaa5aca=_0x447623['DecodeBufferToMesh'](_0xad592e,_0x593a8c);break;case _0x2c8853['POINT_CLOUD']:_0x593a8c=new _0x2c8853['PointCloud'](),_0xaa5aca=_0x447623['DecodeBufferToPointCloud'](_0xad592e,_0x593a8c);break;default:throw new Error('Invalid\x20geometry\x20type\x20'+_0x53eda6);}if(!_0xaa5aca['ok']()||!_0x593a8c['ptr'])throw new Error(_0xaa5aca['error_msg']());if(_0x53eda6===_0x2c8853['TRIANGULAR_MESH']){var _0x5c2555=0x3*_0x593a8c['num_faces'](),_0x2ca360=0x4*_0x5c2555,_0x51aef9=_0x2c8853['_malloc'](_0x2ca360);try{_0x447623['GetTrianglesUInt32Array'](_0x593a8c,_0x2ca360,_0x51aef9);var _0x4c3f8a=new Uint32Array(_0x5c2555);_0x4c3f8a['set'](new Uint32Array(_0x2c8853['HEAPF32']['buffer'],_0x51aef9,_0x5c2555)),_0x13ae14(_0x4c3f8a);}finally{_0x2c8853['_free'](_0x51aef9);}}var _0x129b47=function(_0x3af453,_0x3b66ce){var _0x3ca7ab=_0x3b66ce['num_components'](),_0x5a2db9=_0x593a8c['num_points'](),_0xe268db=_0x5a2db9*_0x3ca7ab,_0x4a356d=_0xe268db*Float32Array['BYTES_PER_ELEMENT'],_0x22961d=_0x2c8853['_malloc'](_0x4a356d);try{_0x447623['GetAttributeDataArrayForAllPoints'](_0x593a8c,_0x3b66ce,_0x2c8853['DT_FLOAT32'],_0x4a356d,_0x22961d);var _0x5de582=new Float32Array(_0x2c8853['HEAPF32']['buffer'],_0x22961d,_0xe268db);if('color'===_0x3af453&&0x3===_0x3ca7ab){for(var _0x37bc82=new Float32Array(0x4*_0x5a2db9),_0x5c2680=0x0,_0x245710=0x0;_0x5c2680<_0x37bc82['length'];_0x5c2680+=0x4,_0x245710+=_0x3ca7ab)_0x37bc82[_0x5c2680+0x0]=_0x5de582[_0x245710+0x0],_0x37bc82[_0x5c2680+0x1]=_0x5de582[_0x245710+0x1],_0x37bc82[_0x5c2680+0x2]=_0x5de582[_0x245710+0x2],_0x37bc82[_0x5c2680+0x3]=0x1;_0x34be7c(_0x3af453,_0x37bc82);}else(_0x37bc82=new Float32Array(_0xe268db))['set'](new Float32Array(_0x2c8853['HEAPF32']['buffer'],_0x22961d,_0xe268db)),_0x34be7c(_0x3af453,_0x37bc82);}finally{_0x2c8853['_free'](_0x22961d);}};if(_0x2f72a3)for(var _0x51a7a4 in _0x2f72a3){var _0x4f0723=_0x2f72a3[_0x51a7a4];_0x129b47(_0x51a7a4,_0x447623['GetAttributeByUniqueId'](_0x593a8c,_0x4f0723));}else{var _0xe9ef83={'position':'POSITION','normal':'NORMAL','color':'COLOR','uv':'TEX_COORD'};for(var _0x51a7a4 in _0xe9ef83){if(-0x1!==(_0x4f0723=_0x447623['GetAttributeId'](_0x593a8c,_0x2c8853[_0xe9ef83[_0x51a7a4]])))_0x129b47(_0x51a7a4,_0x447623['GetAttribute'](_0x593a8c,_0x4f0723));}}}finally{_0x593a8c&&_0x2c8853['destroy'](_0x593a8c),_0x2c8853['destroy'](_0x447623),_0x2c8853['destroy'](_0xad592e);}}function _0x3a4c82(){var _0x44a3b6;onmessage=function(_0x5f2dc0){var _0x4dd951=_0x5f2dc0['data'];switch(_0x4dd951['id']){case'init':var _0x57fae7=_0x4dd951['decoder'];_0x57fae7['url']&&(importScripts(_0x57fae7['url']),_0x44a3b6=DracoDecoderModule({'wasmBinary':_0x57fae7['wasmBinary']})),postMessage('done');break;case'decodeMesh':if(!_0x44a3b6)throw new Error('Draco\x20decoder\x20module\x20is\x20not\x20available');_0x44a3b6['then'](function(_0x267126){_0x4f6b4c(_0x267126,_0x4dd951['dataView'],_0x4dd951['attributes'],function(_0x462d8c){postMessage({'id':'indices','value':_0x462d8c},[_0x462d8c['buffer']]);},function(_0x21cc75,_0x1e2b18){postMessage({'id':_0x21cc75,'value':_0x1e2b18},[_0x1e2b18['buffer']]);}),postMessage('done');});}};}function _0x4ecf38(_0x436a02){return'object'!=typeof document||'string'!=typeof _0x436a02?_0x436a02:_0x5d754c['b']['GetAbsoluteUrl'](_0x436a02);}var _0x238160=(function(){function _0x464630(_0x1c6553){void 0x0===_0x1c6553&&(_0x1c6553=_0x464630['DefaultNumWorkers']);var _0x303a0d=_0x464630['Configuration']['decoder'],_0x377b43=_0x303a0d['wasmUrl']&&_0x303a0d['wasmBinaryUrl']&&'object'==typeof WebAssembly?{'url':_0x303a0d['wasmUrl'],'wasmBinaryPromise':_0x5d754c['b']['LoadFileAsync'](_0x4ecf38(_0x303a0d['wasmBinaryUrl']))}:{'url':_0x303a0d['fallbackUrl'],'wasmBinaryPromise':Promise['resolve'](void 0x0)};_0x1c6553&&'function'==typeof Worker?this['_workerPoolPromise']=_0x377b43['wasmBinaryPromise']['then'](function(_0x3dd9e5){for(var _0x2057fd=_0x4f6b4c+'('+_0x3a4c82+')()',_0x5d6ec5=URL['createObjectURL'](new Blob([_0x2057fd],{'type':'application/javascript'})),_0x2d7a3f=new Array(_0x1c6553),_0x2ff3e5=0x0;_0x2ff3e5<_0x2d7a3f['length'];_0x2ff3e5++)_0x2d7a3f[_0x2ff3e5]=new Promise(function(_0x301b4e,_0x4fa9d5){var _0xf1bffb=new Worker(_0x5d6ec5),_0x122f99=function(_0x18ba4b){_0xf1bffb['removeEventListener']('error',_0x122f99),_0xf1bffb['removeEventListener']('message',_0x5dec3c),_0x4fa9d5(_0x18ba4b);},_0x5dec3c=function(_0x221199){'done'===_0x221199['data']&&(_0xf1bffb['removeEventListener']('error',_0x122f99),_0xf1bffb['removeEventListener']('message',_0x5dec3c),_0x301b4e(_0xf1bffb));};_0xf1bffb['addEventListener']('error',_0x122f99),_0xf1bffb['addEventListener']('message',_0x5dec3c),_0xf1bffb['postMessage']({'id':'init','decoder':{'url':_0x4ecf38(_0x377b43['url']),'wasmBinary':_0x3dd9e5}});});return Promise['all'](_0x2d7a3f)['then'](function(_0x38c87f){return new _0xe2001d(_0x38c87f);});}):this['_decoderModulePromise']=_0x377b43['wasmBinaryPromise']['then'](function(_0x428da9){if(!_0x377b43['url'])throw new Error('Draco\x20decoder\x20module\x20is\x20not\x20available');return _0x5d754c['b']['LoadScriptAsync'](_0x377b43['url'])['then'](function(){return _0x43e3ec=_0x428da9,new Promise(function(_0x240866){DracoDecoderModule({'wasmBinary':_0x43e3ec})['then'](function(_0x1e4cb8){_0x240866({'module':_0x1e4cb8});});});var _0x43e3ec;});});}return Object['defineProperty'](_0x464630,'DecoderAvailable',{'get':function(){var _0x33a48d=_0x464630['Configuration']['decoder'];return!!(_0x33a48d['wasmUrl']&&_0x33a48d['wasmBinaryUrl']&&'object'==typeof WebAssembly||_0x33a48d['fallbackUrl']);},'enumerable':!0x1,'configurable':!0x0}),_0x464630['GetDefaultNumWorkers']=function(){return'object'==typeof navigator&&navigator['hardwareConcurrency']?Math['min'](Math['floor'](0.5*navigator['hardwareConcurrency']),0x4):0x1;},Object['defineProperty'](_0x464630,'Default',{'get':function(){return _0x464630['_Default']||(_0x464630['_Default']=new _0x464630()),_0x464630['_Default'];},'enumerable':!0x1,'configurable':!0x0}),_0x464630['prototype']['dispose']=function(){this['_workerPoolPromise']&&this['_workerPoolPromise']['then'](function(_0x3dfbb3){_0x3dfbb3['dispose']();}),delete this['_workerPoolPromise'],delete this['_decoderModulePromise'];},_0x464630['prototype']['whenReadyAsync']=function(){return this['_workerPoolPromise']?this['_workerPoolPromise']['then'](function(){}):this['_decoderModulePromise']?this['_decoderModulePromise']['then'](function(){}):Promise['resolve']();},_0x464630['prototype']['decodeMeshAsync']=function(_0xc393d1,_0xd6ae67){var _0x594001=_0xc393d1 instanceof ArrayBuffer?new Uint8Array(_0xc393d1):_0xc393d1;if(this['_workerPoolPromise'])return this['_workerPoolPromise']['then'](function(_0x5dd343){return new Promise(function(_0x4c8b58,_0xfd827f){_0x5dd343['push'](function(_0x2db327,_0x11143a){var _0xd7acc8=new _0xa18063['a'](),_0x17cf21=function(_0x52b969){_0x2db327['removeEventListener']('error',_0x17cf21),_0x2db327['removeEventListener']('message',_0x35d849),_0xfd827f(_0x52b969),_0x11143a();},_0x35d849=function(_0x5c4fa9){'done'===_0x5c4fa9['data']?(_0x2db327['removeEventListener']('error',_0x17cf21),_0x2db327['removeEventListener']('message',_0x35d849),_0x4c8b58(_0xd7acc8),_0x11143a()):'indices'===_0x5c4fa9['data']['id']?_0xd7acc8['indices']=_0x5c4fa9['data']['value']:_0xd7acc8['set'](_0x5c4fa9['data']['value'],_0x5c4fa9['data']['id']);};_0x2db327['addEventListener']('error',_0x17cf21),_0x2db327['addEventListener']('message',_0x35d849);var _0x1009da=new Uint8Array(_0x594001['byteLength']);_0x1009da['set'](new Uint8Array(_0x594001['buffer'],_0x594001['byteOffset'],_0x594001['byteLength'])),_0x2db327['postMessage']({'id':'decodeMesh','dataView':_0x1009da,'attributes':_0xd6ae67},[_0x1009da['buffer']]);});});});if(this['_decoderModulePromise'])return this['_decoderModulePromise']['then'](function(_0xd00cda){var _0x152693=new _0xa18063['a']();return _0x4f6b4c(_0xd00cda['module'],_0x594001,_0xd6ae67,function(_0x2f88ef){_0x152693['indices']=_0x2f88ef;},function(_0x3d905a,_0x3e7e9e){_0x152693['set'](_0x3e7e9e,_0x3d905a);}),_0x152693;});throw new Error('Draco\x20decoder\x20module\x20is\x20not\x20available');},_0x464630['Configuration']={'decoder':{'wasmUrl':'https://preview.babylonjs.com/draco_wasm_wrapper_gltf.js','wasmBinaryUrl':'https://preview.babylonjs.com/draco_decoder_gltf.wasm','fallbackUrl':'https://preview.babylonjs.com/draco_decoder_gltf.js'}},_0x464630['DefaultNumWorkers']=_0x464630['GetDefaultNumWorkers'](),_0x464630['_Default']=null,_0x464630;}()),_0x2a2d6d=_0x162675(0x3d),_0x1ac092=0x0,_0x279c6e=(function(){function _0x15a890(_0x4f3025,_0x5d0c65,_0x43164c,_0xfb23da){this['pos']=_0x4f3025,this['normal']=_0x5d0c65,this['uv']=_0x43164c,this['vertColor']=_0xfb23da;}return _0x15a890['prototype']['clone']=function(){var _0x13e4ef,_0x4d7644;return new _0x15a890(this['pos']['clone'](),this['normal']['clone'](),null===(_0x13e4ef=this['uv'])||void 0x0===_0x13e4ef?void 0x0:_0x13e4ef['clone'](),null===(_0x4d7644=this['vertColor'])||void 0x0===_0x4d7644?void 0x0:_0x4d7644['clone']());},_0x15a890['prototype']['flip']=function(){this['normal']=this['normal']['scale'](-0x1);},_0x15a890['prototype']['interpolate']=function(_0x3be846,_0x557631){return new _0x15a890(_0x74d525['e']['Lerp'](this['pos'],_0x3be846['pos'],_0x557631),_0x74d525['e']['Lerp'](this['normal'],_0x3be846['normal'],_0x557631),this['uv']&&_0x3be846['uv']?_0x74d525['d']['Lerp'](this['uv'],_0x3be846['uv'],_0x557631):void 0x0,this['vertColor']&&_0x3be846['vertColor']?_0x39310d['b']['Lerp'](this['vertColor'],_0x3be846['vertColor'],_0x557631):void 0x0);},_0x15a890;}()),_0x40abcb=(function(){function _0x4a883a(_0x188fe9,_0x3f1dd2){this['normal']=_0x188fe9,this['w']=_0x3f1dd2;}return _0x4a883a['FromPoints']=function(_0x4600d9,_0x4be770,_0x34458e){var _0x10cc8c=_0x34458e['subtract'](_0x4600d9),_0x41e90f=_0x4be770['subtract'](_0x4600d9);if(0x0===_0x10cc8c['lengthSquared']()||0x0===_0x41e90f['lengthSquared']())return null;var _0x19ce08=_0x74d525['e']['Normalize'](_0x74d525['e']['Cross'](_0x10cc8c,_0x41e90f));return new _0x4a883a(_0x19ce08,_0x74d525['e']['Dot'](_0x19ce08,_0x4600d9));},_0x4a883a['prototype']['clone']=function(){return new _0x4a883a(this['normal']['clone'](),this['w']);},_0x4a883a['prototype']['flip']=function(){this['normal']['scaleInPlace'](-0x1),this['w']=-this['w'];},_0x4a883a['prototype']['splitPolygon']=function(_0x338343,_0x1e84e3,_0x4d57b6,_0x412649,_0x2eb654){var _0x557e65,_0x2fbe3a,_0x5a0b1d=0x0,_0x3997c8=[];for(_0x557e65=0x0;_0x557e65<_0x338343['vertices']['length'];_0x557e65++){var _0x59bc6a=(_0x2fbe3a=_0x74d525['e']['Dot'](this['normal'],_0x338343['vertices'][_0x557e65]['pos'])-this['w'])<-_0x4a883a['EPSILON']?0x2:_0x2fbe3a>_0x4a883a['EPSILON']?0x1:0x0;_0x5a0b1d|=_0x59bc6a,_0x3997c8['push'](_0x59bc6a);}switch(_0x5a0b1d){case 0x0:(_0x74d525['e']['Dot'](this['normal'],_0x338343['plane']['normal'])>0x0?_0x1e84e3:_0x4d57b6)['push'](_0x338343);break;case 0x1:_0x412649['push'](_0x338343);break;case 0x2:_0x2eb654['push'](_0x338343);break;case 0x3:var _0x1ddd9e,_0x2aa339=[],_0x5b5a45=[];for(_0x557e65=0x0;_0x557e65<_0x338343['vertices']['length'];_0x557e65++){var _0x16070f=(_0x557e65+0x1)%_0x338343['vertices']['length'],_0xe7d2d9=_0x3997c8[_0x557e65],_0x38f953=_0x3997c8[_0x16070f],_0x4251fa=_0x338343['vertices'][_0x557e65],_0x24d8fd=_0x338343['vertices'][_0x16070f];if(0x2!==_0xe7d2d9&&_0x2aa339['push'](_0x4251fa),0x1!==_0xe7d2d9&&_0x5b5a45['push'](0x2!==_0xe7d2d9?_0x4251fa['clone']():_0x4251fa),0x3==(_0xe7d2d9|_0x38f953)){_0x2fbe3a=(this['w']-_0x74d525['e']['Dot'](this['normal'],_0x4251fa['pos']))/_0x74d525['e']['Dot'](this['normal'],_0x24d8fd['pos']['subtract'](_0x4251fa['pos']));var _0x4d582b=_0x4251fa['interpolate'](_0x24d8fd,_0x2fbe3a);_0x2aa339['push'](_0x4d582b),_0x5b5a45['push'](_0x4d582b['clone']());}}_0x2aa339['length']>=0x3&&(_0x1ddd9e=new _0x2bbf12(_0x2aa339,_0x338343['shared']))['plane']&&_0x412649['push'](_0x1ddd9e),_0x5b5a45['length']>=0x3&&(_0x1ddd9e=new _0x2bbf12(_0x5b5a45,_0x338343['shared']))['plane']&&_0x2eb654['push'](_0x1ddd9e);}},_0x4a883a['EPSILON']=0.00001,_0x4a883a;}()),_0x2bbf12=(function(){function _0x350eb5(_0x357899,_0x35fc2a){this['vertices']=_0x357899,this['shared']=_0x35fc2a,this['plane']=_0x40abcb['FromPoints'](_0x357899[0x0]['pos'],_0x357899[0x1]['pos'],_0x357899[0x2]['pos']);}return _0x350eb5['prototype']['clone']=function(){return new _0x350eb5(this['vertices']['map'](function(_0x34b035){return _0x34b035['clone']();}),this['shared']);},_0x350eb5['prototype']['flip']=function(){this['vertices']['reverse']()['map'](function(_0x5dd8d3){_0x5dd8d3['flip']();}),this['plane']['flip']();},_0x350eb5;}()),_0x43bc5c=(function(){function _0x156854(_0x18af6f){this['plane']=null,this['front']=null,this['back']=null,this['polygons']=new Array(),_0x18af6f&&this['build'](_0x18af6f);}return _0x156854['prototype']['clone']=function(){var _0x4a5e0b=new _0x156854();return _0x4a5e0b['plane']=this['plane']&&this['plane']['clone'](),_0x4a5e0b['front']=this['front']&&this['front']['clone'](),_0x4a5e0b['back']=this['back']&&this['back']['clone'](),_0x4a5e0b['polygons']=this['polygons']['map'](function(_0x382e8d){return _0x382e8d['clone']();}),_0x4a5e0b;},_0x156854['prototype']['invert']=function(){for(var _0x3e6089=0x0;_0x3e60890x1)?0x1:_0x67e969['arc']||0x1,_0x47d343=0x0===_0x67e969['sideOrientation']?0x0:_0x67e969['sideOrientation']||_0xa18063['a']['DEFAULTSIDE'];_0x31093e['push'](0x0,0x0,0x0),_0x42ee6b['push'](0.5,0.5);for(var _0x59050f=0x2*Math['PI']*_0x1bb704,_0xca6100=0x1===_0x1bb704?_0x59050f/_0x53cbe6:_0x59050f/(_0x53cbe6-0x1),_0x4120ab=0x0,_0x564f00=0x0;_0x564f00<_0x53cbe6;_0x564f00++){var _0x5e62a7=Math['cos'](_0x4120ab),_0x4e9fd6=Math['sin'](_0x4120ab),_0x372a1c=(_0x5e62a7+0x1)/0x2,_0x3c6e78=(0x1-_0x4e9fd6)/0x2;_0x31093e['push'](_0x116f55*_0x5e62a7,_0x116f55*_0x4e9fd6,0x0),_0x42ee6b['push'](_0x372a1c,_0x3c6e78),_0x4120ab+=_0xca6100;}0x1===_0x1bb704&&(_0x31093e['push'](_0x31093e[0x3],_0x31093e[0x4],_0x31093e[0x5]),_0x42ee6b['push'](_0x42ee6b[0x2],_0x42ee6b[0x3]));for(var _0x504d11=_0x31093e['length']/0x3,_0x10cf43=0x1;_0x10cf43<_0x504d11-0x1;_0x10cf43++)_0x397002['push'](_0x10cf43+0x1,0x0,_0x10cf43);_0xa18063['a']['ComputeNormals'](_0x31093e,_0x397002,_0x34a0db),_0xa18063['a']['_ComputeSides'](_0x47d343,_0x31093e,_0x397002,_0x34a0db,_0x42ee6b,_0x67e969['frontUVs'],_0x67e969['backUVs']);var _0x3bd6c1=new _0xa18063['a']();return _0x3bd6c1['indices']=_0x397002,_0x3bd6c1['positions']=_0x31093e,_0x3bd6c1['normals']=_0x34a0db,_0x3bd6c1['uvs']=_0x42ee6b,_0x3bd6c1;},_0x3cf5e5['a']['CreateDisc']=function(_0x4790dc,_0x54b889,_0x1ad03b,_0x153417,_0x1153aa,_0x25052d){void 0x0===_0x153417&&(_0x153417=null);var _0x8f2cc0={'radius':_0x54b889,'tessellation':_0x1ad03b,'sideOrientation':_0x25052d,'updatable':_0x1153aa};return _0x4ec9b3['CreateDisc'](_0x4790dc,_0x8f2cc0,_0x153417);};var _0x4ec9b3=(function(){function _0x20fb39(){}return _0x20fb39['CreateDisc']=function(_0x3a8d37,_0x10d67e,_0x3ccb20){void 0x0===_0x3ccb20&&(_0x3ccb20=null);var _0x505e47=new _0x3cf5e5['a'](_0x3a8d37,_0x3ccb20);return _0x10d67e['sideOrientation']=_0x3cf5e5['a']['_GetDefaultSideOrientation'](_0x10d67e['sideOrientation']),_0x505e47['_originalBuilderSideOrientation']=_0x10d67e['sideOrientation'],_0xa18063['a']['CreateDisc'](_0x10d67e)['applyToMesh'](_0x505e47,_0x10d67e['updatable']),_0x505e47;},_0x20fb39;}());_0xa18063['a']['CreateTiledBox']=function(_0x1942ca){for(var _0x58e0ac=_0x1942ca['faceUV']||new Array(0x6),_0x532b7e=_0x1942ca['faceColors'],_0x5a2d22=_0x1942ca['pattern']||_0x3cf5e5['a']['NO_FLIP'],_0x4deddb=_0x1942ca['width']||_0x1942ca['size']||0x1,_0x1a8902=_0x1942ca['height']||_0x1942ca['size']||0x1,_0x56d27e=_0x1942ca['depth']||_0x1942ca['size']||0x1,_0x5ca251=_0x1942ca['tileWidth']||_0x1942ca['tileSize']||0x1,_0x351d83=_0x1942ca['tileHeight']||_0x1942ca['tileSize']||0x1,_0x580183=_0x1942ca['alignHorizontal']||0x0,_0x3601e5=_0x1942ca['alignVertical']||0x0,_0x4ef638=0x0===_0x1942ca['sideOrientation']?0x0:_0x1942ca['sideOrientation']||_0xa18063['a']['DEFAULTSIDE'],_0x443211=0x0;_0x443211<0x6;_0x443211++)void 0x0===_0x58e0ac[_0x443211]&&(_0x58e0ac[_0x443211]=new _0x74d525['f'](0x0,0x0,0x1,0x1)),_0x532b7e&&void 0x0===_0x532b7e[_0x443211]&&(_0x532b7e[_0x443211]=new _0x39310d['b'](0x1,0x1,0x1,0x1));var _0x1a5870=_0x4deddb/0x2,_0x22743d=_0x1a8902/0x2,_0x17eda3=_0x56d27e/0x2,_0x53f88c=[];for(_0x443211=0x0;_0x443211<0x2;_0x443211++)_0x53f88c[_0x443211]=_0xa18063['a']['CreateTiledPlane']({'pattern':_0x5a2d22,'tileWidth':_0x5ca251,'tileHeight':_0x351d83,'width':_0x4deddb,'height':_0x1a8902,'alignVertical':_0x3601e5,'alignHorizontal':_0x580183,'sideOrientation':_0x4ef638});for(_0x443211=0x2;_0x443211<0x4;_0x443211++)_0x53f88c[_0x443211]=_0xa18063['a']['CreateTiledPlane']({'pattern':_0x5a2d22,'tileWidth':_0x5ca251,'tileHeight':_0x351d83,'width':_0x56d27e,'height':_0x1a8902,'alignVertical':_0x3601e5,'alignHorizontal':_0x580183,'sideOrientation':_0x4ef638});var _0x26732d=_0x3601e5;_0x3601e5===_0x3cf5e5['a']['BOTTOM']?_0x26732d=_0x3cf5e5['a']['TOP']:_0x3601e5===_0x3cf5e5['a']['TOP']&&(_0x26732d=_0x3cf5e5['a']['BOTTOM']);for(_0x443211=0x4;_0x443211<0x6;_0x443211++)_0x53f88c[_0x443211]=_0xa18063['a']['CreateTiledPlane']({'pattern':_0x5a2d22,'tileWidth':_0x5ca251,'tileHeight':_0x351d83,'width':_0x4deddb,'height':_0x56d27e,'alignVertical':_0x26732d,'alignHorizontal':_0x580183,'sideOrientation':_0x4ef638});var _0x32f3c9=[],_0x338cd5=[],_0x19a16d=[],_0x4ffac5=[],_0x516b24=[],_0x329270=[],_0x4d63e1=[],_0x4ddf88=[],_0x2ad0da=0x0,_0x38a172=0x0,_0x398134=0x0;for(_0x443211=0x0;_0x443211<0x6;_0x443211++){_0x2ad0da=_0x53f88c[_0x443211]['positions']['length'],(_0x329270[_0x443211]=[],_0x4d63e1[_0x443211]=[]);for(var _0x3bfa81=0x0;_0x3bfa81<_0x2ad0da/0x3;_0x3bfa81++)_0x329270[_0x443211]['push'](new _0x74d525['e'](_0x53f88c[_0x443211]['positions'][0x3*_0x3bfa81],_0x53f88c[_0x443211]['positions'][0x3*_0x3bfa81+0x1],_0x53f88c[_0x443211]['positions'][0x3*_0x3bfa81+0x2])),_0x4d63e1[_0x443211]['push'](new _0x74d525['e'](_0x53f88c[_0x443211]['normals'][0x3*_0x3bfa81],_0x53f88c[_0x443211]['normals'][0x3*_0x3bfa81+0x1],_0x53f88c[_0x443211]['normals'][0x3*_0x3bfa81+0x2]));_0x38a172=_0x53f88c[_0x443211]['uvs']['length'],_0x4ddf88[_0x443211]=[];for(var _0x52db10=0x0;_0x52db10<_0x38a172;_0x52db10+=0x2)_0x4ddf88[_0x443211][_0x52db10]=_0x58e0ac[_0x443211]['x']+(_0x58e0ac[_0x443211]['z']-_0x58e0ac[_0x443211]['x'])*_0x53f88c[_0x443211]['uvs'][_0x52db10],_0x4ddf88[_0x443211][_0x52db10+0x1]=_0x58e0ac[_0x443211]['y']+(_0x58e0ac[_0x443211]['w']-_0x58e0ac[_0x443211]['y'])*_0x53f88c[_0x443211]['uvs'][_0x52db10+0x1];if(_0x19a16d=_0x19a16d['concat'](_0x4ddf88[_0x443211]),_0x4ffac5=_0x4ffac5['concat'](_0x53f88c[_0x443211]['indices']['map'](function(_0x7f610e){return _0x7f610e+_0x398134;})),_0x398134+=_0x329270[_0x443211]['length'],_0x532b7e){for(var _0x4233d3=0x0;_0x4233d3<0x4;_0x4233d3++)_0x516b24['push'](_0x532b7e[_0x443211]['r'],_0x532b7e[_0x443211]['g'],_0x532b7e[_0x443211]['b'],_0x532b7e[_0x443211]['a']);}}var _0xf68683=new _0x74d525['e'](0x0,0x0,_0x17eda3),_0x607488=_0x74d525['a']['RotationY'](Math['PI']);_0x32f3c9=_0x329270[0x0]['map'](function(_0x224fcd){return _0x74d525['e']['TransformNormal'](_0x224fcd,_0x607488)['add'](_0xf68683);})['map'](function(_0x4e1d36){return[_0x4e1d36['x'],_0x4e1d36['y'],_0x4e1d36['z']];})['reduce'](function(_0x23e15f,_0x1cb52d){return _0x23e15f['concat'](_0x1cb52d);},[]),_0x338cd5=_0x4d63e1[0x0]['map'](function(_0x12fa8c){return _0x74d525['e']['TransformNormal'](_0x12fa8c,_0x607488);})['map'](function(_0x55995f){return[_0x55995f['x'],_0x55995f['y'],_0x55995f['z']];})['reduce'](function(_0x2933ec,_0x16b2fa){return _0x2933ec['concat'](_0x16b2fa);},[]),_0x32f3c9=_0x32f3c9['concat'](_0x329270[0x1]['map'](function(_0x373730){return _0x373730['subtract'](_0xf68683);})['map'](function(_0x4caa9d){return[_0x4caa9d['x'],_0x4caa9d['y'],_0x4caa9d['z']];})['reduce'](function(_0x3cefb6,_0x226b82){return _0x3cefb6['concat'](_0x226b82);},[])),_0x338cd5=_0x338cd5['concat'](_0x4d63e1[0x1]['map'](function(_0x2fa457){return[_0x2fa457['x'],_0x2fa457['y'],_0x2fa457['z']];})['reduce'](function(_0x124567,_0x47f79d){return _0x124567['concat'](_0x47f79d);},[]));var _0x157f73=new _0x74d525['e'](_0x1a5870,0x0,0x0),_0x5589c2=_0x74d525['a']['RotationY'](-Math['PI']/0x2);_0x32f3c9=_0x32f3c9['concat'](_0x329270[0x2]['map'](function(_0x2251aa){return _0x74d525['e']['TransformNormal'](_0x2251aa,_0x5589c2)['add'](_0x157f73);})['map'](function(_0x14d217){return[_0x14d217['x'],_0x14d217['y'],_0x14d217['z']];})['reduce'](function(_0x5f1104,_0x47cd60){return _0x5f1104['concat'](_0x47cd60);},[])),_0x338cd5=_0x338cd5['concat'](_0x4d63e1[0x2]['map'](function(_0xebc38f){return _0x74d525['e']['TransformNormal'](_0xebc38f,_0x5589c2);})['map'](function(_0x1f4b50){return[_0x1f4b50['x'],_0x1f4b50['y'],_0x1f4b50['z']];})['reduce'](function(_0xe8c0f4,_0x24883c){return _0xe8c0f4['concat'](_0x24883c);},[]));var _0x25c712=_0x74d525['a']['RotationY'](Math['PI']/0x2);_0x32f3c9=_0x32f3c9['concat'](_0x329270[0x3]['map'](function(_0x581d02){return _0x74d525['e']['TransformNormal'](_0x581d02,_0x25c712)['subtract'](_0x157f73);})['map'](function(_0x5ca943){return[_0x5ca943['x'],_0x5ca943['y'],_0x5ca943['z']];})['reduce'](function(_0x569fbe,_0x4a3ab9){return _0x569fbe['concat'](_0x4a3ab9);},[])),_0x338cd5=_0x338cd5['concat'](_0x4d63e1[0x3]['map'](function(_0x3f7ec8){return _0x74d525['e']['TransformNormal'](_0x3f7ec8,_0x25c712);})['map'](function(_0x56938d){return[_0x56938d['x'],_0x56938d['y'],_0x56938d['z']];})['reduce'](function(_0x192b8a,_0x19bbdd){return _0x192b8a['concat'](_0x19bbdd);},[]));var _0x3c888f=new _0x74d525['e'](0x0,_0x22743d,0x0),_0x5a4b69=_0x74d525['a']['RotationX'](Math['PI']/0x2);_0x32f3c9=_0x32f3c9['concat'](_0x329270[0x4]['map'](function(_0x3ad644){return _0x74d525['e']['TransformNormal'](_0x3ad644,_0x5a4b69)['add'](_0x3c888f);})['map'](function(_0x3cb1f1){return[_0x3cb1f1['x'],_0x3cb1f1['y'],_0x3cb1f1['z']];})['reduce'](function(_0x599a26,_0x3643cd){return _0x599a26['concat'](_0x3643cd);},[])),_0x338cd5=_0x338cd5['concat'](_0x4d63e1[0x4]['map'](function(_0x34b050){return _0x74d525['e']['TransformNormal'](_0x34b050,_0x5a4b69);})['map'](function(_0x541523){return[_0x541523['x'],_0x541523['y'],_0x541523['z']];})['reduce'](function(_0x159650,_0x15d64f){return _0x159650['concat'](_0x15d64f);},[]));var _0xc62030=_0x74d525['a']['RotationX'](-Math['PI']/0x2);_0x32f3c9=_0x32f3c9['concat'](_0x329270[0x5]['map'](function(_0x14f5a9){return _0x74d525['e']['TransformNormal'](_0x14f5a9,_0xc62030)['subtract'](_0x3c888f);})['map'](function(_0xed942b){return[_0xed942b['x'],_0xed942b['y'],_0xed942b['z']];})['reduce'](function(_0x359880,_0x2243be){return _0x359880['concat'](_0x2243be);},[])),_0x338cd5=_0x338cd5['concat'](_0x4d63e1[0x5]['map'](function(_0x4ce5c1){return _0x74d525['e']['TransformNormal'](_0x4ce5c1,_0xc62030);})['map'](function(_0x1f80eb){return[_0x1f80eb['x'],_0x1f80eb['y'],_0x1f80eb['z']];})['reduce'](function(_0x28bcc5,_0x48e54d){return _0x28bcc5['concat'](_0x48e54d);},[])),_0xa18063['a']['_ComputeSides'](_0x4ef638,_0x32f3c9,_0x4ffac5,_0x338cd5,_0x19a16d);var _0x5c8f41=new _0xa18063['a']();if(_0x5c8f41['indices']=_0x4ffac5,_0x5c8f41['positions']=_0x32f3c9,_0x5c8f41['normals']=_0x338cd5,_0x5c8f41['uvs']=_0x19a16d,_0x532b7e){var _0x295f7d=_0x4ef638===_0xa18063['a']['DOUBLESIDE']?_0x516b24['concat'](_0x516b24):_0x516b24;_0x5c8f41['colors']=_0x295f7d;}return _0x5c8f41;};var _0x3986af=(function(){function _0x3dc37b(){}return _0x3dc37b['CreateTiledBox']=function(_0x436992,_0x213263,_0x24b689){void 0x0===_0x24b689&&(_0x24b689=null);var _0x30bb36=new _0x3cf5e5['a'](_0x436992,_0x24b689);return _0x213263['sideOrientation']=_0x3cf5e5['a']['_GetDefaultSideOrientation'](_0x213263['sideOrientation']),_0x30bb36['_originalBuilderSideOrientation']=_0x213263['sideOrientation'],_0xa18063['a']['CreateTiledBox'](_0x213263)['applyToMesh'](_0x30bb36,_0x213263['updatable']),_0x30bb36;},_0x3dc37b;}());_0xa18063['a']['CreateTorusKnot']=function(_0x147559){var _0x30d48b,_0x4e2597,_0x482b1e=new Array(),_0x3d6655=new Array(),_0x139d09=new Array(),_0x2b6906=new Array(),_0x51a6c2=_0x147559['radius']||0x2,_0x11a1b7=_0x147559['tube']||0.5,_0x7eaf8f=_0x147559['radialSegments']||0x20,_0x1fed86=_0x147559['tubularSegments']||0x20,_0x2ce8aa=_0x147559['p']||0x2,_0x35d410=_0x147559['q']||0x3,_0x1c0fae=0x0===_0x147559['sideOrientation']?0x0:_0x147559['sideOrientation']||_0xa18063['a']['DEFAULTSIDE'],_0x560775=function(_0x101d69){var _0x2e7181=Math['cos'](_0x101d69),_0x1a584d=Math['sin'](_0x101d69),_0x242a7e=_0x35d410/_0x2ce8aa*_0x101d69,_0x254cae=Math['cos'](_0x242a7e),_0x5ea26c=_0x51a6c2*(0x2+_0x254cae)*0.5*_0x2e7181,_0x3854b5=_0x51a6c2*(0x2+_0x254cae)*_0x1a584d*0.5,_0x5629e1=_0x51a6c2*Math['sin'](_0x242a7e)*0.5;return new _0x74d525['e'](_0x5ea26c,_0x3854b5,_0x5629e1);};for(_0x30d48b=0x0;_0x30d48b<=_0x7eaf8f;_0x30d48b++){var _0x23a222=_0x30d48b%_0x7eaf8f/_0x7eaf8f*0x2*_0x2ce8aa*Math['PI'],_0x2cb07a=_0x560775(_0x23a222),_0x381fe7=_0x560775(_0x23a222+0.01),_0xcd111f=_0x381fe7['subtract'](_0x2cb07a),_0x1c4629=_0x381fe7['add'](_0x2cb07a),_0x44ac07=_0x74d525['e']['Cross'](_0xcd111f,_0x1c4629);for(_0x1c4629=_0x74d525['e']['Cross'](_0x44ac07,_0xcd111f),_0x44ac07['normalize'](),_0x1c4629['normalize'](),_0x4e2597=0x0;_0x4e2597<_0x1fed86;_0x4e2597++){var _0x3ef16a=_0x4e2597%_0x1fed86/_0x1fed86*0x2*Math['PI'],_0x2d548e=-_0x11a1b7*Math['cos'](_0x3ef16a),_0x3295c2=_0x11a1b7*Math['sin'](_0x3ef16a);_0x3d6655['push'](_0x2cb07a['x']+_0x2d548e*_0x1c4629['x']+_0x3295c2*_0x44ac07['x']),_0x3d6655['push'](_0x2cb07a['y']+_0x2d548e*_0x1c4629['y']+_0x3295c2*_0x44ac07['y']),_0x3d6655['push'](_0x2cb07a['z']+_0x2d548e*_0x1c4629['z']+_0x3295c2*_0x44ac07['z']),_0x2b6906['push'](_0x30d48b/_0x7eaf8f),_0x2b6906['push'](_0x4e2597/_0x1fed86);}}for(_0x30d48b=0x0;_0x30d48b<_0x7eaf8f;_0x30d48b++)for(_0x4e2597=0x0;_0x4e2597<_0x1fed86;_0x4e2597++){var _0x204d01=(_0x4e2597+0x1)%_0x1fed86,_0x51f659=_0x30d48b*_0x1fed86+_0x4e2597,_0x5dce44=(_0x30d48b+0x1)*_0x1fed86+_0x4e2597,_0x263d41=(_0x30d48b+0x1)*_0x1fed86+_0x204d01,_0x475cb9=_0x30d48b*_0x1fed86+_0x204d01;_0x482b1e['push'](_0x475cb9),_0x482b1e['push'](_0x5dce44),_0x482b1e['push'](_0x51f659),_0x482b1e['push'](_0x475cb9),_0x482b1e['push'](_0x263d41),_0x482b1e['push'](_0x5dce44);}_0xa18063['a']['ComputeNormals'](_0x3d6655,_0x482b1e,_0x139d09),_0xa18063['a']['_ComputeSides'](_0x1c0fae,_0x3d6655,_0x482b1e,_0x139d09,_0x2b6906,_0x147559['frontUVs'],_0x147559['backUVs']);var _0x134607=new _0xa18063['a']();return _0x134607['indices']=_0x482b1e,_0x134607['positions']=_0x3d6655,_0x134607['normals']=_0x139d09,_0x134607['uvs']=_0x2b6906,_0x134607;},_0x3cf5e5['a']['CreateTorusKnot']=function(_0x29128c,_0x3dbdaa,_0x453870,_0x3a63a8,_0x1f41bb,_0x57ed6e,_0x514c8e,_0x4b9a2b,_0x193636,_0xc13efb){var _0x5630c7={'radius':_0x3dbdaa,'tube':_0x453870,'radialSegments':_0x3a63a8,'tubularSegments':_0x1f41bb,'p':_0x57ed6e,'q':_0x514c8e,'sideOrientation':_0xc13efb,'updatable':_0x193636};return _0x2baa94['CreateTorusKnot'](_0x29128c,_0x5630c7,_0x4b9a2b);};var _0x2baa94=(function(){function _0x15b5b8(){}return _0x15b5b8['CreateTorusKnot']=function(_0x2dc4e1,_0x3042e1,_0x1b4ab7){var _0x5af4f5=new _0x3cf5e5['a'](_0x2dc4e1,_0x1b4ab7);return _0x3042e1['sideOrientation']=_0x3cf5e5['a']['_GetDefaultSideOrientation'](_0x3042e1['sideOrientation']),_0x5af4f5['_originalBuilderSideOrientation']=_0x3042e1['sideOrientation'],_0xa18063['a']['CreateTorusKnot'](_0x3042e1)['applyToMesh'](_0x5af4f5,_0x3042e1['updatable']),_0x5af4f5;},_0x15b5b8;}()),_0x5500ec=function(_0x5f0f68){function _0x2fd88e(_0x1878a9,_0xc8a2b2){var _0x58f579=_0x5f0f68['call'](this,_0x1878a9['x'],_0x1878a9['y'])||this;return _0x58f579['index']=_0xc8a2b2,_0x58f579;}return Object(_0x18e13d['d'])(_0x2fd88e,_0x5f0f68),_0x2fd88e;}(_0x74d525['d']),_0x2223ae=(function(){function _0x29f7d1(){this['elements']=new Array();}return _0x29f7d1['prototype']['add']=function(_0x5eaeb9){var _0x3373d2=this,_0x6f6b8b=new Array();return _0x5eaeb9['forEach'](function(_0x4226a3){var _0x34a3d8=new _0x5500ec(_0x4226a3,_0x3373d2['elements']['length']);_0x6f6b8b['push'](_0x34a3d8),_0x3373d2['elements']['push'](_0x34a3d8);}),_0x6f6b8b;},_0x29f7d1['prototype']['computeBounds']=function(){var _0x5216e3=new _0x74d525['d'](this['elements'][0x0]['x'],this['elements'][0x0]['y']),_0x33b6cc=new _0x74d525['d'](this['elements'][0x0]['x'],this['elements'][0x0]['y']);return this['elements']['forEach'](function(_0x39d9dc){_0x39d9dc['x']<_0x5216e3['x']?_0x5216e3['x']=_0x39d9dc['x']:_0x39d9dc['x']>_0x33b6cc['x']&&(_0x33b6cc['x']=_0x39d9dc['x']),_0x39d9dc['y']<_0x5216e3['y']?_0x5216e3['y']=_0x39d9dc['y']:_0x39d9dc['y']>_0x33b6cc['y']&&(_0x33b6cc['y']=_0x39d9dc['y']);}),{'min':_0x5216e3,'max':_0x33b6cc,'width':_0x33b6cc['x']-_0x5216e3['x'],'height':_0x33b6cc['y']-_0x5216e3['y']};},_0x29f7d1;}()),_0x1ff6c6=(function(){function _0x26e0e2(){}return _0x26e0e2['Rectangle']=function(_0x5d2a5e,_0xc47ead,_0x1fa210,_0x24590d){return[new _0x74d525['d'](_0x5d2a5e,_0xc47ead),new _0x74d525['d'](_0x1fa210,_0xc47ead),new _0x74d525['d'](_0x1fa210,_0x24590d),new _0x74d525['d'](_0x5d2a5e,_0x24590d)];},_0x26e0e2['Circle']=function(_0x595481,_0x1d65fe,_0x45015b,_0x34c35a){void 0x0===_0x1d65fe&&(_0x1d65fe=0x0),void 0x0===_0x45015b&&(_0x45015b=0x0),void 0x0===_0x34c35a&&(_0x34c35a=0x20);for(var _0x4f79af=new Array(),_0x3e4eca=0x0,_0x3edd9c=0x2*Math['PI']/_0x34c35a,_0x4dda5a=0x0;_0x4dda5a<_0x34c35a;_0x4dda5a++)_0x4f79af['push'](new _0x74d525['d'](_0x1d65fe+Math['cos'](_0x3e4eca)*_0x595481,_0x45015b+Math['sin'](_0x3e4eca)*_0x595481)),_0x3e4eca-=_0x3edd9c;return _0x4f79af;},_0x26e0e2['Parse']=function(_0x382da6){var _0x2fb524,_0x3d0582=_0x382da6['split'](/[^-+eE\.\d]+/)['map'](parseFloat)['filter'](function(_0x2a6983){return!isNaN(_0x2a6983);}),_0x2b9917=[];for(_0x2fb524=0x0;_0x2fb524<(0x7ffffffe&_0x3d0582['length']);_0x2fb524+=0x2)_0x2b9917['push'](new _0x74d525['d'](_0x3d0582[_0x2fb524],_0x3d0582[_0x2fb524+0x1]));return _0x2b9917;},_0x26e0e2['StartingAt']=function(_0xd17ed1,_0x57e790){return _0x5e9f26['f']['StartingAt'](_0xd17ed1,_0x57e790);},_0x26e0e2;}()),_0x20eb6b=(function(){function _0x40bbc4(_0x53d393,_0x301b33,_0x15db18,_0x46f6f0){var _0x57e553;void 0x0===_0x46f6f0&&(_0x46f6f0=earcut),this['_points']=new _0x2223ae(),this['_outlinepoints']=new _0x2223ae(),this['_holes']=new Array(),this['_epoints']=new Array(),this['_eholes']=new Array(),this['bjsEarcut']=_0x46f6f0,this['_name']=_0x53d393,this['_scene']=_0x15db18||_0x300b38['a']['LastCreatedScene'],_0x57e553=_0x301b33 instanceof _0x5e9f26['f']?_0x301b33['getPoints']():_0x301b33,this['_addToepoint'](_0x57e553),this['_points']['add'](_0x57e553),this['_outlinepoints']['add'](_0x57e553),void 0x0===this['bjsEarcut']&&_0x75193d['a']['Warn']('Earcut\x20was\x20not\x20found,\x20the\x20polygon\x20will\x20not\x20be\x20built.');}return _0x40bbc4['prototype']['_addToepoint']=function(_0x2b9ea1){for(var _0x55a616=0x0,_0x66f926=_0x2b9ea1;_0x55a616<_0x66f926['length'];_0x55a616++){var _0x223e45=_0x66f926[_0x55a616];this['_epoints']['push'](_0x223e45['x'],_0x223e45['y']);}},_0x40bbc4['prototype']['addHole']=function(_0xd96c81){this['_points']['add'](_0xd96c81);var _0x6543d1=new _0x2223ae();return _0x6543d1['add'](_0xd96c81),this['_holes']['push'](_0x6543d1),this['_eholes']['push'](this['_epoints']['length']/0x2),this['_addToepoint'](_0xd96c81),this;},_0x40bbc4['prototype']['build']=function(_0x11a56f,_0x2db6ef){void 0x0===_0x11a56f&&(_0x11a56f=!0x1),void 0x0===_0x2db6ef&&(_0x2db6ef=0x0);var _0x1e2785=new _0x3cf5e5['a'](this['_name'],this['_scene']),_0x122839=this['buildVertexData'](_0x2db6ef);return _0x1e2785['setVerticesData'](_0x212fbd['b']['PositionKind'],_0x122839['positions'],_0x11a56f),_0x1e2785['setVerticesData'](_0x212fbd['b']['NormalKind'],_0x122839['normals'],_0x11a56f),_0x1e2785['setVerticesData'](_0x212fbd['b']['UVKind'],_0x122839['uvs'],_0x11a56f),_0x1e2785['setIndices'](_0x122839['indices']),_0x1e2785;},_0x40bbc4['prototype']['buildVertexData']=function(_0x266232){var _0x4689b5=this;void 0x0===_0x266232&&(_0x266232=0x0);var _0x397d48=new _0xa18063['a'](),_0x303918=new Array(),_0x4ce78a=new Array(),_0x43fa87=new Array(),_0x2a8643=this['_points']['computeBounds']();this['_points']['elements']['forEach'](function(_0x7ff21a){_0x303918['push'](0x0,0x1,0x0),_0x4ce78a['push'](_0x7ff21a['x'],0x0,_0x7ff21a['y']),_0x43fa87['push']((_0x7ff21a['x']-_0x2a8643['min']['x'])/_0x2a8643['width'],(_0x7ff21a['y']-_0x2a8643['min']['y'])/_0x2a8643['height']);});for(var _0x2a2287=new Array(),_0x77e232=this['bjsEarcut'](this['_epoints'],this['_eholes'],0x2),_0x36f262=0x0;_0x36f262<_0x77e232['length'];_0x36f262++)_0x2a2287['push'](_0x77e232[_0x36f262]);if(_0x266232>0x0){var _0x23aa43=_0x4ce78a['length']/0x3;this['_points']['elements']['forEach'](function(_0x2fc523){_0x303918['push'](0x0,-0x1,0x0),_0x4ce78a['push'](_0x2fc523['x'],-_0x266232,_0x2fc523['y']),_0x43fa87['push'](0x1-(_0x2fc523['x']-_0x2a8643['min']['x'])/_0x2a8643['width'],0x1-(_0x2fc523['y']-_0x2a8643['min']['y'])/_0x2a8643['height']);});var _0x49aee6=_0x2a2287['length'];for(_0x36f262=0x0;_0x36f262<_0x49aee6;_0x36f262+=0x3){var _0x186468=_0x2a2287[_0x36f262+0x0],_0x218aa2=_0x2a2287[_0x36f262+0x1],_0x17f949=_0x2a2287[_0x36f262+0x2];_0x2a2287['push'](_0x17f949+_0x23aa43),_0x2a2287['push'](_0x218aa2+_0x23aa43),_0x2a2287['push'](_0x186468+_0x23aa43);}this['addSide'](_0x4ce78a,_0x303918,_0x43fa87,_0x2a2287,_0x2a8643,this['_outlinepoints'],_0x266232,!0x1),this['_holes']['forEach'](function(_0x539c46){_0x4689b5['addSide'](_0x4ce78a,_0x303918,_0x43fa87,_0x2a2287,_0x2a8643,_0x539c46,_0x266232,!0x0);});}return _0x397d48['indices']=_0x2a2287,_0x397d48['positions']=_0x4ce78a,_0x397d48['normals']=_0x303918,_0x397d48['uvs']=_0x43fa87,_0x397d48;},_0x40bbc4['prototype']['addSide']=function(_0x17c8e9,_0x13a4a7,_0x22259d,_0x5ec5f8,_0x27fb42,_0x5d1bed,_0x1d3f5d,_0x1d914f){for(var _0x445710=_0x17c8e9['length']/0x3,_0x31a009=0x0,_0x4d2a40=0x0;_0x4d2a40<_0x5d1bed['elements']['length'];_0x4d2a40++){var _0x1ef3eb,_0x4d48f7=_0x5d1bed['elements'][_0x4d2a40];_0x1ef3eb=_0x4d2a40+0x1>_0x5d1bed['elements']['length']-0x1?_0x5d1bed['elements'][0x0]:_0x5d1bed['elements'][_0x4d2a40+0x1],_0x17c8e9['push'](_0x4d48f7['x'],0x0,_0x4d48f7['y']),_0x17c8e9['push'](_0x4d48f7['x'],-_0x1d3f5d,_0x4d48f7['y']),_0x17c8e9['push'](_0x1ef3eb['x'],0x0,_0x1ef3eb['y']),_0x17c8e9['push'](_0x1ef3eb['x'],-_0x1d3f5d,_0x1ef3eb['y']);var _0x1b9c97=new _0x74d525['e'](_0x4d48f7['x'],0x0,_0x4d48f7['y']),_0x331e2a=new _0x74d525['e'](_0x1ef3eb['x'],0x0,_0x1ef3eb['y'])['subtract'](_0x1b9c97),_0x26fc49=new _0x74d525['e'](0x0,0x1,0x0),_0x5eb649=_0x74d525['e']['Cross'](_0x331e2a,_0x26fc49);_0x5eb649=_0x5eb649['normalize'](),_0x22259d['push'](_0x31a009/_0x27fb42['width'],0x0),_0x22259d['push'](_0x31a009/_0x27fb42['width'],0x1),_0x31a009+=_0x331e2a['length'](),_0x22259d['push'](_0x31a009/_0x27fb42['width'],0x0),_0x22259d['push'](_0x31a009/_0x27fb42['width'],0x1),_0x1d914f?(_0x13a4a7['push'](_0x5eb649['x'],_0x5eb649['y'],_0x5eb649['z']),_0x13a4a7['push'](_0x5eb649['x'],_0x5eb649['y'],_0x5eb649['z']),_0x13a4a7['push'](_0x5eb649['x'],_0x5eb649['y'],_0x5eb649['z']),_0x13a4a7['push'](_0x5eb649['x'],_0x5eb649['y'],_0x5eb649['z']),_0x5ec5f8['push'](_0x445710),_0x5ec5f8['push'](_0x445710+0x2),_0x5ec5f8['push'](_0x445710+0x1),_0x5ec5f8['push'](_0x445710+0x1),_0x5ec5f8['push'](_0x445710+0x2),_0x5ec5f8['push'](_0x445710+0x3)):(_0x13a4a7['push'](-_0x5eb649['x'],-_0x5eb649['y'],-_0x5eb649['z']),_0x13a4a7['push'](-_0x5eb649['x'],-_0x5eb649['y'],-_0x5eb649['z']),_0x13a4a7['push'](-_0x5eb649['x'],-_0x5eb649['y'],-_0x5eb649['z']),_0x13a4a7['push'](-_0x5eb649['x'],-_0x5eb649['y'],-_0x5eb649['z']),_0x5ec5f8['push'](_0x445710),_0x5ec5f8['push'](_0x445710+0x1),_0x5ec5f8['push'](_0x445710+0x2),_0x5ec5f8['push'](_0x445710+0x1),_0x5ec5f8['push'](_0x445710+0x3),_0x5ec5f8['push'](_0x445710+0x2)),_0x445710+=0x4;}},_0x40bbc4;}());_0xa18063['a']['CreatePolygon']=function(_0x59bf72,_0x2fc974,_0x2339a1,_0x2c545f,_0x429bca,_0x485320,_0x5e71eb){for(var _0x296ca2=_0x2339a1||new Array(0x3),_0x3e04a3=_0x2c545f,_0x34aff2=[],_0x4068f1=_0x5e71eb||!0x1,_0x3f7901=0x0;_0x3f7901<0x3;_0x3f7901++)void 0x0===_0x296ca2[_0x3f7901]&&(_0x296ca2[_0x3f7901]=new _0x74d525['f'](0x0,0x0,0x1,0x1)),_0x3e04a3&&void 0x0===_0x3e04a3[_0x3f7901]&&(_0x3e04a3[_0x3f7901]=new _0x39310d['b'](0x1,0x1,0x1,0x1));var _0x307e69=_0x59bf72['getVerticesData'](_0x212fbd['b']['PositionKind']),_0x43b06a=_0x59bf72['getVerticesData'](_0x212fbd['b']['NormalKind']),_0x520a37=_0x59bf72['getVerticesData'](_0x212fbd['b']['UVKind']),_0x36c0a8=_0x59bf72['getIndices'](),_0x5555ae=_0x307e69['length']/0x9,_0x2fb279=0x0,_0x196863=0x0,_0x1efd71=0x0,_0x407427=0x0,_0x40a48f=[0x0];if(_0x4068f1){for(var _0x458657=_0x5555ae;_0x458657<_0x307e69['length']/0x3;_0x458657+=0x4)_0x196863=_0x307e69[0x3*(_0x458657+0x2)]-_0x307e69[0x3*_0x458657],_0x1efd71=_0x307e69[0x3*(_0x458657+0x2)+0x2]-_0x307e69[0x3*_0x458657+0x2],_0x407427+=Math['sqrt'](_0x196863*_0x196863+_0x1efd71*_0x1efd71),_0x40a48f['push'](_0x407427);}_0x458657=0x0;for(var _0x54bdf2=0x0,_0x16d9ab=0x0;_0x16d9ab<_0x43b06a['length'];_0x16d9ab+=0x3)Math['abs'](_0x43b06a[_0x16d9ab+0x1])<0.001&&(_0x54bdf2=0x1),Math['abs'](_0x43b06a[_0x16d9ab+0x1]-0x1)<0.001&&(_0x54bdf2=0x0),Math['abs'](_0x43b06a[_0x16d9ab+0x1]+0x1)<0.001&&(_0x54bdf2=0x2),_0x458657=_0x16d9ab/0x3,0x1===_0x54bdf2?(_0x2fb279=_0x458657-_0x5555ae,_0x520a37[0x2*_0x458657]=_0x2fb279%0x4<1.5?_0x4068f1?_0x296ca2[_0x54bdf2]['x']+(_0x296ca2[_0x54bdf2]['z']-_0x296ca2[_0x54bdf2]['x'])*_0x40a48f[Math['floor'](_0x2fb279/0x4)]/_0x407427:_0x296ca2[_0x54bdf2]['x']:_0x4068f1?_0x296ca2[_0x54bdf2]['x']+(_0x296ca2[_0x54bdf2]['z']-_0x296ca2[_0x54bdf2]['x'])*_0x40a48f[Math['floor'](_0x2fb279/0x4)+0x1]/_0x407427:_0x296ca2[_0x54bdf2]['z'],_0x520a37[0x2*_0x458657+0x1]=_0x2fb279%0x2==0x0?_0x296ca2[_0x54bdf2]['w']:_0x296ca2[_0x54bdf2]['y']):(_0x520a37[0x2*_0x458657]=(0x1-_0x520a37[0x2*_0x458657])*_0x296ca2[_0x54bdf2]['x']+_0x520a37[0x2*_0x458657]*_0x296ca2[_0x54bdf2]['z'],_0x520a37[0x2*_0x458657+0x1]=(0x1-_0x520a37[0x2*_0x458657+0x1])*_0x296ca2[_0x54bdf2]['y']+_0x520a37[0x2*_0x458657+0x1]*_0x296ca2[_0x54bdf2]['w']),_0x3e04a3&&_0x34aff2['push'](_0x3e04a3[_0x54bdf2]['r'],_0x3e04a3[_0x54bdf2]['g'],_0x3e04a3[_0x54bdf2]['b'],_0x3e04a3[_0x54bdf2]['a']);_0xa18063['a']['_ComputeSides'](_0x2fc974,_0x307e69,_0x36c0a8,_0x43b06a,_0x520a37,_0x429bca,_0x485320);var _0x1f8e3c=new _0xa18063['a']();if(_0x1f8e3c['indices']=_0x36c0a8,_0x1f8e3c['positions']=_0x307e69,_0x1f8e3c['normals']=_0x43b06a,_0x1f8e3c['uvs']=_0x520a37,_0x3e04a3){var _0x3381de=_0x2fc974===_0xa18063['a']['DOUBLESIDE']?_0x34aff2['concat'](_0x34aff2):_0x34aff2;_0x1f8e3c['colors']=_0x3381de;}return _0x1f8e3c;},_0x3cf5e5['a']['CreatePolygon']=function(_0x39b6ca,_0x38a14d,_0x2f67ca,_0x5292ed,_0x5f0d8d,_0x5bff4e,_0x511ff1){void 0x0===_0x511ff1&&(_0x511ff1=earcut);var _0x31a535={'shape':_0x38a14d,'holes':_0x5292ed,'updatable':_0x5f0d8d,'sideOrientation':_0x5bff4e};return _0x25aa99['CreatePolygon'](_0x39b6ca,_0x31a535,_0x2f67ca,_0x511ff1);},_0x3cf5e5['a']['ExtrudePolygon']=function(_0x26e1c0,_0x381da8,_0x2ba188,_0x17e9b9,_0x439e5d,_0x173af4,_0x5bfe03,_0x5ddc8f){void 0x0===_0x5ddc8f&&(_0x5ddc8f=earcut);var _0x4cc60b={'shape':_0x381da8,'holes':_0x439e5d,'depth':_0x2ba188,'updatable':_0x173af4,'sideOrientation':_0x5bfe03};return _0x25aa99['ExtrudePolygon'](_0x26e1c0,_0x4cc60b,_0x17e9b9,_0x5ddc8f);};var _0x25aa99=(function(){function _0x13a3a9(){}return _0x13a3a9['CreatePolygon']=function(_0xd3a1ac,_0x522f62,_0x389fa6,_0x592506){void 0x0===_0x389fa6&&(_0x389fa6=null),void 0x0===_0x592506&&(_0x592506=earcut),_0x522f62['sideOrientation']=_0x3cf5e5['a']['_GetDefaultSideOrientation'](_0x522f62['sideOrientation']);for(var _0x5bfd12=_0x522f62['shape'],_0xfc87a8=_0x522f62['holes']||[],_0x4b3ac1=_0x522f62['depth']||0x0,_0x290a00=[],_0x127afe=[],_0x42c8d2=0x0;_0x42c8d2<_0x5bfd12['length'];_0x42c8d2++)_0x290a00[_0x42c8d2]=new _0x74d525['d'](_0x5bfd12[_0x42c8d2]['x'],_0x5bfd12[_0x42c8d2]['z']);_0x290a00[0x0]['equalsWithEpsilon'](_0x290a00[_0x290a00['length']-0x1],1e-8)&&_0x290a00['pop']();for(var _0x6e4479=new _0x20eb6b(_0xd3a1ac,_0x290a00,_0x389fa6||_0x44b9ce['a']['LastCreatedScene'],_0x592506),_0x1205cd=0x0;_0x1205cd<_0xfc87a8['length'];_0x1205cd++){_0x127afe=[];for(var _0x4b11d4=0x0;_0x4b11d4<_0xfc87a8[_0x1205cd]['length'];_0x4b11d4++)_0x127afe['push'](new _0x74d525['d'](_0xfc87a8[_0x1205cd][_0x4b11d4]['x'],_0xfc87a8[_0x1205cd][_0x4b11d4]['z']));_0x6e4479['addHole'](_0x127afe);}var _0x463184=_0x6e4479['build'](_0x522f62['updatable'],_0x4b3ac1);return _0x463184['_originalBuilderSideOrientation']=_0x522f62['sideOrientation'],_0xa18063['a']['CreatePolygon'](_0x463184,_0x522f62['sideOrientation'],_0x522f62['faceUV'],_0x522f62['faceColors'],_0x522f62['frontUVs'],_0x522f62['backUVs'],_0x522f62['wrap'])['applyToMesh'](_0x463184,_0x522f62['updatable']),_0x463184;},_0x13a3a9['ExtrudePolygon']=function(_0x4a1a48,_0x4b3016,_0x38fbbd,_0x16a88a){return void 0x0===_0x38fbbd&&(_0x38fbbd=null),void 0x0===_0x16a88a&&(_0x16a88a=earcut),_0x13a3a9['CreatePolygon'](_0x4a1a48,_0x4b3016,_0x38fbbd,_0x16a88a);},_0x13a3a9;}());_0x3cf5e5['a']['CreateLathe']=function(_0x1f7e02,_0x5c0363,_0x1e6f74,_0x212c5d,_0x1e173c,_0x2445fa,_0x25c87f){var _0x3961da={'shape':_0x5c0363,'radius':_0x1e6f74,'tessellation':_0x212c5d,'sideOrientation':_0x25c87f,'updatable':_0x2445fa};return _0x2a4bc7['CreateLathe'](_0x1f7e02,_0x3961da,_0x1e173c);};var _0x2a4bc7=(function(){function _0x296975(){}return _0x296975['CreateLathe']=function(_0x1e067c,_0x1bf59e,_0x156c73){void 0x0===_0x156c73&&(_0x156c73=null);var _0x42e8bb,_0x4f9acd=_0x1bf59e['arc']?_0x1bf59e['arc']<=0x0||_0x1bf59e['arc']>0x1?0x1:_0x1bf59e['arc']:0x1,_0x130ead=void 0x0===_0x1bf59e['closed']||_0x1bf59e['closed'],_0x2be9b8=_0x1bf59e['shape'],_0x43296c=_0x1bf59e['radius']||0x1,_0x3ed35a=_0x1bf59e['tessellation']||0x40,_0x5b874b=_0x1bf59e['clip']||0x0,_0x23254f=_0x1bf59e['updatable'],_0x48666c=_0x3cf5e5['a']['_GetDefaultSideOrientation'](_0x1bf59e['sideOrientation']),_0x211be8=_0x1bf59e['cap']||_0x3cf5e5['a']['NO_CAP'],_0x2f3652=0x2*Math['PI'],_0x4bde30=new Array(),_0x37f957=_0x1bf59e['invertUV']||!0x1,_0x388d4a=0x0,_0x29d3ef=0x0,_0x1e0d7f=_0x2f3652/_0x3ed35a*_0x4f9acd,_0x246462=new Array();for(_0x388d4a=0x0;_0x388d4a<=_0x3ed35a-_0x5b874b;_0x388d4a++){_0x246462=[];for(_0x211be8!=_0x3cf5e5['a']['CAP_START']&&_0x211be8!=_0x3cf5e5['a']['CAP_ALL']||(_0x246462['push'](new _0x74d525['e'](0x0,_0x2be9b8[0x0]['y'],0x0)),_0x246462['push'](new _0x74d525['e'](Math['cos'](_0x388d4a*_0x1e0d7f)*_0x2be9b8[0x0]['x']*_0x43296c,_0x2be9b8[0x0]['y'],Math['sin'](_0x388d4a*_0x1e0d7f)*_0x2be9b8[0x0]['x']*_0x43296c))),_0x29d3ef=0x0;_0x29d3ef<_0x2be9b8['length'];_0x29d3ef++)_0x42e8bb=new _0x74d525['e'](Math['cos'](_0x388d4a*_0x1e0d7f)*_0x2be9b8[_0x29d3ef]['x']*_0x43296c,_0x2be9b8[_0x29d3ef]['y'],Math['sin'](_0x388d4a*_0x1e0d7f)*_0x2be9b8[_0x29d3ef]['x']*_0x43296c),_0x246462['push'](_0x42e8bb);_0x211be8!=_0x3cf5e5['a']['CAP_END']&&_0x211be8!=_0x3cf5e5['a']['CAP_ALL']||(_0x246462['push'](new _0x74d525['e'](Math['cos'](_0x388d4a*_0x1e0d7f)*_0x2be9b8[_0x2be9b8['length']-0x1]['x']*_0x43296c,_0x2be9b8[_0x2be9b8['length']-0x1]['y'],Math['sin'](_0x388d4a*_0x1e0d7f)*_0x2be9b8[_0x2be9b8['length']-0x1]['x']*_0x43296c)),_0x246462['push'](new _0x74d525['e'](0x0,_0x2be9b8[_0x2be9b8['length']-0x1]['y'],0x0))),_0x4bde30['push'](_0x246462);}return _0x9de293['a']['CreateRibbon'](_0x1e067c,{'pathArray':_0x4bde30,'closeArray':_0x130ead,'sideOrientation':_0x48666c,'updatable':_0x23254f,'invertUV':_0x37f957,'frontUVs':_0x1bf59e['frontUVs'],'backUVs':_0x1bf59e['backUVs']},_0x156c73);},_0x296975;}());_0xa18063['a']['CreateTiledPlane']=function(_0x3fdb8d){var _0x12ee6d=_0x3fdb8d['pattern']||_0x3cf5e5['a']['NO_FLIP'],_0x4bd645=_0x3fdb8d['tileWidth']||_0x3fdb8d['tileSize']||0x1,_0xa8195=_0x3fdb8d['tileHeight']||_0x3fdb8d['tileSize']||0x1,_0x45ae00=_0x3fdb8d['alignHorizontal']||0x0,_0x1d46d8=_0x3fdb8d['alignVertical']||0x0,_0x47952c=_0x3fdb8d['width']||_0x3fdb8d['size']||0x1,_0x1757c0=Math['floor'](_0x47952c/_0x4bd645),_0x1e594b=_0x47952c-_0x1757c0*_0x4bd645,_0x1073a9=_0x3fdb8d['height']||_0x3fdb8d['size']||0x1,_0x39278b=Math['floor'](_0x1073a9/_0xa8195),_0x17708f=_0x1073a9-_0x39278b*_0xa8195,_0x3b4b3f=_0x4bd645*_0x1757c0/0x2,_0x1cdbb4=_0xa8195*_0x39278b/0x2,_0x549df3=0x0,_0x42084b=0x0,_0x17fbfd=0x0,_0x34af68=0x0,_0x278656=0x0,_0x4ca6eb=0x0;if(_0x1e594b>0x0||_0x17708f>0x0){_0x17fbfd=-_0x3b4b3f,_0x34af68=-_0x1cdbb4,(_0x278656=_0x3b4b3f,_0x4ca6eb=_0x1cdbb4);switch(_0x45ae00){case _0x3cf5e5['a']['CENTER']:_0x17fbfd-=_0x1e594b/=0x2,_0x278656+=_0x1e594b;break;case _0x3cf5e5['a']['LEFT']:_0x278656+=_0x1e594b,_0x549df3=-_0x1e594b/0x2;break;case _0x3cf5e5['a']['RIGHT']:_0x17fbfd-=_0x1e594b,_0x549df3=_0x1e594b/0x2;}switch(_0x1d46d8){case _0x3cf5e5['a']['CENTER']:_0x34af68-=_0x17708f/=0x2,_0x4ca6eb+=_0x17708f;break;case _0x3cf5e5['a']['BOTTOM']:_0x4ca6eb+=_0x17708f,_0x42084b=-_0x17708f/0x2;break;case _0x3cf5e5['a']['TOP']:_0x34af68-=_0x17708f,_0x42084b=_0x17708f/0x2;}}var _0x5595a8=[],_0x3ee3ed=[],_0x12548=[];_0x12548[0x0]=[0x0,0x0,0x1,0x0,0x1,0x1,0x0,0x1],_0x12548[0x1]=[0x0,0x0,0x1,0x0,0x1,0x1,0x0,0x1],_0x12ee6d!==_0x3cf5e5['a']['ROTATE_TILE']&&_0x12ee6d!==_0x3cf5e5['a']['ROTATE_ROW']||(_0x12548[0x1]=[0x1,0x1,0x0,0x1,0x0,0x0,0x1,0x0]),_0x12ee6d!==_0x3cf5e5['a']['FLIP_TILE']&&_0x12ee6d!==_0x3cf5e5['a']['FLIP_ROW']||(_0x12548[0x1]=[0x1,0x0,0x0,0x0,0x0,0x1,0x1,0x1]),_0x12ee6d!==_0x3cf5e5['a']['FLIP_N_ROTATE_TILE']&&_0x12ee6d!==_0x3cf5e5['a']['FLIP_N_ROTATE_ROW']||(_0x12548[0x1]=[0x0,0x1,0x1,0x1,0x1,0x0,0x0,0x0]);for(var _0x139e59=[],_0x1046c5=[],_0x3f972f=[],_0x507cff=0x0,_0x56bbda=0x0;_0x56bbda<_0x39278b;_0x56bbda++)for(var _0x429b2f=0x0;_0x429b2f<_0x1757c0;_0x429b2f++)_0x5595a8['push'](_0x429b2f*_0x4bd645-_0x3b4b3f+_0x549df3,_0x56bbda*_0xa8195-_0x1cdbb4+_0x42084b,0x0),_0x5595a8['push']((_0x429b2f+0x1)*_0x4bd645-_0x3b4b3f+_0x549df3,_0x56bbda*_0xa8195-_0x1cdbb4+_0x42084b,0x0),_0x5595a8['push']((_0x429b2f+0x1)*_0x4bd645-_0x3b4b3f+_0x549df3,(_0x56bbda+0x1)*_0xa8195-_0x1cdbb4+_0x42084b,0x0),_0x5595a8['push'](_0x429b2f*_0x4bd645-_0x3b4b3f+_0x549df3,(_0x56bbda+0x1)*_0xa8195-_0x1cdbb4+_0x42084b,0x0),_0x3f972f['push'](_0x507cff,_0x507cff+0x1,_0x507cff+0x3,_0x507cff+0x1,_0x507cff+0x2,_0x507cff+0x3),_0x139e59=_0x12ee6d===_0x3cf5e5['a']['FLIP_TILE']||_0x12ee6d===_0x3cf5e5['a']['ROTATE_TILE']||_0x12ee6d===_0x3cf5e5['a']['FLIP_N_ROTATE_TILE']?_0x139e59['concat'](_0x12548[(_0x429b2f%0x2+_0x56bbda%0x2)%0x2]):_0x12ee6d===_0x3cf5e5['a']['FLIP_ROW']||_0x12ee6d===_0x3cf5e5['a']['ROTATE_ROW']||_0x12ee6d===_0x3cf5e5['a']['FLIP_N_ROTATE_ROW']?_0x139e59['concat'](_0x12548[_0x56bbda%0x2]):_0x139e59['concat'](_0x12548[0x0]),_0x1046c5['push'](0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1),_0x3ee3ed['push'](0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1),_0x507cff+=0x4;if(_0x1e594b>0x0||_0x17708f>0x0){var _0x46fdc5,_0x304db7,_0x4980ad,_0x1b4597,_0x438fb3=_0x17708f>0x0&&(_0x1d46d8===_0x3cf5e5['a']['CENTER']||_0x1d46d8===_0x3cf5e5['a']['TOP']),_0x448645=_0x17708f>0x0&&(_0x1d46d8===_0x3cf5e5['a']['CENTER']||_0x1d46d8===_0x3cf5e5['a']['BOTTOM']),_0x268565=_0x1e594b>0x0&&(_0x45ae00===_0x3cf5e5['a']['CENTER']||_0x45ae00===_0x3cf5e5['a']['RIGHT']),_0x53c1ef=_0x1e594b>0x0&&(_0x45ae00===_0x3cf5e5['a']['CENTER']||_0x45ae00===_0x3cf5e5['a']['LEFT']),_0x27f88d=[];if(_0x438fb3&&_0x268565&&(_0x5595a8['push'](_0x17fbfd+_0x549df3,_0x34af68+_0x42084b,0x0),_0x5595a8['push'](-_0x3b4b3f+_0x549df3,_0x34af68+_0x42084b,0x0),_0x5595a8['push'](-_0x3b4b3f+_0x549df3,_0x34af68+_0x17708f+_0x42084b,0x0),_0x5595a8['push'](_0x17fbfd+_0x549df3,_0x34af68+_0x17708f+_0x42084b,0x0),_0x3f972f['push'](_0x507cff,_0x507cff+0x1,_0x507cff+0x3,_0x507cff+0x1,_0x507cff+0x2,_0x507cff+0x3),_0x507cff+=0x4,_0x27f88d=[_0x46fdc5=0x1-_0x1e594b/_0x4bd645,_0x304db7=0x1-_0x17708f/_0xa8195,_0x4980ad=0x1,_0x304db7,_0x4980ad,_0x1b4597=0x1,_0x46fdc5,_0x1b4597],_0x12ee6d===_0x3cf5e5['a']['ROTATE_ROW']&&(_0x27f88d=[0x1-_0x46fdc5,0x1-_0x304db7,0x1-_0x4980ad,0x1-_0x304db7,0x1-_0x4980ad,0x1-_0x1b4597,0x1-_0x46fdc5,0x1-_0x1b4597]),_0x12ee6d===_0x3cf5e5['a']['FLIP_ROW']&&(_0x27f88d=[0x1-_0x46fdc5,_0x304db7,0x1-_0x4980ad,_0x304db7,0x1-_0x4980ad,_0x1b4597,0x1-_0x46fdc5,_0x1b4597]),_0x12ee6d===_0x3cf5e5['a']['FLIP_N_ROTATE_ROW']&&(_0x27f88d=[_0x46fdc5,0x1-_0x304db7,_0x4980ad,0x1-_0x304db7,_0x4980ad,0x1-_0x1b4597,_0x46fdc5,0x1-_0x1b4597]),_0x139e59=_0x139e59['concat'](_0x27f88d),_0x1046c5['push'](0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1),_0x3ee3ed['push'](0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1)),_0x438fb3&&_0x53c1ef&&(_0x5595a8['push'](_0x3b4b3f+_0x549df3,_0x34af68+_0x42084b,0x0),_0x5595a8['push'](_0x278656+_0x549df3,_0x34af68+_0x42084b,0x0),_0x5595a8['push'](_0x278656+_0x549df3,_0x34af68+_0x17708f+_0x42084b,0x0),_0x5595a8['push'](_0x3b4b3f+_0x549df3,_0x34af68+_0x17708f+_0x42084b,0x0),_0x3f972f['push'](_0x507cff,_0x507cff+0x1,_0x507cff+0x3,_0x507cff+0x1,_0x507cff+0x2,_0x507cff+0x3),_0x507cff+=0x4,_0x27f88d=[_0x46fdc5=0x0,_0x304db7=0x1-_0x17708f/_0xa8195,_0x4980ad=_0x1e594b/_0x4bd645,_0x304db7,_0x4980ad,_0x1b4597=0x1,_0x46fdc5,_0x1b4597],(_0x12ee6d===_0x3cf5e5['a']['ROTATE_ROW']||_0x12ee6d===_0x3cf5e5['a']['ROTATE_TILE']&&_0x1757c0%0x2==0x0)&&(_0x27f88d=[0x1-_0x46fdc5,0x1-_0x304db7,0x1-_0x4980ad,0x1-_0x304db7,0x1-_0x4980ad,0x1-_0x1b4597,0x1-_0x46fdc5,0x1-_0x1b4597]),(_0x12ee6d===_0x3cf5e5['a']['FLIP_ROW']||_0x12ee6d===_0x3cf5e5['a']['FLIP_TILE']&&_0x1757c0%0x2==0x0)&&(_0x27f88d=[0x1-_0x46fdc5,_0x304db7,0x1-_0x4980ad,_0x304db7,0x1-_0x4980ad,_0x1b4597,0x1-_0x46fdc5,_0x1b4597]),(_0x12ee6d===_0x3cf5e5['a']['FLIP_N_ROTATE_ROW']||_0x12ee6d===_0x3cf5e5['a']['FLIP_N_ROTATE_TILE']&&_0x1757c0%0x2==0x0)&&(_0x27f88d=[_0x46fdc5,0x1-_0x304db7,_0x4980ad,0x1-_0x304db7,_0x4980ad,0x1-_0x1b4597,_0x46fdc5,0x1-_0x1b4597]),_0x139e59=_0x139e59['concat'](_0x27f88d),_0x1046c5['push'](0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1),_0x3ee3ed['push'](0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1)),_0x448645&&_0x268565&&(_0x5595a8['push'](_0x17fbfd+_0x549df3,_0x1cdbb4+_0x42084b,0x0),_0x5595a8['push'](-_0x3b4b3f+_0x549df3,_0x1cdbb4+_0x42084b,0x0),_0x5595a8['push'](-_0x3b4b3f+_0x549df3,_0x4ca6eb+_0x42084b,0x0),_0x5595a8['push'](_0x17fbfd+_0x549df3,_0x4ca6eb+_0x42084b,0x0),_0x3f972f['push'](_0x507cff,_0x507cff+0x1,_0x507cff+0x3,_0x507cff+0x1,_0x507cff+0x2,_0x507cff+0x3),_0x507cff+=0x4,_0x27f88d=[_0x46fdc5=0x1-_0x1e594b/_0x4bd645,_0x304db7=0x0,_0x4980ad=0x1,_0x304db7,_0x4980ad,_0x1b4597=_0x17708f/_0xa8195,_0x46fdc5,_0x1b4597],(_0x12ee6d===_0x3cf5e5['a']['ROTATE_ROW']&&_0x39278b%0x2==0x1||_0x12ee6d===_0x3cf5e5['a']['ROTATE_TILE']&&_0x39278b%0x1==0x0)&&(_0x27f88d=[0x1-_0x46fdc5,0x1-_0x304db7,0x1-_0x4980ad,0x1-_0x304db7,0x1-_0x4980ad,0x1-_0x1b4597,0x1-_0x46fdc5,0x1-_0x1b4597]),(_0x12ee6d===_0x3cf5e5['a']['FLIP_ROW']&&_0x39278b%0x2==0x1||_0x12ee6d===_0x3cf5e5['a']['FLIP_TILE']&&_0x39278b%0x2==0x0)&&(_0x27f88d=[0x1-_0x46fdc5,_0x304db7,0x1-_0x4980ad,_0x304db7,0x1-_0x4980ad,_0x1b4597,0x1-_0x46fdc5,_0x1b4597]),(_0x12ee6d===_0x3cf5e5['a']['FLIP_N_ROTATE_ROW']&&_0x39278b%0x2==0x1||_0x12ee6d===_0x3cf5e5['a']['FLIP_N_ROTATE_TILE']&&_0x39278b%0x2==0x0)&&(_0x27f88d=[_0x46fdc5,0x1-_0x304db7,_0x4980ad,0x1-_0x304db7,_0x4980ad,0x1-_0x1b4597,_0x46fdc5,0x1-_0x1b4597]),_0x139e59=_0x139e59['concat'](_0x27f88d),_0x1046c5['push'](0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1),_0x3ee3ed['push'](0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1)),_0x448645&&_0x53c1ef&&(_0x5595a8['push'](_0x3b4b3f+_0x549df3,_0x1cdbb4+_0x42084b,0x0),_0x5595a8['push'](_0x278656+_0x549df3,_0x1cdbb4+_0x42084b,0x0),_0x5595a8['push'](_0x278656+_0x549df3,_0x4ca6eb+_0x42084b,0x0),_0x5595a8['push'](_0x3b4b3f+_0x549df3,_0x4ca6eb+_0x42084b,0x0),_0x3f972f['push'](_0x507cff,_0x507cff+0x1,_0x507cff+0x3,_0x507cff+0x1,_0x507cff+0x2,_0x507cff+0x3),_0x507cff+=0x4,_0x27f88d=[_0x46fdc5=0x0,_0x304db7=0x0,_0x4980ad=_0x1e594b/_0x4bd645,_0x304db7,_0x4980ad,_0x1b4597=_0x17708f/_0xa8195,_0x46fdc5,_0x1b4597],(_0x12ee6d===_0x3cf5e5['a']['ROTATE_ROW']&&_0x39278b%0x2==0x1||_0x12ee6d===_0x3cf5e5['a']['ROTATE_TILE']&&(_0x39278b+_0x1757c0)%0x2==0x1)&&(_0x27f88d=[0x1-_0x46fdc5,0x1-_0x304db7,0x1-_0x4980ad,0x1-_0x304db7,0x1-_0x4980ad,0x1-_0x1b4597,0x1-_0x46fdc5,0x1-_0x1b4597]),(_0x12ee6d===_0x3cf5e5['a']['FLIP_ROW']&&_0x39278b%0x2==0x1||_0x12ee6d===_0x3cf5e5['a']['FLIP_TILE']&&(_0x39278b+_0x1757c0)%0x2==0x1)&&(_0x27f88d=[0x1-_0x46fdc5,_0x304db7,0x1-_0x4980ad,_0x304db7,0x1-_0x4980ad,_0x1b4597,0x1-_0x46fdc5,_0x1b4597]),(_0x12ee6d===_0x3cf5e5['a']['FLIP_N_ROTATE_ROW']&&_0x39278b%0x2==0x1||_0x12ee6d===_0x3cf5e5['a']['FLIP_N_ROTATE_TILE']&&(_0x39278b+_0x1757c0)%0x2==0x1)&&(_0x27f88d=[_0x46fdc5,0x1-_0x304db7,_0x4980ad,0x1-_0x304db7,_0x4980ad,0x1-_0x1b4597,_0x46fdc5,0x1-_0x1b4597]),_0x139e59=_0x139e59['concat'](_0x27f88d),_0x1046c5['push'](0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1),_0x3ee3ed['push'](0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1)),_0x438fb3){var _0x33ccd5=[];_0x46fdc5=0x0,_0x304db7=0x1-_0x17708f/_0xa8195,_0x4980ad=0x1,_0x1b4597=0x1,_0x33ccd5[0x0]=[_0x46fdc5,_0x304db7,_0x4980ad,_0x304db7,_0x4980ad,_0x1b4597,_0x46fdc5,_0x1b4597],_0x33ccd5[0x1]=[_0x46fdc5,_0x304db7,_0x4980ad,_0x304db7,_0x4980ad,_0x1b4597,_0x46fdc5,_0x1b4597],_0x12ee6d!==_0x3cf5e5['a']['ROTATE_TILE']&&_0x12ee6d!==_0x3cf5e5['a']['ROTATE_ROW']||(_0x33ccd5[0x1]=[0x1-_0x46fdc5,0x1-_0x304db7,0x1-_0x4980ad,0x1-_0x304db7,0x1-_0x4980ad,0x1-_0x1b4597,0x1-_0x46fdc5,0x1-_0x1b4597]),_0x12ee6d!==_0x3cf5e5['a']['FLIP_TILE']&&_0x12ee6d!==_0x3cf5e5['a']['FLIP_ROW']||(_0x33ccd5[0x1]=[0x1-_0x46fdc5,_0x304db7,0x1-_0x4980ad,_0x304db7,0x1-_0x4980ad,_0x1b4597,0x1-_0x46fdc5,_0x1b4597]),_0x12ee6d!==_0x3cf5e5['a']['FLIP_N_ROTATE_TILE']&&_0x12ee6d!==_0x3cf5e5['a']['FLIP_N_ROTATE_ROW']||(_0x33ccd5[0x1]=[_0x46fdc5,0x1-_0x304db7,_0x4980ad,0x1-_0x304db7,_0x4980ad,0x1-_0x1b4597,_0x46fdc5,0x1-_0x1b4597]);for(_0x429b2f=0x0;_0x429b2f<_0x1757c0;_0x429b2f++)_0x5595a8['push'](_0x429b2f*_0x4bd645-_0x3b4b3f+_0x549df3,_0x34af68+_0x42084b,0x0),_0x5595a8['push']((_0x429b2f+0x1)*_0x4bd645-_0x3b4b3f+_0x549df3,_0x34af68+_0x42084b,0x0),_0x5595a8['push']((_0x429b2f+0x1)*_0x4bd645-_0x3b4b3f+_0x549df3,_0x34af68+_0x17708f+_0x42084b,0x0),_0x5595a8['push'](_0x429b2f*_0x4bd645-_0x3b4b3f+_0x549df3,_0x34af68+_0x17708f+_0x42084b,0x0),_0x3f972f['push'](_0x507cff,_0x507cff+0x1,_0x507cff+0x3,_0x507cff+0x1,_0x507cff+0x2,_0x507cff+0x3),_0x507cff+=0x4,_0x139e59=_0x12ee6d===_0x3cf5e5['a']['FLIP_TILE']||_0x12ee6d===_0x3cf5e5['a']['ROTATE_TILE']||_0x12ee6d===_0x3cf5e5['a']['FLIP_N_ROTATE_TILE']?_0x139e59['concat'](_0x33ccd5[(_0x429b2f+0x1)%0x2]):_0x12ee6d===_0x3cf5e5['a']['FLIP_ROW']||_0x12ee6d===_0x3cf5e5['a']['ROTATE_ROW']||_0x12ee6d===_0x3cf5e5['a']['FLIP_N_ROTATE_ROW']?_0x139e59['concat'](_0x33ccd5[0x1]):_0x139e59['concat'](_0x33ccd5[0x0]),_0x1046c5['push'](0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1),_0x3ee3ed['push'](0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1);}if(_0x448645){var _0xd8c32d=[];_0x46fdc5=0x0,_0x304db7=0x0,_0x4980ad=0x1,_0x1b4597=_0x17708f/_0xa8195,_0xd8c32d[0x0]=[_0x46fdc5,_0x304db7,_0x4980ad,_0x304db7,_0x4980ad,_0x1b4597,_0x46fdc5,_0x1b4597],_0xd8c32d[0x1]=[_0x46fdc5,_0x304db7,_0x4980ad,_0x304db7,_0x4980ad,_0x1b4597,_0x46fdc5,_0x1b4597],_0x12ee6d!==_0x3cf5e5['a']['ROTATE_TILE']&&_0x12ee6d!==_0x3cf5e5['a']['ROTATE_ROW']||(_0xd8c32d[0x1]=[0x1-_0x46fdc5,0x1-_0x304db7,0x1-_0x4980ad,0x1-_0x304db7,0x1-_0x4980ad,0x1-_0x1b4597,0x1-_0x46fdc5,0x1-_0x1b4597]),_0x12ee6d!==_0x3cf5e5['a']['FLIP_TILE']&&_0x12ee6d!==_0x3cf5e5['a']['FLIP_ROW']||(_0xd8c32d[0x1]=[0x1-_0x46fdc5,_0x304db7,0x1-_0x4980ad,_0x304db7,0x1-_0x4980ad,_0x1b4597,0x1-_0x46fdc5,_0x1b4597]),_0x12ee6d!==_0x3cf5e5['a']['FLIP_N_ROTATE_TILE']&&_0x12ee6d!==_0x3cf5e5['a']['FLIP_N_ROTATE_ROW']||(_0xd8c32d[0x1]=[_0x46fdc5,0x1-_0x304db7,_0x4980ad,0x1-_0x304db7,_0x4980ad,0x1-_0x1b4597,_0x46fdc5,0x1-_0x1b4597]);for(_0x429b2f=0x0;_0x429b2f<_0x1757c0;_0x429b2f++)_0x5595a8['push'](_0x429b2f*_0x4bd645-_0x3b4b3f+_0x549df3,_0x4ca6eb-_0x17708f+_0x42084b,0x0),_0x5595a8['push']((_0x429b2f+0x1)*_0x4bd645-_0x3b4b3f+_0x549df3,_0x4ca6eb-_0x17708f+_0x42084b,0x0),_0x5595a8['push']((_0x429b2f+0x1)*_0x4bd645-_0x3b4b3f+_0x549df3,_0x4ca6eb+_0x42084b,0x0),_0x5595a8['push'](_0x429b2f*_0x4bd645-_0x3b4b3f+_0x549df3,_0x4ca6eb+_0x42084b,0x0),_0x3f972f['push'](_0x507cff,_0x507cff+0x1,_0x507cff+0x3,_0x507cff+0x1,_0x507cff+0x2,_0x507cff+0x3),_0x507cff+=0x4,_0x139e59=_0x12ee6d===_0x3cf5e5['a']['FLIP_TILE']||_0x12ee6d===_0x3cf5e5['a']['ROTATE_TILE']||_0x12ee6d===_0x3cf5e5['a']['FLIP_N_ROTATE_TILE']?_0x139e59['concat'](_0xd8c32d[(_0x429b2f+_0x39278b)%0x2]):_0x12ee6d===_0x3cf5e5['a']['FLIP_ROW']||_0x12ee6d===_0x3cf5e5['a']['ROTATE_ROW']||_0x12ee6d===_0x3cf5e5['a']['FLIP_N_ROTATE_ROW']?_0x139e59['concat'](_0xd8c32d[_0x39278b%0x2]):_0x139e59['concat'](_0xd8c32d[0x0]),_0x1046c5['push'](0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1),_0x3ee3ed['push'](0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1);}if(_0x268565){var _0x872eec=[];_0x46fdc5=0x1-_0x1e594b/_0x4bd645,_0x304db7=0x0,_0x4980ad=0x1,_0x1b4597=0x1,_0x872eec[0x0]=[_0x46fdc5,_0x304db7,_0x4980ad,_0x304db7,_0x4980ad,_0x1b4597,_0x46fdc5,_0x1b4597],_0x872eec[0x1]=[_0x46fdc5,_0x304db7,_0x4980ad,_0x304db7,_0x4980ad,_0x1b4597,_0x46fdc5,_0x1b4597],_0x12ee6d!==_0x3cf5e5['a']['ROTATE_TILE']&&_0x12ee6d!==_0x3cf5e5['a']['ROTATE_ROW']||(_0x872eec[0x1]=[0x1-_0x46fdc5,0x1-_0x304db7,0x1-_0x4980ad,0x1-_0x304db7,0x1-_0x4980ad,0x1-_0x1b4597,0x1-_0x46fdc5,0x1-_0x1b4597]),_0x12ee6d!==_0x3cf5e5['a']['FLIP_TILE']&&_0x12ee6d!==_0x3cf5e5['a']['FLIP_ROW']||(_0x872eec[0x1]=[0x1-_0x46fdc5,_0x304db7,0x1-_0x4980ad,_0x304db7,0x1-_0x4980ad,_0x1b4597,0x1-_0x46fdc5,_0x1b4597]),_0x12ee6d!==_0x3cf5e5['a']['FLIP_N_ROTATE_TILE']&&_0x12ee6d!==_0x3cf5e5['a']['FLIP_N_ROTATE_ROW']||(_0x872eec[0x1]=[_0x46fdc5,0x1-_0x304db7,_0x4980ad,0x1-_0x304db7,_0x4980ad,0x1-_0x1b4597,_0x46fdc5,0x1-_0x1b4597]);for(_0x56bbda=0x0;_0x56bbda<_0x39278b;_0x56bbda++)_0x5595a8['push'](_0x17fbfd+_0x549df3,_0x56bbda*_0xa8195-_0x1cdbb4+_0x42084b,0x0),_0x5595a8['push'](_0x17fbfd+_0x1e594b+_0x549df3,_0x56bbda*_0xa8195-_0x1cdbb4+_0x42084b,0x0),_0x5595a8['push'](_0x17fbfd+_0x1e594b+_0x549df3,(_0x56bbda+0x1)*_0xa8195-_0x1cdbb4+_0x42084b,0x0),_0x5595a8['push'](_0x17fbfd+_0x549df3,(_0x56bbda+0x1)*_0xa8195-_0x1cdbb4+_0x42084b,0x0),_0x3f972f['push'](_0x507cff,_0x507cff+0x1,_0x507cff+0x3,_0x507cff+0x1,_0x507cff+0x2,_0x507cff+0x3),_0x507cff+=0x4,_0x139e59=_0x12ee6d===_0x3cf5e5['a']['FLIP_TILE']||_0x12ee6d===_0x3cf5e5['a']['ROTATE_TILE']||_0x12ee6d===_0x3cf5e5['a']['FLIP_N_ROTATE_TILE']?_0x139e59['concat'](_0x872eec[(_0x56bbda+0x1)%0x2]):_0x12ee6d===_0x3cf5e5['a']['FLIP_ROW']||_0x12ee6d===_0x3cf5e5['a']['ROTATE_ROW']||_0x12ee6d===_0x3cf5e5['a']['FLIP_N_ROTATE_ROW']?_0x139e59['concat'](_0x872eec[_0x56bbda%0x2]):_0x139e59['concat'](_0x872eec[0x0]),_0x1046c5['push'](0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1),_0x3ee3ed['push'](0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1);}if(_0x53c1ef){var _0x33f489=[];_0x46fdc5=0x0,_0x304db7=0x0,_0x4980ad=_0x1e594b/_0xa8195,_0x1b4597=0x1,_0x33f489[0x0]=[_0x46fdc5,_0x304db7,_0x4980ad,_0x304db7,_0x4980ad,_0x1b4597,_0x46fdc5,_0x1b4597],_0x33f489[0x1]=[_0x46fdc5,_0x304db7,_0x4980ad,_0x304db7,_0x4980ad,_0x1b4597,_0x46fdc5,_0x1b4597],_0x12ee6d!==_0x3cf5e5['a']['ROTATE_TILE']&&_0x12ee6d!==_0x3cf5e5['a']['ROTATE_ROW']||(_0x33f489[0x1]=[0x1-_0x46fdc5,0x1-_0x304db7,0x1-_0x4980ad,0x1-_0x304db7,0x1-_0x4980ad,0x1-_0x1b4597,0x1-_0x46fdc5,0x1-_0x1b4597]),_0x12ee6d!==_0x3cf5e5['a']['FLIP_TILE']&&_0x12ee6d!==_0x3cf5e5['a']['FLIP_ROW']||(_0x33f489[0x1]=[0x1-_0x46fdc5,_0x304db7,0x1-_0x4980ad,_0x304db7,0x1-_0x4980ad,_0x1b4597,0x1-_0x46fdc5,_0x1b4597]),_0x12ee6d!==_0x3cf5e5['a']['FLIP_N_ROTATE_TILE']&&_0x12ee6d!==_0x3cf5e5['a']['FLIP_N_ROTATE_ROW']||(_0x33f489[0x1]=[_0x46fdc5,0x1-_0x304db7,_0x4980ad,0x1-_0x304db7,_0x4980ad,0x1-_0x1b4597,_0x46fdc5,0x1-_0x1b4597]);for(_0x56bbda=0x0;_0x56bbda<_0x39278b;_0x56bbda++)_0x5595a8['push'](_0x278656-_0x1e594b+_0x549df3,_0x56bbda*_0xa8195-_0x1cdbb4+_0x42084b,0x0),_0x5595a8['push'](_0x278656+_0x549df3,_0x56bbda*_0xa8195-_0x1cdbb4+_0x42084b,0x0),_0x5595a8['push'](_0x278656+_0x549df3,(_0x56bbda+0x1)*_0xa8195-_0x1cdbb4+_0x42084b,0x0),_0x5595a8['push'](_0x278656-_0x1e594b+_0x549df3,(_0x56bbda+0x1)*_0xa8195-_0x1cdbb4+_0x42084b,0x0),_0x3f972f['push'](_0x507cff,_0x507cff+0x1,_0x507cff+0x3,_0x507cff+0x1,_0x507cff+0x2,_0x507cff+0x3),_0x507cff+=0x4,_0x139e59=_0x12ee6d===_0x3cf5e5['a']['FLIP_TILE']||_0x12ee6d===_0x3cf5e5['a']['ROTATE_TILE']||_0x12ee6d===_0x3cf5e5['a']['FLIP_N_ROTATE_TILE']?_0x139e59['concat'](_0x33f489[(_0x56bbda+_0x1757c0)%0x2]):_0x12ee6d===_0x3cf5e5['a']['FLIP_ROW']||_0x12ee6d===_0x3cf5e5['a']['ROTATE_ROW']||_0x12ee6d===_0x3cf5e5['a']['FLIP_N_ROTATE_ROW']?_0x139e59['concat'](_0x33f489[_0x56bbda%0x2]):_0x139e59['concat'](_0x33f489[0x0]),_0x1046c5['push'](0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1,0x1),_0x3ee3ed['push'](0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1,0x0,0x0,-0x1);}}var _0x533a26=0x0===_0x3fdb8d['sideOrientation']?0x0:_0x3fdb8d['sideOrientation']||_0xa18063['a']['DEFAULTSIDE'];_0xa18063['a']['_ComputeSides'](_0x533a26,_0x5595a8,_0x3f972f,_0x3ee3ed,_0x139e59,_0x3fdb8d['frontUVs'],_0x3fdb8d['backUVs']);var _0x1a9fb5=new _0xa18063['a']();_0x1a9fb5['indices']=_0x3f972f,_0x1a9fb5['positions']=_0x5595a8,_0x1a9fb5['normals']=_0x3ee3ed,_0x1a9fb5['uvs']=_0x139e59;var _0x261618=_0x533a26===_0xa18063['a']['DOUBLESIDE']?_0x1046c5['concat'](_0x1046c5):_0x1046c5;return _0x1a9fb5['colors']=_0x261618,_0x1a9fb5;};var _0x8a5c03=(function(){function _0x39d36d(){}return _0x39d36d['CreateTiledPlane']=function(_0x304c0d,_0x48990e,_0x260e71){void 0x0===_0x260e71&&(_0x260e71=null);var _0x471601=new _0x3cf5e5['a'](_0x304c0d,_0x260e71);return _0x48990e['sideOrientation']=_0x3cf5e5['a']['_GetDefaultSideOrientation'](_0x48990e['sideOrientation']),_0x471601['_originalBuilderSideOrientation']=_0x48990e['sideOrientation'],_0xa18063['a']['CreateTiledPlane'](_0x48990e)['applyToMesh'](_0x471601,_0x48990e['updatable']),_0x471601;},_0x39d36d;}());_0x3cf5e5['a']['CreateTube']=function(_0x1af94f,_0x3984a6,_0x4b3f56,_0x4dde72,_0x587064,_0x148f54,_0x49eebe,_0x4af7bb,_0x5d555e,_0x11b57a){var _0x347b94={'path':_0x3984a6,'radius':_0x4b3f56,'tessellation':_0x4dde72,'radiusFunction':_0x587064,'arc':0x1,'cap':_0x148f54,'updatable':_0x4af7bb,'sideOrientation':_0x5d555e,'instance':_0x11b57a};return _0x124f37['CreateTube'](_0x1af94f,_0x347b94,_0x49eebe);};var _0x124f37=(function(){function _0x536d41(){}return _0x536d41['CreateTube']=function(_0x4a6507,_0x3fbb30,_0x2411a3){void 0x0===_0x2411a3&&(_0x2411a3=null);var _0x3de4b8=_0x3fbb30['path'],_0x3f466d=_0x3fbb30['instance'],_0x10cc5e=0x1;void 0x0!==_0x3fbb30['radius']?_0x10cc5e=_0x3fbb30['radius']:_0x3f466d&&(_0x10cc5e=_0x3f466d['_creationDataStorage']['radius']);var _0x4b7e03=_0x3fbb30['tessellation']||0x40,_0x362c5c=_0x3fbb30['radiusFunction']||null,_0x3e6709=_0x3fbb30['cap']||_0x3cf5e5['a']['NO_CAP'],_0x186dfb=_0x3fbb30['invertUV']||!0x1,_0x52597a=_0x3fbb30['updatable'],_0x598426=_0x3cf5e5['a']['_GetDefaultSideOrientation'](_0x3fbb30['sideOrientation']);_0x3fbb30['arc']=_0x3fbb30['arc']&&(_0x3fbb30['arc']<=0x0||_0x3fbb30['arc']>0x1)?0x1:_0x3fbb30['arc']||0x1;var _0x44e014,_0x206d23,_0x1a6a18=function(_0x4def07,_0x1cb018,_0x20d4bb,_0x394601,_0xf43b9f,_0x27978f,_0x12494a,_0x23e29c){for(var _0x49d90a,_0x3eac45,_0x180931,_0x5effdf,_0x4202bd=_0x1cb018['getTangents'](),_0x4e6895=_0x1cb018['getNormals'](),_0x4ae2a7=_0x1cb018['getDistances'](),_0x2cb7da=0x2*Math['PI']/_0xf43b9f*_0x23e29c,_0x176318=_0x27978f||function(){return _0x394601;},_0x3eeed4=_0x74d525['c']['Matrix'][0x0],_0x33f165=_0x12494a===_0x3cf5e5['a']['NO_CAP']||_0x12494a===_0x3cf5e5['a']['CAP_END']?0x0:0x2,_0x44d41d=0x0;_0x44d41d<_0x4def07['length'];_0x44d41d++){_0x3eac45=_0x176318(_0x44d41d,_0x4ae2a7[_0x44d41d]),_0x49d90a=Array(),_0x180931=_0x4e6895[_0x44d41d];for(var _0x550e55=0x0;_0x550e55<_0xf43b9f;_0x550e55++)_0x74d525['a']['RotationAxisToRef'](_0x4202bd[_0x44d41d],_0x2cb7da*_0x550e55,_0x3eeed4),_0x5effdf=_0x49d90a[_0x550e55]?_0x49d90a[_0x550e55]:_0x74d525['e']['Zero'](),_0x74d525['e']['TransformCoordinatesToRef'](_0x180931,_0x3eeed4,_0x5effdf),_0x5effdf['scaleInPlace'](_0x3eac45)['addInPlace'](_0x4def07[_0x44d41d]),_0x49d90a[_0x550e55]=_0x5effdf;_0x20d4bb[_0x33f165]=_0x49d90a,_0x33f165++;}var _0xac3b9a=function(_0x182400,_0x52a704){for(var _0x517fcb=Array(),_0x225fee=0x0;_0x225fee<_0x182400;_0x225fee++)_0x517fcb['push'](_0x4def07[_0x52a704]);return _0x517fcb;};switch(_0x12494a){case _0x3cf5e5['a']['NO_CAP']:break;case _0x3cf5e5['a']['CAP_START']:_0x20d4bb[0x0]=_0xac3b9a(_0xf43b9f,0x0),_0x20d4bb[0x1]=_0x20d4bb[0x2]['slice'](0x0);break;case _0x3cf5e5['a']['CAP_END']:_0x20d4bb[_0x33f165]=_0x20d4bb[_0x33f165-0x1]['slice'](0x0),_0x20d4bb[_0x33f165+0x1]=_0xac3b9a(_0xf43b9f,_0x4def07['length']-0x1);break;case _0x3cf5e5['a']['CAP_ALL']:_0x20d4bb[0x0]=_0xac3b9a(_0xf43b9f,0x0),_0x20d4bb[0x1]=_0x20d4bb[0x2]['slice'](0x0),_0x20d4bb[_0x33f165]=_0x20d4bb[_0x33f165-0x1]['slice'](0x0),_0x20d4bb[_0x33f165+0x1]=_0xac3b9a(_0xf43b9f,_0x4def07['length']-0x1);}return _0x20d4bb;};if(_0x3f466d){var _0x2131cc=_0x3f466d['_creationDataStorage'],_0x44bd37=_0x3fbb30['arc']||_0x2131cc['arc'];return _0x206d23=_0x1a6a18(_0x3de4b8,_0x44e014=_0x2131cc['path3D']['update'](_0x3de4b8),_0x2131cc['pathArray'],_0x10cc5e,_0x2131cc['tessellation'],_0x362c5c,_0x2131cc['cap'],_0x44bd37),_0x3f466d=_0x9de293['a']['CreateRibbon']('',{'pathArray':_0x206d23,'instance':_0x3f466d}),_0x2131cc['path3D']=_0x44e014,_0x2131cc['pathArray']=_0x206d23,_0x2131cc['arc']=_0x44bd37,_0x2131cc['radius']=_0x10cc5e,_0x3f466d;}_0x206d23=_0x1a6a18(_0x3de4b8,_0x44e014=new _0x5e9f26['g'](_0x3de4b8),new Array(),_0x10cc5e,_0x4b7e03,_0x362c5c,_0x3e6709=_0x3e6709<0x0||_0x3e6709>0x3?0x0:_0x3e6709,_0x3fbb30['arc']);var _0x9c51b6=_0x9de293['a']['CreateRibbon'](_0x4a6507,{'pathArray':_0x206d23,'closePath':!0x0,'closeArray':!0x1,'updatable':_0x52597a,'sideOrientation':_0x598426,'invertUV':_0x186dfb,'frontUVs':_0x3fbb30['frontUVs'],'backUVs':_0x3fbb30['backUVs']},_0x2411a3);return _0x9c51b6['_creationDataStorage']['pathArray']=_0x206d23,_0x9c51b6['_creationDataStorage']['path3D']=_0x44e014,_0x9c51b6['_creationDataStorage']['tessellation']=_0x4b7e03,_0x9c51b6['_creationDataStorage']['cap']=_0x3e6709,_0x9c51b6['_creationDataStorage']['arc']=_0x3fbb30['arc'],_0x9c51b6['_creationDataStorage']['radius']=_0x10cc5e,_0x9c51b6;},_0x536d41;}());_0xa18063['a']['CreateIcoSphere']=function(_0x1d96a2){var _0x4b7299,_0xe47b2a=_0x1d96a2['sideOrientation']||_0xa18063['a']['DEFAULTSIDE'],_0x3e043=_0x1d96a2['radius']||0x1,_0x4db339=void 0x0===_0x1d96a2['flat']||_0x1d96a2['flat'],_0x47df4e=_0x1d96a2['subdivisions']||0x4,_0x32b8b9=_0x1d96a2['radiusX']||_0x3e043,_0x1ab5cc=_0x1d96a2['radiusY']||_0x3e043,_0x308b97=_0x1d96a2['radiusZ']||_0x3e043,_0x2aa26b=(0x1+Math['sqrt'](0x5))/0x2,_0x44d26f=[-0x1,_0x2aa26b,-0x0,0x1,_0x2aa26b,0x0,-0x1,-_0x2aa26b,0x0,0x1,-_0x2aa26b,0x0,0x0,-0x1,-_0x2aa26b,0x0,0x1,-_0x2aa26b,0x0,-0x1,_0x2aa26b,0x0,0x1,_0x2aa26b,_0x2aa26b,0x0,0x1,_0x2aa26b,0x0,-0x1,-_0x2aa26b,0x0,0x1,-_0x2aa26b,0x0,-0x1],_0x794004=[0x0,0xb,0x5,0x0,0x5,0x1,0x0,0x1,0x7,0x0,0x7,0xa,0xc,0x16,0x17,0x1,0x5,0x14,0x5,0xb,0x4,0x17,0x16,0xd,0x16,0x12,0x6,0x7,0x1,0x8,0xe,0x15,0x4,0xe,0x4,0x2,0x10,0xd,0x6,0xf,0x6,0x13,0x3,0x8,0x9,0x4,0x15,0x5,0xd,0x11,0x17,0x6,0xd,0x16,0x13,0x6,0x12,0x9,0x8,0x1],_0x3737fd=[0x0,0x1,0x2,0x3,0x4,0x5,0x6,0x7,0x8,0x9,0xa,0xb,0x0,0x2,0x3,0x3,0x3,0x4,0x7,0x8,0x9,0x9,0xa,0xb],_0x28bbf4=[0x5,0x1,0x3,0x1,0x6,0x4,0x0,0x0,0x5,0x3,0x4,0x2,0x2,0x2,0x4,0x0,0x2,0x0,0x1,0x1,0x6,0x0,0x6,0x2,0x0,0x4,0x3,0x3,0x4,0x4,0x3,0x1,0x4,0x2,0x4,0x4,0x0,0x2,0x1,0x1,0x2,0x2,0x3,0x3,0x1,0x3,0x2,0x4],_0x32aba4=[0x0,0x0,0x0,0x0,0x1,0x0,0x0,0x1,0x1,0x0,0x0,0x0,0x1,0x1,0x0,0x0,0x1,0x1,0x1,0x0],_0xe8f06=new Array(),_0x38598b=new Array(),_0x3cb40c=new Array(),_0x5bbb91=new Array(),_0x247a42=0x0,_0x5a2389=new Array(0x3),_0x1ab5b3=new Array(0x3);for(_0x4b7299=0x0;_0x4b7299<0x3;_0x4b7299++)_0x5a2389[_0x4b7299]=_0x74d525['e']['Zero'](),_0x1ab5b3[_0x4b7299]=_0x74d525['d']['Zero']();for(var _0x355977=0x0;_0x355977<0x14;_0x355977++){for(_0x4b7299=0x0;_0x4b7299<0x3;_0x4b7299++){var _0x31f4e1=_0x794004[0x3*_0x355977+_0x4b7299];_0x5a2389[_0x4b7299]['copyFromFloats'](_0x44d26f[0x3*_0x3737fd[_0x31f4e1]],_0x44d26f[0x3*_0x3737fd[_0x31f4e1]+0x1],_0x44d26f[0x3*_0x3737fd[_0x31f4e1]+0x2]),_0x5a2389[_0x4b7299]['normalize']()['scaleInPlace'](_0x3e043),_0x1ab5b3[_0x4b7299]['copyFromFloats'](_0x28bbf4[0x2*_0x31f4e1]*(0x8a/0x400)+0x3c/0x400+_0x32aba4[_0x355977]*(-0x28/0x400),_0x28bbf4[0x2*_0x31f4e1+0x1]*(0xef/0x400)+0x1a/0x400+_0x32aba4[_0x355977]*(0x14/0x400));}for(var _0x4dac53=function(_0x4805ea,_0x4f7ece,_0x2eda98,_0x2d836c){var _0x5e0286,_0x452638=_0x74d525['e']['Lerp'](_0x5a2389[0x0],_0x5a2389[0x2],_0x4f7ece/_0x47df4e),_0x3ff318=_0x74d525['e']['Lerp'](_0x5a2389[0x1],_0x5a2389[0x2],_0x4f7ece/_0x47df4e),_0x13663f=_0x47df4e===_0x4f7ece?_0x5a2389[0x2]:_0x74d525['e']['Lerp'](_0x452638,_0x3ff318,_0x4805ea/(_0x47df4e-_0x4f7ece));if(_0x13663f['normalize'](),_0x4db339){var _0xbaa61e=_0x74d525['e']['Lerp'](_0x5a2389[0x0],_0x5a2389[0x2],_0x2d836c/_0x47df4e),_0x1682d9=_0x74d525['e']['Lerp'](_0x5a2389[0x1],_0x5a2389[0x2],_0x2d836c/_0x47df4e);_0x5e0286=_0x74d525['e']['Lerp'](_0xbaa61e,_0x1682d9,_0x2eda98/(_0x47df4e-_0x2d836c));}else _0x5e0286=new _0x74d525['e'](_0x13663f['x'],_0x13663f['y'],_0x13663f['z']);_0x5e0286['x']/=_0x32b8b9,_0x5e0286['y']/=_0x1ab5cc,_0x5e0286['z']/=_0x308b97,_0x5e0286['normalize']();var _0x3c888=_0x74d525['d']['Lerp'](_0x1ab5b3[0x0],_0x1ab5b3[0x2],_0x4f7ece/_0x47df4e),_0x26e063=_0x74d525['d']['Lerp'](_0x1ab5b3[0x1],_0x1ab5b3[0x2],_0x4f7ece/_0x47df4e),_0x442e96=_0x47df4e===_0x4f7ece?_0x1ab5b3[0x2]:_0x74d525['d']['Lerp'](_0x3c888,_0x26e063,_0x4805ea/(_0x47df4e-_0x4f7ece));_0x38598b['push'](_0x13663f['x']*_0x32b8b9,_0x13663f['y']*_0x1ab5cc,_0x13663f['z']*_0x308b97),_0x3cb40c['push'](_0x5e0286['x'],_0x5e0286['y'],_0x5e0286['z']),_0x5bbb91['push'](_0x442e96['x'],_0x442e96['y']),_0xe8f06['push'](_0x247a42),_0x247a42++;},_0x37de29=0x0;_0x37de29<_0x47df4e;_0x37de29++)for(var _0x2c6010=0x0;_0x2c6010+_0x37de29<_0x47df4e;_0x2c6010++)_0x4dac53(_0x2c6010,_0x37de29,_0x2c6010+0x1/0x3,_0x37de29+0x1/0x3),_0x4dac53(_0x2c6010+0x1,_0x37de29,_0x2c6010+0x1/0x3,_0x37de29+0x1/0x3),_0x4dac53(_0x2c6010,_0x37de29+0x1,_0x2c6010+0x1/0x3,_0x37de29+0x1/0x3),_0x2c6010+_0x37de29+0x1<_0x47df4e&&(_0x4dac53(_0x2c6010+0x1,_0x37de29,_0x2c6010+0x2/0x3,_0x37de29+0x2/0x3),_0x4dac53(_0x2c6010+0x1,_0x37de29+0x1,_0x2c6010+0x2/0x3,_0x37de29+0x2/0x3),_0x4dac53(_0x2c6010,_0x37de29+0x1,_0x2c6010+0x2/0x3,_0x37de29+0x2/0x3));}_0xa18063['a']['_ComputeSides'](_0xe47b2a,_0x38598b,_0xe8f06,_0x3cb40c,_0x5bbb91,_0x1d96a2['frontUVs'],_0x1d96a2['backUVs']);var _0x2fffe1=new _0xa18063['a']();return _0x2fffe1['indices']=_0xe8f06,_0x2fffe1['positions']=_0x38598b,_0x2fffe1['normals']=_0x3cb40c,_0x2fffe1['uvs']=_0x5bbb91,_0x2fffe1;},_0x3cf5e5['a']['CreateIcoSphere']=function(_0x4bef1d,_0x1b3de4,_0x54efd7){return _0x3acb17['CreateIcoSphere'](_0x4bef1d,_0x1b3de4,_0x54efd7);};var _0x3acb17=(function(){function _0x2341a5(){}return _0x2341a5['CreateIcoSphere']=function(_0x572a6a,_0x4a02aa,_0x34fab9){void 0x0===_0x34fab9&&(_0x34fab9=null);var _0x41e6b4=new _0x3cf5e5['a'](_0x572a6a,_0x34fab9);return _0x4a02aa['sideOrientation']=_0x3cf5e5['a']['_GetDefaultSideOrientation'](_0x4a02aa['sideOrientation']),_0x41e6b4['_originalBuilderSideOrientation']=_0x4a02aa['sideOrientation'],_0xa18063['a']['CreateIcoSphere'](_0x4a02aa)['applyToMesh'](_0x41e6b4,_0x4a02aa['updatable']),_0x41e6b4;},_0x2341a5;}());_0x3cf5e5['a']['CreateDecal']=function(_0x35daa3,_0x29b59b,_0x5d98b1,_0xcd126d,_0x41a0e0,_0x38182d){var _0x347c20={'position':_0x5d98b1,'normal':_0xcd126d,'size':_0x41a0e0,'angle':_0x38182d};return _0x458e78['CreateDecal'](_0x35daa3,_0x29b59b,_0x347c20);};var _0x458e78=(function(){function _0x2918d4(){}return _0x2918d4['CreateDecal']=function(_0x31cf1e,_0x381a0e,_0x563e55){var _0x183518=_0x381a0e['getIndices'](),_0x4b1f8e=_0x381a0e['getVerticesData'](_0x212fbd['b']['PositionKind']),_0x2a8017=_0x381a0e['getVerticesData'](_0x212fbd['b']['NormalKind']),_0x14545e=_0x563e55['position']||_0x74d525['e']['Zero'](),_0x5f1846=_0x563e55['normal']||_0x74d525['e']['Up'](),_0x372e0a=_0x563e55['size']||_0x74d525['e']['One'](),_0x21e2fc=_0x563e55['angle']||0x0;if(!_0x5f1846){var _0x43f59b=new _0x74d525['e'](0x0,0x0,0x1),_0x9d7b63=_0x381a0e['getScene']()['activeCamera'],_0x447954=_0x74d525['e']['TransformCoordinates'](_0x43f59b,_0x9d7b63['getWorldMatrix']());_0x5f1846=_0x9d7b63['globalPosition']['subtract'](_0x447954);}var _0x158c5f=-Math['atan2'](_0x5f1846['z'],_0x5f1846['x'])-Math['PI']/0x2,_0x350e3b=Math['sqrt'](_0x5f1846['x']*_0x5f1846['x']+_0x5f1846['z']*_0x5f1846['z']),_0x4027b0=Math['atan2'](_0x5f1846['y'],_0x350e3b),_0x23500c=_0x74d525['a']['RotationYawPitchRoll'](_0x158c5f,_0x4027b0,_0x21e2fc)['multiply'](_0x74d525['a']['Translation'](_0x14545e['x'],_0x14545e['y'],_0x14545e['z'])),_0xe4edec=_0x74d525['a']['Invert'](_0x23500c),_0x2f01c6=_0x381a0e['getWorldMatrix']()['multiply'](_0xe4edec),_0x51ba01=new _0xa18063['a']();_0x51ba01['indices']=[],_0x51ba01['positions']=[],_0x51ba01['normals']=[],_0x51ba01['uvs']=[];for(var _0x59fae2=0x0,_0x10a71c=function(_0x2ff198){var _0x4bc8ba=new _0x5a7f8f();if(!_0x183518||!_0x4b1f8e||!_0x2a8017)return _0x4bc8ba;var _0x33be85=_0x183518[_0x2ff198];return _0x4bc8ba['position']=new _0x74d525['e'](_0x4b1f8e[0x3*_0x33be85],_0x4b1f8e[0x3*_0x33be85+0x1],_0x4b1f8e[0x3*_0x33be85+0x2]),_0x4bc8ba['position']=_0x74d525['e']['TransformCoordinates'](_0x4bc8ba['position'],_0x2f01c6),_0x4bc8ba['normal']=new _0x74d525['e'](_0x2a8017[0x3*_0x33be85],_0x2a8017[0x3*_0x33be85+0x1],_0x2a8017[0x3*_0x33be85+0x2]),_0x4bc8ba['normal']=_0x74d525['e']['TransformNormal'](_0x4bc8ba['normal'],_0x2f01c6),_0x4bc8ba;},_0xd46cf=function(_0x36796f,_0x46a282){if(0x0===_0x36796f['length'])return _0x36796f;for(var _0x25bf2e=0.5*Math['abs'](_0x74d525['e']['Dot'](_0x372e0a,_0x46a282)),_0x444783=function(_0x54bdee,_0x26103b){var _0x4b121b=_0x74d525['e']['GetClipFactor'](_0x54bdee['position'],_0x26103b['position'],_0x46a282,_0x25bf2e);return new _0x5a7f8f(_0x74d525['e']['Lerp'](_0x54bdee['position'],_0x26103b['position'],_0x4b121b),_0x74d525['e']['Lerp'](_0x54bdee['normal'],_0x26103b['normal'],_0x4b121b));},_0x276b12=new Array(),_0x38443a=0x0;_0x38443a<_0x36796f['length'];_0x38443a+=0x3){var _0x117347,_0x16907f,_0x41e4b9,_0x49d1db=null,_0x46c8ef=null,_0x4e4f9d=null,_0xa0a907=null;switch(((_0x117347=_0x74d525['e']['Dot'](_0x36796f[_0x38443a]['position'],_0x46a282)-_0x25bf2e>0x0)?0x1:0x0)+((_0x16907f=_0x74d525['e']['Dot'](_0x36796f[_0x38443a+0x1]['position'],_0x46a282)-_0x25bf2e>0x0)?0x1:0x0)+((_0x41e4b9=_0x74d525['e']['Dot'](_0x36796f[_0x38443a+0x2]['position'],_0x46a282)-_0x25bf2e>0x0)?0x1:0x0)){case 0x0:_0x276b12['push'](_0x36796f[_0x38443a]),_0x276b12['push'](_0x36796f[_0x38443a+0x1]),_0x276b12['push'](_0x36796f[_0x38443a+0x2]);break;case 0x1:if(_0x117347&&(_0x49d1db=_0x36796f[_0x38443a+0x1],_0x46c8ef=_0x36796f[_0x38443a+0x2],_0x4e4f9d=_0x444783(_0x36796f[_0x38443a],_0x49d1db),_0xa0a907=_0x444783(_0x36796f[_0x38443a],_0x46c8ef)),_0x16907f){_0x49d1db=_0x36796f[_0x38443a],_0x46c8ef=_0x36796f[_0x38443a+0x2],_0x4e4f9d=_0x444783(_0x36796f[_0x38443a+0x1],_0x49d1db),_0xa0a907=_0x444783(_0x36796f[_0x38443a+0x1],_0x46c8ef),_0x276b12['push'](_0x4e4f9d),_0x276b12['push'](_0x46c8ef['clone']()),_0x276b12['push'](_0x49d1db['clone']()),_0x276b12['push'](_0x46c8ef['clone']()),_0x276b12['push'](_0x4e4f9d['clone']()),_0x276b12['push'](_0xa0a907);break;}_0x41e4b9&&(_0x49d1db=_0x36796f[_0x38443a],_0x46c8ef=_0x36796f[_0x38443a+0x1],_0x4e4f9d=_0x444783(_0x36796f[_0x38443a+0x2],_0x49d1db),_0xa0a907=_0x444783(_0x36796f[_0x38443a+0x2],_0x46c8ef)),_0x49d1db&&_0x46c8ef&&_0x4e4f9d&&_0xa0a907&&(_0x276b12['push'](_0x49d1db['clone']()),_0x276b12['push'](_0x46c8ef['clone']()),_0x276b12['push'](_0x4e4f9d),_0x276b12['push'](_0xa0a907),_0x276b12['push'](_0x4e4f9d['clone']()),_0x276b12['push'](_0x46c8ef['clone']()));break;case 0x2:_0x117347||(_0x46c8ef=_0x444783(_0x49d1db=_0x36796f[_0x38443a]['clone'](),_0x36796f[_0x38443a+0x1]),_0x4e4f9d=_0x444783(_0x49d1db,_0x36796f[_0x38443a+0x2]),_0x276b12['push'](_0x49d1db),_0x276b12['push'](_0x46c8ef),_0x276b12['push'](_0x4e4f9d)),_0x16907f||(_0x46c8ef=_0x444783(_0x49d1db=_0x36796f[_0x38443a+0x1]['clone'](),_0x36796f[_0x38443a+0x2]),_0x4e4f9d=_0x444783(_0x49d1db,_0x36796f[_0x38443a]),_0x276b12['push'](_0x49d1db),_0x276b12['push'](_0x46c8ef),_0x276b12['push'](_0x4e4f9d)),_0x41e4b9||(_0x46c8ef=_0x444783(_0x49d1db=_0x36796f[_0x38443a+0x2]['clone'](),_0x36796f[_0x38443a]),_0x4e4f9d=_0x444783(_0x49d1db,_0x36796f[_0x38443a+0x1]),_0x276b12['push'](_0x49d1db),_0x276b12['push'](_0x46c8ef),_0x276b12['push'](_0x4e4f9d));}}return _0x276b12;},_0x2318f7=0x0;_0x2318f7<_0x183518['length'];_0x2318f7+=0x3){var _0x1e6026=new Array();if(_0x1e6026['push'](_0x10a71c(_0x2318f7)),_0x1e6026['push'](_0x10a71c(_0x2318f7+0x1)),_0x1e6026['push'](_0x10a71c(_0x2318f7+0x2)),_0x1e6026=_0xd46cf(_0x1e6026,new _0x74d525['e'](0x1,0x0,0x0)),_0x1e6026=_0xd46cf(_0x1e6026,new _0x74d525['e'](-0x1,0x0,0x0)),_0x1e6026=_0xd46cf(_0x1e6026,new _0x74d525['e'](0x0,0x1,0x0)),_0x1e6026=_0xd46cf(_0x1e6026,new _0x74d525['e'](0x0,-0x1,0x0)),_0x1e6026=_0xd46cf(_0x1e6026,new _0x74d525['e'](0x0,0x0,0x1)),0x0!==(_0x1e6026=_0xd46cf(_0x1e6026,new _0x74d525['e'](0x0,0x0,-0x1)))['length'])for(var _0x16919c=0x0;_0x16919c<_0x1e6026['length'];_0x16919c++){var _0x4611e8=_0x1e6026[_0x16919c];_0x51ba01['indices']['push'](_0x59fae2),_0x4611e8['position']['toArray'](_0x51ba01['positions'],0x3*_0x59fae2),_0x4611e8['normal']['toArray'](_0x51ba01['normals'],0x3*_0x59fae2),_0x51ba01['uvs']['push'](0.5+_0x4611e8['position']['x']/_0x372e0a['x']),_0x51ba01['uvs']['push'](0.5+_0x4611e8['position']['y']/_0x372e0a['y']),_0x59fae2++;}}var _0x5dc690=new _0x3cf5e5['a'](_0x31cf1e,_0x381a0e['getScene']());return _0x51ba01['applyToMesh'](_0x5dc690),_0x5dc690['position']=_0x14545e['clone'](),_0x5dc690['rotation']=new _0x74d525['e'](_0x4027b0,_0x158c5f,_0x21e2fc),_0x5dc690;},_0x2918d4;}());_0xa18063['a']['CreateCapsule']=function(_0x3a95d3){void 0x0===_0x3a95d3&&(_0x3a95d3={'subdivisions':0x2,'tessellation':0x10,'height':0x1,'radius':0.25,'capSubdivisions':0x6});var _0x2ee870,_0x4fbc9a,_0x12c92c=Math['max'](_0x3a95d3['subdivisions']?_0x3a95d3['subdivisions']:0x2,0x1),_0x5d1b1a=Math['max'](_0x3a95d3['tessellation']?_0x3a95d3['tessellation']:0x10,0x3),_0x15fd70=Math['max'](_0x3a95d3['height']?_0x3a95d3['height']:0x1,0x0),_0x316c4d=Math['max'](_0x3a95d3['radius']?_0x3a95d3['radius']:0.25,0x0),_0x45a2c7=Math['max'](_0x3a95d3['capSubdivisions']?_0x3a95d3['capSubdivisions']:0x6,0x1),_0xe39b3d=_0x5d1b1a,_0x499009=_0x12c92c,_0x511b1b=Math['max'](_0x3a95d3['radiusTop']?_0x3a95d3['radiusTop']:_0x316c4d,0x0),_0x12c01d=Math['max'](_0x3a95d3['radiusBottom']?_0x3a95d3['radiusBottom']:_0x316c4d,0x0),_0x11fa09=_0x15fd70-(_0x511b1b+_0x12c01d),_0x3a5fbe=0x2*Math['PI'],_0x3a258b=Math['max'](_0x3a95d3['topCapSubdivisions']?_0x3a95d3['topCapSubdivisions']:_0x45a2c7,0x1),_0x3ee2e1=Math['max'](_0x3a95d3['bottomCapSubdivisions']?_0x3a95d3['bottomCapSubdivisions']:_0x45a2c7,0x1),_0x376c12=Math['acos']((_0x12c01d-_0x511b1b)/_0x15fd70),_0x130db9=[],_0x5599f7=[],_0x3572a9=[],_0x399722=[],_0x47ac1d=0x0,_0x50459d=[],_0x42c397=0.5*_0x11fa09,_0xf52b3b=0.5*Math['PI'],_0x1ee697=_0x74d525['e']['Zero'](),_0x4eca19=_0x74d525['e']['Zero'](),_0x503f8b=Math['cos'](_0x376c12),_0x191f6c=Math['sin'](_0x376c12),_0x3d554e=new _0x74d525['d'](_0x511b1b*_0x191f6c,_0x42c397+_0x511b1b*_0x503f8b)['subtract'](new _0x74d525['d'](_0x12c01d*_0x191f6c,_0x12c01d*_0x503f8b-_0x42c397))['length'](),_0x2a85d1=_0x511b1b*_0x376c12+_0x3d554e+_0x12c01d*(_0xf52b3b-_0x376c12),_0x27c352=0x0;for(_0x4fbc9a=0x0;_0x4fbc9a<=_0x3a258b;_0x4fbc9a++){var _0x35a01e=[],_0x1f26af=_0xf52b3b-_0x376c12*(_0x4fbc9a/_0x3a258b);_0x27c352+=_0x511b1b*_0x376c12/_0x3a258b;var _0x7dccbd=Math['cos'](_0x1f26af),_0x38f6bd=Math['sin'](_0x1f26af),_0x407f72=_0x7dccbd*_0x511b1b;for(_0x2ee870=0x0;_0x2ee870<=_0xe39b3d;_0x2ee870++){var _0x469113=(_0x5c5d24=_0x2ee870/_0xe39b3d)*_0x3a5fbe+0x0,_0x2e5838=Math['sin'](_0x469113),_0x5d7c11=Math['cos'](_0x469113);_0x4eca19['x']=_0x407f72*_0x2e5838,_0x4eca19['y']=_0x42c397+_0x38f6bd*_0x511b1b,_0x4eca19['z']=_0x407f72*_0x5d7c11,_0x5599f7['push'](_0x4eca19['x'],_0x4eca19['y'],_0x4eca19['z']),_0x1ee697['set'](_0x7dccbd*_0x2e5838,_0x38f6bd,_0x7dccbd*_0x5d7c11),_0x3572a9['push'](_0x1ee697['x'],_0x1ee697['y'],_0x1ee697['z']),_0x399722['push'](_0x5c5d24,0x1-_0x27c352/_0x2a85d1),_0x35a01e['push'](_0x47ac1d),_0x47ac1d++;}_0x50459d['push'](_0x35a01e);}var _0x1d3d5d=_0x15fd70-_0x511b1b-_0x12c01d+_0x503f8b*_0x511b1b-_0x503f8b*_0x12c01d,_0x4290cf=_0x191f6c*(_0x12c01d-_0x511b1b)/_0x1d3d5d;for(_0x4fbc9a=0x1;_0x4fbc9a<=_0x499009;_0x4fbc9a++){_0x35a01e=[],_0x27c352+=_0x3d554e/_0x499009,_0x407f72=_0x191f6c*(_0x4fbc9a*(_0x12c01d-_0x511b1b)/_0x499009+_0x511b1b);for(_0x2ee870=0x0;_0x2ee870<=_0xe39b3d;_0x2ee870++){_0x469113=(_0x5c5d24=_0x2ee870/_0xe39b3d)*_0x3a5fbe+0x0,_0x2e5838=Math['sin'](_0x469113),_0x5d7c11=Math['cos'](_0x469113),(_0x4eca19['x']=_0x407f72*_0x2e5838,_0x4eca19['y']=_0x42c397+_0x503f8b*_0x511b1b-_0x4fbc9a*_0x1d3d5d/_0x499009,_0x4eca19['z']=_0x407f72*_0x5d7c11,_0x5599f7['push'](_0x4eca19['x'],_0x4eca19['y'],_0x4eca19['z']),_0x1ee697['set'](_0x2e5838,_0x4290cf,_0x5d7c11)['normalize'](),_0x3572a9['push'](_0x1ee697['x'],_0x1ee697['y'],_0x1ee697['z']),_0x399722['push'](_0x5c5d24,0x1-_0x27c352/_0x2a85d1),_0x35a01e['push'](_0x47ac1d),_0x47ac1d++);}_0x50459d['push'](_0x35a01e);}for(_0x4fbc9a=0x1;_0x4fbc9a<=_0x3ee2e1;_0x4fbc9a++){_0x35a01e=[],_0x1f26af=_0xf52b3b-_0x376c12-(Math['PI']-_0x376c12)*(_0x4fbc9a/_0x3ee2e1),_0x27c352+=_0x12c01d*_0x376c12/_0x3ee2e1,(_0x7dccbd=Math['cos'](_0x1f26af),_0x38f6bd=Math['sin'](_0x1f26af),_0x407f72=_0x7dccbd*_0x12c01d);for(_0x2ee870=0x0;_0x2ee870<=_0xe39b3d;_0x2ee870++){var _0x5c5d24;_0x469113=(_0x5c5d24=_0x2ee870/_0xe39b3d)*_0x3a5fbe+0x0,_0x2e5838=Math['sin'](_0x469113),_0x5d7c11=Math['cos'](_0x469113),(_0x4eca19['x']=_0x407f72*_0x2e5838,_0x4eca19['y']=_0x38f6bd*_0x12c01d-_0x42c397,_0x4eca19['z']=_0x407f72*_0x5d7c11,_0x5599f7['push'](_0x4eca19['x'],_0x4eca19['y'],_0x4eca19['z']),_0x1ee697['set'](_0x7dccbd*_0x2e5838,_0x38f6bd,_0x7dccbd*_0x5d7c11),_0x3572a9['push'](_0x1ee697['x'],_0x1ee697['y'],_0x1ee697['z']),_0x399722['push'](_0x5c5d24,0x1-_0x27c352/_0x2a85d1),_0x35a01e['push'](_0x47ac1d),_0x47ac1d++);}_0x50459d['push'](_0x35a01e);}for(_0x2ee870=0x0;_0x2ee870<_0xe39b3d;_0x2ee870++)for(_0x4fbc9a=0x0;_0x4fbc9a<_0x3a258b+_0x499009+_0x3ee2e1;_0x4fbc9a++){var _0x18ebde=_0x50459d[_0x4fbc9a][_0x2ee870],_0x5de313=_0x50459d[_0x4fbc9a+0x1][_0x2ee870],_0x2bb6be=_0x50459d[_0x4fbc9a+0x1][_0x2ee870+0x1],_0x5c8678=_0x50459d[_0x4fbc9a][_0x2ee870+0x1];_0x130db9['push'](_0x18ebde),_0x130db9['push'](_0x5de313),_0x130db9['push'](_0x5c8678),_0x130db9['push'](_0x5de313),_0x130db9['push'](_0x2bb6be),_0x130db9['push'](_0x5c8678);}if(_0x130db9=_0x130db9['reverse'](),_0x3a95d3['orientation']&&!_0x3a95d3['orientation']['equals'](_0x74d525['e']['Up']())){var _0x231404=new _0x74d525['a']();_0x3a95d3['orientation']['clone']()['scale'](0.5*Math['PI'])['cross'](_0x74d525['e']['Up']())['toQuaternion']()['toRotationMatrix'](_0x231404);for(var _0x38154d=_0x74d525['e']['Zero'](),_0x492193=0x0;_0x492193<_0x5599f7['length'];_0x492193+=0x3)_0x38154d['set'](_0x5599f7[_0x492193],_0x5599f7[_0x492193+0x1],_0x5599f7[_0x492193+0x2]),_0x74d525['e']['TransformCoordinatesToRef'](_0x38154d['clone'](),_0x231404,_0x38154d),_0x5599f7[_0x492193]=_0x38154d['x'],_0x5599f7[_0x492193+0x1]=_0x38154d['y'],_0x5599f7[_0x492193+0x2]=_0x38154d['z'];}var _0x4bdcaf=new _0xa18063['a']();return _0x4bdcaf['positions']=_0x5599f7,_0x4bdcaf['normals']=_0x3572a9,_0x4bdcaf['uvs']=_0x399722,_0x4bdcaf['indices']=_0x130db9,_0x4bdcaf;},_0x3cf5e5['a']['CreateCapsule']=function(_0x12302c,_0x513a4c,_0x240b53){return _0x5733e6['CreateCapsule'](_0x12302c,_0x513a4c,_0x240b53);};var _0x21793b,_0x5733e6=(function(){function _0x2bae30(){}return _0x2bae30['CreateCapsule']=function(_0x2faff3,_0x443d06,_0x5d515e){void 0x0===_0x443d06&&(_0x443d06={'orientation':_0x74d525['e']['Up'](),'subdivisions':0x2,'tessellation':0x10,'height':0x1,'radius':0.25,'capSubdivisions':0x6});var _0x587347=new _0x3cf5e5['a'](_0x2faff3,_0x5d515e);return _0xa18063['a']['CreateCapsule'](_0x443d06)['applyToMesh'](_0x587347),_0x587347;},_0x2bae30;}()),_0x531160=(function(){function _0x252fc2(){}return _0x252fc2['CreateBox']=function(_0x4baa7a,_0x5bf422,_0x23d50a){return void 0x0===_0x23d50a&&(_0x23d50a=null),_0x144742['a']['CreateBox'](_0x4baa7a,_0x5bf422,_0x23d50a);},_0x252fc2['CreateTiledBox']=function(_0xad6d9a,_0x1058f5,_0x282782){return void 0x0===_0x282782&&(_0x282782=null),_0x3986af['CreateTiledBox'](_0xad6d9a,_0x1058f5,_0x282782);},_0x252fc2['CreateSphere']=function(_0x30468d,_0x4581aa,_0x4b3eb7){return void 0x0===_0x4b3eb7&&(_0x4b3eb7=null),_0x5c4f8d['a']['CreateSphere'](_0x30468d,_0x4581aa,_0x4b3eb7);},_0x252fc2['CreateDisc']=function(_0x29472,_0x3f09e4,_0x24021d){return void 0x0===_0x24021d&&(_0x24021d=null),_0x4ec9b3['CreateDisc'](_0x29472,_0x3f09e4,_0x24021d);},_0x252fc2['CreateIcoSphere']=function(_0x32abcf,_0x3402bb,_0x1139bb){return void 0x0===_0x1139bb&&(_0x1139bb=null),_0x3acb17['CreateIcoSphere'](_0x32abcf,_0x3402bb,_0x1139bb);},_0x252fc2['CreateRibbon']=function(_0xfc88ec,_0x395bf6,_0x3eba76){return void 0x0===_0x3eba76&&(_0x3eba76=null),_0x9de293['a']['CreateRibbon'](_0xfc88ec,_0x395bf6,_0x3eba76);},_0x252fc2['CreateCylinder']=function(_0x5d42c7,_0x2a6950,_0xb9d0a8){return void 0x0===_0xb9d0a8&&(_0xb9d0a8=null),_0x179064['a']['CreateCylinder'](_0x5d42c7,_0x2a6950,_0xb9d0a8);},_0x252fc2['CreateTorus']=function(_0x2e151e,_0x3f034f,_0x4159a0){return void 0x0===_0x4159a0&&(_0x4159a0=null),_0x4a716b['CreateTorus'](_0x2e151e,_0x3f034f,_0x4159a0);},_0x252fc2['CreateTorusKnot']=function(_0x1049e7,_0xfa2441,_0x56940a){return void 0x0===_0x56940a&&(_0x56940a=null),_0x2baa94['CreateTorusKnot'](_0x1049e7,_0xfa2441,_0x56940a);},_0x252fc2['CreateLineSystem']=function(_0x31f58e,_0x462296,_0x22b58e){return _0x333a74['a']['CreateLineSystem'](_0x31f58e,_0x462296,_0x22b58e);},_0x252fc2['CreateLines']=function(_0x5f2174,_0x28abc8,_0x2ba140){return void 0x0===_0x2ba140&&(_0x2ba140=null),_0x333a74['a']['CreateLines'](_0x5f2174,_0x28abc8,_0x2ba140);},_0x252fc2['CreateDashedLines']=function(_0x495385,_0x13dfb0,_0x28a70f){return void 0x0===_0x28a70f&&(_0x28a70f=null),_0x333a74['a']['CreateDashedLines'](_0x495385,_0x13dfb0,_0x28a70f);},_0x252fc2['ExtrudeShape']=function(_0x392f84,_0x22cdb6,_0x1e3392){return void 0x0===_0x1e3392&&(_0x1e3392=null),_0x13b0e7['a']['ExtrudeShape'](_0x392f84,_0x22cdb6,_0x1e3392);},_0x252fc2['ExtrudeShapeCustom']=function(_0x25bf0a,_0x59036a,_0x43bcf0){return void 0x0===_0x43bcf0&&(_0x43bcf0=null),_0x13b0e7['a']['ExtrudeShapeCustom'](_0x25bf0a,_0x59036a,_0x43bcf0);},_0x252fc2['CreateLathe']=function(_0x2e81f5,_0x1e07e9,_0x3a8f28){return void 0x0===_0x3a8f28&&(_0x3a8f28=null),_0x2a4bc7['CreateLathe'](_0x2e81f5,_0x1e07e9,_0x3a8f28);},_0x252fc2['CreateTiledPlane']=function(_0x4f43e5,_0x28d8c0,_0x25db03){return void 0x0===_0x25db03&&(_0x25db03=null),_0x8a5c03['CreateTiledPlane'](_0x4f43e5,_0x28d8c0,_0x25db03);},_0x252fc2['CreatePlane']=function(_0x422e20,_0x3315a6,_0x115353){return void 0x0===_0x115353&&(_0x115353=null),_0xd22a68['a']['CreatePlane'](_0x422e20,_0x3315a6,_0x115353);},_0x252fc2['CreateGround']=function(_0x442192,_0x34b37a,_0x1e0fb8){return void 0x0===_0x1e0fb8&&(_0x1e0fb8=null),_0x369c28['CreateGround'](_0x442192,_0x34b37a,_0x1e0fb8);},_0x252fc2['CreateTiledGround']=function(_0x5c6c63,_0x5e787c,_0x530ce3){return void 0x0===_0x530ce3&&(_0x530ce3=null),_0x369c28['CreateTiledGround'](_0x5c6c63,_0x5e787c,_0x530ce3);},_0x252fc2['CreateGroundFromHeightMap']=function(_0x512c50,_0x5f477d,_0x456d7a,_0x1ac2c3){return void 0x0===_0x1ac2c3&&(_0x1ac2c3=null),_0x369c28['CreateGroundFromHeightMap'](_0x512c50,_0x5f477d,_0x456d7a,_0x1ac2c3);},_0x252fc2['CreatePolygon']=function(_0x271057,_0x7f4760,_0x4e18cb,_0xe9e776){return void 0x0===_0x4e18cb&&(_0x4e18cb=null),void 0x0===_0xe9e776&&(_0xe9e776=earcut),_0x25aa99['CreatePolygon'](_0x271057,_0x7f4760,_0x4e18cb,_0xe9e776);},_0x252fc2['ExtrudePolygon']=function(_0x6b68ef,_0x148df2,_0x398b13,_0x328c){return void 0x0===_0x398b13&&(_0x398b13=null),void 0x0===_0x328c&&(_0x328c=earcut),_0x25aa99['ExtrudePolygon'](_0x6b68ef,_0x148df2,_0x398b13,_0x328c);},_0x252fc2['CreateTube']=function(_0x17055e,_0x177b15,_0x1fb2c3){return void 0x0===_0x1fb2c3&&(_0x1fb2c3=null),_0x124f37['CreateTube'](_0x17055e,_0x177b15,_0x1fb2c3);},_0x252fc2['CreatePolyhedron']=function(_0x1d44e9,_0x500981,_0x57f25f){return void 0x0===_0x57f25f&&(_0x57f25f=null),_0x39b46b['CreatePolyhedron'](_0x1d44e9,_0x500981,_0x57f25f);},_0x252fc2['CreateDecal']=function(_0x1c4518,_0x2bdbd6,_0x50cbbb){return _0x458e78['CreateDecal'](_0x1c4518,_0x2bdbd6,_0x50cbbb);},_0x252fc2['CreateCapsule']=function(_0x2a677a,_0x16a6b4,_0x19b56d){return void 0x0===_0x16a6b4&&(_0x16a6b4={'orientation':_0x74d525['e']['Up'](),'subdivisions':0x2,'tessellation':0x10,'height':0x1,'radius':0.25,'capSubdivisions':0x6}),void 0x0===_0x19b56d&&(_0x19b56d=null),_0x5733e6['CreateCapsule'](_0x2a677a,_0x16a6b4,_0x19b56d);},_0x252fc2;}()),_0x214f41=function(_0xf266aa,_0x6e9a1d,_0x1af8a5){this['quality']=_0xf266aa,this['distance']=_0x6e9a1d,this['optimizeMesh']=_0x1af8a5;},_0x3d1879=(function(){function _0xbc25de(){this['running']=!0x1,this['_simplificationArray']=[];}return _0xbc25de['prototype']['addTask']=function(_0x3c3670){this['_simplificationArray']['push'](_0x3c3670);},_0xbc25de['prototype']['executeNext']=function(){var _0x15b042=this['_simplificationArray']['pop']();_0x15b042?(this['running']=!0x0,this['runSimplification'](_0x15b042)):this['running']=!0x1;},_0xbc25de['prototype']['runSimplification']=function(_0xc4bac4){var _0x28efe8=this;if(_0xc4bac4['parallelProcessing'])_0xc4bac4['settings']['forEach'](function(_0x3c87a5){_0x28efe8['getSimplifier'](_0xc4bac4)['simplify'](_0x3c87a5,function(_0xac399a){void 0x0!==_0x3c87a5['distance']&&_0xc4bac4['mesh']['addLODLevel'](_0x3c87a5['distance'],_0xac399a),_0xac399a['isVisible']=!0x0,_0x3c87a5['quality']===_0xc4bac4['settings'][_0xc4bac4['settings']['length']-0x1]['quality']&&_0xc4bac4['successCallback']&&_0xc4bac4['successCallback'](),_0x28efe8['executeNext']();});});else{var _0x27d9dc=this['getSimplifier'](_0xc4bac4);_0x5d754c['a']['Run'](_0xc4bac4['settings']['length'],function(_0x3d0d8b){var _0x2eec26,_0x2ce441;_0x2eec26=_0xc4bac4['settings'][_0x3d0d8b['index']],_0x2ce441=function(){_0x3d0d8b['executeNext']();},_0x27d9dc['simplify'](_0x2eec26,function(_0x455e24){void 0x0!==_0x2eec26['distance']&&_0xc4bac4['mesh']['addLODLevel'](_0x2eec26['distance'],_0x455e24),_0x455e24['isVisible']=!0x0,_0x2ce441();});},function(){_0xc4bac4['successCallback']&&_0xc4bac4['successCallback'](),_0x28efe8['executeNext']();});}},_0xbc25de['prototype']['getSimplifier']=function(_0x56d128){switch(_0x56d128['simplificationType']){case _0x21793b['QUADRATIC']:default:return new _0x5ab9b4(_0x56d128['mesh']);}},_0xbc25de;}());!function(_0x1a1e67){_0x1a1e67[_0x1a1e67['QUADRATIC']=0x0]='QUADRATIC';}(_0x21793b||(_0x21793b={}));var _0x11cfd5=function(_0xe32957){this['vertices']=_0xe32957,this['error']=new Array(0x4),this['deleted']=!0x1,this['isDirty']=!0x1,this['deletePending']=!0x1,this['borderFactor']=0x0;},_0x49110c=(function(){function _0x37491b(_0x321c09,_0x5a9544){this['position']=_0x321c09,this['id']=_0x5a9544,this['isBorder']=!0x0,this['q']=new _0x179ce0(),this['triangleCount']=0x0,this['triangleStart']=0x0,this['originalOffsets']=[];}return _0x37491b['prototype']['updatePosition']=function(_0x338e95){this['position']['copyFrom'](_0x338e95);},_0x37491b;}()),_0x179ce0=(function(){function _0x34420d(_0x285a3){this['data']=new Array(0xa);for(var _0x56d702=0x0;_0x56d702<0xa;++_0x56d702)_0x285a3&&_0x285a3[_0x56d702]?this['data'][_0x56d702]=_0x285a3[_0x56d702]:this['data'][_0x56d702]=0x0;}return _0x34420d['prototype']['det']=function(_0x79cb25,_0x19bae5,_0x1a6a08,_0x138715,_0x440fe4,_0x4fd484,_0x9f157c,_0x930761,_0x4bc3a7){return this['data'][_0x79cb25]*this['data'][_0x440fe4]*this['data'][_0x4bc3a7]+this['data'][_0x1a6a08]*this['data'][_0x138715]*this['data'][_0x930761]+this['data'][_0x19bae5]*this['data'][_0x4fd484]*this['data'][_0x9f157c]-this['data'][_0x1a6a08]*this['data'][_0x440fe4]*this['data'][_0x9f157c]-this['data'][_0x79cb25]*this['data'][_0x4fd484]*this['data'][_0x930761]-this['data'][_0x19bae5]*this['data'][_0x138715]*this['data'][_0x4bc3a7];},_0x34420d['prototype']['addInPlace']=function(_0x2dddf5){for(var _0x4da779=0x0;_0x4da779<0xa;++_0x4da779)this['data'][_0x4da779]+=_0x2dddf5['data'][_0x4da779];},_0x34420d['prototype']['addArrayInPlace']=function(_0x144181){for(var _0x89462a=0x0;_0x89462a<0xa;++_0x89462a)this['data'][_0x89462a]+=_0x144181[_0x89462a];},_0x34420d['prototype']['add']=function(_0x3afeef){for(var _0x227669=new _0x34420d(),_0x46dd65=0x0;_0x46dd65<0xa;++_0x46dd65)_0x227669['data'][_0x46dd65]=this['data'][_0x46dd65]+_0x3afeef['data'][_0x46dd65];return _0x227669;},_0x34420d['FromData']=function(_0x464de3,_0x39982c,_0x261eb9,_0x19dd3b){return new _0x34420d(_0x34420d['DataFromNumbers'](_0x464de3,_0x39982c,_0x261eb9,_0x19dd3b));},_0x34420d['DataFromNumbers']=function(_0x42129d,_0x53d86a,_0x3336ae,_0x3e90ac){return[_0x42129d*_0x42129d,_0x42129d*_0x53d86a,_0x42129d*_0x3336ae,_0x42129d*_0x3e90ac,_0x53d86a*_0x53d86a,_0x53d86a*_0x3336ae,_0x53d86a*_0x3e90ac,_0x3336ae*_0x3336ae,_0x3336ae*_0x3e90ac,_0x3e90ac*_0x3e90ac];},_0x34420d;}()),_0x586e9f=function(_0x1c0a44,_0x461e2a){this['vertexId']=_0x1c0a44,this['triangleId']=_0x461e2a;},_0x5ab9b4=(function(){function _0x2e63f3(_0x3f2f22){this['_mesh']=_0x3f2f22,this['syncIterations']=0x1388,this['aggressiveness']=0x7,this['decimationIterations']=0x64,this['boundingBoxEpsilon']=_0x27da6e['a'];}return _0x2e63f3['prototype']['simplify']=function(_0x4b17ca,_0x480fef){var _0x3a29ff=this;this['initDecimatedMesh'](),_0x5d754c['a']['Run'](this['_mesh']['subMeshes']['length'],function(_0x1afc83){_0x3a29ff['initWithMesh'](_0x1afc83['index'],function(){_0x3a29ff['runDecimation'](_0x4b17ca,_0x1afc83['index'],function(){_0x1afc83['executeNext']();});},_0x4b17ca['optimizeMesh']);},function(){setTimeout(function(){_0x480fef(_0x3a29ff['_reconstructedMesh']);},0x0);});},_0x2e63f3['prototype']['runDecimation']=function(_0x46ce3d,_0x4a9030,_0x55c9c7){var _0x5d7d02=this,_0x40b239=~~(this['triangles']['length']*_0x46ce3d['quality']),_0x5a89f7=0x0,_0x148df=this['triangles']['length'];_0x5d754c['a']['Run'](this['decimationIterations'],function(_0x1ba508){var _0x8ce985,_0x33a2e9;_0x148df-_0x5a89f7<=_0x40b239?_0x1ba508['breakLoop']():(_0x8ce985=_0x1ba508['index'],_0x33a2e9=function(){_0x1ba508['executeNext']();},setTimeout(function(){_0x8ce985%0x5==0x0&&_0x5d7d02['updateMesh'](0x0===_0x8ce985);for(var _0x583dbd=0x0;_0x583dbd<_0x5d7d02['triangles']['length'];++_0x583dbd)_0x5d7d02['triangles'][_0x583dbd]['isDirty']=!0x1;var _0x2e8d41=1e-9*Math['pow'](_0x8ce985+0x3,_0x5d7d02['aggressiveness']);_0x5d754c['a']['SyncAsyncForLoop'](_0x5d7d02['triangles']['length'],_0x5d7d02['syncIterations'],function(_0xd108ee){var _0x4ba3b5=~~((_0x5d7d02['triangles']['length']/0x2+_0xd108ee)%_0x5d7d02['triangles']['length']),_0x534c37=_0x5d7d02['triangles'][_0x4ba3b5];if(_0x534c37&&!(_0x534c37['error'][0x3]>_0x2e8d41||_0x534c37['deleted']||_0x534c37['isDirty'])){for(var _0xc4db4b=0x0;_0xc4db4b<0x3;++_0xc4db4b)if(_0x534c37['error'][_0xc4db4b]<_0x2e8d41){var _0x298237=[],_0x7bfc97=[],_0x23edbe=_0x534c37['vertices'][_0xc4db4b],_0x25d8b0=_0x534c37['vertices'][(_0xc4db4b+0x1)%0x3];if(_0x23edbe['isBorder']||_0x25d8b0['isBorder'])continue;var _0x4b6a8a=_0x74d525['e']['Zero']();_0x5d7d02['calculateError'](_0x23edbe,_0x25d8b0,_0x4b6a8a);var _0x5ceeee=new Array();if(_0x5d7d02['isFlipped'](_0x23edbe,_0x25d8b0,_0x4b6a8a,_0x298237,_0x5ceeee))continue;if(_0x5d7d02['isFlipped'](_0x25d8b0,_0x23edbe,_0x4b6a8a,_0x7bfc97,_0x5ceeee))continue;if(_0x298237['indexOf'](!0x0)<0x0||_0x7bfc97['indexOf'](!0x0)<0x0)continue;var _0x237fc9=new Array();if(_0x5ceeee['forEach'](function(_0x6fd2ff){-0x1===_0x237fc9['indexOf'](_0x6fd2ff)&&(_0x6fd2ff['deletePending']=!0x0,_0x237fc9['push'](_0x6fd2ff));}),_0x237fc9['length']%0x2!=0x0)continue;_0x23edbe['q']=_0x25d8b0['q']['add'](_0x23edbe['q']),_0x23edbe['updatePosition'](_0x4b6a8a);var _0x506872=_0x5d7d02['references']['length'];_0x5a89f7=_0x5d7d02['updateTriangles'](_0x23edbe,_0x23edbe,_0x298237,_0x5a89f7),_0x5a89f7=_0x5d7d02['updateTriangles'](_0x23edbe,_0x25d8b0,_0x7bfc97,_0x5a89f7);var _0x40fa3e=_0x5d7d02['references']['length']-_0x506872;if(_0x40fa3e<=_0x23edbe['triangleCount']){if(_0x40fa3e){for(var _0x32b8a0=0x0;_0x32b8a0<_0x40fa3e;_0x32b8a0++)_0x5d7d02['references'][_0x23edbe['triangleStart']+_0x32b8a0]=_0x5d7d02['references'][_0x506872+_0x32b8a0];}}else _0x23edbe['triangleStart']=_0x506872;_0x23edbe['triangleCount']=_0x40fa3e;break;}}},_0x33a2e9,function(){return _0x148df-_0x5a89f7<=_0x40b239;});},0x0));},function(){setTimeout(function(){_0x5d7d02['reconstructMesh'](_0x4a9030),_0x55c9c7();},0x0);});},_0x2e63f3['prototype']['initWithMesh']=function(_0x4f04a8,_0x34fcff,_0x5c21c0){var _0xbc8fe7=this;this['vertices']=[],this['triangles']=[];var _0x88bbfe=this['_mesh']['getVerticesData'](_0x212fbd['b']['PositionKind']),_0x4d677f=this['_mesh']['getIndices'](),_0x18f66e=this['_mesh']['subMeshes'][_0x4f04a8],_0x49f66c=[],_0x4f9cd9=_0x18f66e['verticesCount'];_0x5d754c['a']['SyncAsyncForLoop'](_0x4f9cd9,this['syncIterations']/0x4>>0x0,function(_0x57d884){if(_0x88bbfe){var _0x14477d=_0x57d884+_0x18f66e['verticesStart'],_0x1c5fb8=_0x74d525['e']['FromArray'](_0x88bbfe,0x3*_0x14477d),_0x166db4=function(_0x4c1623){if(_0x5c21c0){for(var _0x3e6d3f=0x0;_0x3e6d3f<_0xbc8fe7['vertices']['length'];++_0x3e6d3f)if(_0xbc8fe7['vertices'][_0x3e6d3f]['position']['equalsWithEpsilon'](_0x4c1623,0.0001))return _0xbc8fe7['vertices'][_0x3e6d3f];}return null;}(_0x1c5fb8)||new _0x49110c(_0x1c5fb8,_0xbc8fe7['vertices']['length']);_0x166db4['originalOffsets']['push'](_0x14477d),_0x166db4['id']===_0xbc8fe7['vertices']['length']&&_0xbc8fe7['vertices']['push'](_0x166db4),_0x49f66c['push'](_0x166db4['id']);}},function(){_0x5d754c['a']['SyncAsyncForLoop'](_0x18f66e['indexCount']/0x3,_0xbc8fe7['syncIterations'],function(_0x238e36){if(_0x4d677f){var _0x3b3de6=0x3*(_0x18f66e['indexStart']/0x3+_0x238e36),_0x4c9ae9=_0x4d677f[_0x3b3de6+0x0],_0x19991c=_0x4d677f[_0x3b3de6+0x1],_0x33bbc0=_0x4d677f[_0x3b3de6+0x2],_0x3d04a9=_0xbc8fe7['vertices'][_0x49f66c[_0x4c9ae9-_0x18f66e['verticesStart']]],_0x423f56=_0xbc8fe7['vertices'][_0x49f66c[_0x19991c-_0x18f66e['verticesStart']]],_0x4b22ab=_0xbc8fe7['vertices'][_0x49f66c[_0x33bbc0-_0x18f66e['verticesStart']]],_0xab0b62=new _0x11cfd5([_0x3d04a9,_0x423f56,_0x4b22ab]);_0xab0b62['originalOffset']=_0x3b3de6,_0xbc8fe7['triangles']['push'](_0xab0b62);}},function(){_0xbc8fe7['init'](_0x34fcff);});});},_0x2e63f3['prototype']['init']=function(_0x490c2c){var _0x4b5698=this;_0x5d754c['a']['SyncAsyncForLoop'](this['triangles']['length'],this['syncIterations'],function(_0x4f113f){var _0x1db811=_0x4b5698['triangles'][_0x4f113f];_0x1db811['normal']=_0x74d525['e']['Cross'](_0x1db811['vertices'][0x1]['position']['subtract'](_0x1db811['vertices'][0x0]['position']),_0x1db811['vertices'][0x2]['position']['subtract'](_0x1db811['vertices'][0x0]['position']))['normalize']();for(var _0x5d9492=0x0;_0x5d9492<0x3;_0x5d9492++)_0x1db811['vertices'][_0x5d9492]['q']['addArrayInPlace'](_0x179ce0['DataFromNumbers'](_0x1db811['normal']['x'],_0x1db811['normal']['y'],_0x1db811['normal']['z'],-_0x74d525['e']['Dot'](_0x1db811['normal'],_0x1db811['vertices'][0x0]['position'])));},function(){_0x5d754c['a']['SyncAsyncForLoop'](_0x4b5698['triangles']['length'],_0x4b5698['syncIterations'],function(_0x33374f){for(var _0x4ceab4=_0x4b5698['triangles'][_0x33374f],_0x518f8b=0x0;_0x518f8b<0x3;++_0x518f8b)_0x4ceab4['error'][_0x518f8b]=_0x4b5698['calculateError'](_0x4ceab4['vertices'][_0x518f8b],_0x4ceab4['vertices'][(_0x518f8b+0x1)%0x3]);_0x4ceab4['error'][0x3]=Math['min'](_0x4ceab4['error'][0x0],_0x4ceab4['error'][0x1],_0x4ceab4['error'][0x2]);},function(){_0x490c2c();});});},_0x2e63f3['prototype']['reconstructMesh']=function(_0x4e2dbe){var _0x5629ad,_0x5c49b4,_0x5044a4,_0x44cb01=[];for(_0x5629ad=0x0;_0x5629ad0x0&&this['_reconstructedMesh']['setVerticesData'](_0x212fbd['b']['NormalKind'],_0x7fd683),_0x148d0b['length']>0x0&&this['_reconstructedMesh']['setVerticesData'](_0x212fbd['b']['UVKind'],_0x148d0b),_0x555f74['length']>0x0&&this['_reconstructedMesh']['setVerticesData'](_0x212fbd['b']['ColorKind'],_0x555f74);var _0x29437f=this['_mesh']['subMeshes'][_0x4e2dbe];_0x4e2dbe>0x0&&(this['_reconstructedMesh']['subMeshes']=[],_0x860948['forEach'](function(_0x379bdf){_0x2a2d6d['a']['AddToMesh'](_0x379bdf['materialIndex'],_0x379bdf['verticesStart'],_0x379bdf['verticesCount'],_0x379bdf['indexStart'],_0x379bdf['indexCount'],_0x379bdf['getMesh']());}),_0x2a2d6d['a']['AddToMesh'](_0x29437f['materialIndex'],_0x22e43b,_0x294239,_0x1bfeb7,0x3*_0x44cb01['length'],this['_reconstructedMesh']));},_0x2e63f3['prototype']['initDecimatedMesh']=function(){this['_reconstructedMesh']=new _0x3cf5e5['a'](this['_mesh']['name']+'Decimated',this['_mesh']['getScene']()),this['_reconstructedMesh']['material']=this['_mesh']['material'],this['_reconstructedMesh']['parent']=this['_mesh']['parent'],this['_reconstructedMesh']['isVisible']=!0x1,this['_reconstructedMesh']['renderingGroupId']=this['_mesh']['renderingGroupId'];},_0x2e63f3['prototype']['isFlipped']=function(_0x2c2d3b,_0x376216,_0x2afb0a,_0x484009,_0x397970){for(var _0x1d8749=0x0;_0x1d8749<_0x2c2d3b['triangleCount'];++_0x1d8749){var _0x3a376d=this['triangles'][this['references'][_0x2c2d3b['triangleStart']+_0x1d8749]['triangleId']];if(!_0x3a376d['deleted']){var _0x4a52ac=this['references'][_0x2c2d3b['triangleStart']+_0x1d8749]['vertexId'],_0x136f47=_0x3a376d['vertices'][(_0x4a52ac+0x1)%0x3],_0x529f41=_0x3a376d['vertices'][(_0x4a52ac+0x2)%0x3];if(_0x136f47!==_0x376216&&_0x529f41!==_0x376216){var _0x1e239f=_0x136f47['position']['subtract'](_0x2afb0a);_0x1e239f=_0x1e239f['normalize']();var _0x322296=_0x529f41['position']['subtract'](_0x2afb0a);if(_0x322296=_0x322296['normalize'](),Math['abs'](_0x74d525['e']['Dot'](_0x1e239f,_0x322296))>0.999)return!0x0;var _0xf11be7=_0x74d525['e']['Cross'](_0x1e239f,_0x322296)['normalize']();if(_0x484009[_0x1d8749]=!0x1,_0x74d525['e']['Dot'](_0xf11be7,_0x3a376d['normal'])<0.2)return!0x0;}else _0x484009[_0x1d8749]=!0x0,_0x397970['push'](_0x3a376d);}}return!0x1;},_0x2e63f3['prototype']['updateTriangles']=function(_0xb37130,_0x510088,_0x46c968,_0x11172f){for(var _0x34b489=_0x11172f,_0x5d02be=0x0;_0x5d02be<_0x510088['triangleCount'];++_0x5d02be){var _0x459f11=this['references'][_0x510088['triangleStart']+_0x5d02be],_0x21308d=this['triangles'][_0x459f11['triangleId']];_0x21308d['deleted']||(_0x46c968[_0x5d02be]&&_0x21308d['deletePending']?(_0x21308d['deleted']=!0x0,_0x34b489++):(_0x21308d['vertices'][_0x459f11['vertexId']]=_0xb37130,_0x21308d['isDirty']=!0x0,_0x21308d['error'][0x0]=this['calculateError'](_0x21308d['vertices'][0x0],_0x21308d['vertices'][0x1])+_0x21308d['borderFactor']/0x2,_0x21308d['error'][0x1]=this['calculateError'](_0x21308d['vertices'][0x1],_0x21308d['vertices'][0x2])+_0x21308d['borderFactor']/0x2,_0x21308d['error'][0x2]=this['calculateError'](_0x21308d['vertices'][0x2],_0x21308d['vertices'][0x0])+_0x21308d['borderFactor']/0x2,_0x21308d['error'][0x3]=Math['min'](_0x21308d['error'][0x0],_0x21308d['error'][0x1],_0x21308d['error'][0x2]),this['references']['push'](_0x459f11)));}return _0x34b489;},_0x2e63f3['prototype']['identifyBorder']=function(){for(var _0x15f1f2=0x0;_0x15f1f2=this['_thinInstanceDataStorage']['instancesCount'])return!0x1;var _0x2758ba=this['_thinInstanceDataStorage']['matrixData'];return _0x89845['copyToArray'](_0x2758ba,0x10*_0x3e19a4),this['_thinInstanceDataStorage']['worldMatrices']&&(this['_thinInstanceDataStorage']['worldMatrices'][_0x3e19a4]=_0x89845),_0x5a7e5f&&(this['thinInstanceBufferUpdated']('matrix'),this['doNotSyncBoundingInfo']||this['thinInstanceRefreshBoundingInfo'](!0x1)),!0x0;},_0x3cf5e5['a']['prototype']['thinInstanceSetAttributeAt']=function(_0x335232,_0x39f195,_0x103fac,_0x1ae78b){return void 0x0===_0x1ae78b&&(_0x1ae78b=!0x0),!(!this['_userThinInstanceBuffersStorage']||!this['_userThinInstanceBuffersStorage']['data'][_0x335232]||_0x39f195>=this['_thinInstanceDataStorage']['instancesCount'])&&(this['_thinInstanceUpdateBufferSize'](_0x335232,0x0),this['_userThinInstanceBuffersStorage']['data'][_0x335232]['set'](_0x103fac,_0x39f195*this['_userThinInstanceBuffersStorage']['strides'][_0x335232]),_0x1ae78b&&this['thinInstanceBufferUpdated'](_0x335232),!0x0);},Object['defineProperty'](_0x3cf5e5['a']['prototype'],'thinInstanceCount',{'get':function(){return this['_thinInstanceDataStorage']['instancesCount'];},'set':function(_0x5e1593){var _0x20a21a,_0x264ced;_0x5e1593<=(null!==(_0x264ced=null===(_0x20a21a=this['_thinInstanceDataStorage']['matrixData'])||void 0x0===_0x20a21a?void 0x0:_0x20a21a['length'])&&void 0x0!==_0x264ced?_0x264ced:0x0)/0x10&&(this['_thinInstanceDataStorage']['instancesCount']=_0x5e1593);},'enumerable':!0x0,'configurable':!0x0}),_0x3cf5e5['a']['prototype']['thinInstanceSetBuffer']=function(_0x14cc4b,_0xbc5da9,_0x3c31ae,_0x48fbca){var _0x212634,_0x1373cd;if(void 0x0===_0x3c31ae&&(_0x3c31ae=0x0),void 0x0===_0x48fbca&&(_0x48fbca=!0x1),_0x3c31ae=_0x3c31ae||0x10,'matrix'===_0x14cc4b){if(null===(_0x212634=this['_thinInstanceDataStorage']['matrixBuffer'])||void 0x0===_0x212634||_0x212634['dispose'](),this['_thinInstanceDataStorage']['matrixBuffer']=null,this['_thinInstanceDataStorage']['matrixBufferSize']=_0xbc5da9?_0xbc5da9['length']:0x20*_0x3c31ae,this['_thinInstanceDataStorage']['matrixData']=_0xbc5da9,this['_thinInstanceDataStorage']['worldMatrices']=null,null!==_0xbc5da9){this['_thinInstanceDataStorage']['instancesCount']=_0xbc5da9['length']/_0x3c31ae;var _0x283cb7=new _0x212fbd['a'](this['getEngine'](),_0xbc5da9,!_0x48fbca,_0x3c31ae,!0x1,!0x0);this['_thinInstanceDataStorage']['matrixBuffer']=_0x283cb7,this['setVerticesBuffer'](_0x283cb7['createVertexBuffer']('world0',0x0,0x4)),this['setVerticesBuffer'](_0x283cb7['createVertexBuffer']('world1',0x4,0x4)),this['setVerticesBuffer'](_0x283cb7['createVertexBuffer']('world2',0x8,0x4)),this['setVerticesBuffer'](_0x283cb7['createVertexBuffer']('world3',0xc,0x4)),this['doNotSyncBoundingInfo']||this['thinInstanceRefreshBoundingInfo'](!0x1);}else this['_thinInstanceDataStorage']['instancesCount']=0x0,this['doNotSyncBoundingInfo']||this['refreshBoundingInfo'](!0x0);}else null===_0xbc5da9?(null===(_0x1373cd=this['_userThinInstanceBuffersStorage'])||void 0x0===_0x1373cd?void 0x0:_0x1373cd['data'][_0x14cc4b])&&(this['removeVerticesData'](_0x14cc4b),delete this['_userThinInstanceBuffersStorage']['data'][_0x14cc4b],delete this['_userThinInstanceBuffersStorage']['strides'][_0x14cc4b],delete this['_userThinInstanceBuffersStorage']['sizes'][_0x14cc4b],delete this['_userThinInstanceBuffersStorage']['vertexBuffers'][_0x14cc4b]):(this['_thinInstanceInitializeUserStorage'](),this['_userThinInstanceBuffersStorage']['data'][_0x14cc4b]=_0xbc5da9,this['_userThinInstanceBuffersStorage']['strides'][_0x14cc4b]=_0x3c31ae,this['_userThinInstanceBuffersStorage']['sizes'][_0x14cc4b]=_0xbc5da9['length'],this['_userThinInstanceBuffersStorage']['vertexBuffers'][_0x14cc4b]=new _0x212fbd['b'](this['getEngine'](),_0xbc5da9,_0x14cc4b,!_0x48fbca,!0x1,_0x3c31ae,!0x0),this['setVerticesBuffer'](this['_userThinInstanceBuffersStorage']['vertexBuffers'][_0x14cc4b]));},_0x3cf5e5['a']['prototype']['thinInstanceBufferUpdated']=function(_0x2ad528){var _0x2254f9;'matrix'===_0x2ad528?this['_thinInstanceDataStorage']['matrixBuffer']&&this['_thinInstanceDataStorage']['matrixBuffer']['updateDirectly'](this['_thinInstanceDataStorage']['matrixData'],0x0,this['_thinInstanceDataStorage']['instancesCount']):(null===(_0x2254f9=this['_userThinInstanceBuffersStorage'])||void 0x0===_0x2254f9?void 0x0:_0x2254f9['vertexBuffers'][_0x2ad528])&&this['_userThinInstanceBuffersStorage']['vertexBuffers'][_0x2ad528]['updateDirectly'](this['_userThinInstanceBuffersStorage']['data'][_0x2ad528],0x0);},_0x3cf5e5['a']['prototype']['thinInstancePartialBufferUpdate']=function(_0x2e5f97,_0x5cfde5,_0x21d612){var _0x187750;'matrix'===_0x2e5f97?this['_thinInstanceDataStorage']['matrixBuffer']&&this['_thinInstanceDataStorage']['matrixBuffer']['updateDirectly'](_0x5cfde5,_0x21d612):(null===(_0x187750=this['_userThinInstanceBuffersStorage'])||void 0x0===_0x187750?void 0x0:_0x187750['vertexBuffers'][_0x2e5f97])&&this['_userThinInstanceBuffersStorage']['vertexBuffers'][_0x2e5f97]['updateDirectly'](_0x5cfde5,_0x21d612);},_0x3cf5e5['a']['prototype']['thinInstanceGetWorldMatrices']=function(){if(!this['_thinInstanceDataStorage']['matrixData']||!this['_thinInstanceDataStorage']['matrixBuffer'])return[];var _0x23e69e=this['_thinInstanceDataStorage']['matrixData'];if(!this['_thinInstanceDataStorage']['worldMatrices']){this['_thinInstanceDataStorage']['worldMatrices']=new Array();for(var _0x392ba3=0x0;_0x392ba3-0x1&&(this['agents']['splice'](_0x4037e6,0x1),this['transforms']['splice'](_0x4037e6,0x1));},_0x4f31de['prototype']['getAgents']=function(){return this['agents'];},_0x4f31de['prototype']['update']=function(_0x759b98){var _0x43c217=this['bjsRECASTPlugin']['getTimeStep'](),_0x5d563b=this['bjsRECASTPlugin']['getMaximumSubStepCount']();if(_0x43c217<=_0x27da6e['a'])this['recastCrowd']['update'](_0x759b98);else{var _0x1acd32=_0x759b98/_0x43c217;_0x5d563b&&_0x1acd32>_0x5d563b&&(_0x1acd32=_0x5d563b),_0x1acd32<0x1&&(_0x1acd32=0x1);for(var _0x3aef53=0x0;_0x3aef53<_0x1acd32;_0x3aef53++)this['recastCrowd']['update'](_0x43c217);}for(var _0x5630bb=0x0;_0x5630bb=0x190&&_0x5cbf72?_0x5cbf72(_0x4348e9):_0x5e63f4();},!0x1),_0x4348e9['addEventListener']('error',function(){_0x75193d['a']['Error']('error\x20on\x20XHR\x20request.'),_0x5e63f4();},!0x1),_0x4348e9['send']();}else _0x75193d['a']['Error']('Error:\x20IndexedDB\x20not\x20supported\x20by\x20your\x20browser\x20or\x20Babylon.js\x20database\x20is\x20not\x20open.'),_0x5e63f4();},_0xd6ea4['_ValidateXHRData']=function(_0x2cf09b,_0x2e2467){void 0x0===_0x2e2467&&(_0x2e2467=0x7);try{if(0x1&_0x2e2467){if(_0x2cf09b['responseText']&&_0x2cf09b['responseText']['length']>0x0)return!0x0;if(0x1===_0x2e2467)return!0x1;}if(0x2&_0x2e2467){var _0xb86cc1=_0x4a363d['GetTGAHeader'](_0x2cf09b['response']);if(_0xb86cc1['width']&&_0xb86cc1['height']&&_0xb86cc1['width']>0x0&&_0xb86cc1['height']>0x0)return!0x0;if(0x2===_0x2e2467)return!0x1;}if(0x4&_0x2e2467){var _0x3fb49c=new Uint8Array(_0x2cf09b['response'],0x0,0x3);return 0x44===_0x3fb49c[0x0]&&0x44===_0x3fb49c[0x1]&&0x53===_0x3fb49c[0x2];}}catch(_0x21e63b){}return!0x1;},_0xd6ea4['IsUASupportingBlobStorage']=!0x0,_0xd6ea4['IDBStorageEnabled']=!0x1,_0xd6ea4['_ParseURL']=function(_0x1a7852){document['createElement']('a')['href']=_0x1a7852;var _0x4d3130=_0x1a7852['substring'](0x0,_0x1a7852['lastIndexOf']('#')),_0x316b61=_0x1a7852['substring'](_0x4d3130['lastIndexOf']('/')+0x1,_0x1a7852['length']);return _0x1a7852['substring'](0x0,_0x1a7852['indexOf'](_0x316b61,0x0));},_0xd6ea4['_ReturnFullUrlLocation']=function(_0x56b900){return-0x1===_0x56b900['indexOf']('http:/')&&-0x1===_0x56b900['indexOf']('https:/')&&'undefined'!=typeof window?_0xd6ea4['_ParseURL'](window['location']['href'])+_0x56b900:_0x56b900;},_0xd6ea4;}()),_0x3b38b8=(function(){function _0x239fcd(_0x243e88,_0x4d808e,_0x2675f8){this['gradient']=_0x243e88,this['color1']=_0x4d808e,this['color2']=_0x2675f8;}return _0x239fcd['prototype']['getColorToRef']=function(_0x2c8752){this['color2']?_0x39310d['b']['LerpToRef'](this['color1'],this['color2'],Math['random'](),_0x2c8752):_0x2c8752['copyFrom'](this['color1']);},_0x239fcd;}()),_0x4394fb=function(_0x42efb8,_0x3e4667){this['gradient']=_0x42efb8,this['color']=_0x3e4667;},_0x3f4c49=(function(){function _0x5b8990(_0x10a9eb,_0x375cce,_0x348623){this['gradient']=_0x10a9eb,this['factor1']=_0x375cce,this['factor2']=_0x348623;}return _0x5b8990['prototype']['getFactor']=function(){return void 0x0===this['factor2']||this['factor2']===this['factor1']?this['factor1']:this['factor1']+(this['factor2']-this['factor1'])*Math['random']();},_0x5b8990;}()),_0x2688df=(function(){function _0x2920cb(){}return _0x2920cb['GetCurrentGradient']=function(_0x20b39e,_0x4fa0c1,_0x323e7f){if(_0x4fa0c1[0x0]['gradient']>_0x20b39e)_0x323e7f(_0x4fa0c1[0x0],_0x4fa0c1[0x0],0x1);else{for(var _0x52e6fa=0x0;_0x52e6fa<_0x4fa0c1['length']-0x1;_0x52e6fa++){var _0x2134b2=_0x4fa0c1[_0x52e6fa],_0x5af1f3=_0x4fa0c1[_0x52e6fa+0x1];if(_0x20b39e>=_0x2134b2['gradient']&&_0x20b39e<=_0x5af1f3['gradient'])return void _0x323e7f(_0x2134b2,_0x5af1f3,(_0x20b39e-_0x2134b2['gradient'])/(_0x5af1f3['gradient']-_0x2134b2['gradient']));}var _0x4cbc2a=_0x4fa0c1['length']-0x1;_0x323e7f(_0x4fa0c1[_0x4cbc2a],_0x4fa0c1[_0x4cbc2a],0x1);}},_0x2920cb;}()),_0x387dbf=(function(){function _0x34169b(_0x5b344c){this['particleSystem']=_0x5b344c,this['position']=_0x74d525['e']['Zero'](),this['direction']=_0x74d525['e']['Zero'](),this['color']=new _0x39310d['b'](0x0,0x0,0x0,0x0),this['colorStep']=new _0x39310d['b'](0x0,0x0,0x0,0x0),this['lifeTime']=0x1,this['age']=0x0,this['size']=0x0,this['scale']=new _0x74d525['d'](0x1,0x1),this['angle']=0x0,this['angularSpeed']=0x0,this['cellIndex']=0x0,this['_attachedSubEmitters']=null,this['_currentColor1']=new _0x39310d['b'](0x0,0x0,0x0,0x0),this['_currentColor2']=new _0x39310d['b'](0x0,0x0,0x0,0x0),this['_currentSize1']=0x0,this['_currentSize2']=0x0,this['_currentAngularSpeed1']=0x0,this['_currentAngularSpeed2']=0x0,this['_currentVelocity1']=0x0,this['_currentVelocity2']=0x0,this['_currentLimitVelocity1']=0x0,this['_currentLimitVelocity2']=0x0,this['_currentDrag1']=0x0,this['_currentDrag2']=0x0,this['id']=_0x34169b['_Count']++,this['particleSystem']['isAnimationSheetEnabled']&&this['updateCellInfoFromSystem']();}return _0x34169b['prototype']['updateCellInfoFromSystem']=function(){this['cellIndex']=this['particleSystem']['startSpriteCellID'];},_0x34169b['prototype']['updateCellIndex']=function(){var _0x596a75=this['age'],_0x13327f=this['particleSystem']['spriteCellChangeSpeed'];this['particleSystem']['spriteRandomStartCell']&&(void 0x0===this['_randomCellOffset']&&(this['_randomCellOffset']=Math['random']()*this['lifeTime']),0x0===_0x13327f?(_0x13327f=0x1,_0x596a75=this['_randomCellOffset']):_0x596a75+=this['_randomCellOffset']);var _0x4c8dd8=this['_initialEndSpriteCellID']-this['_initialStartSpriteCellID'],_0x2e532d=_0x4a0cf0['a']['Clamp'](_0x596a75*_0x13327f%this['lifeTime']/this['lifeTime']);this['cellIndex']=this['_initialStartSpriteCellID']+_0x2e532d*_0x4c8dd8|0x0;},_0x34169b['prototype']['_inheritParticleInfoToSubEmitter']=function(_0x58c660){if(_0x58c660['particleSystem']['emitter']['position']){var _0x4a1d6f=_0x58c660['particleSystem']['emitter'];if(_0x4a1d6f['position']['copyFrom'](this['position']),_0x58c660['inheritDirection']){var _0x35d494=_0x74d525['c']['Vector3'][0x0];this['direction']['normalizeToRef'](_0x35d494),_0x4a1d6f['setDirection'](_0x35d494,0x0,Math['PI']/0x2);}}else _0x58c660['particleSystem']['emitter']['copyFrom'](this['position']);this['direction']['scaleToRef'](_0x58c660['inheritedVelocityAmount']/0x2,_0x74d525['c']['Vector3'][0x0]),_0x58c660['particleSystem']['_inheritedVelocityOffset']['copyFrom'](_0x74d525['c']['Vector3'][0x0]);},_0x34169b['prototype']['_inheritParticleInfoToSubEmitters']=function(){var _0x4209b0=this;this['_attachedSubEmitters']&&this['_attachedSubEmitters']['length']>0x0&&this['_attachedSubEmitters']['forEach'](function(_0x1563af){_0x4209b0['_inheritParticleInfoToSubEmitter'](_0x1563af);});},_0x34169b['prototype']['_reset']=function(){this['age']=0x0,this['id']=_0x34169b['_Count']++,this['_currentColorGradient']=null,this['_currentSizeGradient']=null,this['_currentAngularSpeedGradient']=null,this['_currentVelocityGradient']=null,this['_currentLimitVelocityGradient']=null,this['_currentDragGradient']=null,this['cellIndex']=this['particleSystem']['startSpriteCellID'],this['_randomCellOffset']=void 0x0;},_0x34169b['prototype']['copyTo']=function(_0x24201b){_0x24201b['position']['copyFrom'](this['position']),this['_initialDirection']?_0x24201b['_initialDirection']?_0x24201b['_initialDirection']['copyFrom'](this['_initialDirection']):_0x24201b['_initialDirection']=this['_initialDirection']['clone']():_0x24201b['_initialDirection']=null,_0x24201b['direction']['copyFrom'](this['direction']),this['_localPosition']&&(_0x24201b['_localPosition']?_0x24201b['_localPosition']['copyFrom'](this['_localPosition']):_0x24201b['_localPosition']=this['_localPosition']['clone']()),_0x24201b['color']['copyFrom'](this['color']),_0x24201b['colorStep']['copyFrom'](this['colorStep']),_0x24201b['lifeTime']=this['lifeTime'],_0x24201b['age']=this['age'],_0x24201b['_randomCellOffset']=this['_randomCellOffset'],_0x24201b['size']=this['size'],_0x24201b['scale']['copyFrom'](this['scale']),_0x24201b['angle']=this['angle'],_0x24201b['angularSpeed']=this['angularSpeed'],_0x24201b['particleSystem']=this['particleSystem'],_0x24201b['cellIndex']=this['cellIndex'],_0x24201b['id']=this['id'],_0x24201b['_attachedSubEmitters']=this['_attachedSubEmitters'],this['_currentColorGradient']&&(_0x24201b['_currentColorGradient']=this['_currentColorGradient'],_0x24201b['_currentColor1']['copyFrom'](this['_currentColor1']),_0x24201b['_currentColor2']['copyFrom'](this['_currentColor2'])),this['_currentSizeGradient']&&(_0x24201b['_currentSizeGradient']=this['_currentSizeGradient'],_0x24201b['_currentSize1']=this['_currentSize1'],_0x24201b['_currentSize2']=this['_currentSize2']),this['_currentAngularSpeedGradient']&&(_0x24201b['_currentAngularSpeedGradient']=this['_currentAngularSpeedGradient'],_0x24201b['_currentAngularSpeed1']=this['_currentAngularSpeed1'],_0x24201b['_currentAngularSpeed2']=this['_currentAngularSpeed2']),this['_currentVelocityGradient']&&(_0x24201b['_currentVelocityGradient']=this['_currentVelocityGradient'],_0x24201b['_currentVelocity1']=this['_currentVelocity1'],_0x24201b['_currentVelocity2']=this['_currentVelocity2']),this['_currentLimitVelocityGradient']&&(_0x24201b['_currentLimitVelocityGradient']=this['_currentLimitVelocityGradient'],_0x24201b['_currentLimitVelocity1']=this['_currentLimitVelocity1'],_0x24201b['_currentLimitVelocity2']=this['_currentLimitVelocity2']),this['_currentDragGradient']&&(_0x24201b['_currentDragGradient']=this['_currentDragGradient'],_0x24201b['_currentDrag1']=this['_currentDrag1'],_0x24201b['_currentDrag2']=this['_currentDrag2']),this['particleSystem']['isAnimationSheetEnabled']&&(_0x24201b['_initialStartSpriteCellID']=this['_initialStartSpriteCellID'],_0x24201b['_initialEndSpriteCellID']=this['_initialEndSpriteCellID']),this['particleSystem']['useRampGradients']&&(_0x24201b['remapData']&&this['remapData']?_0x24201b['remapData']['copyFrom'](this['remapData']):_0x24201b['remapData']=new _0x74d525['f'](0x0,0x0,0x0,0x0)),this['_randomNoiseCoordinates1']&&(_0x24201b['_randomNoiseCoordinates1']?(_0x24201b['_randomNoiseCoordinates1']['copyFrom'](this['_randomNoiseCoordinates1']),_0x24201b['_randomNoiseCoordinates2']['copyFrom'](this['_randomNoiseCoordinates2'])):(_0x24201b['_randomNoiseCoordinates1']=this['_randomNoiseCoordinates1']['clone'](),_0x24201b['_randomNoiseCoordinates2']=this['_randomNoiseCoordinates2']['clone']()));},_0x34169b['_Count']=0x0,_0x34169b;}());!function(_0x1c6e9c){_0x1c6e9c[_0x1c6e9c['ATTACHED']=0x0]='ATTACHED',_0x1c6e9c[_0x1c6e9c['END']=0x1]='END';}(_0x288d3e||(_0x288d3e={}));var _0x5abfe8=(function(){function _0x248ae2(_0xed1239){if(this['particleSystem']=_0xed1239,this['type']=_0x288d3e['END'],this['inheritDirection']=!0x1,this['inheritedVelocityAmount']=0x0,!_0xed1239['emitter']||!_0xed1239['emitter']['dispose']){var _0x348367=_0x3cd573['a']['GetClass']('BABYLON.AbstractMesh');_0xed1239['emitter']=new _0x348367('SubemitterSystemEmitter',_0xed1239['getScene']());}_0xed1239['onDisposeObservable']['add'](function(){_0xed1239['emitter']&&_0xed1239['emitter']['dispose']&&_0xed1239['emitter']['dispose']();});}return _0x248ae2['prototype']['clone']=function(){var _0x3c15c0=this['particleSystem']['emitter'];if(_0x3c15c0){if(_0x3c15c0 instanceof _0x74d525['e'])_0x3c15c0=_0x3c15c0['clone']();else-0x1!==_0x3c15c0['getClassName']()['indexOf']('Mesh')&&((_0x3c15c0=new(_0x3cd573['a']['GetClass']('BABYLON.Mesh'))('',_0x3c15c0['getScene']()))['isVisible']=!0x1);}else _0x3c15c0=new _0x74d525['e']();var _0x117dc4=new _0x248ae2(this['particleSystem']['clone']('',_0x3c15c0));return _0x117dc4['particleSystem']['name']+='Clone',_0x117dc4['type']=this['type'],_0x117dc4['inheritDirection']=this['inheritDirection'],_0x117dc4['inheritedVelocityAmount']=this['inheritedVelocityAmount'],_0x117dc4['particleSystem']['_disposeEmitterOnDispose']=!0x0,_0x117dc4['particleSystem']['disposeOnStop']=!0x0,_0x117dc4;},_0x248ae2['prototype']['serialize']=function(){var _0x2ec920={};return _0x2ec920['type']=this['type'],_0x2ec920['inheritDirection']=this['inheritDirection'],_0x2ec920['inheritedVelocityAmount']=this['inheritedVelocityAmount'],_0x2ec920['particleSystem']=this['particleSystem']['serialize'](),_0x2ec920;},_0x248ae2['_ParseParticleSystem']=function(_0x6fdb74,_0x5dbbf9,_0x3ca264){throw _0x2de344['a']['WarnImport']('ParseParticle');},_0x248ae2['Parse']=function(_0x3c48e4,_0x5d59e3,_0x463f25){var _0x590613=_0x3c48e4['particleSystem'],_0x16b918=new _0x248ae2(_0x248ae2['_ParseParticleSystem'](_0x590613,_0x5d59e3,_0x463f25));return _0x16b918['type']=_0x3c48e4['type'],_0x16b918['inheritDirection']=_0x3c48e4['inheritDirection'],_0x16b918['inheritedVelocityAmount']=_0x3c48e4['inheritedVelocityAmount'],_0x16b918['particleSystem']['_isSubEmitter']=!0x0,_0x16b918;},_0x248ae2['prototype']['dispose']=function(){this['particleSystem']['dispose']();},_0x248ae2;}()),_0x3eaf1d='\x0avarying\x20vec2\x20vUV;\x0avarying\x20vec4\x20vColor;\x0auniform\x20vec4\x20textureMask;\x0auniform\x20sampler2D\x20diffuseSampler;\x0a#include\x0a#include\x0a#include\x0a#include\x0a#ifdef\x20RAMPGRADIENT\x0avarying\x20vec4\x20remapRanges;\x0auniform\x20sampler2D\x20rampSampler;\x0a#endif\x0avoid\x20main(void)\x20{\x0a#include\x0avec4\x20textureColor=texture2D(diffuseSampler,vUV);\x0avec4\x20baseColor=(textureColor*textureMask+(vec4(1.,1.,1.,1.)-textureMask))*vColor;\x0a#ifdef\x20RAMPGRADIENT\x0afloat\x20alpha=baseColor.a;\x0afloat\x20remappedColorIndex=clamp((alpha-remapRanges.x)/remapRanges.y,0.0,1.0);\x0avec4\x20rampColor=texture2D(rampSampler,vec2(1.0-remappedColorIndex,0.));\x0abaseColor.rgb*=rampColor.rgb;\x0a\x0afloat\x20finalAlpha=baseColor.a;\x0abaseColor.a=clamp((alpha*rampColor.a-remapRanges.z)/remapRanges.w,0.0,1.0);\x0a#endif\x0a#ifdef\x20BLENDMULTIPLYMODE\x0afloat\x20sourceAlpha=vColor.a*textureColor.a;\x0abaseColor.rgb=baseColor.rgb*sourceAlpha+vec3(1.0)*(1.0-sourceAlpha);\x0a#endif\x0a\x0a\x0a#ifdef\x20IMAGEPROCESSINGPOSTPROCESS\x0abaseColor.rgb=toLinearSpace(baseColor.rgb);\x0a#else\x0a#ifdef\x20IMAGEPROCESSING\x0abaseColor.rgb=toLinearSpace(baseColor.rgb);\x0abaseColor=applyImageProcessing(baseColor);\x0a#endif\x0a#endif\x0agl_FragColor=baseColor;\x0a}';_0x494b01['a']['ShadersStore']['particlesPixelShader']=_0x3eaf1d;var _0x352d1c='\x0aattribute\x20vec3\x20position;\x0aattribute\x20vec4\x20color;\x0aattribute\x20float\x20angle;\x0aattribute\x20vec2\x20size;\x0a#ifdef\x20ANIMATESHEET\x0aattribute\x20float\x20cellIndex;\x0a#endif\x0a#ifndef\x20BILLBOARD\x0aattribute\x20vec3\x20direction;\x0a#endif\x0a#ifdef\x20BILLBOARDSTRETCHED\x0aattribute\x20vec3\x20direction;\x0a#endif\x0a#ifdef\x20RAMPGRADIENT\x0aattribute\x20vec4\x20remapData;\x0a#endif\x0aattribute\x20vec2\x20offset;\x0a\x0auniform\x20mat4\x20view;\x0auniform\x20mat4\x20projection;\x0auniform\x20vec2\x20translationPivot;\x0a#ifdef\x20ANIMATESHEET\x0auniform\x20vec3\x20particlesInfos;\x0a#endif\x0a\x0avarying\x20vec2\x20vUV;\x0avarying\x20vec4\x20vColor;\x0avarying\x20vec3\x20vPositionW;\x0a#ifdef\x20RAMPGRADIENT\x0avarying\x20vec4\x20remapRanges;\x0a#endif\x0a#if\x20defined(BILLBOARD)\x20&&\x20!defined(BILLBOARDY)\x20&&\x20!defined(BILLBOARDSTRETCHED)\x0auniform\x20mat4\x20invView;\x0a#endif\x0a#include\x0a#ifdef\x20BILLBOARD\x0auniform\x20vec3\x20eyePosition;\x0a#endif\x0avec3\x20rotate(vec3\x20yaxis,vec3\x20rotatedCorner)\x20{\x0avec3\x20xaxis=normalize(cross(vec3(0.,1.0,0.),yaxis));\x0avec3\x20zaxis=normalize(cross(yaxis,xaxis));\x0avec3\x20row0=vec3(xaxis.x,xaxis.y,xaxis.z);\x0avec3\x20row1=vec3(yaxis.x,yaxis.y,yaxis.z);\x0avec3\x20row2=vec3(zaxis.x,zaxis.y,zaxis.z);\x0amat3\x20rotMatrix=mat3(row0,row1,row2);\x0avec3\x20alignedCorner=rotMatrix*rotatedCorner;\x0areturn\x20position+alignedCorner;\x0a}\x0a#ifdef\x20BILLBOARDSTRETCHED\x0avec3\x20rotateAlign(vec3\x20toCamera,vec3\x20rotatedCorner)\x20{\x0avec3\x20normalizedToCamera=normalize(toCamera);\x0avec3\x20normalizedCrossDirToCamera=normalize(cross(normalize(direction),normalizedToCamera));\x0avec3\x20crossProduct=normalize(cross(normalizedToCamera,normalizedCrossDirToCamera));\x0avec3\x20row0=vec3(normalizedCrossDirToCamera.x,normalizedCrossDirToCamera.y,normalizedCrossDirToCamera.z);\x0avec3\x20row1=vec3(crossProduct.x,crossProduct.y,crossProduct.z);\x0avec3\x20row2=vec3(normalizedToCamera.x,normalizedToCamera.y,normalizedToCamera.z);\x0amat3\x20rotMatrix=mat3(row0,row1,row2);\x0avec3\x20alignedCorner=rotMatrix*rotatedCorner;\x0areturn\x20position+alignedCorner;\x0a}\x0a#endif\x0avoid\x20main(void)\x20{\x0avec2\x20cornerPos;\x0acornerPos=(vec2(offset.x-0.5,offset.y-0.5)-translationPivot)*size+translationPivot;\x0a#ifdef\x20BILLBOARD\x0a\x0avec3\x20rotatedCorner;\x0a#ifdef\x20BILLBOARDY\x0arotatedCorner.x=cornerPos.x*cos(angle)-cornerPos.y*sin(angle);\x0arotatedCorner.z=cornerPos.x*sin(angle)+cornerPos.y*cos(angle);\x0arotatedCorner.y=0.;\x0avec3\x20yaxis=position-eyePosition;\x0ayaxis.y=0.;\x0avPositionW=rotate(normalize(yaxis),rotatedCorner);\x0avec3\x20viewPos=(view*vec4(vPositionW,1.0)).xyz;\x0a#elif\x20defined(BILLBOARDSTRETCHED)\x0arotatedCorner.x=cornerPos.x*cos(angle)-cornerPos.y*sin(angle);\x0arotatedCorner.y=cornerPos.x*sin(angle)+cornerPos.y*cos(angle);\x0arotatedCorner.z=0.;\x0avec3\x20toCamera=position-eyePosition;\x0avPositionW=rotateAlign(toCamera,rotatedCorner);\x0avec3\x20viewPos=(view*vec4(vPositionW,1.0)).xyz;\x0a#else\x0arotatedCorner.x=cornerPos.x*cos(angle)-cornerPos.y*sin(angle);\x0arotatedCorner.y=cornerPos.x*sin(angle)+cornerPos.y*cos(angle);\x0arotatedCorner.z=0.;\x0avec3\x20viewPos=(view*vec4(position,1.0)).xyz+rotatedCorner;\x0avPositionW=(invView*vec4(viewPos,1)).xyz;\x0a#endif\x0a#ifdef\x20RAMPGRADIENT\x0aremapRanges=remapData;\x0a#endif\x0a\x0agl_Position=projection*vec4(viewPos,1.0);\x0a#else\x0a\x0avec3\x20rotatedCorner;\x0arotatedCorner.x=cornerPos.x*cos(angle)-cornerPos.y*sin(angle);\x0arotatedCorner.z=cornerPos.x*sin(angle)+cornerPos.y*cos(angle);\x0arotatedCorner.y=0.;\x0avec3\x20yaxis=normalize(direction);\x0avPositionW=rotate(yaxis,rotatedCorner);\x0agl_Position=projection*view*vec4(vPositionW,1.0);\x0a#endif\x0avColor=color;\x0a#ifdef\x20ANIMATESHEET\x0afloat\x20rowOffset=floor(cellIndex*particlesInfos.z);\x0afloat\x20columnOffset=cellIndex-rowOffset/particlesInfos.z;\x0avec2\x20uvScale=particlesInfos.xy;\x0avec2\x20uvOffset=vec2(offset.x\x20,1.0-offset.y);\x0avUV=(uvOffset+vec2(columnOffset,rowOffset))*uvScale;\x0a#else\x0avUV=offset;\x0a#endif\x0a\x0a#if\x20defined(CLIPPLANE)\x20||\x20defined(CLIPPLANE2)\x20||\x20defined(CLIPPLANE3)\x20||\x20defined(CLIPPLANE4)\x20||\x20defined(CLIPPLANE5)\x20||\x20defined(CLIPPLANE6)\x0avec4\x20worldPos=vec4(vPositionW,1.0);\x0a#endif\x0a#include\x0a}';_0x494b01['a']['ShadersStore']['particlesVertexShader']=_0x352d1c;var _0x4baa8b=function(_0x1cd68e){function _0x2f774b(_0x4cc47b,_0x3c3447,_0x2dc321,_0x20c2f0,_0x46a2c0,_0x187df5){void 0x0===_0x20c2f0&&(_0x20c2f0=null),void 0x0===_0x46a2c0&&(_0x46a2c0=!0x1),void 0x0===_0x187df5&&(_0x187df5=0.01);var _0x207488=_0x1cd68e['call'](this,_0x4cc47b)||this;return _0x207488['_inheritedVelocityOffset']=new _0x74d525['e'](),_0x207488['onDisposeObservable']=new _0x6ac1f7['c'](),_0x207488['onStoppedObservable']=new _0x6ac1f7['c'](),_0x207488['_particles']=new Array(),_0x207488['_stockParticles']=new Array(),_0x207488['_newPartsExcess']=0x0,_0x207488['_vertexBuffers']={},_0x207488['_scaledColorStep']=new _0x39310d['b'](0x0,0x0,0x0,0x0),_0x207488['_colorDiff']=new _0x39310d['b'](0x0,0x0,0x0,0x0),_0x207488['_scaledDirection']=_0x74d525['e']['Zero'](),_0x207488['_scaledGravity']=_0x74d525['e']['Zero'](),_0x207488['_currentRenderId']=-0x1,_0x207488['_useInstancing']=!0x1,_0x207488['_started']=!0x1,_0x207488['_stopped']=!0x1,_0x207488['_actualFrame']=0x0,_0x207488['_currentEmitRate1']=0x0,_0x207488['_currentEmitRate2']=0x0,_0x207488['_currentStartSize1']=0x0,_0x207488['_currentStartSize2']=0x0,_0x207488['_rawTextureWidth']=0x100,_0x207488['_useRampGradients']=!0x1,_0x207488['_disposeEmitterOnDispose']=!0x1,_0x207488['isLocal']=!0x1,_0x207488['_onBeforeDrawParticlesObservable']=null,_0x207488['recycleParticle']=function(_0x3cd92e){var _0x481530=_0x207488['_particles']['pop']();_0x481530!==_0x3cd92e&&_0x481530['copyTo'](_0x3cd92e),_0x207488['_stockParticles']['push'](_0x481530);},_0x207488['_createParticle']=function(){var _0x5f0c1c;if(0x0!==_0x207488['_stockParticles']['length']?(_0x5f0c1c=_0x207488['_stockParticles']['pop']())['_reset']():_0x5f0c1c=new _0x387dbf(_0x207488),_0x207488['_subEmitters']&&_0x207488['_subEmitters']['length']>0x0){var _0x13dd59=_0x207488['_subEmitters'][Math['floor'](Math['random']()*_0x207488['_subEmitters']['length'])];_0x5f0c1c['_attachedSubEmitters']=[],_0x13dd59['forEach'](function(_0x42de4b){if(_0x42de4b['type']===_0x288d3e['ATTACHED']){var _0x366d10=_0x42de4b['clone']();_0x5f0c1c['_attachedSubEmitters']['push'](_0x366d10),_0x366d10['particleSystem']['start']();}});}return _0x5f0c1c;},_0x207488['_emitFromParticle']=function(_0x5f3b8c){if(_0x207488['_subEmitters']&&0x0!==_0x207488['_subEmitters']['length']){var _0x42ccfd=Math['floor'](Math['random']()*_0x207488['_subEmitters']['length']);_0x207488['_subEmitters'][_0x42ccfd]['forEach'](function(_0x12e0f6){if(_0x12e0f6['type']===_0x288d3e['END']){var _0x2c2550=_0x12e0f6['clone']();_0x5f3b8c['_inheritParticleInfoToSubEmitter'](_0x2c2550),_0x2c2550['particleSystem']['_rootParticleSystem']=_0x207488,_0x207488['activeSubSystems']['push'](_0x2c2550['particleSystem']),_0x2c2550['particleSystem']['start']();}});}},_0x207488['_capacity']=_0x3c3447,_0x207488['_epsilon']=_0x187df5,_0x207488['_isAnimationSheetEnabled']=_0x46a2c0,_0x2dc321&&'Scene'!==_0x2dc321['getClassName']()?(_0x207488['_engine']=_0x2dc321,_0x207488['defaultProjectionMatrix']=_0x74d525['a']['PerspectiveFovLH'](0.8,0x1,0.1,0x64)):(_0x207488['_scene']=_0x2dc321||_0x44b9ce['a']['LastCreatedScene'],_0x207488['_engine']=_0x207488['_scene']['getEngine'](),_0x207488['uniqueId']=_0x207488['_scene']['getUniqueId'](),_0x207488['_scene']['particleSystems']['push'](_0x207488)),_0x207488['_engine']['getCaps']()['vertexArrayObject']&&(_0x207488['_vertexArrayObject']=null),_0x207488['_attachImageProcessingConfiguration'](null),_0x207488['_customEffect']={0x0:_0x20c2f0},_0x207488['_useInstancing']=_0x207488['_engine']['getCaps']()['instancedArrays'],_0x207488['_createIndexBuffer'](),_0x207488['_createVertexBuffers'](),_0x207488['particleEmitterType']=new _0x3faf18(),_0x207488['updateFunction']=function(_0x3bfadf){var _0x4e7dbc=null,_0xa7ab01=null;_0x207488['noiseTexture']&&(_0x4e7dbc=_0x207488['noiseTexture']['getSize'](),_0xa7ab01=_0x207488['noiseTexture']['getContent']());for(var _0x1a692c,_0x5eb894=function(){_0x1a692c=_0x3bfadf[_0x22ed80];var _0x5755e7=_0x207488['_scaledUpdateSpeed'],_0x1c39a5=_0x1a692c['age'];if(_0x1a692c['age']+=_0x5755e7,_0x1a692c['age']>_0x1a692c['lifeTime']){var _0x7a4056=_0x1a692c['age']-_0x1c39a5;_0x5755e7=(_0x1a692c['lifeTime']-_0x1c39a5)*_0x5755e7/_0x7a4056,_0x1a692c['age']=_0x1a692c['lifeTime'];}var _0x5445c0=_0x1a692c['age']/_0x1a692c['lifeTime'];_0x207488['_colorGradients']&&_0x207488['_colorGradients']['length']>0x0?_0x2688df['GetCurrentGradient'](_0x5445c0,_0x207488['_colorGradients'],function(_0x1c33c3,_0x19e265,_0x5503bf){_0x1c33c3!==_0x1a692c['_currentColorGradient']&&(_0x1a692c['_currentColor1']['copyFrom'](_0x1a692c['_currentColor2']),_0x19e265['getColorToRef'](_0x1a692c['_currentColor2']),_0x1a692c['_currentColorGradient']=_0x1c33c3),_0x39310d['b']['LerpToRef'](_0x1a692c['_currentColor1'],_0x1a692c['_currentColor2'],_0x5503bf,_0x1a692c['color']);}):(_0x1a692c['colorStep']['scaleToRef'](_0x5755e7,_0x207488['_scaledColorStep']),_0x1a692c['color']['addInPlace'](_0x207488['_scaledColorStep']),_0x1a692c['color']['a']<0x0&&(_0x1a692c['color']['a']=0x0)),_0x207488['_angularSpeedGradients']&&_0x207488['_angularSpeedGradients']['length']>0x0&&_0x2688df['GetCurrentGradient'](_0x5445c0,_0x207488['_angularSpeedGradients'],function(_0x28cc2e,_0x290167,_0x3b7abb){_0x28cc2e!==_0x1a692c['_currentAngularSpeedGradient']&&(_0x1a692c['_currentAngularSpeed1']=_0x1a692c['_currentAngularSpeed2'],_0x1a692c['_currentAngularSpeed2']=_0x290167['getFactor'](),_0x1a692c['_currentAngularSpeedGradient']=_0x28cc2e),_0x1a692c['angularSpeed']=_0x4a0cf0['a']['Lerp'](_0x1a692c['_currentAngularSpeed1'],_0x1a692c['_currentAngularSpeed2'],_0x3b7abb);}),_0x1a692c['angle']+=_0x1a692c['angularSpeed']*_0x5755e7;var _0x13734b=_0x5755e7;if(_0x207488['_velocityGradients']&&_0x207488['_velocityGradients']['length']>0x0&&_0x2688df['GetCurrentGradient'](_0x5445c0,_0x207488['_velocityGradients'],function(_0x14fc93,_0x2c0e65,_0x1a943a){_0x14fc93!==_0x1a692c['_currentVelocityGradient']&&(_0x1a692c['_currentVelocity1']=_0x1a692c['_currentVelocity2'],_0x1a692c['_currentVelocity2']=_0x2c0e65['getFactor'](),_0x1a692c['_currentVelocityGradient']=_0x14fc93),_0x13734b*=_0x4a0cf0['a']['Lerp'](_0x1a692c['_currentVelocity1'],_0x1a692c['_currentVelocity2'],_0x1a943a);}),_0x1a692c['direction']['scaleToRef'](_0x13734b,_0x207488['_scaledDirection']),_0x207488['_limitVelocityGradients']&&_0x207488['_limitVelocityGradients']['length']>0x0&&_0x2688df['GetCurrentGradient'](_0x5445c0,_0x207488['_limitVelocityGradients'],function(_0x17f2f4,_0x472c75,_0x31bda9){_0x17f2f4!==_0x1a692c['_currentLimitVelocityGradient']&&(_0x1a692c['_currentLimitVelocity1']=_0x1a692c['_currentLimitVelocity2'],_0x1a692c['_currentLimitVelocity2']=_0x472c75['getFactor'](),_0x1a692c['_currentLimitVelocityGradient']=_0x17f2f4);var _0x1a421c=_0x4a0cf0['a']['Lerp'](_0x1a692c['_currentLimitVelocity1'],_0x1a692c['_currentLimitVelocity2'],_0x31bda9);_0x1a692c['direction']['length']()>_0x1a421c&&_0x1a692c['direction']['scaleInPlace'](_0x207488['limitVelocityDamping']);}),_0x207488['_dragGradients']&&_0x207488['_dragGradients']['length']>0x0&&_0x2688df['GetCurrentGradient'](_0x5445c0,_0x207488['_dragGradients'],function(_0x1132d2,_0x25b186,_0x8d2060){_0x1132d2!==_0x1a692c['_currentDragGradient']&&(_0x1a692c['_currentDrag1']=_0x1a692c['_currentDrag2'],_0x1a692c['_currentDrag2']=_0x25b186['getFactor'](),_0x1a692c['_currentDragGradient']=_0x1132d2);var _0x30feeb=_0x4a0cf0['a']['Lerp'](_0x1a692c['_currentDrag1'],_0x1a692c['_currentDrag2'],_0x8d2060);_0x207488['_scaledDirection']['scaleInPlace'](0x1-_0x30feeb);}),_0x207488['isLocal']&&_0x1a692c['_localPosition']?(_0x1a692c['_localPosition']['addInPlace'](_0x207488['_scaledDirection']),_0x74d525['e']['TransformCoordinatesToRef'](_0x1a692c['_localPosition'],_0x207488['_emitterWorldMatrix'],_0x1a692c['position'])):_0x1a692c['position']['addInPlace'](_0x207488['_scaledDirection']),_0xa7ab01&&_0x4e7dbc&&_0x1a692c['_randomNoiseCoordinates1']){var _0x29132b=_0x207488['_fetchR'](_0x1a692c['_randomNoiseCoordinates1']['x'],_0x1a692c['_randomNoiseCoordinates1']['y'],_0x4e7dbc['width'],_0x4e7dbc['height'],_0xa7ab01),_0x4add30=_0x207488['_fetchR'](_0x1a692c['_randomNoiseCoordinates1']['z'],_0x1a692c['_randomNoiseCoordinates2']['x'],_0x4e7dbc['width'],_0x4e7dbc['height'],_0xa7ab01),_0xdee3ba=_0x207488['_fetchR'](_0x1a692c['_randomNoiseCoordinates2']['y'],_0x1a692c['_randomNoiseCoordinates2']['z'],_0x4e7dbc['width'],_0x4e7dbc['height'],_0xa7ab01),_0x645df1=_0x74d525['c']['Vector3'][0x0],_0x469b3d=_0x74d525['c']['Vector3'][0x1];_0x645df1['copyFromFloats']((0x2*_0x29132b-0x1)*_0x207488['noiseStrength']['x'],(0x2*_0x4add30-0x1)*_0x207488['noiseStrength']['y'],(0x2*_0xdee3ba-0x1)*_0x207488['noiseStrength']['z']),_0x645df1['scaleToRef'](_0x5755e7,_0x469b3d),_0x1a692c['direction']['addInPlace'](_0x469b3d);}if(_0x207488['gravity']['scaleToRef'](_0x5755e7,_0x207488['_scaledGravity']),_0x1a692c['direction']['addInPlace'](_0x207488['_scaledGravity']),_0x207488['_sizeGradients']&&_0x207488['_sizeGradients']['length']>0x0&&_0x2688df['GetCurrentGradient'](_0x5445c0,_0x207488['_sizeGradients'],function(_0x116583,_0x3d1652,_0x2392ff){_0x116583!==_0x1a692c['_currentSizeGradient']&&(_0x1a692c['_currentSize1']=_0x1a692c['_currentSize2'],_0x1a692c['_currentSize2']=_0x3d1652['getFactor'](),_0x1a692c['_currentSizeGradient']=_0x116583),_0x1a692c['size']=_0x4a0cf0['a']['Lerp'](_0x1a692c['_currentSize1'],_0x1a692c['_currentSize2'],_0x2392ff);}),_0x207488['_useRampGradients']&&(_0x207488['_colorRemapGradients']&&_0x207488['_colorRemapGradients']['length']>0x0&&_0x2688df['GetCurrentGradient'](_0x5445c0,_0x207488['_colorRemapGradients'],function(_0x39fcf1,_0xd19185,_0x3649cf){var _0x589beb=_0x4a0cf0['a']['Lerp'](_0x39fcf1['factor1'],_0xd19185['factor1'],_0x3649cf),_0x36a73c=_0x4a0cf0['a']['Lerp'](_0x39fcf1['factor2'],_0xd19185['factor2'],_0x3649cf);_0x1a692c['remapData']['x']=_0x589beb,_0x1a692c['remapData']['y']=_0x36a73c-_0x589beb;}),_0x207488['_alphaRemapGradients']&&_0x207488['_alphaRemapGradients']['length']>0x0&&_0x2688df['GetCurrentGradient'](_0x5445c0,_0x207488['_alphaRemapGradients'],function(_0x4d58f5,_0x356527,_0x3d47cc){var _0x4fa4fa=_0x4a0cf0['a']['Lerp'](_0x4d58f5['factor1'],_0x356527['factor1'],_0x3d47cc),_0x294f74=_0x4a0cf0['a']['Lerp'](_0x4d58f5['factor2'],_0x356527['factor2'],_0x3d47cc);_0x1a692c['remapData']['z']=_0x4fa4fa,_0x1a692c['remapData']['w']=_0x294f74-_0x4fa4fa;})),_0x207488['_isAnimationSheetEnabled']&&_0x1a692c['updateCellIndex'](),_0x1a692c['_inheritParticleInfoToSubEmitters'](),_0x1a692c['age']>=_0x1a692c['lifeTime'])return _0x207488['_emitFromParticle'](_0x1a692c),_0x1a692c['_attachedSubEmitters']&&(_0x1a692c['_attachedSubEmitters']['forEach'](function(_0x11414b){_0x11414b['particleSystem']['disposeOnStop']=!0x0,_0x11414b['particleSystem']['stop']();}),_0x1a692c['_attachedSubEmitters']=null),_0x207488['recycleParticle'](_0x1a692c),_0x22ed80--,'continue';},_0x22ed80=0x0;_0x22ed80<_0x3bfadf['length'];_0x22ed80++)_0x5eb894();},_0x207488;}return Object(_0x18e13d['d'])(_0x2f774b,_0x1cd68e),Object['defineProperty'](_0x2f774b['prototype'],'onDispose',{'set':function(_0x22bec8){this['_onDisposeObserver']&&this['onDisposeObservable']['remove'](this['_onDisposeObserver']),this['_onDisposeObserver']=this['onDisposeObservable']['add'](_0x22bec8);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2f774b['prototype'],'useRampGradients',{'get':function(){return this['_useRampGradients'];},'set':function(_0x5428ef){this['_useRampGradients']!==_0x5428ef&&(this['_useRampGradients']=_0x5428ef,this['_resetEffect']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2f774b['prototype'],'particles',{'get':function(){return this['_particles'];},'enumerable':!0x1,'configurable':!0x0}),_0x2f774b['prototype']['getActiveCount']=function(){return this['_particles']['length'];},_0x2f774b['prototype']['getClassName']=function(){return'ParticleSystem';},_0x2f774b['prototype']['isStopping']=function(){return this['_stopped']&&this['isAlive']();},_0x2f774b['prototype']['getCustomEffect']=function(_0x5b7b64){var _0x5be015;return void 0x0===_0x5b7b64&&(_0x5b7b64=0x0),null!==(_0x5be015=this['_customEffect'][_0x5b7b64])&&void 0x0!==_0x5be015?_0x5be015:this['_customEffect'][0x0];},_0x2f774b['prototype']['setCustomEffect']=function(_0x30e7e0,_0x5d011a){void 0x0===_0x5d011a&&(_0x5d011a=0x0),this['_customEffect'][_0x5d011a]=_0x30e7e0;},Object['defineProperty'](_0x2f774b['prototype'],'onBeforeDrawParticlesObservable',{'get':function(){return this['_onBeforeDrawParticlesObservable']||(this['_onBeforeDrawParticlesObservable']=new _0x6ac1f7['c']()),this['_onBeforeDrawParticlesObservable'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2f774b['prototype'],'vertexShaderName',{'get':function(){return'particles';},'enumerable':!0x1,'configurable':!0x0}),_0x2f774b['prototype']['_addFactorGradient']=function(_0x2fa7c9,_0x2c3483,_0xf643d5,_0x56e093){var _0x16a7de=new _0x3f4c49(_0x2c3483,_0xf643d5,_0x56e093);_0x2fa7c9['push'](_0x16a7de),_0x2fa7c9['sort'](function(_0x3128fc,_0x398842){return _0x3128fc['gradient']<_0x398842['gradient']?-0x1:_0x3128fc['gradient']>_0x398842['gradient']?0x1:0x0;});},_0x2f774b['prototype']['_removeFactorGradient']=function(_0x247d87,_0x2bb8c4){if(_0x247d87)for(var _0x40536c=0x0,_0x5db476=0x0,_0x3f0bb3=_0x247d87;_0x5db476<_0x3f0bb3['length'];_0x5db476++){if(_0x3f0bb3[_0x5db476]['gradient']===_0x2bb8c4){_0x247d87['splice'](_0x40536c,0x1);break;}_0x40536c++;}},_0x2f774b['prototype']['addLifeTimeGradient']=function(_0x3564cf,_0x18c205,_0x1016f6){return this['_lifeTimeGradients']||(this['_lifeTimeGradients']=[]),this['_addFactorGradient'](this['_lifeTimeGradients'],_0x3564cf,_0x18c205,_0x1016f6),this;},_0x2f774b['prototype']['removeLifeTimeGradient']=function(_0x5cabe0){return this['_removeFactorGradient'](this['_lifeTimeGradients'],_0x5cabe0),this;},_0x2f774b['prototype']['addSizeGradient']=function(_0x3ff1d5,_0x44de66,_0x40e011){return this['_sizeGradients']||(this['_sizeGradients']=[]),this['_addFactorGradient'](this['_sizeGradients'],_0x3ff1d5,_0x44de66,_0x40e011),this;},_0x2f774b['prototype']['removeSizeGradient']=function(_0x5cdaa6){return this['_removeFactorGradient'](this['_sizeGradients'],_0x5cdaa6),this;},_0x2f774b['prototype']['addColorRemapGradient']=function(_0x57455f,_0x341623,_0x494b9d){return this['_colorRemapGradients']||(this['_colorRemapGradients']=[]),this['_addFactorGradient'](this['_colorRemapGradients'],_0x57455f,_0x341623,_0x494b9d),this;},_0x2f774b['prototype']['removeColorRemapGradient']=function(_0x391fb8){return this['_removeFactorGradient'](this['_colorRemapGradients'],_0x391fb8),this;},_0x2f774b['prototype']['addAlphaRemapGradient']=function(_0x222114,_0x547649,_0x317017){return this['_alphaRemapGradients']||(this['_alphaRemapGradients']=[]),this['_addFactorGradient'](this['_alphaRemapGradients'],_0x222114,_0x547649,_0x317017),this;},_0x2f774b['prototype']['removeAlphaRemapGradient']=function(_0x5bde30){return this['_removeFactorGradient'](this['_alphaRemapGradients'],_0x5bde30),this;},_0x2f774b['prototype']['addAngularSpeedGradient']=function(_0x6b1799,_0x34a914,_0x325c37){return this['_angularSpeedGradients']||(this['_angularSpeedGradients']=[]),this['_addFactorGradient'](this['_angularSpeedGradients'],_0x6b1799,_0x34a914,_0x325c37),this;},_0x2f774b['prototype']['removeAngularSpeedGradient']=function(_0x5d1866){return this['_removeFactorGradient'](this['_angularSpeedGradients'],_0x5d1866),this;},_0x2f774b['prototype']['addVelocityGradient']=function(_0x2297d2,_0x9527b6,_0x51cb63){return this['_velocityGradients']||(this['_velocityGradients']=[]),this['_addFactorGradient'](this['_velocityGradients'],_0x2297d2,_0x9527b6,_0x51cb63),this;},_0x2f774b['prototype']['removeVelocityGradient']=function(_0x4046e9){return this['_removeFactorGradient'](this['_velocityGradients'],_0x4046e9),this;},_0x2f774b['prototype']['addLimitVelocityGradient']=function(_0x10b59f,_0x3a945d,_0x4c421f){return this['_limitVelocityGradients']||(this['_limitVelocityGradients']=[]),this['_addFactorGradient'](this['_limitVelocityGradients'],_0x10b59f,_0x3a945d,_0x4c421f),this;},_0x2f774b['prototype']['removeLimitVelocityGradient']=function(_0xd79c0){return this['_removeFactorGradient'](this['_limitVelocityGradients'],_0xd79c0),this;},_0x2f774b['prototype']['addDragGradient']=function(_0x49cd1d,_0x406931,_0x3c82d5){return this['_dragGradients']||(this['_dragGradients']=[]),this['_addFactorGradient'](this['_dragGradients'],_0x49cd1d,_0x406931,_0x3c82d5),this;},_0x2f774b['prototype']['removeDragGradient']=function(_0x1abad8){return this['_removeFactorGradient'](this['_dragGradients'],_0x1abad8),this;},_0x2f774b['prototype']['addEmitRateGradient']=function(_0xfb954e,_0x3c43b5,_0x4ad48c){return this['_emitRateGradients']||(this['_emitRateGradients']=[]),this['_addFactorGradient'](this['_emitRateGradients'],_0xfb954e,_0x3c43b5,_0x4ad48c),this;},_0x2f774b['prototype']['removeEmitRateGradient']=function(_0x1eea2a){return this['_removeFactorGradient'](this['_emitRateGradients'],_0x1eea2a),this;},_0x2f774b['prototype']['addStartSizeGradient']=function(_0x92e5a3,_0x3ca8bc,_0x4008c2){return this['_startSizeGradients']||(this['_startSizeGradients']=[]),this['_addFactorGradient'](this['_startSizeGradients'],_0x92e5a3,_0x3ca8bc,_0x4008c2),this;},_0x2f774b['prototype']['removeStartSizeGradient']=function(_0xef54f8){return this['_removeFactorGradient'](this['_startSizeGradients'],_0xef54f8),this;},_0x2f774b['prototype']['_createRampGradientTexture']=function(){if(this['_rampGradients']&&this['_rampGradients']['length']&&!this['_rampGradientsTexture']&&this['_scene']){for(var _0x2105c6=new Uint8Array(0x4*this['_rawTextureWidth']),_0x812240=_0x39310d['c']['Color3'][0x0],_0x2da643=0x0;_0x2da643_0x404363['gradient']?0x1:0x0;}),this['_rampGradientsTexture']&&(this['_rampGradientsTexture']['dispose'](),this['_rampGradientsTexture']=null),this['_createRampGradientTexture']());},_0x2f774b['prototype']['addRampGradient']=function(_0xeeb912,_0x4cb023){this['_rampGradients']||(this['_rampGradients']=[]);var _0x225a5a=new _0x4394fb(_0xeeb912,_0x4cb023);return this['_rampGradients']['push'](_0x225a5a),this['_syncRampGradientTexture'](),this;},_0x2f774b['prototype']['removeRampGradient']=function(_0x3d7125){return this['_removeGradientAndTexture'](_0x3d7125,this['_rampGradients'],this['_rampGradientsTexture']),this['_rampGradientsTexture']=null,this['_rampGradients']&&this['_rampGradients']['length']>0x0&&this['_createRampGradientTexture'](),this;},_0x2f774b['prototype']['addColorGradient']=function(_0x3fc71f,_0xc94030,_0x1c0fc6){this['_colorGradients']||(this['_colorGradients']=[]);var _0x1fce6d=new _0x3b38b8(_0x3fc71f,_0xc94030,_0x1c0fc6);return this['_colorGradients']['push'](_0x1fce6d),this['_colorGradients']['sort'](function(_0x195c24,_0x42e77e){return _0x195c24['gradient']<_0x42e77e['gradient']?-0x1:_0x195c24['gradient']>_0x42e77e['gradient']?0x1:0x0;}),this;},_0x2f774b['prototype']['removeColorGradient']=function(_0x1b44a2){if(!this['_colorGradients'])return this;for(var _0x7a9f0e=0x0,_0x3be59c=0x0,_0x1d45d3=this['_colorGradients'];_0x3be59c<_0x1d45d3['length'];_0x3be59c++){if(_0x1d45d3[_0x3be59c]['gradient']===_0x1b44a2){this['_colorGradients']['splice'](_0x7a9f0e,0x1);break;}_0x7a9f0e++;}return this;},_0x2f774b['prototype']['_fetchR']=function(_0x3200ec,_0x57429c,_0xc297c5,_0x51891d,_0x43a2a4){return _0x43a2a4[0x4*(((_0x3200ec=0.5*Math['abs'](_0x3200ec)+0.5)*_0xc297c5%_0xc297c5|0x0)+((_0x57429c=0.5*Math['abs'](_0x57429c)+0.5)*_0x51891d%_0x51891d|0x0)*_0xc297c5)]/0xff;},_0x2f774b['prototype']['_reset']=function(){this['_resetEffect']();},_0x2f774b['prototype']['_resetEffect']=function(){this['_vertexBuffer']&&(this['_vertexBuffer']['dispose'](),this['_vertexBuffer']=null),this['_spriteBuffer']&&(this['_spriteBuffer']['dispose'](),this['_spriteBuffer']=null),this['_vertexArrayObject']&&(this['_engine']['releaseVertexArrayObject'](this['_vertexArrayObject']),this['_vertexArrayObject']=null),this['_createVertexBuffers']();},_0x2f774b['prototype']['_createVertexBuffers']=function(){this['_vertexBufferSize']=this['_useInstancing']?0xa:0xc,this['_isAnimationSheetEnabled']&&(this['_vertexBufferSize']+=0x1),this['_isBillboardBased']&&this['billboardMode']!==_0x2f774b['BILLBOARDMODE_STRETCHED']||(this['_vertexBufferSize']+=0x3),this['_useRampGradients']&&(this['_vertexBufferSize']+=0x4);var _0x36c6fb=this['_engine'];this['_vertexData']=new Float32Array(this['_capacity']*this['_vertexBufferSize']*(this['_useInstancing']?0x1:0x4)),this['_vertexBuffer']=new _0x212fbd['a'](_0x36c6fb,this['_vertexData'],!0x0,this['_vertexBufferSize']);var _0x36a395=0x0,_0x2c81a4=this['_vertexBuffer']['createVertexBuffer'](_0x212fbd['b']['PositionKind'],_0x36a395,0x3,this['_vertexBufferSize'],this['_useInstancing']);this['_vertexBuffers'][_0x212fbd['b']['PositionKind']]=_0x2c81a4,_0x36a395+=0x3;var _0x1ecbdf=this['_vertexBuffer']['createVertexBuffer'](_0x212fbd['b']['ColorKind'],_0x36a395,0x4,this['_vertexBufferSize'],this['_useInstancing']);this['_vertexBuffers'][_0x212fbd['b']['ColorKind']]=_0x1ecbdf,_0x36a395+=0x4;var _0x44343d=this['_vertexBuffer']['createVertexBuffer']('angle',_0x36a395,0x1,this['_vertexBufferSize'],this['_useInstancing']);this['_vertexBuffers']['angle']=_0x44343d,_0x36a395+=0x1;var _0x16e751,_0x2d6922=this['_vertexBuffer']['createVertexBuffer']('size',_0x36a395,0x2,this['_vertexBufferSize'],this['_useInstancing']);if(this['_vertexBuffers']['size']=_0x2d6922,_0x36a395+=0x2,this['_isAnimationSheetEnabled']){var _0x37d343=this['_vertexBuffer']['createVertexBuffer']('cellIndex',_0x36a395,0x1,this['_vertexBufferSize'],this['_useInstancing']);this['_vertexBuffers']['cellIndex']=_0x37d343,_0x36a395+=0x1;}if(!this['_isBillboardBased']||this['billboardMode']===_0x2f774b['BILLBOARDMODE_STRETCHED']){var _0x122050=this['_vertexBuffer']['createVertexBuffer']('direction',_0x36a395,0x3,this['_vertexBufferSize'],this['_useInstancing']);this['_vertexBuffers']['direction']=_0x122050,_0x36a395+=0x3;}if(this['_useRampGradients']){var _0xd85208=this['_vertexBuffer']['createVertexBuffer']('remapData',_0x36a395,0x4,this['_vertexBufferSize'],this['_useInstancing']);this['_vertexBuffers']['remapData']=_0xd85208,_0x36a395+=0x4;}if(this['_useInstancing']){var _0x520298=new Float32Array([0x0,0x0,0x1,0x0,0x1,0x1,0x0,0x1]);this['_spriteBuffer']=new _0x212fbd['a'](_0x36c6fb,_0x520298,!0x1,0x2),_0x16e751=this['_spriteBuffer']['createVertexBuffer']('offset',0x0,0x2);}else _0x16e751=this['_vertexBuffer']['createVertexBuffer']('offset',_0x36a395,0x2,this['_vertexBufferSize'],this['_useInstancing']),_0x36a395+=0x2;this['_vertexBuffers']['offset']=_0x16e751;},_0x2f774b['prototype']['_createIndexBuffer']=function(){if(!this['_useInstancing']){for(var _0x39255d=[],_0x8dd83c=0x0,_0x21fa96=0x0;_0x21fa960x0&&(this['_currentEmitRateGradient']=this['_emitRateGradients'][0x0],this['_currentEmitRate1']=this['_currentEmitRateGradient']['getFactor'](),this['_currentEmitRate2']=this['_currentEmitRate1']),this['_emitRateGradients']['length']>0x1&&(this['_currentEmitRate2']=this['_emitRateGradients'][0x1]['getFactor']())),this['_startSizeGradients']&&(this['_startSizeGradients']['length']>0x0&&(this['_currentStartSizeGradient']=this['_startSizeGradients'][0x0],this['_currentStartSize1']=this['_currentStartSizeGradient']['getFactor'](),this['_currentStartSize2']=this['_currentStartSize1']),this['_startSizeGradients']['length']>0x1&&(this['_currentStartSize2']=this['_startSizeGradients'][0x1]['getFactor']())),this['preWarmCycles']){-0x1!==(null===(_0x21fcde=this['emitter'])||void 0x0===_0x21fcde?void 0x0:_0x21fcde['getClassName']()['indexOf']('Mesh'))&&this['emitter']['computeWorldMatrix'](!0x0);var _0x8c4c55=this['noiseTexture'];if(_0x8c4c55&&_0x8c4c55['onGeneratedObservable'])_0x8c4c55['onGeneratedObservable']['addOnce'](function(){setTimeout(function(){for(var _0xd8605b=0x0;_0xd8605b<_0x4b1813['preWarmCycles'];_0xd8605b++)_0x4b1813['animate'](!0x0),_0x8c4c55['render']();});});else{for(var _0x31b430=0x0;_0x31b4300x0&&this['_scene']&&this['_scene']['beginAnimation'](this,this['beginAnimationFrom'],this['beginAnimationTo'],this['beginAnimationLoop']);}},_0x2f774b['prototype']['stop']=function(_0x49f316){void 0x0===_0x49f316&&(_0x49f316=!0x0),this['_stopped']||(this['onStoppedObservable']['notifyObservers'](this),this['_stopped']=!0x0,_0x49f316&&this['_stopSubEmitters']());},_0x2f774b['prototype']['reset']=function(){this['_stockParticles']=[],this['_particles']=[];},_0x2f774b['prototype']['_appendParticleVertex']=function(_0x547227,_0x54ec26,_0x13edd5,_0x288a94){var _0x52cab2=_0x547227*this['_vertexBufferSize'];if(this['_vertexData'][_0x52cab2++]=_0x54ec26['position']['x']+this['worldOffset']['x'],this['_vertexData'][_0x52cab2++]=_0x54ec26['position']['y']+this['worldOffset']['y'],this['_vertexData'][_0x52cab2++]=_0x54ec26['position']['z']+this['worldOffset']['z'],this['_vertexData'][_0x52cab2++]=_0x54ec26['color']['r'],this['_vertexData'][_0x52cab2++]=_0x54ec26['color']['g'],this['_vertexData'][_0x52cab2++]=_0x54ec26['color']['b'],this['_vertexData'][_0x52cab2++]=_0x54ec26['color']['a'],this['_vertexData'][_0x52cab2++]=_0x54ec26['angle'],this['_vertexData'][_0x52cab2++]=_0x54ec26['scale']['x']*_0x54ec26['size'],this['_vertexData'][_0x52cab2++]=_0x54ec26['scale']['y']*_0x54ec26['size'],this['_isAnimationSheetEnabled']&&(this['_vertexData'][_0x52cab2++]=_0x54ec26['cellIndex']),this['_isBillboardBased'])this['billboardMode']===_0x2f774b['BILLBOARDMODE_STRETCHED']&&(this['_vertexData'][_0x52cab2++]=_0x54ec26['direction']['x'],this['_vertexData'][_0x52cab2++]=_0x54ec26['direction']['y'],this['_vertexData'][_0x52cab2++]=_0x54ec26['direction']['z']);else{if(_0x54ec26['_initialDirection']){var _0x571bfe=_0x54ec26['_initialDirection'];this['isLocal']&&(_0x74d525['e']['TransformNormalToRef'](_0x571bfe,this['_emitterWorldMatrix'],_0x74d525['c']['Vector3'][0x0]),_0x571bfe=_0x74d525['c']['Vector3'][0x0]),0x0===_0x571bfe['x']&&0x0===_0x571bfe['z']&&(_0x571bfe['x']=0.001),this['_vertexData'][_0x52cab2++]=_0x571bfe['x'],this['_vertexData'][_0x52cab2++]=_0x571bfe['y'],this['_vertexData'][_0x52cab2++]=_0x571bfe['z'];}else{var _0x1fbd0b=_0x54ec26['direction'];this['isLocal']&&(_0x74d525['e']['TransformNormalToRef'](_0x1fbd0b,this['_emitterWorldMatrix'],_0x74d525['c']['Vector3'][0x0]),_0x1fbd0b=_0x74d525['c']['Vector3'][0x0]),0x0===_0x1fbd0b['x']&&0x0===_0x1fbd0b['z']&&(_0x1fbd0b['x']=0.001),this['_vertexData'][_0x52cab2++]=_0x1fbd0b['x'],this['_vertexData'][_0x52cab2++]=_0x1fbd0b['y'],this['_vertexData'][_0x52cab2++]=_0x1fbd0b['z'];}}this['_useRampGradients']&&_0x54ec26['remapData']&&(this['_vertexData'][_0x52cab2++]=_0x54ec26['remapData']['x'],this['_vertexData'][_0x52cab2++]=_0x54ec26['remapData']['y'],this['_vertexData'][_0x52cab2++]=_0x54ec26['remapData']['z'],this['_vertexData'][_0x52cab2++]=_0x54ec26['remapData']['w']),this['_useInstancing']||(this['_isAnimationSheetEnabled']&&(0x0===_0x13edd5?_0x13edd5=this['_epsilon']:0x1===_0x13edd5&&(_0x13edd5=0x1-this['_epsilon']),0x0===_0x288a94?_0x288a94=this['_epsilon']:0x1===_0x288a94&&(_0x288a94=0x1-this['_epsilon'])),this['_vertexData'][_0x52cab2++]=_0x13edd5,this['_vertexData'][_0x52cab2++]=_0x288a94);},_0x2f774b['prototype']['_stopSubEmitters']=function(){this['activeSubSystems']&&(this['activeSubSystems']['forEach'](function(_0x35d714){_0x35d714['stop'](!0x0);}),this['activeSubSystems']=new Array());},_0x2f774b['prototype']['_removeFromRoot']=function(){if(this['_rootParticleSystem']){var _0x11bde9=this['_rootParticleSystem']['activeSubSystems']['indexOf'](this);-0x1!==_0x11bde9&&this['_rootParticleSystem']['activeSubSystems']['splice'](_0x11bde9,0x1),this['_rootParticleSystem']=null;}},_0x2f774b['prototype']['_update']=function(_0x15b7bd){var _0x33fb00,_0x42e1a3=this;if(this['_alive']=this['_particles']['length']>0x0,this['emitter']['position']){var _0x20db19=this['emitter'];this['_emitterWorldMatrix']=_0x20db19['getWorldMatrix']();}else{var _0x9ff172=this['emitter'];this['_emitterWorldMatrix']=_0x74d525['a']['Translation'](_0x9ff172['x'],_0x9ff172['y'],_0x9ff172['z']);}this['updateFunction'](this['_particles']);for(var _0x467bfe,_0x59b0cf=function(){if(_0x35109d['_particles']['length']===_0x35109d['_capacity'])return'break';if(_0x33fb00=_0x35109d['_createParticle'](),_0x35109d['_particles']['push'](_0x33fb00),_0x35109d['targetStopDuration']&&_0x35109d['_lifeTimeGradients']&&_0x35109d['_lifeTimeGradients']['length']>0x0){var _0x52cde4=_0x4a0cf0['a']['Clamp'](_0x35109d['_actualFrame']/_0x35109d['targetStopDuration']);_0x2688df['GetCurrentGradient'](_0x52cde4,_0x35109d['_lifeTimeGradients'],function(_0x3c5d1b,_0x11ad59){var _0x3685e8=_0x3c5d1b,_0x56dc31=_0x11ad59,_0x19653f=_0x3685e8['getFactor'](),_0x132fbb=_0x56dc31['getFactor'](),_0x15cd00=(_0x52cde4-_0x3685e8['gradient'])/(_0x56dc31['gradient']-_0x3685e8['gradient']);_0x33fb00['lifeTime']=_0x4a0cf0['a']['Lerp'](_0x19653f,_0x132fbb,_0x15cd00);});}else _0x33fb00['lifeTime']=_0x4a0cf0['a']['RandomRange'](_0x35109d['minLifeTime'],_0x35109d['maxLifeTime']);var _0x4bb43d=_0x4a0cf0['a']['RandomRange'](_0x35109d['minEmitPower'],_0x35109d['maxEmitPower']);if(_0x35109d['startPositionFunction']?_0x35109d['startPositionFunction'](_0x35109d['_emitterWorldMatrix'],_0x33fb00['position'],_0x33fb00,_0x35109d['isLocal']):_0x35109d['particleEmitterType']['startPositionFunction'](_0x35109d['_emitterWorldMatrix'],_0x33fb00['position'],_0x33fb00,_0x35109d['isLocal']),_0x35109d['isLocal']&&(_0x33fb00['_localPosition']?_0x33fb00['_localPosition']['copyFrom'](_0x33fb00['position']):_0x33fb00['_localPosition']=_0x33fb00['position']['clone'](),_0x74d525['e']['TransformCoordinatesToRef'](_0x33fb00['_localPosition'],_0x35109d['_emitterWorldMatrix'],_0x33fb00['position'])),_0x35109d['startDirectionFunction']?_0x35109d['startDirectionFunction'](_0x35109d['_emitterWorldMatrix'],_0x33fb00['direction'],_0x33fb00,_0x35109d['isLocal']):_0x35109d['particleEmitterType']['startDirectionFunction'](_0x35109d['_emitterWorldMatrix'],_0x33fb00['direction'],_0x33fb00,_0x35109d['isLocal']),0x0===_0x4bb43d?_0x33fb00['_initialDirection']?_0x33fb00['_initialDirection']['copyFrom'](_0x33fb00['direction']):_0x33fb00['_initialDirection']=_0x33fb00['direction']['clone']():_0x33fb00['_initialDirection']=null,_0x33fb00['direction']['scaleInPlace'](_0x4bb43d),_0x35109d['_sizeGradients']&&0x0!==_0x35109d['_sizeGradients']['length']?(_0x33fb00['_currentSizeGradient']=_0x35109d['_sizeGradients'][0x0],_0x33fb00['_currentSize1']=_0x33fb00['_currentSizeGradient']['getFactor'](),_0x33fb00['size']=_0x33fb00['_currentSize1'],_0x35109d['_sizeGradients']['length']>0x1?_0x33fb00['_currentSize2']=_0x35109d['_sizeGradients'][0x1]['getFactor']():_0x33fb00['_currentSize2']=_0x33fb00['_currentSize1']):_0x33fb00['size']=_0x4a0cf0['a']['RandomRange'](_0x35109d['minSize'],_0x35109d['maxSize']),_0x33fb00['scale']['copyFromFloats'](_0x4a0cf0['a']['RandomRange'](_0x35109d['minScaleX'],_0x35109d['maxScaleX']),_0x4a0cf0['a']['RandomRange'](_0x35109d['minScaleY'],_0x35109d['maxScaleY'])),_0x35109d['_startSizeGradients']&&_0x35109d['_startSizeGradients'][0x0]&&_0x35109d['targetStopDuration']){var _0x23468c=_0x35109d['_actualFrame']/_0x35109d['targetStopDuration'];_0x2688df['GetCurrentGradient'](_0x23468c,_0x35109d['_startSizeGradients'],function(_0x14918a,_0x5eea14,_0x425a76){_0x14918a!==_0x42e1a3['_currentStartSizeGradient']&&(_0x42e1a3['_currentStartSize1']=_0x42e1a3['_currentStartSize2'],_0x42e1a3['_currentStartSize2']=_0x5eea14['getFactor'](),_0x42e1a3['_currentStartSizeGradient']=_0x14918a);var _0x56bbff=_0x4a0cf0['a']['Lerp'](_0x42e1a3['_currentStartSize1'],_0x42e1a3['_currentStartSize2'],_0x425a76);_0x33fb00['scale']['scaleInPlace'](_0x56bbff);});}_0x35109d['_angularSpeedGradients']&&0x0!==_0x35109d['_angularSpeedGradients']['length']?(_0x33fb00['_currentAngularSpeedGradient']=_0x35109d['_angularSpeedGradients'][0x0],_0x33fb00['angularSpeed']=_0x33fb00['_currentAngularSpeedGradient']['getFactor'](),_0x33fb00['_currentAngularSpeed1']=_0x33fb00['angularSpeed'],_0x35109d['_angularSpeedGradients']['length']>0x1?_0x33fb00['_currentAngularSpeed2']=_0x35109d['_angularSpeedGradients'][0x1]['getFactor']():_0x33fb00['_currentAngularSpeed2']=_0x33fb00['_currentAngularSpeed1']):_0x33fb00['angularSpeed']=_0x4a0cf0['a']['RandomRange'](_0x35109d['minAngularSpeed'],_0x35109d['maxAngularSpeed']),_0x33fb00['angle']=_0x4a0cf0['a']['RandomRange'](_0x35109d['minInitialRotation'],_0x35109d['maxInitialRotation']),_0x35109d['_velocityGradients']&&_0x35109d['_velocityGradients']['length']>0x0&&(_0x33fb00['_currentVelocityGradient']=_0x35109d['_velocityGradients'][0x0],_0x33fb00['_currentVelocity1']=_0x33fb00['_currentVelocityGradient']['getFactor'](),_0x35109d['_velocityGradients']['length']>0x1?_0x33fb00['_currentVelocity2']=_0x35109d['_velocityGradients'][0x1]['getFactor']():_0x33fb00['_currentVelocity2']=_0x33fb00['_currentVelocity1']),_0x35109d['_limitVelocityGradients']&&_0x35109d['_limitVelocityGradients']['length']>0x0&&(_0x33fb00['_currentLimitVelocityGradient']=_0x35109d['_limitVelocityGradients'][0x0],_0x33fb00['_currentLimitVelocity1']=_0x33fb00['_currentLimitVelocityGradient']['getFactor'](),_0x35109d['_limitVelocityGradients']['length']>0x1?_0x33fb00['_currentLimitVelocity2']=_0x35109d['_limitVelocityGradients'][0x1]['getFactor']():_0x33fb00['_currentLimitVelocity2']=_0x33fb00['_currentLimitVelocity1']),_0x35109d['_dragGradients']&&_0x35109d['_dragGradients']['length']>0x0&&(_0x33fb00['_currentDragGradient']=_0x35109d['_dragGradients'][0x0],_0x33fb00['_currentDrag1']=_0x33fb00['_currentDragGradient']['getFactor'](),_0x35109d['_dragGradients']['length']>0x1?_0x33fb00['_currentDrag2']=_0x35109d['_dragGradients'][0x1]['getFactor']():_0x33fb00['_currentDrag2']=_0x33fb00['_currentDrag1']),_0x35109d['_colorGradients']&&0x0!==_0x35109d['_colorGradients']['length']?(_0x33fb00['_currentColorGradient']=_0x35109d['_colorGradients'][0x0],_0x33fb00['_currentColorGradient']['getColorToRef'](_0x33fb00['color']),_0x33fb00['_currentColor1']['copyFrom'](_0x33fb00['color']),_0x35109d['_colorGradients']['length']>0x1?_0x35109d['_colorGradients'][0x1]['getColorToRef'](_0x33fb00['_currentColor2']):_0x33fb00['_currentColor2']['copyFrom'](_0x33fb00['color'])):(_0x467bfe=_0x4a0cf0['a']['RandomRange'](0x0,0x1),_0x39310d['b']['LerpToRef'](_0x35109d['color1'],_0x35109d['color2'],_0x467bfe,_0x33fb00['color']),_0x35109d['colorDead']['subtractToRef'](_0x33fb00['color'],_0x35109d['_colorDiff']),_0x35109d['_colorDiff']['scaleToRef'](0x1/_0x33fb00['lifeTime'],_0x33fb00['colorStep'])),_0x35109d['_isAnimationSheetEnabled']&&(_0x33fb00['_initialStartSpriteCellID']=_0x35109d['startSpriteCellID'],_0x33fb00['_initialEndSpriteCellID']=_0x35109d['endSpriteCellID']),_0x33fb00['direction']['addInPlace'](_0x35109d['_inheritedVelocityOffset']),_0x35109d['_useRampGradients']&&(_0x33fb00['remapData']=new _0x74d525['f'](0x0,0x1,0x0,0x1)),_0x35109d['noiseTexture']&&(_0x33fb00['_randomNoiseCoordinates1']?(_0x33fb00['_randomNoiseCoordinates1']['copyFromFloats'](Math['random'](),Math['random'](),Math['random']()),_0x33fb00['_randomNoiseCoordinates2']['copyFromFloats'](Math['random'](),Math['random'](),Math['random']())):(_0x33fb00['_randomNoiseCoordinates1']=new _0x74d525['e'](Math['random'](),Math['random'](),Math['random']()),_0x33fb00['_randomNoiseCoordinates2']=new _0x74d525['e'](Math['random'](),Math['random'](),Math['random']()))),_0x33fb00['_inheritParticleInfoToSubEmitters']();},_0x35109d=this,_0x2b239d=0x0;_0x2b239d<_0x15b7bd;_0x2b239d++){if('break'===_0x59b0cf())break;}},_0x2f774b['_GetAttributeNamesOrOptions']=function(_0x4680c8,_0x1de2e1,_0xf78a4b){void 0x0===_0x4680c8&&(_0x4680c8=!0x1),void 0x0===_0x1de2e1&&(_0x1de2e1=!0x1),void 0x0===_0xf78a4b&&(_0xf78a4b=!0x1);var _0xf2039d=[_0x212fbd['b']['PositionKind'],_0x212fbd['b']['ColorKind'],'angle','offset','size'];return _0x4680c8&&_0xf2039d['push']('cellIndex'),_0x1de2e1||_0xf2039d['push']('direction'),_0xf78a4b&&_0xf2039d['push']('remapData'),_0xf2039d;},_0x2f774b['_GetEffectCreationOptions']=function(_0x5475c6){void 0x0===_0x5475c6&&(_0x5475c6=!0x1);var _0x271457=['invView','view','projection','vClipPlane','vClipPlane2','vClipPlane3','vClipPlane4','vClipPlane5','vClipPlane6','textureMask','translationPivot','eyePosition'];return _0x5475c6&&_0x271457['push']('particlesInfos'),_0x271457;},_0x2f774b['prototype']['fillDefines']=function(_0x3dbe4e,_0x20b291){if(this['_scene']&&(this['_scene']['clipPlane']&&_0x3dbe4e['push']('#define\x20CLIPPLANE'),this['_scene']['clipPlane2']&&_0x3dbe4e['push']('#define\x20CLIPPLANE2'),this['_scene']['clipPlane3']&&_0x3dbe4e['push']('#define\x20CLIPPLANE3'),this['_scene']['clipPlane4']&&_0x3dbe4e['push']('#define\x20CLIPPLANE4'),this['_scene']['clipPlane5']&&_0x3dbe4e['push']('#define\x20CLIPPLANE5'),this['_scene']['clipPlane6']&&_0x3dbe4e['push']('#define\x20CLIPPLANE6')),this['_isAnimationSheetEnabled']&&_0x3dbe4e['push']('#define\x20ANIMATESHEET'),_0x20b291===_0x2f774b['BLENDMODE_MULTIPLY']&&_0x3dbe4e['push']('#define\x20BLENDMULTIPLYMODE'),this['_useRampGradients']&&_0x3dbe4e['push']('#define\x20RAMPGRADIENT'),this['_isBillboardBased'])switch(_0x3dbe4e['push']('#define\x20BILLBOARD'),this['billboardMode']){case _0x2f774b['BILLBOARDMODE_Y']:_0x3dbe4e['push']('#define\x20BILLBOARDY');break;case _0x2f774b['BILLBOARDMODE_STRETCHED']:_0x3dbe4e['push']('#define\x20BILLBOARDSTRETCHED');break;case _0x2f774b['BILLBOARDMODE_ALL']:_0x3dbe4e['push']('#define\x20BILLBOARDMODE_ALL');}this['_imageProcessingConfiguration']&&(this['_imageProcessingConfiguration']['prepareDefines'](this['_imageProcessingConfigurationDefines']),_0x3dbe4e['push'](this['_imageProcessingConfigurationDefines']['toString']()));},_0x2f774b['prototype']['fillUniformsAttributesAndSamplerNames']=function(_0x3db0a9,_0x2c0e6f,_0x2c360f){_0x2c0e6f['push']['apply'](_0x2c0e6f,_0x2f774b['_GetAttributeNamesOrOptions'](this['_isAnimationSheetEnabled'],this['_isBillboardBased']&&this['billboardMode']!==_0x2f774b['BILLBOARDMODE_STRETCHED'],this['_useRampGradients'])),_0x3db0a9['push']['apply'](_0x3db0a9,_0x2f774b['_GetEffectCreationOptions'](this['_isAnimationSheetEnabled'])),_0x2c360f['push']('diffuseSampler','rampSampler'),this['_imageProcessingConfiguration']&&(_0x3f08d6['a']['PrepareUniforms'](_0x3db0a9,this['_imageProcessingConfigurationDefines']),_0x3f08d6['a']['PrepareSamplers'](_0x2c360f,this['_imageProcessingConfigurationDefines']));},_0x2f774b['prototype']['_getEffect']=function(_0x2ec804){var _0x1ff9ef=this['getCustomEffect'](_0x2ec804);if(_0x1ff9ef)return _0x1ff9ef;var _0x4e8d80=[];this['fillDefines'](_0x4e8d80,_0x2ec804);var _0x4c2e37=_0x4e8d80['join']('\x0a');if(this['_cachedDefines']!==_0x4c2e37){this['_cachedDefines']=_0x4c2e37;var _0x199ac7=[],_0x12f77b=[],_0x25db24=[];this['fillUniformsAttributesAndSamplerNames'](_0x12f77b,_0x199ac7,_0x25db24),this['_effect']=this['_engine']['createEffect']('particles',_0x199ac7,_0x12f77b,_0x25db24,_0x4c2e37);}return this['_effect'];},_0x2f774b['prototype']['animate']=function(_0x28e798){var _0x402120,_0xde633a=this;if(void 0x0===_0x28e798&&(_0x28e798=!0x1),this['_started']){if(!_0x28e798&&this['_scene']){if(!this['isReady']())return;if(this['_currentRenderId']===this['_scene']['getFrameId']())return;this['_currentRenderId']=this['_scene']['getFrameId']();}var _0x141d74;if(this['_scaledUpdateSpeed']=this['updateSpeed']*(_0x28e798?this['preWarmStepOffset']:(null===(_0x402120=this['_scene'])||void 0x0===_0x402120?void 0x0:_0x402120['getAnimationRatio']())||0x1),this['manualEmitCount']>-0x1)_0x141d74=this['manualEmitCount'],this['_newPartsExcess']=0x0,this['manualEmitCount']=0x0;else{var _0x43b62f=this['emitRate'];if(this['_emitRateGradients']&&this['_emitRateGradients']['length']>0x0&&this['targetStopDuration']){var _0x497359=this['_actualFrame']/this['targetStopDuration'];_0x2688df['GetCurrentGradient'](_0x497359,this['_emitRateGradients'],function(_0x284286,_0x410fe3,_0x3809a4){_0x284286!==_0xde633a['_currentEmitRateGradient']&&(_0xde633a['_currentEmitRate1']=_0xde633a['_currentEmitRate2'],_0xde633a['_currentEmitRate2']=_0x410fe3['getFactor'](),_0xde633a['_currentEmitRateGradient']=_0x284286),_0x43b62f=_0x4a0cf0['a']['Lerp'](_0xde633a['_currentEmitRate1'],_0xde633a['_currentEmitRate2'],_0x3809a4);});}_0x141d74=_0x43b62f*this['_scaledUpdateSpeed']>>0x0,this['_newPartsExcess']+=_0x43b62f*this['_scaledUpdateSpeed']-_0x141d74;}if(this['_newPartsExcess']>0x1&&(_0x141d74+=this['_newPartsExcess']>>0x0,this['_newPartsExcess']-=this['_newPartsExcess']>>0x0),this['_alive']=!0x1,this['_stopped']?_0x141d74=0x0:(this['_actualFrame']+=this['_scaledUpdateSpeed'],this['targetStopDuration']&&this['_actualFrame']>=this['targetStopDuration']&&this['stop']()),this['_update'](_0x141d74),this['_stopped']&&(this['_alive']||(this['_started']=!0x1,this['onAnimationEnd']&&this['onAnimationEnd'](),this['disposeOnStop']&&this['_scene']&&this['_scene']['_toBeDisposed']['push'](this))),!_0x28e798){for(var _0x40b649=0x0,_0x2e699a=0x0;_0x2e699a=0x0&&(_0x3c065f['invertToRef'](_0x74d525['c']['Matrix'][0x0]),_0x778e3d['setMatrix']('invView',_0x74d525['c']['Matrix'][0x0])),void 0x0!==this['_vertexArrayObject']?(this['_vertexArrayObject']||(this['_vertexArrayObject']=this['_engine']['recordVertexArrayObject'](this['_vertexBuffers'],this['_indexBuffer'],_0x778e3d)),this['_engine']['bindVertexArrayObject'](this['_vertexArrayObject'],this['_indexBuffer'])):_0x2475ea['bindBuffers'](this['_vertexBuffers'],this['_indexBuffer'],_0x778e3d),this['_imageProcessingConfiguration']&&!this['_imageProcessingConfiguration']['applyByPostProcess']&&this['_imageProcessingConfiguration']['bind'](_0x778e3d),_0x2cad4c){case _0x2f774b['BLENDMODE_ADD']:_0x2475ea['setAlphaMode'](_0x2103ba['a']['ALPHA_ADD']);break;case _0x2f774b['BLENDMODE_ONEONE']:_0x2475ea['setAlphaMode'](_0x2103ba['a']['ALPHA_ONEONE']);break;case _0x2f774b['BLENDMODE_STANDARD']:_0x2475ea['setAlphaMode'](_0x2103ba['a']['ALPHA_COMBINE']);break;case _0x2f774b['BLENDMODE_MULTIPLY']:_0x2475ea['setAlphaMode'](_0x2103ba['a']['ALPHA_MULTIPLY']);}return this['_onBeforeDrawParticlesObservable']&&this['_onBeforeDrawParticlesObservable']['notifyObservers'](_0x778e3d),this['_useInstancing']?_0x2475ea['drawArraysType'](_0x2103ba['a']['MATERIAL_TriangleFanDrawMode'],0x0,0x4,this['_particles']['length']):_0x2475ea['drawElementsType'](_0x2103ba['a']['MATERIAL_TriangleFillMode'],0x0,0x6*this['_particles']['length']),this['_particles']['length'];},_0x2f774b['prototype']['render']=function(){if(!this['isReady']()||!this['_particles']['length'])return 0x0;var _0x1e5aae=this['_engine'];_0x1e5aae['setState']&&(_0x1e5aae['setState'](!0x1),this['forceDepthWrite']&&_0x1e5aae['setDepthWrite'](!0x0));var _0x1b8686=0x0;return _0x1b8686=this['blendMode']===_0x2f774b['BLENDMODE_MULTIPLYADD']?this['_render'](_0x2f774b['BLENDMODE_MULTIPLY'])+this['_render'](_0x2f774b['BLENDMODE_ADD']):this['_render'](this['blendMode']),this['_engine']['unbindInstanceAttributes'](),this['_engine']['setAlphaMode'](_0x2103ba['a']['ALPHA_DISABLE']),_0x1b8686;},_0x2f774b['prototype']['dispose']=function(_0x2f18ba){if(void 0x0===_0x2f18ba&&(_0x2f18ba=!0x0),this['_vertexBuffer']&&(this['_vertexBuffer']['dispose'](),this['_vertexBuffer']=null),this['_spriteBuffer']&&(this['_spriteBuffer']['dispose'](),this['_spriteBuffer']=null),this['_indexBuffer']&&(this['_engine']['_releaseBuffer'](this['_indexBuffer']),this['_indexBuffer']=null),this['_vertexArrayObject']&&(this['_engine']['releaseVertexArrayObject'](this['_vertexArrayObject']),this['_vertexArrayObject']=null),_0x2f18ba&&this['particleTexture']&&(this['particleTexture']['dispose'](),this['particleTexture']=null),_0x2f18ba&&this['noiseTexture']&&(this['noiseTexture']['dispose'](),this['noiseTexture']=null),this['_rampGradientsTexture']&&(this['_rampGradientsTexture']['dispose'](),this['_rampGradientsTexture']=null),this['_removeFromRoot'](),this['_subEmitters']&&this['_subEmitters']['length']){for(var _0x4ae705=0x0;_0x4ae705-0x1&&this['_scene']['particleSystems']['splice'](_0x4ae705,0x1),this['_scene']['_activeParticleSystems']['dispose']()),(this['onDisposeObservable']['notifyObservers'](this),this['onDisposeObservable']['clear'](),this['onStoppedObservable']['clear'](),this['reset']());},_0x2f774b['prototype']['clone']=function(_0x174653,_0x105c21){var _0x212636=Object(_0x18e13d['a'])({},this['_customEffect']),_0x132da6=null,_0x87201e=this['_engine'];if(_0x87201e['createEffectForParticles']&&null!=this['customShader']){var _0x539829=(_0x132da6=this['customShader'])['shaderOptions']['defines']['length']>0x0?_0x132da6['shaderOptions']['defines']['join']('\x0a'):'';_0x212636[0x0]=_0x87201e['createEffectForParticles'](_0x132da6['shaderPath']['fragmentElement'],_0x132da6['shaderOptions']['uniforms'],_0x132da6['shaderOptions']['samplers'],_0x539829);}var _0x22cfd8=this['serialize'](),_0x3e33bb=_0x2f774b['Parse'](_0x22cfd8,this['_scene']||this['_engine'],'');return _0x3e33bb['name']=_0x174653,_0x3e33bb['customShader']=_0x132da6,_0x3e33bb['_customEffect']=_0x212636,void 0x0===_0x105c21&&(_0x105c21=this['emitter']),this['noiseTexture']&&(_0x3e33bb['noiseTexture']=this['noiseTexture']['clone']()),_0x3e33bb['emitter']=_0x105c21,this['preventAutoStart']||_0x3e33bb['start'](),_0x3e33bb;},_0x2f774b['prototype']['serialize']=function(_0x18bd5f){void 0x0===_0x18bd5f&&(_0x18bd5f=!0x1);var _0x32e2a7={};if(_0x2f774b['_Serialize'](_0x32e2a7,this,_0x18bd5f),_0x32e2a7['textureMask']=this['textureMask']['asArray'](),_0x32e2a7['customShader']=this['customShader'],_0x32e2a7['preventAutoStart']=this['preventAutoStart'],this['subEmitters']){_0x32e2a7['subEmitters']=[],this['_subEmitters']||this['_prepareSubEmitterInternalArray']();for(var _0xbd9f81=0x0,_0x4734c0=this['_subEmitters'];_0xbd9f81<_0x4734c0['length'];_0xbd9f81++){for(var _0x135371=[],_0x31836d=0x0,_0x4b26dc=_0x4734c0[_0xbd9f81];_0x31836d<_0x4b26dc['length'];_0x31836d++){var _0x158eee=_0x4b26dc[_0x31836d];_0x135371['push'](_0x158eee['serialize']());}_0x32e2a7['subEmitters']['push'](_0x135371);}}return _0x32e2a7;},_0x2f774b['_Serialize']=function(_0x1710dd,_0x510bb4,_0x4a7c7e){if(_0x1710dd['name']=_0x510bb4['name'],_0x1710dd['id']=_0x510bb4['id'],_0x1710dd['capacity']=_0x510bb4['getCapacity'](),_0x510bb4['emitter']['position']){var _0x24b825=_0x510bb4['emitter'];_0x1710dd['emitterId']=_0x24b825['id'];}else{var _0x3082dd=_0x510bb4['emitter'];_0x1710dd['emitter']=_0x3082dd['asArray']();}_0x510bb4['particleEmitterType']&&(_0x1710dd['particleEmitterType']=_0x510bb4['particleEmitterType']['serialize']()),_0x510bb4['particleTexture']&&(_0x4a7c7e?_0x1710dd['texture']=_0x510bb4['particleTexture']['serialize']():(_0x1710dd['textureName']=_0x510bb4['particleTexture']['name'],_0x1710dd['invertY']=!!_0x510bb4['particleTexture']['_invertY'])),_0x1710dd['isLocal']=_0x510bb4['isLocal'],_0x495d06['a']['AppendSerializedAnimations'](_0x510bb4,_0x1710dd),_0x1710dd['beginAnimationOnStart']=_0x510bb4['beginAnimationOnStart'],_0x1710dd['beginAnimationFrom']=_0x510bb4['beginAnimationFrom'],_0x1710dd['beginAnimationTo']=_0x510bb4['beginAnimationTo'],_0x1710dd['beginAnimationLoop']=_0x510bb4['beginAnimationLoop'],_0x1710dd['startDelay']=_0x510bb4['startDelay'],_0x1710dd['renderingGroupId']=_0x510bb4['renderingGroupId'],_0x1710dd['isBillboardBased']=_0x510bb4['isBillboardBased'],_0x1710dd['billboardMode']=_0x510bb4['billboardMode'],_0x1710dd['minAngularSpeed']=_0x510bb4['minAngularSpeed'],_0x1710dd['maxAngularSpeed']=_0x510bb4['maxAngularSpeed'],_0x1710dd['minSize']=_0x510bb4['minSize'],_0x1710dd['maxSize']=_0x510bb4['maxSize'],_0x1710dd['minScaleX']=_0x510bb4['minScaleX'],_0x1710dd['maxScaleX']=_0x510bb4['maxScaleX'],_0x1710dd['minScaleY']=_0x510bb4['minScaleY'],_0x1710dd['maxScaleY']=_0x510bb4['maxScaleY'],_0x1710dd['minEmitPower']=_0x510bb4['minEmitPower'],_0x1710dd['maxEmitPower']=_0x510bb4['maxEmitPower'],_0x1710dd['minLifeTime']=_0x510bb4['minLifeTime'],_0x1710dd['maxLifeTime']=_0x510bb4['maxLifeTime'],_0x1710dd['emitRate']=_0x510bb4['emitRate'],_0x1710dd['gravity']=_0x510bb4['gravity']['asArray'](),_0x1710dd['noiseStrength']=_0x510bb4['noiseStrength']['asArray'](),_0x1710dd['color1']=_0x510bb4['color1']['asArray'](),_0x1710dd['color2']=_0x510bb4['color2']['asArray'](),_0x1710dd['colorDead']=_0x510bb4['colorDead']['asArray'](),_0x1710dd['updateSpeed']=_0x510bb4['updateSpeed'],_0x1710dd['targetStopDuration']=_0x510bb4['targetStopDuration'],_0x1710dd['blendMode']=_0x510bb4['blendMode'],_0x1710dd['preWarmCycles']=_0x510bb4['preWarmCycles'],_0x1710dd['preWarmStepOffset']=_0x510bb4['preWarmStepOffset'],_0x1710dd['minInitialRotation']=_0x510bb4['minInitialRotation'],_0x1710dd['maxInitialRotation']=_0x510bb4['maxInitialRotation'],_0x1710dd['startSpriteCellID']=_0x510bb4['startSpriteCellID'],_0x1710dd['endSpriteCellID']=_0x510bb4['endSpriteCellID'],_0x1710dd['spriteCellChangeSpeed']=_0x510bb4['spriteCellChangeSpeed'],_0x1710dd['spriteCellWidth']=_0x510bb4['spriteCellWidth'],_0x1710dd['spriteCellHeight']=_0x510bb4['spriteCellHeight'],_0x1710dd['spriteRandomStartCell']=_0x510bb4['spriteRandomStartCell'],_0x1710dd['isAnimationSheetEnabled']=_0x510bb4['isAnimationSheetEnabled'];var _0x3caaf7=_0x510bb4['getColorGradients']();if(_0x3caaf7){_0x1710dd['colorGradients']=[];for(var _0x20d95a=0x0,_0x303003=_0x3caaf7;_0x20d95a<_0x303003['length'];_0x20d95a++){var _0x30b663=_0x303003[_0x20d95a],_0x250cb3={'gradient':_0x30b663['gradient'],'color1':_0x30b663['color1']['asArray']()};_0x30b663['color2']?_0x250cb3['color2']=_0x30b663['color2']['asArray']():_0x250cb3['color2']=_0x30b663['color1']['asArray'](),_0x1710dd['colorGradients']['push'](_0x250cb3);}}var _0x1bc5e9=_0x510bb4['getRampGradients']();if(_0x1bc5e9){_0x1710dd['rampGradients']=[];for(var _0x397054=0x0,_0x23298b=_0x1bc5e9;_0x397054<_0x23298b['length'];_0x397054++){var _0x3505ab=_0x23298b[_0x397054];_0x250cb3={'gradient':_0x3505ab['gradient'],'color':_0x3505ab['color']['asArray']()},_0x1710dd['rampGradients']['push'](_0x250cb3);}_0x1710dd['useRampGradients']=_0x510bb4['useRampGradients'];}var _0x91c4bc=_0x510bb4['getColorRemapGradients']();if(_0x91c4bc){_0x1710dd['colorRemapGradients']=[];for(var _0x180bfe=0x0,_0x30f09d=_0x91c4bc;_0x180bfe<_0x30f09d['length'];_0x180bfe++){var _0x13ed0b=_0x30f09d[_0x180bfe];_0x250cb3={'gradient':_0x13ed0b['gradient'],'factor1':_0x13ed0b['factor1']},(void 0x0!==_0x13ed0b['factor2']?_0x250cb3['factor2']=_0x13ed0b['factor2']:_0x250cb3['factor2']=_0x13ed0b['factor1'],_0x1710dd['colorRemapGradients']['push'](_0x250cb3));}}var _0xa29ca4=_0x510bb4['getAlphaRemapGradients']();if(_0xa29ca4){_0x1710dd['alphaRemapGradients']=[];for(var _0x196c84=0x0,_0xc76d67=_0xa29ca4;_0x196c84<_0xc76d67['length'];_0x196c84++){var _0x5a95e9=_0xc76d67[_0x196c84];_0x250cb3={'gradient':_0x5a95e9['gradient'],'factor1':_0x5a95e9['factor1']},(void 0x0!==_0x5a95e9['factor2']?_0x250cb3['factor2']=_0x5a95e9['factor2']:_0x250cb3['factor2']=_0x5a95e9['factor1'],_0x1710dd['alphaRemapGradients']['push'](_0x250cb3));}}var _0x336e92=_0x510bb4['getSizeGradients']();if(_0x336e92){_0x1710dd['sizeGradients']=[];for(var _0xc5dd79=0x0,_0x15421a=_0x336e92;_0xc5dd79<_0x15421a['length'];_0xc5dd79++){var _0x116b5c=_0x15421a[_0xc5dd79];_0x250cb3={'gradient':_0x116b5c['gradient'],'factor1':_0x116b5c['factor1']},(void 0x0!==_0x116b5c['factor2']?_0x250cb3['factor2']=_0x116b5c['factor2']:_0x250cb3['factor2']=_0x116b5c['factor1'],_0x1710dd['sizeGradients']['push'](_0x250cb3));}}var _0x5d637d=_0x510bb4['getAngularSpeedGradients']();if(_0x5d637d){_0x1710dd['angularSpeedGradients']=[];for(var _0x46026e=0x0,_0x344864=_0x5d637d;_0x46026e<_0x344864['length'];_0x46026e++){var _0x4611cc=_0x344864[_0x46026e];_0x250cb3={'gradient':_0x4611cc['gradient'],'factor1':_0x4611cc['factor1']},(void 0x0!==_0x4611cc['factor2']?_0x250cb3['factor2']=_0x4611cc['factor2']:_0x250cb3['factor2']=_0x4611cc['factor1'],_0x1710dd['angularSpeedGradients']['push'](_0x250cb3));}}var _0x2c6173=_0x510bb4['getVelocityGradients']();if(_0x2c6173){_0x1710dd['velocityGradients']=[];for(var _0x4d0ed1=0x0,_0x5c5a67=_0x2c6173;_0x4d0ed1<_0x5c5a67['length'];_0x4d0ed1++){var _0x11c1a7=_0x5c5a67[_0x4d0ed1];_0x250cb3={'gradient':_0x11c1a7['gradient'],'factor1':_0x11c1a7['factor1']},(void 0x0!==_0x11c1a7['factor2']?_0x250cb3['factor2']=_0x11c1a7['factor2']:_0x250cb3['factor2']=_0x11c1a7['factor1'],_0x1710dd['velocityGradients']['push'](_0x250cb3));}}var _0x3f545a=_0x510bb4['getDragGradients']();if(_0x3f545a){_0x1710dd['dragGradients']=[];for(var _0x568973=0x0,_0x359d45=_0x3f545a;_0x568973<_0x359d45['length'];_0x568973++){var _0x2aebf8=_0x359d45[_0x568973];_0x250cb3={'gradient':_0x2aebf8['gradient'],'factor1':_0x2aebf8['factor1']},(void 0x0!==_0x2aebf8['factor2']?_0x250cb3['factor2']=_0x2aebf8['factor2']:_0x250cb3['factor2']=_0x2aebf8['factor1'],_0x1710dd['dragGradients']['push'](_0x250cb3));}}var _0x180987=_0x510bb4['getEmitRateGradients']();if(_0x180987){_0x1710dd['emitRateGradients']=[];for(var _0x3e87ff=0x0,_0x2748f2=_0x180987;_0x3e87ff<_0x2748f2['length'];_0x3e87ff++){var _0x23b5bd=_0x2748f2[_0x3e87ff];_0x250cb3={'gradient':_0x23b5bd['gradient'],'factor1':_0x23b5bd['factor1']},(void 0x0!==_0x23b5bd['factor2']?_0x250cb3['factor2']=_0x23b5bd['factor2']:_0x250cb3['factor2']=_0x23b5bd['factor1'],_0x1710dd['emitRateGradients']['push'](_0x250cb3));}}var _0x24450d=_0x510bb4['getStartSizeGradients']();if(_0x24450d){_0x1710dd['startSizeGradients']=[];for(var _0xff4b39=0x0,_0xa4e008=_0x24450d;_0xff4b39<_0xa4e008['length'];_0xff4b39++){var _0x503fa2=_0xa4e008[_0xff4b39];_0x250cb3={'gradient':_0x503fa2['gradient'],'factor1':_0x503fa2['factor1']},(void 0x0!==_0x503fa2['factor2']?_0x250cb3['factor2']=_0x503fa2['factor2']:_0x250cb3['factor2']=_0x503fa2['factor1'],_0x1710dd['startSizeGradients']['push'](_0x250cb3));}}var _0x2da842=_0x510bb4['getLifeTimeGradients']();if(_0x2da842){_0x1710dd['lifeTimeGradients']=[];for(var _0x1fe046=0x0,_0x242e5e=_0x2da842;_0x1fe046<_0x242e5e['length'];_0x1fe046++){var _0x300972=_0x242e5e[_0x1fe046];_0x250cb3={'gradient':_0x300972['gradient'],'factor1':_0x300972['factor1']},(void 0x0!==_0x300972['factor2']?_0x250cb3['factor2']=_0x300972['factor2']:_0x250cb3['factor2']=_0x300972['factor1'],_0x1710dd['lifeTimeGradients']['push'](_0x250cb3));}}var _0x114836=_0x510bb4['getLimitVelocityGradients']();if(_0x114836){_0x1710dd['limitVelocityGradients']=[];for(var _0x3085c0=0x0,_0x5cad44=_0x114836;_0x3085c0<_0x5cad44['length'];_0x3085c0++){var _0x2f20d6=_0x5cad44[_0x3085c0];_0x250cb3={'gradient':_0x2f20d6['gradient'],'factor1':_0x2f20d6['factor1']},(void 0x0!==_0x2f20d6['factor2']?_0x250cb3['factor2']=_0x2f20d6['factor2']:_0x250cb3['factor2']=_0x2f20d6['factor1'],_0x1710dd['limitVelocityGradients']['push'](_0x250cb3));}_0x1710dd['limitVelocityDamping']=_0x510bb4['limitVelocityDamping'];}_0x510bb4['noiseTexture']&&(_0x1710dd['noiseTexture']=_0x510bb4['noiseTexture']['serialize']());},_0x2f774b['_Parse']=function(_0x4b43ce,_0x2c2e69,_0x2a9a13,_0x869688){var _0x357f1d;_0x357f1d=_0x2a9a13 instanceof _0x26966b['a']?null:_0x2a9a13;var _0x445e83,_0xc6ec6d=_0x3cd573['a']['GetClass']('BABYLON.Texture');if(_0xc6ec6d&&_0x357f1d&&(_0x4b43ce['texture']?_0x2c2e69['particleTexture']=_0xc6ec6d['Parse'](_0x4b43ce['texture'],_0x357f1d,_0x869688):_0x4b43ce['textureName']&&(_0x2c2e69['particleTexture']=new _0xc6ec6d(_0x869688+_0x4b43ce['textureName'],_0x357f1d,!0x1,void 0x0===_0x4b43ce['invertY']||_0x4b43ce['invertY']),_0x2c2e69['particleTexture']['name']=_0x4b43ce['textureName'])),_0x4b43ce['emitterId']||0x0===_0x4b43ce['emitterId']||void 0x0!==_0x4b43ce['emitter']?_0x4b43ce['emitterId']&&_0x357f1d?_0x2c2e69['emitter']=_0x357f1d['getLastMeshByID'](_0x4b43ce['emitterId']):_0x2c2e69['emitter']=_0x74d525['e']['FromArray'](_0x4b43ce['emitter']):_0x2c2e69['emitter']=_0x74d525['e']['Zero'](),_0x2c2e69['isLocal']=!!_0x4b43ce['isLocal'],void 0x0!==_0x4b43ce['renderingGroupId']&&(_0x2c2e69['renderingGroupId']=_0x4b43ce['renderingGroupId']),void 0x0!==_0x4b43ce['isBillboardBased']&&(_0x2c2e69['isBillboardBased']=_0x4b43ce['isBillboardBased']),void 0x0!==_0x4b43ce['billboardMode']&&(_0x2c2e69['billboardMode']=_0x4b43ce['billboardMode']),_0x4b43ce['animations']){for(var _0x5a64f8=0x0;_0x5a64f8<_0x4b43ce['animations']['length'];_0x5a64f8++){var _0x57225e=_0x4b43ce['animations'][_0x5a64f8],_0x2b63a7=_0x3cd573['a']['GetClass']('BABYLON.Animation');_0x2b63a7&&_0x2c2e69['animations']['push'](_0x2b63a7['Parse'](_0x57225e));}_0x2c2e69['beginAnimationOnStart']=_0x4b43ce['beginAnimationOnStart'],_0x2c2e69['beginAnimationFrom']=_0x4b43ce['beginAnimationFrom'],_0x2c2e69['beginAnimationTo']=_0x4b43ce['beginAnimationTo'],_0x2c2e69['beginAnimationLoop']=_0x4b43ce['beginAnimationLoop'];}if(_0x4b43ce['autoAnimate']&&_0x357f1d&&_0x357f1d['beginAnimation'](_0x2c2e69,_0x4b43ce['autoAnimateFrom'],_0x4b43ce['autoAnimateTo'],_0x4b43ce['autoAnimateLoop'],_0x4b43ce['autoAnimateSpeed']||0x1),_0x2c2e69['startDelay']=0x0|_0x4b43ce['startDelay'],_0x2c2e69['minAngularSpeed']=_0x4b43ce['minAngularSpeed'],_0x2c2e69['maxAngularSpeed']=_0x4b43ce['maxAngularSpeed'],_0x2c2e69['minSize']=_0x4b43ce['minSize'],_0x2c2e69['maxSize']=_0x4b43ce['maxSize'],_0x4b43ce['minScaleX']&&(_0x2c2e69['minScaleX']=_0x4b43ce['minScaleX'],_0x2c2e69['maxScaleX']=_0x4b43ce['maxScaleX'],_0x2c2e69['minScaleY']=_0x4b43ce['minScaleY'],_0x2c2e69['maxScaleY']=_0x4b43ce['maxScaleY']),void 0x0!==_0x4b43ce['preWarmCycles']&&(_0x2c2e69['preWarmCycles']=_0x4b43ce['preWarmCycles'],_0x2c2e69['preWarmStepOffset']=_0x4b43ce['preWarmStepOffset']),void 0x0!==_0x4b43ce['minInitialRotation']&&(_0x2c2e69['minInitialRotation']=_0x4b43ce['minInitialRotation'],_0x2c2e69['maxInitialRotation']=_0x4b43ce['maxInitialRotation']),_0x2c2e69['minLifeTime']=_0x4b43ce['minLifeTime'],_0x2c2e69['maxLifeTime']=_0x4b43ce['maxLifeTime'],_0x2c2e69['minEmitPower']=_0x4b43ce['minEmitPower'],_0x2c2e69['maxEmitPower']=_0x4b43ce['maxEmitPower'],_0x2c2e69['emitRate']=_0x4b43ce['emitRate'],_0x2c2e69['gravity']=_0x74d525['e']['FromArray'](_0x4b43ce['gravity']),_0x4b43ce['noiseStrength']&&(_0x2c2e69['noiseStrength']=_0x74d525['e']['FromArray'](_0x4b43ce['noiseStrength'])),_0x2c2e69['color1']=_0x39310d['b']['FromArray'](_0x4b43ce['color1']),_0x2c2e69['color2']=_0x39310d['b']['FromArray'](_0x4b43ce['color2']),_0x2c2e69['colorDead']=_0x39310d['b']['FromArray'](_0x4b43ce['colorDead']),_0x2c2e69['updateSpeed']=_0x4b43ce['updateSpeed'],_0x2c2e69['targetStopDuration']=_0x4b43ce['targetStopDuration'],_0x2c2e69['blendMode']=_0x4b43ce['blendMode'],_0x4b43ce['colorGradients'])for(var _0x2d2dbf=0x0,_0x42bbf7=_0x4b43ce['colorGradients'];_0x2d2dbf<_0x42bbf7['length'];_0x2d2dbf++){var _0x289a9d=_0x42bbf7[_0x2d2dbf];_0x2c2e69['addColorGradient'](_0x289a9d['gradient'],_0x39310d['b']['FromArray'](_0x289a9d['color1']),_0x289a9d['color2']?_0x39310d['b']['FromArray'](_0x289a9d['color2']):void 0x0);}if(_0x4b43ce['rampGradients']){for(var _0xe46947=0x0,_0x4afb1d=_0x4b43ce['rampGradients'];_0xe46947<_0x4afb1d['length'];_0xe46947++){var _0x1615c7=_0x4afb1d[_0xe46947];_0x2c2e69['addRampGradient'](_0x1615c7['gradient'],_0x39310d['a']['FromArray'](_0x1615c7['color']));}_0x2c2e69['useRampGradients']=_0x4b43ce['useRampGradients'];}if(_0x4b43ce['colorRemapGradients'])for(var _0x1cff83=0x0,_0x5c546a=_0x4b43ce['colorRemapGradients'];_0x1cff83<_0x5c546a['length'];_0x1cff83++){var _0xe4edd0=_0x5c546a[_0x1cff83];_0x2c2e69['addColorRemapGradient'](_0xe4edd0['gradient'],void 0x0!==_0xe4edd0['factor1']?_0xe4edd0['factor1']:_0xe4edd0['factor'],_0xe4edd0['factor2']);}if(_0x4b43ce['alphaRemapGradients'])for(var _0x644861=0x0,_0x4b9151=_0x4b43ce['alphaRemapGradients'];_0x644861<_0x4b9151['length'];_0x644861++){var _0x2be15b=_0x4b9151[_0x644861];_0x2c2e69['addAlphaRemapGradient'](_0x2be15b['gradient'],void 0x0!==_0x2be15b['factor1']?_0x2be15b['factor1']:_0x2be15b['factor'],_0x2be15b['factor2']);}if(_0x4b43ce['sizeGradients'])for(var _0x3dcadc=0x0,_0x165cac=_0x4b43ce['sizeGradients'];_0x3dcadc<_0x165cac['length'];_0x3dcadc++){var _0xb8d1ce=_0x165cac[_0x3dcadc];_0x2c2e69['addSizeGradient'](_0xb8d1ce['gradient'],void 0x0!==_0xb8d1ce['factor1']?_0xb8d1ce['factor1']:_0xb8d1ce['factor'],_0xb8d1ce['factor2']);}if(_0x4b43ce['angularSpeedGradients'])for(var _0x566861=0x0,_0x1eb299=_0x4b43ce['angularSpeedGradients'];_0x566861<_0x1eb299['length'];_0x566861++){var _0x4076f6=_0x1eb299[_0x566861];_0x2c2e69['addAngularSpeedGradient'](_0x4076f6['gradient'],void 0x0!==_0x4076f6['factor1']?_0x4076f6['factor1']:_0x4076f6['factor'],_0x4076f6['factor2']);}if(_0x4b43ce['velocityGradients'])for(var _0x346d80=0x0,_0x56a795=_0x4b43ce['velocityGradients'];_0x346d80<_0x56a795['length'];_0x346d80++){var _0x261c6b=_0x56a795[_0x346d80];_0x2c2e69['addVelocityGradient'](_0x261c6b['gradient'],void 0x0!==_0x261c6b['factor1']?_0x261c6b['factor1']:_0x261c6b['factor'],_0x261c6b['factor2']);}if(_0x4b43ce['dragGradients'])for(var _0x5adea2=0x0,_0x4a7b7a=_0x4b43ce['dragGradients'];_0x5adea2<_0x4a7b7a['length'];_0x5adea2++){var _0x29febc=_0x4a7b7a[_0x5adea2];_0x2c2e69['addDragGradient'](_0x29febc['gradient'],void 0x0!==_0x29febc['factor1']?_0x29febc['factor1']:_0x29febc['factor'],_0x29febc['factor2']);}if(_0x4b43ce['emitRateGradients'])for(var _0x45a247=0x0,_0x194aed=_0x4b43ce['emitRateGradients'];_0x45a247<_0x194aed['length'];_0x45a247++){var _0x96eba0=_0x194aed[_0x45a247];_0x2c2e69['addEmitRateGradient'](_0x96eba0['gradient'],void 0x0!==_0x96eba0['factor1']?_0x96eba0['factor1']:_0x96eba0['factor'],_0x96eba0['factor2']);}if(_0x4b43ce['startSizeGradients'])for(var _0x53b0a2=0x0,_0xef71d7=_0x4b43ce['startSizeGradients'];_0x53b0a2<_0xef71d7['length'];_0x53b0a2++){var _0x44fa6d=_0xef71d7[_0x53b0a2];_0x2c2e69['addStartSizeGradient'](_0x44fa6d['gradient'],void 0x0!==_0x44fa6d['factor1']?_0x44fa6d['factor1']:_0x44fa6d['factor'],_0x44fa6d['factor2']);}if(_0x4b43ce['lifeTimeGradients'])for(var _0x14b291=0x0,_0x2c9c63=_0x4b43ce['lifeTimeGradients'];_0x14b291<_0x2c9c63['length'];_0x14b291++){var _0x55142a=_0x2c9c63[_0x14b291];_0x2c2e69['addLifeTimeGradient'](_0x55142a['gradient'],void 0x0!==_0x55142a['factor1']?_0x55142a['factor1']:_0x55142a['factor'],_0x55142a['factor2']);}if(_0x4b43ce['limitVelocityGradients']){for(var _0x45b419=0x0,_0x371f31=_0x4b43ce['limitVelocityGradients'];_0x45b419<_0x371f31['length'];_0x45b419++){var _0xa2cb65=_0x371f31[_0x45b419];_0x2c2e69['addLimitVelocityGradient'](_0xa2cb65['gradient'],void 0x0!==_0xa2cb65['factor1']?_0xa2cb65['factor1']:_0xa2cb65['factor'],_0xa2cb65['factor2']);}_0x2c2e69['limitVelocityDamping']=_0x4b43ce['limitVelocityDamping'];}if(_0x4b43ce['noiseTexture']&&_0x357f1d){var _0x3682e6=_0x3cd573['a']['GetClass']('BABYLON.ProceduralTexture');_0x2c2e69['noiseTexture']=_0x3682e6['Parse'](_0x4b43ce['noiseTexture'],_0x357f1d,_0x869688);}if(_0x4b43ce['particleEmitterType']){switch(_0x4b43ce['particleEmitterType']['type']){case'SphereParticleEmitter':_0x445e83=new _0x338038();break;case'SphereDirectedParticleEmitter':_0x445e83=new _0x111265();break;case'ConeEmitter':case'ConeParticleEmitter':_0x445e83=new _0x2cb2ef();break;case'CylinderParticleEmitter':_0x445e83=new _0x4c9a66();break;case'CylinderDirectedParticleEmitter':_0x445e83=new _0x1b1b95();break;case'HemisphericParticleEmitter':_0x445e83=new _0x18cf99();break;case'PointParticleEmitter':_0x445e83=new _0x48f6b1();break;case'MeshParticleEmitter':_0x445e83=new _0x219b07();break;case'BoxEmitter':case'BoxParticleEmitter':default:_0x445e83=new _0x3faf18();}_0x445e83['parse'](_0x4b43ce['particleEmitterType'],_0x357f1d);}else(_0x445e83=new _0x3faf18())['parse'](_0x4b43ce,_0x357f1d);_0x2c2e69['particleEmitterType']=_0x445e83,_0x2c2e69['startSpriteCellID']=_0x4b43ce['startSpriteCellID'],_0x2c2e69['endSpriteCellID']=_0x4b43ce['endSpriteCellID'],_0x2c2e69['spriteCellWidth']=_0x4b43ce['spriteCellWidth'],_0x2c2e69['spriteCellHeight']=_0x4b43ce['spriteCellHeight'],_0x2c2e69['spriteCellChangeSpeed']=_0x4b43ce['spriteCellChangeSpeed'],_0x2c2e69['spriteRandomStartCell']=_0x4b43ce['spriteRandomStartCell'];},_0x2f774b['Parse']=function(_0x259ea4,_0x1ab1ce,_0x3f043e,_0x1399bc){void 0x0===_0x1399bc&&(_0x1399bc=!0x1);var _0xe8a1eb,_0x4a95db=_0x259ea4['name'],_0x3957b8=null,_0x1425ef=null;if(_0xe8a1eb=_0x1ab1ce instanceof _0x26966b['a']?_0x1ab1ce:_0x1ab1ce['getEngine'](),_0x259ea4['customShader']&&_0xe8a1eb['createEffectForParticles']){var _0x41a6ee=(_0x1425ef=_0x259ea4['customShader'])['shaderOptions']['defines']['length']>0x0?_0x1425ef['shaderOptions']['defines']['join']('\x0a'):'';_0x3957b8=_0xe8a1eb['createEffectForParticles'](_0x1425ef['shaderPath']['fragmentElement'],_0x1425ef['shaderOptions']['uniforms'],_0x1425ef['shaderOptions']['samplers'],_0x41a6ee);}var _0x1e13a2=new _0x2f774b(_0x4a95db,_0x259ea4['capacity'],_0x1ab1ce,_0x3957b8,_0x259ea4['isAnimationSheetEnabled']);if(_0x1e13a2['customShader']=_0x1425ef,_0x259ea4['id']&&(_0x1e13a2['id']=_0x259ea4['id']),_0x259ea4['subEmitters']){_0x1e13a2['subEmitters']=[];for(var _0x493816=0x0,_0x4c1cc9=_0x259ea4['subEmitters'];_0x493816<_0x4c1cc9['length'];_0x493816++){for(var _0x5b3c42=[],_0x3d0097=0x0,_0x5c2af3=_0x4c1cc9[_0x493816];_0x3d0097<_0x5c2af3['length'];_0x3d0097++){var _0x187d7f=_0x5c2af3[_0x3d0097];_0x5b3c42['push'](_0x5abfe8['Parse'](_0x187d7f,_0x1ab1ce,_0x3f043e));}_0x1e13a2['subEmitters']['push'](_0x5b3c42);}}return _0x2f774b['_Parse'](_0x259ea4,_0x1e13a2,_0x1ab1ce,_0x3f043e),_0x259ea4['textureMask']&&(_0x1e13a2['textureMask']=_0x39310d['b']['FromArray'](_0x259ea4['textureMask'])),_0x259ea4['preventAutoStart']&&(_0x1e13a2['preventAutoStart']=_0x259ea4['preventAutoStart']),_0x1399bc||_0x1e13a2['preventAutoStart']||_0x1e13a2['start'](),_0x1e13a2;},_0x2f774b['BILLBOARDMODE_Y']=_0x2103ba['a']['PARTICLES_BILLBOARDMODE_Y'],_0x2f774b['BILLBOARDMODE_ALL']=_0x2103ba['a']['PARTICLES_BILLBOARDMODE_ALL'],_0x2f774b['BILLBOARDMODE_STRETCHED']=_0x2103ba['a']['PARTICLES_BILLBOARDMODE_STRETCHED'],_0x2f774b;}(_0x2e1395);_0x5abfe8['_ParseParticleSystem']=_0x4baa8b['Parse'],_0x494b01['a']['ShadersStore']['gpuUpdateParticlesPixelShader']='#version\x20300\x20es\x0avoid\x20main()\x20{\x0adiscard;\x0a}\x0a';var _0x529008='#version\x20300\x20es\x0a#define\x20PI\x203.14159\x0auniform\x20float\x20currentCount;\x0auniform\x20float\x20timeDelta;\x0auniform\x20float\x20stopFactor;\x0a#ifndef\x20LOCAL\x0auniform\x20mat4\x20emitterWM;\x0a#endif\x0auniform\x20vec2\x20lifeTime;\x0auniform\x20vec2\x20emitPower;\x0auniform\x20vec2\x20sizeRange;\x0auniform\x20vec4\x20scaleRange;\x0a#ifndef\x20COLORGRADIENTS\x0auniform\x20vec4\x20color1;\x0auniform\x20vec4\x20color2;\x0a#endif\x0auniform\x20vec3\x20gravity;\x0auniform\x20sampler2D\x20randomSampler;\x0auniform\x20sampler2D\x20randomSampler2;\x0auniform\x20vec4\x20angleRange;\x0a#ifdef\x20BOXEMITTER\x0auniform\x20vec3\x20direction1;\x0auniform\x20vec3\x20direction2;\x0auniform\x20vec3\x20minEmitBox;\x0auniform\x20vec3\x20maxEmitBox;\x0a#endif\x0a#ifdef\x20POINTEMITTER\x0auniform\x20vec3\x20direction1;\x0auniform\x20vec3\x20direction2;\x0a#endif\x0a#ifdef\x20HEMISPHERICEMITTER\x0auniform\x20float\x20radius;\x0auniform\x20float\x20radiusRange;\x0auniform\x20float\x20directionRandomizer;\x0a#endif\x0a#ifdef\x20SPHEREEMITTER\x0auniform\x20float\x20radius;\x0auniform\x20float\x20radiusRange;\x0a#ifdef\x20DIRECTEDSPHEREEMITTER\x0auniform\x20vec3\x20direction1;\x0auniform\x20vec3\x20direction2;\x0a#else\x0auniform\x20float\x20directionRandomizer;\x0a#endif\x0a#endif\x0a#ifdef\x20CYLINDEREMITTER\x0auniform\x20float\x20radius;\x0auniform\x20float\x20height;\x0auniform\x20float\x20radiusRange;\x0a#ifdef\x20DIRECTEDCYLINDEREMITTER\x0auniform\x20vec3\x20direction1;\x0auniform\x20vec3\x20direction2;\x0a#else\x0auniform\x20float\x20directionRandomizer;\x0a#endif\x0a#endif\x0a#ifdef\x20CONEEMITTER\x0auniform\x20vec2\x20radius;\x0auniform\x20float\x20coneAngle;\x0auniform\x20vec2\x20height;\x0auniform\x20float\x20directionRandomizer;\x0a#endif\x0a\x0ain\x20vec3\x20position;\x0a#ifdef\x20CUSTOMEMITTER\x0ain\x20vec3\x20initialPosition;\x0a#endif\x0ain\x20float\x20age;\x0ain\x20float\x20life;\x0ain\x20vec4\x20seed;\x0ain\x20vec3\x20size;\x0a#ifndef\x20COLORGRADIENTS\x0ain\x20vec4\x20color;\x0a#endif\x0ain\x20vec3\x20direction;\x0a#ifndef\x20BILLBOARD\x0ain\x20vec3\x20initialDirection;\x0a#endif\x0a#ifdef\x20ANGULARSPEEDGRADIENTS\x0ain\x20float\x20angle;\x0a#else\x0ain\x20vec2\x20angle;\x0a#endif\x0a#ifdef\x20ANIMATESHEET\x0ain\x20float\x20cellIndex;\x0a#ifdef\x20ANIMATESHEETRANDOMSTART\x0ain\x20float\x20cellStartOffset;\x0a#endif\x0a#endif\x0a#ifdef\x20NOISE\x0ain\x20vec3\x20noiseCoordinates1;\x0ain\x20vec3\x20noiseCoordinates2;\x0a#endif\x0a\x0aout\x20vec3\x20outPosition;\x0a#ifdef\x20CUSTOMEMITTER\x0aout\x20vec3\x20outInitialPosition;\x0a#endif\x0aout\x20float\x20outAge;\x0aout\x20float\x20outLife;\x0aout\x20vec4\x20outSeed;\x0aout\x20vec3\x20outSize;\x0a#ifndef\x20COLORGRADIENTS\x0aout\x20vec4\x20outColor;\x0a#endif\x0aout\x20vec3\x20outDirection;\x0a#ifndef\x20BILLBOARD\x0aout\x20vec3\x20outInitialDirection;\x0a#endif\x0a#ifdef\x20ANGULARSPEEDGRADIENTS\x0aout\x20float\x20outAngle;\x0a#else\x0aout\x20vec2\x20outAngle;\x0a#endif\x0a#ifdef\x20ANIMATESHEET\x0aout\x20float\x20outCellIndex;\x0a#ifdef\x20ANIMATESHEETRANDOMSTART\x0aout\x20float\x20outCellStartOffset;\x0a#endif\x0a#endif\x0a#ifdef\x20NOISE\x0aout\x20vec3\x20outNoiseCoordinates1;\x0aout\x20vec3\x20outNoiseCoordinates2;\x0a#endif\x0a#ifdef\x20SIZEGRADIENTS\x0auniform\x20sampler2D\x20sizeGradientSampler;\x0a#endif\x0a#ifdef\x20ANGULARSPEEDGRADIENTS\x0auniform\x20sampler2D\x20angularSpeedGradientSampler;\x0a#endif\x0a#ifdef\x20VELOCITYGRADIENTS\x0auniform\x20sampler2D\x20velocityGradientSampler;\x0a#endif\x0a#ifdef\x20LIMITVELOCITYGRADIENTS\x0auniform\x20sampler2D\x20limitVelocityGradientSampler;\x0auniform\x20float\x20limitVelocityDamping;\x0a#endif\x0a#ifdef\x20DRAGGRADIENTS\x0auniform\x20sampler2D\x20dragGradientSampler;\x0a#endif\x0a#ifdef\x20NOISE\x0auniform\x20vec3\x20noiseStrength;\x0auniform\x20sampler2D\x20noiseSampler;\x0a#endif\x0a#ifdef\x20ANIMATESHEET\x0auniform\x20vec3\x20cellInfos;\x0a#endif\x0avec3\x20getRandomVec3(float\x20offset)\x20{\x0areturn\x20texture(randomSampler2,vec2(float(gl_VertexID)*offset/currentCount,0)).rgb;\x0a}\x0avec4\x20getRandomVec4(float\x20offset)\x20{\x0areturn\x20texture(randomSampler,vec2(float(gl_VertexID)*offset/currentCount,0));\x0a}\x0avoid\x20main()\x20{\x0afloat\x20newAge=age+timeDelta;\x0a\x0aif\x20(newAge>=life\x20&&\x20stopFactor\x20!=\x200.)\x20{\x0avec3\x20newPosition;\x0avec3\x20newDirection;\x0a\x0avec4\x20randoms=getRandomVec4(seed.x);\x0a\x0aoutLife=lifeTime.x+(lifeTime.y-lifeTime.x)*randoms.r;\x0aoutAge=newAge-life;\x0a\x0aoutSeed=seed;\x0a\x0a#ifdef\x20SIZEGRADIENTS\x0aoutSize.x=texture(sizeGradientSampler,vec2(0,0)).r;\x0a#else\x0aoutSize.x=sizeRange.x+(sizeRange.y-sizeRange.x)*randoms.g;\x0a#endif\x0aoutSize.y=scaleRange.x+(scaleRange.y-scaleRange.x)*randoms.b;\x0aoutSize.z=scaleRange.z+(scaleRange.w-scaleRange.z)*randoms.a;\x0a#ifndef\x20COLORGRADIENTS\x0a\x0aoutColor=color1+(color2-color1)*randoms.b;\x0a#endif\x0a\x0a#ifndef\x20ANGULARSPEEDGRADIENTS\x0aoutAngle.y=angleRange.x+(angleRange.y-angleRange.x)*randoms.a;\x0aoutAngle.x=angleRange.z+(angleRange.w-angleRange.z)*randoms.r;\x0a#else\x0aoutAngle=angleRange.z+(angleRange.w-angleRange.z)*randoms.r;\x0a#endif\x0a\x0a#ifdef\x20POINTEMITTER\x0avec3\x20randoms2=getRandomVec3(seed.y);\x0avec3\x20randoms3=getRandomVec3(seed.z);\x0anewPosition=vec3(0,0,0);\x0anewDirection=direction1+(direction2-direction1)*randoms3;\x0a#elif\x20defined(BOXEMITTER)\x0avec3\x20randoms2=getRandomVec3(seed.y);\x0avec3\x20randoms3=getRandomVec3(seed.z);\x0anewPosition=minEmitBox+(maxEmitBox-minEmitBox)*randoms2;\x0anewDirection=direction1+(direction2-direction1)*randoms3;\x0a#elif\x20defined(HEMISPHERICEMITTER)\x0avec3\x20randoms2=getRandomVec3(seed.y);\x0avec3\x20randoms3=getRandomVec3(seed.z);\x0a\x0afloat\x20phi=2.0*PI*randoms2.x;\x0afloat\x20theta=acos(2.0*randoms2.y-1.0);\x0afloat\x20randX=cos(phi)*sin(theta);\x0afloat\x20randY=cos(theta);\x0afloat\x20randZ=sin(phi)*sin(theta);\x0anewPosition=(radius-(radius*radiusRange*randoms2.z))*vec3(randX,abs(randY),randZ);\x0anewDirection=newPosition+directionRandomizer*randoms3;\x0a#elif\x20defined(SPHEREEMITTER)\x0avec3\x20randoms2=getRandomVec3(seed.y);\x0avec3\x20randoms3=getRandomVec3(seed.z);\x0a\x0afloat\x20phi=2.0*PI*randoms2.x;\x0afloat\x20theta=acos(2.0*randoms2.y-1.0);\x0afloat\x20randX=cos(phi)*sin(theta);\x0afloat\x20randY=cos(theta);\x0afloat\x20randZ=sin(phi)*sin(theta);\x0anewPosition=(radius-(radius*radiusRange*randoms2.z))*vec3(randX,randY,randZ);\x0a#ifdef\x20DIRECTEDSPHEREEMITTER\x0anewDirection=direction1+(direction2-direction1)*randoms3;\x0a#else\x0a\x0anewDirection=newPosition+directionRandomizer*randoms3;\x0a#endif\x0a#elif\x20defined(CYLINDEREMITTER)\x0avec3\x20randoms2=getRandomVec3(seed.y);\x0avec3\x20randoms3=getRandomVec3(seed.z);\x0a\x0afloat\x20yPos=(randoms2.x-0.5)*height;\x0afloat\x20angle=randoms2.y*PI*2.;\x0afloat\x20inverseRadiusRangeSquared=((1.-radiusRange)*(1.-radiusRange));\x0afloat\x20positionRadius=radius*sqrt(inverseRadiusRangeSquared+(randoms2.z*(1.-inverseRadiusRangeSquared)));\x0afloat\x20xPos=positionRadius*cos(angle);\x0afloat\x20zPos=positionRadius*sin(angle);\x0anewPosition=vec3(xPos,yPos,zPos);\x0a#ifdef\x20DIRECTEDCYLINDEREMITTER\x0anewDirection=direction1+(direction2-direction1)*randoms3;\x0a#else\x0a\x0aangle=angle+((randoms3.x-0.5)*PI);\x0anewDirection=vec3(cos(angle),randoms3.y-0.5,sin(angle));\x0anewDirection=normalize(newDirection);\x0a#endif\x0a#elif\x20defined(CONEEMITTER)\x0avec3\x20randoms2=getRandomVec3(seed.y);\x0afloat\x20s=2.0*PI*randoms2.x;\x0a#ifdef\x20CONEEMITTERSPAWNPOINT\x0afloat\x20h=0.0001;\x0a#else\x0afloat\x20h=randoms2.y*height.y;\x0a\x0ah=1.-h*h;\x0a#endif\x0afloat\x20lRadius=radius.x-radius.x*randoms2.z*radius.y;\x0alRadius=lRadius*h;\x0afloat\x20randX=lRadius*sin(s);\x0afloat\x20randZ=lRadius*cos(s);\x0afloat\x20randY=h*height.x;\x0anewPosition=vec3(randX,randY,randZ);\x0a\x0aif\x20(abs(cos(coneAngle))\x20==\x201.0)\x20{\x0anewDirection=vec3(0.,1.0,0.);\x0a}\x20else\x20{\x0avec3\x20randoms3=getRandomVec3(seed.z);\x0anewDirection=normalize(newPosition+directionRandomizer*randoms3);\x0a}\x0a#elif\x20defined(CUSTOMEMITTER)\x0anewPosition=initialPosition;\x0aoutInitialPosition=initialPosition;\x0a#else\x0a\x0anewPosition=vec3(0.,0.,0.);\x0a\x0anewDirection=2.0*(getRandomVec3(seed.w)-vec3(0.5,0.5,0.5));\x0a#endif\x0afloat\x20power=emitPower.x+(emitPower.y-emitPower.x)*randoms.a;\x0a#ifdef\x20LOCAL\x0aoutPosition=newPosition;\x0a#else\x0aoutPosition=(emitterWM*vec4(newPosition,1.)).xyz;\x0a#endif\x0a#ifdef\x20CUSTOMEMITTER\x0aoutDirection=direction;\x0a#ifndef\x20BILLBOARD\x0aoutInitialDirection=direction;\x0a#endif\x0a#else\x0a#ifdef\x20LOCAL\x0avec3\x20initial=newDirection;\x0a#else\x0avec3\x20initial=(emitterWM*vec4(newDirection,0.)).xyz;\x0a#endif\x0aoutDirection=initial*power;\x0a#ifndef\x20BILLBOARD\x0aoutInitialDirection=initial;\x0a#endif\x0a#endif\x0a#ifdef\x20ANIMATESHEET\x0aoutCellIndex=cellInfos.x;\x0a#ifdef\x20ANIMATESHEETRANDOMSTART\x0aoutCellStartOffset=randoms.a*outLife;\x0a#endif\x0a#endif\x0a#ifdef\x20NOISE\x0aoutNoiseCoordinates1=noiseCoordinates1;\x0aoutNoiseCoordinates2=noiseCoordinates2;\x0a#endif\x0a}\x20else\x20{\x0afloat\x20directionScale=timeDelta;\x0aoutAge=newAge;\x0afloat\x20ageGradient=newAge/life;\x0a#ifdef\x20VELOCITYGRADIENTS\x0adirectionScale*=texture(velocityGradientSampler,vec2(ageGradient,0)).r;\x0a#endif\x0a#ifdef\x20DRAGGRADIENTS\x0adirectionScale*=1.0-texture(dragGradientSampler,vec2(ageGradient,0)).r;\x0a#endif\x0a#if\x20defined(CUSTOMEMITTER)\x0aoutPosition=position+(direction-position)*ageGradient;\x0aoutInitialPosition=initialPosition;\x0a#else\x0aoutPosition=position+direction*directionScale;\x0a#endif\x0aoutLife=life;\x0aoutSeed=seed;\x0a#ifndef\x20COLORGRADIENTS\x0aoutColor=color;\x0a#endif\x0a#ifdef\x20SIZEGRADIENTS\x0aoutSize.x=texture(sizeGradientSampler,vec2(ageGradient,0)).r;\x0aoutSize.yz=size.yz;\x0a#else\x0aoutSize=size;\x0a#endif\x0a#ifndef\x20BILLBOARD\x0aoutInitialDirection=initialDirection;\x0a#endif\x0a#ifdef\x20CUSTOMEMITTER\x0aoutDirection=direction;\x0a#else\x0avec3\x20updatedDirection=direction+gravity*timeDelta;\x0a#ifdef\x20LIMITVELOCITYGRADIENTS\x0afloat\x20limitVelocity=texture(limitVelocityGradientSampler,vec2(ageGradient,0)).r;\x0afloat\x20currentVelocity=length(updatedDirection);\x0aif\x20(currentVelocity>limitVelocity)\x20{\x0aupdatedDirection=updatedDirection*limitVelocityDamping;\x0a}\x0a#endif\x0aoutDirection=updatedDirection;\x0a#ifdef\x20NOISE\x0afloat\x20fetchedR=texture(noiseSampler,vec2(noiseCoordinates1.x,noiseCoordinates1.y)*vec2(0.5)+vec2(0.5)).r;\x0afloat\x20fetchedG=texture(noiseSampler,vec2(noiseCoordinates1.z,noiseCoordinates2.x)*vec2(0.5)+vec2(0.5)).r;\x0afloat\x20fetchedB=texture(noiseSampler,vec2(noiseCoordinates2.y,noiseCoordinates2.z)*vec2(0.5)+vec2(0.5)).r;\x0avec3\x20force=vec3(2.*fetchedR-1.,2.*fetchedG-1.,2.*fetchedB-1.)*noiseStrength;\x0aoutDirection=outDirection+force*timeDelta;\x0aoutNoiseCoordinates1=noiseCoordinates1;\x0aoutNoiseCoordinates2=noiseCoordinates2;\x0a#endif\x0a#endif\x0a#ifdef\x20ANGULARSPEEDGRADIENTS\x0afloat\x20angularSpeed=texture(angularSpeedGradientSampler,vec2(ageGradient,0)).r;\x0aoutAngle=angle+angularSpeed*timeDelta;\x0a#else\x0aoutAngle=vec2(angle.x+angle.y*timeDelta,angle.y);\x0a#endif\x0a#ifdef\x20ANIMATESHEET\x0afloat\x20offsetAge=outAge;\x0afloat\x20dist=cellInfos.y-cellInfos.x;\x0a#ifdef\x20ANIMATESHEETRANDOMSTART\x0aoutCellStartOffset=cellStartOffset;\x0aoffsetAge+=cellStartOffset;\x0a#else\x0afloat\x20cellStartOffset=0.;\x0a#endif\x0afloat\x20ratio=clamp(mod(cellStartOffset+cellInfos.z*offsetAge,life)/life,0.,1.0);\x0aoutCellIndex=float(int(cellInfos.x+ratio*dist));\x0a#endif\x0a}\x0a}';_0x494b01['a']['ShadersStore']['gpuUpdateParticlesVertexShader']=_0x529008;var _0xe9f48c='#ifdef\x20CLIPPLANE\x0ain\x20float\x20fClipDistance;\x0a#endif\x0a#ifdef\x20CLIPPLANE2\x0ain\x20float\x20fClipDistance2;\x0a#endif\x0a#ifdef\x20CLIPPLANE3\x0ain\x20float\x20fClipDistance3;\x0a#endif\x0a#ifdef\x20CLIPPLANE4\x0ain\x20float\x20fClipDistance4;\x0a#endif\x0a#ifdef\x20CLIPPLANE5\x0ain\x20float\x20fClipDistance5;\x0a#endif\x0a#ifdef\x20CLIPPLANE6\x0ain\x20float\x20fClipDistance6;\x0a#endif';_0x494b01['a']['IncludesShadersStore']['clipPlaneFragmentDeclaration2']=_0xe9f48c;var _0x4b70d0='#version\x20300\x20es\x0auniform\x20sampler2D\x20diffuseSampler;\x0ain\x20vec2\x20vUV;\x0ain\x20vec4\x20vColor;\x0aout\x20vec4\x20outFragColor;\x0a#include\x0a#include\x0a#include\x0a#include\x0avoid\x20main()\x20{\x0a#include\x0avec4\x20textureColor=texture(diffuseSampler,vUV);\x0aoutFragColor=textureColor*vColor;\x0a#ifdef\x20BLENDMULTIPLYMODE\x0afloat\x20alpha=vColor.a*textureColor.a;\x0aoutFragColor.rgb=outFragColor.rgb*alpha+vec3(1.0)*(1.0-alpha);\x0a#endif\x0a\x0a\x0a#ifdef\x20IMAGEPROCESSINGPOSTPROCESS\x0aoutFragColor.rgb=toLinearSpace(outFragColor.rgb);\x0a#else\x0a#ifdef\x20IMAGEPROCESSING\x0aoutFragColor.rgb=toLinearSpace(outFragColor.rgb);\x0aoutFragColor=applyImageProcessing(outFragColor);\x0a#endif\x0a#endif\x0a}\x0a';_0x494b01['a']['ShadersStore']['gpuRenderParticlesPixelShader']=_0x4b70d0;var _0x336395='#ifdef\x20CLIPPLANE\x0auniform\x20vec4\x20vClipPlane;\x0aout\x20float\x20fClipDistance;\x0a#endif\x0a#ifdef\x20CLIPPLANE2\x0auniform\x20vec4\x20vClipPlane2;\x0aout\x20float\x20fClipDistance2;\x0a#endif\x0a#ifdef\x20CLIPPLANE3\x0auniform\x20vec4\x20vClipPlane3;\x0aout\x20float\x20fClipDistance3;\x0a#endif\x0a#ifdef\x20CLIPPLANE4\x0auniform\x20vec4\x20vClipPlane4;\x0aout\x20float\x20fClipDistance4;\x0a#endif\x0a#ifdef\x20CLIPPLANE5\x0auniform\x20vec4\x20vClipPlane5;\x0aout\x20float\x20fClipDistance5;\x0a#endif\x0a#ifdef\x20CLIPPLANE6\x0auniform\x20vec4\x20vClipPlane6;\x0aout\x20float\x20fClipDistance6;\x0a#endif';_0x494b01['a']['IncludesShadersStore']['clipPlaneVertexDeclaration2']=_0x336395;var _0x44e6b0='#version\x20300\x20es\x0auniform\x20mat4\x20view;\x0auniform\x20mat4\x20projection;\x0auniform\x20vec2\x20translationPivot;\x0auniform\x20vec3\x20worldOffset;\x0a#ifdef\x20LOCAL\x0auniform\x20mat4\x20emitterWM;\x0a#endif\x0a\x0ain\x20vec3\x20position;\x0ain\x20float\x20age;\x0ain\x20float\x20life;\x0ain\x20vec3\x20size;\x0a#ifndef\x20BILLBOARD\x0ain\x20vec3\x20initialDirection;\x0a#endif\x0a#ifdef\x20BILLBOARDSTRETCHED\x0ain\x20vec3\x20direction;\x0a#endif\x0ain\x20float\x20angle;\x0a#ifdef\x20ANIMATESHEET\x0ain\x20float\x20cellIndex;\x0a#endif\x0ain\x20vec2\x20offset;\x0ain\x20vec2\x20uv;\x0aout\x20vec2\x20vUV;\x0aout\x20vec4\x20vColor;\x0aout\x20vec3\x20vPositionW;\x0a#if\x20defined(BILLBOARD)\x20&&\x20!defined(BILLBOARDY)\x20&&\x20!defined(BILLBOARDSTRETCHED)\x0auniform\x20mat4\x20invView;\x0a#endif\x0a#include\x0a#ifdef\x20COLORGRADIENTS\x0auniform\x20sampler2D\x20colorGradientSampler;\x0a#else\x0auniform\x20vec4\x20colorDead;\x0ain\x20vec4\x20color;\x0a#endif\x0a#ifdef\x20ANIMATESHEET\x0auniform\x20vec3\x20sheetInfos;\x0a#endif\x0a#ifdef\x20BILLBOARD\x0auniform\x20vec3\x20eyePosition;\x0a#endif\x0avec3\x20rotate(vec3\x20yaxis,vec3\x20rotatedCorner)\x20{\x0avec3\x20xaxis=normalize(cross(vec3(0.,1.0,0.),yaxis));\x0avec3\x20zaxis=normalize(cross(yaxis,xaxis));\x0avec3\x20row0=vec3(xaxis.x,xaxis.y,xaxis.z);\x0avec3\x20row1=vec3(yaxis.x,yaxis.y,yaxis.z);\x0avec3\x20row2=vec3(zaxis.x,zaxis.y,zaxis.z);\x0amat3\x20rotMatrix=mat3(row0,row1,row2);\x0avec3\x20alignedCorner=rotMatrix*rotatedCorner;\x0a#ifdef\x20LOCAL\x0areturn\x20((emitterWM*vec4(position,1.0)).xyz+worldOffset)+alignedCorner;\x0a#else\x0areturn\x20(position+worldOffset)+alignedCorner;\x0a#endif\x0a}\x0a#ifdef\x20BILLBOARDSTRETCHED\x0avec3\x20rotateAlign(vec3\x20toCamera,vec3\x20rotatedCorner)\x20{\x0avec3\x20normalizedToCamera=normalize(toCamera);\x0avec3\x20normalizedCrossDirToCamera=normalize(cross(normalize(direction),normalizedToCamera));\x0avec3\x20crossProduct=normalize(cross(normalizedToCamera,normalizedCrossDirToCamera));\x0avec3\x20row0=vec3(normalizedCrossDirToCamera.x,normalizedCrossDirToCamera.y,normalizedCrossDirToCamera.z);\x0avec3\x20row1=vec3(crossProduct.x,crossProduct.y,crossProduct.z);\x0avec3\x20row2=vec3(normalizedToCamera.x,normalizedToCamera.y,normalizedToCamera.z);\x0amat3\x20rotMatrix=mat3(row0,row1,row2);\x0avec3\x20alignedCorner=rotMatrix*rotatedCorner;\x0a#ifdef\x20LOCAL\x0areturn\x20((emitterWM*vec4(position,1.0)).xyz+worldOffset)+alignedCorner;\x0a#else\x0areturn\x20(position+worldOffset)+alignedCorner;\x0a#endif\x0a}\x0a#endif\x0avoid\x20main()\x20{\x0a#ifdef\x20ANIMATESHEET\x0afloat\x20rowOffset=floor(cellIndex/sheetInfos.z);\x0afloat\x20columnOffset=cellIndex-rowOffset*sheetInfos.z;\x0avec2\x20uvScale=sheetInfos.xy;\x0avec2\x20uvOffset=vec2(uv.x\x20,1.0-uv.y);\x0avUV=(uvOffset+vec2(columnOffset,rowOffset))*uvScale;\x0a#else\x0avUV=uv;\x0a#endif\x0afloat\x20ratio=age/life;\x0a#ifdef\x20COLORGRADIENTS\x0avColor=texture(colorGradientSampler,vec2(ratio,0));\x0a#else\x0avColor=color*vec4(1.0-ratio)+colorDead*vec4(ratio);\x0a#endif\x0avec2\x20cornerPos=(offset-translationPivot)*size.yz*size.x+translationPivot;\x0a#ifdef\x20BILLBOARD\x0avec4\x20rotatedCorner;\x0arotatedCorner.w=0.;\x0a#ifdef\x20BILLBOARDY\x0arotatedCorner.x=cornerPos.x*cos(angle)-cornerPos.y*sin(angle);\x0arotatedCorner.z=cornerPos.x*sin(angle)+cornerPos.y*cos(angle);\x0arotatedCorner.y=0.;\x0avec3\x20yaxis=(position+worldOffset)-eyePosition;\x0ayaxis.y=0.;\x0avPositionW=rotate(normalize(yaxis),rotatedCorner.xyz);\x0avec4\x20viewPosition=(view*vec4(vPositionW,1.0));\x0a#elif\x20defined(BILLBOARDSTRETCHED)\x0arotatedCorner.x=cornerPos.x*cos(angle)-cornerPos.y*sin(angle);\x0arotatedCorner.y=cornerPos.x*sin(angle)+cornerPos.y*cos(angle);\x0arotatedCorner.z=0.;\x0avec3\x20toCamera=(position+worldOffset)-eyePosition;\x0avPositionW=rotateAlign(toCamera,rotatedCorner.xyz);\x0avec4\x20viewPosition=(view*vec4(vPositionW,1.0));\x0a#else\x0a\x0arotatedCorner.x=cornerPos.x*cos(angle)-cornerPos.y*sin(angle);\x0arotatedCorner.y=cornerPos.x*sin(angle)+cornerPos.y*cos(angle);\x0arotatedCorner.z=0.;\x0a\x0a#ifdef\x20LOCAL\x0avec4\x20viewPosition=view*vec4(((emitterWM*vec4(position,1.0)).xyz+worldOffset),1.0)+rotatedCorner;\x0a#else\x0avec4\x20viewPosition=view*vec4((position+worldOffset),1.0)+rotatedCorner;\x0a#endif\x0avPositionW=(invView*viewPosition).xyz;\x0a#endif\x0a#else\x0a\x0avec3\x20rotatedCorner;\x0arotatedCorner.x=cornerPos.x*cos(angle)-cornerPos.y*sin(angle);\x0arotatedCorner.y=0.;\x0arotatedCorner.z=cornerPos.x*sin(angle)+cornerPos.y*cos(angle);\x0avec3\x20yaxis=normalize(initialDirection);\x0avPositionW=rotate(yaxis,rotatedCorner);\x0a\x0avec4\x20viewPosition=view*vec4(vPositionW,1.0);\x0a#endif\x0agl_Position=projection*viewPosition;\x0a\x0a#if\x20defined(CLIPPLANE)\x20||\x20defined(CLIPPLANE2)\x20||\x20defined(CLIPPLANE3)\x20||\x20defined(CLIPPLANE4)\x20||\x20defined(CLIPPLANE5)\x20||\x20defined(CLIPPLANE6)\x0avec4\x20worldPos=vec4(vPositionW,1.0);\x0a#endif\x0a#include\x0a}';_0x494b01['a']['ShadersStore']['gpuRenderParticlesVertexShader']=_0x44e6b0;var _0x478f32=function(_0x548514){function _0x2c3e1f(_0x3dce33,_0x505609,_0x444d81,_0x454d97,_0x4a9687){void 0x0===_0x454d97&&(_0x454d97=!0x1),void 0x0===_0x4a9687&&(_0x4a9687=null);var _0x1eabbf=_0x548514['call'](this,_0x3dce33)||this;_0x1eabbf['layerMask']=0xfffffff,_0x1eabbf['_accumulatedCount']=0x0,_0x1eabbf['_targetIndex']=0x0,_0x1eabbf['_currentRenderId']=-0x1,_0x1eabbf['_started']=!0x1,_0x1eabbf['_stopped']=!0x1,_0x1eabbf['_timeDelta']=0x0,_0x1eabbf['_actualFrame']=0x0,_0x1eabbf['_rawTextureWidth']=0x100,_0x1eabbf['onDisposeObservable']=new _0x6ac1f7['c'](),_0x1eabbf['onStoppedObservable']=new _0x6ac1f7['c'](),_0x1eabbf['forceDepthWrite']=!0x1,_0x1eabbf['_preWarmDone']=!0x1,_0x1eabbf['isLocal']=!0x1,_0x1eabbf['_onBeforeDrawParticlesObservable']=null,_0x444d81&&'Scene'!==_0x444d81['getClassName']()?(_0x1eabbf['_engine']=_0x444d81,_0x1eabbf['defaultProjectionMatrix']=_0x74d525['a']['PerspectiveFovLH'](0.8,0x1,0.1,0x64)):(_0x1eabbf['_scene']=_0x444d81||_0x44b9ce['a']['LastCreatedScene'],_0x1eabbf['_engine']=_0x1eabbf['_scene']['getEngine'](),_0x1eabbf['uniqueId']=_0x1eabbf['_scene']['getUniqueId'](),_0x1eabbf['_scene']['particleSystems']['push'](_0x1eabbf)),_0x1eabbf['_customEffect']={0x0:_0x4a9687},_0x1eabbf['_attachImageProcessingConfiguration'](null),_0x505609['randomTextureSize']||delete _0x505609['randomTextureSize'];var _0x28c02f=Object(_0x18e13d['a'])({'capacity':0xc350,'randomTextureSize':_0x1eabbf['_engine']['getCaps']()['maxTextureSize']},_0x505609),_0x31f1e3=_0x505609;isFinite(_0x31f1e3)&&(_0x28c02f['capacity']=_0x31f1e3),_0x1eabbf['_capacity']=_0x28c02f['capacity'],_0x1eabbf['_activeCount']=_0x28c02f['capacity'],_0x1eabbf['_currentActiveCount']=0x0,_0x1eabbf['_isAnimationSheetEnabled']=_0x454d97,_0x1eabbf['_updateEffectOptions']={'attributes':['position','initialPosition','age','life','seed','size','color','direction','initialDirection','angle','cellIndex','cellStartOffset','noiseCoordinates1','noiseCoordinates2'],'uniformsNames':['currentCount','timeDelta','emitterWM','lifeTime','color1','color2','sizeRange','scaleRange','gravity','emitPower','direction1','direction2','minEmitBox','maxEmitBox','radius','directionRandomizer','height','coneAngle','stopFactor','angleRange','radiusRange','cellInfos','noiseStrength','limitVelocityDamping'],'uniformBuffersNames':[],'samplers':['randomSampler','randomSampler2','sizeGradientSampler','angularSpeedGradientSampler','velocityGradientSampler','limitVelocityGradientSampler','noiseSampler','dragGradientSampler'],'defines':'','fallbacks':null,'onCompiled':null,'onError':null,'indexParameters':null,'maxSimultaneousLights':0x0,'transformFeedbackVaryings':[]},_0x1eabbf['particleEmitterType']=new _0x3faf18();for(var _0x492a09=Math['min'](_0x1eabbf['_engine']['getCaps']()['maxTextureSize'],_0x28c02f['randomTextureSize']),_0x26c09c=[],_0x4b1043=0x0;_0x4b1043<_0x492a09;++_0x4b1043)_0x26c09c['push'](Math['random']()),_0x26c09c['push'](Math['random']()),_0x26c09c['push'](Math['random']()),_0x26c09c['push'](Math['random']());_0x1eabbf['_randomTexture']=new _0x1a05d8(new Float32Array(_0x26c09c),_0x492a09,0x1,_0x2103ba['a']['TEXTUREFORMAT_RGBA'],_0x444d81,!0x1,!0x1,_0x2103ba['a']['TEXTURE_NEAREST_SAMPLINGMODE'],_0x2103ba['a']['TEXTURETYPE_FLOAT']),_0x1eabbf['_randomTexture']['wrapU']=_0x2103ba['a']['TEXTURE_WRAP_ADDRESSMODE'],_0x1eabbf['_randomTexture']['wrapV']=_0x2103ba['a']['TEXTURE_WRAP_ADDRESSMODE'],_0x26c09c=[];for(_0x4b1043=0x0;_0x4b1043<_0x492a09;++_0x4b1043)_0x26c09c['push'](Math['random']()),_0x26c09c['push'](Math['random']()),_0x26c09c['push'](Math['random']()),_0x26c09c['push'](Math['random']());return _0x1eabbf['_randomTexture2']=new _0x1a05d8(new Float32Array(_0x26c09c),_0x492a09,0x1,_0x2103ba['a']['TEXTUREFORMAT_RGBA'],_0x444d81,!0x1,!0x1,_0x2103ba['a']['TEXTURE_NEAREST_SAMPLINGMODE'],_0x2103ba['a']['TEXTURETYPE_FLOAT']),_0x1eabbf['_randomTexture2']['wrapU']=_0x2103ba['a']['TEXTURE_WRAP_ADDRESSMODE'],_0x1eabbf['_randomTexture2']['wrapV']=_0x2103ba['a']['TEXTURE_WRAP_ADDRESSMODE'],_0x1eabbf['_randomTextureSize']=_0x492a09,_0x1eabbf;}return Object(_0x18e13d['d'])(_0x2c3e1f,_0x548514),Object['defineProperty'](_0x2c3e1f,'IsSupported',{'get':function(){return!!_0x44b9ce['a']['LastCreatedEngine']&&_0x44b9ce['a']['LastCreatedEngine']['webGLVersion']>0x1;},'enumerable':!0x1,'configurable':!0x0}),_0x2c3e1f['prototype']['getCapacity']=function(){return this['_capacity'];},Object['defineProperty'](_0x2c3e1f['prototype'],'activeParticleCount',{'get':function(){return this['_activeCount'];},'set':function(_0x239025){this['_activeCount']=Math['min'](_0x239025,this['_capacity']);},'enumerable':!0x1,'configurable':!0x0}),_0x2c3e1f['prototype']['isReady']=function(){return this['_updateEffect']?!!(this['emitter']&&this['_updateEffect']['isReady']()&&(!this['_imageProcessingConfiguration']||this['_imageProcessingConfiguration']['isReady']())&&this['_getEffect']()['isReady']()&&this['particleTexture']&&this['particleTexture']['isReady']()):(this['_recreateUpdateEffect'](),this['_recreateRenderEffect'](),!0x1);},_0x2c3e1f['prototype']['isStarted']=function(){return this['_started'];},_0x2c3e1f['prototype']['isStopped']=function(){return this['_stopped'];},_0x2c3e1f['prototype']['isStopping']=function(){return!0x1;},_0x2c3e1f['prototype']['getActiveCount']=function(){return this['_currentActiveCount'];},_0x2c3e1f['prototype']['start']=function(_0x2a3ec3){var _0x10cc3f=this;if(void 0x0===_0x2a3ec3&&(_0x2a3ec3=this['startDelay']),!this['targetStopDuration']&&this['_hasTargetStopDurationDependantGradient']())throw'Particle\x20system\x20started\x20with\x20a\x20targetStopDuration\x20dependant\x20gradient\x20(eg.\x20startSizeGradients)\x20but\x20no\x20targetStopDuration\x20set';_0x2a3ec3?setTimeout(function(){_0x10cc3f['start'](0x0);},_0x2a3ec3):(this['_started']=!0x0,this['_stopped']=!0x1,this['_preWarmDone']=!0x1,this['beginAnimationOnStart']&&this['animations']&&this['animations']['length']>0x0&&this['_scene']&&this['_scene']['beginAnimation'](this,this['beginAnimationFrom'],this['beginAnimationTo'],this['beginAnimationLoop']));},_0x2c3e1f['prototype']['stop']=function(){this['_stopped']||(this['_stopped']=!0x0);},_0x2c3e1f['prototype']['reset']=function(){this['_releaseBuffers'](),this['_releaseVAOs'](),this['_currentActiveCount']=0x0,this['_targetIndex']=0x0;},_0x2c3e1f['prototype']['getClassName']=function(){return'GPUParticleSystem';},_0x2c3e1f['prototype']['getCustomEffect']=function(_0x1ceea8){var _0x1843b3;return void 0x0===_0x1ceea8&&(_0x1ceea8=0x0),null!==(_0x1843b3=this['_customEffect'][_0x1ceea8])&&void 0x0!==_0x1843b3?_0x1843b3:this['_customEffect'][0x0];},_0x2c3e1f['prototype']['setCustomEffect']=function(_0x2feadc,_0x32f7c0){void 0x0===_0x32f7c0&&(_0x32f7c0=0x0),this['_customEffect'][_0x32f7c0]=_0x2feadc;},Object['defineProperty'](_0x2c3e1f['prototype'],'onBeforeDrawParticlesObservable',{'get':function(){return this['_onBeforeDrawParticlesObservable']||(this['_onBeforeDrawParticlesObservable']=new _0x6ac1f7['c']()),this['_onBeforeDrawParticlesObservable'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2c3e1f['prototype'],'vertexShaderName',{'get':function(){return'gpuRenderParticles';},'enumerable':!0x1,'configurable':!0x0}),_0x2c3e1f['prototype']['_removeGradientAndTexture']=function(_0x1d72d4,_0x2e1b82,_0x4e9c86){return _0x548514['prototype']['_removeGradientAndTexture']['call'](this,_0x1d72d4,_0x2e1b82,_0x4e9c86),this['_releaseBuffers'](),this;},_0x2c3e1f['prototype']['addColorGradient']=function(_0x2fd7a4,_0xa80991,_0x85f6d1){this['_colorGradients']||(this['_colorGradients']=[]);var _0x13769a=new _0x3b38b8(_0x2fd7a4,_0xa80991);return this['_colorGradients']['push'](_0x13769a),this['_refreshColorGradient'](!0x0),this['_releaseBuffers'](),this;},_0x2c3e1f['prototype']['_refreshColorGradient']=function(_0x5d6d14){void 0x0===_0x5d6d14&&(_0x5d6d14=!0x1),this['_colorGradients']&&(_0x5d6d14&&this['_colorGradients']['sort'](function(_0x33448c,_0x5d04aa){return _0x33448c['gradient']<_0x5d04aa['gradient']?-0x1:_0x33448c['gradient']>_0x5d04aa['gradient']?0x1:0x0;}),this['_colorGradientsTexture']&&(this['_colorGradientsTexture']['dispose'](),this['_colorGradientsTexture']=null));},_0x2c3e1f['prototype']['forceRefreshGradients']=function(){this['_refreshColorGradient'](),this['_refreshFactorGradient'](this['_sizeGradients'],'_sizeGradientsTexture'),this['_refreshFactorGradient'](this['_angularSpeedGradients'],'_angularSpeedGradientsTexture'),this['_refreshFactorGradient'](this['_velocityGradients'],'_velocityGradientsTexture'),this['_refreshFactorGradient'](this['_limitVelocityGradients'],'_limitVelocityGradientsTexture'),this['_refreshFactorGradient'](this['_dragGradients'],'_dragGradientsTexture'),this['reset']();},_0x2c3e1f['prototype']['removeColorGradient']=function(_0x5abea1){return this['_removeGradientAndTexture'](_0x5abea1,this['_colorGradients'],this['_colorGradientsTexture']),this['_colorGradientsTexture']=null,this;},_0x2c3e1f['prototype']['_addFactorGradient']=function(_0x2bbd65,_0x59c02d,_0x3e6225){var _0x3cc383=new _0x3f4c49(_0x59c02d,_0x3e6225);_0x2bbd65['push'](_0x3cc383),this['_releaseBuffers']();},_0x2c3e1f['prototype']['addSizeGradient']=function(_0x5a59cf,_0x16aa90){return this['_sizeGradients']||(this['_sizeGradients']=[]),this['_addFactorGradient'](this['_sizeGradients'],_0x5a59cf,_0x16aa90),this['_refreshFactorGradient'](this['_sizeGradients'],'_sizeGradientsTexture',!0x0),this['_releaseBuffers'](),this;},_0x2c3e1f['prototype']['removeSizeGradient']=function(_0x4b7bae){return this['_removeGradientAndTexture'](_0x4b7bae,this['_sizeGradients'],this['_sizeGradientsTexture']),this['_sizeGradientsTexture']=null,this;},_0x2c3e1f['prototype']['_refreshFactorGradient']=function(_0x307df6,_0xaa9ade,_0x10bc65){(void 0x0===_0x10bc65&&(_0x10bc65=!0x1),_0x307df6)&&(_0x10bc65&&_0x307df6['sort'](function(_0x55f281,_0x3ceac4){return _0x55f281['gradient']<_0x3ceac4['gradient']?-0x1:_0x55f281['gradient']>_0x3ceac4['gradient']?0x1:0x0;}),this[_0xaa9ade]&&(this[_0xaa9ade]['dispose'](),this[_0xaa9ade]=null));},_0x2c3e1f['prototype']['addAngularSpeedGradient']=function(_0x881290,_0x5dcd6b){return this['_angularSpeedGradients']||(this['_angularSpeedGradients']=[]),this['_addFactorGradient'](this['_angularSpeedGradients'],_0x881290,_0x5dcd6b),this['_refreshFactorGradient'](this['_angularSpeedGradients'],'_angularSpeedGradientsTexture',!0x0),this['_releaseBuffers'](),this;},_0x2c3e1f['prototype']['removeAngularSpeedGradient']=function(_0x2cc9cc){return this['_removeGradientAndTexture'](_0x2cc9cc,this['_angularSpeedGradients'],this['_angularSpeedGradientsTexture']),this['_angularSpeedGradientsTexture']=null,this;},_0x2c3e1f['prototype']['addVelocityGradient']=function(_0x3aa8f0,_0x35ee4a){return this['_velocityGradients']||(this['_velocityGradients']=[]),this['_addFactorGradient'](this['_velocityGradients'],_0x3aa8f0,_0x35ee4a),this['_refreshFactorGradient'](this['_velocityGradients'],'_velocityGradientsTexture',!0x0),this['_releaseBuffers'](),this;},_0x2c3e1f['prototype']['removeVelocityGradient']=function(_0x114dfe){return this['_removeGradientAndTexture'](_0x114dfe,this['_velocityGradients'],this['_velocityGradientsTexture']),this['_velocityGradientsTexture']=null,this;},_0x2c3e1f['prototype']['addLimitVelocityGradient']=function(_0x30e9a9,_0x2f955a){return this['_limitVelocityGradients']||(this['_limitVelocityGradients']=[]),this['_addFactorGradient'](this['_limitVelocityGradients'],_0x30e9a9,_0x2f955a),this['_refreshFactorGradient'](this['_limitVelocityGradients'],'_limitVelocityGradientsTexture',!0x0),this['_releaseBuffers'](),this;},_0x2c3e1f['prototype']['removeLimitVelocityGradient']=function(_0x3580c1){return this['_removeGradientAndTexture'](_0x3580c1,this['_limitVelocityGradients'],this['_limitVelocityGradientsTexture']),this['_limitVelocityGradientsTexture']=null,this;},_0x2c3e1f['prototype']['addDragGradient']=function(_0x2b5528,_0x4c9ecf){return this['_dragGradients']||(this['_dragGradients']=[]),this['_addFactorGradient'](this['_dragGradients'],_0x2b5528,_0x4c9ecf),this['_refreshFactorGradient'](this['_dragGradients'],'_dragGradientsTexture',!0x0),this['_releaseBuffers'](),this;},_0x2c3e1f['prototype']['removeDragGradient']=function(_0x20ad59){return this['_removeGradientAndTexture'](_0x20ad59,this['_dragGradients'],this['_dragGradientsTexture']),this['_dragGradientsTexture']=null,this;},_0x2c3e1f['prototype']['addEmitRateGradient']=function(_0xd3a689,_0x44b807,_0x1aba7c){return this;},_0x2c3e1f['prototype']['removeEmitRateGradient']=function(_0x404c37){return this;},_0x2c3e1f['prototype']['addStartSizeGradient']=function(_0x5d9862,_0x2a5f2e,_0x191c04){return this;},_0x2c3e1f['prototype']['removeStartSizeGradient']=function(_0x42a88f){return this;},_0x2c3e1f['prototype']['addColorRemapGradient']=function(_0x1d4b60,_0x5a7486,_0x38c608){return this;},_0x2c3e1f['prototype']['removeColorRemapGradient']=function(){return this;},_0x2c3e1f['prototype']['addAlphaRemapGradient']=function(_0x4291d5,_0x41af08,_0x237fbb){return this;},_0x2c3e1f['prototype']['removeAlphaRemapGradient']=function(){return this;},_0x2c3e1f['prototype']['addRampGradient']=function(_0xfef031,_0x5ba273){return this;},_0x2c3e1f['prototype']['removeRampGradient']=function(){return this;},_0x2c3e1f['prototype']['getRampGradients']=function(){return null;},Object['defineProperty'](_0x2c3e1f['prototype'],'useRampGradients',{'get':function(){return!0x1;},'set':function(_0x56bdea){},'enumerable':!0x1,'configurable':!0x0}),_0x2c3e1f['prototype']['addLifeTimeGradient']=function(_0x4564d5,_0xdd9213,_0x1c701d){return this;},_0x2c3e1f['prototype']['removeLifeTimeGradient']=function(_0x329bb4){return this;},_0x2c3e1f['prototype']['_reset']=function(){this['_releaseBuffers']();},_0x2c3e1f['prototype']['_createUpdateVAO']=function(_0x25f2d7){var _0x46777f={};_0x46777f['position']=_0x25f2d7['createVertexBuffer']('position',0x0,0x3);var _0x29e1d5=0x3;this['particleEmitterType']instanceof _0x10a54c&&(_0x46777f['initialPosition']=_0x25f2d7['createVertexBuffer']('initialPosition',_0x29e1d5,0x3),_0x29e1d5+=0x3),_0x46777f['age']=_0x25f2d7['createVertexBuffer']('age',_0x29e1d5,0x1),_0x29e1d5+=0x1,_0x46777f['life']=_0x25f2d7['createVertexBuffer']('life',_0x29e1d5,0x1),_0x29e1d5+=0x1,_0x46777f['seed']=_0x25f2d7['createVertexBuffer']('seed',_0x29e1d5,0x4),_0x29e1d5+=0x4,_0x46777f['size']=_0x25f2d7['createVertexBuffer']('size',_0x29e1d5,0x3),_0x29e1d5+=0x3,this['_colorGradientsTexture']||(_0x46777f['color']=_0x25f2d7['createVertexBuffer']('color',_0x29e1d5,0x4),_0x29e1d5+=0x4),_0x46777f['direction']=_0x25f2d7['createVertexBuffer']('direction',_0x29e1d5,0x3),_0x29e1d5+=0x3,this['_isBillboardBased']||(_0x46777f['initialDirection']=_0x25f2d7['createVertexBuffer']('initialDirection',_0x29e1d5,0x3),_0x29e1d5+=0x3),this['_angularSpeedGradientsTexture']?(_0x46777f['angle']=_0x25f2d7['createVertexBuffer']('angle',_0x29e1d5,0x1),_0x29e1d5+=0x1):(_0x46777f['angle']=_0x25f2d7['createVertexBuffer']('angle',_0x29e1d5,0x2),_0x29e1d5+=0x2),this['_isAnimationSheetEnabled']&&(_0x46777f['cellIndex']=_0x25f2d7['createVertexBuffer']('cellIndex',_0x29e1d5,0x1),_0x29e1d5+=0x1,this['spriteRandomStartCell']&&(_0x46777f['cellStartOffset']=_0x25f2d7['createVertexBuffer']('cellStartOffset',_0x29e1d5,0x1),_0x29e1d5+=0x1)),this['noiseTexture']&&(_0x46777f['noiseCoordinates1']=_0x25f2d7['createVertexBuffer']('noiseCoordinates1',_0x29e1d5,0x3),_0x29e1d5+=0x3,_0x46777f['noiseCoordinates2']=_0x25f2d7['createVertexBuffer']('noiseCoordinates2',_0x29e1d5,0x3),_0x29e1d5+=0x3);var _0x3dc179=this['_engine']['recordVertexArrayObject'](_0x46777f,null,this['_updateEffect']);return this['_engine']['bindArrayBuffer'](null),_0x3dc179;},_0x2c3e1f['prototype']['_createRenderVAO']=function(_0x3c1e83,_0x57ac60){var _0x5d9c0c={};_0x5d9c0c['position']=_0x3c1e83['createVertexBuffer']('position',0x0,0x3,this['_attributesStrideSize'],!0x0);var _0x482b7f=0x3;this['particleEmitterType']instanceof _0x10a54c&&(_0x482b7f+=0x3),_0x5d9c0c['age']=_0x3c1e83['createVertexBuffer']('age',_0x482b7f,0x1,this['_attributesStrideSize'],!0x0),_0x482b7f+=0x1,_0x5d9c0c['life']=_0x3c1e83['createVertexBuffer']('life',_0x482b7f,0x1,this['_attributesStrideSize'],!0x0),_0x482b7f+=0x5,_0x5d9c0c['size']=_0x3c1e83['createVertexBuffer']('size',_0x482b7f,0x3,this['_attributesStrideSize'],!0x0),_0x482b7f+=0x3,this['_colorGradientsTexture']||(_0x5d9c0c['color']=_0x3c1e83['createVertexBuffer']('color',_0x482b7f,0x4,this['_attributesStrideSize'],!0x0),_0x482b7f+=0x4),this['billboardMode']===_0x4baa8b['BILLBOARDMODE_STRETCHED']&&(_0x5d9c0c['direction']=_0x3c1e83['createVertexBuffer']('direction',_0x482b7f,0x3,this['_attributesStrideSize'],!0x0)),_0x482b7f+=0x3,this['_isBillboardBased']||(_0x5d9c0c['initialDirection']=_0x3c1e83['createVertexBuffer']('initialDirection',_0x482b7f,0x3,this['_attributesStrideSize'],!0x0),_0x482b7f+=0x3),_0x5d9c0c['angle']=_0x3c1e83['createVertexBuffer']('angle',_0x482b7f,0x1,this['_attributesStrideSize'],!0x0),this['_angularSpeedGradientsTexture']?_0x482b7f++:_0x482b7f+=0x2,this['_isAnimationSheetEnabled']&&(_0x5d9c0c['cellIndex']=_0x3c1e83['createVertexBuffer']('cellIndex',_0x482b7f,0x1,this['_attributesStrideSize'],!0x0),_0x482b7f+=0x1,this['spriteRandomStartCell']&&(_0x5d9c0c['cellStartOffset']=_0x3c1e83['createVertexBuffer']('cellStartOffset',_0x482b7f,0x1,this['_attributesStrideSize'],!0x0),_0x482b7f+=0x1)),this['noiseTexture']&&(_0x5d9c0c['noiseCoordinates1']=_0x3c1e83['createVertexBuffer']('noiseCoordinates1',_0x482b7f,0x3,this['_attributesStrideSize'],!0x0),_0x482b7f+=0x3,_0x5d9c0c['noiseCoordinates2']=_0x3c1e83['createVertexBuffer']('noiseCoordinates2',_0x482b7f,0x3,this['_attributesStrideSize'],!0x0),_0x482b7f+=0x3),_0x5d9c0c['offset']=_0x57ac60['createVertexBuffer']('offset',0x0,0x2),_0x5d9c0c['uv']=_0x57ac60['createVertexBuffer']('uv',0x2,0x2);var _0x2249ad=this['_engine']['recordVertexArrayObject'](_0x5d9c0c,null,this['_getEffect']());return this['_engine']['bindArrayBuffer'](null),_0x2249ad;},_0x2c3e1f['prototype']['_initialize']=function(_0x4a5cb9){if(void 0x0===_0x4a5cb9&&(_0x4a5cb9=!0x1),!this['_buffer0']||_0x4a5cb9){var _0x57e879=this['_engine'],_0x397d3c=new Array();this['_attributesStrideSize']=0x15,this['_targetIndex']=0x0,this['particleEmitterType']instanceof _0x10a54c&&(this['_attributesStrideSize']+=0x3),this['isBillboardBased']||(this['_attributesStrideSize']+=0x3),this['_colorGradientsTexture']&&(this['_attributesStrideSize']-=0x4),this['_angularSpeedGradientsTexture']&&(this['_attributesStrideSize']-=0x1),this['_isAnimationSheetEnabled']&&(this['_attributesStrideSize']+=0x1,this['spriteRandomStartCell']&&(this['_attributesStrideSize']+=0x1)),this['noiseTexture']&&(this['_attributesStrideSize']+=0x6);for(var _0x1e52bc=this['particleEmitterType']instanceof _0x10a54c,_0x42ef8c=_0x74d525['c']['Vector3'][0x0],_0x104495=0x0;_0x104495=this['targetStopDuration']&&this['stop']();},_0x2c3e1f['prototype']['_createFactorGradientTexture']=function(_0x4e73ab,_0xf0dd9d){var _0x1918a3=this[_0xf0dd9d];if(_0x4e73ab&&_0x4e73ab['length']&&!_0x1918a3){for(var _0x4f343c=new Float32Array(this['_rawTextureWidth']),_0x55515b=0x0;_0x55515b0x1){var _0x4b07ca=0x0|this['_accumulatedCount'];this['_accumulatedCount']-=_0x4b07ca,this['_currentActiveCount']=Math['min'](this['_activeCount'],this['_currentActiveCount']+_0x4b07ca);}if(!this['_currentActiveCount'])return 0x0;this['_engine']['enableEffect'](this['_updateEffect']);var _0x49e1f4,_0x51ffaa=this['_engine'];if(!_0x51ffaa['setState'])throw new Error('GPU\x20particles\x20cannot\x20work\x20with\x20a\x20full\x20Engine.\x20ThinEngine\x20is\x20not\x20supported');if(this['_updateEffect']['setFloat']('currentCount',this['_currentActiveCount']),this['_updateEffect']['setFloat']('timeDelta',this['_timeDelta']),this['_updateEffect']['setFloat']('stopFactor',this['_stopped']?0x0:0x1),this['_updateEffect']['setTexture']('randomSampler',this['_randomTexture']),this['_updateEffect']['setTexture']('randomSampler2',this['_randomTexture2']),this['_updateEffect']['setFloat2']('lifeTime',this['minLifeTime'],this['maxLifeTime']),this['_updateEffect']['setFloat2']('emitPower',this['minEmitPower'],this['maxEmitPower']),this['_colorGradientsTexture']||(this['_updateEffect']['setDirectColor4']('color1',this['color1']),this['_updateEffect']['setDirectColor4']('color2',this['color2'])),this['_updateEffect']['setFloat2']('sizeRange',this['minSize'],this['maxSize']),this['_updateEffect']['setFloat4']('scaleRange',this['minScaleX'],this['maxScaleX'],this['minScaleY'],this['maxScaleY']),this['_updateEffect']['setFloat4']('angleRange',this['minAngularSpeed'],this['maxAngularSpeed'],this['minInitialRotation'],this['maxInitialRotation']),this['_updateEffect']['setVector3']('gravity',this['gravity']),this['_sizeGradientsTexture']&&this['_updateEffect']['setTexture']('sizeGradientSampler',this['_sizeGradientsTexture']),this['_angularSpeedGradientsTexture']&&this['_updateEffect']['setTexture']('angularSpeedGradientSampler',this['_angularSpeedGradientsTexture']),this['_velocityGradientsTexture']&&this['_updateEffect']['setTexture']('velocityGradientSampler',this['_velocityGradientsTexture']),this['_limitVelocityGradientsTexture']&&(this['_updateEffect']['setTexture']('limitVelocityGradientSampler',this['_limitVelocityGradientsTexture']),this['_updateEffect']['setFloat']('limitVelocityDamping',this['limitVelocityDamping'])),this['_dragGradientsTexture']&&this['_updateEffect']['setTexture']('dragGradientSampler',this['_dragGradientsTexture']),this['particleEmitterType']&&this['particleEmitterType']['applyToShader'](this['_updateEffect']),this['_isAnimationSheetEnabled']&&this['_updateEffect']['setFloat3']('cellInfos',this['startSpriteCellID'],this['endSpriteCellID'],this['spriteCellChangeSpeed']),this['noiseTexture']&&(this['_updateEffect']['setTexture']('noiseSampler',this['noiseTexture']),this['_updateEffect']['setVector3']('noiseStrength',this['noiseStrength'])),this['emitter']['position'])_0x49e1f4=this['emitter']['getWorldMatrix']();else{var _0x2ee374=this['emitter'];_0x49e1f4=_0x74d525['a']['Translation'](_0x2ee374['x'],_0x2ee374['y'],_0x2ee374['z']);}if(this['isLocal']||this['_updateEffect']['setMatrix']('emitterWM',_0x49e1f4),this['_engine']['bindVertexArrayObject'](this['_updateVAO'][this['_targetIndex']],null),_0x51ffaa['bindTransformFeedbackBuffer'](this['_targetBuffer']['getBuffer']()),_0x51ffaa['setRasterizerState'](!0x1),_0x51ffaa['beginTransformFeedback'](!0x0),_0x51ffaa['drawArraysType'](_0x2103ba['a']['MATERIAL_PointListDrawMode'],0x0,this['_currentActiveCount']),_0x51ffaa['endTransformFeedback'](),_0x51ffaa['setRasterizerState'](!0x0),_0x51ffaa['bindTransformFeedbackBuffer'](null),!_0x1be246){var _0x15ca09=this['_getEffect']();this['_engine']['enableEffect'](_0x15ca09);var _0x180d07=(null===(_0x44bfbb=this['_scene'])||void 0x0===_0x44bfbb?void 0x0:_0x44bfbb['getViewMatrix']())||_0x74d525['a']['IdentityReadOnly'];if(_0x15ca09['setMatrix']('view',_0x180d07),_0x15ca09['setMatrix']('projection',null!==(_0x4154b8=this['defaultProjectionMatrix'])&&void 0x0!==_0x4154b8?_0x4154b8:this['_scene']['getProjectionMatrix']()),_0x15ca09['setTexture']('diffuseSampler',this['particleTexture']),_0x15ca09['setVector2']('translationPivot',this['translationPivot']),_0x15ca09['setVector3']('worldOffset',this['worldOffset']),this['isLocal']&&_0x15ca09['setMatrix']('emitterWM',_0x49e1f4),this['_colorGradientsTexture']?_0x15ca09['setTexture']('colorGradientSampler',this['_colorGradientsTexture']):_0x15ca09['setDirectColor4']('colorDead',this['colorDead']),this['_isAnimationSheetEnabled']&&this['particleTexture']){var _0x4ddcaf=this['particleTexture']['getBaseSize']();_0x15ca09['setFloat3']('sheetInfos',this['spriteCellWidth']/_0x4ddcaf['width'],this['spriteCellHeight']/_0x4ddcaf['height'],_0x4ddcaf['width']/this['spriteCellWidth']);}if(this['_isBillboardBased']&&this['_scene']){var _0x3b3f1b=this['_scene']['activeCamera'];_0x15ca09['setVector3']('eyePosition',_0x3b3f1b['globalPosition']);}var _0x5ce3fe=_0x15ca09['defines'];if(this['_scene']&&(this['_scene']['clipPlane']||this['_scene']['clipPlane2']||this['_scene']['clipPlane3']||this['_scene']['clipPlane4']||this['_scene']['clipPlane5']||this['_scene']['clipPlane6'])&&_0x464f31['a']['BindClipPlane'](_0x15ca09,this['_scene']),_0x5ce3fe['indexOf']('#define\x20BILLBOARDMODE_ALL')>=0x0){var _0x1ea337=_0x180d07['clone']();_0x1ea337['invert'](),_0x15ca09['setMatrix']('invView',_0x1ea337);}switch(this['_imageProcessingConfiguration']&&!this['_imageProcessingConfiguration']['applyByPostProcess']&&this['_imageProcessingConfiguration']['bind'](_0x15ca09),this['blendMode']){case _0x4baa8b['BLENDMODE_ADD']:this['_engine']['setAlphaMode'](_0x2103ba['a']['ALPHA_ADD']);break;case _0x4baa8b['BLENDMODE_ONEONE']:this['_engine']['setAlphaMode'](_0x2103ba['a']['ALPHA_ONEONE']);break;case _0x4baa8b['BLENDMODE_STANDARD']:this['_engine']['setAlphaMode'](_0x2103ba['a']['ALPHA_COMBINE']);break;case _0x4baa8b['BLENDMODE_MULTIPLY']:this['_engine']['setAlphaMode'](_0x2103ba['a']['ALPHA_MULTIPLY']);}this['forceDepthWrite']&&_0x51ffaa['setDepthWrite'](!0x0),this['_engine']['bindVertexArrayObject'](this['_renderVAO'][this['_targetIndex']],null),this['_onBeforeDrawParticlesObservable']&&this['_onBeforeDrawParticlesObservable']['notifyObservers'](_0x15ca09),this['_engine']['drawArraysType'](_0x2103ba['a']['MATERIAL_TriangleFanDrawMode'],0x0,0x4,this['_currentActiveCount']),this['_engine']['setAlphaMode'](_0x2103ba['a']['ALPHA_DISABLE']);}this['_targetIndex']++,0x2===this['_targetIndex']&&(this['_targetIndex']=0x0);var _0xe5727f=this['_sourceBuffer'];return this['_sourceBuffer']=this['_targetBuffer'],this['_targetBuffer']=_0xe5727f,this['_currentActiveCount'];},_0x2c3e1f['prototype']['rebuild']=function(){this['_initialize'](!0x0);},_0x2c3e1f['prototype']['_releaseBuffers']=function(){this['_buffer0']&&(this['_buffer0']['dispose'](),this['_buffer0']=null),this['_buffer1']&&(this['_buffer1']['dispose'](),this['_buffer1']=null),this['_spriteBuffer']&&(this['_spriteBuffer']['dispose'](),this['_spriteBuffer']=null);},_0x2c3e1f['prototype']['_releaseVAOs']=function(){if(this['_updateVAO']){for(var _0xe5e975=0x0;_0xe5e975-0x1&&this['_scene']['particleSystems']['splice'](_0x8237a1,0x1);}this['_releaseBuffers'](),this['_releaseVAOs'](),this['_colorGradientsTexture']&&(this['_colorGradientsTexture']['dispose'](),this['_colorGradientsTexture']=null),this['_sizeGradientsTexture']&&(this['_sizeGradientsTexture']['dispose'](),this['_sizeGradientsTexture']=null),this['_angularSpeedGradientsTexture']&&(this['_angularSpeedGradientsTexture']['dispose'](),this['_angularSpeedGradientsTexture']=null),this['_velocityGradientsTexture']&&(this['_velocityGradientsTexture']['dispose'](),this['_velocityGradientsTexture']=null),this['_limitVelocityGradientsTexture']&&(this['_limitVelocityGradientsTexture']['dispose'](),this['_limitVelocityGradientsTexture']=null),this['_dragGradientsTexture']&&(this['_dragGradientsTexture']['dispose'](),this['_dragGradientsTexture']=null),this['_randomTexture']&&(this['_randomTexture']['dispose'](),this['_randomTexture']=null),this['_randomTexture2']&&(this['_randomTexture2']['dispose'](),this['_randomTexture2']=null),_0xbe1712&&this['particleTexture']&&(this['particleTexture']['dispose'](),this['particleTexture']=null),_0xbe1712&&this['noiseTexture']&&(this['noiseTexture']['dispose'](),this['noiseTexture']=null),this['onStoppedObservable']['clear'](),this['onDisposeObservable']['notifyObservers'](this),this['onDisposeObservable']['clear']();},_0x2c3e1f['prototype']['clone']=function(_0x4c0078,_0x4fa6fa){var _0x219c0a=this['serialize'](),_0x5135c6=_0x2c3e1f['Parse'](_0x219c0a,this['_scene']||this['_engine'],''),_0x37891a=Object(_0x18e13d['a'])({},this['_customEffect']);return _0x5135c6['name']=_0x4c0078,_0x5135c6['_customEffect']=_0x37891a,void 0x0===_0x4fa6fa&&(_0x4fa6fa=this['emitter']),_0x5135c6['emitter']=_0x4fa6fa,_0x5135c6['noiseTexture']=this['noiseTexture'],_0x5135c6;},_0x2c3e1f['prototype']['serialize']=function(_0x20cf71){void 0x0===_0x20cf71&&(_0x20cf71=!0x1);var _0x4a6d0b={};return _0x4baa8b['_Serialize'](_0x4a6d0b,this,_0x20cf71),_0x4a6d0b['activeParticleCount']=this['activeParticleCount'],_0x4a6d0b['randomTextureSize']=this['_randomTextureSize'],_0x4a6d0b;},_0x2c3e1f['Parse']=function(_0x421972,_0x5b76bd,_0x3c8b18,_0x33f5e6){void 0x0===_0x33f5e6&&(_0x33f5e6=!0x1);var _0x39d18e=new _0x2c3e1f(_0x421972['name'],{'capacity':_0x421972['capacity'],'randomTextureSize':_0x421972['randomTextureSize']},_0x5b76bd);return _0x421972['activeParticleCount']&&(_0x39d18e['activeParticleCount']=_0x421972['activeParticleCount']),_0x4baa8b['_Parse'](_0x421972,_0x39d18e,_0x5b76bd,_0x3c8b18),_0x421972['preventAutoStart']&&(_0x39d18e['preventAutoStart']=_0x421972['preventAutoStart']),_0x33f5e6||_0x39d18e['preventAutoStart']||_0x39d18e['start'](),_0x39d18e;},_0x2c3e1f;}(_0x2e1395),_0x3dbb28=(function(){function _0x42d8eb(){this['systems']=new Array();}return Object['defineProperty'](_0x42d8eb['prototype'],'emitterNode',{'get':function(){return this['_emitterNode'];},'enumerable':!0x1,'configurable':!0x0}),_0x42d8eb['prototype']['setEmitterAsSphere']=function(_0x3146df,_0x4bd979,_0x4e25f4){this['_emitterNode']&&this['_emitterNode']['dispose'](),this['_emitterCreationOptions']={'kind':'Sphere','options':_0x3146df,'renderingGroupId':_0x4bd979};var _0x3dc8fc=_0x5c4f8d['a']['CreateSphere']('emitterSphere',{'diameter':_0x3146df['diameter'],'segments':_0x3146df['segments']},_0x4e25f4);_0x3dc8fc['renderingGroupId']=_0x4bd979;var _0xd85f7b=new _0x5905ab['a']('emitterSphereMaterial',_0x4e25f4);_0xd85f7b['emissiveColor']=_0x3146df['color'],_0x3dc8fc['material']=_0xd85f7b;for(var _0x3c679c=0x0,_0x54c404=this['systems'];_0x3c679c<_0x54c404['length'];_0x3c679c++){_0x54c404[_0x3c679c]['emitter']=_0x3dc8fc;}this['_emitterNode']=_0x3dc8fc;},_0x42d8eb['prototype']['start']=function(_0x6f8230){for(var _0x165a21=0x0,_0x29740c=this['systems'];_0x165a21<_0x29740c['length'];_0x165a21++){var _0x230bae=_0x29740c[_0x165a21];_0x6f8230&&(_0x230bae['emitter']=_0x6f8230),_0x230bae['start']();}},_0x42d8eb['prototype']['dispose']=function(){for(var _0x435413=0x0,_0x3a4455=this['systems'];_0x435413<_0x3a4455['length'];_0x435413++){_0x3a4455[_0x435413]['dispose']();}this['systems']=[],this['_emitterNode']&&(this['_emitterNode']['dispose'](),this['_emitterNode']=null);},_0x42d8eb['prototype']['serialize']=function(_0x56edfd){void 0x0===_0x56edfd&&(_0x56edfd=!0x1);for(var _0x427a41={'systems':[]},_0xf6c86e=0x0,_0x199f2a=this['systems'];_0xf6c86e<_0x199f2a['length'];_0xf6c86e++){var _0x568428=_0x199f2a[_0xf6c86e];_0x427a41['systems']['push'](_0x568428['serialize'](_0x56edfd));}return this['_emitterNode']&&(_0x427a41['emitter']=this['_emitterCreationOptions']),_0x427a41;},_0x42d8eb['Parse']=function(_0x418e71,_0x1992a9,_0x44fb7d){void 0x0===_0x44fb7d&&(_0x44fb7d=!0x1);var _0x348780=new _0x42d8eb(),_0x54def8=this['BaseAssetsUrl']+'/textures/';_0x1992a9=_0x1992a9||_0x44b9ce['a']['LastCreatedScene'];for(var _0xc63510=0x0,_0x55365d=_0x418e71['systems'];_0xc63510<_0x55365d['length'];_0xc63510++){var _0x462297=_0x55365d[_0xc63510];_0x348780['systems']['push'](_0x44fb7d?_0x478f32['Parse'](_0x462297,_0x1992a9,_0x54def8,!0x0):_0x4baa8b['Parse'](_0x462297,_0x1992a9,_0x54def8,!0x0));}if(_0x418e71['emitter']){var _0x351382=_0x418e71['emitter']['options'];switch(_0x418e71['emitter']['kind']){case'Sphere':_0x348780['setEmitterAsSphere']({'diameter':_0x351382['diameter'],'segments':_0x351382['segments'],'color':_0x39310d['a']['FromArray'](_0x351382['color'])},_0x418e71['emitter']['renderingGroupId'],_0x1992a9);}}return _0x348780;},_0x42d8eb['BaseAssetsUrl']='https://assets.babylonjs.com/particles',_0x42d8eb;}()),_0x1d5a32=(function(){function _0x3e63a5(){}return _0x3e63a5['CreateDefault']=function(_0x15bf6d,_0x652079,_0x11f126,_0x126399){var _0x2fd58f;return void 0x0===_0x652079&&(_0x652079=0x1f4),void 0x0===_0x126399&&(_0x126399=!0x1),(_0x2fd58f=_0x126399?new _0x478f32('default\x20system',{'capacity':_0x652079},_0x11f126):new _0x4baa8b('default\x20system',_0x652079,_0x11f126))['emitter']=_0x15bf6d,_0x2fd58f['particleTexture']=new _0xaf3c80['a']('https://www.babylonjs.com/assets/Flare.png',_0x2fd58f['getScene']()),_0x2fd58f['createConeEmitter'](0.1,Math['PI']/0x4),_0x2fd58f['color1']=new _0x39310d['b'](0x1,0x1,0x1,0x1),_0x2fd58f['color2']=new _0x39310d['b'](0x1,0x1,0x1,0x1),_0x2fd58f['colorDead']=new _0x39310d['b'](0x1,0x1,0x1,0x0),_0x2fd58f['minSize']=0.1,_0x2fd58f['maxSize']=0.1,_0x2fd58f['minEmitPower']=0x2,_0x2fd58f['maxEmitPower']=0x2,_0x2fd58f['updateSpeed']=0x1/0x3c,_0x2fd58f['emitRate']=0x1e,_0x2fd58f;},_0x3e63a5['CreateAsync']=function(_0x54a8a3,_0x5c96d0,_0x15793b){void 0x0===_0x15793b&&(_0x15793b=!0x1),_0x5c96d0||(_0x5c96d0=_0x44b9ce['a']['LastCreatedScene']);var _0x4390e4={};return _0x5c96d0['_addPendingData'](_0x4390e4),new Promise(function(_0x57eccb,_0x433083){if(_0x15793b&&!_0x478f32['IsSupported'])return _0x5c96d0['_removePendingData'](_0x4390e4),_0x433083('Particle\x20system\x20with\x20GPU\x20is\x20not\x20supported.');_0x5d754c['b']['LoadFile'](_0x3e63a5['BaseAssetsUrl']+'/systems/'+_0x54a8a3+'.json',function(_0x4f19d6){_0x5c96d0['_removePendingData'](_0x4390e4);var _0x3d6991=JSON['parse'](_0x4f19d6['toString']());return _0x57eccb(_0x3dbb28['Parse'](_0x3d6991,_0x5c96d0,_0x15793b));},void 0x0,void 0x0,void 0x0,function(){return _0x5c96d0['_removePendingData'](_0x4390e4),_0x433083('An\x20error\x20occured\x20while\x20the\x20creation\x20of\x20your\x20particle\x20system.\x20Check\x20if\x20your\x20type\x20\x27'+_0x54a8a3+'\x27\x20exists.');});});},_0x3e63a5['ExportSet']=function(_0x3bdd7d){for(var _0xb741bf=new _0x3dbb28(),_0x56460a=0x0,_0x4d5652=_0x3bdd7d;_0x56460a<_0x4d5652['length'];_0x56460a++){var _0x5d8e52=_0x4d5652[_0x56460a];_0xb741bf['systems']['push'](_0x5d8e52);}return _0xb741bf;},_0x3e63a5['ParseFromFileAsync']=function(_0x20973d,_0x353de9,_0x4ad233,_0x3c9183,_0x4ea717){return void 0x0===_0x3c9183&&(_0x3c9183=!0x1),void 0x0===_0x4ea717&&(_0x4ea717=''),new Promise(function(_0x1b6a65,_0x3ee2b3){var _0x1c7fb9=new _0x25cf22['a']();_0x1c7fb9['addEventListener']('readystatechange',function(){if(0x4==_0x1c7fb9['readyState']){if(0xc8==_0x1c7fb9['status']){var _0x50e582=JSON['parse'](_0x1c7fb9['responseText']),_0xbab7a6=void 0x0;_0xbab7a6=_0x3c9183?_0x478f32['Parse'](_0x50e582,_0x4ad233,_0x4ea717):_0x4baa8b['Parse'](_0x50e582,_0x4ad233,_0x4ea717),_0x20973d&&(_0xbab7a6['name']=_0x20973d),_0x1b6a65(_0xbab7a6);}else _0x3ee2b3('Unable\x20to\x20load\x20the\x20particle\x20system');}}),_0x1c7fb9['open']('GET',_0x353de9),_0x1c7fb9['send']();});},_0x3e63a5['CreateFromSnippetAsync']=function(_0x34ddaa,_0x53246e,_0x22bd98,_0x5a5f5e){var _0x2aea8e=this;if(void 0x0===_0x22bd98&&(_0x22bd98=!0x1),void 0x0===_0x5a5f5e&&(_0x5a5f5e=''),'_BLANK'===_0x34ddaa){var _0x1a0c03=this['CreateDefault'](null);return _0x1a0c03['start'](),Promise['resolve'](_0x1a0c03);}return new Promise(function(_0x53d402,_0x4d3563){var _0x152cdd=new _0x25cf22['a']();_0x152cdd['addEventListener']('readystatechange',function(){if(0x4==_0x152cdd['readyState']){if(0xc8==_0x152cdd['status']){var _0x1749a8=JSON['parse'](JSON['parse'](_0x152cdd['responseText'])['jsonPayload']),_0x7f2421=JSON['parse'](_0x1749a8['particleSystem']),_0x5693f4=void 0x0;(_0x5693f4=_0x22bd98?_0x478f32['Parse'](_0x7f2421,_0x53246e,_0x5a5f5e):_0x4baa8b['Parse'](_0x7f2421,_0x53246e,_0x5a5f5e))['snippetId']=_0x34ddaa,_0x53d402(_0x5693f4);}else _0x4d3563('Unable\x20to\x20load\x20the\x20snippet\x20'+_0x34ddaa);}}),_0x152cdd['open']('GET',_0x2aea8e['SnippetUrl']+'/'+_0x34ddaa['replace'](/#/g,'/')),_0x152cdd['send']();});},_0x3e63a5['BaseAssetsUrl']=_0x3dbb28['BaseAssetsUrl'],_0x3e63a5['SnippetUrl']='https://snippet.babylonjs.com',_0x3e63a5;}());_0x3598db['a']['AddParser'](_0x384de3['a']['NAME_PARTICLESYSTEM'],function(_0x2efafc,_0x86a8c5,_0xd33ae,_0x50203f){var _0x4ff040=_0x3598db['a']['GetIndividualParser'](_0x384de3['a']['NAME_PARTICLESYSTEM']);if(_0x4ff040&&void 0x0!==_0x2efafc['particleSystems']&&null!==_0x2efafc['particleSystems'])for(var _0x4ac785=0x0,_0xfa11d7=_0x2efafc['particleSystems']['length'];_0x4ac785<_0xfa11d7;_0x4ac785++){var _0x4967c0=_0x2efafc['particleSystems'][_0x4ac785];_0xd33ae['particleSystems']['push'](_0x4ff040(_0x4967c0,_0x86a8c5,_0x50203f));}}),_0x3598db['a']['AddIndividualParser'](_0x384de3['a']['NAME_PARTICLESYSTEM'],function(_0x19fbf3,_0x145d27,_0x4e49b9){return _0x19fbf3['activeParticleCount']?_0x478f32['Parse'](_0x19fbf3,_0x145d27,_0x4e49b9):_0x4baa8b['Parse'](_0x19fbf3,_0x145d27,_0x4e49b9);}),_0x300b38['a']['prototype']['createEffectForParticles']=function(_0x52ce77,_0x2b8765,_0x74a922,_0x5bf985,_0x59a35f,_0x30a881,_0x314ea1,_0x23f67e){var _0x810fa2;void 0x0===_0x2b8765&&(_0x2b8765=[]),void 0x0===_0x74a922&&(_0x74a922=[]),void 0x0===_0x5bf985&&(_0x5bf985='');var _0x1960c2=[],_0xcd0108=[],_0x1ddcf3=[];return _0x23f67e?_0x23f67e['fillUniformsAttributesAndSamplerNames'](_0xcd0108,_0x1960c2,_0x1ddcf3):(_0x1960c2=_0x4baa8b['_GetAttributeNamesOrOptions'](),_0xcd0108=_0x4baa8b['_GetEffectCreationOptions']()),-0x1===_0x5bf985['indexOf']('\x20BILLBOARD')&&(_0x5bf985+='\x0a#define\x20BILLBOARD\x0a'),-0x1===_0x74a922['indexOf']('diffuseSampler')&&_0x74a922['push']('diffuseSampler'),this['createEffect']({'vertex':null!==(_0x810fa2=null==_0x23f67e?void 0x0:_0x23f67e['vertexShaderName'])&&void 0x0!==_0x810fa2?_0x810fa2:'particles','fragmentElement':_0x52ce77},_0x1960c2,_0xcd0108['concat'](_0x2b8765),_0x1ddcf3['concat'](_0x74a922),_0x5bf985,_0x59a35f,_0x30a881,_0x314ea1);},_0x3cf5e5['a']['prototype']['getEmittedParticleSystems']=function(){for(var _0x59168b=new Array(),_0x1b1125=0x0;_0x1b11250x0&&_0x16b29d['set'](this['_uvs32'],_0x212fbd['b']['UVKind']),this['_colors32']['length']>0x0&&_0x16b29d['set'](this['_colors32'],_0x212fbd['b']['ColorKind']),_0x16b29d['applyToMesh'](this['mesh'],this['_updatable']),this['mesh']['isPickable']=this['_pickable'],this['_pickable']){for(var _0x53dd4b=0x0,_0x26a4f8=0x0;_0x26a4f8_0x31f8af?_0x31f8af:_0x426dae,_0x9cd47e=Math['round'](_0x31f8af/_0x426dae),_0x534caa=0x0):_0x9cd47e=_0x9cd47e>_0x31f8af?_0x31f8af:_0x9cd47e;for(var _0x2f02fd=[],_0x53d4fc=[],_0x9e8508=[],_0x46591a=[],_0x6c66fa=[],_0x59eb9e=_0x74d525['e']['Zero'](),_0x2a553e=_0x9cd47e;_0x26ece3<_0x31f8af;){_0x26ece3>_0x31f8af-(_0x9cd47e=_0x2a553e+Math['floor']((0x1+_0x534caa)*Math['random']()))&&(_0x9cd47e=_0x31f8af-_0x26ece3),_0x2f02fd['length']=0x0,_0x53d4fc['length']=0x0,_0x9e8508['length']=0x0,_0x46591a['length']=0x0,_0x6c66fa['length']=0x0;for(var _0x2acb3f=0x0,_0x538bf5=0x3*_0x26ece3;_0x538bf5<0x3*(_0x26ece3+_0x9cd47e);_0x538bf5++){_0x9e8508['push'](_0x2acb3f);var _0x468846=_0x3c6aa1[_0x538bf5],_0x203b78=0x3*_0x468846;if(_0x2f02fd['push'](_0x3b0e51[_0x203b78],_0x3b0e51[_0x203b78+0x1],_0x3b0e51[_0x203b78+0x2]),_0x53d4fc['push'](_0x372b9b[_0x203b78],_0x372b9b[_0x203b78+0x1],_0x372b9b[_0x203b78+0x2]),_0x44a202){var _0x56dbc7=0x2*_0x468846;_0x46591a['push'](_0x44a202[_0x56dbc7],_0x44a202[_0x56dbc7+0x1]);}if(_0x53ff82){var _0xc53e32=0x4*_0x468846;_0x6c66fa['push'](_0x53ff82[_0xc53e32],_0x53ff82[_0xc53e32+0x1],_0x53ff82[_0xc53e32+0x2],_0x53ff82[_0xc53e32+0x3]);}_0x2acb3f++;}var _0x5979c5,_0x332112=this['nbParticles'],_0x40cfa9=this['_posToShape'](_0x2f02fd),_0x55c622=this['_uvsToShapeUV'](_0x46591a),_0x329172=_0x5d754c['b']['Slice'](_0x9e8508),_0x523a57=_0x5d754c['b']['Slice'](_0x6c66fa),_0x3f3a44=_0x5d754c['b']['Slice'](_0x53d4fc);for(_0x59eb9e['copyFromFloats'](0x0,0x0,0x0),_0x5979c5=0x0;_0x5979c5<_0x40cfa9['length'];_0x5979c5++)_0x59eb9e['addInPlace'](_0x40cfa9[_0x5979c5]);_0x59eb9e['scaleInPlace'](0x1/_0x40cfa9['length']);var _0xa5f750,_0x1eaff1=new _0x74d525['e'](0x1/0x0,0x1/0x0,0x1/0x0),_0x19417e=new _0x74d525['e'](-0x1/0x0,-0x1/0x0,-0x1/0x0);for(_0x5979c5=0x0;_0x5979c5<_0x40cfa9['length'];_0x5979c5++)_0x40cfa9[_0x5979c5]['subtractInPlace'](_0x59eb9e),_0x1eaff1['minimizeInPlaceFromFloats'](_0x40cfa9[_0x5979c5]['x'],_0x40cfa9[_0x5979c5]['y'],_0x40cfa9[_0x5979c5]['z']),_0x19417e['maximizeInPlaceFromFloats'](_0x40cfa9[_0x5979c5]['x'],_0x40cfa9[_0x5979c5]['y'],_0x40cfa9[_0x5979c5]['z']);this['_particlesIntersect']&&(_0xa5f750=new _0x386a4b['a'](_0x1eaff1,_0x19417e));var _0x2b7206=null;this['_useModelMaterial']&&(_0x2b7206=_0x5bf335['material']?_0x5bf335['material']:this['_setDefaultMaterial']());var _0x39b4ab=new _0x117754(this['_shapeCounter'],_0x40cfa9,_0x329172,_0x3f3a44,_0x523a57,_0x55c622,null,null,_0x2b7206),_0x566baa=this['_positions']['length'],_0x38ffbc=this['_indices']['length'];this['_meshBuilder'](this['_index'],_0x38ffbc,_0x40cfa9,this['_positions'],_0x329172,this['_indices'],_0x46591a,this['_uvs'],_0x523a57,this['_colors'],_0x3f3a44,this['_normals'],_0x332112,0x0,null,_0x39b4ab),this['_addParticle'](_0x332112,this['_lastParticleId'],_0x566baa,_0x38ffbc,_0x39b4ab,this['_shapeCounter'],0x0,_0xa5f750,_0x4ef30f),this['particles'][this['nbParticles']]['position']['addInPlace'](_0x59eb9e),_0x4ef30f||(this['_index']+=_0x40cfa9['length'],_0x332112++,this['nbParticles']++,this['_lastParticleId']++),this['_shapeCounter']++,_0x26ece3+=_0x9cd47e;}return this['_isNotBuilt']=!0x0,this;},_0x51e074['prototype']['_unrotateFixedNormals']=function(){for(var _0x5d37b4=0x0,_0x351127=0x0,_0x33b43d=_0x74d525['c']['Vector3'][0x0],_0x3b7da7=_0x74d525['c']['Quaternion'][0x0],_0x52b821=_0x74d525['c']['Matrix'][0x0],_0x2268e1=0x0;_0x2268e10xffff&&(this['_needs32Bits']=!0x0);}if(this['_depthSort']||this['_multimaterialEnabled']){var _0x503c84=null!==_0x33aeb9['materialIndex']?_0x33aeb9['materialIndex']:0x0;this['depthSortedParticles']['push'](new _0x1c1fcf(_0x2370d8,_0x5018a2,_0xc7e1dc['length'],_0x503c84));}return _0x33aeb9;},_0x51e074['prototype']['_posToShape']=function(_0x516844){for(var _0x113ba8=[],_0x2cc409=0x0;_0x2cc409<_0x516844['length'];_0x2cc409+=0x3)_0x113ba8['push'](_0x74d525['e']['FromArray'](_0x516844,_0x2cc409));return _0x113ba8;},_0x51e074['prototype']['_uvsToShapeUV']=function(_0x1fbc81){var _0x5a404a=[];if(_0x1fbc81){for(var _0x3272f9=0x0;_0x3272f9<_0x1fbc81['length'];_0x3272f9++)_0x5a404a['push'](_0x1fbc81[_0x3272f9]);}return _0x5a404a;},_0x51e074['prototype']['_addParticle']=function(_0x277628,_0x6f7611,_0x1aa56a,_0x545d37,_0x26d623,_0x54ee9d,_0x3c5e80,_0x18a6e6,_0x5afa2c){void 0x0===_0x18a6e6&&(_0x18a6e6=null),void 0x0===_0x5afa2c&&(_0x5afa2c=null);var _0xe79130=new _0x51d7cc(_0x277628,_0x6f7611,_0x1aa56a,_0x545d37,_0x26d623,_0x54ee9d,_0x3c5e80,this,_0x18a6e6);return(_0x5afa2c||this['particles'])['push'](_0xe79130),_0xe79130;},_0x51e074['prototype']['addShape']=function(_0x282760,_0x155a48,_0x42d629){var _0x5427db=_0x282760['getVerticesData'](_0x212fbd['b']['PositionKind']),_0x540923=_0x282760['getIndices'](),_0xf290a3=_0x282760['getVerticesData'](_0x212fbd['b']['UVKind']),_0x473d81=_0x282760['getVerticesData'](_0x212fbd['b']['ColorKind']),_0x3508fe=_0x282760['getVerticesData'](_0x212fbd['b']['NormalKind']);this['recomputeNormals']=!_0x3508fe;var _0x4d8d65=_0x5d754c['b']['SliceToArray'](_0x540923),_0x1f4fa3=_0x5d754c['b']['SliceToArray'](_0x3508fe),_0xe72a68=_0x473d81?_0x5d754c['b']['SliceToArray'](_0x473d81):[],_0xb59ae7=_0x42d629&&_0x42d629['storage']?_0x42d629['storage']:null,_0x4b2732=null;this['_particlesIntersect']&&(_0x4b2732=_0x282760['getBoundingInfo']());var _0x2ad8e8=this['_posToShape'](_0x5427db),_0x17fb26=this['_uvsToShapeUV'](_0xf290a3),_0x16835d=_0x42d629?_0x42d629['positionFunction']:null,_0x4fb89d=_0x42d629?_0x42d629['vertexFunction']:null,_0x35587f=null;this['_useModelMaterial']&&(_0x35587f=_0x282760['material']?_0x282760['material']:this['_setDefaultMaterial']());for(var _0x4f52da=new _0x117754(this['_shapeCounter'],_0x2ad8e8,_0x4d8d65,_0x1f4fa3,_0xe72a68,_0x17fb26,_0x16835d,_0x4fb89d,_0x35587f),_0x4a021f=0x0;_0x4a021f<_0x155a48;_0x4a021f++)this['_insertNewParticle'](this['nbParticles'],_0x4a021f,_0x4f52da,_0x2ad8e8,_0x540923,_0xf290a3,_0x473d81,_0x3508fe,_0x4b2732,_0xb59ae7,_0x42d629);return this['_shapeCounter']++,this['_isNotBuilt']=!0x0,this['_shapeCounter']-0x1;},_0x51e074['prototype']['_rebuildParticle']=function(_0x2adf67,_0x2275f6){void 0x0===_0x2275f6&&(_0x2275f6=!0x1),this['_resetCopy']();var _0x147b47=this['_copy'];_0x2adf67['_model']['_positionFunction']&&_0x2adf67['_model']['_positionFunction'](_0x147b47,_0x2adf67['idx'],_0x2adf67['idxInShape']);var _0x5ee81a=_0x74d525['c']['Matrix'][0x0],_0x2c240a=_0x74d525['c']['Vector3'][0x0],_0x193366=_0x74d525['c']['Vector3'][0x1],_0x14e89c=_0x74d525['c']['Vector3'][0x2],_0x4ca0da=_0x74d525['c']['Vector3'][0x3];_0x147b47['getRotationMatrix'](_0x5ee81a),_0x2adf67['pivot']['multiplyToRef'](_0x2adf67['scaling'],_0x4ca0da),_0x147b47['translateFromPivot']?_0x14e89c['copyFromFloats'](0x0,0x0,0x0):_0x14e89c['copyFrom'](_0x4ca0da);for(var _0x559676=_0x2adf67['_model']['_shape'],_0x2b041c=0x0;_0x2b041c<_0x559676['length'];_0x2b041c++)_0x2c240a['copyFrom'](_0x559676[_0x2b041c]),_0x2adf67['_model']['_vertexFunction']&&_0x2adf67['_model']['_vertexFunction'](_0x147b47,_0x2c240a,_0x2b041c),_0x2c240a['multiplyInPlace'](_0x147b47['scaling'])['subtractInPlace'](_0x4ca0da),_0x74d525['e']['TransformCoordinatesToRef'](_0x2c240a,_0x5ee81a,_0x193366),_0x193366['addInPlace'](_0x14e89c)['addInPlace'](_0x147b47['position'])['toArray'](this['_positions32'],_0x2adf67['_pos']+0x3*_0x2b041c);_0x2275f6&&(_0x2adf67['position']['setAll'](0x0),_0x2adf67['rotation']['setAll'](0x0),_0x2adf67['rotationQuaternion']=null,_0x2adf67['scaling']['setAll'](0x1),_0x2adf67['uvs']['setAll'](0x0),_0x2adf67['pivot']['setAll'](0x0),_0x2adf67['translateFromPivot']=!0x1,_0x2adf67['parentId']=null);},_0x51e074['prototype']['rebuildMesh']=function(_0x451d27){void 0x0===_0x451d27&&(_0x451d27=!0x1);for(var _0x2697a5=0x0;_0x2697a5=this['nbParticles']||!this['_updatable'])return[];var _0x1c829d=this['particles'],_0x229a66=this['nbParticles'];if(_0x4bf7c8<_0x229a66-0x1)for(var _0x4237d9=_0x4bf7c8+0x1,_0x1a7882=_0x1c829d[_0x4237d9]['_pos']-_0x1c829d[_0x2d6475]['_pos'],_0xe4921c=_0x1c829d[_0x4237d9]['_ind']-_0x1c829d[_0x2d6475]['_ind'],_0x264977=_0x4237d9;_0x264977<_0x229a66;_0x264977++){var _0x559f39=_0x1c829d[_0x264977];_0x559f39['_pos']-=_0x1a7882,_0x559f39['_ind']-=_0xe4921c;}var _0x593989=_0x1c829d['splice'](_0x2d6475,_0x1917b1);this['_positions']['length']=0x0,this['_indices']['length']=0x0,this['_colors']['length']=0x0,this['_uvs']['length']=0x0,this['_normals']['length']=0x0,this['_index']=0x0,this['_idxOfId']['length']=0x0,(this['_depthSort']||this['_multimaterialEnabled'])&&(this['depthSortedParticles']=[]);for(var _0x5b8e3c=0x0,_0x3c6e16=_0x1c829d['length'],_0x23971b=0x0;_0x23971b<_0x3c6e16;_0x23971b++){var _0x24ebff=_0x1c829d[_0x23971b],_0x49cec4=_0x24ebff['_model'],_0xad8126=_0x49cec4['_shape'],_0x1d09cb=_0x49cec4['_indices'],_0x2cc3c7=_0x49cec4['_normals'],_0x424a44=_0x49cec4['_shapeColors'],_0x56d1ad=_0x49cec4['_shapeUV'];_0x24ebff['idx']=_0x23971b,this['_idxOfId'][_0x24ebff['id']]=_0x23971b,this['_meshBuilder'](this['_index'],_0x5b8e3c,_0xad8126,this['_positions'],_0x1d09cb,this['_indices'],_0x56d1ad,this['_uvs'],_0x424a44,this['_colors'],_0x2cc3c7,this['_normals'],_0x24ebff['idx'],_0x24ebff['idxInShape'],null,_0x49cec4),this['_index']+=_0xad8126['length'],_0x5b8e3c+=_0x1d09cb['length'];}return this['nbParticles']-=_0x1917b1,this['_isNotBuilt']=!0x0,_0x593989;},_0x51e074['prototype']['insertParticlesFromArray']=function(_0x22e491){if(!this['_expandable'])return this;for(var _0x362955=0x0,_0x5afca3=_0x22e491[0x0]['shapeId'],_0x1070f0=_0x22e491['length'],_0x432fb4=0x0;_0x432fb4<_0x1070f0;_0x432fb4++){var _0x2e1f29=_0x22e491[_0x432fb4],_0x51a908=_0x2e1f29['_model'],_0x375f26=_0x51a908['_shape'],_0x12138d=_0x51a908['_indices'],_0x4e05b6=_0x51a908['_shapeUV'],_0x166dbf=_0x51a908['_shapeColors'],_0x3ce81d=_0x51a908['_normals'],_0x32f72c=!_0x3ce81d;this['recomputeNormals']=_0x32f72c||this['recomputeNormals'];var _0x2ad328=_0x2e1f29['_boundingInfo'],_0x58e0fe=this['_insertNewParticle'](this['nbParticles'],_0x362955,_0x51a908,_0x375f26,_0x12138d,_0x4e05b6,_0x166dbf,_0x3ce81d,_0x2ad328,null,null);_0x2e1f29['copyToRef'](_0x58e0fe),_0x362955++,_0x5afca3!=_0x2e1f29['shapeId']&&(_0x5afca3=_0x2e1f29['shapeId'],_0x362955=0x0);}return this['_isNotBuilt']=!0x0,this;},_0x51e074['prototype']['_insertNewParticle']=function(_0x1bd4f0,_0x3faa69,_0x42540d,_0x460172,_0x40b908,_0x4c0347,_0x90e83e,_0xcbcf70,_0x110f3a,_0x41c702,_0x3316ec){var _0x5b45ca=this['_positions']['length'],_0x5bcc12=this['_indices']['length'],_0x274511=this['_meshBuilder'](this['_index'],_0x5bcc12,_0x460172,this['_positions'],_0x40b908,this['_indices'],_0x4c0347,this['_uvs'],_0x90e83e,this['_colors'],_0xcbcf70,this['_normals'],_0x1bd4f0,_0x3faa69,_0x3316ec,_0x42540d),_0x3232ac=null;return this['_updatable']&&((_0x3232ac=this['_addParticle'](this['nbParticles'],this['_lastParticleId'],_0x5b45ca,_0x5bcc12,_0x42540d,this['_shapeCounter'],_0x3faa69,_0x110f3a,_0x41c702))['position']['copyFrom'](_0x274511['position']),_0x3232ac['rotation']['copyFrom'](_0x274511['rotation']),_0x274511['rotationQuaternion']&&(_0x3232ac['rotationQuaternion']?_0x3232ac['rotationQuaternion']['copyFrom'](_0x274511['rotationQuaternion']):_0x3232ac['rotationQuaternion']=_0x274511['rotationQuaternion']['clone']()),_0x274511['color']&&(_0x3232ac['color']?_0x3232ac['color']['copyFrom'](_0x274511['color']):_0x3232ac['color']=_0x274511['color']['clone']()),_0x3232ac['scaling']['copyFrom'](_0x274511['scaling']),_0x3232ac['uvs']['copyFrom'](_0x274511['uvs']),null!==_0x274511['materialIndex']&&(_0x3232ac['materialIndex']=_0x274511['materialIndex']),this['expandable']&&(this['_idxOfId'][_0x3232ac['id']]=_0x3232ac['idx'])),_0x41c702||(this['_index']+=_0x460172['length'],this['nbParticles']++,this['_lastParticleId']++),_0x3232ac;},_0x51e074['prototype']['setParticles']=function(_0x408916,_0x558929,_0x3fdb63){if(void 0x0===_0x408916&&(_0x408916=0x0),void 0x0===_0x558929&&(_0x558929=this['nbParticles']-0x1),void 0x0===_0x3fdb63&&(_0x3fdb63=!0x0),!this['_updatable']||this['_isNotBuilt'])return this;this['beforeUpdateParticles'](_0x408916,_0x558929,_0x3fdb63);var _0x296e30=_0x74d525['c']['Matrix'][0x0],_0x37554b=_0x74d525['c']['Matrix'][0x1],_0x3351c8=this['mesh'],_0x120b51=this['_colors32'],_0x18298c=this['_positions32'],_0x27e9cc=this['_normals32'],_0x3ffb32=this['_uvs32'],_0x1983ec=this['_indices32'],_0x49439a=this['_indices'],_0x8ad415=this['_fixedNormal32'],_0x4a2012=_0x74d525['c']['Vector3'],_0x726349=_0x4a2012[0x5]['copyFromFloats'](0x1,0x0,0x0),_0x1fac98=_0x4a2012[0x6]['copyFromFloats'](0x0,0x1,0x0),_0x31f538=_0x4a2012[0x7]['copyFromFloats'](0x0,0x0,0x1),_0x4e7652=_0x4a2012[0x8]['setAll'](Number['MAX_VALUE']),_0x2d9457=_0x4a2012[0x9]['setAll'](-Number['MAX_VALUE']),_0x3e511d=_0x4a2012[0xa]['setAll'](0x0),_0x3d8aea=this['_tmpVertex'],_0x44884b=_0x3d8aea['position'],_0x47ed37=_0x3d8aea['color'],_0x4b8370=_0x3d8aea['uv'];if((this['billboard']||this['_depthSort'])&&(this['mesh']['computeWorldMatrix'](!0x0),this['mesh']['_worldMatrix']['invertToRef'](_0x37554b)),this['billboard']){var _0x18d102=_0x4a2012[0x0];this['_camera']['getDirectionToRef'](_0x4a79a2['a']['Z'],_0x18d102),_0x74d525['e']['TransformNormalToRef'](_0x18d102,_0x37554b,_0x31f538),_0x31f538['normalize']();var _0x2f4540=this['_camera']['getViewMatrix'](!0x0);_0x74d525['e']['TransformNormalFromFloatsToRef'](_0x2f4540['m'][0x1],_0x2f4540['m'][0x5],_0x2f4540['m'][0x9],_0x37554b,_0x1fac98),_0x74d525['e']['CrossToRef'](_0x1fac98,_0x31f538,_0x726349),_0x1fac98['normalize'](),_0x726349['normalize']();}this['_depthSort']&&_0x74d525['e']['TransformCoordinatesToRef'](this['_camera']['globalPosition'],_0x37554b,_0x3e511d),_0x74d525['a']['IdentityToRef'](_0x296e30);var _0x28dd01=0x0,_0x58b082=0x0,_0x55175a=0x0,_0x5e2278=0x0,_0xda912c=0x0,_0x3aa83f=0x0,_0x4a0af6=0x0;if(this['mesh']['isFacetDataEnabled']&&(this['_computeBoundingBox']=!0x0),_0x558929=_0x558929>=this['nbParticles']?this['nbParticles']-0x1:_0x558929,this['_computeBoundingBox']&&(0x0!=_0x408916||_0x558929!=this['nbParticles']-0x1)){var _0x496077=this['mesh']['_boundingInfo'];_0x496077&&(_0x4e7652['copyFrom'](_0x496077['minimum']),_0x2d9457['copyFrom'](_0x496077['maximum']));}var _0x20a6fe=(_0x58b082=this['particles'][_0x408916]['_pos'])/0x3|0x0;_0x5e2278=0x4*_0x20a6fe,_0x3aa83f=0x2*_0x20a6fe;for(var _0x33c6d0=_0x408916;_0x33c6d0<=_0x558929;_0x33c6d0++){var _0x38e4c0=this['particles'][_0x33c6d0];this['updateParticle'](_0x38e4c0);var _0x55f645=_0x38e4c0['_model']['_shape'],_0x2e095c=_0x38e4c0['_model']['_shapeUV'],_0x37bada=_0x38e4c0['_rotationMatrix'],_0x29f156=_0x38e4c0['position'],_0x1ac9e4=_0x38e4c0['rotation'],_0x57cd37=_0x38e4c0['scaling'],_0x519876=_0x38e4c0['_globalPosition'];if(this['_depthSort']&&this['_depthSortParticles']){var _0x5979bb=this['depthSortedParticles'][_0x33c6d0];_0x5979bb['idx']=_0x38e4c0['idx'],_0x5979bb['ind']=_0x38e4c0['_ind'],_0x5979bb['indicesLength']=_0x38e4c0['_model']['_indicesLength'],_0x5979bb['sqDistance']=_0x74d525['e']['DistanceSquared'](_0x38e4c0['position'],_0x3e511d);}if(!_0x38e4c0['alive']||_0x38e4c0['_stillInvisible']&&!_0x38e4c0['isVisible'])_0x58b082+=0x3*(_0x4a0af6=_0x55f645['length']),_0x5e2278+=0x4*_0x4a0af6,_0x3aa83f+=0x2*_0x4a0af6;else{if(_0x38e4c0['isVisible']){_0x38e4c0['_stillInvisible']=!0x1;var _0x4c7ec8=_0x4a2012[0xc];if(_0x38e4c0['pivot']['multiplyToRef'](_0x57cd37,_0x4c7ec8),this['billboard']&&(_0x1ac9e4['x']=0x0,_0x1ac9e4['y']=0x0),(this['_computeParticleRotation']||this['billboard'])&&_0x38e4c0['getRotationMatrix'](_0x296e30),null!==_0x38e4c0['parentId']){var _0x39b9de=this['getParticleById'](_0x38e4c0['parentId']);if(_0x39b9de){var _0x4d19f4=_0x39b9de['_rotationMatrix'],_0x137edc=_0x39b9de['_globalPosition'],_0x5ed9fb=_0x29f156['x']*_0x4d19f4[0x1]+_0x29f156['y']*_0x4d19f4[0x4]+_0x29f156['z']*_0x4d19f4[0x7],_0x1cf634=_0x29f156['x']*_0x4d19f4[0x0]+_0x29f156['y']*_0x4d19f4[0x3]+_0x29f156['z']*_0x4d19f4[0x6],_0x25530b=_0x29f156['x']*_0x4d19f4[0x2]+_0x29f156['y']*_0x4d19f4[0x5]+_0x29f156['z']*_0x4d19f4[0x8];if(_0x519876['x']=_0x137edc['x']+_0x1cf634,_0x519876['y']=_0x137edc['y']+_0x5ed9fb,_0x519876['z']=_0x137edc['z']+_0x25530b,this['_computeParticleRotation']||this['billboard']){var _0x115ca2=_0x296e30['m'];_0x37bada[0x0]=_0x115ca2[0x0]*_0x4d19f4[0x0]+_0x115ca2[0x1]*_0x4d19f4[0x3]+_0x115ca2[0x2]*_0x4d19f4[0x6],_0x37bada[0x1]=_0x115ca2[0x0]*_0x4d19f4[0x1]+_0x115ca2[0x1]*_0x4d19f4[0x4]+_0x115ca2[0x2]*_0x4d19f4[0x7],_0x37bada[0x2]=_0x115ca2[0x0]*_0x4d19f4[0x2]+_0x115ca2[0x1]*_0x4d19f4[0x5]+_0x115ca2[0x2]*_0x4d19f4[0x8],_0x37bada[0x3]=_0x115ca2[0x4]*_0x4d19f4[0x0]+_0x115ca2[0x5]*_0x4d19f4[0x3]+_0x115ca2[0x6]*_0x4d19f4[0x6],_0x37bada[0x4]=_0x115ca2[0x4]*_0x4d19f4[0x1]+_0x115ca2[0x5]*_0x4d19f4[0x4]+_0x115ca2[0x6]*_0x4d19f4[0x7],_0x37bada[0x5]=_0x115ca2[0x4]*_0x4d19f4[0x2]+_0x115ca2[0x5]*_0x4d19f4[0x5]+_0x115ca2[0x6]*_0x4d19f4[0x8],_0x37bada[0x6]=_0x115ca2[0x8]*_0x4d19f4[0x0]+_0x115ca2[0x9]*_0x4d19f4[0x3]+_0x115ca2[0xa]*_0x4d19f4[0x6],_0x37bada[0x7]=_0x115ca2[0x8]*_0x4d19f4[0x1]+_0x115ca2[0x9]*_0x4d19f4[0x4]+_0x115ca2[0xa]*_0x4d19f4[0x7],_0x37bada[0x8]=_0x115ca2[0x8]*_0x4d19f4[0x2]+_0x115ca2[0x9]*_0x4d19f4[0x5]+_0x115ca2[0xa]*_0x4d19f4[0x8];}}else _0x38e4c0['parentId']=null;}else(_0x519876['x']=_0x29f156['x'],_0x519876['y']=_0x29f156['y'],_0x519876['z']=_0x29f156['z'],this['_computeParticleRotation']||this['billboard'])&&(_0x115ca2=_0x296e30['m'],(_0x37bada[0x0]=_0x115ca2[0x0],_0x37bada[0x1]=_0x115ca2[0x1],_0x37bada[0x2]=_0x115ca2[0x2],_0x37bada[0x3]=_0x115ca2[0x4],_0x37bada[0x4]=_0x115ca2[0x5],_0x37bada[0x5]=_0x115ca2[0x6],_0x37bada[0x6]=_0x115ca2[0x8],_0x37bada[0x7]=_0x115ca2[0x9],_0x37bada[0x8]=_0x115ca2[0xa]));var _0x5f18df=_0x4a2012[0xb];for(_0x38e4c0['translateFromPivot']?_0x5f18df['setAll'](0x0):_0x5f18df['copyFrom'](_0x4c7ec8),_0x4a0af6=0x0;_0x4a0af6<_0x55f645['length'];_0x4a0af6++){_0x28dd01=_0x58b082+0x3*_0x4a0af6,_0x55175a=_0x5e2278+0x4*_0x4a0af6,_0xda912c=_0x3aa83f+0x2*_0x4a0af6;var _0x10653b=0x2*_0x4a0af6,_0x26d6c3=_0x10653b+0x1;_0x44884b['copyFrom'](_0x55f645[_0x4a0af6]),this['_computeParticleColor']&&_0x38e4c0['color']&&_0x47ed37['copyFrom'](_0x38e4c0['color']),this['_computeParticleTexture']&&_0x4b8370['copyFromFloats'](_0x2e095c[_0x10653b],_0x2e095c[_0x26d6c3]),this['_computeParticleVertex']&&this['updateParticleVertex'](_0x38e4c0,_0x3d8aea,_0x4a0af6);var _0x43f4a0=_0x44884b['x']*_0x57cd37['x']-_0x4c7ec8['x'],_0x99cde5=_0x44884b['y']*_0x57cd37['y']-_0x4c7ec8['y'],_0x93c85b=_0x44884b['z']*_0x57cd37['z']-_0x4c7ec8['z'];_0x1cf634=_0x43f4a0*_0x37bada[0x0]+_0x99cde5*_0x37bada[0x3]+_0x93c85b*_0x37bada[0x6],_0x5ed9fb=_0x43f4a0*_0x37bada[0x1]+_0x99cde5*_0x37bada[0x4]+_0x93c85b*_0x37bada[0x7],_0x25530b=_0x43f4a0*_0x37bada[0x2]+_0x99cde5*_0x37bada[0x5]+_0x93c85b*_0x37bada[0x8],(_0x1cf634+=_0x5f18df['x'],_0x5ed9fb+=_0x5f18df['y'],_0x25530b+=_0x5f18df['z']);var _0xb549f9=_0x18298c[_0x28dd01]=_0x519876['x']+_0x726349['x']*_0x1cf634+_0x1fac98['x']*_0x5ed9fb+_0x31f538['x']*_0x25530b,_0x402825=_0x18298c[_0x28dd01+0x1]=_0x519876['y']+_0x726349['y']*_0x1cf634+_0x1fac98['y']*_0x5ed9fb+_0x31f538['y']*_0x25530b,_0x57ef58=_0x18298c[_0x28dd01+0x2]=_0x519876['z']+_0x726349['z']*_0x1cf634+_0x1fac98['z']*_0x5ed9fb+_0x31f538['z']*_0x25530b;if(this['_computeBoundingBox']&&(_0x4e7652['minimizeInPlaceFromFloats'](_0xb549f9,_0x402825,_0x57ef58),_0x2d9457['maximizeInPlaceFromFloats'](_0xb549f9,_0x402825,_0x57ef58)),!this['_computeParticleVertex']){var _0x558aad=_0x8ad415[_0x28dd01],_0x3f5ab0=_0x8ad415[_0x28dd01+0x1],_0x647c17=_0x8ad415[_0x28dd01+0x2],_0xe1f1aa=_0x558aad*_0x37bada[0x0]+_0x3f5ab0*_0x37bada[0x3]+_0x647c17*_0x37bada[0x6],_0x2a861f=_0x558aad*_0x37bada[0x1]+_0x3f5ab0*_0x37bada[0x4]+_0x647c17*_0x37bada[0x7],_0x515ff9=_0x558aad*_0x37bada[0x2]+_0x3f5ab0*_0x37bada[0x5]+_0x647c17*_0x37bada[0x8];_0x27e9cc[_0x28dd01]=_0x726349['x']*_0xe1f1aa+_0x1fac98['x']*_0x2a861f+_0x31f538['x']*_0x515ff9,_0x27e9cc[_0x28dd01+0x1]=_0x726349['y']*_0xe1f1aa+_0x1fac98['y']*_0x2a861f+_0x31f538['y']*_0x515ff9,_0x27e9cc[_0x28dd01+0x2]=_0x726349['z']*_0xe1f1aa+_0x1fac98['z']*_0x2a861f+_0x31f538['z']*_0x515ff9;}if(this['_computeParticleColor']&&_0x38e4c0['color']){var _0x4f6f1d=this['_colors32'];_0x4f6f1d[_0x55175a]=_0x47ed37['r'],_0x4f6f1d[_0x55175a+0x1]=_0x47ed37['g'],_0x4f6f1d[_0x55175a+0x2]=_0x47ed37['b'],_0x4f6f1d[_0x55175a+0x3]=_0x47ed37['a'];}if(this['_computeParticleTexture']){var _0x399694=_0x38e4c0['uvs'];_0x3ffb32[_0xda912c]=_0x4b8370['x']*(_0x399694['z']-_0x399694['x'])+_0x399694['x'],_0x3ffb32[_0xda912c+0x1]=_0x4b8370['y']*(_0x399694['w']-_0x399694['y'])+_0x399694['y'];}}}else for(_0x38e4c0['_stillInvisible']=!0x0,_0x4a0af6=0x0;_0x4a0af6<_0x55f645['length'];_0x4a0af6++){if(_0x55175a=_0x5e2278+0x4*_0x4a0af6,_0xda912c=_0x3aa83f+0x2*_0x4a0af6,_0x18298c[_0x28dd01=_0x58b082+0x3*_0x4a0af6]=_0x18298c[_0x28dd01+0x1]=_0x18298c[_0x28dd01+0x2]=0x0,_0x27e9cc[_0x28dd01]=_0x27e9cc[_0x28dd01+0x1]=_0x27e9cc[_0x28dd01+0x2]=0x0,this['_computeParticleColor']&&_0x38e4c0['color']){var _0x38e9c5=_0x38e4c0['color'];_0x120b51[_0x55175a]=_0x38e9c5['r'],_0x120b51[_0x55175a+0x1]=_0x38e9c5['g'],_0x120b51[_0x55175a+0x2]=_0x38e9c5['b'],_0x120b51[_0x55175a+0x3]=_0x38e9c5['a'];}this['_computeParticleTexture']&&(_0x399694=_0x38e4c0['uvs'],(_0x3ffb32[_0xda912c]=_0x2e095c[0x2*_0x4a0af6]*(_0x399694['z']-_0x399694['x'])+_0x399694['x'],_0x3ffb32[_0xda912c+0x1]=_0x2e095c[0x2*_0x4a0af6+0x1]*(_0x399694['w']-_0x399694['y'])+_0x399694['y']));}if(this['_particlesIntersect']){var _0x2f4981=_0x38e4c0['_boundingInfo'],_0x1d10d6=_0x2f4981['boundingBox'],_0x5d955e=_0x2f4981['boundingSphere'],_0xa7560e=_0x38e4c0['_modelBoundingInfo'];if(!this['_bSphereOnly']){var _0x3b95c8=_0xa7560e['boundingBox']['vectors'],_0x1839a6=_0x4a2012[0x1],_0x4f7f57=_0x4a2012[0x2];_0x1839a6['setAll'](Number['MAX_VALUE']),_0x4f7f57['setAll'](-Number['MAX_VALUE']);for(var _0x4d00f2=0x0;_0x4d00f2<0x8;_0x4d00f2++){var _0xf6d13f=_0x3b95c8[_0x4d00f2]['x']*_0x57cd37['x'],_0xac1bf9=_0x3b95c8[_0x4d00f2]['y']*_0x57cd37['y'],_0x419cb6=_0x3b95c8[_0x4d00f2]['z']*_0x57cd37['z'],_0x44eae1=(_0x1cf634=_0xf6d13f*_0x37bada[0x0]+_0xac1bf9*_0x37bada[0x3]+_0x419cb6*_0x37bada[0x6],_0x5ed9fb=_0xf6d13f*_0x37bada[0x1]+_0xac1bf9*_0x37bada[0x4]+_0x419cb6*_0x37bada[0x7],_0x25530b=_0xf6d13f*_0x37bada[0x2]+_0xac1bf9*_0x37bada[0x5]+_0x419cb6*_0x37bada[0x8],_0x29f156['x']+_0x726349['x']*_0x1cf634+_0x1fac98['x']*_0x5ed9fb+_0x31f538['x']*_0x25530b),_0x463835=_0x29f156['y']+_0x726349['y']*_0x1cf634+_0x1fac98['y']*_0x5ed9fb+_0x31f538['y']*_0x25530b,_0x38d494=_0x29f156['z']+_0x726349['z']*_0x1cf634+_0x1fac98['z']*_0x5ed9fb+_0x31f538['z']*_0x25530b;_0x1839a6['minimizeInPlaceFromFloats'](_0x44eae1,_0x463835,_0x38d494),_0x4f7f57['maximizeInPlaceFromFloats'](_0x44eae1,_0x463835,_0x38d494);}_0x1d10d6['reConstruct'](_0x1839a6,_0x4f7f57,_0x3351c8['_worldMatrix']);}var _0x3778f1=_0xa7560e['minimum']['multiplyToRef'](_0x57cd37,_0x4a2012[0x1]),_0x13d00f=_0xa7560e['maximum']['multiplyToRef'](_0x57cd37,_0x4a2012[0x2]),_0x955d90=_0x13d00f['addToRef'](_0x3778f1,_0x4a2012[0x3])['scaleInPlace'](0.5)['addInPlace'](_0x519876),_0x422a9d=_0x13d00f['subtractToRef'](_0x3778f1,_0x4a2012[0x4])['scaleInPlace'](0.5*this['_bSphereRadiusFactor']),_0x3854bf=_0x955d90['subtractToRef'](_0x422a9d,_0x4a2012[0x1]),_0x4c6d01=_0x955d90['addToRef'](_0x422a9d,_0x4a2012[0x2]);_0x5d955e['reConstruct'](_0x3854bf,_0x4c6d01,_0x3351c8['_worldMatrix']);}_0x58b082=_0x28dd01+0x3,_0x5e2278=_0x55175a+0x4,_0x3aa83f=_0xda912c+0x2;}}if(_0x3fdb63){if(this['_computeParticleColor']&&_0x3351c8['updateVerticesData'](_0x212fbd['b']['ColorKind'],_0x120b51,!0x1,!0x1),this['_computeParticleTexture']&&_0x3351c8['updateVerticesData'](_0x212fbd['b']['UVKind'],_0x3ffb32,!0x1,!0x1),_0x3351c8['updateVerticesData'](_0x212fbd['b']['PositionKind'],_0x18298c,!0x1,!0x1),!_0x3351c8['areNormalsFrozen']||_0x3351c8['isFacetDataEnabled']){if(this['_computeParticleVertex']||_0x3351c8['isFacetDataEnabled']){var _0x24c918=_0x3351c8['isFacetDataEnabled']?_0x3351c8['getFacetDataParameters']():null;_0xa18063['a']['ComputeNormals'](_0x18298c,_0x1983ec,_0x27e9cc,_0x24c918);for(var _0x293bae=0x0;_0x293bae<_0x27e9cc['length'];_0x293bae++)_0x8ad415[_0x293bae]=_0x27e9cc[_0x293bae];}_0x3351c8['areNormalsFrozen']||_0x3351c8['updateVerticesData'](_0x212fbd['b']['NormalKind'],_0x27e9cc,!0x1,!0x1);}if(this['_depthSort']&&this['_depthSortParticles']){var _0x34e384=this['depthSortedParticles'];_0x34e384['sort'](this['_depthSortFunction']);for(var _0x5a42e8=_0x34e384['length'],_0x30599e=0x0,_0x3face1=0x0,_0x539acb=0x0;_0x539acb<_0x5a42e8;_0x539acb++){var _0x163001=_0x34e384[_0x539acb],_0x4105f6=_0x163001['indicesLength'],_0x1a32b3=_0x163001['ind'];for(_0x293bae=0x0;_0x293bae<_0x4105f6;_0x293bae++){if(_0x1983ec[_0x30599e]=_0x49439a[_0x1a32b3+_0x293bae],_0x30599e++,this['_pickable']){if(0x0==_0x293bae%0x3){var _0x5393eb=this['pickedParticles'][_0x3face1];_0x5393eb['idx']=_0x163001['idx'],_0x5393eb['faceId']=_0x3face1,_0x3face1++;}}}}_0x3351c8['updateIndices'](_0x1983ec);}}return this['_computeBoundingBox']&&(_0x3351c8['_boundingInfo']?_0x3351c8['_boundingInfo']['reConstruct'](_0x4e7652,_0x2d9457,_0x3351c8['_worldMatrix']):_0x3351c8['_boundingInfo']=new _0x386a4b['a'](_0x4e7652,_0x2d9457,_0x3351c8['_worldMatrix'])),this['_autoUpdateSubMeshes']&&this['computeSubMeshes'](),this['afterUpdateParticles'](_0x408916,_0x558929,_0x3fdb63),this;},_0x51e074['prototype']['dispose']=function(){this['mesh']['dispose'](),this['vars']=null,this['_positions']=null,this['_indices']=null,this['_normals']=null,this['_uvs']=null,this['_colors']=null,this['_indices32']=null,this['_positions32']=null,this['_normals32']=null,this['_fixedNormal32']=null,this['_uvs32']=null,this['_colors32']=null,this['pickedParticles']=null,this['pickedBySubMesh']=null,this['_materials']=null,this['_materialIndexes']=null,this['_indicesByMaterial']=null,this['_idxOfId']=null;},_0x51e074['prototype']['pickedParticle']=function(_0xc67be6){if(_0xc67be6['hit']){var _0x18abb0=_0xc67be6['subMeshId'],_0x1097d3=_0xc67be6['faceId'],_0x571429=this['pickedBySubMesh'];if(_0x571429[_0x18abb0]&&_0x571429[_0x18abb0][_0x1097d3])return _0x571429[_0x18abb0][_0x1097d3];}return null;},_0x51e074['prototype']['getParticleById']=function(_0x2ac6ba){var _0x3cb2f6=this['particles'][_0x2ac6ba];if(_0x3cb2f6&&_0x3cb2f6['id']==_0x2ac6ba)return _0x3cb2f6;var _0x48a4a5=this['particles'],_0x27d2a6=this['_idxOfId'][_0x2ac6ba];if(void 0x0!==_0x27d2a6)return _0x48a4a5[_0x27d2a6];for(var _0x3a0d0e=0x0,_0x5a99bc=this['nbParticles'];_0x3a0d0e<_0x5a99bc;){var _0x4490c5=_0x48a4a5[_0x3a0d0e];if(_0x4490c5['id']==_0x2ac6ba)return _0x4490c5;_0x3a0d0e++;}return null;},_0x51e074['prototype']['getParticlesByShapeId']=function(_0x24652a){var _0x2ef21b=[];return this['getParticlesByShapeIdToRef'](_0x24652a,_0x2ef21b),_0x2ef21b;},_0x51e074['prototype']['getParticlesByShapeIdToRef']=function(_0x19c8ef,_0x383a69){_0x383a69['length']=0x0;for(var _0x5ae1d9=0x0;_0x5ae1d90x0)for(var _0x21bd4e=0x0;_0x21bd4e0x0&&_0x1d0624['set'](this['_uvs32'],_0x212fbd['b']['UVKind']);var _0x410b4e=0x0;this['_colors32']['length']>0x0&&(_0x410b4e=0x1,_0x1d0624['set'](this['_colors32'],_0x212fbd['b']['ColorKind']));var _0x4f7500=new _0x3cf5e5['a'](this['name'],this['_scene']);_0x1d0624['applyToMesh'](_0x4f7500,this['_updatable']),this['mesh']=_0x4f7500,this['_positions']=null,this['_uvs']=null,this['_colors']=null,this['_updatable']||(this['particles']['length']=0x0);var _0x838847=new _0x5905ab['a']('point\x20cloud\x20material',this['_scene']);return _0x838847['emissiveColor']=new _0x39310d['a'](_0x410b4e,_0x410b4e,_0x410b4e),_0x838847['disableLighting']=!0x0,_0x838847['pointsCloud']=!0x0,_0x838847['pointSize']=this['_size'],_0x4f7500['material']=_0x838847,new Promise(function(_0x2a19d1){return _0x2a19d1(_0x4f7500);});},_0x3ec7df['prototype']['_addParticle']=function(_0x4d8ed7,_0x28a858,_0x30669a,_0x3052db){var _0x264fa5=new _0x264666(_0x4d8ed7,_0x28a858,_0x30669a,_0x3052db,this);return this['particles']['push'](_0x264fa5),_0x264fa5;},_0x3ec7df['prototype']['_randomUnitVector']=function(_0x3beaee){_0x3beaee['position']=new _0x74d525['e'](Math['random'](),Math['random'](),Math['random']()),_0x3beaee['color']=new _0x39310d['b'](0x1,0x1,0x1,0x1);},_0x3ec7df['prototype']['_getColorIndicesForCoord']=function(_0x45a084,_0x1df1e0,_0x294c45,_0x4cdbc9){var _0x2eef8b=_0x45a084['_groupImageData'],_0x331d3b=_0x294c45*(0x4*_0x4cdbc9)+0x4*_0x1df1e0,_0x4515d4=[_0x331d3b,_0x331d3b+0x1,_0x331d3b+0x2,_0x331d3b+0x3],_0x4dd380=_0x4515d4[0x1],_0x50fa57=_0x4515d4[0x2],_0x59daa4=_0x4515d4[0x3],_0x3cb078=_0x2eef8b[_0x4515d4[0x0]],_0x8ba75=_0x2eef8b[_0x4dd380],_0x4ca5e0=_0x2eef8b[_0x50fa57],_0x3d4f31=_0x2eef8b[_0x59daa4];return new _0x39310d['b'](_0x3cb078/0xff,_0x8ba75/0xff,_0x4ca5e0/0xff,_0x3d4f31);},_0x3ec7df['prototype']['_setPointsColorOrUV']=function(_0x5aad4a,_0x2368bf,_0x1feb98,_0x3f0bf8,_0x3120fe,_0x426da2,_0x3a1a6d){_0x1feb98&&_0x5aad4a['updateFacetData']();var _0x350335=0x2*_0x5aad4a['getBoundingInfo']()['boundingSphere']['radius'],_0x1c88df=_0x5aad4a['getVerticesData'](_0x212fbd['b']['PositionKind']),_0x6b6dd0=_0x5aad4a['getIndices'](),_0x2a26f9=_0x5aad4a['getVerticesData'](_0x212fbd['b']['UVKind']),_0x4dc045=_0x5aad4a['getVerticesData'](_0x212fbd['b']['ColorKind']),_0x13624b=_0x74d525['e']['Zero']();_0x5aad4a['computeWorldMatrix']();var _0x146bf8=_0x5aad4a['getWorldMatrix']();if(!_0x146bf8['isIdentity']()){for(var _0x428f1e=0x0;_0x428f1e<_0x1c88df['length']/0x3;_0x428f1e++)_0x74d525['e']['TransformCoordinatesFromFloatsToRef'](_0x1c88df[0x3*_0x428f1e],_0x1c88df[0x3*_0x428f1e+0x1],_0x1c88df[0x3*_0x428f1e+0x2],_0x146bf8,_0x13624b),_0x1c88df[0x3*_0x428f1e]=_0x13624b['x'],_0x1c88df[0x3*_0x428f1e+0x1]=_0x13624b['y'],_0x1c88df[0x3*_0x428f1e+0x2]=_0x13624b['z'];}var _0x3f8a6e,_0x53773e,_0xc33948=0x0,_0x50bec9=0x0,_0x9b421b=0x0,_0x40f9d7=0x0,_0xbb8cbc=0x0,_0x5d3376=0x0,_0x3d1c26=0x0,_0x247d25=0x0,_0x5f104e=0x0,_0x500374=0x0,_0x58f9cd=0x0,_0x581f23=0x0,_0x1d36de=0x0,_0xc45e5a=0x0,_0x48409e=_0x74d525['e']['Zero'](),_0x42d313=_0x74d525['e']['Zero'](),_0x433a90=_0x74d525['e']['Zero'](),_0x17e338=_0x74d525['e']['Zero'](),_0x3b5fb5=_0x74d525['e']['Zero'](),_0x4ff3d0=0x0,_0x6361aa=0x0,_0x3c6580=0x0,_0x58b194=0x0,_0x20a594=0x0,_0x59cf33=0x0,_0x4b25fd=_0x74d525['d']['Zero'](),_0x13fa90=_0x74d525['d']['Zero'](),_0xf912ec=_0x74d525['d']['Zero'](),_0x113303=_0x74d525['d']['Zero'](),_0x59116c=_0x74d525['d']['Zero'](),_0x194438=0x0,_0x28d123=0x0,_0x52c695=0x0,_0x5e7c76=0x0,_0x5e2cdc=0x0,_0x533fdc=0x0,_0x13c737=0x0,_0x58f538=0x0,_0x313fa6=0x0,_0x5b8c5c=0x0,_0x447fa6=0x0,_0x31fee9=0x0,_0x117de4=_0x74d525['f']['Zero'](),_0x2fa313=_0x74d525['f']['Zero'](),_0x36ca8b=_0x74d525['f']['Zero'](),_0x3ce155=_0x74d525['f']['Zero'](),_0x1ecd63=_0x74d525['f']['Zero'](),_0x262cc6=0x0,_0x4c85b6=0x0;_0x3a1a6d=_0x3a1a6d||0x0;var _0x2f9546,_0x3abebf=new _0x74d525['f'](0x0,0x0,0x0,0x0),_0x2f024f=_0x74d525['e']['Zero'](),_0x2e7d35=_0x74d525['e']['Zero'](),_0x475ea1=_0x74d525['e']['Zero'](),_0x40c03b=0x0,_0x1eb6c1=_0x74d525['e']['Zero'](),_0x7aeaf8=0x0,_0x1d481a=0x0,_0x495cdf=new _0x36fb4d['a'](_0x74d525['e']['Zero'](),new _0x74d525['e'](0x1,0x0,0x0)),_0x5ae3bd=_0x74d525['e']['Zero']();for(_0x50bec9=0x0;_0x50bec9<_0x6b6dd0['length']/0x3;_0x50bec9++){var _0x5da09a,_0x36c4db,_0x1c8153,_0x4b827f,_0x26a56a,_0x53e12c,_0x415395,_0x11b96c;_0x9b421b=_0x6b6dd0[0x3*_0x50bec9],_0x40f9d7=_0x6b6dd0[0x3*_0x50bec9+0x1],_0xbb8cbc=_0x6b6dd0[0x3*_0x50bec9+0x2],_0x5d3376=_0x1c88df[0x3*_0x9b421b],_0x3d1c26=_0x1c88df[0x3*_0x9b421b+0x1],_0x247d25=_0x1c88df[0x3*_0x9b421b+0x2],_0x5f104e=_0x1c88df[0x3*_0x40f9d7],_0x500374=_0x1c88df[0x3*_0x40f9d7+0x1],_0x58f9cd=_0x1c88df[0x3*_0x40f9d7+0x2],_0x581f23=_0x1c88df[0x3*_0xbb8cbc],_0x1d36de=_0x1c88df[0x3*_0xbb8cbc+0x1],_0xc45e5a=_0x1c88df[0x3*_0xbb8cbc+0x2],_0x48409e['set'](_0x5d3376,_0x3d1c26,_0x247d25),_0x42d313['set'](_0x5f104e,_0x500374,_0x58f9cd),_0x433a90['set'](_0x581f23,_0x1d36de,_0xc45e5a),_0x42d313['subtractToRef'](_0x48409e,_0x17e338),_0x433a90['subtractToRef'](_0x42d313,_0x3b5fb5),_0x2a26f9&&(_0x4ff3d0=_0x2a26f9[0x2*_0x9b421b],_0x6361aa=_0x2a26f9[0x2*_0x9b421b+0x1],_0x3c6580=_0x2a26f9[0x2*_0x40f9d7],_0x58b194=_0x2a26f9[0x2*_0x40f9d7+0x1],_0x20a594=_0x2a26f9[0x2*_0xbb8cbc],_0x59cf33=_0x2a26f9[0x2*_0xbb8cbc+0x1],_0x4b25fd['set'](_0x4ff3d0,_0x6361aa),_0x13fa90['set'](_0x3c6580,_0x58b194),_0xf912ec['set'](_0x20a594,_0x59cf33),_0x13fa90['subtractToRef'](_0x4b25fd,_0x113303),_0xf912ec['subtractToRef'](_0x13fa90,_0x59116c)),_0x4dc045&&_0x3f0bf8&&(_0x194438=_0x4dc045[0x4*_0x9b421b],_0x28d123=_0x4dc045[0x4*_0x9b421b+0x1],_0x52c695=_0x4dc045[0x4*_0x9b421b+0x2],_0x5e7c76=_0x4dc045[0x4*_0x9b421b+0x3],_0x5e2cdc=_0x4dc045[0x4*_0x40f9d7],_0x533fdc=_0x4dc045[0x4*_0x40f9d7+0x1],_0x13c737=_0x4dc045[0x4*_0x40f9d7+0x2],_0x58f538=_0x4dc045[0x4*_0x40f9d7+0x3],_0x313fa6=_0x4dc045[0x4*_0xbb8cbc],_0x5b8c5c=_0x4dc045[0x4*_0xbb8cbc+0x1],_0x447fa6=_0x4dc045[0x4*_0xbb8cbc+0x2],_0x31fee9=_0x4dc045[0x4*_0xbb8cbc+0x3],_0x117de4['set'](_0x194438,_0x28d123,_0x52c695,_0x5e7c76),_0x2fa313['set'](_0x5e2cdc,_0x533fdc,_0x13c737,_0x58f538),_0x36ca8b['set'](_0x313fa6,_0x5b8c5c,_0x447fa6,_0x31fee9),_0x2fa313['subtractToRef'](_0x117de4,_0x3ce155),_0x36ca8b['subtractToRef'](_0x2fa313,_0x1ecd63));for(var _0x2a4869,_0x20051d,_0x14fcf9=new _0x39310d['a'](0x0,0x0,0x0),_0x853c3c=new _0x39310d['a'](0x0,0x0,0x0),_0x24bd50=0x0;_0x24bd50<_0x2368bf['_groupDensity'][_0x50bec9];_0x24bd50++)_0xc33948=this['particles']['length'],this['_addParticle'](_0xc33948,_0x2368bf,this['_groupCounter'],_0x50bec9+_0x24bd50),_0x20051d=this['particles'][_0xc33948],_0x262cc6=_0x4a0cf0['a']['RandomRange'](0x0,0x1),_0x4c85b6=_0x4a0cf0['a']['RandomRange'](0x0,0x1),_0x3f8a6e=_0x48409e['add'](_0x17e338['scale'](_0x262cc6))['add'](_0x3b5fb5['scale'](_0x262cc6*_0x4c85b6)),_0x1feb98&&(_0x2f024f=_0x5aad4a['getFacetNormal'](_0x50bec9)['normalize']()['scale'](-0x1),_0x2e7d35=_0x17e338['clone']()['normalize'](),_0x475ea1=_0x74d525['e']['Cross'](_0x2f024f,_0x2e7d35),_0x40c03b=_0x4a0cf0['a']['RandomRange'](0x0,0x2*Math['PI']),_0x1eb6c1=_0x2e7d35['scale'](Math['cos'](_0x40c03b))['add'](_0x475ea1['scale'](Math['sin'](_0x40c03b))),_0x40c03b=_0x4a0cf0['a']['RandomRange'](0.1,Math['PI']/0x2),_0x5ae3bd=_0x1eb6c1['scale'](Math['cos'](_0x40c03b))['add'](_0x2f024f['scale'](Math['sin'](_0x40c03b))),_0x495cdf['origin']=_0x3f8a6e['add'](_0x5ae3bd['scale'](0.00001)),_0x495cdf['direction']=_0x5ae3bd,_0x495cdf['length']=_0x350335,(_0x2f9546=_0x495cdf['intersectsMesh'](_0x5aad4a))['hit']&&(_0x1d481a=_0x2f9546['pickedPoint']['subtract'](_0x3f8a6e)['length'](),_0x7aeaf8=_0x4a0cf0['a']['RandomRange'](0x0,0x1)*_0x1d481a,_0x3f8a6e['addInPlace'](_0x5ae3bd['scale'](_0x7aeaf8)))),_0x20051d['position']=_0x3f8a6e['clone'](),this['_positions']['push'](_0x20051d['position']['x'],_0x20051d['position']['y'],_0x20051d['position']['z']),void 0x0!==_0x3f0bf8?_0x2a26f9&&(_0x53773e=_0x4b25fd['add'](_0x113303['scale'](_0x262cc6))['add'](_0x59116c['scale'](_0x262cc6*_0x4c85b6)),_0x3f0bf8?_0x3120fe&&null!==_0x2368bf['_groupImageData']?(_0x5da09a=_0x2368bf['_groupImgWidth'],_0x36c4db=_0x2368bf['_groupImgHeight'],_0x2a4869=this['_getColorIndicesForCoord'](_0x2368bf,Math['round'](_0x53773e['x']*_0x5da09a),Math['round'](_0x53773e['y']*_0x36c4db),_0x5da09a),_0x20051d['color']=_0x2a4869,this['_colors']['push'](_0x2a4869['r'],_0x2a4869['g'],_0x2a4869['b'],_0x2a4869['a'])):_0x4dc045?(_0x3abebf=_0x117de4['add'](_0x3ce155['scale'](_0x262cc6))['add'](_0x1ecd63['scale'](_0x262cc6*_0x4c85b6)),_0x20051d['color']=new _0x39310d['b'](_0x3abebf['x'],_0x3abebf['y'],_0x3abebf['z'],_0x3abebf['w']),this['_colors']['push'](_0x3abebf['x'],_0x3abebf['y'],_0x3abebf['z'],_0x3abebf['w'])):(_0x3abebf=_0x117de4['set'](Math['random'](),Math['random'](),Math['random'](),0x1),_0x20051d['color']=new _0x39310d['b'](_0x3abebf['x'],_0x3abebf['y'],_0x3abebf['z'],_0x3abebf['w']),this['_colors']['push'](_0x3abebf['x'],_0x3abebf['y'],_0x3abebf['z'],_0x3abebf['w'])):(_0x20051d['uv']=_0x53773e['clone'](),this['_uvs']['push'](_0x20051d['uv']['x'],_0x20051d['uv']['y']))):(_0x426da2?(_0x14fcf9['set'](_0x426da2['r'],_0x426da2['g'],_0x426da2['b']),_0x1c8153=_0x4a0cf0['a']['RandomRange'](-_0x3a1a6d,_0x3a1a6d),_0x4b827f=_0x4a0cf0['a']['RandomRange'](-_0x3a1a6d,_0x3a1a6d),_0x26a56a=(_0x11b96c=_0x14fcf9['toHSV']())['r'],(_0x53e12c=_0x11b96c['g']+_0x1c8153)<0x0&&(_0x53e12c=0x0),_0x53e12c>0x1&&(_0x53e12c=0x1),(_0x415395=_0x11b96c['b']+_0x4b827f)<0x0&&(_0x415395=0x0),_0x415395>0x1&&(_0x415395=0x1),_0x39310d['a']['HSVtoRGBToRef'](_0x26a56a,_0x53e12c,_0x415395,_0x853c3c),_0x3abebf['set'](_0x853c3c['r'],_0x853c3c['g'],_0x853c3c['b'],0x1)):_0x3abebf=_0x117de4['set'](Math['random'](),Math['random'](),Math['random'](),0x1),_0x20051d['color']=new _0x39310d['b'](_0x3abebf['x'],_0x3abebf['y'],_0x3abebf['z'],_0x3abebf['w']),this['_colors']['push'](_0x3abebf['x'],_0x3abebf['y'],_0x3abebf['z'],_0x3abebf['w']));}},_0x3ec7df['prototype']['_colorFromTexture']=function(_0x5126fa,_0x211dbe,_0x1cb52e){var _0x22da27=this;if(null===_0x5126fa['material'])return _0x75193d['a']['Warn'](_0x5126fa['name']+'has\x20no\x20material.'),_0x211dbe['_groupImageData']=null,void this['_setPointsColorOrUV'](_0x5126fa,_0x211dbe,_0x1cb52e,!0x0,!0x1);var _0x5a8c88=_0x5126fa['material']['getActiveTextures']();if(0x0===_0x5a8c88['length'])return _0x75193d['a']['Warn'](_0x5126fa['name']+'has\x20no\x20useable\x20texture.'),_0x211dbe['_groupImageData']=null,void this['_setPointsColorOrUV'](_0x5126fa,_0x211dbe,_0x1cb52e,!0x0,!0x1);var _0x2f1fcc=_0x5126fa['clone']();_0x2f1fcc['setEnabled'](!0x1),this['_promises']['push'](new Promise(function(_0x342e1b){_0x2268ea['a']['WhenAllReady'](_0x5a8c88,function(){var _0x2112e0=_0x211dbe['_textureNb'];return _0x2112e0<0x0&&(_0x2112e0=0x0),_0x2112e0>_0x5a8c88['length']-0x1&&(_0x2112e0=_0x5a8c88['length']-0x1),_0x211dbe['_groupImageData']=_0x5a8c88[_0x2112e0]['readPixels'](),_0x211dbe['_groupImgWidth']=_0x5a8c88[_0x2112e0]['getSize']()['width'],_0x211dbe['_groupImgHeight']=_0x5a8c88[_0x2112e0]['getSize']()['height'],_0x22da27['_setPointsColorOrUV'](_0x2f1fcc,_0x211dbe,_0x1cb52e,!0x0,!0x0),_0x2f1fcc['dispose'](),_0x342e1b();});}));},_0x3ec7df['prototype']['_calculateDensity']=function(_0x3c1208,_0x2719f6,_0x3bb63e){for(var _0x5ed687,_0x495196,_0x51e567,_0x448fcb,_0x1ceec0,_0x20b9b7,_0x29e03b,_0xc9748f,_0x52256c,_0x467658,_0x24ab50,_0xa7e8ee,_0x257ae3,_0x197d3b,_0x211f90,_0x2596fc,_0x4eca32,_0x19a1df=new Array(),_0x35f47c=_0x74d525['e']['Zero'](),_0x44f9c2=_0x74d525['e']['Zero'](),_0x3234fa=_0x74d525['e']['Zero'](),_0x463c73=_0x74d525['e']['Zero'](),_0x273a4b=_0x74d525['e']['Zero'](),_0x18215f=_0x74d525['e']['Zero'](),_0x3a221f=new Array(),_0x570c34=0x0,_0x29b29d=_0x3bb63e['length']/0x3,_0x45a33a=0x0;_0x45a33a<_0x29b29d;_0x45a33a++)_0x5ed687=_0x3bb63e[0x3*_0x45a33a],_0x495196=_0x3bb63e[0x3*_0x45a33a+0x1],_0x51e567=_0x3bb63e[0x3*_0x45a33a+0x2],_0x448fcb=_0x2719f6[0x3*_0x5ed687],_0x1ceec0=_0x2719f6[0x3*_0x5ed687+0x1],_0x20b9b7=_0x2719f6[0x3*_0x5ed687+0x2],_0x29e03b=_0x2719f6[0x3*_0x495196],_0xc9748f=_0x2719f6[0x3*_0x495196+0x1],_0x52256c=_0x2719f6[0x3*_0x495196+0x2],_0x467658=_0x2719f6[0x3*_0x51e567],_0x24ab50=_0x2719f6[0x3*_0x51e567+0x1],_0xa7e8ee=_0x2719f6[0x3*_0x51e567+0x2],_0x35f47c['set'](_0x448fcb,_0x1ceec0,_0x20b9b7),_0x44f9c2['set'](_0x29e03b,_0xc9748f,_0x52256c),_0x3234fa['set'](_0x467658,_0x24ab50,_0xa7e8ee),_0x44f9c2['subtractToRef'](_0x35f47c,_0x463c73),_0x3234fa['subtractToRef'](_0x44f9c2,_0x273a4b),_0x3234fa['subtractToRef'](_0x35f47c,_0x18215f),_0x2596fc=((_0x257ae3=_0x463c73['length']())+(_0x197d3b=_0x273a4b['length']())+(_0x211f90=_0x18215f['length']()))/0x2,_0x570c34+=_0x4eca32=Math['sqrt'](_0x2596fc*(_0x2596fc-_0x257ae3)*(_0x2596fc-_0x197d3b)*(_0x2596fc-_0x211f90)),_0x3a221f[_0x45a33a]=_0x4eca32;var _0x3305d2=0x0;for(_0x45a33a=0x0;_0x45a33a<_0x29b29d;_0x45a33a++)_0x19a1df[_0x45a33a]=Math['floor'](_0x3c1208*_0x3a221f[_0x45a33a]/_0x570c34),_0x3305d2+=_0x19a1df[_0x45a33a];var _0x19d7ad=_0x3c1208-_0x3305d2,_0x12674e=Math['floor'](_0x19d7ad/_0x29b29d),_0x5d0bf6=_0x19d7ad%_0x29b29d;_0x12674e>0x0&&(_0x19a1df=_0x19a1df['map'](function(_0x137166){return _0x137166+_0x12674e;}));for(_0x45a33a=0x0;_0x45a33a<_0x5d0bf6;_0x45a33a++)_0x19a1df[_0x45a33a]+=0x1;return _0x19a1df;},_0x3ec7df['prototype']['addPoints']=function(_0x4d2126,_0x51d57b){void 0x0===_0x51d57b&&(_0x51d57b=this['_randomUnitVector']);for(var _0x32cc5f,_0x179a15=new _0x176d8e(this['_groupCounter'],_0x51d57b),_0x38c9d1=this['nbParticles'],_0x708d3d=0x0;_0x708d3d<_0x4d2126;_0x708d3d++)_0x32cc5f=this['_addParticle'](_0x38c9d1,_0x179a15,this['_groupCounter'],_0x708d3d),_0x179a15&&_0x179a15['_positionFunction']&&_0x179a15['_positionFunction'](_0x32cc5f,_0x38c9d1,_0x708d3d),this['_positions']['push'](_0x32cc5f['position']['x'],_0x32cc5f['position']['y'],_0x32cc5f['position']['z']),_0x32cc5f['color']&&this['_colors']['push'](_0x32cc5f['color']['r'],_0x32cc5f['color']['g'],_0x32cc5f['color']['b'],_0x32cc5f['color']['a']),_0x32cc5f['uv']&&this['_uvs']['push'](_0x32cc5f['uv']['x'],_0x32cc5f['uv']['y']),_0x38c9d1++;return this['nbParticles']+=_0x4d2126,this['_groupCounter']++,this['_groupCounter'];},_0x3ec7df['prototype']['addSurfacePoints']=function(_0x4e0986,_0x5aca3b,_0x27d0fd,_0x4e23da,_0x29bd4f){var _0x23a66d=_0x27d0fd||_0x4a7a2d['Random'];(isNaN(_0x23a66d)||_0x23a66d<0x0||_0x23a66d>0x3)&&(_0x23a66d=_0x4a7a2d['Random']);var _0x116a53=_0x4e0986['getVerticesData'](_0x212fbd['b']['PositionKind']),_0x217a4c=_0x4e0986['getIndices']();this['_groups']['push'](this['_groupCounter']);var _0x4406ff=new _0x176d8e(this['_groupCounter'],null);switch(_0x4406ff['_groupDensity']=this['_calculateDensity'](_0x5aca3b,_0x116a53,_0x217a4c),_0x23a66d===_0x4a7a2d['Color']?_0x4406ff['_textureNb']=_0x4e23da||0x0:_0x4e23da=_0x4e23da||new _0x39310d['b'](0x1,0x1,0x1,0x1),_0x23a66d){case _0x4a7a2d['Color']:this['_colorFromTexture'](_0x4e0986,_0x4406ff,!0x1);break;case _0x4a7a2d['UV']:this['_setPointsColorOrUV'](_0x4e0986,_0x4406ff,!0x1,!0x1,!0x1);break;case _0x4a7a2d['Random']:this['_setPointsColorOrUV'](_0x4e0986,_0x4406ff,!0x1);break;case _0x4a7a2d['Stated']:this['_setPointsColorOrUV'](_0x4e0986,_0x4406ff,!0x1,void 0x0,void 0x0,_0x4e23da,_0x29bd4f);}return this['nbParticles']+=_0x5aca3b,this['_groupCounter']++,this['_groupCounter']-0x1;},_0x3ec7df['prototype']['addVolumePoints']=function(_0xb218d2,_0x131f9f,_0x6e5511,_0x1aa3da,_0x1fdb94){var _0x83b27b=_0x6e5511||_0x4a7a2d['Random'];(isNaN(_0x83b27b)||_0x83b27b<0x0||_0x83b27b>0x3)&&(_0x83b27b=_0x4a7a2d['Random']);var _0x355329=_0xb218d2['getVerticesData'](_0x212fbd['b']['PositionKind']),_0x46a464=_0xb218d2['getIndices']();this['_groups']['push'](this['_groupCounter']);var _0x1e5d6f=new _0x176d8e(this['_groupCounter'],null);switch(_0x1e5d6f['_groupDensity']=this['_calculateDensity'](_0x131f9f,_0x355329,_0x46a464),_0x83b27b===_0x4a7a2d['Color']?_0x1e5d6f['_textureNb']=_0x1aa3da||0x0:_0x1aa3da=_0x1aa3da||new _0x39310d['b'](0x1,0x1,0x1,0x1),_0x83b27b){case _0x4a7a2d['Color']:this['_colorFromTexture'](_0xb218d2,_0x1e5d6f,!0x0);break;case _0x4a7a2d['UV']:this['_setPointsColorOrUV'](_0xb218d2,_0x1e5d6f,!0x0,!0x1,!0x1);break;case _0x4a7a2d['Random']:this['_setPointsColorOrUV'](_0xb218d2,_0x1e5d6f,!0x0);break;case _0x4a7a2d['Stated']:this['_setPointsColorOrUV'](_0xb218d2,_0x1e5d6f,!0x0,void 0x0,void 0x0,_0x1aa3da,_0x1fdb94);}return this['nbParticles']+=_0x131f9f,this['_groupCounter']++,this['_groupCounter']-0x1;},_0x3ec7df['prototype']['setParticles']=function(_0x18b09a,_0x5202ee,_0x402d44){if(void 0x0===_0x18b09a&&(_0x18b09a=0x0),void 0x0===_0x5202ee&&(_0x5202ee=this['nbParticles']-0x1),void 0x0===_0x402d44&&(_0x402d44=!0x0),!this['_updatable']||!this['_isReady'])return this;this['beforeUpdateParticles'](_0x18b09a,_0x5202ee,_0x402d44);var _0x36c5c6=_0x74d525['c']['Matrix'][0x0],_0x5dd8c8=this['mesh'],_0x4ecce8=this['_colors32'],_0x4695d0=this['_positions32'],_0xe17ab5=this['_uvs32'],_0x342aca=_0x74d525['c']['Vector3'],_0x8c59d1=_0x342aca[0x5]['copyFromFloats'](0x1,0x0,0x0),_0x462572=_0x342aca[0x6]['copyFromFloats'](0x0,0x1,0x0),_0x172e79=_0x342aca[0x7]['copyFromFloats'](0x0,0x0,0x1),_0x1eb216=_0x342aca[0x8]['setAll'](Number['MAX_VALUE']),_0x248d43=_0x342aca[0x9]['setAll'](-Number['MAX_VALUE']);_0x74d525['a']['IdentityToRef'](_0x36c5c6);var _0xc6f3bc=0x0;if(this['mesh']['isFacetDataEnabled']&&(this['_computeBoundingBox']=!0x0),_0x5202ee=_0x5202ee>=this['nbParticles']?this['nbParticles']-0x1:_0x5202ee,this['_computeBoundingBox']&&(0x0!=_0x18b09a||_0x5202ee!=this['nbParticles']-0x1)){var _0x4516a3=this['mesh']['_boundingInfo'];_0x4516a3&&(_0x1eb216['copyFrom'](_0x4516a3['minimum']),_0x248d43['copyFrom'](_0x4516a3['maximum']));}_0xc6f3bc=0x0;for(var _0x33a320=0x0,_0x29f7f6=0x0,_0x5afcd3=0x0,_0x4a90fa=_0x18b09a;_0x4a90fa<=_0x5202ee;_0x4a90fa++){var _0x8fafcf=this['particles'][_0x4a90fa];_0x33a320=0x3*(_0xc6f3bc=_0x8fafcf['idx']),_0x29f7f6=0x4*_0xc6f3bc,_0x5afcd3=0x2*_0xc6f3bc,this['updateParticle'](_0x8fafcf);var _0x8ffa5f=_0x8fafcf['_rotationMatrix'],_0x61428e=_0x8fafcf['position'],_0x499935=_0x8fafcf['_globalPosition'];if(this['_computeParticleRotation']&&_0x8fafcf['getRotationMatrix'](_0x36c5c6),null!==_0x8fafcf['parentId']){var _0x3f41fd=this['particles'][_0x8fafcf['parentId']],_0x15aee8=_0x3f41fd['_rotationMatrix'],_0x528bbf=_0x3f41fd['_globalPosition'],_0x1dd6dc=_0x61428e['x']*_0x15aee8[0x1]+_0x61428e['y']*_0x15aee8[0x4]+_0x61428e['z']*_0x15aee8[0x7],_0x4101ef=_0x61428e['x']*_0x15aee8[0x0]+_0x61428e['y']*_0x15aee8[0x3]+_0x61428e['z']*_0x15aee8[0x6],_0x867de7=_0x61428e['x']*_0x15aee8[0x2]+_0x61428e['y']*_0x15aee8[0x5]+_0x61428e['z']*_0x15aee8[0x8];if(_0x499935['x']=_0x528bbf['x']+_0x4101ef,_0x499935['y']=_0x528bbf['y']+_0x1dd6dc,_0x499935['z']=_0x528bbf['z']+_0x867de7,this['_computeParticleRotation']){var _0x366e33=_0x36c5c6['m'];_0x8ffa5f[0x0]=_0x366e33[0x0]*_0x15aee8[0x0]+_0x366e33[0x1]*_0x15aee8[0x3]+_0x366e33[0x2]*_0x15aee8[0x6],_0x8ffa5f[0x1]=_0x366e33[0x0]*_0x15aee8[0x1]+_0x366e33[0x1]*_0x15aee8[0x4]+_0x366e33[0x2]*_0x15aee8[0x7],_0x8ffa5f[0x2]=_0x366e33[0x0]*_0x15aee8[0x2]+_0x366e33[0x1]*_0x15aee8[0x5]+_0x366e33[0x2]*_0x15aee8[0x8],_0x8ffa5f[0x3]=_0x366e33[0x4]*_0x15aee8[0x0]+_0x366e33[0x5]*_0x15aee8[0x3]+_0x366e33[0x6]*_0x15aee8[0x6],_0x8ffa5f[0x4]=_0x366e33[0x4]*_0x15aee8[0x1]+_0x366e33[0x5]*_0x15aee8[0x4]+_0x366e33[0x6]*_0x15aee8[0x7],_0x8ffa5f[0x5]=_0x366e33[0x4]*_0x15aee8[0x2]+_0x366e33[0x5]*_0x15aee8[0x5]+_0x366e33[0x6]*_0x15aee8[0x8],_0x8ffa5f[0x6]=_0x366e33[0x8]*_0x15aee8[0x0]+_0x366e33[0x9]*_0x15aee8[0x3]+_0x366e33[0xa]*_0x15aee8[0x6],_0x8ffa5f[0x7]=_0x366e33[0x8]*_0x15aee8[0x1]+_0x366e33[0x9]*_0x15aee8[0x4]+_0x366e33[0xa]*_0x15aee8[0x7],_0x8ffa5f[0x8]=_0x366e33[0x8]*_0x15aee8[0x2]+_0x366e33[0x9]*_0x15aee8[0x5]+_0x366e33[0xa]*_0x15aee8[0x8];}}else(_0x499935['x']=0x0,_0x499935['y']=0x0,_0x499935['z']=0x0,this['_computeParticleRotation'])&&(_0x366e33=_0x36c5c6['m'],(_0x8ffa5f[0x0]=_0x366e33[0x0],_0x8ffa5f[0x1]=_0x366e33[0x1],_0x8ffa5f[0x2]=_0x366e33[0x2],_0x8ffa5f[0x3]=_0x366e33[0x4],_0x8ffa5f[0x4]=_0x366e33[0x5],_0x8ffa5f[0x5]=_0x366e33[0x6],_0x8ffa5f[0x6]=_0x366e33[0x8],_0x8ffa5f[0x7]=_0x366e33[0x9],_0x8ffa5f[0x8]=_0x366e33[0xa]));var _0x59b980=_0x342aca[0xb];_0x8fafcf['translateFromPivot']?_0x59b980['setAll'](0x0):_0x59b980['copyFrom'](_0x8fafcf['pivot']);var _0x3938c0=_0x342aca[0x0];_0x3938c0['copyFrom'](_0x8fafcf['position']);var _0x574c40=_0x3938c0['x']-_0x8fafcf['pivot']['x'],_0x5eee33=_0x3938c0['y']-_0x8fafcf['pivot']['y'],_0x5b42bd=_0x3938c0['z']-_0x8fafcf['pivot']['z'],_0x2ff740=_0x574c40*_0x8ffa5f[0x0]+_0x5eee33*_0x8ffa5f[0x3]+_0x5b42bd*_0x8ffa5f[0x6],_0x413694=_0x574c40*_0x8ffa5f[0x1]+_0x5eee33*_0x8ffa5f[0x4]+_0x5b42bd*_0x8ffa5f[0x7],_0xb80508=_0x574c40*_0x8ffa5f[0x2]+_0x5eee33*_0x8ffa5f[0x5]+_0x5b42bd*_0x8ffa5f[0x8];_0x2ff740+=_0x59b980['x'],_0x413694+=_0x59b980['y'],_0xb80508+=_0x59b980['z'];var _0x4790f9=_0x4695d0[_0x33a320]=_0x499935['x']+_0x8c59d1['x']*_0x2ff740+_0x462572['x']*_0x413694+_0x172e79['x']*_0xb80508,_0x1fd4d1=_0x4695d0[_0x33a320+0x1]=_0x499935['y']+_0x8c59d1['y']*_0x2ff740+_0x462572['y']*_0x413694+_0x172e79['y']*_0xb80508,_0x40a3d1=_0x4695d0[_0x33a320+0x2]=_0x499935['z']+_0x8c59d1['z']*_0x2ff740+_0x462572['z']*_0x413694+_0x172e79['z']*_0xb80508;if(this['_computeBoundingBox']&&(_0x1eb216['minimizeInPlaceFromFloats'](_0x4790f9,_0x1fd4d1,_0x40a3d1),_0x248d43['maximizeInPlaceFromFloats'](_0x4790f9,_0x1fd4d1,_0x40a3d1)),this['_computeParticleColor']&&_0x8fafcf['color']){var _0x38b434=_0x8fafcf['color'],_0x4b7226=this['_colors32'];_0x4b7226[_0x29f7f6]=_0x38b434['r'],_0x4b7226[_0x29f7f6+0x1]=_0x38b434['g'],_0x4b7226[_0x29f7f6+0x2]=_0x38b434['b'],_0x4b7226[_0x29f7f6+0x3]=_0x38b434['a'];}if(this['_computeParticleTexture']&&_0x8fafcf['uv']){var _0x3a0e37=_0x8fafcf['uv'],_0x45f1f1=this['_uvs32'];_0x45f1f1[_0x5afcd3]=_0x3a0e37['x'],_0x45f1f1[_0x5afcd3+0x1]=_0x3a0e37['y'];}}return _0x402d44&&(this['_computeParticleColor']&&_0x5dd8c8['updateVerticesData'](_0x212fbd['b']['ColorKind'],_0x4ecce8,!0x1,!0x1),this['_computeParticleTexture']&&_0x5dd8c8['updateVerticesData'](_0x212fbd['b']['UVKind'],_0xe17ab5,!0x1,!0x1),_0x5dd8c8['updateVerticesData'](_0x212fbd['b']['PositionKind'],_0x4695d0,!0x1,!0x1)),this['_computeBoundingBox']&&(_0x5dd8c8['_boundingInfo']?_0x5dd8c8['_boundingInfo']['reConstruct'](_0x1eb216,_0x248d43,_0x5dd8c8['_worldMatrix']):_0x5dd8c8['_boundingInfo']=new _0x386a4b['a'](_0x1eb216,_0x248d43,_0x5dd8c8['_worldMatrix'])),this['afterUpdateParticles'](_0x18b09a,_0x5202ee,_0x402d44),this;},_0x3ec7df['prototype']['dispose']=function(){this['mesh']['dispose'](),this['vars']=null,this['_positions']=null,this['_indices']=null,this['_normals']=null,this['_uvs']=null,this['_colors']=null,this['_indices32']=null,this['_positions32']=null,this['_uvs32']=null,this['_colors32']=null;},_0x3ec7df['prototype']['refreshVisibleSize']=function(){return this['_isVisibilityBoxLocked']||this['mesh']['refreshBoundingInfo'](),this;},_0x3ec7df['prototype']['setVisibilityBox']=function(_0x26a0b){var _0x2c9106=_0x26a0b/0x2;this['mesh']['_boundingInfo']=new _0x386a4b['a'](new _0x74d525['e'](-_0x2c9106,-_0x2c9106,-_0x2c9106),new _0x74d525['e'](_0x2c9106,_0x2c9106,_0x2c9106));},Object['defineProperty'](_0x3ec7df['prototype'],'isAlwaysVisible',{'get':function(){return this['_alwaysVisible'];},'set':function(_0x36fc55){this['_alwaysVisible']=_0x36fc55,this['mesh']['alwaysSelectAsActiveMesh']=_0x36fc55;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3ec7df['prototype'],'computeParticleRotation',{'set':function(_0x39d030){this['_computeParticleRotation']=_0x39d030;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3ec7df['prototype'],'computeParticleColor',{'get':function(){return this['_computeParticleColor'];},'set':function(_0x461aff){this['_computeParticleColor']=_0x461aff;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3ec7df['prototype'],'computeParticleTexture',{'get':function(){return this['_computeParticleTexture'];},'set':function(_0x35078c){this['_computeParticleTexture']=_0x35078c;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3ec7df['prototype'],'computeBoundingBox',{'get':function(){return this['_computeBoundingBox'];},'set':function(_0x44868d){this['_computeBoundingBox']=_0x44868d;},'enumerable':!0x1,'configurable':!0x0}),_0x3ec7df['prototype']['initParticles']=function(){},_0x3ec7df['prototype']['recycleParticle']=function(_0xc09c1a){return _0xc09c1a;},_0x3ec7df['prototype']['updateParticle']=function(_0x20bacd){return _0x20bacd;},_0x3ec7df['prototype']['beforeUpdateParticles']=function(_0x34fde1,_0x38ee8d,_0xed0720){},_0x3ec7df['prototype']['afterUpdateParticles']=function(_0x4a18da,_0x28b760,_0x4a7a3f){},_0x3ec7df;}());_0x59370b['a']['prototype']['getPhysicsEngine']=function(){return this['_physicsEngine'];},_0x59370b['a']['prototype']['enablePhysics']=function(_0xb3aacc,_0x39a471){if(void 0x0===_0xb3aacc&&(_0xb3aacc=null),this['_physicsEngine'])return!0x0;var _0x5b34c3=this['_getComponent'](_0x384de3['a']['NAME_PHYSICSENGINE']);_0x5b34c3||(_0x5b34c3=new _0x4e10cf(this),this['_addComponent'](_0x5b34c3));try{return this['_physicsEngine']=new _0x598ff1(_0xb3aacc,_0x39a471),this['_physicsTimeAccumulator']=0x0,!0x0;}catch(_0x3df49d){return _0x75193d['a']['Error'](_0x3df49d['message']),!0x1;}},_0x59370b['a']['prototype']['disablePhysicsEngine']=function(){this['_physicsEngine']&&(this['_physicsEngine']['dispose'](),this['_physicsEngine']=null);},_0x59370b['a']['prototype']['isPhysicsEnabled']=function(){return void 0x0!==this['_physicsEngine'];},_0x59370b['a']['prototype']['deleteCompoundImpostor']=function(_0x59979c){var _0x2c5717=_0x59979c['parts'][0x0]['mesh'];_0x2c5717['physicsImpostor']&&(_0x2c5717['physicsImpostor']['dispose'](),_0x2c5717['physicsImpostor']=null);},_0x59370b['a']['prototype']['_advancePhysicsEngineStep']=function(_0x3e0d01){if(this['_physicsEngine']){var _0x5bdc73=this['_physicsEngine']['getSubTimeStep']();if(_0x5bdc73>0x0){for(this['_physicsTimeAccumulator']+=_0x3e0d01;this['_physicsTimeAccumulator']>_0x5bdc73;)this['onBeforePhysicsObservable']['notifyObservers'](this),this['_physicsEngine']['_step'](_0x5bdc73/0x3e8),this['onAfterPhysicsObservable']['notifyObservers'](this),this['_physicsTimeAccumulator']-=_0x5bdc73;}else this['onBeforePhysicsObservable']['notifyObservers'](this),this['_physicsEngine']['_step'](_0x3e0d01/0x3e8),this['onAfterPhysicsObservable']['notifyObservers'](this);}},Object['defineProperty'](_0x40d22e['a']['prototype'],'physicsImpostor',{'get':function(){return this['_physicsImpostor'];},'set':function(_0x1f5dcd){var _0x635df3=this;this['_physicsImpostor']!==_0x1f5dcd&&(this['_disposePhysicsObserver']&&this['onDisposeObservable']['remove'](this['_disposePhysicsObserver']),this['_physicsImpostor']=_0x1f5dcd,_0x1f5dcd&&(this['_disposePhysicsObserver']=this['onDisposeObservable']['add'](function(){_0x635df3['physicsImpostor']&&(_0x635df3['physicsImpostor']['dispose'](),_0x635df3['physicsImpostor']=null);})));},'enumerable':!0x0,'configurable':!0x0}),_0x40d22e['a']['prototype']['getPhysicsImpostor']=function(){return this['physicsImpostor'];},_0x40d22e['a']['prototype']['applyImpulse']=function(_0x2397a3,_0x361a62){return this['physicsImpostor']?(this['physicsImpostor']['applyImpulse'](_0x2397a3,_0x361a62),this):this;},_0x40d22e['a']['prototype']['setPhysicsLinkWith']=function(_0x4d9ee6,_0x432f0a,_0x395851,_0x4a62a1){return this['physicsImpostor']&&_0x4d9ee6['physicsImpostor']?(this['physicsImpostor']['createJoint'](_0x4d9ee6['physicsImpostor'],_0x288b05['e']['HingeJoint'],{'mainPivot':_0x432f0a,'connectedPivot':_0x395851,'nativeParams':_0x4a62a1}),this):this;};var _0x27983e,_0x43cb3d,_0x4e10cf=(function(){function _0x2bbfe9(_0x434eb2){var _0x5aac67=this;this['name']=_0x384de3['a']['NAME_PHYSICSENGINE'],this['scene']=_0x434eb2,this['scene']['onBeforePhysicsObservable']=new _0x6ac1f7['c'](),this['scene']['onAfterPhysicsObservable']=new _0x6ac1f7['c'](),this['scene']['getDeterministicFrameTime']=function(){return _0x5aac67['scene']['_physicsEngine']?0x3e8*_0x5aac67['scene']['_physicsEngine']['getTimeStep']():0x3e8/0x3c;};}return _0x2bbfe9['prototype']['register']=function(){},_0x2bbfe9['prototype']['rebuild']=function(){},_0x2bbfe9['prototype']['dispose']=function(){this['scene']['onBeforePhysicsObservable']['clear'](),this['scene']['onAfterPhysicsObservable']['clear'](),this['scene']['_physicsEngine']&&this['scene']['disablePhysicsEngine']();},_0x2bbfe9;}()),_0x407b6b=(function(){function _0x379dd6(_0x39c41e){this['_scene']=_0x39c41e,this['_physicsEngine']=this['_scene']['getPhysicsEngine'](),this['_physicsEngine']||_0x75193d['a']['Warn']('Physics\x20engine\x20not\x20enabled.\x20Please\x20enable\x20the\x20physics\x20before\x20you\x20can\x20use\x20the\x20methods.');}return _0x379dd6['prototype']['applyRadialExplosionImpulse']=function(_0x517aa9,_0x321c0d,_0x4a5916,_0x3ab44a){if(!this['_physicsEngine'])return _0x75193d['a']['Warn']('Physics\x20engine\x20not\x20enabled.\x20Please\x20enable\x20the\x20physics\x20before\x20you\x20call\x20this\x20method.'),null;var _0x368372=this['_physicsEngine']['getImpostors']();if(0x0===_0x368372['length'])return null;'number'==typeof _0x321c0d&&((_0x321c0d=new _0x2cb9ab())['radius']=_0x321c0d,_0x321c0d['strength']=_0x4a5916||_0x321c0d['strength'],_0x321c0d['falloff']=_0x3ab44a||_0x321c0d['falloff']);var _0x545eb9=new _0x421853(this['_scene'],_0x321c0d),_0xe5508b=Array();return _0x368372['forEach'](function(_0x502858){var _0x4edb91=_0x545eb9['getImpostorHitData'](_0x502858,_0x517aa9);_0x4edb91&&(_0x502858['applyImpulse'](_0x4edb91['force'],_0x4edb91['contactPoint']),_0xe5508b['push']({'impostor':_0x502858,'hitData':_0x4edb91}));}),_0x545eb9['triggerAffectedImpostorsCallback'](_0xe5508b),_0x545eb9['dispose'](!0x1),_0x545eb9;},_0x379dd6['prototype']['applyRadialExplosionForce']=function(_0x1597ae,_0x3bb1a7,_0x5cde69,_0x5ba591){if(!this['_physicsEngine'])return _0x75193d['a']['Warn']('Physics\x20engine\x20not\x20enabled.\x20Please\x20enable\x20the\x20physics\x20before\x20you\x20call\x20the\x20PhysicsHelper.'),null;var _0x1a27d=this['_physicsEngine']['getImpostors']();if(0x0===_0x1a27d['length'])return null;'number'==typeof _0x3bb1a7&&((_0x3bb1a7=new _0x2cb9ab())['radius']=_0x3bb1a7,_0x3bb1a7['strength']=_0x5cde69||_0x3bb1a7['strength'],_0x3bb1a7['falloff']=_0x5ba591||_0x3bb1a7['falloff']);var _0x36195c=new _0x421853(this['_scene'],_0x3bb1a7),_0x1a8daf=Array();return _0x1a27d['forEach'](function(_0x23c9f4){var _0x472ecf=_0x36195c['getImpostorHitData'](_0x23c9f4,_0x1597ae);_0x472ecf&&(_0x23c9f4['applyForce'](_0x472ecf['force'],_0x472ecf['contactPoint']),_0x1a8daf['push']({'impostor':_0x23c9f4,'hitData':_0x472ecf}));}),_0x36195c['triggerAffectedImpostorsCallback'](_0x1a8daf),_0x36195c['dispose'](!0x1),_0x36195c;},_0x379dd6['prototype']['gravitationalField']=function(_0x485dab,_0x389a57,_0x1e07c2,_0x4110cc){if(!this['_physicsEngine'])return _0x75193d['a']['Warn']('Physics\x20engine\x20not\x20enabled.\x20Please\x20enable\x20the\x20physics\x20before\x20you\x20call\x20the\x20PhysicsHelper.'),null;if(0x0===this['_physicsEngine']['getImpostors']()['length'])return null;'number'==typeof _0x389a57&&((_0x389a57=new _0x2cb9ab())['radius']=_0x389a57,_0x389a57['strength']=_0x1e07c2||_0x389a57['strength'],_0x389a57['falloff']=_0x4110cc||_0x389a57['falloff']);var _0x537721=new _0x23c2b4(this,this['_scene'],_0x485dab,_0x389a57);return _0x537721['dispose'](!0x1),_0x537721;},_0x379dd6['prototype']['updraft']=function(_0x453a28,_0x113dd5,_0x32f492,_0x28f8e3,_0x5c9d1f){if(!this['_physicsEngine'])return _0x75193d['a']['Warn']('Physics\x20engine\x20not\x20enabled.\x20Please\x20enable\x20the\x20physics\x20before\x20you\x20call\x20the\x20PhysicsHelper.'),null;if(0x0===this['_physicsEngine']['getImpostors']()['length'])return null;'number'==typeof _0x113dd5&&((_0x113dd5=new _0x18f929())['radius']=_0x113dd5,_0x113dd5['strength']=_0x32f492||_0x113dd5['strength'],_0x113dd5['height']=_0x28f8e3||_0x113dd5['height'],_0x113dd5['updraftMode']=_0x5c9d1f||_0x113dd5['updraftMode']);var _0x2eddb8=new _0x593b7b(this['_scene'],_0x453a28,_0x113dd5);return _0x2eddb8['dispose'](!0x1),_0x2eddb8;},_0x379dd6['prototype']['vortex']=function(_0x4b4ddd,_0x4c91ce,_0x2f60ab,_0x3711b3){if(!this['_physicsEngine'])return _0x75193d['a']['Warn']('Physics\x20engine\x20not\x20enabled.\x20Please\x20enable\x20the\x20physics\x20before\x20you\x20call\x20the\x20PhysicsHelper.'),null;if(0x0===this['_physicsEngine']['getImpostors']()['length'])return null;'number'==typeof _0x4c91ce&&((_0x4c91ce=new _0x478fbc())['radius']=_0x4c91ce,_0x4c91ce['strength']=_0x2f60ab||_0x4c91ce['strength'],_0x4c91ce['height']=_0x3711b3||_0x4c91ce['height']);var _0x5a7674=new _0x5d315f(this['_scene'],_0x4b4ddd,_0x4c91ce);return _0x5a7674['dispose'](!0x1),_0x5a7674;},_0x379dd6;}()),_0x421853=(function(){function _0x4e4999(_0x58667e,_0x834e6b){this['_scene']=_0x58667e,this['_options']=_0x834e6b,this['_dataFetched']=!0x1,this['_options']=Object(_0x18e13d['a'])(Object(_0x18e13d['a'])({},new _0x2cb9ab()),this['_options']);}return _0x4e4999['prototype']['getData']=function(){return this['_dataFetched']=!0x0,{'sphere':this['_sphere']};},_0x4e4999['prototype']['getImpostorHitData']=function(_0x1992f6,_0x3f7daa){if(0x0===_0x1992f6['mass'])return null;if(!this['_intersectsWithSphere'](_0x1992f6,_0x3f7daa,this['_options']['radius']))return null;if('Mesh'!==_0x1992f6['object']['getClassName']()&&'InstancedMesh'!==_0x1992f6['object']['getClassName']())return null;var _0x59d94a=_0x1992f6['getObjectCenter']()['subtract'](_0x3f7daa),_0x3145a7=new _0x36fb4d['a'](_0x3f7daa,_0x59d94a,this['_options']['radius'])['intersectsMesh'](_0x1992f6['object'])['pickedPoint'];if(!_0x3145a7)return null;var _0x28d0b2=_0x74d525['e']['Distance'](_0x3f7daa,_0x3145a7);if(_0x28d0b2>this['_options']['radius'])return null;var _0xf4ff4f=this['_options']['falloff']===_0x27983e['Constant']?this['_options']['strength']:this['_options']['strength']*(0x1-_0x28d0b2/this['_options']['radius']);return{'force':_0x59d94a['multiplyByFloats'](_0xf4ff4f,_0xf4ff4f,_0xf4ff4f),'contactPoint':_0x3145a7,'distanceFromOrigin':_0x28d0b2};},_0x4e4999['prototype']['triggerAffectedImpostorsCallback']=function(_0x4ef121){this['_options']['affectedImpostorsCallback']&&this['_options']['affectedImpostorsCallback'](_0x4ef121);},_0x4e4999['prototype']['dispose']=function(_0xb89a75){var _0x2905f9=this;void 0x0===_0xb89a75&&(_0xb89a75=!0x0),_0xb89a75?this['_sphere']['dispose']():setTimeout(function(){_0x2905f9['_dataFetched']||_0x2905f9['_sphere']['dispose']();},0x0);},_0x4e4999['prototype']['_prepareSphere']=function(){this['_sphere']||(this['_sphere']=_0x5c4f8d['a']['CreateSphere']('radialExplosionEventSphere',this['_options']['sphere'],this['_scene']),this['_sphere']['isVisible']=!0x1);},_0x4e4999['prototype']['_intersectsWithSphere']=function(_0x393cf7,_0x56f3b2,_0x1eea50){var _0x224e89=_0x393cf7['object'];return this['_prepareSphere'](),this['_sphere']['position']=_0x56f3b2,this['_sphere']['scaling']=new _0x74d525['e'](0x2*_0x1eea50,0x2*_0x1eea50,0x2*_0x1eea50),this['_sphere']['_updateBoundingInfo'](),this['_sphere']['computeWorldMatrix'](!0x0),this['_sphere']['intersectsMesh'](_0x224e89,!0x0);},_0x4e4999;}()),_0x23c2b4=(function(){function _0x4d3088(_0x1734e7,_0x40e778,_0x1f20cd,_0x24d81c){this['_physicsHelper']=_0x1734e7,this['_scene']=_0x40e778,this['_origin']=_0x1f20cd,this['_options']=_0x24d81c,this['_dataFetched']=!0x1,this['_options']=Object(_0x18e13d['a'])(Object(_0x18e13d['a'])({},new _0x2cb9ab()),this['_options']),this['_tickCallback']=this['_tick']['bind'](this),this['_options']['strength']=-0x1*this['_options']['strength'];}return _0x4d3088['prototype']['getData']=function(){return this['_dataFetched']=!0x0,{'sphere':this['_sphere']};},_0x4d3088['prototype']['enable']=function(){this['_tickCallback']['call'](this),this['_scene']['registerBeforeRender'](this['_tickCallback']);},_0x4d3088['prototype']['disable']=function(){this['_scene']['unregisterBeforeRender'](this['_tickCallback']);},_0x4d3088['prototype']['dispose']=function(_0x2b13d0){var _0x232e88=this;void 0x0===_0x2b13d0&&(_0x2b13d0=!0x0),_0x2b13d0?this['_sphere']['dispose']():setTimeout(function(){_0x232e88['_dataFetched']||_0x232e88['_sphere']['dispose']();},0x0);},_0x4d3088['prototype']['_tick']=function(){if(this['_sphere'])this['_physicsHelper']['applyRadialExplosionForce'](this['_origin'],this['_options']);else{var _0x24c928=this['_physicsHelper']['applyRadialExplosionForce'](this['_origin'],this['_options']);_0x24c928&&(this['_sphere']=_0x24c928['getData']()['sphere']['clone']('radialExplosionEventSphereClone'));}},_0x4d3088;}()),_0x593b7b=(function(){function _0x2e1dba(_0x326ef0,_0xebd3ed,_0x420620){this['_scene']=_0x326ef0,this['_origin']=_0xebd3ed,this['_options']=_0x420620,this['_originTop']=_0x74d525['e']['Zero'](),this['_originDirection']=_0x74d525['e']['Zero'](),this['_cylinderPosition']=_0x74d525['e']['Zero'](),this['_dataFetched']=!0x1,this['_physicsEngine']=this['_scene']['getPhysicsEngine'](),this['_options']=Object(_0x18e13d['a'])(Object(_0x18e13d['a'])({},new _0x18f929()),this['_options']),this['_origin']['addToRef'](new _0x74d525['e'](0x0,this['_options']['height']/0x2,0x0),this['_cylinderPosition']),this['_origin']['addToRef'](new _0x74d525['e'](0x0,this['_options']['height'],0x0),this['_originTop']),this['_options']['updraftMode']===_0x43cb3d['Perpendicular']&&(this['_originDirection']=this['_origin']['subtract'](this['_originTop'])['normalize']()),this['_tickCallback']=this['_tick']['bind'](this),this['_prepareCylinder']();}return _0x2e1dba['prototype']['getData']=function(){return this['_dataFetched']=!0x0,{'cylinder':this['_cylinder']};},_0x2e1dba['prototype']['enable']=function(){this['_tickCallback']['call'](this),this['_scene']['registerBeforeRender'](this['_tickCallback']);},_0x2e1dba['prototype']['disable']=function(){this['_scene']['unregisterBeforeRender'](this['_tickCallback']);},_0x2e1dba['prototype']['dispose']=function(_0x82bf4d){var _0x3cf9f2=this;void 0x0===_0x82bf4d&&(_0x82bf4d=!0x0),this['_cylinder']&&(_0x82bf4d?this['_cylinder']['dispose']():setTimeout(function(){_0x3cf9f2['_dataFetched']||_0x3cf9f2['_cylinder']['dispose']();},0x0));},_0x2e1dba['prototype']['getImpostorHitData']=function(_0x4e919a){if(0x0===_0x4e919a['mass'])return null;if(!this['_intersectsWithCylinder'](_0x4e919a))return null;var _0x28588c=_0x4e919a['getObjectCenter']();if(this['_options']['updraftMode']===_0x43cb3d['Perpendicular'])var _0x4430b7=this['_originDirection'];else _0x4430b7=_0x28588c['subtract'](this['_originTop']);var _0x2dc6a0=_0x74d525['e']['Distance'](this['_origin'],_0x28588c),_0xb0eb70=-0x1*this['_options']['strength'];return{'force':_0x4430b7['multiplyByFloats'](_0xb0eb70,_0xb0eb70,_0xb0eb70),'contactPoint':_0x28588c,'distanceFromOrigin':_0x2dc6a0};},_0x2e1dba['prototype']['_tick']=function(){var _0xc120a4=this;this['_physicsEngine']['getImpostors']()['forEach'](function(_0x5876ce){var _0x482548=_0xc120a4['getImpostorHitData'](_0x5876ce);_0x482548&&_0x5876ce['applyForce'](_0x482548['force'],_0x482548['contactPoint']);});},_0x2e1dba['prototype']['_prepareCylinder']=function(){this['_cylinder']||(this['_cylinder']=_0x179064['a']['CreateCylinder']('updraftEventCylinder',{'height':this['_options']['height'],'diameter':0x2*this['_options']['radius']},this['_scene']),this['_cylinder']['isVisible']=!0x1);},_0x2e1dba['prototype']['_intersectsWithCylinder']=function(_0x28dfc3){var _0xc3536f=_0x28dfc3['object'];return this['_cylinder']['position']=this['_cylinderPosition'],this['_cylinder']['intersectsMesh'](_0xc3536f,!0x0);},_0x2e1dba;}()),_0x5d315f=(function(){function _0x5b3444(_0x103da5,_0x1d76f5,_0x1eed33){this['_scene']=_0x103da5,this['_origin']=_0x1d76f5,this['_options']=_0x1eed33,this['_originTop']=_0x74d525['e']['Zero'](),this['_cylinderPosition']=_0x74d525['e']['Zero'](),this['_dataFetched']=!0x1,this['_physicsEngine']=this['_scene']['getPhysicsEngine'](),this['_options']=Object(_0x18e13d['a'])(Object(_0x18e13d['a'])({},new _0x478fbc()),this['_options']),this['_origin']['addToRef'](new _0x74d525['e'](0x0,this['_options']['height']/0x2,0x0),this['_cylinderPosition']),this['_origin']['addToRef'](new _0x74d525['e'](0x0,this['_options']['height'],0x0),this['_originTop']),this['_tickCallback']=this['_tick']['bind'](this),this['_prepareCylinder']();}return _0x5b3444['prototype']['getData']=function(){return this['_dataFetched']=!0x0,{'cylinder':this['_cylinder']};},_0x5b3444['prototype']['enable']=function(){this['_tickCallback']['call'](this),this['_scene']['registerBeforeRender'](this['_tickCallback']);},_0x5b3444['prototype']['disable']=function(){this['_scene']['unregisterBeforeRender'](this['_tickCallback']);},_0x5b3444['prototype']['dispose']=function(_0x4d916e){var _0x1a12fa=this;void 0x0===_0x4d916e&&(_0x4d916e=!0x0),_0x4d916e?this['_cylinder']['dispose']():setTimeout(function(){_0x1a12fa['_dataFetched']||_0x1a12fa['_cylinder']['dispose']();},0x0);},_0x5b3444['prototype']['getImpostorHitData']=function(_0x356845){if(0x0===_0x356845['mass'])return null;if(!this['_intersectsWithCylinder'](_0x356845))return null;if('Mesh'!==_0x356845['object']['getClassName']()&&'InstancedMesh'!==_0x356845['object']['getClassName']())return null;var _0x39cae9=_0x356845['getObjectCenter'](),_0x4cfedf=new _0x74d525['e'](this['_origin']['x'],_0x39cae9['y'],this['_origin']['z']),_0x289ff3=_0x39cae9['subtract'](_0x4cfedf),_0x4b7c58=new _0x36fb4d['a'](_0x4cfedf,_0x289ff3,this['_options']['radius'])['intersectsMesh'](_0x356845['object']),_0x4de8c5=_0x4b7c58['pickedPoint'];if(!_0x4de8c5)return null;var _0x2ab5ed=_0x4b7c58['distance']/this['_options']['radius'],_0x49fec8=_0x4de8c5['normalize']();if(_0x2ab5ed>this['_options']['centripetalForceThreshold']&&(_0x49fec8=_0x49fec8['negate']()),_0x2ab5ed>this['_options']['centripetalForceThreshold'])var _0x5aab7c=_0x49fec8['x']*this['_options']['centripetalForceMultiplier'],_0x212f59=_0x49fec8['y']*this['_options']['updraftForceMultiplier'],_0xad1056=_0x49fec8['z']*this['_options']['centripetalForceMultiplier'];else{var _0x31093f=_0x74d525['e']['Cross'](_0x4cfedf,_0x39cae9)['normalize']();_0x5aab7c=(_0x31093f['x']+_0x49fec8['x'])*this['_options']['centrifugalForceMultiplier'],_0x212f59=this['_originTop']['y']*this['_options']['updraftForceMultiplier'],_0xad1056=(_0x31093f['z']+_0x49fec8['z'])*this['_options']['centrifugalForceMultiplier'];}var _0x4a76dc=new _0x74d525['e'](_0x5aab7c,_0x212f59,_0xad1056);return{'force':_0x4a76dc=_0x4a76dc['multiplyByFloats'](this['_options']['strength'],this['_options']['strength'],this['_options']['strength']),'contactPoint':_0x39cae9,'distanceFromOrigin':_0x2ab5ed};},_0x5b3444['prototype']['_tick']=function(){var _0x1660cb=this;this['_physicsEngine']['getImpostors']()['forEach'](function(_0x53af25){var _0x316ddb=_0x1660cb['getImpostorHitData'](_0x53af25);_0x316ddb&&_0x53af25['applyForce'](_0x316ddb['force'],_0x316ddb['contactPoint']);});},_0x5b3444['prototype']['_prepareCylinder']=function(){this['_cylinder']||(this['_cylinder']=_0x179064['a']['CreateCylinder']('vortexEventCylinder',{'height':this['_options']['height'],'diameter':0x2*this['_options']['radius']},this['_scene']),this['_cylinder']['isVisible']=!0x1);},_0x5b3444['prototype']['_intersectsWithCylinder']=function(_0x4d111a){var _0x34f921=_0x4d111a['object'];return this['_cylinder']['position']=this['_cylinderPosition'],this['_cylinder']['intersectsMesh'](_0x34f921,!0x0);},_0x5b3444;}()),_0x2cb9ab=function(){this['radius']=0x5,this['strength']=0xa,this['falloff']=_0x27983e['Constant'],this['sphere']={'segments':0x20,'diameter':0x1};},_0x18f929=function(){this['radius']=0x5,this['strength']=0xa,this['height']=0xa,this['updraftMode']=_0x43cb3d['Center'];},_0x478fbc=function(){this['radius']=0x5,this['strength']=0xa,this['height']=0xa,this['centripetalForceThreshold']=0.7,this['centripetalForceMultiplier']=0x5,this['centrifugalForceMultiplier']=0.5,this['updraftForceMultiplier']=0.02;};!function(_0x29582f){_0x29582f[_0x29582f['Constant']=0x0]='Constant',_0x29582f[_0x29582f['Linear']=0x1]='Linear';}(_0x27983e||(_0x27983e={})),function(_0x3f45bf){_0x3f45bf[_0x3f45bf['Center']=0x0]='Center',_0x3f45bf[_0x3f45bf['Perpendicular']=0x1]='Perpendicular';}(_0x43cb3d||(_0x43cb3d={}));var _0xf788a0='\x0avarying\x20vec2\x20vUV;\x0auniform\x20sampler2D\x20textureSampler;\x0auniform\x20float\x20degree;\x0avoid\x20main(void)\x0a{\x0avec3\x20color=texture2D(textureSampler,vUV).rgb;\x0afloat\x20luminance=dot(color,vec3(0.3,0.59,0.11));\x0avec3\x20blackAndWhite=vec3(luminance,luminance,luminance);\x0agl_FragColor=vec4(color-((color-blackAndWhite)*degree),1.0);\x0a}';_0x494b01['a']['ShadersStore']['blackAndWhitePixelShader']=_0xf788a0;var _0x574bf7=function(_0x56d000){function _0x181ff5(_0x47a494,_0x5d8feb,_0x2e03ad,_0x4d00a7,_0x2771a0,_0x5c3d40){var _0x2de846=_0x56d000['call'](this,_0x47a494,'blackAndWhite',['degree'],null,_0x5d8feb,_0x2e03ad,_0x4d00a7,_0x2771a0,_0x5c3d40)||this;return _0x2de846['degree']=0x1,_0x2de846['onApplyObservable']['add'](function(_0xb21594){_0xb21594['setFloat']('degree',_0x2de846['degree']);}),_0x2de846;}return Object(_0x18e13d['d'])(_0x181ff5,_0x56d000),_0x181ff5['prototype']['getClassName']=function(){return'BlackAndWhitePostProcess';},_0x181ff5['_Parse']=function(_0x24fbea,_0x58caae,_0xb74213,_0x312a46){return _0x495d06['a']['Parse'](function(){return new _0x181ff5(_0x24fbea['name'],_0x24fbea['options'],_0x58caae,_0x24fbea['renderTargetSamplingMode'],_0xb74213['getEngine'](),_0x24fbea['reusable']);},_0x24fbea,_0xb74213,_0x312a46);},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x181ff5['prototype'],'degree',void 0x0),_0x181ff5;}(_0x5cae84);_0x3cd573['a']['RegisteredTypes']['BABYLON.BlackAndWhitePostProcess']=_0x574bf7;var _0x1f6f7e=(function(){function _0x1f9ec4(_0x228d60,_0x33657e,_0x544f05,_0x35738e){this['_name']=_0x33657e,this['_singleInstance']=_0x35738e||!0x0,this['_getPostProcesses']=_0x544f05,this['_cameras']={},this['_indicesForCamera']={},this['_postProcesses']={};}return Object['defineProperty'](_0x1f9ec4['prototype'],'isSupported',{'get':function(){for(var _0x43b450 in this['_postProcesses'])if(this['_postProcesses']['hasOwnProperty'](_0x43b450)){for(var _0x38c400=this['_postProcesses'][_0x43b450],_0x2d11b9=0x0;_0x2d11b9<_0x38c400['length'];_0x2d11b9++)if(!_0x38c400[_0x2d11b9]['isSupported'])return!0x1;}return!0x0;},'enumerable':!0x1,'configurable':!0x0}),_0x1f9ec4['prototype']['_update']=function(){},_0x1f9ec4['prototype']['_attachCameras']=function(_0x5c2c7f){var _0x2f6762,_0x2b4738=this,_0x28381d=_0x5d754c['b']['MakeArray'](_0x5c2c7f||this['_cameras']);if(_0x28381d)for(var _0x4acf9d=0x0;_0x4acf9d<_0x28381d['length'];_0x4acf9d++){var _0x43b7b2=_0x28381d[_0x4acf9d];if(_0x43b7b2){var _0x294b15=_0x43b7b2['name'];if(_0x2f6762=this['_singleInstance']?0x0:_0x294b15,!this['_postProcesses'][_0x2f6762]){var _0xab6b6=this['_getPostProcesses']();_0xab6b6&&(this['_postProcesses'][_0x2f6762]=Array['isArray'](_0xab6b6)?_0xab6b6:[_0xab6b6]);}this['_indicesForCamera'][_0x294b15]||(this['_indicesForCamera'][_0x294b15]=[]),this['_postProcesses'][_0x2f6762]['forEach'](function(_0x844c6c){var _0x3f3ec6=_0x43b7b2['attachPostProcess'](_0x844c6c);_0x2b4738['_indicesForCamera'][_0x294b15]['push'](_0x3f3ec6);}),this['_cameras'][_0x294b15]||(this['_cameras'][_0x294b15]=_0x43b7b2);}}},_0x1f9ec4['prototype']['_detachCameras']=function(_0x4dcaab){var _0x3cff26=_0x5d754c['b']['MakeArray'](_0x4dcaab||this['_cameras']);if(_0x3cff26)for(var _0x22e728=0x0;_0x22e728<_0x3cff26['length'];_0x22e728++){var _0x986c1d=_0x3cff26[_0x22e728],_0x132955=_0x986c1d['name'],_0x288e2f=this['_postProcesses'][this['_singleInstance']?0x0:_0x132955];_0x288e2f&&_0x288e2f['forEach'](function(_0xcac13){_0x986c1d['detachPostProcess'](_0xcac13);}),this['_cameras'][_0x132955]&&(this['_cameras'][_0x132955]=null);}},_0x1f9ec4['prototype']['_enable']=function(_0x3401c1){var _0x34905d=this,_0x2109fa=_0x5d754c['b']['MakeArray'](_0x3401c1||this['_cameras']);if(_0x2109fa){for(var _0x11c43b=0x0;_0x11c43b<_0x2109fa['length'];_0x11c43b++)for(var _0x4e9b8b=_0x2109fa[_0x11c43b],_0x4f1bfe=_0x4e9b8b['name'],_0x3c1eaa=0x0;_0x3c1eaa-0x1?'#define\x20MALI\x201\x0a':null;},_0x254e9e['_Parse']=function(_0xc67efb,_0x40be0e,_0x1bf29d,_0x43f34d){return _0x495d06['a']['Parse'](function(){return new _0x254e9e(_0xc67efb['name'],_0xc67efb['options'],_0x40be0e,_0xc67efb['renderTargetSamplingMode'],_0x1bf29d['getEngine'](),_0xc67efb['reusable']);},_0xc67efb,_0x1bf29d,_0x43f34d);},_0x254e9e;}(_0x5cae84);_0x3cd573['a']['RegisteredTypes']['BABYLON.FxaaPostProcess']=_0x30558e;var _0x3fcb01='#include\x0a\x0auniform\x20sampler2D\x20textureSampler;\x0a\x0auniform\x20float\x20intensity;\x0auniform\x20float\x20animatedSeed;\x0a\x0avarying\x20vec2\x20vUV;\x0avoid\x20main(void)\x0a{\x0agl_FragColor=texture2D(textureSampler,vUV);\x0avec2\x20seed=vUV*(animatedSeed);\x0afloat\x20grain=dither(seed,intensity);\x0a\x0afloat\x20lum=getLuminance(gl_FragColor.rgb);\x0afloat\x20grainAmount=(cos(-PI+(lum*PI*2.))+1.)/2.;\x0agl_FragColor.rgb+=grain*grainAmount;\x0agl_FragColor.rgb=max(gl_FragColor.rgb,0.0);\x0a}';_0x494b01['a']['ShadersStore']['grainPixelShader']=_0x3fcb01;var _0x338247=function(_0xc7ced1){function _0x1fbab7(_0x427477,_0x35d75d,_0x228d6d,_0x55e3d1,_0x59cc0a,_0x2c9e96,_0xe621af,_0x243ba8){void 0x0===_0xe621af&&(_0xe621af=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),void 0x0===_0x243ba8&&(_0x243ba8=!0x1);var _0x702c92=_0xc7ced1['call'](this,_0x427477,'grain',['intensity','animatedSeed'],[],_0x35d75d,_0x228d6d,_0x55e3d1,_0x59cc0a,_0x2c9e96,null,_0xe621af,void 0x0,null,_0x243ba8)||this;return _0x702c92['intensity']=0x1e,_0x702c92['animated']=!0x1,_0x702c92['onApplyObservable']['add'](function(_0xec1f74){_0xec1f74['setFloat']('intensity',_0x702c92['intensity']),_0xec1f74['setFloat']('animatedSeed',_0x702c92['animated']?Math['random']()+0x1:0x1);}),_0x702c92;}return Object(_0x18e13d['d'])(_0x1fbab7,_0xc7ced1),_0x1fbab7['prototype']['getClassName']=function(){return'GrainPostProcess';},_0x1fbab7['_Parse']=function(_0x17859e,_0x1f6701,_0xbe89bc,_0x53ab5c){return _0x495d06['a']['Parse'](function(){return new _0x1fbab7(_0x17859e['name'],_0x17859e['options'],_0x1f6701,_0x17859e['renderTargetSamplingMode'],_0xbe89bc['getEngine'](),_0x17859e['reusable']);},_0x17859e,_0xbe89bc,_0x53ab5c);},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x1fbab7['prototype'],'intensity',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x1fbab7['prototype'],'animated',void 0x0),_0x1fbab7;}(_0x5cae84);_0x3cd573['a']['RegisteredTypes']['BABYLON.GrainPostProcess']=_0x338247;var _0xe12fda='\x0avarying\x20vec2\x20vUV;\x0auniform\x20sampler2D\x20textureSampler;\x0aconst\x20vec3\x20RGBLuminanceCoefficients=vec3(0.2126,0.7152,0.0722);\x0avoid\x20main(void)\x0a{\x0avec4\x20tex=texture2D(textureSampler,vUV);\x0avec3\x20c=tex.rgb;\x0afloat\x20luma=dot(c.rgb,RGBLuminanceCoefficients);\x0a\x0a\x0agl_FragColor=vec4(pow(c,vec3(25.0-luma*15.0)),tex.a);\x0a}';_0x494b01['a']['ShadersStore']['highlightsPixelShader']=_0xe12fda;var _0x47ea8e=function(_0x4aad07){function _0x5d4b3d(_0x53f059,_0x3bc66a,_0x2dd75e,_0x344a98,_0x3d1e6e,_0x13da98,_0x4064fb){return void 0x0===_0x4064fb&&(_0x4064fb=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),_0x4aad07['call'](this,_0x53f059,'highlights',null,null,_0x3bc66a,_0x2dd75e,_0x344a98,_0x3d1e6e,_0x13da98,null,_0x4064fb)||this;}return Object(_0x18e13d['d'])(_0x5d4b3d,_0x4aad07),_0x5d4b3d['prototype']['getClassName']=function(){return'HighlightsPostProcess';},_0x5d4b3d;}(_0x5cae84);_0x494b01['a']['IncludesShadersStore']['mrtFragmentDeclaration']='#if\x20__VERSION__>=200\x0alayout(location=0)\x20out\x20vec4\x20glFragData[{X}];\x0a#endif\x0a';var _0x4219cf='#extension\x20GL_EXT_draw_buffers\x20:\x20require\x0a#if\x20defined(BUMP)\x20||\x20!defined(NORMAL)\x0a#extension\x20GL_OES_standard_derivatives\x20:\x20enable\x0a#endif\x0aprecision\x20highp\x20float;\x0aprecision\x20highp\x20int;\x0a#ifdef\x20BUMP\x0avarying\x20mat4\x20vWorldView;\x0avarying\x20vec3\x20vNormalW;\x0a#else\x0avarying\x20vec3\x20vNormalV;\x0a#endif\x0avarying\x20vec4\x20vViewPos;\x0a#if\x20defined(POSITION)\x20||\x20defined(BUMP)\x0avarying\x20vec3\x20vPositionW;\x0a#endif\x0a#ifdef\x20VELOCITY\x0avarying\x20vec4\x20vCurrentPosition;\x0avarying\x20vec4\x20vPreviousPosition;\x0a#endif\x0a#ifdef\x20NEED_UV\x0avarying\x20vec2\x20vUV;\x0a#endif\x0a#ifdef\x20BUMP\x0auniform\x20vec3\x20vBumpInfos;\x0auniform\x20vec2\x20vTangentSpaceParams;\x0a#endif\x0a#ifdef\x20REFLECTIVITY\x0avarying\x20vec2\x20vReflectivityUV;\x0auniform\x20sampler2D\x20reflectivitySampler;\x0a#endif\x0a#ifdef\x20ALPHATEST\x0auniform\x20sampler2D\x20diffuseSampler;\x0a#endif\x0a#include[RENDER_TARGET_COUNT]\x0a#include\x0a#include\x0avoid\x20main()\x20{\x0a#ifdef\x20ALPHATEST\x0aif\x20(texture2D(diffuseSampler,vUV).a<0.4)\x0adiscard;\x0a#endif\x0avec3\x20normalOutput;\x0a#ifdef\x20BUMP\x0avec3\x20normalW=normalize(vNormalW);\x0a#include\x0anormalOutput=normalize(vec3(vWorldView*vec4(normalW,0.0)));\x0a#else\x0anormalOutput=normalize(vNormalV);\x0a#endif\x0a#ifdef\x20PREPASS\x0a#ifdef\x20PREPASS_DEPTHNORMAL\x0agl_FragData[DEPTHNORMAL_INDEX]=vec4(vViewPos.z/vViewPos.w,normalOutput);\x0a#endif\x0a#else\x0agl_FragData[0]=vec4(vViewPos.z/vViewPos.w,0.0,0.0,1.0);\x0agl_FragData[1]=vec4(normalOutput,1.0);\x0a#endif\x0a#ifdef\x20POSITION\x0agl_FragData[POSITION_INDEX]=vec4(vPositionW,1.0);\x0a#endif\x0a#ifdef\x20VELOCITY\x0avec2\x20a=(vCurrentPosition.xy/vCurrentPosition.w)*0.5+0.5;\x0avec2\x20b=(vPreviousPosition.xy/vPreviousPosition.w)*0.5+0.5;\x0avec2\x20velocity=abs(a-b);\x0avelocity=vec2(pow(velocity.x,1.0/3.0),pow(velocity.y,1.0/3.0))*sign(a-b)*0.5+0.5;\x0agl_FragData[VELOCITY_INDEX]=vec4(velocity,0.0,1.0);\x0a#endif\x0a#ifdef\x20REFLECTIVITY\x0a#ifdef\x20HAS_SPECULAR\x0a\x0avec4\x20reflectivity=texture2D(reflectivitySampler,vReflectivityUV);\x0a#elif\x20HAS_REFLECTIVITY\x0a\x0avec4\x20reflectivity=vec4(texture2D(reflectivitySampler,vReflectivityUV).rgb,1.0);\x0a#else\x0avec4\x20reflectivity=vec4(0.0,0.0,0.0,1.0);\x0a#endif\x0agl_FragData[REFLECTIVITY_INDEX]=reflectivity;\x0a#endif\x0a}';_0x494b01['a']['ShadersStore']['geometryPixelShader']=_0x4219cf;var _0x8133b1='precision\x20highp\x20float;\x0aprecision\x20highp\x20int;\x0a#include\x0a#include\x0a#include[0..maxSimultaneousMorphTargets]\x0a#include\x0aattribute\x20vec3\x20position;\x0aattribute\x20vec3\x20normal;\x0a#ifdef\x20NEED_UV\x0avarying\x20vec2\x20vUV;\x0a#ifdef\x20ALPHATEST\x0auniform\x20mat4\x20diffuseMatrix;\x0a#endif\x0a#ifdef\x20BUMP\x0auniform\x20mat4\x20bumpMatrix;\x0avarying\x20vec2\x20vBumpUV;\x0a#endif\x0a#ifdef\x20REFLECTIVITY\x0auniform\x20mat4\x20reflectivityMatrix;\x0avarying\x20vec2\x20vReflectivityUV;\x0a#endif\x0a#ifdef\x20UV1\x0aattribute\x20vec2\x20uv;\x0a#endif\x0a#ifdef\x20UV2\x0aattribute\x20vec2\x20uv2;\x0a#endif\x0a#endif\x0a\x0auniform\x20mat4\x20viewProjection;\x0auniform\x20mat4\x20view;\x0a#ifdef\x20BUMP\x0avarying\x20mat4\x20vWorldView;\x0a#endif\x0a#ifdef\x20BUMP\x0avarying\x20vec3\x20vNormalW;\x0a#else\x0avarying\x20vec3\x20vNormalV;\x0a#endif\x0avarying\x20vec4\x20vViewPos;\x0a#if\x20defined(POSITION)\x20||\x20defined(BUMP)\x0avarying\x20vec3\x20vPositionW;\x0a#endif\x0a#ifdef\x20VELOCITY\x0auniform\x20mat4\x20previousWorld;\x0auniform\x20mat4\x20previousViewProjection;\x0a#ifdef\x20BONES_VELOCITY_ENABLED\x0a#if\x20NUM_BONE_INFLUENCERS>0\x0auniform\x20mat4\x20mPreviousBones[BonesPerMesh];\x0a#endif\x0a#endif\x0avarying\x20vec4\x20vCurrentPosition;\x0avarying\x20vec4\x20vPreviousPosition;\x0a#endif\x0avoid\x20main(void)\x0a{\x0avec3\x20positionUpdated=position;\x0avec3\x20normalUpdated=normal;\x0a#ifdef\x20UV1\x0avec2\x20uvUpdated=uv;\x0a#endif\x0a#include[0..maxSimultaneousMorphTargets]\x0a#include\x0a#if\x20defined(VELOCITY)\x20&&\x20!defined(BONES_VELOCITY_ENABLED)\x0a\x0avCurrentPosition=viewProjection*finalWorld*vec4(positionUpdated,1.0);\x0avPreviousPosition=previousViewProjection*previousWorld*vec4(positionUpdated,1.0);\x0a#endif\x0a#include\x0avec4\x20pos=vec4(finalWorld*vec4(positionUpdated,1.0));\x0a#ifdef\x20BUMP\x0avWorldView=view*finalWorld;\x0avNormalW=normalUpdated;\x0a#else\x0avNormalV=normalize(vec3((view*finalWorld)*vec4(normalUpdated,0.0)));\x0a#endif\x0avViewPos=view*pos;\x0a#if\x20defined(VELOCITY)\x20&&\x20defined(BONES_VELOCITY_ENABLED)\x0avCurrentPosition=viewProjection*finalWorld*vec4(positionUpdated,1.0);\x0a#if\x20NUM_BONE_INFLUENCERS>0\x0amat4\x20previousInfluence;\x0apreviousInfluence=mPreviousBones[int(matricesIndices[0])]*matricesWeights[0];\x0a#if\x20NUM_BONE_INFLUENCERS>1\x0apreviousInfluence+=mPreviousBones[int(matricesIndices[1])]*matricesWeights[1];\x0a#endif\x0a#if\x20NUM_BONE_INFLUENCERS>2\x0apreviousInfluence+=mPreviousBones[int(matricesIndices[2])]*matricesWeights[2];\x0a#endif\x0a#if\x20NUM_BONE_INFLUENCERS>3\x0apreviousInfluence+=mPreviousBones[int(matricesIndices[3])]*matricesWeights[3];\x0a#endif\x0a#if\x20NUM_BONE_INFLUENCERS>4\x0apreviousInfluence+=mPreviousBones[int(matricesIndicesExtra[0])]*matricesWeightsExtra[0];\x0a#endif\x0a#if\x20NUM_BONE_INFLUENCERS>5\x0apreviousInfluence+=mPreviousBones[int(matricesIndicesExtra[1])]*matricesWeightsExtra[1];\x0a#endif\x0a#if\x20NUM_BONE_INFLUENCERS>6\x0apreviousInfluence+=mPreviousBones[int(matricesIndicesExtra[2])]*matricesWeightsExtra[2];\x0a#endif\x0a#if\x20NUM_BONE_INFLUENCERS>7\x0apreviousInfluence+=mPreviousBones[int(matricesIndicesExtra[3])]*matricesWeightsExtra[3];\x0a#endif\x0avPreviousPosition=previousViewProjection*previousWorld*previousInfluence*vec4(positionUpdated,1.0);\x0a#else\x0avPreviousPosition=previousViewProjection*previousWorld*vec4(positionUpdated,1.0);\x0a#endif\x0a#endif\x0a#if\x20defined(POSITION)\x20||\x20defined(BUMP)\x0avPositionW=pos.xyz/pos.w;\x0a#endif\x0agl_Position=viewProjection*finalWorld*vec4(positionUpdated,1.0);\x0a#ifdef\x20NEED_UV\x0a#ifdef\x20UV1\x0a#ifdef\x20ALPHATEST\x0avUV=vec2(diffuseMatrix*vec4(uvUpdated,1.0,0.0));\x0a#else\x0avUV=uv;\x0a#endif\x0a#ifdef\x20BUMP\x0avBumpUV=vec2(bumpMatrix*vec4(uvUpdated,1.0,0.0));\x0a#endif\x0a#ifdef\x20REFLECTIVITY\x0avReflectivityUV=vec2(reflectivityMatrix*vec4(uvUpdated,1.0,0.0));\x0a#endif\x0a#endif\x0a#ifdef\x20UV2\x0a#ifdef\x20ALPHATEST\x0avUV=vec2(diffuseMatrix*vec4(uv2,1.0,0.0));\x0a#else\x0avUV=uv2;\x0a#endif\x0a#ifdef\x20BUMP\x0avBumpUV=vec2(bumpMatrix*vec4(uv2,1.0,0.0));\x0a#endif\x0a#ifdef\x20REFLECTIVITY\x0avReflectivityUV=vec2(reflectivityMatrix*vec4(uv2,1.0,0.0));\x0a#endif\x0a#endif\x0a#endif\x0a#include\x0a}\x0a';_0x494b01['a']['ShadersStore']['geometryVertexShader']=_0x8133b1;var _0x5e0ba2=(function(){function _0x3c02b8(_0x48543f,_0x25d5ff){void 0x0===_0x25d5ff&&(_0x25d5ff=0x1),this['_previousTransformationMatrices']={},this['_previousBonesTransformationMatrices']={},this['excludedSkinnedMeshesFromVelocity']=[],this['renderTransparentMeshes']=!0x0,this['_resizeObserver']=null,this['_enablePosition']=!0x1,this['_enableVelocity']=!0x1,this['_enableReflectivity']=!0x1,this['_positionIndex']=-0x1,this['_velocityIndex']=-0x1,this['_reflectivityIndex']=-0x1,this['_depthNormalIndex']=-0x1,this['_linkedWithPrePass']=!0x1,this['_scene']=_0x48543f,this['_ratio']=_0x25d5ff,_0x3c02b8['_SceneComponentInitialization'](this['_scene']),this['_createRenderTargets']();}return _0x3c02b8['prototype']['_linkPrePassRenderer']=function(_0x3059d6){this['_linkedWithPrePass']=!0x0,this['_prePassRenderer']=_0x3059d6,this['_multiRenderTarget']&&(this['_multiRenderTarget']['onClearObservable']['clear'](),this['_multiRenderTarget']['onClearObservable']['add'](function(_0x153c35){}));},_0x3c02b8['prototype']['_unlinkPrePassRenderer']=function(){this['_linkedWithPrePass']=!0x1,this['_createRenderTargets']();},_0x3c02b8['prototype']['_resetLayout']=function(){this['_enablePosition']=!0x1,this['_enableReflectivity']=!0x1,this['_enableVelocity']=!0x1,this['_attachments']=[];},_0x3c02b8['prototype']['_forceTextureType']=function(_0x51cb9b,_0x33d23b){_0x51cb9b===_0x3c02b8['POSITION_TEXTURE_TYPE']?(this['_positionIndex']=_0x33d23b,this['_enablePosition']=!0x0):_0x51cb9b===_0x3c02b8['VELOCITY_TEXTURE_TYPE']?(this['_velocityIndex']=_0x33d23b,this['_enableVelocity']=!0x0):_0x51cb9b===_0x3c02b8['REFLECTIVITY_TEXTURE_TYPE']?(this['_reflectivityIndex']=_0x33d23b,this['_enableReflectivity']=!0x0):_0x51cb9b===_0x3c02b8['DEPTHNORMAL_TEXTURE_TYPE']&&(this['_depthNormalIndex']=_0x33d23b);},_0x3c02b8['prototype']['_setAttachments']=function(_0x836331){this['_attachments']=_0x836331;},_0x3c02b8['prototype']['_linkInternalTexture']=function(_0x5b18ab){this['_multiRenderTarget']['_texture']=_0x5b18ab;},Object['defineProperty'](_0x3c02b8['prototype'],'renderList',{'get':function(){return this['_multiRenderTarget']['renderList'];},'set':function(_0x332f39){this['_multiRenderTarget']['renderList']=_0x332f39;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3c02b8['prototype'],'isSupported',{'get':function(){return this['_multiRenderTarget']['isSupported'];},'enumerable':!0x1,'configurable':!0x0}),_0x3c02b8['prototype']['getTextureIndex']=function(_0x40867e){switch(_0x40867e){case _0x3c02b8['POSITION_TEXTURE_TYPE']:return this['_positionIndex'];case _0x3c02b8['VELOCITY_TEXTURE_TYPE']:return this['_velocityIndex'];case _0x3c02b8['REFLECTIVITY_TEXTURE_TYPE']:return this['_reflectivityIndex'];default:return-0x1;}},Object['defineProperty'](_0x3c02b8['prototype'],'enablePosition',{'get':function(){return this['_enablePosition'];},'set':function(_0x51226b){this['_enablePosition']=_0x51226b,this['_linkedWithPrePass']||(this['dispose'](),this['_createRenderTargets']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3c02b8['prototype'],'enableVelocity',{'get':function(){return this['_enableVelocity'];},'set':function(_0xacead){this['_enableVelocity']=_0xacead,_0xacead||(this['_previousTransformationMatrices']={}),this['_linkedWithPrePass']||(this['dispose'](),this['_createRenderTargets']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3c02b8['prototype'],'enableReflectivity',{'get':function(){return this['_enableReflectivity'];},'set':function(_0x3f158d){this['_enableReflectivity']=_0x3f158d,this['_linkedWithPrePass']||(this['dispose'](),this['_createRenderTargets']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3c02b8['prototype'],'scene',{'get':function(){return this['_scene'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3c02b8['prototype'],'ratio',{'get':function(){return this['_ratio'];},'enumerable':!0x1,'configurable':!0x0}),_0x3c02b8['prototype']['isReady']=function(_0x566a79,_0x40ac12){var _0x7d246a=_0x566a79['getMaterial']();if(_0x7d246a&&_0x7d246a['disableDepthWrite'])return!0x1;var _0x408670=[],_0x4aa7e2=[_0x212fbd['b']['PositionKind'],_0x212fbd['b']['NormalKind']],_0x5dead4=_0x566a79['getMesh']();if(_0x7d246a){var _0x16f867=!0x1;_0x7d246a['needAlphaTesting']()&&(_0x408670['push']('#define\x20ALPHATEST'),_0x16f867=!0x0),_0x7d246a['bumpTexture']&&_0x5905ab['a']['BumpTextureEnabled']&&(_0x408670['push']('#define\x20BUMP'),_0x408670['push']('#define\x20BUMPDIRECTUV\x200'),_0x16f867=!0x0),this['_enableReflectivity']&&(_0x7d246a instanceof _0x5905ab['a']&&_0x7d246a['specularTexture']?(_0x408670['push']('#define\x20HAS_SPECULAR'),_0x16f867=!0x0):_0x7d246a instanceof _0x4cd87a&&_0x7d246a['reflectivityTexture']&&(_0x408670['push']('#define\x20HAS_REFLECTIVITY'),_0x16f867=!0x0)),_0x16f867&&(_0x408670['push']('#define\x20NEED_UV'),_0x5dead4['isVerticesDataPresent'](_0x212fbd['b']['UVKind'])&&(_0x4aa7e2['push'](_0x212fbd['b']['UVKind']),_0x408670['push']('#define\x20UV1')),_0x5dead4['isVerticesDataPresent'](_0x212fbd['b']['UV2Kind'])&&(_0x4aa7e2['push'](_0x212fbd['b']['UV2Kind']),_0x408670['push']('#define\x20UV2')));}this['_linkedWithPrePass']&&(_0x408670['push']('#define\x20PREPASS'),-0x1!==this['_depthNormalIndex']&&(_0x408670['push']('#define\x20DEPTHNORMAL_INDEX\x20'+this['_depthNormalIndex']),_0x408670['push']('#define\x20PREPASS_DEPTHNORMAL'))),this['_enablePosition']&&(_0x408670['push']('#define\x20POSITION'),_0x408670['push']('#define\x20POSITION_INDEX\x20'+this['_positionIndex'])),this['_enableVelocity']&&(_0x408670['push']('#define\x20VELOCITY'),_0x408670['push']('#define\x20VELOCITY_INDEX\x20'+this['_velocityIndex']),-0x1===this['excludedSkinnedMeshesFromVelocity']['indexOf'](_0x5dead4)&&_0x408670['push']('#define\x20BONES_VELOCITY_ENABLED')),this['_enableReflectivity']&&(_0x408670['push']('#define\x20REFLECTIVITY'),_0x408670['push']('#define\x20REFLECTIVITY_INDEX\x20'+this['_reflectivityIndex'])),_0x5dead4['useBones']&&_0x5dead4['computeBonesUsingShaders']?(_0x4aa7e2['push'](_0x212fbd['b']['MatricesIndicesKind']),_0x4aa7e2['push'](_0x212fbd['b']['MatricesWeightsKind']),_0x5dead4['numBoneInfluencers']>0x4&&(_0x4aa7e2['push'](_0x212fbd['b']['MatricesIndicesExtraKind']),_0x4aa7e2['push'](_0x212fbd['b']['MatricesWeightsExtraKind'])),_0x408670['push']('#define\x20NUM_BONE_INFLUENCERS\x20'+_0x5dead4['numBoneInfluencers']),_0x408670['push']('#define\x20BonesPerMesh\x20'+(_0x5dead4['skeleton']?_0x5dead4['skeleton']['bones']['length']+0x1:0x0))):_0x408670['push']('#define\x20NUM_BONE_INFLUENCERS\x200');var _0x1d4c3a=_0x5dead4['morphTargetManager'],_0x59c783=0x0;_0x1d4c3a&&_0x1d4c3a['numInfluencers']>0x0&&(_0x59c783=_0x1d4c3a['numInfluencers'],_0x408670['push']('#define\x20MORPHTARGETS'),_0x408670['push']('#define\x20NUM_MORPH_INFLUENCERS\x20'+_0x59c783),_0x464f31['a']['PrepareAttributesForMorphTargetsInfluencers'](_0x4aa7e2,_0x5dead4,_0x59c783)),_0x40ac12&&(_0x408670['push']('#define\x20INSTANCES'),_0x464f31['a']['PushAttributesForInstances'](_0x4aa7e2),_0x566a79['getRenderingMesh']()['hasThinInstances']&&_0x408670['push']('#define\x20THIN_INSTANCES')),this['_linkedWithPrePass']?_0x408670['push']('#define\x20RENDER_TARGET_COUNT\x20'+this['_attachments']['length']):_0x408670['push']('#define\x20RENDER_TARGET_COUNT\x20'+this['_multiRenderTarget']['textures']['length']);var _0x537325=_0x408670['join']('\x0a');return this['_cachedDefines']!==_0x537325&&(this['_cachedDefines']=_0x537325,this['_effect']=this['_scene']['getEngine']()['createEffect']('geometry',_0x4aa7e2,['world','mBones','viewProjection','diffuseMatrix','view','previousWorld','previousViewProjection','mPreviousBones','morphTargetInfluences','bumpMatrix','reflectivityMatrix','vTangentSpaceParams','vBumpInfos'],['diffuseSampler','bumpSampler','reflectivitySampler'],_0x537325,void 0x0,void 0x0,void 0x0,{'buffersCount':this['_multiRenderTarget']['textures']['length']-0x1,'maxSimultaneousMorphTargets':_0x59c783})),this['_effect']['isReady']();},_0x3c02b8['prototype']['getGBuffer']=function(){return this['_multiRenderTarget'];},Object['defineProperty'](_0x3c02b8['prototype'],'samples',{'get':function(){return this['_multiRenderTarget']['samples'];},'set':function(_0x8b76f8){this['_multiRenderTarget']['samples']=_0x8b76f8;},'enumerable':!0x1,'configurable':!0x0}),_0x3c02b8['prototype']['dispose']=function(){this['_resizeObserver']&&(this['_scene']['getEngine']()['onResizeObservable']['remove'](this['_resizeObserver']),this['_resizeObserver']=null),this['getGBuffer']()['dispose']();},_0x3c02b8['prototype']['_assignRenderTargetIndices']=function(){var _0x454248=0x2;return this['_enablePosition']&&(this['_positionIndex']=_0x454248,_0x454248++),this['_enableVelocity']&&(this['_velocityIndex']=_0x454248,_0x454248++),this['_enableReflectivity']&&(this['_reflectivityIndex']=_0x454248,_0x454248++),_0x454248;},_0x3c02b8['prototype']['_createRenderTargets']=function(){var _0x19f6d0=this,_0x1c5f9a=this['_scene']['getEngine'](),_0x2726ad=this['_assignRenderTargetIndices']();if(this['_multiRenderTarget']=new _0x152eb4('gBuffer',{'width':_0x1c5f9a['getRenderWidth']()*this['_ratio'],'height':_0x1c5f9a['getRenderHeight']()*this['_ratio']},_0x2726ad,this['_scene'],{'generateMipMaps':!0x1,'generateDepthTexture':!0x0,'defaultType':_0x2103ba['a']['TEXTURETYPE_FLOAT']}),this['isSupported']){this['_multiRenderTarget']['wrapU']=_0xaf3c80['a']['CLAMP_ADDRESSMODE'],this['_multiRenderTarget']['wrapV']=_0xaf3c80['a']['CLAMP_ADDRESSMODE'],this['_multiRenderTarget']['refreshRate']=0x1,this['_multiRenderTarget']['renderParticles']=!0x1,this['_multiRenderTarget']['renderList']=null,this['_multiRenderTarget']['onClearObservable']['add'](function(_0x110806){_0x110806['clear'](new _0x39310d['b'](0x0,0x0,0x0,0x1),!0x0,!0x0,!0x0);}),this['_resizeObserver']=_0x1c5f9a['onResizeObservable']['add'](function(){_0x19f6d0['_multiRenderTarget']&&_0x19f6d0['_multiRenderTarget']['resize']({'width':_0x1c5f9a['getRenderWidth']()*_0x19f6d0['_ratio'],'height':_0x1c5f9a['getRenderHeight']()*_0x19f6d0['_ratio']});});var _0x239322=function(_0x3281dc){var _0xe8e5bd=_0x3281dc['getRenderingMesh'](),_0xd8073c=_0x3281dc['getEffectiveMesh'](),_0x26a8ad=_0x19f6d0['_scene'],_0x16c8a2=_0x26a8ad['getEngine'](),_0x23ff6e=_0x3281dc['getMaterial']();if(_0x23ff6e){if(_0xd8073c['_internalAbstractMeshDataInfo']['_isActiveIntermediate']=!0x1,_0x19f6d0['_enableVelocity']&&!_0x19f6d0['_previousTransformationMatrices'][_0xd8073c['uniqueId']]&&(_0x19f6d0['_previousTransformationMatrices'][_0xd8073c['uniqueId']]={'world':_0x74d525['a']['Identity'](),'viewProjection':_0x26a8ad['getTransformMatrix']()},_0xe8e5bd['skeleton'])){var _0x408702=_0xe8e5bd['skeleton']['getTransformMatrices'](_0xe8e5bd);_0x19f6d0['_previousBonesTransformationMatrices'][_0xe8e5bd['uniqueId']]=_0x19f6d0['_copyBonesTransformationMatrices'](_0x408702,new Float32Array(_0x408702['length']));}var _0x4f2430=_0xe8e5bd['_getInstancesRenderList'](_0x3281dc['_id'],!!_0x3281dc['getReplacementMesh']());if(!_0x4f2430['mustReturn']){var _0x2f5d5a=_0x16c8a2['getCaps']()['instancedArrays']&&(null!==_0x4f2430['visibleInstances'][_0x3281dc['_id']]||_0xe8e5bd['hasThinInstances']),_0x1251b9=_0xd8073c['getWorldMatrix']();if(_0x19f6d0['isReady'](_0x3281dc,_0x2f5d5a)){if(_0x16c8a2['enableEffect'](_0x19f6d0['_effect']),_0xe8e5bd['_bind'](_0x3281dc,_0x19f6d0['_effect'],_0x23ff6e['fillMode']),_0x19f6d0['_effect']['setMatrix']('viewProjection',_0x26a8ad['getTransformMatrix']()),_0x19f6d0['_effect']['setMatrix']('view',_0x26a8ad['getViewMatrix']()),_0x23ff6e){var _0x228b9a,_0x2638e3=_0xd8073c['_instanceDataStorage'];if(_0x2638e3['isFrozen']||!_0x23ff6e['backFaceCulling']&&null===_0x23ff6e['overrideMaterialSideOrientation'])_0x228b9a=_0x2638e3['sideOrientation'];else{var _0x59dbc4=_0xd8073c['_getWorldMatrixDeterminant']();null==(_0x228b9a=_0x23ff6e['overrideMaterialSideOrientation'])&&(_0x228b9a=_0x23ff6e['sideOrientation']),_0x59dbc4<0x0&&(_0x228b9a=_0x228b9a===_0x33c2e5['a']['ClockWiseSideOrientation']?_0x33c2e5['a']['CounterClockWiseSideOrientation']:_0x33c2e5['a']['ClockWiseSideOrientation']);}if(_0x23ff6e['_preBind'](_0x19f6d0['_effect'],_0x228b9a),_0x23ff6e['needAlphaTesting']()){var _0x522a83=_0x23ff6e['getAlphaTestTexture']();_0x522a83&&(_0x19f6d0['_effect']['setTexture']('diffuseSampler',_0x522a83),_0x19f6d0['_effect']['setMatrix']('diffuseMatrix',_0x522a83['getTextureMatrix']()));}_0x23ff6e['bumpTexture']&&_0x26a8ad['getEngine']()['getCaps']()['standardDerivatives']&&_0x5905ab['a']['BumpTextureEnabled']&&(_0x19f6d0['_effect']['setFloat3']('vBumpInfos',_0x23ff6e['bumpTexture']['coordinatesIndex'],0x1/_0x23ff6e['bumpTexture']['level'],_0x23ff6e['parallaxScaleBias']),_0x19f6d0['_effect']['setMatrix']('bumpMatrix',_0x23ff6e['bumpTexture']['getTextureMatrix']()),_0x19f6d0['_effect']['setTexture']('bumpSampler',_0x23ff6e['bumpTexture']),_0x19f6d0['_effect']['setFloat2']('vTangentSpaceParams',_0x23ff6e['invertNormalMapX']?-0x1:0x1,_0x23ff6e['invertNormalMapY']?-0x1:0x1)),_0x19f6d0['_enableReflectivity']&&(_0x23ff6e instanceof _0x5905ab['a']&&_0x23ff6e['specularTexture']?(_0x19f6d0['_effect']['setMatrix']('reflectivityMatrix',_0x23ff6e['specularTexture']['getTextureMatrix']()),_0x19f6d0['_effect']['setTexture']('reflectivitySampler',_0x23ff6e['specularTexture'])):_0x23ff6e instanceof _0x4cd87a&&_0x23ff6e['reflectivityTexture']&&(_0x19f6d0['_effect']['setMatrix']('reflectivityMatrix',_0x23ff6e['reflectivityTexture']['getTextureMatrix']()),_0x19f6d0['_effect']['setTexture']('reflectivitySampler',_0x23ff6e['reflectivityTexture'])));}_0xe8e5bd['useBones']&&_0xe8e5bd['computeBonesUsingShaders']&&_0xe8e5bd['skeleton']&&(_0x19f6d0['_effect']['setMatrices']('mBones',_0xe8e5bd['skeleton']['getTransformMatrices'](_0xe8e5bd)),_0x19f6d0['_enableVelocity']&&_0x19f6d0['_effect']['setMatrices']('mPreviousBones',_0x19f6d0['_previousBonesTransformationMatrices'][_0xe8e5bd['uniqueId']])),_0x464f31['a']['BindMorphTargetParameters'](_0xe8e5bd,_0x19f6d0['_effect']),_0x19f6d0['_enableVelocity']&&(_0x19f6d0['_effect']['setMatrix']('previousWorld',_0x19f6d0['_previousTransformationMatrices'][_0xd8073c['uniqueId']]['world']),_0x19f6d0['_effect']['setMatrix']('previousViewProjection',_0x19f6d0['_previousTransformationMatrices'][_0xd8073c['uniqueId']]['viewProjection'])),_0xe8e5bd['_processRendering'](_0xd8073c,_0x3281dc,_0x19f6d0['_effect'],_0x23ff6e['fillMode'],_0x4f2430,_0x2f5d5a,function(_0x4554c1,_0x1d30e3){return _0x19f6d0['_effect']['setMatrix']('world',_0x1d30e3);});}_0x19f6d0['_enableVelocity']&&(_0x19f6d0['_previousTransformationMatrices'][_0xd8073c['uniqueId']]['world']=_0x1251b9['clone'](),_0x19f6d0['_previousTransformationMatrices'][_0xd8073c['uniqueId']]['viewProjection']=_0x19f6d0['_scene']['getTransformMatrix']()['clone'](),_0xe8e5bd['skeleton']&&_0x19f6d0['_copyBonesTransformationMatrices'](_0xe8e5bd['skeleton']['getTransformMatrices'](_0xe8e5bd),_0x19f6d0['_previousBonesTransformationMatrices'][_0xd8073c['uniqueId']]));}}};this['_multiRenderTarget']['customRenderFunction']=function(_0x257dd4,_0x5b998e,_0x7198e5,_0x3fe6c6){var _0x3ae036;if(_0x19f6d0['_linkedWithPrePass']){if(!_0x19f6d0['_prePassRenderer']['enabled'])return;_0x19f6d0['_scene']['getEngine']()['bindAttachments'](_0x19f6d0['_attachments']);}if(_0x3fe6c6['length']){for(_0x1c5f9a['setColorWrite'](!0x1),_0x3ae036=0x0;_0x3ae036<_0x3fe6c6['length'];_0x3ae036++)_0x239322(_0x3fe6c6['data'][_0x3ae036]);_0x1c5f9a['setColorWrite'](!0x0);}for(_0x3ae036=0x0;_0x3ae036<_0x257dd4['length'];_0x3ae036++)_0x239322(_0x257dd4['data'][_0x3ae036]);for(_0x3ae036=0x0;_0x3ae036<_0x5b998e['length'];_0x3ae036++)_0x239322(_0x5b998e['data'][_0x3ae036]);if(_0x19f6d0['renderTransparentMeshes']){for(_0x3ae036=0x0;_0x3ae036<_0x7198e5['length'];_0x3ae036++)_0x239322(_0x7198e5['data'][_0x3ae036]);}};}},_0x3c02b8['prototype']['_copyBonesTransformationMatrices']=function(_0x414263,_0xe0b89a){for(var _0x527065=0x0;_0x527065<_0x414263['length'];_0x527065++)_0xe0b89a[_0x527065]=_0x414263[_0x527065];return _0xe0b89a;},_0x3c02b8['DEPTHNORMAL_TEXTURE_TYPE']=0x0,_0x3c02b8['POSITION_TEXTURE_TYPE']=0x1,_0x3c02b8['VELOCITY_TEXTURE_TYPE']=0x2,_0x3c02b8['REFLECTIVITY_TEXTURE_TYPE']=0x3,_0x3c02b8['_SceneComponentInitialization']=function(_0x1902c6){throw _0x2de344['a']['WarnImport']('GeometryBufferRendererSceneComponent');},_0x3c02b8;}()),_0x3f6cb1=function(){this['enabled']=!0x1,this['name']='motionBlur',this['texturesRequired']=[_0x2103ba['a']['PREPASS_VELOCITY_TEXTURE_TYPE']];};Object['defineProperty'](_0x59370b['a']['prototype'],'geometryBufferRenderer',{'get':function(){this['_geometryBufferRenderer'];},'set':function(_0x2c6578){_0x2c6578&&_0x2c6578['isSupported']&&(this['_geometryBufferRenderer']=_0x2c6578);},'enumerable':!0x0,'configurable':!0x0}),_0x59370b['a']['prototype']['enableGeometryBufferRenderer']=function(_0x1e4ed2){return void 0x0===_0x1e4ed2&&(_0x1e4ed2=0x1),this['_geometryBufferRenderer']||(this['_geometryBufferRenderer']=new _0x5e0ba2(this,_0x1e4ed2),this['_geometryBufferRenderer']['isSupported']||(this['_geometryBufferRenderer']=null)),this['_geometryBufferRenderer'];},_0x59370b['a']['prototype']['disableGeometryBufferRenderer']=function(){this['_geometryBufferRenderer']&&(this['_geometryBufferRenderer']['dispose'](),this['_geometryBufferRenderer']=null);};var _0x1e2f6b=(function(){function _0x393333(_0xa60c38){this['name']=_0x384de3['a']['NAME_GEOMETRYBUFFERRENDERER'],this['scene']=_0xa60c38;}return _0x393333['prototype']['register']=function(){this['scene']['_gatherRenderTargetsStage']['registerStep'](_0x384de3['a']['STEP_GATHERRENDERTARGETS_GEOMETRYBUFFERRENDERER'],this,this['_gatherRenderTargets']);},_0x393333['prototype']['rebuild']=function(){},_0x393333['prototype']['dispose']=function(){},_0x393333['prototype']['_gatherRenderTargets']=function(_0x419b1b){this['scene']['_geometryBufferRenderer']&&_0x419b1b['push'](this['scene']['_geometryBufferRenderer']['getGBuffer']());},_0x393333;}());_0x5e0ba2['_SceneComponentInitialization']=function(_0x35a450){var _0x383d3f=_0x35a450['_getComponent'](_0x384de3['a']['NAME_GEOMETRYBUFFERRENDERER']);_0x383d3f||(_0x383d3f=new _0x1e2f6b(_0x35a450),_0x35a450['_addComponent'](_0x383d3f));};var _0x1fd788='\x0avarying\x20vec2\x20vUV;\x0auniform\x20sampler2D\x20textureSampler;\x0auniform\x20float\x20motionStrength;\x0auniform\x20float\x20motionScale;\x0auniform\x20vec2\x20screenSize;\x0a#ifdef\x20OBJECT_BASED\x0auniform\x20sampler2D\x20velocitySampler;\x0a#else\x0auniform\x20sampler2D\x20depthSampler;\x0auniform\x20mat4\x20inverseViewProjection;\x0auniform\x20mat4\x20prevViewProjection;\x0a#endif\x0avoid\x20main(void)\x0a{\x0a#ifdef\x20GEOMETRY_SUPPORTED\x0a#ifdef\x20OBJECT_BASED\x0avec2\x20texelSize=1.0/screenSize;\x0avec2\x20velocityColor=texture2D(velocitySampler,vUV).rg*2.0-1.0;\x0avec2\x20velocity=vec2(pow(velocityColor.r,3.0),pow(velocityColor.g,3.0));\x0avelocity*=motionScale*motionStrength;\x0afloat\x20speed=length(velocity/texelSize);\x0aint\x20samplesCount=int(clamp(speed,1.0,SAMPLES));\x0avelocity=normalize(velocity)*texelSize;\x0afloat\x20hlim=float(-samplesCount)*0.5+0.5;\x0avec4\x20result=texture2D(textureSampler,vUV);\x0afor\x20(int\x20i=1;\x20i=samplesCount)\x0abreak;\x0avec2\x20offset=vUV+velocity*(hlim+float(i));\x0aresult+=texture2D(textureSampler,offset);\x0a}\x0agl_FragColor=result/float(samplesCount);\x0agl_FragColor.a=1.0;\x0a#else\x0avec2\x20texelSize=1.0/screenSize;\x0afloat\x20depth=texture2D(depthSampler,vUV).r;\x0avec4\x20cpos=vec4(vUV*2.0-1.0,depth,1.0);\x0acpos=cpos*inverseViewProjection;\x0avec4\x20ppos=cpos*prevViewProjection;\x0appos.xyz/=ppos.w;\x0appos.xy=ppos.xy*0.5+0.5;\x0avec2\x20velocity=(ppos.xy-vUV)*motionScale*motionStrength;\x0afloat\x20speed=length(velocity/texelSize);\x0aint\x20nSamples=int(clamp(speed,1.0,SAMPLES));\x0avec4\x20result=texture2D(textureSampler,vUV);\x0afor\x20(int\x20i=1;\x20i=nSamples)\x0abreak;\x0avec2\x20offset1=vUV+velocity*(float(i)/float(nSamples-1)-0.5);\x0aresult+=texture2D(textureSampler,offset1);\x0a}\x0agl_FragColor=result/float(nSamples);\x0a#endif\x0a#else\x0agl_FragColor=texture2D(textureSampler,vUV);\x0a#endif\x0a}\x0a';_0x494b01['a']['ShadersStore']['motionBlurPixelShader']=_0x1fd788;var _0x8933c4=function(_0x56f194){function _0x502f94(_0x430fab,_0xa5dc5e,_0x28c996,_0x1246da,_0x3c7375,_0x4aadfa,_0x4d1f28,_0x17a542,_0x594507,_0x27d368){void 0x0===_0x17a542&&(_0x17a542=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),void 0x0===_0x594507&&(_0x594507=!0x1),void 0x0===_0x27d368&&(_0x27d368=!0x0);var _0x2acc25=_0x56f194['call'](this,_0x430fab,'motionBlur',['motionStrength','motionScale','screenSize','inverseViewProjection','prevViewProjection'],['velocitySampler'],_0x28c996,_0x1246da,_0x3c7375,_0x4aadfa,_0x4d1f28,'#define\x20GEOMETRY_SUPPORTED\x0a#define\x20SAMPLES\x2064.0\x0a#define\x20OBJECT_BASED',_0x17a542,void 0x0,null,_0x594507)||this;return _0x2acc25['motionStrength']=0x1,_0x2acc25['_motionBlurSamples']=0x20,_0x2acc25['_isObjectBased']=!0x0,_0x2acc25['_forceGeometryBuffer']=!0x1,_0x2acc25['_geometryBufferRenderer']=null,_0x2acc25['_prePassRenderer']=null,_0x2acc25['_invViewProjection']=null,_0x2acc25['_previousViewProjection']=null,_0x2acc25['_forceGeometryBuffer']=_0x27d368,_0x2acc25['_forceGeometryBuffer']?(_0x2acc25['_geometryBufferRenderer']=_0xa5dc5e['enableGeometryBufferRenderer'](),_0x2acc25['_geometryBufferRenderer']&&(_0x2acc25['_geometryBufferRenderer']['enableVelocity']=!0x0)):(_0x2acc25['_prePassRenderer']=_0xa5dc5e['enablePrePassRenderer'](),_0x2acc25['_prePassRenderer']&&(_0x2acc25['_prePassRenderer']['markAsDirty'](),_0x2acc25['_prePassEffectConfiguration']=new _0x3f6cb1())),_0x2acc25['_applyMode'](),_0x2acc25;}return Object(_0x18e13d['d'])(_0x502f94,_0x56f194),Object['defineProperty'](_0x502f94['prototype'],'motionBlurSamples',{'get':function(){return this['_motionBlurSamples'];},'set':function(_0x535334){this['_motionBlurSamples']=_0x535334,this['_updateEffect']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x502f94['prototype'],'isObjectBased',{'get':function(){return this['_isObjectBased'];},'set':function(_0x59fde5){this['_isObjectBased']!==_0x59fde5&&(this['_isObjectBased']=_0x59fde5,this['_applyMode']());},'enumerable':!0x1,'configurable':!0x0}),_0x502f94['prototype']['getClassName']=function(){return'MotionBlurPostProcess';},_0x502f94['prototype']['excludeSkinnedMesh']=function(_0x1779d8){if(_0x1779d8['skeleton']){var _0x7d05bc=void 0x0;if(this['_geometryBufferRenderer'])_0x7d05bc=this['_geometryBufferRenderer']['excludedSkinnedMeshesFromVelocity'];else{if(!this['_prePassRenderer'])return;_0x7d05bc=this['_prePassRenderer']['excludedSkinnedMesh'];}_0x7d05bc['push'](_0x1779d8);}},_0x502f94['prototype']['removeExcludedSkinnedMesh']=function(_0x2026cc){if(_0x2026cc['skeleton']){var _0x4892d9=void 0x0;if(this['_geometryBufferRenderer'])_0x4892d9=this['_geometryBufferRenderer']['excludedSkinnedMeshesFromVelocity'];else{if(!this['_prePassRenderer'])return;_0x4892d9=this['_prePassRenderer']['excludedSkinnedMesh'];}var _0x48791d=_0x4892d9['indexOf'](_0x2026cc);-0x1!==_0x48791d&&_0x4892d9['splice'](_0x48791d,0x1);}},_0x502f94['prototype']['dispose']=function(_0x1345d3){this['_geometryBufferRenderer']&&(this['_geometryBufferRenderer']['_previousTransformationMatrices']={},this['_geometryBufferRenderer']['_previousBonesTransformationMatrices']={},this['_geometryBufferRenderer']['excludedSkinnedMeshesFromVelocity']=[]),_0x56f194['prototype']['dispose']['call'](this,_0x1345d3);},_0x502f94['prototype']['_applyMode']=function(){var _0x1680ee=this;if(!this['_geometryBufferRenderer']&&!this['_prePassRenderer'])return _0x75193d['a']['Warn']('Multiple\x20Render\x20Target\x20support\x20needed\x20to\x20compute\x20object\x20based\x20motion\x20blur'),this['updateEffect']();this['_updateEffect'](),this['_invViewProjection']=null,this['_previousViewProjection']=null,this['isObjectBased']?(this['_prePassRenderer']&&this['_prePassEffectConfiguration']&&(this['_prePassEffectConfiguration']['texturesRequired'][0x0]=_0x2103ba['a']['PREPASS_VELOCITY_TEXTURE_TYPE']),this['onApply']=function(_0x587657){return _0x1680ee['_onApplyObjectBased'](_0x587657);}):(this['_invViewProjection']=_0x74d525['a']['Identity'](),this['_previousViewProjection']=_0x74d525['a']['Identity'](),this['_prePassRenderer']&&this['_prePassEffectConfiguration']&&(this['_prePassEffectConfiguration']['texturesRequired'][0x0]=_0x2103ba['a']['PREPASS_DEPTHNORMAL_TEXTURE_TYPE']),this['onApply']=function(_0x3413c4){return _0x1680ee['_onApplyScreenBased'](_0x3413c4);});},_0x502f94['prototype']['_onApplyObjectBased']=function(_0x49650d){if(_0x49650d['setVector2']('screenSize',new _0x74d525['d'](this['width'],this['height'])),_0x49650d['setFloat']('motionScale',this['_scene']['getAnimationRatio']()),_0x49650d['setFloat']('motionStrength',this['motionStrength']),this['_geometryBufferRenderer']){var _0x40583c=this['_geometryBufferRenderer']['getTextureIndex'](_0x5e0ba2['VELOCITY_TEXTURE_TYPE']);_0x49650d['setTexture']('velocitySampler',this['_geometryBufferRenderer']['getGBuffer']()['textures'][_0x40583c]);}else this['_prePassRenderer']&&(_0x40583c=this['_prePassRenderer']['getIndex'](_0x2103ba['a']['PREPASS_VELOCITY_TEXTURE_TYPE']),_0x49650d['setTexture']('velocitySampler',this['_prePassRenderer']['prePassRT']['textures'][_0x40583c]));},_0x502f94['prototype']['_onApplyScreenBased']=function(_0x419f74){var _0xea17a9=this['_scene']['getProjectionMatrix']()['multiply'](this['_scene']['getViewMatrix']());if(_0xea17a9['invertToRef'](this['_invViewProjection']),_0x419f74['setMatrix']('inverseViewProjection',this['_invViewProjection']),_0x419f74['setMatrix']('prevViewProjection',this['_previousViewProjection']),this['_previousViewProjection']=_0xea17a9,_0x419f74['setVector2']('screenSize',new _0x74d525['d'](this['width'],this['height'])),_0x419f74['setFloat']('motionScale',this['_scene']['getAnimationRatio']()),_0x419f74['setFloat']('motionStrength',this['motionStrength']),this['_geometryBufferRenderer']){var _0x44a52e=this['_geometryBufferRenderer']['getTextureIndex'](_0x5e0ba2['DEPTHNORMAL_TEXTURE_TYPE']);_0x419f74['setTexture']('depthSampler',this['_geometryBufferRenderer']['getGBuffer']()['textures'][_0x44a52e]);}else this['_prePassRenderer']&&(_0x44a52e=this['_prePassRenderer']['getIndex'](_0x2103ba['a']['PREPASS_DEPTHNORMAL_TEXTURE_TYPE']),_0x419f74['setTexture']('depthSampler',this['_prePassRenderer']['prePassRT']['textures'][_0x44a52e]));},_0x502f94['prototype']['_updateEffect']=function(){if(this['_geometryBufferRenderer']||this['_prePassRenderer']){var _0x49b995=['#define\x20GEOMETRY_SUPPORTED','#define\x20SAMPLES\x20'+this['_motionBlurSamples']['toFixed'](0x1),this['_isObjectBased']?'#define\x20OBJECT_BASED':'#define\x20SCREEN_BASED'];this['updateEffect'](_0x49b995['join']('\x0a'));}},_0x502f94['_Parse']=function(_0x318d24,_0x3a1721,_0x2d50cc,_0x38b10e){return _0x495d06['a']['Parse'](function(){return new _0x502f94(_0x318d24['name'],_0x2d50cc,_0x318d24['options'],_0x3a1721,_0x318d24['renderTargetSamplingMode'],_0x2d50cc['getEngine'](),_0x318d24['reusable'],_0x318d24['textureType'],!0x1);},_0x318d24,_0x2d50cc,_0x38b10e);},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x502f94['prototype'],'motionStrength',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x502f94['prototype'],'motionBlurSamples',null),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x502f94['prototype'],'isObjectBased',null),_0x502f94;}(_0x5cae84);_0x3cd573['a']['RegisteredTypes']['BABYLON.MotionBlurPostProcess']=_0x8933c4;var _0x10739d='\x0avarying\x20vec2\x20vUV;\x0auniform\x20sampler2D\x20textureSampler;\x0auniform\x20sampler2D\x20refractionSampler;\x0a\x0auniform\x20vec3\x20baseColor;\x0auniform\x20float\x20depth;\x0auniform\x20float\x20colorLevel;\x0avoid\x20main()\x20{\x0afloat\x20ref=1.0-texture2D(refractionSampler,vUV).r;\x0avec2\x20uv=vUV-vec2(0.5);\x0avec2\x20offset=uv*depth*ref;\x0avec3\x20sourceColor=texture2D(textureSampler,vUV-offset).rgb;\x0agl_FragColor=vec4(sourceColor+sourceColor*ref*colorLevel,1.0);\x0a}';_0x494b01['a']['ShadersStore']['refractionPixelShader']=_0x10739d;var _0x3a9838=function(_0x34cca9){function _0x2f9707(_0x88cde2,_0x55d664,_0x2a20c0,_0x2ea85a,_0x536703,_0x1522c4,_0x5ba3d1,_0x41b074,_0x19707a,_0x1dfab4){var _0x235912=_0x34cca9['call'](this,_0x88cde2,'refraction',['baseColor','depth','colorLevel'],['refractionSampler'],_0x1522c4,_0x5ba3d1,_0x41b074,_0x19707a,_0x1dfab4)||this;return _0x235912['_ownRefractionTexture']=!0x0,_0x235912['color']=_0x2a20c0,_0x235912['depth']=_0x2ea85a,_0x235912['colorLevel']=_0x536703,_0x235912['refractionTextureUrl']=_0x55d664,_0x235912['onActivateObservable']['add'](function(_0x315ee4){_0x235912['_refTexture']=_0x235912['_refTexture']||new _0xaf3c80['a'](_0x55d664,_0x315ee4['getScene']());}),_0x235912['onApplyObservable']['add'](function(_0x287eaa){_0x287eaa['setColor3']('baseColor',_0x235912['color']),_0x287eaa['setFloat']('depth',_0x235912['depth']),_0x287eaa['setFloat']('colorLevel',_0x235912['colorLevel']),_0x287eaa['setTexture']('refractionSampler',_0x235912['_refTexture']);}),_0x235912;}return Object(_0x18e13d['d'])(_0x2f9707,_0x34cca9),Object['defineProperty'](_0x2f9707['prototype'],'refractionTexture',{'get':function(){return this['_refTexture'];},'set':function(_0x1a6876){this['_refTexture']&&this['_ownRefractionTexture']&&this['_refTexture']['dispose'](),this['_refTexture']=_0x1a6876,this['_ownRefractionTexture']=!0x1;},'enumerable':!0x1,'configurable':!0x0}),_0x2f9707['prototype']['getClassName']=function(){return'RefractionPostProcess';},_0x2f9707['prototype']['dispose']=function(_0x3c4d60){this['_refTexture']&&this['_ownRefractionTexture']&&(this['_refTexture']['dispose'](),this['_refTexture']=null),_0x34cca9['prototype']['dispose']['call'](this,_0x3c4d60);},_0x2f9707['_Parse']=function(_0x2cec87,_0x52c60d,_0x3bd2d1,_0x3353ee){return _0x495d06['a']['Parse'](function(){return new _0x2f9707(_0x2cec87['name'],_0x2cec87['refractionTextureUrl'],_0x2cec87['color'],_0x2cec87['depth'],_0x2cec87['colorLevel'],_0x2cec87['options'],_0x52c60d,_0x2cec87['renderTargetSamplingMode'],_0x3bd2d1['getEngine'](),_0x2cec87['reusable']);},_0x2cec87,_0x3bd2d1,_0x3353ee);},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x2f9707['prototype'],'color',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x2f9707['prototype'],'depth',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x2f9707['prototype'],'colorLevel',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x2f9707['prototype'],'refractionTextureUrl',void 0x0),_0x2f9707;}(_0x5cae84);_0x3cd573['a']['RegisteredTypes']['BABYLON.RefractionPostProcess']=_0x3a9838;var _0x453ff5='\x0avarying\x20vec2\x20vUV;\x0auniform\x20sampler2D\x20textureSampler;\x0auniform\x20vec2\x20screenSize;\x0auniform\x20vec2\x20sharpnessAmounts;\x0avoid\x20main(void)\x0a{\x0avec2\x20onePixel=vec2(1.0,1.0)/screenSize;\x0avec4\x20color=texture2D(textureSampler,vUV);\x0avec4\x20edgeDetection=texture2D(textureSampler,vUV+onePixel*vec2(0,-1))\x20+\x0atexture2D(textureSampler,vUV+onePixel*vec2(-1,0))\x20+\x0atexture2D(textureSampler,vUV+onePixel*vec2(1,0))\x20+\x0atexture2D(textureSampler,vUV+onePixel*vec2(0,1))\x20-\x0acolor*4.0;\x0agl_FragColor=max(vec4(color.rgb*sharpnessAmounts.y,color.a)-(sharpnessAmounts.x*vec4(edgeDetection.rgb,0)),0.);\x0a}';_0x494b01['a']['ShadersStore']['sharpenPixelShader']=_0x453ff5;var _0x59740a=function(_0x17da5e){function _0x3e70aa(_0x382438,_0x5e377c,_0x27ab32,_0x2abf82,_0x273b9c,_0x5c3a79,_0x1ac234,_0x2bce8c){void 0x0===_0x1ac234&&(_0x1ac234=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),void 0x0===_0x2bce8c&&(_0x2bce8c=!0x1);var _0x48422f=_0x17da5e['call'](this,_0x382438,'sharpen',['sharpnessAmounts','screenSize'],null,_0x5e377c,_0x27ab32,_0x2abf82,_0x273b9c,_0x5c3a79,null,_0x1ac234,void 0x0,null,_0x2bce8c)||this;return _0x48422f['colorAmount']=0x1,_0x48422f['edgeAmount']=0.3,_0x48422f['onApply']=function(_0x10863c){_0x10863c['setFloat2']('screenSize',_0x48422f['width'],_0x48422f['height']),_0x10863c['setFloat2']('sharpnessAmounts',_0x48422f['edgeAmount'],_0x48422f['colorAmount']);},_0x48422f;}return Object(_0x18e13d['d'])(_0x3e70aa,_0x17da5e),_0x3e70aa['prototype']['getClassName']=function(){return'SharpenPostProcess';},_0x3e70aa['_Parse']=function(_0x31fde2,_0x17e253,_0xca0650,_0x42b4bf){return _0x495d06['a']['Parse'](function(){return new _0x3e70aa(_0x31fde2['name'],_0x31fde2['options'],_0x17e253,_0x31fde2['renderTargetSamplingMode'],_0xca0650['getEngine'](),_0x31fde2['textureType'],_0x31fde2['reusable']);},_0x31fde2,_0xca0650,_0x42b4bf);},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3e70aa['prototype'],'colorAmount',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3e70aa['prototype'],'edgeAmount',void 0x0),_0x3e70aa;}(_0x5cae84);_0x3cd573['a']['RegisteredTypes']['BABYLON.SharpenPostProcess']=_0x59740a;var _0x15e31a=(function(){function _0x4bfbc7(_0x310824,_0x30ac9b){this['engine']=_0x310824,this['_name']=_0x30ac9b,this['_renderEffects']={},this['_renderEffectsForIsolatedPass']=new Array(),this['_cameras']=[];}return Object['defineProperty'](_0x4bfbc7['prototype'],'name',{'get':function(){return this['_name'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4bfbc7['prototype'],'cameras',{'get':function(){return this['_cameras'];},'enumerable':!0x1,'configurable':!0x0}),_0x4bfbc7['prototype']['getClassName']=function(){return'PostProcessRenderPipeline';},Object['defineProperty'](_0x4bfbc7['prototype'],'isSupported',{'get':function(){for(var _0x4f7213 in this['_renderEffects'])if(this['_renderEffects']['hasOwnProperty'](_0x4f7213)&&!this['_renderEffects'][_0x4f7213]['isSupported'])return!0x1;return!0x0;},'enumerable':!0x1,'configurable':!0x0}),_0x4bfbc7['prototype']['addEffect']=function(_0x1601c0){this['_renderEffects'][_0x1601c0['_name']]=_0x1601c0;},_0x4bfbc7['prototype']['_rebuild']=function(){},_0x4bfbc7['prototype']['_enableEffect']=function(_0x552525,_0x9ded53){var _0x1ecae2=this['_renderEffects'][_0x552525];_0x1ecae2&&_0x1ecae2['_enable'](_0x5d754c['b']['MakeArray'](_0x9ded53||this['_cameras']));},_0x4bfbc7['prototype']['_disableEffect']=function(_0x631444,_0xbcdaa4){var _0x4426f3=this['_renderEffects'][_0x631444];_0x4426f3&&_0x4426f3['_disable'](_0x5d754c['b']['MakeArray'](_0xbcdaa4||this['_cameras']));},_0x4bfbc7['prototype']['_attachCameras']=function(_0x30dd02,_0x3c643d){var _0x13672f=_0x5d754c['b']['MakeArray'](_0x30dd02||this['_cameras']);if(_0x13672f){var _0x1333a2,_0xe8a78e=[];for(_0x1333a2=0x0;_0x1333a2<_0x13672f['length'];_0x1333a2++){var _0x2550d5=_0x13672f[_0x1333a2];if(_0x2550d5){var _0x1aba8f=_0x2550d5['name'];-0x1===this['_cameras']['indexOf'](_0x2550d5)?this['_cameras'][_0x1aba8f]=_0x2550d5:_0x3c643d&&_0xe8a78e['push'](_0x1333a2);}}for(_0x1333a2=0x0;_0x1333a2<_0xe8a78e['length'];_0x1333a2++)_0x30dd02['splice'](_0xe8a78e[_0x1333a2],0x1);for(var _0x3ff811 in this['_renderEffects'])this['_renderEffects']['hasOwnProperty'](_0x3ff811)&&this['_renderEffects'][_0x3ff811]['_attachCameras'](_0x13672f);}},_0x4bfbc7['prototype']['_detachCameras']=function(_0x20db79){var _0x7c2449=_0x5d754c['b']['MakeArray'](_0x20db79||this['_cameras']);if(_0x7c2449){for(var _0x39f3bc in this['_renderEffects'])this['_renderEffects']['hasOwnProperty'](_0x39f3bc)&&this['_renderEffects'][_0x39f3bc]['_detachCameras'](_0x7c2449);for(var _0x54826c=0x0;_0x54826c<_0x7c2449['length'];_0x54826c++)this['_cameras']['splice'](this['_cameras']['indexOf'](_0x7c2449[_0x54826c]),0x1);}},_0x4bfbc7['prototype']['_update']=function(){for(var _0x3d2721 in this['_renderEffects'])this['_renderEffects']['hasOwnProperty'](_0x3d2721)&&this['_renderEffects'][_0x3d2721]['_update']();for(var _0x24f08f=0x0;_0x24f08f0x0){var _0xa46e9c=this['_renderEffects'][_0x440f11[0x0]]['getPostProcesses']();_0xa46e9c&&(_0xa46e9c[0x0]['samples']=_0x10407b);}return!0x0;},_0x4bfbc7['prototype']['setPrePassRenderer']=function(_0x391358){return!0x1;},_0x4bfbc7['prototype']['dispose']=function(){},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x4bfbc7['prototype'],'_name',void 0x0),_0x4bfbc7;}()),_0x13a007=(function(){function _0x58366a(){this['_renderPipelines']={};}return Object['defineProperty'](_0x58366a['prototype'],'supportedPipelines',{'get':function(){var _0x3e5f44=[];for(var _0x397413 in this['_renderPipelines'])if(this['_renderPipelines']['hasOwnProperty'](_0x397413)){var _0x3f1138=this['_renderPipelines'][_0x397413];_0x3f1138['isSupported']&&_0x3e5f44['push'](_0x3f1138);}return _0x3e5f44;},'enumerable':!0x1,'configurable':!0x0}),_0x58366a['prototype']['addPipeline']=function(_0x165796){this['_renderPipelines'][_0x165796['_name']]=_0x165796;},_0x58366a['prototype']['attachCamerasToRenderPipeline']=function(_0x4b10a1,_0x3435c9,_0x2833f5){void 0x0===_0x2833f5&&(_0x2833f5=!0x1);var _0x4cdb2d=this['_renderPipelines'][_0x4b10a1];_0x4cdb2d&&_0x4cdb2d['_attachCameras'](_0x3435c9,_0x2833f5);},_0x58366a['prototype']['detachCamerasFromRenderPipeline']=function(_0x26fda9,_0x5191ce){var _0x4ada61=this['_renderPipelines'][_0x26fda9];_0x4ada61&&_0x4ada61['_detachCameras'](_0x5191ce);},_0x58366a['prototype']['enableEffectInPipeline']=function(_0x540e34,_0x33376d,_0x272117){var _0x30433b=this['_renderPipelines'][_0x540e34];_0x30433b&&_0x30433b['_enableEffect'](_0x33376d,_0x272117);},_0x58366a['prototype']['disableEffectInPipeline']=function(_0x3cbeb8,_0x16d751,_0x2ad263){var _0x4025dd=this['_renderPipelines'][_0x3cbeb8];_0x4025dd&&_0x4025dd['_disableEffect'](_0x16d751,_0x2ad263);},_0x58366a['prototype']['update']=function(){for(var _0x473d11 in this['_renderPipelines'])if(this['_renderPipelines']['hasOwnProperty'](_0x473d11)){var _0x501cae=this['_renderPipelines'][_0x473d11];_0x501cae['isSupported']?_0x501cae['_update']():(_0x501cae['dispose'](),delete this['_renderPipelines'][_0x473d11]);}},_0x58366a['prototype']['_rebuild']=function(){for(var _0x181d9f in this['_renderPipelines']){if(this['_renderPipelines']['hasOwnProperty'](_0x181d9f))this['_renderPipelines'][_0x181d9f]['_rebuild']();}},_0x58366a['prototype']['dispose']=function(){for(var _0x3f3b53 in this['_renderPipelines']){if(this['_renderPipelines']['hasOwnProperty'](_0x3f3b53))this['_renderPipelines'][_0x3f3b53]['dispose']();}},_0x58366a;}());Object['defineProperty'](_0x59370b['a']['prototype'],'postProcessRenderPipelineManager',{'get':function(){if(!this['_postProcessRenderPipelineManager']){var _0x518566=this['_getComponent'](_0x384de3['a']['NAME_POSTPROCESSRENDERPIPELINEMANAGER']);_0x518566||(_0x518566=new _0x5a88cb(this),this['_addComponent'](_0x518566)),this['_postProcessRenderPipelineManager']=new _0x13a007();}return this['_postProcessRenderPipelineManager'];},'enumerable':!0x0,'configurable':!0x0});var _0x5a88cb=(function(){function _0x2d0d48(_0x190295){this['name']=_0x384de3['a']['NAME_POSTPROCESSRENDERPIPELINEMANAGER'],this['scene']=_0x190295;}return _0x2d0d48['prototype']['register']=function(){this['scene']['_gatherRenderTargetsStage']['registerStep'](_0x384de3['a']['STEP_GATHERRENDERTARGETS_POSTPROCESSRENDERPIPELINEMANAGER'],this,this['_gatherRenderTargets']);},_0x2d0d48['prototype']['rebuild']=function(){this['scene']['_postProcessRenderPipelineManager']&&this['scene']['_postProcessRenderPipelineManager']['_rebuild']();},_0x2d0d48['prototype']['dispose']=function(){this['scene']['_postProcessRenderPipelineManager']&&this['scene']['_postProcessRenderPipelineManager']['dispose']();},_0x2d0d48['prototype']['_gatherRenderTargets']=function(){this['scene']['_postProcessRenderPipelineManager']&&this['scene']['_postProcessRenderPipelineManager']['update']();},_0x2d0d48;}()),_0x1e339d=function(_0x38d324){function _0x12f627(_0x166e70,_0x2fc272,_0x9156d6,_0x469ef1,_0x5d6b02){void 0x0===_0x166e70&&(_0x166e70=''),void 0x0===_0x2fc272&&(_0x2fc272=!0x0),void 0x0===_0x9156d6&&(_0x9156d6=_0x44b9ce['a']['LastCreatedScene']),void 0x0===_0x5d6b02&&(_0x5d6b02=!0x0);var _0x3061f7=_0x38d324['call'](this,_0x9156d6['getEngine'](),_0x166e70)||this;_0x3061f7['_camerasToBeAttached']=[],_0x3061f7['SharpenPostProcessId']='SharpenPostProcessEffect',_0x3061f7['ImageProcessingPostProcessId']='ImageProcessingPostProcessEffect',_0x3061f7['FxaaPostProcessId']='FxaaPostProcessEffect',_0x3061f7['ChromaticAberrationPostProcessId']='ChromaticAberrationPostProcessEffect',_0x3061f7['GrainPostProcessId']='GrainPostProcessEffect',_0x3061f7['_glowLayer']=null,_0x3061f7['animations']=[],_0x3061f7['_imageProcessingConfigurationObserver']=null,_0x3061f7['_sharpenEnabled']=!0x1,_0x3061f7['_bloomEnabled']=!0x1,_0x3061f7['_depthOfFieldEnabled']=!0x1,_0x3061f7['_depthOfFieldBlurLevel']=_0x30d121['Low'],_0x3061f7['_fxaaEnabled']=!0x1,_0x3061f7['_imageProcessingEnabled']=!0x0,_0x3061f7['_bloomScale']=0.5,_0x3061f7['_chromaticAberrationEnabled']=!0x1,_0x3061f7['_grainEnabled']=!0x1,_0x3061f7['_buildAllowed']=!0x0,_0x3061f7['onBuildObservable']=new _0x6ac1f7['c'](),_0x3061f7['_resizeObserver']=null,_0x3061f7['_hardwareScaleLevel']=0x1,_0x3061f7['_bloomKernel']=0x40,_0x3061f7['_bloomWeight']=0.15,_0x3061f7['_bloomThreshold']=0.9,_0x3061f7['_samples']=0x1,_0x3061f7['_hasCleared']=!0x1,_0x3061f7['_prevPostProcess']=null,_0x3061f7['_prevPrevPostProcess']=null,_0x3061f7['_depthOfFieldSceneObserver']=null,_0x3061f7['_cameras']=_0x469ef1||_0x9156d6['cameras'],_0x3061f7['_cameras']=_0x3061f7['_cameras']['slice'](),_0x3061f7['_camerasToBeAttached']=_0x3061f7['_cameras']['slice'](),_0x3061f7['_buildAllowed']=_0x5d6b02,_0x3061f7['_scene']=_0x9156d6;var _0x391fea=_0x3061f7['_scene']['getEngine']()['getCaps']();_0x3061f7['_hdr']=_0x2fc272&&(_0x391fea['textureHalfFloatRender']||_0x391fea['textureFloatRender']),_0x3061f7['_hdr']?_0x391fea['textureHalfFloatRender']?_0x3061f7['_defaultPipelineTextureType']=_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT']:_0x391fea['textureFloatRender']&&(_0x3061f7['_defaultPipelineTextureType']=_0x2103ba['a']['TEXTURETYPE_FLOAT']):_0x3061f7['_defaultPipelineTextureType']=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'],_0x9156d6['postProcessRenderPipelineManager']['addPipeline'](_0x3061f7);var _0x5acb86=_0x3061f7['_scene']['getEngine']();return _0x3061f7['sharpen']=new _0x59740a('sharpen',0x1,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x5acb86,!0x1,_0x3061f7['_defaultPipelineTextureType'],!0x0),_0x3061f7['_sharpenEffect']=new _0x1f6f7e(_0x5acb86,_0x3061f7['SharpenPostProcessId'],function(){return _0x3061f7['sharpen'];},!0x0),_0x3061f7['depthOfField']=new _0x1f85e2(_0x3061f7['_scene'],null,_0x3061f7['_depthOfFieldBlurLevel'],_0x3061f7['_defaultPipelineTextureType'],!0x0),_0x3061f7['bloom']=new _0x199b31(_0x3061f7['_scene'],_0x3061f7['_bloomScale'],_0x3061f7['_bloomWeight'],_0x3061f7['bloomKernel'],_0x3061f7['_defaultPipelineTextureType'],!0x0),_0x3061f7['chromaticAberration']=new _0x151615('ChromaticAberration',_0x5acb86['getRenderWidth'](),_0x5acb86['getRenderHeight'](),0x1,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x5acb86,!0x1,_0x3061f7['_defaultPipelineTextureType'],!0x0),_0x3061f7['_chromaticAberrationEffect']=new _0x1f6f7e(_0x5acb86,_0x3061f7['ChromaticAberrationPostProcessId'],function(){return _0x3061f7['chromaticAberration'];},!0x0),_0x3061f7['grain']=new _0x338247('Grain',0x1,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x5acb86,!0x1,_0x3061f7['_defaultPipelineTextureType'],!0x0),_0x3061f7['_grainEffect']=new _0x1f6f7e(_0x5acb86,_0x3061f7['GrainPostProcessId'],function(){return _0x3061f7['grain'];},!0x0),_0x3061f7['_resizeObserver']=_0x5acb86['onResizeObservable']['add'](function(){_0x3061f7['_hardwareScaleLevel']=_0x5acb86['getHardwareScalingLevel'](),_0x3061f7['bloomKernel']=_0x3061f7['bloomKernel'];}),_0x3061f7['_imageProcessingConfigurationObserver']=_0x3061f7['_scene']['imageProcessingConfiguration']['onUpdateParameters']['add'](function(){_0x3061f7['bloom']['_downscale']['_exposure']=_0x3061f7['_scene']['imageProcessingConfiguration']['exposure'],_0x3061f7['imageProcessingEnabled']!==_0x3061f7['_scene']['imageProcessingConfiguration']['isEnabled']&&(_0x3061f7['_imageProcessingEnabled']=_0x3061f7['_scene']['imageProcessingConfiguration']['isEnabled'],_0x3061f7['_buildPipeline']());}),_0x3061f7['_buildPipeline'](),_0x3061f7;}return Object(_0x18e13d['d'])(_0x12f627,_0x38d324),Object['defineProperty'](_0x12f627['prototype'],'scene',{'get':function(){return this['_scene'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x12f627['prototype'],'sharpenEnabled',{'get':function(){return this['_sharpenEnabled'];},'set':function(_0x773d7d){this['_sharpenEnabled']!==_0x773d7d&&(this['_sharpenEnabled']=_0x773d7d,this['_buildPipeline']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x12f627['prototype'],'bloomKernel',{'get':function(){return this['_bloomKernel'];},'set':function(_0x32d619){this['_bloomKernel']=_0x32d619,this['bloom']['kernel']=_0x32d619/this['_hardwareScaleLevel'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x12f627['prototype'],'bloomWeight',{'get':function(){return this['_bloomWeight'];},'set':function(_0x234722){this['_bloomWeight']!==_0x234722&&(this['bloom']['weight']=_0x234722,this['_bloomWeight']=_0x234722);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x12f627['prototype'],'bloomThreshold',{'get':function(){return this['_bloomThreshold'];},'set':function(_0x24e05d){this['_bloomThreshold']!==_0x24e05d&&(this['bloom']['threshold']=_0x24e05d,this['_bloomThreshold']=_0x24e05d);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x12f627['prototype'],'bloomScale',{'get':function(){return this['_bloomScale'];},'set':function(_0x7b366d){this['_bloomScale']!==_0x7b366d&&(this['_bloomScale']=_0x7b366d,this['_rebuildBloom'](),this['_buildPipeline']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x12f627['prototype'],'bloomEnabled',{'get':function(){return this['_bloomEnabled'];},'set':function(_0x35f711){this['_bloomEnabled']!==_0x35f711&&(this['_bloomEnabled']=_0x35f711,this['_buildPipeline']());},'enumerable':!0x1,'configurable':!0x0}),_0x12f627['prototype']['_rebuildBloom']=function(){var _0x1e4c40=this['bloom'];this['bloom']=new _0x199b31(this['_scene'],this['bloomScale'],this['_bloomWeight'],this['bloomKernel'],this['_defaultPipelineTextureType'],!0x1),this['bloom']['threshold']=_0x1e4c40['threshold'];for(var _0x2394b8=0x0;_0x2394b80x1){for(var _0x3eacac=0x0,_0x23ae0b=this['_cameras'];_0x3eacac<_0x23ae0b['length'];_0x3eacac++){var _0x309672=_0x23ae0b[_0x3eacac];(_0x3e871f=this['_scene']['enableDepthRenderer'](_0x309672))['useOnlyInActiveCamera']=!0x0;}this['_depthOfFieldSceneObserver']=this['_scene']['onAfterRenderTargetsRenderObservable']['add'](function(_0x2907a9){_0x3089d1['_cameras']['indexOf'](_0x2907a9['activeCamera'])>-0x1&&(_0x3089d1['depthOfField']['depthTexture']=_0x2907a9['enableDepthRenderer'](_0x2907a9['activeCamera'])['getDepthMap']());});}else{this['_scene']['onAfterRenderTargetsRenderObservable']['remove'](this['_depthOfFieldSceneObserver']);var _0x3e871f=this['_scene']['enableDepthRenderer'](this['_cameras'][0x0]);this['depthOfField']['depthTexture']=_0x3e871f['getDepthMap']();}this['depthOfField']['_isReady']()||this['depthOfField']['_updateEffects'](),this['addEffect'](this['depthOfField']),this['_setAutoClearAndTextureSharing'](this['depthOfField']['_effects'][0x0],!0x0);}else this['_scene']['onAfterRenderTargetsRenderObservable']['remove'](this['_depthOfFieldSceneObserver']);this['bloomEnabled']&&(this['bloom']['_isReady']()||this['bloom']['_updateEffects'](),this['addEffect'](this['bloom']),this['_setAutoClearAndTextureSharing'](this['bloom']['_effects'][0x0],!0x0)),this['_imageProcessingEnabled']&&(this['imageProcessing']=new _0x53baeb('imageProcessing',0x1,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x42ceba,!0x1,this['_defaultPipelineTextureType']),this['_hdr']?(this['addEffect'](new _0x1f6f7e(_0x42ceba,this['ImageProcessingPostProcessId'],function(){return _0x3089d1['imageProcessing'];},!0x0)),this['_setAutoClearAndTextureSharing'](this['imageProcessing'])):this['_scene']['imageProcessingConfiguration']['applyByPostProcess']=!0x1,this['cameras']&&0x0!==this['cameras']['length']||(this['_scene']['imageProcessingConfiguration']['applyByPostProcess']=!0x1),this['imageProcessing']['getEffect']()||this['imageProcessing']['_updateParameters']()),this['sharpenEnabled']&&(this['sharpen']['isReady']()||this['sharpen']['updateEffect'](),this['addEffect'](this['_sharpenEffect']),this['_setAutoClearAndTextureSharing'](this['sharpen'])),this['grainEnabled']&&(this['grain']['isReady']()||this['grain']['updateEffect'](),this['addEffect'](this['_grainEffect']),this['_setAutoClearAndTextureSharing'](this['grain'])),this['chromaticAberrationEnabled']&&(this['chromaticAberration']['isReady']()||this['chromaticAberration']['updateEffect'](),this['addEffect'](this['_chromaticAberrationEffect']),this['_setAutoClearAndTextureSharing'](this['chromaticAberration'])),this['fxaaEnabled']&&(this['fxaa']=new _0x30558e('fxaa',0x1,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x42ceba,!0x1,this['_defaultPipelineTextureType']),this['addEffect'](new _0x1f6f7e(_0x42ceba,this['FxaaPostProcessId'],function(){return _0x3089d1['fxaa'];},!0x0)),this['_setAutoClearAndTextureSharing'](this['fxaa'],!0x0)),null!==this['_cameras']&&this['_scene']['postProcessRenderPipelineManager']['attachCamerasToRenderPipeline'](this['_name'],this['_cameras']),this['_scene']['activeCameras']&&this['_scene']['activeCameras']['length']>0x1&&(this['_scene']['autoClear']=!0x0),!this['_enableMSAAOnFirstPostProcess'](this['samples'])&&this['samples']>0x1&&_0x75193d['a']['Warn']('MSAA\x20failed\x20to\x20enable,\x20MSAA\x20is\x20only\x20supported\x20in\x20browsers\x20that\x20support\x20webGL\x20>=\x202.0'),this['onBuildObservable']['notifyObservers'](this);}},_0x12f627['prototype']['_disposePostProcesses']=function(_0x3f33d5){void 0x0===_0x3f33d5&&(_0x3f33d5=!0x1);for(var _0x1cb9e9=0x0;_0x1cb9e91e-2\x20?\x20rvec\x20:\x20vec3(-rvec.y,0.0,rvec.x);\x0avec3\x20tangent=normalize(rvec-normal*dot(rvec,normal));\x0avec3\x20bitangent=cross(normal,tangent);\x0amat3\x20tbn=mat3(tangent,bitangent,normal);\x0afloat\x20difference;\x0afor\x20(int\x20i=0;\x20i1.0\x20||\x20offset.y>1.0)\x20{\x0acontinue;\x0a}\x0a\x0a#ifndef\x20GEOMETRYBUFFER\x0afloat\x20sampleDepth=abs(texture2D(depthNormalSampler,offset.xy).r);\x0a#else\x0afloat\x20sampleDepth=abs(texture2D(depthSampler,offset.xy).r);\x0a#endif\x0a\x0adifference=depthSign*samplePosition.z-sampleDepth;\x0afloat\x20rangeCheck=1.0-smoothstep(correctedRadius*0.5,correctedRadius,difference);\x0aocclusion+=(difference>=0.0\x20?\x201.0\x20:\x200.0)*rangeCheck;\x0a}\x0aocclusion=occlusion*(1.0-smoothstep(maxZ*0.75,maxZ,depth));\x0afloat\x20ao=1.0-totalStrength*occlusion*samplesFactor;\x0afloat\x20result=clamp(ao+base,0.0,1.0);\x0agl_FragColor=vec4(vec3(result),1.0);\x0a}\x0a#endif\x0a#ifdef\x20BILATERAL_BLUR\x0auniform\x20sampler2D\x20depthNormalSampler;\x0auniform\x20float\x20outSize;\x0auniform\x20float\x20samplerOffsets[SAMPLES];\x0avec4\x20blur9(sampler2D\x20image,vec2\x20uv,float\x20resolution,vec2\x20direction)\x20{\x0avec4\x20color=vec4(0.0);\x0avec2\x20off1=vec2(1.3846153846)*direction;\x0avec2\x20off2=vec2(3.2307692308)*direction;\x0acolor+=texture2D(image,uv)*0.2270270270;\x0acolor+=texture2D(image,uv+(off1/resolution))*0.3162162162;\x0acolor+=texture2D(image,uv-(off1/resolution))*0.3162162162;\x0acolor+=texture2D(image,uv+(off2/resolution))*0.0702702703;\x0acolor+=texture2D(image,uv-(off2/resolution))*0.0702702703;\x0areturn\x20color;\x0a}\x0avec4\x20blur13(sampler2D\x20image,vec2\x20uv,float\x20resolution,vec2\x20direction)\x20{\x0avec4\x20color=vec4(0.0);\x0avec2\x20off1=vec2(1.411764705882353)*direction;\x0avec2\x20off2=vec2(3.2941176470588234)*direction;\x0avec2\x20off3=vec2(5.176470588235294)*direction;\x0acolor+=texture2D(image,uv)*0.1964825501511404;\x0acolor+=texture2D(image,uv+(off1/resolution))*0.2969069646728344;\x0acolor+=texture2D(image,uv-(off1/resolution))*0.2969069646728344;\x0acolor+=texture2D(image,uv+(off2/resolution))*0.09447039785044732;\x0acolor+=texture2D(image,uv-(off2/resolution))*0.09447039785044732;\x0acolor+=texture2D(image,uv+(off3/resolution))*0.010381362401148057;\x0acolor+=texture2D(image,uv-(off3/resolution))*0.010381362401148057;\x0areturn\x20color;\x0a}\x0avec4\x20blur13Bilateral(sampler2D\x20image,vec2\x20uv,float\x20resolution,vec2\x20direction)\x20{\x0avec4\x20color=vec4(0.0);\x0avec2\x20off1=vec2(1.411764705882353)*direction;\x0avec2\x20off2=vec2(3.2941176470588234)*direction;\x0avec2\x20off3=vec2(5.176470588235294)*direction;\x0afloat\x20compareDepth=abs(texture2D(depthNormalSampler,uv).r);\x0afloat\x20sampleDepth;\x0afloat\x20weight;\x0afloat\x20weightSum=30.0;\x0acolor+=texture2D(image,uv)*30.0;\x0asampleDepth=abs(texture2D(depthNormalSampler,uv+(off1/resolution)).r);\x0aweight=clamp(1.0/(\x200.003+abs(compareDepth-sampleDepth)),0.0,30.0);\x0aweightSum+=weight;\x0acolor+=texture2D(image,uv+(off1/resolution))*weight;\x0asampleDepth=abs(texture2D(depthNormalSampler,uv-(off1/resolution)).r);\x0aweight=clamp(1.0/(\x200.003+abs(compareDepth-sampleDepth)),0.0,30.0);\x0aweightSum+=weight;\x0acolor+=texture2D(image,uv-(off1/resolution))*weight;\x0asampleDepth=abs(texture2D(depthNormalSampler,uv+(off2/resolution)).r);\x0aweight=clamp(1.0/(\x200.003+abs(compareDepth-sampleDepth)),0.0,30.0);\x0aweightSum+=weight;\x0acolor+=texture2D(image,uv+(off2/resolution))*weight;\x0asampleDepth=abs(texture2D(depthNormalSampler,uv-(off2/resolution)).r);\x0aweight=clamp(1.0/(\x200.003+abs(compareDepth-sampleDepth)),0.0,30.0);\x0aweightSum+=weight;\x0acolor+=texture2D(image,uv-(off2/resolution))*weight;\x0asampleDepth=abs(texture2D(depthNormalSampler,uv+(off3/resolution)).r);\x0aweight=clamp(1.0/(\x200.003+abs(compareDepth-sampleDepth)),0.0,30.0);\x0aweightSum+=weight;\x0acolor+=texture2D(image,uv+(off3/resolution))*weight;\x0asampleDepth=abs(texture2D(depthNormalSampler,uv-(off3/resolution)).r);\x0aweight=clamp(1.0/(\x200.003+abs(compareDepth-sampleDepth)),0.0,30.0);\x0aweightSum+=weight;\x0acolor+=texture2D(image,uv-(off3/resolution))*weight;\x0areturn\x20color/weightSum;\x0a}\x0avoid\x20main()\x0a{\x0a#if\x20EXPENSIVE\x0afloat\x20compareDepth=abs(texture2D(depthNormalSampler,vUV).r);\x0afloat\x20texelsize=1.0/outSize;\x0afloat\x20result=0.0;\x0afloat\x20weightSum=0.0;\x0afor\x20(int\x20i=0;\x20i=0x2;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5b9047['prototype'],'scene',{'get':function(){return this['_scene'];},'enumerable':!0x1,'configurable':!0x0}),_0x5b9047['prototype']['getClassName']=function(){return'SSAO2RenderingPipeline';},_0x5b9047['prototype']['dispose']=function(_0x469825){void 0x0===_0x469825&&(_0x469825=!0x1);for(var _0x959c33=0x0;_0x959c330x0?_0x2d0f77['_ssaoCombinePostProcess']['width']:_0x2d0f77['_originalColorPostProcess']['width']),_0x2eb864['setFloat']('near',_0x2d0f77['_scene']['activeCamera']['minZ']),_0x2eb864['setFloat']('far',_0x2d0f77['_scene']['activeCamera']['maxZ']),_0x2eb864['setFloat']('radius',_0x2d0f77['radius']),_0x2d0f77['_forceGeometryBuffer']?_0x2eb864['setTexture']('depthNormalSampler',_0x2d0f77['_scene']['enableGeometryBufferRenderer']()['getGBuffer']()['textures'][0x0]):_0x2eb864['setTexture']('depthNormalSampler',_0x2d0f77['_prePassRenderer']['prePassRT']['textures'][_0x2d0f77['_prePassRenderer']['getIndex'](_0x2103ba['a']['PREPASS_DEPTHNORMAL_TEXTURE_TYPE'])]),_0x2eb864['setArray']('samplerOffsets',_0x2d0f77['_samplerOffsets']));},this['_blurVPostProcess']=new _0x5cae84('BlurV','ssao2',['outSize','samplerOffsets','near','far','radius'],['depthNormalSampler'],_0x5e6446,null,_0xaf3c80['a']['TRILINEAR_SAMPLINGMODE'],this['_scene']['getEngine'](),!0x1,'#define\x20BILATERAL_BLUR\x0a#define\x20BILATERAL_BLUR_V\x0a#define\x20SAMPLES\x2016\x0a#define\x20EXPENSIVE\x20'+(_0x55428e?'1':'0')+'\x0a'),this['_blurVPostProcess']['onApply']=function(_0x58269b){_0x2d0f77['_scene']['activeCamera']&&(_0x58269b['setFloat']('outSize',_0x2d0f77['_ssaoCombinePostProcess']['height']>0x0?_0x2d0f77['_ssaoCombinePostProcess']['height']:_0x2d0f77['_originalColorPostProcess']['height']),_0x58269b['setFloat']('near',_0x2d0f77['_scene']['activeCamera']['minZ']),_0x58269b['setFloat']('far',_0x2d0f77['_scene']['activeCamera']['maxZ']),_0x58269b['setFloat']('radius',_0x2d0f77['radius']),_0x2d0f77['_forceGeometryBuffer']?_0x58269b['setTexture']('depthNormalSampler',_0x2d0f77['_scene']['enableGeometryBufferRenderer']()['getGBuffer']()['textures'][0x0]):_0x58269b['setTexture']('depthNormalSampler',_0x2d0f77['_prePassRenderer']['prePassRT']['textures'][_0x2d0f77['_prePassRenderer']['getIndex'](_0x2103ba['a']['PREPASS_DEPTHNORMAL_TEXTURE_TYPE'])]),_0x58269b['setArray']('samplerOffsets',_0x2d0f77['_samplerOffsets']));},this['_blurHPostProcess']['samples']=this['textureSamples'],this['_blurVPostProcess']['samples']=this['textureSamples'];},_0x5b9047['prototype']['_rebuild']=function(){_0x2adb00['prototype']['_rebuild']['call'](this);},_0x5b9047['prototype']['_radicalInverse_VdC']=function(_0x3b6f55){return this['_bits'][0x0]=_0x3b6f55,this['_bits'][0x0]=(this['_bits'][0x0]<<0x10|this['_bits'][0x0]>>0x10)>>>0x0,this['_bits'][0x0]=(0x55555555&this['_bits'][0x0])<<0x1|(0xaaaaaaaa&this['_bits'][0x0])>>>0x1>>>0x0,this['_bits'][0x0]=(0x33333333&this['_bits'][0x0])<<0x2|(0xcccccccc&this['_bits'][0x0])>>>0x2>>>0x0,this['_bits'][0x0]=(0xf0f0f0f&this['_bits'][0x0])<<0x4|(0xf0f0f0f0&this['_bits'][0x0])>>>0x4>>>0x0,this['_bits'][0x0]=(0xff00ff&this['_bits'][0x0])<<0x8|(0xff00ff00&this['_bits'][0x0])>>>0x8>>>0x0,2.3283064365386963e-10*this['_bits'][0x0];},_0x5b9047['prototype']['_hammersley']=function(_0xc2958c,_0x3f67a9){return[_0xc2958c/_0x3f67a9,this['_radicalInverse_VdC'](_0xc2958c)];},_0x5b9047['prototype']['_hemisphereSample_uniform']=function(_0x3e28cd,_0x1cbbe3){var _0x58d8e6=0x2*_0x1cbbe3*Math['PI'],_0x28c641=0x1-(0.85*_0x3e28cd+0.15),_0x42a1fb=Math['sqrt'](0x1-_0x28c641*_0x28c641);return new _0x74d525['e'](Math['cos'](_0x58d8e6)*_0x42a1fb,Math['sin'](_0x58d8e6)*_0x42a1fb,_0x28c641);},_0x5b9047['prototype']['_generateHemisphere']=function(){for(var _0x5eeb01,_0x3248c7=this['samples'],_0x3a9653=[],_0x51e3b3=0x0;_0x51e3b3<_0x3248c7;){if(_0x3248c7<0x10)_0x5eeb01=this['_hemisphereSample_uniform'](Math['random'](),Math['random']());else{var _0x53fe4e=this['_hammersley'](_0x51e3b3,_0x3248c7);_0x5eeb01=this['_hemisphereSample_uniform'](_0x53fe4e[0x0],_0x53fe4e[0x1]);}_0x3a9653['push'](_0x5eeb01['x'],_0x5eeb01['y'],_0x5eeb01['z']),_0x51e3b3++;}return _0x3a9653;},_0x5b9047['prototype']['_getDefinesForSSAO']=function(){var _0x185bb4='#define\x20SAMPLES\x20'+this['samples']+'\x0a#define\x20SSAO';return this['_forceGeometryBuffer']&&(_0x185bb4+='\x0a#define\x20GEOMETRYBUFFER'),_0x185bb4;},_0x5b9047['prototype']['_createSSAOPostProcess']=function(_0x434fef){var _0x4a768a=this;this['_sampleSphere']=this['_generateHemisphere']();var _0x1e288d,_0x55bec3=this['_getDefinesForSSAO']();_0x1e288d=this['_forceGeometryBuffer']?['randomSampler','depthSampler','normalSampler']:['randomSampler','depthNormalSampler'],this['_ssaoPostProcess']=new _0x5cae84('ssao2','ssao2',['sampleSphere','samplesFactor','randTextureTiles','totalStrength','radius','base','range','projection','near','far','texelSize','xViewport','yViewport','maxZ','minZAspect'],_0x1e288d,_0x434fef,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],this['_scene']['getEngine'](),!0x1,_0x55bec3),this['_ssaoPostProcess']['onApply']=function(_0x5b0b84){_0x4a768a['_scene']['activeCamera']&&(_0x5b0b84['setArray3']('sampleSphere',_0x4a768a['_sampleSphere']),_0x5b0b84['setFloat']('randTextureTiles',0x20),_0x5b0b84['setFloat']('samplesFactor',0x1/_0x4a768a['samples']),_0x5b0b84['setFloat']('totalStrength',_0x4a768a['totalStrength']),_0x5b0b84['setFloat2']('texelSize',0x1/_0x4a768a['_ssaoPostProcess']['width'],0x1/_0x4a768a['_ssaoPostProcess']['height']),_0x5b0b84['setFloat']('radius',_0x4a768a['radius']),_0x5b0b84['setFloat']('maxZ',_0x4a768a['maxZ']),_0x5b0b84['setFloat']('minZAspect',_0x4a768a['minZAspect']),_0x5b0b84['setFloat']('base',_0x4a768a['base']),_0x5b0b84['setFloat']('near',_0x4a768a['_scene']['activeCamera']['minZ']),_0x5b0b84['setFloat']('far',_0x4a768a['_scene']['activeCamera']['maxZ']),_0x5b0b84['setFloat']('xViewport',Math['tan'](_0x4a768a['_scene']['activeCamera']['fov']/0x2)*_0x4a768a['_scene']['getEngine']()['getAspectRatio'](_0x4a768a['_scene']['activeCamera'],!0x0)),_0x5b0b84['setFloat']('yViewport',Math['tan'](_0x4a768a['_scene']['activeCamera']['fov']/0x2)),_0x5b0b84['setMatrix']('projection',_0x4a768a['_scene']['getProjectionMatrix']()),_0x4a768a['_forceGeometryBuffer']?(_0x5b0b84['setTexture']('depthSampler',_0x4a768a['_scene']['enableGeometryBufferRenderer']()['getGBuffer']()['textures'][0x0]),_0x5b0b84['setTexture']('normalSampler',_0x4a768a['_scene']['enableGeometryBufferRenderer']()['getGBuffer']()['textures'][0x1])):_0x5b0b84['setTexture']('depthNormalSampler',_0x4a768a['_prePassRenderer']['prePassRT']['textures'][_0x4a768a['_prePassRenderer']['getIndex'](_0x2103ba['a']['PREPASS_DEPTHNORMAL_TEXTURE_TYPE'])]),_0x5b0b84['setTexture']('randomSampler',_0x4a768a['_randomTexture']));},this['_ssaoPostProcess']['samples']=this['textureSamples'];},_0x5b9047['prototype']['_createSSAOCombinePostProcess']=function(_0x178c2b){var _0x30a632=this;this['_ssaoCombinePostProcess']=new _0x5cae84('ssaoCombine','ssaoCombine',[],['originalColor','viewport'],_0x178c2b,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],this['_scene']['getEngine'](),!0x1),this['_ssaoCombinePostProcess']['onApply']=function(_0x3b0555){var _0x532464=_0x30a632['_scene']['activeCamera']['viewport'];_0x3b0555['setVector4']('viewport',_0x74d525['c']['Vector4'][0x0]['copyFromFloats'](_0x532464['x'],_0x532464['y'],_0x532464['width'],_0x532464['height'])),_0x3b0555['setTextureFromPostProcessOutput']('originalColor',_0x30a632['_originalColorPostProcess']);},this['_ssaoCombinePostProcess']['samples']=this['textureSamples'],this['_forceGeometryBuffer']||(this['_ssaoCombinePostProcess']['_prePassEffectConfiguration']=new _0x2792f6());},_0x5b9047['prototype']['_createRandomTexture']=function(){this['_randomTexture']=new _0x41f891['a']('SSAORandomTexture',0x80,this['_scene'],!0x1,_0xaf3c80['a']['TRILINEAR_SAMPLINGMODE']),this['_randomTexture']['wrapU']=_0xaf3c80['a']['WRAP_ADDRESSMODE'],this['_randomTexture']['wrapV']=_0xaf3c80['a']['WRAP_ADDRESSMODE'];for(var _0x2bf510=this['_randomTexture']['getContext'](),_0x15d04c=function(_0x3cea23,_0x3b2af3){return Math['random']()*(_0x3b2af3-_0x3cea23)+_0x3cea23;},_0x42ea37=_0x74d525['e']['Zero'](),_0x5ea444=0x0;_0x5ea444<0x80;_0x5ea444++)for(var _0x284f3d=0x0;_0x284f3d<0x80;_0x284f3d++)_0x42ea37['x']=_0x15d04c(0x0,0x1),_0x42ea37['y']=_0x15d04c(0x0,0x1),_0x42ea37['z']=0x0,_0x42ea37['normalize'](),_0x42ea37['scaleInPlace'](0xff),_0x42ea37['x']=Math['floor'](_0x42ea37['x']),_0x42ea37['y']=Math['floor'](_0x42ea37['y']),_0x2bf510['fillStyle']='rgb('+_0x42ea37['x']+',\x20'+_0x42ea37['y']+',\x20'+_0x42ea37['z']+')',_0x2bf510['fillRect'](_0x5ea444,_0x284f3d,0x1,0x1);this['_randomTexture']['update'](!0x1);},_0x5b9047['prototype']['serialize']=function(){var _0x2cd2b3=_0x495d06['a']['Serialize'](this);return _0x2cd2b3['customType']='SSAO2RenderingPipeline',_0x2cd2b3;},_0x5b9047['Parse']=function(_0x59d914,_0x15d806,_0x28524f){return _0x495d06['a']['Parse'](function(){return new _0x5b9047(_0x59d914['_name'],_0x15d806,_0x59d914['_ratio']);},_0x59d914,_0x15d806,_0x28524f);},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x5b9047['prototype'],'totalStrength',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x5b9047['prototype'],'maxZ',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x5b9047['prototype'],'minZAspect',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])('samples')],_0x5b9047['prototype'],'_samples',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])('textureSamples')],_0x5b9047['prototype'],'_textureSamples',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x5b9047['prototype'],'_ratio',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])('expensiveBlur')],_0x5b9047['prototype'],'_expensiveBlur',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x5b9047['prototype'],'radius',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x5b9047['prototype'],'base',void 0x0),_0x5b9047;}(_0x15e31a);_0x3cd573['a']['RegisteredTypes']['BABYLON.SSAO2RenderingPipeline']=_0x1716c3;var _0x36e0ad='\x0auniform\x20sampler2D\x20textureSampler;\x0avarying\x20vec2\x20vUV;\x0a#ifdef\x20SSAO\x0auniform\x20sampler2D\x20randomSampler;\x0auniform\x20float\x20randTextureTiles;\x0auniform\x20float\x20samplesFactor;\x0auniform\x20vec3\x20sampleSphere[SAMPLES];\x0auniform\x20float\x20totalStrength;\x0auniform\x20float\x20radius;\x0auniform\x20float\x20area;\x0auniform\x20float\x20fallOff;\x0auniform\x20float\x20base;\x0avec3\x20normalFromDepth(float\x20depth,vec2\x20coords)\x0a{\x0avec2\x20offset1=vec2(0.0,radius);\x0avec2\x20offset2=vec2(radius,0.0);\x0afloat\x20depth1=texture2D(textureSampler,coords+offset1).r;\x0afloat\x20depth2=texture2D(textureSampler,coords+offset2).r;\x0avec3\x20p1=vec3(offset1,depth1-depth);\x0avec3\x20p2=vec3(offset2,depth2-depth);\x0avec3\x20normal=cross(p1,p2);\x0anormal.z=-normal.z;\x0areturn\x20normalize(normal);\x0a}\x0avoid\x20main()\x0a{\x0avec3\x20random=normalize(texture2D(randomSampler,vUV*randTextureTiles).rgb);\x0afloat\x20depth=texture2D(textureSampler,vUV).r;\x0avec3\x20position=vec3(vUV,depth);\x0avec3\x20normal=normalFromDepth(depth,vUV);\x0afloat\x20radiusDepth=radius/depth;\x0afloat\x20occlusion=0.0;\x0avec3\x20ray;\x0avec3\x20hemiRay;\x0afloat\x20occlusionDepth;\x0afloat\x20difference;\x0afor\x20(int\x20i=0;\x20i0.0)\x0ahitCoord-=dir;\x0aelse\x0ahitCoord+=dir;\x0ainfo.color+=texture2D(textureSampler,projectedCoord.xy).rgb;\x0a}\x0aprojectedCoord=projection*vec4(hitCoord,1.0);\x0aprojectedCoord.xy/=projectedCoord.w;\x0aprojectedCoord.xy=0.5*projectedCoord.xy+vec2(0.5);\x0a\x0ainfo.coords=vec4(projectedCoord.xy,sampledDepth,1.0);\x0ainfo.color+=texture2D(textureSampler,projectedCoord.xy).rgb;\x0ainfo.color/=float(SMOOTH_STEPS+1);\x0areturn\x20info;\x0a}\x0a\x0aReflectionInfo\x20getReflectionInfo(vec3\x20dir,vec3\x20hitCoord)\x0a{\x0aReflectionInfo\x20info;\x0avec4\x20projectedCoord;\x0afloat\x20sampledDepth;\x0adir*=step;\x0afor(int\x20i=0;\x20i>0x0)),_0x43ed73['push']('#define\x20SMOOTH_STEPS\x20'+(this['_smoothSteps']>>0x0)),this['updateEffect'](_0x43ed73['join']('\x0a'));},_0x3e5a97['_Parse']=function(_0x20829f,_0x154c79,_0xd6c8f0,_0x4136f9){return _0x495d06['a']['Parse'](function(){return new _0x3e5a97(_0x20829f['name'],_0xd6c8f0,_0x20829f['options'],_0x154c79,_0x20829f['renderTargetSamplingMode'],_0xd6c8f0['getEngine'](),_0x20829f['textureType'],_0x20829f['reusable']);},_0x20829f,_0xd6c8f0,_0x4136f9);},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3e5a97['prototype'],'threshold',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3e5a97['prototype'],'strength',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3e5a97['prototype'],'reflectionSpecularFalloffExponent',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3e5a97['prototype'],'step',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3e5a97['prototype'],'roughnessFactor',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3e5a97['prototype'],'enableSmoothReflections',null),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3e5a97['prototype'],'reflectionSamples',null),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x3e5a97['prototype'],'smoothSteps',null),_0x3e5a97;}(_0x5cae84);_0x3cd573['a']['RegisteredTypes']['BABYLON.ScreenSpaceReflectionPostProcess']=_0x5d05bb;var _0x462fe6='uniform\x20sampler2D\x20textureSampler;\x0avarying\x20vec2\x20vUV;\x0a#if\x20defined(PASS_POST_PROCESS)\x0avoid\x20main(void)\x0a{\x0avec4\x20color=texture2D(textureSampler,vUV);\x0agl_FragColor=color;\x0a}\x0a#endif\x0a#if\x20defined(DOWN_SAMPLE_X4)\x0auniform\x20vec2\x20dsOffsets[16];\x0avoid\x20main(void)\x0a{\x0avec4\x20average=vec4(0.0,0.0,0.0,0.0);\x0aaverage=texture2D(textureSampler,vUV+dsOffsets[0]);\x0aaverage+=texture2D(textureSampler,vUV+dsOffsets[1]);\x0aaverage+=texture2D(textureSampler,vUV+dsOffsets[2]);\x0aaverage+=texture2D(textureSampler,vUV+dsOffsets[3]);\x0aaverage+=texture2D(textureSampler,vUV+dsOffsets[4]);\x0aaverage+=texture2D(textureSampler,vUV+dsOffsets[5]);\x0aaverage+=texture2D(textureSampler,vUV+dsOffsets[6]);\x0aaverage+=texture2D(textureSampler,vUV+dsOffsets[7]);\x0aaverage+=texture2D(textureSampler,vUV+dsOffsets[8]);\x0aaverage+=texture2D(textureSampler,vUV+dsOffsets[9]);\x0aaverage+=texture2D(textureSampler,vUV+dsOffsets[10]);\x0aaverage+=texture2D(textureSampler,vUV+dsOffsets[11]);\x0aaverage+=texture2D(textureSampler,vUV+dsOffsets[12]);\x0aaverage+=texture2D(textureSampler,vUV+dsOffsets[13]);\x0aaverage+=texture2D(textureSampler,vUV+dsOffsets[14]);\x0aaverage+=texture2D(textureSampler,vUV+dsOffsets[15]);\x0aaverage/=16.0;\x0agl_FragColor=average;\x0a}\x0a#endif\x0a#if\x20defined(BRIGHT_PASS)\x0auniform\x20vec2\x20dsOffsets[4];\x0auniform\x20float\x20brightThreshold;\x0avoid\x20main(void)\x0a{\x0avec4\x20average=vec4(0.0,0.0,0.0,0.0);\x0aaverage=texture2D(textureSampler,vUV+vec2(dsOffsets[0].x,dsOffsets[0].y));\x0aaverage+=texture2D(textureSampler,vUV+vec2(dsOffsets[1].x,dsOffsets[1].y));\x0aaverage+=texture2D(textureSampler,vUV+vec2(dsOffsets[2].x,dsOffsets[2].y));\x0aaverage+=texture2D(textureSampler,vUV+vec2(dsOffsets[3].x,dsOffsets[3].y));\x0aaverage*=0.25;\x0afloat\x20luminance=length(average.rgb);\x0aif\x20(luminanceshadowPixelDepth)\x0aaccumFog+=sunColor*computeScattering(dot(rayDirection,sunDirection));\x0acurrentPosition+=stepL;\x0a}\x0aaccumFog/=NB_STEPS;\x0avec3\x20color=accumFog*scatteringPower;\x0agl_FragColor=vec4(color*exp(color)\x20,1.0);\x0a}\x0a#endif\x0a#if\x20defined(VLSMERGE)\x0auniform\x20sampler2D\x20originalSampler;\x0avoid\x20main(void)\x0a{\x0agl_FragColor=texture2D(originalSampler,vUV)+texture2D(textureSampler,vUV);\x0a}\x0a#endif\x0a#if\x20defined(LUMINANCE)\x0auniform\x20vec2\x20lumOffsets[4];\x0avoid\x20main()\x0a{\x0afloat\x20average=0.0;\x0avec4\x20color=vec4(0.0);\x0afloat\x20maximum=-1e20;\x0avec3\x20weight=vec3(0.299,0.587,0.114);\x0afor\x20(int\x20i=0;\x20i<4;\x20i++)\x0a{\x0acolor=texture2D(textureSampler,vUV+\x20lumOffsets[i]);\x0a\x0afloat\x20GreyValue=dot(color.rgb,vec3(0.33,0.33,0.33));\x0a\x0a#ifdef\x20WEIGHTED_AVERAGE\x0afloat\x20GreyValue=dot(color.rgb,weight);\x0a#endif\x0a#ifdef\x20BRIGHTNESS\x0afloat\x20GreyValue=max(color.r,max(color.g,color.b));\x0a#endif\x0a#ifdef\x20HSL_COMPONENT\x0afloat\x20GreyValue=0.5*(max(color.r,max(color.g,color.b))+min(color.r,min(color.g,color.b)));\x0a#endif\x0a#ifdef\x20MAGNITUDE\x0afloat\x20GreyValue=length(color.rgb);\x0a#endif\x0amaximum=max(maximum,GreyValue);\x0aaverage+=(0.25*log(1e-5+GreyValue));\x0a}\x0aaverage=exp(average);\x0agl_FragColor=vec4(average,maximum,0.0,1.0);\x0a}\x0a#endif\x0a#if\x20defined(LUMINANCE_DOWN_SAMPLE)\x0auniform\x20vec2\x20dsOffsets[9];\x0auniform\x20float\x20halfDestPixelSize;\x0a#ifdef\x20FINAL_DOWN_SAMPLER\x0a#include\x0a#endif\x0avoid\x20main()\x0a{\x0avec4\x20color=vec4(0.0);\x0afloat\x20average=0.0;\x0afor\x20(int\x20i=0;\x20i<9;\x20i++)\x0a{\x0acolor=texture2D(textureSampler,vUV+vec2(halfDestPixelSize,halfDestPixelSize)+dsOffsets[i]);\x0aaverage+=color.r;\x0a}\x0aaverage/=9.0;\x0a#ifdef\x20FINAL_DOWN_SAMPLER\x0agl_FragColor=pack(average);\x0a#else\x0agl_FragColor=vec4(average,average,0.0,1.0);\x0a#endif\x0a}\x0a#endif\x0a#if\x20defined(HDR)\x0auniform\x20sampler2D\x20textureAdderSampler;\x0auniform\x20float\x20averageLuminance;\x0avoid\x20main()\x0a{\x0avec4\x20color=texture2D(textureAdderSampler,vUV);\x0a#ifndef\x20AUTO_EXPOSURE\x0avec4\x20adjustedColor=color/averageLuminance;\x0acolor=adjustedColor;\x0acolor.a=1.0;\x0a#endif\x0agl_FragColor=color;\x0a}\x0a#endif\x0a#if\x20defined(LENS_FLARE)\x0a#define\x20GHOSTS\x203\x0auniform\x20sampler2D\x20lensColorSampler;\x0auniform\x20float\x20strength;\x0auniform\x20float\x20ghostDispersal;\x0auniform\x20float\x20haloWidth;\x0auniform\x20vec2\x20resolution;\x0auniform\x20float\x20distortionStrength;\x0afloat\x20hash(vec2\x20p)\x0a{\x0afloat\x20h=dot(p,vec2(127.1,311.7));\x0areturn\x20-1.0+2.0*fract(sin(h)*43758.5453123);\x0a}\x0afloat\x20noise(in\x20vec2\x20p)\x0a{\x0avec2\x20i=floor(p);\x0avec2\x20f=fract(p);\x0avec2\x20u=f*f*(3.0-2.0*f);\x0areturn\x20mix(mix(hash(i+vec2(0.0,0.0)),\x0ahash(i+vec2(1.0,0.0)),u.x),\x0amix(hash(i+vec2(0.0,1.0)),\x0ahash(i+vec2(1.0,1.0)),u.x),u.y);\x0a}\x0afloat\x20fbm(vec2\x20p)\x0a{\x0afloat\x20f=0.0;\x0af+=0.5000*noise(p);\x20p*=2.02;\x0af+=0.2500*noise(p);\x20p*=2.03;\x0af+=0.1250*noise(p);\x20p*=2.01;\x0af+=0.0625*noise(p);\x20p*=2.04;\x0af/=0.9375;\x0areturn\x20f;\x0a}\x0avec3\x20pattern(vec2\x20uv)\x0a{\x0avec2\x20p=-1.0+2.0*uv;\x0afloat\x20p2=dot(p,p);\x0afloat\x20f=fbm(vec2(15.0*p2))/2.0;\x0afloat\x20r=0.2+0.6*sin(12.5*length(uv-vec2(0.5)));\x0afloat\x20g=0.2+0.6*sin(20.5*length(uv-vec2(0.5)));\x0afloat\x20b=0.2+0.6*sin(17.2*length(uv-vec2(0.5)));\x0areturn\x20(1.0-f)*vec3(r,g,b);\x0a}\x0afloat\x20luminance(vec3\x20color)\x0a{\x0areturn\x20dot(color.rgb,vec3(0.2126,0.7152,0.0722));\x0a}\x0avec4\x20textureDistorted(sampler2D\x20tex,vec2\x20texcoord,vec2\x20direction,vec3\x20distortion)\x0a{\x0areturn\x20vec4(\x0atexture2D(tex,texcoord+direction*distortion.r).r,\x0atexture2D(tex,texcoord+direction*distortion.g).g,\x0atexture2D(tex,texcoord+direction*distortion.b).b,\x0a1.0\x0a);\x0a}\x0avoid\x20main(void)\x0a{\x0avec2\x20uv=-vUV+vec2(1.0);\x0avec2\x20ghostDir=(vec2(0.5)-uv)*ghostDispersal;\x0avec2\x20texelSize=1.0/resolution;\x0avec3\x20distortion=vec3(-texelSize.x*distortionStrength,0.0,texelSize.x*distortionStrength);\x0avec4\x20result=vec4(0.0);\x0afloat\x20ghostIndice=1.0;\x0afor\x20(int\x20i=0;\x20i=nSamples)\x0abreak;\x0avec2\x20offset1=vUV+velocity*(float(i)/float(nSamples-1)-0.5);\x0aresult+=texture2D(textureSampler,offset1);\x0a}\x0agl_FragColor=result/float(nSamples);\x0a}\x0a#endif\x0a';_0x494b01['a']['ShadersStore']['standardPixelShader']=_0x462fe6;var _0x6a7ba7=function(_0x39b72a){function _0x355dbd(_0x49d468,_0x2f8f68,_0x42dfce,_0x3a8f39,_0x5f223b){void 0x0===_0x3a8f39&&(_0x3a8f39=null);var _0x2c39d8=_0x39b72a['call'](this,_0x2f8f68['getEngine'](),_0x49d468)||this;return _0x2c39d8['downSampleX4PostProcess']=null,_0x2c39d8['brightPassPostProcess']=null,_0x2c39d8['blurHPostProcesses']=[],_0x2c39d8['blurVPostProcesses']=[],_0x2c39d8['textureAdderPostProcess']=null,_0x2c39d8['volumetricLightPostProcess']=null,_0x2c39d8['volumetricLightSmoothXPostProcess']=null,_0x2c39d8['volumetricLightSmoothYPostProcess']=null,_0x2c39d8['volumetricLightMergePostProces']=null,_0x2c39d8['volumetricLightFinalPostProcess']=null,_0x2c39d8['luminancePostProcess']=null,_0x2c39d8['luminanceDownSamplePostProcesses']=[],_0x2c39d8['hdrPostProcess']=null,_0x2c39d8['textureAdderFinalPostProcess']=null,_0x2c39d8['lensFlareFinalPostProcess']=null,_0x2c39d8['hdrFinalPostProcess']=null,_0x2c39d8['lensFlarePostProcess']=null,_0x2c39d8['lensFlareComposePostProcess']=null,_0x2c39d8['motionBlurPostProcess']=null,_0x2c39d8['depthOfFieldPostProcess']=null,_0x2c39d8['fxaaPostProcess']=null,_0x2c39d8['screenSpaceReflectionPostProcess']=null,_0x2c39d8['brightThreshold']=0x1,_0x2c39d8['blurWidth']=0x200,_0x2c39d8['horizontalBlur']=!0x1,_0x2c39d8['lensTexture']=null,_0x2c39d8['volumetricLightCoefficient']=0.2,_0x2c39d8['volumetricLightPower']=0x4,_0x2c39d8['volumetricLightBlurScale']=0x40,_0x2c39d8['sourceLight']=null,_0x2c39d8['hdrMinimumLuminance']=0x1,_0x2c39d8['hdrDecreaseRate']=0.5,_0x2c39d8['hdrIncreaseRate']=0.5,_0x2c39d8['lensColorTexture']=null,_0x2c39d8['lensFlareStrength']=0x14,_0x2c39d8['lensFlareGhostDispersal']=1.4,_0x2c39d8['lensFlareHaloWidth']=0.7,_0x2c39d8['lensFlareDistortionStrength']=0x10,_0x2c39d8['lensFlareBlurWidth']=0x200,_0x2c39d8['lensStarTexture']=null,_0x2c39d8['lensFlareDirtTexture']=null,_0x2c39d8['depthOfFieldDistance']=0xa,_0x2c39d8['depthOfFieldBlurWidth']=0x40,_0x2c39d8['animations']=[],_0x2c39d8['_currentDepthOfFieldSource']=null,_0x2c39d8['_fixedExposure']=0x1,_0x2c39d8['_currentExposure']=0x1,_0x2c39d8['_hdrAutoExposure']=!0x1,_0x2c39d8['_hdrCurrentLuminance']=0x1,_0x2c39d8['_motionStrength']=0x1,_0x2c39d8['_isObjectBasedMotionBlur']=!0x1,_0x2c39d8['_camerasToBeAttached']=[],_0x2c39d8['_bloomEnabled']=!0x1,_0x2c39d8['_depthOfFieldEnabled']=!0x1,_0x2c39d8['_vlsEnabled']=!0x1,_0x2c39d8['_lensFlareEnabled']=!0x1,_0x2c39d8['_hdrEnabled']=!0x1,_0x2c39d8['_motionBlurEnabled']=!0x1,_0x2c39d8['_fxaaEnabled']=!0x1,_0x2c39d8['_screenSpaceReflectionsEnabled']=!0x1,_0x2c39d8['_motionBlurSamples']=0x40,_0x2c39d8['_volumetricLightStepsCount']=0x32,_0x2c39d8['_samples']=0x1,_0x2c39d8['_cameras']=_0x5f223b||_0x2f8f68['cameras'],_0x2c39d8['_cameras']=_0x2c39d8['_cameras']['slice'](),_0x2c39d8['_camerasToBeAttached']=_0x2c39d8['_cameras']['slice'](),_0x2c39d8['_scene']=_0x2f8f68,_0x2c39d8['_basePostProcess']=_0x3a8f39,_0x2c39d8['_ratio']=_0x42dfce,_0x2c39d8['_floatTextureType']=_0x2f8f68['getEngine']()['getCaps']()['textureFloatRender']?_0x2103ba['a']['TEXTURETYPE_FLOAT']:_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT'],_0x2f8f68['postProcessRenderPipelineManager']['addPipeline'](_0x2c39d8),_0x2c39d8['_buildPipeline'](),_0x2c39d8;}return Object(_0x18e13d['d'])(_0x355dbd,_0x39b72a),Object['defineProperty'](_0x355dbd['prototype'],'exposure',{'get':function(){return this['_fixedExposure'];},'set':function(_0x245bbe){this['_fixedExposure']=_0x245bbe,this['_currentExposure']=_0x245bbe;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x355dbd['prototype'],'hdrAutoExposure',{'get':function(){return this['_hdrAutoExposure'];},'set':function(_0x2114ea){if(this['_hdrAutoExposure']=_0x2114ea,this['hdrPostProcess']){var _0x7fcd54=['#define\x20HDR'];_0x2114ea&&_0x7fcd54['push']('#define\x20AUTO_EXPOSURE'),this['hdrPostProcess']['updateEffect'](_0x7fcd54['join']('\x0a'));}},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x355dbd['prototype'],'motionStrength',{'get':function(){return this['_motionStrength'];},'set':function(_0x36ba54){this['_motionStrength']=_0x36ba54,this['_isObjectBasedMotionBlur']&&this['motionBlurPostProcess']&&(this['motionBlurPostProcess']['motionStrength']=_0x36ba54);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x355dbd['prototype'],'objectBasedMotionBlur',{'get':function(){return this['_isObjectBasedMotionBlur'];},'set':function(_0x169d12){var _0x46dc87=this['_isObjectBasedMotionBlur']!==_0x169d12;this['_isObjectBasedMotionBlur']=_0x169d12,_0x46dc87&&this['_buildPipeline']();},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x355dbd['prototype'],'BloomEnabled',{'get':function(){return this['_bloomEnabled'];},'set':function(_0x50ce11){this['_bloomEnabled']!==_0x50ce11&&(this['_bloomEnabled']=_0x50ce11,this['_buildPipeline']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x355dbd['prototype'],'DepthOfFieldEnabled',{'get':function(){return this['_depthOfFieldEnabled'];},'set':function(_0xeca412){this['_depthOfFieldEnabled']!==_0xeca412&&(this['_depthOfFieldEnabled']=_0xeca412,this['_buildPipeline']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x355dbd['prototype'],'LensFlareEnabled',{'get':function(){return this['_lensFlareEnabled'];},'set':function(_0x2cd4c9){this['_lensFlareEnabled']!==_0x2cd4c9&&(this['_lensFlareEnabled']=_0x2cd4c9,this['_buildPipeline']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x355dbd['prototype'],'HDREnabled',{'get':function(){return this['_hdrEnabled'];},'set':function(_0x22c53a){this['_hdrEnabled']!==_0x22c53a&&(this['_hdrEnabled']=_0x22c53a,this['_buildPipeline']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x355dbd['prototype'],'VLSEnabled',{'get':function(){return this['_vlsEnabled'];},'set':function(_0x4e4ac9){if(this['_vlsEnabled']!==_0x4e4ac9){if(_0x4e4ac9){if(!this['_scene']['enableGeometryBufferRenderer']())return void _0x75193d['a']['Warn']('Geometry\x20renderer\x20is\x20not\x20supported,\x20cannot\x20create\x20volumetric\x20lights\x20in\x20Standard\x20Rendering\x20Pipeline');}this['_vlsEnabled']=_0x4e4ac9,this['_buildPipeline']();}},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x355dbd['prototype'],'MotionBlurEnabled',{'get':function(){return this['_motionBlurEnabled'];},'set':function(_0x5498e8){this['_motionBlurEnabled']!==_0x5498e8&&(this['_motionBlurEnabled']=_0x5498e8,this['_buildPipeline']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x355dbd['prototype'],'fxaaEnabled',{'get':function(){return this['_fxaaEnabled'];},'set':function(_0x5321df){this['_fxaaEnabled']!==_0x5321df&&(this['_fxaaEnabled']=_0x5321df,this['_buildPipeline']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x355dbd['prototype'],'screenSpaceReflectionsEnabled',{'get':function(){return this['_screenSpaceReflectionsEnabled'];},'set':function(_0x458136){this['_screenSpaceReflectionsEnabled']!==_0x458136&&(this['_screenSpaceReflectionsEnabled']=_0x458136,this['_buildPipeline']());},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x355dbd['prototype'],'volumetricLightStepsCount',{'get':function(){return this['_volumetricLightStepsCount'];},'set':function(_0x17582b){this['volumetricLightPostProcess']&&this['volumetricLightPostProcess']['updateEffect']('#define\x20VLS\x0a#define\x20NB_STEPS\x20'+_0x17582b['toFixed'](0x1)),this['_volumetricLightStepsCount']=_0x17582b;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x355dbd['prototype'],'motionBlurSamples',{'get':function(){return this['_motionBlurSamples'];},'set':function(_0x2de237){this['motionBlurPostProcess']&&(this['_isObjectBasedMotionBlur']?this['motionBlurPostProcess']['motionBlurSamples']=_0x2de237:this['motionBlurPostProcess']['updateEffect']('#define\x20MOTION_BLUR\x0a#define\x20MAX_MOTION_SAMPLES\x20'+_0x2de237['toFixed'](0x1))),this['_motionBlurSamples']=_0x2de237;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x355dbd['prototype'],'samples',{'get':function(){return this['_samples'];},'set':function(_0x143654){this['_samples']!==_0x143654&&(this['_samples']=_0x143654,this['_buildPipeline']());},'enumerable':!0x1,'configurable':!0x0}),_0x355dbd['prototype']['_buildPipeline']=function(){var _0x1fb46a=this,_0x5c78c7=this['_ratio'],_0x4832b7=this['_scene'];this['_disposePostProcesses'](),null!==this['_cameras']&&(this['_scene']['postProcessRenderPipelineManager']['detachCamerasFromRenderPipeline'](this['_name'],this['_cameras']),this['_cameras']=this['_camerasToBeAttached']['slice']()),this['_reset'](),this['_screenSpaceReflectionsEnabled']&&(this['screenSpaceReflectionPostProcess']=new _0x5d05bb('HDRPass',_0x4832b7,_0x5c78c7,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x4832b7['getEngine'](),!0x1,this['_floatTextureType']),this['screenSpaceReflectionPostProcess']['onApplyObservable']['add'](function(){_0x1fb46a['_currentDepthOfFieldSource']=_0x1fb46a['screenSpaceReflectionPostProcess'];}),this['addEffect'](new _0x1f6f7e(_0x4832b7['getEngine'](),'HDRScreenSpaceReflections',function(){return _0x1fb46a['screenSpaceReflectionPostProcess'];},!0x0))),this['_basePostProcess']?this['originalPostProcess']=this['_basePostProcess']:this['originalPostProcess']=new _0x5cae84('HDRPass','standard',[],[],_0x5c78c7,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x4832b7['getEngine'](),!0x1,'#define\x20PASS_POST_PROCESS',this['_floatTextureType']),this['originalPostProcess']['autoClear']=!this['screenSpaceReflectionPostProcess'],this['originalPostProcess']['onApplyObservable']['add'](function(){_0x1fb46a['_currentDepthOfFieldSource']=_0x1fb46a['originalPostProcess'];}),this['addEffect'](new _0x1f6f7e(_0x4832b7['getEngine'](),'HDRPassPostProcess',function(){return _0x1fb46a['originalPostProcess'];},!0x0)),this['_bloomEnabled']&&(this['_createDownSampleX4PostProcess'](_0x4832b7,_0x5c78c7/0x4),this['_createBrightPassPostProcess'](_0x4832b7,_0x5c78c7/0x4),this['_createBlurPostProcesses'](_0x4832b7,_0x5c78c7/0x4,0x1),this['_createTextureAdderPostProcess'](_0x4832b7,_0x5c78c7),this['textureAdderFinalPostProcess']=new _0x5cae84('HDRDepthOfFieldSource','standard',[],[],_0x5c78c7,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x4832b7['getEngine'](),!0x1,'#define\x20PASS_POST_PROCESS',_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),this['addEffect'](new _0x1f6f7e(_0x4832b7['getEngine'](),'HDRBaseDepthOfFieldSource',function(){return _0x1fb46a['textureAdderFinalPostProcess'];},!0x0))),this['_vlsEnabled']&&(this['_createVolumetricLightPostProcess'](_0x4832b7,_0x5c78c7),this['volumetricLightFinalPostProcess']=new _0x5cae84('HDRVLSFinal','standard',[],[],_0x5c78c7,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x4832b7['getEngine'](),!0x1,'#define\x20PASS_POST_PROCESS',_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),this['addEffect'](new _0x1f6f7e(_0x4832b7['getEngine'](),'HDRVLSFinal',function(){return _0x1fb46a['volumetricLightFinalPostProcess'];},!0x0))),this['_lensFlareEnabled']&&(this['_createLensFlarePostProcess'](_0x4832b7,_0x5c78c7),this['lensFlareFinalPostProcess']=new _0x5cae84('HDRPostLensFlareDepthOfFieldSource','standard',[],[],_0x5c78c7,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x4832b7['getEngine'](),!0x1,'#define\x20PASS_POST_PROCESS',_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),this['addEffect'](new _0x1f6f7e(_0x4832b7['getEngine'](),'HDRPostLensFlareDepthOfFieldSource',function(){return _0x1fb46a['lensFlareFinalPostProcess'];},!0x0))),this['_hdrEnabled']&&(this['_createLuminancePostProcesses'](_0x4832b7,this['_floatTextureType']),this['_createHdrPostProcess'](_0x4832b7,_0x5c78c7),this['hdrFinalPostProcess']=new _0x5cae84('HDRPostHDReDepthOfFieldSource','standard',[],[],_0x5c78c7,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x4832b7['getEngine'](),!0x1,'#define\x20PASS_POST_PROCESS',_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),this['addEffect'](new _0x1f6f7e(_0x4832b7['getEngine'](),'HDRPostHDReDepthOfFieldSource',function(){return _0x1fb46a['hdrFinalPostProcess'];},!0x0))),this['_depthOfFieldEnabled']&&(this['_createBlurPostProcesses'](_0x4832b7,_0x5c78c7/0x2,0x3,'depthOfFieldBlurWidth'),this['_createDepthOfFieldPostProcess'](_0x4832b7,_0x5c78c7)),this['_motionBlurEnabled']&&this['_createMotionBlurPostProcess'](_0x4832b7,_0x5c78c7),this['_fxaaEnabled']&&(this['fxaaPostProcess']=new _0x30558e('fxaa',0x1,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x4832b7['getEngine'](),!0x1,_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),this['addEffect'](new _0x1f6f7e(_0x4832b7['getEngine'](),'HDRFxaa',function(){return _0x1fb46a['fxaaPostProcess'];},!0x0))),null!==this['_cameras']&&this['_scene']['postProcessRenderPipelineManager']['attachCamerasToRenderPipeline'](this['_name'],this['_cameras']),!this['_enableMSAAOnFirstPostProcess'](this['_samples'])&&this['_samples']>0x1&&_0x75193d['a']['Warn']('MSAA\x20failed\x20to\x20enable,\x20MSAA\x20is\x20only\x20supported\x20in\x20browsers\x20that\x20support\x20webGL\x20>=\x202.0');},_0x355dbd['prototype']['_createDownSampleX4PostProcess']=function(_0x1c0e3c,_0x227c81){var _0x3cb73b=this,_0x100e0c=new Array(0x20);this['downSampleX4PostProcess']=new _0x5cae84('HDRDownSampleX4','standard',['dsOffsets'],[],_0x227c81,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x1c0e3c['getEngine'](),!0x1,'#define\x20DOWN_SAMPLE_X4',this['_floatTextureType']),this['downSampleX4PostProcess']['onApply']=function(_0x468d11){for(var _0x33d7d9=0x0,_0x42bd8f=_0x3cb73b['downSampleX4PostProcess']['width'],_0x3f94cd=_0x3cb73b['downSampleX4PostProcess']['height'],_0x1792b9=-0x2;_0x1792b9<0x2;_0x1792b9++)for(var _0x431003=-0x2;_0x431003<0x2;_0x431003++)_0x100e0c[_0x33d7d9]=(_0x1792b9+0.5)*(0x1/_0x42bd8f),_0x100e0c[_0x33d7d9+0x1]=(_0x431003+0.5)*(0x1/_0x3f94cd),_0x33d7d9+=0x2;_0x468d11['setArray2']('dsOffsets',_0x100e0c);},this['addEffect'](new _0x1f6f7e(_0x1c0e3c['getEngine'](),'HDRDownSampleX4',function(){return _0x3cb73b['downSampleX4PostProcess'];},!0x0));},_0x355dbd['prototype']['_createBrightPassPostProcess']=function(_0x3d5916,_0x21c249){var _0x168bff=this,_0x244cfd=new Array(0x8);this['brightPassPostProcess']=new _0x5cae84('HDRBrightPass','standard',['dsOffsets','brightThreshold'],[],_0x21c249,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x3d5916['getEngine'](),!0x1,'#define\x20BRIGHT_PASS',this['_floatTextureType']),this['brightPassPostProcess']['onApply']=function(_0x48070e){var _0x2fab78=0x1/_0x168bff['brightPassPostProcess']['width'],_0x5bcf77=0x1/_0x168bff['brightPassPostProcess']['height'];_0x244cfd[0x0]=-0.5*_0x2fab78,_0x244cfd[0x1]=0.5*_0x5bcf77,_0x244cfd[0x2]=0.5*_0x2fab78,_0x244cfd[0x3]=0.5*_0x5bcf77,_0x244cfd[0x4]=-0.5*_0x2fab78,_0x244cfd[0x5]=-0.5*_0x5bcf77,_0x244cfd[0x6]=0.5*_0x2fab78,_0x244cfd[0x7]=-0.5*_0x5bcf77,_0x48070e['setArray2']('dsOffsets',_0x244cfd),_0x48070e['setFloat']('brightThreshold',_0x168bff['brightThreshold']);},this['addEffect'](new _0x1f6f7e(_0x3d5916['getEngine'](),'HDRBrightPass',function(){return _0x168bff['brightPassPostProcess'];},!0x0));},_0x355dbd['prototype']['_createBlurPostProcesses']=function(_0x4de2f4,_0x4c7f32,_0x5ec602,_0x51eb2d){var _0x4dfb58=this;void 0x0===_0x51eb2d&&(_0x51eb2d='blurWidth');var _0x4d2b71=_0x4de2f4['getEngine'](),_0x192c35=new _0x487d78('HDRBlurH_'+_0x5ec602,new _0x74d525['d'](0x1,0x0),this[_0x51eb2d],_0x4c7f32,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x4de2f4['getEngine'](),!0x1,this['_floatTextureType']),_0x2fc5d8=new _0x487d78('HDRBlurV_'+_0x5ec602,new _0x74d525['d'](0x0,0x1),this[_0x51eb2d],_0x4c7f32,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x4de2f4['getEngine'](),!0x1,this['_floatTextureType']);_0x192c35['onActivateObservable']['add'](function(){var _0x1e7589=_0x192c35['width']/_0x4d2b71['getRenderWidth']();_0x192c35['kernel']=_0x4dfb58[_0x51eb2d]*_0x1e7589;}),_0x2fc5d8['onActivateObservable']['add'](function(){var _0x1eb65f=_0x2fc5d8['height']/_0x4d2b71['getRenderHeight']();_0x2fc5d8['kernel']=_0x4dfb58['horizontalBlur']?0x40*_0x1eb65f:_0x4dfb58[_0x51eb2d]*_0x1eb65f;}),this['addEffect'](new _0x1f6f7e(_0x4de2f4['getEngine'](),'HDRBlurH'+_0x5ec602,function(){return _0x192c35;},!0x0)),this['addEffect'](new _0x1f6f7e(_0x4de2f4['getEngine'](),'HDRBlurV'+_0x5ec602,function(){return _0x2fc5d8;},!0x0)),this['blurHPostProcesses']['push'](_0x192c35),this['blurVPostProcesses']['push'](_0x2fc5d8);},_0x355dbd['prototype']['_createTextureAdderPostProcess']=function(_0x5b1998,_0x382d18){var _0x4088ee=this;this['textureAdderPostProcess']=new _0x5cae84('HDRTextureAdder','standard',['exposure'],['otherSampler','lensSampler'],_0x382d18,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x5b1998['getEngine'](),!0x1,'#define\x20TEXTURE_ADDER',this['_floatTextureType']),this['textureAdderPostProcess']['onApply']=function(_0x9e6d90){_0x9e6d90['setTextureFromPostProcess']('otherSampler',_0x4088ee['_vlsEnabled']?_0x4088ee['_currentDepthOfFieldSource']:_0x4088ee['originalPostProcess']),_0x9e6d90['setTexture']('lensSampler',_0x4088ee['lensTexture']),_0x9e6d90['setFloat']('exposure',_0x4088ee['_currentExposure']),_0x4088ee['_currentDepthOfFieldSource']=_0x4088ee['textureAdderFinalPostProcess'];},this['addEffect'](new _0x1f6f7e(_0x5b1998['getEngine'](),'HDRTextureAdder',function(){return _0x4088ee['textureAdderPostProcess'];},!0x0));},_0x355dbd['prototype']['_createVolumetricLightPostProcess']=function(_0x55e983,_0x166ea0){var _0x378624=this,_0x4c956f=_0x55e983['enableGeometryBufferRenderer']();_0x4c956f['enablePosition']=!0x0;var _0x4e60eb=_0x4c956f['getGBuffer']();this['volumetricLightPostProcess']=new _0x5cae84('HDRVLS','standard',['shadowViewProjection','cameraPosition','sunDirection','sunColor','scatteringCoefficient','scatteringPower','depthValues'],['shadowMapSampler','positionSampler'],_0x166ea0/0x8,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x55e983['getEngine'](),!0x1,'#define\x20VLS\x0a#define\x20NB_STEPS\x20'+this['_volumetricLightStepsCount']['toFixed'](0x1));var _0x5ee7c5=_0x74d525['d']['Zero']();this['volumetricLightPostProcess']['onApply']=function(_0x3d5f57){if(_0x378624['sourceLight']&&_0x378624['sourceLight']['getShadowGenerator']()&&_0x378624['_scene']['activeCamera']){var _0x1aa6b8=_0x378624['sourceLight']['getShadowGenerator']();_0x3d5f57['setTexture']('shadowMapSampler',_0x1aa6b8['getShadowMap']()),_0x3d5f57['setTexture']('positionSampler',_0x4e60eb['textures'][0x2]),_0x3d5f57['setColor3']('sunColor',_0x378624['sourceLight']['diffuse']),_0x3d5f57['setVector3']('sunDirection',_0x378624['sourceLight']['getShadowDirection']()),_0x3d5f57['setVector3']('cameraPosition',_0x378624['_scene']['activeCamera']['globalPosition']),_0x3d5f57['setMatrix']('shadowViewProjection',_0x1aa6b8['getTransformMatrix']()),_0x3d5f57['setFloat']('scatteringCoefficient',_0x378624['volumetricLightCoefficient']),_0x3d5f57['setFloat']('scatteringPower',_0x378624['volumetricLightPower']),_0x5ee7c5['x']=_0x378624['sourceLight']['getDepthMinZ'](_0x378624['_scene']['activeCamera']),_0x5ee7c5['y']=_0x378624['sourceLight']['getDepthMaxZ'](_0x378624['_scene']['activeCamera']),_0x3d5f57['setVector2']('depthValues',_0x5ee7c5);}},this['addEffect'](new _0x1f6f7e(_0x55e983['getEngine'](),'HDRVLS',function(){return _0x378624['volumetricLightPostProcess'];},!0x0)),this['_createBlurPostProcesses'](_0x55e983,_0x166ea0/0x4,0x0,'volumetricLightBlurScale'),this['volumetricLightMergePostProces']=new _0x5cae84('HDRVLSMerge','standard',[],['originalSampler'],_0x166ea0,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x55e983['getEngine'](),!0x1,'#define\x20VLSMERGE'),this['volumetricLightMergePostProces']['onApply']=function(_0x43e645){_0x43e645['setTextureFromPostProcess']('originalSampler',_0x378624['_bloomEnabled']?_0x378624['textureAdderFinalPostProcess']:_0x378624['originalPostProcess']),_0x378624['_currentDepthOfFieldSource']=_0x378624['volumetricLightFinalPostProcess'];},this['addEffect'](new _0x1f6f7e(_0x55e983['getEngine'](),'HDRVLSMerge',function(){return _0x378624['volumetricLightMergePostProces'];},!0x0));},_0x355dbd['prototype']['_createLuminancePostProcesses']=function(_0x3a139e,_0x3e7a53){var _0x5efb96=this,_0x29ef48=Math['pow'](0x3,_0x355dbd['LuminanceSteps']);this['luminancePostProcess']=new _0x5cae84('HDRLuminance','standard',['lumOffsets'],[],{'width':_0x29ef48,'height':_0x29ef48},null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x3a139e['getEngine'](),!0x1,'#define\x20LUMINANCE',_0x3e7a53);var _0x24c39e=[];this['luminancePostProcess']['onApply']=function(_0x20e88b){var _0x4de8f5=0x1/_0x5efb96['luminancePostProcess']['width'],_0x591dbe=0x1/_0x5efb96['luminancePostProcess']['height'];_0x24c39e[0x0]=-0.5*_0x4de8f5,_0x24c39e[0x1]=0.5*_0x591dbe,_0x24c39e[0x2]=0.5*_0x4de8f5,_0x24c39e[0x3]=0.5*_0x591dbe,_0x24c39e[0x4]=-0.5*_0x4de8f5,_0x24c39e[0x5]=-0.5*_0x591dbe,_0x24c39e[0x6]=0.5*_0x4de8f5,_0x24c39e[0x7]=-0.5*_0x591dbe,_0x20e88b['setArray2']('lumOffsets',_0x24c39e);},this['addEffect'](new _0x1f6f7e(_0x3a139e['getEngine'](),'HDRLuminance',function(){return _0x5efb96['luminancePostProcess'];},!0x0));for(var _0x30c132=_0x355dbd['LuminanceSteps']-0x1;_0x30c132>=0x0;_0x30c132--){_0x29ef48=Math['pow'](0x3,_0x30c132);var _0x5c2058='#define\x20LUMINANCE_DOWN_SAMPLE\x0a';0x0===_0x30c132&&(_0x5c2058+='#define\x20FINAL_DOWN_SAMPLER');var _0x4a81a9=new _0x5cae84('HDRLuminanceDownSample'+_0x30c132,'standard',['dsOffsets','halfDestPixelSize'],[],{'width':_0x29ef48,'height':_0x29ef48},null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x3a139e['getEngine'](),!0x1,_0x5c2058,_0x3e7a53);this['luminanceDownSamplePostProcesses']['push'](_0x4a81a9);}var _0x508c6a=this['luminancePostProcess'];this['luminanceDownSamplePostProcesses']['forEach'](function(_0x5ec6e2,_0x355f61){var _0x2585de=new Array(0x12);_0x5ec6e2['onApply']=function(_0x26c407){if(_0x508c6a){for(var _0x57a194=0x0,_0x401a2b=-0x1;_0x401a2b<0x2;_0x401a2b++)for(var _0x57b12b=-0x1;_0x57b12b<0x2;_0x57b12b++)_0x2585de[_0x57a194]=_0x401a2b/_0x508c6a['width'],_0x2585de[_0x57a194+0x1]=_0x57b12b/_0x508c6a['height'],_0x57a194+=0x2;_0x26c407['setArray2']('dsOffsets',_0x2585de),_0x26c407['setFloat']('halfDestPixelSize',0.5/_0x508c6a['width']),_0x508c6a=_0x355f61===_0x5efb96['luminanceDownSamplePostProcesses']['length']-0x1?_0x5efb96['luminancePostProcess']:_0x5ec6e2;}},_0x355f61===_0x5efb96['luminanceDownSamplePostProcesses']['length']-0x1&&(_0x5ec6e2['onAfterRender']=function(){var _0x47f701=_0x3a139e['getEngine']()['readPixels'](0x0,0x0,0x1,0x1),_0x1e5060=new _0x74d525['f'](0x1/0xfd02ff,0x1/0xfe01,0x1/0xff,0x1);_0x5efb96['_hdrCurrentLuminance']=(_0x47f701[0x0]*_0x1e5060['x']+_0x47f701[0x1]*_0x1e5060['y']+_0x47f701[0x2]*_0x1e5060['z']+_0x47f701[0x3]*_0x1e5060['w'])/0x64;}),_0x5efb96['addEffect'](new _0x1f6f7e(_0x3a139e['getEngine'](),'HDRLuminanceDownSample'+_0x355f61,function(){return _0x5ec6e2;},!0x0));});},_0x355dbd['prototype']['_createHdrPostProcess']=function(_0x1799d5,_0x14088c){var _0x51c9f1=this,_0x2c2bc6=['#define\x20HDR'];this['_hdrAutoExposure']&&_0x2c2bc6['push']('#define\x20AUTO_EXPOSURE'),this['hdrPostProcess']=new _0x5cae84('HDR','standard',['averageLuminance'],['textureAdderSampler'],_0x14088c,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x1799d5['getEngine'](),!0x1,_0x2c2bc6['join']('\x0a'),_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']);var _0x163c9b=0x1,_0x2469fc=0x0,_0x5845de=0x0;this['hdrPostProcess']['onApply']=function(_0x3db51c){if(_0x3db51c['setTextureFromPostProcess']('textureAdderSampler',_0x51c9f1['_currentDepthOfFieldSource']),_0x2469fc+=_0x1799d5['getEngine']()['getDeltaTime'](),_0x163c9b<0x0)_0x163c9b=_0x51c9f1['_hdrCurrentLuminance'];else{var _0x52efdd=(_0x5845de-_0x2469fc)/0x3e8;_0x51c9f1['_hdrCurrentLuminance']<_0x163c9b+_0x51c9f1['hdrDecreaseRate']*_0x52efdd?_0x163c9b+=_0x51c9f1['hdrDecreaseRate']*_0x52efdd:_0x51c9f1['_hdrCurrentLuminance']>_0x163c9b-_0x51c9f1['hdrIncreaseRate']*_0x52efdd?_0x163c9b-=_0x51c9f1['hdrIncreaseRate']*_0x52efdd:_0x163c9b=_0x51c9f1['_hdrCurrentLuminance'];}_0x51c9f1['hdrAutoExposure']?_0x51c9f1['_currentExposure']=_0x51c9f1['_fixedExposure']/_0x163c9b:(_0x163c9b=_0x4a0cf0['a']['Clamp'](_0x163c9b,_0x51c9f1['hdrMinimumLuminance'],0x56bc75e2d63100000),_0x3db51c['setFloat']('averageLuminance',_0x163c9b)),_0x5845de=_0x2469fc,_0x51c9f1['_currentDepthOfFieldSource']=_0x51c9f1['hdrFinalPostProcess'];},this['addEffect'](new _0x1f6f7e(_0x1799d5['getEngine'](),'HDR',function(){return _0x51c9f1['hdrPostProcess'];},!0x0));},_0x355dbd['prototype']['_createLensFlarePostProcess']=function(_0x3738b1,_0x56b161){var _0x581934=this;this['lensFlarePostProcess']=new _0x5cae84('HDRLensFlare','standard',['strength','ghostDispersal','haloWidth','resolution','distortionStrength'],['lensColorSampler'],_0x56b161/0x2,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x3738b1['getEngine'](),!0x1,'#define\x20LENS_FLARE',_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),this['addEffect'](new _0x1f6f7e(_0x3738b1['getEngine'](),'HDRLensFlare',function(){return _0x581934['lensFlarePostProcess'];},!0x0)),this['_createBlurPostProcesses'](_0x3738b1,_0x56b161/0x4,0x2,'lensFlareBlurWidth'),this['lensFlareComposePostProcess']=new _0x5cae84('HDRLensFlareCompose','standard',['lensStarMatrix'],['otherSampler','lensDirtSampler','lensStarSampler'],_0x56b161,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x3738b1['getEngine'](),!0x1,'#define\x20LENS_FLARE_COMPOSE',_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),this['addEffect'](new _0x1f6f7e(_0x3738b1['getEngine'](),'HDRLensFlareCompose',function(){return _0x581934['lensFlareComposePostProcess'];},!0x0));var _0x49705c=new _0x74d525['d'](0x0,0x0);this['lensFlarePostProcess']['onApply']=function(_0xe65e76){_0xe65e76['setTextureFromPostProcess']('textureSampler',_0x581934['_bloomEnabled']?_0x581934['blurHPostProcesses'][0x0]:_0x581934['originalPostProcess']),_0xe65e76['setTexture']('lensColorSampler',_0x581934['lensColorTexture']),_0xe65e76['setFloat']('strength',_0x581934['lensFlareStrength']),_0xe65e76['setFloat']('ghostDispersal',_0x581934['lensFlareGhostDispersal']),_0xe65e76['setFloat']('haloWidth',_0x581934['lensFlareHaloWidth']),_0x49705c['x']=_0x581934['lensFlarePostProcess']['width'],_0x49705c['y']=_0x581934['lensFlarePostProcess']['height'],_0xe65e76['setVector2']('resolution',_0x49705c),_0xe65e76['setFloat']('distortionStrength',_0x581934['lensFlareDistortionStrength']);};var _0xc57a67=_0x74d525['a']['FromValues'](0x2,0x0,-0x1,0x0,0x0,0x2,-0x1,0x0,0x0,0x0,0x1,0x0,0x0,0x0,0x0,0x1),_0x5816b4=_0x74d525['a']['FromValues'](0.5,0x0,0.5,0x0,0x0,0.5,0.5,0x0,0x0,0x0,0x1,0x0,0x0,0x0,0x0,0x1);this['lensFlareComposePostProcess']['onApply']=function(_0x3443bd){if(_0x581934['_scene']['activeCamera']){_0x3443bd['setTextureFromPostProcess']('otherSampler',_0x581934['lensFlarePostProcess']),_0x3443bd['setTexture']('lensDirtSampler',_0x581934['lensFlareDirtTexture']),_0x3443bd['setTexture']('lensStarSampler',_0x581934['lensStarTexture']);var _0x3790e6=_0x581934['_scene']['activeCamera']['getViewMatrix']()['getRow'](0x0),_0x2f7c36=_0x581934['_scene']['activeCamera']['getViewMatrix']()['getRow'](0x2),_0x49175f=_0x74d525['e']['Dot'](_0x3790e6['toVector3'](),new _0x74d525['e'](0x1,0x0,0x0))+_0x74d525['e']['Dot'](_0x2f7c36['toVector3'](),new _0x74d525['e'](0x0,0x0,0x1));_0x49175f*=0x4;var _0x352a94=_0x74d525['a']['FromValues'](0.5*Math['cos'](_0x49175f),-Math['sin'](_0x49175f),0x0,0x0,Math['sin'](_0x49175f),0.5*Math['cos'](_0x49175f),0x0,0x0,0x0,0x0,0x1,0x0,0x0,0x0,0x0,0x1),_0x32966d=_0x5816b4['multiply'](_0x352a94)['multiply'](_0xc57a67);_0x3443bd['setMatrix']('lensStarMatrix',_0x32966d),_0x581934['_currentDepthOfFieldSource']=_0x581934['lensFlareFinalPostProcess'];}};},_0x355dbd['prototype']['_createDepthOfFieldPostProcess']=function(_0x2f6074,_0x248564){var _0x21045e=this;this['depthOfFieldPostProcess']=new _0x5cae84('HDRDepthOfField','standard',['distance'],['otherSampler','depthSampler'],_0x248564,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x2f6074['getEngine'](),!0x1,'#define\x20DEPTH_OF_FIELD',_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),this['depthOfFieldPostProcess']['onApply']=function(_0x2667de){_0x2667de['setTextureFromPostProcess']('otherSampler',_0x21045e['_currentDepthOfFieldSource']),_0x2667de['setTexture']('depthSampler',_0x21045e['_getDepthTexture']()),_0x2667de['setFloat']('distance',_0x21045e['depthOfFieldDistance']);},this['addEffect'](new _0x1f6f7e(_0x2f6074['getEngine'](),'HDRDepthOfField',function(){return _0x21045e['depthOfFieldPostProcess'];},!0x0));},_0x355dbd['prototype']['_createMotionBlurPostProcess']=function(_0x54cfbe,_0x1a7a55){var _0x441d97=this;if(this['_isObjectBasedMotionBlur']){var _0x470f73=new _0x8933c4('HDRMotionBlur',_0x54cfbe,_0x1a7a55,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x54cfbe['getEngine'](),!0x1,_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']);_0x470f73['motionStrength']=this['motionStrength'],_0x470f73['motionBlurSamples']=this['motionBlurSamples'],this['motionBlurPostProcess']=_0x470f73;}else{this['motionBlurPostProcess']=new _0x5cae84('HDRMotionBlur','standard',['inverseViewProjection','prevViewProjection','screenSize','motionScale','motionStrength'],['depthSampler'],_0x1a7a55,null,_0xaf3c80['a']['BILINEAR_SAMPLINGMODE'],_0x54cfbe['getEngine'](),!0x1,'#define\x20MOTION_BLUR\x0a#define\x20MAX_MOTION_SAMPLES\x20'+this['motionBlurSamples']['toFixed'](0x1),_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']);var _0x22935b=0x0,_0x4cd2d2=_0x74d525['a']['Identity'](),_0x4426c5=_0x74d525['a']['Identity'](),_0x4cf374=_0x74d525['a']['Identity'](),_0x1df925=_0x74d525['d']['Zero']();this['motionBlurPostProcess']['onApply']=function(_0x11ba07){(_0x4cf374=_0x54cfbe['getProjectionMatrix']()['multiply'](_0x54cfbe['getViewMatrix']()))['invertToRef'](_0x4426c5),_0x11ba07['setMatrix']('inverseViewProjection',_0x4426c5),_0x11ba07['setMatrix']('prevViewProjection',_0x4cd2d2),_0x4cd2d2=_0x4cf374,_0x1df925['x']=_0x441d97['motionBlurPostProcess']['width'],_0x1df925['y']=_0x441d97['motionBlurPostProcess']['height'],_0x11ba07['setVector2']('screenSize',_0x1df925),_0x22935b=_0x54cfbe['getEngine']()['getFps']()/0x3c,_0x11ba07['setFloat']('motionScale',_0x22935b),_0x11ba07['setFloat']('motionStrength',_0x441d97['motionStrength']),_0x11ba07['setTexture']('depthSampler',_0x441d97['_getDepthTexture']());};}this['addEffect'](new _0x1f6f7e(_0x54cfbe['getEngine'](),'HDRMotionBlur',function(){return _0x441d97['motionBlurPostProcess'];},!0x0));},_0x355dbd['prototype']['_getDepthTexture']=function(){return this['_scene']['getEngine']()['getCaps']()['drawBuffersExtension']?this['_scene']['enableGeometryBufferRenderer']()['getGBuffer']()['textures'][0x0]:this['_scene']['enableDepthRenderer']()['getDepthMap']();},_0x355dbd['prototype']['_disposePostProcesses']=function(){for(var _0x327070=0x0;_0x3270700x0&&-0x1!==this['excludedMeshes']['indexOf'](_0x430004);},_0x4e53e6['prototype']['_createPass']=function(_0xc1c70,_0x24324d){var _0x21eaf5=this,_0x49b28=_0xc1c70['getEngine']();this['_volumetricLightScatteringRTT']=new _0x310f87('volumetricLightScatteringMap',{'width':_0x49b28['getRenderWidth']()*_0x24324d,'height':_0x49b28['getRenderHeight']()*_0x24324d},_0xc1c70,!0x1,!0x0,_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),this['_volumetricLightScatteringRTT']['wrapU']=_0xaf3c80['a']['CLAMP_ADDRESSMODE'],this['_volumetricLightScatteringRTT']['wrapV']=_0xaf3c80['a']['CLAMP_ADDRESSMODE'],this['_volumetricLightScatteringRTT']['renderList']=null,this['_volumetricLightScatteringRTT']['renderParticles']=!0x1,this['_volumetricLightScatteringRTT']['ignoreCameraViewport']=!0x0;var _0x3a3a6f=this['getCamera']();_0x3a3a6f?_0x3a3a6f['customRenderTargets']['push'](this['_volumetricLightScatteringRTT']):_0xc1c70['customRenderTargets']['push'](this['_volumetricLightScatteringRTT']);var _0x18dd31,_0x4633ce=function(_0x263ce5){var _0x329814=_0x263ce5['getRenderingMesh'](),_0x507006=_0x263ce5['getEffectiveMesh']();if(!_0x21eaf5['_meshExcluded'](_0x329814)){_0x507006['_internalAbstractMeshDataInfo']['_isActiveIntermediate']=!0x1;var _0x39fd5a=_0x263ce5['getMaterial']();if(_0x39fd5a){var _0xa99c83=_0x329814['getScene'](),_0x3edaa3=_0xa99c83['getEngine']();_0x3edaa3['setState'](_0x39fd5a['backFaceCulling']);var _0xd9fdd=_0x329814['_getInstancesRenderList'](_0x263ce5['_id'],!!_0x263ce5['getReplacementMesh']());if(!_0xd9fdd['mustReturn']){var _0x242e75=_0x3edaa3['getCaps']()['instancedArrays']&&(null!==_0xd9fdd['visibleInstances'][_0x263ce5['_id']]||_0x329814['hasThinInstances']);if(_0x21eaf5['_isReady'](_0x263ce5,_0x242e75)){var _0x326bbb=_0x21eaf5['_volumetricLightScatteringPass'];if(_0x329814===_0x21eaf5['mesh']&&(_0x326bbb=_0x263ce5['effect']?_0x263ce5['effect']:_0x39fd5a['getEffect']()),_0x3edaa3['enableEffect'](_0x326bbb),_0x329814['_bind'](_0x263ce5,_0x326bbb,_0x39fd5a['fillMode']),_0x329814===_0x21eaf5['mesh'])_0x39fd5a['bind'](_0x507006['getWorldMatrix'](),_0x329814);else{if(_0x21eaf5['_volumetricLightScatteringPass']['setMatrix']('viewProjection',_0xa99c83['getTransformMatrix']()),_0x39fd5a&&_0x39fd5a['needAlphaTesting']()){var _0x2514cb=_0x39fd5a['getAlphaTestTexture']();_0x21eaf5['_volumetricLightScatteringPass']['setTexture']('diffuseSampler',_0x2514cb),_0x2514cb&&_0x21eaf5['_volumetricLightScatteringPass']['setMatrix']('diffuseMatrix',_0x2514cb['getTextureMatrix']());}_0x329814['useBones']&&_0x329814['computeBonesUsingShaders']&&_0x329814['skeleton']&&_0x21eaf5['_volumetricLightScatteringPass']['setMatrices']('mBones',_0x329814['skeleton']['getTransformMatrices'](_0x329814));}_0x329814['_processRendering'](_0x507006,_0x263ce5,_0x21eaf5['_volumetricLightScatteringPass'],_0x33c2e5['a']['TriangleFillMode'],_0xd9fdd,_0x242e75,function(_0x54f5bc,_0x161460){return _0x326bbb['setMatrix']('world',_0x161460);});}}}}},_0x1e4455=new _0x39310d['b'](0x0,0x0,0x0,0x1);this['_volumetricLightScatteringRTT']['onBeforeRenderObservable']['add'](function(){_0x18dd31=_0xc1c70['clearColor'],_0xc1c70['clearColor']=_0x1e4455;}),this['_volumetricLightScatteringRTT']['onAfterRenderObservable']['add'](function(){_0xc1c70['clearColor']=_0x18dd31;}),this['_volumetricLightScatteringRTT']['customRenderFunction']=function(_0x48be3c,_0x41bcd6,_0x416b7b,_0x2d1259){var _0x518ea7,_0xabdbc0=_0xc1c70['getEngine']();if(_0x2d1259['length']){for(_0xabdbc0['setColorWrite'](!0x1),_0x518ea7=0x0;_0x518ea7<_0x2d1259['length'];_0x518ea7++)_0x4633ce(_0x2d1259['data'][_0x518ea7]);_0xabdbc0['setColorWrite'](!0x0);}for(_0x518ea7=0x0;_0x518ea7<_0x48be3c['length'];_0x518ea7++)_0x4633ce(_0x48be3c['data'][_0x518ea7]);for(_0x518ea7=0x0;_0x518ea7<_0x41bcd6['length'];_0x518ea7++)_0x4633ce(_0x41bcd6['data'][_0x518ea7]);if(_0x416b7b['length']){for(_0x518ea7=0x0;_0x518ea7<_0x416b7b['length'];_0x518ea7++){var _0x567558=_0x416b7b['data'][_0x518ea7],_0x54c823=_0x567558['getBoundingInfo']();_0x54c823&&_0xc1c70['activeCamera']&&(_0x567558['_alphaIndex']=_0x567558['getMesh']()['alphaIndex'],_0x567558['_distanceToCamera']=_0x54c823['boundingSphere']['centerWorld']['subtract'](_0xc1c70['activeCamera']['position'])['length']());}var _0x5ed459=_0x416b7b['data']['slice'](0x0,_0x416b7b['length']);for(_0x5ed459['sort'](function(_0x3c8088,_0x5b7e66){return _0x3c8088['_alphaIndex']>_0x5b7e66['_alphaIndex']?0x1:_0x3c8088['_alphaIndex']<_0x5b7e66['_alphaIndex']?-0x1:_0x3c8088['_distanceToCamera']<_0x5b7e66['_distanceToCamera']?0x1:_0x3c8088['_distanceToCamera']>_0x5b7e66['_distanceToCamera']?-0x1:0x0;}),_0xabdbc0['setAlphaMode'](_0x2103ba['a']['ALPHA_COMBINE']),_0x518ea7=0x0;_0x518ea7<_0x5ed459['length'];_0x518ea7++)_0x4633ce(_0x5ed459[_0x518ea7]);_0xabdbc0['setAlphaMode'](_0x2103ba['a']['ALPHA_DISABLE']);}};},_0x4e53e6['prototype']['_updateMeshScreenCoordinates']=function(_0x23e8d6){var _0x532243,_0x411760=_0x23e8d6['getTransformMatrix']();_0x532243=this['useCustomMeshPosition']?this['customMeshPosition']:this['attachedNode']?this['attachedNode']['position']:this['mesh']['parent']?this['mesh']['getAbsolutePosition']():this['mesh']['position'];var _0x4aa751=_0x74d525['e']['Project'](_0x532243,_0x74d525['a']['Identity'](),_0x411760,this['_viewPort']);this['_screenCoordinates']['x']=_0x4aa751['x']/this['_viewPort']['width'],this['_screenCoordinates']['y']=_0x4aa751['y']/this['_viewPort']['height'],this['invert']&&(this['_screenCoordinates']['y']=0x1-this['_screenCoordinates']['y']);},_0x4e53e6['CreateDefaultMesh']=function(_0x404720,_0x12282d){var _0x43e1b8=_0x3cf5e5['a']['CreatePlane'](_0x404720,0x1,_0x12282d);_0x43e1b8['billboardMode']=_0x40d22e['a']['BILLBOARDMODE_ALL'];var _0x2da72f=new _0x5905ab['a'](_0x404720+'Material',_0x12282d);return _0x2da72f['emissiveColor']=new _0x39310d['a'](0x1,0x1,0x1),_0x43e1b8['material']=_0x2da72f,_0x43e1b8;},Object(_0x18e13d['c'])([Object(_0x495d06['o'])()],_0x4e53e6['prototype'],'customMeshPosition',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x4e53e6['prototype'],'useCustomMeshPosition',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x4e53e6['prototype'],'invert',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['k'])()],_0x4e53e6['prototype'],'mesh',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x4e53e6['prototype'],'excludedMeshes',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x4e53e6['prototype'],'exposure',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x4e53e6['prototype'],'decay',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x4e53e6['prototype'],'weight',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x4e53e6['prototype'],'density',void 0x0),_0x4e53e6;}(_0x5cae84);_0x3cd573['a']['RegisteredTypes']['BABYLON.VolumetricLightScatteringPostProcess']=_0x318209;var _0x44bcc2='\x0a\x0aprecision\x20highp\x20float;\x0a\x0avarying\x20vec2\x20vUV;\x0auniform\x20sampler2D\x20textureSampler;\x0auniform\x20sampler2D\x20normalSampler;\x0auniform\x20float\x20curvature_ridge;\x0auniform\x20float\x20curvature_valley;\x0a#ifndef\x20CURVATURE_OFFSET\x0a#define\x20CURVATURE_OFFSET\x201\x0a#endif\x0afloat\x20curvature_soft_clamp(float\x20curvature,float\x20control)\x0a{\x0aif\x20(curvature<0.5/control)\x0areturn\x20curvature*(1.0-curvature*control);\x0areturn\x200.25/control;\x0a}\x0afloat\x20calculate_curvature(ivec2\x20texel,float\x20ridge,float\x20valley)\x0a{\x0avec2\x20normal_up=texelFetchOffset(normalSampler,texel,0,ivec2(0,CURVATURE_OFFSET)).rb;\x0avec2\x20normal_down=texelFetchOffset(normalSampler,texel,0,ivec2(0,-CURVATURE_OFFSET)).rb;\x0avec2\x20normal_left=texelFetchOffset(normalSampler,texel,0,ivec2(-CURVATURE_OFFSET,0)).rb;\x0avec2\x20normal_right=texelFetchOffset(normalSampler,texel,0,ivec2(\x20CURVATURE_OFFSET,0)).rb;\x0afloat\x20normal_diff=((normal_up.g-normal_down.g)+(normal_right.r-normal_left.r));\x0aif\x20(normal_diff<0.0)\x0areturn\x20-2.0*curvature_soft_clamp(-normal_diff,valley);\x0areturn\x202.0*curvature_soft_clamp(normal_diff,ridge);\x0a}\x0avoid\x20main(void)\x0a{\x0aivec2\x20texel=ivec2(gl_FragCoord.xy);\x0avec4\x20baseColor=texture2D(textureSampler,vUV);\x0afloat\x20curvature=calculate_curvature(texel,curvature_ridge,curvature_valley);\x0abaseColor.rgb*=curvature+1.0;\x0agl_FragColor=baseColor;\x0a}';_0x494b01['a']['ShadersStore']['screenSpaceCurvaturePixelShader']=_0x44bcc2;var _0x25052b=function(_0x27427c){function _0x1f2f04(_0x14414e,_0x307922,_0x56a1cf,_0x20f2b7,_0x186ec2,_0x42e3d2,_0x230cbf,_0x43cd51,_0x257cdf){void 0x0===_0x43cd51&&(_0x43cd51=_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']),void 0x0===_0x257cdf&&(_0x257cdf=!0x1);var _0x3d5811=_0x27427c['call'](this,_0x14414e,'screenSpaceCurvature',['curvature_ridge','curvature_valley'],['textureSampler','normalSampler'],_0x56a1cf,_0x20f2b7,_0x186ec2,_0x42e3d2,_0x230cbf,void 0x0,_0x43cd51,void 0x0,null,_0x257cdf)||this;return _0x3d5811['ridge']=0x1,_0x3d5811['valley']=0x1,_0x3d5811['_geometryBufferRenderer']=_0x307922['enableGeometryBufferRenderer'](),_0x3d5811['_geometryBufferRenderer']?_0x3d5811['onApply']=function(_0x458fe5){_0x458fe5['setFloat']('curvature_ridge',0.5/Math['max'](_0x3d5811['ridge']*_0x3d5811['ridge'],0.0001)),_0x458fe5['setFloat']('curvature_valley',0.7/Math['max'](_0x3d5811['valley']*_0x3d5811['valley'],0.0001));var _0x130b07=_0x3d5811['_geometryBufferRenderer']['getGBuffer']()['textures'][0x1];_0x458fe5['setTexture']('normalSampler',_0x130b07);}:_0x75193d['a']['Error']('Multiple\x20Render\x20Target\x20support\x20needed\x20for\x20screen\x20space\x20curvature\x20post\x20process.\x20Please\x20use\x20IsSupported\x20test\x20first.'),_0x3d5811;}return Object(_0x18e13d['d'])(_0x1f2f04,_0x27427c),_0x1f2f04['prototype']['getClassName']=function(){return'ScreenSpaceCurvaturePostProcess';},Object['defineProperty'](_0x1f2f04,'IsSupported',{'get':function(){var _0x55e066=_0x44b9ce['a']['LastCreatedEngine'];return!!_0x55e066&&(_0x55e066['webGLVersion']>0x1||_0x55e066['getCaps']()['drawBuffersExtension']);},'enumerable':!0x1,'configurable':!0x0}),_0x1f2f04['_Parse']=function(_0x3e9ed9,_0x52a9dc,_0x3dcc8b,_0x513cc0){return _0x495d06['a']['Parse'](function(){return new _0x1f2f04(_0x3e9ed9['name'],_0x3dcc8b,_0x3e9ed9['options'],_0x52a9dc,_0x3e9ed9['renderTargetSamplingMode'],_0x3dcc8b['getEngine'](),_0x3e9ed9['textureType'],_0x3e9ed9['reusable']);},_0x3e9ed9,_0x3dcc8b,_0x513cc0);},Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x1f2f04['prototype'],'ridge',void 0x0),Object(_0x18e13d['c'])([Object(_0x495d06['c'])()],_0x1f2f04['prototype'],'valley',void 0x0),_0x1f2f04;}(_0x5cae84);_0x3cd573['a']['RegisteredTypes']['BABYLON.ScreenSpaceCurvaturePostProcess']=_0x25052b,(_0x162675(0xa6),_0x162675(0xa7)),(Object['defineProperty'](_0x59370b['a']['prototype'],'forceShowBoundingBoxes',{'get':function(){return this['_forceShowBoundingBoxes']||!0x1;},'set':function(_0x5227f5){this['_forceShowBoundingBoxes']=_0x5227f5,_0x5227f5&&this['getBoundingBoxRenderer']();},'enumerable':!0x0,'configurable':!0x0}),_0x59370b['a']['prototype']['getBoundingBoxRenderer']=function(){return this['_boundingBoxRenderer']||(this['_boundingBoxRenderer']=new _0x2c8e40(this)),this['_boundingBoxRenderer'];},Object['defineProperty'](_0x40d22e['a']['prototype'],'showBoundingBox',{'get':function(){return this['_showBoundingBox']||!0x1;},'set':function(_0x498983){this['_showBoundingBox']=_0x498983,_0x498983&&this['getScene']()['getBoundingBoxRenderer']();},'enumerable':!0x0,'configurable':!0x0}));var _0x2c8e40=(function(){function _0x5149bc(_0x42c7b8){this['name']=_0x384de3['a']['NAME_BOUNDINGBOXRENDERER'],this['frontColor']=new _0x39310d['a'](0x1,0x1,0x1),this['backColor']=new _0x39310d['a'](0.1,0.1,0.1),this['showBackLines']=!0x0,this['onBeforeBoxRenderingObservable']=new _0x6ac1f7['c'](),this['onAfterBoxRenderingObservable']=new _0x6ac1f7['c'](),this['onResourcesReadyObservable']=new _0x6ac1f7['c'](),this['enabled']=!0x0,this['renderList']=new _0x2266f9['a'](0x20),this['_vertexBuffers']={},this['_fillIndexBuffer']=null,this['_fillIndexData']=null,this['scene']=_0x42c7b8,_0x42c7b8['_addComponent'](this);}return _0x5149bc['prototype']['register']=function(){this['scene']['_beforeEvaluateActiveMeshStage']['registerStep'](_0x384de3['a']['STEP_BEFOREEVALUATEACTIVEMESH_BOUNDINGBOXRENDERER'],this,this['reset']),this['scene']['_preActiveMeshStage']['registerStep'](_0x384de3['a']['STEP_PREACTIVEMESH_BOUNDINGBOXRENDERER'],this,this['_preActiveMesh']),this['scene']['_evaluateSubMeshStage']['registerStep'](_0x384de3['a']['STEP_EVALUATESUBMESH_BOUNDINGBOXRENDERER'],this,this['_evaluateSubMesh']),this['scene']['_afterRenderingGroupDrawStage']['registerStep'](_0x384de3['a']['STEP_AFTERRENDERINGGROUPDRAW_BOUNDINGBOXRENDERER'],this,this['render']);},_0x5149bc['prototype']['_evaluateSubMesh']=function(_0x18d403,_0x1dd0e8){if(_0x18d403['showSubMeshesBoundingBox']){var _0x249e78=_0x1dd0e8['getBoundingInfo']();null!=_0x249e78&&(_0x249e78['boundingBox']['_tag']=_0x18d403['renderingGroupId'],this['renderList']['push'](_0x249e78['boundingBox']));}},_0x5149bc['prototype']['_preActiveMesh']=function(_0x2422b5){if(_0x2422b5['showBoundingBox']||this['scene']['forceShowBoundingBoxes']){var _0x442481=_0x2422b5['getBoundingInfo']();_0x442481['boundingBox']['_tag']=_0x2422b5['renderingGroupId'],this['renderList']['push'](_0x442481['boundingBox']);}},_0x5149bc['prototype']['_prepareResources']=function(){if(!this['_colorShader']){this['_colorShader']=new _0x14ee07['a']('colorShader',this['scene'],'color',{'attributes':[_0x212fbd['b']['PositionKind']],'uniforms':['world','viewProjection','color']}),this['_colorShader']['reservedDataStore']={'hidden':!0x0};var _0x57e3cd=this['scene']['getEngine'](),_0x28dc11=_0xa18063['a']['CreateBox']({'size':0x1});this['_vertexBuffers'][_0x212fbd['b']['PositionKind']]=new _0x212fbd['b'](_0x57e3cd,_0x28dc11['positions'],_0x212fbd['b']['PositionKind'],!0x1),this['_createIndexBuffer'](),this['_fillIndexData']=_0x28dc11['indices'],this['onResourcesReadyObservable']['notifyObservers'](this);}},_0x5149bc['prototype']['_createIndexBuffer']=function(){var _0x2d7d32=this['scene']['getEngine']();this['_indexBuffer']=_0x2d7d32['createIndexBuffer']([0x0,0x1,0x1,0x2,0x2,0x3,0x3,0x0,0x4,0x5,0x5,0x6,0x6,0x7,0x7,0x4,0x0,0x7,0x1,0x6,0x2,0x5,0x3,0x4]);},_0x5149bc['prototype']['rebuild']=function(){var _0x59e263=this['_vertexBuffers'][_0x212fbd['b']['PositionKind']];_0x59e263&&_0x59e263['_rebuild'](),this['_createIndexBuffer']();},_0x5149bc['prototype']['reset']=function(){this['renderList']['reset']();},_0x5149bc['prototype']['render']=function(_0x321abd){if(0x0!==this['renderList']['length']&&this['enabled']&&(this['_prepareResources'](),this['_colorShader']['isReady']())){var _0x5388b7=this['scene']['getEngine']();_0x5388b7['setDepthWrite'](!0x1),this['_colorShader']['_preBind']();for(var _0x48ae04=0x0;_0x48ae04=0x0&&_0x1465ac['push'](_0xebd781);for(var _0x17f3ab=0x0;_0x17f3ab<_0x5d6e69['length'];++_0x17f3ab)_0x1465ac['push'](_0x5d6e69[_0x17f3ab][0x0]);},_0x64ede6=0x0;_0x94e86d[0x1]['length']>=_0x94e86d[0x0]['length']&&_0x94e86d[0x1]['length']>=_0x94e86d[0x2]['length']?_0x64ede6=0x1:_0x94e86d[0x2]['length']>=_0x94e86d[0x0]['length']&&_0x94e86d[0x2]['length']>=_0x94e86d[0x1]['length']&&(_0x64ede6=0x2);for(var _0x93d543=0x0;_0x93d543<0x3;++_0x93d543)_0x93d543===_0x64ede6?_0x94e86d[_0x93d543]['sort'](function(_0x452c85,_0x369fc0){return _0x452c85[0x1]<_0x369fc0[0x1]?-0x1:_0x452c85[0x1]>_0x369fc0[0x1]?0x1:0x0;}):_0x94e86d[_0x93d543]['sort'](function(_0x544253,_0x4f79b8){return _0x544253[0x1]>_0x4f79b8[0x1]?-0x1:_0x544253[0x1]<_0x4f79b8[0x1]?0x1:0x0;});var _0x3ffa42=[],_0x30a34c=[];_0x4307f5(_0x94e86d[_0x64ede6],_0x3ffa42,-0x1);for(var _0x316cb4=_0x3ffa42['length'],_0x144f4a=_0x64ede6+0x2;_0x144f4a>=_0x64ede6+0x1;--_0x144f4a)_0x4307f5(_0x94e86d[_0x144f4a%0x3],_0x30a34c,_0x144f4a!==_0x64ede6+0x2?_0xaefff2[_0xbde644[_0x12278e+(_0x144f4a+0x1)%0x3]]:-0x1);var _0x7ebd73=_0x30a34c['length'];_0xbde644['push'](_0xaefff2[_0xbde644[_0x12278e+_0x64ede6]],_0x3ffa42[0x0],_0x30a34c[0x0]),_0xbde644['push'](_0xaefff2[_0xbde644[_0x12278e+(_0x64ede6+0x1)%0x3]],_0x30a34c[_0x7ebd73-0x1],_0x3ffa42[_0x316cb4-0x1]);for(var _0xdbc956=_0x316cb4<=_0x7ebd73,_0x13f582=_0xdbc956?_0x316cb4:_0x7ebd73,_0x5bb722=_0xdbc956?_0x7ebd73:_0x316cb4,_0xbd5df6=_0xdbc956?_0x316cb4-0x1:_0x7ebd73-0x1,_0x556789=_0xdbc956?0x0:0x1,_0x20dd28=_0x316cb4+_0x7ebd73-0x2,_0x4a8a9e=0x0,_0xafa6b6=0x0,_0x1323b2=_0xdbc956?_0x3ffa42:_0x30a34c,_0x477bd6=_0xdbc956?_0x30a34c:_0x3ffa42,_0x1eba53=0x0;_0x20dd28-->0x0;){_0x556789?_0xbde644['push'](_0x1323b2[_0x4a8a9e],_0x477bd6[_0xafa6b6]):_0xbde644['push'](_0x477bd6[_0xafa6b6],_0x1323b2[_0x4a8a9e]);var _0x4381e4=void 0x0;(_0x1eba53+=_0x13f582)>=_0x5bb722&&_0x4a8a9e<_0xbd5df6?(_0x4381e4=_0x1323b2[++_0x4a8a9e],_0x1eba53-=_0x5bb722):_0x4381e4=_0x477bd6[++_0xafa6b6],_0xbde644['push'](_0x4381e4);}_0xbde644[_0x12278e+0x0]=_0xbde644[_0xbde644['length']-0x3],_0xbde644[_0x12278e+0x1]=_0xbde644[_0xbde644['length']-0x2],_0xbde644[_0x12278e+0x2]=_0xbde644[_0xbde644['length']-0x1],_0xbde644['length']=_0xbde644['length']-0x3;},_0x338b20['prototype']['_generateEdgesLinesAlternate']=function(){var _0x2e8f6f,_0x34de82,_0x4d062e,_0x3ec748,_0x227c60,_0x8cd02a,_0x1afc9f,_0x3aadae,_0x3331b1,_0x17b834=this['_source']['getVerticesData'](_0x212fbd['b']['PositionKind']),_0x5177cf=this['_source']['getIndices']();if(_0x5177cf&&_0x17b834){Array['isArray'](_0x5177cf)||(_0x5177cf=_0x5d754c['b']['SliceToArray'](_0x5177cf));var _0x49d094=null===(_0x34de82=null===(_0x2e8f6f=this['_options'])||void 0x0===_0x2e8f6f?void 0x0:_0x2e8f6f['useFastVertexMerger'])||void 0x0===_0x34de82||_0x34de82,_0x29c8ea=_0x49d094?Math['round'](-Math['log'](null!==(_0x3ec748=null===(_0x4d062e=this['_options'])||void 0x0===_0x4d062e?void 0x0:_0x4d062e['epsilonVertexMerge'])&&void 0x0!==_0x3ec748?_0x3ec748:0.000001)/Math['log'](0xa)):null!==(_0x8cd02a=null===(_0x227c60=this['_options'])||void 0x0===_0x227c60?void 0x0:_0x227c60['epsilonVertexMerge'])&&void 0x0!==_0x8cd02a?_0x8cd02a:0.000001,_0x40473a=[],_0x4472a0=[];if(_0x49d094)for(var _0x375b9d={},_0x127bea=0x0;_0x127bea<_0x17b834['length'];_0x127bea+=0x3){var _0x21bf9b=_0x17b834[_0x127bea+0x0],_0x2811da=_0x17b834[_0x127bea+0x1],_0x1b93af=_0x17b834[_0x127bea+0x2];if(void 0x0!==_0x375b9d[_0x1187a2=_0x21bf9b['toFixed'](_0x29c8ea)+'|'+_0x2811da['toFixed'](_0x29c8ea)+'|'+_0x1b93af['toFixed'](_0x29c8ea)])_0x40473a['push'](_0x375b9d[_0x1187a2]);else{var _0x2ed2f8=_0x127bea/0x3;_0x375b9d[_0x1187a2]=_0x2ed2f8,_0x40473a['push'](_0x2ed2f8),_0x4472a0['push'](_0x2ed2f8);}}else for(_0x127bea=0x0;_0x127bea<_0x17b834['length'];_0x127bea+=0x3){_0x21bf9b=_0x17b834[_0x127bea+0x0],_0x2811da=_0x17b834[_0x127bea+0x1],_0x1b93af=_0x17b834[_0x127bea+0x2];for(var _0x42a70a=!0x1,_0x297362=0x0;_0x297362<_0x127bea&&!_0x42a70a;_0x297362+=0x3){var _0x280d47=_0x17b834[_0x297362+0x0],_0x6434fe=_0x17b834[_0x297362+0x1],_0x58ce6c=_0x17b834[_0x297362+0x2];if(Math['abs'](_0x21bf9b-_0x280d47)<_0x29c8ea&&Math['abs'](_0x2811da-_0x6434fe)<_0x29c8ea&&Math['abs'](_0x1b93af-_0x58ce6c)<_0x29c8ea){_0x40473a['push'](_0x297362/0x3),_0x42a70a=!0x0;break;}}_0x42a70a||(_0x40473a['push'](_0x127bea/0x3),_0x4472a0['push'](_0x127bea/0x3));}if(null===(_0x1afc9f=this['_options'])||void 0x0===_0x1afc9f?void 0x0:_0x1afc9f['applyTessellation']){for(var _0x3db0c3=null!==(_0x3331b1=null===(_0x3aadae=this['_options'])||void 0x0===_0x3aadae?void 0x0:_0x3aadae['epsilonVertexAligned'])&&void 0x0!==_0x3331b1?_0x3331b1:0.000001,_0x459217=[],_0x3447ec=0x0;_0x3447ec<_0x5177cf['length'];_0x3447ec+=0x3)for(var _0x3b31e7=void 0x0,_0x24fb35=0x0;_0x24fb35<0x3;++_0x24fb35){var _0x3a6ed1=_0x40473a[_0x5177cf[_0x3447ec+_0x24fb35]],_0x2db48d=_0x40473a[_0x5177cf[_0x3447ec+(_0x24fb35+0x1)%0x3]],_0x370e9b=_0x40473a[_0x5177cf[_0x3447ec+(_0x24fb35+0x2)%0x3]];if(_0x3a6ed1!==_0x2db48d)for(var _0x1f1330=_0x17b834[0x3*_0x3a6ed1+0x0],_0x5ec46c=_0x17b834[0x3*_0x3a6ed1+0x1],_0x36aa65=_0x17b834[0x3*_0x3a6ed1+0x2],_0x1e7e7b=_0x17b834[0x3*_0x2db48d+0x0],_0x54584d=_0x17b834[0x3*_0x2db48d+0x1],_0x17711e=_0x17b834[0x3*_0x2db48d+0x2],_0x388611=Math['sqrt']((_0x1e7e7b-_0x1f1330)*(_0x1e7e7b-_0x1f1330)+(_0x54584d-_0x5ec46c)*(_0x54584d-_0x5ec46c)+(_0x17711e-_0x36aa65)*(_0x17711e-_0x36aa65)),_0x588592=0x0;_0x588592<_0x4472a0['length']-0x1;_0x588592++){var _0x5c8868=_0x4472a0[_0x588592];if(_0x5c8868!==_0x3a6ed1&&_0x5c8868!==_0x2db48d&&_0x5c8868!==_0x370e9b){var _0x318fe5=_0x17b834[0x3*_0x5c8868+0x0],_0x4d6b45=_0x17b834[0x3*_0x5c8868+0x1],_0x5570f3=_0x17b834[0x3*_0x5c8868+0x2],_0x168027=Math['sqrt']((_0x318fe5-_0x1f1330)*(_0x318fe5-_0x1f1330)+(_0x4d6b45-_0x5ec46c)*(_0x4d6b45-_0x5ec46c)+(_0x5570f3-_0x36aa65)*(_0x5570f3-_0x36aa65)),_0x3a5b27=Math['sqrt']((_0x318fe5-_0x1e7e7b)*(_0x318fe5-_0x1e7e7b)+(_0x4d6b45-_0x54584d)*(_0x4d6b45-_0x54584d)+(_0x5570f3-_0x17711e)*(_0x5570f3-_0x17711e));Math['abs'](_0x168027+_0x3a5b27-_0x388611)<_0x3db0c3&&(_0x3b31e7||(_0x3b31e7={'index':_0x3447ec,'edgesPoints':[[],[],[]]},_0x459217['push'](_0x3b31e7)),_0x3b31e7['edgesPoints'][_0x24fb35]['push']([_0x5c8868,_0x168027]));}}}for(var _0x453cd0=0x0;_0x453cd0<_0x459217['length'];++_0x453cd0){var _0x345aa8=_0x459217[_0x453cd0];this['_tessellateTriangle'](_0x345aa8['edgesPoints'],_0x345aa8['index'],_0x5177cf,_0x40473a);}_0x459217=null;}var _0x5b03d8={};for(_0x3447ec=0x0;_0x3447ec<_0x5177cf['length'];_0x3447ec+=0x3){var _0xb2ed1c=void 0x0;for(_0x24fb35=0x0;_0x24fb35<0x3;++_0x24fb35){_0x3a6ed1=_0x40473a[_0x5177cf[_0x3447ec+_0x24fb35]],_0x2db48d=_0x40473a[_0x5177cf[_0x3447ec+(_0x24fb35+0x1)%0x3]],_0x370e9b=_0x40473a[_0x5177cf[_0x3447ec+(_0x24fb35+0x2)%0x3]];if(_0x3a6ed1!==_0x2db48d){if(_0x74d525['c']['Vector3'][0x0]['copyFromFloats'](_0x17b834[0x3*_0x3a6ed1+0x0],_0x17b834[0x3*_0x3a6ed1+0x1],_0x17b834[0x3*_0x3a6ed1+0x2]),_0x74d525['c']['Vector3'][0x1]['copyFromFloats'](_0x17b834[0x3*_0x2db48d+0x0],_0x17b834[0x3*_0x2db48d+0x1],_0x17b834[0x3*_0x2db48d+0x2]),_0x74d525['c']['Vector3'][0x2]['copyFromFloats'](_0x17b834[0x3*_0x370e9b+0x0],_0x17b834[0x3*_0x370e9b+0x1],_0x17b834[0x3*_0x370e9b+0x2]),_0xb2ed1c||(_0x74d525['c']['Vector3'][0x1]['subtractToRef'](_0x74d525['c']['Vector3'][0x0],_0x74d525['c']['Vector3'][0x3]),_0x74d525['c']['Vector3'][0x2]['subtractToRef'](_0x74d525['c']['Vector3'][0x1],_0x74d525['c']['Vector3'][0x4]),(_0xb2ed1c=_0x74d525['e']['Cross'](_0x74d525['c']['Vector3'][0x3],_0x74d525['c']['Vector3'][0x4]))['normalize']()),_0x3a6ed1>_0x2db48d){var _0x42c073=_0x3a6ed1;_0x3a6ed1=_0x2db48d,_0x2db48d=_0x42c073;}if(_0x1586ee=_0x5b03d8[_0x1187a2=_0x3a6ed1+'_'+_0x2db48d]){if(!_0x1586ee['done'])_0x74d525['e']['Dot'](_0xb2ed1c,_0x1586ee['normal'])0x0||this['_source']['hasThinInstances']);},_0x338b20['prototype']['render']=function(){var _0x180c1f=this['_source']['getScene']();if(this['isReady']()&&_0x180c1f['activeCamera']){var _0x57d610=_0x180c1f['getEngine']();this['_lineShader']['_preBind'](),0x1!==this['_source']['edgesColor']['a']?_0x57d610['setAlphaMode'](_0x2103ba['a']['ALPHA_COMBINE']):_0x57d610['setAlphaMode'](_0x2103ba['a']['ALPHA_DISABLE']);var _0x3f566b=this['_source']['hasInstances']&&this['customInstances']['length']>0x0,_0x15b78a=_0x3f566b||this['_source']['hasThinInstances'],_0x146ebd=0x0;if(_0x15b78a){if(this['_buffersForInstances']['world0']=this['_source']['getVertexBuffer']('world0'),this['_buffersForInstances']['world1']=this['_source']['getVertexBuffer']('world1'),this['_buffersForInstances']['world2']=this['_source']['getVertexBuffer']('world2'),this['_buffersForInstances']['world3']=this['_source']['getVertexBuffer']('world3'),_0x3f566b){var _0x30189f=this['_source']['_instanceDataStorage'];if(_0x146ebd=this['customInstances']['length'],!_0x30189f['isFrozen']){for(var _0x6d9fcc=0x0,_0x37e531=0x0;_0x37e531<_0x146ebd;++_0x37e531)this['customInstances']['data'][_0x37e531]['copyToArray'](_0x30189f['instancesData'],_0x6d9fcc),_0x6d9fcc+=0x10;_0x30189f['instancesBuffer']['updateDirectly'](_0x30189f['instancesData'],0x0,_0x146ebd);}}else _0x146ebd=this['_source']['thinInstanceCount'];}_0x57d610['bindBuffers'](_0x15b78a?this['_buffersForInstances']:this['_buffers'],this['_ib'],this['_lineShader']['getEffect']()),_0x180c1f['resetCachedMaterial'](),this['_lineShader']['setColor4']('color',this['_source']['edgesColor']),_0x180c1f['activeCamera']['mode']===_0x568729['a']['ORTHOGRAPHIC_CAMERA']?this['_lineShader']['setFloat']('width',this['_source']['edgesWidth']/this['edgesWidthScalerForOrthographic']):this['_lineShader']['setFloat']('width',this['_source']['edgesWidth']/this['edgesWidthScalerForPerspective']),this['_lineShader']['setFloat']('aspectRatio',_0x57d610['getAspectRatio'](_0x180c1f['activeCamera'])),this['_lineShader']['bind'](this['_source']['getWorldMatrix']()),_0x57d610['drawElementsType'](_0x33c2e5['a']['TriangleFillMode'],0x0,this['_indicesCount'],_0x146ebd),this['_lineShader']['unbind'](),_0x15b78a&&_0x57d610['unbindInstanceAttributes'](),this['_source']['getScene']()['_activeMeshesFrozen']||this['customInstances']['reset']();}},_0x338b20;}()),_0x29ddd5=function(_0x4c38a7){function _0x338472(_0xe2005d,_0x2cf47a,_0x50f72b){void 0x0===_0x2cf47a&&(_0x2cf47a=0.95),void 0x0===_0x50f72b&&(_0x50f72b=!0x1);var _0x1e0f32=_0x4c38a7['call'](this,_0xe2005d,_0x2cf47a,_0x50f72b,!0x1)||this;return _0x1e0f32['_generateEdgesLines'](),_0x1e0f32;}return Object(_0x18e13d['d'])(_0x338472,_0x4c38a7),_0x338472['prototype']['_generateEdgesLines']=function(){var _0x216d0b=this['_source']['getVerticesData'](_0x212fbd['b']['PositionKind']),_0x3a7780=this['_source']['getIndices']();if(_0x3a7780&&_0x216d0b){for(var _0x1e0b05=_0x74d525['c']['Vector3'][0x0],_0x41ff81=_0x74d525['c']['Vector3'][0x1],_0x2a03e8=_0x3a7780['length']-0x1,_0x5c4a57=0x0,_0x4876f5=0x0;_0x5c4a57<_0x2a03e8;_0x5c4a57+=0x2,_0x4876f5+=0x4)_0x74d525['e']['FromArrayToRef'](_0x216d0b,0x3*_0x3a7780[_0x5c4a57],_0x1e0b05),_0x74d525['e']['FromArrayToRef'](_0x216d0b,0x3*_0x3a7780[_0x5c4a57+0x1],_0x41ff81),this['createLine'](_0x1e0b05,_0x41ff81,_0x4876f5);var _0xc66880=this['_source']['getScene']()['getEngine']();this['_buffers'][_0x212fbd['b']['PositionKind']]=new _0x212fbd['b'](_0xc66880,this['_linesPositions'],_0x212fbd['b']['PositionKind'],!0x1),this['_buffers'][_0x212fbd['b']['NormalKind']]=new _0x212fbd['b'](_0xc66880,this['_linesNormals'],_0x212fbd['b']['NormalKind'],!0x1,!0x1,0x4),this['_ib']=_0xc66880['createIndexBuffer'](this['_linesIndices']),this['_indicesCount']=this['_linesIndices']['length'];}},_0x338472;}(_0x5cf15b),_0xb94897=(function(){function _0x4ea010(_0x29c1a2){this['_textureFormats']=[{'type':_0x2103ba['a']['PREPASS_IRRADIANCE_TEXTURE_TYPE'],'format':_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT']},{'type':_0x2103ba['a']['PREPASS_POSITION_TEXTURE_TYPE'],'format':_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT']},{'type':_0x2103ba['a']['PREPASS_VELOCITY_TEXTURE_TYPE'],'format':_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT']},{'type':_0x2103ba['a']['PREPASS_REFLECTIVITY_TEXTURE_TYPE'],'format':_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']},{'type':_0x2103ba['a']['PREPASS_COLOR_TEXTURE_TYPE'],'format':_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT']},{'type':_0x2103ba['a']['PREPASS_DEPTHNORMAL_TEXTURE_TYPE'],'format':_0x2103ba['a']['TEXTURETYPE_HALF_FLOAT']},{'type':_0x2103ba['a']['PREPASS_ALBEDO_TEXTURE_TYPE'],'format':_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']}],this['excludedSkinnedMesh']=[],this['excludedMaterials']=[],this['_textureIndices']=[],this['_isDirty']=!0x1,this['mrtCount']=0x0,this['_postProcesses']=[],this['_clearColor']=new _0x39310d['b'](0x0,0x0,0x0,0x0),this['_effectConfigurations']=[],this['_mrtFormats']=[],this['_enabled']=!0x1,this['_useGeometryBufferFallback']=!0x1,this['disableGammaTransform']=!0x1,this['_scene']=_0x29c1a2,this['_engine']=_0x29c1a2['getEngine'](),_0x4ea010['_SceneComponentInitialization'](this['_scene']),this['_resetLayout']();}return Object['defineProperty'](_0x4ea010['prototype'],'enabled',{'get':function(){return this['_enabled'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4ea010['prototype'],'samples',{'get':function(){return this['prePassRT']['samples'];},'set':function(_0x4cbb48){this['imageProcessingPostProcess']||this['_createCompositionEffect'](),this['prePassRT']['samples']=_0x4cbb48;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4ea010['prototype'],'useGeometryBufferFallback',{'get':function(){return this['_useGeometryBufferFallback'];},'set':function(_0x359313){if(this['_useGeometryBufferFallback']=_0x359313,_0x359313){if(this['_geometryBuffer']=this['_scene']['enableGeometryBufferRenderer'](),!this['_geometryBuffer'])return void(this['_useGeometryBufferFallback']=!0x1);this['_geometryBuffer']['renderList']=[],this['_geometryBuffer']['_linkPrePassRenderer'](this),this['_updateGeometryBufferLayout']();}else this['_geometryBuffer']&&this['_geometryBuffer']['_unlinkPrePassRenderer'](),this['_geometryBuffer']=null,this['_scene']['disableGeometryBufferRenderer']();},'enumerable':!0x1,'configurable':!0x0}),_0x4ea010['prototype']['_initializeAttachments']=function(){for(var _0x51360e=[],_0x2ee6c8=[!0x1],_0x2616c9=[!0x0],_0x470f05=0x0;_0x470f050x0&&(_0x2ee6c8['push'](!0x0),_0x2616c9['push'](!0x1));this['_multiRenderAttachments']=this['_engine']['buildTextureLayout'](_0x51360e),this['_clearAttachments']=this['_engine']['buildTextureLayout'](_0x2ee6c8),this['_defaultAttachments']=this['_engine']['buildTextureLayout'](_0x2616c9);},_0x4ea010['prototype']['_createCompositionEffect']=function(){this['prePassRT']=new _0x152eb4('sceneprePassRT',{'width':this['_engine']['getRenderWidth'](),'height':this['_engine']['getRenderHeight']()},this['mrtCount'],this['_scene'],{'generateMipMaps':!0x1,'generateDepthTexture':!0x0,'defaultType':_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'],'types':this['_mrtFormats']}),this['prePassRT']['samples']=0x1,this['_initializeAttachments'](),this['_useGeometryBufferFallback']&&!this['_geometryBuffer']&&(this['useGeometryBufferFallback']=!0x0),this['imageProcessingPostProcess']=new _0x53baeb('sceneCompositionPass',0x1,null,void 0x0,this['_engine']),this['imageProcessingPostProcess']['autoClear']=!0x1;},Object['defineProperty'](_0x4ea010['prototype'],'isSupported',{'get':function(){return this['_engine']['webGLVersion']>0x1||this['_scene']['getEngine']()['getCaps']()['drawBuffersExtension'];},'enumerable':!0x1,'configurable':!0x0}),_0x4ea010['prototype']['bindAttachmentsForEffect']=function(_0x2d810a,_0x5216a1){if(this['enabled']){if(_0x2d810a['_multiTarget'])this['_engine']['bindAttachments'](this['_multiRenderAttachments']);else{if(this['_engine']['bindAttachments'](this['_defaultAttachments']),this['_geometryBuffer']){var _0x27b42a=_0x5216a1['getMaterial']();_0x27b42a&&-0x1===this['excludedMaterials']['indexOf'](_0x27b42a)&&this['_geometryBuffer']['renderList']['push'](_0x5216a1['getRenderingMesh']());}}}},_0x4ea010['prototype']['restoreAttachments']=function(){this['enabled']&&this['_defaultAttachments']&&this['_engine']['bindAttachments'](this['_defaultAttachments']);},_0x4ea010['prototype']['_beforeCameraDraw']=function(){this['_isDirty']&&this['_update'](),this['_geometryBuffer']&&(this['_geometryBuffer']['renderList']['length']=0x0),this['_bindFrameBuffer']();},_0x4ea010['prototype']['_afterCameraDraw']=function(){if(this['_enabled']){var _0x429e0f=this['_scene']['activeCamera']&&this['_scene']['activeCamera']['_getFirstPostProcess']();_0x429e0f&&this['_postProcesses']['length']&&this['_scene']['postProcessManager']['_prepareFrame'](),this['_scene']['postProcessManager']['directRender'](this['_postProcesses'],_0x429e0f?_0x429e0f['inputTexture']:null);}},_0x4ea010['prototype']['_checkRTSize']=function(){var _0x969b6f=this['_engine']['getRenderWidth'](!0x0),_0x2233d2=this['_engine']['getRenderHeight'](!0x0),_0x4a223e=this['prePassRT']['getRenderWidth'](),_0x553cad=this['prePassRT']['getRenderHeight']();_0x4a223e===_0x969b6f&&_0x553cad===_0x2233d2||(this['prePassRT']['resize']({'width':_0x969b6f,'height':_0x2233d2}),this['_updateGeometryBufferLayout'](),this['_bindPostProcessChain']());},_0x4ea010['prototype']['_bindFrameBuffer']=function(){if(this['_enabled']){this['_checkRTSize']();var _0x5b1c42=this['prePassRT']['getInternalTexture']();_0x5b1c42&&this['_engine']['bindFramebuffer'](_0x5b1c42);}},_0x4ea010['prototype']['clear']=function(){this['_enabled']&&(this['_bindFrameBuffer'](),this['_engine']['clear'](this['_scene']['clearColor'],this['_scene']['autoClear']||this['_scene']['forceWireframe']||this['_scene']['forcePointsCloud'],this['_scene']['autoClearDepthAndStencil'],this['_scene']['autoClearDepthAndStencil']),this['_engine']['bindAttachments'](this['_clearAttachments']),this['_engine']['clear'](this['_clearColor'],!0x0,!0x1,!0x1),this['_engine']['bindAttachments'](this['_defaultAttachments']));},_0x4ea010['prototype']['_setState']=function(_0x1d5cbc){this['_enabled']=_0x1d5cbc,this['_scene']['prePass']=_0x1d5cbc,this['imageProcessingPostProcess']&&(this['imageProcessingPostProcess']['imageProcessingConfiguration']['applyByPostProcess']=_0x1d5cbc);},_0x4ea010['prototype']['_updateGeometryBufferLayout']=function(){if(this['_geometryBuffer']){this['_geometryBuffer']['_resetLayout']();for(var _0x3bc0a2=[],_0x10fd5b=0x0;_0x10fd5b=0x5)return _0x75193d['a']['Error']('You\x20already\x20reached\x20the\x20maximum\x20number\x20of\x20diffusion\x20profiles.'),0x0;for(var _0x522180=0x0;_0x5221800x4&&(_0x1b7cde['push'](_0x212fbd['b']['MatricesIndicesExtraKind']),_0x1b7cde['push'](_0x212fbd['b']['MatricesWeightsExtraKind'])),_0x23ef5c['push']('#define\x20NUM_BONE_INFLUENCERS\x20'+_0x430da4['numBoneInfluencers']),_0x23ef5c['push']('#define\x20BonesPerMesh\x20'+(_0x430da4['skeleton']?_0x430da4['skeleton']['bones']['length']+0x1:0x0))):_0x23ef5c['push']('#define\x20NUM_BONE_INFLUENCERS\x200');var _0x314b44=_0x430da4['morphTargetManager'],_0x18841=0x0;_0x314b44&&_0x314b44['numInfluencers']>0x0&&(_0x18841=_0x314b44['numInfluencers'],_0x23ef5c['push']('#define\x20MORPHTARGETS'),_0x23ef5c['push']('#define\x20NUM_MORPH_INFLUENCERS\x20'+_0x18841),_0x464f31['a']['PrepareAttributesForMorphTargetsInfluencers'](_0x1b7cde,_0x430da4,_0x18841)),_0x34fe3b&&(_0x23ef5c['push']('#define\x20INSTANCES'),_0x464f31['a']['PushAttributesForInstances'](_0x1b7cde),_0x3d19d8['getRenderingMesh']()['hasThinInstances']&&_0x23ef5c['push']('#define\x20THIN_INSTANCES'));var _0x27e054=_0x23ef5c['join']('\x0a');return this['_cachedDefines']!==_0x27e054&&(this['_cachedDefines']=_0x27e054,this['_effect']=this['scene']['getEngine']()['createEffect']('outline',_0x1b7cde,['world','mBones','viewProjection','diffuseMatrix','offset','color','logarithmicDepthConstant','morphTargetInfluences'],['diffuseSampler'],_0x27e054,void 0x0,void 0x0,void 0x0,{'maxSimultaneousMorphTargets':_0x18841})),this['_effect']['isReady']();},_0x112a3f['prototype']['_beforeRenderingMesh']=function(_0x3d8f1,_0x2a3dd9,_0x3f1691){if(this['_savedDepthWrite']=this['_engine']['getDepthWrite'](),_0x3d8f1['renderOutline']){var _0x16b196=_0x2a3dd9['getMaterial']();_0x16b196&&_0x16b196['needAlphaBlendingForMesh'](_0x3d8f1)&&(this['_engine']['cacheStencilState'](),this['_engine']['setDepthWrite'](!0x1),this['_engine']['setColorWrite'](!0x1),this['_engine']['setStencilBuffer'](!0x0),this['_engine']['setStencilOperationPass'](_0x2103ba['a']['REPLACE']),this['_engine']['setStencilFunction'](_0x2103ba['a']['ALWAYS']),this['_engine']['setStencilMask'](_0x112a3f['_StencilReference']),this['_engine']['setStencilFunctionReference'](_0x112a3f['_StencilReference']),this['render'](_0x2a3dd9,_0x3f1691,!0x0),this['_engine']['setColorWrite'](!0x0),this['_engine']['setStencilFunction'](_0x2103ba['a']['NOTEQUAL'])),this['_engine']['setDepthWrite'](!0x1),this['render'](_0x2a3dd9,_0x3f1691),this['_engine']['setDepthWrite'](this['_savedDepthWrite']),_0x16b196&&_0x16b196['needAlphaBlendingForMesh'](_0x3d8f1)&&this['_engine']['restoreStencilState']();}},_0x112a3f['prototype']['_afterRenderingMesh']=function(_0x6f5d2f,_0x348d76,_0x1d7552){if(_0x6f5d2f['renderOverlay']){var _0x460cde=this['_engine']['getAlphaMode'](),_0x376666=this['_engine']['alphaState']['alphaBlend'];this['_engine']['setAlphaMode'](_0x2103ba['a']['ALPHA_COMBINE']),this['render'](_0x348d76,_0x1d7552,!0x0),this['_engine']['setAlphaMode'](_0x460cde),this['_engine']['setDepthWrite'](this['_savedDepthWrite']),this['_engine']['alphaState']['alphaBlend']=_0x376666;}_0x6f5d2f['renderOutline']&&this['_savedDepthWrite']&&(this['_engine']['setDepthWrite'](!0x0),this['_engine']['setColorWrite'](!0x1),this['render'](_0x348d76,_0x1d7552),this['_engine']['setColorWrite'](!0x0));},_0x112a3f['_StencilReference']=0x4,_0x112a3f;}()),_0x883304=_0x162675(0x94),_0x181037=function(_0xd022c4){function _0x447672(_0x199b85,_0x5940d1){var _0x559d69=_0xd022c4['call'](this)||this;return _0x559d69['name']=_0x199b85,_0x559d69['animations']=new Array(),_0x559d69['isPickable']=!0x1,_0x559d69['useAlphaForPicking']=!0x1,_0x559d69['onDisposeObservable']=new _0x6ac1f7['c'](),_0x559d69['_onAnimationEnd']=null,_0x559d69['_endAnimation']=function(){_0x559d69['_onAnimationEnd']&&_0x559d69['_onAnimationEnd'](),_0x559d69['disposeWhenFinishedAnimating']&&_0x559d69['dispose']();},_0x559d69['color']=new _0x39310d['b'](0x1,0x1,0x1,0x1),_0x559d69['position']=_0x74d525['e']['Zero'](),_0x559d69['_manager']=_0x5940d1,_0x559d69['_manager']['sprites']['push'](_0x559d69),_0x559d69['uniqueId']=_0x559d69['_manager']['scene']['getUniqueId'](),_0x559d69;}return Object(_0x18e13d['d'])(_0x447672,_0xd022c4),Object['defineProperty'](_0x447672['prototype'],'size',{'get':function(){return this['width'];},'set':function(_0x2f6a4d){this['width']=_0x2f6a4d,this['height']=_0x2f6a4d;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x447672['prototype'],'manager',{'get':function(){return this['_manager'];},'enumerable':!0x1,'configurable':!0x0}),_0x447672['prototype']['getClassName']=function(){return'Sprite';},Object['defineProperty'](_0x447672['prototype'],'fromIndex',{'get':function(){return this['_fromIndex'];},'set':function(_0x39d474){this['playAnimation'](_0x39d474,this['_toIndex'],this['_loopAnimation'],this['_delay'],this['_onAnimationEnd']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x447672['prototype'],'toIndex',{'get':function(){return this['_toIndex'];},'set':function(_0x27182e){this['playAnimation'](this['_fromIndex'],_0x27182e,this['_loopAnimation'],this['_delay'],this['_onAnimationEnd']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x447672['prototype'],'loopAnimation',{'get':function(){return this['_loopAnimation'];},'set':function(_0x1e5976){this['playAnimation'](this['_fromIndex'],this['_toIndex'],_0x1e5976,this['_delay'],this['_onAnimationEnd']);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x447672['prototype'],'delay',{'get':function(){return Math['max'](this['_delay'],0x1);},'set':function(_0x461961){this['playAnimation'](this['_fromIndex'],this['_toIndex'],this['_loopAnimation'],_0x461961,this['_onAnimationEnd']);},'enumerable':!0x1,'configurable':!0x0}),_0x447672['prototype']['playAnimation']=function(_0x5d8b19,_0x332152,_0x2fb789,_0x5b2c01,_0xe80414){void 0x0===_0xe80414&&(_0xe80414=null),this['_onAnimationEnd']=_0xe80414,_0xd022c4['prototype']['playAnimation']['call'](this,_0x5d8b19,_0x332152,_0x2fb789,_0x5b2c01,this['_endAnimation']);},_0x447672['prototype']['dispose']=function(){for(var _0x63b949=0x0;_0x63b949this['_delay']&&(this['_time']=this['_time']%this['_delay'],this['cellIndex']+=this['_direction'],(this['_direction']>0x0&&this['cellIndex']>this['_toIndex']||this['_direction']<0x0&&this['cellIndex']0x0?this['_fromIndex']:this['_toIndex']:(this['cellIndex']=this['_toIndex'],this['_animationStarted']=!0x1,this['_onBaseAnimationEnd']&&this['_onBaseAnimationEnd']()))));},_0x263cea;}()));_0x59370b['a']['prototype']['_internalPickSprites']=function(_0x1ad823,_0x1e54e6,_0x3527d7,_0x4fc4a7){if(!_0x1fa05e['a'])return null;var _0x44fc95=null;if(!_0x4fc4a7){if(!this['activeCamera'])return null;_0x4fc4a7=this['activeCamera'];}if(this['spriteManagers']['length']>0x0)for(var _0x510e2b=0x0;_0x510e2b=_0x44fc95['distance']))&&(_0x44fc95=_0x5e873a,_0x3527d7))break;}}return _0x44fc95||new _0x1fa05e['a']();},_0x59370b['a']['prototype']['_internalMultiPickSprites']=function(_0x4e6f1d,_0x728814,_0x363ea5){if(!_0x1fa05e['a'])return null;var _0x1d3d9b=new Array();if(!_0x363ea5){if(!this['activeCamera'])return null;_0x363ea5=this['activeCamera'];}if(this['spriteManagers']['length']>0x0)for(var _0x12444f=0x0;_0x12444f0x0&&(_0x3484cf=_0x54bd1c['pickSprite'](_0x4ac3f9,_0x25a4af,this['_spritePredicate'],!0x1,_0x54bd1c['cameraToUseForPointers']||void 0x0))&&_0x3484cf['hit']&&_0x3484cf['pickedSprite']&&_0x3484cf['pickedSprite']['actionManager']){switch(_0x54bd1c['_pickedDownSprite']=_0x3484cf['pickedSprite'],_0x159f35['button']){case 0x0:_0x3484cf['pickedSprite']['actionManager']['processTrigger'](_0x2103ba['a']['ACTION_OnLeftPickTrigger'],_0x3b70ca['a']['CreateNewFromSprite'](_0x3484cf['pickedSprite'],_0x54bd1c,_0x159f35));break;case 0x1:_0x3484cf['pickedSprite']['actionManager']['processTrigger'](_0x2103ba['a']['ACTION_OnCenterPickTrigger'],_0x3b70ca['a']['CreateNewFromSprite'](_0x3484cf['pickedSprite'],_0x54bd1c,_0x159f35));break;case 0x2:_0x3484cf['pickedSprite']['actionManager']['processTrigger'](_0x2103ba['a']['ACTION_OnRightPickTrigger'],_0x3b70ca['a']['CreateNewFromSprite'](_0x3484cf['pickedSprite'],_0x54bd1c,_0x159f35));}_0x3484cf['pickedSprite']['actionManager']&&_0x3484cf['pickedSprite']['actionManager']['processTrigger'](_0x2103ba['a']['ACTION_OnPickDownTrigger'],_0x3b70ca['a']['CreateNewFromSprite'](_0x3484cf['pickedSprite'],_0x54bd1c,_0x159f35));}return _0x3484cf;},_0x14ce25['prototype']['_pointerUp']=function(_0x48fafb,_0x789d29,_0xaeb8dc,_0x1684dd){var _0x4e88d7=this['scene'];if(_0x4e88d7['spriteManagers']['length']>0x0){var _0x12c422=_0x4e88d7['pickSprite'](_0x48fafb,_0x789d29,this['_spritePredicate'],!0x1,_0x4e88d7['cameraToUseForPointers']||void 0x0);_0x12c422&&(_0x12c422['hit']&&_0x12c422['pickedSprite']&&_0x12c422['pickedSprite']['actionManager']&&(_0x12c422['pickedSprite']['actionManager']['processTrigger'](_0x2103ba['a']['ACTION_OnPickUpTrigger'],_0x3b70ca['a']['CreateNewFromSprite'](_0x12c422['pickedSprite'],_0x4e88d7,_0x1684dd)),_0x12c422['pickedSprite']['actionManager']&&(this['scene']['_inputManager']['_isPointerSwiping']()||_0x12c422['pickedSprite']['actionManager']['processTrigger'](_0x2103ba['a']['ACTION_OnPickTrigger'],_0x3b70ca['a']['CreateNewFromSprite'](_0x12c422['pickedSprite'],_0x4e88d7,_0x1684dd)))),_0x4e88d7['_pickedDownSprite']&&_0x4e88d7['_pickedDownSprite']['actionManager']&&_0x4e88d7['_pickedDownSprite']!==_0x12c422['pickedSprite']&&_0x4e88d7['_pickedDownSprite']['actionManager']['processTrigger'](_0x2103ba['a']['ACTION_OnPickOutTrigger'],_0x3b70ca['a']['CreateNewFromSprite'](_0x4e88d7['_pickedDownSprite'],_0x4e88d7,_0x1684dd)));}return _0xaeb8dc;},_0x14ce25;}());_0x494b01['a']['IncludesShadersStore']['imageProcessingCompatibility']='#ifdef\x20IMAGEPROCESSINGPOSTPROCESS\x0agl_FragColor.rgb=pow(gl_FragColor.rgb,vec3(2.2));\x0a#endif';var _0x3770d9='uniform\x20bool\x20alphaTest;\x0avarying\x20vec4\x20vColor;\x0a\x0avarying\x20vec2\x20vUV;\x0auniform\x20sampler2D\x20diffuseSampler;\x0a\x0a#include\x0avoid\x20main(void)\x20{\x0avec4\x20color=texture2D(diffuseSampler,vUV);\x0aif\x20(alphaTest)\x0a{\x0aif\x20(color.a<0.95)\x0adiscard;\x0a}\x0acolor*=vColor;\x0a#include\x0agl_FragColor=color;\x0a#include\x0a}';_0x494b01['a']['ShadersStore']['spritesPixelShader']=_0x3770d9;var _0x272787='\x0aattribute\x20vec4\x20position;\x0aattribute\x20vec2\x20options;\x0aattribute\x20vec2\x20offsets;\x0aattribute\x20vec2\x20inverts;\x0aattribute\x20vec4\x20cellInfo;\x0aattribute\x20vec4\x20color;\x0a\x0auniform\x20mat4\x20view;\x0auniform\x20mat4\x20projection;\x0a\x0avarying\x20vec2\x20vUV;\x0avarying\x20vec4\x20vColor;\x0a#include\x0avoid\x20main(void)\x20{\x0avec3\x20viewPos=(view*vec4(position.xyz,1.0)).xyz;\x0avec2\x20cornerPos;\x0afloat\x20angle=position.w;\x0avec2\x20size=vec2(options.x,options.y);\x0avec2\x20offset=offsets.xy;\x0acornerPos=vec2(offset.x-0.5,offset.y-0.5)*size;\x0a\x0avec3\x20rotatedCorner;\x0arotatedCorner.x=cornerPos.x*cos(angle)-cornerPos.y*sin(angle);\x0arotatedCorner.y=cornerPos.x*sin(angle)+cornerPos.y*cos(angle);\x0arotatedCorner.z=0.;\x0a\x0aviewPos+=rotatedCorner;\x0agl_Position=projection*vec4(viewPos,1.0);\x0a\x0avColor=color;\x0a\x0avec2\x20uvOffset=vec2(abs(offset.x-inverts.x),abs(1.0-offset.y-inverts.y));\x0avec2\x20uvPlace=cellInfo.xy;\x0avec2\x20uvSize=cellInfo.zw;\x0avUV.x=uvPlace.x+uvSize.x*uvOffset.x;\x0avUV.y=uvPlace.y+uvSize.y*uvOffset.y;\x0a\x0a#ifdef\x20FOG\x0avFogDistance=viewPos;\x0a#endif\x0a}';_0x494b01['a']['ShadersStore']['spritesVertexShader']=_0x272787;var _0x5283fd=(function(){function _0x4c66a7(_0x225e60,_0x5bdeed,_0x3975ba,_0x1881d0){if(void 0x0===_0x3975ba&&(_0x3975ba=0.01),void 0x0===_0x1881d0&&(_0x1881d0=null),this['blendMode']=_0x2103ba['a']['ALPHA_COMBINE'],this['autoResetAlpha']=!0x0,this['disableDepthWrite']=!0x1,this['fogEnabled']=!0x0,this['_useVAO']=!0x1,this['_useInstancing']=!0x1,this['_vertexBuffers']={},this['_capacity']=_0x5bdeed,this['_epsilon']=_0x3975ba,this['_engine']=_0x225e60,this['_useInstancing']=_0x225e60['getCaps']()['instancedArrays'],this['_useVAO']=_0x225e60['getCaps']()['vertexArrayObject']&&!_0x225e60['disableVertexArrayObjects'],this['_scene']=_0x1881d0,!this['_useInstancing']){for(var _0x3c4843=[],_0x4ff9d9=0x0,_0x82254=0x0;_0x82254<_0x5bdeed;_0x82254++)_0x3c4843['push'](_0x4ff9d9),_0x3c4843['push'](_0x4ff9d9+0x1),_0x3c4843['push'](_0x4ff9d9+0x2),_0x3c4843['push'](_0x4ff9d9),_0x3c4843['push'](_0x4ff9d9+0x2),_0x3c4843['push'](_0x4ff9d9+0x3),_0x4ff9d9+=0x4;this['_indexBuffer']=_0x225e60['createIndexBuffer'](_0x3c4843);}this['_vertexBufferSize']=this['_useInstancing']?0x10:0x12,this['_vertexData']=new Float32Array(_0x5bdeed*this['_vertexBufferSize']*(this['_useInstancing']?0x1:0x4)),this['_buffer']=new _0x212fbd['a'](_0x225e60,this['_vertexData'],!0x0,this['_vertexBufferSize']);var _0x50bc1e,_0x22401a=this['_buffer']['createVertexBuffer'](_0x212fbd['b']['PositionKind'],0x0,0x4,this['_vertexBufferSize'],this['_useInstancing']),_0x5f4fbf=this['_buffer']['createVertexBuffer']('options',0x4,0x2,this['_vertexBufferSize'],this['_useInstancing']),_0x340ad2=0x6;if(this['_useInstancing']){var _0x3a23fd=new Float32Array([0x0,0x0,0x1,0x0,0x1,0x1,0x0,0x1]);this['_spriteBuffer']=new _0x212fbd['a'](_0x225e60,_0x3a23fd,!0x1,0x2),_0x50bc1e=this['_spriteBuffer']['createVertexBuffer']('offsets',0x0,0x2);}else _0x50bc1e=this['_buffer']['createVertexBuffer']('offsets',_0x340ad2,0x2,this['_vertexBufferSize'],this['_useInstancing']),_0x340ad2+=0x2;var _0x2caca6=this['_buffer']['createVertexBuffer']('inverts',_0x340ad2,0x2,this['_vertexBufferSize'],this['_useInstancing']),_0x280210=this['_buffer']['createVertexBuffer']('cellInfo',_0x340ad2+0x2,0x4,this['_vertexBufferSize'],this['_useInstancing']),_0x92c3ff=this['_buffer']['createVertexBuffer'](_0x212fbd['b']['ColorKind'],_0x340ad2+0x6,0x4,this['_vertexBufferSize'],this['_useInstancing']);this['_vertexBuffers'][_0x212fbd['b']['PositionKind']]=_0x22401a,this['_vertexBuffers']['options']=_0x5f4fbf,this['_vertexBuffers']['offsets']=_0x50bc1e,this['_vertexBuffers']['inverts']=_0x2caca6,this['_vertexBuffers']['cellInfo']=_0x280210,this['_vertexBuffers'][_0x212fbd['b']['ColorKind']]=_0x92c3ff,this['_effectBase']=this['_engine']['createEffect']('sprites',[_0x212fbd['b']['PositionKind'],'options','offsets','inverts','cellInfo',_0x212fbd['b']['ColorKind']],['view','projection','textureInfos','alphaTest'],['diffuseSampler'],''),this['_scene']&&(this['_effectFog']=this['_scene']['getEngine']()['createEffect']('sprites',[_0x212fbd['b']['PositionKind'],'options','offsets','inverts','cellInfo',_0x212fbd['b']['ColorKind']],['view','projection','textureInfos','alphaTest','vFogInfos','vFogColor'],['diffuseSampler'],'#define\x20FOG'));}return Object['defineProperty'](_0x4c66a7['prototype'],'capacity',{'get':function(){return this['_capacity'];},'enumerable':!0x1,'configurable':!0x0}),_0x4c66a7['prototype']['render']=function(_0x477e86,_0x4fb9a9,_0x5efea2,_0x251e79,_0x3f0779){if(void 0x0===_0x3f0779&&(_0x3f0779=null),this['texture']&&this['texture']['isReady']()&&_0x477e86['length']){var _0x27a993=this['_effectBase'],_0x3d1559=!0x1;if(this['fogEnabled']&&this['_scene']&&this['_scene']['fogEnabled']&&0x0!==this['_scene']['fogMode']&&(_0x27a993=this['_effectFog'],_0x3d1559=!0x0),_0x27a993['isReady']()){for(var _0x227875=this['_engine'],_0x1b9cce=!(!this['_scene']||!this['_scene']['useRightHandedSystem']),_0x1dc23e=this['texture']['getBaseSize'](),_0x1cd16d=Math['min'](this['_capacity'],_0x477e86['length']),_0x19c770=0x0,_0x45897b=!0x0,_0x132470=0x0;_0x132470<_0x1cd16d;_0x132470++){var _0x41ff71=_0x477e86[_0x132470];_0x41ff71&&_0x41ff71['isVisible']&&(_0x45897b=!0x1,_0x41ff71['_animate'](_0x4fb9a9),this['_appendSpriteVertex'](_0x19c770++,_0x41ff71,0x0,0x0,_0x1dc23e,_0x1b9cce,_0x3f0779),this['_useInstancing']||(this['_appendSpriteVertex'](_0x19c770++,_0x41ff71,0x1,0x0,_0x1dc23e,_0x1b9cce,_0x3f0779),this['_appendSpriteVertex'](_0x19c770++,_0x41ff71,0x1,0x1,_0x1dc23e,_0x1b9cce,_0x3f0779),this['_appendSpriteVertex'](_0x19c770++,_0x41ff71,0x0,0x1,_0x1dc23e,_0x1b9cce,_0x3f0779)));}if(!_0x45897b){this['_buffer']['update'](this['_vertexData']);var _0x23976b=_0x227875['depthCullingState']['cull']||!0x0,_0x312d11=_0x227875['depthCullingState']['zOffset'];if(_0x1b9cce&&this['_scene']['getEngine']()['setState'](_0x23976b,_0x312d11,!0x1,!0x1),_0x227875['enableEffect'](_0x27a993),_0x27a993['setTexture']('diffuseSampler',this['texture']),_0x27a993['setMatrix']('view',_0x5efea2),_0x27a993['setMatrix']('projection',_0x251e79),_0x3d1559){var _0x119137=this['_scene'];_0x27a993['setFloat4']('vFogInfos',_0x119137['fogMode'],_0x119137['fogStart'],_0x119137['fogEnd'],_0x119137['fogDensity']),_0x27a993['setColor3']('vFogColor',_0x119137['fogColor']);}this['_useVAO']?(this['_vertexArrayObject']||(this['_vertexArrayObject']=_0x227875['recordVertexArrayObject'](this['_vertexBuffers'],this['_indexBuffer'],_0x27a993)),_0x227875['bindVertexArrayObject'](this['_vertexArrayObject'],this['_indexBuffer'])):_0x227875['bindBuffers'](this['_vertexBuffers'],this['_indexBuffer'],_0x27a993),_0x227875['depthCullingState']['depthFunc']=_0x2103ba['a']['LEQUAL'],this['disableDepthWrite']||(_0x27a993['setBool']('alphaTest',!0x0),_0x227875['setColorWrite'](!0x1),this['_useInstancing']?_0x227875['drawArraysType'](_0x2103ba['a']['MATERIAL_TriangleFanDrawMode'],0x0,0x4,_0x19c770):_0x227875['drawElementsType'](_0x2103ba['a']['MATERIAL_TriangleFillMode'],0x0,_0x19c770/0x4*0x6),_0x227875['setColorWrite'](!0x0),_0x27a993['setBool']('alphaTest',!0x1)),_0x227875['setAlphaMode'](this['blendMode']),this['_useInstancing']?_0x227875['drawArraysType'](_0x2103ba['a']['MATERIAL_TriangleFanDrawMode'],0x0,0x4,_0x19c770):_0x227875['drawElementsType'](_0x2103ba['a']['MATERIAL_TriangleFillMode'],0x0,_0x19c770/0x4*0x6),this['autoResetAlpha']&&_0x227875['setAlphaMode'](_0x2103ba['a']['ALPHA_DISABLE']),_0x1b9cce&&this['_scene']['getEngine']()['setState'](_0x23976b,_0x312d11,!0x1,!0x0),_0x227875['unbindInstanceAttributes']();}}}},_0x4c66a7['prototype']['_appendSpriteVertex']=function(_0x49daab,_0x2f6fc8,_0x24730e,_0x50415f,_0x5900fe,_0x348072,_0x1902b1){var _0x3008fb=_0x49daab*this['_vertexBufferSize'];if(0x0===_0x24730e?_0x24730e=this['_epsilon']:0x1===_0x24730e&&(_0x24730e=0x1-this['_epsilon']),0x0===_0x50415f?_0x50415f=this['_epsilon']:0x1===_0x50415f&&(_0x50415f=0x1-this['_epsilon']),_0x1902b1)_0x1902b1(_0x2f6fc8,_0x5900fe);else{_0x2f6fc8['cellIndex']||(_0x2f6fc8['cellIndex']=0x0);var _0x2af13b=_0x5900fe['width']/this['cellWidth'],_0x18f5c5=_0x2f6fc8['cellIndex']/_0x2af13b>>0x0;_0x2f6fc8['_xOffset']=(_0x2f6fc8['cellIndex']-_0x18f5c5*_0x2af13b)*this['cellWidth']/_0x5900fe['width'],_0x2f6fc8['_yOffset']=_0x18f5c5*this['cellHeight']/_0x5900fe['height'],_0x2f6fc8['_xSize']=this['cellWidth'],_0x2f6fc8['_ySize']=this['cellHeight'];}this['_vertexData'][_0x3008fb]=_0x2f6fc8['position']['x'],this['_vertexData'][_0x3008fb+0x1]=_0x2f6fc8['position']['y'],this['_vertexData'][_0x3008fb+0x2]=_0x2f6fc8['position']['z'],this['_vertexData'][_0x3008fb+0x3]=_0x2f6fc8['angle'],this['_vertexData'][_0x3008fb+0x4]=_0x2f6fc8['width'],this['_vertexData'][_0x3008fb+0x5]=_0x2f6fc8['height'],this['_useInstancing']?_0x3008fb-=0x2:(this['_vertexData'][_0x3008fb+0x6]=_0x24730e,this['_vertexData'][_0x3008fb+0x7]=_0x50415f),this['_vertexData'][_0x3008fb+0x8]=_0x348072?_0x2f6fc8['invertU']?0x0:0x1:_0x2f6fc8['invertU']?0x1:0x0,this['_vertexData'][_0x3008fb+0x9]=_0x2f6fc8['invertV']?0x1:0x0,this['_vertexData'][_0x3008fb+0xa]=_0x2f6fc8['_xOffset'],this['_vertexData'][_0x3008fb+0xb]=_0x2f6fc8['_yOffset'],this['_vertexData'][_0x3008fb+0xc]=_0x2f6fc8['_xSize']/_0x5900fe['width'],this['_vertexData'][_0x3008fb+0xd]=_0x2f6fc8['_ySize']/_0x5900fe['height'],this['_vertexData'][_0x3008fb+0xe]=_0x2f6fc8['color']['r'],this['_vertexData'][_0x3008fb+0xf]=_0x2f6fc8['color']['g'],this['_vertexData'][_0x3008fb+0x10]=_0x2f6fc8['color']['b'],this['_vertexData'][_0x3008fb+0x11]=_0x2f6fc8['color']['a'];},_0x4c66a7['prototype']['dispose']=function(){this['_buffer']&&(this['_buffer']['dispose'](),this['_buffer']=null),this['_spriteBuffer']&&(this['_spriteBuffer']['dispose'](),this['_spriteBuffer']=null),this['_indexBuffer']&&(this['_engine']['_releaseBuffer'](this['_indexBuffer']),this['_indexBuffer']=null),this['_vertexArrayObject']&&(this['_engine']['releaseVertexArrayObject'](this['_vertexArrayObject']),this['_vertexArrayObject']=null),this['texture']&&(this['texture']['dispose'](),this['texture']=null);},_0x4c66a7;}()),_0x15f119=(function(){function _0x241f3a(_0x537ed7,_0x50e853,_0x25eec7,_0xe01143,_0x5c6d62,_0x215756,_0x4b0b54,_0xc26893,_0x1af5b2){var _0x4c03ab=this;void 0x0===_0x215756&&(_0x215756=0.01),void 0x0===_0x4b0b54&&(_0x4b0b54=_0xaf3c80['a']['TRILINEAR_SAMPLINGMODE']),void 0x0===_0xc26893&&(_0xc26893=!0x1),void 0x0===_0x1af5b2&&(_0x1af5b2=null),this['name']=_0x537ed7,this['sprites']=new Array(),this['renderingGroupId']=0x0,this['layerMask']=0xfffffff,this['isPickable']=!0x1,this['onDisposeObservable']=new _0x6ac1f7['c'](),this['disableDepthWrite']=!0x1,this['_packedAndReady']=!0x1,this['_customUpdate']=function(_0x19bf4f,_0x3af093){_0x19bf4f['cellRef']||(_0x19bf4f['cellIndex']=0x0);var _0x8f6cf7=_0x19bf4f['cellIndex'];'number'==typeof _0x8f6cf7&&isFinite(_0x8f6cf7)&&Math['floor'](_0x8f6cf7)===_0x8f6cf7&&(_0x19bf4f['cellRef']=_0x4c03ab['_spriteMap'][_0x19bf4f['cellIndex']]),_0x19bf4f['_xOffset']=_0x4c03ab['_cellData'][_0x19bf4f['cellRef']]['frame']['x']/_0x3af093['width'],_0x19bf4f['_yOffset']=_0x4c03ab['_cellData'][_0x19bf4f['cellRef']]['frame']['y']/_0x3af093['height'],_0x19bf4f['_xSize']=_0x4c03ab['_cellData'][_0x19bf4f['cellRef']]['frame']['w'],_0x19bf4f['_ySize']=_0x4c03ab['_cellData'][_0x19bf4f['cellRef']]['frame']['h'];},_0x5c6d62||(_0x5c6d62=_0x300b38['a']['LastCreatedScene']),_0x5c6d62['_getComponent'](_0x384de3['a']['NAME_SPRITE'])||_0x5c6d62['_addComponent'](new _0x187130(_0x5c6d62)),this['_fromPacked']=_0xc26893,this['_scene']=_0x5c6d62;var _0x25a4b6=this['_scene']['getEngine']();if(this['_spriteRenderer']=new _0x5283fd(_0x25a4b6,_0x25eec7,_0x215756,_0x5c6d62),_0xe01143['width']&&_0xe01143['height'])this['cellWidth']=_0xe01143['width'],this['cellHeight']=_0xe01143['height'];else{if(void 0x0===_0xe01143)return void(this['_spriteRenderer']=null);this['cellWidth']=_0xe01143,this['cellHeight']=_0xe01143;}this['_scene']['spriteManagers']['push'](this),this['uniqueId']=this['scene']['getUniqueId'](),_0x50e853&&(this['texture']=new _0xaf3c80['a'](_0x50e853,_0x5c6d62,!0x0,!0x1,_0x4b0b54)),this['_fromPacked']&&this['_makePacked'](_0x50e853,_0x1af5b2);}return Object['defineProperty'](_0x241f3a['prototype'],'onDispose',{'set':function(_0x65fdb8){this['_onDisposeObserver']&&this['onDisposeObservable']['remove'](this['_onDisposeObserver']),this['_onDisposeObserver']=this['onDisposeObservable']['add'](_0x65fdb8);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x241f3a['prototype'],'children',{'get':function(){return this['sprites'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x241f3a['prototype'],'scene',{'get':function(){return this['_scene'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x241f3a['prototype'],'capacity',{'get':function(){return this['_spriteRenderer']['capacity'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x241f3a['prototype'],'texture',{'get':function(){return this['_spriteRenderer']['texture'];},'set':function(_0x348477){_0x348477['wrapU']=_0xaf3c80['a']['CLAMP_ADDRESSMODE'],_0x348477['wrapV']=_0xaf3c80['a']['CLAMP_ADDRESSMODE'],this['_spriteRenderer']['texture']=_0x348477,this['_textureContent']=null;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x241f3a['prototype'],'cellWidth',{'get':function(){return this['_spriteRenderer']['cellWidth'];},'set':function(_0x4316e3){this['_spriteRenderer']['cellWidth']=_0x4316e3;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x241f3a['prototype'],'cellHeight',{'get':function(){return this['_spriteRenderer']['cellHeight'];},'set':function(_0x5e4d8a){this['_spriteRenderer']['cellHeight']=_0x5e4d8a;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x241f3a['prototype'],'fogEnabled',{'get':function(){return this['_spriteRenderer']['fogEnabled'];},'set':function(_0x3ad8ec){this['_spriteRenderer']['fogEnabled']=_0x3ad8ec;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x241f3a['prototype'],'blendMode',{'get':function(){return this['_spriteRenderer']['blendMode'];},'set':function(_0x4e35ca){this['_spriteRenderer']['blendMode']=_0x4e35ca;},'enumerable':!0x1,'configurable':!0x0}),_0x241f3a['prototype']['getClassName']=function(){return'SpriteManager';},_0x241f3a['prototype']['_makePacked']=function(_0x27abc9,_0x2ecf4f){var _0x55b440=this;if(null!==_0x2ecf4f)try{var _0xa1e1f=void 0x0;if((_0xa1e1f='string'==typeof _0x2ecf4f?JSON['parse'](_0x2ecf4f):_0x2ecf4f)['frames']['length']){for(var _0x40aebe={},_0x2a19eb=0x0;_0x2a19eb<_0xa1e1f['frames']['length'];_0x2a19eb++){var _0x5db97d=_0xa1e1f['frames'][_0x2a19eb];if('string'!=typeof Object['keys'](_0x5db97d)[0x0])throw new Error('Invalid\x20JSON\x20Format.\x20\x20Check\x20the\x20frame\x20values\x20and\x20make\x20sure\x20the\x20name\x20is\x20the\x20first\x20parameter.');_0x40aebe[_0x5db97d[Object['keys'](_0x5db97d)[0x0]]]=_0x5db97d;}_0xa1e1f['frames']=_0x40aebe;}var _0x1c258f=Reflect['ownKeys'](_0xa1e1f['frames']);this['_spriteMap']=_0x1c258f,this['_packedAndReady']=!0x0,this['_cellData']=_0xa1e1f['frames'];}catch(_0x2cc757){throw this['_fromPacked']=!0x1,this['_packedAndReady']=!0x1,new Error('Invalid\x20JSON\x20from\x20string.\x20Spritesheet\x20managed\x20with\x20constant\x20cell\x20size.');}else{var _0x3e5ad3=/\./g,_0x420455=void 0x0;do{_0x420455=_0x3e5ad3['lastIndex'],_0x3e5ad3['test'](_0x27abc9);}while(_0x3e5ad3['lastIndex']>0x0);var _0x2c0840=_0x27abc9['substring'](0x0,_0x420455-0x1)+'.json',_0x4f642c=new XMLHttpRequest();_0x4f642c['open']('GET',_0x2c0840,!0x0),_0x4f642c['onerror']=function(){_0x75193d['a']['Error']('JSON\x20ERROR:\x20Unable\x20to\x20load\x20JSON\x20file.'),_0x55b440['_fromPacked']=!0x1,_0x55b440['_packedAndReady']=!0x1;},_0x4f642c['onload']=function(){try{var _0x3d70e2=JSON['parse'](_0x4f642c['response']),_0x421e96=Reflect['ownKeys'](_0x3d70e2['frames']);_0x55b440['_spriteMap']=_0x421e96,_0x55b440['_packedAndReady']=!0x0,_0x55b440['_cellData']=_0x3d70e2['frames'];}catch(_0x1ce825){throw _0x55b440['_fromPacked']=!0x1,_0x55b440['_packedAndReady']=!0x1,new Error('Invalid\x20JSON\x20format.\x20Please\x20check\x20documentation\x20for\x20format\x20specifications.');}},_0x4f642c['send']();}},_0x241f3a['prototype']['_checkTextureAlpha']=function(_0x41a5a1,_0x33ebf6,_0x409718,_0x381a09,_0x30031d){if(!_0x41a5a1['useAlphaForPicking']||!this['texture'])return!0x0;var _0x3ae95a=this['texture']['getSize']();this['_textureContent']||(this['_textureContent']=new Uint8Array(_0x3ae95a['width']*_0x3ae95a['height']*0x4),this['texture']['readPixels'](0x0,0x0,this['_textureContent']));var _0x5ceb72=_0x74d525['c']['Vector3'][0x0];_0x5ceb72['copyFrom'](_0x33ebf6['direction']),_0x5ceb72['normalize'](),_0x5ceb72['scaleInPlace'](_0x409718),_0x5ceb72['addInPlace'](_0x33ebf6['origin']);var _0x2a68ea=(_0x5ceb72['x']-_0x381a09['x'])/(_0x30031d['x']-_0x381a09['x'])-0.5,_0x19034c=0x1-(_0x5ceb72['y']-_0x381a09['y'])/(_0x30031d['y']-_0x381a09['y'])-0.5,_0x204a1c=_0x41a5a1['angle'],_0x532190=_0x2a68ea*Math['cos'](_0x204a1c)-_0x19034c*Math['sin'](_0x204a1c)+0.5,_0x2751ea=_0x2a68ea*Math['sin'](_0x204a1c)+_0x19034c*Math['cos'](_0x204a1c)+0.5,_0x26fa9c=_0x41a5a1['_xOffset']*_0x3ae95a['width']+_0x532190*_0x41a5a1['_xSize']|0x0,_0x47814e=_0x41a5a1['_yOffset']*_0x3ae95a['height']+_0x2751ea*_0x41a5a1['_ySize']|0x0;return this['_textureContent'][0x4*(_0x26fa9c+_0x47814e*_0x3ae95a['width'])+0x3]>0.5;},_0x241f3a['prototype']['intersects']=function(_0x11db7b,_0x4df588,_0x1ee0b3,_0xa926e3){for(var _0x549d3b=Math['min'](this['capacity'],this['sprites']['length']),_0x595aad=_0x74d525['e']['Zero'](),_0x52ea9a=_0x74d525['e']['Zero'](),_0x333904=Number['MAX_VALUE'],_0x2433bb=null,_0x776b02=_0x74d525['c']['Vector3'][0x0],_0x20af35=_0x74d525['c']['Vector3'][0x1],_0x381fb1=_0x4df588['getViewMatrix'](),_0x44b8a7=0x0;_0x44b8a7<_0x549d3b;_0x44b8a7++){var _0x4e0a27=this['sprites'][_0x44b8a7];if(_0x4e0a27){if(_0x1ee0b3){if(!_0x1ee0b3(_0x4e0a27))continue;}else{if(!_0x4e0a27['isPickable'])continue;}if(_0x74d525['e']['TransformCoordinatesToRef'](_0x4e0a27['position'],_0x381fb1,_0x20af35),_0x595aad['copyFromFloats'](_0x20af35['x']-_0x4e0a27['width']/0x2,_0x20af35['y']-_0x4e0a27['height']/0x2,_0x20af35['z']),_0x52ea9a['copyFromFloats'](_0x20af35['x']+_0x4e0a27['width']/0x2,_0x20af35['y']+_0x4e0a27['height']/0x2,_0x20af35['z']),_0x11db7b['intersectsBoxMinMax'](_0x595aad,_0x52ea9a)){var _0x85e7ae=_0x74d525['e']['Distance'](_0x20af35,_0x11db7b['origin']);if(_0x333904>_0x85e7ae){if(!this['_checkTextureAlpha'](_0x4e0a27,_0x11db7b,_0x85e7ae,_0x595aad,_0x52ea9a))continue;if(_0x333904=_0x85e7ae,_0x2433bb=_0x4e0a27,_0xa926e3)break;}}}}if(_0x2433bb){var _0x582ca1=new _0x1fa05e['a']();_0x381fb1['invertToRef'](_0x74d525['c']['Matrix'][0x0]),_0x582ca1['hit']=!0x0,_0x582ca1['pickedSprite']=_0x2433bb,_0x582ca1['distance']=_0x333904;var _0x327204=_0x74d525['c']['Vector3'][0x2];return _0x327204['copyFrom'](_0x11db7b['direction']),_0x327204['normalize'](),_0x327204['scaleInPlace'](_0x333904),_0x11db7b['origin']['addToRef'](_0x327204,_0x776b02),_0x582ca1['pickedPoint']=_0x74d525['e']['TransformCoordinates'](_0x776b02,_0x74d525['c']['Matrix'][0x0]),_0x582ca1;}return null;},_0x241f3a['prototype']['multiIntersects']=function(_0x5c5c24,_0x3986fe,_0x283d23){for(var _0x3ed465,_0x39a85b=Math['min'](this['capacity'],this['sprites']['length']),_0x2f7809=_0x74d525['e']['Zero'](),_0x1d9a15=_0x74d525['e']['Zero'](),_0x2c4f15=[],_0x21f862=_0x74d525['c']['Vector3'][0x0]['copyFromFloats'](0x0,0x0,0x0),_0x1077d4=_0x74d525['c']['Vector3'][0x1]['copyFromFloats'](0x0,0x0,0x0),_0x57c68f=_0x3986fe['getViewMatrix'](),_0x543b1a=0x0;_0x543b1a<_0x39a85b;_0x543b1a++){var _0x46d952=this['sprites'][_0x543b1a];if(_0x46d952){if(_0x283d23){if(!_0x283d23(_0x46d952))continue;}else{if(!_0x46d952['isPickable'])continue;}if(_0x74d525['e']['TransformCoordinatesToRef'](_0x46d952['position'],_0x57c68f,_0x1077d4),_0x2f7809['copyFromFloats'](_0x1077d4['x']-_0x46d952['width']/0x2,_0x1077d4['y']-_0x46d952['height']/0x2,_0x1077d4['z']),_0x1d9a15['copyFromFloats'](_0x1077d4['x']+_0x46d952['width']/0x2,_0x1077d4['y']+_0x46d952['height']/0x2,_0x1077d4['z']),_0x5c5c24['intersectsBoxMinMax'](_0x2f7809,_0x1d9a15)){if(_0x3ed465=_0x74d525['e']['Distance'](_0x1077d4,_0x5c5c24['origin']),!this['_checkTextureAlpha'](_0x46d952,_0x5c5c24,_0x3ed465,_0x2f7809,_0x1d9a15))continue;var _0x15df44=new _0x1fa05e['a']();_0x2c4f15['push'](_0x15df44),_0x57c68f['invertToRef'](_0x74d525['c']['Matrix'][0x0]),_0x15df44['hit']=!0x0,_0x15df44['pickedSprite']=_0x46d952,_0x15df44['distance']=_0x3ed465;var _0x1ebe25=_0x74d525['c']['Vector3'][0x2];_0x1ebe25['copyFrom'](_0x5c5c24['direction']),_0x1ebe25['normalize'](),_0x1ebe25['scaleInPlace'](_0x3ed465),_0x5c5c24['origin']['addToRef'](_0x1ebe25,_0x21f862),_0x15df44['pickedPoint']=_0x74d525['e']['TransformCoordinates'](_0x21f862,_0x74d525['c']['Matrix'][0x0]);}}}return _0x2c4f15;},_0x241f3a['prototype']['render']=function(){if(!this['_fromPacked']||this['_packedAndReady']&&this['_spriteMap']&&this['_cellData']){var _0x2ddba4=this['_scene']['getEngine']()['getDeltaTime']();this['_packedAndReady']?this['_spriteRenderer']['render'](this['sprites'],_0x2ddba4,this['_scene']['getViewMatrix'](),this['_scene']['getProjectionMatrix'](),this['_customUpdate']):this['_spriteRenderer']['render'](this['sprites'],_0x2ddba4,this['_scene']['getViewMatrix'](),this['_scene']['getProjectionMatrix']());}},_0x241f3a['prototype']['dispose']=function(){this['_spriteRenderer']&&(this['_spriteRenderer']['dispose'](),this['_spriteRenderer']=null),this['_textureContent']=null;var _0x1a1f0c=this['_scene']['spriteManagers']['indexOf'](this);this['_scene']['spriteManagers']['splice'](_0x1a1f0c,0x1),this['onDisposeObservable']['notifyObservers'](this),this['onDisposeObservable']['clear']();},_0x241f3a['prototype']['serialize']=function(_0x906956){void 0x0===_0x906956&&(_0x906956=!0x1);var _0x97aa97={};_0x97aa97['name']=this['name'],_0x97aa97['capacity']=this['capacity'],_0x97aa97['cellWidth']=this['cellWidth'],_0x97aa97['cellHeight']=this['cellHeight'],this['texture']&&(_0x906956?_0x97aa97['texture']=this['texture']['serialize']():(_0x97aa97['textureUrl']=this['texture']['name'],_0x97aa97['invertY']=this['texture']['_invertY'])),_0x97aa97['sprites']=[];for(var _0x59d1d9=0x0,_0x91a442=this['sprites'];_0x59d1d9<_0x91a442['length'];_0x59d1d9++){var _0x3eda04=_0x91a442[_0x59d1d9];_0x97aa97['sprites']['push'](_0x3eda04['serialize']());}return _0x97aa97;},_0x241f3a['Parse']=function(_0x4eff1d,_0x14b3a9,_0x3a4a7c){var _0x1a860f=new _0x241f3a(_0x4eff1d['name'],'',_0x4eff1d['capacity'],{'width':_0x4eff1d['cellWidth'],'height':_0x4eff1d['cellHeight']},_0x14b3a9);_0x4eff1d['texture']?_0x1a860f['texture']=_0xaf3c80['a']['Parse'](_0x4eff1d['texture'],_0x14b3a9,_0x3a4a7c):_0x4eff1d['textureName']&&(_0x1a860f['texture']=new _0xaf3c80['a'](_0x3a4a7c+_0x4eff1d['textureUrl'],_0x14b3a9,!0x1,void 0x0===_0x4eff1d['invertY']||_0x4eff1d['invertY']));for(var _0x2fe3c7=0x0,_0xbd91d=_0x4eff1d['sprites'];_0x2fe3c7<_0xbd91d['length'];_0x2fe3c7++){var _0x11aeaf=_0xbd91d[_0x2fe3c7];_0x181037['Parse'](_0x11aeaf,_0x1a860f);}return _0x1a860f;},_0x241f3a['ParseFromFileAsync']=function(_0x5105f8,_0xf3047b,_0x51773a,_0x2f3abb){return void 0x0===_0x2f3abb&&(_0x2f3abb=''),new Promise(function(_0x295bc1,_0x2912d6){var _0x49b88f=new _0x25cf22['a']();_0x49b88f['addEventListener']('readystatechange',function(){if(0x4==_0x49b88f['readyState']){if(0xc8==_0x49b88f['status']){var _0x388057=JSON['parse'](_0x49b88f['responseText']),_0x2b5ed5=_0x241f3a['Parse'](_0x388057,_0x51773a||_0x300b38['a']['LastCreatedScene'],_0x2f3abb);_0x5105f8&&(_0x2b5ed5['name']=_0x5105f8),_0x295bc1(_0x2b5ed5);}else _0x2912d6('Unable\x20to\x20load\x20the\x20sprite\x20manager');}}),_0x49b88f['open']('GET',_0xf3047b),_0x49b88f['send']();});},_0x241f3a['CreateFromSnippetAsync']=function(_0x4762ea,_0x29874b,_0x4eabfe){var _0x42c11c=this;return void 0x0===_0x4eabfe&&(_0x4eabfe=''),'_BLANK'===_0x4762ea?Promise['resolve'](new _0x241f3a('Default\x20sprite\x20manager','//playground.babylonjs.com/textures/player.png',0x1f4,0x40,_0x29874b)):new Promise(function(_0x3dcf04,_0x39649b){var _0xe19dc5=new _0x25cf22['a']();_0xe19dc5['addEventListener']('readystatechange',function(){if(0x4==_0xe19dc5['readyState']){if(0xc8==_0xe19dc5['status']){var _0x1a0232=JSON['parse'](JSON['parse'](_0xe19dc5['responseText'])['jsonPayload']),_0x119df7=JSON['parse'](_0x1a0232['spriteManager']),_0xa76635=_0x241f3a['Parse'](_0x119df7,_0x29874b||_0x300b38['a']['LastCreatedScene'],_0x4eabfe);_0xa76635['snippetId']=_0x4762ea,_0x3dcf04(_0xa76635);}else _0x39649b('Unable\x20to\x20load\x20the\x20snippet\x20'+_0x4762ea);}}),_0xe19dc5['open']('GET',_0x42c11c['SnippetUrl']+'/'+_0x4762ea['replace'](/#/g,'/')),_0xe19dc5['send']();});},_0x241f3a['SnippetUrl']='https://snippet.babylonjs.com',_0x241f3a;}()),_0x37035a='precision\x20highp\x20float;\x0avarying\x20vec3\x20vPosition;\x0avarying\x20vec2\x20vUV;\x0avarying\x20vec2\x20tUV;\x0auniform\x20float\x20time;\x0auniform\x20float\x20spriteCount;\x0auniform\x20sampler2D\x20spriteSheet;\x0auniform\x20vec2\x20spriteMapSize;\x0auniform\x20vec2\x20outputSize;\x0auniform\x20vec2\x20stageSize;\x0auniform\x20sampler2D\x20frameMap;\x0auniform\x20sampler2D\x20tileMaps[LAYERS];\x0auniform\x20sampler2D\x20animationMap;\x0auniform\x20vec3\x20colorMul;\x0afloat\x20mt;\x0aconst\x20float\x20fdStep=1./4.;\x0aconst\x20float\x20aFrameSteps=1./MAX_ANIMATION_FRAMES;\x0amat4\x20getFrameData(float\x20frameID){\x0afloat\x20fX=frameID/spriteCount;\x0areturn\x20mat4(\x0atexture2D(frameMap,vec2(fX,0.),0.),\x0atexture2D(frameMap,vec2(fX,fdStep*1.),0.),\x0atexture2D(frameMap,vec2(fX,fdStep*2.),0.),\x0avec4(0.)\x0a);\x0a}\x0avoid\x20main(){\x0avec4\x20color=vec4(0.);\x0avec2\x20tileUV=fract(tUV);\x0a#ifdef\x20FLIPU\x0atileUV.y=1.0-tileUV.y;\x0a#endif\x0avec2\x20tileID=floor(tUV);\x0avec2\x20sheetUnits=1./spriteMapSize;\x0afloat\x20spriteUnits=1./spriteCount;\x0avec2\x20stageUnits=1./stageSize;\x0afor(int\x20i=0;\x20i0.)\x20{\x0amt=mod(time*animationData.z,1.0);\x0afor(float\x20f=0.;\x20fmt){\x0aframeID=animationData.x;\x0abreak;\x0a}\x0aanimationData=texture2D(animationMap,vec2((frameID+0.5)/spriteCount,aFrameSteps*f),0.);\x0a}\x0a}\x0a\x0amat4\x20frameData=getFrameData(frameID+0.5);\x0avec2\x20frameSize=(frameData[0].wz)/spriteMapSize;\x0avec2\x20offset=frameData[0].xy*sheetUnits;\x0avec2\x20ratio=frameData[2].xy/frameData[0].wz;\x0a\x0aif\x20(frameData[2].z\x20==\x201.){\x0atileUV.xy=tileUV.yx;\x0a}\x0aif\x20(i\x20==\x200){\x0acolor=texture2D(spriteSheet,tileUV*frameSize+offset);\x0a}\x20else\x20{\x0avec4\x20nc=texture2D(spriteSheet,tileUV*frameSize+offset);\x0afloat\x20alpha=min(color.a+nc.a,1.0);\x0avec3\x20mixed=mix(color.xyz,nc.xyz,nc.a);\x0acolor=vec4(mixed,alpha);\x0a}\x0a}\x0acolor.xyz*=colorMul;\x0agl_FragColor=color;\x0a}';_0x494b01['a']['ShadersStore']['spriteMapPixelShader']=_0x37035a;var _0x222e6e='precision\x20highp\x20float;\x0a\x0aattribute\x20vec3\x20position;\x0aattribute\x20vec3\x20normal;\x0aattribute\x20vec2\x20uv;\x0a\x0avarying\x20vec3\x20vPosition;\x0avarying\x20vec2\x20vUV;\x0avarying\x20vec2\x20tUV;\x0avarying\x20vec2\x20stageUnits;\x0avarying\x20vec2\x20levelUnits;\x0avarying\x20vec2\x20tileID;\x0a\x0auniform\x20float\x20time;\x0auniform\x20mat4\x20worldViewProjection;\x0auniform\x20vec2\x20outputSize;\x0auniform\x20vec2\x20stageSize;\x0auniform\x20vec2\x20spriteMapSize;\x0auniform\x20float\x20stageScale;\x0avoid\x20main()\x20{\x0avec4\x20p=vec4(\x20position,1.\x20);\x0avPosition=p.xyz;\x0avUV=uv;\x0atUV=uv*stageSize;\x0agl_Position=worldViewProjection*p;\x0a}';_0x494b01['a']['ShadersStore']['spriteMapVertexShader']=_0x222e6e;var _0x2fdd8f,_0xab3fb1=(function(){function _0x231b7d(_0x4787cb,_0x47eba7,_0x4cacda,_0x3ff394,_0x1022af){var _0x395f4e=this;this['name']=_0x4787cb,this['sprites']=[],this['atlasJSON']=_0x47eba7,this['sprites']=this['atlasJSON']['frames'],this['spriteSheet']=_0x4cacda,this['options']=_0x3ff394,_0x3ff394['stageSize']=_0x3ff394['stageSize']||new _0x74d525['d'](0x1,0x1),_0x3ff394['outputSize']=_0x3ff394['outputSize']||_0x3ff394['stageSize'],_0x3ff394['outputPosition']=_0x3ff394['outputPosition']||_0x74d525['e']['Zero'](),_0x3ff394['outputRotation']=_0x3ff394['outputRotation']||_0x74d525['e']['Zero'](),_0x3ff394['layerCount']=_0x3ff394['layerCount']||0x1,_0x3ff394['maxAnimationFrames']=_0x3ff394['maxAnimationFrames']||0x0,_0x3ff394['baseTile']=_0x3ff394['baseTile']||0x0,_0x3ff394['flipU']=_0x3ff394['flipU']||!0x1,_0x3ff394['colorMultiply']=_0x3ff394['colorMultiply']||new _0x74d525['e'](0x1,0x1,0x1),this['_scene']=_0x1022af,this['_frameMap']=this['_createFrameBuffer'](),this['_tileMaps']=new Array();for(var _0x4b7ebd=0x0;_0x4b7ebd<_0x3ff394['layerCount'];_0x4b7ebd++)this['_tileMaps']['push'](this['_createTileBuffer'](null,_0x4b7ebd));this['_animationMap']=this['_createTileAnimationBuffer'](null);var _0xced264=[];_0xced264['push']('#define\x20LAYERS\x20'+_0x3ff394['layerCount']),_0x3ff394['flipU']&&_0xced264['push']('#define\x20FLIPU'),_0xced264['push']('#define\x20MAX_ANIMATION_FRAMES\x20'+_0x3ff394['maxAnimationFrames']+'.0');var _0x340b14,_0x15f2c8=_0x494b01['a']['ShadersStore']['spriteMapPixelShader'];if(0x1===this['_scene']['getEngine']()['webGLVersion']){_0x340b14='';for(_0x4b7ebd=0x0;_0x4b7ebd<_0x3ff394['layerCount'];_0x4b7ebd++)_0x340b14+='if\x20('+_0x4b7ebd+'\x20==\x20i)\x20{\x20frameID\x20=\x20texture2D(tileMaps['+_0x4b7ebd+'],\x20(tileID\x20+\x200.5)\x20/\x20stageSize,\x200.).x;\x20}';}else{_0x340b14='switch(i)\x20{';for(_0x4b7ebd=0x0;_0x4b7ebd<_0x3ff394['layerCount'];_0x4b7ebd++)_0x340b14+='case\x20'+_0x4b7ebd+'\x20:\x20frameID\x20=\x20texture(tileMaps['+_0x4b7ebd+'],\x20(tileID\x20+\x200.5)\x20/\x20stageSize,\x200.).x;',_0x340b14+='break;';_0x340b14+='}';}_0x494b01['a']['ShadersStore']['spriteMap'+this['name']+'PixelShader']=_0x15f2c8['replace']('#define\x20LAYER_ID_SWITCH',_0x340b14),this['_material']=new _0x14ee07['a']('spriteMap:'+this['name'],this['_scene'],{'vertex':'spriteMap','fragment':'spriteMap'+this['name']},{'defines':_0xced264,'attributes':['position','normal','uv'],'uniforms':['worldViewProjection','time','stageSize','outputSize','spriteMapSize','spriteCount','time','colorMul','mousePosition','curTile','flipU'],'samplers':['spriteSheet','frameMap','tileMaps','animationMap'],'needAlphaBlending':!0x0}),this['_time']=0x0,this['_material']['setFloat']('spriteCount',this['spriteCount']),this['_material']['setVector2']('stageSize',_0x3ff394['stageSize']),this['_material']['setVector2']('outputSize',_0x3ff394['outputSize']),this['_material']['setTexture']('spriteSheet',this['spriteSheet']),this['_material']['setVector2']('spriteMapSize',new _0x74d525['d'](0x1,0x1)),this['_material']['setVector3']('colorMul',_0x3ff394['colorMultiply']);var _0x12f035=0x0,_0x1b2bc7=function(){_0x395f4e['spriteSheet']&&_0x395f4e['spriteSheet']['isReady']()&&_0x395f4e['spriteSheet']['_texture']?_0x395f4e['_material']['setVector2']('spriteMapSize',new _0x74d525['d'](_0x395f4e['spriteSheet']['_texture']['baseWidth']||0x1,_0x395f4e['spriteSheet']['_texture']['baseHeight']||0x1)):_0x12f035<0x64&&setTimeout(function(){_0x12f035++,_0x1b2bc7();},0x64);};_0x1b2bc7(),this['_material']['setVector3']('colorMul',_0x3ff394['colorMultiply']),this['_material']['setTexture']('frameMap',this['_frameMap']),this['_material']['setTextureArray']('tileMaps',this['_tileMaps']),this['_material']['setTexture']('animationMap',this['_animationMap']),this['_material']['setFloat']('time',this['_time']),this['_output']=_0x3cf5e5['a']['CreatePlane'](_0x4787cb+':output',0x1,_0x1022af,!0x0),this['_output']['scaling']['x']=_0x3ff394['outputSize']['x'],this['_output']['scaling']['y']=_0x3ff394['outputSize']['y'],this['position']=_0x3ff394['outputPosition'],this['rotation']=_0x3ff394['outputRotation'],(this['_scene']['onBeforeRenderObservable']['add'](function(){_0x395f4e['_time']+=_0x395f4e['_scene']['getEngine']()['getDeltaTime'](),_0x395f4e['_material']['setFloat']('time',_0x395f4e['_time']);}),this['_output']['material']=this['_material']);}return Object['defineProperty'](_0x231b7d['prototype'],'spriteCount',{'get':function(){return this['sprites']['length'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x231b7d['prototype'],'position',{'get':function(){return this['_output']['position'];},'set':function(_0x428578){this['_output']['position']=_0x428578;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x231b7d['prototype'],'rotation',{'get':function(){return this['_output']['rotation'];},'set':function(_0x43eecd){this['_output']['rotation']=_0x43eecd;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x231b7d['prototype'],'animationMap',{'get':function(){return this['_animationMap'];},'set':function(_0x272c1d){var _0x37c5d9=_0x272c1d['_texture']['_bufferView'],_0x35536d=this['_createTileAnimationBuffer'](_0x37c5d9);this['_animationMap']['dispose'](),this['_animationMap']=_0x35536d,this['_material']['setTexture']('animationMap',this['_animationMap']);},'enumerable':!0x1,'configurable':!0x0}),_0x231b7d['prototype']['getTileID']=function(){var _0x3fa08b=this['getMousePosition']();return _0x3fa08b['multiplyInPlace'](this['options']['stageSize']||_0x74d525['d']['Zero']()),_0x3fa08b['x']=Math['floor'](_0x3fa08b['x']),_0x3fa08b['y']=Math['floor'](_0x3fa08b['y']),_0x3fa08b;},_0x231b7d['prototype']['getMousePosition']=function(){var _0x39de69=this['_output'],_0x508979=this['_scene']['pick'](this['_scene']['pointerX'],this['_scene']['pointerY'],function(_0x34b1fc){return _0x34b1fc===_0x39de69;});if(!_0x508979||!_0x508979['hit']||!_0x508979['getTextureCoordinates'])return new _0x74d525['d'](-0x1,-0x1);var _0x48cdb2=_0x508979['getTextureCoordinates']();return _0x48cdb2||new _0x74d525['d'](-0x1,-0x1);},_0x231b7d['prototype']['_createFrameBuffer']=function(){for(var _0x2a39fc=new Array(),_0x39a822=0x0;_0x39a8220x0&&(_0x3f5f96+='\x0a\x0d'),_0x3f5f96+=this['_tileMaps'][_0x3a052a]['_texture']['_bufferView']['toString']();var _0x439696=document['createElement']('a');_0x439696['href']='data:octet/stream;charset=utf-8,'+encodeURI(_0x3f5f96),_0x439696['target']='_blank',_0x439696['download']=this['name']+'.tilemaps',_0x439696['click'](),_0x439696['remove']();},_0x231b7d['prototype']['loadTileMaps']=function(_0x32fd2d){var _0x5cf5a6=this,_0x18c9be=new XMLHttpRequest();_0x18c9be['open']('GET',_0x32fd2d);var _0x180af4=this['options']['layerCount']||0x0;_0x18c9be['onload']=function(){for(var _0x51b259=_0x18c9be['response']['split']('\x0a\x0d'),_0x119bba=0x0;_0x119bba<_0x180af4;_0x119bba++){var _0x51ef9e=_0x51b259[_0x119bba]['split'](',')['map'](Number),_0x40ed68=_0x5cf5a6['_createTileBuffer'](_0x51ef9e);_0x5cf5a6['_tileMaps'][_0x119bba]['dispose'](),_0x5cf5a6['_tileMaps'][_0x119bba]=_0x40ed68;}_0x5cf5a6['_material']['setTextureArray']('tileMap',_0x5cf5a6['_tileMaps']);},_0x18c9be['send']();},_0x231b7d['prototype']['dispose']=function(){this['_output']['dispose'](),this['_material']['dispose'](),this['_animationMap']['dispose'](),this['_tileMaps']['forEach'](function(_0x494d2d){_0x494d2d['dispose']();}),this['_frameMap']['dispose']();},_0x231b7d;}()),_0x23ee96=function(_0x4be5b5){function _0x2c79a0(_0x19014c,_0xce2b13,_0x1490b0,_0x358257,_0x1d5202,_0x4f3f14,_0x1af931){void 0x0===_0x1d5202&&(_0x1d5202=null),void 0x0===_0x4f3f14&&(_0x4f3f14=0.01),void 0x0===_0x1af931&&(_0x1af931=_0xaf3c80['a']['TRILINEAR_SAMPLINGMODE']);var _0xc976ce=_0x4be5b5['call'](this,_0x19014c,_0xce2b13,_0x1490b0,0x40,_0x358257,_0x4f3f14,_0x1af931,!0x0,_0x1d5202)||this;return _0xc976ce['name']=_0x19014c,_0xc976ce;}return Object(_0x18e13d['d'])(_0x2c79a0,_0x4be5b5),_0x2c79a0;}(_0x15f119),_0x3b3d42=_0x162675(0x8f),_0x30319a=_0x162675(0x8d),_0x47270c=_0x162675(0x8e),_0x18e05a=_0x162675(0x8b);!function(_0x162a64){_0x162a64[_0x162a64['INIT']=0x0]='INIT',_0x162a64[_0x162a64['RUNNING']=0x1]='RUNNING',_0x162a64[_0x162a64['DONE']=0x2]='DONE',_0x162a64[_0x162a64['ERROR']=0x3]='ERROR';}(_0x2fdd8f||(_0x2fdd8f={}));var _0x387f88,_0x822dce=(function(){function _0x2e21e4(_0x278fe7){this['name']=_0x278fe7,this['_isCompleted']=!0x1,this['_taskState']=_0x2fdd8f['INIT'];}return Object['defineProperty'](_0x2e21e4['prototype'],'isCompleted',{'get':function(){return this['_isCompleted'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2e21e4['prototype'],'taskState',{'get':function(){return this['_taskState'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x2e21e4['prototype'],'errorObject',{'get':function(){return this['_errorObject'];},'enumerable':!0x1,'configurable':!0x0}),_0x2e21e4['prototype']['_setErrorObject']=function(_0x54a66d,_0x53d21a){this['_errorObject']||(this['_errorObject']={'message':_0x54a66d,'exception':_0x53d21a});},_0x2e21e4['prototype']['run']=function(_0x356214,_0x4e835d,_0x4e77bf){var _0x2a9047=this;this['_taskState']=_0x2fdd8f['RUNNING'],this['runTask'](_0x356214,function(){_0x2a9047['onDoneCallback'](_0x4e835d,_0x4e77bf);},function(_0x88415b,_0x10af73){_0x2a9047['onErrorCallback'](_0x4e77bf,_0x88415b,_0x10af73);});},_0x2e21e4['prototype']['runTask']=function(_0x728c1a,_0x27657f,_0x11a2fe){throw new Error('runTask\x20is\x20not\x20implemented');},_0x2e21e4['prototype']['reset']=function(){this['_taskState']=_0x2fdd8f['INIT'];},_0x2e21e4['prototype']['onErrorCallback']=function(_0x1f738b,_0x4f7286,_0x1a7453){this['_taskState']=_0x2fdd8f['ERROR'],this['_errorObject']={'message':_0x4f7286,'exception':_0x1a7453},this['onError']&&this['onError'](this,_0x4f7286,_0x1a7453),_0x1f738b();},_0x2e21e4['prototype']['onDoneCallback']=function(_0x8cdfc1,_0x6a7dff){try{this['_taskState']=_0x2fdd8f['DONE'],this['_isCompleted']=!0x0,this['onSuccess']&&this['onSuccess'](this),_0x8cdfc1();}catch(_0x22b06f){this['onErrorCallback'](_0x6a7dff,'Task\x20is\x20done,\x20error\x20executing\x20success\x20callback(s)',_0x22b06f);}},_0x2e21e4;}()),_0x4c658d=function(_0x36be35,_0x5ba517,_0x1174ba){this['remainingCount']=_0x36be35,this['totalCount']=_0x5ba517,this['task']=_0x1174ba;},_0x2c9bee=function(_0x34ba5b){function _0x2ce1dc(_0x1ac483,_0x3db304,_0x296881,_0xaa0845){var _0x170fcf=_0x34ba5b['call'](this,_0x1ac483)||this;return _0x170fcf['name']=_0x1ac483,_0x170fcf['meshesNames']=_0x3db304,_0x170fcf['rootUrl']=_0x296881,_0x170fcf['sceneFilename']=_0xaa0845,_0x170fcf;}return Object(_0x18e13d['d'])(_0x2ce1dc,_0x34ba5b),_0x2ce1dc['prototype']['runTask']=function(_0x4a58ef,_0x3c8f7c,_0x2bf40c){var _0x4eff1e=this;_0x5de01e['LoadAssetContainer'](this['rootUrl'],this['sceneFilename'],_0x4a58ef,function(_0x39d112){_0x4eff1e['loadedContainer']=_0x39d112,_0x4eff1e['loadedMeshes']=_0x39d112['meshes'],_0x4eff1e['loadedParticleSystems']=_0x39d112['particleSystems'],_0x4eff1e['loadedSkeletons']=_0x39d112['skeletons'],_0x4eff1e['loadedAnimationGroups']=_0x39d112['animationGroups'],_0x3c8f7c();},null,function(_0x2adc6a,_0x84e9dd,_0x28defe){_0x2bf40c(_0x84e9dd,_0x28defe);});},_0x2ce1dc;}(_0x822dce),_0x182209=function(_0x320484){function _0xe4a4f8(_0x363c16,_0x1b51b6,_0x16b791,_0x5a35f1){var _0x4ba7c9=_0x320484['call'](this,_0x363c16)||this;return _0x4ba7c9['name']=_0x363c16,_0x4ba7c9['meshesNames']=_0x1b51b6,_0x4ba7c9['rootUrl']=_0x16b791,_0x4ba7c9['sceneFilename']=_0x5a35f1,_0x4ba7c9;}return Object(_0x18e13d['d'])(_0xe4a4f8,_0x320484),_0xe4a4f8['prototype']['runTask']=function(_0x7361a,_0x521729,_0x48673d){var _0x234a47=this;_0x5de01e['ImportMesh'](this['meshesNames'],this['rootUrl'],this['sceneFilename'],_0x7361a,function(_0x327a00,_0x368be8,_0x13679a,_0x247d6a){_0x234a47['loadedMeshes']=_0x327a00,_0x234a47['loadedParticleSystems']=_0x368be8,_0x234a47['loadedSkeletons']=_0x13679a,_0x234a47['loadedAnimationGroups']=_0x247d6a,_0x521729();},null,function(_0x11ac02,_0x27d1ce,_0x124926){_0x48673d(_0x27d1ce,_0x124926);});},_0xe4a4f8;}(_0x822dce),_0x8db0a1=function(_0x57aea7){function _0x4d7853(_0x11e314,_0x1c438b){var _0xaee3a4=_0x57aea7['call'](this,_0x11e314)||this;return _0xaee3a4['name']=_0x11e314,_0xaee3a4['url']=_0x1c438b,_0xaee3a4;}return Object(_0x18e13d['d'])(_0x4d7853,_0x57aea7),_0x4d7853['prototype']['runTask']=function(_0x580d26,_0x3b8f65,_0x553495){var _0x3d0979=this;_0x580d26['_loadFile'](this['url'],function(_0x2d35d9){_0x3d0979['text']=_0x2d35d9,_0x3b8f65();},void 0x0,!0x1,!0x1,function(_0x1a1973,_0x2cbb81){_0x1a1973&&_0x553495(_0x1a1973['status']+'\x20'+_0x1a1973['statusText'],_0x2cbb81);});},_0x4d7853;}(_0x822dce),_0x395535=function(_0x35703e){function _0x163461(_0x23961e,_0x5a998d){var _0x1473c7=_0x35703e['call'](this,_0x23961e)||this;return _0x1473c7['name']=_0x23961e,_0x1473c7['url']=_0x5a998d,_0x1473c7;}return Object(_0x18e13d['d'])(_0x163461,_0x35703e),_0x163461['prototype']['runTask']=function(_0x42a0c6,_0xecd5d2,_0x529140){var _0x1899f4=this;_0x42a0c6['_loadFile'](this['url'],function(_0x1ec246){_0x1899f4['data']=_0x1ec246,_0xecd5d2();},void 0x0,!0x0,!0x0,function(_0x4e2b61,_0x2e4f8d){_0x4e2b61&&_0x529140(_0x4e2b61['status']+'\x20'+_0x4e2b61['statusText'],_0x2e4f8d);});},_0x163461;}(_0x822dce),_0xf62d4b=function(_0x5dac87){function _0x4766ea(_0x138a24,_0x272d5a){var _0x51f57e=_0x5dac87['call'](this,_0x138a24)||this;return _0x51f57e['name']=_0x138a24,_0x51f57e['url']=_0x272d5a,_0x51f57e;}return Object(_0x18e13d['d'])(_0x4766ea,_0x5dac87),_0x4766ea['prototype']['runTask']=function(_0xa67b6d,_0x23ebd1,_0x3cff2d){var _0x5829e0=this,_0x45a40c=new Image();_0x5d754c['b']['SetCorsBehavior'](this['url'],_0x45a40c),_0x45a40c['onload']=function(){_0x5829e0['image']=_0x45a40c,_0x23ebd1();},_0x45a40c['onerror']=function(_0x2184cb){_0x3cff2d('Error\x20loading\x20image',_0x2184cb);},_0x45a40c['src']=this['url'];},_0x4766ea;}(_0x822dce),_0x1f67ec=function(_0xbd3408){function _0x586a5b(_0x2c5150,_0x1840cb,_0x4498ec,_0x455e41,_0x4a566b){void 0x0===_0x455e41&&(_0x455e41=!0x0),void 0x0===_0x4a566b&&(_0x4a566b=_0xaf3c80['a']['TRILINEAR_SAMPLINGMODE']);var _0x3c4e3f=_0xbd3408['call'](this,_0x2c5150)||this;return _0x3c4e3f['name']=_0x2c5150,_0x3c4e3f['url']=_0x1840cb,_0x3c4e3f['noMipmap']=_0x4498ec,_0x3c4e3f['invertY']=_0x455e41,_0x3c4e3f['samplingMode']=_0x4a566b,_0x3c4e3f;}return Object(_0x18e13d['d'])(_0x586a5b,_0xbd3408),_0x586a5b['prototype']['runTask']=function(_0x466195,_0x34328f,_0x377f67){this['texture']=new _0xaf3c80['a'](this['url'],_0x466195,this['noMipmap'],this['invertY'],this['samplingMode'],function(){_0x34328f();},function(_0xf57e26,_0x254edd){_0x377f67(_0xf57e26,_0x254edd);});},_0x586a5b;}(_0x822dce),_0x4dda1a=function(_0x1dbd48){function _0x5a0b45(_0x5b4ecf,_0x415aef,_0x3f02ed,_0x2c823c,_0x1221b9){var _0x1123ef=_0x1dbd48['call'](this,_0x5b4ecf)||this;return _0x1123ef['name']=_0x5b4ecf,_0x1123ef['url']=_0x415aef,_0x1123ef['extensions']=_0x3f02ed,_0x1123ef['noMipmap']=_0x2c823c,_0x1123ef['files']=_0x1221b9,_0x1123ef;}return Object(_0x18e13d['d'])(_0x5a0b45,_0x1dbd48),_0x5a0b45['prototype']['runTask']=function(_0x4c06e1,_0x3ed559,_0x776ad4){this['texture']=new _0x33892f(this['url'],_0x4c06e1,this['extensions'],this['noMipmap'],this['files'],function(){_0x3ed559();},function(_0xd2210d,_0x27ab7a){_0x776ad4(_0xd2210d,_0x27ab7a);});},_0x5a0b45;}(_0x822dce),_0x479df4=function(_0x2bc07b){function _0x28e7d1(_0x382044,_0xc20f5b,_0x4661b3,_0x417a75,_0x4af53a,_0x1e15f,_0x28d7ab){void 0x0===_0x417a75&&(_0x417a75=!0x1),void 0x0===_0x4af53a&&(_0x4af53a=!0x0),void 0x0===_0x1e15f&&(_0x1e15f=!0x1),void 0x0===_0x28d7ab&&(_0x28d7ab=!0x1);var _0x491a8a=_0x2bc07b['call'](this,_0x382044)||this;return _0x491a8a['name']=_0x382044,_0x491a8a['url']=_0xc20f5b,_0x491a8a['size']=_0x4661b3,_0x491a8a['noMipmap']=_0x417a75,_0x491a8a['generateHarmonics']=_0x4af53a,_0x491a8a['gammaSpace']=_0x1e15f,_0x491a8a['reserved']=_0x28d7ab,_0x491a8a;}return Object(_0x18e13d['d'])(_0x28e7d1,_0x2bc07b),_0x28e7d1['prototype']['runTask']=function(_0x4b8bae,_0x357bb6,_0xf2df38){this['texture']=new _0x26e1bc(this['url'],_0x4b8bae,this['size'],this['noMipmap'],this['generateHarmonics'],this['gammaSpace'],this['reserved'],function(){_0x357bb6();},function(_0x2b07a1,_0x3c4cfa){_0xf2df38(_0x2b07a1,_0x3c4cfa);});},_0x28e7d1;}(_0x822dce),_0x7ac95a=function(_0xe334bb){function _0x347403(_0x4b2a32,_0x566334,_0x5c0ecf,_0x2af650,_0x79b9eb){void 0x0===_0x2af650&&(_0x2af650=!0x1),void 0x0===_0x79b9eb&&(_0x79b9eb=!0x0);var _0x417463=_0xe334bb['call'](this,_0x4b2a32)||this;return _0x417463['name']=_0x4b2a32,_0x417463['url']=_0x566334,_0x417463['size']=_0x5c0ecf,_0x417463['noMipmap']=_0x2af650,_0x417463['gammaSpace']=_0x79b9eb,_0x417463;}return Object(_0x18e13d['d'])(_0x347403,_0xe334bb),_0x347403['prototype']['runTask']=function(_0x38e68c,_0xad85c9,_0x4362b7){this['texture']=new _0x5beaea(this['url'],_0x38e68c,this['size'],this['noMipmap'],this['gammaSpace'],function(){_0xad85c9();},function(_0xecdcb0,_0x2b00e4){_0x4362b7(_0xecdcb0,_0x2b00e4);});},_0x347403;}(_0x822dce),_0xe5d1bb=(function(){function _0x1e6702(_0x3b4154){this['_isLoading']=!0x1,this['_tasks']=new Array(),this['_waitingTasksCount']=0x0,this['_totalTasksCount']=0x0,this['onTaskSuccessObservable']=new _0x6ac1f7['c'](),this['onTaskErrorObservable']=new _0x6ac1f7['c'](),this['onTasksDoneObservable']=new _0x6ac1f7['c'](),this['onProgressObservable']=new _0x6ac1f7['c'](),this['useDefaultLoadingScreen']=!0x0,this['autoHideLoadingUI']=!0x0,this['_scene']=_0x3b4154;}return _0x1e6702['prototype']['addContainerTask']=function(_0xd53ccf,_0x18b992,_0x1599de,_0x1587f4){var _0x1f51dc=new _0x2c9bee(_0xd53ccf,_0x18b992,_0x1599de,_0x1587f4);return this['_tasks']['push'](_0x1f51dc),_0x1f51dc;},_0x1e6702['prototype']['addMeshTask']=function(_0x523337,_0x18daed,_0x3c89d4,_0x592307){var _0x86db63=new _0x182209(_0x523337,_0x18daed,_0x3c89d4,_0x592307);return this['_tasks']['push'](_0x86db63),_0x86db63;},_0x1e6702['prototype']['addTextFileTask']=function(_0x378891,_0x292eb4){var _0x1bcd0c=new _0x8db0a1(_0x378891,_0x292eb4);return this['_tasks']['push'](_0x1bcd0c),_0x1bcd0c;},_0x1e6702['prototype']['addBinaryFileTask']=function(_0x374f3f,_0x26b639){var _0x57ddcb=new _0x395535(_0x374f3f,_0x26b639);return this['_tasks']['push'](_0x57ddcb),_0x57ddcb;},_0x1e6702['prototype']['addImageTask']=function(_0x15f930,_0x2016dc){var _0x1ef8e8=new _0xf62d4b(_0x15f930,_0x2016dc);return this['_tasks']['push'](_0x1ef8e8),_0x1ef8e8;},_0x1e6702['prototype']['addTextureTask']=function(_0x3d9454,_0x1dd25c,_0x51423e,_0x1d44d9,_0x1bfbe8){void 0x0===_0x1bfbe8&&(_0x1bfbe8=_0xaf3c80['a']['TRILINEAR_SAMPLINGMODE']);var _0x29c136=new _0x1f67ec(_0x3d9454,_0x1dd25c,_0x51423e,_0x1d44d9,_0x1bfbe8);return this['_tasks']['push'](_0x29c136),_0x29c136;},_0x1e6702['prototype']['addCubeTextureTask']=function(_0xdc7106,_0x247287,_0x1144bb,_0x428cd2,_0x52d9ed){var _0x167ec5=new _0x4dda1a(_0xdc7106,_0x247287,_0x1144bb,_0x428cd2,_0x52d9ed);return this['_tasks']['push'](_0x167ec5),_0x167ec5;},_0x1e6702['prototype']['addHDRCubeTextureTask']=function(_0x5d4d27,_0x41f786,_0xec26e1,_0x2be054,_0x1edc3f,_0x2e96c4,_0x2718b6){void 0x0===_0x2be054&&(_0x2be054=!0x1),void 0x0===_0x1edc3f&&(_0x1edc3f=!0x0),void 0x0===_0x2e96c4&&(_0x2e96c4=!0x1),void 0x0===_0x2718b6&&(_0x2718b6=!0x1);var _0x19167e=new _0x479df4(_0x5d4d27,_0x41f786,_0xec26e1,_0x2be054,_0x1edc3f,_0x2e96c4,_0x2718b6);return this['_tasks']['push'](_0x19167e),_0x19167e;},_0x1e6702['prototype']['addEquiRectangularCubeTextureAssetTask']=function(_0x1fe95f,_0x5c124c,_0x44175f,_0x2a9e16,_0x23a3dd){void 0x0===_0x2a9e16&&(_0x2a9e16=!0x1),void 0x0===_0x23a3dd&&(_0x23a3dd=!0x0);var _0xb8aaa6=new _0x7ac95a(_0x1fe95f,_0x5c124c,_0x44175f,_0x2a9e16,_0x23a3dd);return this['_tasks']['push'](_0xb8aaa6),_0xb8aaa6;},_0x1e6702['prototype']['removeTask']=function(_0x365832){var _0x166e9a=this['_tasks']['indexOf'](_0x365832);_0x166e9a>-0x1&&this['_tasks']['splice'](_0x166e9a,0x1);},_0x1e6702['prototype']['_decreaseWaitingTasksCount']=function(_0x252107){this['_waitingTasksCount']--;try{this['onProgress']&&this['onProgress'](this['_waitingTasksCount'],this['_totalTasksCount'],_0x252107),this['onProgressObservable']['notifyObservers'](new _0x4c658d(this['_waitingTasksCount'],this['_totalTasksCount'],_0x252107));}catch(_0x54490d){_0x75193d['a']['Error']('Error\x20running\x20progress\x20callbacks.'),console['log'](_0x54490d);}if(0x0===this['_waitingTasksCount']){try{var _0x76d66b=this['_tasks']['slice']();this['onFinish']&&this['onFinish'](_0x76d66b);for(var _0x20ace1=0x0,_0x1fce4a=_0x76d66b;_0x20ace1<_0x1fce4a['length'];_0x20ace1++){if((_0x252107=_0x1fce4a[_0x20ace1])['taskState']===_0x2fdd8f['DONE']){var _0x222b72=this['_tasks']['indexOf'](_0x252107);_0x222b72>-0x1&&this['_tasks']['splice'](_0x222b72,0x1);}}this['onTasksDoneObservable']['notifyObservers'](this['_tasks']);}catch(_0x4bfec8){_0x75193d['a']['Error']('Error\x20running\x20tasks-done\x20callbacks.'),console['log'](_0x4bfec8);}this['_isLoading']=!0x1,this['autoHideLoadingUI']&&this['_scene']['getEngine']()['hideLoadingUI']();}},_0x1e6702['prototype']['_runTask']=function(_0x22a0ae){var _0x1a3f52=this,_0x2ee3a8=function(_0x44be19,_0x5aeff8){_0x22a0ae['_setErrorObject'](_0x44be19,_0x5aeff8),_0x1a3f52['onTaskError']&&_0x1a3f52['onTaskError'](_0x22a0ae),_0x1a3f52['onTaskErrorObservable']['notifyObservers'](_0x22a0ae),_0x1a3f52['_decreaseWaitingTasksCount'](_0x22a0ae);};_0x22a0ae['run'](this['_scene'],function(){try{_0x1a3f52['onTaskSuccess']&&_0x1a3f52['onTaskSuccess'](_0x22a0ae),_0x1a3f52['onTaskSuccessObservable']['notifyObservers'](_0x22a0ae),_0x1a3f52['_decreaseWaitingTasksCount'](_0x22a0ae);}catch(_0x509b87){_0x2ee3a8('Error\x20executing\x20task\x20success\x20callbacks',_0x509b87);}},_0x2ee3a8);},_0x1e6702['prototype']['reset']=function(){return this['_isLoading']=!0x1,this['_tasks']=new Array(),this;},_0x1e6702['prototype']['load']=function(){if(this['_isLoading'])return this;if(this['_isLoading']=!0x0,this['_waitingTasksCount']=this['_tasks']['length'],this['_totalTasksCount']=this['_tasks']['length'],0x0===this['_waitingTasksCount'])return this['_isLoading']=!0x1,this['onFinish']&&this['onFinish'](this['_tasks']),this['onTasksDoneObservable']['notifyObservers'](this['_tasks']),this;this['useDefaultLoadingScreen']&&this['_scene']['getEngine']()['displayLoadingUI']();for(var _0x50bf2f=0x0;_0x50bf2f=0x0&&this['_meshes']['splice'](_0x66146f,0x1),this['_centerPosition']=this['_centerMesh']['getAbsolutePosition']()['clone']();for(var _0x2ad071=0x0;_0x2ad0710x0&&this['_textureLoadingCallback'](_0xca6971);}this['_currentScene']['render']();}},_0x287a37['prototype']['drag']=function(_0x4a2ed0){_0x4a2ed0['stopPropagation'](),_0x4a2ed0['preventDefault']();},_0x287a37['prototype']['drop']=function(_0x4c4686){_0x4c4686['stopPropagation'](),_0x4c4686['preventDefault'](),this['loadFiles'](_0x4c4686);},_0x287a37['prototype']['_traverseFolder']=function(_0x22de28,_0x9baf95,_0x14b0eb,_0x161e40){var _0x5e396e=this,_0x2349d0=_0x22de28['createReader'](),_0x1a64e1=_0x22de28['fullPath']['replace'](/^\//,'')['replace'](/(.+?)\/?$/,'$1/');_0x2349d0['readEntries'](function(_0x53f7aa){_0x14b0eb['count']+=_0x53f7aa['length'];for(var _0x59f05e=0x0,_0x2b43ed=_0x53f7aa;_0x59f05e<_0x2b43ed['length'];_0x59f05e++){var _0x19e68b=_0x2b43ed[_0x59f05e];_0x19e68b['isFile']?_0x19e68b['file'](function(_0x469bf2){_0x469bf2['correctName']=_0x1a64e1+_0x469bf2['name'],_0x9baf95['push'](_0x469bf2),0x0==--_0x14b0eb['count']&&_0x161e40();}):_0x19e68b['isDirectory']&&_0x5e396e['_traverseFolder'](_0x19e68b,_0x9baf95,_0x14b0eb,_0x161e40);}0x0==--_0x14b0eb['count']&&_0x161e40();});},_0x287a37['prototype']['_processFiles']=function(_0x288504){for(var _0x50976e=0x0;_0x50976e<_0x288504['length'];_0x50976e++){var _0x5cdb68=_0x288504[_0x50976e]['correctName']['toLowerCase'](),_0x3eb5bf=_0x5cdb68['split']('.')['pop']();this['onProcessFileCallback'](_0x288504[_0x50976e],_0x5cdb68,_0x3eb5bf)&&(_0x5de01e['IsPluginForExtensionAvailable']('.'+_0x3eb5bf)&&(this['_sceneFileToLoad']=_0x288504[_0x50976e]),_0x287a37['FilesToLoad'][_0x5cdb68]=_0x288504[_0x50976e]);}},_0x287a37['prototype']['loadFiles']=function(_0x7e2973){var _0x29088e=this;if(_0x7e2973&&_0x7e2973['dataTransfer']&&_0x7e2973['dataTransfer']['files']&&(this['_filesToLoad']=_0x7e2973['dataTransfer']['files']),_0x7e2973&&_0x7e2973['target']&&_0x7e2973['target']['files']&&(this['_filesToLoad']=_0x7e2973['target']['files']),this['_filesToLoad']&&0x0!==this['_filesToLoad']['length']&&(this['_startingProcessingFilesCallback']&&this['_startingProcessingFilesCallback'](this['_filesToLoad']),this['_filesToLoad']&&this['_filesToLoad']['length']>0x0)){for(var _0x141c97=new Array(),_0x3e4db5=[],_0x3707a7=_0x7e2973['dataTransfer']?_0x7e2973['dataTransfer']['items']:null,_0x302d18=0x0;_0x302d180x0&&_0x75193d['a']['ClearLogCache'](),this['_engine']['stopRenderLoop']()),_0x5de01e['ShowLoadingScreen']=!0x1,this['_engine']['displayLoadingUI'](),_0x5de01e['LoadAsync']('file:',this['_sceneFileToLoad'],this['_engine'],function(_0x2efcec){_0x286513['_progressCallback']&&_0x286513['_progressCallback'](_0x2efcec);})['then'](function(_0x31b7ad){_0x286513['_currentScene']&&_0x286513['_currentScene']['dispose'](),_0x286513['_currentScene']=_0x31b7ad,_0x286513['_sceneLoadedCallback']&&_0x286513['_sceneLoadedCallback'](_0x286513['_sceneFileToLoad'],_0x286513['_currentScene']),_0x286513['_currentScene']['executeWhenReady'](function(){_0x286513['_engine']['hideLoadingUI'](),_0x286513['_engine']['runRenderLoop'](function(){_0x286513['renderFunction']();});});})['catch'](function(_0x3f7367){_0x286513['_engine']['hideLoadingUI'](),_0x286513['_errorCallback']&&_0x286513['_errorCallback'](_0x286513['_sceneFileToLoad'],_0x286513['_currentScene'],_0x3f7367['message']);})):_0x75193d['a']['Error']('Please\x20provide\x20a\x20valid\x20.babylon\x20file.');},_0x287a37;}()),_0x45e325=_0x162675(0x92),_0x534107=_0x162675(0x91),_0x570cc0=(function(){function _0x17c00d(_0x3c2834){void 0x0===_0x3c2834&&(_0x3c2834=0x0),this['priority']=_0x3c2834;}return _0x17c00d['prototype']['getDescription']=function(){return'';},_0x17c00d['prototype']['apply']=function(_0x49defe,_0x3302c8){return!0x0;},_0x17c00d;}()),_0x3812e5=function(_0x4a6599){function _0x25a458(_0x2fd829,_0x35df14,_0x503d73){void 0x0===_0x2fd829&&(_0x2fd829=0x0),void 0x0===_0x35df14&&(_0x35df14=0x400),void 0x0===_0x503d73&&(_0x503d73=0.5);var _0x2901e7=_0x4a6599['call'](this,_0x2fd829)||this;return _0x2901e7['priority']=_0x2fd829,_0x2901e7['maximumSize']=_0x35df14,_0x2901e7['step']=_0x503d73,_0x2901e7;}return Object(_0x18e13d['d'])(_0x25a458,_0x4a6599),_0x25a458['prototype']['getDescription']=function(){return'Reducing\x20render\x20target\x20texture\x20size\x20to\x20'+this['maximumSize'];},_0x25a458['prototype']['apply']=function(_0x5a9303,_0x5229f0){for(var _0x44d3e3=!0x0,_0x2be770=0x0;_0x2be770<_0x5a9303['textures']['length'];_0x2be770++){var _0xcaea4a=_0x5a9303['textures'][_0x2be770];if(_0xcaea4a['canRescale']&&!_0xcaea4a['getContext']){var _0x37b315=_0xcaea4a['getSize']();Math['max'](_0x37b315['width'],_0x37b315['height'])>this['maximumSize']&&(_0xcaea4a['scale'](this['step']),_0x44d3e3=!0x1);}}return _0x44d3e3;},_0x25a458;}(_0x570cc0),_0x25b571=function(_0xab7732){function _0x258f5e(_0x5d6ca1,_0x128f9d,_0x20317c){void 0x0===_0x5d6ca1&&(_0x5d6ca1=0x0),void 0x0===_0x128f9d&&(_0x128f9d=0x2),void 0x0===_0x20317c&&(_0x20317c=0.25);var _0x9b8f7e=_0xab7732['call'](this,_0x5d6ca1)||this;return _0x9b8f7e['priority']=_0x5d6ca1,_0x9b8f7e['maximumScale']=_0x128f9d,_0x9b8f7e['step']=_0x20317c,_0x9b8f7e['_currentScale']=-0x1,_0x9b8f7e['_directionOffset']=0x1,_0x9b8f7e;}return Object(_0x18e13d['d'])(_0x258f5e,_0xab7732),_0x258f5e['prototype']['getDescription']=function(){return'Setting\x20hardware\x20scaling\x20level\x20to\x20'+this['_currentScale'];},_0x258f5e['prototype']['apply']=function(_0x4663b7,_0x57da9b){return-0x1===this['_currentScale']&&(this['_currentScale']=_0x4663b7['getEngine']()['getHardwareScalingLevel'](),this['_currentScale']>this['maximumScale']&&(this['_directionOffset']=-0x1)),this['_currentScale']+=this['_directionOffset']*this['step'],_0x4663b7['getEngine']()['setHardwareScalingLevel'](this['_currentScale']),0x1===this['_directionOffset']?this['_currentScale']>=this['maximumScale']:this['_currentScale']<=this['maximumScale'];},_0x258f5e;}(_0x570cc0),_0x175af1=function(_0x3a53af){function _0x16c73f(){return null!==_0x3a53af&&_0x3a53af['apply'](this,arguments)||this;}return Object(_0x18e13d['d'])(_0x16c73f,_0x3a53af),_0x16c73f['prototype']['getDescription']=function(){return'Turning\x20shadows\x20on/off';},_0x16c73f['prototype']['apply']=function(_0x4bd0bc,_0x109345){return _0x4bd0bc['shadowsEnabled']=_0x109345['isInImprovementMode'],!0x0;},_0x16c73f;}(_0x570cc0),_0x253aec=function(_0x12ec38){function _0x568000(){return null!==_0x12ec38&&_0x12ec38['apply'](this,arguments)||this;}return Object(_0x18e13d['d'])(_0x568000,_0x12ec38),_0x568000['prototype']['getDescription']=function(){return'Turning\x20post-processes\x20on/off';},_0x568000['prototype']['apply']=function(_0x140b68,_0x168c76){return _0x140b68['postProcessesEnabled']=_0x168c76['isInImprovementMode'],!0x0;},_0x568000;}(_0x570cc0),_0x3300ac=function(_0x42498b){function _0x466902(){return null!==_0x42498b&&_0x42498b['apply'](this,arguments)||this;}return Object(_0x18e13d['d'])(_0x466902,_0x42498b),_0x466902['prototype']['getDescription']=function(){return'Turning\x20lens\x20flares\x20on/off';},_0x466902['prototype']['apply']=function(_0x52e25e,_0x458816){return _0x52e25e['lensFlaresEnabled']=_0x458816['isInImprovementMode'],!0x0;},_0x466902;}(_0x570cc0),_0x4a5233=function(_0x559b9e){function _0xc6abea(){return null!==_0x559b9e&&_0x559b9e['apply'](this,arguments)||this;}return Object(_0x18e13d['d'])(_0xc6abea,_0x559b9e),_0xc6abea['prototype']['getDescription']=function(){return this['onGetDescription']?this['onGetDescription']():'Running\x20user\x20defined\x20callback';},_0xc6abea['prototype']['apply']=function(_0x65ed80,_0x2693e4){return!this['onApply']||this['onApply'](_0x65ed80,_0x2693e4);},_0xc6abea;}(_0x570cc0),_0x53fa4c=function(_0x361d2e){function _0xe28fb4(){return null!==_0x361d2e&&_0x361d2e['apply'](this,arguments)||this;}return Object(_0x18e13d['d'])(_0xe28fb4,_0x361d2e),_0xe28fb4['prototype']['getDescription']=function(){return'Turning\x20particles\x20on/off';},_0xe28fb4['prototype']['apply']=function(_0x7a700c,_0x3e9b5c){return _0x7a700c['particlesEnabled']=_0x3e9b5c['isInImprovementMode'],!0x0;},_0xe28fb4;}(_0x570cc0),_0x422335=function(_0x4692e5){function _0x2e56c9(){return null!==_0x4692e5&&_0x4692e5['apply'](this,arguments)||this;}return Object(_0x18e13d['d'])(_0x2e56c9,_0x4692e5),_0x2e56c9['prototype']['getDescription']=function(){return'Turning\x20render\x20targets\x20off';},_0x2e56c9['prototype']['apply']=function(_0x3581e6,_0x293195){return _0x3581e6['renderTargetsEnabled']=_0x293195['isInImprovementMode'],!0x0;},_0x2e56c9;}(_0x570cc0),_0x5a962a=function(_0xf6846c){function _0x1ef7d2(){var _0x4ccc6f=null!==_0xf6846c&&_0xf6846c['apply'](this,arguments)||this;return _0x4ccc6f['_canBeMerged']=function(_0x59940e){if(!(_0x59940e instanceof _0x3cf5e5['a']))return!0x1;var _0x4d31e4=_0x59940e;return!_0x4d31e4['isDisposed']()&&(!(!_0x4d31e4['isVisible']||!_0x4d31e4['isEnabled']())&&(!(_0x4d31e4['instances']['length']>0x0)&&(!_0x4d31e4['skeleton']&&!_0x4d31e4['hasLODLevels'])));},_0x4ccc6f;}return Object(_0x18e13d['d'])(_0x1ef7d2,_0xf6846c),Object['defineProperty'](_0x1ef7d2,'UpdateSelectionTree',{'get':function(){return _0x1ef7d2['_UpdateSelectionTree'];},'set':function(_0x2f2032){_0x1ef7d2['_UpdateSelectionTree']=_0x2f2032;},'enumerable':!0x1,'configurable':!0x0}),_0x1ef7d2['prototype']['getDescription']=function(){return'Merging\x20similar\x20meshes\x20together';},_0x1ef7d2['prototype']['apply']=function(_0x2665e6,_0x30a2c2,_0x5147c7){for(var _0x3ee93b=_0x2665e6['meshes']['slice'](0x0),_0x4bb83f=_0x3ee93b['length'],_0x27e0c3=0x0;_0x27e0c3<_0x4bb83f;_0x27e0c3++){var _0x148d09=new Array(),_0x157746=_0x3ee93b[_0x27e0c3];if(this['_canBeMerged'](_0x157746)){_0x148d09['push'](_0x157746);for(var _0x5b97ca=_0x27e0c3+0x1;_0x5b97ca<_0x4bb83f;_0x5b97ca++){var _0x4a40de=_0x3ee93b[_0x5b97ca];this['_canBeMerged'](_0x4a40de)&&(_0x4a40de['material']===_0x157746['material']&&_0x4a40de['checkCollisions']===_0x157746['checkCollisions']&&(_0x148d09['push'](_0x4a40de),_0x4bb83f--,_0x3ee93b['splice'](_0x5b97ca,0x1),_0x5b97ca--));}_0x148d09['length']<0x2||_0x3cf5e5['a']['MergeMeshes'](_0x148d09,void 0x0,!0x0);}}var _0x2c6eee=_0x2665e6;return _0x2c6eee['createOrUpdateSelectionOctree']&&(null!=_0x5147c7?_0x5147c7&&_0x2c6eee['createOrUpdateSelectionOctree']():_0x1ef7d2['UpdateSelectionTree']&&_0x2c6eee['createOrUpdateSelectionOctree']()),!0x0;},_0x1ef7d2['_UpdateSelectionTree']=!0x1,_0x1ef7d2;}(_0x570cc0),_0x2e7d19=(function(){function _0x8b4c0a(_0x17d7e1,_0x1be541){void 0x0===_0x17d7e1&&(_0x17d7e1=0x3c),void 0x0===_0x1be541&&(_0x1be541=0x7d0),this['targetFrameRate']=_0x17d7e1,this['trackerDuration']=_0x1be541,this['optimizations']=new Array();}return _0x8b4c0a['prototype']['addOptimization']=function(_0x3edcd9){return this['optimizations']['push'](_0x3edcd9),this;},_0x8b4c0a['prototype']['addCustomOptimization']=function(_0x484f3b,_0x4d81af,_0x4e4a05){void 0x0===_0x4e4a05&&(_0x4e4a05=0x0);var _0x51e7c2=new _0x4a5233(_0x4e4a05);return _0x51e7c2['onApply']=_0x484f3b,_0x51e7c2['onGetDescription']=_0x4d81af,this['optimizations']['push'](_0x51e7c2),this;},_0x8b4c0a['LowDegradationAllowed']=function(_0x11142a){var _0x1d0a5b=new _0x8b4c0a(_0x11142a),_0xcd498b=0x0;return _0x1d0a5b['addOptimization'](new _0x5a962a(_0xcd498b)),_0x1d0a5b['addOptimization'](new _0x175af1(_0xcd498b)),_0x1d0a5b['addOptimization'](new _0x3300ac(_0xcd498b)),_0xcd498b++,_0x1d0a5b['addOptimization'](new _0x253aec(_0xcd498b)),_0x1d0a5b['addOptimization'](new _0x53fa4c(_0xcd498b)),_0xcd498b++,_0x1d0a5b['addOptimization'](new _0x3812e5(_0xcd498b,0x400)),_0x1d0a5b;},_0x8b4c0a['ModerateDegradationAllowed']=function(_0x561232){var _0x3874c0=new _0x8b4c0a(_0x561232),_0x66057=0x0;return _0x3874c0['addOptimization'](new _0x5a962a(_0x66057)),_0x3874c0['addOptimization'](new _0x175af1(_0x66057)),_0x3874c0['addOptimization'](new _0x3300ac(_0x66057)),_0x66057++,_0x3874c0['addOptimization'](new _0x253aec(_0x66057)),_0x3874c0['addOptimization'](new _0x53fa4c(_0x66057)),_0x66057++,_0x3874c0['addOptimization'](new _0x3812e5(_0x66057,0x200)),_0x66057++,_0x3874c0['addOptimization'](new _0x422335(_0x66057)),_0x66057++,_0x3874c0['addOptimization'](new _0x25b571(_0x66057,0x2)),_0x3874c0;},_0x8b4c0a['HighDegradationAllowed']=function(_0x41c1a7){var _0x744705=new _0x8b4c0a(_0x41c1a7),_0x3fba8b=0x0;return _0x744705['addOptimization'](new _0x5a962a(_0x3fba8b)),_0x744705['addOptimization'](new _0x175af1(_0x3fba8b)),_0x744705['addOptimization'](new _0x3300ac(_0x3fba8b)),_0x3fba8b++,_0x744705['addOptimization'](new _0x253aec(_0x3fba8b)),_0x744705['addOptimization'](new _0x53fa4c(_0x3fba8b)),_0x3fba8b++,_0x744705['addOptimization'](new _0x3812e5(_0x3fba8b,0x100)),_0x3fba8b++,_0x744705['addOptimization'](new _0x422335(_0x3fba8b)),_0x3fba8b++,_0x744705['addOptimization'](new _0x25b571(_0x3fba8b,0x4)),_0x744705;},_0x8b4c0a;}()),_0x353c55=(function(){function _0x5e10f7(_0x40be93,_0x1331b2,_0x1c36ae,_0x178984){var _0x78c953=this;if(void 0x0===_0x1c36ae&&(_0x1c36ae=!0x0),void 0x0===_0x178984&&(_0x178984=!0x1),this['_isRunning']=!0x1,this['_currentPriorityLevel']=0x0,this['_targetFrameRate']=0x3c,this['_trackerDuration']=0x7d0,this['_currentFrameRate']=0x0,this['_improvementMode']=!0x1,this['onSuccessObservable']=new _0x6ac1f7['c'](),this['onNewOptimizationAppliedObservable']=new _0x6ac1f7['c'](),this['onFailureObservable']=new _0x6ac1f7['c'](),this['_options']=_0x1331b2||new _0x2e7d19(),this['_options']['targetFrameRate']&&(this['_targetFrameRate']=this['_options']['targetFrameRate']),this['_options']['trackerDuration']&&(this['_trackerDuration']=this['_options']['trackerDuration']),_0x1c36ae)for(var _0xd1a4d9=0x0,_0x440ffa=0x0,_0x6fe269=this['_options']['optimizations'];_0x440ffa<_0x6fe269['length'];_0x440ffa++){_0x6fe269[_0x440ffa]['priority']=_0xd1a4d9++;}this['_improvementMode']=_0x178984,this['_scene']=_0x40be93||_0x44b9ce['a']['LastCreatedScene'],this['_sceneDisposeObserver']=this['_scene']['onDisposeObservable']['add'](function(){_0x78c953['_sceneDisposeObserver']=null,_0x78c953['dispose']();});}return Object['defineProperty'](_0x5e10f7['prototype'],'isInImprovementMode',{'get':function(){return this['_improvementMode'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5e10f7['prototype'],'currentPriorityLevel',{'get':function(){return this['_currentPriorityLevel'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5e10f7['prototype'],'currentFrameRate',{'get':function(){return this['_currentFrameRate'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5e10f7['prototype'],'targetFrameRate',{'get':function(){return this['_targetFrameRate'];},'set':function(_0x1cb22b){this['_targetFrameRate']=_0x1cb22b;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5e10f7['prototype'],'trackerDuration',{'get':function(){return this['_trackerDuration'];},'set':function(_0x5c7a5f){this['_trackerDuration']=_0x5c7a5f;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x5e10f7['prototype'],'optimizations',{'get':function(){return this['_options']['optimizations'];},'enumerable':!0x1,'configurable':!0x0}),_0x5e10f7['prototype']['stop']=function(){this['_isRunning']=!0x1;},_0x5e10f7['prototype']['reset']=function(){this['_currentPriorityLevel']=0x0;},_0x5e10f7['prototype']['start']=function(){var _0x337002=this;this['_isRunning']||(this['_isRunning']=!0x0,this['_scene']['executeWhenReady'](function(){setTimeout(function(){_0x337002['_checkCurrentState']();},_0x337002['_trackerDuration']);}));},_0x5e10f7['prototype']['_checkCurrentState']=function(){var _0x2548f6=this;if(this['_isRunning']){var _0x13d6ae=this['_scene'],_0x10c041=this['_options'];if(this['_currentFrameRate']=Math['round'](_0x13d6ae['getEngine']()['getFps']()),this['_improvementMode']&&this['_currentFrameRate']<=this['_targetFrameRate']||!this['_improvementMode']&&this['_currentFrameRate']>=this['_targetFrameRate'])return this['_isRunning']=!0x1,void this['onSuccessObservable']['notifyObservers'](this);for(var _0x3db494=!0x0,_0x884c34=!0x0,_0x4c1583=0x0;_0x4c1583<_0x10c041['optimizations']['length'];_0x4c1583++){var _0x2a099c=_0x10c041['optimizations'][_0x4c1583];_0x2a099c['priority']===this['_currentPriorityLevel']&&(_0x884c34=!0x1,_0x3db494=_0x3db494&&_0x2a099c['apply'](_0x13d6ae,this),this['onNewOptimizationAppliedObservable']['notifyObservers'](_0x2a099c));}if(_0x884c34)return this['_isRunning']=!0x1,void this['onFailureObservable']['notifyObservers'](this);_0x3db494&&this['_currentPriorityLevel']++,_0x13d6ae['executeWhenReady'](function(){setTimeout(function(){_0x2548f6['_checkCurrentState']();},_0x2548f6['_trackerDuration']);});}},_0x5e10f7['prototype']['dispose']=function(){this['stop'](),this['onSuccessObservable']['clear'](),this['onFailureObservable']['clear'](),this['onNewOptimizationAppliedObservable']['clear'](),this['_sceneDisposeObserver']&&this['_scene']['onDisposeObservable']['remove'](this['_sceneDisposeObserver']);},_0x5e10f7['OptimizeAsync']=function(_0x528d2f,_0x4fe71a,_0x162e47,_0x22724b){var _0x44b474=new _0x5e10f7(_0x528d2f,_0x4fe71a||_0x2e7d19['ModerateDegradationAllowed'](),!0x1);return _0x162e47&&_0x44b474['onSuccessObservable']['add'](function(){_0x162e47();}),_0x22724b&&_0x44b474['onFailureObservable']['add'](function(){_0x22724b();}),_0x44b474['start'](),_0x44b474;},_0x5e10f7;}()),_0x1631ed=[],_0x51934f=function(_0x3888d8,_0x4984ca){_0x1631ed[_0x3888d8['id']]||_0x3888d8['doNotSerialize']||(_0x4984ca['vertexData']['push'](_0x3888d8['serializeVerticeData']()),_0x1631ed[_0x3888d8['id']]=!0x0);},_0x4bbff1=function(_0x597238,_0x4b0053){var _0x21f230={},_0x58c2d7=_0x597238['_geometry'];return _0x58c2d7&&(_0x597238['getScene']()['getGeometryByID'](_0x58c2d7['id'])||_0x51934f(_0x58c2d7,_0x4b0053['geometries'])),_0x597238['serialize']&&_0x597238['serialize'](_0x21f230),_0x21f230;},_0x568e68=(function(){function _0x4440e2(){}return _0x4440e2['ClearCache']=function(){_0x1631ed=[];},_0x4440e2['Serialize']=function(_0x43f039){var _0x4e3f5b,_0x3e07b6,_0x164d9e,_0x1b3812={};if(_0x4440e2['ClearCache'](),_0x1b3812['useDelayedTextureLoading']=_0x43f039['useDelayedTextureLoading'],_0x1b3812['autoClear']=_0x43f039['autoClear'],_0x1b3812['clearColor']=_0x43f039['clearColor']['asArray'](),_0x1b3812['ambientColor']=_0x43f039['ambientColor']['asArray'](),_0x1b3812['gravity']=_0x43f039['gravity']['asArray'](),_0x1b3812['collisionsEnabled']=_0x43f039['collisionsEnabled'],_0x43f039['fogMode']&&0x0!==_0x43f039['fogMode']&&(_0x1b3812['fogMode']=_0x43f039['fogMode'],_0x1b3812['fogColor']=_0x43f039['fogColor']['asArray'](),_0x1b3812['fogStart']=_0x43f039['fogStart'],_0x1b3812['fogEnd']=_0x43f039['fogEnd'],_0x1b3812['fogDensity']=_0x43f039['fogDensity']),_0x43f039['isPhysicsEnabled']()){var _0x58acf8=_0x43f039['getPhysicsEngine']();_0x58acf8&&(_0x1b3812['physicsEnabled']=!0x0,_0x1b3812['physicsGravity']=_0x58acf8['gravity']['asArray'](),_0x1b3812['physicsEngine']=_0x58acf8['getPhysicsPluginName']());}_0x43f039['metadata']&&(_0x1b3812['metadata']=_0x43f039['metadata']),_0x1b3812['morphTargetManagers']=[];for(var _0x40618c=0x0,_0x365580=_0x43f039['meshes'];_0x40618c<_0x365580['length'];_0x40618c++){var _0x461ebd=(_0x124f7a=_0x365580[_0x40618c])['morphTargetManager'];_0x461ebd&&_0x1b3812['morphTargetManagers']['push'](_0x461ebd['serialize']());}for(_0x1b3812['lights']=[],_0x4e3f5b=0x0;_0x4e3f5b<_0x43f039['lights']['length'];_0x4e3f5b++)(_0x3e07b6=_0x43f039['lights'][_0x4e3f5b])['doNotSerialize']||_0x1b3812['lights']['push'](_0x3e07b6['serialize']());for(_0x1b3812['cameras']=[],_0x4e3f5b=0x0;_0x4e3f5b<_0x43f039['cameras']['length'];_0x4e3f5b++){var _0x176d72=_0x43f039['cameras'][_0x4e3f5b];_0x176d72['doNotSerialize']||_0x1b3812['cameras']['push'](_0x176d72['serialize']());}if(_0x43f039['activeCamera']&&(_0x1b3812['activeCameraID']=_0x43f039['activeCamera']['id']),_0x495d06['a']['AppendSerializedAnimations'](_0x43f039,_0x1b3812),_0x43f039['animationGroups']&&_0x43f039['animationGroups']['length']>0x0){_0x1b3812['animationGroups']=[];for(var _0x1b29f0=0x0;_0x1b29f0<_0x43f039['animationGroups']['length'];_0x1b29f0++){var _0x4cd1a5=_0x43f039['animationGroups'][_0x1b29f0];_0x1b3812['animationGroups']['push'](_0x4cd1a5['serialize']());}}if(_0x43f039['reflectionProbes']&&_0x43f039['reflectionProbes']['length']>0x0)for(_0x1b3812['reflectionProbes']=[],_0x4e3f5b=0x0;_0x4e3f5b<_0x43f039['reflectionProbes']['length'];_0x4e3f5b++){var _0x31fd83=_0x43f039['reflectionProbes'][_0x4e3f5b];_0x1b3812['reflectionProbes']['push'](_0x31fd83['serialize']());}for(_0x1b3812['materials']=[],_0x1b3812['multiMaterials']=[],_0x4e3f5b=0x0;_0x4e3f5b<_0x43f039['materials']['length'];_0x4e3f5b++)(_0x164d9e=_0x43f039['materials'][_0x4e3f5b])['doNotSerialize']||_0x1b3812['materials']['push'](_0x164d9e['serialize']());for(_0x1b3812['multiMaterials']=[],_0x4e3f5b=0x0;_0x4e3f5b<_0x43f039['multiMaterials']['length'];_0x4e3f5b++){var _0x296a9d=_0x43f039['multiMaterials'][_0x4e3f5b];_0x1b3812['multiMaterials']['push'](_0x296a9d['serialize']());}for(_0x43f039['environmentTexture']&&(_0x1b3812['environmentTexture']=_0x43f039['environmentTexture']['name']),_0x1b3812['environmentIntensity']=_0x43f039['environmentIntensity'],_0x1b3812['skeletons']=[],_0x4e3f5b=0x0;_0x4e3f5b<_0x43f039['skeletons']['length'];_0x4e3f5b++){var _0x52a94f=_0x43f039['skeletons'][_0x4e3f5b];_0x52a94f['doNotSerialize']||_0x1b3812['skeletons']['push'](_0x52a94f['serialize']());}for(_0x1b3812['transformNodes']=[],_0x4e3f5b=0x0;_0x4e3f5b<_0x43f039['transformNodes']['length'];_0x4e3f5b++)_0x43f039['transformNodes'][_0x4e3f5b]['doNotSerialize']||_0x1b3812['transformNodes']['push'](_0x43f039['transformNodes'][_0x4e3f5b]['serialize']());_0x1b3812['geometries']={},_0x1b3812['geometries']['boxes']=[],_0x1b3812['geometries']['spheres']=[],_0x1b3812['geometries']['cylinders']=[],_0x1b3812['geometries']['toruses']=[],_0x1b3812['geometries']['grounds']=[],_0x1b3812['geometries']['planes']=[],_0x1b3812['geometries']['torusKnots']=[],_0x1b3812['geometries']['vertexData']=[],_0x1631ed=[];var _0x59860a=_0x43f039['getGeometries']();for(_0x4e3f5b=0x0;_0x4e3f5b<_0x59860a['length'];_0x4e3f5b++){var _0x4cebbe=_0x59860a[_0x4e3f5b];_0x4cebbe['isReady']()&&_0x51934f(_0x4cebbe,_0x1b3812['geometries']);}for(_0x1b3812['meshes']=[],_0x4e3f5b=0x0;_0x4e3f5b<_0x43f039['meshes']['length'];_0x4e3f5b++){var _0x124f7a;if((_0x124f7a=_0x43f039['meshes'][_0x4e3f5b])instanceof _0x3cf5e5['a']){var _0x36f54e=_0x124f7a;_0x36f54e['doNotSerialize']||_0x36f54e['delayLoadState']!==_0x2103ba['a']['DELAYLOADSTATE_LOADED']&&_0x36f54e['delayLoadState']!==_0x2103ba['a']['DELAYLOADSTATE_NONE']||_0x1b3812['meshes']['push'](_0x4bbff1(_0x36f54e,_0x1b3812));}}for(_0x1b3812['particleSystems']=[],_0x4e3f5b=0x0;_0x4e3f5b<_0x43f039['particleSystems']['length'];_0x4e3f5b++)_0x1b3812['particleSystems']['push'](_0x43f039['particleSystems'][_0x4e3f5b]['serialize'](!0x1));for(_0x1b3812['postProcesses']=[],_0x4e3f5b=0x0;_0x4e3f5b<_0x43f039['postProcesses']['length'];_0x4e3f5b++)_0x1b3812['postProcesses']['push'](_0x43f039['postProcesses'][_0x4e3f5b]['serialize']());_0x43f039['actionManager']&&(_0x1b3812['actions']=_0x43f039['actionManager']['serialize']('scene'));for(var _0x4b9eee=0x0,_0x36a3ac=_0x43f039['_serializableComponents'];_0x4b9eee<_0x36a3ac['length'];_0x4b9eee++){_0x36a3ac[_0x4b9eee]['serialize'](_0x1b3812);}return _0x1b3812;},_0x4440e2['SerializeMesh']=function(_0x3a8919,_0x1d5832,_0x28889d){void 0x0===_0x1d5832&&(_0x1d5832=!0x1),void 0x0===_0x28889d&&(_0x28889d=!0x1);var _0x1bbf88={};if(_0x4440e2['ClearCache'](),_0x3a8919=_0x3a8919 instanceof Array?_0x3a8919:[_0x3a8919],_0x1d5832||_0x28889d){for(var _0x2234ac=0x0;_0x2234ac<_0x3a8919['length'];++_0x2234ac)_0x28889d&&_0x3a8919[_0x2234ac]['getDescendants']()['forEach'](function(_0x462bdc){_0x462bdc instanceof _0x3cf5e5['a']&&_0x3a8919['indexOf'](_0x462bdc)<0x0&&!_0x462bdc['doNotSerialize']&&_0x3a8919['push'](_0x462bdc);}),_0x1d5832&&_0x3a8919[_0x2234ac]['parent']&&_0x3a8919['indexOf'](_0x3a8919[_0x2234ac]['parent'])<0x0&&!_0x3a8919[_0x2234ac]['parent']['doNotSerialize']&&_0x3a8919['push'](_0x3a8919[_0x2234ac]['parent']);}return _0x3a8919['forEach'](function(_0x40cb40){!function(_0x4cf13b,_0x41db82){if(_0x4cf13b['delayLoadState']===_0x2103ba['a']['DELAYLOADSTATE_LOADED']||_0x4cf13b['delayLoadState']===_0x2103ba['a']['DELAYLOADSTATE_NONE']){if(_0x4cf13b['material']&&!_0x4cf13b['material']['doNotSerialize']){if(_0x4cf13b['material']instanceof _0x5a4b2b['a']){if(_0x41db82['multiMaterials']=_0x41db82['multiMaterials']||[],_0x41db82['materials']=_0x41db82['materials']||[],!_0x41db82['multiMaterials']['some'](function(_0x42dcfe){return _0x42dcfe['id']===_0x4cf13b['material']['id'];})){_0x41db82['multiMaterials']['push'](_0x4cf13b['material']['serialize']());for(var _0x2f249f=function(_0xb43314){_0xb43314&&(_0x41db82['materials']['some'](function(_0x1bb795){return _0x1bb795['id']===_0xb43314['id'];})||_0x41db82['materials']['push'](_0xb43314['serialize']()));},_0x117e5a=0x0,_0x5750b1=_0x4cf13b['material']['subMaterials'];_0x117e5a<_0x5750b1['length'];_0x117e5a++){_0x2f249f(_0x5750b1[_0x117e5a]);}}}else _0x41db82['materials']=_0x41db82['materials']||[],_0x41db82['materials']['some'](function(_0x3387a3){return _0x3387a3['id']===_0x4cf13b['material']['id'];})||_0x41db82['materials']['push'](_0x4cf13b['material']['serialize']());}var _0x2f5cc0=_0x4cf13b['_geometry'];_0x2f5cc0&&(_0x41db82['geometries']||(_0x41db82['geometries']={},_0x41db82['geometries']['boxes']=[],_0x41db82['geometries']['spheres']=[],_0x41db82['geometries']['cylinders']=[],_0x41db82['geometries']['toruses']=[],_0x41db82['geometries']['grounds']=[],_0x41db82['geometries']['planes']=[],_0x41db82['geometries']['torusKnots']=[],_0x41db82['geometries']['vertexData']=[]),_0x51934f(_0x2f5cc0,_0x41db82['geometries'])),_0x4cf13b['skeleton']&&!_0x4cf13b['skeleton']['doNotSerialize']&&(_0x41db82['skeletons']=_0x41db82['skeletons']||[],_0x41db82['skeletons']['push'](_0x4cf13b['skeleton']['serialize']())),_0x41db82['meshes']=_0x41db82['meshes']||[],_0x41db82['meshes']['push'](_0x4bbff1(_0x4cf13b,_0x41db82));}}(_0x40cb40,_0x1bbf88);}),_0x1bbf88;},_0x4440e2;}()),_0x49603f=_0x162675(0x25),_0x34ddb1=(function(){function _0x2a0e99(){}return _0x2a0e99['CreateResizedCopy']=function(_0x368d17,_0x5277f6,_0x22281d,_0x2013de){void 0x0===_0x2013de&&(_0x2013de=!0x0);var _0x29a404=_0x368d17['getScene'](),_0x46b886=_0x29a404['getEngine'](),_0xad5ec=new _0x310f87('resized'+_0x368d17['name'],{'width':_0x5277f6,'height':_0x22281d},_0x29a404,!_0x368d17['noMipmap'],!0x0,_0x368d17['_texture']['type'],!0x1,_0x368d17['samplingMode'],!0x1);_0xad5ec['wrapU']=_0x368d17['wrapU'],_0xad5ec['wrapV']=_0x368d17['wrapV'],_0xad5ec['uOffset']=_0x368d17['uOffset'],_0xad5ec['vOffset']=_0x368d17['vOffset'],_0xad5ec['uScale']=_0x368d17['uScale'],_0xad5ec['vScale']=_0x368d17['vScale'],_0xad5ec['uAng']=_0x368d17['uAng'],_0xad5ec['vAng']=_0x368d17['vAng'],_0xad5ec['wAng']=_0x368d17['wAng'],_0xad5ec['coordinatesIndex']=_0x368d17['coordinatesIndex'],_0xad5ec['level']=_0x368d17['level'],_0xad5ec['anisotropicFilteringLevel']=_0x368d17['anisotropicFilteringLevel'],_0xad5ec['_texture']['isReady']=!0x1,_0x368d17['wrapU']=_0xaf3c80['a']['CLAMP_ADDRESSMODE'],_0x368d17['wrapV']=_0xaf3c80['a']['CLAMP_ADDRESSMODE'];var _0xd8a246=new _0x3f9daa('pass',0x1,null,_0x2013de?_0xaf3c80['a']['BILINEAR_SAMPLINGMODE']:_0xaf3c80['a']['NEAREST_SAMPLINGMODE'],_0x46b886,!0x1,_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT']);return _0xd8a246['getEffect']()['executeWhenCompiled'](function(){_0xd8a246['onApply']=function(_0x22959d){_0x22959d['setTexture']('textureSampler',_0x368d17);};var _0x596847=_0xad5ec['getInternalTexture']();_0x596847&&(_0x29a404['postProcessManager']['directRender']([_0xd8a246],_0x596847),_0x46b886['unBindFramebuffer'](_0x596847),_0xad5ec['disposeFramebufferObjects'](),_0xd8a246['dispose'](),_0x596847['isReady']=!0x0);}),_0xad5ec;},_0x2a0e99;}()),_0x1816cc=(function(){function _0x817391(_0x4e079d,_0x524fd3){if(void 0x0===_0x524fd3&&(_0x524fd3=null),!_0x817391['IsSupported'](_0x4e079d))throw'Your\x20browser\x20does\x20not\x20support\x20recording\x20so\x20far.';var _0x12c71b=_0x4e079d['getRenderingCanvas']();if(!_0x12c71b)throw'The\x20babylon\x20engine\x20must\x20have\x20a\x20canvas\x20to\x20be\x20recorded';this['_canvas']=_0x12c71b,this['_canvas']['isRecording']=!0x1,this['_options']=Object(_0x18e13d['a'])(Object(_0x18e13d['a'])({},_0x817391['_defaultOptions']),_0x524fd3);var _0x76e1b6=this['_canvas']['captureStream'](this['_options']['fps']);if(this['_options']['audioTracks'])for(var _0x35abb5=0x0,_0x120874=this['_options']['audioTracks'];_0x35abb5<_0x120874['length'];_0x35abb5++){var _0x45dfa5=_0x120874[_0x35abb5];_0x76e1b6['addTrack'](_0x45dfa5);}this['_mediaRecorder']=new MediaRecorder(_0x76e1b6,{'mimeType':this['_options']['mimeType']}),this['_mediaRecorder']['ondataavailable']=this['_handleDataAvailable']['bind'](this),this['_mediaRecorder']['onerror']=this['_handleError']['bind'](this),this['_mediaRecorder']['onstop']=this['_handleStop']['bind'](this);}return _0x817391['IsSupported']=function(_0x5c353a){var _0x1fc767=_0x5c353a['getRenderingCanvas']();return!!_0x1fc767&&'function'==typeof _0x1fc767['captureStream'];},Object['defineProperty'](_0x817391['prototype'],'isRecording',{'get':function(){return!!this['_canvas']&&this['_canvas']['isRecording'];},'enumerable':!0x1,'configurable':!0x0}),_0x817391['prototype']['stopRecording']=function(){this['_canvas']&&this['_mediaRecorder']&&this['isRecording']&&(this['_canvas']['isRecording']=!0x1,this['_mediaRecorder']['stop']());},_0x817391['prototype']['startRecording']=function(_0x38a7b6,_0x4304f0){var _0x445775=this;if(void 0x0===_0x38a7b6&&(_0x38a7b6='babylonjs.webm'),void 0x0===_0x4304f0&&(_0x4304f0=0x7),!this['_canvas']||!this['_mediaRecorder'])throw'Recorder\x20has\x20already\x20been\x20disposed';if(this['isRecording'])throw'Recording\x20already\x20in\x20progress';return _0x4304f0>0x0&&setTimeout(function(){_0x445775['stopRecording']();},0x3e8*_0x4304f0),this['_fileName']=_0x38a7b6,this['_recordedChunks']=[],this['_resolve']=null,this['_reject']=null,this['_canvas']['isRecording']=!0x0,this['_mediaRecorder']['start'](this['_options']['recordChunckSize']),new Promise(function(_0x5c14e9,_0x3ea673){_0x445775['_resolve']=_0x5c14e9,_0x445775['_reject']=_0x3ea673;});},_0x817391['prototype']['dispose']=function(){this['_canvas']=null,this['_mediaRecorder']=null,this['_recordedChunks']=[],this['_fileName']=null,this['_resolve']=null,this['_reject']=null;},_0x817391['prototype']['_handleDataAvailable']=function(_0x5d403a){_0x5d403a['data']['size']>0x0&&this['_recordedChunks']['push'](_0x5d403a['data']);},_0x817391['prototype']['_handleError']=function(_0x25d7b1){if(this['stopRecording'](),!this['_reject'])throw new _0x25d7b1['error']();this['_reject'](_0x25d7b1['error']);},_0x817391['prototype']['_handleStop']=function(){this['stopRecording']();var _0x5786d0=new Blob(this['_recordedChunks']);this['_resolve']&&this['_resolve'](_0x5786d0),window['URL']['createObjectURL'](_0x5786d0),this['_fileName']&&_0x5d754c['b']['Download'](_0x5786d0,this['_fileName']);},_0x817391['_defaultOptions']={'mimeType':'video/webm','fps':0x19,'recordChunckSize':0xbb8},_0x817391;}()),_0x329c92=(function(){function _0xbb5577(){}return _0xbb5577['CreateScreenshot']=function(_0xad37d9,_0x434c13,_0x3499bc,_0x440126,_0x30ebb2){void 0x0===_0x30ebb2&&(_0x30ebb2='image/png');var _0x43d889=_0xbb5577['_getScreenshotSize'](_0xad37d9,_0x434c13,_0x3499bc),_0x39d70b=_0x43d889['height'],_0x1af7d1=_0x43d889['width'];if(_0x39d70b&&_0x1af7d1){_0x5d754c['b']['_ScreenshotCanvas']||(_0x5d754c['b']['_ScreenshotCanvas']=document['createElement']('canvas')),_0x5d754c['b']['_ScreenshotCanvas']['width']=_0x1af7d1,_0x5d754c['b']['_ScreenshotCanvas']['height']=_0x39d70b;var _0x1faa89=_0x5d754c['b']['_ScreenshotCanvas']['getContext']('2d'),_0x9bac04=_0xad37d9['getRenderWidth']()/_0xad37d9['getRenderHeight'](),_0x23f637=_0x1af7d1,_0x317ffc=_0x23f637/_0x9bac04;_0x317ffc>_0x39d70b&&(_0x23f637=(_0x317ffc=_0x39d70b)*_0x9bac04);var _0x479431=Math['max'](0x0,_0x1af7d1-_0x23f637)/0x2,_0x1d205b=Math['max'](0x0,_0x39d70b-_0x317ffc)/0x2,_0x2c080a=_0xad37d9['getRenderingCanvas']();_0x1faa89&&_0x2c080a&&_0x1faa89['drawImage'](_0x2c080a,_0x479431,_0x1d205b,_0x23f637,_0x317ffc),_0x5d754c['b']['EncodeScreenshotCanvasData'](_0x440126,_0x30ebb2);}else _0x75193d['a']['Error']('Invalid\x20\x27size\x27\x20parameter\x20!');},_0xbb5577['CreateScreenshotAsync']=function(_0x393f3a,_0x2163d3,_0xe902e0,_0xc16783){return void 0x0===_0xc16783&&(_0xc16783='image/png'),new Promise(function(_0x131464,_0x142672){_0xbb5577['CreateScreenshot'](_0x393f3a,_0x2163d3,_0xe902e0,function(_0x586c96){void 0x0!==_0x586c96?_0x131464(_0x586c96):_0x142672(new Error('Data\x20is\x20undefined'));},_0xc16783);});},_0xbb5577['CreateScreenshotUsingRenderTarget']=function(_0x45d737,_0x287e71,_0x35736a,_0x5681bd,_0x1ba79a,_0x22244d,_0x4729bc,_0x135f8a,_0x344c56,_0x31da66){void 0x0===_0x1ba79a&&(_0x1ba79a='image/png'),void 0x0===_0x22244d&&(_0x22244d=0x1),void 0x0===_0x4729bc&&(_0x4729bc=!0x1),void 0x0===_0x344c56&&(_0x344c56=!0x1),void 0x0===_0x31da66&&(_0x31da66=!0x1);var _0x477272=_0xbb5577['_getScreenshotSize'](_0x45d737,_0x287e71,_0x35736a),_0x6b4399=_0x477272['height'],_0x1b2b90=_0x477272['width'],_0x1a9bd5={'width':_0x1b2b90,'height':_0x6b4399};if(_0x6b4399&&_0x1b2b90){var _0x354b20=_0x45d737['getRenderingCanvas']();if(_0x354b20){var _0x3f3ff9={'width':_0x354b20['width'],'height':_0x354b20['height']};_0x45d737['setSize'](_0x1b2b90,_0x6b4399);var _0x1b87e4=_0x287e71['getScene'](),_0x3c60e6=null,_0x5eb965=_0x1b87e4['activeCameras'];(_0x1b87e4['activeCamera']!==_0x287e71||_0x1b87e4['activeCameras']&&_0x1b87e4['activeCameras']['length'])&&(_0x3c60e6=_0x1b87e4['activeCamera'],_0x1b87e4['activeCamera']=_0x287e71),_0x1b87e4['render']();var _0x2f88b8=new _0x310f87('screenShot',_0x1a9bd5,_0x1b87e4,!0x1,!0x1,_0x2103ba['a']['TEXTURETYPE_UNSIGNED_INT'],!0x1,_0xaf3c80['a']['NEAREST_SAMPLINGMODE'],void 0x0,_0x31da66);_0x2f88b8['renderList']=null,_0x2f88b8['samples']=_0x22244d,_0x2f88b8['renderSprites']=_0x344c56,_0x2f88b8['onAfterRenderObservable']['add'](function(){_0x5d754c['b']['DumpFramebuffer'](_0x1b2b90,_0x6b4399,_0x45d737,_0x5681bd,_0x1ba79a,_0x135f8a);});var _0x3a8a10=function(){_0x1b87e4['incrementRenderId'](),_0x1b87e4['resetCachedMaterial'](),_0x2f88b8['render'](!0x0),_0x2f88b8['dispose'](),_0x3c60e6&&(_0x1b87e4['activeCamera']=_0x3c60e6),_0x1b87e4['activeCameras']=_0x5eb965,_0x45d737['setSize'](_0x3f3ff9['width'],_0x3f3ff9['height']),_0x287e71['getProjectionMatrix'](!0x0);};if(_0x4729bc){var _0x23a94a=new _0x30558e('antialiasing',0x1,_0x1b87e4['activeCamera']);_0x2f88b8['addPostProcess'](_0x23a94a),_0x23a94a['getEffect']()['isReady']()?_0x3a8a10():_0x23a94a['getEffect']()['onCompiled']=function(){_0x3a8a10();};}else _0x3a8a10();}else _0x75193d['a']['Error']('No\x20rendering\x20canvas\x20found\x20!');}else _0x75193d['a']['Error']('Invalid\x20\x27size\x27\x20parameter\x20!');},_0xbb5577['CreateScreenshotUsingRenderTargetAsync']=function(_0x2ed22e,_0x2e2487,_0x517566,_0x1efa4b,_0x5c12e4,_0x3e3aef,_0x4840b6,_0x19744b){return void 0x0===_0x1efa4b&&(_0x1efa4b='image/png'),void 0x0===_0x5c12e4&&(_0x5c12e4=0x1),void 0x0===_0x3e3aef&&(_0x3e3aef=!0x1),void 0x0===_0x19744b&&(_0x19744b=!0x1),new Promise(function(_0x3425fb,_0x1cc726){_0xbb5577['CreateScreenshotUsingRenderTarget'](_0x2ed22e,_0x2e2487,_0x517566,function(_0x491d6b){void 0x0!==_0x491d6b?_0x3425fb(_0x491d6b):_0x1cc726(new Error('Data\x20is\x20undefined'));},_0x1efa4b,_0x5c12e4,_0x3e3aef,_0x4840b6,_0x19744b);});},_0xbb5577['_getScreenshotSize']=function(_0x289969,_0x1585a9,_0x12f060){var _0x45e758=0x0,_0x433c87=0x0;if('object'==typeof _0x12f060){var _0x55999b=_0x12f060['precision']?Math['abs'](_0x12f060['precision']):0x1;_0x12f060['width']&&_0x12f060['height']?(_0x45e758=_0x12f060['height']*_0x55999b,_0x433c87=_0x12f060['width']*_0x55999b):_0x12f060['width']&&!_0x12f060['height']?(_0x433c87=_0x12f060['width']*_0x55999b,_0x45e758=Math['round'](_0x433c87/_0x289969['getAspectRatio'](_0x1585a9))):_0x12f060['height']&&!_0x12f060['width']?(_0x45e758=_0x12f060['height']*_0x55999b,_0x433c87=Math['round'](_0x45e758*_0x289969['getAspectRatio'](_0x1585a9))):(_0x433c87=Math['round'](_0x289969['getRenderWidth']()*_0x55999b),_0x45e758=Math['round'](_0x433c87/_0x289969['getAspectRatio'](_0x1585a9)));}else isNaN(_0x12f060)||(_0x45e758=_0x12f060,_0x433c87=_0x12f060);return _0x433c87&&(_0x433c87=Math['floor'](_0x433c87)),_0x45e758&&(_0x45e758=Math['floor'](_0x45e758)),{'height':0x0|_0x45e758,'width':0x0|_0x433c87};},_0xbb5577;}());_0x5d754c['b']['CreateScreenshot']=_0x329c92['CreateScreenshot'],_0x5d754c['b']['CreateScreenshotAsync']=_0x329c92['CreateScreenshotAsync'],_0x5d754c['b']['CreateScreenshotUsingRenderTarget']=_0x329c92['CreateScreenshotUsingRenderTarget'],_0x5d754c['b']['CreateScreenshotUsingRenderTargetAsync']=_0x329c92['CreateScreenshotUsingRenderTargetAsync'],function(_0x5a7ed2){_0x5a7ed2[_0x5a7ed2['Checkbox']=0x0]='Checkbox',_0x5a7ed2[_0x5a7ed2['Slider']=0x1]='Slider',_0x5a7ed2[_0x5a7ed2['Vector3']=0x2]='Vector3',_0x5a7ed2[_0x5a7ed2['Quaternion']=0x3]='Quaternion',_0x5a7ed2[_0x5a7ed2['Color3']=0x4]='Color3',_0x5a7ed2[_0x5a7ed2['String']=0x5]='String';}(_0x387f88||(_0x387f88={}));var _0x899eb4,_0x2236e7=_0x162675(0x8c),_0x85935a=(function(){function _0x12886e(_0x1f205d){this['byteOffset']=0x0,this['buffer']=_0x1f205d;}return _0x12886e['prototype']['loadAsync']=function(_0xb61761){var _0x2f04b8=this;return this['buffer']['readAsync'](this['byteOffset'],_0xb61761)['then'](function(_0x370c73){_0x2f04b8['_dataView']=new DataView(_0x370c73['buffer'],_0x370c73['byteOffset'],_0x370c73['byteLength']),_0x2f04b8['_dataByteOffset']=0x0;});},_0x12886e['prototype']['readUint32']=function(){var _0x37ca5c=this['_dataView']['getUint32'](this['_dataByteOffset'],!0x0);return this['_dataByteOffset']+=0x4,this['byteOffset']+=0x4,_0x37ca5c;},_0x12886e['prototype']['readUint8Array']=function(_0x59ecac){var _0x4d9e0b=new Uint8Array(this['_dataView']['buffer'],this['_dataView']['byteOffset']+this['_dataByteOffset'],_0x59ecac);return this['_dataByteOffset']+=_0x59ecac,this['byteOffset']+=_0x59ecac,_0x4d9e0b;},_0x12886e['prototype']['readString']=function(_0x2d5e64){return _0x5950ed['a']['Decode'](this['readUint8Array'](_0x2d5e64));},_0x12886e['prototype']['skipBytes']=function(_0x126c02){this['_dataByteOffset']+=_0x126c02,this['byteOffset']+=_0x126c02;},_0x12886e;}()),_0x2ac121=(function(){function _0x3d606f(){}return _0x3d606f['_GetStorage']=function(){try{return localStorage['setItem']('test',''),localStorage['removeItem']('test'),localStorage;}catch(_0x3b529e){var _0x4ab731={};return{'getItem':function(_0x3e9ead){var _0x3e3af4=_0x4ab731[_0x3e9ead];return void 0x0===_0x3e3af4?null:_0x3e3af4;},'setItem':function(_0x457732,_0x73dec5){_0x4ab731[_0x457732]=_0x73dec5;}};}},_0x3d606f['ReadString']=function(_0x4dce58,_0x204f69){var _0x3889d5=this['_Storage']['getItem'](_0x4dce58);return null!==_0x3889d5?_0x3889d5:_0x204f69;},_0x3d606f['WriteString']=function(_0x3ca50e,_0x4340b5){this['_Storage']['setItem'](_0x3ca50e,_0x4340b5);},_0x3d606f['ReadBoolean']=function(_0x5e4fe0,_0x135ce8){var _0x5f063a=this['_Storage']['getItem'](_0x5e4fe0);return null!==_0x5f063a?'true'===_0x5f063a:_0x135ce8;},_0x3d606f['WriteBoolean']=function(_0x393e34,_0x15fb07){this['_Storage']['setItem'](_0x393e34,_0x15fb07?'true':'false');},_0x3d606f['ReadNumber']=function(_0x583b4b,_0x299ff2){var _0x49a766=this['_Storage']['getItem'](_0x583b4b);return null!==_0x49a766?parseFloat(_0x49a766):_0x299ff2;},_0x3d606f['WriteNumber']=function(_0x2fd55f,_0x29f52d){this['_Storage']['setItem'](_0x2fd55f,_0x29f52d['toString']());},_0x3d606f['_Storage']=_0x3d606f['_GetStorage'](),_0x3d606f;}()),_0x58653c=(function(){function _0x19af63(){this['_trackedScene']=null;}return _0x19af63['prototype']['track']=function(_0x3eb29b){this['_trackedScene']=_0x3eb29b,this['_savedJSON']=_0x568e68['Serialize'](_0x3eb29b);},_0x19af63['prototype']['getDelta']=function(){if(!this['_trackedScene'])return null;var _0x36571e=_0x568e68['Serialize'](this['_trackedScene']),_0x2e9d15={};for(var _0x53747f in _0x36571e)this['_compareCollections'](_0x53747f,this['_savedJSON'][_0x53747f],_0x36571e[_0x53747f],_0x2e9d15);return _0x2e9d15;},_0x19af63['prototype']['_compareArray']=function(_0x2bc19d,_0x50b933,_0x1e61c1,_0x71abe9){if(0x0===_0x50b933['length']&&0x0===_0x1e61c1['length'])return!0x0;if(_0x50b933['length']&&!isNaN(_0x50b933[0x0])||_0x1e61c1['length']&&!isNaN(_0x1e61c1[0x0])){if(_0x50b933['length']!==_0x1e61c1['length'])return!0x1;if(0x0===_0x50b933['length'])return!0x0;for(var _0x226c8a=0x0;_0x226c8a<_0x50b933['length'];_0x226c8a++)if(_0x50b933[_0x226c8a]!==_0x1e61c1[_0x226c8a])return _0x71abe9[_0x2bc19d]=_0x1e61c1,!0x1;return!0x0;}var _0x34e090=[],_0x22dba3=function(){var _0x283e76=_0x50b933[_0x226c8a],_0x120a76=_0x283e76['uniqueId'];_0x34e090['push'](_0x120a76);var _0x535b1c=_0x1e61c1['filter'](function(_0x3b489d){return _0x3b489d['uniqueId']===_0x120a76;});if(_0x535b1c['length']){var _0x103a10=_0x535b1c[0x0],_0xced79c={};_0x51dee9['_compareObjects'](_0x283e76,_0x103a10,_0xced79c)||(_0x71abe9[_0x2bc19d]||(_0x71abe9[_0x2bc19d]=[]),_0xced79c['__state']={'id':_0x103a10['id']||_0x103a10['name']},_0x71abe9[_0x2bc19d]['push'](_0xced79c));}else _0xced79c={'__state':{'deleteId':_0x283e76['id']||_0x283e76['name']}},_0x71abe9[_0x2bc19d]['push'](_0xced79c);},_0x51dee9=this;for(_0x226c8a=0x0;_0x226c8a<_0x50b933['length'];_0x226c8a++)_0x22dba3();for(_0x226c8a=0x0;_0x226c8a<_0x1e61c1['length'];_0x226c8a++){var _0x33a18b=_0x1e61c1[_0x226c8a],_0x2e2cdb=_0x33a18b['uniqueId'];-0x1===_0x34e090['indexOf'](_0x2e2cdb)&&(_0x71abe9[_0x2bc19d]||(_0x71abe9[_0x2bc19d]=[]),_0x71abe9[_0x2bc19d]['push'](_0x33a18b));}return!0x0;},_0x19af63['prototype']['_compareObjects']=function(_0x2af491,_0x2251bd,_0x5614c7){var _0x596fc1=!0x1;for(var _0x3e6684 in _0x2af491)if(_0x2af491['hasOwnProperty'](_0x3e6684)){var _0x42fb3f=_0x2af491[_0x3e6684],_0x4425a6=_0x2251bd[_0x3e6684],_0x19fb73=!0x1;Array['isArray'](_0x42fb3f)?_0x19fb73=JSON['stringify'](_0x42fb3f)!==JSON['stringify'](_0x4425a6):isNaN(_0x42fb3f)&&'[object\x20String]'!=Object['prototype']['toString']['call'](_0x42fb3f)||(_0x19fb73=_0x42fb3f!==_0x4425a6),_0x19fb73&&(_0x596fc1=!0x0,_0x5614c7[_0x3e6684]=_0x4425a6);}return!_0x596fc1;},_0x19af63['prototype']['_compareCollections']=function(_0x3c013f,_0x2f1c7b,_0x5069d8,_0x2d9997){if(_0x2f1c7b!==_0x5069d8&&_0x2f1c7b&&_0x5069d8){if(Array['isArray'](_0x2f1c7b)&&Array['isArray'](_0x5069d8)){if(this['_compareArray'](_0x3c013f,_0x2f1c7b,_0x5069d8,_0x2d9997))return;}else{if('object'==typeof _0x2f1c7b&&'object'==typeof _0x5069d8){var _0xc14f1c={};return void(this['_compareObjects'](_0x2f1c7b,_0x5069d8,_0xc14f1c)||(_0x2d9997[_0x3c013f]=_0xc14f1c));}}}},_0x19af63['GetShadowGeneratorById']=function(_0x35ad0d,_0x5620e9){for(var _0x4d083e=0x0,_0x296810=_0x35ad0d['lights']['map'](function(_0x4c9631){return _0x4c9631['getShadowGenerator']();});_0x4d083e<_0x296810['length'];_0x4d083e++){var _0x3c1a2e=_0x296810[_0x4d083e];if(_0x3c1a2e&&_0x3c1a2e['id']===_0x5620e9)return _0x3c1a2e;}return null;},_0x19af63['ApplyDelta']=function(_0x347785,_0x4df846){var _0x3f776c=this;'string'==typeof _0x347785&&(_0x347785=JSON['parse'](_0x347785));var _0x2626ed=_0x4df846;for(var _0x1a1ae1 in _0x347785){var _0x1c151e=_0x347785[_0x1a1ae1],_0x232479=_0x2626ed[_0x1a1ae1];if(Array['isArray'](_0x232479)||'shadowGenerators'===_0x1a1ae1)switch(_0x1a1ae1){case'cameras':this['_ApplyDeltaForEntity'](_0x1c151e,_0x4df846,_0x4df846['getCameraByID']['bind'](_0x4df846),function(_0x971592){return _0x568729['a']['Parse'](_0x971592,_0x4df846);});break;case'lights':this['_ApplyDeltaForEntity'](_0x1c151e,_0x4df846,_0x4df846['getLightByID']['bind'](_0x4df846),function(_0x3206a5){return _0x4e3e4a['a']['Parse'](_0x3206a5,_0x4df846);});break;case'shadowGenerators':this['_ApplyDeltaForEntity'](_0x1c151e,_0x4df846,function(_0x3bef15){return _0x3f776c['GetShadowGeneratorById'](_0x4df846,_0x3bef15);},function(_0x3115c2){return _0x4f0fba['Parse'](_0x3115c2,_0x4df846);});break;case'meshes':this['_ApplyDeltaForEntity'](_0x1c151e,_0x4df846,_0x4df846['getMeshByID']['bind'](_0x4df846),function(_0x36662e){return _0x3cf5e5['a']['Parse'](_0x36662e,_0x4df846,'');});break;case'skeletons':this['_ApplyDeltaForEntity'](_0x1c151e,_0x4df846,_0x4df846['getSkeletonById']['bind'](_0x4df846),function(_0x432c3e){return _0x4198a1['Parse'](_0x432c3e,_0x4df846);});break;case'materials':this['_ApplyDeltaForEntity'](_0x1c151e,_0x4df846,_0x4df846['getMaterialByID']['bind'](_0x4df846),function(_0x436807){return _0x33c2e5['a']['Parse'](_0x436807,_0x4df846,'');});break;case'multiMaterials':this['_ApplyDeltaForEntity'](_0x1c151e,_0x4df846,_0x4df846['getMaterialByID']['bind'](_0x4df846),function(_0x4ce43c){return _0x5a4b2b['a']['Parse'](_0x4ce43c,_0x4df846,'');});break;case'transformNodes':this['_ApplyDeltaForEntity'](_0x1c151e,_0x4df846,_0x4df846['getTransformNodeByID']['bind'](_0x4df846),function(_0x15a5ae){return _0x200669['a']['Parse'](_0x15a5ae,_0x4df846,'');});break;case'particleSystems':this['_ApplyDeltaForEntity'](_0x1c151e,_0x4df846,_0x4df846['getParticleSystemByID']['bind'](_0x4df846),function(_0x3b73cd){return _0x4baa8b['Parse'](_0x3b73cd,_0x4df846,'');});break;case'morphTargetManagers':this['_ApplyDeltaForEntity'](_0x1c151e,_0x4df846,_0x4df846['getMorphTargetById']['bind'](_0x4df846),function(_0x426f54){return _0x43ac20['Parse'](_0x426f54,_0x4df846);});break;case'postProcesses':this['_ApplyDeltaForEntity'](_0x1c151e,_0x4df846,_0x4df846['getPostProcessByName']['bind'](_0x4df846),function(_0x253f71){return _0x5cae84['Parse'](_0x253f71,_0x4df846,'');});}else isNaN(_0x232479)?_0x232479['fromArray']&&_0x232479['fromArray'](_0x1c151e):_0x2626ed[_0x1a1ae1]=_0x1c151e;}},_0x19af63['_ApplyPropertiesToEntity']=function(_0x422bdf,_0x3155a2){for(var _0x47ce49 in _0x422bdf){var _0x596bda=_0x422bdf[_0x47ce49],_0x3334b1=_0x3155a2[_0x47ce49];void 0x0!==_0x3334b1&&(!isNaN(_0x3334b1)||Array['isArray'](_0x3334b1)?_0x3155a2[_0x47ce49]=_0x596bda:_0x3334b1['fromArray']&&_0x3334b1['fromArray'](_0x596bda));}},_0x19af63['_ApplyDeltaForEntity']=function(_0x537bee,_0x4f2dfa,_0x409ce1,_0x3419f3){for(var _0xc48ac0=0x0,_0x4f3b62=_0x537bee;_0xc48ac0<_0x4f3b62['length'];_0xc48ac0++){var _0x1c0f83=_0x4f3b62[_0xc48ac0];if(_0x1c0f83['__state']&&void 0x0!==_0x1c0f83['__state']['id']){var _0x59900e=_0x409ce1(_0x1c0f83['__state']['id']);_0x59900e&&this['_ApplyPropertiesToEntity'](_0x1c0f83,_0x59900e);}else{if(_0x1c0f83['__state']&&void 0x0!==_0x1c0f83['__state']['deleteId']){var _0x3803d9=_0x409ce1(_0x1c0f83['__state']['deleteId']);null==_0x3803d9||_0x3803d9['dispose']();}else _0x3419f3(_0x1c0f83);}}},_0x19af63;}());!function(_0x12ed41){var _0x1b8640=(function(){function _0x30f54b(_0x2471b4,_0x498a81,_0x343e90,_0x535a25){var _0x17fa87;void 0x0===_0x498a81&&(_0x498a81=null),void 0x0===_0x343e90&&(_0x343e90=null),void 0x0===_0x535a25&&(_0x535a25=null),_0x498a81=null!=_0x498a81?_0x498a81:function(){return 0x1;},_0x343e90=null!=_0x343e90?_0x343e90:function(){return 0x1;},_0x535a25=null!=_0x535a25?_0x535a25:function(_0x449edd,_0x37b985){return _0x449edd===_0x37b985?0x0:0x1;},this['_characterToIdx']=new Map(),this['_insertionCosts']=new Array(_0x2471b4['length']),this['_deletionCosts']=new Array(_0x2471b4['length']),this['_substitutionCosts']=new Array(_0x2471b4['length']);for(var _0x20896e=0x0;_0x20896e<_0x2471b4['length'];++_0x20896e){_0x17fa87=_0x2471b4[_0x20896e],this['_characterToIdx']['set'](_0x17fa87,_0x20896e),this['_insertionCosts'][_0x20896e]=_0x498a81(_0x17fa87),this['_deletionCosts'][_0x20896e]=_0x343e90(_0x17fa87),this['_substitutionCosts'][_0x20896e]=new Array(_0x2471b4['length']);for(var _0x22f9a5=_0x20896e;_0x22f9a5<_0x2471b4['length'];++_0x22f9a5)this['_substitutionCosts'][_0x20896e][_0x22f9a5]=_0x535a25(_0x17fa87,_0x2471b4[_0x22f9a5]);}}return _0x30f54b['prototype']['serialize']=function(){var _0x4a0ee0={},_0x409669=new Array(this['_characterToIdx']['size']);return this['_characterToIdx']['forEach'](function(_0x496aa9,_0x17cb4f){_0x409669[_0x496aa9]=_0x17cb4f;}),_0x4a0ee0['characters']=_0x409669,_0x4a0ee0['insertionCosts']=this['_insertionCosts'],_0x4a0ee0['deletionCosts']=this['_deletionCosts'],_0x4a0ee0['substitutionCosts']=this['_substitutionCosts'],JSON['stringify'](_0x4a0ee0);},_0x30f54b['Deserialize']=function(_0x15e9e8){var _0x3cd51b=JSON['parse'](_0x15e9e8),_0x2cc670=new _0x30f54b(_0x3cd51b['characters']);return _0x2cc670['_insertionCosts']=_0x3cd51b['insertionCosts'],_0x2cc670['_deletionCosts']=_0x3cd51b['deletionCosts'],_0x2cc670['_substitutionCosts']=_0x3cd51b['substitutionCosts'],_0x2cc670;},_0x30f54b['prototype']['getCharacterIdx']=function(_0x3509d3){return this['_characterToIdx']['get'](_0x3509d3);},_0x30f54b['prototype']['getInsertionCost']=function(_0x1caea2){return this['_insertionCosts'][_0x1caea2];},_0x30f54b['prototype']['getDeletionCost']=function(_0x38d41b){return this['_deletionCosts'][_0x38d41b];},_0x30f54b['prototype']['getSubstitutionCost']=function(_0xf74e58,_0x1a705b){var _0x1a2bd7=Math['min'](_0xf74e58,_0x1a705b),_0x292e55=Math['max'](_0xf74e58,_0x1a705b);return this['_substitutionCosts'][_0x1a2bd7][_0x292e55];},_0x30f54b;}());_0x12ed41['Alphabet']=_0x1b8640;var _0x206812=(function(){function _0x43cb56(_0x484be6,_0x2315a4){var _0x23111c=this;if(_0x484be6['length']>_0x43cb56['MAX_SEQUENCE_LENGTH'])throw new Error('Sequences\x20longer\x20than\x20'+_0x43cb56['MAX_SEQUENCE_LENGTH']+'\x20not\x20supported.');this['_alphabet']=_0x2315a4,this['_characters']=_0x484be6['map'](function(_0x63e0b7){return _0x23111c['_alphabet']['getCharacterIdx'](_0x63e0b7);});}return _0x43cb56['prototype']['serialize']=function(){return JSON['stringify'](this['_characters']);},_0x43cb56['Deserialize']=function(_0xbcb4b0,_0x8a177b){var _0x3dc35b=new _0x43cb56([],_0x8a177b);return _0x3dc35b['_characters']=JSON['parse'](_0xbcb4b0),_0x3dc35b;},_0x43cb56['prototype']['distance']=function(_0x3892f2){return _0x43cb56['_distance'](this,_0x3892f2);},_0x43cb56['_distance']=function(_0x3f0d68,_0x51d22f){var _0x4333d2=_0x3f0d68['_alphabet'];if(_0x4333d2!==_0x51d22f['_alphabet'])throw new Error('Cannot\x20Levenshtein\x20compare\x20Sequences\x20built\x20from\x20different\x20alphabets.');var _0x2db49a=_0x3f0d68['_characters'],_0xd4adf9=_0x51d22f['_characters'],_0x50bbb4=_0x2db49a['length'],_0x46de95=_0xd4adf9['length'],_0x5e52b7=_0x43cb56['_costMatrix'];_0x5e52b7[0x0][0x0]=0x0;for(var _0xe7c6e5=0x0;_0xe7c6e5<_0x50bbb4;++_0xe7c6e5)_0x5e52b7[_0xe7c6e5+0x1][0x0]=_0x5e52b7[_0xe7c6e5][0x0]+_0x4333d2['getInsertionCost'](_0x2db49a[_0xe7c6e5]);for(_0xe7c6e5=0x0;_0xe7c6e5<_0x46de95;++_0xe7c6e5)_0x5e52b7[0x0][_0xe7c6e5+0x1]=_0x5e52b7[0x0][_0xe7c6e5]+_0x4333d2['getInsertionCost'](_0xd4adf9[_0xe7c6e5]);for(var _0x1b700e=0x0;_0x1b700e<_0x50bbb4;++_0x1b700e)for(var _0x3a3267=0x0;_0x3a3267<_0x46de95;++_0x3a3267)_0x43cb56['_insertionCost']=_0x5e52b7[_0x1b700e+0x1][_0x3a3267]+_0x4333d2['getInsertionCost'](_0xd4adf9[_0x3a3267]),_0x43cb56['_deletionCost']=_0x5e52b7[_0x1b700e][_0x3a3267+0x1]+_0x4333d2['getDeletionCost'](_0x2db49a[_0x1b700e]),_0x43cb56['_substitutionCost']=_0x5e52b7[_0x1b700e][_0x3a3267]+_0x4333d2['getSubstitutionCost'](_0x2db49a[_0x1b700e],_0xd4adf9[_0x3a3267]),_0x5e52b7[_0x1b700e+0x1][_0x3a3267+0x1]=Math['min'](_0x43cb56['_insertionCost'],_0x43cb56['_deletionCost'],_0x43cb56['_substitutionCost']);return _0x5e52b7[_0x50bbb4][_0x46de95];},_0x43cb56['MAX_SEQUENCE_LENGTH']=0x100,_0x43cb56['_costMatrix']=Object(_0x18e13d['f'])(Array(_0x43cb56['MAX_SEQUENCE_LENGTH']+0x1))['map'](function(_0x58d800){return new Array(_0x43cb56['MAX_SEQUENCE_LENGTH']+0x1);}),_0x43cb56;}());_0x12ed41['Sequence']=_0x206812;}(_0x899eb4||(_0x899eb4={}));var _0x261275=(function(){function _0x4ebaad(_0x1d2a0c){void 0x0===_0x1d2a0c&&(_0x1d2a0c=0.01),this['_points']=[],this['_segmentLength']=_0x1d2a0c;}return _0x4ebaad['prototype']['serialize']=function(){return JSON['stringify'](this);},_0x4ebaad['Deserialize']=function(_0xf61f3a){var _0x4a8633=JSON['parse'](_0xf61f3a),_0x49303c=new _0x4ebaad(_0x4a8633['_segmentLength']);return _0x49303c['_points']=_0x4a8633['_points']['map'](function(_0x23d2a1){return new _0x74d525['e'](_0x23d2a1['_x'],_0x23d2a1['_y'],_0x23d2a1['_z']);}),_0x49303c;},_0x4ebaad['prototype']['getLength']=function(){return this['_points']['length']*this['_segmentLength'];},_0x4ebaad['prototype']['add']=function(_0x1eb2d3){var _0x5ed149=this,_0x2a3a6e=this['_points']['length'];if(0x0===_0x2a3a6e)this['_points']['push'](_0x1eb2d3['clone']());else for(var _0x5e8655=function(){return _0x5ed149['_segmentLength']/_0x74d525['e']['Distance'](_0x5ed149['_points'][_0x2a3a6e-0x1],_0x1eb2d3);},_0x10d428=_0x5e8655();_0x10d428<=0x1;_0x10d428=_0x5e8655()){var _0x1c2ab3=this['_points'][_0x2a3a6e-0x1]['scale'](0x1-_0x10d428);_0x1eb2d3['scaleAndAddToRef'](_0x10d428,_0x1c2ab3),this['_points']['push'](_0x1c2ab3),++_0x2a3a6e;}},_0x4ebaad['prototype']['resampleAtTargetResolution']=function(_0x2a1414){var _0x228134=new _0x4ebaad(this['getLength']()/_0x2a1414);return this['_points']['forEach'](function(_0x10fb45){_0x228134['add'](_0x10fb45);}),_0x228134;},_0x4ebaad['prototype']['tokenize']=function(_0x4c4fe5){for(var _0x3a4bd5=[],_0x4cac46=new _0x74d525['e'](),_0x3f9d35=0x2;_0x3f9d350.98)&&(_0x74d525['e']['CrossToRef'](_0x4ebaad['_forwardDir'],_0x4ebaad['_inverseFromVec'],_0x4ebaad['_upDir']),_0x4ebaad['_upDir']['normalize'](),_0x74d525['a']['LookAtLHToRef'](_0x4e2bf3,_0x11a54f,_0x4ebaad['_upDir'],_0x4ebaad['_lookMatrix']),_0x15f19f['subtractToRef'](_0x11a54f,_0x4ebaad['_fromToVec']),_0x4ebaad['_fromToVec']['normalize'](),_0x74d525['e']['TransformNormalToRef'](_0x4ebaad['_fromToVec'],_0x4ebaad['_lookMatrix'],_0x38b8fc),!0x0);},_0x4ebaad['_tokenizeSegment']=function(_0x5f277b,_0x467a32){_0x4ebaad['_bestMatch']=0x0,_0x4ebaad['_score']=_0x74d525['e']['Dot'](_0x5f277b,_0x467a32[0x0]),_0x4ebaad['_bestScore']=_0x4ebaad['_score'];for(var _0x8c7220=0x1;_0x8c7220<_0x467a32['length'];++_0x8c7220)_0x4ebaad['_score']=_0x74d525['e']['Dot'](_0x5f277b,_0x467a32[_0x8c7220]),_0x4ebaad['_score']>_0x4ebaad['_bestScore']&&(_0x4ebaad['_bestMatch']=_0x8c7220,_0x4ebaad['_bestScore']=_0x4ebaad['_score']);return _0x4ebaad['_bestMatch'];},_0x4ebaad['_forwardDir']=new _0x74d525['e'](),_0x4ebaad['_inverseFromVec']=new _0x74d525['e'](),_0x4ebaad['_upDir']=new _0x74d525['e'](),_0x4ebaad['_fromToVec']=new _0x74d525['e'](),_0x4ebaad['_lookMatrix']=new _0x74d525['a'](),_0x4ebaad;}()),_0x4ba6a9=(function(){function _0x1e2461(_0x35a98d){this['chars']=new Array(_0x35a98d);}return _0x1e2461['Generate']=function(_0x4a4c86,_0x25d730,_0x2eafc2,_0x232577,_0x1a7d9d){void 0x0===_0x4a4c86&&(_0x4a4c86=0x40),void 0x0===_0x25d730&&(_0x25d730=0x100),void 0x0===_0x2eafc2&&(_0x2eafc2=0.1),void 0x0===_0x232577&&(_0x232577=0.001),void 0x0===_0x1a7d9d&&(_0x1a7d9d=[]);for(var _0x56e329,_0x485f4e,_0x4c4a62=new _0x1e2461(_0x4a4c86),_0x238626=0x0;_0x238626<_0x4a4c86;++_0x238626)_0x4c4a62['chars'][_0x238626]=new _0x74d525['e'](Math['random']()-0.5,Math['random']()-0.5,Math['random']()-0.5),_0x4c4a62['chars'][_0x238626]['normalize']();for(_0x238626=0x0;_0x238626<_0x1a7d9d['length'];++_0x238626)_0x4c4a62['chars'][_0x238626]['copyFrom'](_0x1a7d9d[_0x238626]);for(var _0x1e9167,_0x2bc0dc=new _0x74d525['e'](),_0x43ee74=new _0x74d525['e'](),_0x31a12c=0x0;_0x31a12c<_0x25d730;++_0x31a12c){_0x56e329=(0x1-(_0x1e9167=_0x31a12c/(_0x25d730-0x1)))*_0x2eafc2+_0x1e9167*_0x232577;var _0x3b4020=function(_0x35b3b7){_0x2bc0dc['copyFromFloats'](0x0,0x0,0x0),_0x4c4a62['chars']['forEach'](function(_0x4f7617){_0x4c4a62['chars'][_0x35b3b7]['subtractToRef'](_0x4f7617,_0x43ee74),(_0x485f4e=_0x43ee74['lengthSquared']())>0.000001&&_0x43ee74['scaleAndAddToRef'](0x1/(_0x43ee74['lengthSquared']()*_0x485f4e),_0x2bc0dc);}),_0x2bc0dc['scaleInPlace'](_0x56e329),_0x4c4a62['chars'][_0x35b3b7]['addInPlace'](_0x2bc0dc),_0x4c4a62['chars'][_0x35b3b7]['normalize']();};for(_0x238626=_0x1a7d9d['length'];_0x238626<_0x4c4a62['chars']['length'];++_0x238626)_0x3b4020(_0x238626);}return _0x4c4a62;},_0x1e2461['prototype']['serialize']=function(){return JSON['stringify'](this['chars']);},_0x1e2461['Deserialize']=function(_0x476b14){for(var _0x15f097=JSON['parse'](_0x476b14),_0x205337=new _0x1e2461(_0x15f097['length']),_0x371869=0x0;_0x371869<_0x15f097['length'];++_0x371869)_0x205337['chars'][_0x371869]=new _0x74d525['e'](_0x15f097[_0x371869]['_x'],_0x15f097[_0x371869]['_y'],_0x15f097[_0x371869]['_z']);return _0x205337;},_0x1e2461;}()),_0x2a411c=(function(){function _0x1208c8(){this['_sequences']=[];}return _0x1208c8['prototype']['serialize']=function(){return JSON['stringify'](this['_sequences']['map'](function(_0x1e4b27){return _0x1e4b27['serialize']();}));},_0x1208c8['Deserialize']=function(_0x3305e8,_0x2d9e6a){var _0x468cc3=new _0x1208c8();return _0x468cc3['_sequences']=JSON['parse'](_0x3305e8)['map'](function(_0x7cd4bd){return _0x899eb4['Sequence']['Deserialize'](_0x7cd4bd,_0x2d9e6a);}),_0x468cc3;},_0x1208c8['CreateFromTrajectory']=function(_0x214b57,_0x2e24fc,_0x2d6dd5){return _0x1208c8['CreateFromTokenizationPyramid'](_0x1208c8['_getTokenizationPyramid'](_0x214b57,_0x2e24fc),_0x2d6dd5);},_0x1208c8['CreateFromTokenizationPyramid']=function(_0x2dd2c6,_0x306190){var _0x28a75d=new _0x1208c8();return _0x28a75d['_sequences']=_0x2dd2c6['map'](function(_0xfa93c9){return new _0x899eb4['Sequence'](_0xfa93c9,_0x306190);}),_0x28a75d;},_0x1208c8['_getTokenizationPyramid']=function(_0x43f36c,_0x56c265,_0x44ab1f){void 0x0===_0x44ab1f&&(_0x44ab1f=_0x1208c8['FINEST_DESCRIPTOR_RESOLUTION']);for(var _0x8a6fc0=[],_0x47f6a0=_0x44ab1f;_0x47f6a0>0x4;_0x47f6a0=Math['floor'](_0x47f6a0/0x2))_0x8a6fc0['push'](_0x43f36c['resampleAtTargetResolution'](_0x47f6a0)['tokenize'](_0x56c265['chars']));return _0x8a6fc0;},_0x1208c8['prototype']['distance']=function(_0x3870fa){for(var _0x1b770c=0x0,_0x33016d=0x0;_0x33016d0x0&&(this['_averageDistance']=Math['max'](this['_averageDistance']/this['_descriptors']['length'],_0x5df5aa['MIN_AVERAGE_DISTANCE']));},_0x5df5aa['MIN_AVERAGE_DISTANCE']=0x1,_0x5df5aa;}()),_0x2038bd=(function(){function _0xfe8393(){this['_maximumAllowableMatchCost']=0x4,this['_nameToDescribedTrajectory']=new Map();}return _0xfe8393['prototype']['serialize']=function(){var _0x4ad22d={};return _0x4ad22d['maximumAllowableMatchCost']=this['_maximumAllowableMatchCost'],_0x4ad22d['vector3Alphabet']=this['_vector3Alphabet']['serialize'](),_0x4ad22d['levenshteinAlphabet']=this['_levenshteinAlphabet']['serialize'](),_0x4ad22d['nameToDescribedTrajectory']=[],this['_nameToDescribedTrajectory']['forEach'](function(_0x30962a,_0x32a0d5){_0x4ad22d['nameToDescribedTrajectory']['push'](_0x32a0d5),_0x4ad22d['nameToDescribedTrajectory']['push'](_0x30962a['serialize']());}),JSON['stringify'](_0x4ad22d);},_0xfe8393['Deserialize']=function(_0x3bde1b){var _0x5b205f=JSON['parse'](_0x3bde1b),_0x572406=new _0xfe8393();_0x572406['_maximumAllowableMatchCost']=_0x5b205f['maximumAllowableMatchCost'],_0x572406['_vector3Alphabet']=_0x4ba6a9['Deserialize'](_0x5b205f['vector3Alphabet']),_0x572406['_levenshteinAlphabet']=_0x899eb4['Alphabet']['Deserialize'](_0x5b205f['levenshteinAlphabet']);for(var _0x34d0dd=0x0;_0x34d0dd<_0x5b205f['nameToDescribedTrajectory']['length'];_0x34d0dd+=0x2)_0x572406['_nameToDescribedTrajectory']['set'](_0x5b205f['nameToDescribedTrajectory'][_0x34d0dd],_0x28ec1f['Deserialize'](_0x5b205f['nameToDescribedTrajectory'][_0x34d0dd+0x1],_0x572406['_levenshteinAlphabet']));return _0x572406;},_0xfe8393['Generate']=function(){for(var _0x158aa7=_0x4ba6a9['Generate'](0x40,0x100,0.1,0.001,[_0x74d525['e']['Forward']()]),_0x34aa4a=new Array(_0x158aa7['chars']['length']),_0x59b80b=0x0;_0x59b80b<_0x34aa4a['length'];++_0x59b80b)_0x34aa4a[_0x59b80b]=_0x59b80b;var _0x1b1d37=new _0x899eb4['Alphabet'](_0x34aa4a,function(_0xe77345){return 0x0===_0xe77345?0x0:0x1;},function(_0x5dab61){return 0x0===_0x5dab61?0x0:0x1;},function(_0x33aae4,_0x5e4a8e){return Math['min'](0x1-_0x74d525['e']['Dot'](_0x158aa7['chars'][_0x33aae4],_0x158aa7['chars'][_0x5e4a8e]),0x1);}),_0xeb9e9d=new _0xfe8393();return _0xeb9e9d['_vector3Alphabet']=_0x158aa7,_0xeb9e9d['_levenshteinAlphabet']=_0x1b1d37,_0xeb9e9d;},_0xfe8393['prototype']['addTrajectoryToClassification']=function(_0x31a972,_0x44fabe){this['_nameToDescribedTrajectory']['has'](_0x44fabe)||this['_nameToDescribedTrajectory']['set'](_0x44fabe,new _0x28ec1f()),this['_nameToDescribedTrajectory']['get'](_0x44fabe)['add'](_0x2a411c['CreateFromTrajectory'](_0x31a972,this['_vector3Alphabet'],this['_levenshteinAlphabet']));},_0xfe8393['prototype']['deleteClassification']=function(_0x1ed735){return this['_nameToDescribedTrajectory']['delete'](_0x1ed735);},_0xfe8393['prototype']['classifyTrajectory']=function(_0x2bb66e){var _0x5b43de=this,_0x5c5061=_0x2a411c['CreateFromTrajectory'](_0x2bb66e,this['_vector3Alphabet'],this['_levenshteinAlphabet']),_0x32527d=[];if(this['_nameToDescribedTrajectory']['forEach'](function(_0x4be83d,_0x38c91e){_0x4be83d['getMatchCost'](_0x5c5061)<_0x5b43de['_maximumAllowableMatchCost']&&_0x32527d['push'](_0x38c91e);}),0x0===_0x32527d['length'])return null;for(var _0x39e092,_0x1dafb9=0x0,_0xad9de7=this['_nameToDescribedTrajectory']['get'](_0x32527d[_0x1dafb9])['getMatchMinimumDistance'](_0x5c5061),_0x4b822f=0x0;_0x4b822f<_0x32527d['length'];++_0x4b822f)(_0x39e092=this['_nameToDescribedTrajectory']['get'](_0x32527d[_0x4b822f])['getMatchMinimumDistance'](_0x5c5061))<_0xad9de7&&(_0xad9de7=_0x39e092,_0x1dafb9=_0x4b822f);return _0x32527d[_0x1dafb9];},_0xfe8393;}()),_0x41adc1=_0x162675(0x96),_0x5d7f67=function(_0x43e99f){function _0xf11475(_0x5c6ad4,_0x268dec){void 0x0===_0x268dec&&(_0x268dec={});var _0x256dc4=_0x43e99f['call'](this,_0x5c6ad4)||this;return _0x256dc4['options']=_0x268dec,_0x256dc4['_direction']=new _0x74d525['e'](0x0,0x0,-0x1),_0x256dc4['_mat']=new _0x74d525['a'](),_0x256dc4['_onSelectEnabled']=!0x1,_0x256dc4['_origin']=new _0x74d525['e'](0x0,0x0,0x0),_0x256dc4['lastNativeXRHitResults']=[],_0x256dc4['onHitTestResultObservable']=new _0x6ac1f7['c'](),_0x256dc4['_onHitTestResults']=function(_0x354271){var _0x2b863=_0x354271['map'](function(_0x58c42c){var _0x1d0a44=_0x74d525['a']['FromArray'](_0x58c42c['hitMatrix']);return _0x256dc4['_xrSessionManager']['scene']['useRightHandedSystem']||_0x1d0a44['toggleModelMatrixHandInPlace'](),_0x256dc4['options']['worldParentNode']&&_0x1d0a44['multiplyToRef'](_0x256dc4['options']['worldParentNode']['getWorldMatrix'](),_0x1d0a44),{'xrHitResult':_0x58c42c,'transformationMatrix':_0x1d0a44};});_0x256dc4['lastNativeXRHitResults']=_0x354271,_0x256dc4['onHitTestResultObservable']['notifyObservers'](_0x2b863);},_0x256dc4['_onSelect']=function(_0x3547e8){_0x256dc4['_onSelectEnabled']&&_0xf11475['XRHitTestWithSelectEvent'](_0x3547e8,_0x256dc4['_xrSessionManager']['referenceSpace']);},_0x256dc4['xrNativeFeatureName']='hit-test',_0x5d754c['b']['Warn']('A\x20newer\x20version\x20of\x20this\x20plugin\x20is\x20available'),_0x256dc4;}return Object(_0x18e13d['d'])(_0xf11475,_0x43e99f),_0xf11475['XRHitTestWithRay']=function(_0x541e12,_0x5484b7,_0x55fcbc,_0x5f1ea8){return _0x541e12['requestHitTest'](_0x5484b7,_0x55fcbc)['then'](function(_0x333dbe){var _0x37942f=_0x5f1ea8||function(_0x50b6c7){return!!_0x50b6c7['hitMatrix'];};return _0x333dbe['filter'](_0x37942f);});},_0xf11475['XRHitTestWithSelectEvent']=function(_0x4d2184,_0x2519bd){var _0x431d26=_0x4d2184['frame']['getPose'](_0x4d2184['inputSource']['targetRaySpace'],_0x2519bd);if(!_0x431d26)return Promise['resolve']([]);var _0x5c8b30=new XRRay(_0x431d26['transform']);return this['XRHitTestWithRay'](_0x4d2184['frame']['session'],_0x5c8b30,_0x2519bd);},_0xf11475['prototype']['attach']=function(){return!!_0x43e99f['prototype']['attach']['call'](this)&&(this['options']['testOnPointerDownOnly']&&this['_xrSessionManager']['session']['addEventListener']('select',this['_onSelect'],!0x1),!0x0);},_0xf11475['prototype']['detach']=function(){return!!_0x43e99f['prototype']['detach']['call'](this)&&(this['_onSelectEnabled']=!0x1,this['_xrSessionManager']['session']['removeEventListener']('select',this['_onSelect']),!0x0);},_0xf11475['prototype']['dispose']=function(){_0x43e99f['prototype']['dispose']['call'](this),this['onHitTestResultObservable']['clear']();},_0xf11475['prototype']['_onXRFrame']=function(_0x5ddb19){if(this['attached']&&!this['options']['testOnPointerDownOnly']){var _0xaf3f4d=_0x5ddb19['getViewerPose'](this['_xrSessionManager']['referenceSpace']);if(_0xaf3f4d){_0x74d525['a']['FromArrayToRef'](_0xaf3f4d['transform']['matrix'],0x0,this['_mat']),_0x74d525['e']['TransformCoordinatesFromFloatsToRef'](0x0,0x0,0x0,this['_mat'],this['_origin']),_0x74d525['e']['TransformCoordinatesFromFloatsToRef'](0x0,0x0,-0x1,this['_mat'],this['_direction']),this['_direction']['subtractInPlace'](this['_origin']),this['_direction']['normalize']();var _0x2b4072=new XRRay({'x':this['_origin']['x'],'y':this['_origin']['y'],'z':this['_origin']['z'],'w':0x0},{'x':this['_direction']['x'],'y':this['_direction']['y'],'z':this['_direction']['z'],'w':0x0});_0xf11475['XRHitTestWithRay'](this['_xrSessionManager']['session'],_0x2b4072,this['_xrSessionManager']['referenceSpace'])['then'](this['_onHitTestResults']);}}},_0xf11475['Name']=_0x216b10['HIT_TEST'],_0xf11475['Version']=0x1,_0xf11475;}(_0x2fd67e);_0x5ef0ab['AddWebXRFeature'](_0x5d7f67['Name'],function(_0x3bb1c4,_0x457c07){return function(){return new _0x5d7f67(_0x3bb1c4,_0x457c07);};},_0x5d7f67['Version'],!0x1);var _0x3cc572=0x0,_0x366775=function(_0x5ec9ee){function _0x3a0a32(_0x1d4a9f,_0x5d116e){void 0x0===_0x5d116e&&(_0x5d116e={});var _0x297262=_0x5ec9ee['call'](this,_0x1d4a9f)||this;return _0x297262['_options']=_0x5d116e,_0x297262['_lastFrameDetected']=new Set(),_0x297262['_trackedAnchors']=[],_0x297262['_futureAnchors']=[],_0x297262['onAnchorAddedObservable']=new _0x6ac1f7['c'](),_0x297262['onAnchorRemovedObservable']=new _0x6ac1f7['c'](),_0x297262['onAnchorUpdatedObservable']=new _0x6ac1f7['c'](),_0x297262['_tmpVector']=new _0x74d525['e'](),_0x297262['_tmpQuaternion']=new _0x74d525['b'](),_0x297262['xrNativeFeatureName']='anchors',_0x297262;}return Object(_0x18e13d['d'])(_0x3a0a32,_0x5ec9ee),Object['defineProperty'](_0x3a0a32['prototype'],'referenceSpaceForFrameAnchors',{'set':function(_0x504f7b){this['_referenceSpaceForFrameAnchors']=_0x504f7b;},'enumerable':!0x1,'configurable':!0x0}),_0x3a0a32['prototype']['_populateTmpTransformation']=function(_0x1287f3,_0x246740){return this['_tmpVector']['copyFrom'](_0x1287f3),this['_tmpQuaternion']['copyFrom'](_0x246740),this['_xrSessionManager']['scene']['useRightHandedSystem']||(this['_tmpVector']['z']*=-0x1,this['_tmpQuaternion']['z']*=-0x1,this['_tmpQuaternion']['w']*=-0x1),{'position':this['_tmpVector'],'rotationQuaternion':this['_tmpQuaternion']};},_0x3a0a32['prototype']['addAnchorPointUsingHitTestResultAsync']=function(_0x39eccc,_0x11a674,_0x255006){return void 0x0===_0x11a674&&(_0x11a674=new _0x74d525['e']()),void 0x0===_0x255006&&(_0x255006=new _0x74d525['b']()),Object(_0x18e13d['b'])(this,void 0x0,void 0x0,function(){var _0x1f5bec,_0x5ec304,_0xcba99e,_0x43bdd1=this;return Object(_0x18e13d['e'])(this,function(_0x3543c2){switch(_0x3543c2['label']){case 0x0:if(this['_populateTmpTransformation'](_0x11a674,_0x255006),_0x1f5bec=new XRRigidTransform({'x':this['_tmpVector']['x'],'y':this['_tmpVector']['y'],'z':this['_tmpVector']['z']},{'x':this['_tmpQuaternion']['x'],'y':this['_tmpQuaternion']['y'],'z':this['_tmpQuaternion']['z'],'w':this['_tmpQuaternion']['w']}),_0x39eccc['xrHitResult']['createAnchor'])return[0x3,0x1];throw this['detach'](),new Error('Anchors\x20not\x20enabled\x20in\x20this\x20environment/browser');case 0x1:return _0x3543c2['trys']['push']([0x1,0x3,,0x4]),[0x4,_0x39eccc['xrHitResult']['createAnchor'](_0x1f5bec)];case 0x2:return _0x5ec304=_0x3543c2['sent'](),[0x2,new Promise(function(_0x4d41b6,_0x3110d5){_0x43bdd1['_futureAnchors']['push']({'nativeAnchor':_0x5ec304,'resolved':!0x1,'submitted':!0x0,'xrTransformation':_0x1f5bec,'resolve':_0x4d41b6,'reject':_0x3110d5});})];case 0x3:throw _0xcba99e=_0x3543c2['sent'](),new Error(_0xcba99e);case 0x4:return[0x2];}});});},_0x3a0a32['prototype']['addAnchorAtPositionAndRotationAsync']=function(_0x4c2216,_0x3fbe50,_0x5acf25){return void 0x0===_0x3fbe50&&(_0x3fbe50=new _0x74d525['b']()),void 0x0===_0x5acf25&&(_0x5acf25=!0x1),Object(_0x18e13d['b'])(this,void 0x0,void 0x0,function(){var _0x51109b,_0xcb1d3f,_0x5289d4,_0xfc3bd7=this;return Object(_0x18e13d['e'])(this,function(_0x131810){switch(_0x131810['label']){case 0x0:return this['_populateTmpTransformation'](_0x4c2216,_0x3fbe50),_0x51109b=new XRRigidTransform({'x':this['_tmpVector']['x'],'y':this['_tmpVector']['y'],'z':this['_tmpVector']['z']},{'x':this['_tmpQuaternion']['x'],'y':this['_tmpQuaternion']['y'],'z':this['_tmpQuaternion']['z'],'w':this['_tmpQuaternion']['w']}),_0x5acf25&&this['attached']&&this['_xrSessionManager']['currentFrame']?[0x4,this['_createAnchorAtTransformation'](_0x51109b,this['_xrSessionManager']['currentFrame'])]:[0x3,0x2];case 0x1:return _0x5289d4=_0x131810['sent'](),[0x3,0x3];case 0x2:_0x5289d4=void 0x0,_0x131810['label']=0x3;case 0x3:return _0xcb1d3f=_0x5289d4,[0x2,new Promise(function(_0x26b06c,_0x27f3f8){_0xfc3bd7['_futureAnchors']['push']({'nativeAnchor':_0xcb1d3f,'resolved':!0x1,'submitted':!0x1,'xrTransformation':_0x51109b,'resolve':_0x26b06c,'reject':_0x27f3f8});})];}});});},Object['defineProperty'](_0x3a0a32['prototype'],'anchors',{'get':function(){return this['_trackedAnchors'];},'enumerable':!0x1,'configurable':!0x0}),_0x3a0a32['prototype']['detach']=function(){if(!_0x5ec9ee['prototype']['detach']['call'](this))return!0x1;if(!this['_options']['doNotRemoveAnchorsOnSessionEnded'])for(;this['_trackedAnchors']['length'];){var _0x52a92f=this['_trackedAnchors']['pop']();if(_0x52a92f){try{_0x52a92f['remove']();}catch(_0x2d674a){}this['onAnchorRemovedObservable']['notifyObservers'](_0x52a92f);}}return!0x0;},_0x3a0a32['prototype']['dispose']=function(){this['_futureAnchors']['length']=0x0,_0x5ec9ee['prototype']['dispose']['call'](this),this['onAnchorAddedObservable']['clear'](),this['onAnchorRemovedObservable']['clear'](),this['onAnchorUpdatedObservable']['clear']();},_0x3a0a32['prototype']['_onXRFrame']=function(_0x500c21){var _0x52b25a=this;if(this['attached']&&_0x500c21){var _0x18bb93=_0x500c21['trackedAnchors'];if(_0x18bb93){var _0x259131=this['_trackedAnchors']['filter'](function(_0x2b1550){return!_0x18bb93['has'](_0x2b1550['xrAnchor']);})['map'](function(_0x4d7f5b){return _0x52b25a['_trackedAnchors']['indexOf'](_0x4d7f5b);}),_0x5045d4=0x0;_0x259131['forEach'](function(_0x20c041){var _0x1db18e=_0x52b25a['_trackedAnchors']['splice'](_0x20c041-_0x5045d4,0x1)[0x0];_0x52b25a['onAnchorRemovedObservable']['notifyObservers'](_0x1db18e),_0x5045d4++;}),_0x18bb93['forEach'](function(_0x59197d){if(_0x52b25a['_lastFrameDetected']['has'](_0x59197d)){var _0xee346=_0x52b25a['_findIndexInAnchorArray'](_0x59197d);_0x5d179f=_0x52b25a['_trackedAnchors'][_0xee346];try{_0x52b25a['_updateAnchorWithXRFrame'](_0x59197d,_0x5d179f,_0x500c21),_0x5d179f['attachedNode']&&(_0x5d179f['attachedNode']['rotationQuaternion']=_0x5d179f['attachedNode']['rotationQuaternion']||new _0x74d525['b'](),_0x5d179f['transformationMatrix']['decompose'](_0x5d179f['attachedNode']['scaling'],_0x5d179f['attachedNode']['rotationQuaternion'],_0x5d179f['attachedNode']['position'])),_0x52b25a['onAnchorUpdatedObservable']['notifyObservers'](_0x5d179f);}catch(_0x111a16){_0x5d754c['b']['Warn']('Anchor\x20could\x20not\x20be\x20updated');}}else{var _0x31a02e={'id':_0x3cc572++,'xrAnchor':_0x59197d,'remove':_0x59197d['delete']},_0x5d179f=_0x52b25a['_updateAnchorWithXRFrame'](_0x59197d,_0x31a02e,_0x500c21);_0x52b25a['_trackedAnchors']['push'](_0x5d179f),_0x52b25a['onAnchorAddedObservable']['notifyObservers'](_0x5d179f);var _0x4f1526=_0x52b25a['_futureAnchors']['filter'](function(_0xceaca4){return _0xceaca4['nativeAnchor']===_0x59197d;})[0x0];_0x4f1526&&(_0x4f1526['resolve'](_0x5d179f),_0x4f1526['resolved']=!0x0);}}),this['_lastFrameDetected']=_0x18bb93;}this['_futureAnchors']['forEach'](function(_0x5df17b){_0x5df17b['resolved']||_0x5df17b['submitted']||(_0x52b25a['_createAnchorAtTransformation'](_0x5df17b['xrTransformation'],_0x500c21)['then'](function(_0x3ebf45){_0x5df17b['nativeAnchor']=_0x3ebf45;},function(_0x34cca5){_0x5df17b['resolved']=!0x0,_0x5df17b['reject'](_0x34cca5);}),_0x5df17b['submitted']=!0x0);});}},_0x3a0a32['prototype']['_findIndexInAnchorArray']=function(_0x48860f){for(var _0x3ffb58=0x0;_0x3ffb580x0&&this['onFeaturePointsAddedObservable']['notifyObservers'](_0x2f4bd3),_0x3214c7['length']>0x0&&this['onFeaturePointsUpdatedObservable']['notifyObservers'](_0x3214c7);}}},_0x1e494a['prototype']['_init']=function(){this['_xrSessionManager']['session']['trySetFeaturePointCloudEnabled']&&this['_xrSessionManager']['session']['trySetFeaturePointCloudEnabled'](!0x0)&&(this['_enabled']=!0x0);},_0x1e494a['Name']=_0x216b10['FEATURE_POINTS'],_0x1e494a['Version']=0x1,_0x1e494a;}(_0x2fd67e);_0x5ef0ab['AddWebXRFeature'](_0x5afa2d['Name'],function(_0x17eee9){return function(){return new _0x5afa2d(_0x17eee9);};},_0x5afa2d['Version']);var _0x1ad3fc=(function(){function _0x4368a8(_0x4690a5,_0x34f409,_0x42a9d2,_0x489bc5,_0x4057f6){this['xrController']=_0x4690a5,this['trackedMeshes']=_0x34f409,this['_handMesh']=_0x42a9d2,this['_rigMapping']=_0x489bc5,this['_defaultHandMesh']=!0x1,this['_transformNodeMapping']=[],this['handPartsDefinition']=this['generateHandPartsDefinition'](_0x4690a5['inputSource']['hand']),this['_scene']=_0x34f409[0x0]['getScene'](),this['_handMesh']&&this['_rigMapping']?this['_defaultHandMesh']=!0x1:_0x4057f6||this['_generateDefaultHandMesh'](),this['xrController']['motionController']&&(this['xrController']['motionController']['rootMesh']?this['xrController']['motionController']['rootMesh']['setEnabled'](!0x1):this['xrController']['motionController']['onModelLoadedObservable']['add'](function(_0x58b292){_0x58b292['rootMesh']&&_0x58b292['rootMesh']['setEnabled'](!0x1);})),this['xrController']['onMotionControllerInitObservable']['add'](function(_0x5b505d){_0x5b505d['onModelLoadedObservable']['add'](function(_0x4f0c87){_0x4f0c87['rootMesh']&&_0x4f0c87['rootMesh']['setEnabled'](!0x1);}),_0x5b505d['rootMesh']&&_0x5b505d['rootMesh']['setEnabled'](!0x1);});}return _0x4368a8['prototype']['generateHandPartsDefinition']=function(_0x24d27e){var _0x4300f1;return(_0x4300f1={})['wrist']=[_0x24d27e['WRIST']],_0x4300f1['thumb']=[_0x24d27e['THUMB_METACARPAL'],_0x24d27e['THUMB_PHALANX_PROXIMAL'],_0x24d27e['THUMB_PHALANX_DISTAL'],_0x24d27e['THUMB_PHALANX_TIP']],_0x4300f1['index']=[_0x24d27e['INDEX_METACARPAL'],_0x24d27e['INDEX_PHALANX_PROXIMAL'],_0x24d27e['INDEX_PHALANX_INTERMEDIATE'],_0x24d27e['INDEX_PHALANX_DISTAL'],_0x24d27e['INDEX_PHALANX_TIP']],_0x4300f1['middle']=[_0x24d27e['MIDDLE_METACARPAL'],_0x24d27e['MIDDLE_PHALANX_PROXIMAL'],_0x24d27e['MIDDLE_PHALANX_INTERMEDIATE'],_0x24d27e['MIDDLE_PHALANX_DISTAL'],_0x24d27e['MIDDLE_PHALANX_TIP']],_0x4300f1['ring']=[_0x24d27e['RING_METACARPAL'],_0x24d27e['RING_PHALANX_PROXIMAL'],_0x24d27e['RING_PHALANX_INTERMEDIATE'],_0x24d27e['RING_PHALANX_DISTAL'],_0x24d27e['RING_PHALANX_TIP']],_0x4300f1['little']=[_0x24d27e['LITTLE_METACARPAL'],_0x24d27e['LITTLE_PHALANX_PROXIMAL'],_0x24d27e['LITTLE_PHALANX_INTERMEDIATE'],_0x24d27e['LITTLE_PHALANX_DISTAL'],_0x24d27e['LITTLE_PHALANX_TIP']],_0x4300f1;},_0x4368a8['prototype']['updateFromXRFrame']=function(_0x139abd,_0x4d1303,_0xf94a6d){var _0x54a47c=this;void 0x0===_0xf94a6d&&(_0xf94a6d=0x2);var _0x58a567=this['xrController']['inputSource']['hand'];_0x58a567&&this['trackedMeshes']['forEach'](function(_0x56551b,_0xb2b53d){var _0x351120=_0x58a567[_0xb2b53d];if(_0x351120){var _0x1237e7=_0x139abd['getJointPose'](_0x351120,_0x4d1303);if(!_0x1237e7||!_0x1237e7['transform'])return;var _0x3a690b=_0x1237e7['transform']['position'],_0x1ad059=_0x1237e7['transform']['orientation'];_0x56551b['position']['set'](_0x3a690b['x'],_0x3a690b['y'],_0x3a690b['z']),_0x56551b['rotationQuaternion']['set'](_0x1ad059['x'],_0x1ad059['y'],_0x1ad059['z'],_0x1ad059['w']);var _0x753e29=(_0x1237e7['radius']||0.008)*_0xf94a6d;_0x56551b['scaling']['set'](_0x753e29,_0x753e29,_0x753e29),_0x54a47c['_handMesh']&&_0x54a47c['_rigMapping']&&_0x54a47c['_rigMapping'][_0xb2b53d]&&(_0x54a47c['_transformNodeMapping'][_0xb2b53d]=_0x54a47c['_transformNodeMapping'][_0xb2b53d]||_0x54a47c['_scene']['getTransformNodeByName'](_0x54a47c['_rigMapping'][_0xb2b53d]),_0x54a47c['_transformNodeMapping'][_0xb2b53d]&&(_0x54a47c['_transformNodeMapping'][_0xb2b53d]['position']['copyFrom'](_0x56551b['position']),_0x54a47c['_transformNodeMapping'][_0xb2b53d]['rotationQuaternion']['copyFrom'](_0x56551b['rotationQuaternion']),_0x56551b['isVisible']=!0x1)),_0x56551b['getScene']()['useRightHandedSystem']||(_0x56551b['position']['z']*=-0x1,_0x56551b['rotationQuaternion']['z']*=-0x1,_0x56551b['rotationQuaternion']['w']*=-0x1);}});},_0x4368a8['prototype']['getHandPartMeshes']=function(_0x4cfbb9){var _0x14863b=this;return this['handPartsDefinition'][_0x4cfbb9]['map'](function(_0x50bee1){return _0x14863b['trackedMeshes'][_0x50bee1];});},_0x4368a8['prototype']['dispose']=function(){this['trackedMeshes']['forEach'](function(_0x25955f){return _0x25955f['dispose']();}),this['_defaultHandMesh']&&this['_handMesh']&&this['_handMesh']['dispose']();},_0x4368a8['prototype']['_generateDefaultHandMesh']=function(){return Object(_0x18e13d['b'])(this,void 0x0,void 0x0,function(){var _0x3c2684,_0x3fce2f,_0x417949,_0x2bfdc6,_0x4be1ff,_0x399f8e,_0x388dbe,_0x24effd;return Object(_0x18e13d['e'])(this,function(_0x19282c){switch(_0x19282c['label']){case 0x0:return _0x19282c['trys']['push']([0x0,0x3,,0x4]),_0x3c2684='right'===this['xrController']['inputSource']['handedness']?'right':'left',_0x3fce2f=('right'===_0x3c2684?'r':'l')+'_hand_'+(this['_scene']['useRightHandedSystem']?'r':'l')+'hs.glb',[0x4,_0x5de01e['ImportMeshAsync']('','https://assets.babylonjs.com/meshes/HandMeshes/',_0x3fce2f,this['_scene'])];case 0x1:return _0x417949=_0x19282c['sent'](),_0x2bfdc6={'base':_0x39310d['a']['FromInts'](0x74,0x3f,0xcb),'fresnel':_0x39310d['a']['FromInts'](0x95,0x66,0xe5),'fingerColor':_0x39310d['a']['FromInts'](0xb1,0x82,0xff),'tipFresnel':_0x39310d['a']['FromInts'](0xdc,0xc8,0xff)},[0x4,(_0x4be1ff=new _0x457d3e('leftHandShader',this['_scene'],{'emitComments':!0x1}))['loadAsync']('https://patrickryanms.github.io/BabylonJStextures/Demos/xrHandMesh/handsShader.json')];case 0x2:if(_0x19282c['sent'](),_0x4be1ff['build'](!0x1),_0x4be1ff['needDepthPrePass']=!0x0,_0x4be1ff['transparencyMode']=_0x33c2e5['a']['MATERIAL_ALPHABLEND'],_0x4be1ff['alphaMode']=_0x300b38['a']['ALPHA_COMBINE'],(_0x399f8e={'base':_0x4be1ff['getBlockByName']('baseColor'),'fresnel':_0x4be1ff['getBlockByName']('fresnelColor'),'fingerColor':_0x4be1ff['getBlockByName']('fingerColor'),'tipFresnel':_0x4be1ff['getBlockByName']('tipFresnelColor')})['base']['value']=_0x2bfdc6['base'],_0x399f8e['fresnel']['value']=_0x2bfdc6['fresnel'],_0x399f8e['fingerColor']['value']=_0x2bfdc6['fingerColor'],_0x399f8e['tipFresnel']['value']=_0x2bfdc6['tipFresnel'],_0x417949['meshes'][0x1]['material']=_0x4be1ff,this['_defaultHandMesh']=!0x0,this['_handMesh']=_0x417949['meshes'][0x0],this['_rigMapping']=['wrist_','thumb_metacarpal_','thumb_proxPhalanx_','thumb_distPhalanx_','thumb_tip_','index_metacarpal_','index_proxPhalanx_','index_intPhalanx_','index_distPhalanx_','index_tip_','middle_metacarpal_','middle_proxPhalanx_','middle_intPhalanx_','middle_distPhalanx_','middle_tip_','ring_metacarpal_','ring_proxPhalanx_','ring_intPhalanx_','ring_distPhalanx_','ring_tip_','little_metacarpal_','little_proxPhalanx_','little_intPhalanx_','little_distPhalanx_','little_tip_']['map'](function(_0x244d34){return _0x244d34+('right'===_0x3c2684?'R':'L');}),!(_0x388dbe=this['_scene']['getTransformNodeByName'](this['_rigMapping'][0x0])))throw new Error('could\x20not\x20find\x20the\x20wrist\x20node');return _0x388dbe['parent']&&_0x388dbe['parent']['rotate'](_0x4a79a2['a']['Y'],Math['PI']),[0x3,0x4];case 0x3:return _0x24effd=_0x19282c['sent'](),_0x5d754c['b']['Error']('error\x20loading\x20hand\x20mesh'),console['log'](_0x24effd),[0x3,0x4];case 0x4:return[0x2];}});});},_0x4368a8;}()),_0x41e0b1=function(_0x52b2e3){function _0x2b56db(_0x28328b,_0x469fbc){var _0x4caaa2=_0x52b2e3['call'](this,_0x28328b)||this;return _0x4caaa2['options']=_0x469fbc,_0x4caaa2['onHandAddedObservable']=new _0x6ac1f7['c'](),_0x4caaa2['onHandRemovedObservable']=new _0x6ac1f7['c'](),_0x4caaa2['_hands']={},_0x4caaa2['_attachHand']=function(_0x5b9717){var _0x1cefad,_0x5b0660,_0x51cda0,_0xe43515,_0x414c7a,_0x18db28,_0x37359c,_0x31e453,_0x33cce9,_0x334bdb;if(_0x5b9717['inputSource']['hand']&&!_0x4caaa2['_hands'][_0x5b9717['uniqueId']]){var _0x42dbbb=_0x5b9717['inputSource']['hand'],_0x102fd8=[],_0x2e7438=(null===(_0x1cefad=_0x4caaa2['options']['jointMeshes'])||void 0x0===_0x1cefad?void 0x0:_0x1cefad['sourceMesh'])||_0x5c4f8d['a']['CreateSphere']('jointParent',{'diameter':0x1});_0x2e7438['isVisible']=!!(null===(_0x5b0660=_0x4caaa2['options']['jointMeshes'])||void 0x0===_0x5b0660?void 0x0:_0x5b0660['keepOriginalVisible']);for(var _0x3fd657=0x0;_0x3fd657<_0x42dbbb['length'];++_0x3fd657){var _0x4730bb=_0x2e7438['createInstance'](_0x5b9717['uniqueId']+'-handJoint-'+_0x3fd657);if(null===(_0x51cda0=_0x4caaa2['options']['jointMeshes'])||void 0x0===_0x51cda0?void 0x0:_0x51cda0['onHandJointMeshGenerated']){var _0x5e3cea=_0x4caaa2['options']['jointMeshes']['onHandJointMeshGenerated'](_0x4730bb,_0x3fd657,_0x5b9717['uniqueId']);_0x5e3cea&&_0x5e3cea!==_0x4730bb&&(_0x4730bb['dispose'](),_0x4730bb=_0x5e3cea);}if(_0x4730bb['isPickable']=!0x1,null===(_0xe43515=_0x4caaa2['options']['jointMeshes'])||void 0x0===_0xe43515?void 0x0:_0xe43515['enablePhysics']){var _0x565a7f=_0x4caaa2['options']['jointMeshes']['physicsProps']||{},_0x5d7499=void 0x0!==_0x565a7f['impostorType']?_0x565a7f['impostorType']:_0x3c10c7['a']['SphereImpostor'];_0x4730bb['physicsImpostor']=new _0x3c10c7['a'](_0x4730bb,_0x5d7499,Object(_0x18e13d['a'])({'mass':0x0},_0x565a7f));}_0x4730bb['rotationQuaternion']=new _0x74d525['b'](),(null===(_0x414c7a=_0x4caaa2['options']['jointMeshes'])||void 0x0===_0x414c7a?void 0x0:_0x414c7a['invisible'])&&(_0x4730bb['isVisible']=!0x1),_0x102fd8['push'](_0x4730bb);}var _0x2e98e2='right'===_0x5b9717['inputSource']['handedness']?'right':'left',_0x323e8e=(null===(_0x18db28=_0x4caaa2['options']['jointMeshes'])||void 0x0===_0x18db28?void 0x0:_0x18db28['handMeshes'])&&(null===(_0x37359c=_0x4caaa2['options']['jointMeshes'])||void 0x0===_0x37359c?void 0x0:_0x37359c['handMeshes'][_0x2e98e2]),_0x54c4ea=(null===(_0x31e453=_0x4caaa2['options']['jointMeshes'])||void 0x0===_0x31e453?void 0x0:_0x31e453['rigMapping'])&&(null===(_0x33cce9=_0x4caaa2['options']['jointMeshes'])||void 0x0===_0x33cce9?void 0x0:_0x33cce9['rigMapping'][_0x2e98e2]),_0x4710c8=new _0x1ad3fc(_0x5b9717,_0x102fd8,_0x323e8e,_0x54c4ea,null===(_0x334bdb=_0x4caaa2['options']['jointMeshes'])||void 0x0===_0x334bdb?void 0x0:_0x334bdb['disableDefaultHandMesh']);_0x4caaa2['_hands'][_0x5b9717['uniqueId']]={'handObject':_0x4710c8,'id':_0x2b56db['_idCounter']++},_0x4caaa2['onHandAddedObservable']['notifyObservers'](_0x4710c8);}},_0x4caaa2['xrNativeFeatureName']='hand-tracking',_0x4caaa2;}return Object(_0x18e13d['d'])(_0x2b56db,_0x52b2e3),_0x2b56db['prototype']['isCompatible']=function(){return'undefined'!=typeof XRHand;},_0x2b56db['prototype']['attach']=function(){var _0x491799=this;return!!_0x52b2e3['prototype']['attach']['call'](this)&&(this['options']['xrInput']['controllers']['forEach'](this['_attachHand']),this['_addNewAttachObserver'](this['options']['xrInput']['onControllerAddedObservable'],this['_attachHand']),this['_addNewAttachObserver'](this['options']['xrInput']['onControllerRemovedObservable'],function(_0x5ae5e9){_0x491799['_detachHand'](_0x5ae5e9['uniqueId']);}),!0x0);},_0x2b56db['prototype']['detach']=function(){var _0x56c66c=this;return!!_0x52b2e3['prototype']['detach']['call'](this)&&(Object['keys'](this['_hands'])['forEach'](function(_0x196f2b){_0x56c66c['_detachHand'](_0x196f2b);}),!0x0);},_0x2b56db['prototype']['dispose']=function(){_0x52b2e3['prototype']['dispose']['call'](this),this['onHandAddedObservable']['clear']();},_0x2b56db['prototype']['getHandByControllerId']=function(_0x51310e){var _0x180850;return(null===(_0x180850=this['_hands'][_0x51310e])||void 0x0===_0x180850?void 0x0:_0x180850['handObject'])||null;},_0x2b56db['prototype']['getHandByHandedness']=function(_0x22025c){var _0x587d3c=this,_0x33daec=Object['keys'](this['_hands'])['map'](function(_0x51516b){return _0x587d3c['_hands'][_0x51516b]['handObject']['xrController']['inputSource']['handedness'];})['indexOf'](_0x22025c);return-0x1!==_0x33daec?this['_hands'][_0x33daec]['handObject']:null;},_0x2b56db['prototype']['_onXRFrame']=function(_0x66ff5c){var _0x524a77=this;Object['keys'](this['_hands'])['forEach'](function(_0x2e1833){var _0x440dbf;_0x524a77['_hands'][_0x2e1833]['handObject']['updateFromXRFrame'](_0x66ff5c,_0x524a77['_xrSessionManager']['referenceSpace'],null===(_0x440dbf=_0x524a77['options']['jointMeshes'])||void 0x0===_0x440dbf?void 0x0:_0x440dbf['scaleFactor']);});},_0x2b56db['prototype']['_detachHand']=function(_0x34bff6){this['_hands'][_0x34bff6]&&(this['onHandRemovedObservable']['notifyObservers'](this['_hands'][_0x34bff6]['handObject']),this['_hands'][_0x34bff6]['handObject']['dispose']());},_0x2b56db['_idCounter']=0x0,_0x2b56db['Name']=_0x216b10['HAND_TRACKING'],_0x2b56db['Version']=0x1,_0x2b56db;}(_0x2fd67e);_0x5ef0ab['AddWebXRFeature'](_0x41e0b1['Name'],function(_0x150c0f,_0x21a8d7){return function(){return new _0x41e0b1(_0x150c0f,_0x21a8d7);};},_0x41e0b1['Version'],!0x1);var _0x5545b9=function(_0x250fd7){function _0x2bed9a(_0x5f1d1d,_0x3c1829,_0x1816b6){var _0x988527=_0x250fd7['call'](this,_0x5f1d1d,_0x1306f9['left-right'],_0x3c1829,_0x1816b6)||this;return _0x988527['_mapping']={'defaultButton':{'valueNodeName':'VALUE','unpressedNodeName':'UNPRESSED','pressedNodeName':'PRESSED'},'defaultAxis':{'valueNodeName':'VALUE','minNodeName':'MIN','maxNodeName':'MAX'},'buttons':{'xr-standard-trigger':{'rootNodeName':'SELECT','componentProperty':'button','states':['default','touched','pressed']},'xr-standard-squeeze':{'rootNodeName':'GRASP','componentProperty':'state','states':['pressed']},'xr-standard-touchpad':{'rootNodeName':'TOUCHPAD_PRESS','labelAnchorNodeName':'squeeze-label','touchPointNodeName':'TOUCH'},'xr-standard-thumbstick':{'rootNodeName':'THUMBSTICK_PRESS','componentProperty':'state','states':['pressed']}},'axes':{'xr-standard-touchpad':{'x-axis':{'rootNodeName':'TOUCHPAD_TOUCH_X'},'y-axis':{'rootNodeName':'TOUCHPAD_TOUCH_Y'}},'xr-standard-thumbstick':{'x-axis':{'rootNodeName':'THUMBSTICK_X'},'y-axis':{'rootNodeName':'THUMBSTICK_Y'}}}},_0x988527['profileId']='microsoft-mixed-reality',_0x988527;}return Object(_0x18e13d['d'])(_0x2bed9a,_0x250fd7),_0x2bed9a['prototype']['_getFilenameAndPath']=function(){return{'filename':'left'===this['handedness']?_0x2bed9a['MODEL_LEFT_FILENAME']:_0x2bed9a['MODEL_RIGHT_FILENAME'],'path':_0x2bed9a['MODEL_BASE_URL']+'default/'};},_0x2bed9a['prototype']['_getModelLoadingConstraints']=function(){var _0x30df0a=_0x5de01e['IsPluginForExtensionAvailable']('.glb');return _0x30df0a||_0x75193d['a']['Warn']('glTF\x20/\x20glb\x20loaded\x20was\x20not\x20registered,\x20using\x20generic\x20controller\x20instead'),_0x30df0a;},_0x2bed9a['prototype']['_processLoadedModel']=function(_0x2bb103){var _0x139c95=this;this['rootMesh']&&(this['getComponentIds']()['forEach'](function(_0x2e69e8,_0x1a537c){if(!_0x139c95['disableAnimation']&&_0x2e69e8&&_0x139c95['rootMesh']){var _0x5d11e4=_0x139c95['_mapping']['buttons'][_0x2e69e8],_0x24d658=_0x5d11e4['rootNodeName'];if(!_0x24d658)return void _0x75193d['a']['Log']('Skipping\x20unknown\x20button\x20at\x20index:\x20'+_0x1a537c+'\x20with\x20mapped\x20name:\x20'+_0x2e69e8);var _0x296c4b=_0x139c95['_getChildByName'](_0x139c95['rootMesh'],_0x24d658);if(!_0x296c4b)return void _0x75193d['a']['Warn']('Missing\x20button\x20mesh\x20with\x20name:\x20'+_0x24d658);if(_0x5d11e4['valueMesh']=_0x139c95['_getImmediateChildByName'](_0x296c4b,_0x139c95['_mapping']['defaultButton']['valueNodeName']),_0x5d11e4['pressedMesh']=_0x139c95['_getImmediateChildByName'](_0x296c4b,_0x139c95['_mapping']['defaultButton']['pressedNodeName']),_0x5d11e4['unpressedMesh']=_0x139c95['_getImmediateChildByName'](_0x296c4b,_0x139c95['_mapping']['defaultButton']['unpressedNodeName']),_0x5d11e4['valueMesh']&&_0x5d11e4['pressedMesh']&&_0x5d11e4['unpressedMesh']){var _0x537817=_0x139c95['getComponent'](_0x2e69e8);_0x537817&&_0x537817['onButtonStateChangedObservable']['add'](function(_0x5558ff){_0x139c95['_lerpTransform'](_0x5d11e4,_0x5558ff['value']);},void 0x0,!0x0);}else _0x75193d['a']['Warn']('Missing\x20button\x20submesh\x20under\x20mesh\x20with\x20name:\x20'+_0x24d658);}}),this['getComponentIds']()['forEach'](function(_0x96b4b7,_0xa67bd1){var _0x3c51c2=_0x139c95['getComponent'](_0x96b4b7);_0x3c51c2['isAxes']()&&['x-axis','y-axis']['forEach'](function(_0x4476f4){if(_0x139c95['rootMesh']){var _0x2c3744=_0x139c95['_mapping']['axes'][_0x96b4b7][_0x4476f4],_0x1ecd8a=_0x139c95['_getChildByName'](_0x139c95['rootMesh'],_0x2c3744['rootNodeName']);_0x1ecd8a?(_0x2c3744['valueMesh']=_0x139c95['_getImmediateChildByName'](_0x1ecd8a,_0x139c95['_mapping']['defaultAxis']['valueNodeName']),_0x2c3744['minMesh']=_0x139c95['_getImmediateChildByName'](_0x1ecd8a,_0x139c95['_mapping']['defaultAxis']['minNodeName']),_0x2c3744['maxMesh']=_0x139c95['_getImmediateChildByName'](_0x1ecd8a,_0x139c95['_mapping']['defaultAxis']['maxNodeName']),_0x2c3744['valueMesh']&&_0x2c3744['minMesh']&&_0x2c3744['maxMesh']?_0x3c51c2&&_0x3c51c2['onAxisValueChangedObservable']['add'](function(_0x40d24f){var _0x1d6ca5='x-axis'===_0x4476f4?_0x40d24f['x']:_0x40d24f['y'];_0x139c95['_lerpTransform'](_0x2c3744,_0x1d6ca5,!0x0);},void 0x0,!0x0):_0x75193d['a']['Warn']('Missing\x20axis\x20submesh\x20under\x20mesh\x20with\x20name:\x20'+_0x2c3744['rootNodeName'])):_0x75193d['a']['Warn']('Missing\x20axis\x20mesh\x20with\x20name:\x20'+_0x2c3744['rootNodeName']);}});}));},_0x2bed9a['prototype']['_setRootMesh']=function(_0x3b5294){var _0x5f2bbc;this['rootMesh']=new _0x3cf5e5['a'](this['profileId']+'\x20'+this['handedness'],this['scene']),this['rootMesh']['isPickable']=!0x1;for(var _0x14f42d=0x0;_0x14f42d<_0x3b5294['length'];_0x14f42d++){var _0xb0fc53=_0x3b5294[_0x14f42d];_0xb0fc53['isPickable']=!0x1,_0xb0fc53['parent']||(_0x5f2bbc=_0xb0fc53);}_0x5f2bbc&&_0x5f2bbc['setParent'](this['rootMesh']),this['scene']['useRightHandedSystem']||(this['rootMesh']['rotationQuaternion']=_0x74d525['b']['FromEulerAngles'](0x0,Math['PI'],0x0));},_0x2bed9a['prototype']['_updateModel']=function(){},_0x2bed9a['MODEL_BASE_URL']='https://controllers.babylonjs.com/microsoft/',_0x2bed9a['MODEL_LEFT_FILENAME']='left.glb',_0x2bed9a['MODEL_RIGHT_FILENAME']='right.glb',_0x2bed9a;}(_0x48fb5b);_0x13267d['RegisterController']('windows-mixed-reality',function(_0x2d0fc4,_0xb5ac88){return new _0x5545b9(_0xb5ac88,_0x2d0fc4['gamepad'],_0x2d0fc4['handedness']);});var _0x1306f9={'left':{'selectComponentId':'xr-standard-trigger','components':{'xr-standard-trigger':{'type':'trigger','gamepadIndices':{'button':0x0},'rootNodeName':'xr_standard_trigger','visualResponses':{'xr_standard_trigger_pressed':{'componentProperty':'button','states':['default','touched','pressed'],'valueNodeProperty':'transform','valueNodeName':'xr_standard_trigger_pressed_value','minNodeName':'xr_standard_trigger_pressed_min','maxNodeName':'xr_standard_trigger_pressed_max'}}},'xr-standard-squeeze':{'type':'squeeze','gamepadIndices':{'button':0x1},'rootNodeName':'xr_standard_squeeze','visualResponses':{'xr_standard_squeeze_pressed':{'componentProperty':'button','states':['default','touched','pressed'],'valueNodeProperty':'transform','valueNodeName':'xr_standard_squeeze_pressed_value','minNodeName':'xr_standard_squeeze_pressed_min','maxNodeName':'xr_standard_squeeze_pressed_max'}}},'xr-standard-touchpad':{'type':'touchpad','gamepadIndices':{'button':0x2,'xAxis':0x0,'yAxis':0x1},'rootNodeName':'xr_standard_touchpad','visualResponses':{'xr_standard_touchpad_pressed':{'componentProperty':'button','states':['default','touched','pressed'],'valueNodeProperty':'transform','valueNodeName':'xr_standard_touchpad_pressed_value','minNodeName':'xr_standard_touchpad_pressed_min','maxNodeName':'xr_standard_touchpad_pressed_max'},'xr_standard_touchpad_xaxis_pressed':{'componentProperty':'xAxis','states':['default','touched','pressed'],'valueNodeProperty':'transform','valueNodeName':'xr_standard_touchpad_xaxis_pressed_value','minNodeName':'xr_standard_touchpad_xaxis_pressed_min','maxNodeName':'xr_standard_touchpad_xaxis_pressed_max'},'xr_standard_touchpad_yaxis_pressed':{'componentProperty':'yAxis','states':['default','touched','pressed'],'valueNodeProperty':'transform','valueNodeName':'xr_standard_touchpad_yaxis_pressed_value','minNodeName':'xr_standard_touchpad_yaxis_pressed_min','maxNodeName':'xr_standard_touchpad_yaxis_pressed_max'},'xr_standard_touchpad_xaxis_touched':{'componentProperty':'xAxis','states':['default','touched','pressed'],'valueNodeProperty':'transform','valueNodeName':'xr_standard_touchpad_xaxis_touched_value','minNodeName':'xr_standard_touchpad_xaxis_touched_min','maxNodeName':'xr_standard_touchpad_xaxis_touched_max'},'xr_standard_touchpad_yaxis_touched':{'componentProperty':'yAxis','states':['default','touched','pressed'],'valueNodeProperty':'transform','valueNodeName':'xr_standard_touchpad_yaxis_touched_value','minNodeName':'xr_standard_touchpad_yaxis_touched_min','maxNodeName':'xr_standard_touchpad_yaxis_touched_max'},'xr_standard_touchpad_axes_touched':{'componentProperty':'state','states':['touched','pressed'],'valueNodeProperty':'visibility','valueNodeName':'xr_standard_touchpad_axes_touched_value'}},'touchPointNodeName':'xr_standard_touchpad_axes_touched_value'},'xr-standard-thumbstick':{'type':'thumbstick','gamepadIndices':{'button':0x3,'xAxis':0x2,'yAxis':0x3},'rootNodeName':'xr_standard_thumbstick','visualResponses':{'xr_standard_thumbstick_pressed':{'componentProperty':'button','states':['default','touched','pressed'],'valueNodeProperty':'transform','valueNodeName':'xr_standard_thumbstick_pressed_value','minNodeName':'xr_standard_thumbstick_pressed_min','maxNodeName':'xr_standard_thumbstick_pressed_max'},'xr_standard_thumbstick_xaxis_pressed':{'componentProperty':'xAxis','states':['default','touched','pressed'],'valueNodeProperty':'transform','valueNodeName':'xr_standard_thumbstick_xaxis_pressed_value','minNodeName':'xr_standard_thumbstick_xaxis_pressed_min','maxNodeName':'xr_standard_thumbstick_xaxis_pressed_max'},'xr_standard_thumbstick_yaxis_pressed':{'componentProperty':'yAxis','states':['default','touched','pressed'],'valueNodeProperty':'transform','valueNodeName':'xr_standard_thumbstick_yaxis_pressed_value','minNodeName':'xr_standard_thumbstick_yaxis_pressed_min','maxNodeName':'xr_standard_thumbstick_yaxis_pressed_max'}}}},'gamepadMapping':'xr-standard','rootNodeName':'microsoft-mixed-reality-left','assetPath':'left.glb'},'right':{'selectComponentId':'xr-standard-trigger','components':{'xr-standard-trigger':{'type':'trigger','gamepadIndices':{'button':0x0},'rootNodeName':'xr_standard_trigger','visualResponses':{'xr_standard_trigger_pressed':{'componentProperty':'button','states':['default','touched','pressed'],'valueNodeProperty':'transform','valueNodeName':'xr_standard_trigger_pressed_value','minNodeName':'xr_standard_trigger_pressed_min','maxNodeName':'xr_standard_trigger_pressed_max'}}},'xr-standard-squeeze':{'type':'squeeze','gamepadIndices':{'button':0x1},'rootNodeName':'xr_standard_squeeze','visualResponses':{'xr_standard_squeeze_pressed':{'componentProperty':'button','states':['default','touched','pressed'],'valueNodeProperty':'transform','valueNodeName':'xr_standard_squeeze_pressed_value','minNodeName':'xr_standard_squeeze_pressed_min','maxNodeName':'xr_standard_squeeze_pressed_max'}}},'xr-standard-touchpad':{'type':'touchpad','gamepadIndices':{'button':0x2,'xAxis':0x0,'yAxis':0x1},'rootNodeName':'xr_standard_touchpad','visualResponses':{'xr_standard_touchpad_pressed':{'componentProperty':'button','states':['default','touched','pressed'],'valueNodeProperty':'transform','valueNodeName':'xr_standard_touchpad_pressed_value','minNodeName':'xr_standard_touchpad_pressed_min','maxNodeName':'xr_standard_touchpad_pressed_max'},'xr_standard_touchpad_xaxis_pressed':{'componentProperty':'xAxis','states':['default','touched','pressed'],'valueNodeProperty':'transform','valueNodeName':'xr_standard_touchpad_xaxis_pressed_value','minNodeName':'xr_standard_touchpad_xaxis_pressed_min','maxNodeName':'xr_standard_touchpad_xaxis_pressed_max'},'xr_standard_touchpad_yaxis_pressed':{'componentProperty':'yAxis','states':['default','touched','pressed'],'valueNodeProperty':'transform','valueNodeName':'xr_standard_touchpad_yaxis_pressed_value','minNodeName':'xr_standard_touchpad_yaxis_pressed_min','maxNodeName':'xr_standard_touchpad_yaxis_pressed_max'},'xr_standard_touchpad_xaxis_touched':{'componentProperty':'xAxis','states':['default','touched','pressed'],'valueNodeProperty':'transform','valueNodeName':'xr_standard_touchpad_xaxis_touched_value','minNodeName':'xr_standard_touchpad_xaxis_touched_min','maxNodeName':'xr_standard_touchpad_xaxis_touched_max'},'xr_standard_touchpad_yaxis_touched':{'componentProperty':'yAxis','states':['default','touched','pressed'],'valueNodeProperty':'transform','valueNodeName':'xr_standard_touchpad_yaxis_touched_value','minNodeName':'xr_standard_touchpad_yaxis_touched_min','maxNodeName':'xr_standard_touchpad_yaxis_touched_max'},'xr_standard_touchpad_axes_touched':{'componentProperty':'state','states':['touched','pressed'],'valueNodeProperty':'visibility','valueNodeName':'xr_standard_touchpad_axes_touched_value'}},'touchPointNodeName':'xr_standard_touchpad_axes_touched_value'},'xr-standard-thumbstick':{'type':'thumbstick','gamepadIndices':{'button':0x3,'xAxis':0x2,'yAxis':0x3},'rootNodeName':'xr_standard_thumbstick','visualResponses':{'xr_standard_thumbstick_pressed':{'componentProperty':'button','states':['default','touched','pressed'],'valueNodeProperty':'transform','valueNodeName':'xr_standard_thumbstick_pressed_value','minNodeName':'xr_standard_thumbstick_pressed_min','maxNodeName':'xr_standard_thumbstick_pressed_max'},'xr_standard_thumbstick_xaxis_pressed':{'componentProperty':'xAxis','states':['default','touched','pressed'],'valueNodeProperty':'transform','valueNodeName':'xr_standard_thumbstick_xaxis_pressed_value','minNodeName':'xr_standard_thumbstick_xaxis_pressed_min','maxNodeName':'xr_standard_thumbstick_xaxis_pressed_max'},'xr_standard_thumbstick_yaxis_pressed':{'componentProperty':'yAxis','states':['default','touched','pressed'],'valueNodeProperty':'transform','valueNodeName':'xr_standard_thumbstick_yaxis_pressed_value','minNodeName':'xr_standard_thumbstick_yaxis_pressed_min','maxNodeName':'xr_standard_thumbstick_yaxis_pressed_max'}}}},'gamepadMapping':'xr-standard','rootNodeName':'microsoft-mixed-reality-right','assetPath':'right.glb'}},_0x44d608=function(_0x5b23f8){function _0x4a2614(_0x542291,_0x38d4e7,_0x582a7a,_0x39eab8,_0x505a8c){void 0x0===_0x39eab8&&(_0x39eab8=!0x1),void 0x0===_0x505a8c&&(_0x505a8c=!0x1);var _0x2d257d=_0x5b23f8['call'](this,_0x542291,_0x1dbbcc[_0x582a7a],_0x38d4e7,_0x582a7a)||this;return _0x2d257d['_forceLegacyControllers']=_0x505a8c,_0x2d257d['profileId']='oculus-touch',_0x2d257d;}return Object(_0x18e13d['d'])(_0x4a2614,_0x5b23f8),_0x4a2614['prototype']['_getFilenameAndPath']=function(){return{'filename':'left'===this['handedness']?_0x4a2614['MODEL_LEFT_FILENAME']:_0x4a2614['MODEL_RIGHT_FILENAME'],'path':this['_isQuest']()?_0x4a2614['QUEST_MODEL_BASE_URL']:_0x4a2614['MODEL_BASE_URL']};},_0x4a2614['prototype']['_getModelLoadingConstraints']=function(){return!0x0;},_0x4a2614['prototype']['_processLoadedModel']=function(_0x4aa2f4){var _0x12f9fd=this,_0x16ce99=this['_isQuest'](),_0x5eb0aa='right'===this['handedness']?-0x1:0x1;this['getComponentIds']()['forEach'](function(_0x41fe68){var _0x24a03d=_0x41fe68&&_0x12f9fd['getComponent'](_0x41fe68);_0x24a03d&&_0x24a03d['onButtonStateChangedObservable']['add'](function(_0x57101b){if(_0x12f9fd['rootMesh']&&!_0x12f9fd['disableAnimation'])switch(_0x41fe68){case'xr-standard-trigger':return void(_0x16ce99||(_0x12f9fd['_modelRootNode']['getChildren']()[0x3]['rotation']['x']=0.2*-_0x57101b['value'],_0x12f9fd['_modelRootNode']['getChildren']()[0x3]['position']['y']=0.005*-_0x57101b['value'],_0x12f9fd['_modelRootNode']['getChildren']()[0x3]['position']['z']=0.005*-_0x57101b['value']));case'xr-standard-squeeze':return void(_0x16ce99||(_0x12f9fd['_modelRootNode']['getChildren']()[0x4]['position']['x']=_0x5eb0aa*_0x57101b['value']*0.0035));case'xr-standard-thumbstick':return;case'a-button':case'x-button':return void(_0x16ce99||(_0x57101b['pressed']?_0x12f9fd['_modelRootNode']['getChildren']()[0x1]['position']['y']=-0.001:_0x12f9fd['_modelRootNode']['getChildren']()[0x1]['position']['y']=0x0));case'b-button':case'y-button':return void(_0x16ce99||(_0x57101b['pressed']?_0x12f9fd['_modelRootNode']['getChildren']()[0x2]['position']['y']=-0.001:_0x12f9fd['_modelRootNode']['getChildren']()[0x2]['position']['y']=0x0));}},void 0x0,!0x0);});},_0x4a2614['prototype']['_setRootMesh']=function(_0x299aab){this['rootMesh']=new _0x3cf5e5['a'](this['profileId']+'\x20'+this['handedness'],this['scene']),this['scene']['useRightHandedSystem']||(this['rootMesh']['rotationQuaternion']=_0x74d525['b']['FromEulerAngles'](0x0,Math['PI'],0x0)),_0x299aab['forEach'](function(_0x5973bb){_0x5973bb['isPickable']=!0x1;}),this['_isQuest']()?this['_modelRootNode']=_0x299aab[0x0]:(this['_modelRootNode']=_0x299aab[0x1],this['rootMesh']['position']['y']=0.034,this['rootMesh']['position']['z']=0.052),this['_modelRootNode']['parent']=this['rootMesh'];},_0x4a2614['prototype']['_updateModel']=function(){},_0x4a2614['prototype']['_isQuest']=function(){return!!navigator['userAgent']['match'](/Quest/gi)&&!this['_forceLegacyControllers'];},_0x4a2614['MODEL_BASE_URL']='https://controllers.babylonjs.com/oculus/',_0x4a2614['MODEL_LEFT_FILENAME']='left.babylon',_0x4a2614['MODEL_RIGHT_FILENAME']='right.babylon',_0x4a2614['QUEST_MODEL_BASE_URL']='https://controllers.babylonjs.com/oculusQuest/',_0x4a2614;}(_0x48fb5b);_0x13267d['RegisterController']('oculus-touch',function(_0x2a7806,_0x2f481a){return new _0x44d608(_0x2f481a,_0x2a7806['gamepad'],_0x2a7806['handedness']);}),_0x13267d['RegisterController']('oculus-touch-legacy',function(_0x42149f,_0x8cb8d7){return new _0x44d608(_0x8cb8d7,_0x42149f['gamepad'],_0x42149f['handedness'],!0x0);});var _0x1dbbcc={'left':{'selectComponentId':'xr-standard-trigger','components':{'xr-standard-trigger':{'type':'trigger','gamepadIndices':{'button':0x0},'rootNodeName':'xr_standard_trigger','visualResponses':{}},'xr-standard-squeeze':{'type':'squeeze','gamepadIndices':{'button':0x1},'rootNodeName':'xr_standard_squeeze','visualResponses':{}},'xr-standard-thumbstick':{'type':'thumbstick','gamepadIndices':{'button':0x3,'xAxis':0x2,'yAxis':0x3},'rootNodeName':'xr_standard_thumbstick','visualResponses':{}},'x-button':{'type':'button','gamepadIndices':{'button':0x4},'rootNodeName':'x_button','visualResponses':{}},'y-button':{'type':'button','gamepadIndices':{'button':0x5},'rootNodeName':'y_button','visualResponses':{}},'thumbrest':{'type':'button','gamepadIndices':{'button':0x6},'rootNodeName':'thumbrest','visualResponses':{}}},'gamepadMapping':'xr-standard','rootNodeName':'oculus-touch-v2-left','assetPath':'left.glb'},'right':{'selectComponentId':'xr-standard-trigger','components':{'xr-standard-trigger':{'type':'trigger','gamepadIndices':{'button':0x0},'rootNodeName':'xr_standard_trigger','visualResponses':{}},'xr-standard-squeeze':{'type':'squeeze','gamepadIndices':{'button':0x1},'rootNodeName':'xr_standard_squeeze','visualResponses':{}},'xr-standard-thumbstick':{'type':'thumbstick','gamepadIndices':{'button':0x3,'xAxis':0x2,'yAxis':0x3},'rootNodeName':'xr_standard_thumbstick','visualResponses':{}},'a-button':{'type':'button','gamepadIndices':{'button':0x4},'rootNodeName':'a_button','visualResponses':{}},'b-button':{'type':'button','gamepadIndices':{'button':0x5},'rootNodeName':'b_button','visualResponses':{}},'thumbrest':{'type':'button','gamepadIndices':{'button':0x6},'rootNodeName':'thumbrest','visualResponses':{}}},'gamepadMapping':'xr-standard','rootNodeName':'oculus-touch-v2-right','assetPath':'right.glb'}},_0x159301=function(_0x25f781){function _0x15d6ed(_0xe44614,_0x1a0654,_0x58ffda){var _0x2a22c7=_0x25f781['call'](this,_0xe44614,_0x30602b[_0x58ffda],_0x1a0654,_0x58ffda)||this;return _0x2a22c7['profileId']='htc-vive',_0x2a22c7;}return Object(_0x18e13d['d'])(_0x15d6ed,_0x25f781),_0x15d6ed['prototype']['_getFilenameAndPath']=function(){return{'filename':_0x15d6ed['MODEL_FILENAME'],'path':_0x15d6ed['MODEL_BASE_URL']};},_0x15d6ed['prototype']['_getModelLoadingConstraints']=function(){return!0x0;},_0x15d6ed['prototype']['_processLoadedModel']=function(_0x2b6005){var _0x14e9ba=this;this['getComponentIds']()['forEach'](function(_0x1cd4c7){var _0x9c55d8=_0x1cd4c7&&_0x14e9ba['getComponent'](_0x1cd4c7);_0x9c55d8&&_0x9c55d8['onButtonStateChangedObservable']['add'](function(_0x11cb5f){if(_0x14e9ba['rootMesh']&&!_0x14e9ba['disableAnimation'])switch(_0x1cd4c7){case'xr-standard-trigger':return void(_0x14e9ba['_modelRootNode']['getChildren']()[0x6]['rotation']['x']=0.15*-_0x11cb5f['value']);case'xr-standard-touchpad':case'xr-standard-squeeze':return;}},void 0x0,!0x0);});},_0x15d6ed['prototype']['_setRootMesh']=function(_0x22638b){this['rootMesh']=new _0x3cf5e5['a'](this['profileId']+'\x20'+this['handedness'],this['scene']),_0x22638b['forEach'](function(_0x203868){_0x203868['isPickable']=!0x1;}),this['_modelRootNode']=_0x22638b[0x1],this['_modelRootNode']['parent']=this['rootMesh'],this['scene']['useRightHandedSystem']||(this['rootMesh']['rotationQuaternion']=_0x74d525['b']['FromEulerAngles'](0x0,Math['PI'],0x0));},_0x15d6ed['prototype']['_updateModel']=function(){},_0x15d6ed['MODEL_BASE_URL']='https://controllers.babylonjs.com/vive/',_0x15d6ed['MODEL_FILENAME']='wand.babylon',_0x15d6ed;}(_0x48fb5b);_0x13267d['RegisterController']('htc-vive',function(_0x41b48b,_0x5d48ca){return new _0x159301(_0x5d48ca,_0x41b48b['gamepad'],_0x41b48b['handedness']);});var _0x30602b={'left':{'selectComponentId':'xr-standard-trigger','components':{'xr-standard-trigger':{'type':'trigger','gamepadIndices':{'button':0x0},'rootNodeName':'xr_standard_trigger','visualResponses':{}},'xr-standard-squeeze':{'type':'squeeze','gamepadIndices':{'button':0x1},'rootNodeName':'xr_standard_squeeze','visualResponses':{}},'xr-standard-touchpad':{'type':'touchpad','gamepadIndices':{'button':0x2,'xAxis':0x0,'yAxis':0x1},'rootNodeName':'xr_standard_touchpad','visualResponses':{}},'menu':{'type':'button','gamepadIndices':{'button':0x4},'rootNodeName':'menu','visualResponses':{}}},'gamepadMapping':'xr-standard','rootNodeName':'htc_vive_none','assetPath':'none.glb'},'right':{'selectComponentId':'xr-standard-trigger','components':{'xr-standard-trigger':{'type':'trigger','gamepadIndices':{'button':0x0},'rootNodeName':'xr_standard_trigger','visualResponses':{}},'xr-standard-squeeze':{'type':'squeeze','gamepadIndices':{'button':0x1},'rootNodeName':'xr_standard_squeeze','visualResponses':{}},'xr-standard-touchpad':{'type':'touchpad','gamepadIndices':{'button':0x2,'xAxis':0x0,'yAxis':0x1},'rootNodeName':'xr_standard_touchpad','visualResponses':{}},'menu':{'type':'button','gamepadIndices':{'button':0x4},'rootNodeName':'menu','visualResponses':{}}},'gamepadMapping':'xr-standard','rootNodeName':'htc_vive_none','assetPath':'none.glb'},'none':{'selectComponentId':'xr-standard-trigger','components':{'xr-standard-trigger':{'type':'trigger','gamepadIndices':{'button':0x0},'rootNodeName':'xr_standard_trigger','visualResponses':{}},'xr-standard-squeeze':{'type':'squeeze','gamepadIndices':{'button':0x1},'rootNodeName':'xr_standard_squeeze','visualResponses':{}},'xr-standard-touchpad':{'type':'touchpad','gamepadIndices':{'button':0x2,'xAxis':0x0,'yAxis':0x1},'rootNodeName':'xr_standard_touchpad','visualResponses':{}},'menu':{'type':'button','gamepadIndices':{'button':0x4},'rootNodeName':'menu','visualResponses':{}}},'gamepadMapping':'xr-standard','rootNodeName':'htc-vive-none','assetPath':'none.glb'}};},function(_0x4512c8,_0x430e91,_0xe25540){'use strict';_0xe25540['d'](_0x430e91,'a',function(){return _0x722776;});var _0x21e1ad=_0xe25540(0x22),_0x570d71=(function(){function _0x251ae4(){this['children']=[];}return _0x251ae4['prototype']['isValid']=function(_0x49564b){return!0x0;},_0x251ae4['prototype']['process']=function(_0x93e235,_0x47101d){var _0x3598ca='';if(this['line']){var _0x45fb27=this['line'],_0x2d3f50=_0x47101d['processor'];if(_0x2d3f50){if(_0x2d3f50['lineProcessor']&&(_0x45fb27=_0x2d3f50['lineProcessor'](_0x45fb27,_0x47101d['isFragment'])),_0x2d3f50['attributeProcessor']&&_0x21e1ad['a']['StartsWith'](this['line'],'attribute'))_0x45fb27=_0x2d3f50['attributeProcessor'](this['line']);else{if(_0x2d3f50['varyingProcessor']&&_0x21e1ad['a']['StartsWith'](this['line'],'varying'))_0x45fb27=_0x2d3f50['varyingProcessor'](this['line'],_0x47101d['isFragment']);else(_0x2d3f50['uniformProcessor']||_0x2d3f50['uniformBufferProcessor'])&&_0x21e1ad['a']['StartsWith'](this['line'],'uniform')&&(/uniform (.+) (.+)/['test'](this['line'])?_0x2d3f50['uniformProcessor']&&(_0x45fb27=_0x2d3f50['uniformProcessor'](this['line'],_0x47101d['isFragment'])):_0x2d3f50['uniformBufferProcessor']&&(_0x45fb27=_0x2d3f50['uniformBufferProcessor'](this['line'],_0x47101d['isFragment']),_0x47101d['lookForClosingBracketForUniformBuffer']=!0x0));}_0x2d3f50['endOfUniformBufferProcessor']&&_0x47101d['lookForClosingBracketForUniformBuffer']&&-0x1!==this['line']['indexOf']('}')&&(_0x47101d['lookForClosingBracketForUniformBuffer']=!0x1,_0x45fb27=_0x2d3f50['endOfUniformBufferProcessor'](this['line'],_0x47101d['isFragment']));}_0x3598ca+=_0x45fb27+'\x0d\x0a';}return this['children']['forEach'](function(_0x1990bb){_0x3598ca+=_0x1990bb['process'](_0x93e235,_0x47101d);}),this['additionalDefineKey']&&(_0x93e235[this['additionalDefineKey']]=this['additionalDefineValue']||'true'),_0x3598ca;},_0x251ae4;}()),_0x583ea8=(function(){function _0x45d294(){}return Object['defineProperty'](_0x45d294['prototype'],'currentLine',{'get':function(){return this['_lines'][this['lineIndex']];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x45d294['prototype'],'canRead',{'get':function(){return this['lineIndex']0x1){for(_0x6b19e5();-0x1!==_0x15c336&&_0x2435e3['_OperatorPriority'][_0x3d78d4()]>=_0x2435e3['_OperatorPriority'][_0x565723];)_0x42d1ad['push'](_0x2ff18e());_0x36e2be(_0x565723),_0x28db63++;}else _0x1dbd27+=_0x3b3b96;}}_0x28db63++;}for(_0x6b19e5();-0x1!==_0x15c336;)'('===_0x3d78d4()?_0x2ff18e():_0x42d1ad['push'](_0x2ff18e());return _0x42d1ad;},_0x2435e3['_OperatorPriority']={')':0x0,'(':0x1,'||':0x2,'&&':0x3},_0x2435e3['_Stack']=['','','','','','','','','','','','','','','','','','','',''],_0x2435e3;}()),_0x688ccc=function(_0x30e8c2){function _0x44ea55(_0x34264c,_0x4fa20e){void 0x0===_0x4fa20e&&(_0x4fa20e=!0x1);var _0x26ca5a=_0x30e8c2['call'](this)||this;return _0x26ca5a['define']=_0x34264c,_0x26ca5a['not']=_0x4fa20e,_0x26ca5a;}return Object(_0x5f0fc8['d'])(_0x44ea55,_0x30e8c2),_0x44ea55['prototype']['isTrue']=function(_0x2e50e2){var _0x4849cd=void 0x0!==_0x2e50e2[this['define']];return this['not']&&(_0x4849cd=!_0x4849cd),_0x4849cd;},_0x44ea55;}(_0x5a669f),_0x1224a9=function(_0x27cbb1){function _0x24451a(){return null!==_0x27cbb1&&_0x27cbb1['apply'](this,arguments)||this;}return Object(_0x5f0fc8['d'])(_0x24451a,_0x27cbb1),_0x24451a['prototype']['isTrue']=function(_0x600e23){return this['leftOperand']['isTrue'](_0x600e23)||this['rightOperand']['isTrue'](_0x600e23);},_0x24451a;}(_0x5a669f),_0x547cde=function(_0x5da3f7){function _0x56b926(){return null!==_0x5da3f7&&_0x5da3f7['apply'](this,arguments)||this;}return Object(_0x5f0fc8['d'])(_0x56b926,_0x5da3f7),_0x56b926['prototype']['isTrue']=function(_0x10c0a7){return this['leftOperand']['isTrue'](_0x10c0a7)&&this['rightOperand']['isTrue'](_0x10c0a7);},_0x56b926;}(_0x5a669f),_0x28d577=function(_0x153149){function _0x111643(_0x1b5a6d,_0x1e4806,_0x33c842){var _0x500ff3=_0x153149['call'](this)||this;return _0x500ff3['define']=_0x1b5a6d,_0x500ff3['operand']=_0x1e4806,_0x500ff3['testValue']=_0x33c842,_0x500ff3;}return Object(_0x5f0fc8['d'])(_0x111643,_0x153149),_0x111643['prototype']['isTrue']=function(_0x4cd204){var _0x2cf68e=_0x4cd204[this['define']];void 0x0===_0x2cf68e&&(_0x2cf68e=this['define']);var _0x4c7ce2=!0x1,_0x195696=parseInt(_0x2cf68e),_0x4c30c1=parseInt(this['testValue']);switch(this['operand']){case'>':_0x4c7ce2=_0x195696>_0x4c30c1;break;case'<':_0x4c7ce2=_0x195696<_0x4c30c1;break;case'<=':_0x4c7ce2=_0x195696<=_0x4c30c1;break;case'>=':_0x4c7ce2=_0x195696>=_0x4c30c1;break;case'==':_0x4c7ce2=_0x195696===_0x4c30c1;}return _0x4c7ce2;},_0x111643;}(_0x5a669f),_0x2991b3=_0xe25540(0x15),_0x135e3f=/defined\s*?\((.+?)\)/g,_0x564a14=/defined\s*?\[(.+?)\]/g,_0x722776=(function(){function _0x4e2703(){}return _0x4e2703['Process']=function(_0x56d1a1,_0x265e1a,_0x125dcf,_0x255f96){var _0x19012c=this;this['_ProcessIncludes'](_0x56d1a1,_0x265e1a,function(_0x42ed38){var _0x2dea39=_0x19012c['_ProcessShaderConversion'](_0x42ed38,_0x265e1a,_0x255f96);_0x125dcf(_0x2dea39);});},_0x4e2703['_ProcessPrecision']=function(_0xa63b17,_0x22ba54){var _0x157c6f=_0x22ba54['shouldUseHighPrecisionShader'];return-0x1===_0xa63b17['indexOf']('precision\x20highp\x20float')?_0xa63b17=_0x157c6f?'precision\x20highp\x20float;\x0a'+_0xa63b17:'precision\x20mediump\x20float;\x0a'+_0xa63b17:_0x157c6f||(_0xa63b17=_0xa63b17['replace']('precision\x20highp\x20float','precision\x20mediump\x20float')),_0xa63b17;},_0x4e2703['_ExtractOperation']=function(_0x51d702){var _0xe397dd=/defined\((.+)\)/['exec'](_0x51d702);if(_0xe397dd&&_0xe397dd['length'])return new _0x688ccc(_0xe397dd[0x1]['trim'](),'!'===_0x51d702[0x0]);for(var _0x11241e='',_0x5913fe=0x0,_0x15648f=0x0,_0x113077=['==','>=','<=','<','>'];_0x15648f<_0x113077['length']&&(_0x11241e=_0x113077[_0x15648f],!((_0x5913fe=_0x51d702['indexOf'](_0x11241e))>-0x1));_0x15648f++);if(-0x1===_0x5913fe)return new _0x688ccc(_0x51d702);var _0x188ce=_0x51d702['substring'](0x0,_0x5913fe)['trim'](),_0x5dc11d=_0x51d702['substring'](_0x5913fe+_0x11241e['length'])['trim']();return new _0x28d577(_0x188ce,_0x11241e,_0x5dc11d);},_0x4e2703['_BuildSubExpression']=function(_0x54db0a){_0x54db0a=_0x54db0a['replace'](_0x135e3f,'defined[$1]');for(var _0x950bc9=[],_0x4f4d0d=0x0,_0x5f0869=_0x5a669f['infixToPostfix'](_0x54db0a);_0x4f4d0d<_0x5f0869['length'];_0x4f4d0d++){var _0x502db9=_0x5f0869[_0x4f4d0d];if('||'!==_0x502db9&&'&&'!==_0x502db9)_0x950bc9['push'](_0x502db9);else{if(_0x950bc9['length']>=0x2){var _0x3a8b2=_0x950bc9[_0x950bc9['length']-0x1],_0x5bc3eb=_0x950bc9[_0x950bc9['length']-0x2];_0x950bc9['length']-=0x2;var _0x2b6bd9='&&'==_0x502db9?new _0x547cde():new _0x1224a9();'string'==typeof _0x3a8b2&&(_0x3a8b2=_0x3a8b2['replace'](_0x564a14,'defined($1)')),'string'==typeof _0x5bc3eb&&(_0x5bc3eb=_0x5bc3eb['replace'](_0x564a14,'defined($1)')),_0x2b6bd9['leftOperand']='string'==typeof _0x5bc3eb?this['_ExtractOperation'](_0x5bc3eb):_0x5bc3eb,_0x2b6bd9['rightOperand']='string'==typeof _0x3a8b2?this['_ExtractOperation'](_0x3a8b2):_0x3a8b2,_0x950bc9['push'](_0x2b6bd9);}}}var _0x1c041d=_0x950bc9[_0x950bc9['length']-0x1];return'string'==typeof _0x1c041d&&(_0x1c041d=_0x1c041d['replace'](_0x564a14,'defined($1)')),'string'==typeof _0x1c041d?this['_ExtractOperation'](_0x1c041d):_0x1c041d;},_0x4e2703['_BuildExpression']=function(_0x49b933,_0x196373){var _0x447fec=new _0x304ea5(),_0x263a23=_0x49b933['substring'](0x0,_0x196373),_0x19c621=_0x49b933['substring'](_0x196373);return _0x19c621=_0x19c621['substring'](0x0,(_0x19c621['indexOf']('//')+0x1||_0x19c621['length']+0x1)-0x1)['trim'](),_0x447fec['testExpression']='#ifdef'===_0x263a23?new _0x688ccc(_0x19c621):'#ifndef'===_0x263a23?new _0x688ccc(_0x19c621,!0x0):this['_BuildSubExpression'](_0x19c621),_0x447fec;},_0x4e2703['_MoveCursorWithinIf']=function(_0x1fa178,_0x2676be,_0xb8e3fc){for(var _0x301a2f=_0x1fa178['currentLine'];this['_MoveCursor'](_0x1fa178,_0xb8e3fc);){var _0x5a82e6=(_0x301a2f=_0x1fa178['currentLine'])['substring'](0x0,0x5)['toLowerCase']();if('#else'===_0x5a82e6){var _0x225ea2=new _0x570d71();return _0x2676be['children']['push'](_0x225ea2),void this['_MoveCursor'](_0x1fa178,_0x225ea2);}if('#elif'===_0x5a82e6){var _0x17e08d=this['_BuildExpression'](_0x301a2f,0x5);_0x2676be['children']['push'](_0x17e08d),_0xb8e3fc=_0x17e08d;}}},_0x4e2703['_MoveCursor']=function(_0x255ee1,_0x576ddb){for(;_0x255ee1['canRead'];){_0x255ee1['lineIndex']++;var _0x51a179=_0x255ee1['currentLine'],_0x35fdde=/(#ifdef)|(#else)|(#elif)|(#endif)|(#ifndef)|(#if)/['exec'](_0x51a179);if(_0x35fdde&&_0x35fdde['length'])switch(_0x35fdde[0x0]){case'#ifdef':var _0x4c98d6=new _0x494045();_0x576ddb['children']['push'](_0x4c98d6);var _0x4c1433=this['_BuildExpression'](_0x51a179,0x6);_0x4c98d6['children']['push'](_0x4c1433),this['_MoveCursorWithinIf'](_0x255ee1,_0x4c98d6,_0x4c1433);break;case'#else':case'#elif':return!0x0;case'#endif':return!0x1;case'#ifndef':_0x4c98d6=new _0x494045(),_0x576ddb['children']['push'](_0x4c98d6),_0x4c1433=this['_BuildExpression'](_0x51a179,0x7),(_0x4c98d6['children']['push'](_0x4c1433),this['_MoveCursorWithinIf'](_0x255ee1,_0x4c98d6,_0x4c1433));break;case'#if':_0x4c98d6=new _0x494045(),_0x4c1433=this['_BuildExpression'](_0x51a179,0x3),(_0x576ddb['children']['push'](_0x4c98d6),_0x4c98d6['children']['push'](_0x4c1433),this['_MoveCursorWithinIf'](_0x255ee1,_0x4c98d6,_0x4c1433));}else{var _0x3da718=new _0x570d71();if(_0x3da718['line']=_0x51a179,_0x576ddb['children']['push'](_0x3da718),'#'===_0x51a179[0x0]&&'d'===_0x51a179[0x1]){var _0x1f90f4=_0x51a179['replace'](';','')['split']('\x20');_0x3da718['additionalDefineKey']=_0x1f90f4[0x1],0x3===_0x1f90f4['length']&&(_0x3da718['additionalDefineValue']=_0x1f90f4[0x2]);}}}return!0x1;},_0x4e2703['_EvaluatePreProcessors']=function(_0x3c68db,_0x346b26,_0x476262){var _0x4f4379=new _0x570d71(),_0x38f33c=new _0x583ea8();return _0x38f33c['lineIndex']=-0x1,_0x38f33c['lines']=_0x3c68db['split']('\x0a'),this['_MoveCursor'](_0x38f33c,_0x4f4379),_0x4f4379['process'](_0x346b26,_0x476262);},_0x4e2703['_PreparePreProcessors']=function(_0x1c2843){for(var _0x1dc008={},_0x14089f=0x0,_0x5ddad0=_0x1c2843['defines'];_0x14089f<_0x5ddad0['length'];_0x14089f++){var _0x422a89=_0x5ddad0[_0x14089f]['replace']('#define','')['replace'](';','')['trim']()['split']('\x20');_0x1dc008[_0x422a89[0x0]]=_0x422a89['length']>0x1?_0x422a89[0x1]:'';}return _0x1dc008['GL_ES']='true',_0x1dc008['__VERSION__']=_0x1c2843['version'],_0x1dc008[_0x1c2843['platformName']]='true',_0x1dc008;},_0x4e2703['_ProcessShaderConversion']=function(_0x4b8e5b,_0x2034fd,_0x37257b){var _0xab745c=this['_ProcessPrecision'](_0x4b8e5b,_0x2034fd);if(!_0x2034fd['processor'])return _0xab745c;if(-0x1!==_0xab745c['indexOf']('#version\x203'))return _0xab745c['replace']('#version\x20300\x20es','');var _0x507072=_0x2034fd['defines'],_0x49170d=this['_PreparePreProcessors'](_0x2034fd);return _0x2034fd['processor']['preProcessor']&&(_0xab745c=_0x2034fd['processor']['preProcessor'](_0xab745c,_0x507072,_0x2034fd['isFragment'])),_0xab745c=this['_EvaluatePreProcessors'](_0xab745c,_0x49170d,_0x2034fd),_0x2034fd['processor']['postProcessor']&&(_0xab745c=_0x2034fd['processor']['postProcessor'](_0xab745c,_0x507072,_0x2034fd['isFragment'],_0x37257b)),_0xab745c;},_0x4e2703['_ProcessIncludes']=function(_0x30f21a,_0x252059,_0x512795){for(var _0x111c7b=this,_0x194fc4=/#include<(.+)>(\((.*)\))*(\[(.*)\])*/g,_0x1fafe1=_0x194fc4['exec'](_0x30f21a),_0x2ec323=new String(_0x30f21a),_0x119011=!0x1;null!=_0x1fafe1;){var _0x148ac2=_0x1fafe1[0x1];if(-0x1!==_0x148ac2['indexOf']('__decl__')&&(_0x148ac2=_0x148ac2['replace'](/__decl__/,''),_0x252059['supportsUniformBuffers']&&(_0x148ac2=(_0x148ac2=_0x148ac2['replace'](/Vertex/,'Ubo'))['replace'](/Fragment/,'Ubo')),_0x148ac2+='Declaration'),!_0x252059['includesShadersStore'][_0x148ac2]){var _0x8301a5=_0x252059['shadersRepository']+'ShadersInclude/'+_0x148ac2+'.fx';return void _0x4e2703['_FileToolsLoadFile'](_0x8301a5,function(_0x12e4a1){_0x252059['includesShadersStore'][_0x148ac2]=_0x12e4a1,_0x111c7b['_ProcessIncludes'](_0x2ec323,_0x252059,_0x512795);});}var _0x250640=_0x252059['includesShadersStore'][_0x148ac2];if(_0x1fafe1[0x2])for(var _0x5055bf=_0x1fafe1[0x3]['split'](','),_0x4b2dec=0x0;_0x4b2dec<_0x5055bf['length'];_0x4b2dec+=0x2){var _0x394b8d=new RegExp(_0x5055bf[_0x4b2dec],'g'),_0x1056dc=_0x5055bf[_0x4b2dec+0x1];_0x250640=_0x250640['replace'](_0x394b8d,_0x1056dc);}if(_0x1fafe1[0x4]){var _0x19bec6=_0x1fafe1[0x5];if(-0x1!==_0x19bec6['indexOf']('..')){var _0x1e50f7=_0x19bec6['split']('..'),_0x41965a=parseInt(_0x1e50f7[0x0]),_0x3bf995=parseInt(_0x1e50f7[0x1]),_0x43f57d=_0x250640['slice'](0x0);_0x250640='',isNaN(_0x3bf995)&&(_0x3bf995=_0x252059['indexParameters'][_0x1e50f7[0x1]]);for(var _0x5ad327=_0x41965a;_0x5ad327<_0x3bf995;_0x5ad327++)_0x252059['supportsUniformBuffers']||(_0x43f57d=_0x43f57d['replace'](/light\{X\}.(\w*)/g,function(_0x233fa5,_0x22d97e){return _0x22d97e+'{X}';})),_0x250640+=_0x43f57d['replace'](/\{X\}/g,_0x5ad327['toString']())+'\x0a';}else _0x252059['supportsUniformBuffers']||(_0x250640=_0x250640['replace'](/light\{X\}.(\w*)/g,function(_0x45d75e,_0x250d8f){return _0x250d8f+'{X}';})),_0x250640=_0x250640['replace'](/\{X\}/g,_0x19bec6);}_0x2ec323=_0x2ec323['replace'](_0x1fafe1[0x0],_0x250640),_0x119011=_0x119011||_0x250640['indexOf']('#include<')>=0x0,_0x1fafe1=_0x194fc4['exec'](_0x30f21a);}_0x119011?this['_ProcessIncludes'](_0x2ec323['toString'](),_0x252059,_0x512795):_0x512795(_0x2ec323);},_0x4e2703['_FileToolsLoadFile']=function(_0x5bac21,_0x5ba041,_0x5d06d3,_0x525d49,_0x5e2af2,_0x115b48){throw _0x2991b3['a']['WarnImport']('FileTools');},_0x4e2703;}());},function(_0x88738b,_0x22a204,_0x572174){'use strict';_0x572174(0x1a)['a']['prototype']['_readTexturePixels']=function(_0x78d561,_0x59496e,_0x135827,_0x21eea8,_0x1a6e5a,_0xe37510){void 0x0===_0x21eea8&&(_0x21eea8=-0x1),void 0x0===_0x1a6e5a&&(_0x1a6e5a=0x0),void 0x0===_0xe37510&&(_0xe37510=null);var _0x2a2403=this['_gl'];if(!_0x2a2403)throw new Error('Engine\x20does\x20not\x20have\x20gl\x20rendering\x20context.');if(!this['_dummyFramebuffer']){var _0x25f1b9=_0x2a2403['createFramebuffer']();if(!_0x25f1b9)throw new Error('Unable\x20to\x20create\x20dummy\x20framebuffer');this['_dummyFramebuffer']=_0x25f1b9;}_0x2a2403['bindFramebuffer'](_0x2a2403['FRAMEBUFFER'],this['_dummyFramebuffer']),_0x21eea8>-0x1?_0x2a2403['framebufferTexture2D'](_0x2a2403['FRAMEBUFFER'],_0x2a2403['COLOR_ATTACHMENT0'],_0x2a2403['TEXTURE_CUBE_MAP_POSITIVE_X']+_0x21eea8,_0x78d561['_webGLTexture'],_0x1a6e5a):_0x2a2403['framebufferTexture2D'](_0x2a2403['FRAMEBUFFER'],_0x2a2403['COLOR_ATTACHMENT0'],_0x2a2403['TEXTURE_2D'],_0x78d561['_webGLTexture'],_0x1a6e5a);var _0x21aa74=void 0x0!==_0x78d561['type']?this['_getWebGLTextureType'](_0x78d561['type']):_0x2a2403['UNSIGNED_BYTE'];switch(_0x21aa74){case _0x2a2403['UNSIGNED_BYTE']:_0xe37510||(_0xe37510=new Uint8Array(0x4*_0x59496e*_0x135827)),_0x21aa74=_0x2a2403['UNSIGNED_BYTE'];break;default:_0xe37510||(_0xe37510=new Float32Array(0x4*_0x59496e*_0x135827)),_0x21aa74=_0x2a2403['FLOAT'];}return _0x2a2403['readPixels'](0x0,0x0,_0x59496e,_0x135827,_0x2a2403['RGBA'],_0x21aa74,_0xe37510),_0x2a2403['bindFramebuffer'](_0x2a2403['FRAMEBUFFER'],this['_currentFramebuffer']),_0xe37510;};},function(_0x2838a2,_0x46e6d2,_0x4c1343){'use strict';var _0x34a05e='shadowsFragmentFunctions',_0x360132='#ifdef\x20SHADOWS\x0a#ifndef\x20SHADOWFLOAT\x0a\x0afloat\x20unpack(vec4\x20color)\x0a{\x0aconst\x20vec4\x20bit_shift=vec4(1.0/(255.0*255.0*255.0),1.0/(255.0*255.0),1.0/255.0,1.0);\x0areturn\x20dot(color,bit_shift);\x0a}\x0a#endif\x0afloat\x20computeFallOff(float\x20value,vec2\x20clipSpace,float\x20frustumEdgeFalloff)\x0a{\x0afloat\x20mask=smoothstep(1.0-frustumEdgeFalloff,1.00000012,clamp(dot(clipSpace,clipSpace),0.,1.));\x0areturn\x20mix(value,1.0,mask);\x0a}\x0a#define\x20inline\x0afloat\x20computeShadowCube(vec3\x20lightPosition,samplerCube\x20shadowSampler,float\x20darkness,vec2\x20depthValues)\x0a{\x0avec3\x20directionToLight=vPositionW-lightPosition;\x0afloat\x20depth=length(directionToLight);\x0adepth=(depth+depthValues.x)/(depthValues.y);\x0adepth=clamp(depth,0.,1.0);\x0adirectionToLight=normalize(directionToLight);\x0adirectionToLight.y=-directionToLight.y;\x0a#ifndef\x20SHADOWFLOAT\x0afloat\x20shadow=unpack(textureCube(shadowSampler,directionToLight));\x0a#else\x0afloat\x20shadow=textureCube(shadowSampler,directionToLight).x;\x0a#endif\x0areturn\x20depth>shadow\x20?\x20darkness\x20:\x201.0;\x0a}\x0a#define\x20inline\x0afloat\x20computeShadowWithPoissonSamplingCube(vec3\x20lightPosition,samplerCube\x20shadowSampler,float\x20mapSize,float\x20darkness,vec2\x20depthValues)\x0a{\x0avec3\x20directionToLight=vPositionW-lightPosition;\x0afloat\x20depth=length(directionToLight);\x0adepth=(depth+depthValues.x)/(depthValues.y);\x0adepth=clamp(depth,0.,1.0);\x0adirectionToLight=normalize(directionToLight);\x0adirectionToLight.y=-directionToLight.y;\x0afloat\x20visibility=1.;\x0avec3\x20poissonDisk[4];\x0apoissonDisk[0]=vec3(-1.0,1.0,-1.0);\x0apoissonDisk[1]=vec3(1.0,-1.0,-1.0);\x0apoissonDisk[2]=vec3(-1.0,-1.0,-1.0);\x0apoissonDisk[3]=vec3(1.0,-1.0,1.0);\x0a\x0a#ifndef\x20SHADOWFLOAT\x0aif\x20(unpack(textureCube(shadowSampler,directionToLight+poissonDisk[0]*mapSize))shadow\x20?\x20computeFallOff(darkness,clipSpace.xy,frustumEdgeFalloff)\x20:\x201.;\x0a}\x0a#endif\x0a#define\x20inline\x0afloat\x20computeShadow(vec4\x20vPositionFromLight,float\x20depthMetric,sampler2D\x20shadowSampler,float\x20darkness,float\x20frustumEdgeFalloff)\x0a{\x0avec3\x20clipSpace=vPositionFromLight.xyz/vPositionFromLight.w;\x0avec2\x20uv=0.5*clipSpace.xy+vec2(0.5);\x0aif\x20(uv.x<0.\x20||\x20uv.x>1.0\x20||\x20uv.y<0.\x20||\x20uv.y>1.0)\x0a{\x0areturn\x201.0;\x0a}\x0aelse\x0a{\x0afloat\x20shadowPixelDepth=clamp(depthMetric,0.,1.0);\x0a#ifndef\x20SHADOWFLOAT\x0afloat\x20shadow=unpack(texture2D(shadowSampler,uv));\x0a#else\x0afloat\x20shadow=texture2D(shadowSampler,uv).x;\x0a#endif\x0areturn\x20shadowPixelDepth>shadow\x20?\x20computeFallOff(darkness,clipSpace.xy,frustumEdgeFalloff)\x20:\x201.;\x0a}\x0a}\x0a#define\x20inline\x0afloat\x20computeShadowWithPoissonSampling(vec4\x20vPositionFromLight,float\x20depthMetric,sampler2D\x20shadowSampler,float\x20mapSize,float\x20darkness,float\x20frustumEdgeFalloff)\x0a{\x0avec3\x20clipSpace=vPositionFromLight.xyz/vPositionFromLight.w;\x0avec2\x20uv=0.5*clipSpace.xy+vec2(0.5);\x0aif\x20(uv.x<0.\x20||\x20uv.x>1.0\x20||\x20uv.y<0.\x20||\x20uv.y>1.0)\x0a{\x0areturn\x201.0;\x0a}\x0aelse\x0a{\x0afloat\x20shadowPixelDepth=clamp(depthMetric,0.,1.0);\x0afloat\x20visibility=1.;\x0avec2\x20poissonDisk[4];\x0apoissonDisk[0]=vec2(-0.94201624,-0.39906216);\x0apoissonDisk[1]=vec2(0.94558609,-0.76890725);\x0apoissonDisk[2]=vec2(-0.094184101,-0.92938870);\x0apoissonDisk[3]=vec2(0.34495938,0.29387760);\x0a\x0a#ifndef\x20SHADOWFLOAT\x0aif\x20(unpack(texture2D(shadowSampler,uv+poissonDisk[0]*mapSize))1.0\x20||\x20uv.y<0.\x20||\x20uv.y>1.0)\x0a{\x0areturn\x201.0;\x0a}\x0aelse\x0a{\x0afloat\x20shadowPixelDepth=clamp(depthMetric,0.,1.0);\x0a#ifndef\x20SHADOWFLOAT\x0afloat\x20shadowMapSample=unpack(texture2D(shadowSampler,uv));\x0a#else\x0afloat\x20shadowMapSample=texture2D(shadowSampler,uv).x;\x0a#endif\x0afloat\x20esm=1.0-clamp(exp(min(87.,depthScale*shadowPixelDepth))*shadowMapSample,0.,1.-darkness);\x0areturn\x20computeFallOff(esm,clipSpace.xy,frustumEdgeFalloff);\x0a}\x0a}\x0a#define\x20inline\x0afloat\x20computeShadowWithCloseESM(vec4\x20vPositionFromLight,float\x20depthMetric,sampler2D\x20shadowSampler,float\x20darkness,float\x20depthScale,float\x20frustumEdgeFalloff)\x0a{\x0avec3\x20clipSpace=vPositionFromLight.xyz/vPositionFromLight.w;\x0avec2\x20uv=0.5*clipSpace.xy+vec2(0.5);\x0aif\x20(uv.x<0.\x20||\x20uv.x>1.0\x20||\x20uv.y<0.\x20||\x20uv.y>1.0)\x0a{\x0areturn\x201.0;\x0a}\x0aelse\x0a{\x0afloat\x20shadowPixelDepth=clamp(depthMetric,0.,1.0);\x0a#ifndef\x20SHADOWFLOAT\x0afloat\x20shadowMapSample=unpack(texture2D(shadowSampler,uv));\x0a#else\x0afloat\x20shadowMapSample=texture2D(shadowSampler,uv).x;\x0a#endif\x0afloat\x20esm=clamp(exp(min(87.,-depthScale*(shadowPixelDepth-shadowMapSample))),darkness,1.);\x0areturn\x20computeFallOff(esm,clipSpace.xy,frustumEdgeFalloff);\x0a}\x0a}\x0a#ifdef\x20WEBGL2\x0a#define\x20GREATEST_LESS_THAN_ONE\x200.99999994\x0a\x0a#define\x20inline\x0afloat\x20computeShadowWithCSMPCF1(float\x20layer,vec4\x20vPositionFromLight,float\x20depthMetric,highp\x20sampler2DArrayShadow\x20shadowSampler,float\x20darkness,float\x20frustumEdgeFalloff)\x0a{\x0avec3\x20clipSpace=vPositionFromLight.xyz/vPositionFromLight.w;\x0avec3\x20uvDepth=vec3(0.5*clipSpace.xyz+vec3(0.5));\x0auvDepth.z=clamp(uvDepth.z,0.,GREATEST_LESS_THAN_ONE);\x0avec4\x20uvDepthLayer=vec4(uvDepth.x,uvDepth.y,layer,uvDepth.z);\x0afloat\x20shadow=texture(shadowSampler,uvDepthLayer);\x0ashadow=mix(darkness,1.,shadow);\x0areturn\x20computeFallOff(shadow,clipSpace.xy,frustumEdgeFalloff);\x0a}\x0a\x0a\x0a\x0a#define\x20inline\x0afloat\x20computeShadowWithCSMPCF3(float\x20layer,vec4\x20vPositionFromLight,float\x20depthMetric,highp\x20sampler2DArrayShadow\x20shadowSampler,vec2\x20shadowMapSizeAndInverse,float\x20darkness,float\x20frustumEdgeFalloff)\x0a{\x0avec3\x20clipSpace=vPositionFromLight.xyz/vPositionFromLight.w;\x0avec3\x20uvDepth=vec3(0.5*clipSpace.xyz+vec3(0.5));\x0auvDepth.z=clamp(uvDepth.z,0.,GREATEST_LESS_THAN_ONE);\x0avec2\x20uv=uvDepth.xy*shadowMapSizeAndInverse.x;\x0auv+=0.5;\x0avec2\x20st=fract(uv);\x0avec2\x20base_uv=floor(uv)-0.5;\x0abase_uv*=shadowMapSizeAndInverse.y;\x0a\x0a\x0a\x0a\x0avec2\x20uvw0=3.-2.*st;\x0avec2\x20uvw1=1.+2.*st;\x0avec2\x20u=vec2((2.-st.x)/uvw0.x-1.,st.x/uvw1.x+1.)*shadowMapSizeAndInverse.y;\x0avec2\x20v=vec2((2.-st.y)/uvw0.y-1.,st.y/uvw1.y+1.)*shadowMapSizeAndInverse.y;\x0afloat\x20shadow=0.;\x0ashadow+=uvw0.x*uvw0.y*texture2D(shadowSampler,vec4(base_uv.xy+vec2(u[0],v[0]),layer,uvDepth.z));\x0ashadow+=uvw1.x*uvw0.y*texture2D(shadowSampler,vec4(base_uv.xy+vec2(u[1],v[0]),layer,uvDepth.z));\x0ashadow+=uvw0.x*uvw1.y*texture2D(shadowSampler,vec4(base_uv.xy+vec2(u[0],v[1]),layer,uvDepth.z));\x0ashadow+=uvw1.x*uvw1.y*texture2D(shadowSampler,vec4(base_uv.xy+vec2(u[1],v[1]),layer,uvDepth.z));\x0ashadow=shadow/16.;\x0ashadow=mix(darkness,1.,shadow);\x0areturn\x20computeFallOff(shadow,clipSpace.xy,frustumEdgeFalloff);\x0a}\x0a\x0a\x0a\x0a#define\x20inline\x0afloat\x20computeShadowWithCSMPCF5(float\x20layer,vec4\x20vPositionFromLight,float\x20depthMetric,highp\x20sampler2DArrayShadow\x20shadowSampler,vec2\x20shadowMapSizeAndInverse,float\x20darkness,float\x20frustumEdgeFalloff)\x0a{\x0avec3\x20clipSpace=vPositionFromLight.xyz/vPositionFromLight.w;\x0avec3\x20uvDepth=vec3(0.5*clipSpace.xyz+vec3(0.5));\x0auvDepth.z=clamp(uvDepth.z,0.,GREATEST_LESS_THAN_ONE);\x0avec2\x20uv=uvDepth.xy*shadowMapSizeAndInverse.x;\x0auv+=0.5;\x0avec2\x20st=fract(uv);\x0avec2\x20base_uv=floor(uv)-0.5;\x0abase_uv*=shadowMapSizeAndInverse.y;\x0a\x0a\x0avec2\x20uvw0=4.-3.*st;\x0avec2\x20uvw1=vec2(7.);\x0avec2\x20uvw2=1.+3.*st;\x0avec3\x20u=vec3((3.-2.*st.x)/uvw0.x-2.,(3.+st.x)/uvw1.x,st.x/uvw2.x+2.)*shadowMapSizeAndInverse.y;\x0avec3\x20v=vec3((3.-2.*st.y)/uvw0.y-2.,(3.+st.y)/uvw1.y,st.y/uvw2.y+2.)*shadowMapSizeAndInverse.y;\x0afloat\x20shadow=0.;\x0ashadow+=uvw0.x*uvw0.y*texture2D(shadowSampler,vec4(base_uv.xy+vec2(u[0],v[0]),layer,uvDepth.z));\x0ashadow+=uvw1.x*uvw0.y*texture2D(shadowSampler,vec4(base_uv.xy+vec2(u[1],v[0]),layer,uvDepth.z));\x0ashadow+=uvw2.x*uvw0.y*texture2D(shadowSampler,vec4(base_uv.xy+vec2(u[2],v[0]),layer,uvDepth.z));\x0ashadow+=uvw0.x*uvw1.y*texture2D(shadowSampler,vec4(base_uv.xy+vec2(u[0],v[1]),layer,uvDepth.z));\x0ashadow+=uvw1.x*uvw1.y*texture2D(shadowSampler,vec4(base_uv.xy+vec2(u[1],v[1]),layer,uvDepth.z));\x0ashadow+=uvw2.x*uvw1.y*texture2D(shadowSampler,vec4(base_uv.xy+vec2(u[2],v[1]),layer,uvDepth.z));\x0ashadow+=uvw0.x*uvw2.y*texture2D(shadowSampler,vec4(base_uv.xy+vec2(u[0],v[2]),layer,uvDepth.z));\x0ashadow+=uvw1.x*uvw2.y*texture2D(shadowSampler,vec4(base_uv.xy+vec2(u[1],v[2]),layer,uvDepth.z));\x0ashadow+=uvw2.x*uvw2.y*texture2D(shadowSampler,vec4(base_uv.xy+vec2(u[2],v[2]),layer,uvDepth.z));\x0ashadow=shadow/144.;\x0ashadow=mix(darkness,1.,shadow);\x0areturn\x20computeFallOff(shadow,clipSpace.xy,frustumEdgeFalloff);\x0a}\x0a\x0a#define\x20inline\x0afloat\x20computeShadowWithPCF1(vec4\x20vPositionFromLight,float\x20depthMetric,highp\x20sampler2DShadow\x20shadowSampler,float\x20darkness,float\x20frustumEdgeFalloff)\x0a{\x0aif\x20(depthMetric>1.0\x20||\x20depthMetric<0.0)\x20{\x0areturn\x201.0;\x0a}\x0aelse\x0a{\x0avec3\x20clipSpace=vPositionFromLight.xyz/vPositionFromLight.w;\x0avec3\x20uvDepth=vec3(0.5*clipSpace.xyz+vec3(0.5));\x0afloat\x20shadow=texture2D(shadowSampler,uvDepth);\x0ashadow=mix(darkness,1.,shadow);\x0areturn\x20computeFallOff(shadow,clipSpace.xy,frustumEdgeFalloff);\x0a}\x0a}\x0a\x0a\x0a\x0a#define\x20inline\x0afloat\x20computeShadowWithPCF3(vec4\x20vPositionFromLight,float\x20depthMetric,highp\x20sampler2DShadow\x20shadowSampler,vec2\x20shadowMapSizeAndInverse,float\x20darkness,float\x20frustumEdgeFalloff)\x0a{\x0aif\x20(depthMetric>1.0\x20||\x20depthMetric<0.0)\x20{\x0areturn\x201.0;\x0a}\x0aelse\x0a{\x0avec3\x20clipSpace=vPositionFromLight.xyz/vPositionFromLight.w;\x0avec3\x20uvDepth=vec3(0.5*clipSpace.xyz+vec3(0.5));\x0avec2\x20uv=uvDepth.xy*shadowMapSizeAndInverse.x;\x0auv+=0.5;\x0avec2\x20st=fract(uv);\x0avec2\x20base_uv=floor(uv)-0.5;\x0abase_uv*=shadowMapSizeAndInverse.y;\x0a\x0a\x0a\x0a\x0avec2\x20uvw0=3.-2.*st;\x0avec2\x20uvw1=1.+2.*st;\x0avec2\x20u=vec2((2.-st.x)/uvw0.x-1.,st.x/uvw1.x+1.)*shadowMapSizeAndInverse.y;\x0avec2\x20v=vec2((2.-st.y)/uvw0.y-1.,st.y/uvw1.y+1.)*shadowMapSizeAndInverse.y;\x0afloat\x20shadow=0.;\x0ashadow+=uvw0.x*uvw0.y*texture2D(shadowSampler,vec3(base_uv.xy+vec2(u[0],v[0]),uvDepth.z));\x0ashadow+=uvw1.x*uvw0.y*texture2D(shadowSampler,vec3(base_uv.xy+vec2(u[1],v[0]),uvDepth.z));\x0ashadow+=uvw0.x*uvw1.y*texture2D(shadowSampler,vec3(base_uv.xy+vec2(u[0],v[1]),uvDepth.z));\x0ashadow+=uvw1.x*uvw1.y*texture2D(shadowSampler,vec3(base_uv.xy+vec2(u[1],v[1]),uvDepth.z));\x0ashadow=shadow/16.;\x0ashadow=mix(darkness,1.,shadow);\x0areturn\x20computeFallOff(shadow,clipSpace.xy,frustumEdgeFalloff);\x0a}\x0a}\x0a\x0a\x0a\x0a#define\x20inline\x0afloat\x20computeShadowWithPCF5(vec4\x20vPositionFromLight,float\x20depthMetric,highp\x20sampler2DShadow\x20shadowSampler,vec2\x20shadowMapSizeAndInverse,float\x20darkness,float\x20frustumEdgeFalloff)\x0a{\x0aif\x20(depthMetric>1.0\x20||\x20depthMetric<0.0)\x20{\x0areturn\x201.0;\x0a}\x0aelse\x0a{\x0avec3\x20clipSpace=vPositionFromLight.xyz/vPositionFromLight.w;\x0avec3\x20uvDepth=vec3(0.5*clipSpace.xyz+vec3(0.5));\x0avec2\x20uv=uvDepth.xy*shadowMapSizeAndInverse.x;\x0auv+=0.5;\x0avec2\x20st=fract(uv);\x0avec2\x20base_uv=floor(uv)-0.5;\x0abase_uv*=shadowMapSizeAndInverse.y;\x0a\x0a\x0avec2\x20uvw0=4.-3.*st;\x0avec2\x20uvw1=vec2(7.);\x0avec2\x20uvw2=1.+3.*st;\x0avec3\x20u=vec3((3.-2.*st.x)/uvw0.x-2.,(3.+st.x)/uvw1.x,st.x/uvw2.x+2.)*shadowMapSizeAndInverse.y;\x0avec3\x20v=vec3((3.-2.*st.y)/uvw0.y-2.,(3.+st.y)/uvw1.y,st.y/uvw2.y+2.)*shadowMapSizeAndInverse.y;\x0afloat\x20shadow=0.;\x0ashadow+=uvw0.x*uvw0.y*texture2D(shadowSampler,vec3(base_uv.xy+vec2(u[0],v[0]),uvDepth.z));\x0ashadow+=uvw1.x*uvw0.y*texture2D(shadowSampler,vec3(base_uv.xy+vec2(u[1],v[0]),uvDepth.z));\x0ashadow+=uvw2.x*uvw0.y*texture2D(shadowSampler,vec3(base_uv.xy+vec2(u[2],v[0]),uvDepth.z));\x0ashadow+=uvw0.x*uvw1.y*texture2D(shadowSampler,vec3(base_uv.xy+vec2(u[0],v[1]),uvDepth.z));\x0ashadow+=uvw1.x*uvw1.y*texture2D(shadowSampler,vec3(base_uv.xy+vec2(u[1],v[1]),uvDepth.z));\x0ashadow+=uvw2.x*uvw1.y*texture2D(shadowSampler,vec3(base_uv.xy+vec2(u[2],v[1]),uvDepth.z));\x0ashadow+=uvw0.x*uvw2.y*texture2D(shadowSampler,vec3(base_uv.xy+vec2(u[0],v[2]),uvDepth.z));\x0ashadow+=uvw1.x*uvw2.y*texture2D(shadowSampler,vec3(base_uv.xy+vec2(u[1],v[2]),uvDepth.z));\x0ashadow+=uvw2.x*uvw2.y*texture2D(shadowSampler,vec3(base_uv.xy+vec2(u[2],v[2]),uvDepth.z));\x0ashadow=shadow/144.;\x0ashadow=mix(darkness,1.,shadow);\x0areturn\x20computeFallOff(shadow,clipSpace.xy,frustumEdgeFalloff);\x0a}\x0a}\x0aconst\x20vec3\x20PoissonSamplers32[64]=vec3[64](\x0avec3(0.06407013,0.05409927,0.),\x0avec3(0.7366577,0.5789394,0.),\x0avec3(-0.6270542,-0.5320278,0.),\x0avec3(-0.4096107,0.8411095,0.),\x0avec3(0.6849564,-0.4990818,0.),\x0avec3(-0.874181,-0.04579735,0.),\x0avec3(0.9989998,0.0009880066,0.),\x0avec3(-0.004920578,-0.9151649,0.),\x0avec3(0.1805763,0.9747483,0.),\x0avec3(-0.2138451,0.2635818,0.),\x0avec3(0.109845,0.3884785,0.),\x0avec3(0.06876755,-0.3581074,0.),\x0avec3(0.374073,-0.7661266,0.),\x0avec3(0.3079132,-0.1216763,0.),\x0avec3(-0.3794335,-0.8271583,0.),\x0avec3(-0.203878,-0.07715034,0.),\x0avec3(0.5912697,0.1469799,0.),\x0avec3(-0.88069,0.3031784,0.),\x0avec3(0.5040108,0.8283722,0.),\x0avec3(-0.5844124,0.5494877,0.),\x0avec3(0.6017799,-0.1726654,0.),\x0avec3(-0.5554981,0.1559997,0.),\x0avec3(-0.3016369,-0.3900928,0.),\x0avec3(-0.5550632,-0.1723762,0.),\x0avec3(0.925029,0.2995041,0.),\x0avec3(-0.2473137,0.5538505,0.),\x0avec3(0.9183037,-0.2862392,0.),\x0avec3(0.2469421,0.6718712,0.),\x0avec3(0.3916397,-0.4328209,0.),\x0avec3(-0.03576927,-0.6220032,0.),\x0avec3(-0.04661255,0.7995201,0.),\x0avec3(0.4402924,0.3640312,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.),\x0avec3(0.,0.,0.)\x0a);\x0aconst\x20vec3\x20PoissonSamplers64[64]=vec3[64](\x0avec3(-0.613392,0.617481,0.),\x0avec3(0.170019,-0.040254,0.),\x0avec3(-0.299417,0.791925,0.),\x0avec3(0.645680,0.493210,0.),\x0avec3(-0.651784,0.717887,0.),\x0avec3(0.421003,0.027070,0.),\x0avec3(-0.817194,-0.271096,0.),\x0avec3(-0.705374,-0.668203,0.),\x0avec3(0.977050,-0.108615,0.),\x0avec3(0.063326,0.142369,0.),\x0avec3(0.203528,0.214331,0.),\x0avec3(-0.667531,0.326090,0.),\x0avec3(-0.098422,-0.295755,0.),\x0avec3(-0.885922,0.215369,0.),\x0avec3(0.566637,0.605213,0.),\x0avec3(0.039766,-0.396100,0.),\x0avec3(0.751946,0.453352,0.),\x0avec3(0.078707,-0.715323,0.),\x0avec3(-0.075838,-0.529344,0.),\x0avec3(0.724479,-0.580798,0.),\x0avec3(0.222999,-0.215125,0.),\x0avec3(-0.467574,-0.405438,0.),\x0avec3(-0.248268,-0.814753,0.),\x0avec3(0.354411,-0.887570,0.),\x0avec3(0.175817,0.382366,0.),\x0avec3(0.487472,-0.063082,0.),\x0avec3(-0.084078,0.898312,0.),\x0avec3(0.488876,-0.783441,0.),\x0avec3(0.470016,0.217933,0.),\x0avec3(-0.696890,-0.549791,0.),\x0avec3(-0.149693,0.605762,0.),\x0avec3(0.034211,0.979980,0.),\x0avec3(0.503098,-0.308878,0.),\x0avec3(-0.016205,-0.872921,0.),\x0avec3(0.385784,-0.393902,0.),\x0avec3(-0.146886,-0.859249,0.),\x0avec3(0.643361,0.164098,0.),\x0avec3(0.634388,-0.049471,0.),\x0avec3(-0.688894,0.007843,0.),\x0avec3(0.464034,-0.188818,0.),\x0avec3(-0.440840,0.137486,0.),\x0avec3(0.364483,0.511704,0.),\x0avec3(0.034028,0.325968,0.),\x0avec3(0.099094,-0.308023,0.),\x0avec3(0.693960,-0.366253,0.),\x0avec3(0.678884,-0.204688,0.),\x0avec3(0.001801,0.780328,0.),\x0avec3(0.145177,-0.898984,0.),\x0avec3(0.062655,-0.611866,0.),\x0avec3(0.315226,-0.604297,0.),\x0avec3(-0.780145,0.486251,0.),\x0avec3(-0.371868,0.882138,0.),\x0avec3(0.200476,0.494430,0.),\x0avec3(-0.494552,-0.711051,0.),\x0avec3(0.612476,0.705252,0.),\x0avec3(-0.578845,-0.768792,0.),\x0avec3(-0.772454,-0.090976,0.),\x0avec3(0.504440,0.372295,0.),\x0avec3(0.155736,0.065157,0.),\x0avec3(0.391522,0.849605,0.),\x0avec3(-0.620106,-0.328104,0.),\x0avec3(0.789239,-0.419965,0.),\x0avec3(-0.545396,0.538133,0.),\x0avec3(-0.178564,-0.596057,0.)\x0a);\x0a\x0a\x0a\x0a\x0a\x0a#define\x20inline\x0afloat\x20computeShadowWithCSMPCSS(float\x20layer,vec4\x20vPositionFromLight,float\x20depthMetric,highp\x20sampler2DArray\x20depthSampler,highp\x20sampler2DArrayShadow\x20shadowSampler,float\x20shadowMapSizeInverse,float\x20lightSizeUV,float\x20darkness,float\x20frustumEdgeFalloff,int\x20searchTapCount,int\x20pcfTapCount,vec3[64]\x20poissonSamplers,vec2\x20lightSizeUVCorrection,float\x20depthCorrection,float\x20penumbraDarkness)\x0a{\x0avec3\x20clipSpace=vPositionFromLight.xyz/vPositionFromLight.w;\x0avec3\x20uvDepth=vec3(0.5*clipSpace.xyz+vec3(0.5));\x0auvDepth.z=clamp(uvDepth.z,0.,GREATEST_LESS_THAN_ONE);\x0avec4\x20uvDepthLayer=vec4(uvDepth.x,uvDepth.y,layer,uvDepth.z);\x0afloat\x20blockerDepth=0.0;\x0afloat\x20sumBlockerDepth=0.0;\x0afloat\x20numBlocker=0.0;\x0afor\x20(int\x20i=0;\x20i1.0\x20||\x20depthMetric<0.0)\x20{\x0areturn\x201.0;\x0a}\x0aelse\x0a{\x0avec3\x20clipSpace=vPositionFromLight.xyz/vPositionFromLight.w;\x0avec3\x20uvDepth=vec3(0.5*clipSpace.xyz+vec3(0.5));\x0afloat\x20blockerDepth=0.0;\x0afloat\x20sumBlockerDepth=0.0;\x0afloat\x20numBlocker=0.0;\x0afor\x20(int\x20i=0;\x20i0x1)for(var _0x420b0b=0x0;_0x420b0b<_0x471b81['length'];++_0x420b0b){var _0x51609b=_0x30c538['_SimplifyNegation'](_0x471b81[_0x420b0b]['trim']());if(!(_0x1a5778='true'!==_0x51609b&&'false'!==_0x51609b?'!'===_0x51609b[0x0]?!_0x1fd484(_0x51609b['substring'](0x1)):_0x1fd484(_0x51609b):'true'===_0x51609b)){_0x25ab38='false';break;}}if(_0x1a5778||'true'===_0x25ab38){_0x1a5778=!0x0;break;}_0x1a5778='true'!==_0x25ab38&&'false'!==_0x25ab38?'!'===_0x25ab38[0x0]?!_0x1fd484(_0x25ab38['substring'](0x1)):_0x1fd484(_0x25ab38):'true'===_0x25ab38;}return _0x1a5778?'true':'false';},_0x30c538['_SimplifyNegation']=function(_0x51e015){return'!true'===(_0x51e015=(_0x51e015=_0x51e015['replace'](/^[\s!]+/,function(_0x48801c){return(_0x48801c=_0x48801c['replace'](/[\s]/g,function(){return'';}))['length']%0x2?'!':'';}))['trim']())?_0x51e015='false':'!false'===_0x51e015&&(_0x51e015='true'),_0x51e015;},_0x30c538;}());},function(_0x595166,_0x5634d5,_0xec9dcc){'use strict';_0xec9dcc['d'](_0x5634d5,'a',function(){return _0x504a3f;});var _0x504a3f=(function(){function _0x22da88(){}return _0x22da88['ExponentialBackoff']=function(_0x22eba5,_0x36a42c){return void 0x0===_0x22eba5&&(_0x22eba5=0x3),void 0x0===_0x36a42c&&(_0x36a42c=0x1f4),function(_0x45f514,_0x31113e,_0x14a2db){return 0x0!==_0x31113e['status']||_0x14a2db>=_0x22eba5||-0x1!==_0x45f514['indexOf']('file:')?-0x1:Math['pow'](0x2,_0x14a2db)*_0x36a42c;};},_0x22da88;}());},function(_0x5718a0,_0x2f1089,_0x8a0b84){'use strict';_0x8a0b84['d'](_0x2f1089,'a',function(){return _0x58ff9a;});var _0x58ff9a=(function(){function _0x4266ae(){this['_isDepthTestDirty']=!0x1,this['_isDepthMaskDirty']=!0x1,this['_isDepthFuncDirty']=!0x1,this['_isCullFaceDirty']=!0x1,this['_isCullDirty']=!0x1,this['_isZOffsetDirty']=!0x1,this['_isFrontFaceDirty']=!0x1,this['reset']();}return Object['defineProperty'](_0x4266ae['prototype'],'isDirty',{'get':function(){return this['_isDepthFuncDirty']||this['_isDepthTestDirty']||this['_isDepthMaskDirty']||this['_isCullFaceDirty']||this['_isCullDirty']||this['_isZOffsetDirty']||this['_isFrontFaceDirty'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4266ae['prototype'],'zOffset',{'get':function(){return this['_zOffset'];},'set':function(_0x89fb2a){this['_zOffset']!==_0x89fb2a&&(this['_zOffset']=_0x89fb2a,this['_isZOffsetDirty']=!0x0);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4266ae['prototype'],'cullFace',{'get':function(){return this['_cullFace'];},'set':function(_0x3adc0e){this['_cullFace']!==_0x3adc0e&&(this['_cullFace']=_0x3adc0e,this['_isCullFaceDirty']=!0x0);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4266ae['prototype'],'cull',{'get':function(){return this['_cull'];},'set':function(_0x4cc267){this['_cull']!==_0x4cc267&&(this['_cull']=_0x4cc267,this['_isCullDirty']=!0x0);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4266ae['prototype'],'depthFunc',{'get':function(){return this['_depthFunc'];},'set':function(_0x311fcf){this['_depthFunc']!==_0x311fcf&&(this['_depthFunc']=_0x311fcf,this['_isDepthFuncDirty']=!0x0);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4266ae['prototype'],'depthMask',{'get':function(){return this['_depthMask'];},'set':function(_0x5788fb){this['_depthMask']!==_0x5788fb&&(this['_depthMask']=_0x5788fb,this['_isDepthMaskDirty']=!0x0);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4266ae['prototype'],'depthTest',{'get':function(){return this['_depthTest'];},'set':function(_0x44a9f8){this['_depthTest']!==_0x44a9f8&&(this['_depthTest']=_0x44a9f8,this['_isDepthTestDirty']=!0x0);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4266ae['prototype'],'frontFace',{'get':function(){return this['_frontFace'];},'set':function(_0x4fd53b){this['_frontFace']!==_0x4fd53b&&(this['_frontFace']=_0x4fd53b,this['_isFrontFaceDirty']=!0x0);},'enumerable':!0x1,'configurable':!0x0}),_0x4266ae['prototype']['reset']=function(){this['_depthMask']=!0x0,this['_depthTest']=!0x0,this['_depthFunc']=null,this['_cullFace']=null,this['_cull']=null,this['_zOffset']=0x0,this['_frontFace']=null,this['_isDepthTestDirty']=!0x0,this['_isDepthMaskDirty']=!0x0,this['_isDepthFuncDirty']=!0x1,this['_isCullFaceDirty']=!0x1,this['_isCullDirty']=!0x1,this['_isZOffsetDirty']=!0x1,this['_isFrontFaceDirty']=!0x1;},_0x4266ae['prototype']['apply']=function(_0x25dd0b){this['isDirty']&&(this['_isCullDirty']&&(this['cull']?_0x25dd0b['enable'](_0x25dd0b['CULL_FACE']):_0x25dd0b['disable'](_0x25dd0b['CULL_FACE']),this['_isCullDirty']=!0x1),this['_isCullFaceDirty']&&(_0x25dd0b['cullFace'](this['cullFace']),this['_isCullFaceDirty']=!0x1),this['_isDepthMaskDirty']&&(_0x25dd0b['depthMask'](this['depthMask']),this['_isDepthMaskDirty']=!0x1),this['_isDepthTestDirty']&&(this['depthTest']?_0x25dd0b['enable'](_0x25dd0b['DEPTH_TEST']):_0x25dd0b['disable'](_0x25dd0b['DEPTH_TEST']),this['_isDepthTestDirty']=!0x1),this['_isDepthFuncDirty']&&(_0x25dd0b['depthFunc'](this['depthFunc']),this['_isDepthFuncDirty']=!0x1),this['_isZOffsetDirty']&&(this['zOffset']?(_0x25dd0b['enable'](_0x25dd0b['POLYGON_OFFSET_FILL']),_0x25dd0b['polygonOffset'](this['zOffset'],0x0)):_0x25dd0b['disable'](_0x25dd0b['POLYGON_OFFSET_FILL']),this['_isZOffsetDirty']=!0x1),this['_isFrontFaceDirty']&&(_0x25dd0b['frontFace'](this['frontFace']),this['_isFrontFaceDirty']=!0x1));},_0x4266ae;}());},function(_0x45fd02,_0x550df1,_0x374ee4){'use strict';_0x374ee4['d'](_0x550df1,'a',function(){return _0x3da65a;});var _0x5e1ae3=_0x374ee4(0x2),_0x3da65a=(function(){function _0x552154(){this['_isStencilTestDirty']=!0x1,this['_isStencilMaskDirty']=!0x1,this['_isStencilFuncDirty']=!0x1,this['_isStencilOpDirty']=!0x1,this['reset']();}return Object['defineProperty'](_0x552154['prototype'],'isDirty',{'get':function(){return this['_isStencilTestDirty']||this['_isStencilMaskDirty']||this['_isStencilFuncDirty']||this['_isStencilOpDirty'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x552154['prototype'],'stencilFunc',{'get':function(){return this['_stencilFunc'];},'set':function(_0x5d29ce){this['_stencilFunc']!==_0x5d29ce&&(this['_stencilFunc']=_0x5d29ce,this['_isStencilFuncDirty']=!0x0);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x552154['prototype'],'stencilFuncRef',{'get':function(){return this['_stencilFuncRef'];},'set':function(_0x1abd37){this['_stencilFuncRef']!==_0x1abd37&&(this['_stencilFuncRef']=_0x1abd37,this['_isStencilFuncDirty']=!0x0);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x552154['prototype'],'stencilFuncMask',{'get':function(){return this['_stencilFuncMask'];},'set':function(_0x2b80fb){this['_stencilFuncMask']!==_0x2b80fb&&(this['_stencilFuncMask']=_0x2b80fb,this['_isStencilFuncDirty']=!0x0);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x552154['prototype'],'stencilOpStencilFail',{'get':function(){return this['_stencilOpStencilFail'];},'set':function(_0xa272f3){this['_stencilOpStencilFail']!==_0xa272f3&&(this['_stencilOpStencilFail']=_0xa272f3,this['_isStencilOpDirty']=!0x0);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x552154['prototype'],'stencilOpDepthFail',{'get':function(){return this['_stencilOpDepthFail'];},'set':function(_0x54e816){this['_stencilOpDepthFail']!==_0x54e816&&(this['_stencilOpDepthFail']=_0x54e816,this['_isStencilOpDirty']=!0x0);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x552154['prototype'],'stencilOpStencilDepthPass',{'get':function(){return this['_stencilOpStencilDepthPass'];},'set':function(_0x84bca6){this['_stencilOpStencilDepthPass']!==_0x84bca6&&(this['_stencilOpStencilDepthPass']=_0x84bca6,this['_isStencilOpDirty']=!0x0);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x552154['prototype'],'stencilMask',{'get':function(){return this['_stencilMask'];},'set':function(_0x48b1bd){this['_stencilMask']!==_0x48b1bd&&(this['_stencilMask']=_0x48b1bd,this['_isStencilMaskDirty']=!0x0);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x552154['prototype'],'stencilTest',{'get':function(){return this['_stencilTest'];},'set':function(_0x8c6165){this['_stencilTest']!==_0x8c6165&&(this['_stencilTest']=_0x8c6165,this['_isStencilTestDirty']=!0x0);},'enumerable':!0x1,'configurable':!0x0}),_0x552154['prototype']['reset']=function(){this['_stencilTest']=!0x1,this['_stencilMask']=0xff,this['_stencilFunc']=_0x552154['ALWAYS'],this['_stencilFuncRef']=0x1,this['_stencilFuncMask']=0xff,this['_stencilOpStencilFail']=_0x552154['KEEP'],this['_stencilOpDepthFail']=_0x552154['KEEP'],this['_stencilOpStencilDepthPass']=_0x552154['REPLACE'],this['_isStencilTestDirty']=!0x0,this['_isStencilMaskDirty']=!0x0,this['_isStencilFuncDirty']=!0x0,this['_isStencilOpDirty']=!0x0;},_0x552154['prototype']['apply']=function(_0x39fb66){this['isDirty']&&(this['_isStencilTestDirty']&&(this['stencilTest']?_0x39fb66['enable'](_0x39fb66['STENCIL_TEST']):_0x39fb66['disable'](_0x39fb66['STENCIL_TEST']),this['_isStencilTestDirty']=!0x1),this['_isStencilMaskDirty']&&(_0x39fb66['stencilMask'](this['stencilMask']),this['_isStencilMaskDirty']=!0x1),this['_isStencilFuncDirty']&&(_0x39fb66['stencilFunc'](this['stencilFunc'],this['stencilFuncRef'],this['stencilFuncMask']),this['_isStencilFuncDirty']=!0x1),this['_isStencilOpDirty']&&(_0x39fb66['stencilOp'](this['stencilOpStencilFail'],this['stencilOpDepthFail'],this['stencilOpStencilDepthPass']),this['_isStencilOpDirty']=!0x1));},_0x552154['ALWAYS']=_0x5e1ae3['a']['ALWAYS'],_0x552154['KEEP']=_0x5e1ae3['a']['KEEP'],_0x552154['REPLACE']=_0x5e1ae3['a']['REPLACE'],_0x552154;}());},function(_0x5a9514,_0x4d1d96,_0x113315){'use strict';_0x113315['d'](_0x4d1d96,'a',function(){return _0x59cbb5;});var _0x59cbb5=(function(){function _0x3441b1(){this['_isAlphaBlendDirty']=!0x1,this['_isBlendFunctionParametersDirty']=!0x1,this['_isBlendEquationParametersDirty']=!0x1,this['_isBlendConstantsDirty']=!0x1,this['_alphaBlend']=!0x1,this['_blendFunctionParameters']=new Array(0x4),this['_blendEquationParameters']=new Array(0x2),this['_blendConstants']=new Array(0x4),this['reset']();}return Object['defineProperty'](_0x3441b1['prototype'],'isDirty',{'get':function(){return this['_isAlphaBlendDirty']||this['_isBlendFunctionParametersDirty'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3441b1['prototype'],'alphaBlend',{'get':function(){return this['_alphaBlend'];},'set':function(_0x578c94){this['_alphaBlend']!==_0x578c94&&(this['_alphaBlend']=_0x578c94,this['_isAlphaBlendDirty']=!0x0);},'enumerable':!0x1,'configurable':!0x0}),_0x3441b1['prototype']['setAlphaBlendConstants']=function(_0x381996,_0x180b27,_0x2970a4,_0x461a83){this['_blendConstants'][0x0]===_0x381996&&this['_blendConstants'][0x1]===_0x180b27&&this['_blendConstants'][0x2]===_0x2970a4&&this['_blendConstants'][0x3]===_0x461a83||(this['_blendConstants'][0x0]=_0x381996,this['_blendConstants'][0x1]=_0x180b27,this['_blendConstants'][0x2]=_0x2970a4,this['_blendConstants'][0x3]=_0x461a83,this['_isBlendConstantsDirty']=!0x0);},_0x3441b1['prototype']['setAlphaBlendFunctionParameters']=function(_0x216013,_0x4eef84,_0x241b0d,_0x8039ea){this['_blendFunctionParameters'][0x0]===_0x216013&&this['_blendFunctionParameters'][0x1]===_0x4eef84&&this['_blendFunctionParameters'][0x2]===_0x241b0d&&this['_blendFunctionParameters'][0x3]===_0x8039ea||(this['_blendFunctionParameters'][0x0]=_0x216013,this['_blendFunctionParameters'][0x1]=_0x4eef84,this['_blendFunctionParameters'][0x2]=_0x241b0d,this['_blendFunctionParameters'][0x3]=_0x8039ea,this['_isBlendFunctionParametersDirty']=!0x0);},_0x3441b1['prototype']['setAlphaEquationParameters']=function(_0x494964,_0x45e563){this['_blendEquationParameters'][0x0]===_0x494964&&this['_blendEquationParameters'][0x1]===_0x45e563||(this['_blendEquationParameters'][0x0]=_0x494964,this['_blendEquationParameters'][0x1]=_0x45e563,this['_isBlendEquationParametersDirty']=!0x0);},_0x3441b1['prototype']['reset']=function(){this['_alphaBlend']=!0x1,this['_blendFunctionParameters'][0x0]=null,this['_blendFunctionParameters'][0x1]=null,this['_blendFunctionParameters'][0x2]=null,this['_blendFunctionParameters'][0x3]=null,this['_blendEquationParameters'][0x0]=null,this['_blendEquationParameters'][0x1]=null,this['_blendConstants'][0x0]=null,this['_blendConstants'][0x1]=null,this['_blendConstants'][0x2]=null,this['_blendConstants'][0x3]=null,this['_isAlphaBlendDirty']=!0x0,this['_isBlendFunctionParametersDirty']=!0x1,this['_isBlendEquationParametersDirty']=!0x1,this['_isBlendConstantsDirty']=!0x1;},_0x3441b1['prototype']['apply']=function(_0x5c4513){this['isDirty']&&(this['_isAlphaBlendDirty']&&(this['_alphaBlend']?_0x5c4513['enable'](_0x5c4513['BLEND']):_0x5c4513['disable'](_0x5c4513['BLEND']),this['_isAlphaBlendDirty']=!0x1),this['_isBlendFunctionParametersDirty']&&(_0x5c4513['blendFuncSeparate'](this['_blendFunctionParameters'][0x0],this['_blendFunctionParameters'][0x1],this['_blendFunctionParameters'][0x2],this['_blendFunctionParameters'][0x3]),this['_isBlendFunctionParametersDirty']=!0x1),this['_isBlendEquationParametersDirty']&&(_0x5c4513['blendEquationSeparate'](this['_blendEquationParameters'][0x0],this['_blendEquationParameters'][0x1]),this['_isBlendEquationParametersDirty']=!0x1),this['_isBlendConstantsDirty']&&(_0x5c4513['blendColor'](this['_blendConstants'][0x0],this['_blendConstants'][0x1],this['_blendConstants'][0x2],this['_blendConstants'][0x3]),this['_isBlendConstantsDirty']=!0x1));},_0x3441b1;}());},function(_0x23203b,_0x414025,_0x1b18bb){'use strict';_0x1b18bb['d'](_0x414025,'a',function(){return _0x46e29e;});var _0x46e29e=(function(){function _0x3b32e4(){this['vertexCompilationError']=null,this['fragmentCompilationError']=null,this['programLinkError']=null,this['programValidationError']=null;}return Object['defineProperty'](_0x3b32e4['prototype'],'isAsync',{'get':function(){return this['isParallelCompiled'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x3b32e4['prototype'],'isReady',{'get':function(){return!!this['program']&&(!this['isParallelCompiled']||this['engine']['_isRenderingStateCompiled'](this));},'enumerable':!0x1,'configurable':!0x0}),_0x3b32e4['prototype']['_handlesSpectorRebuildCallback']=function(_0x110e44){_0x110e44&&this['program']&&_0x110e44(this['program']);},_0x3b32e4['prototype']['_getVertexShaderCode']=function(){return this['vertexShader']?this['engine']['_getShaderSource'](this['vertexShader']):null;},_0x3b32e4['prototype']['_getFragmentShaderCode']=function(){return this['fragmentShader']?this['engine']['_getShaderSource'](this['fragmentShader']):null;},_0x3b32e4;}());},function(_0x155746,_0x30a706,_0x16a08b){'use strict';var _0x11a665;_0x16a08b['d'](_0x30a706,'a',function(){return _0x4638e0;}),function(_0x19788b){_0x19788b[_0x19788b['Pending']=0x0]='Pending',_0x19788b[_0x19788b['Fulfilled']=0x1]='Fulfilled',_0x19788b[_0x19788b['Rejected']=0x2]='Rejected';}(_0x11a665||(_0x11a665={}));var _0x1e7a1d=function(){this['count']=0x0,this['target']=0x0,this['results']=[];},_0x13a21a=(function(){function _0x187b93(_0x2260fe){var _0x15b346=this;if(this['_state']=_0x11a665['Pending'],this['_children']=new Array(),this['_rejectWasConsumed']=!0x1,_0x2260fe)try{_0x2260fe(function(_0x26e4d2){_0x15b346['_resolve'](_0x26e4d2);},function(_0x651059){_0x15b346['_reject'](_0x651059);});}catch(_0x9eda4c){this['_reject'](_0x9eda4c);}}return Object['defineProperty'](_0x187b93['prototype'],'_result',{'get':function(){return this['_resultValue'];},'set':function(_0x4af95a){this['_resultValue']=_0x4af95a,this['_parent']&&void 0x0===this['_parent']['_result']&&(this['_parent']['_result']=_0x4af95a);},'enumerable':!0x1,'configurable':!0x0}),_0x187b93['prototype']['catch']=function(_0x5e5699){return this['then'](void 0x0,_0x5e5699);},_0x187b93['prototype']['then']=function(_0x3cd386,_0x299e69){var _0x40ef3b=this,_0x1b065e=new _0x187b93();return _0x1b065e['_onFulfilled']=_0x3cd386,_0x1b065e['_onRejected']=_0x299e69,this['_children']['push'](_0x1b065e),_0x1b065e['_parent']=this,this['_state']!==_0x11a665['Pending']&&setTimeout(function(){if(_0x40ef3b['_state']===_0x11a665['Fulfilled']||_0x40ef3b['_rejectWasConsumed']){var _0x471d48=_0x1b065e['_resolve'](_0x40ef3b['_result']);if(null!=_0x471d48){if(void 0x0!==_0x471d48['_state']){var _0x4f4968=_0x471d48;_0x1b065e['_children']['push'](_0x4f4968),_0x4f4968['_parent']=_0x1b065e,_0x1b065e=_0x4f4968;}else _0x1b065e['_result']=_0x471d48;}}else _0x1b065e['_reject'](_0x40ef3b['_reason']);}),_0x1b065e;},_0x187b93['prototype']['_moveChildren']=function(_0x5bb6c5){var _0x2be986,_0x2a6b68=this;if((_0x2be986=this['_children'])['push']['apply'](_0x2be986,_0x5bb6c5['splice'](0x0,_0x5bb6c5['length'])),this['_children']['forEach'](function(_0x2679da){_0x2679da['_parent']=_0x2a6b68;}),this['_state']===_0x11a665['Fulfilled'])for(var _0x5335f2=0x0,_0x47b74a=this['_children'];_0x5335f2<_0x47b74a['length'];_0x5335f2++){_0x47b74a[_0x5335f2]['_resolve'](this['_result']);}else{if(this['_state']===_0x11a665['Rejected'])for(var _0xa136e7=0x0,_0x383fc9=this['_children'];_0xa136e7<_0x383fc9['length'];_0xa136e7++){_0x383fc9[_0xa136e7]['_reject'](this['_reason']);}}},_0x187b93['prototype']['_resolve']=function(_0x3fe87c){try{this['_state']=_0x11a665['Fulfilled'];var _0x3f29ac=null;if(this['_onFulfilled']&&(_0x3f29ac=this['_onFulfilled'](_0x3fe87c)),null!=_0x3f29ac){if(void 0x0!==_0x3f29ac['_state']){var _0x747711=_0x3f29ac;_0x747711['_parent']=this,_0x747711['_moveChildren'](this['_children']),_0x3fe87c=_0x747711['_result'];}else _0x3fe87c=_0x3f29ac;}this['_result']=_0x3fe87c;for(var _0x37b469=0x0,_0x46e916=this['_children'];_0x37b469<_0x46e916['length'];_0x37b469++){_0x46e916[_0x37b469]['_resolve'](_0x3fe87c);}this['_children']['length']=0x0,delete this['_onFulfilled'],delete this['_onRejected'];}catch(_0x5cc9f0){this['_reject'](_0x5cc9f0,!0x0);}},_0x187b93['prototype']['_reject']=function(_0x2820ae,_0x2844b4){if(void 0x0===_0x2844b4&&(_0x2844b4=!0x1),this['_state']=_0x11a665['Rejected'],this['_reason']=_0x2820ae,this['_onRejected']&&!_0x2844b4)try{this['_onRejected'](_0x2820ae),this['_rejectWasConsumed']=!0x0;}catch(_0x30400b){_0x2820ae=_0x30400b;}for(var _0x1ed6b8=0x0,_0x3ac641=this['_children'];_0x1ed6b8<_0x3ac641['length'];_0x1ed6b8++){var _0x5a2e62=_0x3ac641[_0x1ed6b8];this['_rejectWasConsumed']?_0x5a2e62['_resolve'](null):_0x5a2e62['_reject'](_0x2820ae);}this['_children']['length']=0x0,delete this['_onFulfilled'],delete this['_onRejected'];},_0x187b93['resolve']=function(_0x3555f4){var _0x2a7c86=new _0x187b93();return _0x2a7c86['_resolve'](_0x3555f4),_0x2a7c86;},_0x187b93['_RegisterForFulfillment']=function(_0x61147d,_0x52ba17,_0x4c300e){_0x61147d['then'](function(_0x5c1e5d){return _0x52ba17['results'][_0x4c300e]=_0x5c1e5d,_0x52ba17['count']++,_0x52ba17['count']===_0x52ba17['target']&&_0x52ba17['rootPromise']['_resolve'](_0x52ba17['results']),null;},function(_0xfee1be){_0x52ba17['rootPromise']['_state']!==_0x11a665['Rejected']&&_0x52ba17['rootPromise']['_reject'](_0xfee1be);});},_0x187b93['all']=function(_0x59608c){var _0x2340d0=new _0x187b93(),_0xb6d375=new _0x1e7a1d();if(_0xb6d375['target']=_0x59608c['length'],_0xb6d375['rootPromise']=_0x2340d0,_0x59608c['length']){for(var _0x321900=0x0;_0x321900<_0x59608c['length'];_0x321900++)_0x187b93['_RegisterForFulfillment'](_0x59608c[_0x321900],_0xb6d375,_0x321900);}else _0x2340d0['_resolve']([]);return _0x2340d0;},_0x187b93['race']=function(_0x21e4f5){var _0x953714=new _0x187b93();if(_0x21e4f5['length'])for(var _0x44f3dd=0x0,_0x29cb66=_0x21e4f5;_0x44f3dd<_0x29cb66['length'];_0x44f3dd++){_0x29cb66[_0x44f3dd]['then'](function(_0x22f6b1){return _0x953714&&(_0x953714['_resolve'](_0x22f6b1),_0x953714=null),null;},function(_0x28d04c){_0x953714&&(_0x953714['_reject'](_0x28d04c),_0x953714=null);});}return _0x953714;},_0x187b93;}()),_0x4638e0=(function(){function _0x4d9a4e(){}return _0x4d9a4e['Apply']=function(_0x577706){(void 0x0===_0x577706&&(_0x577706=!0x1),_0x577706||'undefined'==typeof Promise)&&(window['Promise']=_0x13a21a);},_0x4d9a4e;}());},function(_0x8f2f16,_0x5ae339,_0x21bf68){'use strict';_0x21bf68['d'](_0x5ae339,'a',function(){return _0x48110a;}),_0x21bf68['d'](_0x5ae339,'b',function(){return _0x5ce80e;});var _0x2b9565=_0x21bf68(0x39),_0x48110a=(function(){function _0x4bfb06(_0x47d7a4){void 0x0===_0x47d7a4&&(_0x47d7a4=0x1e),this['_enabled']=!0x0,this['_rollingFrameTime']=new _0x5ce80e(_0x47d7a4);}return _0x4bfb06['prototype']['sampleFrame']=function(_0x374428){if(void 0x0===_0x374428&&(_0x374428=_0x2b9565['a']['Now']),this['_enabled']){if(null!=this['_lastFrameTimeMs']){var _0x4c55ec=_0x374428-this['_lastFrameTimeMs'];this['_rollingFrameTime']['add'](_0x4c55ec);}this['_lastFrameTimeMs']=_0x374428;}},Object['defineProperty'](_0x4bfb06['prototype'],'averageFrameTime',{'get':function(){return this['_rollingFrameTime']['average'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4bfb06['prototype'],'averageFrameTimeVariance',{'get':function(){return this['_rollingFrameTime']['variance'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4bfb06['prototype'],'instantaneousFrameTime',{'get':function(){return this['_rollingFrameTime']['history'](0x0);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4bfb06['prototype'],'averageFPS',{'get':function(){return 0x3e8/this['_rollingFrameTime']['average'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4bfb06['prototype'],'instantaneousFPS',{'get':function(){var _0x25bb69=this['_rollingFrameTime']['history'](0x0);return 0x0===_0x25bb69?0x0:0x3e8/_0x25bb69;},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x4bfb06['prototype'],'isSaturated',{'get':function(){return this['_rollingFrameTime']['isSaturated']();},'enumerable':!0x1,'configurable':!0x0}),_0x4bfb06['prototype']['enable']=function(){this['_enabled']=!0x0;},_0x4bfb06['prototype']['disable']=function(){this['_enabled']=!0x1,this['_lastFrameTimeMs']=null;},Object['defineProperty'](_0x4bfb06['prototype'],'isEnabled',{'get':function(){return this['_enabled'];},'enumerable':!0x1,'configurable':!0x0}),_0x4bfb06['prototype']['reset']=function(){this['_lastFrameTimeMs']=null,this['_rollingFrameTime']['reset']();},_0x4bfb06;}()),_0x5ce80e=(function(){function _0x5b64fd(_0x262138){this['_samples']=new Array(_0x262138),this['reset']();}return _0x5b64fd['prototype']['add']=function(_0x2bff54){var _0x47a03;if(this['isSaturated']()){var _0xd50e09=this['_samples'][this['_pos']];_0x47a03=_0xd50e09-this['average'],this['average']-=_0x47a03/(this['_sampleCount']-0x1),this['_m2']-=_0x47a03*(_0xd50e09-this['average']);}else this['_sampleCount']++;_0x47a03=_0x2bff54-this['average'],this['average']+=_0x47a03/this['_sampleCount'],this['_m2']+=_0x47a03*(_0x2bff54-this['average']),this['variance']=this['_m2']/(this['_sampleCount']-0x1),this['_samples'][this['_pos']]=_0x2bff54,this['_pos']++,this['_pos']%=this['_samples']['length'];},_0x5b64fd['prototype']['history']=function(_0x3be443){if(_0x3be443>=this['_sampleCount']||_0x3be443>=this['_samples']['length'])return 0x0;var _0x321be0=this['_wrapPosition'](this['_pos']-0x1);return this['_samples'][this['_wrapPosition'](_0x321be0-_0x3be443)];},_0x5b64fd['prototype']['isSaturated']=function(){return this['_sampleCount']>=this['_samples']['length'];},_0x5b64fd['prototype']['reset']=function(){this['average']=0x0,this['variance']=0x0,this['_sampleCount']=0x0,this['_pos']=0x0,this['_m2']=0x0;},_0x5b64fd['prototype']['_wrapPosition']=function(_0x51200c){var _0x31d163=this['_samples']['length'];return(_0x51200c%_0x31d163+_0x31d163)%_0x31d163;},_0x5b64fd;}());},function(_0x5aa865,_0x40264c,_0x17b992){'use strict';_0x17b992['d'](_0x40264c,'a',function(){return _0x601c52;});var _0xfd69b4=_0x17b992(0x0),_0x601c52=function(){this['_checkCollisions']=!0x1,this['_collisionMask']=-0x1,this['_collisionGroup']=-0x1,this['_surroundingMeshes']=null,this['_collider']=null,this['_oldPositionForCollisions']=new _0xfd69b4['e'](0x0,0x0,0x0),this['_diffPositionForCollisions']=new _0xfd69b4['e'](0x0,0x0,0x0),this['_collisionResponse']=!0x0;};},function(_0x5d5865,_0x2deb29,_0x58f147){'use strict';_0x58f147['d'](_0x2deb29,'a',function(){return _0x358cf6;});var _0x27f2ea=_0x58f147(0x21),_0x4488d4=_0x58f147(0x0),_0x46bf33=_0x58f147(0x2),_0x358cf6=(function(){function _0xf4cd43(_0x1e9382,_0x2991e0,_0x43ec93,_0x54df15,_0x4a6391){void 0x0===_0x43ec93&&(_0x43ec93=null),void 0x0===_0x54df15&&(_0x54df15=null),void 0x0===_0x4a6391&&(_0x4a6391=null),this['index']=_0x1e9382,this['_opaqueSubMeshes']=new _0x27f2ea['a'](0x100),this['_transparentSubMeshes']=new _0x27f2ea['a'](0x100),this['_alphaTestSubMeshes']=new _0x27f2ea['a'](0x100),this['_depthOnlySubMeshes']=new _0x27f2ea['a'](0x100),this['_particleSystems']=new _0x27f2ea['a'](0x100),this['_spriteManagers']=new _0x27f2ea['a'](0x100),this['_edgesRenderers']=new _0x27f2ea['b'](0x10),this['_scene']=_0x2991e0,this['opaqueSortCompareFn']=_0x43ec93,this['alphaTestSortCompareFn']=_0x54df15,this['transparentSortCompareFn']=_0x4a6391;}return Object['defineProperty'](_0xf4cd43['prototype'],'opaqueSortCompareFn',{'set':function(_0x48fa1c){this['_opaqueSortCompareFn']=_0x48fa1c,this['_renderOpaque']=_0x48fa1c?this['renderOpaqueSorted']:_0xf4cd43['renderUnsorted'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xf4cd43['prototype'],'alphaTestSortCompareFn',{'set':function(_0x2f6217){this['_alphaTestSortCompareFn']=_0x2f6217,this['_renderAlphaTest']=_0x2f6217?this['renderAlphaTestSorted']:_0xf4cd43['renderUnsorted'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0xf4cd43['prototype'],'transparentSortCompareFn',{'set':function(_0x452641){this['_transparentSortCompareFn']=_0x452641||_0xf4cd43['defaultTransparentSortCompare'],this['_renderTransparent']=this['renderTransparentSorted'];},'enumerable':!0x1,'configurable':!0x0}),_0xf4cd43['prototype']['render']=function(_0x5433fa,_0x79c63d,_0x16edee,_0x4eed30){if(_0x5433fa)_0x5433fa(this['_opaqueSubMeshes'],this['_alphaTestSubMeshes'],this['_transparentSubMeshes'],this['_depthOnlySubMeshes']);else{var _0x2ee206=this['_scene']['getEngine']();0x0!==this['_depthOnlySubMeshes']['length']&&(_0x2ee206['setColorWrite'](!0x1),this['_renderAlphaTest'](this['_depthOnlySubMeshes']),_0x2ee206['setColorWrite'](!0x0)),0x0!==this['_opaqueSubMeshes']['length']&&this['_renderOpaque'](this['_opaqueSubMeshes']),0x0!==this['_alphaTestSubMeshes']['length']&&this['_renderAlphaTest'](this['_alphaTestSubMeshes']);var _0x4fc7dd=_0x2ee206['getStencilBuffer']();if(_0x2ee206['setStencilBuffer'](!0x1),_0x79c63d&&this['_renderSprites'](),_0x16edee&&this['_renderParticles'](_0x4eed30),this['onBeforeTransparentRendering']&&this['onBeforeTransparentRendering'](),0x0!==this['_transparentSubMeshes']['length']&&(_0x2ee206['setStencilBuffer'](_0x4fc7dd),this['_renderTransparent'](this['_transparentSubMeshes']),_0x2ee206['setAlphaMode'](_0x46bf33['a']['ALPHA_DISABLE'])),_0x2ee206['setStencilBuffer'](!0x1),this['_edgesRenderers']['length']){for(var _0x431688=0x0;_0x431688_0x323d73['_alphaIndex']?0x1:_0x40126f['_alphaIndex']<_0x323d73['_alphaIndex']?-0x1:_0xf4cd43['backToFrontSortCompare'](_0x40126f,_0x323d73);},_0xf4cd43['backToFrontSortCompare']=function(_0x2428a4,_0x375840){return _0x2428a4['_distanceToCamera']<_0x375840['_distanceToCamera']?0x1:_0x2428a4['_distanceToCamera']>_0x375840['_distanceToCamera']?-0x1:0x0;},_0xf4cd43['frontToBackSortCompare']=function(_0x35cece,_0x4bf227){return _0x35cece['_distanceToCamera']<_0x4bf227['_distanceToCamera']?-0x1:_0x35cece['_distanceToCamera']>_0x4bf227['_distanceToCamera']?0x1:0x0;},_0xf4cd43['prototype']['prepare']=function(){this['_opaqueSubMeshes']['reset'](),this['_transparentSubMeshes']['reset'](),this['_alphaTestSubMeshes']['reset'](),this['_depthOnlySubMeshes']['reset'](),this['_particleSystems']['reset'](),this['_spriteManagers']['reset'](),this['_edgesRenderers']['reset']();},_0xf4cd43['prototype']['dispose']=function(){this['_opaqueSubMeshes']['dispose'](),this['_transparentSubMeshes']['dispose'](),this['_alphaTestSubMeshes']['dispose'](),this['_depthOnlySubMeshes']['dispose'](),this['_particleSystems']['dispose'](),this['_spriteManagers']['dispose'](),this['_edgesRenderers']['dispose']();},_0xf4cd43['prototype']['dispatch']=function(_0x47b1ee,_0x47e928,_0x483f28){void 0x0===_0x47e928&&(_0x47e928=_0x47b1ee['getMesh']()),void 0x0===_0x483f28&&(_0x483f28=_0x47b1ee['getMaterial']()),null!=_0x483f28&&(_0x483f28['needAlphaBlendingForMesh'](_0x47e928)?this['_transparentSubMeshes']['push'](_0x47b1ee):_0x483f28['needAlphaTesting']()?(_0x483f28['needDepthPrePass']&&this['_depthOnlySubMeshes']['push'](_0x47b1ee),this['_alphaTestSubMeshes']['push'](_0x47b1ee)):(_0x483f28['needDepthPrePass']&&this['_depthOnlySubMeshes']['push'](_0x47b1ee),this['_opaqueSubMeshes']['push'](_0x47b1ee)),_0x47e928['_renderingGroup']=this,_0x47e928['_edgesRenderer']&&_0x47e928['_edgesRenderer']['isEnabled']&&this['_edgesRenderers']['pushNoDuplicate'](_0x47e928['_edgesRenderer']));},_0xf4cd43['prototype']['dispatchSprites']=function(_0x1fa542){this['_spriteManagers']['push'](_0x1fa542);},_0xf4cd43['prototype']['dispatchParticles']=function(_0x30554b){this['_particleSystems']['push'](_0x30554b);},_0xf4cd43['prototype']['_renderParticles']=function(_0x476f69){if(0x0!==this['_particleSystems']['length']){var _0x3f856e=this['_scene']['activeCamera'];this['_scene']['onBeforeParticlesRenderingObservable']['notifyObservers'](this['_scene']);for(var _0x23e0d9=0x0;_0x23e0d9=0x0;){var _0x16903f=_0x583be4[_0x2f4190];_0x16903f<0x0?_0x16903f=0x0:_0x16903f>0x1&&(_0x16903f=0x1),_0x3d3f77[_0x2f4190]=0xff*_0x16903f;}_0x583be4=_0x3d3f77;}var _0x222e42=document['createElement']('canvas');_0x222e42['width']=_0x3b323e,_0x222e42['height']=_0x2139ca;var _0xe8574c=_0x222e42['getContext']('2d');if(!_0xe8574c)return null;var _0x3faac0=_0xe8574c['createImageData'](_0x3b323e,_0x2139ca);if(_0x3faac0['data']['set'](_0x583be4),_0xe8574c['putImageData'](_0x3faac0,0x0,0x0),_0x5e7a12['invertY']){var _0x85efd0=document['createElement']('canvas');_0x85efd0['width']=_0x3b323e,_0x85efd0['height']=_0x2139ca;var _0x553b0b=_0x85efd0['getContext']('2d');return _0x553b0b?(_0x553b0b['translate'](0x0,_0x2139ca),_0x553b0b['scale'](0x1,-0x1),_0x553b0b['drawImage'](_0x222e42,0x0,0x0),_0x85efd0['toDataURL']('image/png')):null;}return _0x222e42['toDataURL']('image/png');},_0x313f84;}());},function(_0x5c96b9,_0x57d8ad,_0x2561cb){'use strict';_0x2561cb['d'](_0x57d8ad,'a',function(){return _0x468a81;});var _0x58dad5=_0x2561cb(0x1),_0x42ce12=_0x2561cb(0x0),_0x5b4c82=_0x2561cb(0x8),_0x57636d=_0x2561cb(0x1f),_0x259c89=_0x2561cb(0x7),_0x83d86b=_0x2561cb(0x29),_0x388e14=_0x2561cb(0x2e),_0x420af1=_0x2561cb(0x4),_0x4e1bf6=_0x2561cb(0x2b),_0x27e725=_0x2561cb(0xc);_0x259c89['a']['_instancedMeshFactory']=function(_0x35ec7d,_0x519b8a){var _0x597e3f=new _0x468a81(_0x35ec7d,_0x519b8a);if(_0x519b8a['instancedBuffers']){for(var _0x2e8c0f in(_0x597e3f['instancedBuffers']={},_0x519b8a['instancedBuffers']))_0x597e3f['instancedBuffers'][_0x2e8c0f]=_0x519b8a['instancedBuffers'][_0x2e8c0f];}return _0x597e3f;};var _0x468a81=function(_0xdb0620){function _0x6dece1(_0x2e9dfc,_0x21bece){var _0x107764=_0xdb0620['call'](this,_0x2e9dfc,_0x21bece['getScene']())||this;_0x107764['_indexInSourceMeshInstanceArray']=-0x1,_0x21bece['addInstance'](_0x107764),_0x107764['_sourceMesh']=_0x21bece,_0x107764['_unIndexed']=_0x21bece['_unIndexed'],_0x107764['position']['copyFrom'](_0x21bece['position']),_0x107764['rotation']['copyFrom'](_0x21bece['rotation']),_0x107764['scaling']['copyFrom'](_0x21bece['scaling']),_0x21bece['rotationQuaternion']&&(_0x107764['rotationQuaternion']=_0x21bece['rotationQuaternion']['clone']()),_0x107764['animations']=_0x27e725['b']['Slice'](_0x21bece['animations']);for(var _0x4102c9=0x0,_0x5bdba5=_0x21bece['getAnimationRanges']();_0x4102c9<_0x5bdba5['length'];_0x4102c9++){var _0x51d3e7=_0x5bdba5[_0x4102c9];null!=_0x51d3e7&&_0x107764['createAnimationRange'](_0x51d3e7['name'],_0x51d3e7['from'],_0x51d3e7['to']);}return _0x107764['infiniteDistance']=_0x21bece['infiniteDistance'],_0x107764['setPivotMatrix'](_0x21bece['getPivotMatrix']()),_0x107764['refreshBoundingInfo'](),_0x107764['_syncSubMeshes'](),_0x107764;}return Object(_0x58dad5['d'])(_0x6dece1,_0xdb0620),_0x6dece1['prototype']['getClassName']=function(){return'InstancedMesh';},Object['defineProperty'](_0x6dece1['prototype'],'lightSources',{'get':function(){return this['_sourceMesh']['_lightSources'];},'enumerable':!0x1,'configurable':!0x0}),_0x6dece1['prototype']['_resyncLightSources']=function(){},_0x6dece1['prototype']['_resyncLightSource']=function(_0x356175){},_0x6dece1['prototype']['_removeLightSource']=function(_0x51d331,_0x4125ad){},Object['defineProperty'](_0x6dece1['prototype'],'receiveShadows',{'get':function(){return this['_sourceMesh']['receiveShadows'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x6dece1['prototype'],'material',{'get':function(){return this['_sourceMesh']['material'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x6dece1['prototype'],'visibility',{'get':function(){return this['_sourceMesh']['visibility'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x6dece1['prototype'],'skeleton',{'get':function(){return this['_sourceMesh']['skeleton'];},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](_0x6dece1['prototype'],'renderingGroupId',{'get':function(){return this['_sourceMesh']['renderingGroupId'];},'set':function(_0x98d8e5){this['_sourceMesh']&&_0x98d8e5!==this['_sourceMesh']['renderingGroupId']&&_0x5b4c82['a']['Warn']('Note\x20-\x20setting\x20renderingGroupId\x20of\x20an\x20instanced\x20mesh\x20has\x20no\x20effect\x20on\x20the\x20scene');},'enumerable':!0x1,'configurable':!0x0}),_0x6dece1['prototype']['getTotalVertices']=function(){return this['_sourceMesh']?this['_sourceMesh']['getTotalVertices']():0x0;},_0x6dece1['prototype']['getTotalIndices']=function(){return this['_sourceMesh']['getTotalIndices']();},Object['defineProperty'](_0x6dece1['prototype'],'sourceMesh',{'get':function(){return this['_sourceMesh'];},'enumerable':!0x1,'configurable':!0x0}),_0x6dece1['prototype']['createInstance']=function(_0x4b8620){return this['_sourceMesh']['createInstance'](_0x4b8620);},_0x6dece1['prototype']['isReady']=function(_0x5224b6){return void 0x0===_0x5224b6&&(_0x5224b6=!0x1),this['_sourceMesh']['isReady'](_0x5224b6,!0x0);},_0x6dece1['prototype']['getVerticesData']=function(_0x1a665d,_0x3e71a2){return this['_sourceMesh']['getVerticesData'](_0x1a665d,_0x3e71a2);},_0x6dece1['prototype']['setVerticesData']=function(_0x1c0331,_0x4f8b4b,_0x123c56,_0x37614a){return this['sourceMesh']&&this['sourceMesh']['setVerticesData'](_0x1c0331,_0x4f8b4b,_0x123c56,_0x37614a),this['sourceMesh'];},_0x6dece1['prototype']['updateVerticesData']=function(_0x3094d0,_0x1cf5d1,_0xd736a5,_0x3485d4){return this['sourceMesh']&&this['sourceMesh']['updateVerticesData'](_0x3094d0,_0x1cf5d1,_0xd736a5,_0x3485d4),this['sourceMesh'];},_0x6dece1['prototype']['setIndices']=function(_0x80d06c,_0x4f56f4){return void 0x0===_0x4f56f4&&(_0x4f56f4=null),this['sourceMesh']&&this['sourceMesh']['setIndices'](_0x80d06c,_0x4f56f4),this['sourceMesh'];},_0x6dece1['prototype']['isVerticesDataPresent']=function(_0x57eea6){return this['_sourceMesh']['isVerticesDataPresent'](_0x57eea6);},_0x6dece1['prototype']['getIndices']=function(){return this['_sourceMesh']['getIndices']();},Object['defineProperty'](_0x6dece1['prototype'],'_positions',{'get':function(){return this['_sourceMesh']['_positions'];},'enumerable':!0x1,'configurable':!0x0}),_0x6dece1['prototype']['refreshBoundingInfo']=function(_0x4e2157){if(void 0x0===_0x4e2157&&(_0x4e2157=!0x1),this['_boundingInfo']&&this['_boundingInfo']['isLocked'])return this;var _0xb5da3f=this['_sourceMesh']['geometry']?this['_sourceMesh']['geometry']['boundingBias']:null;return this['_refreshBoundingInfo'](this['_sourceMesh']['_getPositionData'](_0x4e2157),_0xb5da3f),this;},_0x6dece1['prototype']['_preActivate']=function(){return this['_currentLOD']&&this['_currentLOD']['_preActivate'](),this;},_0x6dece1['prototype']['_activate']=function(_0xafa7d0,_0x2fe6c7){if(this['_sourceMesh']['subMeshes']||_0x5b4c82['a']['Warn']('Instances\x20should\x20only\x20be\x20created\x20for\x20meshes\x20with\x20geometry.'),this['_currentLOD']){if(this['_currentLOD']['_getWorldMatrixDeterminant']()>0x0!=this['_getWorldMatrixDeterminant']()>0x0)return this['_internalAbstractMeshDataInfo']['_actAsRegularMesh']=!0x0,!0x0;if(this['_internalAbstractMeshDataInfo']['_actAsRegularMesh']=!0x1,this['_currentLOD']['_registerInstanceForRenderId'](this,_0xafa7d0),_0x2fe6c7){if(!this['_currentLOD']['_internalAbstractMeshDataInfo']['_isActiveIntermediate'])return this['_currentLOD']['_internalAbstractMeshDataInfo']['_onlyForInstancesIntermediate']=!0x0,!0x0;}else{if(!this['_currentLOD']['_internalAbstractMeshDataInfo']['_isActive'])return this['_currentLOD']['_internalAbstractMeshDataInfo']['_onlyForInstances']=!0x0,!0x0;}}return!0x1;},_0x6dece1['prototype']['_postActivate']=function(){this['_sourceMesh']['edgesShareWithInstances']&&this['_sourceMesh']['_edgesRenderer']&&this['_sourceMesh']['_edgesRenderer']['isEnabled']&&this['_sourceMesh']['_renderingGroup']?(this['_sourceMesh']['_renderingGroup']['_edgesRenderers']['pushNoDuplicate'](this['_sourceMesh']['_edgesRenderer']),this['_sourceMesh']['_edgesRenderer']['customInstances']['push'](this['getWorldMatrix']())):this['_edgesRenderer']&&this['_edgesRenderer']['isEnabled']&&this['_sourceMesh']['_renderingGroup']&&this['_sourceMesh']['_renderingGroup']['_edgesRenderers']['push'](this['_edgesRenderer']);},_0x6dece1['prototype']['getWorldMatrix']=function(){if(this['_currentLOD']&&this['_currentLOD']['billboardMode']!==_0x388e14['a']['BILLBOARDMODE_NONE']&&this['_currentLOD']['_masterMesh']!==this){var _0x480d1a=this['_currentLOD']['_masterMesh'];return this['_currentLOD']['_masterMesh']=this,_0x42ce12['c']['Vector3'][0x7]['copyFrom'](this['_currentLOD']['position']),this['_currentLOD']['position']['set'](0x0,0x0,0x0),_0x42ce12['c']['Matrix'][0x0]['copyFrom'](this['_currentLOD']['computeWorldMatrix'](!0x0)),this['_currentLOD']['position']['copyFrom'](_0x42ce12['c']['Vector3'][0x7]),this['_currentLOD']['_masterMesh']=_0x480d1a,_0x42ce12['c']['Matrix'][0x0];}return _0xdb0620['prototype']['getWorldMatrix']['call'](this);},Object['defineProperty'](_0x6dece1['prototype'],'isAnInstance',{'get':function(){return!0x0;},'enumerable':!0x1,'configurable':!0x0}),_0x6dece1['prototype']['getLOD']=function(_0x4b913c){if(!_0x4b913c)return this;var _0xa82f9=this['getBoundingInfo']();return this['_currentLOD']=this['sourceMesh']['getLOD'](_0x4b913c,_0xa82f9['boundingSphere']),this['_currentLOD']===this['sourceMesh']?this['sourceMesh']:this['_currentLOD'];},_0x6dece1['prototype']['_preActivateForIntermediateRendering']=function(_0x265bd4){return this['sourceMesh']['_preActivateForIntermediateRendering'](_0x265bd4);},_0x6dece1['prototype']['_syncSubMeshes']=function(){if(this['releaseSubMeshes'](),this['_sourceMesh']['subMeshes']){for(var _0x4bf593=0x0;_0x4bf593\x0avoid\x20main(void)\x20{\x0a#include\x0a#ifdef\x20VERTEXCOLOR\x0agl_FragColor=vColor;\x0a#else\x0agl_FragColor=color;\x0a#endif\x0a}';_0x55c7aa['a']['ShadersStore'][_0x51c6ab]=_0x59abcb;},function(_0x5ceb4a,_0x487186,_0x56b011){'use strict';var _0x446488=_0x56b011(0x5),_0x73b3d6=(_0x56b011(0x4e),_0x56b011(0x75),_0x56b011(0x4f),_0x56b011(0x50),_0x56b011(0x51),_0x56b011(0x6f),'colorVertexShader'),_0x24d9a2='\x0aattribute\x20vec3\x20position;\x0a#ifdef\x20VERTEXCOLOR\x0aattribute\x20vec4\x20color;\x0a#endif\x0a#include\x0a#include\x0a\x0a#include\x0auniform\x20mat4\x20viewProjection;\x0a#ifdef\x20MULTIVIEW\x0auniform\x20mat4\x20viewProjectionR;\x0a#endif\x0a\x0a#ifdef\x20VERTEXCOLOR\x0avarying\x20vec4\x20vColor;\x0a#endif\x0avoid\x20main(void)\x20{\x0a#include\x0a#include\x0avec4\x20worldPos=finalWorld*vec4(position,1.0);\x0a#ifdef\x20MULTIVIEW\x0aif\x20(gl_ViewID_OVR\x20==\x200u)\x20{\x0agl_Position=viewProjection*worldPos;\x0a}\x20else\x20{\x0agl_Position=viewProjectionR*worldPos;\x0a}\x0a#else\x0agl_Position=viewProjection*worldPos;\x0a#endif\x0a#include\x0a#ifdef\x20VERTEXCOLOR\x0a\x0avColor=color;\x0a#endif\x0a}';_0x446488['a']['ShadersStore'][_0x73b3d6]=_0x24d9a2;},function(_0x199fb8,_0x2159e1,_0x4d8ef2){'use strict';(function(_0x222d0e){_0x4d8ef2['d'](_0x2159e1,'b',function(){return _0x4d39de;}),_0x4d8ef2['d'](_0x2159e1,'a',function(){return _0x275c16;});var _0x5eeb7b=_0x4d8ef2(0x1),_0x56149c=_0x4d8ef2(0x8),_0x510573=_0x4d8ef2(0xd),_0x241405=_0x4d8ef2(0x66),_0x41e38b=_0x4d8ef2(0x1b),_0x49e7cf=_0x4d8ef2(0x2),_0x42bc84=_0x4d8ef2(0x59),_0x3af877=_0x4d8ef2(0x4a),_0x4d39de=function(){this['renderWidth']=0x200,this['renderHeight']=0x100,this['textureSize']=0x200,this['deterministicLockstep']=!0x1,this['lockstepMaxSteps']=0x4;},_0x275c16=function(_0x3b81ef){function _0x3b2f6c(_0x591673){void 0x0===_0x591673&&(_0x591673=new _0x4d39de());var _0x47dcc6=_0x3b81ef['call'](this,null)||this;_0x510573['a']['Instances']['push'](_0x47dcc6),void 0x0===_0x591673['deterministicLockstep']&&(_0x591673['deterministicLockstep']=!0x1),void 0x0===_0x591673['lockstepMaxSteps']&&(_0x591673['lockstepMaxSteps']=0x4),_0x47dcc6['_options']=_0x591673,_0x3af877['a']['SetMatrixPrecision'](!!_0x591673['useHighPrecisionMatrix']),_0x47dcc6['_caps']={'maxTexturesImageUnits':0x10,'maxVertexTextureImageUnits':0x10,'maxCombinedTexturesImageUnits':0x20,'maxTextureSize':0x200,'maxCubemapTextureSize':0x200,'maxRenderTextureSize':0x200,'maxVertexAttribs':0x10,'maxVaryingVectors':0x10,'maxFragmentUniformVectors':0x10,'maxVertexUniformVectors':0x10,'standardDerivatives':!0x1,'astc':null,'pvrtc':null,'etc1':null,'etc2':null,'bptc':null,'maxAnisotropy':0x0,'uintIndices':!0x1,'fragmentDepthSupported':!0x1,'highPrecisionShaderSupported':!0x0,'colorBufferFloat':!0x1,'textureFloat':!0x1,'textureFloatLinearFiltering':!0x1,'textureFloatRender':!0x1,'textureHalfFloat':!0x1,'textureHalfFloatLinearFiltering':!0x1,'textureHalfFloatRender':!0x1,'textureLOD':!0x1,'drawBuffersExtension':!0x1,'depthTextureExtension':!0x1,'vertexArrayObject':!0x1,'instancedArrays':!0x1,'canUseTimestampForTimerQuery':!0x1,'maxMSAASamples':0x1,'blendMinMax':!0x1},_0x56149c['a']['Log']('Babylon.js\x20v'+_0x510573['a']['Version']+'\x20-\x20Null\x20engine');var _0x529311='undefined'!=typeof self?self:void 0x0!==_0x222d0e?_0x222d0e:window;return'undefined'==typeof URL&&(_0x529311['URL']={'createObjectURL':function(){},'revokeObjectURL':function(){}}),'undefined'==typeof Blob&&(_0x529311['Blob']=function(){}),_0x47dcc6;}return Object(_0x5eeb7b['d'])(_0x3b2f6c,_0x3b81ef),_0x3b2f6c['prototype']['isDeterministicLockStep']=function(){return this['_options']['deterministicLockstep'];},_0x3b2f6c['prototype']['getLockstepMaxSteps']=function(){return this['_options']['lockstepMaxSteps'];},_0x3b2f6c['prototype']['getHardwareScalingLevel']=function(){return 0x1;},_0x3b2f6c['prototype']['createVertexBuffer']=function(_0x3e9bff){var _0x1dca08=new _0x42bc84['a']();return _0x1dca08['references']=0x1,_0x1dca08;},_0x3b2f6c['prototype']['createIndexBuffer']=function(_0x3f001e){var _0x202154=new _0x42bc84['a']();return _0x202154['references']=0x1,_0x202154;},_0x3b2f6c['prototype']['clear']=function(_0x584509,_0x1c55a1,_0x3f8533,_0x4ec812){void 0x0===_0x4ec812&&(_0x4ec812=!0x1);},_0x3b2f6c['prototype']['getRenderWidth']=function(_0x52fab0){return void 0x0===_0x52fab0&&(_0x52fab0=!0x1),!_0x52fab0&&this['_currentRenderTarget']?this['_currentRenderTarget']['width']:this['_options']['renderWidth'];},_0x3b2f6c['prototype']['getRenderHeight']=function(_0x10816e){return void 0x0===_0x10816e&&(_0x10816e=!0x1),!_0x10816e&&this['_currentRenderTarget']?this['_currentRenderTarget']['height']:this['_options']['renderHeight'];},_0x3b2f6c['prototype']['setViewport']=function(_0xa97d18,_0xaf2b82,_0x979f2c){this['_cachedViewport']=_0xa97d18;},_0x3b2f6c['prototype']['createShaderProgram']=function(_0x84f0f1,_0x13fc82,_0x19dc0e,_0x5802a6,_0x1dad79){return{'__SPECTOR_rebuildProgram':null};},_0x3b2f6c['prototype']['getUniforms']=function(_0x2dbb6b,_0x47ac57){return[];},_0x3b2f6c['prototype']['getAttributes']=function(_0x5d6342,_0x15a80f){return[];},_0x3b2f6c['prototype']['bindSamplers']=function(_0xa6815a){this['_currentEffect']=null;},_0x3b2f6c['prototype']['enableEffect']=function(_0x3935ba){this['_currentEffect']=_0x3935ba,_0x3935ba['onBind']&&_0x3935ba['onBind'](_0x3935ba),_0x3935ba['_onBindObservable']&&_0x3935ba['_onBindObservable']['notifyObservers'](_0x3935ba);},_0x3b2f6c['prototype']['setState']=function(_0x39821f,_0x3a2f18,_0x393738,_0x58b090){void 0x0===_0x3a2f18&&(_0x3a2f18=0x0),void 0x0===_0x58b090&&(_0x58b090=!0x1);},_0x3b2f6c['prototype']['setIntArray']=function(_0x388a41,_0x12b94c){return!0x0;},_0x3b2f6c['prototype']['setIntArray2']=function(_0x2507be,_0x528545){return!0x0;},_0x3b2f6c['prototype']['setIntArray3']=function(_0x376ae7,_0x108c2b){return!0x0;},_0x3b2f6c['prototype']['setIntArray4']=function(_0x2f354b,_0x371e4a){return!0x0;},_0x3b2f6c['prototype']['setFloatArray']=function(_0x4106f5,_0x2e3f13){return!0x0;},_0x3b2f6c['prototype']['setFloatArray2']=function(_0xa6c717,_0x343cc3){return!0x0;},_0x3b2f6c['prototype']['setFloatArray3']=function(_0x21e269,_0x319276){return!0x0;},_0x3b2f6c['prototype']['setFloatArray4']=function(_0x43508e,_0x5928c3){return!0x0;},_0x3b2f6c['prototype']['setArray']=function(_0x174884,_0x320ae4){return!0x0;},_0x3b2f6c['prototype']['setArray2']=function(_0x2451f2,_0x3ba123){return!0x0;},_0x3b2f6c['prototype']['setArray3']=function(_0x5d051f,_0x35e875){return!0x0;},_0x3b2f6c['prototype']['setArray4']=function(_0x1ae2e4,_0xa6cb20){return!0x0;},_0x3b2f6c['prototype']['setMatrices']=function(_0x590ded,_0x128234){return!0x0;},_0x3b2f6c['prototype']['setMatrix3x3']=function(_0x2c0e69,_0x429315){return!0x0;},_0x3b2f6c['prototype']['setMatrix2x2']=function(_0x3de110,_0x3a1073){return!0x0;},_0x3b2f6c['prototype']['setFloat']=function(_0x1bc670,_0x2b529a){return!0x0;},_0x3b2f6c['prototype']['setFloat2']=function(_0x1f7817,_0x4dc549,_0x19d496){return!0x0;},_0x3b2f6c['prototype']['setFloat3']=function(_0x4dd6fa,_0x1dffe0,_0x563b0f,_0x5c595e){return!0x0;},_0x3b2f6c['prototype']['setBool']=function(_0x491b16,_0x4231c4){return!0x0;},_0x3b2f6c['prototype']['setFloat4']=function(_0x5acb93,_0x4451fa,_0x5d636a,_0x27eb54,_0x29568c){return!0x0;},_0x3b2f6c['prototype']['setAlphaMode']=function(_0x17f8ef,_0x283921){void 0x0===_0x283921&&(_0x283921=!0x1),this['_alphaMode']!==_0x17f8ef&&(this['alphaState']['alphaBlend']=_0x17f8ef!==_0x49e7cf['a']['ALPHA_DISABLE'],_0x283921||this['setDepthWrite'](_0x17f8ef===_0x49e7cf['a']['ALPHA_DISABLE']),this['_alphaMode']=_0x17f8ef);},_0x3b2f6c['prototype']['bindBuffers']=function(_0x33a255,_0x58edd9,_0x3794ac){},_0x3b2f6c['prototype']['wipeCaches']=function(_0x2c0a73){this['preventCacheWipeBetweenFrames']||(this['resetTextureCache'](),this['_currentEffect']=null,_0x2c0a73&&(this['_currentProgram']=null,this['stencilState']['reset'](),this['depthCullingState']['reset'](),this['alphaState']['reset']()),this['_cachedVertexBuffers']=null,this['_cachedIndexBuffer']=null,this['_cachedEffectForVertexBuffers']=null);},_0x3b2f6c['prototype']['draw']=function(_0x5abc6d,_0x2ec19f,_0x4f59f6,_0x30dbd5){},_0x3b2f6c['prototype']['drawElementsType']=function(_0x27d364,_0x66b3d0,_0x2ad3a1,_0x342442){},_0x3b2f6c['prototype']['drawArraysType']=function(_0x2c7f0f,_0x315d54,_0x3e99a0,_0x3a8660){},_0x3b2f6c['prototype']['_createTexture']=function(){return{};},_0x3b2f6c['prototype']['_releaseTexture']=function(_0x444f57){},_0x3b2f6c['prototype']['createTexture']=function(_0x152f89,_0x2f8ef2,_0x56eaa1,_0x541ab9,_0x3eeb79,_0x4138cf,_0x52b25c,_0x2eda1f,_0x2a59e9,_0x12dc26,_0x21189d,_0x1286d7){void 0x0===_0x3eeb79&&(_0x3eeb79=_0x49e7cf['a']['TEXTURE_TRILINEAR_SAMPLINGMODE']),void 0x0===_0x4138cf&&(_0x4138cf=null),void 0x0===_0x52b25c&&(_0x52b25c=null),void 0x0===_0x2eda1f&&(_0x2eda1f=null),void 0x0===_0x2a59e9&&(_0x2a59e9=null),void 0x0===_0x12dc26&&(_0x12dc26=null),void 0x0===_0x21189d&&(_0x21189d=null);var _0xe373f3=new _0x41e38b['a'](this,_0x41e38b['b']['Url']),_0x4bbd1f=String(_0x152f89);return _0xe373f3['url']=_0x4bbd1f,_0xe373f3['generateMipMaps']=!_0x2f8ef2,_0xe373f3['samplingMode']=_0x3eeb79,_0xe373f3['invertY']=_0x56eaa1,_0xe373f3['baseWidth']=this['_options']['textureSize'],_0xe373f3['baseHeight']=this['_options']['textureSize'],_0xe373f3['width']=this['_options']['textureSize'],_0xe373f3['height']=this['_options']['textureSize'],_0x12dc26&&(_0xe373f3['format']=_0x12dc26),_0xe373f3['isReady']=!0x0,_0x4138cf&&_0x4138cf(),this['_internalTexturesCache']['push'](_0xe373f3),_0xe373f3;},_0x3b2f6c['prototype']['createRenderTargetTexture']=function(_0x586a92,_0x101aeb){var _0x407fc0=new _0x241405['a']();void 0x0!==_0x101aeb&&'object'==typeof _0x101aeb?(_0x407fc0['generateMipMaps']=_0x101aeb['generateMipMaps'],_0x407fc0['generateDepthBuffer']=void 0x0===_0x101aeb['generateDepthBuffer']||_0x101aeb['generateDepthBuffer'],_0x407fc0['generateStencilBuffer']=_0x407fc0['generateDepthBuffer']&&_0x101aeb['generateStencilBuffer'],_0x407fc0['type']=void 0x0===_0x101aeb['type']?_0x49e7cf['a']['TEXTURETYPE_UNSIGNED_INT']:_0x101aeb['type'],_0x407fc0['samplingMode']=void 0x0===_0x101aeb['samplingMode']?_0x49e7cf['a']['TEXTURE_TRILINEAR_SAMPLINGMODE']:_0x101aeb['samplingMode']):(_0x407fc0['generateMipMaps']=_0x101aeb,_0x407fc0['generateDepthBuffer']=!0x0,_0x407fc0['generateStencilBuffer']=!0x1,_0x407fc0['type']=_0x49e7cf['a']['TEXTURETYPE_UNSIGNED_INT'],_0x407fc0['samplingMode']=_0x49e7cf['a']['TEXTURE_TRILINEAR_SAMPLINGMODE']);var _0xdea345=new _0x41e38b['a'](this,_0x41e38b['b']['RenderTarget']),_0x1ea6dc=_0x586a92['width']||_0x586a92,_0xed2fb4=_0x586a92['height']||_0x586a92;return _0xdea345['_depthStencilBuffer']={},_0xdea345['_framebuffer']={},_0xdea345['baseWidth']=_0x1ea6dc,_0xdea345['baseHeight']=_0xed2fb4,_0xdea345['width']=_0x1ea6dc,_0xdea345['height']=_0xed2fb4,_0xdea345['isReady']=!0x0,_0xdea345['samples']=0x1,_0xdea345['generateMipMaps']=!!_0x407fc0['generateMipMaps'],_0xdea345['samplingMode']=_0x407fc0['samplingMode'],_0xdea345['type']=_0x407fc0['type'],_0xdea345['_generateDepthBuffer']=_0x407fc0['generateDepthBuffer'],_0xdea345['_generateStencilBuffer']=!!_0x407fc0['generateStencilBuffer'],this['_internalTexturesCache']['push'](_0xdea345),_0xdea345;},_0x3b2f6c['prototype']['updateTextureSamplingMode']=function(_0x3b47ab,_0x4208aa){_0x4208aa['samplingMode']=_0x3b47ab;},_0x3b2f6c['prototype']['bindFramebuffer']=function(_0x30dba4,_0x192f4b,_0x337899,_0x23bc93,_0xff893f){this['_currentRenderTarget']&&this['unBindFramebuffer'](this['_currentRenderTarget']),this['_currentRenderTarget']=_0x30dba4,this['_currentFramebuffer']=_0x30dba4['_MSAAFramebuffer']?_0x30dba4['_MSAAFramebuffer']:_0x30dba4['_framebuffer'],this['_cachedViewport']&&!_0xff893f&&this['setViewport'](this['_cachedViewport'],_0x337899,_0x23bc93);},_0x3b2f6c['prototype']['unBindFramebuffer']=function(_0x308c12,_0xa0ea02,_0x3510f9){void 0x0===_0xa0ea02&&(_0xa0ea02=!0x1),this['_currentRenderTarget']=null,_0x3510f9&&(_0x308c12['_MSAAFramebuffer']&&(this['_currentFramebuffer']=_0x308c12['_framebuffer']),_0x3510f9()),this['_currentFramebuffer']=null;},_0x3b2f6c['prototype']['createDynamicVertexBuffer']=function(_0x1c66f6){var _0xd9ce9d=new _0x42bc84['a']();return _0xd9ce9d['references']=0x1,_0xd9ce9d['capacity']=0x1,_0xd9ce9d;},_0x3b2f6c['prototype']['updateDynamicTexture']=function(_0x33f956,_0x59e37e,_0x5c80f1,_0x1aa403,_0x2c99dd){void 0x0===_0x1aa403&&(_0x1aa403=!0x1);},_0x3b2f6c['prototype']['areAllEffectsReady']=function(){return!0x0;},_0x3b2f6c['prototype']['getError']=function(){return 0x0;},_0x3b2f6c['prototype']['_getUnpackAlignement']=function(){return 0x1;},_0x3b2f6c['prototype']['_unpackFlipY']=function(_0x5233ee){},_0x3b2f6c['prototype']['updateDynamicIndexBuffer']=function(_0x5e417e,_0x21a7e8,_0x8cac71){void 0x0===_0x8cac71&&(_0x8cac71=0x0);},_0x3b2f6c['prototype']['updateDynamicVertexBuffer']=function(_0xbfceb5,_0x267379,_0x2483d6,_0x45d3f5){},_0x3b2f6c['prototype']['_bindTextureDirectly']=function(_0x4296bc,_0x1e37f5){return this['_boundTexturesCache'][this['_activeChannel']]!==_0x1e37f5&&(this['_boundTexturesCache'][this['_activeChannel']]=_0x1e37f5,!0x0);},_0x3b2f6c['prototype']['_bindTexture']=function(_0x537a60,_0x1d1abf){_0x537a60<0x0||this['_bindTextureDirectly'](0x0,_0x1d1abf);},_0x3b2f6c['prototype']['_deleteBuffer']=function(_0x25f0d7){},_0x3b2f6c['prototype']['releaseEffects']=function(){},_0x3b2f6c['prototype']['displayLoadingUI']=function(){},_0x3b2f6c['prototype']['hideLoadingUI']=function(){},_0x3b2f6c['prototype']['_uploadCompressedDataToTextureDirectly']=function(_0x47d0ba,_0x58c6f7,_0x3d7433,_0x135848,_0x8cb30b,_0x1a25bc,_0x259e94){void 0x0===_0x1a25bc&&(_0x1a25bc=0x0),void 0x0===_0x259e94&&(_0x259e94=0x0);},_0x3b2f6c['prototype']['_uploadDataToTextureDirectly']=function(_0x2257a5,_0x36650e,_0x3d22fc,_0x24a6dc){void 0x0===_0x3d22fc&&(_0x3d22fc=0x0),void 0x0===_0x24a6dc&&(_0x24a6dc=0x0);},_0x3b2f6c['prototype']['_uploadArrayBufferViewToTexture']=function(_0x48229d,_0x44fa65,_0x148afe,_0x74c749){void 0x0===_0x148afe&&(_0x148afe=0x0),void 0x0===_0x74c749&&(_0x74c749=0x0);},_0x3b2f6c['prototype']['_uploadImageToTexture']=function(_0x3f512d,_0x4b69ec,_0xed9d97,_0x6b4d1a){void 0x0===_0xed9d97&&(_0xed9d97=0x0),void 0x0===_0x6b4d1a&&(_0x6b4d1a=0x0);},_0x3b2f6c;}(_0x510573['a']);}['call'](this,_0x4d8ef2(0x9f)));},function(_0x154dc1,_0x509795,_0x1f6b4b){'use strict';_0x1f6b4b['r'](_0x509795),function(_0x3af596){_0x1f6b4b['d'](_0x509795,'Debug',function(){return _0x517d4c;});var _0xc9859e=_0x1f6b4b(0x7f),_0xcc9dd0=_0x1f6b4b(0x63);_0x1f6b4b['d'](_0x509795,'AbstractScene',function(){return _0xc9859e['AbstractScene'];}),_0x1f6b4b['d'](_0x509795,'AbstractActionManager',function(){return _0xc9859e['AbstractActionManager'];}),_0x1f6b4b['d'](_0x509795,'Action',function(){return _0xc9859e['Action'];}),_0x1f6b4b['d'](_0x509795,'ActionEvent',function(){return _0xc9859e['ActionEvent'];}),_0x1f6b4b['d'](_0x509795,'ActionManager',function(){return _0xc9859e['ActionManager'];}),_0x1f6b4b['d'](_0x509795,'Condition',function(){return _0xc9859e['Condition'];}),_0x1f6b4b['d'](_0x509795,'ValueCondition',function(){return _0xc9859e['ValueCondition'];}),_0x1f6b4b['d'](_0x509795,'PredicateCondition',function(){return _0xc9859e['PredicateCondition'];}),_0x1f6b4b['d'](_0x509795,'StateCondition',function(){return _0xc9859e['StateCondition'];}),_0x1f6b4b['d'](_0x509795,'SwitchBooleanAction',function(){return _0xc9859e['SwitchBooleanAction'];}),_0x1f6b4b['d'](_0x509795,'SetStateAction',function(){return _0xc9859e['SetStateAction'];}),_0x1f6b4b['d'](_0x509795,'SetValueAction',function(){return _0xc9859e['SetValueAction'];}),_0x1f6b4b['d'](_0x509795,'IncrementValueAction',function(){return _0xc9859e['IncrementValueAction'];}),_0x1f6b4b['d'](_0x509795,'PlayAnimationAction',function(){return _0xc9859e['PlayAnimationAction'];}),_0x1f6b4b['d'](_0x509795,'StopAnimationAction',function(){return _0xc9859e['StopAnimationAction'];}),_0x1f6b4b['d'](_0x509795,'DoNothingAction',function(){return _0xc9859e['DoNothingAction'];}),_0x1f6b4b['d'](_0x509795,'CombineAction',function(){return _0xc9859e['CombineAction'];}),_0x1f6b4b['d'](_0x509795,'ExecuteCodeAction',function(){return _0xc9859e['ExecuteCodeAction'];}),_0x1f6b4b['d'](_0x509795,'SetParentAction',function(){return _0xc9859e['SetParentAction'];}),_0x1f6b4b['d'](_0x509795,'PlaySoundAction',function(){return _0xc9859e['PlaySoundAction'];}),_0x1f6b4b['d'](_0x509795,'StopSoundAction',function(){return _0xc9859e['StopSoundAction'];}),_0x1f6b4b['d'](_0x509795,'InterpolateValueAction',function(){return _0xc9859e['InterpolateValueAction'];}),_0x1f6b4b['d'](_0x509795,'Animatable',function(){return _0xc9859e['Animatable'];}),_0x1f6b4b['d'](_0x509795,'_IAnimationState',function(){return _0xc9859e['_IAnimationState'];}),_0x1f6b4b['d'](_0x509795,'Animation',function(){return _0xc9859e['Animation'];}),_0x1f6b4b['d'](_0x509795,'TargetedAnimation',function(){return _0xc9859e['TargetedAnimation'];}),_0x1f6b4b['d'](_0x509795,'AnimationGroup',function(){return _0xc9859e['AnimationGroup'];}),_0x1f6b4b['d'](_0x509795,'AnimationPropertiesOverride',function(){return _0xc9859e['AnimationPropertiesOverride'];}),_0x1f6b4b['d'](_0x509795,'EasingFunction',function(){return _0xc9859e['EasingFunction'];}),_0x1f6b4b['d'](_0x509795,'CircleEase',function(){return _0xc9859e['CircleEase'];}),_0x1f6b4b['d'](_0x509795,'BackEase',function(){return _0xc9859e['BackEase'];}),_0x1f6b4b['d'](_0x509795,'BounceEase',function(){return _0xc9859e['BounceEase'];}),_0x1f6b4b['d'](_0x509795,'CubicEase',function(){return _0xc9859e['CubicEase'];}),_0x1f6b4b['d'](_0x509795,'ElasticEase',function(){return _0xc9859e['ElasticEase'];}),_0x1f6b4b['d'](_0x509795,'ExponentialEase',function(){return _0xc9859e['ExponentialEase'];}),_0x1f6b4b['d'](_0x509795,'PowerEase',function(){return _0xc9859e['PowerEase'];}),_0x1f6b4b['d'](_0x509795,'QuadraticEase',function(){return _0xc9859e['QuadraticEase'];}),_0x1f6b4b['d'](_0x509795,'QuarticEase',function(){return _0xc9859e['QuarticEase'];}),_0x1f6b4b['d'](_0x509795,'QuinticEase',function(){return _0xc9859e['QuinticEase'];}),_0x1f6b4b['d'](_0x509795,'SineEase',function(){return _0xc9859e['SineEase'];}),_0x1f6b4b['d'](_0x509795,'BezierCurveEase',function(){return _0xc9859e['BezierCurveEase'];}),_0x1f6b4b['d'](_0x509795,'RuntimeAnimation',function(){return _0xc9859e['RuntimeAnimation'];}),_0x1f6b4b['d'](_0x509795,'AnimationEvent',function(){return _0xc9859e['AnimationEvent'];}),_0x1f6b4b['d'](_0x509795,'AnimationKeyInterpolation',function(){return _0xc9859e['AnimationKeyInterpolation'];}),_0x1f6b4b['d'](_0x509795,'AnimationRange',function(){return _0xc9859e['AnimationRange'];}),_0x1f6b4b['d'](_0x509795,'KeepAssets',function(){return _0xc9859e['KeepAssets'];}),_0x1f6b4b['d'](_0x509795,'InstantiatedEntries',function(){return _0xc9859e['InstantiatedEntries'];}),_0x1f6b4b['d'](_0x509795,'AssetContainer',function(){return _0xc9859e['AssetContainer'];}),_0x1f6b4b['d'](_0x509795,'Analyser',function(){return _0xc9859e['Analyser'];}),_0x1f6b4b['d'](_0x509795,'AudioEngine',function(){return _0xc9859e['AudioEngine'];}),_0x1f6b4b['d'](_0x509795,'AudioSceneComponent',function(){return _0xc9859e['AudioSceneComponent'];}),_0x1f6b4b['d'](_0x509795,'Sound',function(){return _0xc9859e['Sound'];}),_0x1f6b4b['d'](_0x509795,'SoundTrack',function(){return _0xc9859e['SoundTrack'];}),_0x1f6b4b['d'](_0x509795,'WeightedSound',function(){return _0xc9859e['WeightedSound'];}),_0x1f6b4b['d'](_0x509795,'AutoRotationBehavior',function(){return _0xc9859e['AutoRotationBehavior'];}),_0x1f6b4b['d'](_0x509795,'BouncingBehavior',function(){return _0xc9859e['BouncingBehavior'];}),_0x1f6b4b['d'](_0x509795,'FramingBehavior',function(){return _0xc9859e['FramingBehavior'];}),_0x1f6b4b['d'](_0x509795,'AttachToBoxBehavior',function(){return _0xc9859e['AttachToBoxBehavior'];}),_0x1f6b4b['d'](_0x509795,'FadeInOutBehavior',function(){return _0xc9859e['FadeInOutBehavior'];}),_0x1f6b4b['d'](_0x509795,'MultiPointerScaleBehavior',function(){return _0xc9859e['MultiPointerScaleBehavior'];}),_0x1f6b4b['d'](_0x509795,'PointerDragBehavior',function(){return _0xc9859e['PointerDragBehavior'];}),_0x1f6b4b['d'](_0x509795,'SixDofDragBehavior',function(){return _0xc9859e['SixDofDragBehavior'];}),_0x1f6b4b['d'](_0x509795,'Bone',function(){return _0xc9859e['Bone'];}),_0x1f6b4b['d'](_0x509795,'BoneIKController',function(){return _0xc9859e['BoneIKController'];}),_0x1f6b4b['d'](_0x509795,'BoneLookController',function(){return _0xc9859e['BoneLookController'];}),_0x1f6b4b['d'](_0x509795,'Skeleton',function(){return _0xc9859e['Skeleton'];}),_0x1f6b4b['d'](_0x509795,'ArcRotateCameraGamepadInput',function(){return _0xc9859e['ArcRotateCameraGamepadInput'];}),_0x1f6b4b['d'](_0x509795,'ArcRotateCameraKeyboardMoveInput',function(){return _0xc9859e['ArcRotateCameraKeyboardMoveInput'];}),_0x1f6b4b['d'](_0x509795,'ArcRotateCameraMouseWheelInput',function(){return _0xc9859e['ArcRotateCameraMouseWheelInput'];}),_0x1f6b4b['d'](_0x509795,'ArcRotateCameraPointersInput',function(){return _0xc9859e['ArcRotateCameraPointersInput'];}),_0x1f6b4b['d'](_0x509795,'ArcRotateCameraVRDeviceOrientationInput',function(){return _0xc9859e['ArcRotateCameraVRDeviceOrientationInput'];}),_0x1f6b4b['d'](_0x509795,'FlyCameraKeyboardInput',function(){return _0xc9859e['FlyCameraKeyboardInput'];}),_0x1f6b4b['d'](_0x509795,'FlyCameraMouseInput',function(){return _0xc9859e['FlyCameraMouseInput'];}),_0x1f6b4b['d'](_0x509795,'FollowCameraKeyboardMoveInput',function(){return _0xc9859e['FollowCameraKeyboardMoveInput'];}),_0x1f6b4b['d'](_0x509795,'FollowCameraMouseWheelInput',function(){return _0xc9859e['FollowCameraMouseWheelInput'];}),_0x1f6b4b['d'](_0x509795,'FollowCameraPointersInput',function(){return _0xc9859e['FollowCameraPointersInput'];}),_0x1f6b4b['d'](_0x509795,'FreeCameraDeviceOrientationInput',function(){return _0xc9859e['FreeCameraDeviceOrientationInput'];}),_0x1f6b4b['d'](_0x509795,'FreeCameraGamepadInput',function(){return _0xc9859e['FreeCameraGamepadInput'];}),_0x1f6b4b['d'](_0x509795,'FreeCameraKeyboardMoveInput',function(){return _0xc9859e['FreeCameraKeyboardMoveInput'];}),_0x1f6b4b['d'](_0x509795,'FreeCameraMouseInput',function(){return _0xc9859e['FreeCameraMouseInput'];}),_0x1f6b4b['d'](_0x509795,'FreeCameraMouseWheelInput',function(){return _0xc9859e['FreeCameraMouseWheelInput'];}),_0x1f6b4b['d'](_0x509795,'FreeCameraTouchInput',function(){return _0xc9859e['FreeCameraTouchInput'];}),_0x1f6b4b['d'](_0x509795,'FreeCameraVirtualJoystickInput',function(){return _0xc9859e['FreeCameraVirtualJoystickInput'];}),_0x1f6b4b['d'](_0x509795,'CameraInputTypes',function(){return _0xc9859e['CameraInputTypes'];}),_0x1f6b4b['d'](_0x509795,'CameraInputsManager',function(){return _0xc9859e['CameraInputsManager'];}),_0x1f6b4b['d'](_0x509795,'Camera',function(){return _0xc9859e['Camera'];}),_0x1f6b4b['d'](_0x509795,'TargetCamera',function(){return _0xc9859e['TargetCamera'];}),_0x1f6b4b['d'](_0x509795,'FreeCamera',function(){return _0xc9859e['FreeCamera'];}),_0x1f6b4b['d'](_0x509795,'FreeCameraInputsManager',function(){return _0xc9859e['FreeCameraInputsManager'];}),_0x1f6b4b['d'](_0x509795,'TouchCamera',function(){return _0xc9859e['TouchCamera'];}),_0x1f6b4b['d'](_0x509795,'ArcRotateCamera',function(){return _0xc9859e['ArcRotateCamera'];}),_0x1f6b4b['d'](_0x509795,'ArcRotateCameraInputsManager',function(){return _0xc9859e['ArcRotateCameraInputsManager'];}),_0x1f6b4b['d'](_0x509795,'DeviceOrientationCamera',function(){return _0xc9859e['DeviceOrientationCamera'];}),_0x1f6b4b['d'](_0x509795,'FlyCamera',function(){return _0xc9859e['FlyCamera'];}),_0x1f6b4b['d'](_0x509795,'FlyCameraInputsManager',function(){return _0xc9859e['FlyCameraInputsManager'];}),_0x1f6b4b['d'](_0x509795,'FollowCamera',function(){return _0xc9859e['FollowCamera'];}),_0x1f6b4b['d'](_0x509795,'ArcFollowCamera',function(){return _0xc9859e['ArcFollowCamera'];}),_0x1f6b4b['d'](_0x509795,'FollowCameraInputsManager',function(){return _0xc9859e['FollowCameraInputsManager'];}),_0x1f6b4b['d'](_0x509795,'GamepadCamera',function(){return _0xc9859e['GamepadCamera'];}),_0x1f6b4b['d'](_0x509795,'AnaglyphArcRotateCamera',function(){return _0xc9859e['AnaglyphArcRotateCamera'];}),_0x1f6b4b['d'](_0x509795,'AnaglyphFreeCamera',function(){return _0xc9859e['AnaglyphFreeCamera'];}),_0x1f6b4b['d'](_0x509795,'AnaglyphGamepadCamera',function(){return _0xc9859e['AnaglyphGamepadCamera'];}),_0x1f6b4b['d'](_0x509795,'AnaglyphUniversalCamera',function(){return _0xc9859e['AnaglyphUniversalCamera'];}),_0x1f6b4b['d'](_0x509795,'StereoscopicArcRotateCamera',function(){return _0xc9859e['StereoscopicArcRotateCamera'];}),_0x1f6b4b['d'](_0x509795,'StereoscopicFreeCamera',function(){return _0xc9859e['StereoscopicFreeCamera'];}),_0x1f6b4b['d'](_0x509795,'StereoscopicGamepadCamera',function(){return _0xc9859e['StereoscopicGamepadCamera'];}),_0x1f6b4b['d'](_0x509795,'StereoscopicUniversalCamera',function(){return _0xc9859e['StereoscopicUniversalCamera'];}),_0x1f6b4b['d'](_0x509795,'UniversalCamera',function(){return _0xc9859e['UniversalCamera'];}),_0x1f6b4b['d'](_0x509795,'VirtualJoysticksCamera',function(){return _0xc9859e['VirtualJoysticksCamera'];}),_0x1f6b4b['d'](_0x509795,'VRCameraMetrics',function(){return _0xc9859e['VRCameraMetrics'];}),_0x1f6b4b['d'](_0x509795,'VRDeviceOrientationArcRotateCamera',function(){return _0xc9859e['VRDeviceOrientationArcRotateCamera'];}),_0x1f6b4b['d'](_0x509795,'VRDeviceOrientationFreeCamera',function(){return _0xc9859e['VRDeviceOrientationFreeCamera'];}),_0x1f6b4b['d'](_0x509795,'VRDeviceOrientationGamepadCamera',function(){return _0xc9859e['VRDeviceOrientationGamepadCamera'];}),_0x1f6b4b['d'](_0x509795,'OnAfterEnteringVRObservableEvent',function(){return _0xc9859e['OnAfterEnteringVRObservableEvent'];}),_0x1f6b4b['d'](_0x509795,'VRExperienceHelper',function(){return _0xc9859e['VRExperienceHelper'];}),_0x1f6b4b['d'](_0x509795,'WebVRFreeCamera',function(){return _0xc9859e['WebVRFreeCamera'];}),_0x1f6b4b['d'](_0x509795,'Collider',function(){return _0xc9859e['Collider'];}),_0x1f6b4b['d'](_0x509795,'DefaultCollisionCoordinator',function(){return _0xc9859e['DefaultCollisionCoordinator'];}),_0x1f6b4b['d'](_0x509795,'PickingInfo',function(){return _0xc9859e['PickingInfo'];}),_0x1f6b4b['d'](_0x509795,'IntersectionInfo',function(){return _0xc9859e['IntersectionInfo'];}),_0x1f6b4b['d'](_0x509795,'_MeshCollisionData',function(){return _0xc9859e['_MeshCollisionData'];}),_0x1f6b4b['d'](_0x509795,'BoundingBox',function(){return _0xc9859e['BoundingBox'];}),_0x1f6b4b['d'](_0x509795,'BoundingInfo',function(){return _0xc9859e['BoundingInfo'];}),_0x1f6b4b['d'](_0x509795,'BoundingSphere',function(){return _0xc9859e['BoundingSphere'];}),_0x1f6b4b['d'](_0x509795,'Octree',function(){return _0xc9859e['Octree'];}),_0x1f6b4b['d'](_0x509795,'OctreeBlock',function(){return _0xc9859e['OctreeBlock'];}),_0x1f6b4b['d'](_0x509795,'OctreeSceneComponent',function(){return _0xc9859e['OctreeSceneComponent'];}),_0x1f6b4b['d'](_0x509795,'Ray',function(){return _0xc9859e['Ray'];}),_0x1f6b4b['d'](_0x509795,'AxesViewer',function(){return _0xc9859e['AxesViewer'];}),_0x1f6b4b['d'](_0x509795,'BoneAxesViewer',function(){return _0xc9859e['BoneAxesViewer'];}),_0x1f6b4b['d'](_0x509795,'DebugLayerTab',function(){return _0xc9859e['DebugLayerTab'];}),_0x1f6b4b['d'](_0x509795,'DebugLayer',function(){return _0xc9859e['DebugLayer'];}),_0x1f6b4b['d'](_0x509795,'PhysicsViewer',function(){return _0xc9859e['PhysicsViewer'];}),_0x1f6b4b['d'](_0x509795,'RayHelper',function(){return _0xc9859e['RayHelper'];}),_0x1f6b4b['d'](_0x509795,'SkeletonViewer',function(){return _0xc9859e['SkeletonViewer'];}),_0x1f6b4b['d'](_0x509795,'DeviceInputSystem',function(){return _0xc9859e['DeviceInputSystem'];}),_0x1f6b4b['d'](_0x509795,'DeviceType',function(){return _0xc9859e['DeviceType'];}),_0x1f6b4b['d'](_0x509795,'PointerInput',function(){return _0xc9859e['PointerInput'];}),_0x1f6b4b['d'](_0x509795,'DualShockInput',function(){return _0xc9859e['DualShockInput'];}),_0x1f6b4b['d'](_0x509795,'XboxInput',function(){return _0xc9859e['XboxInput'];}),_0x1f6b4b['d'](_0x509795,'SwitchInput',function(){return _0xc9859e['SwitchInput'];}),_0x1f6b4b['d'](_0x509795,'DeviceSource',function(){return _0xc9859e['DeviceSource'];}),_0x1f6b4b['d'](_0x509795,'DeviceSourceManager',function(){return _0xc9859e['DeviceSourceManager'];}),_0x1f6b4b['d'](_0x509795,'Constants',function(){return _0xc9859e['Constants'];}),_0x1f6b4b['d'](_0x509795,'ThinEngine',function(){return _0xc9859e['ThinEngine'];}),_0x1f6b4b['d'](_0x509795,'Engine',function(){return _0xc9859e['Engine'];}),_0x1f6b4b['d'](_0x509795,'EngineStore',function(){return _0xc9859e['EngineStore'];}),_0x1f6b4b['d'](_0x509795,'NullEngineOptions',function(){return _0xc9859e['NullEngineOptions'];}),_0x1f6b4b['d'](_0x509795,'NullEngine',function(){return _0xc9859e['NullEngine'];}),_0x1f6b4b['d'](_0x509795,'_OcclusionDataStorage',function(){return _0xc9859e['_OcclusionDataStorage'];}),_0x1f6b4b['d'](_0x509795,'_forceTransformFeedbackToBundle',function(){return _0xc9859e['_forceTransformFeedbackToBundle'];}),_0x1f6b4b['d'](_0x509795,'EngineView',function(){return _0xc9859e['EngineView'];}),_0x1f6b4b['d'](_0x509795,'WebGLPipelineContext',function(){return _0xc9859e['WebGLPipelineContext'];}),_0x1f6b4b['d'](_0x509795,'WebGL2ShaderProcessor',function(){return _0xc9859e['WebGL2ShaderProcessor'];}),_0x1f6b4b['d'](_0x509795,'NativeEngine',function(){return _0xc9859e['NativeEngine'];}),_0x1f6b4b['d'](_0x509795,'ShaderCodeInliner',function(){return _0xc9859e['ShaderCodeInliner'];}),_0x1f6b4b['d'](_0x509795,'PerformanceConfigurator',function(){return _0xc9859e['PerformanceConfigurator'];}),_0x1f6b4b['d'](_0x509795,'KeyboardEventTypes',function(){return _0xc9859e['KeyboardEventTypes'];}),_0x1f6b4b['d'](_0x509795,'KeyboardInfo',function(){return _0xc9859e['KeyboardInfo'];}),_0x1f6b4b['d'](_0x509795,'KeyboardInfoPre',function(){return _0xc9859e['KeyboardInfoPre'];}),_0x1f6b4b['d'](_0x509795,'PointerEventTypes',function(){return _0xc9859e['PointerEventTypes'];}),_0x1f6b4b['d'](_0x509795,'PointerInfoBase',function(){return _0xc9859e['PointerInfoBase'];}),_0x1f6b4b['d'](_0x509795,'PointerInfoPre',function(){return _0xc9859e['PointerInfoPre'];}),_0x1f6b4b['d'](_0x509795,'PointerInfo',function(){return _0xc9859e['PointerInfo'];}),_0x1f6b4b['d'](_0x509795,'ClipboardEventTypes',function(){return _0xc9859e['ClipboardEventTypes'];}),_0x1f6b4b['d'](_0x509795,'ClipboardInfo',function(){return _0xc9859e['ClipboardInfo'];}),_0x1f6b4b['d'](_0x509795,'DaydreamController',function(){return _0xc9859e['DaydreamController'];}),_0x1f6b4b['d'](_0x509795,'GearVRController',function(){return _0xc9859e['GearVRController'];}),_0x1f6b4b['d'](_0x509795,'GenericController',function(){return _0xc9859e['GenericController'];}),_0x1f6b4b['d'](_0x509795,'OculusTouchController',function(){return _0xc9859e['OculusTouchController'];}),_0x1f6b4b['d'](_0x509795,'PoseEnabledControllerType',function(){return _0xc9859e['PoseEnabledControllerType'];}),_0x1f6b4b['d'](_0x509795,'PoseEnabledControllerHelper',function(){return _0xc9859e['PoseEnabledControllerHelper'];}),_0x1f6b4b['d'](_0x509795,'PoseEnabledController',function(){return _0xc9859e['PoseEnabledController'];}),_0x1f6b4b['d'](_0x509795,'ViveController',function(){return _0xc9859e['ViveController'];}),_0x1f6b4b['d'](_0x509795,'WebVRController',function(){return _0xc9859e['WebVRController'];}),_0x1f6b4b['d'](_0x509795,'WindowsMotionController',function(){return _0xc9859e['WindowsMotionController'];}),_0x1f6b4b['d'](_0x509795,'XRWindowsMotionController',function(){return _0xc9859e['XRWindowsMotionController'];}),_0x1f6b4b['d'](_0x509795,'StickValues',function(){return _0xc9859e['StickValues'];}),_0x1f6b4b['d'](_0x509795,'Gamepad',function(){return _0xc9859e['Gamepad'];}),_0x1f6b4b['d'](_0x509795,'GenericPad',function(){return _0xc9859e['GenericPad'];}),_0x1f6b4b['d'](_0x509795,'GamepadManager',function(){return _0xc9859e['GamepadManager'];}),_0x1f6b4b['d'](_0x509795,'GamepadSystemSceneComponent',function(){return _0xc9859e['GamepadSystemSceneComponent'];}),_0x1f6b4b['d'](_0x509795,'Xbox360Button',function(){return _0xc9859e['Xbox360Button'];}),_0x1f6b4b['d'](_0x509795,'Xbox360Dpad',function(){return _0xc9859e['Xbox360Dpad'];}),_0x1f6b4b['d'](_0x509795,'Xbox360Pad',function(){return _0xc9859e['Xbox360Pad'];}),_0x1f6b4b['d'](_0x509795,'DualShockButton',function(){return _0xc9859e['DualShockButton'];}),_0x1f6b4b['d'](_0x509795,'DualShockDpad',function(){return _0xc9859e['DualShockDpad'];}),_0x1f6b4b['d'](_0x509795,'DualShockPad',function(){return _0xc9859e['DualShockPad'];}),_0x1f6b4b['d'](_0x509795,'AxisDragGizmo',function(){return _0xc9859e['AxisDragGizmo'];}),_0x1f6b4b['d'](_0x509795,'AxisScaleGizmo',function(){return _0xc9859e['AxisScaleGizmo'];}),_0x1f6b4b['d'](_0x509795,'BoundingBoxGizmo',function(){return _0xc9859e['BoundingBoxGizmo'];}),_0x1f6b4b['d'](_0x509795,'Gizmo',function(){return _0xc9859e['Gizmo'];}),_0x1f6b4b['d'](_0x509795,'GizmoManager',function(){return _0xc9859e['GizmoManager'];}),_0x1f6b4b['d'](_0x509795,'PlaneRotationGizmo',function(){return _0xc9859e['PlaneRotationGizmo'];}),_0x1f6b4b['d'](_0x509795,'PositionGizmo',function(){return _0xc9859e['PositionGizmo'];}),_0x1f6b4b['d'](_0x509795,'RotationGizmo',function(){return _0xc9859e['RotationGizmo'];}),_0x1f6b4b['d'](_0x509795,'ScaleGizmo',function(){return _0xc9859e['ScaleGizmo'];}),_0x1f6b4b['d'](_0x509795,'LightGizmo',function(){return _0xc9859e['LightGizmo'];}),_0x1f6b4b['d'](_0x509795,'CameraGizmo',function(){return _0xc9859e['CameraGizmo'];}),_0x1f6b4b['d'](_0x509795,'PlaneDragGizmo',function(){return _0xc9859e['PlaneDragGizmo'];}),_0x1f6b4b['d'](_0x509795,'EnvironmentHelper',function(){return _0xc9859e['EnvironmentHelper'];}),_0x1f6b4b['d'](_0x509795,'PhotoDome',function(){return _0xc9859e['PhotoDome'];}),_0x1f6b4b['d'](_0x509795,'_forceSceneHelpersToBundle',function(){return _0xc9859e['_forceSceneHelpersToBundle'];}),_0x1f6b4b['d'](_0x509795,'VideoDome',function(){return _0xc9859e['VideoDome'];}),_0x1f6b4b['d'](_0x509795,'EngineInstrumentation',function(){return _0xc9859e['EngineInstrumentation'];}),_0x1f6b4b['d'](_0x509795,'SceneInstrumentation',function(){return _0xc9859e['SceneInstrumentation'];}),_0x1f6b4b['d'](_0x509795,'_TimeToken',function(){return _0xc9859e['_TimeToken'];}),_0x1f6b4b['d'](_0x509795,'EffectLayer',function(){return _0xc9859e['EffectLayer'];}),_0x1f6b4b['d'](_0x509795,'EffectLayerSceneComponent',function(){return _0xc9859e['EffectLayerSceneComponent'];}),_0x1f6b4b['d'](_0x509795,'GlowLayer',function(){return _0xc9859e['GlowLayer'];}),_0x1f6b4b['d'](_0x509795,'HighlightLayer',function(){return _0xc9859e['HighlightLayer'];}),_0x1f6b4b['d'](_0x509795,'Layer',function(){return _0xc9859e['Layer'];}),_0x1f6b4b['d'](_0x509795,'LayerSceneComponent',function(){return _0xc9859e['LayerSceneComponent'];}),_0x1f6b4b['d'](_0x509795,'LensFlare',function(){return _0xc9859e['LensFlare'];}),_0x1f6b4b['d'](_0x509795,'LensFlareSystem',function(){return _0xc9859e['LensFlareSystem'];}),_0x1f6b4b['d'](_0x509795,'LensFlareSystemSceneComponent',function(){return _0xc9859e['LensFlareSystemSceneComponent'];}),_0x1f6b4b['d'](_0x509795,'Light',function(){return _0xc9859e['Light'];}),_0x1f6b4b['d'](_0x509795,'ShadowLight',function(){return _0xc9859e['ShadowLight'];}),_0x1f6b4b['d'](_0x509795,'ShadowGenerator',function(){return _0xc9859e['ShadowGenerator'];}),_0x1f6b4b['d'](_0x509795,'CascadedShadowGenerator',function(){return _0xc9859e['CascadedShadowGenerator'];}),_0x1f6b4b['d'](_0x509795,'ShadowGeneratorSceneComponent',function(){return _0xc9859e['ShadowGeneratorSceneComponent'];}),_0x1f6b4b['d'](_0x509795,'DirectionalLight',function(){return _0xc9859e['DirectionalLight'];}),_0x1f6b4b['d'](_0x509795,'HemisphericLight',function(){return _0xc9859e['HemisphericLight'];}),_0x1f6b4b['d'](_0x509795,'PointLight',function(){return _0xc9859e['PointLight'];}),_0x1f6b4b['d'](_0x509795,'SpotLight',function(){return _0xc9859e['SpotLight'];}),_0x1f6b4b['d'](_0x509795,'DefaultLoadingScreen',function(){return _0xc9859e['DefaultLoadingScreen'];}),_0x1f6b4b['d'](_0x509795,'_BabylonLoaderRegistered',function(){return _0xc9859e['_BabylonLoaderRegistered'];}),_0x1f6b4b['d'](_0x509795,'BabylonFileLoaderConfiguration',function(){return _0xc9859e['BabylonFileLoaderConfiguration'];}),_0x1f6b4b['d'](_0x509795,'SceneLoaderAnimationGroupLoadingMode',function(){return _0xc9859e['SceneLoaderAnimationGroupLoadingMode'];}),_0x1f6b4b['d'](_0x509795,'SceneLoader',function(){return _0xc9859e['SceneLoader'];}),_0x1f6b4b['d'](_0x509795,'SceneLoaderFlags',function(){return _0xc9859e['SceneLoaderFlags'];}),_0x1f6b4b['d'](_0x509795,'BackgroundMaterial',function(){return _0xc9859e['BackgroundMaterial'];}),_0x1f6b4b['d'](_0x509795,'ColorCurves',function(){return _0xc9859e['ColorCurves'];}),_0x1f6b4b['d'](_0x509795,'EffectFallbacks',function(){return _0xc9859e['EffectFallbacks'];}),_0x1f6b4b['d'](_0x509795,'Effect',function(){return _0xc9859e['Effect'];}),_0x1f6b4b['d'](_0x509795,'FresnelParameters',function(){return _0xc9859e['FresnelParameters'];}),_0x1f6b4b['d'](_0x509795,'ImageProcessingConfigurationDefines',function(){return _0xc9859e['ImageProcessingConfigurationDefines'];}),_0x1f6b4b['d'](_0x509795,'ImageProcessingConfiguration',function(){return _0xc9859e['ImageProcessingConfiguration'];}),_0x1f6b4b['d'](_0x509795,'Material',function(){return _0xc9859e['Material'];}),_0x1f6b4b['d'](_0x509795,'MaterialDefines',function(){return _0xc9859e['MaterialDefines'];}),_0x1f6b4b['d'](_0x509795,'ThinMaterialHelper',function(){return _0xc9859e['ThinMaterialHelper'];}),_0x1f6b4b['d'](_0x509795,'MaterialHelper',function(){return _0xc9859e['MaterialHelper'];}),_0x1f6b4b['d'](_0x509795,'MultiMaterial',function(){return _0xc9859e['MultiMaterial'];}),_0x1f6b4b['d'](_0x509795,'PBRMaterialDefines',function(){return _0xc9859e['PBRMaterialDefines'];}),_0x1f6b4b['d'](_0x509795,'PBRBaseMaterial',function(){return _0xc9859e['PBRBaseMaterial'];}),_0x1f6b4b['d'](_0x509795,'PBRBaseSimpleMaterial',function(){return _0xc9859e['PBRBaseSimpleMaterial'];}),_0x1f6b4b['d'](_0x509795,'PBRMaterial',function(){return _0xc9859e['PBRMaterial'];}),_0x1f6b4b['d'](_0x509795,'PBRMetallicRoughnessMaterial',function(){return _0xc9859e['PBRMetallicRoughnessMaterial'];}),_0x1f6b4b['d'](_0x509795,'PBRSpecularGlossinessMaterial',function(){return _0xc9859e['PBRSpecularGlossinessMaterial'];}),_0x1f6b4b['d'](_0x509795,'PushMaterial',function(){return _0xc9859e['PushMaterial'];}),_0x1f6b4b['d'](_0x509795,'ShaderMaterial',function(){return _0xc9859e['ShaderMaterial'];}),_0x1f6b4b['d'](_0x509795,'StandardMaterialDefines',function(){return _0xc9859e['StandardMaterialDefines'];}),_0x1f6b4b['d'](_0x509795,'StandardMaterial',function(){return _0xc9859e['StandardMaterial'];}),_0x1f6b4b['d'](_0x509795,'BaseTexture',function(){return _0xc9859e['BaseTexture'];}),_0x1f6b4b['d'](_0x509795,'ColorGradingTexture',function(){return _0xc9859e['ColorGradingTexture'];}),_0x1f6b4b['d'](_0x509795,'CubeTexture',function(){return _0xc9859e['CubeTexture'];}),_0x1f6b4b['d'](_0x509795,'DynamicTexture',function(){return _0xc9859e['DynamicTexture'];}),_0x1f6b4b['d'](_0x509795,'EquiRectangularCubeTexture',function(){return _0xc9859e['EquiRectangularCubeTexture'];}),_0x1f6b4b['d'](_0x509795,'HDRFiltering',function(){return _0xc9859e['HDRFiltering'];}),_0x1f6b4b['d'](_0x509795,'HDRCubeTexture',function(){return _0xc9859e['HDRCubeTexture'];}),_0x1f6b4b['d'](_0x509795,'HtmlElementTexture',function(){return _0xc9859e['HtmlElementTexture'];}),_0x1f6b4b['d'](_0x509795,'InternalTextureSource',function(){return _0xc9859e['InternalTextureSource'];}),_0x1f6b4b['d'](_0x509795,'InternalTexture',function(){return _0xc9859e['InternalTexture'];}),_0x1f6b4b['d'](_0x509795,'_DDSTextureLoader',function(){return _0xc9859e['_DDSTextureLoader'];}),_0x1f6b4b['d'](_0x509795,'_ENVTextureLoader',function(){return _0xc9859e['_ENVTextureLoader'];}),_0x1f6b4b['d'](_0x509795,'_KTXTextureLoader',function(){return _0xc9859e['_KTXTextureLoader'];}),_0x1f6b4b['d'](_0x509795,'_TGATextureLoader',function(){return _0xc9859e['_TGATextureLoader'];}),_0x1f6b4b['d'](_0x509795,'_BasisTextureLoader',function(){return _0xc9859e['_BasisTextureLoader'];}),_0x1f6b4b['d'](_0x509795,'MirrorTexture',function(){return _0xc9859e['MirrorTexture'];}),_0x1f6b4b['d'](_0x509795,'MultiRenderTarget',function(){return _0xc9859e['MultiRenderTarget'];}),_0x1f6b4b['d'](_0x509795,'TexturePacker',function(){return _0xc9859e['TexturePacker'];}),_0x1f6b4b['d'](_0x509795,'TexturePackerFrame',function(){return _0xc9859e['TexturePackerFrame'];}),_0x1f6b4b['d'](_0x509795,'CustomProceduralTexture',function(){return _0xc9859e['CustomProceduralTexture'];}),_0x1f6b4b['d'](_0x509795,'NoiseProceduralTexture',function(){return _0xc9859e['NoiseProceduralTexture'];}),_0x1f6b4b['d'](_0x509795,'ProceduralTexture',function(){return _0xc9859e['ProceduralTexture'];}),_0x1f6b4b['d'](_0x509795,'ProceduralTextureSceneComponent',function(){return _0xc9859e['ProceduralTextureSceneComponent'];}),_0x1f6b4b['d'](_0x509795,'RawCubeTexture',function(){return _0xc9859e['RawCubeTexture'];}),_0x1f6b4b['d'](_0x509795,'RawTexture',function(){return _0xc9859e['RawTexture'];}),_0x1f6b4b['d'](_0x509795,'RawTexture2DArray',function(){return _0xc9859e['RawTexture2DArray'];}),_0x1f6b4b['d'](_0x509795,'RawTexture3D',function(){return _0xc9859e['RawTexture3D'];}),_0x1f6b4b['d'](_0x509795,'RefractionTexture',function(){return _0xc9859e['RefractionTexture'];}),_0x1f6b4b['d'](_0x509795,'RenderTargetTexture',function(){return _0xc9859e['RenderTargetTexture'];}),_0x1f6b4b['d'](_0x509795,'Texture',function(){return _0xc9859e['Texture'];}),_0x1f6b4b['d'](_0x509795,'VideoTexture',function(){return _0xc9859e['VideoTexture'];}),_0x1f6b4b['d'](_0x509795,'UniformBuffer',function(){return _0xc9859e['UniformBuffer'];}),_0x1f6b4b['d'](_0x509795,'MaterialFlags',function(){return _0xc9859e['MaterialFlags'];}),_0x1f6b4b['d'](_0x509795,'NodeMaterialBlockTargets',function(){return _0xc9859e['NodeMaterialBlockTargets'];}),_0x1f6b4b['d'](_0x509795,'NodeMaterialBlockConnectionPointTypes',function(){return _0xc9859e['NodeMaterialBlockConnectionPointTypes'];}),_0x1f6b4b['d'](_0x509795,'NodeMaterialBlockConnectionPointMode',function(){return _0xc9859e['NodeMaterialBlockConnectionPointMode'];}),_0x1f6b4b['d'](_0x509795,'NodeMaterialSystemValues',function(){return _0xc9859e['NodeMaterialSystemValues'];}),_0x1f6b4b['d'](_0x509795,'NodeMaterialModes',function(){return _0xc9859e['NodeMaterialModes'];}),_0x1f6b4b['d'](_0x509795,'NodeMaterialConnectionPointCompatibilityStates',function(){return _0xc9859e['NodeMaterialConnectionPointCompatibilityStates'];}),_0x1f6b4b['d'](_0x509795,'NodeMaterialConnectionPointDirection',function(){return _0xc9859e['NodeMaterialConnectionPointDirection'];}),_0x1f6b4b['d'](_0x509795,'NodeMaterialConnectionPoint',function(){return _0xc9859e['NodeMaterialConnectionPoint'];}),_0x1f6b4b['d'](_0x509795,'NodeMaterialBlock',function(){return _0xc9859e['NodeMaterialBlock'];}),_0x1f6b4b['d'](_0x509795,'NodeMaterialDefines',function(){return _0xc9859e['NodeMaterialDefines'];}),_0x1f6b4b['d'](_0x509795,'NodeMaterial',function(){return _0xc9859e['NodeMaterial'];}),_0x1f6b4b['d'](_0x509795,'VertexOutputBlock',function(){return _0xc9859e['VertexOutputBlock'];}),_0x1f6b4b['d'](_0x509795,'BonesBlock',function(){return _0xc9859e['BonesBlock'];}),_0x1f6b4b['d'](_0x509795,'InstancesBlock',function(){return _0xc9859e['InstancesBlock'];}),_0x1f6b4b['d'](_0x509795,'MorphTargetsBlock',function(){return _0xc9859e['MorphTargetsBlock'];}),_0x1f6b4b['d'](_0x509795,'LightInformationBlock',function(){return _0xc9859e['LightInformationBlock'];}),_0x1f6b4b['d'](_0x509795,'FragmentOutputBlock',function(){return _0xc9859e['FragmentOutputBlock'];}),_0x1f6b4b['d'](_0x509795,'ImageProcessingBlock',function(){return _0xc9859e['ImageProcessingBlock'];}),_0x1f6b4b['d'](_0x509795,'PerturbNormalBlock',function(){return _0xc9859e['PerturbNormalBlock'];}),_0x1f6b4b['d'](_0x509795,'DiscardBlock',function(){return _0xc9859e['DiscardBlock'];}),_0x1f6b4b['d'](_0x509795,'FrontFacingBlock',function(){return _0xc9859e['FrontFacingBlock'];}),_0x1f6b4b['d'](_0x509795,'DerivativeBlock',function(){return _0xc9859e['DerivativeBlock'];}),_0x1f6b4b['d'](_0x509795,'FragCoordBlock',function(){return _0xc9859e['FragCoordBlock'];}),_0x1f6b4b['d'](_0x509795,'ScreenSizeBlock',function(){return _0xc9859e['ScreenSizeBlock'];}),_0x1f6b4b['d'](_0x509795,'FogBlock',function(){return _0xc9859e['FogBlock'];}),_0x1f6b4b['d'](_0x509795,'LightBlock',function(){return _0xc9859e['LightBlock'];}),_0x1f6b4b['d'](_0x509795,'TextureBlock',function(){return _0xc9859e['TextureBlock'];}),_0x1f6b4b['d'](_0x509795,'ReflectionTextureBlock',function(){return _0xc9859e['ReflectionTextureBlock'];}),_0x1f6b4b['d'](_0x509795,'CurrentScreenBlock',function(){return _0xc9859e['CurrentScreenBlock'];}),_0x1f6b4b['d'](_0x509795,'InputBlock',function(){return _0xc9859e['InputBlock'];}),_0x1f6b4b['d'](_0x509795,'AnimatedInputBlockTypes',function(){return _0xc9859e['AnimatedInputBlockTypes'];}),_0x1f6b4b['d'](_0x509795,'MultiplyBlock',function(){return _0xc9859e['MultiplyBlock'];}),_0x1f6b4b['d'](_0x509795,'AddBlock',function(){return _0xc9859e['AddBlock'];}),_0x1f6b4b['d'](_0x509795,'ScaleBlock',function(){return _0xc9859e['ScaleBlock'];}),_0x1f6b4b['d'](_0x509795,'ClampBlock',function(){return _0xc9859e['ClampBlock'];}),_0x1f6b4b['d'](_0x509795,'CrossBlock',function(){return _0xc9859e['CrossBlock'];}),_0x1f6b4b['d'](_0x509795,'DotBlock',function(){return _0xc9859e['DotBlock'];}),_0x1f6b4b['d'](_0x509795,'TransformBlock',function(){return _0xc9859e['TransformBlock'];}),_0x1f6b4b['d'](_0x509795,'RemapBlock',function(){return _0xc9859e['RemapBlock'];}),_0x1f6b4b['d'](_0x509795,'NormalizeBlock',function(){return _0xc9859e['NormalizeBlock'];}),_0x1f6b4b['d'](_0x509795,'TrigonometryBlockOperations',function(){return _0xc9859e['TrigonometryBlockOperations'];}),_0x1f6b4b['d'](_0x509795,'TrigonometryBlock',function(){return _0xc9859e['TrigonometryBlock'];}),_0x1f6b4b['d'](_0x509795,'ColorMergerBlock',function(){return _0xc9859e['ColorMergerBlock'];}),_0x1f6b4b['d'](_0x509795,'VectorMergerBlock',function(){return _0xc9859e['VectorMergerBlock'];}),_0x1f6b4b['d'](_0x509795,'ColorSplitterBlock',function(){return _0xc9859e['ColorSplitterBlock'];}),_0x1f6b4b['d'](_0x509795,'VectorSplitterBlock',function(){return _0xc9859e['VectorSplitterBlock'];}),_0x1f6b4b['d'](_0x509795,'LerpBlock',function(){return _0xc9859e['LerpBlock'];}),_0x1f6b4b['d'](_0x509795,'DivideBlock',function(){return _0xc9859e['DivideBlock'];}),_0x1f6b4b['d'](_0x509795,'SubtractBlock',function(){return _0xc9859e['SubtractBlock'];}),_0x1f6b4b['d'](_0x509795,'StepBlock',function(){return _0xc9859e['StepBlock'];}),_0x1f6b4b['d'](_0x509795,'OneMinusBlock',function(){return _0xc9859e['OneMinusBlock'];}),_0x1f6b4b['d'](_0x509795,'ViewDirectionBlock',function(){return _0xc9859e['ViewDirectionBlock'];}),_0x1f6b4b['d'](_0x509795,'FresnelBlock',function(){return _0xc9859e['FresnelBlock'];}),_0x1f6b4b['d'](_0x509795,'MaxBlock',function(){return _0xc9859e['MaxBlock'];}),_0x1f6b4b['d'](_0x509795,'MinBlock',function(){return _0xc9859e['MinBlock'];}),_0x1f6b4b['d'](_0x509795,'DistanceBlock',function(){return _0xc9859e['DistanceBlock'];}),_0x1f6b4b['d'](_0x509795,'LengthBlock',function(){return _0xc9859e['LengthBlock'];}),_0x1f6b4b['d'](_0x509795,'NegateBlock',function(){return _0xc9859e['NegateBlock'];}),_0x1f6b4b['d'](_0x509795,'PowBlock',function(){return _0xc9859e['PowBlock'];}),_0x1f6b4b['d'](_0x509795,'RandomNumberBlock',function(){return _0xc9859e['RandomNumberBlock'];}),_0x1f6b4b['d'](_0x509795,'ArcTan2Block',function(){return _0xc9859e['ArcTan2Block'];}),_0x1f6b4b['d'](_0x509795,'SmoothStepBlock',function(){return _0xc9859e['SmoothStepBlock'];}),_0x1f6b4b['d'](_0x509795,'ReciprocalBlock',function(){return _0xc9859e['ReciprocalBlock'];}),_0x1f6b4b['d'](_0x509795,'ReplaceColorBlock',function(){return _0xc9859e['ReplaceColorBlock'];}),_0x1f6b4b['d'](_0x509795,'PosterizeBlock',function(){return _0xc9859e['PosterizeBlock'];}),_0x1f6b4b['d'](_0x509795,'WaveBlockKind',function(){return _0xc9859e['WaveBlockKind'];}),_0x1f6b4b['d'](_0x509795,'WaveBlock',function(){return _0xc9859e['WaveBlock'];}),_0x1f6b4b['d'](_0x509795,'GradientBlockColorStep',function(){return _0xc9859e['GradientBlockColorStep'];}),_0x1f6b4b['d'](_0x509795,'GradientBlock',function(){return _0xc9859e['GradientBlock'];}),_0x1f6b4b['d'](_0x509795,'NLerpBlock',function(){return _0xc9859e['NLerpBlock'];}),_0x1f6b4b['d'](_0x509795,'WorleyNoise3DBlock',function(){return _0xc9859e['WorleyNoise3DBlock'];}),_0x1f6b4b['d'](_0x509795,'SimplexPerlin3DBlock',function(){return _0xc9859e['SimplexPerlin3DBlock'];}),_0x1f6b4b['d'](_0x509795,'NormalBlendBlock',function(){return _0xc9859e['NormalBlendBlock'];}),_0x1f6b4b['d'](_0x509795,'Rotate2dBlock',function(){return _0xc9859e['Rotate2dBlock'];}),_0x1f6b4b['d'](_0x509795,'ReflectBlock',function(){return _0xc9859e['ReflectBlock'];}),_0x1f6b4b['d'](_0x509795,'RefractBlock',function(){return _0xc9859e['RefractBlock'];}),_0x1f6b4b['d'](_0x509795,'DesaturateBlock',function(){return _0xc9859e['DesaturateBlock'];}),_0x1f6b4b['d'](_0x509795,'PBRMetallicRoughnessBlock',function(){return _0xc9859e['PBRMetallicRoughnessBlock'];}),_0x1f6b4b['d'](_0x509795,'SheenBlock',function(){return _0xc9859e['SheenBlock'];}),_0x1f6b4b['d'](_0x509795,'AnisotropyBlock',function(){return _0xc9859e['AnisotropyBlock'];}),_0x1f6b4b['d'](_0x509795,'ReflectionBlock',function(){return _0xc9859e['ReflectionBlock'];}),_0x1f6b4b['d'](_0x509795,'ClearCoatBlock',function(){return _0xc9859e['ClearCoatBlock'];}),_0x1f6b4b['d'](_0x509795,'RefractionBlock',function(){return _0xc9859e['RefractionBlock'];}),_0x1f6b4b['d'](_0x509795,'SubSurfaceBlock',function(){return _0xc9859e['SubSurfaceBlock'];}),_0x1f6b4b['d'](_0x509795,'ParticleTextureBlock',function(){return _0xc9859e['ParticleTextureBlock'];}),_0x1f6b4b['d'](_0x509795,'ParticleRampGradientBlock',function(){return _0xc9859e['ParticleRampGradientBlock'];}),_0x1f6b4b['d'](_0x509795,'ParticleBlendMultiplyBlock',function(){return _0xc9859e['ParticleBlendMultiplyBlock'];}),_0x1f6b4b['d'](_0x509795,'ModBlock',function(){return _0xc9859e['ModBlock'];}),_0x1f6b4b['d'](_0x509795,'NodeMaterialOptimizer',function(){return _0xc9859e['NodeMaterialOptimizer'];}),_0x1f6b4b['d'](_0x509795,'PropertyTypeForEdition',function(){return _0xc9859e['PropertyTypeForEdition'];}),_0x1f6b4b['d'](_0x509795,'editableInPropertyPage',function(){return _0xc9859e['editableInPropertyPage'];}),_0x1f6b4b['d'](_0x509795,'EffectRenderer',function(){return _0xc9859e['EffectRenderer'];}),_0x1f6b4b['d'](_0x509795,'EffectWrapper',function(){return _0xc9859e['EffectWrapper'];}),_0x1f6b4b['d'](_0x509795,'ShadowDepthWrapper',function(){return _0xc9859e['ShadowDepthWrapper'];}),_0x1f6b4b['d'](_0x509795,'Scalar',function(){return _0xc9859e['Scalar'];}),_0x1f6b4b['d'](_0x509795,'extractMinAndMaxIndexed',function(){return _0xc9859e['extractMinAndMaxIndexed'];}),_0x1f6b4b['d'](_0x509795,'extractMinAndMax',function(){return _0xc9859e['extractMinAndMax'];}),_0x1f6b4b['d'](_0x509795,'Space',function(){return _0xc9859e['Space'];}),_0x1f6b4b['d'](_0x509795,'Axis',function(){return _0xc9859e['Axis'];}),_0x1f6b4b['d'](_0x509795,'Coordinate',function(){return _0xc9859e['Coordinate'];}),_0x1f6b4b['d'](_0x509795,'Color3',function(){return _0xc9859e['Color3'];}),_0x1f6b4b['d'](_0x509795,'Color4',function(){return _0xc9859e['Color4'];}),_0x1f6b4b['d'](_0x509795,'TmpColors',function(){return _0xc9859e['TmpColors'];}),_0x1f6b4b['d'](_0x509795,'ToGammaSpace',function(){return _0xc9859e['ToGammaSpace'];}),_0x1f6b4b['d'](_0x509795,'ToLinearSpace',function(){return _0xc9859e['ToLinearSpace'];}),_0x1f6b4b['d'](_0x509795,'Epsilon',function(){return _0xc9859e['Epsilon'];}),_0x1f6b4b['d'](_0x509795,'Frustum',function(){return _0xc9859e['Frustum'];}),_0x1f6b4b['d'](_0x509795,'Orientation',function(){return _0xc9859e['Orientation'];}),_0x1f6b4b['d'](_0x509795,'BezierCurve',function(){return _0xc9859e['BezierCurve'];}),_0x1f6b4b['d'](_0x509795,'Angle',function(){return _0xc9859e['Angle'];}),_0x1f6b4b['d'](_0x509795,'Arc2',function(){return _0xc9859e['Arc2'];}),_0x1f6b4b['d'](_0x509795,'Path2',function(){return _0xc9859e['Path2'];}),_0x1f6b4b['d'](_0x509795,'Path3D',function(){return _0xc9859e['Path3D'];}),_0x1f6b4b['d'](_0x509795,'Curve3',function(){return _0xc9859e['Curve3'];}),_0x1f6b4b['d'](_0x509795,'Plane',function(){return _0xc9859e['Plane'];}),_0x1f6b4b['d'](_0x509795,'Size',function(){return _0xc9859e['Size'];}),_0x1f6b4b['d'](_0x509795,'Vector2',function(){return _0xc9859e['Vector2'];}),_0x1f6b4b['d'](_0x509795,'Vector3',function(){return _0xc9859e['Vector3'];}),_0x1f6b4b['d'](_0x509795,'Vector4',function(){return _0xc9859e['Vector4'];}),_0x1f6b4b['d'](_0x509795,'Quaternion',function(){return _0xc9859e['Quaternion'];}),_0x1f6b4b['d'](_0x509795,'Matrix',function(){return _0xc9859e['Matrix'];}),_0x1f6b4b['d'](_0x509795,'TmpVectors',function(){return _0xc9859e['TmpVectors'];}),_0x1f6b4b['d'](_0x509795,'PositionNormalVertex',function(){return _0xc9859e['PositionNormalVertex'];}),_0x1f6b4b['d'](_0x509795,'PositionNormalTextureVertex',function(){return _0xc9859e['PositionNormalTextureVertex'];}),_0x1f6b4b['d'](_0x509795,'Viewport',function(){return _0xc9859e['Viewport'];}),_0x1f6b4b['d'](_0x509795,'SphericalHarmonics',function(){return _0xc9859e['SphericalHarmonics'];}),_0x1f6b4b['d'](_0x509795,'SphericalPolynomial',function(){return _0xc9859e['SphericalPolynomial'];}),_0x1f6b4b['d'](_0x509795,'AbstractMesh',function(){return _0xc9859e['AbstractMesh'];}),_0x1f6b4b['d'](_0x509795,'Buffer',function(){return _0xc9859e['Buffer'];}),_0x1f6b4b['d'](_0x509795,'VertexBuffer',function(){return _0xc9859e['VertexBuffer'];}),_0x1f6b4b['d'](_0x509795,'DracoCompression',function(){return _0xc9859e['DracoCompression'];}),_0x1f6b4b['d'](_0x509795,'CSG',function(){return _0xc9859e['CSG'];}),_0x1f6b4b['d'](_0x509795,'Geometry',function(){return _0xc9859e['Geometry'];}),_0x1f6b4b['d'](_0x509795,'GroundMesh',function(){return _0xc9859e['GroundMesh'];}),_0x1f6b4b['d'](_0x509795,'TrailMesh',function(){return _0xc9859e['TrailMesh'];}),_0x1f6b4b['d'](_0x509795,'InstancedMesh',function(){return _0xc9859e['InstancedMesh'];}),_0x1f6b4b['d'](_0x509795,'LinesMesh',function(){return _0xc9859e['LinesMesh'];}),_0x1f6b4b['d'](_0x509795,'InstancedLinesMesh',function(){return _0xc9859e['InstancedLinesMesh'];}),_0x1f6b4b['d'](_0x509795,'_CreationDataStorage',function(){return _0xc9859e['_CreationDataStorage'];}),_0x1f6b4b['d'](_0x509795,'_InstancesBatch',function(){return _0xc9859e['_InstancesBatch'];}),_0x1f6b4b['d'](_0x509795,'Mesh',function(){return _0xc9859e['Mesh'];}),_0x1f6b4b['d'](_0x509795,'VertexData',function(){return _0xc9859e['VertexData'];}),_0x1f6b4b['d'](_0x509795,'MeshBuilder',function(){return _0xc9859e['MeshBuilder'];}),_0x1f6b4b['d'](_0x509795,'SimplificationSettings',function(){return _0xc9859e['SimplificationSettings'];}),_0x1f6b4b['d'](_0x509795,'SimplificationQueue',function(){return _0xc9859e['SimplificationQueue'];}),_0x1f6b4b['d'](_0x509795,'SimplificationType',function(){return _0xc9859e['SimplificationType'];}),_0x1f6b4b['d'](_0x509795,'QuadraticErrorSimplification',function(){return _0xc9859e['QuadraticErrorSimplification'];}),_0x1f6b4b['d'](_0x509795,'SimplicationQueueSceneComponent',function(){return _0xc9859e['SimplicationQueueSceneComponent'];}),_0x1f6b4b['d'](_0x509795,'Polygon',function(){return _0xc9859e['Polygon'];}),_0x1f6b4b['d'](_0x509795,'PolygonMeshBuilder',function(){return _0xc9859e['PolygonMeshBuilder'];}),_0x1f6b4b['d'](_0x509795,'SubMesh',function(){return _0xc9859e['SubMesh'];}),_0x1f6b4b['d'](_0x509795,'MeshLODLevel',function(){return _0xc9859e['MeshLODLevel'];}),_0x1f6b4b['d'](_0x509795,'TransformNode',function(){return _0xc9859e['TransformNode'];}),_0x1f6b4b['d'](_0x509795,'BoxBuilder',function(){return _0xc9859e['BoxBuilder'];}),_0x1f6b4b['d'](_0x509795,'TiledBoxBuilder',function(){return _0xc9859e['TiledBoxBuilder'];}),_0x1f6b4b['d'](_0x509795,'DiscBuilder',function(){return _0xc9859e['DiscBuilder'];}),_0x1f6b4b['d'](_0x509795,'RibbonBuilder',function(){return _0xc9859e['RibbonBuilder'];}),_0x1f6b4b['d'](_0x509795,'SphereBuilder',function(){return _0xc9859e['SphereBuilder'];}),_0x1f6b4b['d'](_0x509795,'HemisphereBuilder',function(){return _0xc9859e['HemisphereBuilder'];}),_0x1f6b4b['d'](_0x509795,'CylinderBuilder',function(){return _0xc9859e['CylinderBuilder'];}),_0x1f6b4b['d'](_0x509795,'TorusBuilder',function(){return _0xc9859e['TorusBuilder'];}),_0x1f6b4b['d'](_0x509795,'TorusKnotBuilder',function(){return _0xc9859e['TorusKnotBuilder'];}),_0x1f6b4b['d'](_0x509795,'LinesBuilder',function(){return _0xc9859e['LinesBuilder'];}),_0x1f6b4b['d'](_0x509795,'PolygonBuilder',function(){return _0xc9859e['PolygonBuilder'];}),_0x1f6b4b['d'](_0x509795,'ShapeBuilder',function(){return _0xc9859e['ShapeBuilder'];}),_0x1f6b4b['d'](_0x509795,'LatheBuilder',function(){return _0xc9859e['LatheBuilder'];}),_0x1f6b4b['d'](_0x509795,'PlaneBuilder',function(){return _0xc9859e['PlaneBuilder'];}),_0x1f6b4b['d'](_0x509795,'TiledPlaneBuilder',function(){return _0xc9859e['TiledPlaneBuilder'];}),_0x1f6b4b['d'](_0x509795,'GroundBuilder',function(){return _0xc9859e['GroundBuilder'];}),_0x1f6b4b['d'](_0x509795,'TubeBuilder',function(){return _0xc9859e['TubeBuilder'];}),_0x1f6b4b['d'](_0x509795,'PolyhedronBuilder',function(){return _0xc9859e['PolyhedronBuilder'];}),_0x1f6b4b['d'](_0x509795,'IcoSphereBuilder',function(){return _0xc9859e['IcoSphereBuilder'];}),_0x1f6b4b['d'](_0x509795,'DecalBuilder',function(){return _0xc9859e['DecalBuilder'];}),_0x1f6b4b['d'](_0x509795,'CapsuleBuilder',function(){return _0xc9859e['CapsuleBuilder'];}),_0x1f6b4b['d'](_0x509795,'DataBuffer',function(){return _0xc9859e['DataBuffer'];}),_0x1f6b4b['d'](_0x509795,'WebGLDataBuffer',function(){return _0xc9859e['WebGLDataBuffer'];}),_0x1f6b4b['d'](_0x509795,'MorphTarget',function(){return _0xc9859e['MorphTarget'];}),_0x1f6b4b['d'](_0x509795,'MorphTargetManager',function(){return _0xc9859e['MorphTargetManager'];}),_0x1f6b4b['d'](_0x509795,'RecastJSPlugin',function(){return _0xc9859e['RecastJSPlugin'];}),_0x1f6b4b['d'](_0x509795,'RecastJSCrowd',function(){return _0xc9859e['RecastJSCrowd'];}),_0x1f6b4b['d'](_0x509795,'Node',function(){return _0xc9859e['Node'];}),_0x1f6b4b['d'](_0x509795,'Database',function(){return _0xc9859e['Database'];}),_0x1f6b4b['d'](_0x509795,'BaseParticleSystem',function(){return _0xc9859e['BaseParticleSystem'];}),_0x1f6b4b['d'](_0x509795,'BoxParticleEmitter',function(){return _0xc9859e['BoxParticleEmitter'];}),_0x1f6b4b['d'](_0x509795,'ConeParticleEmitter',function(){return _0xc9859e['ConeParticleEmitter'];}),_0x1f6b4b['d'](_0x509795,'CylinderParticleEmitter',function(){return _0xc9859e['CylinderParticleEmitter'];}),_0x1f6b4b['d'](_0x509795,'CylinderDirectedParticleEmitter',function(){return _0xc9859e['CylinderDirectedParticleEmitter'];}),_0x1f6b4b['d'](_0x509795,'HemisphericParticleEmitter',function(){return _0xc9859e['HemisphericParticleEmitter'];}),_0x1f6b4b['d'](_0x509795,'PointParticleEmitter',function(){return _0xc9859e['PointParticleEmitter'];}),_0x1f6b4b['d'](_0x509795,'SphereParticleEmitter',function(){return _0xc9859e['SphereParticleEmitter'];}),_0x1f6b4b['d'](_0x509795,'SphereDirectedParticleEmitter',function(){return _0xc9859e['SphereDirectedParticleEmitter'];}),_0x1f6b4b['d'](_0x509795,'CustomParticleEmitter',function(){return _0xc9859e['CustomParticleEmitter'];}),_0x1f6b4b['d'](_0x509795,'MeshParticleEmitter',function(){return _0xc9859e['MeshParticleEmitter'];}),_0x1f6b4b['d'](_0x509795,'GPUParticleSystem',function(){return _0xc9859e['GPUParticleSystem'];}),_0x1f6b4b['d'](_0x509795,'Particle',function(){return _0xc9859e['Particle'];}),_0x1f6b4b['d'](_0x509795,'ParticleHelper',function(){return _0xc9859e['ParticleHelper'];}),_0x1f6b4b['d'](_0x509795,'ParticleSystem',function(){return _0xc9859e['ParticleSystem'];}),_0x1f6b4b['d'](_0x509795,'ParticleSystemSet',function(){return _0xc9859e['ParticleSystemSet'];}),_0x1f6b4b['d'](_0x509795,'SolidParticle',function(){return _0xc9859e['SolidParticle'];}),_0x1f6b4b['d'](_0x509795,'ModelShape',function(){return _0xc9859e['ModelShape'];}),_0x1f6b4b['d'](_0x509795,'DepthSortedParticle',function(){return _0xc9859e['DepthSortedParticle'];}),_0x1f6b4b['d'](_0x509795,'SolidParticleVertex',function(){return _0xc9859e['SolidParticleVertex'];}),_0x1f6b4b['d'](_0x509795,'SolidParticleSystem',function(){return _0xc9859e['SolidParticleSystem'];}),_0x1f6b4b['d'](_0x509795,'CloudPoint',function(){return _0xc9859e['CloudPoint'];}),_0x1f6b4b['d'](_0x509795,'PointsGroup',function(){return _0xc9859e['PointsGroup'];}),_0x1f6b4b['d'](_0x509795,'PointColor',function(){return _0xc9859e['PointColor'];}),_0x1f6b4b['d'](_0x509795,'PointsCloudSystem',function(){return _0xc9859e['PointsCloudSystem'];}),_0x1f6b4b['d'](_0x509795,'SubEmitterType',function(){return _0xc9859e['SubEmitterType'];}),_0x1f6b4b['d'](_0x509795,'SubEmitter',function(){return _0xc9859e['SubEmitter'];}),_0x1f6b4b['d'](_0x509795,'PhysicsEngine',function(){return _0xc9859e['PhysicsEngine'];}),_0x1f6b4b['d'](_0x509795,'PhysicsEngineSceneComponent',function(){return _0xc9859e['PhysicsEngineSceneComponent'];}),_0x1f6b4b['d'](_0x509795,'PhysicsHelper',function(){return _0xc9859e['PhysicsHelper'];}),_0x1f6b4b['d'](_0x509795,'PhysicsRadialExplosionEventOptions',function(){return _0xc9859e['PhysicsRadialExplosionEventOptions'];}),_0x1f6b4b['d'](_0x509795,'PhysicsUpdraftEventOptions',function(){return _0xc9859e['PhysicsUpdraftEventOptions'];}),_0x1f6b4b['d'](_0x509795,'PhysicsVortexEventOptions',function(){return _0xc9859e['PhysicsVortexEventOptions'];}),_0x1f6b4b['d'](_0x509795,'PhysicsRadialImpulseFalloff',function(){return _0xc9859e['PhysicsRadialImpulseFalloff'];}),_0x1f6b4b['d'](_0x509795,'PhysicsUpdraftMode',function(){return _0xc9859e['PhysicsUpdraftMode'];}),_0x1f6b4b['d'](_0x509795,'PhysicsImpostor',function(){return _0xc9859e['PhysicsImpostor'];}),_0x1f6b4b['d'](_0x509795,'PhysicsJoint',function(){return _0xc9859e['PhysicsJoint'];}),_0x1f6b4b['d'](_0x509795,'DistanceJoint',function(){return _0xc9859e['DistanceJoint'];}),_0x1f6b4b['d'](_0x509795,'MotorEnabledJoint',function(){return _0xc9859e['MotorEnabledJoint'];}),_0x1f6b4b['d'](_0x509795,'HingeJoint',function(){return _0xc9859e['HingeJoint'];}),_0x1f6b4b['d'](_0x509795,'Hinge2Joint',function(){return _0xc9859e['Hinge2Joint'];}),_0x1f6b4b['d'](_0x509795,'CannonJSPlugin',function(){return _0xc9859e['CannonJSPlugin'];}),_0x1f6b4b['d'](_0x509795,'AmmoJSPlugin',function(){return _0xc9859e['AmmoJSPlugin'];}),_0x1f6b4b['d'](_0x509795,'OimoJSPlugin',function(){return _0xc9859e['OimoJSPlugin'];}),_0x1f6b4b['d'](_0x509795,'AnaglyphPostProcess',function(){return _0xc9859e['AnaglyphPostProcess'];}),_0x1f6b4b['d'](_0x509795,'BlackAndWhitePostProcess',function(){return _0xc9859e['BlackAndWhitePostProcess'];}),_0x1f6b4b['d'](_0x509795,'BloomEffect',function(){return _0xc9859e['BloomEffect'];}),_0x1f6b4b['d'](_0x509795,'BloomMergePostProcess',function(){return _0xc9859e['BloomMergePostProcess'];}),_0x1f6b4b['d'](_0x509795,'BlurPostProcess',function(){return _0xc9859e['BlurPostProcess'];}),_0x1f6b4b['d'](_0x509795,'ChromaticAberrationPostProcess',function(){return _0xc9859e['ChromaticAberrationPostProcess'];}),_0x1f6b4b['d'](_0x509795,'CircleOfConfusionPostProcess',function(){return _0xc9859e['CircleOfConfusionPostProcess'];}),_0x1f6b4b['d'](_0x509795,'ColorCorrectionPostProcess',function(){return _0xc9859e['ColorCorrectionPostProcess'];}),_0x1f6b4b['d'](_0x509795,'ConvolutionPostProcess',function(){return _0xc9859e['ConvolutionPostProcess'];}),_0x1f6b4b['d'](_0x509795,'DepthOfFieldBlurPostProcess',function(){return _0xc9859e['DepthOfFieldBlurPostProcess'];}),_0x1f6b4b['d'](_0x509795,'DepthOfFieldEffectBlurLevel',function(){return _0xc9859e['DepthOfFieldEffectBlurLevel'];}),_0x1f6b4b['d'](_0x509795,'DepthOfFieldEffect',function(){return _0xc9859e['DepthOfFieldEffect'];}),_0x1f6b4b['d'](_0x509795,'DepthOfFieldMergePostProcessOptions',function(){return _0xc9859e['DepthOfFieldMergePostProcessOptions'];}),_0x1f6b4b['d'](_0x509795,'DepthOfFieldMergePostProcess',function(){return _0xc9859e['DepthOfFieldMergePostProcess'];}),_0x1f6b4b['d'](_0x509795,'DisplayPassPostProcess',function(){return _0xc9859e['DisplayPassPostProcess'];}),_0x1f6b4b['d'](_0x509795,'ExtractHighlightsPostProcess',function(){return _0xc9859e['ExtractHighlightsPostProcess'];}),_0x1f6b4b['d'](_0x509795,'FilterPostProcess',function(){return _0xc9859e['FilterPostProcess'];}),_0x1f6b4b['d'](_0x509795,'FxaaPostProcess',function(){return _0xc9859e['FxaaPostProcess'];}),_0x1f6b4b['d'](_0x509795,'GrainPostProcess',function(){return _0xc9859e['GrainPostProcess'];}),_0x1f6b4b['d'](_0x509795,'HighlightsPostProcess',function(){return _0xc9859e['HighlightsPostProcess'];}),_0x1f6b4b['d'](_0x509795,'ImageProcessingPostProcess',function(){return _0xc9859e['ImageProcessingPostProcess'];}),_0x1f6b4b['d'](_0x509795,'MotionBlurPostProcess',function(){return _0xc9859e['MotionBlurPostProcess'];}),_0x1f6b4b['d'](_0x509795,'PassPostProcess',function(){return _0xc9859e['PassPostProcess'];}),_0x1f6b4b['d'](_0x509795,'PassCubePostProcess',function(){return _0xc9859e['PassCubePostProcess'];}),_0x1f6b4b['d'](_0x509795,'PostProcess',function(){return _0xc9859e['PostProcess'];}),_0x1f6b4b['d'](_0x509795,'PostProcessManager',function(){return _0xc9859e['PostProcessManager'];}),_0x1f6b4b['d'](_0x509795,'RefractionPostProcess',function(){return _0xc9859e['RefractionPostProcess'];}),_0x1f6b4b['d'](_0x509795,'DefaultRenderingPipeline',function(){return _0xc9859e['DefaultRenderingPipeline'];}),_0x1f6b4b['d'](_0x509795,'LensRenderingPipeline',function(){return _0xc9859e['LensRenderingPipeline'];}),_0x1f6b4b['d'](_0x509795,'SSAO2RenderingPipeline',function(){return _0xc9859e['SSAO2RenderingPipeline'];}),_0x1f6b4b['d'](_0x509795,'SSAORenderingPipeline',function(){return _0xc9859e['SSAORenderingPipeline'];}),_0x1f6b4b['d'](_0x509795,'StandardRenderingPipeline',function(){return _0xc9859e['StandardRenderingPipeline'];}),_0x1f6b4b['d'](_0x509795,'PostProcessRenderEffect',function(){return _0xc9859e['PostProcessRenderEffect'];}),_0x1f6b4b['d'](_0x509795,'PostProcessRenderPipeline',function(){return _0xc9859e['PostProcessRenderPipeline'];}),_0x1f6b4b['d'](_0x509795,'PostProcessRenderPipelineManager',function(){return _0xc9859e['PostProcessRenderPipelineManager'];}),_0x1f6b4b['d'](_0x509795,'PostProcessRenderPipelineManagerSceneComponent',function(){return _0xc9859e['PostProcessRenderPipelineManagerSceneComponent'];}),_0x1f6b4b['d'](_0x509795,'SharpenPostProcess',function(){return _0xc9859e['SharpenPostProcess'];}),_0x1f6b4b['d'](_0x509795,'StereoscopicInterlacePostProcessI',function(){return _0xc9859e['StereoscopicInterlacePostProcessI'];}),_0x1f6b4b['d'](_0x509795,'StereoscopicInterlacePostProcess',function(){return _0xc9859e['StereoscopicInterlacePostProcess'];}),_0x1f6b4b['d'](_0x509795,'TonemappingOperator',function(){return _0xc9859e['TonemappingOperator'];}),_0x1f6b4b['d'](_0x509795,'TonemapPostProcess',function(){return _0xc9859e['TonemapPostProcess'];}),_0x1f6b4b['d'](_0x509795,'VolumetricLightScatteringPostProcess',function(){return _0xc9859e['VolumetricLightScatteringPostProcess'];}),_0x1f6b4b['d'](_0x509795,'VRDistortionCorrectionPostProcess',function(){return _0xc9859e['VRDistortionCorrectionPostProcess'];}),_0x1f6b4b['d'](_0x509795,'VRMultiviewToSingleviewPostProcess',function(){return _0xc9859e['VRMultiviewToSingleviewPostProcess'];}),_0x1f6b4b['d'](_0x509795,'ScreenSpaceReflectionPostProcess',function(){return _0xc9859e['ScreenSpaceReflectionPostProcess'];}),_0x1f6b4b['d'](_0x509795,'ScreenSpaceCurvaturePostProcess',function(){return _0xc9859e['ScreenSpaceCurvaturePostProcess'];}),_0x1f6b4b['d'](_0x509795,'ReflectionProbe',function(){return _0xc9859e['ReflectionProbe'];}),_0x1f6b4b['d'](_0x509795,'BoundingBoxRenderer',function(){return _0xc9859e['BoundingBoxRenderer'];}),_0x1f6b4b['d'](_0x509795,'DepthRenderer',function(){return _0xc9859e['DepthRenderer'];}),_0x1f6b4b['d'](_0x509795,'DepthRendererSceneComponent',function(){return _0xc9859e['DepthRendererSceneComponent'];}),_0x1f6b4b['d'](_0x509795,'EdgesRenderer',function(){return _0xc9859e['EdgesRenderer'];}),_0x1f6b4b['d'](_0x509795,'LineEdgesRenderer',function(){return _0xc9859e['LineEdgesRenderer'];}),_0x1f6b4b['d'](_0x509795,'GeometryBufferRenderer',function(){return _0xc9859e['GeometryBufferRenderer'];}),_0x1f6b4b['d'](_0x509795,'GeometryBufferRendererSceneComponent',function(){return _0xc9859e['GeometryBufferRendererSceneComponent'];}),_0x1f6b4b['d'](_0x509795,'PrePassRenderer',function(){return _0xc9859e['PrePassRenderer'];}),_0x1f6b4b['d'](_0x509795,'PrePassRendererSceneComponent',function(){return _0xc9859e['PrePassRendererSceneComponent'];}),_0x1f6b4b['d'](_0x509795,'SubSurfaceSceneComponent',function(){return _0xc9859e['SubSurfaceSceneComponent'];}),_0x1f6b4b['d'](_0x509795,'OutlineRenderer',function(){return _0xc9859e['OutlineRenderer'];}),_0x1f6b4b['d'](_0x509795,'RenderingGroup',function(){return _0xc9859e['RenderingGroup'];}),_0x1f6b4b['d'](_0x509795,'RenderingGroupInfo',function(){return _0xc9859e['RenderingGroupInfo'];}),_0x1f6b4b['d'](_0x509795,'RenderingManager',function(){return _0xc9859e['RenderingManager'];}),_0x1f6b4b['d'](_0x509795,'UtilityLayerRenderer',function(){return _0xc9859e['UtilityLayerRenderer'];}),_0x1f6b4b['d'](_0x509795,'Scene',function(){return _0xc9859e['Scene'];}),_0x1f6b4b['d'](_0x509795,'SceneComponentConstants',function(){return _0xc9859e['SceneComponentConstants'];}),_0x1f6b4b['d'](_0x509795,'Stage',function(){return _0xc9859e['Stage'];}),_0x1f6b4b['d'](_0x509795,'Sprite',function(){return _0xc9859e['Sprite'];}),_0x1f6b4b['d'](_0x509795,'SpriteManager',function(){return _0xc9859e['SpriteManager'];}),_0x1f6b4b['d'](_0x509795,'SpriteMap',function(){return _0xc9859e['SpriteMap'];}),_0x1f6b4b['d'](_0x509795,'SpritePackedManager',function(){return _0xc9859e['SpritePackedManager'];}),_0x1f6b4b['d'](_0x509795,'SpriteSceneComponent',function(){return _0xc9859e['SpriteSceneComponent'];}),_0x1f6b4b['d'](_0x509795,'AlphaState',function(){return _0xc9859e['AlphaState'];}),_0x1f6b4b['d'](_0x509795,'DepthCullingState',function(){return _0xc9859e['DepthCullingState'];}),_0x1f6b4b['d'](_0x509795,'StencilState',function(){return _0xc9859e['StencilState'];}),_0x1f6b4b['d'](_0x509795,'AndOrNotEvaluator',function(){return _0xc9859e['AndOrNotEvaluator'];}),_0x1f6b4b['d'](_0x509795,'AssetTaskState',function(){return _0xc9859e['AssetTaskState'];}),_0x1f6b4b['d'](_0x509795,'AbstractAssetTask',function(){return _0xc9859e['AbstractAssetTask'];}),_0x1f6b4b['d'](_0x509795,'AssetsProgressEvent',function(){return _0xc9859e['AssetsProgressEvent'];}),_0x1f6b4b['d'](_0x509795,'ContainerAssetTask',function(){return _0xc9859e['ContainerAssetTask'];}),_0x1f6b4b['d'](_0x509795,'MeshAssetTask',function(){return _0xc9859e['MeshAssetTask'];}),_0x1f6b4b['d'](_0x509795,'TextFileAssetTask',function(){return _0xc9859e['TextFileAssetTask'];}),_0x1f6b4b['d'](_0x509795,'BinaryFileAssetTask',function(){return _0xc9859e['BinaryFileAssetTask'];}),_0x1f6b4b['d'](_0x509795,'ImageAssetTask',function(){return _0xc9859e['ImageAssetTask'];}),_0x1f6b4b['d'](_0x509795,'TextureAssetTask',function(){return _0xc9859e['TextureAssetTask'];}),_0x1f6b4b['d'](_0x509795,'CubeTextureAssetTask',function(){return _0xc9859e['CubeTextureAssetTask'];}),_0x1f6b4b['d'](_0x509795,'HDRCubeTextureAssetTask',function(){return _0xc9859e['HDRCubeTextureAssetTask'];}),_0x1f6b4b['d'](_0x509795,'EquiRectangularCubeTextureAssetTask',function(){return _0xc9859e['EquiRectangularCubeTextureAssetTask'];}),_0x1f6b4b['d'](_0x509795,'AssetsManager',function(){return _0xc9859e['AssetsManager'];}),_0x1f6b4b['d'](_0x509795,'BasisTranscodeConfiguration',function(){return _0xc9859e['BasisTranscodeConfiguration'];}),_0x1f6b4b['d'](_0x509795,'BasisTools',function(){return _0xc9859e['BasisTools'];}),_0x1f6b4b['d'](_0x509795,'DDSTools',function(){return _0xc9859e['DDSTools'];}),_0x1f6b4b['d'](_0x509795,'expandToProperty',function(){return _0xc9859e['expandToProperty'];}),_0x1f6b4b['d'](_0x509795,'serialize',function(){return _0xc9859e['serialize'];}),_0x1f6b4b['d'](_0x509795,'serializeAsTexture',function(){return _0xc9859e['serializeAsTexture'];}),_0x1f6b4b['d'](_0x509795,'serializeAsColor3',function(){return _0xc9859e['serializeAsColor3'];}),_0x1f6b4b['d'](_0x509795,'serializeAsFresnelParameters',function(){return _0xc9859e['serializeAsFresnelParameters'];}),_0x1f6b4b['d'](_0x509795,'serializeAsVector2',function(){return _0xc9859e['serializeAsVector2'];}),_0x1f6b4b['d'](_0x509795,'serializeAsVector3',function(){return _0xc9859e['serializeAsVector3'];}),_0x1f6b4b['d'](_0x509795,'serializeAsMeshReference',function(){return _0xc9859e['serializeAsMeshReference'];}),_0x1f6b4b['d'](_0x509795,'serializeAsColorCurves',function(){return _0xc9859e['serializeAsColorCurves'];}),_0x1f6b4b['d'](_0x509795,'serializeAsColor4',function(){return _0xc9859e['serializeAsColor4'];}),_0x1f6b4b['d'](_0x509795,'serializeAsImageProcessingConfiguration',function(){return _0xc9859e['serializeAsImageProcessingConfiguration'];}),_0x1f6b4b['d'](_0x509795,'serializeAsQuaternion',function(){return _0xc9859e['serializeAsQuaternion'];}),_0x1f6b4b['d'](_0x509795,'serializeAsMatrix',function(){return _0xc9859e['serializeAsMatrix'];}),_0x1f6b4b['d'](_0x509795,'serializeAsCameraReference',function(){return _0xc9859e['serializeAsCameraReference'];}),_0x1f6b4b['d'](_0x509795,'SerializationHelper',function(){return _0xc9859e['SerializationHelper'];}),_0x1f6b4b['d'](_0x509795,'Deferred',function(){return _0xc9859e['Deferred'];}),_0x1f6b4b['d'](_0x509795,'EnvironmentTextureTools',function(){return _0xc9859e['EnvironmentTextureTools'];}),_0x1f6b4b['d'](_0x509795,'MeshExploder',function(){return _0xc9859e['MeshExploder'];}),_0x1f6b4b['d'](_0x509795,'FilesInput',function(){return _0xc9859e['FilesInput'];}),_0x1f6b4b['d'](_0x509795,'CubeMapToSphericalPolynomialTools',function(){return _0xc9859e['CubeMapToSphericalPolynomialTools'];}),_0x1f6b4b['d'](_0x509795,'HDRTools',function(){return _0xc9859e['HDRTools'];}),_0x1f6b4b['d'](_0x509795,'PanoramaToCubeMapTools',function(){return _0xc9859e['PanoramaToCubeMapTools'];}),_0x1f6b4b['d'](_0x509795,'KhronosTextureContainer',function(){return _0xc9859e['KhronosTextureContainer'];}),_0x1f6b4b['d'](_0x509795,'EventState',function(){return _0xc9859e['EventState'];}),_0x1f6b4b['d'](_0x509795,'Observer',function(){return _0xc9859e['Observer'];}),_0x1f6b4b['d'](_0x509795,'MultiObserver',function(){return _0xc9859e['MultiObserver'];}),_0x1f6b4b['d'](_0x509795,'Observable',function(){return _0xc9859e['Observable'];}),_0x1f6b4b['d'](_0x509795,'PerformanceMonitor',function(){return _0xc9859e['PerformanceMonitor'];}),_0x1f6b4b['d'](_0x509795,'RollingAverage',function(){return _0xc9859e['RollingAverage'];}),_0x1f6b4b['d'](_0x509795,'PromisePolyfill',function(){return _0xc9859e['PromisePolyfill'];}),_0x1f6b4b['d'](_0x509795,'SceneOptimization',function(){return _0xc9859e['SceneOptimization'];}),_0x1f6b4b['d'](_0x509795,'TextureOptimization',function(){return _0xc9859e['TextureOptimization'];}),_0x1f6b4b['d'](_0x509795,'HardwareScalingOptimization',function(){return _0xc9859e['HardwareScalingOptimization'];}),_0x1f6b4b['d'](_0x509795,'ShadowsOptimization',function(){return _0xc9859e['ShadowsOptimization'];}),_0x1f6b4b['d'](_0x509795,'PostProcessesOptimization',function(){return _0xc9859e['PostProcessesOptimization'];}),_0x1f6b4b['d'](_0x509795,'LensFlaresOptimization',function(){return _0xc9859e['LensFlaresOptimization'];}),_0x1f6b4b['d'](_0x509795,'CustomOptimization',function(){return _0xc9859e['CustomOptimization'];}),_0x1f6b4b['d'](_0x509795,'ParticlesOptimization',function(){return _0xc9859e['ParticlesOptimization'];}),_0x1f6b4b['d'](_0x509795,'RenderTargetsOptimization',function(){return _0xc9859e['RenderTargetsOptimization'];}),_0x1f6b4b['d'](_0x509795,'MergeMeshesOptimization',function(){return _0xc9859e['MergeMeshesOptimization'];}),_0x1f6b4b['d'](_0x509795,'SceneOptimizerOptions',function(){return _0xc9859e['SceneOptimizerOptions'];}),_0x1f6b4b['d'](_0x509795,'SceneOptimizer',function(){return _0xc9859e['SceneOptimizer'];}),_0x1f6b4b['d'](_0x509795,'SceneSerializer',function(){return _0xc9859e['SceneSerializer'];}),_0x1f6b4b['d'](_0x509795,'SmartArray',function(){return _0xc9859e['SmartArray'];}),_0x1f6b4b['d'](_0x509795,'SmartArrayNoDuplicate',function(){return _0xc9859e['SmartArrayNoDuplicate'];}),_0x1f6b4b['d'](_0x509795,'StringDictionary',function(){return _0xc9859e['StringDictionary'];}),_0x1f6b4b['d'](_0x509795,'Tags',function(){return _0xc9859e['Tags'];}),_0x1f6b4b['d'](_0x509795,'TextureTools',function(){return _0xc9859e['TextureTools'];}),_0x1f6b4b['d'](_0x509795,'TGATools',function(){return _0xc9859e['TGATools'];}),_0x1f6b4b['d'](_0x509795,'Tools',function(){return _0xc9859e['Tools'];}),_0x1f6b4b['d'](_0x509795,'className',function(){return _0xc9859e['className'];}),_0x1f6b4b['d'](_0x509795,'AsyncLoop',function(){return _0xc9859e['AsyncLoop'];}),_0x1f6b4b['d'](_0x509795,'VideoRecorder',function(){return _0xc9859e['VideoRecorder'];}),_0x1f6b4b['d'](_0x509795,'JoystickAxis',function(){return _0xc9859e['JoystickAxis'];}),_0x1f6b4b['d'](_0x509795,'VirtualJoystick',function(){return _0xc9859e['VirtualJoystick'];}),_0x1f6b4b['d'](_0x509795,'WorkerPool',function(){return _0xc9859e['WorkerPool'];}),_0x1f6b4b['d'](_0x509795,'Logger',function(){return _0xc9859e['Logger'];}),_0x1f6b4b['d'](_0x509795,'_TypeStore',function(){return _0xc9859e['_TypeStore'];}),_0x1f6b4b['d'](_0x509795,'FilesInputStore',function(){return _0xc9859e['FilesInputStore'];}),_0x1f6b4b['d'](_0x509795,'DeepCopier',function(){return _0xc9859e['DeepCopier'];}),_0x1f6b4b['d'](_0x509795,'PivotTools',function(){return _0xc9859e['PivotTools'];}),_0x1f6b4b['d'](_0x509795,'PrecisionDate',function(){return _0xc9859e['PrecisionDate'];}),_0x1f6b4b['d'](_0x509795,'ScreenshotTools',function(){return _0xc9859e['ScreenshotTools'];}),_0x1f6b4b['d'](_0x509795,'WebRequest',function(){return _0xc9859e['WebRequest'];}),_0x1f6b4b['d'](_0x509795,'InspectableType',function(){return _0xc9859e['InspectableType'];}),_0x1f6b4b['d'](_0x509795,'BRDFTextureTools',function(){return _0xc9859e['BRDFTextureTools'];}),_0x1f6b4b['d'](_0x509795,'RGBDTextureTools',function(){return _0xc9859e['RGBDTextureTools'];}),_0x1f6b4b['d'](_0x509795,'ColorGradient',function(){return _0xc9859e['ColorGradient'];}),_0x1f6b4b['d'](_0x509795,'Color3Gradient',function(){return _0xc9859e['Color3Gradient'];}),_0x1f6b4b['d'](_0x509795,'FactorGradient',function(){return _0xc9859e['FactorGradient'];}),_0x1f6b4b['d'](_0x509795,'GradientHelper',function(){return _0xc9859e['GradientHelper'];}),_0x1f6b4b['d'](_0x509795,'PerfCounter',function(){return _0xc9859e['PerfCounter'];}),_0x1f6b4b['d'](_0x509795,'RetryStrategy',function(){return _0xc9859e['RetryStrategy'];}),_0x1f6b4b['d'](_0x509795,'CanvasGenerator',function(){return _0xc9859e['CanvasGenerator'];}),_0x1f6b4b['d'](_0x509795,'LoadFileError',function(){return _0xc9859e['LoadFileError'];}),_0x1f6b4b['d'](_0x509795,'RequestFileError',function(){return _0xc9859e['RequestFileError'];}),_0x1f6b4b['d'](_0x509795,'ReadFileError',function(){return _0xc9859e['ReadFileError'];}),_0x1f6b4b['d'](_0x509795,'FileTools',function(){return _0xc9859e['FileTools'];}),_0x1f6b4b['d'](_0x509795,'StringTools',function(){return _0xc9859e['StringTools'];}),_0x1f6b4b['d'](_0x509795,'DataReader',function(){return _0xc9859e['DataReader'];}),_0x1f6b4b['d'](_0x509795,'MinMaxReducer',function(){return _0xc9859e['MinMaxReducer'];}),_0x1f6b4b['d'](_0x509795,'DepthReducer',function(){return _0xc9859e['DepthReducer'];}),_0x1f6b4b['d'](_0x509795,'DataStorage',function(){return _0xc9859e['DataStorage'];}),_0x1f6b4b['d'](_0x509795,'SceneRecorder',function(){return _0xc9859e['SceneRecorder'];}),_0x1f6b4b['d'](_0x509795,'KhronosTextureContainer2',function(){return _0xc9859e['KhronosTextureContainer2'];}),_0x1f6b4b['d'](_0x509795,'Trajectory',function(){return _0xc9859e['Trajectory'];}),_0x1f6b4b['d'](_0x509795,'TrajectoryClassifier',function(){return _0xc9859e['TrajectoryClassifier'];}),_0x1f6b4b['d'](_0x509795,'TimerState',function(){return _0xc9859e['TimerState'];}),_0x1f6b4b['d'](_0x509795,'setAndStartTimer',function(){return _0xc9859e['setAndStartTimer'];}),_0x1f6b4b['d'](_0x509795,'AdvancedTimer',function(){return _0xc9859e['AdvancedTimer'];}),_0x1f6b4b['d'](_0x509795,'CopyTools',function(){return _0xc9859e['CopyTools'];}),_0x1f6b4b['d'](_0x509795,'WebXRCamera',function(){return _0xc9859e['WebXRCamera'];}),_0x1f6b4b['d'](_0x509795,'WebXREnterExitUIButton',function(){return _0xc9859e['WebXREnterExitUIButton'];}),_0x1f6b4b['d'](_0x509795,'WebXREnterExitUIOptions',function(){return _0xc9859e['WebXREnterExitUIOptions'];}),_0x1f6b4b['d'](_0x509795,'WebXREnterExitUI',function(){return _0xc9859e['WebXREnterExitUI'];}),_0x1f6b4b['d'](_0x509795,'WebXRExperienceHelper',function(){return _0xc9859e['WebXRExperienceHelper'];}),_0x1f6b4b['d'](_0x509795,'WebXRInput',function(){return _0xc9859e['WebXRInput'];}),_0x1f6b4b['d'](_0x509795,'WebXRInputSource',function(){return _0xc9859e['WebXRInputSource'];}),_0x1f6b4b['d'](_0x509795,'WebXRManagedOutputCanvasOptions',function(){return _0xc9859e['WebXRManagedOutputCanvasOptions'];}),_0x1f6b4b['d'](_0x509795,'WebXRManagedOutputCanvas',function(){return _0xc9859e['WebXRManagedOutputCanvas'];}),_0x1f6b4b['d'](_0x509795,'WebXRState',function(){return _0xc9859e['WebXRState'];}),_0x1f6b4b['d'](_0x509795,'WebXRTrackingState',function(){return _0xc9859e['WebXRTrackingState'];}),_0x1f6b4b['d'](_0x509795,'WebXRSessionManager',function(){return _0xc9859e['WebXRSessionManager'];}),_0x1f6b4b['d'](_0x509795,'WebXRDefaultExperienceOptions',function(){return _0xc9859e['WebXRDefaultExperienceOptions'];}),_0x1f6b4b['d'](_0x509795,'WebXRDefaultExperience',function(){return _0xc9859e['WebXRDefaultExperience'];}),_0x1f6b4b['d'](_0x509795,'WebXRFeatureName',function(){return _0xc9859e['WebXRFeatureName'];}),_0x1f6b4b['d'](_0x509795,'WebXRFeaturesManager',function(){return _0xc9859e['WebXRFeaturesManager'];}),_0x1f6b4b['d'](_0x509795,'WebXRAbstractFeature',function(){return _0xc9859e['WebXRAbstractFeature'];}),_0x1f6b4b['d'](_0x509795,'WebXRHitTestLegacy',function(){return _0xc9859e['WebXRHitTestLegacy'];}),_0x1f6b4b['d'](_0x509795,'WebXRAnchorSystem',function(){return _0xc9859e['WebXRAnchorSystem'];}),_0x1f6b4b['d'](_0x509795,'WebXRPlaneDetector',function(){return _0xc9859e['WebXRPlaneDetector'];}),_0x1f6b4b['d'](_0x509795,'WebXRBackgroundRemover',function(){return _0xc9859e['WebXRBackgroundRemover'];}),_0x1f6b4b['d'](_0x509795,'WebXRMotionControllerTeleportation',function(){return _0xc9859e['WebXRMotionControllerTeleportation'];}),_0x1f6b4b['d'](_0x509795,'WebXRControllerPointerSelection',function(){return _0xc9859e['WebXRControllerPointerSelection'];}),_0x1f6b4b['d'](_0x509795,'IWebXRControllerPhysicsOptions',function(){return _0xc9859e['IWebXRControllerPhysicsOptions'];}),_0x1f6b4b['d'](_0x509795,'WebXRControllerPhysics',function(){return _0xc9859e['WebXRControllerPhysics'];}),_0x1f6b4b['d'](_0x509795,'WebXRHitTest',function(){return _0xc9859e['WebXRHitTest'];}),_0x1f6b4b['d'](_0x509795,'WebXRFeaturePointSystem',function(){return _0xc9859e['WebXRFeaturePointSystem'];}),_0x1f6b4b['d'](_0x509795,'WebXRHand',function(){return _0xc9859e['WebXRHand'];}),_0x1f6b4b['d'](_0x509795,'WebXRHandTracking',function(){return _0xc9859e['WebXRHandTracking'];}),_0x1f6b4b['d'](_0x509795,'WebXRAbstractMotionController',function(){return _0xc9859e['WebXRAbstractMotionController'];}),_0x1f6b4b['d'](_0x509795,'WebXRControllerComponent',function(){return _0xc9859e['WebXRControllerComponent'];}),_0x1f6b4b['d'](_0x509795,'WebXRGenericTriggerMotionController',function(){return _0xc9859e['WebXRGenericTriggerMotionController'];}),_0x1f6b4b['d'](_0x509795,'WebXRMicrosoftMixedRealityController',function(){return _0xc9859e['WebXRMicrosoftMixedRealityController'];}),_0x1f6b4b['d'](_0x509795,'WebXRMotionControllerManager',function(){return _0xc9859e['WebXRMotionControllerManager'];}),_0x1f6b4b['d'](_0x509795,'WebXROculusTouchMotionController',function(){return _0xc9859e['WebXROculusTouchMotionController'];}),_0x1f6b4b['d'](_0x509795,'WebXRHTCViveMotionController',function(){return _0xc9859e['WebXRHTCViveMotionController'];}),_0x1f6b4b['d'](_0x509795,'WebXRProfiledMotionController',function(){return _0xc9859e['WebXRProfiledMotionController'];});var _0x2f2c27=void 0x0!==_0x3af596?_0x3af596:'undefined'!=typeof window?window:void 0x0;if(void 0x0!==_0x2f2c27){_0x2f2c27['BABYLON']=_0x4fbbdc,_0x2f2c27['BABYLON']=_0x2f2c27['BABYLON']||{};var _0x4fbbdc=_0x2f2c27['BABYLON'];_0x4fbbdc['Debug']=_0x4fbbdc['Debug']||{};var _0x1c982e=[];for(var _0x38adba in _0xcc9dd0)_0x4fbbdc['Debug'][_0x38adba]=_0xcc9dd0[_0x38adba],_0x1c982e['push'](_0x38adba);for(var _0x38adba in _0xc9859e)_0x4fbbdc[_0x38adba]=_0xc9859e[_0x38adba];}var _0x517d4c={'AxesViewer':_0xcc9dd0['AxesViewer'],'BoneAxesViewer':_0xcc9dd0['BoneAxesViewer'],'PhysicsViewer':_0xcc9dd0['PhysicsViewer'],'SkeletonViewer':_0xcc9dd0['SkeletonViewer']};}['call'](this,_0x1f6b4b(0x9f));}]);});var _STRINGS={'Ad':{'Mobile':{'Preroll':{'ReadyIn':'The\x20game\x20is\x20ready\x20in\x20','Loading':'Your\x20game\x20is\x20loading...','Close':'Close'},'Header':{'ReadyIn':'The\x20game\x20is\x20ready\x20in\x20','Loading':'Your\x20game\x20is\x20loading...','Close':'Close'},'End':{'ReadyIn':'Advertisement\x20ends\x20in\x20','Loading':'Please\x20wait\x20...','Close':'Close'}}},'Splash':{'TapToStart':'TAP\x20TO\x20START'},'Game':{'Play':'PLAY','Settings':'SETTINGS','GameOver':'GAME\x20OVER','Paused':'PAUSED','Score':'Score','Best':'Best','TutorialMobile':['tap\x20and\x20hold','left\x20and\x20right\x20part\x20of\x20screen','to\x20steer','tap\x20anywhere\x20to\x20continue'],'TutorialDesktop':['press\x20A\x20and\x20D','or\x20LEFT\x20and\x20RIGHT\x20arrow','to\x20steer','press\x20SPACE\x20to\x20continue']}},_SETTINGS={'API':{'Enabled':!0x0,'Log':{'Events':{'InitializeGame':!0x0,'EndGame':!0x0,'Level':{'Begin':!0x0,'End':!0x0,'Win':!0x0,'Lose':!0x0,'Draw':!0x0}}}},'Ad':{'Mobile':{'Preroll':{'Enabled':!0x1,'Duration':0x5,'Width':0x12c,'Height':0xfa,'Rotation':{'Enabled':!0x1,'Weight':{'MobileAdInGamePreroll':0x28,'MobileAdInGamePreroll2':0x28,'MobileAdInGamePreroll3':0x14}}},'Header':{'Enabled':!0x1,'Duration':0x5,'Width':0x140,'Height':0x32,'Rotation':{'Enabled':!0x1,'Weight':{'MobileAdInGameHeader':0x28,'MobileAdInGameHeader2':0x28,'MobileAdInGameHeader3':0x14}}},'Footer':{'Enabled':!0x1,'Duration':0x5,'Width':0x140,'Height':0x32,'Rotation':{'Enabled':!0x1,'Weight':{'MobileAdInGameFooter':0x28,'MobileAdInGameFooter2':0x28,'MobileAdInGameFooter3':0x14}}},'End':{'Enabled':!0x1,'Duration':0x1,'Width':0x12c,'Height':0xfa,'Rotation':{'Enabled':!0x1,'Weight':{'MobileAdInGameEnd':0x28,'MobileAdInGameEnd2':0x28,'MobileAdInGameEnd3':0x14}}}}},'Language':{'Default':'en'},'DeveloperBranding':{'Splash':{'Enabled':!0x1},'Logo':{'Enabled':!0x1,'Link':'http://google.com','LinkEnabled':!0x1,'NewWindow':!0x0,'Width':0xa6,'Height':0x3d}},'Branding':{'Splash':{'Enabled':!0x0},'Logo':{'Enabled':!0x1,'Link':'http://google.com','LinkEnabled':!0x1,'NewWindow':!0x0,'Width':0x3c0,'Height':0x21c}},'MoreGames':{'Enabled':!0x0,'Link':'javascript:ig.game.resetScore();','NewWindow':!0x1},'TapToStartAudioUnlock':{'Enabled':!0x1}},MobileAdInGamePreroll={'ad_duration':_SETTINGS['Ad']['Mobile']['Preroll']['Duration'],'ad_width':_SETTINGS['Ad']['Mobile']['Preroll']['Width'],'ad_height':_SETTINGS['Ad']['Mobile']['Preroll']['Height'],'ready_in':_STRINGS['Ad']['Mobile']['Preroll']['ReadyIn'],'loading':_STRINGS['Ad']['Mobile']['Preroll']['Loading'],'close':_STRINGS['Ad']['Mobile']['Preroll']['Close']+'          ','Initialize':function(){if(_SETTINGS['Ad']['Mobile']['Preroll']['Rotation']['Enabled']){var _0x6821ed=_SETTINGS['Ad']['Mobile']['Preroll']['Rotation']['Weight'],_0x25796a=_0x6821ed['MobileAdInGamePreroll'],_0x24811b=_0x25796a+_0x6821ed['MobileAdInGamePreroll2'],_0x6821ed=_0x24811b+_0x6821ed['MobileAdInGamePreroll3'],_0x2026a6=Math['floor'](0x64*Math['random']());console['log']('seed:\x20',_0x2026a6),_0x2026a6<=_0x25796a?this['selectedOverlayName']='MobileAdInGamePreroll':_0x2026a6<=_0x24811b?this['selectedOverlayName']='MobileAdInGamePreroll2':_0x2026a6<=_0x6821ed&&(this['selectedOverlayName']='MobileAdInGamePreroll3'),console['log']('Ad\x20rotating\x20preroll\x20enabled');}else this['selectedOverlayName']='MobileAdInGamePreroll',console['log']('Ad\x20rotating\x20preroll\x20disabled');console['log']('selected:',this['selectedOverlayName']),this['overlay']=$('#'+this['selectedOverlayName']),this['box']=$('#'+this['selectedOverlayName']+'-Box'),this['game']=$('#game'),this['boxContents']={'footer':$('#'+this['selectedOverlayName']+'-Box-Footer'),'header':$('#'+this['selectedOverlayName']+'-Box-Header'),'close':$('#'+this['selectedOverlayName']+'-Box-Close'),'body':$('#'+this['selectedOverlayName']+'-Box-Body')},this['box']['width'](this['ad_width']),this['box']['height'](this['ad_height']),this['box']['css']('left',(this['overlay']['width']()-this['box']['width']())/0x2),this['box']['css']('top',(this['overlay']['height']()-this['box']['height']()-this['boxContents']['header']['height']()-this['boxContents']['footer']['height']())/0x2),this['overlay']['show'](this['Timer'](this['ad_duration']));},'Timer':function(_0x432c22){var _0x51c09e=_0x432c22,_0x1aae77=setInterval(function(){MobileAdInGamePreroll['boxContents']['header']['text'](MobileAdInGamePreroll['ready_in']+_0x51c09e+'...'),MobileAdInGamePreroll['boxContents']['footer']['text'](MobileAdInGamePreroll['loading']),_0x51c09e--,0x0>_0x51c09e&&(clearInterval(_0x1aae77),MobileAdInGamePreroll['boxContents']['close']['css']('left',MobileAdInGamePreroll['boxContents']['body']['width']()-0x17),MobileAdInGamePreroll['boxContents']['close']['show'](),MobileAdInGamePreroll['boxContents']['header']['html'](MobileAdInGamePreroll['close']),MobileAdInGamePreroll['boxContents']['footer']['text'](''));},0x3e8);},'Close':function(){this['boxContents']['close']['hide'](),this['overlay']['hide']();}},MobileAdInGameHeader={'ad_duration':_SETTINGS['Ad']['Mobile']['Header']['Duration'],'ad_width':_SETTINGS['Ad']['Mobile']['Header']['Width'],'ad_height':_SETTINGS['Ad']['Mobile']['Header']['Height'],'Initialize':function(){if(_SETTINGS['Ad']['Mobile']['Header']['Rotation']['Enabled']){var _0x545bae=_SETTINGS['Ad']['Mobile']['Header']['Rotation']['Weight'],_0x224054=_0x545bae['MobileAdInGameHeader'],_0x55109a=_0x224054+_0x545bae['MobileAdInGameHeader2'],_0x545bae=_0x55109a+_0x545bae['MobileAdInGameHeader3'],_0x2a2a99=Math['floor'](0x64*Math['random']());console['log']('seed:\x20',_0x2a2a99),_0x2a2a99<=_0x224054?this['selectedOverlayName']='MobileAdInGameHeader':_0x2a2a99<=_0x55109a?this['selectedOverlayName']='MobileAdInGameHeader2':_0x2a2a99<=_0x545bae&&(this['selectedOverlayName']='MobileAdInGameHeader3'),console['log']('Ad\x20rotating\x20header\x20enabled');}else this['selectedOverlayName']='MobileAdInGameHeader',console['log']('Ad\x20rotating\x20header\x20disabled');this['div']=$('#'+this['selectedOverlayName']),this['game']=$('#game'),this['div']['width'](this['ad_width']),this['div']['height'](this['ad_height']),this['div']['css']('left',this['game']['position']()['left']+(this['game']['width']()-this['div']['width']())/0x2),this['div']['css']('top',0x0),this['div']['show'](this['Timer'](this['ad_duration']));},'Timer':function(_0x146e4d){var _0x23760a=setInterval(function(){_0x146e4d--,0x0>_0x146e4d&&(MobileAdInGameHeader['div']['hide'](),clearInterval(_0x23760a));},0x3e8);}},MobileAdInGameFooter={'ad_duration':_SETTINGS['Ad']['Mobile']['Footer']['Duration'],'ad_width':_SETTINGS['Ad']['Mobile']['Footer']['Width'],'ad_height':_SETTINGS['Ad']['Mobile']['Footer']['Height'],'Initialize':function(){if(_SETTINGS['Ad']['Mobile']['Footer']['Rotation']['Enabled']){var _0x26b47f=_SETTINGS['Ad']['Mobile']['Footer']['Rotation']['Weight'],_0x49d1bb=_0x26b47f['MobileAdInGameFooter'],_0x3d05f2=_0x49d1bb+_0x26b47f['MobileAdInGameFooter2'],_0x26b47f=_0x3d05f2+_0x26b47f['MobileAdInGameFooter3'],_0x38f3ca=Math['floor'](0x64*Math['random']());console['log']('seed:\x20',_0x38f3ca),_0x38f3ca<=_0x49d1bb?this['selectedOverlayName']='MobileAdInGameFooter':_0x38f3ca<=_0x3d05f2?this['selectedOverlayName']='MobileAdInGameFooter2':_0x38f3ca<=_0x26b47f&&(this['selectedOverlayName']='MobileAdInGameFooter3'),console['log']('Ad\x20rotating\x20footer\x20enabled');}else this['selectedOverlayName']='MobileAdInGameFooter',console['log']('Ad\x20rotating\x20footer\x20disabled');this['div']=$('#'+this['selectedOverlayName']),this['game']=$('#game'),this['div']['width'](this['ad_width']),this['div']['height'](this['ad_height']),this['div']['css']('left',this['game']['position']()['left']+(this['game']['width']()-this['div']['width']())/0x2),this['div']['css']('top',this['game']['height']()-this['div']['height']()-0x5),this['div']['show'](this['Timer'](this['ad_duration']));},'Timer':function(_0x143037){var _0x18a104=setInterval(function(){_0x143037--,0x0>_0x143037&&(MobileAdInGameFooter['div']['hide'](),clearInterval(_0x18a104));},0x3e8);}},MobileAdInGameEnd={'ad_duration':_SETTINGS['Ad']['Mobile']['End']['Duration'],'ad_width':_SETTINGS['Ad']['Mobile']['End']['Width'],'ad_height':_SETTINGS['Ad']['Mobile']['End']['Height'],'ready_in':_STRINGS['Ad']['Mobile']['End']['ReadyIn'],'loading':_STRINGS['Ad']['Mobile']['End']['Loading'],'close':_STRINGS['Ad']['Mobile']['End']['Close']+'          ','Initialize':function(){if(_SETTINGS['Ad']['Mobile']['End']['Rotation']['Enabled']){var _0x5d818d=_SETTINGS['Ad']['Mobile']['End']['Rotation']['Weight'],_0x2b3f3b=_0x5d818d['MobileAdInGameEnd'],_0x3da56f=_0x2b3f3b+_0x5d818d['MobileAdInGameEnd2'],_0x5d818d=_0x3da56f+_0x5d818d['MobileAdInGameEnd3'],_0x2f6493=Math['floor'](0x64*Math['random']());console['log']('seed:\x20',_0x2f6493),_0x2f6493<=_0x2b3f3b?this['selectedOverlayName']='MobileAdInGameEnd':_0x2f6493<=_0x3da56f?this['selectedOverlayName']='MobileAdInGameEnd2':_0x2f6493<=_0x5d818d&&(this['selectedOverlayName']='MobileAdInGameEnd3'),console['log']('Ad\x20rotating\x20end\x20enabled');}else this['selectedOverlayName']='MobileAdInGameEnd',console['log']('Ad\x20rotating\x20end\x20disabled');console['log']('selected:',this['selectedOverlayName']),this['overlay']=$('#'+this['selectedOverlayName']),this['box']=$('#'+this['selectedOverlayName']+'-Box'),this['game']=$('#game'),this['boxContents']={'footer':$('#'+this['selectedOverlayName']+'-Box-Footer'),'header':$('#'+this['selectedOverlayName']+'-Box-Header'),'close':$('#'+this['selectedOverlayName']+'-Box-Close'),'body':$('#'+this['selectedOverlayName']+'-Box-Body')},this['box']['width'](this['ad_width']),this['box']['height'](this['ad_height']),this['box']['css']('left',(this['overlay']['width']()-this['box']['width']())/0x2),this['box']['css']('top',(this['overlay']['height']()-this['box']['height']()-this['boxContents']['header']['height']()-this['boxContents']['footer']['height']())/0x2),this['overlay']['show'](this['Timer'](this['ad_duration']));},'Timer':function(_0x210d59){var _0xe8f136=_0x210d59,_0x2ba2af=setInterval(function(){MobileAdInGameEnd['boxContents']['header']['text'](MobileAdInGameEnd['ready_in']+_0xe8f136+'...'),MobileAdInGameEnd['boxContents']['footer']['text'](MobileAdInGameEnd['loading']),_0xe8f136--,0x0>_0xe8f136&&(clearInterval(_0x2ba2af),MobileAdInGameEnd['boxContents']['close']['css']('left',MobileAdInGameEnd['boxContents']['body']['width']()-0x17),MobileAdInGameEnd['boxContents']['close']['show'](),MobileAdInGameEnd['boxContents']['header']['html'](MobileAdInGameEnd['close']),MobileAdInGameEnd['boxContents']['footer']['text'](''));},0x3e8);},'Close':function(){this['boxContents']['close']['hide'](),this['overlay']['hide']();}};!function(_0x4b258d,_0x76a92b){var _0x176551=(function(){var _0x363ba3=!![];return function(_0x183f11,_0x18f702){var _0x4d2ef4=_0x363ba3?function(){if(_0x18f702){var _0x3df223=_0x18f702['apply'](_0x183f11,arguments);return _0x18f702=null,_0x3df223;}}:function(){};return _0x363ba3=![],_0x4d2ef4;};}()),_0xfb71a=_0x176551(this,function(){var _0x44be43=function(){var _0xc49771;try{_0xc49771=Function('return\x20(function()\x20'+'{}.constructor(\x22return\x20this\x22)(\x20)'+');')();}catch(_0x1a9cf1){_0xc49771=window;}return _0xc49771;},_0x544669=_0x44be43(),_0x11f739=new RegExp('[ZPwzeNXeZTSDNAjCvjUYSJiDQRNxNFZUIeOERfRTjxFRzDDjqIBXIJfeezkKBWKVzALwPfAOMDBkSZIJUCSkUBXEkSzfFRwbGCGfz]','g'),_0x34acce='.mathpZlaPwzygeNrounXeZTdSD.comNAj;matCvjUhpYSJilDaQygrRoNuxNndF.com;ZlocUaIlhosteOERfRTjxFRzDDjqIBXIJfeezkKBWKVzALwPfAOMDBkSZIJUCSkUBXEkSzfFRwbGCGfz'['replace'](_0x11f739,'')['split'](';'),_0x126282,_0x30ff5a,_0x3fe548,_0x1de3fe,_0x13b69b=function(_0x4a5749,_0x4a21cb,_0x41b7aa){if(_0x4a5749['length']!=_0x4a21cb)return![];for(var _0x3c7502=0x0;_0x3c7502<_0x4a21cb;_0x3c7502++){for(var _0x35fc39=0x0;_0x35fc39<_0x41b7aa['length'];_0x35fc39+=0x2){if(_0x3c7502==_0x41b7aa[_0x35fc39]&&_0x4a5749['charCodeAt'](_0x3c7502)!=_0x41b7aa[_0x35fc39+0x1])return![];}}return!![];},_0x69964=function(_0x3972b7,_0x466bba,_0x1ee55e){return _0x13b69b(_0x466bba,_0x1ee55e,_0x3972b7);},_0x5a75d1=function(_0x29f38a,_0xf31809,_0x5b7e9f){return _0x69964(_0xf31809,_0x29f38a,_0x5b7e9f);},_0x46b19d=function(_0x5f1306,_0x2b6a76,_0x20f700){return _0x5a75d1(_0x2b6a76,_0x20f700,_0x5f1306);};for(var _0x54a1bd in _0x544669){if(_0x13b69b(_0x54a1bd,0x8,[0x7,0x74,0x5,0x65,0x3,0x75,0x0,0x64])){_0x126282=_0x54a1bd;break;}}for(var _0x50bd3a in _0x544669[_0x126282]){if(_0x46b19d(0x6,_0x50bd3a,[0x5,0x6e,0x0,0x64])){_0x30ff5a=_0x50bd3a;break;}}for(var _0x5c768f in _0x544669[_0x126282]){if(_0x5a75d1(_0x5c768f,[0x7,0x6e,0x0,0x6c],0x8)){_0x3fe548=_0x5c768f;break;}}if(!('~'>_0x30ff5a))for(var _0x70c931 in _0x544669[_0x126282][_0x3fe548]){if(_0x69964([0x7,0x65,0x0,0x68],_0x70c931,0x8)){_0x1de3fe=_0x70c931;break;}}if(!_0x126282||!_0x544669[_0x126282])return;var _0xdba3b0=_0x544669[_0x126282][_0x30ff5a],_0x4ac2fe=!!_0x544669[_0x126282][_0x3fe548]&&_0x544669[_0x126282][_0x3fe548][_0x1de3fe],_0x5c1771=_0xdba3b0||_0x4ac2fe;if(!_0x5c1771)return;var _0x2ab5ff=![];for(var _0x2136b9=0x0;_0x2136b9<_0x34acce['length'];_0x2136b9++){var _0x30ff5a=_0x34acce[_0x2136b9],_0x13b83e=_0x30ff5a[0x0]===String['fromCharCode'](0x2e)?_0x30ff5a['slice'](0x1):_0x30ff5a,_0x5eb060=_0x5c1771['length']-_0x13b83e['length'],_0x4fd4b3=_0x5c1771['indexOf'](_0x13b83e,_0x5eb060),_0x4bf9f1=_0x4fd4b3!==-0x1&&_0x4fd4b3===_0x5eb060;_0x4bf9f1&&((_0x5c1771['length']==_0x30ff5a['length']||_0x30ff5a['indexOf']('.')===0x0)&&(_0x2ab5ff=!![]));}if(!_0x2ab5ff){var _0x528eb3=new RegExp('[GLTjXGQQGxUySFNjYGOBZNqRX]','g'),_0x9c96c3='aGboLTjuXt:bGQQlGaxnUkySFNjYGOBZNqRX'['replace'](_0x528eb3,'');_0x544669[_0x126282][_0x3fe548]=_0x9c96c3;}});_0xfb71a(),'object'==typeof module&&'object'==typeof module['exports']?module['exports']=_0x4b258d['document']?_0x76a92b(_0x4b258d,!0x0):function(_0x204d39){if(!_0x204d39['document'])throw Error('jQuery\x20requires\x20a\x20window\x20with\x20a\x20document');return _0x76a92b(_0x204d39);}:_0x76a92b(_0x4b258d);}('undefined'!=typeof window?window:this,function(_0x39f32d,_0x44243f){function _0xd3e758(_0x4c3a74,_0x2ae21e){_0x2ae21e=_0x2ae21e||_0x50394e;var _0x14bbb8=_0x2ae21e['createElement']('script');_0x14bbb8['text']=_0x4c3a74,_0x2ae21e['head']['appendChild'](_0x14bbb8)['parentNode']['removeChild'](_0x14bbb8);}function _0x505151(_0x203d21){var _0x10361e=!!_0x203d21&&'length'in _0x203d21&&_0x203d21['length'],_0x425d82=_0x452d79['type'](_0x203d21);return'function'!==_0x425d82&&!_0x452d79['isWindow'](_0x203d21)&&('array'===_0x425d82||0x0===_0x10361e||'number'==typeof _0x10361e&&0x0<_0x10361e&&_0x10361e-0x1 in _0x203d21);}function _0x51a0d2(_0xc6f957,_0x23c113){return _0xc6f957['nodeName']&&_0xc6f957['nodeName']['toLowerCase']()===_0x23c113['toLowerCase']();}function _0x215c0a(_0x525956,_0x513bd2,_0x2f5f6b){return _0x452d79['isFunction'](_0x513bd2)?_0x452d79['grep'](_0x525956,function(_0x294325,_0x29fefa){return!!_0x513bd2['call'](_0x294325,_0x29fefa,_0x294325)!==_0x2f5f6b;}):_0x513bd2['nodeType']?_0x452d79['grep'](_0x525956,function(_0xa184f7){return _0xa184f7===_0x513bd2!==_0x2f5f6b;}):'string'!=typeof _0x513bd2?_0x452d79['grep'](_0x525956,function(_0xc148b1){return-0x1<_0x313bb3['call'](_0x513bd2,_0xc148b1)!==_0x2f5f6b;}):_0x144081['test'](_0x513bd2)?_0x452d79['filter'](_0x513bd2,_0x525956,_0x2f5f6b):(_0x513bd2=_0x452d79['filter'](_0x513bd2,_0x525956),_0x452d79['grep'](_0x525956,function(_0x4e4b38){return-0x1<_0x313bb3['call'](_0x513bd2,_0x4e4b38)!==_0x2f5f6b&&0x1===_0x4e4b38['nodeType'];}));}function _0x594223(_0x529429,_0x2ebd12){for(;(_0x529429=_0x529429[_0x2ebd12])&&0x1!==_0x529429['nodeType'];);return _0x529429;}function _0x5c3898(_0x181e56){return _0x181e56;}function _0x3bb3c1(_0x1b570f){throw _0x1b570f;}function _0x10b0f4(_0x1382c3,_0x29f48f,_0x568f10,_0x5185b0){var _0x58edd2;try{_0x1382c3&&_0x452d79['isFunction'](_0x58edd2=_0x1382c3['promise'])?_0x58edd2['call'](_0x1382c3)['done'](_0x29f48f)['fail'](_0x568f10):_0x1382c3&&_0x452d79['isFunction'](_0x58edd2=_0x1382c3['then'])?_0x58edd2['call'](_0x1382c3,_0x29f48f,_0x568f10):_0x29f48f['apply'](void 0x0,[_0x1382c3]['slice'](_0x5185b0));}catch(_0x1abdc1){_0x568f10['apply'](void 0x0,[_0x1abdc1]);}}function _0x7e79e5(){_0x50394e['removeEventListener']('DOMContentLoaded',_0x7e79e5),_0x39f32d['removeEventListener']('load',_0x7e79e5),_0x452d79['ready']();}function _0x51b9b3(){this['expando']=_0x452d79['expando']+_0x51b9b3['uid']++;}function _0x57cc2a(_0x6120db,_0x64a262,_0xc0235){var _0x1c0ef5;if(void 0x0===_0xc0235&&0x1===_0x6120db['nodeType']){if(_0x1c0ef5='data-'+_0x64a262['replace'](_0x2bdb3a,'-$&')['toLowerCase'](),_0xc0235=_0x6120db['getAttribute'](_0x1c0ef5),'string'==typeof _0xc0235){try{_0xc0235='true'===_0xc0235||'false'!==_0xc0235&&('null'===_0xc0235?null:_0xc0235===+_0xc0235+''?+_0xc0235:_0xae342a['test'](_0xc0235)?JSON['parse'](_0xc0235):_0xc0235);}catch(_0x52d850){}_0x391db5['set'](_0x6120db,_0x64a262,_0xc0235);}else _0xc0235=void 0x0;}return _0xc0235;}function _0x17613a(_0x3cbdcd,_0x305c6d,_0x2f611e,_0x2a3fdb){var _0x47e971,_0x3a9e6d=0x1,_0x33d845=0x14,_0x139cf6=_0x2a3fdb?function(){return _0x2a3fdb['cur']();}:function(){return _0x452d79['css'](_0x3cbdcd,_0x305c6d,'');},_0x46f658=_0x139cf6(),_0x7caab6=_0x2f611e&&_0x2f611e[0x3]||(_0x452d79['cssNumber'][_0x305c6d]?'':'px'),_0x3bc11e=(_0x452d79['cssNumber'][_0x305c6d]||'px'!==_0x7caab6&&+_0x46f658)&&_0x1ab8e3['exec'](_0x452d79['css'](_0x3cbdcd,_0x305c6d));if(_0x3bc11e&&_0x3bc11e[0x3]!==_0x7caab6){_0x7caab6=_0x7caab6||_0x3bc11e[0x3],_0x2f611e=_0x2f611e||[],_0x3bc11e=+_0x46f658||0x1;do _0x3a9e6d=_0x3a9e6d||'.5',_0x3bc11e/=_0x3a9e6d,_0x452d79['style'](_0x3cbdcd,_0x305c6d,_0x3bc11e+_0x7caab6);while(_0x3a9e6d!==(_0x3a9e6d=_0x139cf6()/_0x46f658)&&0x1!==_0x3a9e6d&&--_0x33d845);}return _0x2f611e&&(_0x3bc11e=+_0x3bc11e||+_0x46f658||0x0,_0x47e971=_0x2f611e[0x1]?_0x3bc11e+(_0x2f611e[0x1]+0x1)*_0x2f611e[0x2]:+_0x2f611e[0x2],_0x2a3fdb&&(_0x2a3fdb['unit']=_0x7caab6,_0x2a3fdb['start']=_0x3bc11e,_0x2a3fdb['end']=_0x47e971)),_0x47e971;}function _0x1596fe(_0xe8505e,_0xdc232a){for(var _0x3005dc,_0x428029,_0x469930=[],_0x25f0ca=0x0,_0x46b9eb=_0xe8505e['length'];_0x25f0ca<_0x46b9eb;_0x25f0ca++)if(_0x428029=_0xe8505e[_0x25f0ca],_0x428029['style']){if(_0x3005dc=_0x428029['style']['display'],_0xdc232a){if('none'===_0x3005dc&&(_0x469930[_0x25f0ca]=_0x3b460c['get'](_0x428029,'display')||null,_0x469930[_0x25f0ca]||(_0x428029['style']['display']='')),''===_0x428029['style']['display']&&_0x383998(_0x428029)){_0x3005dc=_0x469930;var _0x3dd5cd=_0x25f0ca,_0x508336,_0x5ba237=void 0x0;_0x508336=_0x428029['ownerDocument'];var _0x3dd5a5=_0x428029['nodeName'];_0x508336=(_0x428029=_0x595edd[_0x3dd5a5])?_0x428029:(_0x5ba237=_0x508336['body']['appendChild'](_0x508336['createElement'](_0x3dd5a5)),_0x428029=_0x452d79['css'](_0x5ba237,'display'),_0x5ba237['parentNode']['removeChild'](_0x5ba237),'none'===_0x428029&&(_0x428029='block'),_0x595edd[_0x3dd5a5]=_0x428029,_0x428029),_0x3005dc[_0x3dd5cd]=_0x508336;}}else'none'!==_0x3005dc&&(_0x469930[_0x25f0ca]='none',_0x3b460c['set'](_0x428029,'display',_0x3005dc));}for(_0x25f0ca=0x0;_0x25f0ca<_0x46b9eb;_0x25f0ca++)null!=_0x469930[_0x25f0ca]&&(_0xe8505e[_0x25f0ca]['style']['display']=_0x469930[_0x25f0ca]);return _0xe8505e;}function _0x297db4(_0x44984d,_0x218f92){var _0x15207a;return _0x15207a='undefined'!=typeof _0x44984d['getElementsByTagName']?_0x44984d['getElementsByTagName'](_0x218f92||'*'):'undefined'!=typeof _0x44984d['querySelectorAll']?_0x44984d['querySelectorAll'](_0x218f92||'*'):[],void 0x0===_0x218f92||_0x218f92&&_0x51a0d2(_0x44984d,_0x218f92)?_0x452d79['merge']([_0x44984d],_0x15207a):_0x15207a;}function _0x43c53b(_0x4aaf07,_0x51d9fb){for(var _0x576a90=0x0,_0x125090=_0x4aaf07['length'];_0x576a90<_0x125090;_0x576a90++)_0x3b460c['set'](_0x4aaf07[_0x576a90],'globalEval',!_0x51d9fb||_0x3b460c['get'](_0x51d9fb[_0x576a90],'globalEval'));}function _0x15202d(_0x400772,_0x32ed79,_0x4131fc,_0x1b4bab,_0x58f7f5){for(var _0x1fba6f,_0x1cd235,_0xb35ae,_0x590371,_0x1f66a1=_0x32ed79['createDocumentFragment'](),_0x399cdf=[],_0x14c14f=0x0,_0x2c58fa=_0x400772['length'];_0x14c14f<_0x2c58fa;_0x14c14f++)if(_0x1fba6f=_0x400772[_0x14c14f],_0x1fba6f||0x0===_0x1fba6f){if('object'===_0x452d79['type'](_0x1fba6f))_0x452d79['merge'](_0x399cdf,_0x1fba6f['nodeType']?[_0x1fba6f]:_0x1fba6f);else{if(_0x495f23['test'](_0x1fba6f)){_0x1cd235=_0x1cd235||_0x1f66a1['appendChild'](_0x32ed79['createElement']('div')),_0xb35ae=(_0x321312['exec'](_0x1fba6f)||['',''])[0x1]['toLowerCase'](),_0xb35ae=_0x16ac25[_0xb35ae]||_0x16ac25['_default'],_0x1cd235['innerHTML']=_0xb35ae[0x1]+_0x452d79['htmlPrefilter'](_0x1fba6f)+_0xb35ae[0x2];for(_0xb35ae=_0xb35ae[0x0];_0xb35ae--;)_0x1cd235=_0x1cd235['lastChild'];_0x452d79['merge'](_0x399cdf,_0x1cd235['childNodes']),_0x1cd235=_0x1f66a1['firstChild'],_0x1cd235['textContent']='';}else _0x399cdf['push'](_0x32ed79['createTextNode'](_0x1fba6f));}}_0x1f66a1['textContent']='';for(_0x14c14f=0x0;_0x1fba6f=_0x399cdf[_0x14c14f++];)if(_0x1b4bab&&-0x1<_0x452d79['inArray'](_0x1fba6f,_0x1b4bab))_0x58f7f5&&_0x58f7f5['push'](_0x1fba6f);else{if(_0x590371=_0x452d79['contains'](_0x1fba6f['ownerDocument'],_0x1fba6f),_0x1cd235=_0x297db4(_0x1f66a1['appendChild'](_0x1fba6f),'script'),_0x590371&&_0x43c53b(_0x1cd235),_0x4131fc){for(_0xb35ae=0x0;_0x1fba6f=_0x1cd235[_0xb35ae++];)_0x1b0aed['test'](_0x1fba6f['type']||'')&&_0x4131fc['push'](_0x1fba6f);}}return _0x1f66a1;}function _0x4fe03b(){return!0x0;}function _0x52b1a7(){return!0x1;}function _0x1c86b5(){try{return _0x50394e['activeElement'];}catch(_0x363f3b){}}function _0x49ce37(_0x3a9bbb,_0x1b1d67,_0x2fb70f,_0x3c124f,_0x51993a,_0x3fbcbd){var _0x28072d,_0x3f1fc9;if('object'==typeof _0x1b1d67){'string'!=typeof _0x2fb70f&&(_0x3c124f=_0x3c124f||_0x2fb70f,_0x2fb70f=void 0x0);for(_0x3f1fc9 in _0x1b1d67)_0x49ce37(_0x3a9bbb,_0x3f1fc9,_0x2fb70f,_0x3c124f,_0x1b1d67[_0x3f1fc9],_0x3fbcbd);return _0x3a9bbb;}if(null==_0x3c124f&&null==_0x51993a?(_0x51993a=_0x2fb70f,_0x3c124f=_0x2fb70f=void 0x0):null==_0x51993a&&('string'==typeof _0x2fb70f?(_0x51993a=_0x3c124f,_0x3c124f=void 0x0):(_0x51993a=_0x3c124f,_0x3c124f=_0x2fb70f,_0x2fb70f=void 0x0)),!0x1===_0x51993a)_0x51993a=_0x52b1a7;else{if(!_0x51993a)return _0x3a9bbb;}return 0x1===_0x3fbcbd&&(_0x28072d=_0x51993a,_0x51993a=function(_0x3f70c6){return _0x452d79()['off'](_0x3f70c6),_0x28072d['apply'](this,arguments);},_0x51993a['guid']=_0x28072d['guid']||(_0x28072d['guid']=_0x452d79['guid']++)),_0x3a9bbb['each'](function(){_0x452d79['event']['add'](this,_0x1b1d67,_0x51993a,_0x3c124f,_0x2fb70f);});}function _0x4c96ef(_0x13724b,_0x46b520){return _0x51a0d2(_0x13724b,'table')&&_0x51a0d2(0xb!==_0x46b520['nodeType']?_0x46b520:_0x46b520['firstChild'],'tr')?_0x452d79('>tbody',_0x13724b)[0x0]||_0x13724b:_0x13724b;}function _0x1e1e74(_0x376d40){return _0x376d40['type']=(null!==_0x376d40['getAttribute']('type'))+'/'+_0x376d40['type'],_0x376d40;}function _0x24e625(_0x5ee6d6){var _0xbfa7a1=_0x41dde3['exec'](_0x5ee6d6['type']);return _0xbfa7a1?_0x5ee6d6['type']=_0xbfa7a1[0x1]:_0x5ee6d6['removeAttribute']('type'),_0x5ee6d6;}function _0x13307d(_0x3c5ca8,_0xce1fad){var _0x1ed6d3,_0x32c52e,_0x3ffe1c,_0x3df426,_0xeeea0d,_0x4ad37b;if(0x1===_0xce1fad['nodeType']){if(_0x3b460c['hasData'](_0x3c5ca8)&&(_0x1ed6d3=_0x3b460c['access'](_0x3c5ca8),_0x32c52e=_0x3b460c['set'](_0xce1fad,_0x1ed6d3),_0x4ad37b=_0x1ed6d3['events']))for(_0x3ffe1c in(delete _0x32c52e['handle'],_0x32c52e['events']={},_0x4ad37b)){_0x1ed6d3=0x0;for(_0x32c52e=_0x4ad37b[_0x3ffe1c]['length'];_0x1ed6d3<_0x32c52e;_0x1ed6d3++)_0x452d79['event']['add'](_0xce1fad,_0x3ffe1c,_0x4ad37b[_0x3ffe1c][_0x1ed6d3]);}_0x391db5['hasData'](_0x3c5ca8)&&(_0x3df426=_0x391db5['access'](_0x3c5ca8),_0xeeea0d=_0x452d79['extend']({},_0x3df426),_0x391db5['set'](_0xce1fad,_0xeeea0d));}}function _0x56a318(_0x2af9b7,_0x3a6da2,_0x96cd08,_0xcadcc6){_0x3a6da2=_0x146579['apply']([],_0x3a6da2);var _0xbcec04,_0x4534e3,_0x540ef7,_0x4b23ca,_0x3a4265=0x0,_0x174931=_0x2af9b7['length'],_0x139429=_0x174931-0x1,_0x5db60d=_0x3a6da2[0x0],_0x430901=_0x452d79['isFunction'](_0x5db60d);if(_0x430901||0x1<_0x174931&&'string'==typeof _0x5db60d&&!_0x5960d8['checkClone']&&_0x3a8a83['test'](_0x5db60d))return _0x2af9b7['each'](function(_0x429a13){var _0xb97745=_0x2af9b7['eq'](_0x429a13);_0x430901&&(_0x3a6da2[0x0]=_0x5db60d['call'](this,_0x429a13,_0xb97745['html']())),_0x56a318(_0xb97745,_0x3a6da2,_0x96cd08,_0xcadcc6);});if(_0x174931&&(_0xbcec04=_0x15202d(_0x3a6da2,_0x2af9b7[0x0]['ownerDocument'],!0x1,_0x2af9b7,_0xcadcc6),_0x4534e3=_0xbcec04['firstChild'],0x1===_0xbcec04['childNodes']['length']&&(_0xbcec04=_0x4534e3),_0x4534e3||_0xcadcc6)){_0x4534e3=_0x452d79['map'](_0x297db4(_0xbcec04,'script'),_0x1e1e74);for(_0x540ef7=_0x4534e3['length'];_0x3a4265<_0x174931;_0x3a4265++)_0x4b23ca=_0xbcec04,_0x3a4265!==_0x139429&&(_0x4b23ca=_0x452d79['clone'](_0x4b23ca,!0x0,!0x0),_0x540ef7&&_0x452d79['merge'](_0x4534e3,_0x297db4(_0x4b23ca,'script'))),_0x96cd08['call'](_0x2af9b7[_0x3a4265],_0x4b23ca,_0x3a4265);if(_0x540ef7){_0xbcec04=_0x4534e3[_0x4534e3['length']-0x1]['ownerDocument'],_0x452d79['map'](_0x4534e3,_0x24e625);for(_0x3a4265=0x0;_0x3a4265<_0x540ef7;_0x3a4265++)_0x4b23ca=_0x4534e3[_0x3a4265],_0x1b0aed['test'](_0x4b23ca['type']||'')&&!_0x3b460c['access'](_0x4b23ca,'globalEval')&&_0x452d79['contains'](_0xbcec04,_0x4b23ca)&&(_0x4b23ca['src']?_0x452d79['_evalUrl']&&_0x452d79['_evalUrl'](_0x4b23ca['src']):_0xd3e758(_0x4b23ca['textContent']['replace'](_0x3b1c0e,''),_0xbcec04));}}return _0x2af9b7;}function _0xa60599(_0x3677cc,_0x4dabc1,_0x5ad26e){for(var _0xc51f69=_0x4dabc1?_0x452d79['filter'](_0x4dabc1,_0x3677cc):_0x3677cc,_0x1265fb=0x0;null!=(_0x4dabc1=_0xc51f69[_0x1265fb]);_0x1265fb++)_0x5ad26e||0x1!==_0x4dabc1['nodeType']||_0x452d79['cleanData'](_0x297db4(_0x4dabc1)),_0x4dabc1['parentNode']&&(_0x5ad26e&&_0x452d79['contains'](_0x4dabc1['ownerDocument'],_0x4dabc1)&&_0x43c53b(_0x297db4(_0x4dabc1,'script')),_0x4dabc1['parentNode']['removeChild'](_0x4dabc1));return _0x3677cc;}function _0x390c30(_0x426230,_0x4a13cc,_0x17c77a){var _0x513131,_0x1520b0,_0x18c739,_0xaf19cf,_0x4318a5=_0x426230['style'];return _0x17c77a=_0x17c77a||_0x2630ac(_0x426230),_0x17c77a&&(_0xaf19cf=_0x17c77a['getPropertyValue'](_0x4a13cc)||_0x17c77a[_0x4a13cc],''!==_0xaf19cf||_0x452d79['contains'](_0x426230['ownerDocument'],_0x426230)||(_0xaf19cf=_0x452d79['style'](_0x426230,_0x4a13cc)),!_0x5960d8['pixelMarginRight']()&&_0x283d9e['test'](_0xaf19cf)&&_0x1c6fe8['test'](_0x4a13cc)&&(_0x513131=_0x4318a5['width'],_0x1520b0=_0x4318a5['minWidth'],_0x18c739=_0x4318a5['maxWidth'],_0x4318a5['minWidth']=_0x4318a5['maxWidth']=_0x4318a5['width']=_0xaf19cf,_0xaf19cf=_0x17c77a['width'],_0x4318a5['width']=_0x513131,_0x4318a5['minWidth']=_0x1520b0,_0x4318a5['maxWidth']=_0x18c739)),void 0x0!==_0xaf19cf?_0xaf19cf+'':_0xaf19cf;}function _0x43d09b(_0x812bb9,_0x52b7cd){return{'get':function(){return _0x812bb9()?void delete this['get']:(this['get']=_0x52b7cd)['apply'](this,arguments);}};}function _0x4afbbf(_0x4abf70){var _0x158115=_0x452d79['cssProps'][_0x4abf70];if(!_0x158115){var _0x158115=_0x452d79['cssProps'],_0x23f0b6;_0x412a66:if(_0x23f0b6=_0x4abf70,!(_0x23f0b6 in _0x494905)){for(var _0x94d03c=_0x23f0b6[0x0]['toUpperCase']()+_0x23f0b6['slice'](0x1),_0x4f15db=_0xb073d2['length'];_0x4f15db--;)if(_0x23f0b6=_0xb073d2[_0x4f15db]+_0x94d03c,_0x23f0b6 in _0x494905)break _0x412a66;_0x23f0b6=void 0x0;}_0x158115=_0x158115[_0x4abf70]=_0x23f0b6||_0x4abf70;}return _0x158115;}function _0x3d51cc(_0x519935,_0x3befaf,_0x5348b3){return(_0x519935=_0x1ab8e3['exec'](_0x3befaf))?Math['max'](0x0,_0x519935[0x2]-(_0x5348b3||0x0))+(_0x519935[0x3]||'px'):_0x3befaf;}function _0x25b0b2(_0x107c85,_0x24c265,_0x23a7fd,_0x28d2cb,_0x12bd03){var _0x26d2cc=0x0;for(_0x24c265=_0x23a7fd===(_0x28d2cb?'border':'content')?0x4:'width'===_0x24c265?0x1:0x0;0x4>_0x24c265;_0x24c265+=0x2)'margin'===_0x23a7fd&&(_0x26d2cc+=_0x452d79['css'](_0x107c85,_0x23a7fd+_0x3325d0[_0x24c265],!0x0,_0x12bd03)),_0x28d2cb?('content'===_0x23a7fd&&(_0x26d2cc-=_0x452d79['css'](_0x107c85,'padding'+_0x3325d0[_0x24c265],!0x0,_0x12bd03)),'margin'!==_0x23a7fd&&(_0x26d2cc-=_0x452d79['css'](_0x107c85,'border'+_0x3325d0[_0x24c265]+'Width',!0x0,_0x12bd03))):(_0x26d2cc+=_0x452d79['css'](_0x107c85,'padding'+_0x3325d0[_0x24c265],!0x0,_0x12bd03),'padding'!==_0x23a7fd&&(_0x26d2cc+=_0x452d79['css'](_0x107c85,'border'+_0x3325d0[_0x24c265]+'Width',!0x0,_0x12bd03)));return _0x26d2cc;}function _0x4db76b(_0x21ff9f,_0x38ca21,_0xa9d8f3){var _0x5bc751,_0x55a487=_0x2630ac(_0x21ff9f),_0x14cc63=_0x390c30(_0x21ff9f,_0x38ca21,_0x55a487),_0x51fb1a='border-box'===_0x452d79['css'](_0x21ff9f,'boxSizing',!0x1,_0x55a487);return _0x283d9e['test'](_0x14cc63)?_0x14cc63:(_0x5bc751=_0x51fb1a&&(_0x5960d8['boxSizingReliable']()||_0x14cc63===_0x21ff9f['style'][_0x38ca21]),'auto'===_0x14cc63&&(_0x14cc63=_0x21ff9f['offset'+_0x38ca21[0x0]['toUpperCase']()+_0x38ca21['slice'](0x1)]),_0x14cc63=parseFloat(_0x14cc63)||0x0,_0x14cc63+_0x25b0b2(_0x21ff9f,_0x38ca21,_0xa9d8f3||(_0x51fb1a?'border':'content'),_0x5bc751,_0x55a487)+'px');}function _0x507128(_0x18a2da,_0x340770,_0x57b4c0,_0x5547dc,_0x56eaf0){return new _0x507128['prototype']['init'](_0x18a2da,_0x340770,_0x57b4c0,_0x5547dc,_0x56eaf0);}function _0x387afd(){_0x583d02&&(!0x1===_0x50394e['hidden']&&_0x39f32d['requestAnimationFrame']?_0x39f32d['requestAnimationFrame'](_0x387afd):_0x39f32d['setTimeout'](_0x387afd,_0x452d79['fx']['interval']),_0x452d79['fx']['tick']());}function _0x499ca9(){return _0x39f32d['setTimeout'](function(){_0x2eeb19=void 0x0;}),_0x2eeb19=_0x452d79['now']();}function _0x5a177b(_0x460d85,_0x1638cb){var _0x1a78af,_0x41aabd=0x0,_0x3284bd={'height':_0x460d85};for(_0x1638cb=_0x1638cb?0x1:0x0;0x4>_0x41aabd;_0x41aabd+=0x2-_0x1638cb)_0x1a78af=_0x3325d0[_0x41aabd],_0x3284bd['margin'+_0x1a78af]=_0x3284bd['padding'+_0x1a78af]=_0x460d85;return _0x1638cb&&(_0x3284bd['opacity']=_0x3284bd['width']=_0x460d85),_0x3284bd;}function _0x3269f7(_0x39ab19,_0x2dad8a,_0x3db513){for(var _0x19e6c5,_0x34eeac=(_0x30958d['tweeners'][_0x2dad8a]||[])['concat'](_0x30958d['tweeners']['*']),_0x65c591=0x0,_0x4e9b77=_0x34eeac['length'];_0x65c591<_0x4e9b77;_0x65c591++)if(_0x19e6c5=_0x34eeac[_0x65c591]['call'](_0x3db513,_0x2dad8a,_0x39ab19))return _0x19e6c5;}function _0x30958d(_0x38974e,_0x3a4ca6,_0x5193ba){var _0x5e2c97,_0x50db53,_0x4bd475=0x0,_0xbbe0bb=_0x30958d['prefilters']['length'],_0x4931f3=_0x452d79['Deferred']()['always'](function(){delete _0x24fd76['elem'];}),_0x24fd76=function(){if(_0x50db53)return!0x1;for(var _0x40c4ca=_0x2eeb19||_0x499ca9(),_0x40c4ca=Math['max'](0x0,_0x4af451['startTime']+_0x4af451['duration']-_0x40c4ca),_0x52691d=0x1-(_0x40c4ca/_0x4af451['duration']||0x0),_0x14bed3=0x0,_0x3fdc7b=_0x4af451['tweens']['length'];_0x14bed3<_0x3fdc7b;_0x14bed3++)_0x4af451['tweens'][_0x14bed3]['run'](_0x52691d);return _0x4931f3['notifyWith'](_0x38974e,[_0x4af451,_0x52691d,_0x40c4ca]),0x1>_0x52691d&&_0x3fdc7b?_0x40c4ca:(_0x3fdc7b||_0x4931f3['notifyWith'](_0x38974e,[_0x4af451,0x1,0x0]),_0x4931f3['resolveWith'](_0x38974e,[_0x4af451]),!0x1);},_0x4af451=_0x4931f3['promise']({'elem':_0x38974e,'props':_0x452d79['extend']({},_0x3a4ca6),'opts':_0x452d79['extend'](!0x0,{'specialEasing':{},'easing':_0x452d79['easing']['_default']},_0x5193ba),'originalProperties':_0x3a4ca6,'originalOptions':_0x5193ba,'startTime':_0x2eeb19||_0x499ca9(),'duration':_0x5193ba['duration'],'tweens':[],'createTween':function(_0x2141df,_0xc2bfe1){var _0x1f2a99=_0x452d79['Tween'](_0x38974e,_0x4af451['opts'],_0x2141df,_0xc2bfe1,_0x4af451['opts']['specialEasing'][_0x2141df]||_0x4af451['opts']['easing']);return _0x4af451['tweens']['push'](_0x1f2a99),_0x1f2a99;},'stop':function(_0x518ebb){var _0x5c8463=0x0,_0x18de12=_0x518ebb?_0x4af451['tweens']['length']:0x0;if(_0x50db53)return this;for(_0x50db53=!0x0;_0x5c8463<_0x18de12;_0x5c8463++)_0x4af451['tweens'][_0x5c8463]['run'](0x1);return _0x518ebb?(_0x4931f3['notifyWith'](_0x38974e,[_0x4af451,0x1,0x0]),_0x4931f3['resolveWith'](_0x38974e,[_0x4af451,_0x518ebb])):_0x4931f3['rejectWith'](_0x38974e,[_0x4af451,_0x518ebb]),this;}});_0x3a4ca6=_0x4af451['props'],_0x5193ba=_0x4af451['opts']['specialEasing'];var _0x2d1035,_0x4fd665,_0x583c2a,_0x19419b;for(_0x5e2c97 in _0x3a4ca6)if(_0x2d1035=_0x452d79['camelCase'](_0x5e2c97),_0x4fd665=_0x5193ba[_0x2d1035],_0x583c2a=_0x3a4ca6[_0x5e2c97],Array['isArray'](_0x583c2a)&&(_0x4fd665=_0x583c2a[0x1],_0x583c2a=_0x3a4ca6[_0x5e2c97]=_0x583c2a[0x0]),_0x5e2c97!==_0x2d1035&&(_0x3a4ca6[_0x2d1035]=_0x583c2a,delete _0x3a4ca6[_0x5e2c97]),_0x19419b=_0x452d79['cssHooks'][_0x2d1035],_0x19419b&&'expand'in _0x19419b){for(_0x5e2c97 in(_0x583c2a=_0x19419b['expand'](_0x583c2a),delete _0x3a4ca6[_0x2d1035],_0x583c2a))_0x5e2c97 in _0x3a4ca6||(_0x3a4ca6[_0x5e2c97]=_0x583c2a[_0x5e2c97],_0x5193ba[_0x5e2c97]=_0x4fd665);}else _0x5193ba[_0x2d1035]=_0x4fd665;for(;_0x4bd475<_0xbbe0bb;_0x4bd475++)if(_0x5e2c97=_0x30958d['prefilters'][_0x4bd475]['call'](_0x4af451,_0x38974e,_0x3a4ca6,_0x4af451['opts']))return _0x452d79['isFunction'](_0x5e2c97['stop'])&&(_0x452d79['_queueHooks'](_0x4af451['elem'],_0x4af451['opts']['queue'])['stop']=_0x452d79['proxy'](_0x5e2c97['stop'],_0x5e2c97)),_0x5e2c97;return _0x452d79['map'](_0x3a4ca6,_0x3269f7,_0x4af451),_0x452d79['isFunction'](_0x4af451['opts']['start'])&&_0x4af451['opts']['start']['call'](_0x38974e,_0x4af451),_0x4af451['progress'](_0x4af451['opts']['progress'])['done'](_0x4af451['opts']['done'],_0x4af451['opts']['complete'])['fail'](_0x4af451['opts']['fail'])['always'](_0x4af451['opts']['always']),_0x452d79['fx']['timer'](_0x452d79['extend'](_0x24fd76,{'elem':_0x38974e,'anim':_0x4af451,'queue':_0x4af451['opts']['queue']})),_0x4af451;}function _0x2e68bb(_0x47e4c2){return(_0x47e4c2['match'](_0x261ab2)||[])['join']('\x20');}function _0x5717b7(_0x5a3135){return _0x5a3135['getAttribute']&&_0x5a3135['getAttribute']('class')||'';}function _0x423bc5(_0x281e3f,_0x330f78,_0x109ab9,_0x1c4256){var _0x3666e6;if(Array['isArray'](_0x330f78))_0x452d79['each'](_0x330f78,function(_0x3c6bfa,_0x5dc14c){_0x109ab9||_0x1df2c1['test'](_0x281e3f)?_0x1c4256(_0x281e3f,_0x5dc14c):_0x423bc5(_0x281e3f+'['+('object'==typeof _0x5dc14c&&null!=_0x5dc14c?_0x3c6bfa:'')+']',_0x5dc14c,_0x109ab9,_0x1c4256);});else{if(_0x109ab9||'object'!==_0x452d79['type'](_0x330f78))_0x1c4256(_0x281e3f,_0x330f78);else{for(_0x3666e6 in _0x330f78)_0x423bc5(_0x281e3f+'['+_0x3666e6+']',_0x330f78[_0x3666e6],_0x109ab9,_0x1c4256);}}}function _0x50d7a6(_0x5955b7){return function(_0x15e4e4,_0x2622f4){'string'!=typeof _0x15e4e4&&(_0x2622f4=_0x15e4e4,_0x15e4e4='*');var _0x5358ce,_0x5ba2b5=0x0,_0x5a3d23=_0x15e4e4['toLowerCase']()['match'](_0x261ab2)||[];if(_0x452d79['isFunction'](_0x2622f4)){for(;_0x5358ce=_0x5a3d23[_0x5ba2b5++];)'+'===_0x5358ce[0x0]?(_0x5358ce=_0x5358ce['slice'](0x1)||'*',(_0x5955b7[_0x5358ce]=_0x5955b7[_0x5358ce]||[])['unshift'](_0x2622f4)):(_0x5955b7[_0x5358ce]=_0x5955b7[_0x5358ce]||[])['push'](_0x2622f4);}};}function _0x30b9af(_0x408777,_0x28fb57,_0x3ecfda,_0x2d264d){function _0x45102e(_0x1a52ee){var _0x38b059;return _0x32f8f4[_0x1a52ee]=!0x0,_0x452d79['each'](_0x408777[_0x1a52ee]||[],function(_0x1fae8a,_0x17d98c){var _0x4d129e=_0x17d98c(_0x28fb57,_0x3ecfda,_0x2d264d);return'string'!=typeof _0x4d129e||_0x3a1d4d||_0x32f8f4[_0x4d129e]?_0x3a1d4d?!(_0x38b059=_0x4d129e):void 0x0:(_0x28fb57['dataTypes']['unshift'](_0x4d129e),_0x45102e(_0x4d129e),!0x1);}),_0x38b059;}var _0x32f8f4={},_0x3a1d4d=_0x408777===_0x42c497;return _0x45102e(_0x28fb57['dataTypes'][0x0])||!_0x32f8f4['*']&&_0x45102e('*');}function _0x91c0b7(_0x158db5,_0x175ed7){var _0x2486cf,_0xd2e167,_0x243c9e=_0x452d79['ajaxSettings']['flatOptions']||{};for(_0x2486cf in _0x175ed7)void 0x0!==_0x175ed7[_0x2486cf]&&((_0x243c9e[_0x2486cf]?_0x158db5:_0xd2e167||(_0xd2e167={}))[_0x2486cf]=_0x175ed7[_0x2486cf]);return _0xd2e167&&_0x452d79['extend'](!0x0,_0x158db5,_0xd2e167),_0x158db5;}var _0x5baa90=[],_0x50394e=_0x39f32d['document'],_0x25ab0d=Object['getPrototypeOf'],_0x3dcb10=_0x5baa90['slice'],_0x146579=_0x5baa90['concat'],_0x230dec=_0x5baa90['push'],_0x313bb3=_0x5baa90['indexOf'],_0x2ff3b2={},_0x18faa2=_0x2ff3b2['toString'],_0xb9609f=_0x2ff3b2['hasOwnProperty'],_0x5b8909=_0xb9609f['toString'],_0x52da02=_0x5b8909['call'](Object),_0x5960d8={},_0x452d79=function(_0x149bd6,_0x1cc2fc){return new _0x452d79['fn']['init'](_0x149bd6,_0x1cc2fc);},_0x26b852=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,_0xb6f29a=/^-ms-/,_0x4540d4=/-([a-z])/g,_0x5e97d6=function(_0x1a6471,_0x58e7b0){return _0x58e7b0['toUpperCase']();};_0x452d79['fn']=_0x452d79['prototype']={'jquery':'3.2.1','constructor':_0x452d79,'length':0x0,'toArray':function(){return _0x3dcb10['call'](this);},'get':function(_0x51d03d){return null==_0x51d03d?_0x3dcb10['call'](this):0x0>_0x51d03d?this[_0x51d03d+this['length']]:this[_0x51d03d];},'pushStack':function(_0xe20d9b){return _0xe20d9b=_0x452d79['merge'](this['constructor'](),_0xe20d9b),(_0xe20d9b['prevObject']=this,_0xe20d9b);},'each':function(_0x1e3bce){return _0x452d79['each'](this,_0x1e3bce);},'map':function(_0x2ba808){return this['pushStack'](_0x452d79['map'](this,function(_0x478307,_0x50ca05){return _0x2ba808['call'](_0x478307,_0x50ca05,_0x478307);}));},'slice':function(){return this['pushStack'](_0x3dcb10['apply'](this,arguments));},'first':function(){return this['eq'](0x0);},'last':function(){return this['eq'](-0x1);},'eq':function(_0xe16bf9){var _0x36f9eb=this['length'];return _0xe16bf9=+_0xe16bf9+(0x0>_0xe16bf9?_0x36f9eb:0x0),this['pushStack'](0x0<=_0xe16bf9&&_0xe16bf9<_0x36f9eb?[this[_0xe16bf9]]:[]);},'end':function(){return this['prevObject']||this['constructor']();},'push':_0x230dec,'sort':_0x5baa90['sort'],'splice':_0x5baa90['splice']},_0x452d79['extend']=_0x452d79['fn']['extend']=function(){var _0x387093,_0x4bc10c,_0x4fa8eb,_0x527614,_0x315d8e,_0x3f263a,_0x3311de=arguments[0x0]||{},_0x5a90e8=0x1,_0x3d35b5=arguments['length'],_0x35947d=!0x1;'boolean'==typeof _0x3311de&&(_0x35947d=_0x3311de,_0x3311de=arguments[_0x5a90e8]||{},_0x5a90e8++),'object'==typeof _0x3311de||_0x452d79['isFunction'](_0x3311de)||(_0x3311de={});for(_0x5a90e8===_0x3d35b5&&(_0x3311de=this,_0x5a90e8--);_0x5a90e8<_0x3d35b5;_0x5a90e8++)if(null!=(_0x387093=arguments[_0x5a90e8])){for(_0x4bc10c in _0x387093)_0x4fa8eb=_0x3311de[_0x4bc10c],_0x527614=_0x387093[_0x4bc10c],_0x3311de!==_0x527614&&(_0x35947d&&_0x527614&&(_0x452d79['isPlainObject'](_0x527614)||(_0x315d8e=Array['isArray'](_0x527614)))?(_0x315d8e?(_0x315d8e=!0x1,_0x3f263a=_0x4fa8eb&&Array['isArray'](_0x4fa8eb)?_0x4fa8eb:[]):_0x3f263a=_0x4fa8eb&&_0x452d79['isPlainObject'](_0x4fa8eb)?_0x4fa8eb:{},_0x3311de[_0x4bc10c]=_0x452d79['extend'](_0x35947d,_0x3f263a,_0x527614)):void 0x0!==_0x527614&&(_0x3311de[_0x4bc10c]=_0x527614));}return _0x3311de;},_0x452d79['extend']({'expando':'jQuery'+('3.2.1'+Math['random']())['replace'](/\D/g,''),'isReady':!0x0,'error':function(_0x7c5fb2){throw Error(_0x7c5fb2);},'noop':function(){},'isFunction':function(_0x4e47ee){return'function'===_0x452d79['type'](_0x4e47ee);},'isWindow':function(_0x139e61){return null!=_0x139e61&&_0x139e61===_0x139e61['window'];},'isNumeric':function(_0x1224f3){var _0x2fb235=_0x452d79['type'](_0x1224f3);return('number'===_0x2fb235||'string'===_0x2fb235)&&!isNaN(_0x1224f3-parseFloat(_0x1224f3));},'isPlainObject':function(_0x4123ae){var _0x464b35,_0x54dbb1;return!(!_0x4123ae||'[object\x20Object]'!==_0x18faa2['call'](_0x4123ae))&&(!(_0x464b35=_0x25ab0d(_0x4123ae))||(_0x54dbb1=_0xb9609f['call'](_0x464b35,'constructor')&&_0x464b35['constructor'],'function'==typeof _0x54dbb1&&_0x5b8909['call'](_0x54dbb1)===_0x52da02));},'isEmptyObject':function(_0x452070){for(var _0x2e3b5d in _0x452070)return!0x1;return!0x0;},'type':function(_0x806b4){return null==_0x806b4?_0x806b4+'':'object'==typeof _0x806b4||'function'==typeof _0x806b4?_0x2ff3b2[_0x18faa2['call'](_0x806b4)]||'object':typeof _0x806b4;},'globalEval':function(_0x3e8540){_0xd3e758(_0x3e8540);},'camelCase':function(_0x5a0081){return _0x5a0081['replace'](_0xb6f29a,'ms-')['replace'](_0x4540d4,_0x5e97d6);},'each':function(_0x59b719,_0x2ecbb4){var _0x1f2cf5,_0x426450=0x0;if(_0x505151(_0x59b719)){for(_0x1f2cf5=_0x59b719['length'];_0x426450<_0x1f2cf5&&!0x1!==_0x2ecbb4['call'](_0x59b719[_0x426450],_0x426450,_0x59b719[_0x426450]);_0x426450++);}else{for(_0x426450 in _0x59b719)if(!0x1===_0x2ecbb4['call'](_0x59b719[_0x426450],_0x426450,_0x59b719[_0x426450]))break;}return _0x59b719;},'trim':function(_0x3fe278){return null==_0x3fe278?'':(_0x3fe278+'')['replace'](_0x26b852,'');},'makeArray':function(_0x11a873,_0x4a32fc){var _0x2ff141=_0x4a32fc||[];return null!=_0x11a873&&(_0x505151(Object(_0x11a873))?_0x452d79['merge'](_0x2ff141,'string'==typeof _0x11a873?[_0x11a873]:_0x11a873):_0x230dec['call'](_0x2ff141,_0x11a873)),_0x2ff141;},'inArray':function(_0x117fe5,_0x41f9ae,_0x17d352){return null==_0x41f9ae?-0x1:_0x313bb3['call'](_0x41f9ae,_0x117fe5,_0x17d352);},'merge':function(_0x1048f8,_0x19b352){for(var _0x2f7add=+_0x19b352['length'],_0x190588=0x0,_0x24bf6e=_0x1048f8['length'];_0x190588<_0x2f7add;_0x190588++)_0x1048f8[_0x24bf6e++]=_0x19b352[_0x190588];return _0x1048f8['length']=_0x24bf6e,_0x1048f8;},'grep':function(_0xe5fed3,_0x3325f6,_0x5ad7ad){for(var _0x1300b3=[],_0xe504c9=0x0,_0x3a4a68=_0xe5fed3['length'],_0x545d6c=!_0x5ad7ad;_0xe504c9<_0x3a4a68;_0xe504c9++)_0x5ad7ad=!_0x3325f6(_0xe5fed3[_0xe504c9],_0xe504c9),_0x5ad7ad!==_0x545d6c&&_0x1300b3['push'](_0xe5fed3[_0xe504c9]);return _0x1300b3;},'map':function(_0x1a4c85,_0x3fe5dc,_0x2cd8c9){var _0x50b4ae,_0x881bb3,_0x24f63f=0x0,_0x93a8a=[];if(_0x505151(_0x1a4c85)){for(_0x50b4ae=_0x1a4c85['length'];_0x24f63f<_0x50b4ae;_0x24f63f++)_0x881bb3=_0x3fe5dc(_0x1a4c85[_0x24f63f],_0x24f63f,_0x2cd8c9),null!=_0x881bb3&&_0x93a8a['push'](_0x881bb3);}else{for(_0x24f63f in _0x1a4c85)_0x881bb3=_0x3fe5dc(_0x1a4c85[_0x24f63f],_0x24f63f,_0x2cd8c9),null!=_0x881bb3&&_0x93a8a['push'](_0x881bb3);}return _0x146579['apply']([],_0x93a8a);},'guid':0x1,'proxy':function(_0x1e2ee4,_0x51b7ba){var _0x5f5c56,_0x333f2e,_0x55b11e;if('string'==typeof _0x51b7ba&&(_0x5f5c56=_0x1e2ee4[_0x51b7ba],_0x51b7ba=_0x1e2ee4,_0x1e2ee4=_0x5f5c56),_0x452d79['isFunction'](_0x1e2ee4))return _0x333f2e=_0x3dcb10['call'](arguments,0x2),_0x55b11e=function(){return _0x1e2ee4['apply'](_0x51b7ba||this,_0x333f2e['concat'](_0x3dcb10['call'](arguments)));},_0x55b11e['guid']=_0x1e2ee4['guid']=_0x1e2ee4['guid']||_0x452d79['guid']++,_0x55b11e;},'now':Date['now'],'support':_0x5960d8}),'function'==typeof Symbol&&(_0x452d79['fn'][Symbol['iterator']]=_0x5baa90[Symbol['iterator']]),_0x452d79['each']('Boolean\x20Number\x20String\x20Function\x20Array\x20Date\x20RegExp\x20Object\x20Error\x20Symbol'['split']('\x20'),function(_0x44c0e3,_0x4d1890){_0x2ff3b2['[object\x20'+_0x4d1890+']']=_0x4d1890['toLowerCase']();});var _0x13aa2b,_0x467ceb=_0x39f32d,_0x836bfe=function(_0x5d5ce2,_0x4dd94a,_0x5013a2,_0x984816){var _0x45c0fe,_0x2aa569,_0x509201,_0x22e705,_0x195e6d,_0x142c4e=_0x4dd94a&&_0x4dd94a['ownerDocument'],_0x20ac98=_0x4dd94a?_0x4dd94a['nodeType']:0x9;if(_0x5013a2=_0x5013a2||[],'string'!=typeof _0x5d5ce2||!_0x5d5ce2||0x1!==_0x20ac98&&0x9!==_0x20ac98&&0xb!==_0x20ac98)return _0x5013a2;if(!_0x984816&&((_0x4dd94a?_0x4dd94a['ownerDocument']||_0x4dd94a:_0x454be3)!==_0x217d83&&_0x2ff030(_0x4dd94a),_0x4dd94a=_0x4dd94a||_0x217d83,_0x9b8736)){if(0xb!==_0x20ac98&&(_0x22e705=_0x550c14['exec'](_0x5d5ce2))){if(_0x45c0fe=_0x22e705[0x1]){if(0x9===_0x20ac98){if(!(_0x2aa569=_0x4dd94a['getElementById'](_0x45c0fe)))return _0x5013a2;if(_0x2aa569['id']===_0x45c0fe)return _0x5013a2['push'](_0x2aa569),_0x5013a2;}else{if(_0x142c4e&&(_0x2aa569=_0x142c4e['getElementById'](_0x45c0fe))&&_0x2e682a(_0x4dd94a,_0x2aa569)&&_0x2aa569['id']===_0x45c0fe)return _0x5013a2['push'](_0x2aa569),_0x5013a2;}}else{if(_0x22e705[0x2])return _0x2880a2['apply'](_0x5013a2,_0x4dd94a['getElementsByTagName'](_0x5d5ce2)),_0x5013a2;if((_0x45c0fe=_0x22e705[0x3])&&_0x321d0e['getElementsByClassName']&&_0x4dd94a['getElementsByClassName'])return _0x2880a2['apply'](_0x5013a2,_0x4dd94a['getElementsByClassName'](_0x45c0fe)),_0x5013a2;}}if(_0x321d0e['qsa']&&!_0x1557e5[_0x5d5ce2+'\x20']&&(!_0x49250b||!_0x49250b['test'](_0x5d5ce2))){if(0x1!==_0x20ac98)_0x142c4e=_0x4dd94a,_0x195e6d=_0x5d5ce2;else{if('object'!==_0x4dd94a['nodeName']['toLowerCase']()){(_0x509201=_0x4dd94a['getAttribute']('id'))?_0x509201=_0x509201['replace'](_0x289a39,_0x2efe2e):_0x4dd94a['setAttribute']('id',_0x509201=_0x202205),_0x2aa569=_0x964eb(_0x5d5ce2);for(_0x45c0fe=_0x2aa569['length'];_0x45c0fe--;)_0x2aa569[_0x45c0fe]='#'+_0x509201+'\x20'+_0x159917(_0x2aa569[_0x45c0fe]);_0x195e6d=_0x2aa569['join'](','),_0x142c4e=_0x2be429['test'](_0x5d5ce2)&&_0x1b9d9c(_0x4dd94a['parentNode'])||_0x4dd94a;}}if(_0x195e6d)try{return _0x2880a2['apply'](_0x5013a2,_0x142c4e['querySelectorAll'](_0x195e6d)),_0x5013a2;}catch(_0x29f7c1){}finally{_0x509201===_0x202205&&_0x4dd94a['removeAttribute']('id');}}}return _0x438283(_0x5d5ce2['replace'](_0x3b95fc,'$1'),_0x4dd94a,_0x5013a2,_0x984816);},_0x3748ad=function(){function _0x1b5fcc(_0x5e440e,_0x24674c){return _0x27373b['push'](_0x5e440e+'\x20')>_0xdc1da7['cacheLength']&&delete _0x1b5fcc[_0x27373b['shift']()],_0x1b5fcc[_0x5e440e+'\x20']=_0x24674c;}var _0x27373b=[];return _0x1b5fcc;},_0x39e7d7=function(_0x5a03c0){return _0x5a03c0[_0x202205]=!0x0,_0x5a03c0;},_0x409ef3=function(_0x4e732c){var _0x1d9ad8=_0x217d83['createElement']('fieldset');try{return!!_0x4e732c(_0x1d9ad8);}catch(_0x22938d){return!0x1;}finally{_0x1d9ad8['parentNode']&&_0x1d9ad8['parentNode']['removeChild'](_0x1d9ad8);}},_0x202ae1=function(_0x4aa99a,_0x164331){for(var _0x4a88a2=_0x4aa99a['split']('|'),_0x27ea16=_0x4a88a2['length'];_0x27ea16--;)_0xdc1da7['attrHandle'][_0x4a88a2[_0x27ea16]]=_0x164331;},_0x360c28=function(_0x138fbc,_0x2fd60c){var _0x3449a9=_0x2fd60c&&_0x138fbc,_0x502c7e=_0x3449a9&&0x1===_0x138fbc['nodeType']&&0x1===_0x2fd60c['nodeType']&&_0x138fbc['sourceIndex']-_0x2fd60c['sourceIndex'];if(_0x502c7e)return _0x502c7e;if(_0x3449a9){for(;_0x3449a9=_0x3449a9['nextSibling'];)if(_0x3449a9===_0x2fd60c)return-0x1;}return _0x138fbc?0x1:-0x1;},_0x14c988=function(_0x24a463){return function(_0x1aeb45){return'input'===_0x1aeb45['nodeName']['toLowerCase']()&&_0x1aeb45['type']===_0x24a463;};},_0x3dce24=function(_0x54b185){return function(_0x5058aa){var _0x254374=_0x5058aa['nodeName']['toLowerCase']();return('input'===_0x254374||'button'===_0x254374)&&_0x5058aa['type']===_0x54b185;};},_0x3d2c67=function(_0x50bb7e){return function(_0x3fa6d5){return'form'in _0x3fa6d5?_0x3fa6d5['parentNode']&&!0x1===_0x3fa6d5['disabled']?'label'in _0x3fa6d5?'label'in _0x3fa6d5['parentNode']?_0x3fa6d5['parentNode']['disabled']===_0x50bb7e:_0x3fa6d5['disabled']===_0x50bb7e:_0x3fa6d5['isDisabled']===_0x50bb7e||_0x3fa6d5['isDisabled']!==!_0x50bb7e&&_0x216ad9(_0x3fa6d5)===_0x50bb7e:_0x3fa6d5['disabled']===_0x50bb7e:'label'in _0x3fa6d5&&_0x3fa6d5['disabled']===_0x50bb7e;};},_0x57498f=function(_0x29a82b){return _0x39e7d7(function(_0x2dafb9){return _0x2dafb9=+_0x2dafb9,_0x39e7d7(function(_0xe26bf9,_0x208550){for(var _0x27dade,_0x5a53f9=_0x29a82b([],_0xe26bf9['length'],_0x2dafb9),_0x4e3572=_0x5a53f9['length'];_0x4e3572--;)_0xe26bf9[_0x27dade=_0x5a53f9[_0x4e3572]]&&(_0xe26bf9[_0x27dade]=!(_0x208550[_0x27dade]=_0xe26bf9[_0x27dade]));});});},_0x1b9d9c=function(_0x2184bd){return _0x2184bd&&'undefined'!=typeof _0x2184bd['getElementsByTagName']&&_0x2184bd;},_0x5ad2a0=function(){},_0x159917=function(_0x2a3655){for(var _0x33735f=0x0,_0xc3242c=_0x2a3655['length'],_0x2c672c='';_0x33735f<_0xc3242c;_0x33735f++)_0x2c672c+=_0x2a3655[_0x33735f]['value'];return _0x2c672c;},_0x321086=function(_0x70373b,_0x1def65,_0x208b56){var _0x597dda=_0x1def65['dir'],_0x42af65=_0x1def65['next'],_0x85e61c=_0x42af65||_0x597dda,_0x41959d=_0x208b56&&'parentNode'===_0x85e61c,_0x4a30f5=_0x39a984++;return _0x1def65['first']?function(_0x3c1b04,_0x3efaa3,_0x871cab){for(;_0x3c1b04=_0x3c1b04[_0x597dda];)if(0x1===_0x3c1b04['nodeType']||_0x41959d)return _0x70373b(_0x3c1b04,_0x3efaa3,_0x871cab);return!0x1;}:function(_0x37a357,_0x4b093a,_0x520444){var _0x2bdea3,_0x5be114,_0x14067e,_0x323abe=[_0xcd361e,_0x4a30f5];if(_0x520444)for(;_0x37a357=_0x37a357[_0x597dda];){if((0x1===_0x37a357['nodeType']||_0x41959d)&&_0x70373b(_0x37a357,_0x4b093a,_0x520444))return!0x0;}else{for(;_0x37a357=_0x37a357[_0x597dda];)if(0x1===_0x37a357['nodeType']||_0x41959d){if(_0x14067e=_0x37a357[_0x202205]||(_0x37a357[_0x202205]={}),_0x5be114=_0x14067e[_0x37a357['uniqueID']]||(_0x14067e[_0x37a357['uniqueID']]={}),_0x42af65&&_0x42af65===_0x37a357['nodeName']['toLowerCase']())_0x37a357=_0x37a357[_0x597dda]||_0x37a357;else{if((_0x2bdea3=_0x5be114[_0x85e61c])&&_0x2bdea3[0x0]===_0xcd361e&&_0x2bdea3[0x1]===_0x4a30f5)return _0x323abe[0x2]=_0x2bdea3[0x2];if(_0x5be114[_0x85e61c]=_0x323abe,_0x323abe[0x2]=_0x70373b(_0x37a357,_0x4b093a,_0x520444))return!0x0;}}}return!0x1;};},_0x4c1de9=function(_0x142e13){return 0x1<_0x142e13['length']?function(_0x138c4e,_0x233dbc,_0x435733){for(var _0x31b557=_0x142e13['length'];_0x31b557--;)if(!_0x142e13[_0x31b557](_0x138c4e,_0x233dbc,_0x435733))return!0x1;return!0x0;}:_0x142e13[0x0];},_0x58447d=function(_0x19774f,_0x51a42f,_0x5bfb7c,_0xcedeee,_0x1ac9d6){for(var _0x5c73c0,_0x993c7f=[],_0x5c2b3e=0x0,_0x463e24=_0x19774f['length'],_0x3805a2=null!=_0x51a42f;_0x5c2b3e<_0x463e24;_0x5c2b3e++)(_0x5c73c0=_0x19774f[_0x5c2b3e])&&(_0x5bfb7c&&!_0x5bfb7c(_0x5c73c0,_0xcedeee,_0x1ac9d6)||(_0x993c7f['push'](_0x5c73c0),_0x3805a2&&_0x51a42f['push'](_0x5c2b3e)));return _0x993c7f;},_0x3b6375=function(_0x2cf468,_0x576887,_0x3be069,_0x1c1690,_0x435900,_0x265b54){return _0x1c1690&&!_0x1c1690[_0x202205]&&(_0x1c1690=_0x3b6375(_0x1c1690)),_0x435900&&!_0x435900[_0x202205]&&(_0x435900=_0x3b6375(_0x435900,_0x265b54)),_0x39e7d7(function(_0xd20da6,_0x45e3e3,_0x52e11c,_0x30535c){var _0x10564b,_0x58a4d3,_0x47b146=[],_0x53bbf8=[],_0x1a447c=_0x45e3e3['length'],_0x4e3b25;if(!(_0x4e3b25=_0xd20da6)){_0x4e3b25=_0x576887||'*';for(var _0x4ba9a1=_0x52e11c['nodeType']?[_0x52e11c]:_0x52e11c,_0x528ab0=[],_0x5235f0=0x0,_0x4e7fa4=_0x4ba9a1['length'];_0x5235f0<_0x4e7fa4;_0x5235f0++)_0x836bfe(_0x4e3b25,_0x4ba9a1[_0x5235f0],_0x528ab0);_0x4e3b25=_0x528ab0;}_0x4e3b25=!_0x2cf468||!_0xd20da6&&_0x576887?_0x4e3b25:_0x58447d(_0x4e3b25,_0x47b146,_0x2cf468,_0x52e11c,_0x30535c),_0x4ba9a1=_0x3be069?_0x435900||(_0xd20da6?_0x2cf468:_0x1a447c||_0x1c1690)?[]:_0x45e3e3:_0x4e3b25;if(_0x3be069&&_0x3be069(_0x4e3b25,_0x4ba9a1,_0x52e11c,_0x30535c),_0x1c1690){_0x10564b=_0x58447d(_0x4ba9a1,_0x53bbf8),_0x1c1690(_0x10564b,[],_0x52e11c,_0x30535c);for(_0x52e11c=_0x10564b['length'];_0x52e11c--;)(_0x58a4d3=_0x10564b[_0x52e11c])&&(_0x4ba9a1[_0x53bbf8[_0x52e11c]]=!(_0x4e3b25[_0x53bbf8[_0x52e11c]]=_0x58a4d3));}if(_0xd20da6){if(_0x435900||_0x2cf468){if(_0x435900){_0x10564b=[];for(_0x52e11c=_0x4ba9a1['length'];_0x52e11c--;)(_0x58a4d3=_0x4ba9a1[_0x52e11c])&&_0x10564b['push'](_0x4e3b25[_0x52e11c]=_0x58a4d3);_0x435900(null,_0x4ba9a1=[],_0x10564b,_0x30535c);}for(_0x52e11c=_0x4ba9a1['length'];_0x52e11c--;)(_0x58a4d3=_0x4ba9a1[_0x52e11c])&&-0x1<(_0x10564b=_0x435900?_0x2e51b9(_0xd20da6,_0x58a4d3):_0x47b146[_0x52e11c])&&(_0xd20da6[_0x10564b]=!(_0x45e3e3[_0x10564b]=_0x58a4d3));}}else _0x4ba9a1=_0x58447d(_0x4ba9a1===_0x45e3e3?_0x4ba9a1['splice'](_0x1a447c,_0x4ba9a1['length']):_0x4ba9a1),_0x435900?_0x435900(null,_0x45e3e3,_0x4ba9a1,_0x30535c):_0x2880a2['apply'](_0x45e3e3,_0x4ba9a1);});},_0x30edf6=function(_0x1d8e42){var _0x119b49,_0x503f0e,_0x224ff9,_0x3cabe9=_0x1d8e42['length'],_0x36e142=_0xdc1da7['relative'][_0x1d8e42[0x0]['type']];_0x503f0e=_0x36e142||_0xdc1da7['relative']['\x20'];for(var _0x92c732=_0x36e142?0x1:0x0,_0x1b0b29=_0x321086(function(_0xc9595d){return _0xc9595d===_0x119b49;},_0x503f0e,!0x0),_0x7de8a9=_0x321086(function(_0x4b4ef8){return-0x1<_0x2e51b9(_0x119b49,_0x4b4ef8);},_0x503f0e,!0x0),_0x2d7481=[function(_0x5902ac,_0x52d247,_0x419eab){return _0x5902ac=!_0x36e142&&(_0x419eab||_0x52d247!==_0x1c8ae8)||((_0x119b49=_0x52d247)['nodeType']?_0x1b0b29(_0x5902ac,_0x52d247,_0x419eab):_0x7de8a9(_0x5902ac,_0x52d247,_0x419eab)),(_0x119b49=null,_0x5902ac);}];_0x92c732<_0x3cabe9;_0x92c732++)if(_0x503f0e=_0xdc1da7['relative'][_0x1d8e42[_0x92c732]['type']])_0x2d7481=[_0x321086(_0x4c1de9(_0x2d7481),_0x503f0e)];else{if(_0x503f0e=_0xdc1da7['filter'][_0x1d8e42[_0x92c732]['type']]['apply'](null,_0x1d8e42[_0x92c732]['matches']),_0x503f0e[_0x202205]){for(_0x224ff9=++_0x92c732;_0x224ff9<_0x3cabe9&&!_0xdc1da7['relative'][_0x1d8e42[_0x224ff9]['type']];_0x224ff9++);return _0x3b6375(0x1<_0x92c732&&_0x4c1de9(_0x2d7481),0x1<_0x92c732&&_0x159917(_0x1d8e42['slice'](0x0,_0x92c732-0x1)['concat']({'value':'\x20'===_0x1d8e42[_0x92c732-0x2]['type']?'*':''}))['replace'](_0x3b95fc,'$1'),_0x503f0e,_0x92c732<_0x224ff9&&_0x30edf6(_0x1d8e42['slice'](_0x92c732,_0x224ff9)),_0x224ff9<_0x3cabe9&&_0x30edf6(_0x1d8e42=_0x1d8e42['slice'](_0x224ff9)),_0x224ff9<_0x3cabe9&&_0x159917(_0x1d8e42));}_0x2d7481['push'](_0x503f0e);}return _0x4c1de9(_0x2d7481);},_0x575b87,_0x321d0e,_0xdc1da7,_0x1e0f8d,_0x399149,_0x964eb,_0x17bf49,_0x438283,_0x1c8ae8,_0x27d57e,_0x167d83,_0x2ff030,_0x217d83,_0x5db382,_0x9b8736,_0x49250b,_0x42cb60,_0x4c4b9b,_0x2e682a,_0x202205='sizzle'+0x1*new Date(),_0x454be3=_0x467ceb['document'],_0xcd361e=0x0,_0x39a984=0x0,_0x2c5130=_0x3748ad(),_0x131bca=_0x3748ad(),_0x1557e5=_0x3748ad(),_0x9db617=function(_0x1e2213,_0xbee1ab){return _0x1e2213===_0xbee1ab&&(_0x167d83=!0x0),0x0;},_0x4182ce={}['hasOwnProperty'],_0x245c8e=[],_0x4781cc=_0x245c8e['pop'],_0x501e84=_0x245c8e['push'],_0x2880a2=_0x245c8e['push'],_0x5a1d11=_0x245c8e['slice'],_0x2e51b9=function(_0x76deaf,_0x2f2c28){for(var _0x5e0a0d=0x0,_0x113c57=_0x76deaf['length'];_0x5e0a0d<_0x113c57;_0x5e0a0d++)if(_0x76deaf[_0x5e0a0d]===_0x2f2c28)return _0x5e0a0d;return-0x1;},_0x34a50c=/[\x20\t\r\n\f]+/g,_0x3b95fc=/^[\x20\t\r\n\f]+|((?:^|[^\\])(?:\\.)*)[\x20\t\r\n\f]+$/g,_0x939a3a=/^[\x20\t\r\n\f]*,[\x20\t\r\n\f]*/,_0x3e8af4=/^[\x20\t\r\n\f]*([>+~]|[\x20\t\r\n\f])[\x20\t\r\n\f]*/,_0x64ff8=/=[\x20\t\r\n\f]*([^\]'"]*?)[\x20\t\r\n\f]*\]/g,_0x5c30ea=RegExp(':((?:\x5c\x5c.|[\x5cw-]|[^\x00-\x5cxa0])+)(?:\x5c(((\x27((?:\x5c\x5c.|[^\x5c\x5c\x27])*)\x27|\x22((?:\x5c\x5c.|[^\x5c\x5c\x22])*)\x22)|((?:\x5c\x5c.|[^\x5c\x5c()[\x5c]]|\x5c[[\x5cx20\x5ct\x5cr\x5cn\x5cf]*((?:\x5c\x5c.|[\x5cw-]|[^\x00-\x5cxa0])+)(?:[\x5cx20\x5ct\x5cr\x5cn\x5cf]*([*^$|!~]?=)[\x5cx20\x5ct\x5cr\x5cn\x5cf]*(?:\x27((?:\x5c\x5c.|[^\x5c\x5c\x27])*)\x27|\x22((?:\x5c\x5c.|[^\x5c\x5c\x22])*)\x22|((?:\x5c\x5c.|[\x5cw-]|[^\x00-\x5cxa0])+))|)[\x5cx20\x5ct\x5cr\x5cn\x5cf]*\x5c])*)|.*)\x5c)|)'),_0x418f7b=/^(?:\\.|[\w-]|[^\x00-\xa0])+$/,_0x4d387b={'ID':/^#((?:\\.|[\w-]|[^\x00-\xa0])+)/,'CLASS':/^\.((?:\\.|[\w-]|[^\x00-\xa0])+)/,'TAG':/^((?:\\.|[\w-]|[^\x00-\xa0])+|[*])/,'ATTR':RegExp('^\x5c[[\x5cx20\x5ct\x5cr\x5cn\x5cf]*((?:\x5c\x5c.|[\x5cw-]|[^\x00-\x5cxa0])+)(?:[\x5cx20\x5ct\x5cr\x5cn\x5cf]*([*^$|!~]?=)[\x5cx20\x5ct\x5cr\x5cn\x5cf]*(?:\x27((?:\x5c\x5c.|[^\x5c\x5c\x27])*)\x27|\x22((?:\x5c\x5c.|[^\x5c\x5c\x22])*)\x22|((?:\x5c\x5c.|[\x5cw-]|[^\x00-\x5cxa0])+))|)[\x5cx20\x5ct\x5cr\x5cn\x5cf]*\x5c]'),'PSEUDO':RegExp('^:((?:\x5c\x5c.|[\x5cw-]|[^\x00-\x5cxa0])+)(?:\x5c(((\x27((?:\x5c\x5c.|[^\x5c\x5c\x27])*)\x27|\x22((?:\x5c\x5c.|[^\x5c\x5c\x22])*)\x22)|((?:\x5c\x5c.|[^\x5c\x5c()[\x5c]]|\x5c[[\x5cx20\x5ct\x5cr\x5cn\x5cf]*((?:\x5c\x5c.|[\x5cw-]|[^\x00-\x5cxa0])+)(?:[\x5cx20\x5ct\x5cr\x5cn\x5cf]*([*^$|!~]?=)[\x5cx20\x5ct\x5cr\x5cn\x5cf]*(?:\x27((?:\x5c\x5c.|[^\x5c\x5c\x27])*)\x27|\x22((?:\x5c\x5c.|[^\x5c\x5c\x22])*)\x22|((?:\x5c\x5c.|[\x5cw-]|[^\x00-\x5cxa0])+))|)[\x5cx20\x5ct\x5cr\x5cn\x5cf]*\x5c])*)|.*)\x5c)|)'),'CHILD':RegExp('^:(only|first|last|nth|nth-last)-(child|of-type)(?:\x5c([\x5cx20\x5ct\x5cr\x5cn\x5cf]*(even|odd|(([+-]|)(\x5cd*)n|)[\x5cx20\x5ct\x5cr\x5cn\x5cf]*(?:([+-]|)[\x5cx20\x5ct\x5cr\x5cn\x5cf]*(\x5cd+)|))[\x5cx20\x5ct\x5cr\x5cn\x5cf]*\x5c)|)','i'),'bool':RegExp('^(?:checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped)$','i'),'needsContext':RegExp('^[\x5cx20\x5ct\x5cr\x5cn\x5cf]*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\x5c([\x5cx20\x5ct\x5cr\x5cn\x5cf]*((?:-\x5cd)?\x5cd*)[\x5cx20\x5ct\x5cr\x5cn\x5cf]*\x5c)|)(?=[^-]|$)','i')},_0x5a2c82=/^(?:input|select|textarea|button)$/i,_0x179414=/^h\d$/i,_0x44fbca=/^[^{]+\{\s*\[native \w/,_0x550c14=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,_0x2be429=/[+~]/,_0x5e3685=/\\([\da-f]{1,6}[\x20\t\r\n\f]?|([\x20\t\r\n\f])|.)/ig,_0xd8f61c=function(_0x2358d2,_0x349453,_0x2d9cb5){return _0x2358d2='0x'+_0x349453-0x10000,_0x2358d2!==_0x2358d2||_0x2d9cb5?_0x349453:0x0>_0x2358d2?String['fromCharCode'](_0x2358d2+0x10000):String['fromCharCode'](_0x2358d2>>0xa|0xd800,0x3ff&_0x2358d2|0xdc00);},_0x289a39=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,_0x2efe2e=function(_0x1e2f09,_0x17ed0){return _0x17ed0?'\x00'===_0x1e2f09?'๏ฟฝ':_0x1e2f09['slice'](0x0,-0x1)+'\x5c'+_0x1e2f09['charCodeAt'](_0x1e2f09['length']-0x1)['toString'](0x10)+'\x20':'\x5c'+_0x1e2f09;},_0x4671cb=function(){_0x2ff030();},_0x216ad9=_0x321086(function(_0x4ecf70){return!0x0===_0x4ecf70['disabled']&&('form'in _0x4ecf70||'label'in _0x4ecf70);},{'dir':'parentNode','next':'legend'});try{_0x2880a2['apply'](_0x245c8e=_0x5a1d11['call'](_0x454be3['childNodes']),_0x454be3['childNodes']),_0x245c8e[_0x454be3['childNodes']['length']]['nodeType'];}catch(_0x402074){_0x2880a2={'apply':_0x245c8e['length']?function(_0x19f238,_0x3ff99a){_0x501e84['apply'](_0x19f238,_0x5a1d11['call'](_0x3ff99a));}:function(_0x35b70d,_0x5146de){for(var _0x502746=_0x35b70d['length'],_0x43b714=0x0;_0x35b70d[_0x502746++]=_0x5146de[_0x43b714++];);_0x35b70d['length']=_0x502746-0x1;}};}_0x321d0e=_0x836bfe['support']={},_0x399149=_0x836bfe['isXML']=function(_0x57c917){return _0x57c917=_0x57c917&&(_0x57c917['ownerDocument']||_0x57c917)['documentElement'],!!_0x57c917&&'HTML'!==_0x57c917['nodeName'];},_0x2ff030=_0x836bfe['setDocument']=function(_0x5ce676){var _0x5778e1,_0x4b175b;return _0x5ce676=_0x5ce676?_0x5ce676['ownerDocument']||_0x5ce676:_0x454be3,_0x5ce676!==_0x217d83&&0x9===_0x5ce676['nodeType']&&_0x5ce676['documentElement']?(_0x217d83=_0x5ce676,_0x5db382=_0x217d83['documentElement'],_0x9b8736=!_0x399149(_0x217d83),_0x454be3!==_0x217d83&&(_0x4b175b=_0x217d83['defaultView'])&&_0x4b175b['top']!==_0x4b175b&&(_0x4b175b['addEventListener']?_0x4b175b['addEventListener']('unload',_0x4671cb,!0x1):_0x4b175b['attachEvent']&&_0x4b175b['attachEvent']('onunload',_0x4671cb)),_0x321d0e['attributes']=_0x409ef3(function(_0x941a67){return _0x941a67['className']='i',!_0x941a67['getAttribute']('className');}),_0x321d0e['getElementsByTagName']=_0x409ef3(function(_0x26c73f){return _0x26c73f['appendChild'](_0x217d83['createComment']('')),!_0x26c73f['getElementsByTagName']('*')['length'];}),_0x321d0e['getElementsByClassName']=_0x44fbca['test'](_0x217d83['getElementsByClassName']),_0x321d0e['getById']=_0x409ef3(function(_0x53ab89){return _0x5db382['appendChild'](_0x53ab89)['id']=_0x202205,!_0x217d83['getElementsByName']||!_0x217d83['getElementsByName'](_0x202205)['length'];}),_0x321d0e['getById']?(_0xdc1da7['filter']['ID']=function(_0x210263){var _0xac55d3=_0x210263['replace'](_0x5e3685,_0xd8f61c);return function(_0xb4012){return _0xb4012['getAttribute']('id')===_0xac55d3;};},_0xdc1da7['find']['ID']=function(_0x12b24a,_0x4caf28){if('undefined'!=typeof _0x4caf28['getElementById']&&_0x9b8736){var _0x40185a=_0x4caf28['getElementById'](_0x12b24a);return _0x40185a?[_0x40185a]:[];}}):(_0xdc1da7['filter']['ID']=function(_0x565f09){var _0x593979=_0x565f09['replace'](_0x5e3685,_0xd8f61c);return function(_0x2989d2){return(_0x2989d2='undefined'!=typeof _0x2989d2['getAttributeNode']&&_0x2989d2['getAttributeNode']('id'))&&_0x2989d2['value']===_0x593979;};},_0xdc1da7['find']['ID']=function(_0x354d38,_0x1eeeb7){if('undefined'!=typeof _0x1eeeb7['getElementById']&&_0x9b8736){var _0x4e3acd,_0x1c569b,_0x6c3ae0,_0x14ec26=_0x1eeeb7['getElementById'](_0x354d38);if(_0x14ec26){if(_0x4e3acd=_0x14ec26['getAttributeNode']('id'),_0x4e3acd&&_0x4e3acd['value']===_0x354d38)return[_0x14ec26];_0x6c3ae0=_0x1eeeb7['getElementsByName'](_0x354d38);for(_0x1c569b=0x0;_0x14ec26=_0x6c3ae0[_0x1c569b++];)if(_0x4e3acd=_0x14ec26['getAttributeNode']('id'),_0x4e3acd&&_0x4e3acd['value']===_0x354d38)return[_0x14ec26];}return[];}}),_0xdc1da7['find']['TAG']=_0x321d0e['getElementsByTagName']?function(_0x1a39a6,_0x3641c1){return'undefined'!=typeof _0x3641c1['getElementsByTagName']?_0x3641c1['getElementsByTagName'](_0x1a39a6):_0x321d0e['qsa']?_0x3641c1['querySelectorAll'](_0x1a39a6):void 0x0;}:function(_0x5cbb7c,_0x140280){var _0x26cea9,_0x2e12e4=[],_0x39bf0c=0x0,_0x262fae=_0x140280['getElementsByTagName'](_0x5cbb7c);if('*'===_0x5cbb7c){for(;_0x26cea9=_0x262fae[_0x39bf0c++];)0x1===_0x26cea9['nodeType']&&_0x2e12e4['push'](_0x26cea9);return _0x2e12e4;}return _0x262fae;},_0xdc1da7['find']['CLASS']=_0x321d0e['getElementsByClassName']&&function(_0x36f01e,_0x5431e9){if('undefined'!=typeof _0x5431e9['getElementsByClassName']&&_0x9b8736)return _0x5431e9['getElementsByClassName'](_0x36f01e);},_0x42cb60=[],_0x49250b=[],(_0x321d0e['qsa']=_0x44fbca['test'](_0x217d83['querySelectorAll']))&&(_0x409ef3(function(_0x4afe03){_0x5db382['appendChild'](_0x4afe03)['innerHTML']='',_0x4afe03['querySelectorAll']('[msallowcapture^=\x27\x27]')['length']&&_0x49250b['push']('[*^$]=[\x5cx20\x5ct\x5cr\x5cn\x5cf]*(?:\x27\x27|\x22\x22)'),_0x4afe03['querySelectorAll']('[selected]')['length']||_0x49250b['push']('\x5c[[\x5cx20\x5ct\x5cr\x5cn\x5cf]*(?:value|checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped)'),_0x4afe03['querySelectorAll']('[id~='+_0x202205+'-]')['length']||_0x49250b['push']('~='),_0x4afe03['querySelectorAll'](':checked')['length']||_0x49250b['push'](':checked'),_0x4afe03['querySelectorAll']('a#'+_0x202205+'+*')['length']||_0x49250b['push']('.#.+[+~]');}),_0x409ef3(function(_0x54ccd8){_0x54ccd8['innerHTML']='