add argument to fillbricks to bypass confirmation dialog

This commit is contained in:
Redo 2022-10-07 22:04:47 -06:00
parent 93d385e859
commit dc7f27512a

View File

@ -359,7 +359,7 @@ function serverCmdNdConfirmSuperCut(%client)
function serverCmdSC(%client){serverCmdSuperCut(%client);}
//Fill volume with bricks
function serverCmdFillBricks(%client, %subsetname)
function serverCmdFillBricks(%client, %conf, %subsetname)
{
if($Pref::Server::ND::FillBricksAdminOnly && !%client.isAdmin)
{
@ -386,12 +386,16 @@ function serverCmdFillBricks(%client, %subsetname)
}
%client.NDFillBrickSubset = (%subsetname !$= "") ? ndLookupSubsetName(%subsetname) : $ND::SubsetDefault;
commandToClient(%client, 'messageBoxOkCancel', "New Duplicator | /FillBricks",
"/FillBricks will first do a Supercut\nbefore placing bricks, to fix overlap." @
"\n\nSupercut is destructive and does\nNOT support undo at this time." @
"\n\nPlease make sure the box is correct,\nthen press OK below to continue.",
'ndConfirmFillBricks');
if(%conf) {
serverCmdNdConfirmFillBricks(%client, %subsetname);
} else {
commandToClient(%client, 'messageBoxOkCancel', "New Duplicator | /FillBricks",
"/FillBricks will first do a Supercut\nbefore placing bricks, to fix overlap." @
"\n\nSupercut is destructive and does\nNOT support undo at this time." @
"\n\nPlease make sure the box is correct,\nthen press OK below to continue.",
'ndConfirmFillBricks');
}
}
//Confirm fill volume with bricks
@ -434,8 +438,8 @@ function serverCmdNdConfirmFillBricks(%client, %subsetname)
}
//Alternative short command
function serverCmdFB(%client){serverCmdFillBricks(%client);}
function serverCmdFBW(%client) { serverCmdFillBricks(%client, "LogicWire"); }
function serverCmdFB (%client, %conf) { serverCmdFillBricks(%client, %conf); }
function serverCmdFBW(%client, %conf) { serverCmdFillBricks(%client, %conf, "LogicWire"); }
//MultiSelect toggle (ctrl)