[Ajuda] Concessionaria
#1

A quase 1 mкs eu estou tentando colocar a concessionaria Wangs Cars no meu GM, nгo estou conseguindo pois os erros sгo muitos, queria pedir a ajuda de vocкs para fazer um codigo que nem do GM playforever de Concessionaria para o GM Muca, preciso muito, se puder me ajudar agradeзo deis de jah..

Exemplo do Codigo:
Quote:

#define VEH_SAVE_FILE "Conce/%s.ini"

//------------------------------[Conce]-----------------------------------------
enum vInfo
{
vModel,
Float:vX,
Float:vY,
Float:vZ,
Float:vA,
Float:vPX,
Float:vPY,
Float:vPZ,
Float:vPA,
vColor1,
vColor2,
vPaintjob,
vMod[MAX_MODS],
vOwner[MAX_PLAYER_NAME],
vName[128],
vLock,
vPRFLock,
vPark,
}

//--------------------------------[Conce]---------------------------------------

for(new i = 0; i < MAX_PLAYERS; i++)
{
CarColor[i][0] = 1;
CarColor[i][1] = 1;
}
for(new v = 1; v < CAR_AMOUNT; v++)
{
VehicleInfo[v][vModel] = 0;
VehicleInfo[v][vX] = 0;
VehicleInfo[v][vY] = 0;
VehicleInfo[v][vZ] = 0;
VehicleInfo[v][vA] = 0;
VehicleInfo[v][vColor1] = -1;
VehicleInfo[v][vColor2] = -1;
VehicleInfo[v][vPaintjob] = -1;
format(VehicleInfo[v][vName], MAX_PLAYER_NAME, "Nenhum");
format(VehicleInfo[v][vOwner], MAX_PLAYER_NAME, "Nenhum");
VehicleInfo[v][vLock] = 0;
VehicleInfo[v][vPRFLock] = 0;
VehicleInfo[v][vPark] = 0;
VehicleInfo[v][vPX] = 0;
VehicleInfo[v][vPY] = 0;
VehicleInfo[v][vPZ] = 0;
VehicleInfo[v][vPA] = 0;
for(new m = 0; m < MAX_MODS; m++) VehicleInfo[v][vMod][m] = 0;
}

//-----------------------[Conce]------------------------------------------------
LoadPlayerVehicle(playerid);
CarColor[playerid][0] = 1;
CarColor[playerid][1] = 1;
for(new v = 1; v < MAX_VEHICLES; v++) LockVehicle(v);

new playername[MAX_PLAYER_NAME],gw;

//--------------------------------[Conce]---------------------------------------
if (!strcmp("/comprarcarro", cmdtext, true))
{
if(PlayerToPoint(2.0, playerid, 555.9089,-1289.4904,17.2482))
{
for(new i=0;i<MAX_PLAYERS;i++){if(Conce[i]==1){SendClientMessage(playerid, COLOR_OOC, "Alguйm Ja Estб Comprando Um Veiculo Aguarde");TogglePlayerControllable(playerid, 1);return 1;}}
if (GetOwnedVehicleID(playerid) != INVALID_VEHICLE_ID) return SendClientMessage(playerid, RED, "Vocк Ja Possui Um Veiculo!");
if (GetPlayerInterior(playerid) != 0) return SendClientMessage(playerid, RED, "Saia de seu interior"); // To prevent screw ups
GetPlayerPos(playerid, OrgX[playerid], OrgY[playerid], OrgZ[playerid]);
new color1 = CarColor[playerid][0];
new color2 = CarColor[playerid][1];
TogglePlayerControllable(playerid, 0);
SetPlayerCameraPos(playerid, -1980.9927,293.0207,38.9285);
SetPlayerCameraLookAt(playerid, -1971.9277,284.5396,34.8777);
SetPlayerVirtualWorld(playerid, playerid);
ShopCar[playerid] = CreateVehicle(CarModels[0], -1972.5745,284.5845,34.8772, 0.0, color1, color2, 6000000);
SetVehicleVirtualWorld(ShopCar[playerid], playerid);
PutPlayerInVehicle(playerid, ShopCar[playerid], 0);
TogglePlayerControllable(playerid, 0);
CarShopping[playerid] = true;
Conce[playerid] = 1;
SendClientMessage(playerid, COLOR_LIGHTBLUE, "Carros Sport custam R$90.000,00 Motos velozes R$50.000,00 Carros Populares R$32.000,00");
SendClientMessage(playerid, COLOR_LIGHTBLUE, "Motos normais custam R$15.000,00 E veнculos aйreos custam mais de R$ 1.000.000,00");
SendClientMessage(playerid, COLOR_GREY, "Vocк Pode Trocar os Carros Apertando As Setas do Teclado");
SendClientMessage(playerid, COLOR_GREY, "Para Adquirir O Carro Basta Apertar a Tecla CTRL de Seu Teclado");
SendClientMessage(playerid, COLOR_GREY, "Para Sair Da Concessionaria Basta Apertar a Tecla F ou Enter de Seu Teclado");
SendClientMessage(playerid, COLOR_GREEN, "Jб Possui Um Veiculo Em Mente? Use /pularveiculo [Nomedocarro] Obs:Й Mais Recomendado Usar o CMD");
SendClientMessage(playerid, COLOR_YELLOW, "Para mudar a cor do carro antes de comprar digite /corcarro COR1 COR2!");
SendClientMessage(playerid, COLOR_LIGHTBLUE, "Bugou ? Nгo Consegue Sair Use /sairconce!");
SetTimerEx("BrowseCars", 300, 0, "d", playerid);
}
else
{
SendClientMessage(playerid, COLOR_GREEN, "Vocк presisa estar na concessionбria");
}
return 1;
}

if (!strcmp("/pularveiculo", cmd, true))
{
if (CarShopping[playerid] == false) return SendClientMessage(playerid, RED, "[Erro] Vocк nгo estб na Concessionбria!");
tmp = strtok(cmdtext, idx);
if (!strlen(tmp)) return SendClientMessage(playerid,COLOR_RED, "[Use] /pularveiculo [Nomedocarro/id]");
new id = GetVehicleModelIDFromName(tmp);
if (id < 400 || id > 611) return SendClientMessage(playerid, RED, "ID Invalido/Nгo possui em nossa concessionбria");
new color1 = CarColor[playerid][0];
new color2 = CarColor[playerid][1];
carbrowse[playerid] = id-400;
DestroyVehicle(ShopCar[playerid]);
ShopCar[playerid] = CreateVehicle(CarModels[carbrowse[playerid]], -1972.5745,284.5845,34.8772, 0.0, color1, color2, 6000000);
SetVehicleVirtualWorld(ShopCar[playerid], playerid);
PutPlayerInVehicle(playerid, ShopCar[playerid], 0);
return 1;
}
if (!strcmp("/sairconce", cmdtext, true))
{
if (CarShopping[playerid] == false) return SendClientMessage(playerid, RED, "[Erro] Vocк nгo estб na concessionбria!");
Conce[playerid] = 0;
DestroyVehicle(ShopCar[playerid]);
TogglePlayerControllable(playerid, true);
CarShopping[playerid] = false;
carbrowse[playerid] = 0;
GameTextForPlayer(playerid, " ", 1000, 3);
SetPlayerPos(playerid, 556.9771,-1284.8324,17.2482);
SetPlayerFacingAngle(playerid, OrgA[playerid]);
SetPlayerVirtualWorld(playerid, 0);
SetCameraBehindPlayer(playerid);
return 1;
}

if (!strcmp("/corcarro", cmd, true))
{
if (CarShopping[playerid] == false) return SendClientMessage(playerid, RED, "[Erro] Vocк nгo estб no shopping de carros!");
tmp = strtok(cmdtext, idx);
if (!strlen(tmp)) return SendClientMessage(playerid,COLOR_RED, "[Use] /corcarro [color id 1] [color id 2]");
new color1 = strval(tmp);
if (color1 < 0 || color1 > 300) return SendClientMessage(playerid, RED, "Use de 0/300.");
CarColor[playerid][0] = color1;
new color2;
tmp = strtok(cmdtext, idx);
if (!strlen(tmp)) color2 = color1;
else color2 = strval(tmp);
if (color2 < 0 || color2 > 300) return SendClientMessage(playerid, RED, "Use de 0/300.");
CarColor[playerid][1] = color2;
ChangeVehicleColor(GetPlayerVehicleID(playerid), color1, color2);
return 1;
}

if (!strcmp("/pjcarro", cmd, true))
{
if (CarShopping[playerid] == false) return SendClientMessage(playerid, RED, "[Erro] Vocк nгo estб no shopping de carros!");
tmp = strtok(cmdtext, idx);
if (!strlen(tmp)) return SendClientMessage(playerid,COLOR_RED, "[Use] /pjcarro 0 a 2");
new color1 = strval(tmp);
if (color1 < 0 || color1 > 2) return SendClientMessage(playerid, RED, "Use de 0/2.");
CarColor[playerid][0] = color1;
ChangeVehiclePaintjob(GetPlayerVehicleID(playerid) , color1);
return 1;
}

Reply
#2

Para que copiar de outros servers, tenha suas prуprias idйias!

Quando for passar pro GM, vб passando com muito cuidado e vб compilando conforme for passando cada parte, assim vocк vai corrigindo os erros que aparecem.
Reply
#3

passe tudo direitinho e se der erro vai mandando os erros mais facil ou pega uma filterscript de conse pronta
Reply
#4

Eu quero uma concessionaria assim, й mais bonito, hahaha, e nгo й copiar se for assim todo mundo copiou.. Alguem sabe??
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)