Commit a0f14d76 authored by 李维's avatar 李维

Dev commit

parent fa703d42
...@@ -31,7 +31,8 @@ ...@@ -31,7 +31,8 @@
"rxjs": "~6.5.4", "rxjs": "~6.5.4",
"spark-md5": "^3.0.0", "spark-md5": "^3.0.0",
"tslib": "^1.10.0", "tslib": "^1.10.0",
"zone.js": "~0.10.2" "zone.js": "~0.10.2",
"node-sass": "^4.0.0"
}, },
"devDependencies": { "devDependencies": {
"@angular-devkit/build-angular": "~0.900.3", "@angular-devkit/build-angular": "~0.900.3",
......
@import '../style/common_mixin.css';
.model-content {
width: 100%;
height: 100%;
}
.radioPaire {
float: left;
margin: 3px;
border-style: dashed;
border-color: #000;
border-width: 1px;
}
.border {
border-radius: 20px;
border-style: dashed;
padding: 20px;
margin: 20px;
/*width: 500px; */
/*//border-radius: 20px;*/
/*//border-width: 2px;*/
/*//border-color: #000000;*/
}
.border-lite {
border: 2px dashed #ddd;
border-radius: 0.5rem;
padding: 10px;
margin: 10px;
}
<div class="model-content"> <div class="model-content">
<div class="card-config">
<div class="card-item clearfix" style="padding: 0.5vw; width: 100%;" >
<div class="card-item-content border" >
<div class="card-item-content">
<div class="title" >
题目素材
</div>
<div class="section" >
<div class="section-content">
<div style="margin-bottom: 10px;">
<nz-form-item >
<nz-form-label [nzSpan]="2" nzFor="email">背景音乐</nz-form-label>
<nz-form-control [nzSpan]="4">
<app-audio-recorder [audioUrl]="contentObj.bgMusic" (audioUploaded)="onAudioUploadSuccessByItem($event, contentObj, 'bgMusic')" ></app-audio-recorder>
</nz-form-control>
<nz-form-label [nzSpan]="2" nzFor="email">题意音频</nz-form-label>
<nz-form-control [nzSpan]="4">
<app-audio-recorder [audioUrl]="contentObj.questionAudio_url" (audioUploaded)="onAudioUploadSuccessByItem($event, contentObj, 'questionAudio_url')" ></app-audio-recorder>
</nz-form-control>
<nz-form-label [nzSpan]="2" nzFor="email">标题</nz-form-label>
<nz-form-control [nzSpan]="4">
<input type="text" nz-input placeholder="请输入标题" [(ngModel)]="contentObj.titleText" (blur)="saveItem()" style="width: 250px;" />
</nz-form-control>
</nz-form-item >
</div>
</div>
</div>
</div>
</div>
</div>
<div style="padding: 10px;">
<div style="width: 300px;" align='center'>
<span>图1: </span>
<app-upload-image-with-preview
[picUrl]="item.pic_url"
(imageUploaded)="onImageUploadSuccess($event, 'pic_url')">
</app-upload-image-with-preview>
</div>
<div style="width: 300px; margin-top: 5px;" align='center'>
<span>图2: </span>
<app-upload-image-with-preview
[picUrl]="item.pic_url_2"
(imageUploaded)="onImageUploadSuccess($event, 'pic_url_2')">
</app-upload-image-with-preview>
</div>
<div style="width: 300px; margin-top: 15px;">
<span>文本: </span>
<input type="text" nz-input [(ngModel)]="item.text" (blur)="save()">
</div>
<div style="margin-top: 5px"> <div *ngFor="let item of contentObj.dataArray; let i = index" class="card-item" style="padding: 0.5vw; " >
<span>音频: </span> <div class="card-item-content border">
<app-audio-recorder <div class="card-item-content">
[audioUrl]="item.audio_url" <div class="title" >
(audioUploaded)="onAudioUploadSuccess($event, 'audio_url')" 第-<strong>{{ i + 1 }}</strong>-题
></app-audio-recorder>
</div> </div>
<div class="section" >
<div class="section-content">
<div style="display: flex; margin-bottom: 10px;">
<div style="flex:1">
图片
</div>
<div style="flex:5">
<app-upload-image-with-preview style="width: 100%;" [picUrl]="item.image_url" (imageUploaded)="onImageUploadSuccessByItem($event, item, 'image_url')"></app-upload-image-with-preview>
</div>
</div>
<div style="display: flex; ">
<div style="flex:1">
音频
</div>
<div style="flex:5">
<app-audio-recorder [audioUrl]="item.audio_url" (audioUploaded)="onAudioUploadSuccessByItem($event, item, 'audio_url')" ></app-audio-recorder>
</div>
</div>
</div>
</div> </div>
<div class="section" >
<div style="text-align: right; padding-right: 20px;">
<button style="margin-bottom: 10px;" nz-button nzType="danger" (click)="deleteItem(contentObj.dataArray, i)" >
<span>删除本题</span>
</button>
</div>
</div>
</div>
</div>
</div>
<div class="card-item" style="padding: 0.5vw;" >
<button nz-button nzType="primary" class="add-btn" (click)="addItem(contentObj.dataArray)">
<i nz-icon nzType="plus-circle" nzTheme="outline"></i>
新建卡片组
</button>
</div>
</div>
</div> </div>
@import "../style/common_mixin";
.model-content {
margin: 10px;
.card-config {
width: 100%;
height: 100%;
display: flex;
flex-direction: row;
flex-wrap: wrap;
.card-item{
width: 500px;
margin-bottom: 40px;
.border {
border-radius: 20px;
border-style: dashed;
padding:20px;
width: 100%;
}
.card-item-content{
.title {
font-size: 24px;
width: 100%;
text-align: center;
}
.section{
border-top: 1px dashed ;
padding: 10px 0;
.section-title{
font-size: 24px;
width: 100%;
}
.section-content{
display: flex;
flex-direction: column;
margin: 5px 0 10px 0;
}
}
.pic-sound-box {
width: 50%;
display: flex;
flex-direction: column;
}
.add-btn-box {
display: flex;
align-items: center;
justify-content: center;
height: 20vw;
padding: 10px;
padding-top: 5vw;
}
}
}
}
}
.clearfix:before,.clearfix:after {
content: "";
display: block;
clear: both;
}
\ No newline at end of file
import { Component, EventEmitter, Input, OnDestroy, OnChanges, OnInit, Output, ApplicationRef, ChangeDetectorRef } from '@angular/core'; import {Component, EventEmitter, Input, OnDestroy, OnChanges, OnInit, Output, ApplicationRef, ChangeDetectorRef} from '@angular/core';
import { JsonPipe } from '@angular/common'; // import { defauleFormData } from '../../assets/default/formData/defaultData_LST01'
const defauleFormData = {
"version": "1.0",
key: "DataKey_Sbox_FT_08",
bgMusic: "",
titleText: "",
dataArray: []
}
@Component({ @Component({
selector: 'app-form', selector: 'app-form',
templateUrl: './form.component.html', templateUrl: './form.component.html',
styleUrls: ['./form.component.css'] styleUrls: ['./form.component.scss']
}) })
export class FormComponent implements OnInit, OnChanges, OnDestroy { export class FormComponent implements OnInit, OnChanges, OnDestroy {
// 储存数据用 _item: any;
saveKey = "test_001"; KEY = 'DataKey_Sbox_FT_08';
// 储存对象 checkOptionsOne = []
item; Text = "Text"
Image = "Image"
set item(item) {
this._item = item;
}
get item() {
return this._item;
}
contentObj = {
"version": "1.0",
key: "DataKey_Sbox_FT_08",
bgMusic: "",
titleText: "",
questionAudio_url: "",
dataArray: []
}
@Output()
update = new EventEmitter();
constructor(private appRef: ApplicationRef, private changeDetectorRef: ChangeDetectorRef) { constructor(private appRef: ApplicationRef, private changeDetectorRef: ChangeDetectorRef) {
} }
createShell() {
this.item.wordList.push({
word: '',
audio: '',
backWord: '',
backWordAudio: '',
});
this.save(); handleQuestionTypeChange(){
// if(this.contentObj.question.type != 'LongAudio'){
// this.contentObj.answerType='Text'
// }
this.saveItem()
this.changeDetectorRef.markForCheck();
this.changeDetectorRef.detectChanges();
} }
removeShell(idx) { handleAnswerTypeChange(){
this.item.wordList.splice(idx, 1); // console.log("Change")
this.save(); // let len = this.contentObj.dataArray.length
// this.contentObj.dataArray = Array(len).fill("")
this.saveItem()
}
handleTextChange(e, index){
// console.log(e.target.value, index)
this.contentObj.dataArray[index].text = e.target.value
this.saveItem()
this.refresh();
} }
ngOnInit() {
this.item = {};
// 获取存储的数据
(<any>window).courseware.getData((data) => {
ngOnInit() {
this.item = {};
this.item.contentObj = {};
const getData = (<any> window).courseware.getData;
getData((data) => {
console.log("读取数据", data)
if (data) { if (data) {
this.item = data; this.item = data;
} else {
this.item = {};
}
if ( !this.item.contentObj ) {
this.item.contentObj = {};
} }
this.init(); this.init();
this.refresh();
setTimeout(() => {
this.changeDetectorRef.markForCheck(); this.changeDetectorRef.markForCheck();
this.changeDetectorRef.detectChanges(); this.changeDetectorRef.detectChanges();
this.refresh(); }, 100);
// this.save()
}, this.saveKey); }, this.KEY);
} }
ngOnChanges() { ngOnChanges() {
} }
ngOnDestroy() { ngOnDestroy() {
} }
init() { init() {
if (Object.keys(this.item.contentObj).length != 0 && this.item.contentObj.version && this.item.contentObj.version==this.contentObj.version) {
console.log("读取数据", this.item.contentObj)
this.contentObj = this.item.contentObj;
} else {
console.log("使用演示数据", this.contentObj)
this.item.contentObj = this.contentObj;
}
}
cardItemData(){
return {audio_url:"", image_url:""}
} }
cardChoiceData(){
return { isText: true, text: "", image_url: "" }
}
/**
* 储存图片数据
* @param e
*/
onImageUploadSuccess(e, key) {
this.item[key] = e.url; initData() {
this.save();
}
handleMoveItemUp(items, index){
if(index!=0){
items[index] = items.splice(index-1, 1, items[index])[0];
}else{
items.push(items.shift());
}
this.save()
}
handleMoveItemDown(items, index){
if(index!=items.length-1){
items[index] = items.splice(index+1, 1, items[index])[0];
}else{
items.unshift( items.splice(index,1)[0]);
}
this.save()
}
deleteItem(item, index){
item.splice(index,1)
this.save()
}
addItem(item?, type?) {
item.push({text: "", image_url: ""})
this.saveItem();
} }
/** onImageUploadSuccessByItem(e, item, key) {
* 储存音频数据 item[key] = e.url
* @param e this,this.refresh()
*/
onAudioUploadSuccess(e, key) {
this.item[key] = e.url;
this.save(); this.save();
} }
onWordAudioUploadSuccess(e, idx) {
this.item.wordList[idx].audio = e.url; onAudioUploadSuccessByItem(e, item, key) {
item[key] = e.url
this.save(); this.save();
} }
onBackWordAudioUploadSuccess(e, idx) {
this.item.wordList[idx].backWordAudio = e.url; saveItem() {
this.save(); this.save();
} }
/**
* 储存数据
*/
save() { save() {
(<any>window).courseware.setData(this.item, null, this.saveKey); (<any> window).courseware.setData(this.item, null, this.KEY);
this.refresh(); this.refresh();
console.log('this.item = ' + JSON.stringify(this.item)); console.log(JSON.stringify(this.item))
console.log("保存", this.item)
} }
/**
* 刷新 渲染页面
*/
refresh() { refresh() {
setTimeout(() => { setTimeout(() => {
this.appRef.tick(); this.appRef.tick();
}, 1); }, 1);
} }
updateCheckbox(){
let check = []
this.item.contentObj.textDown.forEach((item, index) => {
check.push({label:index+1, value:index, checked:false})
});
let length = check.length
this.item.contentObj.textUp.forEach((item, index) => {
let _check = JSON.parse(JSON.stringify(check))
item.lineTo.forEach(option=> {
if(option<length){
_check[Number(option)].checked = true
}
});
item.checkOptions = _check
});
}
} }
/* You can add global styles to this file, and also import other style files */ /* You can add global styles to this file, and also import other style files */
@import "~ng-zorro-antd/src/ng-zorro-antd.css";
\ No newline at end of file
...@@ -21,6 +21,7 @@ ...@@ -21,6 +21,7 @@
] ]
}, },
"angularCompilerOptions": { "angularCompilerOptions": {
"enableIvy": false,
"fullTemplateTypeCheck": true, "fullTemplateTypeCheck": true,
"strictInjectionParameters": true "strictInjectionParameters": true
} }
......
{ {
"ver": "2.0.1", "ver": "2.0.1",
"uuid": "f0680ae0-c079-45ef-abd7-9e63d90b982b", "uuid": "f9f63fef-f158-4c0f-9a35-c913ae020fc8",
"downloadMode": 0, "downloadMode": 0,
"duration": 0.130612, "duration": 5.09175,
"subMetas": {} "subMetas": {}
} }
\ No newline at end of file
{ {
"ver": "1.1.0", "ver": "1.1.0",
"uuid": "c551970e-b095-45f3-9f1d-25cde8b8deb1", "uuid": "4278e1b0-1b0e-4c36-a439-b8e331576335",
"subMetas": {} "subMetas": {}
} }
\ No newline at end of file
This diff is collapsed.
export default class Cartoon {
elements = {
}
touchEventCallback = {
}
audioCallback = {
}
constructor() {
}
audios = {}
initCartoonElement(key, node) {
if(!node) {
console.error("Can not find node for key:[" + key + "]")
}
this.elements[key] = {}
this.elements[key].key = key
this.elements[key].node = node
this.elements[key].initX = node.x
this.elements[key].initY = node.y
this.elements[key].initScaleX = node.scaleX
this.elements[key].initScaleY = node.scaleY
this.elements[key].dragonBones = new DragonBones(node)
this.elements[key]["setLocation"] = (x, y) => {
if(x) {
this.elements[key].initX = x
this.elements[key].node.x = x
}
if(y) {
this.elements[key].initY = y
this.elements[key].node.y = y
}
}
return this.elements[key]
}
getCartoonElement(key) {
let node = this.elements[key]
if(!node) {
console.error("Can't find '" + key + "' node.")
}
return node
}
getSpritNode(nodeName, nameSpace = "") {
let node = cc.find(`${nameSpace}${nodeName}`)
return node?node:null
}
getNodeByName(nodeName, parentNodeName) {
let node = null
if(parentNodeName) {
node = this.getSpritNode(parentNodeName).getChildByName(nodeName)
} else {
node = this.getSpritNode(nodeName)
}
return node?node:null
}
getNodeByPath(path) {
let node = cc.find(path)
if(!node) {
console.warn("Can not fount node.(PATH:" + path + ")")
}
return node?node:null
}
getColor(hex) {
let color = new cc.color()
color.fromHEX(hex);
return color
}
getFontFamily(fontName) {
let font = cc.find(`Canvas/res/font/${fontName}`).getComponent('cc.Label').font;
return font
}
newLabelNode(text, fontFamily, fontSize, color) {
const labelNode = new cc.Node();
labelNode.color = this.getColor(color);
const label = labelNode.addComponent(cc.Label);
label.string = text;
label.fontSize = fontSize;
label.lineHeight = fontSize;
label.font = this.getFontFamily(fontFamily);
return labelNode
}
cloneNode(targetNode) {
var node = cc.instantiate(targetNode);
return node
}
subscribeTouchEvent(key, callBack) {
if(!this.touchEventCallback[key]) {
this.touchEventCallback[key] = callBack
this.elements[key].node.on(cc.Node.EventType.TOUCH_START, ()=>{
if(this.touchEventCallback[key]) {
this.touchEventCallback[key]()
}
})
} else {
this.touchEventCallback[key] = callBack
}
}
initLocalAudios(audioNames = []) {
const audioNode = cc.find('Canvas/res/audio');
const getAudioByResName = (resName) => {
return audioNode.getChildByName(resName).getComponent(cc.AudioSource);
}
audioNames.forEach(audioName=>{
this.audios[audioName] = getAudioByResName(audioName);
})
}
playLocalAudio(audioName, cb) {
let audio = cc.audioEngine.play(this.audios[audioName].clip, false, 0.2)
if (cb) {
this.audioCallback[audio_url] = cb
cc.audioEngine.setFinishCallback(audio, () => {
delete this.audioCallback[audio_url]
cb();
});
}
}
// Audio
playAudio(audio_url, cb = null) {
if (audio_url) {
var urlreg=/^(?=^.{3,255}$)(http(s)?:\/\/)?(www\.)?[a-zA-Z0-9][-a-zA-Z0-9]{0,62}(\.[a-zA-Z0-9][-a-zA-Z0-9]{0,62})+(:\d+)*(\/\w+\.\w+)*([\?&]\w+=\w*)*$/
if(urlreg.test(audio_url)) {
cc.assetManager.loadRemote(audio_url, (err, audioClip) => {
if(cb) {
this.audioCallback[audio_url] = cb
}
const audioId = cc.audioEngine.play(audioClip, false, 1);
if (cb) {
cc.audioEngine.setFinishCallback(audioId, () => {
delete this.audioCallback[audio_url]
cb();
});
}
});
} else {
const audioNode = cc.find('Canvas/res/audio').getChildByName(audio_url).getComponent(cc.AudioSource);
let audio = cc.audioEngine.play(audioNode.clip, false, 1)
if (cb) {
this.audioCallback[audio_url] = cb
cc.audioEngine.setFinishCallback(audio, () => {
delete this.audioCallback[audio_url]
cb();
});
}
}
}
}
stopAllAudio(exceptUrls = []) {
for(let key in this.audioCallback) {
if(exceptUrls.indexOf(key) == -1) {
this.audioCallback[key]()
}
}
this.audioCallback = {}
cc.audioEngine.stopAll()
}
// Tweenchange
tweenChange(item, obj, time = 0.8, callBack = null, easing = null, update = null) {
const tween = cc.tween(item).to(time, obj).call(()=>{
if(callBack) {
callBack()
}
});
easing && tween.easing(easing);
update && tween.onUpdate((a, b) => { update(a, b); });
tween.start();
return tween;
}
// Common Ani
creatSpeaker(parentNode, nodeName1, nodeName2) {
console.log(`Canvas/res/img/${nodeName1}`, `Canvas/res/img/${nodeName2}`)
const sprNode = this.cloneNode(this.getNodeByPath(`Canvas/res/img/${nodeName1}`));
sprNode.parent = parentNode;
sprNode.x = 0;
sprNode.y = 0;
sprNode.zIndex = 2;
parentNode.icon = sprNode;
const sprNode2 = this.cloneNode(this.getNodeByPath(`Canvas/res/img/${nodeName2}`));
sprNode2.parent = sprNode.parent;
sprNode2.x = sprNode.x;
sprNode2.y = sprNode.y;
sprNode2.opacity = 0;
sprNode.spr2 = sprNode2;
// sprNode.addComponent(cc.Button)
// sprNode.on('click', () => {
// this.showSoundAnima(sprNode);
// if(clickCB) {
// clickCB(this)
// }
// playAudioByUrl( item.data.audio_url , () => {
// this.stopSoundAnima(sprNode);
// });
// });
return sprNode
}
showSoundAnima(iconNode, time = 0.4) {
iconNode.isRunAnima = true;
iconNode.spr2.opacity = 255;
iconNode.opacity = 0;
cc.tween(iconNode)
.delay(time / 2)
.call(() => {
iconNode.spr2.opacity = 0;
iconNode.opacity = 255;
})
.delay(time / 2)
.call(() => {
if (iconNode.isRunAnima) {
this.showSoundAnima(iconNode);
}
})
.start()
}
stopSoundAnima(iconNode) {
iconNode.isRunAnima = false;
}
}
class DragonBones {
parentNode = null
_animationLoaded = null
constructor(parentNode) {
this.parentNode = parentNode
}
resetDragonBones() {
const picNode = this.parentNode
if (picNode.animaNode) {
picNode.animaNode.removeFromParent();
this._animationLoaded = null
}
}
setDragonBones(dragonBonesConfig, callback, onClickCB) {
const parentNode = this.parentNode
if (parentNode.animaNode) {
parentNode.animaNode.removeFromParent();
}
const animaNode = new cc.Node();
animaNode.parent = parentNode;
parentNode.animaNode = animaNode;
const dragonDisplay = animaNode.addComponent(dragonBones.ArmatureDisplay);
this._animationLoaded = dragonDisplay;
// const image = "http://staging-teach.cdn.ireadabc.com/5a0c5af3e952acd0ac83a6e5c6f03ff1.png";
// const ske = "http://staging-teach.cdn.ireadabc.com/bd825dcceea298d1146be8067ae3d17f.json";
// const atlas = "http://staging-teach.cdn.ireadabc.com/246f8991b729fa3e5a7f4802de828efa.json";
const image = dragonBonesConfig.texPngData.url
const ske = dragonBonesConfig.skeJsonData.url
const atlas = dragonBonesConfig.texJsonData.url
cc.loader.load(image, (error, texture) => {
cc.loader.load({url: atlas, type: 'txt'}, (error, atlasJson) => {
cc.loader.load({url: ske, type: 'txt'}, (error, dragonBonesJson) => {
const atlas = new dragonBones.DragonBonesAtlasAsset();
atlas.atlasJson = atlasJson;
atlas.texture = texture;
const asset = new dragonBones.DragonBonesAsset();
asset.dragonBonesJson = dragonBonesJson;
dragonDisplay.dragonAtlasAsset = atlas;
dragonDisplay.dragonAsset = asset;
let json = JSON.parse(asset.dragonBonesJson);
let armatures = json["armature"];
let armatureNames = [];
for (let i = 0; i < armatures.length; i++) {
armatureNames.push(armatures[i].name);
}
if (armatureNames.length > 0) {
let defaultArmatureName = armatureNames[0];
dragonDisplay.armatureName = defaultArmatureName;
let defaultArmature = armatures[0];
let animations = defaultArmature.animation;
let animationNames = [];
for (let i = 0; i < animations.length; i++) {
animationNames.push(animations[i].name);
}
dragonDisplay.animaNames = animationNames;
animaNode.addComponent(cc.Button)
animaNode.on('click', ()=>{
if(onClickCB) {
onClickCB(this)
}
})
}
if(callback) {
callback(this)
}
let sx = parentNode.width / animaNode.width;
let sy = parentNode.height / animaNode.height;
animaNode.setScale(Math.min(sx, sy));
});
});
});
}
showDragonBones(times = 1) {
if (this._animationLoaded && this._animationLoaded.animaNames.length > 0) {
this._animationLoaded.playAnimation(this._animationLoaded.animaNames[0], times);
}
}
}
\ No newline at end of file
{
"ver": "1.0.8",
"uuid": "799c0c91-0e23-4cf4-8fbf-68bbcf9e1616",
"isPlugin": false,
"loadPluginInWeb": true,
"loadPluginInNative": true,
"loadPluginInEditor": false,
"subMetas": {}
}
\ No newline at end of file
This diff is collapsed.
{
"ver": "1.0.8",
"uuid": "356c544f-5ce9-4cbb-a2c1-c0737e0a02e2",
"isPlugin": false,
"loadPluginInWeb": true,
"loadPluginInNative": true,
"loadPluginInEditor": false,
"subMetas": {}
}
\ No newline at end of file
...@@ -4,14 +4,14 @@ ...@@ -4,14 +4,14 @@
// - https://docs.cocos.com/creator/manual/en/scripting/reference/attributes.html // - https://docs.cocos.com/creator/manual/en/scripting/reference/attributes.html
// Learn life-cycle callbacks: // Learn life-cycle callbacks:
// - https://docs.cocos.com/creator/manual/en/scripting/life-cycle-callbacks.html // - https://docs.cocos.com/creator/manual/en/scripting/life-cycle-callbacks.html
import GameLogic from "./GameLogic"
cc.Class({ cc.Class({
extends: cc.Component, extends: cc.Component,
gameLogic: null,
properties: { properties: {
}, },
// 生命周期 onLoad // 生命周期 onLoad
...@@ -67,10 +67,18 @@ cc.Class({ ...@@ -67,10 +67,18 @@ cc.Class({
} }
getData((data) => { getData((data) => {
console.log('data:', data);
this.data = data || this.getDefaultData(); this.data = data || this.getDefaultData();
this.data = JSON.parse(JSON.stringify(this.data)) this.data = JSON.parse(JSON.stringify(this.data))
this.preloadItem() this.preloadItem()
// 添加游戏逻辑
this.gameLogic = new GameLogic(this.data, {
designSize: this._designSize,
frameSize: this._frameSize,
mapScaleMin: this._mapScaleMin,
mapScaleMax: this._mapScaleMax,
cocosScale: this._cocosScale,
});
}) })
}, },
...@@ -79,8 +87,7 @@ cc.Class({ ...@@ -79,8 +87,7 @@ cc.Class({
}, },
getDefaultData() { getDefaultData() {
const dataJson = '{"contentObj":{"version":"1.0","key":"DataKey_Sbox_FT_08","bgMusic":"","titleText":"TEstd","questionAudio_url":"","dataArray":[{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/51795b0a7c66d61ad85a388c4299f614.jpg","audio_url":"http://staging-teach.cdn.ireadabc.com/3b5540cc95a006dff8c41dba7537075a.mp3"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/c9d60af536380445e48c637acb753d51.gif"},{"text":"","image_url":"http://staging-teach.cdn.ireadabc.com/d3cdc8921c6ae9b4f29b25fbb3a0f2f9.jpg"}]}}'
const dataJson = '{"pic_url":"http://staging-teach.cdn.ireadabc.com/ed94332a503c31e0908bd4c6923a2665.png","pic_url_2":"http://staging-teach.cdn.ireadabc.com/5fb60317ade0195d35ad8034d5370a7f.png","text":"This is a test label.","audio_url":"http://staging-teach.cdn.ireadabc.com/f47f1d7b5c160fe1c59500d180346240.mp3"}'
const data = JSON.parse(dataJson); const data = JSON.parse(dataJson);
return data; return data;
}, },
...@@ -95,8 +102,15 @@ cc.Class({ ...@@ -95,8 +102,15 @@ cc.Class({
addPreloadImage() { addPreloadImage() {
this._imageResList.push({ url: this.data.pic_url }); if (!this.data.dataArray) {
this._imageResList.push({ url: this.data.pic_url_2 }); return;
}
this.data.dataArray.forEach(item=>{
this._imageResList.push({ url: item.question.centerImage_url});
})
}, },
addPreloadAudio() { addPreloadAudio() {
...@@ -105,7 +119,16 @@ cc.Class({ ...@@ -105,7 +119,16 @@ cc.Class({
}, },
addPreloadAnima() { addPreloadAnima() {
if (!this.data.dataArray) {
return;
}
this.data.dataArray.forEach((item) => {
if (item.dragonBones) {
this._animaResList.push({url: item.dragonBones.skeJsonData.url});
this._animaResList.push({url: item.dragonBones.texJsonData.url});
this._animaResList.push({url: item.dragonBones.texPngData.url});
}
})
}, },
preload() { preload() {
...@@ -125,7 +148,6 @@ cc.Class({ ...@@ -125,7 +148,6 @@ cc.Class({
loadEnd() { loadEnd() {
this.initData(); this.initData();
this.initAudio();
this.initView(); this.initView();
// this.initListener(); // this.initListener();
}, },
...@@ -136,29 +158,15 @@ cc.Class({ ...@@ -136,29 +158,15 @@ cc.Class({
this._cantouch = true; this._cantouch = true;
}, },
audioBtn: null,
initAudio() {
const audioNode = cc.find('Canvas/res/audio');
const getAudioByResName = (resName) => {
return audioNode.getChildByName(resName).getComponent(cc.AudioSource);
}
this.audioBtn = getAudioByResName('btn');
},
initView() { initView() {
this.initBg(); this.initBg();
this.initPic(); // this.initPic();
this.initBtn(); // this.initBtn();
this.initIcon(); // this.initIcon();
}, },
initBg() { initBg() {
const bgNode = cc.find('Canvas/bg'); const bgNode = cc.find('Canvas/bgMain');
bgNode.scale = this._mapScaleMax; bgNode.scale = this._mapScaleMax;
}, },
...@@ -232,6 +240,7 @@ cc.Class({ ...@@ -232,6 +240,7 @@ cc.Class({
//节点中添加了button组件 则可以添加click事件监听 //节点中添加了button组件 则可以添加click事件监听
leftBtnNode.on('click', () => { leftBtnNode.on('click', () => {
if (!this._cantouch) { if (!this._cantouch) {
console.warn("_cantouch disabeld!")
return; return;
} }
if (this.curPage == 0) { if (this.curPage == 0) {
...@@ -247,6 +256,7 @@ cc.Class({ ...@@ -247,6 +256,7 @@ cc.Class({
//节点中添加了button组件 则可以添加click事件监听 //节点中添加了button组件 则可以添加click事件监听
rightBtnNode.on('click', () => { rightBtnNode.on('click', () => {
if (!this._cantouch) { if (!this._cantouch) {
console.warn("_cantouch disabeld!")
return; return;
} }
if (this.curPage == 1) { if (this.curPage == 1) {
...@@ -322,6 +332,13 @@ cc.Class({ ...@@ -322,6 +332,13 @@ cc.Class({
return node; return node;
}, },
getSprNode(resName) {
const sf = cc.find(resName).getComponent(cc.Sprite).spriteFrame;
const node = new cc.Node();
node.addComponent(cc.Sprite).spriteFrame = sf;
return node;
},
getSpriteFrimeByUrl(url, cb) { getSpriteFrimeByUrl(url, cb) {
cc.loader.load({ url }, (err, img) => { cc.loader.load({ url }, (err, img) => {
......
export default {
default: true,
dataArray: [
{
question: {
question_text: "What Am I Doing?",
body_text: "I am walking.",
question_audio_url: "whatamidoing",
body_audio_url: "imwalking"
},
selectCards: [
{ image_url: "eat", audio_url: "imeatting", stage_image_url: "", isAnswer: false },
{ image_url: "fly", audio_url: "iamflying", stage_image_url: "", isAnswer: false },
{ image_url: "drive", audio_url: "imdrivingmycar", stage_image_url: "", isAnswer: false },
{ image_url: "dance", audio_url: "imdancing", stage_image_url: "", isAnswer: false },
{ image_url: "jump", audio_url: "iamjumping", stage_image_url: "", isAnswer: false },
{ image_url: "roll", audio_url: "iamrolling", stage_image_url: "", isAnswer: false },
{ image_url: "sleep", audio_url: "imsleeping", stage_image_url: "", isAnswer: false },
{ image_url: "walk", audio_url: "imwalking", stage_image_url: "", isAnswer: true }
]
},
{
question: {
question_text: "What Am I Doing?",
body_text: "I am dancing.",
question_audio_url: "",
body_audio_url: "imdancing"
},
selectCards: [
{ image_url: "dance", audio_url: "imdancing", stage_image_url: "", isAnswer: true },
{ image_url: "jump", audio_url: "iamjumping", stage_image_url: "", isAnswer: false },
{ image_url: "sleep", audio_url: "imsleeping", stage_image_url: "", isAnswer: false },
{ image_url: "drive", audio_url: "imdrivingmycar", stage_image_url: "", isAnswer: false },
{ image_url: "walk", audio_url: "imwalking", stage_image_url: "", isAnswer: false }
]
},
{
question: {
question_text: "What Am I Doing?",
body_text: "I am sleeping.",
question_audio_url: "",
body_audio_url: "imsleeping"
},
selectCards: [
{ image_url: "dance", audio_url: "imdancing", stage_image_url: "", isAnswer: false },
{ image_url: "eat", audio_url: "imeatting", stage_image_url: "", isAnswer: false },
{ image_url: "fly", audio_url: "iamflying", stage_image_url: "", isAnswer: false },
{ image_url: "sleep", audio_url: "imsleeping", stage_image_url: "", isAnswer: true },
{ image_url: "drive", audio_url: "imdrivingmycar", stage_image_url: "", isAnswer: false },
{ image_url: "walk", audio_url: "imwalking", stage_image_url: "", isAnswer: false }
]
},
{
question: {
question_text: "What Am I Doing?",
body_text: "I am eatting.",
question_audio_url: "",
body_audio_url: "imeatting"
},
selectCards: [
{ image_url: "drive", audio_url: "imdrivingmycar", stage_image_url: "", isAnswer: false },
{ image_url: "fly", audio_url: "imsleeping", stage_image_url: "", isAnswer: false },
{ image_url: "dance", audio_url: "imdancing", stage_image_url: "", isAnswer: false },
{ image_url: "eat", audio_url: "imeatting", stage_image_url: "", isAnswer: true },
{ image_url: "roll", audio_url: "iamrolling", stage_image_url: "", isAnswer: false },
{ image_url: "jump", audio_url: "iamjumping", stage_image_url: "", isAnswer: false },
{ image_url: "sleep", audio_url: "imsleeping", stage_image_url: "", isAnswer: false },
]
}
]
}
\ No newline at end of file
{
"ver": "1.0.8",
"uuid": "045d28a3-8121-42c8-9c5b-d8a5e06fcebf",
"isPlugin": false,
"loadPluginInWeb": true,
"loadPluginInNative": true,
"loadPluginInEditor": false,
"subMetas": {}
}
\ No newline at end of file
...@@ -118,7 +118,8 @@ export async function asyncPlayEffectByUrl(url, loop = false) { ...@@ -118,7 +118,8 @@ export async function asyncPlayEffectByUrl(url, loop = false) {
}); });
} }
export async function jelly(node) { export function jelly(node) {
console.log("Jelly")
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
cc.tween(node) cc.tween(node)
.to(0.1, { scaleX: 0.9, scaleY: 1.1 }) .to(0.1, { scaleX: 0.9, scaleY: 1.1 })
......
{ {
"ver": "2.3.5", "ver": "2.3.5",
"uuid": "efa5fa09-a4dd-4bfc-ab7e-17c19f85408f", "uuid": "14cea5d9-0c87-4950-a269-a35b2fd51b19",
"type": "sprite", "type": "sprite",
"wrapMode": "clamp", "wrapMode": "clamp",
"filterMode": "bilinear", "filterMode": "bilinear",
"premultiplyAlpha": false, "premultiplyAlpha": false,
"genMipmaps": false, "genMipmaps": false,
"packable": true, "packable": true,
"width": 366, "width": 49,
"height": 336, "height": 48,
"platformSettings": {}, "platformSettings": {},
"subMetas": { "subMetas": {
"1orange": { "bell": {
"ver": "1.0.4", "ver": "1.0.4",
"uuid": "43d1e79d-6de8-4dcb-b8ce-d767df7913aa", "uuid": "84e15acd-4209-49b1-b361-1d08c0dd0022",
"rawTextureUuid": "efa5fa09-a4dd-4bfc-ab7e-17c19f85408f", "rawTextureUuid": "14cea5d9-0c87-4950-a269-a35b2fd51b19",
"trimType": "auto", "trimType": "auto",
"trimThreshold": 1, "trimThreshold": 1,
"rotated": false, "rotated": false,
"offsetX": 0, "offsetX": 0,
"offsetY": -0.5, "offsetY": 0,
"trimX": 0, "trimX": 0,
"trimY": 1, "trimY": 0,
"width": 366, "width": 49,
"height": 335, "height": 48,
"rawWidth": 366, "rawWidth": 49,
"rawHeight": 336, "rawHeight": 48,
"borderTop": 0, "borderTop": 0,
"borderBottom": 0, "borderBottom": 0,
"borderLeft": 0, "borderLeft": 0,
......
{ {
"ver": "2.3.5", "ver": "2.3.5",
"uuid": "d582359e-924e-4ee9-9964-1fc4bb417e71", "uuid": "f6dc66a6-9e60-4771-8a57-1ea5f495d261",
"type": "sprite", "type": "sprite",
"wrapMode": "clamp", "wrapMode": "clamp",
"filterMode": "bilinear", "filterMode": "bilinear",
"premultiplyAlpha": false, "premultiplyAlpha": false,
"genMipmaps": false, "genMipmaps": false,
"packable": true, "packable": true,
"width": 61, "width": 57,
"height": 67, "height": 53,
"platformSettings": {}, "platformSettings": {},
"subMetas": { "subMetas": {
"btn_right": { "bell_outline": {
"ver": "1.0.4", "ver": "1.0.4",
"uuid": "e5a2dbaa-a677-4a32-90d7-a1b057d7fb59", "uuid": "4114e7e7-3fd9-46a0-9087-0a9c2b2b2f04",
"rawTextureUuid": "d582359e-924e-4ee9-9964-1fc4bb417e71", "rawTextureUuid": "f6dc66a6-9e60-4771-8a57-1ea5f495d261",
"trimType": "auto", "trimType": "auto",
"trimThreshold": 1, "trimThreshold": 1,
"rotated": false, "rotated": false,
"offsetX": -0.5, "offsetX": 0,
"offsetY": 0.5, "offsetY": 0,
"trimX": 0, "trimX": 0,
"trimY": 0, "trimY": 0,
"width": 60, "width": 57,
"height": 66, "height": 53,
"rawWidth": 61, "rawWidth": 57,
"rawHeight": 67, "rawHeight": 53,
"borderTop": 0, "borderTop": 0,
"borderBottom": 0, "borderBottom": 0,
"borderLeft": 0, "borderLeft": 0,
......
{
"ver": "2.3.5",
"uuid": "14283191-0c41-4880-988d-296cf6e2fa66",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 244,
"height": 157,
"platformSettings": {},
"subMetas": {
"bg_card": {
"ver": "1.0.4",
"uuid": "21e451e5-006e-47a2-858d-137bd5c93e05",
"rawTextureUuid": "14283191-0c41-4880-988d-296cf6e2fa66",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 244,
"height": 157,
"rawWidth": 244,
"rawHeight": 157,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "705b9dbb-f334-4b06-a184-6cc5bba89e01",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 244,
"height": 157,
"platformSettings": {},
"subMetas": {
"bg_card_selected": {
"ver": "1.0.4",
"uuid": "c58e76ff-7a00-422e-a7ac-85598ae856ef",
"rawTextureUuid": "705b9dbb-f334-4b06-a184-6cc5bba89e01",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 244,
"height": 157,
"rawWidth": 244,
"rawHeight": 157,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{ {
"ver": "2.3.5", "ver": "2.3.5",
"uuid": "e1b4d971-9876-4832-803a-5a321964a78b", "uuid": "97599a18-5d6e-42b7-8b13-4c8016505ea0",
"type": "sprite", "type": "sprite",
"wrapMode": "clamp", "wrapMode": "clamp",
"filterMode": "bilinear", "filterMode": "bilinear",
...@@ -11,10 +11,10 @@ ...@@ -11,10 +11,10 @@
"height": 720, "height": 720,
"platformSettings": {}, "platformSettings": {},
"subMetas": { "subMetas": {
"bg": { "bg_main": {
"ver": "1.0.4", "ver": "1.0.4",
"uuid": "8288e3d4-4c75-4b27-8f01-f7014417f4dd", "uuid": "12f025e1-948d-4457-ab20-7e40c754e9df",
"rawTextureUuid": "e1b4d971-9876-4832-803a-5a321964a78b", "rawTextureUuid": "97599a18-5d6e-42b7-8b13-4c8016505ea0",
"trimType": "auto", "trimType": "auto",
"trimThreshold": 1, "trimThreshold": 1,
"rotated": false, "rotated": false,
......
{
"ver": "2.3.5",
"uuid": "d1ce54c5-6cf2-4e3a-9453-853ff1820663",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 1248,
"height": 136,
"platformSettings": {},
"subMetas": {
"bg_shuicao": {
"ver": "1.0.4",
"uuid": "a11a2983-2743-4300-9768-582c5a968e81",
"rawTextureUuid": "d1ce54c5-6cf2-4e3a-9453-853ff1820663",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 1248,
"height": 136,
"rawWidth": 1248,
"rawHeight": 136,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "9ca4e628-dff4-47b4-ac8e-097dac9b04fd",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 1280,
"height": 392,
"platformSettings": {},
"subMetas": {
"bg_snow": {
"ver": "1.0.4",
"uuid": "019c8b37-02d9-4ec3-a51e-78384eab2ca9",
"rawTextureUuid": "9ca4e628-dff4-47b4-ac8e-097dac9b04fd",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 1280,
"height": 392,
"rawWidth": 1280,
"rawHeight": 392,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "f3ed1875-e025-4e91-b97d-f859167136cb",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 424,
"height": 50,
"platformSettings": {},
"subMetas": {
"bg_title": {
"ver": "1.0.4",
"uuid": "9ec690bb-81d4-4453-96ca-1e54786c20bc",
"rawTextureUuid": "f3ed1875-e025-4e91-b97d-f859167136cb",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 211.5,
"offsetY": -24.5,
"trimX": 423,
"trimY": 49,
"width": 1,
"height": 1,
"rawWidth": 424,
"rawHeight": 50,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "5ef6135d-2395-4377-b3d5-549b3d458bee",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 100,
"height": 100,
"platformSettings": {},
"subMetas": {
"black": {
"ver": "1.0.4",
"uuid": "7a2d99d6-2009-4341-83f8-f18980e6405d",
"rawTextureUuid": "5ef6135d-2395-4377-b3d5-549b3d458bee",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 100,
"height": 100,
"rawWidth": 100,
"rawHeight": 100,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "ede447b3-6e36-4d05-906a-252bfc7c67f9",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 220,
"height": 110,
"platformSettings": {},
"subMetas": {
"card_demo": {
"ver": "1.0.4",
"uuid": "8141731d-96d5-420e-a2f2-694409faf1c5",
"rawTextureUuid": "ede447b3-6e36-4d05-906a-252bfc7c67f9",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 220,
"height": 110,
"rawWidth": 220,
"rawHeight": 110,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "18d07592-51a9-421e-8972-0f67b68d29e1",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 144,
"height": 144,
"platformSettings": {},
"subMetas": {
"icon": {
"ver": "1.0.4",
"uuid": "6fbc30a8-3c49-44ae-8ba4-7f56f385b78a",
"rawTextureUuid": "18d07592-51a9-421e-8972-0f67b68d29e1",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": -0.5,
"trimX": 3,
"trimY": 2,
"width": 138,
"height": 141,
"rawWidth": 144,
"rawHeight": 144,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "bec60727-95aa-416b-be9e-b83d70117ccc",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 220,
"height": 110,
"platformSettings": {},
"subMetas": {
"image_content": {
"ver": "1.0.4",
"uuid": "0d1e523a-103f-4948-bc46-4b7c3b267fad",
"rawTextureUuid": "bec60727-95aa-416b-be9e-b83d70117ccc",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 109.5,
"offsetY": -54.5,
"trimX": 219,
"trimY": 109,
"width": 1,
"height": 1,
"rawWidth": 220,
"rawHeight": 110,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "fff9e44a-70e2-405a-9bd7-cb652324535a",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 1277,
"height": 12,
"platformSettings": {},
"subMetas": {
"shengzi": {
"ver": "1.0.4",
"uuid": "635fed24-4028-46b9-90b7-4f9e1361d4c2",
"rawTextureUuid": "fff9e44a-70e2-405a-9bd7-cb652324535a",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 1277,
"height": 12,
"rawWidth": 1277,
"rawHeight": 12,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "f6eb13db-a0bf-4f1e-99a0-a006850c5ace",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 770,
"height": 720,
"platformSettings": {},
"subMetas": {
"tree_1": {
"ver": "1.0.4",
"uuid": "e781dc23-f1ea-4209-ac32-64c4a865ad57",
"rawTextureUuid": "f6eb13db-a0bf-4f1e-99a0-a006850c5ace",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 770,
"height": 720,
"rawWidth": 770,
"rawHeight": 720,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "6b028ca4-62ce-4c24-9819-b28668671479",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 52,
"height": 658,
"platformSettings": {},
"subMetas": {
"tree_2": {
"ver": "1.0.4",
"uuid": "97485371-52fc-4433-818d-1e9f518feabd",
"rawTextureUuid": "6b028ca4-62ce-4c24-9819-b28668671479",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 52,
"height": 658,
"rawWidth": 52,
"rawHeight": 658,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{ {
"ver": "2.3.5", "ver": "2.3.5",
"uuid": "9a79969a-0506-48d4-bc98-3c05d109b027", "uuid": "423c4318-e496-4936-b0d8-754933ce8da3",
"type": "sprite", "type": "sprite",
"wrapMode": "clamp", "wrapMode": "clamp",
"filterMode": "bilinear", "filterMode": "bilinear",
...@@ -8,13 +8,13 @@ ...@@ -8,13 +8,13 @@
"genMipmaps": false, "genMipmaps": false,
"packable": true, "packable": true,
"width": 61, "width": 61,
"height": 67, "height": 645,
"platformSettings": {}, "platformSettings": {},
"subMetas": { "subMetas": {
"btn_left": { "tree_3": {
"ver": "1.0.4", "ver": "1.0.4",
"uuid": "ce19457d-e8f3-4c38-ae3e-d4b99208ddb5", "uuid": "a6e9ccc0-bf1b-4584-ac37-93ef9cb07890",
"rawTextureUuid": "9a79969a-0506-48d4-bc98-3c05d109b027", "rawTextureUuid": "423c4318-e496-4936-b0d8-754933ce8da3",
"trimType": "auto", "trimType": "auto",
"trimThreshold": 1, "trimThreshold": 1,
"rotated": false, "rotated": false,
...@@ -23,9 +23,9 @@ ...@@ -23,9 +23,9 @@
"trimX": 0, "trimX": 0,
"trimY": 0, "trimY": 0,
"width": 61, "width": 61,
"height": 67, "height": 645,
"rawWidth": 61, "rawWidth": 61,
"rawHeight": 67, "rawHeight": 645,
"borderTop": 0, "borderTop": 0,
"borderBottom": 0, "borderBottom": 0,
"borderLeft": 0, "borderLeft": 0,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment