question

duartedd avatar image
duartedd asked

item class showing up old value instead of new

Hey

2HWeapon + F622F87ABD71021D

i debug logged this output with the below command

Debug.Log(item.ItemClass + " + " + item.ItemInstanceId);

its calling the item in my item database on playfab - I had an old class name of 2HWeapon which i updated AFTER i granted the character this item

so i thought okay i would go in it through the character inventory and check to see if i can change THAT item in playfab thinking it will be 2HWeapon...it just takes me to the actual item (i know this because the class was the correct one i wanted and NOT 2HWeapon)

anywho i revoked the item and just granted that item and that fixed the issue but was wondering is this as design....do the items not keep synced up?

for instance if i said sword of light give +1 attack

then i say later on

i want to change it for that sword of light gives +2 attack cause its to weak compared to other things...i would have to revoke all the sword of light items and then provide them back?

thanks!

daniel

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

·
brendan avatar image
brendan answered

Properties that are part of the InventoryItemInstance are set when you create the item in the player or character inventory - they do not change if you update the catalog. If you want to have the catalog be authoritative, make sure to use the catalog as the source of truth. That can be done for properties that are on the instance - just ignore the instance, and use what's in the catalog definition.

3 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

duartedd avatar image duartedd commented ·

hmm i think i can work around it how you are saying but i need the instanceid from one character to another....
so basically what you are saying is

get the display name (or something else that would match up to the catalog and NOT be changed and is unique to other items) from the item instance -

then search the catalog using that display name and get that item classname from there

did i understand that right? ie no magical checkbox that says keep data synced with catalog item

0 Likes 0 ·
duartedd avatar image duartedd duartedd commented ·

i mean itemid not display name

0 Likes 0 ·
duartedd avatar image duartedd duartedd commented ·

thanks fixed! - to the item i added the catalog reference this way whenever you pull the item you can reference the catalog from that item ..thanks again!

0 Likes 0 ·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.