this native, what does it actually do when it said
Whether or not another player is allowed to take control of the entity
But i want to ask that, if first, the netid was 15 , and after that when it migrates will the netidchange to another number? or it would be the same number when I NetworkGetNetworkIdFromEntity
SetNetworkIdCanMigrate(15,false) will stop the entity with network ID 15 from migrating when done on the client that currently has control/ownership.
It basically stops the entity from having their owner changed. Note that this means the entity might disappear when it’s owner disconnects.
An entity has it’s network ID assigned when it is registered as a networked entity. To get a different network ID it will have to be destroyed (either completely or network-wise) and have a new network ID assigned. Unless you are doing that on purpose it is very unlikely to happen.
Network IDs are reused, however, so there is no guarantee that whatever was network ID 15 half an hour ago is still around and has the same ID.
For example, lots and lots of vehicles are created and destroyed every minute as the players move around the map. They all have a netID. If that netID was to be completely unique it would likely overflow the 16 bits (?) of storage for the netID very quickly, as 65535 isn’t really that high of a number.