[s1894] Implement water script support for SSC water

This requires additional support from SD2 side
Also slightly improve performace on the UpdateunderwaterState function usage

(based on commit [12361] - b630110)