JacobDWoodman / OpenWorldGodot

open world godot project for UWE advanced technologies module
2 stars 2 forks source link

Can this work for Godot 4+ games with multiplayer and open world chunks? #1

Open WithinAmnesia opened 6 months ago

WithinAmnesia commented 6 months ago

Test chunks link: https://github.com/WithinAmnesia/ARPG/discussions/15

I'm trying to find a way to seamless load and unload chunks for a 2D multiplayer game project to make an open world with a working server using Godot 4.2.1.NET.

How can this work for multiplayer and what is needed for this to potentially work? What options can be used for chunk loading and unloading seamlessly in Godot 4.2.1.NET? Please give feedback.

JacobDWoodman commented 6 months ago

Hey,

Thanks for enquiring! This project I worked on for university loaded pre-existing assets for different segments of terrain at runtime. The process will be somewhat different for a generated open world. However, the same methodology could be used for a 2D predetermined world. If you want items to be in those chunks that players can affect, like blocks in minecraft, you could contain data about those items in a variable on the server that the client would request when a player comes within range of the chunk being rendered. If the terrain can't be interacted with, and you don't want object persistence in those chunks, you could keep the data contained on the client side, reducing the amount of information you need to send and call for during a game. this methodolgy would be similar to what i created in my project.

As for turning it 2D, it's pretty simple, you can just forgoe the X or Z axis when determining the player's distance from things. It's actually easier in 2D, since there's no risk of pop-in visuals, since things can simply be deleted off-screen!

Hope this helped, will be happy to provide any further advice or clarification if you need it. Sorry for the late reply as well!

Best wishes,

Jacob

On Fri, Feb 16, 2024 at 6:40 PM, WithinAmnesia @.***> wrote:

Test chunks link: WithinAmnesia/ARPG#15 https://github.com/WithinAmnesia/ARPG/discussions/15

I'm trying to find a way to seamless load and unload chunks for a 2D multiplayer game project to make an open world with a working server using Godot 4.2.1.NET.

How can this work for multiplayer and what is needed for this to potentially work? What options can be used for chunk loading and unloading seamlessly in Godot 4.2.1.NET? Please give feedback.

— Reply to this email directly, view it on GitHub https://github.com/JacobDWoodman/OpenWorldGodot/issues/1, or unsubscribe https://github.com/notifications/unsubscribe-auth/AKM6BT7RS5RUBGGI56IAM5LYT6R2VAVCNFSM6AAAAABDMPNA3WVHI2DSMVQWIX3LMV43ASLTON2WKOZSGEZTSMRQGAZTIMA . You are receiving this because you are subscribed to this thread.Message ID: @.***>

WithinAmnesia commented 6 months ago

Also https://github.com/Zylann/voxelgame/issues/101#issuecomment-1958792464 + https://github.com/WithinAmnesia/ARPG/discussions/16#discussioncomment-8550378 Big 2D/3D hybrid progress update! It all works!