Is there a way I can find out the difference between the position.x of player character and some other character and possibly store this result as an int?
Thanks!
int x_diff = player.x - cOtherguy.x;
If the result needs to be positive, add
if (x_diff < 0) x_diff = -x_diff;