summaryrefslogtreecommitdiffstats
path: root/src/rw/VisibilityPlugins.cpp
diff options
context:
space:
mode:
authoraap <aap@papnet.eu>2020-04-24 13:49:30 +0200
committerGitHub <noreply@github.com>2020-04-24 13:49:30 +0200
commit17dda21cca625d9c985dded2c3b80746eb937c01 (patch)
treec4be4fa57b16c61d45e8156a51dd07b11e049bba /src/rw/VisibilityPlugins.cpp
parentremoved fix that made no sense (diff)
parentimplemented skinned peds, no cutscene hands yet (diff)
downloadre3-17dda21cca625d9c985dded2c3b80746eb937c01.tar
re3-17dda21cca625d9c985dded2c3b80746eb937c01.tar.gz
re3-17dda21cca625d9c985dded2c3b80746eb937c01.tar.bz2
re3-17dda21cca625d9c985dded2c3b80746eb937c01.tar.lz
re3-17dda21cca625d9c985dded2c3b80746eb937c01.tar.xz
re3-17dda21cca625d9c985dded2c3b80746eb937c01.tar.zst
re3-17dda21cca625d9c985dded2c3b80746eb937c01.zip
Diffstat (limited to 'src/rw/VisibilityPlugins.cpp')
-rw-r--r--src/rw/VisibilityPlugins.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/rw/VisibilityPlugins.cpp b/src/rw/VisibilityPlugins.cpp
index 89bd13a6..7dc27f48 100644
--- a/src/rw/VisibilityPlugins.cpp
+++ b/src/rw/VisibilityPlugins.cpp
@@ -543,6 +543,21 @@ CVisibilityPlugins::RenderPedHiDetailCB(RpAtomic *atomic)
return atomic;
}
+// This is needed for peds with only one clump, i.e. skinned models
+// strangely even the xbox version has no such thing
+RpAtomic*
+CVisibilityPlugins::RenderPedCB(RpAtomic *atomic)
+{
+ int32 alpha;
+
+ alpha = GetClumpAlpha(RpAtomicGetClump(atomic));
+ if(alpha == 255)
+ AtomicDefaultRenderCallBack(atomic);
+ else
+ RenderAlphaAtomic(atomic, alpha);
+ return atomic;
+}
+
float
CVisibilityPlugins::GetDistanceSquaredFromCamera(RwFrame *frame)
{