layaair-example

This commit is contained in:
King Wang
2021-07-21 23:11:13 +08:00
parent c3aa1f918e
commit 4bfe797a89
203 changed files with 257823 additions and 0 deletions

View File

@@ -0,0 +1,620 @@
{
"type":"View",
"selectedBox":1,
"selecteID":36,
"referenceLines":null,
"props":{"sceneWidth":600,"sceneHeight":400,"sceneColor":"#000000"},
"nodeParent":-1,
"label":"View",
"isOpen":true,
"isDirectory":true,
"isAniNode":true,
"hasChild":true,
"compId":1,
"child":[
{
"type":"GraphicNode",
"props":{"y":0,"x":0,"width":20,"skin":"test/b1.png","pivotY":10,"pivotX":10,"height":20},
"nodeParent":1,
"label":"GraphicNode",
"isDirectory":false,
"isAniNode":true,
"hasChild":false,
"compId":36,
"child":[
]
},
{
"type":"GraphicNode",
"props":{"y":20,"x":20,"width":20,"skin":"test/b1.png","pivotY":10,"pivotX":10,"height":20},
"nodeParent":1,
"label":"GraphicNode",
"isDirectory":false,
"isAniNode":true,
"hasChild":false,
"compId":37,
"child":[
]
},
{
"type":"GraphicNode",
"props":{"y":20,"x":0,"width":20,"skin":"test/b1.png","pivotY":10,"pivotX":10,"height":20},
"nodeParent":1,
"label":"GraphicNode",
"isDirectory":false,
"isAniNode":true,
"hasChild":false,
"compId":38,
"child":[
]
},
{
"type":"GraphicNode",
"props":{"y":20,"x":-20,"width":20,"skin":"test/b1.png","pivotY":10,"pivotX":10,"height":20},
"nodeParent":1,
"label":"GraphicNode",
"isDirectory":false,
"isAniNode":true,
"hasChild":false,
"compId":39,
"child":[
]
},
{
"type":"GraphicNode",
"props":{"y":0,"x":20,"width":20,"skin":"test/b1.png","pivotY":10,"pivotX":10,"height":20},
"nodeParent":1,
"label":"GraphicNode",
"isDirectory":false,
"isAniNode":true,
"hasChild":false,
"compId":40,
"child":[
]
},
{
"type":"GraphicNode",
"props":{"y":0,"x":-20,"width":20,"skin":"test/b1.png","pivotY":10,"pivotX":10,"height":20},
"nodeParent":1,
"label":"GraphicNode",
"isDirectory":false,
"isAniNode":true,
"hasChild":false,
"compId":41,
"child":[
]
},
{
"type":"GraphicNode",
"props":{"y":-20,"x":20,"width":20,"skin":"test/b1.png","pivotY":10,"pivotX":10,"height":20},
"nodeParent":1,
"label":"GraphicNode",
"isDirectory":false,
"isAniNode":true,
"hasChild":false,
"compId":42,
"child":[
]
},
{
"type":"GraphicNode",
"props":{"y":-20,"x":0,"width":20,"skin":"test/b1.png","pivotY":10,"pivotX":10,"height":20},
"nodeParent":1,
"label":"GraphicNode",
"isDirectory":false,
"isAniNode":true,
"hasChild":false,
"compId":43,
"child":[
]
},
{
"type":"GraphicNode",
"props":{"y":-20,"x":-20,"width":20,"skin":"test/b1.png","pivotY":10,"pivotX":10,"height":20},
"nodeParent":1,
"label":"GraphicNode",
"isDirectory":false,
"isAniNode":true,
"hasChild":false,
"compId":44,
"child":[
]
}],
"animations":[
{
"nodes":[
{
"target":36,
"keyframes":{
"y":[
{
"value":0,
"tweenMethod":"linearNone",
"tween":true,
"target":36,
"key":"y",
"index":0
},
{
"value":-30,
"tweenMethod":"linearNone",
"tween":true,
"target":36,
"key":"y",
"index":5
}],
"x":[
{
"value":0,
"tweenMethod":"linearNone",
"tween":true,
"target":36,
"key":"x",
"index":0
},
{
"value":-165,
"tweenMethod":"linearNone",
"tween":true,
"target":36,
"key":"x",
"index":5
}],
"alpha":[
{
"value":1,
"tweenMethod":"linearNone",
"tween":true,
"target":36,
"key":"alpha",
"index":0
},
{
"value":0.2,
"tweenMethod":"linearNone",
"tween":true,
"target":36,
"key":"alpha",
"index":5
}]
}
},
{
"target":37,
"keyframes":{
"y":[
{
"value":20,
"tweenMethod":"linearNone",
"tween":true,
"target":37,
"key":"y",
"index":0
},
{
"value":30,
"tweenMethod":"linearNone",
"tween":true,
"target":37,
"key":"y",
"index":5
}],
"x":[
{
"value":20,
"tweenMethod":"linearNone",
"tween":true,
"target":37,
"key":"x",
"index":0
},
{
"value":155,
"tweenMethod":"linearNone",
"tween":true,
"target":37,
"key":"x",
"index":5
}],
"alpha":[
{
"value":1,
"tweenMethod":"linearNone",
"tween":true,
"target":37,
"key":"alpha",
"index":0
},
{
"value":0.7,
"tweenMethod":"linearNone",
"tween":true,
"target":37,
"key":"alpha",
"index":5
}]
}
},
{
"target":38,
"keyframes":{
"y":[
{
"value":20,
"tweenMethod":"linearNone",
"tween":true,
"target":38,
"key":"y",
"index":0
},
{
"value":116,
"tweenMethod":"linearNone",
"tween":true,
"target":38,
"key":"y",
"index":5
}],
"x":[
{
"value":0,
"tweenMethod":"linearNone",
"tween":true,
"target":38,
"key":"x",
"index":0
},
{
"value":73,
"tweenMethod":"linearNone",
"tween":true,
"target":38,
"key":"x",
"index":5
}],
"alpha":[
{
"value":1,
"tweenMethod":"linearNone",
"tween":true,
"target":38,
"key":"alpha",
"index":0
},
{
"value":0.2,
"tweenMethod":"linearNone",
"tween":true,
"target":38,
"key":"alpha",
"index":5
}]
}
},
{
"target":39,
"keyframes":{
"y":[
{
"value":20,
"tweenMethod":"linearNone",
"tween":true,
"target":39,
"key":"y",
"index":0
},
{
"value":116,
"tweenMethod":"linearNone",
"tween":true,
"target":39,
"key":"y",
"index":5
}],
"x":[
{
"value":-20,
"tweenMethod":"linearNone",
"tween":true,
"target":39,
"key":"x",
"index":0
},
{
"value":-51,
"tweenMethod":"linearNone",
"tween":true,
"target":39,
"key":"x",
"index":5
}],
"alpha":[
{
"value":1,
"tweenMethod":"linearNone",
"tween":true,
"target":39,
"key":"alpha",
"index":0
},
{
"value":0.4,
"tweenMethod":"linearNone",
"tween":true,
"target":39,
"key":"alpha",
"index":5
}]
}
},
{
"target":40,
"keyframes":{
"y":[
{
"value":0,
"tweenMethod":"linearNone",
"tween":true,
"target":40,
"key":"y",
"index":0
},
{
"value":-79,
"tweenMethod":"linearNone",
"tween":true,
"target":40,
"key":"y",
"index":5
}],
"x":[
{
"value":20,
"tweenMethod":"linearNone",
"tween":true,
"target":40,
"key":"x",
"index":0
},
{
"value":124,
"tweenMethod":"linearNone",
"tween":true,
"target":40,
"key":"x",
"index":5
}],
"alpha":[
{
"value":1,
"tweenMethod":"linearNone",
"tween":true,
"target":40,
"key":"alpha",
"index":0
},
{
"value":0.3,
"tweenMethod":"linearNone",
"tween":true,
"target":40,
"key":"alpha",
"index":5
}]
}
},
{
"target":41,
"keyframes":{
"y":[
{
"value":0,
"tweenMethod":"linearNone",
"tween":true,
"target":41,
"key":"y",
"index":0
},
{
"value":71,
"tweenMethod":"linearNone",
"tween":true,
"target":41,
"key":"y",
"index":5
}],
"x":[
{
"value":-20,
"tweenMethod":"linearNone",
"tween":true,
"target":41,
"key":"x",
"index":0
},
{
"value":-111,
"tweenMethod":"linearNone",
"tween":true,
"target":41,
"key":"x",
"index":5
}],
"alpha":[
{
"value":1,
"tweenMethod":"linearNone",
"tween":true,
"target":41,
"key":"alpha",
"index":0
},
{
"value":0.6,
"tweenMethod":"linearNone",
"tween":true,
"target":41,
"key":"alpha",
"index":5
}]
}
},
{
"target":42,
"keyframes":{
"y":[
{
"value":-20,
"tweenMethod":"linearNone",
"tween":true,
"target":42,
"key":"y",
"index":0
},
{
"value":-49,
"tweenMethod":"linearNone",
"tween":true,
"target":42,
"key":"y",
"index":5
}],
"x":[
{
"value":20,
"tweenMethod":"linearNone",
"tween":true,
"target":42,
"key":"x",
"index":0
},
{
"value":53,
"tweenMethod":"linearNone",
"tween":true,
"target":42,
"key":"x",
"index":5
}],
"alpha":[
{
"value":1,
"tweenMethod":"linearNone",
"tween":true,
"target":42,
"key":"alpha",
"index":0
},
{
"value":0,
"tweenMethod":"linearNone",
"tween":true,
"target":42,
"key":"alpha",
"index":5
}]
}
},
{
"target":43,
"keyframes":{
"y":[
{
"value":-20,
"tweenMethod":"linearNone",
"tween":true,
"target":43,
"key":"y",
"index":0
},
{
"value":-136,
"tweenMethod":"linearNone",
"tween":true,
"target":43,
"key":"y",
"index":5
}],
"alpha":[
{
"value":1,
"tweenMethod":"linearNone",
"tween":true,
"target":43,
"key":"alpha",
"index":0
},
{
"value":0.2,
"tweenMethod":"linearNone",
"tween":true,
"target":43,
"key":"alpha",
"index":5
}]
}
},
{
"target":44,
"keyframes":{
"y":[
{
"value":-20,
"tweenMethod":"linearNone",
"tween":true,
"target":44,
"key":"y",
"index":0
},
{
"value":-69,
"tweenMethod":"linearNone",
"tween":true,
"target":44,
"key":"y",
"index":5
}],
"x":[
{
"value":-20,
"tweenMethod":"linearNone",
"tween":true,
"target":44,
"key":"x",
"index":0
},
{
"value":-91,
"tweenMethod":"linearNone",
"tween":true,
"target":44,
"key":"x",
"index":5
}],
"alpha":[
{
"value":1,
"tweenMethod":"linearNone",
"tween":true,
"target":44,
"key":"alpha",
"index":0
},
{
"value":0.5,
"tweenMethod":"linearNone",
"tween":true,
"target":44,
"key":"alpha",
"index":5
}]
}
}],
"name":"ani1",
"id":1,
"frameRate":30,
"events":[
],
"action":0
}]
}

View File

@@ -0,0 +1,140 @@
{
"x":0,
"type":"Scene",
"selectedBox":1,
"searchKey":"Scene,gameBox",
"referenceLines":null,
"props":{"width":640,"sceneColor":"#000000","runtime":"script/GameUI.ts","name":"gameBox","height":1136},
"nodeParent":-1,
"maxID":21,
"label":"gameBox",
"isOpen":true,
"isDirectory":true,
"isAniNode":true,
"hasChild":true,
"compId":1,
"child":[
{
"x":15,
"type":"Sprite",
"searchKey":"Sprite,ground",
"props":{"y":1116,"x":-83,"width":805,"texture":"test/block.png","name":"ground","height":20},
"nodeParent":1,
"label":"ground",
"isOpen":false,
"isDirectory":true,
"isAniNode":true,
"hasChild":true,
"compId":3,
"child":[
{
"type":"BoxCollider",
"searchKey":"BoxCollider",
"props":{"y":0,"x":0,"width":805,"label":"ground","height":20},
"nodeParent":3,
"label":"BoxCollider",
"isDirectory":false,
"isAniNode":true,
"hasChild":false,
"compId":5,
"child":[
]
},
{
"type":"RigidBody",
"searchKey":"RigidBody",
"props":{"type":"static"},
"nodeParent":3,
"label":"RigidBody",
"isDirectory":false,
"isAniNode":true,
"hasChild":false,
"compId":6,
"child":[
]
}]
},
{
"x":15,
"type":"Sprite",
"searchKey":"Sprite,gameBox",
"props":{"y":0,"x":0,"name":"gameBox"},
"nodeParent":1,
"label":"gameBox",
"isDirectory":false,
"isAniNode":true,
"hasChild":false,
"compId":18,
"child":[
]
},
{
"x":15,
"type":"Sprite",
"searchKey":"Sprite,UI",
"props":{"y":0,"x":0,"name":"UI"},
"nodeParent":1,
"label":"UI",
"isOpen":true,
"isDirectory":true,
"isAniNode":true,
"hasChild":true,
"compId":14,
"child":[
{
"x":30,
"type":"Label",
"searchKey":"Label,scoreLbl",
"props":{"y":50,"x":158,"width":272,"var":"scoreLbl","height":47,"fontSize":40,"color":"#51c524","align":"center"},
"nodeParent":14,
"label":"scoreLbl",
"isDirectory":false,
"isAniNode":true,
"hasChild":false,
"compId":17,
"child":[
]
},
{
"x":30,
"type":"Label",
"searchKey":"Label,tipLbll",
"props":{"y":0,"x":0,"width":640,"var":"tipLbll","valign":"middle","text":"别让箱子掉下来\\n\\n点击屏幕开始游戏","height":1136,"fontSize":40,"color":"#c6302e","align":"center"},
"nodeParent":14,
"label":"tipLbll",
"isDirectory":false,
"isAniNode":true,
"hasChild":false,
"compId":16,
"child":[
]
}]
},
{
"x":15,
"type":"Script",
"switchAble":true,
"source":"src/script/GameControl.ts",
"searchKey":"Script,GameControl",
"removeAble":true,
"props":{"enabled":true,"dropBox":"@Prefab:prefab/DropBox.prefab","bullet":"@Prefab:prefab/Bullet.prefab"},
"nodeParent":1,
"label":"GameControl",
"isDirectory":false,
"isClose":false,
"isAniNode":true,
"hasChild":false,
"compId":20,
"child":[
]
}],
"animations":[
{
"nodes":[
],
"name":"ani1",
"id":1,
"frameRate":24,
"action":0
}]
}