Jump to content

LaZ

V.I.P
  • Posts

    531
  • Joined

  • Last visited

  • Days Won

    5

Everything posted by LaZ

  1. Incearca asa: else { format(string, sizeof(string), "Command %s doesnt exist. Try /commands OR /help.", cmdtext); SendClientMessage(playerid, COLOR_RED, string); } return 1;
  2. Inca un script foarte bun! Tot asa! ;)
  3. Cateodata nu-mi merge linkul. Ar fi mai bine daca ai pune mai multe link-uri de downlodare.
  4. LaZ

    Problema x, y si z

    Am auzit de /save. Si ?
  5. Nu prea cred. Toate fisierele .inc coincid cu toate scripturile. Depinde de script.
  6. LaZ

    [GM]NRG Race

    Am reusit sa rezolv bug-urile. Fa un update la postul tau. /* ------------------------------------------------------------------- --------------------------FARSE------------------------------------ ------------------------------------------------------------------- */ #include <a_samp> #pragma tabsize 0 #define COLOR_BLUE 0x000ecaAA #define COLOR_GREY 0xAFAFAFAA #define COLOR_YELLOW 0xFFFF00AA new gProgressTwo[MAX_PLAYERS]; new onceTwo[MAX_PLAYERS]; new gPositionTwo; new gCountdowntimerTwo; new gCountdownTwo; new gTimeTwo; new gTimerTwo; new gRaceStillInProgressTwo; new gCheckTimeTwo; #define MAX_CHECKPOINTSTWO 35 new Float:gRaceCheckpointsTwo[MAX_CHECKPOINTSTWO][10] = { {2465.968994,-1660.231323,12.276421,23.0},//1 {2413.828369,-1658.252686,12.382813,23.0},//2 {2303.655029,-1659.450439,13.476613,23.0},//3 {2196.926758,-1639.022217,14.312500,23.0},//4 {1996.422363,-1622.989136,12.546875,23.0},//5 {1932.648560,-1617.910400,12.539082,23.0},//7 {1853.574829,-1613.469360,12.390608,23.0},//8 {1826.353027,-1615.203979,12.385198,23.0},//9 {1821.600464,-1575.916260,12.355615,23.0},//10 {1828.757690,-1554.067627,12.370012,23.0}, {1843.231934,-1482.535522,12.370775,23.0}, {1898.395386,-1460.637817,12.382813,23.0}, {1959.481445,-1449.564453,12.549465,23.0}, {1962.781128,-1403.960449,12.577248,23.0}, {1897.272583,-1357.397461,12.509418,23.0}, {2052.366211,-1337.951904,22.820313,23.0},//10 {2170.658936,-1341.698242,22.828125,23.0},//11 {2236.743896,-1342.619263,30.271870,23.0},//12 {2244.935059,-1383.205811,22.832008,23.0},//13 {2279.246826,-1373.169434,23.000313,23.0},//14 {2279.512207,-1351.971069,28.148438,23.0},//14 {2295.099609,-1354.380859,28.148438,23.0},//15 {2296.039307,-1373.999756,23.043247,23.0},//16 {2327.042480,-1384.776489,22.847219,23.0},//16 {2342.080322,-1421.376099,22.828125,23.0},//17 {2311.069092,-1484.864502,22.411690,23.0},//18 {2297.377930,-1524.363159,25.875000,23.0},//19 {2343.977783,-1569.009033,22.838345,23.0},//20 {2344.318115,-1625.633423,16.691774,23.0},//21 {2344.472656,-1681.376221,12.359398,23.0},//22 {2349.645752,-1731.509888,12.382813,23.0},//23 {2370.389160,-1729.067749,12.382813,23.0},//24 {2433.280273,-1730.795410,12.546181,23.0},//25 {2478.954834,-1724.184326,12.554682,23.0},//25 {2484.437256,-1674.049194,12.335947,23.0}//35 }; main() { print("\n----------------------------------"); print(" NRG RACE By Farse"); print(" version 1.0:"); print(" NRG RACE INTERATIVITY"); print("----------------------------------\n"); } public OnGameModeInit() { print("Gamemode successfully loaded"); SetGameModeText("NRG RACE"); AddStaticVehicle(522,2504.912,-1665.003,13.052,89.0,-1,-1); AddStaticVehicle(522,2505.005,-1666.320,13.052,89.0,-1,-1); AddStaticVehicle(522,2505.196,-1667.542,13.052,89.0,-1,-1); AddStaticVehicle(522,2505.068,-1668.704,13.052,89.0,-1,-1); AddStaticVehicle(522,2505.154,-1670.169,13.052,89.0,-1,-1); AddStaticVehicle(522,2504.635,-1661.704,13.052,89.0,-1,-1); AddStaticVehicle(522,2502.000,-1660.175,13.052,89.0,-1,-1); AddStaticVehicle(522,2503.160,-1671.855,13.052,89.0,-1,-1); AddPlayerClass(124,2504.221,-1663.556,13.052,158.2551,0,0,0,0,0,0); // gTimeTwo = 0; return 1; } public OnPlayerRequestClass(playerid, classid) { SetPlayerInterior(playerid,0); SetPlayerPos(playerid,2504.221,-1663.556,13.052); SetPlayerFacingAngle(playerid, 158.2551); SetPlayerCameraPos(playerid,2504.221,-1663.556,13.052); SetPlayerCameraLookAt(playerid,2504.221,-1663.556,13.052); return 1; } public OnGameModeExit() { print("Gamemode successfully unloaded"); return 1; } public OnPlayerConnect(playerid) { new playername[256]; GetPlayerName(playerid,playername,sizeof(playername)); new welcomemsg[256]; format(welcomemsg,sizeof(welcomemsg),"Welcome %s to the NRG RACE mode!",playername); SendClientMessage(playerid,COLOR_YELLOW,welcomemsg); return 1; } public OnPlayerDisconnect(playerid) { printf("OnPlayerDisconnect(%d)", playerid); return 1; } public OnPlayerSpawn(playerid) { SetPlayerInterior(playerid,0); gProgressTwo[playerid] = 0; SetPlayerCheckpoint(playerid,gRaceCheckpointsTwo[0][0],gRaceCheckpointsTwo[0][1],gRaceCheckpointsTwo[0][2],gRaceCheckpointsTwo[0][3]); return 1; } public OnPlayerDeath(playerid, killerid, reason) { if(killerid == INVALID_PLAYER_ID) { SendDeathMessage(INVALID_PLAYER_ID,playerid,reason); } else { SendDeathMessage(killerid,playerid,reason); SetPlayerScore(killerid,GetPlayerScore(killerid)+1); } return 1; } public OnPlayerEnterCheckpoint(playerid) { DisablePlayerCheckpoint(playerid); if (gProgressTwo[playerid] == MAX_CHECKPOINTSTWO-1){ gPositionTwo++; new playername[MAX_PLAYER_NAME]; new finishmessage[256]; new finishtime[256]; new Float:fMinutes; new Minutes; new Seconds; if (gTimeTwo != 0) { fMinutes = gTimeTwo/60; Minutes = floatround(fMinutes, floatround_floor); Seconds = gTimeTwo-(Minutes*60); format(finishtime, sizeof(finishtime),"Ai terminat cursa in %d minute %d secunde.", Minutes, Seconds); SendClientMessage(playerid, COLOR_GREY, finishtime); } GetPlayerName(playerid, playername, MAX_PLAYER_NAME); switch (gPositionTwo){ case 1: { format(finishmessage, sizeof(finishmessage),"%s has won the race!", playername); GameTextForAll(finishmessage, 3000, 5); SetPlayerScore(playerid,GetPlayerScore(playerid)+5); } case 2: { format(finishmessage, sizeof(finishmessage),"%s o terminat %d nd", playername, gPositionTwo); GameTextForAll(finishmessage, 3000, 5); SetPlayerScore(playerid,GetPlayerScore(playerid)+4); } case 3: { format(finishmessage, sizeof(finishmessage),"%s o terminat %d rd", playername, gPositionTwo); GameTextForAll(finishmessage, 3000, 5); SetPlayerScore(playerid,GetPlayerScore(playerid)+3); } default: { format(finishmessage, sizeof(finishmessage),"%s o terminat %d th", playername, gPositionTwo); GameTextForAll(finishmessage, 3000, 5); SetPlayerScore(playerid,GetPlayerScore(playerid)+1); } } } if (gProgressTwo[playerid] == 0) { if (onceTwo[playerid] == 0){ SendClientMessage(playerid, COLOR_YELLOW, "Vrei sa incepi cursa?Scrie /STARTRACE pentru a incepe cursa."); onceTwo[playerid] = 1; } gProgressTwo[playerid]=0; } else { gProgressTwo[playerid]++; SetPlayerCheckpoint(playerid,gRaceCheckpointsTwo[gProgressTwo[playerid]][0],gRaceCheckpointsTwo[gProgressTwo[playerid]][1],gRaceCheckpointsTwo[gProgressTwo[playerid]][2],gRaceCheckpointsTwo[gProgressTwo[playerid]][3]); // ml if (gCheckTimeTwo > 10 || gCheckTimeTwo == 0){ KillTimer(gRaceStillInProgressTwo); gCheckTimeTwo=1; gRaceStillInProgressTwo=SetTimer("CheckpointTimer", 1000, 1); } } return 1;} forward GettimerTwo(); public GettimerTwo() { gCountdownTwo--; if (gCountdownTwo >= 1){ new message[256]; format(message, sizeof(message),"%d", gCountdownTwo); GameTextForAll(message, 750, 5); } else { KillTimer(gCountdowntimerTwo); for (new i = 0; i < MAX_PLAYERS; i++) { TogglePlayerControllable(i, 1); } GameTextForAll("~w~GO", 2000, 5); gTimeTwo = 0; KillTimer(gTimerTwo); gTimerTwo=SetTimer("RaceTimer", 1000, 1); } return 1; } forward RaceTimer(); public RaceTimer() { gTimeTwo++; } forward CheckpointTimer(); public CheckpointTimer() { gCheckTimeTwo++; } forward EndGame(); public EndGame(){ GameModeExit(); } public OnVehicleSpawn(vehicleid) { printf("OnVehicleSpawn(%d)", vehicleid); return 1; } public OnVehicleDeath(vehicleid, killerid) { printf("OnVehicleDeath(%d, %d)", vehicleid, killerid); return 1; } public OnPlayerCommandText(playerid, cmdtext[]) { if (strcmp(cmdtext, "/startrace", true)==0) { if (gCheckTimeTwo > 30 || gCheckTimeTwo == 0 || IsPlayerAdmin(playerid) == 1) { gCountdownTwo=6; gPositionTwo = 0; gTimeTwo = 0; SendClientMessageToAll(COLOR_GREY, "Cursa a inceput"); for (new i = 0; i < MAX_PLAYERS; i++) { gProgressTwo[i] = 1; SetPlayerCheckpoint(i,gRaceCheckpointsTwo[1][0],gRaceCheckpointsTwo[1][1],gRaceCheckpointsTwo[1][2],gRaceCheckpointsTwo[1][3]); } KillTimer(gCountdowntimerTwo); gCountdowntimerTwo=SetTimer("GettimerTwo", 1000, 1); } else { //race in progress msg SendClientMessage(playerid, COLOR_YELLOW, "Scuze cursa sa terminat."); } return 1; } if (strcmp(cmdtext, "/rescueme", true)==0) { gProgressTwo[playerid] = 1; SetPlayerCheckpoint(playerid,gRaceCheckpointsTwo[1][0],gRaceCheckpointsTwo[1][1],gRaceCheckpointsTwo[1][2],gRaceCheckpointsTwo[1][3]); SetPlayerPos(playerid,gRaceCheckpointsTwo[0][0],gRaceCheckpointsTwo[0][1],gRaceCheckpointsTwo[0][2]); } if (strcmp(cmdtext, "/help", true)==0) { SendClientMessage(playerid, COLOR_YELLOW, "Scrie /STARTRACE pentru a incepe cursa. SCRIE /RESCUEME dca ai pierdut."); SendClientMessage(playerid, COLOR_YELLOW, "Urmeaza checkponturile pentru a termina cursa."); } // #include <votescript> printf("OnPlayerInfoChange(%d)"); return 1; }
  7. LaZ

    [MAP]Tribute DSK

    OMG nice map !
  8. LaZ

    Complile error

    O sa-ti mearga si daca iti schimbi Windows-ul.
  9. LaZ

    Complile error

    Si poate ai modificat incat iti apar erori. Si iti dispare gf.amx nu .pwn .pwn dispare doar daca il stergi tu.
  10. LaZ

    Complile error

    Iti merge sectiunea Downloaduri ? ???
  11. LaZ

    Complile error

    Nici mie nu-mi merge pagina.. Oricum ai in folderul pawno unde ti serverul.
  12. Mi-am dat seama cu trebuie pus codul, si merge! Si corect ar fi "SeRvEr CoDeD By Farse"
  13. LaZ

    Complile error

    Atunci intra pe www.sa-mp.ro si da click pe sectiunea Dowloaduri si downlodeaza Pawno Scripting Tool. Cand apare eroarea "Unable to compile..." instalati cel mai nou Windows .NET Framework.
  14. Din modul tau mi-a trebuie codul cu 'TextDraw'(ala cu Server Coded by Farse) ;)
  15. Uitate mai sus la primul meu post. Urmareste fiecare pas. Cred ca nu ai pus libmysql.dll unde nu trebuie.
  16. Imi postez aici colectia mea de includes. Download Link.
  17. La inceputul scriptului este asa: #include <a_samp> ... #include <a_sampmysql> Uitate ce include iti trebuie sa compilezi scriptul si ce ai in Include.
  18. LaZ

    [GM]Football

    Mai trebuie sa lucrezi la script. Are bug-uri.
  19. Deci l-ai pus. Ca sa fi sigur intra in pawno.exe si iesi. Intra din nou in script si compileaza-l.
  20. Fisierul a_sampmysql.inc trebuie pus in Pawno \ Includes.
  21. Ca sa te loghezi pe server, trebuie sa-ti faci cont pe un site anume. Parola si nickname-ul registrate pe site vor fi si in joc.
  22. Daca nu instalezi corect plug-in-ul MySQL, atunci nu poti compila scriptul. [*] Trebuie sa downlodezi plug-in-ul MySQL de aici. [*] Ca sa adaugi un plug-in la serverul tau trebuie sa creezi un folder cu numele 'plugins' unde este si samp-server.exe [*] In folderul 'plugins' pui fisierul sampmysql.dll [*] Intri in server.cfg si scrii asa: plugins sampmysql (fara .dll) [*] a_sampmysql.inc se pune in Pawno \ Includes [*] libmysql.dll se pune langa samp-server.exe [*] Intri in GameMode si il compilezi.
  23. LaZ

    Problema x, y si z

    Si in gamemodul meu sunt gangzones, IsPlayerInTurf si timere. Ii un pic de lag.
  24. Da si mie. Pun la filterscripturi si cand intru pe server nu imi merg comenzile ca /help, /credits, etc.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.