GI JOE RPG Launch
  1. #1
    LordEntrails's Avatar
    Join Date
    May 2015
    Location
    -7 UTC
    Posts
    18,412
    Blog Entries
    9

    Drag and Drop Items/Inventory Not Working for Some Objects

    So I have three data objects that have inventory/equipment lists. Characters, major NPCs, and Starships. I can drag and drop items onto the Character sheet inventory list, but not the other two. All of them can manually add items via iadd buttons/functions. What am I doing wrong?

    Here's the code for the fully working character sheet inventory:
    Code:
                <windowlist name="inventorylist">
                    <bounds>30,40,-49,-220</bounds>
                    <class>char_invitem</class>
                    <datasource>.inventorylist</datasource>
                    <script file="campaign/scripts/char_invlist.lua" />
                </windowlist>
    Here's the code for major NPC:
    Code:
                <windowlist name="equipment">
                    <frame name="frame_windowlist" offset="3,25,3,3" />
                    <anchored>
                        <left offset="9" />
                        <right offset="-7" />
                        <top offset="35" anchor="bottom" parent="benefits_list" relation="relative" />
                        <bottom offset="-16" />
                        <sizelimits>
                            <minimum height="40" />
                        </sizelimits>
                    </anchored>
                    <class>char_invitem</class>
                    <datasource>.inventorylist</datasource>
                    <columns>
                        <width>355</width>
                        <filldown />
                    </columns>
                    <script file="campaign/scripts/char_invlist.lua" />
                </windowlist>
    And here's the Starship (where I tried adding the acceptdrop, even though the character doesn't use it):
    Code:
                <windowlist name="inventorylist">
                    <anchored>
                        <left offset="11" />
                        <right offset="2" />
                        <top offset="186" />
                        <bottom offset="-9" />
                    </anchored>
                    <class>char_invitem</class>
                    <datasource>.inventorylist</datasource>
                    <allowcreate />
                    <allowdelete />
                    <acceptdrop>
                        <class>items</class>
                        <field>*</field>
                    </acceptdrop>
                    <columns>
                        <width>360</width>
                        <filldown />
                    </columns>
                </windowlist>
    (full code is in the frontierSpace ruleset on the forge, files charsheet_inventory.xml, sub_npc_major.xml, & ss_equip.xml)
    Last edited by LordEntrails; April 30th, 2025 at 04:13.

    Problems? See; How to Report Issues, Bugs & Problems
    On Licensing & Distributing Community Content
    Community Contributions: Gemstones, 5E Quick Ref Decal, Adventure Module Creation, Dungeon Trinkets, Balance Disturbed, Dungeon Room Descriptions
    Note, I am not a SmiteWorks employee or representative, I'm just a user like you.

  2. #2
    If you want it to function like a character's inventory, then you'll need to register it in the library that it has inventory. If you open CoreRPG's library file there is a comment section at the top that explains the possible registrations. You can even see how it's set up under the charsheet.
    Dominic Morta
    Ruleset Developer
    Smiteworks

    How to zip up your campaign if the Developers ask for it-How to zip up your campaign if the Developers ask for it

    How to provide an Unity Connection issue?-Connection Issues and What to Provide

    Unity Updater issue?-Updater Issues

    Classic and Unity Port Forwarding?-Fantasy Grounds Connections Explained

    Comcast or Cox ISP User?-Comcast XFinity and Cox Users

    Have a suggestion?-Feature Request

  3. #3
    LordEntrails's Avatar
    Join Date
    May 2015
    Location
    -7 UTC
    Posts
    18,412
    Blog Entries
    9
    Thanks. Lets see if I'm smart enough to figure that out

    Problems? See; How to Report Issues, Bugs & Problems
    On Licensing & Distributing Community Content
    Community Contributions: Gemstones, 5E Quick Ref Decal, Adventure Module Creation, Dungeon Trinkets, Balance Disturbed, Dungeon Room Descriptions
    Note, I am not a SmiteWorks employee or representative, I'm just a user like you.

  4. #4
    LordEntrails's Avatar
    Join Date
    May 2015
    Location
    -7 UTC
    Posts
    18,412
    Blog Entries
    9
    EDIT: NVM, testing shows that just that snippet won't work.
    So, for NPCs since they are already registered with CoreRPG but I only want to set one value, do I need to copy all the registration options in my child ruleset, or can I just add the new option value? Do I need to somehow indicate a merge or append or is the following all I need?

    Code:
    LibraryData.aRecords["npc"] = {
            tOptions = {
                bInventory = true,
            },
            }
    Last edited by LordEntrails; April 30th, 2025 at 05:40.

    Problems? See; How to Report Issues, Bugs & Problems
    On Licensing & Distributing Community Content
    Community Contributions: Gemstones, 5E Quick Ref Decal, Adventure Module Creation, Dungeon Trinkets, Balance Disturbed, Dungeon Room Descriptions
    Note, I am not a SmiteWorks employee or representative, I'm just a user like you.

  5. #5
    Yes, that should work; I believe that the tOptions combine.

    Regards,
    JPG

  6. #6
    LordEntrails's Avatar
    Join Date
    May 2015
    Location
    -7 UTC
    Posts
    18,412
    Blog Entries
    9
    I'll look at it more tomorrow. But my first try didn't work for either starships (which I already was declaring, I just added the option) and for NPCs which caused the library list to go blank. But I was getting an error and tons of warnings suddenly so I did something wrong.

    But, gotta sign off for the night. Appreciate the help.

    Problems? See; How to Report Issues, Bugs & Problems
    On Licensing & Distributing Community Content
    Community Contributions: Gemstones, 5E Quick Ref Decal, Adventure Module Creation, Dungeon Trinkets, Balance Disturbed, Dungeon Room Descriptions
    Note, I am not a SmiteWorks employee or representative, I'm just a user like you.

Thread Information

Users Browsing this Thread

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

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
TALES of the VALIANT

Log in

Log in