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

Pages: [1] 2
1
Other Packages / Re: UI Starter Kit: Starlink (NGUI + TNet)
« on: June 27, 2017, 12:29:16 PM »
Starlink UI kit has been updated to use TNet3 a year and a half ago, so I am not sure what you're asking...

Oh right, since your last post on this topic says it's added to the TODO list and there is a compile error on the package I thought it wasn't done yet.

  1. Assets/StarlinkUI/Scripts/Custom/Misc/GameManager.cs(234,26): error CS0115: `GameManager.OnEnable()' is marked as an override but no suitable method found to override

TNBehavior doesn't have an OnEnable method. Removing the override keyword and base.OnEnable call compiles it. Guess OnEnable got removed after updating the Starlink package.

Apart from that I get a bunch of localization warnings. I see that many widgets have UILocalize attached to them without any keys present. I'm using the latest versions of NGUI (3.11.4), TNet3(3.0.9) and Starlink UI (1.2.0) from the Asset Store.

2
Other Packages / Re: UI Starter Kit: Starlink (NGUI + TNet)
« on: June 22, 2017, 08:20:54 AM »
I'll add it to the TODO list.

Any news on updating the Starlink to work with TNet3? Purchased it before it was free, would love to use it to learn more about Tnet3.

3
NGUI 3 Support / Re: Slider with Custom Shader
« on: August 30, 2015, 03:37:20 PM »
_MainTex is the standard Unity binding for the main texture. UITexture lets you specify a texture + shader, meaning NGUI will create a material here and set the _MainTex for you.

When I assign a material, the shader field is removed from the custom UITexture inspector, why not texture field also? My material has all the textures assigned and if I don't use _MainTex in my shader for any textures and don't assign anything to the mainTexture member, UITexture is automatically disabled on the build only. If it's not a bug, then it's a very frustrating way of doing it.

4
NGUI 3 Support / Re: Slider with Custom Shader
« on: August 29, 2015, 07:48:37 PM »
Nevermind, I see that NGUI assumes that I have a "_MainTex" property for the primary texture in my shader if I leave the texture field null. Question is, why is it a requirement, what does NGUI do with the mainTexture property in UITexture.cs?

5
NGUI 3 Support / Re: Slider with Custom Shader
« on: August 29, 2015, 07:43:04 PM »
I have encountered a strange problem. If I leave the "texture" field of the UITexture null, the widget appears completely transparent in the build only. Looks fine in the Editor. Is this intentional? I'm already assigning a material which contains all the textures and other properties I need and want to leave the texture field null.

6
NGUI 3 Support / Re: Slider with Custom Shader
« on: August 22, 2015, 05:50:00 AM »
That's a cool effect. If you can do it without custom meshes, then you can do it with NGUI. Use UITexture to draw any custom material. The slider can reference any widget, UITexture included.

Managed to achieve the exact same effect by offsetting the texture coordinates with another texture's r and g channels instead of having a custom mesh with distorted uv's. Which made the shader more versatile too. Works perfectly, thanks a lot!

7
NGUI 3 Support / Slider with Custom Shader
« on: August 21, 2015, 01:33:49 PM »
Attached is a screenshot from a shader I've made for a healthbar. It is a very simple shader/mesh effect, using distorted UV coords and a panner.

Is it at all possible to use such a shader and a custom mesh as a slider with the default NGUI classes? If not, what would be the best way to implement this visual effect so that it works as an NGUI widget/slider?

8
NGUI 3 Support / Re: Disabling Interaction While Tweening
« on: June 17, 2015, 02:17:56 AM »
Easiest thing to do is to create a panel with higher depth than other panels, then place a full-screen widget underneath it with a collider (ALT+SHIFT+W, ALT+SHIFT+C). It will intercept all events. Either that, or turn off events on the UICamera.

Thanks, will keep those in mind. I've ended up changing the state of all the buttons, I wanted to show their disabled color too.

9
NGUI 3 Support / Disabling Interaction While Tweening
« on: June 02, 2015, 07:12:45 PM »
I want to use position tweens for the transitions between my panels but I want it so that player won't be able to interact with any UI element while the position tween is playing.

Does NGUI have any utility to handle that or do I disable every element's collider for example wherever I call the PlayForward() and re-enable them on OnFinished?

10
TNet 3 Support / Different Games on Same Lobby Server
« on: December 12, 2014, 02:34:08 PM »
I've searched but couldn't find a similar question, if it's asked before or answered anywhere else my apologies.

Is it possible to register the servers of two completely different games on the same lobby server? Or do I have to rent a new hosting for each game's remote lobby server separately?

11
TNet 3 Support / Re: Creating Lan-Only Server
« on: November 25, 2014, 04:06:45 AM »
Your answers combined with reading the docs and example code and implementing Tnet made it so much clearer. Thanks a lot!

12
TNet 3 Support / Possible Bug in LagPosition Script
« on: November 24, 2014, 09:54:52 AM »
There is possibly something very simple going on and I've probably fixed it with an overkill solution but here it goes.

Setup:

On my player prefab, the renderer and the collider are on two separate game objects. Renderer has the LagPosition script attached. Works great, no problems regarding jittering / stuttering whatsoever.

What happens:

Player1 enters the game.
Player1 moves it's avatar.
Player2 joins the game.
In Player2's instance, Player1's avatar smoothly moves from it's spawn point to it's current position instead of appearing in it's current position.

How I fixed it

I delayed the initialization of the LagPosition script. I set the mTrans, mAbsolute and mRelative variables a couple frames later so they get the synced position of the other avatars.

So is this a bug or am I missing something? At any rate, it's working now.

13
TNet 3 Support / Re: Creating Lan-Only Server
« on: November 22, 2014, 10:10:55 PM »
Okay last questions.

1) I see that in Starlink udp is used for the LAN lobby and tcp for the internet. Is there a specific reason reason for that? Is it better to use the udp lobby for the LAN and the tcp for the internet?

2) Can I register a udp enabled game server on a tcp lobby server and vice-versa?

3) What data is saved in the file given to the "fileName" parameter upon starting a server and why?

14
TNet 3 Support / Re: Creating Lan-Only Server
« on: November 22, 2014, 05:49:08 PM »
Not sure what you mean by it not being playable... did you expect the game code? It's just the UI for it, game code isn't there, there is nothing to be playable.

Oh, I actually bought it to study a tnet integrated game code. Should check the product description and name before buying I guess...

Edit: Upon reading the product description it says here http://www.tasharen.com/forum/index.php?topic=4506;

Optional TNet Networking integration adds:
Server, channel and player lists
Internet/LAN/Direct Connect
Multiplayer chat
Other stuff™


But there is no internet right?

15
TNet 3 Support / Re: Creating Lan-Only Server
« on: November 22, 2014, 03:14:46 PM »
I guess it will be best if I buy starlink and study it's code.

EDIT: So I bought it. Imported in a clean project. Imported the Tnet Integration package on it. Set up the layers. Checked the "run in background". And the game is not working as it's supposed to. Attached are the screenshots of the problems.

- It's not playable at all, stuck on the screen shown in the ss3.jpg.
- As soon as the stats are loaded, a strange background glitch appears as shown in ss1.jpg.
- Internet is greyed out as shown in ss2.jpg.

Pages: [1] 2