For the most part Europeans could almost always rely on their superior military technology to coerce local rulers into doing what the Europeans wanted and they could replace native officials with Europeans if they had to, but in general they preferred to rule indirectly. 