[Blocks&Items] Improve camera update #8

Closed
opened 2023-02-02 09:55:00 +01:00 by beu · 1 comment
Owner

Based on XertroV's tip (https://discord.com/channels/276076890714800129/452462518280126465/1070595141317963827):

    void UpdateCamera() {
        auto editor = cast<CGameCtnEditorFree>(GetApp().Editor);
        auto orbital = editor.OrbitalCameraControl;
        auto origPSZP = editor.OrbitalCameraControl.m_ParamScrollZoomPower;
        editor.OrbitalCameraControl.m_ParamScrollZoomPower = 0;
        editor.ButtonZoomInOnClick();
        editor.OrbitalCameraControl.m_ParamScrollZoomPower = origPSZP;
    }
Based on XertroV's tip (https://discord.com/channels/276076890714800129/452462518280126465/1070595141317963827): ``` void UpdateCamera() { auto editor = cast<CGameCtnEditorFree>(GetApp().Editor); auto orbital = editor.OrbitalCameraControl; auto origPSZP = editor.OrbitalCameraControl.m_ParamScrollZoomPower; editor.OrbitalCameraControl.m_ParamScrollZoomPower = 0; editor.ButtonZoomInOnClick(); editor.OrbitalCameraControl.m_ParamScrollZoomPower = origPSZP; } ```
Author
Owner

done

done
beu closed this issue 2023-09-26 22:14:18 +02:00
Sign in to join this conversation.
No Label
No Milestone
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: beu/Openplanet-Plugins#8
No description provided.