House system :c
#1

Hi friend's, plese help me T.T

pawn Код:
(74) : error 017: undefined symbol "HouseCount"
(78 ) : error 017: undefined symbol "HInfo"
(78 ) : warning 215: expression has no effect
(78 ) : error 001: expected token: ";", but found "]"
(78 ) : error 029: invalid expression, assumed zero
(78 ) : fatal error 107: too many error messages on one line
Pawn

pawn Код:
#include <a_samp>
#include <SII>
#include <sscanf>
#include <streamer>
#include <zcmd>

#if defined FILTERSCRIPT

//==============================================================

#define MAX_HOUSES 100
enum HouseInfo
{
Owner[24],
Owned,
Price,
Float:XPos,
Float:YPos,
Float:ZPos,
VirtualWorld,
Text3D:HouseLabel
}
new HInfo[MAX_HOUSES][HouseInfo];

//==============================================================
new HouseCount;
new HouseEnter[MAX_HOUSES];
new HouseExit[MAX_HOUSES];
new PlayerInHouseID[MAX_PLAYERS];
//==============================================================

public OnFilterScriptInit()
{
    print("\n--------------------------------------");
    print(" Blank Filterscript by your name here");
    print("--------------------------------------\n");
    return 1;
}

public OnFilterScriptExit()
{
    return 1;
}

#else

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

#endif

//==============================================================

CMD:createhouse(playerid,params[])
{
if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid,-1,"Tu no eres Administrador!");
new HousePrice,id = HouseCount;
if(sscanf(params,"i",HousePrice)) return SendClientMessage(playerid,-1,"USO: /createhouse <precio>");
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
HInfo[id][Price] = HousePrice;
HInfo[id][Owned] = 0;
HInfo[id][XPos] = x;
HInfo[id][YPos] = y;
HInfo[id][ZPos] = z;
HInfo[id][VirtualWorld] = GetPlayerVirtualWorld(playerid);
format(HInfo[id][Owner],24,"NoOwner");
SendClientMessage(playerid,-1,"House created");
HouseEnter[id] = CreateDynamicCP(x,y,z,1.5,GetPlayerVirtualWorld(playerid));
HouseExit[id] = CreateDynamicCP(443.9237,509.4609,1001.4195,1.5,GetPlayerVirtualWorld(playerid));
new file[40],labelstring[100];
format(file,sizeof(file),"FHouse/Houses/%i.ini",id);
INI_Open(file);
INI_WriteInt("Price",HousePrice);
INI_WriteInt("Owned",0);/
INI_WriteInt("VirtualWorld",GetPlayerVirtualWorld(playerid));
INI_WriteFloat("XPos",x);
INI_WriteFloat("YPos",y);
INI_WriteFloat("ZPos",z);
INI_WriteString("Owner","NoOwner");
INI_Save();
INI_Close();
format(labelstring,sizeof(labelstring),"Owned: No \nPrice: %i",HousePrice);
HInfo[id][HouseLabel] = Create3DTextLabel(labelstring,0xFF0000FF,x,y,z,25. 0,GetPlayerVirtualWorld(playerid));
HouseCount++;
return 1;
}
pawn Код:
Ln 74:
new HousePrice,id = HouseCount;

Ln 78:
HInfo[id][Price] = HousePrice;
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)