Jump to content

[LE] Understanding "Unable to bind script... because their base types do not match"


Recommended Posts

I see many posts online regarding "Unable to bind script... because their base types do not match," but these people are often trying to debug other people's mods. I'm trying to debug a mod I'm working on.

I have a script called TES4dark11chorroldropscript. It extends Container and needs to attach to 01031B2B (a CONT). It has a property named Dark11ChorrolSackRef_p which is an ObjectReference that needs to attach to 01031B44 (a REFR).

ScriptName TES4Dark11ChorrolDropScript extends Container Conditional
;Content Removed for Brevity
ObjectReference Property Dark11ChorrolSackRef_p Auto Conditional
;More Content Removed for Brevity

This error is written to the Papyrus log:

"error: Unable to bind script TES4dark11chorroldropscript to (01031B44) because their base types do not match"
From that message, I can glean two interpretations:
1. Papyrus is trying to bind TES4dark11chorroldropscript to 01031B44, but the base types do not match. TES4dark11chorroldropscript is a container while 01031B44 is an REFR, so the error message would make sense. The only probem is that TES4dark11chorroldropscript doesn't attach to 01031B44. I'll demonstrate this later.
2. The other interpretation is that Papyrus is trying to bind one of TES4dark11chorroldropscript's properties to 01031B44, but the base types do not match. This property would be Dark11ChorrolSackRef_p. It is an ObjectReference, and I am trying to bind it 01031B44. 01031B44 is a REFR. Those types do match. So again, I can't seem to make the error message match with reality.
In SSEEdit, looking up 01031B44 reveals this:
SSEEdit shows no VMAD records on this REFR. In other words, no script is attached to it. That seems to invalidate possibility #1.
In SSEEdit, looking up 01031B2B reveals this:
Notice that TES4dark11chorroldropscript is attached (under VMAD), and the Dark11ChorrolSackRef_p says, "01031B44."
Creation Kit shows the same information as SSEEdit. I can supply some Creation Kit screenshots too if they are helpful. Can someone please explain why I'm getting this error in the logs? Thank you.
Link to comment
Share on other sites

  • 11 months later...

A year late...

 

Unable to bind scripts because their base types do not match means:

 

[01/28/2015 - 10:14:39AM] Error: Unable to bind script DLC2WaterScript to alias Water on quest DLC2TTF2 (0401AAC8) because their base types do not match.
This error is caused by a script extending one type but being used on an incorrect type. In this particular instance, DLC2WaterScript incorrectly extended ObjectReference when it should have extended ReferenceAlias. This is an error that must be corrected by the mod's author. It should self correct when the game loads after it's been fixed, but only once the content is no longer actively being used.

 

 

Quoted from: https://www.afkmods.com/index.php?/topic/4129-skyrim-interpreting-papyrus-log-errors/

 

That said, the OP's script is extending Container whereas it should be extending ObjectReference. Container is the base form but all containers become object references when placed in the game world. Furthermore the container.psc file is empty of any functions or events. And all functions or events designed to work with containers (OnItemAdded, OnItemRemoved, GetItemCount etc) are housed on the ObjectReference script.

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...