Skip to content

Commit

Permalink
Actually fixed weird tooltip model issue
Browse files Browse the repository at this point in the history
  • Loading branch information
ImUnicke committed Oct 27, 2022
1 parent 9855966 commit 111aabd
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions AllTheThings.lua
Original file line number Diff line number Diff line change
Expand Up @@ -1351,11 +1351,12 @@ GameTooltipModel.TrySetModel = function(self, reference)
end
end

if reference.model and reference.model > 0 then
local modelID = tonumber(reference.model);
if modelID and modelID > 0 then
self.Model:SetFacing(reference.modelRotation and ((reference.modelRotation * math.pi) / 180) or MODELFRAME_DEFAULT_ROTATION);
self.Model:SetCamDistanceScale(reference.modelScale or 1);
self.Model:SetUnit("none");
self.Model:SetModel(reference.model);
self.Model:SetModel(modelID);
self.Model:Show();
self:Show();
return true;
Expand Down

0 comments on commit 111aabd

Please sign in to comment.