Closed #3048: cc.rect can receiving different type parameters now

cc.rect can receiving different type parameters now