Esempio n. 1
0
 //UPDATE
 public override bool UpdateManager()
 {
     DX4D.UpdatePanelParent(uiLink.active, uiLink.linked);
     DX4D.AlignPanel(uiLink.active, horizontalAlignment, verticalAlignment, panelOffset);
     DX4D.UpdatePanelOrder(uiLink.active, showOrder);
     return(true);
 }
Esempio n. 2
0
    void Update()
    {
        if (Input.GetMouseButton(1))
        {
            speed = Vector3.zero; //Reset Speed Variable

            speed.x = true ? (-Input.GetAxis("Mouse X") * 1.0f) : -1.0f;
            //speed.y += Input.GetMouseButton(0) ? 1.0f : 0.0f; //Input.GetAxis("Mouse Y")
            //speed.z += Input.GetMouseButton(2) ? 1.0f : 0.0f;

            avgSpeed = DX4D.SmoothVector(avgSpeed, speed);
        }
        else
        {
            if (dragging)
            {
                speed    = avgSpeed;
                dragging = false;
            }

            speed = DX4D.SmoothVector(speed, lerpSpeed);
        }

        speed = DX4D.LockRotation(speed, !rotateX, !rotateY, !rotateZ);
        DX4D.RotateGameObject(target, speed, rotationSpeed);
    }
Esempio n. 3
0
    private void LateUpdate()
    {
        if (cameraLink == null)
        {
            cameraLink = GetComponent <LinkCamera>();
        }
        if (entityLink == null)
        {
            entityLink = GetComponent <LinkEntity>();
        }

        if (cameraLink == null || entityLink == null)
        {
            return;
        }

        if (cameraLink.active == null)
        {
            return;
        }
        if (entityLink.linked == null || UMMO.IsDead(entityLink.linked))
        {
            cameraLink.active.transform.position = Vector3.zero; return;
        }

        DX4D.Follow(cameraLink.active.transform, entityLink.linked.transform, followOffset);
        LookAt(cameraLink.active, entityLink.linked);
    }
Esempio n. 4
0
    //UPDATE
    void Update()
    {
        LoadLinks();

        if (cameraLink == null || entityLink == null)
        {
            return;
        }
        if (cameraLink.active == null)
        {
            return;
        }

        followOffset = GetOffsets();
        DX4D.ChangeCameraView(cameraLink.active, cameraZoom, cameraFieldOfView, showLayers);

        if (entityLink.linked == null || UMMO.IsDead(entityLink.linked))
        {
            cameraLink.active.transform.position = Vector3.zero; return;
        }

        DX4D.Follow(cameraLink.active.transform, entityLink.linked.transform, followOffset);
        ConfigureCameraLookAt(cameraLink.active, entityLink.linked);
    }