Floating point constant values?

Don't know how to use a machine? Looking for efficient setups? Stuck in a mission?
smolgumball
Manual Inserter
Manual Inserter
Posts: 3
Joined: Thu Oct 31, 2024 2:56 pm
Contact:

Floating point constant values?

Post by smolgumball »

Hi folks, I'm wondering if there's a way to get decimals / floats to work in areas where a number is expected. Primarily I'm working with constant combinators and other circuit blocks for the first time and am finding that such inputs seem to only accept integers.

If it's not possible, could you please point me towards workarounds that folks tend to use? I'm also open to mods if that is something a mod might enable.

Thanks!
Zanthra
Fast Inserter
Fast Inserter
Posts: 232
Joined: Fri Mar 25, 2016 8:18 am
Contact:

Re: Floating point constant values?

Post by Zanthra »

Can you work in percent by multiplying values by 100 before doing anything with them? That is fixed point, but at least it's decimal.
Zaflis
Filter Inserter
Filter Inserter
Posts: 521
Joined: Sun Apr 24, 2016 12:51 am
Contact:

Re: Floating point constant values?

Post by Zaflis »

If you do percentage calculation, multiply first and then divide. Not the other way around.
Post Reply

Return to “Gameplay Help”