Cursor and float prop

Hi guys. I got another question. I want to create a Float property in a Panel with which i want to control the z coordinate of the cursor. I know the basics but i don’t know how to make this interactive. Can anyone lend a hand?

there is already a set of float props in the N-panel for the cursor

right click on one of them and select Edit Source if you wanna see how it’s done (but it’s fairly simple, there’s nothing interactive you need to script)