There are maps and portals but they currently don't seem to work scene to scene. If this did work to travel to scene to scene I could make a more polished community learning demo to help people use multiplayer more in Godot 4+.
What is needed to properly get the portals to work to travel to different maps / scenes in this JDungeon 2D community example? Also where else should this question be asked? All feedback is welcome.
i would do it like this, have a singleton that handles warps and scene loading. then when you execute a warp load new scene, delete previous scene, add player data, and bobs your uncle.
kuligs2 There's an error in the files. As like it says when using the already made but not functioning portals an error happens such as ~'server found'. Or like there is this clear evidence of at least an attempt at working portals that extend the default server map 'World' where players initially spawn in with character creation.
Okay so there is a mystery with JDungeon in how it is supposed to work but there is no documentation. Yet but it looks by the files at one point there was 'teleportation' but it's not easy to replicate. I'll get some screenshots to better communicate it. So there are scenes / maps like a base camp, a forest, a dungeon etc. but they have in the script like 'extend world' (the default server scene / map'). Here is the less buggy / more stable / non-webport version. It has this starter map when the players spawn in. There are usually 2 portals on this map but the bottom two in this image I added in. As with to help test to see how the game reacts to trying to use its portals to teleport to other scenes with portals. Scenes / maps in the files with portals that look like they inter-connected at one point.
This is another map / scene with a portal but it looks to be trying to connect to another scene called 'Wakening Forest' with a portal called 'BaseCampPortal'.
That should be this portal on this map. But when testing in game it does not work.
When the server starts with the game it has this file called .env and this controls where the player spawns in (with at least character creation) in:
"# Comment out the next one to show the world selection menu when running as server
SERVER_MAP=World"
and
"STARTER_SERVER=World"
Each map / scene has a script. this is the World scene script.
Here is that portal destionation 'WakeningForest' scene / map's script. It extends 'World' (the feault / starting multiplayer map scene'). Is this similar to like trying to swap scenes or the like?
What should I investigate / look at to see what to do first? I asked the devs but they might be busy or not reply / they have been inactive on the 2D JDungeon for months. So I figured to ask around to see if there is a proper solution to this portal mystery.
Here is the portal script as well.
The root and server scripts are pretty large.
Its sorta puzzling / maybe I over read it / missed details from the project's wiki: https://github.com/jonathaneeckhout/jdungeon/wiki/Howto-make-new-map-chunks
It looks like the wiki is missing details / there are not released dev versions that had working portals but were ### commented / marked out / inactivated. I've combed through the github history and it looks a bit strange. There are 2 versions a more working with classes and other features non-webport version which feels like a late beta / early release test version. Then also a buggy less complete webport version that feels like an early alpha.
Here are the files for the JDungeon V.0.0.3 (non-webport version used in this portal test): https://github.com/jonathaneeckhout/jdungeon/tree/d5f9ea4a5cace996383bd963dd765a29944a693f
Currently I'm just trying to get the non-webport version to work with portals and polish it up to make a community learning demonstration so it has something for people to learn from for Godot 4+ multiplayer. It feels like 4/5 to 9/10 the way to a working learning demo ready for polish but the non-working teleportation portals are holding it up.
I asked questions / did little tests as JDungeon 2D was getting worked on last year / early this year but it has slowed down. I came back to see about making a happy little like any one can learn Godot 4+ multiplayer via a working example for the community. I've done similar things but it needs to work like map to map travel.
They did this 3D version of JDungeon recently but its very different.
Also the devs slowed way down too in areas so it might be a life change gear thing. I worked with flare engine too and it happens but its really close with JDungeon 2D to be a proper working demo. Its just the portals have a mystery. I'd rather try to save the code / do a proper fix / solution than gut and smash around and make a crude solution but I'm not sure where to look for a proper solution.
So any ideas on what this means from the errors?
Here are the errors:
"I've looked around and I'm not sure how to properly portal / teleport to new / other scenes / maps / servers in both the webport and the non-webport / activated classes version. By the looks of the older versions / map files there are teleport portals to link the maps together. A lot of the portal tests come back with:
World map / scene with a portal called WakingForestDungeonPortal set up as Destination Server: World, Destination Portal: ForestCampPortal [located in the ForestDungeon map / scene]:
Errors:
"W 0:02:00:0705 logger.gd:107 @ logger(): WARN [15/6/2024 15:19:13] GameServer: Gateway server's connection failed
<C++ Source> core/variant/variant_utility.cpp:1111 @ push_warning()
logger.gd:107 @ logger()
logger.gd:130 @ warn()
servergateway.gd:192 @ _on_client_connection_failed()"
"W 0:02:00:0706 logger.gd:107 @ logger(): WARN [15/6/2024 15:19:13] GameServer: Could not connect to gateway=[localhost] on port=[4433]
<C++ Source> core/variant/variant_utility.cpp:1111 @ push_warning()
logger.gd:107 @ logger()
logger.gd:130 @ warn()
serverfsm.gd:157 @ _connect_to_gateway()
servergateway.gd:193 @ _on_client_connection_failed()"
"E 0:02:30:0624 Portal.gd:26 @ _on_body_entered(): Trying to call an RPC via a multiplayer peer which is not connected.
<C++ Error> Condition "peer->get_connection_status() != MultiplayerPeer::CONNECTION_CONNECTED" is true. Returning: ERR_CONNECTION_ERROR
<C++ Source> modules/multiplayer/scene_rpc_interface.cpp:467 @ rpcp()
Portal.gd:26 @ _on_body_entered()"
Sorry for wall of text but it keeps it all in one place.
I know in wow dev the server loads all the maps in advance so like players can teleport to other maps
The other map scripts have 'extend world' going on so are they acting like add on to the main scene / map? There above in a screenshot is the other map script (the other area scripts are all the same).
The game fires up really easy you like download the 0.0.3 release then I think in Godot 4+ you get debug 4 instances / windows, run the gateway in one window, then the server in another and the other 2 windows can be for clients, make a new character, add name and password and login in and play the little demo.
How to start the game / install JDungeon2D.
Hey are there any links / demo multiplayer projects for Godot 4+ multiplayer with a server and something like loading in / inter-travelling to other maps / locations to learn from? Perhaps if there is a working server thing project with Godot 4+ one can reverse engineer the map to map loading and unloading properly. Then one can perhaps try to fix JDungeon / make something new that works in multiplayer? Where some I look / watch / learn from? Any demo / tutorial / github project suggestions?
So you need to look at the S.server_rpc command and what it does. I could not find it. Here would be the switch to a new scene when player enters the portal. Also dest server and portal must be defined in the portal node/script
kuligs2 But honestly reading other people game code not understanding how stuff works is pretty mind boggling.. I suggest maybe practice creating something similar yourself using primitives.
Im working on server browser myself, and im documenting it for a public repo to be released, so it take longer than usual. Also testing testing testing.
Documentation takes more time and effort than the code itself.
kuligs2
The V.0.0.3 (release version here non-webport version linked above / here: https://github.com/jonathaneeckhout/jdungeon/releases/tag/v0.0.3 ) This version 0.0.3 has a full / not #'d out portal script shown above / here in this screenshot. Which is puzzling for I could understand a #'d out script not working but for the full script to not work is intriguing. Especially when it looks like there was a working version somewhere; public or private I am not sure.
Okay so I need to follow this lead "S.server_rpc.enter_portal.rpc_id(1, body.username, destination_server, destination_portal)" and see where that goes and what it is related to. There are two working local map portals on the default map that do not move the player to another map but instead just different locations on the already loaded map. The screenshots above show these sorta working portals but the destination server seems to be 'World' on all of the working portals ('World' is the default server map too). The not-working portals have different destination servers on their portal scripts / information fields. It looks like the map to map travel not-working portals had a sort of scene to scene travel system but I'm not sure how it was all supposed to work. I'll look for "S.server_rpc.enter_portal.rpc_id(1, body.username, destination_server, destination_portal)" and see where that leads.
"I suggest maybe practice creating something similar yourself using primitives."
What are some good examples / tutorials to follow / learn from to set up a working multiplayer / server scene to scene / map to map travel system? If all else fails if there is a good server to server / map to map multiplayer server networking working tutorial / example I'd like to learn from it and possibly get a hybrid or try to get something to work. Documentation is quite intensive but it helps people in the community in the long run. Also it helps when people ask lots of questions to be able to give lots of working examples lol.
What are some good videos / tutorials / example projects / godot 4+ multiplayer githubs to learn from? I've already been able to learn lots about rpg features. Yet but as of right now I'm trying to increase my networking / server skills / knowledge with godot 4+ multiplayer. Godot community could really use a really decent working Godot 4+ multiplayer example with guides but the closest thing I have is JDungeon 2D and less complex zelda / diablo like sorta multiplayer github examples. The multiplayer / networking really needs improvement for my skills and also for working community demonstrations for features that should be standard like scene / map to scene / map travel. I'll look into that server rpc and see where it leads, thank you for the fresh eyes. Sometimes one can miss lots as by just looking over things over and over lol. Time for investigation into server mysteries.
WithinAmnesia Not sure about where to find the warp thing but like i mentioned it earlier, you just need to unload scene and load the next one.. Set up a area3D to sniff for when someone enters it, then connect that signal that gets emmitted when somebody enters it to a function that unloads and loads next scene. Experiment and you will find out how to do it
Sorry to hijack this thread, but it looks like you (OP) are making an ARPG game based on jdungeon. It might be interesting to hear more about this in another thread!
I have scanned github for 377+ project downloads on my current archive. I did this massive search for github looking for working multiplayer examples to learn and expand upon. In your thread linked those 2D and 3D multiplayer shooter examples I have also found and looked at and tinkered with. I've yet to find a robust scene loading and unload multiplayer demo for Godot though. The Godot blocky game / godot_voxel demo comes close but it is very complex and not easy to make many things such as with other Godot multiplayer 2D and 3D examples.
Ideally I would like a 2D / 3D hybrid for player animations if it comes to photorealistic isometric rpgs / games for I've experienced a lot of game dev working with Baldur's Gate, Diablo, WoW retail and private servers and the Flare engine. I've found that the 2.5D prerendered animations are much harder to deal with than 2D 240p pixels and 1080p-4k+ 3D animations. The Godot voxels started as this but for that set up its better to go full 3D like Minecraft / WoW.
JDungeon is 9/10 almost working example that I was hoping to get the areas to work for travel map to map with its smaller and easier scale without ripping out the guts and effectively rebuilding it how I 'know' it could work vs. whatever the dev was doing and not telling. It's very difficult to piece other people's work in progress code together to make it work better for I don't have the design documents nor the foresight to see where things should be without massive deep dives and deconstruction. Which if it comes to that I'd be better off just making a new project / following a from scratch tutorial for advanced godot multiplayer / networking.
So it's a bit of a dilemma. I'd like to make a patch and get the JDungeon portals working and make a community demo with proper documentation then remake new multiplayer game from scratch which might be a hybrid of JDungeon style solutions and other Godot 4+ networking / multiplayer demos / tutorials / examples / projects / addons / past experiences etc.
I'd like the 2D multiplayer Godot example to work and not throw it all in the garbage. For some networking bugs / incomplete sections got in the way of a proper release so close to the finish line / launch and move onto 3D networking. For 2D has quick start dev work advantages which would help the community immensely to get something happening vs dive into the deep end of 3D voxels / unreal levels or complexity and beyond.
"Sorry to hijack this thread, but it looks like you (OP) are making an ARPG game based on jdungeon. It might be interesting to hear more about this in another thread!"
I'd rather try to keep things simple and make a Github and post whatever it is there verses threads across many platforums / websites to maintain. I am here looking for technical help / guides. I'd like to do documentation but right now I'm dealing with game breaking bugs / incomplete features which if they get solved I can make a happy little demo / documentation to give a polished easy to follow / learn demo version to the community.
Yet but first things are first and these dang zone travel issues seem to plague multiple godot community forums / discords and I wish I could talk to a godot dev and or find a working example to reverse engineer vs. trying to guess what would work based on theories. I need to learn a lot of networking and multiplayer for Godot but this common issues of not being able to zone to zone / map to map travel is a common issue with not just JDungeon but literally every github multiplayer example for working Godot multiplayer / networking. Which is such a shame and if I / we can somehow fix this with a working advanced multiplayer demo MIT open source on github. This would be doing a great deal of help for the community. So as to help grow Godot from a strange hard to use game engine (for most gamedevs I talk with); into a better working open community friendly proper game engine for BIG games.
These BIG Godot 4+ working game demos / advanced multiplayer / networking make a massive difference in helping make people be able to create BIG games. As in to realize the community having MIT license open source forever free access to real working examples of BIG games for BIG projects not just endless small flash / 90's / 2000's style single or single screen / small map multiplayer games.
I come from developing BIG games and I want to get back to that and make BIG games on Godot and be forever free MIT license open source community driven game dev. So as to finally smite down the horrendous proprietary game engine soul crushing corporate 'AAA' greed driven mismanagement bs experience. I have many BAD experiences with bigger studios. I come from advanced art, game design / story / world building / engineering / math / science / world history etc. Yet but one needs code and legal freedom to stay creative today. So if my experience in coding / Godot / advanced networking is not amazing; I am what happens when you pretty much max out all the other talents and then have to pivot to the opposite of what you were doing for decades and starting fresh in a new field.
Anyway enough rambling and book writing lol. I am here looking for networking help to learn how to link different Godot scenes together with advanced multiplayer. Ideally this can manifest into a patch for JDungeon to get a quicker result and better help the community with a good example project / tool set for creative dev work / world building. Yet videos / tutorials and starting from scratch can also help. I better stop typing I've too much to share and I hope this stays as a networking looking for help thread to say focused.
"Sorry to hijack this thread, but it looks like you (OP) are making an ARPG game based on jdungeon. It might be interesting to hear more about this in another thread! "
Another thread would be nice but I gotta deliver the goods first with a working demo that can be used to make little happy multiplayer games with as a sort of template / dev toolset. I'd like to make a little microgame with JDungeon and document it and have a MIT license forever free open source github project / template game demo for the community. With nice documentation and clear steps to also make nice little games with and grow the community organically. Right now the one little / big issue of no zone to zone travel is sorta the last big hurdle to get that demo working for the greater creative game dev community. So if I can get some help / figure out a travel solution then yes a JDungeon inspired game demo thread is in order and with happy guides and documentation to follow would be a good addition as well. Bit by bit things can get better. I gotta learn big bits of multiplayer / networking all at once to get this not so trivial traveling patch to work hopefully with JDungeon.
"You just need to unload scene and load the next one.. Set up a area3D to sniff for when someone enters it, then connect that signal that gets emmitted when somebody enters it to a function that unloads and loads next scene. Experiment and you will find out how to do it ." Hopefully I can learn how to do this so it solves many built up issues for JDungeon and other cool Godot multiplayer demos / examples. So we in the community can have cool rpg, shooter, racing and other cool genres I have working Godot 4+ multiplayer demos for yet lack zone to zone travel lol. I wonder if stuff like this can help if I built them from scratch as Godot 4+ MIT license forever free open source github project / template game demo for the community? + + +
What should one do here to get working zone to zone multiplayer for Godot 4+ multiplayer / networking?