LeviLamina
Loading...
Searching...
No Matches
NetherNetServerLocator.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/core/utility/NonOwnerPointer.h"
7#include "mc/network/StubServerLocator.h"
8#include "mc/platform/Result.h"
9#include "mc/platform/threading/UniqueLock.h"
10#include "mc/world/level/GameType.h"
11
12// auto generated forward declare list
13// clang-format off
14class AppPlatform;
15class BinaryStream;
18struct PortPair;
19namespace Bedrock::Threading { class Mutex; }
20namespace NetherNet { struct NetworkID; }
21// clang-format on
22
24public:
25 // NetherNetServerLocator inner types declare
26 // clang-format off
27 struct ServerData;
28 // clang-format on
29
30 // NetherNetServerLocator inner types define
31 struct ServerData {
32 public:
33 // member variables
34 // NOLINTBEGIN
44 // NOLINTEND
45
46 public:
47 // prevent constructor by default
48 ServerData& operator=(ServerData const&);
49 ServerData(ServerData const&);
50 ServerData();
51
52 public:
53 // member functions
54 // NOLINTBEGIN
55 MCNAPI ::Bedrock::Result<void> read(::ReadOnlyBinaryStream& stream);
56
57 MCNAPI void write(::BinaryStream& stream) const;
58
59 MCNAPI ~ServerData();
60 // NOLINTEND
61
62 public:
63 // destructor thunk
64 // NOLINTBEGIN
65 MCNAPI void $dtor();
66 // NOLINTEND
67 };
68
69public:
70 // member variables
71 // NOLINTBEGIN
80 // NOLINTEND
81
82public:
83 // prevent constructor by default
87
88public:
89 // virtual functions
90 // NOLINTBEGIN
91 // vIndex: 0
92 virtual ~NetherNetServerLocator() /*override*/;
93
94 // vIndex: 3
95 virtual void startAnnouncingServer(
96 ::std::string const& playerName,
97 ::std::string const& worldName,
99 ::GameType gameType,
100 int numPlayers,
101 int maxNumPlayers,
102 bool isJoinableThroughServerScreen,
103 bool isEditorWorld,
104 bool isHardcore
105 ) /*override*/;
106
107 // vIndex: 4
108 virtual void stopAnnouncingServer(::Bedrock::NonOwnerPointer<::AppPlatform> appPlatform) /*override*/;
109
110 // vIndex: 5
111 virtual void startServerDiscovery(::PortPair ports) /*override*/;
112
113 // vIndex: 6
114 virtual void stopServerDiscovery() /*override*/;
115
116 // vIndex: 9
117 virtual ::std::vector<::PingedCompatibleServer> getServerList() const /*override*/;
118
119 // vIndex: 10
120 virtual void clearServerList() /*override*/;
121
122 // vIndex: 11
123 virtual void update() /*override*/;
124 // NOLINTEND
125
126public:
127 // member functions
128 // NOLINTBEGIN
130
131 MCNAPI void _onDiscoveryResponse(::NetherNet::NetworkID const& networkID, ::gsl::span<char const> responseData);
132
133 MCNAPI void _setDiscoveryRequestCallback(bool enable);
134
135 MCNAPI void _setDiscoveryResponseCallback(bool enable);
136
137 MCNAPI void _setIsAnnouncing(bool isAnnouncing);
138
139 MCNAPI void _setIsDiscovering(bool isDiscovering);
140 // NOLINTEND
141
142public:
143 // static functions
144 // NOLINTBEGIN
145 MCNAPI static ::PingedCompatibleServer
146 _transformFrom(::NetherNet::NetworkID const& networkID, ::NetherNetServerLocator::ServerData&& serverData);
147 // NOLINTEND
148
149public:
150 // destructor thunk
151 // NOLINTBEGIN
152 MCNAPI void $dtor();
153 // NOLINTEND
154
155public:
156 // virtual function thunks
157 // NOLINTBEGIN
159 ::std::string const& playerName,
160 ::std::string const& worldName,
161 ::Bedrock::NonOwnerPointer<::AppPlatform> appPlatform,
162 ::GameType gameType,
163 int numPlayers,
164 int maxNumPlayers,
165 bool isJoinableThroughServerScreen,
166 bool isEditorWorld,
167 bool isHardcore
168 );
169
170 MCNAPI void $stopAnnouncingServer(::Bedrock::NonOwnerPointer<::AppPlatform> appPlatform);
171
172 MCNAPI void $startServerDiscovery(::PortPair ports);
173
174 MCNAPI void $stopServerDiscovery();
175
176 MCNAPI ::std::vector<::PingedCompatibleServer> $getServerList() const;
177
178 MCNAPI void $clearServerList();
179
180 MCNAPI void $update();
181 // NOLINTEND
182
183public:
184 // vftables
185 // NOLINTBEGIN
186 MCNAPI static void** $vftable();
187 // NOLINTEND
188};
Definition AppPlatform.h:50
Definition NonOwnerPointer.h:9
Definition BinaryStream.h:10
Definition NetherNetServerLocator.h:23
MCAPI void $startAnnouncingServer(::std::string const &playerName, ::std::string const &worldName, ::Bedrock::NonOwnerPointer<::AppPlatform > appPlatform, ::GameType gameType, int numPlayers, int maxNumPlayers, bool isJoinableThroughServerScreen, bool isEditorWorld, bool isHardcore)
MCAPI void _onDiscoveryResponse(::NetherNet::NetworkID const &networkID, ::gsl::span< char const > responseData)
MCAPI void $startServerDiscovery(::PortPair ports)
MCAPI void _setIsDiscovering(bool isDiscovering)
MCAPI void _setIsAnnouncing(bool isAnnouncing)
static MCAPI void ** $vftable()
MCAPI void $clearServerList()
MCAPI void _setDiscoveryRequestCallback(bool enable)
static MCAPI ::PingedCompatibleServer _transformFrom(::NetherNet::NetworkID const &networkID, ::NetherNetServerLocator::ServerData &&serverData)
MCAPI void _cacheDiscoveryResponseData()
MCAPI void $stopServerDiscovery()
MCAPI ::std::vector<::PingedCompatibleServer > $getServerList() const
MCAPI void _setDiscoveryResponseCallback(bool enable)
MCAPI void $stopAnnouncingServer(::Bedrock::NonOwnerPointer<::AppPlatform > appPlatform)
Definition ReadOnlyBinaryStream.h:8
Definition StubServerLocator.h:19
STL namespace.
Definition NetherNetServerLocator.h:31
MCAPI void write(::BinaryStream &stream) const
MCAPI ::Bedrock::Result< void > read(::ReadOnlyBinaryStream &stream)
Definition PingedCompatibleServer.h:5
Definition PortPair.h:5
Definition Alias.h:14