added rect as structure in gameObject