Fix animated texture preview in single tex mode
This commit is contained in:
parent
e4f9b8cf60
commit
dc25b713d5
@ -203,6 +203,11 @@ function setProjectResolution(width, height, modify_uv) {
|
||||
}
|
||||
function updateProjectResolution() {
|
||||
document.querySelector('#project_resolution_status').textContent = `${Project.texture_width} ⨉ ${Project.texture_height}`;
|
||||
if (Texture.selected) {
|
||||
// Update animated textures
|
||||
Texture.selected.height++;
|
||||
Texture.selected.height--;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
@ -830,13 +830,11 @@ const Canvas = {
|
||||
|
||||
stretch = 1;
|
||||
frame = 0;
|
||||
if (cube.faces[f.face].texture && cube.faces[f.face].texture !== null) {
|
||||
var tex = cube.faces[f.face].getTexture()
|
||||
if (tex instanceof Texture && tex.frameCount !== 1) {
|
||||
stretch = tex.frameCount
|
||||
if (animation === true && tex.currentFrame) {
|
||||
frame = tex.currentFrame
|
||||
}
|
||||
let tex = cube.faces[f.face].getTexture();
|
||||
if (tex instanceof Texture && tex.frameCount !== 1) {
|
||||
stretch = tex.frameCount
|
||||
if (animation === true && tex.currentFrame) {
|
||||
frame = tex.currentFrame
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user