Skip to content

Feat: redstone signal optimization - #311

Open
chocodev11 wants to merge 7 commits into
Steel-Foundation:masterfrom
chocodev11:feat/redstone-optimization
Open

Feat: redstone signal optimization#311
chocodev11 wants to merge 7 commits into
Steel-Foundation:masterfrom
chocodev11:feat/redstone-optimization

Conversation

@chocodev11

Copy link
Copy Markdown
Contributor

This PR purpose is porting 2 optimization concept i saw in lithium for redstone and it should be preserve vanilla behaviour, may test with flint idk.

  • It read vertical states once, then visit each horizontal neighbor once and calculate its non-wire input and possible wire input together.
  • It also reuses the above-block conductor result, dispatches no behavior for air/wire direct-signal candidates, returns at strength 15, and stops checking wires once non-wire input is already 14 because attenuated wire cannot exceed 14.

@chocodev11 chocodev11 changed the title Fea: redstone signal optimization Feat: redstone signal optimization Aug 3, 2026
@chocodev11
chocodev11 marked this pull request as draft August 3, 2026 06:28
@@ -49,37 +48,158 @@ impl DefaultRedstoneWireEvaluator {
}

fn calculate_target_strength(&self, level: &dyn LevelReader, pos: BlockPos) -> i32 {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hmm the function look very long, I check on lithium are function are more well organize

@chocodev11
chocodev11 marked this pull request as ready for review August 4, 2026 14:11
@github-actions

github-actions Bot commented Aug 7, 2026

Copy link
Copy Markdown

This pull request has conflicts with the base branch "master". Please resolve those so we can test out your changes.

@github-actions

github-actions Bot commented Aug 7, 2026

Copy link
Copy Markdown

Conflicts have been resolved! 🎉

@chocodev11
chocodev11 requested a review from coco875 August 7, 2026 16:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants