Skip to content

Commit

Permalink
Merge pull request #539 from misternebula/dev
Browse files Browse the repository at this point in the history
0.20.1
  • Loading branch information
misternebula committed Jul 14, 2022
2 parents ac4f2ac + a7b98bc commit 324df63
Show file tree
Hide file tree
Showing 7 changed files with 11 additions and 8 deletions.
6 changes: 4 additions & 2 deletions QSB/Anglerfish/WorldObjects/QSBAngler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,9 @@ public void UpdateTargetVelocity()
return;
}

TargetVelocity = (TargetTransform.position - _lastTargetPosition) / Time.fixedDeltaTime;
_lastTargetPosition = TargetTransform.position;
var reference = Locator.GetCenterOfTheUniverse().GetStaticReferenceFrame().transform;
var currentRelPosition = reference.InverseTransformPoint(TargetTransform.position);
TargetVelocity = (currentRelPosition - _lastTargetPosition) / Time.fixedDeltaTime;
_lastTargetPosition = currentRelPosition;
}
}
2 changes: 1 addition & 1 deletion QSB/Menus/MenuManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ internal class MenuManager : MonoBehaviour, IAddComponentOnStart
private const int _titleButtonIndex = 2;
private float _connectPopupOpenTime;

private const string UpdateChangelog = $"QSB Version 0.20.0\r\nThis update brings better ship syncing (including destruction), more things around the village being synced, and general bug fixes.";
private const string UpdateChangelog = $"QSB Version 0.20.1\r\nFixed a velocity calculation bug with some fish.";

private Action<bool> PopupClose;

Expand Down
2 changes: 1 addition & 1 deletion QSB/Player/RemotePlayerVelocity.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,6 @@ public void FixedUpdate()
var reference = Locator.GetCenterOfTheUniverse().GetStaticReferenceFrame().transform;
var currentRelPosition = reference.InverseTransformPoint(transform.position);
Velocity = (currentRelPosition - _prevRelPosition) / Time.fixedDeltaTime;
_prevRelPosition = reference.InverseTransformPoint(transform.position);
_prevRelPosition = currentRelPosition;
}
}
2 changes: 1 addition & 1 deletion QSB/QSB.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,6 @@
<ProjectReference Include="..\EpicRerouter\EpicRerouter.csproj" />
<ProjectReference Include="..\MirrorWeaver\MirrorWeaver.csproj" ReferenceOutputAssembly="false" />
<PackageReference Include="HarmonyX" Version="2.10.0" IncludeAssets="compile" />
<PackageReference Include="OWML" Version="2.5.1" IncludeAssets="compile" />
<PackageReference Include="OWML" Version="2.5.2" IncludeAssets="compile" />
</ItemGroup>
</Project>
1 change: 0 additions & 1 deletion QSB/Utility/VariableSync/BaseVariableSyncer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ public abstract class BaseVariableSyncer<T> : QSBNetworkBehaviour
[NonSerialized]
public T Value;

public bool Bruh() => HasChanged();
protected override bool HasChanged() => !EqualityComparer<T>.Default.Equals(PrevValue, Value);
protected override void UpdatePrevData() => PrevValue = Value;
protected override void Serialize(NetworkWriter writer) => writer.Write(Value);
Expand Down
4 changes: 2 additions & 2 deletions QSB/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
"body": "- Disable *all* other mods. (Can heavily affect performance)\n- Make sure you are not running any other network-intensive applications."
},
"uniqueName": "Raicuparta.QuantumSpaceBuddies",
"version": "0.20.0",
"owmlVersion": "2.3.3",
"version": "0.20.1",
"owmlVersion": "2.5.2",
"dependencies": [ "_nebula.MenuFramework", "JohnCorby.VanillaFix" ],
"pathsToPreserve": [ "debugsettings.json", "storage.json" ]
}
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,7 @@ The template for this file is this :
- [ShoosGun](https://github.com/ShoosGun)
- [Chris Yeninas](https://github.com/PhantomGamers) - Help with project files and GitHub workflows.
- [Tlya](https://github.com/Tllya) - Russian translation.
- [Xen](https://github.com/xen-42) - French translation.

### Special Thanks
- Thanks to Logan Ver Hoef for help with the game code, and for helping make the damn game in the first place.
Expand All @@ -197,6 +198,7 @@ The template for this file is this :
- [EpicOnlineTransport](https://github.com/FakeByte/EpicOnlineTransport)
- [HarmonyX](https://github.com/BepInEx/HarmonyX)
- [UniTask](https://github.com/Cysharp/UniTask)
- Modified code from [Popcron's Gizmos](https://github.com/popcron/gizmos)

## Help / Discuss development / Whatever

Expand Down

0 comments on commit 324df63

Please sign in to comment.