Commit a36ee2e
committed
Add support for multiple mods for a single ref
- This is essentially a merge of the `multimod-wip` branch
- Previously, if you wanted multiple textures on a mod, the only way to do that was to author a new override texture with all the data you want and then use that instead of the game's preferred texture - which is a pain and breaks game features like dyeing with custom colors.
- You could specify multiple mods for a ref, but they would be initialized as "variants" - which you can only render one of at a time.
- Now you can have multiple mods for a ref which are not variants but use one of the variants as a parent. Just like the existing parent support, these will be rendered alongside the parent mod when it is active. Since each mod can specify its own mesh and textures, you can use different data for those without having to cram everything into one set.
- This is a bit tedious to work with in practice since you generally need to align the mod meshes in one blend file and then create a secondary blend file with just the child data for the secondary mod - then delete that data from the primary blend file. Export them both to different mmobj files and then create all the yaml files for the two mods. I should probably document this somewhere.
- This also opens the door for future features such as shader mods on some parts of an aggregate mod, if I ever decide to do that. But maybe reshade is better for that sort of thing.
- Performance: There is some additional housekeeping and some small allocations when the mod(s) are selected, but profiling with very sleepy indicates no real change in performance - after all the vast majority of the time no mod is even selected because the game is rendering something else.1 parent c9a1026 commit a36ee2e
File tree
8 files changed
+404
-125
lines changed- Native
- hook_core/src
- mod_load/src
- types/src
8 files changed
+404
-125
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
| 24 | + | |
24 | 25 | | |
25 | 26 | | |
26 | 27 | | |
| |||
730 | 731 | | |
731 | 732 | | |
732 | 733 | | |
733 | | - | |
| 734 | + | |
734 | 735 | | |
735 | | - | |
| 736 | + | |
736 | 737 | | |
737 | 738 | | |
738 | 739 | | |
| |||
745 | 746 | | |
746 | 747 | | |
747 | 748 | | |
748 | | - | |
749 | | - | |
750 | | - | |
751 | | - | |
752 | | - | |
753 | | - | |
754 | | - | |
755 | | - | |
756 | | - | |
757 | | - | |
758 | | - | |
759 | | - | |
760 | | - | |
761 | | - | |
762 | | - | |
763 | | - | |
764 | | - | |
765 | | - | |
766 | | - | |
767 | | - | |
768 | | - | |
769 | | - | |
770 | | - | |
| 749 | + | |
| 750 | + | |
| 751 | + | |
| 752 | + | |
771 | 753 | | |
772 | | - | |
773 | | - | |
774 | | - | |
| 754 | + | |
| 755 | + | |
775 | 756 | | |
776 | | - | |
| 757 | + | |
| 758 | + | |
| 759 | + | |
| 760 | + | |
| 761 | + | |
| 762 | + | |
| 763 | + | |
| 764 | + | |
| 765 | + | |
| 766 | + | |
| 767 | + | |
| 768 | + | |
| 769 | + | |
| 770 | + | |
| 771 | + | |
| 772 | + | |
| 773 | + | |
| 774 | + | |
| 775 | + | |
| 776 | + | |
| 777 | + | |
| 778 | + | |
| 779 | + | |
| 780 | + | |
| 781 | + | |
| 782 | + | |
| 783 | + | |
| 784 | + | |
| 785 | + | |
| 786 | + | |
| 787 | + | |
| 788 | + | |
| 789 | + | |
| 790 | + | |
| 791 | + | |
| 792 | + | |
| 793 | + | |
| 794 | + | |
| 795 | + | |
| 796 | + | |
| 797 | + | |
| 798 | + | |
| 799 | + | |
| 800 | + | |
| 801 | + | |
| 802 | + | |
777 | 803 | | |
| 804 | + | |
| 805 | + | |
778 | 806 | | |
779 | 807 | | |
780 | 808 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
| 20 | + | |
20 | 21 | | |
21 | 22 | | |
22 | 23 | | |
| |||
319 | 320 | | |
320 | 321 | | |
321 | 322 | | |
322 | | - | |
323 | | - | |
324 | | - | |
325 | | - | |
326 | | - | |
327 | | - | |
328 | | - | |
329 | | - | |
330 | | - | |
331 | | - | |
332 | | - | |
333 | | - | |
334 | | - | |
335 | | - | |
336 | | - | |
337 | | - | |
338 | | - | |
339 | | - | |
340 | | - | |
341 | | - | |
342 | | - | |
343 | | - | |
344 | | - | |
345 | | - | |
346 | | - | |
347 | | - | |
348 | | - | |
349 | | - | |
350 | | - | |
351 | | - | |
352 | | - | |
353 | | - | |
354 | | - | |
355 | | - | |
356 | | - | |
| 323 | + | |
357 | 324 | | |
358 | 325 | | |
359 | 326 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
34 | 37 | | |
35 | 38 | | |
36 | 39 | | |
| |||
0 commit comments