@fboes/aerofly-custom-missions 1.0.2 → 1.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +4 -0
- package/README.md +14 -12
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -2,19 +2,19 @@
|
|
|
2
2
|
|
|
3
3
|
> Builder for Aerofly FS4 Custom Missions Files
|
|
4
4
|
|
|
5
|
-
[Aerofly Flight Simulator 4](https://www.aerofly.com/) has a custom
|
|
5
|
+
[Aerofly Flight Simulator 4](https://www.aerofly.com/) has a custom missions file `custom_missions_user.tmc` with a very unique format. To help build this custom missions file, this JavaScript / TypeScript library offers Data Transfers Objects (DTOs) to create this flight plan(s) programatically.
|
|
6
6
|
|
|
7
7
|
This library is intended to work in modern browsers as well as [Node.js](https://nodejs.org/en).
|
|
8
8
|
|
|
9
9
|
## Installation
|
|
10
10
|
|
|
11
|
-
Either download the [`dist/index.js`](dist/index.js) to a sensible location in your web project, or do a NPM installation:
|
|
11
|
+
Either download the [`dist/index.js`](dist/index.js) to a sensible location in your web or Node.js project, or do a NPM installation:
|
|
12
12
|
|
|
13
13
|
```bash
|
|
14
14
|
npm install @fboes/aerofly-custom-missions --save
|
|
15
15
|
```
|
|
16
16
|
|
|
17
|
-
Instead of a local installation you may also load the library from https://unpkg.com/. Beware: This makes https://unpkg.com/ a dependency of your project and may pose data protection issues.
|
|
17
|
+
Instead of a local installation for your browser project you may also load the library from https://unpkg.com/. Beware: This makes https://unpkg.com/ a dependency of your project and may pose data protection issues.
|
|
18
18
|
|
|
19
19
|
```html
|
|
20
20
|
<script type="module" src="https://unpkg.com/@fboes/aerofly-custom-missions@latest/dist/index.js"></script>
|
|
@@ -50,15 +50,13 @@ You might want to enable TypeScript type checking by adding `// @ts-check` as yo
|
|
|
50
50
|
|
|
51
51
|
### Basic idea
|
|
52
52
|
|
|
53
|
-
All objects are basic structures needed for the
|
|
54
|
-
|
|
55
|
-
You can alter the properties of the objects afterwards, or (in some cases) by passing an optional configuration object to the constructor.
|
|
53
|
+
All objects are basic structures needed for the missions list. The constructors tell you which properties are required, and will start with sensible defaults for all other properties.
|
|
56
54
|
|
|
57
55
|
All objects can be exported as JSON or as string via the `toString()` methods. Exporting the `AeroflyMissionsList` via `toString()` gives you the complete source code for a valid `custom_missions_user.tmc`.
|
|
58
56
|
|
|
59
57
|
### Building a missions file
|
|
60
58
|
|
|
61
|
-
A mission file contains multiple missions.
|
|
59
|
+
A mission file contains one or multiple missions. Building this file starts with the outer container, wich contains the missions:
|
|
62
60
|
|
|
63
61
|
```javascript
|
|
64
62
|
// Build a missions list
|
|
@@ -74,7 +72,7 @@ console.log(missionList.toString());
|
|
|
74
72
|
|
|
75
73
|
### Building a mission
|
|
76
74
|
|
|
77
|
-
A mission needs multiple properties:
|
|
75
|
+
A single mission needs multiple properties:
|
|
78
76
|
|
|
79
77
|
- The aircraft, its position and state
|
|
80
78
|
- The time and weather conditions
|
|
@@ -119,22 +117,22 @@ const missionList = new AeroflyMissionsList([mission]);
|
|
|
119
117
|
console.log(missionList.toString());
|
|
120
118
|
```
|
|
121
119
|
|
|
122
|
-
As there are lots of properties for the
|
|
120
|
+
As there are lots of properties for the mission object, check the type hinting on the various objects to find out which properties you are able to set.
|
|
123
121
|
|
|
124
122
|
### Important notices
|
|
125
123
|
|
|
126
124
|
- Be aware that `mission.origin` and `mission.destination` do not need to match the flight plan. In case of `origin` you may want to set the position to the actual parking position of your aircraft, which may not be the first way point in your flight plan.
|
|
127
|
-
-
|
|
125
|
+
- Flight plans almost always require at least 4 checkpoints:
|
|
128
126
|
- `origin`
|
|
129
127
|
- `departure_runway`
|
|
130
128
|
- `destination_runway`
|
|
131
129
|
- `destination`
|
|
132
|
-
- Be aware that all
|
|
130
|
+
- Be aware that all units for altitude, elevation or distance are measured in meters! In most cases there will be helper functions for defining these values in feet (for length, altitude, elevation) or statute miles (for visibility).
|
|
133
131
|
|
|
134
132
|
## Status
|
|
135
133
|
|
|
136
134
|
[](https://badge.fury.io/gh/fboes%2Faerofly-custom-missions)
|
|
137
|
-
[](https://badge.fury.io/js/@fboes%2Faerofly-custom-missions)
|
|
138
136
|

|
|
139
137
|
|
|
140
138
|
## Legal stuff
|
|
@@ -142,3 +140,7 @@ As there are lots of properties for the flight plan as well as explanation for t
|
|
|
142
140
|
Author: [Frank Boës](https://3960.org)
|
|
143
141
|
|
|
144
142
|
Copyright & license: See [LICENSE.txt](LICENSE.txt)
|
|
143
|
+
|
|
144
|
+
This tool is NOT affiliated with, endorsed, or sponsored by IPACS GbR. As stated in the [LICENSE.txt](LICENSE.txt), this tool comes with no warranty and might damage your files.
|
|
145
|
+
|
|
146
|
+
This software complies with the General Data Protection Regulation (GDPR) as it does not collect nor transmits any personal data to third parties.
|