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 - Hoppertje

Pages: [1]
1
I appreciate your warning but that is really up to me right?

All i need to find out how creative i can be with TNet's structure...

- How many rooms can you create?
- How many clients could you connect into a single room?
- Can you be sole owner to all rooms that are created?
- Can you communicate between rooms?
- Can you deny players creating rooms?

After having re-read your first reply, you give me a alternative solution which i will test further... however you did not give a answer to my initial code question, can it be done as i suggested, what am i doing wrong in that piece of code?

2
Yes you are right, i do think my mindset is set/stuck in a traditional way... I do not have that clarity you speak off...

What you are describing here I can see this work for a small multi-player environment, where each game is hosted by a player ( 2-64max )... but my approach is that for an MMO( i should have mentioned this earlier )... I do not wish others to run a host at all... There has to be 1 dedicated authoritative server, which is controlled by me...

Sorry for running in circles here...  Should i consider the designated host here to be this dedicated authoritative server ?
Run it locally next to the Lobby(Master)Server ?

( I am not sure what you meant by doing packet inspection! - I dont think i was suggesting this? )

3
Firstly i like to thank you for your very extensive explanation!

And as i will have to re-read this post a couple of times to fully understand it... i do feel to mention that i choose to have client - server code separated... i do not want the client to have any server code...

Does that change things?

4
TNet 3 Support / [UNSOLVED] Sending a message back and forth not working
« on: February 18, 2015, 09:58:53 AM »
I am stuck with sending messages back and forth...

My Goal Is:
Client connects to server(No Lobby)( OnNetworkConnect returns True )
On client connection send message from client to server ( Not Working )
On message receive send back message to client ( Not Working )

The FromClient() in the server script does not get triggered

Unity Server Project:

Attached scripts to empty GameObject:
NetworkManager
TNOObject

  1. using UnityEngine;
  2. using System.Collections;
  3. using TNet;
  4.  
  5. public class NetworkManager : MonoBehaviour
  6.     {
  7.     TNObject    tnoObject;
  8.  
  9.     private void Start( )
  10.         {
  11.         TNServerInstance.Start( xxx1, xxx2 );
  12.         tnoObject = GetComponent<TNObject>( );
  13.         }
  14.  
  15.     private void Update( )
  16.         {
  17.         }
  18.  
  19.     [RFC] void FromClient( string myString, int playerID )
  20.         {
  21.         Debug.Log( "From Client: " + myString );
  22.  
  23.         Player p = TNManager.GetPlayer( playerID );
  24.         // tried p, p.id, p.data
  25.         tnoObject.Send( "FromServer", p.id, "TestFromServer" );
  26.         }
  27.  
  28.     private void OnNetworkConnect( bool success, string message )
  29.         {
  30.         Debug.Log( ">> OnNetworkConnect " + (     success+" <> "+ message ).ToString() );
  31.         }
  32.  
  33.     private void OnNetworkDisconnect( )
  34.         {
  35.         Debug.Log( ">> OnNetworkDisconnect " );
  36.         }
  37.     }



Unity Client Project:

Attached scripts to empty GameObject:
NetworkManager
TNManager
TNObject

  1. using UnityEngine;
  2. using System.Collections;
  3. using TNet;
  4.  
  5. public class NetworkManager : MonoBehaviour
  6.     {
  7.     TNObject    tnoObject;
  8.  
  9.     private void Start( )
  10.         {
  11.         TNManager.Connect( "xx.xx.xx.xx:xxx1" );
  12.         tnoObject = GetComponent<TNObject>( );
  13.         }
  14.  
  15.     private void Update( )
  16.         {
  17.         if( TNManager.isConnected )
  18.             {
  19.             tnoObject.Send( "FromClient", Target.Host, "TestFromClient", TNManager.playerID );
  20.             }
  21.         }
  22.  
  23.     private void OnNetworkConnect( bool success, string message )
  24.         {
  25.         Debug.Log( ">> OnNetworkConnect " + (     success+" <> "+ message ).ToString() );
  26.         }
  27.  
  28.     [RFC] void FromServer( string myString )
  29.         {
  30.         Debug.Log( "From Server: " + myString );
  31.         }
  32.     }


5
TNet 3 Support / Is TNet for me...
« on: February 17, 2015, 05:54:19 PM »
I am looking for a network engine that can support a MMO platform...

I am not really interested in network views or network instantiates... i will be using RPC/RFC's and keep track of players/objects myself...
SideQuestion: One of Unity's Networking bugs was that any dirty client could network.instantiate, the masterserver could be spammed with user made rooms, no locking etc... has this been resolved with TNet?

My preference would be to not use TNet's MasterServer but use a direct approach - Unity client as server, is this possible?

Doing the above, would that undermine what TNet stands for; is TNet for me?


Thanks!



Pages: [1]