May 15, 20187 yr Looking at how conversation textures are loaded: private void LoadConversationSmallTexture() { if (!string.IsNullOrEmpty(this.m_textureConversationSmallPath)) { this.m_textureConversationSmall = Portrait.LoadTexture2DFromPath(this.m_textureConversationSmallPath, 76, 96); } this.NotifyChanged(); } I'm not sure what happens when m_textureConversation[small|Large]Path is empty, but if it is empty, it would be preferable to fallback to m_texture[small|Large]Path, so that we can create large and small portraits without worrying about also creating large and small conversation portraits. In other words: private void LoadConversationSmallTexture() { string texturePath = string.IsNullOrEmpty(this.m_textureConversationSmallPath) ? this.m_textureSmallPath : this.m_textureConversationSmallPath; this.m_textureConversationSmall = Portrait.LoadTexture2DFromPath(texturePath, 76, 96); this.NotifyChanged(); } Edited May 16, 20187 yr by fireundubh
May 15, 20187 yr This is an unrelated note to your thread, but can you tell me what you are using to (I assume) decompile the code to take a look at behaviors? I'd like to take a look to see how specific things are being handled for modding purposes.
May 15, 20187 yr Author This is an unrelated note to your thread, but can you tell me what you are using to (I assume) decompile the code to take a look at behaviors? I'd like to take a look to see how specific things are being handled for modding purposes.dnSpy.
May 16, 20187 yr This is already the behavior, it's just implemented a little differently that you're expecting - Portrait.GetTexture returns the non-conversation portraits if conversation portraits aren't available.
May 16, 20187 yr Author This is already the behavior, it's just implemented a little differently that you're expecting - Portrait.GetTexture returns the non-conversation portraits if conversation portraits aren't available. Awesome! Thank you for the heads-up. edit: I see it now! case Portrait.Style.ConversationLarge: return (!this.m_textureConversationLarge) ? this.m_textureLarge : this.m_textureConversationLarge; case Portrait.Style.ConversationSmall: return (!this.m_textureConversationSmall) ? this.m_textureSmall : this.m_textureConversationSmall; Edited May 16, 20187 yr by fireundubh
Create an account or sign in to comment