Add README.md

This commit is contained in:
root 2023-05-31 19:10:09 +00:00
parent 8807c7bfd9
commit f9cb0192b1

78
README.md Normal file
View File

@ -0,0 +1,78 @@
TODO:
- Custom maps
- increase people amount
- play with config
- inspect the mutator
- Proper shutdown with game status control
- Solve logging with custom /dev/null: `mknod /path/to/black/hole c 1 3`
- Apply webadmin patch
- Establish updates using <https://superuser.com/questions/1727148/check-if-steam-game-requires-an-update-via-command-line>
# Reverse engineering
## Signals listening
```
SigIgn: TRAP(5) ALRM(14)
SigCgt: ILL(4) ABRT(6) BUS(7) FPE(8) SEGV(11) (33)
```
# Hacks
## Parse maps cycle in python
```python
maps.split('=')[2].split(')')[0].replace('(', '[') + ']'
```
# Patch to webadmin
This patch should be applied to `KFGame/Web/ServerAdmin`
```diff
diff --git a/current_players_row.inc b/current_players_row.inc
index 9851873..f1cad82 100755
--- a/current_players_row.inc
+++ b/current_players_row.inc
@@ -2,9 +2,17 @@
<td style="background: <%player.teamcolor%>; color: <%player.teamcolor%>;"><%player.teamid%>&#160;</td>
<td><%player.name%></td>
<td class="right"><%player.ping%></td>
- <td><%player.ip%></td>
+ <td><a href="https://kf2.demb.uk:444/ServerAdmin/systemd_api/whois?ip=<%player.ip%>">^M
+ <div style="height:100%;width:100%">^M
+ <%player.ip%>^M
+ </div>^M
+</a></td>^M
<td><%player.uniqueid%></td>
- <td><%player.steamid%></td>
+ <td><a href="https://steamcommunity.com/profiles/<%player.steamid%>">^M
+ <div style="height:100%;width:100%">^M
+ <%player.steamid%>^M
+ </div>^M
+</a></td>^M
<td><%player.steamname%></td>
<td class="center"><%player.admin%></td>
<td class="center"><%player.spectator%></td>
diff --git a/header_base.inc b/header_base.inc
index 217a460..712fd3c 100755
--- a/header_base.inc
+++ b/header_base.inc
@@ -12,7 +12,7 @@
var pageUri = '<%page.fulluri%>';
</script>
<script type="text/javascript" src="/images/jquery.js?gzip"></script>
- <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,400italic,600,700,700italic,600italic' rel='stylesheet' type='text/css'>
+ <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,400italic,600,700,700italic,600italic' rel='stylesheet' type='text/css'>^M
<%html.headers%>
</head>
<body class="<%page.css.class%>">
diff --git a/navigation.inc b/navigation.inc
index a374dd1..213b986 100755
--- a/navigation.inc
+++ b/navigation.inc
@@ -2,4 +2,5 @@
<div id="menu">
<h2>Navigation</h2>
<%navigation.menu%>
+<li class="no-submenu"><a href="/ServerAdmin/systemd_api/restart" title="Restart server"><span>Restart server</span></a></li>^M
</div>
```