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

Pages: [1] 2
TNet 3 Support / Object ownership
« on: September 21, 2017, 04:04:54 AM »
I have searched the forums regarding transfer of object control / ownership.
In one thread, a poster describes a method of setting mOwner to reassign ownership but is dissuaded from doing so a(by Aaron) as it might mess things top.
On the other hand, in one of the examples there is a ClaimObject method which does exactly the above.

What is the current truth and recommendation? Thanks! :)

PS. Still struggling with the “error: previous reply was less than 180 seconds ago”, even though that is not even true. I can wait 15 minutes and still get that error…?

TNet 3 Support / RFCs IDs : why/when?
« on: September 21, 2017, 03:09:30 AM »
Short question: The examples, documentation and some comments on the forum indicates that RFCs can be sent and implemented with or without a custom ID.
In one post I think Aaron wrote something along the lines of "You don't have to specify an ID, but you can do that if you want to optimise bandwidth".

So, when would you specify an ID and what effects does it have? From a coding POV, skipping IDs are certainly easier as you don't have to keep track of which you have used. So any clarification would be very helpful.

TNet 3 Support / Static TNObject IDs
« on: September 13, 2017, 06:55:03 AM »
Must admit this is a bit confusing.
In our project (which used to use TNet2) we have managers set up inheriting from TNBehaviour. These have RFCs etc. implemented and will respond to network events. These managers are not instantiated at load time and the level is not loaded using TNet.
Does this mean that we now (having upgraded to TNet3) have to handle these managers in a different way? Perhaps they do not even have to inherit from TNBehaviour to respond to network calls? Is there a better way?

TNet 3 Support / TN2.x ->> TN3 ??
« on: July 08, 2017, 06:58:30 AM »

Apologies if this has been covered elsewhere. Did a quick search and came up short.

How compatible is TN3 with TN2? Is the upgrade process similar to the usual (i.e.. delete all related assets and do a clean import)? Or has there been major restructuring requiring a new approach?

Thanks in advance for any links or clarification!

TNet 3 Support / tno.uid and persistance?
« on: May 08, 2014, 03:08:26 PM »
Hi, brief question if I may:

We have a situation where we need to save relationships between objects and need to do so using our own save framework (we cannot rely on TNet). Therefor we need control over the uids we hand objects, and we need to rely on them being the same each time the saved game is started.

Are there any drawbacks to assigning tno ids by hand? An alternative is to separate the save ids and network ideas, but that would leave us with two ids for each object which is not ideal.

Thanks in advance!

TNet 3 Support / TNManager hierarchy and RCCs?
« on: March 03, 2014, 07:45:02 AM »

We will be spawning objects via RCCs, and have read that the functions should be located on the same object as TNManager or on a child. However, some of the functions will only make sense in game (and not in menu scenes, etc.). Will adding child objects to TNManager after scene load still enable TNManager to find functions on these in the event of RCCs?
1. Game starts in menu. TNManager present but no child objects
2. After load of a game scene, a few manager objects are added to the TNManager object, some of these containing RCCs
3. On game exit, these managers are killed and only TNManager remains when returning to the menu scene.

Would that work as intended? Thanks!

TNet 3 Support / RFC payload size limit?
« on: February 28, 2014, 03:49:44 PM »
Did a Google search but found nothing, so here we go:

Is there a size limit or max size recommendation for arguments to RFCs? The only hits I got for the search query was someone sending a string array and getting weird errors. We will be sending a lot of byte[], int[] etc. with a fair number of entries. Will this be a cause of problems?

Edit: By a lot, I do not mean in the same call. But there will likely be a few calls each second with various arrays of varying size (sometimes small, sometimes quite populated).

TNet 3 Support / Dynamic/complex objects
« on: February 13, 2014, 10:15:58 AM »

Perhaps I have missed something in the docs or in the forum, but I have not seen any clear description of the best way to handle situations where you want to generate new content without relying on instantiation but still want to sync states.

For example, we have a set of managers who need to communicate certain data to clients. We also set up avatars using UMA dynamically. Both these cases represent instances where we do not want to instantiate things.

Can I safely assume that it is perfectly fine to:
- Do level loading manually and bring new clients up to speed after the level has been loaded
- Have a scene contain objects with tnobjects already in place with set manually allocated IDs (for managers)
- build new objects at runtime via code and manually add tnobject components with manually allocated ids

Thanks in advance!

TNet 3 Support / A couple of presale questions
« on: December 11, 2013, 03:52:10 AM »

I am considering Tnet as a starting point for our net code. Having looked at Unity Networking and uLink, Tnet comes across as a very good alternative since Unity Networking seems unreliable and uLink is more geared towards authoritative centrally hosted servers. But I have a few questions:

- It is implied but not fully clear that TNet will work simultaneously as both host and client. But I am assuming a player can host a session while him/herself playing using the same Unity instance - correct?

- One strength of Tnet seems to be that the same scene and code paths are used for both multiplayer and single player sessions. I get the impression that the scenes / rigs should be set up as always in multiplayer and single player essentially being simulated multiplayer with one player. Correct? If so, does that mean that lag following / syncing happens much quicker for the local player both in single player sessions and in multiplayer?

- The described approach of separating physics from rendering is one we are already taking. However, we separate physics from rendering as two fully separate objects (to be able to switch off physics fully when not needing it). Will Tnet scripts handle this separated hierarchy or be easily modified to do so? (I am primarily thinking of the "lag following" script referenced in this forum).

- Last but not least, and definitely not meant in a disrespectful way - to the contrary: You seem very competent and I have been very satisfied with NGUI. However, as far as I can tell you are one individual. Are you / will you be able to continuously update Tnet and NGUI and provide support? Since net code is very sensitive and crucial this is a quite important decision factor. While we will definitely delve into the code and hope to be self sustaining, being able to lean on external expertise is a big plus.

Many thanks in advance!

We have the following situation:
- One UIRoot with panels below it used for the main UI w. interaction, centered at origo
- One UIRoot moved out of player view used for rendering to rendertextures for various displays

Despite some minor hickups the above appear to be working fairly well. However, a child panel to the second UIRoot (which is offset) will still have its camera clipping rect indicated around origo instead of around the actual transform of the UIRoot. Is this really intended behavior, or a is it a bug?

NGUI 3 Support / Toggle groups - global?
« on: December 06, 2013, 09:30:56 AM »
We are currently implementing a large number of controls using toggles. I have searched a bit but not found any indication that toggle groups are anything but global, and the possibility to use the root as a group definer seems to have been killed in 3.0.

Assuming that toggle group IDs are indeed global, how would you suggest to keep track of many toggle groups in a project (many of which will not be used simultaneously or in the same context at all)? Honestly, it seems like this is a big step down from the earlier implementation...?

Thanks in advance!

NGUI 3 Support / Getting NGUI to overlay everything? (Oculus Q)
« on: December 06, 2013, 04:34:27 AM »

We are supporting the Oculus rift and need the UI to render on top of all other geometry at all times, and can not use a separate camera for this. (In order to have the UI appear correctly in the Oculus Rift, it needs to be rendered by the stereoscopic pair of cameras rendering the final output to the Rift). Also, we have many separate elements so rendering to a texture and applying that to a plane is not satisfactory.

So, the basic questions: Which shaders are used by NGUI when rendering basic sprites? Is the shader use documented somewhere or how would we go about finding out which shaders are used when (short of stripping the editor code to reveal shaders or walking through the NGUI code)?

Many thanks in advance!

NGUI 3 Support / Duplicating toggle and moving to another panel = confusion
« on: November 25, 2013, 09:48:57 AM »
If I do the following:
- Create a panel ("panel1")
- Create a Toggle under panel1
- Create a second panel ("panel2")
- Duplicate Toggle and move from panel1 to panel2

Selecting the moved toggle will have the checkmark sprite incorrectly placed with an offset relative to panel1. Creating an entirely new Toggle on panel2 will not result in this behavior.

Any ideas? Obvious workaround is to create the controls from scratch for each panel, but this should not be necessary?

NGUI 3 Support / 3.0.6 compile error
« on: November 23, 2013, 11:03:52 AM »
After updating to 3.0.6 (deleted the old folder etc.) I get the following error:

"Assets/NGUI/Scripts/Editor/UIWidgetContainerEditor.cs(110,32): error CS0136: A local variable named `b' cannot be declared in this scope because it would give a different meaning to `b', which is already used in a `child' scope to denote something else"

No earlier issues. Unity version 4.2.2f1.

Thanks in advance

NGUI 3 Support / Tween direction is incorrect?
« on: April 29, 2013, 10:12:20 AM »
When calling UITweener.Play the forwards parameter is not interpreted as expected.

At start we call Play(true) for a tween (position) and then subsequent clicks on the tweened object will toggle the tween. So the next call will be Play(false), followed by Play(true) etc. etc.

Now, the tween plays forwards at start as expected, however the subsequent call Play(false) is ignored. The next call Play(true) incorrectly triggers the revers animation. I have traced through the code but there is nothing strange going on in our code. The calls are sent once for each action and are being ignored the second time, putting the toggle behavior out of sync with other things controlled by it.

Is this a bug or is there anything else that might explain what is going on? Thanks in advance!

Pages: [1] 2