Exemple #1
0
 void Awake()
 {
     _buttonCommands  = new string[3];
     _buttonTexts     = new string[3];
     _resultDescs     = new string[3];
     _resultsAndDescs = new ResultAndDesc();
     _originPos       = new Vector3(0, 39, 0);
 }
Exemple #2
0
 public void EventCaculate()
 {
     mimic = true;
     _cardScript.SetFrontDesc(DataPool._current._ScriptionDic["FindBox"]
                              [Random.Range(0, DataPool._current._ScriptionDic["FindBox"].Count)]);
     _resultAndDesc = CaculateScript.TreasureEncounter(mimic);
     _result        = (TreasureResult[])_resultAndDesc.result;
     _cardScript.CardSetting(_resultAndDesc.desc);
     _cardScript.SetFrontDesc(DataPool._current._ScriptionDic["FindBox"]
                              [Random.Range(0, DataPool._current._ScriptionDic["FindBox"].Count)]);
 }
    public void EventCaculateAfter(ObjectInfo enemy)
    {
        //적 생성
        _enemyInfo  = (EnemyObjInfo)enemy;
        _eventCount = 1;

        _enemyObjCtrl.OnObject();

        _resultAndDesc = CaculateScript.MonsterEncounter(_enemyInfo);
        _result        = (MonsterResult[])_resultAndDesc.result;
        _cardScript.CardSetting(_resultAndDesc.desc);
    }
    public static ResultAndDesc TreasureEncounter(bool mimic)
    {
        ResultAndDesc rd = new ResultAndDesc();

        TreasureResult[] result = new TreasureResult[3];
        result[0]  = TreasureOpen(mimic);
        result[1]  = TreasureSkip();
        result[2]  = TreasureBroken(mimic);
        rd.desc[0] = "1번";
        rd.desc[1] = "2번";
        rd.desc[2] = "3번";
        rd.SetResult(result);
        return(rd);
    }
    public static ResultAndDesc ShrineEncounter()
    {
        ResultAndDesc rd = new ResultAndDesc();

        ShrineResult[] result = new ShrineResult[3];
        //타입 설정하는 함수 필요
        result[0]  = GetShrineEffect();
        result[1]  = null;
        result[2]  = null;
        rd.desc[0] = "1번";
        rd.desc[1] = "2번";
        rd.desc[2] = "";
        rd.SetResult(result);
        return(rd);
    }
    public void EventCaculate()
    {
        //적 생성
        _enemyInfo = (EnemyObjInfo)DataPool._current._eventObjDic["Monster"]
                     [Random.Range(0, DataPool._current._eventObjDic["Monster"].Count)].Clone();
        _eventCount = 0;

        _enemyObjCtrl.OnObject();

        _resultAndDesc = CaculateScript.MonsterEncounter(_enemyInfo);
        _result        = (MonsterResult[])_resultAndDesc.result;
        _cardScript.CardSetting(_resultAndDesc.desc);
        _cardScript.SetFrontDesc(DataPool._current._ScriptionDic["EncounterMessage"]
                                 [Random.Range(0, DataPool._current._ScriptionDic["EncounterMessage"].Count)]);
    }
Exemple #7
0
    public void EventCaculate()
    {
        //오브젝트 그림 생성
        //_ShrineInfo

        _ObejctCtrl.OnObject();

        _resultAndDesc = CaculateScript.ShrineEncounter();
        _result        = (ShrineResult[])_resultAndDesc.result;


        _cardScript.CardSetting(_resultAndDesc.desc);
        _cardScript.SetFrontDesc("신단을 발견했다.");
        CommandArrange();
    }
    public static ResultAndDesc MonsterEncounter(ObjectInfo enemy)
    {
        ResultAndDesc rd = new ResultAndDesc();

        MonsterResult[] result = new MonsterResult[3];
        result[0] = PlayerAttack(enemy);
        result[1] = PlayerEscape(enemy);
        result[2] = PlayerSurprise(enemy);

        rd.desc[0] = "성공확률 : " + result[0]._frequency + " %" + "\n" +
                     "성공시 : " + result[0]._success + " 데미지의 공격" + "\n" +
                     "실패시 : 패널티 없음";
        rd.desc[1] = "성공확률 : " + result[1]._frequency + " %" + "\n" +
                     "성공시 : " + "도망" + "\n" +
                     "실패시 : 피격률 100%";
        rd.desc[2] = "성공확률 : " + result[2]._frequency + " %" + "\n" +
                     "성공시 : " + result[2]._success + " 데미지의 공격" + "\n" +
                     "실패시 : 다음 피격 2배";
        rd.SetResult(result);

        return(rd);
    }