"there still had to be hope" is a clause that is the object of the verb "told". It is the same basic structure as " There is a book on the table" - "there" is a pronoun that stands in for the subject. "hope" is a noun, predicate object of the verb "had to be" The clause translates roughly as "hope still must exist"
New words, one handy idiom, and a 2-minute quiz — delivered to your inbox to keep your streak alive.