-
-
Notifications
You must be signed in to change notification settings - Fork 101
DetailPanels
Extends: VBoxContainer
Allows to add extra info for cards under their focus popups. Typically used in the deckbuilder or in the viewport focus
After adding this node, adjust the info_panel_scene in its details and have it point to your custom info scene.
var info_panel_scene
var existing_details: Dictionary
This dictionary holds all detail scenes added to the list Each entry is an id for the detail (typically its tag or keyword) and the values are a pointer to the node.
var visible_details
-
Getter:
get_visible_details
This dictionary holds all detail scenes added to the list Each entry is an id for the detail (typically its tag or keyword) and the values are a pointer to the node. Returns how many details are currently visible for this card
func setup() -> void
Sets up the illustration detail, as it should always exist first
func hide_illustration() -> void
Hides the illustration detail
func show_illustration(text: String) -> void
Shows the illustration detail. This is different from the usual details, as we allow the illustration text to change every time.
func hide_all_info() -> void
Hides all created info. Typically used before showing the specific ones needed for this card
func add_info(id: String, text: String, info_scene: PackedScene = null, requires_refresh: bool = false) -> void
Adds a new info node. It requires an id for that node (Typically the relevant tag or keyword)
If this ID has already been setup, it will just be made visible If not, It will instance the scene and set up its text.
func get_visible_details() -> int
Getter for visible_details