My custom game rule isn't working with this procedure

Started by supermj767 on

Topic category: Troubleshooting, bugs, and solutions

Joined Dec 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
My custom game rule isn't working with this procedure
Sun, 01/24/2021 - 04:25 (edited)

I need some help with this procedure

doesentwork

This procedure is an additional generation for my geodes that's suppose to check if the game rule is true and does not work.

I either did something wrong or the procedure does not work, its not spawning any amethyst geodes in my mod even if the custom game rule is true.

can anyone help????

Edited by supermj767 on Sun, 01/24/2021 - 04:25
Joined Dec 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
I'm trying to use my custom…
Sun, 01/24/2021 - 00:20

I'm trying to use my custom Gamerule and its not working

Consider printing the value…
Sun, 01/24/2021 - 09:16

Consider printing the value of the game rule before returning the value, to check what value you get.

It could be that one can't access the game rules in the world generating context.

Joined Dec 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Which procedure blocks would…
Sun, 01/24/2021 - 14:54

Which procedure blocks would I use to achieve this?

Joined Dec 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Its spamming the console…
Mon, 01/25/2021 - 19:12

Its spamming the console telling me its set to false, even when it isn't suppose to be.

I think since the "return" block and the "get logic game rule" block are both Logic, they are conflicting with each other, so what its actually doing is setting the game rule false every time I set it to true.

Are they're any fixes for this?

 

Joined Dec 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Are they're any fixes for…
Tue, 01/26/2021 - 23:22

Are they're any fixes for this?

Joined Jan 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Yes! You are setting it to…
Wed, 01/27/2021 - 19:59

Yes! You are setting it to false even if it is true, because you set it to return false whether or not it already returned true. Do if else and put return false in the else instead of putting it on the end. Hope this helps!

Joined Dec 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
The return block has to be…
Thu, 01/28/2021 - 00:06

The return block has to be at the end of the procedure for the additional generation to actually work, but in doing so, its changing my game rule to false, which isn't supposed to happen. this solution will not work. thanks anyway though.

Joined Dec 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
anyone else have any…
Thu, 01/28/2021 - 16:42

anyone else have any solutions?

Joined Dec 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Fixed, thanks though.
Thu, 02/04/2021 - 18:52

Fixed, thanks though.

Joined Nov 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
I'm a bit late but you…
Sat, 02/20/2021 - 20:11

I'm a bit late but you should always return a local variable.

If gamerule = true{

set variable to true

else {

set variable to false

return variable.