Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - meganuke

Pages: [1]
1
NGUI 3 Support / UICamera Input problem (affecting key navigation)
« on: March 02, 2017, 09:31:53 PM »
Well after days looking,
searching on google and this forum

reading people with the same problem, and no one ever saying "its fixed".
even downloading the latest version
i decided to try to fix this issue myself.

its very simple, i add "key navigation" to some buttons, but it doesnt work correctly in the Android microconsole. nor with keyboard strokes.
so i tried a windows version, and it doesnt work either.

so i created a new scene, a new project, created 2 buttons, added 2 key navigations.... and it doesnt works either!!!. :(
so i disabled input by mouse and touch...
and still doesnt work.

then i noticed the small "debug" checkbox, and checked it.

run the program
the debug info reads: "Scheme: Touch"

press "up key"
and the debug info reads: "Scheme: Mouse"

and i can see in the UICamera script line: 1942 method: ProcessEvents (), that events are processed only for the specific input
so.... it seems to me like this a NGUI problem...


right now im working around the issue with 

UICamera.controllerNavigationObject = Buttons[selectedbutton];


but it would be nice if you fix this.

2
NGUI 3 Support / weird stuff with ngui 3.8.2
« on: May 30, 2015, 05:41:26 PM »
hi!!
i had a project started with unity 4. and i upgraded to 5.

also, i started with an older version of NGUI 3.2 may be, and recently upgraded to 3.8


since the migration to unity 5, i lost the "handlers" on screen to rezise the objects, the only way  i have is in the properties windows.

also if i copy / paste an object, the restult is something weird. the properties windows says that the stuff is there, but the truth is, that the object is completely empty.

i recorded a video to show:

https://youtu.be/H7Cr8PERQ8k

https://www.youtube.com/watch?v=H7Cr8PERQ8k&feature=youtu.be

sorry for my english.

3
TNet 3 Support / TNManager.CreateChannel / JoinChannel does not load level
« on: November 10, 2014, 11:52:34 PM »
hi!

i was using an older version, cant remember... 1.85 i think...
and i was using a dedicated server.

i recently changed to 2.0 and im leting the users to create their own servers, and register with my lobby server, to save bandwidth.


but now, when the channel is created, the new scene wont load.
not even with the join channel instruction (it connects correctly)


im using this code for testing:

  1.                 IPEndPoint ip = Tools.ResolveEndPoint(lobbyAddress, lobbyPort);
  2.                 TNManager.StartUDP(UnityEngine.Random.Range(10000, 50000));
  3.                
  4.                 int _Port = UnityEngine.Random.Range(10000, 40000);
  5.  
  6.                 TNServerInstance.Start (_Port, _Port,"",TNServerInstance.Type.Udp, ip);
  7.  
  8.                 TNManager.Connect("127.0.0.1",udpPort);
  9.                 TNManager.CreateChannel("newScene",false,8,null);
  10.                 Debug.Log("Starting Server.........");
  11.  
  12.  

and this in the client

  1.                
  2.                 ServerList.Entry ent = instance.mServerList[i];
  3.                 TNManager.Connect(ent.externalAddress, ent.internalAddress);
  4.                 NGUIDebug.Log("Connecting to " + ent.externalAddress + "_" + ent.internalAddress);
  5.                 TNManager.JoinChannel(0,"newScene");
  6.  




i found this code in the TNManager.cs file

  1.         static public void CreateChannel (string levelName, bool persistent, int playerLimit, string password)
  2.         {
  3.                 if (mInstance != null)
  4.                 {
  5.                         mInstance.mJoiningChannel = true;
  6.                         mInstance.mClient.JoinChannel(-1, levelName, persistent, playerLimit, password);
  7.                 }
  8.                 else Application.LoadLevel(levelName);
  9.         }
  10.  

how does that works?
it will only loads the scene if the TNManager object is null?
in what case would this object be null?


can i get some help please?

4
TNet 3 Support / duplicated players
« on: July 04, 2014, 11:15:50 AM »
hi!!!

i have this extrange behaviour.

i created a simple lobby, and when a player joins, he is added twice to TNManager.players

this is the code for creating and joining the channel:
  1.                 if (Input.GetKeyDown(KeyCode.Alpha5)) {
  2.                         TNManager.JoinChannel(0,"lobby1");
  3.                 }
  4.  
  5.  

and this is how i finally noticed that they were duplicating:
  1.         void OnGUI ()
  2.         {
  3.                 string players = null;
  4.                 players = TNManager.players.size + " players\n";
  5.                 //TNManager.
  6.                 for (int i =0; i<TNManager.players.size;i++){
  7.                         players += TNManager.players[i].id + "-" + TNManager.players[i].name + "\n";
  8.                 }
  9.                
  10.                 GUILayout.Label(players);
  11.         }
  12.  

when 1 player joins it says
Quote
2 players
2 Guest
2 Guest

when another player joins it says:
Quote
4 players
2 Guest
2 Guest
3 Guest
3 Guest

the last player that joins will see the information correctly, i mean: every user only once.
but if a new player joiins after him he will see him duplicated!!


what could be causing this?

5
hi!
yes, its me again.

im creating an udp lobbyserver without problem.

then run a unity program and creates a server with:

  1.                                 TNServerInstance.serverName = "Test Server";
  2.                                 TNServerInstance.Start(5127, 5128, null, TNServerInstance.Type.Udp, Tools.ResolveEndPoint("mytest.com:5129"));
  3.  
  4.  

it works fine from the unity editor, if i print the content from the serverlist i can see the external address being: 190.205.something.something:5127
and the internal adderss being 192.168.0.2:5127


but!
if i build the program and run the .exe file, when i print the serverlits, i can see the external address being: 190.205.something.something:5127 correctly
but the internal address becomes 255.255.255.255:5127

after that i got "The requested address is not valid in its context" messages


what im doing wrong?



6
TNet 3 Support / lobby server not working
« on: June 20, 2014, 02:59:16 AM »
hi!

is anybody using the current version lobby server?

because i got an unhandled exception.

i tried on linux, and in my own computer, and nothing.

i spent a few hours and found where the error is, but i have no idea why it happens.


in the file TNTcpLobbyServer.cs
at the beggining of the  ThreadFunction () function

  1. void ThreadFunction ()
  2.         {
  3.                 for (; ; )
  4.                 {
  5.                         mTime = DateTime.Now.Ticks / 10000;
  6.  
  7.                         // Accept incoming connections
  8.                         while (mListener != null && mListener.Pending())
  9.                         {
  10.                                 TcpProtocol tc = new TcpProtocol();
  11.                                 tc.data = (long)(-1);                                 /* this is supposed to initialize field data to -1 and it works ok */
  12.                 Console.Write(tc.data);                                              /*  prints -1 which is ok */
  13.                                 tc.StartReceiving(mListener.AcceptSocket()); /* something happens here *************/
  14.                 Console.Write(tc.data);                                             /* doesnt print anything, but no exception is thrown */
  15.                                 mTcp.Add(tc);
  16.                         }
  17.  


later on, in the same function,  when the mTcp[n] data is going to be accessed you get a null reference exception.


  1.                         if (mTcp.size > instantUpdatesClientLimit) mInstantUpdates = false;
  2.  
  3.                         // Send the server list to all connected clients
  4.                         for (int i = 0; i < mTcp.size; ++i)
  5.                         {
  6.  
  7.                 Console.Write(mTcp[0].data);        /* doesnt print anything, but no exception is thrown*/
  8.                 Console.Write(i);                         /* prints 0*/
  9.                                 TcpProtocol tc = mTcp[i];
  10.  
  11.                 Console.Write(tc.data);              /* doesnt print anything, but no exception is thrown*/
  12.    
  13.                                 long customTimestamp = (long)tc.data;   /* ***************** null reference exception .... */
  14.  
  15.  

well...

im out of ideas

any help please?



ps. i am using this code in the client:

         TNServerInstance.serverName = "My test Server";
         TNServerInstance.Start(5127, 0, null, TNServerInstance.Type.Tcp, Tools.ResolveEndPoint("myserver.com:5129"));


yes yes... 2 days and i have only 2 lines of code... and they dont work!

7
TNet 3 Support / TypeLoadException on linux debian
« on: June 19, 2014, 10:52:11 AM »
hi!!
im trying to run the tnserver on linux and i got this error:

----------

#mono TNServer.exe -name "test" -tcpLobby 5129

Unhandled Exception: System.TypeLoadException: A type load exception has occurred.
[ERROR] FATAL UNHANDLED EXCEPTION: System.TypeLoadException: A type load exception has occurred.
------------

i understand that this is some mono error, but... what can i do?

one thing that i noted is that it seems to be using mono 2.0 instead of 4.0.

could that be the problem?

how can i make it use mono 4?

8
NGUI 3 Support / label.text does not work on android‏
« on: April 02, 2014, 04:39:32 PM »
hello there!!

i imported a new asset
the terrain for mobile to be specific  (this one: http://u3d.as/content/azert2k/t4m-source-codes-edition/1Ec)

when in converted the terrain to object, the label stoped working.

i was using it this way:

  1. label.text = format;
(format is a string)


now it doesnt work.
the label appear on screen but it only shows the initial value. i cant update it.

i created a second label and had the same problem.


i went to the UILabel script
and changed the "text" method to this:


  1.         public string text
  2.         {
  3.                 get
  4.                 {
  5.                         return mText;
  6.                 }
  7.                 set
  8.                 {
  9.                         GUI.Box(new Rect(500,50,200,40), mText);
  10.                         .........
  11.                         .....
  12.  

but nothing happens... so the text method is not being executed.

but if i put the "GUI.Box....." , before the "label.text=format" , then i can see the value on screen...

so ... there is something in between...

how, and were could i debug this???


please note that it works fine in the unity editor, but not in the android device.

thanks in advance!


ps. i am using version 3.5.1
ps2. please let me know if i wasnt clear.

Pages: [1]