Fix client-side out-of-bounds '[combine' warnings

This commit is contained in:
SmallJoker 2025-03-16 18:49:40 +01:00
parent a0ed992121
commit 247bcdd058

View File

@ -109,7 +109,7 @@ function skin_class:get_preview()
--Right Leg --Right Leg
skin = skin .. "([combine:16x32:0,0=" .. player_skin .. "^[mask:skindb_mask_rleg.png)^" skin = skin .. "([combine:16x32:0,0=" .. player_skin .. "^[mask:skindb_mask_rleg.png)^"
-- 64x skins have non-mirrored arms and legs -- 64x64 skins have non-mirrored arms and legs
local left_arm local left_arm
local left_leg local left_leg
@ -126,17 +126,21 @@ function skin_class:get_preview()
--Left Leg --Left Leg
skin = skin .. left_leg skin = skin .. left_leg
-- Add overlays for 64x skins. these wont appear if skin is 32x because it will be cropped out if self:get_meta("format") == "1.8" then
--Chest Overlay -- Add overlays for 64x64 skins. This check is needed to avoid
skin = skin .. "([combine:16x32:-16,-28=" .. player_skin .. "^[mask:skindb_mask_chest.png)^" -- client-side out-of-bounds "[combine" warnings.
--Right Arm Overlay
skin = skin .. "([combine:16x32:-44,-28=" .. player_skin .. "^[mask:skindb_mask_rarm.png)^" --Chest Overlay
--Right Leg Overlay skin = skin .. "([combine:16x32:-16,-28=" .. player_skin .. "^[mask:skindb_mask_chest.png)^"
skin = skin .. "([combine:16x32:0,-16=" .. player_skin .. "^[mask:skindb_mask_rleg.png)^" --Right Arm Overlay
--Left Arm Overlay skin = skin .. "([combine:16x32:-44,-28=" .. player_skin .. "^[mask:skindb_mask_rarm.png)^"
skin = skin .. "([combine:16x32:-40,-44=" .. player_skin .. "^[mask:(skindb_mask_rarm.png^[transformFX))^" --Right Leg Overlay
--Left Leg Overlay skin = skin .. "([combine:16x32:0,-16=" .. player_skin .. "^[mask:skindb_mask_rleg.png)^"
skin = skin .. "([combine:16x32:4,-32=" .. player_skin .. "^[mask:(skindb_mask_rleg.png^[transformFX))" --Left Arm Overlay
skin = skin .. "([combine:16x32:-40,-44=" .. player_skin .. "^[mask:(skindb_mask_rarm.png^[transformFX))^"
--Left Leg Overlay
skin = skin .. "([combine:16x32:4,-32=" .. player_skin .. "^[mask:(skindb_mask_rleg.png^[transformFX))"
end
-- Full Preview -- Full Preview
skin = "(((" .. skin .. ")^[resize:64x128)^[mask:skindb_transform.png)" skin = "(((" .. skin .. ")^[resize:64x128)^[mask:skindb_transform.png)"