Browser Based Mud

Discussion and location of the Browser Based MMO Tutorial and the RTS tutorial.
Post Reply
User avatar
hallsofvallhalla
Site Admin
Posts: 12031
Joined: Wed Apr 22, 2009 11:29 pm

Browser Based Mud

Post by hallsofvallhalla »

Posting here tonight is video 1 of my latest series of tutorials that I worked on this weekend. Building a Browser Based Mud using Javascript, Jquery, Bootstrap, Node, and Mysql. The focus on this tutorial is to teach people to use each while building a game.

Like always comments, questions and so forth can be posted here as well as any suggestions on how we want the game to turn out and features added. One of the main reasons for choosing a MUD is I hope to bring some more interest back to MUDs. With Jack working on his and the rarity of good html5 MUDs I think it would be great to try to drive players and developers back in that direction.
User avatar
Jackolantern
Posts: 10893
Joined: Wed Jul 01, 2009 11:00 pm

Re: Browser Based Mud

Post by Jackolantern »

I have to admit I have taken a bit of a break from working on my game; maybe a permanent break from it. I made some pretty serious mistakes with it that I started paying for. One of those mistakes was simply using JS objects to store things in memory. It seemed like a good, simple idea at first. But as I went along, I realized I was writing nearly the same kind of logic over and over again to work with the object data stores. What I should have done was either encapsulate access logic into those JS objects to handle their access, or create full modules to hold data and methods to work with it. As it stands now, it would be a huge task to update it to more intelligent memory stores because the logic to access them is scattered throughout the whole server in various forms. And without doing that, I am essentially cursed to be repeatedly rewriting memory access logic until it is done.

It sucks when it takes a mistake that essentially derails dozens of hours of work before you really feel the logic behind the OOP approach. I need to work on using more OOP in Javascript, a language where it is easy to just procedure the day way :P

However, I have done some interesting stuff in it that I am proud of, and would be more than willing to put it up on Github if you want to see it.
The indelible lord of tl;dr
User avatar
Callan S.
Posts: 2043
Joined: Sun Jan 24, 2010 5:43 am

Re: Browser Based Mud

Post by Callan S. »

Still think people are tooooo particular and toooooo demanding of their work - too many projects ending because something went a bit wonky. Never mind the logic of OOP, what about the logic of getting something which, maybe not as polished as it could be, but is DONE none the less? There's a logic in that as well!
User avatar
Jackolantern
Posts: 10893
Joined: Wed Jul 01, 2009 11:00 pm

Re: Browser Based Mud

Post by Jackolantern »

Callan S. wrote:Still think people are tooooo particular and toooooo demanding of their work - too many projects ending because something went a bit wonky. Never mind the logic of OOP, what about the logic of getting something which, maybe not as polished as it could be, but is DONE none the less? There's a logic in that as well!
I know what you are saying, but this was pretty serious. This wasn't Hall's Disease telling me to change projects. This was a "Oh #$%# what have I done?" moment lol. I am at a point where I refactor somewhere around 50% of everything that has been written, or just chug on ahead until the code is completely unworkable and I can't tell anymore what is going to break with every new addition. Having data access code rewritten over and over again with small variations all through the server source and having no protection at all on the memory stores were already starting to give me major headaches, and it was only going to get worse.

Believe me that I agonized over the decision to halt development. I asked myself several times if I was quitting it just because I wanted to work on something else, and I couldn't say that I was. I just made a very serious design mistake that was mostly due to just sitting down and starting to code with basically no design ahead of time. I know that is a pretty big rookie mistake for such a large project, but I started it fairly oddly, as I was just fooling around with node, Socket.io, Express and MongoDB just to learn it when something snapped, I quickly saw I knew everything I needed and suddenly jumped right into development lol :roll:
The indelible lord of tl;dr
User avatar
Callan S.
Posts: 2043
Joined: Sun Jan 24, 2010 5:43 am

Re: Browser Based Mud

Post by Callan S. »

I'm gunna play the bad guy: It's pretty much Hall's desease. Tie up some loose ends and finish the product, even if it only has 5% functionality compared to initial plans. Can only travel from room to room? Okay, tie off the loose ends and let it be finished. Sure, you had to stop short - but you didn't have to stop and not finish it, that way.

If it feels bad to have a clunky product under your name - well, the negative feedback of that is part of the process!

Okay, done playing the bad guy! If I seem reeeeeal bad, just ignore this post - I would! >:)
User avatar
Jackolantern
Posts: 10893
Joined: Wed Jul 01, 2009 11:00 pm

Re: Browser Based Mud

Post by Jackolantern »

Well, it does have about 20% of the functionality of the initial plan. You can move from room-to-room, build rooms in-game, build quests and items, accept and complete quests, pick up items, get the description from anything in the room, talk to other players in the room, whisper any player in the game, ignore players, see the ignore list, remove players from ignore, the GUI stats window works, and more.

Even with the serious issues (that would be pretty solvable by simply sitting down to design the game before coding next time), I am proud of a lot of the stuff I accomplished. :)
The indelible lord of tl;dr
User avatar
a_bertrand
Posts: 1537
Joined: Mon Feb 25, 2013 1:46 pm

Re: Browser Based Mud

Post by a_bertrand »

Indeed that is already a lot! Maybe you should not stop and just fix a few things.
Creator of Dot World Maker
Mad programmer and annoying composer
User avatar
Jackolantern
Posts: 10893
Joined: Wed Jul 01, 2009 11:00 pm

Re: Browser Based Mud

Post by Jackolantern »

I have still not officially abandoned it, and I kept a very good development log while I was working on it with daily (and sometimes multiple daily) reports, so it would not be that hard to pick it back up right where I left off. There would be a lot of issues to tackle, mostly revolving around the complete and total coupling of the game's logic and the data access. Near the end of its active development, any update to the code sent a tidal wave of errors rippling through the whole program, and development was slowing to a halt. It became "change 10 lines of code, spend 4 hours debugging all the errors, change 10 lines of code, spend 5 hours debugging all the errors, etc.". Sadly, it would not be fixing "a few things" that would put it back on the right path :(
The indelible lord of tl;dr
User avatar
a_bertrand
Posts: 1537
Joined: Mon Feb 25, 2013 1:46 pm

Re: Browser Based Mud

Post by a_bertrand »

Is your issue the data storage? If yes what do you use? MySQL? If yes did you checked MongoDB?
Creator of Dot World Maker
Mad programmer and annoying composer
User avatar
Epiales
Posts: 1119
Joined: Thu Aug 15, 2013 1:38 am

Re: Browser Based Mud

Post by Epiales »

Forgive me for being ignorant, but what is Mud? :oops: :oops: :oops:
Nothing fancy, but a work in progress!

http://gameplaytoday.net
Post Reply

Return to “Youtube Tutorials”