Keller-Dev
Docs
· Java & Hytale
Übersicht
Neuer Eintrag
Eintrag bearbeiten
Titel *
Kategorie *
Java Core
Java OOP
Java Advanced
Plugin-System
Event-System
UI-System
Sonstiges
Erklärung / Inhalt *
Eine .ui-Datei ist ein Hytalespezifisches Markup-System. Die Grundlegende Syntax ist hier beschrieben
Code-Beispiel (optional)
// Basic declaration of an element // with its Anchor property set to attach on all sides of its parent // with 10 pixels of margin Group { Anchor: (Left: 10, Top: 10, Right: 10, Bottom: 10); } Group { Anchor: (Full: 10); } // More concise version // Declaration of a Label with a name // (can be used to access the element from game code) Label #MyLabel { Style: LabelStyle(FontSize: 16); // or just Style: (FontSize: 16), type can be inferred. Text: "Hi! I am text."; } // Declaration of a Group containing 2 children // You can use FlexWeight to distribute any left-over space after explicit widths/heights have been subtracted Group { LayoutMode: Left; Label { Text: "Child 1"; FlexWeight: 2; } Label { Text: "Child 2"; FlexWeight: 1; } }
Referenz-Datei / Projekt (optional)
Referenz-Klasse / Interface (optional)
Quellen-Link (optional)
Tags (durch Komma getrennt)
Änderungen speichern
Abbrechen