Fix issue with undoing dragged keyframes (#1370)
Only show inside of Studio preview scene
This commit is contained in:
parent
972da05820
commit
49762b61bf
@ -950,7 +950,12 @@ Interface.definePanels(() => {
|
||||
Blockbench.setStatusBarText();
|
||||
if (values_changed) {
|
||||
Animation.selected.setLength();
|
||||
Undo.finishEdit('Drag keyframes');
|
||||
if (time_stretching) {
|
||||
Undo.finishEdit('Stretch keyframes');
|
||||
} else {
|
||||
Undo.addKeyframeCasualties(deleted);
|
||||
Undo.finishEdit('Drag keyframes');
|
||||
}
|
||||
} else {
|
||||
Undo.cancelEdit();
|
||||
}
|
||||
|
@ -60,6 +60,7 @@ class PreviewModel {
|
||||
this.texture = data.texture;
|
||||
this.color = data.color || '#ffffff';
|
||||
this.shading = data.shading !== false;
|
||||
this.render_side = data.render_side == undefined ? THREE.DoubleSide : data.render_side;
|
||||
this.texture_size = data.texture_size || [16, 16];
|
||||
|
||||
this.buildModel();
|
||||
@ -94,7 +95,7 @@ class PreviewModel {
|
||||
this.material = new (this.shading ? THREE.MeshLambertMaterial : THREE.MeshBasicMaterial)({
|
||||
color: this.color,
|
||||
map: tex,
|
||||
side: 2,
|
||||
side: this.render_side,
|
||||
alphaTest: 0.05
|
||||
});
|
||||
|
||||
@ -793,14 +794,11 @@ new PreviewModel('studio', {
|
||||
texture: './assets/preview_scenes/studio.png',
|
||||
texture_size: [64, 64],
|
||||
shading: false,
|
||||
render_side: THREE.BackSide,
|
||||
cubes: [
|
||||
{position: [-256, 0, -256], size: [512, 128, 512], faces: {
|
||||
{position: [-240, 0, -240], size: [480, 128, 480], faces: {
|
||||
up: {uv: [0, 16.04, 15.96, 31.96]},
|
||||
down: {uv: [0, 0, 16, 16]},
|
||||
east: {uv: [6, 50, 8, 60]},
|
||||
west: {uv: [6, 50, 8, 60]},
|
||||
north: {uv: [6, 50, 8, 60]},
|
||||
south: {uv: [6, 50, 8, 60]},
|
||||
}},
|
||||
{position: [48, 0, -240], size: [96, 128, 480], faces: {
|
||||
south: {uv: [16.06, 0, 64, 64]},
|
||||
|
Loading…
x
Reference in New Issue
Block a user