NineZero's Gun Expansion

NineZero's Gun Expansion

1M Downloads

heavy_assault_rifle and heavy_assault_rifle_1 use the same cgmmeta file

Ruxoxol opened this issue ยท 1 comments

commented

I made a resource pack with my rifle (AR53) and assigned its model to the heavy_assault_rifle_1 tag, but the data on the position of the model parts (assets\nzgmaddon\models\item\heavy_assault_rifle_1.cgmmeta) became common for the standard heavy ar model and for my alternative model and those the elements that I changed (muzzleflash and barrel) look correct on one model, but incorrectly on the other
as I noticed, there is no special cgmmeta file for the second model in the game files
basically, the original and child model loaded the child model data from the resource pack

Image

I'm still new to modding and creating resource packs, so don't judge harshly if my question is too stupid

commented

This is due to the way the model variants are handled. Both cosmetic variants of the Heavy AR are technically the same item as they use the same item ID, just with different parts rendered depending on the NBT. It's the same idea as the removable iron sights and rails on other guns in the mod, which only appear if an scope attachment is (or is not) attached.

The difference is that for the Heavy AR, the base model is switched out for another, instead of rendering an additional part. CGM still treats it as a single item model, so it only pulls data from heavy_assault_rifle.cgmmeta. So both variants will always share attachment and muzzle flash positions.

The idea behind cosmetic variants is to allow one gun to have slightly different variants (mainly colored areas or optional parts) without having to add multiple items. I'd like apologize for the lack of documentation on working with these variants.