Defines the spatial network among the patches. This function is called automatically during spatial setup and should not be called by user code.
WARNING: This is an internal function. Its use in user code is not recommended or supported, and its signature can change in future updates without warning. Use one of the suggested functions above instead, if applicable.
Parameters
patch — Patch, required
The patch whose connections to return.
corners — bool|num, required
Whether to include corner-adjacent patches in the list, and if so, what weight in the network. Weight will be assumed 1 (equivalent to edge-adjacent patches) if
True
.
Return Value — list[tuple(Patch, num)]
A list tuples, each containing a neighbor, and the weight of the connection to that neighbor.
Notes and Examples