Hello Guest

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

Pages: 1 2 3 [4] 5
46
Support / Re: Preparing for git?
« on: July 09, 2013, 11:27:06 pm »
Git is awesome. I would recommend using it even if you are not worried about backing up your work. Monodevelop integrates with it so you can see any modifications made to your code, and easily try out big changes without the chance of spoiling anything.

The docs page on version control recommends ignoring the ~tk2droot file and the tk2d resource files within Assets, is this still advised? I don't think it makes much difference either way.

Full text serialization is Pro only, yes, the best free gets is 'mixed'.

47
Releases / Re: 2D Toolkit 2.1 beta 1
« on: July 09, 2013, 04:38:12 am »
Turn on the 'Fixed Z' button then you can set whatever values you like.

48
Support / Re: Some performance questions
« on: July 08, 2013, 07:55:58 am »
Can't answer 1 but here are some thoughts on 2 & 3...

Quote
2- For a static background, what would be better? The unity mobile skybox, or a big tk2d Sprite?

If it's static then using a skybox seems like wasted texture memory, since skybox cubemap has 6 sides a lot of it will never be seen. Use a "Sprite from texture".

Quote
3- What shader should I choose for my sprites? Should I use the default ones? Is there any documentation about the diferences between them? I see a lot of shaders in the Shaders folder, but I'm totally ignorant about this low level stuff.

Use the ones in the tk2d folder of the dropdown, and pick the one that has the features you need. Most of the built-in Unity ones do not support vertex colours which tk2d makes heavy use of.

Generally ... if the name has 'Lit' in front, the shader supports lighting. If not then it doesn't. Then you have either 'Solid' or 'Transparent' varieties. Solid is fast, good for ground tiles and such that fill the whole sprite polygon.

Transparent is then split into 'additive', 'blend', 'cut-out' or 'pre-multiply', which are all different methods of blending the pixels with the background. Which one you choose again depends on your requirements:

Additive - 'adds' its pixels to the background ones, you see this a lot in glowy effect stuff.
Blend - uses the alpha channel of the bitmap, where shades of grey determine how transparent a pixel is. The most common general-use solution.
Cutout - like blend but uses a cutoff on the alpha channel to basically use only black or white, so a pixel is either transparent or it isn't. This is used to get sorting within a mesh as it can interact with the depth buffer.
Pre-multiply - is a tricky combination of additive and blend, where the alpha channel controls the mix between the two methods. If the alpha channel pixel is black then the RGB pixel is 100% additive, and if it's white then the RGB pixel is 100% blended.

Some knowledge will be required to make more informed choices, the Unity docs has more info on shader families and the differences between them.

49
Releases / Re: 2D Toolkit 2.1 beta 1
« on: July 08, 2013, 05:14:19 am »
WOW this new tk2d camera is awesome. Seriously good - I just love the pixels per meter.

50
Support / Re: Can you make a sprite black when not lit?
« on: July 05, 2013, 11:08:05 pm »
Lol sorry, 'turn off' = set it to zero = make it black, you did the right thing.

51
Support / Re: Can you make a sprite black when not lit?
« on: July 04, 2013, 11:56:57 pm »
The first thing that comes to mind is that you'll need to turn off ambient lighting in render settings, and make sure you are using the tk2d Lit shaders..

52
Support / Re: UI looks scrambled
« on: July 03, 2013, 01:34:02 pm »
I have a 3.5 install, and the same package works fine on that.

I can't see how it would make much difference, but just in case - my 3.5 is a pro license and my 4 is free license.

53
Support / Re: UI looks scrambled
« on: July 03, 2013, 11:34:51 am »
For me it is broken in a brand new empty project (no other packages loaded) with the asset store hotfix 2 version, and with the tilemap pre-release. Win 64 Unity 4.1.4f1.

edit: tested on my Mac as well, same versions and same scrambled result.

54
Support / Re: UI looks scrambled
« on: July 03, 2013, 05:54:15 am »
Pretty sure this is the problem, see here:

Ok for some reason the font is getting wiped. Open up the UIDemoSpriteCollection sprite collection, and then under the "fonts" category, you'll see an entry labelled "Empty". Click on it, and in the "BM Font" slot, drag in "OldSansBlack". Commit and everything should work again. Not sure why its lost the reference - that file has been there for a long time.

55
Support / Re: 2D Toolkit Roadmap Trello
« on: July 03, 2013, 01:29:27 am »
I'm all for vert colour per layer as well. Another interesting thing here would be applying colours by face as well as vertex.

56
Any thoughts on the tilemap tangents implementation from my earlier question in the thread? I voted on Trello but not sure there will be universal excitement for the feature. :(

For now I have just added a generic algorithm I found on Unity Answers that calculates them for the whole mesh, but it's not ideal. Since the tangents already exist for the individual sprites, is there a better way to get those onto the final tilemap mesh?

57
Initially I just manually made a normal map from a duplicate of the generated atlas texture, but to do it properly I'm now following these instructions from another thread on a similar topic:
Duplicate the sprite collection (not the data object), open the duplicate, go into sprite collection settings, "Clear references" and Commit. You should get a second "Data" folder. Go through the list and switch all textures to the normal maps. Make sure the sprite dimensions are identical.

Problem is, 'Clear References' destroyed both the copied and original collections, and now they give "IndexOutOfRangeException: Array index is out of range.
tk2dSpriteCollectionBuilder.UpdateVertexCache (.tk2dSpriteCollection gen, Single scale, tk2dEditor.Atlas.Data[] packers, .tk2dSpriteCollectionData coll, System.Collections.Generic.List`1 spriteLuts) (at Assets/TK2DROOT/tk2d/Editor/Sprites/tk2dSpriteCollectionBuilder.cs:1685)" whenever trying to use them.

I think it may be related to my original collection having multiple materials, as all the materials got wiped as well. I realise this isn't really supported stuff, and am posting it more as a warning for anyone else looking to do similar.

edit: on second thoughts this is probably a bit of a nasty bug - it is easily reproduced by duplicating a collection that uses 2 materials, opening the new collection, 'Clear References' and committing. I am using the pre-release tilemap version.

58
Count me in as another party keen on normal map support for atlases. Or some kind of arbitrary multi-atlas per sprite feature so I can dream about spec and emissive maps as well. :)

Anyway, back to reality - my current experiments have lead me to use normal mapping on tilemaps, and today's issue is that tangents are not generated for tilemaps like they are for sprites.

Any advice on how to go about adding this? For now I have just added a generic algorithm I found on Unity Answers that calculates them for the whole mesh, but it's not ideal. Since the tangents already exist for the individual sprites, is there a better way to get those onto the final tilemap mesh?

59
Support / Re: Question about lighting
« on: July 01, 2013, 06:10:36 am »
You need to make sure your sprites have normals (SpriteCollection/Settings/Normal Generation), and that you use one of the lit shaders.

60
Support / Re: Using Tilemap Editor for Top Down RPG
« on: June 30, 2013, 01:52:22 pm »
Excellent!

I added a "z offset per row" field to the Settings/Layers inspector so I can control it per layer, and it seems to be working wonderfully. Cheers.

Pages: 1 2 3 [4] 5