how do you create a system of unlocking character??
You make an attribute that when it is triggered it unlocks the character.
This is done by creating a new boolean in the game tab of the attributes part. You can rename this to whatever you like (probably the names of the characters). Make sure it's unchecked, as that means the statement is false at the time.
For the character selection screen, this depends on what you want the unlocking characters who are not yet unlocked to appear as. Like a question mark. You'd have a rule set for all the actors who are unlocking characters. This rule will be something like this:
If New character 1 is false
New character 1 image to Question mark
And for having the ability to touch the actor to use that character, you'd have the rule start off with the attribute condition saying "if New character 1 is true" in addition to the touch condition.
Now for how you unlock the character. This also depends on what you are wanting for the unlocking methods. But lets say for instance one of the methods was getting a score of 11,000.
You'd have a rule set for the score actor that says if score reaches 11,000, then change attribute of new character 1 (boolean) to true.
You most likely will need a boolean for each unlocking character as I'm safe to guess each has their own unlocking options.
i did make an attribute and i have succesfully create the system with all your help just one problem that when i unlock one character (boolean) and then change scene and load all the character are unlocked
Did you make a boolean for each character? I feel the problem may lie that each character are being unlocked from the same boolean rule.
You also need to save those unlocked conditions. A table is best for this.
Guru Video Channel | Lost Oasis Games | FRYING BACON STUDIOS
no i use one boolean for all the character, i guess i have to make one for each them now.
Before you go down that route, I would follow Guru's advice and make a table. It will save data indefinitely and achieve this. Make a table column for each character with boolean or integer, I prefer integer. Basically when someone taps to unlock a character you can check if they meet the requirements, change table value, then find the cell of the corresponding character value, and set it to 1 or true and save table data. Then make a rule constraining an attribute to the corresponding cell and if true, allow the unlock.
im not familiar in using table so i just make a boolean for each unlock character, its only 20 character thank you guys for you help