0 votes

I am new to game dev so sorry if this is silly.
When i change costume to the character in the main menu, i want it to apply to the game when it starts. How can i do it?

in Engine by (12 points)

1 Answer

0 votes

Be aware that your question is very broad, so the answer will be as well: You need to store the information about which costume the character currently wears in a place that is accessible both from the main menu and the game scenes, e.g. a Singleton. If you want the information to persist across restarts, you might write it to a file as well. Now all you need to do is check this variable when the character is loaded and change it's appearance accordingly. How exactly you do this, depends a great deal on which node(s) you are using for representing a costume.

by (10,628 points)
Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to [email protected] with your username.