mivalsten / ddb-dm-screen

MIT License
30 stars 10 forks source link

Refactoring of most of the redundant code #16

Closed jfabre closed 5 years ago

jfabre commented 5 years ago

There's a character class that contains all the logic for getting the data. A render method to handle the presentation logic and I tried to split everything by concerns. The ajax call and iframe loading is at the end.

Hp values are now scraped, so that should fix the current bug. I worked a little on the table presentation, but I think something much better could be done by using the DndBeyond's current css.

jfabre commented 5 years ago

Take the time your need, this is a big one. If there are changes you'd like me to make please let me know. I'm still a new DM, so I don't know exactly what I want to be shown, but I know I don't need the raw attributes values (15int, 14 str, etc.).

I think the last step would be to use the current site's style to make something more pretty than a table.

mivalsten commented 5 years ago

Wow, I'm jealous. How much experience in JS do you have? I'm extremaly grateful for your help.

I made some comments in the code. I'm new to actually collaborating with github, so I'm not sure if that sends a notification.

jfabre commented 5 years ago

Not that much honestly, I'm not a js programmer.. :) But I have been coding for over 10 years... and I have done a lot of js and coffeescript in those years.

mivalsten commented 5 years ago

Ok, looks like we will have to switch to desktop version for parsing after all, as not all elements are available at the same time. :(

tbbstny commented 5 years ago

After looking it over, font awesome may be the better way to go. More icons, plus icons for gaming. The 'circle' empty and filled and 'dot-circle' would provide nice three states for no proficiency, proficiency and expertiese. https://fontawesome.com/icons?d=gallery&c=gaming-tabletop,toggle&m=free

jfabre commented 5 years ago

I just commited something, but please be patient I noticed HP and AC aren't right.