there r plenty of em, but ill explain roughly
in beginning of the game create a game cache and set it as a var
when the hero enters that rect save the heroes in that cache variable as 'hero type' for 'number of the map' etc, then in the submap load the hero with the same catogeries u saved it in. (may not include spaces)
i hope u understand this orelse find a good turor