2018-12-18 22:42:15

I do not know if what I am doing is the best way of doing this. Here is my objective, and here is my current solution. I am using bgt to code this, and this code is to help replay the level from rhythm rage in the level creator I have made.
object: replay the level with the correct times
So as of right now, I am having bgt open generated.lvl and read the first line. The contents of that line is then the text of a string. Next I split that string into 2 array entries, one with action name= time=, and the other with the actual time value and the rest of the line. The next step I did was make an integer variable equal to the number in the second array entry.
Do I absolutely need an array to find the number inside the string? Is there an easier way to read the file and grab each time value from it and have the program play the sound at each time value? I do not want to use java and I have everything as variables not classes, so is there any way I can do this without needing an array? I'm sorry if this post is very confusing, I just don't know how to go about this and working with an array for this breaks my mind. I will add I'm not that good at coding, I come up with solutions, but as far as digging deep into code that is not something I have done much.