ValkyrienSkies / Valkyrien-Skies-2

Valkyrien Skies 2
https://valkyrienskies.org/
GNU Lesser General Public License v3.0
220 stars 92 forks source link

Too many physics frames in the physics frame queue. Is the game stage broken? #909

Open stepsword opened 1 month ago

stepsword commented 1 month ago

Mod Name

Mahou Tsukai

This issue occurs when only Valkyrien Skies, addons, and the mod I have specified are installed and no other mods

Minecraft Version

1.16

Mod Loader

Forge

Issue description

2024-07-20-7.log Hi, a user sent me this log, which only happens on servers. Apparently their game sort of hangs after a while after placing down a block from Mahou Tsukai. I haven't tried to replicate it, but the blocks they noted as having the problem tend to be ones which get nearby entities in the world, something like this:

if (livingOnly) {
    List<LivingEntity> entities = this.level.getEntitiesOfClass(LivingEntity.class, aabb, Entity::isAlive);
    doBarrier(entities);
    entitiesInBarrier = new HashSet<>(entities.stream().map(LivingEntity::getUUID).collect(Collectors.toCollection(HashSet::new)));
} else {
    List<Entity> entities = this.level.getEntitiesOfClass(Entity.class, aabb, Entity::isAlive);
    doBarrierNonLiving(entities);
}

I noticed that ValkyrienSkies has a hook in to the getEntities() method which may or may not be causing issues, so hopefully this is useful information..

Issue reproduction

The user said just placing one of the boundaries in Mahou Tsukai in the overworld caused the issue, not even when on a ship, and that it only happened on a dedicated server and not in single player. You can try by getting a "scroll of life drain boundary" from the mahou tsukai creative menu and right clicking the floor somewhere.

Logs

see above

thetheaplant commented 1 month ago

Can you recreate the issue yourself, with no other mods than the specified one present?

stepsword commented 1 month ago

i can't, no, I tried with just my mod, VS, and eureka. i do have like 32GB RAM though on my system, so it's possible that that is a contributing factor, as this has a similar message #891 and someone said it was related to the memory leak issue #525