I went with this as I didn’t see you replied 
parameter "ps1"="names of files whose (name of it as lowercase ends with ".ps1") of folder "C:\tmp""
waithidden {pathname of file ((it as string) of value "Path" of key "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\PowerShell\1\ShellIds\Microsoft.PowerShell" of native registry)} -executionpolicy remotesigned -File "c:\temp\mdfi\"{parameter "ps1"}""
Haven’t tested it yet though 