Skip to content

Commit d0f18ff

Browse files
committed
Updated example with new graphics
1 parent 6b87009 commit d0f18ff

File tree

8 files changed

+14
-46
lines changed

8 files changed

+14
-46
lines changed
Binary file not shown.
Loading
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
images {
2-
image: "/assets/images/bunny2_ready.png"
2+
image: "/assets/images/shipBlue_manned.png"
33
}
44
extrude_borders: 2

animation/chained_tween/example.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
tags: animation
33
title: Tween animations chain
44
brief: This example shows how to chain two tween animations of the position of a game object. In addition, the scale and tint is animated separately.
5-
scripts: bunny.script
5+
scripts: spaceship.script
66
---
77

88
![tween](chained_tween.png)
Original file line numberDiff line numberDiff line change
@@ -1,57 +1,25 @@
11
name: "default"
22
scale_along_z: 0
33
embedded_instances {
4-
id: "bunny"
4+
id: "spaceship"
55
data: "components {\n"
66
" id: \"script\"\n"
7-
" component: \"/example/bunny.script\"\n"
8-
" position {\n"
9-
" x: 0.0\n"
10-
" y: 0.0\n"
11-
" z: 0.0\n"
12-
" }\n"
13-
" rotation {\n"
14-
" x: 0.0\n"
15-
" y: 0.0\n"
16-
" z: 0.0\n"
17-
" w: 1.0\n"
18-
" }\n"
7+
" component: \"/example/spaceship.script\"\n"
198
"}\n"
209
"embedded_components {\n"
2110
" id: \"sprite\"\n"
2211
" type: \"sprite\"\n"
23-
" data: \"tile_set: \\\"/assets/sprites.atlas\\\"\\n"
24-
"default_animation: \\\"bunny2_ready\\\"\\n"
12+
" data: \"default_animation: \\\"shipBlue_manned\\\"\\n"
2513
"material: \\\"/builtins/materials/sprite.material\\\"\\n"
26-
"blend_mode: BLEND_MODE_ALPHA\\n"
14+
"textures {\\n"
15+
" sampler: \\\"texture_sampler\\\"\\n"
16+
" texture: \\\"/assets/sprites.atlas\\\"\\n"
17+
"}\\n"
2718
"\"\n"
28-
" position {\n"
29-
" x: 0.0\n"
30-
" y: 0.0\n"
31-
" z: 0.0\n"
32-
" }\n"
33-
" rotation {\n"
34-
" x: 0.0\n"
35-
" y: 0.0\n"
36-
" z: 0.0\n"
37-
" w: 1.0\n"
38-
" }\n"
3919
"}\n"
4020
""
4121
position {
4222
x: 60.0
4323
y: 96.0
44-
z: 0.0
45-
}
46-
rotation {
47-
x: 0.0
48-
y: 0.0
49-
z: 0.0
50-
w: 1.0
51-
}
52-
scale3 {
53-
x: 1.0
54-
y: 1.0
55-
z: 1.0
5624
}
5725
}
Loading

animation/chained_tween/example/bunny.script renamed to animation/chained_tween/example/spaceship.script

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
local up_down -- <1>
22
local left_right
3-
3+
44
function up_down(self) -- <2>
5-
go.animate(".", "position.y", go.PLAYBACK_ONCE_PINGPONG, 624, go.EASING_INOUTSINE, 2, 0, left_right)
5+
go.animate(".", "position.y", go.PLAYBACK_ONCE_PINGPONG, 624, go.EASING_INOUTSINE, 2, 0, left_right)
66
end
77

88
function left_right(self) -- <3>
9-
go.animate(".", "position.x", go.PLAYBACK_ONCE_PINGPONG, 660, go.EASING_INOUTSINE, 2, 0, up_down)
9+
go.animate(".", "position.x", go.PLAYBACK_ONCE_PINGPONG, 660, go.EASING_INOUTSINE, 2, 0, up_down)
1010
end
1111

1212
function init(self)
13-
up_down(self) -- <4>
13+
up_down(self) -- <4>
1414
go.animate(".", "scale.y", go.PLAYBACK_LOOP_PINGPONG, 0.5, go.EASING_INOUTSINE, 1) -- <5>
1515
go.animate("#sprite", "tint.x", go.PLAYBACK_LOOP_PINGPONG, 0.0, go.EASING_INOUTSINE, 1.5) -- <6>
1616
end

render/camera/example.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
tags: render
33
title: Camera
4-
brief: This example shows how to use use a camera component and have it follow a game object. Click to toggle between following the game object and staying stationary.
4+
brief: This example shows how to use a camera component and have it follow a game object. Click to toggle between following the game object and staying stationary.
55
scripts: bee.script, camera.script
66
---
77

0 commit comments

Comments
 (0)