Initial commit — jibo-cli v3.0.7 with bundled node_modules
This commit is contained in:
11
templates/asset-pack-template/README.md
Normal file
11
templates/asset-pack-template/README.md
Normal file
@@ -0,0 +1,11 @@
|
||||
# Building
|
||||
|
||||
Build process is implemented using NPM scripts installed in the **package.json** file.
|
||||
|
||||
| Command | Description
|
||||
|---|---|
|
||||
|`npm run build` | Build the project in debug mode. |
|
||||
|`npm run build:release` | Build the project in release mode. |
|
||||
|`npm run watch` | Watch the source and behaviors, auto-rebuilds. |
|
||||
|`npm run clean` | Deletes built JavaScript files. |
|
||||
|`npm start` | Alias for `npm run watch`. |
|
||||
59
templates/asset-pack-template/animations/animation.keys
Normal file
59
templates/asset-pack-template/animations/animation.keys
Normal file
@@ -0,0 +1,59 @@
|
||||
{
|
||||
"framerate": 30,
|
||||
"duration": 60,
|
||||
"layers": [
|
||||
{
|
||||
"id": "832d41d5e0934c00bc75634b9a305812",
|
||||
"name": "Body #1",
|
||||
"type": "Body",
|
||||
"visible": true,
|
||||
"locked": false,
|
||||
"keyframes": [
|
||||
{
|
||||
"value": {
|
||||
"Head": 0,
|
||||
"Torso": 0,
|
||||
"Pelvis": 0
|
||||
},
|
||||
"time": 0
|
||||
},
|
||||
{
|
||||
"value": {
|
||||
"Head": 56.000000000000014,
|
||||
"Torso": -65.5,
|
||||
"Pelvis": 0
|
||||
},
|
||||
"time": 29
|
||||
},
|
||||
{
|
||||
"value": {
|
||||
"Head": 0,
|
||||
"Torso": 0,
|
||||
"Pelvis": 0
|
||||
},
|
||||
"time": 59
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "1fd26d531b6e46ab81578d2c4b5ba169",
|
||||
"name": "Eye Texture #1",
|
||||
"type": "Eye Texture",
|
||||
"visible": true,
|
||||
"locked": false,
|
||||
"keyframes": [
|
||||
{
|
||||
"value": {
|
||||
"Texture": "animations/textures/lens.png",
|
||||
"Color": {
|
||||
"h": 0,
|
||||
"s": 0,
|
||||
"v": 100
|
||||
}
|
||||
},
|
||||
"time": 0
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
BIN
templates/asset-pack-template/animations/textures/bg/black.png
Normal file
BIN
templates/asset-pack-template/animations/textures/bg/black.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 18 KiB |
BIN
templates/asset-pack-template/animations/textures/bg/white.png
Normal file
BIN
templates/asset-pack-template/animations/textures/bg/white.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 18 KiB |
BIN
templates/asset-pack-template/animations/textures/happy-face.png
Normal file
BIN
templates/asset-pack-template/animations/textures/happy-face.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 169 KiB |
BIN
templates/asset-pack-template/animations/textures/lens.png
Normal file
BIN
templates/asset-pack-template/animations/textures/lens.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 766 KiB |
BIN
templates/asset-pack-template/animations/textures/white-eye.png
Normal file
BIN
templates/asset-pack-template/animations/textures/white-eye.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 194 KiB |
BIN
templates/asset-pack-template/audio/FX_Bawhoop.mp3
Normal file
BIN
templates/asset-pack-template/audio/FX_Bawhoop.mp3
Normal file
Binary file not shown.
BIN
templates/asset-pack-template/audio/FX_Bleep.mp3
Normal file
BIN
templates/asset-pack-template/audio/FX_Bleep.mp3
Normal file
Binary file not shown.
BIN
templates/asset-pack-template/audio/FX_Blip.mp3
Normal file
BIN
templates/asset-pack-template/audio/FX_Blip.mp3
Normal file
Binary file not shown.
BIN
templates/asset-pack-template/audio/FX_Bloop.mp3
Normal file
BIN
templates/asset-pack-template/audio/FX_Bloop.mp3
Normal file
Binary file not shown.
4
templates/asset-pack-template/build/debug.json
Normal file
4
templates/asset-pack-template/build/debug.json
Normal file
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"DEBUG": true,
|
||||
"RELEASE": false
|
||||
}
|
||||
4
templates/asset-pack-template/build/release.json
Normal file
4
templates/asset-pack-template/build/release.json
Normal file
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"DEBUG": false,
|
||||
"RELEASE": true
|
||||
}
|
||||
4
templates/asset-pack-template/npmignore
Normal file
4
templates/asset-pack-template/npmignore
Normal file
@@ -0,0 +1,4 @@
|
||||
node_modules
|
||||
/build
|
||||
.gitignore
|
||||
src
|
||||
25
templates/asset-pack-template/package.json
Normal file
25
templates/asset-pack-template/package.json
Normal file
@@ -0,0 +1,25 @@
|
||||
{
|
||||
"name": "__package-name__",
|
||||
"version": "1.0.0",
|
||||
"description": "",
|
||||
"main": "index.js",
|
||||
"jibo": {
|
||||
"type": "asset-pack",
|
||||
"display-name": "__display-name__"
|
||||
},
|
||||
"scripts": {
|
||||
"start": "jibo-dev watch",
|
||||
"watch": "jibo-dev watch",
|
||||
"clean": "jibo-dev clean",
|
||||
"behaviors": "behaviorify -o behaviors -i src/behaviors",
|
||||
"prebuild": "npm run behaviors",
|
||||
"build": "jibo-dev build",
|
||||
"prebuild:release": "npm run behaviors",
|
||||
"build:release": "jibo-dev build --prod"
|
||||
},
|
||||
"license": "UNLICENSED",
|
||||
"devDependencies": {
|
||||
"jibo": "^6.0.0",
|
||||
"jibo-dev": "^2.0.0"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
{
|
||||
"TestDebugBehavior": {
|
||||
"type": "leaf",
|
||||
"options": [
|
||||
{
|
||||
"type": "string",
|
||||
"field": "text",
|
||||
"description": "Debug text to log.",
|
||||
"defaultValue": "null"
|
||||
}
|
||||
]
|
||||
},
|
||||
"meta": {
|
||||
"verison": 1
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
import jibo = require('jibo');
|
||||
|
||||
// Custom class extends Behavior
|
||||
class TestDebugBehavior extends jibo.bt.Behavior {
|
||||
private _status:jibo.bt.Status;
|
||||
constructor(options) {
|
||||
super(options);
|
||||
this._status = jibo.bt.Status.INVALID;
|
||||
}
|
||||
start() {
|
||||
this._status = jibo.bt.Status.SUCCEEDED;
|
||||
// @if DEBUG
|
||||
console.log('Debug: ' + this.options.text);
|
||||
// @endif
|
||||
return true;
|
||||
}
|
||||
update() {
|
||||
return this._status;
|
||||
}
|
||||
}
|
||||
|
||||
export default TestDebugBehavior;
|
||||
60
templates/asset-pack-template/src/behaviors/idle.bt
Normal file
60
templates/asset-pack-template/src/behaviors/idle.bt
Normal file
@@ -0,0 +1,60 @@
|
||||
{
|
||||
"91": {
|
||||
"id": 91,
|
||||
"class": "Sequence",
|
||||
"name": "",
|
||||
"children": [
|
||||
111,
|
||||
114,
|
||||
112
|
||||
],
|
||||
"decorators": [],
|
||||
"options": {}
|
||||
},
|
||||
"111": {
|
||||
"id": 111,
|
||||
"class": "PlayAudio",
|
||||
"name": "",
|
||||
"asset-pack": "core",
|
||||
"parent": 91,
|
||||
"options": {
|
||||
"audioPath": "FX_Blip.mp3"
|
||||
}
|
||||
},
|
||||
"112": {
|
||||
"id": 112,
|
||||
"class": "Subtree",
|
||||
"name": "",
|
||||
"asset-pack": "core",
|
||||
"parent": 91,
|
||||
"options": {
|
||||
"behaviorPath": "idle.bt",
|
||||
"getNotepad": [
|
||||
"() => {",
|
||||
"\treturn {};",
|
||||
"}"
|
||||
],
|
||||
"onResult": [
|
||||
"(result) => {",
|
||||
"}"
|
||||
]
|
||||
}
|
||||
},
|
||||
"114": {
|
||||
"id": 114,
|
||||
"class": "PlayAnimation",
|
||||
"name": "",
|
||||
"asset-pack": "core",
|
||||
"parent": 91,
|
||||
"options": {
|
||||
"animPath": "animation.keys",
|
||||
"config": [
|
||||
"(animation) => {",
|
||||
"}"
|
||||
]
|
||||
}
|
||||
},
|
||||
"meta": {
|
||||
"version": 1
|
||||
}
|
||||
}
|
||||
11
templates/asset-pack-template/src/index.ts
Normal file
11
templates/asset-pack-template/src/index.ts
Normal file
@@ -0,0 +1,11 @@
|
||||
/// <reference path="../node_modules/jibo/typings/index.d.ts" />
|
||||
|
||||
import jibo = require('jibo');
|
||||
import TestDebugBehavior from './behaviors/TestDebugBehavior';
|
||||
|
||||
// Register the custom Behavior for the jibo runtime
|
||||
jibo.bt.register(
|
||||
'TestDebugBehavior',
|
||||
'__package-name__',
|
||||
TestDebugBehavior
|
||||
);
|
||||
1
templates/asset-pack-template/src/rules/helloworld.rule
Normal file
1
templates/asset-pack-template/src/rules/helloworld.rule
Normal file
@@ -0,0 +1 @@
|
||||
TopRule = $* (hello world){%what='hello'%} $*;
|
||||
15
templates/asset-pack-template/tsconfig.json
Normal file
15
templates/asset-pack-template/tsconfig.json
Normal file
@@ -0,0 +1,15 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"moduleResolution": "node",
|
||||
"target": "es6",
|
||||
"noImplicitAny": false,
|
||||
"rootDir": ".",
|
||||
"sourceMap": true,
|
||||
"experimentalDecorators": true
|
||||
},
|
||||
"exclude": [
|
||||
"node_modules"
|
||||
],
|
||||
"compileOnSave": false
|
||||
}
|
||||
19
templates/asset-pack-template/tslint.json
Normal file
19
templates/asset-pack-template/tslint.json
Normal file
@@ -0,0 +1,19 @@
|
||||
{
|
||||
"rules": {
|
||||
"curly": true,
|
||||
"triple-equals": true,
|
||||
"semicolon": [true, "always"],
|
||||
"no-var-keyword": true,
|
||||
"no-unused-expression": true,
|
||||
"no-empty": true,
|
||||
"jsdoc-format": true,
|
||||
"no-duplicate-variable": true,
|
||||
"no-debugger": true,
|
||||
"member-ordering": [
|
||||
true,
|
||||
"public-before-private",
|
||||
"static-before-instance",
|
||||
"variables-before-functions"
|
||||
]
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user