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.


Messages - ekilog

Pages: [1]
1
TNet 3 Support / OnNetworkConnect not triggered
« on: March 02, 2014, 04:42:48 PM »
Hello,

It use to work... not anymore. Do you know a reason why OnNetworkConnect() would not be triggered when trying to connect ?

very simple script... no call back...

  1.         void Awake () {
  2.                 Debug.Log("on va se connecter a TNET");
  3.                 TNManager.Connect("78.192.14.236", 54000);
  4.                 Debug.Log ("fait");
  5.         }
  6.  
  7.         public void OnNetworkConnect (bool success, string message)
  8.         {
  9.                 Debug.Log("OnNetworkConnect");
  10.                 if(success)
  11.                 {
  12.                         Debug.Log("onNetworkConnect : " + success + "-" +  message);
  13.                 }
  14.                 else
  15.                 {
  16.                         // il faut prévenir que le réseau ne fonctionne pas.
  17.                         Debug.Log("OnNetworkConnect: pas ok");
  18.                 }
  19.                
  20.                 // on demande la liste des channels disponible actuellement sur le serveur avec un seul joueur
  21.                 //              channelList = new TNet.List<string>();
  22.                 //              TNManager.client.BeginSend(Packet.RequestChannelList);
  23.                 //              TNManager.client.EndSend();
  24.                 statics.networkAvailable();
  25.         }
  26.         void OnNetworkError (string message)
  27.         {
  28.                 Debug.Log("onNetworkError : " + message);
  29.         }
  30.  

2
TNet 3 Support / Re: TNetServer and gateway
« on: February 27, 2014, 03:23:21 AM »
You should generally get a list of channels from the server first, and let the player choose which to join, or create a new game. If you're doing a quick match game and all channels are guaranteed to be your game instances, then joining a random channel is fine. I'd generally advise you to pass a level name though.

I'm looping here...

I want to reproduce the GameCenter behavior.

1st player create a game (create a channel with player limit = 2)
2nd player join the game

3rd player create a game (create a channel with player limit = 2)
etc...

But :

- When the first channel is created, it does not appear in the Channel List (except if the channel is created with JoinChannel() )
- when the first channel is created with JoinRandomChannel, the 2 first players did not see each other.

I'm not sure how to use the JoinRandomChannel.

Any help is appreciated.

regards

3
TNet 3 Support / Re: TNetServer : Channel discussion
« on: February 27, 2014, 01:25:00 AM »
You join a channel using a specific ID. Use the same ID the second time, and you will end up in the same exact game.

ok. But in another post, I explain that the JoinRandomChannel is not triggering any feedback and this is why I tried to use the JoinChannel. Any idea ?

http://www.tasharen.com/forum/index.php?topic=8263.0

4
TNet 3 Support / TNetServer : Channel discussion
« on: February 26, 2014, 01:27:40 PM »
Hello,

I'm confused. I've been able to run the game with the 2 players connected, turn by turn. If one application goes background (player 2), the player 2 leaves the channel.

Player 1 is told that the player 2 has gone.

when player 2 is back (app is back in the foreground), how should I make sure that He will join the same channel and get back the game where He left it ?

Thank you for your help.

Hervé

5
TNet 3 Support / Re: TNetServer and gateway
« on: February 26, 2014, 02:44:30 AM »
JoinRandomChannel passes '-2' for the channel ID, which is interpreted as "any open channel" by TNet.GameServer (line 815).

Whether the join request succeeds or fails, you always get OnNetworkJoinChannel back. This notification is sent to the player who is attempting to join. Other players get a different notification -- OnNetworkPlayerJoin.

Hi,

Thank you for your answer. I probably miss something here. My game is a turn by turn game with 2 players. Should I use JoinRandomChannel or Joinchannel with a static channel number (alway 1 for example). How can I make sure that a channel with 1 player will be filled by the next requester ?

Thank you again.

Hervé

6
TNet 3 Support / Re: TNetServer and gateway
« on: February 25, 2014, 02:27:44 AM »
just for your information, using TNManager.JoinChannel(0, null), it works.
It look like the joinRandomChannel is not connecting players ?
Your help is appreciated.
regards,

7
Other Packages / Re: NGUI: HUD Text
« on: December 18, 2012, 03:42:56 PM »
Delete LookAtTarget from HUDText (or dont import it). I'll fix it in the next update -- it seems the metadata changed.

Hello,

I got NGUI full version and I just purchased HUD Text and cannot get rid of the compilation error. What should I do ?
UNITY 4 PRO + IOS.
error are :

Assets/NGUI/Scripts/UI/UISlicedSprite.cs(140,30): error CS0115: `UISlicedSprite.OnFill(BetterList<UnityEngine.Vector3>, BetterList<UnityEngine.Vector2>, BetterList<UnityEngine.Color32>)' is marked as an override but no suitable method found to override

Assets/NGUI/Scripts/UI/UITexture.cs(124,33): error CS0546: `UITexture.mainTexture.set': cannot override because `UIWidget.mainTexture' does not have an overridable set accessor

Assets/NGUI/Scripts/UI/UITexture.cs(124,33): error CS0506: `UITexture.mainTexture': cannot override inherited member `UIWidget.mainTexture' because it is not marked virtual, abstract or override

Assets/NGUI/Scripts/UI/UITexture.cs(177,30): error CS0505: `UITexture.OnFill(BetterList<UnityEngine.Vector3>, BetterList<UnityEngine.Vector2>, BetterList<UnityEngine.Color32>)': cannot override because `UIWidget.OnFill(BetterList<UnityEngine.Vector3>, BetterList<UnityEngine.Vector2>, BetterList<UnityEngine.Color>)' is not a method

Assets/NGUI/Scripts/UI/UITiledSprite.cs(50,30): error CS0115: `UITiledSprite.OnFill(BetterList<UnityEngine.Vector3>, BetterList<UnityEngine.Vector2>, BetterList<UnityEngine.Color32>)' is marked as an override but no suitable method found to override


thanks.

Hervé

Pages: [1]