26 lines
689 B
GDScript
26 lines
689 B
GDScript
extends Node2D
|
|
|
|
var _card_class = preload("res://card.gd")
|
|
|
|
func _on_request_completed(result, response_code, headers, body):
|
|
var json = JSON.parse_string(body.get_string_from_utf8())
|
|
print(json["name"])
|
|
|
|
# Called when the node enters the scene tree for the first time.
|
|
func _ready() -> void:
|
|
# TODO: Create 2-4 player instances as children of this tabletop node.
|
|
var card = _card_class.new()
|
|
add_child(card)
|
|
|
|
print(card.card_id)
|
|
print(card.card_name)
|
|
print(card.card_type)
|
|
print(card.oracle_text)
|
|
print(card.image_path)
|
|
pass # Replace with function body.
|
|
|
|
|
|
# Called every frame. 'delta' is the elapsed time since the previous frame.
|
|
func _process(delta: float) -> void:
|
|
pass
|