<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	 xmlns:media="http://search.yahoo.com/mrss/" >

<channel>
	<title>Menus &#8211; AnonyViet &#8211; English Version</title>
	<atom:link href="https://en.anonyviet.com/tag/menus/feed/" rel="self" type="application/rss+xml" />
	<link>https://en.anonyviet.com</link>
	<description>The most popular website for sharing information technology, computer networks, and security knowledge. Stay up to date with the hottest news and tips</description>
	<lastBuildDate>Thu, 26 Jan 2023 18:17:43 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.0.1</generator>

<image>
	<url>https://en.anonyviet.com/wp-content/uploads/2023/01/cropped-ico-logo-75x75-1.png</url>
	<title>Menus &#8211; AnonyViet &#8211; English Version</title>
	<link>https://en.anonyviet.com</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>[Tạo 2D Platformer Game với Godot] Part 17: Creating Menus</title>
		<link>https://en.anonyviet.com/tao-2d-platformer-game-voi-godot-part-17-creating-menus/</link>
					<comments>https://en.anonyviet.com/tao-2d-platformer-game-voi-godot-part-17-creating-menus/#respond</comments>
		
		<dc:creator><![CDATA[AnonyViet]]></dc:creator>
		<pubDate>Thu, 26 Jan 2023 18:17:43 +0000</pubDate>
				<category><![CDATA[Tips]]></category>
		<category><![CDATA[creating]]></category>
		<category><![CDATA[Game]]></category>
		<category><![CDATA[Godot]]></category>
		<category><![CDATA[Menus]]></category>
		<category><![CDATA[Part]]></category>
		<category><![CDATA[Platformer]]></category>
		<category><![CDATA[tạo]]></category>
		<category><![CDATA[với]]></category>
		<guid isPermaLink="false">https://en.anonyviet.com/?p=4262</guid>

					<description><![CDATA[In this section, I will show you how to create a Game Menu for this Platformer game. In this part I will show you some new nodes of Godot&#8217;s UI. Join the channel Telegram of the AnonyViet 👉 Link 👈 Then the first thing is you create yourself a new scene with the Control Node [&#8230;]]]></description>
										<content:encoded><![CDATA[<p></p>
<div id="ftwp-postcontent">
<p>In this section, I will show you how to create a Game Menu for this Platformer game.  In this part I will show you some new nodes of Godot&#8217;s UI.</p>
<div class="code-block code-block-16" style="margin: 8px 0; clear: both;">
<div align="center">
<table class=" aligncenter" style="background-color: #c0c0c0; border-collapse: collapse; width: 59.9985%;">
<tbody>
<tr>
<td style="width: 100%; text-align: center;"><span style="font-size: 12pt;"><strong>Join the channel <span style="color: #0000ff;">Telegram</span> of the <span style="color: #008080;">AnonyViet </span> 👉 <span style="text-decoration: underline;"><a target="_blank" href="https://en.anonyviet.com/next-link?url=https%3A%2F%2Ft.me%2Fanonyvietchat" class="local-link" rel="noopener">Link</a></span>  👈</strong></span></td>
</tr>
</tbody>
</table>
</div>
</div>
<p><img fetchpriority="high" decoding="async" class="aligncenter wp-image-36996 size-full" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-27-01.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menus" width="441" height="170" srcset="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-27-01.png 441w, https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-27-01-300x116.png 300w" sizes="(max-width: 441px) 100vw, 441px" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 30 . Menu"/></p>
<p>Then the first thing is you create yourself a new scene with the Control Node as the root node and rename it to Menu.</p>
<p>And add a new node that is Vboxcontanier.</p>
<p><strong>VBoxContainer</strong>: this is the node that will create an area like a container and it will make the nodes inside it all arranged in vertical order.</p>
<p><strong>HBoxContainer: </strong>Hbox is the opposite of Vbox in that it is arranged horizontally.</p>
<p>If you notice, there are letters V and H at the beginning of the name, and this V &#8211; H is the name of the two horizontal and vertical axes in English.</p>
<p><img decoding="async" loading="lazy" class="size-full wp-image-36994 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-26-08.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 27 . Menu" width="153" height="551" srcset="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-26-08.png 153w, https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-26-08-83x300.png 83w" sizes="auto, (max-width: 153px) 100vw, 153px" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 31 . Menu"/></p>
<p>Then you select Layout at the bottom of the toolbar and select full rect<img decoding="async" loading="lazy" class="size-full wp-image-37003 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-42-43.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 28 . Menu" width="436" height="280" srcset="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-42-43.png 436w, https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-42-43-300x193.png 300w" sizes="auto, (max-width: 436px) 100vw, 436px" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 32 . Menu"/></p>
<p>After you select full rect it will look like this.</p>
<p><img decoding="async" loading="lazy" class="size-full wp-image-37004 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-43-25.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 29 . Menu" width="140" height="62" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 33 . Menu"/></p>
<p>I will rename it for easy identification.</p>
<p><img decoding="async" loading="lazy" class="size-full wp-image-37005 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-44-09.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 30 . Menu" width="308" height="156" srcset="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-44-09.png 308w, https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-44-09-300x152.png 300w" sizes="auto, (max-width: 308px) 100vw, 308px" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menu 34"/></p>
<p>And I added 2 more Vbox and renamed it 1 PhanDau and 1 PhanCuoi.</p>
<p>About the reason I added these 2 is because I want PhanDau to be the part I will add Text to VD like game name.vv.  As for PhanCuoi, I will add a button to click.</p>
<p><img decoding="async" loading="lazy" class="size-full wp-image-37006 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-45-58.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 31 . Menu" width="278" height="145" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 35 . Menu"/> <img decoding="async" loading="lazy" class="size-full wp-image-37007 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-46-08.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 32 . Menu" width="286" height="123" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menu 36"/></p>
<p>I will add 1 more node Hbox and rename it TieuDe.</p>
<p><img decoding="async" loading="lazy" class="size-full wp-image-37008 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-46-19.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 33 . Menu" width="273" height="114" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a Menu 37"/></p>
<p>Since I want to create a game title, I will use a node that allows me to display the text that is <strong>Labels.</strong></p>
<p><img decoding="async" loading="lazy" class="size-full wp-image-37009 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-46-38.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menu 34" width="277" height="188" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 38 . Menu"/></p>
<p>To the right there is a text box.<br /><img decoding="async" loading="lazy" class="size-full wp-image-37010 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-46-51.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 35 . Menu" width="311" height="137" srcset="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-46-51.png 311w, https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-46-51-300x132.png 300w" sizes="auto, (max-width: 311px) 100vw, 311px" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menu 39"/></p>
<p>And your label will be moved to the left corner that you want to move to the right, ah and you can&#8217;t manually adjust it.</p>
<p><img decoding="async" loading="lazy" class="size-full wp-image-37011 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-47-02.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menu 36" width="280" height="116" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 40 . Menu"/> <img decoding="async" loading="lazy" class="size-full wp-image-37012 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-47-11.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a Menu 37" width="284" height="121" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menu 41"/></p>
</p>
<p>To adjust, select the TieuDe node in the Inspector and select Center in Aligment.<br /><img decoding="async" loading="lazy" class="size-full wp-image-37013 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-47-30.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 38 . Menu" width="555" height="161" srcset="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-47-30.png 555w, https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-47-30-300x87.png 300w" sizes="auto, (max-width: 555px) 100vw, 555px" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 42 . Menu"/></p>
<p>It will then be moved to the middle<img decoding="async" loading="lazy" class="size-full wp-image-37014 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-51-05.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menu 39" width="284" height="112" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menu 43"/></p>
<p>If you pay attention, you can see that the TieuDe is close to the top of the screen so I will make it wider.</p>
<p>You add a node called NinePatchRect (and put it at the top), then here you can use another node to create space like Vbox, etc.  Here, I just choose great.<br /><img decoding="async" loading="lazy" class="size-full wp-image-37015 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-51-22.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 40 . Menu" width="307" height="234" srcset="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-51-22.png 307w, https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-51-22-300x229.png 300w" sizes="auto, (max-width: 307px) 100vw, 307px" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menu 44"/></p>
</p>
<p>In the Rect section of NinePatchRect you adjust the Min Size to 50.</p>
<p><strong>Note the adjustment at Min size, not size because there are some cases of size adjustment, but it will reset to the original size.</strong><br /><img decoding="async" loading="lazy" class="size-full wp-image-37016 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-51-34.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menu 41" width="610" height="121" srcset="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-51-34.png 610w, https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-51-34-300x60.png 300w" sizes="auto, (max-width: 610px) 100vw, 610px" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 45 . Menu"/></p>
<p>After adjustment.<img decoding="async" loading="lazy" class="size-full wp-image-37017 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-55-12.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 42 . Menu" width="303" height="127" srcset="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-55-12.png 303w, https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-55-12-300x126.png 300w" sizes="auto, (max-width: 303px) 100vw, 303px" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 46 . Menu"/></p>
<p>Next is the button part.  Like Tiude, I add an Hbox and add a node that allows us to press the button that is Button.</p>
<p><img decoding="async" loading="lazy" class="size-full wp-image-37018 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-56-25.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menu 43" width="292" height="132" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a Menu 47"/></p>
<p>I rename again.</p>
<p><img decoding="async" loading="lazy" class="size-full wp-image-37019 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-57-02.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menu 44" width="272" height="158" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 48 . Menu"/></p>
<p>You will have to align it to the center like you did with Tieude.</p>
<p><img decoding="async" loading="lazy" class="size-full wp-image-37020 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-57-12.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 45 . Menu" width="281" height="135" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 49 . Menu"/> <img decoding="async" loading="lazy" class="size-full wp-image-37021 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-57-19.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 46 . Menu" width="326" height="178" srcset="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-57-19.png 326w, https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-57-19-300x164.png 300w" sizes="auto, (max-width: 326px) 100vw, 326px" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 50 . Menu"/></p>
<p>I added NinePatchRect to create space.</p>
<p><img decoding="async" loading="lazy" class="size-full wp-image-37022 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-59-21.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a Menu 47" width="280" height="203" srcset="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-59-21.png 280w, https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-59-21-120x86.png 120w" sizes="auto, (max-width: 280px) 100vw, 280px" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menu 51"/> <img decoding="async" loading="lazy" class="size-full wp-image-37023 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-59-27.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 48 . Menu" width="327" height="268" srcset="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-59-27.png 327w, https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-12-59-27-300x246.png 300w" sizes="auto, (max-width: 327px) 100vw, 327px" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 52 . Menu"/></p>
<p>Similarly, I added an exit button to the game.</p>
<p><img decoding="async" loading="lazy" class="size-full wp-image-37024 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-01-00-59.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 49 . Menu" width="287" height="162" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menu 53"/></p>
<p>Save the scene in a new folder named UI.</p>
<p><img alt="[Tạo 2D Platformer Game với Godot] Part 17: Creating Menus" title="[Tạo 2D Platformer Game với Godot] Part 17: Creating Menus" post-id="4262" fifu-featured="1" decoding="async" loading="lazy" class="size-full wp-image-37025 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-01-01-47.png" alt="[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 50 . Menu" width="344" height="253" srcset="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-01-01-47.png 344w, https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-01-01-47-300x221.png 300w" sizes="auto, (max-width: 344px) 100vw, 344px" title="[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menu 54"/></p>
<h2 id="ftoc-tong-ket" class="ftwp-heading">summary</h2>
<p>So in this part, I showed you how to create a basic menu for the game.</p>
<div class="kk-star-ratings kksr-auto kksr-align-right kksr-valign-bottom" data-payload="{&quot;align&quot;:&quot;right&quot;,&quot;id&quot;:&quot;36992&quot;,&quot;slug&quot;:&quot;default&quot;,&quot;valign&quot;:&quot;bottom&quot;,&quot;ignore&quot;:&quot;&quot;,&quot;reference&quot;:&quot;auto&quot;,&quot;class&quot;:&quot;&quot;,&quot;count&quot;:&quot;100&quot;,&quot;legendonly&quot;:&quot;&quot;,&quot;readonly&quot;:&quot;&quot;,&quot;score&quot;:&quot;5&quot;,&quot;starsonly&quot;:&quot;&quot;,&quot;best&quot;:&quot;5&quot;,&quot;gap&quot;:&quot;5&quot;,&quot;greet&quot;:&quot;\u0110\u00e1nh gi\u00e1 b\u00e0i vi\u1ebft post&quot;,&quot;legend&quot;:&quot;B\u00e0i vi\u1ebft \u0111\u1ea1t: 5\/5 - (100 b\u00ecnh ch\u1ecdn)&quot;,&quot;size&quot;:&quot;24&quot;,&quot;width&quot;:&quot;142.5&quot;,&quot;_legend&quot;:&quot;B\u00e0i vi\u1ebft \u0111\u1ea1t: {score}\/{best} - ({count} {votes})&quot;,&quot;font_factor&quot;:&quot;1.25&quot;}">
<p>            The article achieved: 5/5 &#8211; (100 votes)    </p>
</p></div>
</div>
]]></content:encoded>
					
					<wfw:commentRss>https://en.anonyviet.com/tao-2d-platformer-game-voi-godot-part-17-creating-menus/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<media:content url="https://anonyviet.com/wp-content/uploads/2021/11/19-11-2021-01-01-47.png" medium="image"></media:content>
            	</item>
		<item>
		<title>[Tạo 2D Platformer Game với Godot] Part 25: Creating Menus When Levels Are Out</title>
		<link>https://en.anonyviet.com/tao-2d-platformer-game-voi-godot-part-25-creating-menus-when-levels-are-out/</link>
					<comments>https://en.anonyviet.com/tao-2d-platformer-game-voi-godot-part-25-creating-menus-when-levels-are-out/#respond</comments>
		
		<dc:creator><![CDATA[AnonyViet]]></dc:creator>
		<pubDate>Thu, 26 Jan 2023 14:29:40 +0000</pubDate>
				<category><![CDATA[Tips]]></category>
		<category><![CDATA[creating]]></category>
		<category><![CDATA[Game]]></category>
		<category><![CDATA[Godot]]></category>
		<category><![CDATA[Levels]]></category>
		<category><![CDATA[Menus]]></category>
		<category><![CDATA[Part]]></category>
		<category><![CDATA[Platformer]]></category>
		<category><![CDATA[tạo]]></category>
		<category><![CDATA[với]]></category>
		<guid isPermaLink="false">https://en.anonyviet.com/?p=4129</guid>

					<description><![CDATA[In this part, I will show you how to create a menu when you finish playing a level and it will be able to move to the next level, play again and return to the Level Map menu. Join the channel Telegram of the AnonyViet 👉 Link 👈 Copy Scene Then instead of having to [&#8230;]]]></description>
										<content:encoded><![CDATA[<p></p>
<div id="ftwp-postcontent">
<p>In this part, I will show you how to create a menu when you finish playing a level and it will be able to move to the next level, play again and return to the Level Map menu.</p>
<div class="code-block code-block-16" style="margin: 8px 0; clear: both;">
<div align="center">
<table class=" aligncenter" style="background-color: #c0c0c0; border-collapse: collapse; width: 59.9985%;">
<tbody>
<tr>
<td style="width: 100%; text-align: center;"><span style="font-size: 12pt;"><strong>Join the channel <span style="color: #0000ff;">Telegram</span> of the <span style="color: #008080;">AnonyViet </span> 👉 <span style="text-decoration: underline;"><a target="_blank" href="https://en.anonyviet.com/next-link?url=https%3A%2F%2Ft.me%2Fanonyvietchat" class="local-link" rel="noopener">Link</a></span>  👈</strong></span></td>
</tr>
</tbody>
</table>
</div>
</div>
<h3 id="ftoc-copy-scene" class="ftwp-heading">Copy Scene</h3>
<p>Then instead of having to recreate it from scratch, you can duplicate a new scene from the scene pause menu.</p>
<p><img decoding="async" class="aligncenter wp-image-37366 size-medium" src="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-35-56-300x157.png" alt="[Tạo 2D Platformer Game với Godot]  Part 25: Creating Menus When Levels Are Out" width="300" height="157" srcset="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-35-56-300x157.png 300w, https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-35-56.png 379w" sizes="(max-width: 300px) 100vw, 300px" title="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 19 is over"/></p>
<p>You find the pause menu in the filesystem right click and click duplicate</p>
<p style="text-align: center;"><img decoding="async" loading="lazy" class="size-medium wp-image-37367 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-36-15-300x132.png" alt="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 16 is over" width="300" height="132" srcset="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-36-15-300x132.png 300w, https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-36-15.png 312w" sizes="auto, (max-width: 300px) 100vw, 300px" title="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 20 is over"/></p>
<p style="text-align: center;"><img decoding="async" loading="lazy" class="size-medium wp-image-37368 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-36-50-300x125.png" alt="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 17 is over" width="300" height="125" srcset="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-36-50-300x125.png 300w, https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-36-50.png 306w" sizes="auto, (max-width: 300px) 100vw, 300px" title="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 21 is over"/></p>
</p>
<p>I will rename it EndLevelMenu<br /><img decoding="async" loading="lazy" class="size-medium wp-image-37370 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-38-38-295x300.png" alt="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 18 is over" width="295" height="300" srcset="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-38-38-295x300.png 295w, https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-38-38-75x75.png 75w, https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-38-38.png 329w" sizes="auto, (max-width: 295px) 100vw, 295px" title="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 22 is over"/></p>
</p>
<p>Then you delete the other nodes and leave them as shown, I changed the name NutTepTuc to LevelKeTiep</p>
<p><img decoding="async" loading="lazy" class="size-full wp-image-37376 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-47-15.png" alt="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 19 is over" width="282" height="247" title="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 23 is over"/></p>
</p>
<p>Edit text in TieuDe<br /><img decoding="async" loading="lazy" class="size-medium wp-image-37371 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-38-58-300x78.png" alt="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 20 is over" width="300" height="78" srcset="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-38-58-300x78.png 300w, https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-38-58.png 360w" sizes="auto, (max-width: 300px) 100vw, 300px" title="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 24 is over"/></p>
<p>You will clear the old script by pressing the button with the paper that has an x<img decoding="async" loading="lazy" class="size-medium wp-image-37372 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-39-41-300x65.png" alt="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 21 is over" width="300" height="65" srcset="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-39-41-300x65.png 300w, https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-39-41-350x76.png 350w, https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-39-41.png 352w" sizes="auto, (max-width: 300px) 100vw, 300px" title="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 25 is over"/> <img decoding="async" loading="lazy" class="size-medium wp-image-37373 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-39-50-300x267.png" alt="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 22 is over" width="300" height="267" srcset="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-39-50-300x267.png 300w, https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-39-50.png 361w" sizes="auto, (max-width: 300px) 100vw, 300px" title="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 26 is over"/></p>
<p>Then create a new one.<img decoding="async" loading="lazy" class="size-medium wp-image-37374 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-40-15-157x300.png" alt="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 23 is over" width="157" height="300" srcset="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-40-15-157x300.png 157w, https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-40-15.png 292w" sizes="auto, (max-width: 157px) 100vw, 157px" title="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 27 is over"/></p>
<p>Then 3 buttons, you disconnect because it is connecting to the old script.</p>
<p><img decoding="async" loading="lazy" class="size-medium wp-image-37375 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-46-34-300x223.png" alt="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 24 is over" width="300" height="223" srcset="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-46-34-300x223.png 300w, https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-46-34.png 337w" sizes="auto, (max-width: 300px) 100vw, 300px" title="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 28 is over"/></p>
<p>Then reconnect 3 new ones.</p>
<p><img decoding="async" loading="lazy" class="size-medium wp-image-37377 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-52-50-295x300.png" alt="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 25 is over" width="295" height="300" srcset="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-52-50-295x300.png 295w, https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-52-50-75x75.png 75w, https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-52-50.png 322w" sizes="auto, (max-width: 295px) 100vw, 295px" title="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 29 is over"/></p>
<p>Then Instance EndLevelMenu to Map.</p>
<p>Then you remember to hide the EndLevelMenu that belongs to the Control Node type.</p>
<h3 id="ftoc-script" class="ftwp-heading">Script</h3>
<pre class="EnlighterJSRAW" data-enlighter-language="generic">extends CanvasLayer&#13;
&#13;
&#13;
&#13;
onready var level = get_parent().get_node("KhuVucDiChuyen")&#13;
&#13;
func _on_NutLevelKeTiep_pressed():&#13;
    get_tree().paused = false&#13;
    get_tree().change_scene(level.LevelKeTiep)&#13;
    pass # Replace with function body.&#13;
&#13;
func _on_NutChoiLai_pressed():&#13;
    get_tree().paused = false&#13;
    get_tree().reload_current_scene()&#13;
    print("choi lai")&#13;
    pass # Replace with function body.&#13;
&#13;
&#13;
func _on_NutVeMenu_pressed():&#13;
    get_tree().paused = false&#13;
    get_tree().change_scene("res://Scences/Map/LevelMap.tscn")&#13;
    pass # Replace with function body.&#13;
</pre>
<p>Here is the code of the EndLevelMenu script.</p>
<p>2 signals of the replay button and the menu will remain the same.</p>
<p>For LevelKeTiep to save time instead of having to manually set it up to see which level it moves to the next level, I&#8217;ll take it.  At the KhuVucDi Chuyen node, I have created a variable called LevelKeTiep and it carries the data of the next scene, so I will call that variable instead of doing it manually.</p>
<p><img decoding="async" loading="lazy" class="size-medium wp-image-37378 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-57-26-280x300.png" alt="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 26 is over" width="280" height="300" srcset="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-57-26-280x300.png 280w, https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-10-57-26.png 314w" sizes="auto, (max-width: 280px) 100vw, 280px" title="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 30 is over"/></p>
<p><code class="EnlighterJSRAW" data-enlighter-language="generic">onready var level = get_parent().get_node("KhuVucDiChuyen")</code>: is that I declare it and assign it with the parent node of the EndLevelMenu (as shown in the picture) and from that parent node I can access the KhuVucDi Chuyen node to get the data of the LevelKeTiep variable.</p>
<pre class="EnlighterJSRAW" data-enlighter-language="generic">extends Area2D&#13;
&#13;
&#13;
export (String,FILE) var LevelKeTiep&#13;
onready var endlevelmenu = get_parent().get_node("EndLevelMenu")&#13;
&#13;
func _on_KhuVucDiChuyen_body_entered(body):&#13;
    if body.name == "Player":&#13;
#		get_tree().change_scene(LevelKeTiep)&#13;
        endlevelmenu.get_node("EndLevelMenu").show()&#13;
        get_tree().paused = true&#13;
</pre>
<p>In the script of KhuVucDIChuyen, I changed it a little bit.</p>
<p>Here, instead of moving to the next level as usual, I will show it the EndLevelMenu and then stop the tree like in the pausemenu.</p>
<p>If you wonder why I get_node() 2 EndLevelMenu, then look at the picture below.<img decoding="async" loading="lazy" class="size-medium wp-image-37380 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-11-07-38-300x61.png" alt="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 27 is over" width="300" height="61" srcset="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-11-07-38-300x61.png 300w, https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-11-07-38.png 329w" sizes="auto, (max-width: 300px) 100vw, 300px" title="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 31 is over"/></p>
<p>I call 2 EndLevelMenu because I have 2 nodes :).</p>
<p><img alt="[Tạo 2D Platformer Game với Godot] Part 25: Creating Menus When Levels Are Out" title="[Tạo 2D Platformer Game với Godot] Part 25: Creating Menus When Levels Are Out" post-id="4129" fifu-featured="1" decoding="async" loading="lazy" class="size-full wp-image-37381 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-11-13-02.png" alt="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 28 is over" width="218" height="220" srcset="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-11-13-02.png 218w, https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-11-13-02-150x150.png 150w, https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-11-13-02-75x75.png 75w" sizes="auto, (max-width: 218px) 100vw, 218px" title="[Tạo 2D Platformer Game với Godot]  Part 25: Create a Menu when Level 32 is over"/></p>
<p>And here are my results</p>
<h2 id="ftoc-tong-ket" class="ftwp-heading">Summary</h2>
<p>In the next part, I will show you how to calculate the score after collecting the coins and when you go out of the LevelMap you will get the number of stars corresponding to the number of points.</p>
</p>
</p>
<div class="kk-star-ratings kksr-auto kksr-align-right kksr-valign-bottom" data-payload="{&quot;align&quot;:&quot;right&quot;,&quot;id&quot;:&quot;37363&quot;,&quot;slug&quot;:&quot;default&quot;,&quot;valign&quot;:&quot;bottom&quot;,&quot;ignore&quot;:&quot;&quot;,&quot;reference&quot;:&quot;auto&quot;,&quot;class&quot;:&quot;&quot;,&quot;count&quot;:&quot;100&quot;,&quot;legendonly&quot;:&quot;&quot;,&quot;readonly&quot;:&quot;&quot;,&quot;score&quot;:&quot;5&quot;,&quot;starsonly&quot;:&quot;&quot;,&quot;best&quot;:&quot;5&quot;,&quot;gap&quot;:&quot;5&quot;,&quot;greet&quot;:&quot;\u0110\u00e1nh gi\u00e1 b\u00e0i vi\u1ebft post&quot;,&quot;legend&quot;:&quot;B\u00e0i vi\u1ebft \u0111\u1ea1t: 5\/5 - (100 b\u00ecnh ch\u1ecdn)&quot;,&quot;size&quot;:&quot;24&quot;,&quot;width&quot;:&quot;142.5&quot;,&quot;_legend&quot;:&quot;B\u00e0i vi\u1ebft \u0111\u1ea1t: {score}\/{best} - ({count} {votes})&quot;,&quot;font_factor&quot;:&quot;1.25&quot;}">
<p>            The article achieved: 5/5 &#8211; (100 votes)    </p>
</p></div>
</div>
]]></content:encoded>
					
					<wfw:commentRss>https://en.anonyviet.com/tao-2d-platformer-game-voi-godot-part-25-creating-menus-when-levels-are-out/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<media:content url="https://anonyviet.com/wp-content/uploads/2021/11/23-11-2021-11-13-02.png" medium="image"></media:content>
            	</item>
	</channel>
</rss>
