Partially true, partially not.
The "number" is the displacement of the engine. A .25 engine has a displacement of 1/4 of a cubic inch. Just to confuse things, a 25 engine also has a displacement of 1/4 of a cubic inch, because people got in the habit of leaving off the decimal point very early in the game. Even more confusing yet, if the engine is a 25 and as big as two fists, then it's a 25cc engine.
So, assuming that you have two engines of the same basic design and different displacements, the one with the bigger number will be proportionally more powerful: an OS 46LA can fly a much bigger plane than an OS 25LA.
Is this complicated enough yet? No? You want it to be more confusing yet? Good! I can help you out!
There is a really wide range of power outputs that can be had from various different engines of the exact same displacement. Worse, you can take one engine, and by shuffling propellers, venturis, exhaust systems and launch RPMs around, and get a wide range of power outputs (this is how speed guys entertain themselves). An OS 40LA produces far less maximum power than an OS 40FX (or 40FSR, etc.), and produces more maximum power than an old OS MAX 40S.
Even worse, if you're talking control line stunt, you absolutely positively do not want the engine to be putting out it's maximum power all the time -- if ever. Setting an engine up for maximum power output and stuffing it into a control line stunt plane probably isn't the absolute worst thing you could do, but it would certainly lead to abyssal pattern performance (and muscle strain in your right arm, to boot).
As an example, if there aren't top pattern pilots using 40-sized engines on pipes (OS 40FSR, I think, and RoJett 40s) then they only changed out recently -- but you can take a piped 40 out of a pattern plane, put a RoJett 78 (I think that's right) into the same plane and get equally satisfactory, if significantly different, engine runs.
If you're a beginner to this whole stunt thing, then based on my experinces my suggestion is thus:
OS 20FP for planes up to about 400 square inches.
OS 25LA for planes up to about 500 square inches.
OS 46LA for planes up to about 620 square inches.
You don't have to limit yourself to OS engines -- these are just the ones that I have personal experience with (well, plus a Tower 40, 40LA and a Magnum 36). Enya engines come well recommended, and there are options for engines specifically designed for control line stunt ranging from slightly more than hobby shop prices (Stalker, to name one) up to super-duper professional engines (RoJett and PA).
Probably the best way to figure out what engine/plane combination to use is to ask here -- start a thread saying that you've got a specific plane in mind and ask what engine it'll work with, or start a thread saying you have a specific engine and ask what planes will work with it. Then, because there's a pretty wide range of opinions and ability levels on the group, sort the answers by who's talking (I look at contest results and give more weight to the guys who do well in Advanced and Expert -- so, by my own criteria, you shouldn't listen to me). And if a guy named Randy Smith or another one named Brett Buck says that a combination is good -- believe it.