2D Toolkit Forum
2D Toolkit => Releases => Topic started by: unikronsoftware on June 01, 2013, 12:30:32 am
-
Please read the migration guide before updating. 2D Toolkit 2.0 is not API compatible with 1.x.
http://unikronsoftware.com/2dtoolkit/docs/2.00/migration_guide.html
Documentation available at:
http://unikronsoftware.com/2dtoolkit/docs/2.00
What's new
- 2D Toolkit UI
- Sprite handles - you can resize / move(click and drag) / rotate(alt) sprites using the handles. Turn them off in preferences if you don't like them.
- Static sprite batcher - supports all sprite types (clipped, tiled, sliced, normal) and text meshes too. Multiple materials & sprite collections supported.
- Animated sprite deprecated in favour of tk2dSpriteAnimator. Works the same, but lets you animate different sprite types.
- Text mesh supports inline colors and gradient switching. Click the help button in the text mesh editor for more details.
- "Sprite from Selected Texture" - use to create a sprite without a sprite collection. Use with care, as each will require one draw call. It's not there for convenience, but rather for backgrounds and render textures that can't be atlased.
- Loads of API improvements.
Bug fixes and improvements
- Tilemap.GetTilePosition returns correct values for isometric tiles.
- tk2dSpriteAnimationClip copy constructor.
- Fixed ToggleButtonGroup OnChange order - now called after state is changed.
- Tk2dExternal.Skin.Done is now static - could run into issues before.
- tk2dUiManager.OnMouseWheelChange -> OnScrollWheelChange to stop Unity warning during iOS build because function name starts with OnMouse.
- textInput.SetFocos / IsFocus
- Sprite handles disable themselves when using vertex snap mode in Unity
- Selecting an animation clip will now select the first frame group
- tk2dSpriteAnimation - added "View Data" context menu, to allow viewing data without switching to debug mode.
- Animation editor - warn when invalid clip is detected, non destructive, but can attempt "fix" if requested
- tk2dTextMesh.GetMeshDimensionsForString re-instated
- tk2dStaticSpriteBatcher.UpdateMatrices for legacy support
- Clipped sprite bounds corrected, now will work correctly on trimmed sprites.
- Sprite collection polygon collider defaults to front & back collider faces. Was causing a lot of confusion.
- Creating a sprite will now automatically inherit the layer of the parent.
- Sprite collection names sorted "naturally"
- Removed skin assets - the skin is now stored externally in a DLL. Less files in the project, and less likely to break.
- Sliced sprite legacy mode removed - automatic upgrade should work almost 100% of the time.
- tk2dUIMask in favour of other masking methods - this is extremely efficient.
- Default ortho size in sprite collection is now 10, works better with default Unity physics settings.
- Textmesh data moved to external serializable class. Shouldn't require any changes from user code.
- Got rid of "Always pixel perfect". Its always more efficient to update the camera to compensate for resolution changes.
- You can convert between sprite types in the component settings menu - also add or remove animators to a sprite.
- Moved non-core systems into own directory structures - tk2dUI, and tk2dTileMap.
- Lots more little bugfixes - please let me know if a bug you've reported isn't fixed.
-
Awesome!!!
Not sure if it's something I did wrong or if it was intentionally left this way, but the tk2dTileMap_demo folder is empty after I imported the Unity Package?
-
Something I'd noticed on the pre-release and forgot to comment: the clips listed on tk2dSpriteAnimator are sorted on whatever order they were created, but for large libraries it would be useful to have them sorted by name. While this is something we can change on the editor class ourselves, it'd be ideal if the next release has it already to avoid having to do manual merges.
Thanks!
-
Nice! So, the anchoring system goes to 2.1, right? We are waiting for that before updating our current project.
-
Awesome!!!
Not sure if it's something I did wrong or if it was intentionally left this way, but the tk2dTileMap_demo folder is empty after I imported the Unity Package?
That is empty - by some mistake I included it in the build. 2.1 will have a new tilemap demo and its meant for that.
Also we're trying to keep all the subprojects separate so someone who doesn't need them can delete the ones they don't want.
-
Something I'd noticed on the pre-release and forgot to comment: the clips listed on tk2dSpriteAnimator are sorted on whatever order they were created, but for large libraries it would be useful to have them sorted by name. While this is something we can change on the editor class ourselves, it'd be ideal if the next release has it already to avoid having to do manual merges.
Thanks!
Apologies, this should have been done a long time ago. I think I botched it during the merge :( I've re-added and will be in the next release. If you fancy adding it to yours drop an email to support and I'll give you the file to replace.
-
Nice! So, the anchoring system goes to 2.1, right? We are waiting for that before updating our current project.
I believe so unless something crops up.
-
Nice! So, the anchoring system goes to 2.1, right? We are waiting for that before updating our current project.
I believe so unless something crops up.
Good to hear that :)
-
Fantastic!!! Hooray for V2 :)
-
P.S. not to mention: thanks a lot for releasing V2 for free for existing users. That is truly awesome :)
-
Unity crushed immediately after double clicking .unitypackage, it shows decompressing package for a second and then crushed.
In fact, that's not the only time it happened, unity seems to like to randomly crush with pakcage import, I have suffer this for quite a bit. Truly annoying for this aspect of unity
-
Unity crushed immediately after double clicking .unitypackage, it shows decompressing package for a second and then crushed.
In fact, that's not the only time it happened, unity seems to like to randomly crush with pakcage import, I have suffer this for quite a bit. Truly annoying for this aspect of unity
You should update every asset via "Assets > Import Package...", otherwise it tends to crash.
-
You should update every asset via "Assets > Import Package...", otherwise it tends to crash.
No use. Crush as always...
-
Try importing into a new project. The download could've failed?
-
I get a bunch of errors in newly created project when trying to add tk2dSprite script to an existing empty Game Object. Unity 4.1.3. Could you please test it?
-
Are you using Create > tk2d > Sprite, or creating an empty gameobject, and then adding a component?
Edit: I've found the issue - only happened when adding a sprite component to an empty gameobject. Fixed and reposted 2.0 with this fix in. It was small enough that it didn't warrant being its own release. Redownload the unitypackage and import, and it should fix the issue.
-
Nice! Hey I wonder, is the memory management/ manual atlas unloading still a work in progress?
-
There is a tk2dSpriteCollectionData.UnloadTextures you can use... YMMV with this though.
-
Hi, thanks for fast fix! Now it works perfect.
One more issue with the last package - I got this error on import of tk2d into empty project with the only default Main Camera object:
> PPtr cast failed when dereferencing! Casting from Shader to Camera!
> UnityEditor.AssetPreviewUpdater:CreatePreviewForAsset(Object, Object[], String)
-
I can't say I've ever seen that error.
Could be something to do with the package import stuff in Unity, I've had it do some pretty dodgy things :(
I take it it only happens once and then stops?
-
Thanks so much for the quick turn around from purchase to download access, much appreciated!
-
FYI, I had the same error (PPtr cast failed...) and it did in fact only happen once.
-
I tried to import the package several times - every time I see this error only once. It seems that all other things is ok after that, but I`m not sure.
-
I got one more error.
I`ve just added a tk2dSprite (manually, as a component) on an empty Game Object. And I got this one:
> Destroying assets is not permitted to avoid data loss.
> If you really want to remove an asset use DestroyImmediate (theObject, true);
> UnityEngine.Object:DestroyImmediate(Object)
> tk2dSpriteFromTexture:DestroyInternal() (at Assets/TK2DROOT/tk2d/Code/Sprites/tk2dSpriteFromTexture.cs:92)
> tk2dSpriteFromTexture:Create(tk2dSpriteCollectionSize, Texture, Anchor) (at Assets/TK2DROOT/tk2d/Code/Sprites/tk2dSpriteFromTexture.cs:47)
> tk2dSpriteFromTexture:Awake() (at Assets/TK2DROOT/tk2d/Code/Sprites/tk2dSpriteFromTexture.cs:28)
I`ve removed the sprite, but the error message is still there.
There are two scenes in the project, I`m switching between them and get the message every time I`m in the scene with that sprite (or where that sprite was before I deleted it).
Could you please look into this also?
-
One remark. I see that the error itself relates to tk2dSpriteFromTexture (I have a separate backgrounds as a tk2dSpriteFromTexture in each scene). But it started to appear when I added empty Game Object and tk2dSprite on it. All was alright with tk2dSpriteFromTexture components before, there was no any errors. Hope it could help.
-
Do you have exact steps to reproduce it? It looks very much like your SpriteFromTexture object isn't set up correctly, and has a link to an asset. If you saved the scene after it complained, it should fix it.
We normally just use the GameObject > Create Other > tk2d > Sprite to create a sprite. Any particular reason you prefer to add components instead?
-
I just recreated objects with tk2dSpriteFromTexture and all seems to be ok now. Perhaps it was related to previous reimport of the package or something like this.
> We normally just use the GameObject > Create Other > tk2d > Sprite to create a sprite. Any particular reason you prefer to add components instead?
It`s quite useful when prototyping. At some point I can have a Game Object with some other scripts and don`t want to recreate it from scratch or create a separate child for Sprite.
Anyway it should work this way I think :) As it was in 1.xx
I`m starting a project from scratch and was worried a little as I never saw any errors from 1.xx . But I definitely want to start with 2.00 at least just not to have migration issues in future, when the project will be much bigger. And of course as it have some new great features.
Btw, great product, great support. Good luck in development!
-
Fair enough. Just wanted to know what that's all :)
I suggest creating a thread in the support forum if you find any bugs relating to this so it doesn't get lost in the mix. Its not how we use it here, but just report anything you find and we'll fix it :)
-
I saw someone mentioning the same earlier in this thread, but didn't catch a solution.
After importing, I have these empty folders
tk2dTileMap
tk2dTileMap \ Code
tk2dTileMap \ Editor
tk2dTileMap_demo
Is there a problem with the package?
And also - I like the fact that subsystems are now separated - can I delete the TileMap and UI folders, if I am not using them?
-
tk2dTileMap is empty? The usual reason for that is Unity doesn't move files which already exist in your project.
The demo folder is sadly empty, as the tilemap project hasn't been merged yet :)
Yup, the reason behind separating these out is to make it easier to delete if you're not using em.
-
Oh, that makes sense now.
Yes - tk2dTileMap is empty.
I am guessing that the equivalent in 1.9x folder structure is tk2d \ Editor \ TileMap and tk2d \ Code \ TileMap right?
So I can delete those, and re-import, and have the new 2.0 folder structure. Correct? (or delete them altogether, without re-importing, if not using them).
-
Yup.
-
Ok, done and working.
Just know that the (now integrated-) integrity checker complains about the missing TileMap files. So if the new approach is to allow deleting subsystems, maybe the integrity checker should take that into account.
-
Looking forward to the big Tilemap update in 2.1! Keep up the great work.
-
Wonderful! I updated Goscurry (http://www.goscurry.com/) (my current game) to V2, and it works perfectly. As soon as I updated I got a "PPtr cast failed when dereferencing!" message. But then I closed and restarted Unity, as the upgrade instructions told to, and everything worked great :)
-
@Izitmee - I moved the discussion out of here.
http://unikronsoftware.com/2dtoolkit/forum/index.php/topic,1898.msg9346.html#new