Skip to content

feat(core/rdr3): increase texture override pool size #3296

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 17, 2025

Conversation

Ktos93
Copy link
Contributor

@Ktos93 Ktos93 commented Mar 27, 2025

Goal of this PR

This PR increases the number of textures that can be created from the previous limit of 32 (reserved only for player faces) to 512. This change is a first step toward expanding the scope, allowing server owners to apply textures to other parts of the body, such as legs, torso, and more. Additionally, two new natives have been introduced: REMOVE_TEXTURE and DOES_TEXTURE_EXIST, which help manage textures.

How is this PR achieving the goal

  • Allocates a new array for 512 texture overrides and updates related pointers and offsets.
  • Hooks the texture allocation function with injected stubs to enforce the new limit.
  • Registers new natives (REMOVE_TEXTURE and DOES_TEXTURE_EXIST) for texture management.

This PR applies to the following area(s)

Redm

Successfully tested on

Game builds: 1491

Platforms: Windows

Checklist

  • Code compiles and has been tested successfully.
  • Code explains itself well and/or is documented.
  • My commit message explains what the changes do and what they are for.
  • No extra compilation warnings are added by these changes.

@github-actions github-actions bot added the invalid Requires changes before it's considered valid and can be (re)triaged label Mar 27, 2025
@Ktos93 Ktos93 force-pushed the redm-texture-override-patch branch 2 times, most recently from 97a0c93 to 895e70d Compare March 27, 2025 12:51
@prikolium-cfx
Copy link
Collaborator

Thank you for the contribution. I've pushed that to feature branch specific/feature/redm-texture-override-patch. It will be deployed in ~1 hour

@outsider31000
Copy link
Contributor

Thank you.

@Ktos93 Ktos93 force-pushed the redm-texture-override-patch branch 2 times, most recently from f7e27c8 to d80f272 Compare April 3, 2025 22:15
@prikolium-cfx prikolium-cfx added the RedM Issues/PRs related to RedM label Apr 4, 2025
@Ktos93 Ktos93 force-pushed the redm-texture-override-patch branch 3 times, most recently from bcaad5a to d1e9cb9 Compare April 4, 2025 19:03
@Ktos93 Ktos93 changed the title feat(core/rdr3): extend texture override pool feat(core/rdr3): increase texture override pool size Apr 4, 2025
@github-actions github-actions bot added triage Needs a preliminary assessment to determine the urgency and required action invalid Requires changes before it's considered valid and can be (re)triaged and removed invalid Requires changes before it's considered valid and can be (re)triaged triage Needs a preliminary assessment to determine the urgency and required action labels Apr 4, 2025
@Ktos93 Ktos93 force-pushed the redm-texture-override-patch branch from 38b8948 to 6d533ef Compare April 8, 2025 11:08
@github-actions github-actions bot added triage Needs a preliminary assessment to determine the urgency and required action and removed invalid Requires changes before it's considered valid and can be (re)triaged labels Apr 8, 2025
@outsider31000
Copy link
Contributor

this pull request is ready to be reviewed/merged, all tests were done.

@prikolium-cfx prikolium-cfx added the ready-to-merge This PR is enqueued for merging label Apr 17, 2025
@prikolium-cfx prikolium-cfx merged commit 68148de into citizenfx:master Apr 17, 2025
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready-to-merge This PR is enqueued for merging RedM Issues/PRs related to RedM triage Needs a preliminary assessment to determine the urgency and required action
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants