Author Topic: Just started using Tnet, unity crashing on play\stop  (Read 5671 times)

greyhoundgames

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 39
    • View Profile
Just started using Tnet, unity crashing on play\stop
« on: May 18, 2014, 10:09:50 AM »
After having used unity for a while now and using NGUI, I added TNETto my collection yesterday. I have been playing around with the examples trying to basically put together the 3 following pieces: The NGUI drag and drop example, the TNET create on click example and the TNET drag cubes around example so that I can drag in the example orc prefab from an ngui list, and then drag it around the screen. The code is working for the most part but I keep crashing unity when im stopping or starting it. Its not always but it got much worse when the final dragging of the prefab around the screen part was added. It also stalls out Unity when I pause it as well.

Does anyone know what might be causing this?

Edit: I also saw this a couple times and it can stall the detecting of new servers(but not the unity engine itself) Unable to resolve the external IP address via http://checkip.dyndns.org. Perhpas there is some other network call that can stall the unity engine and make it looked crashed? It may be co-incidence but the crashes stopped happening for about 15 minutes, then this warning happened and the next time I stopped, and then restarted(there was a few minutes between the error and when I started again) it crashed.
« Last Edit: May 18, 2014, 10:29:42 AM by greyhoundgames »

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Just started using Tnet, unity crashing on play\stop
« Reply #1 on: May 18, 2014, 11:50:41 AM »
That indeed sounds unusual. Is it really a crash, or does it simply wait a bit? If it waits a bit (~3 seconds) then that's fine -- it's closing the UPnP ports.

greyhoundgames

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 39
    • View Profile
Re: Just started using Tnet, unity crashing on play\stop
« Reply #2 on: May 18, 2014, 01:43:03 PM »
Sometimes it can recover after 15+ seconds, but often it will still be stuck 30-60 seconds later and i just force quit it.

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Just started using Tnet, unity crashing on play\stop
« Reply #3 on: May 18, 2014, 04:46:44 PM »
That's very strange... can you try disabling UPnP? You can do that by opening up TNServerInstance.cs and basically commenting out all lines that start with "mUp". The part that waits on threads to close is on line 277.

greyhoundgames

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 39
    • View Profile
Re: Just started using Tnet, unity crashing on play\stop
« Reply #4 on: May 19, 2014, 01:34:12 AM »
Ok I will try this and let you know. If it does get better, it may take me a while to be confident its not just luck because it does come and go.

greyhoundgames

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 39
    • View Profile
Re: Just started using Tnet, unity crashing on play\stop
« Reply #5 on: May 19, 2014, 11:07:08 PM »
I got another one with the changes in place. This is on my console before the system locked up: Unable to resolve the external IP address via http://checkip.dyndns.org
This was during a stop btw

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Just started using Tnet, unity crashing on play\stop
« Reply #6 on: May 20, 2014, 03:07:31 PM »
I'll see if I can reproduce it locally, but if you have any other information that would help, please let me know.

greyhoundgames

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 39
    • View Profile
Re: Just started using Tnet, unity crashing on play\stop
« Reply #7 on: May 20, 2014, 07:16:08 PM »
I can send you the project if there is somewhere I can directly send it to you. Its pretty small but it has all the ngui \tnet stuff so I cannot post it here.

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Just started using Tnet, unity crashing on play\stop
« Reply #8 on: May 21, 2014, 01:40:15 PM »
Certainly -- Ideally a dropbox.com link sent to support at tasharen.com.