So, some of the code shown down below, was once working perfectly fine without any errors until I duplicated the blueprint for another weapon. I thought deleting the duplicated blueprint would be the solution, so that any chance that there’s any conflicting code would be impossible, but It still doesn’t work. Now, when I hit the button, nothing happens. I looked through the blueprints over a dozen times, and I can’t figure it out.
Code in FirstPersonBlueprint for Equipping the P2K:
well everything here is depending on a valid reference, so have you tried converting the reference to a validated get and plugging some print strings into the Failed output?
that’s where I would start - make sure the references are good.
You can also double check that the events are able to fire at all by setting them to call in editor (select the node, check in details panel for that)
(oh and double check the boolean is working as intended, or probably just remove it temporarily as you first test the references)
Everything appears to be valid. I placed Print strings in sections of both the P2K Blueprint and the FirstPersonBlueprint and all of them were working. I removed Boolean conditions and double checked them to make sure that it works and there as no errors.
But it’s still not working.
At this point, I think my best solution is to delete the blueprint and try to rebuild it.
you can right click, go to asset actions, and reload.
you can also restart the project.
also check for redirectors and fix those up.
Lastly, nuking and rebuilding is worst case scenario. If you have version control enabled, you can check the blueprint diffs, or you could just undo the changes to that class in the change log.
I figured out the issue. I deleted the Root Component Node that was attached to the Child Actor shown in the post above and replaced it with the default P2K, which solved the visibility issue.
The enabling and disabling functions issue was solved by BIGTIMEMASTER in his suggestion to reload the blueprint in asset actions. Thank you very much.