Core/Misc: replace (Player*) casts with ToPlayer()