Complex sentence: Juba arrives and compliments Cato's strong leadership, and Cato expresses gratitude for Juba's loyalty, promising to give him whatever he wants as repayment when the war ends.
Split into simpler sentences: Juba arrives and praises Cato's strong leadership, prompting Cato to express gratitude for Juba's loyalty. Cato promises to give Juba whatever he wants as repayment for his service when the war ends.