Open elthran opened 6 years ago
I'll take a look. I might have fixed that in another branch.
It might be time to move away from Prebuilt Objects altogether ....
In my new modular code branch I think we could use the 'controller' code to add new user objects. e.g.
import controller.setup_account
# Create a new user in the database with a blank hero attached to it.
controller.setup_account("Marlen", "Brunner, "marlenspam@gmail.com", {})
This concept might still need a bit of work ... but it sets a benchmark for what the controller code needs to be able to do. It needs to be able to add uses to the game from a .csv file!
The idea behind the controller code is that we should be able to interact with the game without accessing the Web Interface. Anything the web interface/views can do ... we should be able to do with a function from the controller code. The views/web interface/app.routes should call the controller code for these interactions.
I want to delete the prebuilt elthran/haldon characters. That way we can just use the admin account by default for testing purposes, and if you want to test with a new character you can use elthran/haldon. Also, on the stable server characters should be deleted every month or so and for testing purposes we should definitely be starting from scratch to look for bugs.
Unfortunately, your "choose_character" code is causing trouble. If an account is prebuilt but doesnt have a character, it cant create one. It gets redirected to "choose_character" which makes no sense since you have none. This should be fixed soon, as we will be deleting characters but not accounts hopefully.