Updating an object value in a nested array

Thank you @santimir ,

The document looks like Pavel suggested

{
   "pity":[
      { "type":"weapon", "totalWishes":0 },
      { "type":"character", "totalWishes":0 },
      { "type":"standard", "totalWishes":0 }
   ]
}

However, I’ve tried what Pavel suggested before I made this post, and not even that worked. The expected output is actually to increment totalWishes, but I thought there was an issue with using the $inc operator so I tried using $set to no avail.