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