Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <a_samp>
- public OnFilterScriptInit()
- {
- printf("strMix(Pawno.pl) = %s", strMix("Pawno.pl"));
- printf("strMix(Pawno.pl) = %s", strMix("Pawno.pl"));
- printf("strMix(Pawno.pl) = %s", strMix("Pawno.pl"));
- return 1;
- }
- #define MAX_MIX_STRING 128
- stock strMix(string[])
- {
- new str2[MAX_MIX_STRING];
- if(strlen(string) < MAX_MIX_STRING)
- {
- new i = strlen(string) - 1;
- new str3[MAX_MIX_STRING];
- new rand;
- strcat(str3, string);
- while(i >= 0)
- {
- rand = random(strlen(str3));
- str2[i] = str3[rand];
- strdel(str3, rand, rand + 1);
- i--;
- }
- }
- return str2;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement