Coder Social home page Coder Social logo

Comments (11)

ogregoire avatar ogregoire commented on July 21, 2024 1

Well, that's kind of the point of me raising an issue rather than putting up a PR: currently "ability_bonuses" maps to an array, but if I were to make those changes, it would map to either an array for all races except Half-Elf or an object for Half-Elf (and other official races outside of the SRD, such as Changeling and Kalashtar). So for the sake of consistency, there should be a switch to a different template than the current array one.

So if that's OK with you my PR will contain changes to all races.

from 5e-database.

bagelbits avatar bagelbits commented on July 21, 2024

What do you think might be the best way to display this? I'm not sure it will really work with how the ability score increases are currently shown in the system.

from 5e-database.

ogregoire avatar ogregoire commented on July 21, 2024

I think a selection would be best, similar to how current selection exist. The current way is kind of flawed and the next one is rather flexible. But yeah, it's not the same as what currently exist. The template can be used for other half-mandatory, half-selection templates.

{
  "fixed": [{"ability": "CHA", "bonus": "+2"}],
  "selection": {
    "choose": 2,
    "from": [
      {"ability": "STR", "bonus": "+1"},
      {"ability": "DEX", "bonus": "+1"},
      {"ability": "CON", "bonus": "+1"},
      {"ability": "INT", "bonus": "+1"},
      {"ability": "WIS", "bonus": "+1"},
    ]
  }
}

from 5e-database.

bagelbits avatar bagelbits commented on July 21, 2024

Would it make sense to have the bonus as a string +1 or just as an integer? Even if you have a negative bonus, I think it would still make sense.

from 5e-database.

ogregoire avatar ogregoire commented on July 21, 2024

It would make sense, indeed. There are several instances of choice in the repository and I'd say the best is to be consistent with the rest of the repository. Abilities are usually added using integers so let's be consistent and use numbers instead of strings. I wrote that originally on my smartphone without thinking much, just trying to quickly match it with the other choices.

from 5e-database.

bagelbits avatar bagelbits commented on July 21, 2024

I think that sounds reasonable then. If you put together a PR, I'll be happy to look it over. I can't guarantee when I'll be able to make one.

from 5e-database.

bagelbits avatar bagelbits commented on July 21, 2024

I think it makes sense to make the change to all races. @adrpadua, any thoughts?

from 5e-database.

bagelbits avatar bagelbits commented on July 21, 2024

Actually, can you think of any examples where you can make the same stat choice twice? Or does it always have to be unique? As far as I know, you aren't supposed to for Half-Elf but I don't know if that is the general rule.

from 5e-database.

ogregoire avatar ogregoire commented on July 21, 2024

Kalashtar, an official race for D&D (not SRD), has CHA +1, WIS +1, Any +1 (including CHA and WIS).

from 5e-database.

bagelbits avatar bagelbits commented on July 21, 2024

I think that's fine. I meant more for where you choose multiple like Half-Elf but it would let you choose the same stat twice.

from 5e-database.

bagelbits avatar bagelbits commented on July 21, 2024

That was awesome! Thank you!

from 5e-database.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.