Skip to content
This repository has been archived by the owner on Nov 1, 2024. It is now read-only.

Commit

Permalink
update level header
Browse files Browse the repository at this point in the history
  • Loading branch information
dreamguxiang committed May 20, 2022
1 parent 05139f4 commit 42ec5a8
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 1 deletion.
13 changes: 13 additions & 0 deletions LiteLoader/Header/MC/Level.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,19 @@ class Level {
*((void**)&rv) = dlsym("?getPacketSender@Level@@UEBAPEAVPacketSender@@XZ");
return (this->*rv)();
}
inline class LevelData& getLevelData()
{
class LevelData& (Level::*rv)();
*((void**)&rv) = dlsym("?getLevelData@Level@@UEAAAEAVLevelData@@XZ");
return (this->*rv)();
}

inline class LevelData const& getLevelData() const
{
class LevelData const& (Level::*rv)() const;
*((void**)&rv) = dlsym("?getLevelData@Level@@UEBAAEBVLevelData@@XZ");
return (this->*rv)();
}
/*
* Wrappers for Muti-Vftable Class
inline void _checkUserStorage() {
Expand Down
7 changes: 6 additions & 1 deletion LiteLoader/Header/MC/ServerNetworkHandler.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,14 @@ class ServerNetworkHandler {
return _onClientAuthenticated(a0, a1);
}

inline class ServerPlayer* getServerPlayer(class NetworkIdentifier const& a0, char a1=0) {
inline class ServerPlayer* getServerPlayer(class NetworkIdentifier const& a0, char a1=0) {
return _getServerPlayer(a0, a1);
}

inline int getActiveAndInProgressPlayerCount(class mce::UUID a1)
{
return _getActiveAndInProgressPlayerCount(a1);
}

inline void handle(class NetworkIdentifier const& a0, class CommandRequestPacket const& a1) {
void (ServerNetworkHandler::*rv)(class NetworkIdentifier const&, class CommandRequestPacket const&);
Expand Down

0 comments on commit 42ec5a8

Please sign in to comment.