Unity Random is an ambiguous error - how to fix

preview_player
Показать описание
Unity Random is ambiguous error show when we have imported System library together with UnityEngine library. Both have Random namespace in them.

Type: 𝘂𝘀𝗶𝗻𝗴 𝗥𝗮𝗻𝗱𝗼𝗺 = 𝗨𝗻𝗶𝘁𝘆𝗘𝗻𝗴𝗶𝗻𝗲.𝗥𝗮𝗻𝗱𝗼𝗺;
at the top of your script. It will let the compiler know which library you want to use in this script👍😉

#unitytips #gamedev #csharp #unity2d #shorts
Рекомендации по теме
Комментарии
Автор

Very helpful, I had that issue the other day. Thanks!

carlsmith
Автор

It can also press down Alt+Enter to show a drop down in VS or Rider, and add 'using Random' faster.

XiaoTN
Автор

muchas gracias me solucionaste el problema

SebastianGT.
welcome to shbcf.ru