Scrap Mechanic

Scrap Mechanic

[Archived] Circuit Creator
Amy  [developer] Dec 13, 2020 @ 5:47am
Feature requests
Post any feature requests here.
A list with upcoming features will be kept up to date on this message.

Planned features
  • Ability to scan sequential circuits
  • Add custom logic gates, which behave like the internal gates of a circuit
  • Add digital data transmitter and receiver parts
  • Create models for the parts (low priority)
  • Change the discovery process during scanning to scan through only one connection (low priority)
Last edited by Amy; Mar 20, 2023 @ 4:31am
< >
Showing 1-15 of 19 comments
Charly Peño Dec 26, 2020 @ 4:35am 
Would it be possible to have the mod generate a compact logic block array, but with vanilla logic blocks? So that you can first build a giant circuit board, which is then compressed in a smaller shape to make vehicles without modded parts? That's a big one to ask, but i guess a lot of vanilla mechanics could use this as a nice tool (me included, since my 200+gate creations were hard to wire, lol)
Last edited by Charly Peño; Dec 26, 2020 @ 4:36am
Amy  [developer] Dec 27, 2020 @ 5:07am 
Originally posted by Charly Peño:
Would it be possible to have the mod generate a compact logic block array, but with vanilla logic blocks? So that you can first build a giant circuit board, which is then compressed in a smaller shape to make vehicles without modded parts? That's a big one to ask, but i guess a lot of vanilla mechanics could use this as a nice tool (me included, since my 200+gate creations were hard to wire, lol)

If I understand your question correctly (I'll rephrase what I understood), you're asking for a mod which takes a blueprint / creation of logic gates, extracts all the information about what boolean operators are used and which connections there are and then recreate this exact configuration with the logic blocks again, just smaller, maybe as a cube or something.

I can't judge for certain the viability of this. Scanning circuits is possible, creating parts in the world, attaching them to each other, as well as creating connections between them is possible via the scripting API, I would say that it technically should be doable.

Under the assumptions above, I don't think this would be a feature that I'd be aiming for, for this mod. But it's a nice idea and I could imagine that, should there be nobody else taking on this idea, I could create a separate mod which does exactly that.

I'll think about it and whether this fits well within the current theme of this mod or if it should be its own mod. I'll do a small analysis of all the requirements and other stuff, before giving a definite answer :)
Charly Peño Dec 28, 2020 @ 3:54am 
Originally posted by Sheggy:
Originally posted by Charly Peño:
Would it be possible to have the mod generate a compact logic block array, but with vanilla logic blocks? So that you can first build a giant circuit board, which is then compressed in a smaller shape to make vehicles without modded parts? That's a big one to ask, but i guess a lot of vanilla mechanics could use this as a nice tool (me included, since my 200+gate creations were hard to wire, lol)

If I understand your question correctly (I'll rephrase what I understood), you're asking for a mod which takes a blueprint / creation of logic gates, extracts all the information about what boolean operators are used and which connections there are and then recreate this exact configuration with the logic blocks again, just smaller, maybe as a cube or something.

I can't judge for certain the viability of this. Scanning circuits is possible, creating parts in the world, attaching them to each other, as well as creating connections between them is possible via the scripting API, I would say that it technically should be doable.

Under the assumptions above, I don't think this would be a feature that I'd be aiming for, for this mod. But it's a nice idea and I could imagine that, should there be nobody else taking on this idea, I could create a separate mod which does exactly that.

I'll think about it and whether this fits well within the current theme of this mod or if it should be its own mod. I'll do a small analysis of all the requirements and other stuff, before giving a definite answer :)
Yes, that's exactly what i meant. As long as you spread out your circuit, it's quite easy to wire, but it gets complicated if you cram all of them into a small space.
duplino Sep 12, 2021 @ 11:01am 
It would be really cool to be able to use mod logic. At least the Modpack number logic.
glob Oct 19, 2021 @ 9:34am 
the modpack memory bit support
glob Oct 19, 2021 @ 9:53am 
Originally posted by duplino:
It would be really cool to be able to use mod logic. At least the Modpack number logic.

wat if he made a mod for that that is the mudpack compatible and can be used in normal circuits and won't break it but can still function
glob Oct 19, 2021 @ 9:54am 
Originally posted by glob:
Originally posted by duplino:
It would be really cool to be able to use mod logic. At least the Modpack number logic.

wat if he made a mod for that that is the mudpack compatible and can be used in normal circuits and won't break it but can still function
,
modpack* autocorrect did it
recursive scanning? It seems not to work
wingcomstriker405  [developer] Feb 26, 2022 @ 1:27am 
would you mind to give a little bit more information on what is not working?
Last edited by StatisticsOnSteroids; Feb 26, 2022 @ 7:14am
would it be possible to preserve time inside the circuits such that they behave the same as normal circuits except their tickrate is higher? Perhaps then that the tickrate is changeable on the interface.
That should allow 1-tick generators and timers to be used. A huge upgrade really.
Amy  [developer] Feb 26, 2022 @ 2:30pm 
Originally posted by StatisticsOnSteroids:
would it be possible to preserve time inside the circuits such that they behave the same as normal circuits except their tickrate is higher? Perhaps then that the tickrate is changeable on the interface.
That should allow 1-tick generators and timers to be used. A huge upgrade really.
It would be possible to do this, but you'd lose the advantage of computing the circuit in one single go. Depending on circuit size this also reduces performance, even if the mod would compute and update the internal state more than once a tick.

Since there is basically no propagation delay for signals, you can treat everything in an idealised way.
The outputs of combinational sub-circuits can be represented as truth tables listing all the outputs and their respective boolean expression.
Sequential sub-circuits can be looked at as if you had an excitation table which (based on the inputs) shows how the output at time T+1 changes.
Originally posted by Sheggy:
Originally posted by StatisticsOnSteroids:
would it be possible to preserve time inside the circuits such that they behave the same as normal circuits except their tickrate is higher? Perhaps then that the tickrate is changeable on the interface.
That should allow 1-tick generators and timers to be used. A huge upgrade really.
It would be possible to do this, but you'd lose the advantage of computing the circuit in one single go. Depending on circuit size this also reduces performance, even if the mod would compute and update the internal state more than once a tick.

Since there is basically no propagation delay for signals, you can treat everything in an idealised way.
The outputs of combinational sub-circuits can be represented as truth tables listing all the outputs and their respective boolean expression.
Sequential sub-circuits can be looked at as if you had an excitation table which (based on the inputs) shows how the output at time T+1 changes.

Ah i see. That seems to make sequential inputs/outputs a lot more challenging, since we cannot know when a sequence ends. We would need as many lookup tables as time steps (which really defeats the purpose of precalculation). Unless we could specify after how many ticks the circuit should reset, or some other signal. Would that be doable?
Last edited by StatisticsOnSteroids; Feb 26, 2022 @ 8:34pm
Amy  [developer] Feb 27, 2022 @ 1:32am 
Originally posted by StatisticsOnSteroids:
Originally posted by Sheggy:
It would be possible to do this, but you'd lose the advantage of computing the circuit in one single go. Depending on circuit size this also reduces performance, even if the mod would compute and update the internal state more than once a tick...

Ah i see. That seems to make sequential inputs/outputs a lot more challenging, since we cannot know when a sequence ends. We would need as many lookup tables as time steps (which really defeats the purpose of precalculation). Unless we could specify after how many ticks the circuit should reset, or some other signal. Would that be doable?
I'm not exactly sure I can follow. Could you provide a small example (blueprint or similar) to explain what you mean?
im afraid i cant make a blueprint to explain this. But perhaps this is of more help:

Given a one tick generator:

A -> B
A -> C
B -> not C

------------------------------------------------------------------------------

Your timeless lookup table:

A || C
----------
0 || 0
1 || 0 and 1

Lookup table errors because multiple entries when A is true.

--------------------------------------------------------------------------------

Time sensitive lookup table:

A | A-1 | A-x || C
----------------------
0 | 0 | 0 || 0
1 | 0 | 0 || 1
0 | 1 | 0 || 1
1 | 1 | 0 || 0

(rip formatting, it removes spaces)

You see the lookup table includes the time series of the input A, remembering past input X timesteps into the past.
X should be low (maybe upper bound specified by the player and determined through analysis), because the table size grows exponencially with X.
However a one tick generator requires only 2 time steps, which are reasonably few.

--------------------------------------------------------------------------------

I hope this helps!
Last edited by StatisticsOnSteroids; Mar 1, 2022 @ 3:16pm
< >
Showing 1-15 of 19 comments
Per page: 1530 50