当前位置:网站首页>Unity布料系統_Cloth組件(包含動態調用相關)
Unity布料系統_Cloth組件(包含動態調用相關)
2022-06-26 21:59:00 【suixinger_lmh】
Unity布料系統
說明:
unity自帶的布料物理系統
使用:
- 新建空物體;
- 添加cloth組件,unity會自動附帶skinned mesh renderer組件;
- 將需要的網格和材質,賦值給skinned mesh renderer組件;
- 點擊cloth組件的左上角的圖標(Edit cloth constraints);
- scene面板中會出現布料參數調節面板(看不到的打開Gizmos,顯示場景圖標);
- 在模型上選中對應頂點(頂點過大或過小的話,調節Constraint Size的大小到合適的值);
- 根據需求對選中的點進行限制(例如:連接旗杆的那條邊一般不會動,勾選Max Distance 值設置為0;讓其不能移動);
要點:
1.布料系統目前只能和Capsule Collider 以及Sphere Collider 兩種碰撞體交互;
2.要將參與布料物理系統的物體的碰撞體拖入cloth組件的碰撞體組中;
動態調用相關:
問題:
看布料的使用方式基本上就是不建議動態去使用,但其實動態去使用也是可行的。
不過動態調用存在很多問題:
- 動態的給cloth組件添加碰撞體,雖然可以一直添加,但是超過一定數量時,多餘的碰撞體並不能够產生物理效果。
- 在布料系統發生物理效果時,如果去改變(删除)碰撞體個數,物理效果會產生突變。在暫時無交互時改變是可行的。
- 添加到布料系統中的碰撞體,即使將物體隱藏掉,enable=false掉,依舊會產生物理效果,甚至於使用position=newpos來改變碰撞體的比特置,newpos和當前路徑之間經過布料系統,依舊能够發生物理效果。
第三條的效果有些類似於character controller與剛體的一些特性,但布料貌似是將所有數據都放在布料系統裏計算了。
這就很坑,要解决第三條,就要把碰撞體從cloth中移除,要移除,就會碰到第二條的問題,需要保證cloth沒有在交互中。
因為是直接使用的,等回頭看看官方文檔再做修改。
边栏推荐
- How to analyze financial expenses
- Is there any risk in opening a new bond registration account? Is it safe?
- MATLAB and MySQL database connection and data exchange (based on ODBC)
- [mathematical modeling] spanning tree based on Matlab GUI random nodes [including Matlab source code 1919]
- Leetcode (452) - detonate the balloon with the minimum number of arrows
- random_ normal_ Initializer uses
- Which platform is the safest for buying stocks and opening accounts? Ask for sharing
- 卷积神经网络(CNN)详解及TensorFlow2代码实现
- Unity 设置Material、Shader的方法
- Shiniman household sprint A shares: annual revenue of nearly 1.2 billion red star Macalline and incredibly home are shareholders
猜你喜欢

In 2022, where will the medium and light-weight games go?

The importance of using fonts correctly in DataWindow

Chapter 2 construction of self defined corpus

Introduction of classic wide & deep model and implementation of tensorflow 2 code

LabVIEW Arduino tcp/ip remote smart home system (project part-5)

leetcode:6103. 从树中删除边的最小分数【dfs + 联通分量 + 子图的值记录】

Data governance does everything

leetcode:141. 环形链表【哈希表 + 快慢指针】

Web crawler 2: crawl the user ID and home page address of Netease cloud music reviews
![leetcode:1567. Length of the longest subarray whose product is a positive number [dp[i] indicates the maximum length ending with I]](/img/a4/c5c31de7a0a3b34a188bfec0b5d184.png)
leetcode:1567. Length of the longest subarray whose product is a positive number [dp[i] indicates the maximum length ending with I]
随机推荐
Is this a bug? Whether the randomly filled letters can be closed
Word chess based on heuristic search
CVPR 2022 - Interpretation of selected papers of meituan technical team
Unity3D插件 AnyPortrait 2D骨骼動畫制作
指南针能开户炒股吗?安全吗?
Data governance does everything
Which platform is the safest for buying stocks and opening accounts? Ask for sharing
Implementation of collaborative filtering evolution version neuralcf and tensorflow2
Unity3D插件 AnyPortrait 2D骨骼动画制作
Web crawler 2: crawl the user ID and home page address of Netease cloud music reviews
Vulnhub's dc9
Solution of valuenotifier < list < t > > monitoring problem in fluent
Listing of maolaiguang discipline on the Innovation Board: it is planned to raise 400million yuan. Fanyi and fanhao brothers are the actual controllers
Release of dolphin scheduler video tutorial in Shangsi Valley
打新债注册开户有没有什么风险?安全吗?
360 mobile assistant is the first to access the app signature service system to help distribute privacy and security
leetcode:141. Circular linked list [hash table + speed pointer]
leetcode:1567. Length of the longest subarray whose product is a positive number [dp[i] indicates the maximum length ending with I]
[solution] sword finger offer 15 Number of 1 in binary (C language)
花店橱窗布置【动态规划】