They are correct, you need to pass in the inventory array for all entities, not completely ignore it. It's simple to do, and as a note, there are quite a few mods out there that add more armor slots and thus would screw up with you hardcoding it to 4.