mirror of
https://github.com/Melledy/Grasscutter.git
synced 2025-02-05 17:18:44 +00:00
Only load groups that have a business type of 0
This commit is contained in:
parent
b375881a3e
commit
4b5f5b3db5
@ -534,8 +534,9 @@ public class Scene {
|
|||||||
var sceneGroups = SceneIndexManager.queryNeighbors(block.sceneGroupIndex, player.getPos(), RANGE);
|
var sceneGroups = SceneIndexManager.queryNeighbors(block.sceneGroupIndex, player.getPos(), RANGE);
|
||||||
|
|
||||||
var groups = new ArrayList<>(sceneGroups.stream()
|
var groups = new ArrayList<>(sceneGroups.stream()
|
||||||
.filter(group -> !scriptManager.getLoadedGroupSetPerBlock().get(block.id).contains(group))
|
.filter(group -> !scriptManager.getLoadedGroupSetPerBlock().get(block.id).contains(group) && group.getBusinessType() == 0)
|
||||||
.peek(group -> scriptManager.getLoadedGroupSetPerBlock().get(block.id).add(group)).toList());
|
.peek(group -> scriptManager.getLoadedGroupSetPerBlock().get(block.id).add(group))
|
||||||
|
.toList());
|
||||||
|
|
||||||
if(groups.size() == 0){
|
if(groups.size() == 0){
|
||||||
return List.of();
|
return List.of();
|
||||||
|
Loading…
Reference in New Issue
Block a user