poohcom1 / godot-private-exports

A Godot addon that lets you set access modifier for exported variables!
https://godotengine.org/asset-library/asset/2136
MIT License
22 stars 0 forks source link

Child scenes setting metadata on exports from parent scenes. #7

Closed poohcom1 closed 1 year ago

poohcom1 commented 1 year ago

Sometimes, child scenes would have metadata set on an export that's inherited from its parent, which shouldn't happen. For example:

Actor
 - speed : protected

Enemy extends Actor
 - speed : private

Because speed is inherited from Actor, Enemy should never be able to set the modifier. But there are cases where the modifier becomes private, which can break functionality because there is no way to set the modifier from the editor of a child scene.

If you encounter issue, go into the .tscn file, and remove the variable name from the metadata/_access_modifiers dictionary.