GUI don't work in Multiplayer

Started by xK3n on

Topic category: Help with modding (Java Edition)

Last seen on 14:07, 3. Dec 2021
Joined Nov 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
GUI don't work in Multiplayer
Tue, 11/23/2021 - 11:22 (edited)

Hi,

I have a Problem with my Character creation system.

In the beginning when you join into a new world, you get a Race Join Screen. If you press "Accept" the Button will bring you automatically to a new GUI for Name Change...

I tried this mod in LAN multiplayer (Normal Minecraft Instance and a MCreator Instance. The host of the game is able to go through the whole Character Creation GUIs but the second Player just get the first GUI. All variables are Player_Persistent.

Here are some Screenshots...

First GUI:

First GUI

The Procedure for the button: First Procedure

 

MCreator 2021.3 EAP 

Edited by xK3n on Tue, 11/23/2021 - 11:22
Last seen on 17:06, 2. Aug 2022
Joined Apr 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
First create an player…
Tue, 11/23/2021 - 13:24

First create an player variable to check if the player has created one yet.
to prevent the player to just close the gui i recommend using the world tick update.
If the player count in the current world is over 0, you can itterate through each player,

then check the variable for each player and if they havent chosen one and the gui is currently not opened; open the gui.

 

This also prevents gui from not even opening the first time the correct way because the player still had an loading screen.

Hope this helps

Last seen on 14:07, 3. Dec 2021
Joined Nov 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Thx for your help. But who…
Tue, 11/23/2021 - 13:53

Thx for your help. But who do I itterate through each player when the player count is over 0?

Last seen on 14:07, 3. Dec 2021
Joined Nov 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
And it didn't work sadly.
Tue, 11/23/2021 - 14:19

And it didn't work sadly.