Page 2 of 5
Re: [MOD 0.14] AAI Programmable Structures
Posted: Thu Apr 27, 2017 12:59 am
by Nam
Is it just me, or are the X/Y coords not correct?
This is my first time using this mod, I followed the video tutorial for setting up the Tile Scanner to a Zone Controller to automatically zone ore, but when Zone Controller sets a zone position, it seems to be a random X/Y within the set distance.
Re: [MOD 0.14] AAI Programmable Structures
Posted: Fri Apr 28, 2017 3:59 am
by MickO
Nam wrote:Is it just me, or are the X/Y coords not correct?
This is my first time using this mod, I followed the video tutorial for setting up the Tile Scanner to a Zone Controller to automatically zone ore, but when Zone Controller sets a zone position, it seems to be a random X/Y within the set distance.
I get the exact same. In fact, I have a video of the behavior, but since this is my first post, I can't post a URL.

However, if you look me up on YouTube ("Mick Ohrberg" - not many of us out there) and pick the latest video, unintentionally mislabeled "Trouble with Factorio and programmable buildings", you can see how it manifests.
Re: [MOD 0.14] AAI Programmable Structures
Posted: Fri Apr 28, 2017 5:50 am
by Earendel
MickO wrote:Nam wrote:Is it just me, or are the X/Y coords not correct?
This is my first time using this mod, I followed the video tutorial for setting up the Tile Scanner to a Zone Controller to automatically zone ore, but when Zone Controller sets a zone position, it seems to be a random X/Y within the set distance.
I get the exact same. In fact, I have a video of the behavior, but since this is my first post, I can't post a URL.

However, if you look me up on YouTube ("Mick Ohrberg" - not many of us out there) and pick the latest video, unintentionally mislabeled "Trouble with Factorio and programmable buildings", you can see how it manifests.
You're both probably having the same problem. Remember that combinators output their results 1 tick after they get their input. On the bottom line of combinators deciding on whether there is ore you have 3 steps. On the top line carrying forwards the XY position you have 2 steps. That means when the signals get to the controller the XY is 1 tick ahead of the decision, so you're placing a zone at a position based on whether the previous tile had ore.
To fix add another arithmetic combinator that does each + 0 output each, plugin in the tile XY, and then connect to the final decider so the top line also has 3 steps.
Re: [MOD 0.14] AAI Programmable Structures
Posted: Fri Apr 28, 2017 12:19 pm
by MickO
Earendel wrote:
(snip)
To fix add another arithmetic combinator that does each + 0 output each, plugin in the tile XY, and then connect to the final decider so the top line also has 3 steps.
Aah! Duh - there you go. I shall endeavor to give this a shot. That's what I get for trying to optimize Nilaus' setup... *blush* Thanks!
Re: [MOD 0.14] AAI Programmable Structures
Posted: Fri Apr 28, 2017 9:42 pm
by Nam
Earendel wrote:MickO wrote:Nam wrote:Is it just me, or are the X/Y coords not correct?
This is my first time using this mod, I followed the video tutorial for setting up the Tile Scanner to a Zone Controller to automatically zone ore, but when Zone Controller sets a zone position, it seems to be a random X/Y within the set distance.
I get the exact same. In fact, I have a video of the behavior, but since this is my first post, I can't post a URL.

However, if you look me up on YouTube ("Mick Ohrberg" - not many of us out there) and pick the latest video, unintentionally mislabeled "Trouble with Factorio and programmable buildings", you can see how it manifests.
You're both probably having the same problem. Remember that combinators output their results 1 tick after they get their input. On the bottom line of combinators deciding on whether there is ore you have 3 steps. On the top line carrying forwards the XY position you have 2 steps. That means when the signals get to the controller the XY is 1 tick ahead of the decision, so you're placing a zone at a position based on whether the previous tile had ore.
To fix add another arithmetic combinator that does each + 0 output each, plugin in the tile XY, and then connect to the final decider so the top line also has 3 steps.
I copied the example from this video
https://www.youtube.com/watch?v=z8zBhn4SBD0 at about the 4:30 mark. The same configuration/setup as the video, but it does not work. That video was published April 17th. Has something changed? I can see in the comments some other people have had the same issue.
Re: [MOD 0.14] AAI Programmable Structures
Posted: Sat Apr 29, 2017 9:55 am
by Earendel
Nam wrote:I copied the example from this video
https://www.youtube.com/watch?v=z8zBhn4SBD0 at about the 4:30 mark. The same configuration/setup as the video, but it does not work. That video was published April 17th. Has something changed? I can see in the comments some other people have had the same issue.
No it's still the same. There's an example of a vanilla version on the programmable vehicles page, it also has the blueprint string.
Re: [MOD 0.14] AAI Programmable Structures
Posted: Mon May 01, 2017 5:25 pm
by Illysune
Hi Earendel,
Love your mods, I'm working on some advanced circuits to make full use of them -- including writing a mod that allows the player to write little lua combinators to handle some more advanced problems. However, I struck a small problem with the unit scanner:
According to the documentation, the output should be:
Count-Of-Type: The number of vehicles currently deployed of the specified type. Useful for looping.
This value is returned even if there is no vehicle found at the specified index.
However, the last bit doesn't seem to be the case and I get no signals after an unsuccessful scan. I'm trying to scan every 60 ticks, so knowing the difference between an unsuccessful scan and no output is important, especially with max_structs_per_tick limits. Looking at the control.lua I can't see any logic that would give the documented output, but maybe I'm mistaken in my interpretation

Re: [MOD 0.14] AAI Programmable Structures
Posted: Sun May 14, 2017 3:43 pm
by Nightinggale
Awesome mod. It's a bit hard to get started since messing up appears to be really easy. However writing plans for wire/combinator layouts on paper seems to do the trick and opens up for near endless options. It enables what I want in so many games, but only this mod has really provided: the ability to micromanage everything while at the same time allowing it to run fully automated once set up.
I started using "Tick Limit" and while it works well, I ran into limitations regarding how to use it. I propose the following:
Add an output signal to tell the number of ticks since last update.
Allow multiple options for when to trigger scan/sending orders:
- every nth tick (current code)
- input condition is met (like decider combinator)
- same as #2, but only if it was false the previous tick, meaning it triggers on a rising signal
#2 is useful for controllers if you want it to say send command 6 ticks after the scanner scanned. That allows outputting garbage to the controller during tick 1-5 without sending weird control signals.
#3 is useful for a next unit for unit looping. It allows spending way fewer ticks on vehicles if they turn out to be say moving haulers or miners with fuel and on something mineable while providing near endless ticks if the next action needs to be determined.
Having an enable signal also allows having scanners, can sit idle for multiple real time minutes without being needed and then suddenly being needed every 10th tick for a few seconds. Right now the only solution to that is to make it scan every 10th tick even when nothing reads the output. Not particularly CPU friendly.
Unit scanner can give x,y for unit target in addition to current x,y location (if different). Useful for detecting what haulers are doing and if they are busy and which region it's going to. It could be useful to avoid sending all haulers to the same miner.
It could also be useful to look into idle power. It could be something like "ticks since last scan"*constant for the first 20 ticks and then just a constant. It bugs me to use full power for say a zone scanner where the output is only used when a miner has mined everything within reach. Also it will (or at least should) make people think about how often they need to scan, which would make the mod more CPU friendly.
Re: [MOD 0.14] AAI Programmable Structures
Posted: Mon May 15, 2017 11:03 pm
by Nightinggale
I can't figure out how to set filters on scanner outputs using the new v0.3.3. From what I can tell, clicking on the output I get a chest like window containing the output and if I add something, it is removed during the next scan. Without access to the checkbox list, I can't enable what I disabled before upgrading. Also where did tick limit go?
Right now I'm seriously considering downgrading because I feel like I had much better control with the previous GUI. However at the same time I feel like it's a bad idea because I'm likely just missing something.
Re: [MOD 0.14] AAI Programmable Structures
Posted: Tue May 16, 2017 7:14 am
by Earendel
It sounds like the fix to the vehicle deployer in the latest version broke the interface to the other structures. I can't check right now, but if you can't access the scanners and control towers interface then roll back to the previous version and try to avoid using the vehicle deployers.
Edit: Yup, I broke it, but now I've fixed it again so it's ok. Nobody panic.
Re: [MOD 0.14] AAI Programmable Structures
Posted: Sun Jul 02, 2017 11:11 pm
by TPRJones
The tile scanner doesn't seem to be working properly with trees; scans of the tiles with trees aren't returning the raw wood resource. All the ores worked fine, but not the trees.
(Bug / Compatibility) with Creative mod
Posted: Sun Jul 02, 2017 11:15 pm
by Sworn
I found a bug, or more like a compatibility issue.
If you have the creative mod for testing and have the cheat mode enabled with all cheats.
You go an place some scanner, for example the "Unit Scanner". Then you hook up all the wires to the combinators and when you are done you pick up a blue print and select everything.
When you use the blue print placement with the cheat mod so you instantly place everything, those ghost block/entity from the scanner will bug. They will overlap everything so the blueprint won't work if you try to change something, for example replace the wire, because actually it has another ghost entity on top. And if you try to remove everything those ghost block will remain there.
Re: [MOD 0.14] AAI Programmable Structures
Posted: Sat Aug 12, 2017 7:04 pm
by Eylrid
I'm having a compatibility problem between Building Platform (1.1.9) and AAI Programmable Structures (0.3.8)/Vehicles (0.3.25). I'm running Factorio 0.15.33
When the Building Platform mod is enabled the vehicle deployer building is not clickable. Neither left clicking nor right clicking do anything. The building is useless and can't be picked up. (I don't know if it can be picked up by a bot. I haven't tried that.) The control panel on the front is clickable, and works as normal, but is useless without the building.
Re: [MOD 0.14] AAI Programmable Structures
Posted: Sun Aug 13, 2017 2:05 pm
by Eylrid
Eylrid wrote:I'm having a compatibility problem between Building Platform (1.1.9) and AAI Programmable Structures (0.3.8)/Vehicles (0.3.25). I'm running Factorio 0.15.33
When the Building Platform mod is enabled the vehicle deployer building is not clickable. Neither left clicking nor right clicking do anything. The building is useless and can't be picked up. (I don't know if it can be picked up by a bot. I haven't tried that.) The control panel on the front is clickable, and works as normal, but is useless without the building.
Turns out Building Platform was monkeying with the draw order. It's been fixed here:
viewtopic.php?f=97&t=30053&p=302564#p302510
Re: [MOD 0.14] AAI Programmable Structures
Posted: Mon Aug 21, 2017 9:04 am
by Helickron
Hy, several people, (including myself), geht this popup instead of the Signal Output Terminal.

Re: [MOD 0.14] AAI Programmable Structures
Posted: Tue Sep 05, 2017 11:35 pm
by Earendel
TPRJones wrote:The tile scanner doesn't seem to be working properly with trees; scans of the tiles with trees aren't returning the raw wood resource. All the ores worked fine, but not the trees.
The results need to include 'entities'.
Re: [MOD 0.14] AAI Programmable Structures
Posted: Thu Sep 14, 2017 7:10 pm
by The_Sane
Earendel wrote:If X or Y is unspecified then 0 is assumed.
Using the unit controller if I give a unit an X coordinate without a Y then it correctly assumes Y = 0 and proceeds to those coordinates. If however I give it a Y without an X it does not move.
Re: [MOD 0.14] AAI Programmable Structures
Posted: Fri Sep 15, 2017 12:28 am
by Earendel
The_Sane wrote:Earendel wrote:If X or Y is unspecified then 0 is assumed.
Using the unit controller if I give a unit an X coordinate without a Y then it correctly assumes Y = 0 and proceeds to those coordinates. If however I give it a Y without an X it does not move.
Then there is probably a bug in my code. I will fix that.
Re: [MOD 0.14] AAI Programmable Structures
Posted: Fri Oct 13, 2017 1:18 am
by EditorRUS
If you open the GUI of a Vehicle Deployer and limit the cells available to none and attempt to put a vehicle into the locked cell, it will crash with an obvious exception as you are trying to access non-existent entity.
Re: [MOD 0.14] AAI Programmable Structures
Posted: Wed Jan 03, 2018 8:12 am
by HammerPiano
Any plans to update this mods (and all of the other AAI mods) for 0.16?