Hello Guest

Author Topic: 2D Toolkit 2.3.3  (Read 61702 times)

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
2D Toolkit 2.3.3
« on: December 15, 2013, 09:40:12 pm »
Please read the migration guide before updating. 2D Toolkit 2.x is not API compatible with 1.x.
http://unikronsoftware.com/2dtoolkit/docs/2.3/migration_guide.html

Maintenance release

Documentation available at:
http://unikronsoftware.com/2dtoolkit/docs/2.3


Be sure to run "Setup for JavaScript" after importing if you're using this feature. 2.3 is a very big update - and you're likely to have errors if you don't run this properly after restarting Unity.

What's new
  • Support for Unity 4.3 - 2D physics and render layers. Notes here
  • Animating 2D polygon colliders when running under Unity 4.3 2D physics
  • Default pixels per meter is now 100 to work better with Unity
  • Png atlases - enable in sprite collection settings. Much smaller builds at the cost of some load time.
  • Dropped support for Unity older than 3.5. Unity 3.5 support will be dropped in 2D Toolkit 2.4
  • Option to disable rotation in sprite collection
  • tk2dCamera - Fill scale mode (contributed code, will need to update with contributor)
  • tk2dTileMap TMX import now supports rotated / flipped tiles.
  • tk2dUIMask - now has sorting layer controls when run on Unity 4.3
  • tk2dTileMap now supports Unity sorting layers - this overrides all other sorting controls.
  • Added experimental PNG atlas usage detection and unloader - disabled by default. Please help test this if you use PNG atlases. Enable it by uncommenting the first line in tk2dEditorSpriteDataUnloader.cs and restart Unity. You shouldn't notice any difference, but Unity shouldn't run out of memory. There are still cases where things get orphaned, please report back if you find any reproducible ones.



Bug fixes and improvements
  • tk2dSpriteAnimator - pingpong mode bugfix with 1 frame
  • SetFocus(bool) on tk2dUITextInput, lets you set shift focus to another control from the callback.
  • tk2dSpriteAnimator - ProcessEvents works with invalid input
  • 2d sprites retain trigger status, should work a bit better than before and shouldn't add random colliders
  • Loadable assets now persist after Rebuild Index
  • Tilemap error on awake, was harmless but annoying
  • Tilemap import bugfix
  • FormatText missing InitInstance
  • PNG atlases building bug with fonts
  • Static sprite batcher null ref error
  • one shot audio volume workaround
  • tilemap material fix
  • material id fix when sprite collection is rebuilt after clearing references with material overrides
  • tk2dCameraAnchor - doesn't mark scene dirty every frame
  • tilemap - random brush respects flip and rotate flags
  • unity 4.3 undo and other compatibility fixes
  • removed useGameWindowResolutionInEditor compile warning
  • AlphaIsTransparency is set on imported textures
  • Sprite collection editor performance improvements, now can handle 10000s of sprites in a collection.
  • Hide tk2d widgets when shift is held down to tweak colliders.
  • tilemap prefabs that are in the scene will be destroyed if the prefab type is changed.
  • Tilemap normals on when sprite collection setting requests normals

Antsurkov

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 2
    • View Profile
Re: 2D Toolkit 2.3.3
« Reply #1 on: December 16, 2013, 06:04:20 am »
Thanks a lot! But please, comment what is "one shot audio volume workaround"?
Previously, I had a strange increase in volume, when playing the same audio files in a short time in Camera.main.audio.PlayOneShot().
Is thaht it?

TekuStudios

  • 2D Toolkit
  • Full Member
  • *
  • Posts: 177
    • View Profile
    • Teku Studios
Re: 2D Toolkit 2.3.3
« Reply #2 on: December 16, 2013, 11:47:21 am »
Nice! What exactly are the problems with this new version? We really need those PNG atlases, so we are thinking on upgrading our 2DT to this version. Is it a viable workaround for us? I mean, will we have to re-make some things with 2.4 (or the next fixed release)? We are going to upgrade most of our project so we need to be sure that the next version won't break things with the new atlases provided with this one.
We are an Indie videogame developer located in Teruel, Spain. A small 6-people team which is currently working on the upcoming 'Candle'.

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: 2D Toolkit 2.3.3
« Reply #3 on: December 16, 2013, 12:18:21 pm »
Its worth a go - it seemed to work fine in our testing, so just turn it on and try it. Its not going to change any runtime code, so everything that happens is editor only. Easy enough to turn off too.

TekuStudios

  • 2D Toolkit
  • Full Member
  • *
  • Posts: 177
    • View Profile
    • Teku Studios
Re: 2D Toolkit 2.3.3
« Reply #4 on: December 16, 2013, 12:34:28 pm »
Okay, I'll try to find an understandable repro case, but for now our project is still always crashing. We have a very, very large amount of sprites at a very high resolution (that's why we needed to reduce as much as we could the atlas size), but every time we hit Play or try to Build Unity throws the exact same memory leak error and closes. We haven't changed anything aside from the collections (each one of them is now PNG atlas).
We are an Indie videogame developer located in Teruel, Spain. A small 6-people team which is currently working on the upcoming 'Candle'.

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: 2D Toolkit 2.3.3
« Reply #5 on: December 16, 2013, 01:04:11 pm »
This is with the data unloader enabled? If so, email me and i'll give you a little bit of debug code to add in there to let you know when it unloads something.

Kea

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 40
    • View Profile
Re: 2D Toolkit 2.3.3
« Reply #6 on: December 16, 2013, 02:18:54 pm »
NullReferenceException: Object reference not set to an instance of an object
tk2dTextGeomGen.GetMeshDimensionsForString (System.String str, .GeomData geomData) (at Assets/TK2DROOT/tk2d/Code/Fonts/tk2dTextGeomGen.cs:39)
tk2dTextGeomGen.SetTextMeshGeom (UnityEngine.Vector3[] pos, UnityEngine.Vector2[] uv, UnityEngine.Vector2[] uv2, UnityEngine.Color32[] color, Int32 offset, .GeomData geomData) (at Assets/TK2DROOT/tk2d/Code/Fonts/tk2dTextGeomGen.cs:298)
tk2dTextMesh.DoNotUse__CommitInternal () (at Assets/TK2DROOT/tk2d/Code/Fonts/tk2dTextMesh.cs:634)
tk2dUpdateManager.FlushQueuesInternal () (at Assets/TK2DROOT/tk2d/Code/Runtime/tk2dUpdateManager.cs:74)
tk2dUpdateManager.LateUpdate () (at Assets/TK2DROOT/tk2d/Code/Runtime/tk2dUpdateManager.cs:57)


Take this error after update.

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: 2D Toolkit 2.3.3
« Reply #7 on: December 16, 2013, 02:21:48 pm »
Can you create a separate post about that with details about what your code is doing there? The only difference there is it tries to initialise itself before using it - previously it should have had an error too unless something else has changed.

TekuStudios

  • 2D Toolkit
  • Full Member
  • *
  • Posts: 177
    • View Profile
    • Teku Studios
Re: 2D Toolkit 2.3.3
« Reply #8 on: December 16, 2013, 03:32:53 pm »
@unikron Yes, we uncommented that line, so it's enabled. By the way, we are using Unity 4.3.1. What do you want me to email exactly?
« Last Edit: December 16, 2013, 03:34:48 pm by TekuStudios »
We are an Indie videogame developer located in Teruel, Spain. A small 6-people team which is currently working on the upcoming 'Candle'.

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: 2D Toolkit 2.3.3
« Reply #9 on: December 16, 2013, 03:44:33 pm »
Nothing just drop me and email and I'll reply with the modified code when I get a chance :)

Finnegan

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 38
    • View Profile
Re: 2D Toolkit 2.3.3
« Reply #10 on: December 16, 2013, 03:45:19 pm »
For some reason I can't open Sprite Animation Editor after update. The "Open Editor" button just does nothing in all my projects.

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: 2D Toolkit 2.3.3
« Reply #11 on: December 16, 2013, 08:07:51 pm »
It could be that unity bug where the editor window position gets corrupted. You can reset this by Reverting to factory layout in Unity to see if that helps.

Finnegan

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 38
    • View Profile
Re: 2D Toolkit 2.3.3
« Reply #12 on: December 17, 2013, 09:39:33 am »
It could be that unity bug where the editor window position gets corrupted. You can reset this by Reverting to factory layout in Unity to see if that helps.
Yep, it was layout bug! Thank you.

Finnegan

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 38
    • View Profile
Re: 2D Toolkit 2.3.3
« Reply #13 on: December 18, 2013, 11:43:15 am »
Another issue: I can't switch the clips from editor on the fly anymore (inside Sprite Animator). It just plays the clip that was selected when scene started to play.

I tested it for an animation with a low frame rate: when switching, the animation shows a new clip for a moment and then returns to the previously selected.

upd: I also can't change Anim Lib property.
If I start with "once" clip, I can select another animations, but they will not play. If I start with a looped clip, it will stuck and prevent editor from switching to other animations.
« Last Edit: December 18, 2013, 11:58:10 am by Finnegan »

Kea

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 40
    • View Profile
Re: 2D Toolkit 2.3.3
« Reply #14 on: December 18, 2013, 01:35:36 pm »
2 unikronsoftware:

Dinesh, i send to you email with description of error. Do you get it?