diff options
Diffstat (limited to 'client')
| -rw-r--r-- | client/Root.cs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/client/Root.cs b/client/Root.cs index b565083..dfbf0da 100644 --- a/client/Root.cs +++ b/client/Root.cs @@ -37,7 +37,8 @@ public partial class Root : Node2D balls[i] = id; Entity *ent; var pos = new Vec2(5f * rng.Next(10), 5f * rng.Next(20)); - var vel = new Vec2(50f + 5f * rng.Next(10), 50f); + var vel = LibDjup.vec2_mul(LibDjup.vec2_normal(new Vec2(50f + 5f * rng.Next(10), 50f)), 25.0f); + GD.Print(vel, " --> ", LibDjup.vec2_length(vel)); ent = LibDjup.world_find_entity(native_world, balls[i]); ent->ball.Position = pos; ent->ball.Velocity = vel; |
