From 7550ff70d9eebbf64cf5ead11a3c8a65eb2bc8a6 Mon Sep 17 00:00:00 2001 From: Julian Smith Date: Sun, 18 Aug 2019 22:06:57 +0100 Subject: [PATCH] Nasal/view.nas: set new property /sim/current-view/multiplayer to 0 or 1. Useful to have this information available as a simple property. --- Nasal/view.nas | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Nasal/view.nas b/Nasal/view.nas index f6f5a6f3d..cb4ec83a0 100644 --- a/Nasal/view.nas +++ b/Nasal/view.nas @@ -530,8 +530,10 @@ var model_view_handler_class = { setup: func(data) { if (data.root == '/') { var ident = '[' ~ data.callsign ~ ']'; + setprop('/sim/current-view/multiplayer', 0); } else { var ident = '"' ~ data.callsign ~ '" (' ~ data.model ~ ')'; + setprop('/sim/current-view/multiplayer', 1); } me.current = data.callsign;