[TOMT] [Movie] Fantasy kids movie

Trying to find a movie back from the late 80s maybe earlier 90s. It’s about a kid whose father is a king in a fantasyland. The kid doesn’t live with him durning his childhood or doesn’t know his dad’s a king but maybe around 10 he find out who his dad is. The kid then goes to this fantasyland and lives with his dad. One scene I remember vividly is the boy and a friend are in a cave playing pan flutes together. This cave was smaller and dark. Thanks in advance if you can help solve this decades long mystery.