You can have a search for 'mds' (Molecular dot surface) code, based on M.L Connolly's publication in Science and J. App. Cryst. (1983).
In principle, you can calculate the solvent surface accessible area (the so called sasa) of ligand without protein and in complex with protein, then the difference will give the buried surface of ligand, which can be converted in percentage by dividing with total sasa of ligand.
Or you can try our two algorithms, the "Tangent Sphere Method" and the "Cutting Plane Method" -- please see S. Cheguri and V. M. Reyes here in ResearchGate or in arXiv.org (full text is available).