/exit & /enter bugg?
#1

Hello, i did make what at command enter and exit but it don't show the text :S
maybe you know the bugg?

pawn Код:
if (strcmp(cmd, "/enter", true) ==0)
{
    if(IsPlayerInRangeOfPoint(playerid, 4, HouseInfo[playerid][hEntrancex], HouseInfo[playerid][hEntrancey], HouseInfo[playerid][hEntrancez]))
    {
        SendClientMessage(playerid, COLOR_RED, "Press Enter or F to enter your house!");
    }
    if(IsPlayerInRangeOfPoint(playerid, 6, BusinessInfo[playerid][bEntrancex], BusinessInfo[playerid][bEntrancey], BusinessInfo[playerid][bEntrancez]))
    {
        SendClientMessage(playerid, COLOR_RED, "Press Enter or F to enter your Business!");
    }
    return 1;
}
pawn Код:
if (strcmp(cmd, "/exit", true) ==0)
{
    if(IsPlayerInRangeOfPoint(playerid, 4, HouseInfo[playerid][hExitx], HouseInfo[playerid][hExity], HouseInfo[playerid][hExitz]))
    {
    SendClientMessage(playerid, COLOR_RED, "Press Enter or F to exit your house!");
    }
    if(IsPlayerInRangeOfPoint(playerid, 6, BusinessInfo[playerid][bExitx], BusinessInfo[playerid][bExity], BusinessInfo[playerid][bExitz]))
    {
        SendClientMessage(playerid, COLOR_RED, "Press Enter or F to exit your Business!");
    }
    return 1;
}
thanks
Reply
#2

That probably means the code doesn't know what you mean by HouseInfo, or HouseInfo is not set properly.
Reply
#3

and if i add delete playerid and change playerid to i

pawn Код:
for(new i=0; i<MAX_HOUSES; i++)
{
pawn Код:
for(new i=0; i<MAX_BUSINESS; i++)
{
Reply
#4

You need to loop through houses.

If you ID is for example 5 then 'HouseInfo[playerid][hEntrancex]' will do 'HouseInfo[5][hEntrancex]'.

Код:
for(new i=0; i<sizeof(HouseInfo); i++)
Reply
#5

it work? but then it spam! me text full
Reply
#6

Quote:
Originally Posted by Silox
it work? but then it spam! me text full
:P
Reply
#7

Bump
Reply
#8

bump
Reply
#9

Quote:
Originally Posted by Silox
bump
Check your virtual world.
Reply
#10

Quote:
Originally Posted by Kartowka
Quote:
Originally Posted by Silox
bump
Check your virtual world.
uh?
Reply


Forum Jump:


Users browsing this thread: