Serialized Form
-
Package it.polimi.ingsw.gc14.Model
-
Class it.polimi.ingsw.gc14.Model.Game
class Game extends Object implements Serializable-
Serialized Fields
-
board
Board board
The board associated with this game. -
currentState
CurrentState currentState
The current state of the game. -
disconnectedPlayers
Map<Player,
Boolean> disconnectedPlayers Map tracking the players who are currently disconnected. Key: player; value:trueif currently disconnected,falseif reconnected. -
nPlayers
int nPlayers
The configured number of players for this game. -
optionalCardQueue
Queue<Player> optionalCardQueue
The queue of players involved in optional card resolution. -
orderLogicCard
OrderLogicCard orderLogicCard
The order logic card associated with this game. -
playersList
ArrayList<Player> playersList
The list of players participating in the game. -
playerStanding
ArrayList<Player> playerStanding
The final ranking of players at the end of the game. -
slotMap
HashMap<Slot,
Player> slotMap The mapping between slots and the players assigned to them. -
totemChoiceQueue
Queue<Player> totemChoiceQueue
Queue containing the players who still have to choose their totem.
-
-
-
Class it.polimi.ingsw.gc14.Model.MiniModel
class MiniModel extends Object implements Serializable-
Serialized Fields
-
availableTotems
List<Totems> availableTotems
List of totems still available for selection. -
currentState
CurrentState currentState
Current state of the game. -
disconnectedPlayers
ArrayList<String> disconnectedPlayers
Usernames of players currently disconnected from the game. -
lastEvent
NetworkEvent lastEvent
The most recent network event applied to this model. -
lowerListBuildingCards
ArrayList<BuildingCard> lowerListBuildingCards
Lower row of building cards currently on the board. -
lowerListTribeCards
ArrayList<TribeCard> lowerListTribeCards
Lower row of tribe cards currently on the board. -
orderLogicCard
OrderLogicCard orderLogicCard
Card used to manage the player turn order. -
players
Map<String,
Player> players Map of players indexed by username. -
slotPlayerMap
Map<Slot,
Player> slotPlayerMap Map associating each occupied slot with the corresponding player. -
standingPlayers
List<Player> standingPlayers
Final standing of the players at the end of the game. -
upperListBuildingCards
ArrayList<BuildingCard> upperListBuildingCards
Upper row of building cards currently on the board. -
upperListTribeCards
ArrayList<TribeCard> upperListTribeCards
Upper row of tribe cards currently on the board.
-
-
-
Class it.polimi.ingsw.gc14.Model.OrderLogicCard
class OrderLogicCard extends Object implements Serializable-
Serialized Fields
-
playerList
List<OrderPlayer> playerList
The list ofOrderPlayerentries tracking turn order and played status. Protected so subclasses can read it for display purposes (e.g.,Object.toString()). -
players
Queue<Player> players
The queue ofPlayersassociated with this order logic card.
-
-
-
Class it.polimi.ingsw.gc14.Model.PlayableCard
class PlayableCard extends Object implements Serializable-
Serialized Fields
-
era
int era
The era associated with this playable card. -
idIMG
String idIMG
The image identifier of the playable card.
-
-
-
Class it.polimi.ingsw.gc14.Model.Player
class Player extends Object implements Serializable-
Serialized Fields
-
artists
ArrayList<Artist> artists
The currentArtistcards in the player's deck. -
builders
ArrayList<Builder> builders
The currentBuildercards in the player's deck. -
buildingCards
ArrayList<BuildingCard> buildingCards
The currentBuilding Cardsin the player's deck. -
foodValue
int foodValue
The current amount ofFoodthe Player possesses. Cannot be negative. -
gatherers
ArrayList<Gatherer> gatherers
The currentGatherercards in the player's deck. -
hunters
ArrayList<Hunter> hunters
The currentHuntercards in the player's deck. -
inventors
ArrayList<Inventor> inventors
The currentInventorcards in the player's deck. -
prestigeValue
int prestigeValue
The current amount ofPrestigethe Player possesses. -
shamans
ArrayList<Shaman> shamans
The currentShamancards in the player's deck. -
totem
Totems totem
Identifier for thePlayerwhen displaying the game through the GUI.- See Also:
-
userName
String userName
Unique string identifier for players; must not benulland must not exceedPlayer.MAX_USERNAME_LENGTHotherwise anIllegalArgumentExceptionwill be thrown when theconstructoris called.
-
-
-
Class it.polimi.ingsw.gc14.Model.Slot
class Slot extends Object implements Serializable-
Serialized Fields
-
food
int food
The amount of Food associated with this slot. -
nLower
int nLower
The number of lower cards associated with this slot. -
nMinPlayer
int nMinPlayer
The minimum number of players required for this slot. -
nUpper
int nUpper
The number of upper cards associated with this slot. -
slotId
char slotId
The identifier of this slot.
-
-
-
-
Package it.polimi.ingsw.gc14.Model.Cards
-
Class it.polimi.ingsw.gc14.Model.Cards.BuildingCard
class BuildingCard extends PlayableCard implements Serializable-
Serialized Fields
-
bought
boolean bought
Indicates whether this building card has already been bought. -
effectId
int effectId
The identifier of the effect associated with this building card. -
effectType
EffectType effectType
The type of effect associated with this building card. -
prestigeValue
int prestigeValue
The prestige value of this building card. -
price
int price
The price of this building card.
-
-
-
Class it.polimi.ingsw.gc14.Model.Cards.TribeCard
class TribeCard extends PlayableCard implements Serializable-
Serialized Fields
-
isEventCard
boolean isEventCard
Indicates whether this tribe card is an event card. -
nMin
int nMin
The minimum number of players required for this tribe card.
-
-
-
-
Package it.polimi.ingsw.gc14.Model.Cards.Building.Effects
-
Class it.polimi.ingsw.gc14.Model.Cards.Building.Effects.Building0
class Building0 extends BuildingCard implements Serializable-
Serialized Fields
-
numSet
int numSet
Number of complete character sets already counted by this building effect. -
purchased
boolean purchased
Indicates whether the building effect has already been initialized after purchase.
-
-
-
Class it.polimi.ingsw.gc14.Model.Cards.Building.Effects.Building1
class Building1 extends BuildingCard implements Serializable-
Serialized Fields
-
icon
CharacterType icon
Character type involved in the building effect.
-
-
-
Class it.polimi.ingsw.gc14.Model.Cards.Building.Effects.Building10
class Building10 extends BuildingCard implements Serializable -
Class it.polimi.ingsw.gc14.Model.Cards.Building.Effects.Building11
class Building11 extends BuildingCard implements Serializable-
Serialized Fields
-
characterType
CharacterType characterType
The character type involved in this building effect. -
prestigeMul
int prestigeMul
The prestige multiplier applied per matching character card at end of game.
-
-
-
Class it.polimi.ingsw.gc14.Model.Cards.Building.Effects.Building13
class Building13 extends BuildingCard implements Serializable -
Class it.polimi.ingsw.gc14.Model.Cards.Building.Effects.Building4
class Building4 extends BuildingCard implements Serializable-
Serialized Fields
-
numPair
int numPair
Number of inventor pairs already counted by this building effect. -
purchased
boolean purchased
Indicates whether the building effect has already been initialized after purchase.
-
-
-
Class it.polimi.ingsw.gc14.Model.Cards.Building.Effects.Building8
class Building8 extends BuildingCard implements Serializable
-
-
Package it.polimi.ingsw.gc14.Model.Cards.TribeCards
-
Class it.polimi.ingsw.gc14.Model.Cards.TribeCards.Character
class Character extends TribeCard implements Serializable-
Serialized Fields
-
type
CharacterType type
The specific type of this character card.
-
-
-
Class it.polimi.ingsw.gc14.Model.Cards.TribeCards.EventCard
class EventCard extends TribeCard implements Serializable-
Serialized Fields
-
type
EventType type
The specific type of this event card.
-
-
-
-
Package it.polimi.ingsw.gc14.Model.Cards.TribeCards.Characters
-
Class it.polimi.ingsw.gc14.Model.Cards.TribeCards.Characters.Artist
class Artist extends Character implements Serializable -
Class it.polimi.ingsw.gc14.Model.Cards.TribeCards.Characters.Builder
class Builder extends Character implements Serializable-
Serialized Fields
-
prestigeValue
int prestigeValue
The prestige value provided by this Builder card. -
reductionValue
int reductionValue
The reduction value provided by this Builder card.
-
-
-
Class it.polimi.ingsw.gc14.Model.Cards.TribeCards.Characters.Gatherer
class Gatherer extends Character implements Serializable -
Class it.polimi.ingsw.gc14.Model.Cards.TribeCards.Characters.Hunter
class Hunter extends Character implements Serializable-
Serialized Fields
-
icon
boolean icon
Describes whether theHunter Iconis present or not. Whenever anHunterwith anHunter Iconis added to the tribe, 1Food tokenis awarded for each Hunter in the tribe (with or without an icon).
-
-
-
Class it.polimi.ingsw.gc14.Model.Cards.TribeCards.Characters.Inventor
class Inventor extends Character implements Serializable-
Serialized Fields
-
icon
int icon
TheIcons's ID. There are a total of 10 different Icons.
-
-
-
Class it.polimi.ingsw.gc14.Model.Cards.TribeCards.Characters.Shaman
class Shaman extends Character implements Serializable-
Serialized Fields
-
icon
int icon
The number of starIconsthe card possesses. During theShamanic Ritual Event, having the majority of these icons provides Prestige Points; having the minority, on the other hand, results in losing Prestige Points.
-
-
-
-
Package it.polimi.ingsw.gc14.Model.Cards.TribeCards.Events
-
Class it.polimi.ingsw.gc14.Model.Cards.TribeCards.Events.CavePaintings
class CavePaintings extends EventCard implements Serializable-
Serialized Fields
-
nLower
int nLower
The minimum number of Artist cards required to avoid the prestige penalty. Also, the bottom number on the card. -
nPrestigeMul
int nPrestigeMul
The Prestige multiplier applied if the player has at leastnLowerArtist cards. -
nPrestigeRem
int nPrestigeRem
The amount of Prestige removed if the player has fewer Artist cards thannLower.
-
-
-
Class it.polimi.ingsw.gc14.Model.Cards.TribeCards.Events.Hunt
class Hunt extends EventCard implements Serializable-
Serialized Fields
-
prestigeMultiplier
int prestigeMultiplier
Prestige Points multiplier used during the event.
-
-
-
Class it.polimi.ingsw.gc14.Model.Cards.TribeCards.Events.ShamanicRitual
class ShamanicRitual extends EventCard implements Serializable-
Serialized Fields
-
prestigeToAdd
int prestigeToAdd
Prestige points awarded to the player with the most shaman icons. -
prestigeToRemove
int prestigeToRemove
Prestige points removed from the player with the fewest shaman icons.
-
-
-
Class it.polimi.ingsw.gc14.Model.Cards.TribeCards.Events.Sustenance
class Sustenance extends EventCard implements Serializable-
Serialized Fields
-
prestigeDebt
int prestigeDebt
The prestige penalty multiplier applied for each unpaid Food unit.
-
-
-
-
Package it.polimi.ingsw.gc14.Model.GamePackage
-
Class it.polimi.ingsw.gc14.Model.GamePackage.Board
class Board extends Object implements Serializable-
Serialized Fields
-
buildingCardsAllEras
ArrayList<List<BuildingCard>> buildingCardsAllEras
All building card lists grouped by era; index 0 = era 1, index 1 = era 2, etc. -
era
int era
Current era of the game -
lowerListBuilding
List<BuildingCard> lowerListBuilding
Contains all the building cards of the lower list. When a new era starts, the old era's buildings are moved from the upper to the lower list. -
lowerListTribe
List<TribeCard> lowerListTribe
The lower row of the tribe card. During the first round, there will be (num. of players + 1) character cards. During the following rounds, lower row will be emptied and populated with upper row's cards. When an Event card gets in the lower row, the event effect will be activated at the end of the round. -
nTotem
int nTotem
Number of players -
slotList
List<Slot> slotList
slotList contains the ordered list of slots (tiles). The slots changes based on the number of players. Each slot (tile) has special action as drawing from the upper/lower row or taking food. -
tribeDeck
Queue<TribeCard> tribeDeck
tribeDeck is the deck from where you draw tribe cards as characters and events. -
upperListBuilding
List<BuildingCard> upperListBuilding
Contains all the building cards of the upper list. When a new era starts, all its building cards are placed here. -
upperListTribe
List<TribeCard> upperListTribe
The upper row of tribe cards. It contains a total ofnTotem + 4tribe cards, which may include both character and event cards.
-
-
-
Class it.polimi.ingsw.gc14.Model.GamePackage.CurrentState
class CurrentState extends Object implements Serializable-
Serialized Fields
-
era
int era
The current era of the game. -
gameStage
GameStages gameStage
The current stage of the game. -
nLower
int nLower
The number of lower cards currently available. -
nUpper
int nUpper
The number of upper cards currently available. -
player
Player player
The current player associated with the game state. -
round
int round
The current round of the game. -
slot
Slot slot
The current slot associated with the game state.
-
-
-
-
Package it.polimi.ingsw.gc14.Model.Orders
-
Class it.polimi.ingsw.gc14.Model.Orders.Order2
class Order2 extends OrderLogicCard implements Serializable -
Class it.polimi.ingsw.gc14.Model.Orders.Order3
class Order3 extends OrderLogicCard implements Serializable -
Class it.polimi.ingsw.gc14.Model.Orders.Order4
class Order4 extends OrderLogicCard implements Serializable -
Class it.polimi.ingsw.gc14.Model.Orders.Order5
class Order5 extends OrderLogicCard implements Serializable -
Class it.polimi.ingsw.gc14.Model.Orders.OrderPlayer
class OrderPlayer extends Object implements Serializable-
Serialized Fields
-
played
boolean played
Indicates whether the player has already played. -
player
Player player
The player associated with this order entry.
-
-
-
-
Package it.polimi.ingsw.gc14.Network
-
Class it.polimi.ingsw.gc14.Network.NetworkEvent
class NetworkEvent extends Object implements Serializable-
Serialized Fields
-
currentState
CurrentState currentState
Current state of the game associated with the event. -
disconnectedPlayers
ArrayList<String> disconnectedPlayers
Usernames of players currently disconnected from the game. Sent with every event so clients always have an up-to-date list. -
errorType
ErrorType errorType
The error type associated with this event; set when the event failed to apply. -
eventType
EventType eventType
Type of the network event. -
isError
boolean isError
Flag indicating whether the event could not be applied successfully. -
orderLogicCard
OrderLogicCard orderLogicCard
Order logic card used to manage the player turn order. -
playerList
List<Player> playerList
List of all players. -
slotPlayerMap
Map<Slot,
Player> slotPlayerMap Map associating each occupied slot with the corresponding player. -
username
String username
Username of the player requesting the event.
-
-
-
-
Package it.polimi.ingsw.gc14.Network.NetworkEvents
-
Class it.polimi.ingsw.gc14.Network.NetworkEvents.AddPlayer
class AddPlayer extends NetworkEvent implements Serializable-
Serialized Fields
-
proposedNPlayer
int proposedNPlayer
Number of players proposed by this player; used only when creating a new game.
-
-
-
Class it.polimi.ingsw.gc14.Network.NetworkEvents.ApplyNextRound
class ApplyNextRound extends NetworkEvent implements Serializable-
Serialized Fields
-
lowerListBuildingCards
ArrayList<BuildingCard> lowerListBuildingCards
Building cards shown in the lower row of the board for the new round. -
lowerListTribeCards
ArrayList<TribeCard> lowerListTribeCards
Tribe cards shown in the lower row of the board for the new round. -
upperListBuildingCards
ArrayList<BuildingCard> upperListBuildingCards
Building cards shown in the upper row of the board for the new round. -
upperListTribeCards
ArrayList<TribeCard> upperListTribeCards
Tribe cards shown in the upper row of the board for the new round.
-
-
-
Class it.polimi.ingsw.gc14.Network.NetworkEvents.DisconnectedPlayer
class DisconnectedPlayer extends NetworkEvent implements Serializable -
Class it.polimi.ingsw.gc14.Network.NetworkEvents.DrawLowerBuildingCard
class DrawLowerBuildingCard extends NetworkEvent implements Serializable-
Serialized Fields
-
pos
int pos
Index of the card to draw
-
-
-
Class it.polimi.ingsw.gc14.Network.NetworkEvents.DrawLowerTribeCard
class DrawLowerTribeCard extends NetworkEvent implements Serializable-
Serialized Fields
-
pos
int pos
Index of the card to draw
-
-
-
Class it.polimi.ingsw.gc14.Network.NetworkEvents.DrawUpperBuildingCard
class DrawUpperBuildingCard extends NetworkEvent implements Serializable-
Serialized Fields
-
pos
int pos
Index of the card to draw
-
-
-
Class it.polimi.ingsw.gc14.Network.NetworkEvents.DrawUpperTribeCard
class DrawUpperTribeCard extends NetworkEvent implements Serializable-
Serialized Fields
-
pos
int pos
Index of the card to draw
-
-
-
Class it.polimi.ingsw.gc14.Network.NetworkEvents.EndedGame
class EndedGame extends NetworkEvent implements Serializable -
Class it.polimi.ingsw.gc14.Network.NetworkEvents.ReconnectPlayer
class ReconnectPlayer extends NetworkEvent implements Serializable -
Class it.polimi.ingsw.gc14.Network.NetworkEvents.SkipTurn
class SkipTurn extends NetworkEvent implements Serializable -
Class it.polimi.ingsw.gc14.Network.NetworkEvents.SlotChoice
class SlotChoice extends NetworkEvent implements Serializable-
Serialized Fields
-
pos
int pos
Index of the selected slot.
-
-
-
Class it.polimi.ingsw.gc14.Network.NetworkEvents.TotemChoice
class TotemChoice extends NetworkEvent implements Serializable
-
-
Package it.polimi.ingsw.gc14.Network.RMI.Client
-
Class it.polimi.ingsw.gc14.Network.RMI.Client.ClientCallbackImpl
class ClientCallbackImpl extends UnicastRemoteObject implements Serializable-
Serialized Fields
-
clientController
ClientController clientController
The client controller used to apply events and update the model
-
-
-
-
Package it.polimi.ingsw.gc14.Network.RMI.Common
-
Package it.polimi.ingsw.gc14.Network.RMI.Server
-
Class it.polimi.ingsw.gc14.Network.RMI.Server.RMIServer
class RMIServer extends UnicastRemoteObject implements Serializable-
Serialized Fields
-
actionQueue
BlockingQueue<NetworkEvent> actionQueue
Shared queue to which player actions are added for sequential processing. -
clients
Map<String, IClientCallback> clients
username → callback -
controller
GameController controller
Server-side game controller; all model access is synchronized on this object. -
host
String host
Hostname or IP address exposed by the RMI runtime (java.rmi.server.hostname). -
nPort
int nPort
Port on which the RMI registry is bound. -
playerList
LimitedMap<String,
Boolean> playerList Shared map tracking each player's connection status (true= online). -
watchdogs
Map<String, RMIHeartbeat> watchdogs
username → watchdog. One watchdog per connected player, mirrorspendingHeartbeat/ per-socket HeartbeatHandler in the TCP stack.
-
-
-