Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Add Item into Character's Array From Box Trigger

I'm working on my first RPG in Unreal and I'm having trouble setting up the inventory system. My initial thoughts were to store all the stats and items inside the ThirdPersonCharacter blueprint because I wanted them to carry over from level to level without having to copy it over everytime.

So, I have an array called "Inventory" which will hold all the items (potions, weapons, armor, etc) in the ThirdPersonCharacter blueprint and a box trigger that holds an item I want to add to the character's inventory. Upon overlap and when the player hits the return key, I call a funtion "AddToInventory" inside the character's blueprint which should take the item from the trigger box and add it to the Inventory array. Think of it like walking up to a treasure chest, hitting a button and collecting an item. However, I keep getting the same error and I don't know why. I've been struggling with this for the past week and nothing I've tried works. All the tutorials I've looked at were very basic movement operations on an actor and didn't really help in my case. If anyone has any experience or knowledge on this, I would greatly appreciate the help!

[1]: /storage/temp/92188-error.jpg

Product Version: UE 4.11
characterbp.jpg (194.6 kB)
toyboxtrigger.jpg (190.4 kB)
error.jpg (49.3 kB)
more ▼

asked May 27 '16 at 03:00 AM in Blueprint Scripting

avatar image


(comments are locked)
10|2000 characters needed characters left
Viewable by all users

0 answers: sort voted first
Be the first one to answer this question
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question