Code showing error: can't implicitly convert type float to int. Are you missing a cast?

Guys I don’t know how to solve this error and if I have to change my values from float to int then my whole scene will be messed up. Please if anyone can help I’ll be much thankful.

You can cast x and y to ints explicitly:

chessPieces[(int)x, (int)y]

Whether that’s a good idea or not depends. Are these going to be perfect integral values? Converting to an int in this way will truncate any fractional part of the number. For example 3.8 would become 3.

Thank you sir but it looks like I have to change my point values from float to int.
It’ll gonna effect my chess board model greatly but it had to be done because of this error.