y_ini loading objects problem
#1

Hello, i'm trying to load some objects using y_ini..which is saved to a file using y_ini.. however when i'm loading them and creating them, they doesn't apear in-game. (However values are there in the file)

The Loading:
Код:
INI_Load("Objects.ini");
for(new idx = 1; idx < sizeof(ObjInfo); idx++)
{
	if(ObjInfo[idx][oModel])
	{
		ObjInfo[idx][obj] = CreateDynamicObject(ObjInfo[idx][oModel], ObjInfo[idx][oX], ObjInfo[idx][oY], ObjInfo[idx][oZ], ObjInfo[idx][oRX], ObjInfo[idx][oRY], ObjInfo[idx][oRZ]);
	}
}
Help me fix this so they will be loaded right.
Reply
#2

You dont appear to be defining ObjInfo, and you dont appear to be waiting for the ini to load.
Read this documentation, it describes how you need a function named similar to the ini file to handle the data of it once it has actually loaded.
Reply
#3

Found how to fix it, thanks!
Reply
#4

Always a pleasure
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)