Closed aabstractt closed 1 year ago
The change must be made to the registered default handler in PlayerNetworkHandlerRegistry instead. PlayStation (and I suspect other OSes) have different offset value and this would affect them.
$this->registerDefault(new ClosurePlayerNetworkHandler(static function(Closure $then) : NetworkStackLatencyEntry{
+ $timestamp = mt_rand();
+ return new NetworkStackLatencyEntry($timestamp * 1000000, $then, $timestamp);
- return new NetworkStackLatencyEntry(mt_rand() * 1000 /* TODO: remove this hack */, $then);
}));
What is the solution for this error for players playing on console? Well, I tried that one, and it didn't work!
Addressed in 363c211
What is the solution for this error for players playing on console? Well, I tried that one, and it didn't work!
Addressed in 363c211
I've highlighted this in https://github.com/Muqsit/InvMenu/issues/216#issuecomment-1635025775. At the moment, I do not have access to a PlayStation and therefore cannot test a solution. I would suggest trying the same fix for Windows 10 users to see if it works for PlayStation users as well:
protected function onEnable() : void{
if(!InvMenuHandler::isRegistered()){
InvMenuHandler::register($this);
}
+ // possible solution for playstation users:
+ $registry = InvMenuHandler::getPlayerManager()->getNetworkHandlerRegistry();
+ $registry->register(DeviceOS::PLAYSTATION, $registry->get(DeviceOS::WINDOWS_10));
}
What is the solution for this error for players playing on console? Well, I tried that one, and it didn't work!
Addressed in 363c211
I've highlighted this in #216 (comment). At the moment, I do not have access to a PlayStation and therefore cannot test a solution. I would suggest trying the same fix for Windows 10 users to see if it works for PlayStation users as well:
protected function onEnable() : void{ if(!InvMenuHandler::isRegistered()){ InvMenuHandler::register($this); } + // possible solution for playstation users: + $registry = InvMenuHandler::getPlayerManager()->getNetworkHandlerRegistry(); + $registry->register(DeviceOS::PLAYSTATION, $registry->get(DeviceOS::WINDOWS_10)); }
So, I tried multiple situations with a PS4 player.
We all love mojang weird protocol changes..
What is the solution for this error for players playing on console? Well, I tried that one, and it didn't work!
Addressed in 363c211
I've highlighted this in #216 (comment). At the moment, I do not have access to a PlayStation and therefore cannot test a solution. I would suggest trying the same fix for Windows 10 users to see if it works for PlayStation users as well:
protected function onEnable() : void{ if(!InvMenuHandler::isRegistered()){ InvMenuHandler::register($this); } + // possible solution for playstation users: + $registry = InvMenuHandler::getPlayerManager()->getNetworkHandlerRegistry(); + $registry->register(DeviceOS::PLAYSTATION, $registry->get(DeviceOS::WINDOWS_10)); }
So, I tried multiple situations with a PS4 player.
- With your actual pushed fixed it doesn't work, nothing opens
- With the possible fix just ahead it doesnt work
- By adding * 1000000 to the playstation thing (line 26) it works !!
We all love mojang weird protocol changes..
Thank you for testing, I expected the fix to be something like that. You're welcome to open a PR that addresses the issue on PlayStation🙂
Fix the menu dont send... Quickfix: multitply 1000000 for the stored timestamp