[Pomoc]Cyber Kuce Problem

Započeo Retardinjo, April 11, 2011, 18:39:37 POSLE PODNE

prethodna tema - sledeća tema

0 članova i 2 gostiju pregledaju ovu temu.

Skripta:Cyber
Problem: Nekontam sta nevalja sa ovom skriptom da mozes uc u kucu al nemozes izac ?? :S (samo kad ju kupis mozes izac al kad izadjes pa ponovo udjes nemozes) :'(
Dio:
if(newkeys == KEY_SECONDARY_ATTACK)
    {
if(IsPlayerConnected(playerid))
{
for(new i = 0; i < sizeof(HouseInfo); i++)
{
if (PlayerToPoint(3, playerid,HouseInfo[i][hEntrancex], HouseInfo[i][hEntrancey], HouseInfo[i][hEntrancez]))
{
//printf("Found House :%d",i);
if(PlayerInfo[playerid][pPhousekey] == i || HouseInfo[i][hLock] == 0)
{
SetPlayerInterior(playerid,HouseInfo[i][hInt]);
SetPlayerPos(playerid,HouseInfo[i][hExitx],HouseInfo[i][hExity],HouseInfo[i][hExitz]);
GameTextForPlayer(playerid, "~w~dobrodosao doma", 5000, 1);
PlayerInfo[playerid][pInt] = HouseInfo[i][hInt];
PlayerInfo[playerid][pHouseEntered] = 1;
PlayerInfo[playerid][pLocal] = i;
PlayerInfo[playerid][pVW] = i;
SetPlayerVirtualWorld(playerid,i);
}
else
{
GameTextForPlayer(playerid, "~r~zakljucano", 5000, 1);
}
}
}
}
}

Pa ne valja taj Exit sistem svi se zale na to niko ne zna da resi


a nista, dajte enter i exit komandu pa cemo vidit sta se moze napravit...

C:\Users\Paul\Desktop\Tuborg RolePlay [0.3c]\gamemodes\Tuborg.pwn(37598) : error 033: array must be indexed (variable "HouseInfo")
C:\Users\Paul\Desktop\Tuborg RolePlay [0.3c]\gamemodes\Tuborg.pwn(37598) : warning 215: expression has no effect
C:\Users\Paul\Desktop\Tuborg RolePlay [0.3c]\gamemodes\Tuborg.pwn(37598) : error 001: expected token: ";", but found "]"
C:\Users\Paul\Desktop\Tuborg RolePlay [0.3c]\gamemodes\Tuborg.pwn(37598) : error 029: invalid expression, assumed zero
C:\Users\Paul\Desktop\Tuborg RolePlay [0.3c]\gamemodes\Tuborg.pwn(37598) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664           Copyright (c) 1997-2006, ITB CompuPhase


4 Errors.


komanda exit


if(strcmp(cmd, "/exit", true) == 0)
   {
       if(IsPlayerConnected(playerid))
      {
          if(HouseEntered[playerid] != 9999)
          {
            new i = HouseEntered[playerid];

            if (IsPlayerInRangeOfPoint(playerid, 3,HouseInfo<i>[hExitx], HouseInfo<i>[hExity], HouseInfo<i>[hExitz]))
            {
               SafeSetPlayerInterior(playerid,0);
               SafeSetPlayerPos(playerid,HouseInfo<i>[hEntrancex],HouseInfo<i>[hEntrancey],HouseInfo<i>[hEntrancez]);
               SetPlayerVirtualWorld(playerid,0);
               PlayerInfo[playerid][pVirWorld] = 0;
               HouseEntered[playerid] = 9999;
               if(HouseInfo<i>[hHel] == 1)
               {
                  new Float:tempheal;
                  GetPlayerHealth(playerid,tempheal);
                  if(tempheal < 100.0)
                  {
                     SetPlayerHealth(playerid,100.0);
                  }
               }
}
}
   return 1;
            }
         }</i></i></i></i></i></i></i>

poznaticovik


Nije to ta komanda sto vam je dao Paul to je on nes smikso tamo ne postoji /exit komanda uopce.  >:(

Ovo je prava:

//***********************HOUSE ENTER I EXIT*************************************//
if(newkeys == KEY_SECONDARY_ATTACK)
    {
if(IsPlayerConnected(playerid))
{
for(new i = 0; i < sizeof(HouseInfo); i++)
{
if (PlayerToPoint(3, playerid,HouseInfo[i][hEntrancex], HouseInfo[i][hEntrancey], HouseInfo[i][hEntrancez]))
{
//printf("Found House :%d",i);
if(PlayerInfo[playerid][pPhousekey] == i || HouseInfo[i][hLock] == 0)
{
SetPlayerInterior(playerid,HouseInfo[i][hInt]);
SetPlayerPos(playerid,HouseInfo[i][hExitx],HouseInfo[i][hExity],HouseInfo[i][hExitz]);
GameTextForPlayer(playerid, "~w~dobrodosao doma", 5000, 1);
PlayerInfo[playerid][pInt] = HouseInfo[i][hInt];
PlayerInfo[playerid][pHouseEntered] = 1;
PlayerInfo[playerid][pLocal] = i;
PlayerInfo[playerid][pVW] = i;
SetPlayerVirtualWorld(playerid,i);
}
else
{
GameTextForPlayer(playerid, "~r~zakljucano", 5000, 1);
}
}
}
}
}

//******************************************************************************//

Citat: Gangasta300 poslato April 13, 2011, 16:39:25 POSLE PODNE
Nije to ta komanda sto vam je dao Paul to je on nes smikso tamo ne postoji /exit komanda uopce.  >:(

Ovo je prava:

//***********************HOUSE ENTER I EXIT*************************************//
if(newkeys == KEY_SECONDARY_ATTACK)
    {
if(IsPlayerConnected(playerid))
{
for(new i = 0; i < sizeof(HouseInfo); i++)
{
if (PlayerToPoint(3, playerid,HouseInfo[i][hEntrancex], HouseInfo[i][hEntrancey], HouseInfo[i][hEntrancez]))
{
//printf("Found House :%d",i);
if(PlayerInfo[playerid][pPhousekey] == i || HouseInfo[i][hLock] == 0)
{
SetPlayerInterior(playerid,HouseInfo[i][hInt]);
SetPlayerPos(playerid,HouseInfo[i][hExitx],HouseInfo[i][hExity],HouseInfo[i][hExitz]);
GameTextForPlayer(playerid, "~w~dobrodosao doma", 5000, 1);
PlayerInfo[playerid][pInt] = HouseInfo[i][hInt];
PlayerInfo[playerid][pHouseEntered] = 1;
PlayerInfo[playerid][pLocal] = i;
PlayerInfo[playerid][pVW] = i;
SetPlayerVirtualWorld(playerid,i);
}
else
{
GameTextForPlayer(playerid, "~r~zakljucano", 5000, 1);
}
}
}
}
}

//******************************************************************************//


Pa kolko znam u tom i je problem sa komande nema...pa sam ja ubacio svoju!

pogledaj moj post pa vidi dal ima il nema :)
kad kupis kucu samo jednom mozes izac a onda vise ne :(