Fix: full network stack refactor

This commit is contained in:
2026-06-14 13:31:32 +02:00
parent b11027a251
commit 3888529b96
27 changed files with 347 additions and 276 deletions
@@ -191,10 +191,82 @@ public class MiniModel implements Serializable {
*
* @param standingPlayers the final ordered list of players.
*/
public void setStandingPlayers(ArrayList<Player> standingPlayers) {
public void setStandingPlayers(List<Player> standingPlayers) {
this.standingPlayers = standingPlayers;
}
/**
* Replaces the upper row of tribe cards on the board.
*
* @param cards the new upper tribe card list.
*/
public void setUpperListTribeCards(ArrayList<TribeCard> cards) {
this.upperListTribeCards = cards;
}
/**
* Replaces the lower row of tribe cards on the board.
*
* @param cards the new lower tribe card list.
*/
public void setLowerListTribeCards(ArrayList<TribeCard> cards) {
this.lowerListTribeCards = cards;
}
/**
* Replaces the upper row of building cards on the board.
*
* @param cards the new upper building card list.
*/
public void setUpperListBuildingCards(ArrayList<BuildingCard> cards) {
this.upperListBuildingCards = cards;
}
/**
* Replaces the lower row of building cards on the board.
*
* @param cards the new lower building card list.
*/
public void setLowerListBuildingCards(ArrayList<BuildingCard> cards) {
this.lowerListBuildingCards = cards;
}
/**
* Removes the card at the given position from the upper tribe card list.
*
* @param pos the zero-based index of the card to remove.
*/
public void removeUpperTribeCard(int pos) {
if (upperListTribeCards != null) upperListTribeCards.remove(pos);
}
/**
* Removes the card at the given position from the lower tribe card list.
*
* @param pos the zero-based index of the card to remove.
*/
public void removeLowerTribeCard(int pos) {
if (lowerListTribeCards != null) lowerListTribeCards.remove(pos);
}
/**
* Removes the card at the given position from the upper building card list.
*
* @param pos the zero-based index of the card to remove.
*/
public void removeUpperBuildingCard(int pos) {
if (upperListBuildingCards != null) upperListBuildingCards.remove(pos);
}
/**
* Removes the card at the given position from the lower building card list.
*
* @param pos the zero-based index of the card to remove.
*/
public void removeLowerBuildingCard(int pos) {
if (lowerListBuildingCards != null) lowerListBuildingCards.remove(pos);
}
/**
* Returns the position of the player with the specified username
* within the player collection.