[Release][EM][ST][SQL] BETA FX-Customs SQL only

Name: FX-Customs

Version: 1.2 Beta

Essential Mode Version Download: https://mega.nz/#!wsdjzYjC!uSyOjQuKIxnuSIJB7INftOcrCdQdCcdQnDxBQ1bLFyw

Requirements For EM Version:

Pnotify is now optional as of 1.1 BETA

You must edit line 41 in server.lua from

 local notification = { type = "pnotify"  } 

to

 local notification = { type = "normal"  } 

Name: FX-Customs

Version: 1.0 Beta

SuperTable Version Download:
https://mega.nz/#!c5lGxJDS!EQbfWOiLROzgR59APLUihyZ8CUMM1WgBig2HwYpmKMY

Requirements For SuperTable Version:

Instructions:

  • Download from the link above and add the resources according to their install instructions.
  • Download the resource from the download link.
  • Add the resource to your resources folder.
  • Add them to your server.cfg and if you get confused you can look at the example server.cfg that’s included.

If you want to ask about me supporting another script etc please wait until I iron out other bugs and stuff and get this out of beta before I think about that. Also if you would like to make this script support that mod please read the section about licensing.

About:
This is a remake of the popular script LS-Customs by Artur. Hopefully, it does a good job of building upon his work. The goal of this script was initially to do a remake with 1:1 parity of LS-Customs with integrated payments. I think I’ve managed to do that as bug-free as possible within my realm of knowledge.

Features:

  • Payment system subtracted from SQL database.
  • Integration with EM by @Kanersps
  • 10 Garage Locations
  • Locked Garages
  • Ability to enable or disable vehicle extras/custom mods per vehicle.
  • Vehicles that are owned are stored in an SQL DB.
  • Stolen vehicles can only be repaired at the shop and are not added to the DB only owned vehicles.

Notes:
This was tested on a windows 10 pc by myself without any other players using a MariaDB. If you encounter errors on another setup I will most likely be unable to reproduce them unless your setup is similar to mine.

CURRENT KNOWN BUGS

  • Double buying rapidly can cause errors.
  • Spam buying will cause console errors.
  • The garage isn’t locked currently so possibly multiple people can enter the customs at the same time. Should be fixed next update.

License:
This is under the no license/license. Everything except the Ft_menuBuilder is under that license. If you would like to edit this to work with something else I.E. VRP or something like that or if you would like to make this work with different scripts specifically contact me first. This is my first attempt at programming as I just started learning to program a month or so ago and have a private bitbucket setup for this script. If you see that I’ve hacked something together or done something completely backward it’s probably because I didn’t know any better so please let me know. I’m using this for learning and to give back to the community. So if your goal is to hide your product from the community I probably won’t allow it. Also, all future versions of this script will be released inside this topic unless I leave the community then I’ll allow someone to take over another topic to prevent confusion.

Thanks:
I would like to thank the elements for giving us this amazing tool to work with. I would like to @SupaCURE for providing me with the supertables script and I would like to thank @Kanersps for his scripts he provides free to the community. and those of you who inspired me to start working on this.

Pics:

2017-08-07-08_55_43-Grand-Theft-Auto-V

6 Likes

I literally just started making my own one 15 minutes ago o.O

Awesome! Have you tried mine out and does it work well for you?

No, i just downloaded it there and i am still going to make my own one, i’ll use yours as a reference if easier to read than the original xD and yes i will credit you if i directly copy anything.

i would love to also get an vRP Version of it since its SQL :slight_smile:

Update the post.
Version 1.0 Still but now includes the SuperTable version. @SupaCURE is the creator of that script. If anyone has any issues or is able to get these running please let me know and give feedback. If there are features that would be nice or bugs you encounter with the script let me know also.

I may look to support vRP in the future. However I think LS-Customs already had a port to vRP.

the vrp port doesnt work properly with fx server and to get it to work you need to use vrp showrooms and tbh i find the regular garages much better.

Alright so once vRP is completely stable on FX I may look into it. Until then I’ll just continue with the direction i’ve been heading.

Thanks for the update tweeter.

Thanks for use my Ft_menuBuilder <3
Do not forget to put the link to ft_menuBuilder.
I saw that you made changes. Why not have ft_ui?

I merged ft ui into ft menu builder and made a few specific edits to make it work with my script that’s why I had to include it into my script. If you look in the folder that has ft menu builder I have links to all your original resources I just did not want users to download that thinking it would work with my script.

However I can add a link to your topic in my thanks section :slight_smile:

Changes are not necessary, sof for AddButtonTable and RemoveButton (What I will add in the official deposit soon). The problem of having to modify the ft_menu is that if another resource uses it it will not work correctly.

I looked at the code is there is no real reason for adding IsModOwned because you already use subText = “” everywhere.

@JinkLeft https://github.com/FivemTools/ft_menuBuilder/releases/tag/0.13.0

Yes, I removed what I was working on there but eventually, I was going to be adding a text2 function that I was testing but removed to get the beta out. where there is logic in there to check if the player owns the mod and draw that mod as owned instead of the price.

I originally had moved menu builder and ui into my own resource but as I didn’t want to license my resource under the GNU license I removed it. I also will have to edit the dimensions of the menus to make some text fit. As some of the mods names are too long and overlap or for example I think having like 100 menu items or so makes the total count for the text go to the next line. So being able to edit that is great on the fly and distribute that :smiley:

Also, I was looking into ways to add a cooldown in the menu between the execution of the events so they can’t spam etc.

If you’d like I can fork your repo and make my edits there?

You can use Pulls Requests for fix or add features :wink:

This will always be better than have 50 versions of the menu and breaking other resources because of this.

A yes I just understood XD

    -- No closable menu for back button
    if settings.closable ~= nil and settings.closable == false then
      return
    end

I look at whether it is really necessary or not

Just wanted to update everyone. If you have had success running this please let me know or have any issues please also let me know which version and what issue you were having.

I’ll be going to sleep soon here but I’m working with samas to work things I need into menuBuilder so I no longer will include it with my resource and can link to his resource. I have some plans to work on some bugs tomorrow and if i can get them worked out I’ll work on my next feature.

I’m debating on trying to add Liveries to the menus next if that’s requested enough.
I’m also debating on something to do with user permissions for groups on the EM version.
So i can do things like police customs where the prices are free for certain mods and add customs shops that only show for them. If there is enough interest in this mod I’ll try to work for that.

Hey :slight_smile:

I just tried, looks like working good for me !

I just noticed you should preview before buying.
I have made a similar script but your menu ordering is really good !

1 Like

Yeah that’s something I’ve thought about doing. If that’s really important to players I can make that the priority after my bugfix update!

Thanks m8. I know there might be some smaller bugs so if you see some things hopefully my bugfixes tomorrow should fix them.

Everytime someone changes a mod or paint on their vehicle it will also change for everyone else who is on the server and in a vehicle.

Ok, I’ve been out of town for a few days and I’m going to start working on the update for previewing paints. I think I may have an idea why this is happening I’ll have to check into it though. Since testing this by myself is there a way you could let me know if it’s also updating the colors for the vehicles in the DB? Of the other players

also is it only for paint and mods?