In multiplayer, sometimes int and sometimes long is used for peer id. For example PeerConnected and PeerDisconnected signals from the MultiplayerApi class pass peer id as long. However GetUniqueId from the same class returns int. If peer id can reach values outside of what int can store, then this is a problem. If the values are all within int's range, this is less of an issue and long can probably be replaced by int for peer ids used in signals.
Steps to reproduce
Compare the type used for peer id in PeerConnected of MultiplayerApi class with type returned by GetUniqueId from the same class.
The engine uses 32 bit values for the peer id, so values outside the int range are never valid.
The signal parameters are of the wrong type as tracked by the linked issue.
Godot version
4.0.1 stable mono win64
System information
irrelevant
Issue description
In multiplayer, sometimes
int
and sometimeslong
is used for peer id. For examplePeerConnected
andPeerDisconnected
signals from theMultiplayerApi
class pass peer id aslong
. HoweverGetUniqueId
from the same class returnsint
. If peer id can reach values outside of whatint
can store, then this is a problem. If the values are all withinint
's range, this is less of an issue andlong
can probably be replaced byint
for peer ids used in signals.Steps to reproduce
Compare the type used for peer id in
PeerConnected
ofMultiplayerApi
class with type returned byGetUniqueId
from the same class.Minimal reproduction project
N/A