SQLite - Save position player
#1

Hi all ^^

My code:

Код:
new string[256];
new Float:posx;
new Float:posy;
new Float:posz;

GetPlayerPos(playerid, posx, posy, posz);
format(string, sizeof(string), "UPDATE `PLAYER` SET `POSX` = '%f' AND `POSY` = '%f' AND `POSZ` = '%f' WHERE NAME= '%s'", posx, posy, posz, DB_Escape(NamePlayer(playerid)));
db_free_result(db_query(Sqlite, string));
No save in Sqlite.db, code of table:

Код:
CREATE TABLE `PLAYER` (`NAME` VARCHAR(45), `SCORE` SMALLINT(5) DEFAULT 0, `KARMA` SMALLINT(5) DEFAULT 0, `POSX` FLOAT DEFAULT 0.0, `POSY` FLOAT DEFAULT 0.0, `POSZ` FLOAT DEFAULT 0.0, `SKIN` SMALLINT(3) DEFAULT 0);
PD: I create POSX, POSY and POSZ in table with Float. But not save, for default in db 0.0

Thx for all, waiting posible fix
Reply


Messages In This Thread
SQLite - Save position player - by u3games - 10.06.2013, 21:14
Re: SQLite - Save position player - by Knappen - 10.06.2013, 21:55
Respuesta: Re: SQLite - Save position player - by u3games - 10.06.2013, 22:22

Forum Jump:


Users browsing this thread: 1 Guest(s)