public void NotifyForEvent(GameEventHandler.NotifyEventTypeEnum notifyEventType, params object[] obj) { if (notifyEventType == GameEventHandler.NotifyEventTypeEnum.EventEnd) { if (Convert.ToInt64(obj[0]) == miniGameData.storyGameStartId) { StartGame(); } else if (Convert.ToInt64(obj[0]) == miniGameData.storyGameAuditId) { //显示主持人 miniGameBuilder.SetCompereCharacterActive(true); //关闭评审员的分数 CloseScoreForAudit(); //结算分数 List <NpcAIMiniGameCookingCpt> listPlayer = miniGameBuilder.GetCharacterByType(NpcAIMiniGameCookingCpt.MiniGameCookingNpcTypeEnum.Player); foreach (NpcAIMiniGameCookingCpt itemNpc in listPlayer) { itemNpc.characterMiniGameData.InitScore(); } //按分数排名 listPlayer = listPlayer.OrderByDescending(item => item.characterMiniGameData.scoreForTotal).ToList(); //打开结算UI uiMiniGameCookingSettlement = UIHandler.Instance.manager.OpenUIAndCloseOther <UIMiniGameCookingSettlement>(UIEnum.MiniGameCookingSettlement); uiMiniGameCookingSettlement.SetCallBack(this); uiMiniGameCookingSettlement.SetData(listPlayer); } } }
public void NotifyForEvent(GameEventHandler.NotifyEventTypeEnum notifyEventType, params object[] data) { if (notifyEventType == GameEventHandler.NotifyEventTypeEnum.TalkForAddFavorability) { addFavorability += (int)data[1]; } else if (notifyEventType == GameEventHandler.NotifyEventTypeEnum.EventEnd) { EventEnd(); } }
public void NotifyForEvent(GameEventHandler.NotifyEventTypeEnum notifyEventType, params object[] obj) { if (notifyEventType == GameEventHandler.NotifyEventTypeEnum.TalkForAddFavorability) { addFavorability += (int)obj[1]; } else if (notifyEventType == GameEventHandler.NotifyEventTypeEnum.EventEnd) { //根据对话的好感加成 不同的反应 if (addFavorability > 0) { SetTeamIntent(RascalIntentEnum.Leave); } else if (addFavorability < 0) { SetTeamIntent(RascalIntentEnum.MakeTrouble); } } }