Skip to content

Instantly share code, notes, and snippets.

Avatar

Pau Oliva poliva

View GitHub Profile
@poliva
poliva / fc2-elo.js
Created Sep 28, 2020
Fightcade's ranking system Elo implementation
View fc2-elo.js
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
}
@poliva
poliva / ZP003030_V18_20160913_APROM_2A79_auth.hex
Created Sep 16, 2016
trace of brook firmware upgrade on Universal Fighting Board
View ZP003030_V18_20160913_APROM_2A79_auth.hex
:020000040000FA
:10000000A976D7144AAB0748401C6DA28CF3B39174
:100010004423E4C3F75415F9DAC55819797E4A1B0D
:10002000DEF2AB7FFCD90E232C0D3F56187EA4B018
:1000300010F5100145264133F5697956D0D7BC76C5
:10004000CB2EDDDBBBA23E400399EBD2A8CA1B0638
:100050000A61173D08D8838DB608B4BF753AE5F438
:100060004EA82815C37BBEFD9DEE1F62582070BCB4
:100070000352A0EF7A4872C462BCDE14854697ED45
:100080004478C82223E60B431E3D2CA8F8AF8D0C04
@poliva
poliva / changes-for-root.txt
Created Oct 8, 2015
sediff output of the changes done by Chainfire's supolicy to sepolicy to allow root in Enforcing mode
View changes-for-root.txt
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 / dynhuff.cpp
Created Oct 28, 2014
standalone Dynamic Huffman Encoder/Decoder
View dynhuff.cpp
//
// Dynamic Huffman Encoder/Decoder
//
// implemented by Gangta
//
//-----------------------------------------------------------
//
// Version History
//
// version 0.1 - first release
@poliva
poliva / ssf2xj-select-difficulty.xml
Created Apr 8, 2014
SSF2XJ mame cheat: Select Difficulty
View ssf2xj-select-difficulty.xml
<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 / ssf2xj-cpu-to-human-player.xml
Last active Aug 29, 2015
SSF2XJ mame cheat: CPU to Human Player
View ssf2xj-cpu-to-human-player.xml
<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-controller-mode-1.xml
Created Apr 8, 2014
SSF2XJ mame cheat: controller mode
View ssf2xj-controller-mode-1.xml
<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-combo-msg-on-cpu.xml
Last active Aug 29, 2015
SSF2XJ mame cheat: Show combo messages on CPU
View ssf2xj-combo-msg-on-cpu.xml
<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>
View keybase.md

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:

You can’t perform that action at this time.