Friday Facts #344 - Tile transition collisions & Team Steelaxe speedrun record

Posted by Klonan, Bilka on 2020-04-24

Tile transition collisions Klonan

We first mentioned a change to our tile transition logic back in FFF-199, and not long after in FFF-214. These two posts focused more on the visual side, and how it makes the game terrain look so much better.

In short, the tile transition logic overlays an additional sprite over adjacent tiles, so that where the two tiles meet has a much more natural look.

Left: Tile transitions on; Right: Tile transitions off.

So while the looks were taken care of, we also had to deal with the 'feel' of the tiles. The easiest example of this is the 1x1 landfill 'stepping stones'. It really looks like you should be able to walk/drive across the 1 tile of water. So we added in an additional layer of collision checks, which will consider the transitions when performing the logic of what can go where.

Now some of the cheesier among you will know that biters don't know how to get across these 1 tile gaps. That is because simply we never enabled the biters to use this collision check logic. One reason is that more checks means more UPS usage for the biter pathfinding, another is that we didn't think it was necessary. However it was available in the engine, and any mod could enable it if they want. That is exactly what I did with my Mining drones mod. Initially this seemed to work, and I thought it might make them walk around lakes a bit more naturally (like the player character does).

However quickly I noticed that people were reporting on the forum that the game was crashing with the mod installed. I quickly reverted the change to my mod and we started looking into it. It turns out that the new abstract pathfinder we added for better unit pathfinding (FFF-317) was not set up to consider units using this tile transition collision logic. This same crash was happening sometimes without any mods installed, but the case was more difficult to reproduce, so this is a nice situation where mods help us work on issues in the base game.

Recently I have been working on another unit heavy mod, Transport drones, and the principle design behind the mod heavily relies on the tile collision logic (the units don't even collide with entities). It turned out to be a really nice test of our new pathfinder, but also highlighted some of the issues that not considering the tile transitions can bring.


By not considering the tile transitions, the drone takes an awkward path along the diagonal road.

This week Oxyd finished his work on an upgrade to the pathfinder, so we can enable the tile transition collision logic with units. The change is immediately noticeable with the above example.


By considering the tile transitions, the drones path much more naturally.

With the logic now in place, we are debating whether to enable it for biters or not. We probably won't, it is only a minor change and would have a non-zero performance impact (a rough test puts the worst case at about 5%), but then again it is a fun way to surprise those who thought the 1 tile of water would stop the biters attacking, and it kinda makes sense they can walk over it just as the player can. Well we will see if there are any issues with it in the modded cases before any further consideration.

As a bonus fact (this is Factorio facts after all), I spent a bit of time benchmarking some late game Transport drone based factories (screenshot), and found a few nice performance gains.

This game is too short, I want my money back! Bilka

This Wednesday, Team Steelaxe set a new Any% multiplayer speedrun world record at 1 hour, 15 minutes and 21 seconds. This is the fastest anyone has ever launched a rocket in an unmodded Factorio game.

I am part of Team Steelaxe, so I want to take the opportunity to explain how we managed to beat the game this quickly. In general, it is all about planning and preparation, we estimate that we have put a combined 200 hours into planning just for this speedrun. The Any% speedrunning category allows to change all map generation settings, including disabling enemies. Multiplayer subcategories allow for up to eight players. Planning begins with picking a map seed. Since there are many possible maps to choose from, we let a script generate maps and automatically filter out the ones without enough ore in the starting area, and then handpick from there. With the map picked, it is possible to start planning the base. This begins with setting a target time to finish the game and calculating the amount of science and number of assemblers required from there. We then come together and arrange a base on the chosen map, which will serve as a reference for the factory built in the actual run. It should be noted that the category rules do not allow blueprint imports, so instead we usually have the planning save file open in another window or use screenshots during the run.


Part of the spreadsheet that contains every player’s responsibilities.

Another big part of the planning is also to create a spreadsheet of everyone’s tasks and when they should be done. We distribute the tasks so that two players build smelting, two build mining, one player builds the power plant and only three people build the factory itself. This strict divide means people only ever take and craft the material that they need, so ideally we don’t have to fight over resources. Furthermore, the task list allows us to optimize by shuffling tasks around, so that no time is wasted by anyone. One example of this is that only two people ever chop wood for power poles, the rest get the wood from them and do not have to waste time on finding trees. The task distribution also means that every player has a very different perspective of the speedrun, so here are some more:

With the complete plan prepared, we do runs and iterate on the planning, taking into account what worked well and what did not. The speedrun above is the result of a few of those planning iterations combined with some improvisation to compensate for mistakes in execution. It may not always sound like it during the run, but we are all friends and when someone makes a mistake, others jump in to help out, so the linked run is the result of good teamwork. Without everyone working together like that, we would not have been able to reach our target time of 1 hour and 15 minutes.

In the future, we hope to be able to launch a rocket in less than an hour, you can watch our next attempts on Sunday at 20:30 CEST on Twitch. You can find over 20 active speedrunners, resources such as save games and replays, or even try running yourself, at Speedrun.com/Factorio.