20.06.2011, 12:46
Hello I'm writing a house system and use the enum to enumerate the parameters of the house and read them MXIni of the file. But I have a problem:
this code enum:
This code is read parameters from file:
and when I try to take the title in Create3DTextLabel, the name does not appear.
MXIni not write text read into a variable HouseInfo[ID][hName], while all other values (numeric), it handles well.
Prompt: how to fix this problem? How to make the text read MXIni written into this variable? Thanks in advance.
this code enum:
PHP код:
enum hInfo
{
hName[255],
hPrice,
<...>
};
PHP код:
new string[512];
format(string,sizeof(string),HouseDir,ID);
new iniFile = ini_openFile(string);
ini_getString(iniFile,"Name",HouseInfo[ID][hName]);// The problem here
ini_getInteger(iniFile,"Price",HouseInfo[ID][hPrice]);
<...>
ini_closeFile(iniFile);
MXIni not write text read into a variable HouseInfo[ID][hName], while all other values (numeric), it handles well.
Prompt: how to fix this problem? How to make the text read MXIni written into this variable? Thanks in advance.