Beispiel #1
0
 void FubenDoEvent()
 {
     log("执行点位事件");
     MiniFport.access(cm, FrontPort.FUBEN_EXECUTE_EVENT, (msg) => {
         FubenGotoNext();
     });
 }
Beispiel #2
0
 void FubenGotoNext()
 {
     log("往下走");
     pointIndex++;
     MiniFport.access(cm, FrontPort.FUBEN_GET_CURRENT, (msg11) => {
         int curSid = StringKit.toInt((msg11.getValue("sid") as ErlType).getValueString());
         if (curSid == 0)
         {
             fuben();
         }
         else
         {
             MiniFport.access(cm, FrontPort.FUBEN_GOTO, (msg22) => {
                 ErlType rt = msg22.getValue("msg") as ErlType;
                 string str = rt != null ? rt.getValueString() : "";
                 if (str == "no_fb")
                 {
                     fuben(missionSid);
                 }
                 else if (str == "not_goto" || str == "goto_point")
                 {
                     //FubenGetEventInfo();
                     StartCoroutine(Utils.DelayRun(FubenGetEventInfo, Random.Range(5, 8)));
                 }
                 else
                 {
                     fuben(missionSid - 1 > 41001?missionSid - 1:41001);
                     Debug.LogError("走点返回异常:" + msg22.toJsonString());
                 }
             });
         }
     });
 }
Beispiel #3
0
    void getCurrentFuben(ErlKVMessage msg)
    {
        ErlType type = msg.getValue("sid") as ErlType;
        int     sid  = StringKit.toInt(type.getValueString());

        if (sid > 0)
        {
            //放弃副本
            MiniFport.access(cm, FrontPort.FUBEN_ABANDON, (msg2) => {
                log("进入副本");
                //进入副本
                MiniFuBenIntoFPort f = new MiniFuBenIntoFPort();
                f.cm = cm;
                f.intoFuben(missionSid = sid, 1, IntoFubenBack);
            });
        }
        else
        {
            log("进入副本");
            //进入副本
            MiniFuBenIntoFPort f = new MiniFuBenIntoFPort();
            f.cm = cm;
            f.intoFuben(missionSid++, 1, IntoFubenBack);
        }
    }
Beispiel #4
0
 void test()
 {
     st = ServerTimeKit.getMillisTime();
     MiniFport.access(cm, "/yxzh/test", (msg) => {
         //Debug.LogError(TimeKit.getMillisTime() - st);
         test();
     });
 }
Beispiel #5
0
    void FubenGetEventInfo()
    {
        log("获取点位信息");

        MiniFport.access(cm, FrontPort.FUBEN_GET_EVENT_INFO, (msg) => {
            FubenDoEvent();
        });
    }
Beispiel #6
0
 void fuben(int sid)
 {
     //MiniFport.access(cm,new ErlKVMessage (FrontPort.FUBEN_GET_CURRENT),getCurrentFuben);
     //放弃副本
     MiniFport.access(cm, FrontPort.FUBEN_ABANDON, (msg2) => {
         log("进入副本");
         //进入副本
         MiniFuBenIntoFPort f = new MiniFuBenIntoFPort();
         f.cm = cm;
         f.intoFuben(sid, 1, IntoFubenBack);
     });
 }