How to ignore two axis on Vector3

Hello guys,

The context of my question is a bit long to explain but I search the way to do this :

if(mesh.bounds.size == Vector3(this number doesn't matter, 0.2, this number doesn't matter)){
...
}

If the goal was to create an object i could use Random.range but the goal is to identify an object so i don’t know what to do. I’m new to unity by the way.

Many thanks in advance

For your 2 axis you don’t care about x and z just re input the x and z axis in from mesh.bounds.size.

if(mesh.bounds.size == Vector3(mesh.bounds.size.x, 0.2, mesh.bounds.size.z)){
...
}

ooh ok ahah it’s as simple as that thank you very much!

Or you could just check y axis only, I was thinking a little slow on the first answer

if(mesh.bounds.size.y == 0.2f){
...
}