# NetworkTransport.AddHost

**URL:** https://discussions.unity.com/t/networktransport-addhost/595875
**Category:** Multiplayer & Networking
**Created:** [September 1, 2015, 9:38pm UTC](https://discussions.unity.com/t/networktransport-addhost/595875 "2015-09-01T21:38:43Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![ManoxCZ](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/manoxcz/32/377834_2.png) [@ManoxCZ](https://discussions.unity.com/u/ManoxCZ)
#### Post date: [September 1, 2015, 9:38pm UTC](https://discussions.unity.com/t/networktransport-addhost/595875/1 "2015-09-01T21:38:43Z")

</div>

Hi,

I want to debug my network code. I start one game instance via build exe and second in Editor. I use NetworkTransport. When I call for the first time NetworkTransport.AddHost(), I get valid hostId. But when the second application calls NetworkTransport.AddHost(), return value is -1. Is it possible to run two application with same host settings on one PC ?

Thanks

---

<div class="post-metadata">

### Author: ![Kewlpatate](https://avatars.discourse-cdn.com/v4/letter/k/839c29/32.png) [@Kewlpatate](https://discussions.unity.com/u/Kewlpatate)
#### Post date: [September 3, 2015, 9:37pm UTC](https://discussions.unity.com/t/networktransport-addhost/595875/2 "2015-09-03T21:37:50Z")

</div>

Hi,  
If you have something like that.  
socketID = NetworkTransport.AddHost (topology, socketPort);

remove the “socketPort” part on the client:  
socketID = NetworkTransport.AddHost (topology);

It’s work for me.
