FactorioScript - If Statements

Post pictures and videos of your factories.
If possible, please post also the blueprints/maps of your creations!
For art/design etc. you can go to Fan Art.

Post Reply
User avatar
DemiPixel
Long Handed Inserter
Long Handed Inserter
Posts: 72
Joined: Mon Mar 21, 2016 7:27 am
Contact:

FactorioScript - If Statements

Post by DemiPixel »

If you have no idea what FactorioScript is, here is a link to the original post

Here is the if statement showoff: https://gfycat.com/DaringDeliciousAmericanlobster

You can read the reddit post for more details!
Here's the code:

Code: Select all

chain {
  if crude_oil*3 > 5 && water+5 < 10 {
    water += 6
  }
}
And since the forum section description says that it likes blueprint strings...

Code: Select all

H4sIADLrOVcAA82Y4Y7aMAzHXwX145aeSIHeTbfsRU5TFVIDkdqkSlO2ruLdlxYQFEibaHCMTyCnjv3L37FLKieZZDSbJKQBobnmUJKmETQHEuSQ8ioPIQOmFWdhITMIUCFLs0wK0vwm4evLAtUkxC+LHWJSCLPSmIyLjwAHP0mjIDXuOs91wlMSIcYVq7huf+AdOjPN7aZXu+nNbsLTXftBh2yo4nqTgzaJMJkvuaBaqot04kM6bsng1vtHEN2yzfpxtSuNy5QfPJ6CIc2Kq1InJV8LmpFG14UJdpVVPA3QPnKmqhRCybOgc1JqKrTZQBagaBd68CVAstJFdemGa8iPXpa0NKkvqywDHeZ0Tf9wAcE5oRQYT0HZ8Sy88PTOOhpgFQ+zOoR1G5RDhidmC/M1L6hqUyPBD2doVOWGReuoqBMmK6GTlZJ5woV52hwWzcqOpI/U5neT2uKOUvtFNag+sjOZfXUgtgG6rY/EfMQ18wIy/2xx9fI68cHTnqa+P0xTo/wiL36zPj9k09M52rUCEH1ZjlxznqV7RTfqwSVPLVh8t4LF+JKwX8VuudIVzY4p740hULY5Zzd1qdwhV558pv8Nn+EbLXbhcsuFHw9PHNOn8QixyyQxAsRhVDzMVjPXUbE/zH0bmPMi3znPs5T71yO+6rfWc4sdR9rInmpkn3YfdXG4CcLx5hgXRtSpwrlMkLUwcE8GY/1yuF1et7rYfiqX5zygiPlj+yV+TL/UqvJtl37THJ65jnM4/rcScIDopn+rIz9Onq8BV4J/FKfPnzHGCtbv5fOqZyKX6dWtbof6wYXt9UklbmG+BVXrDRdr91ofv8Bjz/+AbkjTbMdZ90zDRQqmQ6OB3U1s+1URGqoz4/Vdga6UmCTvINK/AtXb1ewSAAA=
Maybe with this you can help explain to me why those combinators are teleporting upwards!

piriform
Fast Inserter
Fast Inserter
Posts: 117
Joined: Mon Jan 25, 2016 10:02 pm
Contact:

Re: FactorioScript - If Statements

Post by piriform »

This is very exciting work with tremendous potential. Is your plan to partition it and do a staged release or wait until it's fully baked?

User avatar
DemiPixel
Long Handed Inserter
Long Handed Inserter
Posts: 72
Joined: Mon Mar 21, 2016 7:27 am
Contact:

Re: FactorioScript - If Statements

Post by DemiPixel »

piriform wrote:This is very exciting work with tremendous potential. Is your plan to partition it and do a staged release or wait until it's fully baked?
I can't imagine I'll be able to do the whole thing alone. People on reddit have been begging me to put it on a github so I just want to finish enough that it doesn't seem like a project where I just got lazy.

vanatteveldt
Filter Inserter
Filter Inserter
Posts: 945
Joined: Wed Nov 25, 2015 11:44 am
Contact:

Re: FactorioScript - If Statements

Post by vanatteveldt »

looks great!

@demipixel: just put the code on github. The idea of getting a project into a certain shape before publishing is really old-fashioned :). Having a bunch of unfinished projects on github doesn't look like you're lazy, it looks like you're willing to share!

dgw
Fast Inserter
Fast Inserter
Posts: 197
Joined: Tue Apr 12, 2016 7:06 pm
Contact:

Re: FactorioScript - If Statements

Post by dgw »

Went looking around all over for something to help me get a handle on combinators and set up balancing trains between two loading stations at my iron smelting, and found this (actually, on reddit first). And then I noticed that there's no trace of a released anything for it—no source code, no GitHub repo, nothing. I guess this really did end up being unfinished, but man, was I excited to try scripting the behavior I wanted from a combinator array and getting a blueprint to do just that…

Post Reply

Return to “Show your Creations”