Jump to content

Stark.sys

Membru
  • Posts

    113
  • Joined

  • Last visited

  • Days Won

    2

Everything posted by Stark.sys

  1. CMD:wisper(playerid, params[]) { new string[128],id,mess[250],giveplayer[25],sendername[25]; if(PlayerInfo[playerid][pLevel] < 2) return SendClientMessage(playerid, COLOR_WHITE,"{FFB870}You must be level 2 to use /w(isper)."); if(sscanf(params, "us[250]",id,mess)) return SCM(playerid, COLOR_WHITE, "{B8DBFF}Synthax: /w <Name/Playerid> <Message>"); if(IsPlayerConnected(id) != 1) return SendClientMessage(playerid, COLOR_WHITE, "Acest utilizator nu este conectat !"); if(id != INVALID_PLAYER_ID) { if(GetDistanceBetweenPlayers(playerid,id) > 5) return SCM(playerid,COLOR_WHITE,"{FFFFCC}This player is not near you."); if(Spectate[id] != 255) return SCM(playerid, COLOR_WHITE, "{FFFFCC}This player is not near you."); if(HidePM[id] > 0) return SendClientMessage(playerid, COLOR_WHITE,"{FFB870}This player doesn't allow whispers."); if(id == playerid) return SendClientMessage(playerid, COLOR_WHITE,"{FFB870}You can not send a message to yourself."); GetPlayerName(playerid, sendername, sizeof(sendername)), GetPlayerName(id, giveplayer, sizeof(giveplayer)); format(string, sizeof(string), "%s whispers: %s", sendername, mess); SendClientMessage(id, COLOR_YELLOW, string); format(string, sizeof(string), "Whisper to %s: %s", giveplayer, mess); SendClientMessage(playerid, COLOR_YELLOW, string); if(stringContainsIP(mess)) { format(string, sizeof(string), "{f03337}Warning: %s(%d) typed %s.", sendername,playerid,mess); ABroadCast(COLOR_WHITE, string, 1); } for(new i = 0; i < sizeof(Filter); i++) { if(strfind(mess, Filter, true) != -1) { format(string, sizeof(string), "{f03337}Warning: %s(%d) typed %s.", sendername,playerid,mess); ABroadCast(COLOR_WHITE,string,1); } } } return 1; } dar `Filter` asta unde il ai definit ?
  2. for(new d = 1; d < sizeof(Filter); d++) { // your code }
  3. for(new d; d { aici e eroarea !
  4. Astazi o sa postez ce am facut, scuze dar am si eu o viata personala. http://pastebin.com/WXVuZSdj - .pwn http://pastebin.com/Lz5wkzn0 - .sql
  5. Pentru payday. http://pastebin.com/mi8HYqU7 sper sa fie cea ce doresti.
  6. e ceva bun ? P.S: Sunt incepator http://pastebin.com/qytv7d9b si pt phpmyadmin http://pastebin.com/NPwkApUm
  7. public OnPlayerSpawn(playerid) { SetPlayerInterior(playerid,0); TogglePlayerClock(playerid,0); SetTimerEx("spawntime", 2000, 0, "i", playerid); GameTextForPlayer(playerid, "~b~Please ~r~Waitn ~y~for spawned", 2000, 4); return 1; } forward spawntime(playerid); public spawntime(playerid) { SetPlayerCameraPos(playerid, 349.8070, 1670.6421, 108.7149); SetPlayerCameraLookAt(playerid, 349.2492, 1671.4767, 108.3148); SetSpawnInfo(playerid, 0, 0, 349.8070, 1670.6421, 108.7149, 0,0,0,0,0,0); // --- SpawnPlayer(playerid); return 1; }
  8. atunci e un .inc sau plugin de vina !
  9. pune sub #include <nume last include> native mysql_log(E_LOGLEVEL:loglevel = LOG_ERROR | LOG_WARNING, E_LOGTYPE:logtype = LOG_TYPE_TEXT); native mysql_connect(const host[], const user[], const database[], const password[], port = 3306, bool:autoreconnect = true, pool_size = 2); native mysql_errno(connectionHandle = 1); native mysql_format(connectionHandle, output[], len, format[], {Float,_}:...); native mysql_tquery_inline(connHandle, query[], callback:Callback, format[], {Float,_}:...); //y_inline // Cache functions native cache_get_data(&num_rows, &num_fields, connectionHandle = 1); native cache_get_row_count(connectionHandle = 1); native cache_get_field_count(connectionHandle = 1); native cache_get_field_name(field_index, destination[], connectionHandle = 1, max_len = sizeof(destination));
  10. adica gen /upgrade daca ai 6 ore sa poti face up ?
  11. Uite ceva aici ! http://forum.sa-mp.com/showthread.php?t=370378 sau http://forum.sa-mp.com/showthread.php?t=166509
  12. #include <sscanf2> // Y_Less #include <zcmd> // ZeeX stock GetN(playerid) { new n[32]; GetPlayerName(playerid, n, 32); return n; } new WarnLevel, WarnReason[32]; CMD:warn(playerid, params[]) { if(PlayerInfo[playerid][pAdmin] >= 3 || IsPlayerAdmin(playerid)) // Admin level 3+ & Admin Rcon login. { new id; if(sscanf(params, "dis[32]", id, WarnLevel, WarnReason)) return SendClientMessage(playerid, -1, "Use: /warn <Playerid/PartOfName> <Warn Point> <Reason>"); if(IsPlayerConnected(id) != 1 || id != INVALID_PLAYER_ID) return SendClientMessage(playerid, -1, "Acest player nu este conectat sau nu exista."); if(id == playerid) return SendClientMessage(playerid, -1, "Nu iti poti da warn singur."); PlayerInfo[playerid][pWarn] += WarnLevel; new s[132]; format(s, sizeof(s), "Adminul %s, ia dat lui %s [%i] puncte warn. Motiv: %s", GetN(playerid), GetN(id), WarnLevel, WarnReason); SendClientMessageToAll(0xD6802CFF, s); SendClientMessage(playerid, -1, "Ai primit Warn."); } else return SendClientMessage(playerid, -1, "Nu esti admin, sau nu ai level necesar."); return 1; } CMD:unwarn(playerid, params[]) { if(PlayerInfo[playerid][pAdmin] >= 3 || IsPlayerAdmin(playerid)) // Admin level 3+ & Admin Rcon login. { new id, uwn, reason[32]; if(sscanf(params, "dis[32]", id, uwn, reason)) return SendClientMessage(playerid, -1, "Use: /unwarn <Playerid/PartOfName> <Warn Point> <Reason>"); if(IsPlayerConnected(id) != 1 || id != INVALID_PLAYER_ID) return SendClientMessage(playerid, -1, "Acest player nu este conectat sau nu exista."); PlayerInfo[playerid][pWarn] -= uwn; new s[132]; format(s, sizeof(s), "Adminul %s, ia dat lui %s [%i] puncte unwarn. Motiv: %s", GetN(playerid), GetN(id), uwn, reason); SendClientMessageToAll(0xD6802CFF, s); SendClientMessage(playerid, -1, "Ai primit Unwarn."); } else return SendClientMessage(playerid, -1, "Nu esti admin, sau nu ai level necesar."); return 1; } CMD:kick { if(PlayerInfo[playerid][pAdmin] >= 1 || IsPlayerAdmin(playerid)) // Admin level 3+ & Admin Rcon login. { new id; if(sscanf(params, "d", id)) return SendClientMessage(playerid, -1, "Use: /kick <Playerid/PartOfName>"); if(IsPlayerConnected(id) != 1 || id != INVALID_PLAYER_ID) return SendClientMessage(playerid, -1, "Acest player nu este conectat sau nu exista."); Kick(id); new s[132]; format(s, sizeof(s), "Adminul %s, ia dat lui %s kick.", GetN(playerid), GetN(id)); SendClientMessageToAll(0xD6802CFF, s); } else return SendClientMessage(playerid, -1, "Nu esti admin, sau nu ai level necesar."); } /* Pe nume: /warn Player 2 Limbaj Vulgar. = Player - Celui ncare dai warn, 2 - punctele de warn, limbaj - motivul warn-ului.. /unwarn Player 1 Nu stiu motiv ; Pe ID: /warn 0 2 Limbaj Vulgar // 0 - 1000 /unwarn 0 1 Nu stiu motiv ; Kick: /kick Nume/ID */ ce zici iti plac aceste comenzi ?
  13. public OnPlayerSpawn(playerid) { SetPlayerInterior(playerid,0); TogglePlayerClock(playerid,0); SetTimerEx("spawntime", 2000, 1, "i", playerid); return 1; } forward spawntime(playerid); public spawntime(playerid) { SetPlayerCameraPos(playerid, 349.8070, 1670.6421, 108.7149); SetPlayerCameraLookAt(playerid, 349.2492, 1671.4767, 108.3148); GameTextForPlayer(playerid, "~b~Please ~r~Waitn ~y~for spawned", 2000, 4); SpawnPlayer(playerid); return 1; }
  14. Incearca asa #define SkinChange 1337 new SkinID, strin[256]; public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]) { if(dialogid == SkinChange) { if(response) { SetPlayerSkin(playerid, SkinID); format(strin, 256, "Skin Info: Ti-ai setat ski-ul cu id %i.", SkinID); SendClientMessage(playerid, -1, strin); } } return 1; } CMD:skin(playerid, params[]) { if(GetPVarInt(playerid, "PlayerInDM") == 0) { new skin, string[128]; if(sscanf(params, "i", skin)) return SendClientMessage(playerid, COLOR_RED, "Use: {FFFFFF}/skin [skinid]"); SkinID = skin; if(skin < 300 && skin >= 0) return SendClientMessage(playerid, red, "Server: This skin does not exist!"); format(string, 128, "Server: Skin changed to the id %d, have fun", skin); SendClientMessage(playerid, COLOR_LIGHTBLUE, string); SetPlayerSkin(playerid, skin); } if(GetPVarInt(playerid, "PlayerInDM") == 1) { new ints[256]; strcat(ints, "{00FF00}Please insert below the {FF0000}Skin ID{00FF00} which you want to use!"); ShowPlayerDialog(playerid, SkinChange, DIALOG_STYLE_INPUT, "{CCCCCC}MySkin", string, "Ok", "Cancel"); } return 1; }
  15. MySQL r38 e usor, mai greu e cu cache. Zi cateva comezni si poate ti le fac eu daca pot
  16. Cam ce comenzi ai vrea sa aiba ? Si The Row nu cred ca face el asa ceva.
  17. Pune asa: Edit: vezi asa stock aCreateThing(playerid, thingid, orderid) { new Float:XPOS[4], Vehicle[MAX_VEHICLES]; GetPlayerPos(playerid, XPOS[0], XPOS[1], XPOS[2]); GetPlayerFacingAngle(playerid, XPOS[3]); if(thingid != 597) { Vehicle[orderid] = AddStaticVehicleEx(thingid, XPOS[0], XPOS[1], XPOS[2]+3, XPOS[3], random(126), random(126), 40); } else { Vehicle[orderid] = AddStaticVehicleEx(thingid, XPOS[0], XPOS[1], XPOS[2]+3, XPOS[3], 0, 1, 40); } PutPlayerInVehicle(playerid, Vehicle[orderid], 0); TogglePlayerControllable(playerid, true); return 1; }
  18. Eu am spus ca si eu am avut o problema asemanatoare si de asta, scz daca am postat aiurea
  19. Aceiasi problema o aveam si eu vezi sa nu ai prin mysql la update Nume nume2 gen "Admin Level" daca e asa iti da eroarea aia .
  20. Problemă întâlnită (descriere): Crashed wile samp :-? Ero(area / rile) / warning-(ul / urile): Liniile de cod / sursa / script-ul: public Vehicles(vehicleid) { new strquery[256]; gVehInfo[vehicleid][vID] = cache_insert_id(c); mysql_format(c, strquery, sizeof(query), "SELECT * FROM `vehicle` WHERE `ID`='%i'", vehicleid); mysql_query(c, strquery, true); return 1; } OnGameModeInit: mysql_pquery(c, "SELECT * FROM `vehicle`", "OnVehicleLoad", ""); SetTimer("Vehicles", 100, 0); Imagini / Video (optional): - Aţi încercat să rezolvaţi singur?: Da, daca scot mysql_format (); nu mai da crash-u :-? PS: Erori noi ...
  21. Ce versiune mysql folosesti ? Ce phpmyadmin ai ? Ce plugin mysql pe samp ai ?
  22. Descriere tutorial: Salut, as dori si eu un tutorial, link, fs, pentru un sistem de factiuni dinamice mysql R35+ sau R38+. Am gasit ceva pe sa-mp.com dar nu functioneaza sau nu stiu eu sa il fac.
×
×
  • 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.