[Pomoc] warning 217: loose indentation | rešeno

Započeo Virus xD ☞ Weed is ✔, Novembar 09, 2010, 10:40:30 PRE PODNE

prethodna tema - sledeća tema

0 članova i 1 gost pregledaju ovu temu.

popis errora

CitatD:\Server\samp weed core\gamemodes\feuerfrei.pwn(125) : warning 217: loose indentation
D:\Server\samp weed core\gamemodes\feuerfrei.pwn(128) : warning 217: loose indentation
D:\Server\samp weed core\gamemodes\feuerfrei.pwn(647) : warning 217: loose indentation
D:\Server\samp weed core\gamemodes\feuerfrei.pwn(649) : warning 217: loose indentation
D:\Server\samp weed core\gamemodes\feuerfrei.pwn(657) : warning 217: loose indentation
D:\Server\samp weed core\gamemodes\feuerfrei.pwn(658) : warning 217: loose indentation
D:\Server\samp weed core\gamemodes\feuerfrei.pwn(681) : warning 217: loose indentation
D:\Server\samp weed core\gamemodes\feuerfrei.pwn(692) : warning 217: loose indentation
D:\Server\samp weed core\gamemodes\feuerfrei.pwn(695) : warning 217: loose indentation
D:\Server\samp weed core\gamemodes\feuerfrei.pwn(697) : warning 217: loose indentation
Pawn compiler 3.2.3664           Copyright (c) 1997-2006, ITB CompuPhase


10 Warnings.



#include <a_samp>
// mysql
#include <a_mysql>
//
#include <zcmd>
#include <sscanf2>

main()
{
print("\n----------------------------------");
print(" Blank Gamemode by your name here");
print("----------------------------------\n");
}

//------------------------------------------------
// define
//------------------------------------------------
// MYsql
#define MYSQL_HOST "127.0.0.1"
#define MYSQL_USER "root"
#define MYSQL_DB "SAMP"
#define MYSQL_PASS ""

#undef MAX_PLAYERS
#define MAX_PLAYERS 50 // maximalni broj playera na serveru

#define COLOR_RED 0xFF0000
#define COLOR_YELLOW 0xFFFF00

#define MAX_HOUSES 250
#define INVALID_HOUSE_ID 255
#define STANDARD_HOUSEVEHICLE 517

//------------------------------------------------
// New
//------------------------------------------------
// user
enum pEnum
{
Name[MAX_PLAYER_NAME],
Password[32],
Admin,
Money,
//
PozX,
PozY,
PozZ,
PozInt,
PozDimenzion,
Skin,
//
Job,
JobSkill,
JobRank,
//
Org,
OrgRank,
OrgLeader,
//
Cop,
CopDuty,
Arrest,
ArrestTime,
//
Licence,
LicenceCar,
LicenceHelicopter,
LicenceBike,
LicencePlane,
LicenceBoat,
LicenceTrain
};
new UserStats[MAX_PLAYERS][pEnum];
new AccountExists[MAX_PLAYERS];
new PlayerLogged[MAX_PLAYERS];
// houses
enum hInfo()
{
hID,
Float:hEntrancePosX,
Float:hEntrancePosY,
Float:hEntrancePosZ,
Float:hExitPosX,
Float:hExitPosY,
Float:hExitPosZ,
hInterior,
hVirtualWorld,
hOwned,
hOwner[MAX_PLAYER_NAME],
hDescription[35],
hPrice,
hVec,
hVecColor1,
hVecColor2,
Float:hVecPosX,
Float:hVecPosY,
Float:hVecPosZ,
Float:hVecPosA,
};
new HouseInfo[MAX_HOUSES][hInfo];
new HOUSECAR_SPAWN[MAX_VEHICLES];
new HOUSE_PICKUP[MAX_HOUSES];
//

ConnectMySQL()
{
if(mysql_connect(MYSQL_HOST, MYSQL_USER, MYSQL_DB, MYSQL_PASS))
   print("[MySQL] Connection to the MySQL Database was successfully!");

else
   print("[MySQL] Could not connect to the MySQL Database!");
}

CheckMySQL()
{
if(mysql_ping() == -1)
mysql_connect(MYSQL_HOST, MYSQL_USER, MYSQL_DB, MYSQL_PASS);
}

CheckAccountExists(account[])
{
new string[128];
    format(string, sizeof(string), "SELECT * FROM Users WHERE Name = '%s'", account);
    mysql_query(string);

mysql_store_result();

new value;
value = mysql_num_rows();
mysql_free_result();
return value;
}

explode(const sSource[], aExplode[][], const sDelimiter[] = " ", iVertices = sizeof aExplode, iLength = sizeof aExplode[]) // Created by Westie
{
new
iNode,
iPointer,
iPrevious = -1,
iDelimiter = strlen(sDelimiter);

while(iNode < iVertices)
{
iPointer = strfind(sSource, sDelimiter, false, iPointer);

if(iPointer == -1)
{
strmid(aExplode[iNode], sSource, iPrevious, strlen(sSource), iLength);
break;
}
else
{
strmid(aExplode[iNode], sSource, iPrevious, iPointer, iLength);
}

iPrevious = (iPointer += iDelimiter);
++iNode;
}
return iPrevious;
}

stock split(const strsrc[], strdest[][], delimiter)
{
new i, li;
new aNum;
new len;

while(i <= strlen(strsrc))
{
   if(strsrc[i]==delimiter || i==strlen(strsrc))
{
       len = strmid(strdest[aNum], strsrc, li, i, 25);
       strdest[aNum][len] = 0;
       li = i+1;
       aNum++;
}
i++;
}
return 1;
}

public OnGameModeInit()
{
// Don't use these lines if it's a filterscript
SetGameModeText("FF v1.0.0");

ConnectMySQL();

   ReloadAllHouses();

for(new h = 0; h < MAX_HOUSES; h++)
{
HOUSECAR_SPAWN[h] = CreateVehicle(HouseInfo[h][hVec], HouseInfo[h][hVecPosX], HouseInfo[h][hVecPosY], HouseInfo[h][hVecPosZ], HouseInfo[h][hVecPosA], HouseInfo[h][hVecColor1], HouseInfo[h][hVecColor2], -1);

if(HouseInfo[h][hOwned] == 0)
{
   HOUSE_PICKUP[h] = CreatePickup(1273, 1, HouseInfo[h][hEntrancePosX], HouseInfo[h][hEntrancePosY], HouseInfo[h][hEntrancePosZ]);
}
else
{
   HOUSE_PICKUP[h] = CreatePickup(1272, 1, HouseInfo[h][hEntrancePosX], HouseInfo[h][hEntrancePosY], HouseInfo[h][hEntrancePosZ]);
}
}

SetTimer("UpdatePlayerInfo", 3000, true);

return 1;
}

public OnGameModeExit()
{
   mysql_close();
return 1;
}

public OnPlayerRequestClass(playerid, classid)
{
return 0;
}

public OnPlayerConnect(playerid)
{
   GetPlayerName(playerid, UserStats[playerid][Name], MAX_PLAYER_NAME);
   
   new name[MAX_PLAYER_NAME];
   GetPlayerName(playerid, name, sizeof(name));


if(CheckAccountExists(UserStats[playerid][Name])) AccountExists[playerid] = 1;
else AccountExists[playerid] = 0;

   if(AccountExists[playerid])
   {
       new string[22], string2[95];
format(string,sizeof(string), "Weed Core SAMP v1.0.0");
format(string2,sizeof(string2), "Dobro dosli! \r\nIME: %s je pronaÄ'eno u databazi\r\nMolimo vas da se logirate.",name );
ShowPlayerDialog(playerid, 0, DIALOG_STYLE_INPUT , string, string2, "Login", "Exit");
   return 1;
}
else
{
   new string[22], string2[181];
format(string,sizeof(string), "Weed Core SAMP v1.0.0");
format(string2,sizeof(string2), "Dobro dosli! \r\nIME: %s nije registrano\r\nPotrebno ga je registrirati da bi ste mogli zaigrati na serveru.\r\n**Upozorenje** password mora imati vise od 6 znakova",name );
ShowPlayerDialog(playerid, 1, DIALOG_STYLE_INPUT , string, string2, "Register", "Exit");
   return 1;
}

}

public OnPlayerDisconnect(playerid, reason)
{
   SavePlayer(playerid);

UserStats[playerid][Admin] = 0;
UserStats[playerid][Money] = 0;

return 1;
}

public OnPlayerSpawn(playerid)
{
return 1;
}

public OnPlayerDeath(playerid, killerid, reason)
{
   SavePlayer(playerid);
return 1;
}

public OnVehicleSpawn(vehicleid)
{
return 1;
}

public OnVehicleDeath(vehicleid, killerid)
{
return 1;
}

public OnPlayerText(playerid, text[])
{
return 1;
}

/*
77------------------------------------------------------------------------------
77     Komande
77------------------------------------------------------------------------------

public OnPlayerCommandText(playerid, cmdtext[])
{

return 0;
}

http://forum.sa-mp.com/showthread.php?t=91354&highlight=zcmd
ili hr
http://balkan-samp.com/forum/index.php?topic=10516.0

// koristi se
COMMAND:mycommand(playerid, params[]) // or CMD:mycommand(playerid, params[])
{
 // Do something
 return 1;
}

*/


COMMAND:buyhouse(playerid, params[])
{
#pragma unused params

for(new h = 0; h < MAX_HOUSES; h++)
{
   if(IsPlayerInRangeOfPoint(playerid, 2, HouseInfo[h][hEntrancePosX], HouseInfo[h][hEntrancePosY], HouseInfo[h][hEntrancePosZ]))
   {
if(HouseInfo[h][hOwned] == 0)
{
   if(GetPlayerMoney(playerid) >= HouseInfo[h][hPrice])
   {
       new pName[MAX_PLAYER_NAME];
       GetPlayerName(playerid, pName, MAX_PLAYER_NAME); GivePlayerMoney(playerid, -HouseInfo[h][hPrice]);
       strmid(HouseInfo[h][hOwner], pName, false, strlen(pName), 25);
       HouseInfo[h][hVec] = STANDARD_HOUSEVEHICLE; HouseInfo[h][hOwned] = 1;
       SendClientMessage(playerid, 0x00FF00AA, "** You have bought this house successfully!");
  HOUSE_PICKUP[h] = CreatePickup(1272, 1, HouseInfo[h][hEntrancePosX], HouseInfo[h][hEntrancePosY], HouseInfo[h][hEntrancePosZ]);
  SaveAllHouses();
  return 1;
}
else return SendClientMessage(playerid, 0xFF0000AA, "** You don't have enough money for this house!");
}
else return SendClientMessage(playerid, 0xFF0000AA, "** This house is already owned by someone!");
}
}
return 1;
}

COMMAND:sellhouse(playerid, params[])
{
#pragma unused params

for(new h = 0; h < MAX_HOUSES; h++)
{
   if(IsPlayerInRangeOfPoint(playerid, 2, HouseInfo[h][hEntrancePosX], HouseInfo[h][hEntrancePosY], HouseInfo[h][hEntrancePosZ]))
   {
       new pName[MAX_PLAYER_NAME];
       GetPlayerName(playerid, pName, MAX_PLAYER_NAME);
       if(strcmp(HouseInfo[h][hOwner], pName, true) == 0)
       {
           HouseInfo[h][hOwned] = 0;
           strdel(HouseInfo[h][hOwner], 0, strlen(HouseInfo[h][hOwner]));
           GivePlayerMoney(playerid, (HouseInfo[h][hPrice]/2));
SendClientMessage(playerid, 0x00FF00AA, "** You sold this house!");
HOUSE_PICKUP[h] = CreatePickup(1272, 1, HouseInfo[h][hEntrancePosX], HouseInfo[h][hEntrancePosY], HouseInfo[h][hEntrancePosZ]);
SaveAllHouses();
}
else return SendClientMessage(playerid, 0xFF0000AA, "** You only can sell your own houses!");
}
}
return 1;
}

COMMAND:housecar(playerid, params[])
{
new houseid,vehicle,pName[MAX_PLAYER_NAME];
GetPlayerName(playerid, pName, MAX_PLAYER_NAME);
if(sscanf(params, "dd", houseid, vehicle)) return SendClientMessage(playerid, 0xFFFFFFAA, "USAGE: /housecar [houseid] [vehicleid]");
if(strcmp(HouseInfo[houseid][hOwner], pName, true) == 0)
{
   HouseInfo[houseid][hVec] = vehicle;
   DestroyVehicle(HOUSECAR_SPAWN[houseid]);
   HOUSECAR_SPAWN[houseid] = CreateVehicle(HouseInfo[houseid][hVec], HouseInfo[houseid][hVecPosX], HouseInfo[houseid][hVecPosY], HouseInfo[houseid][hVecPosZ], HouseInfo[houseid][hVecPosA], HouseInfo[houseid][hVecColor1], HouseInfo[houseid][hVecColor2], -1);
GivePlayerMoney(playerid, -1500);
}
else return SendClientMessage(playerid, 0xFF0000AA, "** You can only do actions by your own houses!");
return 1;
}

COMMAND:hccolor(playerid, params[])
{
new houseid,clr1,clr2,pName[MAX_PLAYER_NAME];
GetPlayerName(playerid, pName, MAX_PLAYER_NAME);
if(sscanf(params, "ddd", houseid, clr1, clr2)) return SendClientMessage(playerid, 0xFFFFFFAA, "USAGE: /hccolor [vehicleid] [color1] [color2]");
if(strcmp(HouseInfo[houseid][hOwner], pName, true) == 0)
{
HouseInfo[houseid][hVecColor1] = clr1; HouseInfo[houseid][hVecColor2] = clr2;
ChangeVehicleColor(HOUSECAR_SPAWN[houseid], clr1, clr2);
GivePlayerMoney(playerid, -150);
}
else return SendClientMessage(playerid, 0xFF0000AA, "** You can only dp actions by your own houses!");
return 1;
}

COMMAND:enterhouse(playerid, params[])
{
#pragma unused params
for(new h = 0; h < MAX_HOUSES; h++)
{
if(IsPlayerInRangeOfPoint(playerid, 2, HouseInfo[h][hEntrancePosX], HouseInfo[h][hEntrancePosY], HouseInfo[h][hEntrancePosZ]))
{
new pName[MAX_PLAYER_NAME];GetPlayerName(playerid, pName, MAX_PLAYER_NAME);
if(strcmp(HouseInfo[h][hOwner], pName, true) == 0)
{
SetPlayerVirtualWorld(playerid, HouseInfo[h][hVirtualWorld]); SetPlayerInterior(playerid, HouseInfo[h][hInterior]);
SetPlayerPos(playerid, HouseInfo[h][hEntrancePosX], HouseInfo[h][hEntrancePosY], HouseInfo[h][hEntrancePosZ]);
return 1;
}
}
}
return 1;
}

COMMAND:exithouse(playerid, params[])
{
#pragma unused params
for(new h = 0; h < MAX_HOUSES; h++)
{
if(IsPlayerInRangeOfPoint(playerid, 2, HouseInfo[h][hEntrancePosX], HouseInfo[h][hEntrancePosY], HouseInfo[h][hEntrancePosY]))
{
SetPlayerVirtualWorld(playerid, 0);SetPlayerInterior(playerid, 0);
SetPlayerPos(playerid, HouseInfo[h][hExitPosX], HouseInfo[h][hExitPosY], HouseInfo[h][hExitPosZ]);
return 1;
}
}
return 1;
}

COMMAND:tphouse(playerid, params[])
{
if(IsPlayerAdmin(playerid))
{
new houseid,Float:pX,Float:pY,Float:pZ,vir,int;
if(sscanf(params, "d", houseid)) return SendClientMessage(playerid, 0xFFFFFFAA, "USAGE: /tphouse [playerid]");
GetPlayerPos(playerid, pX, pY, pZ); vir = GetPlayerVirtualWorld(playerid); int = GetPlayerInterior(playerid);
HouseInfo[houseid][hEntrancePosX] = pX; HouseInfo[houseid][hEntrancePosY] = pY; HouseInfo[houseid][hEntrancePosZ] = pZ;
HouseInfo[houseid][hVirtualWorld] = vir; HouseInfo[houseid][hInterior] = int;
}
return 1;
}

COMMAND:tphousecar(playerid, params[])
{
if(IsPlayerAdmin(playerid))
{
if(IsPlayerInAnyVehicle(playerid))
{
new Float:pX,Float:pY,Float:pZ,Float:pA,houseid;
if(sscanf(params, "d", houseid)) return SendClientMessage(playerid, 0xFFFFFFAA, "USAGE: /tphousecar [houseid]");
GetVehiclePos(GetPlayerVehicleID(playerid), pX, pY, pZ); GetVehicleZAngle(GetPlayerVehicleID(playerid), pA);
HouseInfo[houseid][hVecPosX] = pX; HouseInfo[houseid][hVecPosY] = pY; HouseInfo[houseid][hVecPosZ] = pZ; HouseInfo[houseid][hVecPosA] = pA;
DestroyVehicle(HOUSECAR_SPAWN[houseid]);
HOUSECAR_SPAWN[houseid] = CreateVehicle(HouseInfo[houseid][hVec], HouseInfo[houseid][hVecPosX], HouseInfo[houseid][hVecPosY], HouseInfo[houseid][hVecPosZ], HouseInfo[houseid][hVecPosA], HouseInfo[houseid][hVecColor1], HouseInfo[houseid][hVecColor2], -1);
return 1;
}
else return SendClientMessage(playerid, 0xFF0000AA, "** You need to be in an vehicle!");
}
return 1;
}

COMMAND:savehouses(playerid, params[])
{
#pragma unused params
if(IsPlayerAdmin(playerid))
{
SaveAllHouses();
}
}

public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
return 1;
}

public OnPlayerExitVehicle(playerid, vehicleid)
{
return 1;
}

public OnPlayerStateChange(playerid, newstate, oldstate)
{
return 1;
}

public OnPlayerEnterCheckpoint(playerid)
{
return 1;
}

public OnPlayerLeaveCheckpoint(playerid)
{
return 1;
}

public OnPlayerEnterRaceCheckpoint(playerid)
{
return 1;
}

public OnPlayerLeaveRaceCheckpoint(playerid)
{
return 1;
}

public OnRconCommand(cmd[])
{
return 1;
}

public OnPlayerRequestSpawn(playerid)
{
return 1;
}

public OnObjectMoved(objectid)
{
return 1;
}

public OnPlayerObjectMoved(playerid, objectid)
{
return 1;
}

public OnPlayerPickUpPickup(playerid, pickupid)
{
return 1;
}

public OnVehicleMod(playerid, vehicleid, componentid)
{
return 1;
}

public OnVehiclePaintjob(playerid, vehicleid, paintjobid)
{
return 1;
}

public OnVehicleRespray(playerid, vehicleid, color1, color2)
{
return 1;
}

public OnPlayerSelectedMenuRow(playerid, row)
{
return 1;
}

public OnPlayerExitedMenu(playerid)
{
return 1;
}

public OnPlayerInteriorChange(playerid, newinteriorid, oldinteriorid)
{
return 1;
}

public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
return 1;
}

public OnRconLoginAttempt(ip[], password[], success)
{
return 1;
}

public OnPlayerUpdate(playerid)
{
return 1;
}

public OnPlayerStreamIn(playerid, forplayerid)
{
return 1;
}

public OnPlayerStreamOut(playerid, forplayerid)
{
return 1;
}

public OnVehicleStreamIn(vehicleid, forplayerid)
{
return 1;
}

public OnVehicleStreamOut(vehicleid, forplayerid)
{
return 1;
}

public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
/// login / register
   if(dialogid == 0)
   {
       if(!response) return SendClientMessage(playerid, 0xFFFFFFFF, "Morate se Ulogirati da bi ste igrali na serveru!"), Kick( playerid );
       LoginPlayer(playerid, inputtext);
       return 1;
   }
   if(dialogid == 1)
   {
       if(!response) return SendClientMessage(playerid, 0xFFFFFFFF, "Morate se Registrirati da bi ste igrali na serveru!"), Kick( playerid );
       if(strlen(inputtext)>6)
       {
           RegisterPlayer(playerid, inputtext);
       }
       else
       {
           new string[22], string2[58];
format(string,sizeof(string), "Weed Core SAMP v1.0.0");
format(string2,sizeof(string2), "Password je prekratak mora sadrzavati minimalno 6 znakova");
ShowPlayerDialog(playerid, 1, DIALOG_STYLE_INPUT , string, string2, "Register", "Exit");
       }
       return 1;
   }
   return 0;
}

public OnPlayerClickPlayer(playerid, clickedplayerid, source)
{
return 1;

}

///////////////////////////-------------------------------------------
///////////////////////////-------------------------------------------
///////////////////////////-------------------------------------------
/////////////////////////// Accaunt
///////////////////////////-------------------------------------------

RegisterPlayer(playerid, password[])
{
CheckMySQL();

new string[128];
format(string, sizeof(string), "INSERT INTO Users (Name,Password) VALUES ('%s','%s')", UserStats[playerid][Name], password);
mysql_query(string);

    AccountExists[playerid] = 1;

LoginPlayer(playerid, password);
return 1;
}

LoginPlayer(playerid, password[])
{
CheckMySQL();

    new string[128];
format(string, sizeof(string), "SELECT * FROM Users WHERE Name = '%s' AND Password = '%s'", UserStats[playerid][Name], password);
mysql_query(string);
mysql_store_result();

if(!mysql_num_rows())
return SendClientMessage(playerid, COLOR_RED, "Kick razlog: Netocan password!"), Kick(playerid);

new row[128]; // The length of 1 'row' total.
new field[4][32]; // [4] = Amount of fields, [24] = Max length of the bigest field.

mysql_fetch_row_format(row, "|");
explode(row, field, "|");
mysql_free_result();

// The field starts here with 1, because the field 'Name' = 0, and we already have the name in a variable.
format(UserStats[playerid][Password], 32, "%s", field[1]);
UserStats[playerid][Admin] = strval(field[2]);
UserStats[playerid][Money] = strval(field[3]);

GivePlayerMoney(playerid, UserStats[playerid][Money]);


format(string, sizeof(string), "[ACCOUNT] Welcome back %s, sad se ulogirani! Ugodnu igru i zabavu.", UserStats[playerid][Name]);
    SendClientMessage(playerid, COLOR_YELLOW, string);

    PlayerLogged[playerid] = 1;
    return 1;
}

SavePlayer(playerid)
{
if(!PlayerLogged[playerid])
return 0;

    UserStats[playerid][Money] = GetPlayerMoney(playerid);


CheckMySQL();

    new string[256];
    format(string, sizeof(string), "UPDATE Users SET Password='%s',Admin='%d',Money='%d' WHERE Name='%s'", UserStats[playerid][Password], UserStats[playerid][Admin], UserStats[playerid][Money], UserStats[playerid][Name]);
    mysql_query(string);
    return 1;
}

///////////////////////////-------------------------------------------
///////////////////////////-------------------------------------------
///////////////////////////-------------------------------------------
/////////////////////////// Houses
///////////////////////////-------------------------------------------

forward SaveAllHouses();
public SaveAllHouses()
{
new h;
new File:houses;
while(h < MAX_HOUSES)
{
   new string[288];
   format(string, sizeof(string), "%d,%f,%f,%f,%f,%f,%f,%d,%d,%d,%s,%s,%d,%d,%d,%d,%f,%f,%f,%f\r\n",
HouseInfo[h][hID],
HouseInfo[h][hEntrancePosX],
HouseInfo[h][hEntrancePosY],
HouseInfo[h][hEntrancePosZ],
HouseInfo[h][hExitPosX],
HouseInfo[h][hExitPosY],
HouseInfo[h][hExitPosZ],
HouseInfo[h][hInterior],
HouseInfo[h][hVirtualWorld],
HouseInfo[h][hOwned],
HouseInfo[h][hOwner],
HouseInfo[h][hDescription],
HouseInfo[h][hPrice],
HouseInfo[h][hVec],
HouseInfo[h][hVecColor1],
HouseInfo[h][hVecColor2],
HouseInfo[h][hVecPosX],
HouseInfo[h][hVecPosY],
HouseInfo[h][hVecPosZ],
HouseInfo[h][hVecPosA]);

if(h == 0)
{
   houses = fopen("Houses.cfg", io_write);
}
else
{
   houses = fopen("Houses.cfg", io_append);
}
fwrite(houses, string);
h++;
fclose(houses);
}
h = 0;
return 1;
}

forward ReloadAllHouses();
public ReloadAllHouses()
{
new string[288];
new arrCoords[20][46];
new File:houses = fopen("Houses.cfg", io_read);
new h;
if(houses)
{
   while(h < MAX_HOUSES)
   {
       fread(houses, string);
       split(string, arrCoords, ',');
       HouseInfo[h][hID] = strval(arrCoords[0]);
       HouseInfo[h][hEntrancePosX] = floatstr(arrCoords[1]);
       HouseInfo[h][hEntrancePosY] = floatstr(arrCoords[2]);
       HouseInfo[h][hEntrancePosZ] = floatstr(arrCoords[3]);
       HouseInfo[h][hExitPosX] = floatstr(arrCoords[4]);
       HouseInfo[h][hExitPosY] = floatstr(arrCoords[5]);
       HouseInfo[h][hExitPosZ] = floatstr(arrCoords[6]);
       HouseInfo[h][hInterior] = strval(arrCoords[7]);
       HouseInfo[h][hVirtualWorld] = strval(arrCoords[8]);
       HouseInfo[h][hOwned] = strval(arrCoords[9]);
       strmid(HouseInfo[h][hOwner], arrCoords[10], false, strlen(arrCoords[10]), MAX_PLAYER_NAME);
       strmid(HouseInfo[h][hDescription], arrCoords[11], false, strlen(arrCoords[11]), 35+1);
       HouseInfo[h][hPrice] = strval(arrCoords[12]);
       HouseInfo[h][hVec] = strval(arrCoords[13]);
       HouseInfo[h][hVecColor1] = strval(arrCoords[14]);
       HouseInfo[h][hVecColor2] = strval(arrCoords[15]);
       HouseInfo[h][hVecPosX] = floatstr(arrCoords[16]);
       HouseInfo[h][hVecPosY] = floatstr(arrCoords[17]);
       HouseInfo[h][hVecPosZ] = floatstr(arrCoords[18]);
       HouseInfo[h][hVecPosA] = floatstr(arrCoords[19]);
       h++;
}
}
fclose(houses);
return 1;
}

forward UpdatePlayerInfo();
public UpdatePlayerInfo()
{
new string[128];
for(new i = 0; i < MAX_PLAYERS; i++)
{
   for(new h = 0; h < MAX_HOUSES; h++)
   {
       if(IsPlayerInRangeOfPoint(i, 2, HouseInfo[h][hEntrancePosX], HouseInfo[h][hEntrancePosY], HouseInfo[h][hEntrancePosZ]))
       {
           if(HouseInfo[h][hOwned] == 0)
           {
               format(string, sizeof(string), "~w~This house is for sale!~n~Typ ~y~/buyhouse~w~ to buy this house for:~g~~n~$%d,-", HouseInfo[h][hPrice]);
}
else
{
   format(string, sizeof(string), "~w~House owned by ~r~%s", HouseInfo[h][hOwner]);
}
GameTextForPlayer(i, string, 2000, 3);
}
}
}
return 1;
}


zašto mi se gubi ? prije je OK radilo i odjenom sere :S

dali sam dao dovoljno podataka ?

koristim mysql pluing http://forum.sa-mp.com/showthread.php?t=56564
i sscanf2 http://forum.sa-mp.com/showthread.php?t=120356
i zcmd http://forum.sa-mp.com/showthread.php?t=91354&highlight=zcmd
Poslednja Izmena: Novembar 09, 2010, 12:35:35 POSLE PODNE od Virus xD ☞ Weed is ✔


aa nepomaže samo još 1 warning :S

warning 207: unknown #pragma

ty na pokušaju

pa jamo me mući jer crasha srv :S

meni crasha servera radi tih stvari :S

ako ti išta znaći sa crash info



--------------------------

SA-MP Server: 0.3b R2



Exception At Address: 0x004A233B



Registers:

EAX: 0x0018F8A0 EBX: 0x03020EEC ECX: 0x00000000 EDX: 0x00405910

ESI: 0x00000000 EDI: 0x02168450 EBP: 0x0018F8B0 ESP: 0x0018F888

EFLAGS: 0x00010286



Stack:

+0000: 0x02168450   0x02168450   0x03020EEC   0xFFFFFFFF

+0010: 0x0018F888   0x0018F45C   0x0018FE24   0x004A5FA4

+0020: 0x004C11C8   0xFFFFFFFF   0x0302638C   0x0040591D

+0030: 0x00000000   0x00401096   0x02168450   0x0304481C

+0040: 0x030266C4   0x00402BB3   0x02168450   0x0000002F

+0050: 0x0018F8F0   0x0304481C   0x0018FD80   0x00000000

+0060: 0x00000000   0x02168450   0x00000000   0x0001E158

+0070: 0x0001E158   0x0001F4B0   0x0001B4CC   0x0001F498

+0080: 0x0001B4CC   0x03020EEC   0x030266C4   0x00000000

+0090: 0x030204F0   0x000057D8   0x0048B6CE   0x02168450

+00A0: 0x0018FD70   0x00000032   0x646D637A   0x476E4F5F

+00B0: 0x4D656D61   0x4965646F   0x0074696E   0x02168450

+00C0: 0x02168450   0x03020EEC   0x00000000   0x00000000

+00D0: 0x00000000   0x00000000   0x00000000   0x00000000

+00E0: 0x00000000   0x00000000   0x00000000   0x00000000

+00F0: 0x00000000   0x00000000   0x00000000   0x00000000

+0100: 0x00000000   0x00000000   0x0064006F   0x00730065

+0110: 0x0066005C   0x00750065   0x00720065   0x00720066

+0120: 0x00690065   0x0061002E   0x0078006D   0x00000000

+0130: 0x00000000   0x00000000   0x00000000   0x00000000


cristiane

Citat: Hoxxy poslato Novembar 09, 2010, 11:04:48 PRE PODNE
Ti warninzi "loose identitation" ti nisu isto sto i errori. Sa errorima ne moze da ti radi mod, a sa ovakvim warningom moze, nije ti to nista...
Ne lupaj gluposti
Citat: Virus xD ☞ Weed is âœ" poslato Novembar 09, 2010, 10:54:43 PRE PODNE
aa nepomaže samo još 1 warning :S

warning 207: unknown #pragma

ty na pokušaju

pa jamo me mući jer crasha srv :S
Probaj compile sa pawno.exe

sad isao samo compile kako si rekao
isto se dogaÄ'a a možad sma nekaj u vezi toga krivo napravio
(onaj ljevo od plave strelice na to si mislio?))


http://www.megaupload.com/?d=82ELSV6C

evo cjeli samp file možda pronaÄ'ete nekaj da je krivo u njemu

pogrijesio sam ja
stavio ovako
#pragma tabsize 0

da,to je slicno onome gore,,ali ono gore je zajedno,a treba odvojeno...samo stavi ovo i vidi oce biti errora...jer sumnjam da ce biti
Poslednja Izmena: Novembar 09, 2010, 12:20:30 POSLE PODNE od Sub Zero




Citat: Sub Zero poslato Novembar 09, 2010, 12:19:22 POSLE PODNE
pogrijesio sam ja
stavio ovako
#pragma tabsize 0

da,to je slicno onome gore,,ali ono gore je zajedno,a treba odvojeno...samo stavi ovo i vidi oce biti errora...jer sumnjam da ce biti

ty to je pomoglo
sad riješit problem zašto mi crasha server :(

ps. kako mi se cini nesto nevalja smysql pluingom al moram u Å¡kolu





glupo se osjećam u scriptfiles sam zaboravio ubaciti house.cfg problem rešen zahvaljujem se svima na pomoći
Poslednja Izmena: Novembar 09, 2010, 12:26:36 POSLE PODNE od Virus xD ☞ Weed is ✔

cristiane


Citat: cristiane poslato Novembar 09, 2010, 12:26:01 POSLE PODNE
Nebi ti trebalo crashat ako nemas warninga

ty again napisoa zašto je crashalo gore lockam temu
edit:

nemogu mora ce global / moderator lockat

edit2:

ps. sad se glupo osjećam radi takvog faila :(
Poslednja Izmena: Novembar 09, 2010, 12:36:20 POSLE PODNE od Virus xD ☞ Weed is ✔