0: Hi guys today we gonna look how we can use the c value to песили generate the same level again again ли v the sen generates рандом мэйс эт the moment, криэйт зе дифферент мейс эври тайм.
1: Ok, lets go to the maze, дженерейтор скрипт ту c, how we can generate the same мейс эген.
2: We can see the algorithm ю юнити с random класс ту рандоми generate the maze by default this we gave different резортс everytime, but we can change this Пейве зе рэндом класс хэз э метод куд ин ит стэйт эллас ту сет ту c value.
3: Forgiven сид валью зе рандом класс wheel лес. Generate the same сиквенс вальюс гивин зе сейм энд резолт лет с серайз филд фо зе сид валью.
4: Ten in the stop Месед вилсет зис валю юзинг зе рандом ИНН и state Месед.
5: Ok lets save the in switch покинит Трайт аут.
6: We'll select the мей generate object in хараки энд сет зе сит валюту Ван лет пресс плей ту трай зис аут.
7: No every time we start the game we get the same мэйс.
8: If we change the sea to to impress play we get to different мейс.
9: So we had кип тайпинг ин дифферент сит вэльюс энд ту ви файнд зе мэйс ви лайк, эназер Вэй ви би ту randomly, generate the mess and and the seat велью юз соу ви кэн криэйтед эген иф ви вонт ту you probably see this in games like minecraft.
10: Random generator б you can get the seed value to regenerative exactly script to see how we anti ю г. The seed value out to the random, we have to do it the different way.
11: The same word again, if you want lets switch back to the can do this класс saw.
12: Random generator б you can get the seed value. To regenerative exactly the same word again. If you want lets switch back to the script to see how we can do this anti ю г. The seed value out to the random класс? Saw we have to do it the different way.
13: Wav серилайзер энд валью ту вин зе кейт в we want to use the seat.
14: Ten in the stop Месед, вуд чек и the six 3 for lying that си вали.
15: If it's not true, в creating ю вендом сид.
16: Va random number between one and эмилион?
17: Thea the random класс виз зе сит
18: We lock the c value to the console соу ви кэн ю ит эген.
19: Ok lets save this in switch потюните Трайт аут ви live to u c, false, false, and press play.
20: Now we have a different рандом mess, but if we look in the console ви хэв зе сит нид ит ту generate again lets stop the game into the seat валью.
21: Демо тект, юси, чекбокс, эмпресс, плай
22: Now we get the same мэйз эген соу нау ви кэн generate random levels, but have the ability to play the same on again, if we want okay cause everything for this видео, how you find that if БИК пейтен, ви рили, прише ю хэлп ин зе сббол, за chanel иф ю.