Веб-сайт самохостера Lotigara

summaryrefslogtreecommitdiff
path: root/source/game/StarWorldClient.cpp
diff options
context:
space:
mode:
authorKae <80987908+Novaenia@users.noreply.github.com>2023-07-16 23:04:09 +1000
committerKae <80987908+Novaenia@users.noreply.github.com>2023-07-16 23:04:09 +1000
commit848b11399f2e34d7f1e0523e214287bfdcc5816c (patch)
treea5ce3b996a7e02a18ee5660832f7b0b5643cd2a7 /source/game/StarWorldClient.cpp
parentda098c7b4812408d1316b14b3b3f46d2ec7dce04 (diff)
Get SE-compatible voice transmission working
Diffstat (limited to 'source/game/StarWorldClient.cpp')
-rw-r--r--source/game/StarWorldClient.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/source/game/StarWorldClient.cpp b/source/game/StarWorldClient.cpp
index 54d4651..091d66e 100644
--- a/source/game/StarWorldClient.cpp
+++ b/source/game/StarWorldClient.cpp
@@ -966,7 +966,10 @@ void WorldClient::update() {
// Secret broadcasts are transmitted through DamageNotifications for vanilla server compatibility.
// Because DamageNotification packets are spoofable, we have to sign the data so other clients can validate that it is legitimate.
auto& publicKey = Curve25519::publicKey();
- m_mainPlayer->setSecretProperty(SECRET_BROADCAST_PUBLIC_KEY, String((const char*)publicKey.data(), publicKey.size()));
+ String publicKeyString((const char*)publicKey.data(), publicKey.size());
+ m_mainPlayer->setSecretProperty(SECRET_BROADCAST_PUBLIC_KEY, publicKeyString);
+ // Temporary: Backwards compatibility with StarExtensions
+ m_mainPlayer->effectsAnimator()->setGlobalTag("\0SE_VOICE_SIGNING_KEY"s, publicKeyString);
++m_currentStep;
//m_interpolationTracker.update(m_currentStep);