Make Card a class

This commit is contained in:
CactiChameleon9 2022-07-25 10:07:39 +01:00
parent 67143708bc
commit eab9ca42f6
2 changed files with 8 additions and 1 deletions

View File

@ -1,4 +1,5 @@
extends Node extends Node
class_name Card
signal return_dice(dice_number) signal return_dice(dice_number)
signal do_movement(movement_range) signal do_movement(movement_range)
@ -6,7 +7,7 @@ signal do_damage(damage, damage_range)
signal do_effect(effect, effect_range) signal do_effect(effect, effect_range)
signal card_removed(card_self) signal card_removed(card_self)
export (Resource) var card_info export (Resource) var card_info = preload("res://Assets/CardDB/Default.tres")
var input_dice = [] var input_dice = []
var addition_dice_amount = card_info.addition_amount var addition_dice_amount = card_info.addition_amount

View File

@ -9,6 +9,11 @@
config_version=4 config_version=4
_global_script_classes=[ { _global_script_classes=[ {
"base": "Node",
"class": "Card",
"language": "GDScript",
"path": "res://UI/Card.gd"
}, {
"base": "Resource", "base": "Resource",
"class": "CardResource", "class": "CardResource",
"language": "GDScript", "language": "GDScript",
@ -20,6 +25,7 @@ _global_script_classes=[ {
"path": "res://Characters/Character.gd" "path": "res://Characters/Character.gd"
} ] } ]
_global_script_class_icons={ _global_script_class_icons={
"Card": "",
"CardResource": "", "CardResource": "",
"Character": "" "Character": ""
} }