From: Anders G. <and...@gi...> - 2007-07-07 08:44:28
|
On Sat, 7 Jul 2007, Melchior FRANZ wrote: > This code sets the same value for all selected engines to the js/mouse > value. But if they weren't all at the same level, this would mean that > some make abrupt jumps. Applying the same delta to all selected engines > would be nicer, but has its own problems ... :-/ Actually, throttleMouse applies a delta while throttleAxis sets an absolute value (unless I misread the code). That behaviour at least makes some kind of sense.. :) > I'd rather make a function something like this: > > var selectEngines = func(state, engines...) { ... > } Ah, yes that is much nicer. I hadn't grasped the argument list possibility. Thanks for the code review! Updated diff: http://www.gidenstam.org/FlightGear/misc/controls.nas_individual_throttles.diff Cheers, Anders -- --------------------------------------------------------------------------- Anders Gidenstam mail: anders(at)gidenstam.org WWW: http://www.gidenstam.org/FlightGear/JSBSim-LTA/ |