Modding Tutorials: Asset-Injection

Discuss modding questions and implementation details.
User avatar
MasonFace
Posts: 357
Joined: Tue Nov 27, 2018 7:28 pm
Contact:

Re: Modding Tutorials: Asset-Injection

Post by MasonFace » Mon Aug 26, 2019 1:16 pm

Ah, when I click dragged to grab just the "273" archive records for the package, I missed the first frame thinking that the XML was before all the other images... I didn't look carefully; sorry about that. :oops:

I've corrected the package and re-uploaded it for testing.

I know this wasn't the issue for my mod file because I used select all and got ALL the files in the folder and have verified that all frames are there.

Ghost Transparency Test 2

User avatar
TheLacus
Posts: 1012
Joined: Wed Sep 14, 2016 6:22 pm
Contact:

Re: Modding Tutorials: Asset-Injection

Post by TheLacus » Mon Aug 26, 2019 2:08 pm

Sorry, i wasn't clear in my previous post. The issue with the scale is what makes the billboard invisible: if you provide an xml file but not a custom scale, zero is incorrectly used as default. You can solve it if you manually provide a value of one, otherwise wait for next build when this will be the default value.

Code: Select all

<scaleX>1</scaleX>
<scaleY>1</scaleY>
Mod System documentation - Learn how to create mods for Daggerfall Unity.
Modder Discussion - General help and discussion for the mod system.
Github Issues - Submit a bug report for the game, including the mod system.

User avatar
MasonFace
Posts: 357
Joined: Tue Nov 27, 2018 7:28 pm
Contact:

Re: Modding Tutorials: Asset-Injection

Post by MasonFace » Mon Aug 26, 2019 4:33 pm

Ah, gotcha.

I tried adding the scale code to the XML file and the frame shows up again, but nothing is transparent. :cry:

I tried lowering the alpha on the source image down real low just in case it was just not very noticeable in game, but it didn't change anything.

User avatar
TheLacus
Posts: 1012
Joined: Wed Sep 14, 2016 6:22 pm
Contact:

Re: Modding Tutorials: Asset-Injection

Post by TheLacus » Mon Aug 26, 2019 7:28 pm

Ah, i didn't notice it. You are putting the rendering mode in the meta file for the record instead of the file for the archive. (check daggerfall-unity/modding/textures/#billboard > Mobile). Also note that you want to use Fade, not Transparent. ;)
Attachments
ghost.png
ghost.png (264.66 KiB) Viewed 1828 times
Mod System documentation - Learn how to create mods for Daggerfall Unity.
Modder Discussion - General help and discussion for the mod system.
Github Issues - Submit a bug report for the game, including the mod system.

User avatar
MasonFace
Posts: 357
Joined: Tue Nov 27, 2018 7:28 pm
Contact:

Re: Modding Tutorials: Asset-Injection

Post by MasonFace » Mon Aug 26, 2019 8:57 pm

Well, I changed the name of the XML file from "273_0-0.xml" to "273.xml" and changed the code to this:

Code: Select all

<?xml version="1.0"?>
<info>
	<renderMode>Fade</renderMode>
	<scaleX>1</scaleX>
	<scaleY>1</scaleY>
</info>
I made sure to include it in the .dfmod and built it per usual. Loaded up the game and now each frame has no transparency. :cry:
Fade.png
Fade.png (99.04 KiB) Viewed 1824 times
I still haven't updated DFTFU. Could that really cause this problem though? I'm running the MOD in DFU alpha 0.10.4.

User avatar
TheLacus
Posts: 1012
Joined: Wed Sep 14, 2016 6:22 pm
Contact:

Re: Modding Tutorials: Asset-Injection

Post by TheLacus » Mon Aug 26, 2019 10:18 pm

I tested it from the Unity Editor but i really should also have checked behaviour with a final build; i'll do it tomorrow. If you want, try running it from the Editor (place it inside StreamingAssets/Mods as usual) and, if it works, include a dummy material with the mod using Fade rendermode. That's should prevent optimization that strips unused shader keywords, which caused similar effects in the past.
Mod System documentation - Learn how to create mods for Daggerfall Unity.
Modder Discussion - General help and discussion for the mod system.
Github Issues - Submit a bug report for the game, including the mod system.

User avatar
MasonFace
Posts: 357
Joined: Tue Nov 27, 2018 7:28 pm
Contact:

Re: Modding Tutorials: Asset-Injection

Post by MasonFace » Tue Aug 27, 2019 2:55 am

Doesn't work in Unity. I included a material with the standard shader using "Fade" rendering mode and it didn't help. :cry:

If it's working on your end, then I must be doing something wrong on my end. You've spent enough of your time trying to help me; I'll keep investigating on my end and see if I can figure it out. I may reach out to you later if I still can't find a solution in a few days.

Thanks for your time, TheLacus!

User avatar
MasonFace
Posts: 357
Joined: Tue Nov 27, 2018 7:28 pm
Contact:

Re: Modding Tutorials: Asset-Injection

Post by MasonFace » Tue Aug 27, 2019 8:24 pm

I updated DFTFU to 1.8.5 and it seems to be working now!

Thanks for all your help, TheLacus! Ghosts are lookin' good now!

User avatar
TheLacus
Posts: 1012
Joined: Wed Sep 14, 2016 6:22 pm
Contact:

Re: Modding Tutorials: Asset-Injection

Post by TheLacus » Wed Aug 28, 2019 12:16 pm

That's good to hear!
Mod System documentation - Learn how to create mods for Daggerfall Unity.
Modder Discussion - General help and discussion for the mod system.
Github Issues - Submit a bug report for the game, including the mod system.

User avatar
MasonFace
Posts: 357
Joined: Tue Nov 27, 2018 7:28 pm
Contact:

Re: Modding Tutorials: Asset-Injection

Post by MasonFace » Mon Sep 02, 2019 3:03 pm

Sorry to dig this back up, but I just had someone post on the Nexusmods page for PVE that the ghosts are showing full black instead of transparency like in this screenshot from before.

I have confirmed that it is working as expected in Unity, but it doesn't work correctly in DFU on my computer. I've double checked that I have a dummy material packaged in the DFMOD file with the standard shader and fade rendering mode. I named the material "Fade_Dummy".

Can you double check and see if the previous package that you got working in DFTFU also works in the final build on your machine?

Post Reply