Make the property system
#4

Try it now:

pawn Код:
#include <a_samp>
#include <sscanf2>
#include <streamer>

#define MAX_PROPERTYS 1000
#define FILE_PROPERTYS "Propertys/"

enum PropertyMain
{
    PropertyName[50],
    PropertyFile[100],
    PropertyIncome,
    PropertyPrice,
    PropertyOwned,
    PropertyOwner[MAX_PLAYER_NAME],
    Float:PropertyX,
    Float:PropertyY,
    Float:PropertyZ
}
new Property[PropertyMain];

public OnFilterScriptInit()
{
    for(new P = 0; P < MAX_PROPERTYS; P++)
    {
        format(Property[PropertyFile],100,"%s%d.ini",FILE_PROPERTYS,P);
        if(fexist(Property[PropertyFile]))
        {
            new File:File = fopen(Property[PropertyFile],io_read);
            new Name[50],Income,Price,Owned,Owner[MAX_PLAYER_NAME],Float:X,Float:Y,Float:Z;
            sscanf(File,"s[50]iiis[40]fff",Name,Income,Price,Owned,Owner,X,Y,Z);
        }
    }
    return 1;
}
I simply did what Jonny said, not sure if you are using an old one or the newest one. Newest one requires this.
Reply


Messages In This Thread
Make the property system - by Prosettur - 23.06.2012, 20:27
Re: Make the property system - by Danijel. - 23.06.2012, 20:30
Re: Make the property system - by Jonny5 - 23.06.2012, 20:33
Re: Make the property system - by Kindred - 23.06.2012, 20:35
Re: Make the property system - by Prosettur - 23.06.2012, 20:37

Forum Jump:


Users browsing this thread: 1 Guest(s)