File system?
#1

Hello!

So... Here's the thing... I'll just say I'm making a map editor. The map editor is saving objects through a for loop:

pawn Код:
for(new objectid = 0; objectid < MAX_OBJECTS; objectid++)
I'm using Dini as a file system, it saves everything perfectly, also loads... I love Dini, it's awesome... But it loads a map with a bigger amount of objects (around 150) really slow and it makes a huge lag about 5-7 seconds (even more)...

I really want to make this system as fast as possible... Suggestions?

P.S: MySQL is not an option.
Reply
#2

y_ini or normal samp file system fopen - fread - fclose
Reply
#3

SQLite would be the best option. It's integrated in SA:MP and documented on the wiki. Go check it out if you decide to give it a chance.
Reply
#4

you have this to OnGameModeInit?

If you have this i think you have to do

for(new i=0;i<MAX_OBJECTS;i++)
{
new file[50];
format(file,sizeof(file),"SAVE THE FILE",objectid);
if(dini_Exists(file))
{
CreateDynamicObject(..
}}
Reply
#5

For that the best thing you can use is SQLite, take an look on Texture Studio from Pottus.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)