Cleanup of code, and added better example gui

This commit is contained in:
Mathias Westerdahl
2018-04-26 20:34:25 +02:00
parent c3c5167127
commit 2dd490557f
9 changed files with 1176 additions and 300 deletions

View File

@@ -1,7 +1,7 @@
name: "main"
scale_along_z: 0
embedded_instances {
id: "go"
id: "controller"
data: "components {\n"
" id: \"script\"\n"
" component: \"/main/main.script\"\n"
@@ -40,7 +40,7 @@ embedded_instances {
""
position {
x: 480.0
y: 640.0
y: 772.055
z: 0.0
}
rotation {
@@ -58,114 +58,6 @@ embedded_instances {
embedded_instances {
id: "logo"
data: "embedded_components {\n"
" id: \"label\"\n"
" type: \"label\"\n"
" data: \"size {\\n"
" x: 128.0\\n"
" y: 32.0\\n"
" z: 0.0\\n"
" w: 0.0\\n"
"}\\n"
"scale {\\n"
" x: 1.0\\n"
" y: 1.0\\n"
" z: 1.0\\n"
" w: 0.0\\n"
"}\\n"
"color {\\n"
" x: 1.0\\n"
" y: 1.0\\n"
" z: 1.0\\n"
" w: 1.0\\n"
"}\\n"
"outline {\\n"
" x: 0.0\\n"
" y: 0.0\\n"
" z: 0.0\\n"
" w: 1.0\\n"
"}\\n"
"shadow {\\n"
" x: 0.0\\n"
" y: 0.0\\n"
" z: 0.0\\n"
" w: 1.0\\n"
"}\\n"
"leading: 1.0\\n"
"tracking: 0.0\\n"
"pivot: PIVOT_E\\n"
"blend_mode: BLEND_MODE_ALPHA\\n"
"line_break: false\\n"
"text: \\\"QRCode: \\\"\\n"
"font: \\\"/dirtylarry/larryfont.font\\\"\\n"
"material: \\\"/builtins/fonts/label-df.material\\\"\\n"
"\"\n"
" position {\n"
" x: 200.54617\n"
" y: 47.57482\n"
" z: 0.0\n"
" }\n"
" rotation {\n"
" x: 0.0\n"
" y: 0.0\n"
" z: 0.0\n"
" w: 1.0\n"
" }\n"
"}\n"
"embedded_components {\n"
" id: \"qrcode\"\n"
" type: \"label\"\n"
" data: \"size {\\n"
" x: 128.0\\n"
" y: 32.0\\n"
" z: 0.0\\n"
" w: 0.0\\n"
"}\\n"
"scale {\\n"
" x: 1.0\\n"
" y: 1.0\\n"
" z: 1.0\\n"
" w: 0.0\\n"
"}\\n"
"color {\\n"
" x: 1.0\\n"
" y: 1.0\\n"
" z: 1.0\\n"
" w: 1.0\\n"
"}\\n"
"outline {\\n"
" x: 0.0\\n"
" y: 0.0\\n"
" z: 0.0\\n"
" w: 1.0\\n"
"}\\n"
"shadow {\\n"
" x: 0.0\\n"
" y: 0.0\\n"
" z: 0.0\\n"
" w: 1.0\\n"
"}\\n"
"leading: 1.0\\n"
"tracking: 0.0\\n"
"pivot: PIVOT_NW\\n"
"blend_mode: BLEND_MODE_ALPHA\\n"
"line_break: true\\n"
"text: \\\"...\\\"\\n"
"font: \\\"/dirtylarry/larryfont.font\\\"\\n"
"material: \\\"/builtins/fonts/label-df.material\\\"\\n"
"\"\n"
" position {\n"
" x: 73.19203\n"
" y: 21.95761\n"
" z: 0.0\n"
" }\n"
" rotation {\n"
" x: 0.0\n"
" y: 0.0\n"
" z: 0.0\n"
" w: 1.0\n"
" }\n"
"}\n"
"embedded_components {\n"
" id: \"sprite\"\n"
" type: \"sprite\"\n"
" data: \"tile_set: \\\"/main/logo.atlas\\\"\\n"
@@ -203,3 +95,38 @@ embedded_instances {
z: 1.0
}
}
embedded_instances {
id: "gui"
data: "components {\n"
" id: \"main\"\n"
" component: \"/main/main.gui\"\n"
" position {\n"
" x: 0.0\n"
" y: 0.0\n"
" z: 0.0\n"
" }\n"
" rotation {\n"
" x: 0.0\n"
" y: 0.0\n"
" z: 0.0\n"
" w: 1.0\n"
" }\n"
"}\n"
""
position {
x: 0.0
y: 0.0
z: 0.0
}
rotation {
x: 0.0
y: 0.0
z: 0.0
w: 1.0
}
scale3 {
x: 1.0
y: 1.0
z: 1.0
}
}