watermark.c 935 B

123456789101112131415161718192021222324252627
  1. class Watermark
  2. {
  3. protected Widget m_Root;
  4. protected ImageWidget m_WatermarkImage;
  5. protected TextWidget m_WatermarkLabel;
  6. protected TextWidget m_WatermarkBuild;
  7. void Watermark(Widget parent)
  8. {
  9. m_Root = GetGame().GetWorkspace().CreateWidgets("gui/layouts/day_z_hud_watermark.layout", parent);
  10. m_WatermarkImage = ImageWidget.Cast(m_Root.FindAnyWidget("WatermarkLogo"));
  11. m_WatermarkLabel = TextWidget.Cast(m_Root.FindAnyWidget("WatermarkLabel"));
  12. m_WatermarkBuild = TextWidget.Cast(m_Root.FindAnyWidget("WatermarkBuild"));
  13. #ifdef PLATFORM_CONSOLE
  14. m_WatermarkImage.LoadImageFile(0, "set:dayz_gui image:DayZLogo");
  15. m_WatermarkLabel.SetText("TESTING BUILD");
  16. #else
  17. m_WatermarkImage.LoadImageFile(0, "Gui/textures/forstline_logo_small_temp.edds");
  18. m_WatermarkLabel.SetText("WISHLIST ON STEAM");
  19. #endif
  20. string buildVersion;
  21. GetGame().GetVersion(buildVersion);
  22. m_WatermarkBuild.SetText(buildVersion);
  23. }
  24. }