Hey there.
I'm not sure I'd technically call it a lunatic mode, but the way the formula is evaluated is line by line, like a standard function, so you could conceivably make a very complex formula with if checks that could return different values based on whether or not the user has a state, or a switch is on, or they have a specific item equipped.
<Weapon Formula> if (a.isStateAffected(26)){ return a.atk * 4 } else { return a.atk * 3 } </weapon formula>
Would be a very simple example pf this.
~Ramza