ID:1719497
 
Is there a way to make it so the context menu on right click will only show up if certain variables are met?
I think no, but you can try use lib "Custom Context Menu"
by Kidpaddle45. It's use interface to show menu.

http://www.byond.com/developer/Kidpaddle45/CustomContextMenu


Don't tie any verbs to it that players can access (i.e. set src in oview(blah)). There might be a trick to disabling it but it's easiest to avoid them altogether.