public void DrawList(List <Artifact> artifactList, int selfIndex, ArtifactManagement manager) { this.manager = manager; for (int i = 0; i < artifactList.Count; i++) { ArtifactPreview preview = Instantiate(previewPrefab, holder.transform); preview.setArtifact(artifactList[i], i, selfIndex, manager); } }
public ArtifactController(ICurrentSession session) { _artifactDao = new ArtifactDAO(); _studentDAO = new StudentDAO(); _session = session; CredentialId = _session.LoggedUser.CredentialID; ArtifactManagmenet = new ArtifactManagement(); Student = _studentDAO.FindOneRecordBy(CredentialId); }
public ArtifactManagementShould() { var _mockGroupTransactionDAO = new Mock <GroupTransactionDAO>(); _mockGroupTransactionDAO.Setup(x => x.FindOneRecordBy(It.IsAny <int>())).Returns(new GroupTransaction() { ID = 1 }); _artifactManagement = new ArtifactManagement(_mockGroupTransactionDAO.Object); }
public void setArtifact(Artifact artifact, int selfIndex, int holderIndex, ArtifactManagement manager) { image.sprite = artifact.image; bonusLabel.text = artifact.bonus.ToString(); this.selfIndex = selfIndex; this.holderIndex = holderIndex; clickDetector.onClick.AddListener(() => { manager.SetSelectedArtifact(this); }); }
public CharactersActions(Button skipTurnButton, ArtifactManagement artifactManager) { skipTurnButton.onClick.AddListener(EndTurn); this.artifactManager = artifactManager; }