Hi guys, how is it going?
Recently I posted here
https://openxcom.org/forum/index.php/topic,5364.0.html about suggestions I wanted to see in Open X-Com and I'm trying to implement suggestion 1, which is a new way of loading and saving layouts based on the soldier's weight.
I know nothing about modding Open X-Com, but I am very inspired by this Merge Pull Request
https://github.com/SupSuper/OpenXcom/commit/5e5281930b79a3b8edd1e04a9ba9a9600dea3284 from @myk002 that shows how the original load/save was put in the game, so I know what files I need to modify.
I need to add new buttons to the inventory, so in the file standard/xcom1/extraSprites.rul I added this:
- type: InvWeightCopy
width: 8
height: 8
singleImage: true
files:
0: Resources/UI/invweightcopy.png
- type: InvWeightPaste
width: 8
height: 8
singleImage: true
files:
0: Resources/UI/invweightpaste.png
But I'm having a compilation problem. This one:
No idea how to solve it. On the original merge pull request, I saw that "- type: InvCopy" is only on that file and has no other reference to it, besides the .cpp and .h files. Also, the metadata.yml on the same folder is very simple and has no references to InvCopy either, so no clue why that error is happening.
For reference, the original code what works is this one:
- type: InvCopy
width: 16
height: 16
singleImage: true
files:
0: Resources/UI/invcopy.png
I checked the image is not the problem because the compiler gives the same error even when I use one image that's already on the folder. The problem is the line "- type: InvWeightCopy"
I'm using a Mac and working on the project using XCode.
Any thoughts?
By the way, this is exactly what I want to achieve. More on that in the specific thread.
Thanks!
Marco