Can't create big string variables? Running out of memory?
#1

My server has been acting up lately. I have a player data save function, but when it gets to a big query string size, it stop working completely and doesn't axacute anything after the variable decleration.

Code:
print("saving data");

new savename[24];
GetPlayerName(playerid, savename, 24);

print("saving data 0.1"); // This gets executed
new query[4096]; // This does NOT executed
print("saving data 0.2"); // This does NOT executed nor does anything after this line.
What is wrong here? I remember it used to work perfectly fine a while back, but now it just breaks and doesn't execute any command that the player data save function is in.
Reply
#2

I have managed to fix the problem.
Reply
#3

You could either use "#pragma dynamic" or decrease the amount of cells you're using. Why do you even use that much? I know most roleplay servers have heaps of player data to save, but overall not much of it is actually noticeable. In my opion, large amounts of data isn't really required; but in some cases, it is (not all of the time). You could also separate users' preferences from the actual player data; well, if you have any.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)