• Home
  • News
  • Software
  • Knowledge
  • MMO
  • Tips
  • Security
  • Network
  • Office
AnonyViet - English Version
  • Home
  • News
  • Software
  • Knowledge
  • MMO
  • Tips
  • Security
  • Network
  • Office
No Result
View All Result
  • Home
  • News
  • Software
  • Knowledge
  • MMO
  • Tips
  • Security
  • Network
  • Office
No Result
View All Result
AnonyViet - English Version
No Result
View All Result

[Tạo 2D Platformer Game với Godot] Part 17: Creating Menus

AnonyViet by AnonyViet
January 27, 2023
in Tips
0

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’s UI.

Join the channel Telegram of the AnonyViet 👉 Link 👈

[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menus

Then the first thing is you create yourself a new scene with the Control Node as the root node and rename it to Menu.

And add a new node that is Vboxcontanier.

VBoxContainer: 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.

HBoxContainer: Hbox is the opposite of Vbox in that it is arranged horizontally.

If you notice, there are letters V and H at the beginning of the name, and this V – H is the name of the two horizontal and vertical axes in English.

[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 27 . Menu

Then you select Layout at the bottom of the toolbar and select full rect[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 28 . Menu

After you select full rect it will look like this.

[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 29 . Menu

I will rename it for easy identification.

[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 30 . Menu

And I added 2 more Vbox and renamed it 1 PhanDau and 1 PhanCuoi.

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.

[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 31 . Menu [Tạo 2D Platformer Game với Godot]  Part 17: Creating a 32 . Menu

I will add 1 more node Hbox and rename it TieuDe.

[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 33 . Menu

Since I want to create a game title, I will use a node that allows me to display the text that is Labels.

[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menu 34

To the right there is a text box.
[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 35 . Menu

And your label will be moved to the left corner that you want to move to the right, ah and you can’t manually adjust it.

[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menu 36 [Tạo 2D Platformer Game với Godot]  Part 17: Creating a Menu 37

To adjust, select the TieuDe node in the Inspector and select Center in Aligment.
[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 38 . Menu

It will then be moved to the middle[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menu 39

If you pay attention, you can see that the TieuDe is close to the top of the screen so I will make it wider.

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.
[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 40 . Menu

In the Rect section of NinePatchRect you adjust the Min Size to 50.

Note the adjustment at Min size, not size because there are some cases of size adjustment, but it will reset to the original size.
[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menu 41

After adjustment.[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 42 . Menu

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.

[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menu 43

I rename again.

[Tạo 2D Platformer Game với Godot]  Part 17: Creating Menu 44

You will have to align it to the center like you did with Tieude.

[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 45 . Menu [Tạo 2D Platformer Game với Godot]  Part 17: Creating a 46 . Menu

I added NinePatchRect to create space.

[Tạo 2D Platformer Game với Godot]  Part 17: Creating a Menu 47 [Tạo 2D Platformer Game với Godot]  Part 17: Creating a 48 . Menu

Similarly, I added an exit button to the game.

[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 49 . Menu

Save the scene in a new folder named UI.

[Tạo 2D Platformer Game với Godot]  Part 17: Creating a 50 . Menu

summary

So in this part, I showed you how to create a basic menu for the game.

The article achieved: 5/5 – (100 votes)

Tags: creatingGameGodotMenusPartPlatformertạovới
Previous Post

How to create VPS Windows, MAC, Ubuntu, Android, IOS for free

Next Post

How to use Conversation Widget on Android 12

AnonyViet

AnonyViet

Related Posts

Top 5 game programming languages ​​to learn now
Tips

Top 5 game programming languages ​​to learn now

June 8, 2025
[Godot Shooter] #2: Creating characters & shooting bullets
Tips

[Godot Shooter] #2: Creating characters & shooting bullets

June 7, 2025
What do you need to learn game programming? Is it difficult? How long does it take?
Tips

What do you need to learn game programming? Is it difficult? How long does it take?

June 6, 2025
Instructions for registering chatgpt team at $ 1
Tips

Instructions for registering chatgpt team at $ 1

June 5, 2025
How to engrave the right mouse menu error on Windows
Tips

How to engrave the right mouse menu error on Windows

June 5, 2025
How to create online meme photos is very easy with a few steps
Tips

How to create online meme photos is very easy with a few steps

June 5, 2025
Next Post
How to use Conversation Widget on Android 12

How to use Conversation Widget on Android 12

0 0 votes
Article Rating
Subscribe
Login
Notify of
guest

guest

0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments

Recent News

Top 5 game programming languages ​​to learn now

Top 5 game programming languages ​​to learn now

June 8, 2025
The iPhone list is updated with iOS 26

The iPhone list is updated with iOS 26

June 8, 2025
Discover the glowing effect next to the iPhone ios 18 screen

Discover the glowing effect next to the iPhone ios 18 screen

June 8, 2025
[Godot Shooter] #2: Creating characters & shooting bullets

[Godot Shooter] #2: Creating characters & shooting bullets

June 7, 2025
Top 5 game programming languages ​​to learn now

Top 5 game programming languages ​​to learn now

June 8, 2025
The iPhone list is updated with iOS 26

The iPhone list is updated with iOS 26

June 8, 2025
Discover the glowing effect next to the iPhone ios 18 screen

Discover the glowing effect next to the iPhone ios 18 screen

June 8, 2025
AnonyViet - English Version

AnonyViet

AnonyViet is a website share knowledge that you have never learned in school!

We are ready to welcome your comments, as well as your articles sent to AnonyViet.

Follow Us

Contact:

Email: anonyviet.com[@]gmail.com

Main Website: https://anonyviet.com

Recent News

Top 5 game programming languages ​​to learn now

Top 5 game programming languages ​​to learn now

June 8, 2025
The iPhone list is updated with iOS 26

The iPhone list is updated with iOS 26

June 8, 2025
  • Home
  • Home 2
  • Home 3
  • Home 4
  • Home 5
  • Home 6
  • Next Dest Page
  • Sample Page

©2024 AnonyVietFor Knowledge kqxs hôm nay xem phim miễn phí SHBET https://kubet88.yoga/ bj88

No Result
View All Result
  • Home
  • News
  • Software
  • Knowledge
  • MMO
  • Tips
  • Security
  • Network
  • Office

©2024 AnonyVietFor Knowledge kqxs hôm nay xem phim miễn phí SHBET https://kubet88.yoga/ bj88

wpDiscuz
0
0
Would love your thoughts, please comment.x
()
x
| Reply