Hey, sorry. I see you aren't setting the UV co-ords when your adding a vertex. This must be done so the texture is layed out properly.
try that :)
v0=AddVertex sideSurface,-1,-1,-1,0,1 v1=AddVertex sideSurface, 1,-1,-1,1,1 v2=AddVertex sideSurface, 1,-1, 1,1,0 v3=AddVertex sideSurface,-1,-1, 1,0,0 AddTriangle sideSurface,v0,v1,v2 AddTriangle sideSurface,v0,v2,v3
try that :)