chenxin
2020-12-02 54181477c210344b037d88f17dbe2cddc5cbc930
Assets/Scripts/Core/Camera/ViewPortAdj.cs
@@ -15,10 +15,17 @@
    public bool bAdjViewPort = false;
    public void DOShakePosition(){
        cachedCamera.DOShakePosition(0.25f, 1.5f, 4);
    public void DOShakePosition()
    {
        KTGMGemClient.GameConfig.IsShaking = true;
        cachedCamera.DOShakePosition(0.25f, 1.5f, 4).OnComplete(() =>
        {
            KTGMGemClient.GameConfig.IsShaking = false;
        });
        backGroundCamera.DOShakePosition(0.25f, 1.5f, 4);
    }
    public void adjViewportRect()
    {
@@ -34,7 +41,7 @@
        //bAdjViewPort = true;
    }
    protected override void Awake()
    {
        base.Awake();
@@ -47,12 +54,13 @@
    {
        // 初始化的时候调整视口就OK了.
        this.adjViewportRect();
        Application.targetFrameRate = 60;
    }
    // Update is called once per frame
    void Update()
    {
        this.adjViewportRect();
        Application.targetFrameRate = 60;
        //this.adjViewportRect();
        //Application.targetFrameRate = 60;
    }
}