mirror of
https://github.com/etlegacy/etlegacy-lua-scripts.git
synced 2025-02-19 18:31:43 +00:00
Merge pull request #4 from estorado/master
Add modname and version to lua
This commit is contained in:
commit
e0f0e71daf
2 changed files with 20 additions and 1 deletions
14
README.md
14
README.md
|
@ -1,6 +1,6 @@
|
|||
# Lua scripts
|
||||
|
||||
Lua scripts for the Legacy mod
|
||||
* Lua scripts for the Legacy mod.
|
||||
|
||||
|
||||
## CONSTANTS
|
||||
|
@ -39,3 +39,15 @@ Lua scripts for the Legacy mod
|
|||
## announcehp
|
||||
|
||||
* Killer's HP is displayed to their victims.
|
||||
|
||||
# Notes
|
||||
* Please always add modname and version to your lua script
|
||||
```
|
||||
modname="NameofLua"
|
||||
version="1.0"
|
||||
|
||||
function et_InitGame()
|
||||
et.RegisterModname(modname.." "..version)
|
||||
end
|
||||
```
|
||||
|
||||
|
|
|
@ -1,4 +1,11 @@
|
|||
--Source: http://lua.wolffiles.de/?fileid=32
|
||||
modname="AnnounceHP"
|
||||
version="1.0"
|
||||
|
||||
function et_InitGame()
|
||||
et.RegisterModname(modname.." "..version)
|
||||
end
|
||||
|
||||
function et_Obituary(victimnum, killernum, meansofdeath)
|
||||
local victimteam = tonumber(et.gentity_get(victimnum, "sess.sessionTeam"))
|
||||
local killerteam = tonumber(et.gentity_get(killernum, "sess.sessionTeam"))
|
||||
|
|
Loading…
Reference in a new issue