Elaztek Developer Hub
Blamite Game Engine - blam!  00406.12.10.23.1457.blamite
The core library for the Blamite Game Engine.
ip_test.hpp
Go to the documentation of this file.
1 #pragma once
2 
4 
16 {
17 public:
18 
22  void Draw()
23  {
24  //Master server connection
25  if (show)
26  {
27  ImGui::Begin("Test Master Server Connection", &show, ImGuiWindowFlags_AlwaysAutoResize/* | ImGuiWindowFlags_HasBorder*/);
28  static char iptest[255] = "343.host.elaztek.com"; // dedicatedHost
29 
30  ImGui::Text("This tool is used to test the connection to the Elaztek Master Server.\nAlternatively, you can test any "
31  "of the fallback servers by changing the IP.\n");
32 
33  ImGui::InputText("IP:", iptest, IM_ARRAYSIZE(iptest));
34  ImGui::SameLine(); Blam::UI::ImGUI::Widgets::ShowHelpMarker("Input the IP address to test in this box.\nYou may "
35  "use a DNS host (dns.domain.com) or a direct IP (1.2.3.4)");
36 
38 
39  if (ImGui::Button("Test", ImVec2(120, 0)))
40  {
41  /*ping*/
42  }
43 
44  ImGui::End();
45  }
46  }
47 };
BlamImGuiWindow::show
bool show
Controls whether or not the group should be shown. May not be used in all groups.
Definition: imgui.h:34
ImGui::InputText
IMGUI_API bool InputText(const char *label, char *buf, size_t buf_size, ImGuiInputTextFlags flags=0, ImGuiInputTextCallback callback=NULL, void *user_data=NULL)
Definition: imgui_widgets.cpp:3068
ImGui::End
IMGUI_API void End()
Definition: imgui.cpp:6016
ImGui::SameLine
IMGUI_API void SameLine(float offset_from_start_x=0.0f, float spacing=-1.0f)
Definition: imgui.cpp:7147
BlamImGuiWindow
Class representing an ImGUI window.
Definition: imgui.h:31
ImVec2
Definition: imgui.h:179
Blam::UI::ImGUI::Widgets::ShowHelpMarker
BLAM void ShowHelpMarker(const char *desc)
Shows a help indicator.
Definition: widgets.cpp:7
ImGui::Begin
IMGUI_API bool Begin(const char *name, bool *p_open=NULL, ImGuiWindowFlags flags=0)
Definition: imgui.cpp:5397
ImGui::Text
IMGUI_API void Text(const char *fmt,...) IM_FMTARGS(1)
Definition: imgui_widgets.cpp:238
IM_ARRAYSIZE
#define IM_ARRAYSIZE(_ARR)
Definition: imgui.h:75
BlamImGuiWindow_IPTest::Draw
void Draw()
Draws the window.
Definition: ip_test.hpp:22
ImGuiWindowFlags_AlwaysAutoResize
@ ImGuiWindowFlags_AlwaysAutoResize
Definition: imgui.h:720
imgui.h
BlamImGuiWindow_IPTest
Legacy IP test dialog.
Definition: ip_test.hpp:15
ImGui::Separator
IMGUI_API void Separator()
Definition: imgui_widgets.cpp:1284
ImGui::Button
IMGUI_API bool Button(const char *label, const ImVec2 &size=ImVec2(0, 0))
Definition: imgui_widgets.cpp:644