Ejemplo n.º 1
0
    public void Init(Vector3 Pos, float gridsize)
    {
        this.Cam        = CinemachineCore.get_Instance().GetActiveBrain(0).get_OutputCamera();
        this.carsolObjs = new CarsolObj[10];
        for (int index = 0; index < this.carsolObjs.Length; ++index)
        {
            this.carsolObjs[index].m_Obj = this.gameObjects[index];
            switch (index)
            {
            case 0:
                this.carsolObjs[index].m_CarsolAreaNumX = 1;
                this.carsolObjs[index].m_CarsolAreaNumZ = 1;
                break;

            case 1:
                this.carsolObjs[index].m_CarsolAreaNumX = 1;
                this.carsolObjs[index].m_CarsolAreaNumZ = 2;
                break;

            case 2:
                this.carsolObjs[index].m_CarsolAreaNumX = 2;
                this.carsolObjs[index].m_CarsolAreaNumZ = 1;
                break;

            case 3:
                this.carsolObjs[index].m_CarsolAreaNumX = 1;
                this.carsolObjs[index].m_CarsolAreaNumZ = 5;
                break;

            case 4:
                this.carsolObjs[index].m_CarsolAreaNumX = 2;
                this.carsolObjs[index].m_CarsolAreaNumZ = 2;
                break;

            case 5:
                this.carsolObjs[index].m_CarsolAreaNumX = 4;
                this.carsolObjs[index].m_CarsolAreaNumZ = 4;
                break;

            case 9:
                this.carsolObjs[index].m_CarsolAreaNumX = 2;
                this.carsolObjs[index].m_CarsolAreaNumZ = 3;
                break;

            default:
                this.carsolObjs[index].m_CarsolAreaNumX = this.carsolObjs[index].m_CarsolAreaNumZ = 0;
                break;
            }
        }
        this.fGridSize        = gridsize;
        this.nDirection       = 0;
        this.bRayFromMouseHit = false;
        this.MinPos           = Pos;
        ref Vector3 local1 = ref this.MinPos;
Ejemplo n.º 2
0
 public void Init()
 {
     this.thisCamera   = CinemachineCore.get_Instance().GetActiveBrain(0).get_OutputCamera();
     this.housingMgr   = Singleton <Housing> .Instance;
     this.CamDat.Fov   = 23f;
     this.CamReset.Fov = 23f;
     ((CameraState) ref this.m_State).set_Lens(this.lens);
     this.isDrags = new bool[this.CONFIG_SIZE];
     for (int index = 0; index < this.isDrags.Length; ++index)
     {
         this.isDrags[index] = false;
     }
     if (this.isInit)
     {
         return;
     }
     this.isButtons    = new bool[this.CONFIG_SIZE];
     this.targetRender = (Renderer)((Component)this.lookAtTarget).GetComponent <Renderer>();
     this.TargetSet(this.lookAtTarget, true);
     this.isOutsideTargetTex = true;
     this.isConfigTargetTex  = true;
     this.input  = Singleton <Input> .Instance;
     this.isInit = true;
 }