SA-MP Forums

Go Back   SA-MP Forums > Non-English > Languages > Português/Portuguese > Lançamentos/Releases

Reply
 
Thread Tools Display Modes
Old 01/11/2010, 09:49 PM   #31
Caio_Cartaxo
Gangsta
 
Join Date: Nov 2009
Posts: 563
Reputation: 15
Default Re: Anti-Hacker Systen 1.2

Poderia me mandar o include "SII"
To usando no meu servidor..
Ja botei seus creditos =D
Caio_Cartaxo is offline   Reply With Quote
Old 01/11/2010, 09:53 PM   #32
[FeK]HigorOliver
Big Clucker
 
Join Date: Oct 2010
Posts: 127
Reputation: 6
Default Re: Anti-Hacker Systen 1.2

Tomaaaaaaaaaa

pawn Code:
//======================================================
// Slick's INI Include 2.0.7
//
// (c) Copyright 2008-2010, [DRuG]Slick
// This file is provided as is (no warranties).
//======================================================


#pragma dynamic 45000 // Change accordingly!!

#if defined MAX_STRING
    #define INI_MAX_VALUE MAX_STRING
#else
    #define INI_MAX_VALUE 128
#endif
#define INI_MAX_KEY 24
#define INI_MAX_LINE (INI_MAX_KEY + INI_MAX_VALUE + 3)
#define INI_MAX_FILENAME 256
#define INI_MAX_LINES 256


enum E_CACHE
{
    E_KEY[INI_MAX_KEY],
    E_VALUE[INI_MAX_VALUE]
}

enum E_FILE
{
    E_FILENAME[INI_MAX_FILENAME],
    bool: E_OPEN
}

static gCache[INI_MAX_LINES][E_CACHE];
static gEmptyCache[E_CACHE];
static gFile[E_FILE];
static gNoFile[E_FILE];


#define INI_Exist fexist


stock INI_Open(const filename[])
{
    if (!filename[0]) return false;
    if (gFile[E_OPEN])
    {
        if (!strcmp(gFile[E_FILENAME], filename, true)) return true;
        //return false;
        INI_Close();
    }
    new File: h;
    h = fopen(filename, io_readwrite);
    if (h)
    {
        INI_strcpy(gFile[E_FILENAME], filename, INI_MAX_FILENAME, INI_MAX_FILENAME);
        new line[INI_MAX_LINE];
        new ln = -1;
        new separator;
        while (((ln + 1) < INI_MAX_LINES) && (fread(h, line)))
        {
            ln ++;
            INI_StripLine(line);
            separator = strfind(line, "=", false);
            if ((line[0] == ';') || (line[0] == '=') || (separator == -1) || (separator > INI_MAX_KEY))
            {
                if (line[0] == ';')
                {
                    INI_strcpy(gCache[ln][E_VALUE], line, INI_MAX_VALUE, INI_MAX_VALUE);
                }
                else
                {
                    INI_strcpy(gCache[ln][E_VALUE][1], line, INI_MAX_VALUE - 1, INI_MAX_VALUE - 1);
                    gCache[ln][E_VALUE][0] = ';';
                }
                continue;
            }
            INI_strcpy(gCache[ln][E_KEY], line, separator, INI_MAX_KEY);
            INI_strcpy(gCache[ln][E_VALUE], line[separator + 1], INI_MAX_VALUE, INI_MAX_VALUE);
            if (!gCache[ln][E_VALUE][0]) gCache[ln][E_VALUE][0] = ' ';
        }
        fclose(h);
        gFile[E_OPEN] = true;
        return 1;
    }
    return 0;
}


stock INI_Save()
{
    if (!gFile[E_OPEN]) return false;
    new File: h;
    h = fopen(gFile[E_FILENAME], io_write);
    if (h)
    {
        new line[INI_MAX_LINE];
        new ln = -1;
        while (((ln + 1) < INI_MAX_LINES) && (gCache[ln + 1][E_VALUE][0]))
        {
            ln ++;
            if (gCache[ln][E_VALUE][0] == ';')
            {
                if (gCache[ln][E_VALUE][1])
                {
                    format(line, sizeof(line), "%s\r\n", gCache[ln][E_VALUE]);
                    fwrite(h, line);
                    continue;
                }
                fwrite(h, "\r\n");
                continue;
            }
            format(line, sizeof(line), "%s=%s\r\n", gCache[ln][E_KEY], gCache[ln][E_VALUE]);
            fwrite(h, line);
        }
        fclose(h);
        return true;
    }
    return false;
}


stock INI_Close()
{
    if (!gFile[E_OPEN]) return false;
    for (new ln; ln < INI_MAX_LINES; ln++) gCache[ln] = gEmptyCache;
    gFile = gNoFile;
    return true;
}


stock INI_ReadString(dest[], const key[], maxlength = sizeof(dest))
{
    if ((!gFile[E_OPEN]) || (!key[0])) return false;
    new ln = -1;
    while (((ln + 1) < INI_MAX_LINES) && (gCache[ln + 1][E_VALUE][0]))
    {
        ln ++;
        if (gCache[ln][E_VALUE][0] == ';') continue;
        if (!strcmp(gCache[ln][E_KEY], key, false))
        {
            INI_strcpy(dest, gCache[ln][E_VALUE], INI_MAX_VALUE, maxlength);
            return true;
        }
    }
    return false;
}


stock INI_ReadInt(const key[])
{
    new dest[12];
    if (INI_ReadString(dest, key)) return strval(dest);
    return false;
}


stock Float: INI_ReadFloat(const key[])
{
    new dest[12];
    if (INI_ReadString(dest, key)) return floatstr(dest);
    return 0.0;
}


stock INI_WriteString(const key[], const value[])
{
    if ((!gFile[E_OPEN]) || (!key[0]) || (key[0] == ';') || (strfind(key, "=", false) != -1)) return false;
    new ln = -1;
    while (((ln + 1) < INI_MAX_LINES) && (gCache[ln + 1][E_VALUE][0]))
    {
        ln ++;
        if (gCache[ln][E_VALUE][0] == ';') continue;
        if (!strcmp(gCache[ln][E_KEY], key, false))
        {
            INI_strcpy(gCache[ln][E_VALUE], value, INI_MAX_VALUE, INI_MAX_VALUE);
            return true;
        }
    }
    ln ++;
    if (ln < INI_MAX_LINES)
    {
        INI_strcpy(gCache[ln][E_KEY], key, INI_MAX_KEY, INI_MAX_KEY);
        INI_strcpy(gCache[ln][E_VALUE], value, INI_MAX_VALUE, INI_MAX_VALUE);
        return true;
    }
    return false;
}


stock INI_WriteInt(const key[], value)
{
    new dest[12];
    format(dest, sizeof(dest), "%i", value);
    return INI_WriteString(key, dest);
}


stock INI_WriteFloat(const key[], Float: value)
{
    new dest[12];
    format(dest, sizeof(dest), "%0.4f", value);
    return INI_WriteString(key, dest);
}


stock INI_RemoveEntry(const key[])
{
    if ((!gFile[E_OPEN]) || (!key[0]) || (strfind(key, "=", false) != -1)) return false;
    new ln = -1;
    while (((ln + 1) < INI_MAX_LINES) && (gCache[ln + 1][E_VALUE][0]))
    {
        ln ++;
        if (gCache[ln][E_VALUE][0] == ';') continue;
        if (!strcmp(gCache[ln][E_KEY], key, false))
        {
            for (; ln < (INI_MAX_LINES - 1); ln ++)
            {
                INI_strcpy(gCache[ln][E_KEY], gCache[ln + 1][E_KEY], INI_MAX_KEY, INI_MAX_KEY);
                INI_strcpy(gCache[ln][E_VALUE], gCache[ln + 1][E_VALUE], INI_MAX_VALUE, INI_MAX_VALUE);
            }
            return true;
        }
    }
    return false;
}


stock INI_Remove(const filename[])
{
    if (!filename[0]) return false;
    if ((gFile[E_OPEN]) && (!strcmp(gFile[E_FILENAME], filename, true))) gFile = gNoFile;
    return fremove(filename);
}


stock INI_strcpy(dest[], const source[], numcells = sizeof(source), maxlength = sizeof(dest))
{
    new i;
    while ((source[i]) && (i < numcells) && (i < maxlength))
    {
        dest[i] = source[i];
        i ++;
    }
    dest[(i == maxlength) ? (i - 1) : (i)] = '\0';
}


stock INI_StripLine(string[])
{
    new l;
    l = strlen(string);
    if (string[l - 2] == '\r') string[l - 2] = '\0';
    if (string[l - 1] == '\n') string[l - 1] = '\0';
}
__________________


GameZone Rox Hosting Anuncia !
50 Slots = R$15.00
100 Slots = R$21.00
Site: www.gamezonerox.net
Painel: http://painel.gamezonerox.net
Contato: atendimento@gamezonerox.com.br(ENDEREÇO NOVO)
Ip Testing Ping: 189.1.171.155:7779

www.homehots.net - Melhor Blog de SA-MP (:

[SoS]Member

[FeK]HigorOliver is offline   Reply With Quote
Old 01/11/2010, 10:12 PM   #33
Caio_Cartaxo
Gangsta
 
Join Date: Nov 2009
Posts: 563
Reputation: 15
Default Re: Anti-Hacker Systen 1.2

Vlw mano ^^
Caio_Cartaxo is offline   Reply With Quote
Old 01/11/2010, 10:35 PM   #34
[FeK]HigorOliver
Big Clucker
 
Join Date: Oct 2010
Posts: 127
Reputation: 6
Default Re: Anti-Hacker Systen 1.2

Não acustuma .rsrs
__________________


GameZone Rox Hosting Anuncia !
50 Slots = R$15.00
100 Slots = R$21.00
Site: www.gamezonerox.net
Painel: http://painel.gamezonerox.net
Contato: atendimento@gamezonerox.com.br(ENDEREÇO NOVO)
Ip Testing Ping: 189.1.171.155:7779

www.homehots.net - Melhor Blog de SA-MP (:

[SoS]Member

[FeK]HigorOliver is offline   Reply With Quote
Old 02/11/2010, 02:51 AM   #35
Caio_Cartaxo
Gangsta
 
Join Date: Nov 2009
Posts: 563
Reputation: 15
Default Re: Anti-Hacker Systen 1.2

De boa UHSAHUASHUSHUSAHUSA'
Caio_Cartaxo is offline   Reply With Quote
Old 11/04/2011, 09:52 AM   #36
leingod
Big Clucker
 
leingod's Avatar
 
Join Date: Mar 2011
Location: Indonesia, Balikpapan
Posts: 125
Reputation: 4
Default Re: Anti-Hacker Systen 1.2

translate it to english pls
__________________
Quote:
Whenever you're feeling down, desperate, just remember you were the fastest sperm!
[FilterScript]
Leingod's Team Chooser System. v.1.0
Leingod's TextDraw Message Box

[Include]
Leingod's TextDraw Message Box
leingod is offline   Reply With Quote
Old 21/06/2012, 04:41 PM   #37
Nunes
Little Clucker
 
Nunes's Avatar
 
Join Date: Jun 2012
Location: Brazil
Posts: 6
Reputation: 0
Default Re: Anti-Hacker Systen 1.2

Higor, preciso compilá-lo (não se preucupe não sou noob o bastante para remover os créditos), mas preciso dos includes #include <SII> e #include <for> (SII e for) para compilá-lo... é que stou scripting para servidores internacionais, preciso traduzi-lo. vc pode postar eles aqui? ou enviar por e-mail.. ?
Nunes is offline   Reply With Quote
Old 21/06/2012, 04:59 PM   #38
Edu33
High-roller
 
Edu33's Avatar
 
Join Date: Apr 2012
Location: Tanzânia
Posts: 1,135
Reputation: 95
Default Re: Anti-Hacker Systen 1.2

/\ O tópico é de dois mil e dez eu ja ia comentar LOL
Cava maldito!
__________________


UM USUÁRIO QUE EXISTIU À ALGUNS TEMPOS ATRÁS

░░░░░░░░░░░▄▄▄▄░░░░░░░░░░░░░░░░░░░░░░░▄▄▄▄▄
░░░█░░░░▄▀█▀▀▄░░▀▀▀▄░░░░▐█░░░░░░░░░▄▀█▀▀▄░░░▀ █▄
░░█░░░░▀░▐▌░░▐▌░░░░░▀░░░▐█░░░░░░░░▀░▐▌░░▐▌░░░ ░█▀
░▐▌░░░░░░░▀▄▄▀░░░░░░░░░░▐█▄▄░░░░░░░░░▀▄▄▀░░░░ ░▐▌
Edu33 is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Hacker got me :O DaneAMattie General 1 10/08/2010 12:48 PM


All times are GMT. The time now is 10:24 AM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.