Text-based MUD Coder, needing help.

First let me say, Hi! Good to meet you.

I'm a newish coder looking for some general help. Well more specific help then I can find in the C++ programming book I've bought, and help manuals I can find. While I haven't read the whole book through, and yes I know I really should read the whole thing through before asking questions on a forum, I would like to start working on my MUD curing code with C++.

With that said, I do fully plan on finishing the book as I have read some very interesting and helpful things thus far, and expect even greater things later on.

Now as to my question.

The book mentions Arrays, which by the way are awesome. So much better then tables within Mudlet. Easier to organize, bigger, and much faster. But I'm getting off track, with the arrays I figure I can start at least a small portion of my coding as I finish the book. Since I am more of a hands on kind of learner I find this would be best suited to my needs then just reading the book and doing a couple codes it explains and some practice one. If I'm working on something I plan to fully use and is a big project then I will learn more, and faster.

Back to why I mentioned Arrays.

So the Text-based MUD that I play, if you don't already know, has things called prompts that show up in clients(Like Mudlet) and everything you code pretty much revolves around that. My question is... How do I go about 'capturing' the prompt, but not the whole thing. Just certain sections and place them within an array so each 'section' is within a different part of the array?

Like for example.

H:5200(100%) M:5750(99%) W:100% E:100% B:100% XP:78.02% [csdb eb] <<21:53:36>>

That is currently my 'prompt' that I see every time I send/recieve a command, altered for my system of course.

What I would like to do is capture:

H:5200(100%)

That and place it within my(From here on out known as) prompt array. Though I don't want the whole chunk, just the '5200' part. But I want to repeat that for every letter there. So H, M, W, E, B, XP, and then again for the csdb eb part. Though that last part I know will be even more difficult as I'd need to seperate each letter and so on and so forth, but thats not my question right now.

With that in mind I know C++ won't 'run' unless it has a program to work out of, and I know... Or at least I think I know that Mudlet can only run LUA which from what I understand is a version of C++ but configured differently for some reason or another(BTW, bonus points if you can explain this. I am interested to know why Mudlet doesn't just run C++ would make this easier.)

So I have a program called 'Mudbot'. I don't know if you've heard of it, but pretty much it's a small windowed program that runs 'Modules' that are made out of .dll files with C++ coding(Possibly other forms of coding too, from what I've heard.) Which I want to, at the end of my project, convert my coding to .dll(If possible.... ?) and have it run through this program which will be linked with Mudlet(Already is as Mudbot has a 'Mapper' Module that I'm currently using. No, I didn't create the Mapper Module and don't know how to open the fold/want to incase I break something.)


I apologize if my ramblings are all over the place. It seems to be the only way for me to fully explain myself. So to better help I will recap what I have explained below in point form for your conveince.

--------------------------------------------------------------------------------

H:5200(100%) M:5750(99%) W:100% E:100% B:100% XP:78.02% [csdb eb] <<21:53:36>>

Section out portions of that(Numbers after the ?: parts) and place within a single Array for later comparison to another form of coding.

How to(If possible) change my C++ coding into a .dll file with the compiler so I can run the 'system' within the program Mudbot.(Which if you'd like an idea of what I'm speaking of I can gladly post a link for your viewing pleasure.)

--------------------------------------------------------------------------------

I believe that covers the major points I wanted to get answered. I know the point form seems like it would have been easier to do in the first place, but I like for people to understand where I am coming from and how my brain works.

If there are answers to this, or webpages that have the answers, can you please be sure that there is a good amount of detail? I should be able to figure out most things with the book I have and the infinite amount of internet out there, all I need is that first foot hold. As I said from what I've been reading in the book it seems like it's all based around making actual programs. Which is nice and I'm enjoying making programs beyond belief, but I'd like to use it more practically towards my gaming experience, and possibly make a few programs on the side just out of boredom.

Thank you for your help.
There is a general problem with serious-minded programmers, they don't read stories. This isn't an history class and you don't get a bonus for lexics or grammar. Summarize your problem, then you'll get their attention
Topic archived. No new replies allowed.