HN Theater @HNTheaterMonth

The best talks and videos of Hacker News.

Hacker News Comments on
Raycasting engine in Factorio 1.0 (unmodded) - Facto-RayO v2.0

arrow in my gluteus maximus · Youtube · 343 HN points · 3 HN comments
HN Theater has aggregated all Hacker News stories and comments that mention arrow in my gluteus maximus's video "Raycasting engine in Factorio 1.0 (unmodded) - Facto-RayO v2.0".
Youtube Summary
Version 2.0 of my ray casting engine build entirely inside factorio. No mods are needed to run it.


more information and download: https://forums.factorio.com/viewtopic.php?f=193&t=88678
---------------------------------------------------------------------
version 1.0: https://youtu.be/7lVAFcDX4eM
my second channel: https://www.youtube.com/channel/UCNQRKtG2pU8LGS08TFiyyAA

my twitter: https://twitter.com/ArrowGMaximus

---------------------------------------------------------------------

credits:


music: vulg by OcularNebula
https://www.youtube.com/watch?v=k5lRcjC3bY4


endscreen image: Banana Lord
https://www.youtube.com/channel/UCuFfgi1yPu1FacJiwsghpDg


idea for the user input mechanism: Kleeb
https://www.reddit.com/r/factorio/comments/ao5say/request_for_user_input_mechanisms/efyjo9r/
---------------------------------------------------------------------

the game in this footage:
https://factorio.com/
https://store.steampowered.com/app/427520/Factorio/

---------------------------------------------------------------------
0:00 demonstration
1:05 real-time
1:19 inserter array
1:45 real-time (continued)
2:08 demonstration (continued)
2:28 size comparison
2:40 tour of the map
4:00 end-screen
HN Theater Rankings

Hacker News Stories and Comments

All the comments and stories posted to Hacker News that reference this video.
Jan 17, 2022 · 3 points, 0 comments · submitted by kvnhn
Neat!

Reminds me of:

  - Pacman in Factorio: https://www.youtube.com/watch?v=_VR_b9YwqH8
  - Raycasting 3D engine in Factorio: https://www.youtube.com/watch?v=28UzqVz1r24
My main questions are:

  - how long does it take?
  - how does Factorio compare to VS Code as an IDE?
CGamesPlay
The video is in real-time, and calculating Fibbonacci is probably 4 instructions in the CPU, so you can get an idea of how fast it is.
sterlind
way faster than Minecraft though! it can take a minute per instruction in the redstone videos I've seen. probably because Minecraft works on ticks affecting adjacent voxels and Factorio is more like labview (not to mention its seemingly excellent engine perf.)
CGamesPlay
It's probably more related to the fact that the basic building blocks in Factorio are much higher level than in Minecraft. You create these out of wires (adders), arithmetic combinators (any other arithmetic operator), and decider combinators (comparisons). Additionally, you have 2 "channels" for data (red and green wires), and "data" is actually a vector of numbers (since each wire carries a "count" for each "item type").
b0afc375b5
Additionally, Darude:

https://youtu.be/mgfwwqwxdxY

If you liked the Game of Life running a Game of Life simulation you might enjoy the YT video[0] showing someone's functioning raycasting engine within the game world of Factorio using thousands of machines and parts provided by the game. It blew my mind.

What I also found quite amusing was the PowerPoint presentation demonstrating the Turing-completeness of PowerPoint animations[1].

I'll never get tired of this kind of tinkering walking the line between genius and a healthy portion of crazy.

[0] https://www.youtube.com/watch?v=28UzqVz1r24

[1] https://www.youtube.com/watch?v=uNjxe8ShM-8

gregsadetsky
I would also very highly recommend you watch this talk about PowerPoint’s Turing-completeness — https://youtu.be/_3loq22TxSc

It’s from the same person (Tom Wildenhain) as your video, but this is an hour long, there’s an actual audience (that’s supportive and spends most of the talk in disbelief), and the end with recursive slides / fractals is an absolute mind melt.

Strong recommend! :) Thanks for the suggestions/reminder!

fouronnes3
That's an idea for a talk. Crazy place where people have implemented computers. My personal favorite is the pokemon red implementation in minecraft.

https://youtu.be/H-U96W89Z90

You can also play factorio https://www.youtube.com/watch?v=28UzqVz1r24&t=145s
jimnotgym
...if you want to waste 100 hours without realising it.
Oct 03, 2020 · 339 points, 31 comments · submitted by bufferoverflow
akeck
That's insane. When he zoomed in to machine level and then out to show different functional units, I felt like I was looking at "the real world" from The Matrix.
afro88
Reminded me of the alien computer from the 3 body problem
nielsole
In the three body problem, a computer is created out of 30 million uneducated soldiers that stand in a 6x6km square communicating mostly through flags. 3 soldiers form AND or OR gates. A memory bus is run by cavalry.

I am only half way through the book, so this might not be THE alien computer from the book, but still fitting.

petargyurov
If this isn't proof that our world is just part of some teenage alien's half-working science project then I don't know what is.
szczesniewski
This comment and it's position got me thinking that technology and teology are finally converging. Maybe majority of people believing in higher power are right?
ladberg
As someone who doesn't play Factorio, what basic building blocks is this made from? Are there programmable objects or is it built from logic gates?

To make a Minecraft analogy that more people might understand, is it closer to redstone or command blocks?

kmill
It's closer to redstone, but it's a more complicated system. It's like ladder logic in industrial control but with a couple hundred integer-valued registers per circuit network that the "combinators" update every game tick. The combinators include arithmetic and boolean operations, and you can set them to be performed on two or all of the registers.

It was fun figuring out how to make an automated system that feeds nuclear reactors with fuel to supply my base with just the right amount of steam for the generators, signaling an alarm in case of over utilization.

wolfram74
I've not played around with command blocks, but it's a bit more than redstone components.

When Factorio items are wired together with signal cable they have a few different operating modes. You can specify what objects are requested from a delivery network and what items are taken from a chest, or if any are to be taken at all. So this solution involved chests being filled with various items that have a specific color on belts, and then staggering pulls from the chests to place on belts in such a manner as to make pixels.

Those commands were issued by combinations of the constant signal block, the comparison/decider block, and the arithmetic block. I would say those entities are between NAND gates and pre fabricated if/else or for loop constructs.

mastax
They're like individual logic/arithmetic gates: https://wiki.factorio.com/Arithmetic_combinator

So something in-between.

galuvian
Factorio only has very basic gates. slightly more advanced than plain redstone, but not anything close to command blocks.

There are three types of combinators: arithmetic, decider, and constant.

Signals have a channel name (one for each item type and a few dozen other options) and an integer value.

Arithmetic combinators can perform arithmetic operations on one or all signals with one signal and a constant integer, or two signals.

Decider combinators perform comparison operations.

Constant combinators emit constant signals on a given channel.

There are also abilities to detect state on some other items and cause behavior to change, the equivalent of observers, dispensers, pistons, etc.

https://wiki.factorio.com/Circuit_network#Logic_signals

ehsankia
What about higher level manipulation. Are these made by hand? What does the tooling look like? Can you modify the "maps" using editors, or code? I remember even early on there were Python libraries for manipulating Minecraft chunks.
tlarkworthy
You can create blueprints and have robots do the placement. It's aggressively anti micro, and scalable
narrationbox
There are sophisticated keybinding-friendly editors built-in. It is very different from vanilla Minecraft.
input_sh
You usually have items in an inventory. If you have what's needed, you can craft plenty of things by hand (but not complicated things like engines or anything to do with oil or uranium). Otherwise, you build belts to assembly machines, they take things from the belt, and make whatever you tell them.

Mid to late game you also get construction and logistics bots. The former allows you to copy/paste groups of machines (bots will make them), and the latter of which just makes sure you have things that you need in your inventory. Bots speed the game up quite a bit.

hombre_fatal
Cute track from the video: https://www.youtube.com/watch?v=k5lRcjC3bY4
maCDzP
This is crazy. Is this a virtual machine within Factorio? Made me thinking. Would it be possible to build a computer within Factorio and to then break out of it?
personjerry
I can't wait to play Doom in Factorio
Papirola
so Factorio is a Turing machine?
WJW
Well it lacks the infinite size tape so technically it's not a "real" Turing machine. It has the basic boolean operators though, so you can compute anything you want as long as your computer has enough RAM.
PixyMisa
Yes, not a Turing machine, but Turing-complete.
rrss
If we are not ignoring the requirement of infinite tape, then it's not turing-complete either.
AbraKdabra
If you don't play Factorio, let me tell you this is absolutely freaking nuts. Even the 16-bit ALU in Minecraft from 10 years ago seems like child's play compared to this.
faitswulff
I only watched the trailer, but don't your structures get attacked randomly during the game? Curious how they were able to build so much if there were random attacks.
TillE
You can turn enemies off entirely, set them to not expand their bases (so you only have to clear them out once), or simply build adequate defenses.

With this kind of weird experiment, you'd just go for the first option.

elihu
They're probably playing with a "peaceful" map. It's quite possible to turn all of that off without a game mod. I think there are also some infinite resource modes as well for just trying things out and making schematics and so on.

(So far I've just played some of the tutorials and the standard game scenario with minor settings tweaks.)

trevyn
"Yes sir, we have extracted infinite resources from this planet to create a 144p LCD screen."
TeMPOraL
It's an e-ink screen! If you shut off the power, the last image remains visible forever!
friendlybus
The game is a sandbox and presents a menu where you can change a lot of parameters for your next game. You can turn off aliens, or make them peaceful and change their spawn rate. There is also a creative mode in console with unlimited everything.
carry_bit
It's possible to play with enemies disabled, or in peaceful mode.
adwn
You can turn off alien attacks when you start a new game.
dgrin91
As others have mentioned, you can turn off enemies. But the 'true' factorio way is to _automate your defenses_. You can automatically build turrets, have robots place them, build bullets to go along with them and have them delivered to the turrets. Once you get it down it 'just works' and you dont really need to think about it.
m4rtink
Yeah - we have a death world x 3 going at the moment, with enemy expansion enabled and everything - the nests basically span anywhere outside our base defenses by this point.

Still, we are far enough research and rsource vise it's no longer a problem (there were quite a few close calls before). Our automatic defense system looks like this, going from no-mans-land to the base:

* checkerboard pattern of walls, effectively "dragons teeth" as used on many 20 century fortifications * double concrete wall * laser turrets * a conveyor belt with depleted uranium munition for gun Gateling gun turrets & artillery cannons (each on one side of the belt) * Gatling gun turrets firing depleted uranium munition * flamethrower turrets feeding from the closest oil deposit * piping for the flame turrets & power poles for electricity supply * an artillery cannon feeding from the belt & automatically attacking anything that strays into the no mans land * base stations for construction robots to repair the damage that still occurs, even with such a rather crazy powerful setup

Still, this actually just "holds the line"! Conquering any additional are from the aliens would be still rather hard, with more and more bugs spawning as you try to attach their nests. Well, then we found out Spidertron (a giant spider like robot players can ride) can fire nukes.

The end result is pretty much the ultimate industrialized warefare - a player boards Spidertron stocked with nuclear warhead tipped rockets and proceeds to the are to be cleared, the fires nukes at targets as appropriate. This will clear the nests bug will make many of the survivors very angry - some of them can even take an indirect hit by the shock wave and still charge at you! You can install some close-in laser defense on the Spidertron but it's still a rather dangerous job. The end result - a new area with new juicy resources & space for new factory complexes, totally pockmarked with with burnt out crates from nuclear blasts! These scars apparently never go away (unless you pave them over) you will always see where a nuke has gone off.

Next you place the defenses as described above on the new perimeter (preferably as short as possible, creatively making use of water that can't be crossed). The build new railway lines and build mining outposts connected to those, to feed you smelters and processing plants.

On the place that remains you can place various processing, research, manufacturing complexes, rocket launch silos - or build a computer that runs a game engine. ;-)

Fed by trains bringing resources over endless nuclear scared wasteland and protected by ever vigilant wall of death.

wittenator
This read had a pretty intense 40k vibe to it :)
Sep 19, 2020 · 1 points, 0 comments · submitted by baalimago
HN Theater is an independent project and is not operated by Y Combinator or any of the video hosting platforms linked to on this site.
~ yaj@
;laksdfhjdhksalkfj more things
yahnd.com ~ Privacy Policy ~
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.