Dany_Alex Posted January 26, 2013 Report Share Posted January 26, 2013 Sall all deci am adaugat un FS in care trb sa transporti anumite materiale si cand ajungi la checkpoint primesti 10k ei bne intradevar i primesc dar dupa ce se incarca toti mi ia inapoi o fi de la JunkBuster dak are cnv vreo idee...Multumesc Acesta este Scriptul:[pawn]#include <a_samp>#define COLOR_DARKGOLD 0x808000AA#define COLOR_RED 0xFF0000AA#define COLOR_YELLOW 0xFFFF00AA/*new jobtruck[] = {512,513,514,515,516};*/new truckjobrunning = 0;new info;public OnFilterScriptInit(){ AddStaticVehicleEx(455,-43.9742,-1155.8762,1.4823,65.0184,-1,-1, 10); AddStaticVehicleEx(455,-39.6336,-1148.4509,1.5148,62.2225,-1,-1, 10); AddStaticVehicleEx(455,-37.7033,-1144.2280,1.5173,65.7564,-1,-1, 10); AddStaticVehicleEx(455,-35.7032,-1140.0637,1.5149,66.4882,-1,-1, 10); AddStaticVehicleEx(455,-41.9300,-1152.2032,1.5132,62.4657,-1,-1, 10); AddStaticVehicle(411,2074.7217,-2121.5066,13.3707,270.4157,116,1); // AddStaticVehicle(411,2065.8503,-2121.5710,13.3679,270.3890,116,1); // AddStaticVehicle(411,2085.5073,-2121.6392,13.3711,267.6290,116,1); // info = CreatePickup(1239,1,-70.7099,-1139.1187,1.0781,-1);}public OnPlayerCommandText(playerid, cmdtext[]){ if (strcmp("/truck", cmdtext, true, 10) == 0) { if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 455) { truckjobrunning = 1; SetPlayerCheckpoint(playerid, 2058.3142,-2092.4023,9.9832, 10); GameTextForPlayer(playerid, "~g~You started the job, good luck!", 3000, 3); new name[MAX_PLAYER_NAME], string[48]; GetPlayerName(playerid, name, sizeof(name)); format(string, sizeof(string), "%s is now a Truck Driver.", name ); SendClientMessageToAll(COLOR_RED, string); return 1; } SendClientMessage(playerid, COLOR_RED,"You have to be in a truck to start the job"); } if (strcmp("/truckinfo", cmdtext, true, 10) == 0) { SendClientMessage(playerid, COLOR_YELLOW, "You need to bring the truckload to the airport."); SendClientMessage(playerid, COLOR_YELLOW, "There they will reward you for your help."); SendClientMessage(playerid, COLOR_YELLOW, "If you enter the truck, type /truck and a red marker will appear."); SendClientMessage(playerid, COLOR_YELLOW, "Just drive to the marker and you're done."); return 1; } return 0;}public OnPlayerEnterCheckpoint(playerid){ if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 455) { GivePlayerMoney(playerid, 10000); GameTextForPlayer(playerid, "~g~You Completed the job, well done!", 3000, 3); SetVehicleToRespawn(513); DisablePlayerCheckpoint(playerid); truckjobrunning = 0; }}public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger){ if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 455) { SendClientMessage(playerid, COLOR_RED, "You can start the truck-mission with /truck"); } return 0;}public OnPlayerExitVehicle(playerid, vehicleid){ if((truckjobrunning) == 1) { truckjobrunning = 0; SendClientMessage(playerid, COLOR_RED, "You left your truck behind, get in again if you want to continue your job."); }else if((truckjobrunning) == 0){ //Nothing }}public OnPlayerPickUpPickup(playerid, pickupid){ if(pickupid == info) { GameTextForPlayer(playerid, "~g~Welcome at the Truck Driver job, use /truckinfo to know more", 3000, 3); }}[/pawn] Link to comment Share on other sites More sharing options...
Gireada Posted January 26, 2013 Report Share Posted January 26, 2013 Sigur e de la junk buster, ca scriptul nu are nimica Link to comment Share on other sites More sharing options...
Dany_Alex Posted January 26, 2013 Author Report Share Posted January 26, 2013 am facut un test am dezactivat Junk Buster si acu merge dar e o problema merge si hackul ce pot face ms frumos pt ajutor Link to comment Share on other sites More sharing options...
AlexTraficantuL Posted January 26, 2013 Report Share Posted January 26, 2013 Incearca sa cauti un JunkBuster bun... Link to comment Share on other sites More sharing options...
sTr Posted January 26, 2013 Report Share Posted January 26, 2013 Incearca sa pui asa:La inceputul scriptului:[pawn]#define GivePlayerMoney JBC_GivePlayerMoney[/pawn]Iar unde ai GivePlayerMoney, sa pui asa:[pawn]JBC_GivePlayerMoney(playerid, money);[/pawn] RPG.QGAMING.RO Link to comment Share on other sites More sharing options...
Dany_Alex Posted January 27, 2013 Author Report Share Posted January 27, 2013 str am incercat sa fac cum ai spus uh si mia dat o eroare la compile spune : error 017: undefined symbol "JBC_GivePlayerMoney" Link to comment Share on other sites More sharing options...
sTr Posted January 27, 2013 Report Share Posted January 27, 2013 Atunci incearca sa stergi 'C'u de la 'JBC' sa sa fie doar 'JB', depinde cum iti e definit si JunkBuster-ul tau. RPG.QGAMING.RO Link to comment Share on other sites More sharing options...
Dany_Alex Posted January 27, 2013 Author Report Share Posted January 27, 2013 Am incercat si nu merge dar in GM am JB_GivePlayerMoney si merge nu am probleme dar in FS nu mil ia uite o parte din script cred ca la asta te referi am pus tot ce tine de GivePlayerMoney[pawn]forward JB_GivePlayerMoney(playerid,amount);ublic JB_GivePlayerMoney(playerid,amount){ if(IsPlayerConnected(playerid)) { GivePlayerMoney(playerid,amount); JB_PlayerInfo[playerid][JB_pMoney]+=amount; return 1; } return 0;}#define GivePlayerMoney JB_GivePlayerMoney[/pawn] Link to comment Share on other sites More sharing options...
Dany_Alex Posted January 27, 2013 Author Report Share Posted January 27, 2013 am rezolvato am bagat jobul in GM si merge perfect dar totusi in FS dc imi lua bani dupa ce se incarcau si in GM nu sigur nui cva din script?Oricum multumesc frumos pt ajutor :P Link to comment Share on other sites More sharing options...
Fallen0329 Posted January 27, 2013 Report Share Posted January 27, 2013 daca vrei sa mearga jobul si in fs trebuie sa adaugi la inceput[pawn]#include <junkbuster>[/pawn] Link to comment Share on other sites More sharing options...
Dany_Alex Posted January 27, 2013 Author Report Share Posted January 27, 2013 Fallen0329 am adaugat #include <junkbuster> la inceputul FS-ului si acu intradevar merge perfect dar nu imi mai merge GM de ex dak dau /givemoney id suma mi da si porma mi ia inapoi.Acu face GM exact cum facea FS inainte )... poti sa imi mai explici o data ms Link to comment Share on other sites More sharing options...
Fallen0329 Posted January 28, 2013 Report Share Posted January 28, 2013 daca ai junkbuster sub forma de fs atunci trebuie sa adaugi acel include peste tot in toate fs-urile si in gm Link to comment Share on other sites More sharing options...
Dany_Alex Posted January 28, 2013 Author Report Share Posted January 28, 2013 Si dak nu il am in FS si il am in ScriptFiles si in pawno/includes cum trb sa procedez? Link to comment Share on other sites More sharing options...
Question
Dany_Alex
Sall all deci am adaugat un FS in care trb sa transporti anumite materiale si cand ajungi la checkpoint primesti 10k ei bne intradevar i primesc dar dupa ce se incarca toti mi ia inapoi o fi de la JunkBuster dak are cnv vreo idee...Multumesc
Acesta este Scriptul:
[pawn]
#include <a_samp>
#define COLOR_DARKGOLD 0x808000AA
#define COLOR_RED 0xFF0000AA
#define COLOR_YELLOW 0xFFFF00AA
/*new jobtruck[] = {
512,513,514,515,516};*/
new truckjobrunning = 0;
new info;
public OnFilterScriptInit()
{
AddStaticVehicleEx(455,-43.9742,-1155.8762,1.4823,65.0184,-1,-1, 10);
AddStaticVehicleEx(455,-39.6336,-1148.4509,1.5148,62.2225,-1,-1, 10);
AddStaticVehicleEx(455,-37.7033,-1144.2280,1.5173,65.7564,-1,-1, 10);
AddStaticVehicleEx(455,-35.7032,-1140.0637,1.5149,66.4882,-1,-1, 10);
AddStaticVehicleEx(455,-41.9300,-1152.2032,1.5132,62.4657,-1,-1, 10);
AddStaticVehicle(411,2074.7217,-2121.5066,13.3707,270.4157,116,1); //
AddStaticVehicle(411,2065.8503,-2121.5710,13.3679,270.3890,116,1); //
AddStaticVehicle(411,2085.5073,-2121.6392,13.3711,267.6290,116,1); //
info = CreatePickup(1239,1,-70.7099,-1139.1187,1.0781,-1);
}
public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp("/truck", cmdtext, true, 10) == 0)
{
if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 455)
{
truckjobrunning = 1;
SetPlayerCheckpoint(playerid, 2058.3142,-2092.4023,9.9832, 10);
GameTextForPlayer(playerid, "~g~You started the job, good luck!", 3000, 3);
new name[MAX_PLAYER_NAME], string[48];
GetPlayerName(playerid, name, sizeof(name));
format(string, sizeof(string), "%s is now a Truck Driver.", name );
SendClientMessageToAll(COLOR_RED, string);
return 1;
}
SendClientMessage(playerid, COLOR_RED,"You have to be in a truck to start the job");
}
if (strcmp("/truckinfo", cmdtext, true, 10) == 0)
{
SendClientMessage(playerid, COLOR_YELLOW, "You need to bring the truckload to the airport.");
SendClientMessage(playerid, COLOR_YELLOW, "There they will reward you for your help.");
SendClientMessage(playerid, COLOR_YELLOW, "If you enter the truck, type /truck and a red marker will appear.");
SendClientMessage(playerid, COLOR_YELLOW, "Just drive to the marker and you're done.");
return 1;
}
return 0;
}
public OnPlayerEnterCheckpoint(playerid)
{
if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 455)
{
GivePlayerMoney(playerid, 10000);
GameTextForPlayer(playerid, "~g~You Completed the job, well done!", 3000, 3);
SetVehicleToRespawn(513);
DisablePlayerCheckpoint(playerid);
truckjobrunning = 0;
}
}
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 455)
{
SendClientMessage(playerid, COLOR_RED, "You can start the truck-mission with /truck");
}
return 0;
}
public OnPlayerExitVehicle(playerid, vehicleid)
{
if((truckjobrunning) == 1)
{
truckjobrunning = 0;
SendClientMessage(playerid, COLOR_RED, "You left your truck behind, get in again if you want to continue your job.");
}else if((truckjobrunning) == 0){
//Nothing
}
}
public OnPlayerPickUpPickup(playerid, pickupid)
{
if(pickupid == info)
{
GameTextForPlayer(playerid, "~g~Welcome at the Truck Driver job, use /truckinfo to know more", 3000, 3);
}
}
[/pawn]
Link to comment
Share on other sites
12 answers to this question
Recommended Posts