we don't know how to send data to a specific, multiple and all rifle/s without having to know the exact routing table. I mean, we would like to be able, for example, to send a "host game packet" from a rifle, to the net, and all the players connected to the net could join that game. After this, a "start game packet" is sent to all players at the same time.
What I would do in your case is to set up a Raspberry Pi (or for now your computer) with a fix ip (for example 192.168.1.2 if the router is 192.168.1.1), and then the rifles connect to it for information when they want to start a game or join to a game.
rifle1 wants to start a game
rifle1 sends a packet to Raspberry (he knows its IP, because it's hardcoded): "I want to start a game"
Now Raspberry knows rifle1's IP
Raspberry logs it: new game by rifle1
rifle4 wants to join the game
rifle4 sends a packet to Raspberry: "List me the games"
Now Raspberry knows rifle4's IP.
Raspberry to rifle 4: "There is only one game: rifle1's game"
rifle4 to Raspberry: "I want to join to rifle1's game"
Then the rifles always send packets to the Raspberry Pi, and the Raspberry sends them to the appropriate receiver. So the Raspberry will have a nice log of everything. For example:
rifle1 was hit by rifle4 (the number 4 is sent with the infrared signal)
rifle1 sends a packet to the Raspberry: "I was hit by rifle4"
Raspberry knows the IP of rifle1, so he knows the origin of the message. He also knows the IP of rifle4 (since first every rifle connected to him to join the game).
Raspberry sends a packet to rifle4: "You hit rifle1" or "You hit someone" (depends on your logic)
Raspberry logs the action: kills_of_rifle4++; deaths_of_rifle1++;
In the end of the game Raspberry can send the statistics to everyone. Either one-by-one (one packet to each rifle; after all there won't be too many riffles around), or using multicast or broadcast (although I don't know if ESP8266 handles them correctly).
Of course you can do it without a central module, but then the code on the rifles will be more complicated, since the rifle which hosts the game needs to take care of more stuff.
Or alternatively you can just simply send all packets to the broadcast IP (eg 192.168.1.255) and then everyone will receive it and handle the logic in the data part. For example data would be like: "rifle1 was hit by rifle4" then rifle4 will play some sound ("Good job!") and every other rifle will store this kill in the score table. This will make a lot of unnecessary communication and processing, but if you only send packet if someone is killed (which won't happen 100 times per second) I think this could work. (Also I haven't tested the broadcast with ESP, but it should work.)