[Pomoc]Server

Započeo PROXY, Februar 12, 2012, 17:35:57 POSLE PODNE

prethodna tema - sledeća tema

0 članova i 1 gost pregledaju ovu temu.

Skripta koju koristim:StreetStories
Detaljan opis problema:kada god neko ulazi na server server se blokira i posle logina tog igraca serveer se unblokira da li znate u cemu je problem :(
Dio skripte://
Neke slike/video za lakse dobivanje pomoci(neobavezno)://

?Xavier?


Pa kad bi nam objasnio malo više u čemu je problem možda bi mogli nešta riješiti.Kako to misliš "blokira se server"?


Evo ovako Opsirnije kada bilo koji igrac ulazi na server ostali igracima zabaguje server kao da se restartovaoo ili nesto drugo i kada se igrac spawnuje onda se odblokira isto se ponavlja i kada drugi igraci ulaze!  >:(

Citat: [NG]Serano ^.- poslato Februar 12, 2012, 17:39:38 POSLE PODNE
Evo ovako Opsirnije kada bilo koji igrac ulazi na server ostali igracima zabaguje server kao da se restartovaoo ili nesto drugo i kada se igrac spawnuje onda se odblokira isto se ponavlja i kada drugi igraci ulaze!  >:(

Nebih znao rijesiti taj problem ali mislim da bi trebao nesta uraditi u OnPlayerConnect ili OnPlayerLogin OnPlayerSpawn postaj nam to ali ipak nisam siguran jer nezz ni ja to rijesiti.

public OnPlayerLogin(playerid,password[])
{
new tmp2[128];
    new string2[64];
new playername2[MAX_PLAYER_NAME];
new playernamesplit[3][MAX_PLAYER_NAME];
    GetPlayerName(playerid, playername2, sizeof(playername2));
split(playername2, playernamesplit, '_');
format(string2, sizeof(string2), "users/%s.ini", playername2);
new File: UserFile = fopen(string2, io_read);
if ( UserFile )
{
    new PassData[128];
    new keytmp[128], valtmp[128];
    fread( UserFile , PassData , sizeof( PassData ) );
    keytmp = ini_GetKey( PassData );
    if( strcmp( keytmp , "Key" , true ) == 0 )
{
valtmp = ini_GetValue( PassData );
strmid(PlayerInfo[playerid][pKey], valtmp, 0, strlen(valtmp)-1, 255);
}
if(strcmp(PlayerInfo[playerid][pKey],password, true ) == 0 )
{
    new key[ 256 ] , val[ 256 ];
    new Data[ 256 ];
    while ( fread( UserFile , Data , sizeof( Data ) ) ) {

[/code]ublic OnPlayerSpawn(playerid)
{


   TextDrawShowForPlayer(playerid, Poruke);
   TextDrawShowForPlayer(playerid, ServerPoruke);
    TextDrawShowForPlayer(playerid, Textdraw60);
   TextDrawShowForPlayer(playerid, Textdraw61);
   TextDrawShowForPlayer(playerid, Textdraw62);
   TextDrawShowForPlayer(playerid, Textdraw63);
   TextDrawShowForPlayer(playerid, Textdraw64);
   TextDrawShowForPlayer(playerid, Textdraw65);
   TextDrawShowForPlayer(playerid, Textdraw66);
   TextDrawShowForPlayer(playerid, Textdraw67);
   TextDrawShowForPlayer(playerid, Textdraw68);
   TextDrawShowForPlayer(playerid, Textdraw69);
   TextDrawShowForPlayer(playerid, Textdraw70);
   TextDrawShowForPlayer(playerid, Textdraw71);
   TextDrawShowForPlayer(playerid, Textdraw72);
   TextDrawShowForPlayer(playerid, Vreme);
    TextDrawShowForPlayer(playerid, Datum);
   




   InitLockDoors(playerid);
   STDPlayer[playerid] = 0;
   gTeam[playerid] = PlayerInfo[playerid][pTeam];
   AntiDeAMX();
   SetPVarInt(playerid, "Krepalo [cenzura]", 1);
  if(MedicBill[playerid] == 1 && PlayerInfo[playerid][pJailed] == 0 && PlayerPaintballing[playerid] == 0)
      {
          if(FirstSpawn[playerid] != 1)
          {
             //new string[256];
            GivePlayerMoney(playerid,-200);
            MedicBill[playerid] = 0;
            MedicTime[playerid] = 0;
            NeedMedicTime[playerid] = 0;
            SetPlayerToTeamColor(playerid);
            SetPlayerPos(playerid,1178.8889,-1323.5004,14.1423);
            SetPlayerFacingAngle(playerid, 0);
            SetPlayerInterior(playerid,0);
            PlayerInfo[playerid][pInt] = 0;
              /*SetPlayerHealth(playerid, 50.0);
            PlayerInfo[playerid][pDeaths] += 1;
             SetPlayerInterior(playerid, 3);
             PlayerInfo[playerid][pInt] = 3;
              rand = random(sizeof(gMedicSpawns));
            SetPlayerPos(playerid, gMedicSpawns[rand][0], gMedicSpawns[rand][1], gMedicSpawns[rand][2]); // Warp the player
            SetPlayerFacingAngle(playerid, 0);
              TogglePlayerControllable(playerid, 0);
              GameTextForPlayer(playerid, "~n~~n~~n~~n~~n~~n~~n~~n~~n~~w~You need to rest now ...", 30000, 3);
                JustDied[playerid] = 1;
              MedicTime[playerid] = 1;
              ApplyAnimation(playerid, "CRACK", "crckdeth2", 4.0, 1, 0, 0, 0, 0);
              if(PlayerInfo[playerid][pDonateRank] > 0)
              {
                  NeedMedicTime[playerid] = 30;
              }
              else
              {
                 NeedMedicTime[playerid] = 40;
            }*/
             return 1;
         }
      }