Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Couple minor tweaks - logic hardening and memory #4365

Merged
merged 2 commits into from
Jan 2, 2021

Conversation

Cervator
Copy link
Member

@Cervator Cervator commented Jan 2, 2021

Part of some minor observations from recent testing.

  • Guards against NPE in some behavior tree code, briefly discussed with @casals as a case where some state might get lost. Ideally we'd also hook up a special monitor for this via telemetry to get more intel about when it happens, how
  • Increases default memory when running from Gradle - flying around in settings like Metal Renegades does not appreciate being memory starved. Goes beyond the 32-bit JVM capacity, but we honestly could have probably done that years ago, playing the game on 32-bit is one thing, developing it a whole other thing.

…sionally, leave todo to capture it for telemetry as well
@Cervator Cervator added the Category: Build/CI Requests, Issues and Changes targeting gradle, groovy, Jenkins, etc. label Jan 2, 2021
@@ -102,6 +102,12 @@ public void update(float delta) {
Iterable<EntityRef> entities = entityManager.getEntitiesWith(BehaviorComponent.class);
for (EntityRef entity : entities) {
BehaviorComponent behaviorComponent = entity.getComponent(BehaviorComponent.class);
// NPE observed in the past, suspected to be about loss of behavior state. Hopefully one skip is OK then resume next tick?
// TODO: Highlight this log entry to the telemetry system to gather better data over time
if (behaviorComponent.interpreter == null) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, the behavior stuff is still part of the engine o.O

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't really remember why that particular piece is still in there 🤔

@skaldarnar skaldarnar added this to the v4.2.0 milestone Jan 2, 2021
@skaldarnar skaldarnar changed the title Couple minor tweaks - logic hardening and memory chore: Couple minor tweaks - logic hardening and memory Jan 2, 2021
@skaldarnar skaldarnar merged commit d1476d4 into MovingBlocks:develop Jan 2, 2021
@Cervator Cervator deleted the coupleTweaks branch January 2, 2021 21:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Category: Build/CI Requests, Issues and Changes targeting gradle, groovy, Jenkins, etc.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants