JirkaDellOro / FUDGE

Furtwangen University Didactic Game Editor
https://jirkadelloro.github.io/FUDGE
MIT License
33 stars 27 forks source link

Editor: ViewPreview freezes editor #318

Closed plojo closed 2 years ago

plojo commented 2 years ago

Use the attached Project: FUDGE_EDITOR_BUG.zip

When selecting the graph in the internal view the editor freezes.

image

This seems to happen because ViewPreview attaches an event listener which listens for FudgeCore.EVENT.MUTATE (link) to initiate a redraw (redrawing the viewport). Both animation and particle system will dispatch the mutate event while redrawing causing a new redraw leading to an endless loop.

JirkaDellOro commented 2 years ago

Aua. I think it's not so much an issue with the ViewPreview, but with the recently implemented functionality of the synchronization of a graph and its instances. If not explicitely stopped. a mutation of a graph mutates all its instances, and a mutation of an instance mutates the graph and subsequently the instances again. I didn't think of the animation which of course works through mutation. Let's talk about that today.