How do I create a role?

How to make your own role.
  1. Go to your roles folder: wos-renegadesquad-xxx/lua/wos/prs/role-sys/roles
  2. Create a new Lua file in that folder. Example: `mycoolrole.lua`
  3. Paste the given template below and fill in the fields with your own content.
wOS.RenegadeSquad.Roles:RegisterRole({
    Name = "Template",
    Description = "A general template to create more roles!", -- Role description displayed in the upgrade list.
    Loadout = { "swep_example", "swep_example_1" }, -- Weapons the role will spawn with.
    Model = "player/example/example.mdl", -- Model assigned to players using role.
    BodyGroups = { -- Bodygroup set assigned to players on spawn.
        [5] = 1,
    },
    PlayerCost = 50,
    PlayerLocked = false,
    SquadCost = 50,
    SquadLocked = false,
    UserGroups = { "exampleusergroup" }, -- Restrict role to an allegiance (Set to false to be available for all).
    Allegiances = { -- Allegiance that this role is restricted to (Set to false to be available for all).
        [ "Example Allegiance" ] = true, 
    },

    CertifRequirements = { -- Certifications required to purchase and switch to this role.
        [ "Example Certification"] = true,
    },

    OnSpawn = function( ply )
    
    end,
})
  • RSS, Roles
  • 0 Els usuaris han Trobat Això Útil
Ha estat útil la resposta?

Articles Relacionats

How do I create an allegiance?

How to make your own allegiance. 1) Navigate to the following directory:...

How do I make my own unlock?

How to make your own appearance unlock. Navigate to...

Installation and Configuration

Installing the ContentBefore you begin installing the addon you need to install the required...

How do I assign other people and myself certifications?

How to assign other people certifications: Hold c, and right-click a player. Click view...

How To Disable The WiltOS Chat Advertisement

How to disable the wOS chat advert Navigate to lua/wos/prs/config/general/sv_config.lua Find...