use of com.minecolonies.coremod.network.messages.server.colony.building.MarkBuildingDirtyMessage in project minecolonies by ldtteam.
the class WindowBuilderResModule method onOpened.
@Override
public void onOpened() {
super.onOpened();
pullResourcesFromHut();
final ScrollingList resourceList = findPaneOfTypeByID(LIST_RESOURCES, ScrollingList.class);
resourceList.setDataProvider(new ScrollingList.DataProvider() {
@Override
public int getElementCount() {
return resources.size();
}
@Override
public void updateElement(final int index, @NotNull final Pane rowPane) {
updateResourcePane(index, rowPane);
}
});
// Make sure we have a fresh view
Network.getNetwork().sendToServer(new MarkBuildingDirtyMessage(this.buildingView));
findPaneOfTypeByID(LABEL_CONSTRUCTION_NAME, Text.class).setText(moduleView.getConstructionName());
findPaneOfTypeByID(STEP_PROGRESS, Text.class).setText(new TranslationTextComponent("com.minecolonies.coremod.gui.progress.step", moduleView.getCurrentStage(), moduleView.getTotalStages()));
}
Aggregations