Hark! Coding!
Hmm the only thing that I can think of that might be wrong is the layers. Have you made sure than the texture is merged into one layer?