求大佬指點!
playerNew.Difficulty =(DifficultyType)Enum.Parse(typeof(DifficultyType), difficultyPopolist.value);
這句代碼我是放在update里面執行的,這里的playNew.Difficulty是一個我定義的難度陣列,difficultyPopolist是我做的一個難度選項,但是每次運行就會報value不能為空的錯,我用的是NgUi的popolist
轉載請註明出處,本文鏈接:https://www.uj5u.com/qita/22253.html
標籤:Unity3D
