There were ones like, for example, Mali, who were actually pretty powerful and massively wealthy, or Ethiopia who actually had managed to keep themselves alive.
Obviously there's a lot that can be said here but this answer by /u/Georgy_K_Zhukov on Ethiopia's complicated relationship with European powers and the way they worked to get an independent military able to fight them off is a fascinating look at one facet of your question https://www.reddit.com/r/AskHistorians/comments/cu0meo/comment/ey6818w/