Elemente, Kombos, Fallen, KI mit Vorausschau, Kampagne, Hotseat und Netzwerk, Werkstatt, Erfolge, Tagesaufgaben, Tests und Exporte. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01QPgKvy5W9WRNFHjkm5QsHx
26 lines
882 B
GDScript
26 lines
882 B
GDScript
class_name RulesScreen
|
|
extends Control
|
|
|
|
var app
|
|
|
|
|
|
func _ready() -> void:
|
|
Style.label(self, "Regeln", 36, Style.GOLD, Rect2(0, 18, 1280, 50), "center", true)
|
|
var scroll := ScrollContainer.new()
|
|
scroll.position = Vector2(60, 78)
|
|
scroll.size = Vector2(1160, 640)
|
|
scroll.horizontal_scroll_mode = ScrollContainer.SCROLL_MODE_DISABLED
|
|
add_child(scroll)
|
|
var text := Label.new()
|
|
text.text = Style.rules_text()
|
|
text.autowrap_mode = TextServer.AUTOWRAP_WORD
|
|
text.custom_minimum_size = Vector2(1140, 0)
|
|
text.add_theme_font_size_override("font_size", 15)
|
|
scroll.add_child(text)
|
|
Style.button(self, "Zurück", Rect2(560, 735, 160, 44), func(): app.show_screen(MenuScreen.new()))
|
|
|
|
|
|
func _input(event: InputEvent) -> void:
|
|
if event is InputEventKey and event.pressed and event.keycode == KEY_ESCAPE:
|
|
app.show_screen(MenuScreen.new())
|