How do I check for a certain text in a variety of variables?

Hi! I have a question about how I can check for a certain text in a variety of variables.

I’m trying to make a little simulation of money and the player needs to make their own fake credit card to start, but they need to enter a custom card number, CVC, etc. When they registered, I set it up so that all the details are stored in one variable(for example: 1234123412341234,3/27/25,324,Visa,John Lee, or cardnumber/expiredate/CVC/cardprovider/name). Then the player can enter the exact detail to check balances or bills. How do I make it so that when they enter the card information, the game checks from all the other credit card variables, just to find that one variable with the correct information?

If any of what I said is confusing, please let me know. This is my first time using this forum so I may or not know certain things about this. I also do not use the javascript writing functions on GDevelop so I just use the events. I used GDevelop for a year by now, but I never looked at any tutorials or documentation, I just tried creating a game or experiments to learn from them.

Any help would be appreciated. Thanks.

You could look into String Expressions Text manipulation - GDevelop documentation or even use JavaScript and Regex via an extension.

A simpler solution might just be storing the data in child variables. That way you can just check the value of the specific key.

Example, store it in a scene variable.

Then simply check the variables.

Thanks, but that only checks from only 1 structure. How do I set up a system that checks all the structures? I want to app to have a way to register as many cards as they want, and I want the game to check from the multiple structures or cards to check for the exact one.

Use an array of structures - so an array with nodes that is the credit card structure as in @Eiklahc’s screen snip. Then use the For each child... event to iterate over each credit card structure.