Walk, Idle, and Turn Around: Action RPG in Unity Tutorial #2

Поділитися
Вставка
  • Опубліковано 26 лис 2024

КОМЕНТАРІ • 16

  • @anoushmistry
    @anoushmistry 6 місяців тому +3

    Yay another video ❤️❤️

  • @kamm3021
    @kamm3021 3 місяці тому +1

    This is very helpful
    Thanks for making this series

    • @NightRunStudio
      @NightRunStudio  3 місяці тому +1

      You’re welcome! Glad to hear when people find the series helpful!

  • @Mavs_GT
    @Mavs_GT 6 місяців тому +1

    hi thank you i just finished your inventory system, do u know how use the block from inventory and place it on tile? like minecraft but 2d

    • @NightRunStudio
      @NightRunStudio  6 місяців тому

      I'm afraid that's a whole tutorial in itself. I know that Muddy Wolf has a video on Destructible Tiles and another on Spawning Tiles. I haven't tried them myself, but I know people who've found them useful. That might be a good place to start looking.

  • @paweswiezy578
    @paweswiezy578 Місяць тому

    I cant get access to full version of TinySwords, only like a Demo one, got any clue where can i find all the graphics?

    • @NightRunStudio
      @NightRunStudio  Місяць тому

      This is where I got it from: pixelfrog-assets.itch.io/tiny-swords/download/eyJpZCI6MTU5MTA3NywiZXhwaXJlcyI6MTcyODY3MTk4MX0%3d.iZd9E%2bburlTI7OBFGcq6dBGmCMQ%3d
      That should get you the full version that I'm using.

  • @anoushmistry
    @anoushmistry 6 місяців тому +1

    I just used the pre made animations given in the asset pack and I am using a blend tree for idle and movement related animations. Is that okay? 🤔

    • @NightRunStudio
      @NightRunStudio  6 місяців тому +1

      That should be just fine. Later, we will add a simple state machine to our code for controlling the player's different states and animations. At that time, you may have to do a little adjusting, but it shouldn't be a big deal.

    • @anoushmistry
      @anoushmistry 6 місяців тому +1

      @@NightRunStudio Thanks a lot

  • @snookems17
    @snookems17 6 місяців тому +1

    Why is your code for the flipping so complicated? I used these lines and it works just fine.
    if(theRB.velocity.x > 0)
    {
    transform.localScale = Vector3.one;
    }
    if (theRB.velocity.x < 0)
    {
    transform.localScale = new Vector3(-1f, 1f, 0);
    }

    • @NightRunStudio
      @NightRunStudio  6 місяців тому +1

      We will build on it later, so having facingDirection stored will come in handy. Also, as movement scripts grow, separating concerns (like Flipping) into their own methods is considered best practice (that way we don't get monster scripts that are hard to read, where Update is packed with stuff).
      The other reason is that Vector3.one only works if people don't touch their scale. If they re-size their scale, Vector3.one suddenly introduces scaling issues.

    • @atilliator
      @atilliator 2 місяці тому +1

      @@NightRunStudio spriteRenderer.flipX = true;

    • @NightRunStudio
      @NightRunStudio  2 місяці тому

      @atilliator that one is super helpful if all you need is to flip the sprite. But if you are going to add children that also need to flip (like weapons, health bar, etc) rotate works nicely.