Part 1: UI Creation and Game Pause -- Let's Make An Inventory System in Unity!

Поделиться
HTML-код
  • Опубликовано: 19 дек 2024

Комментарии •

  • @CELUGames
    @CELUGames 20 дней назад +3

    Great tutorial, friend! Just one detail for everyone: make sure the type is "Key or Mouse Button", otherwise the inout Inventory won't work!

    • @NightRunStudio
      @NightRunStudio  20 дней назад +1

      Good point! Definitely important to remember that.

  • @stephenq24
    @stephenq24 Год назад +3

    So far, so good. Your videos are great. Give the channel time and keep adding quality content. Trust me, it will grow. There is a great demand for Unity tutorials.

    • @NightRunStudio
      @NightRunStudio  Год назад

      Thanks for that! As much as I'd love to reach a larger audience, it's still super encouraging to know the vids are helping people. Thanks for sharing.

  • @justinbale6074
    @justinbale6074 Год назад +2

    Love the tutorials! Your guides are easy to follow and very informative. I'll be keeping my eye out for more videos. Keep up the excellent work, and thank you!

    • @NightRunStudio
      @NightRunStudio  Год назад +1

      Thanks for sharing that! I love hearing that the vids are working for people.

  • @magstargaming2193
    @magstargaming2193 Год назад +3

    Love this waiting for more parts. Finally a simple inventory system that i can add in my platformer game

    • @NightRunStudio
      @NightRunStudio  Год назад

      Thanks a bunch! I'll try to keep rolling out the videos as quickly as possible.

  • @cheftechnique
    @cheftechnique 7 месяцев назад +1

    Thank You this actually made sense and was so easy to set up because you took the time to explain clearly and simply without too much extra info. You saved me!

    • @NightRunStudio
      @NightRunStudio  7 месяцев назад

      So glad to hear it! Thanks for taking the time to share this.

  • @racrity
    @racrity 9 месяцев назад +1

    Thank you so much for this! Clear and refreshing as college sumer vodka nights.

    • @NightRunStudio
      @NightRunStudio  9 месяцев назад

      That's the greatest simile I've ever had applied to me :)

  • @IzzWizard
    @IzzWizard 7 месяцев назад +1

    About to start this list of tuts. Thank you for making them.

    • @NightRunStudio
      @NightRunStudio  7 месяцев назад +1

      Hope you find them helpful!

    • @IzzWizard
      @IzzWizard 7 месяцев назад +1

      @@NightRunStudio I know I will. Already am

  • @kucirulz
    @kucirulz 10 месяцев назад +1

    Any simple way to create the blank/"empty" sprite you use for the series?

    • @NightRunStudio
      @NightRunStudio  10 месяцев назад

      You could:
      Create a new Sprite by going to "Assets" > "Create" > 2D > "Sprite".
      Set the Texture Type to "Sprite (2D and UI)".
      In the Texture Import Settings, set the Texture Shape to "2D" and the Alpha Source to "None".
      Save the sprite asset.

    • @kucirulz
      @kucirulz 10 месяцев назад

      @@NightRunStudio When creating it, how do you stop at "Sprite" without choosing the last option where you need to pick a form?

    • @NightRunStudio
      @NightRunStudio  10 месяцев назад

      Sorry… you do have to pick one but then making it default to 0 alpha should do the trick.

    • @NightRunStudio
      @NightRunStudio  10 месяцев назад

      If you open up the advanced tab on the inspector,you should be able to set alpha source to none

    • @kucirulz
      @kucirulz 10 месяцев назад

      @@NightRunStudio Thank you for replies! I can't make it work but I will try again later. I set the Alpha Source to none but that does not make the random sprite I chose invisible.

  • @the_smiling_child
    @the_smiling_child Месяц назад +1

    Hi, I have a problem, I setted up the e buton but it doesn't work

    • @NightRunStudio
      @NightRunStudio  Месяц назад

      Which spot did you put it in the input manager?

    • @the_smiling_child
      @the_smiling_child Месяц назад

      @NightRunStudio InventoryMenu

    • @NightRunStudio
      @NightRunStudio  Месяц назад

      Did you replace an existing button or make a new one? If the button isn’t doing anything, it’s possible you have it set up for a mouse or joystick instead of a key press. That’s one reason I usually suggest using the existing Fire buttons as they are set up properly for key inputs.

    • @the_smiling_child
      @the_smiling_child Месяц назад +1

      @NightRunStudio It's made for joystick, thank you

  • @saide7674
    @saide7674 9 месяцев назад +1

    hi for some reason when i press the letter nothing happens.

    • @NightRunStudio
      @NightRunStudio  9 месяцев назад +1

      Do you have your buttons set up in the Input Manager?

    • @TweetyStickFigure
      @TweetyStickFigure 7 месяцев назад

      @@NightRunStudiohow do I set that up? I don’t have it.

    • @NightRunStudio
      @NightRunStudio  7 месяцев назад +1

      @@TweetyStickFigure We do it at 6:10 in the video.

    • @TweetyStickFigure
      @TweetyStickFigure 7 месяцев назад +1

      @@NightRunStudio sorry I thought there was some settings I had to alter. I re watched it though thank you. Very useful tutorial (:

  • @seaderwerks3046
    @seaderwerks3046 Год назад +1

    Interesting. Only first episode, copied your input settings, along with your set up and script and set everything up, yet after entering play mode and pressing E, nothing happens. I can turn on the inventorymenu from the hierarchy, but after pressing e again it just closes and nothing happens after that. cannot reopen it. Wonder why.

    • @seaderwerks3046
      @seaderwerks3046 Год назад +7

      Ahh, fixed it. Seems even after adding an "Inventory" to my input manager and making the positive T for it, nothing continued to happen, So.
      I added this line of code in replacement of this
      (Input.GetKeyDown(KeyCode.T) && menuActivated)
      (Input.GetKeyDown(KeyCode.T) && !menuActivated)
      This resolved my issue. So if you don't want to go playing with the input setting within unity due to different types of input controls, this might fix what is blocking you.

    • @NightRunStudio
      @NightRunStudio  Год назад

      Thanks for sharing another way to do this! I imagine some people will find that super helpful!

    • @seaderwerks3046
      @seaderwerks3046 Год назад

      @@NightRunStudio On Episode 3 now lets see if I can get this inventory system to work. :P

  • @IIDMovieWerx
    @IIDMovieWerx Год назад +1

    I like your style and this tutorial seems easy to follow however i am getting a error can you help ?? this is the error "
    InvalidOperationException: You are trying to read Input using the UnityEngine.Input class, but you have switched active Input handling to Input System package in Player Settings.
    InventoryManager.Update () (at Assets/InventoryManager.cs:19)
    I think its using a input system but I am having trouble adapting your info to it?
    thanks
    Frank

    • @NightRunStudio
      @NightRunStudio  Год назад +2

      Thanks for watching! I haven't come across this issue before, but I suspect (as you said) that it comes from the new input system. I did a quick search, and found this post
      stackoverflow.com/questions/65027247/unity-conflict-between-new-inputsystem-and-old-eventsystem
      which may be helpful for updating settings in order to get things working. Hopefully that clears up the issue for you.

  • @copycoffee7
    @copycoffee7 Год назад +1

    Hi Night Run, I seem to be getting a bug where if I open my menu in the air, then I stay frozen in the air. When I try to move again my character flips but stays above the ground. Any reason this is happening??

    • @NightRunStudio
      @NightRunStudio  Год назад

      It sounds to me like your game is not un-pausing when you leave the menu. I suspect that your player flip is being called from FixedUpdate(which runs independent of the timescale method we are using to pause the game). That's why you can still flip the character, but you can't move because the game is still paused.
      I would double check that you are unpausing the game when leaving the menu. If you want to fix the player flipping issue, you will have to manually turn off flipping when you pause (the easiest is probably just to disable your playerController at the same time that you call the pause, and then re-enable it when you un-pause.
      I hope that helps!

    • @copycoffee7
      @copycoffee7 Год назад +1

      @@NightRunStudio it worked, Thanks!

    • @NightRunStudio
      @NightRunStudio  Год назад

      Awesome! So glad you figured it out.

  • @ML-lm2dr
    @ML-lm2dr 25 дней назад

    i hawe no errors popingout but when i press the inventorry button it the inventorry doesnot show up

    • @NightRunStudio
      @NightRunStudio  25 дней назад

      Have you tried adding a debug log to make sure the button press is registering?

  • @alialbadry-u4m
    @alialbadry-u4m Год назад +1

    u are the best 💜

  • @SaphireDO
    @SaphireDO Год назад

    How do i make inventory with infinity slots and scrollbar?

    • @NightRunStudio
      @NightRunStudio  Год назад +1

      An infinite inventory would need a slightly different setup; however, with this system, you could set it up with as many slots as you want (thousands....). You would just want to add a scroll bar so that you can move around in your inventory. It would take a whole extra video to get into that, but if you want to check out scroll bars, Unity does a lesson them here: ruclips.net/video/JpmQuLdLct4/видео.html

  • @JoshuaTreeJoinery
    @JoshuaTreeJoinery Месяц назад +1

    great vid man, did anyone ever tell you you sound just like the lock picking lawyer?

    • @NightRunStudio
      @NightRunStudio  Месяц назад

      Haha. Nope, that’s definitely a first! Glad you enjoyed the video.

  • @Unknown-e5z7y
    @Unknown-e5z7y 7 месяцев назад

    How do you express HP in numbers?

    • @NightRunStudio
      @NightRunStudio  7 месяцев назад

      I'm not totally sure what you mean... like do you just want your health to be displayed on screen: 13/15 sort of thing?

    • @Unknown-e5z7y
      @Unknown-e5z7y 7 месяцев назад

      @@NightRunStudio Yes, Which of your lectures should I refer to?

    • @NightRunStudio
      @NightRunStudio  7 месяцев назад

      @@Unknown-e5z7y If you want a numerical system, this one should get you started: ruclips.net/video/cFtCCOVee40/видео.htmlsi=X_FxShaoCKLzPqD8

    • @Unknown-e5z7y
      @Unknown-e5z7y 7 месяцев назад +1

      @@NightRunStudio Thank you!

  • @coreygrace8937
    @coreygrace8937 10 месяцев назад +1

    this is lit!! lol

  • @trollgasm
    @trollgasm Год назад +1

    Already excited to get through this set of tutorials. Making a Metroidvania called Wheel King for a game jam! All very informative.

    • @NightRunStudio
      @NightRunStudio  Год назад

      Sounds like an ambitious project for a jam! Best of luck with it.