Video Problem

I have alot of avi videos downloaded off various P2P sharing programs. I mostly download anime.

The video plays perfect and without a hitch, but when I encode the video to mpeg the problems in the video show. I dont understand why Windows Media Player can play it perfect but when encoded the blocks in the video scramble in some parts. I have used Virtual Dub, AviFix, and many other programs to fix this. Is their a way to record the video from WMP to make a good video to encode? I have all the codecs needed. I dont want to delete the bad frames if they do not show when played on WindowsMediaPlayer(original file played Avi), their must be a way! I do not want to find another source. I wish to learn how to fix videos. Any help you can give me would be great. Have a video tool program I should try let me know. Thank you.

What i have done in Virtual dub: redrive keyframe + opend in avi compatability mode. Video Full Processing - Audio full processing. Nothing fixes the scrambled frames but doesnt show when played on WMP.
TMPGEnc is what i use to encode to mpeg.