Paltalk Admin Bot 9.9

Paltalk programs

Re: Paltalk Admin Bot 9.9

Postby Mbirmbilis » Thu Aug 19, 2010 12:01 pm


Hello locohacker!
It was this delay. As i told you i have no idea of programming. May be it is something that should stay as You changed it. But the swearbounce should work! Aswell the Autobounce and the Autoredot do not work! The question is why? Did Paltalk change something and the prog does not work? I realy don't know!

locohacker wrote:Aigh, I put a delay on the bouncing. One thing does it happens when you try to redot them, and see if it takes you out right after the bounce window comes on or like a second later. Here, its not an installer is just the files in a folder :swift:
Mbirmbilis
imFiles Newbie
imFiles Newbie
 
Posts: 12
Joined: Sun Jul 11, 2010 6:29 pm

Re: Paltalk Admin Bot 9.9

Postby express01 » Fri Aug 20, 2010 2:42 am

Might i have the source code for the Bot please?
Thanks alot !
express01
imFiles Newbie
imFiles Newbie
 
Posts: 9
Joined: Fri Aug 20, 2010 2:35 am

Re: Paltalk Admin Bot 9.9

Postby String » Fri Aug 20, 2010 4:37 am

express01 wrote:Might i have the source code for the Bot please?
You might. Have you tried searching this forum for it?
-= Please ask your questions in the forum, not in pm.
String
imFiles Senior
imFiles Senior
 
Posts: 313
Joined: Mon Mar 10, 2008 7:06 am
Location: IDE

Re: Paltalk Admin Bot 9.9

Postby Departure » Fri Aug 20, 2010 6:29 am

Yes auto bots can be hard to code, I used a Pos in delphi meaning that if a string exists in another string it will return its position in that string, so in other words if it does not exsists it will return 0, I dont know if this helps but it might be useful

procedure TForm1.HandleRmText(copyDataStruct: PCopyDataStruct);
var
sData, sNickname: string;
iLoop, iFound: Integer;
begin

if NOT isAdmin then
Exit;

iFound := 0;
sData := PChar(copyDataStruct.lpData);
Trim(sData);
sNickname := GetToken(sData, ':', 1);

for iLoop := 0 to pred(lbWords.Count) do
begin
iFound := iFound + PosEx(Uppercase(('>' + lbWords.Items.Strings[iLoop] + '<')), Uppercase(sData));
iFound := iFound + PosEx(Uppercase(('>' + lbWords.Items.Strings[iLoop] + ' ')), Uppercase(sData));
iFound := iFound + PosEx(Uppercase((' ' + lbWords.Items.Strings[iLoop] + '<')), Uppercase(sData));
iFound := iFound + PosEx(Uppercase((' ' + lbWords.Items.Strings[iLoop] + ' ')), Uppercase(sData));
if iFound <> 0 then
begin
case Integer(lbWords.Items.Objects[iLoop]) of
0: RedDotNick(sNickname);
1: BounceNick(sNickname);
end;
iFound:= 0;
end;
end;
end;


Basically I set EVERYTHING to uppercase and then chack if the word is used at the beginning of the line or just by its self or in-between or at the end the of line.. so 4 checks are done for each word in Auotbounce/Autoban AKA "SwearBot" so it minimizes the chance of missing a word.
User avatar
Departure
Global Moderator
Global Moderator
 
Posts: 996
Joined: Thu Mar 17, 2005 11:26 am
Location: Australia

Re: Paltalk Admin Bot 9.9

Postby autopilot » Fri Aug 20, 2010 7:01 am

Departure wrote:Basically I set EVERYTHING to uppercase and then chack if the word is used at the beginning of the line or just by its self or in-between or at the end the of line.. so 4 checks are done for each word in Auotbounce/Autoban AKA "SwearBot" so it minimizes the chance of missing a word.

With VB6, the InStr function returns the possition if a string match is found. It does not matter were in the line it matches, or what is before or after. The case however is included in the evaluation and therefore a force to upper or lower case should be done with the InStr call. So only 1 check needs to be done using InStr as long as both input and pattern are in the same case.

loco, in your timer, you get the last line and then run all your bot actions on it. this is the reason for the multiple bounce attempts. you need to put the different bot actions into there own subs and you need a variable to hold the last incoming text. then do a check against the the last text and incoming text and only run your bot actions if it is new incoming text.
Code: Select all
'if last text and incoming are different
If Not incomingtext = lasttext then
    'process new incoming
    'save new incoming
    lasttext = incomingtext
    'if bot is on, then run its check
    if swearboton then checkswear(lasttext)
    if greeteron then checkgreet(lasttext)
    if whateverboton then dowhatever(lasttext)
end if


the code above is just the logic not actual code
User avatar
autopilot
Forum Moderator
Forum Moderator
 
Posts: 358
Joined: Sat Sep 23, 2006 7:19 pm

Re: Paltalk Admin Bot 9.9

Postby Departure » Sat Aug 21, 2010 4:56 am

autopilot wrote:With VB6, the InStr function returns the possition if a string match is found. It does not matter were in the line it matches, or what is before or after. The case however is included in the evaluation and therefore a force to upper or lower case should be done with the InStr call. So only 1 check needs to be done using InStr as long as both input and pattern are in the same case.


Yes I understand that, But notice the Integer value "If > 0" meaning that if any of the search patterns are found it will bounce/kick/red ect... Reason for the 4 checks is because if it was plain "asshole" as bad word and someones nickname was "ImAaSShOle" <--- For example it would bounce this person no matter what because you are ONLY looking for word "asshole" so you need to look for the word by self example " asshole " and then look for the word as being the first word in the lastline example ">asshole " or last word in last line example "asshole<" so what we are trying to do is NOT look for the Word "asshole" but look for the word in how it might be used otherwise it might bounce people with that word in there nicknames or sub word of a word. So if any of these matches are found the integer value becomes greater than 0 which mean bounce them.

Sorry if this makes no sense at all to you, It makes perfect sense in my twisted way of thinking im just sorry I couldn't explain it better.

Now for second part of my example, Use a case statement to determine if the bot should bounce/kick/reddot the user...

if iFound <> 0 then
begin
case Integer(lbWords.Items.Objects[iLoop]) of
0: RedDotNick(sNickname);
1: BounceNick(sNickname);
end;

The case Statement will only get executed if the pattern matches(what I described above). Basically for each item in the list I have set a "Tag" or knowen in Delphi as Object ID which when adding the "BadWord" to the list it also added "Tag" to that word in this case if the tag was 0 it would reddot the user or if I had set it 1 when adding the "bad word" it would bounce the user. This removes the need for multiple checks and multiple lists. Also in theory should speed up your code because we are using "case of" statement instead of "if then" and not to mention it will only need to search through 1 list not half a dozen. Hope this help you loco.

Just another Idea, in your "bad word" list you could assign a image 1 image for bounce and another for reddot, when checking the list check what image is used and based upon the image used you will know if you should reddot the user or bounce the user. Also would cool to see little images instead of heaps of different lists



P.s
@AutoPilot
Nice to see your still around mate, Long time since we talked, Hope to catch up with you soon
User avatar
Departure
Global Moderator
Global Moderator
 
Posts: 996
Joined: Thu Mar 17, 2005 11:26 am
Location: Australia

Re: Paltalk Admin Bot 9.9

Postby autopilot » Sat Aug 21, 2010 3:37 pm

Departure wrote:P.s
@AutoPilot
Nice to see your still around mate, Long time since we talked, Hope to catch up with you soon

i been trying to get you on messenger, but not been seeing you. :(

anyway, if a sensored word is in the nic, then we most likely dont want that person in room anyway! but the way i do it, i strip the nic off before running checks in chat text.

EDIT: I do understand the thought to check for the word as stand alone, but people like to get past the bot by running words together. So if i were to make a censorbot, i would leave it to the user to decide what is censored and what is not. and they can be as tough or loose as they want in the list, but if the list word is contained in the post, no matter how it is used, it bounces. this means that small words that can easily be used in other non offensive words dont get added to the list.
User avatar
autopilot
Forum Moderator
Forum Moderator
 
Posts: 358
Joined: Sat Sep 23, 2006 7:19 pm

Re: Paltalk Admin Bot 9.9

Postby express01 » Mon Aug 30, 2010 11:04 am

can i have the source code for the latest stand of the admin bot please?

Thanks!
express01
imFiles Newbie
imFiles Newbie
 
Posts: 9
Joined: Fri Aug 20, 2010 2:35 am

Re: Paltalk Admin Bot 9.9

Postby locohacker » Mon Aug 30, 2010 11:13 pm

Here the latest, I haven't done more changes cause I am back to school :D man I got some hard classes this year lol anyways chek it here I pus it in this post for ya
paltalk-9-9-source-codes-t32314.html#p81245
User avatar
locohacker
Site Admin
Site Admin
 
Posts: 4364
Joined: Fri Dec 31, 2004 6:59 pm

Re: Paltalk Admin Bot 9.9

Postby express01 » Tue Aug 31, 2010 1:06 pm

thanks alot locohacker :D
express01
imFiles Newbie
imFiles Newbie
 
Posts: 9
Joined: Fri Aug 20, 2010 2:35 am

Previous

Return to Paltalk Programs

 


  • Related topics
    Replies
    Views
    Last post

Who is online

Users browsing this forum: No registered users and 0 guests