Coder Social home page Coder Social logo

hx_medical's Introduction

RP Medical - WIP

Simple medical system for ox_core that leverages StateBags, statuses and the CEventNetworkEntityDamage game event.

Our goal was to decouple the EMS job from the medical system to allow more flexibility. This system will not include EMS but we do plan on writing that as a separate resource.

This script handles:

  1. Wounding statuses using ox_core's status system.
    • bleed
    • stagger
    • unconscious
  2. Player death and respawning using player state.
  3. Usage of Pillbox (default configured to AshiroDev's hospital map) for self-serve care.

Many lines of code have been borrowed from qbox-ambulancejob and their efforts have saved us a significant amount of work and time. Thanks guys.

Contributions

Please open an issue prior to spending time coding any major changes to avoid wasting your time.

Exports

Revive player:

exports.rp_medical:Revive(target)

Dependecies

Optional

Installation

Drop script into resources folder

Create config file: medical.cfg to adjust default settings

Convars:

## respawn countdown (in seconds) | 180 by default
 setr medical:deathTimer 60

## 0 to disable 1 to enable | 0 by default
 setr medical:debug 1

Database:

Update required to run this script properly.

Run statuses.sql to update your database for compatibility or manually update the ox_statuses table.

INSERT INTO `ox_statuses` (`name`, `ontick`) VALUES ('unconscious', -0.1);
INSERT INTO `ox_statuses` (`name`, `ontick`) VALUES ('stagger', -0.1);
INSERT INTO `ox_statuses` (`name`, `ontick`) VALUES ('bleed', 0);

License

GPLv3 License

Authors

hx_medical's People

Contributors

sumndaiy avatar tclrd avatar sovimuffin avatar ruggione avatar boringwolf 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.