![Image](https://forums.factorio.com/images/ext/3bcbf3cf13a12a02c83a8ae708604685.png)
![Image](https://forums.factorio.com/images/ext/4b5c996fead057151c332c476404a909.png)
Moderator: ickputzdirwech
Hmm, I'm not sure I knew DIV from assembly language. Think it may have been SQL.Yoyobuae wrote:Eh? I didn't know the assembly language DIV mnemonic was actually common knowledge.DRY411S wrote:Indeed. DIV would be no different to '/', but it would help readability.Yoyobuae wrote:Signals are integer values. So Arithmetic combinator division is actually integer division.DRY411S wrote:Integer functions (DIV, MOD, x^y, factorial!)
Readability for who? Software engineers? Not all players have that kind of background.
Similar problem with MOD and even x^y (but there's no other good option for those).
Klonan wrote:Sneak peek of 0.15
And DIV and MOD and x^yYoyobuae wrote:@Klonan: Nice! Seems even bitwise AND, OR, XOR are in there.
Awesome!Klonan wrote:Sneak peek of 0.15
WoohootooDRY411S wrote:Klonan wrote:Sneak peek of 0.15
Woohoo.
I'd imagine the same way they've always worked.Gertibrumm wrote:Woohootoo![]()
now I can remove two deciders and add one!
but the /= seems intimidating.
How are the bitwise operators going to work?
So we got x bit channels now or is this shift stuff encoded into integer numbers?DRY411S wrote:I'd imagine the same way they've always worked.![]()
Input: >> or << (shift left or right): this_many_shifts => output_here
Integers are encoded as binary numbers (signed 32 bit integers).Gertibrumm wrote:So we got x bit channels now or is this shift stuff encoded into integer numbers?DRY411S wrote:I'd imagine the same way they've always worked.![]()
Input: >> or << (shift left or right): this_many_shifts => output_here
You will have both and and or logical oprations. Those are your bit testsYoyobuae wrote:Integers are encoded as binary numbers (signed 32 bit integers).Gertibrumm wrote:So we got x bit channels now or is this shift stuff encoded into integer numbers?DRY411S wrote:I'd imagine the same way they've always worked.![]()
Input: >> or << (shift left or right): this_many_shifts => output_here
I imagine those operations will be applied to the underlying binary representation (ie. just like the operators would work in a programming language).
One thing that I kinda wanted but still is missing is bit test as condition operator. Right now the work around is using extra arithmetic combinators and abusing less/greater than operators. Either option has it's limitations.
The use case is having hundreds of inserters, lamps, pumps, belts being controlled in parallel by only a handful of signals. Minimizes the amount of wiring and the amount of signals, which in turn minimizes the required combinators to control them.
But I want to program bit tests directly to inserters and such.orzelek wrote:You will have both and and or logical oprations. Those are your bit tests
Not a problem. Just work out your boolean expressions before feeding into the decider.Yoyobuae wrote:But I want to program bit tests directly to inserters and such.orzelek wrote:You will have both and and or logical oprations. Those are your bit tests
In the above screenshot the AND, OR operators were shown only for arithmetic combinator (so not available for conditional operators, like in deciders, inserters, lamps, etc).