ported includes from scriptdev2R2