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

Object's set_meta() doesn't work on inherited scenes #12990

Closed
Tracked by #4778
kubecz3k opened this issue Nov 17, 2017 · 9 comments
Closed
Tracked by #4778

Object's set_meta() doesn't work on inherited scenes #12990

kubecz3k opened this issue Nov 17, 2017 · 9 comments

Comments

@kubecz3k
Copy link
Contributor

Operating system or device, Godot version, GPU Model and driver (if graphics related):
6277e6d

Issue description:
I'm writing an editor tool in which I would like to save some informations inside the scene itself. It turns out I can't save any information inside those scenes which are extending another ones.

Steps to reproduce:
Short way:

  1. Download sample project
  2. open InheritedScene.tscn
  3. Save it.
  4. Check InheritedScene.tscn in notepad and see that there is no meta data
  5. Additional: Repeat above steps for BaseScene.tscn and see meta is saved inside BaseScene.tscn

Long way:

  1. Create BaseScene.tscn
  2. Create scene which is inheriting BaseScene.tscn save it as InheritedScene.tscn
  3. Attach this code to InheritedScene.tscn:
tool
extends Node
func _ready():
	set_meta("Custom Meta", "Meta informations: " +  get_name() + " save time: " + str(OS.get_time()));
  1. Reopen InheritedScene.tscn
  2. Save it
  3. Open InheritedScene.tscn in notepad and see that there is no meta data

Link to minimal example project:
MetaInfoSaveInInheritedSceneTool.zip

@fracteed
Copy link

Good to see that you have isolated the issue! I was having lots of trouble reading metadata via the get_meta function a few weeks back on my game. Now I realise why I was getting all the errors :)

@kubecz3k
Copy link
Contributor Author

I also suspect this issue is related with #12838

@Piet-G
Copy link
Contributor

Piet-G commented Sep 15, 2018

Tested in Master, the meta still won't get added.

@akien-mga
Copy link
Member

For the reference, I checked if #32416 would fix this issue, but it did not.

@blaze-the-star
Copy link

2 Years later and this error still persists.

@eh-jogos
Copy link

Having problems with this as well, on 3.3

@Jayman2000
Copy link
Contributor

A side effect of this bug is that Editor Descriptions can’t be set for inherited scenes.

@Calinou Calinou changed the title Set_meta() don't work for inherited scenes Object's set_meta() doesn't work on inherited scenes Nov 12, 2021
@Rubonnek
Copy link
Member

I'm not able to reproduce this issue in the 3.x branch at commit a75afd6

@Calinou
Copy link
Member

Calinou commented Dec 27, 2021

Closing per @Rubonnek's comment. Please comment if you can still reproduce this.

@Calinou Calinou closed this as completed Dec 27, 2021
@Calinou Calinou added this to the 3.4 milestone Dec 27, 2021
clayton14 pushed a commit to clayton14/simple-brick-breaker-pr that referenced this issue Jul 16, 2022
Normally, I would have included the links in the editor descriptions for
levels, but they don’t get saved:
<godotengine/godot#12990>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

9 participants