As per me, pointers “point to” a specific area in the memory of a system.
So, when we use the “*” - dereference operator in var = *var2, we tell the compiler to assign the value which is at “var2” position in the memory, to var.
So,
var2 is the memory location, while
*var2 is the value at this location.
And pointers are useful in our case, as instead of assigning the whole asset, which takes a large amount of space, we can assign the memory location, which is much smaller, and then point to the value at that memory location. Hence, lessening our memory usage.
Also, from cplusplus.com’s pointer tutorial, incrementing and decrementing pointers is different as compared to normal variables, and there is the address of (&) operator, which returns the address of the pointer.
The concept of pointers is overall pretty useful in large games, but slightly difficult to handle when you have pointers to pointers, or the same memory address being pointed by 2 or more pointers.
So, it helps save time (runtime) and memory of a process.