I experimented a little with the skinning sample downloaded from creators.xna.com and I've managed to add it into my own engine. I had several problems like the content processor was attaching the shader while processing the model but I've managed to deal with it. My problem is this. See the bad one picture.... You see the problem

Now, see the good one picture. You're probably asking, what the hell??
When i don't scale the model, i just load it and draw it, it looks like on the bad one picture.
When i scale the model to 0.001f, 0.001f, 0.001f it displays perfectly, with no other changes! Only i have to zoom in the camera to see the model.
What could it be??
I think it's something with the camera, because it's not the first model i've had problems. And just to know, I made my own camera class, which contains some of the code from HM Engine
Here it is
#region NCameraTPS class
/// <summary>
/// A third person camera
/// </summary>
public class NCameraTPS : NCamera, NICamera, NICameraTPS
{
#region Variables
NObject parentedObject = null;
NInput input = null;
#region Fields
private float CAMERA_ROTATION_Y = 0.1f;
private float CAMERA_ROTATION_X = 0.1f;
private float hRotation = (float)Math.PI / 2.0f;
private float vRotation = 0.5f;
private float radius = 1.0f;
private bool CAMERA_OBJECT_ROTATION = true;
private bool CAMERA_ZOOM = true;
private float zoomInValue = 0.01f;
private float minRadius = 0.3f;
private float maxRadius = 3.0f;
/// <summary>
/// The camera radius
/// </summary>
public float CameraRadius
{
get { return radius; }
set
{
radius = value;
if (radius < minRadius) radius = minRadius;
if (radius > maxRadius) radius = maxRadius;
}
}
/// <summary>
/// Do we want to rotate around the object??
/// </summary>
public bool CameraRotateAroundObject
{
get { return CAMERA_OBJECT_ROTATION; }
set { CAMERA_OBJECT_ROTATION = value; }
}
/// <summary>
/// The Y rotation of the camera
/// </summary>
public float CameraRotationY
{
get { return CAMERA_ROTATION_Y; }
set { CAMERA_ROTATION_Y = value; }
}
/// <summary>
/// The X rotation of the camera
/// </summary>
public float CameraRotationX
{
get { return CAMERA_ROTATION_X; }
set { CAMERA_ROTATION_X = value; }
}
/// <summary>
/// The horizontal camera rotation
/// </summary>
public float CameraHorizontalRotation
{
get { return hRotation; }
set { hRotation = value; }
}
/// <summary>
/// The vertical camera rotation
/// </summary>
public float CameraVerticalRotation
{
get { return vRotation; }
set { vRotation = value; }
}
/// <summary>
/// Do we want to zoom into the object??
/// </summary>
public bool CameraZoom
{
get { return CAMERA_ZOOM; }
set { CAMERA_ZOOM = value; }
}
/// <summary>
/// Amount of zooming in
/// </summary>
public float CameraZoomInValue
{
get { return zoomInValue; }
set { zoomInValue = value; }
}
/// <summary>
/// The minimum radius
/// </summary>
public float CameraMinRadius
{
get { return minRadius; }
set { minRadius = value; }
}
/// <summary>
/// The maximum radius
/// </summary>
public float CameraMaxRadius
{
get { return maxRadius; }
set { maxRadius = value; }
}
#endregion
#endregion
#region NCameraTPS( engineInput )
/// <summary>
/// Third person camera
/// </summary>
/// <param name="engineInput">The engine input</param>
public NCameraTPS(NInput engineInput)
{
input = engineInput;
}
#endregion
#region UpdateSpecial()
/// <summary>
/// Empty...
/// </summary>
public void UpdateSpecial()
{
//empty...
}
#endregion
#region UpdateSpecial( viewport )
/// <summary>
/// Updates the camera special abilities
/// </summary>
public void UpdateSpecial(Viewport viewport)
{
if (parentedObject == null) return;
if (input != null)
{
#region Some special actions
if (CAMERA_OBJECT_ROTATION)
{
if (input.MousePosition.X <= 10.0f)
{
hRotation += CAMERA_ROTATION_Y;
}
if (input.MousePosition.X >= viewport.Width - 10.0f)
{
hRotation -= CAMERA_ROTATION_Y;
}
if (input.MousePosition.Y <= 10.0f)
{
vRotation += CAMERA_ROTATION_X;
}
if (input.MousePosition.Y >= viewport.Height - 10.0f)
{
vRotation -= CAMERA_ROTATION_X;
}
}
if (CAMERA_ZOOM)
{
if (input.ScrollWheelValue != 0)
{
radius -= input.ScrollWheelValue * zoomInValue;
if (radius < CameraMinRadius) radius = CameraMinRadius;
if (radius > CameraMaxRadius) radius = CameraMaxRadius;
}
}
#endregion
}
if (vRotation > 1.5f) vRotation = 1.5f;
if (vRotation < 0.0f) vRotation = 0.0f;
CameraPositionX = (float)( radius * Math.Cos(vRotation) * Math.Cos(hRotation) );
CameraPositionY = (float)( radius * Math.Sin(vRotation) );
CameraPositionZ = (float)( radius * Math.Cos(vRotation) * Math.Sin(hRotation) );
CameraPosition += parentedObject.Position;
LookAtVector = parentedObject.Position;
}
#endregion
#region SetParentObject( obj )
/// <summary>
/// Sets a parent object which camera will look at
/// </summary>
/// <param name="obj">The object to look at</param>
public void SetParentObject(NObject obj)
{
parentedObject = obj;
}
#endregion
}
#endregion
Please help!
And if anyone is interested I can explain how to get the animation working...
[attachment deleted by admin]