Modding:GUIs/ru: Difference between revisions

From Vintage Story Wiki
Created page with "В общем, вы можете создать свою собственную систему графического интерфейса, если хотите, прост..."
(Created page with "== Основы графического интерфейса ==")
(Created page with "В общем, вы можете создать свою собственную систему графического интерфейса, если хотите, прост...")
Line 24: Line 24:
== Основы графического интерфейса ==
== Основы графического интерфейса ==


In general, you can pretty much build your own GUI system if you want to, by just overriding <code>OnRenderGUI</code> and render whatever you like. There's a multitude of overridable methods to handle mouse and keyboard inputs as well, see also the [https://github.com/anegostudios/vsapi/blob/master/Client/UI/Dialog/GuiDialog.cs GuiDialog] class on Github
В общем, вы можете создать свою собственную систему графического интерфейса, если хотите, просто переопределив <code>OnRenderGUI</code> и визуализируя все, что вам нравится. Также существует множество переопределяемых методов для обработки ввода с клавиатуры и мыши, см. также класс [https://github.com/anegostudios/vsapi/blob/master/Client/UI/Dialog/GuiDialog.cs GuiDialog] на Github.


If you want to use the vanilla GUI system, it's concept is merely a flat or hierarchical list of GUI elements placed at certain positions. The position is determined by an instance of <code>ElementBounds</code>. Let's have a closer look at it's properties:
If you want to use the vanilla GUI system, it's concept is merely a flat or hierarchical list of GUI elements placed at certain positions. The position is determined by an instance of <code>ElementBounds</code>. Let's have a closer look at it's properties:
Confirmedusers
13,514

edits