[Alpha] BMS RESTful Client/Server API
-
Just a little project I worked on the last couple of hours. It utilises the shared memory of falcon bms to read the current player list and export it via HTTP as json. It could be used to show the current player count and player list for your squadron servers on the squadron homepage. Requires the client running this to be in 3d(which is common for most squadrons).
Sample output:
{ "pilots": [ { "name": "bawki" } ], "pilotsOnline": 1 }
Can be used to read any value that is exported into shared memory, potentially could be used to also issue cockpit commands to the client running the server(not implemented). Let me know what type of values you would like to read, the list is available in your Falcon directory(FalconBMS\Tools\SharedMem\FlightData.h).
-
Very interesting, bawki! it’s always good to see BMS improve on the cross-platform side…
uwe
-
Yes very good idea.
-
Interesting, the guys at FO appear to use live steaming from the server but this would be a lot more efficient. The currentTime would be a good one to include.
-
Interesting, the guys at FO appear to use live steaming from the server but this would be a lot more efficient. The currentTime would be a good one to include.
Yeah that is sort of what made me start this little side project, also I added currenttime. See: https://github.com/bogie/Falcon-BMS-Server-Status/releases/tag/0.2
-
Just wanted to say thanks to Bawki. We have implemented this on our website and it is working fantastic
-
Thanks Bawki for making this available to the community, as X said we have it up and running and it works great, one question though, do you know what change would need to be made to pull the day of the campaign in addition to the current time which is already there?
-
Hmm can you check if the currenttime is seconds since 0:00 or if it is from the start of the campaign(5:00 day1 if i recall correctly). Otherwise the bms devs would have to export the current day in shared memory.
-
Unfortunately it is HH:MM:SS. Xtacy thought it may be what you said but wanted to check here also. Thanks for the response and putting this together. It is located here in the top right if you want to have a look.
-
I had some hope, since in the campaign save files they use seconds since the start of the campaign, which is at 05:00(or 06:00?). But since this is cockpit data, they are probably just using time of day. I wonder if there is any date display in the f16 pit. If so then we could probably request for an export, but I have yet to see anything like this. It would be required for GPS guidance though, so the F16 should have the date saved SOMEWHERE.
-
I would have to check the time page on the ICP next time I get on, I dont think there is a day but I could be wrong. We have a work around for now that does it externally, so that works for now.