Giter VIP home page Giter VIP logo

5l1v3r1 / nui_doorlock Goto Github PK

View Code? Open in Web Editor NEW

This project forked from aypixt/nui_doorlock

0.0 1.0 0.0 138 KB

A conversion of nui_doorlock for QBCore. Thank you Linden for this amazing resource, unfortunately Linden has taken it off of their github so this repo now looks like it's a fork of another one but it was originally a fork of the original which was Linden's repo all credits are going to Berkie who converted the script to qb-core

License: GNU General Public License v3.0

JavaScript 2.27% Lua 91.76% CSS 1.55% HTML 4.42%

nui_doorlock's Introduction

nui_doorlock

A conversion of nui_doorlock for QBCore. Thank you Linden for this amazing resource, unfortunately Linden has taken it off of their github so this repo now looks like it's a fork of another one but it was originally a fork of the original which was Linden repo all credits are going to Beriek who converted the script to qb-core ty to Bashenga who helped me to fix the ui stuff



  • Easily add and configure new doors! Example video
    Use the /newdoor command to automatically create a new entry on the DoorList.

  • No more SetEntityHeading and FreezeEntityPosition natives.
    Doors in range are assigned a doorHash, used with AddDoorToSystem.
    Doors are assigned a state depending on if they are unlocked, locked, or locking with DoorSystemSetDoorState.

  • Garage doors and gates can be locked and will properly move into the correct position.
    If a player comes into range of an unlocked automatic door like this, it will open appropriately.

  • The state of the door is drawn into the world using NUI, meaning full customisation of the appearance and content.
    By default, icons from font-awesome are being displayed; but there is support for images with this method.
    Customisable audio playback! Modify the lock and unlock sound on a door-by-door basic.

  • Improved performance by utilising threads and functions where appropriate.
    Instead of updating the door list every X seconds, your position will be compared to where the last update occured and update when appropriate.
    The state of doors is only checked while in range, and the number of checks per loop depends on the state of the door.

  • Persistent door states! Door states are saved when the resource stops, then loaded back up on start.
    States.json will auto-generate if the file does not exist.

  • Config for both Community MRPD and gabz_MRPD
    Just choose which config file to use and delete the one you are not using.

  • Set door access permissions
    Set multiple jobs to be authorised to use a door, with the minimum required grade authorizedJobs = {['police']=0, ['offpolice']=0}
    Allow the door to be lockpicked with lockpick = true
    Allow item authorisation with items = {'key_master', 'key_lspd'} etc.

Distant

image

Near Door

image

Dependencies

Installation

  • just plug an play and dont forgett to rename the folder from qb-nui_doorlock to nui_doorlock

How to use for bankrobbery

  • first of all you need to change some stuff in you config thats the config how it should be look for example here doorlock in pacific bank dont forgett to add the door id by your self. if you want it correctly working you need to change the table.insert for evrey door and add in evrey door the id manualy.
   fixText = false,
   doorID = 5,
   maxDistance = 2.0,
   lockpick = false,
   audioRemote = false,
   locked = true,
   objHeading = 340.00003051758,
   objCoords = vector3(256.3116, 220.6579, 106.4296),
   objHash = -222270721,
   authorizedJobs = { ['police']=0 },
   slides = false,
   garage = false,			
   	-- oldMethod = true,
   	-- audioLock = {['file'] = 'metal-locker.ogg', ['volume'] = 0.6},
   	-- audioUnlock = {['file'] = 'metallic-creak.ogg', ['volume'] = 0.7},
   	-- autoLock = 1000
})

the event how to trigger open a door automaticly when the hacking game of you shose is done and succes its this here TriggerServerEvent('nui_doorlock:server:updateState',5, false, false, true, false) ass you can see its the same door id like on my config.

nui_doorlock's People

Contributors

aypixt avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.