更新文档到 2.4.9-v1.0.0

This commit is contained in:
SmallMain
2022-07-05 18:10:58 +08:00
parent b89bb48ce7
commit 746d9ce5cd
267 changed files with 8506 additions and 5284 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -1,321 +0,0 @@
[
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

@@ -1 +0,0 @@
{"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"}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -1,321 +0,0 @@
[
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

@@ -1 +0,0 @@
{"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"}

File diff suppressed because one or more lines are too long

View File

@@ -8,28 +8,28 @@
"fonts/SFNSMonoItalic",
"cc.TTFFont"
],
"80AR/OlBFOoajT99htLYeJ": [
"fonts/normalFont",
"cc.BitmapFont"
],
"45vlnzVlVDaZ6fRVyB0t3Z": [
"fonts/normalFont",
"cc.Texture2D"
],
"80AR/OlBFOoajT99htLYeJ": [
"fonts/normalFont",
"cc.BitmapFont"
],
"92aqwImq1Ik7GrBSFnKTF2": [
"fonts/normalFont",
"cc.SpriteFrame",
1
],
"c1Hf3Sl8ZAnJwP/fpoHxap": [
"images/1655112479313",
"cc.Texture2D"
],
"a7ZscqX+JCIZRS157bMyhq": [
"images/1655112479313",
"cc.SpriteFrame",
1
],
"c1Hf3Sl8ZAnJwP/fpoHxap": [
"images/1655112479313",
"cc.Texture2D"
],
"62MQQadaVK8qQN8n6UmJAa": [
"images/1655112514006",
"cc.Texture2D"
@@ -39,17 +39,13 @@
"cc.SpriteFrame",
1
],
"39jYWzSTREwI2OOBK5nwFe": [
"images/1655112526123",
"cc.Texture2D"
],
"09o3P/9gBP/Yc7AnxUBZ+Q": [
"images/1655112526123",
"cc.SpriteFrame",
1
],
"d0bST/wYpJQIL5T+PCq46W": [
"images/1655112538161",
"39jYWzSTREwI2OOBK5nwFe": [
"images/1655112526123",
"cc.Texture2D"
],
"70VXjGE0JMUqGli0jmCmTF": [
@@ -57,6 +53,10 @@
"cc.SpriteFrame",
1
],
"d0bST/wYpJQIL5T+PCq46W": [
"images/1655112538161",
"cc.Texture2D"
],
"68Q/ALDvRLfKrAQu5CY15V": [
"images/1655112548981",
"cc.Texture2D"
@@ -84,15 +84,15 @@
"cc.SpriteFrame",
1
],
"a97PGbCjtNjr/hYUBJUJ3p": [
"images/1655799093442",
"cc.Texture2D"
],
"34Wm35ZlJBApgKytyVFWhX": [
"images/1655799093442",
"cc.SpriteFrame",
1
],
"a97PGbCjtNjr/hYUBJUJ3p": [
"images/1655799093442",
"cc.Texture2D"
],
"2cDGL4OAVN0ZbEl3w2urT8": [
"materials/custom-2d-sprite",
"cc.Material"
@@ -101,19 +101,40 @@
"spines/huatuo",
"cc.Asset"
],
"93dM6KrkZCf5dgNpQwf7T6": [
"spines/huatuo",
"sp.SkeletonData"
],
"80ThG1v09KeKxKhEPnFmvh": [
"spines/huatuo",
"cc.Texture2D"
],
"93dM6KrkZCf5dgNpQwf7T6": [
"spines/huatuo",
"sp.SkeletonData"
],
"b5ObM0rx1GDKGN3k5VlH0s": [
"spines/huatuo",
"cc.SpriteFrame",
1
],
"07GcDk8RNGZbcrHAq5lPag": [
"spines/shengxing_kuang",
"cc.SpriteFrame",
1
],
"3479J6IuROz7rZhiZpn63y": [
"spines/shengxing_kuang",
"sp.SkeletonData"
],
"37/FrRNqBAiadz9TDqSpRx": [
"spines/shengxing_kuang",
"cc.Asset"
],
"aaYr2KZ+xPDqeLsRHUKxRA": [
"spines/shengxing_kuang",
"cc.Texture2D"
],
"b6OkwTsm1LK5cvRTwFehiy": [
"spines/spineboy",
"cc.TextAsset"
],
"bc2ZOJo5NCbrI0FXxitEvE": [
"spines/spineboy",
"sp.SkeletonData"
@@ -126,54 +147,57 @@
"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",
"07GcDk8RNGZbcrHAq5lPag",
"09o3P/9gBP/Yc7AnxUBZ+Q",
"d0bST/wYpJQIL5T+PCq46W",
"70VXjGE0JMUqGli0jmCmTF",
"68Q/ALDvRLfKrAQu5CY15V",
"87/8ZHBEVIkKeNxmalrn9r",
"70JFWsm5JN17FDywI0Lb5I",
"d0Bu8c2MBCKJc+mKBWzjsJ",
"1cijzBpFJCdoSNK98w5oUq",
"8029xEf4FHy49dWo6NK8c7",
"a97PGbCjtNjr/hYUBJUJ3p",
"34Wm35ZlJBApgKytyVFWhX",
"2cDGL4OAVN0ZbEl3w2urT8",
"34Wm35ZlJBApgKytyVFWhX",
"3479J6IuROz7rZhiZpn63y",
"37/FrRNqBAiadz9TDqSpRx",
"39jYWzSTREwI2OOBK5nwFe",
"3e30KyALhNkZttyuW0A6EU",
"45vlnzVlVDaZ6fRVyB0t3Z",
"62MQQadaVK8qQN8n6UmJAa",
"68Q/ALDvRLfKrAQu5CY15V",
"69Fj/0+E5NeI6nlG9iAH/N",
"93dM6KrkZCf5dgNpQwf7T6",
"6eBWFz0oVHPLIGQKf/9Thu",
"70JFWsm5JN17FDywI0Lb5I",
"70VXjGE0JMUqGli0jmCmTF",
"80AR/OlBFOoajT99htLYeJ",
"80ThG1v09KeKxKhEPnFmvh",
"8029xEf4FHy49dWo6NK8c7",
"85yTK+9shIo7RQfQ1TDEUi",
"87/8ZHBEVIkKeNxmalrn9r",
"92aqwImq1Ik7GrBSFnKTF2",
"93dM6KrkZCf5dgNpQwf7T6",
"a7ZscqX+JCIZRS157bMyhq",
"a97PGbCjtNjr/hYUBJUJ3p",
"aaYr2KZ+xPDqeLsRHUKxRA",
"b5ObM0rx1GDKGN3k5VlH0s",
"bc2ZOJo5NCbrI0FXxitEvE",
"d9xFMK7wVFwbAS60aG9McP",
"f2P0YcCjtHDqebnuMp4CMZ",
"b6OkwTsm1LK5cvRTwFehiy",
"6eBWFz0oVHPLIGQKf/9Thu"
"bc2ZOJo5NCbrI0FXxitEvE",
"c1Hf3Sl8ZAnJwP/fpoHxap",
"d0Bu8c2MBCKJc+mKBWzjsJ",
"d0bST/wYpJQIL5T+PCq46W",
"d9xFMK7wVFwbAS60aG9McP",
"e8ql4cBzBOvoGh5/oNub59",
"f2P0YcCjtHDqebnuMp4CMZ"
],
"scenes": {},
"redirect": [],
"deps": [],
"packs": {
"0472ad032": [
"01d612a1e": [
"07GcDk8RNGZbcrHAq5lPag",
"09o3P/9gBP/Yc7AnxUBZ+Q",
"1cijzBpFJCdoSNK98w5oUq",
"2cDGL4OAVN0ZbEl3w2urT8",
"34Wm35ZlJBApgKytyVFWhX",
"3479J6IuROz7rZhiZpn63y",
"37/FrRNqBAiadz9TDqSpRx",
"39jYWzSTREwI2OOBK5nwFe",
"3e30KyALhNkZttyuW0A6EU",
"45vlnzVlVDaZ6fRVyB0t3Z",
@@ -192,6 +216,7 @@
"93dM6KrkZCf5dgNpQwf7T6",
"a7ZscqX+JCIZRS157bMyhq",
"a97PGbCjtNjr/hYUBJUJ3p",
"aaYr2KZ+xPDqeLsRHUKxRA",
"b5ObM0rx1GDKGN3k5VlH0s",
"b6OkwTsm1LK5cvRTwFehiy",
"bc2ZOJo5NCbrI0FXxitEvE",
@@ -211,12 +236,14 @@
"encrypted": false,
"versions": {
"import": [
"0472ad032",
"4b502"
"01d612a1e",
"92a17"
],
"native": [
"1cijzBpFJCdoSNK98w5oUq",
"91637",
"37/FrRNqBAiadz9TDqSpRx",
"6e46c",
"39jYWzSTREwI2OOBK5nwFe",
"2eb47",
"45vlnzVlVDaZ6fRVyB0t3Z",
@@ -235,6 +262,8 @@
"fd38c",
"a97PGbCjtNjr/hYUBJUJ3p",
"0f278",
"aaYr2KZ+xPDqeLsRHUKxRA",
"48cd8",
"c1Hf3Sl8ZAnJwP/fpoHxap",
"d86d7",
"d0bST/wYpJQIL5T+PCq46W",

View File

@@ -1,6 +1,7 @@
[
1,
[
"aaYr2KZ+xPDqeLsRHUKxRA",
"62MQQadaVK8qQN8n6UmJAa",
"80ThG1v09KeKxKhEPnFmvh",
"d9xFMK7wVFwbAS60aG9McP",
@@ -35,32 +36,6 @@
2,
11
],
[
"cc.EffectAsset",
[
"_name",
"shaders",
"techniques"
],
0
],
[
"cc.Asset",
[
"_name",
"_native"
],
1
],
[
"cc.BitmapFont",
[
"_name",
"fontSize",
"_fntConfig"
],
0
],
[
"sp.SkeletonData",
[
@@ -73,6 +48,32 @@
-1,
3
],
[
"cc.Asset",
[
"_name",
"_native"
],
1
],
[
"cc.EffectAsset",
[
"_name",
"shaders",
"techniques"
],
0
],
[
"cc.BitmapFont",
[
"_name",
"fontSize",
"_fntConfig"
],
0
],
[
"cc.TextAsset",
[
@@ -92,7 +93,7 @@
],
[
[
6,
3,
0,
1,
2,
@@ -100,25 +101,18 @@
4,
5
],
[
2,
0,
1,
2
],
[
3,
0,
1,
2,
4
],
[
4,
0,
1,
3
],
[
2,
0,
1,
2
],
[
5,
0,
@@ -126,6 +120,13 @@
2,
4
],
[
6,
0,
1,
2,
4
],
[
7,
0,
@@ -140,6 +141,46 @@
]
],
[
[
[
{
"name": "shengxing_kuang",
"rect": [
2,
2,
176,
347
],
"offset": [
0,
0
],
"originalSize": [
180,
351
],
"capInsets": [
0,
0,
0,
0
]
}
],
[
1
],
0,
[
0
],
[
0
],
[
0
]
],
[
[
{
@@ -177,7 +218,7 @@
0
],
[
3
4
]
],
[
@@ -196,7 +237,7 @@
[
[
[
1,
2,
"custom-2d-sprite",
[
{},
@@ -241,9 +282,9 @@
3
],
[
0,
4,
5
1,
5,
6
]
],
[
@@ -283,9 +324,174 @@
0
],
[
6
7
]
],
[
[
[
0,
"shengxing_kuang",
"\nshengxing_kuang.png\nsize: 180,351\nformat: RGBA8888\nfilter: Linear,Linear\nrepeat: none\nfx_frame_red\n rotate: false\n xy: 2, 2\n size: 176, 347\n orig: 180, 351\n offset: 2, 2\n index: -1\n",
[
"shengxing_kuang.png"
],
{
"skeleton": {
"hash": "X8GrJN5Hvt74DISCwkkMDigOeyA",
"spine": "3.8.99",
"x": -180,
"y": -351,
"width": 360,
"height": 702,
"images": "./images/",
"audio": ""
},
"bones": [
{
"name": "root"
},
{
"name": "fx_frame",
"parent": "root"
}
],
"slots": [
{
"name": "fx_frame",
"bone": "fx_frame",
"color": "ffffff00",
"dark": "000000",
"attachment": "fx_frame_red",
"blend": "additive"
}
],
"skins": [
{
"name": "default",
"attachments": {
"fx_frame": {
"fx_frame_red": {
"scaleX": 2,
"scaleY": 2,
"width": 180,
"height": 351
}
}
}
}
],
"animations": {
"shengxing_kuang_r": {
"slots": {
"fx_frame": {
"twoColor": [
{
"light": "4aff91c6",
"dark": "009a3e",
"curve": 0.25,
"c3": 0.75
},
{
"time": 0.5,
"light": "49ff9100",
"dark": "009a3e"
}
]
}
}
},
"shengxing_kuang_s": {
"slots": {
"fx_frame": {
"twoColor": [
{
"light": "ffffffc6",
"dark": "fc00ff",
"curve": 0.25,
"c3": 0.75
},
{
"time": 0.5,
"light": "ffffff00",
"dark": "fc00ff"
}
]
}
}
},
"shengxing_kuang_sr": {
"slots": {
"fx_frame": {
"twoColor": [
{
"light": "ffffffc6",
"dark": "ff7300",
"curve": 0.25,
"c3": 0.75
},
{
"time": 0.5,
"light": "ffffff00",
"dark": "ff7300"
}
]
}
}
},
"shengxing_kuang_ssr": {
"slots": {
"fx_frame": {
"twoColor": [
{
"light": "ffffffc5",
"dark": "000000",
"curve": 0.25,
"c3": 0.75
},
{
"time": 0.5,
"light": "ffffff00",
"dark": "000000"
}
]
}
}
}
}
},
[
0
]
]
],
0,
0,
[
0
],
[
-1
],
[
0
]
],
[
[
[
1,
"shengxing_kuang",
".atlas"
],
-1
],
0,
0,
[],
[],
[]
],
[
[
"0,9729,9729,33071,33071,0,0,1",
@@ -302,7 +508,7 @@
[
[
[
2,
3,
"custom-2d-sprite",
[
{
@@ -703,7 +909,7 @@
[
[
[
3,
1,
"huatuo",
".atlas"
],
@@ -778,7 +984,7 @@
0
],
[
7
8
]
],
[
@@ -3058,7 +3264,7 @@
4
],
[
8
9
]
],
[
@@ -3111,7 +3317,7 @@
0
],
[
9
10
]
],
[
@@ -3151,7 +3357,7 @@
0
],
[
0
1
]
],
[
@@ -3191,7 +3397,7 @@
0
],
[
10
11
]
],
[
@@ -3231,7 +3437,7 @@
0
],
[
11
12
]
],
[
@@ -17799,7 +18005,7 @@
"L-Thigh": {
"height": 35,
"hull": 11,
"type": "skinnedmesh",
"type": "mesh",
"width": 29,
"edges": [
0,
@@ -18050,7 +18256,7 @@
"R-Thigh": {
"height": 36,
"hull": 12,
"type": "skinnedmesh",
"type": "mesh",
"width": 30,
"edges": [
0,
@@ -18268,7 +18474,7 @@
"beilou": {
"height": 148,
"hull": 18,
"type": "skinnedmesh",
"type": "mesh",
"width": 113,
"edges": [
0,
@@ -18744,7 +18950,7 @@
-1
],
[
1
2
]
],
[
@@ -18784,7 +18990,7 @@
0
],
[
12
13
]
],
[
@@ -18800,6 +19006,19 @@
[],
[]
],
[
[
"0,9729,9729,33071,33071,0,0,1",
-1
],
[
0
],
0,
[],
[],
[]
],
[
[
{
@@ -18837,7 +19056,7 @@
0
],
[
1
2
]
],
[
@@ -25249,7 +25468,7 @@
-1
],
[
2
3
]
],
[
@@ -25302,7 +25521,7 @@
0
],
[
13
14
]
],
[
@@ -25383,7 +25602,7 @@
0
],
[
2
3
]
]
]

View File

@@ -0,0 +1,13 @@
shengxing_kuang.png
size: 180,351
format: RGBA8888
filter: Linear,Linear
repeat: none
fx_frame_red
rotate: false
xy: 2, 2
size: 176, 347
orig: 180, 351
offset: 2, 2
index: -1

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.1 KiB

View File

@@ -6,46 +6,46 @@
]
},
"uuids": [
"e3EaADwKFP+ZmDIVTeFF63",
"ecpdLyjvZBwrvm+cedCcQy",
"312JYturtOx74Zjp9UpOqZ",
"e7q6FL+VZEgLJUjVeDLic/",
"02kcE0s9pAmLe145ftvpR/",
"29FYIk+N1GYaeWH/q1NxQO",
"68J8oyAQdFUrqy37MXmbtE",
"90AErWL21A4ZPvtxQ3XG8G",
"312JYturtOx74Zjp9UpOqZ",
"34Wm35ZlJBApgKytyVFWhX",
"7a/QZLET9IDreTiBfRn2PD",
"93dM6KrkZCf5dgNpQwf7T6",
"56fc2Ai/RFNYpaMT8crweK",
"5cO7kybDxGj4ipyMYdRYZB",
"5f5dyqtRNNxaFmVzYns6FZ",
"a2MjXRFdtLlYQ5ouAFv/+R",
"02kcE0s9pAmLe145ftvpR/",
"56fc2Ai/RFNYpaMT8crweK",
"d2kHe6FidKcpV5e1aiNTQM",
"68J8oyAQdFUrqy37MXmbtE",
"71VhFCTINJM6/Ky3oX9nBT",
"73oJA92A5OPKpn+ZlUPAj1"
"73oJA92A5OPKpn+ZlUPAj1",
"7a/QZLET9IDreTiBfRn2PD",
"90AErWL21A4ZPvtxQ3XG8G",
"93dM6KrkZCf5dgNpQwf7T6",
"a2MjXRFdtLlYQ5ouAFv/+R",
"d2kHe6FidKcpV5e1aiNTQM",
"e3EaADwKFP+ZmDIVTeFF63",
"e7q6FL+VZEgLJUjVeDLic/",
"ecpdLyjvZBwrvm+cedCcQy"
],
"scenes": {},
"redirect": [
"ecpdLyjvZBwrvm+cedCcQy",
0,
"34Wm35ZlJBApgKytyVFWhX",
0,
"5cO7kybDxGj4ipyMYdRYZB",
1,
"5f5dyqtRNNxaFmVzYns6FZ",
1,
"7a/QZLET9IDreTiBfRn2PD",
0,
2,
"93dM6KrkZCf5dgNpQwf7T6",
1,
"5cO7kybDxGj4ipyMYdRYZB",
2,
"5f5dyqtRNNxaFmVzYns6FZ",
2,
0,
"a2MjXRFdtLlYQ5ouAFv/+R",
1,
"ecpdLyjvZBwrvm+cedCcQy",
2
],
"deps": [
"internal",
"common",
"main"
"main",
"internal"
],
"packs": {
"025f75dc8": [

View File

@@ -76,6 +76,7 @@ window.__require = function e(t, n, r) {
var _this = this;
this.prefabs = this.objects.children.concat();
this.objects.removeAllChildren(false);
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);

File diff suppressed because one or more lines are too long

View File

@@ -70,24 +70,24 @@
]
},
"uuids": [
"30aC+Hnw1PF4pEcoY3kUYb",
"14TDKXr2NJ6LjvHPops74o",
"f1h0LXVtJOta5JLZ1xCzfI",
"02delMVqdBD70a/HSD99FK",
"0ek66qC1NOQLjgYmi04HvX",
"14TDKXr2NJ6LjvHPops74o",
"28dPjdQWxEQIG3VVl1Qm6T",
"2aKWBXJHxKHLvrBUi2yYZQ",
"2afAA24LNP4YmYiaVLiivs",
"c0BAyVxX9JzZy8EjFrc9DU",
"30aC+Hnw1PF4pEcoY3kUYb",
"3ae7efMv1CLq2ilvUY/tQi",
"46bU+b5fROqIXVPG6aZWWK",
"6dkeWRTOBGXICfYQ7JUBnG",
"6fgBCSDDdPMInvyNlggls2",
"a1U5RdJRFMFL57BdJC9H1X",
"3ae7efMv1CLq2ilvUY/tQi",
"e0LYfU5ZlNFoAB4UiRrGUG",
"7a/QZLET9IDreTiBfRn2PD",
"ecpdLyjvZBwrvm+cedCcQy",
"46bU+b5fROqIXVPG6aZWWK",
"a1U5RdJRFMFL57BdJC9H1X",
"c0BAyVxX9JzZy8EjFrc9DU",
"cffgu4qBxEqa150o1DmRAy",
"2aKWBXJHxKHLvrBUi2yYZQ",
"02delMVqdBD70a/HSD99FK"
"e0LYfU5ZlNFoAB4UiRrGUG",
"ecpdLyjvZBwrvm+cedCcQy",
"f1h0LXVtJOta5JLZ1xCzfI"
],
"scenes": {},
"redirect": [],
@@ -123,7 +123,7 @@
"versions": {
"import": [
"0967b326a",
"c3301"
"eef84"
],
"native": [
"02delMVqdBD70a/HSD99FK",

View File

@@ -308,16 +308,16 @@
"builtin-2d-sprite",
[
{
"hash": 3278106612,
"hash": 2440430725,
"record": null,
"name": "builtin-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#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 #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#endif\nvoid main () {\n vec4 o = vec4(1, 1, 1, 1);\n #if USE_TEXTURE\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 o *= v_color;\n ALPHA_TEST(o);\n gl_FragColor = o;\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#endif\nvoid main () {\n vec4 o = vec4(1, 1, 1, 1);\n #if USE_TEXTURE\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 o *= v_color;\n ALPHA_TEST(o);\n #if USE_BGRA\n gl_FragColor = o.bgra;\n #else\n gl_FragColor = o.rgba;\n #endif\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#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 #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#endif\nvoid main () {\n vec4 o = vec4(1, 1, 1, 1);\n #if USE_TEXTURE\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 o *= v_color;\n ALPHA_TEST(o);\n gl_FragColor = o;\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#endif\nvoid main () {\n vec4 o = vec4(1, 1, 1, 1);\n #if USE_TEXTURE\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 o *= v_color;\n ALPHA_TEST(o);\n #if USE_BGRA\n gl_FragColor = o.bgra;\n #else\n gl_FragColor = o.rgba;\n #endif\n}"
},
"builtins": {
"globals": {
@@ -368,6 +368,11 @@
"defines": [
"USE_TEXTURE"
]
},
{
"name": "USE_BGRA",
"type": "boolean",
"defines": []
}
],
"blocks": [
@@ -1592,7 +1597,7 @@
},
"depthStencilState": {
"depthTest": true,
"depthWrite": true
"depthWrite": false
},
"properties": {
"diffuseTexture": {

View File

@@ -1,22 +1,22 @@
{
"paths": {},
"uuids": [
"catK9m3HRBtYgmebOjC6ma",
"ecpdLyjvZBwrvm+cedCcQy",
"a2MjXRFdtLlYQ5ouAFv/+R",
"02delMVqdBD70a/HSD99FK",
"5cO7kybDxGj4ipyMYdRYZB",
"5f5dyqtRNNxaFmVzYns6FZ",
"02delMVqdBD70a/HSD99FK",
"61cyPdEfRN047sDK9rO0W5",
"d608qFRoFHwbXd0Dap056i"
"a2MjXRFdtLlYQ5ouAFv/+R",
"catK9m3HRBtYgmebOjC6ma",
"d608qFRoFHwbXd0Dap056i",
"ecpdLyjvZBwrvm+cedCcQy"
],
"scenes": {
"db://assets/main.fire": "catK9m3HRBtYgmebOjC6ma"
},
"redirect": [
"ecpdLyjvZBwrvm+cedCcQy",
0,
"02delMVqdBD70a/HSD99FK",
0,
"ecpdLyjvZBwrvm+cedCcQy",
0
],
"deps": [

View File

@@ -231,6 +231,8 @@ window.__require = function e(t, n, r) {
}(cc.Component);
exports.default = Main;
cc.sp.labelRetinaScale = 2;
cc.sp.charAtlasAutoBatchCount = 2;
cc.macro.CLEANUP_IMAGE_CACHE = false;
cc.dynamicAtlasManager.maxFrameSize = 2048;
cc._RF.pop();
}, {} ]

File diff suppressed because one or more lines are too long

View File

@@ -18,15 +18,15 @@
"cc.SpriteFrame",
1
],
"ebcqWiiDdPRaJKJIbu9ft4": [
"multi-batcher/images/png",
"cc.Texture2D"
],
"0a5R1NT2lDxqcI2pwtgfb1": [
"multi-batcher/images/png",
"cc.SpriteFrame",
1
],
"ebcqWiiDdPRaJKJIbu9ft4": [
"multi-batcher/images/png",
"cc.Texture2D"
],
"22JHeF7zBLZqnS68r2p/bo": [
"multi-batcher/images/pvrtc2_rgb_a",
"cc.Texture2D"
@@ -63,15 +63,15 @@
"cc.SpriteFrame",
1
],
"7aeIQwZiFL1YbOCVeiFt1p": [
"multi-batcher/images/sheep_run_1",
"cc.Texture2D"
],
"55URLSNf5K3IyZBezfiMKa": [
"multi-batcher/images/sheep_run_1",
"cc.SpriteFrame",
1
],
"7aeIQwZiFL1YbOCVeiFt1p": [
"multi-batcher/images/sheep_run_1",
"cc.Texture2D"
],
"14W7pBGWJJ7q7JCPsVTovy": [
"multi-batcher/multi-batcher",
"cc.Prefab"
@@ -86,83 +86,89 @@
]
},
"uuids": [
"77hE9EwNpMlKl/+sGrhEVR",
"c4+eoUuahAOa4lmC/4Hkdi",
"b6FhIxTWVHXKa7qBmehR6I",
"eahTDGUrZBV4Y+i+JslTuW",
"ebcqWiiDdPRaJKJIbu9ft4",
"0a5R1NT2lDxqcI2pwtgfb1",
"0eAM9yHrBFe4PSAXHMHNl+",
"10Drosz6JPsKWsqV+bRh/A",
"14W7pBGWJJ7q7JCPsVTovy",
"1cijzBpFJCdoSNK98w5oUq",
"22JHeF7zBLZqnS68r2p/bo",
"29FYIk+N1GYaeWH/q1NxQO",
"2cDGL4OAVN0ZbEl3w2urT8",
"2dPOEW20pCTLs79c0WyZVp",
"3479J6IuROz7rZhiZpn63y",
"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",
"e8Ueib+qJEhL6mXAHdnwbi",
"5dz/wYuRNGDqDZXXT0zaEr",
"c1Hf3Sl8ZAnJwP/fpoHxap",
"1cijzBpFJCdoSNK98w5oUq",
"45vlnzVlVDaZ6fRVyB0t3Z",
"d9xFMK7wVFwbAS60aG9McP",
"55URLSNf5K3IyZBezfiMKa",
"5cO7kybDxGj4ipyMYdRYZB",
"5dz/wYuRNGDqDZXXT0zaEr",
"5f5dyqtRNNxaFmVzYns6FZ",
"6eBWFz0oVHPLIGQKf/9Thu",
"71VhFCTINJM6/Ky3oX9nBT",
"77hE9EwNpMlKl/+sGrhEVR",
"7aeIQwZiFL1YbOCVeiFt1p",
"80AR/OlBFOoajT99htLYeJ",
"8029xEf4FHy49dWo6NK8c7",
"8c20Sso/ZEn7NUfNSM+EBh",
"8fHzmU6I5EBqjpHEb0Xl3i",
"a2MjXRFdtLlYQ5ouAFv/+R",
"a7ZscqX+JCIZRS157bMyhq",
"aaYr2KZ+xPDqeLsRHUKxRA",
"b4P/PCArtIdIH38t6mlw8Y",
"71VhFCTINJM6/Ky3oX9nBT"
"b48cuQCqRMLaIzf9I1fTbW",
"b6FhIxTWVHXKa7qBmehR6I",
"bc2ZOJo5NCbrI0FXxitEvE",
"c1Hf3Sl8ZAnJwP/fpoHxap",
"c4+eoUuahAOa4lmC/4Hkdi",
"c58wUeG09DhJOcuDi8uPW/",
"d9xFMK7wVFwbAS60aG9McP",
"e8Ueib+qJEhL6mXAHdnwbi",
"e97GVMl6JHh5Ml5qEDdSGa",
"eahTDGUrZBV4Y+i+JslTuW",
"ebcqWiiDdPRaJKJIbu9ft4",
"ecpdLyjvZBwrvm+cedCcQy",
"f0BIwQ8D5Ml7nTNQbh1YlS"
],
"scenes": {},
"redirect": [
"ecpdLyjvZBwrvm+cedCcQy",
"1cijzBpFJCdoSNK98w5oUq",
0,
"2cDGL4OAVN0ZbEl3w2urT8",
0,
"3479J6IuROz7rZhiZpn63y",
0,
"45vlnzVlVDaZ6fRVyB0t3Z",
0,
"5cO7kybDxGj4ipyMYdRYZB",
1,
"5f5dyqtRNNxaFmVzYns6FZ",
1,
"6eBWFz0oVHPLIGQKf/9Thu",
0,
"80AR/OlBFOoajT99htLYeJ",
0,
"8029xEf4FHy49dWo6NK8c7",
0,
"a2MjXRFdtLlYQ5ouAFv/+R",
1,
"8029xEf4FHy49dWo6NK8c7",
2,
"a7ZscqX+JCIZRS157bMyhq",
2,
"80AR/OlBFOoajT99htLYeJ",
2,
"6eBWFz0oVHPLIGQKf/9Thu",
2,
0,
"aaYr2KZ+xPDqeLsRHUKxRA",
0,
"bc2ZOJo5NCbrI0FXxitEvE",
2,
"2cDGL4OAVN0ZbEl3w2urT8",
2,
0,
"c1Hf3Sl8ZAnJwP/fpoHxap",
2,
"1cijzBpFJCdoSNK98w5oUq",
2,
"45vlnzVlVDaZ6fRVyB0t3Z",
2,
0,
"d9xFMK7wVFwbAS60aG9McP",
0,
"ecpdLyjvZBwrvm+cedCcQy",
2
],
"deps": [
"internal",
"common",
"main",
"common"
"internal"
],
"packs": {
"03de068c3": [
@@ -204,7 +210,7 @@
"versions": {
"import": [
"03de068c3",
"a5082"
"732a1"
],
"native": [
"10Drosz6JPsKWsqV+bRh/A",

View File

@@ -1,7 +1,7 @@
{
"paths": {
"5dz/wYuRNGDqDZXXT0zaEr": [
"effects/multi-2d-sprite",
"effects/multi-2d-universal",
"cc.EffectAsset"
]
},
@@ -21,7 +21,7 @@
"versions": {
"import": [
"5dz/wYuRNGDqDZXXT0zaEr",
"a50cc"
"d60ab"
],
"native": []
}

View File

@@ -0,0 +1,326 @@
[
1,
0,
0,
[
[
"cc.EffectAsset",
[
"_name",
"shaders",
"techniques"
],
0
]
],
[
[
0,
0,
1,
2,
4
]
],
[
[
0,
"multi-2d-universal",
[
{
"hash": 501441714,
"record": null,
"name": "multi-2d-universal|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_TINT\nin vec4 a_color0;\nout vec4 v_color0;\n#endif\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 #if USE_TINT\n v_color0 = a_color0;\n #endif\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_TINT\nin vec4 v_color0;\n#endif\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 #if USE_TINT\n vec4 finalColor;\n finalColor.a = v_color.a * o.a;\n finalColor.rgb = ((o.a - 1.0) * v_color0.a + 1.0 - o.rgb) * v_color0.rgb + o.rgb * v_color.rgb;\n ALPHA_TEST(finalColor);\n gl_FragColor = finalColor;\n #else\n o *= v_color;\n ALPHA_TEST(o);\n gl_FragColor = o;\n #endif\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_TINT\nattribute vec4 a_color0;\nvarying vec4 v_color0;\n#endif\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 #if USE_TINT\n v_color0 = a_color0;\n #endif\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_TINT\nvarying vec4 v_color0;\n#endif\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 #if USE_TINT\n vec4 finalColor;\n finalColor.a = v_color.a * o.a;\n finalColor.rgb = ((o.a - 1.0) * v_color0.a + 1.0 - o.rgb) * v_color0.rgb + o.rgb * v_color.rgb;\n ALPHA_TEST(finalColor);\n gl_FragColor = finalColor;\n #else\n o *= v_color;\n ALPHA_TEST(o);\n gl_FragColor = o;\n #endif\n}"
},
"builtins": {
"globals": {
"blocks": [
{
"name": "CCGlobal",
"defines": []
}
],
"samplers": []
},
"locals": {
"blocks": [
{
"name": "CCLocal",
"defines": []
}
],
"samplers": []
}
},
"defines": [
{
"name": "USE_TINT",
"type": "boolean",
"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-universal|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

@@ -10,58 +10,58 @@
]
},
"uuids": [
"76ZjeTsCNJMYn7/rwRXCpD",
"03EprhmOVCZKUbb5XyPXQq",
"7a/QZLET9IDreTiBfRn2PD",
"93dM6KrkZCf5dgNpQwf7T6",
"ecpdLyjvZBwrvm+cedCcQy",
"f0BIwQ8D5Ml7nTNQbh1YlS",
"e97GVMl6JHh5Ml5qEDdSGa",
"09o3P/9gBP/Yc7AnxUBZ+Q",
"29FYIk+N1GYaeWH/q1NxQO",
"5cO7kybDxGj4ipyMYdRYZB",
"5f5dyqtRNNxaFmVzYns6FZ",
"70VXjGE0JMUqGli0jmCmTF",
"71VhFCTINJM6/Ky3oX9nBT",
"76ZjeTsCNJMYn7/rwRXCpD",
"7a/QZLET9IDreTiBfRn2PD",
"85yTK+9shIo7RQfQ1TDEUi",
"87/8ZHBEVIkKeNxmalrn9r",
"93dM6KrkZCf5dgNpQwf7T6",
"a2MjXRFdtLlYQ5ouAFv/+R",
"a7ZscqX+JCIZRS157bMyhq",
"85yTK+9shIo7RQfQ1TDEUi",
"09o3P/9gBP/Yc7AnxUBZ+Q",
"70VXjGE0JMUqGli0jmCmTF",
"87/8ZHBEVIkKeNxmalrn9r",
"b4P/PCArtIdIH38t6mlw8Y",
"d0Bu8c2MBCKJc+mKBWzjsJ",
"e8Ueib+qJEhL6mXAHdnwbi",
"71VhFCTINJM6/Ky3oX9nBT",
"b4P/PCArtIdIH38t6mlw8Y"
"e97GVMl6JHh5Ml5qEDdSGa",
"ecpdLyjvZBwrvm+cedCcQy",
"f0BIwQ8D5Ml7nTNQbh1YlS"
],
"scenes": {},
"redirect": [
"7a/QZLET9IDreTiBfRn2PD",
0,
"93dM6KrkZCf5dgNpQwf7T6",
1,
"ecpdLyjvZBwrvm+cedCcQy",
"09o3P/9gBP/Yc7AnxUBZ+Q",
0,
"5cO7kybDxGj4ipyMYdRYZB",
2,
1,
"5f5dyqtRNNxaFmVzYns6FZ",
2,
"a2MjXRFdtLlYQ5ouAFv/+R",
2,
"a7ZscqX+JCIZRS157bMyhq",
1,
"85yTK+9shIo7RQfQ1TDEUi",
1,
"09o3P/9gBP/Yc7AnxUBZ+Q",
1,
"70VXjGE0JMUqGli0jmCmTF",
1,
0,
"7a/QZLET9IDreTiBfRn2PD",
2,
"85yTK+9shIo7RQfQ1TDEUi",
0,
"87/8ZHBEVIkKeNxmalrn9r",
0,
"93dM6KrkZCf5dgNpQwf7T6",
0,
"a2MjXRFdtLlYQ5ouAFv/+R",
1,
"a7ZscqX+JCIZRS157bMyhq",
0,
"d0Bu8c2MBCKJc+mKBWzjsJ",
1
0,
"ecpdLyjvZBwrvm+cedCcQy",
2
],
"deps": [
"internal",
"common",
"main"
"main",
"internal"
],
"packs": {
"05fa2ad10": [
@@ -84,7 +84,7 @@
"versions": {
"import": [
"05fa2ad10",
"ef553"
"b4dad"
],
"native": [
"71VhFCTINJM6/Ky3oX9nBT",

View File

@@ -54,6 +54,20 @@ window.__require = function e(t, n, r) {
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.");
};
Object.defineProperty(exports, "__esModule", {
value: true
});
@@ -68,6 +82,7 @@ window.__require = function e(t, n, r) {
_this.boy = null;
_this.heads = [];
_this.boys = [];
_this.datas = [];
return _this;
}
SpineSkin.prototype.start = function() {
@@ -76,6 +91,7 @@ window.__require = function e(t, n, r) {
var newSkeletonData = boySpine.skeletonData.clone();
boySpine.skeletonData = newSkeletonData;
boySpine.animation = "attack";
this.datas.push(newSkeletonData);
this.boys.push(this.boy);
this.addBoyBtn.on("click", function() {
var newBoy = cc.instantiate(_this.boy);
@@ -89,19 +105,41 @@ window.__require = function e(t, n, r) {
newBoy.getComponentInChildren(sp.Skeleton).setAnimationCacheMode(sp.Skeleton.AnimationCacheMode.PRIVATE_CACHE);
newBoy.getComponentInChildren(cc.Label).string = "Spine - Cache";
}
_this.datas.push(newBoySpine.skeletonData);
_this.boys.push(newBoy);
});
this.removeBoyBtn.on("click", function() {
if (_this.boys.length > 1) {
_this.datas[_this.datas.length - 1].destroy();
_this.boys[_this.boys.length - 1].destroy();
_this.datas.length -= 1;
_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)]));
boy.setRegionData("Head", "Head", new sp.RegionData(_this.heads[Math.floor(Math.random() * _this.heads.length)]));
});
};
SpineSkin.prototype.onDestroy = function() {
var e_1, _a;
try {
for (var _b = __values(this.datas), _c = _b.next(); !_c.done; _c = _b.next()) {
var data = _c.value;
data.destroy();
}
} 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;
}
}
};
__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);

File diff suppressed because one or more lines are too long

View File

@@ -10,27 +10,27 @@
]
},
"uuids": [
"f4jvTRdINIaICWEVrgQxx2",
"e2Z8EqOaxB256X3o4ZbClt",
"ecpdLyjvZBwrvm+cedCcQy",
"5cO7kybDxGj4ipyMYdRYZB",
"5f5dyqtRNNxaFmVzYns6FZ",
"a2MjXRFdtLlYQ5ouAFv/+R"
"a2MjXRFdtLlYQ5ouAFv/+R",
"e2Z8EqOaxB256X3o4ZbClt",
"ecpdLyjvZBwrvm+cedCcQy",
"f4jvTRdINIaICWEVrgQxx2"
],
"scenes": {},
"redirect": [
"ecpdLyjvZBwrvm+cedCcQy",
0,
"5cO7kybDxGj4ipyMYdRYZB",
1,
0,
"5f5dyqtRNNxaFmVzYns6FZ",
1,
0,
"a2MjXRFdtLlYQ5ouAFv/+R",
0,
"ecpdLyjvZBwrvm+cedCcQy",
1
],
"deps": [
"internal",
"main"
"main",
"internal"
],
"packs": {
"0dccb646b": [

File diff suppressed because one or more lines are too long

View File

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

View File

@@ -33,8 +33,8 @@
<p class="footer">Made with <a href="https://www.cocos.com/products#CocosCreator" title="Cocos Creator">Cocos Creator</a></p>
<script src="src/settings.111b8.js" charset="utf-8"></script>
<script src="main.73020.js" charset="utf-8"></script>
<script src="src/settings.2d5f7.js" charset="utf-8"></script>
<script src="main.42123.js" charset="utf-8"></script>
<script type="text/javascript">
(function () {
@@ -60,7 +60,7 @@
document.body.appendChild(domScript);
}
loadScript(debug ? 'cocos2d-js.76b90.js' : 'cocos2d-js-min.js', function () {
loadScript(debug ? 'cocos2d-js.be84c.js' : 'cocos2d-js-min.js', function () {
if (CC_PHYSICS_BUILTIN || CC_PHYSICS_CANNON) {
loadScript(debug ? 'physics.js' : 'physics-min.js', window.boot);
}

View File

@@ -123,7 +123,7 @@ window.boot = function () {
if (window.jsb) {
var isRuntime = (typeof loadRuntime === 'function');
if (isRuntime) {
require('src/settings.111b8.js');
require('src/settings.2d5f7.js');
require('src/cocos2d-runtime.js');
if (CC_PHYSICS_BUILTIN || CC_PHYSICS_CANNON) {
require('src/physics.js');
@@ -131,7 +131,7 @@ if (window.jsb) {
require('jsb-adapter/engine/index.js');
}
else {
require('src/settings.111b8.js');
require('src/settings.2d5f7.js');
require('src/cocos2d-jsb.js');
if (CC_PHYSICS_BUILTIN || CC_PHYSICS_CANNON) {
require('src/physics.js');

View File

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 13 KiB

View File

@@ -17,13 +17,13 @@ window._CCSettings = {
debug: true,
jsList: [],
bundleVers: {
sp: "de22b",
internal: "8360b",
common: "0ae49",
home: "72e22",
"multi-render": "67d3d",
spine: "2adf8",
"text-render": "2db47",
main: "ffc79"
sp: "5b68f",
internal: "1bdcb",
common: "31278",
home: "df293",
"multi-render": "d13c6",
spine: "ed69a",
"text-render": "da36b",
main: "3d26a"
}
};

View File

@@ -8,28 +8,28 @@
"fonts/SFNSMonoItalic",
"cc.TTFFont"
],
"80AR/OlBFOoajT99htLYeJ": [
"fonts/normalFont",
"cc.BitmapFont"
],
"45vlnzVlVDaZ6fRVyB0t3Z": [
"fonts/normalFont",
"cc.Texture2D"
],
"80AR/OlBFOoajT99htLYeJ": [
"fonts/normalFont",
"cc.BitmapFont"
],
"92aqwImq1Ik7GrBSFnKTF2": [
"fonts/normalFont",
"cc.SpriteFrame",
1
],
"c1Hf3Sl8ZAnJwP/fpoHxap": [
"images/1655112479313",
"cc.Texture2D"
],
"a7ZscqX+JCIZRS157bMyhq": [
"images/1655112479313",
"cc.SpriteFrame",
1
],
"c1Hf3Sl8ZAnJwP/fpoHxap": [
"images/1655112479313",
"cc.Texture2D"
],
"62MQQadaVK8qQN8n6UmJAa": [
"images/1655112514006",
"cc.Texture2D"
@@ -39,17 +39,13 @@
"cc.SpriteFrame",
1
],
"39jYWzSTREwI2OOBK5nwFe": [
"images/1655112526123",
"cc.Texture2D"
],
"09o3P/9gBP/Yc7AnxUBZ+Q": [
"images/1655112526123",
"cc.SpriteFrame",
1
],
"d0bST/wYpJQIL5T+PCq46W": [
"images/1655112538161",
"39jYWzSTREwI2OOBK5nwFe": [
"images/1655112526123",
"cc.Texture2D"
],
"70VXjGE0JMUqGli0jmCmTF": [
@@ -57,6 +53,10 @@
"cc.SpriteFrame",
1
],
"d0bST/wYpJQIL5T+PCq46W": [
"images/1655112538161",
"cc.Texture2D"
],
"68Q/ALDvRLfKrAQu5CY15V": [
"images/1655112548981",
"cc.Texture2D"
@@ -84,15 +84,15 @@
"cc.SpriteFrame",
1
],
"a97PGbCjtNjr/hYUBJUJ3p": [
"images/1655799093442",
"cc.Texture2D"
],
"34Wm35ZlJBApgKytyVFWhX": [
"images/1655799093442",
"cc.SpriteFrame",
1
],
"a97PGbCjtNjr/hYUBJUJ3p": [
"images/1655799093442",
"cc.Texture2D"
],
"2cDGL4OAVN0ZbEl3w2urT8": [
"materials/custom-2d-sprite",
"cc.Material"
@@ -101,19 +101,40 @@
"spines/huatuo",
"cc.Asset"
],
"93dM6KrkZCf5dgNpQwf7T6": [
"spines/huatuo",
"sp.SkeletonData"
],
"80ThG1v09KeKxKhEPnFmvh": [
"spines/huatuo",
"cc.Texture2D"
],
"93dM6KrkZCf5dgNpQwf7T6": [
"spines/huatuo",
"sp.SkeletonData"
],
"b5ObM0rx1GDKGN3k5VlH0s": [
"spines/huatuo",
"cc.SpriteFrame",
1
],
"07GcDk8RNGZbcrHAq5lPag": [
"spines/shengxing_kuang",
"cc.SpriteFrame",
1
],
"3479J6IuROz7rZhiZpn63y": [
"spines/shengxing_kuang",
"sp.SkeletonData"
],
"37/FrRNqBAiadz9TDqSpRx": [
"spines/shengxing_kuang",
"cc.Asset"
],
"aaYr2KZ+xPDqeLsRHUKxRA": [
"spines/shengxing_kuang",
"cc.Texture2D"
],
"b6OkwTsm1LK5cvRTwFehiy": [
"spines/spineboy",
"cc.TextAsset"
],
"bc2ZOJo5NCbrI0FXxitEvE": [
"spines/spineboy",
"sp.SkeletonData"
@@ -126,54 +147,57 @@
"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",
"07GcDk8RNGZbcrHAq5lPag",
"09o3P/9gBP/Yc7AnxUBZ+Q",
"d0bST/wYpJQIL5T+PCq46W",
"70VXjGE0JMUqGli0jmCmTF",
"68Q/ALDvRLfKrAQu5CY15V",
"87/8ZHBEVIkKeNxmalrn9r",
"70JFWsm5JN17FDywI0Lb5I",
"d0Bu8c2MBCKJc+mKBWzjsJ",
"1cijzBpFJCdoSNK98w5oUq",
"8029xEf4FHy49dWo6NK8c7",
"a97PGbCjtNjr/hYUBJUJ3p",
"34Wm35ZlJBApgKytyVFWhX",
"2cDGL4OAVN0ZbEl3w2urT8",
"34Wm35ZlJBApgKytyVFWhX",
"3479J6IuROz7rZhiZpn63y",
"37/FrRNqBAiadz9TDqSpRx",
"39jYWzSTREwI2OOBK5nwFe",
"3e30KyALhNkZttyuW0A6EU",
"45vlnzVlVDaZ6fRVyB0t3Z",
"62MQQadaVK8qQN8n6UmJAa",
"68Q/ALDvRLfKrAQu5CY15V",
"69Fj/0+E5NeI6nlG9iAH/N",
"93dM6KrkZCf5dgNpQwf7T6",
"6eBWFz0oVHPLIGQKf/9Thu",
"70JFWsm5JN17FDywI0Lb5I",
"70VXjGE0JMUqGli0jmCmTF",
"80AR/OlBFOoajT99htLYeJ",
"80ThG1v09KeKxKhEPnFmvh",
"8029xEf4FHy49dWo6NK8c7",
"85yTK+9shIo7RQfQ1TDEUi",
"87/8ZHBEVIkKeNxmalrn9r",
"92aqwImq1Ik7GrBSFnKTF2",
"93dM6KrkZCf5dgNpQwf7T6",
"a7ZscqX+JCIZRS157bMyhq",
"a97PGbCjtNjr/hYUBJUJ3p",
"aaYr2KZ+xPDqeLsRHUKxRA",
"b5ObM0rx1GDKGN3k5VlH0s",
"bc2ZOJo5NCbrI0FXxitEvE",
"d9xFMK7wVFwbAS60aG9McP",
"f2P0YcCjtHDqebnuMp4CMZ",
"b6OkwTsm1LK5cvRTwFehiy",
"6eBWFz0oVHPLIGQKf/9Thu"
"bc2ZOJo5NCbrI0FXxitEvE",
"c1Hf3Sl8ZAnJwP/fpoHxap",
"d0Bu8c2MBCKJc+mKBWzjsJ",
"d0bST/wYpJQIL5T+PCq46W",
"d9xFMK7wVFwbAS60aG9McP",
"e8ql4cBzBOvoGh5/oNub59",
"f2P0YcCjtHDqebnuMp4CMZ"
],
"scenes": {},
"redirect": [],
"deps": [],
"packs": {
"0472ad032": [
"01d612a1e": [
"07GcDk8RNGZbcrHAq5lPag",
"09o3P/9gBP/Yc7AnxUBZ+Q",
"1cijzBpFJCdoSNK98w5oUq",
"2cDGL4OAVN0ZbEl3w2urT8",
"34Wm35ZlJBApgKytyVFWhX",
"3479J6IuROz7rZhiZpn63y",
"37/FrRNqBAiadz9TDqSpRx",
"39jYWzSTREwI2OOBK5nwFe",
"3e30KyALhNkZttyuW0A6EU",
"45vlnzVlVDaZ6fRVyB0t3Z",
@@ -192,6 +216,7 @@
"93dM6KrkZCf5dgNpQwf7T6",
"a7ZscqX+JCIZRS157bMyhq",
"a97PGbCjtNjr/hYUBJUJ3p",
"aaYr2KZ+xPDqeLsRHUKxRA",
"b5ObM0rx1GDKGN3k5VlH0s",
"b6OkwTsm1LK5cvRTwFehiy",
"bc2ZOJo5NCbrI0FXxitEvE",
@@ -211,12 +236,14 @@
"encrypted": false,
"versions": {
"import": [
"0472ad032",
"4b502"
"01d612a1e",
"92a17"
],
"native": [
"1cijzBpFJCdoSNK98w5oUq",
"91637",
"37/FrRNqBAiadz9TDqSpRx",
"6e46c",
"39jYWzSTREwI2OOBK5nwFe",
"2eb47",
"45vlnzVlVDaZ6fRVyB0t3Z",
@@ -235,6 +262,8 @@
"fd38c",
"a97PGbCjtNjr/hYUBJUJ3p",
"0f278",
"aaYr2KZ+xPDqeLsRHUKxRA",
"48cd8",
"c1Hf3Sl8ZAnJwP/fpoHxap",
"d86d7",
"d0bST/wYpJQIL5T+PCq46W",

View File

@@ -1,6 +1,7 @@
[
1,
[
"aaYr2KZ+xPDqeLsRHUKxRA",
"62MQQadaVK8qQN8n6UmJAa",
"80ThG1v09KeKxKhEPnFmvh",
"d9xFMK7wVFwbAS60aG9McP",
@@ -35,32 +36,6 @@
2,
11
],
[
"cc.EffectAsset",
[
"_name",
"shaders",
"techniques"
],
0
],
[
"cc.Asset",
[
"_name",
"_native"
],
1
],
[
"cc.BitmapFont",
[
"_name",
"fontSize",
"_fntConfig"
],
0
],
[
"sp.SkeletonData",
[
@@ -73,6 +48,32 @@
-1,
3
],
[
"cc.Asset",
[
"_name",
"_native"
],
1
],
[
"cc.EffectAsset",
[
"_name",
"shaders",
"techniques"
],
0
],
[
"cc.BitmapFont",
[
"_name",
"fontSize",
"_fntConfig"
],
0
],
[
"cc.TextAsset",
[
@@ -92,7 +93,7 @@
],
[
[
6,
3,
0,
1,
2,
@@ -100,25 +101,18 @@
4,
5
],
[
2,
0,
1,
2
],
[
3,
0,
1,
2,
4
],
[
4,
0,
1,
3
],
[
2,
0,
1,
2
],
[
5,
0,
@@ -126,6 +120,13 @@
2,
4
],
[
6,
0,
1,
2,
4
],
[
7,
0,
@@ -140,6 +141,46 @@
]
],
[
[
[
{
"name": "shengxing_kuang",
"rect": [
2,
2,
176,
347
],
"offset": [
0,
0
],
"originalSize": [
180,
351
],
"capInsets": [
0,
0,
0,
0
]
}
],
[
1
],
0,
[
0
],
[
0
],
[
0
]
],
[
[
{
@@ -177,7 +218,7 @@
0
],
[
3
4
]
],
[
@@ -196,7 +237,7 @@
[
[
[
1,
2,
"custom-2d-sprite",
[
{},
@@ -241,9 +282,9 @@
3
],
[
0,
4,
5
1,
5,
6
]
],
[
@@ -283,9 +324,174 @@
0
],
[
6
7
]
],
[
[
[
0,
"shengxing_kuang",
"\nshengxing_kuang.png\nsize: 180,351\nformat: RGBA8888\nfilter: Linear,Linear\nrepeat: none\nfx_frame_red\n rotate: false\n xy: 2, 2\n size: 176, 347\n orig: 180, 351\n offset: 2, 2\n index: -1\n",
[
"shengxing_kuang.png"
],
{
"skeleton": {
"hash": "X8GrJN5Hvt74DISCwkkMDigOeyA",
"spine": "3.8.99",
"x": -180,
"y": -351,
"width": 360,
"height": 702,
"images": "./images/",
"audio": ""
},
"bones": [
{
"name": "root"
},
{
"name": "fx_frame",
"parent": "root"
}
],
"slots": [
{
"name": "fx_frame",
"bone": "fx_frame",
"color": "ffffff00",
"dark": "000000",
"attachment": "fx_frame_red",
"blend": "additive"
}
],
"skins": [
{
"name": "default",
"attachments": {
"fx_frame": {
"fx_frame_red": {
"scaleX": 2,
"scaleY": 2,
"width": 180,
"height": 351
}
}
}
}
],
"animations": {
"shengxing_kuang_r": {
"slots": {
"fx_frame": {
"twoColor": [
{
"light": "4aff91c6",
"dark": "009a3e",
"curve": 0.25,
"c3": 0.75
},
{
"time": 0.5,
"light": "49ff9100",
"dark": "009a3e"
}
]
}
}
},
"shengxing_kuang_s": {
"slots": {
"fx_frame": {
"twoColor": [
{
"light": "ffffffc6",
"dark": "fc00ff",
"curve": 0.25,
"c3": 0.75
},
{
"time": 0.5,
"light": "ffffff00",
"dark": "fc00ff"
}
]
}
}
},
"shengxing_kuang_sr": {
"slots": {
"fx_frame": {
"twoColor": [
{
"light": "ffffffc6",
"dark": "ff7300",
"curve": 0.25,
"c3": 0.75
},
{
"time": 0.5,
"light": "ffffff00",
"dark": "ff7300"
}
]
}
}
},
"shengxing_kuang_ssr": {
"slots": {
"fx_frame": {
"twoColor": [
{
"light": "ffffffc5",
"dark": "000000",
"curve": 0.25,
"c3": 0.75
},
{
"time": 0.5,
"light": "ffffff00",
"dark": "000000"
}
]
}
}
}
}
},
[
0
]
]
],
0,
0,
[
0
],
[
-1
],
[
0
]
],
[
[
[
1,
"shengxing_kuang",
".atlas"
],
-1
],
0,
0,
[],
[],
[]
],
[
[
"0,9729,9729,33071,33071,0,0,1",
@@ -302,7 +508,7 @@
[
[
[
2,
3,
"custom-2d-sprite",
[
{
@@ -703,7 +909,7 @@
[
[
[
3,
1,
"huatuo",
".atlas"
],
@@ -778,7 +984,7 @@
0
],
[
7
8
]
],
[
@@ -3058,7 +3264,7 @@
4
],
[
8
9
]
],
[
@@ -3111,7 +3317,7 @@
0
],
[
9
10
]
],
[
@@ -3151,7 +3357,7 @@
0
],
[
0
1
]
],
[
@@ -3191,7 +3397,7 @@
0
],
[
10
11
]
],
[
@@ -3231,7 +3437,7 @@
0
],
[
11
12
]
],
[
@@ -17799,7 +18005,7 @@
"L-Thigh": {
"height": 35,
"hull": 11,
"type": "skinnedmesh",
"type": "mesh",
"width": 29,
"edges": [
0,
@@ -18050,7 +18256,7 @@
"R-Thigh": {
"height": 36,
"hull": 12,
"type": "skinnedmesh",
"type": "mesh",
"width": 30,
"edges": [
0,
@@ -18268,7 +18474,7 @@
"beilou": {
"height": 148,
"hull": 18,
"type": "skinnedmesh",
"type": "mesh",
"width": 113,
"edges": [
0,
@@ -18744,7 +18950,7 @@
-1
],
[
1
2
]
],
[
@@ -18784,7 +18990,7 @@
0
],
[
12
13
]
],
[
@@ -18800,6 +19006,19 @@
[],
[]
],
[
[
"0,9729,9729,33071,33071,0,0,1",
-1
],
[
0
],
0,
[],
[],
[]
],
[
[
{
@@ -18837,7 +19056,7 @@
0
],
[
1
2
]
],
[
@@ -25249,7 +25468,7 @@
-1
],
[
2
3
]
],
[
@@ -25302,7 +25521,7 @@
0
],
[
13
14
]
],
[
@@ -25383,7 +25602,7 @@
0
],
[
2
3
]
]
]

View File

@@ -0,0 +1,13 @@
shengxing_kuang.png
size: 180,351
format: RGBA8888
filter: Linear,Linear
repeat: none
fx_frame_red
rotate: false
xy: 2, 2
size: 176, 347
orig: 180, 351
offset: 2, 2
index: -1

Some files were not shown because too many files have changed in this diff Show More