Vehicle System

Started by KrlozZ..., Apr 26, 2017, 09:58 PM

Previous topic - Next topic

dracc

Quote from: Xmair on Mar 03, 2019, 12:18 PM
Quote from: dracc on Feb 27, 2019, 01:53 PMWhat makes you think it's an invalid query? :-\
Wrong syntax, and please refrain from bumping topics.

Oh, true. My misstake.

dracc

Quote from: Mahmut_T7 on Jun 18, 2019, 12:05 PMI need help.

https://imgur.com/7pM7oJm

When I add your commands in function they wont work I think there is problem in here
:

 local cmd = command.tolower();
 local cmd = text;
 cmd = command.tolower();
 text = arguments;
 local params;
The error lies within your changes to the code as I replied in the thread you created for this same problem.

Mahmut_T7

Quote from: dracc on Jun 18, 2019, 05:36 PM
Quote from: Mahmut_T7 on Jun 18, 2019, 12:05 PMI need help.

https://imgur.com/7pM7oJm

When I add your commands in function they wont work I think there is problem in here
:

 local cmd = command.tolower();
 local cmd = text;
 cmd = command.tolower();
 text = arguments;
 local params;
The error lies within your changes to the code as I replied in the thread you created for this same problem.
Me again, sorry I need your help.When I buy a car my money still same.

Where at problem ?
https://imgur.com/lil1GS4
https://imgur.com/L6Prs1e
Böl ve yönet

AroliS^

#33
Quote from: Mahmut_T7 on Jun 19, 2019, 04:00 PM
Quote from: dracc on Jun 18, 2019, 05:36 PM
Quote from: Mahmut_T7 on Jun 18, 2019, 12:05 PMI need help.

https://imgur.com/7pM7oJm

When I add your commands in function they wont work I think there is problem in here
:

 local cmd = command.tolower();
 local cmd = text;
 cmd = command.tolower();
 text = arguments;
 local params;
The error lies within your changes to the code as I replied in the thread you created for this same problem.
Me again, sorry I need your help.When I buy a car my money still same.

Where at problem ?
https://imgur.com/lil1GS4
https://imgur.com/L6Prs1e

/*
DecCash( player, Cost  );
*/
->
DecCash( player, Cost  );

i guess you already gave the DecCash function
Lemme love ya

dracc

Quote from: Mahmut_T7 on Jun 19, 2019, 04:00 PM
Quote from: dracc on Jun 18, 2019, 05:36 PM
Quote from: Mahmut_T7 on Jun 18, 2019, 12:05 PMI need help.

https://imgur.com/7pM7oJm

When I add your commands in function they wont work I think there is problem in here
:

 local cmd = command.tolower();
 local cmd = text;
 cmd = command.tolower();
 text = arguments;
 local params;
The error lies within your changes to the code as I replied in the thread you created for this same problem.
Me again, sorry I need your help.When I buy a car my money still same.

Where at problem ?
https://imgur.com/lil1GS4
https://imgur.com/L6Prs1e
Are you seriously using comic sans for your scripting?

dracc

Quote from: AroliS^ on Jun 19, 2019, 04:59 PM
Quote from: Mahmut_T7 on Jun 19, 2019, 04:00 PM
Quote from: dracc on Jun 18, 2019, 05:36 PM
Quote from: Mahmut_T7 on Jun 18, 2019, 12:05 PMI need help.

https://imgur.com/7pM7oJm

When I add your commands in function they wont work I think there is problem in here
:

 local cmd = command.tolower();
 local cmd = text;
 cmd = command.tolower();
 text = arguments;
 local params;
The error lies within your changes to the code as I replied in the thread you created for this same problem.
Me again, sorry I need your help.When I buy a car my money still same.

Where at problem ?
https://imgur.com/lil1GS4
https://imgur.com/L6Prs1e

/*
IncCash( player, Cost  );
*/
->
IncCash( player, Cost  );

i guess you already gave the IncCash function
Looks like you're right, except for the mis-quotation. It's "DecCash(...".

lambada7

Quote from: KrooB on Dec 07, 2018, 01:27 PMelse if (cmd=="aracekle")
{
if ( stats[ player.ID ].Reg == false ) return MessagePlayer( "[#E0E0E0]kayit olmaniz gerek.", player );
else if ( stats[ player.ID ].Log == false ) return MessagePlayer( "[#E0E0E0]giris yapmaniz gerek", player );
if ( player.Name == "KrOoB" )   

if ( player.Vehicle ) MessagePlayer("[#E0E0E0]Aractan inmek zorundasin", player );
if ( !player.IsSpawned ) MessagePlayer("[#E0E0E0]Dogman gerek!", player );
else if( !text ) MessagePlayer("[#E0E0E0]Kod /"+cmd+" <Veh/ID> <Col1/ID> <Col2/ID> <World> <Price>", player);
else {
local TextSplit = split( text, " " ),ModelID=TextSplit[ 0 ],ColID1=TextSplit[ 1 ],ColID2=TextSplit[ 2 ],WorldID=TextSplit[ 3 ],Price=TextSplit[ 4 ];
if (!IsNum(ModelID)) MessagePlayer("[#E0E0E0]Kod /"+cmd+" <Veh/ID> <Col1/ID> <Col2/ID> <World> <Price>.", player);
else if ( !IsNum(ColID1)) MessagePlayer("[#E0E0E0]Kod /"+cmd+" <Veh/ID> <Col1/ID> <Col2/ID> <World> <Price>", player);
else if ( !IsNum(ColID2)) MessagePlayer("[#E0E0E0]Kod /"+cmd+" <Veh/ID> <Col1/ID> <Col2/ID> <World> <Price>", player);
else if ( !IsNum(WorldID)) MessagePlayer("[#E0E0E0]Kod /"+cmd+" <Veh/ID> <Col1/ID> <Col2/ID> <World> <Price>", player);
else if ( !IsNum(Price)) MessagePlayer("[#E0E0E0]Kod /"+cmd+" <Veh/ID> <Col1/ID> <Col2/ID> <World> <Price>", player);
else if ( !Price ) MessagePlayer("[#E0E0E0]Kod /"+cmd+" <Veh/ID> <Col1/ID> <Col2/ID> <World> <Price>", player);
else if ((ModelID.tointeger() < 130) ) MessagePlayer ( "[#E0E0E0]ID 13'den buyuk olmali" , player );
else if ((ModelID.tointeger() == 180))MessagePlayer ("[#E0E0E0]Bu ID arac icin degil" , player );
else if ((ModelID.tointeger() == 181))MessagePlayer ("[#E0E0E0]Bu ID arac icin degil" , player );
else if ((ModelID.tointeger() == 165))MessagePlayer ("[#E0E0E0]Bu ID arac icin degil" , player );
else {
local VehicleID=GetVehicleCount();
VehicleID+=1;
QuerySQL( Vehicles, "INSERT INTO Creation ( id, model, x, y, z, col1, col2, world, angle ) VALUES ( '"+VehicleID+"', '"+ModelID+"', '"+player.Pos.x+"', '"+player.Pos.y+"', '"+player.Pos.z+"', '"+ColID1+"', '"+ColID2+"', '"+WorldID+"', '"+player.Angle+"' )" );
QuerySQL( Vehicles, "INSERT INTO Sale ( ID, Cost, Owner, Shared, Shared2 ) VALUES ( '"+VehicleID+"', '"+Price+"', 'Sahibi satiliga cikardi', 'None', 'None' )" );
CreateVehicle(ModelID.tointeger(),WorldID.tointeger(),player.Pos, player.Angle,ColID1.tointeger(),ColID2.tointeger());
Message( "[#E0E0E0]Yetkili ["+player.Name+"] yeni arac ekledi, ID: "+VehicleID+"" );
player.Pos.z +6;
     }
     }
}

Dene bunu olmalı

Try this
Olmadı....happened....
Hala Aynı!
Still same!


Mahmut_T7

Quote from: AroliS^ on Jun 19, 2019, 04:59 PM
Quote from: Mahmut_T7 on Jun 19, 2019, 04:00 PM
Quote from: dracc on Jun 18, 2019, 05:36 PM
Quote from: Mahmut_T7 on Jun 18, 2019, 12:05 PMI need help.

https://imgur.com/7pM7oJm

When I add your commands in function they wont work I think there is problem in here
:

 local cmd = command.tolower();
 local cmd = text;
 cmd = command.tolower();
 text = arguments;
 local params;
The error lies within your changes to the code as I replied in the thread you created for this same problem.
Me again, sorry I need your help.When I buy a car my money still same.

Where at problem ?
https://imgur.com/lil1GS4
https://imgur.com/L6Prs1e

/*
DecCash( player, Cost  );
*/
->
DecCash( player, Cost  );

i guess you already gave the IncCash function
Thanks !
Böl ve yönet

Mahmut_T7

Quote from: dracc on Jun 19, 2019, 05:07 PM
Quote from: Mahmut_T7 on Jun 19, 2019, 04:00 PM
Quote from: dracc on Jun 18, 2019, 05:36 PM
Quote from: Mahmut_T7 on Jun 18, 2019, 12:05 PMI need help.

https://imgur.com/7pM7oJm

When I add your commands in function they wont work I think there is problem in here
:

 local cmd = command.tolower();
 local cmd = text;
 cmd = command.tolower();
 text = arguments;
 local params;
The error lies within your changes to the code as I replied in the thread you created for this same problem.
Me again, sorry I need your help.When I buy a car my money still same.

Where at problem ?
https://imgur.com/lil1GS4
https://imgur.com/L6Prs1e
Are you seriously using comic sans for your scripting?
No Im using notepad ++ but I opened with that for taking screenshoot easier ;D
Böl ve yönet

KrOoB_

u didn't look at this script thoroughly, did u ?