
Packet routing should be possible
Ktlo opened this issue ยท 2 comments
As soon as I found out that in this mod it is possible to build a TCP/IP network in the Minecraft world, I immediately wanted to do a simple routing of packets between two subnets. I tried to insert two network interface cards into a future router computer. Two network interfaces appeared in the computer, but unfortunately only one of them could communicate with the network connectors. After examining the mod's code, I found that there is no any way to make two network interface cards work together and use different connectors.
I am assuming there is no other reason that does not allow packet routing. For verification, I added the "oc2: real_network_interface_card" item to the mod, which allows you to connect to a real network via a TAP interface. I tried to route packets from the subnet in Minecraft to my real subnet. It worked. This raises the question: would there be any way to make two network cards work together? It looks like this should definitely be present in the mod.
That's definitely a valid use-case. Main thing I'm unsure about is how to make this configurable and communicate it to the player.
- Sides are configured in the network card (i.e. the relative computer faces it connects to).
- Cards are configured in the network connector (i.e. which card slot it connects to).
- Generically in the casing, what card slot connects to which Block face. Similar to OC1 servers (most "in your face" approach, but also probably only relevant to this card, and easily confusing).
- ...?
Currently leaning towards the first (configured in the card), since it makes sense API-wise, is specific to this use-case, will still work by default, but allow the customization to those who're looking for it. Will see.