Connecting two android devices without a router myself and a friend want to play a multiplayer game that only works on the local network, and in work, there is no open WiFi network that we can both connect. Is there anyway that we can link up both our phones with wifi to play the game, without an extra router?

Maybe if I open the portable hotspot, it would work?

Thanks
Hosting a Hotspot is your way to go!

You can download an app from the Play Store such as FoxFi, to setup a WiFi network using one of the devices, and use the other to connect.

If you need to know IP specifics, FoxFi will provide you with information on connected devices, and their address on the network.

Be careful when using this method though, as the person hosting the hotspot will accumulate all of the data usage from both devices.