DayZ 1.30
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено
ServerBrowserTab.c
См. документацию.
9
10enum SelectedPanel
11{
15 DETAILS
16}
17
18enum ServerBrowserRightAreaView
19{
20 FILTERS,
21 DETAILS
22}
23
25{
26 protected Widget m_Root;
27 protected ScrollWidget m_ServerListScroller;
28 protected SpacerBaseWidget m_ServerList;
29
30 //protected ref array<ref GetServersResultRow> m_Entries;
31
34
35 protected ref ServerBrowserFilterContainer m_Filters;
36
37 protected ServerBrowserMenuNew m_Menu;
38 protected ServerBrowserEntry m_SelectedServer;
39
40 protected TabType m_TabType;
43
44 protected SelectedPanel m_SelectedPanel;
45 protected bool m_Initialized;
46 protected bool m_BegunLoading;
47 protected bool m_Loading;
48 protected int m_TotalServers; // UNUSED
49 protected int m_TotalLoadedServers;
50 protected int m_LastLoadedPage;
51 protected int m_TotalPages;
52 protected bool m_LoadingFinished;
53 protected int m_CurrentPageNum;
54
55 protected string m_CurrentSelectedServer;
56 protected int m_CurrentLoadedPage;
58
63 protected Widget m_HostSort;
64 protected Widget m_TimeSort;
67 protected Widget m_PingSort;
68 protected Widget m_MapSort;
72 protected ButtonWidget m_BtnPagePrev;
73 protected ButtonWidget m_BtnPageNext;
74
77 protected ref set<string> m_OnlineFavServers;
78
82 protected ButtonWidget m_BtnShowDetails;
83
85 protected ButtonWidget m_BtnShowFilters;
86
87 protected ref ServerBrowserDetailsContainer m_Details;
88
89#ifdef DIAG_DEVELOPER
90 protected ref GetServersResult m_DummyServers;
91 protected static bool m_DummyServersEnabled;
92#endif
93
94 void ServerBrowserTab(Widget parent, ServerBrowserMenuNew menu, TabType type)
95 {
96 Construct(parent, menu, type);
97 m_OnlineFavServers = new set<string>();
98 g_Game.GetContentDLCService().Subscribe(OnDLCChange);
99 }
100
101 protected void Construct(Widget parent, ServerBrowserMenuNew menu, TabType type)
102 {
106 m_LoadingText = TextWidget.Cast(m_Root.FindAnyWidget("loading_servers_info"));
107 }
108
110 {
111 if ( m_Filters )
112 m_Filters.SaveFilters();
113
114 if (m_Root)
115 delete m_Root;
116
117 if (g_Game.GetContentDLCService())
118 g_Game.GetContentDLCService().Unsubscribe(OnDLCChange);
119
120 #ifdef DIAG_DEVELOPER
121 PluginDiagMenuClient.GetSBDummyServersInvoker().Remove(OnDummyServersEnabledChanged);
122 #endif
123 }
124
125 ServerBrowserMenuNew GetRootMenu()
126 {
127 return m_Menu;
128 }
129
131 {
132 return m_LoadingFinished;
133 }
134
136 {
137 array<ServerBrowserEntry> serverEntries = m_EntryWidgets.GetValueArray();
138 foreach (ServerBrowserEntry entry : serverEntries)
139 {
140 entry.RefreshDLCIcon();
141 }
142 }
143
144 void ScrollToEntry( ServerBrowserEntry entry )
145 {
146 if ( entry )
147 {
148 float x, y;
149 float x_s, y_s;
150 float x_l, y_l;
151
152 Widget root = entry.GetRoot();
153 Widget first_child = root.GetParent().GetChildren();
154 Widget last_child = first_child;
155 while ( last_child )
156 {
157 if ( last_child.GetSibling() )
158 last_child = last_child.GetSibling();
159 else
160 break;
161 }
162
163 root.GetParent().Update();
164 root.Update();
165
166 m_ServerListScroller.GetScreenPos( x, y );
167 m_ServerListScroller.GetScreenSize( x_s, y_s );
168
169 float bottom_pos = y + y_s;
170
171 root.GetScreenPos( x_l, y_l );
172 root.GetScreenSize( x_s, y_s );
173
174 if ( root == first_child )
175 {
176 m_ServerListScroller.VScrollToPos01( 0 );
177 }
178 else if ( root == last_child )
179 {
180 m_ServerListScroller.VScrollToPos01( 1 );
181 }
182 else if ( y_l + y_s >= bottom_pos )
183 {
184 m_ServerListScroller.VScrollToPos( m_ServerListScroller.GetVScrollPos() + y_s );
185 }
186 else if ( y_l <= y )
187 {
188 m_ServerListScroller.VScrollToPos( m_ServerListScroller.GetVScrollPos() - y_s );
189 }
190 }
191 }
192
203
205 {
206 m_SelectedPanel = SelectedPanel.FILTERS;
207 m_Menu.FilterFocus(false);
208 }
209
211 {
212 m_SelectedPanel = SelectedPanel.FILTERS;
213 m_Menu.FilterFocus(true);
214 }
215
217 {
218 m_SelectedPanel = SelectedPanel.DETAILS;
219 m_Menu.DetailsFocus(false);
220 }
221
223 {
224 m_SelectedPanel = SelectedPanel.DETAILS;
225 m_Menu.DetailsFocus(true);
226 }
227
229
230 void ServerListFocus(bool focus, bool favorite)
231 {
232 if (!m_Menu)
233 return;
234
235 m_Menu.ServerListFocus(focus, favorite);
236 }
237
238 override bool OnFocus(Widget w, int x, int y)
239 {
240 if (IsFocusable(w))
241 {
242 if (w == m_FilterSearchTextBox)
243 {
245 return false;
246 }
247 else
248 {
250 }
251
252 #ifdef PLATFORM_CONSOLE
253 string aButtonLabel;
254 if (w == m_RefreshList || w == m_ApplyFilter || w == m_ResetFilters)
255 {
256 #ifdef PLATFORM_PS4
257 aButtonLabel = "#ps4_ingame_menu_select";
258 #else
259 aButtonLabel = "#layout_xbox_ingame_menu_select";
260 #endif
261 m_Menu.UpdateAButtonLabel(aButtonLabel);
262 }
263 else if (w != m_BtnShowFilters && w != m_BtnShowDetails)
264 {
265 aButtonLabel = "#dialog_change";
266 m_Menu.UpdateAButtonLabel(aButtonLabel);
267 }
268 else
269 {
270 m_Menu.ShowAButton(false);
271 }
272 #endif
273
274 return true;
275 }
276
277 return false;
278 }
279
280 override bool OnFocusLost(Widget w, int x, int y)
281 {
282 if (IsFocusable(w))
283 {
284 if (w == m_FilterSearchTextBox)
285 {
287 return true;
288 }
289 else
290 {
291 ColorNormal(w);
292 }
293 return true;
294 }
295 return false;
296 }
297
298 override bool OnMouseEnter(Widget w, int x, int y)
299 {
300 if (IsFocusable(w))
301 {
303 if (w == m_FilterSearchText)
304 {
306 return true;
307 }
308 return true;
309 }
310 return false;
311 }
312
313 override bool OnMouseLeave(Widget w, Widget enterW, int x, int y)
314 {
315 if (IsFocusable(w))
316 {
317 if (enterW == m_FilterSearchText || enterW == m_FilterSearchTextBox)
318 {
319 }
320 else
321 {
322 ColorNormal(w);
323 }
324 return true;
325 }
326 return false;
327 }
328
330 {
331 if (w)
332 {
333 return (w == m_ApplyFilter || w == m_RefreshList || w == m_ResetFilters || w == m_FilterSearchText || w == m_FilterSearchTextBox || w == m_BtnShowDetails || w == m_BtnShowFilters);
334 }
335 return false;
336 }
337
338 // Unused?!
340
341 void PressA();
342
343 void PressX()
344 {
345 if ( m_Menu.GetServersLoadingTab() == TabType.NONE )
346 RefreshList();
347 }
348
349 void PressY();
353 void Left();
354 void LeftHold();
356 void Right();
357 void RightHold();
359 void Up();
360 void Down();
362
363 void OnLoadServerModsAsync(string server_id, array<string> mods)
364 {
365 m_EntryMods.Set( server_id, mods );
366 }
367
369 {
370 Widget focused = GetFocus();
371 if ( !focused )
372 return;
373 Widget sibling = focused.GetSibling();
374 if ( !sibling )
375 return;
376
377 if ( focused.GetName() == "server_browser_list_entry_root" )
378 {
379 if ( sibling )
380 SetFocus( focused.GetSibling() );
381 else
382 SetFocus( focused.GetParent().GetSibling().GetChildren() );
383 }
384 }
385
387 {
388 Widget focused = GetFocus();
389 if ( focused && focused.GetName() == "server_browser_list_entry_root" )
390 {
391 Widget sibling = focused.GetParent().GetChildren();
392 if ( focused == sibling )
393 return;
394
395 while ( sibling )
396 {
397 if ( sibling && sibling.GetSibling() == focused )
398 {
399 SetFocus( sibling );
400 }
401 else
402 {
403 sibling = sibling.GetSibling();
404 }
405 }
406 }
407 }
408
409 // Unused?!
411
412 // Unused?!
414
415 void SetCurrentPage(int page_num)
416 {
417 m_CurrentPageNum = page_num;
418 }
419
421 {
422 return m_CurrentPageNum;
423 }
424
426 {
428 }
429
431 {
432 m_Filters.ResetFilters();
433 }
434
436
438 {
439 m_Menu.AddFavoritesToFilter( input );
440 }
441
443 {
444 m_Menu.SetServersLoadingTab( m_TabType );
445
446 m_LoadingFinished = false;
447 m_Initialized = true;
448 m_BegunLoading = false;
450 m_TotalPages = -1;
451 m_TotalServers = 0;
454
455 m_Menu.DeselectCurrentServer();
456
457 m_EntryWidgets.Clear();
458
459 #ifndef PLATFORM_WINDOWS // XBOX OR PS
460 m_CurrentFilterInput = m_Filters.GetFilterOptionsConsoles();
463 m_CurrentFilterInput.m_SortOrder = m_SortOrder;
464 #else // PLATFORM_WINDOWS
465 m_CurrentFilterInput = m_Filters.GetFilterOptionsPC();
466 #ifdef PLATFORM_CONSOLE // PC client with -XBOX flag
468 #else
469 m_CurrentFilterInput.m_Page = 0;
470 #endif
471 #endif
472
473 m_Loading = true;
474 switch ( m_TabType )
475 {
476 case TabType.OFFICIAL:
477 {
478 m_CurrentFilterInput.SetOfficialFilter( true );
480 break;
481 }
482 case TabType.COMMUNITY:
483 {
484 m_CurrentFilterInput.SetOfficialFilter( false );
486 break;
487 }
488 case TabType.LAN:
489 {
490 m_CurrentFilterInput.SetLAN();
492 break;
493 }
494 }
495 }
496
505
506 void SelectServer(ServerBrowserEntry server)
507 {
508 #ifdef PLATFORM_CONSOLE
509 ScrollToEntry(server);
510 #endif
511
512 m_SelectedServer = server;
513
514 m_CurrentSelectedServer = m_SelectedServer.GetServerData().m_Id;
515
516 if (!m_Menu)
517 return;
518
519 m_Menu.SelectServer(server);
520 }
521
522 void OnLoadServersAsyncPC(GetServersResult result_list, EBiosError error, string response);
523
524 void OnLoadServersAsyncConsole(GetServersResult result_list, EBiosError error, string response);
525
527
528 void SetSort( ESortType type, ESortOrder order )
529 {
530 m_SortOrder = order;
531 m_SortType = type;
532 }
533
534 bool IsPingInRange( int ping, string max_ping )
535 {
536 int max = max_ping.Substring( 1, max_ping.Length() - 1 ).ToInt();
537
538 if ( ping < max )
539 return true;
540 return false;
541 }
542
544 {
545 if ( !m_Menu || m_Menu.GetServersLoadingTab() != m_TabType )
546 {
547 return false;
548 }
549
550 if ( m_Filters.m_PingFilter.IsSet() )
551 {
552 if ( !IsPingInRange( result.m_Ping, m_Filters.m_PingFilter.GetStringValue() ) )
553 {
554 return false;
555 }
556 }
557
558 return true;
559 }
560
561 // Adds extra servers to the END of the list
562 protected void LoadExtraEntries(int index);
563
564 void Connect( ServerBrowserEntry server )
565 {
566 if ( !m_Menu )
567 return;
568
569 if ( m_Menu.GetServersLoadingTab() != TabType.NONE )
570 return;
571
572 m_SelectedServer = server;
573 m_Menu.Connect( server );
574 }
575
577 {
578 switch ( m_SortType )
579 {
580 case ESortType.HOST:
581 {
582 return "name";
583 }
584 case ESortType.TIME:
585 {
586 return "name";
587 }
588 case ESortType.POPULATION:
589 {
590 return "currentNumberPlayers";
591 }
592 case ESortType.SLOTS:
593 {
594 return "freeSlots";
595 }
596 case ESortType.PING:
597 {
598 return "name";
599 }
600 }
601 return "";
602 }
603
605 {
606 return -1;
607 }
608
609 void Unfavorite(string uid)
610 {
611 ServerBrowserEntry entry;
612 if (m_EntryWidgets.Find(uid, entry))
613 {
614 entry.SetFavorite(false);
615
616 // If this is an entry in favorites tab, hide it
617 if (m_TabType == TabType.FAVORITE)
618 {
619 entry.Show(false);
620 }
621 }
622 }
623
625 {
626 return m_TabType;
627 }
628
630 {
631 w.ClearFlags( WidgetFlags.IGNOREPOINTER );
632 ColorNormal(w);
633 }
634
636 {
637 w.SetFlags( WidgetFlags.IGNOREPOINTER );
638 ColorDisable(w);
639 }
640
641 //Coloring functions (Until WidgetStyles are useful)
643 {
644 if ( w.IsInherited( ButtonWidget ) )
645 {
646 ButtonWidget button = ButtonWidget.Cast( w );
647 button.SetTextColor( ARGB( 255, 200, 0, 0 ) );
648 }
649
650 w.SetColor( ARGB( 255, 0, 0, 0) );
651
652 TextWidget text1 = TextWidget.Cast(w.FindAnyWidget( w.GetName() + "_text" ) );
653 TextWidget text2 = TextWidget.Cast(w.FindAnyWidget( w.GetName() + "_label" ) );
654 TextWidget text3 = TextWidget.Cast(w.FindAnyWidget( w.GetName() + "_text_1" ) );
655 ImageWidget image = ImageWidget.Cast( w.FindAnyWidget( w.GetName() + "_image" ) );
656 Widget option = Widget.Cast( w.FindAnyWidget( w.GetName() + "_option_wrapper" ) );
657 Widget option_label = w.FindAnyWidget( "option_label" );
658
659 if ( text1 )
660 {
661 text1.SetColor( ARGB( 255, 255, 0, 0 ) );
662 }
663
664 if ( text2 )
665 {
666 text2.SetColor( ARGB( 255, 255, 0, 0 ) );
667 }
668
669 if ( text3 )
670 {
671 text3.SetColor( ARGB( 255, 255, 0, 0 ) );
672 w.SetAlpha(1);
673 }
674
675 if ( image )
676 {
677 image.SetColor( ARGB( 255, 200, 0, 0 ) );
678 }
679
680 if ( option )
681 {
682 option.SetColor( ARGB( 255, 255, 0, 0 ) );
683 }
684
685 if ( option_label )
686 {
687 option_label.SetColor( ARGB( 255, 255, 0, 0 ) );
688 }
689 }
690
692 {
693 if ( (w.GetFlags() & WidgetFlags.IGNOREPOINTER) == WidgetFlags.IGNOREPOINTER )
694 {
695 return;
696 }
697
698 if ( w.IsInherited( ButtonWidget ) )
699 {
700 ButtonWidget button = ButtonWidget.Cast( w );
701 button.SetTextColor( ARGB( 255, 255, 255, 255 ) );
702 }
703
704 TextWidget text1 = TextWidget.Cast(w.FindAnyWidget( w.GetName() + "_text" ) );
705 TextWidget text2 = TextWidget.Cast(w.FindAnyWidget( w.GetName() + "_text_1" ) );
706 TextWidget text3 = TextWidget.Cast(w.FindAnyWidget( w.GetName() + "_label" ) );
707 ImageWidget image = ImageWidget.Cast( w.FindAnyWidget( w.GetName() + "_image" ) );
708 Widget option = w.FindAnyWidget( w.GetName() + "_option_wrapper" );
709 Widget option_label = w.FindAnyWidget( "option_label" );
710
711 if ( text1 )
712 {
713 text1.SetColor( ARGB( 255, 255, 255, 255 ) );
714 }
715
716 if ( text2 )
717 {
718 text2.SetColor( ARGB( 255, 255, 255, 255 ) );
719 }
720
721 if ( text3 )
722 {
723 text3.SetColor( ARGB( 255, 255, 255, 255 ) );
724 w.SetAlpha(0);
725 }
726
727 if ( image )
728 {
729 image.SetColor( ARGB( 255, 255, 255, 255 ) );
730 }
731
732 if ( option )
733 {
734 option.SetColor( ARGB( 150, 255, 255, 255 ) );
735 }
736
737 if ( option_label )
738 {
739 option_label.SetColor( ARGB( 255, 255, 255, 255 ) );
740 }
741 }
742
744 {
745 #ifdef PLATFORM_WINDOWS
746 SetFocus( null );
747 #endif
748
749 if ( w )
750 {
751 ButtonWidget button = ButtonWidget.Cast( w );
752 if ( button )
753 {
754 button.SetTextColor( ColorManager.COLOR_DISABLED_TEXT );
755 }
756 }
757 }
758
760 {
761 switch (m_SelectedPanel)
762 {
763 case SelectedPanel.BROWSER:
764 {
765 if (m_DetailsRoot.IsVisible())
766 {
767 SwitchToFilters(false);
768 }
769 else if (m_FilterRoot.IsVisible())
770 {
771 SwitchToDetails(false);
772 }
773 break;
774 }
775 case SelectedPanel.DETAILS:
776 {
778 break;
779 }
780 case SelectedPanel.FILTERS:
781 {
783 break;
784 }
785 }
786 }
787
788 // Here for overrides in the classes that inherit from class ServerBrowserTab
789 void SwitchToDetails(bool focus = true);
790 void SwitchToFilters(bool focus = true);
791
792 void SetServerDetails(GetServersResultRow server_info, bool online)
793 {
794 m_Details.SetDetails(server_info, online);
795 }
796
798 {
799 m_DetailsRoot.Show(true);
800 m_BtnShowDetails.Show(false);
801 m_Root.FindAnyWidget("spacer1").Show(m_TabType != TabType.FAVORITE && m_TabType != TabType.LAN);
802 m_RightAreaHeaderText.SetText("#STR_server_browser_menu_server_details");
803 }
804
806 {
807 return m_FilterRoot;
808 }
809
811 {
812 return m_DetailsRoot;
813 }
814
815 ServerBrowserEntry GetSelectedServer()
816 {
817 return m_SelectedServer;
818 }
819
820#ifdef DIAG_DEVELOPER
821 protected void InitDummyServers()
822 {
823 m_DummyServersEnabled = DiagMenu.GetBool(DiagMenuIDs.SERVER_BROWSER_DUMMY_SERVERS);
824 PluginDiagMenuClient.GetSBDummyServersInvoker().Insert(OnDummyServersEnabledChanged);
825
826 m_DummyServers = new GetServersResult();
827 m_DummyServers.m_NumServers = 100;
828
829 int serversVisibleCount = GetServersVisibleCount();
830 m_DummyServers.m_Pages = (m_DummyServers.m_NumServers + serversVisibleCount - 1) / serversVisibleCount;
831 if (m_DummyServers.m_Pages < 1)
832 {
833 m_DummyServers.m_Pages = 1;
834 }
835 m_DummyServers.m_Page = 1;
836 m_DummyServers.m_Results = new GetServersResultRowArray();
837
838 TStringArray mapNames = {"chernarusplus", "enoch", "sakhal"};
839 for (int i = 0; i < m_DummyServers.m_NumServers; ++i)
840 {
841 GetServersResultRow row = new GetServersResultRow();
842
843 string fakeIP = "127.0.0." + ((i % 250) + 1).ToString();
844 int fakePort = 2302 + (i % 10);
845 row.m_Name = string.Format("[TEST] Dummy Server %1", i + 1);
846 row.m_Id = fakeIP + ":" + fakePort.ToString();
847 #ifdef PLATFORM_CONSOLE
848 row.m_HostIp = fakeIP;
849 #endif
850 row.m_HostPort = fakePort;
851 row.m_Favorite = false;
852 row.m_Description = string.Format("Dummy server %1 description. Do not favorite me!", i + 1);
853 row.m_MapNameToRun = mapNames.GetRandomElement();
854 row.m_MaxPlayers = 60;
855 row.m_CurrentNumberPlayers = i % 60;
856 row.m_PlayersInQueue = i % 4;
857 row.m_Ping = 20 + (i % 180);
858 row.m_TimeOfDay = string.Format("%1:%2", 5 + (i % 18), i % 60);
859
860 m_DummyServers.m_Results.Insert(row);
861 }
862 }
863
864 protected void OnDummyServersEnabledChanged()
865 {
866 m_DummyServersEnabled = DiagMenu.GetBool(DiagMenuIDs.SERVER_BROWSER_DUMMY_SERVERS);
867
869 if (!m_Root || !m_Root.IsVisible())
870 return;
871 }
872
873 protected int GetServersVisibleCount()
874 {
875 return 0;
876 }
877
878 protected bool PassLocalFilters(GetServersResultRow result)
879 {
881 if (!PassFilter(result))
882 {
883 return false;
884 }
885
886 if (!m_Filters)
887 {
888 return true;
889 }
890
892 string searchName = m_Filters.GetSearchByNameFilterText();
893 if (searchName != "")
894 {
895 string serverName = result.m_Name;
896 serverName.ToLower();
897
898 if (serverName.IndexOf(searchName) == -1)
899 {
900 return false;
901 }
902 }
903
905 #ifdef PLATFORM_WINDOWS
906 string searchIP = m_Filters.GetSearchByIPFilterText();
907 if (searchIP != "")
908 {
909 string hostIp = result.m_HostIp;
910 string ipPort = result.GetIpPort();
911
912 hostIp.ToLower();
913 ipPort.ToLower();
914
915 if (hostIp.IndexOf(searchIP) == -1 && ipPort.IndexOf(searchIP) == -1)
916 {
917 return false;
918 }
919 }
920 #endif
921
923 string mapFilter = m_Filters.GetMapFilterInternalName();
924 if (mapFilter != "")
925 {
926 string serverMap = result.m_MapNameToRun;
927 serverMap.ToLower();
928
929 if (serverMap != mapFilter)
930 {
931 return false;
932 }
933 }
934
935 return true;
936 }
937#endif
938}
EBiosError
Possible Error codes for bios API. This is the list of errors that can be returned from bios API....
Определения BIOSErrorModule.c:7
ESortOrder
Определения BiosLobbyService.c:46
ESortType
Определения BiosLobbyService.c:33
@ FAVORITE
Определения BiosLobbyService.c:39
array< ref GetServersResultRow > GetServersResultRowArray
Определения BiosLobbyService.c:332
map
Определения ControlsXboxNew.c:4
DayZGame g_Game
Определения DayZGame.c:4074
DiagMenuIDs
Определения EDiagMenuIDs.c:2
proto string ToString()
Icon x
Icon y
void LoadExtraEntries(int index)
void ServerBrowserTab(Widget parent, ServerBrowserMenuNew menu, TabType type)
Определения ServerBrowserTab.c:94
ref ServerBrowserFilterContainer m_Filters
Определения ServerBrowserTab.c:35
void GetPrevFilter()
void OnDLCChange()
Определения ServerBrowserTab.c:135
ref map< ESortType, ref array< ref GetServersResultRow > > m_EntriesSorted
Определения ServerBrowserTab.c:75
void OnDetailsFocusLost(Widget w)
Определения ServerBrowserTab.c:216
TabType GetTabType()
Определения ServerBrowserTab.c:624
TabType m_TabType
Определения ServerBrowserTab.c:40
Widget m_FilterSearchText
Определения ServerBrowserTab.c:69
void SelectServer(ServerBrowserEntry server)
Определения ServerBrowserTab.c:506
Widget m_FiltersChanged
Определения ServerBrowserTab.c:62
Widget m_SlotsSort
Определения ServerBrowserTab.c:66
void GetNextPage()
Определения ServerBrowserTab.c:497
TextWidget m_RightAreaHeaderText
Определения ServerBrowserTab.c:79
bool m_LoadingFinished
Определения ServerBrowserTab.c:52
ServerBrowserEntry m_SelectedServer
Определения ServerBrowserTab.c:38
void GetNextEntry()
Определения ServerBrowserTab.c:368
enum TabType BROWSER
int m_CurrentLoadedPage
Определения ServerBrowserTab.c:56
void ButtonDisable(Widget w)
Определения ServerBrowserTab.c:635
ref GetServersInput m_CurrentFilterInput
Определения ServerBrowserTab.c:57
void SwitchRightAreaView()
Определения ServerBrowserTab.c:759
void SetPanelFocus()
void ServerListFocus(bool focus, bool favorite)
Определения ServerBrowserTab.c:230
ButtonWidget m_BtnPageNext
Определения ServerBrowserTab.c:73
ref map< ESortType, ESortOrder > m_SortInverted
Определения ServerBrowserTab.c:76
bool IsPingInRange(int ping, string max_ping)
Определения ServerBrowserTab.c:534
ButtonWidget m_BtnShowFilters
Определения ServerBrowserTab.c:85
ref map< string, ref ServerBrowserEntry > m_EntryWidgets
Определения ServerBrowserTab.c:32
int m_TotalPages
Определения ServerBrowserTab.c:51
bool GetIsServerLoadingFinished()
Определения ServerBrowserTab.c:130
void ScrollToEntry(ServerBrowserEntry entry)
Определения ServerBrowserTab.c:144
bool m_BegunLoading
Определения ServerBrowserTab.c:46
void Connect(ServerBrowserEntry server)
Определения ServerBrowserTab.c:564
enum TabType FILTERS
TabType
Определения ServerBrowserTab.c:2
@ COMMUNITY
Определения ServerBrowserTab.c:4
@ LAN
Определения ServerBrowserTab.c:5
@ OFFICIAL
Определения ServerBrowserTab.c:3
ScrollWidget m_ServerListScroller
Определения ServerBrowserTab.c:27
Widget m_PingSort
Определения ServerBrowserTab.c:67
int m_TotalLoadedServers
Определения ServerBrowserTab.c:49
string m_CurrentSelectedServer
Определения ServerBrowserTab.c:55
string GetSortOption()
Определения ServerBrowserTab.c:576
Widget m_ApplyFilter
Определения ServerBrowserTab.c:59
void GetPrevEntry()
Определения ServerBrowserTab.c:386
ServerBrowserMenuNew m_Menu
Определения ServerBrowserTab.c:37
ref map< string, ref array< string > > m_EntryMods
Определения ServerBrowserTab.c:33
void Down()
bool m_Loading
Определения ServerBrowserTab.c:47
SelectedPanel m_SelectedPanel
Определения ServerBrowserTab.c:44
int m_LastLoadedPage
Определения ServerBrowserTab.c:50
ESortType m_SortType
Определения ServerBrowserTab.c:41
ServerBrowserEntry GetSelectedServer()
Определения ServerBrowserTab.c:815
void GetNextFilter()
TextWidget m_LoadingText
Определения ServerBrowserTab.c:71
void Up()
Widget m_PopulationSort
Определения ServerBrowserTab.c:65
Widget m_MapSort
Определения ServerBrowserTab.c:68
Widget m_HostSort
Определения ServerBrowserTab.c:63
void Unfavorite(string uid)
Определения ServerBrowserTab.c:609
ButtonWidget m_BtnPagePrev
Определения ServerBrowserTab.c:72
void ButtonEnable(Widget w)
Определения ServerBrowserTab.c:629
ESortOrder m_SortOrder
Определения ServerBrowserTab.c:42
SpacerBaseWidget m_ServerList
Определения ServerBrowserTab.c:28
int m_TotalServers
Определения ServerBrowserTab.c:48
int m_CurrentPageNum
Определения ServerBrowserTab.c:53
bool IsNotInitialized()
Определения ServerBrowserTab.c:425
void OnDetailsFocus(Widget w)
Определения ServerBrowserTab.c:222
void AddFavoritesToFilter(GetServersInput input)
Определения ServerBrowserTab.c:437
void SetServerDetails(GetServersResultRow server_info, bool online)
Определения ServerBrowserTab.c:792
Widget GetFilterRoot()
Определения ServerBrowserTab.c:805
override bool OnFocusLost(Widget w, int x, int y)
Определения ServerBrowserTab.c:280
int GetCurrentPage()
Определения ServerBrowserTab.c:420
Widget m_FilterSearchTextBox
Определения ServerBrowserTab.c:70
ref ServerBrowserDetailsContainer m_Details
Определения ServerBrowserTab.c:87
Widget m_FilterRoot
Определения ServerBrowserTab.c:80
Widget m_ResetFilters
Определения ServerBrowserTab.c:61
Widget m_DetailsRoot
Определения ServerBrowserTab.c:84
Widget m_RefreshList
Определения ServerBrowserTab.c:60
override bool OnFocus(Widget w, int x, int y)
Определения ServerBrowserTab.c:238
Widget GetDetailsRoot()
Определения ServerBrowserTab.c:810
Widget m_TimeSort
Определения ServerBrowserTab.c:64
Widget m_FilterContent
Определения ServerBrowserTab.c:81
void ~ServerBrowserTab()
Определения ServerBrowserTab.c:109
ref set< string > m_OnlineFavServers
Определения ServerBrowserTab.c:77
void SetCurrentPage(int page_num)
Определения ServerBrowserTab.c:415
ButtonWidget m_BtnShowDetails
Определения ServerBrowserTab.c:82
ServerBrowserMenuNew GetRootMenu()
Определения ServerBrowserTab.c:125
Widget m_Root
Определения SizeToChild.c:91
bool m_Initialized
Определения UiHintPanel.c:317
static int COLOR_DISABLED_TEXT
Определения ColorManager.c:11
Определения ColorManager.c:2
GetServersInput the input structure of the GetServers operation.
Определения BiosLobbyService.c:381
GetServersResult the output structure of the GetServers operation.
Определения BiosLobbyService.c:371
string GetIpPort()
Определения BiosLobbyService.c:222
string m_TimeOfDay
Определения BiosLobbyService.c:210
int m_MaxPlayers
Определения BiosLobbyService.c:186
string m_Description
Определения BiosLobbyService.c:175
int m_CurrentNumberPlayers
Определения BiosLobbyService.c:188
string m_Name
Определения BiosLobbyService.c:174
string m_Id
Определения BiosLobbyService.c:172
bool m_Favorite
Определения BiosLobbyService.c:220
int m_PlayersInQueue
Определения BiosLobbyService.c:189
int m_Ping
Определения BiosLobbyService.c:209
int m_HostPort
Определения BiosLobbyService.c:177
string m_HostIp
Определения BiosLobbyService.c:176
string m_MapNameToRun
Определения BiosLobbyService.c:180
GetServersResultRow the output structure of the GetServers operation that represents one game server.
Определения BiosLobbyService.c:171
static void LoadServers(notnull GetServersInput inputValues)
Определения OnlineServices.c:96
Определения OnlineServices.c:2
void Remove(EntityAI item)
Определения PluginInventoryRepair.c:152
Deprecated.
Определения EnWidgets.c:657
override void OnFilterFocus(Widget w)
Определения ServerBrowserTabConsole.c:200
override void PressThumbRight()
Определения ServerBrowserTabConsolePages.c:486
override void OnFilterFocusLost(Widget w)
Определения ServerBrowserTabConsole.c:245
override void PressSholderRight()
Определения ServerBrowserTabConsole.c:293
override bool IsFocusable(Widget w)
Определения ServerBrowserTabPc.c:1100
override void ShowServerDetails()
Определения ServerBrowserTabConsolePages.c:629
override void ColorDisable(Widget w)
Определения ServerBrowserTabConsole.c:448
override void PressA()
Определения ServerBrowserTabConsole.c:250
override void ApplyFilters()
Определения ServerBrowserTabConsole.c:238
override bool OnMouseLeave(Widget w, Widget enterW, int x, int y)
Определения ServerBrowserTabPc.c:396
override void SwitchToDetails(bool focus=true)
Определения ServerBrowserTabConsolePages.c:913
override void PressY()
Определения ServerBrowserTabConsole.c:260
override void SetSort(ESortType type, ESortOrder order)
Определения ServerBrowserTabPc.c:555
override void SwitchToFilters(bool focus=true)
Определения ServerBrowserTabConsolePages.c:924
override void ColorNormal(Widget w)
Определения ServerBrowserTabConsole.c:396
override int AddSorted(GetServersResultRow entry)
Определения ServerBrowserTabPc.c:667
override void ResetFilters()
Определения ServerBrowserTabConsole.c:231
override bool PassFilter(GetServersResultRow result)
Определения ServerBrowserTabConsolePages.c:335
override void RefreshList()
Определения ServerBrowserTabConsole.c:212
override void LeftHold()
Определения ServerBrowserTabConsolePages.c:523
override void OnLoadServersAsyncConsole(GetServersResult result_list, EBiosError error, string response)
Определения ServerBrowserTabConsole.c:72
override void UpdateServerList()
Определения ServerBrowserTabPc.c:1000
override void PressSholderLeft()
Определения ServerBrowserTabConsole.c:288
override void OnFilterChanged()
Определения ServerBrowserTabConsole.c:207
override bool OnMouseEnter(Widget w, int x, int y)
Определения ServerBrowserTabPc.c:376
override void OnPressShoulder()
Определения ServerBrowserTabConsole.c:298
override void RightRelease()
Определения ServerBrowserTabConsolePages.c:571
override void OnLoadServerModsAsync(string server_id, array< string > mods)
Определения ServerBrowserTabPc.c:1061
override void Construct(Widget parent, ServerBrowserMenuNew menu, TabType type)
Определения ServerBrowserTabConsole.c:10
override void Left()
Определения ServerBrowserTabConsolePages.c:509
override void Focus()
Определения ServerBrowserTabConsole.c:339
override void ColorHighlight(Widget w)
Определения ServerBrowserTabConsole.c:386
override void OnLoadServersAsyncPC(GetServersResult result_list, EBiosError error, string response)
Определения ServerBrowserTabPc.c:240
override void RightHold()
Определения ServerBrowserTabConsolePages.c:558
override void PressX()
Определения ServerBrowserTabConsole.c:255
override void LeftRelease()
Определения ServerBrowserTabConsolePages.c:536
override void Right()
Определения ServerBrowserTabConsolePages.c:544
Определения EnWidgets.c:220
Определения EnWidgets.c:190
Result for an object found in CGame.IsBoxCollidingGeometryProxy.
Определения Transport.c:70
class array< Class T > TStringArray
@ MENU
Определения EnSystem.c:343
@ NONE
body is not in simulation, nor in collision world
Определения SimulationState.c:15
proto native int Length()
Returns length of string.
static proto string ToString(void var, bool type=false, bool name=false, bool quotes=true)
Return string representation of variable.
proto native int ToInt()
Converts string to integer.
proto void Insert(int index, string input)
Inserts a string into the n-th index, increasing the string length by the size of the input.
proto string Substring(int start, int len)
Substring of 'str' from 'start' position 'len' number of characters.
proto native int IndexOf(string sample)
Finds 'sample' in 'str'. Returns -1 when not found.
static proto string Format(string fmt, void param1=NULL, void param2=NULL, void param3=NULL, void param4=NULL, void param5=NULL, void param6=NULL, void param7=NULL, void param8=NULL, void param9=NULL)
Gets n-th character from string.
proto int ToLower()
Changes string to lowercase. Returns length.
WidgetFlags
Определения EnWidgets.c:58
proto native Widget GetFocus()
proto native void SetFocus(Widget w)
int ARGB(int a, int r, int g, int b)
Определения proto.c:322