# My Game Stops or Lagging Sometime

**URL:** <https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365>\
**Category:** Blueprint\
**Tags:** unreal-engine, iOS, Blueprint, question\
**Created:** [May 27, 2023, 2:37pm UTC](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365 "2023-05-27T14:37:37Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![bimhs](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@bimhs](https://forums.unrealengine.com/u/bimhs)\
**Post date:** [May 27, 2023, 2:37pm UTC](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365/1 "2023-05-27T14:37:37Z")

</div>

When I test my game in iPhoneXS, It stops sometimes.  
If you see the video, the little square doesn’t move smoothly and stops shortly in the middle of controlling.  
What I did is simplely keep pressing the joystick.  
And in the game, It spawn background and blocks at first, and it spawn next background and blocks if the little square passed end of current backgraund.

It also happen when I made realy simple sprite charater moving on empty ground.

Is there any setting about moblie optimizing?  
Am I spawning too much things?  
Please help me.

 ![KakaoTalk_20230527_165907386](https://d3kjluh73b9h9o.cloudfront.net/original/4X/e/9/f/e9f11918f4cf0576fbeb0486353d7c4e9b63d58b.jpeg)

[https://d3kjluh73b9h9o.cloudfront.net/original/4X/8/c/8/8c8d3e37cd349ac2f824d8e8969c396dd543b041.mp4](https://d3kjluh73b9h9o.cloudfront.net/original/4X/8/c/8/8c8d3e37cd349ac2f824d8e8969c396dd543b041.mp4)

---

<div class="post-metadata">

**Author:** ![3dRaven](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/3draven/32/906552_2.png) [@3dRaven](https://forums.unrealengine.com/u/3dRaven)\
**Post date:** [May 27, 2023, 6:29pm UTC](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365/2 "2023-05-27T18:29:55Z")

</div>

Seem that in places you are getting high frame times

`Frame time is the total amount of time spent generating one frame of the game. Since both the Game and Draw threads sync up before finishing a frame, Frame time is often close to the time being shown in one of these threads.`

Are you modifying many dynamic materials? Do you have many overlapping transparent objects?

In the editor try running the shader complexity view F5, and see if you have green (good) or red and white (bad) areas.

This thread might help too

> [@Mobile - lags on the first run](https://forums.unrealengine.com/t/mobile-lags-on-the-first-run/469176):
>
> I am creating a mobile game for both Android and IOS platforms. I have one issue on every device on a first run. The game freezes when any asset first time appears on the scene(static mesh, particle, etc.). Second and further runs I have stable 60 fps with no freezes. Any advice would be great.

---

<div class="post-metadata">

**Author:** ![bimhs](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@bimhs](https://forums.unrealengine.com/u/bimhs)\
**Post date:** [May 28, 2023, 11:21pm UTC](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365/3 "2023-05-28T23:21:35Z")

</div>

Thank you for help!  
Actually those big blocks are dynamic mesh.

 ![20230529_001910_001](https://d3kjluh73b9h9o.cloudfront.net/original/4X/5/8/a/58a1ab34512e8c2c441dbb8fbba3ddc3eeff0a29.png)

I though it’s okay as it’s simple box…  
Is it normal to got this kind of frame drop for like 10 dynamic mesh in mobile game?

and is collision count as transparent objects?

Also I could see it’s red when I view via F5…

 ![20230529_001649_001](https://d3kjluh73b9h9o.cloudfront.net/original/4X/6/5/3/6536b13bc6fa3e9c24773f689d563ee2183e5755.png)

---

<div class="post-metadata">

**Author:** ![3dRaven](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/3draven/32/906552_2.png) [@3dRaven](https://forums.unrealengine.com/u/3dRaven)\
**Post date:** [May 29, 2023, 12:03am UTC](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365/4 "2023-05-29T00:03:24Z")

</div>

The red is probably overdraw so lots of unneeded overlapping. Dynamic mesh can be pretty intensive if done often.

---

<div class="post-metadata">

**Author:** ![bimhs](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@bimhs](https://forums.unrealengine.com/u/bimhs)\
**Post date:** [May 29, 2023, 3:39pm UTC](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365/5 "2023-05-29T15:39:08Z")

</div>

Thank you for your help again!  
I’ve reduced dynamic mesh and it’s not red anymore but I still have frame drop…

 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/7/6/3/763aa67e727e754d69f03adff327abc8cefc61dc.png)  

[https://d3kjluh73b9h9o.cloudfront.net/original/4X/9/0/5/90599e64d075e655ee5114cde4400d7bc20e4eac.mp4](https://d3kjluh73b9h9o.cloudfront.net/original/4X/9/0/5/90599e64d075e655ee5114cde4400d7bc20e4eac.mp4)

---

<div class="post-metadata">

**Author:** ![3dRaven](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/3draven/32/906552_2.png) [@3dRaven](https://forums.unrealengine.com/u/3dRaven)\
**Post date:** [May 29, 2023, 3:57pm UTC](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365/6 "2023-05-29T15:57:15Z")

</div>

Is the stutter happening when you are Applying mesh booleans?

---

<div class="post-metadata">

**Author:** ![bimhs](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@bimhs](https://forums.unrealengine.com/u/bimhs)\
**Post date:** [May 29, 2023, 4:14pm UTC](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365/7 "2023-05-29T16:14:03Z")

</div>

The big block only spawn when next stage spawned.  
So in that video there is noting newly spawned.

BTW the big block is made like this video.

# Geometry Script Tutorial - Destructible Wall at Runtime in Unreal Engine 5 | Bool Mesh Operation

![](https://d3kjluh73b9h9o.cloudfront.net/optimized/4X/b/2/6/b261fe7b346fc15f31a8099caf6b6a7a37e53a2c_2_690x388.jpeg)https://www.youtube.com/embed/ITP_8DqFZ-c?feature=oembed&wmode=opaque&list=WL

---

<div class="post-metadata">

**Author:** ![3dRaven](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/3draven/32/906552_2.png) [@3dRaven](https://forums.unrealengine.com/u/3dRaven)\
**Post date:** [May 29, 2023, 4:33pm UTC](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365/8 "2023-05-29T16:33:15Z")

</div>

The stutters seem to be at rather even time intervals. Are you calling a function by timer set on loop or do you have a tick event with longer intervals running?

---

<div class="post-metadata">

**Author:** ![bimhs](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@bimhs](https://forums.unrealengine.com/u/bimhs)\
**Post date:** [May 29, 2023, 4:42pm UTC](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365/9 "2023-05-29T16:42:06Z")

</div>

You are right! it seems like stutter is happen with intervals. (even though I don’t move!)  
I remove all blocks and it still happened.  
The only tick event I have is to moving camera…

 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/9/7/d/97d059398617435d1ce454aef9a4558a9f1bc60c.png)  

[https://d3kjluh73b9h9o.cloudfront.net/original/4X/3/3/5/335efd35cedcaa680adacaa3ed60db61a2a9bcda.mp4](https://d3kjluh73b9h9o.cloudfront.net/original/4X/3/3/5/335efd35cedcaa680adacaa3ed60db61a2a9bcda.mp4)

---

<div class="post-metadata">

**Author:** ![3dRaven](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/3draven/32/906552_2.png) [@3dRaven](https://forums.unrealengine.com/u/3dRaven)\
**Post date:** [May 29, 2023, 4:47pm UTC](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365/10 "2023-05-29T16:47:43Z")

</div>

Try going into all actors & components and check if tick is enabled in the details panel (it is on by default). If you don’t need tick somewhere then turn it off.

---

<div class="post-metadata">

**Author:** ![bimhs](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@bimhs](https://forums.unrealengine.com/u/bimhs)\
**Post date:** [May 29, 2023, 5:54pm UTC](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365/11 "2023-05-29T17:54:38Z")

</div>

It still happen even though I removed everything in the map.  
And it feels like it stutters more often.  
Do you have any clue what is effect?  
 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/d/c/7/dc7667b4f84e39e74e37c8b99f4f68b1742f93e8.png)

[https://d3kjluh73b9h9o.cloudfront.net/original/4X/4/3/9/439bb88533e60026d5bca61ad5fd5c28663fda07.mp4](https://d3kjluh73b9h9o.cloudfront.net/original/4X/4/3/9/439bb88533e60026d5bca61ad5fd5c28663fda07.mp4)
  
 ![KakaoTalk_20230529_185904256](https://d3kjluh73b9h9o.cloudfront.net/original/4X/c/5/b/c5b6dd714d9e42b400c95ea4b4a0c25e23e87d97.jpeg)

---

<div class="post-metadata">

**Author:** ![3dRaven](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/3draven/32/906552_2.png) [@3dRaven](https://forums.unrealengine.com/u/3dRaven)\
**Post date:** [May 29, 2023, 6:01pm UTC](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365/12 "2023-05-29T18:01:56Z")

</div>

You could try setting the project properties regarding shadows & switching to classic “Shadow maps”. It should be more performant.

I’ll have to look into the red bottom warning with GC. I’m guessing it has something to do with garbage collection. If you are rapidly creating and destroying objects it will trigger stutters and garbage collection.

If so you should introduce some sort of object pooling

![txt2](https://d3kjluh73b9h9o.cloudfront.net/original/4X/4/f/5/4f5f2bc3c1b22d460179b5e45b4fb9ba03fbc088.png)

“Click the dropdown arrow next to Perspective in the viewport, go to Stat → Hide All.”

---

<div class="post-metadata">

**Author:** ![bimhs](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@bimhs](https://forums.unrealengine.com/u/bimhs)\
**Post date:** [May 29, 2023, 6:32pm UTC](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365/13 "2023-05-29T18:32:34Z")

</div>

I couldn’t find Stat → Hide all  
Is this the one you said?  
 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/3/4/6/34613309f444fa6ab4beb4625e1634f46d676783.png)

---

<div class="post-metadata">

**Author:** ![3dRaven](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/3draven/32/906552_2.png) [@3dRaven](https://forums.unrealengine.com/u/3dRaven)\
**Post date:** [May 29, 2023, 6:34pm UTC](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365/14 "2023-05-29T18:34:26Z")

</div>

Click the three lines next to the perspective cube icon =\> click the checkbox “Show Stats” so that it is unchecked.

---

<div class="post-metadata">

**Author:** ![bimhs](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@bimhs](https://forums.unrealengine.com/u/bimhs)\
**Post date:** [May 29, 2023, 6:40pm UTC](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365/15 "2023-05-29T18:40:33Z")

</div>

I unchecked it! It was checked originally.

 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/8/b/6/8b66fbeb76a06db5d77325d228787dfd5ba729c2.jpeg)

---

<div class="post-metadata">

**Author:** ![bimhs](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@bimhs](https://forums.unrealengine.com/u/bimhs)\
**Post date:** [May 29, 2023, 8:22pm UTC](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365/16 "2023-05-29T20:22:32Z")

</div>

It also happen when I build empty map and new project.  
Is it like Unreal engine bug?

---

<div class="post-metadata">

**Author:** ![3dRaven](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/3draven/32/906552_2.png) [@3dRaven](https://forums.unrealengine.com/u/3dRaven)\
**Post date:** [May 29, 2023, 8:25pm UTC](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365/17 "2023-05-29T20:25:03Z")

</div>

Could it be that your target device has too low specifications for unreal?

---

<div class="post-metadata">

**Author:** ![bimhs](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@bimhs](https://forums.unrealengine.com/u/bimhs)\
**Post date:** [May 29, 2023, 8:25pm UTC](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365/18 "2023-05-29T20:25:59Z")

</div>

I don’t think so… It’s iPhoneXS and it stuttered when I tested in iPad pro 13

---

<div class="post-metadata">

**Author:** ![3dRaven](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/3draven/32/906552_2.png) [@3dRaven](https://forums.unrealengine.com/u/3dRaven)\
**Post date:** [May 29, 2023, 8:26pm UTC](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365/19 "2023-05-29T20:26:52Z")

</div>

Did you turn off lumen? Probably not needed for a mobile game and it might be pretty taxing hardware wise.

Also try console comand stat unitGraph. It will show which part of the engine is stalling over time as a graph. So you can see where it spikes in processing.

---

<div class="post-metadata">

**Author:** ![bimhs](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@bimhs](https://forums.unrealengine.com/u/bimhs)\
**Post date:** [May 29, 2023, 9:15pm UTC](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365/20 "2023-05-29T21:15:18Z")

</div>

I noticed that there is some log in device log.  
Is this mean something?

May 29 18:09:35 Test2[27647] : [UE] [2023.05.29-17.09.35:629][199]LogUdpMessaging: Warning: Failed to join multicast group ‘[::ffff:230.0.0.1]:6666’ on detected local interface ‘2a01:4c8:c002:5bff:e5ac:b16d:148e:1c7f’  
May 29 18:09:35 Test2[27647] : [UE] [2023.05.29-17.09.35:629][199]LogUdpMessaging: Warning: Failed to join multicast group ‘[::ffff:230.0.0.1]:6666’ on detected local interface ‘2a01:4c8:c002:5bff:ed49:d25d:1e2a:8058’  
May 29 18:09:35 Test2[27647] : [UE] [2023.05.29-17.09.35:629][199]LogUdpMessaging: Warning: Failed to join multicast group ‘[::ffff:230.0.0.1]:6666’ on detected local interface ‘2a00:23ee:1c50:3cfe:4dff:c2de:7a20:3626’  
May 29 18:09:35 Test2[27647] : [UE] [2023.05.29-17.09.35:629][199]LogUdpMessaging: Warning: Failed to join multicast group ‘[::ffff:230.0.0.1]:6666’ on detected local interface ‘2a00:23ee:1c50:3cfe:6dc1:317c:eba:362e’  
May 29 18:09:35 Test2[27647] : [UE] [2023.05.29-17.09.35:629][199]LogUdpMessaging: Warning: Failed to join multicast group ‘[::ffff:230.0.0.1]:6666’ on detected local interface ‘fe80::1:1:1eb7:ff4b’  
May 29 18:09:35 Test2[27647] : [UE] [2023.05.29-17.09.35:629][199]LogUdpMessaging: Warning: Failed to join multicast group ‘[::ffff:230.0.0.1]:6666’ on detected local interface ‘2a01:4c8:c002:5bff:186d:6853:19e4:3f16’  
May 29 18:09:35 Test2[27647] : [UE] [2023.05.29-17.09.35:629][199]LogUdpMessaging: Warning: Failed to join multicast group ‘[::ffff:230.0.0.1]:6666’ on detected local interface ‘192.0.0.2’  
May 29 18:09:35 Test2[27647] : [UE] [2023.05.29-17.09.35:632][199]LogUdpMessaging: Warning: UDP messaging encountered an error. Auto repair routine started for reinitialization

 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/8/6/2/862e0a604b17e3e3c8d5481d71bf56e557160206.png)  

[https://d3kjluh73b9h9o.cloudfront.net/original/4X/d/f/b/dfb5e3fb0024a6884a3a8c1cbf553b7f04bbc08c.mp4](https://d3kjluh73b9h9o.cloudfront.net/original/4X/d/f/b/dfb5e3fb0024a6884a3a8c1cbf553b7f04bbc08c.mp4)

[Next page](https://forums.unrealengine.com/t/my-game-stops-or-lagging-sometime/1180365.md?page=2)
