In game timer

Hi all, I see this in some server : http://www.noelshack.com/2014-22-1401648260-sans-titre.png

It show the time you play on a server, and it can be very good for job.

For exemple : if i stand 3H on the server i can be a gundealer.

Thank you all.

Yes, it’s a very nice timer.

It’s called UTime. You can find it here: https://github.com/Nayruden/Ulysses

Apparently some people aren’t willing to help.

I think what he means is, if you’ve been on the server for 3 hours you can become a gun dealer.

You’d need a CustomCheck for the job:


function(ply) return ply:GetUTime() > 10800 end

Thank you all

I try your function me and it dont work , the consol say me :
[ERROR] addons/darkrpmodification-master/lua/darkrp_customthings/jobs.lua:121: function arguments expected near ‘>’

  1. unknown - addons/darkrpmodification-master/lua/darkrp_customthings/jobs.lua:0

function(ply) return ply:GetUTime() > 10800 end

I assume. He forgot parentheses

Thanks, I didn’t check my code before posting it.

Now i have a trouble with CustoCheck… i place the code and the consol say to me

[ERROR] addons/darkrpmodification-master/lua/darkrp_customthings/jobs.lua:122: ‘}’ expected (to close ‘{’ at line 108) near ‘CustomCheckFailMsg’

  1. unknown - addons/darkrpmodification-master/lua/darkrp_customthings/jobs.lua:0

i try to fix it but i dont…

this is my code (it is in french) :


TEAM_REB = DarkRP.createJob("Rebelle médecin", {
color = Color(75, 75, 75, 255),
model = {"models/player/group03m/male_05.mdl",
"models/player/group03m/female_02.mdl"},
description = [[Vous formez la Rebellion de Cité17, organisez vous, et menez des assaults contre 
la MPF (sans oubliez les règles bien sur) et n'oubliez vous devez Aider les citoyens.]],
weapons = {"weapon_medkit"},
command = "gangster_medecin",
max = 1,
salary = 0,
admin = 0,
vote = false,
hasLicense = false,
customCheck = function(ply) return ply:GetUTime() > 10800 end
CustomCheckFailMsg = "Il faut 3 heures de jeu !",
PlayerDeath = function(ply)
ply:changeTeam( TEAM_CITIZEN, true)
end
})

This should work.


TEAM_REB = DarkRP.createJob("Rebelle médecin", {
	color = Color(75, 75, 75, 255),
	model = {"models/player/group03m/male_05.mdl",
	"models/player/group03m/female_02.mdl"},
	description = [[Vous formez la Rebellion de Cité17, organisez vous, et menez des assaults contre 
	la MPF (sans oubliez les règles bien sur) et n'oubliez vous devez Aider les citoyens.]],
	weapons = {"weapon_medkit"},
	command = "gangster_medecin",
	max = 1,
	salary = 0,
	admin = 0,
	vote = false,
	hasLicense = false,
	customCheck = function(ply) return ply:GetUTime() > 10800 end,
	CustomCheckFailMsg = "Il faut 3 heures de jeu !",
	PlayerDeath = function(ply) ply:changeTeam(TEAM_CITIZEN, true) end,
})