How to make GUI only for one player (meant for mod to be used in multiplayer)

Started by Gamemaster2022 on

Topic category: Help with Minecraft modding (Java Edition)

Active 7 hours ago
Joined Apr 2021
Points:
618

User statistics:

  • Modifications: 1
  • Forum topics: 15
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 36
How to make GUI only for one player (meant for mod to be used in multiplayer)

Hi, in my mod I have got 5x5 crafting table with multiple recipes. My problem is, that in multiplayer game anyone can see how I am crafting when they open the GUI and steal items. It works like a chest. I want to make it act like normal crafting table.I mean, when I try to craft only I can see my items when crafting. When another player opens the crafting table it can not see my items and it can craft too. I have no clue how to do it. Thanks for replys.

Active 2 years ago
Joined Feb 2019
Points:
741

User statistics:

  • Modifications: 0
  • Forum topics: 1
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 159
the block is tile entity?
Thu, 05/06/2021 - 18:16

the block is tile entity?

Active 7 hours ago
Joined Apr 2021
Points:
618

User statistics:

  • Modifications: 1
  • Forum topics: 15
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 36
Yes. I was unable to use it…
Fri, 05/07/2021 - 05:38

Yes. I was unable to use it without tile entity mode activated

 

Active 2 years ago
Joined Feb 2019
Points:
741

User statistics:

  • Modifications: 0
  • Forum topics: 1
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 159
Try removing the tile entity…
Fri, 05/07/2021 - 06:17

Try removing the tile entity
just add a tigger "on block right clicked"
8

Active 7 hours ago
Joined Apr 2021
Points:
618

User statistics:

  • Modifications: 1
  • Forum topics: 15
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 36
GUI opens but I can not craft
Fri, 05/07/2021 - 06:27

GUI opens but I can not craft

Look how my GUI looks. It should craft but when I click "Craft" button to call procedures to be used as crafting recipe, It just play the sound and nothing happens

Active 2 years ago
Joined Feb 2019
Points:
741

User statistics:

  • Modifications: 0
  • Forum topics: 1
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 159
I understand, so maybe a…
Fri, 05/07/2021 - 06:43

I understand, so maybe a solution could be to use the tile entity but only allow to use one player at a time.

Active 7 hours ago
Joined Apr 2021
Points:
618

User statistics:

  • Modifications: 1
  • Forum topics: 15
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 36
S how to do it :D
Fri, 05/07/2021 - 06:44

S how to do it :D

Active 2 years ago
Joined Apr 2018
Points:
743

User statistics:

  • Modifications: 0
  • Forum topics: 1
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 125
The thing is that Crafting…
Fri, 05/07/2021 - 06:50

The thing is that Crafting Table doesn’t even have a tile entity. You can replace procedure blocks from block procedures to the one that in Slot and GUI or whatever it’s called. These procedure blocks work without tile. But you will not be able to store item inside your block. And finally create a procedure for opening your GUI.

Active 7 hours ago
Joined Apr 2021
Points:
618

User statistics:

  • Modifications: 1
  • Forum topics: 15
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 36
Well I know what you mean…
Fri, 05/07/2021 - 07:29

Well I know what you mean but I do not understand how to do it. Making recipes took me a lot of time...