# Game Instance doesn't work in packaged game

**URL:** <https://forums.unrealengine.com/t/game-instance-doesnt-work-in-packaged-game/397106>\
**Category:** Platform & Builds\
**Tags:** game-instance, unreal-engine, packaging-projects, question\
**Created:** [July 7, 2017, 11:33am UTC](https://forums.unrealengine.com/t/game-instance-doesnt-work-in-packaged-game/397106 "2017-07-07T11:33:01Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mempsis](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Mempsis](https://forums.unrealengine.com/u/Mempsis)\
**Post date:** [July 7, 2017, 11:33am UTC](https://forums.unrealengine.com/t/game-instance-doesnt-work-in-packaged-game/397106/1 "2017-07-07T11:33:01Z")

</div>

I packaged my game and managed to make it run. Soon I noticed a problem with booleans located in my custom Game Instance, since their value is not changing. What could be causing the problem?

---

<div class="post-metadata">

**Author:** ![Ninjin](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Ninjin](https://forums.unrealengine.com/u/Ninjin)\
**Post date:** [July 7, 2017, 12:02pm UTC](https://forums.unrealengine.com/t/game-instance-doesnt-work-in-packaged-game/397106/2 "2017-07-07T12:02:30Z")

</div>

Did you changed the GameInstance in your Project Settings by any chance? \<3

---

<div class="post-metadata">

**Author:** ![Mempsis](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Mempsis](https://forums.unrealengine.com/u/Mempsis)\
**Post date:** [July 7, 2017, 12:05pm UTC](https://forums.unrealengine.com/t/game-instance-doesnt-work-in-packaged-game/397106/3 "2017-07-07T12:05:33Z")

</div>

Yes I did, forgot to mention that!

---

<div class="post-metadata">

**Author:** ![Mempsis](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Mempsis](https://forums.unrealengine.com/u/Mempsis)\
**Post date:** [July 10, 2017, 6:52am UTC](https://forums.unrealengine.com/t/game-instance-doesnt-work-in-packaged-game/397106/4 "2017-07-10T06:52:12Z")

</div>

Okay what’s even more weird is that the Game Instance actually works partly. Like it stores the location of an object between levels if I move it but somehow when I use a boolean in my player controller’s tick event, that doesn’t work at all. I even tried to change the boolean to a switch but there’s no effect.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_a8729913](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_a8729913](https://forums.unrealengine.com/u/anonymous_user_a8729913)\
**Post date:** [November 30, 2017, 7:05am UTC](https://forums.unrealengine.com/t/game-instance-doesnt-work-in-packaged-game/397106/5 "2017-11-30T07:05:34Z")

</div>

Did you already find a solution? same problem here 😉

---

<div class="post-metadata">

**Author:** ![JonathanArmstrong](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@JonathanArmstrong](https://forums.unrealengine.com/u/JonathanArmstrong)\
**Post date:** [August 12, 2019, 12:27am UTC](https://forums.unrealengine.com/t/game-instance-doesnt-work-in-packaged-game/397106/6 "2019-08-12T00:27:36Z")

</div>

This fixes it (have to rename the instance object in the DefaultEngine.ini project file): [https://answers.unrealengine.com/questions/595245/casting-to-game-instance-always-fails-when-packagi.html?sort=oldest](https://answers.unrealengine.com/questions/595245/casting-to-game-instance-always-fails-when-packagi.html?sort=oldest)

---

<div class="post-metadata">

**Author:** ![yuki0okami](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/yuki0okami/32/564279_2.png) [@yuki0okami](https://forums.unrealengine.com/u/yuki0okami)\
**Post date:** [November 30, 2022, 12:14am UTC](https://forums.unrealengine.com/t/game-instance-doesnt-work-in-packaged-game/397106/7 "2022-11-30T00:14:26Z")

</div>

For me the solution was to move Cast To Game Instance nodes  
from my character Construction Script  
to my character Event Begin Play
