DST for Items

dragondreams
dragondreams

Seeing as how the Item pages were cloned from Characters...

I am working on a campaign using Mekton - where you have player characters and also Mecha (like Jaegers in Pacific Rim, as well as a boat load of mecha based anime and manga... Gundham, Evangelion, Macross, etc.:-).)  These defimnitely have (in some cases) fancier build/item sheets than the people do - LOL.  There may be other cases where you maybe have a bit of a build sheet for some airplanes or maybe magic swords or something, etc.

Anyhow - I am debating whether I stuff those under characters but thought maybe if its not that hard to ask to have build sheets for Items seeing as they came from characters.  

Just a thought.

Thanks!

  

Comments

  • thaen
    thaen
    Posts: 580

    Thanks for the request!

    For this, on the Items, I'd start out with just using static HTML/CSS in the Description or Bio.  Is there a reason you would need the JavaScript part of the DST for this?

    Obsidian Portal Developer

  • dragondreams
    dragondreams
    Posts: 24

    Hello!  

    This is a character sheet for Mekton Zeta - https://rtalsoriangames.com/wp-content/uploads/2013/01/zcharacter156.pdf ;

    This is a sheet for a 'item' Mecha (i.e. like the Jaeger Striker Eureka in Pacific Rim): https://rtalsoriangames.com/wp-content/uploads/2013/01/zbuild112.pdf ;

    For Items, do I have the capabilities to retrieve the values of the item attributes, i.e.:


    <span class="dsf dsf_weapon1_WA"></span>

    How do I add attributes like I can by the definitions in the DST HTML part ? 

    I (currently - still learning :-) ) see the use of DST Javascript two ways - one for being able to edit the item sheet as you would a character sheet (just some fancier niceties you can do with JS), and two certainly for the dynamic HTML document attribute generation that makes character sheets like the Exalted ones by ChainsawXIV just flippin' unbelievable, :-).

    Does the current 'Character API' also work for items?  I could then make a separate method to do editing and then publish to the Item API?   (provided that I can get past where I'm currently stuck - the step 1 authorization call, LOL .)

    (Thanks, BTW for responding to my dumb questions, :-) )

    Now, I would not expect all items to be as complicated as a Mecha, but I can imagine for a Fantasy Campaign, having a DST to create magic swords, rigs, etc. , could be handy, :-).

    Does that make sense?

     

    Thanks again!

    Stephani

     

      

     

     

  • thaen
    thaen
    Posts: 580

    "(Thanks, BTW for responding to my dumb questions, :-) )"

    I'm more than happy to!  It is impossible for anyone here to ask a dumb question.  Any question I don't understand, just means I'm missing the context, or I haven't shared enough context.

    Case in point...I now see how complex these Mecha sheets are.

    I don't see that level of complexity for most "items" (like a magical sword)...whereas most Characters are going to have some number of fields that interact (strength improves attack, for example), so I doubt we'll implement DSTs for Items.  It would add complexity to the Items page, but not benefit most of the members using the Items pages.

    My recommendation for "static HTML/CSS" would not give you any of the pretty editing.  You would be editing HTML every time you wanted to change an attribute.  With a smaller amount of fields and HTML, that seems manageable to me, but with this many fields, I can see why it would not be manageable.

    For the Mechas...how many different sheets are there?  Could the Character DST actually have a dropdown selection in the DST that allowed you to choose which Mecha you had, which would then present all of the fields for that Mecha sheet?  Essentially all of the "Mecha DSTs" could live inside of the "Character DST".

    "Does the current 'Character API' also work for items?  I could then make a separate method to do editing and then publish to the Item API?   (provided that I can get past where I'm currently stuck - the step 1 authorization call, LOL .)"

    Sorry!  My understanding is that the API authorization is currently broken, and it's a low priority compared to other things that need fixing, so it probably won't be fixed any time soon.

    Let me know if I missed answering anything.

    Obsidian Portal Developer

  • dragondreams
    dragondreams
    Posts: 24

    > My understanding is that the API authorization is currently broken

    LOL... then maybe cry a bit...  :-)  I kept looking for "API" in the Help and Community, but just assumed it was me making a mistake.  I tried every NodeJS and Javascript library out there and had been coding from scratch off the RFC5849 (that oath_signature is crazy).  I do know an awful lot about OATH1.0a (Three-legged) now :-).  Most of my other stuff (and work stuff) is OATH 2.0 or OpenID Connect.  

    I was thinking of storing the mecha on OP so that I can pull their stats over to the 'crude but it works' multi-player shared hex map I threw together and finally got working (let's just say the AWS documentation is 'fun' in some very important places, :-).)

    Is there any way to pull the Character Sheet info from another source?     

    Thanks again!

  • thaen
    thaen
    Posts: 580

    Again, sorry!  Moving to OAUTH 2.0 is the plan, but not high priority.

    If you only want the actual values of the stats, those are stored in the HTML of the Character itself.  So, if you're up for "coding from scratch", and assuming your Character is public, you should be able to pull that data directly from the url.  For example:

    https://tobuyafatpig.obsidianportal.com/characters/bodrin-hurald

    Take a look at the source of that page and search for "var dynamic_sheet_attrs = ", and you'll find all of the values paired with their field names.

    Is that what you were looking for?

    Obsidian Portal Developer

  • dragondreams
    dragondreams
    Posts: 24

    No need to be sorry!  I should have asked earlier, :-).  What about having a pinned Discussion in the Community Area like "Features with Known Issues" or something like that?

    On screen scraping - yes, that will definitely work :-).  Thanks!

    Getting back to DST for Items, the items don't have to be as crazy as mecha.  I was thinking like for a D&D campaign having that would make it easier for a DM to generate items.  

    There does not seem to be a lot of interest, :-).  So I certainly understand not making the cut.

    Thanks agian for listening!

  • thaen
    thaen
    Posts: 580

    It might be better for us to put a note right in the path of the member as they are trying to do this.  Where was the first place you went when you started trying to work with the API before you hit any issues?

    If we get more interest for DSTs for Items, then it would get more dev time.

    Obsidian Portal Developer

  • dragondreams
    dragondreams
    Posts: 24

    Hello!

    I think a good place would be :

    https://help.obsidianportal.com/article/82-api-overview ;

    under the Steps?

    and this whole page : https://help.obsidianportal.com/article/105-api-authentication-oauth

    Does that make sense?

    Thanks!

  • thaen
    thaen
    Posts: 580

    Makes perfect sense.  Thank you!  I've added an "UPDATE" note to both articles.  Thanks for helping to make things a little less painful for the next member to go down that path.  : )

    Obsidian Portal Developer

  • jodie
    jodie
    Posts: 74

    This would be amazing for fighters and star ships in my star wars and 40k games. 

  • jodie
    jodie
    Posts: 74

    Although my gm makes the star ships in 40k characters anyway because of their spirits. I should make another little dst. 

  • jodie
    jodie
    Posts: 74

    This came up again for our upcoming starwars d6 game - my GM asked me if I could make a DST for star wars ships and vehicles and I was like.... no sorry. I could make them characters. Then he was all - that would fill up the NPCs too much :(

  • thaen
    thaen
    Posts: 580

    Cool, so this is a request for "ships" as "Items".  Above I was suggesting that the Character DST could have a section for the Mecha, since it would be applied to the Character.  But that doesn't work for ships.

    And just so I'm clear, the drive for the GM to have a DST is so the GM doesn't have to edit html when updating the Ship's stats?

    A feature we've toyed with is the idea of a "click to edit" field on any WikiPage/AdventureLog/Item/Character.  So you could kind of create a "fill only" DST on any page and it wouldn't require Edit to change the text/data in those fields.  It wouldn't calculate anything, but it would be easy and clear to edit.

    Thoughts on that as a solution for this?

     

    Obsidian Portal Developer

  • jodie
    jodie
    Posts: 74

    That's interesting. I'd have to see it in action to really understand how it would work. Personally I'm not a fan of UX that forces mouse->keyboard->mouse (click, type, press okay). I like to be able to tab though inputs without the page shifting or going to my mouse. I also don't like the elements shifting.

    Yeah the DST for ships would pretty much just be to avoid the GM editing html/markdown. I mean it would be nice down the road to maybe have fancy dsts that will calculate things and roll damage and whatnot for ships, as they have attacks and defenses much like characters.

  • thaen
    thaen
    Posts: 580

    Good feedback on wanting to be able to tab between the fields.  Thanks!

    Fancy DSTs for Items is a pretty niche feature, so I can't say if it would ever make it to the top of the dev queue, but it's on the list.  If Community Members are reading this and want this feature, chime in.

    Obsidian Portal Developer

  • jodie
    jodie
    Posts: 74

    I think a click to edit feature would be pretty popular, and let a more technical player set things up for their GM.



    The solution Chainsaw did to switch elements to 'contenteditable' is really cool and supports tabbing without altering the page. It appears to be technically an experimental feature, but given chainsaw's code has been using it since.... 2014. I'd be surprised if it suddenly vanished. I think you end up having to listen to keydown though to catch changes so that can be fiddly.

Sign In or Register to comment.

July's Campaign of the Month is The Coldfall Sanction!

Read the feature post on the blog!
Or return to Obsidian Portal!

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Discussions