1
1
mirror of https://github.com/Rundll86/Dog-Lynx-And-HCN.git synced 2026-06-04 10:47:13 +08:00
Files
Dog-Lynx-And-HCN/scripts/Contents/Panels/SelectIntialFeed.gd
T

17 lines
513 B
GDScript
Raw Normal View History

@tool
extends FullscreenPanelBase
@onready var initialFeedSelection: HBoxContainer = $%initialFeedSelection
func beforeOpen(_args: Array = []):
for feed in initialFeedSelection.get_children():
feed.queue_free()
ComponentManager.feeds.shuffle()
for feed in ComponentManager.feeds:
var card = feed.instantiate() as Feed
if card.topic == FeedName.Topic.WEAPON:
continue
2026-01-30 11:50:16 +08:00
card.freeToBuy = true
card.selected.connect(func(_success): UIState.closeCurrentPanel())
initialFeedSelection.add_child(card)