Skip to content

Instantly share code, notes, and snippets.

View markski1's full-sized avatar

Markski / Juan G. markski1

View GitHub Profile
## Based on Nbjohnston86's simple_tes3mp_deploy script.
## Just fixes a few bugs dealing with files.
## https://github.com/Nbjohnston86/simple_tes3mp_deploy/
## any error will stop the script.
set -e
## parameter 1: tes3mp binaries
if [ -z "$1" ]
then
@markski1
markski1 / samp-precise-timers-benchmark.pwn
Last active June 4, 2019 13:36
Accuracy benchmark of the samp-precise-timers plugin
//////////////////
/*
These are the results of 1 minute of samp-precise-timers accuracy tests in a server with NPCs and several other timers w/ moderately sized functions on each actively running.
Please note that the most severe innacuracies are most likely to be caused by the time it takes the AMX instance to finish a callback before serving the Timer's call rather than the timer itself being inaccurate.
The results display that even in these conditions the timer's accuracy remains within a <1% threshold, 99% of the time.
Data compiled by Markski
*/
//////////////////
@markski1
markski1 / SG.INC
Last active June 30, 2020 07:48
Calculate the amount of shotgun pellets that hit a target based on the given damage. Works for all kinds of shotgun.
/*
2019 by Markski. mrks.cf
The function CalculateSGHitPellets is for calculating the hit pellets of a Sawn-Off shotgun or a Pump Action shotgun.
The function CalculateCSGHitPellets is for calculating the hit pellets of a Combat shotgun.
The functions should only be called if the weaponid is the correct one for each. (Combat Shotgun: 27, Sawn-Off: 26, Pump Action: 25)