MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / SetViewMode

Function SetViewMode

editor/MainFrm.cpp:2943–2959  ·  view source on GitHub ↗

Set the editor view mode

Source from the content-addressed store, hash-verified

2941void CMainFrame::OnObjectMovePlayer() { HObjectMoveToViewer(Player_object); }
2942
2943// Set the editor view mode
2944void SetViewMode(int view_mode) {
2945 // Set new view mode
2946 Editor_view_mode = view_mode;
2947
2948 // Get the correct viewer (terrain or mine or room)
2949 SetEditorViewer();
2950
2951 // Set the correct wireframe view
2952 if (view_mode == VM_ROOM)
2953 Wireframe_view = &Wireframe_view_room;
2954 else if (view_mode == VM_MINE)
2955 Wireframe_view = &Wireframe_view_mine;
2956
2957 // Force the windows to update
2958 AfxGetMainWnd()->Invalidate(TRUE);
2959 AfxGetMainWnd()->UpdateWindow();
2960}
2961
2962void CMainFrame::OnRoomView() { SetViewMode(VM_ROOM); }

Callers 8

OnIdleMethod · 0.85
MoveViewerFunction · 0.85
OnLoadRoomMethod · 0.85
OnGotoMethod · 0.85
OnRoomViewMethod · 0.85
OnTerrainViewMethod · 0.85
OnMineViewMethod · 0.85
SetViewerFunction · 0.85

Calls 2

SetEditorViewerFunction · 0.85
InvalidateMethod · 0.80

Tested by

no test coverage detected