on alertme
set the beepSound to specialFolderPath("engine") & "/TriBeep.aiff"
--do other stuff
end alertme
This handler simply stops at 'set the beepSound'. Yes, the file is in the copy files pane of the standalone settings. If I comment out that line, the rest of the handler executes.
Did you try with parens?
...
set the beepSound to (specialFolderPath("engine") & "/TriBeep.aiff")
...
Sometimes the engine is a bit picky in this respect
And don't forget that iOS is CASE sensitive!
Just to be sure:
The sound itself plays fine with:
...
play (specialFolderPath("engine") & "/TriBeep.aiff")
...
?
Ashamed to say that this was a typo of mine in the file extension (aiff vs aif).
But what is odd is that I checked the result immediately after the 'set' command and that line did not execute, instead the set command just silently failed.
Oddly enough:
play "soundfileThatDoesNotExist.aif"
answer the result
returns empty. You would think it would return some string indicating a file not found error. I am new to LC and this is a little troublesome. Not only the result not returning an error string, but with 'set the beepsound to "soundfileThatDoesNotExist.aif"', not even being able to check the result, with script execution just stopping.
on errorDialog
put the params into field "xxx"
end errorDialog
assuming you provide a field "xxx" for every card if the script is at the stack level (I use a group whose background behavior is true) or a field "xxx" for the card if the script is at the card level.
Although the error code is not very informative at least you know there is something going on. When the app is ready I delete the field and the script.
Kind regards