HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Need STRING help

12-28-2003, 11:28 PM#1
c0nnick
Hey everyone, im making a new RPG, but i need help. Its kind of based off of the Mario RPG thing for anyone who played SC, where when u got near an enemy unit, u were brought to an area where u wud fight a few enemy units of that type.

Anyway, im trying to make a simple method for myself, so i dont need too many triggers. I will make the unit name have the name, the amount it makes, and what fighting arena it will take you to. The only problem is, i dont know how to take things out of strings, and stuff. Like if the unit name is BearA+, I want the map to simply take the A and the + out, so i can use some if statements on them to determine where and how many of the creature will be spawned. PLEASE HELP
12-29-2003, 12:05 AM#2
Ligature
I wouldn't use the unit name to store this information... I'd try using point values, or maybe custom values... Or maybe, if you're going to apply a bunch of if statements to it anyway, just have the if statements check the unit-type instead of the unit's name.

If you really do need to use the unit name, you're either going to have to put the information in a standardized format at the beginning of the name, or use delimiters to designate when you're starting and ending a block of information. So when you select one of these enemies, its name will be something like "A22Hobgoblin" or "Hobgoblin-A22." Then, you're going to have to write a whole parsing trigger... it'll get messy.
12-29-2003, 12:25 AM#3
c0nnick
Haha, point values and stuff Thanks! I really appreciate such a fast reply