• 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

[Lập Trình Game] Lesson 4: Create a camera to track the character

AnonyViet by AnonyViet
February 2, 2023
in Tips
0

Next in the series Game programming with Godot, today I will guide you to create a character tracking camera. When the character moves on the screen, we will easily follow our character.

Join the channel Telegram of the AnonyViet 👉 Link 👈

Let’s get started:

Camera

In the previous post you did, you will see when running the game it will look like the picture

complete game design using godot

And this is after the camera

Create a camera to track the game programming character godot

How to create a character tracking camera

So today I will guide you to create a camera for your character.

First in Player you find and create for yourself Node Camera2D

camera godot

Then you zoom out to notice that you will see 2 squares:

  • 1 piece below is incomplete.
  • the one above is complete and The complete one is your camera frame.

[Lập Trình Game]  Lesson 4: Create a camera to track the character 14

If you run the game it stays the same so we need to edit again settings of the camera

Open your own section Limit beside setting camera2d

[Lập Trình Game]  Lesson 4: Create a 15 . character tracking camera

What is Limit? Limit is the limit of the camera, for example left is the coordinate that it will go to the left

To make it easier to understand, please pay attention to the picture below

[Lập Trình Game]  Lesson 4: Create a 16 . character tracking camera

The vertical green line is the number 0 and that is coordinates x and the red line going to the left is y . coordinates

VD: You want the camera move to 0 x-axis is to stop and not move, you can edit it in the box Limit part left is 0

Ah must turn on Current it just works

[Lập Trình Game]  Lesson 4: Create a camera to track the character 17

When you turn it on, you will see a change and if you turn it on, you won’t see anything so let’s continue

Part top I also let 0 so that it doesn’t go over the red line

Part Botton I let 325 and how to bottom setting

Friend zoom up the part you want it to be limited to bottom

[Lập Trình Game]  Lesson 4: Create an 18 . character tracking camera

You guys keep looking for landmarks and then zoom When you go up, you will see the number in the left column and then fill it in bottom like photo

[Lập Trình Game]  Lesson 4: Create a camera to track the character 19

And then adjust the zoom X 1 – Y 1 -> X 0.5 – Y 0.5

[Lập Trình Game]  Lesson 4: Create a 20 . character tracking camera

Run the game and you’ll see the difference

And you can see our game screen has changed

[Lập Trình Game]  Lesson 4: Create a camera to track the character 21

If you think it’s too big, adjust it 0.6- 0.8 Please. If you do not want to adjust but see it as large, just adjust the Player to be smaller.

And one more part is that if you pay attention, you will see when you move, the camera moves along and in godot also supports you to add a mode that when you move a segment, the camera will move.

That is the part: Drag Margin H – Drag Margin DRAW

[Lập Trình Game]  Lesson 4: Create a 22 . character tracking camera

Click on those 2 you will see the difference.

And when you move, you will see that when you reach a position, the camera will move according to the character, so is there a way to adjust the position limit so that the camera will move the character? And of course there are you guys looking for yourself Drag Margin live settings camera

[Lập Trình Game]  Lesson 4: Create a camera to track the character 23

And it will not show a frame telling you how limited it is, so you can turn it on for yourself as follows:

Find Editor > enable Draw Drag Margin okay and it will be displayed and you can edit it as you like

[Lập Trình Game]  Lesson 4: Create a 24 . character tracking camera

So, I have finished the guide to monitoring the character screen by configuring the Camera. You should see from post 0 Go to this post for easy steps.

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

Tags: CameracharactercreateGamelậpLessontracktrình
Previous Post

How to listen to music on Youtube when the phone screen is off with Music Pro

Next Post

New update of Windows 10 continues to delete user data

AnonyViet

AnonyViet

Related Posts

The 10 best Torrent websites today – 100% still operate
Tips

The 10 best Torrent websites today – 100% still operate

May 20, 2025
Share Code Shop Selling Acc game extremely lightweight written in bootstrap
Tips

Share Code Shop Selling Acc game extremely lightweight written in bootstrap

May 19, 2025
Display the Internet speed on Windows Taskbar with Du Metter
Tips

Display the Internet speed on Windows Taskbar with Du Metter

May 18, 2025
Interesting facts about Google that you don’t know
Tips

Interesting facts about Google that you don’t know

May 17, 2025
How to create a 1 -word Facebook name on the phone is 100% successful
Tips

How to create a 1 -word Facebook name on the phone is 100% successful

May 16, 2025
4 ways to remove Ask Copilot from the right -click menu on Windows 11
Tips

4 ways to remove Ask Copilot from the right -click menu on Windows 11

May 15, 2025
Next Post
New update of Windows 10 continues to delete user data

New update of Windows 10 continues to delete user data

0 0 votes
Article Rating
Subscribe
Login
Notify of
guest

guest

0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments

Recent News

Discover Supermix – Smart playlist on YouTube Music

Discover Supermix – Smart playlist on YouTube Music

May 20, 2025
The 10 best Torrent websites today – 100% still operate

The 10 best Torrent websites today – 100% still operate

May 20, 2025
Share Code Shop Selling Acc game extremely lightweight written in bootstrap

Share Code Shop Selling Acc game extremely lightweight written in bootstrap

May 19, 2025
Instructions for downloading all photos and story from Instagram

Instructions for downloading all photos and story from Instagram

May 19, 2025
Discover Supermix – Smart playlist on YouTube Music

Discover Supermix – Smart playlist on YouTube Music

May 20, 2025
The 10 best Torrent websites today – 100% still operate

The 10 best Torrent websites today – 100% still operate

May 20, 2025
Share Code Shop Selling Acc game extremely lightweight written in bootstrap

Share Code Shop Selling Acc game extremely lightweight written in bootstrap

May 19, 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

Discover Supermix – Smart playlist on YouTube Music

Discover Supermix – Smart playlist on YouTube Music

May 20, 2025
The 10 best Torrent websites today – 100% still operate

The 10 best Torrent websites today – 100% still operate

May 20, 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 bongdaso

wpDiscuz
0
0
Would love your thoughts, please comment.x
()
x
| Reply
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 bongdaso