Hello everyone,
I hope you’re doing well. Today we will grow a beard 🙂
It’s really nice resource which add a roleplay atmosphere to your server and bring revenue to the barber or shops which sell shavers.
config.lua
Here you can set an intervall how long does it take for the beard to reach next level. 1 = 1 min. i.g. 0.1 = 10 sek per Level,
client.lua
Here you can adjust shave function. You need this function to use shaver item. I don’t know why but it didn’t work for me with condition < 10 maybe it was some specific issue on my side,
Here is sql if you want to add a shaver item to your server for ESX 1.1. for other versions you can replace limit by weight.
INSERT INTO items
(name
, label
, limit
, rare
, can_remove
) VALUES
(‘shaver’, ‘Shaver’, 3, 0, 1);
We also need to make item usable. We must register item as usable in esx i.g. the esx_basicneeds\server\main.lua
ESX.RegisterUsableItem(‘shaver’, function(source)
local xPlayer = ESX.GetPlayerFromId(source)
xPlayer.removeInventoryItem(‘shaver’, 1)
TriggerClientEvent(‘SimpleBeardGrowth:shave’, source)
end)
SimpleBeardGrowth – Let your beard grow over time
https://forum.cfx.re/t/simplebeardgrowth-let-your-beard-grow-over-time/2126333
If you need FiveM Gameserver with one click installation check this:
https://zap-hosting.com/rpscripts
20% discount if you want: denmak-a-6883
If you need some general Fivem help, you can take a look at this Discord server:
https://discord.gg/Bdk3QHX
Description:
This script grows your beard over time, when you have a beard (So woman won’t get a beard).
The time interval can be set up in the Config.lua.
If you want to create a shaver itm or similar, you can simply trigger the following client event:
TriggerEvent(‘SimpleBeardGrowth:shave’)
Have fun with it!
Installation:
Download resource
put SimpleBeardGrowth in resources folder on the server
Add start SimpleBeardGrowth to your server.cfg
(re)start your server
Enjoy!
If you want to add shaver as an item follow steps in the video.