isValid

fun isValid(baseZoneX: Int, baseZoneZ: Int): Boolean

Checks if the provided arguments are valid (as in produce the same end coordinates if re-calculated). It is worth noting that the C++ client has zoom functionality for which the server does not get information, so it is not possible to verify this on the C++ clients. Additionally, clients such as RuneLite have their own built-in zoom and also do not correct the packet itself. For these reasons, the verification is not done by the library, but it could provide a useful bit of information for complete vanilla builds.

Parameters

baseZoneX

the south-western zone x coordinate of the build area

baseZoneZ

the south-western zone z coordinate of the build area The base zone coordinates are relative to the build-area that the client builds around. If the player logs in at absolute coordinates 3200, 3220, their baseZoneX would be ((3200 - (6 * 8)) / 8), and the baseZoneZ would be ((3220 - (6 * 8)) / 8), resulting in base zone coordinates of 394, 396. The (6 * 8) is the normal subtraction to go from the center of the build-area to the south-western corner, as a value of 48 is subtracted in the case of a size 104 build-area.