I tried branching method before and all it does is crash the game. For example like the game you already hacked; Castle Clashers.
// Token: 0x060019A4 RID: 6564 RVA: 0x00003F32 File Offset: 0x00003F32
[global::Address(RVA = "0x36BBEEC", Offset = "0x36BBEEC", VA = "0x36BBEEC")]
public void OnSettingsButtonClicked()
{
}
// Token: 0x06001A7A RID: 6778 RVA: 0x0000410B File Offset: 0x0000410B
[global::Address(RVA = "0x36CA520", Offset = "0x36CA520", VA = "0x36CA520")]
public void OnSettingsClicked()
{
}
// Token: 0x06002F1A RID: 12058 RVA: 0x00007108 File Offset: 0x00007108
[global::Address(RVA = "0x38D0138", Offset = "0x38D0138", VA = "0x38D0138")]
public static void TryOpen()
{
}
// Token: 0x06000735 RID: 1845 RVA: 0x00001788 File Offset: 0x00001788
[Obsolete]
[global::Address(RVA = "0x348D3CC", Offset = "0x348D3CC", VA = "0x348D3CC")]
internal void OnCheatingDetected(IObscuredType type, object decrypted, object fake)
{
}
Settings button (Gear icon): 0x36BBEEC with branch to tryopen (93500894)
Math: TryNow 38D0138 - SettingsButton 36BBEEC = 21424C
bl #0x21424c
OnClick Settings button: 36CA520 with branch to tryopen (06170894)
Same method with doing the math above.
Disable anti-cheats: 348D3CC with a return (c0035fd6) or nop (1f2003d5)
when settings is pressed; nothing happen; instead it crashes the game.