解决 github pages 缓存问题

This commit is contained in:
SmallMain
2022-06-21 23:42:01 +08:00
parent e57f6e5e9f
commit e9c7c6c96a
161 changed files with 8 additions and 8 deletions

View File

@@ -0,0 +1,248 @@
{
"paths": {
"3e30KyALhNkZttyuW0A6EU": [
"effects/custom-2d-sprite",
"cc.EffectAsset"
],
"e8ql4cBzBOvoGh5/oNub59": [
"fonts/SFNSMonoItalic",
"cc.TTFFont"
],
"80AR/OlBFOoajT99htLYeJ": [
"fonts/normalFont",
"cc.BitmapFont"
],
"45vlnzVlVDaZ6fRVyB0t3Z": [
"fonts/normalFont",
"cc.Texture2D"
],
"92aqwImq1Ik7GrBSFnKTF2": [
"fonts/normalFont",
"cc.SpriteFrame",
1
],
"c1Hf3Sl8ZAnJwP/fpoHxap": [
"images/1655112479313",
"cc.Texture2D"
],
"a7ZscqX+JCIZRS157bMyhq": [
"images/1655112479313",
"cc.SpriteFrame",
1
],
"62MQQadaVK8qQN8n6UmJAa": [
"images/1655112514006",
"cc.Texture2D"
],
"85yTK+9shIo7RQfQ1TDEUi": [
"images/1655112514006",
"cc.SpriteFrame",
1
],
"39jYWzSTREwI2OOBK5nwFe": [
"images/1655112526123",
"cc.Texture2D"
],
"09o3P/9gBP/Yc7AnxUBZ+Q": [
"images/1655112526123",
"cc.SpriteFrame",
1
],
"d0bST/wYpJQIL5T+PCq46W": [
"images/1655112538161",
"cc.Texture2D"
],
"70VXjGE0JMUqGli0jmCmTF": [
"images/1655112538161",
"cc.SpriteFrame",
1
],
"68Q/ALDvRLfKrAQu5CY15V": [
"images/1655112548981",
"cc.Texture2D"
],
"87/8ZHBEVIkKeNxmalrn9r": [
"images/1655112548981",
"cc.SpriteFrame",
1
],
"70JFWsm5JN17FDywI0Lb5I": [
"images/1655112563832",
"cc.Texture2D"
],
"d0Bu8c2MBCKJc+mKBWzjsJ": [
"images/1655112563832",
"cc.SpriteFrame",
1
],
"1cijzBpFJCdoSNK98w5oUq": [
"images/1655112624336",
"cc.Texture2D"
],
"8029xEf4FHy49dWo6NK8c7": [
"images/1655112624336",
"cc.SpriteFrame",
1
],
"a97PGbCjtNjr/hYUBJUJ3p": [
"images/1655799093442",
"cc.Texture2D"
],
"34Wm35ZlJBApgKytyVFWhX": [
"images/1655799093442",
"cc.SpriteFrame",
1
],
"2cDGL4OAVN0ZbEl3w2urT8": [
"materials/custom-2d-sprite",
"cc.Material"
],
"69Fj/0+E5NeI6nlG9iAH/N": [
"spines/huatuo",
"cc.Asset"
],
"93dM6KrkZCf5dgNpQwf7T6": [
"spines/huatuo",
"sp.SkeletonData"
],
"80ThG1v09KeKxKhEPnFmvh": [
"spines/huatuo",
"cc.Texture2D"
],
"b5ObM0rx1GDKGN3k5VlH0s": [
"spines/huatuo",
"cc.SpriteFrame",
1
],
"bc2ZOJo5NCbrI0FXxitEvE": [
"spines/spineboy",
"sp.SkeletonData"
],
"d9xFMK7wVFwbAS60aG9McP": [
"spines/spineboy",
"cc.Texture2D"
],
"f2P0YcCjtHDqebnuMp4CMZ": [
"spines/spineboy",
"cc.SpriteFrame",
1
],
"b6OkwTsm1LK5cvRTwFehiy": [
"spines/spineboy",
"cc.TextAsset"
]
},
"uuids": [
"3e30KyALhNkZttyuW0A6EU",
"80AR/OlBFOoajT99htLYeJ",
"45vlnzVlVDaZ6fRVyB0t3Z",
"92aqwImq1Ik7GrBSFnKTF2",
"e8ql4cBzBOvoGh5/oNub59",
"c1Hf3Sl8ZAnJwP/fpoHxap",
"a7ZscqX+JCIZRS157bMyhq",
"62MQQadaVK8qQN8n6UmJAa",
"85yTK+9shIo7RQfQ1TDEUi",
"39jYWzSTREwI2OOBK5nwFe",
"09o3P/9gBP/Yc7AnxUBZ+Q",
"d0bST/wYpJQIL5T+PCq46W",
"70VXjGE0JMUqGli0jmCmTF",
"68Q/ALDvRLfKrAQu5CY15V",
"87/8ZHBEVIkKeNxmalrn9r",
"70JFWsm5JN17FDywI0Lb5I",
"d0Bu8c2MBCKJc+mKBWzjsJ",
"1cijzBpFJCdoSNK98w5oUq",
"8029xEf4FHy49dWo6NK8c7",
"a97PGbCjtNjr/hYUBJUJ3p",
"34Wm35ZlJBApgKytyVFWhX",
"2cDGL4OAVN0ZbEl3w2urT8",
"69Fj/0+E5NeI6nlG9iAH/N",
"93dM6KrkZCf5dgNpQwf7T6",
"80ThG1v09KeKxKhEPnFmvh",
"b5ObM0rx1GDKGN3k5VlH0s",
"bc2ZOJo5NCbrI0FXxitEvE",
"d9xFMK7wVFwbAS60aG9McP",
"f2P0YcCjtHDqebnuMp4CMZ",
"b6OkwTsm1LK5cvRTwFehiy",
"6eBWFz0oVHPLIGQKf/9Thu"
],
"scenes": {},
"redirect": [],
"deps": [],
"packs": {
"0472ad032": [
"09o3P/9gBP/Yc7AnxUBZ+Q",
"1cijzBpFJCdoSNK98w5oUq",
"2cDGL4OAVN0ZbEl3w2urT8",
"34Wm35ZlJBApgKytyVFWhX",
"39jYWzSTREwI2OOBK5nwFe",
"3e30KyALhNkZttyuW0A6EU",
"45vlnzVlVDaZ6fRVyB0t3Z",
"62MQQadaVK8qQN8n6UmJAa",
"68Q/ALDvRLfKrAQu5CY15V",
"69Fj/0+E5NeI6nlG9iAH/N",
"6eBWFz0oVHPLIGQKf/9Thu",
"70JFWsm5JN17FDywI0Lb5I",
"70VXjGE0JMUqGli0jmCmTF",
"80AR/OlBFOoajT99htLYeJ",
"80ThG1v09KeKxKhEPnFmvh",
"8029xEf4FHy49dWo6NK8c7",
"85yTK+9shIo7RQfQ1TDEUi",
"87/8ZHBEVIkKeNxmalrn9r",
"92aqwImq1Ik7GrBSFnKTF2",
"93dM6KrkZCf5dgNpQwf7T6",
"a7ZscqX+JCIZRS157bMyhq",
"a97PGbCjtNjr/hYUBJUJ3p",
"b5ObM0rx1GDKGN3k5VlH0s",
"b6OkwTsm1LK5cvRTwFehiy",
"bc2ZOJo5NCbrI0FXxitEvE",
"c1Hf3Sl8ZAnJwP/fpoHxap",
"d0Bu8c2MBCKJc+mKBWzjsJ",
"d0bST/wYpJQIL5T+PCq46W",
"d9xFMK7wVFwbAS60aG9McP",
"e8ql4cBzBOvoGh5/oNub59",
"f2P0YcCjtHDqebnuMp4CMZ"
]
},
"name": "common",
"importBase": "import",
"nativeBase": "native",
"debug": true,
"isZip": false,
"encrypted": false,
"versions": {
"import": [
"0472ad032",
"4b502"
],
"native": [
"1cijzBpFJCdoSNK98w5oUq",
"91637",
"39jYWzSTREwI2OOBK5nwFe",
"2eb47",
"45vlnzVlVDaZ6fRVyB0t3Z",
"ca872",
"62MQQadaVK8qQN8n6UmJAa",
"40d17",
"68Q/ALDvRLfKrAQu5CY15V",
"9a531",
"69Fj/0+E5NeI6nlG9iAH/N",
"b8970",
"6eBWFz0oVHPLIGQKf/9Thu",
"6d3cf",
"70JFWsm5JN17FDywI0Lb5I",
"7b3fa",
"80ThG1v09KeKxKhEPnFmvh",
"fd38c",
"a97PGbCjtNjr/hYUBJUJ3p",
"0f278",
"c1Hf3Sl8ZAnJwP/fpoHxap",
"d86d7",
"d0bST/wYpJQIL5T+PCq46W",
"9c555",
"d9xFMK7wVFwbAS60aG9McP",
"abf6b",
"e8ql4cBzBOvoGh5/oNub59",
"a6625"
]
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,29 @@
(function e(t, n, r) {
function s(o, u) {
if (!n[o]) {
if (!t[o]) {
var b = o.split("/");
b = b[b.length - 1];
if (!t[b]) {
var a = "function" == typeof __require && __require;
if (!u && a) return a(b, !0);
if (i) return i(b, !0);
throw new Error("Cannot find module '" + o + "'");
}
o = b;
}
var f = n[o] = {
exports: {}
};
t[o][0].call(f.exports, function(e) {
var n = t[o][1][e];
return s(n || e);
}, f, f.exports, e, t, n, r);
}
return n[o].exports;
}
var i = "function" == typeof __require && __require;
for (var o = 0; o < r.length; o++) s(r[o]);
return s;
})({}, {}, []);
//# sourceMappingURL=index.js.map

View File

@@ -0,0 +1 @@
{"version":3,"sources":[],"names":[],"mappings":"","sourcesContent":[],"file":"index.js"}

Binary file not shown.

After

Width:  |  Height:  |  Size: 53 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 291 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 199 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 198 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 105 KiB

View File

@@ -0,0 +1,209 @@
huatuo.png
size: 701,208
format: RGBA8888
filter: Linear,Linear
repeat: none
Body
rotate: false
xy: 487, 72
size: 90, 91
orig: 90, 91
offset: 0, 0
index: -1
Eye
rotate: false
xy: 473, 44
size: 45, 24
orig: 45, 24
offset: 0, 0
index: -1
Eye-beiji
rotate: false
xy: 360, 60
size: 57, 23
orig: 57, 23
offset: 0, 0
index: -1
Eye-fennu
rotate: false
xy: 570, 39
size: 39, 21
orig: 39, 21
offset: 0, 0
index: -1
Eye-shengli
rotate: false
xy: 421, 64
size: 45, 19
orig: 45, 19
offset: 0, 0
index: -1
Eye-siwang
rotate: false
xy: 522, 48
size: 44, 20
orig: 44, 20
offset: 0, 0
index: -1
Head
rotate: false
xy: 581, 64
size: 89, 99
orig: 89, 99
offset: 0, 0
index: -1
L-Forearm
rotate: false
xy: 613, 29
size: 32, 31
orig: 32, 31
offset: 0, 0
index: -1
L-Hand
rotate: false
xy: 674, 150
size: 27, 26
orig: 27, 26
offset: 0, 0
index: -1
L-Lowerleg
rotate: false
xy: 674, 117
size: 26, 29
orig: 26, 29
offset: 0, 0
index: -1
L-Thigh
rotate: false
xy: 649, 25
size: 29, 35
orig: 29, 35
offset: 0, 0
index: -1
L-Upperarm
rotate: false
xy: 318, 7
size: 50, 49
orig: 50, 49
offset: 0, 0
index: -1
Mouth
rotate: false
xy: 682, 36
size: 18, 10
orig: 18, 10
offset: 0, 0
index: -1
Mouth-beiji
rotate: false
xy: 470, 72
size: 13, 11
orig: 13, 11
offset: 0, 0
index: -1
Mouth-fennu
rotate: false
xy: 674, 66
size: 22, 17
orig: 22, 17
offset: 0, 0
index: -1
Mouth-shengli
rotate: false
xy: 581, 17
size: 20, 18
orig: 20, 18
offset: 0, 0
index: -1
Mouth-siwang
rotate: false
xy: 682, 50
size: 18, 12
orig: 18, 12
offset: 0, 0
index: -1
Pelvis
rotate: false
xy: 641, 180
size: 43, 28
orig: 43, 28
offset: 0, 0
index: -1
R-Forearm
rotate: false
xy: 473, 9
size: 38, 31
orig: 38, 31
offset: 0, 0
index: -1
R-Hand
rotate: false
xy: 549, 12
size: 28, 23
orig: 28, 23
offset: 0, 0
index: -1
R-Lowerleg
rotate: false
xy: 674, 87
size: 26, 26
orig: 26, 26
offset: 0, 0
index: -1
R-Thigh
rotate: false
xy: 515, 4
size: 30, 36
orig: 30, 36
offset: 0, 0
index: -1
R-Upperarm
rotate: false
xy: 431, 12
size: 38, 48
orig: 38, 48
offset: 0, 0
index: -1
SE-daoguang
rotate: false
xy: 0, 0
size: 239, 208
orig: 239, 208
offset: 0, 0
index: -1
SE-guang
rotate: false
xy: 360, 87
size: 123, 121
orig: 123, 121
offset: 0, 0
index: -1
Weapon
rotate: false
xy: 243, 10
size: 71, 46
orig: 71, 46
offset: 0, 0
index: -1
beilou
rotate: false
xy: 243, 60
size: 113, 148
orig: 113, 148
offset: 0, 0
index: -1
hulu
rotate: false
xy: 372, 4
size: 55, 52
orig: 55, 52
offset: 0, 0
index: -1
shadow
rotate: false
xy: 487, 167
size: 150, 41
orig: 150, 41
offset: 0, 0
index: -1

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 144 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 212 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 83 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 102 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 215 KiB

View File

@@ -0,0 +1,89 @@
{
"paths": {
"e3EaADwKFP+ZmDIVTeFF63": [
"home",
"cc.Prefab"
]
},
"uuids": [
"e3EaADwKFP+ZmDIVTeFF63",
"ecpdLyjvZBwrvm+cedCcQy",
"312JYturtOx74Zjp9UpOqZ",
"e7q6FL+VZEgLJUjVeDLic/",
"29FYIk+N1GYaeWH/q1NxQO",
"68J8oyAQdFUrqy37MXmbtE",
"90AErWL21A4ZPvtxQ3XG8G",
"34Wm35ZlJBApgKytyVFWhX",
"7a/QZLET9IDreTiBfRn2PD",
"93dM6KrkZCf5dgNpQwf7T6",
"5cO7kybDxGj4ipyMYdRYZB",
"5f5dyqtRNNxaFmVzYns6FZ",
"a2MjXRFdtLlYQ5ouAFv/+R",
"02kcE0s9pAmLe145ftvpR/",
"71VhFCTINJM6/Ky3oX9nBT",
"56fc2Ai/RFNYpaMT8crweK",
"d2kHe6FidKcpV5e1aiNTQM",
"73oJA92A5OPKpn+ZlUPAj1"
],
"scenes": {},
"redirect": [
"ecpdLyjvZBwrvm+cedCcQy",
0,
"34Wm35ZlJBApgKytyVFWhX",
1,
"7a/QZLET9IDreTiBfRn2PD",
0,
"93dM6KrkZCf5dgNpQwf7T6",
1,
"5cO7kybDxGj4ipyMYdRYZB",
2,
"5f5dyqtRNNxaFmVzYns6FZ",
2,
"a2MjXRFdtLlYQ5ouAFv/+R",
2
],
"deps": [
"internal",
"common",
"main"
],
"packs": {
"025f75dc8": [
"02kcE0s9pAmLe145ftvpR/",
"29FYIk+N1GYaeWH/q1NxQO",
"312JYturtOx74Zjp9UpOqZ",
"56fc2Ai/RFNYpaMT8crweK",
"68J8oyAQdFUrqy37MXmbtE",
"71VhFCTINJM6/Ky3oX9nBT",
"73oJA92A5OPKpn+ZlUPAj1",
"90AErWL21A4ZPvtxQ3XG8G",
"d2kHe6FidKcpV5e1aiNTQM",
"e3EaADwKFP+ZmDIVTeFF63",
"e7q6FL+VZEgLJUjVeDLic/"
]
},
"name": "home",
"importBase": "import",
"nativeBase": "native",
"debug": true,
"isZip": false,
"encrypted": false,
"versions": {
"import": [
"025f75dc8",
"515a0"
],
"native": [
"02kcE0s9pAmLe145ftvpR/",
"b7a3e",
"56fc2Ai/RFNYpaMT8crweK",
"5f1d9",
"71VhFCTINJM6/Ky3oX9nBT",
"c06a9",
"73oJA92A5OPKpn+ZlUPAj1",
"7661e",
"d2kHe6FidKcpV5e1aiNTQM",
"65417"
]
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,135 @@
window.__require = function e(t, n, r) {
function s(o, u) {
if (!n[o]) {
if (!t[o]) {
var b = o.split("/");
b = b[b.length - 1];
if (!t[b]) {
var a = "function" == typeof __require && __require;
if (!u && a) return a(b, !0);
if (i) return i(b, !0);
throw new Error("Cannot find module '" + o + "'");
}
o = b;
}
var f = n[o] = {
exports: {}
};
t[o][0].call(f.exports, function(e) {
var n = t[o][1][e];
return s(n || e);
}, f, f.exports, e, t, n, r);
}
return n[o].exports;
}
var i = "function" == typeof __require && __require;
for (var o = 0; o < r.length; o++) s(r[o]);
return s;
}({
home: [ function(require, module, exports) {
"use strict";
cc._RF.push(module, "fae4avBZoFIhLI0tl2YbZCe", "home");
"use strict";
var __extends = this && this.__extends || function() {
var extendStatics = function(d, b) {
extendStatics = Object.setPrototypeOf || {
__proto__: []
} instanceof Array && function(d, b) {
d.__proto__ = b;
} || function(d, b) {
for (var p in b) Object.prototype.hasOwnProperty.call(b, p) && (d[p] = b[p]);
};
return extendStatics(d, b);
};
return function(d, b) {
extendStatics(d, b);
function __() {
this.constructor = d;
}
d.prototype = null === b ? Object.create(b) : (__.prototype = b.prototype, new __());
};
}();
var __decorate = this && this.__decorate || function(decorators, target, key, desc) {
var c = arguments.length, r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
if ("object" === typeof Reflect && "function" === typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc); else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
return c > 3 && r && Object.defineProperty(target, key, r), r;
};
Object.defineProperty(exports, "__esModule", {
value: true
});
var _a = cc._decorator, ccclass = _a.ccclass, property = _a.property;
var Home = function(_super) {
__extends(Home, _super);
function Home() {
var _this = null !== _super && _super.apply(this, arguments) || this;
_this.objectNumLabel = null;
_this.objectNumSlider = null;
_this.enbaleMultiNode = null;
_this.objects = null;
_this.nums = [ 10, 1e4 ];
_this.num = _this.nums[0];
_this.enableMultiRender = true;
_this.prefabs = [];
return _this;
}
Home.prototype.onLoad = function() {
var _this = this;
this.prefabs = this.objects.children.concat();
this.objects.removeAllChildren(false);
this.objectNumSlider.node.on("slide", function(slider) {
var offset = (_this.nums[1] - _this.nums[0]) * slider.progress;
_this.num = _this.nums[0] + Math.ceil(offset);
_this.numUpdate();
});
this.enbaleMultiNode.on("toggle", function(toggle) {
_this.enableMultiRender = toggle.isChecked;
_this.multiRenderUpdate();
});
this.objectNumSlider.progress = .02;
var offset = (this.nums[1] - this.nums[0]) * this.objectNumSlider.progress;
this.num = this.nums[0] + Math.ceil(offset);
this.numUpdate();
this.multiRenderUpdate();
};
Home.prototype.numUpdate = function() {
this.objectNumLabel.string = "\u5bf9\u8c61\u6570\u91cf\uff1a" + this.num;
var offset = this.num - this.objects.children.length;
if (offset > 0) for (var i = 0; i < offset; i++) this.createObject(); else {
offset = -offset;
for (var i = 0; i < offset; i++) this.objects.children[i].destroy();
}
};
Home.prototype.multiRenderUpdate = function() {
this.reCreateObjects();
};
Home.prototype.reCreateObjects = function() {
this.objects.destroyAllChildren();
for (var i = 0; i < this.num; i++) this.createObject();
};
Home.prototype.createObject = function() {
var _a, _b, _c;
var random = Math.floor(Math.random() * this.prefabs.length);
var node = cc.instantiate(this.prefabs[random]);
if (this.enableMultiRender) {
var comp = null !== (_c = null !== (_b = null !== (_a = node.getComponent(cc.Label)) && void 0 !== _a ? _a : node.getComponent(cc.Sprite)) && void 0 !== _b ? _b : node.getComponent(cc.RichText)) && void 0 !== _c ? _c : node.getComponent(sp.Skeleton);
comp.autoSwitchMaterial = cc.RenderComponent.EnableType.ENABLE;
comp.allowDynamicAtlas = cc.RenderComponent.EnableType.ENABLE;
}
this.objects.addChild(node);
node.position = cc.v3(Math.floor(Math.random() * this.objects.width), Math.floor(Math.random() * this.objects.height));
cc.tween(node).by(3, {
angle: 360
}).repeatForever().start();
};
__decorate([ property(cc.Label) ], Home.prototype, "objectNumLabel", void 0);
__decorate([ property(cc.Slider) ], Home.prototype, "objectNumSlider", void 0);
__decorate([ property(cc.Node) ], Home.prototype, "enbaleMultiNode", void 0);
__decorate([ property(cc.Node) ], Home.prototype, "objects", void 0);
Home = __decorate([ ccclass ], Home);
return Home;
}(cc.Component);
exports.default = Home;
cc._RF.pop();
}, {} ]
}, {}, [ "home" ]);
//# sourceMappingURL=index.js.map

File diff suppressed because one or more lines are too long

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

View File

@@ -0,0 +1,133 @@
{
"paths": {
"30aC+Hnw1PF4pEcoY3kUYb": [
"effects/builtin-2d-graphics",
"cc.EffectAsset"
],
"14TDKXr2NJ6LjvHPops74o": [
"effects/builtin-2d-gray-sprite",
"cc.EffectAsset"
],
"f1h0LXVtJOta5JLZ1xCzfI": [
"effects/builtin-2d-label",
"cc.EffectAsset"
],
"0ek66qC1NOQLjgYmi04HvX": [
"effects/builtin-2d-spine",
"cc.EffectAsset"
],
"28dPjdQWxEQIG3VVl1Qm6T": [
"effects/builtin-2d-sprite",
"cc.EffectAsset"
],
"2afAA24LNP4YmYiaVLiivs": [
"effects/builtin-3d-trail",
"cc.EffectAsset"
],
"c0BAyVxX9JzZy8EjFrc9DU": [
"effects/builtin-clear-stencil",
"cc.EffectAsset"
],
"6dkeWRTOBGXICfYQ7JUBnG": [
"effects/builtin-unlit",
"cc.EffectAsset"
],
"6fgBCSDDdPMInvyNlggls2": [
"materials/builtin-2d-base",
"cc.Material"
],
"a1U5RdJRFMFL57BdJC9H1X": [
"materials/builtin-2d-graphics",
"cc.Material"
],
"3ae7efMv1CLq2ilvUY/tQi": [
"materials/builtin-2d-gray-sprite",
"cc.Material"
],
"e0LYfU5ZlNFoAB4UiRrGUG": [
"materials/builtin-2d-label",
"cc.Material"
],
"7a/QZLET9IDreTiBfRn2PD": [
"materials/builtin-2d-spine",
"cc.Material"
],
"ecpdLyjvZBwrvm+cedCcQy": [
"materials/builtin-2d-sprite",
"cc.Material"
],
"46bU+b5fROqIXVPG6aZWWK": [
"materials/builtin-3d-trail",
"cc.Material"
],
"cffgu4qBxEqa150o1DmRAy": [
"materials/builtin-clear-stencil",
"cc.Material"
],
"2aKWBXJHxKHLvrBUi2yYZQ": [
"materials/builtin-unlit",
"cc.Material"
]
},
"uuids": [
"30aC+Hnw1PF4pEcoY3kUYb",
"14TDKXr2NJ6LjvHPops74o",
"f1h0LXVtJOta5JLZ1xCzfI",
"0ek66qC1NOQLjgYmi04HvX",
"28dPjdQWxEQIG3VVl1Qm6T",
"2afAA24LNP4YmYiaVLiivs",
"c0BAyVxX9JzZy8EjFrc9DU",
"6dkeWRTOBGXICfYQ7JUBnG",
"6fgBCSDDdPMInvyNlggls2",
"a1U5RdJRFMFL57BdJC9H1X",
"3ae7efMv1CLq2ilvUY/tQi",
"e0LYfU5ZlNFoAB4UiRrGUG",
"7a/QZLET9IDreTiBfRn2PD",
"ecpdLyjvZBwrvm+cedCcQy",
"46bU+b5fROqIXVPG6aZWWK",
"cffgu4qBxEqa150o1DmRAy",
"2aKWBXJHxKHLvrBUi2yYZQ",
"02delMVqdBD70a/HSD99FK"
],
"scenes": {},
"redirect": [],
"deps": [],
"packs": {
"0967b326a": [
"02delMVqdBD70a/HSD99FK",
"0ek66qC1NOQLjgYmi04HvX",
"14TDKXr2NJ6LjvHPops74o",
"28dPjdQWxEQIG3VVl1Qm6T",
"2aKWBXJHxKHLvrBUi2yYZQ",
"2afAA24LNP4YmYiaVLiivs",
"30aC+Hnw1PF4pEcoY3kUYb",
"3ae7efMv1CLq2ilvUY/tQi",
"46bU+b5fROqIXVPG6aZWWK",
"6dkeWRTOBGXICfYQ7JUBnG",
"6fgBCSDDdPMInvyNlggls2",
"7a/QZLET9IDreTiBfRn2PD",
"a1U5RdJRFMFL57BdJC9H1X",
"c0BAyVxX9JzZy8EjFrc9DU",
"cffgu4qBxEqa150o1DmRAy",
"e0LYfU5ZlNFoAB4UiRrGUG",
"ecpdLyjvZBwrvm+cedCcQy",
"f1h0LXVtJOta5JLZ1xCzfI"
]
},
"name": "internal",
"importBase": "import",
"nativeBase": "native",
"debug": true,
"isZip": false,
"encrypted": false,
"versions": {
"import": [
"0967b326a",
"c3301"
],
"native": [
"02delMVqdBD70a/HSD99FK",
"cea68"
]
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,29 @@
(function e(t, n, r) {
function s(o, u) {
if (!n[o]) {
if (!t[o]) {
var b = o.split("/");
b = b[b.length - 1];
if (!t[b]) {
var a = "function" == typeof __require && __require;
if (!u && a) return a(b, !0);
if (i) return i(b, !0);
throw new Error("Cannot find module '" + o + "'");
}
o = b;
}
var f = n[o] = {
exports: {}
};
t[o][0].call(f.exports, function(e) {
var n = t[o][1][e];
return s(n || e);
}, f, f.exports, e, t, n, r);
}
return n[o].exports;
}
var i = "function" == typeof __require && __require;
for (var o = 0; o < r.length; o++) s(r[o]);
return s;
})({}, {}, []);
//# sourceMappingURL=index.js.map

View File

@@ -0,0 +1 @@
{"version":3,"sources":[],"names":[],"mappings":"","sourcesContent":[],"file":"index.js"}

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 B

View File

@@ -0,0 +1,53 @@
{
"paths": {},
"uuids": [
"catK9m3HRBtYgmebOjC6ma",
"ecpdLyjvZBwrvm+cedCcQy",
"a2MjXRFdtLlYQ5ouAFv/+R",
"5cO7kybDxGj4ipyMYdRYZB",
"5f5dyqtRNNxaFmVzYns6FZ",
"02delMVqdBD70a/HSD99FK",
"61cyPdEfRN047sDK9rO0W5",
"d608qFRoFHwbXd0Dap056i"
],
"scenes": {
"db://assets/main.fire": "catK9m3HRBtYgmebOjC6ma"
},
"redirect": [
"ecpdLyjvZBwrvm+cedCcQy",
0,
"02delMVqdBD70a/HSD99FK",
0
],
"deps": [
"internal"
],
"packs": {
"0b206e9e9": [
"5cO7kybDxGj4ipyMYdRYZB",
"5f5dyqtRNNxaFmVzYns6FZ",
"61cyPdEfRN047sDK9rO0W5",
"a2MjXRFdtLlYQ5ouAFv/+R",
"catK9m3HRBtYgmebOjC6ma",
"d608qFRoFHwbXd0Dap056i"
]
},
"name": "main",
"importBase": "import",
"nativeBase": "native",
"debug": true,
"isZip": false,
"encrypted": false,
"versions": {
"import": [
"0b206e9e9",
"4db5f"
],
"native": [
"61cyPdEfRN047sDK9rO0W5",
"6d707",
"d608qFRoFHwbXd0Dap056i",
"d55c2"
]
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,238 @@
window.__require = function e(t, n, r) {
function s(o, u) {
if (!n[o]) {
if (!t[o]) {
var b = o.split("/");
b = b[b.length - 1];
if (!t[b]) {
var a = "function" == typeof __require && __require;
if (!u && a) return a(b, !0);
if (i) return i(b, !0);
throw new Error("Cannot find module '" + o + "'");
}
o = b;
}
var f = n[o] = {
exports: {}
};
t[o][0].call(f.exports, function(e) {
var n = t[o][1][e];
return s(n || e);
}, f, f.exports, e, t, n, r);
}
return n[o].exports;
}
var i = "function" == typeof __require && __require;
for (var o = 0; o < r.length; o++) s(r[o]);
return s;
}({
"left-area": [ function(require, module, exports) {
"use strict";
cc._RF.push(module, "853f5uyG5pFHpEaXeXta1ML", "left-area");
"use strict";
var __extends = this && this.__extends || function() {
var extendStatics = function(d, b) {
extendStatics = Object.setPrototypeOf || {
__proto__: []
} instanceof Array && function(d, b) {
d.__proto__ = b;
} || function(d, b) {
for (var p in b) Object.prototype.hasOwnProperty.call(b, p) && (d[p] = b[p]);
};
return extendStatics(d, b);
};
return function(d, b) {
extendStatics(d, b);
function __() {
this.constructor = d;
}
d.prototype = null === b ? Object.create(b) : (__.prototype = b.prototype, new __());
};
}();
var __decorate = this && this.__decorate || function(decorators, target, key, desc) {
var c = arguments.length, r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
if ("object" === typeof Reflect && "function" === typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc); else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
return c > 3 && r && Object.defineProperty(target, key, r), r;
};
var __values = this && this.__values || function(o) {
var s = "function" === typeof Symbol && Symbol.iterator, m = s && o[s], i = 0;
if (m) return m.call(o);
if (o && "number" === typeof o.length) return {
next: function() {
o && i >= o.length && (o = void 0);
return {
value: o && o[i++],
done: !o
};
}
};
throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
};
var __read = this && this.__read || function(o, n) {
var m = "function" === typeof Symbol && o[Symbol.iterator];
if (!m) return o;
var i = m.call(o), r, ar = [], e;
try {
while ((void 0 === n || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
} catch (error) {
e = {
error: error
};
} finally {
try {
r && !r.done && (m = i["return"]) && m.call(i);
} finally {
if (e) throw e.error;
}
}
return ar;
};
Object.defineProperty(exports, "__esModule", {
value: true
});
var _a = cc._decorator, ccclass = _a.ccclass, property = _a.property;
var LeftArea = function(_super) {
__extends(LeftArea, _super);
function LeftArea() {
var _this = null !== _super && _super.apply(this, arguments) || this;
_this.home = null;
_this.multiMaterial = null;
_this.multiBatcher = null;
_this.charMode = null;
_this.highDPI = null;
_this.spineBatch = null;
_this.spineSkin = null;
_this.mainArea = null;
_this.tick = 0;
return _this;
}
LeftArea.prototype.start = function() {
this.map = new Map([ [ this.home, {
bundle: "home",
path: "home"
} ], [ this.multiMaterial, {
bundle: "multi-render",
path: "multi-material/multi-material"
} ], [ this.multiBatcher, {
bundle: "multi-render",
path: "multi-batcher/multi-batcher"
} ], [ this.charMode, {
bundle: "text-render",
path: "char-mode/char-mode"
} ], [ this.highDPI, {
bundle: "text-render",
path: "high-dpi/high-dpi"
} ], [ this.spineBatch, {
bundle: "spine",
path: "batch/spine-batch"
} ], [ this.spineSkin, {
bundle: "spine",
path: "skin/spine-skin"
} ] ]);
this.initBtns();
this.switchPage(this.map.get(this.home));
};
LeftArea.prototype.initBtns = function() {
var e_1, _a;
var _this = this;
var _loop_1 = function(node, route) {
node.on("toggle", function(toggle) {
toggle.isChecked && _this.switchPage(route);
});
};
try {
for (var _b = __values(this.map), _c = _b.next(); !_c.done; _c = _b.next()) {
var _d = __read(_c.value, 2), node = _d[0], route = _d[1];
_loop_1(node, route);
}
} catch (e_1_1) {
e_1 = {
error: e_1_1
};
} finally {
try {
_c && !_c.done && (_a = _b.return) && _a.call(_b);
} finally {
if (e_1) throw e_1.error;
}
}
};
LeftArea.prototype.switchPage = function(route) {
var _this = this;
var cur = ++this.tick;
this.mainArea.destroyAllChildren();
route && cc.assetManager.loadBundle("common", function() {
cc.assetManager.loadBundle(route.bundle, function(err, bundle) {
err || bundle.load(route.path, cc.Prefab, function(err, prefab) {
err || cur !== _this.tick || _this.mainArea.addChild(cc.instantiate(prefab));
});
});
});
};
__decorate([ property(cc.Node) ], LeftArea.prototype, "home", void 0);
__decorate([ property(cc.Node) ], LeftArea.prototype, "multiMaterial", void 0);
__decorate([ property(cc.Node) ], LeftArea.prototype, "multiBatcher", void 0);
__decorate([ property(cc.Node) ], LeftArea.prototype, "charMode", void 0);
__decorate([ property(cc.Node) ], LeftArea.prototype, "highDPI", void 0);
__decorate([ property(cc.Node) ], LeftArea.prototype, "spineBatch", void 0);
__decorate([ property(cc.Node) ], LeftArea.prototype, "spineSkin", void 0);
__decorate([ property(cc.Node) ], LeftArea.prototype, "mainArea", void 0);
LeftArea = __decorate([ ccclass ], LeftArea);
return LeftArea;
}(cc.Component);
exports.default = LeftArea;
cc._RF.pop();
}, {} ],
main: [ function(require, module, exports) {
"use strict";
cc._RF.push(module, "2454fZB1jNNTbYkc7ryXmr1", "main");
"use strict";
var __extends = this && this.__extends || function() {
var extendStatics = function(d, b) {
extendStatics = Object.setPrototypeOf || {
__proto__: []
} instanceof Array && function(d, b) {
d.__proto__ = b;
} || function(d, b) {
for (var p in b) Object.prototype.hasOwnProperty.call(b, p) && (d[p] = b[p]);
};
return extendStatics(d, b);
};
return function(d, b) {
extendStatics(d, b);
function __() {
this.constructor = d;
}
d.prototype = null === b ? Object.create(b) : (__.prototype = b.prototype, new __());
};
}();
var __decorate = this && this.__decorate || function(decorators, target, key, desc) {
var c = arguments.length, r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
if ("object" === typeof Reflect && "function" === typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc); else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
return c > 3 && r && Object.defineProperty(target, key, r), r;
};
Object.defineProperty(exports, "__esModule", {
value: true
});
var _a = cc._decorator, ccclass = _a.ccclass, property = _a.property;
var Main = function(_super) {
__extends(Main, _super);
function Main() {
var _this = null !== _super && _super.apply(this, arguments) || this;
_this.version = null;
return _this;
}
Main.prototype.start = function() {
this.version.string = "Version: v" + cc.sp.version + "\n";
};
__decorate([ property(cc.Label) ], Main.prototype, "version", void 0);
Main = __decorate([ ccclass ], Main);
return Main;
}(cc.Component);
exports.default = Main;
cc.sp.labelRetinaScale = 2;
cc.dynamicAtlasManager.maxFrameSize = 2048;
cc._RF.pop();
}, {} ]
}, {}, [ "left-area", "main" ]);
//# sourceMappingURL=index.js.map

File diff suppressed because one or more lines are too long

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

View File

@@ -0,0 +1,234 @@
{
"paths": {
"77hE9EwNpMlKl/+sGrhEVR": [
"multi-batcher/images/1",
"cc.Texture2D"
],
"c4+eoUuahAOa4lmC/4Hkdi": [
"multi-batcher/images/1",
"cc.SpriteFrame",
1
],
"b6FhIxTWVHXKa7qBmehR6I": [
"multi-batcher/images/etc1_rgb_a",
"cc.Texture2D"
],
"eahTDGUrZBV4Y+i+JslTuW": [
"multi-batcher/images/etc1_rgb_a",
"cc.SpriteFrame",
1
],
"ebcqWiiDdPRaJKJIbu9ft4": [
"multi-batcher/images/png",
"cc.Texture2D"
],
"0a5R1NT2lDxqcI2pwtgfb1": [
"multi-batcher/images/png",
"cc.SpriteFrame",
1
],
"22JHeF7zBLZqnS68r2p/bo": [
"multi-batcher/images/pvrtc2_rgb_a",
"cc.Texture2D"
],
"41Zz922rlJZZmZnFZqPxVK": [
"multi-batcher/images/pvrtc2_rgb_a",
"cc.SpriteFrame",
1
],
"43jA/TdMpFA7K8IIjNbb9M": [
"multi-batcher/images/sheep_down_0",
"cc.Texture2D"
],
"8fHzmU6I5EBqjpHEb0Xl3i": [
"multi-batcher/images/sheep_down_0",
"cc.SpriteFrame",
1
],
"10Drosz6JPsKWsqV+bRh/A": [
"multi-batcher/images/sheep_jump_2",
"cc.Texture2D"
],
"2dPOEW20pCTLs79c0WyZVp": [
"multi-batcher/images/sheep_jump_2",
"cc.SpriteFrame",
1
],
"44mZ0YUdFAF56mmNytjs31": [
"multi-batcher/images/sheep_jump_3",
"cc.Texture2D"
],
"b48cuQCqRMLaIzf9I1fTbW": [
"multi-batcher/images/sheep_jump_3",
"cc.SpriteFrame",
1
],
"7aeIQwZiFL1YbOCVeiFt1p": [
"multi-batcher/images/sheep_run_1",
"cc.Texture2D"
],
"55URLSNf5K3IyZBezfiMKa": [
"multi-batcher/images/sheep_run_1",
"cc.SpriteFrame",
1
],
"14W7pBGWJJ7q7JCPsVTovy": [
"multi-batcher/multi-batcher",
"cc.Prefab"
],
"c58wUeG09DhJOcuDi8uPW/": [
"multi-material/multi-material",
"cc.Prefab"
],
"0eAM9yHrBFe4PSAXHMHNl+": [
"multi-material/test-material",
"cc.Material"
]
},
"uuids": [
"77hE9EwNpMlKl/+sGrhEVR",
"c4+eoUuahAOa4lmC/4Hkdi",
"b6FhIxTWVHXKa7qBmehR6I",
"eahTDGUrZBV4Y+i+JslTuW",
"ebcqWiiDdPRaJKJIbu9ft4",
"0a5R1NT2lDxqcI2pwtgfb1",
"22JHeF7zBLZqnS68r2p/bo",
"41Zz922rlJZZmZnFZqPxVK",
"43jA/TdMpFA7K8IIjNbb9M",
"8fHzmU6I5EBqjpHEb0Xl3i",
"10Drosz6JPsKWsqV+bRh/A",
"2dPOEW20pCTLs79c0WyZVp",
"44mZ0YUdFAF56mmNytjs31",
"b48cuQCqRMLaIzf9I1fTbW",
"7aeIQwZiFL1YbOCVeiFt1p",
"55URLSNf5K3IyZBezfiMKa",
"14W7pBGWJJ7q7JCPsVTovy",
"c58wUeG09DhJOcuDi8uPW/",
"0eAM9yHrBFe4PSAXHMHNl+",
"ecpdLyjvZBwrvm+cedCcQy",
"f0BIwQ8D5Ml7nTNQbh1YlS",
"e97GVMl6JHh5Ml5qEDdSGa",
"29FYIk+N1GYaeWH/q1NxQO",
"5cO7kybDxGj4ipyMYdRYZB",
"5f5dyqtRNNxaFmVzYns6FZ",
"a2MjXRFdtLlYQ5ouAFv/+R",
"8c20Sso/ZEn7NUfNSM+EBh",
"8029xEf4FHy49dWo6NK8c7",
"a7ZscqX+JCIZRS157bMyhq",
"80AR/OlBFOoajT99htLYeJ",
"6eBWFz0oVHPLIGQKf/9Thu",
"bc2ZOJo5NCbrI0FXxitEvE",
"2cDGL4OAVN0ZbEl3w2urT8",
"5dz/wYuRNGDqDZXXT0zaEr",
"c1Hf3Sl8ZAnJwP/fpoHxap",
"1cijzBpFJCdoSNK98w5oUq",
"45vlnzVlVDaZ6fRVyB0t3Z",
"d9xFMK7wVFwbAS60aG9McP",
"e8Ueib+qJEhL6mXAHdnwbi",
"b4P/PCArtIdIH38t6mlw8Y",
"71VhFCTINJM6/Ky3oX9nBT"
],
"scenes": {},
"redirect": [
"ecpdLyjvZBwrvm+cedCcQy",
0,
"5cO7kybDxGj4ipyMYdRYZB",
1,
"5f5dyqtRNNxaFmVzYns6FZ",
1,
"a2MjXRFdtLlYQ5ouAFv/+R",
1,
"8029xEf4FHy49dWo6NK8c7",
2,
"a7ZscqX+JCIZRS157bMyhq",
2,
"80AR/OlBFOoajT99htLYeJ",
2,
"6eBWFz0oVHPLIGQKf/9Thu",
2,
"bc2ZOJo5NCbrI0FXxitEvE",
2,
"2cDGL4OAVN0ZbEl3w2urT8",
2,
"c1Hf3Sl8ZAnJwP/fpoHxap",
2,
"1cijzBpFJCdoSNK98w5oUq",
2,
"45vlnzVlVDaZ6fRVyB0t3Z",
2,
"d9xFMK7wVFwbAS60aG9McP",
2
],
"deps": [
"internal",
"main",
"common"
],
"packs": {
"03de068c3": [
"0a5R1NT2lDxqcI2pwtgfb1",
"0eAM9yHrBFe4PSAXHMHNl+",
"10Drosz6JPsKWsqV+bRh/A",
"14W7pBGWJJ7q7JCPsVTovy",
"22JHeF7zBLZqnS68r2p/bo",
"29FYIk+N1GYaeWH/q1NxQO",
"2dPOEW20pCTLs79c0WyZVp",
"41Zz922rlJZZmZnFZqPxVK",
"43jA/TdMpFA7K8IIjNbb9M",
"44mZ0YUdFAF56mmNytjs31",
"55URLSNf5K3IyZBezfiMKa",
"5dz/wYuRNGDqDZXXT0zaEr",
"71VhFCTINJM6/Ky3oX9nBT",
"77hE9EwNpMlKl/+sGrhEVR",
"7aeIQwZiFL1YbOCVeiFt1p",
"8c20Sso/ZEn7NUfNSM+EBh",
"8fHzmU6I5EBqjpHEb0Xl3i",
"b4P/PCArtIdIH38t6mlw8Y",
"b48cuQCqRMLaIzf9I1fTbW",
"b6FhIxTWVHXKa7qBmehR6I",
"c4+eoUuahAOa4lmC/4Hkdi",
"c58wUeG09DhJOcuDi8uPW/",
"e8Ueib+qJEhL6mXAHdnwbi",
"e97GVMl6JHh5Ml5qEDdSGa",
"eahTDGUrZBV4Y+i+JslTuW",
"ebcqWiiDdPRaJKJIbu9ft4",
"f0BIwQ8D5Ml7nTNQbh1YlS"
]
},
"name": "multi-render",
"importBase": "import",
"nativeBase": "native",
"debug": true,
"isZip": false,
"encrypted": false,
"versions": {
"import": [
"03de068c3",
"a5082"
],
"native": [
"10Drosz6JPsKWsqV+bRh/A",
"eae97",
"22JHeF7zBLZqnS68r2p/bo",
"2ecc6",
"43jA/TdMpFA7K8IIjNbb9M",
"28847",
"44mZ0YUdFAF56mmNytjs31",
"99af5",
"71VhFCTINJM6/Ky3oX9nBT",
"c06a9",
"77hE9EwNpMlKl/+sGrhEVR",
"92cfc",
"7aeIQwZiFL1YbOCVeiFt1p",
"9e7e3",
"b4P/PCArtIdIH38t6mlw8Y",
"83fcc",
"b6FhIxTWVHXKa7qBmehR6I",
"6159f",
"e8Ueib+qJEhL6mXAHdnwbi",
"90cf4",
"ebcqWiiDdPRaJKJIbu9ft4",
"46cee"
]
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,100 @@
window.__require = function e(t, n, r) {
function s(o, u) {
if (!n[o]) {
if (!t[o]) {
var b = o.split("/");
b = b[b.length - 1];
if (!t[b]) {
var a = "function" == typeof __require && __require;
if (!u && a) return a(b, !0);
if (i) return i(b, !0);
throw new Error("Cannot find module '" + o + "'");
}
o = b;
}
var f = n[o] = {
exports: {}
};
t[o][0].call(f.exports, function(e) {
var n = t[o][1][e];
return s(n || e);
}, f, f.exports, e, t, n, r);
}
return n[o].exports;
}
var i = "function" == typeof __require && __require;
for (var o = 0; o < r.length; o++) s(r[o]);
return s;
}({
"multi-batcher": [ function(require, module, exports) {
"use strict";
cc._RF.push(module, "3e9188DEK9FCYlYeL+jvmrQ", "multi-batcher");
"use strict";
var __extends = this && this.__extends || function() {
var extendStatics = function(d, b) {
extendStatics = Object.setPrototypeOf || {
__proto__: []
} instanceof Array && function(d, b) {
d.__proto__ = b;
} || function(d, b) {
for (var p in b) Object.prototype.hasOwnProperty.call(b, p) && (d[p] = b[p]);
};
return extendStatics(d, b);
};
return function(d, b) {
extendStatics(d, b);
function __() {
this.constructor = d;
}
d.prototype = null === b ? Object.create(b) : (__.prototype = b.prototype, new __());
};
}();
var __decorate = this && this.__decorate || function(decorators, target, key, desc) {
var c = arguments.length, r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
if ("object" === typeof Reflect && "function" === typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc); else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
return c > 3 && r && Object.defineProperty(target, key, r), r;
};
Object.defineProperty(exports, "__esModule", {
value: true
});
var _a = cc._decorator, ccclass = _a.ccclass, property = _a.property;
var MultiBatcher = function(_super) {
__extends(MultiBatcher, _super);
function MultiBatcher() {
var _this = null !== _super && _super.apply(this, arguments) || this;
_this.batchBtn = null;
_this.cancelBtn = null;
_this.textures = null;
return _this;
}
MultiBatcher.prototype.onLoad = function() {
var _this = this;
this.batchBtn.on("click", function() {
var batcher = new cc.sp.MultiBatcher();
batcher.init();
_this.textures.children.forEach(function(v) {
var sprite = v.getComponent(cc.Sprite);
batcher.requsetMaterial(sprite.spriteFrame.getTexture());
sprite.setVertsDirty();
});
});
this.cancelBtn.on("click", function() {
_this.textures.children.forEach(function(v) {
var sprite = v.getComponent(cc.Sprite);
sprite.spriteFrame.getTexture().unlinkMaterial();
sprite.setMaterial(0, cc.Material.getBuiltinMaterial("2d-sprite"));
sprite.setVertsDirty();
});
});
};
__decorate([ property(cc.Node) ], MultiBatcher.prototype, "batchBtn", void 0);
__decorate([ property(cc.Node) ], MultiBatcher.prototype, "cancelBtn", void 0);
__decorate([ property(cc.Node) ], MultiBatcher.prototype, "textures", void 0);
MultiBatcher = __decorate([ ccclass ], MultiBatcher);
return MultiBatcher;
}(cc.Component);
exports.default = MultiBatcher;
cc._RF.pop();
}, {} ]
}, {}, [ "multi-batcher" ]);
//# sourceMappingURL=index.js.map

View File

@@ -0,0 +1 @@
{"version":3,"sources":["assets/multi-render/multi-batcher/multi-batcher.ts"],"names":["_a","cc","_decorator","ccclass","property","MultiBatcher","_super","__extends","_this","apply","this","arguments","batchBtn","cancelBtn","textures","prototype","onLoad","on","batcher","sp","init","children","forEach","v","sprite","getComponent","Sprite","requsetMaterial","spriteFrame","getTexture","setVertsDirty","unlinkMaterial","setMaterial","Material","getBuiltinMaterial","__decorate","Node","Component","exports","default"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IACM,IAAAA,KAAAC,GAAAC,YAAAC,UAAAH,GAAAG,SAAAC,WAAAJ,GAAAI;IAGN,IAAAC,eAAA,SAAAC;MAA0CC,UAAAF,cAAAC;MAA1C,SAAAD;QAAA,IAAAG,QAAA,SAAAF,UAAAA,OAAAG,MAAAC,MAAAC,cAAAD;QAGIF,MAAAI,WAAA;QAGAJ,MAAAK,YAAA;QAGAL,MAAAM,WAAA;;;MAGUT,aAAAU,UAAAC,SAAA;QAAV,IAAAR,QAAAE;QACIA,KAAAE,SAAAK,GAAA,SAAA;UACI,IAAAC,UAAA,IAAAjB,GAAAkB,GAAAd;UACAa,QAAAE;UACAZ,MAAAM,SAAAO,SAAAC,QAAA,SAAAC;YACI,IAAAC,SAAAD,EAAAE,aAAAxB,GAAAyB;YACAR,QAAAS,gBAAAH,OAAAI,YAAAC;YACAL,OAAAM;;;QAIRpB,KAAAG,UAAAI,GAAA,SAAA;UACIT,MAAAM,SAAAO,SAAAC,QAAA,SAAAC;YACI,IAAAC,SAAAD,EAAAE,aAAAxB,GAAAyB;YACAF,OAAAI,YAAAC,aAAAE;YACAP,OAAAQ,YAAA,GAAA/B,GAAAgC,SAAAC,mBAAA;YACAV,OAAAM;;;;MAzBZK,WAAA,EADC/B,SAAAH,GAAAmC,SACwB/B,aAAAU,WAAA,iBAAA;MAGzBoB,WAAA,EADC/B,SAAAH,GAAAmC,SACyB/B,aAAAU,WAAA,kBAAA;MAG1BoB,WAAA,EADC/B,SAAAH,GAAAmC,SACwB/B,aAAAU,WAAA,iBAAA;MATRV,eAAA8B,WAAA,EADpBhC,WACoBE;MAiCrB,OAAAA;KAjCA,CAAAJ,GAAAoC;IAAqBC,QAAAC,UAAAlC","sourcesContent":["\nconst { ccclass, property } = cc._decorator;\n\n@ccclass\nexport default class MultiBatcher extends cc.Component {\n\n @property(cc.Node)\n batchBtn: cc.Node = null;\n\n @property(cc.Node)\n cancelBtn: cc.Node = null;\n\n @property(cc.Node)\n textures: cc.Node = null;\n\n\n protected onLoad(): void {\n this.batchBtn.on('click', () => {\n const batcher = new cc.sp.MultiBatcher();\n batcher.init();\n this.textures.children.forEach(v => {\n const sprite = v.getComponent(cc.Sprite);\n batcher.requsetMaterial(sprite.spriteFrame.getTexture());\n sprite.setVertsDirty();\n });\n });\n\n this.cancelBtn.on('click', () => {\n this.textures.children.forEach(v => {\n const sprite = v.getComponent(cc.Sprite);\n sprite.spriteFrame.getTexture().unlinkMaterial();\n sprite.setMaterial(0, cc.Material.getBuiltinMaterial('2d-sprite'));\n sprite.setVertsDirty();\n });\n });\n }\n\n}\n"],"file":"index.js"}

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.3 KiB

View File

@@ -0,0 +1,28 @@
{
"paths": {
"5dz/wYuRNGDqDZXXT0zaEr": [
"effects/multi-2d-sprite",
"cc.EffectAsset"
]
},
"uuids": [
"5dz/wYuRNGDqDZXXT0zaEr"
],
"scenes": {},
"redirect": [],
"deps": [],
"packs": {},
"name": "sp",
"importBase": "import",
"nativeBase": "native",
"debug": true,
"isZip": false,
"encrypted": false,
"versions": {
"import": [
"5dz/wYuRNGDqDZXXT0zaEr",
"a50cc"
],
"native": []
}
}

View File

@@ -0,0 +1,321 @@
[
1,
0,
0,
[
[
"cc.EffectAsset",
[
"_name",
"shaders",
"techniques"
],
0
]
],
[
[
0,
0,
1,
2,
4
]
],
[
[
0,
"multi-2d-sprite",
[
{
"hash": 3894394603,
"record": null,
"name": "multi-2d-sprite|vs|fs",
"glsl3": {
"vert": "\nprecision highp float;\nuniform CCGlobal {\n mat4 cc_matView;\n mat4 cc_matViewInv;\n mat4 cc_matProj;\n mat4 cc_matProjInv;\n mat4 cc_matViewProj;\n mat4 cc_matViewProjInv;\n vec4 cc_cameraPos;\n vec4 cc_time;\n mediump vec4 cc_screenSize;\n mediump vec4 cc_screenScale;\n};\nuniform CCLocal {\n mat4 cc_matWorld;\n mat4 cc_matWorldIT;\n};\nin vec3 a_position;\nin vec4 a_color;\nout vec4 v_color;\n#if USE_TEXTURE\nin vec2 a_uv0;\nout vec2 v_uv0;\n#if USE_MULTI_TEXTURE\nin float a_texId;\nout float v_texId;\n#endif\n#endif\nvoid main () {\n vec4 pos = vec4(a_position, 1);\n #if CC_USE_MODEL\n pos = cc_matViewProj * cc_matWorld * pos;\n #else\n pos = cc_matViewProj * pos;\n #endif\n #if USE_TEXTURE\n v_uv0 = a_uv0;\n #if USE_MULTI_TEXTURE\n v_texId = a_texId;\n #endif\n #endif\n v_color = a_color;\n gl_Position = pos;\n}",
"frag": "\nprecision highp float;\n#if USE_ALPHA_TEST\n uniform ALPHA_TEST {\n float alphaThreshold;\n };\n#endif\nvoid ALPHA_TEST (in vec4 color) {\n #if USE_ALPHA_TEST\n if (color.a < alphaThreshold) discard;\n #endif\n}\nvoid ALPHA_TEST (in float alpha) {\n #if USE_ALPHA_TEST\n if (alpha < alphaThreshold) discard;\n #endif\n}\nin vec4 v_color;\n#if USE_TEXTURE\nin vec2 v_uv0;\nuniform sampler2D texture;\n#if USE_MULTI_TEXTURE\nin float v_texId;\nuniform sampler2D texture2;\nuniform sampler2D texture3;\nuniform sampler2D texture4;\nuniform sampler2D texture5;\nuniform sampler2D texture6;\nuniform sampler2D texture7;\nuniform sampler2D texture8;\n#endif\n#endif\nvoid main () {\n vec4 o = vec4(1, 1, 1, 1);\n #if USE_TEXTURE\n #if USE_MULTI_TEXTURE\n if(v_texId < 1.0){\n vec4 texture_tmp = texture(texture, v_uv0);\n #if CC_USE_ALPHA_ATLAS_texture\n texture_tmp.a *= texture(texture, v_uv0 + vec2(0, 0.5)).r;\n #endif\n #if INPUT_IS_GAMMA\n o.rgb *= (texture_tmp.rgb * texture_tmp.rgb);\n o.a *= texture_tmp.a;\n #else\n o *= texture_tmp;\n #endif\n } else if(v_texId < 2.0){\n vec4 texture2_tmp = texture(texture2, v_uv0);\n #if CC_USE_ALPHA_ATLAS_texture2\n texture2_tmp.a *= texture(texture2, v_uv0 + vec2(0, 0.5)).r;\n #endif\n #if INPUT_IS_GAMMA\n o.rgb *= (texture2_tmp.rgb * texture2_tmp.rgb);\n o.a *= texture2_tmp.a;\n #else\n o *= texture2_tmp;\n #endif\n } else if(v_texId < 3.0){\n vec4 texture3_tmp = texture(texture3, v_uv0);\n #if CC_USE_ALPHA_ATLAS_texture3\n texture3_tmp.a *= texture(texture3, v_uv0 + vec2(0, 0.5)).r;\n #endif\n #if INPUT_IS_GAMMA\n o.rgb *= (texture3_tmp.rgb * texture3_tmp.rgb);\n o.a *= texture3_tmp.a;\n #else\n o *= texture3_tmp;\n #endif\n } else if(v_texId < 4.0){\n vec4 texture4_tmp = texture(texture4, v_uv0);\n #if CC_USE_ALPHA_ATLAS_texture4\n texture4_tmp.a *= texture(texture4, v_uv0 + vec2(0, 0.5)).r;\n #endif\n #if INPUT_IS_GAMMA\n o.rgb *= (texture4_tmp.rgb * texture4_tmp.rgb);\n o.a *= texture4_tmp.a;\n #else\n o *= texture4_tmp;\n #endif\n } else if(v_texId < 5.0){\n vec4 texture5_tmp = texture(texture5, v_uv0);\n #if CC_USE_ALPHA_ATLAS_texture5\n texture5_tmp.a *= texture(texture5, v_uv0 + vec2(0, 0.5)).r;\n #endif\n #if INPUT_IS_GAMMA\n o.rgb *= (texture5_tmp.rgb * texture5_tmp.rgb);\n o.a *= texture5_tmp.a;\n #else\n o *= texture5_tmp;\n #endif\n } else if(v_texId < 6.0){\n vec4 texture6_tmp = texture(texture6, v_uv0);\n #if CC_USE_ALPHA_ATLAS_texture6\n texture6_tmp.a *= texture(texture6, v_uv0 + vec2(0, 0.5)).r;\n #endif\n #if INPUT_IS_GAMMA\n o.rgb *= (texture6_tmp.rgb * texture6_tmp.rgb);\n o.a *= texture6_tmp.a;\n #else\n o *= texture6_tmp;\n #endif\n } else if(v_texId < 7.0){\n vec4 texture7_tmp = texture(texture7, v_uv0);\n #if CC_USE_ALPHA_ATLAS_texture7\n texture7_tmp.a *= texture(texture7, v_uv0 + vec2(0, 0.5)).r;\n #endif\n #if INPUT_IS_GAMMA\n o.rgb *= (texture7_tmp.rgb * texture7_tmp.rgb);\n o.a *= texture7_tmp.a;\n #else\n o *= texture7_tmp;\n #endif\n } else {\n vec4 texture8_tmp = texture(texture8, v_uv0);\n #if CC_USE_ALPHA_ATLAS_texture8\n texture8_tmp.a *= texture(texture8, v_uv0 + vec2(0, 0.5)).r;\n #endif\n #if INPUT_IS_GAMMA\n o.rgb *= (texture8_tmp.rgb * texture8_tmp.rgb);\n o.a *= texture8_tmp.a;\n #else\n o *= texture8_tmp;\n #endif\n }\n #else\n vec4 texture_tmp = texture(texture, v_uv0);\n #if CC_USE_ALPHA_ATLAS_texture\n texture_tmp.a *= texture(texture, v_uv0 + vec2(0, 0.5)).r;\n #endif\n #if INPUT_IS_GAMMA\n o.rgb *= (texture_tmp.rgb * texture_tmp.rgb);\n o.a *= texture_tmp.a;\n #else\n o *= texture_tmp;\n #endif\n #endif\n #endif\n o *= v_color;\n ALPHA_TEST(o);\n gl_FragColor = o;\n}"
},
"glsl1": {
"vert": "\nprecision highp float;\nuniform mat4 cc_matViewProj;\nuniform mat4 cc_matWorld;\nattribute vec3 a_position;\nattribute vec4 a_color;\nvarying vec4 v_color;\n#if USE_TEXTURE\nattribute vec2 a_uv0;\nvarying vec2 v_uv0;\n#if USE_MULTI_TEXTURE\nattribute float a_texId;\nvarying float v_texId;\n#endif\n#endif\nvoid main () {\n vec4 pos = vec4(a_position, 1);\n #if CC_USE_MODEL\n pos = cc_matViewProj * cc_matWorld * pos;\n #else\n pos = cc_matViewProj * pos;\n #endif\n #if USE_TEXTURE\n v_uv0 = a_uv0;\n #if USE_MULTI_TEXTURE\n v_texId = a_texId;\n #endif\n #endif\n v_color = a_color;\n gl_Position = pos;\n}",
"frag": "\nprecision highp float;\n#if USE_ALPHA_TEST\n uniform float alphaThreshold;\n#endif\nvoid ALPHA_TEST (in vec4 color) {\n #if USE_ALPHA_TEST\n if (color.a < alphaThreshold) discard;\n #endif\n}\nvoid ALPHA_TEST (in float alpha) {\n #if USE_ALPHA_TEST\n if (alpha < alphaThreshold) discard;\n #endif\n}\nvarying vec4 v_color;\n#if USE_TEXTURE\nvarying vec2 v_uv0;\nuniform sampler2D texture;\n#if USE_MULTI_TEXTURE\nvarying float v_texId;\nuniform sampler2D texture2;\nuniform sampler2D texture3;\nuniform sampler2D texture4;\nuniform sampler2D texture5;\nuniform sampler2D texture6;\nuniform sampler2D texture7;\nuniform sampler2D texture8;\n#endif\n#endif\nvoid main () {\n vec4 o = vec4(1, 1, 1, 1);\n #if USE_TEXTURE\n #if USE_MULTI_TEXTURE\n if(v_texId < 1.0){\n vec4 texture_tmp = texture2D(texture, v_uv0);\n #if CC_USE_ALPHA_ATLAS_texture\n texture_tmp.a *= texture2D(texture, v_uv0 + vec2(0, 0.5)).r;\n #endif\n #if INPUT_IS_GAMMA\n o.rgb *= (texture_tmp.rgb * texture_tmp.rgb);\n o.a *= texture_tmp.a;\n #else\n o *= texture_tmp;\n #endif\n } else if(v_texId < 2.0){\n vec4 texture2_tmp = texture2D(texture2, v_uv0);\n #if CC_USE_ALPHA_ATLAS_texture2\n texture2_tmp.a *= texture2D(texture2, v_uv0 + vec2(0, 0.5)).r;\n #endif\n #if INPUT_IS_GAMMA\n o.rgb *= (texture2_tmp.rgb * texture2_tmp.rgb);\n o.a *= texture2_tmp.a;\n #else\n o *= texture2_tmp;\n #endif\n } else if(v_texId < 3.0){\n vec4 texture3_tmp = texture2D(texture3, v_uv0);\n #if CC_USE_ALPHA_ATLAS_texture3\n texture3_tmp.a *= texture2D(texture3, v_uv0 + vec2(0, 0.5)).r;\n #endif\n #if INPUT_IS_GAMMA\n o.rgb *= (texture3_tmp.rgb * texture3_tmp.rgb);\n o.a *= texture3_tmp.a;\n #else\n o *= texture3_tmp;\n #endif\n } else if(v_texId < 4.0){\n vec4 texture4_tmp = texture2D(texture4, v_uv0);\n #if CC_USE_ALPHA_ATLAS_texture4\n texture4_tmp.a *= texture2D(texture4, v_uv0 + vec2(0, 0.5)).r;\n #endif\n #if INPUT_IS_GAMMA\n o.rgb *= (texture4_tmp.rgb * texture4_tmp.rgb);\n o.a *= texture4_tmp.a;\n #else\n o *= texture4_tmp;\n #endif\n } else if(v_texId < 5.0){\n vec4 texture5_tmp = texture2D(texture5, v_uv0);\n #if CC_USE_ALPHA_ATLAS_texture5\n texture5_tmp.a *= texture2D(texture5, v_uv0 + vec2(0, 0.5)).r;\n #endif\n #if INPUT_IS_GAMMA\n o.rgb *= (texture5_tmp.rgb * texture5_tmp.rgb);\n o.a *= texture5_tmp.a;\n #else\n o *= texture5_tmp;\n #endif\n } else if(v_texId < 6.0){\n vec4 texture6_tmp = texture2D(texture6, v_uv0);\n #if CC_USE_ALPHA_ATLAS_texture6\n texture6_tmp.a *= texture2D(texture6, v_uv0 + vec2(0, 0.5)).r;\n #endif\n #if INPUT_IS_GAMMA\n o.rgb *= (texture6_tmp.rgb * texture6_tmp.rgb);\n o.a *= texture6_tmp.a;\n #else\n o *= texture6_tmp;\n #endif\n } else if(v_texId < 7.0){\n vec4 texture7_tmp = texture2D(texture7, v_uv0);\n #if CC_USE_ALPHA_ATLAS_texture7\n texture7_tmp.a *= texture2D(texture7, v_uv0 + vec2(0, 0.5)).r;\n #endif\n #if INPUT_IS_GAMMA\n o.rgb *= (texture7_tmp.rgb * texture7_tmp.rgb);\n o.a *= texture7_tmp.a;\n #else\n o *= texture7_tmp;\n #endif\n } else {\n vec4 texture8_tmp = texture2D(texture8, v_uv0);\n #if CC_USE_ALPHA_ATLAS_texture8\n texture8_tmp.a *= texture2D(texture8, v_uv0 + vec2(0, 0.5)).r;\n #endif\n #if INPUT_IS_GAMMA\n o.rgb *= (texture8_tmp.rgb * texture8_tmp.rgb);\n o.a *= texture8_tmp.a;\n #else\n o *= texture8_tmp;\n #endif\n }\n #else\n vec4 texture_tmp = texture2D(texture, v_uv0);\n #if CC_USE_ALPHA_ATLAS_texture\n texture_tmp.a *= texture2D(texture, v_uv0 + vec2(0, 0.5)).r;\n #endif\n #if INPUT_IS_GAMMA\n o.rgb *= (texture_tmp.rgb * texture_tmp.rgb);\n o.a *= texture_tmp.a;\n #else\n o *= texture_tmp;\n #endif\n #endif\n #endif\n o *= v_color;\n ALPHA_TEST(o);\n gl_FragColor = o;\n}"
},
"builtins": {
"globals": {
"blocks": [
{
"name": "CCGlobal",
"defines": []
}
],
"samplers": []
},
"locals": {
"blocks": [
{
"name": "CCLocal",
"defines": []
}
],
"samplers": []
}
},
"defines": [
{
"name": "USE_TEXTURE",
"type": "boolean",
"defines": []
},
{
"name": "USE_MULTI_TEXTURE",
"type": "boolean",
"defines": [
"USE_TEXTURE"
]
},
{
"name": "CC_USE_MODEL",
"type": "boolean",
"defines": []
},
{
"name": "USE_ALPHA_TEST",
"type": "boolean",
"defines": []
},
{
"name": "CC_USE_ALPHA_ATLAS_texture",
"type": "boolean",
"defines": [
"USE_TEXTURE"
]
},
{
"name": "INPUT_IS_GAMMA",
"type": "boolean",
"defines": [
"USE_TEXTURE"
]
},
{
"name": "CC_USE_ALPHA_ATLAS_texture2",
"type": "boolean",
"defines": [
"USE_TEXTURE",
"USE_MULTI_TEXTURE"
]
},
{
"name": "CC_USE_ALPHA_ATLAS_texture3",
"type": "boolean",
"defines": [
"USE_TEXTURE",
"USE_MULTI_TEXTURE"
]
},
{
"name": "CC_USE_ALPHA_ATLAS_texture4",
"type": "boolean",
"defines": [
"USE_TEXTURE",
"USE_MULTI_TEXTURE"
]
},
{
"name": "CC_USE_ALPHA_ATLAS_texture5",
"type": "boolean",
"defines": [
"USE_TEXTURE",
"USE_MULTI_TEXTURE"
]
},
{
"name": "CC_USE_ALPHA_ATLAS_texture6",
"type": "boolean",
"defines": [
"USE_TEXTURE",
"USE_MULTI_TEXTURE"
]
},
{
"name": "CC_USE_ALPHA_ATLAS_texture7",
"type": "boolean",
"defines": [
"USE_TEXTURE",
"USE_MULTI_TEXTURE"
]
},
{
"name": "CC_USE_ALPHA_ATLAS_texture8",
"type": "boolean",
"defines": [
"USE_TEXTURE",
"USE_MULTI_TEXTURE"
]
}
],
"blocks": [
{
"name": "ALPHA_TEST",
"binding": 0,
"members": [
{
"name": "alphaThreshold",
"type": 13,
"count": 1
}
],
"defines": [
"USE_ALPHA_TEST"
]
}
],
"samplers": [
{
"name": "texture",
"type": 29,
"count": 1,
"binding": 30,
"defines": [
"USE_TEXTURE"
]
},
{
"name": "texture2",
"type": 29,
"count": 1,
"binding": 31,
"defines": [
"USE_TEXTURE",
"USE_MULTI_TEXTURE"
]
},
{
"name": "texture3",
"type": 29,
"count": 1,
"binding": 32,
"defines": [
"USE_TEXTURE",
"USE_MULTI_TEXTURE"
]
},
{
"name": "texture4",
"type": 29,
"count": 1,
"binding": 33,
"defines": [
"USE_TEXTURE",
"USE_MULTI_TEXTURE"
]
},
{
"name": "texture5",
"type": 29,
"count": 1,
"binding": 34,
"defines": [
"USE_TEXTURE",
"USE_MULTI_TEXTURE"
]
},
{
"name": "texture6",
"type": 29,
"count": 1,
"binding": 35,
"defines": [
"USE_TEXTURE",
"USE_MULTI_TEXTURE"
]
},
{
"name": "texture7",
"type": 29,
"count": 1,
"binding": 36,
"defines": [
"USE_TEXTURE",
"USE_MULTI_TEXTURE"
]
},
{
"name": "texture8",
"type": 29,
"count": 1,
"binding": 37,
"defines": [
"USE_TEXTURE",
"USE_MULTI_TEXTURE"
]
}
]
}
],
[
{
"passes": [
{
"program": "multi-2d-sprite|vs|fs",
"blendState": {
"targets": [
{
"blend": true
}
]
},
"rasterizerState": {
"cullMode": 0
},
"properties": {
"texture": {
"value": "white",
"type": 29
},
"texture2": {
"value": "white",
"type": 29
},
"texture3": {
"value": "white",
"type": 29
},
"texture4": {
"value": "white",
"type": 29
},
"texture5": {
"value": "white",
"type": 29
},
"texture6": {
"value": "white",
"type": 29
},
"texture7": {
"value": "white",
"type": 29
},
"texture8": {
"value": "white",
"type": 29
},
"alphaThreshold": {
"type": 13,
"value": [
0.5
]
}
}
}
]
}
]
]
],
0,
0,
[],
[],
[]
]

View File

@@ -0,0 +1,29 @@
(function e(t, n, r) {
function s(o, u) {
if (!n[o]) {
if (!t[o]) {
var b = o.split("/");
b = b[b.length - 1];
if (!t[b]) {
var a = "function" == typeof __require && __require;
if (!u && a) return a(b, !0);
if (i) return i(b, !0);
throw new Error("Cannot find module '" + o + "'");
}
o = b;
}
var f = n[o] = {
exports: {}
};
t[o][0].call(f.exports, function(e) {
var n = t[o][1][e];
return s(n || e);
}, f, f.exports, e, t, n, r);
}
return n[o].exports;
}
var i = "function" == typeof __require && __require;
for (var o = 0; o < r.length; o++) s(r[o]);
return s;
})({}, {}, []);
//# sourceMappingURL=index.js.map

View File

@@ -0,0 +1 @@
{"version":3,"sources":[],"names":[],"mappings":"","sourcesContent":[],"file":"index.js"}

View File

@@ -0,0 +1,98 @@
{
"paths": {
"76ZjeTsCNJMYn7/rwRXCpD": [
"batch/spine-batch",
"cc.Prefab"
],
"03EprhmOVCZKUbb5XyPXQq": [
"skin/spine-skin",
"cc.Prefab"
]
},
"uuids": [
"76ZjeTsCNJMYn7/rwRXCpD",
"03EprhmOVCZKUbb5XyPXQq",
"ecpdLyjvZBwrvm+cedCcQy",
"a7ZscqX+JCIZRS157bMyhq",
"7a/QZLET9IDreTiBfRn2PD",
"93dM6KrkZCf5dgNpQwf7T6",
"85yTK+9shIo7RQfQ1TDEUi",
"09o3P/9gBP/Yc7AnxUBZ+Q",
"5cO7kybDxGj4ipyMYdRYZB",
"5f5dyqtRNNxaFmVzYns6FZ",
"a2MjXRFdtLlYQ5ouAFv/+R",
"f0BIwQ8D5Ml7nTNQbh1YlS",
"e97GVMl6JHh5Ml5qEDdSGa",
"29FYIk+N1GYaeWH/q1NxQO",
"70VXjGE0JMUqGli0jmCmTF",
"87/8ZHBEVIkKeNxmalrn9r",
"d0Bu8c2MBCKJc+mKBWzjsJ",
"e8Ueib+qJEhL6mXAHdnwbi",
"b4P/PCArtIdIH38t6mlw8Y",
"71VhFCTINJM6/Ky3oX9nBT"
],
"scenes": {},
"redirect": [
"ecpdLyjvZBwrvm+cedCcQy",
0,
"a7ZscqX+JCIZRS157bMyhq",
1,
"7a/QZLET9IDreTiBfRn2PD",
0,
"93dM6KrkZCf5dgNpQwf7T6",
1,
"85yTK+9shIo7RQfQ1TDEUi",
1,
"09o3P/9gBP/Yc7AnxUBZ+Q",
1,
"5cO7kybDxGj4ipyMYdRYZB",
2,
"5f5dyqtRNNxaFmVzYns6FZ",
2,
"a2MjXRFdtLlYQ5ouAFv/+R",
2,
"70VXjGE0JMUqGli0jmCmTF",
1,
"87/8ZHBEVIkKeNxmalrn9r",
1,
"d0Bu8c2MBCKJc+mKBWzjsJ",
1
],
"deps": [
"internal",
"common",
"main"
],
"packs": {
"05fa2ad10": [
"03EprhmOVCZKUbb5XyPXQq",
"29FYIk+N1GYaeWH/q1NxQO",
"71VhFCTINJM6/Ky3oX9nBT",
"76ZjeTsCNJMYn7/rwRXCpD",
"b4P/PCArtIdIH38t6mlw8Y",
"e8Ueib+qJEhL6mXAHdnwbi",
"e97GVMl6JHh5Ml5qEDdSGa",
"f0BIwQ8D5Ml7nTNQbh1YlS"
]
},
"name": "spine",
"importBase": "import",
"nativeBase": "native",
"debug": true,
"isZip": false,
"encrypted": false,
"versions": {
"import": [
"05fa2ad10",
"ef553"
],
"native": [
"71VhFCTINJM6/Ky3oX9nBT",
"c06a9",
"b4P/PCArtIdIH38t6mlw8Y",
"83fcc",
"e8Ueib+qJEhL6mXAHdnwbi",
"90cf4"
]
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,117 @@
window.__require = function e(t, n, r) {
function s(o, u) {
if (!n[o]) {
if (!t[o]) {
var b = o.split("/");
b = b[b.length - 1];
if (!t[b]) {
var a = "function" == typeof __require && __require;
if (!u && a) return a(b, !0);
if (i) return i(b, !0);
throw new Error("Cannot find module '" + o + "'");
}
o = b;
}
var f = n[o] = {
exports: {}
};
t[o][0].call(f.exports, function(e) {
var n = t[o][1][e];
return s(n || e);
}, f, f.exports, e, t, n, r);
}
return n[o].exports;
}
var i = "function" == typeof __require && __require;
for (var o = 0; o < r.length; o++) s(r[o]);
return s;
}({
"spine-skin": [ function(require, module, exports) {
"use strict";
cc._RF.push(module, "27990QihT9DxaLHUpAMue3v", "spine-skin");
"use strict";
var __extends = this && this.__extends || function() {
var extendStatics = function(d, b) {
extendStatics = Object.setPrototypeOf || {
__proto__: []
} instanceof Array && function(d, b) {
d.__proto__ = b;
} || function(d, b) {
for (var p in b) Object.prototype.hasOwnProperty.call(b, p) && (d[p] = b[p]);
};
return extendStatics(d, b);
};
return function(d, b) {
extendStatics(d, b);
function __() {
this.constructor = d;
}
d.prototype = null === b ? Object.create(b) : (__.prototype = b.prototype, new __());
};
}();
var __decorate = this && this.__decorate || function(decorators, target, key, desc) {
var c = arguments.length, r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
if ("object" === typeof Reflect && "function" === typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc); else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
return c > 3 && r && Object.defineProperty(target, key, r), r;
};
Object.defineProperty(exports, "__esModule", {
value: true
});
var _a = cc._decorator, ccclass = _a.ccclass, property = _a.property;
var SpineSkin = function(_super) {
__extends(SpineSkin, _super);
function SpineSkin() {
var _this = null !== _super && _super.apply(this, arguments) || this;
_this.addBoyBtn = null;
_this.removeBoyBtn = null;
_this.randomChangeBtn = null;
_this.boy = null;
_this.heads = [];
_this.boys = [];
return _this;
}
SpineSkin.prototype.start = function() {
var _this = this;
var boySpine = this.boy.getComponentInChildren(sp.Skeleton);
var newSkeletonData = boySpine.skeletonData.clone();
boySpine.skeletonData = newSkeletonData;
boySpine.animation = "attack";
this.boys.push(this.boy);
this.addBoyBtn.on("click", function() {
var newBoy = cc.instantiate(_this.boy);
var newBoySpine = newBoy.getComponentInChildren(sp.Skeleton);
newBoySpine.skeletonData = boySpine.skeletonData.clone();
newBoySpine.animation = "attack";
_this.boy.parent.addChild(newBoy);
newBoy.setPosition(_this.boys[_this.boys.length - 1].position);
newBoy.x += 100;
if (_this.boys.length % 2 === 1) {
newBoy.getComponentInChildren(sp.Skeleton).setAnimationCacheMode(sp.Skeleton.AnimationCacheMode.PRIVATE_CACHE);
newBoy.getComponentInChildren(cc.Label).string = "Spine - Cache";
}
_this.boys.push(newBoy);
});
this.removeBoyBtn.on("click", function() {
if (_this.boys.length > 1) {
_this.boys[_this.boys.length - 1].destroy();
_this.boys.length -= 1;
}
});
this.randomChangeBtn.on("click", function() {
var boy = _this.boys[_this.boys.length - 1].getComponentInChildren(sp.Skeleton);
boy.setRegion("Head", "Head", sp.SkeletonData.createRegion(_this.heads[Math.floor(Math.random() * _this.heads.length)]));
});
};
__decorate([ property(cc.Node) ], SpineSkin.prototype, "addBoyBtn", void 0);
__decorate([ property(cc.Node) ], SpineSkin.prototype, "removeBoyBtn", void 0);
__decorate([ property(cc.Node) ], SpineSkin.prototype, "randomChangeBtn", void 0);
__decorate([ property(cc.Node) ], SpineSkin.prototype, "boy", void 0);
__decorate([ property([ cc.SpriteFrame ]) ], SpineSkin.prototype, "heads", void 0);
SpineSkin = __decorate([ ccclass ], SpineSkin);
return SpineSkin;
}(cc.Component);
exports.default = SpineSkin;
cc._RF.pop();
}, {} ]
}, {}, [ "spine-skin" ]);
//# sourceMappingURL=index.js.map

View File

@@ -0,0 +1 @@
{"version":3,"sources":["assets/spine/skin/spine-skin.ts"],"names":["_a","cc","_decorator","ccclass","property","SpineSkin","_super","__extends","_this","apply","this","arguments","addBoyBtn","removeBoyBtn","randomChangeBtn","boy","heads","boys","prototype","start","boySpine","getComponentInChildren","sp","Skeleton","newSkeletonData","skeletonData","clone","animation","push","on","newBoy","instantiate","newBoySpine","parent","addChild","setPosition","length","position","x","setAnimationCacheMode","AnimationCacheMode","PRIVATE_CACHE","Label","string","destroy","setRegion","SkeletonData","createRegion","Math","floor","random","__decorate","Node","SpriteFrame","Component","exports","default"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAAM,IAAAA,KAAAC,GAAAC,YAAAC,UAAAH,GAAAG,SAAAC,WAAAJ,GAAAI;IAGN,IAAAC,YAAA,SAAAC;MAAuCC,UAAAF,WAAAC;MAAvC,SAAAD;QAAA,IAAAG,QAAA,SAAAF,UAAAA,OAAAG,MAAAC,MAAAC,cAAAD;QAGIF,MAAAI,YAAA;QAGAJ,MAAAK,eAAA;QAGAL,MAAAM,kBAAA;QAGAN,MAAAO,MAAA;QAGAP,MAAAQ,QAAA;QAEAR,MAAAS,OAAA;;;MAEUZ,UAAAa,UAAAC,QAAA;QAAV,IAAAX,QAAAE;QACI,IAAAU,WAAAV,KAAAK,IAAAM,uBAAAC,GAAAC;QACA,IAAAC,kBAAAJ,SAAAK,aAAAC;QACAN,SAAAK,eAAAD;QACAJ,SAAAO,YAAA;QAEAjB,KAAAO,KAAAW,KAAAlB,KAAAK;QAEAL,KAAAE,UAAAiB,GAAA,SAAA;UACI,IAAAC,SAAA7B,GAAA8B,YAAAvB,MAAAO;UACA,IAAAiB,cAAAF,OAAAT,uBAAAC,GAAAC;UACAS,YAAAP,eAAAL,SAAAK,aAAAC;UACAM,YAAAL,YAAA;UAEAnB,MAAAO,IAAAkB,OAAAC,SAAAJ;UACAA,OAAAK,YAAA3B,MAAAS,KAAAT,MAAAS,KAAAmB,SAAA,GAAAC;UACAP,OAAAQ,KAAA;UACA,IAAA9B,MAAAS,KAAAmB,SAAA,MAAA,GAAA;YACIN,OAAAT,uBAAAC,GAAAC,UAAAgB,sBAAAjB,GAAAC,SAAAiB,mBAAAC;YACAX,OAAAT,uBAAApB,GAAAyC,OAAAC,SAAA;;UAEJnC,MAAAS,KAAAW,KAAAE;;QAGJpB,KAAAG,aAAAgB,GAAA,SAAA;UACI,IAAArB,MAAAS,KAAAmB,SAAA,GAAA;YACI5B,MAAAS,KAAAT,MAAAS,KAAAmB,SAAA,GAAAQ;YACApC,MAAAS,KAAAmB,UAAA;;;QAIR1B,KAAAI,gBAAAe,GAAA,SAAA;UACI,IAAAd,MAAAP,MAAAS,KAAAT,MAAAS,KAAAmB,SAAA,GAAAf,uBAAAC,GAAAC;UACAR,IAAA8B,UAAA,QAAA,QAAAvB,GAAAwB,aAAAC,aAAAvC,MAAAQ,MAAAgC,KAAAC,MAAAD,KAAAE,WAAA1C,MAAAQ,MAAA;;;MAjDRmC,WAAA,EADC/C,SAAAH,GAAAmD,SACyB/C,UAAAa,WAAA,kBAAA;MAG1BiC,WAAA,EADC/C,SAAAH,GAAAmD,SAC4B/C,UAAAa,WAAA,qBAAA;MAG7BiC,WAAA,EADC/C,SAAAH,GAAAmD,SAC+B/C,UAAAa,WAAA,wBAAA;MAGhCiC,WAAA,EADC/C,SAAAH,GAAAmD,SACmB/C,UAAAa,WAAA,YAAA;MAGpBiC,WAAA,EADC/C,SAAA,EAAAH,GAAAoD,kBAC4BhD,UAAAa,WAAA,cAAA;MAfZb,YAAA8C,WAAA,EADpBhD,WACoBE;MAwDrB,OAAAA;KAxDA,CAAAJ,GAAAqD;IAAqBC,QAAAC,UAAAnD","sourcesContent":["const { ccclass, property } = cc._decorator;\n\n@ccclass\nexport default class SpineSkin extends cc.Component {\n\n @property(cc.Node)\n addBoyBtn: cc.Node = null;\n\n @property(cc.Node)\n removeBoyBtn: cc.Node = null;\n\n @property(cc.Node)\n randomChangeBtn: cc.Node = null;\n\n @property(cc.Node)\n boy: cc.Node = null;\n\n @property([cc.SpriteFrame])\n heads: cc.SpriteFrame[] = [];\n\n boys: cc.Node[] = [];\n\n protected start(): void {\n const boySpine = this.boy.getComponentInChildren(sp.Skeleton);\n const newSkeletonData = boySpine.skeletonData.clone();\n boySpine.skeletonData = newSkeletonData;\n boySpine.animation = 'attack';\n\n this.boys.push(this.boy);\n\n this.addBoyBtn.on('click', () => {\n const newBoy = cc.instantiate(this.boy);\n const newBoySpine = newBoy.getComponentInChildren(sp.Skeleton);\n newBoySpine.skeletonData = boySpine.skeletonData.clone();\n newBoySpine.animation = 'attack';\n\n this.boy.parent.addChild(newBoy);\n newBoy.setPosition(this.boys[this.boys.length - 1].position);\n newBoy.x += 100;\n if (this.boys.length % 2 === 1) {\n newBoy.getComponentInChildren(sp.Skeleton).setAnimationCacheMode(sp.Skeleton.AnimationCacheMode.PRIVATE_CACHE);\n newBoy.getComponentInChildren(cc.Label).string = `Spine - Cache`;\n }\n this.boys.push(newBoy);\n });\n\n this.removeBoyBtn.on('click', () => {\n if (this.boys.length > 1) {\n this.boys[this.boys.length - 1].destroy();\n this.boys.length -= 1;\n }\n });\n\n this.randomChangeBtn.on('click', () => {\n const boy = this.boys[this.boys.length - 1].getComponentInChildren(sp.Skeleton);\n boy.setRegion('Head', 'Head', sp.SkeletonData.createRegion(this.heads[Math.floor(Math.random() * (this.heads.length))]));\n });\n }\n\n}\n"],"file":"index.js"}

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

View File

@@ -0,0 +1,54 @@
{
"paths": {
"f4jvTRdINIaICWEVrgQxx2": [
"char-mode/char-mode",
"cc.Prefab"
],
"e2Z8EqOaxB256X3o4ZbClt": [
"high-dpi/high-dpi",
"cc.Prefab"
]
},
"uuids": [
"f4jvTRdINIaICWEVrgQxx2",
"e2Z8EqOaxB256X3o4ZbClt",
"ecpdLyjvZBwrvm+cedCcQy",
"5cO7kybDxGj4ipyMYdRYZB",
"5f5dyqtRNNxaFmVzYns6FZ",
"a2MjXRFdtLlYQ5ouAFv/+R"
],
"scenes": {},
"redirect": [
"ecpdLyjvZBwrvm+cedCcQy",
0,
"5cO7kybDxGj4ipyMYdRYZB",
1,
"5f5dyqtRNNxaFmVzYns6FZ",
1,
"a2MjXRFdtLlYQ5ouAFv/+R",
1
],
"deps": [
"internal",
"main"
],
"packs": {
"0dccb646b": [
"e2Z8EqOaxB256X3o4ZbClt",
"f4jvTRdINIaICWEVrgQxx2"
]
},
"name": "text-render",
"importBase": "import",
"nativeBase": "native",
"debug": true,
"isZip": false,
"encrypted": false,
"versions": {
"import": [
"0dccb646b",
"61654"
],
"native": []
}
}

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long