gpt4 book ai didi

ios - 前台应用程序事件超过 100%?

转载 作者:行者123 更新时间:2023-11-29 00:40:32 26 4
gpt4 key购买 nike

我刚刚监控我的 iOS 游戏的能源使用情况,发现前台应用程序事件通常高达 126%。我只是想知道这是我应该关心的事情吗?能源使用量显示恒定值 1/20--- 但时间列始终为“00:00 - 00:00”,所以我有点困惑这意味着什么。

此外,有没有办法在我的应用程序中禁用蓝牙、GPS,因为这些功能未使用?我认为它们会有助于某种能源的使用。仪器显示除了状态为“开启”且时间为“00:00”之外没有其他信息。

enter image description here

最佳答案

基于 Apple 文档:https://developer.apple.com/library/content/documentation/Performance/Conceptual/EnergyGuide-iOS/MonitorEnergyWithInstruments.html

The Energy Usage instrument indicates a level from 0 to 20, indicating how much energy your app is using at any given time. These numbers are subjective. If your app’s energy usage level is occasionally high, it doesn’t necessarily mean that your app has a problem. Your app may simply require more energy for some of the tasks it performs. For example, it may use the GPS while performing complex network operations. This is valid energy use. What you should look for are spikes or areas of high energy use that are unexpected or that could be performed at more optimal times.

我认为我不会太担心你所看到的事情。你的 FPS 是多少?你保持 60 fps 吗?您的主要时间都花在前台应用程序上,因此如果您想减少它的时间,您应该查看 CPU 正在做什么。如果您想看看是否可以提高性能,请查看 Time Profiler。

话虽这么说,我认为用户确实意识到,如果你在玩游戏,电池生命周期会受到影响。然而,该评论应该根据游戏类型进行调整。如果您在玩井字游戏时耗尽了电池的电量,我想您会感到惊讶。

您没有办法(这不会让您被拒绝)强行关闭某些功能。即使你可以,你也可能最终会招致愤怒的用户。假设您使用的是蓝牙耳机……然后您关闭了蓝牙?

只要确保你的游戏很有趣,人们就会原谅你;)

关于ios - 前台应用程序事件超过 100%?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/39629236/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com