Skip to content

Releases: manups4e/ScaleformUI

Lua Bugfix

06 Jul 15:31
Compare
Choose a tag to compare

Hi everyone!
Some Lua bugs were addressed in this update of ScaleformUI:
(Lua is a very stupid language we all know that 😃)

  • fixed some indexing issues that prevented mouse from working correctly in pause menu
  • fixed some typos in UIMenu and added a check for values < 0 in menu building.
  • fixed labels for all items that requires them for all languages.
  • fixed UIMenu side panels fixed position if not enough space is available

Some scaleform generic fixes were also made, so please as usual

⚠️⚠️ UPDATE YOUR ASSETS TOO

PS: no C# update because it's perfect as it is ❤️


If you like my work please consider donating anything you want (a Tesla... a new 8K TV... a new girlfriend on NetChix...), you can donate with the following:

  • ko-fi
  • PayPal
  • Tebex
    Any help is greatly appreciated and motivates me to keep going. ❤️

Make FiveM Great Again (MFGA) - Part 2

05 May 15:15
174001e
Compare
Choose a tag to compare

📜 ScaleformUI - Make Fivem Great Again (MFGA) part 2

⚠️ DISCLAIMER: This is a major upgrade (breaking changes)!

Updating to this version may break existing code or throw errors if your scripts rely on old APIs or initialization patterns.
Please review the changelog carefully and adjust your code before deploying.
Test thoroughly in your development environment before updating your live servers!


A lot of things changed while the API remained almost the same outside!
More than 70% of original code is gone while maintaining efficiency and performances maxed out! (Thanks Mr Recycle!)

✨ Main Features & Changes

  • Tabs are now column-focused:
    • Each tab supports a Left, a Center (if compatible), and a Right (if compatible) column.
    • Example: TextTab uses Left column only while PlayerListTab supports all 3 columns and multiple of the same type.
  • Simplified column initialization using SetupLeftColumn(), SetupCenterColumn(), and SetupRightColumn() for PlayerListTab.
  • ⚠️ MissionPanel can only be set to the Right column — throws exception otherwise.
  • Lobby Menu (MainView) is now an extension of the base Pause Menu:
    • Less Scaleform code = better performance!
    • Works like PlayerListTab internally.
  • Removed the "new style" selection from PlayerListTab and MainView based on community feedback for a vanilla feeling.

🛠️ Rewritten & Improved

  • 70% codebase rewritten for reduction and performance boost.
  • Introduced column concept of columns in PauseMenu tabs for ordered execution and easier usage.
  • Scaleform rendering rewritten in MVC style for better compatibility and less code execution (faster times).
  • UIMenuItems now handle color directly in Scaleform (fixes selection color delay).
  • Renamed BasicTabItemPauseMenuItem in both Lua and C#.
  • UIMissionDetailsPanel: Added Clear() and Refresh() methods to control side panel updates.

🐛 Fixes

  • Lua: Fixed RemoveItem for UIMenu and PauseMenu (PlayerListTab / Lobby).
  • Fixed header positioning in PauseMenu for some resolutions (Lua & C#).

➕ Additions

  • UIMenuItem: Added KeepTextColorWhite override to lock text color.
  • MainView (Lua / C#): Added TabsColor parameter to customize lobby header color.

🔄 Lua Specific

  • Introduced inheritance between metatables, removing Base from child tables.

  • There are certainly more changes i forgot to mention as they are all internal / scaleform side, for the full changelog you can check here:
    Full Changelog: 5.7.1...5.8


📝 Example Code for PlayerListTab (C#)

SettingsListColumn settings = new SettingsListColumn("settings", 16);
PlayerListColumn players = new PlayerListColumn("players", 16);
MissionDetailsPanel missionPanel = new MissionDetailsPanel("missionPanel");

playersTab.SetupLeftColumn(settings);
playersTab.SetupCenterColumn(players);
playersTab.SetupRightColumn(missionPanel);

📝 Example Code for PlayerListTab (Lua)

local settings = SettingsListColumn.New("settings", 16)
local players = PlayerListColumn.New("players", 16)
local missionPanel = MissionDetailsPanel.New("missionPanel")

playersTab:SetupLeftColumn(settings)
playersTab:SetupCenterColumn(players)
playersTab:SetupRightColumn(missionPanel)

You can see more in the example.lua / MenuExample.cs files, in case you need support you can join mu discord server at https://discord.gg/KKN7kRT2vM where I and the community will provide you with support, snippets, and marriage counseling.


If you like my work please consider donating anything you want (a Tesla... a new 8K TV... a new girlfriend on NetChix...), you can donate with the following:

  • ko-fi
  • PayPal
  • Tebex
    Any help is greatly appreciated and motivates me to keep going. ❤️

Fixes and Tweakses (updated)

19 Mar 17:05
Compare
Choose a tag to compare

⚠️⚠️ Due to the changes in ScaleformUI_Assets an update of both assets and script is M A N D A T O R Y!!!!

Full Changelog: v5.7...5.7.1

  • ScaleformUI_Assets will include the minimap loader Scaleform and a Lua file to enable remote loading via events. This setup sends the handle through events, allowing everyone to use MinimapOverlays directly by referencing ScUI in the manifest — without relying on exports that require specifying a resource name, this makes MinimapOverlays more accessible across runtimes, especially for those using Lua (and in the future, JavaScript) by removing the need for awkward export calls (fixed res name and overhead).
  • The files folder in ScaleformUI_Lua / CSharp can be removed from next update and in manifest due to the above description.
  • UIMenu received another set of fixes
    • Fixed freeze / crash when removing the last visible item in menu, somehow Lua fucks up when handling the last item inside a callback event.. Lua sucks we all know it, i'm sorry on behalf of all the Lua devs for their shitty product 💩💩
    • Fixed subtitle shifting up / down under the banner.
    • Added RemoveItemsRange(int startIndex, int count) in both Lua and C#: this function allows developers to remove a range of items starting from an index and counting. Settings count to 0 equals to no removal, default 1. If you need to remove multiple items in a range, consider using this instead of a for loop 😄
    • You can now open an empty menu or switch to one!! The old Pagination system didn't allow this feature which i know many of you found weird to not be able to use. So enjoy my little scaleform fans!!
  • MinimapOverlays has been updated in Lua allowing devs to directly call the overlays methods in the overlay itself. For example you can now create an overlay and then do overlay:SetOverlayColor(color) the API will handle it for you ❤️
  • Fixed Mouse interaction in Area overlays (zones).
  • I hope i didn't forget anything else XD in case i'll double check during the release process :slight_smile:

If you encounter any more bugs, please let me know!!


If you like my work please consider donating anything you want (a Tesla... a new 8K TV... a new girlfriend on NetChix...), you can donate with the following:

  • ko-fi
  • PayPal
  • Tebex
    Any help is greatly appreciated and motivates me to keep going. ❤️

Fixes and Tweaks

16 Mar 16:08
Compare
Choose a tag to compare

A new feature has been added to ScUI in this update: MinimapOverlays will now support custom zones via vector lists!!!
image
You can add as many areas as you want, usage is very simple!
Lua:

local overlays = exports.ScaleformUI_Lua:GetMinimapOverlays()

local list = {
vector3(-100.78, -1129.4, 25.8),
vector3(36.1, -1120.28, 19.2),
vector3(91.26, -1004.77, 29.35),
vector3(-24.42, -963.52, 29.35),
}

local areaoverlay = overlays:AddAreaOverlay(list, false, SColor.FromArgb(180, 255, 0, 0))

C#

List<Vector3> list = new List<Vector3>()
{
    new Vector3(-100.78f, -1129.4f, 25.8f),
    new Vector3(36.1f, -1120.28f, 19.2f),
    new Vector3(91.26f, -1004.77f, 29.35f),
    new Vector3(-24.42f, -963.52f, 29.35f),
};

var areaoverlay = await MinimapOverlays.AddAreaOverlay(list, false, SColor.FromArgb(180, SColor.HUD_Red));

Here a list of changes:

  • Lua: Fixed an edge case crash when removing items with menu open
  • Lua: Fixed an edge case crash when setting current selection without items
  • Added back and fixed UIMenuStatsItem in UIMenu
  • Updated scaleform and updated building process for items to match R* style
  • Added support for AddAreaOverlay in MinimapOverlays

⚠️⚠️ AS USUAL, DOWNLOAD AND RUN (OR UPDATE) THE ASSETS ZIP INSTEAD OF ASKING WHY YOUR MENU IS NOT WORKING!!

If you like my work please consider donating anything you want (a Tesla... a new 8K TV... a new girlfriend on NetChix...), you can donate with the following:

  • ko-fi
  • PayPal
  • Tebex
    Any help is greatly appreciated and motivates me to keep going. ❤️

BugFixing

27 Feb 19:28
Compare
Choose a tag to compare

Thanks to the community i was able to quickly address A LOT of edge cases and to fix them all!!!

  • By your many requests, MinimapOverlays are now mouse reactive! Any time you create a new mouseOverlay, the metatable/object will include a new OnMouseEvent function for Lua and event for C# with one parameter, the event index :)
  • Fixed sorting / filtering / resetting menu items
  • Fixed adding and removing items with menu open
  • Fixed menu rebuild
  • (Lua) Fixed all non custom scaleforms not working anymore in the loop
  • Fixed White first item on menu visible
  • Fixed Refreshing Menu
  • Fixed wrong indexing sometimes when opening menu (especially in a switchTo with specified index)
  • Switching to a new menu now remembers the old index of that menu in case of previous opening.
  • Added controlled errors for empty menus.
  • Fixed lots of in-scaleform movie fixes :3

⚠️⚠️ UPDATING YOUR ASSETS IS AS ALWAYS MANDATORY! ⚠️⚠️

ScaleformUI - Update 3: Make FiveM Great Again - Part 1

23 Feb 10:47
2b35051
Compare
Choose a tag to compare

Great news Everyone!

UIMenu is finally updated!! 🥳🥳🥳

I started making scaleform movies for FiveM back in 2020, my first movie was ScaleformUI and in all these years i only added junk onto junk to make it work the way it worked.
I decided it was time to finally make a real UIMenu the way a GTA scaleform is made. And now the first part of Update 3 is completed.
UIMenu is now completely renewed both in the scaleform movie and in the API, but don't worry!! All the exposed API has not been edited to maintain your menu code compatibility with the new update, marking as obsolete all the removed features, the only thing changed is the removed FadingTime parameter in UIMenu.New / constructor and removed TextColor, HighlightedTextColor parameters as obsolete and legacy.

Changelog:

  • Completely rewrote the main Scaleform movie.
  • Fixed Glare position across resolutions (16:10 is completely bad on fivem for certain ui elements)
  • Code Breaking:
    • Removed fading time parameter in Lua/C# UIMenu constructors
    • Removed TextColor and HighlightedTextColor parameters in Items (unused and legacy)
  • Disabled all animations in menu.
  • Rewrote menu building system.
  • Rewrote menu and components updating process.
  • Modularized Scaleform movie to give the R* feeling we didn't know we were missing and didn't know we needed.
  • Fixed menu switching inheritance, it's now almost instant.
  • Performances increased up to by 40% across ScRTs.
  • UIMenuItem is now dynamic.
  • UIMenuListItem supports now virtually infinite list elements
  • I'm sure i forgot something.. 😛

All UIMenus are now updated.
Next update will bring a totally renewed and rewrote PauseMenu.

What's Changed

  • ScaleformUI - Update 3: Make FiveM Great Again - Part 1 by @manups4e in #249

Full Changelog: v5.5.1...v5.6.0

⚠️⚠️⚠️ SCALEFORMUI.gfx MOVIE CHANGED, UPDATING THE ASSETS IS MANDATORY ⚠️⚠️⚠️

February BugFix

10 Feb 14:14
Compare
Choose a tag to compare

Changes since last release:

What's Changed

  • fix police blips (lua/csharp) and blip legend (csharp) by @celeron9ultra in #246
  • Fixed Pause and Lobby rendering across all resolutions and all Aspect Ratios
  • Fixed UIMenu rendering across all resolutions, some aspect ratios don't work with full screen rendered scaleforms (ex: 16:10 on 1080p resolution), a fix will be researched.
  • Fixed Header title that somehow f***d up on its own
  • Fixed Header tab selection change in Lua
  • Fixed tab disposing in TabView when changing tab. (Fixes Minimap Panel persistance when changing tabs)
  • Fixed a weird Memory Leak crash caused by too many (long) descriptions. Same crash may occur with too many List Items with a lot of items, a solution is using DynamicListItems which make the menu virtually supporting infinite Lists.

A new updated Documentation has been added to ScaleformUI and it's in WIP (unfinished) you can check it out at https://manups4e.github.io/ScaleformUI/

New Contributors

Full Changelog: v5.5.0.1...v5.5.1

⚠️⚠️ AS USUAL UPDATE BOTH ASSETS AND SCRIPT TO AVOID ERRORS! ⚠️⚠️

Happy New (late) Year!

22 Jan 09:48
Compare
Choose a tag to compare

Happy new year everyone!!
A new release rich of features and bugfixes!! 🥳🥳🎉🎉👯‍♀️👯‍♂️🏟️

What's Changed

  • tweak(menu colors): typecheck using assert by @Mathu-lmn in #232
  • Improve MainView by @chaixshot in #239
  • Add drilling scaleform handler by @Mathu-lmn in #214
  • Improved Menu positioning now safezone reactive.
    • Added a new feature where it's now possible to decide if menu is aligned left or right side of the screen without the need of setting coordinates yourself!
  • Fixed Glare positioning that now follows the menu.
  • Fixed some bugs in the scaleform itself.
  • Added menu:IsMouseOverTheMenu() for LUA, and menu.IsMouseOverTheMenu for C#. It allows devs to know when the mouse is over any component of the menu or outside.
  • Added menu.ExtensionMethod(menu) in both lua and C# (in C# it's an event like other menu events menu.ExtensionMethod += myMethod).
    • The ExtensionMethod runs on tick along the menu and stops running when that menu is closed. Each menu has its own extension method.. all menus can have the same extension method by adding it to them.
  • To both Lua and C#
    • Updated exampleMenu
    • Fixed Glare and Unified Offset Management
    • UIMenu is now SafeZone dependant
    • Fixed MenuItems bugs
    • Fixed PickerColor SColor values
    • Fixed TimerBars
    • Updated MenuHandler
    • Updated TabView && MainView

Full Changelog: v5.4.0...v.5.5.0

⚠️⚠️⚠️ AS USUAL, DOWNLOAD AND / OR UPDATE THE ASSETS TO MAKE THE MENU WORK!!!! ⚠️⚠️⚠️

Huge thanks to everyone for keeping this project alive. We (I) love you all!

Bug fixing a new features!

26 Oct 07:40
Compare
Choose a tag to compare

New update, new features, less bugs!

In this version:

  • Lua: Added missing new badges
  • Lua: Fixed non string values in ListItem lists not being converted to strings
  • Lua & C#: Added new Custom Badge feature for MenuItems and MissionItems!
    • To use custom badges, simply call SetCustomRightBadge(string txd, string txn) or SetCustomLeftBadge(string txd, string txn) in C# and :CustomLeftBadge(txd,txn) or :CustomRightBadge(txd,txn) in Lua

image

  • C#: Fix for ped not being spawned for same item selection in Pause and Lobby
  • Lua: Fixed scoreboard (player list) empty icon not being converted to empty string in scaleform
  • Lua & C#: Fix for footer not being shown when changing tabs sometimes.
  • Scaleforms: created unique code for scaleforms instead of duplicates and enhanced performances, removed textured checkbox for a custom made one to avoid multiple calls in the internal API slowing down the performance for multiple checkboxes, and more bug fixes scaleform side.

Full Changelog: v5.3.6.2...v5.4.0

⚠️⚠️ As usual, please make sure to update both API and Assets resources!! ⚠️⚠️

Bug fixing for UIMenu Panels and more.

30 Aug 16:28
Compare
Choose a tag to compare

What's Changed

  • Enhanced Glare animation on UIMenu and fixed both sizes and offsets.
  • Fixed UIMenuPanels not working correctly in Lua and fixed also in C# (for percentage panel.. if you need to check the panel.Percentage value.. it has been changed in panel._percentage because of some weird collision in metatable, i suggest using panel:Percentage()
  • Added experimental fix for item descriptions sometimes not being correctly removed / showed.
  • Fix TimerBarPool RemoveBar function when remove more than one bar by @Swellington-Soares in #220
  • Add SetMenuOffset method by @Saturn745 in #221
  • fix typo in colour by @Mathu-lmn in #222

New Contributors

Full Changelog: v5.3.5...v5.3.6