Scirra / Construct-bugs

Public bug report submissions for Construct 3 and Construct Animate. Please read the guidelines then click the 'Issues' tab to get started.
https://www.construct.net
107 stars 83 forks source link

Editor crashes when previewing a sprite animation with loop and just one frame #7399

Closed lootzifr closed 1 year ago

lootzifr commented 1 year ago

problem description

The editor crashes when a sprite animation is previewed in the editor layout and the animation is set to loop but just has one frame.

image image image image

Example files

AnimationCrash.c3p.zip

Steps to reproduce

  1. create new project
  2. add a sprite
  3. set two frames with the initial animation
  4. add another animation with just one frame
  5. set that animation to loop
  6. Close image editor
  7. Preview the sprite animation (default)
  8. While previewing switch the animation to the animation with just one sprite
  9. Editor crashes

Observed result

Editor crashing

Expected result

More details

If your initial animation has just one sprite the editor is blocking the option to preview it. (that is fine) To see the bug you need to start previewing with a multi-frame animation and then switch to an animation with just one frame. The animation needs to be set to looping.

System details

Error report information Type: assertion failure Message: changing to same frame Stack: Error at oa.a0a (https://editor.construct.net/r358/main.js:1120:314) at window.assert (https://editor.construct.net/r358/main.js:1035:353) at YKb (https://editor.construct.net/r358/plugins/allEditorPlugins.js:23:34) at window.Srb.uL (https://editor.construct.net/r358/plugins/allEditorPlugins.js:262:385) at VRb.Instance.$f (https://editor.construct.net/r358/plugins/allEditorPlugins.js:270:136) at d.$f (https://editor.construct.net/r358/projectResources.js:860:9) at d.$f (https://editor.construct.net/r358/projectResources.js:1400:471) at d.$f (https://editor.construct.net/r358/projectResources.js:1357:320) at Fbc (https://editor.construct.net/r358/components/editors/layoutView/layoutView.js:91:303) Construct version: r358 URL: https://editor.construct.net/ Date: Mon Sep 18 2023 14:37:58 GMT+0200 (Mitteleuropäische Sommerzeit) Uptime: 527 s

Platform information Product: Construct 3 r358 (stable) Browser: Chrome 116.0.5845.187 Browser engine: Chromium Context: webapp Operating system: macOS 13.5.2 Device type: desktop Device pixel ratio: 2 Logical CPU cores: 8 Approx. device memory: 8 GB User agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/116.0.0.0 Safari/537.36 Language setting: en-US

WebGL information Version string: WebGL 2.0 (OpenGL ES 3.0 Chromium) Numeric version: 2 Supports NPOT textures: yes Supports GPU profiling: no Supports highp precision: yes Vendor: Google Inc. (Apple) Renderer: ANGLE (Apple, Apple M2, OpenGL 4.1) Major performance caveat: no Maximum texture size: 16384 Point size range: 1 to 64 Extensions: EXT_color_buffer_float, EXT_color_buffer_half_float, EXT_disjoint_timer_query_webgl2, EXT_float_blend, EXT_texture_compression_rgtc, EXT_texture_filter_anisotropic, EXT_texture_norm16, KHR_parallel_shader_compile, OES_draw_buffers_indexed, OES_texture_float_linear, WEBGL_compressed_texture_s3tc, WEBGL_compressed_texture_s3tc_srgb, WEBGL_debug_renderer_info, WEBGL_debug_shaders, WEBGL_lose_context, WEBGL_multi_draw, WEBGL_provoking_vertex

XHXIAIEIN commented 1 year ago

I can reproduce it.

Snipaste_2023-09-22_16-10-01

and change Initial animaiton Snipaste_2023-09-22_16-10-18

DiegoScirra commented 1 year ago

Will be fixed in the next beta.