Guest Airsoft3r Odesláno: 26. Únor, 2010 Share Odesláno: 26. Únor, 2010 ... Pridávam sem svoj druhý MiniTuT-ík o cenzúre s vlastnou zložkou pre cenzúrované slová aké chcete... ===> DEFINE <=== #define MAX_SWEARS 100 #define STR 100 ===> NEW <=== new Swears[MAX_SWEARS][sTR]; new num_words = 0; ===> OnFilterScriptInit/OnGameModeInit <=== new string[sTR], File:file; if((file = fopen("cenzura.cfg",io_read))){ while(fread(file,string)){ FixChars(string); for(new i = 0, j = strlen(string); i < j; i++) if(string[i] == '\n' || string[i] == '\r') string[i] = '\0'; Swears[num_words] = string; num_words++;} fclose(file);} ===> OnPlayerText <=== FixChars(text); for(new s = 0; s < num_words; s++){ new pos; while((pos = strfind(text,Swears[s],true)) != -1) for(new i = pos, j = pos + strlen(Swears[s]); i < j; i++) text[i] = '*';} // Tu máte hneď na konci text(i) = '*'; takže to znamienko * sa bude zobrazovať miesto cenzurovaných slov ===> Niekde kde je voľno, ale najlepšie miesto je pod OnPlayerText <=== FixChars(string[]) for (new i=0;i [color=#FF0000][size=150]//EDIT !! Skoro by som zabudol, že si musíte vytvoriť súbor cenzura.cfg a dať ho do zložky scriptfiles do toho súboru si potom vypíšete slová, ktoré chcete cenzúrovať ![/size][/color] PS:// Je to len MiniTuT, takže nic moc..ale niekto by to chcel na svoj server. ([color=#40BF00]Mám to sám na svojom servery.[/color]) Link to comment Share on other sites More sharing options...
DonMafia 14 Odesláno: 26. Únor, 2010 Share Odesláno: 26. Únor, 2010 Už som to tu videl. Presné také isté Link to comment Share on other sites More sharing options...
Guest Airsoft3r Odesláno: 26. Únor, 2010 Share Odesláno: 26. Únor, 2010 Už som to tu videl. Presné také isté Hmm..tak to sorry, lebo ja nie.. Link to comment Share on other sites More sharing options...
DON 1 Odesláno: 1. Březen, 2010 Share Odesláno: 1. Březen, 2010 ZKOPÍROVÁNO airsoftere ses nula http://pawnobox.net/smf2/index.php?topic=2177.0 Link to comment Share on other sites More sharing options...
Guest Smok3RS Odesláno: 3. Březen, 2010 Share Odesláno: 3. Březen, 2010 jjj Link to comment Share on other sites More sharing options...
Roox 1 Odesláno: 3. Březen, 2010 Share Odesláno: 3. Březen, 2010 To SmokeSVK: To ze jsi novacek, neznamena ze tady muzes spamovat prispevkem jako napr jjj Jinak tohle to mam v mode akorad trosku jinak udelany a je fakt, ze si mohl aspon napsat, ze je to zkopceny. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now