It's been a couple months since I touched that however I vaguely remember the id capping at a rather low value.
I have dozens of script_xxxxxx.pl files that I use, nothing higher then 32767, that works, so just keep that in mind if it doesnt work.
You probably already found it but you just modify scriptfileid for the item in question.
IE /quests/items/script_12520.pl --> scriptfileid = 12520
__________________
|