I'm currently working on a project and I'm trying to scale an image down. I have a hitbox determined by the following code.
public Rectangle bound
{
get
{
return new Rectangle((int)position.X, (int)position.Y,
texture.Width * (int)scale.X,
texture.Height * (int)scale.Y);
}
}
This works assuming the scale is either one or greater. However, when I input a scale value less than one collisions don't work and the Console.WriteLine() function returns {X:300 Y:300 Width:0 Height:0}. Is there something I'm doing wrong?