Fix spawn accounting for ping
This commit is contained in:
1 file changed
+1
-1
@@ -483,7 +483,7 @@ public class MultiplayerGamePlayer : MonoBehaviour {
|
||||
|
||||
float delayMs = DateTimeOffset.UtcNow.ToUnixTimeMilliseconds() - berry.Timestamp;
|
||||
float spawnY = (canvasRect.rect.height / 2) + newBerry.rectTransform.rect.height;
|
||||
float distanceTraveled = 200f / 1000f * delayMs;
|
||||
float distanceTraveled = 200f * canvasRect.lossyScale.y / 1000f * delayMs;
|
||||
float y = spawnY - distanceTraveled;
|
||||
|
||||
float bottomEdge = -(canvasRect.rect.height / 2) - newBerry.rectTransform.rect.height;
|
||||
|
||||
Reference in new issue
Block a user