Why it stop my server?
#6

How is the function HoraSave() being called?
Is it in a timer that runs every second or so?
Because that would explain your problem.
All these queries would be sent every second for about a minute in duration if that's the case and could cause slowdowns.

Also, in SalvarServer, you declare a variable FactionID but you never use it, so you're updating ALL rows in your server 100 times if you have 100 factions.
There is no WHERE clause to be seen in those queries.

And I don't get why you update all this info all at once?
Most of the data doesn't even change.

When saving those houses, why update the OutPosX and such coordinates?
Do your houses move every hour or what?

Save whatever must be saved, and only do it when it changes.
Don't create such huge and many queries all at once.
No wonder your server locks up and hangs for a while.

When the owner of the house changes, update that and only that.
Don't go updating all other never-changing data about the house, because it's position (outposx, outposy, outposz, inposx, inposy, inposz) hasn't changed, the price hasn't changed, so no need to update those values.
Reply


Messages In This Thread
Why it stop my server? - by maikons - 10.02.2016, 23:08
Re: Why it stop my server? - by Vince - 10.02.2016, 23:30
Re: Why it stop my server? - by Loinal - 10.02.2016, 23:35
Re: Why it stop my server? - by itsCody - 10.02.2016, 23:42
Re: Why it stop my server? - by Loinal - 10.02.2016, 23:43
Re: Why it stop my server? - by AmigaBlizzard - 10.02.2016, 23:46
Re: Why it stop my server? - by maikons - 10.02.2016, 23:56
Re: Why it stop my server? - by maikons - 12.02.2016, 23:15

Forum Jump:


Users browsing this thread: 1 Guest(s)