# Problems with world generation

**URL:** <https://forum.makecode.com/t/problems-with-world-generation/5305>\
**Category:** Help\
**Created:** [January 2, 2021, 3:39am UTC](https://forum.makecode.com/t/problems-with-world-generation/5305 "2021-01-02T03:39:26Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![GameGod](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/gamegod/32/2756_2.png) [@GameGod](https://forum.makecode.com/u/GameGod)\
**Post date:** [January 2, 2021, 3:39am UTC](https://forum.makecode.com/t/problems-with-world-generation/5305/1 "2021-01-02T03:39:26Z")

</div>

> **[otherworldly](https://arcade.makecode.com/17408-10605-13382-25770)**
>
> Made with ❤️ in Microsoft MakeCode Arcade.

In the “game” (it’s not a game yet) above, you can easily walk to the right of the screen and it generates new terrain. But, if you walk to the left of the screen, it makes some weird canyon-like terrain. How can I fix this? The code to generate the left terrain is in the function, “`MakeLeftWorld`”.

(There is probably a small error in my code that I am missing)

---

<div class="post-metadata">

**Author:** ![DahbixLP](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/dahbixlp/32/4760_2.png) [@DahbixLP](https://forum.makecode.com/u/DahbixLP)\
**Post date:** [January 2, 2021, 3:51pm UTC](https://forum.makecode.com/t/problems-with-world-generation/5305/2 "2021-01-02T15:51:32Z")

</div>

Well I found out that the Left world function is longer! So maybe there is some extra blocks…! I will compare every block! that might take a while! But here is what I mean! (Does that extra block need to be there or is it not supposed to be there?) The end is kinda different! Maybe thats why?

![image](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/2X/7/7720e23d80181bd5d2fc469663d46c2a06e62957.png)  
 ![image](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/2X/3/393c4b285b3462c6d980d404e79ee8831fc2e05c.png)

---

<div class="post-metadata">

**Author:** ![GameGod](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/gamegod/32/2756_2.png) [@GameGod](https://forum.makecode.com/u/GameGod)\
**Post date:** [January 2, 2021, 5:12pm UTC](https://forum.makecode.com/t/problems-with-world-generation/5305/3 "2021-01-02T17:12:29Z")

</div>

> **[otherworldly](https://arcade.makecode.com/86232-24414-25488-55474)**
>
> Made with ❤️ in Microsoft MakeCode Arcade.

This link has all the comments describing each block.

 ![image](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/2X/3/338c023799d2ae5b03536175ba8b714e98e92a56.png)

---

<div class="post-metadata">

**Author:** ![DahbixLP](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/dahbixlp/32/4760_2.png) [@DahbixLP](https://forum.makecode.com/u/DahbixLP)\
**Post date:** [January 2, 2021, 5:12pm UTC](https://forum.makecode.com/t/problems-with-world-generation/5305/4 "2021-01-02T17:12:39Z")

</div>

Sooo I think I know the problem…  
The random land width! Bc with that it looks like this!  
 ![image](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/2X/6/6bf1f5173db8c19f41ed427838a45e6b2bba9df5.png)  
 ![image](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/2X/d/d834c888c52c8b3bcf1b939007498e936d849b24.png)  
But if I set it to e.g 3 it looks like this!  
 ![image](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/2X/d/df8b20bc2182f5e9bd2337684c4b41f86db1c8a3.png)  
 ![image](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/2X/5/51e75ec8df6ca7949631a9d4ae11f8d0d92d51ea.png)  
It looks way better bu the width is always the same and the end part is always empty…  
I changed the background image so that in the bottom there is a bit more bc there also is a gap! I tried to put the random number in a variable but it is just the same…

---

<div class="post-metadata">

**Author:** ![GameGod](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/gamegod/32/2756_2.png) [@GameGod](https://forum.makecode.com/u/GameGod)\
**Post date:** [January 2, 2021, 6:06pm UTC](https://forum.makecode.com/t/problems-with-world-generation/5305/5 "2021-01-02T18:06:57Z")

</div>

Thanks! I fixed it. Here is the link -

> **[otherworldly](https://arcade.makecode.com/51416-06624-94982-92983)**
>
> Made with ❤️ in Microsoft MakeCode Arcade.

What I did - I drew it like I would draw the right map, but then just flipped the image.

---

<div class="post-metadata">

**Author:** ![DahbixLP](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/dahbixlp/32/4760_2.png) [@DahbixLP](https://forum.makecode.com/u/DahbixLP)\
**Post date:** [January 2, 2021, 6:36pm UTC](https://forum.makecode.com/t/problems-with-world-generation/5305/6 "2021-01-02T18:36:52Z")

</div>

Nice! Should I do stuff like item sprites? Idk what you need but maybe pickaxes or something!

---

<div class="post-metadata">

**Author:** ![GameGod](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/gamegod/32/2756_2.png) [@GameGod](https://forum.makecode.com/u/GameGod)\
**Post date:** [January 2, 2021, 7:16pm UTC](https://forum.makecode.com/t/problems-with-world-generation/5305/7 "2021-01-02T19:16:15Z")

</div>

Yes, I am going to do that. First, I need to finish world generation (trees, stone, etc.)

---

<div class="post-metadata">

**Author:** ![GameGod](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/gamegod/32/2756_2.png) [@GameGod](https://forum.makecode.com/u/GameGod)\
**Post date:** [January 2, 2021, 7:59pm UTC](https://forum.makecode.com/t/problems-with-world-generation/5305/8 "2021-01-02T19:59:06Z")

</div>

> [@GameGod](#):
>
> trees

Speaking of trees,

> **[otherworldly](https://arcade.makecode.com/38795-20433-58855-24974)**
>
> Made with ❤️ in Microsoft MakeCode Arcade.

---

<div class="post-metadata">

**Author:** ![DahbixLP](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/dahbixlp/32/4760_2.png) [@DahbixLP](https://forum.makecode.com/u/DahbixLP)\
**Post date:** [January 2, 2021, 7:59pm UTC](https://forum.makecode.com/t/problems-with-world-generation/5305/9 "2021-01-02T19:59:15Z")

</div>

Here is some! (Just Ideas)  
Press A to make it bigger and again to make smaller! (Error if image is big and gets switched from 0 to 14 and 14 to 0)

> **[Otherworldly Sprite Art](https://arcade.makecode.com/24528-71829-04029-61143)**
>
> Made with ❤️ in Microsoft MakeCode Arcade.

---

<div class="post-metadata">

**Author:** ![DahbixLP](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/dahbixlp/32/4760_2.png) [@DahbixLP](https://forum.makecode.com/u/DahbixLP)\
**Post date:** [January 2, 2021, 8:13pm UTC](https://forum.makecode.com/t/problems-with-world-generation/5305/10 "2021-01-02T20:13:49Z")

</div>

You shoult make it so that if like 80% of the trunk is gone then the whole trunk goes away and when the trung is gone make the leaves disappear! (Not like in Minecraft where the leaves float around)

---

<div class="post-metadata">

**Author:** ![GameGod](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/gamegod/32/2756_2.png) [@GameGod](https://forum.makecode.com/u/GameGod)\
**Post date:** [January 2, 2021, 8:13pm UTC](https://forum.makecode.com/t/problems-with-world-generation/5305/11 "2021-01-02T20:13:55Z")

</div>

These are EPIC! Such great art! I’ll try to add as much of these as possible into the game.

Since you’ve already helped so much, do you want to collaborate on this?

---

<div class="post-metadata">

**Author:** ![DahbixLP](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/dahbixlp/32/4760_2.png) [@DahbixLP](https://forum.makecode.com/u/DahbixLP)\
**Post date:** [January 2, 2021, 8:13pm UTC](https://forum.makecode.com/t/problems-with-world-generation/5305/12 "2021-01-02T20:13:58Z")

</div>

That is great! Until now I did not even notice it saves the maps!

---

<div class="post-metadata">

**Author:** ![DahbixLP](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/dahbixlp/32/4760_2.png) [@DahbixLP](https://forum.makecode.com/u/DahbixLP)\
**Post date:** [January 2, 2021, 8:17pm UTC](https://forum.makecode.com/t/problems-with-world-generation/5305/13 "2021-01-02T20:17:34Z")

</div>

I would love to! I can make art and stuff! Animations, enemies, items, Tools and tips and suggestions! I am currently not working on anything too big so I would like to!

---

<div class="post-metadata">

**Author:** ![G30](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/g30/32/5516_2.png) [@G30](https://forum.makecode.com/u/G30)\
**Post date:** [January 3, 2021, 7:23am UTC](https://forum.makecode.com/t/problems-with-world-generation/5305/14 "2021-01-03T07:23:05Z")

</div>

i think i can help because i can code in npc’s and dialogue as well as world deletion. also i saw how your game works and you can only delete trees so i was hoping i could help add an objective also here is an example of my work [https://makecode.com/\_b06iaxhrycsj](https://makecode.com/_b06iaxhrycsj) , i’m not the best with sprites.

---

<div class="post-metadata">

**Author:** ![G30](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/g30/32/5516_2.png) [@G30](https://forum.makecode.com/u/G30)\
**Post date:** [January 3, 2021, 7:23am UTC](https://forum.makecode.com/t/problems-with-world-generation/5305/15 "2021-01-03T07:23:08Z")

</div>

ok so im here now game god,

---

<div class="post-metadata">

**Author:** ![GameGod](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/gamegod/32/2756_2.png) [@GameGod](https://forum.makecode.com/u/GameGod)\
**Post date:** [January 3, 2021, 4:31pm UTC](https://forum.makecode.com/t/problems-with-world-generation/5305/16 "2021-01-03T16:31:54Z")

</div>

Sure, you can help! Great game! I made a similar one a while ago:

> [@BugBots](https://forum.makecode.com/t/bugbots/3659/24):
>
> Now with durability autosave!

---

<div class="post-metadata">

**Author:** ![G30](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/g30/32/5516_2.png) [@G30](https://forum.makecode.com/u/G30)\
**Post date:** [January 3, 2021, 6:02pm UTC](https://forum.makecode.com/t/problems-with-world-generation/5305/17 "2021-01-03T18:02:36Z")

</div>

nice game and thanks for letting me help

---

<div class="post-metadata">

**Author:** ![DahbixLP](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/dahbixlp/32/4760_2.png) [@DahbixLP](https://forum.makecode.com/u/DahbixLP)\
**Post date:** [January 3, 2021, 6:16pm UTC](https://forum.makecode.com/t/problems-with-world-generation/5305/18 "2021-01-03T18:16:50Z")

</div>

Hi Gamegod! I was wondering what a crafting bench/oven… should look like!?  
Should they be 10 \* 10 or small like 5 \* 5?

---

<div class="post-metadata">

**Author:** ![GameGod](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/gamegod/32/2756_2.png) [@GameGod](https://forum.makecode.com/u/GameGod)\
**Post date:** [January 3, 2021, 6:23pm UTC](https://forum.makecode.com/t/problems-with-world-generation/5305/19 "2021-01-03T18:23:45Z")

</div>

> [@DahbixLP](#):
>
> 5 \* 5

This would be good!

---

<div class="post-metadata">

**Author:** ![omnisImperium](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/omnisimperium/32/2728_2.png) [@omnisImperium](https://forum.makecode.com/u/omnisImperium)\
**Post date:** [January 3, 2021, 9:59pm UTC](https://forum.makecode.com/t/problems-with-world-generation/5305/20 "2021-01-03T21:59:17Z")

</div>

Hey! If it is fine, can I join too? I can make concepts for characters and other art…

[Next page](https://forum.makecode.com/t/problems-with-world-generation/5305.md?page=2)
