Hi,
I am getting an error when I am trying to do pickups (following integration part 1, 33 min mark). I am using the InventoryItemPickup method (1st method in tutorial).
If I leave the Prefab Attribute name blank (Image 1), I don't get any errors, however the real pickup visual is not shown, so it reverts to default visual (this is what I would expect). When you play, the Prefab Attribute Name defaults to PickupPrefab.
The way I want it to work is exactly how you are doing it in the tutorial, so I set the Prefab Attribute name to DropPrefab, however when I press play I get 4 errors (ill just post one of them for now):
Here are two images that show the InventoryItemVisualizer and my item definition.
I have UCC 2.3.2 UIS 1.1.7 and latest integration.
Do you know what the issue is?
I am getting an error when I am trying to do pickups (following integration part 1, 33 min mark). I am using the InventoryItemPickup method (1st method in tutorial).
If I leave the Prefab Attribute name blank (Image 1), I don't get any errors, however the real pickup visual is not shown, so it reverts to default visual (this is what I would expect). When you play, the Prefab Attribute Name defaults to PickupPrefab.
The way I want it to work is exactly how you are doing it in the tutorial, so I set the Prefab Attribute name to DropPrefab, however when I press play I get 4 errors (ill just post one of them for now):
NullReferenceException: Object reference not set to an instance of an object
Opsive.UltimateCharacterController.Items.Actions.ItemAction.Awake () (at Assets/Opsive/UltimateCharacterController/Scripts/Items/Actions/ItemAction.cs:59)
Opsive.UltimateCharacterController.Items.Actions.UsableItem.Awake () (at Assets/Opsive/UltimateCharacterController/Scripts/Items/Actions/UsableItem.cs:124)
Opsive.UltimateCharacterController.Items.Actions.ShootableWeapon.Awake () (at Assets/Opsive/UltimateCharacterController/Scripts/Items/Actions/ShootableWeapon.cs:375)
UnityEngine.Object:Instantiate(GameObject, Vector3, Quaternion, Transform)
Opsive.Shared.Game.ObjectPoolBase:InstantiateInternal(GameObject, Int32, Vector3, Quaternion, Transform)
Opsive.Shared.Game.ObjectPoolBase:InstantiateInternal(GameObject, Vector3, Quaternion, Transform)
Opsive.Shared.Game.ObjectPoolBase:Instantiate(GameObject, Vector3, Quaternion, Transform)
Opsive.Shared.Game.ObjectPoolBase:Instantiate(GameObject, Transform)
Opsive.UltimateInventorySystem.DropsAndPickups.ItemVisualizerBase:SetVisualInternal(ItemInfo) (at Assets/Opsive/UltimateInventorySystem/Scripts/DropsAndPickups/ItemVisualizerBase.cs:152)
Opsive.UltimateInventorySystem.DropsAndPickups.ItemVisualizerBase:UpdateVisual(ItemInfo) (at Assets/Opsive/UltimateInventorySystem/Scripts/DropsAndPickups/ItemVisualizerBase.cs:89)
Opsive.UltimateInventorySystem.DropsAndPickups.InventoryItemVisualizer:UpdateVisual() (at Assets/Opsive/UltimateInventorySystem/Scripts/DropsAndPickups/InventoryItemVisualizer.cs:78)
Opsive.UltimateInventorySystem.DropsAndPickups.ItemVisualizerBase:OnEnable() (at Assets/Opsive/UltimateInventorySystem/Scripts/DropsAndPickups/ItemVisualizerBase.cs:74)
Opsive.UltimateInventorySystem.DropsAndPickups.InventoryItemVisualizer:OnEnable() (at Assets/Opsive/UltimateInventorySystem/Scripts/DropsAndPickups/InventoryItemVisualizer.cs:48)
Here are two images that show the InventoryItemVisualizer and my item definition.
I have UCC 2.3.2 UIS 1.1.7 and latest integration.
Do you know what the issue is?