Redstone Continuation

Started by TheVoidShadows on Tue, 11/08/2022 - 03:55

Topic category: Help with modding (Java Edition)

Last seen on 03:11, 29. Nov 2022
Joined Dec 2017
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
Redstone Continuation
Tue, 11/08/2022 - 03:55

What am I trying to do?

I am trying to create a block that acts like a 6-sided redstone repeater. In other words, a block that, when powered by redstone, will emit a redstone signal.

 

So what have I tried?

  • I have tried to test if the block itself is redstone powered. Below is the procedure I used. The return value was used to set the redstone emission value.
    • if block at x y z is redstone powered
    • do
      • return 15
    • return 0
  • I have tried testing if any of the blocks surrounding the block is emitting redstone, (Checking if the block above, below, in front of, behind, and to either side using many many if statement.
  • Similarly, I tested if and of the surrounding block was emitting redstone using 1 if-do statement and several or's
  • I tested if each side of the block is redstone powered (both with several if statements, and 1 if statement with several or's.)
  • I have attempted using 2 separate procedures, one to check for powered or emitting blocks and return true, the other to set the emission value if the return value of the other procedure returns true.

All attempts so far has lead to a crash. 

 

So what is the question?

How would I set it so that the block only emits a redstone signal if it is powered by redstone WITHOUT having to use 2 separate blocks.