Uploaded game files

This commit is contained in:
JamnedZ 2022-11-18 00:52:05 +07:00
parent 459da513f6
commit f71e7e39a0
1543 changed files with 50503 additions and 0 deletions

View file

@ -0,0 +1,29 @@
func generate_animation(anima_tween: Tween, data: Dictionary) -> void:
#var delay: float = data._wait_time
var bounce_frames = [
{ percentage = 0, to = 0 },
{ percentage = 20, to = 0 },
{ percentage = 40, to = -30, easing_points = [0.7555, 0.5, 0.8555, 0.06] },
{ percentage = 43, to = 0, easing_points = [0.7555, 0.5, 0.8555, 0.06] },
{ percentage = 53, to = +30 },
{ percentage = 70, to = -15, easing_points = [0.755, 0.05, 0.855, 0.06] },
{ percentage = 80, to = +15 },
{ percentage = 90, to = -4 },
{ percentage = 100, to = +4 },
]
var scale = DialogicAnimaPropertiesHelper.get_scale(data.node)
var scale_frames = [
{ percentage = 0, to = 1 * scale.y },
{ percentage = 20, to = 1 * scale.y },
{ percentage = 40, to = 1.1 * scale.y, easing_points = [0.7555, 0.5, 0.8555, 0.06] },
{ percentage = 43, to = 1.1 * scale.y, easing_points = [0.7555, 0.5, 0.8555, 0.06] },
{ percentage = 53, to = 1 * scale.y },
{ percentage = 70, to = 1.05 * scale.y, easing_points = [0.755, 0.05, 0.855, 0.06] },
{ percentage = 80, to = 0.95 * scale.y },
{ percentage = 90, to = 1.02 * scale.y },
{ percentage = 100, to = 1 * scale.y },
]
anima_tween.add_relative_frames(data, "Y", bounce_frames)
anima_tween.add_frames(data, "scale:y", scale_frames)

View file

@ -0,0 +1,10 @@
func generate_animation(anima_tween: Tween, data: Dictionary) -> void:
var frames = [
{ percentage = 0, from = 1 },
{ percentage = 25, to = 0 },
{ percentage = 50, to = 1 },
{ percentage = 75, to = 0 },
{ percentage = 100, to = 1 },
]
anima_tween.add_frames(data, "opacity", frames)

View file

@ -0,0 +1,27 @@
func generate_animation(anima_tween: Tween, data: Dictionary) -> void:
var start = DialogicAnimaPropertiesHelper.get_position(data.node)
var shake_frames = [
{ percentage = 0, from = 0 },
{ percentage = 6.5, to = -6 },
{ percentage = 18.5, to = +5 },
{ percentage = 31.5, to = -3 },
{ percentage = 43.5, to = +2 },
{ percentage = 50, to = 0 },
{ percentage = 100, to = 0 },
]
var rotate_frames = [
{ percentage = 0, to = 0 },
{ percentage = 6.5, to = -9 },
{ percentage = 18.5, to = +7 },
{ percentage = 31.5, to = -5 },
{ percentage = 43.5, to = +3 },
{ percentage = 50, to = 0 },
{ percentage = 100, to = 0 },
]
DialogicAnimaPropertiesHelper.set_2D_pivot(data.node, DialogicAnimaPropertiesHelper.PIVOT.CENTER)
anima_tween.add_relative_frames(data, "x", shake_frames)
anima_tween.add_frames(data, "rotation", rotate_frames)

View file

@ -0,0 +1,14 @@
func generate_animation(anima_tween: Tween, data: Dictionary) -> void:
var scale = DialogicAnimaPropertiesHelper.get_scale(data.node)
var frames = [
{ percentage = 0, from = scale * Vector2(1, 1) },
{ percentage = 14, to = scale * Vector2(1.3, 1.3) },
{ percentage = 28, to = scale * Vector2(1, 1) },
{ percentage = 42, to = scale * Vector2(1.3, 1.3) },
{ percentage = 70, to = scale * Vector2(1, 1) },
{ percentage = 100, to = scale * Vector2(1, 1) },
]
DialogicAnimaPropertiesHelper.set_2D_pivot(data.node, DialogicAnimaPropertiesHelper.PIVOT.CENTER)
anima_tween.add_frames(data, "scale", frames)

View file

@ -0,0 +1,32 @@
func generate_animation(anima_tween: Tween, data: Dictionary) -> void:
var start_x = data.node.get_global_transform().y.x
var start_y = data.node.get_global_transform().x.y
var skew_x := []
var skew_y := []
var values = [
{ percentage = 0, add = 0 },
{ percentage = 11.1, add = 0 },
{ percentage = 22.2, add = - 0.3 },
{ percentage = 33.3, add = + 0.265 },
{ percentage = 44.4, add = - 0.1325 },
{ percentage = 55.5, add = + 0.06625 },
{ percentage = 66.6, add = - 0.033125 },
{ percentage = 77.7, add = + 0.0165625 },
{ percentage = 88.8, add = - 0.00828125},
{ percentage = 100, add = 0 },
]
for value in values:
skew_x.push_back({ percentage = value.percentage, to = start_x + value.add })
skew_y.push_back({ percentage = value.percentage, to = start_y + value.add })
DialogicAnimaPropertiesHelper.set_2D_pivot(data.node, DialogicAnimaPropertiesHelper.PIVOT.CENTER)
# Skew works only with Node2D
if not data.node is Node2D:
return
anima_tween.add_frames(data, "skew:x", skew_x)
anima_tween.add_frames(data, "skew:y", skew_y)

View file

@ -0,0 +1,12 @@
func generate_animation(anima_tween: Tween, data: Dictionary) -> void:
var scale = DialogicAnimaPropertiesHelper.get_scale(data.node)
var frames = [
{ percentage = 0, from = scale * Vector2(1, 1) },
{ percentage = 50, to = scale * Vector2(1.05, 1.05), easing = anima_tween.EASING.EASE_IN_OUT_SINE },
{ percentage = 100, to = scale * Vector2(1, 1) },
]
DialogicAnimaPropertiesHelper.set_2D_pivot(data.node, DialogicAnimaPropertiesHelper.PIVOT.CENTER)
anima_tween.add_frames(data, "scale", frames)

View file

@ -0,0 +1,15 @@
func generate_animation(anima_tween: Tween, data: Dictionary) -> void:
var scale = DialogicAnimaPropertiesHelper.get_scale(data.node)
var frames = [
{ percentage = 0, from = scale * Vector2(1, 1) },
{ percentage = 30, to = scale * Vector2(1.25, 0.75) },
{ percentage = 40, to = scale * Vector2(0.75, 1.25) },
{ percentage = 50, to = scale * Vector2(1.15, 0.85) },
{ percentage = 65, to = scale * Vector2(0.95, 1.05) },
{ percentage = 75, to = scale * Vector2(1.05, 0.95) },
{ percentage = 100, to = scale * Vector2(1, 1) },
]
DialogicAnimaPropertiesHelper.set_2D_pivot(data.node, DialogicAnimaPropertiesHelper.PIVOT.CENTER)
anima_tween.add_frames(data, "scale", frames)

View file

@ -0,0 +1,16 @@
func generate_animation(anima_tween: Tween, data: Dictionary) -> void:
var frames = [
{ percentage = 0, to = 0 },
{ percentage = 10, to = -10 },
{ percentage = 20, to = +20 },
{ percentage = 30, to = -20 },
{ percentage = 40, to = +20 },
{ percentage = 50, to = -20 },
{ percentage = 60, to = +20 },
{ percentage = 70, to = -20 },
{ percentage = 80, to = +20 },
{ percentage = 90, to = -20 },
{ percentage = 100, to = +10 },
]
anima_tween.add_relative_frames(data, "x", frames)

View file

@ -0,0 +1,16 @@
func generate_animation(anima_tween: Tween, data: Dictionary) -> void:
var frames = [
{ percentage = 0, to = 0 },
{ percentage = 10, to = -10 },
{ percentage = 20, to = +20 },
{ percentage = 30, to = -20 },
{ percentage = 40, to = +20 },
{ percentage = 50, to = -20 },
{ percentage = 60, to = +20 },
{ percentage = 70, to = -20 },
{ percentage = 80, to = +20 },
{ percentage = 90, to = -20 },
{ percentage = 100, to = +10 },
]
anima_tween.add_relative_frames(data, "y", frames)

View file

@ -0,0 +1,12 @@
func generate_animation(anima_tween: Tween, data: Dictionary) -> void:
var frames = [
{ percentage = 0, from = 0 },
{ percentage = 20, to = 15 },
{ percentage = 40, to = -10 },
{ percentage = 60, to = 5 },
{ percentage = 80, to = -5 },
{ percentage = 100, to = 0 },
]
DialogicAnimaPropertiesHelper.set_2D_pivot(data.node, DialogicAnimaPropertiesHelper.PIVOT.TOP_CENTER)
anima_tween.add_frames(data, "rotation", frames)

View file

@ -0,0 +1,22 @@
func generate_animation(anima_tween: Tween, data: Dictionary) -> void:
var rotate_frames = [
{ percentage = 0, from = 0 },
]
var scale_frames = [
{ percentage = 0, from = DialogicAnimaPropertiesHelper.get_scale(data.node) * Vector2(1, 1) },
]
for index in range(2, 9):
var s = -1 if index % 2 == 0 else 1
var percent = index * 10.0
rotate_frames.push_back({ percentage = percent, to = 3 * s })
scale_frames.push_back({ percentage = percent, to = Vector2(1.1, 1.1) })
DialogicAnimaPropertiesHelper.set_2D_pivot(data.node, DialogicAnimaPropertiesHelper.PIVOT.CENTER)
rotate_frames.push_back({percentage = 100, to = 0})
scale_frames.push_back({percentage = 100, to = Vector2(1, 1)})
anima_tween.add_frames(data, "rotation", rotate_frames)
anima_tween.add_frames(data, "scale", scale_frames)

View file

@ -0,0 +1,28 @@
func generate_animation(anima_tween: Tween, data: Dictionary) -> void:
var node = data.node
var start_position = DialogicAnimaPropertiesHelper.get_position(node)
var size = DialogicAnimaPropertiesHelper.get_size(node)
var x_frames = [
{ percentage = 0, from = start_position.x },
{ percentage = 15, to = start_position.x + size.x * -0.25 },
{ percentage = 30, to = start_position.x + size.x * 0.2 },
{ percentage = 45, to = start_position.x + size.x * -0.15 },
{ percentage = 60, to = start_position.x + size.x * 0.1 },
{ percentage = 75, to = start_position.x + size.x * -0.05 },
{ percentage = 100, to = start_position.x },
]
var rotation_frames = [
{ percentage = 0, from = 0 },
{ percentage = 15, to = -5 },
{ percentage = 30, to = 3 },
{ percentage = 45, to = -3 },
{ percentage = 60, to = 2 },
{ percentage = 75, to = -1 },
{ percentage = 100, to = 0 },
]
DialogicAnimaPropertiesHelper.set_2D_pivot(data.node, DialogicAnimaPropertiesHelper.PIVOT.TOP_CENTER)
anima_tween.add_frames(data, "x", x_frames)
anima_tween.add_frames(data, "rotation", rotation_frames)