/**
* Opcode #0xFE.
*
* CP n
*
* @param Core $core
*/
public static function opcode254(Core $core)
{
$dirtySum = $core->registerA - $core->memoryRead($core->programCounter);
$core->FHalfCarry = ($core->unsbtub($dirtySum) & 0xf) > ($core->registerA & 0xf);
$core->FCarry = $dirtySum < 0;
$core->FZero = $dirtySum == 0;
$core->programCounter = $core->programCounter + 1 & 0xffff;
$core->FSubtract = true;
}