Loading a vehicle
#5

urgh you are so hardened

also what the heck is A if R is the angle?

pawn Код:
stock LoadCars(playerid)
{
    new query[96], stats[256], Type, id, Owner[24], Float:x, Float:y, Float:z, Float:A, Float:R, Color1, Color2[5];
    format(query, sizeof(query), "SELECT * FROM `vehicles` WHERE `Owner` = '%s'", Name(playerid));
    mysql_query(query);
    mysql_store_result();
    if(mysql_num_rows())
    {
        if(mysql_fetch_row_format(stats))
        {
            sscanf(stats, "p<|>ds[24]fffffddd", id, Owner, x, y, z, A, R, Color1, Color2, Type);
            SetPVarInt(playerid, "ID", id);
            SetPVarString(playerid, "Owner", Owner);
            SetPVarFloat(playerid, "X", x);
            SetPVarFloat(playerid, "Y", y);
            SetPVarFloat(playerid, "Z", z);
            SetPVarFloat(playerid, "A", A);
            SetPVarFloat(playerid, "R", R);
            SetPVarInt(playerid, "C1", Color1);
            SetPVarInt(playerid, "C2", Color2);
            SetPVarInt(playerid, "Type", Type);
            CreateVehicle(Type, x, y, z, R, Color1, Color2, 60000);
            Attach3DTextLabelToVehicle(Vehicle, id, 0, 10, 0);
        }
    }
}
Reply


Messages In This Thread
Loading a vehicle - by futuretrucker - 13.06.2011, 20:07
Re: Loading a vehicle - by Donya - 13.06.2011, 20:10
Re: Loading a vehicle - by futuretrucker - 13.06.2011, 22:55
Re: Loading a vehicle - by randomkid88 - 14.06.2011, 01:48
Re: Loading a vehicle - by Donya - 14.06.2011, 02:01

Forum Jump:


Users browsing this thread: 2 Guest(s)