[RedM] [VORP] Advanced Character Height System | Database Saving & Sync

:glowing_star: Introduction

Bring diversity to your Red Dead Redemption 2 roleplay server! af-pedscale is a robust and optimized script designed for VORP Core that allows administrators to permanently change the height of player characters. Unlike simple commands that reset on relog, this system saves the character’s height to the database and ensures it is perfectly synchronized for all players.

Add depth to your roleplay:Create dwarves, giants, or simply varied character heights to make your population feel real!

:movie_camera: Preview

Click Here to Watch the Video

:shopping_cart: Purchase

Get it on Tebex


:fire: Key Features

  • :floppy_disk: Database Persistence: Changes are saved to the database (oxmysql). When a player disconnects or the server restarts, their height remains the same.
  • :counterclockwise_arrows_button: Instant Synchronization: When a height is set, it syncs instantly to all connected clients.
  • :gear: VORP Core Integration: Fully integrated with VORP’s character system. The height loads automatically when the character is selected.
  • :person_running: Dynamic Speed (Optional): Includes a unique feature where character size can affect movement speed (e.g., larger characters move slower/faster), configurable in config.lua.
  • :shield: Admin Controls: Easy-to-use commands for admins to set or reset heights.
  • :globe_showing_europe_africa: Localization: Fully translatable (includes locales/).
  • :test_tube: Test Mode: Includes a test mode for players to try out heights locally (can be disabled).

:laptop: Commands

Admin Commands

  • /setheight [index] [playerId] - Applies a scale from the config to a specific player and saves it.
    • Example: /setheight 1 5 (Sets height index 1 to player ID 5)
  • /removeheight [playerId] - Resets the player to default size and removes data from DB.

Test Commands (If Config.TestMode is active)

  • /testheight [index] - Applies height locally for testing purposes.
  • /testremoveheight - Resets local testing height.

:gear: Configuration

You can easily configure height presets, speed multipliers, and translations.

Config.Heights = {
0.7, – 1: Very Short
0.8, – 2: Short
0.9, – 3: Slightly Short
1.0, – 4: Normal
1.1, – 5: Tall
1.2, – 6: Very Tall
1.4 – 7: Giant
}

Config.ScaleSpeed = {
enabled = false, – Should scale affect movement speed?
inverse = true, – true: big = slow, false: big = fast
}

:clipboard: Resource Information

Code is accessible No
Subscription-based No
Lines (approximately) ~350
Requirements VORP Core, oxmysql
Support Yes
3 Likes

[1.0.1] - CHANGE LOG

:hammer_and_wrench: Fixed

  • Height Reset Issues: Resolved a bug where player height would reset to default after death, revive, or respawn events.
    • Integrated Listeners: vorp_core:Client:OnPlayerRevive, vorp_core:Client:OnPlayerRespawn, and vorp_core:Client:OnPlayerSpawned to ensure full persistence.
  • Character Reload Support: Enhanced vorp:SelectedCharacter handling to correctly re-apply saved height data when characters are reloaded (e.g., via /rc).
  • Network Streaming Logic: Fixed a critical synchronization bug where unstreamed players (returning ID -1) could inadvertently overwrite the local player’s scale. The system now validates player handles before any scale modification.
  • Initialization Delay: Implemented a 2000ms safety buffer during the application process to ensure character models and clothing assets are fully streamed before adjusting the ped size.

:sparkles: Added

  • Manual Reload Command: Introduced a new failsafe command (/rcheight by default) allowing players to manually pull their saved height from the database.
    • Toggleable via Config.ReloadHeightCommand.
    • Fully customizable command name in the config.
    • Includes error notifications if no saved data is found, preventing accidental overrides.

:gear: Changed

  • Default Configuration: Config.TestMode is now set to false by default for production environments.
  • Performance Optimization: Refined the synchronization loop to minimize resource usage while checking for valid networked entities.

AF-Pedscale Changelog [1.0.2]

Fixed

  • Carry-Sync Lock: Resolved a critical bug where players’ heights would visually “freeze” for other clients after being carried or interacting with physics objects.

  • Dual-Fix Implementation: Combines Model Swapping and Dimension Hopping to fully purge network entity locks.

  • Hardcoded Notifications: Fixed remaining hardcoded strings in client.lua and server.lua, ensuring all system messages respect the configured locale.

  • Entity Synchronization: Fixed a race condition where the scale would occasionally fail to apply on the server-side entity handle during rapid dimension switches.

Added

  • Deep Fix System (Dimension Hop): A robust server-side mechanism that switches routing buckets (0 → Temp → 0) to force a complete network refresh for all peers.

  • Combo-Refresh Pipeline: Integrated the /rc (ReloadCharacter) command into the stabilization flow to clear carry bugs without unwanted health or stat resets.

Changed

  • Unified Event Handling: Consolidated redundant listeners (Revive, Respawn, Spawned, SelectedCharacter) into a single centralized synchronization channel.

Hey, thanks for the feedback! No issue with the AI part, didn’t try to hide that. Appreciate you flagging the hogtied/lassoed/grappled/grabbed sizing bug, what version were you testing on, and got repro steps? Want to take a proper look at it.

Would genuinely like to see your version if you’re open to sharing, always happy to compare notes and improve things further.

Feel Free to shoot me a dm and i can show you stuff

1 Like