Query File Path of .lock File


I’m currently writing a script and I’m hoping to find the file path of the current open sbpz file. I can’t seem to think of a good way to do this unless I somehow query the .lock file that gets created but I’m not sure where that file path would be stored.

Any help is appreciated!

Thank you