mirror of
https://github.com/ifengzp/cocos-awesome.git
synced 2025-10-09 16:45:51 +00:00
init
This commit is contained in:
16
assets/Script/Helloworld.ts
Normal file
16
assets/Script/Helloworld.ts
Normal file
@@ -0,0 +1,16 @@
|
||||
const {ccclass, property} = cc._decorator;
|
||||
|
||||
@ccclass
|
||||
export default class Helloworld extends cc.Component {
|
||||
|
||||
@property(cc.Label)
|
||||
label: cc.Label = null;
|
||||
|
||||
@property
|
||||
text: string = 'hello';
|
||||
|
||||
start () {
|
||||
// init logic
|
||||
this.label.string = this.text;
|
||||
}
|
||||
}
|
9
assets/Script/Helloworld.ts.meta
Normal file
9
assets/Script/Helloworld.ts.meta
Normal file
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"ver": "1.0.5",
|
||||
"uuid": "e1b90feb-a217-4493-849d-9a611900d683",
|
||||
"isPlugin": false,
|
||||
"loadPluginInWeb": true,
|
||||
"loadPluginInNative": true,
|
||||
"loadPluginInEditor": false,
|
||||
"subMetas": {}
|
||||
}
|
Reference in New Issue
Block a user