1
0
Fork 0
Commit graph

3488 commits

Author SHA1 Message Date
mfranz
490ed46d89 - allow selection and manipulation of multiple objects
- replace lon/lat adjustment with more predictable nearer/farther/left/right
  adjustment (i.e. movements relative to the UFO position)
- add key bindings to move objects
2007-02-26 17:57:55 +00:00
mfranz
ad8048627d add Dialog.namespace() method, which returns the XML dialog's namespace
if the dialog is open and contains embedded <nasal>, or nil otherwise.
This can be used to call dialog functions.
2007-02-26 11:00:04 +00:00
mfranz
3079726bda move dialogs from ufo.nas into dialog XML files 2007-02-24 19:48:02 +00:00
mfranz
2987f9660f let Shift-Space open property browser 2007-02-24 10:16:26 +00:00
mfranz
4ee7b32fa1 a more modern, electronic overspeed and alarm sound 2007-02-24 09:09:31 +00:00
mfranz
c2e6b853de add a note about Wolfpack for providing some of the helicopter sounds
that we are using since a while (especially in the bo105)
2007-02-24 09:04:17 +00:00
mfranz
8f977f33ff - immediately unfreeze when mouse mode changes to a non-pointer mode
- rename variable s/speed/time/
2007-02-23 22:17:55 +00:00
martin
6650f2890f Re-Add under new directory name after Melchior's removal. 2007-02-21 22:05:42 +00:00
mfranz
07754b8802 rename mag.sw/ to magneto-switch/ 2007-02-21 16:25:15 +00:00
martin
6a98c34b79 Fix typo. 2007-02-20 14:34:43 +00:00
mfranz
9fccb51f59 update, now that no aircraft overrides the n/N keys :-) 2007-02-19 21:25:30 +00:00
martin
3734cb0fd1 Dave Perry:
This patch makes the pa24 changes to use the mag.sw from Instruments 3d.
Changed the mag_switch.ac to include the pick rectangles and the
mags.xml to use the pick automation.  Also includes the edits to
pa28-161.xml and pa28-161-set.xml to use the 3d radio stack.
2007-02-19 12:08:31 +00:00
martin
eaa8d8cfb5 Ron Jensen:
I've finished (I hope) a 3D Kap-140 head.
2007-02-18 21:35:22 +00:00
mfranz
4a03f25bb6 - replace ["OFF", "ON"][i] with faster ternary operators (which didn't
exist when this was written)
- cosmetics
2007-02-18 18:33:11 +00:00
mfranz
9e11e2102f - add property /sim/startup/terminal-ansi-colors {BOOL}. This is used
by debug.nas to turn on/off syntax coloring for dumped data (which
  is desirable as compound data types can fill several screens with
  rather hard to read data). Unfortunately, it can't be reliably deduced
  from the OS whether ANSI colors are available or not.
- move "multiplayer chat" properties to where they belong
2007-02-18 17:21:50 +00:00
martin
4bf8add100 Holger Wirtz:
Trigger realtime voice communication according to PTT button.
2007-02-16 10:53:26 +00:00
mfranz
22e2a72f8e Jakub KLAWITER: "bindings for Boeder P-20 flightstick Pro USB" 2007-02-12 20:30:44 +00:00
mfranz
ef78365c1c Ed SIRETT: configuration for Saitek P880
Ron JENSEN: replaced direct property use with Nasal wrapper calls
2007-02-12 18:51:48 +00:00
mfranz
dfb4316b43 - make duration of view change configurable (default 0.2 seconds)
- extract some constants
2007-02-11 16:56:15 +00:00
mfranz
420b9bff99 allow to open several property browsers via menu 2007-02-10 23:50:41 +00:00
mfranz
7763462f24 - add some documentation
- reset values
2007-02-10 23:47:02 +00:00
martin
3831675000 Dave Perry:
Changes:
1.  remove typo from all the /Systems/KAP140.xml files
2.  changes to put radio_stack in Instruments-3d
3.  Add "pick" to vor, alt, hi, in Instruments-3d
4.  changes to pa24-250 and pa28-161 to use 2 and 3.
5.  add "pick" and "2d text in window" in 3d OAT in pa24-250
2007-02-10 21:24:46 +00:00
mfranz
7f30f1599e prevent math.ln(0) 2007-02-10 20:42:36 +00:00
mfranz
892f665997 small fix; need to remove the whole silly wrapper, anyway 2007-02-09 18:10:22 +00:00
mfranz
c587c9dd3a In mouse view mode <=> one could already move the view left/right/up/down
when dragging the mouse with middle mouse button (MMB) pressed (reset
with MMB+LMB):

Add support for forward/backward moving (MMB+KbdCtrl). With this one can,
for example, read what's written on the backside of the cup of coffee
on top of the screen in the E3B's operator room, or walk around between
the passenger seats in the fokker70 searching for the toilet.  :-)
2007-02-09 13:31:04 +00:00
mfranz
4b7c559b69 - extend lookat() function: dynamic_view.lookat(hdg, pitch, roll, x, y, z [, fov])
- use extra function for resuming normal mode after lookat: dynamic_view.resume()
- add fov (field-of-view) to interface:  me.fov_offset
- remove register_headshake and me.headshake; this can still be done via
  normal register(). If only headshaking is to be added, while keeping default
  plane view, do this:

  dynamic_view.register(func {
      default_plane();
      me.x_offset = ...
      me.y_offset = ...
      me.z_offset = ...
  });
2007-02-08 22:16:10 +00:00
mfranz
4ebd876c85 - move all module initialization code into one-shot listener
- initialize /sim/time/delta-realtime-sec, so that the lowpass filter doesn't
  complain if it's starter eraly (of course the results won't be correct
  until the delta is real)
2007-02-08 18:42:02 +00:00
martin
c7aace9926 Sava? Yatmaz:
Logitech Dual-action gamepad driver.
2007-02-08 06:56:19 +00:00
mfranz
12f5714b37 add support for x/y/z axes. The built-in function is (still) a NOOP, but
aircraft can plug a custom function. This function can access all internal
variables of the ViewManager class. It can set me.{x,y,z}_offset, and also
add offsets to me.{heading,pitch,roll}_offset. Example:

dynamic_view.register_headshake(func {
        me.x_offset = rand() * 0.02;  # Parkinson effect
});

The advantage of this implementation is that it doesn't break MMB drag
functionality, and that is can be frozen by mouse movements.
2007-02-07 22:13:51 +00:00
mfranz
b07ebf0dfa work around Nasal bug (and/or operators) 2007-02-07 17:31:41 +00:00
mfranz
caf96d76c8 minor documentation fix 2007-02-07 17:06:52 +00:00
mfranz
3bec4f4cfc - add debug.local([<frame>]) to output local variables of frame #0
or of given frame
- add debug.string(<variable>). This returns the variable dump as
  string.
- add var to module function variables to avoid collisions with module names
2007-02-07 17:06:05 +00:00
mfranz
a1556fa69a make lookat work correctly for when the user changed view direction;
Remember: dynamic_view.lookat(heading, pitch, roll) moves view
smoothly to this direction, while dynamic_view.lookat() moves it back.
This can be used for quick view changes to the panel etc. It's currently
only used in the bo105 (flaps-up binding).
2007-02-07 16:58:46 +00:00
mfranz
96cc08519b keymap update: only the f4u is left as overriding the n/N keys. Yay! 2007-02-07 00:28:48 +00:00
mfranz
e034e66c57 interpolate between frozen or lookat direction and current view direction 2007-02-06 16:25:44 +00:00
mfranz
df1bd972f8 - fix reinit/reset (has this caused the spinning view on reset for some?)
- add var to module functions to avoid conflicts with module names
2007-02-06 14:33:59 +00:00
mfranz
c9db8c22a3 don't waste time when we aren't in dyn-view mode at all 2007-02-05 22:59:51 +00:00
mfranz
286629c3e1 oh, and freeze while a button is pressed in arrow mode ... 2007-02-05 20:57:19 +00:00
mfranz
ea2d56aa33 don't generally freeze dynamic_view in arrow mouse mode, but only a short
time after mouse movements or clicks. After that period a rather ugly jump
happens. TODO: make this smoother
2007-02-05 20:36:29 +00:00
mfranz
90100e2514 disable dynamic view in mouse arrow mode. Operating all the tiny switches
on 3d panels while hopping over bumpy terrain has become difficult -- much
harder than in real life. I'm open for better solutions. Just complain. :-)
2007-02-05 16:14:51 +00:00
mfranz
0f07c14bd3 getBoolValue() on an undefined node shall return "false", not "true".
This isn't only more logical, it's also how SGPropertyNode::getBoolValue()
acts. The fix has potential to break code, but so far I haven't seen any
problems. I added a debug message to my copy and will for a while check
all cases that I run into. To check yourself, just add one line:

    getBoolValue : func {
        val = me.getValue();
+       if(val == nil) { debug.dump(me) }
        if(me.getType() == "STRING" and val == "false") { 0 }
        else { val != nil and val != 0 }
    }

This will output a debug message to the terminal for each case where
formerly "true" was returned, and now "false" is.
2007-02-05 11:40:49 +00:00
mfranz
3a3ee3a5d0 - work around broken props.Node.getBoolValue()
- simplification & cleanup
2007-02-04 22:09:43 +00:00
mfranz
43435d1077 - reset engines' consumed fuel
- change variable name
2007-02-04 20:20:45 +00:00
martin
e550dee7dc Ron Jensen:
Add panel lighting effects to transponder.
2007-02-04 13:30:10 +00:00
mfranz
10efd065c4 Dave Perry & Roy Vegard Ovesen:
"This patch allows all the AC using the kap140 to use one kap140.nas
which includes Roy's move to "bool" values as well as the check for
power used by the pa24-250." (dp)
2007-02-04 12:55:28 +00:00
mfranz
cb25691c03 call setWeightOpts on reset, too 2007-01-31 21:37:14 +00:00
mfranz
003ba28784 make sure that setWeightOpts isn't called before fuel.nas' init fdm listener.
This is a bit hackish and needs to be reconsidered.
2007-01-31 21:13:16 +00:00
mfranz
9117ddf71d --aircraft=c172p-panel-only set file (some instruments like fuel, egt,
pressure don't work yet)
2007-01-31 17:58:48 +00:00
mfranz
221c23e18b - don't create tanks in empty tank nodes (that nasty native_fdm.cxx causes)
- use Nasal features that were introduced after this code was first written:
  * var for local variables (and to make clear when a variable is first used)
  * += operator
  * listeners to import seldom changing variables and to avoid waiting for
    the FDM in a loop

This new code started as empty file where I added my stuff and then copied
parts from the old code, piece by piece. This is why the coding & indentation
style has changed. Functionally the code should basically be equivalent.
2007-01-31 15:53:01 +00:00
mfranz
80b188706f cosmetics and stuff 2007-01-30 23:22:36 +00:00