How To Triple Jump In Unity
2:41
Жыл бұрын
Smooth Camera Zoom In Unity
3:23
Жыл бұрын
How To Dash In Unity
3:53
2 жыл бұрын
2D Player Movement In Unity
5:34
2 жыл бұрын
How To Double Jump In Unity
2:12
2 жыл бұрын
Smooth Camera Follow In Unity
2:23
3 жыл бұрын
How To Make 2D Jump Pads in Unity
1:52
How To Make 2D Teleporters In Unity
3:39
Custom Cursors In Unity
3:52
3 жыл бұрын
How To Make 2D Ladders In Unity
4:25
How To Build Your Own Alexa In Unity
6:44
Пікірлер
@Srbin12.34
@Srbin12.34 9 сағат бұрын
my character falls through the ground help pleaes
@Adam_MK-YT
@Adam_MK-YT 2 күн бұрын
When i completed everything in the tutorial and tested the game, the dashing was way too far, so for anyone that had the same problem here is how to fix it: make private float dashingPower = 6f; instead of private float dashingPower = 24f;
@johnnygamer4933
@johnnygamer4933 3 күн бұрын
1 minute to say that you are going to talk about ladders... when the title is 'How to make Ladders'.
@Rivaldix12
@Rivaldix12 4 күн бұрын
When i type this line; if (isWalled() && !grounded() && xInput != 0f) it says "Non-invocable member 'PlayerMovement.grounded' cannot be used like a method." Can you please help :(
@SantaGT-sd5je
@SantaGT-sd5je 4 күн бұрын
my cube keeps colliding through the floor how do i fix it
@bendux
@bendux 3 күн бұрын
If you want two game objects to collide with each other, both game objects require a collider.
@SantaGT-sd5je
@SantaGT-sd5je 3 күн бұрын
@@bendux ok thanks
@SantaGT-sd5je
@SantaGT-sd5je 3 күн бұрын
Also how do i add a collider
@kheloras4786
@kheloras4786 8 күн бұрын
What a simple and clear tutorial. Thanks for this ! It helps me a lot on my project !
@FKIguanadons
@FKIguanadons 13 күн бұрын
lmao bro 100 years later, don't do me like that all kids should experience split screen gaming with their friends. enough of this online bs
@BigCMakesVids2.0
@BigCMakesVids2.0 14 күн бұрын
I copied your actions and I just fell through the floor.
@BigCMakesVids2.0
@BigCMakesVids2.0 14 күн бұрын
Fixed but it's impossible to jump
@bendux
@bendux 10 күн бұрын
You probably skipped one or two important steps in the tutorial.
@BigCMakesVids2.0
@BigCMakesVids2.0 9 күн бұрын
@@bendux I used your code from GitHub, I dunno what's wrong with it.
@bendux
@bendux 3 күн бұрын
@@BigCMakesVids2.0 If you follow the video step by step, you should end up with a moving and jumping player.
15 күн бұрын
Thanks bro it was short and really effective.
@陳柏宇-s6z
@陳柏宇-s6z 16 күн бұрын
great tutorial, the video and code are both short and clean, thank you
@edmornee
@edmornee 17 күн бұрын
if you want dashing no shift bu right mouse click then here it is!! using System.Collections; using UnityEngine; public class PlayerMovement : MonoBehaviour { private float horizontal; private float speed = 8f; private float jumpingPower = 16f; private bool isFacingRight = true; private bool canDash = true; private bool isDashing; private float dashingPower = 24f; private float dashingTime = 0.2f; private float dashingCooldown = 1f; [SerializeField] private Rigidbody2D rb; [SerializeField] private Transform groundCheck; [SerializeField] private LayerMask groundLayer; [SerializeField] private TrailRenderer tr; private void Update() { if (isDashing) { return; } horizontal = Input.GetAxisRaw("Horizontal"); if (Input.GetButtonDown("Jump") && IsGrounded()) { rb.velocity = new Vector2(rb.velocity.x, jumpingPower); } if (Input.GetButtonUp("Jump") && rb.velocity.y > 0f) { rb.velocity = new Vector2(rb.velocity.x, rb.velocity.y * 0.5f); } if (Input.GetMouseButtonDown(1) && canDash) { StartCoroutine(Dash()); } Flip(); } private void FixedUpdate() { if (isDashing) { return; } rb.velocity = new Vector2(horizontal * speed, rb.velocity.y); } private bool IsGrounded() { return Physics2D.OverlapCircle(groundCheck.position, 0.2f, groundLayer); } private void Flip() { if (isFacingRight && horizontal < 0f || !isFacingRight && horizontal > 0f) { Vector3 localScale = transform.localScale; isFacingRight = !isFacingRight; localScale.x *= -1f; transform.localScale = localScale; } } private IEnumerator Dash() { canDash = false; isDashing = true; float originalGravity = rb.gravityScale; rb.gravityScale = 0f; rb.velocity = new Vector2(transform.localScale.x * dashingPower, 0f); tr.emitting = true; yield return new WaitForSeconds(dashingTime); tr.emitting = false; rb.gravityScale = originalGravity; isDashing = false; yield return new WaitForSeconds(dashingCooldown); canDash = true; } }
@ebmpingu
@ebmpingu 17 күн бұрын
Hours spent just understanding this Bro just used 4min 👏👏👏
@viporidk461
@viporidk461 22 күн бұрын
u saved me bro, god bless you with all thats good in life , lions walks with lions and hyena walks with hyenas it's what it's lol kekw keep it real 💯 asap rn
@reibarata
@reibarata 24 күн бұрын
thanks :D short and simple
@Freeze_Vr55
@Freeze_Vr55 24 күн бұрын
Holy crap thanks so much, the camera is buttery smooth.
@imacube2636
@imacube2636 26 күн бұрын
im bouta blow
@SolaroidSF
@SolaroidSF Ай бұрын
Using this to make a quick 2d roguelike in 2 hours for an online course Much love from my laptop <3
@bmonye854
@bmonye854 Ай бұрын
Ty dude, really thank you, get this for free at last I let you a like and a view
@ActiveVRdude
@ActiveVRdude Ай бұрын
did I do something wrong? the groundCheck object isn't following the player object???
@bendux
@bendux Ай бұрын
The ground check must be a child of the player.
@luanlugo6005
@luanlugo6005 Ай бұрын
Edson vence o Larry seu lacrador., amei o video my man.
@MrSmashmasterk
@MrSmashmasterk Ай бұрын
How did you make those straight lines in the code at 2:46?
@andyzheng1064
@andyzheng1064 Ай бұрын
This is kind of simple ladder. No horizontal control, no climb down. It is not enough to make a real demo
@Herobetter-r4f
@Herobetter-r4f Ай бұрын
IT LITERALLLY DOESNT WORK IT JUST GIVES ME ERRORS
@mr.phewphew4971
@mr.phewphew4971 Ай бұрын
Same
@bendux
@bendux Ай бұрын
Without further information, it's impossible to help you.
@fraz1142
@fraz1142 Ай бұрын
that was smooth
@loutherobot
@loutherobot Ай бұрын
TYSM for this amazing tutorial
@iamkennegee
@iamkennegee Ай бұрын
I could use some help regarding slopes. Much appreciated for the easy to follow tutorials!
@Mballs2478
@Mballs2478 Ай бұрын
Thanks buddy :)
@blasterxt9
@blasterxt9 Ай бұрын
German game developer right 👍🏻
@bendux
@bendux Ай бұрын
Yes!
@blasterxt9
@blasterxt9 Ай бұрын
@@bendux hey buddy Do you have discord server
@bendux
@bendux 25 күн бұрын
@@blasterxt9 There is a link to our Discord server in the description.
@realmorteza802
@realmorteza802 Ай бұрын
It was very useful for me. Thank you very much 👌😍
@CourruptVR
@CourruptVR Ай бұрын
Tell me how to open up the script I don’t know how to edit it pls🙏🙏🙏🙏
@mr.phewphew4971
@mr.phewphew4971 Ай бұрын
I think you need a vistual studio code software
@bendux
@bendux Ай бұрын
Have you tried double-clicking the script?
@bicho1331
@bicho1331 Ай бұрын
Best tutorial on this topic i've seen. Thank you so much!
@sigma9.90
@sigma9.90 Ай бұрын
when using this, my player wont jump half the time, i have to press the button a good few times before it works
@jackmoon824
@jackmoon824 Ай бұрын
Didn't worked to me, fuck
@bendux
@bendux Ай бұрын
Without further information, it's impossible to help you.
@jackmoon824
@jackmoon824 Ай бұрын
@@bendux Later, I tried again and it worked. Don't remember what was the problem. Thank you so much for this tutorial! And sorry, I was really stressed and angry. Also, thank you so much for you jumping code. Was way better than the one that I had (about different power of jump), thank to that I had no more troubles to put doble jump to a character. You helped me with 2 complicated stuff on my game with your code, thank you so much
@llenvnn
@llenvnn Ай бұрын
The jump when I had gravity scale on 4 as u showed was short and small so I tried reducing it to 1 and it was higher but now it feels float that character does go down in an fast enough speed u know what I can do to fix it? Or is it a size prob?
@llenvnn
@llenvnn Ай бұрын
I made the cam size 1.8 and sized down the platform and the player and now it jumps higher but it's just too fast 🥹
@bendux
@bendux Ай бұрын
Decrease the jumping power at the top of the script.
@TimFresco
@TimFresco Ай бұрын
Bro I have started making my dream game and I think of a mechanic I need, search it up and you have the tutorial, it is amazing
@flamingfireguns
@flamingfireguns Ай бұрын
my vector3 is underlines in red for some reason could you help meout?
@flamingfireguns
@flamingfireguns Ай бұрын
nvm bro interpolation tip was insane
@no2no182
@no2no182 Ай бұрын
When I dash my speed doesn’t increase It works but I’m just not faster
@bendux
@bendux 10 күн бұрын
It probably has something to do with the order of execution in your script.
@tnam_4159
@tnam_4159 Ай бұрын
Good Tutorial
@S.Dimitris-z9c
@S.Dimitris-z9c Ай бұрын
I used it in my game and it worked perfectly fine. I turned off my pc and when i opened it again (3 hours later) all of a sudden it doesnt work. Why is that? Can anyone help me?
@Slorple
@Slorple Ай бұрын
4:55 theres no "ground check" or "rb" options
@bendux
@bendux Ай бұрын
Make sure that the script is saved and doesn't contain any errors.
@matt1a-bs
@matt1a-bs Ай бұрын
This tutorial is perfection. Thank you, brother.
@AzanAhmed-hy7oc
@AzanAhmed-hy7oc Ай бұрын
Player movement script:using System.Collections; using System.Collections.Generic; using UnityEngine; public class Movement : MonoBehaviour { public float speed = 100f; public float JumpHeight; public bool InAir = false; private Rigidbody2D rb2d; void Start() { rb2d = GetComponent<Rigidbody2D>(); } private void OnCollisionEnter2D(Collision2D collision) { InAir = false; Debug.Log("InAir false"); } private void OnCollisionExit2D(Collision2D collision) { InAir = true; Debug.Log("InAir True"); } void FixedUpdate() { Vector2 NoMovement = new Vector2(0f, 0f); float moveHorizontal = Input.GetAxis("Horizontal"); if (moveHorizontal > 0) { { rb2d.velocity = new Vector2(speed, rb2d.velocity.y); } } if (moveHorizontal < 0) { rb2d.velocity = new Vector2(-speed, rb2d.velocity.y); } if (Input.GetKeyDown(KeyCode.W) || (Input.GetKeyDown(KeyCode.UpArrow))) { if (InAir == false) { rb2d.AddForce(new Vector2(0, JumpHeight), ForceMode2D.Impulse); } } } }
@scordio2305
@scordio2305 Ай бұрын
It works perfectly
@glowraptor5228
@glowraptor5228 2 ай бұрын
is there any way to add a kick off the wall so that if you hold the directional input into the wall, you go upwards and away from the wall
@Heisenburg29
@Heisenburg29 2 ай бұрын
i can't jump
@ITAgame777
@ITAgame777 2 ай бұрын
But i can
@Heisenburg29
@Heisenburg29 2 ай бұрын
@@ITAgame777 ok
@bendux
@bendux Ай бұрын
You probably skipped one or two important steps in the tutorial.
@TheAnimatedSquare
@TheAnimatedSquare 2 ай бұрын
Bendux, would you maybe consider making a tutorial on 2D conveyor belts? I’m made a rudimentary system using Vector2.AddForce, but I was wondering if there is a smarter way.
@TrashCoonTales
@TrashCoonTales 2 ай бұрын
Hi since u make 2d movement, could u make a video about edge skipping, so when ur bearly under a platform u get pushed, or when u miss a platform jump by a few pixels u get bumped up? Ur movement is by far the best!
@RadishMalan
@RadishMalan 2 ай бұрын
At first some stuff may fail, but once you start reading and remembering what you do and see in this tutorials you'll see success at some point
@SutKafa
@SutKafa 2 ай бұрын
nice greek video
@AlesioAlimerkaj
@AlesioAlimerkaj 2 ай бұрын
Idk why this happens but in the compoment Player Movment it only showsh Script and the name Player Movment