Need your help! (Dialogs)
#1

The problem is - Dialogs dsnt show up probably. It takes like 5-20 seconds to wait. can anybody help me plzz?

screen


code

pawn Код:
else if(dialogid == 6)
    {
        if(response)
        {
            new Float:oldposx, Float:oldposy, Float:oldposz;
            GetPlayerName(playerid, playername, sizeof(playername));
            GetPlayerPos(playerid, oldposx, oldposy, oldposz);
            for(new h = 0; h < sizeof(HouseInfo); h++)
            {
                if(PlayerToPoint(2.0, playerid, HouseInfo[h][hEntrancex], HouseInfo[h][hEntrancey], HouseInfo[h][hEntrancez]) && HouseInfo[h][hOwned] == 1 &&  HouseInfo[h][hRentabil] == 1)
                {
                    if(PlayerInfo[playerid][pPhousekey] != 255 && strcmp(playername, HouseInfo[PlayerInfo[playerid][pPhousekey]][hOwner], true) == 0)
                    {
                        SendClientMessage(playerid, COLOR_WHITE, "   Вы уже имеете дом, /sellhouse если Вы хотите арендовать этот.");
                        return 1;
                    }
                    if(GetPlayerMoney(playerid) > HouseInfo[h][hRent])
                    {
                        PlayerInfo[playerid][pPhousekey] = h;
                        GivePlayerMoney(playerid,-HouseInfo[h][hRent]);
                        HouseInfo[h][hTakings] = HouseInfo[h][hTakings]+HouseInfo[h][hRent];
                        PlayerPlayMusic(playerid);
                        SetPlayerInterior(playerid,HouseInfo[h][hInt]);
                        SetPlayerPos(playerid,HouseInfo[h][hExitx],HouseInfo[h][hExity],HouseInfo[h][hExitz]);
                        GameTextForPlayer(playerid, "~w~Welcome Home~n~You can exit at any time by moving to this door and typing /exit", 5000, 3);
                        PlayerInfo[playerid][pInt] = HouseInfo[h][hInt];
                        PlayerInfo[playerid][pLocal] = h;
                        SendClientMessage(playerid, COLOR_WHITE, "Поздравления, Вы можете войти и выйти здесь в любое время.");
                        SendClientMessage(playerid, COLOR_WHITE, "Напечатайте /help чтобы рассмотреть информацию.");
                        OnPlayerUpdate_GF(playerid);
                        return 1;
                    }
                    else
                    {
                        SendClientMessage(playerid, COLOR_WHITE, "У Вас нет наличных денег для этого");
                        return 1;
                    }
                }
            }
        }
    }
    else if(dialogid == 7)
    {
        if(response)
        {
            new Float:oldposx, Float:oldposy, Float:oldposz;
            GetPlayerName(playerid, playername, sizeof(playername));
            GetPlayerPos(playerid, oldposx, oldposy, oldposz);
            for(new h = 0; h < sizeof(HouseInfo); h++)
            {
                if(PlayerToPoint(2.0, playerid, HouseInfo[h][hEntrancex], HouseInfo[h][hEntrancey], HouseInfo[h][hEntrancez]) && HouseInfo[h][hOwned] == 0)
                {
                    if(PlayerInfo[playerid][pLevel] < HouseInfo[h][hLevel])
                    {
                        format(string, sizeof(string), "   Вы должны быть Уровнем %d, чтобы купить это !", HouseInfo[h][hLevel]);
                        SendClientMessage(playerid, COLOR_GRAD5, string);
                        return 1;
                    }
                    if(PlayerInfo[playerid][pPhousekey] != 255 && strcmp(playername, HouseInfo[PlayerInfo[playerid][pPhousekey]][hOwner], true) == 0)
                    {
                        SendClientMessage(playerid, COLOR_WHITE, "   Вы уже имеете дом, печатаете /sellhouse если Вы хотите купить этот !");
                        return 1;
                    }
                    if(GetPlayerMoney(playerid) > HouseInfo[h][hValue])
                    {
                        PlayerInfo[playerid][pPhousekey] = h;
                        HouseInfo[h][hOwned] = 1;
                        GetPlayerName(playerid, sendername, sizeof(sendername));
                        strmid(HouseInfo[h][hOwner], sendername, 0, strlen(sendername), 255);
                        GivePlayerMoney(playerid,-HouseInfo[h][hValue]);
                        PlayerPlayMusic(playerid);
                        SetPlayerInterior(playerid,HouseInfo[h][hInt]);
                        SetPlayerPos(playerid,HouseInfo[h][hExitx],HouseInfo[h][hExity],HouseInfo[h][hExitz]);
                        GameTextForPlayer(playerid, "~w~Welcome Home~n~You can exit at any time by moving to this door and typing /exit", 5000, 3);
                        PlayerInfo[playerid][pInt] = HouseInfo[h][hInt];
                        PlayerInfo[playerid][pLocal] = h;
                        SendClientMessage(playerid, COLOR_WHITE, "Поздравления, Вы можете войти и выйти здесь в любое время !");
                        SendClientMessage(playerid, COLOR_WHITE, "Напечатайте /help чтобы рассмотреть информацию !");
                        DateProp(playerid);
                        OnPropUpdate();
                        OnPlayerUpdate_GF(playerid);
                        return 1;
                    }
                    else
                    {
                        SendClientMessage(playerid, COLOR_WHITE, "У вас не хватает денег.");
                        return 1;
                    }
                }
            }
        }
    }
Reply
#2

Next time use [pawn] ..... [/pawn


I guess you have something wrong with loop
Reply
#3

Quote:

Next time use [pawn] ..... [/pawn

oke

Quote:

I guess you have something wrong with loop

what is loop? can u explain plz
Reply
#4

Your prob is that it shows dialog slow or that you can't buy a house? or
Reply
#5

Yes it shows dialog very slow. takes about 3-10 seconds
Reply
#6

Maybe it's lag. If you're running this server off of your home connection, it will definitely lag.
Reply
#7

Quote:
Originally Posted by RealCop228
Посмотреть сообщение
Maybe it's lag. If you're running this server off of your home connection, it will definitely lag.
Running off an low end computer also will cause ingame lagg.
Reply
#8

Yes Low End computer that cant support running the feed,
you have to have a rather bad computer not be able to host.
But you need a good connection rate otherwise its just "not" going to happen.
Reply
#9

its lan

anyway 2night im gonna buy a host and we'll see lagg or no
Reply
#10

Hosts can still have lag depends on what there DEDI's are like etc.
But it wont lagg like your's.
And yeah hopfully it will be fine for you, some hosts can be bad though but nothing into the diffiency range of your old one.
Good luck.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)