Starfinder Playlist
Page 5 of 5 First ... 345
  1. #41
    I should note that even with the sample campaign I gave you - where I don't override parseNPCpower - you could easily put a printstack in your ruleset version and see that when I do the polymorph it never gets called - hence blank. Using equipped effects I can do my own printstack as in that one I do override pareseNPCpower. But in both cases, the behavior no longer triggers pareseNPCpower in your new way of doing things triggered by the drop only.
    Free(Forums/Forge) Extension(FGU 5E):
    Paid (Forge) Extension(FGU 5E):

  2. #42
    I did more digging it looks like addNPC in LIVE used to call parseNPCPower directly and addNPC in TEST no longer does. Nor does it trigger it when addNPC is called directly. Not all CT node addition occurs due to a drop. Some are due to direct calls to addNPC.
    Free(Forums/Forge) Extension(FGU 5E):
    Paid (Forge) Extension(FGU 5E):

  3. #43
    In the core ruleset, there are no direct calls to addNPC.

    If you need to call something analogous to addNPC, then you would you would call need to make a call like this with the new code:

    Code:
    	local tCustom = { sClass = "npc", sRecord = [sourcepath] };
    	CombatRecordManager.onRecordTypeEvent("npc", tCustom);
    Regards,
    JPG

  4. #44
    Quote Originally Posted by Moon Wizard View Post
    In the core ruleset, there are no direct calls to addNPC.

    If you need to call something analogous to addNPC, then you would you would call need to make a call like this with the new code:

    Code:
    	local tCustom = { sClass = "npc", sRecord = [sourcepath] };
    	CombatRecordManager.onRecordTypeEvent("npc", tCustom);
    Regards,
    JPG
    That Solved it - much appreciated. Just need to figure out the infinite loop as my only "known" problem left.

    Replace any addNPC calls with the above and all my CT action lines are there.
    Last edited by SilentRuin; June 28th, 2022 at 23:38.
    Free(Forums/Forge) Extension(FGU 5E):
    Paid (Forge) Extension(FGU 5E):

  5. #45
    Infinite loop solved, per Moon Wizard suggestion, replaced CombatManager.setCustomAddNPC(onHostAddNPC) call with the following:

    In onDesktopInit...
    Code:
    		savedOldFn = CombatRecordManager.getRecordTypePostAddCallback("npc");
    		CombatRecordManager.setRecordTypePostAddCallback("npc", onNPCPostAdd);
    With function...
    Code:
    function onNPCPostAdd(tCustom)
    	if savedOldFn then
    		savedOldFn(tCustom); -- assume if something there they call CombatManager2.onNPCPostAdd
    	else
    		CombatManager2.onNPCPostAdd(tCustom);
    	end
    	local nodeCT = tCustom.nodeCT;
    
    ... My Stuff ...
    Last edited by SilentRuin; June 29th, 2022 at 04:49.
    Free(Forums/Forge) Extension(FGU 5E):
    Paid (Forge) Extension(FGU 5E):

  6. #46
    There was a bug in CombatRecordManager.getRecordTypePostAddCallback that I just fixed in the beta Test channel.

    You shouldn't need the CombatManager2.onNPCPostAdd(tCustom); backup call any more.

    Code:
    function onNPCPostAdd(tCustom)
    	if savedOldFn then
    		savedOldFn(tCustom);
    	end
    	local nodeCT = tCustom.nodeCT;
    
    ... My Stuff ...
    Regards,
    JPG

  7. #47
    Quote Originally Posted by Moon Wizard View Post
    There was a bug in CombatRecordManager.getRecordTypePostAddCallback that I just fixed in the beta Test channel.

    You shouldn't need the CombatManager2.onNPCPostAdd(tCustom); backup call any more.

    Code:
    function onNPCPostAdd(tCustom)
    	if savedOldFn then
    		savedOldFn(tCustom);
    	end
    	local nodeCT = tCustom.nodeCT;
    
    ... My Stuff ...
    Regards,
    JPG
    I assume if it ever did come back null in this check I'd still have to call the CombatManager2.onNPCPostAdd - though I understand you've fixed it so it should not.
    Free(Forums/Forge) Extension(FGU 5E):
    Paid (Forge) Extension(FGU 5E):

  8. #48
    As this is my grab bag thread of things I've had to fix in my extensions for TEST - I figured I'd mention this one. Make sure you replace addNPC calls etc. with CombatRecordManager.onRecordTypeEvent - or you will pay for it in subtle ways.
    Last edited by SilentRuin; July 1st, 2022 at 18:36.
    Free(Forums/Forge) Extension(FGU 5E):
    Paid (Forge) Extension(FGU 5E):

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
  •  
STAR TREK 2d20

Log in

Log in