Hearts manager Gary Locke paid tribute to his side's character after two late goals snatched a dramatic 3-3 draw at St Johnstone.