Author Topic: some of our jobs dissappeared from F4  (Read 4864 times)

0 Members and 2 Guests are viewing this topic.

Offline petturoidakko

  • Newbie
  • *
  • Posts: 7
  • Karma: -1
some of our jobs dissappeared from F4
« on: March 27, 2015, 04:48:45 PM »
So suddendly some of our custom jobs stopped showing on F4menu, but you can still use command example /swat  in chat to become one of those jobs.

Quote
})

TEAM_SWAT = DarkRP.createJob("SWAT", {
   color = Color(25, 25, 170, 255),
   model = "models/gign remasteredhd.mdl",
   description = [[More experienced than the average CP.
You guys are called in to prevent raids.]],
   weapons = {"m9k_m16a4_acog", "weapon_shield", "m9k_m61_frag", "m9k_knife", "arrest_stick", "unarrest_stick", "stunstick", "door_ram", "weaponchecker","weapon_taser"},
   command = "swat",
   max = 5,
   salary = 85,
   admin = 0,
   vote = false,
   hasLicense = true,
   hasRadio = true,
   canTalkToGlobal = true,
   
   candemote = false,
        customCheck = function(ply) return ply:IsUserGroup("donator") or ply:IsUserGroup("donor mod") or ply:IsUserGroup("donor admin") or ply:IsUserGroup("superadmin") end,
        CustomCheckFailMsg = "You need to be a donator to become a SWAT."
})

that is the code we use for ex: swat.
cant find anything wrong with it.

Our ulx groups are like that

donator
donor mod
superadmin
admin
no uppercase letters

Offline Caustic Soda-Senpai

  • Sr. Member
  • ****
  • Posts: 469
  • Karma: 54
  • <Insert something clever here>
    • Steam Page
Re: some of our jobs dissappeared from F4
« Reply #1 on: March 27, 2015, 05:04:08 PM »
First, for simplicity, you can use ply:IsSuperAdmin instead of ply:IsUserGroup("superadmin") just for the laziness all coders have and are there any errors printed to console when you load the server? Are you using stock F4? Are any other jobs with these same ranks having these problems or is it just SWAT?
Once you get to know me, you'll find you'll have never met me at all.

Offline petturoidakko

  • Newbie
  • *
  • Posts: 7
  • Karma: -1
Re: some of our jobs dissappeared from F4
« Reply #2 on: March 28, 2015, 03:55:48 AM »
First, for simplicity, you can use ply:IsSuperAdmin instead of ply:IsUserGroup("superadmin") just for the laziness all coders have and are there any errors printed to console when you load the server? Are you using stock F4? Are any other jobs with these same ranks having these problems or is it just SWAT?

Well not with these groups, but example superadmin job is working completly fine.

but you cant use   ply:IsSuperAdmin  like ply:IsDonator  right?

Offline Caustic Soda-Senpai

  • Sr. Member
  • ****
  • Posts: 469
  • Karma: 54
  • <Insert something clever here>
    • Steam Page
Re: some of our jobs dissappeared from F4
« Reply #3 on: March 28, 2015, 04:18:33 AM »
My money is on the spaces in your ULX Groups. From my knowledge, ULX doesn't like spaces.

Also, you can use ply:IsAdmin (which allows anyone who inherits admin to use it.) or ply:IsSuperAdmin (which allows anyone who inherits superadmin to use it.)
Once you get to know me, you'll find you'll have never met me at all.

Offline petturoidakko

  • Newbie
  • *
  • Posts: 7
  • Karma: -1
Re: some of our jobs dissappeared from F4
« Reply #4 on: March 28, 2015, 06:03:54 AM »
My money is on the spaces in your ULX Groups. From my knowledge, ULX doesn't like spaces.

Also, you can use ply:IsAdmin (which allows anyone who inherits admin to use it.) or ply:IsSuperAdmin (which allows anyone who inherits superadmin to use it.)

But I dont understand why it does not work as it worked fine, but suddendly stopped working.

Offline Livaco

  • Full Member
  • ***
  • Posts: 133
  • Karma: -37
    • Livaco
Re: some of our jobs dissappeared from F4
« Reply #5 on: March 28, 2015, 07:00:41 AM »
It Might Be The Custum Cheak
Here To Help And Be Happy And Help :)

My Website
My Addons
PermaBanV1.0

Quote from:  Livaco on April 12 at 9:10:20 PM
I May Be Dum But Am Still Better Then The Rest

Livaco Products©

Offline XxLMM13xX

  • Sr. Member
  • ****
  • Posts: 265
  • Karma: -51
  • New to lua development
    • Twitch
Re: some of our jobs dissappeared from F4
« Reply #6 on: March 28, 2015, 07:11:29 AM »
Where are you putting the code??? If it's in the darkrp files then that's the problem you need to have darkrp modification!

Offline petturoidakko

  • Newbie
  • *
  • Posts: 7
  • Karma: -1
Re: some of our jobs dissappeared from F4
« Reply #7 on: March 28, 2015, 07:56:50 AM »
Where are you putting the code??? If it's in the darkrp files then that's the problem you need to have darkrp modification!

we got darkrp modification, and I just realized the jobs work, like you can type the chat command to become one, they just wont show up in F4 menu.

Offline Aaron113

  • Hero Member
  • *****
  • Posts: 803
  • Karma: 102
Re: some of our jobs dissappeared from F4
« Reply #8 on: March 28, 2015, 08:24:56 AM »
I know next to nothing about DarkRP, so I can't give you any help there.  I would, however, not recommend using IsSuperAdmin() just to keep everything the same.  It will function the same either way, but using two different functions just doesn't look as nice.

Offline XxLMM13xX

  • Sr. Member
  • ****
  • Posts: 265
  • Karma: -51
  • New to lua development
    • Twitch
Re: some of our jobs dissappeared from F4
« Reply #9 on: March 28, 2015, 09:40:42 PM »
Try using this: http://thecodingbeast.com/tools?id=customcheck

This will give you the code for the check that may be the issue this will help ALOT scroll down to the bottom of the page and fill it out!

Offline JamminR

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 8096
  • Karma: 390
  • Sertafide Ulysses Jenius
    • Team Ulysses [ULib/ULX, other fine releases]
Re: some of our jobs dissappeared from F4
« Reply #10 on: March 28, 2015, 10:11:11 PM »
I'm moving this to Developers corner, as I feel right now it's not so much how to use ULib or ULX.
"Though a program be but three lines long, someday it will have to be maintained." -- The Tao of Programming

Offline Caustic Soda-Senpai

  • Sr. Member
  • ****
  • Posts: 469
  • Karma: 54
  • <Insert something clever here>
    • Steam Page
Re: some of our jobs dissappeared from F4
« Reply #11 on: March 29, 2015, 02:02:50 AM »
MY advice: try removing the spaces from your groups. Humour me.
Once you get to know me, you'll find you'll have never met me at all.

Offline Livaco

  • Full Member
  • ***
  • Posts: 133
  • Karma: -37
    • Livaco
Re: some of our jobs dissappeared from F4
« Reply #12 on: April 01, 2015, 07:55:03 AM »
Try using this: http://thecodingbeast.com/tools?id=customcheck

This will give you the code for the check that may be the issue this will help ALOT scroll down to the bottom of the page and fill it out!
I Use That
Here To Help And Be Happy And Help :)

My Website
My Addons
PermaBanV1.0

Quote from:  Livaco on April 12 at 9:10:20 PM
I May Be Dum But Am Still Better Then The Rest

Livaco Products©

Offline Caustic Soda-Senpai

  • Sr. Member
  • ****
  • Posts: 469
  • Karma: 54
  • <Insert something clever here>
    • Steam Page
Re: some of our jobs dissappeared from F4
« Reply #13 on: April 01, 2015, 09:00:29 AM »
If you guys actually READ the code, you'd see he's using the check...
Once you get to know me, you'll find you'll have never met me at all.

Offline Livaco

  • Full Member
  • ***
  • Posts: 133
  • Karma: -37
    • Livaco
Re: some of our jobs dissappeared from F4
« Reply #14 on: April 01, 2015, 09:39:29 AM »
If you guys actually READ the code, you'd see he's using the check...
I Know
Here To Help And Be Happy And Help :)

My Website
My Addons
PermaBanV1.0

Quote from:  Livaco on April 12 at 9:10:20 PM
I May Be Dum But Am Still Better Then The Rest

Livaco Products©