[Unity]彈跳物件。
這一次,我想反彈物件。
準備一個立方體,並套用紅色材質,如下圖所示。








在準備好的立方體上加入元件:物理 > 剛體。


然後在專案中按一下滑鼠右鍵,選擇建立 > 物理材質。

這次我們將物理材質命名為「bound」。
接下來,選取這個邊界,將檢查器的’Bounciness’設定為 1。1 似乎是最大值。


彈跳度」設定完成後,選取紅色立方體,將束縛拖曳到 Inspector 中,就會套用如下。

現在當您按下播放時,紅色立方體會向下掉落,並在碰到地面時彈起。