Dynamic Character Sheets

1234579

Comments

  • ChainsawXIV
    ChainsawXIV
    Posts: 530
    Dynamic elements must be spans, so that could be the issue (last time I looked, the script searches through the spans on the page to do its thing, so anything else will be totally ignored).

    If that's not the issue, I'd look at any custom JavaScript you're running there. It's possible that you accidentally created a function which overrides something essential from the basic version, but doesn't do the right thing.
  • barsoomcore
    barsoomcore
    Posts: 15
    Okay, so I did have some dsf's that were in s and s, so that's been cleared up. There is no custom Javascript, so I'm quite sure I haven't broken anything there.

    However, do I need to load "characters.js" into the Javascript field in the dynamic sheet submission form? I've been leaving that field blank since I supply none of my own.
  • ChainsawXIV
    ChainsawXIV
    Posts: 530
    Leaving it blank should be to correct move... I'm really not sure what the problem could be at this point.
  • barsoomcore
    barsoomcore
    Posts: 15
    Yeah, I'm stumped. I appreciate the help, though. Maybe when Micah finds a spare moment he can have a look...
  • jbteller4
    jbteller4
    Posts: 4 edited September 2010
    I'm working on a Dresden Files DST. I'm familiar (enough) with HTML and CSS to do the basic DST. But there are two javascript functions that I'd like to copy from someone else and use: a) The clickable pips (though I'd like to reverse it so that the pips to the *right* of the click are filled in instead of to the left, if possible), and b) the ability to click to add a line (e.g. click '+' to add another Stunt or Power, etc.), plus the options to delete and move up or down lines.

    I know that Chainsaw XIV's Exalted sheet uses both of these functions. The problem is that I know practically zilch about JavaScript and only the most rudimentary basics on any type of scripting (I've done some simple vBasic stuff inside of MS Access at work and that's really it).

    So when I look through Chainsaw XIV's DST, I think I basically follow what he's doing, but I'm not at all confident that I know enough to copy and paste it into my DST in the right place, then make the right changes to have it work.

    I'm not even sure exactly where to begin or what questions to ask, so any and all help is appreciated. Like I said, I'm not familiar with javaScript and I'm trying to keep it simple, but those two functions would be very helpful

    Thanks in advance

    EDIT: Fixed some spelling.
    Post edited by jbteller4 on
  • Curufea
    Curufea
    Posts: 161
    @jbteller4 - ditto actually, I need to update the DWAITAS sheets to create new traits/fields on the fly - I haven't had time to look at jquery and calling on its functions - but I will be looking at Chainsaw's now!
  • ChainsawXIV
    ChainsawXIV
    Posts: 530
    Jbteller4, I can help you out when I get home tonight. For what you want to do, you should be able to use my scripts with very minor alternations (which I can make for you, or show you how to do yourself), and different images. If you use AIM or something like that, drop me a PM so I can walk you through it in real time.

    Curufea, brace yourself for at least a little bit of hackery. There are some interesting tricks used to work within the existing DST data storage system and such. That being said, the code is designed to be reused and easily adapted. If you have any questions, don't hesitate to ask me. I'll be happy to help out. I can also provide the original files if you like.
  • lphillips
    lphillips
    Posts: 1
    What's the policy on editing templates authored by another user? Specifically, I'm interested in making a Lunar variant of ChainsawXIV's Solar-centric Exalted sheet. I just want to add a section for Knacks and add pips for making Attributes favored -- stuff like that.

    Also, I'm new to Obsidian Portal and dynamic sheet templates, so I'm not sure where to download the source files for templates. It looks like they were once stored on github, but now they're served from Obsidian Portal's database? That's what I gathered from the tutorial and the github site, at any rate. Any pointers about how to download template source (or just something to read to get up to speed on that) would be much appreciated.
  • ChainsawXIV
    ChainsawXIV
    Posts: 530
    Well, as far as I'm concerned, you're welcome to create a lunar version of the Exalted sheet. I chose to do a solar one on account of that's what I was actually playing, but there's no reason it shouldn't support all kinds, and no sense in starting from scratch. I can send you the source code if you like, and help figure things out - just drop me a PM with an email to send it to.
  • Curufea
    Curufea
    Posts: 161 edited September 2010
    ChainsawXIV - I've basically used all your javascript as there are calls to create areas for the dynamic list creation text inputs- but I've removed the pips and tabs. Works fine currently - "DWAITAS sheet":http://www.obsidianportal.com/dynamic_sheet_templates/21

    Here's an "example of the new sheet":http://www.curufea.com/Wikka/uploads/FactionDW/justine.png

    Thanks for the help!
    Post edited by Curufea on
  • ChainsawXIV
    ChainsawXIV
    Posts: 530
    Nice! Glad I could help!
  • GunbunnyFuFu
    GunbunnyFuFu
    Posts: 6
    Any DCS in the works for Warhammer 2E?
  • Grokkit
    Grokkit
    Posts: 23
    Hi there,

    Has anyone noticed that the D&D 4e Dynamic Character Sheet is no longer rendering correctly in IE? All the columns on the crunch tab are now in the first column on the left instead of evenly spread out across the 3 columns.

    Ideas?
  • Curufea
    Curufea
    Posts: 161
    My first thought is that the newer version of textile must be parsing some of it that it shouldn't or that the CSS has changed for OP as a whole. I can only speculate though.
  • ChainsawXIV
    ChainsawXIV
    Posts: 530 edited October 2010
    Most likely you've turned on compatibility view (the little broken page icon just right of your address bar) for the page. It looked fine to me in IE when I checked it, but it's just as you described if you turn that on. Turning it on basically makes IE8 act like an older version, and is designed to be turned on only for pages that need it (those pages which haven't been updated in years, mostly). Try turning it off and let me know if that helps.

    Edit: There's also an apparently new issue where, in IE only, the template doesn't load its styles correctly when you first select it from the list. Save the character however, and it will work fine. That will be a bug on Micah's end of things I suspect. From the look of it, it's not successfully loading the style sheets on the fly. If I had to guess, I'd bet that an updated version of jquery isn't working quite right with the existing code or something similar.
    Post edited by ChainsawXIV on
  • Grokkit
    Grokkit
    Posts: 23
    Thanks Chainsaw... I should have caught that. It's not the first time that the compat mode setting has dinged me. As for the other issue... I did notice that and corrected after saving. Not a show stopper in the least.
  • Mach5RR
    Mach5RR
    Posts: 3 edited October 2010
    barsoomcore, I believe I know what is wrong with your build. When I was, ahhhh, "borrowing" your code for a True20 DST I noticed that your CSS sheet refers to "dinopirates"; however, your slug on the dynamic sheets template page refers to "dino-pirates" (ie with a dash). I believe these should match. Either edit your slug (easiest IMO) or edit your CSS and your problem should be resolved.
    Post edited by Mach5RR on
  • jbteller4
    jbteller4
    Posts: 4
    I just submitted my DST for the Dresden Files RPG and made a few small corrections for issues I hadn't noticed on my end before uploading. Thanks again to Chainsaw for helping with the pips and the click to add a row lists.
  • NerdimusPrime
    NerdimusPrime
    Posts: 1
    Chainsaw, thanks very much for the Exalted DST! I love it, and it will come in very handy when our campaign starts up. I have a technical question about it though: Is the 7-dot limit on Essence and Willpower score by design, or are my browsers (Safari and Chrome) cutting them off?
  • barsoomcore
    barsoomcore
    Posts: 15
    Mach5rr: Yep, that did the trick! Thanks so much! Now I've spent the afternoon sorting out all the CSS that wasn't working, but at least the thing works.

    Really appreciate your help. Also, do NOT recommend making use of my stuff -- I'm actively bad at this sort of thing and will lead you into terrible directions.
  • ChainsawXIV
    ChainsawXIV
    Posts: 530
    NerdimusPrime, I've been meaning to fix that for a while and just haven't gotten to it. It's dead easy, since the interface already supports up to ten dots, so I'll try to get it done sooner rather than later. Truth be told, it's only set to seven at the moment because it fits better in the space available, and I got tired of mucking about with the formatting.
  • Micah
    Micah
    Posts: 894
    I've added DSTs to the API. You can see more here: http://help.obsidianportal.com/faqs/api/api-dynamic-sheet-templates

    I have a cool idea on how to use this. I'll put up a blog post with more info.
  • TheSouljourner
    TheSouljourner
    Posts: 22
    BTW Tinkeron, I totally ganked your Hero System DST and mangled it for my own purposes. Hope you don't mind. It's great, I just wanted a few tweaks to make it more compact.
  • Squirrelboy38
    Squirrelboy38
    Posts: 5 edited December 2010
    I got a lot to do with setting up an Eclipse Phase campaign. Once I am done with it all I will try to help out with an Eclipse Phase DST if it is still needed and the other guy hasn't completed one yet.
    Post edited by Squirrelboy38 on
  • udalrich
    Posts: 7
    Is there an example of how to implement a "Add new skill" button? I have an idea how I would do it, but if there's an example that I can modify, that would be great. Something as simple as "look at the element with class dsf_foo in this sheet" would probably be enough.

    If I am going to add elements that are jeditable, do I need to do that in the preload hook? If so, that seems difficult, since I am not sure how to get the values of the fields there without accessing dynamic_sheet_attrs, which I think is considered private.
  • udalrich
    Posts: 7 edited January 2011
    I was testing a version of a Pathfinder DST, and I am confused by some text on "page on creating a DST":http://help.obsidianportal.com/kb/advanced/creating-a-dynamic-character-sheet-template-dst.

    That page says

    A DST allows for marking up the underlying structured metadata for an RPG character. At least in the beginning, we will be reducing every character down to a set of key-value pairs. For example, here's a highly simplified D&D character expressed as a set of key-value pairs:

    {
    "name" : "Tordek",
    "race" : "Dwarf",
    "class" : "Fighter",
    "level" : 12
    }

    Is there a way to enter that data into the character (in that format or similar) and have the sheet populated. My intention was to create the character in something like PCGen (which understands and enforces the rules) and have it output the character in a format like that. Then I could cut and paste to Obsidian portal. If I have to click, type and click on each field, it makes the DST much less useful.
    Post edited by udalrich on
  • udalrich
    Posts: 7
    It looks like there's a bug in the code for editing/saving a character. Look at "this character":http://www.obsidianportal.com/campaigns/udalrich-s-test-campaign/characters/test-cleric?value=Fred

    (You might need to do some magic to use the unapproved DST.)

    Near the bottom is a table labeled "Spells Known". In it, you will see a text box and an OK button, as if you were editing it. I think what happened was I clicked the field to edit it, then clicked on Save, so it saved the html to create the button as the value of the field.
  • ChainsawXIV
    ChainsawXIV
    Posts: 530
    Hey there Udalrich.

    Doing dynamic lists requires some semi-complex JavaScript gymnastics, but conveniently I've already written it, for use in the 4th Edition and Exalted sheets, and one or two other developers have also borrowed it for theirs. Send me a PM with an email address, and I'll send along the files for your perusal - much easier to get through than digging through page source.

    There's not presently a simple way of doing what you want to do for direct data entry from another file type. It is technically feasible using the latest or upcoming features of the API with a stand alone application or hosted web script, but I don't know of anyone having actually set that up just yet. You may wish to peruse the API thread for more information.

    At a glance, the bug you're describing shouldn't be happening. The jeditable interface is generally good about closing out whenever you click anywhere else but on it, which should protect against it, but there may be an edge case where that's not working. I'd suggest reporting it to the sight admins (read: Micah) as a bug through the help system.
  • jwalduck
    jwalduck
    Posts: 3
    I am working on a DST and am having problems with jQuery not being recognised.

    Here is an example:

    function requiem_dataChange(opts){
    alert('requiem_dataChange');
    if ( $('.dsf_'+opts.fieldName).hasClass('pips') ) {
    alert('requiem_dataChange converts ' + opts.fieldName);
    }
    }

    When this is in a DST it is fired on data change - the first alert comes up - but then it errors and reports:
    Property '$' of object [object DOMWindow] is not a function
  • ChainsawXIV
    ChainsawXIV
    Posts: 530 edited January 2011
    I expect the issue here is that you're attempting to use a common shorthand (_$_ commonly represents _document.getElementById_ commonly, and in jQuery various other element finding functions, depending on the parameter) which isn't defined in the context of your script. I could explain how to do this with old fashioned javaScript if you like, but I'm not really conversant in jQuery, so unfortunately I couldn't tell you how to get into the proper context to do it that way.

    [Edit to add more jQuery specific information]
    Post edited by ChainsawXIV on
Sign In or Register to comment.

April 2024
Season of Strife

Read the feature post on the blog
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