method
IVec2.add
IVec2.add(a, b) -> IVec2
Adds two integer vectors component-wise. Adding a direction step to a position is how a token moves one cell on a grid.
Example
program Demo {
handler Step phase Update {
let next = IVec2.add(pos, IVec2.make(1, 0))
}
}