5df2bb2c0b explains how we gain access to the game's interfaces.
Once we have access to the interfaces, we retrieve the address of the variables' we're interested in by reading the assembly of one or more functions accessing them.
The process for each function is documented in the code.