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

Ensure entity instances have unique ids, closes #213 #214

Merged
merged 1 commit into from
Dec 1, 2024

Conversation

bitbrain
Copy link
Owner

No description provided.

@bitbrain bitbrain force-pushed the ensure-entities-have-unique-ids branch from 0ff4f26 to 4bd9f6e Compare November 30, 2024 18:29
@@ -634,15 +639,19 @@ func is_category(category_id: String) -> bool:
category = Pandora.get_category(parent_id)
parent_id = category._category_id
return false


func get_entity_instance_id() -> String:
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

get_instance_id() is already reserved for Godot.



## Initializes this entity with the given data dictionary.
## Dictionary needs to confirm the structure of this entity.
func load_data(data: Dictionary) -> void:
if data.has("_id"):
_id = data["_id"]
if data.has("_instanced_from_id"):
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a breaking change.

@bitbrain bitbrain merged commit 38a5aa3 into godot-4.x Dec 1, 2024
2 checks passed
@bitbrain bitbrain deleted the ensure-entities-have-unique-ids branch December 1, 2024 18:22
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

Successfully merging this pull request may close these issues.

1 participant