-
Posts
194 -
Joined
-
Last visited
-
Days Won
2
Content Type
Profiles
Forums
News
Documentation
Everything posted by Mark S.
-
Descriere tutorial: As dori un tutorial de comanda care sa fie ceva de genul: /event [nume event] [nume sponsor] [premiu] [cu masina da/nu] si cand scrie sa afiseze asa: Eventul Deagle este organizat de sponsorul Selby cu premiu de 100k . Cerinte vehicul: NU. Nu sunt prea bun la result while si cum se face. Format string alea alea stiu cum e dar nu stiu cum sa faci sa scrie, asa ca am solicitat un tutorial deoarece as dori sa mai fac cate 2 3 comenzi ceva in gen si nu vreau sa postez de fiecare data la "ajutor scripting". Multumesc anticipat
-
public OnPlayerRegister sau public OnPlayerLogin Ai?
-
Acum se vede asa: primul textdraw arata text la propriu "Hud;radardisc" iar al doilea este negru http://i.imgur.com/ed8Lfsj.png eu vreau sa arata asa http://i.imgur.com/aTpSvwX.png
-
arata in continuare, trebuie sa fie multe ceva gen TestPoints[playerid] = 0; OfficerCourseStep[playerid] = 255; IsPlayerInEVehicle[playerid] = 9999; Searching[playerid] = 0; admin[playerid] = 0; AFK[playerid] = 0; UsedAreaRecently[playerid] = 0; SelectChar[playerid] = 0; HidePM[playerid] = 0; PhoneOnline[playerid] = 0; SelectCharID[playerid] = 0; fireinfo[playerid] = 0; ghost[playerid] = 0; PlayerInfo[playerid][pplane] = 0 si pune spoiler pentru ele sau code pentru ca o s fie multe
-
pai acesta este text drawul dar este pe negru si cum il fac alb pentru ca trebuie sa aiba si box text = TextDrawCreate(493.000000, 156.000000, "hud:radardisc");//color TextDrawBackgroundColor(text, 0xFFFFFFC8); TextDrawFont(text, 4); TextDrawLetterSize(text, 0.500000, 1.000000); TextDrawColor(text, 0xFFFFFF00); TextDrawSetOutline(text, 0); TextDrawSetProportional(text, 1); TextDrawSetShadow(text, 0); TextDrawUseBox(text, 1); TextDrawBoxColor(text, 1); TextDrawTextSize(text, 27.000000, 33.000000); TextDrawSetSelectable(text, 0); este pe wiki http://wiki.sa-mp.com/wiki/TextDrawBoxColor dar nu inteleg daca pun culoarea 0x000000FF o sa se faca " cutia" culoarea textului adica cea cu rosu de sus?
-
tot negru este acum. Am observat ca box color este de vina si am pus box color 0xFFFFFFAA si este transparent cum il fac sa fie alb?
-
Daca pun asa se face transparent, eu vreau alb... daca pun asa se face negru PS: textdraw-ul este de la un telefon.
-
Problema intalnita (descriere): am un text draw negru si as dori sa il fac alb Ero(area / rile) / warning-(ul / urile): - Liniile de cod / sursa / script-ul: text = TextDrawCreate(493.000000, 156.000000, "hud:radardisc");//color TextDrawBackgroundColor(text, 0xFFFFFFC8); TextDrawFont(text, 4); TextDrawLetterSize(text, 0.500000, 1.000000); TextDrawColor(text, 0xFFFFFFC8); TextDrawSetOutline(text, 0); TextDrawSetProportional(text, 1); TextDrawSetShadow(text, 0); TextDrawUseBox(text, 1); TextDrawBoxColor(text, 1); TextDrawTextSize(text, 27.000000, 33.000000); TextDrawSetSelectable(text, 0); text2 = TextDrawCreate(493.000000, 423.000000, "hud:radardisc");//color TextDrawBackgroundColor(text2, 0xFFFFFFC8); TextDrawFont(text2, 4); TextDrawLetterSize(text2, 0.500000, 1.000000); TextDrawColor(text2, 0xFFFFFFC8); TextDrawSetOutline(text2, 0); TextDrawSetProportional(text2, 1); TextDrawSetShadow(text2, 0xFFFFFFC8); TextDrawUseBox(text2, 1); TextDrawBoxColor(text2, 0xFFFFFFC8); TextDrawTextSize(text2, 27.000000, -33.000000); TextDrawSetSelectable(text2, 0); Imagini / Video (optional): http://i.imgur.com/jiatMIV.png Ati incercat sa rezolvati singur?: pai am pus peste tot culoarea alb
-
folosesti Gm Raven NoNamed?
-
pune inloc de if (PlayerToPoint(1.5, playerid,HouseInfo[hExitx], HouseInfo[hExity], HouseInfo[hExitz])) if(IsPlayerInRangeOfPoint(playerid, 2.0, playerid,HouseInfo[hExitx], HouseInfo[hExity], HouseInfo[hExitz]))
-
Salut, la primul code este funcia cand iesi afara din casa, si ce nu merge?
-
La comenzile cu dcmd face vreo una "Unknow"?
-
Merge, afiseaza text lock si am pus paramasex. Multumesc
-
Multumesc merge, desi atunci cand urci in masina nu scrie gametext Locked
-
Am pus asa si merge doar pentru mine alt player poate intra in ea. Ce sa ii fac sa nu poate ceilalti playeri?
-
Salut, Sealand asta ai la onplayercommand text, nu? public OnPlayerCommandText(playerid, cmdtext[]) { dcmd(xgoto, 5, cmdtext); dcmd(gpsfind, 7, cmdtext); dcmd(attach,6,cmdtext); dcmd(unattach,8,cmdtext); dcmd(acheckcode,10,cmdtext); dcmd(alias,5,cmdtext); dcmd(ips,3,cmdtext); dcmd(getips,6,cmdtext); dcmd(getaliases,10,cmdtext); dcmd(unban,5,cmdtext); dcmd(saveeverything,14,cmdtext); new string[512 char]; new playermoney; new sendername[MAX_PLAYER_NAME]; new giveplayer[MAX_PLAYER_NAME]; new playername[MAX_PLAYER_NAME]; new cmd[128]; new tmp[128]; new dancestyle; new giveplayerid, moneys, idx; new idcar = GetPlayerVehicleID(playerid); new pveh = GetVehicleModel(GetPlayerVehicleID(playerid)); cmd = strtok(cmdtext, idx); GetPlayerName(playerid, sendername, sizeof(sendername)); new y5, m5, d5; new h5,mi5,s5; getdate(y5,m5,d5); gettime(h5,mi5,s5); format(string,sizeof(string), "(%d/%d/%d)[%d:%d:%d] %s [CMD] -> %s",d5,m5,y5,h5,mi5,s5,sendername,cmdtext); AllCommandLog(string); if(PlayerInfo[playerid][pAdmin] == 0) Commands[playerid] ++; if(Commands[playerid] >= 1) { KillTimer(CommandsTimer[playerid]); CommandsTimer[playerid] = SetTimerEx("ResetCommands",1500,false,"i",playerid); } if(Commands[playerid] == 5) SendClientMessage(playerid, COLOR_LIGHTBLUE,"* Slow it down or you will be kicked!"); if(Commands[playerid] == 10) { Daca da atunci sterge acele dcmd(xgoto, 5, cmdtext); si incearca.
-
Problema intalnita (descriere): Nu merge comanda /lock1 si /lock2 Ero(area / rile) / warning-(ul / urile): -- Liniile de cod / sursa / script-ul: else if(strcmp(x_nr,"lock",true) == 0) { new keycar = PlayerInfo[playerid][pPcarkey]; if(keycar != 9999) { new Float:X,Float:Y,Float:Z; GetVehiclePos(keycar,X,Y,Z); if(IsPlayerInRangeOfPoint(playerid, 25,X,Y,Z)) { new locked[128]; locked = strtok(cmdtext, idx); if(CarInfo[keycar][cLock] == 1) { format(string, sizeof(string), "~w~Vehicle~n~~g~Unlocked"); GameTextForPlayer(playerid, string, 4000, 3); SetVehicleParamsForPlayer(GetPlayerVehicleID(playerid),playerid,0,0); CarInfo[keycar][cLock] = 0; OnPropUpdate(4,keycar); return 1; } else if(CarInfo[keycar][cLock] == 0) { format(string, sizeof(string), "~w~Vehicle~n~~r~Locked"); GameTextForPlayer(playerid, string, 4000, 3); SetVehicleParamsForPlayer(GetPlayerVehicleID(playerid),playerid,0,1); CarInfo[keycar][cLock] = 1; OnPropUpdate(4,keycar); return 1; } } else { SendClientMessage(playerid, COLOR_GREY,"* You must be Near or in Your car to lock it!"); return 1; } } else { SendClientMessage(playerid, COLOR_GREY, "* You don't have a vehicle at slot 1"); return 1; } } else if(strcmp(x_nr,"lock2",true) == 0) { new keycar = PlayerInfo[playerid][pPcarkey2]; if(keycar != 9999) { new Float:X,Float:Y,Float:Z; GetVehiclePos(keycar,X,Y,Z); if(IsPlayerInRangeOfPoint(playerid, 25,X,Y,Z)) { new locked[128]; locked = strtok(cmdtext, idx); if(CarInfo[keycar][cLock] == 1) { format(string, sizeof(string), "~w~Vehicle~n~~g~Unlocked"); GameTextForPlayer(playerid, string, 4000, 3); SetVehicleParamsForPlayer(GetPlayerVehicleID(playerid),playerid,0,0); CarInfo[keycar][cLock] = 0; OnPropUpdate(4,keycar); return 1; } else if(CarInfo[keycar][cLock] == 0) { format(string, sizeof(string), "~w~Vehicle~n~~r~Locked"); GameTextForPlayer(playerid, string, 4000, 3); CarInfo[keycar][cLock] = 1; OnPropUpdate(4,keycar); SetVehicleParamsForPlayer(GetPlayerVehicleID(playerid),playerid,0,1); return 1; } } else { SendClientMessage(playerid, COLOR_GREY,"* You must be Near or in Your car to lock it!"); return 1; } } else { SendClientMessage(playerid, COLOR_GREY, " You don't have a vehicle at slot 2"); return 1; } } Imagini / Video (optional): Ati incercat sa rezolvati singur?: am pus la onplayerentervehicle new keycar = PlayerInfo[playerid][pPcarkey2]; if(CarInfo[keycar][cLock] == 1) { GameTextForPlayer(playerid, "Lock", 4000, 3); return 1; } si nu merge
-
la /handbrake era asa GetVehicleZAngle(coche, VehFrenoPOS[coche][3]); si la public era asa SetVehicleZAngle(vehicleid, VehComprobar[playerid][3]); asa ca am modificat in SetVehicleZAngle(vehicleid, VehFrenoPOS[playerid][3]); si merge multumesc
-
Salut oricum ar fi fancy angle el il seteaza tot 0 sau 90 cat o fi
-
Problema intalnita (descriere): Buna ziua, Comanda handbrake are un bug: cand scrii /handbrake iti ia fancyangle si daca o misti seteaza fancyangle asa "este" doar ca in loc sa faca fancyangle al meu il face 0. Ero(area / rile) / warning-(ul / urile): 0 Liniile de cod / sursa / script-ul: if(!engineOn[GetPlayerVehicleID(playerid)]) { new coche = GetPlayerVehicleID(playerid); new nombre[MAX_PLAYER_NAME], string_freno[128], partes[7]; GetPlayerName(playerid, nombre, sizeof(nombre)); if(FrenodeMano[coche] == 1) { FrenodeMano[coche] = 0; if(idioma == 0) format(string_freno, sizeof(string_freno), "* %s took the hand brake the vehicle.", nombre); if(idioma == 1) format(string_freno, sizeof(string_freno), "* %s took the hand brake the vehicle.", nombre); ProxDetector(30.0, playerid, string_freno, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE); GetVehicleParamsEx(coche, partes[0], partes[1], partes[2], partes[3], partes[4], partes[5], partes[6]); SetVehicleParamsEx(coche,VEHICLE_PARAMS_OFF, partes[1], partes[2], partes[3], partes[4], partes[5], partes[6]); return 1; } if(FrenodeMano[coche] == 0) { FrenodeMano[coche] = 1; GetVehiclePos(coche, VehFrenoPOS[coche][0], VehFrenoPOS[coche][1], VehFrenoPOS[coche][2]); GetVehicleZAngle(coche, VehFrenoPOS[coche][3]); SetVehicleVelocity(coche, 0, 0, 0); if(idioma == 0) format(string_freno, sizeof(string_freno), "* %s put the hand brake the vehicle.", nombre); if(idioma == 1) format(string_freno, sizeof(string_freno), "* %s put the hand brake the vehicle.", nombre); ProxDetector(30.0, playerid, string_freno, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE); GetVehicleParamsEx(coche, partes[0], partes[1], partes[2], partes[3], partes[4], partes[5], partes[6]); SetVehicleParamsEx(coche,VEHICLE_PARAMS_OFF, partes[1], partes[2], partes[3], partes[4], partes[5], partes[6]); return 1; } } else { GameTextForPlayer(playerid, "Opreste motorul!", 1000, 1); } si aici public OnUnoccupiedVehicleUpdate(vehicleid, playerid, passenger_seat) { if(FrenodeMano[vehicleid] == 1) { GetVehiclePos(playerid, VehComprobar[vehicleid][0], VehComprobar[vehicleid][1], VehComprobar[vehicleid][2]); GetVehicleZAngle(playerid, VehComprobar[playerid][3]); if(VehComprobar[vehicleid][0] == VehFrenoPOS[vehicleid][0] || VehComprobar[vehicleid][1] == VehFrenoPOS[vehicleid][1] || VehComprobar[vehicleid][2] == VehFrenoPOS[vehicleid][2]|| VehComprobar[vehicleid][3] == VehFrenoPOS[vehicleid][3]) return 1; SetVehiclePos(vehicleid, VehFrenoPOS[vehicleid][0], VehFrenoPOS[vehicleid][1], VehFrenoPOS[vehicleid][2]); SetVehicleZAngle(vehicleid, VehComprobar[playerid][3]); } return 1; } Imagini / Video (optional):- Ati incercat sa rezolvati singur?: am incercat sa pun dinou sa imi ia fanciangle si sa il seteze dar nu a mai mers deloc...
-
if(strcmp(cmd, "/setkm", true) == 0) { new car = GetPlayerVehicleID(playerid); tmp = strtok(cmdtext, idx); if(!strlen(tmp) && PlayerInfo[playerid][pAdmin] >= 3) { SendClientMessage(playerid, COLOR_GREY, "/setkm [km]"); return 1; } if(IsPlayerInAnyVehicle(playerid)) { new dammount; dammount = strval(tmp); VehicleKM[car] += dammount; SendClientMessage(playerid, COLOR_GREY, "Changed"); ProportionalUpdate(1, idx); } else { SendClientMessage(playerid, COLOR_GRAD1, " Nu esti in masina!"); return 1; } nu merge Am rezolvat am facut asa: if(strcmp(cmd, "/setkm", true) == 0) { new car = GetPlayerVehicleID(playerid); tmp = strtok(cmdtext, idx); if(!strlen(tmp) && PlayerInfo[playerid][pAdmin] >= 3) { SendClientMessage(playerid, COLOR_GREY, "/setkm [km]"); return 1; } if(IsPlayerInAnyVehicle(playerid)) { new dammount; dammount = strval(tmp); VehicleKM[car] = dammount; SendClientMessage(playerid, COLOR_GREY, "Changed"); ProportionalUpdate(1, idx); } else { SendClientMessage(playerid, COLOR_GRAD1, " Nu esti in masina!"); return 1; } }
-
if(strcmp(cmd, "/setkm", true) == 0) { ProportionalUpdate(1, idx); new car = GetPlayerVehicleID(playerid); tmp = strtok(cmdtext, idx); if(!strlen(tmp) && PlayerInfo[playerid][pAdmin] >= 3) { SendClientMessage(playerid, COLOR_GREY, "/setkm [km]"); return 1; } if(IsPlayerInAnyVehicle(playerid)) { new dammount; dammount = strval(tmp); CarInfo[car][KM] += dammount; SendClientMessage(playerid, COLOR_GREY, "Changed"); } else { SendClientMessage(playerid, COLOR_GRAD1, " Nu esti in masina!"); return 1; } } nu merge