String Manipulations

DaMaster0

Member
ok, here's the problem. I want to make a function that returns what the council wants you to do as an array. Here's what I've narrowed it down to so far:
>The Spookiness still emanates from the Cyrpt, Adventurer. See if you can find and destroy the source, and bring us back proof of your conquest.<p>The Baron Rof L'm Fao still needs your help, Adventurer! You can find his valley beyond the Orc Chasm, in the Big Mountains.<p>If you're having trouble getting past the Chasm, the pirates on the Mysterious Island of Mystery might have something that will help you.<p><cen
I've used zarqon's excise() so far, but know I want to get the test in an array, with the <p> as the break point between entries. So I thought this through and figured I'd need something like excise() but it doesn't delete the end point. It would be helpful if someone could make that for me, but what I'm really looking for is someone to explain how substring() works, so I can make my own and hopefully be better at string manipulations in the future.

Thanks!
 

mredge73

Member
this has been done before:
http://www.kolmafia.us/showthread.php?t=810

I have implemented this in with my scripts and is available as one of my library functions as well.

As for using substrings I am not the expert here, I like matchers now that I know how to use them. As for the endpoint use .<p> as your break point between entries.
 
Top