- 最后登录
- 2015-4-28
- 注册时间
- 2014-1-7
- 阅读权限
- 20
- 积分
- 169
- 纳金币
- 78
- 精华
- 0
|
Upgrade Guide
◾Behavior of masking has changed. By default graphics have masking disabled. To enable it you can set the 'maskable' property to true via script or via the debug inspector. The default editor currently does not expose the property.
Improvements
◾Core: Add GetComponents<List<T>> Will fetch components of type T and grow the list as needed.
◾Core: Add StopCoroutine(Coroutine) function
◾Core: Add callback 'OnTransformParentChanged' to MonoBehaviour. Called whenever a transform, or one of it's parent transforms has been reparented
Known Issues◾Input field caret lags behind by 1 character.
◾Multicanvas support is broken.
The following are changes and fixes to 4.6 features and regressions...
Changes
◾uGUI: Auto layout options for an element are now specified by adding a LayoutElement component on that element rather than setting them in the parent layout group. All children of a transform are now automatically included in a layout group on that transform and their order in the layout are determined by the child order in the Hierarchy.
◾uGUI: FreeformLayoutGroup has been removed since it doesn't fit into the design we're moving towards with the layout system. It was mostly useful together with Text components with the ResizeBounds options, but we're going to remove that option down the line. Instead, the new ContentSizeFitter component will do that job.
◾uGUI: The FitHorizontal and FitVertical properties on the layout groups have been removed. A new ContentSizeFitter has been added which can be used instead, and which has the advantage of also being able to be used directly on the same GameObject as e.g. an Image or Text component.
◾Editor: RectTransform.drivenByObject has been removed from the API since it was too easy to make mistakes where RectTransforms would get stuck as driven. Instead components that should drive RectTransforms should use the new DrivenRectTransformTracker struct.
◾uGUI: Remove tween classes from public API, since the long term plan is to move to using animation for everything.
◾uGUI: Rename Graphics DoColorTween and DoAlphaTween to CrossFadeColor and CrossFadeAlpha.
◾uGUI: EventSystem.IsPointerOverEventSystem(pointerId) will tell you if a pointer is over some object controlled by the event system
Improvements
◾Editor: Concept of driven RectTransform properties has been implemented. When setting a RectTransform to be driven, a mask is specified that controls which properties are driven. Driven properties are controlled by script and can't be set manually in the Inspector. They also always serialize as zero, to avoid merge conflicts. The drivenProperties are specified through the DrivenRectTransformTracker. The driven mask values for PositionZ, Rotation, and Scale are not yet fully implemented in beta 9.
◾uGUI: Auto-Layout system now no longer does its calculations every frame but instead when it's needed due to changes in components that affect the layout.
◾uGUI: Text Improvements:
◾ Add horizontal and vertical overflow modes to Text
◾ 'Best Fit' with Min / Max size
◾uGUI: Add callback Canvas.willRenderCanvases. This is called just before Canvas rendering
◾uGUI: Add GetMaterial() to UIRenderer
◾uGUI: Deferred Graphic updates: Graphics are now updated just before rendering instead of being updated as properties change, this means that vertices ect will only be updated once per frame. You can mark a Graphic as dirty by calling SetDirty() or Canvas.MarkGraphicForRebuild(Graphic graphic). Note: In a future release Canvas.MarkGraphicForRebuild(Graphic graphic) will be refactored to take an interface so custom components will work with is also.
◾uGUI: Performance improvements (moved performance sensitve code into C++)
◾uGUI: Greatly improve memory usage (remove many GC allocations)
◾uGUI: The Slider component now drives the anchors of the handle RectTransform.
◾uGUI: The ContentSizeFitter component drives the width and/or height of a RectTransform as well as anchorMax to ensure it's the same as anchorMin.
◾uGUI: Make UI objects created from menu have default localScale and localRotation.
◾uGUI: EventSystem now send enter and exit events even it the mouse isnt moving as items behind could be moving
◾uGUI: Canvas will now distance sort properly in world
◾uGUI: SpriteSwap transitions no longer ask for a Normal Image. It will use the Source Image from the Image Component.
Fixes◾uGUI: Update the canvas rect transform when a property is changed on the canvas.
◾uGUI: World Canvas's now render in a more correct order with everything else.
◾uGUI: Screen space canvas's will now only be drawn once.
◾uGUI: Fix bug with batch ordering (many less batches generated now)
◾uGUI: Clear animation state on buttons before retriggering. Stops buttons getting stuck in highlighted state
◾uGUI: Auto layout components no longer cause the scene to be dirtied.
◾uGUI: Fix sometimes not being able to select the first Graphics of a Canvas
◾UnityEvents: Fix minor bugs with UnityEvent Property Drawer
◾Editor: Don't show sibling anchors for RectTransform siblings that are not activeInHierarchy.
◾Editor: Immediately update any Canvas when changing the Game View resolution/aspect-ratio.
◾Editor: Immediately update any Canvas when making the Game View visible in-case it was resized whilst invisible.
◾Core: Fix precision errors in Camera.ScreenPointToRay that could cause jittery movement when dragging handles in the Scene View.
|
|