Skip to main content

Posts

Showing posts with the label game mechanics

Improve your jumping! | Type of jumps in Godot

Wall jump, Wall climbing, Wall sliding and double jump are some of the most common mechanics for a plat-former game. And on top of that they are super easy to create in Godot. So in this Godot tutorial, I have tried to implement all these things in the simplest way possible. I would highly recommend you to watch the 2-D movement video first, because I am adding wall jumps and other stuff in that same script. So, watch it at 1.5x speed! to get an overview. VIDEO TUTORIAL TEXT TUTORIAL Double Jump For this, create a variable jump_counter. This will keep track of how many jumps we have done, while we're in the air. So by default it will be 0. var jump_counter : int = 0 <------- var jump_buffer_counter : int = 0 var cayote_counter : int = 0 Now if you remember, in the previous video, when we are pressing the jump button. We are setting the jump_buffer_counter. So, when we are not on the ground, we will check if buffer_counter > 0 This will be true, only when we have pressed th...

Background Loading in Godot | DICODE

Video Tutorial       

Easiest way to create cutscene in Godot

Hello everyone! I know you have been waiting for this for a long time,  so here it is another Godot tutorial. 

How to make enemy patrolling on a custom path.

If you are creating a top down game then you will want to move your enemy in a certain path. patrolling is a very important aspect of any game and with Godot it is very easy to create. All you need is path2D node and pathfollow2D. In this video I have cover both straight line patrolling and circular path patrolling. here is the video tutorial-

How to create an object pickup system in Godot

Hey there I have shown you how you can make pick and drop system in Godot. It is very simple and there is no complex calculation going on and this will take your game development skill to next level. I have given complete logic about how it will work. I have shown you in top down game but you can make it in platformer or even in 3D the logic will remain the same. If you have question like how to make pick and drop system in Godot ? how to make pickup system in Godot ? how to pick any object in Godot ? then you will get answer to all of these questions.... here is the video tutorial-

How to share variable between scenes in Godot

  if you have questions like 1. how to share variable between scripts ? 2. how to transfer variable between one script to another ? 3. how to transfer variable over another scene ? then you are at right place. what ever game you create there is always a need to share or transfer variables between scripts. there are actually three very easy way to share variable between scripts. 1. by creating a global script 2. by sending variables with signals 3. by sending values using functions there may be other ways also to share data but these are more common and simple way to share variable. I hope this helps you in making your game. Here is the video tutorial-

How to Create Joystick in Godot

  here is the tutorial video: code use in the tutorial Joystick Code var start_pos: Vector2 = Vector2.ZERO var end_pos: Vector2 = Vector2.ZERO var valid_pos = false onready var js_pos = get_node("background").rect_position onready var js_bg = get_node("background") onready var js_handle = get_node("background/handle") signal swipe_detect(swipe_direction, strength) signal swipe_end func _input(event: InputEvent) -> void: if valid_pos: if event is InputEventScreenDrag: if start_pos == Vector2.ZERO: start_pos = event.position js_bg.rect_position = Vector2(start_pos.x - 128, start_pos.y - 128) end_pos = event.position var direction = end_pos - start_pos if direction.length() < 120: js_handle.rect_position.x = 96 + direction.length() js_handle.rect_pivot_offset.x = 32 - direction.length() js_handle.rect_rotation = rad2deg(direction.angle()) emit_signal("swipe_detect",direction, direction.length())...