# Should I clear arrays of pointers before saving struct to GameSave?

**URL:** <https://forums.unrealengine.com/t/should-i-clear-arrays-of-pointers-before-saving-struct-to-gamesave/751456>\
**Category:** Programming & Scripting\
**Tags:** unreal-engine, question, CPP\
**Created:** [January 17, 2023, 6:06pm UTC](https://forums.unrealengine.com/t/should-i-clear-arrays-of-pointers-before-saving-struct-to-gamesave/751456 "2023-01-17T18:06:14Z")\
**Posts on this page:** 1\
**Showing post:** 22

<div class="post-metadata">

**Author:** ![MaxCambs](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/maxcambs/32/625703_2.png) [@MaxCambs](https://forums.unrealengine.com/u/MaxCambs)\
**Post date:** [February 24, 2023, 11:32am UTC](https://forums.unrealengine.com/t/should-i-clear-arrays-of-pointers-before-saving-struct-to-gamesave/751456/22 "2023-02-24T11:32:21Z")

</div>

As promised I have put up a complete example solution on my private GitHub:

> **[GitHub - lumyx2/SavingTest: Saving/Loading Serialisation Example (Unreal 5.1)](https://github.com/lumyx2/SavingTest)**
>
> Saving/Loading Serialisation Example (Unreal 5.1). Contribute to lumyx2/SavingTest development by creating an account on GitHub.

Hopefully, it helps future visitors. This would not have been possible without the help and guidance of @Chatouille.

Cheers!  
M

---

_[View the full topic](https://forums.unrealengine.com/t/should-i-clear-arrays-of-pointers-before-saving-struct-to-gamesave/751456)._
