public IConteneurCarte getConteneur() { if (CarteUtils.checkCarteActive(this)) { return(transform.GetComponentInParent <IConteneurCarte> ()); } else { return(null); } }
public void usePoseConstructionCapacity(NetworkInstanceId netIdJoueur, CarteMetierAbstract carteSourceAction, ISelectionnable cible, NetworkInstanceId netIdTaskEvent) { if (CarteUtils.checkCarteActive(this) && (this.getConteneur() is EmplacementMetierAbstract || carteSourceAction.netId == this.netId)) { List <CapaciteDTO> capacitePoseConstruction = getListCapaciteToCall(netIdJoueur, carteSourceAction.netId, ConstanteIdObjet.ID_CONDITION_ACTION_POSE_CONSTRUCTION); foreach (CapaciteDTO capacite in capacitePoseConstruction) { CapaciteUtils.callCapacite(this, carteSourceAction, cible, capacite, netIdJoueur, ConstanteIdObjet.ID_CONDITION_ACTION_POSE_CONSTRUCTION, netIdTaskEvent); } } }