added test stickman card deck textures
This commit is contained in:
@@ -9,10 +9,12 @@ var card_details: Card
|
||||
|
||||
signal card_clicked(playing_card: PlayingCard)
|
||||
|
||||
func _ready() -> void:
|
||||
func _enter_tree() -> void:
|
||||
if card_details:
|
||||
print("yeses!")
|
||||
set_front_texture(CardManager.get_card_texture(card_details.card_id))
|
||||
else:
|
||||
print("NO!")
|
||||
set_front_texture(CardManager.get_card_texture(-1))
|
||||
|
||||
func move_to(new_x_position: float) -> void:
|
||||
@@ -25,7 +27,7 @@ func unselect() -> void:
|
||||
_get_new_tween().tween_property(self, "position:y", 0.0, move_duration)
|
||||
|
||||
func set_front_texture(texture: Texture) -> void:
|
||||
card_mesh.get_surface_override_material(0).albedo_texture = front_texture
|
||||
card_mesh.get_surface_override_material(0).albedo_texture = texture
|
||||
|
||||
func _get_new_tween() -> Tween:
|
||||
var tween = create_tween()
|
||||
|
||||
Reference in New Issue
Block a user