Punkbuster will detect the DirectX Tweaker as cheat and kick you. To stop this you need to change some settings in your Battlefield 2 profile. 

DirectX 9 tap: select Direct3D 9 ; Alternate 1 ; Force Loading
DirectX 8 tap: deselect all
Legacy tap:  deselect all
Options tap: deselect all

