Why did you expect that changing the variable enemylevel would cause playerhp and enemyhp to change?
Each variable is a location in memory. So
int playerlevel = 1;
stores the value 1 in the location where the int playerlevel is located.
int enemylevel = playerlevel;
reads the value out of the memory where int playerlevel is located and then stores it in the memory location for enemylevel.
The two variables now have the same value, but they are stored in totally different locations in memory. So changing one location will not change the other.
If I understand your problem correctly, that you want to be able to change (only) playerlevel and have the other variables track the changes according to some fixed rules, then the C++ way would be a class.