From 84adc0ac9b03f344565a1dbd2f78824b62ba9205 Mon Sep 17 00:00:00 2001 From: Dennis Ploeger Date: Mon, 6 Dec 2021 15:12:52 +0100 Subject: [PATCH] fix: Support Godot 3.4 (#478) --- .../resources/esc_animationresource.gd | 36 +++---------------- 1 file changed, 4 insertions(+), 32 deletions(-) diff --git a/addons/escoria-core/game/core-scripts/resources/esc_animationresource.gd b/addons/escoria-core/game/core-scripts/resources/esc_animationresource.gd index 7cae50ae..a8861d72 100644 --- a/addons/escoria-core/game/core-scripts/resources/esc_animationresource.gd +++ b/addons/escoria-core/game/core-scripts/resources/esc_animationresource.gd @@ -10,49 +10,21 @@ class_name ESCAnimationResource # start_angle must be between 0 and 360. # Angle 0 and 360 are the same and correspond to UP/NORTH # 90 is RIGHT/EAST, 180 is DOWN/SOUTH, etc -var dir_angles: Array = [] +export(Array, Resource) var dir_angles: Array = [] # Array of animations for each direction, from UP to RIGHT_UP clockwise # [animation_name, scale]: scale parameter can be set to -1 to mirror # the animation -var directions: Array = [] +export(Array, Resource) var directions: Array = [] # Array containing the idle animations for each direction (in the # order defined by dir_angles): scale parameter can be set to -1 to mirror # the animation -var idles: Array = [] +export(Array, Resource) var idles: Array = [] # Array containing the speak animations for each direction (in the # order defined by dir_angles): scale parameter can be set to -1 to mirror # the animation -var speaks: Array = [] +export(Array, Resource) var speaks: Array = [] - -func _get_property_list(): - var properties = [] - properties.append({ - "name": "dir_angles", - "type": TYPE_ARRAY, - "hint": 19, - "hint_string": "17/17:ESCDirectionAngle" - }) - properties.append({ - "name": "directions", - "type": TYPE_ARRAY, - "hint": 19, - "hint_string": "17/17:ESCAnimationName" - }) - properties.append({ - "name": "idles", - "type": TYPE_ARRAY, - "hint": 19, - "hint_string": "17/17:ESCAnimationName" - }) - properties.append({ - "name": "speaks", - "type": TYPE_ARRAY, - "hint": 19, - "hint_string": "17/17:ESCAnimationName" - }) - return properties