Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

  • I am poliva on github.
  • I am pof (https://keybase.io/pof) on keybase.
  • I have a public key whose fingerprint is E641 0CE8 E19F 770F 1A9D DF67 665D 05B5 3353 9E02

To claim this, I am signing this object:

@poliva
poliva / ssf2xj-combo-msg-on-cpu.xml
Last active August 29, 2015 13:58
SSF2XJ mame cheat: Show combo messages on CPU
<cheat desc="Show combo messages on CPU">
<script state="on">
<action>maincpu.ow@68f58=4E71</action>
</script>
<script state="off">
<action>maincpu.ow@68f58=671A</action>
</script>
</cheat>
@poliva
poliva / ssf2xj-controller-mode-1.xml
Created April 8, 2014 07:50
SSF2XJ mame cheat: controller mode
<cheat desc="P1 Controller">
<comment>Crashes if the game started as Human and you switch it to CPU</comment>
<parameter>
<item value="0x00">CPU</item>
<item value="0x01">Human</item>
</parameter>
<script state="run">
<action>maincpu.pb@FF87DC=param</action>
</script>
</cheat>
@poliva
poliva / ssf2xj-cpu-to-human-player.xml
Last active August 29, 2015 13:58
SSF2XJ mame cheat: CPU to Human Player
<cheat desc="CPU to Human Player">
<comment>Human controlled CPU</comment>
<script state="on">
<action>maincpu.ow@078034=4E71</action>
</script>
<script state="off">
<action>maincpu.ow@078034=6710</action>
</script>
</cheat>
@poliva
poliva / ssf2xj-select-difficulty.xml
Created April 8, 2014 08:07
SSF2XJ mame cheat: Select Difficulty
<cheat desc="Select Difficulty">
<parameter>
<item value="0x00">1/Easiest</item>
<item value="0x01">2/Very Easy</item>
<item value="0x02">3/Easy</item>
<item value="0x03">4/Medium</item>
<item value="0x04">5/Medium Hard</item>
<item value="0x05">6/Hard</item>
<item value="0x06">7/Very Hard</item>
<item value="0x07">8/Hardest</item>
@poliva
poliva / dynhuff.cpp
Created October 28, 2014 12:30
standalone Dynamic Huffman Encoder/Decoder
//
// Dynamic Huffman Encoder/Decoder
//
// implemented by Gangta
//
//-----------------------------------------------------------
//
// Version History
//
// version 0.1 - first release
@poliva
poliva / changes-for-root.txt
Created October 8, 2015 12:14
sediff output of the changes done by Chainfire's supolicy to sepolicy to allow root in Enforcing mode
Classes (Added 0, Removed 0, Modified 0)
Added Classes: 0
Removed Classes: 0
Modified Classes: 0
Commons (Added 0, Removed 0, Modified 0)
Added Commons: 0
Removed Commons: 0
Modified Commons: 0
@poliva
poliva / ZP003030_V18_20160913_APROM_2A79_auth.hex
Created September 16, 2016 07:49
trace of brook firmware upgrade on Universal Fighting Board
:020000040000FA
:10000000A976D7144AAB0748401C6DA28CF3B39174
:100010004423E4C3F75415F9DAC55819797E4A1B0D
:10002000DEF2AB7FFCD90E232C0D3F56187EA4B018
:1000300010F5100145264133F5697956D0D7BC76C5
:10004000CB2EDDDBBBA23E400399EBD2A8CA1B0638
:100050000A61173D08D8838DB608B4BF753AE5F438
:100060004EA82815C37BBEFD9DEE1F62582070BCB4
:100070000352A0EF7A4872C462BCDE14854697ED45
:100080004478C82223E60B431E3D2CA8F8AF8D0C04
@poliva
poliva / fc2-elo.js
Created September 28, 2020 10:13
Fightcade's ranking system Elo implementation
function getK (elo) {
// for rank '?' (<10 games played) the K factor is 20
if (elo < 700) return 34; // rank E
if (elo < 1000) return 32; // rank D
if (elo < 1300) return 30; // rank C
if (elo < 1600) return 28; // rank B
if (elo < 1900) return 26; // rank A
return 24; // rank S
}