项目作者: CFC-Servers

项目描述 :
Stubs out M9k values allowing for customization without self-hosting of M9k
高级语言: Lua
项目地址: git://github.com/CFC-Servers/cfc_m9k_stubber.git
创建时间: 2019-01-06T19:05:47Z
项目社区:https://github.com/CFC-Servers/cfc_m9k_stubber

开源协议:GNU General Public License v3.0

下载


Relies on cfc_waiter: https://github.com/CFC-Servers/cfc_waiter

Allows for the stubbing of almost all properties on M9k without having to actually modify the M9k files directly.

One can create the stub files in lua/cfc_m9k_stubber/stubs/<pack>/<weapon_name>.lua (see below for example).

The stubs are applied after M9k is loaded during server startup.

Example stub registration

  1. -- lua/cfc_m9k_stubber/stubs/m9k_heavy_weapons/m9k_ares_shrike.lua
  2. if SERVER then AddCSLuaFile() end
  3. CFC_M9k_Stubber.registerStub(function()
  4. local weapon = weapons.GetStored("m9k_ares_shrike")
  5. weapon.Primary.Ammo = "AirboatGun"
  6. weapon.Primary.Damage = 20
  7. weapon.Primary.Spread = .08
  8. end)