--- a/LuaGUI.wiki Wed Apr 17 14:59:27 2019 +0100
+++ b/LuaGUI.wiki Wed Apr 17 15:02:34 2019 +0100
@@ -3,10 +3,9 @@
= Lua API: GUI functions =
This page is a list of all functios in the [LuaAPI Lua API] that affect the GUI (graphical user interface).
-<wiki:toc max_depth="3" />
+<wiki:toc max_depth="2" />
-== Captions ==
-=== <tt>!AddCaption(text)</tt> ===
+== <tt>!AddCaption(text)</tt> ==
Display an event text in the upper part of the screen. The text will be white and the caption group will be `capgrpMessage`.
Example:
@@ -14,7 +13,7 @@
AddCaption("Hello, world!")
</code>
-=== <tt>!AddCaption(text, color, captiongroup)</tt> ===
+== <tt>!AddCaption(text, color, captiongroup)</tt> ==
Display an event text in the upper part of the screen with the specified RGBA text [LuaOverview#Color color] and caption group. Although an RBGA color is used, Hedgewars does not actually support transparent or semi-transparent captions, so the fourth byte is ignored. We recommend you to always specify a full opacity (`FF` in hexadecimal) for the caption.
|| *`captiongroup`* || *Meaning* ||
@@ -37,8 +36,7 @@
-- Green example message.
</code>
-== Mission panel ==
-=== <tt>!ShowMission(caption, subcaption, text, icon, time [, forceDisplay])</tt> ===
+== <tt>!ShowMission(caption, subcaption, text, icon, time [, forceDisplay])</tt> ==
This function will open the mission panel and set the texts in it.
Use to tell the player what he/she is supposed to do. If you use this function, a mission panel is shown for the amount of time specified in `time` (in milliseconds). If `time` is set to 0, it will be displayed for a default amount of time.
@@ -81,18 +79,16 @@
(Note: `loc` comes from the [LuaLibraryLocale Locale Lua library.)
-=== <tt>!HideMission()</tt> ===
+== <tt>!HideMission()</tt> ==
Hides the mission panel if it is currently displayed, otherwise, this function does nothing.
-== Zoom ==
-=== <tt>!SetZoom(zoomLevel)</tt> ===
+== <tt>!SetZoom(zoomLevel)</tt> ==
Sets the zoom level. The value for maximum zoom is currently 1.0 and for minimum 3.0 The default zoom level is 2.0
-=== <tt>!GetZoom()</tt> ===
+== <tt>!GetZoom()</tt> ==
Returns the current zoom level.
-== Cinematic mode ==
-=== <tt>!SetCinematicMode(enable)</tt> (0.9.23) ===
+== <tt>!SetCinematicMode(enable)</tt> (0.9.23) ==
Turns on or off cinematic mode. Cinematic mode can be used for cutscenes etc.
If `enable` is set to `true`, cinematic mode is enabled,
if it is `false`, cinematic mode is disabled.