I used command blocks to constantly set all arrows' life data tag to zero, keeping them perpetually young. I expected that this would stop them from despawning, and it did, but arrows still turn invisible after one minute. Reloading the chunks does nothing. Closing the world and reopening it makes arrows visible for another minute.
- Set up a repeating command block using the command below to keep arrows from despawning
Optionally, you can also have it run the command below to show that the arrows are still there
- Fire some arrows
- Wait one minute for arrows to turn invisible
- Test that they are still there (they can be picked up, targeted in commands, etc)
Based on 1.13.1 decompiled using MCPConfig.
It appears the underlying problem is that the client destroys the entity. Usually only the server should destroy the entity and then inform the client about this.
While in this case sending the life value to the client would solve this specific problem, it would not solve other problems caused by the above described situation, for example when the client incorrectly thinks the arrow is ground, destroying it after a certain amount of time.