Welcome!

Join our community of MMO enthusiasts and game developers! By registering, you'll gain access to discussions on the latest developments in MMO server files and collaborate with like-minded individuals. Join us today and unlock the potential of MMO server development!

Join Today!

[ALPHA] stormcaster

Joined
Jul 12, 2011
Messages
1,229
Reaction score
475
The Problem
One of the fundamental issues with websites in the Maple PS sphere is that everyone wants a unique looking website, but everyone wants the same features. Redoing all your backend logic and styling for every single website is sort of annoying, and even moving to a MVC framework like Laravel or RoR doesn't really help too much, because you still have to rewrite your templates. MS websites are incredibly simple. There's no reason that changing the UI should be so much work.

The Solution
Here's the solution. Decoupling the backend entirely with the frontend. The goal of stormcaster is to create a REST API service, that allows server admins to quickly have a backend up and running. Once the API is working on their server, all they have to do is write a front end website that simply makes POST and GET requests to stormcaster.

Github:


12/18/15
- Created project
- Completed registration
- Completed rankings
- Completed news viewing

12/21/15
- Changed project name
- Switched to Laravel for easier JWT integration
- Completed JWT authorization
- Completed UCP actions (just disconnect for now)
- News management (editing, creation, deletion)
- Start vote, most likely will not finish this.

12/22/15
- Moved back to Lumen, confirmed all API endpoints are functioning

12/23/15
- Documentation

12/18/16
- Upgrade from Lumen 5.1 -> Laravel 5.3
- Create unit tests for all existing functionality, and add TravisCI for continuous testing.
- Add CodeCov for test CI
- Add admin middleware to reduce code repetition
- Split admin actions into separate controller
- Add StyleCI for style checking
- Add CORS package for correct preflight headers
- Modify News to generic Posts (encapsulates news/events/blogs into one item)

12/19/16
- Fix control flow and status message mixing design
- Add account password changing

12/20/16
- Switch manual SQL username and password querying with builtin Auth::attempt (removes reliance on weak SHA1 passwords)
- Move voting functionality out of User controller, so that route level middleware can be applied (previously controller-level with exceptions)
- fix rankings to only serve needed information, instead of entire character model

12/21/16
- Add implicit model binding and remove try/catch for post crud



DEMO:
 
Last edited:
Divine Celestial
Loyal Member
Joined
Sep 29, 2008
Messages
804
Reaction score
219
Re: [ALPHA] MapleLumen

Awesome! I'm super excited by this. I tried doing it with a server (decoupling the front and back end, essentially creating a web-based API) I worked on previously and I really liked what I did (despite the super basic code). This is super duper promising and can't wait to see the results.
 
Joined
Jul 12, 2011
Messages
1,229
Reaction score
475
Re: [ALPHA] MapleLumen

Awesome! I'm super excited by this. I tried doing it with a server (decoupling the front and back end, essentially creating a web-based API) I worked on previously and I really liked what I did (despite the super basic code). This is super duper promising and can't wait to see the results.

Thanks! I think the backend portion will not be that interesting, because it's just things most people are familiar with. Might be interesting for those who have never worked with an API.
I'm more excited for the frontend part of this, because I've been wanting to get more experience with JS frameworks for a long time now!
 
Joined
Jul 12, 2011
Messages
1,229
Reaction score
475
Re: [ALPHA] MapleLumen

Lumen turned out to be a bit too barebones for what I'm trying to do. Decided to switch over to Laravel for easier integration with JWT and other packages.

I'm planning on getting a beta version out by the end of today. Stay tuned!

Update: Updated github links. Very rough copy, hope to have it fixed up tonight. I am now working on cleaning things up and writing the documentation! A development thread for the JS frontend will be created soon.



Mostly completed project is now on Github. Check it out, and enjoy :)

Gk9OMsf - [ALPHA] stormcaster - RaGEZONE Forums
 

Attachments

You must be registered for see attachments list
Last edited:
Joined
Jul 12, 2011
Messages
1,229
Reaction score
475
Good news! After tinkering around with Lumen, I was able to port all the code I wrote yesterday back into Lumen. Functionally, these apps are exactly the same (same public API, and mostly the same source code). Stormcaster is now much faster!
 
Joined
Jul 12, 2011
Messages
1,229
Reaction score
475
Had some free time and was bored this morning, so I revived the project by transferring the codebase to Laravel 5.3 (I keep flip flopping, but now I'm stickin' with Laravel because there's less hacks involved in getting things to work).
Changelog since whenever I last worked on this:
- Upgrade from Lumen 5.1 -> Laravel 5.3
- Create unit tests for all existing functionality, and add TravisCI for convenience
- Add admin middleware to reduce code repetition
- Split admin actions into separate controller
- Add StyleCI for style checking
- Add CORS package for correct preflight headers

Haven't really added any new features yet, just made it nicer to work with and develop with in the future.
 
Infraction Baɴɴed
Loyal Member
Joined
Apr 9, 2008
Messages
1,416
Reaction score
169
looking at the code on git, it looks like a overly complex project for a few key features people use (registration, news, ranking, voting).

but it also looks like a nice project to expand your understanding of the language, just dont see the value of this for someone that runs 1 server.
 
Joined
Jul 12, 2011
Messages
1,229
Reaction score
475
can u actually explain wtf is this for people who don't do web

looking at the code on git, it looks like a overly complex project for a few key features people use (registration, news, ranking, voting).

but it also looks like a nice project to expand your understanding of the language, just dont see the value of this for someone that runs 1 server.

Sure. So consider current maplestory sites, eg MapleBit, that combine HTML and PHP. This is a very outdated way of writing websites, and for good reason. Mixing your logic with your presentation is messy, hard to test, hard to maintain, and hard to iterate. Frameworks like Laravel/RoR/etc. solve this with the MVC pattern. Going one step further, this project creates an API (client-server model) to interact with the database, so that the frontend (the "view" or what the user sees) can be written without knowing the implementation details. For example, if my webapp wanted to create an account, I would send a POST request to stormcaster with the username, password, and email, and I would either get a sucess or error message. The fact that my frontend is written in React or Angular doesn't matter to my backend. This means that server owners can iterate much much faster on designs, and don't have to bother rewriting large portions of their sites to drastically change their layout. Is it useful for people who never touch their website? Probably not. Is it useful for servers/developers that are looking to iterate their design rapidly? Absolutely.
I'm not sure what you find overly complex though!
 
Joined
Apr 10, 2008
Messages
4,087
Reaction score
1,264
I'm not sure what you find overly complex though!

Haven't found anything overly complex actually - I was just scrolling through and was too lazy to google all this.

Thanks for the reply - it seems like the most rational thing to do.. I'm really surprised it hasn't been done until now, so good job for you on that note.
 
Joined
Jul 12, 2011
Messages
1,229
Reaction score
475
Haven't found anything overly complex actually - I was just scrolling through and was too lazy to google all this.

Thanks for the reply - it seems like the most rational thing to do.. I'm really surprised it hasn't been done until now, so good job for you on that note.

Oh, sorry, I was replying to you both (holt commented that the project was complex). And yeah, I'm excited to be diving into React this break, so hopefully should have a nice demo of both components done in a couple weeks!
 
Back
Top