![](https://img-blog.csdnimg.cn/20201014180756913.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
前端
技術性裝怪
这个作者很懒,什么都没留下…
展开
-
Unity cinmachine 重置位置
虚拟摄像机freelookA,freelookB当A根据目标位置发生移动,切换到B,再由B切换回A时,摄像机朝向为切换到B时的朝向,如果需要复原摄像机位置,需要:1.将binding mode改为LockToTargetWithWorldUp2.freeLookCam.PreviousStateIsValid = false;freeLookCam.m_XAxis.Value = 0;freeLookCam.m_YAxis.Value = 0.7f;...原创 2020-09-05 14:58:20 · 1100 阅读 · 0 评论 -
Cinemachinefreelook 按住鼠标后拖动鼠标改变视角方法
if (Input.GetMouseButtonDown(0)) { freeLookCam.m_YAxis.m_MaxSpeed = 2; freeLookCam.m_XAxis.m_MaxSpeed = 300; } if (Input.GetMouseButtonUp(0)) { freeLookCam.m_YAxis.m_MaxSpeed = 0; ...原创 2020-08-25 16:28:29 · 1961 阅读 · 1 评论 -
ContentSizeFitter嵌套使用时需要强制刷新
ContentSizeFitter嵌套使用时需要强制刷新,否则ContentSizeFitter会因为刷新不及时导致高度为0foreach (ContentSizeFitter child in LevelUpNeedOne.GetComponentsInChildren<ContentSizeFitter>(true)) { LayoutRebuilder.ForceRebuildLayoutImmediate(child.Ge...原创 2020-07-08 16:18:50 · 2324 阅读 · 0 评论 -
nginx跨域问题简单配置
nginx跨域在nginx.conf中http中添加server { listen 80;#nginx端口 location / { root html; index index.html index.htm; add_header 'Access-Control-Allow-Origin' '...原创 2020-03-24 16:22:01 · 146 阅读 · 0 评论