Jump to content

Question

Posted

#include <a_samp>

//Created buy Vampir_MD

#define MAX_MSG 24

#define MAX_ENIS 120

#define red 0xFF0000AA

#define G  "{6EF83C}"

#define R  "{F81414}"

#pragma tabsize 0

static V_pro[MAX_ENIS][MAX_MSG];

public OnFilterScriptInit()

{

if(fexist("V_pro.txt"))

{

new File:V_myFile,

    V_Lie[MAX_MSG],

        inxv=0;

    V_myFile=fopen("V_pro.txt",filemode:io_read);

      while(fread(V_myFile,V_Lie,sizeof V_Lie) && (inxv != MAX_ENIS)) {

    if(strlen(V_Lie)>MAX_MSG) continue;

    StripNewLine(V_Lie);

  strmid(V_pro[inxv],V_Lie,0,strlen(V_Lie),sizeof V_Lie);

inxv++;

}

}

return 1;

}

public OnPlayerText(playerid,text[])

{

    new id;

for(new i=0; i<MAX_ENIS; i++)

{

    if(!V_pro[0]) continue;

          new BigString[1900];

          strcat(BigString, ""G"Ai folosit un cuvant urat ,"R"Ai Kick\n", 1900 );

          strcat(BigString, ""G"Pentru urmatoare data mai gandeste-te ce scri.\n", 1900 );

  ShowPlayerDialog(playerid, 1000, DIALOG_STYLE_MSGBOX, "{6EF83C}----- {F81414}Waring Kick{6EF83C}-----", BigString, "-->oK<--","");

  Kick(id);

MSGPRO(text,V_pro);

}

return 1;

}

stock StripNewLine(str[])

{

new V = strlen(str);

while (V-- && str[V] <= ' ') str[V] = '\0';

}

stock MSGPRO(string[],word[],destch='*')

{

new ON_inxv=(-1),

    OF_inxv=(-1);

ON_inxv=strfind(string,word,true);

  if(ON_inxv==(-1)) return false;

OF_inxv=(ON_inxv+strlen(word));

for( ; ON_inxv<OF_inxv; ON_inxv++)

          string[ON_inxv]=destch;

return 1;

}

Folosesc acest FS dar cand injur imi da direct server closed connection fara sa imi dea nici un mesaj

7 answers to this question

Recommended Posts

Posted

NexT." post="136519" timestamp="1364111724"]

Schimba 

Kick(id);

MSGPRO(text,V_pro);

in

MSGPRO(text,V_pro);

Kick(id);

Imi da asta [pawn]error 048: array dimensions do not match[/pawn]

Posted

Si inainte iti dadea eroarea ? Trebuie sa pui sa apare mai intai mesajul, iar apoi Kick, deoarece daca ii da Kick mai intai nu mai apare mesajul.

35012l1.png.aee1a3398b9bd9f8eec50574d2cd

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.