Me again...
I defined a struct:
typedef struct
{
STRING*script;
MAP*map;
} LEVEL;
and initialized the STRING at the beginning:
LEVEL*lvl_K={script="#20";}
Now, i want to copy something in it:
STRING*str=str_create("hello");
str_cpy(lvl_K.script,str);
When i try to copy it, the Engine says: Invalid Arguments.
EDIT:
When i add
lvl_k.script=str_create("#20");
before i copy something in it, the Engine doesn't give any errors and the string contains "hello". But text(
TEXT*txt_1=
{
pos_x=100;
pos_y=100;
layer=2;
font="Courier#25b";
string=lvl_K.script;
}
) still shows "#20". Not an empty contant of 20 characters, simply #20. Why?
Help me!