summaryrefslogtreecommitdiffstats
path: root/src/entities/Entity.cpp
diff options
context:
space:
mode:
authoraap <aap@papnet.eu>2020-05-17 20:20:14 +0200
committerGitHub <noreply@github.com>2020-05-17 20:20:14 +0200
commit8a7210cad162930e800f9632afd99ec15a75ebcf (patch)
treeb4f2b7bcc798fbc86867839b00cb9b79fd6eecf1 /src/entities/Entity.cpp
parentloading screens (diff)
parentWeapon fixes and thingies (diff)
downloadre3-8a7210cad162930e800f9632afd99ec15a75ebcf.tar
re3-8a7210cad162930e800f9632afd99ec15a75ebcf.tar.gz
re3-8a7210cad162930e800f9632afd99ec15a75ebcf.tar.bz2
re3-8a7210cad162930e800f9632afd99ec15a75ebcf.tar.lz
re3-8a7210cad162930e800f9632afd99ec15a75ebcf.tar.xz
re3-8a7210cad162930e800f9632afd99ec15a75ebcf.tar.zst
re3-8a7210cad162930e800f9632afd99ec15a75ebcf.zip
Diffstat (limited to 'src/entities/Entity.cpp')
-rw-r--r--src/entities/Entity.cpp33
1 files changed, 16 insertions, 17 deletions
diff --git a/src/entities/Entity.cpp b/src/entities/Entity.cpp
index 6f8ebcb4..b35ddb25 100644
--- a/src/entities/Entity.cpp
+++ b/src/entities/Entity.cpp
@@ -400,22 +400,6 @@ CEntity::PreRender(void)
GetMatrix().UpdateRW();
UpdateRwFrame();
}
- }else if(IsPickupModel(GetModelIndex())){
- if(((CObject*)this)->bIsPickup){
- CPickups::DoPickUpEffects(this);
- GetMatrix().UpdateRW();
- UpdateRwFrame();
- }else if(GetModelIndex() == MI_GRENADE){
- CMotionBlurStreaks::RegisterStreak((uintptr)this,
- 100, 100, 100,
- GetPosition() - 0.07f*TheCamera.GetRight(),
- GetPosition() + 0.07f*TheCamera.GetRight());
- }else if(GetModelIndex() == MI_MOLOTOV){
- CMotionBlurStreaks::RegisterStreak((uintptr)this,
- 0, 100, 0,
- GetPosition() - 0.07f*TheCamera.GetRight(),
- GetPosition() + 0.07f*TheCamera.GetRight());
- }
}else if(GetModelIndex() == MI_MISSILE){
CVector pos = GetPosition();
float flicker = (CGeneral::GetRandomNumber() & 0xF)/(float)0x10;
@@ -437,7 +421,22 @@ CEntity::PreRender(void)
CCoronas::FLARE_NONE, CCoronas::REFLECTION_ON,
CCoronas::LOSCHECK_OFF, CCoronas::STREAK_OFF, 0.0f);
}else if(IsGlass(GetModelIndex())){
- PreRenderForGlassWindow();
+ if(!((CSimpleModelInfo*)CModelInfo::GetModelInfo(GetModelIndex()))->m_isArtistGlass)
+ PreRenderForGlassWindow();
+ }else if (((CObject*)this)->bIsPickup) {
+ CPickups::DoPickUpEffects(this);
+ GetMatrix().UpdateRW();
+ UpdateRwFrame();
+ } else if (GetModelIndex() == MI_GRENADE) {
+ CMotionBlurStreaks::RegisterStreak((uintptr)this,
+ 100, 100, 100,
+ GetPosition() - 0.07f * TheCamera.GetRight(),
+ GetPosition() + 0.07f * TheCamera.GetRight());
+ } else if (GetModelIndex() == MI_MOLOTOV) {
+ CMotionBlurStreaks::RegisterStreak((uintptr)this,
+ 0, 100, 0,
+ GetPosition() - 0.07f * TheCamera.GetRight(),
+ GetPosition() + 0.07f * TheCamera.GetRight());
}
// fall through
case ENTITY_TYPE_DUMMY: