I'm building a game, and when I change the value in 2d-map using the following code
char example[100];
strcpy(example, " ");
strcat(example, player1->unitName[j]);
strcat(example, " ");
map->map[x][y] = example;
the whole values I put with example in map change.
I guess I'm putting the pointer to the example.
Is there any way I can put just the value of example not the address or pointer?