I am making a top down view tank shooting game, and I want to set basic controls (forward, backwards, left, right).
I have tried moving it with CFrames but it clips through walls, when using collide functions to disallow this, I came across another problem which is that its laggy due to movement on the server. Since the part is anchored, I cannot set it’s network ownership either.
How could I communicate client-server and also move the tank so it replicates to everyone? Thanks!
You could use a Raycast to detect obstacles and stop the tank or adjust its path
For movement, I think it’s best to let the client handle it with Network Ownership. Running it on the server can cause delays for players with high ping. Alternatively, you could have the client control movement, send updates with FireServer, and let the server update other players with FireClient if the player is within range