Creating the 3D city In this tutorial we are just going to carry over some of the changes from the last one, since the only method we need to change is copied from it and extended. So we change this line in the SetUpVertices() method: cityVertexBuffer = new VertexBuffer(device, verticesList.Count * VertexPositionNormalTexture.SizeInBytes, BufferUsage.WriteOnly); cityVertexBuffer.SetData (verticesList.ToArray()); to this: cityVertexBuffer […]

Loading the floorplan We start this tutorial with something that should be very familiar by now the VertexDeclaration so we can remove this: VertexDeclaration texturedVertexDeclaration; In XNA Game Studio 4.0 the VertexBuffer syntax changed slightly now we don’t need to tell the graphics card the size of memory to allocate, XNA does that under the hood once […]