For QGIS 3.8 or greater, generating tiles is built in - you can find it in the Processing tool box as Generate XYZ tiles (Directory) and Generate XYZ tiles (MBTiles).
For QGIS 3.8 or greater, generating tiles is built in - you can find it in the Processing tool box as Generate XYZ tiles (Directory) and Generate XYZ tiles (MBTiles).