1
0
Fork 0
mirror of https://git.rip/DMCA_FUCKER/re3.git synced 2024-06-29 07:57:05 +00:00

mark file and fix screen offset

This commit is contained in:
Roman Masanin 2020-10-12 13:41:57 +03:00
parent e6a1ea9d4f
commit 56bb7d721a
2 changed files with 62 additions and 61 deletions

View file

@ -179,11 +179,11 @@ CSpecialFX::Render2DFXs(void)
CFont::SetScale(SCREEN_SCALE_X(1.5f), SCREEN_SCALE_Y(1.5f)); CFont::SetScale(SCREEN_SCALE_X(1.5f), SCREEN_SCALE_Y(1.5f));
CFont::SetJustifyOff(); CFont::SetJustifyOff();
CFont::SetBackgroundOff(); CFont::SetBackgroundOff();
CFont::SetCentreSize(SCREEN_WIDTH - 20); CFont::SetCentreSize(SCREEN_SCALE_FROM_RIGHT(20.0f));
CFont::SetCentreOff(); CFont::SetCentreOff();
CFont::SetPropOn(); CFont::SetPropOn();
CFont::SetColor(CRGBA(0, 255, 0, 200)); CFont::SetColor(CRGBA(0, 255, 0, 200));
CFont::SetFontStyle(FONT_STANDARD); FONT_LOCALE(FONT_STANDARD);
sprintf(gString, "%d", CTimer::GetFrameCounter() & 0x3F); // mb % 63 sprintf(gString, "%d", CTimer::GetFrameCounter() & 0x3F); // mb % 63
AsciiToUnicode(gString, gUString); AsciiToUnicode(gString, gUString);
CFont::PrintString(SCREEN_WIDTH * 8 / 10, SCREEN_HEIGHT * 8 / 10, gUString); CFont::PrintString(SCREEN_WIDTH * 8 / 10, SCREEN_HEIGHT * 8 / 10, gUString);
@ -204,11 +204,11 @@ CSpecialFX::Render2DFXs(void)
CFont::SetScale(SCREEN_SCALE_X(1.5f), SCREEN_SCALE_Y(1.5f)); CFont::SetScale(SCREEN_SCALE_X(1.5f), SCREEN_SCALE_Y(1.5f));
CFont::SetJustifyOff(); CFont::SetJustifyOff();
CFont::SetBackgroundOff(); CFont::SetBackgroundOff();
CFont::SetCentreSize(SCREEN_WIDTH - 20); CFont::SetCentreSize(SCREEN_SCALE_FROM_RIGHT(20.0f));
CFont::SetCentreOff(); CFont::SetCentreOff();
CFont::SetPropOn(); CFont::SetPropOn();
CFont::SetColor(CRGBA(100, 100, 100, 200)); CFont::SetColor(CRGBA(100, 100, 100, 200));
CFont::SetFontStyle(FONT_STANDARD); FONT_LOCALE(FONT_STANDARD);
CFont::PrintString(SCREEN_WIDTH * 8 / 10, SCREEN_HEIGHT * 8 / 10, gUString); CFont::PrintString(SCREEN_WIDTH * 8 / 10, SCREEN_HEIGHT * 8 / 10, gUString);
for (int32 i = 0; i < SCREEN_HEIGHT; i += 4) { for (int32 i = 0; i < SCREEN_HEIGHT; i += 4) {
RwRenderStateSet(rwRENDERSTATESRCBLEND, (void*)rwBLENDONE); RwRenderStateSet(rwRENDERSTATESRCBLEND, (void*)rwBLENDONE);
@ -1337,7 +1337,7 @@ CMoneyMessage::Render()
CFont::SetJustifyOff(); CFont::SetJustifyOff();
CFont::SetColor(CRGBA(m_Colour.r, m_Colour.g, m_Colour.b, (255.0f - 255.0f * fLifeTime) * m_fOpacity)); CFont::SetColor(CRGBA(m_Colour.r, m_Colour.g, m_Colour.b, (255.0f - 255.0f * fLifeTime) * m_fOpacity));
CFont::SetBackGroundOnlyTextOff(); CFont::SetBackGroundOnlyTextOff();
CFont::SetFontStyle(FONT_STANDARD); FONT_LOCALE(FONT_STANDARD);
CFont::PrintString(vecOut.x, vecOut.y, m_aText); CFont::PrintString(vecOut.x, vecOut.y, m_aText);
} }
} }

View file

@ -1,6 +1,7 @@
#pragma once #pragma once
//done //file done
class CSpecialFX class CSpecialFX
{ {
public: public:
@ -9,15 +10,15 @@ public:
static bool bSnapShotActive; static bool bSnapShotActive;
static int32 SnapShotFrames; static int32 SnapShotFrames;
static void Render(void); //done static void Render(void);
static void Update(void); //done static void Update(void);
static void Init(void); //done static void Init(void);
static void Shutdown(void); //done static void Shutdown(void);
static void AddWeaponStreak(int type); //done static void AddWeaponStreak(int type);
static void Render2DFXs(); //done static void Render2DFXs();
}; };
//done
class CRegisteredMotionBlurStreak class CRegisteredMotionBlurStreak
{ {
public: public:
@ -29,22 +30,22 @@ public:
CVector m_pos2[3]; CVector m_pos2[3];
bool m_isValid[3]; bool m_isValid[3];
void Update(void); //done void Update(void);
void Render(void); //done void Render(void);
}; };
//done
class CMotionBlurStreaks class CMotionBlurStreaks
{ {
static CRegisteredMotionBlurStreak aStreaks[NUMMBLURSTREAKS]; static CRegisteredMotionBlurStreak aStreaks[NUMMBLURSTREAKS];
public: public:
static void Init(void); //done static void Init(void);
static void Update(void); //done static void Update(void);
static void RegisterStreak(uintptr id, uint8 r, uint8 g, uint8 b, CVector p1, CVector p2); //done static void RegisterStreak(uintptr id, uint8 r, uint8 g, uint8 b, CVector p1, CVector p2);
static void Render(void); //done static void Render(void);
}; };
//done
struct CBulletTrace struct CBulletTrace
{ {
CVector m_vecCurrentPos; CVector m_vecCurrentPos;
@ -55,20 +56,20 @@ struct CBulletTrace
float m_fThicknes; float m_fThicknes;
uint8 m_fVisibility; uint8 m_fVisibility;
void Update(void); //done void Update(void);
}; };
//done
class CBulletTraces class CBulletTraces
{ {
public: public:
static CBulletTrace aTraces[NUMBULLETTRACES]; static CBulletTrace aTraces[NUMBULLETTRACES];
static void Init(void); //done static void Init(void);
static void Render(void); //done static void Render(void);
static void Update(void); //done static void Update(void);
static void AddTrace(CVector* start, CVector* end, float thickness, uint32 lifeTime, uint8 visibility); //done static void AddTrace(CVector* start, CVector* end, float thickness, uint32 lifeTime, uint8 visibility);
static void AddTrace(CVector* start, CVector* end, int32 weaponType, class CEntity* shooter); //done static void AddTrace(CVector* start, CVector* end, int32 weaponType, class CEntity* shooter);
}; };
enum enum
@ -83,7 +84,7 @@ enum
MARKERTYPE_INVALID = 0x101 MARKERTYPE_INVALID = 0x101
}; };
//done
class C3dMarker class C3dMarker
{ {
public: public:
@ -104,21 +105,21 @@ public:
float m_fBrightness; float m_fBrightness;
float m_fCameraRange; float m_fCameraRange;
bool AddMarker(uint32 identifier, uint16 type, float fSize, uint8 r, uint8 g, uint8 b, uint8 a, uint16 pulsePeriod, float pulseFraction, int16 rotateRate); //done bool AddMarker(uint32 identifier, uint16 type, float fSize, uint8 r, uint8 g, uint8 b, uint8 a, uint16 pulsePeriod, float pulseFraction, int16 rotateRate);
void DeleteMarkerObject(); //done void DeleteMarkerObject();
void Render(); //done void Render();
}; };
//done
class C3dMarkers class C3dMarkers
{ {
public: public:
static void Init(); //done static void Init();
static void Shutdown(); //done static void Shutdown();
static C3dMarker *PlaceMarker(uint32 id, uint16 type, CVector &pos, float size, uint8 r, uint8 g, uint8 b, uint8 a, uint16 pulsePeriod, float pulseFraction, int16 rotateRate); //done static C3dMarker *PlaceMarker(uint32 id, uint16 type, CVector &pos, float size, uint8 r, uint8 g, uint8 b, uint8 a, uint16 pulsePeriod, float pulseFraction, int16 rotateRate);
static void PlaceMarkerSet(uint32 id, uint16 type, CVector &pos, float size, uint8 r, uint8 g, uint8 b, uint8 a, uint16 pulsePeriod, float pulseFraction, int16 rotateRate); //done static void PlaceMarkerSet(uint32 id, uint16 type, CVector &pos, float size, uint8 r, uint8 g, uint8 b, uint8 a, uint16 pulsePeriod, float pulseFraction, int16 rotateRate);
static void Render(); //done static void Render();
static void Update(); //done static void Update();
static C3dMarker m_aMarkerArray[NUM3DMARKERS]; static C3dMarker m_aMarkerArray[NUM3DMARKERS];
static int32 NumActiveMarkers; static int32 NumActiveMarkers;
@ -150,7 +151,7 @@ enum
BRIGHTLIGHT_REAR = BRIGHTLIGHT_REAR_LONG, BRIGHTLIGHT_REAR = BRIGHTLIGHT_REAR_LONG,
}; };
//done
class CBrightLight class CBrightLight
{ {
public: public:
@ -165,17 +166,17 @@ public:
uint8 m_blue; uint8 m_blue;
}; };
//done
class CBrightLights class CBrightLights
{ {
static int NumBrightLights; static int NumBrightLights;
static CBrightLight aBrightLights[NUMBRIGHTLIGHTS]; static CBrightLight aBrightLights[NUMBRIGHTLIGHTS];
public: public:
static void Init(void); //done static void Init(void);
static void RegisterOne(CVector pos, CVector up, CVector side, CVector front, static void RegisterOne(CVector pos, CVector up, CVector side, CVector front,
uint8 type, uint8 red = 0, uint8 green = 0, uint8 blue = 0); //done uint8 type, uint8 red = 0, uint8 green = 0, uint8 blue = 0);
static void Render(void); //done static void Render(void);
static void RenderOutGeometryBuffer(void); //done static void RenderOutGeometryBuffer(void);
}; };
@ -185,7 +186,7 @@ enum
SHINYTEXT_FLAT SHINYTEXT_FLAT
}; };
//done
class CShinyText class CShinyText
{ {
public: public:
@ -198,21 +199,21 @@ public:
uint8 m_blue; uint8 m_blue;
}; };
//done
class CShinyTexts class CShinyTexts
{ {
static int NumShinyTexts; static int NumShinyTexts;
static CShinyText aShinyTexts[NUMSHINYTEXTS]; static CShinyText aShinyTexts[NUMSHINYTEXTS];
public: public:
static void Init(void); //done static void Init(void);
static void RegisterOne(CVector p0, CVector p1, CVector p2, CVector p3, static void RegisterOne(CVector p0, CVector p1, CVector p2, CVector p3,
float u0, float v0, float u1, float v1, float u2, float v2, float u3, float v3, float u0, float v0, float u1, float v1, float u2, float v2, float u3, float v3,
uint8 type, uint8 red, uint8 green, uint8 blue, float maxDist); //done, not used uint8 type, uint8 red, uint8 green, uint8 blue, float maxDist); //not used
static void Render(void); //done static void Render(void);
static void RenderOutGeometryBuffer(void); //done static void RenderOutGeometryBuffer(void);
}; };
//done
class CMoneyMessage class CMoneyMessage
{ {
friend class CMoneyMessages; friend class CMoneyMessages;
@ -224,25 +225,25 @@ class CMoneyMessage
float m_fSize; float m_fSize;
float m_fOpacity; float m_fOpacity;
public: public:
void Render(); //done void Render();
}; };
//done
class CMoneyMessages class CMoneyMessages
{ {
static CMoneyMessage aMoneyMessages[NUMMONEYMESSAGES]; static CMoneyMessage aMoneyMessages[NUMMONEYMESSAGES];
public: public:
static void Init(); //done static void Init();
static void Render(); //done static void Render();
static void RegisterOne(CVector vecPos, const char *pText, uint8 bRed, uint8 bGreen, uint8 bBlue, float fSize, float fOpacity); //done static void RegisterOne(CVector vecPos, const char *pText, uint8 bRed, uint8 bGreen, uint8 bBlue, float fSize, float fOpacity);
}; };
//done
class CSpecialParticleStuff class CSpecialParticleStuff
{ {
static uint32 BoatFromStart; static uint32 BoatFromStart;
public: public:
static void CreateFoamAroundObject(CMatrix*, float, float, float, int32); //done, not used static void CreateFoamAroundObject(CMatrix*, float, float, float, int32); //not used
static void StartBoatFoamAnimation(); //done, not used static void StartBoatFoamAnimation(); //not used
static void UpdateBoatFoamAnimation(CMatrix*); //done, not used static void UpdateBoatFoamAnimation(CMatrix*); //not used
}; };