Skip to content

Instantly share code, notes, and snippets.

@mittorn
mittorn / fix.sh
Created January 24, 2021 13:39
Fix gcc2/msvc6 server code
f="effects.h *.cpp monsters/*.cpp"
for m in SetThink SetTouch SetUse SetBlocked SetMoveDone; do
m2=`echo $m|sed -e s/Set/Reset/`
sed -e s/$m[[:space:]]\*\([[:space:]]\*/$m\(/g -e s/$m\([[:space:]]\*\\\&/$m\(/g -e s/$m\([[:space:]]\*NULL[[:space:]]\)/$m2\(\)/g -e s/$m\([[:space:]]*/$m\(\ \\\&/g -e s/$m2\(\)/$m\(\ NULL\ \)/g -i $f
done
@mittorn
mittorn / dlstub.c
Last active July 26, 2023 04:06
Static linking helpers. Static-linked glibc tries to load current glibc version dynamically, this is to workaround this mess
// this prevents using glibc's dinamic linker features (which may cause failure)
// remove -ldl when linking it, this should remove static linking warning
// if you really need dlopen implementation that works in static binary,
// try https://github.com/mittorn/custom-linker or android bionic linker
void *dlopen( const char *n, int f )
{
return 0;
}
void *dlsym( void *l, const char *n )
{
@mittorn
mittorn / xtree.cpp
Created February 23, 2019 15:49
xtree 2019(ggm coop)
#include "extdll.h"
#include "util.h"
#include "cbase.h"
class CXTreeModel: public CBaseEntity
{
void Precache()
{
PRECACHE_MODEL( "models/xtree.mdl" );
# default control; alsamixer and such will use this
ctl.!default {
type hw
card 1
}
# analog output (channels swapped, i have speakers swapped)
pcm.dmixer_onboard {
type dmix
ipc_key 1024
// ==UserScript==
// @name recaptcha
// @namespace *
// @include *
// @version 1
// @grant GM_xmlhttpRequest
// @grant GM.xmlHttpRequest
// ==/UserScript==
// https://addons.mozilla.org/en-US/firefox/addon/recaptcha-solver/
This file has been truncated, but you can view the full file.
diff --git b/change.log a/change.log
new file mode 100644
index 0000000..1993d14
--- /dev/null
+++ a/change.log
@@ -0,0 +1,797 @@
+build 3597
+
+Engine: implemenantion of generic extension of BSP file format. Some extra lumps used by mods to get a new features like terrains, improved lighting etc
+Engine: rewrite PVS system for variable PVS radius that can be used as FAT pvs or FAT phs without recalculating vis-array
This file has been truncated, but you can view the full file.
Только в engine/: Android.mk
diff --suppress-blank-empty -prudwEZbB engine/cdll_exp.h /mnt/data/Xash3D_original/engine/cdll_exp.h
--- engine/cdll_exp.h 2016-01-18 16:21:32.000000000 +0000
+++ /mnt/data/Xash3D_original/engine/cdll_exp.h 2016-02-24 19:10:06.000000000 +0000
@@ -15,10 +15,6 @@ GNU General Public License for more deta
#ifndef CDLL_EXP_H
#define CDLL_EXP_H
-struct tempent_s;
-struct engine_studio_api_s;
@mittorn
mittorn / userconfig.cfg
Last active December 3, 2015 05:04
cstrike userconfig
alias savequick "buy;hidescores"
// Simple toggle example
alias loadquick showscores
alias showscores "+showscores;alias loadquick hidescores"
alias hidescores "-showscores;alias loadquick showscores"
// Example of button action replace. Use unalias command to prevent recursive commands.
alias +duck toggle_duck
// echo does nothing
alias -duck echo
alias sitdown "unalias +duck;+duck;alias toggle_duck standup; alias +duck toggle_duck"
@mittorn
mittorn / telnet-example.c
Last active March 28, 2020 15:32
Simple telnet bot example
/* telnet-example.c
*
* Copyright (c) 2015 Mittorn. Use may be in whole
* or in part in accordance to the General Public License (GPL).
*
* THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL