RTS Rules:
1) #clearall, if used, must be at the top of your script, or else everything before it will be cleared
2) #version and #define values, if used, must be after #clearall, but before the rest of your script
3) a radiustrigger can only exist between start_map and end_map
4) all other functions can only exist between radiustrigger (or rect_trigger) and end_radiustrigger
5) functions can be in any order, as long as they are between radiustrigger (or rect_trigger) and end_radiustrigger
Check your spelling and values carefully, and add a few functions at a time, then test.
Just like DDF development, adding a lot of entries without testing makes it much harder to find problems. If you add a little and test often, you have less scripting to rummage through to find errors.