Code Monkey home page Code Monkey logo

esx_badges's Introduction

Esx_badges

 

ESX Badges

Github top language Github language count Repository size License

About   |   Features   |   Technologies   |   Requirements   |   Usage   |   Further Links   |   License   |   Author


🎯 About

ESX Badges is an easy tool to let your players show their affiliation with agencies and firms. You can easily create your own badges and id cards. It is based on the jsfour ID-Card System by jonassvensson4. You can easily create your own id cards with the image tool of your choice.

✨ Features

✔️ easy to use;
✔️ easy to customize;
✔️ lightweight;

🚀 Technologies

The following tools were used in this project:

✅ Requirements

Before starting, you need to have a Running FiveM Server, a MySQL Connector (e.g. ox-mysql or mysql-async) and a running version of the ESX Framework installed.

🔧 Usage

To use the script you need to add the events to a client-side file of your choice and incorporate it in a menu of your choice.

The event has the following format:

TriggerServerEvent('esx_badges:open', showingPlayer, targetPlayer, job)

It is possible to trigger this event either from client-side or from server-side

Example:

-- Show your badge to someone (as a police officer)
closestPlayer, closestDistance = ESX.Game.GetClosestPlayer()
											
if closestDistance ~= -1 and closestDistance <= 3.0 then
  TriggerServerEvent('esx_badges:open', GetPlayerServerId(PlayerId()), GetPlayerServerId(closestPlayer), "police")
else
  ESX.ShowNotification("No players nerby.")
end

-- Look at your own badge
TriggerServerEvent('esx_badges:open', GetPlayerServerId(PlayerId()), GetPlayerServerId(PlayerId()), "police")

🏁 Further Links

📝 License

This project is under license from MIT. For more details, see the LICENSE file.

Made with ❤️ by derBalou

 

Back to top

esx_badges's People

Contributors

derbalou 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.