hello im making my own property system.. i need spawnprop cmd help .. if anyone idea or have help me :)
(https://forum.vc-mp.org/proxy.php?request=http%3A%2F%2Fi0.kym-cdn.com%2Fphotos%2Fimages%2Fnewsfeed%2F000%2F126%2F314%2F3cd8a33a.png%3F1306264975&hash=a81fe9cee29ecff77bd245425619359d5a7d7ae2)
Spawnprop? What?
Quote from: Murdock on Sep 20, 2016, 07:01 AMSpawnprop? What?
lif i setspawn pos to my property .. when ever i join server. i will spawn at my property.
it is simple just check how many props you own select a random prop coods and spawn yourself
e.g player.Pos = Vector(prop.Pos.x, prop.Pos,y,prop.Pos.z);
Quote from: MacTavish on Sep 20, 2016, 07:44 AMit is simple just check how many props you own select a random prop coods and spawn yourself
e.g player.Pos = Vector(prop.Pos.x, prop.Pos,y,prop.Pos.z);
TY i will try.
local q = QuerySQL( db, "SELECT Name, rowid FROM Properties WHERE Owner LIKE '" + player.Name + "'" );
if ( GetSQLColumnData(q,0) != null )
{
local splitPos = split( GetSQLColumnData( q, 5 ), " " );
local x = splitPos[ 1 ], y = splitPos[ 2 ], z = splitPos[ 3 ];
player.Pos = Vector(x.tofloat(), y.tofloat(), z.tofloat());
MessagePlayer("[#F9FF2A]*Teleported* [#FFFFFF]Teleported To Your Property!", player );
FreeSQLQuery(q);
}
i tried .. i cant goto prop when i spawn.
You are selecting Name and rowid only from the query.
Quote from: Xmair on Sep 20, 2016, 04:51 PMYou are selecting Name and rowid only from the query.
its wrong? any help pls?
Quote from: Slark__ on Sep 20, 2016, 05:11 PMQuote from: Xmair on Sep 20, 2016, 04:51 PMYou are selecting Name and rowid only from the query.
its wrong? any help pls?
Use
SELECT *
Because that's what I see in most shitty scripts :p
Quote from: KAKAN on Sep 21, 2016, 08:44 AMQuote from: Slark__ on Sep 20, 2016, 05:11 PMQuote from: Xmair on Sep 20, 2016, 04:51 PMYou are selecting Name and rowid only from the query.
its wrong? any help pls?
Use SELECT *
Because that's what I see in most shitty scripts :p
Yup but i fixed :D