25.10.2012, 16:34
(
Последний раз редактировалось AndreT; 25.10.2012 в 17:16.
)
Nice tutorial, but there's a thing I don't understand. Your function returns r, which I don't see being a declared variable. I have not been in any decent contact with these functions and thereby cannot tell if it is a mistaken on your side or a predefined variable on the server side :P
Also, take note that the MySQL plugin actually creates only one thread which processes all the pooled queries. A new query does not initiate a new thread, the queries are just ran in another thread to avoid cluttering the main script thread.
Anyways, in the case you present here, adding a value to a value which you get from the DB using a custom function, wouldn't you lose all the hassle by storing the money value in your GM (I suppose it gets accessed quite often or no?).
// EDIT: lol Vince
Also, take note that the MySQL plugin actually creates only one thread which processes all the pooled queries. A new query does not initiate a new thread, the queries are just ran in another thread to avoid cluttering the main script thread.
Anyways, in the case you present here, adding a value to a value which you get from the DB using a custom function, wouldn't you lose all the hassle by storing the money value in your GM (I suppose it gets accessed quite often or no?).
// EDIT: lol Vince