Skip to content

Render the map as the game's real 3D scene, rebuilt from RAM - #77

Draft
hugou74130 wants to merge 1 commit into
Developmentfrom
feature/map-3d-moteur
Draft

hugou74130 wants to merge 1 commit into
Developmentfrom
feature/map-3d-moteur

Conversation

@hugou74130

Copy link
Copy Markdown
Collaborator

This pull request introduces several enhancements and fixes across the savestate decompression logic, OpenGL shader programs, and 3D map rendering in the STROOP project. Key highlights include the addition of LZ4 decompression support for savestates, improved shader programs for level models and skyboxes, more robust gridline and object rendering in the map tab, and new utility classes for RAM access and pointer handling.

Core functionality and decompression:

  • Added a new SavestateDecompression utility that supports both GZip and LZ4 decompression for savestate files, replacing the previous GZip-only logic in StFileIO. This makes savestate loading more robust and compatible with additional formats. [1] [2]

Graphics and rendering improvements:

  • Introduced new and improved GLSL shaders for level models (LevelModel.vert.glsl, LevelModel.frag.glsl), skyboxes (Skybox.vert.glsl, Skybox.frag.glsl), and enhanced the Lines.geom.glsl shader with better clipping and color/width interpolation. [1] [2] [3] [4] [5] [6]
  • Updated map rendering logic to allow 3D collision geometry to be drawn when either the 3D level geometry is displayed or the level model is hidden, improving visualization flexibility. [1] [2]

Map tab and object interaction fixes:

  • Improved gridline rendering by fixing vertical increment logic, ensuring proper 3D grid visualization.
  • Enhanced MapDrawingObject to correctly handle vertex heights depending on the current view mode, making drawing more intuitive in both top-down and 3D views. [1] [2] [3] [4] [5]
  • Refined object icon rendering to only show hovered game objects when object models are displayed, aligning with ghost rendering logic. [1] [2]

Memory access and utility additions:

  • Added a CopyCachedRam method to ProcessStream for efficient RAM copying, and introduced a new Rdram class for segment-aware RAM access and pointer handling, facilitating advanced memory operations. [1] [2]

GhostTab enhancements:

  • Added properties and logic to GhostTab for checking the installation of colored hats and ghost hacks, and for determining when ghosts are drawn in-game.

These changes collectively improve savestate compatibility, visual fidelity, and the flexibility and reliability of map and object interactions.


Core functionality and decompression

  • Added SavestateDecompression utility class to support both GZip and LZ4 decompression for savestates, and refactored StFileIO to use it for loading memory. [1] [2]

Graphics and rendering improvements

  • Introduced new and improved GLSL shaders for level models, skyboxes, and lines, enhancing rendering quality and adding features like color/width interpolation and proper clipping. [1] [2] [3] [4] [5] [6]
  • Updated map rendering logic to allow 3D collision geometry drawing based on display state, increasing visualization flexibility. [1] [2]

Map tab and object interaction fixes

  • Fixed vertical increment logic in gridline rendering for correct 3D grid display.
  • Improved MapDrawingObject to handle vertex heights appropriately in different view modes, making drawing more intuitive. [1] [2] [3] [4] [5]
  • Refined icon and ghost rendering to only show hovered objects when models are displayed, for consistency. [1] [2]

Memory access and utility additions

  • Added CopyCachedRam method to ProcessStream and a new Rdram class for advanced RAM and pointer handling. [1] [2]

GhostTab enhancements

  • Added properties and checks for colored hats and ghost hack installations, and improved logic for in-game ghost drawing.

Copilot AI balanced review requested due to automatic review settings October 8, 2026 16:09

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants