Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Weird behavior and potential project corruption if you copy a scene with sliders #6894

Open
1 task done
TheRealSoloLeo opened this issue Aug 28, 2024 · 3 comments
Open
1 task done

Comments

@TheRealSoloLeo
Copy link

Is there an existing issue for this?

Describe the bug

Copying a scene with a slider in it and pasting it in a different project can corrupt the project.

Steps to reproduce

  1. Create a new project
  2. Click on "Add a new object"
  3. Select "slider"
  4. This happened with "Square White Slider", I haven't tested if it works with the other ones
  5. Copy the scene
  6. Create a new project and paste the scene with the slider in it
  7. The slider is now a corrupted object
  8. If you don't delete the object before closing the project GDevelop will refuse to open it and say it's corrupted

GDevelop platform

Desktop, Web, Mobile

GDevelop version

5.4.209

Platform info

Windows

Windows 11

Additional context

I also put an instance of the object in the scene before copying it, I don't know if this is necessary to reproduce the bug.

The only way to recover the project is by manually deleting the slider in the json.

@ClementPasteau
Copy link
Collaborator

Thanks for the report @TheRealSoloLeo

@D8H is looking into it.

@D8H
Copy link
Collaborator

D8H commented Sep 2, 2024

The issue happens when:

  • the project with the custom object and its extension is open
  • the project with the copied custom object but where the extension is missing is open (letting GDevelop close the other project automatically)

The error message is "Error: Event-based objects don't have blueprint. This method should not never be called.".

As a workaround :

  • the project with the missing extension can be open if the other project is closed manually beforehand.
  • the missing extension can then be installed, the project needs to be closed and open back to see the custom object configuration
  • then the resources must be added to the new project.

@4ian
Copy link
Owner

4ian commented Sep 3, 2024

@D8H What can we do to fix the issue?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants