2D Toolkit Forum
2D Toolkit => Releases => Topic started by: unikronsoftware on July 19, 2013, 10:41:18 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.10/migration_guide.html
Documentation available at:
http://unikronsoftware.com/2dtoolkit/docs/2.10
What's new
- Documentation has been updated for 2.1 and the first part of the whack-a-mole tutorial has now been published.
- UI Item sendmessage call wrapped - you can now select methods from a dropdown instead of typing them out. A default parameter is also sent.
- Tilemap demo added.
- Attach point demo added.
- Tilemap editor - Flipped tile support.
- Tilemap editor - Unlimited scratchpad to store templates / custom tile layouts.
- Tilemap editor - Tile paint mode massively improved with new UI, vertex color paint supports individual channels.
- Tilemap editor - Instanced prefabs are saved. You can change properties on them and they will be remembered.
- Tilemap editor - Physics material can be set up per tilemap layer.
- Attach points - You can now set up attach points directly on the sprites. You can attach other sprites to these attach points, or simply use them as markers in your code. When set up on a frames of animation, these will be animated together with the frames.
- Sprite collection builder - duplicate textures are now removed, textures are compared by a contents hash.
- Sprite collection global texture rescale.
- tk2dCamera v3 - now much better than before. Preview of native resolution, preview resolution in viewport.
- tk2dCamera v3 - Uses game view resolution/aspectratio as "preview resolution" when present, no need to enter resolutions twice.
- tk2dCamera v3 - Zoom Factor (replacing zoom scale), works with or without overrides
- tk2dCamera v3 - Size set up as "ortho size" or "pixels per meter". Default legacy size, Pixels per meter = 1
- tk2dCamera v3 - Works on perspective camera as well, allowing for 1:1 to be exact at any resolution
- tk2dCamera v3 - hides the Unity camera implemnentation to avoid confusion
- tk2dCamera v3 - supports multiple cameras with different sizes in scene, uses unity layers to VERY quickly detect the right camera for a sprite / object.
- tk2dCamera v3 - Override UI revamped.
- tk2dCameraAnchor - Works with any camera type, including perspective.
- Sprite collection / font editor - will automatically detect camera settings if a tk2dCamera is found in the scene, less room for error. Set up exactly the same as a tk2dCamera.
- Static sprite batcher - option to sort by camera, allows correct sorting when not viewed straight along z axis.
- PlayMaker actions included - unpack from tk2d/Goodies/PlayMaker Actions
Bug fixes and improvements
- Tilemap editor - more undo fixes. Should've got everything now. When entering edit mode, chunk gameobjects are created for all chunks. This is not a bug, and required for undo to work properly. Unnecessary ones are deleted when committed.
- Tilemap editor - vertical scroll wheel works when mouse is over tilemap palette.
- Tilemap editor - Creation stage made far more sensible, and replaced sprite collection picker.
- tk2dCamera - default far clip plane = 50.
- tk2d update checker window - warn when in webplayer.
- Sprite collection editor - copy geometry islands correctly.
- Removed beta tag from tilemap editor.
- Word wrap correctly considers spacing.
- Convert to ui sprite animator moved to UI code, dependency in core tk2d removed.
- Tilemap colliders built properly, even if not committed.
- Tilemap editor - fixed a lot of cases where modified prefab data could be lost.
- Tilemap editor - fixed undo which failed in some situations leaving orphaned chunks of data.
- Tilemap editor - Prefabs can be spawned at runtime using SetTile.
- tk2dCamera - removed half pixel offset from camera anchors on Windows/D3D.
- tk2dCamera - Patched for missing screenResolution / ScreenOffset functions, marked as Obsolete.
- tk2dCamera - Fixed rogue memory allocation at runtime.
- Packed fonts fixed.
- Text mesh inline styling bugfix when used from code.
- Sprite selector bugfix.
- UI scrollablearea fixed to work the same regardless of resolution.
- UI scrollablearea - OnScroll is now triggered when expected.
- UI scrollablearea - MeasureContentLength, for when you just want to fit the content you've dynamically created at runtime.
- Diced texture parameters are shown in the editor - easier to make decisions on dice size.
- Font - cope with invalid characters.
- Tilemap - bugfix with color interpolation at boundaries.
- Sprites - Scene widget works at any axis.
- UI demo - old sans font replaced.
- And many many more bugfixes - Let us know if a bug you reported isn't fixed.
-
Scrollable palette, woo-hoo!! As always, thanks much for the updates.
-
Great :)
-
@fsadeq - can you help try to break the tilemap editor in the ways you could before, please? That is the last thing I'm still testing before releasing the final version.
-
Yup, no prob.
-
I can't seem to break the prefab values being saved thing..which is great! Also haven't replicated the extra chunks bug either. Seems solid to me, except for one tiny thing:
For whatever reason, my (H) and (J) keyboard shortcuts in the tilemap don't work. They're supposed to flip the tiles, but they seem to only work some of the time (and that's after manually clicking the icons in the toolbar).
-
Thanks a lot. Been waiting for that tutorial :D
One small suggestion. Please put all the game downloadable files, graphics + code in one zip file on the first page of the tutorial, so we don't have to hunt for links in tutorial pages.
I will soon be following the tutorial to make this "Hello World!" game :D
Thanks,
// chall3ng3r //
-
@chall3ng3r - initially thought of doing that, but we're going to be updating the code as the tutorial progresses, so the code you get on a particular page is relevant to that page mostly. What I'm thinking of doing is though, at the end of each part, to have a zipped Unity project containing the final result. It'll help as reference in case you made a mistake following the tutorials. Maybe we can have a "downloads" section for each page - that could help in some way.
-
Hi, when will the 2d toolkit UI support playmaker?
-
Hi, when will the 2d toolkit UI support playmaker?
I've added a couple boxes to the roadmap trello for more Playmaker support. Please vote on them, and they will be picked up for the next release if there is enough interest.
https://trello.com/b/UfqlXqXy/2d-toolkit-roadmap
-
I can't seem to break the prefab values being saved thing..which is great! Also haven't replicated the extra chunks bug either. Seems solid to me, except for one tiny thing:
For whatever reason, my (H) and (J) keyboard shortcuts in the tilemap don't work. They're supposed to flip the tiles, but they seem to only work some of the time (and that's after manually clicking the icons in the toolbar).
I've actually managed to have the prefab instances lose their values again. Problem is, I have no idea how I did it. Could have been any number of steps before I committed the tilemap. :(
-
I'll look through the code once more. There are VERY few places this could possibly happen now, and I can test each path to make sure. I was concentrating on all the undo stuff in the last release.
-
I can't seem to enable Viewport Clipping no matter what I do. Also the tk2dcamera resets things like Depth and Inherit settings if I try to change the clear flags.
-
Can you post in the private support forum with a bit more details about that, please? I'm going through the last few bugs in 2.1 and I'd like to sort this out ASAP if possible.
-
When I edit "Pixels Per Meter" or "Zoom factor" on the tk2dCamera, the clipping frame displayed in the scene view automatically adjusts its width... but not its height.
Also, it looks like "Origin: Center" actually sets the origin to bottom-center.
-
Is it because you have an override? What are your native and preview resolutions?
-
Yes,
at the end of tutorial full download of project would be great!
Thanks,
// chall3ng3r //
-
No, I'm just an idiot. ;D I was viewing the wrong axis pair (XZ instead of XY) and the clipping plane depth lines on Z happened to match an approximate 16x9 ratio against width lines on X.
-
I just upgraded one of my games to use the latest 2d Toolkit.
I was using:
int cameraPosX= (int)_gameCamera2d.ScaledResolution.x;
int cameraPosY= (int)_gameCamera2d.ScaledResolution.y;
And now get:
error CS1061: Type `tk2dCamera' does not contain a definition for `ScaledResolution' and no extension method `ScaledResolution' of type `tk2dCamera' could be found (are you missing a using directive or an assembly reference?)
What's the equivalent in this release? I checked the upgrade guide but didn't see it mentioned.
Thanks,
Cliff
-
I missed that in scaled resolution :( I'll add that back in the next release marked as obsolete. Wasn't intentionally removed.
ScreenExtents & NativeScreenExtents are the ones you want now - theyre rects, so use width & height
-
I missed that in scaled resolution :( I'll add that back in the next release marked as obsolete. Wasn't intentionally removed.
ScreenExtents & NativeScreenExtents are the ones you want now - theyre rects, so use width & height
Cheers :)
-
2DT 2.1 final will be compatible with Unity 4.2, right?
-
I'm running it with 4.2 right now and it seems to be fine :)
-
Nice, thanks for the quick answer :)
-
Are the resolution overrides implemented different now ?
It doesn't work when I set resolution to match any height or width (-1).
From documentation:
int width
Screen width to match. Set to -1 to match any width.
int height
Screen height to match. Set to -1 to match any height.
-
@korn3l - that is incorrect in the docs, I've fixed it for the next release. The one you want is above it - matchBy
set that to MatchByType.Wildcard to detect any resolution.
-
What happens if I want to match only by width or only by height?
Is this feature dropped ?
-
Didn't see any use for it which couldn't be handled by wildcard + "Fit Height" / "Fit Width".
What do you use it for? I can put it back in easy enough.
-
I guess you are right. For my needs it works ok with wildcard and fit height.
I'm thinking that feature could be used for some specific overrides e.g. -1 x 480 "Fit Height" and 640 x -1 "Fit Visible"
You can't do that anymore I guess.
But I don't know if someone uses that anyway, so it works fine for now. Thanks for the reply.
-
Really enjoying this beta release. I haven't played with the UI or the TileMap till now and it blew me away. I didn't realise what you'd done but it looks great!
My only final request is when adding attachment points, we can choose position and rotation. Can we also choose a z offset? I.e. On some frames I want my attached object to be behind the sprite, while on others I'd like it in front. (I.e. simple layering).
Perhaps just a checkbox for 'Set behind' as I noticed that the existing z pos is -0.05, so just a toggle to set it to 0.05 ?
-
Following the Whack a Mole tutorial. Static Sprite Batcher seems to make the background not show up when running it on my windows phone. Works in the game view and web player or if I don't use the static sprite batcher.
-
I really enjoy the Anchor Point feature, but it would be nice if you could select to manual set rotation. For example if you have an arm that is attached to the body using the anchor points and you want to set the arm to point to the mouse cursor. In this case you would want the anchor point to change only the position and not the rotation.
-
I really enjoy the Anchor Point feature, but it would be nice if you could select to manual set rotation. For example if you have an arm that is attached to the body using the anchor points and you want to set the arm to point to the mouse cursor. In this case you would want the anchor point to change only the position and not the rotation.
Hi, we'll certainly update the behaviour in the future, but for now - feel free to create a copy and modify it. It is a really really simple class - tk2dSpriteAttachPoint, and you can easily add a bool to ignore rotation. The data is more or less guaranteed to not change, so you should be good making a copy and modifying this class.
-
Really enjoying this beta release. I haven't played with the UI or the TileMap till now and it blew me away. I didn't realise what you'd done but it looks great!
My only final request is when adding attachment points, we can choose position and rotation. Can we also choose a z offset? I.e. On some frames I want my attached object to be behind the sprite, while on others I'd like it in front. (I.e. simple layering).
Perhaps just a checkbox for 'Set behind' as I noticed that the existing z pos is -0.05, so just a toggle to set it to 0.05 ?
We want to get this right - we'll have a way of sorting things manually in a later release :) There may be a new feature in the next release to help with this.
-
I have been checking the tile map and everything seems pretty good. Grat Work!!.
Do you think It would be possible to select a single tile and have an offset, from its position. Right now the tiles are arranged exactly in the position it meant to be drawn but what happens if I would like to do something like: "Hey I would like to move this and only this tile 5 pixels to the left".
Do you think this could be possible.
Thanks :)
-
You can't do that - it will require storing a lot more information and increase the memory footprint quite a bit. You can position them as normal sprites though - that should just work
-
Having a tk2dCamera in a scene keeps marking the scene as dirty.
When the camera is NOT selected, commenting out everything in UpdateCameraMatrix stops making it dirty.
If the camera is selected, even with the code commented, it gets dirty. (But it doesn't get set dirty because of GUI.changed)
(BTW shouldn't the Update() call in UpdateCameraMatrix be in editor only?)
Thanks a lot!
-
This is far more messy than it should be for one reason - There is no way to detect if a camera is using a custom projection matrix or not. i.e. orthographic could be true, and a custom projection matrix could be set up to make it perspective, or even worse. I'll look into improving it in the next version.