script: CScript gains template matching support