Skip to content
This repository has been archived by the owner on May 16, 2024. It is now read-only.

Commit

Permalink
Merge branch 'features/extra-lighting' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
mattnischan committed Dec 15, 2020
2 parents 5df3b52 + 28cc528 commit 73d2823
Show file tree
Hide file tree
Showing 243 changed files with 36,271 additions and 4,645 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -58,4 +58,4 @@ node_modules
dist
.cache
.tmp
src/workingtitle-vcockpits-instruments-cj4/html_ui/Pages/VCockpit/Instruments/Airliners/CJ4/WTLibs/wtsdk.js
src/workingtitle-vcockpits-instruments-cj4/html_ui/Pages/VCockpit/Instruments/Airliners/CJ4/WTLibs/wtsdk.js
18 changes: 17 additions & 1 deletion PackageDefinitions/workingtitle-aircraft-cj4-metapackage.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<AssetPackage Name="workingtitle-aircraft-cj4" Version="0.7.3">
<AssetPackage Name="workingtitle-aircraft-cj4" Version="0.8.0">
<ItemSettings>
<ContentType>CUSTOM</ContentType>
<Title>CJ4</Title>
Expand Down Expand Up @@ -50,5 +50,21 @@
<AssetDir>src\workingtitle-vcockpits-instruments-airliners</AssetDir>
<OutputDir>.\</OutputDir>
</AssetGroup>
<AssetGroup Name="workingtitle-core-library">
<Type>Copy</Type>
<Flags>
<FSXCompatibility>false</FSXCompatibility>
</Flags>
<AssetDir>src\workingtitle-core-library</AssetDir>
<OutputDir>.\</OutputDir>
</AssetGroup>
<AssetGroup Name="workingtitle-vcockpits-instruments">
<Type>Copy</Type>
<Flags>
<FSXCompatibility>false</FSXCompatibility>
</Flags>
<AssetDir>src\workingtitle-vcockpits-instruments</AssetDir>
<OutputDir>.\</OutputDir>
</AssetGroup>
</AssetGroups>
</AssetPackage>
2 changes: 1 addition & 1 deletion PackageDefinitions/workingtitle-aircraft-cj4.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<AssetPackage Name="workingtitle-aircraft-cj4" Version="0.7.3">
<AssetPackage Name="workingtitle-aircraft-cj4" Version="0.8.0">
<ItemSettings>
<ContentType>CUSTOM</ContentType>
<Title>CJ4</Title>
Expand Down
51 changes: 45 additions & 6 deletions build.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ param (
$global:FileChanged = $false
$Action = 'Update-Packages'

Get-EventSubscriber -Force | Unregister-Event -Force

function Update-Packages {
param (

Expand Down Expand Up @@ -106,7 +108,32 @@ function Wait-FileChange {
NotifyFilter = [IO.NotifyFilters]'FileName, LastWrite'
}
$onChange = Register-ObjectEvent $Watcher -EventName "Changed" -Action {
$global:FileChanged = $true
if($global:FileChanged -eq $false) {
$details = $event.SourceEventArgs
$Name = $details.Name
$FullPath = $details.FullPath
$OldFullPath = $details.OldFullPath
$OldName = $details.OldName
$ChangeType = $details.ChangeType
$Timestamp = $event.TimeGenerated
if($FullPath -NotLike ".\src\wtsdk*"){
$text = "{0} was {1} at {2}" -f $FullPath, $ChangeType, $Timestamp
Write-Host ""
Write-Host $text -ForegroundColor Green

$global:FileChanged = $true
} elseif($FullPath -Like ".\src\wtsdk\src*") {
$text = "{0} was {1} at {2}" -f $FullPath, $ChangeType, $Timestamp
Write-Host ""
Write-Host $text -ForegroundColor Green
Write-Host "npm run build...please wait..." -ForegroundColor Yellow
Push-Location "src\wtsdk"
$global:FileChanged = $true
& npm run build | Write-Host
Pop-Location
Write-Host "build finished" -ForegroundColor Green
}
}
}

while ($global:FileChanged -eq $false) {
Expand All @@ -117,13 +144,25 @@ function Wait-FileChange {
Unregister-Event -SubscriptionId $onChange.Id
}

if($Project -Like "*cj4*"){
Write-Host "npm run build...please wait..." -ForegroundColor Yellow
Push-Location "src\wtsdk"
& npm run build | Write-Host
Pop-Location
}

Update-Packages

# FILE WATCHER
if ($WatchFiles -eq $true) {
while (1 -eq 1) {
Write-Host "Waiting for file changes... (CTRL+C to quit)"
Wait-FileChange -Folder (Join-Path "." "src") -Action $Action
Start-Sleep -Milliseconds 100
try {
while (1 -eq 1) {
Write-Host "Waiting for file changes... (CTRL+C to quit)"
Wait-FileChange -Folder (Join-Path "." "src") -Action $Action
Start-Sleep -Milliseconds 100
}
}
}
finally {
Get-EventSubscriber -Force | Unregister-Event -Force
}
}
127 changes: 115 additions & 12 deletions docs/workingtitle-cj4/CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,21 +1,124 @@
# Working Title CJ4 v0.7.3 Changes
# Working Title CJ4 v0.8.0 Changes

Welcome to the latest update of the Working Title CJ4 (v0.7.2). This is a hotfix for adjusting the autopilot PIDs to get rid of the bugs introduces with MSFS update 1.11.6.0!
Welcome to the Working Title CJ4 v0.8.0, one of the largest and most comprehensive updates to the aircraft to date. This update includes an enormous navigational systems overhaul, making it an excellent aircraft for a full range of IFR flight activities and procedures. We have also added a number of other great features, like a full FADEC and sound overhaul.

Thanks to Asobo and FBW for finding a solution to this pressing issue.
This release is incredibly large, and is such very much a beta release. Please check the list of outstanding issues below, and file any issues encountered on our GitHub Issues tracker.

We hope you enjoy flying this release!

## Installation
Installation is easy, simply copy the `workingtitle-aircraft-cj4` folder inside the zip file to your MSFS Community folder.

**Important: We recommend that you fully delete the previous `workingtitle-aircraft-cj4` folder before copying this release.**

## Changes
* Changed Autopilot PID values to get rid of problems introduces with MSFS update 1.11.6.0
## 🆕 Key Features
* Custom Flight Plan Manager
* Vertical Navigation (VNAV)
* FADEC
* Custom Lateral Navigation
* RNAV capability with LPV
* Improved FMA Display
* Sound overhaul (WIP)
* PFD/MFD improvements (a lot)
* Map improvements
* Many many more...

## Custom Flight Plan Manager
* Independent from MSFS flightplan
* Much improved procedure data, even when using the stock NavBlue data
* Modifiable approaches
* Appropriate discontinuities
* Direct-to to any fix on the plan at any time
* Correct vectors, heading-to-altitude, and intercept legs

## Vertical Navigation (VNAV)
* Full support of all CJ4 VNAV modes including VVS, VFLC, and VPATH
* Continuous vertical path calculation
* Display of vertical path snowflake
* Display of required vertical speed donut to meet next restriction
* Display of TOD on the map
* Overhauled altitude modes including ALTS and ALTV
* Ability to add custom altitude restrictions in FMC LEGS page

## Lateral Navigation
* New lateral navigation over the top of existing AP
* Greatly improved bank response and turn performance
* Supports correct discontinuity behavior
* Compatibility with the new Flight Plan Manager
* Much improved ILS APPR capture success rate

## RNAV
* Ability to fly RNAV procedures at all times
* Correct sensitivity scaling for the enroute (2NM), terminal (1NM), and approach phases (.3NM)
* Correct PFD annunciations for navigational sensitivity
* Full LPV approach support, including correct increasing angular sensitivity as distance to threshold decreases
* Full AP support of APPR and GP modes for RNAV approaches

## FADEC
* Proper flat rating of engine for consistent performance at varying field elevations and temperatures
* TO and CLB throttle detents with indication on MFD N1 display
* FADEC properly targets increasing thrust curve and N1 with altitude in CLB
* Full CRZ throttle range

## FMC
* Reserve fuel can now be changed
* Revised the format of the FLPN page to better match the real unit, especially for approaches
* Approach ref temp of zero can now be entered

## Engines
* Light now off occurs at 12% N2
* Performance adjustments to fit climb profile using FADEC

## PFD/MFD
* Complete overhaul of the PFD Flight Mode Annunciator to match the correct CJ4 mode symbology
* IAS hold will now automatically switch to Mach when the values are the same
* IAS/Mach button switch now captures current mach number
* Added ability to adjust BARO minimums and added minimums aural callout
* Added altitude capture aural alert and flashing altitude selection indicator
* Added FMC waypoint sequence alerting: waypoint ident and distance will flash 5 seconds before sequencing
* Course needles now smoothly swing to position as per the real display
* Fixed an issue where the upper panel knob also controlled menues in the MFD

## PPOS/PLAN map
* Added “NO FLIGHT PLAN” to ROSE/ARC modes when no flight plan detected
* Added “DISCONTINUITY” to ROSE/ARC modes when discontinuity is reached
* Icons updated for airports, waypoints, and intersections
* Added correct label font and sizing for map labels
* Procedures should now be drawn more accurately to how they appear in the procedure charts
* Temporary flight plans (modifying a route) now displays as a dashed white line

## New Sounds (work in progress)
* Engine exterior and interior run, start, stop
* Avionics fans
* Spoiler drag, Gear drag, extend, retract
* Cockpit wind and rain
* FMS, AP panel, DCP, CCP, and soft buttons
* Aurals (Altitude Alert, Minimums, AP disconnect, Caution/Warning, Landing Gear, Pull up, Overspeed, Sink Rate, Don't Sink)
* Removed TAWS System Test (To be replaced with accurate sound)

## Misc
* New camera presets (pax, lavatory etc.)

---
## ℹ️ Navigational items not currently implemented but scheduled for future updates
* Holds and procedure turns
* FMC INTC CRS capability
* VNAV Vertical Direct-To Fix
* Manual Point/Bearing or Point/Bearing/Distance fixes
* Route offsets
* LNAV/VNAV approaches. Currently all RNAV approaches use LPV in APPR mode due to no minimums type information in the available navdata.
* Going direct-to on the LEGS page does not give you an EXEC option, it will automatically execute.

## ⚠️ Known Issues
* Sync to the game flightplan (ATC/VFR Map) is very much work in progress and turned off by default. You can enable this feature in MOD SETTINGS on the FMC.
* Some external applications that use the GPS/Flight plan SimVars may not function correctly or as expected.
* Loading and saving flights can occasionally have bad results.
* Custom liveries can render FADEC inoperative if they ship with a panel.cfg. You must uninstall them or remove their panel.cfg from the livery folder. This is a limitation of the Asobo livery system.
* Autopilot modes cannot be triggered via keybindings or controllers and must currently be triggered in the cockpit with the mouse.
* Due to sim autopilot bank rate limitations, the aircraft may overshoot on certain RNP approaches with tight turns. If you encounter this, we recommend handflying the approach with the given lateral and vertical guidance.
* Sometimes when turning more than 90 degrees onto an approach segment, VNAV might give a NOPATH condition because it sees that you are too high. Engage FLC or VS and descend down and it should recapture the path.
* Very long legs may display some constant cross track deviation on the map and course needles. The plane will still track properly towards the fix. This will be addressed later in the beta.
* The FMS now builds turn anticipation into direct-to course projection. However, you will still encounter some overshoot beyond 90 or so degrees.
* If for whatever reason, you find that VNAV is not behaving as expected, try and turn it off and on again.

## Known Issues
* Altitude constraints are not currently selectable on the map due to incorrect data being displayed.
* The speed constraints on arrivals may not show correctly because of database issues.
* After using Direct-To, the navigation will not always automatically sequence to the next fix and may enter ROL mode. You can re-activate NAV to navigate to the next fix if you encounter this issue.
* The aircraft is still using the built-in MSFS autopilot (for now). All the existing limitations of that still apply. It does behave a bit better with the various enhancements applied.
* Some flight plan distances may still be misreported when the approach is activated. Please log an issue if you encounter this with details.
* Some instances of the autopilot skipping approach waypoints still occur - this is deep in the sim handling of waypoints and is, for now, out of our hands. We will continue to research this.
### 🎅 Have fun! 🎅
21 changes: 21 additions & 0 deletions docs/workingtitle-cj4/Working Title CJ4 v0.7.3 Changes.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Working Title CJ4 v0.7.3 Changes

Welcome to the latest update of the Working Title CJ4 (v0.7.2). This is a hotfix for adjusting the autopilot PIDs to get rid of the bugs introduces with MSFS update 1.11.6.0!

Thanks to Asobo and FBW for finding a solution to this pressing issue.

## Installation
Installation is easy, simply copy the `workingtitle-aircraft-cj4` folder inside the zip file to your MSFS Community folder.

**Important: We recommend that you fully delete the previous `workingtitle-aircraft-cj4` folder before copying this release.**

## Changes
* Changed Autopilot PID values to get rid of problems introduces with MSFS update 1.11.6.0

## Known Issues
* Altitude constraints are not currently selectable on the map due to incorrect data being displayed.
* The speed constraints on arrivals may not show correctly because of database issues.
* After using Direct-To, the navigation will not always automatically sequence to the next fix and may enter ROL mode. You can re-activate NAV to navigate to the next fix if you encounter this issue.
* The aircraft is still using the built-in MSFS autopilot (for now). All the existing limitations of that still apply. It does behave a bit better with the various enhancements applied.
* Some flight plan distances may still be misreported when the approach is activated. Please log an issue if you encounter this with details.
* Some instances of the autopilot skipping approach waypoints still occur - this is deep in the sim handling of waypoints and is, for now, out of our hands. We will continue to research this.
14 changes: 8 additions & 6 deletions jsconfig.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
{
"compilerOptions": {
"module": "commonjs",
"target": "es6"
}
}
{
"compilerOptions": {
"module": "commonjs",
"target": "es6"
},
"include": ["src/**/*"],
"exclude": ["**/node_modules", "**/dist"]
}
19 changes: 18 additions & 1 deletion src/.eslintrc.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{
"root": true,
"env": {
"browser": true,
"es2017": true
Expand All @@ -13,16 +14,28 @@
"no-unused-vars": [
"error", {
"vars": "all",
"varsIgnorePattern": "^CJ4_|^WT|Loader$|^Jet_"
"varsIgnorePattern": "^CJ4|^WT|Loader$|^Jet_"
}
],
"semi": [2, "always"]
},
"globals": {
"VerticalNavModeState": "writable",
"CJ4_MFD": "writable",
"CJ4_PFD": "writable",
"SvgWaypointElement": "writable",
"AutopilotMode": "writable",
"Avionics": "writable",
"EmptyCallback": "writable",
"LatLong": "writable",
"Coherent": "writable",
"WT_BaseAutopilot": "writable",
"WT_VNavPathAutopilot": "writable",
"WT_VnavAutopilot": "writable",
"CJ4NavModeSelector": "writable",
"FlightPlanManager": "writable",
"SegmentType": "writable",
"FlightPlanSegment": "writable",
"SimVar": "writable",
"Simplane": "writable",
"fastToFixed": "writable",
Expand All @@ -48,6 +61,9 @@
"NavSystemElement": "writable",
"MFD_NearestNDB_Element": "writable",
"AS1000": "writable",
"MemoryState": "writable",
"WT_BaseLnav": "writable",
"WT_BaseVnav": "writable",
"g_modDebugMgr": "writable",
"BaseAS1000": "writable",
"NearestWaypointRoute": "writable",
Expand Down Expand Up @@ -88,6 +104,7 @@
"CJ4_FMC_TakeoffRefPage": "writable",
"CJ4_FMC_FuelMgmtPage": "writable",
"CJ4_MapSymbol": "writable",
"CJ4_FMC_VNavSetupPage": "writable",
"CJ4_PopupMenu": "writable",
"CJ4_PopupMenu_Key": "writable",
"CJ4_SystemPage": "writable",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<?xml version="1.0" encoding="utf-8"?>
<WwiseDocument Type="WorkUnit" ID="{8066802F-8FED-4C99-B3A9-9777472C1FD5}" SchemaVersion="97" RootDocumentID="{727C0BB7-5FD8-4BE5-9331-0CA9BB1C06DD}">
<AudioObjects>
<WorkUnit Name="Ambience" ID="{8066802F-8FED-4C99-B3A9-9777472C1FD5}" OwnerID="{17E3FED6-BD2E-4086-8581-62B73B953F10}" PersistMode="Nested">
<ChildrenList>
<ActorMixer Name="ambience" ID="{5855951D-7E27-4745-A966-A54B47169D53}" ShortID="980880327">
<PropertyList>
<Property Name="OverrideOutput" Type="bool" Value="True"/>
</PropertyList>
<ReferenceList>
<Reference Name="Conversion">
<ObjectRef Name="Default Conversion Settings" ID="{6D1B890C-9826-4384-BF07-C15223E9FB56}" WorkUnitID="{72C899CE-308C-4CA7-87C0-8E1504B1D757}"/>
</Reference>
<Reference Name="OutputBus">
<ObjectRef Name="miscellaneous_inside_generic" ID="{893FB4F8-B5B7-4DD2-9589-F17E7FFDF1A0}" WorkUnitID="{D8341C40-AF31-4D5B-9D65-E60D709F4609}"/>
</Reference>
</ReferenceList>
<ChildrenList>
<WorkUnit Name="Battery" ID="{C1079D91-FF2B-4433-A403-85578F051E45}" PersistMode="Reference"/>
</ChildrenList>
</ActorMixer>
</ChildrenList>
</WorkUnit>
</AudioObjects>
</WwiseDocument>
Loading

0 comments on commit 73d2823

Please sign in to comment.