First,
I do believe this language for text-based games need more string manipulation features, such as:
- get length of a string
- replace letter(s) in a string
- take portion of string into another variable
as for now, we can only concatenate from two variables, no other manipulation can be done.
let’s say I have variables: first_name “johnny”, last_name “sins”,
with features above, concatenation will not always yield “johnnysins”, or just adding capital on first letter of variables or adding space between two variables,
but we can do this:
- get first four letter of first_name (John)
- get first letter of last_name (s)
- get second letter of first_name (o)
- get fourth letter of first_name (n)
in one concatenate command, using more than two conditions to get “Johnson” as result
this will make wording more dynamic, it can change the displayed text without
changing the value of variables used for it, and less static variables has to be made.
Second,
I hope string and integer data type can communicate, so I can store data in a very long weird string.
let’s say I got a variable stats containing “John&Knight&100&75&3&5”, then I split this string into six other strings based on the character “&”, thus yield:
Name: John&
Class: Knight&
HP: 100&
SP: 75&
ATK: 3&
DEF: 5&
erase those last character from every variables and I get values I need. From there, I can use HP, SP, ATK, and DEF which are strings, move their values into integer variables, to do some math for combat and so on.
with this, I can store John’s parameters as string, use *temp for calculations without changing value of the six variables.
Well, for a language dedicated to text-based, CYOA games, I was expecting advanced string manipulation at least, but it’s okay there are room for improvements. I hope I don’t offend anyone, I was just saying that this kind of string manipulation are somewhat staple