Forum begins after the advertisement:


[Part 15] Knife Level Up Does Not Appear

Home Forums Video Game Tutorial Series Creating a Rogue-like Shoot-em Up in Unity [Part 15] Knife Level Up Does Not Appear

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #15768
    Ariel S
    Participant
    Helpful?
    Up
    0
    ::

    Hi,
    Whenever I level up my knife weapon it does not appear after. I tried messing with the code, but nothing works. I looked at the inspector for the player whenever it levels up and the controller is still there, so I’m thinking it might have to do something with the instantiation or the prefab, but not sure. Help would be appreciated.

    #15779
    Terence
    Keymaster
    Helpful?
    Up
    0
    ::

    Make sure you assign your Knife weapon data to the Available Weapons list in the Player Inventory component.

    Available Weapons and Passives

    #15780
    Ariel S
    Participant
    Helpful?
    Up
    1
    ::

    I made sure that it is, but the prefab still does not appear whenever I level up.
    This is what it shows in the console whenever I do level up the knife (I called it dagger in mine).
    https://imgur.com/oqrYn59
    https://imgur.com/h097qRu
    https://imgur.com/w53uU7o
    Let me know if you need me to paste code in here

    #15781
    Ariel S
    Participant
    Helpful?
    Up
    1
    ::

    Nevermind, I got it to work.
    I forgot to uncomment the line

    result.projectilePrefab = s2.projectilePrefab ?? s1.projectilePrefab;

    in Weapon script.
    Thank you anyways.

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.

Go to Login Page →


Advertisement below: