Palette swap shader not working, interpolates between colors

okay well I replaced

float4 outputColor = PaletteTexture.Sample(PaletteTextureSampler, float2(((texColor.r*256) + (texColor.g*256))/PaletteTextureWidth, 0));

with

float4 outputColor = tex2D(PaletteTextureSampler, float2(((texColor.r * 256) + (texColor.g * 256)) / PaletteTextureWidth, 0));

and everything works fine now, so this is solved I guess