]> git.lizzy.rs Git - dragonfireclient.git/blobdiff - src/guiFormSpecMenu.h
Prevent world creation if the world already exists
[dragonfireclient.git] / src / guiFormSpecMenu.h
index 0830165a502bcf4f507ba7cbcd25369eee809997..5c01bdcd222ec606703e933da7abc5e5024a9347 100644 (file)
@@ -86,11 +86,12 @@ class GUIFormSpecMenu : public GUIModalMenu
                }
                ListDrawSpec(const InventoryLocation &a_inventoryloc,
                                const std::string &a_listname,
-                               v2s32 a_pos, v2s32 a_geom):
+                               v2s32 a_pos, v2s32 a_geom, s32 a_start_item_i):
                        inventoryloc(a_inventoryloc),
                        listname(a_listname),
                        pos(a_pos),
-                       geom(a_geom)
+                       geom(a_geom),
+                       start_item_i(a_start_item_i)
                {
                }
 
@@ -98,6 +99,7 @@ class GUIFormSpecMenu : public GUIModalMenu
                std::string listname;
                v2s32 pos;
                v2s32 geom;
+               s32 start_item_i;
        };
 
        struct ImageDrawSpec
@@ -130,6 +132,7 @@ class GUIFormSpecMenu : public GUIModalMenu
                {
                        send = false;
                        is_button = false;
+                       is_exit = false;
                }
                std::wstring fname;
                std::wstring flabel;
@@ -137,6 +140,7 @@ class GUIFormSpecMenu : public GUIModalMenu
                int fid;
                bool send;
                bool is_button;
+               bool is_exit;
        };
 
 public:
@@ -208,6 +212,12 @@ class GUIFormSpecMenu : public GUIModalMenu
        ItemSpec *m_selected_item;
        u32 m_selected_amount;
        bool m_selected_dragging;
+       
+       // WARNING: BLACK MAGIC
+       // Used to guess and keep up with some special things the server can do.
+       // If name is "", no guess exists.
+       ItemStack m_selected_content_guess;
+       InventoryLocation m_selected_content_guess_inventory;
 
        v2s32 m_pointer;
        gui::IGUIStaticText *m_tooltip_element;