Pathfinder – How can an NPC call for help visible and heard?

This is a bit related to How can I send messages over long distances?
However, this concerns D & D 5th and my question is address to Pathfinder.

I have an idea of ​​the catchy story and could use some help to clarify the logic required.

Scenario: An NPC is trapped in a crypt / dungeon. The PCs are in another area of ​​the plane, exploring a dungeon / cave. When the PCs enter a tunnel, they leave the plane in the desert. Upon arrival, the PCs see an audio-visual call for help. (Think of Princess Leia's help, Obi-Wan Kenobi.) NOTE: They are now close enough to help the NPC.

How can an NPC call for help who is seen and heard? It could be triggered when it detects humanoids nearby or is on a loop.

I'm not so interested in connecting a cave to the desert. But if someone knows a reference to explain this, it would also be useful.