Recent research says that chess is a positive form of mental training:
Buraida reported on the authority of his father that Allah’s Apostle (ﷺ) said:
He who played Nardashir (a game similar to backgammon) is like one who dyed his hand with the flesh and blood of swine.
Sahih Muslim 2260
Book 28, Hadith 5612