5E Product Walkthrough Playlist
Page 2 of 2 First 12
  1. #11
    Varsuuk's Avatar
    Join Date
    Dec 2015
    Location
    New York
    Posts
    2,075
    Yup, that fixed it.

    I changed my definition to:

    Code:
    	<template name="list_text" merge="join">
    		<windowlist>
    			<child mergerule="resetandadd"></child>
    			<child><backcolor>1A40301E</backcolor></child>
    			<allowcreate />
    			<allowdelete />
    			<script file="common/scripts/list_text.lua" />
    		</windowlist>
    	</template>
    And added the "onSortCompare" from above to the newly copied "list_text.lua" file I grabbed from CoreRPG.


    I assume that was my only choice? Anyone have any better suggestions for me than copying code whole cloth like that?

  2. #12
    Varsuuk's Avatar
    Join Date
    Dec 2015
    Location
    New York
    Posts
    2,075
    EDIT:

    Turns out - I could ignore what I did above.

    ie: delete the copied text_list.lua from CoreRPG.
    Remove the entry for templates_list.xml in extension.xml in my extension (and delete the xml file)

    because this in the record_char_more.xml file handles it for each control I wanted that functionality on:

    Code:
    			<!-- Customize sorting for the Attributes list -->
    			<list_text name="cliroller1" merge="join">
    				<script file="utility/scripts/sort_methods/sort_on_alt_sort_order.lua" />
    			</list_text>

    oops - I guess I left some orphaned stuff in git and forgot.


    ===> So the TAKEAWAY I should learn here, correct if wrong:

    If I added the <script> to a redefined (with merge="join") template of same name "list_text" only the <script> in MY override goes into effect. BUT if I merely do an override of an named INSTANCE of that template (e.g. <list_text name="cliroller1" merge="join">) - I am able to ADD more "code" to the template's ummm... "code space?"

    ??
    Last edited by Varsuuk; August 9th, 2020 at 05:56.

  3. #13

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
  •  
5E Character Create Playlist

Log in

Log in