MCPcopy Create free account
hub / github.com/Meridian59/Meridian59 / CmMiscLDSplitSector

Method CmMiscLDSplitSector

roomedit/source/editcli.cpp:3439–3469  ·  view source on GitHub ↗

//////////////////////////////////////////////////////////////// TEditorClient -------------

Source from the content-addressed store, hash-verified

3437// -------------
3438//
3439void TEditorClient::CmMiscLDSplitSector ()
3440{
3441 // Ignore if "insert object" mode
3442 if ( InsertingObject )
3443 return;
3444
3445 SET_HELP_CONTEXT(Split_LineDefs_and_Sectors);
3446
3447 // Check two object selected
3448 if ( CheckSelection (2, 2) == FALSE )
3449 goto End;
3450
3451 // UNDO
3452 StartUndoRecording("Split Sector");
3453
3454 // Split LineDef's and add a sector
3455 SplitLineDefsAndSector (Selected->objnum, Selected->next->objnum);
3456
3457 // UNDO
3458 StopUndoRecording();
3459
3460 // SELECTION IS STILL VALID
3461 // Restore selection
3462 SetupSelection (FALSE);
3463
3464 // Redraw map, info windows and status bar
3465 RefreshWindows();
3466
3467End:
3468 RESTORE_HELP_CONTEXT();
3469}
3470
3471
3472/////////////////////////////////////////////////////////////////////

Callers

nothing calls this directly

Calls 3

StartUndoRecordingFunction · 0.85
SplitLineDefsAndSectorFunction · 0.85
StopUndoRecordingFunction · 0.85

Tested by

no test coverage detected