Joshua Stream Pre
Page 4 of 4 First ... 234

Thread: TopSecret SI

  1. #31
    Im trying to create a single field that will take one drag and drop of a single roll. Just like how you do all the rolls under <list_text/> but instead of it being a list, its one single item.

    <string name="Weapon1">
    <anchored to="weapons" position="insidetopleft" offset="30,40" width="100" />
    <font>sheetlabel</font>
    <class>cli_rolls</class>
    <acceptdrop>
    <class>cas</class>
    <field>*</field>
    </acceptdrop>
    <frame>
    <name>textline</name>
    <offset>2,0,2,0</offset>
    </frame>
    </string>

  2. #32
    damned's Avatar
    Join Date
    Mar 2011
    Location
    Australia
    Posts
    23,188
    Blog Entries
    1
    Look at Race and Class

    MoreCore - Generic Ruleset
    --- Projects ---
    Extensions | Tutorials | MoreCore | MoreCore Themes | Call of Cthulhu | Maelstrom | FG Con

  3. #33
    I think i figured it out. I tweaked a version of the cli_rolls class and just added all the weapon stats plus a roll bound to dbdamage. Works good in testing. Its kind of important to do it this way because the attribute links to the weapon skills and that links to the weapon. Each one with its own modifiers being added along the way. Worried it might be too complex without instruction.

    Im going to start cleaning things up and try to get a initial copy out there. Hoping to get some feedback.

    weaponstest.png

    Quick question - is there a way to get the dbdamage to pick up the weapon name?

    <stringfield name="weapondmg" >
    <anchored to="weaponrng" position="left" offset="20" width="40" />
    <tabtarget prev="weaponname" next="weaponrng"/>
    <center/>
    <frame name="fielddark" offset="7,8,7,8" />
    <stateframe>
    <hover name="rowshade" offset="7,8,7,8" />
    </stateframe>
    <script>
    function onDoubleClick(x,y)
    local dicerolltmp = tostring(window.weapondmg.getValue());
    CustomDiceManager.processRoll("dbdamage", dicerolltmp)
    end
    </script>
    </stringfield>
    Last edited by Pharo; January 29th, 2021 at 07:02.

  4. #34
    Answered my own question .. given enough persistence ..

    function onDoubleClick(x,y)
    local sParams = tostring(window.weapondmg.getValue());
    local rSource = tostring(window.name.getValue());
    local rActor = ActorManager.getActor("pc", window.getDatabaseNode().getParent().getParent());
    sParams = sParams .." "..rSource;
    CustomDiceManager.performAction("dbdamage", nil, rActor, sParams)
    end


  5. #35
    damned's Avatar
    Join Date
    Mar 2011
    Location
    Australia
    Posts
    23,188
    Blog Entries
    1
    Sorry Pharo I missed that there was a Q in there. Well done!

    MoreCore - Generic Ruleset
    --- Projects ---
    Extensions | Tutorials | MoreCore | MoreCore Themes | Call of Cthulhu | Maelstrom | FG Con

  6. #36
    Still so much I want to fix but running out of free time.

    Any feedback would be welcome.
    Attached Files Attached Files

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Fantasy Grounds Fridays Pre

Log in

Log in