I don't though that since all command should run internally pre-build functions within engine, so do not make sense add some command, if their function is not created yet within the engine.
Better so, follow the Teabone's guidelines; write some script, declare global variables, even a counter variable and increase it by 1, each time any item is collected.
Since you know how many colletable items you put in your map, put this quantity into variable, named lets say <nItems>. Well, when variable called <counter> being equal to <nItems>, so game over.
Reloaded automatically advise you about the item collected.
Since I'm really new with LUA, no sure if you can declare a very hight variable, so you can use it to hold values, even increase it, and being acceced for any script in any moment for query/add/modify its value.
Also would be useful be able to declare static variables.
As you can see, I can give the theory, but the LUA script is other history, I've my doubts like you.
3com