Skip to content

Commit

Permalink
Beta Build
Browse files Browse the repository at this point in the history
  • Loading branch information
Fragtality committed Sep 26, 2022
1 parent 8fe69e4 commit 66244bb
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 15 deletions.
Binary file modified PilotsDeck-latest.zip
Binary file not shown.
6 changes: 2 additions & 4 deletions PilotsDeck/FSUIPC/IPCManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,8 @@ private bool ConnectFSUIPC()
{
WASM.OnLogEntryReceived += OnVariableServiceLogEvent;
WASM.OnVariableListChanged += OnVariableServiceListChanged;
WASM.Init(System.Diagnostics.Process.GetCurrentProcess().MainWindowHandle);
//WASM.Init(System.Diagnostics.Process.GetCurrentProcess().MainWindowHandle);
WASM.Init();
WASM.LVARUpdateFrequency = 0;
WASM.LogLevel = LOGLEVEL.LOG_LEVEL_DEBUG;

Expand Down Expand Up @@ -259,9 +260,6 @@ public IPCValue RegisterAddress(string address, string group, bool persistent =
value = xpConnector.Register(address);
if (value == null)
{
value.Dispose();
value = null;

Log.Logger.Error($"RegisterValue: Failed to register XP DataRef! [{address}]");
return value;
}
Expand Down
8 changes: 3 additions & 5 deletions PilotsDeck/FSUIPC/IPCValueDataRef.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,20 +6,18 @@ namespace PilotsDeck
public class IPCValueDataRef : IPCValue
{
public float FloatValue { get; set; } = 0.0f;
private float _lastValue = 0.0f;
//private float _lastValue = 0.0f;

public IPCValueDataRef(string address) : base(address)
{

}

public override bool IsChanged
{
get
{
bool result = _lastValue != FloatValue;
_lastValue = FloatValue;
return result;
return true;
}
}

Expand Down
6 changes: 1 addition & 5 deletions PilotsDeck/FSUIPC/IPCValueDataRefString.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
{
public class IPCValueDataRefString : IPCValue
{
private string lastString = "";
private char[] charArray;
public int Length { private set; get; }
public string BaseAddress
Expand All @@ -28,10 +27,7 @@ public override bool IsChanged
{
get
{
string tmp = Value;
bool result = lastString != tmp;
lastString = tmp;
return result;
return true;
}
}

Expand Down
2 changes: 1 addition & 1 deletion PilotsDeck/PilotsDeck.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="FSUIPCClientDLL" Version="3.2.20" />
<PackageReference Include="FSUIPCClientDLL" Version="3.2.21-beta" />
<PackageReference Include="Microsoft.Extensions.Configuration" Version="6.0.1" />
<PackageReference Include="Microsoft.Extensions.Configuration.Abstractions" Version="6.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="6.0.0" />
Expand Down

0 comments on commit 66244bb

Please sign in to comment.